/* =====================================================================
   DESIGN TOKENS — colour, type, motion. Everything else derives from these.
   ===================================================================== */
:root {
  /* ================= THE PALETTE — three colours, plus paper =================
     ONE green  · --olive  #8e9140  (the invitation's menu-card moss)
     ONE red    · --wine   #6a2131  (the wine seal)
     ivory + white for ground.
     --wine-deep / --olive-deep are shades of those same two hues, not new
     colours. --ink is the text black, carrying a faint wine cast so it
     belongs to the family. Nothing else may introduce a hue. */
  --olive: #8e9140;
  --olive-deep: #6d7032;
  --olive-soft: #eef0e2;         /* palest tint of the green */
  --wine: #6a2131;
  --wine-deep: #4a1622;
  --ivory: #faf8f5;
  --paper: #ffffff;
  --ink: #2a2026;                /* body text */
  --muted: rgba(42, 32, 38, 0.62);
  --line: rgba(142, 145, 64, 0.26);   /* hairlines = the green, low alpha */

  /* legacy names kept so every existing rule resolves to the palette above */
  --burgundy: var(--wine);
  --burgundy-deep: var(--wine-deep);
  --sage: var(--olive);
  --sage-soft: var(--olive-soft);
  --olive-card: var(--olive);
  --text: var(--ink);
  /* layout */
  --header-h: 62px;
  /* type */
  --script: "Pinyon Script", cursive;
  --serif: "Cormorant Garamond", Georgia, serif;
  --sans: "Montserrat", system-ui, sans-serif;
  --cjk: "Noto Serif TC", "PingFang TC", "Songti TC", serif;
  /* motion schema — one easing, three durations, one travel distance */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);   /* "out-quint": fast start, soft landing */
  --dur-1: 220ms;   /* micro: hover, focus */
  --dur-2: 600ms;   /* element reveal */
  --dur-3: 900ms;   /* page / section change */
  --rise: 22px;     /* how far things travel when they appear */
  --stagger: 80ms;  /* delay between siblings */
}

/* ---------- Reset & base ---------- */
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--sans); font-weight: 400; font-size: 15px;
  color: var(--text); line-height: 1.75; min-height: 100vh; display: flex; flex-direction: column;
  background-color: var(--ivory);
  -webkit-font-smoothing: antialiased;
}
main { flex: 1; }
/* decorative blooms hang past the text column; never let them scroll the page */
body { overflow-x: clip; }
.panel { overflow-x: clip; }
.wrap { max-width: 940px; margin: 0 auto; padding: 5rem 1rem; }
.wrap.wide { max-width: 1200px; }
[hidden] { display: none !important; }
img { max-width: 100%; }
::selection { background: var(--sage-soft); color: var(--burgundy); }
:focus-visible { outline: 2px solid var(--sage); outline-offset: 3px; }

/* ---------- Typography (editorial scale: big serif heads, whisper-small kickers) ---------- */
h1, h2, h3 { font-family: var(--serif); font-weight: 400; color: var(--burgundy); }
h2 { font-size: clamp(2.4rem, 5vw, 3.6rem); text-align: center; line-height: 1.08; letter-spacing: -0.01em; font-weight: 300; }
h3 { font-size: 1.45rem; }
.script { font-family: var(--script); font-weight: 400; }
.cjk { font-family: var(--cjk); }
.kicker { text-align: center; font-size: 0.64rem; letter-spacing: 0.32em; text-transform: uppercase; color: var(--olive); margin-bottom: 1rem; }
.kicker.left { text-align: left; }
.kicker.light { color: rgba(250,248,245,0.72); }
.sub { text-align: center; color: var(--burgundy); font-family: var(--serif); font-style: italic; font-size: 1.3rem; margin: 0.5rem 0 2.8rem; }
.lead { max-width: 600px; margin: 1.4rem auto 0; text-align: center; color: var(--muted); font-size: 1rem; }
.lead.small { font-size: 0.86rem; margin-top: 0.9rem; opacity: 0.85; }
.lead.left { text-align: left; margin-left: 0; }
.group-title { text-align: center; margin: 3.5rem 0 1.2rem; }
.group-title::after { content: ""; display: block; width: 40px; height: 1px; background: var(--sage); margin: 0.6rem auto 0; }

/* ---------- Header ---------- */
/* Glass: over the photo it is a clear frosted pane with light type;
   once scrolled it frosts to paper and the type returns to ink. */
