:root {
    --primary: #006994;
    --secondary: #00A5CF;
    --accent: #00C9B1;
    --dark: #0A2342;
    --light: #F7F9FC;
    --text: #333333;
    --gold: #FFD700;
    --deep-blue: #002366;
    --glow: 0 0 30px rgba(0, 201, 177, 0.7);
    --text-glow: 0 0 10px rgba(255, 255, 255, 0.8);
}

/* Reset Nuclear */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: 'Playfair Display', serif;
    color: var(--text);
    overflow-x: hidden;
    min-height: 100vh;
    background: var(--dark);
    touch-action: manipulation;
}

/* Animaciones Épicas */
@keyframes float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    25% { transform: translateY(-10px) rotate(1deg); }
    75% { transform: translateY(5px) rotate(-1deg); }
}

@keyframes pulse {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.03); opacity: 0.9; }
    100% { transform: scale(1); opacity: 1; }
}

@keyframes ripple {
    0% { transform: scale(0); opacity: 0.5; }
    100% { transform: scale(2); opacity: 0; }
}

@keyframes particle-float {
    0% { transform: translateY(0) rotate(0deg); opacity: 0.6; }
    100% { transform: translateY(-100vh) rotate(360deg); opacity: 0; }
}

@keyframes bubble-float {
    0% { transform: translateY(0); opacity: 0.8; }
    100% { transform: translateY(-100vh); opacity: 0; }
}

@keyframes wave {
    0% { transform: scaleX(0); opacity: 1; }
    100% { transform: scaleX(1); opacity: 0; }
}

/* Layout Overlord */
.main-container {
    min-height: 100vh;
    position: relative;
    overflow: hidden;
}

/* Header */
.lab-header {
    text-align: center;
    padding: 4rem 2rem 3rem;
    position: relative;
    overflow: hidden;
}

.lab-header h1 {
    font-family: 'Playfair Display', serif;
    font-size: 3.5rem;
    margin-bottom: 1rem;
    color: var(--light);
    text-shadow: var(--text-glow);
    position: relative;
    z-index: 2;
}

.lab-header h1 span {
    color: var(--accent);
}

.lab-header p {
    font-size: 1.2rem;
    color: var(--light);
    opacity: 0.8;
    position: relative;
    z-index: 2;
}

.water-effect-top {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, transparent 0%, transparent 100%);
    z-index: 1;
}

.home-btn {
    position: absolute;
    top: 1rem;
    right: 1rem;
    z-index: 10;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    background: transparent;
    color: var(--light);
    border: 2px solid var(--accent);
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    overflow: hidden;
    transition: all 0.3s ease;
}

.home-btn:hover {
    background: var(--accent);
    color: var(--dark);
    box-shadow: var(--glow);
}

.home-btn i {
    font-size: 1.2rem;
}

.home-btn .liquid-effect {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--accent);
    z-index: -1;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.home-btn:hover .liquid-effect {
    transform: translateY(0);
}

.home-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 10px;
    background: var(--accent);
    animation: wave 3s linear infinite;
    z-index: -1;
}

/* Lab Section */
.lab-section {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: linear-gradient(135deg, var(--dark) 0%, var(--primary) 80%);
    min-height: 100vh;
    padding: 3rem 1rem;
    z-index: 1;
}

.lab-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, 
        rgba(0, 201, 177, 0.2) 0%, 
        transparent 70%);
    z-index: -1;
}

/* Partículas Cuánticas */
.particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

.particle {
    position: absolute;
    background: rgba(0, 201, 177, 0.5);
    border-radius: 50%;
    pointer-events: none;
    filter: blur(1.5px);
    will-change: transform, opacity;
}

/* Burbujas de Energía */
.bubbles {
    position: absolute;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.bubble {
    position: absolute;
    bottom: -100px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 50%;
    pointer-events: none;
    filter: blur(2px);
    will-change: transform, opacity;
}

/* Lab Intro */
.lab-intro {
    text-align: center;
    max-width: 800px;
    margin-bottom: 3rem;
    z-index: 10;
}

.lab-intro p {
    color: var(--light);
    font-size: 1.1rem;
    line-height: 1.6;
    font-weight: 300;
}

.lab-intro strong {
    color: var(--accent);
}

/* Analysis Container */
.analysis-container {
    max-width: 1000px;
    margin-bottom: 4rem;
    text-align: center;
}

.analysis-container h2 {
    font-family: 'Playfair Display', serif;
    color: var(--light);
    font-size: 2.2rem;
    text-shadow: var(--text-glow);
    margin-bottom: 2rem;
}

.analysis-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.analysis-card {
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(12px);
    border-radius: 15px;
    border: 1px solid rgba(0, 201, 177, 0.25);
    padding: 1.5rem;
    box-shadow: var(--glow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
}

.analysis-card:hover {
    transform: scale(1.05);
    box-shadow: 0 0 50px rgba(0, 201, 177, 0.9);
}

.analysis-card::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(0, 201, 177, 0.3), transparent);
    transform: translate(-50%, -50%) scale(0);
    transition: transform 0.5s ease;
    z-index: -1;
}

