/**
 * The Bash - Tournament Page Styles
 * Ball603 Design System Extension
 */

/* ===== SNOW EFFECT ===== */
.snow-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 2;
  overflow: hidden;
}

.snowflake {
  position: absolute;
  top: -20px;
  color: #ffffff;
  font-size: 1em;
  opacity: 1;
  animation: snowfall linear forwards;
  text-shadow: 0 0 3px rgba(255, 255, 255, 0.8);
  filter: brightness(1.5);
}

@keyframes snowfall {
  0% {
    transform: translateY(0) rotate(0deg);
    opacity: 1;
  }
  90% {
    opacity: 0.8;
  }
  100% {
    transform: translateY(300px) rotate(360deg);
    opacity: 0;
  }
}

/* ===== LANDING PAGE BASE ===== */
.bash-landing {
  background: #f5f5f5;
  min-height: 100vh;
}

.bash-landing-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 30px 20px 60px;
}

/* ===== CONTINUE BANNER ===== */
.bash-continue-banner {
  background: #1a1a2e;
  color: white;
  padding: 10px 20px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
  font-size: 14px;
}

.bash-continue-btn {
  background: #f57c00;
  color: white;
  padding: 6px 16px;
  border-radius: 20px;
  text-decoration: none;
  font-weight: 600;
  font-size: 13px;
}

/* ===== HEADER ===== */
.bash-landing-header {
  background: #1a1a2e;
  padding: 12px 20px;
  position: sticky;
  top: 0;
  z-index: 100;
}

.bash-landing-header-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.bash-landing-nav {
  display: flex;
  gap: 30px;
}

.bash-nav-link {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
}

.bash-nav-link:hover {
  color: #f57c00;
}

.bash-main-site-link {
  color: #f57c00;
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
}

/* ===== HERO SECTION ===== */
.bash-hero {
  background: linear-gradient(135deg, #1a1a2e 0%, #2d2d44 100%);
  color: white;
  text-align: center;
  padding: 60px 20px 80px;
  position: relative;
  overflow: hidden;
}

.bash-hero-content {
  position: relative;
  z-index: 3;
}

.bash-hero-tagline {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 20px;
}

.bash-hero-logo {
  max-width: 300px;
  margin: 0 auto 20px;
  display: block;
}

.bash-hero-dates {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 8px;
}

.bash-hero-venue {
  font-size: 16px;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 30px;
}

.bash-hero-stats {
  display: flex;
  justify-content: center;
  gap: 50px;
}

.bash-hero-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.bash-hero-stat .stat-value {
  font-size: 36px;
  font-weight: 700;
  color: #f57c00;
}

.bash-hero-stat .stat-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: rgba(255, 255, 255, 0.6);
}

/* ===== SECTION HEADERS ===== */
.bash-section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.bash-section-title {
  font-size: 20px;
  font-weight: 700;
  color: #1a1a2e;
  margin: 0;
}

.bash-section-link {
  color: #f57c00;
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
}

/* ===== TODAY'S GAMES (with logos) ===== */
.bash-today {
  margin-bottom: 50px;
}

.bash-today-scroll {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding-bottom: 10px;
  scrollbar-width: thin;
}

.bash-today-game {
  flex-shrink: 0;
  width: 240px;
  background: white;
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.bash-today-time {
  font-size: 12px;
  font-weight: 600;
  color: #f57c00;
  margin-bottom: 12px;
}

.bash-today-teams {
  margin-bottom: 12px;
}

.bash-today-team {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid #f0f0f0;
}

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

.bash-today-team-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.bash-today-logo {
  width: 24px;
  height: 24px;
  object-fit: contain;
  border-radius: 4px;
}

.bash-today-team .team-name {
  font-size: 14px;
  font-weight: 500;
  color: #333;
}

.bash-today-team .team-score {
  font-size: 16px;
  font-weight: 700;
  color: #333;
}

.bash-today-team.winner .team-name,
.bash-today-team.winner .team-score {
  color: #f57c00;
  font-weight: 700;
}

.bash-today-meta {
  display: flex;
  gap: 12px;
  font-size: 11px;
  color: #888;
}

.bash-today-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 10px;
  border-top: 1px solid #f0f0f0;
  margin-top: 4px;
}

.bash-today-info {
  font-size: 11px;
  color: #888;
}

