/* Self-hosted fonts (Google Fonts, OFL license) — no third-party CDN calls */
@font-face { font-family: 'Cormorant Garamond'; font-style: italic; font-weight: 400; font-display: swap; src: url("../fonts/cormorant-garamond-latin-400-italic.3e2c4175a96d.woff2") format('woff2'); }
@font-face { font-family: 'Cormorant Garamond'; font-style: italic; font-weight: 500; font-display: swap; src: url("../fonts/cormorant-garamond-latin-500-italic.3e2c4175a96d.woff2") format('woff2'); }
@font-face { font-family: 'Cormorant Garamond'; font-style: normal; font-weight: 400; font-display: swap; src: url("../fonts/cormorant-garamond-latin-400.c47ff12887a3.woff2") format('woff2'); }
@font-face { font-family: 'Cormorant Garamond'; font-style: normal; font-weight: 500; font-display: swap; src: url("../fonts/cormorant-garamond-latin-500.c47ff12887a3.woff2") format('woff2'); }
@font-face { font-family: 'Cormorant Garamond'; font-style: normal; font-weight: 600; font-display: swap; src: url("../fonts/cormorant-garamond-latin-600.c47ff12887a3.woff2") format('woff2'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 400; font-display: swap; src: url("../fonts/inter-latin-400.260c81a4759b.woff2") format('woff2'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 500; font-display: swap; src: url("../fonts/inter-latin-500.260c81a4759b.woff2") format('woff2'); }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 600; font-display: swap; src: url("../fonts/inter-latin-600.260c81a4759b.woff2") format('woff2'); }
/* ============================================================
   Luca & Nasrin — wedding memory wall
   Warm, luminous, classical, romantic. Ivory paper + aubergine
   ink + agapanthus lavender + antique gold.
   ============================================================ */

:root {
  --paper: #FBF8F3;
  --paper-deep: #F3EDE3;
  --ink: #2E2A3B;
  --ink-soft: #4A4458;
  --lavender: #8E7CC3;
  --lavender-tint: #C9BFE4;
  --gold: #C6A15B;
  --gold-soft: #E2CDA4;
  --sage: #8A9A7B;
  --terracotta: #B5654A;
  --white: #FFFFFF;
  --shadow: 0 12px 40px rgba(46, 42, 59, 0.14);
  --radius: 14px;
  --font-display: "Cormorant Garamond", "Times New Roman", serif;
  --font-body: "Inter", "Helvetica Neue", Arial, sans-serif;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --header-h: 72px;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16.5px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3 { font-family: var(--font-display); font-weight: 600; line-height: 1.1; margin: 0; }
p { margin: 0 0 1em; }
a { color: var(--lavender); text-decoration: none; }
a:hover { text-decoration: underline; }
img, video { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; }

:focus-visible {
  outline: 3px solid var(--lavender);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--ink); color: var(--paper); padding: 10px 18px; border-radius: 0 0 10px 0;
}
.skip-link:focus { left: 0; }

/* ---------- header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  height: var(--header-h);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 clamp(16px, 4vw, 48px);
  transition: background 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.site-header.scrolled {
  background: rgba(251, 248, 243, 0.97);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 rgba(46, 42, 59, 0.07), 0 10px 28px -14px rgba(46, 42, 59, 0.22);
}
.site-header.over-dark { color: var(--paper); }
.site-header.over-dark .brand-names { color: var(--paper); }
.site-header.over-dark .lang-link { color: var(--paper); border-color: rgba(251,248,243,0.55); }
.site-header.over-dark .lang-current { color: var(--ink); background: var(--gold-soft); }
.site-header.over-dark.scrolled { color: var(--ink); }
.site-header.over-dark.scrolled .brand-names { color: var(--ink); }
.site-header.over-dark.scrolled .lang-link { color: var(--ink); border-color: rgba(46,42,59,0.35); }
.site-header.over-dark.scrolled .lang-current { color: var(--ink); background: var(--gold); }

.brand { display: flex; align-items: center; gap: 12px; }
.brand .crest { display: block; }
.brand-names {
  font-family: var(--font-display); font-size: 22px; font-weight: 600;
  letter-spacing: 0.04em; color: var(--ink);
}
.brand-names .amp { font-style: italic; color: var(--gold); padding: 0 2px; }

.lang-nav { display: flex; align-items: center; gap: 6px; font-size: 12.5px; letter-spacing: 0.18em; }
.lang-link, .lang-current { padding: 7px 13px; border-radius: 999px; }
.lang-link { color: var(--ink); border: 1px solid var(--lavender-tint); }
.lang-current { color: var(--ink); background: var(--gold); font-weight: 600; border: 1px solid var(--gold); }

/* ---------- crest ---------- */
.crest { color: var(--gold); overflow: visible; }
.crest .crest-rings circle { fill: none; stroke: currentColor; stroke-width: 1.4; }
.crest .crest-rings circle:last-child { stroke-width: 0.7; }
.crest .crest-date { font-family: var(--font-display); font-size: 10.5px; letter-spacing: 0.28em; fill: currentColor; }
.crest .crest-monogram { font-family: var(--font-display); font-size: 19px; font-weight: 600; letter-spacing: 0.12em; fill: currentColor; }
.crest .griffin path, .crest .crest-emblem path { fill: none; stroke: currentColor; stroke-width: 1.15; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- divider ---------- */
.divider { width: min(520px, 86vw); height: 44px; color: var(--gold); opacity: 0.85; display: block; margin: 0 auto; }
.divider .divider-lotus path, .divider .divider-laurel path, .divider .divider-ticks path { fill: none; stroke: currentColor; stroke-width: 1.3; stroke-linecap: round; }
.divider g[transform*="300"] circle { fill: none; stroke: currentColor; stroke-width: 1.3; }

/* ---------- hero ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  background: var(--ink);
  isolation: isolate;
}
.hero-media { position: absolute; inset: -6% 0; z-index: -2; will-change: transform; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 38%; }
.hero-placeholder {
  position: absolute; inset: 0; z-index: -2;
  display: flex; align-items: flex-start; justify-content: center;
  padding-top: 15vh;
  background:
    radial-gradient(1200px 600px at 70% 20%, rgba(198,161,91,0.35), transparent 60%),
    radial-gradient(900px 500px at 20% 70%, rgba(142,124,195,0.3), transparent 60%),
    linear-gradient(160deg, #3A3550 0%, #2E2A3B 55%, #241F31 100%);
}
.hero-placeholder .crest {
  color: var(--gold-soft); opacity: 0.95;
}
.hero-placeholder .crest .crest-rings circle { stroke-width: 2.2; }
.hero-placeholder .crest .crest-rings circle:last-child { stroke-width: 1.1; }
.hero-placeholder .crest .griffin path, .hero-placeholder .crest .crest-emblem path { stroke-width: 1.7; }
.hero-placeholder .crest .crest-date { font-size: 13px; }
.hero-placeholder .crest .crest-monogram { font-size: 24px; }
.hero-scrim {
  position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(to top, rgba(24, 20, 32, 0.85) 0%, rgba(24,20,32,0.38) 32%, rgba(24,20,32,0.10) 55%, rgba(24,20,32,0.32) 100%);
}
.hero-meander {
  position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%); z-index: 1;
  width: min(320px, 70vw); height: 12px; opacity: 0.55;
  color: var(--gold-soft);
}
.hero-inner {
  width: 100%;
  padding: calc(var(--header-h) + 20px) 20px 70px;
  text-align: center;
  color: var(--paper);
  animation: rise 1.1s var(--ease) both;
}
.hero-kicker {
  font-size: 13px; letter-spacing: 0.42em; text-transform: uppercase;
  color: var(--gold-soft); margin-bottom: 18px;
  text-shadow: 0 1px 12px rgba(0,0,0,0.4);
}
.hero-names {
  font-size: clamp(52px, 11vw, 118px);
  font-weight: 500; line-height: 0.98;
  letter-spacing: 0.01em;
  color: #FFFDF8;
  text-shadow: 0 2px 34px rgba(0,0,0,0.5);
}
.hero-names .amp { font-style: italic; color: #E8CF9F; }
.hero-date {
  margin-top: 20px;
  font-size: clamp(15px, 2.4vw, 19px);
  letter-spacing: 0.34em; text-transform: uppercase; color: rgba(255,253,248,0.95);
  text-shadow: 0 1px 14px rgba(0,0,0,0.45);
}

/* countdown */
.countdown {
  display: flex; justify-content: center; gap: clamp(12px, 3.4vw, 30px);
  margin-top: 34px; flex-wrap: wrap;
}
.countdown-cell { min-width: 78px; position: relative; }
.countdown-cell + .countdown-cell::before {
  content: ""; position: absolute; left: -14px; top: 12px; bottom: 12px;
  width: 1px; background: linear-gradient(to bottom, transparent, rgba(232,207,159,0.5), transparent);
}
.countdown-num {
  font-family: var(--font-display); font-size: clamp(40px, 6.5vw, 58px); font-weight: 500;
  line-height: 1; color: #FFFDF8;
  font-variant-numeric: tabular-nums;
  text-shadow: 0 2px 22px rgba(0,0,0,0.45);
}
.countdown-label {
  display: block; margin-top: 8px;
  font-size: 10.5px; letter-spacing: 0.3em; text-transform: uppercase;
  color: #E8CF9F;
}
.countdown-done { margin-top: 30px; font-size: 19px; letter-spacing: 0.14em; color: #E8CF9F; font-style: italic; font-family: var(--font-display); }

/* ---------- sections ---------- */
.section { padding: clamp(56px, 9vw, 110px) clamp(20px, 6vw, 64px); }
.section-paper { background: var(--paper); }
.section-tint { background: linear-gradient(180deg, var(--paper) 0%, #F5F0E8 100%); }
.wrap { max-width: 1080px; margin: 0 auto; }

.lead {
  max-width: 640px; margin: 0 auto;
  text-align: center;
}
.lead-kicker { font-size: 12.5px; letter-spacing: 0.34em; text-transform: uppercase; color: var(--gold); margin-bottom: 16px; }
.lead-title { font-size: clamp(30px, 5vw, 46px); margin-bottom: 22px; color: var(--ink); }
.lead-text { font-size: clamp(16.5px, 2.3vw, 19px); line-height: 1.75; color: var(--ink-soft); }
.lead-text em { font-family: var(--font-display); font-size: 1.08em; color: var(--ink); }
.lead-sign { margin-top: 26px; font-family: var(--font-display); font-size: 24px; font-style: italic; color: var(--lavender); }

/* CTA */
.cta-band { text-align: center; }
.cta-title { font-size: clamp(28px, 4.6vw, 42px); margin-bottom: 14px; }
.cta-sub { color: var(--ink-soft); max-width: 520px; margin: 0 auto 30px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 14px 30px;
  border-radius: 999px; border: 1.5px solid var(--ink);
  font-family: var(--font-body); font-size: 15.5px; font-weight: 500; letter-spacing: 0.02em;
  color: var(--paper); background: var(--ink);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), background 0.25s;
  box-shadow: 0 6px 22px rgba(46,42,59,0.22);
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 10px 30px rgba(46,42,59,0.28); text-decoration: none; }
.btn-gold { background: var(--gold); border-color: var(--gold); color: var(--paper); box-shadow: 0 6px 22px rgba(198,161,91,0.35); }
.btn-ghost { background: transparent; color: var(--ink); box-shadow: none; }
.btn-ghost:hover { background: var(--paper-deep); }
.btn-lav { background: var(--lavender); border-color: var(--lavender); }

/* guest entry links */
.guest-entries { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-top: 26px; }

/* ---------- footer ---------- */
.site-footer { background: var(--ink); color: rgba(251,248,243,0.75); padding: 44px 20px 52px; text-align: center; }
.footer-inner { max-width: 640px; margin: 0 auto; }
.footer-inner .crest { color: var(--gold-soft); margin: 0 auto 14px; }
.footer-line { font-family: var(--font-display); font-size: 19px; letter-spacing: 0.24em; color: var(--paper); margin-bottom: 8px; }
.footer-note { font-size: 12.5px; color: rgba(251,248,243,0.55); margin-bottom: 10px; }
.footer-admin a { font-size: 12px; letter-spacing: 0.22em; text-transform: uppercase; color: rgba(198,161,91,0.85); }

/* ---------- reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.8s var(--ease), transform 0.8s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

@keyframes rise { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }

/* ---------- upload page ---------- */
.upload-hero { padding: calc(var(--header-h) + 40px) 20px 20px; text-align: center; }
.upload-hero h1 { font-size: clamp(34px, 6vw, 54px); }
.upload-hero p { color: var(--ink-soft); max-width: 520px; margin: 12px auto 0; }

.name-banner {
  max-width: 560px; margin: 28px auto 0;
  background: var(--paper-deep); border: 1px solid var(--gold-soft);
  border-radius: var(--radius); padding: 22px 24px; text-align: center;
}
.name-banner h2 { font-size: 24px; margin-bottom: 6px; }
.name-banner input[type="text"] {
  width: 100%; max-width: 340px; margin: 12px auto 8px; display: block;
  padding: 12px 16px; border-radius: 10px; border: 1.5px solid var(--lavender-tint);
  font: inherit; background: var(--white); color: var(--ink);
}
.name-banner .btn { margin-top: 6px; }

.upload-zone-wrap { max-width: 760px; margin: 26px auto 0; padding: 0 16px; }
.upload-zone {
  border: 2px dashed var(--lavender-tint); border-radius: 20px;
  background: rgba(255,255,255,0.55);
  padding: clamp(30px, 6vw, 56px) 20px; text-align: center;
  transition: border-color 0.25s, background 0.25s, transform 0.25s var(--ease);
  cursor: pointer;
}
.upload-zone:hover, .upload-zone.drag { border-color: var(--lavender); background: rgba(201,191,228,0.16); transform: scale(1.005); }
.upload-zone .big-icon { width: 64px; height: 64px; margin: 0 auto 16px; color: var(--lavender); }
.upload-zone h2 { font-size: clamp(24px, 4vw, 32px); margin-bottom: 8px; }
.upload-zone p { color: var(--ink-soft); margin-bottom: 4px; font-size: 14.5px; }

.file-list { margin-top: 22px; display: grid; gap: 10px; }
.file-row {
  display: grid; grid-template-columns: 44px 1fr auto; gap: 12px; align-items: center;
  background: var(--white); border: 1px solid var(--paper-deep); border-radius: 12px; padding: 10px 14px;
}
.file-row .f-thumb { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; background: var(--paper-deep); }
.file-row .f-meta { min-width: 0; }
.file-row .f-name { font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.file-row .f-progress { height: 5px; border-radius: 3px; background: var(--paper-deep); margin-top: 7px; overflow: hidden; }
.file-row .f-progress > span { display: block; height: 100%; background: linear-gradient(90deg, var(--lavender), var(--gold)); transition: width 0.3s var(--ease); }
.file-row .f-state { font-size: 12.5px; color: var(--ink-soft); min-width: 70px; text-align: right; }
.file-row.done .f-state { color: var(--sage); }
.file-row.error .f-state { color: var(--terracotta); }

.upload-success {
  display: none; margin-top: 22px; text-align: center;
  background: linear-gradient(135deg, rgba(138,154,123,0.12), rgba(201,191,228,0.16));
  border: 1px solid var(--gold-soft); border-radius: var(--radius); padding: 24px;
}
.upload-success h3 { font-size: 26px; color: var(--ink); margin-bottom: 4px; }
.upload-success p { color: var(--ink-soft); }

.fresh-grid { margin-top: 26px; display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; }
.fresh-grid img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 10px; }

/* ---------- gallery ---------- */
.gallery-top { padding: calc(var(--header-h) + 34px) 20px 0; text-align: center; }
.gallery-top h1 { font-size: clamp(34px, 6vw, 54px); }
.gallery-controls {
  display: flex; gap: 10px; justify-content: center; align-items: center; flex-wrap: wrap;
  margin: 22px auto 26px; max-width: 820px;
}
.chip {
  min-height: 40px; padding: 8px 18px; border-radius: 999px;
  border: 1.5px solid var(--lavender-tint); background: transparent;
  color: var(--ink-soft); font: inherit; font-size: 14px;
  transition: all 0.2s;
}
.chip:hover { border-color: var(--lavender); }
.chip.active { background: var(--lavender); border-color: var(--lavender); color: var(--paper); }
select.chip { cursor: pointer; }
.sort-toggle { min-height: 40px; padding: 8px 18px; border-radius: 999px; border: 1.5px solid var(--lavender-tint); background: transparent; font: inherit; font-size: 14px; color: var(--ink-soft); }
.sort-toggle.active { border-color: var(--gold); color: var(--gold); }

.masonry { columns: 2 200px; column-gap: 12px; max-width: 1280px; margin: 0 auto; padding: 0 16px 40px; }
.tile {
  break-inside: avoid; margin-bottom: 12px; position: relative;
  border-radius: 12px; overflow: hidden; background: var(--paper-deep);
  cursor: zoom-in; display: block;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
  box-shadow: 0 2px 8px rgba(46,42,59,0.08);
}
.tile:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.tile img, .tile video { width: 100%; height: auto; display: block; }
.tile .tile-kind {
  position: absolute; top: 10px; right: 10px;
  background: rgba(46,42,59,0.72); color: var(--paper);
  font-size: 11px; letter-spacing: 0.14em; padding: 4px 9px; border-radius: 999px;
  backdrop-filter: blur(4px);
}
.tile .tile-who {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 26px 12px 9px;
  background: linear-gradient(to top, rgba(30,26,40,0.72), transparent);
  color: var(--paper); font-size: 12.5px; opacity: 0; transition: opacity 0.3s;
}
.tile:hover .tile-who { opacity: 1; }

.empty-state { text-align: center; padding: 70px 20px; color: var(--ink-soft); }
.empty-state .crest { margin: 0 auto 18px; color: var(--lavender-tint); }
.empty-state h2 { font-size: 28px; color: var(--ink); margin-bottom: 8px; }

.loading-sentinel { text-align: center; padding: 26px; color: var(--ink-soft); font-size: 14px; }

/* lightbox */
.lightbox {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(24, 20, 32, 0.96);
  display: none; align-items: center; justify-content: center;
  touch-action: pan-y;
}
.lightbox.open { display: flex; }
.lightbox-stage { position: relative; max-width: 94vw; max-height: 88vh; }
.lightbox-stage img, .lightbox-stage video { max-width: 94vw; max-height: 88vh; object-fit: contain; border-radius: 6px; }
.lightbox-caption {
  position: absolute; left: 0; right: 0; bottom: -38px; text-align: center;
  color: rgba(251,248,243,0.85); font-size: 14px;
}
.lb-btn {
  position: absolute; z-index: 5;
  background: rgba(251,248,243,0.1); color: var(--paper);
  border: 1px solid rgba(251,248,243,0.25); border-radius: 50%;
  width: 48px; height: 48px; display: flex; align-items: center; justify-content: center;
  font-size: 20px; transition: background 0.2s;
}
.lb-btn:hover { background: rgba(251,248,243,0.22); text-decoration: none; }
.lb-close { top: 18px; right: 18px; }
.lb-prev { left: 14px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 14px; top: 50%; transform: translateY(-50%); }
.lb-download { bottom: 18px; right: 18px; font-size: 15px; width: auto; border-radius: 999px; padding: 0 18px; }
@media (max-width: 640px) {
  .lb-prev { left: 6px; } .lb-next { right: 6px; }
}

/* ---------- slideshow ---------- */
.slideshow-body { background: #000; overflow: hidden; cursor: none; }
.slideshow-body .site-header, .slideshow-body .site-footer, .slideshow-body .skip-link { display: none; }
.slideshow-stage { position: fixed; inset: 0; }
.slideshow-stage .slide {
  position: absolute; inset: 0; opacity: 0; transition: opacity 1.4s ease;
  display: flex; align-items: center; justify-content: center;
}
.slideshow-stage .slide.active { opacity: 1; }
.slideshow-stage img, .slideshow-stage video { max-width: 100vw; max-height: 100vh; object-fit: contain; }
.slideshow-stage img.kenburns { animation: kenburns 9s ease-in-out alternate infinite; }
@keyframes kenburns {
  from { transform: scale(1) translate(0, 0); }
  to { transform: scale(1.08) translate(1.2%, -1%); }
}
.slideshow-wordmark {
  position: fixed; left: 18px; bottom: 14px; z-index: 10;
  color: rgba(251,248,243,0.55); font-family: var(--font-display);
  font-size: 17px; letter-spacing: 0.22em;
}
.slideshow-wordmark .crest { width: 20px; height: 20px; display: inline-block; vertical-align: -4px; margin-right: 8px; color: rgba(198,161,91,0.8); }
.slideshow-empty { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; color: rgba(251,248,243,0.5); font-family: var(--font-display); font-size: 26px; letter-spacing: 0.2em; }

/* ---------- staff ---------- */
.staff-body { background: var(--paper); }
.staff-login-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; }
.staff-login-card {
  width: 100%; max-width: 400px; background: var(--white);
  border: 1px solid var(--paper-deep); border-radius: 18px;
  padding: 40px 34px; box-shadow: var(--shadow); text-align: center;
}
.staff-login-card .crest { margin: 0 auto 12px; }
.staff-login-card h1 { font-size: 28px; margin-bottom: 20px; }
.staff-login-card input[type="text"], .staff-login-card input[type="password"] {
  width: 100%; padding: 12px 14px; margin-bottom: 12px; border-radius: 10px;
  border: 1.5px solid var(--lavender-tint); font: inherit;
}
.staff-login-card .btn { width: 100%; }
.errorlist { color: var(--terracotta); font-size: 13.5px; list-style: none; padding: 0; margin: 0 0 10px; }

.dash { max-width: 1180px; margin: 0 auto; padding: calc(var(--header-h) + 30px) 20px 60px; }
.dash h1 { font-size: clamp(30px, 4.5vw, 42px); margin-bottom: 6px; }
.dash .dash-sub { color: var(--ink-soft); margin-bottom: 26px; }
.dash-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin-bottom: 26px; }
.stat-card { background: var(--white); border: 1px solid var(--paper-deep); border-radius: 14px; padding: 18px 20px; }
.stat-card .stat-num { font-family: var(--font-display); font-size: 34px; font-weight: 600; color: var(--lavender); line-height: 1; }
.stat-card .stat-label { font-size: 12.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-soft); margin-top: 8px; }
.stat-card.warn .stat-num { color: var(--terracotta); }

.panel { background: var(--white); border: 1px solid var(--paper-deep); border-radius: 16px; padding: 22px 24px; margin-bottom: 22px; }
.panel h2 { font-size: 22px; margin-bottom: 14px; }
.panel .row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.panel code { background: var(--paper-deep); padding: 3px 8px; border-radius: 6px; font-size: 13px; word-break: break-all; }
.toggle-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 10px 0; border-bottom: 1px solid var(--paper-deep); }
.toggle-row:last-child { border-bottom: 0; }
.switch { position: relative; width: 52px; height: 28px; flex: 0 0 auto; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch .slider {
  position: absolute; inset: 0; border-radius: 999px; background: var(--lavender-tint); transition: 0.25s;
}
.switch .slider::before {
  content: ""; position: absolute; width: 22px; height: 22px; border-radius: 50%;
  left: 3px; top: 3px; background: var(--white); transition: 0.25s; box-shadow: 0 1px 4px rgba(0,0,0,0.2);
}
.switch input:checked + .slider { background: var(--sage); }
.switch input:checked + .slider::before { transform: translateX(24px); }

.mod-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.mod-table th, .mod-table td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--paper-deep); vertical-align: middle; }
.mod-table th { font-size: 11.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-soft); }
.mod-table th:nth-child(2), .mod-table td:nth-child(2) { width: 66px; }
.mod-table img { width: 46px; height: 46px; max-width: none; object-fit: cover; border-radius: 8px; cursor: zoom-in; }
.mod-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.mini-btn {
  padding: 5px 11px; border-radius: 999px; border: 1.5px solid var(--lavender-tint);
  background: transparent; font: inherit; font-size: 12.5px; color: var(--ink-soft);
}
.mini-btn:hover { border-color: var(--lavender); color: var(--ink); }
.mini-btn.danger { border-color: rgba(181,101,74,0.5); color: var(--terracotta); }

