:root {
    /* Colors */
    --bg: #050505;
    --surface: #0a0a0a;
    --text: #f0f0f0;
    --text-muted: #888888;
    --accent: #d4d4d4;
    --line: rgba(255, 255, 255, 0.08);
    --error: #ff3300;

    /* Typography */
    --font-head: "Italiana", "Songti SC", "Noto Serif SC", "SimSun", serif;
    --font-body: "Manrope", "PingFang SC", "Microsoft YaHei", "Noto Sans SC", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-mono: "Space Mono", "PingFang SC", "Microsoft YaHei", monospace;

    /* Spacing & Sizing */
    --gap-base: 24px;
    --container-max: 1400px;
    
    /* Animation */
    --ease-cinematic: cubic-bezier(0.23, 1, 0.32, 1);
    --transition-slow: 0.8s var(--ease-cinematic);
    --transition-base: 0.4s var(--ease-cinematic);
}

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

html {
    scroll-behavior: smooth;
    background-color: var(--bg);
    overflow-x: hidden; /* Force hide horizontal scrollbar */
    width: 100%;
}

body {
    background-color: var(--bg);
    color: var(--text);
    font-family: var(--font-body);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden; /* Double assurance */
    width: 100%;
    position: relative; /* Establish positioning context */
}

/* Typography Helpers */
h1, h2, h3 {
    font-family: var(--font-head);
    font-weight: 400;
    line-height: 1.1;
}

.text-mono {
    font-family: var(--font-mono);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 0.8rem;
}

/* Layout Containers */
.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 60px;
}

section, #mission, #dream, #magic {
    position: relative;
    padding: 100px 0; /* Reduced from 120px for better flow */
    border-top: none !important; /* Force remove separator line globally */
}

@media (max-width: 768px) {
    .container {
        padding: 0 20px; /* Tighter padding for mobile */
    }
    
    section {
        padding: 30px 0; /* Further reduced vertical spacing */
    }
}

/* Utility */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s var(--ease-cinematic), transform 0.8s var(--ease-cinematic);
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered Entrance Animations */
.animate-focus {
    opacity: 0;
    transform: scale(1.1);
    filter: blur(10px);
    animation: scaleDownFocus 1.5s var(--ease-cinematic) forwards;
}

.delay-text { animation-delay: 0.2s; }
.delay-btn { opacity: 0; animation: fadeInSimple 1s ease forwards; animation-delay: 2.2s; }

@keyframes scaleDownFocus {
    to {
        opacity: 1;
        transform: scale(1);
        filter: blur(0);
    }
}

@keyframes fadeInSimple {
    to { opacity: 1; }
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
