/* GTA Codex — core stylesheet (hand-compiled; no build step required)
   Design tokens per design.md §2.3. */

:root {
  --ink: #170E21;
  --ink-raised: #261832;
  --plum: #4D2B5B;
  --plum-muted: #76517D;
  --paper: #FFF8EC;
  --paper-muted: #E9DCCE;
  --white: #FFFFFF;
  --sunset-pink: #F05A9D;
  --sunset-coral: #FF745A;
  --sun-gold: #FFB33F;
  --lagoon: #55C9D2;
  --ocean: #317AB7;
  --transit: #3C7DFF;
  --palm: #34745F;
  --danger: #D7445B;
  /* Service/place category colours (see gc-glyphs.js + ServiceCategoriesSeeder) */
  --svc-clothing: #F05A9D; --svc-tattoo: #7A5CFF; --svc-car-dealer: #317AB7; --svc-car-mod: #2F9E8F;
  --svc-gas: #FF745A; --svc-shop: #FFB33F; --svc-hair: #E06FAE; --svc-bar: #B9822E;
  --svc-factory: #8A94A3; --svc-club: #9B4DFF; --svc-hospital: #E23B4E; --svc-police: #2F6AD0;
  --svc-bank: #34745F; --svc-atm: #4AA06F;
  --svc-restaurant: #E06C3B; --svc-car-wash: #2C9EEB; --svc-gun-shop: #9D4B4B;
  --text-on-dark: #FFF8EC;
  --text-dark: #211626;
  --text-quiet-dark: #CDBBD1;
  --text-quiet-light: #695866;
  --hairline: #3A2547;
  --maxw: 1440px;
  --header-h: 72px;
  --radius: 8px;
  --ease: cubic-bezier(.2, .7, .3, 1);
}


*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--ink);
  color: var(--text-on-dark);
  font-family: Manrope, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  font-size: 16px; line-height: 1.6;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
main { padding-top: var(--header-h); }
img { max-width: 100%; display: block; }
a { color: var(--sunset-pink); text-decoration: none; }
a:hover { color: var(--sunset-coral); }
::selection { background: var(--sunset-pink); color: var(--ink); }
:focus-visible { outline: 2px solid var(--sun-gold); outline-offset: 2px; border-radius: 3px; }
h1, h2, h3 { margin: 0; }
.display { font-family: 'Bebas Neue', Impact, sans-serif; text-transform: uppercase; letter-spacing: .04em; font-weight: 400; line-height: .95; }

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 clamp(16px, 3vw, 24px); }
.section { padding: clamp(56px, 7vw, 100px) 0; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: clamp(20px, 3vw, 32px); }
.section-head h2 { font-size: clamp(1.75rem, 3.4vw, 3rem); }
.section-head .eyebrow, .eyebrow { display: block; font-size: 12px; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; color: var(--sun-gold); margin-bottom: 8px; }
.section-head p { margin: 6px 0 0; color: var(--text-quiet-dark); max-width: 52ch; }
.link-arrow { font-weight: 700; font-size: 14px; letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; }
.link-arrow::after { content: " →"; }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; gap: 10px; height: 48px; padding: 0 22px; border-radius: var(--radius);
  font-family: inherit; font-size: 15px; font-weight: 700; letter-spacing: .02em; cursor: pointer; border: 2px solid transparent;
  transition: transform 180ms var(--ease), background-color 180ms var(--ease), color 180ms var(--ease), border-color 180ms var(--ease); }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--sunset-pink); color: #fff; border-color: var(--sunset-pink); }
