@import url('style.css');

:root {
  --live-bg: #0d0d0d;
  --live-surface: #1f1f1f;
  --live-card: #161616;
  --live-border: #2b2b2b;
  --live-accent: #ff4d4d;
  --live-accent-alt: #d43d3d;
  --live-text: #f5f5f5;
  --live-muted: #c7c7c7;
}

body {
  margin: 0;
  background: radial-gradient(circle at top right, rgba(255, 77, 77, 0.14), transparent 55%), var(--live-bg);
  color: var(--live-text);
}

main.live-page {
  width: min(1080px, 92%);
  margin: 106px auto 64px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.live-header-card {
  background: linear-gradient(165deg, #242428, #1c1c21);
  border: 1px solid #32323a;
  border-radius: 16px;
  padding: 18px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.35);
}

#live-title {
  margin: 0;
  font-size: clamp(1.6rem, 4.8vw, 2.1rem);
  line-height: 1.15;
}

.live-subtitle {
  margin: 6px 0 0;
  color: var(--live-muted);
  font-size: 0.95rem;
}

.status-pill,
.status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid #3a3a43;
  background: #222228;
  color: #f0f0f0;
  font-size: 0.76rem;
  letter-spacing: 0.7px;
  font-weight: 700;
  text-transform: uppercase;
}

.status-checking {
  color: #d6d6d6;
}

.status-live {
  background: rgba(255, 77, 77, 0.2);
  border-color: rgba(255, 77, 77, 0.46);
  color: #ff9d9d;
}

.status-standby {
  background: rgba(245, 165, 36, 0.2);
  border-color: rgba(245, 165, 36, 0.36);
  color: #ffd28e;
}

.status-offline {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.12);
  color: var(--live-muted);
}

.info-card,
#live-content,
#drivers-container {
  background: var(--live-surface);
  border: 1px solid var(--live-border);
  border-radius: 14px;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.26);
}

.info-card,
#live-content {
  padding: 14px;
}

.hero-meta {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.meta-item {
  background: var(--live-card);
  border: 1px solid var(--live-border);
  border-radius: 10px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-height: 84px;
}

.meta-label {
  color: var(--live-muted);
  text-transform: uppercase;
  font-size: 0.72rem;
  letter-spacing: 0.9px;
}

.meta-value {
  color: var(--live-text);
  font-size: 1.02rem;
  font-weight: 700;
}

.loading-screen p,
.live-message,
#live-content p {
  margin: 0;
  color: var(--live-muted);
  line-height: 1.45;
}

.live-message.warning {
  color: #ffd28e;
}

.inline-actions {
  margin-top: 12px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

#class-filter {
  min-width: 150px;
  border-radius: 10px;
  border: 1px solid var(--live-border);
  background: #121217;
  color: var(--live-text);
  padding: 9px 11px;
  margin-left: 8px;
}

#live-content label {
  color: var(--live-muted);
  font-size: 0.87rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.login-btn,
.signup-btn,
.subscribe-btn,
.schedule-btn,
.live-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 10px;
  padding: 10px 14px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.login-btn,
.signup-btn,
.subscribe-btn,
.schedule-btn,
.live-btn.play {
  background: var(--live-accent);
  color: #fff;
}

.login-btn:hover,
.signup-btn:hover,
.subscribe-btn:hover,
.schedule-btn:hover,
.live-btn.play:hover {
  background: var(--live-accent-alt);
  box-shadow: 0 8px 18px rgba(140, 19, 19, 0.4);
  transform: translateY(-1px);
}

.live-btn.locked {
  background: #2a2a31;
  color: var(--live-muted);
  border-color: #3a3a43;
  cursor: not-allowed;
}

#drivers-container {
  padding: 0;
  overflow: hidden;
}

.drivers-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.drivers-row {
  display: grid;
  grid-template-columns: 58px minmax(120px, 1.6fr) minmax(100px, 1fr) minmax(92px, 0.9fr) minmax(94px, 0.95fr);
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-top: 1px solid var(--live-border);
}

.drivers-row.header {
  border-top: 0;
  background: #24242a;
  color: #d8d8de;
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.85px;
}

.drivers-row:not(.header):nth-child(odd) {
  background: #1b1b20;
}

.drivers-row:not(.header):hover {
  background: #25252c;
}

.num-badge {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  border: 1px solid var(--live-border);
  background: #23232a;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.num-logo {
  width: 36px;
  height: 36px;
  object-fit: contain;
}

.num-fallback {
  color: #fff;
  font-weight: 800;
  font-size: 0.92rem;
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 9px;
  border-radius: 999px;
  border: 1px solid rgba(255, 77, 77, 0.35);
  background: rgba(255, 77, 77, 0.12);
  color: #ffc0c0;
  font-size: 0.72rem;
  font-weight: 700;
  white-space: nowrap;
}

.icecast-uptime {
  margin: 0 2px 2px;
  color: var(--live-muted);
  font-size: 0.84rem;
}

@media (max-width: 980px) {
  .hero-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .drivers-row {
    grid-template-columns: 54px minmax(120px, 1fr) minmax(84px, 0.75fr) minmax(92px, 0.9fr);
  }

  .col-hometown {
    display: none;
  }
}

@media (max-width: 680px) {
  main.live-page {
    width: 94%;
    margin-top: 92px;
    gap: 12px;
  }

  .live-header-card {
    flex-direction: column;
    align-items: flex-start;
    padding: 14px;
  }

  .hero-meta {
    grid-template-columns: 1fr;
  }

  .drivers-row {
    grid-template-columns: 48px 1fr 86px;
    gap: 8px;
    padding: 10px;
  }

  .drivers-row > :nth-child(4) {
    display: none;
  }

  .drivers-row.header > :nth-child(4) {
    display: none;
  }

  .drivers-row > :nth-child(3) {
    text-align: right;
  }

  .drivers-row.header {
    font-size: 0.7rem;
  }

  .login-btn,
  .signup-btn,
  .subscribe-btn,
  .schedule-btn,
  .live-btn {
    width: 100%;
  }

  .inline-actions {
    width: 100%;
  }
}
