:root {
    --bg-color: #050505;
    --text-primary: #ffffff;
    --text-secondary: #a0a0a0;
    --accent-color: #00f3ff;
    --accent-secondary: #7000ff;
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
}

body.logged-out .hero-content {
    max-width: min(1120px, 100%);
}

.public-live-panel,
.public-last-results-card {
    width: min(1040px, 100%);
    margin: 1.15rem auto 0;
    border: 1px solid rgba(0, 243, 255, 0.15);
    background: rgba(10, 16, 30, 0.75);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 18px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), 0 0 15px rgba(0, 243, 255, 0.05);
}

.public-live-panel {
    padding: clamp(0.9rem, 2vw, 1.25rem);
}

.public-live-heading,
.public-last-results-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.85rem;
    text-align: left;
}

.public-live-heading span,
.public-last-results-header span {
    color: var(--accent-color, #00f3ff);
    font-family: 'Orbitron', sans-serif;
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
    text-shadow: 0 0 10px rgba(0, 243, 255, 0.4);
}

.public-live-heading strong,
.public-last-results-header strong {
    color: #ffffff;
    font-size: 0.95rem;
    font-weight: 700;
    text-transform: uppercase;
    opacity: 0.9;
}

.public-score-carousel {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: clamp(210px, 24vw, 260px);
    gap: 0.85rem;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 0.25rem;
    padding: 0.2rem 0.12rem 0.65rem;
    scrollbar-width: thin;
}

.public-score-carousel::-webkit-scrollbar {
    height: 6px;
}

.public-score-carousel::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 99px;
}

.public-score-carousel::-webkit-scrollbar-thumb {
    background: rgba(0, 243, 255, 0.3);
    border-radius: 99px;
    transition: background 0.3s;
}

.public-score-carousel::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 243, 255, 0.6);
}

.public-score-card {
    min-height: 155px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.95rem;
    border-radius: 14px;
    border: 1px solid rgba(0, 243, 255, 0.12);
    border-top: 3px solid #00f3ff;
    background: linear-gradient(135deg, rgba(13, 22, 43, 0.75), rgba(7, 12, 25, 0.92));
    color: #ffffff;
    scroll-snap-align: start;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.45);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.public-score-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(0, 243, 255, 0.03) 0%, transparent 100%);
    pointer-events: none;
}

.public-score-card:hover {
    border-color: rgba(0, 243, 255, 0.4);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.65), 0 0 20px rgba(0, 243, 255, 0.25);
    transform: translateY(-4px);
}

.public-score-game {
    min-height: 2.2em;
    color: #ffffff;
    font-size: 0.88rem;
    font-family: 'Orbitron', sans-serif;
    font-weight: 850;
    line-height: 1.2;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding-bottom: 8px;
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.15);
}

.public-score-line {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 0.6rem;
    background: rgba(0, 0, 0, 0.15);
    padding: 6px 12px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.02);
}

.public-score-line div {
    min-width: 0;
    text-align: center;
}

.public-score-line small {
    display: block;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.62rem;
    font-weight: 700;
    line-height: 1;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.public-score-line strong {
    display: block;
    margin-top: 0.2rem;
    color: #ffffff;
    font-family: 'Orbitron', sans-serif;
    font-size: 1.8rem;
    font-weight: 900;
    line-height: 1;
}

/* Style positive score */
.public-score-line div:first-child strong {
    color: #10b981;
    text-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
}

/* Style loss score */
.public-score-line div:last-child strong {
    color: #ef4444;
    text-shadow: 0 0 10px rgba(239, 68, 68, 0.5);
}

.public-score-line b {
    color: rgba(255, 255, 255, 0.15);
    font-family: 'Orbitron', sans-serif;
    font-size: 0.8rem;
    font-weight: 900;
}

.public-score-meta {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px 10px;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.65rem;
    font-weight: 750;
    text-transform: uppercase;
    background: rgba(0, 0, 0, 0.3);
    padding: 8px 10px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.04);
}

.public-score-meta span {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4px;
}

.public-score-meta b {
    font-family: 'Orbitron', sans-serif;
    font-weight: 850;
}

/* Color coding scoreboard breakdown tags with glow */
.public-score-meta span:nth-child(1) b {
    color: #00f3ff;
    text-shadow: 0 0 6px rgba(0, 243, 255, 0.45);
}

.public-score-meta span:nth-child(2) b {
    color: #a855f7;
    text-shadow: 0 0 6px rgba(168, 85, 247, 0.45);
}

.public-score-meta span:nth-child(3) b {
    color: #ec4899;
    text-shadow: 0 0 6px rgba(236, 72, 153, 0.45);
}

.public-score-meta span:nth-child(4) b {
    color: #eab308;
    text-shadow: 0 0 6px rgba(234, 179, 8, 0.45);
}

.public-score-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.65rem;
    padding-top: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.65rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.public-score-footer strong {
    color: #00f3ff;
    font-family: 'Orbitron', sans-serif;
    font-size: 1.05rem;
    font-weight: 900;
    text-shadow: 0 0 10px rgba(0, 243, 255, 0.6);
}

.public-last-results-card {
    padding: 1rem 0 0.85rem;
    border-radius: 18px;
    overflow: hidden;
}

.public-last-results-header {
    padding: 0 1.25rem;
}

.public-result-carousel {
    overflow: hidden;
}

.public-result-track {
    width: max-content;
    display: flex;
    align-items: stretch;
    gap: 0.82rem;
    padding: 0.15rem 0.9rem 0.25rem;
    animation: public-result-scroll 34s linear infinite;
}

.public-last-results-card:hover .public-result-track {
    animation-play-state: paused;
}

.public-result-slide {
    width: 320px;
    min-height: 104px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.58rem;
    padding: 0.78rem 0.82rem;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: linear-gradient(135deg, rgba(20, 30, 55, 0.6), rgba(10, 15, 30, 0.8));
    color: #ffffff;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.3);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.public-result-slide:hover {
    border-color: rgba(0, 243, 255, 0.35);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5), 0 0 15px rgba(0, 243, 255, 0.18);
    transform: translateY(-3px);
}

.public-result-slide span {
    color: #ffffff;
    font-size: 0.85rem;
    font-family: 'Orbitron', sans-serif;
    font-weight: 700;
    line-height: 1.15;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    padding-bottom: 6px;
}

.public-result-slide strong {
    min-width: 0;
    color: #ffffff;
    font-family: 'Orbitron', sans-serif;
    font-size: 1rem;
    line-height: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.public-result-slide em {
    min-width: 0;
}

.public-result-chip-row {
    display: grid;
    grid-template-columns: repeat(10, minmax(0, 1fr));
    gap: 0.28rem;
}

.public-result-chip {
    min-width: 0;
    height: 34px;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.05);
    color: #ffffff;
    font-style: normal;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-weight: 800;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.public-result-chip b {
    color: #ffffff;
    font-size: 0.72rem;
    line-height: 1;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}

.public-result-slide.is-aviator-result .public-result-chip b {
    font-size: 0.62rem;
    font-weight: 750;
    letter-spacing: -0.3px;
}

.public-result-chip.is-B,
.public-result-chip.is-D,
.public-result-chip.is-V {
    background: linear-gradient(135deg, #ef4444, #991b1b);
    border-color: rgba(239, 68, 68, 0.4);
    box-shadow: 0 0 8px rgba(239, 68, 68, 0.3);
}

.public-result-chip.is-J,
.public-result-chip.is-A {
    background: linear-gradient(135deg, #3b82f6, #1e3a8a);
    border-color: rgba(59, 130, 246, 0.4);
    box-shadow: 0 0 8px rgba(59, 130, 246, 0.3);
}

.public-result-slide.is-roulette-result .public-result-chip.is-J {
    background: linear-gradient(135deg, #1e293b, #0f172a);
    border-color: rgba(255, 255, 255, 0.1);
}

.public-result-slide.is-dragon-tiger-result .public-result-chip.is-J,
.public-result-slide.is-dragon-tiger-result .public-result-chip.is-T {
    background: linear-gradient(135deg, #eab308, #854d0e);
    border-color: rgba(234, 179, 8, 0.4);
    box-shadow: 0 0 8px rgba(234, 179, 8, 0.3);
}

.public-result-chip.is-Y,
.public-result-chip.is-E {
    background: linear-gradient(135deg, #eab308, #854d0e);
    border-color: rgba(234, 179, 8, 0.4);
    box-shadow: 0 0 8px rgba(234, 179, 8, 0.3);
}

.public-result-chip.is-G {
    background: linear-gradient(135deg, #10b981, #065f46);
    border-color: rgba(16, 185, 129, 0.4);
    box-shadow: 0 0 8px rgba(16, 185, 129, 0.3);
}

.public-result-slide.is-super-trunfo-result .public-result-chip.is-E {
    background: linear-gradient(135deg, #10b981, #065f46);
    border-color: rgba(16, 185, 129, 0.4);
    box-shadow: 0 0 8px rgba(16, 185, 129, 0.3);
}

.public-result-slide.is-aviator-result .public-result-chip.is-O {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

.public-result-slide.is-aviator-result .public-result-chip.is-aviator-low {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

.public-result-slide.is-aviator-result .public-result-chip.is-aviator-blue {
    background: linear-gradient(135deg, #3b82f6, #1e3a8a);
    border-color: rgba(59, 130, 246, 0.4);
}

.public-result-slide.is-aviator-result .public-result-chip.is-aviator-purple {
    background: linear-gradient(135deg, #8b5cf6, #5b21b6);
    border-color: rgba(139, 92, 246, 0.4);
}

.public-result-slide.is-aviator-result .public-result-chip.is-aviator-pink {
    background: linear-gradient(135deg, #ec4899, #be185d);
    border-color: rgba(236, 72, 153, 0.4);
}

.public-result-slide.is-aviator-result .public-result-chip.is-aviator-hot {
    background: linear-gradient(135deg, #ff1493, #be0a6e);
    border-color: rgba(255, 20, 147, 0.4);
    box-shadow: 0 5px 14px rgba(255, 20, 147, 0.35);
}

@keyframes public-result-scroll {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(-50%);
    }
}

@media (max-width: 760px) {
    .public-live-heading,
    .public-last-results-header {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.22rem;
    }

    .public-score-carousel {
        grid-auto-columns: minmax(220px, 78vw);
    }

    .public-score-card {
        min-height: 136px;
    }

    .public-score-line {
        gap: 0.42rem;
    }

    .public-score-line strong {
        font-size: 1.22rem;
    }

    .public-result-slide {
        width: 292px;
    }

    .public-result-chip {
        height: 32px;
    }
}

/* Proteção de texto e arraste */
body, * {
    -webkit-user-select: none !important;
    -moz-user-select: none !important;
    -ms-user-select: none !important;
    user-select: none !important;
    -webkit-user-drag: none !important;
}

input, textarea {
    -webkit-user-select: text !important;
    -moz-user-select: text !important;
    -ms-user-select: text !important;
    user-select: text !important;
}

/* Correção simples e final do layout interno dos games */
body.game-page-body .game-page {
    width: 100%;
    max-width: none;
    margin: 0 auto;
    padding: 0.55rem clamp(1rem, 2vw, 2.2rem) 1rem;
}

body.game-page-body .game-back {
    font-size: 0;
}

body.game-page-body .game-back::after {
    content: "← Jogos";
    font-size: 0.72rem;
}

body.game-page-body .game-title-block > p:not(.game-subtitle-clean) {
    display: none;
}

body.game-page-body .game-subtitle-clean {
    display: block;
}

body.game-page-body .game-live-status {
    font-size: 0;
}

body.game-page-body .game-live-status::before {
    content: "↻ Ao Vivo • ";
    font-size: 0.82rem;
}

body.game-page-body .game-live-status span {
    font-size: 0.82rem;
}

body.game-page-body .game-topbar {
    min-height: 34px;
    margin-bottom: 0.65rem;
}

body.game-page-body .game-hero-panel {
    padding: 0.45rem 0 0.65rem;
    margin: 0;
}

body.game-page-body .game-stats-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.85rem;
    margin: 0 0 0.75rem;
}

body.game-page-body .game-stat-card {
    min-height: 112px;
    padding: 0.95rem 1rem;
}

body.game-page-body .stat-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.9rem;
}

body.game-page-body .stat-values strong {
    display: block;
    font-size: 1.75rem;
    line-height: 1;
}

body.game-page-body .round-filter {
    min-height: 40px;
    margin: 0 0 0.75rem;
}

body.game-page-body .game-tabs {
    margin-bottom: 0.8rem;
}

body.game-page-body .pattern-validator-card,
body.game-page-body .analysis-card {
    border-radius: 10px;
}

body.game-page-body .pattern-validator-card {
    padding: 1rem 1.15rem;
}

body.game-page-body .validator-layout {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

body.game-page-body .validator-pattern-box {
    min-height: 54px;
}

body.game-page-body .game-analysis-grid {
    grid-template-columns: minmax(0, 1.55fr) minmax(360px, 0.62fr);
    gap: 1rem;
}

body.game-page-body .analysis-card {
    min-height: 280px;
}

body.game-page-body .live-history-section {
    min-height: 360px;
}

@media (min-width: 1500px) {
    body.game-page-body .game-page {
        padding-left: 2rem;
        padding-right: 2rem;
    }

    body.game-page-body .game-analysis-grid {
        grid-template-columns: minmax(0, 1.7fr) minmax(420px, 0.55fr);
    }

    body.game-page-body .result-chip-grid {
        grid-template-columns: repeat(auto-fill, minmax(30px, 30px));
    }
}

@media (max-width: 900px) {
    body.game-page-body .game-page {
        width: 100%;
        padding: 0.5rem 0.65rem 1rem;
    }

    body.game-page-body .game-stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    body.game-page-body .game-stat-card {
        min-height: 100px;
    }

    body.game-page-body .validator-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 520px) {
    body.game-page-body .game-stats-grid {
        grid-template-columns: 1fr;
    }

    body.game-page-body .game-stat-card {
        min-height: 82px;
    }
}

/* Preenchimento total da página de jogo */
body.game-page-body .game-page {
    width: 100%;
    max-width: none;
    padding-left: clamp(1rem, 2vw, 2.2rem);
    padding-right: clamp(1rem, 2vw, 2.2rem);
}

body.game-page-body .game-analysis-grid {
    grid-template-columns: minmax(0, 1.6fr) minmax(360px, 0.6fr);
}

@media (min-width: 1500px) {
    body.game-page-body .game-analysis-grid {
        grid-template-columns: minmax(0, 1.75fr) minmax(430px, 0.55fr);
    }
}

@media (max-width: 900px) {
    body.game-page-body .game-analysis-grid {
        grid-template-columns: 1fr;
    }
}

/* Layout fluido dos games - ultima regra */
body.game-page-body .game-stats-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
}

body.game-page-body .validator-layout {
    grid-template-columns: minmax(0, 1fr) minmax(320px, 0.85fr);
}

body.game-page-body .history-card-grid {
    grid-template-columns: repeat(auto-fill, minmax(clamp(44px, 4vw, 64px), 1fr));
}

@media (min-width: 1700px) {
    body.game-page-body .game-stats-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    body.game-page-body .analysis-card {
        min-height: 320px;
    }

    body.game-page-body .live-history-section {
        min-height: 410px;
    }
}

@media (max-width: 1200px) {
    body.game-page-body .game-analysis-grid,
    body.game-page-body .validator-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    body.game-page-body .game-stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    body.game-page-body .round-filter {
        justify-content: flex-start;
        overflow-x: auto;
    }
}

@media (max-width: 520px) {
    body.game-page-body .game-stats-grid,
    body.game-page-body .validator-controls,
    body.game-page-body .validator-summary-grid {
        grid-template-columns: 1fr;
    }
}

/* Layout fluido final dos games */
body.game-page-body .game-stats-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
}

body.game-page-body .round-filter {
    justify-content: center;
    overflow: visible;
}

body.game-page-body .game-tabs {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

body.game-page-body .validator-layout {
    grid-template-columns: minmax(0, 1fr) minmax(320px, 0.85fr);
}

body.game-page-body .history-card-grid {
    grid-template-columns: repeat(auto-fill, minmax(clamp(44px, 4vw, 64px), 1fr));
}

@media (min-width: 1700px) {
    body.game-page-body .game-page {
        padding-left: 2.6rem;
        padding-right: 2.6rem;
    }

    body.game-page-body .game-stats-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    body.game-page-body .analysis-card {
        min-height: 320px;
    }

    body.game-page-body .live-history-section {
        min-height: 410px;
    }
}

@media (max-width: 1200px) {
    body.game-page-body .game-analysis-grid {
        grid-template-columns: 1fr;
    }

    body.game-page-body .validator-layout {
        grid-template-columns: 1fr;
    }

    body.game-page-body .analysis-card {
        min-height: auto;
    }
}

@media (max-width: 760px) {
    .course-card {
        padding: 1rem;
        border-radius: 18px;
    }

    .course-video-shell {
        padding: 0.6rem;
        border-radius: 15px;
    }

    .course-copy p {
        font-size: 0.9rem;
    }

    body.game-page-body .game-page {
        padding-left: 0.85rem;
        padding-right: 0.85rem;
    }

    body.game-page-body .game-topbar {
        grid-template-columns: 1fr;
    }

    body.game-page-body .game-hero-panel {
        flex-direction: column;
    }

    body.game-page-body .game-stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    body.game-page-body .round-filter {
        justify-content: flex-start;
        overflow-x: auto;
    }

    body.game-page-body .game-tabs {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    body.game-page-body .latest-result-card {
        grid-template-columns: auto auto minmax(0, 1fr);
    }

    body.game-page-body .latest-result-card time {
        grid-column: 1 / -1;
    }
}

@media (max-width: 520px) {
    body.game-page-body .game-page {
        padding-left: 0.65rem;
        padding-right: 0.65rem;
    }

    body.game-page-body .game-stats-grid,
    body.game-page-body .validator-controls,
    body.game-page-body .validator-summary-grid {
        grid-template-columns: 1fr;
    }

    body.game-page-body .game-tabs button {
        min-height: 40px;
        padding: 0 0.4rem;
    }

    body.game-page-body .result-chip-grid {
        grid-template-columns: repeat(auto-fill, minmax(26px, 26px));
    }

    body.game-page-body .history-card-grid {
        grid-template-columns: repeat(auto-fill, minmax(44px, 1fr));
    }
}

/* Ajuste fluido da página de jogo por tamanho de tela */
body.game-page-body .game-stats-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
}

body.game-page-body .round-filter {
    justify-content: center;
}

body.game-page-body .game-tabs {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

body.game-page-body .validator-layout {
    grid-template-columns: minmax(0, 1fr) minmax(320px, 0.85fr);
}

body.game-page-body .history-card-grid {
    grid-template-columns: repeat(auto-fill, minmax(clamp(44px, 4vw, 64px), 1fr));
}

@media (min-width: 1700px) {
    body.game-page-body .game-page {
        padding-left: 2.6rem;
        padding-right: 2.6rem;
    }

    body.game-page-body .game-stats-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    body.game-page-body .analysis-card {
        min-height: 320px;
    }

    body.game-page-body .live-history-section {
        min-height: 410px;
    }
}

@media (max-width: 1200px) {
    body.game-page-body .game-analysis-grid {
        grid-template-columns: 1fr;
    }

    body.game-page-body .validator-layout {
        grid-template-columns: 1fr;
    }

    body.game-page-body .analysis-card {
        min-height: auto;
    }
}

@media (max-width: 760px) {
    body.game-page-body .game-page {
        padding-left: 0.85rem;
        padding-right: 0.85rem;
    }

    body.game-page-body .game-topbar {
        grid-template-columns: 1fr;
    }

    body.game-page-body .game-hero-panel {
        flex-direction: column;
    }

    body.game-page-body .game-stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    body.game-page-body .round-filter {
        justify-content: flex-start;
        overflow-x: auto;
    }

    body.game-page-body .game-tabs {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    body.game-page-body .latest-result-card {
        grid-template-columns: auto auto minmax(0, 1fr);
    }

    body.game-page-body .latest-result-card time {
        grid-column: 1 / -1;
    }
}

@media (max-width: 520px) {
    body.game-page-body .game-page {
        padding-left: 0.65rem;
        padding-right: 0.65rem;
    }

    body.game-page-body .game-stats-grid,
    body.game-page-body .validator-controls,
    body.game-page-body .validator-summary-grid {
        grid-template-columns: 1fr;
    }

    body.game-page-body .game-tabs button {
        min-height: 40px;
        padding: 0 0.4rem;
    }

    body.game-page-body .result-chip-grid {
        grid-template-columns: repeat(auto-fill, minmax(26px, 26px));
    }

    body.game-page-body .history-card-grid {
        grid-template-columns: repeat(auto-fill, minmax(44px, 1fr));
    }
}

/* Polimento final da página de jogo */
body.game-page-body {
    background:
        radial-gradient(circle at 0% 0%, rgba(10, 42, 55, 0.7), transparent 34%),
        linear-gradient(90deg, #081620 0%, #080f18 42%, #080b11 100%);
}

body.game-page-body .game-page {
    max-width: 1250px;
    padding: 0.65rem 0.85rem 1.35rem;
}

body.game-page-body .game-topbar {
    min-height: 38px;
    margin-bottom: 1.1rem;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
}

body.game-page-body .game-back {
    width: max-content;
    max-width: 180px;
    min-height: 30px;
    padding: 0.38rem 0.9rem;
    border-radius: 9px;
    font-size: 0.72rem;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

body.game-page-body .game-hero-panel {
    min-height: auto;
    padding: 0.5rem 0;
    align-items: center;
}

body.game-page-body .game-title-block {
    display: block;
    width: auto;
}

body.game-page-body .game-title-block h1 {
    font-size: clamp(1.25rem, 2vw, 1.55rem);
    margin-bottom: 0.25rem;
}

body.game-page-body .game-title-block p,
body.game-page-body .game-live-status {
    font-size: 0.82rem;
}

body.game-page-body .game-stats-grid {
    gap: 0.75rem;
    margin-bottom: 0.85rem;
}

body.game-page-body .game-stat-card {
    border-radius: 11px;
}

body.game-page-body .round-filter {
    margin: 0.75rem 0 1rem;
}

body.game-page-body .game-tabs {
    margin-bottom: 1rem;
    gap: 0.45rem;
}

body.game-page-body .game-tabs button {
    height: 42px;
}

body.game-page-body .pattern-validator-card {
    min-height: auto;
    padding: 1.45rem;
    border-radius: 11px;
}

body.game-page-body .validator-title h2 {
    font-size: 1.05rem;
}

body.game-page-body .validator-title p {
    margin-bottom: 0.9rem;
}

body.game-page-body .validator-layout {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: stretch;
    gap: 1rem;
}

body.game-page-body .validator-pattern-box {
    min-height: 56px;
}

body.game-page-body .validator-token {
    width: 44px;
    height: 36px;
}

body.game-page-body .validator-stats-card {
    min-height: 148px;
}

@media (max-width: 1024px) {
    body.game-page-body .game-page {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    body.game-page-body .game-hero-panel {
        padding-top: 0.75rem;
        padding-bottom: 0.75rem;
    }

    body.game-page-body .game-stat-card {
        min-height: 118px;
    }

    body.game-page-body .validator-layout {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    }
}

@media (max-width: 760px) {
    body.game-page-body .game-page {
        padding: 0.65rem 0.75rem 1.25rem;
    }

    body.game-page-body .game-topbar {
        grid-template-columns: 1fr;
        gap: 0.55rem;
        justify-items: center;
        margin-bottom: 0.75rem;
    }

    body.game-page-body .game-back {
        justify-self: start;
    }

    body.game-page-body .game-hero-panel {
        gap: 0.35rem;
    }

    body.game-page-body .game-stats-grid {
        grid-template-columns: 1fr;
    }

    body.game-page-body .game-stat-card {
        min-height: 88px;
    }

    body.game-page-body .game-tabs {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    body.game-page-body .game-tabs button {
        height: 38px;
        min-height: 38px;
    }

    body.game-page-body .validator-layout {
        grid-template-columns: 1fr;
    }

    body.game-page-body .pattern-validator-card {
        padding: 1rem;
    }
}

/* Correção simples e final do layout interno dos games - camada final */
body.game-page-body .game-page {
    width: min(100%, 1180px);
    max-width: 1180px;
    margin: 0 auto;
    padding: 0.55rem 0.75rem 1rem;
}

body.game-page-body .game-back {
    font-size: 0;
}

body.game-page-body .game-back::after {
    content: "← Jogos";
    font-size: 0.72rem;
}

body.game-page-body .game-title-block > p:not(.game-subtitle-clean) {
    display: none;
}

body.game-page-body .game-subtitle-clean {
    display: block;
}

body.game-page-body .game-live-status {
    font-size: 0;
}

body.game-page-body .game-live-status::before {
    content: "↻ Ao Vivo • ";
    font-size: 0.82rem;
}

body.game-page-body .game-live-status span {
    font-size: 0.82rem;
}

body.game-page-body .game-topbar {
    min-height: 34px;
    margin-bottom: 0.65rem;
}

body.game-page-body .game-hero-panel {
    padding: 0.45rem 0 0.65rem;
    margin: 0;
}

body.game-page-body .game-stats-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.75rem;
    margin: 0 0 0.75rem;
}

body.game-page-body .game-stat-card {
    min-height: 112px;
    padding: 0.95rem 1rem;
}

body.game-page-body .stat-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.9rem;
}

body.game-page-body .stat-values strong {
    display: block;
    font-size: 1.75rem;
    line-height: 1;
}

body.game-page-body .round-filter {
    min-height: 40px;
    margin: 0 0 0.75rem;
}

body.game-page-body .game-tabs {
    margin-bottom: 0.8rem;
}

body.game-page-body .pattern-validator-card,
body.game-page-body .analysis-card {
    border-radius: 10px;
}

body.game-page-body .pattern-validator-card {
    padding: 1rem 1.15rem;
}

body.game-page-body .validator-layout {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

body.game-page-body .validator-pattern-box {
    min-height: 54px;
}

@media (max-width: 900px) {
    body.game-page-body .game-page {
        width: 100%;
        padding: 0.5rem 0.65rem 1rem;
    }

    body.game-page-body .game-stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    body.game-page-body .game-stat-card {
        min-height: 100px;
    }

    body.game-page-body .validator-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 520px) {
    body.game-page-body .game-stats-grid {
        grid-template-columns: 1fr;
    }

    body.game-page-body .game-stat-card {
        min-height: 82px;
    }
}

/* Correção simples e final do layout interno dos games - manter por último */
body.game-page-body .game-page {
    width: min(100%, 1180px);
    max-width: 1180px;
    margin: 0 auto;
    padding: 0.55rem 0.75rem 1rem;
}

body.game-page-body .game-back {
    font-size: 0;
}

body.game-page-body .game-back::after {
    content: "← Jogos";
    font-size: 0.72rem;
}

body.game-page-body .game-title-block > p:not(.game-subtitle-clean) {
    display: none;
}

body.game-page-body .game-subtitle-clean {
    display: block;
}

body.game-page-body .game-live-status {
    font-size: 0;
}

body.game-page-body .game-live-status::before {
    content: "↻ Ao Vivo • ";
    font-size: 0.82rem;
}

body.game-page-body .game-live-status span {
    font-size: 0.82rem;
}

body.game-page-body .game-topbar {
    min-height: 34px;
    margin-bottom: 0.65rem;
}

body.game-page-body .game-hero-panel {
    padding: 0.45rem 0 0.65rem;
    margin: 0;
}

body.game-page-body .game-stats-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.75rem;
    margin: 0 0 0.75rem;
}

body.game-page-body .game-stat-card {
    min-height: 112px;
    padding: 0.95rem 1rem;
}

body.game-page-body .stat-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.9rem;
}

body.game-page-body .stat-values strong {
    display: block;
    font-size: 1.75rem;
    line-height: 1;
}

body.game-page-body .round-filter {
    min-height: 40px;
    margin: 0 0 0.75rem;
}

body.game-page-body .game-tabs {
    margin-bottom: 0.8rem;
}

body.game-page-body .pattern-validator-card,
body.game-page-body .analysis-card {
    border-radius: 10px;
}

body.game-page-body .pattern-validator-card {
    padding: 1rem 1.15rem;
}

body.game-page-body .validator-layout {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

body.game-page-body .validator-pattern-box {
    min-height: 54px;
}

@media (max-width: 900px) {
    body.game-page-body .game-page {
        width: 100%;
        padding: 0.5rem 0.65rem 1rem;
    }

    body.game-page-body .game-stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    body.game-page-body .game-stat-card {
        min-height: 100px;
    }

    body.game-page-body .validator-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 520px) {
    body.game-page-body .game-stats-grid {
        grid-template-columns: 1fr;
    }

    body.game-page-body .game-stat-card {
        min-height: 82px;
    }
}

/* Responsividade geral: camada final para todas as telas */
html,
body {
    width: 100%;
    max-width: 100%;
}

img,
svg,
video,
canvas {
    max-width: 100%;
}

.ui-wrapper,
.game-page,
main,
section,
nav,
.dashboard-grid,
.games-grid,
.game-analysis-grid,
.validator-layout,
.live-history-section {
    min-width: 0;
}

.ui-wrapper {
    padding-left: clamp(0.85rem, 3vw, 2rem);
    padding-right: clamp(0.85rem, 3vw, 2rem);
}

nav {
    gap: 1rem;
}

.hero-content {
    max-width: min(700px, 100%);
}

h1.glitch {
    font-size: clamp(2.15rem, 8vw, 5rem);
}

.subtitle {
    font-size: clamp(0.95rem, 2.2vw, 1.2rem);
}

.stats-container {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr));
}

.dashboard-grid,
#dashboard .games-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
}

.game-card,
.chart-card,
.locked-section,
.lock-overlay,
.modal-content {
    max-width: 100%;
}

.game-logo-frame,
.chart-card canvas {
    max-width: 100%;
}

.results-ticker {
    max-width: 100%;
}

.ticker-game {
    max-width: min(34vw, 220px);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.game-page {
    max-width: min(1250px, 100%);
}

.game-topbar,
.game-hero-panel,
.latest-result-card,
.analysis-card-header {
    min-width: 0;
}

.game-title-block,
.game-live-status {
    min-width: 0;
}

.game-title-block h1,
.game-title-block p,
.game-live-status,
.analysis-card-header h2,
.analysis-card-header span {
    overflow-wrap: anywhere;
}

.game-stats-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
}

.game-analysis-grid {
    grid-template-columns: minmax(0, 1.55fr) minmax(280px, 0.6fr);
}

.validator-layout {
    grid-template-columns: minmax(0, 1fr) minmax(min(100%, 360px), 0.95fr);
}

.history-card-grid {
    grid-template-columns: repeat(auto-fill, minmax(52px, 1fr));
}

@media (max-width: 900px) {
    body {
        padding-bottom: 96px;
    }

    body.game-page-body {
        padding-bottom: 0;
    }

    nav {
        flex-wrap: wrap;
        justify-content: center;
        padding: 1rem 0;
    }

    .nav-links {
        width: 100%;
        display: flex;
        justify-content: center;
    }

    .nav-links a {
        margin-left: 0;
    }

    main {
        min-height: auto;
        padding-top: 1rem;
    }

    .hero-content {
        text-align: center;
    }

    .hero-brand {
        align-items: center;
    }

    .dashboard-section,
    .locked-section {
        padding-top: 2rem;
    }

    .game-page {
        max-width: 100%;
    }

    .game-topbar {
        grid-template-columns: 1fr;
        justify-items: center;
    }

    .game-back {
        justify-self: start;
    }

    .game-hero-panel {
        flex-direction: column;
        gap: 0.45rem;
    }

    .game-live-status {
        align-self: flex-start;
    }

    .game-analysis-grid,
    .validator-layout,
    .distribution-layout {
        grid-template-columns: 1fr;
    }

    .game-tabs {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 560px) {
    .ui-wrapper {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }

    .brand-led {
        justify-content: center;
        flex-wrap: wrap;
        text-align: center;
    }

    .tab-bar {
        width: calc(100% - 0.8rem);
        padding: 6px 6px;
        gap: 0;
    }

    .tab-item {
        min-width: 0;
        padding: 5px 1px;
    }

    .tab-item .icon {
        font-size: 1.05rem;
    }

    .tab-item span {
        max-width: 100%;
        font-size: 0.48rem;
        letter-spacing: 0.4px;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .central-bg {
        width: 46px;
        height: 46px;
    }

    .dashboard-grid,
    #dashboard .games-grid {
        grid-template-columns: 1fr;
        gap: 0.9rem;
    }

    .game-card {
        min-height: auto;
    }

    .game-page {
        padding-left: 0.7rem;
        padding-right: 0.7rem;
    }

    .game-stats-grid {
        grid-template-columns: 1fr;
    }

    .game-tabs {
        gap: 0.35rem;
    }

    .round-filter {
        justify-content: flex-start;
    }

    .latest-result-card {
        grid-template-columns: auto auto minmax(0, 1fr);
    }

    .latest-result-card time {
        grid-column: 1 / -1;
    }

    .validator-actions-row,
    .validator-controls,
    .validator-summary-grid {
        grid-template-columns: 1fr;
    }

    .validator-clear {
        width: 100%;
    }
}

/* Logged-in home should not feel like a blocking splash screen */
body.logged-in main#home {
    min-height: 0 !important;
    padding-top: 0 !important;
    margin: 0 0 0.85rem !important;
}

body.logged-in main#home .hero-content {
    max-width: none !important;
    min-height: 0 !important;
    padding: 0.85rem 1rem !important;
    border: 1px solid rgba(0, 243, 255, 0.1);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.028);
}

body.logged-in main#home .hero-content::before {
    height: calc(100% - 1.2rem);
    top: 0.6rem;
}

body.logged-in main#home .hero-brand {
    display: flex !important;
    grid-column: 1 / -1;
    margin: 0 0 0.25rem !important;
    gap: 0.12rem !important;
}

body.logged-in main#home .hero-main-word {
    line-height: 1;
}

body.logged-in main#home .hero-community {
    font-size: 0.72rem !important;
    letter-spacing: 0.16em !important;
}

body.logged-in main#home .hero-cyber,
body.logged-in main#home .hero-bot {
    font-size: clamp(1.8rem, 3.8vw, 2.85rem) !important;
    letter-spacing: 0.035em !important;
}

body.logged-in main#home .subtitle {
    grid-column: auto !important;
    grid-row: auto !important;
    margin: 0 !important;
    max-width: 68ch !important;
    font-size: 0.95rem !important;
    line-height: 1.45 !important;
}

body.logged-in main#home .session-timer {
    margin-top: 0 !important;
}

@media (min-width: 769px) {
    body.logged-in main#home .hero-content {
        display: grid;
        grid-template-columns: minmax(260px, 0.62fr) minmax(300px, 0.85fr) minmax(360px, 1.15fr);
        gap: 1rem;
        align-items: center;
    }

    body.logged-in main#home .hero-brand {
        grid-column: 1;
        grid-row: 1 / 3;
        margin: 0 !important;
    }

    body.logged-in main#home .subtitle {
        grid-column: 2 !important;
    }

    body.logged-in main#home .session-timer {
        grid-column: 2 !important;
    }

    body.logged-in main#home .command-strip {
        grid-column: 3 !important;
        margin-top: 0;
    }
}

