@import url('https://cdn.jsdelivr.net/npm/firago@1.0.0/css/firago.min.css');

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  /* ========================================
     BRAND COLORS: BLACK + SILVER + RED
  ======================================== */

  /* Backgrounds */
  --bg: #050505;                 /* Main page background */
  --bg-soft: #0d0d0d;            /* Secondary background */
  --panel: #141414;              /* Cards and panels */
  --panel-2: #1c1c1c;            /* Hover states */

  /* Borders */
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.16);

  /* Text */
  --text: #f3f4f6;               /* Main text */
  --muted: #9ca3af;              /* Secondary text */
  --white: #ffffff;

  /* Accent Colors */
  /*
  --accent: #dc2626;             /* Main red */ 
  /*
  --accent-dark: #b91c1c;        /* Darker red */
  /*
  --accent-light: #ef4444;       /* Lighter red */

  /* Accent Colors (Silver / Metallic) */
--accent: #d1d5db;        /* Main silver */
--accent-dark: #9ca3af;   /* Darker silver */
--accent-light: #f3f4f6;  /* Lighter silver */

  /* Silver / Metallic */
  --silver: #d1d5db;
  --silver-dark: #9ca3af;
  --silver-light: #f9fafb;

  /* Effects */
  --shadow: 0 12px 35px rgba(0, 0, 0, 0.45);
  --radius: 20px;

  /* Font weights */
  --fw-thin: 100;
  --fw-extralight: 200;
  --fw-light: 300;
  --fw-regular: 400;
  --fw-medium: 500;
  --fw-semibold: 600;
  --fw-bold: 700;
  --fw-extrabold: 800;
  --fw-black: 900;
}



html,
body {
  font-family: "FiraGO", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  background:
    radial-gradient(circle at top left, rgba(165, 165, 165, 0.08), transparent 28%),
    radial-gradient(circle at top right, rgba(165, 165, 165, 0.08), transparent 22%),
    var(--bg);
  color: var(--text);
  font-weight: var(--fw-regular);
  line-height: 1.5;
  min-height: 100vh;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

.container {
  width: min(1240px, 92%);
  margin: 0 auto;
}

/* Header */

header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(12px);
  background: rgba(5, 5, 5, 0.88);
  border-bottom: 1px solid var(--line);
}

.nav {
  min-height: 78px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.logo {
  display: inline-flex;
  align-items: center;
}

.logo-img {
  height: 52px;
  width: auto;
  display: block;
}

.nav-links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.nav-links a {
  color: var(--muted);
  font-size: 15px;
  font-weight: var(--fw-semibold);
  padding: 10px 14px;
  border-radius: 12px;
  transition: 0.22s ease;
}

.nav-links a:hover {
  color: var(--white);
  background: rgba(255, 255, 255, 0.05);
}

/* Mobile Menu */

.menu-toggle,
.menu-close {
  background: none;
  border: none;
  color: var(--white);
  cursor: pointer;
  padding: 0;
}

.menu-toggle {
  width: 46px;
  height: 46px;
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  flex-shrink: 0;
}

.menu-toggle span {
  width: 22px;
  height: 2px;
  background: var(--white);
  border-radius: 10px;
  display: block;
}

.desktop-nav {
  display: flex;
}

.mobile-menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(5, 5, 5, 0.96);
  opacity: 0;
  visibility: hidden;
  transition: 0.25s ease;
  z-index: 999;
}

.mobile-menu {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100dvh;
  background:
    radial-gradient(circle at top left, rgba(133, 133, 133, 0.08), transparent 28%),
    var(--bg);
  opacity: 0;
  visibility: hidden;
  transform: translateX(-24px);
  transition: 0.25s ease;
  z-index: 1000;
  padding: 22px 20px 32px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.mobile-menu.active {
  opacity: 1;
  visibility: visible;
  transform: translateX(0);
}

.mobile-menu-overlay.active {
  opacity: 1;
  visibility: visible;
}

.mobile-menu-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.menu-close {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  font-size: 34px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
}

.mobile-menu-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 10px;
}

.mobile-menu-links a {
  padding: 16px 14px;
  border-radius: 14px;
  color: var(--text);
  font-weight: 800;
  font-size: 18px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
  transition: 0.2s ease;
}

.mobile-menu-links a:hover {
  background: rgba(255, 255, 255, 0.06);
}

body.menu-open {
  overflow: hidden;
}

/* Sections */

section {
  padding: 48px 0;
}

.page-top {
  padding-top: 48px;
  padding-bottom: 0;
}

.hero {
  padding-top: 56px;
  padding-bottom: 44px;
}

.overview-section,
.last-matchday-section,
.in-form-section,
.month-leaders-section {
  padding-top: 52px;
  padding-bottom: 52px;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 20px;
  margin-bottom: 26px;
}

.section-head h2 {
  font-size: clamp(20px, 2.7vw, 30px);
  line-height: 1.1;
  margin-bottom: 8px;
}

.section-head p {
  color: var(--muted);
  max-width: 680px;
  font-size: 16px;
  line-height: 1.5;
}

.section-kicker {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(125, 125, 125, 0.12);
  color: var(--accent);
  font-size: 12px;
  font-weight: var(--fw-medium);
  letter-spacing: 0.3px;
  margin-bottom: 12px;
}

/* Hero */

.hero-box {
  background:
    linear-gradient(135deg,rgba(165, 165, 165, 0.08), transparent 40%),
    linear-gradient(180deg, var(--panel), var(--bg-soft));
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  border-radius: 28px;
  padding: 34px;
  display: grid;
  grid-template-columns: 1.3fr 0.9fr;
  gap: 22px;
  min-width: 0;
}