.site-header {
  position: sticky; top: 0; z-index: 20; min-height: var(--header-h);
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 0.8rem 1.5rem;
  background: rgba(250, 248, 245, 0.55);
  backdrop-filter: blur(16px) saturate(130%); -webkit-backdrop-filter: blur(16px) saturate(130%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.35);
  transition: background var(--dur-2) var(--ease), border-color var(--dur-2) var(--ease), box-shadow var(--dur-1);
}
.site-header.scrolled {
  background: rgba(250, 248, 245, 0.72);
  border-bottom-color: var(--line); box-shadow: 0 10px 30px -20px rgba(74,22,34,0.25);
}
/* light type while the glass is over the photo */
.site-header .monogram { color: var(--burgundy); }
.site-header .monogram span { color: var(--olive); }
.site-header .nav a { color: var(--muted); }
.site-header .nav a:hover, .site-header .nav a.active { color: var(--burgundy); }
.site-header .nav a::after { background: var(--burgundy); }
.site-header .lang { border-color: var(--olive); }
.site-header .lang button { color: var(--olive); }
.site-header .lang button[aria-pressed="true"] { background: var(--olive); color: var(--paper); }
.site-header .nav-toggle span { background: var(--burgundy); }
/* ink type once frosted to paper */
.site-header.scrolled .monogram { color: var(--burgundy); }
.site-header.scrolled .monogram span { color: var(--olive); }
.site-header.scrolled .nav a { color: var(--muted); }
.site-header.scrolled .nav a:hover, .site-header.scrolled .nav a.active { color: var(--burgundy); }
.site-header.scrolled .nav a::after { background: var(--burgundy); }
.site-header.scrolled .lang { border-color: var(--olive); }
.site-header.scrolled .lang button { color: var(--olive); }
.site-header.scrolled .lang button[aria-pressed="true"] { background: var(--olive); color: var(--paper); }
.site-header.scrolled .nav-toggle span { background: var(--burgundy); }
.monogram { font-family: var(--serif); font-weight: 300; font-size: 1.7rem; letter-spacing: 0.02em; text-decoration: none; line-height: 1; transition: color var(--dur-2) var(--ease); }
.monogram span { font-family: var(--script); font-size: 1.2rem; margin: 0 0.06em; }
.nav { display: flex; gap: 1.6rem; }
.nav a {
  position: relative; color: var(--muted); text-decoration: none; font-size: 0.68rem; font-weight: 400;
  letter-spacing: 0.22em; text-transform: uppercase; padding: 0.3rem 0; transition: color var(--dur-1);
}
.nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--sage); transform: scaleX(0); transform-origin: left; transition: transform var(--dur-2) var(--ease); }
.nav a:hover { color: var(--burgundy); }
.nav a:hover::after { transform: scaleX(1); }
.nav a.active { color: var(--burgundy); }
.nav a.active::after { transform: scaleX(1); }
.header-right { display: flex; align-items: center; gap: 0.6rem; }
.lang { display: flex; border: 1px solid var(--olive); border-radius: 999px; overflow: hidden; }
.lang button { background: none; border: 0; cursor: pointer; padding: 0.3rem 0.7rem; font: 500 0.66rem var(--sans); letter-spacing: 0.1em; color: var(--olive); transition: background var(--dur-1), color var(--dur-1); }
.lang button[aria-pressed="true"] { background: var(--olive); color: var(--ivory); }
.nav-toggle { display: none; background: none; border: 0; cursor: pointer; padding: 0.4rem; }
.nav-toggle span { display: block; width: 22px; height: 1.5px; margin: 5px 0; background: var(--burgundy); transition: transform var(--dur-2) var(--ease), opacity var(--dur-1); }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; padding: 0.85rem 2.2rem; border-radius: 999px; cursor: pointer; white-space: nowrap;
  background: var(--burgundy); color: var(--ivory); text-decoration: none; border: 1px solid var(--burgundy);
  font-size: 0.68rem; letter-spacing: 0.24em; text-transform: uppercase;
  transition: background var(--dur-1), border-color var(--dur-1), transform var(--dur-2) var(--ease), box-shadow var(--dur-2) var(--ease);
}
.btn:hover { background: var(--olive); border-color: var(--olive); transform: translateY(-2px); box-shadow: 0 12px 24px -14px rgba(74,22,34,0.6); }
.btn-ivory { background: var(--ivory); color: var(--burgundy); border-color: var(--ivory); }
.btn-ivory:hover { background: var(--burgundy); color: var(--ivory); border-color: var(--burgundy); }

