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

body {
    background-color: #0a0a0f;
    overflow: auto;
    width: 100vw;
    height: 100vh;
}

/* Disable scrolling on mobile */
@media (max-width: 768px) {
    body {
        overflow: hidden;
        position: fixed;
        width: 100%;
        height: 100%;
    }
}

#star-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: block;
    z-index: 3;
}

#background-gradient {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 2;
    pointer-events: none;
}

#mountain {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: auto;
    object-fit: cover;
    object-position: bottom;
    z-index: 3;
    pointer-events: none;
    transform: translateY(2vw);
}

@media (min-width: 1500px) {
    #mountain {
        transform: translateY(6vw);
        /* Shift down more on large screens */
    }
}

#text {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, calc(-50% - 4vw));
    z-index: 4;
    pointer-events: none;
    text-align: center;
    transition: opacity 0.5s ease-out;
}

.line-1 {
    color: white;
    font-family: "EB Garamond", serif;
    font-size: 4.5vw;
    font-weight: 500;
    margin: 0;
    text-shadow: 3px 3px 5px #465975;
    transition: opacity 0.5s ease-out;
}

.line-2 {
    color: white;
    margin: 0;
    margin-top: -2.3vw;
    font-family: "EB Garamond", serif;
    font-size: 9vw;
    transition: opacity 0.5s ease-out;
}

.im-text {
    font-weight: 400;
    text-shadow: 3px 3px 5px #465975;
}

.jiayi-text {
    font-weight: 600;
    font-style: italic;
    text-shadow: 3px 3px 5px #465975;
}

.line-3 {
    color: white;
    margin: 0;
    margin-top: 0.5vw;
    position: relative;
    font-family: "Manrope", sans-serif;
    font-size: 1vw;
    font-weight: 500;
    display: inline-block;
    transition: opacity 0.5s ease-out;
}

.line-3-glow {
    position: absolute;
    top: 0;
    left: 0;
    filter: blur(4px);
    opacity: 0.8;
    z-index: 0;
    white-space: nowrap;
}

.line-3-text {
    position: relative;
    z-index: 1;
    white-space: nowrap;
}

#hamburger-menu {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
}

#hamburger-button {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 37px;
    height: 25px;
    gap: 5px;
    transition: transform 0.3s ease;
    position: relative;
    z-index: 10000;
}

#hamburger-button:hover {
    transform: scale(1.1);
}

.hamburger-line {
    width: 37px;
    height: 5px;
    background-color: #ffffff;
    border-radius: 2px;
    transition: all 0.3s ease;
    display: block;
    position: relative;
    z-index: 10000;
    transform-origin: center;
    box-shadow: 3px 3px 5px rgba(70, 89, 117, 0.8);
}

#hamburger-button.active .hamburger-line:nth-child(1) {
    transform: translate(0, 10px) rotate(45deg);
}

#hamburger-button.active .hamburger-line:nth-child(2) {
    opacity: 0;
}

#hamburger-button.active .hamburger-line:nth-child(3) {
    transform: translate(0, -10px) rotate(-45deg);
}

#dropdown-menu {
    position: absolute;
    top: 50px;
    right: 0;
    background-color: rgba(10, 10, 15, 0.65);
    border-radius: 8px;
    padding: 8px 0;
    min-width: 140px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease;
}

.dropdown-hidden {
    opacity: 0;
    transform: translateY(-10px);
    visibility: hidden;
}

.dropdown-visible {
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
}

.dropdown-item {
    display: block;
    color: white;
    text-decoration: none;
    padding: 10px 16px;
    font-family: "Manrope", sans-serif;
    font-size: 14px;
    font-weight: 500;
    transition: background-color 0.2s ease, padding-left 0.2s ease;
}

.dropdown-item:hover {
    background-color: rgba(255, 255, 255, 0.1);
    padding-left: 25px;
}

#explore-button {
    position: fixed;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    background: none;
    border: none;
    color: rgba(203, 209, 220, 0.5);
    font-family: "Manrope", sans-serif;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 1px;
    cursor: pointer;
    padding: 12px 24px;
    z-index: 9999;
    transition: color 0.3s ease, transform 0.3s ease;
}

#explore-button:hover {
    color: #ffffff;
    transform: translateX(-50%) scale(1.05);
}

#content {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 4;
    text-align: center;
    color: white;
    font-family: "EB Garamond", serif;
}

#content h1 {
    font-size: 64px;
    font-weight: 500;
    text-shadow: 3px 3px 5px #465975;
}

