/* === CSS MINIMO DEPURADO (provisional) === */

/* Variables de marca (sin perder apariencia del inline) */
:root {
    --brand-stylevision: #fcbc01;
    --brand-stylemove: #002bff;
    --brand-styleglass: #06b6d4;
    --brand-stylespace: #ef4444;
    --brand-stylesmart: #22c55e;
    --brand-styledoor: #ff00f8;
}

/* Base */
html,
body {
    height: 100%;
    margin: 0;
    padding: 0;
    overflow: hidden; /* shorthand replaces overflow-x & overflow-y */

    /* NUEVO: bloquea scroll vertical del documento */
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    text-align: justify;
}

#presentation-wrapper {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100vh;

    /* NUEVO: fija a alto de ventana */
    min-height: 100vh;
    /* NUEVO: robustez en móviles */
    overflow-x: hidden;
}

#presentation-container {
    flex-grow: 1;
    position: relative;
    width: 100%;
    height: 100%;
    /* NUEVO: hereda del wrapper */
    background: #000;
    overflow: hidden;
    /* NUEVO: oculta desbordes internos */
}

/* Animaciones “eléctricas” de textos y logos (migradas del HTML) */
@keyframes electricidad-stylevision {
    0%,
    100% {
        filter: drop-shadow(0 0 2px #fff) drop-shadow(0 0 6px #ff9800);
    }

    50% {
        filter: drop-shadow(0 0 8px #fff) drop-shadow(0 0 14px #ff9800);
    }
}

.texto-electricidad-stylevision {
    animation: electricidad-stylevision 0.9s ease-in-out infinite;
    color: var(--brand-stylevision) !important;
    font-weight: 700 !important;
}

@keyframes electricidad-stylemove {
    0%,
    100% {
        filter: drop-shadow(0 0 2px #fff) drop-shadow(0 0 6px #1e40ff);
    }

    50% {
        filter: drop-shadow(0 0 8px rgb(30 64 255 / 0.9)) drop-shadow(0 0 14px #fff);
    }
}

.texto-electricidad-stylemove {
    animation: electricidad-stylemove 0.9s ease-in-out infinite;
    color: var(--brand-stylemove) !important;
    font-weight: 700 !important;
}

@keyframes electricidad-styleglass {
    0%,
    100% {
        filter: drop-shadow(0 0 2px #fff) drop-shadow(0 0 6px rgb(6 182 212 / 0.12));
    }

    50% {
        filter: drop-shadow(0 0 10px rgb(6 182 212 / 0.35));
    }
}

.texto-electricidad-styleglass {
    animation: electricidad-styleglass 0.95s ease-in-out infinite;
    color: var(--brand-styleglass) !important;
    font-weight: 800;
}

@keyframes electricidad-stylespace {
    0%,
    100% {
        filter: drop-shadow(0 0 2px #fff) drop-shadow(0 0 6px rgb(239 68 68 / 0.12));
    }

    50% {
        filter: drop-shadow(0 0 10px rgb(239 68 68 / 0.4));
    }
}

.texto-electricidad-stylespace {
    animation: electricidad-stylespace 0.95s ease-in-out infinite;
    color: var(--brand-stylespace) !important;
}

@keyframes electricidad-stylesmart {
    0%,
    100% {
        filter: drop-shadow(0 0 2px #fff) drop-shadow(0 0 6px rgb(34 197 94 / 0.12));
    }

    50% {
        filter: drop-shadow(0 0 10px rgb(34 197 94 / 0.4));
    }
}

.texto-electricidad-stylesmart,
.stylesmart-electric {
    animation: electricidad-stylesmart 0.95s ease-in-out infinite;
    color: var(--brand-stylesmart) !important;
}

@keyframes electricidad-styledoor {
    0%,
    100% {
        filter: drop-shadow(0 0 2px #fff) drop-shadow(0 0 6px rgb(255 0 248 / 0.12));
    }

    50% {
        filter: drop-shadow(0 0 10px rgb(255 0 248 / 0.4));
    }
}

.texto-electricidad-styledoor {
    animation: electricidad-styledoor 0.95s ease-in-out infinite;
    color: var(--brand-styledoor) !important;
}

/* Slides genérico */
.slide {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    visibility: hidden;
    transition:
        opacity 1s ease,
        transform 1s ease;
    display: flex;
    flex-direction: column;
    background: #fff;
    color: #000;
    box-sizing: border-box;
    padding-top: 3.5rem;
    padding-inline: clamp(1.5rem, 4vw, 3rem);
    padding-bottom: clamp(1.5rem, 3vh, 2.5rem);
    transform: translate3d(5%, 0, 0);
    overflow: hidden;
    /* NUEVO */
}

.slide.active {
    opacity: 1;
    visibility: visible;
    transform: translate3d(0, 0, 0);
}

.slide.bg-black {
    background: #000;
    color: #fff;
}

/* Numeración genérica */
.slide::before {
    content: attr(data-page);
    position: absolute;
    bottom: clamp(1rem, 4vh, 2rem);
    left: clamp(1rem, 4vw, 2rem);
    font-size: clamp(1.5rem, 3vw, 2.5rem);
    font-weight: 700;
    color: #fff;
    background: #000;
    border-radius: 999px;
    padding: 0.25rem 0.9rem;
    backdrop-filter: blur(6px);
    pointer-events: none;
    z-index: 30;
}

/* Flechas navegación */
.nav-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 56px;
    height: 56px;
    background: #000 !important;
    /* MODIFICADO */
    color: #fff !important;
    /* MODIFICADO */
    border-radius: 12px;
    box-shadow: 0 8px 24px rgb(2 6 23 / 0.28);
    border: 1px solid rgb(15 23 42 / 0.06);
    z-index: 120;
    cursor: pointer;
    transition:
        background-color 0.3s,
        opacity 0.3s;
}

.nav-arrow:hover {
    background: #111 !important;
    /* MODIFICADO */
}

.nav-arrow:active {
    background: #fff !important;
    /* NUEVO: invertir colores al presionar */
    color: #000 !important;
}

.nav-arrow:disabled,
.nav-arrow[aria-disabled='true'] {
    opacity: 0.28;
    pointer-events: none;
    filter: grayscale(60%);
}

.nav-arrow svg {
    width: 22px !important;
    height: 22px !important;
    stroke: currentColor !important;
}

.nav-arrow.left-4 {
    left: clamp(0.5rem, 2vw, 1rem);
}

.nav-arrow.right-4 {
    right: clamp(0.5rem, 2vw, 1rem);
}

@media (max-width: 640px) {
    .nav-arrow {
        width: 64px !important;
        height: 64px !important;
    }
}

/* Miniaturas */
#thumbnail-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 0;
    padding: 0;
    opacity: 0;
    transform: translateY(110%);
    pointer-events: none;
    z-index: 60;
    background: rgb(0 0 0 / 0.9);
    backdrop-filter: blur(6px);
    transition: 0.3s;
    overflow: hidden;
    /* NUEVO */
}

#presentation-wrapper.show-thumbnails #thumbnail-nav {
    height: clamp(5rem, 16vh, 8rem);
    padding: 0.75rem 1rem calc(0.75rem + env(safe-area-inset-bottom, 0));
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

#thumbnail-nav #thumbnail-container {
    height: 100%;
}

#thumbnail-container .thumb {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    aspect-ratio: 16/9;
    border: 2px solid transparent;
    border-radius: 0.5rem;
    overflow: hidden;
    flex: 0 0 auto;
    background: #000 !important;
    /* MODIFICADO */
    transition: 0.2s;
}

#thumbnail-container .thumb img {
    height: 100%;
    width: auto;
    object-fit: cover;
    display: block;
}

#thumbnail-container .thumb:hover {
    transform: scale(1.03);
    border-color: rgb(59 130 246 / 0.6);
}

#thumbnail-container .thumb.active {
    transform: scale(1.05);
    border-color: #3b82f6;
    box-shadow: 0 6px 18px rgb(59 130 246 / 0.45);
}

#thumbnail-container .thumb .label {
    position: absolute;
    bottom: 4px;
    right: 6px;
    font-size: 0.625rem;
    line-height: 1;
    background: rgb(0 0 0 / 0.55);
    color: #fff;
    padding: 2px 6px;
    border-radius: 0.25rem;
}

