@font-face {
    font-family: 'Geist Mono';
    src: url('fonts_web/GeistMono-VariableFont_wght.ttf') format('truetype-variations');
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Geist Mono';
    src: url('fonts_web/GeistMono-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Geist Mono';
    src: url('fonts_web/GeistMono-Medium.ttf') format('truetype');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Geist Mono';
    src: url('fonts_web/GeistMono-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Geist Mono';
    src: url('fonts_web/GeistMono-Light.ttf') format('truetype');
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Geist Mono';
    src: url('fonts_web/GeistMono-SemiBold.ttf') format('truetype');
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes slideUp {
    from { transform: translateY(30px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}
@keyframes lineFromBottom {
    from { 
        height: 0;
        transform: translateY(100vh);
    }
    to { 
        height: 100vh;
        transform: translateY(0);
    }
}
@keyframes lineFromTop {
    from { 
        height: 0;
        transform: translateY(-100vh);
    }
    to { 
        height: 100vh;
        transform: translateY(0);
    }
}
@keyframes letterAppear {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes lettersToCenter {
    from { transform: translateX(0); }
    to { transform: translateX(0); }
}
@keyframes subtitleFadeUp {
    from { 
        opacity: 0;
        transform: translateY(30px);
    }
    to { 
        opacity: 1;
        transform: translateY(0);
    }
}
@keyframes fadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}

/* Unified animation duration for section transitions */
:root {
    --section-anim-ms: 500ms;
    --font-anim-ms: 500ms;
    /* Ease-in: start slow, end fast */
    --section-easing: linear;
    --font-easing: linear;
    --left-easing: linear;
    /* Theme colors */
    --color-primary: #e7dcd6;
    --color-secondary: #8e9982;
}

body {
    font-family: 'Geist Mono';
    letter-spacing: -0.01em;
    cursor: none; /* hide native cursor so custom one is visible */
    background-color: var(--color-secondary);
    margin: 0;
    padding: 0;
}

/* Disable scroll on PC (desktop) */
@media (min-width: 768px) {
    html, body {
        height: 100vh;
        overflow: hidden; /* prevent page scrolling on desktop */
    }
}

/* Enhanced typography */
h1, h2, h3, h4, h5, h6 {
    letter-spacing: -0.02em;
    font-weight: 500;
}

/* Improved button styles */
.btn-primary {
    background: linear-gradient(135deg, #8e9982 0%, #868583 100%);
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(142, 153, 130, 0.3);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(142, 153, 130, 0.4);
}

/* Enhanced card styles */
.card-hover {
    transition: all 0.3s ease;
}
.card-hover:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

/* Enhanced animations */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease-in;
}
.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}
.stagger-1 { transition-delay: 0.1s; }
.stagger-2 { transition-delay: 0.2s; }
.stagger-3 { transition-delay: 0.3s; }

/* Parallax effect */
.parallax {
    transform: translateZ(0);
    will-change: transform;
}

/* Enhanced logo animation */
.logo-float {
    animation: logoFloat 3s ease-in-out infinite;
}
@keyframes logoFloat {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.animation-container {
    position: relative; /* scrolls with the page */
    width: 100%;
    height: 100vh; /* hard cap to viewport height */
    max-height: 100vh;
    overflow: visible; /* allow content to be visible */
    display: flex;
    align-items: center;
    justify-content: center;
    transform-origin: top center; /* shrink toward top */
    background: linear-gradient(to top, var(--color-secondary) 50.5%, var(--color-primary) 50.5%);
    background-size: 100% 200.5%;
    background-position: 0% 0%;
    transition: transform var(--section-anim-ms) var(--section-easing),
                background-position var(--section-anim-ms) var(--section-easing);
}

/* Shrink entire container instead of individual letters */
.animation-container.letters-section-active {
    background-position: 0% 100%;
    transition: transform var(--section-anim-ms) var(--section-easing),
                background-position var(--section-anim-ms) var(--section-easing) !important;
}

/* Letters move to top and stay anchored */
.animation-container.letters-section-active .letter {
    font-size: clamp(2rem, 6.5vw, 10rem);
    top: 1vh;
    transform: translate(-50%, 0);
    transition: font-size var(--section-anim-ms) var(--section-easing),
                left var(--section-anim-ms) var(--left-easing),
                top var(--section-anim-ms) var(--section-easing),
                transform var(--section-anim-ms) var(--section-easing);
}
.animation-container.letters-section-active .letter-3 {
    /* Keep letter-3 position relative to others */
    top: 8vh;
}

/* Remove individual left overrides - spacing is now automatic */

.letters-section-active .letter-1 { left: 43% !important; }
.letters-section-active .letter-2 { left: 46.5% !important; }
.letters-section-active .letter-3 { left: 50% !important; }
.letters-section-active .letter-4 { left: 53.5% !important; }
.letters-section-active .letter-5 { left: 57% !important; }



.line {
    position: absolute;
    width: 9px;
    background-color: #000000;
    height: 100vh;
    animation: lineFromBottom 1s ease-in 0.5s both;
}
.line-1 { left: 20%; }
.line-2 { left: 40%; animation-name: lineFromTop; }
.line-3 { left: 60%; }
.line-4 { left: 80%; animation-name: lineFromTop; }

.letter-1.letters-close { left: 10%; }
.letter-2.letters-close { left: 30%; }
.letter-3.letters-close { left: 50%; }
.letter-4.letters-close { left: 70%; }
.letter-5.letters-close { left: 90%; }

.letter {
    position: absolute;
    top: 50%;
    font-size: clamp(16rem, min(35vw, 80vh), 45rem);
    font-weight: 300;
    color: #000000;
    opacity: 0;
    /* animation: letterAppear 1.5s ease-out both; */
    animation: letterAppear both;
    transition: 
        top var(--section-anim-ms) var(--section-easing),
        left var(--section-anim-ms) var(--left-easing),
        font-size var(--font-anim-ms) var(--font-easing);
    transform: translate(-50%, -50%);
    transform-origin: bottom center;
    line-height: 1;
    white-space: nowrap;
    z-index: 10001;  /* keep letters on top after overlay fades */
 
}
@media (max-width: 768px) {
    .letter { font-size: clamp(6rem, 18vw, 12rem); }
}
.letter-1 { left: 10%; animation-delay: 2s; }
.letter-2 { left: 30%; animation-delay: 2.2s; }
.letter-3 { left: 50%; animation-delay: 2.4s; }
.letter-4 { left: 70%; animation-delay: 2.6s; }
.letter-5 { left: 90%; animation-delay: 2.8s; }


.subtitle {
    position: absolute;
    font-size: 1.5rem;
    font-weight: 600;
    color: #000000;
    opacity: 0;
    animation: subtitleFadeUp 0.7s ease-in 3.5s both;
    text-align: center;
    line-height: 1.3;
    left: 47%;
    transform: translateX(-50%) translateY(var(--lower-offset, 0em));
    transition: transform 0.6s ease-in;
    top: 55%;
    z-index: 10001; /* keep subtitle on top after overlay fades */
}

.fade-out {
    animation: fadeOut 1s ease-in 7s both;
}

/* Custom circular cursor */
.custom-cursor {
    position: fixed;
    top: 0;
    left: 0;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.35); /* medium opacity */
    pointer-events: none;
    transform: translate(-50%, -50%);
    transition: transform 120ms ease, width 120ms ease, height 120ms ease, background 120ms ease, opacity 160ms ease;
    z-index: 100000;
    mix-blend-mode: normal;
    will-change: transform, opacity;
}

/* Enlarge slightly on interactive hover */
.custom-cursor.cursor-hover {
    transform: translate(-50%, -50%) scale(1.5);
    background: rgba(0, 0, 0, 0.45);
}

/* Hidden state (when leaving window or over inputs if desired) */
.custom-cursor.cursor-hidden {
    opacity: 0;
    transition: opacity 120ms ease;
}

/* Main content container: 75% of original height */
#main-content {
    background-color: #8e9982;
    height: 75vh;
    max-height: 75vh;
    overflow: auto;
}

/* Content section: 50% of original height */
#content {
    min-height: 75vh;
    height: 75vh;
    max-height: 75vh;
}

/* Shift animation container down by 10% with a 500ms transition */
.animation-container.shift-down-10 {
    transform: translateY(15%);
    transition: transform 500ms;
}

/* Remove shift when letters-section-active so content isn't pushed down */
.animation-container.shift-down-10.letters-section-active {
    transform: translateY(0);
}

/* Remove gap between animation container and content */
#animation-wrapper {
    font-size: 0;
    line-height: 0;
    position: relative;
}

#animation-wrapper::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 5px;
    background-color: var(--color-secondary);
    z-index: 10000;
}

#main-content {
    margin-top: -1px;
}

/* Content area inside animation container */
.content-area {
    position: absolute;
    top: 30vh;
    left: 0;
    right: 0;
    padding: 2rem;
    z-index: 9999;
    overflow-y: auto;
    max-height: 65vh;
}

.content-area.visible {
    display: block;
}

/* Content section fade-in animation */
.content-section {
    opacity: 0;
    transition: opacity 0.5s ease-in;
}

.content-section.visible {
    opacity: 1;
}

.content-section.hidden {
    display: none;
}
