/* ============================
   GLOBAL DESIGN SYSTEM
============================ */
:root {
    --primary-color: #1E3A8A;
    --accent-color: #F59E0B;
    --secondary-color: #64748B;
    --bg-color: #F9FAFB;
    --font-color: #111827;
}

/* ============================
   BASE STYLES
============================ */
body {
    font-family: 'Inter', 'Arial', sans-serif;
    margin: 0;
    padding: 0;
    background-color: var(--bg-color);
    color: var(--font-color);
}
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem; /* Adds space on both sides */
}

a {
    color: var(--primary-color);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* ============================
   HEADER
============================ */
.header {
    background-color: var(--primary-color);
    color: white;
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header h1 {
    margin: 0;
}

.header .search-bar {
    display: flex;
    align-items: center;
}

.header .search-bar input[type="text"] {
    padding: 5px;
    border: none;
    border-radius: 4px 0 0 4px;
    width: 200px;
}

.header .search-bar button {
    padding: 6px 10px;
    border: none;
    border-radius: 0 4px 4px 0;
    background-color: white;
    color: var(--primary-color);
    cursor: pointer;
}

/* ============================
   NAVIGATION BAR
============================ */
.navbar {
    background-color: white;
    display: flex;
    padding: 10px 20px;
    border-bottom: 1px solid #e2e8f0;
}

.navbar a {
    margin-right: 20px;
    font-weight: 600;
    color: var(--primary-color);
}

.navbar a:hover {
    color: var(--accent-color);
}
.nav-left, .nav-right {
  display: flex;
  align-items: center;
}

.nav-left {
  flex-grow: 1;
}

.nav-right input {
  padding: 6px 10px;
  border: 1px solid #ccc;
  border-radius: 5px;
}

/* Side Navigation Bar (subnav) */
.subnav {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  background: #e0e0e0;
  padding: 10px;
  position: sticky;
  top: 0;
  z-index: 10;
}

.subnav button {
  background: #004080;
  color: white;
  padding: 0.5rem 1rem;
  border: none;
  cursor: pointer;
  border-radius: 4px;
}

/* Dropdowns */
.dropdown {
  position: relative;
  display: inline-block;
}

.dropdown-content {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background-color: white;
  border: 1px solid #ccc;
  padding: 10px;
  z-index: 100;
  border-radius: 4px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.dropdown-content a {
  display: block;
  margin: 5px 0;
  color: var(--primary-color);
}

.dropdown:hover .dropdown-content {
  display: block;
}

/* ============================
   MAIN CONTENT
============================ */
.content {
    padding: 20px;
}

/* ============================
   FILTER SECTION
============================ */
.filters {
    margin-bottom: 20px;
}

.filters select {
    padding: 6px 8px;
    margin-right: 10px;
    border-radius: 4px;
    border: 1px solid #d1d5db;
}

/* ============================
   TABLE STYLES
============================ */
.games-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

.games-table th,
.games-table td {
    border: 1px solid #e5e7eb;
    padding: 10px;
    text-align: center;
}

.games-table th {
    background-color: var(--primary-color);
    color: white;
    font-weight: bold;
}

.games-table tr {
    transition: background-color 0.3s ease;
}

.games-table tr:hover {
    background-color: #f1f5f9;
}

/* ============================
   FOOTER
============================ */
.footer {
    background-color: #e2e8f0;
    text-align: center;
    padding: 15px 0;
    color: var(--secondary-color);
    font-size: 0.9rem;
    margin-top: 40px;
}

/* ============================
   BUTTONS (Reusable)
============================ */
.btn-primary {
    background-color: var(--primary-color);
    color: white;
    padding: 8px 16px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.2s ease-in-out;
}

.btn-primary:hover {
    background-color: #334155;
}

.btn-accent {
    background-color: var(--accent-color);
    color: white;
}

.btn-accent:hover {
    background-color: #d97706;
}

/* ============================
   For Main Page Games
============================ */

.scroll-container {
  display: flex;
  overflow-x: auto;
  gap: 1rem;
  padding: 1rem 0;
}

.game-tile, .result-tile, .matchup-tile, .chart-tile {
  background: #f8f8f8;
  background-color: #fff; /* match the logo's white */
  border-radius: 10px;
  padding: 1rem;
  min-width: 250px;
  flex: 0 0 auto;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  text-align: center; /* Center everything inside the tile */
  margin-bottom: 20px;
}
.home-featured-logos-container {
    display: flex;
    justify-content: center; /* Centers the logos horizontally */
    align-items: center;     /* Aligns vertically if needed */
    gap: 20px;               /* Space between logos and VS */
    margin-bottom: 10px;
}

.home-featured-team-logo {
    width: 120px;   /* Adjust to make logos bigger */
    height: auto;   /* Keep aspect ratio */
}
.leaders-section {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: space-between;
}

.leaders-table table {
  width: 100%;
  border-collapse: collapse;
  flex: 1;
  min-width: 250px;
}

.leaders-table th, .leaders-table td {
  padding: 0.5rem;
  text-align: left;
  border-bottom: 1px solid #ccc;
}
.leader-buttons {
  margin: 0.5rem 0;
}

.leader-buttons button {
  margin-right: 0.5rem;
  padding: 0.4rem 0.8rem;
  border: none;
  border-radius: 5px;
  background-color: #004080;
  color: white;
  cursor: pointer;
  font-weight: bold;
}

.leader-buttons button:hover {
  background-color: #0066cc;
}



/* ============================
   For Games page
============================ */


.page-container {
    max-width: 1200px;
    margin: auto;
    padding: 1rem;
    font-family: Arial, sans-serif;
}
.games-grid-team-logo {
    width: 60px;    /* or whatever size you want */
    height: auto;   /* keeps aspect ratio */
    margin-right: 8px;  /* spacing between logo and team name */
    vertical-align: middle;
}


h1 {
    text-align: center;
}

.game-date-header {
    margin-top: 2rem;
    font-size: 1.5rem;
    color: #333;
}

.game-card-grid {
    display: flex;

    flex-wrap: wrap;
    justify-content: flex-start; /* use flex-start if you want left-aligned */
    gap: 1.5rem;
    margin-top: 1rem;
}

.game-card {
    width: 350px;
    background-color: #fff; /* match the logo's white */
    padding: 0.75rem;
    border-radius: 10px;
    box-shadow: 0 0 6px rgba(0,0,0,0.05);
    cursor: pointer;
    transition: transform 0.2s ease;
}

.game-time {
    font-size: 0.95rem;
    font-weight: 500;
    color: #555;
    margin-bottom: 0.5rem;
}

.team {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.4rem;
}

.team img {
    height: 24px;
    width: 24px;
    object-fit: contain;
    margin-right: 0.5rem;
}

.team-name {
    flex-grow: 1;
    margin-left: 0.5rem;
    font-weight: 500;
    font-size: 0.95rem;
}

.score {
    font-size: 1rem;
    font-weight: bold;
}

.game-tag {
    font-size: 0.8rem;
    padding: 0.2rem 0.4rem;
    border-radius: 6px;
    background-color: #ffd700;
    color: #333;
    display: inline-block;
    margin-top: 0.3rem;
}

.week-selector-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;

}

.week-scroll-container {
    display: flex;
    overflow-x: auto;
    scroll-behavior: smooth;
    gap: 0.5rem;
    padding: 0.5rem;
    max-width: 90vw;
    scroll-behavior: smooth;
}

.week-button {
    padding: 0.5rem 1rem;
    border-radius: 8px;
    border: 1px solid #ccc;
    white-space: nowrap;
    background-color: white;
    color: #1E3A8A;
    font-weight: bold;
    transition: 0.2s;
    cursor: pointer;
    opacity: 0.6; /* default greyed out */
}

.week-button.active {
    background-color: #1E3A8A !important;
    color: white !important;
    opacity: 1 !important;
}

.week-button:not(.active):hover {
    opacity: 1;
}

.scroll-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.25rem 0.5rem;
}

.schedule-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 1rem;

}

