/* The M8 section (/m8/ and the team pages). Same surface language as the tier list and the news: navy ground, flat panels,
   hairline borders, one mint accent, Exo 2 for names and numbers. The live block itself is styled by m8.css. */
.esports-page {
  --j-ground: #0a1a2f; --j-panel: #0f2236; --j-raised: #142b42; --j-hover: #17304a;
  --j-line: #243b52; --j-line-strong: #34506b; --j-ink: #f1f5f8; --j-text: #d5dee7; --j-muted: #9fb0c0; --j-faint: #7d93a7;
  --j-accent: #00ff9d; --j-accent-ink: #04271b; --j-red: #ef6b6b; --j-gutter: clamp(16px, 4vw, 48px);
  padding-bottom: 48px; color: var(--j-text);
}
.esports-hub { padding-top: 104px; }
.esports-hub > .arena-mast { margin-bottom: 8px; }
.esports-hub .m8hub { padding-top: 0; }
.esports-block { margin: 40px 0 0; }
.esports-block > h2 { margin: 0 0 16px; color: var(--j-ink); font-size: clamp(1.375rem, 2.4vw, 1.625rem); font-weight: 650; letter-spacing: -.02em; }
.esports-note { margin: -6px 0 16px; color: var(--j-muted); font-size: .9375rem; line-height: 1.55; }
.esports-note a, .esports-more a { color: var(--j-accent); text-decoration: none; }
.esports-note a:hover, .esports-more a:hover { text-decoration: underline; }
.esports-more { margin: 12px 0 0; font-size: .9375rem; }

/* CIS teams on the hub */
.cis-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.cis-card { display: grid; gap: 12px; padding: 18px; border: 1px solid var(--j-line); border-radius: 14px; background: var(--j-panel); color: var(--j-text); text-decoration: none; transition: border-color .15s, background .15s; }
.cis-card:hover, .cis-card:focus-visible { border-color: var(--j-line-strong); background: var(--j-raised); }
.cis-card__top { display: flex; align-items: center; gap: 12px; }
.cis-card__top b { display: block; color: var(--j-ink); font-family: 'Exo 2', sans-serif; font-size: 1.1875rem; font-weight: 600; }
.cis-card__top small { color: var(--j-muted); font-size: .875rem; }
.cis-card__start { color: var(--j-accent); font-size: .9375rem; font-weight: 600; }
.cis-card__roster { color: var(--j-muted); font-size: .875rem; line-height: 1.5; }

