.intro-video-controls{justify-content:space-between}
.egg-page,.birth-page,.name-page,.first-three-page,.garden-arrival-page{height:100dvh;min-height:0;overflow:hidden}
.egg-discovery{min-height:0}
.phone .egg-page>.egg-discovery{position:absolute;inset:0;height:100%}
.phone :is(.egg-page,.birth-page,.name-page,.first-three-page,.garden-arrival-page)>.test-survey-prompt{display:none}
.phone:has(:is(.egg-page,.birth-page,.name-page,.first-three-page,.garden-arrival-page)){height:100dvh;min-height:0}
.phone>:is(.egg-page,.birth-page,.name-page,.first-three-page,.garden-arrival-page){flex:0 0 100%;height:100%;max-height:100%;min-height:0}
.egg-prompt{position:absolute;z-index:3;left:18px;right:18px;bottom:calc(38px + env(safe-area-inset-bottom));padding:14px 18px;border-radius:20px;background:#141526dc;color:#fff;text-align:center;pointer-events:none;box-shadow:0 8px 28px #0008}
.egg-prompt p{font-size:17px;font-weight:700;line-height:1.4}
.egg-prompt span{display:block;font-size:26px;letter-spacing:.3em;line-height:1.4;color:#efe0ff}
.egg-discovery.tap-1 .egg-touch,.egg-discovery.tap-2 .egg-touch{animation:eggKnockOne .45s ease-out}
.egg-discovery.tap-2 .egg-touch{animation-name:eggKnockTwo}
@keyframes egg-knock{0%,100%{transform:translateX(0) rotate(0)}25%{transform:translateX(-5px) rotate(-2deg)}55%{transform:translateX(5px) rotate(2deg)}}
@keyframes egg-flash{0%,100%{filter:none}40%{filter:brightness(1.28)}}
.birth-stage{min-height:0;height:100%;overflow:hidden}
.birth-stage video{object-fit:cover;background:#141323}
.birth-seam{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;pointer-events:none}
.birth-video-playing .birth-seam{opacity:0;transition:opacity .25s}
.sound-toggle{display:grid;place-items:center;width:48px;height:52px;border-radius:14px;border:1px solid #fff8;background:#141323b3;color:#fff;line-height:1}
.sound-toggle span{font-size:21px}.sound-toggle small{font-size:10px;font-weight:800}.sound-toggle.is-on{background:#f3e7ffe6;color:#2a1f45}
.egg-page .sound-toggle{position:absolute;z-index:5;right:18px;top:calc(16px + env(safe-area-inset-top))}
.birth-haze{background:linear-gradient(#14132388,transparent 20%,transparent 80%,#14132377)}
.birth-top{position:absolute;z-index:2;top:calc(16px + env(safe-area-inset-top));left:18px;right:18px;display:flex;align-items:center;justify-content:space-between;gap:12px;color:white;font-size:13px;font-weight:700;text-shadow:0 1px 5px #000}
.birth-sound{border:1px solid #fff8;border-radius:50%;width:40px;height:40px;background:#141323b3;color:white;font-size:18px}
.birth-bottom{position:absolute;left:0;right:0;bottom:0;z-index:3;padding:20px 20px calc(22px + env(safe-area-inset-bottom));background:linear-gradient(#19162ce8,#19162cfa);text-align:center;animation:card-sheet-rise .35s ease-out}
.birth-bottom h1{margin:0 0 8px;font-size:clamp(23px,6vw,29px)}
.birth-bottom p{margin:0 0 14px;font-size:12px;line-height:1.5}
.birth-bottom .button{text-align:center}
.birth-replay{display:block;margin:8px auto 0;padding:3px 10px;border:0;background:none;color:#d9cdec;text-decoration:underline;font-size:12px}
.name-page{padding-bottom:calc(20px + env(safe-area-inset-bottom))}
.name-page .hero{padding-top:15px}
.name-page .name-fox{min-height:0;height:auto;flex:1;margin:16px 0;overflow:hidden}
.name-page .name-fox img{height:min(35dvh,245px)}
.name-page #name-form{flex:none}
/* Keep the birth actions anchored to the visible viewport, including during the reveal. */
.app-shell:has(.birth-page){padding:0;min-height:100dvh;align-items:center}
#app>.phone:has(.birth-page){height:100dvh;max-height:100dvh;min-height:0}
#app>.phone>.birth-page{flex:1 1 auto;height:100%;min-height:0;max-height:100%;overflow:hidden}
.birth-page>.birth-stage{height:100%;min-height:0;max-height:100%}
.birth-bottom{max-height:100%;overflow-y:auto;overscroll-behavior:contain;animation:none;padding-bottom:calc(22px + env(safe-area-inset-bottom))}
.name-page #name-form .button{text-align:center}
.first-three-page{padding:0!important}
.first-three.first-three-guardian-flow,.first-three.first-three-star-flow{box-sizing:border-box;width:100%;max-width:none;height:100%;min-height:0;margin:0;padding:calc(16px + env(safe-area-inset-top)) 14px calc(16px + env(safe-area-inset-bottom));display:flex;flex-direction:column;gap:10px;overflow:hidden}
.first-flow-heading{flex:none;text-align:center}
.first-flow-heading h1{font-size:clamp(19px,5vw,25px);line-height:1.3;margin:0}
.first-flow-star-name{display:block;font-size:.7em;font-weight:500;color:#d9cff0}
.first-flow-heading small{display:block;margin-bottom:4px;color:#d5c5f5;font-size:12px}
.first-flow-heading p{font-size:12px;line-height:1.5;margin:5px 0 0;max-height:4.5em;overflow:hidden;color:#e9e3f4}
.first-three-guardian-flow>.saju-card-reveal{flex:1;min-height:0;max-height:none;width:100%;max-width:100%;margin:0;display:flex;flex-direction:column}
.first-three-guardian-flow>.saju-card-reveal>.saju-card-art{position:relative;flex:1;min-height:0;aspect-ratio:auto;border-radius:14px;background:#131327}
.first-three-guardian-flow .saju-card-art img,.first-three-guardian-flow .saju-card-art video{position:absolute;inset:0;width:100%;height:100%;object-fit:contain}
.first-three-guardian-flow .saju-card-art video:not(.is-playing){display:none}
.first-three-guardian-flow .saju-card-reveal:not([open]) .saju-card-caption{display:none}
.first-three-guardian-flow .saju-card-reveal>.saju-card-tti,.first-three-guardian-flow .saju-card-explain{display:none}
.first-flow-notes{flex:none;display:grid;gap:4px}
.first-flow-notes p{margin:0;padding:7px 10px;border-radius:10px;background:#ffffff13;color:#eee8fa;font-size:11px;line-height:1.45}
.first-flow-footer{flex:none;margin-top:auto!important;margin-left:0!important;margin-right:0!important;width:100%}
.first-flow-footer .button{text-align:center}
.first-three-guardian-flow .saju-card-reveal[open][data-stage='sheet']>.saju-card-art{display:none!important}
.first-three-guardian-flow .saju-card-reveal[open][data-stage='sheet'] .saju-card-sheet{max-height:85dvh;z-index:103}
.first-three-guardian-flow:has(.saju-card-reveal[open])>.first-flow-footer{visibility:hidden}
.first-three-guardian-flow .saju-card-sheet>.button{margin-top:12px;text-align:center}
.first-flow-art{flex:1;min-height:0;display:flex;align-items:center;justify-content:center;overflow:hidden}
.first-flow-art img{height:100%;max-width:100%;object-fit:contain;border-radius:14px}
.garden-arrival-page{padding:0!important}
.garden-arrival{height:100%;padding:calc(25px + env(safe-area-inset-top)) 20px calc(20px + env(safe-area-inset-bottom));display:flex;flex-direction:column;text-align:center;background:radial-gradient(circle at 50% 45%,#5f558d,#211d49 65%,#141230)}
.garden-arrival h1{font-size:clamp(24px,6vw,30px)}
.garden-arrival-spirit{flex:1;min-height:0;display:grid;place-items:center}
.garden-arrival-spirit img{width:100%;height:min(55dvh,460px);object-fit:contain;filter:drop-shadow(0 12px 32px #cbb8ff88)}
@media(min-width:521px){.phone:has(.first-three-page),.phone:has(.garden-arrival-page),.phone:has(.birth-page),.phone:has(.egg-page),.phone:has(.name-page){height:100dvh;max-height:1060px;min-height:0;width:min(100%,560px);border:0;border-radius:0;margin-inline:auto}.egg-page,.birth-page,.name-page,.first-three-page,.garden-arrival-page{height:100%}}
.phone>.page:is(.egg-page,.name-page,.first-three-page,.garden-arrival-page){min-height:0;overflow-y:auto;overscroll-behavior:contain}
.first-three.first-three-guardian-flow,.first-three.first-three-star-flow{overflow-y:auto}
.first-flow-footer{position:sticky;bottom:0;z-index:5;padding-bottom:env(safe-area-inset-bottom);background:#19162c}
.first-flow-art{min-height:120px}
.first-flow-footer .button{display:flex;align-items:center;justify-content:center}
#app:has(.tester-banner) .birth-top,#app:has(.tester-banner) .egg-page .sound-toggle{top:calc(46px + env(safe-area-inset-top))}
#app:has(.tester-banner) .first-three.first-three-guardian-flow,#app:has(.tester-banner) .first-three.first-three-star-flow{padding-top:calc(48px + env(safe-area-inset-top))}
/* The approved egg image carries no printed shadow; the future form appears softly above it. */
.egg-touch>img.egg-spirit-shadow{position:absolute;z-index:1;left:35%;top:38%;width:30%;height:29%;object-fit:contain;filter:brightness(0) blur(7px);opacity:.18;transform:scale(.83);transition:opacity .55s ease,filter .55s ease,transform .55s ease;animation:none;pointer-events:none}
.egg-discovery.tap-1 .egg-touch>img.egg-spirit-shadow{opacity:.27;filter:brightness(0) blur(5px);transform:scale(.91)}
.egg-discovery.tap-2 .egg-touch>img.egg-spirit-shadow{opacity:.43;filter:brightness(0) blur(3px);transform:scale(1)}
.egg-discovery.is-opening .egg-touch>img.egg-spirit-shadow{opacity:.56;filter:brightness(0) blur(1px);transform:scale(1.06)}
.birth-stage .fallback{background:#1b192b}.birth-stage .fallback .birth-cushion{position:absolute;inset:0;width:100%;height:100%;max-width:none;object-fit:cover;filter:none}.birth-stage .fallback img:not(.birth-cushion){position:relative;z-index:1;width:62%;max-width:270px;filter:drop-shadow(0 12px 20px #1b142b80)}
.birth-ritual{position:absolute;z-index:4;left:50%;top:44%;width:min(72vw,270px);aspect-ratio:1;transform:translate(-50%,-50%);display:grid;place-items:center;pointer-events:none;color:#f6df9f;animation:ritual-arrive 3s ease-out both}.birth-ritual svg{position:absolute;inset:0;width:100%;height:100%;fill:none;stroke:#c9a24a;stroke-width:2}.birth-ritual .ritual-halo{stroke-width:8;opacity:.42;filter:url(#ritual-glow)}.birth-ritual .ritual-ring{stroke-dasharray:6 10;animation:ritual-turn 3s ease-out both}.birth-ritual .ritual-cloud{stroke-linecap:round;opacity:.75}.birth-ritual span{font-family:'Noto Serif KR','Nanum Myeongjo',serif;font-size:38px;font-weight:700;letter-spacing:.1em;text-shadow:0 0 12px #eac16e,0 2px 7px #36284b}
@keyframes ritual-arrive{0%{opacity:0;transform:translate(-50%,-44%) scale(.76)}22%,68%{opacity:1;transform:translate(-50%,-50%) scale(1)}100%{opacity:0;transform:translate(-50%,-58%) scale(1.08)}}@keyframes ritual-turn{from{transform-origin:center;transform:rotate(-28deg)}to{transform-origin:center;transform:rotate(22deg)}}
@media(prefers-reduced-motion:reduce){.egg-touch>img.egg-spirit-shadow,.birth-ritual,.birth-ritual .ritual-ring{animation:none;transition:none}.birth-ritual{opacity:1}}
.egg-touch>.egg-motion{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;pointer-events:none}
.egg-discovery.tap-1 .egg-touch>img:first-child,.egg-discovery.tap-2 .egg-touch>img:first-child{animation:none;filter:none}
.egg-discovery.tap-1 .egg-touch,.egg-discovery.tap-2 .egg-touch{animation:none}
.egg-discovery.is-opening .egg-touch>.egg-motion{filter:none;transform:none}
@media(prefers-reduced-motion:reduce){.egg-touch>.egg-motion{display:none}}
.low-motion-app .egg-touch>.egg-motion{display:none}
