/* ============================================================
   mores.dev — Anti-Design Stylesheet
   Palette: #0d0d0d, #1a1a1a, #FF2D6B, #3D5AFE, #FFD600, #FAFAFA, #B0B0B0, #FFFFFF
   Fonts: Bebas Neue, Space Grotesk" (Google Fonts), IBM Plex Mono" (Google Fonts)
   Scroll: IntersectionObserver or requestAnimationFrame-throttled scroll
   ============================================================ */

/* --- RESET & BASE --- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    overflow-x: hidden;
    scroll-behavior: auto;
    background: #0d0d0d;
}

body {
    margin: 0;
    padding: 0;
    background: #0d0d0d;
    color: #FAFAFA;
    font-family: 'Space Grotesk', sans-serif;
    overflow-x: hidden;
    cursor: none;
}

/* --- CUSTOM CURSOR --- */
.wave-cursor {
    position: fixed;
    pointer-events: none;
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.15s;
}

body:hover .wave-cursor {
    opacity: 1;
}

.cursor-wave-path {
    animation: cursorOscillate 0.6s ease-in-out infinite alternate;
}

@keyframes cursorOscillate {
    0% {
        d: path("M0,5 C5,2 10,8 15,5 C20,2 25,8 30,5");
    }
    100% {
        d: path("M0,5 C5,8 10,2 15,5 C20,8 25,2 30,5");
    }
}

/* --- MICRO-WAVE TEXTURE OVERLAY --- */
.micro-wave-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
    opacity: 0.03;
    background-image: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 8px,
        rgba(250, 250, 250, 0.15) 8px,
        rgba(250, 250, 250, 0.15) 10px
    ),
    repeating-linear-gradient(
        90deg,
        transparent,
        transparent 8px,
        rgba(250, 250, 250, 0.1) 8px,
        rgba(250, 250, 250, 0.1) 10px
    );
    background-size: 10px 10px;
}

/* --- ZONE BASE --- */
.zone {
    position: relative;
    width: 100%;
    overflow: hidden;
}

/* ============================================================
   ZONE 1: THE BREACH (Hero Zone)
   ============================================================ */
.zone-breach {
    height: 200vh;
    background: #0d0d0d;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 2;
}

.breach-bg-texture {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.03;
    background-image:
        repeating-linear-gradient(
            45deg,
            transparent,
            transparent 4px,
            rgba(255, 45, 107, 0.1) 4px,
            rgba(255, 45, 107, 0.1) 5px
        );
    background-size: 7px 7px;
    pointer-events: none;
}

.breach-flash {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #FFFFFF;
    opacity: 0;
    pointer-events: none;
    z-index: 100;
    transition: opacity 0.05s ease-out;
}

.breach-flash.active {
    opacity: 0.3;
}

.hero-word-container {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(8);
    transform-origin: center center;
    width: 80vw;
    max-width: 1200px;
    z-index: 3;
    will-change: transform;
}

.hero-svg {
    width: 100%;
    height: auto;
    display: block;
}

.hero-norm-wave {
    animation: heroWaveSlide 30s linear infinite;
}

@keyframes heroWaveSlide {
    0% { transform: translateX(0); }
    100% { transform: translateX(-200px); }
}

/* ============================================================
   ZONE 2: THE FAULT LINE (Tension Zone)
   ============================================================ */
.zone-fault-line {
    height: 20vh;
    background: #3D5AFE;
    position: relative;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
}