/* =====================================================================
   MOTION SCHEMA
   .panel           — section (tab) entrance: soft fade + rise
   .stagger [--i]   — on-load sequence inside the hero (index sets delay)
   .reveal          — appears when scrolled into view (fade + rise)
   .reveal-group    — children each get a reveal, staggered by --stagger
   Respects prefers-reduced-motion: everything is simply visible.
   ===================================================================== */
@keyframes rise { from { opacity: 0; transform: translateY(var(--rise)); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

.panel { animation: rise var(--dur-3) var(--ease) both; }
.stagger { animation: rise var(--dur-2) var(--ease) both; animation-delay: calc(200ms + var(--i, 0) * var(--stagger)); }

.reveal, .reveal-group > * { opacity: 0; transform: translateY(var(--rise)); transition: opacity var(--dur-2) var(--ease), transform var(--dur-2) var(--ease); }
.reveal.in, .reveal-group.in > * { opacity: 1; transform: none; }
.reveal-group.in > *:nth-child(1) { transition-delay: calc(0 * var(--stagger)); }
.reveal-group.in > *:nth-child(2) { transition-delay: calc(1 * var(--stagger)); }
.reveal-group.in > *:nth-child(3) { transition-delay: calc(2 * var(--stagger)); }
.reveal-group.in > *:nth-child(4) { transition-delay: calc(3 * var(--stagger)); }
.reveal-group.in > *:nth-child(5) { transition-delay: calc(4 * var(--stagger)); }
.reveal-group.in > *:nth-child(6) { transition-delay: calc(5 * var(--stagger)); }
.reveal-group.in > *:nth-child(7) { transition-delay: calc(6 * var(--stagger)); }
.reveal-group.in > *:nth-child(8) { transition-delay: calc(7 * var(--stagger)); }
.reveal-group.in > *:nth-child(n+9) { transition-delay: calc(8 * var(--stagger)); }

/* Cross-fade between tabs when the browser supports View Transitions */
::view-transition-old(root) { animation: fade var(--dur-2) var(--ease) reverse; }
::view-transition-new(root) { animation: fade var(--dur-2) var(--ease); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .panel, .stagger { animation: none; }
  .reveal, .reveal-group > * { opacity: 1; transform: none; transition: none; }
  ::view-transition-old(root), ::view-transition-new(root) { animation: none; }
  * { transition-duration: 0.01ms !important; }
}

/* ---------- Hero: full-bleed landscape photo, names on the image ---------- */
.hero { position: relative; background: var(--ivory); }
.hero-photo {
  position: relative; display: grid; align-items: end; justify-items: center;
  min-height: min(82vh, 760px);
  margin-top: calc(-1 * var(--header-h));   /* photo runs up behind the glass header */
  padding: calc(var(--header-h) + 3rem) 1.5rem clamp(2.5rem, 7vh, 4.5rem);
  background-image: url("assets/photos/trial-web.jpg");
  background-size: cover; background-position: 50% 45%; background-repeat: no-repeat;
}
/* Scrim: dark at the top so the glass header reads, then the foot of the
   photo fades into the page cream — which both blends into the countdown
   section below and gives the burgundy names a light ground to sit on. */
.hero-photo::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to bottom,
    rgba(20,18,17,0.18) 0%, rgba(20,18,17,0.04) 16%, rgba(20,18,17,0.00) 34%,
    rgba(250,248,245,0.00) 48%, rgba(250,248,245,0.62) 72%,
    rgba(250,248,245,0.94) 88%, rgba(250,248,245,1) 100%);
}
.hero-caption { position: relative; z-index: 2; text-align: center; color: var(--paper); width: min(52rem, 100%); }
/* one line: Agnieszka & Jing */
/* names in the house burgundy, ampersand in the olive */
.hero-caption h1 { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: center; gap: 0 0.3em; line-height: 1.05; margin: 0 0 0.2rem; color: var(--burgundy); }
.hero-caption h1 .script { font-size: clamp(2.5rem, 7vw, 5.2rem); line-height: 1.12; }
.hero-caption h1 .and { font-family: var(--script); font-weight: 400; font-size: clamp(1.6rem, 3.6vw, 2.8rem); color: var(--olive-card); margin: 0; }
.hero-caption .rule { justify-content: center; color: var(--olive-card); margin: 0.9rem 0 1.1rem; }
.hero-caption .rule i { background: var(--olive-card); opacity: 0.5; width: 52px; }

/* Under the photo: the countdown, then the date. No frame, no button —
   the welcome words follow in the band below. */
.hero-below {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  padding: clamp(1.2rem, 3vh, 2rem) 1.5rem clamp(3.5rem, 8vh, 5rem);
}
.hero-below .hero-date { margin-top: 1.6rem; }

