/* ==========================================================================
   1. VARIABLES Y ESTILOS GLOBALES
   ========================================================================== */
:root {
    --brand-cyan: #00FFFF;
    --brand-cyan-rgb: 0, 255, 255;
    --brand-magenta: #FF00FF;
    --brand-blue: #007BFF;
    --dark-bg: #121212;
    --dark-bg-secondary: #1A1A1A;
    --light-text: #E0E0E0;
    --medium-text: #A0A0A0;
    --font-primary: 'Poppins', sans-serif;
    --font-headings: 'Montserrat', sans-serif;
    --dark-bg-rgb: 18, 18, 18;
    --dark-bg-secondary-rgb: 26, 26, 26;
    --header-height: 80px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--dark-bg);
    color: var(--light-text);
    font-family: var(--font-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    width: 90%;
    max-width: 1100px;
    margin: 0 auto;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

/* ==========================================================================
   2. CLASES DE UTILIDAD
   ========================================================================== */
.text-center { text-align: center; }
.hidden { display: none !important; }
.relative { position: relative; }
.overflow-hidden { overflow: hidden; }
.z-1 { z-index: 1; }
.z-10 { z-index: 10; }

/* ==========================================================================
   3. COMPONENTES GENERALES
   ========================================================================== */
.section {
    padding: 80px 0;
    position: relative;
    overflow: hidden;
}

.section .container {
    position: relative;
    z-index: 10;
}

.section-title {
    font-family: var(--font-headings);
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 24px;
    text-align: center;
}

.section-subtitle {
    text-align: center;
    color: var(--medium-text);
    font-size: 1.125rem;
    margin-bottom: 64px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.bg-secondary {
    background-color: var(--dark-bg-secondary);
}

.color-blur-effect {
    position: absolute;
    border-radius: 50%;
    z-index: 1;
}

.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 8px;
    font-weight: bold;
    font-size: 1rem;
    text-align: center;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
}
.btn:hover {
    transform: translateY(-2px);
}

.btn-primary {
    background-color: var(--brand-cyan);
    color: var(--dark-bg);
    box-shadow: 0 4px 10px rgba(0, 255, 255, 0.15);
}
.btn-primary:hover {
    background-color: var(--brand-magenta);
    box-shadow: 0 6px 12px rgba(255, 0, 255, 0.2);
}

.btn-secondary {
    border: 2px solid var(--medium-text);
    color: var(--medium-text);
    background-color: transparent;
}
.btn-secondary:hover {
    border-color: var(--brand-cyan);
    color: var(--brand-cyan);
}

/* ==========================================================================
   4. ESTILOS POR SECCIÓN
   ========================================================================== */

/* -------------------- HEADER -------------------- */
.site-header {
    background-color: rgba(var(--dark-bg-rgb), 0.8);
    backdrop-filter: blur(10px);
    padding: 20px 0;
    position: sticky;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1002; /* Header por encima del overlay del menú */
    height: var(--header-height);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-img {
    height: 35px;
    width: auto;
}

.main-nav { display: none; } /* Oculto por defecto, se muestra en desktop via media query */
.nav-list { display: flex; align-items: center; gap: 32px; }
.nav-link { color: var(--light-text); transition: color 0.3s ease; font-weight: 600; }
.nav-link:hover { color: var(--brand-cyan); }
.nav-button {
    background-color: var(--brand-cyan);
    color: var(--dark-bg);
    padding: 10px 24px;
    border-radius: 6px;
    font-weight: bold;
    transition: background-color 0.3s ease;
}
.nav-button:hover { background-color: var(--brand-magenta); }

/* Botón de Hamburguesa/X en el Header */
#mobile-menu-button.mobile-menu-toggle {
    display: block; /* Visible en móvil */
    background: none;
    border: none;
    color: var(--light-text);
    cursor: pointer;
    padding: 8px;
    /* z-index ya está cubierto por .site-header si es necesario, o añadir uno específico si hay problemas */
}
#mobile-menu-button .icon-menu,
#mobile-menu-button .icon-close {
    width: 24px;
    height: 24px;
}
#mobile-menu-button .icon-menu.hidden,
#mobile-menu-button .icon-close.hidden {
    display: none !important;
}

/* -------------------- MENÚ MÓVIL OVERLAY -------------------- */
.mobile-nav-overlay {
    position: fixed;
    top: 0;
    right: 0;
    width: 100%;
    max-width: 320px;
    height: 100vh;
    background-color: rgba(var(--dark-bg-secondary-rgb), 0.85);
    backdrop-filter: blur(10px);
    box-shadow: -5px 0px 25px rgba(0,0,0,0.3);
    z-index: 1001; /* Por debajo del header, pero encima del contenido de la página */
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.4s cubic-bezier(0.25, 0.1, 0.25, 1),
                opacity 0.3s ease-out,
                visibility 0s linear 0.4s;
}
.mobile-nav-overlay.active {
    transform: translateX(0);
    opacity: 1;
    visibility: visible;
    transition-delay: 0s;
}