.fault-line-wave {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* ============================================================
   ZONE 3: THE GRID COLLAPSE (Content Zone)
   ============================================================ */
.zone-grid-collapse {
    min-height: 200vh;
    position: relative;
    z-index: 5;
}

.decay-wave-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.decay-wave-path {
    animation: decayDash 15s linear infinite;
}

@keyframes decayDash {
    0% { stroke-dashoffset: 0; }
    100% { stroke-dashoffset: 200; }
}

/* Content Bands */
.content-band {
    position: relative;
    z-index: 1;
    padding: 8vh 5vw;
    width: 100%;
}

.band-dark {
    background: #0d0d0d;
}

.band-charcoal {
    background: #1a1a1a;
}

/* Mono Labels */
.mono-label {
    display: block;
    font-family: 'IBM Plex Mono', monospace;
    font-weight: 400;
    font-size: clamp(0.7rem, 1vw, 0.9rem);
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #FFD600;
    margin-bottom: 3vh;
}

/* Section Headings */
.section-heading {
    font-family: 'Bebas Neue', sans-serif;
    font-weight: 400;
    font-size: clamp(8vw, 12vw, 16vw);
    letter-spacing: -0.03em;
    line-height: 0.85;
    color: #FAFAFA;
    margin-bottom: 4vh;
    text-transform: uppercase;
}

/* Body Text */
.body-text {
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 300;
    font-size: clamp(1rem, 1.8vw, 1.4rem);
    line-height: 1.6;
    letter-spacing: 0.01em;
    color: #B0B0B0;
    width: 100%;
    margin: 0;
    padding: 0;
}

.body-text.rotated {
    transform: rotate(calc(-1deg + var(--rotation-offset, 0deg)));
    transform-origin: left center;
}

/* Wave Dividers */
.wave-divider {
    display: block;
    width: 100%;
    height: 20px;
    margin: 3vh 0;
}

/* ============================================================
   ZONE 4: THE WAVE WALL (Motif Zone)
   ============================================================ */
.zone-wave-wall {
    height: 100vh;
    background: #0d0d0d;
    position: relative;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.wave-wall-svg {
    position: absolute;
    top: 0;
    left: -50%;
    width: 200%;
    height: 100%;
}

/* Norm Wave Animation - slow, steady, 60s */
.wave-norm-group {
    animation: waveNormSlide 60s linear infinite;
}

@keyframes waveNormSlide {
    0% { transform: translateX(0); }
    100% { transform: translateX(-1200px); }
}

/* Disruption Wave Animation - faster, opposite direction, 23s */
.wave-disruption-group {
    animation: waveDisruptionSlide 23s linear infinite;
}

@keyframes waveDisruptionSlide {
    0% { transform: translateX(0); }
    100% { transform: translateX(1200px); }
}

/* Decay Wave Animation - blink segments, 15s */
.wave-decay-group {
    animation: waveDecayBlink 15s linear infinite;
}

@keyframes waveDecayBlink {
    0% { stroke-dashoffset: 0; }
    100% { stroke-dashoffset: 300; }
}

.wave-norm {
    stroke: #FF2D6B;
    stroke-width: 3;
    fill: none;
}

.wave-disruption {
    stroke: #3D5AFE;
    stroke-width: 2;
    fill: none;
}

.wave-decay {
    stroke: #FFD600;
    stroke-width: 1.5;
    fill: none;
    stroke-dasharray: 20 40 10 30;
}

/* ============================================================
   ZONE 5: THE EXIT WOUND (Footer Zone)
   ============================================================ */
.zone-exit-wound {
    height: 60vh;
    background: #0d0d0d;
    position: relative;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.exit-wound-text {
    font-family: 'Bebas Neue', sans-serif;
    font-weight: 400;
    font-size: 14vw;
    letter-spacing: -0.03em;
    line-height: 0.85;
    color: #FAFAFA;
    text-transform: uppercase;
    white-space: nowrap;
    transform: rotate(-2deg);
    transform-origin: center center;
    will-change: transform;
    width: 100%;
    text-align: center;
    padding: 0 5vw;
}

/* ============================================================
   RESPONSIVE ADJUSTMENTS
   ============================================================ */

/* On touch devices, restore default cursor */
@media (hover: none) and (pointer: coarse) {
    body {
        cursor: auto;
    }
    .wave-cursor {
        display: none;
    }
}

/* Small screens: keep the anti-design intentional overflow */
@media screen and (max-width: 768px) {
    .section-heading {
        font-size: clamp(10vw, 14vw, 18vw);
    }

    .exit-wound-text {
        font-size: 16vw;
    }

    .content-band {
        padding: 6vh 4vw;
    }
}