.schedule-header h1 {
    margin: 0;
    font-size: 1.75rem;
}

.schedule-filters {
    display: flex;
    gap: 0.75rem;

}

.schedule-filters select {
    padding: 6px 10px;
    border-radius: 6px;
    border: 1px solid #ccc;
    background-color: white;
    font-size: 1rem;
    cursor: pointer;
}

/* ============================
   For Games Details page
============================ */


/* Main Content Container */
.main-container {
  max-width: 1000px;
  margin: auto;
  padding: 1rem;
}

/* Game Summary Section */
.game-summary .teams {
  display: flex;
  justify-content: space-around;
  align-items: center;
  background: white;
  padding: 1rem;
  margin-bottom: 1rem;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
.games-summary-team-logo {
    width: 100px !important;   /* adjust as needed */
    height: auto !important;   /* maintain aspect ratio */
}

.game-summary .team {
  text-align: center;
}

.game-summary .score {
  text-align: center;
  font-size: 1.5rem;
}

/* Section Card Layout */
.content-section {
  background: white;
  padding: 1rem;
  margin-bottom: 1rem;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
/* Key Stats Table */
.key-stats-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 1rem;
}

.key-stats-table th,
.key-stats-table td {
  border: 1px solid #ccc;
  padding: 0.5rem;
}

.key-stats-table th {
  background: #f0f0f0;
}
/* Full Team Stats Table */
.full-team-stats-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 1rem;
}

