/* ================================================================ live mirror */
.card { background: var(--vm-panel); border: 1px solid var(--vm-grid); border-radius: var(--radius); padding: 16px 18px; min-width: 0; }
.card h3 { margin-bottom: 8px; }
.hint { color: var(--vm-text-dim); font-size: 13px; }
.live { display: grid; gap: var(--gap); }
.banner { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; background: var(--vm-panel-raised); border: 1px solid var(--vm-grid-strong); border-radius: var(--radius-sm); padding: 10px 16px; }
.banner.warn { background: #1f1b0e; border-color: #7a6a20; color: #f6e7a8; }
.banner.play { background: rgba(79, 209, 197, .1); border-color: rgba(79, 209, 197, .5); justify-content: flex-start; }
.banner.play .btn { margin-left: auto; }

.stage { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); }
.stage-tabs { display: none; }
.canvas-wrap { position: relative; }
.canvas-wrap canvas, .roll-wrap canvas { display: block; width: 100%; }
.stage .canvas-wrap canvas { height: clamp(260px, 40vh, 440px); background: #0b0e13; }
.canvas-wrap.wide canvas { height: 240px; background: #0b0e13; }
.chip-label, .chip-slow { position: absolute; background: rgba(10, 14, 20, .78); border-radius: 999px; padding: 4px 12px; font-size: 13px; font-weight: 700; pointer-events: none; }
.chip-label { top: 10px; left: 10px; font-size: 15px; }
.chip-label:empty, .chip-slow:empty { display: none; }
.chip-slow { bottom: 10px; right: 10px; color: var(--vm-text-dim); font-weight: 500; font-size: 12px; max-width: 46%; text-align: right; }
.chip-label[data-label=pressed], .chip-label[data-label=constricted] { color: #f6ad55; }
.chip-label[data-label=breathy], .chip-label[data-label=thin] { color: #90cdf4; }
.chip-label[data-label=balanced] { color: var(--vm-good); }
.chip-label[data-label=heavy] { color: #fbb6ce; }
.caption { margin: 10px 4px 2px; color: #c6d0de; min-height: 3em; font-size: 15px; }
.badge-host { margin-left: auto; }
.panel > header .badge-host .badge { margin-left: 0; }

.live-grid { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(300px, 1fr); gap: var(--gap); align-items: start; }
.side { display: grid; gap: var(--gap); }
.pitch-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; margin-bottom: 10px; }
.pitch-label { color: var(--vm-text-dim); font-size: 13px; }
.note-big { font-size: clamp(34px, 6vw, 52px); font-weight: 800; line-height: 1.1; letter-spacing: -.02em; min-height: 1.15em; }
.tune { font-size: 15px; color: var(--vm-text-dim); min-height: 1.5em; font-weight: 600; }
.tune[data-tone=good] { color: var(--vm-good); }
.tune[data-tone=off] { color: var(--vm-text); }
.reg-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding-top: 8px; }
.reg-label { color: var(--vm-text-dim); font-size: 13px; }
.badge.reg { font-size: 16px; padding: 4px 14px; min-width: 6em; justify-content: center; }
.reg-conf { font-size: 12px; color: var(--vm-text-dim); }
.roll-wrap canvas { height: 230px; border-radius: 12px; background: #0b0e13; }
.pitch-card .hint { margin-top: 8px; }
.cue-text { font-size: 19px; font-weight: 700; line-height: 1.45; min-height: 2.9em; color: var(--vm-text); }
.cue-text[data-active=""] { color: var(--vm-text-dim); font-weight: 500; font-size: 16px; }
.coach-card { border-color: rgba(79, 209, 197, .35); }
.meters { display: grid; gap: 10px; margin-top: 10px; }
.meter[data-mirror] .m-zone { background: rgba(255, 255, 255, .05); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14); }
.meter[data-mirror] .m-needle, .meter[data-mirror][data-level=good] .m-needle, .meter[data-mirror][data-level=off] .m-needle { background: var(--vm-accent); box-shadow: 0 0 0 3px rgba(0, 0, 0, .3), 0 0 14px rgba(79, 209, 197, .45); }
.meter[data-mirror][data-level=idle] .m-needle { background: var(--vm-text-dim); box-shadow: 0 0 0 3px rgba(0, 0, 0, .3); }

.controls { display: grid; grid-template-columns: auto 1fr; gap: 14px 22px; align-items: center; margin-top: var(--gap); }
.col { display: grid; gap: var(--gap); min-width: 0; }
.controls-side { display: flex; gap: 10px; flex-wrap: wrap; }
.tone-hint { grid-column: 1 / -1; }
.rec-btn { width: 84px; height: 84px; border-radius: 50%; border: 4px solid var(--vm-text); background: transparent; display: grid; place-items: center; cursor: pointer; position: relative; padding: 0; color: var(--vm-text); }
.rec-btn:hover { border-color: #fff; }
.rec-dot { width: 46px; height: 46px; border-radius: 50%; background: #f56565; transition: all .15s; }
.rec-btn.on .rec-dot { width: 30px; height: 30px; border-radius: 8px; }
.rec-btn.on { border-color: #f56565; animation: recpulse 1.4s infinite; }
.rec-btn[disabled] { opacity: .4; cursor: default; }
.rec-wrap { display: grid; justify-items: center; gap: 6px; }
.rec-label { font-size: 13px; font-weight: 700; white-space: nowrap; }
@keyframes recpulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(245, 101, 101, .5); } 50% { box-shadow: 0 0 0 12px rgba(245, 101, 101, 0); } }

.takes { list-style: none; padding: 0; display: grid; gap: 8px; }
.take { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; background: var(--vm-panel-raised); border-radius: var(--radius-sm); padding: 8px 12px; }
.take small { color: var(--vm-text-dim); }
.take-actions { display: flex; gap: 6px; align-items: center; }
.takes .empty { color: var(--vm-text-dim); }

.details { display: grid; gap: var(--gap); }
.details-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); align-items: start; }
.numbers { display: grid; gap: 4px; }
.numbers > div { display: flex; justify-content: space-between; gap: 12px; border-bottom: 1px solid var(--vm-grid); padding: 4px 0; }
.numbers dt { color: var(--vm-text-dim); font-size: 14px; }
.numbers dd { font-weight: 700; font-variant-numeric: tabular-nums; }

@media (max-width: 980px) {
  .live-grid { grid-template-columns: 1fr; }
  .live-grid .col, .live-grid .side { display: contents; }
  .pitch-card { order: 1; } .coach-card { order: 2; } .meters-card { order: 3; } .controls { order: 4; }
  .details-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .stage { grid-template-columns: 1fr; }
  .stage-tabs { display: flex; gap: 6px; background: var(--vm-panel); border-radius: 999px; padding: 4px; }
  .stage-tabs .tab { flex: 1; border: 0; background: none; color: var(--vm-text-dim); padding: 9px 12px; border-radius: 999px; font-weight: 700; cursor: pointer; }
  .stage-tabs .tab.on { background: var(--vm-panel-raised); color: var(--vm-text); }
  .stage[data-tab=folds] .panel-tract, .stage[data-tab=tract] .panel-folds { display: none; }
  .stage .canvas-wrap canvas { height: min(52vh, 380px); }
  .controls { grid-template-columns: 1fr; justify-items: center; }
  .roll-wrap canvas { height: 190px; }
  .cue-text { min-height: 0; }
  .note-big { font-size: 40px; }
}
