/* Styles shared by the audio tools and apps. Colors come from the site's variables, so dark mode follows. */
.ga-wave{display:block;width:100%;height:120px;border:1px solid var(--border);border-radius:10px;background:var(--bg);margin-top:14px}
.ga-bar{display:flex;flex-wrap:wrap;align-items:center;gap:8px 10px;margin-top:12px}
.ga-bar .spacer{flex:1}
.ga-time{font-variant-numeric:tabular-nums;font-weight:600;min-width:112px}
.ga-icon{font:inherit;display:inline-grid;place-items:center;width:40px;height:40px;border-radius:999px;border:1px solid var(--border);background:var(--surface);color:var(--text);cursor:pointer;padding:0}
.ga-icon:hover{border-color:var(--accent);color:var(--accent)}
.ga-icon.main{background:var(--btn);color:#fff;border-color:transparent;width:48px;height:48px}
.ga-icon.main:hover{background:var(--btn-hover);color:#fff}
.ga-icon.rec{background:#dc2626;color:#fff;border-color:transparent}
.ga-icon.rec:hover{background:#b91c1c;color:#fff}
.ga-icon:disabled{opacity:.45;cursor:not-allowed}
.ga-icon svg{width:20px;height:20px;fill:currentColor}
.ga-panel{border:1px solid var(--border);border-radius:10px;background:var(--bg);padding:14px;margin-top:14px}
.ga-panel>h3:first-child,.ga-panel>.h3:first-child{margin-top:0}
.ga-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:12px 16px;margin-top:12px}
.ga-slider{display:flex;flex-direction:column;gap:2px}
.ga-slider>span{display:flex;justify-content:space-between;font-size:.88rem;font-weight:600;color:var(--muted)}
.ga-slider output{color:var(--text);font-variant-numeric:tabular-nums}
.ga-result{margin-top:16px}
.ga-result-row{align-items:flex-end}
.ga-result-row .field{flex:0 1 190px}
.ga-meter{height:10px;border-radius:999px;background:var(--border);overflow:hidden;margin-top:10px}
.ga-meter i{display:block;height:100%;width:0;background:var(--ok);border-radius:999px;transition:width .06s linear}
.ga-meter i.hot{background:var(--err)}
.ga-chips{display:flex;flex-wrap:wrap;gap:6px;margin-top:10px}
.ga-chips button{font:inherit;font-size:.88rem;font-weight:600;padding:6px 12px;border-radius:999px;border:1px solid var(--border);background:var(--surface);color:var(--text);cursor:pointer}
.ga-chips button:hover{border-color:var(--accent);color:var(--accent)}
.ga-chips button[aria-pressed=true]{background:var(--btn);border-color:transparent;color:#fff}
.ga-big{font-size:clamp(3rem,14vw,6rem);font-weight:800;line-height:1;font-variant-numeric:tabular-nums;text-align:center}
.ga-big small{font-size:.4em;font-weight:700;color:var(--muted)}
.ga-center{text-align:center}
.ga-hide{display:none!important}

/* Tuner */
.tn-dial{position:relative;height:74px;margin:14px auto 0;max-width:560px}
.tn-scale{position:absolute;left:0;right:0;top:30px;height:14px;border-radius:999px;background:linear-gradient(90deg,var(--err),#f59e0b 30%,var(--ok) 46%,var(--ok) 54%,#f59e0b 70%,var(--err))}
.tn-needle{position:absolute;top:18px;left:50%;width:4px;height:38px;margin-left:-2px;border-radius:2px;background:var(--text);transition:left .08s linear}
.tn-labels{display:flex;justify-content:space-between;font-size:.8rem;color:var(--muted);max-width:560px;margin:0 auto}
.tn-note.ok{color:var(--ok)}
.tn-strings{display:flex;flex-wrap:wrap;justify-content:center;gap:8px;margin-top:14px}
.tn-strings button{font:inherit;font-weight:700;min-width:56px;padding:8px 10px;border-radius:10px;border:1px solid var(--border);background:var(--surface);color:var(--text);cursor:pointer}
.tn-strings button small{display:block;font-weight:500;font-size:.72rem;color:var(--muted)}
.tn-strings button.near{border-color:var(--accent);background:var(--accent-soft)}
.tn-strings button.tuned{border-color:var(--ok);color:var(--ok)}

/* Metronome */
.mt-dots{display:flex;flex-wrap:wrap;justify-content:center;gap:10px;margin:16px 0 6px}
.mt-dots i{width:22px;height:22px;border-radius:50%;border:2px solid var(--border);background:var(--bg)}
.mt-dots i.acc{border-color:var(--accent)}
.mt-dots i.on{background:var(--accent);border-color:var(--accent);transform:scale(1.15)}
.mt-dots i.acc.on{background:var(--ok);border-color:var(--ok)}
.mt-tempo{display:flex;align-items:center;justify-content:center;gap:10px;flex-wrap:wrap}

/* Step grids (beat maker) */
.bm-wrap{overflow-x:auto;margin-top:12px;padding-bottom:6px}
.bm-grid{display:grid;gap:4px;align-items:center;min-width:640px}
.bm-name{font-size:.85rem;font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;cursor:pointer;background:none;border:0;color:var(--text);text-align:left;padding:4px 6px;border-radius:6px;font-family:inherit}
.bm-name:hover{background:var(--accent-soft);color:var(--accent)}
.bm-cell{height:34px;border-radius:6px;border:1px solid var(--border);background:var(--surface);cursor:pointer;padding:0}
.bm-cell.beat{background:var(--bg);border-color:var(--muted)}
.bm-cell.on{background:var(--accent);border-color:var(--accent)}
.bm-cell.on.acc{box-shadow:inset 0 0 0 3px rgba(255,255,255,.55)}
.bm-cell.now{outline:2px solid var(--ok);outline-offset:1px}
.bm-vol{width:70px}

/* Piano */
.pn-keys{position:relative;height:190px;margin-top:14px;user-select:none;-webkit-user-select:none;touch-action:none;overflow-x:auto;overflow-y:hidden;border-radius:0 0 10px 10px}
.pn-inner{position:relative;height:100%;min-width:100%}
.pn-key{position:absolute;top:0;border:1px solid #9aa3b5;border-radius:0 0 6px 6px;display:flex;align-items:flex-end;justify-content:center;font-size:.7rem;font-weight:600;padding-bottom:6px;cursor:pointer}
.pn-key.w{background:#fff;color:#5b6475;height:100%;z-index:1}
.pn-key.b{background:#14171f;color:#c9cfdb;height:62%;z-index:2;border-color:#000}
.pn-key.w.on{background:#bcd0ff}
.pn-key.b.on{background:#2563eb}

/* Multitrack editor and podcast studio */
.ed{border:1px solid var(--border);border-radius:10px;overflow:hidden;margin-top:12px;background:var(--bg)}
.ed-tools{display:flex;flex-wrap:wrap;gap:6px;align-items:center;padding:8px;border-bottom:1px solid var(--border);background:var(--surface)}
.ed-tools .sep{width:1px;height:24px;background:var(--border);margin:0 4px}
.ed-tools .btn.small{padding:7px 10px}
.ed-body{display:flex;min-height:180px}
.ed-heads{flex:0 0 190px;border-right:1px solid var(--border);background:var(--surface)}
.ed-ruler-pad{height:26px;border-bottom:1px solid var(--border)}
.ed-head{height:96px;border-bottom:1px solid var(--border);padding:6px 8px;display:flex;flex-direction:column;gap:4px;box-sizing:border-box}
.ed-head.sel{background:var(--accent-soft)}
.ed-head input[type=text]{padding:3px 6px;font-size:.85rem;font-weight:600;background:transparent;border-color:transparent}
.ed-head input[type=text]:hover,.ed-head input[type=text]:focus{border-color:var(--border);background:var(--bg)}
.ed-head .r{display:flex;gap:4px;align-items:center}
.ed-head .r button{font:inherit;font-size:.75rem;font-weight:700;width:26px;height:24px;border-radius:6px;border:1px solid var(--border);background:var(--bg);color:var(--muted);cursor:pointer;padding:0}
.ed-head .r button[aria-pressed=true]{background:var(--btn);color:#fff;border-color:transparent}
.ed-head .r button.m[aria-pressed=true]{background:#d97706}
.ed-head .r input[type=range]{flex:1;min-width:0}
.ed-head .r span{font-size:.7rem;color:var(--muted);width:22px}
.ed-scroll{flex:1;min-width:0;overflow-x:auto;overflow-y:hidden;position:relative}
.ed-canvas{display:block;touch-action:none}
.ed-empty{padding:28px 16px;text-align:center;color:var(--muted)}
.ed-insp{display:flex;flex-wrap:wrap;gap:10px 14px;align-items:flex-end;padding:10px;border-top:1px solid var(--border);background:var(--surface)}
.ed-insp .field{flex:0 1 150px}
.ed-insp .ga-slider{flex:1 1 150px}
@media (max-width:640px){.ed-heads{flex-basis:128px}.ed-head .r span{display:none}}
.pc-list{list-style:none;padding:0;margin:12px 0 0;display:flex;flex-direction:column;gap:8px}
.pc-list li{display:flex;flex-wrap:wrap;gap:8px;align-items:center;padding:10px 12px;border:1px solid var(--border);border-radius:10px;background:var(--surface)}
.pc-list .nm{flex:1 1 160px;min-width:0;font-weight:600;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.pc-list .meta{color:var(--muted);font-size:.85rem}
.pc-tag{font-size:.72rem;font-weight:700;text-transform:uppercase;letter-spacing:.04em;padding:2px 8px;border-radius:999px;background:var(--accent-soft);color:var(--accent)}
input[type=number].mt-bpm{font-size:clamp(3rem,14vw,5.5rem);font-weight:800;line-height:1;width:3.6ch;text-align:center;border-color:transparent;background:transparent;padding:0;font-variant-numeric:tabular-nums;-moz-appearance:textfield;appearance:textfield}
input.mt-bpm::-webkit-outer-spin-button,input.mt-bpm::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}
.ed-canvas{position:sticky;left:0}
.ed-spacer{height:1px;margin-top:-1px}
#editor.over .ed{outline:2px dashed var(--accent);outline-offset:2px}
.ed-tools .ga-icon{width:36px;height:36px}
.ed-tools .ga-icon.rec{background:#dc2626;color:#fff;border-color:transparent;animation:ga-pulse 1s infinite}
.ed-tools .ed-rec-btn svg{fill:#dc2626}.ed-tools .ed-rec-btn.rec svg{fill:#fff}
@keyframes ga-pulse{50%{opacity:.6}}
.ed-file-btn{position:relative;overflow:hidden;cursor:pointer}
.ed-file-btn input{position:absolute;inset:0;opacity:0;cursor:pointer;font-size:0}
.ed-insp h3,.ed-insp .h3{margin:0;font-size:.85rem;flex:0 0 100%;color:var(--muted);text-transform:uppercase;letter-spacing:.04em}
.ed-insp>div{display:flex;flex-wrap:wrap;gap:10px 14px;align-items:flex-end;flex:1 1 100%}
.row>.ga-slider{flex:1 1 160px;min-width:0}
.pn-key span{pointer-events:none;text-align:center;line-height:1.3}
.btn.rec{background:#dc2626;color:#fff}
.pn-keys{border:1px solid var(--border);border-top:6px solid #14171f;background:#d7dbe4}
