/* ============================================================
   GÁS DELIVERY SISTEMAS — estilo base do painel
   Paleta: ardósia escura + laranja-chama (identidade do setor,
   usado com moderação — só em ações e destaques, não em blocos grandes)
   ============================================================ */

:root {
    --slate-950: #12181f;
    --slate-900: #1a222c;
    --slate-800: #232d3a;
    --slate-700: #34404f;
    --slate-500: #6b7789;
    --slate-300: #a9b3c1;
    --slate-100: #eef1f5;
    --white: #ffffff;

    --flame-500: #e8703a;
    --flame-600: #d4592a;
    --flame-100: #fdeee5;

    --success: #2f9e5b;
    --success-bg: #e7f6ed;
    --danger: #d33f3f;
    --danger-bg: #fbe9e9;
    --warning: #c98a1c;
    --warning-bg: #fdf3e0;

    --radius: 8px;
    --shadow: 0 1px 3px rgba(18, 24, 31, 0.08), 0 1px 2px rgba(18, 24, 31, 0.06);
    --font-display: 'Sora', -apple-system, sans-serif;
    --font-body: 'Inter', -apple-system, sans-serif;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: var(--font-body);
    background: var(--slate-100);
    color: var(--slate-900);
    font-size: 15px;
    line-height: 1.5;
}

h1, h2, h3 {
    font-family: var(--font-display);
    font-weight: 700;
    letter-spacing: -0.01em;
    color: var(--slate-950);
    margin: 0 0 4px;
}

a { color: var(--flame-600); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ---- Tela de login (centralizada, split visual) ---- */
.tela-login {
    min-height: 100vh;
    display: flex;
}

.login-lado-marca {
    flex: 1;
    background: linear-gradient(160deg, var(--slate-950) 0%, var(--slate-900) 55%, #2a1810 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 64px;
    color: var(--white);
    position: relative;
    overflow: hidden;
}

.login-lado-marca::after {
    content: '';
    position: absolute;
    width: 480px;
    height: 480px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(232,112,58,0.25) 0%, rgba(232,112,58,0) 70%);
    top: -120px;
    right: -120px;
}

.login-lado-marca .marca-eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 12px;
    color: var(--flame-500);
    font-weight: 600;
    margin-bottom: 18px;
}

.login-lado-marca h1 {
    color: var(--white);
    font-size: 34px;
    max-width: 420px;
    margin-bottom: 14px;
}

.login-lado-marca p {
    color: var(--slate-300);
    max-width: 380px;
    font-size: 15px;
}

.login-marca-imagem {
    position: absolute;
    right: -40px;
    bottom: -40px;
    width: 46%;
    max-width: 480px;
    min-width: 260px;
    pointer-events: none;
    filter: drop-shadow(0 20px 40px rgba(0,0,0,0.45));
}

@media (max-width: 1100px) {
    .login-marca-imagem { width: 38%; right: -20px; bottom: -20px; }
}

.login-lado-form {
    width: 440px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--white);
    padding: 40px;
}

.login-form-box { width: 100%; max-width: 320px; }
.login-form-box h2 { font-size: 22px; margin-bottom: 6px; }
.login-form-box .subtitulo { color: var(--slate-500); font-size: 14px; margin-bottom: 28px; }

@media (max-width: 860px) {
    .login-lado-marca { display: none; }
    .login-lado-form { width: 100%; }
}