.mobile-nav-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}
.mobile-nav-logo .logo-img {
    height: 30px;
}

/* Botón de Cierre 'X' dentro del Menú Overlay */
#mobile-menu-close-button.mobile-menu-toggle { /* Usa la clase .mobile-menu-toggle para estilos comunes si quieres */
    display: block; /* Siempre visible cuando el overlay está activo */
    background: none;
    border: none;
    color: var(--light-text);
    cursor: pointer;
    padding: 8px;
}
#mobile-menu-close-button .icon-menu { display: none; } /* Ocultar icono de hamburguesa */
#mobile-menu-close-button .icon-close { display: block; } /* Mostrar icono de X */


.mobile-nav-content { flex-grow: 1; padding: 20px; overflow-y: auto; }
.mobile-nav-list { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.mobile-nav-link { display: block; padding: 12px 15px; color: var(--light-text); width: 100%; text-align: left; border-radius: 6px; font-size: 1.1rem; transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease; }
.mobile-nav-link:hover, .mobile-nav-link:focus { background-color: rgba(var(--brand-cyan-rgb), 0.1); color: var(--brand-cyan); transform: translateX(5px); }
.mobile-nav-button { background-color: var(--brand-cyan); color: var(--dark-bg); padding: 12px 24px; border-radius: 8px; font-weight: bold; margin-top: 20px; text-align: center; width: 100%; }
.mobile-nav-button:hover, .mobile-nav-button:focus { background-color: var(--brand-magenta); color: var(--dark-bg); transform: scale(1.03); }

/* -------------------- HERO SECTION -------------------- */
.hero-section {
    min-height: calc(100vh - var(--header-height));
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}
.hero-title { font-family: var(--font-headings); font-size: 3rem; font-weight: 800; line-height: 1.2; margin-bottom: 24px; }
.text-gradient { background: linear-gradient(90deg, var(--brand-cyan), var(--brand-magenta)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; }
.hero-subtitle { font-size: 1.25rem; color: var(--medium-text); max-width: 700px; margin: 0 auto 40px auto; }
.hero-buttons .btn { margin: 0 10px; padding: 16px 32px; font-size: 1.125rem; }
.blur-hero-1 { width: 50vw; height: 50vw; background: radial-gradient(circle, var(--brand-cyan) 0%, var(--brand-magenta) 70%); top: -20%; right: -20%; opacity: 0.35; filter: blur(130px); }
.blur-hero-2 { width: 45vw; height: 45vw; background: radial-gradient(circle, var(--brand-blue) 0%, var(--brand-magenta) 70%); bottom: -15%; left: -15%; opacity: 0.25; filter: blur(140px); }

/* -------------------- SERVICES SECTION -------------------- */
.services-list { display: flex; flex-direction: column; gap: 80px; }
.service-card { display: flex; flex-direction: column; }
.service-card-visual { flex-shrink: 0; margin-bottom: 24px; perspective: 1000px; }
.service-card-visual img { width: 100%; height: auto; display: block; max-height: 350px; object-fit: cover; border-radius: 10px; box-shadow: 0 5px 15px rgba(0,0,0,0.1); transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1), box-shadow 0.4s cubic-bezier(0.25, 0.8, 0.25, 1); backface-visibility: hidden; transform-style: preserve-3d; }
.service-card-visual img:hover { box-shadow: 0 15px 35px rgba(0,0,0,0.25), 0 8px 15px rgba(0,0,0,0.2); }
.service-card:nth-child(odd) .service-card-visual img:hover { transform: scale(1.05) rotateX(5deg) rotateY(-7deg) translateZ(20px); }
.service-card:nth-child(even) .service-card-visual img:hover { transform: scale(1.06) rotateX(-4deg) rotateY(6deg) translateZ(25px); }
.service-card-content { padding: 0; display: flex; flex-direction: column; justify-content: center; }
.service-card-title { font-family: var(--font-headings); font-size: 2rem; color: var(--light-text); margin-bottom: 16px; }
.service-card-description { color: var(--medium-text); font-size: 1.05rem; line-height: 1.8; margin-bottom: 32px; }
.service-card-button { background-color: transparent; color: var(--brand-cyan); border: 2px solid var(--brand-cyan); padding: 10px 26px; align-self: flex-start; border-radius: 8px; font-weight: bold; font-size: 1rem; text-align: center; transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, transform 0.2s ease; }
.service-card-button:hover { background-color: var(--brand-cyan); color: var(--dark-bg); transform: translateY(-2px); }
.blur-services-1 { width: 60vw; height: 60vw; background: radial-gradient(circle, var(--brand-cyan, #00FFFF) 0%, var(--brand-blue, #007BFF) 70%); top: 5%; left: -25%; opacity: 0.15; filter: blur(130px); }
.blur-services-2 { width: 50vw; height: 50vw; background: radial-gradient(circle, var(--brand-magenta, #FF00FF) 0%, var(--brand-blue, #007BFF) 60%); bottom: 5%; right: -20%; opacity: 0.12; filter: blur(140px); }
.blur-services-3 { width: 70vw; height: 40vh; background: radial-gradient(ellipse at center, var(--brand-blue, #007BFF) 0%, transparent 60%); top: 50%; left: 50%; transform: translate(-50%, -50%); opacity: 0.08; filter: blur(100px); border-radius: 40% 60% 60% 40% / 30% 30% 70% 70%; }

/* -------------------- ABOUT SECTION -------------------- */
.about-content { display: flex; flex-direction: column; gap: 40px; align-items: center; }
.about-text { flex: 1; }
.about-text h3 { font-family: var(--font-headings); font-size: 1.75rem; color: var(--light-text); margin-bottom: 16px; }
.about-text h4 { font-family: var(--font-headings); font-size: 1.3rem; color: var(--brand-cyan); margin-top: 32px; margin-bottom: 16px; }
.about-text p { color: var(--medium-text); margin-bottom: 16px; line-height: 1.8; }
.about-text p strong { color: var(--light-text); font-weight: 600; }
.about-values { list-style: none; padding-left: 0; }
.about-values li { display: flex; align-items: flex-start; color: var(--medium-text); margin-bottom: 12px; font-size: 0.95rem; }
.about-values li svg { width: 20px; height: 20px; fill: var(--brand-cyan); margin-right: 12px; flex-shrink: 0; margin-top: 3px; }
.about-values li span strong { color: var(--light-text); font-weight: 600; }
.about-visual { flex: 1; max-width: 400px; width: 90%; margin-left: auto; margin-right: auto; position: relative; padding-bottom: 40px; }
.levitating-image { width: 100%; height: auto; display: block; border-radius: 20px; object-fit: cover; box-shadow: 0 15px 30px rgba(0,0,0,0.2), 0 10px 10px rgba(0,0,0,0.15); animation: levitate 6s ease-in-out infinite; position: relative; z-index: 5; }
.visual-caption { text-align: center; font-style: italic; color: var(--medium-text); font-size: 0.9rem; margin-top: 20px; }
@keyframes levitate { 0% { transform: translateY(0px); } 50% { transform: translateY(-15px); } 100% { transform: translateY(0px); } }
.blur-about-1 { width: 50vw; height: 70vh; background: radial-gradient(ellipse at top left, var(--brand-cyan) 0%, transparent 60%); top: 0; left: -10%; opacity: 0.1; filter: blur(120px); }
.blur-about-2 { width: 50vw; height: 70vh; background: radial-gradient(ellipse at bottom right, var(--brand-magenta) 0%, transparent 60%); bottom: 0; right: -10%; opacity: 0.1; filter: blur(120px); }

/* -------------------- TESTIMONIALS SECTION -------------------- */
.blur-testimonials-1 { width: 70vw; height: 40vh; background: radial-gradient(ellipse at center, var(--brand-blue) 0%, var(--brand-cyan) 50%, transparent 80%); top: 50%; left: 50%; transform: translate(-50%, -50%); opacity: 0.15; filter: blur(110px); }
.testimonial-carousel-wrapper { width: 100%; overflow: hidden; padding: 20px 0; -webkit-mask-image: linear-gradient(to right, transparent 0%, black 10%, black 90%, transparent 100%); mask-image: linear-gradient(to right, transparent 0%, black 10%, black 90%, transparent 100%); }
.testimonial-carousel { display: flex; width: fit-content; animation: scrollTestimonialsRich 45s linear infinite; }
.testimonial-item-rich { background-color: var(--dark-bg); color: var(--light-text); padding: 20px 30px; margin: 0 12px; border-radius: 12px; min-width: 280px; max-width: 350px; box-shadow: 0 4px 10px rgba(0,0,0,0.2); flex-shrink: 0; display: flex; flex-direction: column; justify-content: space-between; text-align: left; }
.testimonial-item-rich .quote { font-style: italic; color: var(--medium-text); font-size: 0.95rem; line-height: 1.6; margin-bottom: 12px; }
.testimonial-item-rich .author { font-weight: bold; color: var(--brand-cyan); font-size: 0.9rem; margin-top: auto; text-align: right; }
@keyframes scrollTestimonialsRich { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
.testimonial-carousel-wrapper:hover .testimonial-carousel { animation-play-state: paused; }

/* -------------------- CONTACT SECTION -------------------- */
#contact.section.full-viewport-section { /* No necesitas .full-viewport-section aquí si no la defines */ }
#contact .container.contact-container { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; width: 100%; }
.contact-form { width: 100%; max-width: 600px; margin-top: 32px; }
.form-group { margin-bottom: 24px; }
.form-group textarea { width: 100%; padding: 15px 20px; background-color: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 8px; color: var(--light-text); font-family: var(--font-primary); font-size: 1rem; line-height: 1.6; resize: vertical; min-height: 120px; }
.form-group textarea::placeholder { color: var(--medium-text); opacity: 0.7; }
.form-group textarea:focus { outline: none; border-color: var(--brand-cyan); box-shadow: 0 0 0 3px rgba(var(--brand-cyan-rgb), 0.2); }
.contact-submit-button { width: 100%; padding-top: 16px; padding-bottom: 16px; font-size: 1.1rem; display: inline-flex; align-items: center; justify-content: center; }
.contact-note { margin-top: 20px; font-size: 0.85rem; color: var(--medium-text); opacity: 0.8; }
.blur-contact-1 { width: 40vw; height: 80vh; background: linear-gradient(to bottom right, var(--brand-magenta), var(--brand-blue), var(--brand-cyan)); top: 10%; right: -15%; opacity: 0.1; filter: blur(150px); border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%; }
.blur-contact-2 { width: 40vw; height: 80vh; background: linear-gradient(to top left, var(--brand-cyan), var(--brand-blue)); bottom: 10%; left: -15%; opacity: 0.1; filter: blur(150px); border-radius: 30% 70% 40% 60% / 40% 60% 30% 70%; }

/* -------------------- FOOTER -------------------- */
.site-footer { background-color: var(--dark-bg-secondary); padding: 32px 0; text-align: center; border-top: 1px solid #333; position: relative; }
.footer-logo { height: 40px; width: 40px; border-radius: 50%; object-fit: cover; margin: 0 auto 16px auto; border: 1px solid var(--medium-text); }
.footer-content p { color: var(--medium-text); font-size: 0.9rem; }

/* ==========================================================================
   5. MEDIA QUERIES
   ========================================================================== */
@media (min-width: 768px) { /* Tablets y Desktop Pequeño */
    .main-nav { display: block; }
    /* CORRECCIÓN AQUÍ: Ocultar específicamente el botón del header */
    #mobile-menu-button.mobile-menu-toggle { 
        display: none; 
    }

    .section-title { font-size: 3rem; }
    .hero-title { font-size: 4.5rem; }
    .hero-subtitle { font-size: 1.5rem; }
    .blur-hero-1 { width: 400px; height: 400px; top:-10%; right: -10%;}
    .blur-hero-2 { width: 350px; height: 350px; bottom:-10%; left: -10%;}
}

@media (min-width: 992px) { /* Desktop Mediano */
    .service-card { flex-direction: row; align-items: center; gap: 64px; min-height: 400px; }
    .service-card-visual { flex-basis: 50%; margin-bottom: 0; }
    .service-card-visual img { max-height: 100%; }
    .service-card-content { flex-basis: 50%; }
    .service-card:nth-child(even) .service-card-content { order: 1; }
    .service-card:nth-child(even) .service-card-visual { order: 2; }

    .about-content { flex-direction: row; align-items: center; /* O flex-start si prefieres */ gap: 64px; }
    .about-text { flex-basis: 55%; }
    .about-visual { flex-basis: 45%; max-width: 400px; /* O quitar max-width si quieres que ocupe el 45% */ }


    .blur-services-1 { width: 500px; height: 500px; opacity: 0.12; }
    .blur-services-2 { width: 450px; height: 450px; opacity: 0.1; }
    .blur-services-3 { width: 60vw; height: 35vh; opacity: 0.07;}
}

@media (max-width: 767px) { /* Móviles */
    .hero-buttons { display: flex; flex-direction: column; gap: 16px; align-items: center; }
    .hero-buttons .btn { width: 80%; margin: 0; }
    .hero-title br { display: none; }
    .section-title { font-size: 2.25rem; }
}

/* Fallback para prefers-reduced-motion en testimonios */
@media (prefers-reduced-motion: reduce) {
  .testimonial-carousel { animation: none; }
  .testimonial-carousel-wrapper { -webkit-mask-image: none; mask-image: none; /* overflow-x: auto; */ }
}

/* Si definiste .full-viewport-section para la sección de contacto */
.full-viewport-section {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding-top: var(--header-height); /* Considerar si es la primera sección visible */
    padding-bottom: 40px;
}