.hero-main {
  min-height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.hero-content {
  max-width: 760px;
}

.hero h1 {
  font-size: clamp(38px, 5.6vw, 58px);
  line-height: 1.02;
  margin-bottom: 14px;
}

.hero p {
  color: var(--muted);
  font-size: 17px;
  max-width: 680px;
  margin-bottom: 22px;
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero-buttons .btn {
  min-width: 190px;
}

.hero-buttons-bottom {
  margin-top: 40px;
  justify-content: flex-start;
  align-items: flex-end;
}

.hero-side {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 24px;
}

/* Buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 18px;
  border-radius: 14px;
  font-weight: 700;
  font-size: 15px;
  transition: 0.22s ease, transform 0.22s ease, box-shadow 0.22s ease;
}

/*
.btn:hover {
  transform: translateY(-2px);
}
  */

.btn-primary {
  background: #222222;
  color: #bcbcbc;
  font-weight: var(--fw-semibold);
}

.btn-primary:hover {
  background: #363636;
 /* box-shadow: 0 12px 24px rgba(220, 38, 38, 0.18); */
}

.btn-secondary {
  border: 1.2px solid rgba(118, 118, 118, 0.2);
  color: #bcbcbc;
  background: none;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.06);
}

/* Cards */

.cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.card {
  background: linear-gradient(180deg, var(--panel), var(--bg-soft));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
  min-width: 0;
}

.stat-label {
  color: var(--muted);
  font-size: 14px;
  font-weight: var(--fw-medium);
  margin-bottom: 12px;
}

.stat-value {
  font-size: clamp(32px, 3.8vw, 38px);
  line-height: 1.05;
  font-weight: var(--fw-semibold);
}

.stat-sub {
  color: var(--accent);
  font-size: 15px;
  line-height: 1.4;
  font-weight: var(--fw-semibold);
  margin-top: 8px;
}

/* Overview */

.overview-head {
  margin-bottom: 26px;
}

.overview-cards {
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.overview-card {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  padding: 24px;
  min-height: 170px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02)),
    linear-gradient(180deg, var(--panel), var(--bg-soft));
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.overview-card::before,
.overview-card-accent::before {
  content: none !important;
}

.overview-card-accent {
  border-color: rgba(220, 38, 38, 0.28);
  box-shadow:
    0 8px 24px rgba(220, 38, 38, 0.07),
    inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.overview-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.overview-card .stat-label {
  font-size: 14px;
  font-weight: var(--fw-medium);
  color: var(--muted);
  margin-bottom: 0;
}

.overview-card .stat-value {
  font-size: clamp(32px, 3.8vw, 38px);
  font-weight: var(--fw-bold);
  line-height: 1.05;
  margin-bottom: 12px;
}

.overview-card .stat-sub {
  font-size: 15px;
  font-weight: 700;
  font-weight: var(--fw-semibold);
}

/* Layout */

.content-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 18px;
  min-width: 0;
}

.panel {
  background: linear-gradient(180deg, var(--panel), var(--bg-soft));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
  min-width: 0;
}

.panel h3 {
  font-size: 24px;
  line-height: 1.15;
  margin-bottom: 18px;
}

/* Tables */

.table-wrap {
  overflow-x: auto;
  max-width: 100%;
}

table {
  width: 100%;
  border-collapse: collapse;
}

.table-wrap table {
  min-width: 720px;
}

th,
td {
  padding: 13px 10px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}

th {
  color: var(--muted);
  font-weight: 700;
  background: var(--panel);
}

.panel table th,
.panel table td {
   
  padding: 12px 8px;
  font-size: 14px;
  font-weight: var(--fw-semibold);
}

tbody tr:hover {
  background: rgba(255, 255, 255, 0.03);
}

/* Lists */

.mini-list {
  display: grid;
  gap: 10px;
}

.mini-item {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
  padding: 13px 14px;
  border-radius: 14px;
}

/* Filters */

.filters {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.filters label {
  color: var(--white);
  font-size: 15px;
  font-weight: var(--fw-medium);
}

.filters select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-color: var(--panel);
  color: var(--white);
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  padding: 12px 52px 12px 18px;
  min-width: 180px;
  font-size: 14px;
  font-weight: var(--fw-medium);
  line-height: 1;
  cursor: pointer;
  transition: 0.22s ease;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  background-size: 18px;
}

.filters select:hover {
  border-color: rgba(94, 94, 94, 0.45);
  background-color: var(--panel-2);
}

.filters select:focus {
  outline: none;
  border-color: rgba(94, 94, 94, 0.45);
}

/* Leaderboards */

.leaderboards-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 22px;
}

.rank-name {
  font-weight: 700;
}

.rank-value {
  color: var(--accent);
  font-weight: 800;
}

/* Records */

.records-grid {
  display: grid;
  margin-top: 15px;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.record-card {
  background: linear-gradient(180deg, var(--panel), var(--bg-soft));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
}

.record-label {
  color: var(--muted);
  font-size: 14px;
  font-weight: var(--fw-medium);
  margin-bottom: 10px;
}

.record-name {
  font-size: 20px;
  font-weight: var(--fw-semibold);
}

.record-value {
  font-size: clamp(30px, 3.8vw, 44px);
  line-height: 1.05;
  font-weight: var(--fw-bold);
  color: var(--accent);
}

.record-sub {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.4;
  font-weight: var(--fw-regular);
}

/* Matchdays */

.matchday-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.matchday-btn {
  background: var(--panel);
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 11px 15px;
  font-weight: var(--fw-semibold);
  cursor: pointer;
}

.matchday-btn.active {
  background: var(--bg);
  color: var(--white);
}

.matchday-summary-name {
  font-size: 16px;
  font-weight: var(--fw-semibold);
  color: var(--white);
  margin-bottom: 6px;
}

.matchday-summary-name a {
  color: var(--white);
  font-size: 16px;
}

.matchday-summary-name a:hover {
  color: var(--accent);
}

/* Player */

.player-link {
  font-size: 15px;
  font-weight: var(--fw-medium);
}

.player-link:hover {
  color: var(--accent);
  font-size: 15px;
}

.player-hero {
  display: flex;
  align-items: center;
  gap: 18px;
  background: linear-gradient(180deg, var(--panel), var(--bg-soft));
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 24px;
}

.player-hero-avatar {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  background: var(--panel-2);
  display: grid;
  place-items: center;
  font-size: 28px;
  font-weight: 800;
  color: var(--accent);
}

/* Top Performers */

.top-performers-box {
  display: flex;
  flex-direction: column;
  justify-content: center;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02)),
    linear-gradient(180deg, var(--panel), var(--bg-soft));
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  padding: 24px;
  box-shadow: var(--shadow);
}

.top-performers-head {
  margin-bottom: 18px;
}

