:root {
    /* OKLCH Color Palette */
    --c-dark-bg: oklch(0.16 0.02 260);
    --c-off-white: oklch(0.96 0.01 250);
    --c-ink: oklch(0.20 0.01 260);
    --c-gold: oklch(0.75 0.08 85);

    /* Typography */
    --font-display: 'Instrument Serif', serif;
    --font-mono: 'JetBrains Mono', monospace;
    
    /* Spacing */
    --space-sm: 1rem;
    --space-md: 2rem;
    --space-lg: 4rem;
    --space-xl: 8rem;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--c-dark-bg); /* Fallback */
    color: var(--c-off-white);
    font-family: var(--font-display);
    font-size: 1.5rem;
    line-height: 1.4;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Canvas Background */
#webgl-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 0;
    pointer-events: none; /* Let clicks pass through to HTML */
}

/* Make smooth-wrapper transparent so we see WebGL */
#smooth-wrapper {
    position: relative;
    z-index: 10;
    width: 100%;
}

#smooth-content {
    position: relative;
    width: 100%;
}

/* Typography utilities */
.mono {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.display-title {
    font-size: clamp(3rem, 8vw, 6rem);
    line-height: 1.1;
    font-weight: 400;
    margin-bottom: var(--space-md);
    text-shadow: 0 4px 16px rgba(0, 0, 0, 0.9), 0 0 40px rgba(0, 0, 0, 0.7);
}

.subtitle {
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    line-height: 1.3;
    max-width: 800px;
    margin-bottom: var(--space-lg);
    opacity: 0.95; /* Increased opacity slightly for better reading */
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.9), 0 0 30px rgba(0, 0, 0, 0.7);
}

.body-text {
    font-size: clamp(1.5rem, 3vw, 2.5rem);
    max-width: 800px;
    line-height: 1.4;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.9), 0 0 30px rgba(0, 0, 0, 0.7);
}

/* Layout */
.container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 var(--space-md);
}

.scene {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    /* Dark gradient overlay for text legibility */
    background: linear-gradient(to right, rgba(10, 8, 18, 0.8) 0%, rgba(10, 8, 18, 0.4) 50%, rgba(10, 8, 18, 0.8) 100%);
}

/* Preloader */
.preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--c-dark-bg);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Scene 1: Hero */
.scene-hero {
    align-items: center;
    text-align: center;
}

.scroll-indicator {
    position: absolute;
    bottom: var(--space-lg);
    left: 50%;
    transform: translateX(-50%);
    opacity: 0.5;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { opacity: 0.3; }
    50% { opacity: 0.8; }
    100% { opacity: 0.3; }
}

/* Scene 2: Core (Pinned) */
.scene-core {
    align-items: center;
    text-align: center;
}

.core-content {
    position: relative;
    height: 60vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.core-statement {
    position: absolute;
    width: 100%;
    opacity: 0;
    transform: translateY(30px);
}

.statement-text {
    font-size: clamp(2rem, 5vw, 4rem);
    line-height: 1.2;
    max-width: 1000px;
    margin: 0 auto;
    text-align: center;
    text-shadow: 0 4px 16px rgba(0, 0, 0, 0.9), 0 0 40px rgba(0, 0, 0, 0.7);
}

/* Scene 3: Permanence */
.scene-permanence {
    /* Adding a subtle gradient overlay to separate sections if needed */
    background: linear-gradient(to bottom, transparent, rgba(10, 10, 15, 0.5));
}

/* Content Containers */
.hero-content, .archive-content, .sensibility-content, .structured-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.hero-content .subtitle {
    margin: 0 auto;
    max-width: 600px;
}

/* Footer (Single Line) */
.site-footer {
    padding: 3rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: 5rem;
}

.footer-single-line {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.5rem;
    color: var(--c-parchment);
    opacity: 0.7;
    font-size: 0.85rem;
}

.footer-single-line a {
    color: inherit;
    text-decoration: none;
    transition: opacity 0.3s;
}

.footer-single-line a:hover {
    opacity: 1;
}

.separator {
    opacity: 0.5;
}

/* Scene 4: Contact */
.scene-contact {
    background: var(--c-dark-bg); /* Solid background for footer area */
    padding-top: var(--space-xl);
}

.contact-container {
    max-width: 600px;
    margin: 0 auto;
    margin-bottom: var(--space-xl);
    display: flex;
    flex-direction: column;
    align-items: center; /* Center the form container */
}

.contact-header {
    text-align: center;
    margin-bottom: 3rem;
}

.contact-form {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    color: var(--c-gold);
}

input, select, textarea {
    background: transparent;
    border: none;
    border-bottom: 1px solid rgba(255,255,255,0.2);
    color: var(--c-off-white);
    font-family: var(--font-display);
    font-size: 1.5rem;
    padding: 0.5rem 0;
    transition: border-color 0.3s;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-bottom-color: var(--c-off-white);
}

select {
    appearance: none;
    cursor: pointer;
}

select option {
    background: var(--c-dark-bg);
    color: var(--c-off-white);
}

.btn {
    display: inline-block;
    padding: 1rem 2rem;
    text-decoration: none;
    border: 1px solid var(--c-off-white);
    color: var(--c-dark-bg);
    background: var(--c-off-white);
    transition: all 0.3s ease;
    cursor: pointer;
    margin-top: 1rem;
    width: fit-content;
    align-self: center; /* Center button in form */
}

.btn:hover {
    background: transparent;
    color: var(--c-off-white);
}

@media (max-width: 768px) {
    .footer-single-line {
        flex-direction: column;
        gap: 0.5rem;
    }
    .separator {
        display: none;
    }
}
