/* sora.quest - Blobitecture / Mysterious Moody */

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

:root {
    --bg: #FDF5F0;
    --lavender: #E8D8EC;
    --mint: #D8ECE0;
    --peach: #F0DCD0;
    --butter: #F0E8C8;
    --text-primary: #4A3848;
    --text-body: #5A4858;
    --label: #9B8898;
    --underline: #C8889C;
    --shadow: rgba(74, 56, 72, 0.08);
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg);
    color: var(--text-body);
    font-family: 'Karla', sans-serif;
    font-weight: 400;
    font-size: 0.9375rem;
    line-height: 1.7;
    overflow-x: hidden;
}

/* Nautilus Background */
.nautilus-bg {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 400px;
    height: 400px;
    pointer-events: none;
    z-index: 0;
}

/* Bubbles */
.bubbles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.bubble {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.6) 0%, rgba(255,255,255,0.1) 50%, transparent 100%);
}

.bubble--lg {
    width: 40px;
    height: 40px;
    animation: bubbleFloat 6s ease-in-out infinite;
}

.bubble--md {
    width: 24px;
    height: 24px;
    animation: bubbleFloat 8s ease-in-out infinite reverse;
}

.bubble--sm {
    width: 14px;
    height: 14px;
}

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

/* Sections */
.threshold,
.descent,
.chamber,
.surface {
    position: relative;
    z-index: 1;
    padding: 40px 24px;
}

.threshold {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chamber {
    display: flex;
    justify-content: center;
    padding: 80px 24px;
}

.surface {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 60px;
    padding: 80px 24px 120px;
}

/* Blob Pods */
.blob-pod {
    border-radius: var(--br, 50%);
    padding: 40px 36px;
    box-shadow: 0 8px 40px var(--shadow);
    position: relative;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.blob-pod.visible {
    opacity: 1;
    transform: translateY(0);
}

.blob-pod--hero {
    width: 400px;
    max-width: 90vw;
    text-align: center;
    transform: translateY(80px);
    animation: blobBreathe1 10s ease-in-out infinite;
}

.blob-pod--hero.visible {
    transform: translateY(0);
}

.blob-pod--large {
    width: 560px;
    max-width: 90vw;
    animation: blobBreathe2 14s ease-in-out infinite;
}

.blob-pod--medium {
    width: 420px;
    max-width: 85vw;
    margin-bottom: 40px;
    animation: blobBreathe3 10s ease-in-out infinite;
}

.blob-pod--small {
    width: 200px;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    margin-bottom: 40px;
    animation: blobBreathe1 12s ease-in-out infinite;
}

.blob-pod--final {
    width: 120px;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Pod Colors */
.blob-pod--lavender { background-color: var(--lavender); }
.blob-pod--mint { background-color: var(--mint); }
.blob-pod--peach { background-color: var(--peach); }
.blob-pod--butter { background-color: var(--butter); }

/* Breathing animations */
@keyframes blobBreathe1 {
    0%, 100% { border-radius: var(--br, 48% 52% 45% 55% / 52% 48% 55% 45%); }
    50% { border-radius: 51% 49% 42% 58% / 49% 51% 58% 42%; }
}

@keyframes blobBreathe2 {
    0%, 100% { border-radius: var(--br, 46% 54% 50% 50% / 54% 46% 50% 50%); }
    33% { border-radius: 49% 51% 47% 53% / 51% 49% 53% 47%; }
    66% { border-radius: 43% 57% 53% 47% / 57% 43% 47% 53%; }
}

@keyframes blobBreathe3 {
    0%, 100% { border-radius: var(--br, 50% 50% 42% 58% / 46% 54% 58% 42%); }
    50% { border-radius: 53% 47% 45% 55% / 43% 57% 55% 45%; }
}

/* Typography */
.pod-heading {
    font-family: 'Barlow Condensed', sans-serif;
    font-weight: 700;
    font-size: clamp(1.5rem, 3vw, 2.75rem);
    color: var(--text-primary);
    text-transform: uppercase;
    letter-spacing: 0.02em;
    margin-bottom: 0.25rem;
}

.pod-heading--hero {
    font-size: clamp(1.75rem, 3.5vw, 2.75rem);
}

.pod-heading--large {
    font-size: clamp(1.5rem, 3vw, 2.25rem);
}

.pod-tagline {
    font-family: 'Karla', sans-serif;
    font-weight: 400;
    font-style: italic;
    font-size: 1rem;
    color: var(--label);
    margin-top: 0.75rem;
}

.pod-text {
    font-family: 'Karla', sans-serif;
    font-weight: 400;
    font-size: 0.9375rem;
    line-height: 1.7;
    color: var(--text-body);
    margin-top: 1rem;
}

.quest-label {
    font-family: 'Barlow Condensed', sans-serif;
    font-weight: 500;
    font-size: 0.6875rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--label);
    display: block;
    margin-bottom: 0.5rem;
}

.pod-kanji {
    font-family: 'Barlow Condensed', sans-serif;
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--text-primary);
    text-align: center;
}

/* Wavy Underline */
.wavy-underline {
    width: 200px;
    height: 10px;
    display: block;
    margin-bottom: 0.5rem;
}

.wavy-underline--sm {
    width: 160px;
}

.underline-path {
    transition: stroke-dashoffset 0.6s ease;
}

.blob-pod.visible .underline-path {
    stroke-dashoffset: 0;
}

/* Collage */
.collage {
    position: relative;
    margin-top: 1rem;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.collage--chamber {
    height: 60px;
}

.collage-el {
    width: 60px;
    height: 60px;
    position: absolute;
}

.collage-el--1 { left: 20%; top: 0; }
.collage-el--2 { right: 20%; top: 10px; }

/* Responsive */
@media (max-width: 768px) {
    .blob-pod--hero { width: 90vw; }
    .blob-pod--large { width: 90vw; }
    .blob-pod--medium { width: 90vw; margin-left: 5% !important; margin-right: 5% !important; }
    .blob-pod--small { width: 160px; height: 160px; margin-left: auto !important; margin-right: auto !important; }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.3s !important;
    }

    .blob-pod {
        opacity: 1;
        transform: none;
    }

    .underline-path {
        stroke-dashoffset: 0;
    }

    .bubble--lg,
    .bubble--md {
        animation: none;
    }
}
