/* ============================================================
    WEDDING WEBSITE — styles.css
    Sections:
    1. CSS Variables & Reset
    2. Background Collage
    3. Navigation
    4. Shared Section Utilities
    5. Hero
    6. Details
    7. Our Story
    8. Registry
    9. Travel
    10. Hotels
    11. RSVP Form
    12. Footer
    13. Admin Modal
    14. Animations
    15. Responsive
===========================================================*/


/* ── 1. VARIABLES & RESET ──────────────────────────────── */
:root {
  --rose:      #c9897a;
  --deep-rose: #8b4a42;
  --petal:     #eeddd8;
  --cream:     #fdf8f5;
  --blush:     #fdf0eb;
  --sage:      #8a9e8c;
  --gold:      #c8a96e;
  --text:      #2e2020;
  --muted:     #7a6060;

  --font-serif: 'Cormorant Garamond', serif;
  --font-sans:  'Jost', sans-serif;

  --radius-sm: 2px;
  --radius-md: 4px;
  --transition: 0.3s ease;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html  { scroll-behavior: smooth; }
body  {
  font-family: var(--font-sans);
  color: var(--text);
  font-weight: 300;
  overflow-x: hidden;
}
img   { display: block; max-width: 100%; }
a     { color: inherit; }


/* ── 2. BACKGROUND COLLAGE ─────────────────────────────── */
.bg-collage {
  position: fixed; inset: 0; z-index: -2;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows:    repeat(3, 1fr);
  opacity: 1.50;
}
.bg-collage-cell          { overflow: hidden; }
.bg-collage-cell img      { width: 100%; height: 100%; object-fit: cover; }

/* Placeholder gradients — remove once real photos are added */
.p1  { background: linear-gradient(135deg, #f2c4b0, #e8a090); }
.p2  { background: linear-gradient(135deg, #ddc4bc, #c9897a); }
.p3  { background: linear-gradient(135deg, #e8b8a8, #d4907e); }
.p4  { background: linear-gradient(135deg, #f5d5c8, #e8a090); }
.p5  { background: linear-gradient(135deg, #c8a090, #b87060); }
.p6  { background: linear-gradient(135deg, #e0c8bc, #d4a090); }
.p7  { background: linear-gradient(135deg, #f0d8cc, #d8987a); }
.p8  { background: linear-gradient(135deg, #c4b0a8, #b89088); }
.p9  { background: linear-gradient(135deg, #e8c8bc, #d8887a); }
.p10 { background: linear-gradient(135deg, #f4c8b0, #e09078); }
.p11 { background: linear-gradient(135deg, #d8b0a8, #c08878); }
.p12 { background: linear-gradient(135deg, #ecd0c4, #da9880); }

.bg-overlay {
  position: fixed; inset: 0; z-index: -1;
  background: rgba(253, 248, 245, 0.83);
}

/* Individual positioning */
.img-1 {
  object-position: center top;
}
.img-2 {
  object-position: 20% 35%;
}
.img-3 {
  object-position: 50% 35%;
}
.img-4 {
  object-position: 50% 60%;
}
.img-5 {
  object-position: 50% 25%;
}
.img-6 {
  object-position: 50% 65%;
}
.img-7 {
  object-position: 50% 50%;
}
.img-8 {
  object-position: 50% 30%;
}
.img-9 {
  object-position: 50% 35%;
}
.img-10 {
  object-position: 50% 50%;
}
.img-11 {
  object-position: 50% 50%;
}
.img-12 {
  object-position: 50% 35%;
}


/* ── 3. NAVIGATION ─────────────────────────────────────── */
#main-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  padding: 1rem 2rem;
  display: flex; justify-content: center; align-items: center;
  gap: 1.8rem; flex-wrap: wrap;
  background: rgba(253, 248, 245, 0.93);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 0.5px solid rgba(201, 137, 122, 0.2);
}
#main-nav a {
  font-size: 0.68rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--muted); text-decoration: none;
  transition: color var(--transition); white-space: nowrap; cursor: pointer;
}
#main-nav a:hover { color: var(--deep-rose); }
#main-nav .nav-admin { color: var(--gold); }
#main-nav .nav-admin:hover { color: var(--deep-rose); }


/* ── 4. SHARED SECTION UTILITIES ───────────────────────── */
.section-band { width: 100%; }
.band-white    { background: rgba(255, 255, 255, 0.70); }
.band-blush    { background: rgba(253, 240, 235, 0.80); }

.sw {
  max-width: 960px;
  margin: 0 auto;
  padding: 5rem 2rem;
}

.slabel {
  font-size: 0.63rem; letter-spacing: 0.3em; text-transform: uppercase;
  color: var(--rose); text-align: center; margin-bottom: 0.4rem;
}
.stitle {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 300; text-align: center;
  color: var(--deep-rose); margin-bottom: 1rem;
}
.sbody {
  text-align: center; color: var(--muted);
  line-height: 1.9; font-size: 1rem;
  max-width: 600px; margin: 0 auto;
}


/* ── 5. HERO ───────────────────────────────────────────── */
#home {
  min-height: 100vh;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  text-align: center;
  padding: 6rem 2rem 4rem;
}
.hero-date {
  font-size: 0.7rem; letter-spacing: 0.35em; text-transform: uppercase;
  color: var(--rose); margin-bottom: 1.5rem;
}
.hero-names {
  font-family: var(--font-serif);
  font-size: clamp(3.5rem, 10vw, 7rem);
  font-weight: 300; line-height: 1.05;
  color: var(--deep-rose); letter-spacing: 0.02em;
}
.hero-names .and {
  font-style: italic; font-size: 0.58em;
  color: var(--rose); display: block; margin: 0.1em 0;
}
.hero-sub {
  font-size: 0.85rem; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--muted); margin-top: 1.5rem;
}
.hero-deco { margin-top: 1.8rem; opacity: 0.4; }
.hero-cta {
  margin-top: 2.5rem; display: inline-block;
  padding: 0.9rem 2.5rem;
  border: 1px solid var(--rose); color: var(--deep-rose);
  text-decoration: none; font-size: 0.78rem;
  letter-spacing: 0.2em; text-transform: uppercase;
  transition: all var(--transition);
  background: rgba(255, 255, 255, 0.6);
}
.hero-cta:hover { background: var(--rose); color: white; }


/* ── 6. DETAILS ────────────────────────────────────────── */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem; margin-top: 3rem;
}
.dcard {
  background: rgba(255, 255, 255, 0.92);
  border: 0.5px solid rgba(201, 137, 122, 0.25);
  padding: 2rem 1.5rem; text-align: center;
  border-radius: var(--radius-sm);
}
.dcard .card-icon { font-size: 1.1rem; margin-bottom: 0.9rem; color: var(--rose); }
.dcard h3 {
  font-family: var(--font-serif); font-size: 1.2rem; font-weight: 400;
  color: var(--deep-rose); margin-bottom: 0.5rem;
}
.dcard p { font-size: 0.87rem; color: var(--muted); line-height: 1.75; }


/* ── 7. OUR STORY ──────────────────────────────────────── */
.story-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 2.5rem; margin-top: 3rem;
}
.scard {
  background: rgba(255, 255, 255, 0.88);
  border: 0.5px solid rgba(201, 137, 122, 0.2);
  padding: 2.5rem 2rem;
  border-radius: var(--radius-sm);
}
.scard .persp {
  font-size: 0.6rem; letter-spacing: 0.25em; text-transform: uppercase;
  color: var(--rose); margin-bottom: 0.3rem;
}
.scard h3 {
  font-family: var(--font-serif); font-size: 1.5rem; font-weight: 300;
  color: var(--deep-rose); margin-bottom: 1.2rem;
}
.scard p { font-size: 0.9rem; color: var(--muted); line-height: 1.9; font-style: italic; }
.scard p + p { margin-top: 0.9rem; }


/* ── 8. REGISTRY ───────────────────────────────────────── */
.reg-box {
  max-width: 520px; margin: 2.5rem auto 0;
  background: rgba(255, 255, 255, 0.94);
  border: 0.5px solid rgba(201, 137, 122, 0.3);
  padding: 2.5rem; text-align: center;
  border-radius: var(--radius-sm);
}
.reg-box p { color: var(--muted); font-size: 0.92rem; line-height: 1.85; margin-bottom: 1.8rem; }
.reg-btn {
  display: inline-block; padding: 0.9rem 2.2rem;
  background: var(--deep-rose); color: white; text-decoration: none;
  font-size: 0.78rem; letter-spacing: 0.2em; text-transform: uppercase;
  transition: background var(--transition);
  border-radius: var(--radius-sm);
}
.reg-btn:hover { background: var(--rose); }
.reg-note { margin-top: 1rem; font-size: 0.8rem; color: var(--rose); margin-bottom: 0 !important; }


/* ── 9. TRAVEL ─────────────────────────────────────────── */
.travel-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.5rem; margin-top: 3rem;
}
.tcard {
  background: rgba(255, 255, 255, 0.90);
  border: 0.5px solid rgba(201, 137, 122, 0.2);
  padding: 1.8rem 1.5rem;
  border-radius: var(--radius-sm);
}
.tcard h3 {
  font-family: var(--font-serif); font-size: 1.15rem; font-weight: 400;
  color: var(--deep-rose); margin-bottom: 0.65rem;
}
.tcard p { font-size: 0.85rem; color: var(--muted); line-height: 1.75; }
.pill {
  display: inline-block; margin-top: 0.75rem;
  padding: 0.25rem 0.75rem;
  font-size: 0.63rem; letter-spacing: 0.1em; text-transform: uppercase;
  background: var(--petal); color: var(--deep-rose); border-radius: 20px;
}
.flight-cta { text-align: center; margin-top: 2.5rem; }
.flight-link {
  display: inline-block; padding: 0.85rem 2.2rem;
  border: 1px solid var(--rose); color: var(--deep-rose);
  text-decoration: none; font-size: 0.78rem;
  letter-spacing: 0.18em; text-transform: uppercase;
  transition: all var(--transition);
  background: rgba(255, 255, 255, 0.6);
}
.flight-link:hover { background: var(--rose); color: white; }


/* ── 10. HOTELS ────────────────────────────────────────── */
.hotels-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem; margin-top: 3rem;
}
.hcard {
  background: rgba(255, 255, 255, 0.93);
  border: 0.5px solid rgba(201, 137, 122, 0.2);
  padding: 1.8rem 1.5rem;
  border-radius: var(--radius-sm);
}
.hcard .stars    { color: var(--gold); font-size: 0.72rem; margin-bottom: 0.5rem; }
.hcard h3        { font-family: var(--font-serif); font-size: 1.15rem; font-weight: 400; color: var(--deep-rose); margin-bottom: 0.4rem; }
.hcard .addr     { font-size: 0.77rem; color: var(--rose); margin-bottom: 0.75rem; font-style: italic; }
.hcard p         { font-size: 0.84rem; color: var(--muted); line-height: 1.75; }
.dist {
  display: inline-block; margin-top: 0.75rem;
  padding: 0.22rem 0.7rem;
  font-size: 0.62rem; letter-spacing: 0.1em; text-transform: uppercase;
  background: #eef4ec; color: #3b6611; border-radius: 20px;
}


/* ── 11. RSVP FORM ─────────────────────────────────────── */
.rsvp-inner { max-width: 600px; margin: 0 auto; }

.frow             { margin-bottom: 1.4rem; }
.frow label       {
  display: block; font-size: 0.67rem; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--muted); margin-bottom: 0.45rem;
}
.frow input,
.frow select,
.frow textarea    {
  width: 100%; padding: 0.9rem 1rem;
  border: 0.5px solid rgba(201, 137, 122, 0.4);
  background: rgba(255, 255, 255, 0.9);
  font-family: var(--font-sans); font-size: 0.95rem; color: var(--text);
  outline: none; border-radius: var(--radius-sm);
  transition: border-color var(--transition);
}
.frow input:focus,
.frow select:focus,
.frow textarea:focus { border-color: var(--rose); }
.frow textarea    { resize: vertical; min-height: 78px; }
.frow select      { appearance: none; cursor: pointer; }

.f2col { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }

.sub-btn {
  width: 100%; padding: 1.1rem;
  background: var(--deep-rose); color: white; border: none;
  font-family: var(--font-sans); font-size: 0.78rem;
  letter-spacing: 0.25em; text-transform: uppercase;
  cursor: pointer; transition: background var(--transition);
  border-radius: var(--radius-sm); margin-top: 0.5rem;
}
.sub-btn:hover    { background: var(--rose); }
.sub-btn:disabled { background: var(--muted); cursor: not-allowed; }

.fmsg {
  text-align: center; padding: 1rem; border-radius: var(--radius-sm);
  margin-top: 1rem; display: none; font-size: 0.9rem;
}
.fmsg.ok  { background: #eef4ec; color: #3b6611; border: 0.5px solid #b2d48a; display: block; }
.fmsg.err { background: #faeaea; color: #8a2020; border: 0.5px solid #e8a0a0; display: block; }
.fmsg.cap { background: #fdf0eb; color: var(--deep-rose); border: 0.5px solid var(--rose); display: block; }

.rem-note {
  font-size: 0.8rem; color: var(--muted);
  text-align: center; margin-top: 0.8rem; font-style: italic; display: none;
}


/* ── 12. FOOTER ────────────────────────────────────────── */
footer {
  background: var(--deep-rose);
  color: rgba(255, 255, 255, 0.75);
  text-align: center; padding: 3rem 2rem;
}
.footer-names {
  font-family: var(--font-serif); font-size: 2rem;
  color: white; font-style: italic; margin-bottom: 0.4rem;
}
footer p { font-size: 0.8rem; letter-spacing: 0.1em; }
.footer-credit { margin-top: 0.5rem; opacity: 0.42; font-size: 0.72rem !important; }


/* ── 13. ADMIN MODAL ───────────────────────────────────── */
#admin-overlay {
  display: none; position: fixed; inset: 0; z-index: 1000;
  background: rgba(46, 32, 32, 0.65);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  align-items: flex-start; justify-content: center;
  padding: 3rem 1rem 2rem;
  overflow-y: auto;
}
#admin-overlay.open { display: flex; }

.amodal {
  background: var(--cream); width: 100%; max-width: 920px;
  border: 0.5px solid rgba(201, 137, 122, 0.3);
  border-radius: var(--radius-md); overflow: hidden;
}
.amodal-hdr {
  background: var(--deep-rose); color: white;
  padding: 1.1rem 1.8rem;
  display: flex; justify-content: space-between; align-items: center;
}
.amodal-hdr h2 { font-family: var(--font-serif); font-size: 1.45rem; font-weight: 300; }
.aclose {
  background: none; border: none; color: rgba(255,255,255,0.7);
  font-size: 1.6rem; cursor: pointer; line-height: 1;
  transition: color var(--transition);
}
.aclose:hover { color: white; }
.amodal-body  { padding: 2rem; }

/* Login */
.alog   { text-align: center; padding: 2rem 1rem; }
.alog p { color: var(--muted); font-size: 0.88rem; margin-bottom: 1.2rem; }
.alog input {
  padding: 0.75rem 1rem;
  border: 0.5px solid rgba(201, 137, 122, 0.4);
  font-family: var(--font-sans); width: 220px;
  border-radius: var(--radius-sm); outline: none;
  background: white; color: var(--text);
  display: block; margin: 0 auto 0.4rem;
}
.alog-btn {
  margin-top: 0.9rem; padding: 0.75rem 2rem;
  background: var(--deep-rose); color: white; border: none;
  font-family: var(--font-sans); font-size: 0.75rem;
  letter-spacing: 0.18em; text-transform: uppercase;
  cursor: pointer; border-radius: var(--radius-sm);
  transition: background var(--transition);
}
.alog-btn:hover { background: var(--rose); }
.aperr { color: #8a2020; font-size: 0.82rem; margin-top: 0.5rem; display: none; }

/* Dashboard */
#adash { display: none; }

.astats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 1rem; margin-bottom: 1.5rem;
}
.astat {
  background: white; border: 0.5px solid rgba(201, 137, 122, 0.2);
  padding: 1rem; text-align: center; border-radius: var(--radius-sm);
}
.astat.span2 { grid-column: span 2; }

.anum       { font-family: var(--font-serif); font-size: 2rem; color: var(--deep-rose); }
.anum.sm    { font-size: 1.35rem; }
.anum.sage  { color: var(--sage); }
.anum.muted { color: var(--muted); }
.anum.gold  { color: var(--gold); }
.albl { font-size: 0.6rem; letter-spacing: 0.15em; text-transform: uppercase; color: var(--muted); margin-top: 0.2rem; }

.abar-wrap  { height: 4px; background: var(--petal); border-radius: 2px; overflow: hidden; margin: 0.7rem 0 0.25rem; }
.abar-fill  { height: 100%; background: var(--rose); width: 0%; transition: width 0.8s ease; }

.aacts { display: flex; gap: 0.7rem; flex-wrap: wrap; margin: 1.2rem 0; }
.abtn {
  padding: 0.52rem 1.05rem;
  border: 0.5px solid var(--rose); background: transparent;
  color: var(--deep-rose); font-family: var(--font-sans);
  font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase;
  cursor: pointer; transition: all 0.2s; border-radius: var(--radius-sm);
}
.abtn:hover          { background: var(--rose); color: white; }
.abtn.danger         { border-color: #c04040; color: #c04040; }
.abtn.danger:hover   { background: #c04040; color: white; }
.abtn.logout         { margin-left: auto; }

.atable-wrap { overflow-x: auto; }
.atable {
  width: 100%; border-collapse: collapse;
  font-size: 0.82rem; min-width: 580px;
}
.atable th {
  font-size: 0.6rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--muted); text-align: left; padding: 0.5rem 0.7rem;
  border-bottom: 0.5px solid var(--petal);
}
.atable td { padding: 0.6rem 0.7rem; border-bottom: 0.5px solid var(--petal); color: var(--text); }

.badge        { display: inline-block; padding: 0.2rem 0.6rem; border-radius: 20px; font-size: 0.67rem; }
.badge.yes    { background: #eef4ec; color: #3b6611; }
.badge.no     { background: #faeaea; color: #8a2020; }
.badge.maybe  { background: #fdf7ec; color: #7a5a10; }

.aempty { text-align: center; color: var(--muted); padding: 2rem; font-style: italic; font-size: 0.88rem; }


/* ── Gallery grid (CSS masonry via grid) ───────────────── */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-auto-rows: 220px;
  gap: 10px;
  margin-top: 3rem;
}

/* Tall item spans 2 rows */
.g-item.g-tall { grid-row: span 2; }

/* Wide item spans 2 columns */
.g-item.g-wide { grid-column: span 2; }

/* Each photo cell */
.g-item {
  position: relative;
  overflow: hidden;
  border-radius: 2px;
  cursor: pointer;
  background: var(--petal);
}

.g-item img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.55s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Hover overlay */
.g-item::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(
    to top,
    rgba(139, 74, 66, 0.55) 0%,
    transparent 50%
  );
  opacity: 0;
  transition: opacity 0.35s ease;
}
.g-item:hover::after         { opacity: 1; }
.g-item:hover img            { transform: scale(1.06); }

/* Caption on hover */
.g-item .g-caption-hover {
  position: absolute; bottom: 0; left: 0; right: 0;
  padding: 0.9rem 1rem 0.75rem;
  font-size: 0.75rem; letter-spacing: 0.12em;
  text-transform: uppercase; color: white;
  font-family: var(--font-sans); font-weight: 300;
  transform: translateY(6px);
  opacity: 0;
  transition: opacity 0.35s ease, transform 0.35s ease;
  z-index: 2;
}
.g-item:hover .g-caption-hover {
  opacity: 1;
  transform: translateY(0);
}

/* Placeholder tiles (remove when real photos are added) */
.g-placeholder {
  width: 100%; height: 100%;
}
.g-placeholder.p1  { background: linear-gradient(135deg, #f2c4b0, #e8a090); }
.g-placeholder.p2  { background: linear-gradient(135deg, #ddc4bc, #c9897a); }
.g-placeholder.p3  { background: linear-gradient(135deg, #e8b8a8, #d4907e); }
.g-placeholder.p4  { background: linear-gradient(135deg, #f5d5c8, #e0a888); }
.g-placeholder.p5  { background: linear-gradient(135deg, #c8a090, #b87060); }
.g-placeholder.p6  { background: linear-gradient(135deg, #e0c8bc, #d4a090); }
.g-placeholder.p7  { background: linear-gradient(135deg, #f0d8cc, #d8987a); }
.g-placeholder.p8  { background: linear-gradient(135deg, #c4b0a8, #b89088); }
.g-placeholder.p9  { background: linear-gradient(135deg, #e8c8bc, #d8887a); }
.g-placeholder.p10 { background: linear-gradient(135deg, #f4c8b0, #e09078); }
.g-placeholder.p11 { background: linear-gradient(135deg, #d8b0a8, #c08878); }
.g-placeholder.p12 { background: linear-gradient(135deg, #ecd0c4, #da9880); }


/* ── Lightbox ───────────────────────────────────────────── */
#lightbox {
  display: none;
  position: fixed; inset: 0; z-index: 2000;
  background: rgba(22, 10, 10, 0.93);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  align-items: center; justify-content: center;
  flex-direction: column;
  padding: 2rem;
}
#lightbox.open { display: flex; }

#lb-img-wrap {
  max-width: 90vw;
  max-height: 80vh;
  display: flex; align-items: center; justify-content: center;
}
#lb-img {
  max-width: 100%;
  max-height: 80vh;
  object-fit: contain;
  border-radius: 2px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
  transition: opacity 0.25s ease;
}
#lb-img.fading { opacity: 0; }

#lb-caption {
  margin-top: 1.2rem;
  font-family: var(--font-serif);
  font-size: 1.1rem; font-style: italic;
  color: rgba(255,255,255,0.75);
  letter-spacing: 0.04em;
  text-align: center;
  min-height: 1.5rem;
}

/* Close button */
#lb-close {
  position: absolute; top: 1.2rem; right: 1.5rem;
  background: none; border: none;
  color: rgba(255,255,255,0.6); font-size: 2rem;
  cursor: pointer; line-height: 1;
  transition: color 0.2s;
}
#lb-close:hover { color: white; }

/* Prev / Next arrows */
#lb-prev,
#lb-next {
  position: absolute; top: 50%; transform: translateY(-50%);
  background: none; border: none;
  color: rgba(255,255,255,0.5);
  font-size: 3rem; cursor: pointer; line-height: 1;
  padding: 0.5rem 1rem;
  transition: color 0.2s;
  user-select: none;
}
#lb-prev { left: 1rem; }
#lb-next { right: 1rem; }
#lb-prev:hover,
#lb-next:hover { color: white; }



/* ── 14. ANIMATIONS ────────────────────────────────────── */
.fi {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}
.fi.v {
  opacity: 1;
  transform: translateY(0);
}


/* ── 15. RESPONSIVE ────────────────────────────────────── */
@media (max-width: 640px) {
  #main-nav { gap: 1rem; padding: 0.8rem 1rem; }
  #main-nav a { font-size: 0.6rem; }
  .story-grid { grid-template-columns: 1fr; }
  .f2col      { grid-template-columns: 1fr; }
  .astat.span2 { grid-column: span 1; }
}
@media (max-width: 400px) {
  #main-nav { gap: 0.7rem; }
}

@media (max-width: 768px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 180px;
  }
  /* On mobile, wide items still span 2 cols (fills width nicely) */
  /* But tall items revert to single row to avoid large empty gaps */
  .g-item.g-tall { grid-row: span 1; }
}
@media (max-width: 480px) {
  .gallery-grid {
    grid-template-columns: 1fr 1fr;
    grid-auto-rows: 140px;
    gap: 6px;
  }
  #lb-prev { left: 0.3rem; font-size: 2rem; }
  #lb-next { right: 0.3rem; font-size: 2rem; }
}


/* ── QR Status badges (admin table) ── */
.badge.qr-used    { background: #eef4ec; color: #3b6611; }
.badge.qr-pending { background: #fdf7ec; color: #7a5a10; }