.top-performers-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(125, 125, 125, 0.12);
  color: var(--accent);
  font-size: 12px;
  font-weight: var(--fw-medium);
  letter-spacing: 0.3px;
  margin-bottom: 10px;
}

.top-performers-head h3 {
  font-size: 24px;
  line-height: 1.15;
}

.top-performers-list {
  display: grid;
  gap: 14px;
}

.top-performer-item {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.035);
  transition: 0.22s ease;
}

.top-performer-item:hover {
  transform: translateY(-1px);
  border-color: rgba(220, 38, 38, 0.28);
  background: rgba(255, 255, 255, 0.05);
}

.top-performer-left {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.top-performer-label {
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.35px;
}

.top-performer-right {
  text-align: right;
  font-size: 16px;
  font-weight: 800;
  color: var(--white);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.top-performer-right a {
  color: var(--white);
}

.top-performer-right a:hover {
  color: var(--accent);
}

.top-performer-number {
  color: var(--accent);
  font-size: 14px;
  font-weight: 700;
}

/* Last Matchday */

.last-matchday-box {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.015)),
    linear-gradient(180deg, var(--panel), var(--bg-soft));
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 28px;
  padding: 28px;
  box-shadow: var(--shadow);
}

.last-matchday-top {
  margin-bottom: 24px;
}

.last-matchday-title-wrap {
  max-width: 720px;
}

.last-matchday-label {
  color: var(--muted);
  font-size: 14px;
  font-weight: var(--fw-medium);
  margin-bottom: 10px;
}

.last-matchday-title-wrap h3 {
      font-size: clamp(23px, 2.8vw, 34px);
  line-height: 1.02;
  font-weight: var(--fw-bold);
  margin-bottom: 10px;
  color: var(--white);
}

.last-matchday-title-wrap p {
  color: var(--accent);
  font-size: 14px;
  font-weight: var(--fw-medium);
}

.last-matchday-cards {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 18px;
}

.last-matchday-cards .card {
  min-height: 170px;
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02)),
    linear-gradient(180deg, var(--panel), var(--bg-soft));
}

.last-matchday-footer {
  margin-top: 24px;
  display: flex;
  justify-content: flex-start;
}

.last-matchday-footer .btn {
  
    padding: 8px 18px;
    margin-top: 10px;
    font-size: 14px;
    min-width: auto;
    min-height: 35px;
    font-weight: var(--fw-semibold);
}

/* In Form */

.in-form-cards {
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.in-form-cards .card {
  min-height: 170px;
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02)),
    linear-gradient(180deg, var(--panel), var(--bg-soft));
}

.in-form-list {
  display: grid;
  gap: 10px;
  margin-bottom: 12px;
}

.in-form-player-line {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
}

.in-form-player-name a {
  color: var(--white);
  font-weight: var(--fw-semibold);
}

.in-form-player-name a:hover {
  color: var(--accent);
}

.in-form-player-label {
  color: var(--accent);
  font-size: 14px;
  font-weight: 800;
  white-space: nowrap;
}

/* Month leaders */

.month-leaders-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.month-leaders-grid .panel {
  min-height: 170px;
  overflow: hidden;
}

.month-leaders-grid table {
  min-width: 100%;
}

.month-leaders-grid th,
.month-leaders-grid td {
  padding: 12px 8px;
  font-size: 15px;
}

.month-leaders-grid h3 {
  font-size: 22px;
}

.month-leaders-grid a {
  font-size: 15px;
  font-weight: var(--fw-semibold);
}


.month-blocks-wrap {
  margin-top: 18px;
}

/* Footer */

footer {
  padding: 34px 0 42px;
  color: #64748b;
  text-align: center;
}

/* Responsive */

@media (max-width: 1200px) {
  .month-leaders-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1100px) {
  .cards,
  .records-grid,
  .leaderboards-grid,
  .content-grid,
  .hero-box {
    grid-template-columns: 1fr;
  }

  .hero-main {
    min-height: auto;
  }

  .hero-buttons-bottom {
    margin-top: 28px;
  }

  .overview-cards,
  .last-matchday-cards,
  .in-form-cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 700px) {
  section {
    padding: 36px 0;
  }

  .hero {
    padding-top: 36px;
    padding-bottom: 36px;
  }

  .overview-section,
  .last-matchday-section,
  .in-form-section,
  .month-leaders-section {
    padding-top: 38px;
    padding-bottom: 38px;
  }

  .nav {
    min-height: 74px;
    padding: 14px 0;
    justify-content: space-between;
  }

  .menu-toggle {
    display: inline-flex;
  }

  .desktop-nav {
    display: none !important;
  }

  .logo {
    margin-left: auto;
  }

  .logo-img {
    height: 42px;
  }

  .cards,
  .records-grid,
  .overview-cards,
  .last-matchday-cards,
  .in-form-cards,
  .month-leaders-grid {
    grid-template-columns: 1fr;
  }

  .section-head {
    margin-bottom: 20px;
  }

  .section-head h2 {
    font-size: 28px;
  }

  .section-head p {
    font-size: 15px;
  }

  .hero-box,
  .card,
  .panel,
  .record-card,
  .last-matchday-box,
  .top-performers-box {
    padding: 18px;
  }

  .player-hero {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero-buttons {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }

  .hero-buttons .btn,
  .last-matchday-footer .btn {
    width: 100%;
    min-width: 0;
  }

  .top-performer-item {
    padding: 14px;
    border-radius: 16px;
  }

  .top-performers-head h3,
  .panel h3,
  .month-leaders-grid h3 {
    font-size: 22px;
  }

  .overview-card {
    padding: 20px 18px 22px;
    border-radius: 20px;
  }

  .stat-value,
  .overview-card .stat-value,
  .record-value {
    font-size: 36px;
  }

  .last-matchday-title-wrap h3 {
    font-size: 34px;
  }

  .last-matchday-title-wrap p {
    font-size: 16px;
  }

  th,
  td,
  .month-leaders-grid th,
  .month-leaders-grid td {
    font-size: 13px;
    padding: 11px 8px;
  }
}


/* =========================
   MATCHDAYS CLEAN MODERN
========================= */

.matchday-buttons {
  gap: 10px;
  margin-bottom: 22px;
}

.matchday-btn {
  background:
    linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.015)),
    linear-gradient(180deg, var(--panel), var(--bg-soft));
  color: var(--text);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 14px;
  padding: 11px 15px;
  font-size: 13px;
  font-weight: 700;
  box-shadow: 0 6px 18px rgba(0,0,0,0.16);
  transition: 0.2s ease;
}

