:root {
  --cream: #FBF4E4;
  --paper: #F6ECDA;
  --beige: #E9DCCB;
  --hairline: #E3D1BE;
  --plum: #3A1426;
  --plum-muted: #7A5A64;
  --wine: #6E0F3A;
  --pink: #F3C9CF;
  --forest: #2F4A36;
  --olive: #DCE3C6;
  --serif: 'Instrument Serif', Georgia, serif;
  --sans: 'Hanken Grotesk', system-ui, sans-serif;
  --gutter: 20px;
}

* { box-sizing: border-box; }
html, body { margin: 0; background: var(--cream); color: var(--plum); -webkit-font-smoothing: antialiased; }
html { scroll-behavior: smooth; }
body { font-family: var(--sans); font-weight: 300; font-size: 17px; line-height: 1.6; }
body.locked, html.locked { overflow: hidden; }
a { color: var(--wine); text-decoration-thickness: 1px; text-underline-offset: 4px; }
a:hover { color: var(--plum); }
strong { font-weight: 500; }
p { margin: 0; text-wrap: pretty; }
figure { margin: 0; }
[hidden] { display: none !important; }

/* Shared type */
.eyebrow, .eyebrow-sm, .label, .eyebrow-link {
  font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase;
}
.eyebrow { font-size: 13px; color: var(--plum-muted); }
.eyebrow-sm { font-size: 12px; color: var(--plum-muted); }
h2 {
  margin: 0; font-family: var(--serif); font-weight: 400;
  font-size: clamp(48px, 9vw, 88px); line-height: 0.95; color: var(--wine);
}
.mark { font-family: var(--serif); font-size: 24px; line-height: 1; color: var(--cream); text-decoration: none; }
.eyebrow-link {
  all: unset; cursor: pointer; font-family: var(--sans);
  font-size: 13px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--cream); text-decoration: none; padding: 10px 0;
}
.eyebrow-link:focus-visible, .mark:focus-visible { outline: 1px solid currentColor; outline-offset: 4px; }

/* Layout */
.wrap { max-width: 1120px; margin: 0 auto; }
.section { padding: 96px var(--gutter); }
.section.ruled { border-top: 1px solid var(--hairline); }
.split {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
  gap: 32px 72px;
}
.stack { display: grid; gap: 48px; }
.title-col { display: grid; gap: 12px; align-content: start; }
.title-col .intro { margin-top: 6px; max-width: 420px; }
.rows { display: grid; }
.blocks { display: grid; gap: 36px; }
.blocks-tight { gap: 28px; }
.block { display: grid; gap: 6px; border-top: 1px solid var(--hairline); padding-top: 18px; }
.blocks-tight .block { gap: 4px; }
.block-loose { gap: 10px; }
.block-name { font-family: var(--serif); font-size: 32px; line-height: 1.1; }
.block .strong { font-weight: 500; }
.small-link { justify-self: start; font-weight: 500; font-size: 15px; }
.lead { font-family: var(--serif); font-size: 26px; line-height: 1.25; color: var(--wine); }
.aside { font-family: var(--serif); font-style: italic; font-size: 24px; line-height: 1.3; color: var(--wine); }

/* Photo placeholder: beige box with a label; the img (if present) covers it. */
.ph { position: relative; background: var(--beige); overflow: hidden; }
.ph::before {
  content: attr(data-label); position: absolute; inset: 0; display: grid; place-items: center;
  padding: 12px; text-align: center; font-family: var(--serif); font-size: 22px; color: var(--wine); opacity: 0.6;
}
.ph img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }

/* Top bar */
.topbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 30;
  display: flex; justify-content: space-between; align-items: center;
  padding: 18px var(--gutter); padding-top: max(18px, env(safe-area-inset-top));
  color: var(--cream); pointer-events: none;
  transition: opacity 1.2s ease, visibility 1.2s;
}
.topbar a, .topbar button { pointer-events: auto; transition: color 0.3s ease; }
/* main.js adds on-light over cream sections; over dark sections and photos the bar stays cream. */
.topbar { text-shadow: 0 1px 10px rgba(58,20,38,0.45); }
.topbar.on-light { text-shadow: none; }
.topbar.on-light .mark, .topbar.on-light .eyebrow-link { color: var(--plum); }
.topbar-right { display: flex; gap: 22px; align-items: center; }
.intro-running .topbar { opacity: 0; visibility: hidden; }

