:root {
    --verde: #00863d;
    --cinza-claro: #f4f5f7;
    --cinza-texto: #444;
    --branco: #fff;
    --amarelo-badge: #fff3cd;
    --amarelo-badge-texto: #8a6d00;
}

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

body {
    font-family: 'Segoe UI', Arial, sans-serif;
    background: var(--cinza-claro);
    color: var(--cinza-texto);
    line-height: 1.5;
}

.container { max-width: 1140px; margin: 0 auto; padding: 0 16px; }
.main-content { max-width: 1140px; margin: 0 auto; padding: 24px 16px 60px; min-height: 60vh; }

/* Header + logo */
.site-header { background: #1a1d29; }
.header-inner { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; flex-wrap: wrap; }
.logo { color: #fff; font-size: 1.5rem; font-weight: 800; text-decoration: none; letter-spacing: -0.5px; }
.logo span { color: #4ade80; }

.menu-toggle {
    display: none; background: none; border: none; color: #fff; font-size: 1.5rem; cursor: pointer;
}

.main-nav { display: flex; align-items: center; gap: 4px; }
.main-nav > a {
    color: #cbd5e1; text-decoration: none; font-weight: 500; padding: 10px 14px; border-radius: 6px; font-size: 0.92rem;
    transition: background 0.15s, color 0.15s;
}
.main-nav > a:hover { background: rgba(255,255,255,0.08); color: #fff; }

.nav-dropdown { position: relative; }
.nav-dropdown-btn {
    background: none; border: none; color: #cbd5e1; font-family: inherit; font-size: 0.92rem; font-weight: 500;
    padding: 10px 14px; border-radius: 6px; cursor: pointer;
}
.nav-dropdown-btn:hover { background: rgba(255,255,255,0.08); color: #fff; }
.nav-dropdown-content {
    display: none; position: absolute; top: 100%; left: 0; background: #fff; min-width: 220px;
    border-radius: 10px; box-shadow: 0 10px 30px rgba(0,0,0,0.2); overflow: hidden; z-index: 20; padding: 6px;
}
.nav-dropdown:hover .nav-dropdown-content { display: block; }
.nav-dropdown-content a {
    display: flex; align-items: center; gap: 10px; padding: 9px 12px; color: #333; text-decoration: none;
    font-size: 0.9rem; border-radius: 6px;
}
.nav-dropdown-content a:hover { background: #f4f5f7; }
.dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }

@media (max-width: 860px) {
    .menu-toggle { display: block; }
    .main-nav {
        display: none; flex-direction: column; align-items: stretch; width: 100%;
        background: #1a1d29; padding: 10px 0; gap: 0;
    }
    .main-nav.aberto { display: flex; }
    .main-nav > a { padding: 12px 8px; }
    .nav-dropdown-content { position: static; box-shadow: none; background: #22263a; margin-left: 12px; }
    .nav-dropdown-content a { color: #cbd5e1; }
    .nav-dropdown-content a:hover { background: rgba(255,255,255,0.06); }
}

/* Hero */
.hero-banner { background: linear-gradient(135deg, #1a1d29 0%, #2d3348 100%); padding: 56px 0; text-align: center; }
.hero-banner h1 { color: #fff; font-size: 2.3rem; font-weight: 800; margin-bottom: 10px; letter-spacing: -0.5px; }
.hero-sub { color: #a8afc2; font-size: 1.05rem; max-width: 560px; margin: 0 auto; }

/* Ticker "sorteia hoje" */
.ticker-hoje { background: #fff; border-bottom: 1px solid #eee; padding: 12px 0; }
.ticker-hoje-inner { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.ticker-label { font-size: 0.72rem; font-weight: 800; color: #999; letter-spacing: 1.5px; white-space: nowrap; }
.ticker-itens { display: flex; gap: 10px; flex-wrap: wrap; }
.ticker-item {
    display: inline-flex; align-items: center; gap: 6px; text-decoration: none; color: #333;
    font-size: 0.85rem; font-weight: 600; padding: 5px 12px; border-radius: 20px; background: #f4f5f7;
}
.ticker-item:hover { background: #ececec; }
.ticker-item strong { color: var(--cor-loteria); font-weight: 700; }
.ticker-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--cor-loteria); flex-shrink: 0; }

.titulo-secao { text-align: center; font-size: 1.5rem; margin: 36px 0 20px; color: #1a1d29; font-weight: 700; }

/* Cards de resultado (design próprio, com barra lateral colorida em vez de topo colorido) */
.resultados-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 18px; }
.resultado-card {
    background: #fff; border-radius: 10px; padding: 20px; border-left: 5px solid var(--cor-loteria);
    box-shadow: 0 1px 4px rgba(0,0,0,0.06); display: flex; flex-direction: column;
}
.resultado-card-topo { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 4px; }
.resultado-card-topo h3 { font-size: 1.1rem; color: #1a1d29; }
.tag-concurso { font-size: 0.75rem; color: #999; font-weight: 600; }
.resultado-card-rodape {
    display: flex; justify-content: space-between; font-size: 0.8rem; color: #888;
    border-top: 1px solid #f0f0f0; padding-top: 10px; margin-top: 12px;
}

.data-sorteio-label { font-size: 0.8rem; color: #888; text-align: center; margin-bottom: 10px; }
.data-sorteio-label strong { color: #333; }
.numeros-label { font-size: 0.75rem; color: #999; text-align: center; letter-spacing: 1px; margin: 10px 0 6px; }

.dezenas { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-bottom: 4px; }
.bola {
    display: inline-flex; align-items: center; justify-content: center;
    width: 36px; height: 36px; border-radius: 50%;
    background: var(--cor-loteria, var(--verde)); color: var(--branco); font-weight: bold; font-size: 0.9rem;
}

.badge-acumulou, .badge-ganhador {
    margin: 14px 0; padding: 10px; border-radius: 8px; text-align: center;
    background: var(--amarelo-badge); color: var(--amarelo-badge-texto); font-weight: bold;
}
.badge-ganhador { background: #d4f4dd; color: #1a6b34; }
.badge-ganhador small { display: block; font-weight: normal; margin-top: 4px; }

.estimativa-label { font-size: 0.72rem; color: #999; text-align: center; letter-spacing: 0.5px; margin-top: 12px; }
.estimativa-valor { font-size: 1.4rem; font-weight: bold; color: var(--cor-loteria); text-align: center; margin: 4px 0; }
.proximo-sorteio { font-size: 0.78rem; color: #999; text-align: center; }

.btn-conferir {
    display: block; text-align: center; background: var(--cor-loteria); color: var(--branco);
    padding: 14px; text-decoration: none; font-weight: 600; margin-top: auto;
}
.btn-conferir:hover { filter: brightness(0.92); }

/* Tabelas */
.tabela-info { width: 100%; border-collapse: collapse; margin-top: 16px; }
.tabela-info td, .tabela-info th { padding: 8px 10px; border-bottom: 1px solid #eee; text-align: left; }
.tabela-info tr td:first-child { color: #666; }

.navegacao-concursos { display: flex; justify-content: space-between; margin-top: 20px; }
.navegacao-concursos a { color: var(--verde); text-decoration: none; font-weight: 500; }

/* Card individual (página de resultado) */
.card-resultado {
    background: var(--branco); border-radius: 10px; padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08); max-width: 500px; margin: 20px auto;
}
.card-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }

/* Formulários */
.form-gerador, .filtro-loteria {
    background: var(--branco); padding: 20px; border-radius: 10px;
    display: flex; flex-direction: column; gap: 10px; max-width: 420px; margin-bottom: 24px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}
.form-gerador label { font-weight: 600; }
.form-gerador select, .form-gerador input {
    padding: 10px; border: 1px solid #ddd; border-radius: 6px; font-size: 1rem;
}
.btn-gerar {
    background: var(--verde); color: var(--branco); border: none; padding: 12px;
    border-radius: 6px; font-size: 1rem; cursor: pointer; font-weight: 600;
}
.btn-gerar:hover { filter: brightness(0.92); }

.estatisticas-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; }
.bloco-estatistica { background: var(--branco); padding: 20px; border-radius: 10px; box-shadow: 0 2px 8px rgba(0,0,0,0.08); }
.bola-stat { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.bola-stat small { color: #888; }
.bola-trevo { background: #2e7d32; border-radius: 8px; }

.lista-bilhetes { display: flex; flex-direction: column; gap: 6px; margin: 10px 0; }
.bilhete-item {
    display: flex; align-items: center; justify-content: space-between;
    background: var(--cor-loteria); color: #fff; padding: 10px 16px; border-radius: 6px; font-weight: 600;
}
.bilhete-posicao { min-width: 30px; }
.bilhete-numero { flex: 1; text-align: center; letter-spacing: 1px; }
.bilhete-valor { min-width: 110px; text-align: right; }
.info-extra-valor { text-align: center; font-weight: bold; font-size: 1.1rem; color: #222; margin-bottom: 8px; }

.tabela-info th { background: #f4f5f7; font-size: 0.85rem; text-transform: uppercase; color: #666; }
.tabela-info td { font-size: 0.9rem; }
.tabela-info tr:last-child td { border-bottom: none; }

/* Volante (grade de números, estilo cartão de aposta oficial) */
.volante-grid {
    display: grid; grid-template-columns: repeat(var(--colunas, 10), 42px); gap: 4px;
    margin: 12px 0; justify-content: center;
}
.volante-numero {
    display: flex; align-items: center; justify-content: center;
    width: 42px; height: 36px; border-radius: 4px; font-weight: 600; font-size: 0.85rem;
    background: #fff; border: 1px solid #ccc; color: #555;
}
.volante-clicavel { cursor: pointer; transition: all 0.12s; user-select: none; }
.volante-clicavel:hover { border-color: var(--cor-loteria, #333); }
.volante-numero.marcado {
    background: var(--cor-loteria, var(--verde)); border-color: var(--cor-loteria, var(--verde)); color: #fff;
}
#contador-selecionados { color: #888; font-weight: normal; }

/* Volante da Super Sete: 7 colunas, cada uma com os dígitos 0-9 empilhados */
.supersete-colunas { display: flex; gap: 4px; margin: 12px 0; justify-content: center; }
.supersete-coluna { display: flex; flex-direction: column; gap: 4px; }
.supersete-digito {
    width: 40px; height: 32px; display: flex; align-items: center; justify-content: center;
    border-radius: 4px; border: 1px solid #ccc; background: #fff; color: #666; font-weight: 600; font-size: 0.85rem;
}
.supersete-digito.marcado { background: var(--cor-loteria, var(--verde)); border-color: var(--cor-loteria, var(--verde)); color: #fff; }
.supersete-digito.clicavel { cursor: pointer; }
.supersete-digito.clicavel:hover { border-color: var(--cor-loteria, #333); }

/* Bilhetes gerados da Federal */
.bilhetes-gerados { display: flex; flex-direction: column; gap: 6px; max-width: 320px; margin: 16px auto; }
.bilhete-gerado {
    background: var(--cor-loteria); color: #fff; text-align: center; padding: 10px;
    border-radius: 6px; font-weight: 600;
}

.busca-concurso { display: flex; gap: 8px; max-width: 400px; margin: 0 auto 20px; }
.busca-concurso input {
    flex: 1; padding: 10px; border: 1px solid #ddd; border-radius: 6px; font-size: 0.95rem;
}
.busca-concurso button {
    background: #333; color: #fff; border: none; padding: 10px 16px; border-radius: 6px; cursor: pointer; font-size: 0.9rem;
}
.busca-concurso button:hover { background: #555; }

/* Estatísticas completas */
.secao-estatistica { margin-bottom: 40px; }
.secao-estatistica h2 { text-align: center; margin-bottom: 4px; }
.subtitulo-estatistica { text-align: center; color: #888; font-size: 0.9rem; margin-bottom: 16px; }
.tabela-scroll { overflow-x: auto; }
.tabela-freq { width: 100%; border-collapse: collapse; margin: 0 auto; }
.tabela-freq th {
    background: var(--cor-loteria); color: #fff; padding: 6px 10px; font-size: 0.8rem; text-align: center;
}
.tabela-freq td { padding: 8px 10px; text-align: center; border-bottom: 1px solid #eee; font-size: 0.9rem; }
.tabela-freq .celula-dezena { background: var(--cor-loteria); color: #fff; font-weight: bold; }
.tabela-detalhada th { background: var(--cor-loteria); color: #fff; }
.tabela-detalhada td { text-align: center; }

/* Páginas de texto (política de privacidade etc) */
.pagina-texto { max-width: 780px; background: #fff; padding: 32px; border-radius: 10px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.pagina-texto h1 { margin-bottom: 4px; }
.pagina-texto h2 { margin-top: 28px; margin-bottom: 8px; font-size: 1.2rem; color: var(--verde); }
.pagina-texto p, .pagina-texto li { color: #444; line-height: 1.7; }
.pagina-texto ul { margin: 8px 0 8px 20px; }
.atualizado-em { color: #999; font-size: 0.85rem; margin-bottom: 20px; }

.footer-links { margin-top: 8px; }
.footer-links a { color: #999; font-size: 0.8rem; text-decoration: underline; }

/* Links relacionados (botões grandes, estilo "próximo passo") */
.links-relacionados { display: flex; flex-direction: column; gap: 10px; max-width: 500px; margin: 24px auto 0; }
.link-relacionado {
    display: flex; align-items: center; gap: 12px; background: var(--cor-loteria); color: #fff;
    text-decoration: none; padding: 14px 18px; border-radius: 8px; font-weight: 600; font-size: 0.95rem;
    transition: filter 0.15s;
}
.link-relacionado:hover { filter: brightness(0.92); }
.link-icone { font-size: 1.1rem; }
.link-seta { margin-left: auto; font-weight: bold; }

/* Página de últimos resultados */
.lista-ultimos-resultados { display: flex; flex-direction: column; gap: 16px; max-width: 700px; margin: 0 auto; }
.item-ultimo-resultado {
    background: #fff; border: 1px solid #eee; border-radius: 10px; padding: 18px; text-align: center;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}
.item-cabecalho {
    display: inline-block; border: 1px solid #ddd; border-radius: 20px; padding: 6px 18px;
    font-weight: 600; color: #333; margin-bottom: 14px; font-size: 0.9rem;
}
.link-ver-detalhes {
    display: inline-block; margin-top: 14px; color: var(--cor-loteria); text-decoration: none; font-weight: 600;
}
.link-ver-detalhes:hover { text-decoration: underline; }

/* Responsividade dos volantes em telas pequenas */
@media (max-width: 600px) {
    .volante-grid { grid-template-columns: repeat(var(--colunas, 10), minmax(0, 1fr)); gap: 3px; }
    .volante-numero { width: 100%; height: 30px; font-size: 0.72rem; }
    .supersete-colunas { gap: 2px; overflow-x: auto; padding-bottom: 4px; }
    .supersete-digito { width: 30px; height: 26px; font-size: 0.75rem; }
    .form-gerador, .filtro-loteria { max-width: 100%; }
}

.erro { color: #c0392b; font-weight: bold; margin-bottom: 16px; }

/* Footer */
.site-footer { background: #1c1c1c; color: #ccc; text-align: center; padding: 24px 0; margin-top: 40px; }
.site-footer .disclaimer { font-size: 0.8rem; margin-top: 8px; color: #999; }
.site-footer a { color: var(--verde); }

@media (max-width: 600px) {
    .hero h1 { font-size: 1.7rem; }
}