.thumbnail--placeholder {
    background: #000 !important;
    /* MODIFICADO (reemplaza gradiente) */
    color: #f3f4f6;
    font-size: 0.65rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Traducciones (toggle EN / FR) */
.en-inline,
.fr-inline,
.en-block,
.fr-block {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    height: 0 !important;
    overflow: hidden !important;
}

#presentation-wrapper.show-en .en-inline,
#presentation-wrapper.show-en .en-block {
    display: inline !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
    overflow: visible !important;
    color: #0ea5e9 !important;
    background: rgb(14 165 233 / 0.06);
    padding: 0.06rem 0.28rem;
    border-radius: 0.35rem;
    font-weight: 700 !important;
}

#presentation-wrapper.show-fr .fr-inline,
#presentation-wrapper.show-fr .fr-block {
    display: inline !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
    overflow: visible !important;
    color: #c026d3 !important;
    background: rgb(192 38 211 / 0.06);
    padding: 0.06rem 0.28rem;
    border-radius: 0.35rem;
    font-weight: 700 !important;
}

body.show-en .en-inline,
body.show-en .en-block {
    display: inline !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
    overflow: visible !important;
    color: #0ea5e9 !important;
    background: rgb(14 165 233 / 0.06);
    padding: 0.06rem 0.28rem;
    border-radius: 0.35rem;
    font-weight: 700 !important;
}