/* Menu */
.menu {
  position: fixed; inset: 0; z-index: 40; background: var(--wine); color: var(--cream);
  padding: 18px var(--gutter) 40px; padding-top: max(18px, env(safe-area-inset-top));
  display: grid; grid-template-rows: auto 1fr auto; overflow: auto;
}
.menu-head { display: flex; justify-content: space-between; align-items: center; }
.menu-nav {
  display: grid; align-content: center; gap: 4px;
  font-family: var(--serif); font-size: clamp(40px, 10vw, 72px); line-height: 1.15;
}
.menu-nav a { color: var(--cream); text-decoration: none; justify-self: start; }
.menu-nav a:hover { color: var(--pink); }
.menu-nav .menu-rsvp { color: var(--pink); font-style: italic; }
.menu-foot { font-size: 13px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--pink); }

/* Hero */
.hero {
  position: relative; height: 100vh; height: 100svh; min-height: 560px;
  background: var(--wine); color: var(--cream); overflow: hidden;
}
.hero-video {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  visibility: hidden; transition: opacity 1.8s ease;
}
.hero.video-ready .hero-video { visibility: visible; }
.hero-shade {
  position: absolute; inset: 0; pointer-events: none; transition: opacity 1.8s ease;
  background: linear-gradient(180deg, rgba(58,20,38,0.35) 0%, rgba(58,20,38,0) 40%, rgba(58,20,38,0) 70%, rgba(58,20,38,0.6) 100%);
}
.hero.intro-done .hero-video, .hero.intro-done .hero-shade { opacity: 0; }
.hero-invite {
  position: absolute; left: 0; right: 0; top: 16%; padding: 0 var(--gutter);
  display: grid; justify-items: center; text-align: center; gap: 14px; pointer-events: none;
  text-shadow: 0 2px 24px rgba(58,20,38,0.35);
}
/* Invite reveal: greeting and & fade in; Judy slides in from the right, Stephen from the left. */
.hero-dear, .hero-kicker, .couple .amp { opacity: 0; transition: opacity 1.8s ease; }
.couple-judy, .couple-stephen { opacity: 0; transition: opacity 1s ease, transform 2.2s cubic-bezier(.16,.84,.3,1); }
.couple-judy { transform: translateX(100vw); transition-delay: 0.3s; }
.couple-stephen { transform: translateX(-100vw); transition-delay: 0.6s; }
.hero.invite-in .couple .amp { transition-delay: 1.9s; }
.hero.invite-in .hero-dear, .hero.invite-in .hero-kicker, .hero.invite-in .couple > span { opacity: 1; transform: none; }
.hero-dear { font-family: var(--serif); font-style: italic; font-size: 22px; }
.hero-kicker { font-size: 13px; font-weight: 500; letter-spacing: 0.2em; text-transform: uppercase; }
.hero h1 {
  margin: 0; font-family: var(--serif); font-weight: 400;
  font-size: clamp(52px, 11vw, 132px); line-height: 0.95; letter-spacing: -0.01em;
}
.hero h1 em, .honan-b em { font-style: italic; }
.hero h1 .amp { font-style: italic; color: var(--pink); }
/* Names staggered: Judy to the left, & centred, Stephen to the right. */
.couple { display: grid; width: min(100%, 7em); }
.couple > span { display: block; white-space: nowrap; }
.couple-judy { justify-self: start; }
.couple .amp { justify-self: center; }
.couple-stephen { justify-self: end; }
.hero-strip {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 0 var(--gutter) 32px;
  padding-bottom: max(32px, env(safe-area-inset-bottom));
  transition: opacity 1.2s ease 0.6s;
}
.intro-running .hero-strip { opacity: 0; }
.hero-strip-inner {
  max-width: 1120px; margin: 0 auto;
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 16px;
  border-top: 1px solid rgba(251,244,228,0.4); padding-top: 14px;
  font-size: 13px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase;
}
.hero-strip a { color: var(--cream); }
.hero-facts { display: flex; flex-wrap: wrap; gap: 6px 20px; }
.hero-days { color: var(--pink); }

/* 01 The day */
.sched { display: grid; grid-template-columns: 76px 1fr; gap: 16px; padding: 18px 0; border-top: 1px solid var(--hairline); }
.sched-time { font-family: var(--serif); font-size: 28px; line-height: 1.1; color: var(--wine); }
.sched-title { font-weight: 500; font-size: 18px; }
.sched-detail { font-size: 15px; color: var(--plum-muted); margin-top: 2px; }
.day2 { margin-top: 72px; }
.sched-tba { grid-template-columns: 1fr; }