/* ---- Formulários ---- */
.campo { margin-bottom: 16px; }
.campo label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--slate-700);
    margin-bottom: 6px;
}
.campo input,
.campo select,
.campo textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--slate-300);
    border-radius: var(--radius);
    font-size: 14px;
    font-family: var(--font-body);
    background: var(--white);
    transition: border-color .15s ease;
}
.campo input:focus,
.campo select:focus,
.campo textarea:focus {
    outline: none;
    border-color: var(--flame-500);
    box-shadow: 0 0 0 3px var(--flame-100);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 18px;
    border-radius: var(--radius);
    font-size: 14px;
    font-weight: 600;
    font-family: var(--font-body);
    border: none;
    cursor: pointer;
    text-decoration: none;
}
.btn:hover { text-decoration: none; }
.btn-primario { background: var(--flame-500); color: var(--white); width: 100%; }
.btn-primario:hover { background: var(--flame-600); }
.btn-secundario { background: var(--slate-100); color: var(--slate-900); border: 1px solid var(--slate-300); }
.btn-secundario:hover { background: var(--slate-100); filter: brightness(0.97); }
.btn-perigo { background: var(--danger-bg); color: var(--danger); }
.btn-sm { padding: 6px 12px; font-size: 13px; }

/* ---- Layout do painel ---- */
.painel-shell { display: flex; min-height: 100vh; }

.sidebar {
    width: 240px;
    background: var(--slate-950);
    color: var(--white);
    padding: 24px 16px;
    flex-shrink: 0;
}
.sidebar .marca {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 16px;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.sidebar .marca .chama { color: var(--flame-500); }
.sidebar .subtitulo-sidebar { color: var(--slate-500); font-size: 12px; margin-bottom: 32px; }
.sidebar nav a {
    display: block;
    padding: 10px 12px;
    border-radius: var(--radius);
    color: var(--slate-300);
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 2px;
}
.sidebar nav a:hover { background: var(--slate-800); text-decoration: none; color: var(--white); }
.sidebar nav a.ativo { background: var(--flame-500); color: var(--white); }

.conteudo { flex: 1; padding: 32px 40px; max-width: 1200px; }

.topo-pagina {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 28px;
}
.topo-pagina .usuario-logado { font-size: 13px; color: var(--slate-500); text-align: right; }

/* ---- Cards / tabelas ---- */
.card {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 24px;
    margin-bottom: 20px;
}

.grid-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin-bottom: 24px; }
.stat-card { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 20px; }
.stat-card .valor { font-family: var(--font-display); font-size: 28px; font-weight: 700; color: var(--slate-950); }
.stat-card .rotulo { font-size: 13px; color: var(--slate-500); margin-top: 2px; }

table { width: 100%; border-collapse: collapse; }
th {
    text-align: left;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--slate-500);
    padding: 10px 12px;
    border-bottom: 1px solid var(--slate-300);
}
td { padding: 12px; border-bottom: 1px solid var(--slate-100); font-size: 14px; }
tr:hover td { background: var(--slate-100); }

.badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 100px;
    font-size: 12px;
    font-weight: 600;
}
.badge-sucesso { background: var(--success-bg); color: var(--success); }
.badge-perigo { background: var(--danger-bg); color: var(--danger); }
.badge-alerta { background: var(--warning-bg); color: var(--warning); }
.badge-neutro { background: var(--slate-100); color: var(--slate-500); }

.alerta { padding: 12px 16px; border-radius: var(--radius); margin-bottom: 20px; font-size: 14px; }
.alerta-sucesso { background: var(--success-bg); color: var(--success); }
.alerta-erro { background: var(--danger-bg); color: var(--danger); }

.texto-vazio { text-align: center; padding: 48px 20px; color: var(--slate-500); }

/* ---- Aviso de vencimento do plano ---- */
.aviso-vencimento {
    background: var(--warning-bg);
    color: #7a5510;
    padding: 12px 24px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 16px;
    font-size: 14px;
    font-weight: 500;
    flex-wrap: wrap;
    border-bottom: 1px solid rgba(0,0,0,0.06);
}
.aviso-vencimento-critico {
    background: var(--danger-bg);
    color: #8a2a2a;
}
.aviso-vencimento .btn-renovar {
    background: var(--flame-500);
    color: var(--white);
    padding: 6px 16px;
    border-radius: 100px;
    font-weight: 600;
    font-size: 13px;
    text-decoration: none;
    white-space: nowrap;
}
.aviso-vencimento .btn-renovar:hover { background: var(--flame-600); text-decoration: none; }
