/* ==========================================================================
   OTI - CUSTOM STYLES (Diseño Moderno Conservando Identidad)
   ========================================================================== */

:root {
    /* Paleta OTI - Azul Original Modernizado */
    --oti-blue: #1a4bb8;      /* Azul principal vibrante (Barra superior y Menu) */
    --oti-blue-dark: #103487; /* Azul más oscuro para footer y hover */
    --oti-accent: #3b82f6;    /* Azul claro brillante para detalles */
    --corporate-light: #f4f7fa; 
    --text-dark: #2d3748;
    
    /* Tipografía y Espacios */
    --font-primary: 'Inter', sans-serif;
    --transition: all 0.3s ease-in-out;
    --shadow-soft: 0 10px 30px rgba(0, 0, 0, 0.05);
    --shadow-hover: 0 15px 35px rgba(26, 75, 184, 0.15);
}

body {
    font-family: var(--font-primary);
    background-color: var(--corporate-light);
    color: var(--text-dark);
    -webkit-font-smoothing: antialiased;
}

/* --- Utilidades --- */
.bg-oti-blue { background-color: var(--oti-blue) !important; }
.bg-corporate-light { background-color: var(--corporate-light) !important; }
.text-oti-blue { color: var(--oti-blue) !important; }
.text-accent { color: var(--oti-accent) !important; }
.letter-spacing-2 { letter-spacing: 2px; }
.text-sm { font-size: 0.9rem; }
.opacity-25 { opacity: 0.25; }
.opacity-75 { opacity: 0.75; }
.transition { transition: var(--transition); }
.hover-white:hover { color: #ffffff !important; text-decoration: none; }
.border-oti { border-color: var(--oti-blue) !important; border-width: 3px !important; }

/* --- Botones --- */
.btn-oti-primary {
    background-color: var(--oti-blue);
    color: #fff;
    border: none;
    font-weight: 600;
    transition: var(--transition);
}
.btn-oti-primary:hover {
    background-color: var(--oti-blue-dark);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}
.btn-user-role {
    color: var(--oti-blue) !important;
    font-weight: 700;
    background: var(--corporate-light);
    border-radius: 20px;
    padding: 8px 20px !important;
    display: inline-flex;
    align-items: center;
}

/* --- Navegación (Navbar) --- */
.corporate-nav {
    z-index: 1030;
}
.navbar-light .navbar-nav .nav-link {
    color: #4a5568;
    font-weight: 600;
    font-size: 15px;
    padding: 25px 15px;
    position: relative;
    transition: var(--transition);
}
.navbar-light .navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    bottom: 12px;
    left: 15px;
    right: 15px;
    height: 3px;
    background-color: var(--oti-blue);
    border: none !important; /* Evita conflicto con el triángulo de dropdown de Bootstrap */
    margin: 0 !important;
    vertical-align: baseline !important;
    transform: scaleX(0);
    transition: transform 0.3s ease;
    border-radius: 2px;
}
.navbar-light .navbar-nav .nav-link:hover::after,
.navbar-light .navbar-nav .nav-link.active::after {
    transform: scaleX(1);
}
.navbar-light .navbar-nav .nav-link:hover,
.navbar-light .navbar-nav .nav-link.active {
    color: var(--oti-blue) !important;
}

/* --- Ajuste específico de la línea azul para el botón de Rol --- */
.navbar-light .navbar-nav .nav-link.btn-user-role::after {
    bottom: 3px; /* Baja la línea para que no pise el texto ni el ícono */
    left: 20px;
    right: 20px;
    height: 2.5px;
}
.navbar-light .navbar-nav .show > .nav-link.btn-user-role::after {
    transform: scaleX(1);
}

.dropdown-menu {
    border: none;
    border-radius: 8px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.08);
}
.dropdown-item {
    padding: 10px 20px;
    font-weight: 500;
    font-size: 14.5px;
    transition: background-color 0.2s;
}
.dropdown-item:hover {
    background-color: var(--corporate-light);
    color: var(--oti-blue);
}

/* --- Hero Carrusel (Actualizado a gris elegante) --- */
.hero-overlay {
    position: relative;
    background-color: #1a1d24; /* Gris oscuro/carbón neutro */
}
.hero-img {
    height: 75vh;
    object-fit: cover;
    opacity: 0.55; /* Deja ver el gris de fondo sin teñir de azul la foto original */
}
.carousel-caption {
    top: 0;
    bottom: 0;
    z-index: 10;
}

/* --- Tarjetas (Cards) de Contacto Flotantes --- */
.relative-overlap {
    position: relative;
    z-index: 20;
    margin-top: -80px; 
}
.info-card {
    border: 1px solid rgba(0,0,0,0.03);
    transition: var(--transition);
}
.info-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-soft) !important;
}

/* --- Equipo Carousel --- */
.team-card {
    border: 1px solid rgba(0,0,0,0.04);
    transition: var(--transition);
}
.team-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover) !important;
}

/* --- Galería --- */
.gallery-card {
    border: 1px solid rgba(0,0,0,0.04);
    border-radius: 12px; /* Bordes un poco más suaves */
}
.gallery-img {
    height: 350px; /* Aumentamos el tamaño de 260px a 350px para que no se vea chica */
    object-fit: cover;
    transition: transform 0.6s ease; /* Transición suave para el zoom */
}
.gallery-card:hover .gallery-img {
    transform: scale(1.08); /* Efecto zoom elegante al pasar el ratón */
}
.gallery-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(26, 75, 184, 0.9); /* Azul un pelín más opaco para que las letras resalten bien */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center; /* Fuerza el centrado en textos de varias líneas */
    padding: 2rem; /* Relleno vital para que el texto NO pegue de los lados */
    opacity: 0;
    transition: var(--transition);
}
.gallery-overlay h5 {
    line-height: 1.5; /* Separa un poco las líneas si el título es muy largo */
    font-size: 1.3rem; /* Título un poco más grande y legible */
}
.gallery-card:hover .gallery-overlay {
    opacity: 1;
}

/* --- Back to Top --- */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    z-index: 999;
    display: none; 
}