/**
 * Estilos para módulos de Reembolsos en Admin
 * Grupo: Reembolsos
 */

/* =============================================================================
   CONTENEDOR GENERAL
   ============================================================================= */
.reembolsos-admin {
    padding: 10px 0;
}

.reembolsos-admin h3 {
    margin-bottom: 15px;
}

.reembolsos-admin h4 {
    margin-bottom: 10px;
    color: #333;
    font-size: 18px;
}
table p {
    font-size: 14px;
}
/* =============================================================================
   CONFIGURACIÓN DE BECAS
   ============================================================================= */

.box-beca-admin {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 15px;
    display: flex;
    flex-direction: column;
    /* background: #fafafa; */
}

.box-beca-admin h4 {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1em;
    color: #333;
}

.box-beca-admin-fila {
    display: flex;
    gap: 30px;
    align-items: flex-start;
}

.box-beca-admin-fila > h4 {
    min-width: 110px;
    margin: 10px 0 0;
}

.box-beca-admin .bloque {
    flex: 1;
    min-width: 0;
    position: relative;
}

.box-beca-admin .row {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.box-beca-admin .row > div {
    flex: 1;
    min-width: 200px;
}

.box-beca-admin label {
    display: block;
    /* font-weight: 600; */
    margin-bottom: 5px;
    font-size: 0.9em;
    color: #555;
}

.box-beca-admin input[type="text"],
.box-beca-admin input.pikaday {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 0.95em;
    box-sizing: border-box;
}

.box-beca-admin input[type="text"]:focus,
.box-beca-admin input.pikaday:focus {
    border-color: #3f51b5;
    outline: none;
}

.box-beca-admin input.invalido {
    border-color: #e74c3c;
    background-color: #fdf2f2;
}

.box-beca-admin .form__file > label {
    margin-bottom: 6px;
}

.box-beca-admin .form__file > small {
    display: block;
    margin-bottom: 8px;
    color: #666;
    font-size: 12px;
    justify-self: flex-end;
}

.box-beca-admin .form__file .text.upload {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 42px;
    padding: 0 12px;
    border: 1px solid #ccc;
    border-radius: 4px;
    background: #fff;
    box-sizing: border-box;
    max-width: 100%;
}

.box-beca-admin .form__file .text.upload .bi {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    color: #0C4497;
    font-size: 20px;
    pointer-events: none;
}

.box-beca-admin .form__file .text.upload input[type="text"] {
    border: none;
    padding: 0;
    background: transparent;
}

.box-beca-admin .form__file .text.upload input[type="text"]:focus {
    border: none;
}

.box-beca-admin .form__file .text.upload input[type="file"] {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
    left: 0;
    right: 0;
    top: 0;
    bottom: 0;
    max-width: initial;
}

.imagen-evento-rendicion {
    width: 100%;
    max-width: 250px;
    height: auto;
    border-radius: 8px;
    margin-bottom: 15px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

.item-detalle-configuracion {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px solid #f0f0f0;
}

.item-detalle-configuracion:last-child {
    border-bottom: none;
}

/* Mensajes de éxito/error en formulario */
#exito-actualizado {
    background: #d4edda;
    color: #155724;
    padding: 10px 15px;
    border-radius: 4px;
    margin-bottom: 15px;
    display: none;
}

#error-actualizado {
    background: #f8d7da;
    color: #721c24;
    padding: 10px 15px;
    border-radius: 4px;
    margin-bottom: 15px;
    display: none;
}

#errores_configurar-beca-admin {
    background: #f8d7da;
    color: #721c24;
    padding: 10px 15px;
    border-radius: 4px;
    margin-bottom: 15px;
    display: none;
}


/* =============================================================================
   ETIQUETAS DE ESTADO
   ============================================================================= */

.label-estado {
    display: inline-block;
    padding: 4px 10px;
    border-radius:4px;
    font-size: 0.8em;
    font-weight: 600;
    text-transform: capitalize;
    white-space: nowrap;
    min-width: 85px;
}

