:root {
  --bg: #eef3f7;
  --surface: #ffffff;
  --surface-2: #f7f9fb;
  --text: #142033;
  --muted: #667387;
  --border: #d9e2ea;
  --navy: #10233f;
  --teal: #00a884;
  --amber: #f4a51c;
  --red: #df4151;
  --blue: #3478f6;
  --violet: #7c5cff;
  --shadow: 0 16px 45px rgba(20, 32, 51, .08);
}

* { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
}
button, input, select, textarea { font: inherit; }
button,
a,
label,
select,
summary,
[role="button"],
[data-frame-link],
[data-library-type],
[data-commercial-view],
input[type="checkbox"],
input[type="radio"],
input[type="range"],
input[type="file"] {
  cursor: pointer;
}

body.persistent-console {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  height: 100vh;
  overflow: hidden;
  background: #08172a;
}
.broadcast-bar {
  position: relative;
  z-index: 50;
  display: grid;
  grid-template-columns: minmax(210px, 1.25fr) auto minmax(250px, 1.45fr) minmax(260px, 1.6fr) minmax(210px, 1.05fr) minmax(145px, .7fr) minmax(150px, .8fr) auto minmax(110px, .55fr);
  align-items: center;
  gap: 18px;
  min-height: 88px;
  padding: 15px 18px;
  color: #f8fbff;
  background:
    radial-gradient(circle at 8% 0%, rgba(0, 210, 165, .18), transparent 28%),
    linear-gradient(135deg, #061326 0%, #071b31 55%, #09223a 100%);
  box-shadow: 0 12px 34px rgba(2, 8, 23, .38);
}
.broadcast-brand {
  display: flex;
  align-items: center;
  gap: 13px;
  min-width: 0;
}
.broadcast-brand strong {
  display: block;
  font-size: 21px;
  letter-spacing: .01em;
}
.broadcast-brand span,
.broadcast-now span,
.broadcast-now small,
.broadcast-next span,
.broadcast-next small,
.broadcast-clock span,
.broadcast-controls span {
  color: #b8c7d9;
  font-size: 12px;
  font-weight: 750;
}
.signal-mark {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  width: 44px;
  height: 44px;
  color: #22e6a8;
}
.signal-mark i {
  width: 4px;
  border-radius: 999px;
  background: currentColor;
  box-shadow: 0 0 12px rgba(34, 230, 168, .42);
}
.signal-mark i:nth-child(1) { height: 12px; }
.signal-mark i:nth-child(2) { height: 24px; }
.signal-mark i:nth-child(3) { height: 34px; }
.signal-mark i:nth-child(4) { height: 24px; }
.signal-mark i:nth-child(5) { height: 14px; }
.live-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 0 15px;
  border: 1px solid rgba(148, 163, 184, .34);
  border-radius: 8px;
  color: #94a3b8;
  font-weight: 950;
  text-transform: uppercase;
  white-space: nowrap;
}
.live-badge i,
.persistent-system i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #64748b;
  box-shadow: 0 0 0 5px rgba(148, 163, 184, .1);
}
.live-badge.is-live {
  border-color: rgba(34, 230, 168, .45);
  color: #22e6a8;
}
.live-badge.is-live i {
  background: #22e6a8;
  box-shadow: 0 0 0 5px rgba(34, 230, 168, .12);
}
.broadcast-now,
.broadcast-next {
  min-width: 0;
}
.broadcast-now strong,
.broadcast-next strong {
  display: block;
  overflow: hidden;
  margin-top: 3px;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 16px;
}
.broadcast-now small,
.broadcast-next small {
  display: block;
  overflow: hidden;
  margin-top: 3px;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.broadcast-auto-cue {
  width: max-content;
  max-width: 100%;
  margin-top: 7px;
  border-color: rgba(255,255,255,.14);
  background: rgba(255,255,255,.08);
}
.broadcast-vu {
  display: grid;
  gap: 8px;
  min-width: 0;
}
.broadcast-vu span {
  overflow: hidden;
  color: #e5edf7;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.broadcast-vu small,
.on-air-elapsed {
  display: block;
  color: #9fb1c8;
  font-size: 12px;
  font-weight: 850;
}
.on-air-box .on-air-elapsed {
  margin-top: 4px;
  color: #991b1b;
}
.audio-seek-bar {
  width: 100%;
  height: 6px;
  accent-color: #22c55e;
  cursor: pointer;
}
.audio-seek-bar:disabled {
  cursor: not-allowed;
  opacity: .45;
}
.broadcast-vu .audio-seek-bar {
  margin-top: -2px;
}
.on-air-box .on-air-seek {
  margin-top: 10px;
  accent-color: #ef4444;
}
.broadcast-meter {
  display: flex;
  align-items: end;
  gap: 4px;
  width: 100%;
  height: 24px;
}
.broadcast-meter i {
  flex: 1 1 0;
  max-width: 7px;
  min-width: 3px;
  min-height: 5px;
  border-radius: 999px;
  background: rgba(34, 230, 168, .3);
}
.broadcast-bar.is-playing .broadcast-meter i {
  background: #22e6a8;
  animation: vu 820ms infinite ease-in-out;
}
.broadcast-bar.is-playing .broadcast-meter i:nth-child(2n) { animation-delay: .11s; }
.broadcast-bar.is-playing .broadcast-meter i:nth-child(3n) { animation-delay: .22s; }
.broadcast-bar.is-playing .broadcast-meter i:nth-child(4n) { animation-delay: .33s; }
@keyframes vu {
  0%, 100% { height: 5px; opacity: .45; }
  45% { height: 24px; opacity: 1; }
}
.broadcast-controls {
  display: grid;
  gap: 5px;
  min-width: 0;
}
.broadcast-controls button {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 8px;
  color: #f8fbff;
  background: rgba(255,255,255,.1);
  font-weight: 950;
}
.broadcast-controls label {
  display: grid;
  gap: 5px;
  min-width: 130px;
}
.broadcast-controls span {
  display: flex;
  justify-content: space-between;
}
.broadcast-controls b {
  color: #f8fbff;
}
.broadcast-controls input {
  width: 90px;
  accent-color: #22e6a8;
}
.broadcast-clock {
  padding-left: 16px;
  border-left: 1px solid rgba(255,255,255,.12);
}
.broadcast-clock strong {
  display: block;
  font-size: 23px;
}
.broadcast-clock span {
  display: block;
  margin-top: 3px;
}
.broadcast-settings {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  color: #dce9f7;
  background: rgba(255,255,255,.08);
  text-decoration: none;
}
.broadcast-user {
  display: grid;
  align-items: center;
  justify-items: center;
  gap: 9px;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}
.settings-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(300px, 1fr));
  gap: 16px;
}
.settings-tabs {
  display: grid;
  gap: 0;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(255, 255, 255, .92);
  box-shadow: 0 12px 30px rgba(15, 23, 42, .08);
}
.settings-tab-list {
  display: flex;
  gap: 8px;
  padding: 12px;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, #ffffff, #f7fafc);
}
.settings-tab {
  min-height: 42px;
  padding: 0 18px;
  border: 1px solid #d5e0ec;
  border-radius: 10px;
  background: #fff;
  color: #64748b;
  font-weight: 900;
}
.settings-tab.is-active {
  border-color: #93c5fd;
  background: #eff6ff;
  color: #0f4fd8;
  box-shadow: 0 7px 18px rgba(37, 99, 235, .12);
}
.settings-tab-panel {
  display: none;
  padding: 18px;
}
.settings-tab-panel.is-active {
  display: block;
}
.settings-tab-panel .settings-card {
  max-width: 980px;
  min-height: 360px;
  box-shadow: none;
}
.stations-layout {
  display: grid;
  grid-template-columns: minmax(320px, 430px) minmax(520px, 1fr);
  gap: 16px;
  align-items: start;
}
.station-create-card {
  position: sticky;
  top: 16px;
}
.stations-panel {
  min-height: 420px;
}
.stations-list {
  display: grid;
  gap: 10px;
  padding: 14px;
}
.station-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: linear-gradient(135deg, #ffffff, #f8fbff);
}
.station-card.is-current {
  border-color: #14b8a6;
  box-shadow: inset 4px 0 0 #14b8a6;
}
.station-card h3 {
  margin: 8px 0 4px;
  color: var(--text);
  font-size: 20px;
}
.station-card p {
  margin: 0;
  color: var(--muted);
}
.station-badge {
  display: inline-flex;
  width: max-content;
  border-radius: 999px;
  padding: 5px 10px;
  background: #eaf6ff;
  color: #075985;
  font-size: 11px;
  font-weight: 1000;
  letter-spacing: .02em;
  text-transform: uppercase;
}
.station-card.is-current .station-badge {
  background: #d1fae5;
  color: #047857;
}
.station-card dl {
  display: grid;
  grid-template-columns: repeat(3, auto);
  gap: 10px;
  margin: 0;
}
.station-card dt {
  color: var(--muted);
  font-size: 10px;
  font-weight: 1000;
  text-transform: uppercase;
}
.station-card dd {
  margin: 3px 0 0;
  max-width: 120px;
  overflow: hidden;
  color: var(--text);
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.form-error {
  padding: 14px;
  color: #991b1b;
  background: #fff1f2;
  border: 1px solid #fecdd3;
  border-radius: 8px;
  font-weight: 900;
}
.microprogram-layout {
  display: grid;
  grid-template-columns: minmax(240px, 320px) minmax(420px, 720px);
  gap: 16px;
  align-items: start;
}
.microprogram-list {
  display: grid;
  gap: 8px;
}
.microprogram-list button {
  display: grid;
  gap: 3px;
  min-height: 64px;
  padding: 14px 16px;
  text-align: left;
  border: 1px solid var(--border);
  background: var(--surface);
}
.microprogram-list button.is-active {
  border-color: #14b8a6;
  background: #f0fdfa;
}
.microprogram-list span {
  color: var(--muted);
  font-size: 12px;
}
.microprogram-form {
  max-width: none;
}
.microprogram-form-head {
  display: grid;
  gap: 14px;
}
.microprogram-form-head .auto-cue-runtime {
  width: max-content;
}
.microprogram-upload-field {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 8px;
  align-items: center;
}
.microprogram-upload-field .ghost-button {
  min-height: 40px;
}
.microprogram-upload-field small {
  overflow: hidden;
  color: var(--muted);
  font-weight: 700;
  text-transform: none;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.settings-check {
  display: flex !important;
  align-items: center;
  gap: 10px;
}
@media (max-width: 900px) {
  .microprogram-layout {
    grid-template-columns: 1fr;
  }
  .stations-layout {
    grid-template-columns: 1fr;
  }
  .station-create-card {
    position: static;
  }
  .station-card {
    grid-template-columns: 1fr;
  }
  .station-card dl {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
.settings-card {
  display: grid;
  gap: 14px;
  align-content: start;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.settings-card h2,
.settings-card p {
  margin: 0;
}
.settings-card p {
  margin-top: 4px;
  color: var(--muted);
}
.settings-card label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.settings-card input,
.settings-card select,
.settings-card textarea {
  width: 100%;
  box-sizing: border-box;
  min-height: 40px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 11px;
  background: #fff;
  color: var(--text);
}
.settings-card textarea {
  min-height: 96px;
  resize: vertical;
  line-height: 1.45;
}
.microprogram-form .form-grid {
  align-items: end;
}
.settings-card.is-target {
  border-color: #fdba74;
  box-shadow: 0 0 0 3px rgba(249, 115, 22, .12);
}

.monitor-topbar {
  align-items: center;
}

.monitor-sync-pill {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  background: #e6fffb;
  color: #047857;
  font-weight: 900;
}

.remote-monitor-shell {
  display: grid;
  grid-template-columns: minmax(280px, 380px) minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.remote-monitor-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(280px, 1fr));
  gap: 16px;
}

.remote-monitor-card {
  overflow: hidden;
  border: 1px solid #d7dce3;
  border-radius: 18px;
  background: rgba(255, 255, 255, .94);
  box-shadow: 0 18px 42px rgba(15, 23, 42, .10);
}

.remote-radio-card {
  position: sticky;
  top: 16px;
  display: grid;
  gap: 14px;
  padding: 18px;
  background:
    radial-gradient(circle at 26% 20%, rgba(250, 204, 21, .22), transparent 24%),
    radial-gradient(circle at 76% 22%, rgba(239, 68, 68, .22), transparent 24%),
    linear-gradient(145deg, #102033, #17263a);
  color: #fff;
}

.monitor-card-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 18px;
  border-bottom: 1px solid rgba(148, 163, 184, .22);
}

.remote-radio-card .monitor-card-head {
  padding: 0;
  border-bottom: 0;
}

.monitor-card-head span,
.monitor-card-head small,
.remote-radio-card p,
.monitor-time-row,
.monitor-row span {
  color: #64748b;
  font-weight: 750;
}

.remote-radio-card .monitor-card-head span,
.remote-radio-card p,
.remote-radio-card .monitor-time-row {
  color: #cbd5e1;
}

.monitor-card-head h2,
.remote-radio-card h2,
.remote-radio-card h3 {
  margin: 4px 0 0;
}

.monitor-live-badge {
  align-self: start;
  border-radius: 999px;
  padding: 8px 12px;
  background: #e2e8f0;
  color: #64748b;
  text-transform: uppercase;
  font-size: 12px;
}

.monitor-live-badge.is-live {
  background: #10b981;
  color: #fff;
}

.monitor-album-art {
  display: grid;
  place-items: center;
  position: relative;
  height: 210px;
  overflow: hidden;
  border-radius: 22px;
  background: linear-gradient(135deg, #1557d8, #102033);
}

.monitor-album-art i {
  position: absolute;
  width: 86px;
  height: 86px;
  border-radius: 999px;
  filter: blur(10px);
  opacity: .82;
}

.monitor-album-art i:first-child {
  left: 42px;
  top: 34px;
  background: #fbbf24;
}

.monitor-album-art i:nth-child(2) {
  right: 36px;
  top: 42px;
  background: #ef4444;
}

.monitor-album-art b {
  position: relative;
  z-index: 1;
  color: rgba(255,255,255,.92);
  font-size: 30px;
  letter-spacing: .18em;
}

.monitor-progress {
  position: relative;
  height: 12px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255,255,255,.18);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.08);
}

.monitor-progress span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background:
    repeating-linear-gradient(90deg, rgba(255,255,255,.25) 0 8px, transparent 8px 16px),
    linear-gradient(90deg, #ff3b30, #ff9f0a, #ef4444, #ff3b30);
  background-size: 64px 100%, 220% 100%;
  transition: width .25s ease;
}

.remote-radio-card.is-live .monitor-progress span {
  animation: monitorPulseBar .72s linear infinite, monitorColorFlow 1.8s linear infinite;
}

.remote-radio-card.is-live .monitor-progress::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.45), transparent);
  animation: monitorSweep 1.6s ease-in-out infinite;
}

