/* ==========================================
   MAGIC MUSE - LIQUID GLASS DESIGN SYSTEM
   Aether Philosophy Implementation
   ========================================== */

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

:root {
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.15);
    --glass-highlight: rgba(255, 255, 255, 0.25);
    --glass-shadow: rgba(0, 0, 0, 0.3);
    --primary-glow: #00f3ff;
    --secondary-glow: #bf00ff;
    --accent-glow: #ff0080;
    --radius-lg: 1rem;
    --radius-full: 9999px;
    --timing-smooth: cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: linear-gradient(135deg, #0a0e27 0%, #1a0b2e 50%, #16213e 100%);
    color: #ffffff;
    overflow-x: hidden;
    line-height: 1.6;
    min-height: 100vh;
}

/* ========== GLASS COMPONENTS ========== */

.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(20px) saturate(180%) brightness(120%);
    -webkit-backdrop-filter: blur(20px) saturate(180%) brightness(120%);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    box-shadow: 0 8px 32px var(--glass-shadow), inset 0 1px 0 rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
    transition: all 0.4s var(--timing-smooth);
}

.glass-card:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--glass-highlight);
    box-shadow: 0 12px 48px rgba(0, 243, 255, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

.glass-input, .glass-select {
    width: 100%;
    padding: 1rem 1.5rem;
    background: var(--glass-bg);
    backdrop-filter: blur(10px) saturate(150%);
    -webkit-backdrop-filter: blur(10px) saturate(150%);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    color: #ffffff;
    font-size: 1rem;
    transition: all 0.3s var(--timing-smooth);
    outline: none;
}

.glass-input:focus, .glass-select:focus {
    border-color: var(--primary-glow);
    box-shadow: 0 0 0 3px rgba(0, 243, 255, 0.1), inset 0 0 20px rgba(0, 243, 255, 0.05);
}

.glass-input::placeholder { color: rgba(255, 255, 255, 0.5); }

.glass-slider {
    width: 100%;
    height: 6px;
    background: var(--glass-bg);
    border-radius: var(--radius-full);
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
}

.glass-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    background: var(--primary-glow);
    border-radius: var(--radius-full);
    cursor: pointer;
    box-shadow: 0 0 10px var(--primary-glow);
    transition: all 0.3s var(--timing-smooth);
}

.glass-slider::-webkit-slider-thumb:hover {
    transform: scale(1.2);
    box-shadow: 0 0 20px var(--primary-glow);
}

.glass-slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    background: var(--primary-glow);
    border-radius: var(--radius-full);
    border: none;
    cursor: pointer;
    box-shadow: 0 0 10px var(--primary-glow);
}

/* ========== NAVIGATION ========== */

.glass-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(10, 14, 39, 0.7);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid var(--glass-border);
    padding: 1rem 0;
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 700;
    cursor: pointer;
}

.logo-icon {
    font-size: 2rem;
    animation: float 3s ease-in-out infinite;
}

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

.nav-links {
    display: flex;
    gap: 0.5rem;
    list-style: none;
}

.nav-link {
    padding: 0.75rem 1.5rem;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    border-radius: var(--radius-lg);
    transition: all 0.3s var(--timing-smooth);
    position: relative;
    cursor: pointer;
}

.nav-link:hover, .nav-link.active {
    color: #ffffff;
    background: var(--glass-bg);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: 0.5rem;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 4px;
    background: var(--primary-glow);
    border-radius: var(--radius-full);
    box-shadow: 0 0 10px var(--primary-glow);
}

/* ========== SECTIONS ========== */

.section {
    min-height: 100vh;
    padding: 6rem 2rem;
    display: none;
    position: relative;
    opacity: 0;
    transition: opacity 0.5s var(--timing-smooth);
}

.section.active {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 1;
}

/* ========== HERO SECTION ========== */

.hero-section { position: relative; overflow: hidden; }

.particles-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 900px;
}

.hero-title { margin-bottom: 1.5rem; }

.title-line {
    display: block;
    font-size: 1.5rem;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.6);
    letter-spacing: 0.3em;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
    animation: fadeInUp 0.8s var(--timing-smooth);
}

.title-main {
    display: block;
    font-size: 5rem;
    font-weight: 800;
    background: linear-gradient(135deg, #00f3ff 0%, #bf00ff 50%, #ff0080 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: fadeInUp 0.8s var(--timing-smooth) 0.2s backwards;
}

.hero-subtitle {
    font-size: 1.5rem;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 3rem;
    animation: fadeInUp 0.8s var(--timing-smooth) 0.4s backwards;
}

.hero-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    animation: fadeInUp 0.8s var(--timing-smooth) 0.6s backwards;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ========== BUTTONS ========== */

.btn-primary, .btn-secondary {
    padding: 1.25rem 2.5rem;
    font-size: 1.1rem;
    font-weight: 600;
    border: none;
    border-radius: var(--radius-lg);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    transition: all 0.3s var(--timing-smooth);
    position: relative;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-glow), var(--secondary-glow));
    color: #ffffff;
    box-shadow: 0 8px 24px rgba(0, 243, 255, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(0, 243, 255, 0.5);
}

.btn-secondary {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    color: #ffffff;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--glass-highlight);
    transform: translateY(-2px);
}

.btn-icon { transition: transform 0.3s var(--timing-smooth); }
.btn-primary:hover .btn-icon, .btn-secondary:hover .btn-icon { transform: translateX(4px); }

