/* General Styles */
body {
  font-family: Arial, sans-serif;
  max-width: 800px;
  margin: 0 auto;
  padding: 20px;
  background-color: #f5f5f5;
}

.header {
  text-align: center;
  color: #333;
  margin-bottom: 30px;
}

.footer {
  text-align: center;
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid #dee2e6;
  color: #23263d;
  font-size: 0.8em;
}

/* Table Styles */
table {
  width: 100%;
  max-width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
  font-size: 16px;
  text-align: left;
  background-color: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

thead {
  background-color: #23263d;
  color: #fff;
}

thead th {
  padding: 12px 15px;
  text-align: center;
}

tbody tr {
  border-bottom: 1px solid #ddd;
}

tbody tr:nth-of-type(even) {
  background-color: #f9f9f9;
}

tbody tr:hover {
  background-color: #f1f1f1;
}

tbody td {
  padding: 10px 15px;
}

th[colspan] {
  text-align: center;
  font-weight: bold;
  font-size: 1.1em;
}

/* Score Column Styles */
.score-column {
  display: table-cell;
}

.scores-header {
  display: table-cell;
}

/* Make this rule more specific to hide ALL score columns */
.scores-collapsed .score-column,
.scores-collapsed th.score-column,
.scores-collapsed td.score-column,
.scores-collapsed .scores-header {
  display: none !important; /* Use !important to override any inline styles */
}

/* Button Styles */
button,
.refresh-button {
  background-color: #23263d;

  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.9em;
}

.toggle-scores-button {
  margin-bottom: 10px;
}

.toggle-scores-button:hover {
  background-color: #ddd;
  color: black;
}

/* Event Card Styles */
.event-container {
  background-color: white;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  margin-bottom: 15px;
  padding: 20px;
  transition: transform 0.2s ease-in-out;
}

.event-container:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.event-date {
  font-weight: bold;
  color: #2c3e50;
  font-size: 1.1em;
  margin-bottom: 8px;
}

.event-name {
  color: #34495e;
  font-size: 1em;
  line-height: 1.4;
}

.no-events {
  text-align: center;
  color: #7f8c8d;
  font-style: italic;
  margin-top: 50px;
}

.event-count {
  text-align: center;
  color: #7f8c8d;
  margin-bottom: 20px;
  font-style: italic;
}

/* Navigation Bar Styles */
.topnav {
  background-color: #23263d;
  overflow: hidden;
  position: relative;
}

.topnav a {
  float: left;
  color: #f2f2f2;
  text-align: center;
  padding: 14px 16px;
  text-decoration: none;
  font-size: 17px;
}

.topnav a.icon {
  display: none;
}

.topnav a:hover {
  background-color: #ddd;
  color: black;
}

.topnav a.active {
  background-color: #434659;
  color: white;
}

/* Responsive Navigation Bar */
@media screen and (max-width: 600px) {
  .topnav a {
    display: none; /* Hide all links by default */
  }

  .topnav a.icon {
    float: right;
    display: block; /* Show the hamburger icon */
  }

  .topnav.responsive {
    position: relative;
  }

  .topnav.responsive a {
    float: none;
    display: block; /* Show all links when the menu is toggled */
    text-align: left;
  }

  .topnav.responsive a.icon {
    position: absolute;
    right: 0;
    top: 0;
  }
}
.controls {
  display: flex;
  align-items: center;
  gap: 12px; /* Space between dropdown and button */
  flex-wrap: wrap; /* Wrap if the screen is too narrow */
  margin-bottom: 10px;
}



.controls form {
  margin: 0;
}

.controls .toggle-scores-button {
  margin-bottom: 0;
}

#season-dropdown {
  padding: 10px;
  border: 1px solid #23263d;
  border-radius: 4px;
  background-color: #23263d;
  color: white;
  font-size: 0.9em;
  cursor: pointer;
}


#season-dropdown:hover {
  background-color: #434659;
}



#season-dropdown:focus {
  outline: none;
  box-shadow: 0 0 4px #23263d;
}

/* Make tables responsive */
.table-container {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
}

/* Responsive collapsed table */
.table-container.scores-collapsed {
  max-width: 100%;
  margin: 0 auto;
}

/* Allow text wrapping in name column */
tbody td:nth-child(2) {
  white-space: normal;
  word-break: break-word;
  min-width: 120px; /* Ensure name column doesn't get too narrow */
}

/* Make sure numbers don't break */
tbody td:nth-child(3),
tbody td:nth-child(4) {
  white-space: nowrap;
}



/* Utility Styles */
span {
  display: inline-block;
  padding: 2px 5px;
  background-color: #e8f4fd;
  border-radius: 4px;
  font-size: 0.9em;
  color: #333;
}