/* 01 The ceremony: interior photo with a see-through wine panel over it */
.ceremony {
  position: relative; min-height: 100vh; min-height: 100svh; overflow: hidden;
  display: grid; align-items: center; background: var(--wine); color: var(--cream);
}
.ceremony-photo { position: absolute; inset: 0; background: var(--wine); }
.ceremony-inner { position: relative; width: 100%; padding: 96px var(--gutter); }
.ceremony-box {
  max-width: 540px; display: grid; gap: 16px; padding: 40px 32px;
  background: rgba(110, 15, 58, 0.8);
  -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px);
  transition: opacity 1.4s ease, transform 1.6s cubic-bezier(.2,.7,.2,1);
}
.js .ceremony:not(.is-in) .ceremony-box { opacity: 0; transform: translateY(32px); }
.ceremony .eyebrow { color: var(--pink); }
.ceremony h2 { color: var(--cream); }
.ceremony-box h2 { margin-bottom: 4px; }
.ceremony-music { font-family: var(--serif); font-style: italic; font-size: 24px; line-height: 1.3; color: var(--pink); }
/* Phones: the photo gets its own space (altar in view) and the panel overlaps only its lower part. */
@media (max-width: 600px) {
  .ceremony { display: block; min-height: 0; }
  .ceremony-photo { position: relative; height: 75vh; height: 75svh; }
  .ceremony-inner { padding: 0 12px 12px; margin-top: -30vh; margin-top: -30svh; }
  .ceremony-box { padding: 28px 22px; }
}

/* 02 Getting there */
.travel { padding: 0 0 96px; }
.honan { position: relative; aspect-ratio: 3 / 2; min-height: 420px; max-height: 88vh; width: 100%; }
.honan .ph { position: absolute; inset: 0; }
/* Cover photos take turns: the current one slides out left as the next slides in from the right. */
.honan-slides img { transform: translateX(100%); transition: transform 1.4s cubic-bezier(.6,0,.2,1); }
.honan-slides img.is-on { transform: none; }
.honan-slides img.is-off { transform: translateX(-100%); }
.honan-slides img.no-anim { transition: none; }
.honan-shade {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(90deg, rgba(58,20,38,0.72) 0%, rgba(58,20,38,0.35) 45%, rgba(58,20,38,0) 75%);
}
.honan-text { position: absolute; left: 0; right: 0; bottom: 0; padding: 0 var(--gutter) 40px; color: var(--cream); pointer-events: none; }
.honan-text-inner { display: grid; gap: 10px; }
.honan-a, .honan-c { font-size: 13px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; }
.honan-a { color: var(--pink); }
.honan-b { font-family: var(--serif); font-size: clamp(56px, 12vw, 140px); line-height: 0.9; letter-spacing: -0.01em; }
.honan-a { transition: opacity 1.2s ease, transform 1.4s cubic-bezier(.2,.7,.2,1); }
.honan-b { transition: opacity 1.4s ease 0.3s, transform 1.8s cubic-bezier(.2,.7,.2,1) 0.3s; }
.honan-c { transition: opacity 1.2s ease 0.8s, transform 1.4s cubic-bezier(.2,.7,.2,1) 0.8s; }
.js .honan:not(.is-in) .honan-a, .js .honan:not(.is-in) .honan-c { opacity: 0; transform: translateX(-60px); }
.js .honan:not(.is-in) .honan-b { opacity: 0; transform: translateX(-120px); }
.travel-body { padding: 80px var(--gutter) 0; }
.route { padding: 72px var(--gutter) 0; }
.route-fig { display: grid; gap: 14px; border-top: 1px solid var(--hairline); padding-top: 18px; }
.route-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; }
.route-frame { position: relative; width: 100%; aspect-ratio: 16 / 9; min-height: 460px; background: var(--paper); overflow: hidden; }
.route-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.route-cap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; font-size: 15px; color: var(--plum-muted); }
.route-cap a { font-weight: 500; }

/* 03 Where to stay */
.green { background: var(--forest); color: var(--cream); }
.green .eyebrow { color: var(--cream); }
.green h2 { color: var(--cream); }
.hotel { display: grid; gap: 2px; padding: 20px 0; border-top: 1px solid rgba(251,244,228,0.25); }
.hotel-name { font-family: var(--serif); font-size: 30px; line-height: 1.15; }
.hotel-dist { font-size: 15px; color: var(--cream); }

