:root {
  color-scheme: dark;
  --bg: #101418;
  --bg-elevated: #151b21;
  --surface: rgba(28, 35, 42, 0.74);
  --surface-strong: rgba(35, 43, 51, 0.92);
  --surface-soft: rgba(255, 255, 255, 0.06);
  --line: rgba(255, 255, 255, 0.12);
  --line-strong: rgba(255, 255, 255, 0.2);
  --text: #f4f7fb;
  --muted: #a9b6c4;
  --muted-2: #7d8996;
  --primary: #63d9b7;
  --primary-ink: #082b23;
  --secondary: #7c91ff;
  --tertiary: #ffb25f;
  --danger: #ff6b7a;
  --warning: #ffd166;
  --success: #45e0a8;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.34);
  --shadow-soft: 0 12px 34px rgba(0, 0, 0, 0.22);
  --radius-xs: 8px;
  --radius-sm: 12px;
  --radius-md: 18px;
  --radius-lg: 24px;
  --sidebar: 280px;
  --ease: cubic-bezier(.2, .8, .2, 1);
  font-family: Inter, "Noto Sans JP", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

:root[data-theme="light"] {
  color-scheme: light;
  --bg: #f4f7f8;
  --bg-elevated: #ffffff;
  --surface: rgba(255, 255, 255, 0.78);
  --surface-strong: rgba(255, 255, 255, 0.94);
  --surface-soft: rgba(0, 0, 0, 0.045);
  --line: rgba(17, 24, 39, 0.12);
  --line-strong: rgba(17, 24, 39, 0.2);
  --text: #142029;
  --muted: #50606d;
  --muted-2: #71808d;
  --primary: #007f68;
  --primary-ink: #e8fff8;
  --secondary: #4056c8;
  --tertiary: #a65b00;
  --danger: #c5263d;
  --shadow: 0 24px 70px rgba(35, 48, 58, 0.14);
  --shadow-soft: 0 12px 34px rgba(35, 48, 58, 0.1);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at 12% 8%, rgba(99, 217, 183, 0.12), transparent 31rem),
    radial-gradient(circle at 88% 2%, rgba(255, 178, 95, 0.12), transparent 34rem),
    linear-gradient(135deg, var(--bg) 0%, #121920 46%, #171719 100%);
  line-height: 1.6;
  letter-spacing: 0;
  overflow-x: hidden;
}

:root[data-theme="light"] body {
  background:
    radial-gradient(circle at 12% 8%, rgba(0, 127, 104, 0.1), transparent 31rem),
    radial-gradient(circle at 88% 2%, rgba(166, 91, 0, 0.1), transparent 34rem),
    linear-gradient(135deg, var(--bg) 0%, #eef4f6 100%);
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  content: "";
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.028) 1px, transparent 1px);
  background-size: 52px 52px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, .86), transparent 86%);
}

body::after {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  content: "";
  backdrop-filter: blur(0.01px);
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
  letter-spacing: 0;
}

button {
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
  opacity: .54;
}

img,
canvas {
  max-width: 100%;
}

.material-symbols-rounded {
  display: inline-flex;
  overflow: hidden;
  width: 1em;
  height: 1em;
  align-items: center;
  justify-content: center;
  font-family: "Material Symbols Rounded";
  font-size: 1.35em;
  font-style: normal;
  font-weight: 500;
  line-height: 1;
  vertical-align: -0.2em;
}

.splash {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-content: center;
  gap: 20px;
  background: var(--bg);
  transition: opacity .55s var(--ease), visibility .55s var(--ease);
}

.splash.is-hidden {
  visibility: hidden;
  opacity: 0;
}

.splash-title {
  margin: 0;
  color: var(--text);
  font-size: 1.35rem;
  font-weight: 800;
  text-align: center;
}

.loading-bar {
  width: 220px;
  height: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--surface-soft);
}

.loading-bar span {
  display: block;
  width: 42%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--primary), var(--secondary), var(--tertiary));
  animation: loading 1.2s infinite var(--ease);
}