.matchday-btn:hover {
  transform: translateY(-1px);
  border-color: var(--accent-light);
}

.matchday-btn.active {
  background: #323232;
  color: var(--white);
  border-color: var(--accent);
}

#selectedMatchdayTitle {
  font-size: clamp(20px, 2.7vw, 30px);
  line-height: 1.1;
  margin-bottom: 20px;
}

#matchdaySummaryCards {
  gap: 16px;
  margin-bottom: 22px;
}

#matchdaySummaryCards .card {
  min-height: 145px;
  border-radius: 20px;
  padding: 20px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.035), rgba(255,255,255,0.015)),
    linear-gradient(180deg, var(--panel), var(--bg-soft));
  border: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 10px 24px rgba(0,0,0,0.18);
}

#matchdaySummaryCards .stat-label {
  font-size: 13px;
  font-weight: var(--fw-medium);
  margin-bottom: 8px;
}

#matchdaySummaryCards .stat-value {
  font-size: clamp(26px, 3vw, 36px);
  font-weight: var(--fw-semibold);

}

#matchdaySummaryCards .stat-sub {
  font-size: 13px;
  font-weight: var(--fw-semibold);

}

.in-form-cards .stat-sub {
    color: #8c9095;
    font-size: 13px;
    line-height: 1.4;
    font-weight: var(--fw-medium);
    margin-top: 8px;
}

.matchday-summary-name {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 6px;
}

.panel {
  background:
    linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.012)),
    linear-gradient(180deg, var(--panel), var(--bg-soft));
  border: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 10px 24px rgba(0,0,0,0.18);
}

.panel h3 {
  font-size: 21px;
  font-weight: var(--fw-semibold);
  margin-bottom: 16px;
}

th,
td {
  font-size: 13px;
  padding: 11px 8px;
}

th {
  background: rgba(255,255,255,0.03);
  font-weight: 700;
}

tbody tr:hover {
  background: rgba(255, 255, 255, 0.04);
}

@media (max-width: 700px) {
  #selectedMatchdayTitle {
    font-size: 26px;
  }

  #matchdaySummaryCards .card {
    padding: 16px;
    min-height: auto;
  }

  .matchday-btn {
    width: 100%;
  }
}

/* =========================
   MODERN LEADERBOARDS PAGE
========================= */

.leaderboards-hero {
  padding-top: 58px;
  padding-bottom: 34px;
}

.leaderboards-hero h1 {
  font-size: clamp(25px, 3.6vw, 32px);
  line-height: 1.02;
  margin-bottom: 12px;
}

.leaderboards-hero p {
  color: var(--muted);
  font-size: 16px;
  max-width: 720px;
  font-weight: var(--fw-medium);
  margin-bottom: 24px;
}

.leaderboard-filters {
  margin-top: 8px;
}

.leaderboard-section {
  padding-top: 42px;
  padding-bottom: 42px;
}

.leaderboard-section + .leaderboard-section {
  padding-top: 54px;
}

.leaderboard-section-head {
  margin-bottom: 24px;
}

.leaderboard-section-head h2 {
  font-size: clamp(22px, 2.8vw, 32px);
  line-height: 1.1;
}

.leaderboards-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.leaderboard-panel {
  border-radius: 26px;
  padding: 24px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.04), rgba(255,255,255,0.018)),
    linear-gradient(180deg, var(--panel), var(--bg-soft));
  border: 1px solid rgba(255,255,255,0.09);
  box-shadow: 0 14px 35px rgba(0,0,0,0.24);
}

.leaderboard-panel h3 {
  font-size: 22px;
  margin-bottom: 18px;
}

.leaderboard-panel table {
  width: 100%;
}

.leaderboard-panel th,
.leaderboard-panel td {
  font-size: 14px;
  padding: 13px 10px;
}

.leaderboard-panel th:first-child,
.leaderboard-panel td:first-child {
  width: 48px;
  color: var(--accent);
  font-weight: 800;
}

.leaderboard-panel td:nth-child(2) {
  font-weight: 800;
}

.leaderboard-panel td:last-child {
  color: var(--white);
  font-weight: 800;
}

.leaderboard-panel tbody tr:hover {
  background: rgba(255, 255, 255, 0.045);
}

@media (max-width: 1100px) {
  .leaderboards-grid {
    grid-template-columns: 1fr;
  }

  .leaderboards-hero {
    padding-top: 42px;
  }
}

@media (max-width: 700px) {
  .leaderboards-hero h1 {
    font-size: 38px;
  }

  .leaderboards-hero p {
    font-size: 15px;
  }

  .leaderboard-section {
    padding-top: 34px;
    padding-bottom: 34px;
  }

  .leaderboard-panel {
    padding: 18px;
    border-radius: 22px;
  }

  .leaderboard-panel h3 {
    font-size: 20px;
  }

  .leaderboard-panel th,
  .leaderboard-panel td {
    font-size: 13px;
    padding: 11px 8px;
  }
}

.metric-rule {
  display: inline-flex;
  margin-left: 8px;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(125, 125, 125, 0.12);
  color: var(--accent);
  font-size: 11px;
  font-weight: var(--fw-medium);
  vertical-align: middle;
  white-space: nowrap;
}

  

.leaderboard-title {
  margin-bottom: 24px;
}

.leaderboard-title h3 {
  margin: 0 0 8px;
}

.leaderboard-title p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}


.stats-search {
  margin-bottom: 24px;
}

.stats-search input {
  width: 100%;
  max-width: 420px;
  padding: 14px 18px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.10);
  background: rgba(255, 255, 255, 0.05);
  color: var(--white);
  font-size: 15px;
  outline: none;
  transition: 0.2s ease;
}

.stats-search input::placeholder {
  color: var(--muted);
}

.stats-search input:focus {
  border-color: #9ca3af;
  background: rgba(255, 255, 255, 0.07);
}

@media (max-width: 700px) {
  .stats-search input {
    max-width: 100%;
  }
}


/* ========================================
   ALL STATS SEARCH + FILTER CONTROLS
======================================== */

.all-stats-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
}

