/* Root variables for consistent theming */
:root {
    --primary-bg: #0a0f18;
    --primary-text: #e0e0e0;
    --accent-life: #4d9f8d;
    --highlight-hope: #f0b88b;
    --dark-overlay: rgba(10, 15, 24, 0.9);
    --serif-font: 'Lora', serif;
    --sans-font: 'Source Sans 3', sans-serif;
}

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--sans-font);
    color: var(--primary-text);
    background-color: var(--primary-bg);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Canvas background */
#consciousness-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    opacity: 0.8;
}

/* Typography */
h1, h2, h3 {
    font-family: var(--serif-font);
    font-weight: 500;
    letter-spacing: 0.02em;
}

h1 {
    font-size: clamp(3rem, 8vw, 6rem);
    text-align: center;
    margin-bottom: 1rem;
}

h2 {
    font-size: clamp(2rem, 5vw, 3.5rem);
    margin-bottom: 2rem;
    text-align: center;
    color: var(--highlight-hope);
}

h3 {
    font-size: clamp(1.5rem, 3vw, 2rem);
    margin-bottom: 0.5rem;
    color: var(--accent-life);
}

h4 {
    font-size: 1.1rem;
    color: var(--primary-text);
    opacity: 0.8;
    margin-bottom: 1rem;
    font-weight: 300;
}

p {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    font-weight: 300;
    opacity: 0.9;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

em {
    font-style: italic;
    color: var(--accent-life);
}

/* Full screen sections */
.full-screen {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

/* Hero section */
#hero {
    background: radial-gradient(circle at center, transparent, var(--dark-overlay));
}

.hero-content {
    text-align: center;
    animation: fadeIn 2s ease-out;
}

.hero-title {
    background: linear-gradient(135deg, var(--primary-text) 0%, var(--accent-life) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: shimmer 10s ease-in-out infinite;
}

.hero-subtitle {
    font-size: 1.5rem;
    opacity: 0.8;
    margin-bottom: 3rem;
    animation: fadeInUp 2s ease-out 0.5s both;
}

@keyframes shimmer {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.8; }
}

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

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

/* Buttons */
.cta-button {
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
    font-family: var(--sans-font);
    font-weight: 400;
    background: transparent;
    color: var(--primary-text);
    border: 2px solid var(--accent-life);
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: lowercase;
    letter-spacing: 0.1em;
}

.cta-button:hover {
    background: var(--accent-life);
    color: var(--primary-bg);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(77, 159, 141, 0.3);
}

.cta-button.glow {
    animation: pulse 3s infinite;
}

.cta-button.primary {
    background: linear-gradient(135deg, var(--accent-life), var(--highlight-hope));
    border: none;
    color: var(--primary-bg);
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 0 20px rgba(77, 159, 141, 0.5);
    }
    50% {
        box-shadow: 0 0 40px rgba(77, 159, 141, 0.8);
    }
}

/* Scroll indicator */
.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(10px); }
}

/* Content sections */
.content-section {
    padding: 5rem 1rem;
    position: relative;
    background: var(--dark-overlay);
    backdrop-filter: blur(10px);
}

.content-section:nth-child(even) {
    background: rgba(77, 159, 141, 0.05);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

.section-content {
    animation: fadeInUp 1s ease-out;
}

.section-content p {
    animation: fadeInUp 1s ease-out;
    animation-fill-mode: both;
}

.section-content p:nth-child(1) { animation-delay: 0.1s; }
.section-content p:nth-child(2) { animation-delay: 0.2s; }
.section-content p:nth-child(3) { animation-delay: 0.3s; }
.section-content p:nth-child(4) { animation-delay: 0.4s; }

/* Dark section variant */
.dark-section {
    background: linear-gradient(180deg, var(--primary-bg) 0%, rgba(77, 159, 141, 0.1) 100%);
}

/* Highlight text */
.highlight {
    color: var(--highlight-hope);
    font-size: 1.3rem;
    text-align: center;
    font-weight: 400;
    margin-top: 2rem;
}

/* Pillars section */
.pillars {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
    margin-top: 3rem;
}

.pillar {
    padding: 2rem;
    background: rgba(77, 159, 141, 0.05);
    border-radius: 20px;
    border: 1px solid rgba(77, 159, 141, 0.2);
    transition: all 0.3s ease;
}

.pillar:hover {
    transform: translateY(-5px);
    background: rgba(77, 159, 141, 0.1);
    box-shadow: 0 20px 40px rgba(77, 159, 141, 0.2);
}

.pillar h3 {
    margin-bottom: 0.5rem;
}

.pillar p {
    font-size: 1rem;
}

/* Final section */
.final-section {
    min-height: 60vh;
    display: flex;
    align-items: center;
    background: radial-gradient(circle at center, rgba(240, 184, 139, 0.1), transparent);
}

.centered {
    text-align: center;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(10, 15, 24, 0.95);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
    animation: fadeIn 0.3s ease-out;
}

.modal-content {
    background: var(--primary-bg);
    padding: 3rem;
    border-radius: 20px;
    border: 2px solid var(--accent-life);
    max-width: 500px;
    width: 90%;
    position: relative;
    animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.close-modal {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    color: var(--primary-text);
    font-size: 2rem;
    cursor: pointer;
    opacity: 0.5;
    transition: opacity 0.3s;
}

.close-modal:hover {
    opacity: 1;
}

/* Form */
#email-form {
    margin: 2rem 0;
}

#email-input {
    width: 100%;
    padding: 1rem;
    background: rgba(77, 159, 141, 0.1);
    border: 1px solid var(--accent-life);
    border-radius: 50px;
    color: var(--primary-text);
    font-size: 1rem;
    margin-bottom: 1rem;
}

#email-input::placeholder {
    color: var(--primary-text);
    opacity: 0.5;
}

#email-input:focus {
    outline: none;
    border-color: var(--highlight-hope);
    box-shadow: 0 0 20px rgba(240, 184, 139, 0.3);
}

.consent-text {
    font-size: 0.9rem;
    opacity: 0.7;
    text-align: center;
}

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
    border: 0;
}

/* Focus styles for keyboard navigation */
*:focus {
    outline: 2px solid var(--accent-life);
    outline-offset: 2px;
}

/* Responsive design */
@media (max-width: 768px) {
    .content-section {
        padding: 3rem 1rem;
    }
    
    .pillars {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    h1 {
        font-size: 3rem;
    }
    
    h2 {
        font-size: 2rem;
    }
    
    p {
        font-size: 1rem;
    }
    
    .modal-content {
        padding: 2rem;
    }
}

/* Loading animation */
@keyframes loading {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Smooth transitions for all interactive elements */
* {
    transition: opacity 0.3s ease, transform 0.3s ease;
}