:root {
  color-scheme: light;
  --navy: #09233d;
  --navy-2: #113b5d;
  --ink: #12263a;
  --muted: #5c6c7b;
  --paper: #fbfaf6;
  --white: #ffffff;
  --line: #d8e0e7;
  --gold: #d1a93b;
  --gold-soft: #f7edcf;
  --blue-soft: #eaf2f8;
  --focus: #0a67b2;
  --success: #276749;
  --danger: #a33a2a;
  --shadow: 0 18px 50px rgba(9, 35, 61, .13);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 1rem/1.55 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  text-rendering: optimizeLegibility;
}
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }

.skip-link {
  position: fixed;
  z-index: 1000;
  left: 16px;
  top: -80px;
  padding: 10px 14px;
  border-radius: 8px;
  background: #fff;
  color: var(--navy);
  font-weight: 700;
}
.skip-link:focus { top: 12px; }

.site-header { background: var(--navy); color: #fff; }
.header-inner {
  width: min(1120px, calc(100% - 32px));
  min-height: 72px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255,255,255,.38);
  border-radius: 13px;
  color: var(--gold);
  font: 800 1.1rem/1 ui-monospace, SFMono-Regular, Menlo, monospace;
}
.brand strong { display: block; font-size: 1.05rem; letter-spacing: -.01em; }
.brand small { display: block; color: rgba(255,255,255,.72); font-size: .78rem; }
.pilot-badge {
  min-height: 44px;
  padding: 7px 10px;
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(255,255,255,.28);
  border-radius: 999px;
  color: #fff;
  font-size: .78rem;
  font-weight: 700;
}
.back-link {
  min-height: 44px;
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  color: rgba(255,255,255,.86);
  font-size: .9rem;
  font-weight: 700;
  text-underline-offset: 3px;
}

.hero {
  color: #fff;
  background:
    radial-gradient(circle at 84% 18%, rgba(209,169,59,.22), transparent 28%),
    linear-gradient(145deg, var(--navy), var(--navy-2));
  border-radius: 0 0 36px 36px;
}
.hero-inner { width: min(960px, calc(100% - 32px)); margin: 0 auto; padding: 58px 0 42px; }
.eyebrow, .results-kicker {
  margin: 0 0 8px;
  color: var(--gold);
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}
h1 {
  max-width: 740px;
  margin: 0;
  font-size: clamp(2.25rem, 6vw, 4.75rem);
  line-height: 1.02;
  letter-spacing: -.045em;
  text-wrap: balance;
}
.hero-copy { max-width: 650px; margin: 18px 0 30px; color: rgba(255,255,255,.83); font-size: clamp(1.05rem, 2vw, 1.25rem); }

.search-card {
  padding: 20px;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 22px;
  background: rgba(255,255,255,.98);
  color: var(--ink);
  box-shadow: var(--shadow);
}
.search-main > label { display: block; margin: 0 0 8px; font-weight: 750; }
.search-control { display: grid; grid-template-columns: 1fr auto; gap: 10px; }
.search-control input, .filters select {
  width: 100%;
  min-height: 52px;
  border: 1.5px solid #b9c7d2;
  border-radius: 12px;
  background: #fff;
  color: var(--ink);
}
.search-control input { padding: 0 16px; font-size: 1.05rem; }
.search-control button {
  min-height: 52px;
  padding: 0 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  border-radius: 12px;
  background: var(--navy);
  color: #fff;
  font-weight: 750;
  cursor: pointer;
}
.search-control button svg { width: 20px; fill: none; stroke: currentColor; stroke-width: 2; }
.search-control button:disabled { opacity: .62; cursor: wait; }
.filters { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 14px; }
.filters label > span { display: block; margin: 0 0 6px; color: var(--muted); font-size: .84rem; font-weight: 700; }
.filters select { padding: 0 42px 0 14px; }
.examples { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; margin-top: 16px; color: var(--muted); font-size: .84rem; }
.examples button {
  min-height: 44px;
  padding: 8px 12px;
  border: 1px solid #cfd9e1;
  border-radius: 999px;
  background: var(--blue-soft);
  color: var(--navy);
  cursor: pointer;
}

