/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    min-height: 100vh;
    overflow: hidden;
    background: #000; /* Fallback */
}

/* Stacked Background Effect */
.background {
    position: fixed;
    inset: 0;
    z-index: -1;
}

/* First Layer (Base) */
.background::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url('images/Arvee-Wallpaper-Long-Blue.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    filter: brightness(0.9) saturate(0.9); /* Slightly dimmer base */
}

/* Second Layer (Offset Echo) */
.background::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url('images/Arvee-Wallpaper-Long-Blue.jpg');
    background-size: cover;
    background-position: 5% 5%; /* Slight offset */
    background-repeat: no-repeat;
    mix-blend-mode: multiply; /* Creates depth by blending */
    opacity: 0.35; /* Subtle visibility */
    filter: brightness(1.1) saturate(1.1); /* Slightly brighter */
    animation: drift 20s ease-in-out infinite alternate;
}

/* Drift Animation for subtle movement */
@keyframes drift {
    0% {
        background-position: 5% 5%;
        transform: scale(1);
    }
    100% {
        background-position: 10% 10%;
        transform: scale(1.02);
    }
}

/* Dark Overlay for contrast */
.background::after {
    /* Reuse ::after for overlay? No, we need a separate layer for overlay */
    /* Let's add a third pseudo-element or use a wrapper. Simpler: use a separate div */
}

/* Better approach: Use a separate overlay div */
.background-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(1px);
    z-index: -1;
}

/* Centered Content */
.content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    z-index: 1;
    padding: 2rem;
    width: 100%;
    max-width: 90vw;
}

/* Beveled Text Effect */
.beveled-text {
    font-size: clamp(2rem, 10vw, 6rem);
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    
    white-space: normal;
    word-break: keep-all;
    overflow-wrap: break-word;
    
    color: #ffffff;
    text-shadow:
        1px 1px 0 #000000,
        2px 2px 0 #000000,
        3px 3px 0 #000000,
        4px 4px 0 #000000,
        5px 5px 0 #000000,
        0 0 25px rgba(255, 255, 255, 0.4),
        0 0 50px rgba(255, 255, 255, 0.2);
    
    animation: fadeInBevel 1.5s ease-out forwards, pulseGlow 5s ease-in-out infinite;
    opacity: 0;
}

.subtitle {
    font-size: clamp(0.8rem, 2.5vw, 1.3rem);
    font-weight: 300;
    letter-spacing: 0.4em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.8);
    text-shadow:
        1px 1px 0 #000000,
        2px 2px 0 #000000,
        0 0 15px rgba(255, 255, 255, 0.25);
    animation: fadeIn 1.5s ease-out 0.5s forwards;
    opacity: 0;
}

/* Animations */
@keyframes fadeInBevel {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes pulseGlow {
    0%, 100% {
        text-shadow:
            1px 1px 0 #000, 2px 2px 0 #000, 3px 3px 0 #000, 4px 4px 0 #000, 5px 5px 0 #000,
            0 0 25px rgba(255,255,255,0.4), 0 0 50px rgba(255,255,255,0.2);
    }
    50% {
        text-shadow:
            1px 1px 0 #000, 2px 2px 0 #000, 3px 3px 0 #000, 4px 4px 0 #000, 5px 5px 0 #000,
            0 0 35px rgba(255,255,255,0.6), 0 0 70px rgba(255,255,255,0.3);
    }
}

/* Mobile Adjustments */
@media (max-width: 768px) {
    .content {
        padding: 1rem;
        max-width: 95vw;
    }
    .beveled-text {
        white-space: nowrap;
        font-size: clamp(1.8rem, 8vw, 3.5rem);
    }
    @media (max-width: 480px) {
        .beveled-text {
            white-space: normal;
            font-size: clamp(1.5rem, 7vw, 2.5rem);
            line-height: 1.4;
        }
        .subtitle {
            letter-spacing: 0.15em;
            font-size: clamp(0.7rem, 2vw, 1rem);
        }
    }
}
