/* ==========================================================================
   Skilz marketing site — shared stylesheet
   Brand tokens read literally from src/constants/colors.ts, quadrants.ts,
   and ranks.ts. Do not change hex values here without changing them there.
   ========================================================================== */

:root {
  color-scheme: light;

  /* Brand palette — src/constants/colors.ts */
  --navy: #0D274B;
  --green: #55AE1E;
  --deep-navy: #183356;
  --dark-green: #3A7B10;
  --light-green: #7DCE42;
  --white: #FFFFFF;
  --navy-light: #EDF2F8;
  --mint: #E8F5E2;
  --charcoal: #2C2C3E;
  --gray: #666680;
  --mid-gray: #CCCCCC;
  --light-gray: #F5F5F8;

  /* Quadrant colors — src/constants/quadrants.ts. Already darkened for
     4.5:1 contrast on white. Do not lighten. */
  --quad-academic: #C64F20;
  --quad-body-soul: #158378;
  --quad-creativity: #5D7E47;
  --quad-money: #976E00;

  /* Rank colors — src/constants/ranks.ts */
  --rank-recruit: #888888;
  --rank-apprentice: #55AE1E;
  --rank-explorer: #3B82F6;
  --rank-achiever: #9334E6;
  --rank-champion: #F97316;
  --rank-elite: #EF4444;
  --rank-master: #EAB308;
  --rank-legend: #EAB308;
  --rank-gold-legend: #D4AF37;
  --rank-legacy: #B8860B;
  --rank-mentor: #55AE1E;

  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --max-width: 1120px;
  --gutter: 24px;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --shadow-card: 0 2px 10px rgba(13, 39, 75, 0.08);
  --shadow-lift: 0 10px 30px rgba(13, 39, 75, 0.18);
}

/* ---- Reset -------------------------------------------------------------- */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--white);
  color: var(--charcoal);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: inherit; }

ul, ol { padding-left: 1.3em; }

button { font-family: inherit; }

h1, h2, h3, h4 {
  font-weight: 800;
  line-height: 1.15;
  margin: 0 0 0.5em;
  color: var(--navy);
}

h1 { font-size: clamp(32px, 5vw, 52px); font-weight: 800; }
h2 { font-size: clamp(26px, 3.6vw, 38px); }
h3 { font-size: 21px; font-weight: 700; }

p { margin: 0 0 1em; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

/* ---- Focus ---------------------------------------------------------------
   Visible on every interactive element, brand green, 2px offset. */

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ---- Skip link ------------------------------------------------------------ */

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 1000;
  background: var(--navy);
  color: var(--white);
  padding: 12px 20px;
  border-radius: 0 0 var(--radius-sm) 0;
  font-weight: 700;
  text-decoration: none;
}

.skip-link:focus {
  left: 0;
}

/* ---- Layout helpers -------------------------------------------------------- */

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.section {
  padding: 72px 0;
}

@media (min-width: 960px) {
  .section { padding: 112px 0; }
}

.section-head {
  max-width: 720px;
  margin: 0 0 40px;
}

.section-head.center {
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--green);
  margin: 0 0 12px;
}

.lede {
  font-size: 19px;
  color: var(--gray);
}

.section--tint {
  background: var(--light-gray);
}

.section--mint {
  background: var(--mint);
}

.section--navy {
  background: var(--navy);
  color: var(--white);
}

.section--navy h1,
.section--navy h2,
.section--navy h3 {
  color: var(--white);
}

.section--navy .lede {
  color: rgba(255, 255, 255, 0.78);
}

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ---- Buttons ---------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 26px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 16px;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
}

.btn:active { transform: translateY(1px); }

.btn--primary {
  background: var(--green);
  color: var(--white);
  border-color: var(--green);
}

.btn--primary:hover { background: var(--dark-green); border-color: var(--dark-green); }

.btn--secondary {
  background: transparent;
  color: var(--navy);
  border-color: var(--navy);
}

.btn--secondary:hover { background: var(--navy); color: var(--white); }

.section--navy .btn--secondary {
  color: var(--white);
  border-color: var(--white);
}

.section--navy .btn--secondary:hover {
  background: var(--white);
  color: var(--navy);
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
}

/* ---- Header / nav ------------------------------------------------------------ */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--light-gray);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  gap: 16px;
}

.brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

/* The logo file is a full lockup (wordmark + tagline) sitting inside a lot
   of transparent margin — roughly 9% on the left and 24% on the top. This
   box crops to the artwork itself, so the mark reads at header size
   instead of shrinking to mush. Change the width and the three derived
   numbers together. */