/* 05 Wedding party */
.party {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px clamp(16px, 5vw, 72px); max-width: 760px; width: 100%;
}
.party-col { display: grid; gap: 28px; align-content: start; }
.party-side {
  font-size: 12px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--wine); border-bottom: 1px solid var(--hairline); padding-bottom: 10px;
}
.person { display: grid; gap: 10px; transition: opacity 1.2s ease, transform 1.2s ease; }
.js .party:not(.is-in) .person { opacity: 0; transform: translateY(24px); }
.ph-portrait { aspect-ratio: 3 / 4; width: 100%; }
.ph-portrait img { filter: grayscale(1); }
.person figcaption { display: grid; }
.person-name { font-family: var(--serif); font-size: 26px; line-height: 1.1; }
.person-role { font-size: 12px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: var(--plum-muted); }
.flower-girls {
  border-top: 1px solid var(--hairline); padding-top: 18px;
  display: flex; flex-wrap: wrap; gap: 6px 20px; align-items: baseline;
}

/* 06 Meet the team */
.team { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); gap: 40px 20px; }
.vendor { display: grid; gap: 12px; align-content: start; }
.ph-vendor { aspect-ratio: 4 / 5; width: 100%; }
.vendor-body { display: grid; gap: 4px; }
.vendor-name { font-family: var(--serif); font-size: 30px; line-height: 1.1; }
.vendor-body p { margin-top: 2px; font-size: 15px; }
.vendor-body a { justify-self: start; font-size: 14px; font-weight: 500; margin-top: 4px; }

/* 07 Honeymoon */
.gifts {
  position: relative; min-height: 90vh; min-height: 90svh; display: grid; grid-template-columns: minmax(0, 1fr); align-items: end;
  color: var(--cream); overflow: hidden; background: var(--forest);
}
.gifts-photo { position: absolute; inset: 0; background: transparent; }
/* The photo fades in and stays; the text arrives on a translucent panel, like the ceremony. */
.gifts-photo { opacity: 0; transition: opacity 2s ease; }
.gifts[data-state] .gifts-photo { opacity: 1; }
.gifts-text {
  position: relative; width: 100%; padding: 96px var(--gutter) 64px;
  opacity: 0; transform: translateY(24px); transition: opacity 1.8s ease, transform 2.4s ease;
}
.gifts[data-state="text"] .gifts-text { opacity: 1; transform: none; }
.gifts-box {
  max-width: 540px; display: grid; gap: 16px; padding: 40px 32px;
  background: rgba(47, 74, 54, 0.8);
  -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px);
}
.gifts-box h2 { margin-bottom: 4px; }
.gifts .eyebrow { color: var(--cream); }
.gifts h2 { color: var(--cream); }
@media (max-width: 600px) {
  .gifts-text { padding: 96px 12px 12px; }
  .gifts-box { padding: 28px 22px; }
}
.gifts-lead { font-family: var(--serif); font-size: 28px; line-height: 1.25; }
.btn-cream {
  justify-self: start; background: var(--cream); color: var(--plum); text-decoration: none;
  font-size: 13px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; padding: 16px 26px;
}
.btn-cream:hover { color: var(--wine); }

/* 08 Questions */
.faq { display: grid; border-bottom: 1px solid var(--hairline); }
.faq-item { border-top: 1px solid var(--hairline); }
.faq-q {
  all: unset; cursor: pointer; width: 100%; box-sizing: border-box;
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 18px 0; min-height: 52px;
  font-family: var(--serif); font-size: 24px; line-height: 1.2; color: var(--plum);
}
.faq-q:focus-visible { outline: 1px solid var(--wine); outline-offset: 2px; }
.faq-icon { font-family: var(--sans); font-size: 20px; font-weight: 300; color: var(--wine); flex-shrink: 0; }
.faq-a { margin: 0 0 20px; max-width: 520px; }