/* ---------- token invalid ---------- */
.invalid-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; text-align: center; }
.invalid-card { max-width: 480px; }
.invalid-card .crest { margin: 0 auto 18px; color: var(--lavender); }
.invalid-card h1 { font-size: 34px; margin-bottom: 10px; }
.invalid-card p { color: var(--ink-soft); }

/* ---------- responsive ---------- */
@media (max-width: 640px) {
  .brand-names { font-size: 18px; }
  .hero-inner { padding-bottom: 56px; }
  .btn { width: 100%; max-width: 420px; }
  .dash { padding-left: 14px; padding-right: 14px; }
  .hero-placeholder .crest { width: 110px; height: 110px; margin-bottom: 8px; }
  .countdown {
    display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px;
    max-width: 360px; margin-left: auto; margin-right: auto;
  }
  .countdown-cell { min-width: 0; }
  .countdown-cell + .countdown-cell::before { display: none; }
  .countdown-num { font-size: clamp(28px, 9vw, 40px); }
  .countdown-label { font-size: 9.5px; letter-spacing: 0.16em; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; }
  .hero-media { will-change: auto; }
}

/* ---------- landing QR scanner ---------- */
.btn-scan { font-size: 17px; padding: 16px 38px; border-radius: 999px; }
.scan-hint { margin-top: 14px; font-size: 14px; }
.scan-frame {
  position: relative; max-width: 340px; margin: 18px auto 0;
  border-radius: 18px; overflow: hidden;
  box-shadow: 0 14px 40px -18px rgba(46, 42, 59, 0.35);
  border: 1px solid rgba(198, 161, 91, 0.35);
}
.scan-frame video { width: 100%; display: block; aspect-ratio: 1 / 1; object-fit: cover; }
.scan-status { margin: 12px 0 0; font-size: 13.5px; color: var(--ink-soft); min-height: 1.2em; }
#scanClose { margin-top: 12px; }
.scan-fallback { margin-top: 14px; font-size: 13.5px; }

/* moderation pager */
.pager { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 14px; }
.pager-info { font-size: 13px; color: var(--ink-soft); }
.pager .mini-btn:disabled { opacity: 0.45; cursor: default; }

/* landing QR scanner actions */
.scan-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
