/* Replay layer on top of the dashboard's styles.css (site/ only). Uses the dashboard's color tokens, so it
   follows its dark/light themes. */

/* ------------------------------------------------------------------ admin controls: not in a replay */
#conn, #auth, #breaker-reset, #start-task, .mandate-actions, .approval-actions, .vendor-url { display: none !important; }
#vendor-modes .seg { pointer-events: none; }
.rp-note { margin: 8px 0 0; font-size: 12px; color: var(--muted); line-height: 1.45; }
.breaker-why .rp-note { margin-top: 10px; }

/* ------------------------------------------------------------------ the replay bar */
.rp {
  background: var(--panel-2);
  border-bottom: 1px solid var(--border);
  padding: 12px 20px 10px;
  display: grid; gap: 10px;
}
.rp-top { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.rp-badge {
  display: inline-flex; align-items: center; gap: 7px; align-self: center;
  padding: 3px 10px; border-radius: 999px;
  background: var(--warn-bg); color: var(--warn-ink);
  border: 1px solid color-mix(in srgb, var(--warn) 45%, transparent);
  font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
}
.rp-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--warn); }
.rp-what { margin: 0; flex: 1 1 420px; color: var(--text-2); font-size: 13.5px; line-height: 1.5; }
.rp-what b { color: var(--text); }
.rp-links { display: flex; gap: 14px; font-size: 13px; font-weight: 600; }
.rp-links a { color: var(--accent-ink); text-decoration: none; white-space: nowrap; }
.rp-links a:hover { text-decoration: underline; }

.rp-controls { display: flex; align-items: center; gap: 12px 16px; flex-wrap: wrap; }
.rp-play { min-width: 104px; }
.rp-speed { display: flex; }
.rp-speed .seg:first-child { border-radius: 7px 0 0 7px; }
.rp-speed .seg:last-child { border-radius: 0 7px 7px 0; }
.rp-speed .seg + .seg { border-left: 0; }
.rp-takes { display: flex; align-items: center; gap: 8px 14px; flex-wrap: wrap; }
.rp-group { display: flex; align-items: center; gap: 4px; }
.rp-group-label { font-size: 11px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 650; margin-right: 4px; white-space: nowrap; }
.rp-take { border-radius: 7px; min-width: 34px; font-family: var(--mono); }
.rp-clock { margin-left: auto; font-family: var(--mono); font-size: 15px; font-weight: 650; font-variant-numeric: tabular-nums; color: var(--text); }

.rp-track {
  position: relative; height: 6px; border-radius: 999px; cursor: pointer;
  background: var(--raised); border: 1px solid var(--border);
}
.rp-track:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.rp-fill { position: absolute; inset: 0 auto 0 0; border-radius: 999px; background: var(--accent); }
.rp-tick { position: absolute; top: -3px; bottom: -3px; width: 2px; margin-left: -1px; background: var(--faint); border-radius: 1px; }

.rp-caption {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px;
  font-size: 13.5px; line-height: 1.5; color: var(--text-2); min-height: 42px;
}
.rp-scene { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--accent-ink); font-weight: 700; white-space: nowrap; }
.rp-title { color: var(--text); }
.rp-look { flex: 1 1 100%; }
.rp-look a { color: var(--accent-ink); }
.rp-live-note { color: var(--warn-ink); }
.rp-result { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px; font-weight: 600; color: var(--text); }

@media (max-width: 640px) {
  .rp { padding: 10px 16px; }
  .rp-clock { margin-left: 0; }
  .rp-group { flex-wrap: wrap; }
}