@media (max-width: 768px) {
    body.logged-in main#home .hero-content {
        display: grid !important;
        gap: 0.75rem;
        padding-left: 1rem !important;
    }

    body.logged-in main#home .subtitle {
        text-align: left;
    }
}

/* Absolute final: show compact logo when logged in */
body.logged-in main#home .hero-content h1.hero-brand,
body.logged-in main#home h1.hero-brand {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    grid-column: 1 / -1;
    margin: 0 0 0.25rem !important;
    gap: 0.12rem !important;
}

body.logged-in main#home h1.hero-brand .hero-main-word {
    line-height: 1;
}

body.logged-in main#home h1.hero-brand .hero-community {
    font-size: 0.72rem !important;
    letter-spacing: 0.16em !important;
}

body.logged-in main#home h1.hero-brand .hero-cyber,
body.logged-in main#home h1.hero-brand .hero-bot {
    font-size: clamp(1.8rem, 3.8vw, 2.85rem) !important;
    letter-spacing: 0.035em !important;
}

@media (min-width: 769px) {
    body.logged-in main#home .hero-content {
        grid-template-columns: minmax(260px, 0.62fr) minmax(300px, 0.85fr) minmax(360px, 1.15fr) !important;
    }

    body.logged-in main#home .hero-content h1.hero-brand {
        grid-column: 1 !important;
        grid-row: 1 / 3 !important;
        margin: 0 !important;
    }

    body.logged-in main#home .subtitle,
    body.logged-in main#home .session-timer {
        grid-column: 2 !important;
    }

    body.logged-in main#home .command-strip {
        grid-column: 3 !important;
    }
}

body.logged-out .hero-content {
    max-width: min(1120px, 100%) !important;
}

.quick-access-cards {
    width: min(1180px, 100%);
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1rem;
    margin: 0 auto 1.35rem;
}

.quick-access-card {
    position: relative;
    min-height: 118px;
    display: grid;
    grid-template-columns: 74px minmax(0, 1fr);
    grid-template-rows: auto auto auto;
    align-items: center;
    column-gap: 1rem;
    padding: 1.15rem 1.25rem;
    border-radius: 12px;
    border: 1px solid rgba(0, 243, 255, 0.16);
    color: #ffffff;
    text-align: left;
    text-decoration: none;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.045);
    box-shadow:
        0 18px 42px rgba(0, 0, 0, 0.24),
        inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.quick-access-card::before {
    content: "";
    position: absolute;
    inset: 0;
    opacity: 0.88;
    transition: transform 0.22s ease, opacity 0.22s ease;
}

.quick-access-instagram::before {
    background:
        radial-gradient(circle at 12% 18%, rgba(255, 214, 0, 0.22), transparent 28%),
        linear-gradient(135deg, rgba(255, 0, 122, 0.22), rgba(112, 0, 255, 0.18));
}

.quick-access-support::before {
    background:
        radial-gradient(circle at 12% 18%, rgba(0, 243, 255, 0.2), transparent 30%),
        linear-gradient(135deg, rgba(0, 136, 204, 0.22), rgba(25, 195, 125, 0.12));
}

.quick-access-telegram::before {
    background:
        radial-gradient(circle at 12% 18%, rgba(0, 243, 255, 0.24), transparent 30%),
        linear-gradient(135deg, rgba(29, 167, 223, 0.24), rgba(112, 0, 255, 0.12));
}

.quick-access-youtube::before {
    background:
        radial-gradient(circle at 12% 18%, rgba(255, 255, 255, 0.16), transparent 28%),
        linear-gradient(135deg, rgba(255, 0, 0, 0.24), rgba(120, 0, 0, 0.16));
}

.quick-access-logo {
    position: relative;
    z-index: 1;
    grid-row: 1 / 4;
    width: 74px;
    height: 74px;
    object-fit: contain;
    border-radius: 18px;
    background: transparent;
    box-shadow: 0 0 24px rgba(0, 243, 255, 0.16);
}

.quick-access-support .quick-access-logo {
    border-radius: 16px;
}

.quick-access-support-logo {
    background: rgba(255, 255, 255, 0.9);
    padding: 3px;
}

.quick-access-youtube-logo {
    border-radius: 18px;
    background: transparent;
    padding: 0;
}

.quick-access-card span,
.quick-access-card strong,
.quick-access-card small {
    position: relative;
    z-index: 1;
}

.quick-access-card span {
    align-self: end;
    color: #00f3ff;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 1.4px;
    text-transform: uppercase;
}

.quick-access-card strong {
    max-width: 74%;
    align-self: center;
    font-size: clamp(1rem, 2vw, 1.28rem);
    line-height: 1.1;
}

.quick-access-card small {
    align-self: start;
    color: #9eb4c4;
    font-size: 0.78rem;
    font-weight: 800;
}

.quick-access-card:hover::before {
    opacity: 1;
    transform: scale(1.04);
}

.public-quick-access-cards {
    width: min(1180px, 100%);
    margin: 1.35rem 0 0;
}

.public-quick-access-cards .quick-access-card {
    min-height: 104px;
    grid-template-columns: 62px minmax(0, 1fr);
    padding: 0.95rem 1rem;
}

.public-quick-access-cards .quick-access-logo {
    width: 62px;
    height: 62px;
    border-radius: 15px;
}

.public-quick-access-cards .quick-access-support .quick-access-logo {
    border-radius: 14px;
}

@media (max-width: 980px) {
    .quick-access-cards {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.75rem;
    }
}

@media (max-width: 720px) {
    .quick-access-cards {
        grid-template-columns: 1fr;
    }

    .quick-access-card {
        min-height: 104px;
        grid-template-columns: 64px minmax(0, 1fr);
    }

    .quick-access-card strong {
        max-width: 100%;
    }

    .quick-access-logo {
        width: 64px;
        height: 64px;
        border-radius: 15px;
    }
}

/* Restore compact logged-in logo */
body.logged-in main#home .hero-brand {
    display: flex !important;
    grid-column: 1 / -1;
    margin: 0 0 0.25rem !important;
    gap: 0.12rem !important;
}

body.logged-in main#home .hero-main-word {
    line-height: 1;
}

body.logged-in main#home .hero-community {
    font-size: 0.72rem !important;
    letter-spacing: 0.16em !important;
}

body.logged-in main#home .hero-cyber,
body.logged-in main#home .hero-bot {
    font-size: clamp(1.8rem, 3.8vw, 2.85rem) !important;
    letter-spacing: 0.035em !important;
}

@media (min-width: 769px) {
    body.logged-in main#home .hero-content {
        grid-template-columns: minmax(260px, 0.62fr) minmax(300px, 0.85fr) minmax(360px, 1.15fr) !important;
    }

    body.logged-in main#home .hero-brand {
        grid-column: 1;
        grid-row: 1 / 3;
        margin: 0 !important;
    }

    body.logged-in main#home .subtitle {
        grid-column: 2 !important;
    }

    body.logged-in main#home .session-timer {
        grid-column: 2 !important;
    }

    body.logged-in main#home .command-strip {
        grid-column: 3 !important;
        margin-top: 0;
    }
}

@media (max-width: 360px) {
    h1.glitch {
        font-size: 1.9rem;
    }

    .hero-community {
        letter-spacing: 0.02em;
    }

    .game-tabs button::after {
        font-size: 0.72rem;
    }

    .result-chip-grid {
        grid-template-columns: repeat(auto-fill, minmax(24px, 24px));
    }

    .history-card-grid {
        grid-template-columns: repeat(auto-fill, minmax(40px, 1fr));
    }

    .history-card {
        width: 40px;
        height: 40px;
    }
}

html {
    scroll-behavior: smooth;
    min-height: 100%;
}

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

body {
    background:
        radial-gradient(circle at 18% 0%, rgba(23, 54, 67, 0.55), transparent 36%),
        radial-gradient(circle at 52% 100%, rgba(16, 41, 55, 0.38), transparent 30%),
        linear-gradient(90deg, #081620 0%, #07111a 42%, #070b11 100%);
    background-attachment: fixed;
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    overflow-x: hidden;
    min-height: 100vh;
    padding-bottom: 120px;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
    background-size: 40px 40px;
    opacity: 0.35;
}

#worm-canvas {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    pointer-events: none;
    opacity: 0.72;
    mix-blend-mode: screen;
}

.ui-wrapper {
    position: relative;
    z-index: 10;
    width: 100%;
    padding: 2rem;
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
}

.tab-bar {
    position: fixed;
    bottom: 22px;
    left: 50%;
    transform: translateX(-50%);
    width: min(92vw, 760px);
    background: rgba(11, 17, 33, 0.8);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 50px;
    padding: 10px 36px; /* Aumentado para PC */
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4rem; /* Mais espaço no PC */
    gap: 1.5rem;
    z-index: 10000;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.7);
    transition: all 0.4s ease;
}

.tab-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.3s ease;
    padding: 5px 10px;
    min-width: 60px;
    max-width: 120px;
    text-align: center;
    overflow: visible;
}

.tab-item .icon {
    font-size: 1.8rem; /* Ícones maiores para PC */
    margin-bottom: 6px;
    transition: all 0.3s ease;
}

.tab-item span {
    font-size: 0.75rem; /* Texto legível no PC */
    font-family: 'Orbitron', sans-serif;
    letter-spacing: 2px;
    font-weight: bold;
    white-space: nowrap;
}

.tab-item:hover, .tab-item.active {
    color: var(--accent-color);
}

.tab-item:hover .icon, .tab-item.active .icon {
    transform: translateY(-3px);
    filter: drop-shadow(0 0 8px var(--accent-color));
}

/* Botão Central de Destaque */
.tab-item.central {
    position: relative;
    top: -20px;
    z-index: 1001;
}

.central-bg {
    width: 58px;
    height: 58px;
    background: linear-gradient(45deg, var(--accent-color), #00a8ff);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 25px rgba(0, 243, 255, 0.5);
    border: 4px solid var(--bg-color);
    transition: all 0.3s ease;
}

.central-bg .icon {
    font-size: 1.65rem;
    color: var(--bg-color);
    margin-bottom: 0;
}

.tab-item.central:hover .central-bg {
    transform: scale(1.1);
    box-shadow: 0 0 35px var(--accent-color);
}

.tab-item.central span {
    margin-top: 5px;
    display: block;
}

/* Mobile Menu Button */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
    z-index: 101;
}

.mobile-menu-btn span {
    width: 30px;
    height: 2px;
    background-color: var(--text-primary);
    transition: all 0.3s ease;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem 0;
}

.logo {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 2px;
}

.logo span {
    color: var(--accent-color);
}

.brand-led {
    display: flex;
    align-items: center;
    gap: 0.35rem; /* Ajustado de 0.45rem */
    font-size: 1.3rem;
    font-weight: 800;
}

.brand-community {
    color: #ffffff;
    opacity: 0.85;
    font-size: 0.8rem;
    letter-spacing: 1px;
}

.brand-cyber {
    color: #00f3ff;
    text-shadow: 0 0 10px rgba(0, 243, 255, 0.6),
                 0 0 20px rgba(0, 243, 255, 0.4);
    animation: text-flicker 4s infinite;
}

.brand-bot {
    color: #9f4dff;
    text-shadow: 0 0 10px rgba(159, 77, 255, 0.6);
}

@keyframes text-flicker {
    0%, 100% { opacity: 1; }
    92% { opacity: 1; }
    93% { opacity: 0.8; }
    94% { opacity: 1; }
    95% { opacity: 0.9; }
    96% { opacity: 1; }
}

.nav-links a {
    color: var(--text-primary);
    text-decoration: none;
    margin-left: 2rem;
    font-size: 0.9rem;
    font-weight: 400;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: var(--accent-color);
}

.install-app-btn {
    margin-right: 0.75rem;
    padding: 0.72rem 1.25rem;
    color: var(--text-primary);
    border: 1px solid rgba(0, 243, 255, 0.45);
    border-radius: 999px;
    background: rgba(0, 243, 255, 0.08);
    cursor: pointer;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    transition: all 0.25s ease;
}

.install-app-btn.is-ready,
.install-app-btn:hover {
    color: #061018;
    background: var(--accent-color);
    box-shadow: 0 0 22px rgba(0, 243, 255, 0.32);
}

.btn-glow {
    padding: 0.75rem 1.8rem;
    border: 1px solid var(--accent-color);
    border-radius: 50px; /* Mais arredondado = mais premium */
    background: rgba(0, 243, 255, 0.05);
    box-shadow: 0 0 15px rgba(0, 243, 255, 0.15);
    font-size: 0.75rem;
    font-family: 'Orbitron', sans-serif;
    color: var(--accent-color);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-weight: 700;
    letter-spacing: 1.5px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-glow:hover {
    background: var(--accent-color);
    color: var(--bg-color);
    box-shadow: 0 0 25px var(--accent-color),
                 0 0 50px rgba(0, 243, 255, 0.3);
    transform: translateY(-2px);
}

.btn-glow.is-disabled {
    pointer-events: none;
    opacity: 0.72;
    border-color: rgba(242, 176, 30, 0.38);
    color: #ffd989;
    background: rgba(242, 176, 30, 0.08);
    box-shadow: none;
    transform: none;
}

.dashboard-maintenance-notice {
    display: grid;
    gap: 0.3rem;
    margin: -1rem 0 1.4rem;
    padding: 0.9rem 1rem;
    border-radius: 12px;
    border: 1px solid rgba(242, 176, 30, 0.32);
    background: rgba(242, 176, 30, 0.08);
}

.dashboard-maintenance-notice strong {
    color: #ffe29a;
    font-size: 0.95rem;
}

.dashboard-maintenance-notice span {
    color: rgba(240, 245, 250, 0.88);
    font-size: 0.86rem;
}

.game-card.game-card-unavailable {
    opacity: 0.52;
    filter: grayscale(0.18);
    border-color: rgba(242, 176, 30, 0.26);
}

.game-card.game-card-unavailable .btn-glow {
    pointer-events: none;
}

main {
    min-height: calc(100svh - 110px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4rem;
    transition: min-height 0.5s ease;
}

/* Reduzir hero quando logado para focar no dashboard */
body.logged-in main {
    min-height: auto;
    padding-top: 2rem;
    margin-bottom: 1rem;
    gap: 1.5rem;
}

.hero-content {
    max-width: 700px;
    width: 100%;
}

h1.glitch {
    font-family: 'Orbitron', sans-serif;
    font-size: 5rem;
    line-height: 1;
    margin-bottom: 1.5rem;
    position: relative;
    text-transform: uppercase;
    overflow-wrap: anywhere;
}

.hero-brand {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.16em;
    perspective: 1000px;
}

.hero-brand::before,
.hero-brand::after {
    display: none;
}

.hero-community {
    color: #ffffff;
    display: block;
    font-size: 0.31em;
    line-height: 1.15;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    opacity: 0.9;
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.3);
    margin-bottom: 0;
}

.hero-cyber {
    color: #ffffff;
    display: block;
    line-height: 0.9;
    text-shadow:
        0 0 10px rgba(0, 243, 255, 0.8),
        0 0 25px rgba(0, 243, 255, 0.4),
        0 0 50px rgba(0, 243, 255, 0.2);
    font-weight: 900;
}

.hero-bot {
    color: #00f3ff;
    display: block;
    line-height: 0.9;
    text-shadow:
        0 0 10px rgba(159, 77, 255, 0.8),
        0 0 25px rgba(0, 243, 255, 0.4);
    font-weight: 900;
}

.subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    line-height: 1.6;
    max-width: 62ch;
}

.cta-group {
    display: flex;
    gap: 1.5rem;
}

button {
    padding: 1rem 2rem;
    font-size: 1rem;
    font-family: 'Orbitron', sans-serif;
    cursor: pointer;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.primary-btn {
    background: linear-gradient(45deg, var(--accent-secondary), var(--accent-color));
    color: white;
    border: none;
    box-shadow: 0 4px 20px rgba(112, 0, 255, 0.4);
}

.primary-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 30px rgba(112, 0, 255, 0.6);
}

.secondary-btn {
    background: var(--glass-bg);
    color: white;
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
}

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

.stats-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    max-width: 800px;
}

.stat-card {
    padding: 1.5rem;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
    border-radius: 8px;
    text-align: center;
}

.stat-card h3 {
    font-family: 'Orbitron', sans-serif;
    color: var(--accent-color);
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
}

.stat-card p {
    color: var(--text-secondary);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Glitch Effect */
.glitch::before,
.glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.glitch::before {
    left: 2px;
    text-shadow: -2px 0 var(--accent-secondary);
    clip: rect(44px, 450px, 56px, 0);
    animation: glitch-anim 5s infinite linear alternate-reverse;
    opacity: 0.45;
}

.glitch::after {
    left: -2px;
    text-shadow: -2px 0 var(--accent-color);
    clip: rect(44px, 450px, 56px, 0);
    animation: glitch-anim2 1s infinite linear alternate-reverse;
    opacity: 0.35;
}

@keyframes glitch-anim {
    0% { clip: rect(31px, 9999px, 94px, 0); }
    20% { clip: rect(62px, 9999px, 42px, 0); }
    40% { clip: rect(16px, 9999px, 78px, 0); }
    60% { clip: rect(1px, 9999px, 13px, 0); }
    80% { clip: rect(53px, 9999px, 86px, 0); }
    100% { clip: rect(91px, 9999px, 98px, 0); }
}

@keyframes glitch-anim2 {
    0% { clip: rect(65px, 9999px, 100px, 0); }
    20% { clip: rect(12px, 9999px, 55px, 0); }
    40% { clip: rect(76px, 9999px, 92px, 0); }
    60% { clip: rect(43px, 9999px, 15px, 0); }
    80% { clip: rect(1px, 9999px, 40px, 0); }
    100% { clip: rect(25px, 9999px, 88px, 0); }
}

/* Animations */
.section-title {
    font-family: 'Orbitron', sans-serif;
    font-size: 2.5rem;
    margin-bottom: 3.5rem;
    text-align: center;
    letter-spacing: 2px;
}

.section-title span {
    color: var(--accent-color);
    display: block;
    font-size: 1.2rem;
    margin-top: 0.5rem;
}

.hero-content {
    animation: fadeInUp 1s ease-out;
}

.stats-container {
    animation: fadeInUp 1s ease-out 0.3s backwards;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Dashboard Section */
.dashboard-section {
    padding-top: 2rem;
    padding-bottom: 2rem;
    min-height: auto;
    display: flex;
    flex-direction: column;
    scroll-margin-top: 2rem;
}

.dashboard-grid {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); /* Mais flexível que 400px */
    gap: 1.25rem;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
    width: 100%;
}

.footer {
    margin-top: 6rem;
    padding: 3rem 0 8rem;
    text-align: center;
    border-top: 1px solid var(--glass-border);
    width: 100%;
}

.footer p {
    color: var(--text-secondary);
    font-size: 0.8rem;
    font-family: 'Orbitron', sans-serif;
    letter-spacing: 2px;
    line-height: 1.5;
}

.chart-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(15px);
    border-radius: 12px;
    padding: 1.5rem;
    min-height: 300px; /* Reduzido de 350px para mobile */
    min-width: 0;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.chart-card:hover {
    transform: translateY(-5px);
    border-color: var(--accent-color);
}

.chart-card h4 {
    font-family: 'Orbitron', sans-serif;
    font-size: 1rem;
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
}

.chart-card canvas {
    flex: 1;
    width: 100% !important;
    max-height: 250px;
}

/* Scroll Reveal Effects */
.reveal {
    opacity: 1;
    transform: none;
    transition: none;
    filter: none;
}

.reveal.active {
    opacity: 1;
    transform: none;
    filter: none;
}

.reveal-delayed {
    transition-delay: 0s;
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    z-index: 15;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.scroll-indicator:hover {
    opacity: 1;
}

.mouse {
    width: 26px;
    height: 42px;
    border: 2px solid var(--text-primary);
    border-radius: 15px;
    position: relative;
}

.wheel {
    width: 4px;
    height: 8px;
    background-color: var(--accent-color);
    border-radius: 2px;
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    animation: none;
}

@keyframes scroll-wheel {
    0% { opacity: 1; transform: translateX(-50%) translateY(0); }
    100% { opacity: 0; transform: translateX(-50%) translateY(15px); }
}

.scroll-indicator span {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--text-secondary);
    font-family: 'Orbitron', sans-serif;
}

/* Timer de Sessão */
.session-timer {
    margin-top: 1rem;
    font-family: 'Orbitron', sans-serif;
    color: var(--accent-color);
    font-size: 0.9rem;
    letter-spacing: 1px;
}

#timer {
    font-weight: bold;
    text-shadow: 0 0 10px var(--accent-color);
}

/* Painel Bloqueado */
.locked-section {
    min-height: calc(100svh - 220px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem 0 7rem;
    position: relative;
}

.lock-overlay {
    background: rgba(7, 13, 21, 0.42);
    border: 1px solid rgba(255, 255, 255, 0.13);
    backdrop-filter: blur(10px);
    padding: 4rem 2rem;
    border-radius: 18px;
    text-align: center;
    max-width: 580px;
    width: 100%;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.lock-icon {
    font-size: 5rem; /* Ícone 🔒 gigante */
    margin-bottom: 2rem;
    filter: drop-shadow(0 0 20px var(--accent-secondary));
}

.lock-overlay h3 {
    font-family: 'Orbitron', sans-serif;
    font-size: 2.5rem; /* Título maior */
    margin-bottom: 1.5rem;
}

.lock-overlay p {
    color: var(--text-secondary);
    margin-bottom: 3rem;
    font-size: 1.1rem;
    line-height: 1.6;
}

.lock-icon {
    font-size: 4.4rem;
    margin-bottom: 1.7rem;
}

.lock-overlay h3 {
    font-size: 2.1rem;
    margin-bottom: 1.35rem;
    line-height: 1.2;
}

.lock-overlay p {
    margin: 0 auto 2.4rem;
    font-size: 1rem;
    max-width: 430px;
}

body.logged-out .scroll-indicator {
    display: none;
}

body.logged-in .scroll-indicator {
    display: none;
}

/* Modal de Autenticação */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.48);
    backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
}

.modal-content {
    background: #c7cdd4;
    border: 1px solid #7f8995;
    padding: 28px;
    border-radius: 14px;
    text-align: left;
    width: min(100%, 460px);
    max-width: 100%;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.26);
    color: #000;
}

.loader {
    border: 3px solid rgba(15, 23, 42, 0.12);
    border-top: 3px solid #0ea5e9;
    border-radius: 50%;
    width: 34px;
    height: 34px;
    animation: spin 1s linear infinite;
    margin: 0;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.modal h2 {
    font-family: 'Orbitron', sans-serif;
    margin: 18px 0 10px;
    color: #000;
    font-size: clamp(1.35rem, 4vw, 1.8rem);
    line-height: 1.1;
    letter-spacing: 0;
}

.modal p {
    color: #111827;
    font-size: 0.98rem;
    line-height: 1.5;
    margin: 0;
}

.modal p.small {
    font-size: 0.86rem;
    color: #374151;
    margin-top: 16px;
}

.modal p.small a {
    color: #0369a1;
    font-weight: 700;
    text-decoration: none;
}

.modal p.small a:hover {
    text-decoration: underline;
}

.auth-system-card {
    position: relative;
    overflow: hidden;
}

.auth-system-card::before {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    height: 4px;
    background: linear-gradient(90deg, #0ea5e9, #22c55e);
}

.auth-system-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.auth-system-icon {
    display: grid;
    place-items: center;
    width: 58px;
    height: 58px;
    border-radius: 14px;
    background: #aeb8c3;
    border: 1px solid #7f8995;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55);
}

.auth-system-kicker {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(14, 165, 233, 0.12);
    border: 1px solid rgba(14, 165, 233, 0.28);
    color: #075985;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.auth-system-status {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 18px;
    padding: 12px 14px;
    border-radius: 10px;
    background: #b7c0ca;
    border: 1px solid #8f9aa6;
}

.auth-system-status span {
    width: 9px;
    height: 9px;
    border-radius: 999px;
    background: #22c55e;
    box-shadow: 0 0 0 5px rgba(34, 197, 94, 0.14);
}

.auth-system-status strong {
    color: #000;
    font-size: 0.86rem;
    font-weight: 800;
}

/* Seção de Jogos & Cards */
.game-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(15px);
    border-radius: 20px;
    padding: 2rem;
    position: relative;
    overflow: hidden;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 320px;
    min-width: 0;
}

.game-card:hover {
    transform: translateY(-10px) scale(1.02);
    border-color: var(--accent-color);
    box-shadow: 0 0 30px rgba(0, 243, 255, 0.2);
    background: rgba(0, 243, 255, 0.05);
}

.game-icon {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.5));
}

.game-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: var(--accent-secondary);
    color: white;
    font-size: 0.65rem;
    font-family: 'Orbitron', sans-serif;
    padding: 4px 10px;
    border-radius: 20px;
    font-weight: bold;
    box-shadow: 0 0 10px var(--accent-secondary);
    animation: pulse-neon 2s infinite;
}

/* Estilos Premium para a Página de Jogo */
.game-back {
    display: inline-flex;
    align-items: center;
    gap: 0.8rem;
    color: #ffffff;
    text-decoration: none;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 1px;
    padding: 0.6rem 1.2rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    transition: all 0.3s ease;
    text-transform: uppercase;
}

