/* --- Base Layout --- */
body {
    background-color: var(--bg-deep);
    color: var(--text-pure);
    font-family: var(--font-main);
    line-height: 1.6;
    margin: 0;
    overflow-x: hidden;
    animation: bodyFadeIn var(--dur-slow) var(--ease-out-expo);
}

@keyframes bodyFadeIn {
    from { opacity: 0; filter: blur(10px); }
    to { opacity: 1; filter: blur(0); }
}

.container {
    width: min(1440px, 94vw); /* Aumento del ancho útil según solicitud */
    margin-inline: auto;
}

/* --- Responsive Layout Utilities --- */
.bento-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: var(--sp-lg);
}

.bento-col-3 { grid-column: span 3; }
.bento-col-4 { grid-column: span 4; }
.bento-col-6 { grid-column: span 6; }
.bento-col-8 { grid-column: span 8; }
.bento-col-12 { grid-column: span 12; }

@media (max-width: 1200px) {
    .bento-col-3 { grid-column: span 4; }
}

@media (max-width: 1024px) {
    .bento-col-3, .bento-col-4, .bento-col-6 { grid-column: span 6; }
}

@media (max-width: 768px) {
    .bento-col-3, .bento-col-4, .bento-col-6, .bento-col-8 { grid-column: span 12; }
}

/* --- Hero Foundation --- */
.hero-premium {
    min-height: 85vh; /* Ajustado para visibilidad above-the-fold */
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    padding: var(--sp-section) 0;
    overflow: hidden;
    background: radial-gradient(circle at 50% 50%, rgba(0, 210, 255, 0.03) 0%, transparent 70%);
}

.hero-premium::before {
    content: '';
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: 80%; height: 80%;
    background: radial-gradient(circle, var(--brand-glow-subtle) 0%, transparent 70%);
    z-index: 0;
    filter: blur(100px);
    animation: ambientGlow var(--dur-ambient) var(--ease-in-out-soft) infinite alternate;
}

@keyframes ambientGlow {
    from { opacity: 0.1; transform: translate(-50%, -50%) scale(0.9); }
    to { opacity: 0.25; transform: translate(-50%, -50%) scale(1.1); }
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--sp-3xl);
    align-items: center;
    position: relative;
    z-index: 2;
}

@media (max-width: 968px) {
    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

/* --- Advanced Background Layers --- */
.bg-scanlines {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.05) 50%); /* Más sutil */
    background-size: 100% 4px;
    pointer-events: none;
    z-index: 9999;
    opacity: 0.02; /* Reducido de 0.05 */
}

.bg-noise {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.02;
    pointer-events: none;
    z-index: 9998;
}

/* --- Reveal Engine: Progressive Enhancement --- */
.js-enabled [data-reveal] {
    opacity: 0;
    transform: translateY(20px) scale(0.98); /* Less aggressive defaults */
    filter: blur(8px);
    transition: opacity var(--dur-slow) var(--ease-out-expo), 
                transform var(--dur-slow) var(--ease-out-expo),
                filter var(--dur-slow) var(--ease-out-expo);
    will-change: transform, opacity, filter;
}

.js-enabled [data-reveal].revealed {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
}

/* --- Utilities --- */
.text-mono { font-family: var(--font-mono); }
.section-cv { content-visibility: auto; contain-intrinsic-size: 1px 1000px; }

/* --- Legal --- */
.legal-body { color: var(--text-muted); line-height: 1.8; }
.legal-body h3 { color: var(--text-pure); margin: 3rem 0 1rem; font-size: 1.25rem; }
.legal-body p { margin-bottom: 1.5rem; }
