body {
    display: flex;
    flex-direction: column;
    margin: 0;
    font-family: 'ZCOOL QingKe HuangYou', cursive, sans-serif;
    background: radial-gradient(ellipse at bottom, #1B2735 0%, #090A0F 100%);
    color: #fff;
    overflow-x: hidden;
    position: relative;
    min-height: 100vh;
}

.page-content {
    flex: 1;
    position: relative;
    z-index: 1;
    padding-bottom: 100px;
}

.page-title {
    position: absolute;
    top: 3vh;
    left: 50%;
    transform: translateX(-50%);
    font-size: 2.2rem;
    z-index: 10;
    font-family: 'ZCOOL QingKe HuangYou', cursive;
}


canvas#stars-canvas {
    position: fixed;
    top: 0;
    left: 0;
    z-index: -1;
    width: 100%;
    height: 100%;
}


.opening-text {
    position: absolute;
    top: 18vh;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 800px;
    text-align: center;
    z-index: 10;
}

.opening-text p {
    font-size: 2rem;
    line-height: 1.6;
    margin: 20px 0;
    opacity: 0;
    animation: fadeIn 1s forwards;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

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


#bottles-container {
    position: relative;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none; 
    z-index: 20;
    margin-top: 70vh;
}

.bottle {
    position: absolute;
    width: 80px;
    height: 120px;
    cursor: pointer;
    opacity: 0;
    pointer-events: auto; 
    transition: all 1s ease;
    z-index: 30;
}

.bottle.visible {
    transform: translateY(0);
    opacity: 1;
}

.bottle img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 0 15px rgba(170, 216, 194, 0.6));
    transition: all 0.5s ease;
}

.bottle:hover img {
    transform: translateY(-10px) rotate(5deg);
    filter: drop-shadow(0 0 20px rgba(170, 216, 194, 0.9));
}

.bottle-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 150%;
    height: 150%;
    transform: translate(-50%, -50%);
    background: radial-gradient(circle, rgba(170, 216, 194, 0.4) 0%, transparent 70%);
    border-radius: 50%;
    animation: glow-pulse 3s infinite alternate;
    z-index: -1;
}

@keyframes glow-pulse {
    0% { opacity: 0.3; transform: translate(-50%, -50%) scale(0.8); }
    100% { opacity: 0.7; transform: translate(-50%, -50%) scale(1.2); }
}


.wish-card {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.8);
    width: 90%;
    max-width: 600px;
    background: rgba(27, 39, 53, 0.95);
    border: 2px solid rgba(170, 216, 194, 0.3);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.2, 0.8, 0.3, 1);
    z-index: 100;
    overflow-y: auto;
    max-height: 80vh;
}

.wish-card.active {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
}

.wish-card img {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 20px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.wish-text {
    font-size: 1.2rem;
    line-height: 1.8;
    text-align: left;
    padding: 0 10px;
}

.close-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 2rem;
    color: #aad8c2;
    cursor: pointer;
    transition: all 0.3s;
}

.close-btn:hover {
    transform: scale(1.2);
    color: #fff;
}


#continue-btn {
    position: relative;
    bottom: -20vh;
    left: 50%;
    transform: translateX(-50%);
    padding: 15px 40px;
    background: rgba(170, 216, 194, 0.7);
    backdrop-filter: blur(5px);
    border: none;
    border-radius: 50px;
    color: white;
    font-size: 1.2rem;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.5s;
    z-index: 30;
    opacity: 0;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
}

#continue-btn.visible {
    opacity: 1;
    animation: float 3s ease-in-out infinite;
}

#continue-btn:hover {
    background: rgba(170, 216, 194, 0.9);
    transform: translateX(-50%) scale(1.05);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

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


.page-transition-wave {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 0;
    background: linear-gradient(to top, #aad8c2, #7ab8a0);
    z-index: 999;
    animation: waveRise 1.2s cubic-bezier(0.7, 0, 0.3, 1) forwards;
}

@keyframes waveRise {
    to { height: 100%; }
}


@media (max-width: 768px) {
    .opening-text p {
        font-size: 1.5rem;
    }

    .bottle {
        width: 60px;
        height: 90px;
    }

    .wish-card {
        padding: 20px;
    }

    .wish-text {
        font-size: 1rem;
    }

    #continue-btn {
        padding: 12px 30px;
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    #bottles-container {
        padding: 0 5%;
    }

    .bottle {
        width: 50px;
        height: 75px;
    }
}


.hidden {
    display: none !important;
}

.visible {
    display: block !important;
}