/* =====================================================================
   Santa Calls: the "magic" layer. Gentle motion that makes the whole site
   feel enchanted: things drift in, stars twinkle, gold shimmers, buttons
   catch the light and taps leave a puff of sparkles (see js/magic.js).
   - Nothing here runs on the call screen (body.in-call): Santa's face needs
     the processor there.
   - theme.css already switches every animation off for people who ask their
     device to reduce motion, and magic.js shows everything straight away for them.
   ===================================================================== */

/* ---------- Header button: just the words ---------- */
.site-header .parent-button { gap:0; padding:9px 18px; border-radius:999px; border:1px solid #daba76a6; background:linear-gradient(180deg,#17423bd9,#0e2f31d9); color:#f8edcf; letter-spacing:.4px; box-shadow:inset 0 1px 0 #ffffff14, 0 4px 14px #0004; position:relative; overflow:hidden; }
.site-header .parent-button:hover { background:linear-gradient(180deg,#1d5045e6,#123a3be6); border-color:#e8cd8f; color:#fff; box-shadow:inset 0 1px 0 #ffffff1f, 0 0 18px #e1be7e55; }
@media (max-width:650px) { .site-header .parent-button { padding:8px 13px; } }

/* ---------- Things drift in as they come into view ---------- */
html.magic-on .magic-reveal { opacity:0; translate:0 26px; scale:.97; filter:blur(5px); transition:opacity .9s ease, translate .9s cubic-bezier(.2,.8,.2,1), scale .9s cubic-bezier(.2,.8,.2,1), filter .9s ease; transition-delay:var(--magic-delay, 0ms); }
html.magic-on .magic-reveal.is-in { opacity:1; translate:0 0; scale:1; filter:none; }

/* ---------- The hero arrives like a curtain rising ---------- */
html.magic-on .landing .hero-copy > * { animation:magic-rise 1.1s cubic-bezier(.2,.8,.2,1) both; }
html.magic-on .landing .hero-copy > :nth-child(1) { animation-delay:.10s; }
html.magic-on .landing .hero-copy > :nth-child(2) { animation-delay:.25s; }
html.magic-on .landing .hero-copy > :nth-child(3) { animation-delay:.45s; }
html.magic-on .landing .hero-copy > :nth-child(4) { animation-delay:.60s; }
html.magic-on .landing .hero-copy > :nth-child(5) { animation-delay:.72s; }
html.magic-on .landing .hero-copy > :nth-child(6) { animation-delay:.84s; }
html.magic-on .landing .hero-copy > :nth-child(n+7) { animation-delay:.96s; }
html.magic-on .landing .phone-scene { animation:magic-rise-big 1.4s cubic-bezier(.2,.8,.2,1) .2s both; }
@keyframes magic-rise { from { opacity:0; translate:0 22px; filter:blur(6px); } to { opacity:1; translate:0 0; filter:none; } }
@keyframes magic-rise-big { from { opacity:0; translate:0 40px; filter:blur(8px); } to { opacity:1; translate:0 0; filter:none; } }

/* ---------- Gold that shimmers ---------- */
.landing .section-intro h2 em, .landing .elf-copy h2 em, .landing .membership-copy h2 em {
    background:linear-gradient(100deg,#d9b46a 0%,#e9c98a 38%,#fff6dc 50%,#e9c98a 62%,#d9b46a 100%);
    background-size:260% 100%; -webkit-background-clip:text; background-clip:text; color:transparent;
    animation:magic-shimmer 7s ease-in-out infinite;
}
@keyframes magic-shimmer { 0%,15% { background-position:100% 0; } 55%,100% { background-position:0 0; } }

/* ---------- Stars twinkle, pictures float ---------- */
.landing .elf-star, .landing .headline-star, .landing .eyebrow > svg, .closing svg[class*="star"] { animation:magic-twinkle 3.2s ease-in-out infinite; transform-origin:center; }
.landing .elf-star-two, .landing .eyebrow > svg:last-child { animation-delay:1.4s; }
@keyframes magic-twinkle { 0%,100% { opacity:1; scale:1; rotate:0deg; } 50% { opacity:.45; scale:.72; rotate:20deg; } }

.landing .elf-photo-girl { animation:magic-float 6.5s ease-in-out infinite; }
.landing .elf-photo-boy  { animation:magic-float 7.5s ease-in-out -2.5s infinite; }
.landing .elf-tag        { animation:magic-float 5.5s ease-in-out -1s infinite; }
.landing .nice-quote img { animation:magic-float 6s ease-in-out infinite; }
.landing .gift-one       { animation:magic-float 5s ease-in-out infinite; }
.landing .gift-two       { animation:magic-float 6s ease-in-out -2s infinite; }
@keyframes magic-float { 0%,100% { translate:0 0; } 50% { translate:0 -9px; } }

/* The New: elf link glows softly now and then */
.landing .elf-teaser { animation:magic-glow 4.5s ease-in-out infinite; }
@keyframes magic-glow { 0%,100% { box-shadow:0 0 0 #e1be7e00; } 50% { box-shadow:0 0 22px #e1be7e40; } }

/* ---------- Buttons catch the light ---------- */
.magic-shine-host { position:relative; overflow:hidden; isolation:isolate; }
.magic-shine { position:absolute; inset:0; pointer-events:none; z-index:1; background:linear-gradient(105deg,transparent 35%,#ffffff55 48%,#fff8 50%,#ffffff55 52%,transparent 65%); background-size:250% 100%; background-position:150% 0; animation:magic-sheen 5.5s ease-in-out infinite; animation-delay:var(--magic-delay, 0s); mix-blend-mode:soft-light; }
@keyframes magic-sheen { 0%,62% { background-position:150% 0; } 85%,100% { background-position:-60% 0; } }

/* ---------- Cards lift and glow under your finger ---------- */
.landing .steps article, .landing .nice-cards article, .call-card { transition:translate .35s cubic-bezier(.2,.8,.2,1), box-shadow .35s ease, border-color .35s ease; }
.landing .steps article:hover { translate:0 -6px; } /* the three steps just lift: no box or edge */
.landing .nice-cards article:hover { translate:0 -6px; box-shadow:0 14px 34px #0006, 0 0 0 1px #e1be7e55; border-color:#e1be7e80; }
.call-card:hover { translate:0 -5px; box-shadow:0 14px 30px #6b4a2033, 0 0 0 2px #e1be7e88 !important; }

/* Kids page: the little tree sways */
.call-title-tree { display:inline-block; animation:magic-sway 3.5s ease-in-out infinite; transform-origin:50% 90%; }
@keyframes magic-sway { 0%,100% { rotate:-6deg; } 50% { rotate:6deg; } }

/* ---------- Sparkles: puffs on tap, fairy dust behind the pointer ---------- */
.magic-spark, .magic-dust { position:fixed; left:0; top:0; pointer-events:none; z-index:9999; }
.magic-spark { width:var(--s,10px); height:var(--s,10px); margin:calc(var(--s,10px) / -2) 0 0 calc(var(--s,10px) / -2); color:var(--c,#f3d58f); animation:magic-burst .85s cubic-bezier(.15,.7,.3,1) forwards; }
.magic-spark svg { width:100%; height:100%; display:block; filter:drop-shadow(0 0 4px currentColor); }
@keyframes magic-burst {
    0%   { opacity:1; transform:translate(0,0) scale(.4) rotate(0deg); }
    70%  { opacity:1; }
    100% { opacity:0; transform:translate(var(--dx),var(--dy)) scale(1) rotate(160deg); }
}
.magic-dust { width:var(--s,4px); height:var(--s,4px); margin:-2px 0 0 -2px; border-radius:50%; background:var(--c,#ffe6a8); box-shadow:0 0 6px 1px var(--c,#ffe6a8); animation:magic-dust 1s ease-out forwards; }
@keyframes magic-dust { from { opacity:.9; transform:translate(0,0) scale(1); } to { opacity:0; transform:translate(var(--dx,0),var(--dy,18px)) scale(.2); } }

/* Sign-in "coming soon" page */
.signin-soon { padding:30px 10px; max-width:520px; margin:0 auto; }
.signin-star { font-size:46px; animation:magic-float 4s ease-in-out infinite; display:inline-block; }

@media (prefers-reduced-motion: reduce) {
    html.magic-on .magic-reveal { opacity:1; translate:none; scale:none; filter:none; }
    .magic-spark, .magic-dust, .magic-shine { display:none; }
}

/* FAQs (accordion in magic.js): the chevron turns smoothly, and turns back as soon as an answer starts closing. */
.faqs summary svg { transition:transform .45s cubic-bezier(.25,.8,.25,1); }
.faqs details.is-closing summary svg { transform:none; }
.faqs summary { transition:color .25s ease; }
.faqs summary:hover { color:#e1be7e; }

/* =====================================================================
   Phone menu: a full-page night sky that opens like a circle of light
   growing out of the menu button (--mx/--my are set by site.js), with
   the links drifting in one by one. Bigger screens keep the plain top menu.
   ===================================================================== */
.menu-head, .menu-foot, .menu-sky, .nav .menu-only { display:none; }

@media (max-width:650px) {
    body.menu-open { overflow:hidden; }
    body.menu-open .site-header { z-index:1000; }

    .nav, .nav.open {
        display:flex; position:fixed; inset:0; z-index:1000;
        flex-direction:column; align-items:center; gap:2px;
        padding:0 22px calc(26px + env(safe-area-inset-bottom));
        background:
            radial-gradient(ellipse 130% 55% at 50% -12%, #2a8a6c4d, transparent 62%),
            radial-gradient(ellipse 80% 40% at 15% 30%, #3d7d9a26, transparent 70%),
            radial-gradient(ellipse 100% 45% at 85% 112%, #9c2c2c3d, transparent 65%),
            linear-gradient(180deg,#0a2a33 0%,#0b252c 55%,#061a20 100%);
        border:0; box-shadow:none; backdrop-filter:none; color:#f8edcf;
        overflow-y:auto; overscroll-behavior:contain;
        clip-path:circle(0px at var(--mx, calc(100% - 34px)) var(--my, 60px));
        visibility:hidden; pointer-events:none;
        transition:clip-path .5s cubic-bezier(.6,0,.35,1) .12s, visibility 0s linear .62s;
    }
    .nav.open {
        clip-path:circle(150vmax at var(--mx, calc(100% - 34px)) var(--my, 60px));
        visibility:visible; pointer-events:auto;
        transition:clip-path .8s cubic-bezier(.65,0,.2,1), visibility 0s;
    }

    /* Top bar: logo and a round close button */
    .menu-head { display:flex; width:100%; height:75px; flex-shrink:0; align-items:center; justify-content:space-between; margin-bottom:5vh; border-bottom:1px solid #e6d8b81f; }
    .menu-logo img { height:42px; width:auto; display:block; filter:drop-shadow(0 0 1px #fffaeef2) drop-shadow(0 0 2px #fffaeecc) drop-shadow(0 2px 10px #fff4dc59); } /* same glow as the header logo */
    .nav .menu-logo, .nav .menu-account { padding:0; }
    .nav .menu-logo::after, .nav .menu-account::after { display:none; }
    .menu-close { display:grid; place-items:center; width:44px; height:44px; border-radius:50%; border:1px solid #daba7680; background:#ffffff0a; color:#f8edcf; rotate:-90deg; scale:.6; opacity:0; transition:rotate .5s cubic-bezier(.3,1.4,.5,1), scale .5s cubic-bezier(.3,1.4,.5,1), opacity .3s; }
    .nav.open .menu-close { rotate:0deg; scale:1; opacity:1; transition-delay:.35s; }
    .menu-logo { opacity:0; translate:0 -8px; transition:opacity .3s, translate .3s; }
    .nav.open .menu-logo { opacity:1; translate:0 0; transition:opacity .6s .3s, translate .6s cubic-bezier(.2,.8,.2,1) .3s; }

    /* The links: big festive type that drifts in one after another */
    .nav > a { font-family:var(--serif); font-size:31px; line-height:1.15; color:#f8edcf; padding:13px 0; text-align:center;
        opacity:0; translate:0 22px; filter:blur(5px); transition:opacity .2s, translate .2s, filter .2s, color .25s; }
    .nav > a.menu-only { display:block; }
    .nav.open > a { opacity:1; translate:0 0; filter:none;
        transition:opacity .6s ease, translate .7s cubic-bezier(.2,.8,.2,1), filter .6s ease, color .25s;
        transition-delay:calc(.32s + var(--i, 0) * .08s); }
    .nav > a:hover, .nav > a:focus-visible { color:#f3cc7b; }
    .nav > a::after { left:50%; right:50%; bottom:6px; background:#e8bd72; transition:left .3s, right .3s; }
    .nav > a:hover::after { left:30%; right:30%; }

    /* Bottom: the grown-ups' button and a sign-off */
    .menu-foot { display:flex; flex-direction:column; align-items:center; gap:16px; margin-top:auto; padding-top:28px; width:100%;
        opacity:0; translate:0 16px; transition:opacity .2s, translate .2s; }
    .nav.open .menu-foot { opacity:1; translate:0 0; transition:opacity .6s .65s, translate .7s cubic-bezier(.2,.8,.2,1) .65s; }
    .nav .menu-account { display:inline-block; padding:14px 40px; border-radius:999px; border:1px solid #daba76a6; background:linear-gradient(180deg,#17423b,#0e2f31); color:#f8edcf; font-size:14px; font-weight:600; letter-spacing:.4px; box-shadow:0 0 22px #e1be7e26; }
    .menu-foot p { margin:0; display:flex; gap:8px; align-items:center; font-family:'Caveat',cursive; font-size:17px; color:#a8bfba; }
    .menu-foot p svg { width:8px; height:8px; color:#daba76; }

    /* Twinkling stars behind it all */
    .menu-sky { display:block; position:absolute; inset:0; z-index:-1; pointer-events:none; }
    .menu-sky i { position:absolute; width:var(--z); height:var(--z); border-radius:50%; background:#fff3d6; box-shadow:0 0 8px 2px #f3d58f66; opacity:.2; animation:menu-twinkle 3.4s ease-in-out infinite; }
    @keyframes menu-twinkle { 0%,100% { opacity:.15; scale:.6; } 50% { opacity:.9; scale:1; } }
}
