/* ==========================================================================
   Ekene & Noel — invitation styles
   1 Tokens · 2 Base · 3 Shell, frame & tone · 4 Shared pieces
   5 Chapters I–V · 6 Chapter navigation · 7 Motion preferences
   ========================================================================== */

/* 1. Tokens ---------------------------------------------------------------- */
:root {
  /* colour */
  --ivory: #F8F4EC;
  --paper: #FCF9F3;
  --ink: #23201C;
  --ink-soft: #5A5149;
  --burgundy: #6E2A35;
  --burgundy-deep: #57202A;
  --burgundy-night: #4E1A26;      /* gallery backdrop */
  --oxblood: #431D28;
  --gold: #B79A61;
  --champagne: #D8C49A;
  --gold-light: #E2D1A8;          /* gold text on burgundy (6.8:1) */
  --gold-ink: #7A5F2E;            /* gold text on ivory (5.5:1) */
  --emerald: #3F7A63;             /* restrained accent, decorative only */
  --hairline: #DCD0BC;
  --error: #8A2232;
  --gold-sheen: linear-gradient(90deg, rgba(183,154,97,0) 0%, var(--gold) 18%, var(--champagne) 50%, var(--gold) 82%, rgba(183,154,97,0) 100%);

  /* type: three families */
  --serif: "Cormorant Garamond", "Cormorant", Georgia, "Times New Roman", serif;   /* names, headings */
  --display: "Bodoni Moda", "Didot", "Bodoni 72", Georgia, serif;                 /* numerals, expressive italics, address */
  --sans: "Instrument Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; /* supporting text, UI */

  /* space & motion */
  --frame: 10px;
  --pad: clamp(20px, 5vw, 56px);
  --nav-h: 68px;
  --ease-out: cubic-bezier(.22, .8, .2, 1);
  --ease-in-out: cubic-bezier(.65, 0, .35, 1);
  --tone-dur: .7s;
}
@media (min-width: 900px) { :root { --frame: 18px; --nav-h: 76px; } }

/* 2. Base ------------------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html, body { margin: 0; background: var(--ivory); color: var(--ink); }
body { font: 400 17px/1.6 var(--sans); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
.js body { overflow: hidden; }
img { display: block; max-width: 100%; }
h1, h2, h3, p, figure, ol, ul, dl, dd { margin: 0; }
ol, ul { padding: 0; list-style: none; }
button, input, textarea { font: inherit; color: inherit; }
a { color: var(--burgundy); }
::selection { background: var(--champagne); color: var(--ink); }
:focus-visible { outline: 2px solid var(--burgundy); outline-offset: 3px; border-radius: 4px; }
.on-dark :focus-visible, [data-tone="dark"] .chapter-nav :focus-visible { outline-color: var(--champagne); }
[data-chapter-heading]:focus { outline: none; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 16px; top: -60px; z-index: 50; padding: 10px 16px; background: var(--burgundy); color: var(--gold-light); border-radius: 999px; text-decoration: none; }
.skip-link:focus { top: 16px; }
.ico { fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }

/* 3. Shell, frame & tone ---------------------------------------------------- */
.app {
  position: relative; height: 100vh; height: 100dvh;
  display: grid; grid-template-rows: minmax(0, 1fr) auto;
  padding: max(var(--frame), env(safe-area-inset-top)) max(var(--frame), env(safe-area-inset-right)) max(var(--frame), env(safe-area-inset-bottom)) max(var(--frame), env(safe-area-inset-left));
  background-color: var(--ivory);
  transition: background-color var(--tone-dur) var(--ease-in-out);
}
/* Burgundy ↔ ivory: the whole page shifts tone with the chapter */
.app[data-tone="dark"] { background-color: var(--burgundy-night); }
html:not(.js) .app { height: auto; min-height: 100vh; }

.frame { position: absolute; z-index: 30; pointer-events: none; color: var(--gold);
  inset: max(calc(var(--frame) / 2), calc(env(safe-area-inset-top) - 4px)) max(calc(var(--frame) / 2), calc(env(safe-area-inset-right) - 4px)) max(calc(var(--frame) / 2), calc(env(safe-area-inset-bottom) - 4px)) max(calc(var(--frame) / 2), calc(env(safe-area-inset-left) - 4px)); }