.brand-logo {
  display: block;
  position: relative;
  overflow: hidden;
  width: 124px;
  height: 43px;
}

.brand-logo img {
  position: absolute;
  width: 149px;
  height: auto;
  max-width: none;
  left: -14px;
  top: -24px;
}

.brand-logo--lg {
  width: 158px;
  height: 55px;
}

.brand-logo--lg img {
  width: 190px;
  left: -18px;
  top: -31px;
}

.nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--light-gray);
  background: var(--white);
  cursor: pointer;
}

.nav-toggle svg { width: 22px; height: 22px; }

@media (min-width: 960px) {
  .nav-toggle { display: none; }
}

.main-nav {
  display: none;
  align-items: center;
  gap: 28px;
}

.main-nav a {
  text-decoration: none;
  font-weight: 600;
  color: var(--charcoal);
  font-size: 15px;
}

.main-nav a:hover { color: var(--green); }

@media (min-width: 960px) {
  .main-nav { display: flex; }
}

.site-header.nav-open .main-nav {
  display: flex;
  position: absolute;
  top: 72px;
  left: 0;
  right: 0;
  background: var(--white);
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 12px var(--gutter) 20px;
  border-bottom: 1px solid var(--light-gray);
  box-shadow: var(--shadow-card);
}

.site-header.nav-open .main-nav a {
  width: 100%;
  padding: 10px 0;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Below the nav breakpoint the header is just logo + hamburger. The store
   badges are ~330px on their own and would push the header — and with it
   the whole page — wider than a phone viewport. The hero carries its own
   pair, so nothing is lost by dropping them here. */
@media (max-width: 959px) {
  .header-actions .store-badges { display: none; }
}

/* ---- Store badges (disabled, "coming soon") --------------------------------- */

.store-badges {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.store-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--mid-gray);
  color: var(--gray);
  font-size: 13px;
  font-weight: 700;
  background: var(--white);
  cursor: default;
  user-select: none;
}

.section--navy .store-badge {
  border-color: rgba(255, 255, 255, 0.35);
  color: rgba(255, 255, 255, 0.75);
  background: rgba(255, 255, 255, 0.06);
}

.store-badge svg { width: 18px; height: 18px; flex-shrink: 0; }

.store-badge .store-badge-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.store-badge .store-badge-text small {
  font-weight: 500;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  opacity: 0.85;
}

/* ---- Hero --------------------------------------------------------------------- */

.hero {
  position: relative;
  overflow: hidden;
  padding-top: 48px;
  padding-bottom: 48px;
}

@media (min-width: 640px) {
  .hero { padding-top: 64px; padding-bottom: 64px; }
}

@media (min-width: 960px) {
  .hero { padding-top: 96px; padding-bottom: 96px; }
}

/* Below 640px the desktop type scale is too heavy for the column: h1 sits
   at its 32px clamp floor across 4 lines and .lede runs 19px across 6,
   stacking into one dense block before any visual break. Scale both down
   and loosen the headline's line-height so the block reads instead of
   just filling the screen. */
@media (max-width: 639px) {
  .hero h1 { font-size: 30px; line-height: 1.22; }
  .hero .lede { font-size: 16px; line-height: 1.55; }
  .hero .eyebrow { margin-bottom: 10px; }
  .hero-copy p.lede { margin-top: 14px; margin-bottom: 24px; }

  /* One centred column on a phone: a left-aligned block of buttons and
     store badges leaves a ragged gap down the right-hand side. */
  .hero-copy { text-align: center; }
  .hero-copy .btn-row,
  .hero-copy .store-badges { justify-content: center; }
}

/* The second half of the hero sentence — detail that earns its place on a
   wide screen and only adds bulk on a phone. */
@media (max-width: 639px) {
  .lede-more { display: none; }
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  object-fit: cover;
  width: 100%;
  height: 100%;
  opacity: 0.35;
}

.hero .container {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 40px;
  align-items: center;
}

@media (min-width: 960px) {
  .hero .container {
    grid-template-columns: 1.05fr 0.95fr;
  }
}

.hero-copy p.lede { margin-bottom: 28px; }

.hero-media {
  position: relative;
}

