@import url('https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100..900;1,100..900&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Roboto+Flex:opsz,wght,XOPQ,XTRA,YOPQ,YTDE,YTFI,YTLC,YTUC@8..144,100..1000,96,468,79,-203,738,514,712&family=Roboto:ital,wght@0,100..900;1,100..900&display=swap');

:root {
    /* En desarrollo usas /nccms, en producción lo dejas vacío '' */
    --base-path: '/nccms'; 

    /* 1. COLORES DE MARCA (BRANDING) */
    /* Usar con moderación para resaltar elementos clave */
    --color-brand-primary: #03073b;   /* Azul profundo (Identidad) */
    --color-brand-accent: #ff0000;    /* Rojo (Llamadas a la acción / Alertas) */

    /* 2. SUPERFICIES Y FONDOS (NEUTROS) */
    /* Colores base para evitar la fatiga visual de los colores marca */
    --bg-main: #faf7f2;               /* Crema claro: Fondo general de página (Suave) */
    --bg-dark: #2b2b33;               /* Gris oscuro: Para pies de página o secciones destacadas */
    --bg-card: #ffffff;               /* Blanco puro: Para cajas, inputs o ventanas */

    /* 3. TIPOGRAFÍA (TEXTO) */
    /* Garantizan legibilidad sobre los fondos neutros */
    --text-dark: #2b2b33;             /* Texto principal sobre fondo claro */
    --text-light: #faf7f2;            /* Texto sobre fondos oscuros (marca o bg-dark) */
    --text-muted: #666666;            /* Para textos menos importantes */
    --text-white: #ffffff;            /* fuente blanca */

    /* 4. ELEMENTOS DE INTERFAZ (UI) */
    --border-soft: #e0ddd8;           /* Borde sutil para separar elementos */
    --input-bg: #ffffff;              /* Fondo para campos de formulario */
    --btn-primary-bg: var(--color-brand-primary);
    --btn-primary-text: var(--text-light);
}

*{
    margin:0;
    padding:0;
    text-decoration: none;
    font-size: 0.9rem;
    font-family: Arial, Verdana, Calibri, sans-serif; 
    scrollbar-width: thin;
    scrollbar-color: var(--bg-dark) transparent;
} 

/* Chrome, Edge, Safari y Opera */
::-webkit-scrollbar {
    width: 8px; /* Ancho del scroll vertical */
    height: 8px; /* Alto del scroll horizontal */
}

/* Fondo del scroll (Track) */
::-webkit-scrollbar-track {
    background: transparent;
}

/* Barra desplazable (Thumb) */
::-webkit-scrollbar-thumb {
    background-color: var(--bg-card);
    border-radius: 10px;
    border: 2px solid transparent; /* Crea un efecto de margen interno */
    background-clip: content-box;
}

/* Color al pasar el mouse */
::-webkit-scrollbar-thumb:hover {
    background-color: var(--color-brand-primary); /* O la variable que uses para resaltar */
}

/* Ocultar botones de flecha (Opcional para elegancia) */
::-webkit-scrollbar-button {
    display: none;
}

.contenido{
    width:100%;
    height:calc( 100% - 80px);
    position:fixed;
    top:80px;
    left:0;
    background-color:whitesmoke;
    z-index:0;
    overflow-x:hidden;
    overflow-y:auto;
}

.contenedor{
    width: calc( 100% - 20px);
    max-width: 1600px;
    height: auto;
    display: block; 
    margin: 0 auto;
    padding: 10px;
}
.contenedor1200{
    width: calc( 100% - 20px);
    max-width: 1200px;
    height: auto;
    display: block; 
    margin: 0 auto;
    padding: 10px;
}

.group{
    width: 100%;
    height:auto;
    display:block;
    background-color:transparent;
}
.sectionhome{
    width: calc(100% - 20px);
    height: auto;
    background-color: var(--bg-main);
    padding: 30px 10px;
}

.sectionhome_dark{
    width: calc(100% - 20px);
    height: auto;
    background-color: var(--bg-dark);
    padding: 30px 10px;
    
}
.footer{
    width: 100%;
    height: auto;
    background-color: var(--color-brand-primary);
}
.row{
    width:100%;
    height:auto;
    overflow:hidden;
    display:block;
}
.copyright{
    color: white;
    font-size: 1.5rem;
    text-align: center;
    font-family: "Roboto", sans-serif;
    padding: 10px 0;
    border-top: 1px solid var(--text-muted);
}
.footer_cols{
    display: flex;
    flex-direction: row;
    justify-content: center;
    padding: 20px 0;
}
.footer_col{
    color: white;
    font-size: clamp(1.1rem, 4vh, 1.5rem);
    text-align: center;
    padding: 0 10px;
}
.footer_col::before {
    content:"•";
    color:#ff4d4d;
    margin-right:8px;
}
.footer_slogan{
    width: calc(100% - 40px);
    padding: 0px 20px;
    color: white;
    font-size: 2rem;
    text-align: center;
    margin: 10px 0px;
}
.footer_logo{
    width: 320px;
    height: 70px;
    background-position: center;
    background-repeat: no-repeat;
    background-size: contain;
    margin: 0 auto;
    margin-top: 10px;
    margin-bottom: 10px;
} 
.slider-dinamico{   
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}
.slider-dinamico img {
    transition: opacity 1s ease-in-out;
    opacity: 1;
}
/******************************************************************************/
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    justify-content: center;
    align-items: center;
    overflow: hidden; /* Evita que la imagen se salga al crecer */
    touch-action: none; /* Bloquea el scroll del navegador */
}