body.show-fr .fr-inline,
body.show-fr .fr-block {
    display: inline !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
    overflow: visible !important;
    color: #c026d3 !important;
    background: rgb(192 38 211 / 0.06);
    padding: 0.06rem 0.28rem;
    border-radius: 0.35rem;
    font-weight: 700 !important;
}

/* Utilidades generales */
video,
img.asset {
    object-fit: cover;
    width: 100%;
    height: 100%;
}

.text-shadow-sm {
    text-shadow: 1px 1px 3px rgb(0 0 0 / 0.5);
}

/* UI persistente */
#presentation-ui {
    position: fixed !important;
    z-index: 10000 !important;
    top: 3.5rem !important;
    left: 1.5rem !important;
    display: flex !important;
    gap: 12px !important;
    pointer-events: auto !important;
}

/* Botones de UI (Índice, EN, FR) */
#btn-index,
#btn-en,
#btn-fr {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    height: 36px !important;
    background-color: #000 !important;
    color: #fff !important;
    border: 1px solid rgb(255 255 255 / 0.5) !important;
    border-radius: 6px !important;
    padding: 0 16px !important;
    font-weight: 600 !important;
    font-size: 0.9rem !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer !important;
    text-decoration: none !important;
    opacity: 1 !important;
    visibility: visible !important;
    box-shadow: 0 4px 12px rgb(0 0 0 / 0.3) !important;
    transition: all 0.2s ease !important;
}

#btn-index:hover,
#btn-en:hover,
#btn-fr:hover,
#btn-index.active,
#btn-en.active,
#btn-fr.active {
    background-color: #fff !important;
    color: #000 !important;
    border-color: #fff !important;
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgb(0 0 0 / 0.4) !important;
}

#progress-indicator {
    background: #000;
    backdrop-filter: blur(4px);
    border: 1px solid rgb(255 255 255 / 0.1);
    color: #fff;
    font-weight: 600;
}

