/* =================================================
   BRASFOOT PREMIUM – LUXURY EDITION
   Upgrade visual completo
================================================= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700&display=swap');

:root {
    --gold: #f5c46b;
    --gold-soft: #ffd98a;
    --blue-dark: #071a2b;
    --blue-mid: #0b2b44;
    --blue-light: #1d6fa5;
    --glass: rgba(255,255,255,.06);
    --glass-strong: rgba(255,255,255,.12);
}

* {
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

/* ==============================
   BODY
============================== */
body {
    margin: 0;
    min-height: 100vh;
    background:
        radial-gradient(circle at top, #123c5e 0%, #071a2b 60%);
    color: #eef6ff;
}

/* ==============================
   FUNDO
============================== */
.background-stadium {
    position: fixed;
    inset: 0;
    background:
        linear-gradient(to bottom, rgba(4,18,35,.92), rgba(4,18,35,.96)),
        url("../img/bg-stadium.jpg") center/cover no-repeat;
    filter: contrast(1.05) saturate(1.05);
    z-index: -1;
}

/* ==============================
   CONTAINER
============================== */
.main-container {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    padding: 40px 20px;
    min-height: 100vh;
}

/* ==============================
   HEADER PRINCIPAL (ACIMA DA JANELA)
============================== */
.main-header {
    text-align: center;
    margin-bottom: 30px;
    width: 100%;
    max-width: 980px;
}

.logo {
    font-size: 36px;
    font-weight: 700;
    color: var(--gold);
    margin: 0 0 8px 0;
    text-shadow: 
        0 2px 10px rgba(245,196,107,.5),
        0 0 20px rgba(245,196,107,.3);
    letter-spacing: 1px;
}

.subtitle {
    font-size: 16px;
    color: rgba(255,255,255,.8);
    margin: 0;
    font-weight: 400;
}

/* ==============================
   JANELA PRINCIPAL
============================== */
.config-window {
    width: 980px;
    max-width: 100%;
    background:
        linear-gradient(180deg, rgba(18,60,94,.85), rgba(7,26,43,.95));
    border-radius: 18px;
    box-shadow:
        0 40px 120px rgba(0,0,0,.8),
        inset 0 0 0 1px rgba(255,255,255,.08);
    overflow: hidden;
    backdrop-filter: blur(8px);
}

/* ==============================
   HEADER
============================== */
.window-header {
    background:
        linear-gradient(90deg, #1e88e5, #0f3d5f);
    color: #fff;
    padding: 14px 20px;
    font-size: 22px;
    font-weight: 700;
    text-align: center;
    letter-spacing: 1px;
    text-transform: uppercase;
    border-bottom: 1px solid rgba(255,255,255,.15);
    box-shadow: inset 0 -1px 0 rgba(255,255,255,.1);
}

.window-header h2 {
    margin: 0;
    color: #fff;
}

/* ==============================
   CONTEÚDO
============================== */
.config-content {
    padding: 24px;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 22px;
}

/* ==============================
   SEÇÕES
============================== */
.config-section {
    background: linear-gradient(
        180deg,
        rgba(255,255,255,.08),
        rgba(255,255,255,.02)
    );
    border-radius: 14px;
    padding: 16px;
    box-shadow:
        inset 0 0 0 1px rgba(255,255,255,.08),
        0 10px 30px rgba(0,0,0,.4);
}

.config-section h3 {
    margin: 0 0 10px;
    font-size: 15px;
    font-weight: 700;
    color: var(--gold);
    text-transform: uppercase;
    letter-spacing: .5px;
}

/* ==============================
   TABELAS
============================== */
.config-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.config-table th {
    text-align: left;
    padding: 8px;
    background: rgba(255,255,255,.08);
    color: var(--gold-soft);
    text-transform: uppercase;
    font-size: 12px;
    font-weight: 700;
}

.config-table td {
    padding: 8px;
    border-top: 1px solid rgba(255,255,255,.05);
    color: #e6f1ff;
}

.config-table tbody tr:hover {
    background: rgba(245,196,107,.08);
}

/* ==============================
   LINHAS COM BANDEIRAS
============================== */
.pais {
    display: flex;
    align-items: center;
    gap: 10px;
}

.pais img {
    width: 24px;
    height: 16px;
    border-radius: 2px;
    object-fit: cover;
    box-shadow: 0 0 0 1px rgba(255,255,255,.2);
}

/* ==============================
   CHECKBOX / RADIO
============================== */
input[type="checkbox"],
input[type="radio"] {
    accent-color: var(--gold);
    cursor: pointer;
}

/* ==============================
   BOTÕES – PREMIUM
============================== */
button,
.btn-config,
.btn-auth,
.btn-nav,
.btn-cadastrar,
.btn-entrar,
.btn-confirmar {
    background:
        linear-gradient(180deg, #f5c46b, #d4a24a);
    border: none;
    border-radius: 10px;
    padding: 10px 16px;
    color: #1a1a1a;
    font-weight: 700;
    letter-spacing: .3px;
    cursor: pointer;
    transition: all .25s ease;
    box-shadow:
        0 8px 25px rgba(245,196,107,.45),
        inset 0 1px 0 rgba(255,255,255,.6);
}

button:hover,
.btn-config:hover,
.btn-auth:hover,
.btn-nav:hover,
.btn-cadastrar:hover,
.btn-entrar:hover,
.btn-confirmar:hover {
    background:
        linear-gradient(180deg, #ffd98a, #e0b25a);
    transform: translateY(-1px);
    box-shadow:
        0 12px 35px rgba(245,196,107,.7),
        inset 0 1px 0 rgba(255,255,255,.7);
}

button:disabled {
    opacity: .4;
    cursor: not-allowed;
    transform: none;
}

/* ==============================
   BOTÕES SECUNDÁRIOS
============================== */
.btn-cancelar {
    background: rgba(255,255,255,.12);
    color: #fff;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.2);
}

.btn-cancelar:hover {
    background: rgba(255,255,255,.18);
    transform: translateY(-1px);
}

/* ==============================
   FOOTER
============================== */
.window-footer {
    padding: 18px 22px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0,0,0,.2);
}

/* ==============================
   LOGIN / CADASTRO
============================== */
.auth-buttons {
    display: flex;
    gap: 12px;
}

/* ==============================
   SELECT / INPUT
============================== */
select,
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"] {
    width: 100%;
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.2);
    border-radius: 8px;
    padding: 8px 10px;
    color: #fff;
    transition: all .25s ease;
}

select:focus,
input:focus {
    outline: none;
    box-shadow:
        0 0 0 2px rgba(245,196,107,.4);
    border-color: var(--gold);
}

select option {
    background: #0b2b44;
    color: #fff;
}

/* ==============================
   ABAS (jogar.php)
============================== */
.titulo-aba {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 14px;
    color: var(--gold);
    letter-spacing: .5px;
}

.caixa-simulacao {
    background: linear-gradient(
        180deg,
        rgba(255,255,255,.06),
        rgba(255,255,255,.02)
    );
    padding: 14px;
    border-radius: 10px;
    margin-bottom: 12px;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.1);
}

