*{
    margin:0;
    padding:0;
    box-sizing:border-box;
    font-family:Arial, Helvetica, sans-serif;
}

:root{
    --primary:#003b71;
    --primary-light:#0f5aa3;
    --accent:#ffc400;
    --bg:#f5f7fb;
    --white:#ffffff;
    --text:#0f172a;
    --muted:#64748b;
    --border:#e2e8f0;
    --shadow:0 8px 24px rgba(15,23,42,0.06);
    --radius:24px;
}

body{
    background:var(--bg);
    color:var(--text);
    min-height:100vh;
}

/* LOGIN */

.login-body{
    display:flex;
    align-items:center;
    justify-content:center;
    min-height:100vh;
    padding:20px;
    background:#f5f7fb;
}

.login-container{
    width:100%;
    max-width:430px;
}

.login-card{
    background:var(--white);
    border-radius:32px;
    padding:40px;
    box-shadow:var(--shadow);
}

.login-header{
    text-align:center;
    margin-bottom:30px;
}

.login-header h1{
    color:var(--primary);
    font-size:clamp(28px,4vw,42px);
    margin-bottom:10px;
}

.login-header p{
    color:var(--muted);
    font-size:1rem;
}

.login-form input{
    width:100%;
    height:56px;
    margin-bottom:18px;
    border:none;
    border-radius:16px;
    background:#f1f5f9;
    padding:0 18px;
    font-size:15px;
    outline:none;
    transition:0.2s;
}

.login-form input:focus{
    background:white;
    border:2px solid var(--accent);
}

.login-form button{
    width:100%;
    height:56px;
    border:none;
    border-radius:16px;
    background:var(--accent);
    color:var(--primary);
    font-weight:800;
    font-size:16px;
    cursor:pointer;
    transition:0.2s;
}

.login-form button:hover{
    background:#f0b800;
}

.login-footer{
    text-align:center;
    margin-top:20px;
    color:var(--muted);
    font-size:14px;
}

/* LAYOUT */

.container{
    width:100%;
    max-width:1400px;
    margin:auto;
    padding:24px;
}

/* NAVBAR */

.navbar{
    background:var(--white);
    border-radius:24px;
    padding:18px 24px;
    display:flex;
    justify-content:space-between;
    align-items:center;
    flex-wrap:wrap;
    gap:20px;
    box-shadow:var(--shadow);
    margin-bottom:30px;
}

.logo{
    font-size:1.3rem;
    font-weight:800;
    color:var(--primary);
}

.user-info{
    display:flex;
    align-items:center;
    gap:10px;
    color:var(--muted);
}

.admin-badge{
    background:#fee2e2;
    color:#b91c1c;
    padding:6px 12px;
    border-radius:30px;
    text-decoration:none;
    font-size:12px;
    font-weight:700;
}

.nav-links{
    display:flex;
    flex-wrap:wrap;
    gap:10px;
    list-style:none;
}

.nav-links a{
    text-decoration:none;
    color:#334155;
    font-weight:600;
    padding:10px 16px;
    border-radius:14px;
    transition:0.2s ease;
}

.nav-links a:hover,
.nav-links a.active{
    background:var(--primary);
    color:white;
}

/* DASHBOARD */

.dashboard{
    width:100%;
}

.dashboard h1{
    font-size:clamp(30px,4vw,42px);
    color:var(--primary);
    margin-bottom:30px;
}

/* STATS */

.stats,
.admin-stats{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
    gap:20px;
    margin:25px 0;
}

.stat-card{
    background:var(--white);
    border-radius:24px;
    padding:28px;
    box-shadow:var(--shadow);
    transition:0.2s;
}

.stat-card:hover{
    transform:translateY(-3px);
}

.stat-card h3{
    color:var(--muted);
    margin-bottom:12px;
    font-size:1rem;
}

.stat-card p{
    font-size:2.3rem;
    font-weight:800;
    color:var(--primary);
}

/* TABLES */

.table-responsive{
    width:100%;
    overflow-x:auto;
}

.table{
    width:100%;
    border-collapse:collapse;
    background:var(--white);
    border-radius:24px;
    overflow:hidden;
    box-shadow:var(--shadow);
    min-width:900px;
}

.table thead{
    background:var(--primary);
    color:white;
}

.table th{
    padding:18px 16px;
    text-align:left;
    font-size:14px;
}

.table td{
    padding:16px;
    border-bottom:1px solid var(--border);
    font-size:14px;
}

.table tbody tr:hover{
    background:#f8fafc;
}

/* FORMS */

