* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Inter", sans-serif;
  background: #070b17;
  color: #e7edff;
}

.hero {
  padding: 1rem 1rem 2rem;
  background: radial-gradient(circle at 20% 20%, #243d8a 0%, #0b132c 45%, #070b17 100%);
}

.hero--compact {
  padding-bottom: 0.75rem;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  flex-wrap: wrap;
}

.site-logo {
  font-weight: 800;
  letter-spacing: 0.2px;
}

.nav-btn,
.cta {
  text-decoration: none;
  color: #06112f;
  background: linear-gradient(90deg, #39d3ff, #8effb0);
  padding: 0.6rem 0.95rem;
  border-radius: 999px;
  font-size: 0.92rem;
  font-weight: 700;
}

.nav-btn--ghost {
  background: rgba(255, 255, 255, 0.12);
  color: #e7edff;
  border: 1px solid rgba(255, 255, 255, 0.22);
}

button.nav-btn {
  cursor: pointer;
  border: none;
  font: inherit;
}

button.nav-btn.nav-btn--ghost {
  border: 1px solid rgba(255, 255, 255, 0.22);
}

.hero-content {
  margin-top: 1.4rem;
  max-width: 760px;
}

.eyebrow {
  margin: 0;
  color: #9ad7ff;
  font-weight: 600;
}

h1 {
  margin: 0.55rem 0;
  font-size: 1.85rem;
  line-height: 1.15;
}

.subtitle {
  margin: 0.35rem 0 1.2rem;
  color: #c3d3ff;
  line-height: 1.5;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 1rem;
}

.cta--secondary {
  background: transparent;
  color: #e7edff;
  border: 1px solid rgba(255, 255, 255, 0.35);
}

.hero-highlights {
  margin: 0;
  padding: 0 0 0 1.1rem;
  color: #b8c9ff;
  line-height: 1.55;
  font-size: 0.95rem;
}

.hero-highlights li {
  margin-bottom: 0.35rem;
}

.hero-highlights strong {
  color: #e7edff;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.teams-section {
  padding: 1.25rem 1rem 0.5rem;
  background: linear-gradient(180deg, #070b17 0%, #0a1024 100%);
}

.teams-inner {
  max-width: 1100px;
  margin: 0 auto;
}

.teams-head h2 {
  margin: 0 0 0.4rem;
  font-size: 1.35rem;
}

.teams-lede {
  margin: 0 0 0.85rem;
  color: #a9b9e8;
  line-height: 1.45;
  font-size: 0.95rem;
}

.today-matches-section {
  padding: 1.5rem 1rem 2rem;
  background: linear-gradient(180deg, #0a1024 0%, #070b17 100%);
  border-top: 1px solid #233161;
}

.today-matches-section h2 {
  margin: 0 0 0.4rem;
  font-size: 1.35rem;
}

.today-matches-lede {
  margin: 0 0 0.85rem;
}

.today-matches-strip {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 0.25rem;
}

@media (min-width: 900px) {
  .today-matches-strip {
    flex-direction: row;
    flex-wrap: wrap;
  }

  .today-match-card {
    flex: 1 1 calc(50% - 0.375rem);
    max-width: 520px;
  }
}

.today-match-card {
  background: #101936;
  border: 1px solid #2a3f8a;
  border-radius: 16px;
  padding: 1rem 1.1rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}

.today-match-card__top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.35rem;
}

.today-match-card__order {
  font-size: 0.78rem;
  font-weight: 700;
  color: #7a8ab8;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.today-match-card--live {
  border-color: rgba(255,80,80,0.45);
  box-shadow: 0 0 0 2px rgba(255,80,80,0.12), 0 8px 24px rgba(0,0,0,0.3);
}

.today-match-card__status {
  font-size: 0.78rem;
  font-weight: 600;
  color: #8effb0;
}
.today-match-card__status--live {
  color: #ff5050;
  animation: live-pulse 1.6s ease-in-out infinite;
}
.today-match-card__status--post { color: #a9b9e8; }

@keyframes live-pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.55; }
}

.today-match-card__teams {
  font-size: 1.08rem;
  font-weight: 700;
  color: #e7edff;
  line-height: 1.35;
}

/* Score block */
.today-match-card__scores {
  margin: 0.6rem 0 0.3rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.today-match-card__innings {
  font-size: 0.92rem;
  color: #e7edff;
  display: flex;
  align-items: baseline;
  gap: 0.4rem;
}

.today-match-card__inn-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: #7a8ab8;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  min-width: 32px;
}

.today-match-card__chase {
  font-size: 0.85rem;
  color: #ffd166;
  font-weight: 600;
  margin-top: 0.1rem;
}

.today-match-card__progress {
  font-size: 0.78rem;
  color: #39d3ff;
  font-weight: 600;
}

.today-match-card__result {
  font-size: 0.85rem;
  color: #8effb0;
  margin-top: 0.3rem;
}

.today-match-card__toss {
  font-size: 0.8rem;
  color: rgba(231,237,255,0.55);
  margin-top: 0.2rem;
}

.today-match-card__meta {
  margin-top: 0.45rem;
  font-size: 0.88rem;
  color: #a9b9e8;
  line-height: 1.4;
}

.today-match-card__updated {
  font-size: 0.72rem;
  color: rgba(169,185,232,0.45);
  margin-top: 0.25rem;
}

/* Schedule modal score rows */
.schedule-match__scores {
  margin: 0.4rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
.schedule-match__inn {
  font-size: 0.85rem;
  color: #e7edff;
  display: flex;
  gap: 0.4rem;
}
.schedule-match__inn span {
  font-size: 0.72rem;
  font-weight: 700;
  color: #7a8ab8;
  text-transform: uppercase;
  min-width: 30px;
}
.schedule-match__chase {
  font-size: 0.82rem;
  color: #ffd166;
  font-weight: 600;
}
.schedule-match__mom {
  font-size: 0.82rem;
  color: #8effb0;
}
.schedule-match__status--live {
  color: #ff5050;
}
.schedule-match__status--post {
  color: #a9b9e8;
}

.team-search {
  width: 100%;
  max-width: 520px;
  display: block;
  border: 1px solid #2a3a72;
  background: #0b132c;
  color: #ebf1ff;
  border-radius: 12px;
  padding: 0.75rem 0.9rem;
  font-size: 1rem;
}

.team-search::placeholder {
  color: #7a8ab8;
}

.player-search {
  border: 1px solid #2a3a72;
  background: #0b132c;
  color: #ebf1ff;
  border-radius: 10px;
  padding: 0.65rem;
  font-size: 0.95rem;
}

.player-search::placeholder {
  color: #7a8ab8;
}

.hidden {
  display: none;
}

.teams-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 0.65rem;
  margin-top: 1rem;
}

.team-card {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-align: left;
  width: 100%;
  border: 1px solid #233161;
  background: #111a38;
  border-radius: 14px;
  padding: 0.65rem 0.75rem;
  cursor: pointer;
  color: inherit;
  font: inherit;
  transition: border-color 0.15s ease, transform 0.12s ease;
}

.team-card:hover,
.team-card:focus-visible {
  border-color: #57ccff;
  outline: none;
  transform: translateY(-1px);
}

.team-card-logo-wrap {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  border-radius: 14px;
  overflow: hidden;
  background: #0b132c;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.team-card-logo-wrap img {
  width: 56px;
  height: 56px;
  display: block;
  object-fit: cover;
}

.team-card-body {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}

.team-card-short {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #9fb2e6;
  text-transform: uppercase;
}

.team-card-name {
  font-size: 0.88rem;
  font-weight: 600;
  line-height: 1.15;
  color: #e7edff;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-clamp: 2;
}

.teams-hint {
  margin: 0.75rem 0 0;
  color: #9eaed9;
  font-size: 0.92rem;
}

.players-section {
  padding: 0.75rem 1rem 0.5rem;
  background: linear-gradient(180deg, #0a1024 0%, #070b17 100%);
}

.players-inner {
  max-width: 1100px;
  margin: 0 auto;
}

.players-head h2 {
  margin: 0 0 0.4rem;
  font-size: 1.35rem;
}

.players-lede {
  margin: 0 0 0.85rem;
  color: #a9b9e8;
  line-height: 1.45;
  font-size: 0.95rem;
}

.player-directory-search {
  width: 100%;
  max-width: 520px;
  display: block;
  border: 1px solid #2a3a72;
  background: #0b132c;
  color: #ebf1ff;
  border-radius: 12px;
  padding: 0.75rem 0.9rem;
  font-size: 1rem;
}

.player-directory-search::placeholder {
  color: #7a8ab8;
}

.players-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem 1.1rem;
  margin-top: 1rem;
}

@media (min-width: 900px) {
  .players-grid {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.15rem 1.25rem;
  }
}

.player-card {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  text-align: left;
  border: 1px solid #233161;
  background: linear-gradient(180deg, #141d42 0%, #111a38 100%);
  border-radius: 16px;
  padding: 0;
  overflow: hidden;
  color: #e7edff;
  font: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  transition:
    border-color 0.18s ease,
    transform 0.15s ease,
    box-shadow 0.18s ease;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.22);
}

.player-card:hover,
.player-card:focus-visible {
  border-color: #57ccff;
  outline: none;
  transform: translateY(-3px);
  box-shadow:
    0 14px 32px rgba(0, 0, 0, 0.38),
    0 0 0 1px rgba(87, 204, 255, 0.15);
}

.player-card-photo-wrap {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 0;
  overflow: hidden;
  flex-shrink: 0;
  background: linear-gradient(160deg, #1a2858 0%, #0b132c 55%, #070b17 100%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.player-card-photo-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}

.player-card-name {
  min-width: 0;
  line-height: 1.3;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-clamp: 2;
}

.player-card-text {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 0;
  flex: 1;
  padding: 0.9rem 1rem 1.05rem;
}

.player-card-short-name {
  color: #9fb2e6;
  font-size: 0.78rem;
  font-weight: 500;
  line-height: 1.15;
}

.subpage {
  min-height: 100vh;
  background: #070b17;
}

.subpage-hero {
  padding: 1rem 1rem 0.5rem;
  background: radial-gradient(circle at 20% 20%, #243d8a 0%, #0b132c 45%, #070b17 100%);
}

.subpage-title {
  margin: 0.75rem 0 0.25rem;
  font-size: 1.5rem;
  padding: 0 1rem;
  max-width: 900px;
}

.subpage-subtitle {
  margin: 0 0 1rem;
  color: #a9b9e8;
  padding: 0 1rem;
  font-size: 0.95rem;
}

.subpage-main {
  padding: 0 1rem 2rem;
  max-width: 900px;
  margin: 0 auto;
}

/* Squad / player directory: room for larger photo cards */
.subpage-main--wide {
  max-width: 1180px;
}

.player-card--link {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  height: 100%;
  min-height: 0;
}

.player-card-role {
  color: #9fb2e6;
  font-size: 0.82rem;
  font-weight: 500;
  line-height: 1.3;
}

.squad-grid {
  margin-top: 1rem;
}

.player-profile-main {
  max-width: 720px;
}

.player-profile-card {
  margin-top: 0.5rem;
}

.player-profile-header {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  flex-wrap: wrap;
}

.player-profile-photo-wrap {
  width: 120px;
  height: 120px;
  border-radius: 16px;
  overflow: hidden;
  background: #0b132c;
  flex-shrink: 0;
}

.player-profile-photo-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.player-profile-name {
  margin: 0;
  font-size: 1.5rem;
}

.player-profile-team {
  margin: 0.35rem 0 0;
  color: #9ad7ff;
  font-weight: 600;
}

.player-profile-meta {
  margin: 0.5rem 0 0;
  color: #c3d3ff;
  line-height: 1.45;
}

.profile-link {
  display: inline-block;
  margin-top: 0.75rem;
  color: #57ccff;
  font-weight: 600;
}

.stats-block {
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid #233161;
}

.stats-block h2 {
  margin: 0 0 0.65rem;
  font-size: 1.05rem;
}

.stats-note {
  margin: 0 0 0.75rem;
  color: #a9b9e8;
  font-size: 0.92rem;
  line-height: 1.45;
}

.profile-kpis {
  margin-top: 0.5rem;
}

body.stats-modal-open {
  overflow: hidden;
}

.stats-modal[hidden] {
  display: none !important;
}

.stats-modal {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.stats-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4, 8, 20, 0.78);
  backdrop-filter: blur(6px);
}

.stats-modal__dialog {
  position: relative;
  z-index: 1;
  width: min(960px, 100%);
  max-height: min(90vh, 880px);
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #121a3d 0%, #0b132c 100%);
  border: 1px solid #2a3f8a;
  border-radius: 18px;
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.55),
    0 0 0 1px rgba(87, 204, 255, 0.12);
  overflow: hidden;
}

.stats-modal__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.15rem 0.75rem;
  border-bottom: 1px solid #233161;
}

.stats-modal__header h2 {
  margin: 0;
  font-size: 1.15rem;
  line-height: 1.25;
  color: #e7edff;
}

.fantasy-modal {
  z-index: 3100;
}

.fantasy-modal__dialog {
  width: min(880px, 100%);
}

.fantasy-modal__intro {
  margin: 0;
  padding: 0 1.15rem 0.75rem;
  color: #a9b9e8;
  font-size: 0.92rem;
  line-height: 1.45;
}

.fantasy-modal__field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 0 1.15rem 0.75rem;
}

.fantasy-modal__field label {
  font-size: 0.85rem;
  font-weight: 600;
  color: #c8d4f5;
}

.fantasy-modal__select {
  width: 100%;
  padding: 0.6rem 0.75rem;
  border-radius: 12px;
  border: 1px solid #2a3a72;
  background: #0b132c;
  color: #e7edff;
  font: inherit;
  font-size: 0.95rem;
}

.fantasy-modal__actions {
  padding: 0 1.15rem 0.85rem;
}

.fantasy-modal__result {
  padding: 0 1.15rem 1.15rem;
  overflow: auto;
  max-height: min(52vh, 520px);
}

.fantasy-cv-row {
  margin-bottom: 0.85rem;
  padding: 0.65rem 0.85rem;
  border-radius: 12px;
  background: rgba(87, 204, 255, 0.08);
  border: 1px solid rgba(87, 204, 255, 0.2);
  color: #e7edff;
  font-size: 0.92rem;
  line-height: 1.4;
}

.fantasy-xi-scroll {
  overflow-x: auto;
  margin-bottom: 0.85rem;
  border-radius: 12px;
  border: 1px solid #233161;
}

.fantasy-xi-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.fantasy-xi-table th,
.fantasy-xi-table td {
  padding: 0.5rem 0.65rem;
  text-align: left;
  border-bottom: 1px solid #233161;
}

.fantasy-xi-table th {
  background: rgba(0, 0, 0, 0.25);
  color: #c8d4f5;
  font-weight: 600;
}

.fantasy-xi-table tr:last-child td {
  border-bottom: none;
}

.fantasy-notes {
  margin: 0;
  padding-left: 1.2rem;
  color: #a9b9e8;
  font-size: 0.88rem;
  line-height: 1.5;
}

.fantasy-notes li {
  margin-bottom: 0.35rem;
}

/* ── match header inside result ── */
.fantasy-match-header {
  font-size: 1rem;
  font-weight: 700;
  color: #e7edff;
  margin-bottom: 0.6rem;
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  flex-wrap: wrap;
}
.fantasy-match-venue {
  font-size: 0.82rem;
  font-weight: 400;
  color: #6b82c0;
}

/* ── captain / vice-captain banner ── */
.fantasy-cv-row {
  margin-bottom: 0.7rem;
  padding: 0.6rem 0.85rem;
  border-radius: 12px;
  background: rgba(87, 204, 255, 0.08);
  border: 1px solid rgba(87, 204, 255, 0.2);
  color: #e7edff;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.35rem;
}
.fantasy-cv-badge {
  display: inline-block;
  border-radius: 6px;
  font-size: 0.7rem;
  font-weight: 800;
  padding: 0.1rem 0.4rem;
  vertical-align: middle;
}
.fantasy-cv-c  { background: #ffd166; color: #1a1200; }
.fantasy-cv-vc { background: #c0caef; color: #0e1530; }
.fantasy-score-chip {
  display: inline-block;
  font-size: 0.75rem;
  background: rgba(57,211,255,0.12);
  border: 1px solid rgba(57,211,255,0.25);
  border-radius: 999px;
  padding: 0.05rem 0.4rem;
  color: #57ccff;
  vertical-align: middle;
}

/* ── role legend ── */
.fantasy-role-legend {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 0.75rem;
}
.fantasy-role-pill {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  border: 1px solid;
}
.fantasy-role-pill--wk   { background: rgba(255,100,100,0.12); border-color: rgba(255,100,100,0.4); color: #ff9090; }
.fantasy-role-pill--bat  { background: rgba(100,200,255,0.12); border-color: rgba(100,200,255,0.4); color: #64c8ff; }
.fantasy-role-pill--ar   { background: rgba(100,255,150,0.12); border-color: rgba(100,255,150,0.4); color: #64ff96; }
.fantasy-role-pill--bowl { background: rgba(255,200,80,0.12);  border-color: rgba(255,200,80,0.4);  color: #ffc850; }

/* ── table column sizing ── */
.fantasy-td-num   { width: 2rem; text-align: center; color: #6b82c0; font-size: 0.82rem; }
.fantasy-td-player { min-width: 180px; }
.fantasy-td-team  { color: #a9b9e8; font-size: 0.83rem; white-space: nowrap; }
.fantasy-td-role  { white-space: nowrap; }
.fantasy-td-score { text-align: right; color: #57ccff; font-variant-numeric: tabular-nums; font-size: 0.88rem; }
.fantasy-td-arm   { text-align: center; }

/* ── player name + reasoning in table ── */
.fantasy-player-name {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  color: #e7edff;
}
.fantasy-player-reason {
  display: block;
  font-size: 0.74rem;
  color: #7a92cf;
  line-height: 1.35;
  margin-top: 0.15rem;
  max-width: 360px;
}

/* ── role tags in table ── */
.fantasy-role-tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.15rem 0.45rem;
  border-radius: 6px;
}
.fantasy-role-tag--wk   { background: rgba(255,100,100,0.18); color: #ff9090; }
.fantasy-role-tag--bat  { background: rgba(100,200,255,0.18); color: #64c8ff; }
.fantasy-role-tag--ar   { background: rgba(100,255,150,0.18); color: #64ff96; }
.fantasy-role-tag--bowl { background: rgba(255,200,80,0.18);  color: #ffc850; }

/* ── captain / vice row highlight ── */
.fantasy-row--captain td { background: rgba(255,209,102,0.06); }
.fantasy-row--vice    td { background: rgba(192,202,239,0.05); }

/* ── strategy notes heading ── */
.fantasy-notes-head {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #6b82c0;
  margin: 0.6rem 0 0.3rem;
}

.wa-share-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  margin-top: 1.4rem;
  padding: 0.75rem 1.4rem;
  background: #25D366;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 700;
  border-radius: 999px;
  text-decoration: none;
  transition: background 0.15s, transform 0.15s, box-shadow 0.15s;
  width: 100%;
  justify-content: center;
  box-sizing: border-box;
}

.wa-share-btn:hover {
  background: #1ebe5d;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(37, 211, 102, 0.35);
}

/* ══════════════════════════════════════════
   PITCH REPORT CARD
══════════════════════════════════════════ */
.pitch-report-card {
  background: rgba(10, 20, 50, 0.7);
  border: 1px solid rgba(57, 211, 255, 0.18);
  border-radius: 14px;
  padding: 0.85rem 1rem;
  margin-bottom: 0.85rem;
}

.pitch-report-header {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 0.65rem;
  font-size: 0.84rem;
  color: #a9b9e8;
}

.pitch-badge {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
  text-transform: uppercase;
}
.pitch-badge--batting  { background: rgba(100,200,100,0.2);  color: #80ff80;  border: 1px solid rgba(100,200,100,0.4); }
.pitch-badge--bowling  { background: rgba(255,100,80,0.2);   color: #ff9070;  border: 1px solid rgba(255,100,80,0.4); }
.pitch-badge--spin     { background: rgba(200,130,255,0.2);  color: #d88fff;  border: 1px solid rgba(200,130,255,0.4); }
.pitch-badge--pace     { background: rgba(255,200,50,0.2);   color: #ffc832;  border: 1px solid rgba(255,200,50,0.4); }
.pitch-badge--balanced { background: rgba(100,180,255,0.2);  color: #64b4ff;  border: 1px solid rgba(100,180,255,0.4); }

.pitch-avg-score strong { color: #e7edff; }
.pitch-toss  { color: #ffd166; font-size: 0.82rem; }
.pitch-dew   { color: #57ccff; font-size: 0.82rem; }

.pitch-report-bars {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 0.55rem;
}

.pitch-bar-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.pitch-bar-label {
  font-size: 0.78rem;
  color: #a9b9e8;
  width: 4rem;
  flex-shrink: 0;
}

.pitch-bar-track {
  flex: 1;
  height: 7px;
  background: rgba(255,255,255,0.07);
  border-radius: 999px;
  overflow: hidden;
}

.pitch-bar-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 0.4s ease;
}
.pitch-bar-fill--pace { background: linear-gradient(90deg, #ffc832, #ff8c00); }
.pitch-bar-fill--spin { background: linear-gradient(90deg, #b88fff, #7c3aed); }

.pitch-bar-val {
  font-size: 0.78rem;
  color: #6b82c0;
  width: 2.5rem;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.pitch-report-notes {
  font-size: 0.78rem;
  color: #7a92cf;
  margin: 0;
  line-height: 1.45;
  border-top: 1px solid rgba(255,255,255,0.06);
  padding-top: 0.45rem;
}

.stats-modal__close {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  color: #e7edff;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.15s ease;
}

.stats-modal__close:hover {
  background: rgba(255, 255, 255, 0.14);
}

.stats-modal__tabs {
  display: flex;
  gap: 0.5rem;
  padding: 0.75rem 1rem 0.5rem;
  background: rgba(0, 0, 0, 0.15);
}

.stats-tab {
  flex: 1;
  padding: 0.65rem 0.85rem;
  border-radius: 12px;
  border: 1px solid #2a3a72;
  background: #0b132c;
  color: #a9b9e8;
  font: inherit;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  transition:
    border-color 0.15s ease,
    background 0.15s ease,
    color 0.15s ease;
}

.stats-tab.is-active {
  border-color: #57ccff;
  background: linear-gradient(90deg, rgba(57, 211, 255, 0.18), rgba(142, 255, 176, 0.12));
  color: #e7edff;
  box-shadow: 0 0 0 1px rgba(87, 204, 255, 0.2);
}

.stats-modal__loading,
.stats-modal__error {
  padding: 0.75rem 1rem;
  font-size: 0.92rem;
}

.stats-modal__loading {
  color: #9ad7ff;
}

.stats-modal__error {
  color: #ff8a9c;
}

.stats-modal__panel {
  flex: 1;
  min-height: 0;
  padding: 0.65rem 0.85rem 1rem;
  overflow: hidden;
  display: none;
}

.stats-modal__panel.is-active {
  display: block;
}

.ipl-stats-scroll {
  max-height: min(58vh, 520px);
  overflow: auto;
  border-radius: 12px;
  border: 1px solid #233161;
  background: #070b17;
}

.ipl-stats-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
  min-width: 720px;
}

.ipl-stats-table thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 0.55rem 0.45rem;
  text-align: left;
  font-weight: 700;
  color: #9fb2e6;
  background: #101936;
  border-bottom: 1px solid #233161;
  white-space: nowrap;
}

.ipl-stats-table tbody td {
  padding: 0.5rem 0.45rem;
  border-bottom: 1px solid #1c2748;
  color: #e7edff;
  white-space: nowrap;
}

.ipl-stats-table tbody tr:hover td {
  background: rgba(87, 204, 255, 0.06);
}

.ipl-stats-table__career td {
  font-weight: 700;
  background: rgba(57, 211, 255, 0.08);
  color: #c8eaff;
}

.schedule-modal__dialog {
  max-height: min(92vh, 900px);
}

.schedule-modal__meta {
  margin: 0 1rem 0.5rem;
  color: #9fb2e6;
  font-size: 0.88rem;
}

.schedule-modal__body {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 0.5rem 0.85rem 1rem;
}

.schedule-day {
  margin-bottom: 1.25rem;
}

.schedule-day__title {
  margin: 0 0 0.5rem;
  font-size: 0.95rem;
  font-weight: 700;
  color: #9ad7ff;
  letter-spacing: 0.02em;
}

.schedule-match {
  background: #0b132c;
  border: 1px solid #233161;
  border-radius: 14px;
  padding: 0.75rem 0.9rem;
  margin-bottom: 0.5rem;
}

.schedule-match__top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.35rem;
}

.schedule-match__order {
  font-size: 0.78rem;
  font-weight: 700;
  color: #7a8ab8;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.schedule-match__status {
  font-size: 0.78rem;
  font-weight: 600;
  color: #8effb0;
}

.schedule-match__teams {
  font-size: 1.02rem;
  font-weight: 700;
  color: #e7edff;
  line-height: 1.35;
}

.schedule-match__meta {
  margin-top: 0.45rem;
  font-size: 0.86rem;
  color: #a9b9e8;
  line-height: 1.4;
}

.schedule-match__btn-row {
  margin-top: 0.65rem;
  display: flex;
  gap: 0.5rem;
}

.schedule-match__fantasy-btn,
.schedule-match__create-btn {
  flex: 1;
  padding: 0.5rem 0.6rem;
  border-radius: 12px;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition:
    background 0.15s ease,
    border-color 0.15s ease,
    color 0.15s ease;
}

.schedule-match__fantasy-btn {
  border: 1px solid #2a3f8a;
  background: rgba(87, 204, 255, 0.1);
  color: #9ad7ff;
}

.schedule-match__fantasy-btn:hover {
  background: rgba(87, 204, 255, 0.16);
  border-color: #4a6ad4;
  color: #e7edff;
}

.schedule-match__create-btn {
  border: 1px solid rgba(143, 255, 176, 0.3);
  background: rgba(143, 255, 176, 0.08);
  color: #8effb0;
}

.schedule-match__create-btn:hover {
  background: rgba(143, 255, 176, 0.16);
  border-color: rgba(143, 255, 176, 0.55);
  color: #e7edff;
}

.schedule-match__fantasy-btn:disabled,
.schedule-match__create-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.players-hint {
  margin: 0.75rem 0 0;
  color: #9eaed9;
  font-size: 0.92rem;
}

.dashboard {
  padding: 1rem;
}

.panel {
  background: #101936;
  border: 1px solid #1f2b55;
  border-radius: 16px;
  padding: 1rem;
}

.filters h2 {
  margin: 0 0 0.9rem;
}

.filters-tip {
  margin: -0.35rem 0 0.85rem;
  color: #a9b9e8;
  font-size: 0.92rem;
  line-height: 1.45;
}

.filters-tip strong {
  color: #e7edff;
}

.filters-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.7rem;
}

.toggle-wrap {
  flex-direction: row;
  align-items: center;
  gap: 0.55rem;
  min-height: 42px;
}

.toggle-wrap input[type="checkbox"] {
  inline-size: 18px;
  block-size: 18px;
}

label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  color: #cfe1ff;
  font-size: 0.92rem;
}

select,
button {
  border: 1px solid #2a3a72;
  background: #0b132c;
  color: #ebf1ff;
  border-radius: 10px;
  padding: 0.65rem;
  font-size: 0.95rem;
}

button {
  cursor: pointer;
  background: linear-gradient(90deg, #3277ff, #20b8ff);
  border: none;
  font-weight: 700;
}

.kpi-grid {
  margin-top: 1rem;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.7rem;
}

.kpi-card {
  background: #111a38;
  border: 1px solid #233161;
  border-radius: 14px;
  padding: 0.9rem;
}

.kpi-card h3 {
  margin: 0;
  font-size: 0.85rem;
  color: #9fb2e6;
  font-weight: 600;
}

.kpi-card p {
  margin: 0.5rem 0 0;
  font-size: 1.3rem;
  font-weight: 800;
}

.charts-grid {
  margin-top: 1rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.8rem;
}

.chart-card h3 {
  margin-top: 0;
}

/* Chart.js: parent must have fixed height when maintainAspectRatio is false,
   or the canvas grows without bound (infinite vertical stretch). */
.chart-wrap {
  position: relative;
  width: 100%;
  height: 280px;
  max-height: 280px;
  overflow: hidden;
}

.chart-wrap canvas {
  display: block;
  max-width: 100%;
}

.footer {
  text-align: center;
  color: #9eaed9;
  padding: 1rem;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.sql-console-lede strong {
  color: #9ad7ff;
  font-weight: 700;
}

.sql-console-main {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1rem 2rem;
}

.sql-console-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem 1rem;
  margin-bottom: 0.75rem;
}

.sql-console-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: #c8d4f5;
  margin-bottom: 0.35rem;
}

.sql-console-toolbar .sql-console-label {
  margin-bottom: 0;
}

.sql-console-select {
  min-width: 200px;
  padding: 0.5rem 0.65rem;
  border-radius: 10px;
  border: 1px solid #2a3a72;
  background: #0b132c;
  color: #e7edff;
  font: inherit;
  font-size: 0.92rem;
}

.sql-console-hint {
  font-size: 0.82rem;
  color: #7a8ab8;
}

.sql-console-input {
  width: 100%;
  min-height: 200px;
  padding: 0.85rem 1rem;
  border-radius: 12px;
  border: 1px solid #233161;
  background: #0a0f24;
  color: #e7edff;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 0.88rem;
  line-height: 1.45;
  resize: vertical;
}

.sql-console-input:focus {
  outline: none;
  border-color: #4a6ad4;
  box-shadow: 0 0 0 1px rgba(87, 204, 255, 0.2);
}

.sql-console-msg {
  margin-top: 0.75rem;
}

.sql-console-meta {
  margin: 0.5rem 0 0;
  font-size: 0.86rem;
  color: #8effb0;
}

.sql-console-table-wrap {
  margin-top: 1rem;
  overflow: auto;
  max-height: min(60vh, 560px);
  border-radius: 12px;
  border: 1px solid #233161;
  background: #0b132c;
}

.sql-console-table {
  width: 100%;
  border-collapse: collapse;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 0.82rem;
}

.sql-console-table th,
.sql-console-table td {
  padding: 0.45rem 0.65rem;
  text-align: left;
  border-bottom: 1px solid #233161;
  vertical-align: top;
  white-space: pre-wrap;
  word-break: break-word;
}

.sql-console-table th {
  position: sticky;
  top: 0;
  background: #101936;
  color: #9ad7ff;
  font-weight: 600;
  z-index: 1;
}

.sql-console-table tr:last-child td {
  border-bottom: none;
}

.sql-console-null {
  color: #7a8ab8;
  font-style: italic;
}

@media (min-width: 780px) {
  .hero {
    padding: 1.4rem 2.2rem 3rem;
  }

  .teams-section {
    padding: 1.75rem 2.2rem 0.75rem;
  }

  .players-section {
    padding: 1rem 2.2rem 0.75rem;
  }

  .dashboard {
    padding: 1.2rem 2.2rem 2rem;
  }

  .filters-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    align-items: end;
  }

  .kpi-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .charts-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Landing hero (inspired by IPL-style homepage layout) */
.landing-hero {
  padding: 2rem 1rem 1.2rem;
  background: linear-gradient(180deg, rgba(14, 25, 70, 0.65) 0%, rgba(7, 11, 23, 0) 100%);
  border-bottom: 1px solid rgba(35, 49, 97, 0.9);
}

.landing-hero__inner {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 0.2rem 0;
}

.landing-hero__badge {
  display: inline-flex;
  align-self: flex-start;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  background: rgba(142, 255, 176, 0.12);
  border: 1px solid rgba(142, 255, 176, 0.35);
  color: #bfffd0;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  font-size: 0.85rem;
}

.landing-hero__title {
  margin: 0.2rem 0 0;
  font-size: 2rem;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.landing-hero__subtitle {
  margin: 0;
  color: #a9b9e8;
  line-height: 1.55;
  max-width: 760px;
  font-size: 1rem;
}

.landing-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 0.1rem;
}

.landing-hero-highlights {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.55rem;
  color: #e7edff;
}

.landing-hero-highlights li {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(35, 49, 97, 0.75);
  border-radius: 14px;
  padding: 0.75rem 0.9rem;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.12);
}

@media (min-width: 900px) {
  .landing-hero {
    padding-top: 2.4rem;
  }
  .landing-hero-highlights {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .landing-hero__title {
    font-size: 2.4rem;
  }
}

/* ══════════════════════════════════════════
   CREATE YOUR OWN TEAM MODAL
══════════════════════════════════════════ */

.create-team-modal__dialog {
  max-width: 820px;
  max-height: 90vh;
  overflow-y: auto;
}

.create-team-modal__match-info {
  font-size: 1.05rem;
  font-weight: 700;
  color: #39d3ff;
  margin: 0.2rem 0 0.5rem;
}

.create-team-modal__counter {
  font-size: 0.88rem;
  color: #9ab;
  margin: 0 0 0.6rem;
}
.create-team-modal__counter strong { color: #8effb0; font-size: 1.05rem; }

.create-team-modal__cv-row {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 0.8rem;
}
.create-team-modal__cv-row label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #c8d6e5;
}
.create-team-modal__cv-select {
  margin-left: 0.3rem;
  padding: 0.35rem 0.6rem;
  border-radius: 6px;
  border: 1px solid rgba(57,211,255,0.3);
  background: rgba(10,20,50,0.8);
  color: #e7edff;
  font-size: 0.82rem;
  font-family: inherit;
}

.create-team-modal__search {
  width: 100%;
  padding: 0.6rem 0.9rem;
  border-radius: 8px;
  border: 1px solid rgba(57,211,255,0.2);
  background: rgba(10,20,50,0.6);
  color: #e7edff;
  font-size: 0.88rem;
  font-family: inherit;
  margin-bottom: 0.8rem;
  box-sizing: border-box;
}
.create-team-modal__search::placeholder { color: #556; }

.create-team-modal__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 0.5rem;
  max-height: 45vh;
  overflow-y: auto;
  padding: 0.25rem;
}

.ct-player-card {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.55rem 0.7rem;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(10,20,50,0.5);
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}
.ct-player-card:hover { border-color: rgba(57,211,255,0.3); background: rgba(10,20,50,0.7); }
.ct-player-card--selected {
  border-color: #8effb0;
  background: rgba(142,255,176,0.08);
}

.ct-player-card__check {
  width: 22px;
  height: 22px;
  border-radius: 4px;
  border: 2px solid rgba(255,255,255,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  color: #8effb0;
  flex-shrink: 0;
}
.ct-player-card--selected .ct-player-card__check {
  border-color: #8effb0;
  background: rgba(142,255,176,0.15);
}

.ct-player-card__info { flex: 1; min-width: 0; }
.ct-player-card__name { display: block; font-weight: 600; font-size: 0.88rem; color: #e7edff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ct-player-card__meta { display: flex; align-items: center; gap: 0.5rem; margin-top: 0.15rem; }
.ct-player-card__team { font-size: 0.72rem; color: #6b82c0; }

.create-team-modal__actions {
  display: flex;
  justify-content: flex-end;
  padding-top: 0.8rem;
}

.cta--outline {
  background: transparent;
  border: 2px solid #39d3ff;
  color: #39d3ff;
}
.cta--outline:hover { background: rgba(57,211,255,0.1); }

.cta--small {
  padding: 0.4rem 1rem;
  font-size: 0.82rem;
}

/* ══════════════════════════════════════════
   MY TEAMS PAGE
══════════════════════════════════════════ */

.my-teams-page { min-height: 80vh; }

.my-teams-page__login {
  text-align: center;
  font-size: 1.1rem;
  color: #c8d6e5;
  padding: 3rem 0;
}
.my-teams-page__login .lp-btn { margin-bottom: 1rem; }

.my-teams-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  padding-bottom: 3rem;
}

.my-team-card {
  background: rgba(10,20,50,0.7);
  border: 1px solid rgba(57,211,255,0.15);
  border-radius: 12px;
  padding: 1.2rem 1.4rem;
}

.my-team-card__header {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-bottom: 0.8rem;
}
.my-team-card__title-row {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  flex-wrap: wrap;
}
.my-team-card__header h3 { margin: 0; color: #e7edff; font-size: 1.05rem; }
.my-team-card__date { font-size: 0.82rem; color: #6b82c0; }
.my-team-card__venue { font-size: 0.78rem; color: #556; }
.my-team-card__status {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
}
.my-team-card__status--locked {
  background: rgba(255,107,107,0.12);
  color: #ff9999;
}
.my-team-card__status--open {
  background: rgba(142,255,176,0.12);
  color: #8effb0;
}
.my-team-card__edit-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: #39d3ff;
  background: rgba(57,211,255,0.1);
  border: 1px solid rgba(57,211,255,0.3);
  border-radius: 6px;
  padding: 0.22rem 0.65rem;
  text-decoration: none;
  transition: background 0.15s;
  white-space: nowrap;
}
.my-team-card__edit-btn:hover { background: rgba(57,211,255,0.2); }

.my-team-card__table {
  font-size: 0.82rem;
  margin-bottom: 0.8rem;
}

.my-team-card__compare {
  padding-top: 0.6rem;
  border-top: 1px solid rgba(255,255,255,0.06);
}

.my-team-card__compare-result {
  margin-top: 0.6rem;
  padding: 0.7rem;
  background: rgba(57,211,255,0.06);
  border-radius: 8px;
  font-size: 0.82rem;
  color: #c8d6e5;
  line-height: 1.6;
}
.my-team-card__compare-result strong { color: #39d3ff; }