.game-back:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: var(--accent-color);
    color: var(--accent-color);
    padding-left: 0.9rem; /* Movimento da seta */
    box-shadow: 0 0 20px rgba(0, 243, 255, 0.2);
}

/* Novo Grid de Jogos e Ticker */
.games-grid {
    margin-bottom: 4rem;
}

.game-provider-group {
    margin-bottom: 3rem;
}

.provider-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem;
    margin: 0 0 1.15rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.provider-heading span {
    color: var(--accent-color);
    font-family: 'Orbitron', sans-serif;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.provider-heading h3 {
    margin: 0;
    color: var(--text-primary);
    font-family: 'Orbitron', sans-serif;
    font-size: 1.35rem;
    line-height: 1.2;
    text-align: right;
    text-transform: uppercase;
}

.provider-games-grid {
    margin-bottom: 0;
}

.suggestion-panel {
    display: grid;
    grid-template-columns: minmax(220px, 0.7fr) minmax(280px, 1.3fr);
    gap: 1.25rem;
    align-items: stretch;
    margin: 0 0 3rem;
    padding: 1.25rem;
    border: 1px solid rgba(0, 243, 255, 0.18);
    border-radius: 18px;
    background:
        linear-gradient(135deg, rgba(0, 243, 255, 0.08), rgba(112, 0, 255, 0.06)),
        rgba(6, 13, 22, 0.82);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05), 0 18px 36px rgba(0, 0, 0, 0.22);
}

.suggestion-admin-panel {
    display: grid;
    grid-template-columns: minmax(220px, 0.55fr) minmax(320px, 1.45fr);
    gap: 1.25rem;
    margin: -1.5rem 0 3rem;
    padding: 1.25rem;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 18px;
    background: rgba(6, 13, 22, 0.72);
}

.suggestion-copy {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.suggestion-kicker {
    color: var(--accent-color);
    font-family: 'Orbitron', sans-serif;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
}

.suggestion-copy h3 {
    margin: 0.45rem 0 0.55rem;
    color: var(--text-primary);
    font-family: 'Orbitron', sans-serif;
    font-size: 1.35rem;
    text-transform: uppercase;
}

.suggestion-copy p {
    margin: 0;
    color: var(--text-secondary);
    line-height: 1.5;
}

.suggestion-form {
    display: grid;
    gap: 0.85rem;
}

.suggestion-form textarea,
.suggestion-reply-form textarea {
    width: 100%;
    min-height: 132px;
    resize: vertical;
    padding: 1rem;
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.28);
    outline: none;
}

.suggestion-form textarea:focus,
.suggestion-reply-form textarea:focus {
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(0, 243, 255, 0.12);
}

.suggestion-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.suggestion-status {
    min-height: 1.2rem;
    color: var(--text-secondary);
    font-size: 0.86rem;
}

.suggestion-status.is-success {
    color: #19c37d;
}

.suggestion-status.is-error {
    color: #ff6b6b;
}

.session-user-id {
    display: inline-block;
    margin-left: 0.75rem;
    color: rgba(240, 245, 250, 0.72);
    font-size: 0.88em;
}

.launch-banner {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
    background:
        radial-gradient(circle at 50% 30%, rgba(0, 243, 255, 0.14), transparent 34%),
        rgba(0, 0, 0, 0.68);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.24s ease;
}

.launch-banner.is-visible {
    opacity: 1;
    pointer-events: auto;
}

.launch-banner.is-hidden {
    display: none;
}

.launch-banner-card {
    position: relative;
    width: min(100%, 620px);
    overflow: hidden;
    padding: 1.75rem;
    border: 1px solid rgba(0, 243, 255, 0.34);
    border-radius: 22px;
    background:
        radial-gradient(circle at top left, rgba(0, 243, 255, 0.18), transparent 32%),
        radial-gradient(circle at bottom right, rgba(112, 0, 255, 0.18), transparent 34%),
        linear-gradient(135deg, rgba(10, 24, 36, 0.98), rgba(5, 8, 18, 0.98)),
        rgba(6, 13, 22, 0.96);
    box-shadow:
        0 34px 90px rgba(0, 0, 0, 0.58),
        0 0 42px rgba(0, 243, 255, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.launch-banner-card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    pointer-events: none;
}

.launch-banner-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    margin-bottom: 0.9rem;
    color: #061018;
    border-radius: 16px;
    background: linear-gradient(135deg, #00f3ff, #8afcff);
    font-family: 'Orbitron', sans-serif;
    font-weight: 900;
    box-shadow: 0 0 28px rgba(0, 243, 255, 0.35);
}

.launch-banner-close {
    position: absolute;
    top: 0.85rem;
    right: 0.85rem;
    width: 36px;
    height: 36px;
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.34);
    cursor: pointer;
    font-weight: 800;
}

.launch-banner-kicker {
    color: var(--accent-color);
    font-family: 'Orbitron', sans-serif;
    font-size: 0.76rem;
    font-weight: 700;
    text-transform: uppercase;
}

.launch-banner-card h2 {
    margin: 0.55rem 2rem 0.75rem 0;
    color: var(--text-primary);
    font-family: 'Orbitron', sans-serif;
    font-size: clamp(1.35rem, 3vw, 1.9rem);
    line-height: 1.2;
    text-transform: uppercase;
}

.launch-banner-card p {
    margin: 0 0 1.35rem;
    color: var(--text-secondary);
    line-height: 1.55;
}

.launch-banner-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
}

.launch-banner-actions .btn-glow {
    min-width: 138px;
    text-align: center;
}

.feedback-wall {
    margin: -1.75rem 0 3rem;
}

.feedback-wall-header {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.feedback-wall-header h3 {
    margin: 0;
    color: var(--text-primary);
    font-family: 'Orbitron', sans-serif;
    font-size: 1.2rem;
    text-transform: uppercase;
}

.public-suggestion-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
    gap: 1rem;
}

.public-suggestion-empty,
.public-suggestion-card {
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 14px;
    background: rgba(0, 0, 0, 0.22);
}

.public-suggestion-empty {
    padding: 1rem;
    color: var(--text-secondary);
}

.public-suggestion-card {
    display: grid;
    gap: 0.65rem;
    padding: 1rem;
}

.public-suggestion-card.is-answered {
    border-color: rgba(25, 195, 125, 0.28);
}

.public-suggestion-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.public-suggestion-meta strong {
    color: var(--accent-color);
    font-size: 0.86rem;
}

.public-suggestion-meta span {
    color: var(--text-secondary);
    font-size: 0.78rem;
}

.public-suggestion-card p {
    margin: 0;
    color: var(--text-secondary);
    line-height: 1.45;
    white-space: pre-wrap;
}

.public-suggestion-reply {
    display: grid;
    gap: 0.35rem;
    color: #19c37d;
    line-height: 1.45;
    padding: 0.65rem;
    border-radius: 10px;
    background: rgba(25, 195, 125, 0.08);
    white-space: pre-wrap;
}

.public-suggestion-reply strong {
    color: #7dffbd;
    font-size: 0.78rem;
    text-transform: uppercase;
}

.public-suggestion-reply span {
    color: #d8ffe9;
}

.suggestion-admin-list {
    display: grid;
    gap: 1rem;
    max-height: 620px;
    overflow: auto;
    padding-right: 0.25rem;
}

.suggestion-admin-empty {
    color: var(--text-secondary);
    padding: 1rem;
    border: 1px dashed rgba(255, 255, 255, 0.16);
    border-radius: 12px;
}

.suggestion-admin-card {
    display: grid;
    gap: 0.85rem;
    padding: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 14px;
    background: rgba(0, 0, 0, 0.24);
}

.suggestion-admin-card.is-answered {
    border-color: rgba(25, 195, 125, 0.28);
}

.suggestion-admin-card-header {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
}

.suggestion-admin-title-wrap {
    display: grid;
    gap: 0.25rem;
}

.suggestion-admin-card-header strong {
    color: var(--text-primary);
}

.suggestion-admin-card-header span {
    color: var(--text-secondary);
    font-size: 0.78rem;
    text-align: right;
}

.suggestion-delete-btn {
    align-self: flex-start;
    color: #ff7f8f;
    border: 1px solid rgba(255, 127, 143, 0.45);
    border-radius: 999px;
    background: rgba(255, 60, 80, 0.08);
    cursor: pointer;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.68rem;
    font-weight: 700;
    padding: 0.45rem 0.75rem;
    transition: all 0.2s ease;
}

.suggestion-delete-btn:hover {
    color: #ffffff;
    background: rgba(255, 60, 80, 0.22);
    border-color: rgba(255, 127, 143, 0.85);
}

.suggestion-delete-btn:disabled {
    cursor: wait;
    opacity: 0.65;
}

.suggestion-admin-text,
.suggestion-admin-reply {
    margin: 0;
    color: var(--text-secondary);
    line-height: 1.45;
    white-space: pre-wrap;
}

.suggestion-admin-reply {
    color: #19c37d;
    padding: 0.75rem;
    border-radius: 10px;
    background: rgba(25, 195, 125, 0.08);
}

.suggestion-reply-form {
    display: grid;
    gap: 0.75rem;
}

.suggestion-reply-form textarea {
    min-height: 86px;
}

@media (max-width: 640px) {
    .provider-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.35rem;
    }

    .provider-heading h3 {
        font-size: 1.05rem;
        text-align: left;
    }

    .suggestion-panel {
        grid-template-columns: 1fr;
        padding: 1rem;
    }

    .suggestion-admin-panel {
        grid-template-columns: 1fr;
        padding: 1rem;
    }

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

    .feedback-wall-header {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.35rem;
    }

    .suggestion-admin-card-header {
        flex-direction: column;
        gap: 0.35rem;
    }

    .suggestion-admin-card-header span {
        text-align: left;
    }

    .suggestion-delete-btn {
        width: 100%;
    }
}

.game-logo-frame {
    height: 150px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
}

.game-logo-frame::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, rgba(0, 243, 255, 0.1), transparent);
    pointer-events: none;
}

.game-logo {
    max-width: 100%;
    max-height: 110px;
    object-fit: contain;
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.2));
    transition: transform 0.4s ease;
}

.game-card:hover .game-logo {
    transform: scale(1.1);
}

.results-ticker {
    background: rgba(0, 0, 0, 0.4);
    border-top: 1px solid var(--glass-border);
    border-bottom: 1px solid var(--glass-border);
    padding: 0.75rem 0;
    margin: 2rem 0;
    overflow: hidden;
    white-space: nowrap;
    position: relative;
    mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
}

.ticker-track {
    display: inline-flex;
    animation: ticker-roll 30s linear infinite;
    gap: 3rem;
}

.ticker-item {
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    color: #fff;
    text-decoration: none;
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.ticker-game {
    color: var(--accent-color);
    font-weight: bold;
}

@keyframes ticker-roll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.game-card p {
    color: var(--text-secondary);
    font-size: 0.85rem;
    margin-bottom: 1.25rem;
    line-height: 1.4;
}

.section-header {
    text-align: center;
}

.section-subtitle {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.6;
    margin: -2rem auto 3rem;
    max-width: 620px;
}

#dashboard .games-grid {
    display: none;
}

#dashboard .game-provider-group {
    display: none;
}

.games-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
}

.course-section {
    margin: 0 0 2rem;
}

.course-card {
    position: relative;
    overflow: hidden;
    padding: 1.4rem;
    border-radius: 22px;
    border: 1px solid rgba(0, 243, 255, 0.18);
    background:
        radial-gradient(circle at top right, rgba(0, 243, 255, 0.08), transparent 28%),
        radial-gradient(circle at bottom left, rgba(36, 119, 255, 0.08), transparent 34%),
        rgba(6, 13, 22, 0.78);
    backdrop-filter: blur(14px);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.05),
        0 18px 32px rgba(0, 0, 0, 0.22);
}

.course-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, rgba(255, 255, 255, 0.02), transparent 35%, transparent 68%, rgba(255, 255, 255, 0.015));
    pointer-events: none;
}

.tab-item-youtube .icon {
    color: transparent !important;
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.tab-item-youtube .icon::before {
    content: '▶';
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.55rem;
    min-height: 1.15rem;
    padding: 0 0.2rem;
    border-radius: 0.5rem;
    background: linear-gradient(180deg, #ff4d5f, #c40020);
    color: #fff;
    box-shadow: 0 0 16px rgba(255, 45, 85, 0.26);
    font-style: normal;
    font-size: 0.72rem;
    line-height: 1;
}

.tab-item-youtube:hover .youtube-icon::before,
.tab-item-youtube.active .youtube-icon::before {
    background: linear-gradient(180deg, #ff6574, #de1638);
    box-shadow: 0 0 22px rgba(255, 64, 101, 0.34);
}

.tab-item-youtube .icon::before {
    content: '▶' !important;
}

.tab-item-youtube:hover .icon::before,
.tab-item-youtube.active .icon::before {
    background: linear-gradient(180deg, #ff6574, #de1638);
    box-shadow: 0 0 22px rgba(255, 64, 101, 0.34);
}

.course-copy,
.course-video-shell {
    position: relative;
    z-index: 1;
}

.course-copy {
    text-align: center;
    margin-bottom: 1rem;
}

.course-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 32px;
    padding: 0 0.9rem;
    margin-bottom: 0.75rem;
    border-radius: 999px;
    border: 1px solid rgba(0, 243, 255, 0.2);
    background: rgba(0, 243, 255, 0.08);
    color: var(--accent-color);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.12em;
}

.course-copy h3 {
    margin: 0 0 0.45rem;
    color: var(--text-primary);
    font-family: 'Orbitron', sans-serif;
    font-size: clamp(1.2rem, 2vw, 1.6rem);
}

.course-copy p {
    margin: 0 auto;
    max-width: 720px;
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
}

.course-video-shell {
    border-radius: 18px;
    padding: 0.8rem;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.course-video-frame {
    position: relative;
    width: 100%;
    padding-top: 56.25%;
    overflow: hidden;
    border-radius: 14px;
    background: #050b12;
    box-shadow: inset 0 0 0 1px rgba(0, 243, 255, 0.08);
}

.course-video-frame iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.game-logo-frame {
    width: 100%;
    height: 150px;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.18);
}

.game-logo {
    display: block;
    max-width: 86%;
    max-height: 120px;
    object-fit: contain;
    filter: drop-shadow(0 14px 24px rgba(0, 0, 0, 0.55));
}

.game-logo-wide {
    max-width: 95%;
}

.game-logo-cover {
    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;
    object-fit: cover;
}

.game-logo-fallback {
    border: 1px solid rgba(0, 243, 255, 0.22);
    box-shadow: inset 0 0 22px rgba(0, 243, 255, 0.08);
}

.game-logo-fallback span {
    color: var(--accent-color);
    font-family: 'Orbitron', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-align: center;
}

.results-ticker {
    width: 100%;
    margin: 1.25rem 0 0;
    overflow: hidden;
    border-radius: 12px;
    border: 1px solid rgba(0, 243, 255, 0.18);
    background: rgba(6, 13, 22, 0.72);
    backdrop-filter: blur(14px);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.ticker-track {
    width: max-content;
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.55rem 0.65rem;
    animation: ticker-scroll 38s linear infinite;
}

.results-ticker:hover .ticker-track {
    animation-play-state: paused;
}

.ticker-item {
    min-width: max-content;
    height: 34px;
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0 0.85rem;
    border-radius: 999px;
    color: #ffffff;
    text-decoration: none;
    background: rgba(255, 255, 255, 0.055);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.ticker-game {
    color: #8fa7b8;
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
}

.ticker-item strong {
    color: #00f3ff;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.8rem;
}

.ticker-item em {
    min-width: 28px;
    height: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 7px;
    background: rgba(0, 243, 255, 0.12);
    color: #ffffff;
    font-style: normal;
    font-weight: 900;
    box-shadow: 0 0 14px rgba(0, 243, 255, 0.2);
}

@keyframes ticker-scroll {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(-50%);
    }
}

.game-card[data-game] {
    cursor: pointer;
}

.game-page-body {
    padding-bottom: 0;
    overflow-x: hidden;
}

.game-tabs button:focus {
    outline: none !important;
}

.game-page {
    position: relative;
    z-index: 10;
    width: 100%;
    max-width: 1250px;
    min-height: 100svh;
    margin: 0 auto;
    padding: 0.45rem clamp(0.85rem, 1.6vw, 1.35rem) 1.1rem;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

.game-topbar {
    min-height: 34px;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.game-back {
    color: var(--text-secondary);
    font-family: 'Orbitron', sans-serif;
    font-size: 0.8rem;
    text-decoration: none;
}

.game-live-center {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.live-pill,
.clock-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    height: 24px;
    padding: 0 0.65rem;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #ffffff;
    font-weight: 700;
    font-size: 0.8rem;
}

.live-pill {
    color: #26ffc0;
    background: rgba(38, 255, 192, 0.1);
    border-color: rgba(38, 255, 192, 0.18);
}

.live-pill span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #0ee39c;
    box-shadow: 0 0 12px rgba(14, 227, 156, 0.8);
}

body.game-page-body .game-live-status {
    display: none !important;
}

.game-hero-panel {
    min-height: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.75rem 0;
}

.game-title-block {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
    min-width: 0;
    width: min(100%, 560px);
}

.game-page-logo-frame {
    width: 170px;
    height: 68px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.game-page-logo {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.game-title-block h1 {
    margin: 0 0 0.25rem;
    font-size: clamp(1rem, 1.35vw, 1.45rem);
    line-height: 1.1;
    color: #ffffff;
    overflow-wrap: anywhere;
}

.game-title-block p,
.game-live-status {
    color: #91a4b2;
    font-size: 0.82rem;
}

.game-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.85rem;
    margin-bottom: 1.25rem;
}

.game-stat-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.stat-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.stat-icon {
    width: 28px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    border-radius: 6px;
    background: #16bdf2;
    color: #ffffff;
    font-weight: 800;
    font-size: 0.9rem;
}

.game-stat-card span {
    display: block;
    color: #91a4b2;
    font-weight: 600;
    font-size: 0.9rem;
}

.stat-values {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.game-stat-card strong {
    display: block;
    color: #1fc6ff;
    font-size: 1.85rem;
    line-height: 1;
    font-weight: 700;
}

.game-stat-card small {
    display: block;
    color: #91a4b2;
    font-weight: 600;
    font-size: 0.75rem;
}

.round-filter {
    min-height: 36px;
    margin: 0.5rem 0 0.7rem;
    padding: 0.35rem 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.06);
    overflow-x: auto;
    scrollbar-width: thin;
}

.round-filter span {
    color: #91a4b2;
    font-weight: 600;
    font-size: 0.8rem;
    flex: 0 0 auto;
    margin-right: 0.5rem;
}

.round-filter a {
    flex: 0 0 auto;
    min-width: 42px;
    padding: 0.25rem 0.6rem;
    border-radius: 999px;
    color: #8293a0;
    text-decoration: none;
    text-align: center;
    font-weight: 700;
    font-size: 0.8rem;
}

.round-filter a.active {
    color: #00131a;
    background: #22c7ff;
}

.game-tabs {
    display: flex;
    justify-content: space-between;
    gap: 0;
    margin-bottom: 1rem;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    padding: 0.35rem;
}

.game-tabs button[data-tab="ai"] {
    display: none;
}

.game-tabs button[data-tab="overview"],
.game-tabs button[data-tab="validator"],
.game-tabs button[data-tab="rooms"] {
    font-size: 0.85rem;
}

.game-tabs button {
    flex: 1;
    height: 36px;
    padding: 0 1rem;
    border-radius: 10px;
    border: 1px solid transparent;
    background: transparent;
    color: #91a4b2;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 0.85rem;
    white-space: nowrap;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: all 0.3s ease;
    cursor: pointer;
}

.game-tabs button.active {
    color: #ffffff;
    border-color: #1fc6ff;
    background: rgba(31, 198, 255, 0.1);
    box-shadow: 0 0 15px rgba(31, 198, 255, 0.15);
}

.tab-panel.hidden {
    display: none !important;
}

.game-analysis-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.65fr) minmax(300px, 0.55fr);
    gap: 1rem;
    flex: 1 1 auto;
    width: 100%;
    min-width: 0;
}

.analysis-card {
    min-height: 250px;
    padding: 1.1rem;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.055);
    border: 1px solid rgba(255, 255, 255, 0.06);
    min-width: 0;
}

.results-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

#result-chip-area {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    max-height: clamp(180px, 42vh, 520px);
    overflow: hidden;
}

.analysis-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.analysis-card-header h2 {
    color: #ffffff;
    font-size: 1rem;
    margin: 0;
}

.analysis-card-header span {
    color: #91a4b2;
    font-size: 0.85rem;
}

.result-chip-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(22px, 22px));
    grid-auto-flow: row;
    gap: 3px;
    width: 100%;
    max-width: 100%;
    margin-top: auto;
    align-content: start;
    justify-content: start;
    overflow-x: hidden;
    overflow-y: auto;
    padding: 0.25rem 0.25rem 0.55rem;
    scrollbar-color: rgba(0, 243, 255, 0.55) rgba(255, 255, 255, 0.08);
    scrollbar-width: thin;
}

.result-chip-grid::-webkit-scrollbar {
    width: 6px;
}

.result-chip-grid::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.04);
    border-radius: 999px;
}

.result-chip-grid::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 999px;
}