/* The screenshots are 1220x2611 and include the Android system nav bar in
   the bottom 163px (measured: app content ends at y=2448, nav glyphs start
   at y=2502). We crop at y=2475 — clear of the labels, clear of the glyphs.
   The frame's aspect ratio is the screenshot MINUS that bar, so cover +
   object-position:top crops the nav bar off exactly. box-sizing is
   content-box below so this ratio describes the screen, not the bezel.
   Change the ratio and the box-sizing together or the crop drifts. */
.phone-frame {
  box-sizing: content-box; /* aspect-ratio must describe the SCREEN, not the bezel */
  width: 100%;
  max-width: 300px;
  margin: 0 auto;
  border-radius: 34px;
  border: 6px solid var(--deep-navy);
  background: var(--deep-navy);
  box-shadow: var(--shadow-lift);
  overflow: hidden;
  aspect-ratio: 1220 / 2475;
}

.phone-frame img,
.phone-frame .img-placeholder {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

/* Rotating screenshots inside the frame. */
.phone-shots {
  position: relative;
  width: 100%;
  height: 100%;
}

.phone-frame .phone-shots img {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 700ms ease;
}

.phone-frame .phone-shots img.is-active { opacity: 1; }

.shot-dots {
  list-style: none;
  padding: 0;
  margin: 18px auto 0;
  display: flex;
  gap: 8px;
  justify-content: center;
}

.shot-dots li {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transition: background-color 300ms ease;
}

.shot-dots li.is-active { background: var(--green); }

.shot-caption {
  text-align: center;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  margin: 10px 0 0;
}

/* On a light ground (the Passport section) the dots and caption invert. */
.split-media .shot-dots li { background: var(--mid-gray); }
.split-media .shot-dots li.is-active { background: var(--green); }
.split-media .shot-caption { color: var(--gray); }

.split-media--phone {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.split-media--phone .phone-frame { max-width: 290px; }

/* .split-media img sets a 4:3 ratio, a radius and a shadow for the photo
   sections. A phone frame inside one must opt out of all three. */
.split-media--phone .phone-frame img {
  aspect-ratio: auto;
  border-radius: 0;
  box-shadow: none;
  height: 100%;
}

/* ---- Image placeholder (used until real assets land) ------------------------ */

.img-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: repeating-linear-gradient(
    45deg,
    var(--mid-gray),
    var(--mid-gray) 10px,
    var(--light-gray) 10px,
    var(--light-gray) 20px
  );
  color: var(--gray);
  font-size: 12px;
  font-weight: 700;
  text-align: center;
  padding: 12px;
  border-radius: inherit;
}

.img-placeholder span {
  background: rgba(255, 255, 255, 0.85);
  padding: 4px 8px;
  border-radius: 6px;
}

/* ---- Core loop steps ----------------------------------------------------------- */

.steps {
  display: grid;
  gap: 28px;
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .steps { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 960px) {
  .steps { grid-template-columns: repeat(4, 1fr); }
}

.step {
  text-align: left;
}

.step-icon {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-md);
  background: var(--mint);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.step-icon svg { width: 28px; height: 28px; color: var(--dark-green); }

.step h3 { margin-bottom: 6px; }

.step p { color: var(--gray); margin: 0; font-size: 15px; }

.step-number {
  font-size: 13px;
  font-weight: 800;
  color: var(--green);
  letter-spacing: 0.06em;
  margin-bottom: 4px;
  display: block;
}

/* Single column on a phone: left-aligned icons above left-aligned text read
   as four loose fragments rather than four steps. Centring gives the column
   one spine. */
@media (max-width: 639px) {
  .step { text-align: center; }
  .step-icon { margin-left: auto; margin-right: auto; }
}

/* ---- Quadrant cards -------------------------------------------------------------- */

.quadrant-grid {
  display: grid;
  gap: 24px;
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .quadrant-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 960px) {
  .quadrant-grid { grid-template-columns: repeat(4, 1fr); }
}

.quadrant-card {
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--white);
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
}

.quadrant-card .quadrant-photo {
  aspect-ratio: 4 / 3;
  width: 100%;
}

.quadrant-card .quadrant-photo img,
.quadrant-card .quadrant-photo .img-placeholder {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0;
}

.quadrant-card-body {
  padding: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.quadrant-card-body p {
  color: var(--gray);
  font-size: 15px;
  margin: 0;
  flex: 1;
}

.quadrant-count {
  font-size: 13px;
  font-weight: 700;
  color: var(--navy);
}

/* Chip — outlined, per quadrant color. Never the sole identifier: text name
   is always present alongside. */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
  border: 1.5px solid currentColor;
  background: transparent;
  width: fit-content;
}

.chip--academic   { color: var(--quad-academic); }
.chip--body-soul  { color: var(--quad-body-soul); }
.chip--creativity { color: var(--quad-creativity); }
.chip--money      { color: var(--quad-money); }

.quadrant-total-line {
  text-align: center;
  margin-top: 32px;
  color: var(--gray);
  font-size: 15px;
}

/* ---- Ranks ladder ------------------------------------------------------------------ */

/* A wrapping grid, not a scrolling row: all 11 ranks must be visible at
   once. A single row of 11 overflows the 1120px container and silently
   clips the last four. */
.rank-ladder {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

@media (min-width: 640px) {
  .rank-ladder {
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
  }
}

@media (min-width: 960px) {
  .rank-ladder {
    grid-template-columns: repeat(6, 1fr);
    gap: 16px;
  }
}

/* Centred at every width. The medal is the thing worth looking at, so it
   sits above the name rather than beside it. */
.rank-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
  padding: 18px 12px;
  border-radius: var(--radius-md);
  background: var(--white);
  box-shadow: var(--shadow-card);
  border-top: 4px solid var(--rank-color, var(--mid-gray));
}

.rank-item img,
.rank-item .img-placeholder {
  width: 64px;
  height: 64px;
  object-fit: contain;
  border-radius: 12px;
  flex-shrink: 0;
}

@media (min-width: 640px) {
  .rank-item img,
  .rank-item .img-placeholder {
    width: 72px;
    height: 72px;
  }
}

.rank-item .rank-name {
  font-weight: 800;
  font-size: 15px;
  color: var(--navy);
}

.rank-item .rank-meta {
  font-size: 12px;
  color: var(--gray);
  font-weight: 600;
}

.rank-item .rank-meta.awarded {
  color: var(--dark-green);
}

/* ---- Badge grid ---------------------------------------------------------------------- */

.badge-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(2, 1fr);
}