.btn-primary:hover { background: var(--sunset-coral); border-color: var(--sunset-coral); color: #fff; }
.btn-secondary { background: transparent; color: var(--paper); border-color: var(--paper); }
.btn-secondary:hover { border-color: var(--sun-gold); color: var(--sun-gold); }

/* ---------- Header (white bar) ---------- */
.hdr { position: fixed; top: 0; left: 0; right: 0; z-index: 1300; isolation: isolate; height: var(--header-h); }
.hdr__bg { position: absolute; inset: 0; background: rgba(255,255,255,.78); backdrop-filter: blur(14px) saturate(1.3); -webkit-backdrop-filter: blur(14px) saturate(1.3); border-bottom: 1px solid rgba(23,14,33,.06); box-shadow: none; transition: background .3s ease, box-shadow .3s ease, border-color .3s ease; }
.hdr.is-solid .hdr__bg { background: #FFFFFF; border-bottom-color: var(--paper-muted); box-shadow: 0 2px 14px rgba(23,14,33,.10); }
/* Shared scroll-reveal utility (used site-wide; JS adds .is-in when in view). */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .7s cubic-bezier(.16,1,.3,1); }
.reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }
.hdr__inner { position: relative; height: 100%; display: flex; align-items: center; gap: clamp(12px, 2vw, 28px); }
.brand { display: flex; align-items: center; flex: none; }
.brand__logo { height: 46px; width: auto; display: block; }
.nav { display: flex; align-items: center; gap: clamp(10px, 1.6vw, 22px); }
.nav a { color: var(--text-dark); font-size: 14px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; padding: 8px 2px; border-bottom: 2px solid transparent; }
.nav a:hover, .nav a[aria-current="page"] { border-bottom-color: var(--sunset-pink); color: var(--ink); }
.spacer { flex: 1; }
.search-btn { display: flex; align-items: center; gap: 10px; width: clamp(200px, 24vw, 320px); height: 40px; padding: 0 12px;
  background: #F5EFE4; border: 1px solid var(--paper-muted); border-radius: var(--radius); color: var(--text-quiet-light);
  font-family: inherit; font-size: 14px; cursor: pointer; text-align: left; }
