:root {
    --forest: #102d25;
    --forest-deep: #071b17;
    --moss: #315b3b;
    --gold: #e8bd67;
    --gold-light: #ffe6a8;
    --cream: #fff9e9;
    --ink: #21352c;
    --muted: #6d786f;
    --pink: #ed9da6;
    --pink-light: #ffd6df;
    --pink-magic: #d47d91;
    --pink-deep: #7d354f;
    --shadow: 0 20px 55px rgba(9, 31, 24, .17);
}

* { box-sizing: border-box; }
html {
    scroll-behavior: smooth;
    scroll-snap-type: y mandatory;
    scroll-padding-top: 0;
}
body {
    margin: 0;
    color: var(--ink);
    background: var(--forest-deep);
    font-family: "Nunito", sans-serif;
    overflow-x: hidden;
}
body.gift-locked { overflow: hidden; }
.gift-cover { position: fixed; inset: 0; z-index: 200; display: grid; overflow: hidden; place-items: center; color: white; background: radial-gradient(circle at 50% 0, #315b3b 0, var(--forest) 55%, var(--forest-deep) 100%); isolation: isolate; }
.gift-cover[hidden] { display: none; }
.gift-cover::before, .gift-cover::after { content: ""; position: absolute; top: 0; left: 0; width: 4px; height: 4px; z-index: -1; border-radius: 50%; pointer-events: none; background: #ffe6a8; }
.gift-cover::before { box-shadow: 7vw 18vh 7px #ffe6a8, 19vw 73vh 5px #fff4c7, 38vw 27vh 8px #ffe6a8, 61vw 82vh 6px #fff4c7, 79vw 14vh 8px #ffe6a8, 93vw 59vh 6px #fff4c7; animation: gift-stars-a 7s ease-in-out infinite; }
.gift-cover::after { width: 3px; height: 3px; box-shadow: 13vw 46vh 6px #fff4c7, 31vw 88vh 7px #ffe6a8, 53vw 9vh 5px #fff4c7, 72vw 56vh 8px #ffe6a8, 88vw 34vh 6px #fff4c7; animation: gift-stars-b 10s ease-in-out -3s infinite; }
.gift-button { display: grid; position: relative; width: min(430px, calc(100vw - 36px)); padding: 24px 18px 12px; place-items: center; border: 0; color: white; cursor: pointer; background: transparent; font: inherit; -webkit-tap-highlight-color: transparent; }
.gift-button:focus-visible { outline: 3px solid var(--gold-light); outline-offset: 5px; border-radius: 28px; }
.gift-title { margin-bottom: 28px; color: var(--gold-light); font: italic 600 clamp(2.2rem, 8vw, 3.8rem)/1 "Cormorant Garamond", serif; text-shadow: 0 4px 22px rgba(0,0,0,.35); }
.gift-box { display: block; position: relative; width: clamp(220px, 62vw, 310px); height: clamp(205px, 52vw, 260px); filter: drop-shadow(0 24px 28px rgba(0,0,0,.36)); }
.gift-body { display: grid; position: absolute; right: 7%; bottom: 0; left: 7%; height: 76%; place-items: center; overflow: hidden; border: 2px solid rgba(255,255,255,.34); border-radius: 12px 12px 24px 24px; background: linear-gradient(145deg, #f9c5d2, #dc8098); }
.gift-body::before, .gift-body::after { content: ""; position: absolute; border-radius: 50%; background: rgba(255,255,255,.13); }
.gift-body::before { width: 120px; height: 120px; top: -54px; left: -34px; }
.gift-body::after { width: 90px; height: 90px; right: -25px; bottom: -38px; }
.gift-ribbon { position: absolute; inset: 0 auto 0 50%; width: 38px; background: linear-gradient(90deg, #e8bd67, #fff0b9, #d5a544); transform: translateX(-50%); }
.gift-name { position: relative; z-index: 1; padding: 8px 15px; border-radius: 999px; color: #523043; background: rgba(255,249,233,.9); font: 700 1.35rem "Cormorant Garamond", serif; }
.gift-lid { position: absolute; top: 9%; right: 0; left: 0; height: 26%; z-index: 3; border: 2px solid rgba(255,255,255,.38); border-radius: 14px; background: linear-gradient(145deg, #ffdce5, #e895aa); transform-origin: 15% 100%; }
.gift-lid::after { content: ""; position: absolute; top: 0; bottom: 0; left: 50%; width: 42px; background: linear-gradient(90deg, #d9a63e, #fff0b9, #d9a63e); transform: translateX(-50%); }
.gift-flowers { position: absolute; right: 0; bottom: 72%; left: 0; z-index: 2; font-size: clamp(1.6rem, 7vw, 2.35rem); letter-spacing: -.12em; filter: drop-shadow(0 5px 5px rgba(0,0,0,.22)); }
.gift-bow { position: absolute; bottom: 42%; left: 50%; z-index: 4; color: #75591d; font-size: 2.6rem; transform: translate(-50%, 50%) rotate(90deg); }
.gift-hint { margin-top: 18px; padding: 9px 16px; border: 1px solid rgba(255,255,255,.28); border-radius: 999px; color: rgba(255,255,255,.9); background: rgba(255,255,255,.06); font-size: .85rem; font-weight: 800; animation: gift-hint-pulse 1.8s ease-in-out infinite; }
.gift-glow { position: absolute; top: 50%; left: 50%; width: 80px; height: 80px; z-index: -1; border-radius: 50%; background: #fff4bd; opacity: 0; transform: translate(-50%,-50%) scale(.2); box-shadow: 0 0 80px 40px rgba(255,230,168,.6); }
.gift-cover.opening { animation: gift-cover-away 2.15s ease-in forwards; }
.gift-cover.opening .gift-lid { animation: gift-lid-open 1.3s cubic-bezier(.2,.9,.25,1) forwards; }
.gift-cover.opening .gift-body { animation: gift-body-open 1.5s ease-out forwards; }
.gift-cover.opening .gift-glow { animation: gift-glow-open 1.5s ease-out forwards; }
.gift-cover.opening .gift-title, .gift-cover.opening .gift-hint { animation: gift-text-away .7s ease-out forwards; }
@keyframes gift-hint-pulse { 50% { transform: scale(1.04); background: rgba(255,255,255,.12); } }
@keyframes gift-lid-open { 45% { transform: translateY(-30px) rotate(-5deg); } 100% { transform: translate(-90px,-160px) rotate(-34deg); opacity: .2; } }
@keyframes gift-body-open { 55% { transform: scale(1.05); } 100% { transform: scale(.86) translateY(30px); opacity: .25; } }
@keyframes gift-glow-open { 35% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%,-50%) scale(8); } }
@keyframes gift-text-away { to { opacity: 0; transform: translateY(-16px); } }
@keyframes gift-cover-away { 0%, 72% { opacity: 1; } 100% { opacity: 0; visibility: hidden; } }
@keyframes gift-stars-a { 0%, 100% { opacity: .28; transform: translate3d(-5px,8px,0); } 45% { opacity: .9; transform: translate3d(9px,-8px,0); } 72% { opacity: .48; transform: translate3d(15px,-14px,0); } }
@keyframes gift-stars-b { 0%, 100% { opacity: .72; transform: translate3d(8px,-4px,0) scale(1); } 38% { opacity: .18; transform: translate3d(-7px,-13px,0) scale(.96); } 68% { opacity: .82; transform: translate3d(12px,-20px,0) scale(1.03); } }
.stage-butterflies { position: absolute; inset: 0; z-index: 2; overflow: hidden; pointer-events: none; }
.gift-cover .stage-butterflies { z-index: 0; }
.stage-butterfly { position: absolute; top: var(--butterfly-y); left: var(--butterfly-x); opacity: var(--butterfly-opacity); font-size: var(--butterfly-size); filter: drop-shadow(0 5px 5px rgba(0,0,0,.24)); will-change: transform; animation: random-butterfly-flight var(--butterfly-duration) ease-in-out var(--butterfly-delay) infinite alternate; }
.stage-butterfly.butterfly-natural { filter: drop-shadow(0 5px 5px rgba(0,0,0,.24)); }
.stage-butterfly.butterfly-yellow { filter: grayscale(.55) sepia(1) saturate(5.5) hue-rotate(350deg) brightness(1.25) drop-shadow(0 5px 5px rgba(0,0,0,.22)); }
.stage-butterfly.butterfly-pink { filter: grayscale(.25) sepia(.35) saturate(2.8) hue-rotate(285deg) brightness(1.16) drop-shadow(0 5px 5px rgba(0,0,0,.22)); }
@keyframes random-butterfly-flight {
    0% { transform: translate3d(0,0,0) rotate(var(--butterfly-rotation)) scaleX(var(--butterfly-flip)); }
    48% { transform: translate3d(var(--butterfly-drift-x),var(--butterfly-drift-y),0) rotate(var(--butterfly-rotation-end)) scale(1.12) scaleX(var(--butterfly-flip)); }
    100% { transform: translate3d(var(--butterfly-drift-x-2),var(--butterfly-drift-y-2),0) rotate(var(--butterfly-rotation)) scaleX(var(--butterfly-flip)); }
}
.hero,
.page-stage {
    min-height: 100svh;
    scroll-snap-align: start;
    scroll-snap-stop: always;
}
.page-stage {
    display: flex;
    position: relative;
    overflow: hidden;
    flex-direction: column;
    isolation: isolate;
}
.mobile-only { display: none; }
.page-stage::before,
.mobile-stage::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    opacity: .48;
    pointer-events: none;
    background:
        radial-gradient(circle at 9% 18%, rgba(255,230,168,.9) 0 2px, transparent 3px),
        radial-gradient(circle at 88% 23%, rgba(232,189,103,.75) 0 1.5px, transparent 3px),
        radial-gradient(circle at 18% 76%, rgba(255,255,220,.8) 0 1.5px, transparent 3px),
        radial-gradient(circle at 82% 82%, rgba(255,230,168,.8) 0 2px, transparent 3px),
        radial-gradient(circle at 52% 52%, rgba(255,255,255,.7) 0 1px, transparent 2px);
    background-size: 290px 270px, 330px 310px, 260px 300px, 370px 340px, 220px 240px;
    animation: fairy-drift 9s ease-in-out infinite alternate;
}
.page-stage > *:not(.stage-butterflies), .mobile-stage > *:not(.stage-butterflies) { position: relative; z-index: 1; }
button, input { font: inherit; }
.shell { width: min(1120px, calc(100% - 36px)); margin-inline: auto; }
.section { padding: 100px 0; }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { font-family: "Cormorant Garamond", serif; }
h2 { margin-bottom: 18px; font-size: clamp(2.6rem, 6vw, 4.7rem); line-height: .95; color: var(--forest); }
.section-kicker, .eyebrow { margin-bottom: 12px; color: #a5782b; font-size: .76rem; font-weight: 800; letter-spacing: .2em; text-transform: uppercase; }

.hero {
    position: relative;
    min-height: 100svh;
    color: white;
    background-image: linear-gradient(90deg, rgba(4, 20, 17, .88) 0%, rgba(4, 20, 17, .64) 35%, rgba(4, 20, 17, .05) 70%), url("../images/elaine-king-hero.png");
    background-size: cover;
    background-position: 62% center;
    isolation: isolate;
}
.hero::after { content: ""; position: absolute; inset: auto 0 0; height: 170px; z-index: -1; background: linear-gradient(transparent, rgba(7, 27, 23, .7)); }
.nav { height: 88px; display: flex; align-items: center; justify-content: flex-end; }
.brand { color: var(--gold-light); font: 700 1.6rem "Cormorant Garamond", serif; text-decoration: none; letter-spacing: .12em; }
.nav-link { padding: 9px 18px; border: 1px solid rgba(255,255,255,.35); border-radius: 999px; color: white; text-decoration: none; font-size: .9rem; }
.hero-content { display: flex; min-height: calc(100svh - 130px); padding-block: 9vh 16vh; align-items: flex-start; justify-content: center; flex-direction: column; }
.hero-content > * { max-width: 620px; }
.eyebrow { color: var(--gold-light); }
.hero h1 { margin-bottom: 0; font-size: clamp(3.4rem, 8vw, 7rem); font-weight: 500; line-height: .78; text-shadow: 0 4px 28px rgba(0,0,0,.25); }
.hero-name { max-width: none; margin: 4px 0 18px; color: var(--gold-light); font: italic 600 clamp(4.3rem, 11vw, 9rem)/1 "Cormorant Garamond", serif; white-space: nowrap; }
.hero-copy { max-width: 520px; margin-bottom: 30px; color: rgba(255,255,255,.86); font-size: 1.08rem; line-height: 1.7; }
.button { display: inline-flex; min-height: 48px; padding: 12px 23px; align-items: center; justify-content: center; gap: 12px; border: 0; border-radius: 999px; cursor: pointer; font-weight: 800; text-decoration: none; transition: transform .2s, box-shadow .2s, filter .2s; }
.button:hover { transform: translateY(-2px); filter: brightness(1.06); }
.button-primary { color: var(--forest-deep); background: linear-gradient(135deg, var(--gold-light), var(--gold)); box-shadow: 0 10px 30px rgba(232,189,103,.25); }
.scroll-cue { position: absolute; bottom: 26px; left: 50%; color: var(--gold-light); animation: float 2s ease-in-out infinite; }
.music-toggle { position: fixed; top: 22px; left: 18px; z-index: 90; display: grid; width: 48px; height: 48px; padding: 0; place-items: center; border: 1px solid rgba(255,230,168,.5); border-radius: 50%; color: var(--gold-light); cursor: pointer; background: rgba(7,27,23,.82); box-shadow: 0 10px 30px rgba(0,0,0,.28); backdrop-filter: blur(9px); }
.music-toggle[aria-pressed="true"] { color: var(--forest-deep); background: var(--gold-light); }
.music-toggle:focus-visible { outline: 3px solid white; outline-offset: 3px; }
.music-icon { display: grid; position: relative; width: 34px; height: 34px; place-items: center; font-size: 1.35rem; line-height: 1; }
.music-off-mark { position: absolute; inset: 2px; border: 2px solid #e22d3f; border-radius: 50%; }
.music-off-mark::after { content: ""; position: absolute; top: 14px; left: 2px; width: 25px; height: 2px; border-radius: 2px; background: #e22d3f; transform: rotate(-45deg); transform-origin: center; }
.music-toggle[aria-pressed="true"] .music-off-mark { display: none; }

.invitation-stage, .mobile-invitation-info, .mobile-invitation-message, .game-stage, .game-section, .records-stage { color: white; background: radial-gradient(circle at 50% 0, #315b3b 0, var(--forest) 55%, var(--forest-deep) 100%); }
.details { color: white; text-align: center; background: transparent; }
.details .section-kicker { color: var(--gold); }
.invitation-stage .section-kicker { font-size: 1.08rem; letter-spacing: .23em; }
.detail-grid { display: grid; margin-top: 55px; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.detail-card { padding: 42px 25px; border: 1px solid rgba(49,91,59,.13); border-radius: 160px 160px 24px 24px; background: rgba(255,255,255,.74); box-shadow: 0 12px 35px rgba(16,45,37,.06); }
.detail-card, .mobile-detail-card, .mobile-mission-card, .mobile-quote-card { position: relative; overflow: hidden; }
.detail-card::after, .mobile-detail-card::after, .mobile-mission-card::after, .mobile-quote-card::after {
    content: "✦";
    position: absolute;
    top: 13%;
    right: 10%;
    color: rgba(232,189,103,.72);
    pointer-events: none;
    text-shadow: -36px 58px 0 rgba(255,230,168,.42), 18px 112px 0 rgba(232,189,103,.28);
    animation: magic-sparkle 2.8s ease-in-out infinite alternate;
}
.detail-card.featured { color: white; background: var(--forest); transform: translateY(-18px); }
.video-door { width: 100%; cursor: pointer; font: inherit; transition: transform .25s, box-shadow .25s; }
.video-door:hover { transform: translateY(-23px); box-shadow: 0 25px 50px rgba(16,45,37,.25); }
.video-door:focus-visible { outline: 4px solid var(--gold); outline-offset: 5px; }
.video-door-hint { display: inline-flex; margin-top: 22px; padding: 8px 14px; align-items: center; gap: 8px; border: 1px solid rgba(255,255,255,.25); border-radius: 999px; color: var(--gold-light); font-size: .78rem; font-weight: 800; }
.detail-card.featured h3 { color: var(--gold-light); }
.detail-icon { display: block; margin-bottom: 18px; color: var(--gold); font-size: 2rem; }
.detail-card h3 { margin-bottom: 10px; font-size: 2rem; }
.detail-card p { min-height: 52px; color: var(--muted); line-height: 1.6; }
.detail-card.featured p { color: rgba(255,255,255,.72); }
.detail-card strong { display: block; font-size: .91rem; }
.detail-card .event-date { min-height: 0; margin-bottom: 8px; color: var(--gold-light); font: 700 clamp(1.7rem, 3vw, 2.35rem)/1.1 "Cormorant Garamond", serif; }
.detail-card .event-time { margin-bottom: 16px; color: white; }
.detail-card .event-surprises { min-height: 0; margin: 0; color: rgba(255,255,255,.78); font-size: .88rem; line-height: 1.45; }
.mission-card p { min-height: 0; color: var(--ink); font: 600 clamp(1.45rem, 2.7vw, 2.15rem)/1.25 "Cormorant Garamond", serif; }

@media (min-width: 821px) {
    .invitation-stage .detail-card {
        border-color: rgba(255,214,223,.38);
        color: var(--ink);
        background: linear-gradient(145deg, rgba(255,224,234,.88), rgba(255,190,211,.68));
        box-shadow: 0 18px 44px rgba(96,45,62,.16);
    }
    .invitation-stage .detail-card.featured { color: white; background: linear-gradient(145deg, rgba(255,186,210,.76), rgba(244,151,184,.62)); }
    .invitation-stage .detail-card h3 { color: var(--gold-light); }
    .invitation-stage .detail-card:not(.featured) p { color: var(--muted); }
    .invitation-stage .detail-card:not(.featured) .event-date { color: var(--ink); }
    .invitation-stage .detail-card:not(.featured) .event-time,
    .invitation-stage .detail-card:not(.featured) .event-surprises,
    .invitation-stage .detail-card:not(.featured) strong { color: #304239; }
    .invitation-stage .detail-card.featured p { color: rgba(255,255,255,.78); }
    .invitation-stage .detail-card.featured strong { color: var(--gold-light); }
    .invitation-stage .mission-card { background: linear-gradient(145deg, rgba(255,190,212,.72), rgba(244,151,184,.58)); }
    .invitation-stage .mission-card p { color: #24151c; font-weight: 700; text-shadow: none; }
    .invitation-stage .mission-card strong { color: #3d2d34; text-shadow: 0 1px 0 rgba(255,255,255,.28); }
}
.quote-section { padding: 30px 0 100px; background: transparent; }
.quote-card { position: relative; padding: 70px 30px; overflow: hidden; border: 1px solid rgba(255,255,255,.14); border-radius: 26px; color: white; text-align: center; background: linear-gradient(135deg, #244a35, #0b251e); box-shadow: var(--shadow); }
.quote-card > span { position: absolute; top: -35px; left: 4%; color: rgba(255,255,255,.07); font: 15rem "Cormorant Garamond"; }
.quote-card p { position: relative; max-width: 720px; margin: 0 auto 18px; color: var(--gold-light); font: italic 600 clamp(2rem, 5vw, 3.6rem)/1.15 "Cormorant Garamond"; }
.quote-card small { letter-spacing: .2em; text-transform: uppercase; }

.game-section { color: white; }
.game-layout { display: grid; grid-template-columns: .8fr 1.2fr; gap: 58px; align-items: center; }
.game-section h2 { color: var(--gold-light); }
.game-intro > p:not(.section-kicker):not(.form-message) { color: rgba(255,255,255,.7); line-height: 1.7; }
.game-intro label { display: block; margin: 26px 0 8px; color: var(--gold-light); font-size: .85rem; font-weight: 800; }
.player-type { display: grid; margin: 24px 0 18px; padding: 0; grid-template-columns: 1fr 1fr; gap: 9px; border: 0; }
.player-type legend { margin-bottom: 9px; color: var(--gold-light); font-size: .85rem; font-weight: 800; }
.player-type label { display: block; position: relative; margin: 0; cursor: pointer; }
.player-type input { position: absolute; opacity: 0; }
.player-type span { display: grid; min-height: 52px; padding: 10px 12px; place-items: center; border: 2px solid rgba(255,230,168,.68); border-radius: 14px; color: white; text-align: center; background: rgba(212,125,145,.16); box-shadow: 0 7px 20px rgba(0,0,0,.14); transition: .2s; }
.player-type input:checked + span { border-color: var(--gold); color: var(--forest-deep); background: var(--gold-light); box-shadow: 0 0 0 3px rgba(232,189,103,.16); }
.player-type input:focus-visible + span { outline: 3px solid white; outline-offset: 3px; }
.player-row { display: flex; gap: 10px; }
.player-row input { min-width: 0; flex: 1; padding: 13px 18px; border: 2px solid var(--gold-light); border-radius: 999px; outline: none; color: var(--ink); background: var(--cream); box-shadow: 0 8px 24px rgba(0,0,0,.16); }
.player-row input:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(232,189,103,.16); }
.player-row input::placeholder { color: #68756d; }
.game-duration {
    width: 100%;
    min-height: 48px;
    padding: 10px 42px 10px 16px;
    border: 1px solid rgba(255,255,255,.2);
    border-radius: 14px;
    outline: none;
    color: white;
    background: var(--forest) linear-gradient(45deg, transparent 50%, var(--gold-light) 50%) calc(100% - 20px) 20px/7px 7px no-repeat;
    appearance: none;
}
.game-duration:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(232,189,103,.16); }
.game-duration option { color: var(--ink); background: white; }
.form-message { min-height: 22px; margin: 8px 0 0; color: #ffcfcf; font-size: .85rem; }
.stats { display: grid; margin-top: 24px; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.stats div { padding: 13px 8px; border: 1px solid rgba(255,255,255,.1); border-radius: 12px; text-align: center; background: rgba(255,255,255,.04); }
.stats span { display: block; color: rgba(255,255,255,.55); font-size: .7rem; text-transform: uppercase; }
.stats strong, .stats strong span { display: inline; color: var(--gold-light); font-size: 1.5rem; }
.game-instructions { margin: 18px 0 0; padding: 14px 16px; border-radius: 14px; background: rgba(212,125,145,.12); }
.game-board { position: relative; height: min(560px, 67vh); min-height: 390px; overflow: hidden; border: 1px solid rgba(255,255,255,.14); border-radius: 28px; background: radial-gradient(circle at 50% 100%, #3d6c41 0, #173b2d 45%, #091f1a 100%); box-shadow: inset 0 -30px 60px rgba(0,0,0,.3), 0 25px 70px rgba(0,0,0,.3); }
.game-board::before { content: ""; position: absolute; inset: 0; opacity: .2; background-image: radial-gradient(circle, #ffe6a8 1px, transparent 2px); background-size: 47px 47px; }
.board-score { position: absolute; top: 14px; right: 17px; z-index: 4; color: rgba(255,255,255,.72); text-align: right; pointer-events: none; }
.board-score span { display: block; font-size: .58rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.board-score strong { color: var(--gold-light); font: 700 1.45rem/1 "Cormorant Garamond", serif; text-shadow: 0 2px 12px rgba(0,0,0,.45); }
.game-placeholder { position: absolute; inset: 0; display: grid; place-content: center; color: rgba(255,255,255,.55); text-align: center; }
.game-placeholder span { font-size: 4rem; filter: grayscale(.3); }
.game-placeholder p { max-width: 250px; }
.game-finish-actions { display: flex; margin-top: 18px; justify-content: center; flex-wrap: wrap; gap: 10px; }
.game-finish-actions[hidden] { display: none; }
.button-secondary { border: 1px solid rgba(255,255,255,.28); color: white; background: rgba(255,255,255,.08); }
.character-target { position: absolute; display: none; width: 132px; height: 150px; padding: 10px; touch-action: manipulation; border: 0; border-radius: 28px; cursor: pointer; background: rgba(255,255,255,.035); filter: drop-shadow(0 10px 11px rgba(0,0,0,.4)); animation: character-pop .18s ease-out; -webkit-tap-highlight-color: transparent; }
.character-target::after { content: ""; position: absolute; inset: 3px; border: 1px solid transparent; border-radius: 25px; }
.character-target:active { transform: scale(.94); }
.character-target img { display: block; width: 100%; height: 100%; pointer-events: none; object-fit: contain; user-select: none; }
.character-target:focus-visible { outline: 4px solid var(--gold-light); outline-offset: 4px; }
.character-target.correct-hit::after { border-color: #c7ffb8; box-shadow: 0 0 22px #8cff7b; }
.character-target.wrong-hit::after { border-color: #ffb2b2; box-shadow: 0 0 20px #ff7777; }

.records-stage { color: white; }
.leaderboard-section { background: transparent; }
.records-stage h2 { color: var(--gold-light); }
.records-stage .leaderboard-wrap > div > p:last-child { color: rgba(255,255,255,.72); }
.leaderboard-wrap { display: grid; grid-template-columns: .8fr 1.2fr; gap: 65px; align-items: center; }
.leaderboard-wrap > div > p:last-child { color: var(--muted); }
.leaderboard-card { padding: 18px 28px; border-radius: 24px; background: white; box-shadow: var(--shadow); }
.record-tabs { display: grid; margin-bottom: 12px; padding: 5px; grid-template-columns: repeat(3, 1fr); gap: 5px; border-radius: 999px; background: #f4eedb; }
.record-tab { min-height: 38px; border: 0; border-radius: 999px; color: var(--moss); cursor: pointer; background: transparent; font-weight: 800; }
.record-tab.active { color: var(--forest-deep); background: var(--gold-light); box-shadow: 0 4px 14px rgba(16,45,37,.12); }
.leaderboard { margin: 0; padding: 0; list-style: none; counter-reset: ranking; }
.leaderboard li { display: grid; padding: 15px 4px; grid-template-columns: 42px 1fr auto; align-items: center; border-bottom: 1px solid #eee9dc; counter-increment: ranking; }
.leaderboard li:last-child { border-bottom: 0; }
.leaderboard li::before { content: counter(ranking); display: grid; width: 28px; height: 28px; place-items: center; border-radius: 50%; color: var(--moss); background: #eef4e9; font-size: .8rem; font-weight: 800; }
.leaderboard li:nth-child(1)::before { color: #6b4910; background: var(--gold-light); }
.leaderboard-name { overflow: hidden; color: var(--ink); font-weight: 800; text-overflow: ellipsis; white-space: nowrap; }
.leaderboard-score { color: #a5782b; font-weight: 900; }
.leaderboard li.loading, .leaderboard li.empty { display: block; color: var(--muted); text-align: center; }
.leaderboard li.loading::before, .leaderboard li.empty::before { display: none; }
footer { padding: 30px 18px; color: rgba(255,255,255,.7); text-align: center; background: #061713; font-size: .87rem; }
footer p { margin: 0; }

.beach-note {
    max-width: 920px;
    margin: 30px auto 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    color: rgba(255,255,255,.78);
    background: transparent;
    line-height: 1.55;
    text-align: justify;
    text-justify: inter-word;
}
.beach-note strong { color: var(--gold-light); }

.invitation-stage .details { flex: 1; }
.game-stage .game-section { flex: 1; }
.records-stage .leaderboard-section { display: flex; flex: 1; align-items: center; }

@media (min-width: 821px) and (min-height: 680px) {
    .invitation-stage .details { padding: clamp(42px, 6vh, 72px) 0 28px; }
    .invitation-stage .detail-grid { margin-top: clamp(24px, 4vh, 42px); }
    .invitation-stage .detail-card { padding: clamp(25px, 4vh, 38px) 24px; }
    .invitation-stage .quote-section { padding: 0 0 clamp(26px, 5vh, 56px); }
    .invitation-stage .quote-card { padding: clamp(26px, 5vh, 52px) 30px; }

    .game-stage { background: radial-gradient(circle at 50% 0, #315b3b 0, var(--forest) 55%, var(--forest-deep) 100%); }
    .game-stage .game-section { padding: clamp(38px, 5vh, 64px) 0; }
    .game-stage .game-layout { grid-template-columns: minmax(280px, .78fr) minmax(420px, 1.22fr); gap: clamp(28px, 4vw, 58px); }
    .game-stage .game-board { height: clamp(390px, 52vh, 520px); }
    .records-stage .leaderboard-section { padding: clamp(48px, 8vh, 90px) 0; }
    .records-stage .leaderboard-wrap { grid-template-columns: .65fr 1.35fr; gap: 54px; }
    .records-stage .leaderboard-card { max-height: 70vh; overflow-y: auto; }
}

.fireflies::before, .fireflies::after {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 4px;
    height: 4px;
    z-index: 5;
    border-radius: 50%;
    pointer-events: none;
    background: #fff2ad;
    will-change: transform, opacity;
}
.fireflies::before {
    box-shadow: 8vw 16vh 7px #ffe592, 20vw 44vh 5px #fff2ad, 31vw 78vh 8px #ffe592, 46vw 26vh 6px #fff8cf, 58vw 63vh 9px #ffe592, 72vw 12vh 6px #fff2ad, 82vw 84vh 8px #ffe592, 94vw 38vh 7px #fff8cf;
    animation: star-drift-a 6.8s ease-in-out infinite;
}
.fireflies::after {
    width: 3px;
    height: 3px;
    box-shadow: 5vw 68vh 6px #fff8cf, 15vw 30vh 8px #ffe592, 38vw 9vh 5px #fff2ad, 49vw 88vh 7px #ffe592, 64vw 39vh 8px #fff8cf, 76vw 72vh 5px #ffe592, 89vw 20vh 8px #fff2ad, 97vw 61vh 6px #ffe592;
    animation: star-drift-b 9.2s ease-in-out -3.1s infinite;
}
@keyframes star-drift-a {
    0%, 100% { opacity: .3; transform: translate3d(-3px, 7px, 0) scale(.82); }
    28% { opacity: 1; transform: translate3d(7px, -5px, 0) scale(1.18); }
    57% { opacity: .48; transform: translate3d(13px, -13px, 0) scale(.9); }
    78% { opacity: .9; transform: translate3d(3px, -7px, 0) scale(1.08); }
}
@keyframes star-drift-b {
    0%, 100% { opacity: .85; transform: translate3d(8px, -4px, 0) scale(1); }
    24% { opacity: .25; transform: translate3d(15px, -12px, 0) scale(.72); }
    52% { opacity: 1; transform: translate3d(5px, -18px, 0) scale(1.22); }
    76% { opacity: .4; transform: translate3d(-5px, -9px, 0) scale(.85); }
}
@keyframes float { 50% { transform: translateY(9px); } }
@keyframes character-pop { from { opacity: 0; transform: scale(.3) rotate(-8deg); } to { opacity: 1; transform: scale(1); } }
@keyframes fairy-drift { to { opacity: .72; transform: translate3d(8px, -10px, 0); } }
@keyframes magic-sparkle { from { opacity: .32; transform: scale(.72) rotate(-8deg); } to { opacity: 1; transform: scale(1.12) rotate(8deg); } }

.video-modal[hidden] { display: none; }
.video-modal { position: fixed; inset: 0; z-index: 100; display: grid; padding: 24px; place-items: center; }
.video-modal-backdrop { position: absolute; inset: 0; background: rgba(3,16,13,.88); backdrop-filter: blur(8px); }
.video-modal-content { position: relative; width: min(980px, 100%); max-height: calc(100svh - 48px); padding: 28px; overflow-y: auto; border: 1px solid rgba(255,255,255,.15); border-radius: 26px; color: white; background: var(--forest-deep); box-shadow: 0 30px 100px rgba(0,0,0,.5); }
.video-modal-content h2 { color: var(--gold-light); }
.video-modal video { display: block; width: 100%; max-height: 65svh; border-radius: 16px; background: black; }
.video-close { position: absolute; top: 18px; right: 18px; z-index: 2; width: 44px; height: 44px; border: 1px solid rgba(255,255,255,.25); border-radius: 50%; color: white; cursor: pointer; background: rgba(255,255,255,.08); font-size: 1.8rem; line-height: 1; }
.video-note { margin: 15px 0 0; color: rgba(255,255,255,.63); font-size: .82rem; }
body.modal-open { overflow: hidden; }

.stage-back {
    position: fixed;
    top: max(78px, calc(env(safe-area-inset-top) + 64px));
    left: 14px;
    z-index: 80;
    min-height: 38px;
    padding: 8px 13px;
    border: 1px solid rgba(255,255,255,.3);
    border-radius: 999px;
    color: white;
    cursor: pointer;
    background: rgba(7,27,23,.78);
    box-shadow: 0 8px 24px rgba(0,0,0,.18);
    backdrop-filter: blur(8px);
    font-size: .78rem;
    font-weight: 800;
}
.stage-back[hidden] { display: none; }

@media (max-width: 820px) {
    .section { padding: 76px 0; }
    .hero { background-position: 68% center; }
    .hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(0deg, rgba(4,20,17,.93) 0, rgba(4,20,17,.35) 80%); }
    .hero-content { justify-content: flex-end; }
    .hero h1 { max-width: 490px; }
    .detail-grid { grid-template-columns: 1fr; }
    .detail-card { max-width: 520px; width: 100%; margin: 0 auto; border-radius: 90px 90px 24px 24px; }
    .detail-card.featured { transform: none; }
    .video-door:hover { transform: translateY(-4px); }
    .game-layout, .leaderboard-wrap { grid-template-columns: 1fr; }
    .game-board { height: 480px; }
    .page-stage { min-height: 100svh; }
    .invitation-stage .quote-section { padding-bottom: 76px; }
}
@media (max-width: 500px) {
    .invitation-stage { display: none; }
    .mobile-only { display: flex; }
    .mobile-stage {
        min-height: 100svh;
        padding: clamp(28px, 6svh, 54px) 0;
        position: relative;
        overflow: hidden;
        align-items: center;
        isolation: isolate;
        scroll-snap-align: start;
        scroll-snap-stop: always;
    }
    .mobile-stage-content {
        display: flex;
        min-height: calc(100svh - clamp(56px, 12svh, 108px));
        justify-content: center;
        flex-direction: column;
        gap: clamp(22px, 4svh, 38px);
    }
    .mobile-invitation-info { color: white; }
    .mobile-invitation-info h2 { margin-bottom: 0; font-size: clamp(3rem, 14vw, 4rem); }
    .mobile-invitation-info .section-kicker { color: var(--gold); }
    .mobile-invitation-info .section-kicker { font-size: 1.02rem; line-height: 1.45; }
    .mobile-detail-stack { display: grid; gap: 15px; }
    .mobile-detail-card {
        display: grid;
        width: 100%;
        min-height: clamp(142px, 22svh, 176px);
        padding: 24px;
        grid-template-columns: 54px 1fr;
        align-items: center;
        gap: 10px;
        border: 1px solid rgba(49,91,59,.13);
        border-radius: 78px 78px 28px 28px;
        color: var(--ink);
        text-align: left;
        background: linear-gradient(145deg, rgba(255,224,234,.88), rgba(255,190,211,.68));
        box-shadow: 0 12px 35px rgba(96,45,62,.1);
    }
    .mobile-detail-card .detail-icon { margin: 0; text-align: center; }
    .mobile-detail-card h3 { margin-bottom: 6px; font-size: 2.35rem; }
    .mobile-detail-card p { margin: 0; color: var(--muted); font-size: 1.06rem; line-height: 1.5; }
    .mobile-detail-card .mobile-event-date { color: var(--ink); font: 700 1.38rem/1.25 "Cormorant Garamond", serif; }
    .mobile-detail-card .mobile-event-surprises { margin-top: 8px; color: var(--muted); font-size: .94rem; line-height: 1.4; }
    .mobile-location-button { color: white; cursor: pointer; background: linear-gradient(145deg, rgba(255,186,210,.76), rgba(244,151,184,.62)); }
    .mobile-location-button h3, .mobile-location-button .detail-icon { color: var(--gold-light); }
    .mobile-location-button p { color: rgba(255,255,255,.78); }
    .mobile-location-button strong { display: block; margin-top: 9px; color: var(--gold-light); font-size: .92rem; }
    .mobile-location-button:focus-visible { outline: 4px solid var(--gold); outline-offset: 4px; }
    .mobile-beach-note { margin-top: 0; padding: 0; font-size: .9rem; }

    .mobile-invitation-message { color: white; }
    .mobile-mission-card, .mobile-quote-card { padding: clamp(25px, 5svh, 40px) 24px; border-radius: 68px 68px 28px 28px; text-align: center; }
    .mobile-mission-card { border: 1px solid rgba(255,214,223,.34); color: white; background: linear-gradient(145deg, rgba(255,190,212,.72), rgba(244,151,184,.58)); box-shadow: 0 16px 42px rgba(96,45,62,.12); }
    .mobile-mission-card .detail-icon { margin-bottom: 8px; }
    .mobile-mission-card h2 { margin-bottom: 12px; color: var(--gold-light); font-size: 2.8rem; }
    .mobile-mission-card p { color: rgba(255,255,255,.72); line-height: 1.55; }
    .mobile-mission-card p { color: var(--gold-light); font: 600 clamp(2rem, 9vw, 2.8rem)/1.18 "Cormorant Garamond", serif; }
    .mobile-mission-card strong { color: white; }
    .mobile-quote-card { border: 1px solid rgba(255,214,223,.3); color: white; background: linear-gradient(145deg, rgba(255,196,216,.7), rgba(241,145,178,.56)); box-shadow: 0 20px 55px rgba(96,45,62,.13); }
    .mobile-quote-card p { margin-bottom: 15px; color: var(--gold-light); font: italic 600 clamp(1.8rem, 8vw, 2.5rem)/1.15 "Cormorant Garamond", serif; }
    .mobile-quote-card small { color: white; }
    .mobile-quote-card small { letter-spacing: .18em; text-transform: uppercase; }

    .game-stage { display: block; min-height: 0; overflow: visible; scroll-snap-align: none; }
    .game-stage .game-section { padding: 0; }
    .game-stage .game-layout { display: block; }
    .game-stage .game-intro {
        display: flex;
        min-height: 100svh;
        padding: 24px 0;
        justify-content: center;
        flex-direction: column;
        scroll-snap-align: start;
        scroll-snap-stop: always;
    }
    .game-stage .game-intro h2 { margin-bottom: 10px; font-size: clamp(2.7rem, 12vw, 3.4rem); }
    .game-stage .game-intro > p:not(.section-kicker):not(.form-message) { margin-bottom: 8px; line-height: 1.42; }
    .game-stage .player-type { margin: 12px 0 8px; grid-template-columns: 1fr 1fr; }
    .game-stage .player-type span { min-height: 48px; padding: 8px; font-size: .8rem; }
    .game-stage .game-intro > label { margin: 10px 0 6px; }
    .game-stage .game-duration { min-height: 43px; }
    .game-stage .player-row { flex-direction: row; }
    .game-stage .player-row .button { padding-inline: 18px; }
    .game-stage .stats { margin-top: 12px; }
    .game-stage .stats div { padding: 9px 5px; }
    .game-stage .form-message { min-height: 18px; margin-top: 4px; }
    .game-stage .game-board {
        height: calc(100svh - 36px);
        min-height: 0;
        margin: 18px 0;
        scroll-snap-align: start;
        scroll-snap-stop: always;
    }
    .hero { min-height: 100svh; background-position: 67% center; }
    .hero-content { min-height: calc(100svh - 100px); padding-bottom: 11vh; }
    .hero h1 { font-size: 3.5rem; }
    .hero .eyebrow { margin-bottom: 22px; }
    .hero h1 { margin-bottom: 18px; }
    .hero-name { max-width: 620px; margin: 12px 0 30px; font-size: 5rem; white-space: normal; }
    .hero-copy { margin-bottom: 42px; font-size: .96rem; }
    .player-row { align-items: stretch; flex-direction: column; }
    .player-type { grid-template-columns: 1fr; }
    .game-board { min-height: 390px; height: 54vh; }
    .character-target { width: 118px; height: 138px; padding: 8px; }
    .video-modal { padding: 12px; }
    .video-modal-content { padding: 22px 14px 16px; }
    .leaderboard-card { padding: 12px 16px; }
}
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; scroll-snap-type: none; }
    *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}