/* La imagen que recibirá el zoom */
.lightbox-content {
    max-width: 90%;
    max-height: 80vh;
    object-fit: contain;
    transition: transform 0.1s ease-out; /* Transición mínima para fluidez */
    user-select: none;
    pointer-events: auto;
    will-change: transform; /* Optimiza el rendimiento en móvil */
}

/* Botón de cerrar */
.close-lightbox {
    position: absolute;
    top: 20px;
    right: 30px;
    color: white;
    font-size: 45px;
    font-weight: 100;
    cursor: pointer;
    z-index: 10001;
}

/* Pie de foto */
#lightbox-caption {
    position: absolute;
    bottom: 0px;
    color: white;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    font-size: 12px;
    padding: 20px;
    /* background-color: #000000; */
    width: calc(100% - 40px);
    text-align: center;
}

/******************************************************************************/
/* 1. CORRECCIÓN DEL CONTENEDOR FLEX (Para que el texto no salga al lado) */
#lightbox-compare.lightbox {
    flex-direction: column !important; /* Fuerza orden vertical: Imagen arriba, texto abajo */
    justify-content: center;
    align-items: center;
    padding: 20px;
    width: calc(100% - 40px);
}

/* 2. EL WRAPPER (El escenario de la comparación) */
.compare-wrapper {
    position: relative;
    width: 90vw;      
    height: 70vh;     
    max-width: 1100px;
    overflow: hidden; 
    display: block;   
    background: #000;
}

/* 3. LOS BOXES (Superposición) */
.compare-box {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.compare-box:nth-child(1) {
    z-index: 2;
    width: 50%; /* Este es el que el JS moverá */
    overflow: hidden; 
    border-right: 2px solid white;
}

/* 4. LA IMAGEN (Evita que se encoja) */
.compare-box img {
    width: 90vw;      /* Debe medir lo mismo que el .compare-wrapper */
    height: 70vh;     
    max-width: 1100px;
    object-fit: contain; /* Mantiene proporción sin deformar */
    display: block;
    pointer-events: none;
}

/* 5. LA BARRA DIVISORA */
.slider-handle {
    position: absolute;
    top: 0;
    left: 50%;
    width: 4px;
    height: 100%;
    background: white;
    z-index: 5;
    transform: translateX(-50%);
    pointer-events: none;
}

/* 6. EL PIE DE FOTO (Categoría y Etiquetas) */
#compare-caption {
    width: 100%;
    max-width: 1100px;
    text-align: center;
    color: white;
    margin-top: 15px;
}
/******************************************************************************/

/* Contenedor de botones */
.portfolio-filters {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin: 20px 0px 0px 0px;
    flex-wrap: wrap;
}

.filter-btn {
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    color: #999;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 10px 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn:hover, .filter-btn.active {
    color: #111;
    border-bottom: 2px solid #111;
}

/* Transición para las cajas de la galería */
.project-box {
    transition: opacity 0.3s ease, transform 0.3s ease;
}

#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #ffffff;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 999999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.spinner-container {
    position: relative;
    width: 100px;  
    height: 100px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.spinner {
    position: absolute;
    width: 100%;
    height: 100%;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #000065;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loader-logo {
    width: 60px;
    height: auto;
    position: relative;
    z-index: 2;
}

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

.fade-out {
    opacity: 0;
    visibility: hidden;
}


/*************************************************************************/

/* 1. HERO */
/* --- PAGE HERO SLIDER --- */

.page--hero {
    position: relative;
    width: 100%;
    height: 400px; /* Altura ajustable según prefieras */    
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background-color: var(--bg-dark); /* Fondo de seguridad */
}

/* Contenedor de imágenes */
.page--slider {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}
.hero-box{
    background-color: var(--bg-dark);
    color: var(--text-light);
    font-family: 'Roboto Flex', sans-serif;
}

.page--slider .slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0;
    transition: opacity 1.5s ease-in-out; /* Transición suave entre fotos */
}
.slider-progress-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px; /* Grosor de la línea */
    background: rgba(255, 255, 255, 0.25); /* Color de fondo (puedes usar el tuyo) */
    z-index: 10;
    transform: scaleX(0);
    transform-origin: left;
}

/* Esta clase ejecutará la animación */
.slider-progress-bar.animate {
    animation: sliderProgress 5s linear forwards;
}

@keyframes sliderProgress {
    0% { transform: scaleX(0); }
    100% { transform: scaleX(1); }
}
.page--slider .slide.active {
    opacity: 1;
}

/* Overlay para legibilidad del texto */
.page--overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6); /* Oscurece la imagen para resaltar el texto */
    z-index: 2;
}

/* --- CONTENIDO DEL HERO --- */

.page--content {
    position: relative;
    z-index: 3; /* Por encima del slider y el overlay */
    text-align: center;
    padding: 0 20px;
    max-width: 900px;
}

.title--page {
    font-size: clamp(2.8rem, 5vw, 3.5rem);
    font-weight: 700;
    color: var(--text-light);
    line-height: 1.1;
    margin-bottom: 20px;
    text-transform: uppercase;
}

.subtitle--page {
    font-size: 1.6rem;
    color: var(--text-light);
    opacity: 0.9;
    line-height: 1.6;
    max-width: 700px;
    margin: 0 auto;
}

/* --- RESPONSIVE --- */

@media (max-width: 768px) {
    .page--hero {
        height: 60vh;
    }
    
    .title--page {
        font-size: 2.5rem;
    }
}

#sms{
    width: 100%;
    height: 80px;
    background-color: beige;
    color: black;
    z-index: 999;
    position: fixed;
    top: 0;
    font-size: 1.5rem;
    text-align: center;
    line-height: 80px;
}