/* A small, self-contained birthday stage. All colours are scoped to the game. */
.mg-section{--mg-ink:#553b2d;--mg-muted:#796252;--mg-gold:#a56b24;padding:88px 24px 80px;background:#fffaf1;color:var(--mg-ink);text-align:center;position:relative}
.mg-section [hidden]{display:none!important}.mg-heading{max-width:650px;margin:0 auto 32px}.mg-heading .eyebrow{color:var(--mg-gold);margin-bottom:15px}.mg-heading h2{font-size:clamp(38px,4vw,57px);line-height:1.08;margin:0 0 16px}.mg-heading h2 em{color:var(--mg-gold)}.mg-heading>p:last-child{font-size:15px;line-height:1.6;color:var(--mg-muted);margin:0}
.mg-shell{max-width:1000px;margin:auto;background:#fdf4e7;border:1px solid #e9d9c1;border-radius:32px;overflow:hidden;box-shadow:0 18px 65px #6f44200d,0 2px 0 #fff inset;position:relative}
.mg-toolbar{position:relative;z-index:3;padding:20px 28px;display:flex;align-items:center;justify-content:space-between;gap:12px;font-size:12px;color:var(--mg-muted)}.mg-label{display:flex;align-items:center;gap:8px}.mg-label svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:1.5}.mg-score{display:flex;align-items:center;gap:12px}.mg-count{font-variant-numeric:tabular-nums;letter-spacing:1px;font-size:11px;font-weight:700;padding:7px 12px;border-radius:30px;background:#fff9ed;border:1px solid #e2ceb3}.mg-pause,.mg-replay{color:var(--mg-ink);background:transparent;border:0;text-decoration:underline;text-underline-offset:4px;cursor:pointer;min-height:44px;padding:8px}.mg-pause{font-size:12px}
.mg-scene{height:465px;position:relative;isolation:isolate;margin:-10px auto 0;max-width:660px;touch-action:pan-y}.mg-arch{position:absolute;left:50%;top:-14px;transform:translateX(-50%);width:74%;height:370px;border-radius:50% 50% 20px 20px;background:radial-gradient(ellipse at 50% 40%,#fff7e7 15%,#f7e7d1 70%);box-shadow:0 1px 1px #b48a5821 inset;border:1px solid #f1e0c8;z-index:-3}.mg-arch:after{content:'';position:absolute;inset:16px;border:1px solid #fff7e8;border-radius:inherit}.mg-floor{position:absolute;bottom:10px;left:7%;width:86%;height:165px;border-radius:50%;background:radial-gradient(ellipse,#e2c9a952,#f9eddd 65%,#fff0 72%);z-index:-2}.mg-stage-ring{position:absolute;bottom:22px;left:7%;width:86%;height:94px;border:1px solid #dcc3a548;border-radius:50%;z-index:-1}
.mg-bunting{position:absolute;width:68%;height:86px;left:16%;top:2px;opacity:.85}.mg-star{position:absolute;color:#b58642;top:104px;left:18%;font-size:22px;opacity:.6}.mg-star.second{left:auto;right:18%;top:190px;font-size:16px}.mg-balloon{position:absolute;width:64px;height:80px;border-radius:50% 50% 46% 46%;left:7%;top:105px;background:radial-gradient(circle at 32% 23%,#fff2e3 1%,#edccb6 35%,#cfaa96 100%);box-shadow:inset -6px -8px 13px #b47c5220,0 12px 20px #795d3810;transform:rotate(-12deg);animation:mg-balloon-float 6s ease-in-out infinite alternate;z-index:-1}.mg-balloon:before{content:'';position:absolute;width:1px;height:118px;left:50%;top:100%;background:linear-gradient(#c2aa86,#c2aa8600);transform:rotate(8deg)}.mg-balloon:after{content:'';position:absolute;left:calc(50% - 4px);bottom:-5px;border-left:4px solid transparent;border-right:4px solid transparent;border-bottom:7px solid #d5af96}.mg-balloon.blue{left:auto;right:6%;top:69px;width:72px;height:91px;background:radial-gradient(circle at 30% 23%,#edf7f5,#bcd8d5 48%,#9abebc);transform:rotate(12deg);animation-delay:-2s}.mg-balloon.blue:after{border-bottom-color:#a8c7c4}
.mg-cake{position:absolute;width:360px;height:240px;left:50%;top:119px;transform:translateX(-50%);filter:drop-shadow(0 16px 10px #8d603e1c);z-index:0}.mg-cake svg{display:block;width:100%;height:100%;overflow:visible}
.mg-candle{position:absolute;top:111px;left:var(--x);width:12px;height:53px;border-radius:4px 4px 2px 2px;background:repeating-linear-gradient(135deg,transparent 0 8px,#ffffff91 8px 12px),linear-gradient(90deg,#c08763,#ecc9a8 42%,#ce9d7b);box-shadow:2px 3px 3px #84602c24;transform:translateX(-50%);z-index:2;transition:filter .2s}.mg-candle:nth-child(even){background:repeating-linear-gradient(135deg,transparent 0 8px,#ffffff8a 8px 12px),linear-gradient(90deg,#7da7a6,#c0dcd7 42%,#85b0af)}.mg-candle:before{content:'';position:absolute;top:-7px;left:5px;width:2px;height:8px;background:#694d35;border-radius:2px}.mg-candle:after{content:'';position:absolute;bottom:-6px;left:-5px;width:22px;height:7px;border-radius:50%;background:#b28d5733;filter:blur(2px)}.mg-flame{position:absolute;bottom:calc(100% + 5px);left:-1px;width:14px;height:24px;border-radius:70% 30% 60% 40%;background:radial-gradient(ellipse at 50% 75%,#fffbe8 0 22%,#ffd985 40%,#f8b454 70%,#ed995b 100%);box-shadow:0 0 14px 5px #ffc87860;transform-origin:50% 100%;animation:mg-flicker .9s ease-in-out infinite alternate;animation-delay:var(--delay);transition:opacity .18s,scale .18s}.mg-candle.is-aligned .mg-flame{box-shadow:0 0 20px 9px #ffd177a6}.mg-candle.is-aligned{filter:brightness(1.08)}.mg-candle.is-out .mg-flame{opacity:0;scale:.15;animation:none}.mg-smoke{position:absolute;width:27px;height:60px;bottom:calc(100% + 5px);left:-8px;fill:none;stroke:#a39180;stroke-linecap:round;stroke-width:2;opacity:0}.mg-candle.is-out .mg-smoke{animation:mg-smoke 1.3s ease-out both}
.mg-player{position:absolute;bottom:18px;left:18%;width:172px;height:258px;transform:translateX(-50%);z-index:4;pointer-events:none}.mg-player:after{content:'';position:absolute;bottom:0;left:23%;width:61%;height:12px;border-radius:50%;background:#86613738;filter:blur(5px);z-index:-1}.mg-player-tilt{height:100%;transform-origin:50% 90%;transition:transform .18s}.mg-character-image{width:100%;height:100%;object-fit:contain}.mg-moving .mg-player img{animation:mg-walk .65s ease-in-out infinite}.mg-player.is-blowing .mg-player-tilt{transform:rotate(7deg) translateY(-3px) scaleY(.98)}.mg-breath{position:absolute;inset:0;width:100%;height:100%;z-index:5;pointer-events:none;overflow:visible;opacity:0}.mg-breath path{fill:none;stroke:#9ac4c9;stroke-width:3.5;stroke-linecap:round;filter:drop-shadow(0 1px 2px #8eaaac66);stroke-dasharray:45 210;stroke-dashoffset:60}.mg-breath path:nth-child(2){stroke-width:5;animation-delay:.055s!important}.mg-breath path:nth-child(3){stroke-width:2;animation-delay:.1s!important}.mg-breath.is-active{opacity:1}.mg-breath.is-active path{animation:mg-puff .55s ease-out both}
.mg-surface{position:absolute;inset:0;width:100%;height:100%;z-index:6;border:0;background:transparent;border-radius:24px;cursor:pointer;touch-action:pan-y;-webkit-tap-highlight-color:transparent}.mg-surface:disabled{cursor:default}.mg-surface:focus-visible{outline:2px solid #a56b24;outline-offset:-6px}.mg-start{position:absolute;z-index:7;left:50%;bottom:18px;transform:translateX(-50%);border:1px solid #85532b;background:#63422d;color:#fff9ed;border-radius:30px;padding:15px 27px;font-weight:600;box-shadow:0 5px 14px #62422d22;white-space:nowrap;cursor:pointer;min-height:48px}.mg-start:disabled{opacity:.7}.mg-start:hover{background:#795136}.mg-instructions{position:relative;padding:7px 20px 22px;min-height:92px}.mg-instruction{font-weight:600;font-size:14px;margin-bottom:6px;color:var(--mg-ink)}.mg-status{font-size:12px;line-height:1.6;color:var(--mg-muted);margin:0;min-height:20px}.mg-steps{display:none;gap:14px;justify-content:center;margin:10px 0}.mg-reduced .mg-steps{display:flex}.mg-step-left,.mg-step-right{background:#fff9ed;border:1px solid #d0b28e;border-radius:50%;width:44px;height:44px;color:#553b2d;font-size:20px;cursor:pointer}.mg-fallback{display:inline-block;color:#553b2d;text-decoration:underline;padding:10px}.mg-footnote{margin:21px 0 0;color:#796252;font:21px 'Caveat',cursive}
.mg-result{position:absolute;inset:0;z-index:9;display:flex;align-items:center;justify-content:center;padding:30px;background:#fbf0dfed;backdrop-filter:blur(7px);animation:mg-reveal .6s ease both}.mg-result-card{position:relative;display:grid;grid-template-columns:190px 1fr;gap:20px;align-items:center;text-align:left;width:760px;max-width:100%;padding:44px 38px 36px 24px;border:1px solid #e2cdb0;border-radius:27px;background:#fffdf6;box-shadow:0 20px 65px #78502b1c;color:#553b2d;z-index:1}.mg-celebration-mascot{height:295px;transform-origin:50% 100%;animation:mg-invite 2.5s ease-in-out infinite}.mg-result-kicker{margin:0 0 10px;color:#8b642f;font-size:10px;letter-spacing:1.8px;font-weight:700}.mg-result-title{font-family:'DM Serif Display',Georgia,serif;font-size:clamp(34px,3.7vw,48px);line-height:1.1;letter-spacing:-1px;font-weight:400;color:#553b2d;margin:0 0 20px}.mg-result-title:focus{outline:none}.mg-result-memory{color:#553b2d;font-size:18px;line-height:1.55;margin:0 0 17px}.mg-result-memory strong{font-weight:600}.mg-result-description{color:#796252;font-size:14px;line-height:1.7;margin:0 0 23px;max-width:330px}.mg-cta{display:inline-flex;align-items:center;justify-content:center;gap:10px;padding:17px 19px;border-radius:16px;color:#fffdf6;background:#315d4e;font-size:13px;font-weight:600;box-shadow:0 5px 0 #24483c,0 9px 16px #315d4e1c;transition:background .2s,transform .2s;min-height:52px}.mg-cta:hover{background:#244d3e;transform:translateY(-2px)}.mg-cta svg{width:20px;height:20px;flex-shrink:0;fill:none;stroke:currentColor;stroke-width:1.7}.mg-replay{display:block;font-size:12px;margin:13px 0 0;padding-left:0}.mg-confetti{position:absolute;inset:0;overflow:hidden;z-index:10;pointer-events:none}.mg-confetti i{position:absolute;top:-20px;width:7px;height:11px;background:#c79749;border-radius:2px;animation:mg-confetti 2.6s ease-out both;animation-delay:var(--delay)}.mg-confetti i:nth-child(3n){background:#9dbfb8}.mg-confetti i:nth-child(3n + 1){background:#d9aa93;border-radius:50%;width:8px;height:8px}.mg-dormant *, .mg-dormant *:before,.mg-dormant *:after{animation-play-state:paused!important}
@keyframes mg-flicker{from{transform:rotate(-5deg) scaleY(.92)}to{transform:rotate(7deg) scaleY(1.07)}}@keyframes mg-walk{0%,100%{transform:rotate(-2deg) translateY(0)}50%{transform:rotate(2deg) translateY(-5px)}}@keyframes mg-puff{0%{stroke-dashoffset:60;opacity:0}20%{opacity:1}100%{stroke-dashoffset:-220;opacity:0}}@keyframes mg-smoke{0%{opacity:0;transform:translateY(5px) scale(.6)}25%{opacity:.65}100%{opacity:0;transform:translateY(-28px) scale(1.4)}}@keyframes mg-balloon-float{to{translate:0 -9px;rotate:4deg}}@keyframes mg-invite{0%,100%{transform:rotate(-2deg)}50%{transform:rotate(2deg) translateY(-5px)}}@keyframes mg-reveal{from{opacity:0;translate:0 10px}to{opacity:1;translate:0 0}}@keyframes mg-confetti{0%{opacity:0;transform:translateY(-15px) rotate(0)}10%{opacity:1}100%{opacity:0;transform:translateY(620px) rotate(var(--turn))}}
@media(max-width:700px){.mg-section{padding:64px 16px 56px}.mg-heading{margin-bottom:25px}.mg-heading .eyebrow{font-size:9px}.mg-heading>p:last-child{font-size:14px;max-width:285px;margin:auto}.mg-shell{border-radius:24px}.mg-toolbar{padding:14px 17px;font-size:10px;min-height:66px}.mg-score{gap:5px}.mg-count{padding:6px 9px;font-size:10px}.mg-scene{height:430px}.mg-arch{width:86%;height:340px;top:0}.mg-cake{width:270px;height:180px;top:136px}.mg-candle{top:119px;height:53px;width:10px}.mg-candle:before{left:4px}.mg-flame{left:-2px}.mg-player{height:217px;width:145px;bottom:22px}.mg-balloon{width:41px;height:53px;left:4%;top:94px}.mg-balloon.blue{width:44px;height:57px;right:3%;top:79px}.mg-balloon:before{height:90px}.mg-star{left:12%;top:174px;font-size:17px}.mg-star.second{right:10%;top:234px;font-size:13px}.mg-bunting{width:80%;left:10%;top:5px}.mg-instructions{min-height:94px;padding:7px 16px 20px}.mg-status{font-size:11px;max-width:285px;margin:auto}.mg-start{bottom:7px;font-size:13px}.mg-result{padding:14px}.mg-result-card{display:flex;flex-direction:column;gap:0;text-align:center;padding:20px 18px 14px;border-radius:22px}.mg-celebration-mascot{height:145px;width:105px;align-self:center;margin-bottom:6px}.mg-result-kicker{font-size:8px;margin-bottom:8px}.mg-result-title{font-size:34px;margin-bottom:13px}.mg-result-memory{font-size:16px;line-height:1.5;margin-bottom:12px}.mg-result-description{font-size:12px;line-height:1.6;margin:0 auto 18px;max-width:250px}.mg-cta{font-size:12px;gap:8px;padding:15px 13px;border-radius:13px;width:100%}.mg-replay{margin:12px auto 0;font-size:11px;padding:7px}.mg-footnote{font-size:20px}.mg-result-content{width:100%}}
@media(max-width:370px){.mg-label span{max-width:110px;text-align:left;line-height:1.4}.mg-result-title{font-size:30px}.mg-celebration-mascot{height:125px}.mg-cta{font-size:11px}.mg-scene{height:415px}.mg-player{height:200px;width:134px}.mg-cake{width:248px;height:166px;top:139px}}
@media(prefers-reduced-motion:reduce){.mg-section *,.mg-section *:before,.mg-section *:after{animation:none!important;transition:none!important}.mg-player.is-blowing .mg-player-tilt{transform:none}.mg-breath.is-active{opacity:.8}.mg-breath.is-active path{stroke-dasharray:none}.mg-candle.is-out .mg-smoke{opacity:.4}.mg-result{backdrop-filter:none}}
