/*
 * theme.css — Core Bikers Bhopal. Opens DARK: a charcoal-black workshop ground,
 * bone-white type and one signal red, like a race-paddock poster. The light set
 * is a warm paper ground for daylight reading, not the dark one inverted.
 * Reference: Royal Enfield's editorial pages crossed with a Rapha club page —
 * condensed industrial display type, hard edges, photography doing the talking.
 *
 * Own tokens (--x-*): text set over photographs stays light in both modes, and
 * the dark statement band stays dark in both modes.
 */

:root {
  color-scheme: dark;
  --canvas: #0d0d0e;
  --surface: #161618;
  --surface-2: #1f1f22;
  --border: #2c2c30;
  --border-strong: #4a4a50;
  --ink: #f3f0ea;
  --muted: #a6a29b;
  --accent: #d42a1f;
  --accent-hover: #b31f16;
  --accent-ink: #ffffff;
  --accent-text: #ff5d50;
  --accent-strong: #ff9a90;
  --accent-soft: #2b1210;
  --accent-border: #5e1d17;
  --success: #1f8a4c;
  --success-ink: #ffffff;
  --success-soft: #11261a;
  --success-strong: #6fd09a;
  --warning: #b8650b;
  --warning-ink: #ffffff;
  --warning-soft: #2c1f0e;
  --warning-strong: #f0b46a;
  --danger: #c4261b;
  --danger-ink: #ffffff;
  --danger-soft: #2c1210;
  --danger-strong: #ff8d84;
  --chart-1: #d42a1f;
  --chart-2: #c8c4bc;
  --chart-3: #8a8f99;
  --chart-4: #e08a3c;
  --chart-5: #5f8fb3;
  --chart-6: #7b6aa8;

  --font-display: "Big Shoulders Display", "Archivo", Impact, sans-serif;
  --font-body: "Archivo", ui-sans-serif, system-ui, sans-serif;
  --font-sans: "Archivo", ui-sans-serif, system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --display-weight: 800;
  --display-tracking: -0.005em;
  --eyebrow-tracking: 0.22em;

  --radius-btn: 2px;
  --radius-card: 2px;
  --radius-input: 2px;
  --border-w: 1px;
  --border-strong-w: 1px;
  --shadow-card: none;
  --shadow-btn: none;
  --shadow-raised: 0 24px 60px rgba(0, 0, 0, 0.55);
  --card-pad: 1.75rem;
  --caps: uppercase;
  --caps-tracking: 0.12em;
  --btn-weight: 700;
  --measure: 66ch;
  --gradient-hero: linear-gradient(180deg, rgba(0, 0, 0, 0.6) 0%, rgba(0, 0, 0, 0.2) 38%, rgba(0, 0, 0, 0.9) 100%);

  --x-on-photo: #f7f4ee;
  --x-on-photo-muted: #d6d1c8;
  --x-photo-accent: #ff5144;
  --x-band-bg: #050505;
  --x-band-ink: #f3f0ea;
  --x-band-muted: #a6a29b;
  --x-band-border: #2a2a2d;
}

html[data-theme="light"] {
  color-scheme: light;
  --canvas: #f4f1eb;
  --surface: #ffffff;
  --surface-2: #e9e5dd;
  --border: #d8d3c9;
  --border-strong: #9f998e;
  --ink: #151413;
  --muted: #5c5851;
  --accent: #c0211a;
  --accent-hover: #9c1912;
  --accent-ink: #ffffff;
  --accent-text: #a8180f;
  --accent-strong: #86140d;
  --accent-soft: #fbe3df;
  --accent-border: #eeaaa3;
  --success: #17733e;
  --success-ink: #ffffff;
  --success-soft: #dcefe3;
  --success-strong: #125f33;
  --warning: #a35608;
  --warning-ink: #ffffff;
  --warning-soft: #f6e7d3;
  --warning-strong: #7f4306;
  --danger: #b91c1c;
  --danger-ink: #ffffff;
  --danger-soft: #f8e0de;
  --danger-strong: #9a1717;
  --chart-1: #c0211a;
  --chart-2: #3d3a35;
  --chart-3: #7a7f88;
  --chart-4: #c0701e;
  --chart-5: #3f6f93;
  --chart-6: #5f4f8c;
  --shadow-raised: 0 24px 60px rgba(0, 0, 0, 0.18);

  --x-on-photo: #f7f4ee;
  --x-on-photo-muted: #e2ddd4;
  --x-photo-accent: #ff5144;
  --x-band-bg: #141312;
  --x-band-ink: #f3f0ea;
  --x-band-muted: #b3aea5;
  --x-band-border: #34322f;
}