.search-btn:hover { border-color: var(--plum-muted); }
.search-btn kbd { margin-left: auto; font-family: inherit; font-size: 12px; font-weight: 700; color: var(--text-quiet-light); background: #fff; border: 1px solid var(--paper-muted); border-radius: 4px; padding: 1px 6px; }
.progress-link { display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px; border: 2px solid var(--sunset-pink); border-radius: var(--radius); background: var(--sunset-pink); color: #fff; font-size: 14px; font-weight: 800; flex: none; }
.progress-link:hover { background: var(--sunset-coral); border-color: var(--sunset-coral); color: #fff; }
.icon-btn { width: 44px; height: 44px; display: grid; place-items: center; background: #F5EFE4; border: 1px solid var(--paper-muted); border-radius: var(--radius); color: var(--ink); cursor: pointer; }
.hdr__actions { align-items: center; gap: 12px; }
.menu-toggle { display: none; margin-left: auto; }
.only-wide { display: flex; }
.only-narrow { display: none; }

/* Mobile menu (dark overlay) */
.menu { position: fixed; inset: 0; z-index: 1400; background: var(--ink); display: none; flex-direction: column; padding: 16px; }
.menu.is-open { display: flex; }
.menu__top { display: flex; align-items: center; justify-content: space-between; height: 44px; }
.menu__top .display { font-size: 24px; letter-spacing: .06em; color: var(--paper); }
.menu__top .icon-btn { background: var(--ink-raised); border-color: var(--hairline); color: var(--paper); }
.menu nav { display: flex; flex-direction: column; gap: 2px; margin-top: 24px; }
.menu nav a { display: flex; align-items: center; justify-content: space-between; min-height: 56px; padding: 0 4px; border-bottom: 1px solid var(--hairline); color: var(--paper); font-family: 'Bebas Neue', Impact, sans-serif; font-size: 30px; letter-spacing: .05em; }
.menu nav a small { font-family: Manrope, sans-serif; font-size: 13px; font-weight: 600; color: var(--text-quiet-dark); }
.menu__body { display: flex; flex-direction: column; gap: 18px; margin-top: 20px; overflow-y: auto; }
.menu__body .menu__nav { margin-top: 0; }
.menu__search { display: flex; align-items: center; gap: 10px; height: 50px; padding: 0 16px; background: var(--ink-raised); border: 1px solid var(--hairline); border-radius: var(--radius); color: var(--text-quiet-dark); font-size: 16px; font-weight: 600; }
.menu__progress { display: flex; align-items: center; justify-content: center; gap: 10px; height: 54px; border-radius: var(--radius); background: var(--sunset-pink); color: #fff; font-size: 16px; font-weight: 800; border: 2px solid var(--sunset-pink); box-shadow: 0 0 16px rgba(240,90,157,.55); }
.menu__progress:hover { background: var(--sunset-coral); border-color: var(--sunset-coral); color: #fff; }

/* ---------- Video banner + hero content ---------- */
.hero-banner { position: relative; width: 100%; height: clamp(280px, 46vw, 620px); background: var(--ink); overflow: hidden; }
.hero-banner__video { width: 100%; height: 100%; object-fit: cover; display: block; background-size: cover; background-position: center; }
.hero-banner__fade { position: absolute; left: 0; right: 0; bottom: 0; height: 40%; background: linear-gradient(to top, var(--ink), rgba(23,14,33,0)); pointer-events: none; }
.hero-content { padding: clamp(24px, 4vw, 44px) 0 clamp(32px, 5vw, 56px); background: var(--ink); }
.hero-content .kicker { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; color: var(--sun-gold); margin-bottom: 14px; }
.hero-content .kicker .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--sunset-pink); box-shadow: 0 0 0 4px rgba(240,90,157,.25); }
.hero-content h1 { font-size: clamp(2.75rem, 8vw, 6rem); }
.hero-content h1 .accent { color: var(--sunset-pink); }
.hero-content .tagline { font-size: clamp(1.05rem, 2.4vw, 1.5rem); font-weight: 600; color: var(--paper); margin: 12px 0 26px; }
.hero-content .actions { display: flex; flex-wrap: wrap; gap: 14px; }

/* ---------- Region rail ---------- */
.rail { display: grid; grid-template-columns: repeat(2, 1fr); gap: clamp(12px, 1.4vw, 18px); }
@media (min-width: 620px) { .rail { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1180px) { .rail { grid-template-columns: repeat(6, 1fr); } }
.rail::-webkit-scrollbar { height: 8px; }
.rail::-webkit-scrollbar-thumb { background: var(--hairline); border-radius: 8px; }
.postcard { position: relative; scroll-snap-align: start; display: block; aspect-ratio: 3/2; border-radius: var(--radius); overflow: hidden; border: 2px solid var(--paper); background: var(--ink-raised); transition: transform 200ms var(--ease); }
.postcard:hover { transform: translateY(-4px) rotate(-.4deg); }
.postcard img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.postcard__grad { position: absolute; inset: 0; background: linear-gradient(to top, rgba(23,14,33,.9) 6%, rgba(23,14,33,.15) 55%, rgba(23,14,33,0) 80%); }
.postcard__label { position: absolute; left: 14px; right: 14px; bottom: 12px; }
.postcard__label .name { font-family: 'Bebas Neue', Impact, sans-serif; font-size: 26px; letter-spacing: .04em; color: var(--paper); }
.postcard__label .meta { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--text-quiet-dark); }

/* ---------- Panels / tracker / states ---------- */
.panel { background: var(--ink-raised); border: 1px solid var(--hairline); border-radius: var(--radius); padding: clamp(20px, 3vw, 32px); }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(18px, 3vw, 28px); align-items: center; }
.tracker-cta { background: linear-gradient(135deg, var(--plum), var(--ink-raised)); border: 1px solid var(--hairline); border-radius: var(--radius); padding: clamp(24px, 4vw, 40px); }
.tracker-cta h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); }
.tracker-cta p { color: var(--text-quiet-dark); max-width: 46ch; }
.meter { height: 12px; background: var(--ink); border: 1px solid var(--hairline); border-radius: 999px; overflow: hidden; margin: 18px 0; }
.meter > span { display: block; height: 100%; width: 0%; background: linear-gradient(90deg, var(--sun-gold), var(--sunset-pink)); }
.empty { border: 1px dashed var(--hairline); border-radius: var(--radius); padding: clamp(24px, 4vw, 40px); text-align: center; color: var(--text-quiet-dark); background: rgba(38,24,50,.4); }
.empty strong { color: var(--paper); display: block; font-size: 1.1rem; margin-bottom: 6px; }
.chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 8px; }
.chip { display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--hairline); background: var(--ink); color: var(--paper); font-size: 13px; font-weight: 700; }
.chip .sw { width: 10px; height: 10px; border-radius: 50%; }

/* Map teaser (home) */
.teaser { position: relative; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--hairline); }