@keyframes loading {
  0% { transform: translateX(-90%); }
  100% { transform: translateX(250%); }
}

.app-shell {
  display: grid;
  grid-template-columns: var(--sidebar) minmax(0, 1fr);
  min-height: 100vh;
}

.side-nav {
  position: sticky;
  top: 0;
  display: flex;
  height: 100vh;
  flex-direction: column;
  gap: 26px;
  padding: 24px;
  border-right: 1px solid var(--line);
  background: rgba(13, 17, 22, .72);
  backdrop-filter: blur(22px);
}

:root[data-theme="light"] .side-nav {
  background: rgba(255, 255, 255, .72);
}

.brand {
  display: grid;
  grid-template-columns: 50px 1fr;
  gap: 14px;
  align-items: center;
  min-width: 0;
}

.brand strong,
.brand small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.brand strong {
  font-size: 1rem;
  font-weight: 800;
}

.brand small {
  color: var(--muted);
  font-size: .78rem;
  font-weight: 600;
}

.brand-mark {
  display: inline-grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .18);
  border-radius: 16px;
  color: var(--primary);
  background: linear-gradient(135deg, rgba(99, 217, 183, .18), rgba(124, 145, 255, .16) 52%, rgba(255, 178, 95, .14));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .18), var(--shadow-soft);
}

.brand-mark-large {
  width: 86px;
  height: 86px;
  margin-inline: auto;
  border-radius: 28px;
  font-size: 1.8rem;
}

.nav-list {
  display: grid;
  gap: 8px;
}

.nav-item,
.bottom-nav a {
  display: flex;
  align-items: center;
  color: var(--muted);
  font-weight: 700;
  transition: color .2s var(--ease), background .2s var(--ease), transform .2s var(--ease);
}

.nav-item {
  gap: 12px;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: 18px;
}

.nav-item:hover,
.bottom-nav a:hover {
  color: var(--text);
  background: var(--surface-soft);
}

.nav-item.active,
.bottom-nav a.active {
  color: var(--primary);
  background: rgba(99, 217, 183, .12);
}

.nav-item.active {
  border-color: rgba(99, 217, 183, .2);
}

.nav-footer {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: auto;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  color: var(--muted);
  background: var(--surface-soft);
  font-size: .84rem;
  font-weight: 700;
}

.status-dot {
  position: relative;
  width: 10px;
  height: 10px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 7px rgba(69, 224, 168, .12);
}

.main-content {
  width: min(100%, 1480px);
  margin: 0 auto;
  padding: 28px clamp(18px, 4vw, 44px) 44px;
}

.topbar {
  display: flex;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
}

.topbar h1 {
  margin: 2px 0 0;
  font-size: clamp(2rem, 5vw, 4.4rem);
  font-weight: 850;
  line-height: 1.04;
}

.topbar-actions,
.toolbar,
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.eyebrow {
  margin: 0;
  color: var(--primary);
  font-size: .78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.home-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(320px, .82fr);
  gap: 22px;
  align-items: stretch;
  margin-bottom: 22px;
}

.hero-copy,
.on-air-console,
.panel,
.metric-card,
.action-card {
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(22px);
}

.hero-copy {
  display: flex;
  min-height: 360px;
  flex-direction: column;
  justify-content: center;
  padding: clamp(26px, 6vw, 56px);
  border-radius: var(--radius-lg);
}

.hero-copy h2 {
  max-width: 780px;
  margin: 6px 0 14px;
  font-size: clamp(2rem, 5vw, 4.1rem);
  font-weight: 850;
  line-height: 1.08;
}

.hero-copy p:not(.eyebrow) {
  max-width: 680px;
  margin: 0 0 24px;
  color: var(--muted);
  font-size: 1.05rem;
}

.on-air-console {
  display: flex;
  min-height: 360px;
  flex-direction: column;
  justify-content: space-between;
  padding: 22px;
  border-radius: var(--radius-lg);
  background:
    linear-gradient(160deg, rgba(124, 145, 255, .18), rgba(99, 217, 183, .08)),
    var(--surface);
}