.eyebrow { text-transform: uppercase; letter-spacing: 0.3em; font-size: 0.62rem; color: var(--olive); line-height: 1.8; }
.rule { display: flex; align-items: center; gap: 0.7rem; justify-content: center; margin: 0.6rem 0 1rem; color: var(--sage); }
.rule i { width: 60px; height: 1px; background: var(--sage); }
.hero-date { font-family: var(--serif); font-size: 1.55rem; font-style: italic; color: var(--burgundy); }
.hero-place { text-transform: uppercase; letter-spacing: 0.25em; font-size: 0.66rem; color: var(--muted); margin-top: 0.2rem; }

/* Countdown: olive ogee cards with an inset hairline frame —
   the shape and colour of the menu card from the invitation suite.
   --ogee is a scalloped lozenge: pointed top and bottom, concave shoulders. */
.countdown { display: flex; justify-content: center; align-items: stretch; gap: 0; margin: 0 0 2rem; flex-wrap: nowrap; }
.countdown div { padding: 0 clamp(0.45rem, 1.3vw, 0.95rem); border: 0; }
/* hairline between the units, not around each one */
.countdown div + div { border-left: 1px solid rgba(142, 145, 64, 0.3); }
.countdown b { display: block; font-family: var(--serif); font-weight: 400; font-size: clamp(1.7rem, 3.2vw, 2.2rem); line-height: 1.05; color: var(--wine); font-variant-numeric: tabular-nums; }
.countdown small { display: block; text-transform: uppercase; font-size: 0.5rem; letter-spacing: 0.1em; color: var(--olive); margin-top: 0.15rem; }
.countdown .done { font-family: var(--script); font-size: 2.4rem; color: var(--burgundy); }

/* ---------- Botanical accents (cut-out PNGs, assets/flowers) ---------- */
.panel { position: relative; }
.bloom {
  position: absolute; z-index: 0; pointer-events: none; user-select: none;
}
.bloom.left  { left: -3.5rem; }
.bloom.right { right: -3.5rem; }
.bloom img { display: block; width: 100%; height: auto; }
/* keep content above the petals */
.panel > .wrap, .panel > .band, .panel > .tab-hero, .panel > .hero { position: relative; z-index: 1; }
@media (max-width: 1100px) { .bloom { display: none; } }

/* ---------- While you're here ---------- */
.place-group { margin-top: 3.5rem; }
.place-label {
  display: flex; align-items: center; gap: 1.2rem;
  text-transform: uppercase; letter-spacing: 0.28em; font-size: 0.6rem;
  color: var(--olive); margin-bottom: 1.6rem;
}
.place-label::before, .place-label::after { content: ""; flex: 1; height: 1px; background: var(--line); }

.place-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.2rem; }
/* lead cards: two per row, larger type and a more generous image */
.place.lead { grid-column: span 2; }
.place.lead .place-img { aspect-ratio: 16 / 10; }
.place.lead figcaption { padding: 1.3rem 1.5rem 1.5rem; }
.place.lead h3 { font-size: 1.4rem; margin-bottom: 0.4rem; }
.place.lead p { font-size: 0.92rem; }
@media (max-width: 900px) { .place-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) {
  .place-grid { grid-template-columns: 1fr; }
  .place.lead { grid-column: auto; }
}
.place { margin: 0; background: var(--paper); border: 1px solid var(--line); overflow: hidden;
  transition: transform var(--dur-2) var(--ease), box-shadow var(--dur-2) var(--ease); }
.place:hover { transform: translateY(-4px); box-shadow: 0 30px 50px -36px rgba(106,33,49,0.45); }
.place-img { overflow: hidden; aspect-ratio: 4 / 3; }
.place-img img { width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform var(--dur-3) var(--ease); }
.place:hover .place-img img { transform: scale(1.04); }
.place figcaption { padding: 1.1rem 1.2rem 1.3rem; }
.place h3 { font-size: 1.1rem; margin-bottom: 0.3rem; }
.place p { color: var(--muted); font-size: 0.84rem; line-height: 1.6; }


/* ---------- Contact cards + dietary note ---------- */
.contacts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.4rem; max-width: 820px; margin: 0 auto; }
/* arched cards — the same window shape as the love cards, so the section
   reads as part of the family rather than a generic row of boxes */