.scroll-indicator {
    position: absolute;
    bottom: 3rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
}

.scroll-arrow { animation: bounce 2s infinite; }

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

/* ========== SECTION HEADERS ========== */

.section-header { text-align: center; margin-bottom: 4rem; }

.section-title {
    font-size: 3.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-glow), var(--secondary-glow));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
}

.section-subtitle { font-size: 1.25rem; color: rgba(255, 255, 255, 0.6); }

/* ========== POETRY GARDEN ========== */

.poetry-section { padding-top: 8rem; }

.poetry-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    max-width: 1400px;
    width: 100%;
}

.poetry-card { padding: 2.5rem; position: relative; }

.card-glow {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, var(--primary-glow) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.5s var(--timing-smooth);
    pointer-events: none;
}

.poetry-card:hover .card-glow { opacity: 0.1; }

.poetry-title {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--primary-glow);
}

.poetry-content { margin-bottom: 2rem; line-height: 1.8; }
.poetry-content p { margin-bottom: 0.5rem; color: rgba(255, 255, 255, 0.9); }
.poetry-meta { display: flex; gap: 0.75rem; flex-wrap: wrap; }

.poetry-tag {
    padding: 0.5rem 1rem;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-full);
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.7);
}

/* ========== SPELL FORGE ========== */

.spell-section { padding-top: 8rem; }

.spell-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    max-width: 1400px;
    width: 100%;
}

.spell-forge, .spell-output { padding: 3rem; }
.forge-input-group { margin-bottom: 2rem; }

.forge-input-group label {
    display: block;
    margin-bottom: 0.75rem;
    font-weight: 600;
    color: var(--primary-glow);
}

.forge-btn { width: 100%; justify-content: center; margin-top: 1rem; }

.spell-output {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 400px;
}

.output-placeholder {
    text-align: center;
    color: rgba(255, 255, 255, 0.4);
}

.placeholder-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.3;
}

.spell-result {
    padding: 2rem;
    text-align: center;
    width: 100%;
    animation: fadeInUp 0.6s var(--timing-smooth);
}

.spell-incantation {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--primary-glow);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.spell-description {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.8;
}

/* ========== WORLDBUILDING ========== */

.world-section { padding-top: 8rem; }

.world-generator {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 2rem;
    max-width: 1400px;
    width: 100%;
}

.generator-controls { padding: 3rem; }

.generator-controls h3 {
    font-size: 1.75rem;
    margin-bottom: 2rem;
    color: var(--primary-glow);
}

.control-group { margin-bottom: 2.5rem; }

.control-group label {
    display: block;
    margin-bottom: 1rem;
    font-weight: 600;
    color: var(--primary-glow);
}

.slider-container { margin-top: 1rem; }

.slider-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 0.75rem;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.5);
}

.world-output {
    padding: 3rem;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.world-result {
    width: 100%;
    animation: fadeInUp 0.6s var(--timing-smooth);
}

.world-result h3 {
    font-size: 2rem;
    color: var(--primary-glow);
    margin-bottom: 1.5rem;
}

.world-result p {
    margin-bottom: 1.5rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.8;
}

.world-features {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin-top: 2rem;
}

.world-feature {
    padding: 1.5rem;
    background: rgba(0, 243, 255, 0.05);
    border-radius: var(--radius-lg);
    border: 1px solid rgba(0, 243, 255, 0.2);
}

.world-feature h4 {
    color: var(--primary-glow);
    margin-bottom: 0.5rem;
}

.world-feature p {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
    margin: 0;
}

/* ========== ABOUT SECTION ========== */

.about-section { padding-top: 8rem; }
.about-content { max-width: 900px; padding: 4rem; }
.about-text { line-height: 1.8; }

.about-intro {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    color: rgba(255, 255, 255, 0.9);
}

.about-text p {
    margin-bottom: 1.5rem;
    color: rgba(255, 255, 255, 0.7);
}

.about-features {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin: 3rem 0;
}

.feature-item { text-align: center; }

.feature-icon {
    font-size: 3rem;
    display: block;
    margin-bottom: 1rem;
}

.feature-item h4 {
    color: var(--primary-glow);
    margin-bottom: 0.75rem;
}

.feature-item p {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.6);
}

.about-footer {
    font-style: italic;
    color: rgba(255, 255, 255, 0.5);
}

/* ========== FOOTER ========== */

.glass-footer {
    background: rgba(10, 14, 39, 0.7);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid var(--glass-border);
    padding: 3rem 2rem;
    margin-top: 4rem;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    text-align: center;
}

.footer-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.footer-tagline {
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 2rem;
}

.footer-links {
    display: flex;
    gap: 2rem;
    justify-content: center;
    margin-bottom: 2rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover { color: var(--primary-glow); }

.footer-copyright {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.4);
}

/* ========== RESPONSIVE DESIGN ========== */

@media (max-width: 1024px) {
    .spell-container, .world-generator {
        grid-template-columns: 1fr;
    }
    
    .world-features {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .title-main { font-size: 3rem; }
    .section-title { font-size: 2.5rem; }
    
    .hero-buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .btn-primary, .btn-secondary {
        width: 100%;
        justify-content: center;
    }
    
    .about-features {
        grid-template-columns: 1fr;
    }
    
    .nav-links {
        gap: 0.25rem;
    }
    
    .nav-link {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
    
    .poetry-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .title-main { font-size: 2rem; }
    .nav-container { padding: 0 1rem; }
    .section { padding: 4rem 1rem; }
}