/*
 * app.css — Core Bikers Bhopal's own surfaces: the bar, the cinematic hero,
 * the member ticker, the editorial destination layouts, the application form
 * and the admin shell. Tokens only.
 *
 * Motion is limited to three things: the hero photo's slow settle, the member
 * ticker, and the bar tucking away while you scroll down. All three stop under
 * reduced motion.
 */

/* ---- Base type ------------------------------------------------------------ */
body.site, .admin, .auth { font-family: var(--font-body); }
.display, .font-display {
  font-family: var(--font-display);
  font-weight: var(--display-weight);
  text-transform: uppercase;
  letter-spacing: var(--display-tracking);
  line-height: 0.92;
}
.kicker {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: var(--eyebrow-tracking);
  color: var(--accent-text);
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.kicker::before { content: ""; width: 2rem; height: 2px; background: var(--accent); }
.meta-line { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.16em; color: var(--muted); }
.skip-link { position: absolute; left: -999px; top: 0.5rem; z-index: 100; background: var(--accent); color: var(--accent-ink); padding: 0.5rem 1rem; }
.skip-link:focus { left: 0.5rem; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.req { color: var(--danger-strong); margin-left: 0.125rem; }

/* ---- Emblem and wordmark --------------------------------------------------- */
.emblem-road { fill: var(--accent); }
.emblem-dash { fill: var(--canvas); }
.wordmark { display: flex; flex-direction: column; line-height: 1; min-width: 0; }
.wordmark-name { font-family: var(--font-display); font-weight: 900; text-transform: uppercase; font-size: 1.35rem; letter-spacing: 0.02em; white-space: nowrap; }
.wordmark-sub { margin-top: 0.2rem; display: flex; align-items: center; gap: 0.4rem; font-size: 0.625rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.24em; color: var(--muted); white-space: nowrap; }
.wordmark-dot { width: 4px; height: 4px; background: var(--accent); transform: rotate(45deg); }
.wordmark-lg .wordmark-name { font-size: 2.25rem; }
.wordmark-lg .wordmark-sub { font-size: 0.75rem; }

/* ---- The bar: solid, sticky, tucks away on scroll down --------------------- */
.site-bar {
  position: sticky; top: 0; z-index: 40;
  background: var(--canvas);
  border-bottom: 1px solid var(--border);
  transition: transform 260ms var(--ease-out, ease-out);
}
.site-bar.is-tucked { transform: translateY(-100%); }
.nav-link {
  position: relative; font-size: 0.8125rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.14em; color: var(--muted);
  padding: 0.5rem 0;
}
.nav-link:hover, .nav-link[aria-current="page"] { color: var(--ink); text-decoration: none; }
.nav-link[aria-current="page"]::after { content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 2px; background: var(--accent); }
.nav-drawer { position: relative; }
.nav-drawer > summary { list-style: none; }
.nav-drawer > summary::-webkit-details-marker { display: none; }
.nav-drawer-panel {
  position: fixed; left: 0; right: 0; top: 4rem; z-index: 50;
  background: var(--canvas); border-bottom: 1px solid var(--border);
  padding: 1.5rem 1rem 2rem; box-shadow: var(--shadow-raised);
}
.drawer-link {
  font-family: var(--font-display); font-weight: 800; text-transform: uppercase; font-size: 2rem; line-height: 1;
  padding: 0.75rem 0; border-bottom: 1px solid var(--border); color: var(--ink);
}
.drawer-link:hover { color: var(--accent-text); text-decoration: none; }

/* ---- Hero -------------------------------------------------------------------- */
.hero { position: relative; min-height: max(36rem, calc(100svh - 4rem)); overflow: hidden; color: var(--x-on-photo); display: flex; }
.hero-photo, .join-band-photo, .dest-hero-photo { position: absolute; inset: 0; overflow: hidden; }
.hero-photo img, .join-band-photo img, .dest-hero-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hero-photo img { transform-origin: 60% 40%; animation: hero-settle 16s cubic-bezier(0.2, 0.6, 0.2, 1) both; }
@keyframes hero-settle { from { transform: scale(1.12); } to { transform: scale(1); } }
.hero-shade { position: absolute; inset: 0; background: var(--gradient-hero); }
.hero-inner { position: relative; width: 100%; }
.hero-tag {
  display: flex; align-items: center; gap: 1rem; font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.3em;
  color: var(--x-on-photo-muted);
}
.hero-bar { width: 2.5rem; height: 2px; background: var(--x-photo-accent); }
.hero-title { font-size: clamp(3.75rem, 13vw, 11rem); line-height: 0.86; color: var(--x-on-photo); }
.hero-title .text-accent-text { color: var(--x-photo-accent); }
.hero-lead { font-size: 1.25rem; line-height: 1.5; color: var(--x-on-photo-muted); max-width: 36rem; }
.btn-hero-ghost { background: transparent; color: var(--x-on-photo); border-color: color-mix(in srgb, var(--x-on-photo) 60%, transparent); }
.btn-hero-ghost:hover { background: rgba(255, 255, 255, 0.12); border-color: var(--x-on-photo); color: var(--x-on-photo); }

/* ---- Member ticker -------------------------------------------------------------- */
.ticker { position: relative; background: var(--x-band-bg); color: var(--x-band-ink); border-top: 2px solid var(--accent); border-bottom: 1px solid var(--x-band-border); }
.ticker-viewport { overflow: hidden; padding: 1.35rem 0; mask-image: linear-gradient(90deg, transparent, black 6%, black 94%, transparent); }
.ticker-track { display: flex; width: max-content; animation: ticker var(--ticker-duration, 40s) linear infinite; will-change: transform; }
.ticker-group { display: flex; align-items: center; gap: 2.5rem; padding-right: 2.5rem; flex-shrink: 0; }
.ticker-item { display: flex; align-items: center; gap: 2.5rem; white-space: nowrap; font-family: var(--font-display); font-weight: 800; text-transform: uppercase; font-size: clamp(1.5rem, 3.4vw, 2.5rem); line-height: 1; }
.ticker-sep { width: 0.6rem; height: 0.6rem; background: var(--accent); transform: rotate(45deg); flex-shrink: 0; }
.ticker:hover .ticker-track, .ticker.is-paused .ticker-track { animation-play-state: paused; }
.ticker-empty .ticker-item { color: var(--x-band-muted); }
.ticker-empty .ticker-item:nth-child(2n) { color: var(--x-band-ink); }
.ticker-cover { position: absolute; inset: 0; z-index: 1; }
.ticker-cover:focus-visible { outline: 2px solid var(--accent); outline-offset: -4px; }
@keyframes ticker { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(-50%, 0, 0); } }

/* ---- Sections ------------------------------------------------------------------ */
.band-dark { background: var(--x-band-bg); color: var(--x-band-ink); }
.band-dark .text-muted { color: var(--x-band-muted); }
.band-tint { background: var(--surface-2); }
.page-hero { border-bottom: 1px solid var(--border); }
.caption-row { display: flex; justify-content: space-between; gap: 1rem; padding-top: 0.75rem; font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.16em; color: var(--muted); border-top: 1px solid var(--border); margin-top: 0.75rem; }
.about-copy p + p { margin-top: 1.25rem; }
.mission-list { display: grid; gap: 0; border-top: 1px solid var(--border); }
.mission-list > div { display: grid; gap: 0.5rem; padding: 1.5rem 0; border-bottom: 1px solid var(--border); }
@media (min-width: 640px) { .mission-list > div { grid-template-columns: 12rem 1fr; gap: 2rem; } }
.mission-list dt { font-family: var(--font-display); font-weight: 800; text-transform: uppercase; font-size: 1.5rem; line-height: 1; }
.mission-list dd { color: var(--muted); }

.values-grid { display: grid; grid-template-columns: 1fr; border-top: 1px solid var(--x-band-border); }
@media (min-width: 768px) { .values-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1200px) { .values-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.value { padding: 2.25rem 0; border-bottom: 1px solid var(--x-band-border); }
@media (min-width: 768px) { .value { padding: 2.5rem 2rem 2.5rem 0; } .value + .value { padding-left: 2rem; border-left: 1px solid var(--x-band-border); } }
@media (min-width: 768px) and (max-width: 1199px) { .value:nth-child(3) { padding-left: 0; border-left: 0; } }
.value-ic { display: inline-grid; place-items: center; width: 3rem; height: 3rem; border: 1px solid var(--accent); color: var(--accent-text); }
.band-dark .value-ic { color: var(--x-photo-accent); }

/* ---- Destinations ----------------------------------------------------------------- */
.feature-dest { display: grid; border: 1px solid var(--border); background: var(--surface); color: var(--ink); }
.feature-dest:hover { text-decoration: none; border-color: var(--border-strong); }
@media (min-width: 900px) { .feature-dest { grid-template-columns: 1.6fr 1fr; } }
.feature-dest-media { position: relative; min-height: 22rem; overflow: hidden; }
@media (min-width: 900px) { .feature-dest-media { min-height: 32rem; } }
.feature-dest-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 600ms var(--ease-out, ease-out); }
.feature-dest:hover .feature-dest-media img { transform: scale(1.03); }
.feature-dest-copy { padding: 2rem; display: flex; flex-direction: column; justify-content: flex-end; }
@media (min-width: 900px) { .feature-dest-copy { padding: 3rem; } }
.dest-grid { display: grid; grid-template-columns: 1fr; gap: 1.5rem; }
@media (min-width: 700px) { .dest-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .dest-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.dest-card { min-width: 0; }
.dest-card-link { display: flex; flex-direction: column; height: 100%; border: 1px solid var(--border); background: var(--surface); color: var(--ink); }
.dest-card-link:hover { text-decoration: none; border-color: var(--border-strong); }
.dest-card-media { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: var(--surface-2); }
.dest-card-media img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 600ms var(--ease-out, ease-out); }
.dest-card-link:hover .dest-card-media img { transform: scale(1.04); }
.dest-card-body { padding: 1.5rem; display: flex; flex-direction: column; flex: 1; }
.dest-card-body > div:last-child { margin-top: auto; }
.photo-flag { position: absolute; left: 0.75rem; bottom: 0.75rem; background: rgba(0, 0, 0, 0.7); color: var(--x-on-photo); font-size: 0.6875rem; font-weight: 600; letter-spacing: 0.06em; padding: 0.25rem 0.5rem; }
.filter-row { display: flex; gap: 0.5rem; overflow-x: auto; padding-bottom: 0.25rem; scrollbar-width: none; }
.filter-row::-webkit-scrollbar { display: none; }
.filter-row .chip { flex-shrink: 0; text-transform: uppercase; letter-spacing: 0.1em; font-size: 0.75rem; font-weight: 700; }

.dest-hero { position: relative; min-height: 34rem; height: 72svh; max-height: 46rem; color: var(--x-on-photo); overflow: hidden; }
.dest-hero .hero-title { font-size: clamp(3rem, 9vw, 8rem); }
.back-link { display: inline-flex; align-items: center; gap: 0.5rem; font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.16em; color: inherit; opacity: 0.85; }
.back-link:hover { opacity: 1; text-decoration: none; }
.caption-strip { background: var(--x-band-bg); color: var(--x-band-muted); font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.16em; }
.note-stack { display: flex; flex-direction: column; gap: 1rem; }
.note { border-left: 3px solid var(--border-strong); padding: 0.25rem 0 0.25rem 1.25rem; }
.note-safety { border-left-color: var(--accent); }
.note-head { display: flex; align-items: center; gap: 0.5rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; font-size: 0.8125rem; margin-bottom: 0.5rem; }
.note p:last-child { color: var(--muted); }
.facts { display: grid; gap: 0; }
.fact { display: grid; gap: 0.25rem; padding: 1rem 0; border-bottom: 1px solid var(--border); }
.fact:first-child { padding-top: 0; }
.fact dt { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.16em; color: var(--muted); }
.fact dd { font-size: 1.125rem; }
.facts-wide { border-top: 1px solid var(--border); }
@media (min-width: 640px) { .facts-wide { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 2rem; } .facts-wide .fact:first-child { padding-top: 1rem; } }
.mini-ride { display: flex; justify-content: space-between; gap: 1rem; padding: 0.875rem 1rem; border: 1px solid var(--border); background: var(--surface); color: var(--ink); }
.mini-ride:hover { border-color: var(--accent); text-decoration: none; }

/* ---- Rides ---------------------------------------------------------------------------- */
.ride-list { display: flex; flex-direction: column; border-top: 1px solid var(--border); }
.ride-row { display: grid; grid-template-columns: 4.5rem minmax(0, 1fr); gap: 1.25rem; align-items: center; padding: 1.5rem 0; border-bottom: 1px solid var(--border); }
.ride-row .ride-thumb, .ride-row .ride-cta { display: none; }
@media (min-width: 900px) {
  .ride-row { grid-template-columns: 5.5rem 11rem minmax(0, 1fr) auto; gap: 2rem; }
  .ride-row .ride-thumb { display: block; aspect-ratio: 4 / 3; }
  .ride-row .ride-cta { display: inline-flex; }
}
.ride-date { display: flex; flex-direction: column; align-items: center; justify-content: center; border: 1px solid var(--border-strong); padding: 0.6rem 0; }
.ride-day { font-family: var(--font-display); font-weight: 900; font-size: 2.5rem; line-height: 0.9; }
.ride-mon { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.2em; color: var(--accent-text); }
.ride-row.is-cancelled h3 { text-decoration: line-through; text-decoration-thickness: 2px; color: var(--muted); }
.empty-ride { display: flex; flex-direction: column; gap: 1.5rem; padding: 2rem; border: 1px dashed var(--border-strong); background: var(--surface); }
@media (min-width: 900px) { .empty-ride { flex-direction: row; align-items: center; padding: 2.5rem; } .empty-ride > div { flex: 1; } }
.empty-ride .empty-art, .empty-art { display: inline-grid; place-items: center; width: 3.5rem; height: 3.5rem; flex-shrink: 0; background: var(--accent-soft); color: var(--accent-strong); }

/* ---- Gallery ------------------------------------------------------------------------------ */
.gallery-grid { columns: 1; column-gap: 1rem; }
@media (min-width: 600px) { .gallery-grid { columns: 2; } }
@media (min-width: 1000px) { .gallery-grid { columns: 3; } }
.gallery-item { break-inside: avoid; margin-bottom: 1rem; }
.gallery-open { display: block; width: 100%; padding: 0; border: 0; background: var(--surface-2); cursor: zoom-in; overflow: hidden; }
.gallery-open img { width: 100%; height: auto; display: block; transition: transform 500ms var(--ease-out, ease-out); }
.gallery-open:hover img { transform: scale(1.03); }
.gallery-open:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.gallery-cap { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; padding-top: 0.5rem; font-size: 0.875rem; color: var(--muted); }
.empty-gallery { display: grid; gap: 2.5rem; align-items: center; padding: 2.5rem; border: 1px dashed var(--border-strong); }
@media (min-width: 900px) { .empty-gallery { grid-template-columns: 22rem 1fr; } }
.empty-gallery-frames { position: relative; height: 12rem; }
.empty-gallery-frames span { position: absolute; width: 9rem; height: 11rem; border: 1px solid var(--border-strong); background: var(--surface); }
.empty-gallery-frames span:nth-child(1) { left: 0; top: 0.75rem; transform: rotate(-6deg); }
.empty-gallery-frames span:nth-child(2) { left: 5.5rem; top: 0; transform: rotate(3deg); background: var(--surface-2); }
.empty-gallery-frames span:nth-child(3) { left: 11rem; top: 1rem; transform: rotate(-2deg); border-color: var(--accent); }
.lightbox { margin: auto; max-width: min(72rem, calc(100vw - 2rem)); max-height: calc(100vh - 2rem); padding: 0; border: 0; background: transparent; color: var(--x-on-photo); overflow: visible; }
.lightbox::backdrop { background: rgba(0, 0, 0, 0.88); }
.lightbox img { max-width: 100%; max-height: calc(100vh - 7rem); display: block; margin: 0 auto; }
.lightbox-cap { margin-top: 0.75rem; text-align: center; color: var(--x-on-photo-muted); }
.lightbox-close { position: absolute; top: -3rem; right: 0; color: var(--x-on-photo); }

/* ---- Join band, rules, contact, closing ---------------------------------------------- */
.join-band { position: relative; overflow: hidden; color: var(--x-on-photo); }
.join-band-shade { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(0, 0, 0, 0.88) 0%, rgba(0, 0, 0, 0.6) 55%, rgba(0, 0, 0, 0.35) 100%); }
.join-band .hero-title { font-size: clamp(3.25rem, 10vw, 8.5rem); }
.join-steps { display: flex; flex-direction: column; gap: 0.75rem; color: var(--x-on-photo-muted); font-size: 1.0625rem; }
.join-steps li { display: flex; align-items: center; gap: 1rem; }
.join-steps span { display: inline-grid; place-items: center; width: 2rem; height: 2rem; flex-shrink: 0; border: 1px solid var(--x-photo-accent); color: var(--x-on-photo); font-weight: 700; font-size: 0.875rem; }
.rule-list { border-top: 1px solid var(--border); }
.rule-list li { display: flex; align-items: baseline; gap: 1.5rem; padding: 1.25rem 0; border-bottom: 1px solid var(--border); font-size: 1.25rem; }
.rule-num { font-family: var(--font-mono); font-size: 0.875rem; color: var(--accent-text); flex-shrink: 0; }
.form-panel { background: var(--surface); border: 1px solid var(--border); padding: 1.5rem; }
@media (min-width: 768px) { .form-panel { padding: 2.25rem; } }
.contact-row { display: flex; gap: 1rem; padding: 1.25rem 0; border-bottom: 1px solid var(--border); }
.contact-row:first-child { border-top: 1px solid var(--border); }
.contact-ic { display: inline-grid; place-items: center; width: 2.5rem; height: 2.5rem; flex-shrink: 0; background: var(--accent-soft); color: var(--accent-strong); }
.closing { border-top: 1px solid var(--border); }
.closing-title { font-size: clamp(3rem, 9vw, 8.5rem); line-height: 0.9; max-width: 14ch; }