.frame__edge { position: absolute; opacity: .7; }
.frame__edge--top, .frame__edge--bottom { left: 26px; right: 26px; height: 1px; background: var(--gold-sheen); }
.frame__edge--top { top: 0; } .frame__edge--bottom { bottom: 0; }
.frame__edge--left, .frame__edge--right { top: 26px; bottom: 26px; width: 1px; background: linear-gradient(180deg, rgba(183,154,97,0), var(--gold) 15%, var(--champagne) 50%, var(--gold) 85%, rgba(183,154,97,0)); }
.frame__edge--left { left: 0; } .frame__edge--right { right: 0; }
.frame__corner { position: absolute; width: 30px; height: 30px; }
.frame__corner--tl { top: 0; left: 0; }
.frame__corner--tr { top: 0; right: 0; transform: scaleX(-1); }
.frame__corner--bl { bottom: 0; left: 0; transform: scaleY(-1); }
.frame__corner--br { bottom: 0; right: 0; transform: scale(-1); }
@media (min-width: 900px) { .frame__corner { width: 40px; height: 40px; } }
.js .frame__edge--top, .js .frame__edge--bottom { animation: drawX 1.3s var(--ease-out) both; }
.js .frame__edge--left, .js .frame__edge--right { animation: drawY 1.3s var(--ease-out) both; }
.js .frame__corner { animation: fadeIn .9s .35s var(--ease-out) both; }
@keyframes drawX { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes drawY { from { transform: scaleY(0); } to { transform: scaleY(1); } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.stage { position: relative; overflow: hidden; min-height: 0; }
.chapter {
  position: absolute; inset: 0; display: flex; flex-direction: column;
  overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch;
  padding: calc(var(--pad) * .9) var(--pad) var(--pad);
  scrollbar-width: thin; scrollbar-color: var(--hairline) transparent;
}
.chapter[hidden] { display: none; }
.chapter__inner { margin-block: auto; width: 100%; max-width: 1180px; margin-inline: auto; }
html:not(.js) .chapter { position: relative; }
.noscript__inner { max-width: 560px; margin: auto; display: grid; gap: 16px; text-align: center; padding: 48px 0; }

.veil { position: absolute; inset: 0; pointer-events: none; z-index: 20; }
.veil__line { position: absolute; left: 6%; right: 6%; top: 50%; height: 1px; background: var(--gold-sheen); transform: scaleX(0); opacity: 0; }

/* 4. Shared pieces ---------------------------------------------------------- */
.eyebrow { display: inline-flex; align-items: center; gap: 12px; font: 600 12px/1.3 var(--sans); letter-spacing: .24em; text-transform: uppercase; color: var(--gold-ink); }
.eyebrow__num { font: italic 500 18px/1 var(--display); letter-spacing: .02em; color: var(--burgundy); text-transform: none; }
.eyebrow__rule { width: 28px; height: 1px; background: var(--gold); }
.on-dark .eyebrow { color: var(--champagne); }
.on-dark .eyebrow__num { color: var(--gold-light); }

.display { font: 500 clamp(40px, min(13vw, 8.4dvh), 128px)/.92 var(--serif); letter-spacing: -.015em; }
.display em { font-style: italic; font-weight: 400; color: var(--burgundy); }
.title { font: 500 clamp(30px, min(8.6vw, 6.4dvh), 60px)/1.04 var(--serif); letter-spacing: -.01em; }
.lede { font: 400 clamp(21px, min(5vw, 3.2dvh), 30px)/1.3 var(--serif); }
.meridiem { font-style: italic; font-size: .42em; letter-spacing: 0; margin-left: .14em; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 12px; min-height: 50px; padding: 0 26px; border-radius: 999px;
  font: 500 15px/1 var(--sans); letter-spacing: .03em; text-decoration: none; cursor: pointer; border: 1px solid transparent; white-space: nowrap;
  transition: background-color .3s var(--ease-out), color .3s var(--ease-out), border-color .3s var(--ease-out), transform .25s var(--ease-out);
}
.btn .ico { width: 18px; height: 18px; transition: transform .35s var(--ease-out); }
.btn:active { transform: scale(.98); }
.btn--primary { background: var(--burgundy); color: var(--gold-light); box-shadow: inset 0 0 0 1px rgba(216,196,154,.35); }
.btn--primary:hover { background: var(--burgundy-deep); color: var(--gold-light); }
.btn--primary:hover .arrow { transform: translateX(3px); }

.monogram { width: 54px; height: 54px; color: var(--gold); }
.monogram circle { fill: none; stroke: currentColor; }
.monogram .thin { stroke-width: .6; }
.monogram text { font: italic 17px var(--display); fill: var(--ink); text-anchor: middle; }
.ornament { width: 120px; height: 12px; color: var(--gold); display: block; }
.ornament__line { stroke: currentColor; stroke-width: 1; }
.ornament__gem, .ornament circle { fill: currentColor; }

.media { position: relative; overflow: hidden; background: #E8DFD1; }
.media > img, .media > video, .media > picture, .media picture img { width: 100%; height: 100%; object-fit: cover; }
.arch-wrap { position: relative; justify-self: center; }
.arch-wrap::before { content: ""; position: absolute; inset: -9px; border: 1px solid var(--gold); border-radius: 999px 999px 24px 24px; opacity: .75; pointer-events: none; }
.arch { border-radius: 999px 999px 18px 18px; }

.arrival-chip { white-space: nowrap; display: inline-flex; align-items: center; gap: 10px; padding: 8px 16px 8px 12px; border: 1px solid var(--gold); border-radius: 999px; background: rgba(252,249,243,.7); font-size: 15px; color: var(--ink); }
.arrival-chip .ico { width: 18px; height: 18px; stroke: var(--burgundy); stroke-width: 1.5; }
.arrival-chip strong { color: var(--burgundy); font-weight: 600; }

/* address: Bodoni at text size — characterful but readable */
.address { font: 400 17px/1.5 var(--display); font-style: normal; font-variant-numeric: lining-nums; color: var(--ink); }

/* 5. Chapters -------------------------------------------------------------- */

/* I — The Invitation */
.c-invite .chapter__inner { display: grid; justify-items: center; text-align: center; gap: clamp(14px, 2.6dvh, 26px); }
.c-invite .arch-wrap { margin-top: 10px; }
.c-invite .arch { height: clamp(150px, 31dvh, 440px); aspect-ratio: 4 / 5; }
.invite__copy { display: grid; justify-items: center; gap: clamp(12px, 2.2dvh, 22px); }
.invite__mono { display: none; }
.invite__lede { max-width: 25ch; }
.occasion { font: italic 400 clamp(19px, 4.8vw, 24px)/1.2 var(--display); color: var(--burgundy); letter-spacing: .01em; }
.date-line { font: 400 clamp(28px, 7.4vw, 38px)/1 var(--display); letter-spacing: .06em; color: var(--ink); font-variant-numeric: lining-nums; white-space: nowrap; }
.date-line__sep { color: var(--gold); font-weight: 300; margin: 0 .12em; }
@media (min-width: 900px) {
  .c-invite .chapter__inner { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); align-items: center; justify-items: start; text-align: left; column-gap: clamp(48px, 7vw, 120px); }
  .c-invite .arch-wrap { justify-self: end; margin: 0; }
  .c-invite .arch { height: min(70dvh, 660px); }
  .invite__copy { justify-items: start; }
  .invite__mono { display: block; }
}

/* II — Ceremony */
.c-ceremony .chapter__inner { display: grid; gap: clamp(18px, 2.8dvh, 32px); max-width: 1120px; }
.ceremony__head { display: grid; gap: 10px; justify-items: center; text-align: center; }
.c-ceremony .title { white-space: nowrap; }
.year-mark { display: flex; align-items: center; gap: 12px; font: 400 clamp(24px, 5.4vw, 32px)/1 var(--display); letter-spacing: .24em; color: var(--gold-ink); font-variant-numeric: lining-nums; }
.year-mark span { margin-right: -.24em; }    /* balance the trailing letter-space */
.year-mark::before, .year-mark::after { content: ""; width: 34px; height: 1px; background: linear-gradient(90deg, rgba(183,154,97,0), var(--gold)); }
.year-mark::after { transform: scaleX(-1); }
.ceremony__body { display: grid; gap: clamp(18px, 2.8dvh, 30px); max-width: 560px; width: 100%; margin-inline: auto; }
.arrival { position: relative; text-align: center; padding: clamp(14px, 2.4dvh, 24px) 0; border-top: 1px solid var(--gold); border-bottom: 1px solid var(--gold); }
.arrival::before, .arrival::after { content: ""; position: absolute; left: 50%; width: 7px; height: 7px; background: var(--ivory); border: 1px solid var(--gold); transform: translate(-50%, -50%) rotate(45deg); }
.arrival::before { top: 0; } .arrival::after { top: 100%; }
.arrival__label { font: 600 12px/1.3 var(--sans); letter-spacing: .24em; text-transform: uppercase; color: var(--gold-ink); }
.arrival__time { font: 400 clamp(52px, min(16vw, 10dvh), 112px)/1 var(--display); color: var(--burgundy); letter-spacing: -.01em; margin-top: 6px; white-space: nowrap; }
.schedule__row { display: grid; grid-template-columns: 9.6em minmax(0, 1fr); gap: 20px; align-items: baseline; padding: clamp(8px, 1.3dvh, 12px) 0; border-bottom: 1px solid var(--hairline); }
.schedule__row:first-child { border-top: 1px solid var(--hairline); }
.schedule__time { font: 400 18px/1.2 var(--display); letter-spacing: .04em; word-spacing: .12em; white-space: nowrap; }
.schedule__what { font-size: 16px; white-space: nowrap; }
.venue { display: grid; gap: 10px; justify-items: center; text-align: center; }
.venue__label { font: 600 12px/1.3 var(--sans); letter-spacing: .24em; text-transform: uppercase; color: var(--gold-ink); }
.venue__name { font: 500 clamp(21px, 5.4vw, 28px)/1.1 var(--serif); letter-spacing: .06em; text-transform: uppercase; }
.venue__main { white-space: nowrap; }
.venue__note { display: inline-flex; align-items: center; gap: 10px; font-size: 13.5px; line-height: 1.35; color: var(--ink-soft); text-align: left; max-width: 32ch; }
.parking-badge { display: inline-grid; place-items: center; width: 22px; height: 22px; flex: none; border: 1px solid var(--gold); border-radius: 5px; font: 600 12px/1 var(--sans); color: var(--gold-ink); }
.venue__alt { display: block; font: italic 400 18px/1.3 var(--serif); letter-spacing: 0; text-transform: none; color: var(--ink-soft); margin-top: 4px; }
.ceremony__photo { display: none; }
.ceremony__right { display: grid; gap: clamp(18px, 2.8dvh, 28px); }
@media (max-width: 420px) { .schedule__row { grid-template-columns: 8.6em minmax(0, 1fr); gap: 14px; } .schedule__time { font-size: 16px; } }
/* Phones and tablets: the schedule follows the centred column (time over a gold label, diamond between entries) */
@media (max-width: 899px) {
  .schedule { display: grid; justify-items: center; gap: 10px; }
  .schedule .schedule__row { display: grid; grid-template-columns: none; justify-items: center; gap: 3px; padding: 0; border: 0; text-align: center; }
  .schedule .schedule__row + .schedule__row::before { content: ""; width: 6px; height: 6px; border: 1px solid var(--gold); transform: rotate(45deg); margin-bottom: 9px; }
  .schedule .schedule__time { font-size: 21px; }
  .schedule .schedule__what { font: 600 11px/1.3 var(--sans); letter-spacing: .22em; text-transform: uppercase; color: var(--gold-ink); }
}
@media (min-width: 900px) {
  .c-ceremony .chapter__inner { grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); column-gap: clamp(40px, 6vw, 96px); align-items: center; }
  .ceremony__photo { display: block; grid-row: 1 / span 2; }
  .ceremony__photo .arch { height: min(72dvh, 640px); aspect-ratio: 3 / 4.4; }
  .ceremony__head { justify-items: start; text-align: left; }
  .year-mark::before { display: none; }
  .ceremony__body { max-width: none; margin: 0; }
  .arrival { text-align: left; }
  .arrival::before, .arrival::after { left: 0; transform: translate(0, -50%) rotate(45deg); }
}
@media (min-width: 1200px) { .ceremony__right { grid-template-columns: minmax(0, 1fr) auto; column-gap: clamp(32px, 3.6vw, 56px); align-items: start; } }
@media (min-width: 900px) and (max-width: 1199px) {
  .c-ceremony .chapter__inner { grid-template-columns: minmax(0, 1fr); max-width: 820px; gap: 22px; }
  .ceremony__photo { display: none; }
  .ceremony__right { grid-template-columns: minmax(0, 1fr) auto; column-gap: 40px; align-items: start; }
}

/* III — Our Moments: burgundy room, stacked photographs */
.c-moments { color: var(--ivory); background: radial-gradient(120% 80% at 30% 10%, rgba(216,196,154,.08), rgba(216,196,154,0) 60%); }
.c-moments .chapter__inner { display: grid; justify-items: center; gap: clamp(12px, 2.2dvh, 24px); }
.moments__head { display: grid; gap: 6px; justify-items: center; text-align: center; }
.c-moments .title { color: var(--ivory); font-size: clamp(28px, min(7.6vw, 5.4dvh), 56px); }

.stack { position: relative; height: clamp(230px, 46dvh, 760px); aspect-ratio: 2 / 3; margin-right: 6%; }
.card {
  position: absolute; inset: 0; margin: 0; padding: clamp(5px, 1.2vw, 9px);
  background: #F6EEE1; border-radius: 8px;
  box-shadow: 0 30px 50px -26px rgba(16,4,8,.85), 0 8px 18px -8px rgba(16,4,8,.5);
  transform: var(--t); opacity: var(--o); z-index: var(--z); filter: var(--f, none);
  transform-origin: 50% 90%;
  transition: transform .7s var(--ease-out), opacity .7s var(--ease-out), filter .7s var(--ease-out);
}
.card::after { content: ""; position: absolute; inset: 3px; border: 1px solid rgba(183,154,97,.6); border-radius: 6px; pointer-events: none; }
.card__photo { width: 100%; height: 100%; overflow: hidden; border-radius: 3px; background: #2B1117; }
.card__photo img { width: 100%; height: 100%; object-fit: cover; }
.pos-0 { --t: none; --o: 1; --z: 5; --f: none; }
.pos-1 { --t: translate(8%, -3%) rotate(4deg) scale(.93); --o: .95; --z: 4; --f: brightness(.62) saturate(.85); }
.pos-2 { --t: translate(15%, -5.5%) rotate(8deg) scale(.86); --o: .8; --z: 3; --f: brightness(.45) saturate(.8); }
.pos-3 { --t: translate(18%, -7%) rotate(10deg) scale(.8); --o: 0; --z: 2; --f: brightness(.4); }
.pos-4 { --t: translate(-9%, -3%) rotate(-5deg) scale(.91); --o: .7; --z: 1; --f: brightness(.45) saturate(.8); }
.card.is-leaving { animation: cardLeave .9s var(--ease-in-out) both; transition: none; }
.card.is-returning { animation: cardReturn .9s var(--ease-in-out) both; transition: none; }
@keyframes cardLeave {
  0%   { transform: none; opacity: 1; z-index: 6; filter: none; }
  45%  { transform: translate(-58%, -2%) rotate(-11deg) scale(.97); opacity: 1; z-index: 6; filter: none; }
  55%  { z-index: 1; }
  100% { transform: translate(-9%, -3%) rotate(-5deg) scale(.91); opacity: .7; z-index: 1; filter: brightness(.45) saturate(.8); }
}
@keyframes cardReturn {
  0%   { transform: translate(-9%, -3%) rotate(-5deg) scale(.91); opacity: .7; z-index: 1; filter: brightness(.45) saturate(.8); }
  45%  { transform: translate(-58%, -2%) rotate(-11deg) scale(.97); opacity: 1; z-index: 1; filter: none; }
  55%  { z-index: 6; }
  100% { transform: none; opacity: 1; z-index: 6; filter: none; }
}

.moments__foot { display: grid; justify-items: center; gap: 12px; width: 100%; }
.caption { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 2.5em; font: italic 400 clamp(20px, 5vw, 26px)/1.25 var(--serif); color: #F3E9D8; text-align: center; max-width: min(30ch, 100%); }
.caption::before { content: ""; width: 6px; height: 6px; flex: none; transform: rotate(45deg); background: var(--emerald); box-shadow: 0 0 0 1px rgba(216,196,154,.5); }
.photo-nav { display: flex; align-items: center; justify-content: center; gap: 10px; }
.thumbs { display: flex; gap: 8px; }
.thumb {
  width: 44px; height: 44px; padding: 0; border-radius: 50%; overflow: hidden; cursor: pointer; background: #2B1117;
  border: 1px solid rgba(183,154,97,.55); opacity: .55;
  transition: opacity .35s var(--ease-out), transform .35s var(--ease-out), box-shadow .35s var(--ease-out);
}
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb:hover { opacity: .85; }
.thumb[aria-current="true"] { opacity: 1; transform: scale(1.06); border-color: var(--champagne); box-shadow: 0 0 0 2px var(--burgundy-night), 0 0 0 3px var(--gold); }
.photo-step {
  width: 44px; height: 44px; flex: none; border-radius: 50%; border: 1px solid rgba(183,154,97,.75); background: transparent; color: var(--gold-light);
  display: inline-flex; align-items: center; justify-content: center; cursor: pointer;
  transition: background-color .3s var(--ease-out), color .3s var(--ease-out);
}
.photo-step:hover { background: var(--gold); color: var(--oxblood); }
.photo-step .ico { width: 18px; height: 18px; stroke-width: 1.5; }
.photo-count { font: italic 400 15px/1 var(--display); color: var(--champagne); letter-spacing: .04em; }
@media (max-width: 379px) {
  .thumbs { gap: 5px; }
  .thumb { width: 38px; height: 38px; }
  .photo-step { width: 40px; height: 40px; }
  .photo-nav { gap: 6px; }
}
@media (min-width: 900px) {
  .c-moments .chapter__inner { grid-template-columns: auto minmax(0, 1fr); grid-template-rows: auto auto; column-gap: clamp(64px, 8vw, 140px); align-items: center; justify-items: start; }
  .stack { grid-row: 1 / span 2; grid-column: 1; height: min(70dvh, 700px); margin-right: 14%; }
  .moments__head { grid-column: 2; justify-items: start; text-align: left; align-self: end; }
  .moments__foot { grid-column: 2; justify-items: start; align-self: start; gap: 18px; }
  .caption { justify-content: flex-start; text-align: left; font-size: clamp(24px, 2.2vw, 32px); }
  .photo-nav { justify-content: flex-start; }
  .thumb { width: 52px; height: 52px; }
}

/* IV — Dinner */
.c-dinner .chapter__inner { display: grid; justify-items: center; text-align: center; max-width: 1080px; }
.dinner__photo { display: none; }
.dinner__copy { display: grid; justify-items: center; gap: clamp(14px, 2.4dvh, 22px); }
.dinner__title { display: grid; justify-items: center; font: italic 400 clamp(84px, min(26vw, 17dvh), 180px)/.82 var(--serif); color: var(--burgundy); letter-spacing: -.02em; }
.dinner__at { font: italic 400 clamp(22px, 5.6vw, 32px)/1.2 var(--display); color: var(--ink); letter-spacing: .01em; margin-top: .35em; }
.dinner__note { font: 400 clamp(18px, 4.6vw, 21px)/1.35 var(--serif); color: var(--ink-soft); max-width: 30ch; text-wrap: balance; }
.dinner__facts { display: grid; grid-template-columns: auto 1px auto; align-items: center; column-gap: clamp(18px, 5vw, 32px); }
.dinner__facts::before { content: ""; grid-column: 2; grid-row: 1; width: 1px; height: 64%; background: var(--gold); }
.dinner__facts > div:first-child { grid-column: 1; grid-row: 1; }
.dinner__facts > div:last-child { grid-column: 3; grid-row: 1; }
.dinner__facts dt { font: 600 11px/1.3 var(--sans); letter-spacing: .26em; text-transform: uppercase; color: var(--gold-ink); margin-bottom: 6px; }
.dinner__time { font: 400 clamp(40px, 11vw, 56px)/1 var(--display); color: var(--burgundy); white-space: nowrap; }
.dinner__date { font: 400 clamp(17px, 4.4vw, 21px)/1.25 var(--display); white-space: nowrap; }
.attire-line { display: flex; align-items: baseline; gap: 12px; margin-top: 14px; white-space: nowrap; }
.attire-line__label { font: 600 11px/1.3 var(--sans); letter-spacing: .24em; text-transform: uppercase; color: var(--gold-ink); }
.attire-line__name { font: italic 400 20px/1.2 var(--display); color: var(--burgundy); }
@media (max-width: 899px) { .attire-line { justify-content: center; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--hairline); } }
.attire { position: relative; display: grid; justify-items: center; gap: 2px; padding: 12px 26px 13px; border: 1px solid rgba(183,154,97,.7); border-radius: 14px; text-align: center; background: rgba(252,249,243,.6); }
.attire::before { content: ""; position: absolute; inset: 4px; border: 1px solid rgba(183,154,97,.28); border-radius: 10px; pointer-events: none; }
.attire__label { font: 600 11px/1.3 var(--sans); letter-spacing: .26em; text-transform: uppercase; color: var(--gold-ink); }
.attire__name { font: italic 400 clamp(23px, 5.6vw, 28px)/1.15 var(--display); color: var(--burgundy); white-space: nowrap; }
.attire__note { font-size: 13.5px; line-height: 1.4; color: var(--ink-soft); max-width: 30ch; }
@media (max-width: 379px) { .dinner__facts { grid-template-columns: auto; row-gap: 12px; } .dinner__facts::before { display: none; } .dinner__facts > div:last-child { grid-column: 1; grid-row: 2; } }
@media (min-width: 900px) {
  .c-dinner .chapter__inner { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); column-gap: clamp(48px, 7vw, 110px); align-items: center; text-align: left; }
  .dinner__copy { justify-items: start; grid-column: 1; grid-row: 1; }
  .dinner__title { justify-items: start; }
  .dinner__photo { display: block; grid-column: 2; grid-row: 1; justify-self: center; }
  .dinner__photo .arch { height: min(66dvh, 600px); aspect-ratio: 3 / 4.2; }
  .dinner__copy { gap: 14px; }
  .dinner__title { font-size: clamp(84px, 12.5dvh, 150px); }
  .dinner__note { max-width: 42ch; }
  .dinner__photo img { object-position: 50% 22%; }
}

/* V — Your Reply */
.c-reply .chapter__inner { display: grid; gap: clamp(16px, 2.8dvh, 28px); max-width: 1040px; }
.reply__intro { display: grid; gap: 10px; justify-items: center; text-align: center; }
.reply__portrait { display: none; }
.reply__by { color: var(--ink-soft); }
.reply__by strong { color: var(--ink); font-weight: 600; white-space: nowrap; }
.reply__panel { width: 100%; max-width: 520px; margin-inline: auto; display: grid; gap: 16px; }
.field { display: grid; gap: 6px; }
.field__label { font-size: 15px; font-weight: 600; padding: 0; }
.field__opt { font-weight: 400; color: var(--ink-soft); }
.input { width: 100%; min-height: 50px; padding: 12px 16px; border: 1px solid #CFC4B2; border-radius: 12px; background: #FFFDF9; font-size: 17px; line-height: 1.4; color: var(--ink); transition: border-color .25s var(--ease-out), box-shadow .25s var(--ease-out); }
.input::placeholder { color: #8C8278; }
.input:focus { outline: none; border-color: var(--burgundy); box-shadow: 0 0 0 4px rgba(110,42,53,.12); }

.choice-group { border: 0; margin: 0; padding: 0; min-width: 0; display: grid; gap: 10px; }
.choice-group legend { margin-bottom: 8px; }
.option { position: relative; display: block; }
.option input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.option__face {
  position: relative; overflow: hidden; display: flex; align-items: center; gap: 14px; min-height: 60px; padding: 12px 18px;
  border: 1px solid #CFC4B2; border-radius: 16px; background: #FFFDF9; cursor: pointer; white-space: nowrap;
  font: 500 17px/1.2 var(--sans); color: var(--ink);
  transition: background-color .45s var(--ease-out), color .45s var(--ease-out), border-color .45s var(--ease-out), box-shadow .45s var(--ease-out), transform .25s var(--ease-out);
}
.option:hover .option__face { border-color: var(--gold); }
.option__face:active { transform: scale(.99); }
.option__mark { position: relative; width: 18px; height: 18px; flex: none; border-radius: 50%; border: 1px solid currentColor; }
.option__mark::after { content: ""; position: absolute; inset: 4px; border-radius: 50%; background: currentColor; transform: scale(0); transition: transform .35s var(--ease-out); }
.option input:checked + .option__face .option__mark::after { transform: scale(1); }
.option input:focus-visible + .option__face { outline: 2px solid var(--burgundy); outline-offset: 3px; }
/* Joyfully attending: burgundy and gold, with a single shimmer when chosen */
.option--yes input:checked + .option__face {
  background: linear-gradient(135deg, var(--burgundy) 0%, var(--burgundy-deep) 100%); color: var(--gold-light); border-color: var(--gold);
  box-shadow: inset 0 0 0 1px rgba(216,196,154,.35), 0 16px 30px -18px rgba(67,29,40,.7);
}
.option__shine { position: absolute; inset: 0; pointer-events: none; transform: translateX(-120%);
  background: linear-gradient(105deg, rgba(216,196,154,0) 30%, rgba(232,214,170,.45) 46%, rgba(255,244,214,.75) 50%, rgba(232,214,170,.45) 54%, rgba(216,196,154,0) 70%); }
.option__face.is-celebrating .option__shine { animation: shine 1.2s var(--ease-in-out) .1s both; }
@keyframes shine { from { transform: translateX(-120%); } to { transform: translateX(120%); } }
/* Sadly can't make it: quiet and understated */
.option--no input:checked + .option__face { background: #EFE8DD; border-color: var(--ink-soft); color: var(--ink); }

.response { display: grid; justify-items: center; text-align: center; padding: 4px 8px 0; }
.response[hidden], .response__yes[hidden], .response__no[hidden] { display: none; }
.response__yes, .response__no { display: grid; justify-items: center; gap: 8px; }
.response__title { font: italic 400 clamp(28px, 6.4vw, 36px)/1.1 var(--serif); color: var(--burgundy); }
.response__no .response__title { color: var(--ink); }
.response__text { color: #4A423B; max-width: 34ch; }
.flourish { width: 140px; height: 22px; color: var(--gold); }
.flourish__line { fill: none; stroke: currentColor; stroke-width: 1.2; stroke-dasharray: 200; stroke-dashoffset: 200; }
.flourish__gem { fill: currentColor; transform-origin: 80px 12px; transform: scale(0); }
.flourish.is-drawn .flourish__line { stroke-dashoffset: 0; transition: stroke-dashoffset 1.1s var(--ease-out) .15s; }
.flourish.is-drawn .flourish__gem { transform: scale(1); transition: transform .5s var(--ease-out) .7s; }

.prototype-note { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding: 10px 12px; border: 1px dashed var(--gold); border-radius: 12px; background: rgba(252,249,243,.8); font-size: 13.5px; line-height: 1.45; color: #4A423B; }
.prototype-note > span { flex: 1 1 200px; }
.prototype-note .ico { flex: none; width: 18px; height: 18px; stroke: var(--gold-ink); }
.link-btn { min-height: 44px; padding: 0 6px; border: 0; background: none; cursor: pointer; font-size: 14px; color: var(--burgundy); text-decoration: underline; text-underline-offset: 3px; }
.link-btn[hidden] { display: none; }
@media (min-width: 900px) {
  .c-reply .chapter__inner { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); column-gap: clamp(48px, 7vw, 110px); align-items: center; }
  .reply__intro { justify-items: start; text-align: left; }
  .reply__portrait { display: block; width: 132px; height: 132px; border-radius: 50%; box-shadow: 0 0 0 6px var(--ivory), 0 0 0 7px var(--gold); margin: 8px 0 14px 7px; }
  .reply__portrait img { object-position: 50% 28%; }
}

/* Short phones: tighten vertical rhythm */
@media (max-width: 899px) and (max-height: 760px) {
  .chapter { padding-top: 14px; }
  .c-invite .arch { height: clamp(140px, 25dvh, 300px); }
  .c-invite .chapter__inner, .invite__copy { gap: 10px; }
  .arrival { padding: 10px 0; }
  .arrival__time { font-size: clamp(46px, 8dvh, 84px); }
  .schedule__row { padding: 7px 0; }
  .schedule { gap: 6px; }
  .schedule .schedule__time { font-size: 19px; }
  .schedule .schedule__row + .schedule__row::before { margin-bottom: 6px; }
  .attire-line { margin-top: 6px; padding-top: 0; border-top: 0; }
  .attire-line__name { font-size: 18px; }
  .arrival { padding: 6px 0; }
  .arrival__time { font-size: clamp(44px, 7.2dvh, 80px); margin-top: 2px; }
  .year-mark { font-size: 21px; }
  .schedule { gap: 4px; }
  .schedule .schedule__time { font-size: 18px; }
  .schedule .schedule__row + .schedule__row::before { margin-bottom: 4px; }
  .c-ceremony .chapter__inner, .ceremony__body, .ceremony__right { gap: 14px; }
  .venue { gap: 6px; }
  .ceremony__head { gap: 6px; }
  .c-moments .chapter__inner { gap: 10px; }
  .reply__panel { gap: 12px; }
  .dinner__copy { gap: 9px; }
  .dinner__title { font-size: clamp(70px, 13dvh, 110px); }
  .attire { padding: 9px 22px 10px; }
}

/* "More below" cue */
.more-cue { position: absolute; left: 50%; bottom: 10px; z-index: 15; transform: translateX(-50%); display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 14px; border-radius: 999px; background: rgba(252,249,243,.94); border: 1px solid var(--gold); color: var(--gold-ink); font: 600 11px/1 var(--sans); letter-spacing: .18em; text-transform: uppercase; pointer-events: none; opacity: 0; transition: opacity .35s var(--ease-out), transform .35s var(--ease-out); box-shadow: 0 8px 20px -12px rgba(35,32,28,.35); }
.more-cue .ico { width: 14px; height: 14px; }
.more-cue.is-visible { opacity: 1; transform: translate(-50%, -2px); }

/* 6. Chapter navigation ---------------------------------------------------- */
.chapter-nav { position: relative; z-index: 25; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 10px; min-height: var(--nav-h); padding: 10px clamp(6px, 2vw, 22px) 6px; }
.chapter-nav::before { content: ""; position: absolute; top: 0; left: 12px; right: 12px; height: 1px; background: var(--gold-sheen); opacity: .7; }
html:not(.js) .chapter-nav { display: none; }
.nav-btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-width: 48px; height: 48px; padding: 0 18px; border-radius: 999px; cursor: pointer; font: 500 14px/1 var(--sans); letter-spacing: .04em; white-space: nowrap;
  transition: background-color var(--tone-dur) var(--ease-out), color var(--tone-dur) var(--ease-out), border-color var(--tone-dur) var(--ease-out), transform .2s var(--ease-out); }
.nav-btn .ico { width: 18px; height: 18px; transition: transform .35s var(--ease-out); }
.nav-btn:active { transform: scale(.97); }
.nav-btn--prev { background: transparent; color: var(--ink); border: 1px solid var(--hairline); }
.nav-btn--prev:hover { border-color: var(--ink); }
.nav-btn--prev:hover .ico { transform: translateX(-2px); }
.nav-btn--next { background: var(--burgundy); color: var(--gold-light); border: 1px solid var(--burgundy); }
.nav-btn--next:hover { background: var(--burgundy-deep); }
.nav-btn--next:hover .ico { transform: translateX(2px); }
.nav-btn[aria-disabled="true"] { opacity: .35; cursor: default; pointer-events: none; }
.nav-btn[data-hidden="true"] { visibility: hidden; }
@media (max-width: 479px) { .nav-btn { padding: 0; width: 48px; } .nav-btn__text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; } }
.progress { display: grid; justify-items: center; gap: 2px; min-width: 0; }
.progress__meta { display: flex; align-items: baseline; gap: 10px; font-size: 11px; letter-spacing: .2em; text-transform: uppercase; white-space: nowrap; max-width: 100%; overflow: hidden; }
.progress__count { font-variant-numeric: tabular-nums; color: var(--burgundy); font-weight: 600; transition: color var(--tone-dur) var(--ease-out); }
.progress__label { color: var(--ink-soft); overflow: hidden; text-overflow: ellipsis; transition: color var(--tone-dur) var(--ease-out); }
.progress__steps { display: flex; align-items: center; }
.progress__step { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; padding: 0; border: 0; background: transparent; cursor: pointer; }
.progress__step::before { content: ""; width: 18px; height: 2px; border-radius: 2px; background: var(--hairline); transition: width .45s var(--ease-out), background-color .45s var(--ease-out); }
.progress__step.is-done::before { background: var(--gold); }
.progress__step[aria-current="step"]::before { width: 26px; background: var(--burgundy); }
.progress__step:hover::before { background: var(--gold-ink); }
@media (max-width: 359px) { .progress__label { display: none; } }
/* nav on the burgundy chapter: gold on burgundy */
[data-tone="dark"] .nav-btn--prev { color: var(--gold-light); border-color: rgba(216,196,154,.45); }
[data-tone="dark"] .nav-btn--prev:hover { border-color: var(--gold-light); }
[data-tone="dark"] .nav-btn--next { background: var(--champagne); border-color: var(--champagne); color: var(--oxblood); }
[data-tone="dark"] .nav-btn--next:hover { background: var(--gold-light); }
[data-tone="dark"] .progress__count { color: var(--gold-light); }
[data-tone="dark"] .progress__label { color: #E7DAC4; }
[data-tone="dark"] .progress__step::before { background: rgba(216,196,154,.28); }
[data-tone="dark"] .progress__step.is-done::before { background: var(--gold); }
[data-tone="dark"] .progress__step[aria-current="step"]::before { background: var(--gold-light); }

/* 7. Motion preferences ---------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
