:root {
  --milk: #fffaf3;
  --cream: #f7edde;
  --blush: #ecd1ca;
  --peach: #e7aa92;
  --champagne: #d9bd86;
  --berry: #762f43;
  --berry-dark: #532231;
  --ink: #3c2b27;
  --muted: #75645f;
  --line: rgba(91, 56, 48, 0.16);
  --paper: #fffdf8;
  --shadow: 0 22px 70px rgba(81, 45, 38, 0.13);
  --serif: Georgia, "Times New Roman", serif;
  --sans: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { margin: 0; min-width: 0; overflow-x: hidden; color: var(--ink); background: var(--milk); font-family: var(--sans); line-height: 1.65; }
body.dialog-open { overflow: hidden; }
.js.intro-locked { height: 100%; overflow: hidden; overscroll-behavior: none; }
.js.intro-locked body { position: fixed; inset: 0; width: 100%; height: 100%; overflow: hidden; overscroll-behavior: none; touch-action: none; }
.js.intro-locked .story, .js.intro-locked .footer { visibility: hidden; }
.js.intro-locked .hero__scroll { display: none; }
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { color: inherit; }
img, video { display: block; max-width: 100%; }
a { color: inherit; }

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; z-index: 1000; top: 10px; left: 10px; padding: .7rem 1rem; transform: translateY(-150%); background: var(--paper); border-radius: 999px; }
.skip-link:focus { transform: none; }
:focus-visible { outline: 3px solid var(--berry); outline-offset: 4px; }

.eyebrow { margin: 0 0 .7rem; color: var(--berry); font-size: clamp(.7rem, 1.1vw, .82rem); font-weight: 700; letter-spacing: .18em; line-height: 1.3; text-transform: uppercase; }
h1, h2, h3, p { overflow-wrap: anywhere; }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; line-height: .98; }
h1 { max-width: 780px; margin: 0 auto; font-size: clamp(2.5rem, 7.2vw, 6.9rem); letter-spacing: -.055em; }
h2 { margin: 0; font-size: clamp(2.25rem, 5vw, 5rem); letter-spacing: -.045em; }
h3 { margin: 0; font-size: clamp(1.35rem, 2.2vw, 2rem); }