.form-section{
    background:var(--white);
    border-radius:24px;
    padding:30px;
    margin-bottom:30px;
    box-shadow:var(--shadow);
}

.form-section h3{
    margin-bottom:20px;
    color:var(--primary);
}

.form-inline{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(200px,1fr));
    gap:15px;
}

input,
select,
button{
    font-size:15px;
}

input,
select{
    height:52px;
    border:none;
    border-radius:14px;
    background:#f1f5f9;
    padding:0 16px;
    outline:none;
    transition:0.2s;
}

input:focus,
select:focus{
    background:white;
    border:2px solid var(--accent);
}

/* BUTTONS */

button,
.btn-primary,
.btn-secondary,
.btn-danger,
.btn-sm,
.btn-warning,
.btn-success,
.btn-info{
    border:none;
    text-decoration:none;
    cursor:pointer;
    transition:0.2s ease;
    font-weight:700;
    display:inline-flex;
    align-items:center;
    justify-content:center;
}

button,
.btn-primary{
    background:var(--accent);
    color:var(--primary);
}

button:hover,
.btn-primary:hover{
    background:#f0b800;
}

.btn-secondary{
    background:var(--primary);
    color:white;
}

.btn-danger{
    background:#fee2e2;
    color:#b91c1c;
}

.btn-warning{
    background:#fef3c7;
    color:#92400e;
}

.btn-success{
    background:#dcfce7;
    color:#166534;
}

.btn-info{
    background:#dbeafe;
    color:#1d4ed8;
}

.btn-sm{
    padding:10px 14px;
    border-radius:12px;
    font-size:13px;
}

.btn-primary,
.btn-secondary{
    padding:14px 20px;
    border-radius:14px;
}

/* ALERTS */

.alert{
    padding:16px 20px;
    border-radius:16px;
    margin:20px 0;
    font-weight:600;
}

.success{
    background:#dcfce7;
    color:#166534;
}

.error{
    background:#fee2e2;
    color:#b91c1c;
}

.warning{
    background:#fef3c7;
    color:#92400e;
}

.info{
    background:#dbeafe;
    color:#1d4ed8;
}

/* BADGES */

.badge{
    padding:6px 12px;
    border-radius:30px;
    font-size:12px;
    font-weight:700;
}

.badge.admin{
    background:#dbeafe;
    color:#1d4ed8;
}

.badge.usuario{
    background:#e2e8f0;
    color:#334155;
}

.badge.activo{
    background:#dcfce7;
    color:#166534;
}

.badge.inactivo{
    background:#fee2e2;
    color:#b91c1c;
}

/* ASISTENCIA */

.asistencia-header{
    display:flex;
    justify-content:space-between;
    align-items:center;
    flex-wrap:wrap;
    gap:15px;
    margin:20px 0;
    padding:20px;
    background:var(--white);
    border-radius:24px;
    box-shadow:var(--shadow);
}

.toolbar{
    display:flex;
    gap:10px;
    flex-wrap:wrap;
}

.fecha-info{
    font-size:1rem;
    color:var(--primary);
    font-weight:700;
}

.estado-badge{
    font-size:13px;
}

.actions{
    display:flex;
    flex-wrap:wrap;
    gap:10px;
}

.quick-actions{
    background:var(--white);
    border-radius:24px;
    padding:28px;
    margin-top:25px;
    box-shadow:var(--shadow);
}

.action-buttons{
    display:flex;
    flex-wrap:wrap;
    gap:15px;
    margin-top:18px;
}

.action-buttons a{
    text-decoration:none;
}

.note{
    margin-top:15px;
    color:var(--muted);
    font-size:14px;
}

.inactive-row{
    opacity:0.6;
}

.text-muted{
    color:#94a3b8;
    font-size:13px;
}

/* RESPONSIVE */

@media (max-width:768px){

    .container{
        padding:15px;
    }

    .navbar{
        flex-direction:column;
        align-items:flex-start;
    }

    .nav-links{
        width:100%;
    }

    .nav-links li{
        width:100%;
    }

    .nav-links a{
        display:block;
        width:100%;
    }

    .form-inline{
        grid-template-columns:1fr;
    }

    .action-buttons{
        flex-direction:column;
    }

    .action-buttons a,
    .btn-primary,
    .btn-secondary{
        width:100%;
    }

    .table{
        min-width:800px;
    }
}

@media (max-width:480px){

    .login-card{
        padding:28px 22px;
    }

    .stat-card{
        padding:22px;
    }

    .stat-card p{
        font-size:1.8rem;
    }

    .dashboard h1{
        font-size:2rem;
    }

    .quick-actions,
    .form-section{
        padding:22px;
    }
}