.bash-today-coverage {
  display: flex;
  gap: 8px;
}

.bash-coverage-icon {
  font-size: 14px;
  text-decoration: none;
  opacity: 0.7;
  transition: opacity 0.2s;
}

.bash-coverage-icon:hover {
  opacity: 1;
}

.bash-today-recap {
  display: block;
  margin-top: 12px;
  text-align: center;
  background: #f5f5f5;
  color: #333;
  padding: 8px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
}

.bash-today-recap:hover {
  background: #f57c00;
  color: white;
}

.bash-no-stories {
  text-align: center;
  padding: 40px;
  color: #888;
  font-size: 14px;
}

/* ===== STORIES GRID ===== */
.bash-stories {
  margin-bottom: 50px;
}

.bash-stories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

.bash-story-card {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.2s;
}

.bash-story-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

/* ===== QUICK LINKS ===== */
.bash-quicklinks {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 50px;
}

.bash-quicklink {
  background: white;
  border-radius: 12px;
  padding: 24px;
  text-align: center;
  text-decoration: none;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  transition: transform 0.2s, box-shadow 0.2s;
}

.bash-quicklink:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.bash-quicklink-icon {
  font-size: 32px;
  display: block;
  margin-bottom: 10px;
}

.bash-quicklink-text {
  font-size: 14px;
  font-weight: 600;
  color: #1a1a2e;
}

/* ===== TABS SECTION ===== */
.bash-tabs-section {
  background: white;
  border-radius: 12px;
  padding: 24px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.bash-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 24px;
  border-bottom: 2px solid #eee;
  padding-bottom: 12px;
}

.bash-tab {
  background: none;
  border: none;
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 600;
  color: #666;
  cursor: pointer;
  border-radius: 8px;
  transition: all 0.2s;
}

.bash-tab:hover {
  background: #f5f5f5;
  color: #333;
}

.bash-tab.active {
  background: #1a1a2e;
  color: white;
}

.bash-panel {
  display: none;
}