.ai-note { display: flex; gap: 12px; max-width: 780px; margin: 22px 0 0; color: rgba(255,255,255,.78); font-size: .88rem; }
.ai-note svg { width: 24px; height: 24px; flex: none; margin-top: 2px; fill: none; stroke: var(--gold); stroke-width: 1.7; }
.ai-note p { margin: 0; }
.ai-note strong { color: #fff; }

.results-section { width: min(960px, calc(100% - 32px)); min-height: 420px; margin: 0 auto; padding: 42px 0 76px; }
.results-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 18px; }
.results-kicker { color: var(--success); }
h2 { margin: 0; color: var(--navy); font-size: clamp(1.75rem, 4vw, 2.45rem); line-height: 1.12; }
.reset {
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid #bcc9d2;
  border-radius: 10px;
  background: #fff;
  color: var(--navy);
  font-weight: 700;
  cursor: pointer;
}
.status {
  min-height: 220px;
  padding: 38px 24px;
  display: grid;
  place-items: center;
  align-content: center;
  border: 1px dashed #b8c5cf;
  border-radius: 18px;
  background: rgba(255,255,255,.58);
  color: var(--muted);
  text-align: center;
}
.status p { margin: 16px 0 0; }
.status[hidden] { display: none; }
.empty-illustration { display: flex; align-items: end; gap: 7px; height: 54px; }
.empty-illustration span { display: block; width: 16px; border-radius: 8px 8px 3px 3px; background: #cbd7df; }
.empty-illustration span:nth-child(1) { height: 30px; }
.empty-illustration span:nth-child(2) { height: 50px; background: var(--gold); }
.empty-illustration span:nth-child(3) { height: 40px; }
.loader { width: 34px; height: 34px; border: 3px solid #d9e2e8; border-top-color: var(--navy); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.results { display: grid; gap: 12px; }
.result-card {
  display: grid;
  grid-template-columns: 114px 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(9,35,61,.055);
}
.date-tile {
  min-height: 88px;
  padding: 12px;
  display: grid;
  place-items: center;
  align-content: center;
  border-radius: 12px;
  background: var(--gold-soft);
  color: var(--navy);
  text-align: center;
}
.date-tile strong { display: block; font-size: 1.05rem; line-height: 1.2; }
.date-tile span { display: block; margin-top: 3px; font-size: .76rem; }
.result-copy { min-width: 0; }
.result-copy h3 { margin: 0 0 6px; color: var(--navy); font-size: 1.18rem; line-height: 1.25; text-wrap: balance; }
.result-copy p { margin: 0; color: var(--muted); }
.result-meta { display: flex; flex-wrap: wrap; gap: 6px 12px; margin-top: 9px; color: #45576a; font-size: .82rem; }
.result-link {
  min-height: 44px;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid var(--navy);
  border-radius: 10px;
  color: var(--navy);
  font-weight: 750;
  text-decoration: none;
  white-space: nowrap;
}
.result-link:hover { background: var(--navy); color: #fff; }
.result-card:focus-within { outline: 3px solid rgba(10,103,178,.24); outline-offset: 2px; }

footer { padding: 24px 16px calc(24px + env(safe-area-inset-bottom)); background: #e9eef2; color: #506171; text-align: center; font-size: .84rem; }
footer p { margin: 0; }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }

@media (max-width: 720px) {
  .header-inner { width: min(100% - 24px, 960px); min-height: 64px; }
  .hero { border-radius: 0 0 24px 24px; }
  .hero-inner { width: min(100% - 24px, 960px); padding: 36px 0 28px; }
  h1 { font-size: clamp(2.35rem, 13vw, 3.65rem); }
  .hero-copy { margin-top: 14px; }
  .search-card { margin: 0 -2px; padding: 14px; border-radius: 17px; }
  .search-control { grid-template-columns: 1fr; }
  .search-control button { width: 100%; }
  .filters { grid-template-columns: 1fr; }
  .examples { align-items: flex-start; }
  .examples > span { width: 100%; }
  .ai-note { font-size: .82rem; }
  .results-section { width: min(100% - 24px, 960px); padding-top: 30px; }
  .results-head { align-items: center; }
  .result-card { grid-template-columns: 82px 1fr; gap: 12px; padding: 13px; }
  .date-tile { min-height: 76px; padding: 9px; }
  .result-link { grid-column: 1 / -1; width: 100%; }
}

@media (max-width: 360px) {
  .pilot-badge { font-size: .7rem; }
  .back-link { display: none; }
  .brand-mark { width: 38px; height: 38px; }
  .results-head { align-items: flex-start; flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