@keyframes monitorPulseBar {
  from { background-position: 0 0, 0% 0; }
  to { background-position: 64px 0, 0% 0; }
}

@keyframes monitorColorFlow {
  from { filter: saturate(1) brightness(1); }
  50% { filter: saturate(1.35) brightness(1.12); }
  to { filter: saturate(1) brightness(1); }
}

@keyframes monitorSweep {
  from { transform: translateX(-100%); }
  to { transform: translateX(100%); }
}

.monitor-time-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.monitor-list {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.monitor-list.compact {
  gap: 8px;
}

.monitor-row {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  min-height: 58px;
  padding: 12px;
  border: 1px solid #dbeafe;
  border-radius: 14px;
  background: #f8fbff;
}

.monitor-row.event {
  border-color: #c7f5ea;
  background: #f0fdfa;
}

.monitor-row.log {
  grid-template-columns: 56px minmax(0, 1fr);
}

.monitor-row b,
.monitor-row span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.monitor-row strong {
  color: #0f766e;
}

.monitor-row em {
  border-radius: 999px;
  padding: 7px 10px;
  background: #fee2e2;
  color: #dc2626;
  font-size: 11px;
  font-style: normal;
  font-weight: 1000;
  text-transform: uppercase;
}

.monitor-empty {
  padding: 16px;
  border-radius: 12px;
  background: #f8fafc;
  color: #64748b;
  font-weight: 800;
}

.monitor-bars {
  display: flex;
  align-items: end;
  gap: 8px;
  height: 116px;
  padding: 18px;
}

.monitor-bars i {
  flex: 1;
  max-width: 26px;
  border-radius: 999px 999px 0 0;
  background: linear-gradient(180deg, #ef4444, #f59e0b);
}

.monitor-stat-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 16px;
}

.monitor-stat-grid div {
  min-height: 92px;
  padding: 14px;
  border-radius: 14px;
  background: #f1f5f9;
}

.monitor-stat-grid strong,
.monitor-stat-grid span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
}

.monitor-stat-grid strong {
  margin-bottom: 8px;
  white-space: nowrap;
}

.monitor-stat-grid span {
  color: #64748b;
  font-weight: 800;
}

@media (max-width: 1180px) {
  .remote-monitor-shell,
  .remote-monitor-grid {
    grid-template-columns: 1fr;
  }
  .remote-radio-card {
    position: static;
  }
}

.broadcast-user span {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(255,255,255,.11);
  color: #dce9f7;
  font-weight: 950;
}
.broadcast-user strong {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 13px;
}
.playlist-picker-tools {
  padding: 14px 18px 4px;
}
.playlist-picker-tools input {
  width: 100%;
  min-height: 46px;
  padding: 0 16px;
  border: 1px solid #cbd8e6;
  border-radius: 8px;
  background: #f8fbff;
  color: var(--text);
  font: inherit;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.03);
}
.playlist-picker-tools input:focus {
  outline: none;
  border-color: #0f766e;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.14);
}
.broadcast-manual {
  min-height: 34px;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 8px;
  background: rgba(255,255,255,.08);
  color: #dce9f7;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}
.broadcast-picker {
  position: absolute;
  top: 74px;
  right: 18px;
  z-index: 55;
  width: min(430px, calc(100vw - 36px));
  max-height: 420px;
  overflow-y: auto;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 8px;
  background: white;
  box-shadow: 0 24px 60px rgba(2, 8, 23, .32);
}
.persistent-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  min-height: 0;
}
.persistent-sidebar {
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-height: 0;
  padding: 18px 12px;
  background: #071b31;
  color: #e8f1fb;
}
.persistent-sidebar nav {
  display: grid;
  gap: 7px;
}
.persistent-sidebar a {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  padding: 0 12px;
  border-radius: 8px;
  color: #d7e4f2;
  text-decoration: none;
  font-weight: 850;
}
.persistent-sidebar a span {
  display: grid;
  place-items: center;
  width: 23px;
  color: #9db3cc;
  font-size: 18px;
}
.persistent-sidebar a.active,
.persistent-sidebar a:hover {
  background: rgba(255,255,255,.1);
  color: white;
}
.persistent-sidebar a.active {
  box-shadow: inset 3px 0 0 #22e6a8;
}
.persistent-system {
  display: grid;
  gap: 9px;
  margin-top: auto;
  padding: 14px 12px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 8px;
  background: rgba(255,255,255,.05);
}
.persistent-system span {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #22e6a8;
  font-size: 13px;
  font-weight: 850;
}
.persistent-system small {
  color: #a9bad0;
}
.persistent-system #remoteSyncStatus {
  color: #d8e5f4;
  font-weight: 750;
}
.persistent-workspace {
  min-width: 0;
  min-height: 0;
  background: var(--bg);
}
.persistent-workspace iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: var(--bg);
}
.persistent-queue {
  display: none;
}
.persistent-hidden {
  display: none !important;
}
body.embedded-page {
  min-height: auto;
  overflow: auto;
}
body.embedded-page .app-shell,
body.embedded-page .app-shell.single-workspace {
  display: block;
  min-height: auto;
}
body.embedded-page .sidebar {
  display: none;
}
body.embedded-page .workspace {
  padding: 18px;
}
body.embedded-page .inspector {
  position: static;
}
body.embedded-page .native-audio {
  display: none;
}

.app-shell {
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr) 340px;
  min-height: 100vh;
}
.app-shell.single-workspace {
  grid-template-columns: 248px minmax(0, 1fr);
}
body.sidebar-collapsed .app-shell,
body.sidebar-collapsed .app-shell.single-workspace {
  grid-template-columns: 76px minmax(0, 1fr);
}
.sidebar {
  position: relative;
  background: var(--navy);
  color: #f8fbff;
  padding: 24px 18px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}
body.sidebar-collapsed .sidebar {
  padding: 20px 12px;
  align-items: center;
}
body.sidebar-collapsed .brand div,
body.sidebar-collapsed .nav-item,
body.sidebar-collapsed .sidebar-card {
  display: none;
}
.sidebar-toggle {
  width: 40px;
  height: 40px;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 8px;
  background: rgba(255,255,255,.08);
  color: white;
  font-weight: 900;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}
.brand-mark {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  background: var(--teal);
  color: white;
  font-weight: 800;
}
.brand small, .sidebar-card small {
  display: block;
  color: #aebbd0;
  margin-top: 2px;
  font-size: 12px;
}
.nav-list { display: grid; gap: 6px; }
.nav-item {
  color: #d7deea;
  text-decoration: none;
  padding: 12px 13px;
  border-radius: 8px;
  font-weight: 700;
}
.nav-item.active, .nav-item:hover {
  background: rgba(255,255,255,.11);
  color: white;
}
.sidebar-card {
  margin-top: auto;
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 14px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 8px;
  background: rgba(255,255,255,.06);
}
.status-dot {
  width: 10px;
  height: 10px;
  background: var(--teal);
  border-radius: 50%;
  box-shadow: 0 0 0 5px rgba(0,168,132,.15);
}

