:root {
  --ink: #10222e;
  --muted: #475f6d;
  --bg: #f5f8f7;
  --surface: #ffffff;
  --alt: #eaf3f2;
  --navy: #0d3b4f;
  --teal: #0b6b74;
  --teal-dark: #084f56;
  --amber: #f4b400;
  --amber-dark: #dca000;
  --line: #d3dfe3;
  --radius: 16px;
  --shadow: 0 8px 28px rgba(13, 59, 79, 0.1);
  --header-h: 64px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 12px);
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  overflow-x: hidden;
}

img, svg, iframe { max-width: 100%; }
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: var(--teal-dark); }
[hidden] { display: none !important; }

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

.container { width: min(1160px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(760px, 100% - 32px); }

:focus-visible {
  outline: 3px solid #1d4ed8;
  outline-offset: 2px;
  border-radius: 6px;
}

.skip-link {
  position: absolute;
  left: 8px;
  top: -60px;
  z-index: 100;
  background: var(--navy);
  color: #fff;
  padding: 10px 14px;
  border-radius: 8px;
}
.skip-link:focus { top: 8px; }

.icon {
  width: 1.25em;
  height: 1.25em;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.icon-lg { width: 32px; height: 32px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 18px;
  border: 2px solid transparent;
  border-radius: 12px;
  font: inherit;
  font-weight: 650;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.18s ease, border-color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}
.btn:active { transform: translateY(1px); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: 0.6; cursor: wait; }
.btn-lg { min-height: 52px; padding: 12px 24px; font-size: 1.05rem; }
.btn-primary { background: var(--amber); color: #1b1400; box-shadow: 0 4px 14px rgba(244, 180, 0, 0.35); }
.btn-primary:hover { background: var(--amber-dark); }
.btn-secondary { background: #fff; color: var(--navy); border-color: var(--navy); }
.btn-secondary:hover { background: var(--alt); }
.btn-outline { background: var(--navy); color: #fff; }
.btn-outline:hover { background: var(--teal-dark); }
.btn-ghost { background: transparent; color: var(--navy); }
.btn-ghost:hover { background: var(--alt); }

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 2px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--navy);
  cursor: pointer;
}

.text-link { font-weight: 650; }

/* ---------- header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(8px);
}
.header-row {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: var(--header-h);
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  color: var(--navy);
  font-weight: 750;
  line-height: 1.15;
  text-decoration: none;
}
.brand-mark { display: inline-flex; flex: none; }
.brand-mark img { display: block; width: 41px; height: auto; }
.brand-text { font-size: 0.85rem; }
.header-row { gap: 8px; }
.header-actions { display: flex; flex: none; align-items: center; gap: 6px; margin-left: auto; }
.btn-map-label { display: none; }
.header-actions .btn { padding-inline: 12px; }
.btn-map { padding-inline: 10px; min-width: 44px; }

.nav {
  position: absolute;
  left: 0;
  right: 0;
  top: var(--header-h);
  display: none;
  flex-direction: column;
  padding: 8px 16px 16px;
  background: #fff;
  border-bottom: 1px solid var(--line);
  box-shadow: var(--shadow);
}
.nav.open { display: flex; }
.nav a {
  padding: 14px 4px;
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid var(--line);
}
.nav a:last-child { border-bottom: 0; }

html:not(.js) .nav { position: static; display: flex; flex-direction: row; flex-wrap: wrap; gap: 4px 16px; box-shadow: none; border: 0; padding: 0; }
html:not(.js) .nav-toggle { display: none; }

@media (min-width: 480px) {
  .brand-text { font-size: 1rem; }
  .btn-map-label { display: inline; }
  .header-row { gap: 12px; }
  .header-actions { gap: 8px; }
}

@media (min-width: 900px) {
  .nav-toggle { display: none; }
  .nav {
    position: static;
    display: flex;
    flex-direction: row;
    gap: 4px;
    margin-left: 24px;
    padding: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
  }
  .nav a { padding: 10px 12px; border: 0; border-radius: 10px; }
  .nav a:hover { background: var(--alt); }
}

.dev-note {
  background: #fff4d1;
  color: #4a3600;
  border-bottom: 1px solid #f0d98a;
  font-size: 0.9rem;
}
.dev-note .container { padding: 8px 0; }

/* ---------- hero ---------- */
.hero {
  background:
    radial-gradient(900px 400px at 85% -10%, #cfe9ee 0%, rgba(207, 233, 238, 0) 70%),
    linear-gradient(180deg, #f1f8f7 0%, var(--bg) 100%);
  padding: 40px 0 56px;
}
.hero-grid { display: grid; gap: 32px; align-items: center; }
.eyebrow {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--teal-dark);
  font-size: 0.85rem;
  font-weight: 650;
}
.hero h1 {
  margin-top: 16px;
  color: var(--navy);
  font-size: clamp(2rem, 6.5vw, 3.4rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  text-wrap: balance;
}
.lead { margin-top: 16px; max-width: 56ch; font-size: 1.1rem; color: var(--muted); }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.hero-extra { margin-top: 16px; }
.hero-points { display: grid; gap: 10px; margin-top: 24px; }
.hero-points li { display: flex; align-items: center; gap: 10px; color: var(--ink); }
.hero-points .icon { color: var(--teal); }
.fineprint { margin-top: 16px; font-size: 0.88rem; color: var(--muted); }

.hero-visual { display: grid; gap: 10px; }
.visual-frame {
  position: relative;
  max-width: 540px;
  margin-inline: auto;
  width: 100%;
  border-radius: 28px;
  box-shadow: var(--shadow);
  overflow: hidden;
  background: #dcecf3;
}
.visual-frame svg { display: block; width: 100%; height: auto; }
.mock-card {
  position: absolute;
  right: 5%;
  bottom: 6%;
  width: min(58%, 270px);
  display: grid;
  gap: 8px;
  padding: 14px;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(13, 59, 79, 0.2);
}
.mock-chip { justify-self: start; padding: 2px 10px; border-radius: 999px; background: var(--alt); color: var(--teal-dark); font-size: 0.75rem; font-weight: 650; }
.mock-line { display: block; height: 9px; width: 70%; border-radius: 6px; background: #dfe8ec; }
.mock-line-lg { width: 90%; height: 12px; background: #c8d6dc; }
.mock-route { justify-self: start; padding: 6px 10px; border-radius: 10px; background: var(--amber); color: #1b1400; font-size: 0.8rem; font-weight: 700; }
.hero-visual figcaption { text-align: center; font-size: 0.85rem; color: var(--muted); }

@media (prefers-reduced-motion: no-preference) {
  .route { animation: dash 8s linear infinite; }
  @keyframes dash { to { stroke-dashoffset: -96; } }
}

@media (min-width: 900px) {
  .hero { padding: 64px 0 80px; }
  .hero-grid { grid-template-columns: 1.1fr 0.9fr; gap: 48px; }
}

/* ---------- sections ---------- */
.section { padding: 56px 0; }
.section-alt { background: var(--alt); }
.section-head { margin-bottom: 28px; max-width: 70ch; }
.section h2 { color: var(--navy); font-size: clamp(1.5rem, 4vw, 2.1rem); line-height: 1.2; letter-spacing: -0.01em; }
.section-head p { margin-top: 10px; color: var(--muted); }
.narrow h2 { margin-bottom: 12px; }
.narrow p + p, .narrow div p + p { margin-top: 12px; }

@media (prefers-reduced-motion: no-preference) {
  html.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.5s ease, transform 0.5s ease; }
  html.js .reveal.in { opacity: 1; transform: none; }
}

/* ---------- search ---------- */
.section-search { background: var(--surface); border-block: 1px solid var(--line); }
.search-grid { display: grid; gap: 28px; grid-template-columns: minmax(0, 1fr); }
.search-grid > * { min-width: 0; }
.search-form { display: grid; gap: 14px; grid-template-columns: minmax(0, 1fr); }
.field { display: grid; gap: 6px; }
.field label { font-weight: 650; font-size: 0.95rem; }
.field input, .field select {
  width: 100%;
  min-height: 48px;
  padding: 10px 14px;
  border: 2px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--ink);
  font: inherit;
}
.field input:hover, .field select:hover { border-color: #9db6bf; }
.field input:focus-visible, .field select:focus-visible { outline: 3px solid #1d4ed8; outline-offset: 1px; border-color: #1d4ed8; }
.form-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.form-actions .btn { flex: 1 1 160px; }
.geo-note { margin-top: 14px; font-size: 0.9rem; color: var(--muted); }
.status { min-height: 1.4em; margin-top: 8px; font-size: 0.95rem; font-weight: 600; color: var(--teal-dark); }
.status.is-warn { color: #8a3a00; }
.results { margin-top: 12px; outline: none; }
.results-head { margin-bottom: 12px; font-weight: 650; }
.empty {
  padding: 16px;
  border: 1px dashed #9db6bf;
  border-radius: 12px;
  background: #f8fbfb;
  color: var(--muted);
}

.map-panel { display: grid; gap: 10px; align-content: start; }
.map-frame {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  background: #dcecf3;
  width: 100%;
  height: 320px;
}
.map-frame iframe { display: block; width: 100%; height: 100%; border: 0; }
.map-panel figcaption { font-size: 0.85rem; color: var(--muted); }

@media (min-width: 960px) {
  .search-grid { grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: 40px; align-items: start; }
  .search-form { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .map-frame { height: auto; aspect-ratio: 4 / 3; min-height: 320px; }
  .field-wide, .form-actions { grid-column: 1 / -1; }
  .map-panel { position: sticky; top: calc(var(--header-h) + 16px); }
}

/* ---------- categories ---------- */
.cat-grid { display: grid; gap: 12px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cat-tile {
  min-width: 0;
  overflow-wrap: anywhere;
  hyphens: auto;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  width: 100%;
  min-height: 120px;
  padding: 16px;
  border: 2px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--navy);
  font: inherit;
  font-weight: 700;
  line-height: 1.25;
  text-align: left;
  cursor: pointer;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}
.cat-tile .icon { color: var(--teal); }
.cat-tile:hover { border-color: var(--teal); box-shadow: var(--shadow); transform: translateY(-2px); }
.cat-tile[aria-pressed="true"] { border-color: var(--teal); background: #eef8f7; }

@media (min-width: 700px) { .cat-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

/* ---------- cards ---------- */
.cards { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(min(250px, 100%), 1fr)); }
.card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 2px 10px rgba(13, 59, 79, 0.05);
}
.card-media { position: relative; aspect-ratio: 16 / 10; background: var(--alt); }
.card-media img { display: block; width: 100%; height: 100%; object-fit: cover; }
.card-media .placeholder { display: grid; place-items: center; width: 100%; height: 100%; color: var(--teal); }
.badges { position: absolute; left: 10px; top: 10px; display: flex; flex-wrap: wrap; gap: 6px; }
.badge { padding: 3px 10px; border-radius: 999px; background: var(--navy); color: #fff; font-size: 0.78rem; font-weight: 700; }
.badge-ad { background: #fff; color: var(--ink); border: 1px solid var(--ink); }
.badge-test { background: #7c2d12; }
.card-body { display: flex; flex: 1; flex-direction: column; gap: 8px; padding: 16px; }
.card-cat { font-size: 0.82rem; font-weight: 700; color: var(--teal-dark); }
.card h3 { font-size: 1.1rem; line-height: 1.25; color: var(--navy); }
.card-desc { color: var(--muted); font-size: 0.95rem; }
.card-meta { font-size: 0.9rem; color: var(--ink); }
.card-offer { padding: 10px 12px; border-radius: 12px; background: #fff7dc; border: 1px solid #f0d98a; font-size: 0.9rem; }
.card-offer strong { display: block; }
.card-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; padding-top: 8px; }
.card-actions .btn { flex: 1 1 120px; min-height: 44px; padding: 8px 12px; font-size: 0.95rem; }

/* ---------- steps / benefits ---------- */
.steps { display: grid; gap: 14px; counter-reset: step; }
.steps li {
  position: relative;
  padding: 18px 18px 18px 72px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  counter-increment: step;
}
.steps li::before {
  content: counter(step);
  position: absolute;
  left: 18px;
  top: 16px;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  font-weight: 750;
}
.steps h3 { font-size: 1.05rem; color: var(--navy); }
.steps p { margin-top: 4px; color: var(--muted); }

@media (min-width: 900px) {
  .steps { grid-template-columns: repeat(4, 1fr); }
  .steps li { padding: 72px 18px 18px; }
  .steps li::before { left: 18px; top: 18px; }
}

.benefits { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); }
.benefits li { padding: 20px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.benefits .icon { color: var(--teal); }
.benefits h3 { margin-top: 12px; font-size: 1.05rem; color: var(--navy); }
.benefits p { margin-top: 6px; color: var(--muted); }

/* ---------- faq ---------- */
.faq { display: grid; gap: 10px; }
.faq details { border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.faq summary {
  min-height: 48px;
  padding: 14px 16px;
  font-weight: 650;
  color: var(--navy);
  cursor: pointer;
}
.faq p { padding: 0 16px 16px; color: var(--muted); }

/* ---------- footer ---------- */
.site-footer { background: var(--navy); color: #e5f0f3; padding: 36px 0; }
.footer-grid { display: grid; gap: 24px; }
.footer-brand { font-weight: 750; font-size: 1.1rem; color: #fff; }
.footer-sub { margin-top: 4px; color: #bcd3da; }
.site-footer ul { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.site-footer a { color: #fff; }
@media (min-width: 700px) { .footer-grid { grid-template-columns: 1fr auto; align-items: start; } }

/* ---------- misc ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 20px;
  z-index: 80;
  width: min(92vw, 420px);
  transform: translateX(-50%);
  padding: 14px 18px;
  border-radius: 12px;
  background: var(--navy);
  color: #fff;
  box-shadow: var(--shadow);
}
.noscript { padding: 12px 16px; background: #fff4d1; text-align: center; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  html.js .reveal { opacity: 1 !important; transform: none !important; }
}
