/* CSS principal do site — Partida Certa.
 * Antes ficava embutido em TODA página (base.html). Agora é um arquivo à parte, que o
 * navegador guarda em cache. O que varia por conta/requisição (escudo no cabeçalho, espaço
 * da barra inferior e as cores do tema) continua em <style> pequenos no base.html.
 * Editar aqui; o ?v= da URL muda sozinho (mtime) e força o celular a baixar de novo.
 * Não usar {{ }} nem {% %} neste arquivo (não passa pelo Jinja). */
    :root {
      --sao-grena: #6b1522;
      --sao-grena-rgb: 107, 21, 34;
      --sao-grena-escuro: #4a0f18;
      --sao-verde: #0f4a2c;
      --sao-verde-rgb: 15, 74, 44;
      --sao-verde-escuro: #0a3620;
      --sao-dourado: #c9a227;
      --bg-pagina: #e3e7ea;
      --texto-suave: #6c757d;
    }

    * { font-family: 'Inter', system-ui, -apple-system, sans-serif; }

    html, body { min-height: 100%; overflow-x: hidden; overflow-x: clip; }
    body {
      background: var(--bg-pagina);
      color: #222;
      width: 100%;
    }

    /* ---------- Navbar ---------- */
    .navbar-custom {
      background: linear-gradient(100deg, var(--sao-grena) 0%, var(--sao-verde-escuro) 100%);
      box-shadow: 0 2px 12px rgba(0,0,0,.25);
      padding-top: .6rem;
      padding-bottom: .6rem;
    }
    .navbar-brand {
      display: flex;
      align-items: center;
      gap: .5rem;
    }
    .navbar-brand-link {
      font-weight: 800;
      display: flex;
      align-items: center;
      gap: .85rem;
      letter-spacing: .2px;
      font-size: 1.35rem;
      color: #fff;
      text-decoration: none;
      background: rgba(255,255,255,.08);
      border: 1px solid rgba(255,255,255,.15);
      border-radius: 14px;
      padding: .4rem 1rem .4rem .5rem;
    }
    .navbar-brand-link:hover { color: #fff; background: rgba(255,255,255,.14); }
    .navbar-brand-link img {
      height: 56px; width: 56px; object-fit: contain; flex-shrink: 0;
      border-radius: 10px; padding: 4px;
      background: linear-gradient(
        to bottom,
        var(--sao-grena) 0%, var(--sao-grena) 33%,
        #f6f6f4 33%, #f6f6f4 66%,
        var(--sao-verde) 66%, var(--sao-verde) 100%
      );
      border: 1px solid rgba(255,255,255,.25);
    }
    .navbar-brand-link img.navbar-brand-generico {
      background: none; border: none; padding: 0;
    }
    .selo-partida-certa-link {
      display: inline-flex; align-items: center; justify-content: center;
      width: 40px; height: 40px; border-radius: 10px; flex-shrink: 0;
      background: rgba(255,255,255,.08);
      border: 1px solid rgba(255,255,255,.15);
      transition: background .15s ease, transform .15s ease;
    }
    .selo-partida-certa-link:hover { background: rgba(255,255,255,.18); transform: translateY(-1px); }
    .selo-partida-certa-link .selo-partida-certa {
      height: 26px; width: 26px; flex-shrink: 0;
      border-radius: 6px; padding: 0; background: none; border: none;
    }
    .logo-prefeitura-navbar {
      height: 48px; width: auto; max-width: 140px; object-fit: contain;
      background: transparent; flex-shrink: 0;
    }
    @media (max-width: 576px) {
      .navbar-brand-link {
        font-size: 1rem;
        gap: .55rem;
        padding: .3rem .7rem .3rem .3rem;
        white-space: normal;
      }
      .navbar-brand-link img { height: 38px; width: 38px; }
      .selo-partida-certa-link { width: 32px; height: 32px; }
      .selo-partida-certa-link .selo-partida-certa { height: 20px; width: 20px; }
      .logo-prefeitura-navbar { height: 36px; max-width: 100px; }
    }
    .nav-link-custom {
      color: rgba(255,255,255,.85) !important;
      font-weight: 500;
      padding: .5rem .9rem !important;
      border-radius: 8px;
      transition: background .15s ease, color .15s ease;
      background: transparent;
    }
    button.nav-link-custom {
      font-family: inherit;
      font-size: 1rem;
      line-height: 1.5;
    }
    .nav-link-custom:hover { background: rgba(255,255,255,.12); color: #fff !important; }
    .nav-link-custom.active { background: rgba(255,255,255,.18); color: #fff !important; }

    /* ---------- Hero / page header ---------- */
    .page-hero {
      position: relative;
      width: 100%;
      background: linear-gradient(120deg, var(--sao-grena) 0%, var(--sao-grena-escuro) 60%, var(--sao-verde-escuro) 100%);
      color: #fff;
      padding: 2rem 0 3.25rem;
      margin-bottom: -2rem;
      overflow: hidden;
    }
    .page-hero .container { position: relative; z-index: 1; }
    .page-hero h1 { font-weight: 800; font-size: 1.6rem; margin: 0; }
    .page-hero .subtitle { color: rgba(255,255,255,.8); font-size: .95rem; }

    .content-shell {
      background: transparent;
      padding-bottom: 3rem;
      /* impede que a margin-top de um filho direto (ex: a fileira de abas)
         "atravesse" este contêiner e se misture com a margin-bottom negativa
         do .page-hero lá fora — sem isso, cada navegador calcula a
         sobreposição de um jeito (Safari e Chrome divergiam aqui). */
      display: flow-root;
    }

    /* ---------- Cards ---------- */
    .card {
      border: 1px solid rgba(20, 20, 40, .12);
      border-radius: 18px;
      box-shadow: 0 6px 22px rgba(20, 20, 40, .1);
    }
    [data-bs-theme="dark"] .card {
      border-color: rgba(255, 255, 255, .1);
    }
    .card-jogo { border-top: 4px solid var(--sao-verde); }
    .card-pendente { border-top: 4px solid var(--sao-dourado); }
    .card-cancelado { border-top: 4px solid var(--sao-grena); opacity: 0.85; }
    .card-livre { border-top: 4px solid #d7dbe0; opacity: 0.95; }
    .card-resultado-vitoria { border-top-color: #1f9d55; }
    .card-resultado-empate { border-top-color: #8a8f96; }
    .card-resultado-derrota { border-top-color: #c0392b; }
    .jogo-card .card-body { padding: 1.15rem; }

    .badge-ao-vivo {
      background: #e0483a !important;
      display: inline-flex;
      align-items: center;
      gap: .4rem;
      letter-spacing: .03em;
    }
    .dot-pulso {
      width: 7px; height: 7px; border-radius: 50%;
      background: #fff;
      animation: agendaPulso 1.4s ease-in-out infinite;
    }
    @keyframes agendaPulso {
      0%, 100% { opacity: 1; transform: scale(1); }
      50% { opacity: .4; transform: scale(.65); }
    }

    .resultado-chip { font-size: .78rem; padding: .35rem .85rem; }

    .jogo-meta {
      display: flex;
      flex-wrap: wrap;
      gap: .45rem 1rem;
      margin: .85rem 0 .5rem;
      font-size: .82rem;
      color: var(--texto-suave);
    }
    .jogo-meta-item { display: inline-flex; align-items: center; gap: .38rem; }
    .jogo-meta-item i { color: var(--sao-verde); font-size: .8rem; }
    .jogo-meta-item a { color: inherit; text-decoration: underline; text-decoration-color: rgba(0, 0, 0, .25); }
    [data-bs-theme="dark"] .jogo-meta-item i { color: #6bcf8f; }
    [data-bs-theme="dark"] .jogo-meta-item a { text-decoration-color: rgba(255, 255, 255, .3); }

    .jogo-acoes .btn { border-radius: 999px; padding: .42rem 1rem; }

    /* ---------- Badges & buttons ---------- */
    .badge-confirmado { background: var(--sao-verde) !important; }
    .badge-pendente { background: var(--sao-dourado) !important; color: #3a2e00 !important; }
    .badge-cancelado { background: #9aa0a6 !important; }
    .badge-vitoria { background: #1f9d55 !important; }
    .badge-empate { background: #8a8f96 !important; }
    .badge-derrota { background: #c0392b !important; }
    .badge-temporada {
      display: inline-flex;
      align-items: center;
      gap: .5rem;
      padding: .55rem 1.1rem;
      border-radius: 999px;
      font-weight: 800;
      font-size: 1rem;
      letter-spacing: .02em;
      color: #3a2e00;
      background: linear-gradient(135deg, #ffe9a8, #c9a227);
      box-shadow: 0 4px 16px rgba(201, 162, 39, .45), inset 0 1px 0 rgba(255, 255, 255, .6);
      border: 1px solid rgba(255, 255, 255, .4);
    }
    [data-bs-theme="dark"] .badge-temporada {
      color: #2a2000;
      box-shadow: 0 4px 18px rgba(201, 162, 39, .55), inset 0 1px 0 rgba(255, 255, 255, .5);
    }
    .table-warning,
    .table-warning td,
    .table-warning a,
    .table-warning a:hover {
      color: #2a2000 !important;
    }
    .table-warning a {
      text-decoration: none;
    }
    .table-warning a:hover .fw-semibold {
      text-decoration: underline;
    }
    .card-artilharia-destaque {
      background: linear-gradient(120deg, var(--sao-grena) 0%, var(--sao-grena-escuro) 100%);
      color: #fff;
      border: 1px solid rgba(255, 255, 255, .15);
      box-shadow: 0 6px 18px rgba(var(--sao-grena-rgb), .35);
      transition: transform .15s ease, box-shadow .15s ease;
      position: relative;
    }
    .card-artilharia-destaque:hover {
      transform: translateY(-2px);
      box-shadow: 0 10px 26px rgba(var(--sao-grena-rgb), .45);
    }
    .ranking-destaque-card {
      height: clamp(300px, 44vw, 400px);
      max-width: clamp(150px, 26vw, 320px);
      margin: 0 auto;
      overflow: visible;
    }
    .ranking-destaque-card .card-body {
      display: flex;
      flex-direction: column;
      align-items: center;
      height: 100%;
      overflow: visible;
    }
    .ranking-destaque-corpo {
      flex: 1 1 auto;
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: flex-start;
      padding-top: .5rem;
      width: 100%;
      min-width: 0;
      overflow: visible;
    }
    .ranking-destaque-escudo {
      width: clamp(170px, 28vw, 330px);
      height: auto;
      display: block;
      margin: 0 auto;
      filter: drop-shadow(0 8px 14px rgba(0, 0, 0, .45));
    }
    .ranking-destaque-foto-wrap {
      display: block;
      width: clamp(170px, 28vw, 330px);
      height: clamp(170px, 28vw, 330px);
      margin: 0 auto;
      border-radius: 50%;
      overflow: hidden;
      filter: drop-shadow(0 8px 14px rgba(0, 0, 0, .45));
    }
    .ranking-destaque-foto-wrap img {
      width: 100%;
      height: 100%;
      object-fit: cover;
      object-position: center top;
      display: block;
    }
    .ranking-destaques-row {
      /* "visible" puro nos dois eixos — misturar hidden/visible faz o
         navegador forçar "auto" (mesma pegadinha das abas), o que criaria
         uma barra de rolagem vertical em vez de deixar o escudo vazar livre.
         Quem impede a barra horizontal da página é o overflow-x do body. */
      overflow: visible;
      margin-top: 2.5rem;
    }
    .ranking-destaque-numero {
      font-size: clamp(1.1rem, 2.4vw, 2.1rem);
      font-weight: 800;
      color: #ffd76a;
      line-height: 1.1;
    }
    .card-artilharia-destaque i.bi-trophy-fill { color: #ffd76a; }
    .btn-outline-warning-brand {
      border-color: var(--sao-dourado);
      color: #7a6210;
    }
    .btn-outline-warning-brand:hover { background: var(--sao-dourado); color: #3a2e00; }
    .btn-brand {
      background: var(--sao-verde);
      border-color: var(--sao-verde);
      color: #fff;
    }
    .btn-brand:hover { background: var(--sao-verde-escuro); border-color: var(--sao-verde-escuro); color: #fff; }
    .btn-outline-brand {
      background: var(--sao-grena);
      border-color: var(--sao-grena);
      color: #fff;
      box-shadow: 0 2px 8px rgba(var(--sao-grena-rgb), .3);
    }
    .btn-outline-brand:hover { background: var(--sao-grena-escuro); border-color: var(--sao-grena-escuro); color: #fff; }
    .btn-outline-danger {
      background: #e0483a;
      border-color: #e0483a;
      color: #fff;
      box-shadow: 0 2px 8px rgba(224, 72, 58, .35);
    }
    .btn-outline-danger:hover { background: #c0392b; border-color: #c0392b; color: #fff; }

    .pill-nav .btn { border-radius: 999px; }

    .mes-nav {
      display: flex;
      flex-wrap: nowrap;
      overflow-x: auto;
      gap: .4rem;
      -ms-overflow-style: none;
      scrollbar-width: none;
    }
    .mes-nav::-webkit-scrollbar { display: none; }
    .mes-nav-item {
      flex-shrink: 0;
      padding: .4rem .85rem;
      border-radius: 999px;
      font-weight: 700;
      font-size: .85rem;
      color: rgba(255, 255, 255, .85);
      background: rgba(255, 255, 255, .12);
      border: 1px solid rgba(255, 255, 255, .18);
      text-decoration: none;
      transition: background .15s ease, color .15s ease, transform .15s ease;
    }
    .mes-nav-item:hover {
      background: rgba(255, 255, 255, .22);
      color: #fff;
    }
    .mes-nav-item.active {
      background: var(--sao-dourado);
      border-color: var(--sao-dourado);
      color: #3a2e00;
      font-size: .95rem;
      padding: .5rem 1.05rem;
      box-shadow: 0 4px 14px rgba(201, 162, 39, .55);
      transform: scale(1.08);
    }
    .mes-nav-item.active:hover { color: #3a2e00; }

    .escudo-circulo {
      width: 46px; height: 46px; border-radius: 12px;
      object-fit: contain; background: #fff; border: 1px solid #e3e6ea;
      padding: 3px; box-shadow: 0 2px 6px rgba(20,20,40,.12);
    }
    .escudo-placeholder-circulo {
      width: 46px; height: 46px; border-radius: 12px;
      display: flex; align-items: center; justify-content: center;
      background: #eef1f3; color: #b3b9bf; font-size: 1.2rem; border: 1px solid #e3e6ea;
      box-shadow: 0 2px 6px rgba(20,20,40,.12);
    }

    /* ---------- Artilharia ---------- */
    .artilheiro-linha {
      display: flex;
      align-items: center;
      gap: 1rem;
      padding: .9rem .75rem;
      border-radius: 14px;
      transition: background .15s ease, transform .15s ease;
      flex-wrap: wrap;
      position: relative;
    }
    .artilheiro-linha:hover { background: rgba(var(--sao-verde-rgb), .05); }
    .artilheiro-clicavel { cursor: pointer; -webkit-tap-highlight-color: transparent; }
    .artilheiro-clicavel:active { transform: scale(.99); }
    .artilheiro-linha:not(:last-child) { border-bottom: 1px solid #eef1f3; }
    .artilheiro-podio {
      background: rgba(201, 162, 39, .07);
      border-left: 4px solid transparent;
    }
    .artilheiro-podio-1 { border-left-color: #c9a227; background: rgba(255, 215, 106, .1); }
    .artilheiro-podio-2 { border-left-color: #a8a8a8; background: rgba(200, 200, 200, .08); }
    .artilheiro-podio-3 { border-left-color: #9c6530; background: rgba(215, 160, 103, .08); }
    .artilheiro-posicao {
      width: 36px; height: 36px; border-radius: 50%;
      display: flex; align-items: center; justify-content: center;
      font-weight: 800; font-size: .95rem; flex-shrink: 0;
      background: #eef1f3; color: var(--texto-suave);
    }
    .artilheiro-medalha {
      width: 44px; height: 44px; border-radius: 50%;
      display: flex; align-items: center; justify-content: center;
      font-size: 1.5rem; flex-shrink: 0;
      position: relative;
      filter: drop-shadow(0 3px 6px rgba(20, 20, 40, .3));
    }
    .artilheiro-medalha::before {
      content: "";
      position: absolute;
      inset: 0;
      border-radius: 50%;
      z-index: -1;
    }
    .artilheiro-medalha.ouro::before {
      background: radial-gradient(circle at 35% 30%, #fff2c2, #ffd76a 45%, #c9a227 100%);
      box-shadow: 0 3px 12px rgba(201, 162, 39, .55), inset 0 1px 2px rgba(255, 255, 255, .6);
    }
    .artilheiro-medalha.prata::before {
      background: radial-gradient(circle at 35% 30%, #ffffff, #e2e2e2 45%, #9c9c9c 100%);
      box-shadow: 0 3px 12px rgba(120, 120, 120, .45), inset 0 1px 2px rgba(255, 255, 255, .7);
    }
    .artilheiro-medalha.bronze::before {
      background: radial-gradient(circle at 35% 30%, #f0c49a, #d7a067 45%, #8a5a2c 100%);
      box-shadow: 0 3px 12px rgba(140, 90, 40, .5), inset 0 1px 2px rgba(255, 255, 255, .5);
    }
    .artilheiro-linha.artilheiro-podio-1 .artilheiro-foto { width: 60px; height: 60px; }
    .artilheiro-linha.artilheiro-podio-1 .artilheiro-info .fw-semibold { font-size: 1.08rem; }
    .artilheiro-foto { width: 52px; height: 52px; flex-shrink: 0; }
    .artilheiro-info { flex: 1 1 160px; min-width: 0; }
    .artilheiro-stats { display: flex; gap: 1.5rem; flex-shrink: 0; margin-left: auto; }
    .artilheiro-stat { text-align: center; min-width: 42px; }
    .artilheiro-stat-valor { font-weight: 800; font-size: 1.15rem; color: var(--sao-verde); }
    .artilheiro-stat-label { font-size: .68rem; text-transform: uppercase; letter-spacing: .04em; color: var(--texto-suave); }
    @media (max-width: 420px) {
      .artilheiro-linha { gap: .6rem; padding: .8rem .5rem; }
      .artilheiro-foto { width: 44px; height: 44px; }
      .artilheiro-info { flex-basis: 90px; }
      .artilheiro-stats { gap: .7rem; }
      .artilheiro-stat { min-width: 30px; }
      .artilheiro-stat-valor { font-size: .95rem; }
      .artilheiro-stat-label { font-size: .58rem; }
    }
    [data-bs-theme="dark"] .artilheiro-linha:not(:last-child) { border-bottom-color: #2c353b; }
    [data-bs-theme="dark"] .artilheiro-linha:hover { background: rgba(255, 255, 255, .04); }
    [data-bs-theme="dark"] .artilheiro-podio-1 { background: rgba(255, 215, 106, .07); }
    [data-bs-theme="dark"] .artilheiro-podio-2 { background: rgba(200, 200, 200, .06); }
    [data-bs-theme="dark"] .artilheiro-podio-3 { background: rgba(215, 160, 103, .06); }
    [data-bs-theme="dark"] .artilheiro-posicao:not(.ouro):not(.prata):not(.bronze) { background: #1e2529; color: #9aa4ab; }
    [data-bs-theme="dark"] .artilheiro-stat-valor { color: #6bcf8f; }

    /* ---------- Histórico de gols do jogador (modal) ---------- */
    .jogador-historico-foto { width: 64px; height: 64px; flex-shrink: 0; }
    .jogador-historico-lista { display: flex; flex-direction: column; }
    .jogador-historico-linha {
      display: flex;
      align-items: center;
      gap: .85rem;
      padding: .85rem 1.25rem;
      border-top: 1px solid #eef1f3;
      animation: agendaEntrada .3s ease both;
    }
    [data-bs-theme="dark"] .jogador-historico-linha { border-top-color: #2c353b; }
    .jogador-historico-escudo-wrap .escudo-circulo,
    .jogador-historico-escudo-wrap .escudo-placeholder-circulo { width: 40px; height: 40px; flex-shrink: 0; }
    .jogador-historico-info { flex: 1 1 auto; min-width: 0; }
    .jogador-historico-gols-valor { flex-shrink: 0; }

    /* ---------- Lista de times no celular (sem precisar arrastar pro lado) ---------- */
    .time-linha-mobile {
      display: flex;
      align-items: center;
      gap: .85rem;
      padding: .85rem 1rem;
      border-bottom: 1px solid #eef1f3;
    }
    .time-linha-mobile:last-child { border-bottom: none; }
    .time-linha-mobile-info { flex: 1 1 auto; min-width: 0; }
    .time-linha-clicavel { cursor: pointer; -webkit-tap-highlight-color: transparent; }
    .time-linha-clicavel:active { background: rgba(var(--sao-verde-rgb), .06); }
    [data-bs-theme="dark"] .time-linha-mobile { border-bottom-color: #2c353b; }
    [data-bs-theme="dark"] .time-linha-clicavel:active { background: rgba(255, 255, 255, .05); }

    /* ---------- Confronto (matchup com glassmorphism) ---------- */
    .confronto {
      --pos-santo: 22%;
      --pos-adv: 78%;
      --cor-adv-rgb: 107, 21, 34;
      position: relative;
      display: flex;
      align-items: flex-start;
      justify-content: center;
      gap: 1rem;
      padding: 1.6rem .9rem 1.4rem;
      border-radius: 22px;
      overflow: hidden;
      isolation: isolate;
      background: rgba(255, 255, 255, .05);
      border: 1px solid rgba(20, 20, 40, .18);
      box-shadow:
        0 14px 40px rgba(20, 20, 40, .16),
        0 2px 8px rgba(20, 20, 40, .08),
        inset 0 1px 0 rgba(255, 255, 255, .45);
      transition: transform .25s ease, box-shadow .25s ease;
    }
    .confronto:hover {
      transform: translateY(-2px);
      box-shadow:
        0 20px 48px rgba(20, 20, 40, .2),
        0 3px 10px rgba(20, 20, 40, .1),
        inset 0 1px 0 rgba(255, 255, 255, .5);
    }
    .confronto::before {
      content: "";
      position: absolute;
      inset: 0;
      z-index: -1;
      /* Lado do time da casa (da conta): grená → branco → verde do tema da
         conta (visual "bandeira", só que com as cores do time em vez de fixo
         Santo Antônio), translúcido. As cores vão até a borda (em vez de sumir
         em "transparent") pra não deixar uma faixa branca/cinza sem graça nas
         pontas do card no modo claro. */
      background:
        radial-gradient(circle at var(--pos-santo) 50%,
          rgba(var(--sao-grena-rgb), .95) 0%, rgba(246, 246, 244, .9) 34%, rgba(var(--sao-verde-rgb), .95) 62%, rgba(var(--sao-verde-rgb), .4) 100%),
        radial-gradient(circle at var(--pos-adv) 50%, rgba(var(--cor-adv-rgb), .95) 0%, rgba(var(--cor-adv-rgb), .4) 100%);
      filter: blur(16px);
    }
    .confronto::after {
      content: "";
      position: absolute;
      inset: 0;
      z-index: 0;
      background: linear-gradient(165deg, rgba(255, 255, 255, .3) 0%, rgba(255, 255, 255, 0) 45%);
      pointer-events: none;
    }
    .confronto-time {
      position: relative;
      z-index: 1;
      display: flex;
      flex-direction: column;
      align-items: center;
      text-align: center;
      width: 118px;
      flex-shrink: 0;
    }
    .confronto-escudo-wrap {
      position: relative;
      display: flex;
      align-items: center;
      justify-content: center;
    }
    .confronto-escudo-wrap::before {
      content: "";
      position: absolute;
      inset: -10px;
      border-radius: 50%;
      background: radial-gradient(circle, rgba(255, 255, 255, .55) 0%, rgba(255, 255, 255, 0) 72%);
      z-index: -1;
    }
    .confronto-escudo {
      width: 78px; height: 78px; object-fit: contain;
      image-rendering: -webkit-optimize-contrast;
      image-rendering: crisp-edges;
      filter: drop-shadow(0 5px 10px rgba(20, 20, 40, .32));
    }
    .confronto-nome {
      margin-top: .6rem;
      font-weight: 800;
      font-size: .85rem;
      line-height: 1.2;
      min-height: 2.15em;
      display: flex;
      align-items: flex-start;
      justify-content: center;
      text-shadow: 0 1px 3px rgba(20, 20, 40, .12);
      overflow-wrap: break-word;
    }
    .confronto-versus {
      position: relative;
      z-index: 1;
      flex-shrink: 0;
      width: 40px; height: 40px;
      margin-top: 20px;
      border-radius: 50%;
      display: flex; align-items: center; justify-content: center;
      font-weight: 800; font-size: 1rem;
      color: var(--texto-suave);
      background: rgba(255, 255, 255, .7);
      box-shadow: 0 3px 12px rgba(20, 20, 40, .18), inset 0 1px 0 rgba(255, 255, 255, .7);
      backdrop-filter: blur(8px);
    }
    .confronto-grande .confronto-escudo { width: 112px; height: 112px; }
    .confronto-grande .confronto-time { width: 160px; }
    .confronto-grande .confronto-nome { font-size: 1rem; }
    .confronto-placar {
      width: auto;
      min-width: 46px;
      height: 46px;
      margin-top: 20px;
      padding: 0 .75rem;
      border-radius: 999px;
      font-size: 1.2rem;
      font-weight: 800;
      color: #fff !important;
      white-space: nowrap;
      box-shadow: 0 4px 14px rgba(20, 20, 40, .28), inset 0 1px 0 rgba(255, 255, 255, .35);
    }
    [data-bs-theme="dark"] .confronto {
      background: rgba(255, 255, 255, .07);
      border-color: rgba(255, 255, 255, .14);
      box-shadow:
        0 14px 40px rgba(0, 0, 0, .4),
        0 2px 8px rgba(0, 0, 0, .25),
        inset 0 1px 0 rgba(255, 255, 255, .12);
    }
    [data-bs-theme="dark"] .confronto:hover {
      box-shadow:
        0 20px 48px rgba(0, 0, 0, .45),
        0 3px 10px rgba(0, 0, 0, .3),
        inset 0 1px 0 rgba(255, 255, 255, .14);
    }
    [data-bs-theme="dark"] .confronto::after {
      background: linear-gradient(165deg, rgba(255, 255, 255, .1) 0%, rgba(255, 255, 255, 0) 45%);
    }
    [data-bs-theme="dark"] .confronto-escudo-wrap::before {
      background: radial-gradient(circle, rgba(255, 255, 255, .18) 0%, rgba(255, 255, 255, 0) 72%);
    }
    [data-bs-theme="dark"] .confronto-escudo {
      filter: drop-shadow(0 3px 10px rgba(0, 0, 0, .5));
    }
    [data-bs-theme="dark"] .confronto-nome { text-shadow: 0 1px 3px rgba(0, 0, 0, .4); }
    [data-bs-theme="dark"] .confronto-versus {
      background: rgba(30, 37, 41, .75);
      color: #cfd6db;
      box-shadow: 0 3px 12px rgba(0, 0, 0, .3), inset 0 1px 0 rgba(255, 255, 255, .12);
    }
    @media (max-width: 480px) {
      .confronto { gap: 1rem; padding: 1.3rem .75rem; }
      .confronto-time { width: 96px; }
      .confronto-escudo { width: 72px; height: 72px; }
      .confronto-nome { font-size: .78rem; min-height: 1.9em; margin-top: .5rem; }
      .confronto-versus { width: 38px; height: 38px; margin-top: 14px; font-size: .95rem; }
      .confronto-placar { min-width: 42px; height: 40px; margin-top: 14px; font-size: 1.05rem; padding: 0 .65rem; }
      .confronto-grande .confronto-escudo { width: 84px; height: 84px; }
      .confronto-grande .confronto-time { width: 118px; }
      .confronto-grande .confronto-nome { font-size: .82rem; }
    }

    /* ---------- Dropdown de busca (times/endereços) ---------- */
    .time-picker-dropdown {
      display: none;
      position: absolute;
      top: calc(100% + 6px);
      left: 0;
      right: 0;
      z-index: 20;
      max-height: 320px;
      overflow-y: auto;
      background: #fff;
      border: 1px solid #e3e6ea;
      border-radius: 12px;
      box-shadow: 0 12px 32px rgba(20,20,40,.18);
      padding: .4rem;
    }
    .time-picker-dropdown.aberta { display: block; }
    .time-picker-item {
      display: flex;
      align-items: center;
      gap: .65rem;
      padding: .5rem .6rem;
      border-radius: 8px;
      cursor: pointer;
    }
    .time-picker-item:hover { background: #eef1f3; }

    footer.app-footer {
      color: var(--texto-suave);
      font-size: .82rem;
      text-align: center;
      padding: 1.5rem 0;
    }

    /* ---------- Barra de navegação inferior (estilo app de app de time) ---------- */
    .barra-nav-inferior {
      position: fixed;
      bottom: 0; left: 0; right: 0;
      z-index: 1030;
      display: flex;
      background: var(--bs-body-bg, #fff);
      border-top: 1px solid var(--bs-border-color, #e3e6ea);
      box-shadow: 0 -4px 18px rgba(0, 0, 0, .08);
      padding-bottom: env(safe-area-inset-bottom, 0px);
    }
    .barra-nav-item {
      flex: 1;
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      gap: .15rem;
      padding: .5rem 0 .4rem;
      color: var(--texto-suave);
      text-decoration: none;
      font-size: .66rem;
      font-weight: 700;
      transition: color .15s ease;
    }
    .barra-nav-item i { font-size: 1.25rem; line-height: 1; }
    .barra-nav-item:hover { color: var(--sao-verde); }
    .barra-nav-item.active { color: var(--sao-verde); }
    /* as duas metades dividem a largura igualmente entre si (2 itens à
       esquerda, 3 à direita) — garante que o vão central fique sempre
       exatamente no meio da barra, não importa quantos itens tem cada lado */
    .barra-nav-metade { flex: 1 1 0; display: flex; min-width: 0; }
    .barra-nav-vao { flex: 0 0 70px; }
    [data-bs-theme="dark"] .barra-nav-inferior { background: #1a2226; border-top-color: #2c353b; }
    [data-bs-theme="dark"] .barra-nav-item.active,
    [data-bs-theme="dark"] .barra-nav-item:hover { color: #3ecf6a; }

    /* item central em destaque (Escala 11) — "botão flutuante" erguido acima
       da barra, tirado do fluxo flex normal (os outros 5 itens continuam
       dividindo 100% da largura igualmente entre si) */
    .barra-nav-item-destaque {
      position: absolute;
      top: -22px;
      left: 50%;
      transform: translateX(-50%);
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: .2rem;
      text-decoration: none;
      width: 64px;
    }
    .barra-nav-destaque-circulo {
      width: 52px;
      height: 52px;
      border-radius: 50%;
      display: flex;
      align-items: center;
      justify-content: center;
      background: linear-gradient(135deg, var(--sao-verde), var(--sao-verde-escuro, #0a3620));
      box-shadow: 0 6px 16px rgba(20, 107, 57, .45), 0 0 0 4px var(--bs-body-bg, #fff);
      color: #fff;
      font-size: 1.4rem;
      transition: box-shadow .15s ease, transform .15s ease;
    }
    /* marcações de campo (linha central + círculo central) desenhadas dentro
       do próprio círculo verde — vira uma mini "bola de campo" em vez de ícone */
    .barra-nav-campo-svg { width: 30px; height: 30px; }
    .barra-nav-destaque-label {
      font-size: .64rem;
      font-weight: 800;
      color: var(--sao-verde);
    }
    .barra-nav-item-destaque:hover .barra-nav-destaque-circulo,
    .barra-nav-item-destaque.active .barra-nav-destaque-circulo {
      box-shadow: 0 8px 20px rgba(20, 107, 57, .6), 0 0 0 4px var(--bs-body-bg, #fff);
      transform: translateY(-2px);
    }
    [data-bs-theme="dark"] .barra-nav-destaque-circulo { box-shadow: 0 6px 16px rgba(62, 207, 106, .35), 0 0 0 4px #1a2226; }
    [data-bs-theme="dark"] .barra-nav-item-destaque:hover .barra-nav-destaque-circulo,
    [data-bs-theme="dark"] .barra-nav-item-destaque.active .barra-nav-destaque-circulo {
      box-shadow: 0 8px 20px rgba(62, 207, 106, .5), 0 0 0 4px #1a2226;
    }
    [data-bs-theme="dark"] .barra-nav-destaque-label { color: #3ecf6a; }

    /* ---------- Resumo (próximo jogo / temporada) ---------- */
    .resumo-card { border-top: 4px solid var(--sao-dourado); }
    .resumo-escudo { width: 64px !important; height: 64px !important; }
    .aproveitamento-bar { background: linear-gradient(90deg, var(--sao-verde), var(--sao-dourado)); }

    /* ---------- Tema escuro ---------- */
    [data-bs-theme="dark"] {
      --bg-pagina: #12181b;
      --texto-suave: #9aa4ab;
    }
    [data-bs-theme="dark"] body { color: #e9edf0; }
    [data-bs-theme="dark"] .card { box-shadow: 0 4px 18px rgba(0, 0, 0, .35); }
    [data-bs-theme="dark"] .escudo-circulo,
    [data-bs-theme="dark"] .time-picker-dropdown,
    [data-bs-theme="dark"] .time-picker-item img { background: #1e2529; border-color: #2c353b; }
    [data-bs-theme="dark"] .escudo-placeholder-circulo,
    [data-bs-theme="dark"] .time-picker-placeholder { background: #1e2529; border-color: #2c353b; color: #6c757d; }
    [data-bs-theme="dark"] .time-picker-item:hover { background: #232b30; }
    [data-bs-theme="dark"] .mandante-toggle { background: #1e2529; }
    [data-bs-theme="dark"] .input-group-text.bg-white { background: #1e2529 !important; color: #e9edf0; border-color: #2c353b; }
    [data-bs-theme="dark"] .table-light,
    [data-bs-theme="dark"] .table-light > * { background: #1e2529; color: #e9edf0; }
    [data-bs-theme="dark"] .card-livre { opacity: .8; }
    [data-bs-theme="dark"] .btn-outline-secondary { color: #cfd6db; border-color: #3a444b; }
    [data-bs-theme="dark"] .btn-outline-warning-brand {
      border-color: var(--sao-dourado);
      color: #e0c157;
    }
    [data-bs-theme="dark"] .btn-outline-warning-brand:hover { background: var(--sao-dourado); color: #1a1015; }

    .theme-toggle {
      background: rgba(255,255,255,.1);
      border: 1px solid rgba(255,255,255,.2);
      color: #fff;
      border-radius: 10px;
      width: 40px;
      height: 40px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      transition: background .2s ease, transform .2s ease;
    }
    .theme-toggle:hover { background: rgba(255,255,255,.2); transform: translateY(-1px); }
    [data-bs-theme="dark"] .theme-toggle .bi-moon-stars-fill { display: none; }
    [data-bs-theme="light"] .theme-toggle .bi-sun-fill { display: none; }

    .suporte-whatsapp {
      background: #25D366;
      border: 1px solid rgba(255,255,255,.2);
      color: #fff;
      border-radius: 10px;
      width: 40px;
      height: 40px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      font-size: 1.2rem;
      transition: background .2s ease, transform .2s ease;
    }
    .suporte-whatsapp:hover { background: #1ebe5a; color: #fff; transform: translateY(-1px); }

    .atalho-agenda-livre {
      background: rgba(255,255,255,.1);
      border: 1px solid rgba(255,255,255,.2);
      color: #fff;
      border-radius: 10px;
      width: 40px;
      height: 40px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      font-size: 1.1rem;
      transition: background .2s ease, transform .2s ease;
    }
    .atalho-agenda-livre:hover { background: rgba(255,255,255,.2); color: #fff; transform: translateY(-1px); }
    .atalho-agenda-livre.active { background: var(--sao-verde, #2e7d32); border-color: var(--sao-verde, #2e7d32); }

    /* ---------- Animações ---------- */
    @keyframes agendaEntrada {
      from { opacity: 0; transform: translateY(12px); }
      to { opacity: 1; transform: translateY(0); }
    }
    .content-shell .card { animation: agendaEntrada .45s ease both; }
    .row.g-3 > div:nth-child(1) .card,
    .row.row-cols-1 > .col:nth-child(1) .card { animation-delay: .02s; }
    .row.g-3 > div:nth-child(2) .card,
    .row.row-cols-1 > .col:nth-child(2) .card { animation-delay: .07s; }
    .row.row-cols-1 > .col:nth-child(3) .card { animation-delay: .12s; }
    .row.row-cols-1 > .col:nth-child(4) .card { animation-delay: .17s; }
    .row.row-cols-1 > .col:nth-child(5) .card { animation-delay: .22s; }
    .card {
      transition: transform .2s ease, box-shadow .2s ease;
    }
    .card:hover { transform: translateY(-3px); box-shadow: 0 10px 28px rgba(20, 20, 40, .14); }
    [data-bs-theme="dark"] .card:hover { box-shadow: 0 10px 28px rgba(0, 0, 0, .45); }
    .btn { transition: transform .15s ease, background-color .15s ease, border-color .15s ease, color .15s ease; }
    .btn:active { transform: scale(.96); }
    .ios-install-banner {
      background: var(--sao-verde);
      color: #fff;
      font-size: .9rem;
      padding: .6rem 0;
    }
    .ios-install-banner.d-none { display: none; }

    /* ---------- Abas persistentes (navegação sem recarregar) ---------- */
    .app-abas-abertas {
      position: relative;
      z-index: 2;
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: .5rem;
      padding: .9rem .9rem;
      margin-top: 2.5rem;
      margin-bottom: 1rem;
      background: #e9ecef;
      border-radius: 12px;
    }
    [data-bs-theme="dark"] .app-abas-abertas { background: #0c1013; }
    .app-aba {
      display: inline-flex;
      align-items: center;
      gap: .5rem;
      padding: .5rem .6rem .5rem .95rem;
      border-radius: 999px;
      background: #ffffff;
      color: #364049;
      font-weight: 700;
      font-size: .8rem;
      cursor: pointer;
      border: 1px solid rgba(20,20,40,.12);
      max-width: 200px;
      box-shadow: 0 1px 3px rgba(20,20,40,.12);
    }
    .app-aba span.titulo { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .app-aba .fechar {
      display: inline-flex; align-items: center; justify-content: center;
      width: 17px; height: 17px; border-radius: 50%;
      background: rgba(0,0,0,.08); flex-shrink: 0; color: #364049;
    }
    .app-aba .fechar:hover { background: #c0392b; color: #fff; }
    .app-aba.active {
      background: var(--sao-verde);
      color: #fff;
      border-color: var(--sao-verde);
      box-shadow: 0 2px 8px rgba(var(--sao-verde-rgb), .5);
    }
    .app-aba.active .fechar { background: rgba(255,255,255,.25); color: #fff; }
    .app-pane { display: none; }
    .app-pane.active { display: block; }