.full-team-stats-table th,
.full-team-stats-table td {
  border: 1px solid #ccc;
  padding: 0.5rem;
}

.full-team-stats-table th {
  background: #f0f0f0;
}

.bold-text  {
  font-weight: bold;
}
.winning-score {
  color: #000; /* or team primary color */
  font-weight: bold;
}

.losing-score {
  color: #999; /* greyed out */
  font-weight: normal;
}
.tie-score {
  color: #666;
  font-style: italic;
}

/* Drives Chart Styling */
.drive-chart-section {
  width: 900px;
  margin: 0 auto;
  padding: 1rem; /* optional, for spacing inside */
  text-align: center;
  table-layout: fixed;
}
.drive-table {
  width: 900px;
  margin: 0 auto;
  padding: 1rem; /* optional, for spacing inside */
  text-align: center;
  table-layout: fixed;
}
.tabs {
  margin-bottom: 10px;
}
.tab-button {
  background: #336699;
  color: white;
  padding: 0.5rem 1rem;
  border: none;
  cursor: pointer;
  border-radius: 4px;
}
.tab-button.active {
  background: #004080;
  color: white;
}
.filters {
  margin-bottom: 15px;
}
.quarter-header {
  background-color: #e2e2e2;
  font-weight: bold;
  text-align: center;
}
.drive-row.td-drive {
  background-color: #d1ffd1;
}
.drive-row.fg-drive {
  background-color: #d1e7ff;
}
.drive-row.turnover-drive {
  background-color: #ffd1d1;
}
.drive-row.fourth-quarter {
  border-left: 4px solid red;
}
.hidden {
  display: none;
}
.team-logo {
  height: 20px;
  margin-right: 5px;
}
.expand-button {
  background: none;
  border: none;
  font-size: 1rem;
  cursor: pointer;
}

.drive-details{
  color: #999;
  font-size: 1rem;
}


/* Box Score Table Styling */
.boxscore{
    border-collapse: collapse;
}
.boxscore td {

    vertical-align: top;
    text-align: left;
    padding: 0.5rem;
    border: none;
}
.boxscore td:nth-child(1),
.boxscore th:nth-child(1) {
  border-right: 1px solid lightgray; /* vertical middle line */
}

.boxscore-section {
    width: 100%;
    border-collapse: collapse; /* no spacing between cells */
    border: none; /* removes outer border */
    font-family: Arial, sans-serif;
}

/* Header row: light gray bottom border */
.boxscore-section th {
    border-bottom: 2px solid lightgray;
    text-align: left;
    padding: 0.5rem;
}

/* Table cells: padding and vertical alignment */
.boxscore-section td {
    padding: 0.5rem;
    vertical-align: top;
}

/* Vertical line after first column */
.boxscore-section td:first-child,
.boxscore-section th:first-child {
    border-right: 1px solid lightgray;
}

/* Alternate row colors */
.boxscore-section tr:nth-child(even) td {
    background-color: #f9f9f9; /* very light gray */
}
.boxscore-section tr:nth-child(odd) td {
    background-color: #ffffff; /* white */
}

@media (max-width: 900px) {
    .game-card {
        flex: 1 1 calc(48% - 1rem);
    }
}

@media (max-width: 600px) {
    .game-card {
        flex: 1 1 100%;
    }
}

