:root {
  --primary: #007bff;
  --bg-dark: #0a0a0a;
  --bg-card: #1b1b1b;
  --text: #ffffff;
  --text-muted: #aaa;
  --border: rgba(255,255,255,0.1);
  --live-color: #4CAF50;
  --favorite-color: #FFD700;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background: var(--bg-dark);
  color: var(--text);
  line-height: 1.6;
}

#app {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 0px;
}

/* Header */
header {
  margin-bottom: 20px;
  text-align: center;
}

h1 {
  color: var(--primary);
  font-size: 2.5rem;
  margin-bottom: 10px;
}

.header-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.date-nav {
  display: flex;
  align-items: center;
  gap: 15px;
}

.nav-btn {
  background: var(--primary);
  color: var(--text);
  border: none;
  padding: 8px 16px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 24px;
  font-weight: bold;
  transition: background 0.2s;
}

.nav-btn:hover {
  background: #0056b3;
}

#currentDate {
  font-size: 16px;
  font-weight: 600;
  min-width: 200px;
}

/* Tabs */
.tabs-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-bottom: 20px;
  padding: 12px 20px;
  /*background: var(--bg-card);
  */
  border-radius: 12px;
  flex-wrap: wrap;
  border-bottom: 2px solid rgba(255,255,255,0.2);
}

.tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  overflow-x: auto;
  align-items: center;
}

.guide-tab {
  background: rgba(255,255,255,0.08);
  border: none;
  color: #aaa;
  padding: 10px 20px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.2s;
  white-space: nowrap;
  width: 90px;
}

.guide-tab:hover {
  background: rgba(255,255,255,0.12);
  color: var(--text);
}

.guide-tab.active {
  background: #dc3545;
  color: var(--text);
}

.filter-toggle {
  display: flex;
  gap: 4px;
  /*background: rgba(255,255,255,0.05);*/

  padding: 4px;
  border-radius: 6px;
}

.filter-btn {
  background: transparent;
  border: none;
  color: #aaa;
  padding: 6px 16px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  transition: all 0.2s;
  white-space: nowrap;
}

.filter-btn:hover {
  color: var(--text);
}

.filter-btn.active {
  background: var(--primary);
  color: var(--text);
}

/* Content */
.loading,
.no-games {
  text-align: center;
  padding: 40px 20px;
  font-size: 16px;
  color: #888;
}

.hidden {
  display: none !important;
}

.content {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding: 8px;
  width: 100%;
}

/* Game Cards */
.guide-game {
  padding: 6px 10px;
  background: rgba(255,255,255,0.03);
  border-radius: 8px;
  border-left: 4px solid #dc3545;
  display: flex;
  flex-direction: column;
  gap: 4px;
  width: 100%;
}

.guide-game.state-live {
  background: #ffffff;
  color: #333;
}

.guide-game.state-live .guide-game-status,
.guide-game.state-live .guide-team-name {
  color: #333;
}

.guide-game.state-completed {
  background: #333;
}

.guide-game.state-upcoming {
  background: rgba(255,255,255,0.05);
}

.guide-game.has-favorite {
  border-left-color: #dc3545;
}

.guide-game-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  gap: 8px;
}

.guide-game-status {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
}

.guide-game-status.live-status {
  color: var(--text);
}

.guide-team-channel {
  font-size: 12px;
  color: #aaa;
  background: rgba(255,255,255,0.05);
  padding: 3px 6px;
  border-radius: 4px;
  white-space: nowrap;
  flex-shrink: 0;
}

.guide-team-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.team-star {
  cursor: pointer;
  font-size: 16px;
  color: #666;
  transition: color 0.2s;
  user-select: none;
  flex-shrink: 0;
}

.team-star:hover {
  color: #888;
}

.team-star.favorite {
  color: #FFD700;
}

.guide-team-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  flex: 1;
  min-width: 0;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.guide-team-score {
  font-size: 18px;
  font-weight: bold;
  color: var(--primary);
  width: 35px;
  text-align: right;
  flex-shrink: 0;
}

.guide-team-score.score-winner {
  color: #007bff;
}

.guide-team-score.score-loser {
  color: #666666;
}

/* Responsive */
@media (min-width: 1000px) {
  .guide-game {
    width: calc(33.333% - 8px);
  }
}

@media (min-width: 700px) and (max-width: 999px) {
  .guide-game {
    width: calc(50% - 6px);
  }
}

@media (max-width: 699px) {
  .guide-game {
    width: 100%;
  }
}

@media (max-width: 768px) {
  h1 {
    font-size: 2rem;
  }

  .tabs-container {
    flex-direction: column;
    align-items: stretch;
  }

  .tabs {
    justify-content: center;
  }

  .filter-toggle {
    justify-content: center;
  }
}