/* 09 RSVP */
.wine { background: var(--wine); color: var(--cream); }
.rsvp { padding-bottom: 112px; }
.rsvp .split { gap: 40px 72px; }
.rsvp .eyebrow { color: var(--pink); }
.rsvp-title { font-size: clamp(64px, 14vw, 128px); line-height: 0.9; color: var(--cream); }
.form { display: grid; gap: 28px; }
.field { display: grid; gap: 10px; }
label.field { gap: 6px; }
.label { font-size: 12px; color: var(--pink); }
.attending-only { display: grid; gap: 28px; }
.form input, .form textarea {
  font: inherit; font-size: 18px; padding: 10px 0; border: none; border-radius: 0;
  border-bottom: 1px solid rgba(251,244,228,0.5); background: transparent; color: var(--cream);
  outline: none; min-height: 48px; width: 100%;
}
.form textarea { resize: vertical; }
.form input:focus, .form textarea:focus { border-bottom-color: var(--cream); }
.form input::placeholder, .form textarea::placeholder { color: rgba(251,244,228,0.55); }
.people-field { border: 0; margin: 0; padding: 0; min-width: 0; }
.people-field legend { padding: 0; margin-bottom: 10px; }
.people-field p.label { margin: 0 0 10px; }
.event-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; }
.event-name { font-family: var(--serif); font-size: 32px; line-height: 1.15; }
.event-date { font-size: 13px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--pink); }
.people-list { display: grid; border-bottom: 1px solid rgba(251,244,228,0.35); }
.person-reply { display: grid; gap: 4px; padding: 6px 0 10px; border-top: 1px solid rgba(251,244,228,0.35); }
.tick { display: flex; align-items: center; gap: 16px; min-height: 52px; cursor: pointer; }
.tick input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.tick-box {
  flex-shrink: 0; width: 28px; height: 28px; border: 1px solid var(--cream);
  display: grid; place-items: center; transition: background 0.2s ease;
}
.tick-box::after { content: ''; width: 8px; height: 14px; border: solid var(--wine); border-width: 0 2px 2px 0; transform: translateY(-2px) rotate(45deg); opacity: 0; }
.tick input:checked + .tick-box { background: var(--cream); }
.tick input:checked + .tick-box::after { opacity: 1; }
.tick input:focus-visible + .tick-box { outline: 2px solid var(--pink); outline-offset: 2px; }
.tick-name { font-family: var(--serif); font-size: 28px; line-height: 1.15; }
.form .diet { margin-left: 44px; width: calc(100% - 44px); font-size: 16px; }
.rsvp-gate { display: grid; gap: 12px; border-top: 1px solid rgba(251,244,228,0.35); padding-top: 22px; max-width: 520px; }
.rsvp-gate-title { font-family: var(--serif); font-size: 32px; line-height: 1.15; }
.rsvp-gate a { color: var(--cream); }
.replying { display: grid; gap: 2px; border-top: 1px solid rgba(251,244,228,0.35); padding-top: 18px; }
.replying-name { font-family: var(--serif); font-size: 32px; line-height: 1.15; }
.form-error { color: var(--pink); font-weight: 500; font-size: 15px; }
.btn-submit {
  font: inherit; font-size: 13px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase;
  cursor: pointer; min-height: 56px; border: none; background: var(--cream); color: var(--wine);
}
.btn-submit:disabled { opacity: 0.6; cursor: wait; }
.btn-submit:focus-visible, .text-btn:focus-visible {
  outline: 2px solid var(--pink); outline-offset: 2px;
}
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.thanks { display: grid; gap: 12px; border-top: 1px solid rgba(251,244,228,0.35); padding-top: 22px; }
.thanks-title { font-family: var(--serif); font-size: 40px; line-height: 1.1; }
.contact-field { gap: 8px; }
.contact-hint { font-size: 15px; color: rgba(251,244,228,0.75); }
.form input.invalid { border-bottom: 2px solid var(--pink); }
.field-error { margin: -2px 0 4px; font-size: 14px; font-weight: 500; color: var(--pink); }
.suggest-btn {
  all: unset; cursor: pointer; color: var(--cream);
  text-decoration: underline; text-underline-offset: 3px;
}
.suggest-btn:focus-visible { outline: 2px solid var(--pink); outline-offset: 2px; }
.cal { display: grid; gap: 10px; margin-top: 6px; }
.cal-btns { display: flex; flex-wrap: wrap; gap: 12px; }
.cal-btn {
  display: inline-flex; align-items: center; min-height: 48px; padding: 0 20px;
  border: 1px solid var(--cream); color: var(--cream); text-decoration: none;
  font-size: 13px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase;
}
.cal-btn:hover { background: var(--cream); color: var(--wine); }
.cal-btn:focus-visible { outline: 2px solid var(--pink); outline-offset: 2px; }
.text-btn {
  all: unset; cursor: pointer; justify-self: start; padding: 10px 0;
  font-size: 13px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase;
  text-decoration: underline; text-underline-offset: 4px;
}

/* Thank-you screen: video plays once, the words print from an invisible line,
   then a plum gradient rises with the calendar buttons on it. */