.console-header,
.console-metrics {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.console-header {
  color: var(--muted);
  font-weight: 800;
}

.live-pill {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  color: #fff;
  background: var(--danger);
  font-size: .78rem;
  font-weight: 850;
}

.console-metrics span {
  display: grid;
  min-width: 88px;
  gap: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(0, 0, 0, .18);
}

.console-metrics strong {
  font-size: 1.35rem;
  line-height: 1.1;
}

.console-metrics small {
  color: var(--muted);
  font-weight: 800;
}

.action-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 22px;
}

.action-card {
  display: grid;
  min-height: 174px;
  align-content: start;
  gap: 10px;
  padding: 20px;
  border-radius: var(--radius-lg);
  transition: transform .2s var(--ease), border-color .2s var(--ease), background .2s var(--ease);
}

.action-card:hover {
  transform: translateY(-3px);
  border-color: var(--line-strong);
  background: var(--surface-strong);
}

.action-card .material-symbols-rounded {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  font-size: 1.55rem;
  background: var(--surface-soft);
}

.action-card strong {
  font-size: 1.08rem;
}

.action-card small {
  color: var(--muted);
  font-size: .88rem;
  font-weight: 600;
}

.accent-a .material-symbols-rounded { color: var(--primary); }
.accent-b .material-symbols-rounded { color: var(--secondary); }
.accent-c .material-symbols-rounded { color: var(--tertiary); }
.accent-d .material-symbols-rounded { color: #ff7da7; }
.accent-e .material-symbols-rounded { color: #88d8ff; }

.two-column,
.studio-layout,
.listener-stage,
.scheduler-layout,
.dashboard-grid,
.settings-grid,
.player-layout {
  display: grid;
  gap: 22px;
}

.two-column {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.studio-layout {
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, .65fr);
  align-items: start;
  margin-bottom: 22px;
}

.listener-stage {
  grid-template-columns: minmax(280px, .54fr) minmax(0, 1.2fr);
  align-items: start;
  margin-bottom: 22px;
}

.scheduler-layout {
  grid-template-columns: minmax(0, 1fr) minmax(320px, 390px);
  align-items: start;
}

.dashboard-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-bottom: 22px;
}

.settings-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.player-layout {
  grid-template-columns: minmax(260px, .44fr) minmax(0, 1fr);
  align-items: stretch;
}

.panel {
  border-radius: var(--radius-lg);
  padding: clamp(18px, 3vw, 26px);
}

.wide-panel {
  grid-column: 1 / -1;
}

.section-heading {
  display: grid;
  grid-template-columns: 46px 1fr;
  gap: 14px;
  align-items: start;
  margin-bottom: 20px;
}

.section-heading > .material-symbols-rounded {
  width: 46px;
  height: 46px;
  border: 1px solid var(--line);
  border-radius: 16px;
  color: var(--primary);
  background: var(--surface-soft);
}

.section-heading h2,
.calendar-toolbar h2,
.station-meta h2 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 850;
  line-height: 1.25;
}

.section-heading p,
.station-meta p,
.helper-text {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: .93rem;
}

.field {
  display: grid;
  gap: 8px;
  min-width: 0;
  color: var(--muted);
  font-size: .88rem;
  font-weight: 800;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 16px;
  outline: none;
  color: var(--text);
  background: rgba(0, 0, 0, .18);
  padding: 0 14px;
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease), background .2s var(--ease);
}

:root[data-theme="light"] .field input,
:root[data-theme="light"] .field select,
:root[data-theme="light"] .field textarea {
  background: rgba(255, 255, 255, .72);
}

.field textarea {
  min-height: 168px;
  padding: 14px;
  resize: vertical;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: .9rem;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(99, 217, 183, .14);
}

.field input[type="range"] {
  height: 48px;
  padding: 0;
  border: 0;
  background: transparent;
  accent-color: var(--primary);
}

.station-code input {
  height: 76px;
  font-size: 2rem;
  font-weight: 850;
  text-align: center;
}

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