.stats-search {
  position: relative;
  flex: 1;
  max-width: 440px;
  margin-bottom: 0;
}

.stats-search-icon {
  position: absolute;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  color: var(--muted);
  pointer-events: none;
}

.stats-search-icon svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.stats-search input {
  width: 100%;
  height: 56px;
  padding: 0 18px 0 50px;
  border-radius: 16px;
  border: 1px solid var(--line-strong);
  background: var(--panel);
  color: var(--white);
  font-size: 16px;
  font-weight: var(--fw-semibold);
  outline: none;
  transition: 0.22s ease;
}

.stats-search input::placeholder {
  color: var(--muted);
  font-weight: var(--fw-medium);
}

.stats-search input:hover {
  border-color: #696c71;
  background: var(--panel-2);
}

.stats-search input:focus {
  border-color: var(--accent);
  background: var(--panel-2);

}

.all-stats-controls .filters {
  margin: 0;
  flex-shrink: 0;
}

@media (max-width: 800px) {
  .all-stats-controls {
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
  }

  .stats-search {
    max-width: 100%;
  }

  .all-stats-controls .filters {
    width: 100%;
    justify-content: space-between;
  }

  .all-stats-controls .filters select {
    flex: 1;
    min-width: 0;
  }
}


/* Make search bar the same height as the period filter */
.stats-search input {
  height: 48px;
  padding: 0 18px 0 48px;
  border-radius: 14px;
  font-size: 15px;
}

.stats-search-icon {
  left: 16px;
  width: 17px;
  height: 17px;
}

/* Match filter alignment */
.all-stats-controls .filters {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
}

/* Ensure both controls align perfectly */
.stats-search input,
.all-stats-controls .filters select {
  box-sizing: border-box;
}


.matchday-video-box {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 14px;
  align-items: center;

  width: 40%;
  min-width: 420px;
  max-width: 520px;

  margin: 24px 0 42px;
  padding: 12px;

  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.035), rgba(255,255,255,0.015)),
    linear-gradient(180deg, var(--panel), var(--bg-soft));
  border: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 8px 20px rgba(0,0,0,0.18);
  transition: 0.22s ease;
}

.matchday-video-box:hover {
  transform: translateY(-2px);
  border-color: #3e3e3f;
}

.matchday-video-thumb {
  aspect-ratio: 16 / 9;
  border-radius: 12px;
  overflow: hidden;
  background: var(--panel-2);
}

.matchday-video-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.matchday-video-placeholder {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  color: var(--white);
  font-size: 24px;
  background: rgba(255,255,255,0.05);
}

.matchday-video-info span {
  color: var(--accent);
  font-size: 11px;
  font-weight: var(--fw--semibold);
  letter-spacing: 0.4px;
}

.matchday-video-info h3 {
  font-size: 20px;
  line-height: 1.2;
  font-weight: var(--fw-bold);
  margin: 4px 0;
  color: var(--white);
}

.matchday-video-info p {
  color: var(--muted);
  font-size: 13px;
  font-weight: var(--fw-medium);
  margin: 0;
}

@media (max-width: 900px) {
  .matchday-video-box {
    width: 100%;
    min-width: 0;
    max-width: none;
  }
}

@media (max-width: 700px) {
  .matchday-video-box {
    grid-template-columns: 1fr;
    gap: 12px;
    margin: 20px 0 36px;
  }
}



/* ========================================
   COMPACT TOP PERFORMERS HERO
======================================== */

.hero-top-performers {
  padding: 24px;
}

.top-performers-head {
  margin-bottom: 18px;
}

.top-performers-head h2 {
  font-size: clamp(20px, 2.7vw, 30px);
  line-height: 1.1;
  margin: 6px 0 0;
}

.hero-performers-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 0;
}

.hero-top-list {
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
}



.hero-top-list-items {
  display: grid;
  gap: 6px;
}

.hero-top-list-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.025);
}

.hero-top-list-row > div:first-child {
  min-width: 0;
  flex: 1;
}

.hero-top-list-row a {
  font-size: 14px;
  font-weight: 700;
  color: var(--white);
}

.hero-top-list-row a:hover {
  color: var(--accent);
}

.hero-top-list-row strong {
  font-size: 13px;
  font-weight: 800;
  color: var(--accent);
  white-space: nowrap;
}

.hero-rank {
  display: inline-block;
  width: 24px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.hero-performers-buttons {
  display: flex;
  justify-content: flex-end; /* move buttons to the right */
  gap: 12px;
  margin-top: 18px;
}

.hero-performers-buttons .btn {
  padding: 8px 18px;
  margin-top: 30px;
  font-size: 14px;
  min-width: auto;
  min-height: 35px;
  font-weight: var(--fw-semibold);

}

/* Tablet */
@media (max-width: 900px) {
  .hero-performers-grid {
    grid-template-columns: 1fr;
  }

  .hero-performers-buttons {
    justify-content: stretch;
  }

  .hero-performers-buttons .btn {
    flex: 1;
  }
}

/* Mobile */
@media (max-width: 700px) {
  .hero-top-performers {
    padding: 18px;
  }

  .hero-top-list {
    padding: 12px;
  }

  .hero-top-list h3 {
    font-size: 15px;
  }

  .hero-top-list-row {
    padding: 7px 8px;
  }

  .hero-top-list-row a {
    font-size: 13px;
  }

  .hero-top-list-row strong {
    font-size: 12px;
  }

  .hero-performers-buttons {
    flex-direction: column;
  }

  .hero-performers-buttons .btn {
    width: 100%;
  }
}

.hero-top-list {
  padding: 20px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.hero-top-list h3 {
  font-size: clamp(14px, 1.2vw, 24px);
  font-weight: var(--fw-medium);
  color: var(--accent-dark);
  margin: 0 0 14px;
}

.hero-top-single {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.hero-top-single-name a {
  font-size: 18px;
  font-weight: var(--fw-semibold);
  color: var( --silver-light);
}

.hero-top-single-name .player-link {
  font-size: 18px;
}

.hero-top-single-name a:hover {
  color: var(--accent);
}

.hero-top-single-value {
  font-size: 24px;
  font-weight: var(--fw-bold);
  color: var(--accent);
  line-height: 1;
}

.hero-top-single-sub {
  font-size: 12px;
  font-weight: var(--fw-medium);
  color: #888b91;
  letter-spacing: 0.4px;
}

/* Top Performers: 4 cards in one row */
.hero-performers-grid,
#topPerformers {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

/* Large tablets */
@media (max-width: 1200px) {
  .hero-performers-grid,
  #topPerformers {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Mobile */
@media (max-width: 700px) {
  .hero-performers-grid,
  #topPerformers {
    grid-template-columns: 1fr;
  }
}

.hero-top-single-value-row {
  display: flex;
  align-items: baseline;
  justify-content: flex-start;
  gap: 8px; /* smaller gap */
}




.player-chart-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 18px;
}

.player-chart-btn {
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  transition: 0.2s ease;
}

.player-chart-btn:hover,
.player-chart-btn.active {
  background: #4c4e51;
  border-color: var(--accent);
  color: var(--white);
}

body.menu-open {
  overflow: hidden;
}

.mobile-menu {
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}



.matchday-video-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: 12px;
  overflow: hidden;
  background: var(--panel-2);
}

.matchday-video-thumb::after {
  content: "▶";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;

  background: rgba(0, 0, 0, 0.65);
  color: #ffffff;
  font-size: 20px;
  font-weight: 900;

  pointer-events: none;
  z-index: 2;
  transition: 0.2s ease;
}

.matchday-video-box:hover .matchday-video-thumb::after {
  transform: translate(-50%, -50%) scale(1.08);
  background: rgba(220, 38, 38, 0.9);
}

.matchday-video-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}