.bash-panel.active {
  display: block;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ===== SCHEDULE TABLE (New Layout) ===== */
.bash-schedule-filters {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.bash-filter-btn {
  background: #f5f5f5;
  border: none;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.bash-filter-btn.active,
.bash-filter-btn:hover {
  background: #f57c00;
  color: white;
}

.bash-filter-select {
  padding: 8px 12px;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 13px;
  background: white;
}

.bash-schedule-table-wrap {
  overflow-x: auto;
}

.bash-schedule-tbl {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  min-width: 700px;
}

.bash-schedule-tbl th {
  text-align: left;
  padding: 12px 10px;
  background: #f5f5f5;
  font-weight: 600;
  color: #555;
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

.bash-schedule-tbl td {
  padding: 12px 10px;
  border-bottom: 1px solid #eee;
  vertical-align: middle;
}

.bash-schedule-tbl .date-row td {
  background: #1a1a2e;
  color: white;
  font-weight: 700;
  font-size: 15px;
  padding: 14px 10px;
}

.bash-schedule-tbl .game-row:hover {
  background: #fafafa;
}

/* Column alignments */
.bash-schedule-tbl .col-time {
  width: 80px;
  color: #666;
}

.bash-schedule-tbl .col-gender {
  width: 60px;
  text-align: center;
}

.bash-schedule-tbl .col-site {
  width: 60px;
  text-align: center;
  color: #888;
}

.bash-schedule-tbl .col-away {
  text-align: right;
  width: 200px;
}

.bash-schedule-tbl .col-score {
  width: 80px;
  text-align: center;
  font-weight: 600;
  color: #888;
}

.bash-schedule-tbl .col-home {
  text-align: left;
  width: 200px;
}

.bash-schedule-tbl .col-coverage {
  width: 120px;
}

/* Team cells with logos */
.team-cell {
  display: flex;
  align-items: center;
  gap: 8px;
}

.team-cell.away {
  justify-content: flex-end;
}

.team-cell.home {
  justify-content: flex-start;
}

.team-logo-small {
  width: 24px;
  height: 24px;
  object-fit: contain;
  border-radius: 4px;
  flex-shrink: 0;
}

.team-name-text {
  font-weight: 500;
  color: #333;
}

.team-name-text.winner {
  color: #f57c00;
  font-weight: 700;
}

.coverage-link {
  color: #f57c00;
  text-decoration: none;
  font-size: 12px;
  font-weight: 500;
  margin-right: 10px;
}

.coverage-link:hover {
  text-decoration: underline;
}

/* ===== MARCH MADNESS BRACKET ===== */
.bash-bracket-title {
  font-size: 18px;
  font-weight: 700;
  color: #1a1a2e;
  margin: 0 0 8px 0;
  text-align: center;
}

.bash-bracket-subtitle {
  font-size: 13px;
  color: #888;
  text-align: center;
  margin: 0 0 20px 0;
}

.bracket-container {
  overflow-x: auto;
  padding-bottom: 20px;
}

.bracket-wrapper {
  min-width: 950px;
  padding: 20px;
}

/* Round Headers */
.bracket-headers {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin-bottom: 20px;
  text-align: center;
}

.bracket-header {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #1a1a2e;
  padding: 10px;
  background: #f5f5f5;
  border-radius: 6px;
}

/* ===== BOYS BRACKET (16-team) ===== */
/* Game box ~70px tall, gap 16px between first round games */

.bracket-rounds {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.bracket-round {
  display: flex;
  flex-direction: column;
}

/* First Round - 8 games stacked with 16px gap */
.bracket-round.round-1 {
  gap: 16px;
  padding-top: 0;
}

/* Quarterfinals - 4 games centered between first round pairs */
.bracket-round.round-2 {
  gap: 0;
  padding-top: 43px;
}
.bracket-round.round-2 .bracket-game {
  margin-bottom: 86px;
}
.bracket-round.round-2 .bracket-game:last-child {
  margin-bottom: 0;
}

/* Semifinals - 2 games centered between quarterfinal pairs */
.bracket-round.round-3 {
  gap: 0;
  padding-top: 129px;
}
.bracket-round.round-3 .bracket-game {
  margin-bottom: 242px;
}
.bracket-round.round-3 .bracket-game:last-child {
  margin-bottom: 0;
}

/* Championship - 1 game centered between semifinals */
.bracket-round.round-4 {
  padding-top: 293px;
}

/* ===== GIRLS BRACKET (12-team with byes) ===== */
/* First round games align with quarterfinal games */

.girls-bracket-wrapper {
  min-width: 950px;
}

/* Girls First Round - same spacing as quarterfinals */
.girls-round-1 {
  gap: 0 !important;
  padding-top: 43px !important;
}
.girls-round-1 .bracket-game {
  margin-bottom: 86px;
}
.girls-round-1 .bracket-game:last-child {
  margin-bottom: 0;
}

/* Girls Quarterfinals - 4 games */
.girls-round-2 {
  gap: 0 !important;
  padding-top: 43px !important;
}
.girls-round-2 .bracket-game {
  margin-bottom: 86px;
}
.girls-round-2 .bracket-game:last-child {
  margin-bottom: 0;
}

/* Girls Semifinals - 2 games */
.girls-round-3 {
  gap: 0 !important;
  padding-top: 129px !important;
}
.girls-round-3 .bracket-game {
  margin-bottom: 242px;
}
.girls-round-3 .bracket-game:last-child {
  margin-bottom: 0;
}

/* Girls Championship */
.girls-round-4 {
  padding-top: 293px !important;
}

/* ===== INDIVIDUAL GAME STYLING ===== */
.bracket-game {
  background: white;
  border-radius: 8px;
  border: 1px solid #e0e0e0;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  min-width: 180px;
}

.bracket-game.championship {
  border: 2px solid #f57c00;
  box-shadow: 0 4px 12px rgba(245, 124, 0, 0.2);
}

.bracket-game-label {
  font-size: 10px;
  font-weight: 600;
  color: #888;
  padding: 6px 10px;
  background: #f9f9f9;
  border-bottom: 1px solid #eee;
}

.bracket-matchup {
  display: flex;
  flex-direction: column;
}

/* Team Row in Bracket */
.bracket-team {
  display: flex;
  align-items: center;
  padding: 8px 10px;
  gap: 8px;
  border-bottom: 1px solid #f0f0f0;
  transition: background 0.2s;
}

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

.bracket-team:hover {
  background: #fafafa;
}

.bracket-team.pending {
  opacity: 0.6;
}

/* Bye team and advancing/winner - light orange */
.bracket-team.bye-team,
.bracket-team.winner,
.bracket-team.advancing {
  background: #fff8f0;
  border-left: 3px solid #ffb74d;
}

.bracket-team.bye-team .bracket-team-name,
.bracket-team.winner .bracket-team-name,
.bracket-team.advancing .bracket-team-name {
  color: #e65100;
  font-weight: 600;
}

.bracket-team-logo {
  width: 22px;
  height: 22px;
  object-fit: contain;
  border-radius: 4px;
  flex-shrink: 0;
}

.bracket-team-name {
  flex: 1;
  font-size: 12px;
  font-weight: 500;
  color: #333;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bracket-team-score {
  font-size: 13px;
  font-weight: 700;
  color: #333;
  min-width: 24px;
  text-align: right;
}
  font-weight: 700;
  color: #333;
  min-width: 24px;
  text-align: right;
}

/* Connector Lines (Pure CSS) */
.bracket-round.round-1 .bracket-game {
  position: relative;
}

.bracket-round.round-1 .bracket-game::after {
  content: '';
  position: absolute;
  right: -10px;
  top: 50%;
  width: 10px;
  height: 1px;
  background: #ddd;
}

.bracket-round.round-2 .bracket-game::after,
.bracket-round.round-3 .bracket-game::after {
  content: '';
  position: absolute;
  right: -10px;
  top: 50%;
  width: 10px;
  height: 1px;
  background: #ddd;
}

/* ===== HISTORY SECTION ===== */
.bash-history-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
}

.bash-history-tab {
  background: #f5f5f5;
  border: none;
  padding: 10px 20px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.bash-history-tab.active {
  background: #1a1a2e;
  color: white;
}

.bash-history-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.bash-history-table th {
  text-align: left;
  padding: 12px 10px;
  background: #f5f5f5;
  font-weight: 600;
  color: #555;
  text-transform: uppercase;
  font-size: 11px;
}

.bash-history-table td {
  padding: 12px 10px;
  border-bottom: 1px solid #eee;
  vertical-align: middle;
}

.bash-history-table tr:hover {
  background: #fafafa;
}

/* ===== FOOTER ===== */
.bash-footer {
  background: #1a1a2e;
  color: white;
  padding: 40px 20px;
  margin-top: 60px;
}

.bash-footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 30px;
}

.bash-footer-brand p {
  color: rgba(255, 255, 255, 0.8);
  font-size: 14px;
  margin: 0;
}

.bash-footer-links {
  display: flex;
  gap: 24px;
}

.bash-footer-links a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  font-size: 14px;
}

.bash-footer-links a:hover {
  color: #f57c00;
}

.bash-footer-powered {
  color: rgba(255, 255, 255, 0.6);
  font-size: 13px;
}

/* ===== UTILITIES ===== */
.bash-loading {
  text-align: center;
  padding: 40px;
  color: #888;
}

.bash-no-games {
  text-align: center;
  padding: 40px;
  color: #888;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .bash-continue-banner {
    flex-direction: column;
    gap: 10px;
    padding: 12px;
    font-size: 12px;
  }
  
  .bash-landing-nav {
    display: none;
  }
  
  .bash-hero {
    padding: 40px 20px 60px;
  }
  
  .bash-hero-logo {
    max-width: 200px;
  }
  
  .bash-hero-stats {
    gap: 30px;
  }
  
  .bash-hero-stat .stat-value {
    font-size: 28px;
  }
  
  .bash-quicklinks {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
  
  .bash-quicklink {
    padding: 16px;
  }
  
  .bash-quicklink-icon {
    font-size: 24px;
  }
  
  .bash-quicklink-text {
    font-size: 12px;
  }
  
  .bash-tabs {
    flex-wrap: wrap;
    gap: 6px;
  }
  
  .bash-tab {
    padding: 8px 14px;
    font-size: 12px;
  }
  
  .bracket-wrapper {
    min-width: 1000px;
  }
  
  .bash-footer-inner {
    flex-direction: column;
    text-align: center;
  }
}

/* ===== PRINT STYLES ===== */
@media print {
  .bash-continue-banner,
  .bash-landing-header,
  .bash-quicklinks,
  .bash-tabs,
  .bash-footer {
    display: none;
  }
  
  .bash-hero {
    padding: 20px;
    background: white;
    color: black;
  }
  
  .bash-hero-stat .stat-value {
    color: black;
  }
}