.control-grid.compact {
  gap: 12px;
}

.control-grid .wide {
  grid-column: 1 / -1;
}

.form-stack {
  display: grid;
  gap: 16px;
}

.check-row {
  display: flex;
  gap: 10px;
  align-items: center;
  min-height: 44px;
  color: var(--muted);
  font-weight: 800;
}

.check-row input {
  width: 20px;
  height: 20px;
  accent-color: var(--primary);
}

.button,
.icon-button,
.quality-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  border: 1px solid transparent;
  font-weight: 850;
  line-height: 1;
  transition: transform .2s var(--ease), border-color .2s var(--ease), background .2s var(--ease), color .2s var(--ease), box-shadow .2s var(--ease);
}

.button {
  gap: 8px;
  min-width: 0;
  padding: 0 18px;
  border-radius: 999px;
}

.button:hover,
.icon-button:hover {
  transform: translateY(-1px);
}

.button.primary {
  color: var(--primary-ink);
  background: var(--primary);
  box-shadow: 0 10px 26px rgba(99, 217, 183, .22);
}

:root[data-theme="light"] .button.primary {
  color: #ffffff;
}

.button.tonal {
  color: var(--primary);
  border-color: rgba(99, 217, 183, .2);
  background: rgba(99, 217, 183, .12);
}

.button.ghost,
.icon-button {
  color: var(--text);
  border-color: var(--line);
  background: var(--surface-soft);
}

.button.danger {
  color: #fff;
  background: var(--danger);
}

.icon-button {
  width: 46px;
  height: 46px;
  flex: 0 0 auto;
  border-radius: 50%;
  padding: 0;
}

.icon-button.large {
  width: 60px;
  height: 60px;
  background: var(--primary);
  color: var(--primary-ink);
  box-shadow: 0 10px 26px rgba(99, 217, 183, .22);
}

:root[data-theme="light"] .icon-button.large {
  color: #ffffff;
}

.quality-chip {
  gap: 8px;
  min-height: 38px;
  padding: 0 12px;
  border-color: var(--line);
  border-radius: 999px;
  color: var(--muted);
  background: var(--surface-soft);
  font-size: .86rem;
}

.quality-chip.is-live,
.quality-chip.good {
  color: var(--primary);
  border-color: rgba(99, 217, 183, .22);
  background: rgba(99, 217, 183, .13);
}

.quality-chip.bad {
  color: var(--danger);
  border-color: rgba(255, 107, 122, .24);
  background: rgba(255, 107, 122, .12);
}

.meter-wrap {
  position: relative;
  display: grid;
  margin-bottom: 18px;
}

.meter-wrap span {
  position: absolute;
  right: 14px;
  bottom: 12px;
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-weight: 800;
}

.level-meter,
.waveform {
  display: block;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .06), rgba(255, 255, 255, .02)),
    rgba(0, 0, 0, .18);
}

.waveform.compact {
  min-height: 150px;
}

.drop-zone {
  display: grid;
  min-height: 246px;
  place-items: center;
  align-content: center;
  gap: 8px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-lg);
  color: var(--muted);
  background: var(--surface-soft);
  text-align: center;
  transition: border-color .2s var(--ease), background .2s var(--ease), transform .2s var(--ease);
}

.drop-zone:hover,
.drop-zone.dragging {
  transform: translateY(-2px);
  border-color: var(--primary);
  background: rgba(99, 217, 183, .12);
}

.drop-zone .material-symbols-rounded {
  color: var(--primary);
  font-size: 2.2rem;
}

.drop-zone strong {
  color: var(--text);
}

.player-controls {
  display: grid;
  gap: 16px;
  align-content: start;
}

.now-playing {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 14px;
  align-items: center;
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface-soft);
}

.now-playing .material-symbols-rounded {
  width: 58px;
  height: 58px;
  border-radius: 16px;
  color: var(--secondary);
  background: rgba(124, 145, 255, .16);
}

.now-playing small,
.station-meta small {
  color: var(--primary);
  font-weight: 850;
}