.contact-card {
  text-align: center; padding: 2.8rem 1.3rem 2.4rem; background: var(--burgundy);
  border: 1px solid var(--burgundy); border-radius: 120px 120px 10px 10px;
  transition: transform var(--dur-2) var(--ease), box-shadow var(--dur-2) var(--ease);
}
.contact-card:hover { transform: translateY(-4px); box-shadow: 0 30px 50px -30px rgba(74,22,34,0.65); }
/* on burgundy: pale tint of the house green for the role, ivory for the rest */
.contact-role { text-transform: uppercase; letter-spacing: 0.24em; font-size: 0.58rem; color: #c9cc92; margin-bottom: 0.6rem; }
.contact-role::after { content: ""; display: block; width: 26px; height: 1px; background: rgba(250,248,245,0.3); margin: 0.6rem auto 0; }
.contact-card h3 { font-size: 1.7rem; margin-bottom: 0.7rem; color: var(--ivory); }
.contact-phone {
  font-family: var(--serif); font-size: 1.2rem; color: rgba(250,248,245,0.92); text-decoration: none;
  border-bottom: 1px solid rgba(201,204,146,0.55); padding-bottom: 2px; transition: border-color var(--dur-1), color var(--dur-1);
}
.contact-phone:hover { color: #ffffff; border-bottom-color: var(--ivory); }
.note {
  max-width: 640px; margin: 3rem auto 0; text-align: center;
  padding: 2rem 1.8rem; background: var(--paper); border-radius: 10px;
  border: 1px solid rgba(106, 33, 49, 0.3);
  box-shadow: 0 30px 55px -34px rgba(74, 22, 34, 0.45);
}
.note h3 { font-size: 1.15rem; margin-bottom: 0.5rem; }
.note p { color: var(--muted); font-size: 0.95rem; }

/* ---------- Monogram (see crest.js): initials only, light serif ---------- */
.crest { --mono-ink: var(--burgundy); --mono-amp: var(--sage); display: flex; align-items: center; justify-content: center; gap: 0.08em; color: var(--mono-ink); font-family: var(--serif); font-weight: 300; line-height: 1; }
.mono-i { font-size: 1em; letter-spacing: 0.02em; }
.mono-amp { font-family: var(--script); font-size: 0.55em; color: var(--mono-amp); position: relative; top: 0.05em; margin: 0 0.12em; }
.crest.light { --mono-ink: var(--ivory); --mono-amp: rgba(250,248,245,0.75); }
.crest.medium { font-size: 3.2rem; margin: 0 auto 0.8rem; }
.crest.badge {
  position: absolute; left: 50%; bottom: -50px; transform: translateX(-50%);
  width: 100px; height: 100px; border-radius: 50%; font-size: 2.6rem;
  background: var(--paper); border: 1px solid var(--sage); box-shadow: 0 16px 30px -18px rgba(106,33,49,0.4);
}
.crest.badge.stagger { animation-name: badge-in; }
@keyframes badge-in { from { opacity: 0; transform: translateX(-50%) scale(0.85); } to { opacity: 1; transform: translateX(-50%) scale(1); } }

/* ---------- Polaroids (figure > img: robust on every browser) ---------- */
.polaroid { margin: 0; background: var(--paper); padding: 10px 10px 34px; box-shadow: 0 12px 30px -10px rgba(74,22,34,0.4); }
.polaroid img { display: block; width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }

/* ---------- Burgundy band ---------- */
.band { background: var(--burgundy); color: var(--ivory); }
.band h2, .band h3 { color: var(--ivory); }
.band .kicker { color: rgba(250,248,245,0.75); }
.band .sub { color: rgba(250,248,245,0.80); }
.band .lead { color: rgba(250,248,245,0.86); }

/* ---------- Love block (愛 · miłość) ---------- */
.love { margin-top: 6rem; }
/* stretch, so both cards match height whatever the text length or language */
.love-grid { display: grid; grid-template-columns: 1fr auto 1fr; gap: 2rem; align-items: stretch; margin-top: 2.5rem; }
.love-card { display: flex; flex-direction: column; justify-content: center; text-align: center; background: var(--paper); border: 1px solid rgba(106, 33, 49, 0.3); box-shadow: 0 30px 55px -34px rgba(74, 22, 34, 0.45); padding: 2.4rem 1.6rem; border-radius: 140px 140px 10px 10px; transition: transform var(--dur-2) var(--ease), box-shadow var(--dur-2) var(--ease); }
.love-word { font-size: 4.6rem; line-height: 1; color: var(--burgundy); }
.love-word.cjk { font-size: 5rem; }
.love-say { font-family: var(--serif); font-style: italic; color: var(--olive); font-size: 1.2rem; margin: 0.4rem 0 0.9rem; min-height: 1.2em; }
.love-text { color: var(--muted); font-size: 0.93rem; }
.love-divider { color: var(--sage); font-size: 1.4rem; align-self: center; }

/* ---------- Story ---------- */
.story-layout { display: grid; grid-template-columns: 1fr 1.15fr; gap: 3rem; align-items: center; }
.story-photos { position: relative; padding: 0 0 30% 0; }
.story-photos .s1 { width: 62%; transform: rotate(-6deg); position: relative; z-index: 2; }
.story-photos .s2 { width: 62%; position: absolute; right: -5%; bottom: 0; transform: rotate(5deg); }
.story { list-style: none; position: relative; padding-left: 2rem; }
.story::before { content: ""; position: absolute; left: 6px; top: 0.5rem; bottom: 0.5rem; width: 1px; background: var(--sage); }
.story li { position: relative; margin-bottom: 2rem; }
.story li:last-child { margin-bottom: 0; }
.story li::before { content: ""; position: absolute; left: -2rem; top: 0.45rem; width: 13px; height: 13px; border-radius: 50%; background: var(--ivory); border: 2px solid var(--burgundy); }
.story-year { font-size: 0.66rem; letter-spacing: 0.24em; color: var(--olive); font-weight: 500; }
.story p { color: var(--muted); }

/* ---------- Day program (icon row) ---------- */
.program { list-style: none; display: grid; grid-template-columns: repeat(6, 1fr); gap: 1rem; text-align: center; }
.program li { display: flex; flex-direction: column; align-items: center; gap: 0.3rem; }
.program svg { width: 48px; height: 48px; stroke: rgba(250,248,245,0.72); fill: none; stroke-width: 1.2; stroke-linecap: round; stroke-linejoin: round; margin-bottom: 0.3rem; transition: transform var(--dur-2) var(--ease), stroke var(--dur-1); }
.program li:hover svg { transform: translateY(-4px); stroke: var(--ivory); }
.program .time { font-family: var(--serif); font-size: 1.4rem; font-variant-numeric: tabular-nums; }
.program .name { font-size: 0.64rem; letter-spacing: 0.18em; text-transform: uppercase; color: rgba(250,248,245,0.80); }
.program .place { font-family: var(--serif); font-style: italic; font-size: 0.98rem; color: rgba(250,248,245,0.70); }

/* ---------- Attire ---------- */
.attire { display: grid; grid-template-columns: 1.4fr 1fr; gap: 3rem; align-items: center; }
.attire h2 { text-align: left; }
.swatches { display: flex; gap: 0.9rem; margin-top: 1.5rem; }
.swatches span { width: 44px; height: 44px; border-radius: 50%; box-shadow: inset 0 0 0 3px var(--ivory), 0 0 0 1px var(--line); transition: transform var(--dur-2) var(--ease); }
.swatches span:hover { transform: scale(1.12); }
.card.rsvp { text-align: center; border-top-color: var(--burgundy); padding: 2.4rem 1.6rem; }

/* ---------- Tables ---------- */
.table { width: 100%; border-collapse: collapse; background: var(--paper); border: 1px solid var(--line); }
.table th, .table td { padding: 1rem 1.1rem; text-align: center; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table th { font-weight: 500; font-size: 0.62rem; text-transform: uppercase; letter-spacing: 0.2em; color: var(--ivory); background: var(--olive-deep); }
.table tr:last-child td { border-bottom: 0; }
.table td:first-child { font-family: var(--serif); font-size: 1.15rem; color: var(--burgundy); white-space: nowrap; }
.table td:first-child svg {
  width: 21px; height: 21px; stroke: var(--olive); fill: none;
  stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round;
  vertical-align: -4px; margin-right: 0.55rem;
}

/* ---------- Cards ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1rem; margin-top: 2rem; }

/* ---------- Gifts: one quiet bank-details panel, nothing to click ---------- */
.registry-for {
  max-width: 560px; margin: 1.6rem auto 0; text-align: center;
  font-family: var(--serif); font-style: italic; font-size: 1.18rem; color: var(--burgundy);
}
.registry-details {
  max-width: 440px; margin: 2.6rem auto 0; padding: 3rem 2rem 1.8rem;
  background: var(--paper); border: 1px solid rgba(106, 33, 49, 0.3);
  border-radius: 120px 120px 10px 10px;
  box-shadow: 0 30px 55px -34px rgba(74, 22, 34, 0.45);
  text-align: center;
}
.rd-row { padding: 0.9rem 0; }
.rd-row + .rd-row { border-top: 1px solid rgba(106, 33, 49, 0.18); }
.rd-label { display: block; text-transform: uppercase; letter-spacing: 0.2em; font-size: 0.62rem; color: var(--olive-deep); margin-bottom: 0.3rem; }
.rd-value { font-size: 0.95rem; color: var(--wine-deep); letter-spacing: 0.05em; }
.card { background: var(--paper); border: 1px solid var(--line); border-top: 3px solid var(--sage); padding: 1.8rem 1.6rem; transition: transform var(--dur-2) var(--ease), box-shadow var(--dur-2) var(--ease); }
.card:hover { transform: translateY(-4px); box-shadow: 0 30px 50px -36px rgba(106,33,49,0.5); }
.card h3 { margin-bottom: 0.3rem; }
.card p { color: var(--muted); font-size: 0.92rem; }
.card .meta { color: var(--olive); font-size: 0.66rem; letter-spacing: 0.16em; text-transform: uppercase; margin-bottom: 0.5rem; }
.card.center { text-align: center; }
.card .icon { font-size: 1.8rem; margin-bottom: 0.4rem; }
.link { display: inline-block; margin-top: 0.9rem; color: var(--burgundy); text-decoration: none; font-weight: 500; font-size: 0.7rem; letter-spacing: 0.16em; text-transform: uppercase; transition: color var(--dur-1), letter-spacing var(--dur-2) var(--ease); }
.link:hover { color: var(--olive); letter-spacing: 0.22em; }

/* ---------- Hotels: deep-olive arches, same family as the contact cards ---------- */
#hotels .card {
  background: var(--olive-deep); border: 1px solid var(--olive-deep);
  border-radius: 120px 120px 10px 10px; text-align: center;
  padding: 2.6rem 1.5rem 2.2rem;
}
#hotels .card h3 { color: var(--ivory); font-size: 1.5rem; }
#hotels .card .meta { color: #c9cc92; margin: 0.4rem 0 0.7rem; }
#hotels .card p { color: rgba(250, 248, 245, 0.85); }
#hotels .link { color: var(--ivory); }
#hotels .link:hover { color: #c9cc92; }
#hotels .card:hover { box-shadow: 0 30px 50px -30px rgba(109, 112, 50, 0.7); }

/* ---------- Tab hero (Travel) ---------- */
.tab-hero {
  position: relative; min-height: 400px; display: grid; place-content: center; text-align: center; padding: 3rem 1rem;
  background-size: cover; background-position: center 60%; color: var(--ivory);
}
.tab-hero::before { content: ""; position: absolute; inset: 0; background: linear-gradient(rgba(74,22,34,0.3), rgba(74,22,34,0.65)); }
.tab-hero > * { position: relative; }
.tab-hero h2 { color: var(--ivory); }
.tab-hero .sub { color: rgba(250,248,245,0.86); margin-bottom: 0; }

/* ---------- Venue + map ---------- */
.venue-note {
  text-align: center; max-width: 560px; margin: -0.2rem auto 2rem;
  font-family: var(--serif); font-style: italic; font-size: 1.15rem; color: var(--burgundy);
}
.venue { background: var(--paper); border: 1px solid var(--line); overflow: hidden; }
.venue-photo { margin: 0; overflow: hidden; }
.venue-photo img { width: 100%; height: clamp(300px, 46vw, 440px); object-fit: cover; display: block; transition: transform calc(var(--dur-3) * 2) var(--ease); }
.venue:hover .venue-photo img { transform: scale(1.04); }
.venue-info { padding: 1.4rem 2rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; background: var(--olive-deep); color: var(--ivory); }
.venue-address { font-size: 0.95rem; }

/* ---------- Gallery: editorial grid, captions on hover, lightbox with arrows ---------- */
.gallery { display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 240px; grid-auto-flow: dense; gap: 0.8rem; }
.gallery figure { position: relative; margin: 0; overflow: hidden; background: var(--sage-soft); cursor: zoom-in; }
.gallery figure.wide { grid-column: span 2; }
.gallery figure.tall { grid-row: span 2; }
.gallery img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform calc(var(--dur-3) * 1.5) var(--ease), filter var(--dur-2); }
.gallery figure:hover img { transform: scale(1.05); }
.gallery figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 2.2rem 1rem 0.9rem;
  background: linear-gradient(transparent, rgba(74, 22, 34, 0.65)); color: var(--ivory);
  font-family: var(--serif); font-style: italic; font-size: 1rem;
  opacity: 0; transform: translateY(8px); transition: opacity var(--dur-2) var(--ease), transform var(--dur-2) var(--ease);
}
.gallery figure:hover figcaption { opacity: 1; transform: none; }
.after { text-align: center; max-width: 560px; margin: 4rem auto 0; padding: 2.5rem 1.5rem; border: 1px solid var(--line); background: var(--paper); border-radius: 140px 140px 10px 10px; }
.after p { color: var(--muted); margin-top: 0.4rem; }
.after strong { color: var(--burgundy); font-weight: 500; letter-spacing: 0.05em; }