/* Hero chips (meta, team heroes) */
/* 6, 12: always full rows at 6, 3 and 2 columns. */
.ehero-row { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; }
.ehero { display: flex; align-items: center; gap: 10px; padding: 8px 12px 8px 8px; border: 1px solid var(--j-line); border-radius: 12px; background: var(--j-panel); color: var(--j-text); text-decoration: none; min-width: 0; }
.ehero:hover, .ehero:focus-visible { border-color: var(--j-line-strong); background: var(--j-raised); }
.ehero img { flex: none; width: 44px; height: 44px; border-radius: 10px; object-fit: cover; }
.ehero span { display: grid; min-width: 0; }
.ehero b { color: var(--j-ink); font-size: .9375rem; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ehero small { color: var(--j-muted); font-size: .8125rem; }

/* Team page head */
.team-page .page-back { margin-top: 20px; }
.team-head { display: grid; grid-template-columns: auto 1fr; gap: 20px; align-items: center; margin: 20px 0 8px; }
.team-head__logo { display: grid; place-items: center; width: 104px; height: 104px; border: 1px solid var(--j-line); border-radius: 20px; background: var(--j-panel); }
.team-head__logo .tl { --s: 72px; }
.team-head h1 { margin: 0; color: var(--j-ink); font-family: 'Exo 2', sans-serif; font-size: clamp(2rem, 4.4vw, 2.875rem); font-weight: 700; letter-spacing: -.01em; line-height: 1.05; }
.team-head__sub { margin: 6px 0 0; color: var(--j-muted); font-size: 1rem; }
.team-facts { display: flex; flex-wrap: wrap; gap: 8px 32px; margin: 16px 0 0; }
.team-facts div { display: grid; gap: 2px; }
.team-facts dt { color: var(--j-muted); font-size: .8125rem; }
.team-facts dd { margin: 0; color: var(--j-ink); font-size: 1.0625rem; font-weight: 600; }

/* Roster */
/* One row on a computer whatever the roster size (--n is set by the page). */
.players { display: grid; grid-template-columns: repeat(var(--n, 5), minmax(0, 1fr)); gap: 12px; margin: 0; padding: 0; list-style: none; }
.player { display: grid; align-content: start; gap: 4px; padding: 16px; border: 1px solid var(--j-line); border-radius: 14px; background: var(--j-panel); }
.player p { margin: 0; }
.player__role { display: flex; align-items: center; gap: 8px; color: var(--j-muted); font-size: .8125rem; }
.player__role img { width: 20px; height: 20px; }
.player__nick { color: var(--j-ink); font-family: 'Exo 2', sans-serif; font-size: 1.375rem; font-weight: 600; overflow-wrap: anywhere; }
.player__cap { margin-left: 4px; padding: 1px 6px; border: 1px solid rgba(0, 255, 157, .45); border-radius: 4px; color: var(--j-accent); font-family: inherit; font-size: .6875rem; font-weight: 600; vertical-align: middle; }
.player__meta { color: var(--j-muted); font-size: .8125rem; line-height: 1.4; }
.player__heroes { display: flex; gap: 6px; margin-top: 8px !important; }
.player__heroes img { width: 32px; height: 32px; border-radius: 8px; display: block; }

/* Tables */
.etable-wrap { overflow-x: auto; border: 1px solid var(--j-line); border-radius: 14px; background: var(--j-panel); }
.etable { width: 100%; border-collapse: collapse; font-size: .9375rem; }
.etable th, .etable td { padding: 12px 16px; border-bottom: 1px solid var(--j-line); text-align: left; vertical-align: middle; }
.etable tbody tr:last-child th, .etable tbody tr:last-child td { border-bottom: 0; }
.etable thead th { color: var(--j-muted); font-size: .8125rem; font-weight: 500; white-space: nowrap; }
.etable tbody th { color: var(--j-ink); font-weight: 600; white-space: nowrap; }
.etable tbody th img { width: 20px; height: 20px; margin-right: 8px; vertical-align: -4px; }
.etable td a { color: var(--j-ink); text-decoration: none; }
.etable td a:hover { color: var(--j-accent); }
.etable .score { font-family: 'Exo 2', sans-serif; font-weight: 600; white-space: nowrap; }
.etable tr[data-result="win"] .score { color: var(--j-accent); }
.etable tr[data-result="loss"] .score { color: var(--j-red); }
.etable time { white-space: nowrap; }
.vs { display: inline-flex; align-items: center; gap: 8px; }
.lane-heroes { display: flex; flex-wrap: wrap; gap: 8px; }
.lane-heroes a { display: inline-flex; align-items: center; gap: 6px; padding: 3px 8px 3px 3px; border: 1px solid var(--j-line); border-radius: 8px; }
.lane-heroes img { width: 28px; height: 28px; border-radius: 6px; }
.lane-heroes small { color: var(--j-muted); }

/* Links and other teams */
.esports-links { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; }
.esports-links a { padding: 8px 14px; border: 1px solid var(--j-line); border-radius: 10px; color: var(--j-ink); font-size: .9375rem; text-decoration: none; }
.esports-links a:hover { border-color: var(--j-accent); }
.team-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.team-chip { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px 6px 8px; border: 1px solid var(--j-line); border-radius: 10px; color: var(--j-text); font-size: .875rem; text-decoration: none; }
.team-chip:hover { border-color: var(--j-line-strong); background: var(--j-raised); color: var(--j-ink); }

/* The price offer at the end: one quiet block. */
.esports-cta { margin-top: 48px; }
.esports-cta .calc-btn { display: inline-flex; align-items: center; gap: 8px; }
.esports-cta .calc-btn img { width: 28px; height: 28px; }
.esports-page .seo-faq { margin-top: 48px; }

@media (max-width: 1000px) { .ehero-row { grid-template-columns: repeat(3, minmax(0, 1fr)); } .players { grid-template-columns: repeat(2, minmax(0, 1fr)); } .player:last-child:nth-child(odd) { grid-column: 1 / -1; } }
@media (max-width: 900px) { .cis-cards { grid-template-columns: 1fr; } }
@media (max-width: 640px) {
  .team-head { grid-template-columns: 1fr; gap: 12px; }
  .team-head__logo { width: 80px; height: 80px; border-radius: 16px; }
  .team-head__logo .tl { --s: 56px; }
  .team-facts { gap: 8px 20px; }
  .players { gap: 8px; }
  .player { padding: 12px; }
  .player__nick { font-size: 1.125rem; }
  .ehero-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .etable th, .etable td { padding: 10px 12px; }
}

/* Phones: lane table rows become blocks, heroes get the full width instead of a clipped third column (01.12.2026). */
@media (max-width: 640px) {
  .etable--lanes thead { display: none; }
  .etable--lanes, .etable--lanes tbody, .etable--lanes tr { display: block; width: 100%; }
  .etable--lanes tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 12px; padding: 12px 14px; border-top: 1px solid var(--j-line); }
  .etable--lanes tbody tr:first-child { border-top: 0; }
  .etable--lanes th, .etable--lanes td { display: block; padding: 0; border: 0; }
  .etable--lanes td:nth-child(2) { align-self: center; color: var(--j-muted); }
  .etable--lanes td:nth-child(3) { grid-column: 1 / -1; }
}
