
:root{--ink:#243c36;--muted:#77817a;--paper:#f6f5ef;--green:#315c49;--line:#dedfd5}*{box-sizing:border-box}body{display:block;background:var(--paper);color:var(--ink);font-family:Inter,"Microsoft YaHei",sans-serif;margin:0}body>header{height:86px;border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;padding:0 5%;font-size:12px;letter-spacing:1px}a{color:inherit;text-decoration:none}header>a:first-child{font-size:24px;font-weight:700}header>a span{font-size:16px;margin-left:12px}main{max-width:1320px;margin:auto;padding:48px 40px}h1{font-size:36px;margin:12px 0}p{color:var(--muted);line-height:1.8}.intro{display:flex;justify-content:space-between;align-items:center;margin-bottom:32px}.eyebrow{font-size:11px;letter-spacing:2px;color:var(--muted);font-weight:600}.pill{padding:10px 16px;border:1px solid var(--line);border-radius:24px;font-size:12px;white-space:nowrap}.workspace{display:grid;grid-template-columns:minmax(0,1fr) 320px;gap:24px}.stage,.panel{border:1px solid var(--line);border-radius:20px;background:#fffef9;padding:28px}.stage-top,.stage-bottom{display:flex;justify-content:space-between;font-size:12px;color:var(--muted)}.stage-top span:first-child{color:var(--green)}.chord-pair{display:grid;grid-template-columns:1.35fr 1fr;align-items:center;text-align:center;margin:28px 0 12px}.current{border-right:1px solid var(--line)}.chord-pair h2{font-size:64px;margin:6px 0 0;line-height:1.2;font-family:Georgia,serif}.chord-pair svg{width:190px;max-width:100%;height:220px}.next h2{font-size:36px}.next svg{width:130px;height:160px;opacity:.75}.next p{font-size:11px;margin:0}.beats{display:flex;justify-content:center;gap:15px;margin:16px 0 24px}.beats span{display:grid;place-items:center;width:44px;height:44px;border:1px solid var(--line);border-radius:50%;color:var(--muted);transition:background .08s}.beats span.on{background:var(--green);color:white;border-color:var(--green);box-shadow:0 0 0 5px #315c4910}.progress{height:4px;background:#eceee6;border-radius:4px;margin-bottom:12px;overflow:hidden}.progress div{background:#87a384;height:100%;width:0}.actions{display:flex;justify-content:center;gap:12px;margin-top:28px}button,select{font:inherit;cursor:pointer;border:1px solid var(--line);border-radius:9px;padding:12px 18px;background:transparent;color:var(--ink)}button.primary{background:var(--green);color:white;min-width:200px;border-color:var(--green)}button:hover{filter:brightness(.95)}button:focus-visible,input:focus-visible,select:focus-visible,a:focus-visible{outline:3px solid #c6984a;outline-offset:4px}.shortcut{text-align:center;font-size:11px;margin:14px 0 0}#error{color:#a34130;text-align:center;font-size:12px;margin:8px 0}aside{position:static;width:auto;background:none;border:0;padding:0;display:block;height:auto}.panel label{display:flex;justify-content:space-between;align-items:center;font-size:13px;margin:26px 0 12px}.panel strong{font-size:28px;font-weight:500}.panel small{font-size:10px;color:var(--muted)}.tempo{display:flex;align-items:center;gap:12px}.tempo button{padding:5px 10px}.tempo input{min-width:0;width:100%;accent-color:var(--green)}.range-label{display:flex;justify-content:space-between;font-size:10px;color:var(--muted);margin-top:8px}select{width:100%;padding:12px;font-size:12px;background:white}.panel label.check{justify-content:flex-start;gap:8px;font-size:12px;margin:20px 0 0}.check input{accent-color:var(--green)}.note{padding:24px 12px}.note span{font-size:13px}.note p{font-size:12px;margin-bottom:0}.library{margin-top:44px}.library-heading{display:flex;align-items:center;justify-content:space-between}.library h2{font-size:23px;margin:8px 0}.library-heading>span{font-size:12px;color:var(--green)}.library>p{font-size:12px}.cards{display:grid;grid-template-columns:repeat(7,1fr);gap:12px;margin:20px 0}.chord-card{position:relative;min-width:0;padding:18px 6px 10px;background:#fffef9;border-radius:12px;border:1px solid var(--line);opacity:.5}.chord-card[aria-pressed=true]{opacity:1;border-color:#87a384;background:#f0f4ec}.chord-card strong{font-family:Georgia,serif;font-size:22px}.chord-card svg{width:100%;display:block;margin-top:10px}.chord-card .selected{position:absolute;right:8px;top:8px;font-size:10px;color:var(--green)}.legend{display:flex;flex-wrap:wrap;gap:12px 25px;font-size:11px;color:var(--muted);padding:16px 0;border-top:1px solid var(--line)}.footnote{font-size:11px!important}footer{text-align:center;padding:12px 20px 32px;font-size:11px;color:var(--muted);margin:0} @media(max-width:1000px){.cards{grid-template-columns:repeat(4,1fr)}.intro{display:block}.pill{display:inline-block;margin-top:12px}.workspace{grid-template-columns:minmax(0,1fr) 280px}main{padding:30px 24px}}@media(max-width:720px){body>header{height:68px;padding:0 20px}header>span{display:none}main{padding:28px 16px}.workspace{grid-template-columns:1fr}.stage{padding:22px 16px}h1{font-size:27px}.intro p{font-size:13px}.chord-pair h2{font-size:52px}.next h2{font-size:32px}.chord-pair svg{width:160px}.next svg{width:115px}.cards{gap:8px}.chord-card strong{font-size:18px}.actions button{padding:12px}.actions button.primary{min-width:160px}.shortcut{font-size:10px}.stage-top{font-size:11px}}



.mic-panel{margin-top:24px;display:grid;grid-template-columns:1fr auto;gap:16px;align-items:center}.mic-panel h2{font-size:22px;margin:10px 0}.mic-panel p{font-size:12px;margin:8px 0}.mic-feedback{padding:18px;border-radius:12px;background:#f0f2eb;grid-column:1/-1}.mic-feedback strong{font-size:22px}.mic-panel[data-state=match] .mic-feedback{background:#e2efdf;color:#285231}.mic-panel[data-state=different] .mic-feedback{background:#fbefda;color:#805621}.mic-meter{display:flex;gap:14px;align-items:center;font-size:12px}.mic-meter meter{width:160px;height:14px}.mic-help{grid-column:1/-1}@media(max-width:720px){.mic-panel{grid-template-columns:1fr}.mic-panel>button{justify-self:start}}

.chord-feedback{min-height:30px;display:inline-block;max-width:95%;padding:6px 10px;margin:0 0 12px;border-radius:8px;background:#eceee7;color:#65716a;font-size:12px}.chord-feedback[data-state=match],.card-feedback[data-state=match]{background:#d9edd7;color:#215732}.chord-feedback[data-state=different],.card-feedback[data-state=different]{background:#fae7d9;color:#8b4523}.card-feedback{display:block;min-height:22px;font:10px sans-serif;border-radius:4px;margin:10px 0 6px;padding:3px}.mic-controls{grid-column:1/-1;display:grid;gap:10px;grid-template-columns:1fr 1fr}.mic-controls label,.mic-controls select,.mic-controls input,.mic-controls small{grid-column:1/-1}.mic-controls label{display:flex;justify-content:space-between;font-size:12px}.mic-controls small{font-size:11px;color:var(--muted)}.mic-controls input{width:100%;accent-color:var(--green)}.mic-meter{grid-column:1/-1;flex-wrap:wrap}.mic-meter meter{flex:1;min-width:100px}.statistics{margin-top:24px}.statistics p{font-size:12px}.statistics h3{font-size:16px;margin-top:30px}.statistics label{font-size:12px}.stats-legend{display:flex;flex-wrap:wrap;gap:18px;font-size:12px}.stats-legend span:first-child{color:#315c49}.stats-legend span:nth-child(2){color:#b86437}.bar-chart{display:grid;grid-template-columns:repeat(7,minmax(64px,1fr));overflow-x:auto;gap:16px;padding:20px 0}.bar-group{text-align:center;font-size:12px;min-width:100px}.bar-pair{height:148px;display:flex;justify-content:center;align-items:end;gap:7px;border-bottom:1px solid var(--line);margin-bottom:10px}.bar-column{width:26px;display:flex;flex-direction:column;align-items:center;gap:5px}.bar-column b{font-size:11px;font-weight:400}.stat-bar{width:24px;border-radius:4px 4px 0 0}.stat-bar.correct{background:#47725a}.stat-bar.wrong{background:#bd724b}.bar-group small{display:block;color:var(--muted);margin:6px 0}.transition-bars{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:20px;max-height:540px;overflow-y:auto;padding:12px 4px}.transition-bars>div{text-align:center}.transition-bars button{font-size:11px;padding:7px 12px}.empty-stats{padding:25px;background:#f3f3eb;border-radius:10px}.bar-chart .bar-group{min-width:64px}@media(max-width:720px){.statistics{padding:20px 14px}.statistics .library-heading{flex-wrap:wrap;gap:10px}.bar-chart{grid-template-columns:repeat(7,72px)}.mic-panel .mic-controls label{margin:0}}
.bar-group>strong{font-size:13px;font-weight:600}.bar-column b{font-size:11px}.mic-panel[data-state=off] .mic-feedback{background:#f0f2eb}

main{padding-top:24px;padding-bottom:24px}

.stage-top{justify-content:space-between}
.actions{flex-wrap:wrap;gap:10px}
.actions button{padding:12px 14px;font-size:13px}
.actions button.primary{min-width:120px}
#open-mic-settings{width:100%;margin-top:16px;background:#fffef9}
#mic-settings{width:min(600px,calc(100% - 32px));max-height:calc(100dvh - 48px);padding:0;border:1px solid var(--line);border-radius:20px;color:var(--ink);background:#fffef9}
#mic-settings::backdrop{background:rgb(24 40 34 / 40%)}
#mic-settings .mic-panel{margin:0;border:0;grid-template-columns:1fr}
.mic-settings-heading{display:flex;justify-content:space-between;align-items:center;gap:16px}
#close-mic-settings{font-size:24px;padding:4px 12px}
body:has(#mic-settings[open]){overflow:hidden}

.tempo-heading{display:flex;justify-content:space-between;align-items:center;font-size:13px;margin:26px 0 12px}.tempo-heading span{font-size:11px;color:var(--muted)}.tempo-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;background:#eeefe7;padding:5px;border-radius:12px}.tempo-options button{padding:10px 4px;font-size:14px;border-color:transparent}.tempo-options button[aria-pressed="true"]{background:var(--green);color:#fff;border-color:var(--green)}

.stage-volume{border-top:1px solid var(--line);margin-top:22px;padding-top:16px;color:var(--muted);font-size:11px}
.volume-heading,.volume-footer{display:flex;justify-content:space-between;gap:12px;align-items:center}.volume-heading{color:var(--ink);font-size:12px}.volume-footer{margin-top:8px;font-size:10px;flex-wrap:wrap}
.stage-volume meter{display:block;width:100%;height:14px;margin-top:10px;appearance:none;border:0;border-radius:7px;background:#eceee6}
.stage-volume meter::-webkit-meter-bar{background:#eceee6;border:0;border-radius:7px}.stage-volume meter::-webkit-meter-optimum-value{background:var(--green);border-radius:7px;transition:width .1s}.stage-volume meter::-moz-meter-bar{background:var(--green);border-radius:7px}
.stage-volume[data-state=quiet] meter::-webkit-meter-optimum-value{background:#b69a63}.stage-volume[data-state=loud] meter::-webkit-meter-optimum-value{background:#b44f36}.stage-volume[data-state=loud] #stage-mic-status{color:#b44f36}.stage-volume[data-state=ready] #stage-mic-status{color:var(--green)}

.stage-top{align-items:center;gap:16px}.stage-top .stage-tools button{display:inline-flex;align-items:center;justify-content:center;width:104px;height:40px;font-size:12px;line-height:1;padding:0 10px;white-space:nowrap}
.stage-recognition{text-align:center;margin:14px auto 0;padding:10px 16px;border-radius:10px;background:#f0f2eb;color:var(--muted);font-size:14px;min-height:40px;width:fit-content;max-width:100%}
.stage-recognition[data-state=match]{background:#d9edd7;color:#215732}.stage-recognition[data-state=different]{background:#fae7d9;color:#8b4523}
#stage-dialog{inset:0;margin:0;width:100%;height:100%;max-width:none;max-height:none;padding:0;border:0;background:var(--paper);color:var(--ink);overflow:auto}
#stage-dialog .stage{min-height:100dvh;border:0;border-radius:0;width:100%;padding:24px clamp(16px,5vw,80px);display:flex;flex-direction:column}
#stage-dialog .chord-pair{flex:1;grid-template-columns:1fr 1fr;margin-top:16px}
#stage-dialog .current h2{font-size:clamp(64px,10vh,120px)}#stage-dialog .next h2{font-size:clamp(44px,7vh,88px)}
#stage-dialog .current svg{width:auto;max-width:100%;height:clamp(220px,40vh,500px)}#stage-dialog .next svg{width:auto;max-width:100%;height:clamp(180px,32vh,400px)}
#stage-dialog .actions{margin-top:18px}body:has(#stage-dialog[open]){overflow:hidden}

.bar-chart{grid-template-columns:repeat(18,minmax(72px,1fr))}

.selection-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap;font-size:12px}.selection-actions button{padding:8px 12px}.library>.library-heading{flex-wrap:wrap;gap:12px}

.bar-chart{grid-template-columns:repeat(30,minmax(72px,1fr))}.combo-controls{display:flex;gap:10px;flex-wrap:wrap;align-items:center;margin-top:16px}.combo-controls input,.combo-controls select{width:220px;max-width:100%;padding:12px;border:1px solid var(--line);border-radius:9px;font:inherit;background:white;color:var(--ink)}#combo-status{width:100%;font-size:12px;color:var(--muted)}

.challenge-panel{margin-top:16px;padding:12px;border:1px solid var(--line);border-radius:12px;display:flex;align-items:center;flex-wrap:wrap;gap:12px;font-size:13px}.challenge-panel progress{width:100%;height:6px;accent-color:var(--green)}.challenge-panel p{width:100%;font-size:12px;margin:0}.challenge-panel p:empty{display:none}
.games{margin-top:24px}.game-links{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px}.game-links a{display:flex;flex-direction:column;justify-content:space-between;min-height:180px;gap:24px;padding:28px;border:1px solid var(--line);border-radius:14px;color:var(--ink);text-decoration:none;background:var(--bg)}.game-links a:hover{border-color:var(--green)}.game-links span,.games>p{font-size:13px;color:var(--muted)}@media(max-width:650px){.game-links{grid-template-columns:1fr}}

.game-links a strong{display:flex;align-items:center;gap:8px;font-size:24px;font-weight:600}.game-links .game-arrow{margin-left:auto;font-size:24px;color:var(--green)}.game-links a:hover{box-shadow:0 6px 20px #00000012}.game-links a>span{line-height:1.7}

.workspace #current-diagram svg{width:250px;max-width:100%;height:auto}

.workspace{grid-template-columns:minmax(0,1fr)}.stage-tools{display:flex;align-items:center;gap:10px}.stage-top{align-items:center}#rhythm-settings{width:min(420px,calc(100vw - 32px));max-height:90dvh;overflow:auto;padding:0;border:1px solid var(--line);border-radius:20px}#rhythm-settings .panel{border:0}#rhythm-settings::backdrop{background:rgba(0,0,0,.5)}.rhythm-heading{display:flex;align-items:center;justify-content:space-between;gap:16px}.rhythm-heading h2{font-size:20px;margin:0}

.practice-sound{display:flex;justify-content:center;margin-top:16px}.practice-sound .check{display:flex;align-items:center;gap:8px;font-size:13px;cursor:pointer}
