@charset "utf-8";
/* CSS Document */

/* --- RESET & BASE --- */
* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    background: #2d4169;
    background: radial-gradient(circle,rgba(45, 65, 105, 1) 0%, rgba(35, 17, 51, 1) 100%);
    color: #f0f0f0;
    font-family: 'Helvetica Neue', 'Montserrat', sans-serif;
    overflow-x: hidden;
    width: 100vw;
}

/* --- CURSOR --- */
.cursor {
    width: 20px; height: 20px; border: 1px solid white; border-radius: 50%;
    position: fixed; left: 0; top: 0; pointer-events: none; z-index: 2147483647;
    transition: width 0.3s, height 0.3s, opacity 0.2s;
    mix-blend-mode: difference;
    will-change: transform;
    opacity: 0;
}
.cursor.visible { opacity: 1; }
.cursor.active { width: 80px; height: 80px; background-color: white; border: none; }

/* Ocultar cursor nativo solo sobre elementos del menu overlay */
.menu-toggle,
.menu-toggle span,
.overlay-link,
.overlay-close { cursor: none; }

/* --- HEADER (ESTILO UNIFICADO) --- */
.header-bar {
    position: fixed; top: 0; left: 0; width: 100%; height: 100px; z-index: 1000;
    display: flex; justify-content: space-between; align-items: center; padding: 0 40px;
    background: linear-gradient(to bottom, rgba(0,0,0,0.8), transparent);
    pointer-events: none;
}

.logo-mini { width: 80px; pointer-events: auto; mix-blend-mode: normal; cursor: pointer; }
.logo-mini a { cursor: pointer; display: block; }
.logo-mini img { width: 100%; display: block; cursor: pointer;}

.header-right { display: flex; align-items: center; gap: 30px; pointer-events: auto; }

