:root {
  color-scheme: dark;
  --muted: #b9c2cf;
  --ink: #b9c2cf;
  --panel: #101722;
  --panel-soft: #151f2d;
  --line: #2a3647;
  --page: #070b10;
  --navy: #0c1320;
  --gold: #f5c542;
  --green: #2ed47a;
  --yellow: #f3b23c;
  --red: #ff5f56;
  --blue: #4aa3ff;
  --green-bg: #10291d;
  --yellow-bg: #30230c;
  --red-bg: #321615;
  --status-pill-font-size: 0.68rem;
  --status-pill-font-weight: 1000;
  --status-pill-height: 22px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

@property --spin-angle {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0deg;
}

* {
  box-sizing: border-box;
}

html {
  max-width: 100%;
  overflow-x: hidden;
}

body {
  margin: 0;
  min-height: 100vh;
  background: radial-gradient(circle at 30% 0, rgba(245, 197, 66, 0.12), transparent 32%), var(--page);
  color: var(--ink);
  max-width: 100%;
  overflow-x: hidden;
  overflow-y: scroll;
  scrollbar-gutter: stable;
}

button,
input {
  font: inherit;
}

input[type="datetime-local"] {
  color-scheme: dark;
  min-width: 0;
  text-transform: none;
}

.app-shell {
  align-items: start;
  display: grid;
  gap: 0;
  margin: 0 auto;
  max-width: 1120px;
  padding: 16px;
  width: 100%;
}

.mission-panel,
.results-panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  min-width: 0;
  padding: 16px;
}

.mission-panel {
  overflow: hidden;
  position: relative;
}

.brand-row {
  align-items: center;
  --impact-x: clamp(228px, 68vw, 304px);
  --impact-y: 33px;
  --tracer-travel: 92px;
  --tracer-width: 92px;
  display: flex;
  gap: 12px;
  margin-bottom: 18px;
  overflow: hidden;
  padding-left: 6px;
  position: relative;
}

.brand-mark {
  border: 1px solid rgba(245, 197, 66, 0.42);
  border-radius: 8px;
  filter: brightness(0.88) contrast(0.95);
  height: 72px;
  object-fit: cover;
  width: 72px;
}

.brand-link {
  border-radius: 8px;
  display: inline-flex;
  position: relative;
  transition: box-shadow 160ms ease, transform 120ms ease;
}

.brand-link::before,
.brand-link::after {
  content: "";
  pointer-events: none;
  position: absolute;
}

.brand-link::before {
  border: 1px solid rgba(245, 197, 66, 0.62);
  border-radius: 10px;
  inset: -4px;
  opacity: 0;
}

