* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    background: #f0f2f5;
    color: #1e293b;
    line-height: 1.6;
    min-height: 100vh;
}

/* ===== AUTH ===== */
.auth-body {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 100%);
}

.auth-container { width: 100%; max-width: 480px; }

.auth-card {
    background: #fff;
    padding: 40px 30px;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.2);
}

.auth-card h1 { text-align: center; font-size: 26px; color: #1e3a8a; margin-bottom: 6px; }
.subtitle { text-align: center; color: #64748b; font-size: 13px; margin-bottom: 24px; }
.auth-footer { text-align: center; margin-top: 20px; font-size: 14px; color: #64748b; }
.auth-footer a { color: #2563eb; font-weight: 600; text-decoration: none; }

/* ===== LOGO ===== */
.auth-card .logo-img {
    display: block;
    margin: 0 auto 20px auto; /* Centra la imagen y da un margen abajo */
    max-width: 180px;         /* Aumentado de 120px a 180px */
    height: auto;             /* Mantiene la proporción original */
}

/* ===== FORM ===== */
.form-group { margin-bottom: 16px; }
.form-group label {
    display: block; font-size: 13px; font-weight: 600;
    color: #334155; margin-bottom: 6px;
}
.form-group input,
.form-group select {
    width: 100%; padding: 11px 14px;
    border: 1.5px solid #cbd5e1; border-radius: 8px;
    font-size: 14px; transition: all 0.2s; background: #fff;
}
.form-group input:focus,
.form-group select:focus {
    outline: none; border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59,130,246,0.15);
}
.form-row {
    display: grid; grid-template-columns: 1fr 1fr; gap: 14px;
}
@media (max-width: 520px) { .form-row { grid-template-columns: 1fr; } }

/* ===== BOTONES ===== */
.btn {
    display: inline-block; padding: 11px 20px;
    border: none; border-radius: 8px;
    font-size: 14px; font-weight: 600;
    cursor: pointer; text-decoration: none;
    text-align: center; transition: all 0.2s;
}
.btn-primary { background: #2563eb; color: #fff; }
.btn-primary:hover { background: #1d4ed8; }
.btn-outline {
    background: transparent; color: #fff;
    border: 1.5px solid rgba(255,255,255,0.5);
}
.btn-outline:hover { background: rgba(255,255,255,0.1); }
.btn-block { width: 100%; }
.btn-sm { padding: 7px 14px; font-size: 13px; }

/* ===== HEADER ===== */
.main-header {
    background: linear-gradient(135deg, #1e3a8a, #2563eb);
    color: #fff; padding: 14px 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}
.header-inner {
    display: flex; justify-content: space-between;
    align-items: center; flex-wrap: wrap; gap: 10px;
}
.brand { font-weight: 700; font-size: 17px; }
.main-header nav {
    display: flex; align-items: center; gap: 14px;
    color: #e0e7ff; font-size: 14px;
}

/* ===== CONTAINER ===== */
.container { max-width: 1000px; margin: 0 auto; padding: 0 20px; }
.main-content { padding-top: 30px; padding-bottom: 60px; }
.main-content h1 { font-size: 26px; margin-bottom: 6px; color: #1e293b; }
.muted { color: #64748b; font-size: 14px; }

/* ===== CARDS ===== */
.card {
    background: #fff; border-radius: 12px;
    padding: 24px; margin-top: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.card h2 {
    font-size: 18px; margin-bottom: 16px;
    color: #1e3a8a; border-bottom: 2px solid #e0e7ff;
    padding-bottom: 8px;
}
.card h2:not(:first-child) { margin-top: 24px; }

/* ===== ALERTS ===== */
.alert { padding: 12px 16px; border-radius: 8px; font-size: 14px; margin-bottom: 16px; }
.alert-error { background: #fef2f2; color: #b91c1c; border-left: 4px solid #dc2626; }
.alert-success { background: #f0fdf4; color: #15803d; border-left: 4px solid #16a34a; }

/* ===== TABLAS ===== */
.table-responsive { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { padding: 12px 14px; text-align: left; border-bottom: 1px solid #e2e8f0; }
th {
    background: #f8fafc; font-weight: 600; color: #475569;
    font-size: 13px; text-transform: uppercase; letter-spacing: 0.5px;
}
tr:hover { background: #f8fafc; }

/* ===== INFO GRID ===== */
.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px; margin: 16px 0;
}
.info-grid > div {
    background: #f8fafc; padding: 12px 16px;
    border-radius: 8px; font-size: 14px;
}

/* ===== BADGES ===== */
.badge {
    padding: 4px 12px; border-radius: 20px;
    font-size: 12px; font-weight: 600; text-transform: uppercase;
}
.badge-pendiente { background: #fef3c7; color: #92400e; }
.badge-aprobada { background: #d1fae5; color: #065f46; }
.badge-rechazada { background: #fee2e2; color: #991b1b; }

.comprobante-link { margin-top: 12px; font-size: 14px; }
.comprobante-link a { color: #2563eb; font-weight: 600; text-decoration: none; }

/* ===== PREVIEW CLASES ===== */
.preview-box {
    background: #f8fafc; border: 2px dashed #cbd5e1;
    border-radius: 10px; padding: 18px;
    margin-bottom: 16px; min-height: 80px;
}
.preview-box table { background: #fff; border-radius: 6px; overflow: hidden; }

/* ===== RESPONSIVE ===== */
@media (max-width: 640px) {
    .auth-card { padding: 28px 20px; }
    .main-content h1 { font-size: 22px; }
    .card { padding: 18px; }
    .brand { font-size: 15px; }
    th, td { padding: 10px; font-size: 13px; }
}