:root {
  --bg: #020707;
  --surface: rgba(10, 23, 20, 0.86);
  --surface-soft: rgba(16, 35, 29, 0.72);
  --surface-strong: #07130f;
  --ink: #f5fff8;
  --muted: #b8c9c1;
  --muted-2: #82978e;
  --line: rgba(42, 255, 122, 0.22);
  --line-soft: rgba(255, 255, 255, 0.08);
  --green: #17e86f;
  --green-dark: #10c862;
  --yellow: #f5c542;
  --red: #ff6b63;
  --blue: #4aa3ff;
  --purple: #aa82ff;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.46);
  --radius: 8px;
  --max: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  overflow-x: hidden;
  font-family: Inter, Arial, Helvetica, sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 50% 10%, rgba(21, 226, 111, 0.12), transparent 28rem),
    linear-gradient(180deg, #020807 0%, #03110d 42%, #010504 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    linear-gradient(rgba(2, 7, 7, 0.34), rgba(2, 7, 7, 0.78)),
    linear-gradient(115deg, transparent 0 31%, rgba(36, 255, 130, 0.08) 32%, transparent 39%),
    repeating-linear-gradient(90deg, rgba(255,255,255,0.012) 0 1px, transparent 1px 80px);
  pointer-events: none;
}

body::after {
  content: "";
  position: fixed;
  inset: auto 0 0;
  height: 34vh;
  z-index: -1;
  background:
    linear-gradient(180deg, transparent, rgba(1, 6, 5, 0.94)),
    radial-gradient(ellipse at center bottom, rgba(18, 214, 97, 0.16), transparent 58%);
  pointer-events: none;
}

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

img {
  max-width: 100%;
}