#playerSummaryCards .stat-label {
  font-size: 16px;
}






/* ==========================================
   FINAL MOBILE POLISH
   Add this at the very end of style.css
========================================== */
@media (max-width: 700px) {

  /* Layout */
  .container {
    width: calc(100% - 24px);
  }

  section {
    padding: 32px 0;
  }

  /* Typography */
  h1 {
    font-size: clamp(30px, 8vw, 40px) !important;
    line-height: 1.08 !important;
  }

  h2 {
    font-size: clamp(24px, 6vw, 30px) !important;
    line-height: 1.15 !important;
  }

  h3 {
    font-size: 20px !important;
    line-height: 1.2 !important;
  }

  p {
    font-size: 15px;
    line-height: 1.6;
  }

  /* Hero */
  .hero {
    padding-top: 24px;
    padding-bottom: 24px;
  }

  .hero-box {
    padding: 18px;
    border-radius: 20px;
    gap: 18px;
  }

  .hero p {
    font-size: 15px;
    margin-bottom: 18px;
  }

  /* Cards */
  .card,
  .panel,
  .record-card,
  .overview-card,
  .top-performers-box,
  .last-matchday-box,
  .hero-top-list {
    padding: 16px !important;
    border-radius: 18px !important;
  }

  /* Stat Values */
  .stat-value,
  .overview-card .stat-value,
  .record-value {
    font-size: clamp(28px, 8vw, 36px) !important;
    line-height: 1.05;
  }

  .stat-label,
  .record-label {
    font-size: 13px !important;
  }

  .stat-sub,
  .record-sub {
    font-size: 13px !important;
  }

  /* Section headings */
  .section-head {
    margin-bottom: 18px;
    gap: 10px;
  }

  .section-head h2 {
    font-size: 24px !important;
    margin-bottom: 4px;
  }

  .section-head p {
    font-size: 14px;
  }

  /* Buttons */
  .btn {
    min-height: 44px;
    font-size: 14px;
    padding: 0 16px;
    border-radius: 12px;
  }

  /* Tables */
  .table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  table {
    min-width: 600px;
  }

  th,
  td {
    font-size: 12px !important;
    padding: 10px 8px !important;
    white-space: nowrap;
  }

  /* Filters */
  .filters {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .filters select {
    width: 100%;
    min-width: 0;
    font-size: 14px;
  }

  /* Search */
  .stats-search input {
    height: 46px;
    font-size: 14px;
    padding-left: 44px;
  }

  /* Matchday buttons */
  .matchday-buttons {
    gap: 8px;
  }

  .matchday-btn {
    width: 100%;
    padding: 12px;
    font-size: 13px;
  }

  /* Matchday video */
  .matchday-video-box {
    width: 100%;
    min-width: 0;
    margin: 20px 0 30px;
    padding: 10px;
    border-radius: 16px;
  }

  .matchday-video-info h3 {
    font-size: 17px;
  }

  .matchday-video-info p {
    font-size: 12px;
  }

  /* Top performers */
  .hero-top-single-name a,
  .hero-top-single-name .player-link {
    font-size: 16px;
  }

  .hero-top-single-value {
    font-size: 22px;
  }

  /* Player hero */
  .player-hero {
    padding: 18px;
    gap: 14px;
  }

  .player-hero-avatar {
    width: 68px;
    height: 68px;
    font-size: 24px;
  }

  /* Footer */
  .site-footer {
    margin-top: 60px;
    padding: 50px 0 24px;
  }

  .footer-grid {
    gap: 28px;
  }

  .footer-column h4 {
    font-size: 15px;
    margin-bottom: 14px;
  }

  .footer-nav a {
    font-size: 14px;
  }

  .footer-social-link {
    width: 40px;
    height: 40px;
  }

  .footer-social-link svg {
    width: 20px;
    height: 20px;
  }

  .footer-bottom p {
    font-size: 12px;
  }
}



@media (max-width: 700px) {
  .nav {
  min-height: 62px;
  padding: 10px 0;
  justify-content: space-between;
}

.menu-toggle {
  display: inline-flex;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  gap: 4px;
}

.menu-toggle span {
  width: 18px;
  height: 2px;
}

.logo-img {
  height: 36px;
}

 .mobile-menu {
    padding: 10px 12px 24px;
    gap: 22px;
  }

  .mobile-menu-head {
    min-height: 62px;
  }

 .menu-close {
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: 10px;
    font-size: 0; /* hide the × character size */
    line-height: 1;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--line);
    color: var(--white);
    position: relative;
  }

  /* Draw the X manually so it matches the burger icon size */
  .menu-close::before,
  .menu-close::after {
    content: "";
    position: absolute;
    width: 18px;   /* same visual width as burger lines */
    height: 2px;
    border-radius: 10px;
    background: currentColor;
  }

  .menu-close::before {
    transform: rotate(45deg);
  }

  .menu-close::after {
    transform: rotate(-45deg);
  }

  .mobile-menu .logo-img {
    height: 36px;
  }

  .mobile-menu-links {
    gap: 8px;
    margin-top: 4px;
  }

  .mobile-menu-links a {
    padding: 13px 14px;
    border-radius: 14px;
    font-size: 16px;
    font-weight: 700;
}

 .mobile-menu {
    padding-top: 0;
  }

  .mobile-menu-head {
    min-height: 62px;
    padding: 10px 0;
    align-items: center;
  }

  .mobile-menu .logo-img {
    height: 36px;
  }

  .menu-close {
    width: 40px;
    height: 40px;
  }



   .hero-performers-grid,
  #topPerformers {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .hero-top-list {
    padding: 14px;
    border-radius: 16px;
  }

  .hero-top-list h3 {
    font-size: 1px;
    margin-bottom: 10px;
  }

  .hero-top-single-name a,
  .hero-top-single-name .player-link {
    font-size: 14px;
  }

  .hero-top-single-value {
    font-size: 10px;
  }

  .hero-top-single-sub {
    font-size: 8px;
  }

    .hero-top-single-value-row {
    display: flex;
    align-items: baseline;
    gap: 4px;
    flex-wrap: nowrap;
  }

  .hero-top-single-value {
    font-size: 18px;
    line-height: 1;
    margin: 0;
  }

  .hero-top-single-sub {
    font-size: 11px;
    line-height: 1;
    margin: 0;
    white-space: nowrap;
    display: none;
  }

  .hero-top-list h3 {
    font-size: 14px !important;
  }

  .hero-performers-buttons {
    display: flex;
    flex-direction: row !important;
    justify-content: flex-end;
    align-items: center;
    gap: 8px;
    margin-top: 25px !important;
  }

  .hero-performers-buttons .btn {
    width: auto !important;
    flex: 0 0 auto;
    min-width: auto;
    margin-top: 0;
    white-space: nowrap;
  }

    .overview-cards {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px;
  }

  .overview-card {
    min-height: 150px;
    padding: 16px !important;
  }

  .overview-card .stat-value {
    font-size: 24px !important;
  }

  .overview-card .stat-label {
    font-size: 12px !important;
  }

  .overview-card .stat-sub {
    font-size: 12px !important;
    line-height: 1.3;
  }

   .overview-card {
    min-height: auto !important;
    height: auto !important;
    padding: 16px !important;
  }

  .overview-card .stat-value {
    margin-bottom: 6px;
  }

  .overview-card .stat-sub {
    margin-top: 4px;
    line-height: 1.25;
  }

  
  .last-matchday-cards {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px;
  }

  .last-matchday-cards .card {
    min-height: auto !important;
    height: auto !important;
    padding: 16px !important;
  }

  .last-matchday-cards .stat-value {
    font-size: 28px !important;
    margin-bottom: 6px;
  }

  .last-matchday-cards .stat-label {
    font-size: 12px;
  }

  .last-matchday-cards .stat-sub {
    font-size: 12px;
    line-height: 1.25;
    margin-top: 4px;
  }

  .last-matchday-title-wrap p {
    display: none;
  }

  .last-matchday-label {
    font-size: 12px;
  }
    .last-matchday-footer .btn {
    width: auto !important;
    min-width: auto !important;
    flex: 0 0 auto;
    padding: 8px 18px;
  }

  .last-matchday-footer {
    display: flex;
    justify-content: flex-end;
  }

  .last-matchday-footer .btn {
    width: auto !important;
    min-width: auto !important;
    flex: 0 0 auto;
    padding: 8px 18px;
  }

    .in-form-cards {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px;
  }

  .in-form-cards .card {
    min-height: auto !important;
    height: auto !important;
    padding: 16px !important;
  }

  .in-form-cards .stat-value {
    font-size: 28px !important;
    margin-bottom: 6px;
  }

  .in-form-cards .stat-label {
    font-size: 12px;
  }

  .in-form-cards .stat-sub {
    display: none;
  }

   .in-form-player-line {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }

  .in-form-player-label {
    white-space: normal;
  }

   .month-leaders-grid {
    gap: 30px !important; 
  }

   .matchday-buttons {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
  }

  .matchday-btn {
    width: 100% !important;
    min-width: 0;
    padding: 8px 6px;
    font-size: 12px;
    text-align: center;
    white-space: nowrap;
  }

   .matchday-video-box {
    width: 100%;
    max-width: 260px;   /* adjust to 240px or 280px if needed */
    min-width: 0;
    margin: 16px 0 28px;
    padding: 14px; /* increased inner spacing */
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .matchday-video-info h3 {
    font-size: 15px;
    margin: 2px 0;
  }

  .matchday-video-info p {
    font-size: 11px;
  }

    #matchdaySummaryCards {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  #matchdaySummaryCards .card {
    min-height: auto !important;
    height: auto !important;
    padding: 16px !important;
  }

  #matchdaySummaryCards .stat-value {
    font-size: 28px !important;
    margin-bottom: 6px;
  }

  #matchdaySummaryCards .stat-label {
    font-size: 12px;
  }

  #matchdaySummaryCards .stat-sub {
    font-size: 12px;
    line-height: 1.25;
    margin-top: 4px;
  }

  /* All Stats page: force Period label and filter onto one line */
