/* --- RESET & VARIABLES --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-user-select: none;
    /* Safari */
    -moz-user-select: none;
    /* Firefox */
    -ms-user-select: none;
    /* IE/Edge */
    user-select: none;
    /* Standard */
}

:root {
    --bg-core: #000000;
    /* Pure Black for maximum contrast */
    --text-primary: #F2F2F2;
    --text-secondary: #888888;
    --font-sans: 'DM Sans', sans-serif;
    --font-serif: 'DM Sans', sans-serif;
}

body {
    font-family: var(--font-sans);
    background-color: var(--bg-core);
    color: var(--text-primary);
    height: 100vh;
    width: 100vw;
    overflow-x: hidden;
    overflow-y: scroll;
    -webkit-scroll-snap-type: y mandatory;
    /* Safari */
    scroll-snap-type: y mandatory;
    position: relative;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    touch-action: pan-y;
    /* Better touch scrolling */
    -webkit-overflow-scrolling: touch;
    /* Smooth iOS scrolling */
}

/* --- BACKGROUND LAYERS --- */
canvas#liquid-chrome {
    position: fixed;
    /* Fixed background */
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    display: block;
}

.grain {
    position: fixed;
    /* Fixed grain */
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 20;
    /* Ensure it's above everything including white background */
    opacity: 0.05;
    /* Slightly increased for visibility on white */
    pointer-events: none;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
    mix-blend-mode: overlay;
    /* Better visibility on both dark and light */
}

/* --- SECTIONS --- */
.section {
    position: relative;
    z-index: 10;
    height: 100vh;
    width: 100%;
    -webkit-scroll-snap-align: start;
    /* Safari */
    scroll-snap-align: start;
    overflow: hidden;
    contain: layout style paint;
    /* Performance isolation */
}



.light-section {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
}

.massive-logo {
    width: 80vw;
    /* Massive */
    max-width: 1200px;
    height: auto;
    opacity: 0;
    transform: scale(0.9);
    transition: all 1s ease-out;
}

.light-section.visible .massive-logo {
    opacity: 1;
    transform: scale(1);
}

/* --- UI LAYOUT --- */
.layout {
    position: relative;
    height: 100vh;
    /* Full viewport height for first section */
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 15px 60px;
}

/* Header */
.header {
    width: 100%;
    display: flex;
    justify-content: flex-start;
    align-items: center;
}

/* Logo Image Styling */
.brand-logo {
    height: 140px;
    /* Adjustable height */
    width: auto;
    /* Maintain aspect ratio */
    opacity: 0;
    animation: fadeIn 2s ease forwards 0.2s;
    /* Optional: Invert if your logo is black and needs to be white */
    /* filter: invert(1); */
    pointer-events: none;
    user-select: none;
    -webkit-user-drag: none;
}

/* Main Content - RIGHT ALIGNED */
.content-area {
    display: flex;
    justify-content: flex-end;
    /* Push to right */
    align-items: center;
    flex-grow: 1;
    padding-right: 0;
    padding-bottom: 15vh;
}

.text-group {
    /* Increased width for "Longer" look */
    max-width: 750px;
    text-align: left;
    margin-right: 2vw;
}

.title {
    font-family: 'DM Sans', sans-serif;
    /* Increased font size for "Bigger" look */
    font-size: 4.5rem;
    line-height: 1.2;
    font-weight: 500;
    /* Google Sans looks best at 500 for titles */
    color: #FFFFFF;
    margin-bottom: 32px;
    letter-spacing: -0.03em;
    /* Tighter tracking for geometric sans */
    opacity: 0;
    transform: translateY(30px);
    animation: textReveal 1.8s cubic-bezier(0.16, 1, 0.3, 1) forwards 0.5s;
    text-shadow: 0 20px 50px rgba(0, 0, 0, 1);
}

/* --- REVERTED TO SOLID ELEGANCE --- */
.title em {
    font-family: 'DM Sans', sans-serif;
    font-weight: 500;
    font-style: normal;
    /* Re-enable italics for emphasis */
    color: #FFFFFF;
    /* Solid white, no transparency */
    opacity: 0.95;
    /* Subtle depth */
    text-shadow: 0 0 30px rgba(255, 255, 255, 0.2);
    /* Soft glow instead of glass refraction */
    padding-right: 0;
}