/* ---- Footer -------------------------------------------------------------------------- */
.site-footer { background: var(--x-band-bg); color: var(--x-band-ink); border-top: 2px solid var(--accent); }
.site-footer .text-muted, .site-footer a:not(.btn) { color: var(--x-band-muted); }
.site-footer a:not(.btn):hover { color: var(--x-band-ink); }
.site-footer .wordmark-sub { color: var(--x-band-muted); }
.site-footer .emblem-dash { fill: var(--x-band-bg); }
.site-footer .border-border { border-color: var(--x-band-border); }
.foot-head { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.2em; color: var(--x-band-ink); margin-bottom: 1rem; }

/* ---- Application form ---------------------------------------------------------------- */
.join-index { position: sticky; top: 6rem; display: flex; flex-direction: column; border-top: 1px solid var(--border); }
.join-index a { display: flex; gap: 0.75rem; padding: 0.9rem 0; border-bottom: 1px solid var(--border); color: var(--muted); font-weight: 600; font-size: 0.9375rem; }
.join-index a span { font-family: var(--font-mono); color: var(--accent-text); font-size: 0.8125rem; }
.join-index a:hover, .join-index a.is-current { color: var(--ink); text-decoration: none; }
.join-section { border: 0; padding: 0; margin: 0; min-width: 0; padding-top: 3rem; scroll-margin-top: 5rem; }
.join-section + .join-section { border-top: 1px solid var(--border); margin-top: 3rem; }
.join-section-head { display: flex; gap: 1.25rem; align-items: flex-start; }
.join-num { font-family: var(--font-display); font-weight: 900; font-size: 3.5rem; line-height: 0.8; color: var(--accent-text); }
.join-section-body { margin-top: 2rem; }
.why-box, .privacy-note { border: 1px solid var(--border); background: var(--surface); padding: 1.25rem 1.5rem; }
.privacy-note { border-left: 3px solid var(--accent); }
.choice-grid { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.choice { position: relative; display: inline-flex; cursor: pointer; }
.choice input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.choice span { display: inline-flex; align-items: center; min-height: 2.5rem; padding: 0 1rem; border: 1px solid var(--border-strong); background: var(--surface); color: var(--ink); font-weight: 600; font-size: 0.9375rem; transition: background-color 150ms, border-color 150ms; }
.choice:hover span { border-color: var(--ink); }
.choice input:checked + span { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.choice input:focus-visible + span { box-shadow: var(--ring); }
.choice-invalid span { border-color: var(--danger); }
.upload { border: 1px solid var(--border); background: var(--surface); padding: 1.25rem; min-width: 0; display: flex; flex-direction: column; }
.upload.is-invalid { border-color: var(--danger); }
.upload-ic { display: inline-grid; place-items: center; width: 2.5rem; height: 2.5rem; flex-shrink: 0; background: var(--surface-2); color: var(--accent-text); }
.upload-drop { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.35rem; min-height: 7.5rem; border: 1px dashed var(--border-strong); text-align: center; padding: 1rem; transition: border-color 150ms, background-color 150ms; }
.upload-drop:hover, .upload-drop.is-over { border-color: var(--accent); background: var(--accent-soft); }
.upload-input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.upload-input:focus-visible + .upload-cta { outline: 2px solid var(--accent); outline-offset: 4px; }
.upload-cta { display: inline-flex; align-items: center; gap: 0.5rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.12em; font-size: 0.8125rem; }
.upload-limit { font-size: 0.8125rem; color: var(--muted); }
.upload.has-file .upload-drop { display: none; }
.upload-preview { margin-top: 1rem; display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap; }
.upload-preview[hidden] { display: none; }
.upload-thumb { width: 4rem; height: 4rem; flex-shrink: 0; background: var(--surface-2); display: grid; place-items: center; overflow: hidden; color: var(--muted); }
.upload-thumb img { width: 100%; height: 100%; object-fit: cover; }
.consent-list { display: flex; flex-direction: column; gap: 0.75rem; }
.consent-list .check { align-items: flex-start; padding: 1rem 1.25rem; border: 1px solid var(--border); background: var(--surface); }
.consent-list .check input { margin-top: 0.2rem; width: 1.1rem; height: 1.1rem; accent-color: var(--accent); flex-shrink: 0; }
.check input[type="checkbox"] { accent-color: var(--accent); width: 1.1rem; height: 1.1rem; flex-shrink: 0; }
.submit-bar { margin-top: 3rem; padding-top: 2rem; border-top: 2px solid var(--ink); display: flex; flex-direction: column; gap: 1.25rem; }
.upload-progress[hidden] { display: none; }
[data-error-for]:not([hidden]) { margin-top: 0.25rem; }

.received-ic { display: inline-grid; place-items: center; width: 4.5rem; height: 4.5rem; background: var(--accent); color: var(--accent-ink); }
.received-ic .icon { width: 2.25rem; height: 2.25rem; }
.ref-box { border: 1px solid var(--border-strong); border-left: 4px solid var(--accent); background: var(--surface); padding: 1.5rem 1.75rem; }
.ref-code { font-family: var(--font-mono); font-size: clamp(1.5rem, 5vw, 2.5rem); letter-spacing: 0.06em; }

/* ---- Guidelines ---------------------------------------------------------------------- */
.guide-grid { display: grid; grid-template-columns: 1fr; border-top: 1px solid var(--border); border-left: 1px solid var(--border); }
@media (min-width: 700px) { .guide-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .guide-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.guide { padding: 2rem; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); }

/* ---- Admin shell --------------------------------------------------------------------- */
.admin { min-height: 100vh; }
.admin-side { display: none; }
.admin-top { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; justify-content: space-between; height: 4rem; padding: 0 1rem; background: var(--canvas); border-bottom: 1px solid var(--border); }
.admin-main { padding: 1.5rem 1rem 4rem; min-width: 0; }
@media (min-width: 1024px) {
  .admin { display: grid; grid-template-columns: 16rem minmax(0, 1fr); }
  .admin-top { display: none; }
  .admin-side { display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; padding: 1.5rem 1rem; border-right: 1px solid var(--border); background: var(--surface); }
  .admin-main { padding: 2.5rem 2.5rem 5rem; }
}
.admin-link { display: flex; align-items: center; gap: 0.75rem; padding: 0.6rem 0.75rem; font-weight: 600; font-size: 0.9375rem; color: var(--muted); border-left: 2px solid transparent; }
.admin-link:hover { color: var(--ink); background: var(--surface-2); text-decoration: none; }
.admin-link[aria-current="page"] { color: var(--ink); border-left-color: var(--accent); background: var(--surface-2); }
.stat-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; background: var(--border); border: 1px solid var(--border); }
@media (min-width: 900px) { .stat-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1400px) { .stat-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); } }
.stat-tile { display: flex; flex-direction: column; gap: 0.5rem; padding: 1.25rem; background: var(--surface); color: var(--ink); }
.stat-tile:hover { background: var(--surface-2); text-decoration: none; }
.stat-num { font-family: var(--font-display); font-weight: 900; font-size: 3rem; line-height: 0.9; }
.stat-label { font-size: 0.8125rem; color: var(--muted); }
.stat-tile.is-hot .stat-num { color: var(--accent-text); }
.activity li { padding: 0.875rem 1.5rem; border-bottom: 1px solid var(--border); }
.activity li:last-child { border-bottom: 0; }
.filter-bar { display: grid; grid-template-columns: 1fr; gap: 1rem; padding: 1.25rem; border: 1px solid var(--border); background: var(--surface); }
@media (min-width: 900px) { .filter-bar { grid-template-columns: 2fr 1.5fr 1fr 1fr auto; align-items: end; } }
.kv { display: grid; grid-template-columns: 1fr; margin-top: 1rem; }
@media (min-width: 640px) { .kv { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 2rem; } }
.kv > div { padding: 0.75rem 0; border-bottom: 1px solid var(--border); min-width: 0; }
.kv dt { font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.1em; color: var(--muted); }
.kv dd { margin-top: 0.25rem; overflow-wrap: anywhere; }
.file-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr)); gap: 1rem; }
.file-card { display: flex; flex-direction: column; gap: 0.35rem; min-width: 0; }
.file-thumb { display: grid; place-items: center; aspect-ratio: 4 / 3; background: var(--surface-2); border: 1px solid var(--border); overflow: hidden; color: var(--muted); }
.file-thumb img { width: 100%; height: 100%; object-fit: cover; }
.file-card.is-gone .file-thumb { border-style: dashed; }
.intro-quote { margin-top: 1.25rem; border-left: 3px solid var(--accent); padding-left: 1rem; color: var(--muted); white-space: pre-line; }
.review-grid { display: grid; grid-template-columns: 1fr; gap: 1.25rem; }
@media (min-width: 700px) { .review-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1300px) { .review-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.auth { min-height: 100vh; display: grid; place-items: center; padding: 2rem 1rem; background: var(--canvas); }
.auth-card { width: 100%; max-width: 28rem; background: var(--surface); border: 1px solid var(--border); border-top: 3px solid var(--accent); padding: 2rem; }

/* ---- Reduced motion ------------------------------------------------------------------- */
html.reduced-motion .hero-photo img { animation: none; }
html.reduced-motion .ticker-track { animation: none; }
html.reduced-motion .ticker-viewport { overflow-x: auto; mask-image: none; }
html.reduced-motion .site-bar { transition: none; }
@media (prefers-reduced-motion: reduce) {
  .hero-photo img, .ticker-track { animation: none; }
  .ticker-viewport { overflow-x: auto; mask-image: none; }
}