.lightbox { position: fixed; inset: 0; z-index: 50; background: rgba(44, 13, 20, 0.94); display: grid; place-items: center; padding: 1rem; animation: fade var(--dur-2) var(--ease); }
.lightbox figure { margin: 0; text-align: center; max-width: 100%; animation: rise var(--dur-2) var(--ease); }
.lightbox img { max-width: min(100%, 1100px); max-height: 84vh; display: block; margin: 0 auto; box-shadow: 0 40px 80px -30px rgba(0,0,0,0.7); }
.lightbox figcaption { color: rgba(250,248,245,0.86); font-family: var(--serif); font-style: italic; font-size: 1.15rem; margin-top: 0.9rem; }
.lb-btn, .lb-close { position: absolute; background: none; border: 0; color: var(--ivory); cursor: pointer; opacity: 0.75; transition: opacity var(--dur-1), transform var(--dur-2) var(--ease); }
.lb-btn:hover, .lb-close:hover { opacity: 1; }
.lb-btn { top: 50%; transform: translateY(-50%); font-size: 3.4rem; line-height: 1; padding: 1rem; font-family: var(--serif); }
.lb-prev { left: 0.5rem; } .lb-next { right: 0.5rem; }
.lb-close { top: 0.6rem; right: 1.2rem; font-size: 2.4rem; }