@media (min-width: 640px) {
  .badge-grid { grid-template-columns: repeat(4, 1fr); }
}

@media (min-width: 960px) {
  .badge-grid { grid-template-columns: repeat(7, 1fr); }
}

.badge-item {
  text-align: center;
}

/* height:auto is load-bearing. The <img> carries height="120" as an HTML
   attribute, and aspect-ratio only fills in a dimension that is auto — so
   without this the box locks to 146x120 and object-fit:fill squashes the
   512x512 medal art by ~22%. object-fit:contain is the belt-and-braces:
   the art can never distort even if the box ratio drifts. */
.badge-item img,
.badge-item .img-placeholder {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  border-radius: 14px;
  margin-bottom: 10px;
}

.badge-item .badge-name {
  font-weight: 700;
  font-size: 13px;
  color: var(--navy);
  margin-bottom: 4px;
}

.badge-item .badge-desc {
  font-size: 12px;
  color: var(--gray);
  display: none;
  line-height: 1.4;
}

@media (min-width: 960px) {
  .badge-item .badge-desc { display: block; }
}

/* ---- Feature split (Passport / parents / schools) ------------------------------------- */

.split {
  display: grid;
  gap: 40px;
  align-items: center;
}

@media (min-width: 960px) {
  .split { grid-template-columns: 1fr 1fr; gap: 64px; }
  .split.split--reverse .split-media { order: 2; }
}

.split-media img,
.split-media .img-placeholder {
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
}

.split-copy .checklist {
  list-style: none;
  padding: 0;
  margin: 20px 0 28px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.split-copy .checklist li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 15px;
  color: var(--charcoal);
}

.split-copy .checklist svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--green);
  margin-top: 2px;
}

/* ---- Safety strip ---------------------------------------------------------------------- */

.safety-strip {
  position: relative;
  overflow: hidden;
}

.safety-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  object-fit: cover;
  width: 100%;
  height: 100%;
  opacity: 0.5;
}

.safety-strip .container { position: relative; z-index: 1; }

.safety-grid {
  display: grid;
  gap: 24px;
  grid-template-columns: 1fr;
  margin-top: 32px;
}

@media (min-width: 640px) {
  .safety-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 960px) {
  .safety-grid { grid-template-columns: repeat(4, 1fr); }
}

.safety-item {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 22px;
  box-shadow: var(--shadow-card);
}

.safety-item .safety-icon {
  width: 40px;
  height: 40px;
  color: var(--dark-green);
  margin-bottom: 12px;
}

