/* =====================================================================
   lsw.css — Sistema de diseño de Trabajo Estándar
   ---------------------------------------------------------------------
   Se carga DESPUÉS de Bootstrap: no reemplaza el framework (modales,
   acordeón, dropdowns siguen siendo de Bootstrap), solo le cambia la
   piel a cada componente. No toca ningún nombre de clase que use el
   JavaScript (btn-marcar, input-nota, chk-vacacion, sel-cubre,
   toggle-nota) — solo su apariencia.
   ===================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@500;600;700&family=IBM+Plex+Sans:wght@400;500;600&display=swap');

:root {
    --ink:      #171B24;
    --steel:    #5B6479;
    --steel-40: #5B647966;
    --paper:    #F1F2F5;
    --surface:  #FFFFFF;
    --line:     #DFE2E8;
    --amber:    #E2963C;
    --amber-dark: #B36F1F;
    --moss:     #2E9563;
    --rust:     #C94A4A;

    --radius-sm: 6px;
    --radius-md: 10px;
    --font-display: 'Space Grotesk', system-ui, sans-serif;
    --font-body: 'IBM Plex Sans', system-ui, sans-serif;
}

/* --- Base ------------------------------------------------------------ */
body {
    background: var(--paper);
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 0.9375rem;
}
h1, h2, h3, h4, h5, h6 { font-family: var(--font-display); font-weight: 600; letter-spacing: -0.01em; }
a { color: var(--amber-dark); }
a:hover { color: var(--ink); }

/* --- Cascarón: sidebar + contenido ------------------------------------ */
.lsw-shell { display: flex; min-height: 100vh; }