.workspace {
  padding: 24px;
  min-width: 0;
}
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}
h1, h2, p { margin: 0; }
h1 { font-size: 30px; line-height: 1.1; letter-spacing: 0; }
.topbar p, .inspector p { color: var(--muted); margin-top: 7px; line-height: 1.45; }
.onair {
  min-width: 230px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 14px;
  box-shadow: var(--shadow);
}
.onair span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}
.onair strong { display: block; margin-top: 4px; }

.studio-grid {
  display: grid;
  grid-template-columns: minmax(210px, 1.8fr) minmax(0, 6fr) minmax(240px, 2.2fr);
  gap: 16px;
  align-items: start;
}
.studio-status-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 16px;
}
.studio-side {
  display: grid;
  gap: 12px;
}
.studio-pads-column {
  min-width: 0;
}
.commercials-column {
  min-width: 0;
}
.studio-status {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 14px;
  box-shadow: var(--shadow);
}
.studio-status strong {
  display: block;
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}
.studio-status span {
  display: block;
  margin-top: 6px;
  font-weight: 850;
  line-height: 1.35;
}
.on-air-box {
  border-color: #ef4444;
  background: #fff1f2;
  box-shadow: 0 16px 45px rgba(239, 68, 68, .12);
}
.on-air-box strong {
  color: #b91c1c;
}
.on-air-box span {
  color: #7f1d1d;
}
.onair-status-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.vumeter {
  display: inline-flex;
  align-items: end;
  gap: 3px;
  height: 20px;
}
.vumeter i {
  display: block;
  width: 4px;
  height: 5px;
  border-radius: 999px;
  background: #ef4444;
  opacity: .35;
}
.on-air-box.is-playing .vumeter i {
  opacity: 1;
  animation: vuPulse .78s ease-in-out infinite;
}
.on-air-box.is-playing .vumeter i:nth-child(2) { animation-delay: .08s; }
.on-air-box.is-playing .vumeter i:nth-child(3) { animation-delay: .16s; }
.on-air-box.is-playing .vumeter i:nth-child(4) { animation-delay: .24s; }
.on-air-box.is-playing .vumeter i:nth-child(5) { animation-delay: .32s; }
.on-air-box.is-playing .vumeter i:nth-child(6) { animation-delay: .40s; }
.on-air-box.is-playing .vumeter i:nth-child(7) { animation-delay: .48s; }
@keyframes vuPulse {
  0%, 100% { height: 5px; background: #fecaca; }
  45% { height: 20px; background: #dc2626; }
}
.tall-queue {
  max-height: 520px;
}
.compact-pads .pads-grid {
  grid-template-columns: repeat(2, minmax(120px, 1fr));
}
.compact-pads .pad-button {
  min-height: 82px;
}
.commercials-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.commercials-header {
  padding: 15px 16px;
  border-bottom: 1px solid var(--border);
}
.commercials-header strong,
.commercials-header span {
  display: block;
}
.commercials-header span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
}
.commercial-breaks-list {
  display: grid;
  max-height: 520px;
  overflow-y: auto;
}
.commercial-break-hour-group {
  display: grid;
  gap: 8px;
  padding: 12px;
  border-bottom: 1px solid var(--border);
}
.commercial-break-hour-group.is-next {
  background: #fffaf0;
}
.commercial-break-hour-group.active {
  background: #fff1f2;
}
.commercial-break-hour-group.pending {
  background: #fff7ed;
}
.break-hour-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.break-hour-head em {
  border-radius: 999px;
  background: #f1f5f9;
  color: var(--muted);
  padding: 3px 8px;
  font-size: 10px;
  font-style: normal;
  font-weight: 950;
  text-transform: uppercase;
}
.commercial-break-hour-group.active .break-hour-head em,
.commercial-break-hour-group.active .break-time-pill {
  background: #fee2e2;
  color: #991b1b;
}
.commercial-break-hour-group.pending .break-hour-head em,
.commercial-break-hour-group.pending .break-time-pill {
  background: #ffedd5;
  color: #9a3412;
}
.break-hour-items {
  display: grid;
  gap: 8px;
}
.commercial-break-card {
  display: grid;
  gap: 6px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: inset 4px 0 0 #94a3b8;
}
.commercial-break-card.empty {
  color: var(--muted);
}
.break-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.break-card-top em {
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--muted);
  padding: 3px 8px;
  font-size: 10px;
  font-style: normal;
  font-weight: 950;
  text-transform: uppercase;
}
.break-time-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: #e9f8f3;
  color: #087a61;
  padding: 3px 9px;
  font-size: 12px;
  font-weight: 950;
}
.commercial-break-card strong {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 15px;
  line-height: 1.22;
}
.break-card-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}
.break-card-meta b,
.break-card-meta i {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  border-radius: 999px;
  padding: 2px 7px;
  background: var(--surface-2);
  color: var(--muted);
  font-style: normal;
  font-weight: 800;
}
.break-card-meta b {
  color: var(--break-color, #475569);
  background: var(--break-soft, #f1f5f9);
  text-transform: uppercase;
  font-size: 10px;
}
.commercial-break-card.pending {
  background: #fff7ed;
  box-shadow: inset 4px 0 0 #f97316;
}
.commercial-break-card.active {
  background: #fff1f2;
  box-shadow: inset 4px 0 0 #ef4444;
}
.commercial-break-card.active .break-time-pill,
.commercial-break-card.active .break-card-top em {
  background: #fee2e2;
  color: #991b1b;
}
.commercial-break-card.pending .break-time-pill,
.commercial-break-card.pending .break-card-top em {
  background: #ffedd5;
  color: #9a3412;
}
.commercial-break-card.type-commercial {
  --break-color: #0f766e;
  --break-soft: #ccfbf1;
  box-shadow: inset 4px 0 0 #14b8a6;
}
.commercial-break-card.type-jingle {
  --break-color: #6d28d9;
  --break-soft: #ede9fe;
  box-shadow: inset 4px 0 0 #8b5cf6;
}
.commercial-break-card.type-fx {
  --break-color: #be123c;
  --break-soft: #ffe4e6;
  box-shadow: inset 4px 0 0 #f43f5e;
}
.commercial-break-card.type-sweeper {
  --break-color: #1d4ed8;
  --break-soft: #dbeafe;
  box-shadow: inset 4px 0 0 #3b82f6;
}
.commercial-break-card.type-voice_track {
  --break-color: #b45309;
  --break-soft: #fef3c7;
  box-shadow: inset 4px 0 0 #f59e0b;
}
.commercial-break-card.is-next {
  animation: nextBreakPulse 1.35s ease-in-out infinite;
}
.commercial-break-card.is-next .break-time-pill {
  animation: nextBreakPillPulse 1.35s ease-in-out infinite;
}
.commercial-break-card.pending,
.commercial-break-card.active {
  --break-color: inherit;
}
@keyframes nextBreakPulse {
  0%, 100% {
    background: #ffffff;
  }
  50% {
    background: #fff7ed;
  }
}
@keyframes nextBreakPillPulse {
  0%, 100% {
    transform: scale(1);
    box-shadow: none;
  }
  50% {
    transform: scale(1.05);
    box-shadow: 0 0 0 5px rgba(249, 115, 22, 0.16);
  }
}
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.quick-create {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 16px;
}
.type-button, .primary-button, .ghost-button {
  border: 0;
  border-radius: 8px;
  font-weight: 800;
  min-height: 42px;
}
.type-button {
  padding: 0 14px;
  color: white;
}
.type-button.selected { outline: 3px solid rgba(20,32,51,.18); }
.playlist, .event-card.playlist { background: var(--blue); }
.jingle, .event-card.jingle { background: var(--violet); }
.commercial, .event-card.commercial { background: var(--amber); color: #2d2205; }
.live, .event-card.live { background: var(--teal); }
.signal, .event-card.signal { background: var(--red); }

.library-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: var(--shadow);
  margin-bottom: 16px;
  overflow: hidden;
}
.library-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 16px;
  border-bottom: 1px solid var(--border);
}
.library-header span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
}
.upload-form {
  display: grid;
  gap: 14px;
  padding: 16px;
  border-bottom: 1px solid var(--border);
  background: #fbfdff;
}
.drop-zone {
  display: grid;
  place-items: center;
  min-height: 132px;
  padding: 18px;
  border: 2px dashed #adc0d4;
  border-radius: 8px;
  color: var(--text);
  text-align: center;
  background: #fffbea;
  cursor: pointer;
}
.drop-zone.drag-over {
  border-color: var(--teal);
  background: #effcf9;
}
.drop-zone input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.drop-zone strong {
  display: block;
  font-size: 17px;
}
.upload-fields {
  display: grid;
  grid-template-columns: repeat(4, minmax(120px, 1fr));
  gap: 12px;
}
.upload-fields label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.upload-fields input,
.upload-fields select,
.library-tools input,
.library-tools select {
  width: 100%;
  min-height: 40px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 11px;
  color: var(--text);
  background: white;
  font-size: 14px;
  font-weight: 650;
}
.upload-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.upload-actions span {
  color: var(--muted);
  font-weight: 750;
}
.muted-cell {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}
.library-tools {
  display: grid;
  grid-template-columns: minmax(220px, 1fr);
  gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
}
.library-tabs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 10px 16px;
  border-bottom: 1px solid var(--border);
  background: #fbfdff;
}
.library-tabs button,
.library-pagination button,
.tiny-action {
  min-height: 34px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: white;
  color: var(--text);
  padding: 0 11px;
  font-weight: 900;
  white-space: nowrap;
}
.library-tabs button.active {
  background: var(--navy);
  border-color: var(--navy);
  color: white;
}
.library-table-wrap {
  overflow-x: auto;
}
.library-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.library-table th,
.library-table td {
  padding: 11px 13px;
  border-bottom: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
}
.library-table th {
  background: var(--surface-2);
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}
.library-table strong {
  display: block;
  color: var(--text);
}
.library-table small {
  display: block;
  color: var(--muted);
  margin-top: 3px;
}
.audio-type-pill {
  display: inline-flex;
  min-height: 26px;
  align-items: center;
  border-radius: 8px;
  padding: 0 9px;
  background: #edf4ff;
  color: #24579d;
  font-weight: 900;
  white-space: nowrap;
}
.library-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  border-top: 1px solid var(--border);
}
.library-pagination div {
  display: flex;
  align-items: center;
  gap: 8px;
}
.library-pagination button:disabled {
  opacity: .45;
  cursor: not-allowed;
}
.tiny-action {
  min-height: 30px;
  color: #9f2030;
}

