/* === CSS Variables for Easy Theming === */
:root {
  --font-main: 'Segoe UI', sans-serif;
  --color-bg: #f8f9fa;
  --color-text: #030c18;
  --color-accent: #9c1313;
  --color-flash: #006426;
  --color-nav-start: #003366;
  --color-nav-end: #005599;
  --color-nav-hover: rgba(255, 255, 255, 0.2);
  --color-nav-active: rgba(255, 255, 255, 0.4);
  --color-table-even: rgba(255, 255, 255, 0.6);
  --color-table-odd: rgba(240, 248, 255, 0.6);
  --color-pick-bg: rgba(239, 252, 241, 0.85);
  --color-submit: #007bff;
  --color-submit-hover: #0056b3;
}

/* === Base Styling === */
body {
  font-family: var(--font-main);
  margin: 0;
  padding: 0;
  background: url("../images/Nighttime American F.png") center/cover no-repeat fixed;
  background-color: var(--color-bg);
  color: var(--color-text);
}

.container {
  max-width: 960px;
  margin: 40px auto;
  padding: 20px;
  background-color: white;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

h1 {
  text-align: center;
  margin-bottom: 10px;
  color: var(--color-text);
}

/* === Flash Message === */
.flash-message {
  background-color: var(--color-bg);
  color: var(--color-flash);
  padding: 5px 10px;
  border-radius: 5px;
  margin: 20px auto;
  width: 40%;
  text-align: center;
  font-weight: bold;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  transition: opacity 0.5s ease-out;
}

.flash-hide {
  opacity: 0;
  transform: translateY(-20px);
  transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

/* === Dashboard Navigation === */
.dashboard-nav {
  background: linear-gradient(to right, var(--color-nav-start), var(--color-nav-end));
  padding: 12px 0;
  display: flex;
  justify-content: center;
  gap: 24px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}

.dashboard-nav a,
.dashboard-nav .dropdown > a {
  color: white;
  text-decoration: none;
  padding: 10px 20px;
  border-radius: 6px;
  font-weight: 500;
  transition: background-color 0.3s ease, transform 0.2s ease;
}

.dashboard-nav a:hover,
.dashboard-nav .dropdown > a:hover {
  background-color: var(--color-nav-hover);
  transform: scale(1.05);
}

.dashboard-nav a.active {
  background-color: var(--color-nav-active);
  font-weight: bold;
  box-shadow: 0 0 5px rgba(255,255,255,0.6);
}

/* === Dropdown Menu === */
.dashboard-nav .dropdown {
  position: relative;
  display: flex;
  align-items: center;
}

.dashboard-nav .dropdown-content {
  position: absolute;
  top: 100%;
  left: 0;
  background-color: var(--color-nav-start);
  min-width: 160px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
  z-index: 999;
  border-radius: 6px;
  display: none;
}

.dashboard-nav .dropdown:hover .dropdown-content,
.dropdown.open .dropdown-content {
  display: block;
}

.dropdown-content a {
  color: white;
  padding: 10px 20px;
  text-decoration: none;
  display: block;
  transition: background-color 0.3s ease;
}

.dropdown-content a:hover {
  background-color: var(--color-nav-hover);
}

/* === Picks Table === */
.picks-table {
  background-color: rgba(173, 216, 230, 0.3);
  border-collapse: collapse;
  width: 60%;
  margin: 15px auto;
  border-radius: 8px;
  overflow: hidden;
}

.picks-table th,
.picks-table td {
  padding: 8px;
  text-align: center;
  vertical-align: middle;
  font-size: 16px;
  line-height: 1;
}

.picks-table thead th {
  position: sticky;
  top: 0;
  background-color: #94c5f3;
  z-index: 2;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.picks-table tbody tr {
  border-bottom: 1px solid #ccc;
}

.picks-table tbody tr:nth-child(even) {
  background-color: var(--color-table-even);
}

.picks-table tbody tr:nth-child(odd) {
  background-color: var(--color-table-odd);
}

.picks-table tbody tr:hover {
  background-color: rgba(0, 128, 255, 0.1);
  cursor: pointer;
}

.picks-table td.pick-cell {
  text-align: left;
  padding-left: 24px;
}

/* === Matchup Layout === */
.kickoff-cell {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.5;
}

.matchup {
  padding: 6px 0;
  text-align: center;
}

.matchup-flex {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 2px 0;
}

.team-logo {
  height: 32px;
  width: auto;
  vertical-align: middle;
}

.away-team,
.home-team {
  display: inline-block;
  vertical-align: middle;
  font-size: 18px;
  font-weight: 600;
  color: #111;
  text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

.at-symbol {
  display: inline-block;
  vertical-align: middle;
  font-size: 16px;
  line-height: 1.5;
  color: #666;
}

/* === Pick Options === */
.pick-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: var(--color-pick-bg);
  padding: 6px 10px;
  border-radius: 6px;
  margin-bottom: 8px;
  font-weight: 400;
  color: #111;
  text-shadow: 0 1px 2px rgba(0,0,0,0.2);
  transition: background-color 0.2s ease;
  cursor: pointer;
}

.pick-option:hover {
  background-color: white;
  box-shadow: 0 0 4px rgba(0,0,0,0.2);
}

.pick-option input[type="radio"] {
  margin-right: 12px;
  transform: scale(1.2);
}

.team-name {
  flex-grow: 1;
}

/* Ensure scores have spacing and don’t bleed into yard line text */
.team-score {
  font-weight: bold;
  font-size: 1em;
  min-width: 32px;
  text-align: center;
  background-color: rgba(255, 215, 0, 0.1);
  padding: 2px 6px;
  border-radius: 4px;
  margin-left: 8px;   /* ✅ adds breathing room from yard line/badges */
}

.checkmark {
  font-size: 18px;
  color: green;
  visibility: hidden;
  margin-left: 12px;
}

.pick-option input[type="radio"]:checked ~ .checkmark {
  visibility: visible;
}

/* === Spread & Highlights === */
.spread {
  font-size: 14px;
  color: var(--color-accent);
  margin-left: 6px;
}

.locked-row {
  background-color: rgba(200, 200, 200, 0.2);
  color: #666;
}

.prime-slot {
  color: var(--color-accent);
  font-weight: bold;
}

/* === Submit Button === */
.submit-button {
  display: block;
  margin: 20px auto 0;
  padding: 14px 32px;
  background-color: var(--color-submit);
  color: rgb(255, 255, 255);
  font-size: 17px;
  font-weight: bold;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.2s ease;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

.submit-button:hover {
  background-color: var(--color-submit-hover);
  transform: scale(1.03);
}

/* === Sticky Elements === */
.sticky-submit,
.navbar {
  position: sticky;
  top: 0;
  z-index: 10;
  padding: 10px 0;
  text-align: center;
  box-shadow: none;
  /*background-color: white;*/
}

/* === Responsive Tweaks === */
@media screen and (max-width: 768px) {
  .picks-table {
    width: 90%;
    font-size: 14px;
  }

  .team-logo {
    height: 24px;
  }

  .pick-option {
    padding: 6px;
  }

  .dashboard-nav {
    flex-direction: column;
    align-items: center;
    gap: 12px;
  }

  .dashboard-nav a,
  .dashboard-nav .dropdown > a {
    padding: 8px 16px;
  }

  .dropdown-content {
    position: static;
    width: 100%;
    box-shadow: none;
  }

  .dropdown-content a {
    padding: 8px 16px;
  }
}
.timezone-note-inline {
  text-align: center;
  font-size: 14px;
  color: #050ef8;
  margin: 12px 0;
}
.week-selector {
  margin: 20px auto;
  text-align: center;
  font-size: 1.1em;
}

.week-selector select {
  padding: 6px 12px;
  font-size: 1em;
  border-radius: 4px;
  border: 1px solid #ccc;
}
.sticky-submit {
  background-color: #59a0f0;
  border-bottom: 1px solid #ccc;
  padding: 10px;
  display: flex;
  justify-content: center;
}

.submit-controls {
  display: flex;
  align-items: baseline;
  gap: 20px;
}

.submit-controls label {
  font-weight: bold;
  color: #333;
}

.submit-controls select {
  padding: 6px 10px;
  font-size: 1em;
  border-radius: 4px;
  border: 1px solid #aaa;
  line-height: 1.2;
}

.submit-button {
  padding: 6px 12px;
  font-size: 1em;
  background-color: #cc0000;
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}
.back-button {
  display: block;
  margin: 20px auto;
  padding: 10px 20px;
  background-color: #003366;
  color: white;
  border: none;
  border-radius: 6px;
  font-size: 1em;
  cursor: pointer;
  transition: background-color 0.3s ease;
}
.back-button:hover {
  background-color: #001f4d;
}
.welcome-user {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  color: #640046; /* Smoky purple */
  font-size: 2em;
  font-weight: bold;
  text-align: center;
  margin-top: 20px;
  text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}
.spread {
  font-size: 14px;
  margin-left: 6px;
  font-weight: bold;
}

.spread.fav {
  color: crimson;
}

.spread.dog {
  color: steelblue;
}
/* Sticky bar label */
.submit-controls label {
  font-weight: bold;
  font-size: 1.1em;
  color: #4307cf; /* Matches your header theme */
  margin-right: 10px;
}

/* Week dropdown */
.submit-controls select {
  font-family: 'Segoe UI', sans-serif;
  font-size: 1em;
  font-weight: bold;
  padding: 6px 12px;
  border: 2px solid #640046;
  border-radius: 6px;
  background-color: #fff;
  color: #333;
  transition: all 0.2s ease-in-out;
  cursor: pointer;
}

/* On hover/focus */
.submit-controls select:hover,
.submit-controls select:focus {
  border-color: #cc0000;
  box-shadow: 0 0 4px rgba(204, 0, 0, 0.4);
  outline: none;
}
.admin-badge {
  background-color: #ffd700;
  color: #640046;
  font-weight: bold;
  padding: 4px 10px;
  border-radius: 6px;
  margin-left: 12px;
  box-shadow: 0 0 4px rgba(0,0,0,0.2);
}
table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
}

th, td {
  padding: 8px 12px;
  text-align: center;
  border: 1px solid #ccc;
}

thead th {
  background-color: #640046;
  color: white;
}

tbody tr:nth-child(even) {
  background-color: #f9f9f9;
}
.perfect {
  background-color: #ffd700;
  font-weight: bold;
}

.good {
  background-color: #d4edda;
  color: #155724;
}

.bad {
  background-color: #f8d7da;
  color: #721c24;
}

/* === Pick Board Specific === */
.pick-board-title {
  text-align: center;
  font-size: 2em;
  margin-top: 20px;
  color: #640046;
  text-shadow: 1px 1px 2px rgba(0,0,0,0.2);
}

.toggle-buttons {
  text-align: center;
  margin: 20px 0;
}

.toggle-btn {
  background-color: rgba(255, 255, 255, 0.1);
  color: #640046;
  padding: 8px 16px;
  margin: 0 6px;
  border-radius: 6px;
  font-weight: bold;
  text-decoration: none;
  transition: background-color 0.3s ease;
}

.toggle-btn:hover {
  background-color: rgba(255, 255, 255, 0.3);
}

.toggle-btn.active {
  background-color: #ffd700;
  color: black;
  box-shadow: 0 0 6px rgba(0,0,0,0.2);
}

.pick-board-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
}

.pick-board-table th,
.pick-board-table td {
  padding: 8px 12px;
  text-align: center;
  border: 1px solid #ccc;
  font-size: 0.95em;
}

.pick-board-table thead th {
  background-color: #640046;
  color: rgb(153, 28, 28);
}

.pick-board-table tbody tr:nth-child(even) {
  background-color: #f9f9f9;
}

.pick-board-table tbody tr:nth-child(odd) {
  background-color: #fff;
}

.pick-board-table td strong {
  color: #ff4081;
}

/* === Pick Board Scoped Styles — Blue Theme === */
.pick-board-wrapper {
  overflow-x: auto;
  max-width: 100%;
  margin: auto;
  animation: fadeIn 0.8s ease;
  padding-bottom: 30px;
}

/* Table container */
.pick-board-wrapper .picks-table {
  width: 92%;
  margin: 0 auto;
  border-collapse: collapse;
  font-size: 0.9em;
  background-color: #eaf2fb; /* soft blue background */
  color: #1c2b3a;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
  border: 1px solid #b0c4de;
}

/* Header and cell styling */
.pick-board-wrapper .picks-table th,
.pick-board-wrapper .picks-table td {
  padding: 6px 10px;
  border: 1px solid #a0b8d8; /* prominent blue-gray border */
  text-align: center;
  vertical-align: middle;
}

/* Header row */
.pick-board-wrapper .picks-table th {
  background-color: #3b5b7e; /* deep blue */
  color: #f0f8ff; /* soft white-blue */
  position: sticky;
  top: 0;
  z-index: 10;
  font-size: 0.9em;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Alternating row background */
.pick-board-wrapper .picks-table tr:nth-child(even) {
  background-color: #f5faff; /* very light blue */
}

/* Correct pick cell */
.pick-board-wrapper .pick-correct {
  background-color: rgba(0, 160, 0, 0.18);
  font-weight: 500;
  color: #1e4620;
  border: 1px solid #2e7d32;
}

/* Incorrect pick cell */
.pick-board-wrapper .pick-incorrect {
  background-color: rgba(180, 0, 0, 0.18);
  font-weight: 500;
  color: #5a1a1a;
  border: 1px solid #8b0000;
}

/* Locked cell */
.pick-board-wrapper td.locked {
  background-color: #dbe6f2;
  color: #6c7a89;
  font-style: italic;
}

/* Hover effect */
.pick-board-wrapper .picks-table td:hover {
  background-color: #d0e0f0;
  cursor: default;
}

/* Smooth transitions */
.pick-board-wrapper .picks-table td {
  transition: background-color 0.3s ease;
}

.flash-success {
  background-color: #fff3cd; /* soft yellow */
  color: #856404;
  border: 1px solid #ffeeba;
}

.flash-error {
  background-color: #f8d7da; /* soft red */
  color: #721c24;
  border: 1px solid #f5c6cb;
}

.flash-info {
  background-color: #cce5ff; /* soft blue */
  color: #004085;
  border: 1px solid #b8daff;
}

.pick-push {
  background-color: #42c4f0; /* light blue */
  color: #000;
  font-weight: bold;
}

/* Highlight only the username cell for the logged-in user */
.highlight-user td:first-child {
  background-color: #c5e5ff;   /* soft yellow fill */
  font-weight: bold;
  color: #000;                 /* ensure text is readable */
  border-left: 3px solid #1900ff; /* optional accent border */
  border-right: 3px solid #1900ff;
}