:root {
  --bg: #0b0f13;
  --card: #12171d;
  --muted: #8fa0b2;
  --text: #e7eef6;
  --accent: #4cc38a;
  --accent-2: #3e63dd;
  --danger: #ef4444;
}

#agendaFrame {
  margin: auto;
}

* {
  box-sizing: border-box;
}

a {
  color: white;
}

html,
body {
  height: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}

.container {
  width: 90%;
  margin: 0 auto;
  padding: 16px;
}
.container-agenda {
  width: 60%;
  margin: 0 auto;
  padding: 16px;
}

.site-header {
  z-index: 20;
  background: rgba(11, 15, 19, 0.8);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid #1e2630;
}

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

.brand .logo {
  font-size: 20px;
}

.brand h1 {
  font-size: 32px;
  margin: 0;
  font-weight: 700;
}

.site-nav a {
  color: var(--muted);
  text-decoration: none;
  margin-left: 16px;
}

.site-nav a.active {
  color: var(--text);
  font-weight: 600;
}

.intro {
  margin: 12px 0 8px;
}

.intro h2 {
  margin: 0 0 4px 0;
  font-size: 22px;
}

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

.day-banner {
  width: 100%;
  background: #032d56;
  color: #e9ffef;
  padding: 10px 12px;
  border-radius: 10px;
  font-weight: 700;
}

.agenda {
  display: grid;
  gap: 16px;
}

.competition {
  background: var(--card);
  border: 1px solid #1e2630;
  border-radius: 12px;
  overflow: hidden;
}

.competition-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border-bottom: 1px solid #1e2630;
  background: #10151b;
}

.competition-title {
  font-weight: 700;
}

.competition-country {
  color: var(--muted);
  font-size: 12px;
}

.matches {
  padding: 8px;
  display: grid;
  gap: 8px;
}

.agenda.compact .match-card {
  display: grid;
  grid-template-columns: 64px 1fr auto;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  border: 1px solid #1e2630;
  border-radius: 10px;
  background: #0e1318;
  cursor: pointer;
}

.time-col {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}

.time-badge {
  background: #0b1015;
  border: 1px solid #2b3546;
  color: #d3dfed;
  font-weight: 700;
  font-size: 11px;
  padding: 1px 6px;
  border-radius: 6px;
}

.status.badge {
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 999px;
  border: 1px solid #293142;
  color: #a8b3c5;
  background: #0c1116;
}

.match-main {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.teams {
  font-weight: 600;
}

.meta {
  color: var(--muted);
  font-size: 12px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.status {
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid #293142;
  color: #a8b3c5;
  font-size: 11px;
}

.actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn {
  appearance: none;
  border: 1px solid #2b3546;
  background: #151b23;
  color: var(--text);
  padding: 6px 10px;
  border-radius: 8px;
  cursor: pointer;
}

.btn.primary {
  border-color: transparent;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.dropdown {
  margin-top: 6px;
  display: none;
  gap: 8px;
  align-items: center;
  grid-column: 1 / -1;
}

.dropdown.open {
  display: block;
}

.dropdown select {
  background: #0f141a;
  border: 1px solid #2b3546;
  color: var(--text);
  padding: 8px 10px;
  border-radius: 8px;
}

/* Lista de canales (dropdown tipo menú) */
.channel-menu {
  list-style: none;
  padding: 0;
  margin: 6px 0 0 0;
  display: grid;
  gap: 6px;
}

.channel-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 10px;
  background: #0f141a;
  border: 1px solid #2b3546;
  border-radius: 8px;
  cursor: pointer;
}

.channel-item:hover {
  border-color: #3552a3;
}

.channel-item .left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.play-icon {
  width: 0;
  height: 0;
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
  border-left: 10px solid #2c3e50;
}

.channel-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 8px;
  border: 1px solid #2b3546;
  border-radius: 999px;
  font-size: 11px;
  color: #bdc9d7;
}

.agenda.compact .channel-pill {
  font-size: 0;
  padding: 0;
  border: none;
}

.channel-logos {
  display: flex;
  align-items: center;
  gap: 6px;
}

.channel-pill img {
  width: 18px;
  height: 18px;
  border-radius: 4px;
  display: block;
}

.site-footer {
  border-top: 1px solid #1e2630;
  margin-top: 24px;
  color: var(--muted);
}

.site-footer a {
  color: var(--muted);
}

/* Transmisión layout */
.layout-player {
  display: grid;
  grid-template-columns: 2fr .75fr;
  gap: 12px;
}

.player-card,
.chat-card {
  background: var(--card);
  border: 1px solid #1e2630;
  border-radius: 12px;
  overflow: hidden;
}

.card-header {
  padding: 10px 12px;
  border-bottom: 1px solid #1e2630;
  background: #10151b;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.card-body {
  padding: 12px;
}

.card-body iframe {
  width: 100%;
  height: 62vh;
  border: 0;
  border-radius: 8px;
  background: #000;
}

.option-select {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.option-select select {
  background: #0f141a;
  border: 1px solid #2b3546;
  color: var(--text);
  padding: 8px 10px;
  border-radius: 8px;
}

.channel-head {
  display: flex;
  align-items: center;
  gap: 8px;
}

.channel-head img {
  width: 20px;
  height: 20px;
  border-radius: 4px;
}

.channel-head .name {
  font-weight: 600;
}

@media (max-width: 900px) {
  .layout-player {
    grid-template-columns: 1fr;
  }

  .card-body iframe {
    height: 48vh;
  }
}

/* Canales grid */
.channels-section {
  margin-top: 20px;
}

.section-title {
  margin: 8px 0 8px;
  font-size: 16px;
  color: #bcd0e6;
}

.channels-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 12px;
}

.channel-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  background: var(--card);
  border: 1px solid #1e2630;
  border-radius: 10px;
  cursor: pointer;
}

.channel-card img {
  width: 28px;
  height: 28px;
  border-radius: 6px;
}

.channel-card .name {
  font-weight: 600;
  font-size: 14px;
}