.safety-item p {
  margin: 0;
  font-size: 14.5px;
  color: var(--charcoal);
  font-weight: 600;
}

/* Same reasoning as the steps: one centred column on a phone. The icon is
   an inline SVG, so it needs display:block before auto margins bite. */
@media (max-width: 639px) {
  .safety-item { text-align: center; }
  .safety-item .safety-icon {
    display: block;
    margin-left: auto;
    margin-right: auto;
  }
}

/* ---- FAQ ------------------------------------------------------------------------------- */

.faq-list {
  max-width: 780px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.faq-item {
  background: var(--white);
  border: 1px solid var(--light-gray);
  border-radius: var(--radius-md);
  padding: 4px 20px;
}

.faq-item summary {
  cursor: pointer;
  font-weight: 700;
  font-size: 16px;
  padding: 16px 0;
  color: var(--navy);
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.faq-item summary::-webkit-details-marker { display: none; }

.faq-item summary .chevron {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  transition: transform 0.15s ease;
  color: var(--gray);
}

.faq-item[open] summary .chevron { transform: rotate(180deg); }

.faq-item p {
  color: var(--gray);
  padding-bottom: 18px;
  margin: 0;
  font-size: 15px;
}

/* ---- Final CTA -------------------------------------------------------------------------- */

.final-cta {
  text-align: center;
}

.final-cta .btn-row { justify-content: center; }

/* ---- Footer ----------------------------------------------------------------------------- */

.site-footer {
  background: var(--navy);
  color: rgba(255, 255, 255, 0.75);
  padding: 56px 0 32px;
}

.footer-top {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  justify-content: space-between;
  padding-bottom: 32px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}

.footer-brand {
  max-width: 320px;
}

.footer-brand .brand {
  color: var(--white);
}

.footer-brand p {
  font-size: 14px;
  margin-top: 12px;
  color: rgba(255, 255, 255, 0.65);
}

.footer-links {
  display: flex;
  gap: 56px;
  flex-wrap: wrap;
}

.footer-col h4 {
  color: var(--white);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 14px;
}

.footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-col a {
  text-decoration: none;
  font-size: 14.5px;
  color: rgba(255, 255, 255, 0.75);
}

.footer-col a:hover { color: var(--white); }

.footer-bottom {
  padding-top: 24px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.5);
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
}

/* ---- Legal / content pages ---------------------------------------------------------------- */

.page-hero {
  background: var(--navy-light);
  padding: 56px 0 40px;
}

.page-hero--photo {
  position: relative;
  overflow: hidden;
  color: var(--white);
  padding: 72px 0 48px;
}

.page-hero--photo::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--navy);
  opacity: 0.72;
  z-index: 0;
}

.page-hero--photo .hero-photo-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  object-fit: cover;
  width: 100%;
  height: 100%;
}

.page-hero--photo .container { position: relative; z-index: 1; }

.page-hero--photo h1 { color: var(--white); }

.page-hero--photo .updated { color: rgba(255, 255, 255, 0.8); }

.page-hero h1 { margin-bottom: 8px; }

.page-hero .updated {
  color: var(--gray);
  font-size: 14px;
  font-weight: 600;
}

.legal-layout {
  display: grid;
  gap: 40px;
  max-width: 900px;
  margin: 0 auto;
}

@media (min-width: 768px) {
  .legal-layout { grid-template-columns: 220px 1fr; align-items: start; }
}

.toc {
  position: relative;
  background: var(--light-gray);
  border-radius: var(--radius-md);
  padding: 20px;
}

@media (min-width: 768px) {
  .toc { position: sticky; top: 96px; }
}

.toc h2 {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 12px;
  color: var(--gray);
}