.now-playing strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.playlist {
  display: grid;
  gap: 10px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
}

.playlist li,
.list-item,
.log-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: center;
  min-width: 0;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface-soft);
}

.playlist li.active {
  border-color: rgba(99, 217, 183, .28);
  background: rgba(99, 217, 183, .12);
}

.drag-handle {
  color: var(--muted-2);
}

.station-id-card {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 12px;
  align-items: center;
  margin: 18px 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(99, 217, 183, .1);
}

.station-id-card span {
  color: var(--muted);
  font-weight: 850;
}

.station-id-card strong {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 2rem;
  letter-spacing: .08em;
}

.qr-code {
  display: block;
  width: 174px;
  height: 174px;
  margin: 0 auto 18px;
  border: 10px solid #fff;
  border-radius: 18px;
  background: #fff;
}

.broadcast-time {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-weight: 850;
}

.radio-player {
  display: grid;
  justify-items: center;
  text-align: center;
}

.station-art {
  display: grid;
  width: min(100%, 230px);
  aspect-ratio: 1;
  place-items: center;
  margin-bottom: 18px;
  border: 1px solid var(--line);
  border-radius: 32px;
  color: var(--primary);
  background:
    linear-gradient(135deg, rgba(99, 217, 183, .22), rgba(124, 145, 255, .2) 54%, rgba(255, 178, 95, .16)),
    var(--surface-soft);
  box-shadow: var(--shadow-soft);
}

.station-art .material-symbols-rounded {
  font-size: 4.6rem;
}

.station-meta {
  width: 100%;
  min-width: 0;
  margin-bottom: 18px;
}

.station-meta h2 {
  margin-top: 4px;
  overflow-wrap: anywhere;
}

.eq-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  align-items: center;
}

.field.vertical {
  justify-items: center;
}

.field.vertical input[type="range"] {
  width: 100%;
}

.list-stack,
.log-list {
  display: grid;
  gap: 10px;
}

.empty {
  margin: 0;
  color: var(--muted);
}

.calendar-toolbar {
  display: grid;
  grid-template-columns: auto 1fr auto auto;
  gap: 12px;
  align-items: center;
  margin-bottom: 18px;
}

.calendar-toolbar h2 {
  text-align: center;
}

.segmented {
  display: inline-flex;
  max-width: 100%;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-soft);
}

.segmented button {
  min-height: 38px;
  min-width: 62px;
  border: 0;
  border-radius: 999px;
  color: var(--muted);
  background: transparent;
  padding: 0 12px;
  font-weight: 850;
}

.segmented button.active {
  color: var(--primary-ink);
  background: var(--primary);
}

:root[data-theme="light"] .segmented button.active {
  color: #ffffff;
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
}

.calendar-day-name {
  padding: 0 8px 6px;
  color: var(--muted);
  font-size: .78rem;
  font-weight: 850;
  text-align: center;
}

.calendar-cell {
  display: grid;
  min-height: 122px;
  align-content: start;
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(0, 0, 0, .12);
}

.calendar-cell.is-muted {
  opacity: .48;
}

.calendar-cell.is-today {
  border-color: rgba(99, 217, 183, .42);
  box-shadow: inset 0 0 0 1px rgba(99, 217, 183, .18);
}

.calendar-cell time {
  color: var(--muted);
  font-size: .84rem;
  font-weight: 850;
}

.event-pill {
  display: block;
  overflow: hidden;
  width: 100%;
  min-height: 28px;
  border-radius: 10px;
  color: var(--text);
  background: rgba(124, 145, 255, .18);
  padding: 5px 8px;
  font-size: .76rem;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.timeline {
  display: grid;
  gap: 10px;
}

.timeline-item {
  display: grid;
  grid-template-columns: 78px 1fr;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface-soft);
}

.timeline-item time {
  color: var(--primary);
  font-weight: 850;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 22px;
}

.metric-card {
  display: grid;
  gap: 8px;
  min-height: 150px;
  align-content: start;
  padding: 18px;
  border-radius: var(--radius-lg);
}

