/* KinetIQ, on top of app.css. Same system: aqua, white, black. One font, sizes 12/14/17/32, weights 500/700, 8 point spacing.
   Numbers use tabular figures so they line up and don't jump while you step frames. */
body.kq { background: var(--ink); }
.kq-word { font-size: 17px; font-weight: 700; letter-spacing: 2px; text-transform: uppercase; color: var(--white); }
.kq-word b { color: var(--aqua); font-weight: 700; }
.center { flex: 1; display: flex; align-items: center; justify-content: center; }
.hlink { font-size: 14px; font-weight: 700; min-height: 44px; display: inline-flex; align-items: center; text-decoration: none; }
.sr { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.label { display: block; margin-bottom: 8px; }
textarea { height: auto; min-height: 96px; padding: 16px; line-height: 1.5; resize: vertical; }
textarea:focus, select:focus { outline: none; border-color: var(--aqua); }
select { width: 100%; height: 56px; border: 1px solid var(--line); border-radius: 12px; padding: 0 16px; font: 500 17px Montserrat, system-ui, sans-serif; color: var(--white); background: var(--fill); color-scheme: dark; }
input[type=search] { -webkit-appearance: none; appearance: none; }
.check { flex-direction: row; align-items: center; gap: 12px; font-size: 14px; min-height: 44px; }
.check input { width: 20px; height: 20px; flex: none; accent-color: var(--aqua); }
.unit-in { position: relative; display: block; }
.unit-in input { padding-right: 64px; font-variant-numeric: tabular-nums; }
.unit-in span { position: absolute; right: 16px; top: 50%; transform: translateY(-50%); font-size: 14px; color: var(--t62); }

/* lists of reps and athletes */
.list { display: flex; flex-direction: column; }
.rep-row { display: flex; align-items: center; gap: 16px; width: 100%; min-height: 72px; padding: 12px 0; border: 0; border-bottom: 1px solid rgba(255,255,255,.12); background: transparent; color: var(--white); text-align: left; }
.rep-row:last-child { border-bottom: 0; }
.rep-row .mid { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.rep-row .t { font-size: 17px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rep-row .d { font-size: 14px; color: var(--t62); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rep-row .b { margin-top: 4px; }
.thumb { width: 72px; height: 48px; flex: none; border-radius: 8px; overflow: hidden; background: var(--fill); display: flex; align-items: center; justify-content: center; }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.num { flex: none; font-size: 17px; font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; }
.num small { margin-left: 4px; font-size: 12px; font-weight: 500; color: var(--t62); }
.num.sm { color: var(--t80); }

.search input { padding-left: 16px; }
.chips.scroll { flex-wrap: nowrap; overflow-x: auto; margin: 0 -24px; padding: 0 24px; scrollbar-width: none; }
.chips.scroll::-webkit-scrollbar { display: none; }
.chips.scroll button { flex: none; }

/* headline numbers */
.big { display: block; font-size: 32px; font-weight: 700; line-height: 1.1; font-variant-numeric: tabular-nums; color: var(--white); }
.big small { margin-left: 4px; font-size: 14px; font-weight: 500; color: var(--t62); }
.lbl { display: block; font-size: 12px; color: var(--t62); }
.stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.stats .lbl { margin-bottom: 4px; }
.numbers { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 16px; margin-top: 16px; }
.numbers .lbl { margin-top: 4px; }
.numbers > div:first-child:nth-last-child(1) { grid-column: 1 / -1; }
.result { border-color: var(--aqua); }

/* progress chart: one series, recessive grid, hover and tap read-out */
.chart { margin-top: 24px; }
.chart .tip { min-height: 20px; margin-bottom: 8px; font-variant-numeric: tabular-nums; }
.chart .tip b { color: var(--white); font-weight: 700; }
.chart svg { display: block; width: 100%; height: auto; touch-action: pan-y; }
.chart .grid { stroke: rgba(255,255,255,.08); stroke-width: 1; }
.chart .ax { fill: rgba(255,255,255,.62); font: 500 12px Montserrat, system-ui, sans-serif; font-variant-numeric: tabular-nums; }
.chart .ln { fill: none; stroke: var(--aqua); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.chart .dot { fill: var(--aqua); stroke: var(--ink); stroke-width: 2; }
.chart .dot.on { r: 6; }
.chart .cross { stroke: rgba(255,255,255,.4); stroke-width: 1; }

/* rep page */
.player { margin: 0 -24px; background: #000; }
.player video { display: block; width: 100%; max-height: 64vh; background: #000; }
.notes { display: flex; flex-direction: column; gap: 16px; }
.note { padding: 16px; border-radius: 12px; background: var(--fill); }
.note.coach { background: rgba(0,194,178,.08); border: 1px solid rgba(0,194,178,.24); }
.note .who { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 12px; color: var(--t62); }
.note .who b { color: var(--white); font-size: 14px; }
.note .who .pill { background: transparent; min-height: 28px; cursor: pointer; font-family: inherit; }
.note .body { margin-top: 8px; font-size: 14px; line-height: 1.5; color: var(--t80); white-space: pre-wrap; overflow-wrap: anywhere; }

.switch { position: relative; width: 52px; height: 32px; flex: none; border: 0; border-radius: 999px; background: rgba(255,255,255,.2); padding: 0; transition: background .2s; }
.switch span { position: absolute; top: 4px; left: 4px; width: 24px; height: 24px; border-radius: 999px; background: var(--white); transition: transform .2s; }
.switch.on { background: var(--aqua); }
.switch.on span { transform: translateX(20px); }
.switch::after { content: ''; position: absolute; inset: -8px; }

label.choice.file { cursor: pointer; flex-direction: row; }
label.choice.small-choice { padding: 16px; border-width: 1px; }
.tips p { color: var(--t72); }

/* analyzer */
.dock { position: sticky; top: 0; z-index: 4; margin: 0 -24px; padding: 0 24px 8px; background: var(--ink); border-bottom: 1px solid var(--line); }
.stage { position: relative; margin: 8px -24px 0; background: #000; height: min(40vh, 400px); }
.stage video, .stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.stage canvas { touch-action: manipulation; cursor: crosshair; }
.stage .hint, .stage .busy { position: absolute; left: 50%; transform: translateX(-50%); padding: 8px 16px; border-radius: 999px; background: rgba(13,13,13,.88); font-size: 14px; font-weight: 700; white-space: nowrap; pointer-events: none; }
.stage .hint { top: 16px; color: var(--aqua); }
.stage .busy { top: 50%; color: var(--white); }
.transport { display: flex; gap: 8px; margin-top: 8px; }
.transport button { flex: 1; height: 48px; border: 1px solid var(--line); border-radius: 12px; background: var(--fill); color: var(--white); font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums; display: flex; align-items: center; justify-content: center; }
.transport button[data-act=playA] { background: var(--aqua); color: var(--ink); border-color: var(--aqua); }
input[type=range]#scrub { -webkit-appearance: none; appearance: none; height: 44px; padding: 0; border: 0; background: transparent; margin-top: 0; }
#scrub::-webkit-slider-runnable-track { height: 4px; border-radius: 2px; background: rgba(255,255,255,.2); }
#scrub::-webkit-slider-thumb { -webkit-appearance: none; width: 24px; height: 24px; margin-top: -10px; border-radius: 999px; background: var(--aqua); border: 2px solid var(--ink); }
#scrub::-moz-range-track { height: 4px; border-radius: 2px; background: rgba(255,255,255,.2); }
#scrub::-moz-range-thumb { width: 20px; height: 20px; border-radius: 999px; background: var(--aqua); border: 2px solid var(--ink); }
.readout { font-variant-numeric: tabular-nums; }
.readout b { color: var(--white); }
.setup { margin-top: 16px; padding: 16px; }
.mark { display: flex; align-items: center; gap: 12px; padding: 12px 12px 12px 16px; border-radius: 12px; border: 1px solid var(--line); background: var(--card); }
.mark .mid { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.mark .t { font-size: 14px; font-weight: 700; }
.mark .d { font-size: 12px; color: var(--t62); font-variant-numeric: tabular-nums; }
.mark.set .d { color: var(--aqua); }
.mark.armed { border-color: var(--aqua); background: rgba(0,194,178,.10); }
.mark .btn.sm { width: auto; flex: none; height: 44px; padding: 0 16px; }
.mark .link { min-height: 44px; flex: none; align-self: center; }
.assist { margin-top: 16px; padding: 16px; }
.assist .mark { background: transparent; }

.bar { height: 8px; border-radius: 4px; background: rgba(255,255,255,.12); overflow: hidden; margin-top: 24px; }
.bar span { display: block; height: 100%; background: var(--aqua); transition: width .2s; }

@media (min-width: 528px) {
  .stage, .player { margin-left: 0; margin-right: 0; border-radius: 16px; overflow: hidden; }
  .dock { padding-top: 8px; }
}

/* standalone app pieces */
.switcher select { height: 44px; max-width: 160px; padding: 0 12px; font-size: 14px; font-weight: 700; border-radius: 12px; text-overflow: ellipsis; }
.notice { margin: 0 0 16px; padding: 12px 16px; border-radius: 12px; border: 1px solid rgba(0,194,178,.4); background: rgba(0,194,178,.08); font-size: 14px; color: var(--white); }
.big.code { letter-spacing: 4px; margin-top: 8px; }
.tabbar.four { gap: 8px; justify-content: space-around; }
.tabbar.four button { min-width: 72px; }
.legal h2 { margin-top: 32px; }
.legal .body { margin: 0; font-size: 14px; }