#orbital-lines {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

#orbital-lines .orbital-line {
    opacity: 0;
}

.back-link {
    display: inline-block;
    margin-top: 20px;
    color: rgba(203, 209, 220, 0.6);
    text-decoration: none;
    font-family: "Manrope", sans-serif;
    font-size: 14px;
    font-weight: 700;
    transition: all 0.3s ease;
    cursor: pointer;
}

.back-link:hover {
    color: white;
    transform: scale(1.1);
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
}

.back-link-fixed {
    position: fixed;
    top: 40px;
    left: 40px;
    z-index: 100;
    color: rgba(203, 209, 220, 0.6);
    text-decoration: none;
    font-family: "Manrope", sans-serif;
    font-size: 14px;
    font-weight: 700;
    transition: all 0.3s ease;
    cursor: pointer;
}

.back-link-fixed:hover {
    color: white;
    transform: scale(1.1);
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
}

.back-link-center {
    position: fixed;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    background: none;
    border: none;
    color: rgba(203, 209, 220, 0.5);
    font-family: "Manrope", sans-serif;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 1px;
    cursor: pointer;
    padding: 12px 24px;
    transition: color 0.3s ease, transform 0.3s ease;
}

.back-link-center:hover {
    color: #ffffff;
    transform: translateX(-50%) scale(1.05);
}

/* Mobile Breakpoints */
@media (max-width: 768px) {
    body {
        overflow: hidden;
        position: fixed;
        width: 100%;
        height: 100%;
    }

    #text {
        transform: translate(-50%, calc(-50% - 15vw));
        width: 90%;
        padding: 0 20px;
    }

    .line-1 {
        font-size: 11vw;
    }

    .line-2 {
        font-size: 22vw;
        margin-top: -5vw;
    }

    .line-3 {
        font-size: 4.2vw;
        margin-top: 2.5vw;
    }

    /* Zoom in mountain to take up ~20% of viewport */
    #mountain {
        transform: translateY(0) scale(1.8);
        transform-origin: bottom center;
        height: 25vh;
        width: auto;
        min-width: 100%;
    }

    #hamburger-menu {
        top: 15px;
        right: 15px;
    }

    #hamburger-button {
        width: 30px;
        height: 20px;
    }

    .hamburger-line {
        width: 30px;
        height: 4px;
    }

    #hamburger-button.active .hamburger-line:nth-child(1) {
        transform: translate(0, 8px) rotate(45deg);
    }

    #hamburger-button.active .hamburger-line:nth-child(3) {
        transform: translate(0, -8px) rotate(-45deg);
    }

    #dropdown-menu {
        min-width: 120px;
        font-size: 12px;
    }

    .dropdown-item {
        font-size: 12px;
        padding: 8px 12px;
    }

    #explore-button,
    .back-link-center {
        bottom: 30px;
        font-size: 12px;
        padding: 10px 20px;
    }

    .back-link-fixed {
        top: 30px;
        left: 30px;
        font-size: 12px;
    }

    #content h1 {
        font-size: 32px;
    }
}

@media (max-width: 480px) {
    body {
        overflow: hidden;
        position: fixed;
    }

    #text {
        transform: translate(-50%, calc(-50% - 18vw));
    }

    .line-1 {
        font-size: 13vw;
    }

    .line-2 {
        font-size: 26vw;
        margin-top: -6vw;
    }

    .line-3 {
        font-size: 4.8vw;
        margin-top: 3.5vw;
    }

    /* Zoom in mountain even more on smaller screens */
    #mountain {
        transform: translateY(0) scale(2.2);
        transform-origin: bottom center;
        height: 22vh;
        width: auto;
        min-width: 100%;
    }

    #hamburger-menu {
        top: 10px;
        right: 10px;
    }

    #hamburger-button {
        width: 25px;
        height: 18px;
    }

    .hamburger-line {
        width: 25px;
        height: 3px;
    }

    #hamburger-button.active .hamburger-line:nth-child(1) {
        transform: translate(0, 7px) rotate(45deg);
    }

    #hamburger-button.active .hamburger-line:nth-child(3) {
        transform: translate(0, -7px) rotate(-45deg);
    }

    #explore-button,
    .back-link-center {
        bottom: 20px;
        font-size: 11px;
        padding: 8px 16px;
    }

    .back-link-fixed {
        top: 20px;
        left: 20px;
        font-size: 11px;
    }

    #content h1 {
        font-size: 24px;
    }
}