.metric-card .material-symbols-rounded {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  color: var(--primary);
  background: var(--surface-soft);
}

.metric-card small {
  color: var(--muted);
  font-weight: 850;
}

.metric-card strong {
  font-size: clamp(1.5rem, 4vw, 2.2rem);
  font-weight: 850;
  line-height: 1;
}

.chart-panel canvas {
  width: 100%;
  min-height: 260px;
}

.log-item {
  grid-template-columns: auto 1fr auto;
  color: var(--muted);
}

.log-item strong {
  color: var(--text);
}

.storage-meter {
  width: 100%;
  height: 12px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--surface-soft);
}

.storage-meter span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--primary), var(--secondary), var(--tertiary));
}

.bottom-nav {
  position: fixed;
  right: 12px;
  bottom: 12px;
  left: 12px;
  z-index: 50;
  display: none;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 4px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(16, 20, 24, .82);
  box-shadow: var(--shadow);
  backdrop-filter: blur(24px);
}

:root[data-theme="light"] .bottom-nav {
  background: rgba(255, 255, 255, .84);
}

.bottom-nav a {
  min-width: 0;
  flex-direction: column;
  gap: 2px;
  justify-content: center;
  min-height: 58px;
  border-radius: 18px;
  font-size: .75rem;
}

.bottom-nav small {
  overflow: hidden;
  max-width: 100%;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.toast {
  position: fixed;
  right: 20px;
  bottom: 22px;
  z-index: 120;
  max-width: min(420px, calc(100vw - 40px));
  padding: 13px 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  color: var(--text);
  background: var(--surface-strong);
  box-shadow: var(--shadow);
  animation: toast-in .25s var(--ease);
}

@keyframes toast-in {
  from { transform: translateY(12px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

:focus-visible {
  outline: 3px solid rgba(99, 217, 183, .58);
  outline-offset: 3px;
}

@media (max-width: 1180px) {
  .action-grid,
  .metric-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .home-hero,
  .studio-layout,
  .listener-stage,
  .scheduler-layout {
    grid-template-columns: 1fr;
  }

  .broadcast-card {
    order: -1;
  }
}

@media (max-width: 860px) {
  .app-shell {
    display: block;
  }

  .side-nav {
    display: none;
  }

  .main-content {
    padding: 20px 14px 106px;
  }

  .topbar {
    align-items: flex-start;
  }

  .topbar h1 {
    font-size: 2.4rem;
  }

  .topbar-actions {
    justify-content: flex-end;
  }

  .bottom-nav {
    display: grid;
  }

  .home-hero,
  .two-column,
  .dashboard-grid,
  .settings-grid,
  .player-layout {
    grid-template-columns: 1fr;
  }

  .action-grid,
  .metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hero-copy,
  .on-air-console {
    min-height: auto;
  }

  .calendar-toolbar {
    grid-template-columns: auto 1fr auto;
  }

  .calendar-toolbar .segmented {
    grid-column: 1 / -1;
    justify-self: center;
  }

  .calendar-cell {
    min-height: 94px;
    padding: 8px;
  }
}

@media (max-width: 560px) {
  .topbar {
    display: grid;
  }

  .topbar h1 {
    font-size: 2rem;
  }

  .hero-copy h2 {
    font-size: 2rem;
  }

  .action-grid,
  .metric-grid,
  .control-grid {
    grid-template-columns: 1fr;
  }

  .panel,
  .hero-copy,
  .on-air-console {
    border-radius: 20px;
    padding: 18px;
  }

  .station-id-card {
    grid-template-columns: 1fr auto;
  }

  .station-id-card strong {
    grid-column: 1 / -1;
    grid-row: 2;
    font-size: 1.9rem;
  }

  .console-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .console-metrics span {
    min-width: 0;
    padding: 10px;
  }

  .calendar-grid {
    gap: 5px;
  }

  .calendar-cell {
    min-height: 78px;
    border-radius: 12px;
  }

  .event-pill {
    min-height: 22px;
    padding: 3px 5px;
    font-size: .68rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
}
