/* ==========================================
   VANES THEME PRO (Dark clean, sin manchas)
   Archivo: static/css/theme_pro.css
   ========================================== */

:root {
    --bg0: #070914;
    --bg1: #070914;
    /* mismo tono -> fondo limpio */

    --panel: rgba(255, 255, 255, .035);
    --panel2: rgba(255, 255, 255, .05);

    --border: rgba(255, 255, 255, .08);
    --border2: rgba(255, 255, 255, .12);

    --text: #eaf0ff;
    --muted: rgba(234, 240, 255, .70);

    --accent: #63b3ff;
    --accent2: #7c5cff;

    --good: #00e676;
    --bad: #ff5252;

    --r16: 16px;
    --r20: 20px;
    --blur: 16px;

    --shadow1: 0 18px 55px rgba(0, 0, 0, .55);
    --shadow2: 0 10px 30px rgba(0, 0, 0, .40);

    --sidebar-w: 260px;
}

/* Base */
html,
body {
    height: 100%;
}

body {
    font-family: "Inter", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
    background: linear-gradient(180deg, var(--bg0), var(--bg1));
    color: var(--text);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Suave “film grain/glow” muy leve (NO mancha)
   Si lo querés 100% plano, poné opacity: 0; */
body:before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background:
        radial-gradient(900px 500px at 50% -10%, rgba(255, 255, 255, .05), transparent 60%),
        radial-gradient(900px 500px at 0% 100%, rgba(255, 255, 255, .03), transparent 60%);
    opacity: 0;
    /* bajísimo, no genera franjas */
    z-index: 0;
}

/* Login no se altera */
body.is-login {
    background: linear-gradient(180deg, var(--bg0), var(--bg1));
}

body.is-login:before {
    opacity: 0;
}

/* ------------------------------------------
   Sidebar FIX
------------------------------------------ */

.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: var(--sidebar-w);
    height: 100vh;
    z-index: 20;

    background: rgba(255, 255, 255, .03);
    border-right: 1px solid var(--border);
    backdrop-filter: blur(var(--blur));
}

.sidebar a {
    color: rgba(234, 240, 255, .86);
    border-radius: 14px;
    transition: background .15s, border .15s;
}

.sidebar a:hover {
    background: rgba(255, 255, 255, .06);
}

.sidebar a.active,
.sidebar a[aria-current="page"] {
    background: rgba(99, 179, 255, .12);
    border: 1px solid rgba(99, 179, 255, .18);
}

/* ------------------------------------------
   Main offset (evita que pise sidebar)
------------------------------------------ */

.app-main {
    position: relative;
    z-index: 1;
    margin-left: var(--sidebar-w);
    padding: 26px 28px;
    min-height: 100vh;
}

/* Responsive */
@media (max-width: 980px) {
    :root {
        --sidebar-w: 220px;
    }

    .sidebar {
        width: var(--sidebar-w);
    }

    .app-main {
        margin-left: var(--sidebar-w);
        padding: 20px;
    }
}

@media (max-width: 760px) {
    .sidebar {
        position: static;
        width: 100%;
        height: auto;
    }

    .app-main {
        margin-left: 0;
        padding: 18px;
    }
}

/* ------------------------------------------
   Cards / Panels
------------------------------------------ */

.card,
.panel,
.box,
.widget,
.table-card,
.stats-card,
.descargas-card,
.descargas-page .card {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: var(--r20);
    box-shadow: var(--shadow2);
    backdrop-filter: blur(var(--blur));
}

.card:hover,
.panel:hover,
.widget:hover {
    border-color: rgba(255, 255, 255, .12);
}

/* Títulos */
h1,
h2,
h3 {
    letter-spacing: -0.02em;
}

/* ------------------------------------------
   Inputs / Selects (PRO)
------------------------------------------ */

input[type="text"],
input[type="number"],
input[type="date"],
input[type="search"],
input[type="password"],
select,
textarea {
    background: rgba(8, 10, 22, .80);
    border: 1px solid rgba(255, 255, 255, .10);
    color: var(--text);
    border-radius: 14px;
    outline: none;
    transition: box-shadow .15s, border .15s, background .15s;
}

input:focus,
select:focus,
textarea:focus {
    border-color: rgba(99, 179, 255, .28);
    box-shadow: 0 0 0 4px rgba(99, 179, 255, .10);
    background: rgba(8, 10, 22, .92);
}

input::placeholder,
textarea::placeholder {
    color: rgba(234, 240, 255, .45);
}

/* ------------------------------------------
   Botones
------------------------------------------ */

.btn,
button,
.button {
    border-radius: 14px;
    font-weight: 800;
}

.btn-primary,
.btn.btn-primary {
    background: linear-gradient(180deg, rgba(0, 230, 118, 1), rgba(0, 200, 100, 1));
    color: #04110b;
    border: 0;
    box-shadow: 0 12px 30px rgba(0, 230, 118, .16);
}

.btn-secondary,
.btn.btn-secondary {
    background: rgba(255, 255, 255, .06);
    color: var(--text);
    border: 1px solid var(--border);
}

.btn:disabled,
button:disabled {
    opacity: .45;
    cursor: not-allowed;
}

/* ------------------------------------------
   Tablas
------------------------------------------ */

table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

thead th {
    background: rgba(255, 255, 255, .04);
    color: rgba(234, 240, 255, .85);
    border-bottom: 1px solid rgba(255, 255, 255, .10);
}

tbody td {
    border-bottom: 1px solid rgba(255, 255, 255, .06);
    color: rgba(234, 240, 255, .88);
}

tbody tr:hover td {
    background: rgba(255, 255, 255, .03);
}