.pads-panel {
  background: #101c30;
  color: white;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 8px;
  box-shadow: var(--shadow);
  margin-bottom: 16px;
  overflow: hidden;
}
.pads-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 15px 16px;
  border-bottom: 1px solid rgba(255,255,255,.12);
}
.pads-header span {
  display: block;
  color: #aebbd0;
  font-size: 13px;
  margin-top: 3px;
}
.pads-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}
.pads-actions label {
  display: grid;
  gap: 5px;
  color: #cbd5e1;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}
.pads-actions input { width: 120px; }
.pads-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(120px, 1fr));
  gap: 10px;
  padding: 14px;
}
.pad-button {
  position: relative;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 8px;
  min-height: 94px;
  padding: 12px;
  color: white;
  text-align: left;
  background: linear-gradient(145deg, rgba(255,255,255,.12), rgba(255,255,255,.04));
  overflow: hidden;
  box-shadow: inset 0 -1px 0 rgba(0,0,0,.25);
}
.pad-button::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--pad-color);
  opacity: .18;
}
.pad-button > * {
  position: relative;
  z-index: 1;
}
.pad-button.playing {
  border-color: rgba(255,255,255,.55);
  box-shadow: 0 0 0 2px rgba(255,255,255,.16), inset 0 -1px 0 rgba(0,0,0,.25);
}
.pad-key {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 7px;
  background: rgba(255,255,255,.14);
  color: #dbeafe;
  font-weight: 900;
  margin-bottom: 12px;
}
.pad-button strong {
  display: block;
  font-size: 16px;
  line-height: 1.1;
}
.pad-button span {
  display: block;
  margin-top: 6px;
  color: #cbd5e1;
  font-size: 12px;
  font-weight: 700;
}
.pad-button.playing {
  outline: 3px solid rgba(255,255,255,.36);
  transform: translateY(1px);
}
.pad-button.playing::after {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 10px;
  height: 4px;
  border-radius: 99px;
  background: var(--pad-color);
  box-shadow: 0 0 18px var(--pad-color);
}
.pad-admin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 14px;
  padding: 16px;
}
.pad-admin-card {
  display: grid;
  gap: 12px;
  align-content: start;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px;
  background: #fbfdff;
}
.pad-admin-preview {
  min-height: 92px;
  border-radius: 8px;
  padding: 12px;
  color: white;
  background: linear-gradient(145deg, var(--pad-color), #16233a);
}
.pad-admin-preview strong,
.pad-admin-preview small {
  display: block;
  margin-top: 8px;
}
.pad-admin-preview small {
  color: rgba(255,255,255,.78);
  font-weight: 750;
}
.pad-admin-card label {
  display: grid;
  gap: 6px;
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.pad-admin-card input,
.pad-admin-card select {
  width: 100%;
  min-width: 0;
  min-height: 40px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 11px;
  color: var(--text);
  background: white;
  font-size: 14px;
  font-weight: 650;
}
.pad-admin-card input[type="search"] {
  text-transform: none;
}
.pad-admin-card .form-grid {
  min-width: 0;
}
.pad-audio-picker {
  align-content: start;
}
.pad-audio-combobox {
  position: relative;
  display: grid;
  gap: 6px;
  min-width: 0;
}
.pad-audio-selected {
  width: 100%;
  min-width: 0;
  min-height: 44px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: white;
  color: var(--text);
  padding: 9px 34px 9px 11px;
  font-size: 14px;
  font-weight: 650;
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.pad-audio-selected::after {
  content: '⌄';
  position: absolute;
  right: 12px;
}
.pad-audio-options {
  position: absolute;
  z-index: 30;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  display: grid;
  max-height: 260px;
  overflow-y: auto;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: white;
  box-shadow: 0 18px 38px rgba(15, 23, 42, .18);
}
.pad-audio-options[hidden] {
  display: none;
}
.pad-audio-options button {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  border: 0;
  border-bottom: 1px solid var(--border);
  background: white;
  color: var(--text);
  padding: 10px 11px;
  text-align: left;
}
.pad-audio-options button:last-child {
  border-bottom: 0;
}
.pad-audio-options button:hover {
  background: #f8fafc;
}
.pad-audio-options strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pad-audio-options span {
  color: var(--muted);
  font-size: 12px;
}
.pad-admin-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  flex-wrap: wrap;
  padding-top: 4px;
}
.pad-admin-actions .ghost-button,
.pad-admin-actions .primary-button {
  min-width: 96px;
}

.player-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: var(--shadow);
  margin-bottom: 16px;
  overflow: hidden;
}
.priority-player {
  border-color: #b8d4ed;
}
.player-now {
  padding: 15px 16px;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);
}
.player-now span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.program-title-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 4px;
}
.player-now strong {
  display: block;
  font-size: 24px;
  line-height: 1.18;
}
.manual-playlist-button {
  min-height: 34px;
  margin-left: auto;
  padding: 0 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}
.player-now small {
  display: block;
  color: var(--muted);
  margin-top: 4px;
}
.playlist-refresh-notice {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 11px;
  border: 1px solid #fde68a;
  border-radius: 8px;
  background: #fffbeb;
  padding: 8px 10px;
  color: #92400e;
  font-size: 13px;
  font-weight: 850;
}
.playlist-refresh-notice[hidden] {
  display: none;
}
.playlist-refresh-notice .ghost-button {
  min-height: 32px;
  padding: 0 10px;
}
.player-meta-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 4px;
}
.player-meta-row small {
  margin-top: 0;
}
.auto-cue-runtime {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  min-height: 28px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  cursor: default;
  user-select: none;
}
.auto-cue-runtime[hidden] {
  display: none;
}
.auto-cue-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 26px;
  padding: 4px 9px;
  border: 1px solid #bbf7d0;
  border-radius: 999px;
  color: #047857;
  background: #ecfdf5;
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}
.auto-cue-pill[hidden] {
  display: none;
}
.auto-cue-pill i {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #22c55e;
  box-shadow: 0 0 0 4px rgba(34, 197, 94, .14);
}
.player-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
}
.player-controls label {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  margin-left: 0;
}
.player-controls label:first-of-type { margin-left: auto; }
.player-controls input { width: 130px; }
.transport-button {
  display: inline-grid;
  grid-template-columns: 34px auto;
  align-items: center;
  gap: 8px;
  min-height: 52px;
  padding: 0 14px 0 10px;
}
.transport-button span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: #eaf1f8;
  color: var(--navy);
  font-size: 22px;
  line-height: 1;
}
.transport-button small {
  color: var(--text);
  font-size: 15px;
  font-weight: 900;
}
.primary-transport span {
  background: var(--navy);
  color: white;
}
.fade-control {
  grid-template-columns: 58px auto;
  align-items: end;
  column-gap: 6px;
}
.fade-control input {
  width: 58px;
  min-height: 32px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0 8px;
  background: white;
  color: var(--text);
  font-weight: 800;
}
.fade-control span {
  align-self: center;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: none;
}
.queue-list {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 390px;
  overflow-y: auto;
}
.queue-list li {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) minmax(86px, auto) 34px 62px;
  gap: 10px;
  align-items: center;
  min-height: 42px;
  padding: 8px 16px 8px 12px;
  border-bottom: 1px solid var(--border);
  color: var(--muted);
  font-size: 13px;
  background: rgba(255,255,255,.72);
}
.queue-list li.active {
  background: #eefcf8;
  color: var(--text);
  font-weight: 800;
  box-shadow: inset 4px 0 0 var(--teal);
}
.queue-list li:not(.active) {
  opacity: .72;
}
.queue-list li.from-genre.active {
  background: #ecfdf5;
}
.queue-list li.time-announcement strong {
  color: #7c3aed;
}
.queue-list li.time-announcement.active {
  background: #f5f3ff;
  box-shadow: inset 4px 0 0 #8b5cf6;
}
.queue-number {
  color: #53627a;
  font-weight: 750;
  text-align: center;
}
.queue-track-main {
  display: grid;
  gap: 3px;
  min-width: 0;
}
.queue-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.queue-list strong {
  color: var(--text);
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  min-width: 0;
}
.queue-list li:not(.active) strong {
  font-weight: 750;
  color: #29374d;
}
.queue-subtitle {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  color: var(--muted);
  font-size: 12px;
}
.genre-badge {
  display: inline-block;
  max-width: 150px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  border-radius: 999px;
  padding: 3px 8px;
  background: #d1fae5;
  color: #047857;
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
  text-transform: uppercase;
}
.time-announcement-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  max-width: 150px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  border-radius: 999px;
  padding: 3px 8px;
  background: #ede9fe;
  color: #6d28d9;
  font-size: 11px;
  font-style: normal;
  font-weight: 950;
  text-transform: uppercase;
}
.time-announcement-badge span {
  font-size: 13px;
  line-height: 1;
}
.queue-tag-cell {
  min-width: 0;
  text-align: left;
}
.queue-duration {
  justify-self: end;
  color: #5b6780;
  font-weight: 750;
  font-size: 12px;
  text-align: right;
}
.queue-list li.active .queue-duration,
.queue-list li.active .queue-subtitle {
  color: #42526a;
}
.queue-table-head {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) minmax(140px, auto) 82px;
  gap: 10px;
  align-items: center;
  min-height: 34px;
  padding: 0 16px 0 12px;
  border-bottom: 1px solid var(--border);
  background: #f8fafc;
  color: var(--muted);
  font-size: 11px;
  font-weight: 1000;
  text-transform: uppercase;
}
.table-queue li {
  grid-template-columns: 56px minmax(0, 1fr) minmax(140px, auto) 82px;
  min-height: 58px;
  padding: 8px 16px 8px 12px;
}
.table-queue .queue-number {
  font-size: 16px;
}
.table-queue .queue-tag-cell {
  justify-self: start;
}
.native-audio {
  display: block;
  width: calc(100% - 32px);
  margin: 12px 16px 16px;
}
.hidden-audio {
  display: none;
}
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(16, 35, 63, .52);
}
.modal-backdrop[hidden] {
  display: none;
}
.playlist-modal {
  width: min(680px, 100%);
  max-height: min(720px, 90vh);
  overflow: hidden;
  background: var(--surface);
  border-radius: 8px;
  box-shadow: 0 24px 80px rgba(16, 35, 63, .28);
}
.modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 18px;
  border-bottom: 1px solid var(--border);
}
.modal-header h2 {
  font-size: 22px;
  line-height: 1.15;
}
.modal-header p {
  margin-top: 6px;
  color: var(--muted);
}
.playlist-picker {
  display: grid;
  gap: 10px;
  max-height: 520px;
  overflow-y: auto;
  padding: 14px;
}
.playlist-inline-picker {
  display: grid;
  gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  background: #f8fbff;
}
.playlist-inline-picker[hidden] {
  display: none;
}
.playlist-choice {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  width: 100%;
  min-height: 74px;
  padding: 13px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: white;
  color: var(--text);
  text-align: left;
}
.playlist-choice:hover {
  border-color: #9fb4cc;
  background: #f8fbff;
}
.playlist-choice strong {
  display: block;
  font-size: 16px;
}
.playlist-choice span {
  display: block;
  color: var(--muted);
  margin-top: 4px;
  font-size: 13px;
}
.playlist-choice em {
  justify-self: end;
  border-radius: 8px;
  background: #eefcf8;
  color: #08765f;
  padding: 8px 10px;
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}
.empty-picker {
  padding: 18px;
  color: var(--muted);
  border: 1px dashed var(--border);
  border-radius: 8px;
}

