/* =========================================
   1. Estilo General y Centrado Total
   ========================================= */
html, body {
    height: 100%;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #ffffff;
    display: flex;
    justify-content: center; 
    align-items: flex-start; 
    padding-top: 50px;
}

.container {
    width: 95%;
    max-width: 1300px; 
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center; 
}

h1 {
    color: #00447b;
    font-size: 32px;
    margin-bottom: 30px;
    font-weight: bold;
    text-align: center;
}

/* =========================================
   2. Tabla Institucional Centrada
   ========================================= */
.cas-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    border: 1px solid #dee2e6;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.cas-table thead th {
    background-color: #004481; /* Azul institucional */
    color: #ffffff;
    padding: 15px;
    border: 1px solid #00447b;
    text-align: center !important;
}

.cas-table td {
    padding: 12px;
    border: 1px solid #dee2e6;
    vertical-align: middle !important;
    text-align: center !important; /* Centrado forzado */
    color: #333;
}

.cas-table tr:nth-child(even) {
    background-color: #f8f9fa;
}

/* =========================================
   3. Manejo de Múltiples Archivos (NUEVO)
   ========================================= */
.file-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    align-items: center; /* Centra la lista en la celda */
    justify-content: center;
}

.file-list li {
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    justify-content: center; /* Centra icono y texto */
    width: 100%;
}

.file-list li::before {
    content: "\f15c";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    margin-right: 8px;
    color: #dc3545; /* Rojo PDF */
    font-size: 0.9em;
}

.link-multiple {
    font-size: 0.85em;
    text-decoration: none;
    color: #004481;
    font-weight: 500;
    transition: 0.2s;
}

.link-multiple:hover {
    text-decoration: underline;
    color: #002a50;
}

/* =========================================
   4. Botones y Estados
   ========================================= */
.btn-status {
    display: inline-block;
    padding: 8px 20px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: bold;
    font-size: 13px;
    text-align: center;
}

.btn-blue {
    background-color: #007bff;
    color: white;
}

.btn-gray {
    background-color: #e9ecef;
    color: #6c757d;
    cursor: not-allowed;
    border: 1px solid #dee2e6;
}

.status-tag {
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: bold;
    display: inline-block;
    min-width: 85px;
    text-align: center;
    text-transform: uppercase;
}

.status-open { background-color: #28a745; color: white; }
.status-process { background-color: #ffc107; color: #333; }
.status-closed { background-color: #dc3545; color: white; }
.status-finalized { background-color: #6c757d; color: white; }

/* Efecto de rotación para carga */
.spinner {
    display: inline-block;
    width: 15px;
    height: 15px;
    border: 3px solid rgba(255,255,255,.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
    margin-right: 10px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.ayuda-contenedor {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 15px;
        margin-bottom: 30px;
    }

    /* Botón Principal: Manual */
    .btn-manual-principal {
        background-color: #f8f9fa;
        color: #003366;
        padding: 12px 25px;
        border: 2px solid #003366;
        border-radius: 8px;
        text-decoration: none;
        font-weight: bold;
        display: inline-flex;
        align-items: center;
        gap: 10px;
        transition: all 0.3s ease;
        width: fit-content;
    }

    .btn-manual-principal:hover {
        background-color: #003366;
        color: white;
    }

    /* Fila de Anexos */
    .anexos-fila {
        display: flex;
        justify-content: center;
        gap: 20px;
        width: 100%;
    }

    .anexo-item {
        background: #f8f9fa;
        padding: 8px 15px;
        border: 1px solid #dee2e6;
        border-radius: 5px;
        font-weight: bold;
        font-size: 14px;
        display: flex;
        align-items: center;
        gap: 8px;
    }

    .anexo-item a {
        text-decoration: none;
        font-size: 18px;
        color: #dc3545; /* Rojo para PDF/Docx */
    }