.section-title {
    font-family: 'Montserrat', sans-serif; font-weight: 900; font-size: 24px;
    text-transform: uppercase; letter-spacing: 2px;
    background: linear-gradient(90deg, #FF6B00 0%, #FF006E 100%);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* --- HAMBURGER TOGGLE --- */
.menu-toggle {
    width: 60px; height: 60px; display: flex; flex-direction: column;
    justify-content: center; align-items: center; gap: 6px; cursor: none; z-index: 2000;
    transition: transform 0.3s ease;
}

.menu-toggle:hover { transform: scale(1.15); }

.menu-toggle span { 
    display: block; width: 30px; height: 2px; background-color: #fff; 
    transition: all 0.3s ease; 
}

.menu-toggle:hover span { background: linear-gradient(90deg, #FF6B00 0%, #FF006E 100%); }

.menu-toggle.open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.menu-toggle.open span:nth-child(2) { opacity: 0; }
.menu-toggle.open span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* --- FEATURE SECTION (MAPS INFO) --- */
.feature-section {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 120px 20px 60px 20px; 
    display: flex;
    flex-direction: column;
    gap: 60px;
    cursor: auto !important;
}

.feature-section * {
    cursor: auto;
}

/* Feature Images */
.feature-single-row { width: 100%; margin-bottom: 20px; }

.feature-top-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    width: 100%;
}

.feature-card { display: flex; flex-direction: column; gap: 20px; }

.feature-img-wrapper {
    width: 100%; overflow: hidden; border-radius: 10px; position: relative;
    cursor: pointer !important; 
}

/* AJUSTE CLAVE 1: El contenedor se adapta */
.feature-single-row .feature-img-wrapper { aspect-ratio: auto; }
.feature-top-row .feature-img-wrapper { aspect-ratio: 16/10; }

.feature-img-wrapper img {
    width: 100%; height: 100%; object-fit: cover; display: block;
    transition: transform 0.5s ease;
}

/* AJUSTE CLAVE 2: La imagen recupera su altura natural en la fila simple */
.feature-single-row .feature-img-wrapper img {
    height: auto !important;
    position: relative;
}

.feature-img-wrapper:hover img { transform: scale(1.03); }

.feature-text h3 {
    font-family: 'Montserrat', sans-serif; font-weight: 700; font-size: 1.2rem;
    margin-bottom: 10px; color: #fff;
}

.feature-text p {
    font-weight: 300; font-size: 0.95rem; line-height: 1.6;
    color: #ccc; margin-bottom: 15px;
}

.feature-text-bottom {
    max-width: 1000px; margin: 0 auto; text-align: left; width: 100%; 
}

.feature-text-bottom .feature-list { display: block; margin-top: 20px; }
.feature-text-bottom .feature-list li { justify-content: flex-start; }

.feature-list { list-style: none; padding: 0; }

.feature-list li {
    display: flex; align-items: center; gap: 10px;
    font-size: 0.9rem; font-weight: 400; color: #ddd; margin-bottom: 8px;
}

.feature-list li::before {
    content: ''; display: block; width: 8px; height: 8px;
    border-radius: 50%; background: linear-gradient(90deg, #FF6B00 0%, #FF006E 100%);
    flex-shrink: 0;
}

/* --- BEFORE / AFTER SLIDER --- */
.ba-container {
    width: 100%; position: relative; border-radius: 10px; overflow: hidden;
    aspect-ratio: 16/9; cursor: pointer !important; 
}

.ba-img-wrapper {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%; overflow: hidden;
}
.ba-img-wrapper img { width: 100%; height: 100%; object-fit: cover; display: block; }

.ba-bg { z-index: 1; }
.ba-overlay { 
    z-index: 2; width: 50%; border-right: 2px solid #fff; 
    position: absolute; top: 0; left: 0; height: 100%;
}
.ba-overlay img { width: auto; height: 100%; max-width: none; }

.ba-handle {
    position: absolute; top: 50%; left: 50%;
    width: 40px; height: 40px; background: #fff;
    border-radius: 50%; z-index: 3;
    transform: translate(-50%, -50%);
    display: flex; justify-content: center; align-items: center;
    box-shadow: 0 0 15px rgba(0,0,0,0.5); pointer-events: none; 
}
.ba-handle::after { content: '↔'; color: #000; font-weight: bold; }

.ba-range {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    opacity: 0; z-index: 4; margin: 0; cursor: pointer !important;
}

/* --- PORTFOLIO GRID --- */
.portfolio-grid {
    display: grid; width: 100%; 
    grid-template-columns: repeat(5, 1fr); 
    gap: 0; padding-top: 0;
}

.grid-item { 
    position: relative; width: 100%; aspect-ratio: 3 / 4; 
    overflow: hidden; background-color: #000;
}

.grid-item img {
    width: 100%; height: 100%; object-fit: cover; display: block;
    transition: transform 0.5s ease, filter 0.3s ease; opacity: 0.9; 
}

.grid-item:hover img { transform: scale(1.05); filter: brightness(1.1); opacity: 1; }

/* --- OVERLAY MENU --- */
.nav-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background-color: rgba(10, 10, 10, 0.98); z-index: 2147483640;
    display: flex; flex-direction: column; justify-content: center; align-items: center;
    opacity: 0; visibility: hidden; transition: opacity 0.4s ease, visibility 0.4s ease;
}
.nav-overlay.open { opacity: 1; visibility: visible; }

.overlay-close {
    position: absolute; top: 30px; right: 40px; background: transparent;
    border: none; color: #fff; font-family: 'Montserrat', sans-serif;
    font-weight: 100; font-size: 4rem; line-height: 1; cursor: none;
    transition: transform 0.3s ease, color 0.3s ease;
}
.overlay-close:hover { color: #FF006E; transform: rotate(90deg); }

.overlay-menu { display: flex; flex-direction: column; gap: 2vh; text-align: center; }
.overlay-link {
    text-decoration: none; font-size: 4vw; font-weight: 900; text-transform: uppercase; 
    background: linear-gradient(90deg, #ccff00 0%, #ffff00 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    -webkit-text-stroke: 0px; transition: transform 0.4s ease;
}
.overlay-link:hover {
    background: linear-gradient(90deg, #FF6B00 0%, #FF006E 100%);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; -webkit-text-stroke: 0px;
    mix-blend-mode: normal; transform: translateX(20px);
}

/* --- LIGHTBOX (CORREGIDO) --- */
.lightbox {
    position: fixed; top: 0; left: 0; width: 100vw; height: 100dvh;
    background: rgba(0,0,0,0.92); /* Fondo oscuro para resaltar */
    z-index: 5000;
    display: none; 
    flex-direction: column; 
    justify-content: center; align-items: center;
    overflow: hidden;
}
.lightbox.active { display: flex; }

.lightbox-content {
    max-width: 90vw; 
    max-height: 75vh; max-height: 75dvh; 
    object-fit: contain;
    box-shadow: 0 0 50px rgba(0,0,0,0.8);
    pointer-events: auto; 
    border-radius: 10px; /* Radio suavizado */
    user-select: none;
    margin: 0; /* IMPORTANTE: Margin 0 para centrado correcto con caption */
    display: block;
}

.lb-caption {
    position: relative; z-index: 6000; 
    margin-top: 15px; /* Separación controlada */
    color: #ffffff;
    font-family: 'Montserrat', sans-serif; font-weight: 200; font-size: 16px; 
    text-align: center; letter-spacing: 1.5px; line-height: 1.4;
    max-width: 90%; opacity: 0.9; display: block;
    padding: 0;
}

.lb-btn {
    position: absolute; top: 50%; transform: translateY(-50%);
    background: transparent; border: none; color: #fff;
    font-size: 3rem; padding: 20px; z-index: 5001;
    transition: color 0.3s ease, transform 0.2s ease;
    font-family: 'Montserrat', sans-serif; font-weight: 100;
}
.lb-btn:hover { color: #FF006E; transform: translateY(-50%) scale(1.2); }
.lb-prev { left: 20px; }
.lb-next { right: 20px; }

/* Ocultar botones si se abre una imagen individual */
.lightbox.single-view .lb-btn.lb-prev, 
.lightbox.single-view .lb-btn.lb-next { display: none; }

.lb-close {
    position: absolute; top: 20px; right: 30px;
    font-size: 2rem; transform: none;
}
.lb-close:hover { transform: scale(1.2); }

/* --- FOOTER --- */
.footer {
    padding: 40px 0; background-color: #0a0a0a; color: #ffffff;
    mix-blend-mode: difference; font-size: 12px; font-weight: 300;
    letter-spacing: 1px; text-transform: lowercase; text-align: center; width: 100%;
}
span.caja_ultima_linea_footer {
    background-color: rgba(0, 0, 0, 0.6); padding: 8px 20px; 
    border-radius: 50px; width: auto; white-space: nowrap;
    box-shadow: 0 0 10px rgba(0,0,0,0.5);
    border: 1px solid rgba(255,255,255,0.3); 
}
.footer .caja_ultima_linea_footer a {
    color: #ccff00; text-decoration: none; font-weight: 500; transition: color 0.3s ease;
}
.footer .caja_ultima_linea_footer a:hover {
    background: linear-gradient(90deg, #FF6B00 0%, #FF006E 100%);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; display: inline-block; transform: scale(1.02);
}
.text_footer_email_1 {font-size: 16px!important;}
.phone-link { text-decoration: none; color: #fff; cursor: pointer; transition: color 0.3s ease; }
.phone-link:hover { color: #FF006E; }
.text_footer_email_2 { background: #fff; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }

/* ==========================================================================
   RESPONSIVE MEDIA QUERIES
   ========================================================================== */

/* 1. ESCRITORIO GRANDE */
@media (min-width: 1200px) {
    .portfolio-grid { grid-template-columns: repeat(5, 1fr); } /* 5 columnas en Maps */
}

/* 2. TABLET */
@media (max-width: 1024px) {
    .portfolio-grid { grid-template-columns: repeat(3, 1fr); }
    .feature-top-row { gap: 30px; }
    .ba-container { aspect-ratio: 16/10; }
}

/* 3. MÓVIL VERTICAL (<768px) - ESTILOS UNIFICADOS */
@media (max-width: 768px) {
    .header-bar { 
        position: fixed !important; 
        top: 15px !important;       
        left: 15px !important;      
        right: 15px !important;     
        
        transform: none !important; 
        margin-top: 0 !important;
        
        width: auto;     
        height: 70px;
        
        padding: 5px 15px; 

        z-index: 9999; 
        border: none; 
        border-radius: 0; 
        background: transparent; 
        backdrop-filter: blur(5px); 
        -webkit-backdrop-filter: blur(5px);
    }

    .header-bar::before {
        content: "";
        position: absolute;
        inset: 0;
        border-radius: 0; 
        padding: 1px; 
        background: linear-gradient(90deg, #ccff00 0%, #ffff00 100%);
        -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
        -webkit-mask-composite: xor;
        mask-composite: exclude;
        pointer-events: none;
        z-index: -1;
    }

    /* Ajustes Header Content */
    .section-title { 
        font-size: 16px; 
        margin-left: 5px; 
    }
    
    .logo-mini { 
        width: 60px; 
        padding-left: 0 !important;
        margin-left: -8px; 
    }
    
    .header-right { 
        gap: 10px; 
        margin-right: -12px; 
    }

    /* Grid y Layout Móvil */
    .portfolio-grid { grid-template-columns: repeat(2, 1fr); }
    
    /* Feature Section Mobile */
    .feature-section { padding-top: 100px; gap: 17px; }
    .feature-top-row { grid-template-columns: 1fr; gap: 17px; }
    .ba-container { aspect-ratio: 4/3; }
    
    /* Fila simple en móvil también debe ser auto */
    .feature-single-row .feature-img-wrapper { aspect-ratio: auto; }

    /* UI */
    .overlay-close { top: 20px; right: 20px; font-size: 3rem; }
    .overlay-link { font-size: 10vw; }
    .cursor { display: none; }
    
    .lb-btn { font-size: 2rem; padding: 10px; }
    .lb-prev { left: 5px; }
    .lb-next { right: 5px; }
    
    .lb-caption { font-size: 14px; margin-top: 15px; width: 90%; }
    .lightbox-content { max-height: 65vh; }
}

/* 4. MÓVIL HORIZONTAL (LANDSCAPE) */
@media (max-height: 600px) and (orientation: landscape) {
    .header-bar { 
        position: absolute !important; /* Se mueve con el scroll */
        
        top: 15px !important;
        left: 15px !important;
        right: 15px !important;
        width: auto;
        
        height: 60px; 
        padding: 0 20px; 
        
        backdrop-filter: blur(5px);
        -webkit-backdrop-filter: blur(5px);
        background: transparent; 
    }

    /* Reset grids */
    .portfolio-grid { 
        grid-template-columns: repeat(4, 1fr); 
        padding-top: 0 !important; 
    }
    
    .logo-mini { width: 50px; }
    .section-title { font-size: 14px; }
    
    .overlay-link { font-size: 8vh; }
    
    .lightbox-content { max-height: 85dvh; }
    .lb-caption { font-size: 12px; margin-top: 10px; }
}

/* =========================================
   EFECTO GLITCH PARA LOGO (CORREGIDO: Z-INDEX SUPERIOR)
   ========================================= */

.efecto_glitch_logo_header {
    /* Variables */
    --glitch-cyan: #00f0ff;
    --glitch-pink: #ff0099;
    
    position: relative;
    display: inline-block; 
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
    text-decoration: none;
    /* Importante: permite que los hijos se ordenen en 3D si fuera necesario */
    transform-style: preserve-3d; 
}

/* La imagen original (BASE) */
.efecto_glitch_logo_header img {
    position: relative;
    display: block;
    /* Z-INDEX BAJO: La imagen original se queda abajo como "base" */
    z-index: 1; 
}

/* Pseudo-elementos (FANTASMAS GLITCH) */
.efecto_glitch_logo_header::before,
.efecto_glitch_logo_header::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    
    /* Cargamos la misma imagen */
    background-image: url('images_advertising_animation_studio/logo_goonie_studio_animation_branding_illustration_storyboard_studio.gif');
    background-size: 100% 100%;
    background-repeat: no-repeat;
    background-position: center;
    
    background-color: transparent !important;
    opacity: 0; 
    
    /* Z-INDEX ALTO: Ahora están ENCIMA de la imagen original */
    z-index: 2; 
    
    pointer-events: none;
    
    /* MEZCLA: Esto es vital. 'hard-light' o 'screen' hace que 
       el fantasma se fusione con la imagen de abajo en lugar de taparla */
    mix-blend-mode: hard-light; 
}

/* --- ESTADO HOVER --- */

/* 1. La imagen base vibra un poco */
.efecto_glitch_logo_header:hover img {
    animation: glitch-main-shake 0.4s infinite cubic-bezier(0.25, 0.46, 0.45, 0.94) both;
}

/* 2. Fantasma Cyan (ENCIMA) */
.efecto_glitch_logo_header:hover::before {
    opacity: 0.9; /* Bien visible */
    /* Usamos drop-shadow para colorear la silueta */
    filter: drop-shadow(-3px 0px var(--glitch-cyan)); 
    animation: glitch-anim-1 0.4s infinite cubic-bezier(0.25, 0.46, 0.45, 0.94) both;
}

/* 3. Fantasma Rosa (ENCIMA) */
.efecto_glitch_logo_header:hover::after {
    opacity: 0.9; /* Bien visible */
    filter: drop-shadow(3px 0px var(--glitch-pink)); 
    animation: glitch-anim-2 0.4s infinite cubic-bezier(0.25, 0.46, 0.45, 0.94) reverse both;
}

/* --- KEYFRAMES --- */
@keyframes glitch-main-shake {
    0% { transform: translate(0); }
    20% { transform: translate(-1px, 1px); }
    40% { transform: translate(-1px, -1px); }
    60% { transform: translate(1px, 1px); }
    80% { transform: translate(1px, -1px); }
    100% { transform: translate(0); }
}

@keyframes glitch-anim-1 {
    0% { clip-path: inset(20% 0 80% 0); transform: translate(-3px, 0); }
    20% { clip-path: inset(60% 0 10% 0); transform: translate(3px, 0); }
    40% { clip-path: inset(40% 0 50% 0); transform: translate(-3px, 0); }
    60% { clip-path: inset(80% 0 5% 0); transform: translate(3px, 0); }
    80% { clip-path: inset(10% 0 60% 0); transform: translate(-3px, 0); }
    100% { clip-path: inset(30% 0 30% 0); transform: translate(3px, 0); }
}

@keyframes glitch-anim-2 {
    0% { clip-path: inset(10% 0 60% 0); transform: translate(3px, 0); }
    20% { clip-path: inset(30% 0 20% 0); transform: translate(-3px, 0); }
    40% { clip-path: inset(70% 0 10% 0); transform: translate(3px, 0); }
    60% { clip-path: inset(20% 0 50% 0); transform: translate(-3px, 0); }
    80% { clip-path: inset(50% 0 30% 0); transform: translate(3px, 0); }
    100% { clip-path: inset(0% 0 80% 0); transform: translate(-3px, 0); }
}