/* --- Estilos Generales (Tema Oscuro) --- */
:root {
    /* Paleta de Tema Oscuro */
    --primary-color: #4a90e2; /* Azul brillante para mejor contraste */
    --secondary-color: #e54b4b; /* Rojo brillante para acentos */
    --background-color: rgba(28, 28, 30, 0.9); /* Fondo principal oscuro con 90% opacidad */
    --element-bg: #2c2c2e; /* Fondo para elementos como tarjetas y listas */
    --text-color: #f2f2f2; /* Color de texto principal (claro) */
    --sidebar-bg: #242526; /* Fondo de la barra lateral */
    --border-color: #444; /* Color para bordes sutiles */

    /* Mapeo de variables antiguas para compatibilidad */
    --light-gray: var(--element-bg);
    --dark-gray: var(--text-color);
    
    /* Dimensiones de la barra lateral */
    --sidebar-width: 80px;
    --sidebar-width-expanded: 200px;
}

/* --- Contenedor Principal y Layout --- */
.sm-container {
    display: flex;
    position: relative;
    font-family: Arial, sans-serif;
    color: var(--text-color);
    background-color: var(--background-color);
    max-width: 1200px;
    margin: 0 auto; /* Centra el contenido si se usa fuera de un contenedor fluido */
    padding-left: var(--sidebar-width); /* Espacio para la barra lateral */
    box-sizing: border-box;
}

/* --- Barra Lateral de Navegación --- */
.sm-sidebar {
    position: absolute;
    top: 0;
    left: 0;
    width: var(--sidebar-width);
    height: 100%;
    background-color: var(--sidebar-bg);
    padding-top: 20px;
    transition: width 0.3s ease;
    z-index: 10; /* Asegura que esté por encima del contenido */
}

.sm-sidebar:hover {
    width: var(--sidebar-width-expanded);
}

.sm-nav {
    display: flex;
    flex-direction: column;
}

.sm-nav a {
    display: flex;
    align-items: center;
    color: var(--text-color);
    padding: 15px 0;
    text-decoration: none;
    transition: background-color 0.3s ease;
    overflow: hidden;
    white-space: nowrap;
}

.sm-nav a i {
    min-width: var(--sidebar-width);
    text-align: center;
    font-size: 1.8rem;
}

.sm-nav a span {
    opacity: 0;
    transition: opacity 0.2s ease;
}

.sm-sidebar:hover .sm-nav a span {
    opacity: 1;
}

.sm-nav a:hover {
    background-color: var(--primary-color);
}


/* --- Contenido Principal --- */
.sm-content {
    flex-grow: 1;
    padding: 2rem;
    box-sizing: border-box;
    width: 100%;
}

h2 {
    color: var(--primary-color);
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    border-bottom: 3px solid var(--secondary-color);
    padding-bottom: 0.5rem;
    text-transform: uppercase;
}

/* --- Carrusel de Imágenes --- */
.sm-carousel-section {
    margin-bottom: 2rem;
}

.sm-carousel {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.sm-carousel-inner {
    display: flex;
    transition: transform 0.5s ease-in-out;
}

.sm-carousel-item {
    min-width: 100%;
    box-sizing: border-box;
}

.sm-carousel-item img {
    width: 100%;
    height: auto;
    max-height: 500px;
    object-fit: cover;
    display: block;
}

.sm-carousel-control {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: 10px 15px;
    cursor: pointer;
    border-radius: 50%;
    font-size: 1.5rem;
    transition: background-color 0.3s;
}

.sm-carousel-control:hover {
    background-color: rgba(0, 0, 0, 0.8);
}

.sm-carousel-control.prev {
    left: 10px;
}

.sm-carousel-control.next {
    right: 10px;
}

.sm-no-images {
    text-align: center;
    padding: 3rem;
    background-color: var(--element-bg);
    border-radius: 8px;
}

/* --- Secciones de Texto --- */
.sm-text-section p {
    line-height: 1.7;
    margin-bottom: 1rem;
    font-size: 1.1rem;
    text-align: justify;
}

/* --- Acróstico Misión --- */
.sm-acrostic-letter {
    font-size: 4rem;
    font-weight: bold;
    color: var(--secondary-color);
    float: left;
    margin-right: 10px;
    line-height: 1;
}

/* --- Columnas divididas (Misión/Visión) --- */
.sm-split-section {
    display: flex;
    gap: 2rem;
}
.sm-split-column {
    flex: 1;
    min-width: 0;
}


/* --- Lista de Valores --- */
.sm-values-list {
    list-style: none;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.sm-values-list li {
    background-color: var(--element-bg);
    padding: 1.5rem;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: bold;
    display: flex;
    align-items: center;
    transition: transform 0.2s, box-shadow 0.2s;
}

.sm-values-list li:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.sm-values-list i {
    color: var(--primary-color);
    font-size: 1.5rem;
    margin-right: 1rem;
}

/* --- Sección de Video --- */
.sm-video-wrapper {
    position: relative;
    padding-bottom: 56.25%; /* Proporción 16:9 */
    height: 0;
    overflow: hidden;
    max-width: 100%;
    background: #000;
    border-radius: 10px;
}

.sm-video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* --- Footer de Redes Sociales --- */
.sm-social-footer {
    text-align: center;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.sm-social-footer h3 {
    color: var(--text-color);
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.sm-social-icons a {
    color: var(--text-color);
    font-size: 2rem;
    margin: 0 15px;
    transition: color 0.3s, transform 0.3s;
}

.sm-social-icons a:hover {
    color: var(--primary-color);
    transform: scale(1.2);
}

/* --- Diseño Responsivo --- */
/* Tablets (hasta 992px) */
@media (max-width: 992px) {
    .sm-container {
        flex-direction: column;
        padding-left: 0;
    }

    .sm-sidebar {
        position: static;
        width: 100%;
        height: auto;
        display: flex;
        justify-content: center;
        padding-top: 0;
        box-shadow: none;
        border-bottom: 1px solid var(--border-color);
    }
    
    .sm-sidebar:hover {
        width: 100%;
    }

    .sm-nav {
        flex-direction: row;
    }

    .sm-nav a {
        padding: 15px;
    }

    .sm-nav a span {
        display: none; /* Oculta el texto en la barra horizontal */
    }

    .sm-content {
        padding: 1.5rem;
    }

    h2 {
        font-size: 2rem;
    }

    .sm-split-section {
        flex-direction: column;
    }
}

/* Celulares (hasta 576px) */
@media (max-width: 576px) {
    .sm-content {
        padding: 1rem;
    }

    h2 {
        font-size: 1.8rem;
    }
    
    .sm-acrostic-letter {
        font-size: 3rem;
    }

    .sm-values-list {
        grid-template-columns: 1fr;
    }
    
    .sm-social-icons a {
        font-size: 1.8rem;
        margin: 0 10px;
    }
}

