/* NFL Live Feeds Styling */

.nfl-games-section {
  padding: 40px 0;
}

.games-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  flex-wrap: wrap;
  gap: 15px;
}

.games-header h2 {
  font-size: clamp(28px, 3vw, 40px);
  margin: 0;
}

.refresh-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: var(--acc);
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.3s ease;
}

.refresh-btn:hover {
  background: #00a65a;
  transform: translateY(-2px);
}

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

.refresh-icon {
  display: inline-block;
  transition: transform 0.5s ease;
}

.refresh-btn.loading .refresh-icon {
  animation: spin 1s linear infinite;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* Games Grid */
#nflGamesContainer {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
  gap: 20px;
}

/* Game Card */
.game-card {
  background: var(--card-bg);
  border: 2px solid var(--border);
  border-radius: 16px;
  padding: 20px;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px var(--shadow);
}

.game-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 16px var(--shadow);
}

.game-card.live {
  border-color: var(--acc);
  box-shadow: 0 0 20px rgba(0, 184, 107, 0.3);
}

/* Game Header */
.game-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 15px;
  border-bottom: 1px solid var(--border);
}

.game-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
}

/* Status Badges */
.status-badge {
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.status-badge.live {
  background: #E63946;
  color: white;
  animation: pulse-badge 2s ease-in-out infinite;
}

.status-badge.final {
  background: var(--text-d);
  color: white;
}

.status-badge.scheduled {
  background: var(--acc-2);
  color: white;
}

@keyframes pulse-badge {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

/* Game Body */
.game-body {
  margin-bottom: 15px;
}

.team-row {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 15px;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}

.team-row:last-child {
  border-bottom: none;
}

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

.team-logo {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.team-name {
  font-size: 18px;
  font-weight: 700;
  font-family: 'Bebas Neue', sans-serif;
  letter-spacing: 0.5px;
}

.team-score {
  font-size: 32px;
  font-weight: 800;
  font-family: 'Bebas Neue', sans-serif;
  color: var(--acc);
  min-width: 50px;
  text-align: center;
}

/* Quarter Scores */
.quarter-scores {
  display: flex;
  gap: 8px;
}

.quarter-scores span {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-d);
}

/* Game Clock */
.game-clock {
  text-align: center;
  padding: 10px;
  background: rgba(230, 57, 70, 0.1);
  border-radius: 8px;
  font-weight: 700;
  color: #E63946;
  margin-bottom: 15px;
  font-family: 'Bebas Neue', sans-serif;
  font-size: 18px;
  letter-spacing: 1px;
}

/* Game Actions */
.game-actions {
  display: flex;
  gap: 10px;
  margin-top: 15px;
}

.btn-sm {
  padding: 8px 16px;
  font-size: 13px;
}

/* Loading State */
.loading-games {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-d);
}

.loading-spinner {
  width: 50px;
  height: 50px;
  border: 4px solid var(--border);
  border-top-color: var(--acc);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 20px;
}

/* Empty State */
.no-games {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-d);
}

.no-games-icon {
  font-size: 64px;
  margin-bottom: 20px;
  opacity: 0.5;
}

/* Live Indicator */
.live-indicator {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  color: #E63946;
  text-transform: uppercase;
}

.live-dot {
  width: 8px;
  height: 8px;
  background: #E63946;
  border-radius: 50%;
  animation: pulse-dot 1.5s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.5;
    transform: scale(1.2);
  }
}

/* Filters */
.games-filters {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.filter-btn {
  padding: 8px 16px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-d);
  cursor: pointer;
  transition: all 0.2s ease;
  font-weight: 600;
  font-size: 14px;
}

.filter-btn:hover {
  border-color: var(--acc);
  color: var(--acc);
}

.filter-btn.active {
  background: var(--acc);
  border-color: var(--acc);
  color: white;
}

/* Responsive Design */
@media (max-width: 900px) {
  #nflGamesContainer {
    grid-template-columns: 1fr;
  }

  .team-row {
    grid-template-columns: 1fr auto;
  }

  .quarter-scores {
    grid-column: 1 / -1;
    justify-content: flex-end;
    margin-top: 8px;
  }

  .team-logo {
    width: 32px;
    height: 32px;
  }

  .team-name {
    font-size: 16px;
  }

  .team-score {
    font-size: 28px;
  }
}

@media (max-width: 600px) {
  .games-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .refresh-btn {
    width: 100%;
    justify-content: center;
  }

  .game-card {
    padding: 15px;
  }

  .quarter-scores span {
    width: 28px;
    height: 28px;
    font-size: 12px;
  }

  .game-selector-controls {
    flex-direction: column;
    align-items: stretch;
  }

  .game-selector-controls .btn {
    margin-top: 10px !important;
    width: 100%;
  }

  .selected-game-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .change-game-btn {
    width: 100%;
  }
}

/* Integration with Game Board */
.game-selector-container {
  background: var(--card-bg);
  border: 2px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 20px;
}

.game-selector-header {
  margin-bottom: 20px;
}

.game-selector-header h3 {
  font-size: 20px;
  margin: 0 0 5px 0;
}

.game-selector-controls {
  display: flex;
  gap: 15px;
  align-items: flex-end;
}

.game-select {
  width: 100%;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.2s ease;
}

.game-select:hover {
  border-color: var(--acc);
}

.game-select:focus {
  outline: none;
  border-color: var(--acc);
  box-shadow: 0 0 0 3px rgba(0, 184, 107, 0.1);
}

.game-select option {
  padding: 10px;
}

.selected-game-info {
  background: var(--card-bg);
  border: 2px solid var(--acc);
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 20px;
}

.selected-game-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
}

.selected-game-title {
  font-size: 20px;
  font-weight: 700;
  font-family: 'Bebas Neue', sans-serif;
}

.change-game-btn {
  padding: 6px 12px;
  font-size: 12px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.change-game-btn:hover {
  border-color: var(--acc);
  color: var(--acc);
}