@media (max-width: 700px) {
  /* Parent wrapper */
  .filters {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: flex-start !important;
    flex-wrap: nowrap !important;
    gap: 10px !important;
  }

  /* Period label */
  .filters label,
  .filters .filter-label,
  .filters > span,
  .filters > p {
    margin: 0 !important;
    white-space: nowrap !important;
    flex: 0 0 auto !important;
  }

  /* Select element */
  .filters select {
    width: auto !important;
    min-width: 140px !important;
    max-width: 140px !important;
    flex: 0 0 auto !important;
    display: inline-block !important;

    padding: 9px 34px 9px 14px !important;
    font-size: 13px !important;
    border-radius: 14px !important;
  }
}

  
}

/* Fix table lines overflowing outside leaderboard boxes */
.leaderboard-panel {
  overflow: hidden;
}

.leaderboard-panel table {
  width: 100%;
  min-width: 0 !important;
}

.leaderboard-panel th,
.leaderboard-panel td {
  box-sizing: border-box;
}

@media (max-width: 700px) {
  .leaderboard-panel {
    overflow: hidden;
  }

  .leaderboard-panel table {
    width: 100%;
    min-width: 0 !important;
  }

  /* Center the values column (numbers to the right of player names) */
.leaderboard-panel th:last-child,
.leaderboard-panel td:last-child {
  text-align: center !important;
}

/* Leaderboards: slightly smaller player names */
.leaderboard-panel td:nth-child(2) {
  font-size: 0.95em !important; /* slightly smaller than default */
}
}