.subtitle {
    font-family: var(--font-sans);
    /* Increased font size */
    font-size: 1.15rem;
    line-height: 1.6;
    font-weight: 300;
    color: rgba(230, 230, 230, 0.7);
    letter-spacing: 0.02em;
    opacity: 0;
    transform: translateY(20px);
    animation: textReveal 1.8s cubic-bezier(0.16, 1, 0.3, 1) forwards 0.8s;
    padding-left: 24px;
    position: relative;
    /* border-left: 1px solid rgba(255, 255, 255, 0.15); */
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
    max-width: 600px;
    /* Ensure subtitle doesn't get too wide to read */
}

.subtitle::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 2px;

    /* The Look (Glass + Shine) */
    background: linear-gradient(to bottom,
            rgba(255, 255, 255, 0.1) 0%,
            rgba(255, 255, 255, 0.1) 40%,
            rgba(255, 255, 255, 0.8) 50%,
            /* Softer, more elegant shine */
            rgba(255, 255, 255, 0.1) 60%,
            rgba(255, 255, 255, 0.1) 100%);
    background-size: 100% 200%;
    animation: liquidShine 8s linear infinite;
    /* Even slower */

    /* The Shape (Squares) */
    -webkit-mask-image: linear-gradient(to bottom, black 2px, transparent 2px);
    mask-image: linear-gradient(to bottom, black 2px, transparent 2px);
    -webkit-mask-size: 2px 5px;
    /* Slightly tighter pattern */
    mask-size: 2px 5px;
    -webkit-mask-repeat: repeat-y;
    mask-repeat: repeat-y;

    /* Glass Glow */
    filter: drop-shadow(0 0 3px rgba(255, 255, 255, 0.4));
    /* Softer glow */
}

/* Footer */
.footer {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 400;
    opacity: 0;
    animation: fadeIn 2s ease forwards 1.2s;
    mix-blend-mode: difference;
    /* Invert color based on background */
    color: #FFFFFF;
    /* Base color white */
    width: 100%;
    font-family: 'DM Sans', sans-serif;
    /* Geometric Sans like Google Sans */
}

.authors {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 0.7rem;
    letter-spacing: 0.05em;
    /* mix-blend-mode: difference; Removed from child, applied to parent */
    color: inherit;
    padding-bottom: 12px;
}

.author-link {
    text-decoration: none;
    color: inherit;
    transition: opacity 0.3s ease;
}

.author-link:hover {
    opacity: 0.7;
}



.contact-link {
    text-decoration: none;
    color: inherit;
    /* Inherit from footer (white) */
    opacity: 0.5;
    transition: opacity 0.3s ease;
    letter-spacing: 0.02em;
}

.contact-link:hover {
    opacity: 1;
}

/* --- ANIMATIONS --- */
@keyframes textReveal {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes liquidShine {
    0% {
        background-position: 0% 0%;
    }

    100% {
        background-position: 0% 200%;
    }
}

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

/* --- RESPONSIVE --- */
@media (max-width: 1024px) {
    .text-group {
        max-width: 100%;
        margin-right: 0;
    }

    .title {
        font-size: 3.5rem;
    }
}

@media (max-width: 768px) {
    .layout {
        padding: 30px;
    }

    .text-group {
        max-width: 100%;
        margin-right: 0;
    }

    .content-area {
        justify-content: flex-start;
        margin-right: 0;
    }

    .title {
        font-size: 2.8rem;
        line-height: 1.3;
        /* Increased line-height for mobile */
        padding-right: 10px;
        /* Prevent horizontal clipping */
    }

    .title em {
        padding-right: 0;
        /* Extra padding for italic slant on mobile */
    }

    .subtitle {
        font-size: 1rem;
    }

    .footer {
        flex-direction: column-reverse;
        align-items: flex-start;
        gap: 20px;
    }
}

/* Accessibility: Reduced Motion */
@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Accessibility: Focus Styles */
:focus-visible {
    outline: 2px solid #FFFFFF;
    outline-offset: 4px;
}

/* Fallback for mix-blend-mode */
@supports not (mix-blend-mode: difference) {
    .footer {
        color: #FFFFFF !important;
    }
}