/* Slide 01: textos animados (marquee vertical) */
@keyframes scroll-words {
    0% {
        transform: translateY(var(--marquee-container));
    }

    /* aparece desde abajo */
    100% {
        transform: translateY(calc(-1 * var(--marquee-distance)));
    }

    /* sale por arriba */
}

.scrolling-words-container {
    position: absolute;
    top: 0;
    right: clamp(48px, 6vw, 96px);
    /* aumentado margen derecho */
    bottom: 0;
    width: clamp(80px, 10vw, 140px);
    overflow: hidden;
    z-index: 5;
    pointer-events: none;
    /* ELIMINADO: -webkit-mask-image y mask-image que ocultaban el texto en extremos */
}

.scrolling-words {
    position: absolute;
    top: 0;
    /* MODIFICADO: fija el origen al borde superior del track */
    width: 100%;
    animation: scroll-words var(--marquee-duration) linear infinite;
    will-change: transform;
    /* MODIFICADO: pista clara para compositor */
    --word-gap: 0;
    /* el gap ya no se usa desde CSS */
    /* AUMENTADO: más separación entre palabras */
    /* MODIFICADO: mayor separación por defecto */
    --marquee-gap: 0;
    /* valor inicial, se sobrescribe desde JS */
}

.scrolling-words span {
    display: block;
    /* necesario para que height afecte al layout */
    white-space: nowrap;
    /* ELIMINADO: escritura vertical */
    /* writing-mode: vertical-rl !important;
       text-orientation: upright !important; */
    /* AÑADIDO: rotación de palabras */
    transform: rotate(-90deg);
    transform-origin: left top;
    /* para evitar recortes al rotar */
    /* ajustado para reserva vertical coherente */
    font-weight: 700;
    color: #9ca3af;
    /* MODIFICADO: gris en lugar de blanco */
    text-shadow: 0 2px 8px rgb(0 0 0 / 0.6);
    margin: 0 auto var(--marquee-gap);
    /* el margin-bottom lo fija JS */
    /* el JS agregará margin-bottom */
    font-size: clamp(2.475rem, 8.1vw, 5.85rem);
    letter-spacing: 0.02em;
    line-height: 1;
}

.scrolling-words span:last-child {
    margin-bottom: 0;
    /* evitar gap extra al final */
}

/* Barrido logos slide 26 (derecha -> izquierda continuo) */
@keyframes logo-sweep-rl {
    0% {
        transform: translateX(110vw) scale(1);
        opacity: 0;
    }

    5% {
        opacity: 1;
    }

    95% {
        opacity: 1;
    }

    100% {
        transform: translateX(-110vw) scale(1);
        opacity: 0;
    }
}

/* Slide marcas: animación de logos (ex “Slide 25”, actual data-page="32") */
.logo-animation-container {
    display: grid;
    gap: 0 !important;
    align-content: center;
    justify-items: start;
    padding-block: 0 !important;
    /* antes: .5rem */
}

/* Quitar márgenes/paddings en figuras e imágenes dentro del contenedor de marcas */
.slide--brand-range .logo-animation-container > * {
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
}

.slide--brand-range figure.sliding-logo {
    display: block;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    line-height: 0 !important;
}

.slide--brand-range .sliding-logo {
    width: 100%;
    display: flex !important;
    align-items: center;
}

.slide--brand-range .sliding-logo img {
    width: 100% !important;
    max-width: clamp(180px, 52%, 340px) !important;
    max-height: clamp(64px, 9.5vw, 136px);
    height: auto !important;
    transform: none !important;
    object-fit: contain;
    margin: 0 auto 0;
}

.slide--brand-range .logo-animation-container > .sliding-logo:last-child {
    margin-bottom: clamp(8px, 2vh, 20px);
}

.slide--brand-range .brand-range__heading {
    margin-bottom: clamp(6px, 1.5vw, 16px) !important;
}