.result-chip {
    height: 100%;
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #ffffff;
    font-size: 0.65rem;
    font-weight: 700;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.result-B { background: var(--game-color-B, #c62828); color: var(--game-text-B, #ffffff); }
.result-J { background: var(--game-color-J, #1265d8); color: var(--game-text-J, #ffffff); }
.result-D { background: var(--game-color-D, #c62828); color: var(--game-text-D, #ffffff); }
.result-T { background: var(--game-color-T, #f2b01e); color: var(--game-text-T, #221600); }
.result-E { background: var(--game-color-E, #f2b01e); color: var(--game-text-E, #221600); }
.result-G { background: var(--game-color-G, #19c37d); color: var(--game-text-G, #ffffff); }
.result-Y { background: var(--game-color-Y, #f2b01e); color: var(--game-text-Y, #221600); }
.result-O { background: var(--game-color-O, #18b7ea); color: var(--game-text-O, #ffffff); }

.result-text-B { color: var(--game-color-B, #c62828); }
.result-text-J { color: var(--game-color-J, #1265d8); }
.result-text-D { color: var(--game-color-D, #c62828); }
.result-text-T { color: var(--game-color-T, #f2b01e); }
.result-text-E { color: var(--game-color-E, #f2b01e); }
.result-text-G { color: var(--game-color-G, #19c37d); }
.result-text-Y { color: var(--game-color-Y, #f2b01e); }
.result-text-O { color: var(--game-color-O, #18b7ea); }

.result-dot {
    display: inline-block;
    flex: 0 0 auto;
}

.result-chip.current-result {
    position: relative;
    z-index: 2;
    outline: 2px solid #ffffff;
    outline-offset: 2px;
    box-shadow:
        0 0 0 3px rgba(0, 243, 255, 0.2),
        0 0 14px rgba(0, 243, 255, 0.9),
        0 0 28px rgba(159, 77, 255, 0.6);
    animation: current-result-pulse 1.4s ease-in-out infinite;
}

@keyframes current-result-pulse {
    0%, 100% {
        transform: scale(1);
        filter: brightness(1);
    }
    50% {
        transform: scale(1.12);
        filter: brightness(1.25);
    }
}

.result-legend {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 1rem;
}

.result-legend span,
.distribution-list span {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #91a4b2;
    font-size: 0.85rem;
}

.result-legend i,
.distribution-list i {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.distribution-layout {
    display: grid;
    grid-template-columns: minmax(110px, 140px) minmax(0, 1fr);
    gap: 1rem;
    align-items: center;
    min-height: 178px;
    padding: 0.5rem 0.35rem 0.25rem;
}

.donut-chart {
    width: clamp(110px, 8vw, 132px);
    height: clamp(110px, 8vw, 132px);
    margin: 0 auto;
    border-radius: 50%;
    background:
        conic-gradient(
            #c62828 0 calc(var(--b) * 1%),
            #1265d8 calc(var(--b) * 1%) calc((var(--b) + var(--j)) * 1%),
            #f2b01e calc((var(--b) + var(--j)) * 1%) calc((var(--b) + var(--j) + var(--e)) * 1%),
            #18b7ea 0
        );
    position: relative;
    box-shadow:
        0 0 24px rgba(0, 243, 255, 0.12),
        0 0 34px rgba(18, 101, 216, 0.16);
}

.donut-chart::after {
    content: "";
    position: absolute;
    inset: 34%;
    border-radius: 50%;
    background: #101722;
    box-shadow: inset 0 0 18px rgba(0, 0, 0, 0.5);
}

.distribution-list {
    display: grid;
    gap: 0.7rem;
    align-content: center;
    width: 100%;
}

.distribution-list div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.25rem;
    min-height: 34px;
    padding: 0.42rem 0.6rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.035);
    border: 1px solid rgba(255, 255, 255, 0.045);
}

.distribution-list strong {
    color: #ffffff;
    font-size: 0.88rem;
    min-width: 52px;
    text-align: right;
}

.distribution-list span {
    font-size: 0.82rem;
    font-weight: 800;
}

.distribution-list i {
    width: 11px;
    height: 11px;
}

.empty-results {
    min-height: 150px;
    display: grid;
    place-content: center;
    gap: 0.4rem;
    text-align: center;
    color: #91a4b2;
}

.empty-results strong {
    color: #ffffff;
}

.pattern-validator-panel {
    width: 100%;
}

.pattern-validator-card {
    min-height: 255px;
}

.validator-title h2 {
    margin: 0 0 0.4rem;
    color: #ffffff;
    font-size: 1.05rem;
}

.validator-title p {
    margin: 0 0 0.9rem;
    color: #91a4b2;
    font-size: 0.86rem;
}

.validator-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(360px, 0.95fr);
    gap: 1rem;
}

.validator-builder,
.validator-stats-card {
    min-width: 0;
}

.validator-builder > strong {
    display: block;
    margin-bottom: 0.45rem;
    color: #91a4b2;
}

.validator-pattern-box {
    min-height: 56px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.45rem;
    padding: 0.65rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.045);
    overflow-x: auto;
}

.validator-placeholder {
    color: #91a4b2;
}

.validator-pattern-chip,
.validator-pattern-plain {
    flex: 0 0 auto;
}

.validator-pattern-chip {
    width: 40px;
    height: 40px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-weight: 900;
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.16), 0 8px 18px rgba(0, 0, 0, 0.18);
}

.validator-pattern-chip.token-B { background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-B, #c62828) 58%, white), var(--game-color-B, #c62828) 68%); color: var(--game-text-B, #ffffff); }
.validator-pattern-chip.token-J { background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-J, #1265d8) 58%, white), var(--game-color-J, #1265d8) 68%); color: var(--game-text-J, #ffffff); }
.validator-pattern-chip.token-E { background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-E, #19c37d) 58%, white), var(--game-color-E, #19c37d) 68%); color: var(--game-text-E, #ffffff); }
.validator-pattern-chip.token-G { background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-G, #129f66) 58%, white), var(--game-color-G, #129f66) 68%); color: var(--game-text-G, #ffffff); }
.validator-pattern-chip.token-Y { background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-Y, #d8a512) 58%, white), var(--game-color-Y, #d8a512) 68%); color: var(--game-text-Y, #221600); }
.validator-pattern-chip.token-O { background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-O, #0097b8) 58%, white), var(--game-color-O, #0097b8) 68%); color: var(--game-text-O, #ffffff); }
.validator-pattern-chip.token-A { background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-A, #1265d8) 58%, white), var(--game-color-A, #1265d8) 68%); color: var(--game-text-A, #ffffff); }
.validator-pattern-chip.token-C { background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-C, #19c37d) 58%, white), var(--game-color-C, #19c37d) 68%); color: var(--game-text-C, #ffffff); }
.validator-pattern-chip.token-D { background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-D, #c62828) 58%, white), var(--game-color-D, #c62828) 68%); color: var(--game-text-D, #ffffff); }
.validator-pattern-chip.token-T { background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-T, #f2b01e) 58%, white), var(--game-color-T, #f2b01e) 68%); color: var(--game-text-T, #221600); }
.validator-pattern-chip.token-S { background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-S, #19c37d) 58%, white), var(--game-color-S, #19c37d) 68%); color: var(--game-text-S, #ffffff); }

.validator-pattern-chip-number {
    font-size: 0.88rem;
    line-height: 1;
    letter-spacing: -0.03em;
}

.validator-pattern-chip-core {
    width: 10px;
    height: 10px;
}

.validator-pattern-plain {
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at 30% 30%, #ffffff, #dbe7f1 72%);
    border: 1px solid rgba(255, 255, 255, 0.7);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4), 0 8px 18px rgba(0, 0, 0, 0.18);
    color: #0b1118;
    font-size: 0.82rem;
    font-weight: 900;
    letter-spacing: -0.03em;
}

.validator-count {
    margin: 0.35rem 0 0.7rem;
    color: #91a4b2;
    text-align: right;
    font-size: 0.82rem;
}

.validator-actions-row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 0.65rem;
    align-items: start;
}

.validator-palette {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.validator-token {
    width: 44px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 9px;
    color: #ffffff;
    font-weight: 900;
}

.token-B { background: var(--game-color-B, #c62828); color: var(--game-text-B, #ffffff); }
.token-J { background: var(--game-color-J, #1265d8); color: var(--game-text-J, #ffffff); }
.token-E { background: var(--game-color-E, #19c37d); color: var(--game-text-E, #ffffff); }
.token-C { background: var(--game-color-C, #19c37d); color: var(--game-text-C, #ffffff); }
.token-A { background: var(--game-color-A, #1265d8); color: var(--game-text-A, #ffffff); }
.token-D { background: var(--game-color-D, #c62828); color: var(--game-text-D, #ffffff); }
.token-T,
.token-Y { background: var(--game-color-Y, #f2b01e); color: var(--game-text-Y, #221600); }
.token-number { background: #f2a40d; color: #ffffff; }

.validator-clear {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.04);
    color: #ffffff;
}

.validator-builder > small {
    display: block;
    margin: 0.55rem 0 0.9rem;
    color: #91a4b2;
    font-size: 0.75rem;
}

.validator-controls {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.validator-controls > div {
    min-height: 72px;
    padding: 0.7rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
}

.validator-controls span {
    display: block;
    margin-bottom: 0.55rem;
    color: #91a4b2;
    font-size: 0.82rem;
}

.validator-stepper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.validator-stepper button {
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.06);
    color: #ffffff;
    font-size: 1.2rem;
}

.validator-stepper strong {
    color: #ffffff;
    font-size: 1.25rem;
}

.validator-controls select {
    width: 100%;
    height: 36px;
    border: 0;
    border-radius: 9px;
    background: rgba(255, 255, 255, 0.06);
    color: #ffffff;
    padding: 0 0.7rem;
}

.validator-stats-card {
    padding: 0.85rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
}

.validator-stats-card h3 {
    margin: 0 0 0.75rem;
    color: #ffffff;
    font-size: 1rem;
}

.validator-analyzing {
    min-height: 30px;
    display: flex;
    align-items: center;
    padding: 0 0.75rem;
    margin-bottom: 0.8rem;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.035);
    color: #91a4b2;
    font-size: 0.82rem;
}

.validator-rate-row {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.45rem;
    font-size: 0.82rem;
    font-weight: 800;
}

.validator-rate-row .wins { color: #22c55e; }
.validator-rate-row .losses { color: #ef4444; }

.validator-bar {
    height: 10px;
    margin-bottom: 0.75rem;
    border-radius: 999px;
    overflow: hidden;
    background: rgba(239, 68, 68, 0.22);
}

.validator-bar span {
    display: block;
    height: 100%;
    width: var(--win-rate, 0%);
    background: linear-gradient(90deg, #22c55e, #facc15);
}

.validator-summary-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.validator-summary-grid div {
    min-height: 54px;
    display: grid;
    place-content: center;
    gap: 0.2rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
    text-align: center;
}

.validator-summary-grid b {
    color: #ffffff;
    font-size: 1.1rem;
}

.validator-summary-grid small {
    color: #91a4b2;
}

.validator-gale-lines {
    display: grid;
    gap: 0.35rem;
}

.validator-gale-lines div {
    display: flex;
    justify-content: space-between;
    color: #91a4b2;
    font-size: 0.82rem;
}

@media (min-width: 1400px) {
    .game-page {
        width: 100%;
        max-width: 1250px;
        padding-left: 1.35rem;
        padding-right: 1.35rem;
    }

    .game-stats-grid {
        gap: 1.25rem;
    }

    .game-analysis-grid {
        grid-template-columns: minmax(0, 1.75fr) minmax(320px, 0.5fr);
        gap: 1.25rem;
    }

    .analysis-card {
        min-height: 255px;
    }

    .result-chip-grid {
        grid-template-columns: repeat(auto-fill, minmax(24px, 24px));
        gap: 4px;
    }

    .history-card-grid {
        grid-template-columns: repeat(auto-fill, minmax(66px, 1fr));
        gap: 1.15rem 0.65rem;
    }
}

@media (min-width: 1200px) and (min-height: 850px) {
    .game-hero-panel {
        min-height: 78px;
    }

    .game-stat-card {
        min-height: 96px;
    }

    .analysis-card {
        min-height: 265px;
    }

    .live-history-section {
        min-height: 360px;
    }
}

@media (min-width: 1600px) and (min-height: 900px) {
    .game-page {
        padding-bottom: 1.25rem;
        padding-left: 1.35rem;
        padding-right: 1.35rem;
    }

    .analysis-card {
        min-height: 275px;
    }

    .live-history-section {
        min-height: 410px;
    }

    .history-card {
        width: 64px;
        height: 60px;
    }
}

@media (max-width: 1180px) {
    .game-page {
        padding-left: clamp(0.85rem, 2.4vw, 1.5rem);
        padding-right: clamp(0.85rem, 2.4vw, 1.5rem);
    }

    .game-analysis-grid {
        grid-template-columns: 1fr;
    }

    .validator-layout {
        grid-template-columns: 1fr;
    }

    .analysis-card {
        min-height: auto;
    }

    .result-chip-grid {
        grid-template-columns: repeat(auto-fill, minmax(30px, 30px));
    }

    .distribution-layout {
        grid-template-columns: minmax(108px, 132px) minmax(0, 1fr);
        min-height: 170px;
    }
}

@media (max-width: 940px) {
    .game-tabs {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .game-tabs button {
        font-size: 0.78rem;
        padding: 0 0.7rem;
    }

    .game-hero-panel {
        align-items: flex-start;
    }

    .game-live-status {
        flex: 0 0 auto;
        white-space: nowrap;
    }
}

.live-history-section {
    margin-top: 1.25rem;
    padding: 1.25rem;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.045);
    border: 1px solid rgba(255, 255, 255, 0.06);
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    width: 100%;
}

.live-history-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.history-icon {
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: #1cbcff;
    color: #ffffff;
    font-size: 1.4rem;
    box-shadow: 0 0 20px rgba(28, 188, 255, 0.25);
}

.live-history-title h2 {
    margin: 0;
    color: #ffffff;
    font-size: 1.25rem;
}

.live-history-title span {
    display: block;
    margin-top: 0.15rem;
    color: #91a4b2;
    font-size: 0.85rem;
}

.history-meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.15rem;
}

.history-meta span {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 0.8rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.055);
    color: #d9e5ee;
    font-size: 0.8rem;
    font-weight: 800;
}

.latest-result-card {
    min-height: 78px;
    margin-bottom: 1.35rem;
    padding: 0.75rem 0.8rem;
    display: grid;
    grid-template-columns: auto auto 1fr auto;
    align-items: center;
    gap: 0.85rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
}

.latest-result-card > span {
    color: #91a4b2;
}

.latest-result-card em {
    font-style: normal;
    font-weight: 800;
}

.latest-result-card time {
    color: #91a4b2;
    font-size: 0.8rem;
}

.history-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(62px, 1fr));
    gap: 1.1rem 0.55rem;
    align-content: start;
    flex: 1 1 auto;
}

.history-card-wrap {
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
}

.history-card {
    width: 58px;
    height: 55px;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    color: #ffffff;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.history-card strong,
.history-card b {
    display: block;
    font-size: 1rem;
    line-height: 1;
}

.history-card span,
.history-card small {
    display: block;
    margin-top: 0.2rem;
    color: currentColor;
    font-size: 0.72rem;
    line-height: 1;
}

.history-card-wrap time {
    color: #81929e;
    font-size: 0.64rem;
    line-height: 1;
}

.history-card-wrap small {
    min-height: 13px;
    padding: 0 0.28rem;
    border-radius: 4px;
    background: rgba(242, 176, 30, 0.34);
    color: #f2b01e;
    font-size: 0.55rem;
    font-weight: 800;
}

.history-empty {
    min-height: 180px;
}

@keyframes pulse-neon {
    0% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.7; transform: scale(1.05); }
    100% { opacity: 1; transform: scale(1); }
}

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

    nav {
        justify-content: center;
        padding: 1rem 0;
    }

    .tab-bar {
        width: 95%; /* Um pouco mais largo para caber 5 itens */
        max-width: 450px;
        padding: 5px 10px;
        bottom: 15px;
        left: 50% !important;
        transform: translateX(-50%) !important;
        justify-content: space-around;
        border-radius: 30px;
        gap: 0;
    }
    
    .tab-item {
        flex: 1;
        min-width: 0;
        padding: 5px 2px;
    }
    
    .tab-item span {
        font-size: 0.5rem;
        transform: scale(0.9);
        display: block;
    }

    .tab-item .icon {
        font-size: 1.2rem;
    }

    .central-bg {
        width: 55px;
        height: 55px;
        border-width: 3px;
    }

    .central-bg .icon {
        font-size: 1.5rem;
    }

    .dashboard-grid {
        grid-template-columns: 1fr;
        padding-bottom: 80px;
        gap: 1rem;
    }
    
    .hero-content {
        text-align: center;
        padding: 1rem;
    }
    
    /* Hero ainda menor no mobile quando logado */
    body.logged-in main {
        min-height: auto;
        padding-top: 1.5rem;
        gap: 1rem;
    }

    h1.glitch {
        font-size: 2.2rem;
        margin-bottom: 1rem;
    }

    .subtitle {
        font-size: 1rem;
        margin-bottom: 2rem;
    }

    .section-title {
        font-size: 1.8rem;
        margin-bottom: 2rem;
    }

    .dashboard-section {
        padding-top: 1.5rem;
    }

    .lock-overlay {
        padding: 2rem 1rem;
        margin: 1rem;
    }
}

@media (max-width: 1024px) {
    body {
        background-attachment: scroll;
        background-position: center top;
    }

    .ui-wrapper {
        padding: 1.5rem;
    }

    .tab-bar {
        width: calc(100% - 3rem);
        gap: 0.75rem;
        padding: 10px 22px;
    }

    h1.glitch {
        font-size: 3.8rem;
    }

    .hero-community {
        font-size: 0.42em;
    }

    .dashboard-grid {
        gap: 1.5rem;
    }

    .footer {
        margin-top: 4rem;
    }
}

@media (max-width: 768px) {
    body {
        padding-bottom: 105px;
    }

    .ui-wrapper {
        padding: 1rem;
    }

    nav {
        justify-content: center;
        padding: 1rem 0;
    }

    .tab-bar {
        width: calc(100% - 1rem);
        max-width: 450px;
        padding: 6px 8px;
        bottom: 10px;
        border-radius: 28px;
        gap: 0;
    }

    .tab-item {
        max-width: none;
        padding: 5px 1px;
    }

    .tab-item span {
        letter-spacing: 0.5px;
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
        transform: none;
    }

    .central-bg {
        width: 52px;
        height: 52px;
    }

    main {
        min-height: calc(100svh - 80px);
        gap: 2rem;
        justify-content: center;
    }

    .hero-content {
        padding: 0.5rem 0;
        margin: 0 auto;
    }

    h1.glitch {
        font-size: 2.6rem;
    }

    .hero-brand {
        justify-content: center;
        gap: 0.12em;
    }

    .hero-community {
        font-size: 0.4em;
        letter-spacing: 0.08em;
    }

    .subtitle {
        max-width: 100%;
    }

    .section-title {
        line-height: 1.25;
        overflow-wrap: anywhere;
    }

    .section-title span {
        font-size: 1rem;
    }

    .dashboard-section {
        min-height: auto;
    }

    .dashboard-grid {
        padding-bottom: 80px;
    }

    .results-ticker {
        margin-top: 1rem;
    }

    .ticker-track {
        animation-duration: 28s;
    }

    .ticker-item {
        height: 32px;
        padding: 0 0.65rem;
    }

    .ticker-game {
        max-width: 130px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .chart-card {
        min-height: 260px;
        padding: 1.25rem;
    }

    .chart-card canvas {
        max-height: 210px;
    }

    .game-card {
        min-height: 260px;
        padding: 1.5rem 1rem;
    }

    .game-logo-frame {
        height: 130px;
        margin-bottom: 1.25rem;
    }

    .game-logo {
        max-height: 105px;
    }

    .game-icon {
        font-size: 3rem;
        margin-bottom: 1rem;
    }

    .footer {
        margin-top: 2rem;
        padding: 2rem 0 1rem;
    }

    .lock-overlay {
        margin: 0;
        border-radius: 20px;
        max-width: 100%;
    }

    .lock-icon {
        font-size: 3.5rem;
        margin-bottom: 1.25rem;
    }

    .lock-overlay h3 {
        font-size: 1.45rem;
        margin-bottom: 1rem;
    }

    .lock-overlay p {
        font-size: 0.95rem;
        margin-bottom: 1.75rem;
    }

    .modal {
        padding: 1rem;
    }

    .modal-content {
        padding: 2rem 1rem;
    }

    .scroll-indicator {
        display: none;
    }

    .game-page-body {
        padding-bottom: 0;
    }

    .game-page {
        padding: 0.75rem 1rem 1.5rem;
        min-height: 100svh;
        gap: 0;
        justify-content: flex-start;
    }

    .game-topbar {
        grid-template-columns: 1fr;
        gap: 0.75rem;
        justify-items: center;
        padding-bottom: 0.75rem;
    }

    .game-back {
        justify-self: start;
    }

    .game-hero-panel {
        align-items: flex-start;
        flex-direction: column;
        padding-top: 1.25rem;
        min-height: auto;
    }

    .game-title-block {
        align-items: flex-start;
        flex-direction: column;
        width: 100%;
    }

    .game-page-logo-frame {
        width: 100%;
        max-width: 360px;
        height: 96px;
    }

    .game-page-logo {
        width: 100%;
        height: 100%;
    }

    body[data-game="evobacbo5"] .game-page-logo {
        transform: scale(1.25);
    }

    .game-stats-grid {
        grid-template-columns: 1fr;
    }

    .game-stat-card {
        min-height: 112px;
        align-items: center;
    }

    .game-stat-card > div:not(.stat-icon) {
        min-width: 0;
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: center;
        column-gap: 0.75rem;
        row-gap: 0.25rem;
        flex: 1;
    }

    .game-stat-card span {
        margin: 0;
    }

    .game-stat-card strong {
        grid-row: 1 / span 2;
        grid-column: 2;
        font-size: 1.65rem;
        text-align: right;
    }

    .game-stat-card small {
        margin: 0;
        grid-column: 1;
    }

    .round-filter {
        justify-content: flex-start;
        overflow-x: auto;
    }

    .game-tabs {
        grid-template-columns: 1fr;
    }

    .game-analysis-grid {
        grid-template-columns: 1fr;
    }

    .distribution-layout {
        grid-template-columns: 1fr;
        justify-items: center;
        min-height: auto;
    }

    .distribution-list {
        width: 100%;
    }

    .result-chip-grid {
        grid-template-columns: repeat(auto-fill, minmax(30px, 30px));
    }

    .live-history-section {
        padding: 1rem;
    }

    .history-meta {
        flex-wrap: wrap;
    }

    .latest-result-card {
        grid-template-columns: auto auto minmax(0, 1fr) auto;
        align-items: center;
        gap: 0.55rem;
    }

    .latest-result-card time {
        grid-column: auto;
    }

    .history-card-grid {
        grid-template-columns: repeat(auto-fill, minmax(48px, 1fr));
        gap: 0.9rem 0.4rem;
    }

    .history-card {
        width: 48px;
        height: 48px;
    }
}

@media (max-width: 420px) {
    .logo {
        font-size: 1.25rem;
    }

    .brand-led {
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.25rem;
    }

    h1.glitch {
        font-size: 2.15rem;
    }

    .hero-community {
        font-size: 0.38em;
        letter-spacing: 0.05em;
    }

    .subtitle {
        font-size: 0.95rem;
    }

    .tab-item .icon {
        font-size: 1rem;
        margin-bottom: 4px;
    }

    .tab-item span {
        font-size: 0.45rem;
    }

    .central-bg {
        width: 46px;
        height: 46px;
    }

    .central-bg .icon {
        font-size: 1.3rem;
    }

    .chart-card {
        min-height: 240px;
        padding: 1rem;
    }

    .btn-glow,
    button {
        width: 100%;
        padding: 0.9rem 1rem;
    }

    .game-page {
        padding: 0.65rem 0.7rem 1.25rem;
    }

    .game-live-center {
        flex-wrap: wrap;
        justify-content: center;
    }

    .game-title-block h1 {
        font-size: 1.05rem;
    }

    .game-page-logo-frame {
        width: 100%;
        max-width: 330px;
        height: 84px;
    }

    body[data-game="evobacbo5"] .game-page-logo {
        transform: scale(1.45);
    }

    .game-stat-card {
        min-height: 104px;
        padding: 0.85rem;
    }

    .game-stat-card strong {
        font-size: 1.5rem;
    }

    .round-filter {
        padding: 0.5rem;
        gap: 0.35rem;
    }

    .round-filter a {
        min-width: 44px;
        padding: 0.4rem 0.62rem;
        font-size: 0.8rem;
    }

    .game-tabs button {
        min-height: 44px;
        height: auto;
        white-space: normal;
        line-height: 1.2;
    }

    .analysis-card,
    .live-history-section {
        padding: 0.85rem;
    }

    .validator-controls,
    .validator-summary-grid {
        grid-template-columns: 1fr;
    }

    .validator-token {
        width: 40px;
        height: 34px;
    }

    .analysis-card-header {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.35rem;
    }

    .distribution-layout {
        gap: 0.9rem;
        padding-top: 0.5rem;
    }

    .donut-chart {
        width: 128px;
        height: 128px;
    }

    .distribution-list div {
        min-height: 38px;
        padding: 0.48rem 0.6rem;
    }

    .distribution-list span {
        font-size: 0.86rem;
    }

    .distribution-list strong {
        font-size: 0.9rem;
        min-width: 56px;
    }

    .latest-result-card {
        grid-template-columns: auto auto minmax(0, 1fr) auto;
        gap: 0.45rem;
    }

    .latest-result-card time {
        grid-column: auto;
        font-size: 0.72rem;
    }

    .result-chip-grid {
        grid-template-columns: repeat(auto-fill, minmax(26px, 26px));
        gap: 4px;
    }

    .history-card-grid {
        grid-template-columns: repeat(auto-fill, minmax(44px, 1fr));
    }

    .history-card {
        width: 44px;
        height: 44px;
    }
}

/* Hero brand polish */
body.logged-in .ui-wrapper > nav:first-of-type .logo {
    opacity: 0;
    pointer-events: none;
}

body.logged-in .ui-wrapper > nav:first-of-type {
    padding-bottom: 0.75rem;
}

body.logged-in .ui-wrapper > nav:first-of-type .nav-links {
    margin-left: auto;
}

body.logged-in main {
    padding-top: 0.6rem;
}

.hero-content {
    position: relative;
}

.hero-content::before {
    content: "";
    position: absolute;
    left: -1.2rem;
    top: 0.15rem;
    width: 3px;
    height: 7.4rem;
    border-radius: 999px;
    background: linear-gradient(180deg, #00f3ff, rgba(159, 77, 255, 0.9));
    box-shadow: 0 0 24px rgba(0, 243, 255, 0.58);
}

.hero-brand {
    gap: 0.22rem;
    margin-bottom: 1.25rem;
}

.hero-main-word {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    column-gap: 0.12em;
    line-height: 0.9;
}

.hero-community {
    color: rgba(241, 247, 255, 0.86);
    font-size: clamp(1.05rem, 2.05vw, 1.65rem);
    letter-spacing: 0.22em;
    line-height: 1;
    text-shadow: 0 0 18px rgba(0, 243, 255, 0.22);
}

.hero-cyber,
.hero-bot {
    font-size: clamp(4rem, 8vw, 6.9rem);
    letter-spacing: 0.045em;
}

.hero-cyber {
    color: #f4feff;
    text-shadow:
        0 0 10px rgba(255, 255, 255, 0.75),
        0 0 28px rgba(0, 243, 255, 0.52);
}

.hero-bot {
    color: #00f3ff;
    background: linear-gradient(180deg, #ffffff 0%, #00f3ff 45%, #8f47ff 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: none;
    filter: drop-shadow(0 0 16px rgba(0, 243, 255, 0.58));
}

.subtitle {
    max-width: 650px;
    color: rgba(232, 240, 247, 0.74);
    font-size: 1.12rem;
    margin-bottom: 2.1rem;
}

.session-timer {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.65rem 0.95rem;
    border: 1px solid rgba(0, 243, 255, 0.22);
    border-radius: 999px;
    background: rgba(0, 243, 255, 0.045);
    box-shadow: inset 0 0 18px rgba(0, 243, 255, 0.05);
}

.session-user-id {
    padding-left: 0.75rem;
    border-left: 1px solid rgba(255, 255, 255, 0.14);
}

@media (max-width: 768px) {
    body.logged-in .ui-wrapper > nav:first-of-type .logo {
        display: none;
    }

    body.logged-in .ui-wrapper > nav:first-of-type .nav-links {
        width: 100%;
        display: flex;
        gap: 0.65rem;
    }

    .hero-content {
        text-align: left;
        padding-left: 1rem;
    }

    .hero-content::before {
        left: 0;
        height: 5.9rem;
    }

    .hero-main-word {
        column-gap: 0.08em;
    }

    .hero-cyber,
    .hero-bot {
        font-size: clamp(2.7rem, 14vw, 4.4rem);
    }

    .session-timer {
        width: 100%;
        justify-content: space-between;
        border-radius: 14px;
    }
}

@media (max-width: 420px) {
    .hero-content {
        padding-left: 0.8rem;
    }

    .hero-community {
        letter-spacing: 0.14em;
    }

    .hero-cyber,
    .hero-bot {
        font-size: clamp(2.25rem, 13vw, 3.4rem);
    }
}

/* Desktop navigation final override */
@media (min-width: 769px) {
    body.logged-in {
        padding-bottom: 48px;
    }

    body.logged-in .tab-bar {
        position: sticky;
        top: 14px;
        left: auto;
        bottom: auto;
        transform: none;
        width: fit-content;
        max-width: calc(100vw - 4rem);
        min-height: 0;
        margin: -0.25rem auto 1.35rem;
        padding: 6px;
        gap: 4px;
        justify-content: center;
        border-radius: 16px;
        background: rgba(8, 14, 26, 0.78);
        border: 1px solid rgba(0, 243, 255, 0.14);
        box-shadow: 0 14px 34px rgba(0, 0, 0, 0.34);
        backdrop-filter: blur(16px);
    }

    body.logged-in .tab-bar .tab-item {
        height: 40px;
        min-width: 0;
        max-width: none;
        padding: 0 14px;
        flex-direction: row;
        gap: 8px;
        border-radius: 11px;
        color: rgba(231, 238, 246, 0.68);
    }

    body.logged-in .tab-bar .tab-item:hover,
    body.logged-in .tab-bar .tab-item.active {
        color: #061018;
        background: #00f3ff;
        box-shadow: 0 0 20px rgba(0, 243, 255, 0.22);
    }

    body.logged-in .tab-bar .tab-item .icon,
    body.logged-in .tab-bar .central-bg .icon {
        width: 18px;
        height: 18px;
        font-size: 1rem;
        margin: 0;
        filter: none;
    }

    body.logged-in .tab-bar .tab-item:hover .icon,
    body.logged-in .tab-bar .tab-item.active .icon {
        transform: none;
        filter: none;
    }

    body.logged-in .tab-bar .tab-item span {
        min-height: 0;
        font-size: 0.66rem;
        letter-spacing: 0.08em;
        line-height: 1;
    }

    body.logged-in .tab-bar .tab-item.central {
        top: 0;
    }

    body.logged-in .tab-bar .central-bg {
        width: 18px;
        height: 18px;
        border: 0;
        border-radius: 0;
        background: transparent;
        box-shadow: none;
    }

    body.logged-in .tab-bar .central-bg .icon {
        color: currentColor;
    }

    body.logged-in .tab-bar .tab-item-youtube .icon::before {
        width: 19px;
        height: 13px;
        border-radius: 4px;
    }

    body.logged-in .tab-bar .tab-item-youtube .icon::after {
        border-top-width: 3px;
        border-bottom-width: 3px;
        border-left-width: 5px;
    }
}

/* Desktop sidebar navigation */
@media (min-width: 769px) {
    body.logged-in {
        padding-bottom: 0;
    }

    body.logged-in .ui-wrapper {
        padding-left: 7.5rem;
    }

    body.logged-in .tab-bar {
        position: fixed;
        top: 50%;
        left: 1.35rem;
        bottom: auto;
        transform: translateY(-50%);
        width: 82px;
        max-width: 82px;
        min-height: 0;
        margin: 0;
        padding: 12px 8px;
        display: flex;
        flex-direction: column;
        gap: 8px;
        border-radius: 22px;
        background: rgba(8, 14, 26, 0.82);
        border: 1px solid rgba(0, 243, 255, 0.16);
        box-shadow: 0 18px 40px rgba(0, 0, 0, 0.38);
        backdrop-filter: blur(18px);
    }

    body.logged-in .tab-bar .tab-item {
        width: 100%;
        height: 58px;
        min-width: 0;
        max-width: none;
        padding: 7px 4px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 5px;
        border-radius: 15px;
        color: rgba(231, 238, 246, 0.68);
    }

    body.logged-in .tab-bar .tab-item:hover,
    body.logged-in .tab-bar .tab-item.active {
        color: #061018;
        background: #00f3ff;
        box-shadow: 0 0 22px rgba(0, 243, 255, 0.24);
    }

    body.logged-in .tab-bar .tab-item .icon,
    body.logged-in .tab-bar .central-bg .icon {
        width: 22px;
        height: 22px;
        font-size: 1.15rem;
        margin: 0;
        filter: none;
    }

    body.logged-in .tab-bar .tab-item:hover .icon,
    body.logged-in .tab-bar .tab-item.active .icon {
        transform: none;
        filter: none;
    }

    body.logged-in .tab-bar .tab-item span {
        width: 100%;
        min-height: 0;
        display: block;
        font-size: 0.54rem;
        letter-spacing: 0.08em;
        line-height: 1;
        text-align: center;
        white-space: nowrap;
    }

    body.logged-in .tab-bar .tab-item.central {
        top: 0;
    }

    body.logged-in .tab-bar .central-bg {
        width: 22px;
        height: 22px;
        border: 0;
        border-radius: 0;
        background: transparent;
        box-shadow: none;
    }

    body.logged-in .tab-bar .central-bg .icon {
        color: currentColor;
    }

    body.logged-in .tab-bar .tab-item-youtube .icon::before {
        width: 21px;
        height: 14px;
        border-radius: 4px;
    }

    body.logged-in .tab-bar .tab-item-youtube .icon::after {
        border-top-width: 3px;
        border-bottom-width: 3px;
        border-left-width: 5px;
    }
}

/* Desktop navigation: keep the mobile dock only on phones */
@media (min-width: 769px) {
    body.logged-in {
        padding-bottom: 48px;
    }

    body.logged-in .tab-bar {
        position: sticky;
        top: 14px;
        left: auto;
        bottom: auto;
        transform: none;
        width: fit-content;
        max-width: calc(100vw - 4rem);
        min-height: 0;
        margin: -0.25rem auto 1.35rem;
        padding: 6px;
        gap: 4px;
        justify-content: center;
        border-radius: 16px;
        background: rgba(8, 14, 26, 0.78);
        border: 1px solid rgba(0, 243, 255, 0.14);
        box-shadow: 0 14px 34px rgba(0, 0, 0, 0.34);
        backdrop-filter: blur(16px);
    }

    body.logged-in .tab-bar .tab-item {
        height: 40px;
        min-width: 0;
        max-width: none;
        padding: 0 14px;
        flex-direction: row;
        gap: 8px;
        border-radius: 11px;
        color: rgba(231, 238, 246, 0.68);
    }

    body.logged-in .tab-bar .tab-item:hover,
    body.logged-in .tab-bar .tab-item.active {
        color: #061018;
        background: #00f3ff;
        box-shadow: 0 0 20px rgba(0, 243, 255, 0.22);
    }

    body.logged-in .tab-bar .tab-item .icon,
    body.logged-in .tab-bar .central-bg .icon {
        width: 18px;
        height: 18px;
        font-size: 1rem;
        margin: 0;
        filter: none;
    }

    body.logged-in .tab-bar .tab-item:hover .icon,
    body.logged-in .tab-bar .tab-item.active .icon {
        transform: none;
        filter: none;
    }

    body.logged-in .tab-bar .tab-item span {
        min-height: 0;
        font-size: 0.66rem;
        letter-spacing: 0.08em;
        line-height: 1;
    }

    body.logged-in .tab-bar .tab-item.central {
        top: 0;
    }

    body.logged-in .tab-bar .central-bg {
        width: 18px;
        height: 18px;
        border: 0;
        border-radius: 0;
        background: transparent;
        box-shadow: none;
    }

    body.logged-in .tab-bar .central-bg .icon {
        color: currentColor;
    }

    body.logged-in .tab-bar .tab-item-youtube .icon::before {
        width: 19px;
        height: 13px;
        border-radius: 4px;
    }

    body.logged-in .tab-bar .tab-item-youtube .icon::after {
        border-top-width: 3px;
        border-bottom-width: 3px;
        border-left-width: 5px;
    }
}

/* Layout normal da pagina inicial: sem fundo animado e sem hero em tela cheia */
#worm-canvas,
.scroll-indicator {
    display: none !important;
}

main {
    min-height: auto !important;
    justify-content: flex-start !important;
    gap: 1.5rem !important;
    padding-top: 1.5rem !important;
    margin-bottom: 1rem !important;
}

body.logged-out main {
    min-height: auto !important;
    padding: 2rem 0 1rem !important;
}

/* Polimento final da página de jogo - manter no fim do CSS */
body.game-page-body {
    background:
        radial-gradient(circle at 0% 0%, rgba(10, 42, 55, 0.7), transparent 34%),
        linear-gradient(90deg, #081620 0%, #080f18 42%, #080b11 100%);
}

body.game-page-body .game-page {
    max-width: 1250px;
    padding: 0.65rem 0.85rem 1.35rem;
}

body.game-page-body .game-topbar {
    min-height: 38px;
    margin-bottom: 1.1rem;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
}

body.game-page-body .game-back {
    width: max-content;
    max-width: 180px;
    min-height: 30px;
    padding: 0.38rem 0.9rem;
    border-radius: 9px;
    font-size: 0.72rem;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

body.game-page-body .game-hero-panel {
    min-height: auto;
    padding: 0.95rem 0 0.8rem;
    align-items: flex-start;
}

body.game-page-body .game-title-block {
    display: block;
    width: auto;
}

body.game-page-body .game-title-block h1 {
    font-size: clamp(1.25rem, 2vw, 1.55rem);
    margin-bottom: 0.25rem;
}

body.game-page-body .game-title-block p,
body.game-page-body .game-live-status {
    font-size: 0.82rem;
}

body.game-page-body .game-stats-grid {
    gap: 0.75rem;
    margin-bottom: 0.85rem;
}

body.game-page-body .game-stat-card {
    min-height: 136px;
    padding: 1rem;
    border-radius: 11px;
}

body.game-page-body .round-filter {
    margin: 0.75rem 0 1rem;
}

body.game-page-body .game-tabs {
    margin-bottom: 1rem;
    gap: 0.45rem;
}

body.game-page-body .game-tabs button {
    height: 42px;
}

body.game-page-body .pattern-validator-card {
    min-height: auto;
    padding: 1.45rem;
    border-radius: 11px;
}

body.game-page-body .validator-layout {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: stretch;
    gap: 1rem;
}

body.game-page-body .validator-pattern-box {
    min-height: 56px;
}

body.game-page-body .validator-token {
    width: 44px;
    height: 36px;
}

body.game-page-body .validator-stats-card {
    min-height: 148px;
}

@media (max-width: 1024px) {
    body.game-page-body .game-page {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    body.game-page-body .game-hero-panel {
        padding-top: 0.75rem;
        padding-bottom: 0.75rem;
    }

    body.game-page-body .game-stat-card {
        min-height: 118px;
    }

    body.game-page-body .validator-layout {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    }
}

@media (max-width: 760px) {
    body.game-page-body .game-page {
        padding: 0.65rem 0.75rem 1.25rem;
    }

    body.game-page-body .game-topbar {
        grid-template-columns: 1fr;
        gap: 0.55rem;
        justify-items: center;
        margin-bottom: 0.75rem;
    }

    body.game-page-body .game-back {
        justify-self: start;
    }

    body.game-page-body .game-hero-panel {
        gap: 0.35rem;
    }

    body.game-page-body .game-stats-grid {
        grid-template-columns: 1fr;
    }

    body.game-page-body .game-stat-card {
        min-height: 88px;
    }

    body.game-page-body .game-tabs {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    body.game-page-body .game-tabs button {
        height: 38px;
        min-height: 38px;
    }

    body.game-page-body .validator-layout {
        grid-template-columns: 1fr;
    }

    body.game-page-body .pattern-validator-card {
        padding: 1rem;
    }
}

/* Correção simples e final do layout interno dos games - camada final real */
body.game-page-body .game-page {
    width: min(100%, 1180px);
    max-width: 1180px;
    margin: 0 auto;
    padding: 0.55rem 0.75rem 1rem;
}

body.game-page-body .game-back {
    font-size: 0;
}

body.game-page-body .game-back::after {
    content: "← Jogos";
    font-size: 0.72rem;
}

body.game-page-body .game-title-block > p:not(.game-subtitle-clean) {
    display: none;
}

body.game-page-body .game-subtitle-clean {
    display: block;
}

body.game-page-body .game-live-status {
    font-size: 0;
}

body.game-page-body .game-live-status::before {
    content: "↻ Ao Vivo • ";
    font-size: 0.82rem;
}

body.game-page-body .game-live-status span {
    font-size: 0.82rem;
}

body.game-page-body .game-topbar {
    min-height: 34px;
    margin-bottom: 0.65rem;
}

body.game-page-body .game-hero-panel {
    padding: 0.45rem 0 0.65rem;
    margin: 0;
}

body.game-page-body .game-stats-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.75rem;
    margin: 0 0 0.75rem;
}

body.game-page-body .game-stat-card {
    min-height: 112px;
    padding: 0.95rem 1rem;
}

body.game-page-body .stat-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.9rem;
}

body.game-page-body .stat-values strong {
    display: block;
    font-size: 1.75rem;
    line-height: 1;
}

body.game-page-body .round-filter {
    min-height: 40px;
    margin: 0 0 0.75rem;
}

body.game-page-body .game-tabs {
    margin-bottom: 0.8rem;
}

body.game-page-body .pattern-validator-card,
body.game-page-body .analysis-card {
    border-radius: 10px;
}

body.game-page-body .pattern-validator-card {
    padding: 1rem 1.15rem;
}

body.game-page-body .validator-layout {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

body.game-page-body .validator-pattern-box {
    min-height: 54px;
}

@media (max-width: 900px) {
    body.game-page-body .game-page {
        width: 100%;
        padding: 0.5rem 0.65rem 1rem;
    }

    body.game-page-body .game-stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    body.game-page-body .game-stat-card {
        min-height: 100px;
    }

    body.game-page-body .validator-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 520px) {
    body.game-page-body .game-stats-grid {
        grid-template-columns: 1fr;
    }

    body.game-page-body .game-stat-card {
        min-height: 82px;
    }
}

/* Preenchimento total da página de jogo */
body.game-page-body .game-page {
    width: 100%;
    max-width: none;
    padding-left: clamp(1rem, 2vw, 2.2rem);
    padding-right: clamp(1rem, 2vw, 2.2rem);
}

body.game-page-body .game-analysis-grid {
    grid-template-columns: minmax(0, 1.6fr) minmax(360px, 0.6fr);
}

@media (min-width: 1500px) {
    body.game-page-body .game-analysis-grid {
        grid-template-columns: minmax(0, 1.75fr) minmax(430px, 0.55fr);
    }
}

@media (max-width: 900px) {
    body.game-page-body .game-analysis-grid {
        grid-template-columns: 1fr;
    }
}

/* Layout fluido dos games - ultima regra */
body.game-page-body .game-stats-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
}

body.game-page-body .validator-layout {
    grid-template-columns: minmax(0, 1fr) minmax(320px, 0.85fr);
}

body.game-page-body .history-card-grid {
    grid-template-columns: repeat(auto-fill, minmax(clamp(44px, 4vw, 64px), 1fr));
}

@media (min-width: 1700px) {
    body.game-page-body .game-stats-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    body.game-page-body .analysis-card {
        min-height: 320px;
    }

    body.game-page-body .live-history-section {
        min-height: 410px;
    }
}

@media (max-width: 1200px) {
    body.game-page-body .game-analysis-grid,
    body.game-page-body .validator-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    body.game-page-body .game-stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    body.game-page-body .round-filter {
        justify-content: flex-start;
        overflow-x: auto;
    }
}

@media (max-width: 520px) {
    body.game-page-body .game-stats-grid,
    body.game-page-body .validator-controls,
    body.game-page-body .validator-summary-grid {
        grid-template-columns: 1fr;
    }
}

/* Painel de contagem ate empate */
body.game-page-body .tie-counter-section {
    margin-top: clamp(1rem, 1.8vw, 1.6rem);
    padding: clamp(0.85rem, 1.4vw, 1.2rem);
    border: 1px solid rgba(242, 176, 30, 0.38);
    border-radius: 10px;
    background:
        linear-gradient(135deg, rgba(60, 26, 8, 0.88), rgba(18, 9, 8, 0.9) 52%, rgba(9, 12, 18, 0.92)),
        repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.025) 0 1px, transparent 1px 26px),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.025) 0 1px, transparent 1px 26px);
    box-shadow: inset 0 0 0 1px rgba(255, 214, 128, 0.04), 0 18px 48px rgba(0, 0, 0, 0.28);
    color: #f8ead2;
}

body.game-page-body .tie-counter-header,
body.game-page-body .tie-counter-heading,
body.game-page-body .tie-counter-summary,
body.game-page-body .tie-legend {
    display: flex;
    align-items: center;
}

body.game-page-body .tie-counter-header {
    justify-content: space-between;
    gap: 1rem;
}

body.game-page-body .tie-counter-heading {
    gap: 0.75rem;
    min-width: 0;
}

body.game-page-body .tie-counter-icon {
    display: inline-grid;
    width: 28px;
    height: 28px;
    place-items: center;
    border: 1px solid rgba(242, 176, 30, 0.45);
    border-radius: 7px;
    color: #f2b01e;
    font: 700 0.68rem/1 'Orbitron', sans-serif;
    background: rgba(242, 176, 30, 0.08);
}

body.game-page-body .tie-counter-heading h2 {
    margin: 0;
    font-family: 'Orbitron', sans-serif;
    font-size: clamp(1.25rem, 2.3vw, 2.25rem);
    line-height: 0.95;
    letter-spacing: 0;
    color: #fff7e9;
}

body.game-page-body .tie-counter-heading p {
    margin: 0.35rem 0 0;
    color: rgba(255, 238, 211, 0.74);
    font-size: clamp(0.78rem, 1vw, 0.92rem);
}

body.game-page-body .tie-counter-summary {
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.35rem;
    padding: 0.35rem;
    border: 1px solid rgba(242, 176, 30, 0.28);
    border-radius: 999px;
    background: rgba(17, 10, 8, 0.6);
    font-size: 0.82rem;
}

body.game-page-body .tie-counter-summary strong,
body.game-page-body .tie-counter-summary span {
    display: inline-flex;
    min-height: 30px;
    align-items: center;
    padding: 0 0.8rem;
    border-radius: 999px;
    background: rgba(242, 176, 30, 0.07);
    white-space: nowrap;
}

body.game-page-body .tie-metric-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr));
    gap: 0.7rem;
    margin-top: 1rem;
}

body.game-page-body .tie-metric-card {
    min-height: 86px;
    padding: 0.75rem 0.85rem;
    border: 1px solid rgba(242, 176, 30, 0.25);
    border-radius: 8px;
    background: rgba(22, 14, 13, 0.72);
}

body.game-page-body .tie-metric-card span,
body.game-page-body .tie-metric-card small {
    display: block;
    color: rgba(255, 238, 211, 0.66);
    font-weight: 700;
}

body.game-page-body .tie-metric-card span {
    font-size: 0.72rem;
    text-transform: uppercase;
}

body.game-page-body .tie-metric-card strong {
    display: block;
    margin: 0.28rem 0 0.18rem;
    font-size: clamp(1.35rem, 2vw, 2rem);
    color: #fff7e9;
}

body.game-page-body .tie-metric-alert strong {
    color: #ffd35c;
}

body.game-page-body .tie-chart-card {
    margin-top: 0.9rem;
    padding: 0.9rem;
    border: 1px solid rgba(242, 176, 30, 0.24);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(24, 19, 20, 0.86), rgba(13, 16, 23, 0.76));
}

body.game-page-body .tie-chart-topline {
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
    color: rgba(255, 238, 211, 0.72);
    font-size: 0.78rem;
    font-weight: 800;
}

body.game-page-body .tie-chart-topline-meta {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    flex-wrap: wrap;
}

body.game-page-body .tie-chart-bars {
    display: flex;
    align-items: flex-end;
    gap: 4px;
    min-height: 190px;
    margin-top: 0.55rem;
    padding: 0.35rem 0 0.6rem;
    overflow-x: auto;
    border-bottom: 1px solid rgba(255, 211, 92, 0.35);
    background:
        linear-gradient(180deg, transparent 0 34%, rgba(255, 103, 64, 0.12) 34% 62%, transparent 62%),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.03) 0 1px, transparent 1px 34px);
}

body.game-page-body .tie-chart-bar {
    width: clamp(7px, 0.75vw, 11px);
    min-width: clamp(7px, 0.75vw, 11px);
    border-radius: 999px 999px 2px 2px;
    background: #45d6ff;
    box-shadow: 0 0 10px rgba(69, 214, 255, 0.45);
}

body.game-page-body .tie-chart-bar.result-B {
    background: #e23a3a;
    box-shadow: 0 0 10px rgba(226, 58, 58, 0.45);
}

body.game-page-body .tie-chart-bar.result-J {
    background: #2278f0;
    box-shadow: 0 0 10px rgba(34, 120, 240, 0.45);
}

body.game-page-body .tie-chart-bar.result-Y,
body.game-page-body .tie-chart-bar.result-E,
body.game-page-body .tie-chart-bar.tie-reset {
    background: #1bb56c;
    box-shadow: 0 0 12px rgba(242, 176, 30, 0.55);
}

body.game-page-body .tie-h-1 { height: 14px; }
body.game-page-body .tie-h-2 { height: 28px; }
body.game-page-body .tie-h-3 { height: 42px; }
body.game-page-body .tie-h-4 { height: 56px; }
body.game-page-body .tie-h-5 { height: 70px; }
body.game-page-body .tie-h-6 { height: 84px; }
body.game-page-body .tie-h-7 { height: 98px; }
body.game-page-body .tie-h-8 { height: 112px; }
body.game-page-body .tie-h-9 { height: 126px; }
body.game-page-body .tie-h-10 { height: 140px; }
body.game-page-body .tie-h-11 { height: 154px; }
body.game-page-body .tie-h-12 { height: 168px; }

body.game-page-body .tie-legend {
    flex-wrap: wrap;
    gap: 0.45rem;
    margin-top: 0.75rem;
}

body.game-page-body .tie-legend span {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    min-height: 26px;
    padding: 0 0.65rem;
    border: 1px solid rgba(69, 214, 255, 0.28);
    border-radius: 999px;
    background: rgba(9, 19, 31, 0.62);
    color: rgba(232, 244, 255, 0.8);
    font-size: 0.75rem;
    font-weight: 800;
}

body.game-page-body .tie-line-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
}

body.game-page-body .line-live { background: #45d6ff; }
body.game-page-body .line-average { background: #9a7cff; }
body.game-page-body .line-tie { background: #1bb56c; }

body.game-page-body .tie-top-section {
    margin-top: 0.8rem;
}

body.game-page-body .tie-top-section h3 {
    margin: 0 0 0.55rem;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.86rem;
    color: #ffe1a3;
}

body.game-page-body .tie-top-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 170px), 1fr));
    gap: 0.55rem;
}

body.game-page-body .tie-top-card {
    padding: 0.65rem 0.75rem;
    border: 1px solid rgba(0, 194, 255, 0.28);
    border-radius: 8px;
    background: rgba(7, 22, 41, 0.72);
    text-align: center;
}

body.game-page-body .tie-top-card strong {
    display: block;
    color: #fff7e9;
    font-size: 1.25rem;
}

body.game-page-body .tie-top-card span,
body.game-page-body .tie-top-card small {
    display: block;
    color: rgba(255, 238, 211, 0.72);
    font-weight: 800;
}

body.game-page-body .tie-footnote {
    margin-top: 0.8rem;
    padding: 0.75rem 0.85rem;
    border: 1px solid rgba(242, 176, 30, 0.22);
    border-radius: 8px;
    background: rgba(10, 13, 22, 0.72);
    color: rgba(255, 238, 211, 0.82);
    font-weight: 700;
}

body.game-page-body .tie-footnote strong {
    color: #fff7e9;
}

@media (max-width: 980px) {
    body.game-page-body .tie-counter-header,
    body.game-page-body .tie-chart-topline {
        align-items: flex-start;
        flex-direction: column;
    }

    body.game-page-body .tie-counter-summary {
        width: 100%;
        justify-content: flex-start;
        border-radius: 10px;
    }
}

@media (max-width: 560px) {
    body.game-page-body .tie-counter-section {
        padding: 0.75rem;
    }

    body.game-page-body .tie-counter-heading {
        align-items: flex-start;
    }

    body.game-page-body .tie-counter-heading h2 {
        font-size: 1.25rem;
        line-height: 1.1;
    }

    body.game-page-body .tie-metric-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    body.game-page-body .tie-chart-bars {
        min-height: 145px;
    }

    body.game-page-body .tie-h-8 { height: 88px; }
    body.game-page-body .tie-h-9 { height: 99px; }
    body.game-page-body .tie-h-10 { height: 110px; }
    body.game-page-body .tie-h-11 { height: 121px; }
    body.game-page-body .tie-h-12 { height: 132px; }
}

/* Tema final da contagem de empate no layout da pagina */
body.game-page-body .tie-counter-section {
    border-color: rgba(0, 194, 255, 0.24);
    background:
        linear-gradient(180deg, rgba(18, 29, 40, 0.94), rgba(13, 20, 30, 0.96)),
        repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.025) 0 1px, transparent 1px 26px),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.025) 0 1px, transparent 1px 26px);
    box-shadow: inset 0 0 0 1px rgba(0, 194, 255, 0.04), 0 16px 42px rgba(0, 0, 0, 0.24);
    color: #e9f6ff;
}

body.game-page-body .tie-counter-icon {
    border-color: rgba(0, 194, 255, 0.42);
    color: #22d3ff;
    background: rgba(0, 194, 255, 0.11);
    box-shadow: 0 0 18px rgba(0, 194, 255, 0.18);
}

body.game-page-body .tie-counter-heading h2 {
    color: #f7fbff;
    text-shadow: 0 0 14px rgba(0, 255, 255, 0.24);
}

body.game-page-body .tie-counter-heading p,
body.game-page-body .tie-metric-card span,
body.game-page-body .tie-metric-card small,
body.game-page-body .tie-chart-topline,
body.game-page-body .tie-top-card span,
body.game-page-body .tie-top-card small,
body.game-page-body .tie-footnote {
    color: rgba(169, 190, 205, 0.92);
}

body.game-page-body .tie-counter-summary {
    border-color: rgba(0, 194, 255, 0.2);
    background: rgba(8, 13, 22, 0.7);
}

body.game-page-body .tie-counter-summary strong,
body.game-page-body .tie-counter-summary span {
    background: rgba(20, 32, 45, 0.92);
    color: #dff8ff;
}

body.game-page-body .tie-metric-card,
body.game-page-body .tie-chart-card,
body.game-page-body .tie-top-card,
body.game-page-body .tie-footnote {
    border-color: rgba(42, 58, 75, 0.95);
    background: rgba(18, 28, 40, 0.82);
}

body.game-page-body .tie-metric-card strong,
body.game-page-body .tie-top-card strong,
body.game-page-body .tie-footnote strong {
    color: #f7fbff;
}

body.game-page-body .tie-metric-alert strong {
    color: #22d3ff;
    text-shadow: 0 0 16px rgba(34, 211, 255, 0.38);
}

body.game-page-body .tie-chart-card {
    padding: clamp(0.75rem, 1vw, 1rem);
    background:
        linear-gradient(180deg, rgba(18, 28, 40, 0.88), rgba(11, 17, 27, 0.9)),
        repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.022) 0 1px, transparent 1px 28px),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.022) 0 1px, transparent 1px 34px);
}

body.game-page-body .tie-zoom-controls {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

body.game-page-body .tie-zoom-controls button {
    width: 34px;
    height: 34px;
    border: 1px solid rgba(42, 58, 75, 0.95);
    border-radius: 8px;
    background: rgba(13, 20, 30, 0.86);
    color: #dff8ff;
    font: 900 1rem/1 'Inter', sans-serif;
    cursor: pointer;
    transition: 0.2s ease;
}

body.game-page-body .tie-zoom-controls button:hover:not(:disabled) {
    border-color: rgba(34, 211, 255, 0.82);
    color: #22d3ff;
    box-shadow: inset 0 0 0 1px rgba(34, 211, 255, 0.18), 0 0 16px rgba(34, 211, 255, 0.12);
}

body.game-page-body .tie-zoom-controls button:disabled {
    opacity: 0.45;
    cursor: default;
}

body.game-page-body .tie-line-chart-wrap {
    width: 100%;
    min-height: clamp(180px, 18vw, 260px);
    margin-top: 0.65rem;
    overflow: auto;
    border: 1px solid rgba(0, 194, 255, 0.16);
    border-radius: 8px;
    background:
        linear-gradient(180deg, rgba(10, 18, 30, 0.12), rgba(0, 194, 255, 0.035)),
        repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.03) 0 1px, transparent 1px 42px),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.025) 0 1px, transparent 1px 56px);
}

body.game-page-body .tie-line-chart-wrap.tie-zoom-level-1 {
    min-height: clamp(240px, 24vw, 340px);
}

body.game-page-body .tie-line-chart-wrap.tie-zoom-level-2 {
    min-height: clamp(300px, 30vw, 420px);
}

body.game-page-body .tie-line-chart {
    display: block;
    width: var(--tie-chart-width, 1000px);
    min-width: var(--tie-chart-width, 1000px);
    height: clamp(180px, 18vw, 260px);
}

body.game-page-body .tie-line-chart-wrap.tie-zoom-level-1 .tie-line-chart {
    width: calc(var(--tie-chart-width, 1000px) * 1.32);
    min-width: calc(var(--tie-chart-width, 1000px) * 1.32);
    height: clamp(240px, 24vw, 340px);
}

body.game-page-body .tie-line-chart-wrap.tie-zoom-level-2 .tie-line-chart {
    width: calc(var(--tie-chart-width, 1000px) * 1.68);
    min-width: calc(var(--tie-chart-width, 1000px) * 1.68);
    height: clamp(300px, 30vw, 420px);
}

body.game-page-body .tie-chart-ma {
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
}

body.game-page-body .tie-chart-ma-fast {
    stroke: rgba(255, 196, 87, 0.95);
    stroke-width: 2.4;
    filter: drop-shadow(0 0 6px rgba(255, 196, 87, 0.35));
}

body.game-page-body .tie-chart-ma-slow {
    stroke: rgba(255, 96, 96, 0.9);
    stroke-width: 2.2;
    stroke-dasharray: 10 7;
    filter: drop-shadow(0 0 6px rgba(255, 96, 96, 0.28));
}

body.game-page-body .tie-chart-main-line {
    fill: none;
    stroke: #45d6ff;
    stroke-width: 4;
    stroke-linecap: round;
    stroke-linejoin: round;
    filter: drop-shadow(0 0 8px rgba(69, 214, 255, 0.45));
}

body.game-page-body .tie-chart-point {
    fill: #45d6ff;
    stroke: #dff8ff;
    stroke-width: 2;
    filter: drop-shadow(0 0 7px rgba(69, 214, 255, 0.58));
}

body.game-page-body .tie-chart-point.result-B {
    fill: var(--game-color-B, #d72d34);
    filter: drop-shadow(0 0 7px color-mix(in srgb, var(--game-color-B, #d72d34) 72%, transparent));
}

body.game-page-body .tie-chart-point.result-J {
    fill: var(--game-color-J, #1265d8);
    filter: drop-shadow(0 0 7px color-mix(in srgb, var(--game-color-J, #1265d8) 72%, transparent));
}

body.game-page-body .tie-chart-point.result-G {
    fill: var(--game-color-G, #19c37d);
    filter: drop-shadow(0 0 7px color-mix(in srgb, var(--game-color-G, #19c37d) 72%, transparent));
}

body.game-page-body .tie-chart-point.result-Y {
    fill: var(--game-color-Y, #f2b01e);
    filter: drop-shadow(0 0 9px color-mix(in srgb, var(--game-color-Y, #f2b01e) 78%, transparent));
}

body.game-page-body .tie-chart-point.result-E,
body.game-page-body .tie-chart-point.tie-reset {
    fill: var(--game-color-E, #f2b01e);
    filter: drop-shadow(0 0 9px color-mix(in srgb, var(--game-color-E, #f2b01e) 78%, transparent));
}

body.game-page-body .tie-chart-point.is-current {
    stroke: #ffffff;
    stroke-width: 2.6;
    filter:
        drop-shadow(0 0 10px rgba(255, 255, 255, 0.7))
        drop-shadow(0 0 18px rgba(69, 214, 255, 0.55));
    animation: tieCurrentPulse 1.7s ease-in-out infinite;
}

body.game-page-body .tie-chart-point.tie-reset.is-current {
    filter:
        drop-shadow(0 0 10px rgba(255, 250, 214, 0.78))
        drop-shadow(0 0 18px rgba(242, 176, 30, 0.72));
}

body.game-page-body .tie-chart-point-group.is-current .tie-chart-point-label {
    fill: #0c131b;
    stroke: rgba(255, 255, 255, 0.98);
    animation: tieCurrentLabelPulse 1.7s ease-in-out infinite;
}

body.game-page-body .tie-chart-point-group {
    pointer-events: none;
}

body.game-page-body .tie-chart-point-label {
    fill: #10161e;
    font: 900 12px/1 'Inter', sans-serif;
    text-anchor: middle;
    paint-order: stroke;
    stroke: rgba(255, 244, 214, 0.95);
    stroke-width: 4px;
    stroke-linejoin: round;
}

body.game-page-body .tie-top-section h3 {
    color: #dff8ff;
}

body.game-page-body .tie-legend span {
    border-color: rgba(42, 58, 75, 0.95);
    background: rgba(18, 28, 40, 0.82);
}

body.game-page-body .line-live { background: #45d6ff; }
body.game-page-body .line-ma-fast { background: #ffc457; }
body.game-page-body .line-ma-slow { background: #ff6060; }
body.game-page-body .line-tie { background: #1bb56c; }

@keyframes tieCurrentPulse {
    0%, 100% {
        opacity: 1;
        filter:
            drop-shadow(0 0 8px rgba(255, 255, 255, 0.62))
            drop-shadow(0 0 14px rgba(69, 214, 255, 0.42));
    }
    50% {
        opacity: 0.82;
        filter:
            drop-shadow(0 0 14px rgba(255, 255, 255, 0.92))
            drop-shadow(0 0 24px rgba(69, 214, 255, 0.78));
    }
}

@keyframes tieCurrentLabelPulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.82;
    }
}

@media (max-width: 560px) {
    body.game-page-body .tie-line-chart-wrap,
    body.game-page-body .tie-line-chart {
        min-height: 170px;
        height: 170px;
    }

    body.game-page-body .tie-metric-grid {
        grid-template-columns: 1fr;
    }

    body.game-page-body .tie-chart-topline {
        align-items: flex-start;
        flex-direction: column;
    }
}

/* Conferidor de sinais */
body.game-page-body .signal-checker-section {
    margin-top: clamp(1rem, 1.8vw, 1.5rem);
    padding: clamp(0.85rem, 1.3vw, 1.15rem);
    border: 1px solid rgba(0, 194, 255, 0.24);
    border-radius: 10px;
    background:
        linear-gradient(180deg, rgba(18, 29, 40, 0.94), rgba(13, 20, 30, 0.96)),
        repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.025) 0 1px, transparent 1px 26px),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.025) 0 1px, transparent 1px 26px);
}

body.game-page-body .signal-checker-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

body.game-page-body .signal-checker-header h2 {
    margin: 0;
    color: #f7fbff;
    font-family: 'Orbitron', sans-serif;
    font-size: clamp(1rem, 1.4vw, 1.35rem);
    letter-spacing: 0;
}

body.game-page-body .signal-checker-header p {
    margin: 0.3rem 0 0;
    color: rgba(169, 190, 205, 0.92);
    font-weight: 700;
}

body.game-page-body .signal-summary-pills {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.45rem;
}

body.game-page-body .signal-summary-pills span {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    min-height: 30px;
    padding: 0 0.65rem;
    border: 1px solid rgba(42, 58, 75, 0.95);
    border-radius: 999px;
    background: rgba(13, 20, 30, 0.86);
    color: rgba(232, 244, 255, 0.82);
    font-size: 0.74rem;
    font-weight: 900;
}

body.game-page-body .signal-summary-pills b {
    color: #f7fbff;
}

body.game-page-body .signal-live-block {
    margin-top: 0.9rem;
    margin-bottom: 0.9rem;
    padding: 0.9rem;
    border: 1px solid rgba(46, 72, 102, 0.95);
    border-radius: 8px;
    background: rgba(10, 26, 42, 0.55);
}

body.game-page-body .signal-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    margin-bottom: 0.7rem;
}

body.game-page-body .signal-section-head-main {
    display: grid;
    gap: 0.18rem;
}

body.game-page-body .signal-section-head h3 {
    margin: 0;
    color: #f7fbff;
    font-size: 0.98rem;
}

body.game-page-body .signal-section-head span {
    color: rgba(169, 190, 205, 0.92);
    font-size: 0.78rem;
    font-weight: 800;
}

body.game-page-body .signal-focus-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    min-height: 32px;
    padding: 0 0.7rem;
    border-radius: 999px;
    border: 1px solid rgba(46, 72, 102, 0.95);
    background: rgba(11, 20, 31, 0.68);
    color: #dff3ff;
    font-size: 0.76rem;
    font-weight: 800;
    cursor: pointer;
    user-select: none;
}

body.game-page-body .signal-focus-toggle input {
    accent-color: #22d3ff;
    width: 14px;
    height: 14px;
    margin: 0;
}

body.game-page-body .signal-live-block.signal-focus-pulse {
    animation: signalFocusPulse 1.4s ease-out;
}

body.game-page-body .signal-live-list {
    display: grid;
    gap: 0.55rem;
}

body.game-page-body .signal-live-list .signal-card {
    background: rgba(15, 28, 42, 0.95);
    border-color: rgba(64, 121, 173, 0.9);
}

body.game-page-body .signal-scanner-card {
    position: relative;
    overflow: hidden;
    display: grid;
    gap: 0.9rem;
    min-height: 138px;
    padding: 1rem 1.05rem;
    border: 1px solid rgba(49, 104, 153, 0.7);
    border-radius: 12px;
    background:
        radial-gradient(circle at top right, rgba(34, 211, 255, 0.08), transparent 32%),
        linear-gradient(180deg, rgba(11, 20, 31, 0.96), rgba(15, 28, 42, 0.96));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), 0 18px 34px rgba(0, 0, 0, 0.18);
}

body.game-page-body .signal-scanner-head {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

body.game-page-body .signal-scanner-core {
    position: relative;
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
    display: grid;
    place-items: center;
}

body.game-page-body .signal-scanner-pulse,
body.game-page-body .signal-scanner-dot {
    position: absolute;
    border-radius: 999px;
}

body.game-page-body .signal-scanner-pulse {
    inset: 0;
    border: 1px solid rgba(34, 211, 255, 0.4);
    background: rgba(34, 211, 255, 0.08);
    animation: signalScannerPulse 1.8s ease-out infinite;
}

body.game-page-body .signal-scanner-dot {
    width: 10px;
    height: 10px;
    background: #22d3ff;
    box-shadow: 0 0 12px rgba(34, 211, 255, 0.8);
}

body.game-page-body .signal-scanner-copy {
    display: grid;
    gap: 0.16rem;
}

body.game-page-body .signal-scanner-copy strong {
    color: #eef8ff;
    font-size: 1rem;
    font-weight: 900;
}

body.game-page-body .signal-scanner-copy span {
    color: rgba(169, 190, 205, 0.92);
    font-size: 0.78rem;
    font-weight: 700;
}

body.game-page-body .signal-scanner-track {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    min-height: 32px;
    animation: signalScannerDrift 6s linear infinite;
}

body.game-page-body .scan-token {
    width: 28px;
    height: 28px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #f7fbff;
    font-size: 0.74rem;
    font-weight: 900;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.14), 0 6px 16px rgba(0, 0, 0, 0.22);
}

body.game-page-body .signal-scanner-line {
    position: relative;
    height: 12px;
    border-radius: 999px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

body.game-page-body .signal-scanner-beam {
    position: absolute;
    top: -10px;
    bottom: -10px;
    width: 24%;
    border-radius: 999px;
    background: linear-gradient(90deg, transparent, rgba(34, 211, 255, 0.45), transparent);
    filter: blur(1px);
    animation: signalScannerBeam 2.8s ease-in-out infinite;
}

body.game-page-body .signal-scanner-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
}

body.game-page-body .signal-scanner-status {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 0.7rem;
    border-radius: 999px;
    background: rgba(34, 211, 255, 0.08);
    border: 1px solid rgba(34, 211, 255, 0.14);
    color: #bfeeff;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.02em;
}

body.game-page-body .signal-list {
    display: grid;
    gap: 0.55rem;
    margin-top: 0.9rem;
}

body.game-page-body .signal-card {
    display: grid;
    grid-template-columns: 88px minmax(0, 1fr) 72px;
    gap: 0.75rem;
    align-items: center;
    min-height: 46px;
    padding: 0.45rem 0.7rem;
    border: 1px solid rgba(42, 58, 75, 0.95);
    border-radius: 8px;
    background: rgba(14, 22, 33, 0.82);
}

body.game-page-body .signal-status-group {
    display: grid;
    gap: 0.2rem;
    align-items: center;
}

body.game-page-body .signal-status {
    display: inline-grid;
    min-height: 26px;
    place-items: center;
    border-radius: 8px;
    color: #f7fbff;
    font-weight: 900;
    background: rgba(34, 211, 255, 0.16);
    font-size: 0.95rem;
}

body.game-page-body .signal-stage-badge {
    display: inline-grid;
    min-height: 20px;
    place-items: center;
    padding: 0 0.45rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: rgba(210, 225, 236, 0.92);
    font-size: 0.68rem;
    font-weight: 900;
    letter-spacing: 0.04em;
}

body.game-page-body .signal-flow {
    display: grid;
    gap: 0.28rem;
    min-width: 0;
}

body.game-page-body .signal-flow-line {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    min-width: 0;
    flex-wrap: wrap;
}

body.game-page-body .signal-flow-results {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    min-width: 0;
    flex-wrap: wrap;
}

body.game-page-body .signal-flow-meta,
body.game-page-body .signal-card time {
    color: rgba(169, 190, 205, 0.92);
    font-size: 0.78rem;
    font-weight: 800;
}

body.game-page-body .signal-flow-meta-trail {
    margin-left: 0.15rem;
}

body.game-page-body .signal-pattern-stats {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex-wrap: wrap;
}

body.game-page-body .signal-pattern-stat {
    display: inline-flex;
    align-items: center;
    min-height: 22px;
    padding: 0 0.45rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.045);
    border: 1px solid rgba(255, 255, 255, 0.06);
    color: rgba(189, 214, 230, 0.96);
    font-size: 0.68rem;
    font-weight: 800;
}

body.game-page-body .signal-token-line {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    min-height: 28px;
}

body.game-page-body .signal-token-line-inline {
    min-height: 28px;
}

body.game-page-body .signal-token-track {
    display: flex;
    align-items: center;
    gap: 0.34rem;
    flex-wrap: wrap;
}

body.game-page-body .signal-token-track-inline {
    gap: 0.22rem;
}

body.game-page-body .signal-token-track-trail {
    gap: 0.18rem;
}

body.game-page-body .signal-separator {
    color: rgba(116, 144, 167, 0.85);
    font-size: 0.8rem;
    font-weight: 900;
    line-height: 1;
}

body.game-page-body .signal-token-badge {
    width: 30px;
    height: 30px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12), 0 8px 20px rgba(0, 0, 0, 0.22);
    color: #f7fbff;
    font-weight: 900;
    line-height: 1;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}

body.game-page-body .signal-token-badge.signal-token-inline {
    width: 28px;
    height: 28px;
}

body.game-page-body .signal-token-number {
    font-size: 0.78rem;
    letter-spacing: -0.03em;
}

body.game-page-body .signal-token-inline .signal-token-number {
    font-size: 0.74rem;
}

body.game-page-body .signal-token-badge.signal-token-color-only {
    color: transparent;
    text-shadow: none;
}

body.game-page-body .signal-token-badge.signal-token-number-only {
    background: radial-gradient(circle at 30% 30%, #ffffff, #dbe7f1 72%);
    color: #0b1118;
    text-shadow: none;
    border-color: rgba(255, 255, 255, 0.72);
}

body.game-page-body .signal-token-badge.result-B {
    background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-B, #c62828) 58%, white), var(--game-color-B, #c62828) 68%);
}

body.game-page-body .signal-token-badge.result-J {
    background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-J, #1265d8) 58%, white), var(--game-color-J, #1265d8) 68%);
}

body.game-page-body .signal-token-badge.result-D {
    background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-D, #c62828) 58%, white), var(--game-color-D, #c62828) 68%);
}

body.game-page-body .signal-token-badge.result-T {
    background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-T, #f2b01e) 58%, white), var(--game-color-T, #f2b01e) 68%);
    color: var(--game-text-T, #221600);
}

body.game-page-body .signal-token-badge.result-E {
    background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-E, #f2b01e) 58%, white), var(--game-color-E, #f2b01e) 68%);
    color: var(--game-text-E, #221600);
}

body.game-page-body .signal-token-badge.result-G {
    background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-G, #19c37d) 58%, white), var(--game-color-G, #19c37d) 68%);
}

body.game-page-body .signal-token-badge.result-Y {
    background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-Y, #f2b01e) 58%, white), var(--game-color-Y, #f2b01e) 68%);
    color: var(--game-text-Y, #221600);
}

body.game-page-body .signal-token-badge.result-O {
    background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-O, #0097b8) 58%, white), var(--game-color-O, #0097b8) 68%);
}

body.game-page-body .signal-token-badge.result-N {
    background: radial-gradient(circle at 30% 30%, #ffffff, #dbe7f1 72%);
}

body.game-page-body .scan-token.result-B {
    background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-B, #c62828) 58%, white), var(--game-color-B, #c62828) 68%);
}

body.game-page-body .scan-token.result-J {
    background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-J, #1265d8) 58%, white), var(--game-color-J, #1265d8) 68%);
}

body.game-page-body .scan-token.result-D {
    background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-D, #c62828) 58%, white), var(--game-color-D, #c62828) 68%);
}

body.game-page-body .scan-token.result-T {
    background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-T, #f2b01e) 58%, white), var(--game-color-T, #f2b01e) 68%);
    color: var(--game-text-T, #221600);
}

body.game-page-body .scan-token.result-E {
    background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--game-color-E, #f2b01e) 58%, white), var(--game-color-E, #f2b01e) 68%);
    color: var(--game-text-E, #221600);
}

body.game-page-body .signal-awaiting {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 0.65rem;
    border-radius: 999px;
    background: rgba(169, 190, 205, 0.1);
    border: 1px solid rgba(169, 190, 205, 0.18);
    color: #d8e4ee;
    font-size: 0.74rem;
    font-weight: 800;
}

body.game-page-body .signal-equals {
    color: #f7fbff;
    font-size: 1rem;
    font-weight: 900;
    line-height: 1;
}

body.game-page-body .signal-card.status-win .signal-status,
body.game-page-body .signal-status-win {
    border-color: rgba(25, 195, 125, 0.34);
    color: #4dffae;
    background: rgba(25, 195, 125, 0.12);
}

body.game-page-body .signal-card.status-gale-1 .signal-status,
body.game-page-body .signal-card.status-gale-2 .signal-status,
body.game-page-body .signal-status-gale {
    border-color: rgba(34, 211, 255, 0.34);
    color: #22d3ff;
    background: rgba(34, 211, 255, 0.12);
}

body.game-page-body .signal-card.status-ao-vivo .signal-status,
body.game-page-body .signal-card.status-em-gale-1 .signal-status,
body.game-page-body .signal-card.status-em-gale-2 .signal-status,
body.game-page-body .signal-status-live {
    border-color: rgba(144, 205, 255, 0.34);
    color: #90cdff;
    background: rgba(59, 130, 246, 0.12);
}

body.game-page-body .signal-card.status-empate .signal-status,
body.game-page-body .signal-status-tie {
    border-color: rgba(242, 176, 30, 0.36);
    color: #f2b01e;
    background: rgba(242, 176, 30, 0.12);
}

body.game-page-body .signal-card.status-loss .signal-status,
body.game-page-body .signal-status-loss {
    border-color: rgba(215, 45, 52, 0.36);
    color: #ff6b72;
    background: rgba(215, 45, 52, 0.12);
}

body.game-page-body .signal-card.status-aguardando .signal-status {
    color: #a9becd;
    background: rgba(169, 190, 205, 0.1);
}

@keyframes signalScannerPulse {
    0% {
        transform: scale(0.8);
        opacity: 0.2;
    }
    60% {
        transform: scale(1.18);
        opacity: 0.7;
    }
    100% {
        transform: scale(1.28);
        opacity: 0;
    }
}

@keyframes signalScannerBeam {
    0% {
        left: -28%;
    }
    100% {
        left: 104%;
    }
}

@keyframes signalScannerDrift {
    0%, 100% {
        transform: translateX(0);
    }
    50% {
        transform: translateX(10px);
    }
}

@keyframes signalFocusPulse {
    0% {
        box-shadow: 0 0 0 0 rgba(34, 211, 255, 0.32);
        border-color: rgba(46, 72, 102, 0.95);
    }
    35% {
        box-shadow: 0 0 0 12px rgba(34, 211, 255, 0);
        border-color: rgba(34, 211, 255, 0.88);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(34, 211, 255, 0);
        border-color: rgba(46, 72, 102, 0.95);
    }
}

@media (max-width: 900px) {
    body.game-page-body .signal-checker-header {
        flex-direction: column;
    }

    body.game-page-body .signal-summary-pills {
        justify-content: flex-start;
    }

    body.game-page-body .signal-section-head {
        align-items: flex-start;
        flex-direction: column;
    }

    body.game-page-body .signal-card {
        grid-template-columns: 84px minmax(0, 1fr);
    }

    body.game-page-body .signal-scanner-card {
        min-height: 150px;
    }

    body.game-page-body .signal-card time {
        grid-column: 2;
    }
}

@media (max-width: 560px) {
    body.game-page-body .signal-card {
        grid-template-columns: 1fr;
    }

    body.game-page-body .signal-flow-line {
        gap: 0.35rem;
    }

    body.game-page-body .signal-scanner-head {
        align-items: flex-start;
    }

    body.game-page-body .signal-scanner-footer {
        gap: 0.4rem;
    }

    body.game-page-body .signal-card time {
        grid-column: auto;
    }
}

/* Camada final de responsividade da pagina de jogos */
body.game-page-body {
    overflow-x: hidden;
}

body.game-page-body .game-page {
    width: min(100%, 1440px);
    max-width: 1440px;
    margin: 0 auto;
    padding: clamp(0.75rem, 1.4vw, 1.25rem);
}

body.game-page-body .game-topbar,
body.game-page-body .game-hero-panel,
body.game-page-body .game-stats-grid,
body.game-page-body .round-filter,
body.game-page-body .game-tabs,
body.game-page-body .game-analysis-grid,
body.game-page-body .validator-layout,
body.game-page-body .distribution-layout,
body.game-page-body .tie-counter-header,
body.game-page-body .tie-counter-heading,
body.game-page-body .tie-counter-summary,
body.game-page-body .signal-checker-header,
body.game-page-body .signal-section-head,
body.game-page-body .latest-result-card {
    min-width: 0;
}

body.game-page-body .game-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    flex-wrap: wrap;
}

body.game-page-body .game-live-center {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

body.game-page-body .game-hero-panel {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

body.game-page-body .game-title-block {
    flex: 1 1 320px;
    min-width: 0;
}

body.game-page-body .game-live-status {
    flex: 0 1 auto;
    white-space: nowrap;
}

body.game-page-body .game-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
    gap: 0.85rem;
}

body.game-page-body .round-filter {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    flex-wrap: wrap;
}

body.game-page-body .round-filter span {
    flex: 0 0 auto;
}

body.game-page-body .game-tabs {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
    gap: 0.6rem;
}

body.game-page-body .game-tabs button {
    width: 100%;
    min-width: 0;
    white-space: normal;
}

body.game-page-body .game-analysis-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) minmax(300px, 0.72fr);
    gap: 1rem;
    align-items: stretch;
}

body.game-page-body .analysis-card,
body.game-page-body .pattern-validator-card,
body.game-page-body .live-history-section,
body.game-page-body .tie-counter-section,
body.game-page-body .signal-checker-section {
    min-width: 0;
}

body.game-page-body .analysis-card-header,
body.game-page-body .results-card-heading,
body.game-page-body .signal-checker-header,
body.game-page-body .signal-section-head {
    min-width: 0;
}

body.game-page-body .analysis-card-header {
    flex-wrap: wrap;
}

body.game-page-body .results-card-heading,
body.game-page-body .analysis-card-header h2,
body.game-page-body .analysis-card-header span {
    min-width: 0;
    overflow-wrap: anywhere;
}

body.game-page-body .distribution-layout {
    display: grid;
    grid-template-columns: minmax(120px, 150px) minmax(0, 1fr);
    align-items: center;
    gap: 1rem;
}

body.game-page-body .distribution-list {
    min-width: 0;
}

body.game-page-body .distribution-list div,
body.game-page-body .latest-result-card,
body.game-page-body .signal-card {
    min-width: 0;
}

body.game-page-body .latest-result-card {
    display: grid;
    grid-template-columns: auto auto minmax(0, 1fr) auto;
    gap: 0.6rem;
    align-items: center;
}

body.game-page-body .latest-result-card em,
body.game-page-body .latest-result-card time {
    min-width: 0;
    overflow-wrap: anywhere;
}

body.game-page-body .history-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(clamp(44px, 4.2vw, 62px), 1fr));
    gap: 0.9rem 0.45rem;
}

body.game-page-body .validator-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
    gap: 1rem;
}

body.game-page-body .validator-actions-row,
body.game-page-body .validator-controls,
body.game-page-body .validator-summary-grid,
body.game-page-body .tie-metric-grid,
body.game-page-body .tie-top-grid {
    min-width: 0;
}

body.game-page-body .validator-palette {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

body.game-page-body .tie-counter-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

body.game-page-body .tie-counter-heading {
    flex: 1 1 380px;
}

body.game-page-body .tie-counter-summary {
    flex: 1 1 320px;
}

body.game-page-body .tie-metric-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr));
    gap: 0.75rem;
}

body.game-page-body .tie-chart-topline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    flex-wrap: wrap;
}

body.game-page-body .tie-top-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 170px), 1fr));
    gap: 0.75rem;
}

body.game-page-body .signal-checker-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.9rem;
    flex-wrap: wrap;
}

body.game-page-body .signal-summary-pills {
    justify-content: flex-start;
}

body.game-page-body .signal-card {
    grid-template-columns: 88px minmax(0, 1fr) 72px;
}

@media (max-width: 1200px) {
    body.game-page-body .game-analysis-grid,
    body.game-page-body .validator-layout,
    body.game-page-body .distribution-layout {
        grid-template-columns: 1fr;
    }

    body.game-page-body .distribution-layout {
        justify-items: center;
    }

    body.game-page-body .distribution-list {
        width: 100%;
    }
}

@media (max-width: 900px) {
    body.game-page-body .game-page {
        padding: 0.8rem 0.75rem 1rem;
    }

    body.game-page-body .game-topbar,
    body.game-page-body .game-hero-panel,
    body.game-page-body .tie-counter-header,
    body.game-page-body .tie-chart-topline,
    body.game-page-body .signal-checker-header,
    body.game-page-body .signal-section-head {
        flex-direction: column;
        align-items: stretch;
    }

    body.game-page-body .game-live-center {
        justify-content: flex-start;
    }

    body.game-page-body .game-live-status {
        white-space: normal;
    }

    body.game-page-body .game-stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    body.game-page-body .latest-result-card,
    body.game-page-body .signal-card {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    body.game-page-body .game-page {
        padding: 0.7rem 0.6rem 0.9rem;
    }

    body.game-page-body .game-stats-grid,
    body.game-page-body .validator-controls,
    body.game-page-body .validator-summary-grid,
    body.game-page-body .tie-metric-grid {
        grid-template-columns: 1fr;
    }

    body.game-page-body .round-filter {
        align-items: stretch;
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 0.1rem;
    }

    body.game-page-body .round-filter a {
        flex: 0 0 auto;
    }

    body.game-page-body .game-tabs {
        grid-template-columns: 1fr;
    }

    body.game-page-body .validator-actions-row {
        display: grid;
        grid-template-columns: 1fr;
        gap: 0.6rem;
    }

    body.game-page-body .validator-clear {
        width: 100%;
    }
}

/* Refinos de layout sem mudar a paleta */
body.game-page-body .game-page {
    display: grid;
    gap: 1.25rem;
    width: 100%;
    justify-items: stretch;
}

body.game-page-body .game-topbar {
    margin-bottom: 0;
}

body.game-page-body .game-hero-panel {
    padding: 1rem 0;
    gap: 1.25rem;
    width: 100%;
}

body.game-page-body .game-title-block h1 {
    font-size: clamp(1.45rem, 2.6vw, 2.35rem);
    line-height: 0.98;
    letter-spacing: -0.03em;
    margin-bottom: 0.35rem;
}

body.game-page-body .game-subtitle-clean {
    max-width: 42ch;
}

body.game-page-body .game-live-status {
    align-self: center;
}

body.game-page-body .game-stats-grid {
    gap: 0.9rem;
}

body.game-page-body .game-stat-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 108px;
    padding: 1rem 1.05rem;
}

body.game-page-body .stat-header {
    margin-bottom: 0.55rem;
}

body.game-page-body .stat-values {
    display: grid;
    gap: 0.2rem;
}

body.game-page-body .round-filter {
    gap: 0.55rem;
    margin: 0;
}

body.game-page-body .round-filter a {
    min-width: 62px;
    text-align: center;
}

body.game-page-body .game-tabs {
    gap: 0.65rem;
    margin: 0;
}

body.game-page-body .game-tabs button {
    min-height: 48px;
    padding: 0.7rem 0.95rem;
}

body.game-page-body .game-analysis-grid {
    gap: 1.1rem;
}

body.game-page-body .analysis-card,
body.game-page-body .pattern-validator-card,
body.game-page-body .live-history-section,
body.game-page-body .tie-counter-section,
body.game-page-body .signal-checker-section {
    border-radius: 18px;
}

body.game-page-body .analysis-card-header {
    margin-bottom: 0.85rem;
}

body.game-page-body .results-card-heading {
    gap: 0.16rem;
}

body.game-page-body .results-card-heading h2,
body.game-page-body .analysis-card-header h2,
body.game-page-body .live-history-title h2,
body.game-page-body .validator-title h2,
body.game-page-body .tie-counter-heading h2,
body.game-page-body .signal-checker-header h2 {
    letter-spacing: -0.02em;
}

body.game-page-body .distribution-card,
body.game-page-body .results-card {
    height: 100%;
}

body.game-page-body .distribution-layout {
    min-height: 100%;
}

body.game-page-body .live-history-section {
    padding: 1.15rem;
}

body.game-page-body .live-history-title {
    align-items: center;
    gap: 0.85rem;
    margin-bottom: 0.7rem;
}

body.game-page-body .live-history-title h2 {
    font-size: clamp(1.2rem, 2vw, 1.8rem);
    line-height: 1;
}

body.game-page-body .history-meta {
    margin-bottom: 0.9rem;
}

body.game-page-body .latest-result-card {
    margin-bottom: 0.95rem;
    padding: 0.8rem 0.9rem;
}

body.game-page-body .history-card-grid {
    gap: 0.95rem 0.5rem;
}

body.game-page-body .history-card-wrap {
    gap: 0.22rem;
}

body.game-page-body .history-card {
    border-radius: 16px;
}

body.game-page-body .pattern-validator-card {
    padding: 1.15rem;
}

body.game-page-body .validator-title {
    margin-bottom: 0.9rem;
}

body.game-page-body .validator-layout {
    gap: 1.1rem;
}

body.game-page-body .validator-builder,
body.game-page-body .validator-stats-card {
    display: grid;
    align-content: start;
    gap: 0.75rem;
}

body.game-page-body .validator-pattern-box {
    padding: 0.8rem;
}

body.game-page-body .validator-controls {
    gap: 0.8rem;
}

body.game-page-body .tie-counter-section {
    padding: 1.2rem;
}

body.game-page-body .tie-counter-header {
    margin-bottom: 0.95rem;
}

body.game-page-body .tie-metric-grid,
body.game-page-body .tie-top-grid {
    gap: 0.8rem;
}

body.game-page-body .signal-checker-section {
    padding: 1.1rem;
}

body.game-page-body .signal-live-block {
    margin-top: 0.8rem;
    margin-bottom: 0.8rem;
}

body.game-page-body .signal-list {
    margin-top: 0.8rem;
}

@media (max-width: 900px) {
    body.game-page-body .game-page {
        gap: 0.9rem;
    }

    body.game-page-body .game-hero-panel {
        padding-top: 0.6rem;
        gap: 0.8rem;
    }

    body.game-page-body .game-title-block h1 {
        font-size: clamp(1.3rem, 6vw, 1.9rem);
    }

    body.game-page-body .game-stat-card,
    body.game-page-body .live-history-section,
    body.game-page-body .pattern-validator-card,
    body.game-page-body .tie-counter-section,
    body.game-page-body .signal-checker-section {
        padding: 1rem;
    }

    body.game-page-body .game-tabs button {
        min-height: 44px;
    }
}

@media (max-width: 640px) {
    body.game-page-body .game-page {
        gap: 0.75rem;
    }

    body.game-page-body .game-hero-panel {
        padding-top: 0.35rem;
    }

    body.game-page-body .game-stat-card {
        min-height: 92px;
        padding: 0.9rem;
    }

    body.game-page-body .stat-header {
        gap: 0.55rem;
    }

    body.game-page-body .round-filter {
        gap: 0.45rem;
    }

    body.game-page-body .round-filter a {
        min-width: 56px;
    }

    body.game-page-body .latest-result-card {
        padding: 0.7rem 0.75rem;
    }
}

/* Refinos extras de mobile */
@media (max-width: 768px) {
    body.game-page-body .game-page {
        width: 100%;
        max-width: 100%;
        padding: 0.72rem 0.62rem 1rem;
    }

    body.game-page-body .game-topbar {
        gap: 0.55rem;
    }

    body.game-page-body .game-back,
    body.game-page-body .live-pill,
    body.game-page-body .clock-pill,
    body.game-page-body .results-table-badge {
        min-height: 38px;
    }

    body.game-page-body .game-hero-panel {
        padding: 0.2rem 0 0.15rem;
        gap: 0.55rem;
        min-height: auto;
        align-items: flex-start;
        justify-content: flex-start;
    }

    body.game-page-body .game-title-block h1 {
        font-size: clamp(1.18rem, 7vw, 1.7rem);
        line-height: 1.02;
    }

    body.game-page-body .game-subtitle-clean,
    body.game-page-body .game-live-status {
        font-size: 0.76rem;
    }

    body.game-page-body .game-stats-grid {
        margin-top: 0;
    }

    body.game-page-body .game-stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.62rem;
    }

    body.game-page-body .game-stat-card {
        min-height: 118px;
        padding: 0.78rem;
        border-radius: 14px;
        display: grid;
        align-content: space-between;
        gap: 0.45rem;
    }

    body.game-page-body .stat-header {
        margin-bottom: 0;
        gap: 0.5rem;
        align-items: center;
    }

    body.game-page-body .stat-icon {
        width: 28px;
        height: 28px;
        font-size: 0.82rem;
        flex: 0 0 28px;
    }

    body.game-page-body .stat-header span {
        font-size: 0.8rem;
        line-height: 1.1;
    }

    body.game-page-body .stat-values {
        gap: 0.1rem;
    }

    body.game-page-body .stat-values strong {
        font-size: 1.48rem;
        line-height: 1;
    }

    body.game-page-body .stat-values small {
        font-size: 0.74rem;
    }

    body.game-page-body .round-filter {
        display: grid;
        grid-auto-flow: column;
        grid-auto-columns: max-content;
        justify-content: flex-start;
        gap: 0.42rem;
        flex-wrap: nowrap;
        overflow-x: auto;
        padding: 0 0 0.18rem;
        margin: 0;
    }

    body.game-page-body .round-filter span {
        position: sticky;
        left: 0;
        z-index: 1;
        display: inline-flex;
        align-items: center;
        padding-right: 0.25rem;
        background: inherit;
    }

    body.game-page-body .round-filter a {
        min-width: 54px;
        min-height: 38px;
        padding: 0.52rem 0.72rem;
        font-size: 0.78rem;
    }

    body.game-page-body .game-tabs {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }

    body.game-page-body .game-tabs button {
        min-height: 44px;
        padding: 0.75rem 0.85rem;
        font-size: 0.8rem;
    }

    body.game-page-body .analysis-card,
    body.game-page-body .distribution-card,
    body.game-page-body .results-card,
    body.game-page-body .pattern-validator-card,
    body.game-page-body .live-history-section,
    body.game-page-body .tie-counter-section,
    body.game-page-body .signal-checker-section {
        border-radius: 14px;
        padding: 0.9rem;
    }

    body.game-page-body .analysis-card-header,
    body.game-page-body .live-history-title,
    body.game-page-body .signal-section-head {
        gap: 0.45rem;
        margin-bottom: 0.7rem;
    }

    body.game-page-body .results-card-heading h2,
    body.game-page-body .analysis-card-header h2,
    body.game-page-body .live-history-title h2,
    body.game-page-body .validator-title h2,
    body.game-page-body .tie-counter-heading h2,
    body.game-page-body .signal-checker-header h2 {
        font-size: 1.02rem;
        line-height: 1.05;
    }

    body.game-page-body .results-card-heading small,
    body.game-page-body .analysis-card-header span,
    body.game-page-body .live-history-title span,
    body.game-page-body .history-meta span,
    body.game-page-body .validator-title p,
    body.game-page-body .signal-section-head span {
        font-size: 0.74rem;
    }

    body.game-page-body #result-chip-area {
        margin-top: 0;
    }

    body.game-page-body .result-chip-grid {
        grid-template-rows: repeat(6, minmax(0, 1fr));
        grid-auto-columns: minmax(24px, 24px);
        gap: 0.22rem;
        padding: 0.4rem 0.02rem 0.1rem;
    }

    body.game-page-body .result-chip {
        font-size: 0.48rem;
    }

    body.game-page-body .result-legend {
        justify-content: flex-start;
        gap: 0.4rem;
        margin-top: 0.7rem;
        padding-top: 0.65rem;
    }

    body.game-page-body .result-legend span {
        min-height: 26px;
        padding: 0 0.55rem;
        font-size: 0.72rem;
    }

    body.game-page-body .distribution-layout {
        grid-template-columns: 1fr;
        justify-items: center;
        gap: 0.75rem;
        min-height: auto;
        padding-top: 0.1rem;
    }

    body.game-page-body .donut-chart {
        width: 112px;
        height: 112px;
    }

    body.game-page-body .distribution-list {
        gap: 0.48rem;
    }

    body.game-page-body .distribution-list div {
        min-height: 34px;
        padding: 0.48rem 0.62rem;
        border-radius: 10px;
    }

    body.game-page-body .distribution-list strong,
    body.game-page-body .distribution-list span {
        font-size: 0.78rem;
    }

    body.game-page-body .validator-layout,
    body.game-page-body .game-analysis-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }

    body.game-page-body .validator-builder,
    body.game-page-body .validator-stats-card {
        gap: 0.65rem;
    }

    body.game-page-body .validator-pattern-box {
        min-height: 48px;
        padding: 0.7rem;
    }

    body.game-page-body .validator-palette {
        gap: 0.35rem;
    }

    body.game-page-body .validator-token {
        width: 38px;
        height: 34px;
        font-size: 0.76rem;
    }

    body.game-page-body .validator-controls {
        grid-template-columns: 1fr;
        gap: 0.62rem;
    }

    body.game-page-body .tie-counter-section {
        padding: 0.92rem;
        min-height: auto;
    }

    body.game-page-body .tie-counter-header,
    body.game-page-body .tie-chart-topline,
    body.game-page-body .signal-checker-header,
    body.game-page-body .signal-section-head {
        gap: 0.55rem;
    }

    body.game-page-body .tie-counter-icon {
        width: 38px;
        height: 38px;
        font-size: 0.8rem;
    }

    body.game-page-body .tie-metric-grid,
    body.game-page-body .tie-top-grid {
        grid-template-columns: 1fr;
        gap: 0.6rem;
    }

    body.game-page-body .tie-metric-card,
    body.game-page-body .tie-top-card,
    body.game-page-body .tie-footnote {
        padding: 0.78rem;
    }

    body.game-page-body .tie-chart-card,
    body.game-page-body .tie-top-section,
    body.game-page-body .tie-footnote {
        min-height: auto;
    }

    body.game-page-body .tie-chart-card {
        padding: 0.78rem;
    }

    body.game-page-body .tie-chart-topline {
        margin-bottom: 0.48rem;
    }

    body.game-page-body .tie-counter-summary {
        gap: 0.4rem;
    }

    body.game-page-body .tie-counter-summary strong,
    body.game-page-body .tie-counter-summary span {
        min-height: 28px;
        padding: 0 0.56rem;
        font-size: 0.69rem;
    }

    body.game-page-body .tie-line-chart-wrap,
    body.game-page-body .tie-line-chart {
        min-height: 180px;
        height: 180px;
    }

    body.game-page-body .signal-summary-pills {
        gap: 0.35rem;
    }

    body.game-page-body .signal-summary-pills span {
        min-height: 26px;
        padding: 0 0.52rem;
        font-size: 0.68rem;
    }

    body.game-page-body .signal-live-block {
        padding: 0.78rem;
    }

    body.game-page-body .signal-card {
        grid-template-columns: 1fr;
        gap: 0.55rem;
        min-height: auto;
        padding: 0.6rem;
    }

    body.game-page-body .signal-status {
        min-height: 30px;
        font-size: 0.84rem;
    }

    body.game-page-body .signal-card time,
    body.game-page-body .signal-flow-meta {
        font-size: 0.72rem;
    }

    body.game-page-body .live-history-section {
        padding: 0.9rem;
    }

    body.game-page-body .live-history-title {
        align-items: flex-start;
    }

    body.game-page-body .history-icon {
        width: 36px;
        height: 36px;
        font-size: 1rem;
    }

    body.game-page-body .history-meta {
        gap: 0.35rem;
        margin-bottom: 0.75rem;
    }

    body.game-page-body .latest-result-card {
        grid-template-columns: auto auto minmax(0, 1fr);
        gap: 0.45rem;
        margin-bottom: 0.75rem;
        padding: 0.65rem 0.7rem;
    }

    body.game-page-body .latest-result-card time {
        grid-column: 1 / -1;
    }

    body.game-page-body .history-card-grid {
        grid-template-columns: repeat(auto-fill, minmax(46px, 1fr));
        gap: 0.78rem 0.32rem;
    }

    body.game-page-body .history-card {
        width: 46px;
        height: 46px;
        border-radius: 14px;
    }

    body.game-page-body .history-card strong,
    body.game-page-body .history-card b {
        font-size: 0.82rem;
    }

    body.game-page-body .history-card-wrap time,
    body.game-page-body .history-card-wrap small {
        font-size: 0.64rem;
    }
}

@media (max-width: 420px) {
    body.game-page-body .game-page {
        padding: 0.65rem 0.52rem 0.9rem;
    }

    body.game-page-body .game-title-block h1 {
        font-size: 1.08rem;
    }

    body.game-page-body .game-stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 0.55rem;
    }

    body.game-page-body .game-stat-card {
        min-height: 108px;
        padding: 0.72rem;
    }

    body.game-page-body .stat-icon {
        width: 26px;
        height: 26px;
        flex-basis: 26px;
    }

    body.game-page-body .stat-header span {
        font-size: 0.76rem;
    }

    body.game-page-body .stat-values strong {
        font-size: 1.34rem;
    }

    body.game-page-body .stat-values small {
        font-size: 0.7rem;
    }

    body.game-page-body .game-hero-panel {
        padding-top: 0.1rem;
        padding-bottom: 0;
        gap: 0.42rem;
    }

    body.game-page-body .game-title-block {
        flex-basis: auto;
    }

    body.game-page-body .result-chip-grid {
        grid-auto-columns: minmax(22px, 22px);
        gap: 0.18rem;
    }

    body.game-page-body .tie-counter-section {
        padding: 0.82rem;
    }

    body.game-page-body .tie-counter-heading {
        gap: 0.5rem;
    }

    body.game-page-body .tie-counter-heading h2 {
        font-size: 0.96rem;
        line-height: 1.04;
    }

    body.game-page-body .tie-counter-heading p {
        font-size: 0.72rem;
    }

    body.game-page-body .tie-line-chart-wrap,
    body.game-page-body .tie-line-chart {
        min-height: 160px;
        height: 160px;
    }

    body.game-page-body .history-card-grid {
        grid-template-columns: repeat(auto-fill, minmax(42px, 1fr));
    }

    body.game-page-body .history-card {
        width: 42px;
        height: 42px;
    }
}

/* Correcao final do bloco de empate no mobile */
@media (max-width: 768px) {
    body.game-page-body .tie-counter-section {
        display: grid;
        gap: 0.7rem;
        min-height: 0 !important;
        overflow: hidden;
    }

    body.game-page-body .tie-counter-header,
    body.game-page-body .tie-counter-heading,
    body.game-page-body .tie-counter-summary {
        margin: 0;
    }

    body.game-page-body .tie-counter-heading,
    body.game-page-body .tie-counter-summary {
        flex: 0 0 auto !important;
        width: 100%;
        min-width: 0;
    }

    body.game-page-body .tie-counter-header {
        display: grid;
        grid-template-columns: 1fr;
        align-items: start;
    }

    body.game-page-body .tie-counter-heading {
        display: grid;
        grid-template-columns: auto minmax(0, 1fr);
        align-items: start;
    }

    body.game-page-body .tie-counter-heading p,
    body.game-page-body .tie-chart-topline span {
        overflow-wrap: anywhere;
    }

    body.game-page-body .tie-chart-card,
    body.game-page-body .tie-top-section,
    body.game-page-body .tie-footnote,
    body.game-page-body .tie-metric-card {
        min-height: 0 !important;
        height: auto !important;
        min-width: 0;
    }

    body.game-page-body .tie-chart-card {
        margin-top: 0;
        overflow: hidden;
    }

    body.game-page-body .tie-line-chart-wrap,
    body.game-page-body .tie-line-chart,
    body.game-page-body .tie-line-chart-wrap.tie-zoom-level-1,
    body.game-page-body .tie-line-chart-wrap.tie-zoom-level-2,
    body.game-page-body .tie-line-chart-wrap.tie-zoom-level-1 .tie-line-chart,
    body.game-page-body .tie-line-chart-wrap.tie-zoom-level-2 .tie-line-chart {
        min-height: 150px !important;
        height: 150px !important;
    }

    body.game-page-body .tie-line-chart-wrap {
        overflow-x: auto !important;
        overflow-y: hidden !important;
    }

    body.game-page-body .tie-chart-point-label {
        display: none;
    }

    body.game-page-body .tie-chart-main-line {
        stroke-width: 3;
    }

    body.game-page-body .tie-chart-ma-fast,
    body.game-page-body .tie-chart-ma-slow {
        stroke-width: 1.9;
    }

    body.game-page-body .tie-chart-point {
        stroke-width: 1.4;
    }

    body.game-page-body .tie-chart-topline-meta {
        width: 100%;
        justify-content: flex-start;
    }

    body.game-page-body .tie-counter-summary {
        display: flex;
        justify-content: flex-start;
        align-items: stretch;
        flex-wrap: wrap;
        width: 100%;
        max-width: 100%;
        overflow: hidden;
    }

    body.game-page-body .tie-counter-summary strong,
    body.game-page-body .tie-counter-summary span {
        white-space: normal;
        min-width: 0;
    }

    body.game-page-body .tie-metric-grid {
        width: 100%;
    }

    body.game-page-body .tie-metric-card {
        overflow: hidden;
    }

    body.game-page-body .tie-metric-card span,
    body.game-page-body .tie-metric-card small,
    body.game-page-body .tie-metric-card strong {
        overflow-wrap: anywhere;
    }

    body.game-page-body .tie-legend {
        margin-top: 0.6rem;
        gap: 0.35rem;
        max-width: 100%;
    }

    body.game-page-body .tie-legend span {
        min-height: 24px;
        padding: 0 0.52rem;
        font-size: 0.68rem;
        min-width: 0;
        max-width: 100%;
        overflow-wrap: anywhere;
    }
}

@media (max-width: 420px) {
    body.game-page-body .tie-line-chart-wrap,
    body.game-page-body .tie-line-chart,
    body.game-page-body .tie-line-chart-wrap.tie-zoom-level-1,
    body.game-page-body .tie-line-chart-wrap.tie-zoom-level-2,
    body.game-page-body .tie-line-chart-wrap.tie-zoom-level-1 .tie-line-chart,
    body.game-page-body .tie-line-chart-wrap.tie-zoom-level-2 .tie-line-chart {
        min-height: 132px !important;
        height: 132px !important;
    }

    body.game-page-body .tie-counter-summary {
        padding: 0.28rem;
    }

    body.game-page-body .tie-counter-summary strong,
    body.game-page-body .tie-counter-summary span {
        min-height: 26px;
        padding: 0 0.5rem;
        font-size: 0.66rem;
    }
}

/* Painel fixo de 126 resultados */
body.game-page-body .results-card {
    position: relative;
    padding: 1.2rem 1.2rem 1rem;
    border: 1px solid rgba(77, 111, 148, 0.56);
    border-radius: 18px;
    background:
        radial-gradient(circle at top left, rgba(34, 211, 255, 0.12), transparent 24%),
        radial-gradient(circle at bottom right, rgba(59, 130, 246, 0.1), transparent 28%),
        linear-gradient(180deg, rgba(23, 34, 47, 0.96), rgba(16, 24, 35, 0.99));
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.04),
        0 18px 40px rgba(0, 0, 0, 0.24);
}

body.game-page-body .results-card-heading {
    display: grid;
    gap: 0.22rem;
}

body.game-page-body .results-card-heading h2 {
    margin: 0;
    font-size: 1.08rem;
    letter-spacing: -0.02em;
}

body.game-page-body .results-card-heading small {
    color: rgba(174, 197, 214, 0.82);
    font-size: 0.74rem;
    font-weight: 800;
}

body.game-page-body .results-table-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 32px;
    padding: 0.1rem 0.8rem;
    border-radius: 999px;
    border: 1px solid rgba(34, 211, 255, 0.3);
    background: linear-gradient(180deg, rgba(34, 211, 255, 0.14), rgba(34, 211, 255, 0.08));
    color: #e8fbff;
    font-size: 0.8rem;
    font-weight: 900;
    letter-spacing: 0.02em;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

body.game-page-body #result-chip-area {
    display: block;
    flex: none;
    min-height: auto;
    max-height: none;
    overflow: visible;
    margin-top: 0.15rem;
}

body.game-page-body .result-chip-grid {
    display: grid;
    grid-auto-flow: column;
    grid-template-rows: repeat(6, minmax(0, 1fr));
    grid-auto-columns: minmax(40px, 40px);
    gap: 0.38rem;
    width: max-content;
    max-width: 100%;
    margin-top: 0;
    padding: 0.55rem 0.1rem 0.15rem;
    overflow-x: auto;
    overflow-y: hidden;
}

body.game-page-body .result-chip {
    position: relative;
    aspect-ratio: 1;
    width: 100%;
    height: auto;
    min-width: 0;
    border: 1px solid rgba(255, 255, 255, 0.12);
    font-size: 0.56rem;
    font-weight: 900;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.22),
        0 10px 16px rgba(0, 0, 0, 0.16);
    transition: transform 0.18s ease, filter 0.18s ease, box-shadow 0.18s ease;
}

body.game-page-body .result-chip::before {
    content: "";
    position: absolute;
    inset: 8% 12% auto 12%;
    height: 28%;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    filter: blur(1px);
    pointer-events: none;
}

body.game-page-body .result-chip:hover {
    transform: translateY(-1px) scale(1.05);
    filter: brightness(1.08);
}

body.game-page-body .result-chip.current-result {
    outline: 2px solid rgba(255, 255, 255, 0.95);
    outline-offset: 1px;
    box-shadow:
        0 0 0 3px rgba(34, 211, 255, 0.18),
        0 0 18px rgba(34, 211, 255, 0.45),
        0 10px 18px rgba(0, 0, 0, 0.22);
}

body.game-page-body .result-legend {
    margin-top: 0.9rem;
    padding-top: 0.8rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    justify-content: center;
    gap: 0.55rem;
}

body.game-page-body .result-legend span {
    min-height: 28px;
    padding: 0 0.72rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.03));
    color: rgba(224, 237, 245, 0.92);
    font-size: 0.77rem;
    font-weight: 800;
}

body.game-page-body .distribution-card {
    padding: 1.2rem;
    border: 1px solid rgba(77, 111, 148, 0.48);
    border-radius: 18px;
    background:
        radial-gradient(circle at top right, rgba(35, 118, 255, 0.16), transparent 30%),
        radial-gradient(circle at bottom left, rgba(34, 211, 255, 0.08), transparent 26%),
        linear-gradient(180deg, rgba(25, 31, 43, 0.97), rgba(18, 24, 34, 0.99));
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.04),
        0 18px 34px rgba(0, 0, 0, 0.18);
}

body.game-page-body .distribution-layout {
    align-items: center;
    gap: 1.1rem;
    padding-top: 0.4rem;
}

body.game-page-body .distribution-list div {
    min-height: 38px;
    padding: 0.56rem 0.8rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.03));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

body.game-page-body .distribution-list strong {
    font-size: 0.92rem;
}

body.game-page-body .distribution-list span {
    color: #dbe9f3;
}

@media (max-width: 1180px) {
    body.game-page-body .result-chip-grid {
        grid-auto-columns: minmax(34px, 34px);
        gap: 0.3rem;
    }
}

@media (max-width: 760px) {
    body.game-page-body .results-card,
    body.game-page-body .distribution-card {
        padding: 1rem;
    }

    body.game-page-body .result-chip-grid {
        grid-auto-columns: minmax(30px, 30px);
        gap: 0.28rem;
    }
}

@media (max-width: 520px) {
    body.game-page-body .analysis-card-header {
        align-items: flex-start;
        flex-direction: column;
    }

    body.game-page-body .results-table-badge {
        min-height: 30px;
        padding: 0 0.72rem;
    }

    body.game-page-body .result-chip-grid {
        grid-auto-columns: minmax(26px, 26px);
        gap: 0.24rem;
    }

    body.game-page-body .result-chip {
        font-size: 0.52rem;
    }
}

/* Risk Zone and Max Line */
.tie-chart-risk-zone { fill: rgba(255, 0, 85, 0.08); stroke: rgba(255, 0, 85, 0.4); stroke-width: 1px; stroke-dasharray: 4; }
.tie-chart-max-line { stroke: #ff0055; stroke-width: 1.5px; stroke-dasharray: 6 4; opacity: 0.9; }
.tie-chart-max-label { fill: #ff0055; font-family: 'Orbitron', sans-serif; font-size: 10px; font-weight: 700; letter-spacing: 1px; opacity: 1; filter: drop-shadow(0 0 5px rgba(255, 0, 85, 0.5)); }

/* --- Efeitos de Bordas Animadas (Premium Border Effects) --- */

/* Border Draw - Efeito de desenho na borda ao passar o mouse */
.draw-border,
.fx-border-draw,
.game-card,
.ticker-item {
    position: relative !important;
}

.draw-border::before, .draw-border::after,
.fx-border-draw::before, .fx-border-draw::after,
.game-card::before, .game-card::after,
.ticker-item::before, .ticker-item::after {
    content: '';
    position: absolute;
    width: 0;
    height: 0;
    border: 2px solid transparent;
    box-sizing: border-box;
    pointer-events: none;
    z-index: 5;
    border-radius: inherit;
    inset: 0 auto auto 0;
}

.draw-border::before,
.fx-border-draw::before,
.game-card::before,
.ticker-item::before {
    top: 0;
    left: 0;
    border-top-color: var(--accent-color);
    border-right-color: var(--accent-color);
    transition: width 0.25s ease-out, height 0.25s ease-out 0.25s;
}

.draw-border::after,
.fx-border-draw::after,
.game-card::after,
.ticker-item::after {
    bottom: 0;
    right: 0;
    border-bottom-color: var(--accent-color);
    border-left-color: var(--accent-color);
    transition: width 0.25s ease-out 0.5s, height 0.25s ease-out 0.75s;
}

.draw-border:hover::before,
.fx-border-draw:hover::before,
.game-card:hover::before,
.ticker-item:hover::before,
.draw-border:hover::after,
.fx-border-draw:hover::after,
.game-card:hover::after,
.ticker-item:hover::after {
    width: 100%;
    height: 100%;
}

/* Perpetual Draw - Borda giratória infinita (usar com moderação em elementos chave) */
.perpetual-draw {
    position: relative;
    z-index: 0;
    overflow: hidden;
}

.perpetual-draw::before {
    content: '';
    position: absolute;
    z-index: -2;
    left: -50%;
    top: -50%;
    width: 200%;
    height: 200%;
    background-color: transparent;
    background-repeat: no-repeat;
    background-size: 50% 50%, 50% 50%;
    background-position: 0 0, 100% 0, 100% 100%, 0 100%;
    background-image: linear-gradient(var(--accent-color), var(--accent-color)), 
                      linear-gradient(var(--accent-secondary), var(--accent-secondary)), 
                      linear-gradient(var(--accent-color), var(--accent-color)), 
                      linear-gradient(var(--accent-secondary), var(--accent-secondary));
    animation: rotate-border 4s linear infinite;
}

.perpetual-draw::after {
    content: '';
    position: absolute;
    z-index: -1;
    left: 2px;
    top: 2px;
    width: calc(100% - 4px);
    height: calc(100% - 4px);
    background: var(--bg-color);
    border-radius: inherit;
}

@keyframes rotate-border {
    100% { transform: rotate(1turn); }
}

/* Corner Sweep - Brilho que percorre o card ao passar o mouse */
.corner-sweep,
.fx-border-sweep,
.btn-glow,
.course-video-frame {
    position: relative !important;
    overflow: hidden !important;
}

.corner-sweep::after,
.fx-border-sweep::after,
.btn-glow::after,
.course-video-frame::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -60%;
    width: 20%;
    height: 200%;
    background: rgba(255, 255, 255, 0.25);
    transform: rotate(30deg);
    transition: all 0.6s cubic-bezier(0.19, 1, 0.22, 1);
    pointer-events: none;
    z-index: 10;
}

.corner-sweep:hover::after,
.fx-border-sweep:hover::after,
.btn-glow:hover::after,
.course-video-frame:hover::after {
    left: 140%;
    opacity: 0;
}


/* --- Dashboard TITAN IA --- */
.titan-dashboard {
    background: linear-gradient(135deg, rgba(13, 20, 26, 0.7) 0%, rgba(5, 10, 15, 0.9) 100%);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(0, 243, 255, 0.15);
    border-radius: 24px;
    padding: 2.5rem;
    width: 100%;
    margin-bottom: 2rem;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), 0 0 30px rgba(0, 243, 255, 0.05);
    position: relative;
    overflow: hidden;
}

.titan-dashboard::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 0% 0%, rgba(0, 243, 255, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 100% 100%, rgba(112, 0, 255, 0.05) 0%, transparent 50%);
    pointer-events: none;
}

.titan-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 3rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.titan-title-group h2 {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.8rem;
    font-weight: 900;
    margin: 0;
    letter-spacing: 4px;
    background: linear-gradient(90deg, #fff, #00f3ff);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-transform: uppercase;
}

.titan-title-group span {
    font-size: 0.75rem;
    color: #566a7a;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: 0.5rem;
    display: block;
    font-weight: 700;
}

.btn-trocar-ia {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(0, 243, 255, 0.3);
    color: #00f3ff;
    padding: 0.6rem 1.4rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 800;
    font-family: 'Orbitron', sans-serif;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn-trocar-ia:hover {
    background: rgba(0, 243, 255, 0.1);
    border-color: #00f3ff;
    box-shadow: 0 0 20px rgba(0, 243, 255, 0.2);
    transform: translateY(-2px);
}

.titan-stats-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.titan-stat-item {
    position: relative;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    transition: all 0.3s ease;
}

.titan-stat-item:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.1);
}

.titan-stat-item small {
    display: block;
    font-size: 0.65rem;
    color: #566a7a;
    margin-bottom: 0.8rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

.titan-stat-box {
    font-size: 2.2rem;
    font-weight: 900;
    font-family: 'Orbitron', sans-serif;
    color: #fff;
    line-height: 1;
}

#titan-win { color: #1bb56c; text-shadow: 0 0 20px rgba(27, 181, 108, 0.3); }
#titan-g1 { color: #1265d8; text-shadow: 0 0 20px rgba(18, 101, 216, 0.3); }
#titan-g2 { color: #7000ff; text-shadow: 0 0 20px rgba(112, 0, 255, 0.3); }
#titan-loss { color: #ff3b30; text-shadow: 0 0 20px rgba(255, 59, 48, 0.3); }

.titan-signal-area {
    min-height: 180px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 20px;
    border: 1px solid rgba(0, 243, 255, 0.1);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.titan-signal-area::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(0deg, transparent 0%, rgba(0, 243, 255, 0.03) 50%, transparent 100%);
    background-size: 100% 4px;
    pointer-events: none;
}

.titan-scanner-card {
    width: 100%;
    text-align: center;
    padding: 3rem 1.5rem;
    position: relative;
    z-index: 1;
}

.titan-scanner-visual {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.ai-spinner {
    width: 60px;
    height: 60px;
    border: 3px solid rgba(0, 243, 255, 0.1);
    border-top: 3px solid #00f3ff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    box-shadow: 0 0 15px rgba(0, 243, 255, 0.2);
}

.ai-spinner-alert {
    border-top-color: #f2b01e;
    box-shadow: 0 0 20px rgba(242, 176, 30, 0.4);
}

.titan-scanner-visual h3 {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.2rem;
    color: #fff;
    letter-spacing: 2px;
    margin: 0;
    text-transform: uppercase;
    animation: pulse-text 2s infinite;
}

.titan-scanner-track {
    display: flex;
    justify-content: center;
    gap: 0.8rem;
    margin-bottom: 2rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 12px;
}

.scan-token {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.9rem;
    font-weight: 700;
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.1);
    animation: scan-token-in 0.5s ease-out forwards;
}

@keyframes scan-token-in {
    from { opacity: 0; transform: scale(0.8); }
    to { opacity: 1; transform: scale(1); }
}

.titan-scanner-footer {
    font-size: 0.8rem;
    color: #566a7a;
    font-weight: 600;
    letter-spacing: 1px;
}

/* Signal Card Premium */
.titan-dashboard .signal-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.03) 0%, rgba(255, 255, 255, 0.01) 100%);
    border: 1px solid rgba(0, 243, 255, 0.3);
    border-radius: 20px;
    padding: 2rem;
    width: 100%;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3), inset 0 0 20px rgba(0, 243, 255, 0.05);
    animation: signal-entry 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes signal-entry {
    from { opacity: 0; transform: scale(0.95) translateY(20px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

.titan-dashboard .signal-status-group {
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
}

.titan-dashboard .signal-status {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.85rem;
    padding: 0.5rem 1.5rem;
    background: rgba(0, 243, 255, 0.15);
    color: #00f3ff;
    border-radius: 99px;
    font-weight: 900;
    letter-spacing: 2px;
}

.titan-dashboard .signal-flow-line {
    font-size: 2.2rem;
    justify-content: center;
    gap: 1.5rem;
    display: flex;
    align-items: center;
}

.titan-dashboard .signal-token-target {
    transform: scale(1.3);
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.1);
}

.titan-dashboard .signal-equals {
    font-size: 1.8rem;
    color: rgba(255, 255, 255, 0.2);
}

.titan-dashboard .signal-flow-results {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.titan-dashboard .signal-flow-meta {
    font-size: 0.9rem;
    font-weight: 800;
    color: #f2b01e;
    margin-bottom: 1rem;
}

@keyframes pulse-text {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.7; transform: scale(0.98); }
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.titan-history-section {
    margin-top: 2rem;
}

.tab-bar .tab-item {
    height: 74px;
    justify-content: center;
    gap: 5px;
}

.tab-bar .tab-item .icon,
.tab-bar .central-bg .icon {
    width: 34px;
    height: 34px;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    text-align: center;
    font-style: normal;
}

.tab-bar .tab-item span {
    min-height: 12px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    text-align: center;
}

.tab-bar .tab-item.central {
    top: -14px;
}

.tab-bar .tab-item.central span {
    margin-top: 0;
}

.tab-bar .central-bg {
    flex: 0 0 auto;
}

.tab-bar .tab-item-youtube .icon::before {
    width: 28px;
    height: 18px;
    min-width: 0;
    min-height: 0;
    padding: 0;
    margin: 0;
    border-radius: 7px;
    line-height: 1;
}

@media (max-width: 560px) {
    .tab-bar {
        min-height: 64px;
        align-items: center;
    }

    .tab-bar .tab-item {
        height: 52px;
        padding: 0 1px;
        display: grid;
        grid-template-rows: 34px 12px;
        align-items: center;
        justify-items: center;
        gap: 0;
    }

    .tab-bar .tab-item .icon,
    .tab-bar .central-bg .icon {
        width: 34px;
        height: 34px;
        font-size: 1.18rem;
        margin: 0;
        display: flex;
        align-items: center;
        justify-content: center;
        line-height: 1;
    }

    .tab-bar .tab-item.central {
        top: 0;
    }

    .tab-bar .central-bg {
        width: 36px;
        height: 36px;
        border-width: 2px;
        box-shadow: 0 0 14px rgba(0, 243, 255, 0.38);
        align-self: center;
        justify-self: center;
    }

    .tab-bar .tab-item.central span {
        margin-top: 0;
    }

    .tab-bar .tab-item span {
        width: 100%;
        line-height: 1;
        min-height: 10px;
        display: flex;
        align-items: center;
        justify-content: center;
        transform: none;
        font-size: 0.48rem;
        letter-spacing: 0.35px;
    }

    .tab-bar .tab-item-youtube .icon::before {
        width: 28px;
        height: 18px;
        border-radius: 6px;
        font-size: 0.62rem;
        display: flex;
        align-items: center;
        justify-content: center;
    }
}

.tab-bar .tab-item-youtube .icon {
    position: relative;
    overflow: visible;
    color: transparent !important;
    font-size: 0;
}

.tab-bar .tab-item-youtube .icon::before {
    content: '' !important;
    display: block;
    width: 28px;
    height: 18px;
    min-width: 0;
    min-height: 0;
    padding: 0;
    margin: 0;
    border-radius: 6px;
    background: linear-gradient(180deg, #ff4d5f, #c40020);
    box-shadow: 0 0 16px rgba(255, 45, 85, 0.28);
}

.tab-bar .tab-item-youtube .icon::after {
    content: '';
    position: absolute;
    left: 50%;
    top: 50%;
    width: 0;
    height: 0;
    transform: translate(-36%, -50%);
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
    border-left: 7px solid #fff;
}

@media (max-width: 768px) {
    .game-provider-group {
        margin-bottom: 1.5rem;
    }

    .provider-heading {
        align-items: flex-start;
        margin-bottom: 0.7rem;
        padding-bottom: 0.45rem;
    }

    .provider-heading h3 {
        font-size: 0.9rem;
        text-align: right;
    }

    .provider-games-grid,
    #dashboard .provider-games-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 0.6rem;
        margin-bottom: 0;
    }

    .provider-games-grid .game-card {
        min-height: 0;
        padding: 0.65rem 0.7rem;
        border-radius: 14px;
        display: grid;
        grid-template-columns: 72px minmax(0, 1fr);
        align-items: center;
        gap: 0.75rem;
        text-align: left;
    }

    .provider-games-grid .game-card:hover {
        transform: none;
    }

    .provider-games-grid .game-logo-frame {
        width: 72px;
        height: 52px;
        margin: 0;
        padding: 0.45rem;
        border-radius: 10px;
    }

    .provider-games-grid .game-logo {
        max-width: 100%;
        max-height: 42px;
    }

    .provider-games-grid .game-info {
        min-width: 0;
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: center;
        column-gap: 0.55rem;
        row-gap: 0.15rem;
    }

    .provider-games-grid .game-info h4 {
        margin: 0;
        font-size: 0.78rem;
        line-height: 1.15;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .provider-games-grid .game-info p {
        grid-column: 1 / 2;
        margin: 0;
        font-size: 0.68rem;
        line-height: 1.2;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .provider-games-grid .game-info .btn-glow {
        grid-row: 1 / 3;
        grid-column: 2 / 3;
        width: auto;
        min-width: 34px;
        height: 34px;
        padding: 0;
        border-radius: 999px;
        font-size: 0;
        letter-spacing: 0;
    }

    .provider-games-grid .game-info .btn-glow::before {
        content: '>';
        font-size: 1rem;
        line-height: 1;
    }

    .provider-games-grid .game-badge {
        top: 6px;
        right: 6px;
        padding: 2px 6px;
        font-size: 0.48rem;
        border-radius: 999px;
    }
}

/* Final hero brand layer */
body.logged-in .ui-wrapper > nav:first-of-type .logo {
    opacity: 0;
    pointer-events: none;
}

body.logged-in .ui-wrapper > nav:first-of-type {
    padding-bottom: 0.75rem;
}

body.logged-in .ui-wrapper > nav:first-of-type .nav-links {
    margin-left: auto;
}

body.logged-in main {
    padding-top: 0.6rem;
}

.hero-content {
    position: relative;
}

.hero-content::before {
    content: "";
    position: absolute;
    left: -1.2rem;
    top: 0.15rem;
    width: 3px;
    height: 7.4rem;
    border-radius: 999px;
    background: linear-gradient(180deg, #00f3ff, rgba(159, 77, 255, 0.9));
    box-shadow: 0 0 24px rgba(0, 243, 255, 0.58);
}

.hero-brand {
    gap: 0.22rem;
    margin-bottom: 1.25rem;
}

.hero-main-word {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    column-gap: 0.12em;
    line-height: 0.9;
}

.hero-community {
    color: rgba(241, 247, 255, 0.86);
    font-size: clamp(1.05rem, 2.05vw, 1.65rem);
    letter-spacing: 0.22em;
    line-height: 1;
    text-shadow: 0 0 18px rgba(0, 243, 255, 0.22);
}

.hero-cyber,
.hero-bot {
    font-size: clamp(4rem, 8vw, 6.9rem);
    letter-spacing: 0.045em;
}

.hero-cyber {
    color: #f4feff;
    text-shadow:
        0 0 10px rgba(255, 255, 255, 0.75),
        0 0 28px rgba(0, 243, 255, 0.52);
}

.hero-bot {
    color: #00f3ff;
    background: linear-gradient(180deg, #ffffff 0%, #00f3ff 45%, #8f47ff 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: none;
    filter: drop-shadow(0 0 16px rgba(0, 243, 255, 0.58));
}

.subtitle {
    max-width: 650px;
    color: rgba(232, 240, 247, 0.74);
    font-size: 1.12rem;
    margin-bottom: 2.1rem;
}

.session-timer {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.65rem 0.95rem;
    border: 1px solid rgba(0, 243, 255, 0.22);
    border-radius: 999px;
    background: rgba(0, 243, 255, 0.045);
    box-shadow: inset 0 0 18px rgba(0, 243, 255, 0.05);
}

.session-user-id {
    padding-left: 0.75rem;
    border-left: 1px solid rgba(255, 255, 255, 0.14);
}

@media (max-width: 768px) {
    body.logged-in .ui-wrapper > nav:first-of-type .logo {
        display: none;
    }

    body.logged-in .ui-wrapper > nav:first-of-type .nav-links {
        width: 100%;
        display: flex;
        gap: 0.65rem;
    }

    .hero-content {
        text-align: left;
        padding-left: 1rem;
    }

    .hero-content::before {
        left: 0;
        height: 5.9rem;
    }

    .hero-main-word {
        column-gap: 0.08em;
    }

    .hero-cyber,
    .hero-bot {
        font-size: clamp(2.7rem, 14vw, 4.4rem);
    }

    .session-timer {
        width: 100%;
        justify-content: space-between;
        border-radius: 14px;
    }
}

@media (max-width: 420px) {
    .hero-content {
        padding-left: 0.8rem;
    }

    .hero-community {
        letter-spacing: 0.14em;
    }

    .hero-cyber,
    .hero-bot {
        font-size: clamp(2.25rem, 13vw, 3.4rem);
    }
}

/* Desktop navigation final override */
@media (min-width: 769px) {
    body.logged-in {
        padding-bottom: 48px;
    }

    body.logged-in .tab-bar {
        position: sticky;
        top: 14px;
        left: auto;
        bottom: auto;
        transform: none;
        width: fit-content;
        max-width: calc(100vw - 4rem);
        min-height: 0;
        margin: -0.25rem auto 1.35rem;
        padding: 6px;
        gap: 4px;
        justify-content: center;
        border-radius: 16px;
        background: rgba(8, 14, 26, 0.78);
        border: 1px solid rgba(0, 243, 255, 0.14);
        box-shadow: 0 14px 34px rgba(0, 0, 0, 0.34);
        backdrop-filter: blur(16px);
    }

    body.logged-in .tab-bar .tab-item {
        height: 40px;
        min-width: 0;
        max-width: none;
        padding: 0 14px;
        flex-direction: row;
        gap: 8px;
        border-radius: 11px;
        color: rgba(231, 238, 246, 0.68);
    }

    body.logged-in .tab-bar .tab-item:hover,
    body.logged-in .tab-bar .tab-item.active {
        color: #061018;
        background: #00f3ff;
        box-shadow: 0 0 20px rgba(0, 243, 255, 0.22);
    }

    body.logged-in .tab-bar .tab-item .icon,
    body.logged-in .tab-bar .central-bg .icon {
        width: 18px;
        height: 18px;
        font-size: 1rem;
        margin: 0;
        filter: none;
    }

    body.logged-in .tab-bar .tab-item:hover .icon,
    body.logged-in .tab-bar .tab-item.active .icon {
        transform: none;
        filter: none;
    }

    body.logged-in .tab-bar .tab-item span {
        min-height: 0;
        font-size: 0.66rem;
        letter-spacing: 0.08em;
        line-height: 1;
    }

    body.logged-in .tab-bar .tab-item.central {
        top: 0;
    }

    body.logged-in .tab-bar .central-bg {
        width: 18px;
        height: 18px;
        border: 0;
        border-radius: 0;
        background: transparent;
        box-shadow: none;
    }

    body.logged-in .tab-bar .central-bg .icon {
        color: currentColor;
    }

    body.logged-in .tab-bar .tab-item-youtube .icon::before {
        width: 19px;
        height: 13px;
        border-radius: 4px;
    }

    body.logged-in .tab-bar .tab-item-youtube .icon::after {
        border-top-width: 3px;
        border-bottom-width: 3px;
        border-left-width: 5px;
    }
}

/* Desktop sidebar navigation - final winning layer */
@media (min-width: 769px) {
    body.logged-in {
        padding-bottom: 0;
    }

    body.logged-in .ui-wrapper {
        padding-left: 7.5rem;
    }

    body.logged-in .tab-bar {
        position: fixed;
        top: 50%;
        left: 1.35rem;
        bottom: auto;
        transform: translateY(-50%);
        width: 82px;
        max-width: 82px;
        min-height: 0;
        margin: 0;
        padding: 12px 8px;
        display: flex;
        flex-direction: column;
        gap: 8px;
        border-radius: 22px;
        background: rgba(8, 14, 26, 0.82);
        border: 1px solid rgba(0, 243, 255, 0.16);
        box-shadow: 0 18px 40px rgba(0, 0, 0, 0.38);
        backdrop-filter: blur(18px);
    }

    body.logged-in .tab-bar .tab-item {
        width: 100%;
        height: 58px;
        min-width: 0;
        max-width: none;
        padding: 7px 4px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 5px;
        border-radius: 15px;
        color: rgba(231, 238, 246, 0.68);
    }

    body.logged-in .tab-bar .tab-item:hover,
    body.logged-in .tab-bar .tab-item.active {
        color: #061018;
        background: #00f3ff;
        box-shadow: 0 0 22px rgba(0, 243, 255, 0.24);
    }

    body.logged-in .tab-bar .tab-item .icon,
    body.logged-in .tab-bar .central-bg .icon {
        width: 22px;
        height: 22px;
        font-size: 1.15rem;
        margin: 0;
        filter: none;
    }

    body.logged-in .tab-bar .tab-item:hover .icon,
    body.logged-in .tab-bar .tab-item.active .icon {
        transform: none;
        filter: none;
    }

    body.logged-in .tab-bar .tab-item span {
        width: 100%;
        min-height: 0;
        display: block;
        font-size: 0.54rem;
        letter-spacing: 0.08em;
        line-height: 1;
        text-align: center;
        white-space: nowrap;
    }

    body.logged-in .tab-bar .tab-item.central {
        top: 0;
    }

    body.logged-in .tab-bar .central-bg {
        width: 22px;
        height: 22px;
        border: 0;
        border-radius: 0;
        background: transparent;
        box-shadow: none;
    }

    body.logged-in .tab-bar .central-bg .icon {
        color: currentColor;
    }

    body.logged-in .tab-bar .tab-item-youtube .icon::before {
        width: 21px;
        height: 14px;
        border-radius: 4px;
    }

    body.logged-in .tab-bar .tab-item-youtube .icon::after {
        border-top-width: 3px;
        border-bottom-width: 3px;
        border-left-width: 5px;
    }
}

/* Layout refinement pass */
@media (min-width: 769px) {
    body.logged-in {
        padding-bottom: 0;
    }

    body.logged-in .ui-wrapper {
        max-width: 1480px;
        padding-left: 8.25rem;
        padding-right: 2.4rem;
    }

    body.logged-in .tab-bar {
        position: fixed;
        top: 50%;
        left: 1.25rem;
        bottom: auto;
        transform: translateY(-50%);
        width: 76px;
        max-width: 76px;
        margin: 0;
        padding: 10px 8px;
        flex-direction: column;
        align-items: stretch;
        gap: 7px;
        border-radius: 22px;
        background: rgba(7, 13, 24, 0.86);
        border: 1px solid rgba(0, 243, 255, 0.14);
        box-shadow: 0 20px 48px rgba(0, 0, 0, 0.38);
        backdrop-filter: blur(18px);
        transition: width 0.22s ease, max-width 0.22s ease, box-shadow 0.22s ease;
    }

    body.logged-in .tab-bar:hover {
        width: 176px;
        max-width: 176px;
        box-shadow: 0 22px 58px rgba(0, 0, 0, 0.44), 0 0 24px rgba(0, 243, 255, 0.08);
    }

    body.logged-in .tab-bar .tab-item {
        position: relative;
        width: 100%;
        height: 50px;
        min-width: 0;
        max-width: none;
        padding: 0 12px;
        flex-direction: row;
        justify-content: flex-start;
        gap: 12px;
        overflow: hidden;
        border-radius: 15px;
        color: rgba(232, 239, 247, 0.72);
    }

    body.logged-in .tab-bar .tab-item::before {
        content: attr(data-desktop-icon);
        flex: 0 0 34px;
        width: 34px;
        height: 34px;
        display: grid;
        place-items: center;
        border-radius: 11px;
        color: #00f3ff;
        background: rgba(0, 243, 255, 0.08);
        border: 1px solid rgba(0, 243, 255, 0.12);
        font-family: 'Orbitron', sans-serif;
        font-size: 0.7rem;
        font-weight: 800;
        letter-spacing: 0.04em;
    }

    body.logged-in .tab-bar .tab-item .icon,
    body.logged-in .tab-bar .central-bg {
        display: none;
    }

    body.logged-in .tab-bar .tab-item span {
        width: auto;
        min-width: 88px;
        opacity: 0;
        transform: translateX(-5px);
        transition: opacity 0.18s ease, transform 0.18s ease;
        font-size: 0.68rem;
        letter-spacing: 0.08em;
        text-align: left;
        white-space: nowrap;
    }

    body.logged-in .tab-bar:hover .tab-item span {
        opacity: 1;
        transform: translateX(0);
    }

    body.logged-in .tab-bar .tab-item:hover,
    body.logged-in .tab-bar .tab-item.active {
        color: #f8fdff;
        background: rgba(0, 243, 255, 0.1);
        box-shadow: inset 3px 0 0 #00f3ff;
    }

    body.logged-in .tab-bar .tab-item:hover::before,
    body.logged-in .tab-bar .tab-item.active::before {
        color: #061018;
        background: #00f3ff;
        box-shadow: 0 0 20px rgba(0, 243, 255, 0.34);
    }

    body.logged-in main {
        min-height: auto;
        padding-top: 0.2rem;
        margin-bottom: 1.25rem;
    }

    body.logged-in .hero-content {
        max-width: 980px;
        display: grid;
        grid-template-columns: minmax(320px, 0.9fr) minmax(420px, 1.1fr);
        align-items: center;
        gap: 1.6rem;
    }

    body.logged-in .hero-brand {
        margin-bottom: 0;
    }

    body.logged-in .hero-community {
        font-size: 0.92rem;
    }

    body.logged-in .hero-cyber,
    body.logged-in .hero-bot {
        font-size: clamp(2.9rem, 5.4vw, 5rem);
    }

    body.logged-in .subtitle {
        grid-column: 2;
        grid-row: 1;
        align-self: end;
        margin: 0;
        max-width: 58ch;
        font-size: 1rem;
    }

    body.logged-in .session-timer {
        grid-column: 1;
        width: max-content;
        margin-top: 0.9rem;
    }

    .command-strip {
        grid-column: 2;
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 0.7rem;
        align-self: start;
        margin-top: 1rem;
    }

    .command-strip-item {
        min-height: 76px;
        padding: 0.8rem 0.9rem;
        border-radius: 12px;
        background: rgba(255, 255, 255, 0.045);
        border: 1px solid rgba(255, 255, 255, 0.075);
        box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
    }

    .command-strip-item span {
        display: block;
        margin-bottom: 0.35rem;
        color: rgba(232, 239, 247, 0.58);
        font-size: 0.68rem;
        font-weight: 800;
        text-transform: uppercase;
        letter-spacing: 0.08em;
    }

    .command-strip-item strong {
        color: #f8fdff;
        font-family: 'Orbitron', sans-serif;
        font-size: 1.35rem;
        line-height: 1;
    }

    .command-strip-item.is-alert strong {
        color: #ff7b7b;
    }

    .dashboard-section {
        padding-top: 1rem;
    }

    .game-provider-group,
    .chart-card,
    .suggestion-panel,
    .course-card {
        border-radius: 12px;
        background: rgba(255, 255, 255, 0.04);
        border-color: rgba(255, 255, 255, 0.08);
        box-shadow: 0 16px 38px rgba(0, 0, 0, 0.24);
    }

    .game-card {
        border-radius: 12px;
        background: rgba(6, 14, 24, 0.72);
        border-color: rgba(255, 255, 255, 0.075);
        box-shadow: none;
    }

    .game-card:hover {
        border-color: rgba(0, 243, 255, 0.34);
        transform: translateY(-3px);
        box-shadow: 0 18px 34px rgba(0, 0, 0, 0.28);
    }
}

@media (max-width: 768px) {
    .command-strip {
        display: none;
    }
}

/* Premium launch modal */
.launch-banner {
    z-index: 20000;
    background: rgba(15, 23, 42, 0.48);
    backdrop-filter: blur(8px);
    padding: 20px;
    box-sizing: border-box;
}

.launch-banner-card {
    width: min(100%, 640px);
    padding: 28px;
    border-radius: 14px;
    border: 1px solid #7f8995;
    background: #c7cdd4;
    color: #000;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.26);
}

.launch-banner-card::before {
    border-top: 0;
    height: 4px;
    background: linear-gradient(90deg, #0ea5e9, #22c55e);
    opacity: 1;
}

.launch-banner-top {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 0.85rem;
    margin-bottom: 1.35rem;
}

.launch-banner-mark {
    width: 58px;
    height: 58px;
    margin: 0;
    border-radius: 14px;
    background: #aeb8c3;
    border: 1px solid #7f8995;
    color: #075985;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55);
}

.launch-banner-kicker {
    display: block;
    margin-bottom: 0.25rem;
    color: #075985;
    letter-spacing: 0.08em;
}

.launch-banner-status {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    color: #111827;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.launch-banner-status::before {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 999px;
    background: #22c55e;
    box-shadow: 0 0 0 5px rgba(34, 197, 94, 0.14);
}

.launch-banner-card h2,
.launch-banner-card p,
.launch-banner-actions,
.launch-banner-points,
.launch-banner-foot {
    position: relative;
    z-index: 1;
}

.launch-banner-card h2 {
    max-width: 16ch;
    margin: 0 3rem 0.8rem 0;
    color: #000;
    font-size: clamp(1.55rem, 4vw, 2.1rem);
    line-height: 1.08;
    letter-spacing: 0;
}

.launch-banner-card p {
    max-width: 58ch;
    margin-bottom: 1.2rem;
    color: #111827;
    font-size: 1rem;
    line-height: 1.55;
}

.launch-banner-points {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
    margin-bottom: 1.35rem;
}

.launch-banner-points span {
    padding: 0.42rem 0.7rem;
    border-radius: 999px;
    color: #111827;
    background: #b7c0ca;
    border: 1px solid #8f9aa6;
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.launch-banner-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 1rem;
}

.launch-banner-actions .btn-glow {
    min-width: 148px;
    border-radius: 10px;
    border: 1px solid #0ea5e9;
    background: #d7dde4;
    color: #075985;
    box-shadow: none;
    text-transform: uppercase;
}

.launch-banner-actions .btn-glow:hover {
    background: #0ea5e9;
    color: #fff;
    box-shadow: 0 12px 26px rgba(14, 165, 233, 0.22);
}

.launch-banner-foot {
    display: block;
    color: #4b5563;
    font-size: 0.74rem;
}

.launch-banner-close {
    z-index: 2;
    top: 1rem;
    right: 1rem;
    width: 38px;
    height: 38px;
    color: #111827;
    border-color: #8f9aa6;
    background: #b7c0ca;
    box-shadow: none;
}

.launch-banner-close:hover {
    color: #fff;
    background: #111827;
    box-shadow: none;
}

@media (max-width: 560px) {
    .launch-banner {
        align-items: flex-end;
        padding: 0.7rem;
    }

    .launch-banner-card {
        padding: 1.25rem;
        border-radius: 18px;
    }

    .launch-banner-card h2 {
        max-width: 11ch;
        font-size: 1.55rem;
    }

    .launch-banner-card p {
        font-size: 0.92rem;
    }

    .launch-banner-actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .launch-banner-actions .btn-glow {
        min-width: 0;
        width: 100%;
        padding-inline: 0.75rem;
    }
}

/* Final logged-in home compact layout */
body.logged-in main#home {
    min-height: 0 !important;
    padding-top: 0 !important;
    margin: 0 0 0.85rem !important;
}

body.logged-in main#home .hero-content {
    max-width: none !important;
    min-height: 0 !important;
    padding: 0.85rem 1rem !important;
    border: 1px solid rgba(0, 243, 255, 0.1);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.028);
}

body.logged-in main#home .hero-content::before {
    height: calc(100% - 1.2rem);
    top: 0.6rem;
}

body.logged-in main#home .hero-brand {
    display: none !important;
}

body.logged-in main#home .subtitle {
    grid-column: auto !important;
    grid-row: auto !important;
    margin: 0 !important;
    max-width: 68ch !important;
    font-size: 0.95rem !important;
    line-height: 1.45 !important;
}

body.logged-in main#home .session-timer {
    margin-top: 0 !important;
}

@media (min-width: 769px) {
    body.logged-in main#home .hero-content {
        display: grid;
        grid-template-columns: minmax(300px, 0.9fr) minmax(360px, 1.1fr);
        gap: 1rem;
        align-items: center;
    }

    body.logged-in main#home .command-strip {
        margin-top: 0;
    }
}

@media (max-width: 768px) {
    body.logged-in main#home .hero-content {
        display: grid !important;
        gap: 0.75rem;
        padding-left: 1rem !important;
    }

    body.logged-in main#home .subtitle {
        text-align: left;
    }
}
/* Absolute final: show compact logo when logged in */
body.logged-in main#home .hero-content h1.hero-brand,
body.logged-in main#home h1.hero-brand {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    grid-column: 1 / -1;
    margin: 0 0 0.25rem !important;
    gap: 0.12rem !important;
}

body.logged-in main#home h1.hero-brand .hero-main-word {
    line-height: 1;
}

body.logged-in main#home h1.hero-brand .hero-community {
    font-size: 0.72rem !important;
    letter-spacing: 0.16em !important;
}

body.logged-in main#home h1.hero-brand .hero-cyber,
body.logged-in main#home h1.hero-brand .hero-bot {
    font-size: clamp(1.8rem, 3.8vw, 2.85rem) !important;
    letter-spacing: 0.035em !important;
}

@media (min-width: 769px) {
    body.logged-in main#home .hero-content {
        grid-template-columns: minmax(260px, 0.62fr) minmax(300px, 0.85fr) minmax(360px, 1.15fr) !important;
    }

    body.logged-in main#home .hero-content h1.hero-brand {
        grid-column: 1 !important;
        grid-row: 1 / 3 !important;
        margin: 0 !important;
    }

    body.logged-in main#home .subtitle,
    body.logged-in main#home .session-timer {
        grid-column: 2 !important;
    }

    body.logged-in main#home .command-strip {
        grid-column: 3 !important;
    }
}
/* Crash games keep a compact list layout on every viewport. */
.crash-games-grid,
#dashboard .crash-games-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.7rem;
    margin-bottom: 0;
}

.crash-games-grid .game-card {
    min-height: 0;
    padding: 0.68rem 0.72rem;
    border-radius: 14px;
    display: grid;
    grid-template-columns: 78px minmax(0, 1fr);
    align-items: center;
    gap: 0.78rem;
    text-align: left;
    background: rgba(8, 17, 28, 0.86);
}

.crash-games-grid .game-card:hover {
    transform: none;
}

.crash-games-grid .game-logo-frame {
    width: 78px;
    height: 52px;
    margin: 0;
    padding: 0.25rem;
    border-radius: 10px;
}

.crash-games-grid .game-logo {
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
    object-fit: cover;
    border-radius: 7px;
}

.crash-games-grid .game-info {
    min-width: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 38px;
    align-items: center;
    column-gap: 0.65rem;
    row-gap: 0.16rem;
}

.crash-games-grid .game-info h4 {
    margin: 0;
    font-size: 0.86rem;
    line-height: 1.14;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.crash-games-grid .game-info p {
    grid-column: 1 / 2;
    margin: 0;
    font-size: 0.72rem;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.crash-games-grid .game-info .btn-glow {
    grid-row: 1 / 3;
    grid-column: 2 / 3;
    width: 36px;
    min-width: 36px;
    height: 36px;
    padding: 0;
    border-radius: 999px;
    font-size: 0;
    letter-spacing: 0;
}

.crash-games-grid .game-info .btn-glow::before {
    content: '>';
    font-size: 1.08rem;
    line-height: 1;
}

.crash-games-grid .game-badge {
    top: 7px;
    right: 7px;
    padding: 2px 7px;
    font-size: 0.5rem;
    border-radius: 999px;
}

/* The dedicated games page uses the compact list layout for every provider. */
body.jogos-page .provider-games-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.7rem;
    margin-bottom: 0;
}

body.jogos-page .provider-games-grid .game-card {
    min-height: 0;
    padding: 0.68rem 0.72rem;
    border-radius: 14px;
    display: grid;
    grid-template-columns: 78px minmax(0, 1fr);
    align-items: center;
    gap: 0.78rem;
    text-align: left;
    background: rgba(8, 17, 28, 0.86);
}

body.jogos-page .provider-games-grid .game-card:hover {
    transform: none;
}

body.jogos-page .provider-games-grid .game-logo-frame {
    width: 78px;
    height: 52px;
    margin: 0;
    padding: 0.25rem;
    border-radius: 10px;
}

body.jogos-page .provider-games-grid .game-logo {
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
    object-fit: cover;
    border-radius: 7px;
}

body.jogos-page .provider-games-grid .game-info {
    min-width: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 38px;
    align-items: center;
    column-gap: 0.65rem;
    row-gap: 0.16rem;
}

body.jogos-page .provider-games-grid .game-info h4 {
    margin: 0;
    font-size: 0.86rem;
    line-height: 1.14;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

body.jogos-page .provider-games-grid .game-info p {
    grid-column: 1 / 2;
    margin: 0;
    font-size: 0.72rem;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

body.jogos-page .provider-games-grid .game-info .btn-glow {
    grid-row: 1 / 3;
    grid-column: 2 / 3;
    width: 36px;
    min-width: 36px;
    height: 36px;
    padding: 0;
    border-radius: 999px;
    font-size: 0;
    letter-spacing: 0;
}

body.jogos-page .provider-games-grid .game-info .btn-glow::before {
    content: '>';
    font-size: 1.08rem;
    line-height: 1;
}

body.jogos-page .provider-games-grid .game-badge {
    top: 7px;
    right: 7px;
    padding: 2px 7px;
    font-size: 0.5rem;
    border-radius: 999px;
}

body.jogos-page .game-provider-group {
    width: min(100%, 920px);
    margin: 0 auto 1rem;
    padding: 0.72rem;
    border-radius: 16px;
    border: 1px solid rgba(0, 243, 255, 0.12);
    background: rgba(7, 18, 29, 0.54);
}

body.jogos-page .provider-heading {
    min-height: 38px;
    margin-bottom: 0.62rem;
    padding: 0 0.12rem 0.55rem;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

body.jogos-page .provider-heading h3 {
    margin: 0;
    font-size: clamp(0.98rem, 1.7vw, 1.35rem);
    line-height: 1;
}

body.jogos-page .provider-heading span {
    font-size: 0.72rem;
    line-height: 1;
}

body.jogos-page .provider-games-grid {
    gap: 0.52rem;
}

body.jogos-page .provider-games-grid .game-card {
    min-height: 74px;
    padding: 0.58rem 0.7rem;
    grid-template-columns: 82px minmax(0, 1fr);
    gap: 0.74rem;
}

body.jogos-page .provider-games-grid .game-logo-frame {
    width: 82px;
    height: 50px;
}

body.jogos-page .provider-games-grid .game-info {
    grid-template-columns: minmax(0, 1fr) 40px;
}

@media (max-width: 640px) {
    body.jogos-page .game-provider-group {
        width: 100%;
        padding: 0.55rem;
        border-radius: 14px;
    }

    body.jogos-page .provider-heading {
        min-height: 34px;
        margin-bottom: 0.52rem;
    }

    body.jogos-page .provider-games-grid .game-card {
        min-height: 70px;
        grid-template-columns: 72px minmax(0, 1fr);
        gap: 0.62rem;
    }

    body.jogos-page .provider-games-grid .game-logo-frame {
        width: 72px;
        height: 48px;
    }

    body.jogos-page .provider-games-grid .game-info h4 {
        font-size: 0.78rem;
    }

    body.jogos-page .provider-games-grid .game-info p {
        font-size: 0.67rem;
    }
}


/* --- NOVO MENU CYBER SIDEBAR --- */
.cyber-sidebar {
    position: fixed;
    top: 50%;
    left: 1.5rem;
    transform: translateY(-50%);
    background: rgba(8, 14, 26, 0.85);
    border: 1px solid rgba(0, 243, 255, 0.15);
    border-radius: 20px;
    padding: 16px;
    z-index: 1000;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(16px);
    transition: all 0.3s ease;
}

.cyber-sidebar-inner {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.cyber-nav-item {
    display: flex;
    align-items: center;
    gap: 16px;
    text-decoration: none;
    color: rgba(231, 238, 246, 0.68);
    padding: 8px 16px 8px 8px;
    border-radius: 14px;
    transition: all 0.3s ease;
    background: transparent;
    cursor: pointer;
}

.cyber-nav-item:hover {
    background: rgba(0, 243, 255, 0.05);
    color: #fff;
}

.cyber-nav-item.active {
    background: rgba(0, 243, 255, 0.1);
    color: #00f3ff;
    box-shadow: inset 0 0 15px rgba(0, 243, 255, 0.1);
}

.cyber-nav-icon {
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    font-weight: 700;
    font-size: 13px;
    border: 1px solid rgba(0, 243, 255, 0.2);
    color: #00f3ff;
    transition: all 0.3s ease;
    font-family: 'Orbitron', sans-serif;
    background: rgba(0, 243, 255, 0.05);
}

.cyber-nav-item:hover .cyber-nav-icon {
    border-color: rgba(0, 243, 255, 0.4);
    box-shadow: 0 0 10px rgba(0, 243, 255, 0.2);
}

.cyber-nav-item.active .cyber-nav-icon {
    background: #00f3ff;
    border-color: #00f3ff;
    color: #081017;
    box-shadow: 0 0 15px rgba(0, 243, 255, 0.5);
}

.cyber-nav-label {
    font-weight: 600;
    font-size: 13px;
    letter-spacing: 0.05em;
    font-family: 'Inter', sans-serif;
    white-space: nowrap;
}

.logout-btn {
    margin-top: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 18px;
}
.logout-btn .cyber-nav-icon {
    color: #ff4757;
    border-color: rgba(255, 71, 87, 0.2);
    background: rgba(255, 71, 87, 0.05);
}
.logout-btn:hover {
    background: rgba(255, 71, 87, 0.05);
    color: #ff4757;
}
.logout-btn:hover .cyber-nav-icon {
    border-color: rgba(255, 71, 87, 0.4);
    box-shadow: 0 0 10px rgba(255, 71, 87, 0.2);
}

/* Esconder o menu antigo caso tenha sobrado */
.tab-bar { display: none !important; }

/* Mobile Adjustments */
@media (max-width: 768px) {
    .cyber-sidebar {
        top: auto;
        bottom: 0;
        left: 0;
        transform: none;
        width: 100%;
        border-radius: 20px 20px 0 0;
        border-left: none;
        border-right: none;
        border-bottom: none;
        padding: 12px 6px;
        overflow-x: auto;
    }
    
    .cyber-sidebar-inner {
        flex-direction: row;
        justify-content: flex-start;
        gap: 6px;
        width: max-content;
    }
    
    .cyber-nav-label {
        display: none;
    }
    
    .cyber-nav-item {
        padding: 6px;
        gap: 0;
    }

    .logout-btn {
        margin-top: 0;
        border-top: none;
        padding-top: 6px;
        border-left: 1px solid rgba(255, 255, 255, 0.05);
        margin-left: 4px;
        padding-left: 10px;
    }
    
    body.logged-in .ui-wrapper {
        padding-left: 0 !important;
        padding-bottom: 85px !important;
    }
}

@media (min-width: 769px) {
    body.logged-in .ui-wrapper {
        padding-left: 190px !important;
    }
}

/* Gradiente Premium de Cinza e Azul Escuro nos Backgrounds */
html, 
html body, 
html body.logged-in,
html body.logged-out,
html body.rank-page,
html body.rooms-page,
html body.aulas-page,
html body.gestao-page,
html body.plataforma-page,
html body.notifications-page,
html body.admin-page,
html body.editar-page,
html body .ui-wrapper,
html body.logged-in .ui-wrapper,
html body.logged-out .ui-wrapper {
    background: linear-gradient(135deg, #0a0f26 0%, #05070f 50%, #010206 100%) !important;
    background-color: #05070f !important; /* Fallback */
    background-attachment: fixed !important;
}

/* Transparência global de altíssima especificidade para os containers principais de todas as páginas */
html body.logged-in.rank-page .ui-wrapper,
html body.logged-out.rank-page .ui-wrapper,
html body.logged-in.rooms-page .ui-wrapper,
html body.logged-out.rooms-page .ui-wrapper,
html body.logged-in.aulas-page .ui-wrapper,
html body.logged-out.aulas-page .ui-wrapper,
html body.logged-in.gestao-page .ui-wrapper,
html body.logged-out.gestao-page .ui-wrapper,
html body.logged-in.plataforma-page .ui-wrapper,
html body.logged-out.plataforma-page .ui-wrapper,
html body.logged-in.notifications-page .ui-wrapper,
html body.logged-out.notifications-page .ui-wrapper,
html body.logged-in.admin-page .ui-wrapper,
html body.logged-out.admin-page .ui-wrapper,
html body.logged-in.editar-page .ui-wrapper,
html body.logged-out.editar-page .ui-wrapper,
html body.logged-in .ui-wrapper,
html body.logged-out .ui-wrapper,
html body.rank-page .ui-wrapper,
html body.rooms-page .ui-wrapper,
html body.aulas-page .ui-wrapper,
html body.gestao-page .ui-wrapper,
html body.plataforma-page .ui-wrapper,
html body.notifications-page .ui-wrapper,
html body.admin-page .ui-wrapper,
html body.editar-page .ui-wrapper,
html body.logged-in.rank-page .rank-page-main,
html body.logged-in.rooms-page main#rooms-content,
html body.logged-in.aulas-page .aulas-page-main,
html body.logged-in.plataforma-page main.plataforma-page-main,
html body.logged-in.gestao-page main.management-shell,
html body main,
html body .rank-page-main,
html body main#rooms-content,
html body .aulas-page-main,
html body main#home,
html body .dashboard-section,
html body .management-shell,
html body .plataforma-page-main,
html body .notification-main,
html body .admin-page-main,
html body .editar-page-main {
    background: transparent !important;
    background-color: transparent !important;
    background-image: none !important;
}

/* Ajustes premium de contraste para os textos e títulos diretamente sobre o gradiente */
body.logged-in #dashboard .section-title,
body.logged-in #dashboard .section-title *,
html body h2.section-title,
html body h2.section-title * {
    color: #ffffff !important;
    text-shadow: 0 4px 12px rgba(0, 0, 0, 0.5) !important;
}

body.logged-in #dashboard .section-title span,
html body h2.section-title span {
    color: #38bdf8 !important; /* Azul celeste claro para destaque */
}

/* Footer com contraste ideal */
html body .footer,
html body .footer p,
html body footer,
html body footer p {
    color: #94a3b8 !important; /* Tom cinza-claro perfeito */
    opacity: 0.85 !important;
}

/* Estilo premium e legível para a modal de nova aula do index.ejs */
html body .lesson-banner-modal {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%) !important;
    border: 2px solid #38bdf8 !important;
    box-shadow: 0 0 35px rgba(56, 189, 248, 0.3) !important;
}

html body .lesson-banner-title {
    color: #ffffff !important;
}

html body .lesson-banner-text {
    color: #cbd5e1 !important;
}