.lsw-sidebar {
    width: 232px; flex: 0 0 232px;
    background: var(--ink);
    color: #C7CCDA;
    display: flex; flex-direction: column;
    position: sticky; top: 0; height: 100vh;
}
.lsw-brand {
    font-family: var(--font-display); font-weight: 700; font-size: 1.05rem;
    color: #fff; padding: 1.25rem 1.25rem 1rem;
    display: flex; align-items: center; gap: 0.5rem;
    border-bottom: 1px solid #ffffff1a;
}
.lsw-brand .mark {
    width: 10px; height: 10px; border-radius: 3px; background: var(--amber);
    display: inline-block; flex: none;
}
.lsw-nav { flex: 1; padding: 0.75rem 0.6rem; overflow-y: auto; }
.lsw-nav-label {
    font-size: 0.7rem; color: #C7CCDA80; padding: 0.9rem 0.6rem 0.35rem;
    font-weight: 600;
}
.lsw-nav a {
    display: flex; align-items: center; gap: 0.6rem;
    padding: 0.5rem 0.6rem; border-radius: var(--radius-sm);
    color: #C7CCDA; text-decoration: none; font-size: 0.875rem;
    margin-bottom: 1px;
}
.lsw-nav a i { width: 1.1rem; text-align: center; color: #C7CCDA99; font-size: 0.85rem; }
.lsw-nav a:hover { background: #ffffff14; color: #fff; }
.lsw-nav a.active { background: var(--amber); color: var(--ink); font-weight: 600; }
.lsw-nav a.active i { color: var(--ink); }
.lsw-user {
    padding: 0.9rem 1.1rem; border-top: 1px solid #ffffff1a;
    font-size: 0.8rem;
}
.lsw-user .name { color: #fff; font-weight: 600; display: block; }
.lsw-user a { color: #C7CCDA99; text-decoration: none; }
.lsw-user a:hover { color: var(--amber); }

.lsw-main { flex: 1; min-width: 0; padding: 1.75rem 2rem 3rem; }
.lsw-topline { display:flex; justify-content:space-between; align-items:flex-start; margin-bottom: 1.25rem; flex-wrap: wrap; gap: 0.75rem; }

.lsw-sidebar-toggle { display: none; }
@media (max-width: 860px) {
    .lsw-sidebar { position: fixed; z-index: 40; transform: translateX(-100%); transition: transform .18s ease; }
    .lsw-sidebar.open { transform: translateX(0); }
    .lsw-main { padding: 1.1rem 1rem 2.5rem; }
    .lsw-sidebar-toggle {
        display: inline-flex; align-items:center; gap:.4rem;
        background: var(--ink); color:#fff; border:none; border-radius: var(--radius-sm);
        padding: .45rem .7rem; font-size: .85rem; margin-bottom: 1rem;
    }
}

/* --- Tarjetas: borde, no sombra genérica ------------------------------ */
.card {
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    box-shadow: none;
}
.card-header, .card-footer { background: var(--surface); border-color: var(--line); }

/* --- Tablas ------------------------------------------------------------ */
.table {
    background: var(--surface);
    border-radius: var(--radius-md);
    overflow: hidden;
    font-size: 0.875rem;
}
.table thead th {
    background: var(--paper);
    color: var(--steel);
    font-weight: 600; font-size: 0.75rem;
    text-transform: none; letter-spacing: 0.01em;
    border-bottom: 1px solid var(--line);
    padding-top: 0.7rem; padding-bottom: 0.7rem;
}
.table td { border-color: var(--line); vertical-align: middle; }
.table-bordered { border: 1px solid var(--line); }

/* --- Botones ------------------------------------------------------------ */
.btn { border-radius: var(--radius-sm); font-weight: 500; font-size: 0.875rem; }
.btn-success { background: var(--ink); border-color: var(--ink); }
.btn-success:hover, .btn-success:focus { background: #0d0f15; border-color: #0d0f15; }
.btn-outline-secondary { color: var(--steel); border-color: var(--line); }
.btn-outline-secondary:hover { background: var(--ink); border-color: var(--ink); }
.btn-outline-primary { color: var(--amber-dark); border-color: var(--amber); }
.btn-outline-primary:hover { background: var(--amber); border-color: var(--amber); color: var(--ink); }
.btn-outline-danger { color: var(--rust); border-color: #E9C7C7; }
.btn-outline-danger:hover { background: var(--rust); border-color: var(--rust); }
.btn-light.disabled { background: var(--surface); border: 1px solid var(--line); color: var(--ink); opacity: 1; font-weight: 500; }

/* Casillas de estado (REALIZADO/NO REALIZADO): tile tipo andon, no botón Bootstrap plano */
.btn-marcar {
    width: 34px; height: 34px; border-radius: var(--radius-sm);
    font-weight: 700; font-size: 0.95rem; padding: 0; line-height: 1;
}
.btn-marcar.btn-success { background: var(--moss); border-color: var(--moss); color: #fff; }
.btn-marcar.btn-outline-secondary { background: var(--surface); border: 1.5px solid var(--line); color: var(--steel-40); }
.btn-marcar.btn-outline-secondary:hover { border-color: var(--amber); color: var(--amber-dark); background: var(--surface); }

/* --- Insignias de prioridad -------------------------------------------- */
.badge { font-weight: 600; font-size: 0.72rem; padding: 0.32em 0.6em; border-radius: var(--radius-sm); }
.badge.bg-danger  { background: #FBEBEB !important; color: var(--rust) !important; }
.badge.bg-warning { background: #FBF0DE !important; color: var(--amber-dark) !important; }
.badge.bg-secondary { background: var(--paper) !important; color: var(--steel) !important; }

/* --- Formularios --------------------------------------------------------- */
.form-control, .form-select {
    border-color: var(--line); border-radius: var(--radius-sm);
    font-size: 0.9rem;
}
.form-control:focus, .form-select:focus {
    border-color: var(--amber); box-shadow: 0 0 0 3px #E2963C33;
}
.form-label { font-size: 0.82rem; font-weight: 500; color: var(--steel); }

/* --- Alertas -------------------------------------------------------------- */
.alert { border-radius: var(--radius-md); border: 1px solid; font-size: 0.9rem; }
.alert-success { background: #EAF6EF; border-color: #C9E9D6; color: #1E6B44; }
.alert-info    { background: #EEF1FB; border-color: #D6DCF3; color: var(--ink); }
.alert-warning { background: #FBF0DE; border-color: #F0DCB1; color: var(--amber-dark); }

/* --- Modal / Acordeón ------------------------------------------------------ */
.modal-content { border-radius: var(--radius-md); border: 1px solid var(--line); }
.modal-header, .modal-footer { border-color: var(--line); }
.accordion-item { border-color: var(--line); }
.accordion-button:not(.collapsed) { background: var(--paper); color: var(--ink); box-shadow: none; }
.accordion-button:focus { box-shadow: none; }

/* --- Tarjetas de resumen del menú (usadas en menu.php) --------------------- */
.lsw-stat {
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-md);
    padding: 1.1rem; text-decoration: none; color: var(--ink); display: block; height: 100%;
    transition: border-color .12s ease;
}
.lsw-stat:hover { border-color: var(--amber); color: var(--ink); }
.lsw-stat .n { font-family: var(--font-display); font-size: 1.9rem; font-weight: 700; line-height: 1; }
.lsw-stat .label { font-size: 0.8rem; color: var(--steel); margin-top: 0.3rem; }
.lsw-stat i { color: var(--amber); font-size: 0.95rem; }

/* --- Chips de contexto (reemplazan "A · B · C") ---------------------------- */
.lsw-tagline { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0.35rem 0 0; padding: 0; list-style: none; }
.lsw-tagline li {
    background: var(--paper); color: var(--steel); border: 1px solid var(--line);
    font-size: 0.78rem; padding: 0.18rem 0.6rem; border-radius: 999px;
}

/* --- Login: panel partido ---------------------------------------------------- */
.lsw-auth { min-height: 100vh; display: flex; }
.lsw-auth-hero {
    flex: 1 1 46%; background: var(--ink); color: #fff;
    display: flex; flex-direction: column; justify-content: center;
    padding: 3rem 3.5rem; position: relative; overflow: hidden;
}
.lsw-auth-hero h1 { font-size: 1.6rem; margin: 1.5rem 0 0.6rem; }
.lsw-auth-hero p { color: #C7CCDA; max-width: 32ch; font-size: 0.95rem; }
.lsw-auth-brand { display: flex; align-items: center; gap: 0.55rem; font-family: var(--font-display); font-weight: 700; font-size: 1.05rem; }
.lsw-auth-brand .mark { width: 11px; height: 11px; border-radius: 3px; background: var(--amber); display: inline-block; }
.lsw-dotgrid { display: grid; grid-template-columns: repeat(10, 1fr); gap: 6px; max-width: 300px; margin-top: 2.2rem; }
.lsw-dotgrid span { display: block; width: 100%; padding-top: 100%; border-radius: 3px; }
.lsw-auth-form { flex: 1 1 54%; display: flex; align-items: center; justify-content: center; background: var(--surface); padding: 2rem; }
.lsw-auth-form form { width: 100%; max-width: 340px; }
.lsw-auth-form h2 { margin-bottom: 1.4rem; }
@media (max-width: 760px) {
    .lsw-auth { flex-direction: column; }
    .lsw-auth-hero { padding: 2.2rem 1.75rem; }
    .lsw-dotgrid { display: none; }
}