.slide--brand-range .brand-range__left {
    display: flex !important;
    justify-content: space-between !important;
    align-self: stretch;
    min-height: calc(100vh - clamp(12px, 3vh, 24px));
}

.slide--brand-range .brand-range__right {
    position: relative;
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    min-height: calc(100vh - clamp(12px, 3vh, 24px));
}

.slide--brand-range .brand-range__inner {
    padding-bottom: clamp(12px, 3vh, 24px);
}

.slide--brand-range .brand-contact-overlay {
    position: absolute;
    right: clamp(12px, 4vw, 48px);
    bottom: clamp(28px, 6vh, 64px);
}

.slide--brand-range .logo-animation-container {
    display: flex !important;
    flex-direction: column;
    gap: 0 !important;
    row-gap: 0 !important;
    line-height: 0 !important;
    transform: scale(0.9);
    transform-origin: left center;
    flex: 1;
    justify-content: flex-start;
}

.slide--brand-range .brand-contact-overlay .brand-contact__logo,
.slide--brand-range .brand-contact-overlay .brand-contact__info > * {
    opacity: 0;
}

/* ==========================================================================
   EFECTOS DE CRISTAL ESMERILADO PARA TARJETAS SLIDE 04
   ========================================================================== */

/* Efecto cristal para las tarjetas de productos en slide 04 */
.product-card {
    position: relative;
    overflow: hidden;
}

.product-card .bg-white\/10 {
    background: linear-gradient(
        135deg,
        rgb(255 255 255 / 0.15) 0%,
        rgb(255 255 255 / 0.08) 50%,
        rgb(255 255 255 / 0.05) 100%
    ) !important;
    backdrop-filter: blur(15px) saturate(180%) brightness(1.1) !important;
    -webkit-backdrop-filter: blur(15px) saturate(180%) brightness(1.1) !important;
    border-radius: 20px !important;
    box-shadow:
        0 8px 32px rgb(0 0 0 / 0.1),
        0 4px 16px rgb(0 0 0 / 0.08),
        inset 0 1px 0 rgb(255 255 255 / 0.2) !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.product-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        120deg,
        rgb(255 255 255 / 0.25) 0%,
        rgb(255 255 255 / 0.1) 45%,
        rgb(255 255 255 / 0.05) 78%,
        transparent 100%
    );
    opacity: 0.6;
    pointer-events: none;
    z-index: 0;
    border-radius: 20px;
}

.product-card:hover .bg-white\/10 {
    transform: translateY(-8px) scale(1.02) !important;
    box-shadow:
        0 16px 48px rgb(0 0 0 / 0.15),
        0 8px 24px rgb(0 0 0 / 0.1),
        inset 0 1px 0 rgb(255 255 255 / 0.3) !important;
}

/* Variantes de cristal por sistema */
.product-card:nth-child(1) .bg-white\/10 {
    border-color: rgb(0 188 212 / 0.4) !important;
}

.product-card:nth-child(2) .bg-white\/10 {
    border-color: rgb(244 67 54 / 0.4) !important;
}

.product-card:nth-child(3) .bg-white\/10 {
    border-color: rgb(255 193 7 / 0.4) !important;
}

.product-card:nth-child(4) .bg-white\/10 {
    border-color: rgb(76 175 80 / 0.4) !important;
}

.product-card:nth-child(5) .bg-white\/10 {
    border-color: rgb(255 0 248 / 0.4) !important;
}

/* Fallback para navegadores sin soporte backdrop-filter */
@supports not (backdrop-filter: blur(1px)) {
    .product-card .bg-white\/10 {
        background: linear-gradient(
            135deg,
            rgb(255 255 255 / 0.25) 0%,
            rgb(255 255 255 / 0.15) 100%
        ) !important;
    }
}

/* Scroll vertical por slide (especialmente útil en pantallas pequeñas cuando el contenido se extiende) */
@media (max-width: 768px),
(max-height: 720px) {
    .slide {
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        overscroll-behavior-y: contain;
    }
}