/* ---------- Footer ---------- */
.site-footer { background: var(--burgundy-deep); color: var(--ivory); text-align: center; padding: 2.5rem 1rem; }
.site-footer .tiny { font-size: 0.62rem; letter-spacing: 0.3em; opacity: 0.7; margin-top: 0.3rem; text-transform: uppercase; }

/* ---------- Responsive ---------- */
@media (max-width: 1000px) {
  .nav-toggle { display: block; }
  .nav { display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; gap: 0;
         background: rgba(250, 248, 245, 0.95); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
         border-bottom: 1px solid var(--line); }
  .nav.open { display: flex; animation: rise var(--dur-2) var(--ease); }
  .nav a { padding: 1rem 1.5rem; border-bottom: 1px solid var(--line); }
  .nav a::after { display: none; }
  .nav a.active { font-weight: 500; }
  /* the dropdown is a light pane even while the header glass is over the photo */
  .site-header .nav a { color: var(--muted); }
  .site-header .nav a:hover, .site-header .nav a.active { color: var(--burgundy); }
  .program { grid-template-columns: repeat(3, 1fr); row-gap: 2rem; }
  .gallery { grid-template-columns: repeat(3, 1fr); grid-auto-rows: 200px; }
}
@media (max-width: 760px) {
  .wrap { padding: 3.5rem 1rem; }
  .hero-photo { min-height: 74vh; background-size: auto 131%; background-position: 49% 38%; padding-bottom: 2.5rem; }
  .hero-caption .eyebrow { letter-spacing: 0.2em; }
  .hero-caption h1 .and { font-size: 1.4rem; }
  .hero-below { padding: 2.2rem 1rem 3.2rem; }
  .countdown { gap: 0; }
  .countdown div { padding: 0 0.45rem; }
  .countdown b { font-size: 1.7rem; }
  .love-grid { grid-template-columns: 1fr; }
  .contacts { grid-template-columns: 1fr; }
  .love-divider { text-align: center; }
  .story-layout, .attire, .venue { grid-template-columns: 1fr; }
  .story-photos { max-width: 340px; margin: 0 auto 2.5rem; }
  .attire h2, .kicker.left { text-align: center; }
  .lead.left { text-align: center; margin: 1.2rem auto 0; }
  .swatches { justify-content: center; }
  .program { grid-template-columns: repeat(2, 1fr); }
  .tab-hero { min-height: 280px; }
  .table th, .table td { padding: 0.75rem 0.6rem; font-size: 0.85rem; }
  .gallery { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 170px; gap: 0.5rem; }
  .gallery figcaption { opacity: 1; transform: none; font-size: 0.85rem; padding: 1.6rem 0.7rem 0.6rem; }
  .lb-btn { font-size: 2.6rem; padding: 0.5rem; }
}