.analysis-card:hover::before {
    transform: translate(-50%, -50%) scale(1);
}

.analysis-card h3 {
    font-family: 'Playfair Display', serif;
    color: var(--light);
    font-size: 1.6rem;
    margin-bottom: 0.5rem;
}

.analysis-card p {
    color: var(--light);
    font-size: 1rem;
    font-weight: 300;
    line-height: 1.6;
}

/* Carousel Section */
.carousel-section {
    max-width: 1000px;
    text-align: center;
    margin: 3rem auto;
}

.carousel-section h2 {
    font-family: 'Playfair Display', serif;
    color: var(--light);
    font-size: 2.2rem;
    text-shadow: var(--text-glow);
    margin-bottom: 2rem;
}

.carousel-container {
    position: relative;
    width: 100%;
    max-width: 800px;
    height: 450px;
    overflow: hidden;
    margin: 0 auto;
    z-index: 10;
}

.carousel {
    display: flex;
    width: 100%;
    height: 100%;
    transition: transform 0.6s cubic-bezier(0.19, 1, 0.22, 1);
}

.carousel-image {
    flex: 0 0 100%;
    width: 100%;
    height: 100%;
    position: relative;
    overflow: hidden;
    border-radius: 15px;
    box-shadow: var(--glow);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.carousel-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.9);
    transition: transform 0.3s ease;
}

.carousel-image:hover img {
    transform: scale(1.05);
}

.image-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: rgba(0, 35, 66, 0.7);
    backdrop-filter: blur(5px);
    padding: 1rem;
    color: var(--light);
    font-size: 1rem;
    font-weight: 300;
    text-align: center;
    transition: opacity 0.3s ease;
}

.carousel-image:hover .image-overlay {
    opacity: 0.9;
}

/* Carousel Buttons */
.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(8px);
    border-radius: 50%;
    border: 1px solid rgba(0, 201, 177, 0.4);
    color: var(--light);
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 15;
    display: flex;
    align-items: center;
    justify-content: center;
}

.carousel-btn.prev {
    left: 20px;
}

.carousel-btn.next {
    right: 20px;
}

.carousel-btn:hover {
    background: var(--accent);
    color: var(--dark);
    transform: translateY(-50%) scale(1.15);
}

/* Carousel Dots */
.carousel-dots {
    display: flex;
    justify-content: center;
    margin-top: 1.5rem;
    z-index: 10;
}

.dot {
    width: 12px;
    height: 12px;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    margin: 0 8px;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.3s ease;
}

.dot.active {
    background: var(--accent);
    transform: scale(1.3);
}

/* Loader */
.loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--dark);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    transition: opacity 1s ease;
}

.loader-logo {
    width: 160px;
    height: auto;
    margin-bottom: 30px;
    animation: float 3s ease-in-out infinite;
    filter: drop-shadow(0 0 20px rgba(0, 201, 177, 0.6));
}

.loader-bar {
    width: 320px;
    height: 5px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 2px;
    overflow: hidden;
}

.loader-progress {
    height: 100%;
    width: 0;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    transition: width 0.3s ease;
}

/* Cursor */
.cursor {
    position: fixed;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgba(0, 201, 177, 0.7);
    pointer-events: none;
    transform: translate(-50%, -50%);
    mix-blend-mode: screen;
    z-index: 9999;
    transition: transform 0.1s ease, width 0.3s ease, height 0.3s ease;
}

.cursor-follower {
    position: fixed;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid rgba(0, 201, 177, 0.5);
    pointer-events: none;
    transform: translate(-50%, -50%);
    z-index: 9998;
    transition: transform 0.3s ease, width 0.3s ease, height 0.3s ease;
}

/* Notification */
.notification {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.9);
    color: var(--light);
    padding: 15px 25px;
    border-radius: 8px;
    transform: translateX(150%);
    transition: transform 0.5s cubic-bezier(0.68, -0.55, 0.27, 1.55);
    z-index: 1000;
    backdrop-filter: blur(12px);
    border-left: 4px solid var(--accent);
    font-size: 0.95rem;
}

.notification.show {
    transform: translateX(0);
}

/* Footer idéntico a noticias.html */
.news-footer {
    background: var(--dark);
    color: white;
    padding: 2rem 0 1rem 0;
    position: relative;
    min-height: 120px;
    width: 100vw;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
}
.wave-divider {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 120px;
    overflow: hidden;
    line-height: 0;
    z-index: 2;
}
.footer-content {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
    position: relative;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.2rem;
    padding: 0 1rem;
}
.social-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    margin-bottom: 0.5rem;
    flex-wrap: wrap;
}
.social-icon {
    color: white !important;
    font-size: 2rem !important;
    background: rgba(0,201,177,0.13) !important;
    border-radius: 50%;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}
.social-icon:hover {
    color: var(--accent) !important;
    background: rgba(0,201,177,0.22) !important;
    transform: translateY(-3px) scale(1.15);
}
.footer-content p {
    margin: 0;
    font-size: 1rem;
    opacity: 0.85;
    width: 100%;
    text-align: center;
}
@media (max-width: 600px) {
    .news-footer {
        padding: 1.2rem 0 0.5rem 0;
    }
    .footer-content {
        font-size: 0.95rem;
        gap: 0.7rem;
        padding: 0 0.5rem;
    }
    .social-links {
        gap: 1rem;
    }
    .social-icon {
        font-size: 1.3rem !important;
        padding: 0.35rem;
    }
}