.toc ol {
  list-style: decimal;
  padding-left: 1.1em;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toc a {
  text-decoration: none;
  font-size: 14px;
  color: var(--charcoal);
  font-weight: 600;
}

.toc a:hover { color: var(--green); }

.legal-body {
  max-width: 720px;
}

.legal-body h2 {
  font-size: 21px;
  margin-top: 40px;
  scroll-margin-top: 96px;
}

.legal-body h2:first-of-type { margin-top: 0; }

.legal-body p {
  color: var(--charcoal);
  font-size: 16px;
}

.notice-box {
  background: #FFF7E6;
  border: 1.5px solid #E8C468;
  border-radius: var(--radius-md);
  padding: 18px 20px;
  margin-bottom: 32px;
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.notice-box svg {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  color: #976E00;
  margin-top: 2px;
}

.notice-box p {
  margin: 0;
  font-size: 14.5px;
  color: #5C4405;
  font-weight: 600;
}

.placeholder-fact {
  background: var(--navy-light);
  color: var(--navy);
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.94em;
}

.legal-body .table-scroll {
  overflow-x: auto;
  margin: 20px 0;
}

.legal-body table {
  width: 100%;
  min-width: 640px;
  border-collapse: collapse;
  font-size: 14px;
}

.legal-body th,
.legal-body td {
  text-align: left;
  vertical-align: top;
  padding: 10px 12px;
  border: 1px solid #E5E5E5;
  color: var(--charcoal);
}

.legal-body th {
  background: var(--navy-light);
  color: var(--navy);
  font-weight: 700;
}

/* ---- Contact page ------------------------------------------------------------------------- */

.contact-routes {
  display: grid;
  gap: 20px;
  grid-template-columns: 1fr;
  margin-bottom: 56px;
}

@media (min-width: 768px) {
  .contact-routes { grid-template-columns: repeat(3, 1fr); }
}

.contact-route {
  display: block;
  text-decoration: none;
  background: var(--white);
  border: 1.5px solid var(--light-gray);
  border-radius: var(--radius-md);
  padding: 24px;
  transition: border-color 0.15s ease, transform 0.1s ease;
}

.contact-route:hover {
  border-color: var(--green);
  transform: translateY(-2px);
}

.contact-route .route-icon {
  width: 32px;
  height: 32px;
  color: var(--dark-green);
  margin-bottom: 14px;
}

.contact-route h3 { margin-bottom: 6px; }

.contact-route p {
  color: var(--gray);
  font-size: 14px;
  margin: 0;
}

.contact-form-wrap {
  max-width: 640px;
  margin: 0 auto;
  background: var(--light-gray);
  border-radius: var(--radius-lg);
  padding: 32px;
}

@media (min-width: 640px) {
  .contact-form-wrap { padding: 40px; }
}

.form-note {
  font-size: 14px;
  color: var(--gray);
  margin-bottom: 24px;
}

.field {
  margin-bottom: 18px;
}

.field label {
  display: block;
  font-weight: 700;
  font-size: 14px;
  color: var(--navy);
  margin-bottom: 6px;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--mid-gray);
  background: var(--white);
  font-family: inherit;
  font-size: 15px;
  color: var(--charcoal);
}

.field textarea {
  min-height: 140px;
  resize: vertical;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--green);
}

.form-response {
  margin-top: 16px;
  font-size: 14px;
  color: var(--dark-green);
  font-weight: 700;
  display: none;
}

.form-response.visible { display: block; }

.contact-meta {
  max-width: 640px;
  margin: 40px auto 0;
  text-align: center;
  color: var(--gray);
  font-size: 14px;
}

.contact-meta p { margin-bottom: 6px; }

/* ---- Facility application page ------------------------------------------ */
.apply-steps {
  max-width: 760px;
  margin: 0 auto 40px;
}

.apply-steps ol {
  margin: 0;
  padding-left: 22px;
  color: var(--charcoal);
}

.apply-steps li {
  margin-bottom: 8px;
  line-height: 1.55;
}

.contact-form-wrap--wide { max-width: 760px; }

.form-group {
  border: 0;
  border-top: 1.5px solid var(--mid-gray);
  margin: 0 0 28px;
  padding: 24px 0 0;
}

.form-group:first-of-type {
  border-top: 0;
  padding-top: 0;
}

.form-group legend {
  font-weight: 800;
  font-size: 16px;
  color: var(--navy);
  padding: 0;
  margin-bottom: 14px;
}

.form-hint {
  font-size: 13px;
  color: var(--gray);
  margin: -4px 0 16px;
  line-height: 1.5;
}

.field .req { font-weight: 400; color: var(--gray); font-size: 12px; }
.field .opt { font-weight: 400; color: var(--gray); font-size: 12px; }

.gm-row {
  display: grid;
  gap: 0 16px;
}

@media (min-width: 640px) {
  .gm-row { grid-template-columns: 1fr 1fr; }
}

.check {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-bottom: 12px;
  font-size: 14px;
  color: var(--charcoal);
  line-height: 1.5;
}

.check input {
  margin-top: 3px;
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  accent-color: var(--green);
}

.btn--sm {
  padding: 8px 16px;
  font-size: 14px;
}