.estado-pendiente {
    background-color: #fff3cd;
    color: #856404;
}

.estado-aprobado,
.estado-aprobada {
    background-color: #d4edda;
    color: #155724;
}

.estado-rechazado,
.estado-rechazada {
    background-color: #f8d7da;
    color: #721c24;
}

.estado-en_revision {
    background-color: #cce5ff;
    color: #004085;
}

.estado-cerrado {
    background-color: #e2e8f0;
    color: #475569;
    border: 1px solid #cbd5e1;
}

.estado-no-solicita {
    background-color: #f1f5f9;
    color: #64748b;
    border: 1px solid #e2e8f0;
}

.boton-cerrar-admin {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: #fff;
    color: #dc2626 !important;
    border: 1px solid #f87171;
    border-radius: 4px;
    padding: 4px 8px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    margin-top: 4px;
}
.boton-cerrar-admin:hover {
    background: #fef2f2;
}

.boton-reabrir-admin {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: #fff;
    color: #2563eb !important;
    border: 1px solid #93c5fd;
    border-radius: 4px;
    padding: 4px 8px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    margin-top: 4px;
}
.boton-reabrir-admin:hover {
    background: #eff6ff;
}


/* =============================================================================
   BADGES
   ============================================================================= */

.badge-pendiente {
    background-color: #ffc107;
    color: #fff;
    padding: 3px 8px;
    border-radius: 10px;
    font-size: 0.75em;
    font-weight: 600;
}

.badge-aprobado,
.badge-aprobada {
    background-color: #28a745;
    color: #fff;
    padding: 3px 8px;
    border-radius: 10px;
    font-size: 0.75em;
    font-weight: 600;
}

.badge-rechazado,
.badge-rechazada {
    background-color: #dc3545;
    color: #fff;
    padding: 3px 8px;
    border-radius: 10px;
    font-size: 0.75em;
    font-weight: 600;
}


/* =============================================================================
   TIPOS DE BECA
   ============================================================================= */

.tipo-personal {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.8em;
    font-weight: 600;
    background-color: #e8f5e9;
    color: #2e7d32;
}

.tipo-colegio {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.8em;
    font-weight: 600;
    background-color: #e3f2fd;
    color: #1565c0;
}


/* =============================================================================
   TABLA DE REEMBOLSOS
   ============================================================================= */

.reembolsos-admin table.tablesorter {
    width: 100%;
    font-size: 0.9em;
}

.reembolsos-admin table.tablesorter td {
    vertical-align: middle;
}

.reembolsos-admin .form-actualizar-estado {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.reembolsos-admin .form-actualizar-estado select {
    padding: 5px 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 0.9em;
}

.reembolsos-admin .form-actualizar-estado input[type="text"] {
    padding: 5px 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 0.9em;
    min-width: 150px;
}


/* =============================================================================
   DETALLE DEL REEMBOLSO
   ============================================================================= */

.reembolsos-admin .detalle-seccion {
    background: #f9f9f9;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 15px 20px;
    margin-bottom: 15px;
}

.reembolsos-admin .detalle-seccion h4 {
    margin-top: 0;
    padding-bottom: 8px;
    border-bottom: 1px solid #e0e0e0;
}

.reembolsos-admin .info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px 20px;
    margin-top: 10px;
}

.reembolsos-admin .info-grid p {
    margin: 0;
    font-size: 0.9em;
}

.reembolsos-admin .info-grid strong {
    color: #555;
}

td small {
    font-size:12px;
}
.boton.small {
    font-size:12px !important;
}
table a.primario:hover{
    color:#fff !important;
}
/* =============================================================================
   BOTONES DE ACCIÓN
   ============================================================================= */

.reembolsos-admin .acciones-detalle {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 10px;
}


/* =============================================================================
   RESPONSIVE
   ============================================================================= */