/* Responsive Design */
@media (max-width: 1024px) {
    .carousel-container {
        max-width: 700px;
        height: 400px;
    }

    .carousel-btn.prev {
        left: 15px;
    }

    .carousel-btn.next {
        right: 15px;
    }
}

@media (max-width: 768px) {
    .lab-section {
        padding: 2rem 0.5rem;
    }

    .carousel-container {
        max-width: 500px;
        height: 350px;
    }

    .analysis-card {
        padding: 1.2rem;
    }

    .analysis-card h3 {
        font-size: 1.4rem;
    }

    .analysis-card p {
        font-size: 0.95rem;
    }

    .lab-header h1 {
        font-size: 2.8rem;
    }

    .carousel-btn {
        width: 50px;
        height: 50px;
        font-size: 1.3rem;
    }

    .carousel-btn.prev {
        left: 10px;
    }

    .carousel-btn.next {
        right: 10px;
    }
}

@media (max-width: 480px) {
    .carousel-container {
        max-width: 340px;
        height: 300px;
    }

    .analysis-card h3 {
        font-size: 1.2rem;
    }

    .analysis-card p {
        font-size: 0.9rem;
    }

    .lab-header h1 {
        font-size: 2.2rem;
    }

    .lab-header p {
        font-size: 1.1rem;
    }

    .analysis-container h2 {
        font-size: 1.8rem;
    }

    .carousel-btn {
        width: 40px;
        height: 40px;
        font-size: 1.1rem;
    }

    .dot {
        width: 10px;
        height: 10px;
        margin: 0 6px;
    }

    .home-btn {
        padding: 0.8rem 1.5rem;
        font-size: 0.9rem;
    }
}

@media (pointer: coarse) {
    .cursor, .cursor-follower {
        display: none;
    }
}

@media (prefers-reduced-motion) {
    .carousel {
        transition: none !important;
    }

    .analysis-card, .carousel-image, .carousel-btn, .dot, .home-btn {
        transition: none !important;
    }
}

.header-top {
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 100;
}

.news-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid var(--accent);
    border-radius: 30px;
    color: var(--light);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
}

.news-btn i {
    font-size: 1.2em;
}

.news-btn:hover {
    background: var(--accent);
    color: var(--dark);
    transform: translateY(-2px);
    box-shadow: var(--glow);
}

.news-btn:active {
    transform: translateY(0);
}

@media (max-width: 768px) {
    .header-top {
        top: 15px;
        left: 15px;
    }

    .news-btn {
        padding: 8px 15px;
        font-size: 0.9em;
    }

    .news-btn span {
        display: none;
    }

    .news-btn i {
        font-size: 1.4em;
    }
}
/* ========================================= */
/* === BLOQUE MAESTRO 2.0 (FLUIDO & RESPONSIVE) === */
/* ========================================= */

/* 1. Configuración de Texto (Se adapta automáticamente) */
body, p, span, a, li, input, textarea, label {
    font-family: 'Roboto', sans-serif; 
    font-weight: 400;
    line-height: 1.6;
    color: var(--light);
}

/* 2. Títulos Inteligentes (Usa clamp para escalar suavemente) */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
    /* Evita que palabras largas rompan el celular */
    word-wrap: break-word; 
    hyphens: auto;
}

/* TAMAÑOS: (Mínimo móvil, Ideal variable, Máximo escritorio) */
h1 { 
    font-size: clamp(2.2rem, 5vw + 1rem, 3.5rem) !important; 
}

h2 { 
    font-size: clamp(1.8rem, 4vw + 1rem, 2.5rem) !important; 
    color: var(--light);
}

h3 { 
    font-size: clamp(1.3rem, 3vw + 1rem, 1.8rem) !important; 
}

/* 3. SALVAVIDAS MÓVIL (Evita el desastre lateral) */
html, body {
    max-width: 100vw;
    overflow-x: hidden; /* Bloquea el scroll horizontal indeseado */
}

img, video, iframe, .map-container {
    max-width: 100% !important; /* Nada puede ser más ancho que la pantalla */
    height: auto !important;
}

/* 4. Ajustes Específicos para Celulares ( < 768px ) */
@media (max-width: 768px) {
    /* Reduce el relleno lateral excesivo */
    .contact-header, .about-header, .exp-header, .news-header, .lab-header {
        padding: 3rem 1rem !important; 
    }
    
    /* Asegura que los contenedores no se peguen a los bordes */
    .main-container, .contact-container, .about-container, .section {
        padding-left: 15px !important;
        padding-right: 15px !important;
        width: 100% !important;
    }

    /* Fuerza que las cajas se apilen verticalmente */
    .contact-container, .about-card, .news-container {
        flex-direction: column !important;
        display: flex !important;
    }
}

/* ========================================= */
/* === FIN DEL BLOQUE MAESTRO 2.0 === */
/* ========================================= */