/* 
CSS para las unidades no Converge (Oficialia Mayor y Protocolo)
Replica el diseño de salas_no_converge.php
*/

/* Configuración base */
html, body {
    height: 100%;
    margin: 0;
    padding: 0;
}

body {
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
}

/* Sección de contenido con logo de fondo */
#content {
    flex: 1;
    background-image: url('../logos/logo_salas_detalle.png');
    background-position: bottom right;
    background-repeat: no-repeat;
    padding: 40px 20px;
    min-height: calc(100vh - 200px);
}

/* Título principal */
#content h1 {
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 40px;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
}

/* Títulos de edificio */
#content h3 {
    font-size: 1.8rem;
    font-weight: bold;
    border-bottom: 2px solid #dc3545;
    padding-bottom: 8px;
    margin-bottom: 20px;
}

/* Lista numerada de salas */
.list-group-numbered {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.list-group-item {
    border: none;
    border-bottom: 1px solid #dee2e6;
    padding: 15px 20px;
    transition: all 0.3s ease;
}

.list-group-item:last-child {
    border-bottom: none;
}

.list-group-item a {
    text-decoration: none;
    color: #212529;
    display: block;
    font-weight: 500;
    transition: all 0.3s ease;
}

.list-group-item:hover {
    background-color: #f8f9fa !important;
    transform: translateX(5px);
}

.list-group-item:hover a {
    color: #dc3545 !important;
    font-weight: bold !important;
}

/* Alertas para casos sin datos */
.alert {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    margin-top: 40px;
}

/* Responsive Design */
@media screen and (max-width: 768px) {
    #content {
        padding: 20px 15px;
    }
    
    #content h1 {
        font-size: 1.8rem;
        margin-bottom: 30px;
    }
    
    #content h3 {
        font-size: 1.4rem;
    }
    
    .list-group-item {
        padding: 12px 15px;
        font-size: 1.2em !important;
    }
    
    .col-6 {
        width: 100%;
        margin-bottom: 20px;
    }
    
    /* Ajustar logo de fondo en móvil */
    #content {
        background-size: 150px auto;
        background-position: bottom center;
    }
}

@media screen and (max-width: 480px) {
    #content h1 {
        font-size: 1.5rem;
    }
    
    #content h3 {
        font-size: 1.2rem;
    }
    
    .list-group-item {
        font-size: 1.1em !important;
    }
    
    #content {
        background-size: 120px auto;
    }
}

/* Animaciones */
@keyframes slideInFromLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

#content h1 {
    animation: slideInFromLeft 0.8s ease-out;
}

#content h3 {
    animation: fadeInUp 0.6s ease-out;
}

/* Accesibilidad */
.list-group-item a:focus {
    outline: 2px solid #dc3545;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Estados de carga */
.list-group-numbered.loading {
    opacity: 0.6;
    pointer-events: none;
}

.list-group-numbered.loading::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #dc3545;
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Print styles */
@media print {
    #content {
        background-image: none;
    }
    
    .list-group-item a {
        color: #000 !important;
    }
    
    #content h1:after {
        content: " - Impreso desde el Sistema de Reservas CSIC";
        font-size: 12px;
        color: #666;
        display: block;
        margin-top: 10px;
    }
} 