@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400;600;700&family=Philosopher:wght@400;700&display=swap');

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

body {
    font-family: 'Philosopher', sans-serif;
    background: linear-gradient(135deg, #191970 0%, #483d8b 50%, #6a5acd 100%);
    color: #f0f8ff;
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(circle at 20% 20%, rgba(240, 248, 255, 0.1) 0%, transparent 40%),
        radial-gradient(circle at 80% 80%, rgba(106, 90, 205, 0.08) 0%, transparent 35%);
    pointer-events: none;
    z-index: 1;
}

.dream-realm {
    position: relative;
    z-index: 2;
    min-height: 100vh;
}

/* Header Styles */
.ethereal-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: linear-gradient(135deg, rgba(25, 25, 112, 0.95), rgba(72, 61, 139, 0.95));
    backdrop-filter: blur(15px);
    border-bottom: 3px solid #f0f8ff;
    padding: 1rem 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.header-clouds {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
}

.dream-return {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    color: #f0f8ff;
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    padding: 0.8rem 1.5rem;
    border: 2px solid transparent;
    border-radius: 10px;
    background: rgba(240, 248, 255, 0.1);
}

.dream-return:hover {
    color: #e6e6fa;
    border-color: #f0f8ff;
    background: rgba(240, 248, 255, 0.2);
    transform: translateX(-5px);
    box-shadow: 0 0 20px rgba(240, 248, 255, 0.3);
}

.return-moon {
    font-size: 1.5rem;
    font-weight: bold;
    animation: moonGlow 2s ease-in-out infinite;
}

@keyframes moonGlow {
    0%, 100% { transform: translateX(0) scale(1); }
    50% { transform: translateX(-5px) scale(1.1); }
}

.dream-altar {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    text-align: center;
}

.altar-moon, .altar-star {
    font-size: 2.5rem;
    color: #f0f8ff;
    animation: altarFloat 4s ease-in-out infinite alternate;
}

.altar-star {
    animation-delay: 2s;
}

@keyframes altarFloat {
    0% { text-shadow: 0 0 10px rgba(240, 248, 255, 0.5); transform: scale(1) rotate(0deg); }
    100% { text-shadow: 0 0 30px rgba(240, 248, 255, 1); transform: scale(1.1) rotate(360deg); }
}

.dream-altar h1 {
    font-family: 'Cinzel', serif;
    font-size: 2.8rem;
    font-weight: 700;
    color: #f0f8ff;
    text-shadow:
        3px 3px 0px rgba(0, 0, 0, 0.5),
        0 0 20px rgba(240, 248, 255, 0.8);
    letter-spacing: 2px;
}

.ethereal-status {
    display: flex;
    gap: 2rem;
}

.status-dream {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    background: linear-gradient(135deg, rgba(240, 248, 255, 0.2), rgba(106, 90, 205, 0.1));
    padding: 1rem 1.5rem;
    border-radius: 15px;
    border: 2px solid rgba(240, 248, 255, 0.5);
    font-size: 1.2rem;
    font-weight: 600;
}

.dream-icon {
    font-size: 1.5rem;
    animation: dreamFloat 2s ease-in-out infinite;
}

@keyframes dreamFloat {
    0%, 100% { transform: scale(1) rotate(0deg); }
    50% { transform: scale(1.2) rotate(5deg); }
}

/* Main Dream Hall */
.dream-hall {
    max-width: 1400px;
    margin: 0 auto;
    padding: 3rem 2rem;
}

.mystical-web {
    background: linear-gradient(135deg, #4b0082 0%, #191970 50%, #000080 100%);
    border-radius: 25px;
    padding: 3rem;
    border: 5px solid #f0f8ff;
    box-shadow:
        0 0 50px rgba(240, 248, 255, 0.3),
        inset 0 0 30px rgba(0, 0, 0, 0.5);
    position: relative;
    overflow: hidden;
}

.mystical-web::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: conic-gradient(from 0deg, transparent, rgba(240, 248, 255, 0.05), transparent);
    animation: webRotate 30s linear infinite;
    pointer-events: none;
}

@keyframes webRotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.celestial-decorations {
    position: absolute;
    top: -2rem;
    left: -2rem;
    right: -2rem;
    bottom: -2rem;
    pointer-events: none;
    color: #f0f8ff;
    font-size: 1.5rem;
    opacity: 0.7;
}

.deco-top {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    font-size: 2rem;
    animation: decoFloat 5s ease-in-out infinite;
}

.deco-sides {
    position: absolute;
    top: 50%;
    width: 100%;
    transform: translateY(-50%);
    display: flex;
    justify-content: space-between;
}

.side-dream {
    font-size: 2.5rem;
    animation: dreamShimmer 4s ease-in-out infinite alternate;
}

.side-dream:last-child {
    animation-delay: 2s;
}

.deco-bottom {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    font-size: 2rem;
    animation: decoFloat 5s ease-in-out infinite reverse;
}

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

@keyframes dreamShimmer {
    0% { text-shadow: 0 0 10px rgba(240, 248, 255, 0.5); }
    100% { text-shadow: 0 0 30px rgba(240, 248, 255, 1), 0 0 40px rgba(106, 90, 205, 0.8); }
}

/* Dream Frame */
.dream-frame {
    position: relative;
    width: 100%;
    height: 600px;
    background: linear-gradient(135deg, #000 0%, #191970 50%, #000 100%);
    border: 4px solid #f0f8ff;
    border-radius: 20px;
    margin: 2rem 0;
    overflow: hidden;
    box-shadow:
        inset 0 0 30px rgba(240, 248, 255, 0.2),
        0 0 20px rgba(0, 0, 0, 0.8);
    z-index: 2;
}

.dream-iframe {
    width: 100%;
    height: 100%;
    border: none;
    border-radius: 16px;
}

/* Dream Wisdom */
.dream-wisdom {
    position: relative;
    z-index: 2;
    margin-top: 2rem;
}

.wisdom-web {
    text-align: center;
    background: linear-gradient(135deg, rgba(240, 248, 255, 0.2), rgba(106, 90, 205, 0.1));
    padding: 2rem;
    border-radius: 20px;
    border: 3px solid #f0f8ff;
    position: relative;
}

.wisdom-web::before {
    content: '🌙';
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #4b0082, #191970);
    padding: 0 1rem;
    font-size: 2rem;
    color: #f0f8ff;
}

.wisdom-web h3 {
    font-family: 'Cinzel', serif;
    font-size: 2rem;
    color: #f0f8ff;
    margin-bottom: 1rem;
    text-shadow: 0 0 15px rgba(240, 248, 255, 0.8);
}

.wisdom-web p {
    font-size: 1.2rem;
    color: #e6e6fa;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.celestial-features {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.dream-feature {
    background: linear-gradient(135deg, #6a5acd, #9370db);
    color: #fff;
    padding: 0.8rem 1.5rem;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: 600;
    border: 2px solid #f0f8ff;
    transition: all 0.3s ease;
    font-family: 'Cinzel', serif;
    box-shadow: 0 0 10px rgba(106, 90, 205, 0.3);
}

.dream-feature:hover {
    background: linear-gradient(135deg, #9370db, #ba55d3);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(106, 90, 205, 0.5);
}

/* Footer */
.dream-footer {
    background: linear-gradient(135deg, #191970, #483d8b);
    color: #f0f8ff;
    padding: 2rem;
    text-align: center;
    border-top: 3px solid #f0f8ff;
    margin-top: 3rem;
}

.footer-stars {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 1rem;
    font-size: 2rem;
    animation: starsDance 10s ease-in-out infinite;
}

@keyframes starsDance {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    25% { transform: translateY(-10px) rotate(90deg); }
    50% { transform: translateY(0) rotate(180deg); }
    75% { transform: translateY(10px) rotate(270deg); }
}

.footer-whisper {
    font-style: italic;
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    color: #e6e6fa;
    text-shadow: 0 0 10px rgba(240, 248, 255, 0.5);
}

.footer-visions {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.footer-visions a {
    color: #f0f8ff;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    font-weight: 600;
    border: 2px solid transparent;
}

.footer-visions a:hover {
    color: #e6e6fa;
    background: rgba(240, 248, 255, 0.2);
    border-color: #f0f8ff;
    text-shadow: 0 0 10px rgba(240, 248, 255, 0.8);
}

.age-disclaimer {
    color: #ff6b6b;
    font-size: 1rem;
    font-weight: 600;
    margin: 1rem auto;
    text-align: center;
    padding: 0.8rem;
    background: rgba(255, 107, 107, 0.1);
    border: 2px solid rgba(255, 107, 107, 0.3);
    border-radius: 8px;
    max-width: 600px;
}

/* Floating Dreams */
.floating-dreams {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.float-dream {
    position: absolute;
    color: rgba(240, 248, 255, 0.4);
    font-size: 2rem;
    animation: dreamFloat 25s linear infinite;
}

.float-dream:nth-child(1) {
    left: 10%;
    animation-delay: 0s;
}

.float-dream:nth-child(2) {
    left: 30%;
    animation-delay: 6s;
    color: rgba(106, 90, 205, 0.4);
}

.float-dream:nth-child(3) {
    left: 60%;
    animation-delay: 12s;
    color: rgba(147, 112, 219, 0.4);
}

.float-dream:nth-child(4) {
    left: 80%;
    animation-delay: 18s;
}

@keyframes dreamFloat {
    0% {
        transform: translateY(100vh) rotate(0deg) scale(1);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    50% {
        transform: translateY(50vh) rotate(180deg) scale(1.5);
        opacity: 0.7;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(-10vh) rotate(360deg) scale(0.5);
        opacity: 0;
    }
}

/* Responsive Design */
@media (max-width: 1024px) {
    .dream-hall {
        padding: 2rem 1rem;
    }

    .mystical-web {
        padding: 2rem;
    }

    .dream-frame {
        height: 500px;
    }
}

@media (max-width: 768px) {
    .header-clouds {
        flex-direction: column;
        gap: 1rem;
        padding: 0 1rem;
    }

    .ethereal-status {
        gap: 1rem;
    }

    .dream-altar h1 {
        font-size: 2rem;
    }

    .mystical-web {
        padding: 1.5rem 1rem;
    }

    .dream-frame {
        height: 400px;
        margin: 1rem 0;
    }

    .celestial-features {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
    }

    .dream-feature {
        width: 200px;
        text-align: center;
    }

    .footer-visions {
        flex-direction: column;
        gap: 1rem;
    }
}

@media (max-width: 480px) {
    .dream-frame {
        height: 350px;
    }

    .mystical-web {
        padding: 1rem;
    }

    .celestial-decorations {
        font-size: 1.2rem;
    }
}
