:root {
    /* Color Palette */
    --black: #000000;
    --white: #ffffff;
    --gray-light: #e0e0e0;
    --gray-dark: #333333;

    /* Accents (Text Only) */
    --accent-purple: #9d4edd;
    --accent-red: #d00000;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Galmuri9', 'Galmuri7', sans-serif;
}

body {
    background: linear-gradient(90deg, var(--black) 50%, var(--white) 50%);
    overflow-x: hidden;
    color: var(--white);
    /* Default */
    position: relative;
    min-height: 100vh;
}

/* Ambient Background Layer */
/* Changed to Absolute for Scroll Interaction */
#ambient-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
    overflow: hidden;
}

.bg-cocktail {
    position: fixed;
    /* Keep cocktail fixed (Parallax logic in JS uses fixed/relative window, but let's keep it fixed to be visible always) */
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0.85;
    filter: blur(8px);
    width: 120vh;
    height: auto;
    will-change: transform;
}

.bg-cocktail img {
    width: 100%;
    height: auto;
    display: block;
}

/* Floating Text Styles */
.floating-word {
    position: absolute;
    /* Color is set by JS based on position */
    font-size: 1.5rem;
    pointer-events: none;
    white-space: nowrap;
    font-weight: bold;
    opacity: 0;
    /* Start hidden */
}

/* 
    Animation Logic: Accel -> Maintain -> Decel 
    Duration: 10s
    0-20% (2s): Accel, Fade In
    20-80% (6s): Sustain, Opacity 1
    80-100% (2s): Decel, Fade Out
*/

.floating-word.flow-right {
    animation: flowRight 10s forwards;
}

.floating-word.flow-left {
    animation: flowLeft 10s forwards;
}

@keyframes flowRight {
    0% {
        opacity: 0;
        transform: translateX(0);
        animation-timing-function: ease-in;
        /* Accel */
    }

    20% {
        opacity: 1;
        transform: translateX(100px);
        animation-timing-function: linear;
        /* Maintain */
    }

    80% {
        opacity: 1;
        transform: translateX(400px);
        animation-timing-function: ease-out;
        /* Decel */
    }

    100% {
        opacity: 0;
        transform: translateX(450px);
    }
}

@keyframes flowLeft {
    0% {
        opacity: 0;
        transform: translateX(0);
        animation-timing-function: ease-in;
    }

    20% {
        opacity: 1;
        transform: translateX(-100px);
        animation-timing-function: linear;
    }

    80% {
        opacity: 1;
        transform: translateX(-400px);
        animation-timing-function: ease-out;
    }

    100% {
        opacity: 0;
        transform: translateX(-450px);
    }
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 1.5rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.logo {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--white);
    letter-spacing: 1px;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 2rem;
}

.nav-links a,
.nav-btn {
    text-decoration: none;
    background: none;
    border: none;
    cursor: pointer;
    font-family: inherit;
    color: var(--white);
    font-size: 0.9rem;
    opacity: 0.7;
    transition: opacity 0.3s;
    padding: 0;
}

.nav-links a:hover,
.nav-btn:hover {
    opacity: 1;
}

/* Hero Section */
.hero-section {
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.hero-content {
    background: rgba(0, 0, 0, 0.6);
    padding: 3rem;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
}

.hero-title {
    font-size: 4rem;
    margin-bottom: 1rem;
    color: var(--white);
}

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--accent-purple);
    margin-bottom: 2rem;
}

.hero-desc {
    font-size: 1.2rem;
    line-height: 1.6;
}

/* Content Sections */
.content-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 100px 0;
}

.container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 5%;
}

.content-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0;
}

.text-panel,
.visual-panel {
    flex: 1;
    padding: 3rem;
    position: relative;
    z-index: 1;
}

/* Text Colors based on Background */
.left-text .text-panel {
    color: var(--white);
    text-align: left;
}

.left-text .section-title {
    color: var(--white);
    border-left: 4px solid var(--accent-purple);
    padding-left: 1.5rem;
}

.left-text .flavor-text {
    color: var(--gray-light);
}

.left-text .desc-text {
    color: #aaa;
}

.right-text .text-panel {
    color: var(--black);
    text-align: right;
}

.right-text .section-title {
    color: var(--black);
    border-right: 4px solid var(--accent-red);
    padding-right: 1.5rem;
}

.right-text .flavor-text {
    color: var(--gray-dark);
}

.right-text .desc-text {
    color: #666;
}

/* Typography Common */
.section-title {
    font-size: 3rem;
    margin-bottom: 2.5rem;
    line-height: 1.2;
}

.flavor-text {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 2rem;
    line-height: 1.6;
}

.desc-text {
    font-size: 1rem;
    line-height: 1.8;
}

/* Visuals */
.visual-panel {
    display: flex;
    justify-content: center;
    align-items: center;
}

.image-container {
    width: 100%;
    max-width: 500px;
}

.featured-img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}

.cocktail-img {
    display: none;
}

.lore-card {
    background: #111;
    color: #fff;
    padding: 4rem;
    border: 1px solid #333;
    text-align: center;
    border-radius: 2px;
}

.lore-card h3 {
    color: var(--accent-red);
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

/* Cocktail List */
.cocktail-list {
    list-style: none;
    margin-top: 3rem;
}

.cocktail-item {
    margin-bottom: 2rem;
}

.c-name {
    display: block;
    font-size: 1.3rem;
    color: var(--accent-purple);
    margin-bottom: 0.5rem;
    font-weight: bold;
}

.c-desc {
    font-size: 0.95rem;
    opacity: 0.8;
}

/* Typing Animation Cursor */
.typing-cursor::after {
    content: '▋';
    display: inline-block;
    vertical-align: middle;
    animation: blink 1s step-end infinite;
    color: inherit;
    margin-left: 2px;
    font-size: 0.8em;
}

.right-text .typing-cursor::after {
    color: var(--black);
}

@keyframes blink {

    from,
    to {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

/* Footer */
footer {
    padding: 4rem;
    background: black;
    color: #666;
    text-align: center;
    border-top: 1px solid #222;
}

/* Mobile & Tablet Optimization */
@media (max-width: 900px) {
    body {
        background: var(--black);
    }

    .bg-cocktail {
        width: 80vw;
        opacity: 0.1;
    }

    .content-wrapper {
        flex-direction: column;
        gap: 4rem;
    }

    .left-text .content-wrapper {
        flex-direction: column-reverse;
    }

    .right-text .text-panel {
        color: var(--white);
        text-align: center;
    }

    .left-text .text-panel {
        text-align: center;
    }

    .right-text .section-title,
    .left-text .section-title {
        color: var(--white);
        border: none;
        border-bottom: 3px solid var(--accent-purple);
        padding: 0 0 1rem 0;
        display: inline-block;
    }

    .right-text .flavor-text,
    .left-text .flavor-text {
        color: var(--gray-light);
    }

    .right-text .desc-text,
    .left-text .desc-text {
        color: #aaa;
    }

    .lore-card {
        border-color: #333;
    }

    .hero-title {
        font-size: 3rem;
    }

    .panel {
        padding: 1rem;
    }

    /* Ensure floating text is visible on black bg */
    .floating-word {
        color: rgba(255, 255, 255, 0.4);
    }
}