.scheduler-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.schedule-tools {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 16px;
  border-bottom: 1px solid var(--border);
}
.schedule-tools span {
  display: block;
  color: var(--muted);
  margin-top: 3px;
  font-size: 13px;
}
.primary-button {
  background: var(--navy);
  color: white;
  padding: 0 16px;
}
.ghost-button {
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 0 14px;
}

.timeline {
  display: grid;
  grid-template-columns: 68px repeat(7, minmax(118px, 1fr));
  grid-auto-rows: 58px;
  overflow-x: auto;
}
.day-head, .time-cell, .slot {
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.corner, .day-head {
  min-height: 54px;
  grid-row: 1;
  background: var(--surface-2);
}
.day-head {
  padding: 11px 10px;
  font-weight: 800;
}
.day-head small {
  display: block;
  color: var(--muted);
  font-weight: 700;
  margin-top: 2px;
}
.time-cell {
  padding: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  background: var(--surface-2);
}
.slot {
  position: relative;
  z-index: 1;
  padding: 5px;
  background: white;
}
.slot:hover { background: #f4fbff; }
.event-card {
  position: relative;
  z-index: 2;
  align-self: stretch;
  margin: 6px;
  color: white;
  border-radius: 7px;
  padding: 7px 8px;
  overflow: hidden;
  font-size: 12px;
  line-height: 1.25;
  box-shadow: inset 0 -1px 0 rgba(0,0,0,.16);
}
.event-card strong {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.event-card span { opacity: .9; }
.event-card.conflict {
  outline: 3px solid rgba(223,65,81,.35);
}
.event-card.repeat-copy {
  box-shadow: inset 0 -1px 0 rgba(0,0,0,.16), inset 0 0 0 2px rgba(255,255,255,.2);
}

.inspector {
  background: var(--surface);
  border-left: 1px solid var(--border);
  padding: 24px;
  min-width: 0;
}
.inspector-header {
  border-bottom: 1px solid var(--border);
  padding-bottom: 18px;
  margin-bottom: 18px;
}
.event-badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 8px;
  color: white;
  font-size: 12px;
  font-weight: 900;
  margin-bottom: 12px;
}
.event-form { display: grid; gap: 14px; }
.event-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.event-form input, .event-form select, .event-form textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 11px 12px;
  color: var(--text);
  background: white;
  font-size: 14px;
  font-weight: 650;
  text-transform: none;
}
.event-form textarea { resize: vertical; line-height: 1.45; }
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.check-row {
  grid-template-columns: 18px 1fr !important;
  align-items: center;
  text-transform: none !important;
  color: var(--text) !important;
}
.check-row input { width: 16px; }
.conflict-box {
  padding: 11px 12px;
  border-radius: 8px;
  background: #fff2f3;
  color: #9f2030;
  border: 1px solid #ffd1d7;
  font-weight: 800;
  font-size: 13px;
}
.form-actions {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding-top: 4px;
}
.form-note {
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.schedule-page.embedded-page .app-shell {
  display: grid;
  grid-template-columns: minmax(720px, 1fr) 360px;
  min-height: 100vh;
}
.schedule-page.embedded-page .workspace {
  min-width: 0;
  padding: 18px;
}
.schedule-page.embedded-page .inspector {
  display: block;
  position: sticky;
  top: 0;
  align-self: start;
  min-height: 100vh;
  border-left: 1px solid var(--border);
  border-top: 0;
  box-shadow: -18px 0 38px rgba(20, 32, 51, .06);
}
.schedule-topbar {
  align-items: center;
  margin-bottom: 12px;
}
.schedule-topbar h1 {
  font-size: 22px;
}
.schedule-page .scheduler-panel {
  border-radius: 10px;
  box-shadow: 0 16px 45px rgba(20, 32, 51, .08);
}
.schedule-page .schedule-tools {
  min-height: 58px;
  background: #ffffff;
}
.schedule-legend {
  display: inline-flex !important;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}
.schedule-legend i {
  width: 10px;
  height: 10px;
  border-radius: 3px;
}
.schedule-legend i.playlist { background: #bfdbfe; }
.schedule-legend i.live { background: #bbf7d0; }
.schedule-legend i.jingle { background: #ddd6fe; }
.schedule-legend i.signal { background: #fecdd3; }
.schedule-page .timeline {
  grid-template-columns: 64px repeat(7, minmax(132px, 1fr));
  grid-auto-rows: 54px;
  min-width: 1040px;
}
.schedule-page .day-head,
.schedule-page .time-cell,
.schedule-page .slot {
  border-color: #d7e1eb;
}
.schedule-page .corner,
.schedule-page .day-head,
.schedule-page .time-cell {
  background: #f8fafc;
}
.schedule-page .day-head {
  color: #12203a;
  font-size: 13px;
  text-transform: uppercase;
}
.schedule-page .slot {
  background: linear-gradient(180deg, #ffffff 0%, #fbfdff 100%);
}
.schedule-page .slot:hover {
  background: #eef6ff;
}
.schedule-page .event-card {
  margin: 4px;
  border: 1px solid transparent;
  border-radius: 6px;
  color: var(--text);
  padding: 6px 8px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, .08);
}
.schedule-page .event-card small {
  display: block;
  margin-bottom: 2px;
  font-size: 11px;
  font-weight: 950;
}
.schedule-page .event-card span {
  color: #334155;
  opacity: 1;
}
.schedule-page .event-card.playlist {
  background: #dbeafe;
  border-color: #93c5fd;
}
.schedule-page .event-card.playlist small { color: #1d4ed8; }
.schedule-page .event-card.live {
  background: #dcfce7;
  border-color: #86efac;
}
.schedule-page .event-card.live small { color: #047857; }
.schedule-page .event-card.jingle {
  background: #fee2e2;
  border-color: #fca5a5;
}
.schedule-page .event-card.jingle small { color: #dc2626; }
.schedule-page .event-card.signal {
  background: #ede9fe;
  border-color: #c4b5fd;
}
.schedule-page .event-card.signal small { color: #6d28d9; }
.schedule-page .event-card.commercial {
  background: #fef3c7;
  border-color: #fbbf24;
}
.schedule-page .event-card.commercial small { color: #b45309; }
.schedule-page .inspector-header {
  padding-bottom: 20px;
}
.schedule-page .inspector-header h2 {
  font-size: 22px;
}
.schedule-page .event-form {
  gap: 15px;
}
.schedule-page .event-form.is-disabled {
  position: relative;
  opacity: .48;
  filter: grayscale(.2);
}
.schedule-page .event-form.is-disabled::before {
  content: 'Selecciona un bloque o una hora libre para activar este panel.';
  display: block;
  padding: 12px 13px;
  border: 1px dashed #cbd5e1;
  border-radius: 8px;
  background: #f8fafc;
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}
.schedule-page .form-actions .primary-button {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}
.event-badge.muted {
  background: #e2e8f0;
  color: #64748b;
}

.commercial-board {
  display: grid;
  grid-template-columns: minmax(430px, 500px) minmax(0, 1fr);
  align-items: start;
  gap: 16px;
  margin-bottom: 16px;
}

.playlist-builder {
  display: grid;
  grid-template-columns: minmax(320px, .95fr) minmax(360px, 1.05fr);
  gap: 16px;
  margin-bottom: 16px;
}
.playlist-home-view,
.standalone-form-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.playlist-home-view[hidden],
.playlist-create-view[hidden],
.playlist-builder[hidden] {
  display: none;
}
.playlist-home-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px;
  border-bottom: 1px solid var(--border);
}
.playlist-home-header h2 {
  margin: 0;
}
.playlist-home-header p {
  margin: 4px 0 0;
  color: var(--muted);
}
.playlist-overview-list {
  display: grid;
}
.playlist-overview-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 12px;
  align-items: center;
  min-height: 68px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
}
.playlist-overview-card:last-child {
  border-bottom: 0;
}
.playlist-overview-card strong,
.playlist-overview-card span {
  display: block;
}
.playlist-overview-card span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
}
.playlist-overview-card em {
  border-radius: 999px;
  background: #e9f8f3;
  color: #087a61;
  padding: 5px 10px;
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
}
.playlist-overview-empty {
  display: grid;
  gap: 4px;
  padding: 20px 16px;
}
.playlist-overview-empty span {
  color: var(--muted);
}
.playlist-create-view {
  max-width: 620px;
}
.standalone-playlist-form {
  display: grid;
  gap: 14px;
  padding: 16px;
}
.standalone-playlist-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.standalone-playlist-form input {
  min-height: 40px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 11px;
}
.list-admin-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(320px, 1fr));
  gap: 16px;
}
.managed-list {
  display: grid;
  max-height: 620px;
  overflow-y: auto;
}
.builder-panel {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.builder-header {
  padding: 15px 16px;
  border-bottom: 1px solid var(--border);
}
.builder-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.builder-header-row .primary-button {
  min-height: 38px;
  white-space: nowrap;
}
.builder-header span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
}
.playlist-create {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) auto;
  gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
}
.playlist-create input {
  min-height: 40px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 11px;
  color: var(--text);
  background: white;
  font-size: 14px;
  font-weight: 650;
}
.playlist-create-modal .modal-body {
  display: grid;
  gap: 12px;
  padding: 16px;
}
.playlist-create-modal label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.playlist-create-modal input,
.builder-label select {
  min-height: 40px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 11px;
  color: var(--text);
  background: white;
  font-size: 14px;
  font-weight: 650;
}
.modal-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-top: 1px solid var(--border);
}
.modal-actions span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}
.builder-label {
  display: grid;
  gap: 7px;
  padding: 14px 16px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  border-bottom: 1px solid var(--border);
}
.recipe-tools {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) auto auto;
  gap: 10px;
  align-items: end;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  background: #fbfdff;
}
.recipe-tools label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.recipe-tools select {
  min-height: 40px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 11px;
  color: var(--text);
  background: white;
  font-size: 14px;
  font-weight: 650;
}
.auto-cue-panel {
  display: grid;
  gap: 10px;
  padding: 14px 16px;
  border-top: 1px solid var(--border);
  background: #fffaf3;
}
.auto-cue-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.auto-cue-panel-head > strong {
  color: #9a3412;
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
}
.playlist-auto-cue-toggle {
  min-width: 114px;
  justify-content: space-between;
}
.auto-cue-details {
  display: grid;
  gap: 10px;
}
.auto-cue-details[hidden] {
  display: none;
}
.auto-cue-panel p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 650;
}
.auto-cue-tools {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) auto;
  gap: 10px;
  align-items: center;
}
.auto-cue-tools input {
  min-height: 38px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 10px;
  font-weight: 750;
}
.auto-cue-tools span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}
.auto-cue-list {
  display: grid;
  gap: 8px;
  max-height: 190px;
  overflow-y: auto;
}
.auto-cue-list > span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}
.auto-cue-list label {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 9px;
  align-items: center;
  min-height: 44px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: white;
}
.auto-cue-list strong,
.auto-cue-list small {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.auto-cue-list small {
  color: var(--muted);
  margin-top: 2px;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}
.playlist-track-list,
.available-track-list {
  display: grid;
  max-height: min(620px, 68vh);
  overflow-y: auto;
}
.track-row {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  min-height: 48px;
  padding: 9px 14px;
  border-bottom: 1px solid var(--border);
}
.playlist-row {
  grid-template-columns: 34px minmax(0, 1fr) 98px auto;
}
.playlist-row.dragging {
  opacity: .55;
}
.playlist-row.drag-over {
  background: #eef6ff;
  box-shadow: inset 0 2px 0 #3478f6;
}
.track-position {
  color: var(--muted);
  font-weight: 900;
}
.track-row strong {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.track-row small {
  display: block;
  color: var(--muted);
  margin-top: 2px;
}
.genre-rule-row strong {
  color: #0f766e;
}
.time-rule-row strong {
  color: #7c3aed;
}
.rule-tag {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  border-radius: 999px;
  padding: 2px 8px;
  margin-right: 8px;
  font-size: 10px;
  font-weight: 950;
  text-transform: uppercase;
  vertical-align: middle;
}
.genre-tag {
  background: #ccfbf1;
  color: #0f766e;
}
.time-tag {
  background: #ede9fe;
  color: #6d28d9;
  font-size: 14px;
  line-height: 1;
}
.track-order-controls {
  display: grid;
  grid-template-columns: repeat(3, 28px);
  gap: 5px;
}
.drag-handle {
  cursor: grab;
}
.drag-handle:active {
  cursor: grabbing;
}
.track-row button {
  min-height: 34px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-2);
  color: var(--text);
  font-weight: 900;
  padding: 0 10px;
}
.builder-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 14px 16px;
}
.builder-actions span {
  color: var(--muted);
  font-weight: 750;
}
.compact-tools {
  grid-template-columns: minmax(160px, 1fr) 130px;
}
.commercial-form,
.commercial-list {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: var(--shadow);
  padding: 16px;
}
.commercial-form {
  display: grid;
  gap: 13px;
}
.edit-mode-banner {
  display: grid;
  gap: 4px;
  border: 1px solid #fdba74;
  border-left: 7px solid #f97316;
  border-radius: 8px;
  background: #fff7ed;
  color: #9a3412;
  padding: 14px 15px;
  box-shadow: 0 10px 24px rgba(249, 115, 22, 0.12);
}
.edit-mode-banner[hidden] {
  display: none;
}
.edit-mode-banner.is-visible {
  display: grid;
}
.edit-mode-banner strong {
  font-size: 18px;
  font-weight: 950;
  text-transform: uppercase;
}
.edit-mode-banner span {
  color: #7c2d12;
  font-size: 14px;
  font-weight: 850;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.commercial-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.day-checks,
.schedule-modes,
.hour-checks,
.commercial-audio-picker {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fbfdff;
}

.commercial-audio-picker.is-special-event .commercial-audio-tools input {
  display: none;
}
.day-checks {
  grid-template-columns: repeat(2, minmax(120px, 1fr));
}
.hour-checks {
  grid-template-columns: repeat(4, minmax(54px, 1fr));
}
.commercial-audio-picker {
  overflow: hidden;
}
.commercial-audio-tools {
  position: sticky;
  top: 0;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 6px;
  align-items: stretch;
  padding-bottom: 8px;
  background: #fbfdff;
}
.commercial-audio-tools input {
  min-height: 38px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 10px;
}
.commercial-audio-tools span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
  line-height: 1.25;
  white-space: normal;
}
.commercial-audio-list {
  display: grid;
  gap: 8px;
  max-height: 238px;
  overflow-y: auto;
  padding-right: 2px;
}
.commercial-audio-list label {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr) 34px;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 8px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: white;
  cursor: pointer;
  transition: border-color .15s ease, background .15s ease, box-shadow .15s ease;
}
.commercial-audio-list label:hover {
  border-color: #93c5fd;
  background: #f8fbff;
}
.commercial-audio-list label.is-selected {
  border-color: #0f766e;
  background: #ecfdf5;
  box-shadow: inset 3px 0 0 #14b8a6;
}
.audio-preview-button {
  width: 32px;
  height: 32px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: #f8fafc;
  color: var(--ink);
  font-size: 12px;
  font-weight: 950;
  line-height: 1;
  display: inline-grid;
  place-items: center;
  cursor: pointer;
}
.audio-preview-button:hover {
  border-color: #0f766e;
  background: #ecfdf5;
  color: #0f766e;
}
.audio-preview-button.is-playing {
  border-color: #ef4444;
  background: #fef2f2;
  color: #991b1b;
}
.commercial-audio-list strong,
.commercial-audio-list small {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.commercial-audio-list small {
  color: var(--muted);
  margin-top: 2px;
}
.audio-list-note {
  padding: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}
.hour-checks[hidden] {
  display: none;
}
.day-checks legend,
.schedule-modes legend,
.hour-checks legend,
.commercial-audio-picker legend {
  padding: 0 5px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.day-checks label,
.schedule-modes label,
.hour-checks label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text);
  font-size: 13px;
  font-weight: 750;
  text-transform: none;
}
.day-checks input,
.schedule-modes input,
.hour-checks input {
  width: auto;
  min-height: auto;
}
.commercial-form input,
.commercial-form select {
  min-height: 40px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 11px;
  color: var(--text);
  background: white;
  font-size: 14px;
  font-weight: 650;
}
.commercial-form .day-checks input,
.commercial-form .schedule-modes input,
.commercial-form .hour-checks input,
.commercial-form .commercial-audio-picker input {
  width: auto;
  min-height: auto;
}
.break-row {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  min-height: 54px;
  border-bottom: 1px solid var(--border);
  padding: 10px 0;
}
.commercial-event-row {
  grid-template-columns: minmax(150px, 190px) 88px minmax(0, 1fr) auto;
  align-items: start;
}
.commercial-event-row.is-error {
  grid-template-columns: 90px minmax(0, 1fr) auto;
  background: #fff1f2;
  border: 1px solid #fecdd3;
  border-radius: 10px;
  padding: 12px;
}
.commercial-event-row.is-error .event-time-box strong,
.commercial-event-row.is-error span,
.commercial-event-row.is-error em {
  color: #9f1239;
}
.commercial-event-row.is-expired {
  opacity: .68;
  background: #f8fafc;
  border-style: dashed;
}
.commercial-event-row.is-expired .event-time-box strong,
.commercial-event-row.is-expired > span:not(.event-type-column) {
  color: #6b7280;
}
.commercial-event-row.is-expired .event-type-column,
.commercial-event-row.is-expired .time-chip {
  filter: grayscale(.55);
}
.commercial-event-row.is-expired .event-actions {
  opacity: 1;
}
.event-time-box {
  min-width: 0;
}
.event-time-box strong {
  display: block;
  color: var(--text);
  font-size: 14px;
  line-height: 1.2;
}
.time-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 7px;
}
.time-chip {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  border-radius: 999px;
  background: #e9f8f3;
  color: #087a61;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 900;
}
.time-chip.muted {
  background: var(--surface-2);
  color: var(--muted);
}
.event-type-column {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  border-radius: 999px;
  background: #eef6ff;
  color: #1d4ed8;
  padding: 0 9px;
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}
.break-row span {
  min-width: 0;
  font-weight: 800;
}
.break-row small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
  text-transform: capitalize;
}
.break-row em {
  border-radius: 8px;
  background: #fff7ed;
  color: #9a4c00;
  padding: 7px 9px;
  font-style: normal;
  font-weight: 900;
}
.event-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}
.event-actions .ghost-button {
  min-height: 36px;
  padding: 0 11px;
}
.commercial-week-section {
  margin-top: 0;
}
.commercial-week-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.commercial-week-header h3 {
  margin: 0;
  font-size: 20px;
}
.commercial-week-header span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 650;
}
.commercial-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 18px;
}
.commercial-tab {
  border: 1px solid var(--border);
  border-radius: 8px;
  background: white;
  color: var(--muted);
  padding: 8px 12px;
  font-weight: 900;
}
.commercial-tab.is-active {
  border-color: #bfd8ff;
  background: #eff6ff;
  color: #1d4ed8;
}
.commercial-view-panel[hidden] {
  display: none;
}
.day-grid-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}
.day-grid-nav .ghost-button {
  min-width: 36px;
  min-height: 36px;
  padding: 0;
}
.day-grid-nav strong {
  min-width: 110px;
  text-align: center;
}
.commercial-week-grid {
  display: grid;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}