.caixa-simulacao p {
    margin: 4px 0;
    font-size: 14px;
    color: #e6f1ff;
}

/* ==============================
   RESULTADO FINAL
============================== */
.resultado-final {
    background: linear-gradient(
        180deg,
        rgba(255,255,255,.06),
        rgba(255,255,255,.02)
    );
    padding: 14px;
    border-radius: 10px;
    text-align: center;
    margin-bottom: 12px;
    font-weight: 700;
    color: var(--gold);
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.1);
}

/* ==============================
   MODAIS
============================== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    z-index: 1000;
    backdrop-filter: blur(5px);
}

.modal-overlay.active,
.modal-overlay[style*="display: block"] {
    display: block !important;
}

.modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1001;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    display: none;
}

.modal.active {
    display: block;
    animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: translate(-50%, -60%);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%);
    }
}

.modal-content {
    background:
        linear-gradient(180deg, rgba(18,60,94,.9), rgba(7,26,43,.98));
    border-radius: 18px;
    box-shadow:
        0 40px 120px rgba(0,0,0,.8),
        inset 0 0 0 1px rgba(255,255,255,.08);
    overflow: hidden;
}

.modal-header {
    background:
        linear-gradient(90deg, #1e88e5, #0f3d5f);
    color: #fff;
    padding: 14px 20px;
    border-bottom: 1px solid rgba(255,255,255,.15);
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: inset 0 -1px 0 rgba(255,255,255,.1);
}

.modal-header h2 {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: .5px;
}

.modal-close {
    background: transparent;
    border: none;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    line-height: 1;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: all 0.2s;
    font-weight: bold;
}

.modal-close:hover {
    background: rgba(255,255,255,.1);
}

/* ==============================
   FORMULÁRIOS
============================== */
form {
    padding: 20px;
    background: rgba(255,255,255,.02);
}

.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    color: var(--gold-soft);
    margin-bottom: 6px;
    font-weight: 600;
    font-size: 14px;
}

.form-group small {
    display: block;
    color: rgba(255,255,255,.6);
    margin-top: 4px;
    font-size: 12px;
}

.form-group small a {
    color: var(--gold);
    text-decoration: underline;
}

.form-group small a:hover {
    color: var(--gold-soft);
}

.mensagem {
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 16px;
    display: none;
    font-size: 14px;
}

.mensagem.erro {
    background: rgba(220, 53, 69, 0.2);
    border: 1px solid rgba(220, 53, 69, 0.5);
    color: #ff6b7a;
    display: block;
}

.mensagem.sucesso {
    background: rgba(40, 167, 69, 0.2);
    border: 1px solid rgba(40, 167, 69, 0.5);
    color: #4ade80;
    display: block;
}

.form-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 20px;
}

.modal-footer {
    padding: 12px 20px;
    border-top: 1px solid rgba(255,255,255,.1);
    text-align: center;
    color: rgba(255,255,255,.6);
    background: rgba(0,0,0,.1);
    font-size: 12px;
}

.modal-footer a {
    color: var(--gold);
    text-decoration: underline;
    font-weight: normal;
}

.modal-footer a:hover {
    color: var(--gold-soft);
}

/* ==============================
   SCROLLBAR PREMIUM
============================== */
.config-content::-webkit-scrollbar,
.modal::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

.config-content::-webkit-scrollbar-track,
.modal::-webkit-scrollbar-track {
    background: rgba(255,255,255,.05);
    border-radius: 5px;
}

.config-content::-webkit-scrollbar-thumb,
.modal::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #f5c46b, #d4a24a);
    border-radius: 5px;
}

.config-content::-webkit-scrollbar-thumb:hover,
.modal::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #ffd98a, #e0b25a);
}

/* ==============================
   RESPONSIVO
============================== */
@media (max-width: 900px) {
    .config-content {
        grid-template-columns: 1fr;
    }
    
    .config-window {
        width: 100%;
        border-radius: 0;
    }
    
    .main-container {
        padding: 20px 10px;
    }
}
