/* Brand header and unified home composition. */
.app-header{height:76px;background:#ed782b;color:#fff8ea;border:0;position:relative;overflow:hidden}
.app-header:after{content:'';position:absolute;width:160px;height:70px;border:1px solid #fff3;border-radius:50%;right:-62px;top:-35px;pointer-events:none;box-shadow:0 0 0 10px #fff1,0 0 0 20px #fff1}
.brand-mark,.brand-lockup small{color:#fff8ea}.brand-lockup{font-size:17px;letter-spacing:3px}.brand-lockup small{font-size:9px;letter-spacing:1px;opacity:.87}.brand-mark{width:76px}.app-header .icon-button{position:relative;z-index:1}
.home-page{background-size:100% 100%;padding-top:23px;min-height:calc(100dvh - 76px)}
.home-page .title-row{min-height:122px}.home-page .page-title{font-size:27px}.home-page .pond{height:345px}
.home-page .pet-caption{top:10px;left:50%;transform:translateX(-50%);width:max-content;text-align:center;color:#4e5c48;font-size:13px;letter-spacing:3px;border-bottom:1px solid #737b5c66;padding:6px 18px 9px}
.home-page .pet-caption:before,.home-page .pet-caption:after{content:'';position:absolute;width:3px;height:3px;border-radius:50%;background:#ed782b;bottom:-2px}.home-page .pet-caption:before{left:0}.home-page .pet-caption:after{right:0}
.home-page .pond .pet-wrap.stage-0{top:43%;width:148px;height:135px}.home-page .pond-ripple{bottom:126px;opacity:1;color:#a2a77c}.home-page .pet-name{bottom:96px;font-size:18px}.pet-name .tiny{display:block;font-family:var(--sans);font-size:10px;letter-spacing:2px;margin-top:4px}
.pond-action{width:116px;height:112px;bottom:8px;display:grid;grid-template-columns:32px 1fr;grid-template-rows:75px 27px;column-gap:0;align-items:center}
.pond-action svg{grid-column:1/3;grid-row:1;width:100%;height:83px}.pond-action span{grid-row:2;grid-column:1/3;font-size:14px;letter-spacing:3px;background:none;border:0;padding:0;text-align:center;color:#394735}
.pond-action span:before{content:'';display:inline-block;width:4px;height:4px;background:#ed782b;transform:rotate(45deg);vertical-align:middle;margin-right:9px}.pond-action small{display:none}.sing-action{left:24px}.feed-action{right:24px}
.home-page .info-line{border:0;background:none;padding:16px 0 4px;font-size:12px}.home-page .growth-net{height:87px;background:none}.home-page .growth-caption{margin-bottom:10px;border-bottom:1px solid #929c7355;padding-bottom:14px}.home-page .footnote{color:#69755b;font-size:11px;margin-bottom:17px}
.home-page .song-teaser{background:none;border:0;border-top:1px solid #88967555;margin-top:5px}.home-page .section-head,.home-page .milestones,.home-page .accessories{position:relative}.home-page .section-head{margin-top:17px}.home-page .accessories button{border-color:#87906d88}
.home-page:after{content:'';display:block;height:55px;background:repeating-linear-gradient(65deg,transparent 0 25px,#a0a78733 26px,transparent 27px 48px);mask-image:linear-gradient(transparent,#000)}
/* Library transforms live on character wrappers, preserving composited eye-expression layers. */
[data-motion]{transform-origin:50% 85%}.actor svg{width:100%;height:100%;overflow:hidden}
[data-motion="waiting"]>svg{animation:actor-wait 3.8s ease-in-out infinite}
[data-motion="singing"]>svg{animation:actor-sing .65s ease-in-out infinite alternate}
[data-motion="shake"]>svg{animation:actor-shake .24s ease-in-out 4}
[data-motion="happy"]>svg{animation:actor-happy .52s ease-in-out 3}
[data-motion="feeding"]>svg{animation:actor-feed .6s ease-in-out 3}
[data-motion="surface"]>svg{animation:actor-surface .7s cubic-bezier(.2,.8,.2,1) both}
@keyframes actor-surface{0%{transform:translateY(45px);opacity:.2}65%{transform:translateY(-10px);opacity:1}100%{transform:none;opacity:1}}
.happy-eyes{display:none}[data-motion="happy"] .happy-eyes,[data-motion="feeding"] .happy-eyes{display:block}
.character-emotion{position:absolute;top:3%;right:10%;width:20px;height:16px;opacity:0;border-top:3px solid #ed782b;border-radius:50%;transform:rotate(-25deg)}
[data-motion="happy"] .character-emotion{opacity:1;animation:actor-happy .52s 3}[data-motion="shake"] .character-emotion{opacity:1;border-color:#63735a;transform:rotate(15deg)}
.fed-happy .pet-name:after{content:'吃饱啦，再一起唱一曲';display:block;color:#61774f;font-size:11px;letter-spacing:1px;margin-top:3px}
@keyframes actor-wait{50%{transform:translateY(-2px) rotate(1deg)}}
@keyframes actor-sing{to{transform:translateY(-5px) rotate(-2deg) scaleY(1.025)}}
@keyframes actor-shake{25%{transform:rotate(-7deg)}75%{transform:rotate(7deg)}}
@keyframes actor-happy{50%{transform:translateY(-12px) rotate(4deg) scaleY(1.04)}}
@keyframes actor-feed{50%{transform:translateY(3px) rotate(-4deg) scale(1.04)}}
/* Comic opening: lake -> three arrivals -> dive below -> crab greeting. */
.lake-intro{min-height:calc(100dvh - 154px);background:#edf0df;position:relative;overflow:hidden;padding-bottom:28px}
.intro-toolbar{display:flex;justify-content:space-between;position:relative;z-index:4;padding:20px 23px;font-size:12px;letter-spacing:2px}.intro-toolbar button{color:#64745b;font-size:12px}
.intro-camera{height:490px;position:relative;overflow:hidden;isolation:isolate}.intro-paper{position:absolute;inset:-30px;background:url('assets/ink-water-v2.png') center/cover;transition:transform 2s,filter 2s}.intro-location{position:absolute;top:13%;width:100%;text-align:center;font-family:var(--serif);font-size:43px;letter-spacing:12px;color:#415b47;transition:opacity 1s}.intro-location small{display:block;font-family:var(--sans);font-size:11px;letter-spacing:3px;margin-top:17px}
.intro-bird{position:absolute;width:58%;height:280px;bottom:85px;left:13%;opacity:0}.intro-bird svg{width:100%;height:100%}.intro-bird.fly-in{animation:intro-fly 1.1s ease-out both}
.intro-dialog{position:absolute;bottom:10px;left:8%;right:8%;padding:18px 20px;background:#f8f4e9e8;border:1px solid #9ba58b;border-radius:45% 30% 35% 18% / 12% 25% 15% 20%;font-family:var(--serif);font-size:17px;line-height:1.9;z-index:5;box-shadow:3px 4px 0 #76866b15}
.intro-crab{position:absolute;width:53%;height:190px;bottom:110px;left:24%;transform:translateY(320px);transition:transform 1.1s cubic-bezier(.2,.8,.2,1)}.intro-crab>svg{width:100%;height:100%}
.intro-camera:not([data-panel="0"]) .intro-location{opacity:0}.intro-camera[data-panel="4"] .intro-paper{transform:translateY(-14%) scale(1.35);filter:hue-rotate(12deg)}.intro-camera[data-panel="4"] .intro-bird{opacity:0;animation:none}.intro-camera[data-panel="4"] .intro-crab{transform:translateY(0)}.intro-camera[data-panel="4"] .lake-water{background:#92b1a144;height:100%;top:0}
.intro-pages{display:flex;gap:9px;justify-content:center;margin:23px 0}.intro-pages i{width:5px;height:5px;border-radius:50%;background:#b4bda6}.intro-pages i.on{background:#ed782b;box-shadow:0 0 0 3px #ed782b22}.intro-next{display:block;margin:auto;font-family:var(--serif);letter-spacing:3px;font-size:15px;border-bottom:1px solid #8a977b;padding:7px 10px}.intro-next span{margin-left:30px;color:#ed782b}
@keyframes intro-fly{0%{opacity:0;transform:translate(180px,-180px) rotate(-18deg)}65%{opacity:1;transform:translate(-8px,0) rotate(4deg)}100%{opacity:1;transform:none}}
/* Voice game: lyrics belong to the speaker, no separate subtitle panel. */
.voice-game{padding:0 0 20px;background:#e9edde}.voice-game .practice-top{padding:10px 22px;margin:0;border-bottom:1px solid #9da98a55}.voice-game .practice-top button{font-size:12px;min-height:35px}.voice-game .practice-top strong{font-family:var(--serif);font-size:16px;color:#4c624a}
.game-status{text-align:center;padding:14px 18px 10px}.game-status .eyebrow{font-size:10px;margin:0;letter-spacing:3px}.voice-game h2{font-size:21px;margin:5px 0 0;letter-spacing:2px}.voice-game .practice-tag{font-size:10px;margin-top:3px}
.voice-game .practice-scene{height:310px;margin:0;isolation:isolate;background:#e6eddf;overflow:hidden}.voice-game .pond-landscape{opacity:.55;object-position:center 65%}.lake-water{position:absolute;left:0;right:0;bottom:0;height:62%;pointer-events:none;background:linear-gradient(transparent,#7897892b)}.lake-water>svg{width:100%;height:100%}
.voice-game .bird{width:34%;height:158px;left:9%;bottom:44px;z-index:3;animation:none}.voice-game .crab{width:33%;height:113px;right:8%;bottom:35px;z-index:3;transition:transform .65s,opacity .65s;animation:none;clip-path:inset(-80% -60% 0)}
.voice-game .crab[data-motion="submerge"]{transform:translateY(42px);opacity:.32;clip-path:inset(0 0 43%)}
.bird-perch{position:absolute;width:110px;height:45px;left:10%;bottom:25px;z-index:2}.bird-perch svg{width:100%;height:100%}
.voice-game .speaker-ripple{bottom:24px;height:38px;width:44%;z-index:4;opacity:.45;color:#617d70;pointer-events:none}.voice-game .speaker-ripple.left{left:2%}.voice-game .speaker-ripple.right{right:2%}.voice-game .speaker-ripple.active{opacity:1;color:#ed782b;filter:drop-shadow(0 1px 0 #fff9)}.voice-game .ripple-svg{stroke-width:1.8}
.voice-game .speaker-ripple.active ellipse{animation:ripple 1.3s infinite}.voice-game .user-voicing .speaker-ripple.right{transform:scale(calc(1 + var(--voice-energy,.2)*.2));stroke-width:2}
.water-splash{position:absolute;left:50%;bottom:4px;width:1px;height:1px;pointer-events:none;z-index:5}.water-splash i{position:absolute;width:4px;height:9px;opacity:0;border-radius:80% 20% 70% 30%;background:#699b8e;--angle:calc((var(--drop) - 3)*23deg);transform:rotate(var(--angle))}
.splash-now .water-splash i,.intro-camera[data-panel="4"] .water-splash i{animation:water-drop .85s ease-out both;animation-delay:calc(var(--drop)*.025s)}
@keyframes water-drop{0%{opacity:0;transform:rotate(var(--angle)) translateY(0)}25%{opacity:.9}100%{opacity:0;transform:rotate(var(--angle)) translateY(-65px) scale(.4)}}
.lyric-bubble{position:absolute;top:13px;width:44%;z-index:6;padding:12px 12px 10px;background:#f8f4e9db;border:1px solid #849477;border-radius:29% 17% 23% 14% / 14% 23% 12% 17%;transition:opacity .3s,transform .3s,background .3s;box-shadow:2px 3px 0 #73866812;opacity:.6}
.bubble-lead{left:3%}.bubble-response{right:3%;top:57px}.lyric-bubble:after{content:'';position:absolute;bottom:-9px;width:14px;height:15px;background:#f8f4e9;transform:skew(-20deg) rotate(40deg);border-bottom:1px solid #849477;border-right:1px solid #849477;left:36%}.bubble-response:after{left:60%}
.lyric-bubble small{display:block;font-size:10px;letter-spacing:1px;color:#677b5c;margin-bottom:5px}.lyric-bubble p{font-family:var(--serif);font-size:19px;line-height:1.65;letter-spacing:1px;word-break:break-all}.bubble-meter{display:block;height:2px;background:#d8dfcd;margin-top:9px}.bubble-meter i{height:100%;display:block;width:0;background:#ed782b}
[data-phase="lead"] .bubble-lead,[data-phase="example"] .bubble-response,[data-phase="response"] .bubble-response{opacity:1;border-color:#d77535;background:#fff8e9;transform:translateY(-3px)}
[data-phase="lead"] .bubble-lead .bubble-meter i,[data-phase="example"] .bubble-response .bubble-meter i,[data-phase="response"] .bubble-response .bubble-meter i{width:var(--phrase-progress,0%)}
[data-phase="response"] .bubble-response small{color:#b65a23}[data-phase="response"] .bubble-response p{color:#b65a23}
.turn-cue{position:absolute;bottom:1px;left:0;right:0;text-align:center;font-size:11px;letter-spacing:1px;color:#4d6851;z-index:8;background:#e5eddad9;padding:5px}
.game-console{position:relative;padding:0 24px 15px;background:#e1e8d6;border-top:1px solid #9bab8855}.voice-game .round-dots{margin:18px 0 9px;gap:15px}.voice-game .round-dots i{width:23px;height:23px;border:1px solid #899a76;background:transparent;border-radius:50%;display:grid;place-items:center;font-style:normal}.round-dots span{font-size:10px;color:#69815a}.voice-game .round-dots i.done{border-color:#ed782b;background:#ed782b}.round-dots i.done span{color:#fff}
.voice-game .phase-caption{font-size:12px;min-height:26px;line-height:1.7}.voice-game .progress-track{margin:10px 0 12px}.voice-game .mic-control{margin:0;gap:5px}.voice-game .mic-button{width:56px;height:56px;box-shadow:0 0 0 5px #ed782b18}.voice-game .mic-meter{margin-top:6px}.voice-game .meter-caption{font-size:11px}.voice-game .practice-actions{margin-top:8px;gap:23px}.voice-game .practice-actions .text-button{font-size:11px;min-height:32px}.game-options{padding:0 24px 14px}.game-options>.text-button{font-size:11px;margin-right:17px}
.result-partner{position:absolute;left:0;bottom:10px;width:40%;height:150px}.result-partner svg{width:100%;height:100%}.result .result-hero .pet-wrap{left:68%;width:45%}
@media(max-height:850px){.voice-game .game-status{padding-top:8px;padding-bottom:6px}.voice-game .practice-scene{height:280px}.voice-game .game-console{padding-bottom:5px}.voice-game .round-dots{margin-top:11px}.voice-game .mic-button{width:49px;height:49px}.voice-game .practice-actions{margin-top:3px}.voice-game .mic-control{gap:3px}}
@media(max-width:380px){.sing-action{left:16px}.feed-action{right:16px}.pond-action{width:103px}.voice-game .practice-scene{height:285px}.lyric-bubble{padding:10px}.lyric-bubble p{font-size:17px}.voice-game .bird{height:140px}.voice-game .crab{height:100px}.intro-camera{height:425px}.home-page .pond{height:325px}}
@media(prefers-reduced-motion:reduce){.intro-bird.fly-in{opacity:1}.intro-crab{transition:none}[data-motion]>svg{animation:none!important}.water-splash i{animation:none!important}}