.container {
  width: min(var(--max), calc(100% - 40px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  background: rgba(1, 7, 7, 0.9);
  backdrop-filter: blur(16px);
}

.header-content {
  min-height: 82px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

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

.logo img {
  width: 146px;
  display: block;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 28px;
  font-size: 0.88rem;
  font-weight: 800;
  color: rgba(245, 255, 248, 0.86);
}

.main-nav a:hover {
  color: var(--green);
}

.header-actions,
.hero-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 0 22px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-size: 0.92rem;
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  color: #021008;
  background: linear-gradient(135deg, #1fff82, #13d966);
  box-shadow: 0 12px 30px rgba(21, 201, 107, 0.22);
}

.btn-outline,
.btn-ghost {
  color: var(--ink);
  border-color: rgba(29, 231, 111, 0.32);
  background: rgba(255, 255, 255, 0.035);
}

.btn-small {
  min-height: 44px;
  padding-inline: 18px;
}

.hero {
  padding: 36px 0 26px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  background:
    linear-gradient(90deg, rgba(1, 8, 7, 0.98) 0%, rgba(2, 13, 9, 0.76) 35%, rgba(2, 10, 7, 0.28) 70%, rgba(1, 7, 6, 0.92) 100%),
    radial-gradient(circle at 63% 52%, rgba(39, 255, 132, 0.18), transparent 24rem),
    linear-gradient(180deg, rgba(8, 64, 37, 0.18), rgba(1, 6, 5, 0.82)),
    repeating-linear-gradient(8deg, rgba(255,255,255,0.028) 0 1px, transparent 1px 23px);
  color: #f7fff9;
}

.hero-grid {
  min-height: 370px;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
  align-items: center;
  gap: 34px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 16px;
  color: #f6d56a;
  font-size: 0.84rem;
  font-weight: 900;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 720px;
  margin: 0;
  font-size: clamp(2.35rem, 5vw, 4.8rem);
  line-height: 0.98;
  letter-spacing: 0;
}

.hero p {
  max-width: 640px;
  margin: 20px 0 28px;
  color: rgba(247, 255, 249, 0.84);
  font-size: 1.08rem;
  line-height: 1.7;
}

.hero-panel {
  padding: 22px;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: var(--radius);
  background: rgba(8, 27, 21, 0.72);
  box-shadow: var(--shadow);
}

.hero-round-card {
  display: grid;
  gap: 16px;
}

.hero-round-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.hero-round-header span {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 1.04rem;
  font-weight: 900;
}

.hero-round-header strong {
  padding: 8px 11px;
  border: 1px solid rgba(23, 232, 111, 0.2);
  border-radius: 999px;
  background: rgba(23, 232, 111, 0.1);
  color: var(--green);
  font-size: 0.82rem;
}

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

.hero-match-card {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  min-height: 72px;
  padding: 12px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: rgba(255,255,255,0.045);
}

.hero-match-date {
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 900;
}

.hero-team {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero-team img {
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  object-fit: contain;
}

.hero-team strong {
  overflow: hidden;
  font-size: 0.86rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hero-score {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-width: 62px;
  color: var(--green);
  font-size: 1.3rem;
  font-weight: 900;
}

.hero-score small {
  color: var(--ink);
  font-size: 0.78rem;
}

.hero-round-link {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border-radius: var(--radius);
  background: rgba(255,255,255,0.06);
  color: var(--ink);
  font-size: 0.85rem;
  font-weight: 900;
}

.hero-empty {
  padding: 16px;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  color: var(--muted);
  line-height: 1.6;
}

.live-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 390px;
  gap: 22px;
  align-items: start;
  padding: 28px 0 44px;
}

.live-layout > *,
.seo-section > * {
  min-width: 0;
}

.panel,
.seo-section {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 22px;
  border-bottom: 1px solid var(--line-soft);
}

.section-header span {
  display: block;
  margin-bottom: 5px;
  color: var(--green);
  font-size: 0.75rem;
  font-weight: 900;
  text-transform: uppercase;
}

.section-header h2 {
  margin: 0;
  font-size: 1.18rem;
  line-height: 1.25;
}

.section-header > strong {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(23, 232, 111, 0.1);
  color: var(--green);
  font-size: 0.86rem;
}

.standings-stack {
  padding: 18px;
}

.standings-block-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.standings-block-title strong {
  font-size: 0.95rem;
}

.standings-block-title span {
  color: var(--muted);
  font-size: 0.84rem;
}

.standings-table-wrap {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.standings-table {
  width: 100%;
  min-width: 720px;
  border-collapse: collapse;
  table-layout: fixed;
}

.standings-table th,
.standings-table td {
  height: 48px;
  padding: 8px;
  border-bottom: 1px solid var(--line-soft);
  text-align: center;
  font-size: 0.86rem;
}

.standings-table th {
  background: rgba(255,255,255,0.045);
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.standings-table tr:last-child td {
  border-bottom: 0;
}

.standings-table .is-club {
  position: sticky;
  left: 0;
  z-index: 1;
  width: 208px;
  min-width: 208px;
  max-width: 208px;
  text-align: left;
  background: #0b1a15;
  white-space: nowrap;
}

.standings-table th.is-club {
  background: #10221b;
}

.standings-table .is-club strong {
  display: inline-block;
  max-width: 126px;
  overflow: hidden;
  text-overflow: ellipsis;
  vertical-align: middle;
  white-space: nowrap;
}

.standing-position {
  display: inline-block;
  width: 26px;
  color: var(--muted);
  font-weight: 900;
  vertical-align: middle;
}

.standings-table img {
  width: 28px;
  height: 28px;
  margin-right: 8px;
  object-fit: contain;
  vertical-align: middle;
}

.points {
  color: var(--green);
  font-weight: 900;
}

.standing-zone-libertadores {
  box-shadow: inset 4px 0 0 var(--blue);
}

.standing-zone-pre-libertadores {
  box-shadow: inset 4px 0 0 var(--purple);
}

.standing-zone-sul-americana {
  box-shadow: inset 4px 0 0 var(--green);
}

.standing-zone-rebaixados {
  box-shadow: inset 4px 0 0 var(--red);
}

.form-dots {
  display: inline-flex;
  gap: 4px;
}

.form-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #c8d2cc;
}

.form-w {
  background: var(--green);
}

.form-d {
  background: var(--yellow);
}

.form-l {
  background: var(--red);
}

.standings-zone-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding: 0 18px 18px;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 800;
}

.standings-zone-legend span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.standings-zone-legend i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.zone-libertadores { background: var(--blue); }
.zone-pre-libertadores { background: var(--purple); }
.zone-sul-americana { background: var(--green); }
.zone-rebaixados { background: var(--red); }

.round-panel {
  min-width: 0;
  overflow: hidden;
  position: sticky;
  top: 102px;
}

.round-switcher {
  display: grid;
  grid-template-columns: 44px 1fr 44px;
  align-items: center;
  gap: 10px;
  padding: 18px;
}

.round-switcher button {
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255,255,255,0.04);
  color: var(--ink);
  cursor: pointer;
}

.round-switcher button:disabled {
  opacity: 0.42;
  cursor: not-allowed;
}

.round-switcher strong {
  text-align: center;
  font-size: 1rem;
}

.round-browser-status {
  margin: 0 18px 14px;
  padding: 11px 12px;
  border-radius: var(--radius);
  background: rgba(245, 197, 66, 0.14);
  color: #ffe38a;
  font-size: 0.84rem;
  font-weight: 800;
}

.current-round-list {
  min-width: 0;
  display: grid;
  gap: 14px;
  padding: 0 18px 18px;
}

.current-round-group > strong {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 0.78rem;
  text-transform: uppercase;
}

.mini-match-row {
  min-width: 0;
  display: grid;
  grid-template-columns: 74px 1fr;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-soft);
}

.mini-match-date {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 900;
}

.mini-match-scoreline {
  min-width: 0;
  display: grid;
  grid-template-columns: 28px 24px 14px 24px 28px;
  align-items: center;
  justify-content: center;
  gap: 7px;
}

.mini-match-scoreline img {
  width: 28px;
  height: 28px;
  object-fit: contain;
}

.mini-match-scoreline b,
.mini-match-scoreline small {
  text-align: center;
}

.mini-match-place {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 0.74rem;
  font-style: normal;
  text-align: center;
}

.empty-state,
.tournament-empty {
  display: grid;
  gap: 6px;
  margin: 18px;
  padding: 18px;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  color: var(--muted);
}

.empty-state strong,
.tournament-empty strong {
  color: var(--ink);
}

.seo-section {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(320px, 1.08fr);
  gap: 26px;
  margin-bottom: 42px;
  padding: 28px;
}

.seo-copy h2 {
  margin: 0 0 14px;
  font-size: 1.85rem;
  line-height: 1.15;
}

.seo-copy p {
  margin: 0 0 22px;
  color: var(--muted);
  line-height: 1.7;
}

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

.faq-list details {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-soft);
}

.faq-list summary {
  padding: 16px;
  cursor: pointer;
  font-weight: 900;
}

.faq-list p {
  margin: 0;
  padding: 0 16px 16px;
  color: var(--muted);
  line-height: 1.6;
}

.site-footer {
  padding: 44px 0 28px;
  border-top: 1px solid var(--line-soft);
  background: rgba(1, 7, 7, 0.72);
  color: #eef8f1;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.1fr repeat(3, 1fr);
  gap: 46px;
  padding-bottom: 30px;
  border-bottom: 1px solid var(--line-soft);
}

.footer-logo {
  width: 150px;
}

.footer-col h3 {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 0.82rem;
  text-transform: uppercase;
}

.footer-col a,
.footer-col span {
  display: block;
  margin-bottom: 9px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.footer-col a:hover {
  color: var(--green);
}

.social-links {
  display: flex;
  gap: 18px;
  color: var(--green);
  font-size: 1.15rem;
}

.copyright {
  padding-top: 18px;
  color: var(--muted-2);
  text-align: center;
  font-size: 0.86rem;
}

@media (max-width: 980px) {
  .main-nav {
    display: none;
  }

  .hero-grid,
  .live-layout,
  .seo-section,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .round-panel {
    position: static;
  }

  .standings-panel {
    overflow: hidden;
  }
}

@media (max-width: 640px) {
  .container {
    width: min(100% - 24px, var(--max));
  }

  .site-header {
    position: relative;
  }

  .header-content {
    min-height: 72px;
    align-items: stretch;
    flex-direction: column;
    gap: 10px;
    padding: 14px 0;
  }

  .logo {
    justify-content: center;
    width: 100%;
  }

  .logo img {
    width: 132px;
  }

  .header-actions {
    width: 100%;
    justify-content: center;
    gap: 8px;
  }

  .header-actions .btn {
    flex: 1;
  }

  .btn {
    min-height: 42px;
    padding-inline: 13px;
    font-size: 0.82rem;
  }

  .hero {
    padding: 26px 0 20px;
  }

  .hero-grid {
    min-height: 0;
    gap: 22px;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero h1 {
    font-size: 2.35rem;
    line-height: 1.02;
  }

  .hero p {
    font-size: 0.98rem;
  }

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

  .hero-match-card {
    grid-template-columns: 1fr auto 1fr;
    gap: 8px;
  }

  .hero-match-date {
    grid-column: 1 / -1;
    text-align: center;
  }

  .hero-team {
    flex-direction: column;
    text-align: center;
  }

  .hero-team strong {
    max-width: 100%;
    font-size: 0.78rem;
  }

  .live-layout {
    padding-top: 18px;
  }

  .section-header,
  .standings-stack,
  .round-switcher,
  .current-round-list,
  .seo-section {
    padding: 14px;
  }

  .section-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .section-header > strong {
    max-width: 100%;
  }

  .standings-table {
    min-width: 640px;
  }

  .standings-table .is-club {
    width: 170px;
    min-width: 170px;
    max-width: 170px;
  }

  .standings-table th,
  .standings-table td {
    padding-inline: 8px;
    font-size: 0.8rem;
  }

  .standings-table img {
    width: 24px;
    height: 24px;
  }

  .standing-position {
    width: 22px;
  }

  .standings-table .is-club strong {
    max-width: 98px;
  }

  .standings-zone-legend {
    padding: 0 14px 14px;
  }

  .mini-match-row {
    grid-template-columns: 1fr;
  }

  .mini-match-date {
    text-align: center;
  }

  .mini-match-main,
  .mini-match-scoreline {
    width: 100%;
  }

  .mini-match-scoreline {
    grid-template-columns: 32px 26px 14px 26px 32px;
  }

  .footer-grid {
    gap: 24px;
    text-align: center;
    justify-items: center;
  }

  .footer-col a,
  .footer-col span {
    text-align: center;
  }

  .social-links {
    justify-content: center;
  }
}

/* Responsive containment pass - 2026-05-22 */
html,
body {
  max-width: 100%;
}

body {
  overflow-x: clip;
}

@supports not (overflow-x: clip) {
  body {
    overflow-x: hidden;
  }
}

.container,
.site-header,
.header-content,
.hero,
.hero-grid,
.section,
.section-header,
.standings-shell,
.current-round-list,
.round-switcher,
.footer-grid {
  min-width: 0;
  max-width: 100%;
}

.round-box,
.mini-match-row,
.mini-match-main,
.mini-match-scoreline,
.seo-section,
.standing-position {
  min-width: 0;
}

.table-scroll,
.standings-table-wrap,
.groups-table-wrap {
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

:is(.hero, .section-header, .round-box, .seo-section, .mini-match-main) :is(h1, h2, h3, p, strong) {
  overflow-wrap: anywhere;
}

@media (max-width: 640px) {
  .container {
    width: min(100% - 28px, var(--max));
  }
}