@media (max-width: 768px) {
    .box-beca-admin-fila {
        flex-direction: column;
        gap: 15px;
    }

    .box-beca-admin-fila > h4 {
        min-width: auto;
        margin-top: 0;
    }

    .box-beca-admin .form__file {
        margin-left: 0;
    }

    .box-beca-admin .row {
        flex-direction: column;
    }

    .reembolsos-admin .info-grid {
        grid-template-columns: 1fr;
    }

    .reembolsos-admin .form-actualizar-estado {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* =============================================================================
   EXCEPCIONES DE PLAZO
   ============================================================================= */
.label-excepcion {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

.label-excepcion i {
    margin-right: 3px;
}

.excepcion-pendiente {
    background-color: #fff3cd;
    color: #856404;
    border: 1px solid #ffc107;
}

.excepcion-aprobada {
    background-color: #d4edda;
    padding: 10px;
    font-weight: 500;
}

.excepcion-rechazada {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #dc3545;
}

.excepcion-expirada {
    background-color: #e2e3e5;
    color: #383d41;
    border: 1px solid #6c757d;
}

.texto-secundario {
    color: var(--secundario) !important;
}

.tipo-beca-rendicion {
    padding: 6px 14px;
    height: 20px;
    border-radius: 5px;
    color: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    font-size: 11px;
    width: fit-content;
    font-weight: 600;
    line-height: 10px;
}

table .tipo-beca-rendicion {
    margin: 3px 2px;
    display: inline-block;
    padding: 4px 14px;
}
.tipo-alimentacion.tipo-beca-rendicion {
    background: #05C2B5;
}
.tipo-alojamiento.tipo-beca-rendicion {
    background: #E78617;
}
.tipo-transporte.tipo-beca-rendicion {
    background: #0CB7E6;
}

/* VISTA DETALLE: Etiquetas de Estado */
.label-estado {
    display: inline-block;
    padding: 5px 10px;
    border-radius: 4px;
    font-weight: bold;
    font-size: 0.9em;
    text-align: center;
    min-width: 100px;
}
.estado-pendiente {
    background-color: #fcf8e3;
    color: #8a6d3b;
    margin: 0 auto;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
}
.estado-aprobado {
    background-color: #dff0d8;
    color: #3c763d;
    margin: 0 auto;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
}
.estado-rechazado {
    background-color: #f2dede;
    color: #a94442;
    text-transform: capitalize;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
}

/* VISTA DETALLE: Etiquetas de Tipo (Personal/Colegio) */
.label-tipo {
    display: inline-block;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 0.8em;
    text-transform: uppercase;
}
.tipo-personal {
    background-color: #e3f2fd;
    color: #0d47a1;
    border: 1px solid #bbdefb;
    width: fit-content;
    margin: 0 auto;
}
.tipo-colegio {
    background-color: #e8f5e9;
    color: #1b5e20;
    border: 1px solid #c8e6c9;
    width: fit-content;
    margin: 0 auto;
}

/* ============================================
   Pestañas de becas - Revisión Reembolsos
   ============================================ */
.tabs-rendicion-nav {
    display: flex;
    gap: 5px;
    margin-bottom: 20px;
    border-bottom: 2px solid #eee;
    padding-bottom: 0;
}
.tab-btn-rendicion {
    padding: 10px 20px;
    border: none;
    border-bottom: 3px solid transparent;
    background: none;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    color: #777;
    transition: all 0.2s ease;
    border-radius: 4px 4px 0 0;
}
.tab-btn-rendicion:hover {
    color: #333;
    background-color: #f5f5f5;
}
.tab-btn-rendicion.active {
    color: #00205C;
    border-bottom-color: #00205C;
    background-color: #f0f4ff;
}
.tab-btn-rendicion.active.tipo-transporte { color: #0d6efd; border-bottom-color: #0d6efd; background-color: #e7f1ff; }
.tab-btn-rendicion.active.tipo-alojamiento { color: #6f42c1; border-bottom-color: #6f42c1; background-color: #f3eeff; }
.tab-btn-rendicion.active.tipo-alimentacion { color: #198754; border-bottom-color: #198754; background-color: #e8f5e9; }