.commercials-native-page {
  background:
    radial-gradient(circle at 18% 0%, rgba(20, 184, 166, .08), transparent 30%),
    linear-gradient(180deg, #f7fafc 0%, #edf3f8 100%);
}
.commercials-native-page .workspace {
  padding: 18px 24px 26px;
}
.commercial-native-hero {
  align-items: end;
  min-height: auto;
  margin-bottom: 18px;
  border: 0;
  background: transparent;
  box-shadow: none;
  padding: 0;
}
.commercial-native-hero h1 {
  font-size: 30px;
  letter-spacing: -0.02em;
}
.commercial-native-hero p {
  color: #5f6f84;
}
.commercials-native-page .commercial-rules-board {
  grid-template-columns: minmax(390px, 500px) minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}
.commercials-native-page .commercial-form,
.commercials-native-page .commercial-list {
  border-color: rgba(156, 174, 195, .72);
  border-radius: 14px;
  background: rgba(255, 255, 255, .86);
  box-shadow: 0 18px 45px rgba(15, 35, 54, .10);
  backdrop-filter: blur(18px);
}
.commercials-native-page .commercial-form {
  position: sticky;
  top: 14px;
  padding: 20px;
}
.commercials-native-page .commercial-form h2,
.commercials-native-page .commercial-view-panel h2 {
  margin: 0;
  letter-spacing: -0.02em;
}
.commercials-native-page .commercial-form label,
.commercials-native-page .day-checks legend,
.commercials-native-page .schedule-modes legend,
.commercials-native-page .hour-checks legend,
.commercials-native-page .commercial-audio-picker legend {
  color: #65748a;
  font-size: 11px;
  letter-spacing: .02em;
}
.commercials-native-page .commercial-form input,
.commercials-native-page .commercial-form select {
  min-height: 42px;
  border-color: #cfd9e6;
  border-radius: 11px;
  background: rgba(255,255,255,.94);
}
.commercials-native-page .day-checks,
.commercials-native-page .schedule-modes,
.commercials-native-page .hour-checks,
.commercials-native-page .commercial-audio-picker {
  border-color: #d5e0ec;
  border-radius: 12px;
  background: rgba(248, 251, 255, .82);
}
.commercials-native-page .commercial-tabs {
  width: max-content;
  gap: 2px;
  margin-bottom: 18px;
  padding: 4px;
  border: 1px solid #cfd9e6;
  border-radius: 12px;
  background: #eef3f8;
}
.commercials-native-page .commercial-tab {
  min-height: 34px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #65748a;
  padding: 0 14px;
}
.commercials-native-page .commercial-tab.is-active {
  background: white;
  color: #155ee8;
  box-shadow: 0 4px 14px rgba(15, 35, 54, .10);
}

.commercials-native-page .commercial-tab-offers.is-active {
  color: #c2410c;
  background: #fff7ed;
}
.commercials-native-page .commercial-list {
  min-height: 620px;
  padding: 16px;
}
.commercials-native-page .commercial-view-panel {
  border-radius: 12px;
  background: rgba(255,255,255,.62);
}

.ad-offers-station-panel {
  min-height: 520px;
}

.ad-offers-station-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 16px;
  padding: 16px;
  border: 1px solid #fed7aa;
  border-radius: 14px;
  background: linear-gradient(135deg, #fff7ed, rgba(255,255,255,.84));
}

.ad-offers-station-head span {
  display: inline-flex;
  width: max-content;
  margin-bottom: 6px;
  padding: 5px 9px;
  border-radius: 999px;
  color: #9a3412;
  background: #ffedd5;
  font-size: 11px;
  font-weight: 1000;
  text-transform: uppercase;
}

.ad-offers-station-head h2,
.ad-offers-station-head p {
  margin: 0;
}

.ad-offers-station-head p {
  margin-top: 3px;
  color: var(--muted);
  font-weight: 700;
}

.station-ad-offers-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.station-ad-offer-card {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr) 180px;
  gap: 16px;
  align-items: center;
  padding: 14px;
  border: 1px solid #fed7aa;
  border-left: 5px solid #f97316;
  border-radius: 14px;
  background: #fffaf4;
  box-shadow: 0 10px 24px rgba(154, 52, 18, .07);
}