.brand-link::after {
  background: radial-gradient(circle, #fff9d8 0 16%, rgba(245, 197, 66, 0.92) 36%, transparent 68%);
  border-radius: 999px;
  filter: blur(0.2px);
  height: 18px;
  opacity: 0;
  right: -10px;
  top: 27px;
  width: 24px;
}

.brand-tracer {
  background:
    radial-gradient(ellipse at 96% 50%, #ffffff 0 7%, #fff6c7 16%, rgba(245, 197, 66, 0.76) 28%, transparent 44%),
    linear-gradient(90deg, transparent 0%, rgba(245, 197, 66, 0.03) 26%, rgba(245, 197, 66, 0.2) 68%, rgba(255, 255, 255, 0.78) 100%);
  border-radius: 999px;
  box-shadow: 0 0 8px rgba(255, 255, 255, 0.55), 0 0 18px rgba(245, 197, 66, 0.46);
  height: 3px;
  left: calc(var(--impact-x) - var(--tracer-width));
  opacity: 0;
  pointer-events: none;
  position: absolute;
  top: 34px;
  transform-origin: 90% 50%;
  width: var(--tracer-width);
  z-index: 5;
}

.brand-tracer::before {
  content: "";
  display: none;
}

.brand-tracer::after {
  background: linear-gradient(90deg, #9b7227 0%, #e7bd68 38%, #fff8d4 72%, #ffffff 100%);
  border-radius: 55% 50% 50% 55% / 50%;
  box-shadow: inset -2px 0 3px rgba(255, 255, 255, 0.62), inset 2px 0 4px rgba(75, 39, 8, 0.42), 0 0 8px #fff, 0 0 18px rgba(245, 197, 66, 0.82);
  content: "";
  height: 7px;
  position: absolute;
  right: -1px;
  top: -1px;
  width: 16px;
}

.brand-shatter {
  background:
    radial-gradient(circle at 42% 45%, #ffffff 0 17%, #fff1a6 18% 36%, #a97928 37% 58%, transparent 62%),
    linear-gradient(90deg, #6f4515, #d6a13f 48%, #fff3b0 100%);
  border-radius: 60% 42% 42% 60% / 52%;
  box-shadow:
    0 0 0 rgba(255, 255, 255, 0),
    0 0 0 rgba(245, 197, 66, 0),
    0 0 0 rgba(255, 255, 255, 0),
    0 0 0 rgba(245, 197, 66, 0),
    0 0 0 rgba(255, 255, 255, 0),
    0 0 0 rgba(245, 197, 66, 0),
    0 0 0 rgba(255, 255, 255, 0);
  filter: drop-shadow(0 0 4px rgba(255, 245, 188, 0.55));
  height: 5px;
  opacity: 0;
  pointer-events: none;
  position: absolute;
  left: var(--impact-x);
  top: var(--impact-y);
  transform-origin: 40% 50%;
  width: 6px;
  z-index: 6;
}

.brand-link:hover,
.brand-link:focus-visible {
  box-shadow: 0 0 0 2px rgba(245, 197, 66, 0.28), 0 0 22px rgba(245, 197, 66, 0.52);
  outline: none;
}

.brand-link:active {
  transform: scale(0.97);
}

.brand-row.brand-animate .brand-link {
  animation: logoCharge 0.42s cubic-bezier(0.18, 0.84, 0.22, 1) both;
}

.brand-row.brand-animate .brand-link::before {
  animation: chargeRing 0.42s cubic-bezier(0.14, 0.82, 0.24, 1) both;
}

.brand-row.brand-animate .brand-link::after {
  animation: muzzleFlash 0.16s ease-out 0.31s both;
}

.brand-row.brand-animate .brand-tracer {
  animation: tracerShot 0.28s linear 0.36s both;
}

.brand-row.brand-animate .brand-shatter {
  animation: bulletShatter 0.36s ease-out 0.62s forwards;
  background: transparent;
  filter: none;
}

.brand-row.brand-animate .brand-fire-button span {
  animation: boltFireRecoil 0.72s cubic-bezier(0.16, 0.9, 0.28, 1) both;
}

.eyebrow,
.role,
.decision-label {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0;
  margin: 0 0 4px;
  text-transform: uppercase;
}

h1,
h2,
h3,
h4,
p {
  margin-top: 0;
}

h1 {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  font-size: 1.65rem;
  gap: 0.18em;
  line-height: 1.1;
  margin-bottom: 0;
  position: relative;
}

h1::after {
  content: none;
}

.brand-fire-button {
  align-items: center;
  align-self: center;
  background: transparent;
  border: 0;
  border-radius: 6px;
  cursor: pointer;
  display: inline-grid;
  height: 1.08em;
  justify-items: center;
  margin: 0 0.02em;
  min-height: 0;
  padding: 0;
  position: relative;
  transition: filter 140ms ease, transform 110ms ease;
  width: 0.64em;
}

.brand-fire-button span {
  background: linear-gradient(160deg, #e2d8bd 0%, #c99f35 48%, #8f6519 100%);
  clip-path: polygon(58% 0, 18% 50%, 45% 50%, 30% 100%, 86% 36%, 57% 36%);
  display: block;
  filter: drop-shadow(0 0 3px rgba(201, 159, 53, 0.28));
  height: 0.98em;
  transform: skewX(-4deg);
  width: 0.56em;
}

.brand-fire-button:hover,
.brand-fire-button:focus-visible {
  filter: drop-shadow(0 0 6px rgba(201, 159, 53, 0.46));
  outline: none;
}

.brand-fire-button:active {
  transform: translateY(1px) scale(0.94);
}

.mission-form {
  display: grid;
  gap: 12px;
  grid-template-columns: 1fr;
}

.alternate-actions {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.code-hunt-icon {
  border: 2px solid currentColor;
  border-radius: 50%;
  display: inline-block;
  height: 18px;
  position: relative;
  width: 18px;
}

.code-hunt-icon::before {
  background: currentColor;
  border-radius: 999px;
  content: "";
  height: 2px;
  left: 3px;
  position: absolute;
  top: 7px;
  width: 10px;
}

.code-hunt-icon::after {
  background: currentColor;
  border-radius: 999px;
  content: "";
  height: 8px;
  position: absolute;
  right: -4px;
  top: 12px;
  transform: rotate(45deg);
  width: 2px;
}

.code-hunt-button.code-hunt-thinking .code-hunt-icon {
  animation: codeHuntSpin 720ms cubic-bezier(0.2, 0.75, 0.28, 1) infinite;
}

.code-hunt-button.code-hunt-settle .code-hunt-icon {
  animation: codeHuntSettle 480ms cubic-bezier(0.16, 0.9, 0.32, 1) both;
}

.input-action-row,
.mission-submit-row {
  display: grid;
  gap: 8px;
  grid-template-columns: minmax(0, 1fr) 54px;
}

.now-reference {
  display: grid;
  gap: 6px;
}

.now-reference span {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 700;
}

.now-reference p {
  align-items: center;
  background: #0b111b;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  display: flex;
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.25;
  margin: 0;
  min-height: 46px;
  padding: 10px 12px;
}

.mission-submit-row {
  grid-template-columns: 54px minmax(0, 1fr) 54px;
}

.symbol-button {
  align-items: center;
  display: inline-flex;
  font-family: inherit;
  font-size: 1.2rem;
  font-weight: 1000;
  justify-content: center;
  line-height: 1;
  min-height: 42px;
  padding: 8px;
}

.copy-icon {
  height: 18px;
  position: relative;
  width: 18px;
}

.copy-icon::before,
.copy-icon::after {
  border: 2px solid currentColor;
  border-radius: 3px;
  content: "";
  height: 12px;
  position: absolute;
  width: 12px;
}

.copy-icon::before {
  left: 1px;
  top: 4px;
  opacity: 0.72;
}

.copy-icon::after {
  background: var(--panel-soft);
  left: 5px;
  top: 0;
}

.dice-button {
  overflow: hidden;
  position: relative;
}

.dice-icon {
  background:
    radial-gradient(circle at 32% 32%, #0b111b 0 2px, transparent 2.5px),
    radial-gradient(circle at 68% 32%, #0b111b 0 2px, transparent 2.5px),
    radial-gradient(circle at 50% 50%, #0b111b 0 2px, transparent 2.5px),
    radial-gradient(circle at 32% 68%, #0b111b 0 2px, transparent 2.5px),
    radial-gradient(circle at 68% 68%, #0b111b 0 2px, transparent 2.5px),
    var(--ink);
  border: 1px solid rgba(245, 197, 66, 0.55);
  border-radius: 6px;
  box-shadow: inset 0 -2px 4px rgba(0, 0, 0, 0.22), 0 0 10px rgba(245, 197, 66, 0.18);
  display: inline-block;
  height: 24px;
  transform: rotate(0deg);
  width: 24px;
}

.risk-dice-icon {
  background:
    radial-gradient(circle at 32% 32%, #fff2ee 0 2px, transparent 2.5px),
    radial-gradient(circle at 68% 32%, #fff2ee 0 2px, transparent 2.5px),
    radial-gradient(circle at 50% 50%, #fff2ee 0 2px, transparent 2.5px),
    radial-gradient(circle at 32% 68%, #fff2ee 0 2px, transparent 2.5px),
    radial-gradient(circle at 68% 68%, #fff2ee 0 2px, transparent 2.5px),
    linear-gradient(145deg, #ff7c72, #9f241f);
  border-color: rgba(255, 95, 86, 0.78);
  box-shadow: inset 0 -2px 5px rgba(0, 0, 0, 0.34), 0 0 12px rgba(255, 95, 86, 0.24);
}

.risk-dice-button:hover,
.risk-dice-button:focus-visible {
  box-shadow: 0 0 0 2px rgba(255, 95, 86, 0.24), 0 0 18px rgba(255, 95, 86, 0.38);
}

.risk-dice-button.dice-on-fire {
  overflow: visible;
}

.risk-dice-button.dice-on-fire::before,
.risk-dice-button.dice-on-fire::after {
  border-radius: 999px;
  content: "";
  left: 50%;
  pointer-events: none;
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 0;
}

.risk-dice-button.dice-on-fire::before {
  animation: riskDiceFire 680ms ease-in-out infinite alternate;
  background:
    radial-gradient(circle at 50% 62%, rgba(255, 255, 230, 0.95) 0 8px, transparent 9px),
    radial-gradient(circle at 48% 48%, rgba(245, 197, 66, 0.95) 0 15px, transparent 16px),
    radial-gradient(circle at 52% 36%, rgba(255, 95, 86, 0.72) 0 24px, transparent 25px);
  filter: blur(2px);
  height: 56px;
  width: 56px;
}

.risk-dice-button.dice-on-fire::after {
  animation: riskDiceEmbers 520ms linear infinite;
  box-shadow:
    -17px -15px 0 -2px rgba(255, 236, 160, 0.85),
    -5px -23px 0 -2px rgba(255, 95, 86, 0.78),
    11px -19px 0 -2px rgba(245, 197, 66, 0.78),
    19px -9px 0 -3px rgba(255, 255, 230, 0.72),
    -20px 8px 0 -3px rgba(255, 95, 86, 0.52);
  height: 6px;
  width: 6px;
}

.risk-dice-button.dice-on-fire .dice-icon {
  animation: riskDiceHeat 300ms ease-in-out infinite alternate;
  position: relative;
  z-index: 1;
}

.risk-dice-button.dice-on-fire.dice-fire-fade::before,
.risk-dice-button.dice-on-fire.dice-fire-fade::after {
  animation: riskDiceFadeOut 760ms ease forwards;
}

.risk-dice-button.dice-on-fire.dice-fire-fade .dice-icon {
  animation: riskDiceIconFadeOut 760ms ease forwards;
}

.search-icon {
  border: 2px solid var(--ink);
  border-radius: 999px;
  display: inline-block;
  height: 16px;
  position: relative;
  width: 16px;
}

.search-icon::after {
  background: var(--ink);
  border-radius: 999px;
  content: "";
  height: 8px;
  position: absolute;
  right: -6px;
  top: 11px;
  transform: rotate(45deg);
  transform-origin: 50% 0;
  width: 2px;
}

.compass-icon {
  background:
    linear-gradient(35deg, transparent 44%, #0b111b 45% 55%, transparent 56%),
    linear-gradient(125deg, transparent 44%, #0b111b 45% 55%, transparent 56%),
    radial-gradient(circle, transparent 0 4px, #0b111b 4.5px 5.5px, transparent 6px),
    radial-gradient(circle, rgba(245, 197, 66, 0.95), rgba(245, 197, 66, 0.18));
  border: 1px solid rgba(245, 197, 66, 0.65);
  border-radius: 999px;
  box-shadow: inset 0 -2px 5px rgba(0, 0, 0, 0.34), 0 0 12px rgba(245, 197, 66, 0.2);
  display: inline-block;
  height: 26px;
  position: relative;
  width: 26px;
}

.compass-icon::before,
.compass-icon::after {
  content: "";
  left: 50%;
  position: absolute;
  top: 50%;
  transform-origin: 50% 85%;
}

.compass-icon::before {
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-bottom: 13px solid var(--red);
  transform: translate(-50%, -84%) rotate(28deg);
}

.compass-icon::after {
  border-left: 3px solid transparent;
  border-right: 3px solid transparent;
  border-top: 10px solid var(--ink);
  transform: translate(-50%, 0%) rotate(28deg);
}

.compass-button:hover,
.compass-button:focus-visible {
  box-shadow: 0 0 0 2px rgba(245, 197, 66, 0.24), 0 0 18px rgba(245, 197, 66, 0.38);
}

.dice-thinking .dice-icon {
  animation: diceRoll 720ms cubic-bezier(0.2, 0.75, 0.28, 1) infinite;
}

.dice-settle .dice-icon {
  animation: diceSettle 480ms cubic-bezier(0.16, 0.9, 0.32, 1) both;
}

.time-jump-button {
  font-size: 0.9rem;
  font-weight: 1000;
  min-height: 46px;
  padding: 8px;
}

label {
  display: grid;
  gap: 6px;
}

label span {
  align-items: center;
  color: var(--muted);
  display: flex;
  font-size: 0.86rem;
  font-weight: 700;
  justify-content: space-between;
}

.inline-count {
  background: rgba(245, 197, 66, 0.12);
  border: 1px solid rgba(245, 197, 66, 0.42);
  border-radius: 999px;
  color: #ffe0a3;
  display: inline-flex;
  font-size: 0.7rem;
  font-weight: 1000;
  justify-content: center;
  line-height: 1;
  margin-left: 6px;
  min-width: 24px;
  padding: 4px 7px;
}

.flight-time-pill {
  cursor: pointer;
  font-family: inherit;
  margin-left: auto;
  min-height: 0;
  transition: box-shadow 160ms ease, transform 120ms ease, border-color 160ms ease;
}

.flight-time-pill:hover,
.flight-time-pill:focus-visible {
  box-shadow: 0 0 0 2px rgba(46, 212, 122, 0.18), 0 0 14px rgba(46, 212, 122, 0.22);
  outline: none;
}

.flight-time-pill:active {
  transform: translateY(1px) scale(0.98);
}

.flight-time-good {
  background: rgba(38, 224, 127, 0.12);
  border-color: rgba(38, 224, 127, 0.58);
  color: #b8ffd4;
}

.flight-time-bad {
  background: rgba(255, 91, 91, 0.16);
  border-color: rgba(255, 91, 91, 0.72);
  color: #ffd2d2;
}

.sortie-duration-panel {
  display: grid;
  gap: 12px;
}

input {
  background: #0b111b;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  min-height: 46px;
  min-width: 0;
  padding: 10px 12px;
  text-transform: uppercase;
  width: 100%;
}

input[type="date"] {
  text-transform: none;
}

button {
  background: var(--gold);
  border: 0;
  border-radius: 8px;
  color: #0b111b;
  cursor: pointer;
  font-weight: 800;
  min-height: 48px;
  padding: 12px 16px;
  transform: translateY(0);
  transition: box-shadow 160ms ease, transform 120ms ease, filter 160ms ease, border-color 160ms ease;
  -webkit-tap-highlight-color: transparent;
}

button:hover,
button:focus-visible {
  box-shadow: 0 0 0 2px rgba(245, 197, 66, 0.26), 0 0 22px rgba(245, 197, 66, 0.52);
  filter: brightness(1.08);
  outline: none;
}

button:active {
  box-shadow: 0 0 0 3px rgba(245, 197, 66, 0.38), 0 0 30px rgba(245, 197, 66, 0.72);
  transform: translateY(1px) scale(0.98);
}

button:disabled {
  cursor: not-allowed;
}

#check-mission-button {
  align-items: center;
  display: inline-flex;
  justify-content: center;
  line-height: 1.12;
  min-height: 60px;
  text-align: center;
  white-space: normal;
}

.button-searching {
  background:
    linear-gradient(var(--gold), var(--gold)) padding-box,
    conic-gradient(from var(--spin-angle), rgba(255, 255, 255, 0.55), rgba(245, 197, 66, 0.08), rgba(255, 255, 255, 0.55)) border-box;
  border: 2px solid transparent;
  box-shadow: 0 0 0 1px rgba(245, 197, 66, 0.22), 0 0 12px rgba(245, 197, 66, 0.2);
  animation: buttonSpin 0.85s linear infinite;
}

.button-success {
  background: var(--gold);
  box-shadow: 0 0 0 2px rgba(46, 212, 122, 0.32), 0 0 12px rgba(46, 212, 122, 0.34);
}

.button-partial {
  background: var(--gold);
  box-shadow: 0 0 0 2px rgba(243, 178, 60, 0.34), 0 0 12px rgba(243, 178, 60, 0.34);
}

.button-unable {
  background: var(--gold);
  box-shadow: 0 0 0 2px rgba(255, 95, 86, 0.32), 0 0 12px rgba(255, 95, 86, 0.34);
}

.secondary-button {
  background: var(--panel-soft);
  border: 1px solid var(--line);
  color: var(--ink);
  min-height: 42px;
}

.rulebook-panel {
  background: #0b111b;
  border: 1px solid rgba(245, 197, 66, 0.34);
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.55), 0 0 30px rgba(245, 197, 66, 0.18);
  color: var(--muted);
  font-size: 0.82rem;
  isolation: isolate;
  line-height: 1.4;
  left: 50%;
  max-height: calc(100dvh - 16px);
  max-width: 520px;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 12px;
  position: fixed;
  top: 50%;
  transform: translate(-50%, -50%);
  width: calc(100vw - 32px);
  z-index: 1100;
}

.rulebook-panel[hidden] {
  display: none;
}

.visibility-table-panel,
.wind-table-panel {
  z-index: 1140;
}

body.rulebook-open::before,
body.defaults-open::before,
body.limits-open::before,
body.sortie-duration-open::before,
body.visibility-table-open::before,
body.wind-table-open::before,
body.code-hunt-open::before,
body.assist-lock-open::before,
body.search-open::before {
  content: none;
}

body.rulebook-open,
body.defaults-open,
body.limits-open,
body.sortie-duration-open,
body.visibility-table-open,
body.wind-table-open,
body.code-hunt-open,
body.assist-lock-open,
body.search-open {
  overflow: hidden;
}

.rulebook-header {
  align-items: center;
  display: flex;
  gap: 10px;
  justify-content: space-between;
}

.conversion-table-button {
  background: rgba(74, 163, 255, 0.12);
  border: 1px solid rgba(74, 163, 255, 0.5);
  border-radius: 999px;
  color: #cfe7ff;
  display: inline-flex;
  font-size: 0.66rem;
  font-weight: 1000;
  line-height: 1;
  margin-left: 6px;
  min-height: 0;
  padding: 3px 7px;
  text-transform: uppercase;
  vertical-align: 0.08em;
}

.conversion-table-button:hover,
.conversion-table-button:focus-visible {
  box-shadow: 0 0 0 2px rgba(74, 163, 255, 0.22), 0 0 16px rgba(74, 163, 255, 0.32);
  outline: none;
}

.conversion-table {
  border-collapse: collapse;
  color: var(--ink);
  font-size: 0.86rem;
  width: 100%;
}

.conversion-table th,
.conversion-table td {
  border-bottom: 1px solid var(--line);
  padding: 7px 8px;
  text-align: left;
}

.conversion-table th {
  color: #cfe7ff;
  font-size: 0.72rem;
  text-transform: uppercase;
}

.conversion-table tr:last-child td {
  border-bottom: 0;
}

.rulebook-panel h2 {
  align-items: center;
  color: var(--ink);
  display: inline-flex;
  font-size: 0.9rem;
  gap: 8px;
  margin-bottom: 0;
  text-transform: uppercase;
}

.guide-title-icon {
  flex: 0 0 auto;
  transform: scale(0.78);
  transform-origin: center;
}

.rulebook-panel h3 {
  color: var(--ink);
  font-size: 0.8rem;
  margin: 12px 0 6px;
  text-transform: uppercase;
}

.rulebook-close {
  font-size: 0.9rem;
  font-weight: 1000;
  min-height: 34px;
  min-width: 42px;
  padding: 6px 10px;
}

.rulebook-panel p {
  margin-top: 8px;
  margin-bottom: 8px;
}

.rulebook-panel ul {
  margin: 0;
  padding-left: 18px;
}

.rulebook-panel li + li {
  margin-top: 5px;
}

.guide-control-list {
  list-style: none;
  padding-left: 0;
}

.guide-control-list li {
  align-items: center;
  display: grid;
  gap: 10px;
  grid-template-columns: 28px minmax(0, 1fr);
}

.guide-symbol,
.guide-glyph {
  align-items: center;
  display: inline-flex;
  justify-content: center;
  justify-self: center;
}

.guide-glyph {
  color: var(--ink);
  font-size: 1.1rem;
  font-weight: 1000;
  line-height: 1;
}

.guide-control-list .search-icon {
  color: var(--ink);
}

.defaults-panel {
  display: grid;
  gap: 10px;
}

.defaults-panel[hidden] {
  display: none;
}

.defaults-actions {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.defaults-actions button {
  min-height: 42px;
  padding: 8px;
}

.dice-region-setting,
.assist-default-setting {
  align-items: center;
  background: var(--panel-soft);
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 10px;
  grid-template-columns: auto minmax(0, 1fr);
  padding: 10px;
}

.assist-default-setting {
  gap: 8px;
  grid-template-columns: auto;
  justify-items: start;
  padding: 8px;
}

.limits-setting {
  background: var(--panel-soft);
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 8px;
  padding: 8px;
}

.limits-setting-header {
  align-items: baseline;
  display: flex;
  gap: 8px;
  justify-content: space-between;
}

.limits-setting-header h3 {
  font-size: 0.76rem;
  margin: 0;
  text-transform: uppercase;
}

.limits-setting-header p,
.limits-note {
  color: var(--muted);
  font-size: 0.74rem;
  line-height: 1.35;
  margin: 0;
}

.limits-tiles {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.limit-tile {
  align-items: center;
  display: grid;
  gap: 5px;
  justify-items: center;
  min-height: 74px;
  padding: 8px 4px;
  text-align: center;
}

.limit-tile span:not(.limit-icon) {
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
}

.limit-tile strong {
  color: #ffe0a3;
  font-size: 0.68rem;
  font-weight: 1000;
  line-height: 1.1;
}

.limit-icon {
  display: inline-block;
  height: 20px;
  position: relative;
  width: 24px;
}

.limit-cloud::before {
  background:
    radial-gradient(circle at 35% 58%, var(--ink) 0 6px, transparent 6.5px),
    radial-gradient(circle at 54% 42%, var(--ink) 0 7px, transparent 7.5px),
    radial-gradient(circle at 70% 60%, var(--ink) 0 5px, transparent 5.5px);
  content: "";
  inset: 0;
  position: absolute;
}

.limit-eye::before,
.limit-eye::after {
  border: 2px solid var(--ink);
  border-radius: 999px;
  content: "";
  height: 10px;
  position: absolute;
  top: 6px;
  width: 9px;
}

.limit-eye::before {
  left: 1px;
}

.limit-eye::after {
  right: 1px;
}

.limit-eye {
  background:
    linear-gradient(var(--ink), var(--ink)) 50% 12px / 6px 2px no-repeat,
    linear-gradient(118deg, transparent 0 48%, var(--ink) 49% 55%, transparent 56%) 0 3px / 8px 7px no-repeat,
    linear-gradient(62deg, transparent 0 48%, var(--ink) 49% 55%, transparent 56%) 100% 3px / 8px 7px no-repeat;
}

.limit-wind::before,
.limit-wind::after {
  border-top: 2px solid var(--ink);
  border-radius: 999px;
  content: "";
  left: 2px;
  position: absolute;
}

.limit-wind::before {
  box-shadow: 5px 7px 0 -1px var(--ink);
  top: 5px;
  width: 20px;
}

.limit-wind::after {
  top: 13px;
  width: 13px;
}

.limits-panel {
  min-width: min(520px, calc(100vw - 24px));
}

.code-hunt-panel {
  max-width: 760px;
}

.code-hunt-grid {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.code-hunt-option {
  align-items: start;
  display: grid;
  gap: 4px;
  justify-items: start;
  min-height: 58px;
  padding: 8px;
  text-align: left;
}

.code-hunt-option strong {
  color: var(--ink);
  font-size: 0.86rem;
  font-weight: 900;
  line-height: 1;
}

.code-hunt-option span {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.2;
}

@media (max-width: 680px) {
  .code-hunt-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.limits-editor-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.limit-field {
  background: rgba(15, 26, 42, 0.72);
  border: 1px solid var(--line);
  border-radius: 8px;
  gap: 8px;
  padding: 8px;
}

.limit-field.limit-yellow {
  background: rgba(245, 197, 66, 0.08);
  border-color: rgba(245, 197, 66, 0.72);
}

.limit-field.limit-red {
  background: rgba(255, 92, 92, 0.09);
  border-color: rgba(255, 92, 92, 0.72);
}

.limit-field > span {
  gap: 6px;
  justify-content: flex-start;
}

.limit-field .limit-unit {
  color: var(--muted);
  font-size: 0.72rem;
  margin-left: auto;
}

.limit-ruler {
  border: 1px solid currentColor;
  border-radius: 3px;
  color: var(--gold);
  display: inline-block;
  flex: 0 0 auto;
  height: 14px;
  position: relative;
  transform: rotate(-8deg);
  width: 24px;
}

.limit-ruler::before {
  background: repeating-linear-gradient(90deg, currentColor 0 1px, transparent 1px 5px);
  content: "";
  inset: 2px 3px;
  position: absolute;
}

.limit-ruler-button {
  align-items: center;
  background: rgba(245, 197, 66, 0.1);
  border-color: rgba(245, 197, 66, 0.58);
  border-radius: 7px;
  height: 28px;
  justify-content: center;
  margin-left: 0;
  padding: 0;
  width: 34px;
}

.limit-ruler-button .limit-ruler {
  height: 13px;
  width: 23px;
}

.limit-ruler-button:hover,
.limit-ruler-button:focus-visible {
  box-shadow: 0 0 0 2px rgba(245, 197, 66, 0.22), 0 0 16px rgba(245, 197, 66, 0.32);
}

.assist-default-setting > .assist-default-icon {
  display: none;
}

.assist-default-toggle::before {
  content: "✦";
}

.assist-default-icon {
  align-items: center;
  background: rgba(245, 197, 66, 0.14);
  border: 1px solid rgba(245, 197, 66, 0.52);
  border-radius: 8px;
  color: var(--gold);
  display: inline-flex;
  font-size: 1rem;
  font-weight: 1000;
  height: 36px;
  justify-content: center;
  width: 36px;
}

.dice-region-icons {
  align-items: center;
  display: flex;
  gap: 7px;
}

.dice-region-icons .dice-icon {
  flex: 0 0 auto;
}

.dice-region-icons .code-hunt-icon {
  flex: 0 0 auto;
}

.dice-region-buttons {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.region-toggle,
.assist-default-toggle {
  align-items: center;
  display: inline-flex;
  gap: 8px;
  justify-content: center;
  min-height: 38px;
  padding: 8px;
}

.assist-default-toggle {
  font-size: 1rem;
  font-weight: 1000;
  gap: 0;
  height: 38px;
  min-width: 0;
  padding: 0;
  width: 38px;
}

.assist-default-toggle::before {
  content: "\2726";
}

.region-toggle[aria-pressed="true"],
.assist-default-toggle[aria-pressed="true"] {
  background: rgba(245, 197, 66, 0.18);
  border-color: rgba(245, 197, 66, 0.72);
  box-shadow: inset 0 0 0 1px rgba(245, 197, 66, 0.16);
  color: #ffe0a3;
}

.settings-button:hover,
.settings-button:focus-visible,
.search-button:hover,
.search-button:focus-visible {
  box-shadow: 0 0 0 2px rgba(245, 197, 66, 0.24), 0 0 18px rgba(245, 197, 66, 0.38);
}

.airfield-search-panel {
  display: grid;
  gap: 10px;
  z-index: 1120;
}

.airfield-search-panel[hidden] {
  display: none;
}

.search-helper {
  color: var(--muted);
  font-size: 0.78rem;
}

.airfield-search-results {
  display: grid;
  gap: 8px;
}

.airfield-result {
  align-items: center;
  background: var(--panel-soft);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  display: grid;
  gap: 2px;
  grid-template-columns: auto minmax(0, 1fr);
  justify-items: start;
  min-height: 54px;
  padding: 9px 10px;
  text-align: left;
  width: 100%;
}

.airfield-result:hover,
.airfield-result:focus-visible {
  border-color: rgba(245, 197, 66, 0.65);
  box-shadow: 0 0 0 2px rgba(245, 197, 66, 0.16), 0 0 16px rgba(245, 197, 66, 0.28);
}

.airfield-result-code {
  color: var(--ink);
  font-size: 1rem;
  font-weight: 1000;
  min-width: 58px;
}

.airfield-result-name {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  width: 100%;
}

.airfield-result-wx {
  display: flex;
  gap: 5px;
  grid-column: 2;
}

.wx-capability {
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.62rem;
  font-weight: 1000;
  padding: 2px 6px;
}

.wx-capability-on {
  background: rgba(46, 212, 122, 0.12);
  border-color: rgba(46, 212, 122, 0.5);
  color: #bff5d8;
}

.wx-capability-off {
  background: rgba(255, 95, 86, 0.1);
  border-color: rgba(255, 95, 86, 0.32);
  color: #c9a6a3;
  opacity: 0.66;
}

.airfield-result-history {
  border-color: rgba(74, 163, 255, 0.5);
}

.airfield-result-history::after {
  color: var(--blue);
  content: "Recent";
  font-size: 0.68rem;
  font-weight: 1000;
  grid-column: 1 / -1;
  text-transform: uppercase;
}

.search-empty {
  background: #090e16;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  margin: 0;
  padding: 12px;
}

.data-ribbon {
  align-items: center;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  font-size: 0.76rem;
  font-weight: 800;
  gap: 8px 14px;
  justify-content: space-between;
  margin-bottom: 12px;
  text-transform: uppercase;
}

.data-age {
  border-radius: 999px;
  display: inline-block;
  font-size: var(--status-pill-font-size);
  font-weight: var(--status-pill-font-weight);
  margin-left: 6px;
  padding: 3px 7px;
}

.age-green {
  background: rgba(46, 212, 122, 0.12);
  border: 1px solid rgba(46, 212, 122, 0.5);
  color: #bff5d8;
}

.age-yellow {
  background: rgba(243, 178, 60, 0.16);
  border: 1px solid var(--yellow);
  color: #ffe0a3;
}

.age-red {
  background: rgba(255, 95, 86, 0.18);
  border: 1px solid var(--red);
  color: #ffd5d2;
}

.mission-summary {
  background: var(--panel-soft);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  font-size: 0.76rem;
  font-weight: 800;
  margin-bottom: 12px;
  padding: 10px 8px;
  text-transform: uppercase;
}

.decision-banner,
.result-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 8px;
}

.result-card {
  padding-bottom: 6px;
}

.decision-banner {
  position: relative;
}

.card-disclosure > summary {
  align-items: center;
  column-gap: 8px;
  cursor: pointer;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  list-style: none;
  min-height: 0;
  padding-bottom: 0;
  padding-right: 62px;
  position: relative;
  row-gap: 6px;
}

.card-disclosure > summary::-webkit-details-marker {
  display: none;
}

.card-disclosure > summary::after {
  content: "";
}

.card-disclosure[open] > summary::after {
  content: "";
}

.card-disclosure > summary:hover,
.card-disclosure > summary:focus-visible {
  outline: none;
}

.card-disclosure > summary:active {
  outline: none;
}

.result-card {
  transition: background 160ms ease, box-shadow 160ms ease, transform 120ms ease;
}

.result-card:has(.card-disclosure > summary:hover),
.result-card:has(.card-disclosure > summary:focus-visible) {
  background: rgba(74, 163, 255, 0.04);
  box-shadow: 0 0 0 1px rgba(74, 163, 255, 0.18), 0 0 22px rgba(74, 163, 255, 0.12);
}

.result-card:has(.card-disclosure > summary:active) {
  background: rgba(74, 163, 255, 0.08);
  transform: scale(0.997);
}

.result-card.status-green:has(.card-disclosure > summary:hover),
.result-card.status-green:has(.card-disclosure > summary:focus-visible) {
  background: rgba(46, 212, 122, 0.05);
  box-shadow: 0 0 0 1px rgba(46, 212, 122, 0.22), 0 0 22px rgba(46, 212, 122, 0.14);
}

.result-card.status-green:has(.card-disclosure > summary:active) {
  background: rgba(46, 212, 122, 0.09);
}

.result-card.status-yellow:has(.card-disclosure > summary:hover),
.result-card.status-yellow:has(.card-disclosure > summary:focus-visible) {
  background: rgba(243, 178, 60, 0.06);
  box-shadow: 0 0 0 1px rgba(243, 178, 60, 0.24), 0 0 22px rgba(243, 178, 60, 0.16);
}

.result-card.status-yellow:has(.card-disclosure > summary:active) {
  background: rgba(243, 178, 60, 0.1);
}

.result-card.status-red:has(.card-disclosure > summary:hover),
.result-card.status-red:has(.card-disclosure > summary:focus-visible) {
  background: rgba(255, 95, 86, 0.06);
  box-shadow: 0 0 0 1px rgba(255, 95, 86, 0.24), 0 0 22px rgba(255, 95, 86, 0.16);
}

.result-card.status-red:has(.card-disclosure > summary:active) {
  background: rgba(255, 95, 86, 0.1);
}

.card-disclosure .card-actions {
  align-items: center;
  bottom: 4px;
  display: inline-flex;
  gap: 0;
  justify-content: flex-end;
  position: absolute;
  right: 0;
  width: 48px;
}

.assist-toggle,
.expand-toggle {
  align-items: center;
  align-self: center;
  background: transparent;
  border: 0;
  border-radius: 0;
  color: var(--gold);
  display: inline-flex;
  font-size: 1.35rem;
  font-weight: 900;
  height: 28px;
  justify-content: center;
  justify-self: end;
  margin-top: 0;
  position: static;
  right: 0;
  width: 28px;
}

.assist-toggle {
  border: 1px solid rgba(245, 197, 66, 0.42);
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.9rem;
  height: 28px;
  line-height: 1;
  min-height: 0;
  min-width: 0;
  margin-right: 18px;
  padding: 0;
  transition: background 140ms ease, border-color 140ms ease, color 140ms ease, box-shadow 140ms ease, transform 120ms ease;
  width: 28px;
}

.expand-toggle {
  align-items: flex-end;
  bottom: -5px;
  height: 24px;
  justify-content: flex-end;
  position: absolute;
  right: -2px;
  width: 18px;
}

.assist-toggle.active {
  background: rgba(245, 197, 66, 0.16);
  border-color: rgba(245, 197, 66, 0.72);
  box-shadow: 0 0 12px rgba(245, 197, 66, 0.18);
}

.assist-toggle:not(.active) {
  color: var(--muted);
  opacity: 0.62;
}

.assist-toggle.assist-locked {
  color: var(--muted);
  opacity: 0.58;
  position: relative;
}

.assist-toggle.assist-locked::before {
  border: 2px solid var(--red);
  border-radius: 999px;
  content: "";
  height: 20px;
  left: 50%;
  opacity: 0.95;
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 20px;
}

.assist-toggle.assist-locked::after {
  background: var(--red);
  border-radius: 999px;
  content: "";
  height: 2px;
  left: 50%;
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%) rotate(-45deg);
  width: 22px;
}

.assist-toggle.assist-locked:disabled {
  cursor: not-allowed;
}

.assist-toggle:hover,
.assist-toggle:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px rgba(245, 197, 66, 0.18), 0 0 16px rgba(245, 197, 66, 0.2);
}

.assist-toggle:active {
  transform: scale(0.94);
}

.expand-toggle::before {
  content: "+";
}

.card-disclosure[open] .expand-toggle::before {
  content: "-";
}

.card-expanded {
  border-top: 1px solid var(--line);
  margin-top: 10px;
  padding-bottom: 38px;
  padding-top: 10px;
  position: relative;
}

.card-nav-buttons {
  align-items: center;
  bottom: 2px;
  display: inline-flex;
  gap: 6px;
  position: absolute;
  right: 0;
}

.card-nav-button {
  align-items: center;
  background: rgba(15, 26, 42, 0.92);
  border: 1px solid rgba(245, 197, 66, 0.5);
  border-radius: 8px;
  color: var(--gold);
  display: inline-flex;
  height: 28px;
  justify-content: center;
  min-height: 0;
  padding: 0;
  transition: background 140ms ease, border-color 140ms ease, box-shadow 140ms ease, transform 120ms ease;
  width: 28px;
}

.card-nav-button:hover,
.card-nav-button:focus-visible {
  box-shadow: 0 0 0 2px rgba(245, 197, 66, 0.18), 0 0 16px rgba(245, 197, 66, 0.2);
  outline: none;
}

.card-nav-button:active {
  transform: translateY(1px) scale(0.96);
}

.home-icon {
  display: inline-block;
  height: 16px;
  position: relative;
  width: 17px;
}

.home-icon::before {
  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-bottom: 8px solid currentColor;
  content: "";
  left: 0;
  position: absolute;
  top: 0;
}

.home-icon::after {
  background: currentColor;
  border-radius: 2px 2px 1px 1px;
  bottom: 0;
  content: "";
  height: 9px;
  left: 3px;
  position: absolute;
  width: 11px;
}

.pencil-icon {
  display: inline-block;
  height: 17px;
  position: relative;
  transform: rotate(-35deg);
  width: 17px;
}

.pencil-icon::before {
  background: currentColor;
  border-radius: 2px;
  content: "";
  height: 13px;
  left: 7px;
  position: absolute;
  top: 1px;
  width: 4px;
}

.pencil-icon::after {
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid currentColor;
  content: "";
  left: 5px;
  position: absolute;
  top: 13px;
}

.decision-banner {
  margin-bottom: 14px;
}

.jump-hint {
  color: #b8dcff;
  font-size: 0.84rem;
  font-weight: 800;
  margin-bottom: 0;
}

.control-strip {
  align-items: center;
  display: grid;
  gap: 8px;
  grid-template-columns: 1fr auto;
  margin-bottom: 14px;
}

.filter-bar {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.results-toolbar .card-actions {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(2, 44px);
}

.compact-action {
  align-items: center;
  display: inline-flex;
  font-size: 1.35rem;
  height: 40px;
  justify-content: center;
  line-height: 1;
  min-height: 40px;
  padding: 0;
  width: 40px;
}

.compact-action span {
  display: block;
  height: 16px;
  pointer-events: none;
  position: relative;
  width: 16px;
}

.compact-action span::before,
.compact-action span::after {
  background: currentColor;
  border-radius: 999px;
  content: "";
  height: 3px;
  left: 50%;
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 14px;
}

.compact-plus span::after {
  transform: translate(-50%, -50%) rotate(90deg);
}

.compact-minus span::after {
  display: none;
}

.filter-button {
  align-items: center;
  background: var(--panel-soft);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  display: inline-flex;
  gap: 4px;
  justify-content: center;
  line-height: 1;
  min-height: 40px;
  padding: 8px;
}

.filter-button span {
  display: inline-flex;
  font-weight: 900;
  line-height: 1;
  pointer-events: none;
}

.filter-button.active {
  border-color: var(--blue);
  color: var(--ink);
}

.filter-button:hover,
.filter-button:focus-visible {
  box-shadow: 0 0 0 2px rgba(74, 163, 255, 0.22), 0 0 20px rgba(74, 163, 255, 0.42);
}

.filter-button:active {
  box-shadow: 0 0 0 3px rgba(74, 163, 255, 0.34), 0 0 26px rgba(74, 163, 255, 0.62);
}

.filter-red.active {
  background: var(--red);
  border-color: var(--red);
  color: #140403;
}

.filter-red:hover,
.filter-red:focus-visible,
.filter-red.tap-glow {
  box-shadow: 0 0 0 2px rgba(255, 95, 86, 0.26), 0 0 22px rgba(255, 95, 86, 0.56);
}

.filter-yellow.active {
  background: var(--yellow);
  border-color: var(--yellow);
  color: #170f04;
}

.filter-yellow:hover,
.filter-yellow:focus-visible,
.filter-yellow.tap-glow {
  box-shadow: 0 0 0 2px rgba(243, 178, 60, 0.26), 0 0 22px rgba(243, 178, 60, 0.56);
}

.filter-green.active {
  background: var(--green);
  border-color: var(--green);
  color: #07100b;
}

.filter-green:hover,
.filter-green:focus-visible,
.filter-green.tap-glow {
  box-shadow: 0 0 0 2px rgba(46, 212, 122, 0.26), 0 0 22px rgba(46, 212, 122, 0.56);
}

@media (hover: none) {
  button:not(.tap-glow):hover,
  button:not(.tap-glow):focus,
  button:not(.tap-glow):focus-visible {
    box-shadow: none;
    filter: none;
    outline: none;
  }

  .filter-button:not(.tap-glow):hover,
  .filter-button:not(.tap-glow):focus,
  .filter-button:not(.tap-glow):focus-visible,
  .compact-action:not(.tap-glow):hover,
  .compact-action:not(.tap-glow):focus,
  .compact-action:not(.tap-glow):focus-visible {
    box-shadow: none;
  }

  .brand-fire-button:not(.tap-glow):hover,
  .brand-fire-button:not(.tap-glow):focus,
  .brand-fire-button:not(.tap-glow):focus-visible {
    filter: none;
  }
}

.tap-glow {
  animation: tapPulse 420ms ease;
}

@keyframes tapPulse {
  0% {
    transform: scale(0.98);
  }
  45% {
    box-shadow: 0 0 0 4px rgba(245, 197, 66, 0.38), 0 0 30px rgba(245, 197, 66, 0.72);
    transform: scale(1.015);
  }
  100% {
    box-shadow: none;
    transform: scale(1);
  }
}

@keyframes buttonSpin {
  to {
    --spin-angle: 360deg;
  }
}

@keyframes diceRoll {
  0% {
    transform: rotate(0deg) scale(1);
  }
  45% {
    transform: rotate(190deg) scale(1.08);
  }
  100% {
    transform: rotate(360deg) scale(1);
  }
}

@keyframes diceSettle {
  0% {
    transform: rotate(-18deg) scale(1.12);
  }
  45% {
    transform: rotate(10deg) scale(0.94);
  }
  72% {
    transform: rotate(-4deg) scale(1.04);
  }
  100% {
    transform: rotate(0deg) scale(1);
  }
}

@keyframes codeHuntSpin {
  0% {
    transform: rotate(0deg) scale(1);
  }
  45% {
    transform: rotate(190deg) scale(1.08);
  }
  100% {
    transform: rotate(360deg) scale(1);
  }
}

@keyframes codeHuntSettle {
  0% {
    transform: rotate(-16deg) scale(1.14);
  }
  45% {
    transform: rotate(9deg) scale(0.95);
  }
  72% {
    transform: rotate(-4deg) scale(1.04);
  }
  100% {
    transform: rotate(0deg) scale(1);
  }
}

@keyframes riskDiceFire {
  from {
    opacity: 0.68;
    transform: translate(-50%, -50%) scale(0.9) rotate(-3deg);
  }

  to {
    opacity: 0.95;
    transform: translate(-50%, -56%) scale(1.08) rotate(3deg);
  }
}

@keyframes riskDiceEmbers {
  from {
    opacity: 0.9;
    transform: translate(-50%, -50%) translateY(4px) scale(0.9);
  }

  to {
    opacity: 0.25;
    transform: translate(-50%, -50%) translateY(-10px) scale(1.16);
  }
}

@keyframes riskDiceHeat {
  from {
    filter: drop-shadow(0 0 7px rgba(255, 95, 86, 0.48));
    transform: rotate(-3deg) scale(1);
  }

  to {
    filter: drop-shadow(0 0 14px rgba(245, 197, 66, 0.72));
    transform: rotate(3deg) scale(1.05);
  }
}

@keyframes riskDiceFadeOut {
  from {
    opacity: 0.85;
    transform: translate(-50%, -54%) scale(1);
  }

  to {
    opacity: 0;
    transform: translate(-50%, -62%) scale(0.62);
  }
}

@keyframes riskDiceIconFadeOut {
  from {
    filter: drop-shadow(0 0 14px rgba(245, 197, 66, 0.66));
    transform: rotate(2deg) scale(1.04);
  }

  to {
    filter: drop-shadow(0 0 0 rgba(255, 95, 86, 0));
    transform: rotate(0deg) scale(1);
  }
}

@keyframes logoCharge {
  0% {
    box-shadow: 0 0 0 rgba(245, 197, 66, 0);
    filter: brightness(0.78) saturate(0.9);
    transform: scale(0.965);
  }
  42% {
    box-shadow: 0 0 0 2px rgba(245, 197, 66, 0.18), 0 0 16px rgba(245, 197, 66, 0.36);
    filter: brightness(1.08) saturate(1.08);
    transform: scale(1.018);
  }
  76% {
    box-shadow: 0 0 0 4px rgba(245, 197, 66, 0.28), 0 0 34px rgba(245, 197, 66, 0.72), 0 0 54px rgba(255, 255, 255, 0.22);
    filter: brightness(1.34) saturate(1.24);
    transform: scale(1.052);
  }
  82% {
    box-shadow: 0 0 0 5px rgba(245, 197, 66, 0.32), 0 0 38px rgba(245, 197, 66, 0.78);
    filter: brightness(1.42) saturate(1.3);
    transform: translateX(0) scale(1.058);
  }
  88% {
    box-shadow: 0 0 0 2px rgba(245, 197, 66, 0.22), 0 0 20px rgba(245, 197, 66, 0.48);
    filter: brightness(1.12) saturate(1.12);
    transform: translateX(-5px) rotate(-1.2deg) scale(0.992);
  }
  94% {
    transform: translateX(2px) rotate(0.45deg) scale(1.01);
  }
  100% {
    box-shadow: 0 0 0 1px rgba(245, 197, 66, 0.16), 0 0 10px rgba(245, 197, 66, 0.24);
    filter: brightness(1);
    transform: scale(1);
  }
}

@keyframes chargeRing {
  0% {
    opacity: 0;
    transform: scale(0.78);
  }
  38% {
    opacity: 0.62;
    transform: scale(0.96);
  }
  78% {
    opacity: 1;
    transform: scale(1.13);
  }
  100% {
    opacity: 0;
    transform: scale(1.34);
  }
}

@keyframes muzzleFlash {
  0% {
    opacity: 0;
    transform: scale(0.4) translateX(-2px);
  }
  35% {
    opacity: 1;
    transform: scale(1.85) translateX(1px);
  }
  100% {
    opacity: 0;
    transform: scale(0.24) translateX(12px);
  }
}

@keyframes boltFireRecoil {
  0% {
    filter: drop-shadow(0 0 2px rgba(201, 159, 53, 0.18));
    transform: skewX(-4deg) scale(1);
  }
  26% {
    filter: drop-shadow(0 0 7px rgba(245, 197, 66, 0.58));
    transform: skewX(-4deg) scale(1.08) rotate(-2deg);
  }
  44% {
    filter: drop-shadow(0 0 11px rgba(255, 245, 188, 0.72));
    transform: translateX(-1px) skewX(-8deg) scale(1.16) rotate(3deg);
  }
  51% {
    transform: translateX(2px) skewX(2deg) scale(0.94) rotate(-5deg);
  }
  60% {
    transform: translateX(-1px) skewX(-6deg) scale(1.03) rotate(2deg);
  }
  76% {
    filter: drop-shadow(0 0 5px rgba(201, 159, 53, 0.38));
    transform: translateX(0) skewX(-4deg) scale(1) rotate(0deg);
  }
  100% {
    filter: drop-shadow(0 0 3px rgba(201, 159, 53, 0.28));
    transform: skewX(-4deg) scale(1);
  }
}

@keyframes tracerShot {
  0% {
    opacity: 0;
    transform: translateX(calc(-1 * var(--tracer-travel))) scaleX(0.38) skewX(-6deg);
  }
  6% {
    opacity: 1;
    transform: translateX(calc(-0.94 * var(--tracer-travel))) scaleX(0.55) skewX(-6deg);
  }
  96% {
    opacity: 1;
    transform: translateX(0) scaleX(1) skewX(-6deg);
  }
  100% {
    opacity: 0;
    transform: translateX(0) scaleX(0.62) skewX(-6deg);
  }
}

@keyframes bulletShatter {
  0% {
    opacity: 1;
    transform: translateX(0) scaleX(0.58) scaleY(1.24) rotate(5deg);
    box-shadow:
      -1px 0 0 1px rgba(255, 255, 255, 0.96),
      2px -1px 0 0 rgba(245, 197, 66, 0.92),
      5px 1px 0 -1px rgba(255, 236, 155, 0.86),
      8px -2px 0 -1px rgba(245, 197, 66, 0.7),
      9px 3px 0 -1px rgba(255, 255, 255, 0.62),
      0 0 10px 1px rgba(255, 246, 204, 0.48),
      0 0 18px 2px rgba(245, 197, 66, 0.38);
  }
  62% {
    opacity: 1;
    transform: translateX(8px) scale(0.72) rotate(18deg);
    box-shadow:
      2px -4px 0 -2px rgba(255, 255, 255, 0.86),
      5px 5px 0 -2px rgba(151, 93, 28, 0.9),
      13px -7px 0 -2px rgba(255, 236, 160, 0.78),
      20px 3px 0 -2px rgba(184, 121, 33, 0.78),
      30px -2px 0 -2px rgba(255, 249, 215, 0.62),
      12px 9px 0 -2px rgba(245, 197, 66, 0.58),
      39px 6px 0 -3px rgba(255, 255, 255, 0.4);
  }
  100% {
    opacity: 0;
    transform: translateX(16px) scale(0.28) rotate(34deg);
    box-shadow:
      6px -7px 0 -4px rgba(255, 255, 255, 0),
      12px 10px 0 -4px rgba(151, 93, 28, 0),
      24px -13px 0 -4px rgba(255, 236, 160, 0),
      40px 8px 0 -4px rgba(184, 121, 33, 0),
      58px -4px 0 -4px rgba(255, 249, 215, 0),
      24px 18px 0 -4px rgba(245, 197, 66, 0),
      72px 13px 0 -5px rgba(255, 255, 255, 0);
  }
}

.decision-banner h2 {
  font-size: 1.25rem;
  line-height: 1.18;
  margin-bottom: 8px;
}

.alternate-required {
  color: var(--ink);
  font-weight: 800;
  margin-bottom: 8px;
}

.assist-off-pill {
  align-items: center;
  background: rgba(185, 194, 207, 0.08);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  display: inline-flex;
  font-size: 0.76rem;
  font-weight: 800;
  line-height: 1;
  margin-left: 8px;
  padding: 6px 10px;
  text-transform: uppercase;
  vertical-align: middle;
}

.limits-mode-pill {
  align-items: center;
  background: rgba(185, 194, 207, 0.08);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  cursor: pointer;
  display: inline-flex;
  font-size: 0.76rem;
  font-weight: 800;
  font-family: inherit;
  line-height: 1;
  margin-left: 8px;
  min-height: 0;
  padding: 6px 10px;
  text-transform: uppercase;
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 120ms ease;
  vertical-align: middle;
}

.limits-mode-pill.custom {
  background: rgba(74, 163, 255, 0.12);
  border-color: rgba(74, 163, 255, 0.52);
  color: #cfe7ff;
}

.limits-mode-pill:hover,
.limits-mode-pill:focus-visible {
  box-shadow: 0 0 0 2px rgba(185, 194, 207, 0.16), 0 0 14px rgba(185, 194, 207, 0.24);
  outline: none;
}

.limits-mode-pill.custom:hover,
.limits-mode-pill.custom:focus-visible {
  box-shadow: 0 0 0 2px rgba(74, 163, 255, 0.2), 0 0 14px rgba(74, 163, 255, 0.3);
}

.limits-mode-pill:active {
  transform: translateY(1px) scale(0.98);
}

.summary-issues {
  display: grid;
  gap: 10px;
  padding-right: 34px;
}

.summary-issue {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  column-gap: 8px;
  row-gap: 6px;
}

.summary-issue .issue-chip {
  font-size: 0.76rem;
  font-weight: 800;
  padding: 6px 10px;
}

.summary-icao {
  color: var(--muted);
  display: inline-block;
  font-size: 1.32rem;
  font-weight: 700;
  line-height: 1.2;
  margin: 0;
}

.summary-icao[role="button"] {
  cursor: pointer;
  transform: translateY(0);
  transition: color 160ms ease, text-shadow 160ms ease, transform 120ms ease;
  -webkit-tap-highlight-color: transparent;
}

@media (hover: hover) {
  .summary-icao[role="button"]:hover,
  .summary-icao[role="button"]:focus-visible {
    color: var(--muted);
    outline: none;
    text-shadow: 0 0 14px rgba(245, 197, 66, 0.3);
  }
}

.summary-icao[role="button"]:active {
  transform: scale(0.98);
}

.summary-assist-toggle {
  bottom: 8px;
  margin-right: 0;
  position: absolute;
  right: 8px;
}

.decision-banner .summary-assist-toggle,
.decision-banner .summary-assist-toggle.assist-locked {
  bottom: 8px;
  margin: 0;
  position: absolute;
  right: 8px;
}

.decision-banner.assist-off .summary-issue .issue-chip {
  pointer-events: none;
  visibility: hidden;
}

.decision-banner.assist-off .summary-issue .issue-chip.hunt-chip {
  pointer-events: auto;
  visibility: visible;
}

.decision-banner.assist-off {
  border-color: var(--line);
}

.results-panel:has(.decision-banner.assist-off) .filter-button span {
  display: none;
}

.decision-reason,
.reason,
.airport-name,
.raw-line,
.metar-block p,
.notam-block li {
  color: var(--muted);
  line-height: 1.45;
}

.cards {
  display: grid;
  gap: 12px;
}

.empty-filter {
  background: var(--panel-soft);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  margin: 0;
  padding: 14px;
}

.card-header {
  align-items: start;
  display: flex;
  gap: 10px;
  grid-column: 1 / -1;
  justify-content: space-between;
}

.card-main {
  min-width: 0;
}

.airport-row {
  align-items: baseline;
  column-gap: 8px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
}

.airport-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.card-meta {
  align-self: start;
  justify-self: center;
  min-width: 190px;
}

.card-status {
  align-items: flex-start;
  align-self: start;
  display: flex;
  justify-content: flex-end;
  position: absolute;
  right: 0;
  top: 0;
  width: 86px;
}

.card-header h3 {
  color: var(--muted);
  display: inline-block;
  font-size: 1.32rem;
  font-weight: 700;
  line-height: 1.2;
  margin: 0;
  margin-bottom: 0;
}

.evaluated-at {
  align-items: center;
  color: var(--muted);
  display: flex;
  font-size: 0.76rem;
  font-weight: 800;
  gap: 5px;
  margin-bottom: 0;
  text-transform: uppercase;
  white-space: nowrap;
}

.eval-delta-pill {
  border: 1px solid var(--line);
  border-radius: 999px;
  display: inline-flex;
  flex: 0 0 auto;
  font-size: 0.68rem;
  font-weight: 1000;
  height: var(--status-pill-height);
  align-items: center;
  line-height: 1;
  padding: 3px 7px;
}

.eval-delta-future {
  background: rgba(46, 212, 122, 0.12);
  border-color: rgba(46, 212, 122, 0.58);
  color: #bff5d8;
}

.eval-delta-past {
  background: rgba(255, 95, 86, 0.18);
  border-color: rgba(255, 95, 86, 0.72);
  color: #ffd5d2;
}

.source-labels {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 800;
  margin-bottom: 0;
  text-transform: uppercase;
}

.wx-failed {
  color: #ffe0a3;
  font-weight: 1000;
}

.issue-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 2px 0 0;
  min-width: 0;
}

.issue-chip {
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 800;
  padding: 6px 10px;
}

.issue-chip[role="button"] {
  cursor: pointer;
}

.issue-chip[role="button"]:hover,
.issue-chip[role="button"]:focus-visible {
  outline: none;
}

.issue-chip[role="button"]:active {
  transform: scale(0.96);
}

.result-card.assist-off .assist-chip {
  display: none;
}

.result-card.assist-off {
  border-color: var(--line);
}

.result-card.assist-off:has(.card-disclosure > summary:hover),
.result-card.assist-off:has(.card-disclosure > summary:focus-visible) {
  background: rgba(185, 194, 207, 0.035);
  box-shadow: 0 0 0 1px rgba(185, 194, 207, 0.14), 0 0 18px rgba(185, 194, 207, 0.1);
}

.result-card.assist-off:has(.card-disclosure > summary:active) {
  background: rgba(185, 194, 207, 0.06);
  box-shadow: 0 0 0 1px rgba(185, 194, 207, 0.14), 0 0 18px rgba(185, 194, 207, 0.1);
  transform: scale(0.997);
}

.result-card.assist-off .status-pill {
  display: none;
}

.result-card.assist-off .taf-decode-row.taf-applicable summary,
.result-card.assist-off .taf-decode-row.taf-window summary,
.result-card.assist-off .taf-decode-row.taf-status-green summary,
.result-card.assist-off .taf-decode-row.taf-status-yellow summary,
.result-card.assist-off .taf-decode-row.taf-status-red summary {
  background: transparent;
  border-color: transparent;
}

.result-card.assist-off .taf-markers {
  display: none;
}

.chip-red[role="button"]:hover,
.chip-red[role="button"]:focus-visible {
  box-shadow: 0 0 0 2px rgba(255, 95, 86, 0.26), 0 0 18px rgba(255, 95, 86, 0.34);
}

.chip-yellow[role="button"]:hover,
.chip-yellow[role="button"]:focus-visible {
  box-shadow: 0 0 0 2px rgba(243, 178, 60, 0.26), 0 0 18px rgba(243, 178, 60, 0.34);
}

.chip-green[role="button"]:hover,
.chip-green[role="button"]:focus-visible {
  box-shadow: 0 0 0 2px rgba(46, 212, 122, 0.26), 0 0 18px rgba(46, 212, 122, 0.34);
}

.chip-blue[role="button"]:hover,
.chip-blue[role="button"]:focus-visible {
  box-shadow: 0 0 0 2px rgba(74, 163, 255, 0.26), 0 0 18px rgba(74, 163, 255, 0.34);
}

.chip-red {
  background: rgba(255, 95, 86, 0.18);
  border: 1px solid var(--red);
  color: #ffd5d2;
}

.chip-yellow {
  background: rgba(243, 178, 60, 0.16);
  border: 1px solid var(--yellow);
  color: #ffe0a3;
}

.chip-green {
  background: rgba(46, 212, 122, 0.12);
  border: 1px solid rgba(46, 212, 122, 0.5);
  color: #bff5d8;
}

.chip-blue {
  background: rgba(74, 163, 255, 0.14);
  border: 1px solid rgba(74, 163, 255, 0.62);
  color: #cfe8ff;
}

.hunt-search-token {
  border-radius: 4px;
  box-shadow: inset 0 0 0 1px rgba(74, 163, 255, 0.5);
  color: #dff0ff;
  padding: 0 2px;
}

.hunt-token-focus {
  animation: huntTokenFocus 1.8s ease-out both;
}

.status-pill {
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--ink);
  font-size: 0.78rem;
  font-weight: 900;
  padding: 6px 10px;
  text-transform: uppercase;
}

.status-green {
  border-color: #2c8f5d;
}

.status-green .status-pill {
  background: rgba(46, 212, 122, 0.12);
  border-color: rgba(46, 212, 122, 0.5);
  color: #bff5d8;
}

.status-yellow {
  border-color: #a96f16;
}

.status-yellow .status-pill {
  background: rgba(243, 178, 60, 0.16);
  border-color: var(--yellow);
  color: #ffe0a3;
}

.status-red {
  border-color: #a8403a;
}

.status-red .status-pill {
  background: rgba(255, 95, 86, 0.18);
  border-color: var(--red);
  color: #ffd5d2;
}

.scroll-focus {
  box-shadow: 0 0 0 3px rgba(46, 212, 122, 0.76);
}

.scroll-focus-red {
  box-shadow: 0 0 0 3px rgba(255, 95, 86, 0.82), 0 0 24px rgba(255, 95, 86, 0.34);
}

.scroll-focus-yellow {
  box-shadow: 0 0 0 3px rgba(243, 178, 60, 0.82), 0 0 24px rgba(243, 178, 60, 0.34);
}

.scroll-focus-green {
  box-shadow: 0 0 0 3px rgba(46, 212, 122, 0.82), 0 0 24px rgba(46, 212, 122, 0.34);
}

@keyframes huntTokenFocus {
  0% {
    background: rgba(74, 163, 255, 0.42);
    box-shadow: inset 0 0 0 1px rgba(74, 163, 255, 0.95), 0 0 0 0 rgba(74, 163, 255, 0.0);
  }

  18% {
    background: rgba(74, 163, 255, 0.5);
    box-shadow: inset 0 0 0 1px rgba(74, 163, 255, 1), 0 0 18px rgba(74, 163, 255, 0.55);
  }

  100% {
    background: transparent;
    box-shadow: inset 0 0 0 1px rgba(74, 163, 255, 0.5);
  }
}

.taf-decode-row.taf-applicable.source-focus.source-focus-red summary,
.taf-decode-row.taf-window.source-focus.source-focus-red summary {
  box-shadow: 0 0 14px rgba(255, 95, 86, 0.42);
}

.taf-decode-row.taf-applicable.source-focus.source-focus-yellow summary,
.taf-decode-row.taf-window.source-focus.source-focus-yellow summary {
  box-shadow: 0 0 14px rgba(243, 178, 60, 0.38);
}

.taf-decode-row.taf-applicable.source-focus.source-focus-green summary,
.taf-decode-row.taf-window.source-focus.source-focus-green summary {
  box-shadow: 0 0 14px rgba(46, 212, 122, 0.38);
}

.notam-item {
  border-radius: 6px;
  margin: 4px 0;
  padding: 4px 6px;
}

.notam-closed {
  background: rgba(255, 95, 86, 0.18);
  border: 1px solid var(--red);
  color: #ffd5d2;
  font-weight: 900;
}

.notam-limiting {
  background: rgba(243, 178, 60, 0.14);
  border: 1px solid rgba(243, 178, 60, 0.45);
}

.notam-unavailable {
  background: rgba(243, 178, 60, 0.12);
  border: 1px solid rgba(243, 178, 60, 0.36);
  border-radius: 6px;
  color: #ffe0a3;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 0.86rem;
  font-weight: 900;
  line-height: 1.55;
  margin: 0;
  padding: 6px 8px;
}

.notam-list {
  margin: 0;
  padding-left: 18px;
}

.wx-grid {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(3, 1fr);
  margin: 12px 0;
}

.wx-grid div {
  background: var(--panel-soft);
  border: 1px solid rgba(245, 197, 66, 0.12);
  border-radius: 8px;
  padding: 10px;
}

.wx-source-tile {
  cursor: pointer;
  transition: border-color 140ms ease, box-shadow 140ms ease, transform 120ms ease;
}

.wx-source-tile:hover,
.wx-source-tile:focus-visible {
  box-shadow: 0 0 0 2px rgba(74, 163, 255, 0.18), 0 0 18px rgba(74, 163, 255, 0.18);
  outline: none;
}

.wx-source-tile:active {
  transform: scale(0.99);
}

.wx-source-tile.impact-red:hover,
.wx-source-tile.impact-red:focus-visible {
  box-shadow: 0 0 0 2px rgba(255, 95, 86, 0.28), 0 0 18px rgba(255, 95, 86, 0.26);
}

.wx-source-tile.impact-yellow:hover,
.wx-source-tile.impact-yellow:focus-visible {
  box-shadow: 0 0 0 2px rgba(243, 178, 60, 0.28), 0 0 18px rgba(243, 178, 60, 0.24);
}

.wx-source-tile.impact-green:hover,
.wx-source-tile.impact-green:focus-visible {
  box-shadow: 0 0 0 2px rgba(46, 212, 122, 0.24), 0 0 18px rgba(46, 212, 122, 0.22);
}

.wx-grid .impact-green {
  background: rgba(46, 212, 122, 0.12);
  border-color: rgba(46, 212, 122, 0.5);
}

.wx-grid .impact-yellow {
  background: rgba(243, 178, 60, 0.16);
  border-color: var(--yellow);
}

.wx-grid .impact-red {
  background: rgba(255, 95, 86, 0.18);
  border-color: var(--red);
}

.result-card.assist-off .wx-grid .impact-green,
.result-card.assist-off .wx-grid .impact-yellow,
.result-card.assist-off .wx-grid .impact-red {
  background: var(--panel-soft);
  border-color: rgba(245, 197, 66, 0.12);
}

.result-card.assist-off .wx-source-tile {
  cursor: default;
}

.result-card.assist-off .wx-source-tile:hover,
.result-card.assist-off .wx-source-tile:focus-visible,
.result-card.assist-off .wx-source-tile.impact-green:hover,
.result-card.assist-off .wx-source-tile.impact-green:focus-visible,
.result-card.assist-off .wx-source-tile.impact-yellow:hover,
.result-card.assist-off .wx-source-tile.impact-yellow:focus-visible,
.result-card.assist-off .wx-source-tile.impact-red:hover,
.result-card.assist-off .wx-source-tile.impact-red:focus-visible {
  box-shadow: 0 0 0 1px rgba(185, 194, 207, 0.14), 0 0 14px rgba(185, 194, 207, 0.08);
}

.result-card.assist-off .wx-source-tile:active {
  transform: none;
}

.result-card.assist-off .wx-source-tile dd {
  visibility: hidden;
}

h3.impact-red {
  background: rgba(255, 95, 86, 0.18);
  border: 1px solid var(--red);
  border-radius: 6px;
  color: #ffd5d2;
  display: inline-block;
  padding: 2px 8px;
}

dt {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 800;
  margin-bottom: 2px;
  text-transform: uppercase;
}

dd {
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 0.86rem;
  font-weight: 800;
  line-height: 1.55;
  margin: 0;
}

.raw-line,
.taf-line {
  background: #080d14;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 0.86rem;
  line-height: 1.55;
  padding: 10px 0;
  white-space: normal;
  word-break: break-word;
}

.metar-block,
.taf-block,
.notam-block {
  margin-top: 12px;
}

.metar-title,
.taf-title {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.metar-title .data-age,
.taf-title .data-age,
.taf-eval-time {
  align-items: center;
  box-sizing: border-box;
  display: inline-flex;
  font-size: var(--status-pill-font-size);
  font-weight: var(--status-pill-font-weight);
  height: var(--status-pill-height);
  line-height: 1;
  margin-left: 0;
  padding: 3px 7px;
}

.metar-title .data-age,
.taf-title .data-age {
  justify-content: center;
  min-width: 52px;
}

.taf-eval-time {
  background: rgba(74, 163, 255, 0.12);
  border: 1px solid rgba(74, 163, 255, 0.42);
  border-radius: 999px;
  color: #b8dcff;
  cursor: pointer;
  transform: translateY(0);
  transition: box-shadow 160ms ease, transform 120ms ease, filter 160ms ease, background 160ms ease;
  -webkit-tap-highlight-color: transparent;
}

.taf-eval-found {
  background: rgba(46, 212, 122, 0.12);
  border-color: rgba(46, 212, 122, 0.58);
  color: #bff5d8;
}

.taf-eval-missing {
  background: rgba(255, 95, 86, 0.18);
  border-color: rgba(255, 95, 86, 0.72);
  color: #ffd5d2;
}

.taf-eval-time:focus-visible,
.taf-age[role="button"]:focus-visible,
.metar-age[role="button"]:focus-visible {
  box-shadow: 0 0 0 2px rgba(74, 163, 255, 0.2), 0 0 14px rgba(74, 163, 255, 0.26);
  outline: none;
}

@media (hover: hover) {
  .taf-eval-time:hover,
  .taf-age[role="button"]:hover,
  .metar-age[role="button"]:hover {
    box-shadow: 0 0 0 2px rgba(74, 163, 255, 0.2), 0 0 14px rgba(74, 163, 255, 0.26);
    outline: none;
  }
}

.taf-age[role="button"],
.metar-age[role="button"] {
  cursor: pointer;
  transform: translateY(0);
  transition: box-shadow 160ms ease, transform 120ms ease, filter 160ms ease, background 160ms ease;
  -webkit-tap-highlight-color: transparent;
}

.taf-eval-time:active,
.taf-age[role="button"]:active,
.metar-age[role="button"]:active {
  transform: translateY(1px) scale(0.96);
}

.taf-eval-time.tap-glow,
.taf-age[role="button"].tap-glow,
.metar-age[role="button"].tap-glow {
  animation: tapPulse 420ms ease;
}

.vis-separator {
  color: var(--muted);
  font-weight: 1000;
  margin: 0 2px;
}

.details-block {
  margin-top: 12px;
}

.details-block summary {
  align-items: center;
  color: var(--muted);
  cursor: pointer;
  display: flex;
  flex-wrap: wrap;
  font-size: 0.86rem;
  gap: 8px;
  font-weight: 800;
  list-style-position: inside;
  text-transform: uppercase;
}

.metar-decode-row,
.taf-decode-row {
  margin: 4px 0;
}

.metar-decode-row summary,
.taf-decode-row summary {
  border-radius: 6px;
  color: var(--ink);
  cursor: pointer;
  display: block;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 0.86rem;
  font-weight: 900;
  line-height: 1.55;
  list-style: none;
  padding: 2px 1px;
  white-space: normal;
  word-break: break-word;
}

.metar-decode-row summary::-webkit-details-marker,
.taf-decode-row summary::-webkit-details-marker {
  display: none;
}

.metar-decode-row summary:hover,
.metar-decode-row summary:focus-visible,
.taf-decode-row summary:hover,
.taf-decode-row summary:focus-visible {
  background: rgba(74, 163, 255, 0.12);
  outline: none;
}

.metar-decode-row[open] summary,
.taf-decode-row[open] summary {
  background: rgba(74, 163, 255, 0.12);
}

mark,
.taf-decode-row.taf-applicable summary,
.taf-decode-row.taf-window summary {
  background: rgba(74, 163, 255, 0.2);
  border: 1px solid var(--blue);
  border-radius: 6px;
  color: var(--ink);
  display: block;
  font-weight: 900;
  margin: 4px 0;
  padding: 2px 4px;
  position: relative;
}

.taf-decode-row.taf-applicable summary::after,
.taf-decode-row.taf-window summary::after {
  clear: both;
  content: "";
  display: block;
}

.taf-decode-row.taf-applicable summary > span:first-child,
.taf-decode-row.taf-window summary > span:first-child {
  display: inline;
}

.taf-decode-row.taf-window summary {
  background: rgba(102, 217, 232, 0.12);
  border-color: #66d9e8;
}

.taf-decode-row.taf-status-green summary {
  background: rgba(46, 212, 122, 0.12);
  border-color: var(--green);
}

.taf-decode-row.taf-status-yellow summary {
  background: rgba(243, 178, 60, 0.16);
  border-color: var(--yellow);
}

.taf-decode-row.taf-status-red summary {
  background: rgba(255, 95, 86, 0.18);
  border-color: var(--red);
}

.eval-time-token-focus {
  background: rgba(74, 163, 255, 0.34);
  border-radius: 4px;
  box-shadow: 0 0 0 1px rgba(74, 163, 255, 0.92), 0 0 14px rgba(74, 163, 255, 0.32);
  color: #e7f4ff;
  padding: 1px 2px;
}

.eval-time-token-focus.eval-time-token-green {
  background: rgba(46, 212, 122, 0.28);
  box-shadow: 0 0 0 1px rgba(46, 212, 122, 0.9), 0 0 14px rgba(46, 212, 122, 0.28);
  color: #dffbe9;
}

.eval-time-token-focus.eval-time-token-yellow {
  background: rgba(243, 178, 60, 0.32);
  box-shadow: 0 0 0 1px rgba(243, 178, 60, 0.9), 0 0 14px rgba(243, 178, 60, 0.28);
  color: #fff1c4;
}

.eval-time-token-focus.eval-time-token-red {
  background: rgba(255, 95, 86, 0.34);
  box-shadow: 0 0 0 1px rgba(255, 95, 86, 0.9), 0 0 14px rgba(255, 95, 86, 0.28);
  color: #ffe5e2;
}

mark.taf-applicable {
  display: inline;
}

.taf-decode {
  background: rgba(255, 255, 255, 0.04);
  border-left: 2px solid var(--blue);
  margin: 6px 0 10px 8px;
  padding: 8px 10px;
}

.taf-decode dl {
  display: grid;
  gap: 6px;
  margin: 0;
}

.taf-decode div {
  display: grid;
  gap: 2px;
}

.taf-decode dt {
  color: #b8dcff;
  font-family: var(--font);
  font-size: 0.72rem;
  font-weight: 1000;
  text-transform: uppercase;
}

.taf-decode dd {
  color: var(--muted);
  font-family: var(--font);
  margin: 0;
}

.taf-marker {
  align-items: center;
  background: rgba(74, 163, 255, 0.28);
  border: 1px solid var(--blue);
  border-radius: 4px;
  color: #dceeff;
  display: inline-flex;
  flex: 0 0 auto;
  font-family: var(--font);
  font-size: 0.72rem;
  font-weight: 1000;
  height: 20px;
  justify-content: center;
  line-height: 1;
  min-width: 20px;
  padding: 0 5px;
}

.taf-markers {
  align-items: center;
  display: inline-flex;
  float: right;
  gap: 4px;
  margin: 1px -5px 0 6px;
}

.taf-window .taf-marker {
  background: rgba(102, 217, 232, 0.18);
  border-color: #66d9e8;
  color: #d6fbff;
  min-width: 42px;
}

.taf-marker.marker-green {
  background: rgba(46, 212, 122, 0.14);
  border-color: var(--green);
  color: #c9f7dc;
}

.taf-marker.marker-yellow {
  background: rgba(243, 178, 60, 0.16);
  border-color: var(--yellow);
  color: #ffe0a3;
}

.taf-marker.marker-red {
  background: rgba(255, 95, 86, 0.2);
  border-color: var(--red);
  color: #ffd8d5;
}

.taf-source-focus {
  border-radius: 4px;
  padding: 1px 2px;
}

.taf-source-focus.scroll-focus-red {
  background: rgba(255, 95, 86, 0.34);
  box-shadow: 0 0 0 1px var(--red);
}

.taf-source-focus.scroll-focus-yellow {
  background: rgba(243, 178, 60, 0.3);
  box-shadow: 0 0 0 1px var(--yellow);
}

.taf-source-focus.scroll-focus-green {
  background: rgba(46, 212, 122, 0.24);
  box-shadow: 0 0 0 1px var(--green);
}

h4 {
  font-size: 0.86rem;
  font-weight: 800;
  margin-bottom: 6px;
  text-transform: uppercase;
}

ul {
  margin: 0;
  padding-left: 18px;
}

.prototype-footer {
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.35;
  margin-top: 18px;
  text-align: center;
}

@media (min-width: 760px) {
  .app-shell {
    grid-template-columns: 360px 1fr;
    padding: 0 24px 24px;
  }

  .mission-panel {
    align-self: start;
    max-height: 100vh;
    overflow-y: auto;
    position: sticky;
    top: 0;
  }
}

@media (min-width: 980px) {
  .mission-panel {
    left: max(24px, calc(50% - 536px));
    max-height: none;
    overflow: visible;
    position: fixed;
    top: 0;
    width: 360px;
    z-index: 20;
  }

  .results-panel {
    grid-column: 2;
  }

  .card-header {
    align-items: start;
    display: grid;
    grid-template-columns: minmax(240px, 1fr) minmax(240px, 1fr) 86px;
  }

  .airport-row {
    column-gap: 12px;
  }

  .issue-chips {
    margin-right: 0;
  }
}

@media (min-width: 760px) and (max-height: 560px) {
  .app-shell {
    display: grid;
    gap: 0;
    grid-template-columns: 1fr;
    max-width: 100%;
    padding: 0;
  }

  .mission-panel {
    left: auto;
    max-height: none;
    overflow: hidden;
    position: relative;
    top: auto;
    width: auto;
  }

  .results-panel {
    grid-column: auto;
  }

  .mission-panel,
  .results-panel {
    border-radius: 8px;
    padding: 8px;
  }
}

@media (pointer: coarse) and (orientation: landscape) {
  .app-shell {
    display: grid;
    grid-template-columns: 1fr;
    max-width: 100%;
    padding: 0;
  }

  .mission-panel {
    left: auto;
    max-height: none;
    overflow: hidden;
    position: relative;
    top: auto;
    width: auto;
  }

  .results-panel {
    grid-column: auto;
  }
}

@media (max-width: 759px) {
  .app-shell {
    gap: 0;
    max-width: 100%;
    padding: 0;
  }

  .mission-panel,
  .results-panel {
    padding: 8px;
  }

  .decision-banner,
  .result-card {
    padding-left: 8px;
    padding-right: 8px;
  }

  .raw-line,
  .taf-line,
  .taf-decode,
  .wx-grid div {
    padding-left: 2px;
    padding-right: 2px;
  }

  .taf-line {
    padding-left: 0;
    padding-right: 0;
  }

  .taf-decode-row summary,
  .metar-decode-row summary,
  .taf-decode-row.taf-applicable summary,
  .taf-decode-row.taf-window summary {
    margin-left: 0;
    margin-right: 0;
  }

  .brand-row {
    align-items: center;
  }

  h1 {
    font-size: 1.45rem;
  }

  .data-ribbon {
    align-items: flex-start;
    display: grid;
    gap: 6px;
    grid-template-columns: minmax(0, 1fr);
    justify-items: stretch;
    width: 100%;
  }

  #pulled-at {
    align-items: center;
    display: grid;
    gap: 6px;
    grid-template-columns: minmax(0, 1fr) auto;
    justify-self: stretch;
    width: 100%;
  }

  #pulled-at > span:first-child {
    min-width: 0;
  }

  #pulled-at .data-age {
    justify-self: end;
    margin-left: 0;
  }

  .control-strip {
    gap: 6px;
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .filter-bar {
    gap: 6px;
  }

  .filter-button {
    min-width: 0;
    padding: 8px 4px;
  }

  .results-toolbar .card-actions {
    gap: 6px;
    grid-template-columns: repeat(2, 38px);
  }

  .compact-action {
    min-height: 40px;
  }

  .card-header {
    align-items: start;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    position: static;
  }

  .airport-row {
    padding-right: 82px;
  }

  .card-meta {
    grid-column: 1 / -1;
    justify-self: stretch;
    min-width: 0;
    padding-right: 0;
  }

  .evaluated-at {
    max-width: 100%;
    overflow-wrap: normal;
  }

  .card-status {
    grid-column: 2;
    grid-row: 1;
    min-width: 0;
    position: absolute;
    right: 0;
    top: 0;
    width: auto;
  }

  .mission-summary,
  .raw-line,
  .taf-line,
  .taf-decode-row summary,
  .metar-decode-row summary {
    overflow-wrap: anywhere;
  }

  .taf-decode-row.taf-applicable,
  .taf-decode-row.taf-window {
    margin-left: 0;
    margin-right: 0;
    margin-bottom: 8px;
  }

  .taf-decode-row.taf-applicable summary,
  .taf-decode-row.taf-window summary {
    padding-bottom: 3px;
  }

  .taf-markers {
    margin: 1px -5px 0 6px;
  }

  .wx-grid {
    grid-template-columns: 1fr;
  }

  .details-block:not([open]) {
    border-top: 1px solid var(--line);
    padding-top: 10px;
  }

  .details-block[open] summary {
    margin-bottom: 8px;
  }

  .airfield-search-panel {
    left: 6px;
    max-height: calc(100dvh - 16px);
    max-width: none;
    top: 8px;
    transform: none;
    width: calc(100vw - 12px);
  }

  .airfield-search-results {
    max-height: min(58vh, calc(100dvh - 220px));
    overflow-y: auto;
    padding-right: 2px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .brand-link,
  .brand-link::before,
  .brand-link::after,
  .brand-tracer,
  .brand-tracer::before,
  .brand-tracer::after,
  .brand-shatter,
  .brand-fire-button span {
    animation: none;
  }
}