.ty {
  position: fixed; inset: 0; z-index: 50; overflow: hidden; outline: none;
  background: var(--plum); color: var(--cream); opacity: 0; transition: opacity 0.6s ease;
}
.ty.is-open { opacity: 1; }
/* The video file is 406×720 with black bars; the picture is the 334×444 at (36,138).
   .ty-frame is that picture's shape, filling a phone screen or centred on a wide one;
   the video is oversized inside it so the bars fall outside. */
.ty-frame {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); overflow: hidden;
  width: min(100vw, 100svh * 334 / 444); height: min(100svh, 100vw * 444 / 334);
}
@media (max-aspect-ratio: 4/5) {
  .ty-frame { width: max(100vw, 100svh * 334 / 444); height: max(100svh, 100vw * 444 / 334); }
}
.ty-video {
  position: absolute; max-width: none; object-fit: fill;
  width: calc(100% * 406 / 334); height: calc(100% * 720 / 444);
  left: calc(-100% * 36 / 334); top: calc(-100% * 138 / 444);
}
.ty-shade {
  position: absolute; left: 0; right: 0; bottom: 0; height: 55%; pointer-events: none;
  background: linear-gradient(180deg, rgba(58,20,38,0) 0%, rgba(58,20,38,0.55) 40%, rgba(58,20,38,0.9) 100%);
  opacity: 0; transition: opacity 1.6s ease;
}
.ty.is-ended .ty-shade { opacity: 1; }
/* The print line sits high so the words land on the sky, not on faces. */
.ty-words { position: absolute; left: 0; right: 0; top: 22%; height: 0; text-align: center; }
.ty-up, .ty-down { position: absolute; left: 0; right: 0; overflow: hidden; padding: 0 var(--gutter); }
.ty-up { bottom: 0; }
.ty-down { top: 0; }
.ty-big, .ty-small { text-shadow: 0 2px 24px rgba(58,20,38,0.5); }
.ty-big {
  margin: 0; font-family: var(--serif); font-weight: 400; color: var(--cream);
  font-size: clamp(96px, 24vw, 220px); line-height: 1; transform: translateY(100%);
}
.ty-small {
  margin: 0; padding-top: 8px; font-family: var(--serif); font-style: italic;
  font-size: clamp(28px, 6.5vw, 48px); line-height: 1.2; transform: translateY(-100%);
}
/* Thin line between the two: spreads out from the centre just before Thanks! slides up from it. */
.ty-line {
  position: absolute; left: 50%; top: 0; width: min(70vw, 560px); height: 2px;
  margin-left: calc(min(70vw, 560px) / -2); margin-top: -1px;
  background: var(--wine); transform: scaleX(0);
}
.ty-up { padding-bottom: 6px; }
.ty-down { padding-top: 6px; }
.ty.is-open .ty-line { animation: ty-spread 0.9s cubic-bezier(0.3, 0.7, 0.2, 1) 0.3s forwards; }
.ty.is-open .ty-big { animation: ty-print 1.1s cubic-bezier(0.2, 0.7, 0.2, 1) 0.5s forwards; }
.ty.is-open .ty-small { animation: ty-print 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) 1.4s forwards; }
@keyframes ty-print { to { transform: none; } }
@keyframes ty-spread { to { transform: none; } }
.ty-foot {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 0 var(--gutter) max(40px, env(safe-area-inset-bottom));
  display: grid; gap: 14px; justify-items: center; text-align: center;
  opacity: 0; transform: translateY(12px); pointer-events: none;
  transition: opacity 1s ease 0.9s, transform 1s ease 0.9s;
}
.ty.is-ended .ty-foot { opacity: 1; transform: none; pointer-events: auto; }
.ty-foot .cal { justify-items: center; }
.ty-foot .text-btn { justify-self: center; }
.ty-foot .cal-btns { justify-content: center; }
.ty .label { color: var(--pink); }
@media (prefers-reduced-motion: reduce) {
  .ty-big, .ty-small, .ty-line { transform: none; }
  .ty.is-open .ty-big, .ty.is-open .ty-small, .ty.is-open .ty-line { animation: none; }
}

/* Footer */
.footer { padding: 40px var(--gutter); padding-bottom: max(40px, env(safe-area-inset-bottom)); background: var(--plum); color: var(--cream); }
.footer-inner { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 12px; }
.footer-name { font-family: var(--serif); font-size: 28px; }
.footer-meta { font-size: 13px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--pink); }
.footer-meta a { color: var(--pink); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