.station-ad-offer-card.is-accepted {
  border-color: #bbf7d0;
  border-left-color: #22c55e;
  background: #f0fdf4;
}

.station-ad-offer-price {
  display: grid;
  gap: 4px;
  padding: 12px;
  border-radius: 12px;
  background: #ffedd5;
  color: #7c2d12;
}

.station-ad-offer-price span,
.station-ad-offer-body span {
  font-size: 10px;
  font-weight: 1000;
  text-transform: uppercase;
}

.station-ad-offer-price strong {
  font-size: 22px;
  letter-spacing: -.03em;
}

.station-ad-offer-body h3,
.station-ad-offer-body p,
.station-ad-offer-body small,
.station-ad-offer-meta b {
  margin: 0;
}

.station-ad-offer-body {
  display: grid;
  gap: 4px;
}

.station-ad-offer-body span {
  color: #c2410c;
}

.station-ad-offer-body h3 {
  color: #162235;
  font-size: 18px;
}

.station-ad-offer-body p,
.station-ad-offer-body small {
  color: var(--muted);
  font-weight: 700;
}

.station-ad-offer-meta {
  display: grid;
  gap: 8px;
  justify-items: end;
}

.station-ad-offer-meta em,
.offer-accept-button {
  width: max-content;
  padding: 6px 10px;
  border: 0;
  border-radius: 999px;
  color: #9a3412;
  background: #ffedd5;
  font-size: 11px;
  font-style: normal;
  font-weight: 1000;
  text-transform: uppercase;
}

.offer-accept-button {
  min-height: 34px;
  color: white;
  background: #f97316;
  cursor: pointer;
}

.offer-accept-button:disabled {
  color: #166534;
  background: #dcfce7;
  cursor: default;
}

.ad-offer-empty {
  border-color: #fed7aa;
  background: #fff7ed;
  color: #9a3412;
}

