@import url('../styles.css');
.wh-header{position:sticky;top:0;z-index:20;border-bottom:1px solid #e3e9df;background:#fffdf8f2;backdrop-filter:blur(12px)}
.wh-header-inner{width:min(1040px,calc(100% - 48px));min-height:88px;margin:auto;display:flex;align-items:center;justify-content:space-between;gap:16px}
.wh-brand{display:flex;align-items:center;gap:10px;text-decoration:none;color:#244d40}
.wh-brand img{width:58px;height:58px;background:#e8efdf;border-radius:18px;object-fit:cover}
.wh-brand>span{display:grid;gap:3px}.wh-brand strong{font:900 1.3rem Nunito,sans-serif;letter-spacing:-.03em}.wh-brand b{color:#e88642}.wh-brand small{font-size:.75rem;font-weight:700;color:#789087}
.wh-header-note{font:900 2.5rem Nunito,sans-serif;color:#e9975b;transform:rotate(12deg)}
.wh-page{width:min(960px,calc(100% - 48px));margin:0 auto;padding:30px 0 35px}
.wh-hero{position:relative;display:grid;grid-template-columns:1.5fr 1fr;align-items:center;gap:24px;margin-bottom:24px;padding:0 30px}
.wh-eyebrow{font-size:.66rem;letter-spacing:.15em;font-weight:900;color:#c77639}
.wh-hero h1{font:900 clamp(2.4rem,4.5vw,3.65rem)/1.06 Nunito,sans-serif;letter-spacing:-.05em;margin:14px 0}
.wh-hero h1 em{font-style:normal;color:#e88948}
.wh-hero p{max-width:440px;color:#6d837a;font-size:.95rem;line-height:1.65;margin:0}
.wh-bird{display:block;width:min(100%,280px);height:auto;justify-self:center}
.wh-game{padding:25px 30px 17px;border:1px solid #e0e7d9;border-radius:28px;background:#fffef9;box-shadow:0 18px 50px #234c3710}
.wh-game-top{display:flex;align-items:center;justify-content:space-between;gap:18px}
.wh-score{display:flex;gap:30px}.wh-score>span{display:flex;align-items:center;gap:9px;color:var(--filipika-muted,#59485a);font-size:.58rem;letter-spacing:.07em;font-weight:800}.wh-score strong{font:900 1.65rem Nunito,sans-serif;letter-spacing:-.04em;color:#2e6852}.wh-score>span:first-child strong{color:#e88b46}
.wh-switch{display:flex;align-items:center;gap:9px;color:#577465;font-size:.74rem;font-weight:700;cursor:pointer;min-height:44px;position:relative}
.wh-switch input{position:absolute;opacity:0;width:38px;height:24px;margin:0;left:0}
.wh-switch-track{width:38px;height:23px;flex:none;border-radius:20px;background:#dbe2d6;transition:background .2s}
.wh-switch-track:after{content:"";display:block;width:17px;height:17px;margin:3px;border-radius:50%;background:#fff;box-shadow:0 1px 4px #284e3d22;transition:transform .2s}
.wh-switch input:checked+.wh-switch-track{background:#73996d}.wh-switch input:checked+.wh-switch-track:after{transform:translateX(15px)}
.wh-switch input:focus-visible+.wh-switch-track{outline:3px solid #e89a5b;outline-offset:4px}
.wh-status{margin:24px 0 0;text-align:center;min-height:100px}.wh-phase{font-size:.61rem;letter-spacing:.12em;color:#9aab90;font-weight:800}.wh-status h2{font:900 clamp(1.4rem,3vw,1.9rem)/1.18 Nunito,sans-serif;letter-spacing:-.035em;margin:9px 0 7px;color:#2a5142}.wh-status p{color:#7b8f82;margin:0;font-size:.8rem;line-height:1.5}
.wh-progress{display:flex;justify-content:center;align-items:center;gap:6px;min-height:18px;margin:1px 0 17px}.wh-progress i{width:7px;height:7px;border-radius:50%;background:#e3e9de}.wh-progress i.done{background:#77a77d}.wh-progress i.current{background:#eda269;transform:scale(1.2)}.wh-progress span{font-size:.7rem;font-weight:800;color:#7b8f82}
.wh-piano{padding:13px 13px 0;border:1px solid #c5d4bb;border-radius:19px;background:#8da47d;box-shadow:0 7px 0 #718664,0 12px 20px #53634720}
.wh-keyboard{--key-height:214px;position:relative;display:flex;gap:0;isolation:isolate}
.wh-keyboard-row{--white:calc(100% / var(--columns));position:relative;display:grid;grid-template-columns:repeat(var(--columns),minmax(0,1fr));flex:var(--columns) 1 0;min-width:0;height:var(--key-height)}
.wh-key{position:relative;display:flex;align-items:flex-end;justify-content:center;min-width:0;padding:0 0 20px;cursor:pointer;touch-action:manipulation;user-select:none;-webkit-tap-highlight-color:transparent;transition:background .12s,box-shadow .12s;outline-offset:3px}
.wh-key.white{height:100%;border:1px solid #c8cbbf;border-bottom:6px solid #d9d8c9;border-radius:0 0 10px 10px;background:linear-gradient(#fffef8,#f8f6ec);box-shadow:inset 0 -4px 4px #ddd9c325;color:var(--filipika-muted,#59485a);z-index:1}
.wh-key.black{position:absolute;top:0;left:calc(var(--boundary) * var(--white) - var(--white) * .31);width:calc(var(--white) * .62);height:62%;padding-bottom:15px;z-index:2;border:1px solid #29463c;border-bottom:6px solid #1f3c32;border-radius:0 0 8px 8px;background:linear-gradient(110deg,#527362,#365446);color:#ecf1e5;box-shadow:0 6px 8px #233e3a30}
.wh-key:hover:not(:disabled){filter:brightness(.97)}.wh-key:active:not(:disabled){border-bottom-width:3px;transform:translateY(2px)}
.wh-key .key-number{font:900 clamp(.9rem,2.2vw,1.25rem) Nunito,sans-serif;opacity:0;transition:opacity .15s}.show-numbers .wh-key .key-number{opacity:1}
.wh-key.is-demo{background:#f4bc73;border-color:#dfa05e;border-bottom-color:#c98a49;color:#6e441f;box-shadow:inset 0 0 0 2px #ffe5b4}
.wh-key.is-correct{background:#a6d7a6;border-color:#72aa76;border-bottom-color:#5e9465;color:#245c38;box-shadow:inset 0 0 0 2px #d5efc2}
.wh-key.is-wrong{background:#f2b4a4;border-color:#dc9887;border-bottom-color:#ca8372;color:#834839}
.wh-key:disabled{cursor:default;opacity:1}.wh-key:focus-visible{outline:3px solid #eb8e47;z-index:4}
.wh-piano-signature{display:flex;align-items:center;justify-content:center;gap:12px;height:34px;font:800 .68rem Nunito,sans-serif;letter-spacing:.12em;color:var(--filipika-plum,#310f2f)}.wh-piano-signature span{font-size:1rem;color:var(--filipika-plum,#310f2f)}
.wh-controls{display:flex;justify-content:center;margin:28px 0 13px;min-height:51px}.wh-start{min-width:210px;padding:13px 28px;border:0;border-radius:16px;background:#f58d46;box-shadow:0 7px 18px #e8924422;color:#fff;font:900 1.05rem Nunito,sans-serif;cursor:pointer;transition:transform .15s,background .15s}.wh-start:hover{background:#e87c37;transform:translateY(-1px)}.wh-start.secondary{min-width:160px;background:#eef2e8;color:#6c806c;box-shadow:none;font-size:.88rem}.wh-start:disabled{opacity:.6;cursor:wait}.wh-start:focus-visible,.wh-brand:focus-visible{outline:3px solid #e89a5b;outline-offset:4px}
.wh-help,.wh-error{text-align:center;font-size:.71rem;line-height:1.5;margin:0;color:#91a18d}.wh-error{color:#a35f40}.wh-error:empty{display:none}
.wh-steps{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:25px;padding:0 20px;margin:30px 0;list-style:none}.wh-steps li{display:flex;gap:11px;align-items:flex-start}.wh-steps b{flex:none;width:29px;height:29px;display:grid;place-items:center;border-radius:50%;background:#f7e5d2;color:#c3844b;font:900 .85rem Nunito,sans-serif}.wh-steps span{color:#8b9b89;font-size:.72rem;line-height:1.55}.wh-steps strong{display:block;color:#54755e;font-size:.82rem;margin-bottom:3px}
.wh-local-note{text-align:center;color:#96a38f;font-size:.72rem;line-height:1.6}.wh-footer{margin:0;padding:22px;border-top:1px solid #e5e9df;text-align:center;font-size:.72rem;color:#93a08c}
.wh-game[data-phase="over"] .wh-status h2{color:#ac6c4f}.wh-game[data-phase="success"] .wh-status h2{color:#579369}
@media(max-width:680px){.wh-header-inner{width:calc(100% - 32px);min-height:76px}.wh-page{width:calc(100% - 28px);padding-top:23px}.wh-hero{padding:0 8px;grid-template-columns:1.5fr 1fr;gap:0;margin-bottom:23px}.wh-hero h1{font-size:clamp(1.65rem,5.9vw,2.4rem);margin:10px 0}.wh-hero p{font-size:.76rem;line-height:1.5}.wh-eyebrow{font-size:.5rem;letter-spacing:.09em}.wh-bird{width:100%}.wh-game{padding:17px 14px 15px;border-radius:23px}.wh-game-top{gap:8px;flex-wrap:wrap}.wh-score{gap:17px}.wh-score>span{font-size:.53rem;gap:6px}.wh-score strong{font-size:1.4rem}.wh-switch{font-size:.66rem}.wh-status{margin-top:18px;min-height:104px}.wh-status h2{font-size:1.4rem}.wh-status p{font-size:.73rem}.wh-piano{padding:8px 8px 0;border-radius:14px}.wh-keyboard{--key-height:180px}.wh-key{padding-bottom:16px}.wh-key.black{padding-bottom:12px}.wh-steps{padding:0 4px;gap:12px}.wh-steps li{gap:7px}.wh-steps b{width:24px;height:24px}.wh-steps strong{font-size:.72rem}.wh-steps span{font-size:.64rem}.wh-brand img{width:48px;height:48px;border-radius:14px}.wh-brand strong{font-size:1.08rem}.wh-brand small{font-size:.66rem}}
@media(max-width:390px){.wh-header-inner{width:calc(100% - 24px)}.wh-header-note{display:none}.wh-page{width:calc(100% - 20px)}.wh-game{padding:15px 10px}.wh-game-top{justify-content:center;gap:0}.wh-score{width:100%;justify-content:center;gap:30px}.wh-switch{min-height:44px}.wh-hero{grid-template-columns:1.7fr 1fr}.wh-keyboard{--key-height:166px}.wh-status{margin-top:10px}.wh-steps{gap:14px;grid-template-columns:1fr}.wh-steps li{align-items:center}.wh-steps strong{display:inline;margin-right:7px}.wh-piano-signature{letter-spacing:.07em}}
@media(prefers-reduced-motion:reduce){*,*:before,*:after{transition:none!important;scroll-behavior:auto!important}}

.wh-options{display:flex;align-items:center;justify-content:flex-end;flex-wrap:wrap;gap:20px}
.wh-range{margin:0;padding:0;border:0;min-width:0}
.wh-range legend{padding:0;margin-bottom:4px;color:var(--filipika-muted,#59485a);font-size:.62rem;font-weight:800}
.wh-range-buttons{display:flex;padding:3px;border-radius:12px;background:#edf2e7}
.wh-range button{min-height:44px;padding:7px 12px;border:0;border-radius:9px;background:none;color:#70866b;font:800 .73rem 'DM Sans',sans-serif;cursor:pointer}
.wh-range button[aria-pressed="true"]{background:#fffef9;color:#2d674b;box-shadow:0 2px 6px #4d70451a}
.wh-range button:focus-visible{outline:3px solid #e89a5b;outline-offset:3px}
.wh-range button:disabled{cursor:wait;opacity:.6}
.wh-range-hint{margin:5px 0 0;text-align:right;font-size:.61rem;color:#91a18d}
@media(max-width:680px){.wh-game-top{justify-content:center}.wh-options{justify-content:center;gap:14px}.wh-range-hint{text-align:center;margin-top:8px}.wh-keyboard[data-key-count="20"]{flex-direction:column;gap:12px}.wh-keyboard[data-key-count="20"] .wh-keyboard-row{flex:none;width:100%}.wh-keyboard[data-key-count="20"] .wh-key.black{left:calc(var(--boundary) * var(--white) - var(--white) * .34);width:calc(var(--white) * .68)}}

/* Progress stays above the instrument, so neither row can slide underneath it. */
.wh-status {scroll-margin-top:112px;}
@media(max-width:680px) {
  .wh-status {min-height:80px;margin-top:10px;}
  .wh-status h2 {margin:6px 0;}
  .wh-progress {margin-bottom:10px;}
  .wh-keyboard[data-key-count="20"] {--key-height:142px;gap:9px;}
  .wh-controls {min-height:44px;margin:18px 0 10px;}
  .wh-range button {min-width:44px;}
}
/* Small live instructions use the same readable text token as the shared shell. */
.wh-phase,.wh-range-hint,.wh-status p,.wh-steps span {color:var(--filipika-muted,#59485a);}
.wh-score>span:first-child strong {color:var(--filipika-purple-dark,#64168e);}