/* Records page: show cards in 2 columns on mobile */
@media (max-width: 700px) {
  .records-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px;
  }

  .record-card {
    padding: 14px !important;
    border-radius: 18px !important;
    min-height: auto !important;
    height: auto !important;
  }

  .record-value {
    font-size: 28px !important;
    line-height: 1.05;
    margin-bottom: 6px;
  }

  .record-label {
    font-size: 12px !important;
    line-height: 1.25;
  }

  .record-sub {
    font-size: 11px !important;
    line-height: 1.3;
    margin-top: 4px;
  }

  .record-name {
    font-size: 14px !important;
  }
  

  
}


/* ==========================================
   PLAYER PAGE HERO: 2-COLUMN MOBILE LAYOUT
   Avatar on left, name + stats on right
========================================== */
@media (max-width: 700px) {
  .player-hero {
    display: grid !important;
    grid-template-columns: 68px 1fr;
    align-items: start;
    gap: 14px;
    padding: 18px !important;
  }

  .player-hero .stat-label {
font-size: 13px !important;
margin-bottom: 10px;
  }

  

  .player-hero-avatar {
    width: 68px;
    height: 68px;
    font-size: 24px;
    margin: 0;
    flex-shrink: 0;
  }

  /* Right column */
  .player-hero-content,
  .player-hero-info {
    min-width: 0;
  }

  .player-hero h1,
  .player-hero h2 {
    margin-bottom: 8px;
    font-size: 22px !important;
    line-height: 1.1;
  }

  .player-hero p {
    font-size: 14px !important;
  }

  /* Stats under the name */
  .player-hero .stat-sub,
  .player-hero-meta,
  .player-hero-stats {
    font-size: 13px;
    line-height: 1.4;
  }

  #playerSummaryCards,
  .player-summary-cards,
  .player-cards {
    display: grid;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px;
  }

  #playerSummaryCards .card,
  .player-summary-cards .card,
  .player-cards .card {
    min-height: auto !important;
    height: auto !important;
    padding: 16px !important;
  }

  #playerSummaryCards .stat-value,
  .player-summary-cards .stat-value,
  .player-cards .stat-value {
    font-size: 28px !important;
    margin-bottom: 6px;
  }

  #playerSummaryCards .stat-label,
  .player-summary-cards .stat-label,
  .player-cards .stat-label {
    font-size: 12px !important;
  }

  #playerSummaryCards .stat-sub,
  .player-summary-cards .stat-sub,
  .player-cards .stat-sub {
    font-size: 12px !important;
    line-height: 1.25;
    margin-top: 4px;
  }

  .player-chart-wrap canvas,
  .player-chart canvas {
    max-height: 260px;
  }

  /* Chart.js renders labels on canvas, so reduce the overall chart font size */
  .player-chart-wrap,
  .player-chart {
    font-size: 11px;
  }



  /* .panel itself does not have bottom margin.
   The spacing comes from the parent grid's gap. */



    body:has(.player-hero) section {
    padding-top: 15px !important;
    padding-bottom: 15px !important;
  }

  body:has(.player-hero) .content-grid,
  body:has(.player-hero) .month-leaders-grid,
  body:has(.player-hero) .leaderboards-grid,
  body:has(.player-hero) .cards {
    gap: 10px !important;
  }

  body:has(.player-hero) .panel {
    margin-top: 0 !important;
    margin-bottom: 10px !important;
  }
}


/* Smooth modern mobile menu animation */
.mobile-menu-overlay {
  transition: opacity 0.35s ease, visibility 0.35s ease;
}

.mobile-menu {
  transform: translateX(-100%);
  opacity: 1;
  visibility: hidden;
  transition:
    transform 0.42s cubic-bezier(0.22, 1, 0.36, 1),
    visibility 0.42s;
  will-change: transform;
}

.mobile-menu.active {
  transform: translateX(0);
  visibility: visible;
}

/* Animate menu items one by one */
.mobile-menu-links a {
  opacity: 0;
  transform: translateX(-12px);
  transition:
    opacity 0.28s ease,
    transform 0.28s ease,
    background 0.2s ease;
}

.mobile-menu.active .mobile-menu-links a {
  opacity: 1;
  transform: translateX(0);
}

.mobile-menu.active .mobile-menu-links a:nth-child(1) { transition-delay: 0.08s; }
.mobile-menu.active .mobile-menu-links a:nth-child(2) { transition-delay: 0.11s; }
.mobile-menu.active .mobile-menu-links a:nth-child(3) { transition-delay: 0.14s; }
.mobile-menu.active .mobile-menu-links a:nth-child(4) { transition-delay: 0.17s; }
.mobile-menu.active .mobile-menu-links a:nth-child(5) { transition-delay: 0.20s; }
.mobile-menu.active .mobile-menu-links a:nth-child(6) { transition-delay: 0.23s; }
.mobile-menu.active .mobile-menu-links a:nth-child(7) { transition-delay: 0.26s; }

/* Smooth mobile menu animation (no staggered item reveal) */
.mobile-menu-overlay {
  transition: opacity 0.45s ease, visibility 0.45s ease;
}

.mobile-menu {
  transform: translateX(-100%);
  opacity: 1;
  visibility: hidden;
  will-change: transform;

  transition:
    transform 0.55s cubic-bezier(0.22, 1, 0.36, 1),
    visibility 0.55s;
}

.mobile-menu.active {
  transform: translateX(0);
  visibility: visible;
}

/* Menu links appear immediately */
.mobile-menu-links a {
  opacity: 1;
  transform: none;
  transition: background 0.2s ease, border-color 0.2s ease;
}


 