@media (max-width: 980px) {
  .station-ad-offer-card {
    grid-template-columns: 1fr;
  }

  .ad-offers-station-head {
    flex-direction: column;
  }

  .station-ad-offer-meta {
    justify-items: start;
  }
}
.commercials-native-page .scheduled-break-list {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}
.commercials-native-page .commercial-event-row {
  grid-template-columns: minmax(148px, 190px) 96px minmax(0, 1fr) auto;
  min-height: 70px;
  padding: 12px 14px;
  border: 1px solid #d8e2ee;
  border-radius: 12px;
  background: rgba(255,255,255,.92);
  box-shadow: 0 8px 22px rgba(15, 35, 54, .055);
}
.commercials-native-page .commercial-event-row:hover {
  border-color: #b7c8dc;
  background: white;
}
.commercials-native-page .commercial-event-row.is-expired {
  background: rgba(248, 250, 252, .82);
  box-shadow: none;
}
.commercials-native-page .commercial-event-row.is-expired:hover {
  background: #f8fafc;
}
.commercials-native-page .event-time-box strong {
  font-size: 13px;
}
.commercials-native-page .event-type-column {
  min-width: 86px;
  background: #e8f2ff;
  color: #155ee8;
}
.commercials-native-page .break-row span {
  color: #1d2735;
}
.commercials-native-page .break-row small {
  color: #66758a;
}
.commercials-native-page .event-actions .ghost-button {
  min-height: 36px;
  border-radius: 10px;
  background: #f8fafc;
}
.commercials-native-page .event-actions [data-delete-commercial-rule] {
  color: #b42318;
  border-color: #ffd0cc;
  background: #fff7f6;
}
.commercials-native-page .event-actions [data-delete-commercial-rule]:hover {
  background: #fee2e2;
  border-color: #fca5a5;
}
.commercials-native-page .commercial-audio-tools input {
  border-radius: 10px;
}
.commercials-native-page .commercial-audio-list label {
  border-radius: 11px;
}
.day-hour-row {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  min-height: 62px;
  border-bottom: 1px solid var(--border);
  background: white;
}
.day-hour-row:last-child {
  border-bottom: 0;
}
.day-hour-row > strong {
  padding: 15px 12px;
  border-right: 1px solid var(--border);
  background: #f8fafc;
  color: var(--muted);
  font-size: 12px;
}
.day-hour-events {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 8px;
  padding: 8px;
}
.commercial-day-column {
  min-width: 150px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #f8fafc;
  overflow: hidden;
}
.commercial-day-column header {
  display: grid;
  gap: 2px;
  padding: 10px 11px;
  border-bottom: 1px solid var(--border);
  background: #fff;
}
.commercial-day-column header strong {
  font-size: 14px;
}
.commercial-day-column header span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: capitalize;
}
.commercial-day-column header em {
  justify-self: start;
  margin-top: 4px;
  border-radius: 999px;
  background: #e9f8f3;
  color: #087a61;
  padding: 3px 8px;
  font-size: 10px;
  font-style: normal;
  font-weight: 950;
}
.commercial-day-events {
  display: grid;
  gap: 7px;
  max-height: 390px;
  overflow-y: auto;
  padding: 9px;
}
.week-event-chip {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 3px 7px;
  width: min(260px, 100%);
  border: 1px solid var(--break-soft, #e2e8f0);
  border-left: 4px solid var(--break-color, #64748b);
  border-radius: 9px;
  background: #fff;
  color: var(--text);
  padding: 8px;
  text-align: left;
  cursor: pointer;
}
.week-event-chip b {
  color: var(--break-color, #475569);
  font-size: 12px;
}
.week-event-chip span {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 12px;
  font-weight: 900;
}
.week-event-chip i {
  grid-column: 2;
  color: var(--muted);
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
  text-transform: uppercase;
}
.week-event-chip.type-commercial,
.week-event-chip.type-jingle,
.week-event-chip.type-fx,
.week-event-chip.type-sweeper,
.week-event-chip.type-voice_track {
  --break-soft: #e2e8f0;
}
.week-event-chip.type-commercial {
  --break-color: #14b8a6;
  --break-soft: #ccfbf1;
}
.week-event-chip.type-jingle {
  --break-color: #8b5cf6;
  --break-soft: #ede9fe;
}
.week-event-chip.type-fx {
  --break-color: #f43f5e;
  --break-soft: #ffe4e6;
}
.week-event-chip.type-sweeper {
  --break-color: #3b82f6;
  --break-soft: #dbeafe;
}
.week-event-chip.type-voice_track {
  --break-color: #f59e0b;
  --break-soft: #fef3c7;
}
.week-more-chip,
.day-empty,
.week-grid-empty {
  border-radius: 9px;
  background: var(--surface-2);
  color: var(--muted);
  padding: 10px;
  font-size: 12px;
  font-weight: 800;
}
.week-grid-empty {
  grid-column: 1 / -1;
}

@media (max-width: 1120px) {
  .app-shell { grid-template-columns: 220px minmax(0, 1fr); }
  .app-shell.single-workspace { grid-template-columns: 220px minmax(0, 1fr); }
  .inspector { grid-column: 1 / -1; border-left: 0; border-top: 1px solid var(--border); }
  .pads-grid { grid-template-columns: repeat(2, minmax(120px, 1fr)); }
  .upload-fields { grid-template-columns: repeat(2, minmax(120px, 1fr)); }
  .studio-grid,
  .commercial-board,
  .playlist-builder,
  .list-admin-grid,
  .pad-admin-grid { grid-template-columns: 1fr; }
  .studio-status-row { grid-template-columns: 1fr; }
  body.sidebar-collapsed .app-shell,
  body.sidebar-collapsed .app-shell.single-workspace,
  .app-shell,
  .app-shell.single-workspace { grid-template-columns: 220px minmax(0, 1fr); }
}
@media (max-width: 760px) {
  .app-shell { display: block; }
  body.sidebar-collapsed .app-shell,
  body.sidebar-collapsed .app-shell.single-workspace { display: block; }
  .sidebar {
    min-height: auto;
    padding: 14px;
    gap: 12px;
  }
  .brand-mark {
    width: 40px;
    height: 40px;
  }
  .nav-list {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 2px;
  }
  .nav-item {
    flex: 0 0 auto;
    padding: 10px 12px;
    white-space: nowrap;
  }
  .sidebar-card { display: none; }
  .topbar, .schedule-tools, .pads-header, .pads-actions { align-items: flex-start; flex-direction: column; }
  .onair { width: 100%; }
  .workspace, .inspector { padding: 16px; }
  .form-grid { grid-template-columns: 1fr; }
  .pads-grid { grid-template-columns: 1fr; }
  .player-controls label { margin-left: 0; }
  .playlist-choice { grid-template-columns: 1fr; }
  .playlist-choice em { justify-self: start; }
  .library-header, .upload-actions { align-items: flex-start; flex-direction: column; }
  .upload-fields, .library-tools { grid-template-columns: 1fr; }
  .playlist-create { grid-template-columns: 1fr; }
  .recipe-tools { grid-template-columns: 1fr; }
}
.auth-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 18% 12%, rgba(20, 184, 166, 0.18), transparent 30%),
    linear-gradient(135deg, #071018 0%, #08262a 48%, #04100f 100%);
}

.auth-shell {
  width: min(460px, calc(100% - 32px));
}

.auth-card {
  display: grid;
  gap: 18px;
  padding: 28px;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 28px 72px rgba(0, 0, 0, 0.34);
}

.auth-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.auth-brand .auth-signal {
  width: 44px;
  min-width: 44px;
}

.auth-brand .auth-signal i {
  background: #2dd4bf;
}

.auth-brand div,
.auth-card form {
  display: grid;
  gap: 4px;
}

.auth-brand small,
.auth-card p {
  color: #64748b;
}

.auth-card h1 {
  margin: 0 0 4px;
}

.auth-card form {
  gap: 14px;
}

.auth-error {
  padding: 12px;
  border-radius: 8px;
  background: #fff1f2;
  color: #be123c;
  font-weight: 700;
}

.auth-link {
  color: #0f766e;
  font-weight: 800;
  text-align: center;
  text-decoration: none;
}

.backoffice-login .auth-card {
  border-color: rgba(45, 212, 191, 0.28);
}

.persistent-system a {
  color: #cbd5e1;
  font-size: 12px;
  text-decoration: none;
}

.dashboard-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.dashboard-metrics article,
.dashboard-card {
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
}

.dashboard-metrics article {
  display: grid;
  gap: 4px;
  padding: 18px;
}

.dashboard-metrics strong {
  font-size: 28px;
}

.dashboard-metrics span,
.dashboard-card p {
  color: var(--muted);
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.dashboard-card {
  padding: 18px;
}

.rank-list {
  display: grid;
  margin-top: 14px;
}

.rank-list div {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  border-top: 1px solid var(--border);
}

.rank-list b {
  color: var(--muted);
}

.rank-list em {
  border-radius: 999px;
  background: #eefcf8;
  color: #08765f;
  padding: 5px 9px;
  font-style: normal;
  font-weight: 800;
}

@media (max-width: 900px) {
  .dashboard-metrics,
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
}

/* Native desktop polish */
body {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

:root {
  --bg: #eef2f5;
  --surface: #ffffff;
  --surface-2: #f7f9fb;
  --text: #1d1d1f;
  --muted: #6e6e73;
  --border: #d7dce3;
  --navy: #101820;
  --teal: #00a99d;
  --amber: #ff9f0a;
  --red: #ff453a;
  --blue: #0a84ff;
  --violet: #bf5af2;
  --shadow: 0 10px 26px rgba(0, 0, 0, .09);
}

body.persistent-console {
  background: #101820;
}

.broadcast-bar {
  min-height: 116px;
  padding: 16px 24px;
  gap: 18px;
  background:
    radial-gradient(circle at 10% 0%, rgba(48, 209, 88, .14), transparent 28%),
    linear-gradient(135deg, #123234 0%, #111c2a 44%, #0c1420 100%);
  box-shadow: 0 10px 26px rgba(0, 0, 0, .28);
}

.broadcast-brand strong {
  font-size: 20px;
  font-weight: 720;
  letter-spacing: -.015em;
}

.broadcast-brand span,
.broadcast-now span,
.broadcast-now small,
.broadcast-next span,
.broadcast-next small,
.broadcast-clock span,
.broadcast-controls span {
  font-weight: 600;
}

.live-badge {
  min-height: 45px;
  border-radius: 10px;
  font-weight: 750;
}

.broadcast-now strong,
.broadcast-next strong {
  font-weight: 720;
}

.broadcast-vu span {
  color: #f3f7fb;
  font-weight: 700;
  text-transform: none;
  letter-spacing: 0;
}

.broadcast-meter i {
  background: rgba(48, 209, 88, .3);
}

.broadcast-bar.is-playing .broadcast-meter i {
  background: linear-gradient(180deg, #6bf07e, #30d158);
}

.broadcast-controls input,
.audio-seek-bar {
  accent-color: #30d158;
}

.broadcast-clock strong {
  font-size: 28px;
  font-weight: 650;
  letter-spacing: -.03em;
}

.broadcast-user {
  border-radius: 12px;
}

.broadcast-user span {
  background: #2e445f;
}

.persistent-layout {
  grid-template-columns: 166px minmax(0, 1fr);
}

.persistent-sidebar {
  padding: 18px 14px;
  background: linear-gradient(180deg, #121d28 0%, #0a111b 100%);
}

.persistent-sidebar a {
  gap: 11px;
  min-height: 42px;
  padding: 0 13px;
  border-radius: 10px;
  color: #c8d8ea;
  font-size: 13px;
  font-weight: 650;
}

.persistent-sidebar a svg {
  flex: 0 0 21px;
  width: 21px;
  height: 21px;
  color: #9db2c8;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: color .16s ease, transform .16s ease;
}

.persistent-sidebar a span {
  display: block;
  overflow: visible;
  width: auto;
  min-width: 0;
  color: inherit;
  font-size: inherit;
  white-space: nowrap;
}

.persistent-sidebar a.active,
.persistent-sidebar a:hover {
  background: rgba(255,255,255,.12);
}

.persistent-sidebar a.active svg,
.persistent-sidebar a:hover svg {
  color: #30d158;
}

.persistent-sidebar a:hover svg {
  transform: translateY(-1px);
}

.persistent-sidebar a.active {
  box-shadow: inset 3px 0 0 #30d158;
}

.persistent-system {
  border-radius: 12px;
  background: rgba(255,255,255,.08);
}

.persistent-system span {
  color: #30d158;
  font-weight: 700;
}

.persistent-workspace,
.persistent-workspace iframe,
body.embedded-page {
  background:
    linear-gradient(180deg, rgba(255,255,255,.58), rgba(255,255,255,0) 190px),
    #eef2f5;
}

body.embedded-page .workspace {
  padding: 20px 22px 22px;
}

h1 {
  color: #1d1d1f;
  font-size: 29px;
  font-weight: 700;
  letter-spacing: -.035em;
}

h2 {
  letter-spacing: -.025em;
}

.topbar p,
.inspector p {
  color: #6e6e73;
  font-size: 15px;
}

.onair,
.studio-status,
.commercials-panel,
.player-panel,
.library-panel,
.pads-panel,
.pad-admin-card,
.scheduler-panel,
.event-form,
.playlist-builder,
.playlist-home-view,
.standalone-form-panel,
.builder-panel,
.settings-card,
.dashboard-metrics article,
.dashboard-card,
.microprogram-list,
.stations-panel,
.station-create-card,
.commercial-view-panel {
  border-color: #d7dce3;
  border-radius: 12px;
  box-shadow: 0 10px 26px rgba(0, 0, 0, .09);
}

.onair,
.studio-status,
.commercials-panel,
.player-panel,
.library-panel,
.scheduler-panel,
.event-form,
.playlist-builder,
.playlist-home-view,
.standalone-form-panel,
.builder-panel,
.settings-card,
.dashboard-metrics article,
.dashboard-card,
.commercial-view-panel {
  background: rgba(255,255,255,.94);
}

.studio-status {
  padding: 14px 16px;
}

.studio-status strong,
.onair span,
.commercials-header span,
.player-now span,
.library-header span,
.pads-header span,
.settings-card label,
.upload-fields label,
.event-form label,
.commercial-form label,
.builder-label,
.schedule-modes legend,
.auto-cue-panel-head > strong {
  color: #6e6e73;
  font-weight: 650;
}

.studio-status span {
  font-weight: 700;
}

.on-air-box {
  border-color: rgba(0, 169, 157, .65);
  background: linear-gradient(135deg, #ecfdf5, #f8fffc);
  box-shadow: 0 0 0 3px rgba(0, 169, 157, .08), 0 10px 26px rgba(0,0,0,.08);
}

.on-air-box strong,
.on-air-box span,
.on-air-box .on-air-elapsed {
  color: #064e3b;
}

.vumeter i,
.on-air-box.is-playing .vumeter i {
  background: #30d158;
}

.studio-grid {
  grid-template-columns: minmax(280px, 20%) minmax(620px, 1fr) minmax(320px, 23%);
}

.commercial-break-card strong {
  font-size: 14px;
  font-weight: 700;
}

.break-card-top em,
.break-time-pill,
.break-card-meta b,
.break-card-meta i,
.auto-cue-pill,
.audio-type-pill {
  font-weight: 700;
}

.player-now strong,
.library-table strong,
.track-row strong,
.pad-button strong,
.dashboard-metrics strong,
.dashboard-card h2 {
  font-weight: 720;
}

.type-button,
.primary-button,
.ghost-button,
.library-tabs button,
.library-pagination button,
.tiny-action,
.transport-button,
.manual-playlist-button {
  border-radius: 10px;
  font-weight: 700;
}

.ghost-button,
.library-tabs button,
.library-pagination button,
.tiny-action {
  border-color: #d7dce3;
  background: #fff;
  color: #1d1d1f;
}

.primary-button {
  background: #0a84ff;
}

.transport-button span {
  border-radius: 9px;
}

.library-header,
.commercials-header,
.pads-header,
.player-now,
.player-controls,
.playlist-refresh-notice,
.modal-header,
.builder-header-row,
.auto-cue-panel {
  border-color: #d7dce3;
}

.library-tabs,
.library-tools,
.upload-form,
.queue-head,
.schedule-tools {
  background: #f7f9fb;
}

.drop-zone,
.library-tabs button,
.playlist-choice,
.track-row,
.auto-cue-list label,
.commercial-audio-list label,
.pad-admin-card input,
.pad-admin-card select,
.settings-card input,
.settings-card select,
.settings-card textarea,
.upload-fields input,
.upload-fields select,
.library-tools input,
.library-tools select,
.event-form input,
.event-form select,
.event-form textarea,
.commercial-form input,
.commercial-form select,
.playlist-create-modal input,
.builder-label select,
.standalone-playlist-form input,
.playlist-create input {
  border-radius: 10px;
}

.library-table th {
  color: #6e6e73;
  font-weight: 700;
}

.library-table td {
  color: #4f5969;
}

.pads-panel {
  background: #111c2a;
  border-color: #111c2a;
}

.pad-button {
  border-radius: 12px;
}

.pad-button strong {
  font-size: 16px;
}

.pad-button span {
  font-weight: 650;
}

.schedule-page .day-head,
.schedule-page .time-cell,
.schedule-page .slot {
  border-color: #d7dce3;
}

.schedule-page .event-card,
.event-card {
  border-radius: 10px;
  box-shadow: none;
}

.schedule-page .event-card strong,
.event-card strong {
  font-weight: 720;
}