.hero { position: relative; min-height: 100vh; min-height: 100svh; padding: max(1.5rem, env(safe-area-inset-top)) max(1.25rem, env(safe-area-inset-right)) max(1.2rem, env(safe-area-inset-bottom)) max(1.25rem, env(safe-area-inset-left)); display: grid; place-items: center; overflow: hidden; isolation: isolate; background: radial-gradient(circle at 50% 15%, #fffdf8 0, #f8eee2 48%, #ead5c8 100%); }
.hero::before { content: ""; position: absolute; z-index: -1; inset: 18px; border: 1px solid rgba(107, 64, 54, .18); border-radius: min(4vw, 40px); pointer-events: none; }
.hero__content { width: min(100%, 1050px); text-align: center; display: flex; flex-direction: column; align-items: center; }
.hero__thought { max-width: 570px; margin: 1rem auto 0; color: var(--muted); font-family: var(--serif); font-size: clamp(1.02rem, 1.8vw, 1.32rem); font-style: italic; }
.hero__supporting { max-width: 540px; margin: .75rem auto 0; color: var(--muted); font-size: clamp(.86rem, 1.3vw, 1rem); }
.hero__date { margin: .7rem 0 -.2rem; color: var(--berry); font-size: .84rem; font-weight: 700; letter-spacing: .15em; text-transform: uppercase; }
.hero__glow { position: absolute; z-index: -2; border-radius: 50%; filter: blur(2px); opacity: .6; }
.hero__glow--one { width: min(35vw, 430px); aspect-ratio: 1; left: -8%; top: 7%; background: rgba(223, 171, 155, .25); }
.hero__glow--two { width: min(42vw, 530px); aspect-ratio: 1; right: -14%; bottom: -13%; background: rgba(209, 180, 120, .22); }

.keepsake { position: relative; width: min(clamp(245px, 35vh, 340px), calc(100vw - 4rem)); aspect-ratio: 4 / 3; margin: clamp(.75rem, 1.8vh, 1.35rem) auto clamp(.8rem, 1.8vh, 1.35rem); perspective: 800px; }
.keepsake__envelope { position: absolute; inset: 8% 0 0; isolation: isolate; }
.keepsake__back { position: absolute; z-index: 0; inset: 17% 3% 4%; border: 1px solid rgba(117, 61, 58, .14); border-radius: 3px 18px 3px 18px; background: #f6e5d7; box-shadow: 0 18px 42px rgba(78, 45, 37, .17); }
.keepsake__photo { position: absolute; z-index: 1; top: 0; left: 8%; width: 84%; aspect-ratio: 4 / 3; overflow: hidden; border: 8px solid var(--paper); border-radius: 3px; background: #eadbcf; box-shadow: 0 12px 32px rgba(78, 45, 37, .2); transform: translateY(29%) rotate(-.7deg) scale(.91); transform-origin: center bottom; opacity: 0; transition: transform .62s cubic-bezier(.2,.85,.25,1), opacity .42s ease, box-shadow .62s ease; }
.keepsake__photo > img { width: 100%; height: 100%; object-fit: var(--photo-fit, cover); object-position: var(--photo-position, 50% 50%); background: #eadbcf; }
.keepsake__flap { position: absolute; z-index: 2; inset: 17% 3% auto; height: 43%; clip-path: polygon(0 0, 100% 0, 50% 83%); border-radius: 3px 18px 0 0; background: linear-gradient(160deg, #f1d7c7, #e5c1b2); transform-origin: center top; transition: transform .52s cubic-bezier(.25,.75,.25,1), opacity .35s ease; }
.keepsake__pocket { position: absolute; z-index: 3; inset: 32% 3% 4%; clip-path: polygon(0 0, 50% 46%, 100% 0, 100% 100%, 0 100%); border-radius: 0 0 3px 18px; background: linear-gradient(145deg, #f4dfd1, #e7c6b8); box-shadow: inset 0 0 0 1px rgba(117,61,58,.08); transition: opacity .45s ease, transform .58s ease; }
.keepsake__seal { position: absolute; z-index: 4; left: 50%; top: 55%; width: 34px; aspect-ratio: 1; display: grid; place-items: center; transform: translate(-50%,-50%); border-radius: 50%; color: #f7e9d7; background: var(--berry); box-shadow: 0 5px 14px rgba(83,34,49,.2); font: .9rem/1 var(--serif); transition: opacity .25s ease, transform .45s ease; }
.is-open .keepsake__photo { z-index: 5; transform: translateY(-10%) rotate(.45deg) scale(1); opacity: 1; box-shadow: 0 20px 48px rgba(78,45,37,.24); }
.is-open .keepsake__flap { transform: translateY(-7%) scaleY(.22); opacity: .35; }
.is-open .keepsake__pocket { transform: translateY(3%); opacity: .42; }
.is-open .keepsake__seal { transform: translate(-50%,-30%) scale(.82); opacity: 0; }

.button { min-height: 50px; padding: .8rem 1.3rem; display: inline-flex; align-items: center; justify-content: center; gap: .8rem; border: 0; border-radius: 999px; cursor: pointer; font-weight: 700; transition: transform .2s ease, box-shadow .2s ease, background .2s ease; }
.button:hover { transform: translateY(-2px); }
.button--primary { min-width: min(100%, 250px); color: #fff9f4; background: var(--berry); box-shadow: 0 12px 27px rgba(106, 39, 58, .25); }
.button--primary:hover { background: var(--berry-dark); box-shadow: 0 16px 34px rgba(106, 39, 58, .3); }
.button--light { color: var(--berry-dark); background: #fff8ec; box-shadow: 0 12px 28px rgba(45, 17, 24, .2); }
.hero__hint { margin: .6rem 0 0; color: var(--muted); font-size: .75rem; }
.hero__scroll { position: absolute; bottom: max(.85rem, env(safe-area-inset-bottom)); left: 50%; width: 1px; height: 28px; background: rgba(94, 58, 50, .22); }
.hero__scroll span { position: absolute; top: 0; left: -2px; width: 5px; height: 5px; border-radius: 50%; background: var(--berry); animation: scrollDot 2.2s ease-in-out infinite; }
@keyframes scrollDot { 0%,100% { transform: translateY(0); opacity: .4; } 50% { transform: translateY(23px); opacity: 1; } }

.story { position: relative; }
.section { position: relative; padding: clamp(5rem, 10vw, 9rem) max(1.25rem, env(safe-area-inset-right)) clamp(5rem, 10vw, 9rem) max(1.25rem, env(safe-area-inset-left)); overflow: hidden; }
.section__number { position: absolute; top: 2rem; right: max(1.25rem, calc((100vw - 1160px) / 2)); color: rgba(93, 48, 57, .18); font: 400 clamp(3rem, 8vw, 8rem)/1 var(--serif); }
.section-heading { width: min(100%, 1160px); margin: 0 auto clamp(2.5rem, 6vw, 5rem); }
.section-heading > p:last-child { max-width: 570px; margin: 1.2rem 0 0; color: var(--muted); }
.section-heading--split { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(260px, .6fr); gap: 2rem; align-items: end; }
.section-heading--split > p:last-child { margin: 0 0 .35rem; }

.section--letter { background: var(--cream); }
.letter-wrap { position: relative; width: min(100%, 900px); margin: 0 auto; padding-top: clamp(1.5rem, 7vw, 5rem); }
.letter-paper { position: relative; z-index: 2; padding: clamp(2rem, 5vw, 4.5rem); border: 1px solid rgba(110, 77, 62, .13); background: linear-gradient(135deg, rgba(255,255,255,.8), transparent 35%), var(--paper); box-shadow: var(--shadow); transform: rotate(-.35deg); }
.letter-paper::before { content: ""; position: absolute; top: 28px; left: 28px; width: 42px; height: 42px; border-top: 1px solid var(--champagne); border-left: 1px solid var(--champagne); }
.letter-paper h2 { margin-bottom: 1.5rem; font-style: italic; }
.letter-paper__text { margin: 0; color: #53423d; font-family: var(--serif); font-size: clamp(1.05rem, 2vw, 1.32rem); line-height: 1.72; }
.letter-paper__text p { margin: 0; }
.letter-paper__text p + p { margin-top: 1.15rem; }
.letter-photo { width: min(100%, 560px); margin: 1.8rem auto .2rem; padding: 9px; border: 1px solid rgba(110, 77, 62, .12); background: #fffaf1; box-shadow: 0 14px 35px rgba(78,45,37,.12); transform: rotate(.35deg); }
.letter-photo[hidden] { display: none; }.letter-photo img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: var(--photo-position, 50% 50%); background: #eee3d8; }.letter-photo figcaption { margin-top: .75rem; color: #7a625a; font: italic .92rem/1.4 var(--serif); text-align: center; }
.signature { margin: 1.65rem 0 0; color: var(--berry); font: italic clamp(1.25rem, 2vw, 1.65rem)/1.4 var(--serif); text-align: right; }
.envelope { position: absolute; z-index: 3; top: 0; right: -7%; width: clamp(130px, 22vw, 230px); aspect-ratio: 1.5; transform: rotate(7deg); background: #d9aa9b; box-shadow: 0 18px 38px rgba(75, 42, 36, .18); transition: transform .9s cubic-bezier(.2,.9,.2,1), opacity .5s ease; }
.envelope::after { content: ""; position: absolute; inset: 0; clip-path: polygon(0 100%, 0 35%, 50% 70%, 100% 35%, 100% 100%); background: #e7c1b3; }
.envelope__flap { position: absolute; z-index: 2; inset: 0; clip-path: polygon(0 0, 100% 0, 50% 64%); background: #c98e81; transform-origin: top; transition: transform .8s ease; }
.envelope__seal { position: absolute; z-index: 4; left: 50%; top: 50%; width: 42px; aspect-ratio: 1; display: grid; place-items: center; transform: translate(-50%,-25%); border-radius: 50%; color: #f8e6d2; background: var(--berry); font: 1.1rem var(--serif); }
.is-open .envelope { transform: translate(45%, -42%) rotate(15deg); opacity: .28; }
.is-open .envelope__flap { transform: rotateX(150deg); }

.section--memories { background: #fdf9f2; }
.timeline { position: relative; width: min(100%, 1120px); margin: auto; display: grid; gap: clamp(1.2rem, 3vw, 2.4rem); }
.timeline::before { content: ""; position: absolute; top: 1rem; bottom: 1rem; left: 25px; width: 1px; background: linear-gradient(transparent, var(--champagne) 8%, var(--champagne) 92%, transparent); }
.memory-card { position: relative; width: 100%; min-height: 0; padding: clamp(1.3rem, 3vw, 2.25rem); display: grid; grid-template-columns: 50px minmax(230px, .72fr) minmax(0, 1.35fr); gap: clamp(1rem, 2.4vw, 2rem); align-items: center; border: 1px solid var(--line); border-radius: 4px 40px 4px 40px; background: rgba(255,255,255,.76); box-shadow: 0 14px 45px rgba(78,48,38,.07); }
.memory-card:nth-child(even) { grid-template-columns: 50px minmax(0, 1.35fr) minmax(230px, .72fr); border-radius: 40px 4px 40px 4px; }
.memory-card:nth-child(even) .memory-card__copy { grid-column: 3; }
.memory-card:nth-child(even) .memory-card__photos { grid-column: 2; grid-row: 1; }
.memory-card__index { position: relative; z-index: 1; align-self: start; padding-top: .15rem; color: var(--champagne); background: rgba(255,255,255,.76); font: 400 1.7rem/1 var(--serif); }
.memory-card__date { margin: 0 0 .5rem; color: var(--berry); font-size: .72rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.memory-card p:last-child, .memory-card__text { margin: .8rem 0 0; color: var(--muted); font-size: .94rem; }
.memory-card__copy { min-width: 0; }
.memory-card__photos { min-width: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; align-items: stretch; }
.memory-photo { position: relative; min-width: 0; min-height: 0; overflow: hidden; padding: 0; border: 0; border-radius: 2px 16px 2px 16px; background: #eee3d8; box-shadow: 0 8px 24px rgba(73,43,36,.08); cursor: pointer; }
.memory-photo--landscape { aspect-ratio: 16 / 10; }
.memory-photo--portrait { aspect-ratio: 4 / 5; }
.memory-card__photos--landscape-first .memory-photo:first-child { grid-column: 1 / -1; aspect-ratio: 16 / 8.2; }
.memory-card__photos--all-portrait { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.memory-card__photos--portrait-first { grid-template-columns: 1.05fr .95fr; grid-template-rows: repeat(2, minmax(0, 1fr)); }
.memory-card__photos--portrait-first .memory-photo:first-child { grid-row: 1 / 3; }
.memory-card__photos--portrait-first .memory-photo--landscape { aspect-ratio: auto; }
.memory-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: var(--photo-position, 50% 50%); transition: transform .2s ease, filter .2s ease; }
@media (hover: hover) and (pointer: fine) {
  .memory-photo:hover img { transform: scale(1.015); filter: saturate(1.02); }
}

.section--gallery { background: #ead7ce; }
.photo-grid { width: min(100%, 1160px); margin: auto; display: grid; grid-template-columns: repeat(12, 1fr); grid-auto-flow: dense; grid-auto-rows: 112px; gap: clamp(.8rem, 2vw, 1.4rem); }
.photo-card { position: relative; grid-column: span 4; grid-row: span 3; min-width: 0; min-height: 0; overflow: hidden; padding: 0; border: 0; border-radius: 3px 30px 3px 30px; background: var(--paper); box-shadow: 0 15px 45px rgba(73,43,36,.11); cursor: pointer; }
.photo-card--wide { grid-column: span 8; grid-row: span 3; }
.photo-card--portrait { grid-row: span 4; }
.photo-card--tall { grid-row: span 5; }
.photo-card--compact { grid-column: span 4; grid-row: span 2; }
.photo-card--mini { grid-column: span 3; grid-row: span 3; }
.photo-card img { width: 100%; height: 100%; object-fit: cover; object-position: var(--photo-position, 50% 50%); background: #eee3d8; transition: transform .55s ease; }
.photo-card--contain img { object-fit: contain; }
.photo-card:hover img { transform: scale(1.025); }
.photo-card__caption { position: absolute; inset: auto 0 0; padding: 2.5rem 1.2rem 1.1rem; color: #fff; text-align: left; background: linear-gradient(transparent, rgba(48,27,25,.78)); }
.photo-card__caption strong { display: block; font-family: var(--serif); font-size: 1.14rem; }
.photo-card__caption small { opacity: .8; }
.placeholder-photo { display: grid; place-items: center; isolation: isolate; background: linear-gradient(145deg, #edd7c9, #f8eadb 47%, #d8b09e); cursor: default; }
.placeholder-photo::before, .placeholder-photo::after { content: ""; position: absolute; z-index: -1; border-radius: 50%; opacity: .65; }
.placeholder-photo::before { width: 55%; aspect-ratio: 1; top: -18%; right: -14%; border: 1px solid rgba(119,68,60,.25); }
.placeholder-photo::after { width: 45%; aspect-ratio: 1; bottom: -20%; left: -10%; background: rgba(117,55,70,.12); }
.placeholder-photo span { padding: 1rem; color: rgba(82,54,47,.62); font: italic 1.05rem var(--serif); text-align: center; }

.section--videos { color: #f9efe6; background: #3f2c2c; }
.section--videos .eyebrow { color: #e2b68f; }
.section--videos .section__number { color: rgba(255,255,255,.09); }
.video-grid { width: min(100%, 1060px); margin: auto; display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 1.4rem; }
.video-card { position: relative; min-height: 320px; overflow: hidden; padding: 0; border: 1px solid rgba(255,255,255,.14); border-radius: 4px 34px 4px 34px; background: #2c2020; cursor: pointer; text-align: left; }
.video-card img { width: 100%; height: 100%; object-fit: cover; opacity: .76; }
.video-card > .placeholder-photo { position: absolute; inset: 0; }
.video-card__overlay { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: flex-start; justify-content: flex-end; padding: 1.5rem; background: linear-gradient(transparent 30%, rgba(29,15,17,.87)); }
.video-card__play, .video-empty__play { width: 52px; aspect-ratio: 1; margin-bottom: 1rem; display: grid; place-items: center; border-radius: 50%; color: var(--berry); background: #fff6e9; }
.video-card h3 { margin-bottom: .35rem; }.video-card p { margin: 0; color: rgba(255,255,255,.75); font-size: .9rem; }
.video-empty { grid-column: 1/-1; min-height: 250px; padding: clamp(2rem, 6vw, 4rem); display: flex; align-items: center; justify-content: center; gap: 1.5rem; border: 1px dashed rgba(255,255,255,.22); border-radius: 4px 44px 4px 44px; background: rgba(255,255,255,.035); }
.video-empty__play { flex: 0 0 auto; margin: 0; }.video-empty p { margin: .5rem 0 0; color: rgba(255,255,255,.65); }

.section--reasons { background: #fbf5ed; }
.reasons-grid { width: min(100%, 1040px); margin: auto; display: grid; grid-template-columns: repeat(6, minmax(0,1fr)); gap: clamp(.8rem, 2vw, 1.25rem); align-items: start; }
.thank-note { position: relative; grid-column: span 2; min-height: 150px; padding: clamp(1.25rem, 2.5vw, 2rem); display: grid; place-items: center; border: 1px solid var(--line); border-radius: 3px 24px 3px 24px; background: rgba(255,255,255,.72); box-shadow: 0 12px 30px rgba(73,43,36,.07); transform: rotate(-.45deg); }
.thank-note:nth-child(even) { transform: translateY(16px) rotate(.55deg); }
.thank-note:nth-child(4) { grid-column: 2 / span 2; }
.thank-note p { margin: 0; font: 1.12rem/1.55 var(--serif); text-align: center; }
.thank-note--accent { grid-column: span 2; color: var(--berry-dark); border-color: rgba(118,47,67,.58); background: linear-gradient(145deg, #fff9f3, #f3dfe0); }

.section--final { min-height: 100vh; min-height: 100svh; display: grid; place-items: center; background: radial-gradient(circle at 50% 20%, #9b4e61 0, var(--berry) 42%, #45202a 100%); }
.final-card { width: min(100%, 860px); padding: clamp(1.8rem, 6vw, 4.5rem); color: #fff8ef; text-align: center; border: 1px solid rgba(255,255,255,.18); border-radius: 4px 60px 4px 60px; background: rgba(63,24,35,.23); box-shadow: 0 28px 90px rgba(37,11,18,.28); backdrop-filter: blur(10px); }
.final-card .eyebrow { color: #e8c89e; }
.final-card h2 { max-width: 650px; margin-inline: auto; }
.final-card__closed { margin-top: 1.7rem; }
.final-card__closed .button { margin-top: 1.8rem; }
.gift { position: relative; width: 132px; height: 120px; margin: 0 auto 2rem; transition: transform .6s ease; }
.gift__box { position: absolute; inset: 37px 6px 0; border-radius: 4px; background: #f1d2ae; box-shadow: inset 0 0 0 1px rgba(79,36,43,.12); }
.gift__lid { position: absolute; z-index: 2; top: 28px; left: 0; right: 0; height: 28px; border-radius: 3px; background: #fff0d8; transition: transform .8s cubic-bezier(.2,.9,.2,1); }
.gift__lid i { position: absolute; bottom: 19px; width: 48px; height: 32px; border: 7px solid #d3907d; }.gift__lid i:first-child { left: 19px; border-radius: 100% 10% 10% 10%; transform: rotate(17deg); }.gift__lid i:last-child { right: 19px; border-radius: 10% 100% 10% 10%; transform: rotate(-17deg); }
.gift__ribbon { position: absolute; z-index: 3; top: 28px; bottom: 0; left: 50%; width: 21px; transform: translateX(-50%); background: #d3907d; }
.final-card.is-revealed .gift__lid { transform: translate(20px,-48px) rotate(13deg); }.final-card.is-revealed .gift { height: 54px; margin-bottom: .8rem; transform: translateY(5px) scale(.68); }
.final-card__opened { display: none; }.final-card.is-revealed .final-card__closed { display: none; }.final-card.is-revealed .final-card__opened { display: block; animation: fadeUp .7s both; }
.gift-intro { max-width: 650px; margin: 0 auto 1.8rem; color: #fff8ef; font: clamp(1.12rem, 2vw, 1.4rem)/1.6 var(--serif); white-space: pre-line; }
.gift-visual { position: relative; width: min(100%, 620px); aspect-ratio: 4 / 5; margin: 0 auto; overflow: hidden; border: 10px solid #fff9ee; border-radius: 4px; background: #eadfd5; box-shadow: 0 22px 62px rgba(34,9,16,.34); }
.gift-visual::after { content: ""; position: absolute; inset: 0; z-index: 3; pointer-events: none; opacity: 0; background: repeating-linear-gradient(12deg, rgba(255,255,255,.1) 0 1px, rgba(84,45,30,.06) 1px 3px); mix-blend-mode: soft-light; transition: opacity .72s ease; }
.gift-visual__image { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #eadfd5; transition: opacity .72s ease, filter .72s ease; }
.gift-visual__image--photo { z-index: 1; opacity: 1; }
.gift-visual__image--painting { z-index: 2; opacity: 0; filter: saturate(.92) brightness(.96); }
.final-card.is-painted .gift-visual__image--photo { opacity: 0; filter: brightness(.86); }
.final-card.is-painted .gift-visual__image--painting { opacity: 1; filter: none; }
.final-card.is-transforming .gift-visual::after, .final-card.is-painted .gift-visual::after { opacity: .2; }
.gift-visual--missing { min-height: 320px; }
.gift-media-error { width: min(100%, 620px); margin: 1rem auto 0; color: #ffe5d0; }
.gift-action { margin-top: 1.65rem; }
.gift-action .button { max-width: 100%; white-space: normal; }
.gift-finale { margin-top: 2.4rem; animation: fadeUp .65s both; }
.gift-finale h2 { font-size: clamp(2.35rem, 5.2vw, 4.6rem); line-height: 1.02; }
.gift-final-love { margin: 1.25rem 0 .15rem; font: clamp(1.18rem, 2.2vw, 1.5rem)/1.5 var(--serif); }
.gift-finale .signature { margin-bottom: 1.65rem; }
.hug-message { margin: 1.5rem auto 0; color: #fff3df; font: clamp(1.2rem, 2.2vw, 1.55rem)/1.5 var(--serif); }
.gift-replay { display: block; margin-inline: auto; }
.gift-replay[hidden] { display: none; }
.signature--light { margin-top: .2rem; color: #efd2ac; text-align: center; }
.text-button { margin-top: 1.5rem; padding: .45rem .1rem; border: 0; border-bottom: 1px solid currentColor; color: #f8dec2; background: transparent; cursor: pointer; }
.confetti-piece { position: fixed; z-index: 999; top: -20px; width: 8px; height: 14px; border-radius: 2px; pointer-events: none; animation: confettiFall var(--duration) cubic-bezier(.15,.7,.35,1) forwards; }
@keyframes confettiFall { to { transform: translate3d(var(--drift), 108vh, 0) rotate(var(--spin)); opacity: .1; } }

.footer { padding: 2.2rem max(1.25rem, env(safe-area-inset-right)) max(2.2rem, env(safe-area-inset-bottom)) max(1.25rem, env(safe-area-inset-left)); display: flex; justify-content: space-between; gap: 1rem; color: #88716b; background: #2e2121; font-size: .78rem; }
.footer p { margin: 0; }.footer a { text-decoration: none; }

.music-control { position: fixed; z-index: 80; right: max(1rem, env(safe-area-inset-right)); bottom: max(1rem, env(safe-area-inset-bottom)); padding: .55rem; display: flex; align-items: center; gap: .6rem; border: 1px solid rgba(100,58,50,.12); border-radius: 999px; background: rgba(255,250,243,.92); box-shadow: 0 10px 35px rgba(54,30,27,.15); backdrop-filter: blur(10px); }
.music-control[hidden] { display: none; }.music-control button { min-height: 42px; padding: .5rem .8rem; display: flex; gap: .45rem; align-items: center; border: 0; border-radius: 999px; color: var(--berry); background: transparent; cursor: pointer; }.music-control input { width: 78px; accent-color: var(--berry); }

.media-dialog { width: min(94vw, 1050px); max-width: none; max-height: 92vh; padding: 0; overflow: visible; border: 0; color: #fff; background: transparent; }
.media-dialog::backdrop { background: rgba(28,17,16,.91); backdrop-filter: blur(9px); }
.media-dialog figure { margin: 0; display: grid; place-items: center; }
.dialog-image-wrap { max-width: 100%; max-height: 75vh; display: grid; place-items: center; touch-action: pan-y; }
.dialog-image-wrap img { max-height: 75vh; object-fit: contain; box-shadow: 0 18px 70px rgba(0,0,0,.35); }
.media-dialog figcaption { width: min(100%, 760px); margin-top: 1rem; display: flex; justify-content: space-between; gap: 1rem; color: rgba(255,255,255,.85); }.media-dialog figcaption span:last-child { white-space: nowrap; color: rgba(255,255,255,.58); }
.dialog-close, .dialog-nav { position: fixed; z-index: 2; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.28); border-radius: 50%; color: #fff; background: rgba(255,255,255,.08); cursor: pointer; }
.dialog-close { top: max(1rem, env(safe-area-inset-top)); right: max(1rem, env(safe-area-inset-right)); width: 48px; height: 48px; font-size: 2rem; }.dialog-nav { top: 50%; width: 52px; height: 52px; transform: translateY(-50%); font-size: 2.2rem; }.dialog-nav--prev { left: max(1rem, env(safe-area-inset-left)); }.dialog-nav--next { right: max(1rem, env(safe-area-inset-right)); }
.dialog-video-wrap { max-height: 72vh; display: grid; place-items: center; }.dialog-video-wrap video { max-width: 100%; max-height: 72vh; background: #000; }.video-dialog-copy { padding-top: 1rem; }.video-dialog-copy h3 { font-size: 1.5rem; }.video-dialog-copy p { margin: .4rem 0 0; color: rgba(255,255,255,.68); }
.noscript-note { position: fixed; z-index: 100; right: 1rem; bottom: 1rem; max-width: 360px; padding: .8rem 1rem; border-radius: 8px; color: white; background: var(--berry); }

.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.js .reveal.is-visible { opacity: 1; transform: none; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
.petal { position: fixed; z-index: 120; top: 38%; left: 50%; width: 10px; height: 16px; border-radius: 100% 0 100% 0; background: var(--petal); pointer-events: none; animation: petalFly var(--duration) ease-out forwards; }
@keyframes petalFly { to { opacity: 0; transform: translate(var(--x), var(--y)) rotate(var(--rotate)); } }

@media (max-width: 900px) {
  .section-heading--split { grid-template-columns: 1fr; }.section-heading--split > p:last-child { margin: 0; }
  .memory-card, .memory-card:nth-child(even) { grid-template-columns: 42px minmax(0, 1fr); }
  .memory-card .memory-card__copy, .memory-card:nth-child(even) .memory-card__copy { grid-column: 2; grid-row: 1; }
  .memory-card .memory-card__photos, .memory-card:nth-child(even) .memory-card__photos { grid-column: 1 / -1; grid-row: 2; }
  .photo-card { grid-column: span 6; }.photo-card--wide { grid-column: span 12; }.photo-card--compact, .photo-card--mini { grid-column: span 4; }
  .reasons-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }.thank-note, .thank-note:nth-child(4), .thank-note--accent { grid-column: span 1; }.thank-note:last-child { grid-column: 1 / -1; }
}
@media (max-width: 680px) {
  .hero::before { inset: 10px; border-radius: 22px; }
  .hero__scroll { display: none; }
  .section { padding-top: 5.3rem; padding-bottom: 5.3rem; }
  .section__number { top: 1.5rem; }
  .envelope { right: -2%; width: 138px; }.letter-wrap { padding-top: 3.8rem; }.letter-paper { padding: 2.2rem 1.4rem 2.4rem; }.letter-paper::before { top: 16px; left: 16px; width: 24px; height: 24px; }
  .timeline::before { left: 20px; }.memory-card, .memory-card:nth-child(even) { width: 100%; padding: 1.2rem; grid-template-columns: 34px minmax(0, 1fr); border-radius: 3px 28px 3px 28px; }.memory-card__index { font-size: 1.35rem; }.memory-card__photos, .memory-card__photos--portrait-first { grid-template-columns: repeat(2, minmax(0,1fr)); grid-template-rows: auto; }.memory-card__photos--landscape-first .memory-photo:first-child, .memory-card__photos--all-portrait .memory-photo:first-child, .memory-card__photos--portrait-first .memory-photo:first-child { grid-column: 1 / -1; grid-row: auto; }.memory-card__photos--all-portrait { grid-template-columns: repeat(2, minmax(0,1fr)); }.memory-card__photos--all-portrait .memory-photo:first-child { width: min(100%, 270px); justify-self: center; }.memory-card__photos--portrait-first .memory-photo--landscape { aspect-ratio: 16 / 10; }
  .photo-grid { grid-template-columns: repeat(2, minmax(0,1fr)); grid-auto-rows: 105px; }.photo-card { grid-column: span 1; grid-row: span 2; }.photo-card--wide { grid-column: span 2; grid-row: span 3; }.photo-card--portrait { grid-column: span 1; grid-row: span 3; }.photo-card--tall { grid-column: span 1; grid-row: span 4; }.photo-card--compact, .photo-card--mini { grid-column: span 1; grid-row: span 2; }
  .video-grid { grid-template-columns: 1fr; }.video-empty { flex-direction: column; text-align: center; }
  .reasons-grid { grid-template-columns: 1fr; }.thank-note, .thank-note:nth-child(4), .thank-note--accent, .thank-note:last-child { grid-column: 1; min-height: 120px; transform: none; }.thank-note:nth-child(even) { transform: none; }
  .footer { flex-direction: column; }.footer p { margin: 0; }
  .music-control label { display: none; }
  .dialog-nav { top: auto; bottom: max(1.2rem, env(safe-area-inset-bottom)); }.dialog-nav--prev { left: 28%; }.dialog-nav--next { right: 28%; }.media-dialog figcaption { padding-bottom: 5rem; flex-direction: column; gap: .2rem; }
  .keepsake__photo > img, .letter-photo img, .memory-card__photos img, .photo-card img { object-position: var(--photo-position-mobile, var(--photo-position, 50% 50%)); }
  .section--final { padding-inline: max(.65rem, env(safe-area-inset-left)) max(.65rem, env(safe-area-inset-right)); }
  .final-card { padding-inline: .85rem; border-radius: 3px 34px 3px 34px; }
  .gift-visual { width: 100%; border-width: 7px; }
  .gift-intro { font-size: 1.05rem; }
}
@media (max-height: 700px) {
  .hero { padding-top: 1rem; padding-bottom: .8rem; }
  .hero::before { inset: 8px; }
  .eyebrow { margin-bottom: .35rem; }
  .hero h1 { font-size: clamp(2.2rem, 7vh, 3.7rem); }
  .hero__thought { margin-top: .45rem; font-size: .95rem; }
  .keepsake { width: clamp(118px, 22vh, 155px); margin: .35rem auto .45rem; }
  .button { min-height: 46px; padding-block: .65rem; }
  .hero__hint { margin-top: .3rem; }
}
@media (max-height: 590px) {
  .keepsake { width: 140px; }.hero__hint { display: none; }.hero__thought { font-size: .85rem; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .js .reveal { opacity: 1; transform: none; }
}
@media (forced-colors: active) { .placeholder-photo, .thank-note, .letter-paper { border: 1px solid CanvasText; } }
