/* =============================================
   PPADDL.com - Immersive Digital Bathhouse
   ============================================= */

/* Custom Properties */
:root {
    --midnight-abyss: #0A1628;
    --bathhouse-blue: #162A50;
    --moonlit-surface: #4A6FA5;
    --carrara-warm: #F0E6D6;
    --amber-bio: #D4A054;
    --thermal-glow: #C4806E;
    --caustic-teal: #3BBFA0;
    --bubble-iridescence: #B8D4E8;
    --vein-grey: #6B7B8D;
    --deep-abyss: #0D0B1A;

    --depth: 0;
    --elastic: cubic-bezier(0.68, -0.55, 0.265, 1.55);

    --font-headline: 'Cormorant Garamond', Georgia, serif;
    --font-body: 'Source Sans 3', 'Source Sans Pro', sans-serif;
    --font-accent: 'Cinzel', serif;
    --font-mono: 'DM Mono', monospace;
}

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

html {
    scroll-behavior: smooth;
}

body {
    background: linear-gradient(180deg, #162A50 0%, #0A1628 40%, #0D0B1A 100%);
    color: var(--carrara-warm);
    font-family: var(--font-body);
    font-size: 18px;
    line-height: 1.75;
    font-weight: 400;
    letter-spacing: 0.01em;
    overflow-x: hidden;
    min-height: 100vh;
}

::selection {
    background: rgba(59, 191, 160, 0.3);
}

/* =============================================
   MARBLE PILASTERS
   ============================================= */

.pilaster {
    position: fixed;
    top: 0;
    bottom: 0;
    width: 40px;
    z-index: 10;
    opacity: 0;
    transition: opacity 1.5s ease;
    pointer-events: none;
}

.pilaster.visible {
    opacity: 1;
}

.pilaster-left {
    left: calc(50% - 400px);
    background:
        linear-gradient(180deg,
            rgba(240, 230, 214, 0.08) 0%,
            rgba(184, 212, 232, 0.05) 20%,
            rgba(107, 123, 141, 0.06) 60%,
            rgba(240, 230, 214, 0.08) 80%
        ),
        radial-gradient(ellipse at 20% 30%, rgba(107, 123, 141, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 60%, rgba(107, 123, 141, 0.04) 0%, transparent 40%),
        radial-gradient(ellipse at 40% 80%, rgba(107, 123, 141, 0.05) 0%, transparent 45%),
        radial-gradient(ellipse at 60% 10%, rgba(107, 123, 141, 0.03) 0%, transparent 35%);
    border-right: 1px solid rgba(240, 230, 214, 0.08);
}

.pilaster-right {
    right: calc(50% - 400px);
    background:
        linear-gradient(180deg,
            rgba(240, 230, 214, 0.08) 0%,
            rgba(184, 212, 232, 0.05) 20%,
            rgba(107, 123, 141, 0.06) 60%,
            rgba(240, 230, 214, 0.08) 80%
        ),
        radial-gradient(ellipse at 80% 30%, rgba(107, 123, 141, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 20% 60%, rgba(107, 123, 141, 0.04) 0%, transparent 40%),
        radial-gradient(ellipse at 60% 80%, rgba(107, 123, 141, 0.05) 0%, transparent 45%),
        radial-gradient(ellipse at 40% 10%, rgba(107, 123, 141, 0.03) 0%, transparent 35%);
    border-left: 1px solid rgba(240, 230, 214, 0.08);
}

/* =============================================
   BUBBLE CONTAINER
   ============================================= */

#bubble-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
    overflow: hidden;
}

.bubble {
    position: absolute;
    border-radius: 50%;
    pointer-events: auto;
    cursor: pointer;
    background: radial-gradient(
        ellipse at 30% 25%,
        rgba(184, 212, 232, 0.6) 0%,
        rgba(184, 212, 232, 0.2) 30%,
        rgba(59, 191, 160, 0.1) 60%,
        transparent 80%
    );
    box-shadow:
        inset 0 -2px 4px rgba(59, 191, 160, 0.1),
        0 0 8px rgba(184, 212, 232, 0.1);
    transition: transform 400ms var(--elastic);
}

.bubble:hover {
    transform: scale(1.15);
}

.bubble.popping {
    animation: bubble-pop 300ms ease-out forwards;
}

@keyframes bubble-pop {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.3); opacity: 0.5; }
    100% { transform: scale(0); opacity: 0; }
}

@keyframes bubble-wobble {
    0% { transform: translateX(0) scaleX(1) scaleY(1); }
    25% { transform: translateX(4px) scaleX(1.03) scaleY(0.97); }
    50% { transform: translateX(-3px) scaleX(0.97) scaleY(1.03); }
    75% { transform: translateX(2px) scaleX(1.02) scaleY(0.98); }
    100% { transform: translateX(0) scaleX(1) scaleY(1); }
}

/* =============================================
   CAUSTIC OVERLAY
   ============================================= */

.caustic-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    pointer-events: none;
    mix-blend-mode: overlay;
    opacity: 0.06;
    background:
        radial-gradient(ellipse 600px 400px at 30% 40%, rgba(59, 191, 160, 0.4) 0%, transparent 70%),
        radial-gradient(ellipse 500px 500px at 70% 60%, rgba(59, 191, 160, 0.3) 0%, transparent 70%),
        radial-gradient(ellipse 400px 300px at 50% 30%, rgba(59, 191, 160, 0.35) 0%, transparent 70%);
    animation: caustic-move 12s ease-in-out infinite alternate;
}

@keyframes caustic-move {
    0% {
        background-position: 0% 0%, 100% 100%, 50% 50%;
    }
    33% {
        background-position: 20% 30%, 80% 70%, 40% 60%;
    }
    66% {
        background-position: 40% 10%, 60% 90%, 30% 40%;
    }
    100% {
        background-position: 10% 50%, 90% 30%, 60% 20%;
    }
}

/* =============================================
   DEPTH INDICATOR (bottom-right floating bubble)
   ============================================= */

.depth-indicator {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 100;
    opacity: 0.6;
    transition: opacity 300ms ease;
}

.depth-indicator:hover {
    opacity: 1;
}

/* =============================================
   MAIN CONTENT COLUMN
   ============================================= */

.content-column {
    position: relative;
    z-index: 5;
    max-width: 720px;
    margin: 0 auto;
    padding: 0 24px;
}

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

.hero-section {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.water-surface {
    position: absolute;
    top: 0;
    left: -50vw;
    right: -50vw;
    height: 100%;
    background:
        linear-gradient(180deg,
            rgba(74, 111, 165, 0.2) 0%,
            rgba(22, 42, 80, 0.4) 40%,
            rgba(10, 22, 40, 0.8) 100%
        );
    z-index: -1;
}

.water-surface::before {
    content: '';
    position: absolute;
    top: 15%;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg,
        transparent 0%,
        rgba(184, 212, 232, 0.3) 20%,
        rgba(184, 212, 232, 0.5) 50%,
        rgba(184, 212, 232, 0.3) 80%,
        transparent 100%
    );
    animation: surface-shimmer 4s ease-in-out infinite;
}

@keyframes surface-shimmer {
    0%, 100% { transform: scaleX(0.95); opacity: 0.5; }
    50% { transform: scaleX(1.05); opacity: 0.8; }
}

.hero-content {
    text-align: center;
    position: relative;
}

.hero-title {
    font-family: var(--font-headline);
    font-weight: 600;
    font-size: clamp(2.8rem, 4vw + 1rem, 5.5rem);
    letter-spacing: 0.08em;
    color: var(--carrara-warm);
    text-shadow:
        0 0 40px rgba(212, 160, 84, 0.2),
        0 0 80px rgba(59, 191, 160, 0.1);
    animation: title-refraction 6s ease-in-out infinite;
}

@keyframes title-refraction {
    0%, 100% { transform: skewX(0deg); }
    25% { transform: skewX(1.5deg); }
    75% { transform: skewX(-1.5deg); }
}

.hero-subtitle {
    font-family: var(--font-accent);
    font-weight: 700;
    font-size: 12px;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--amber-bio);
    margin-top: 24px;
    opacity: 0.7;
}

.scroll-hint {
    position: absolute;
    bottom: 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    animation: hint-pulse 3s ease-in-out infinite;
}

.scroll-hint .depth-label {
    font-family: var(--font-accent);
    font-weight: 700;
    font-size: 11px;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--moonlit-surface);
    opacity: 0.5;
}

.scroll-arrow {
    width: 16px;
    height: 16px;
    border-right: 1.5px solid var(--moonlit-surface);
    border-bottom: 1.5px solid var(--moonlit-surface);
    transform: rotate(45deg);
    opacity: 0.4;
}

@keyframes hint-pulse {
    0%, 100% { transform: translateY(0); opacity: 0.7; }
    50% { transform: translateY(8px); opacity: 1; }
}

/* =============================================
   WATER LEVEL MARKERS
   ============================================= */

.water-level-marker {
    position: relative;
    height: 24px;
    margin: 80px 0;
    overflow: hidden;
}

.water-level-marker::before {
    content: '';
    position: absolute;
    top: 50%;
    left: -20px;
    right: -20px;
    height: 2px;
    background: linear-gradient(90deg,
        transparent,
        rgba(74, 111, 165, 0.3) 20%,
        rgba(184, 212, 232, 0.2) 50%,
        rgba(74, 111, 165, 0.3) 80%,
        transparent
    );
    animation: meniscus 5s ease-in-out infinite;
}

@keyframes meniscus {
    0%, 100% {
        clip-path: polygon(0% 40%, 10% 55%, 20% 45%, 30% 58%, 40% 42%, 50% 55%, 60% 40%, 70% 52%, 80% 44%, 90% 56%, 100% 42%);
    }
    50% {
        clip-path: polygon(0% 55%, 10% 42%, 20% 58%, 30% 44%, 40% 55%, 50% 40%, 60% 54%, 70% 42%, 80% 56%, 90% 44%, 100% 55%);
    }
}

/* =============================================
   GREEK KEY DIVIDER
   ============================================= */

.greek-key-divider {
    height: 20px;
    margin: 60px auto;
    max-width: 400px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='40' height='20' viewBox='0 0 40 20'%3E%3Cpath d='M0 10 L0 0 L10 0 L10 6 L4 6 L4 10 M10 10 L10 14 L16 14 L16 10 M20 10 L20 0 L30 0 L30 6 L24 6 L24 10 M30 10 L30 14 L36 14 L36 10' fill='none' stroke='%234A6FA5' stroke-width='1.5' opacity='0.2'/%3E%3C/svg%3E");
    background-repeat: repeat-x;
    background-position: 0 center;
    animation: greek-scroll 40s linear infinite;
    opacity: 0.6;
}

@keyframes greek-scroll {
    0% { background-position: 0 center; }
    100% { background-position: 400px center; }
}

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

.content-section {
    padding: 40px 0;
    position: relative;
}

/* Depth Markers */
.depth-marker {
    position: relative;
    margin-bottom: 32px;
    padding-left: 8px;
}

.depth-marker span {
    font-family: var(--font-accent);
    font-weight: 700;
    font-size: 12px;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--amber-bio);
    opacity: 0;
    transform: scale(0.8);
    transition: opacity 600ms ease, transform 600ms var(--elastic);
    display: inline-block;
    text-shadow: 0 0 20px rgba(212, 160, 84, 0.15);
}

.depth-marker.visible span {
    opacity: 0.8;
    transform: scale(1);
}

/* Content Cards */
.content-card {
    position: relative;
    background: rgba(22, 42, 80, 0.6);
    backdrop-filter: blur(16px) saturate(1.2);
    -webkit-backdrop-filter: blur(16px) saturate(1.2);
    border: 1px solid rgba(74, 111, 165, 0.15);
    border-radius: 4px;
    padding: 48px 40px;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 600ms ease, transform 600ms var(--elastic);
}

.content-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.content-card h2 {
    font-family: var(--font-headline);
    font-weight: 500;
    font-size: clamp(1.8rem, 2.5vw + 0.5rem, 3rem);
    letter-spacing: 0.02em;
    color: var(--carrara-warm);
    margin-bottom: 28px;
    line-height: 1.2;
}

.content-card p {
    margin-bottom: 20px;
    color: rgba(240, 230, 214, 0.85);
}

.content-card p:last-of-type {
    margin-bottom: 0;
}

/* Acanthus Corner Ornaments */
.acanthus-corner {
    position: absolute;
    width: 24px;
    height: 24px;
    opacity: 0.15;
}

.acanthus-tl {
    top: 8px;
    left: 8px;
    border-top: 2px solid var(--amber-bio);
    border-left: 2px solid var(--amber-bio);
}

.acanthus-tl::after {
    content: '';
    position: absolute;
    top: 4px;
    left: 4px;
    width: 10px;
    height: 10px;
    border-top: 1px solid var(--amber-bio);
    border-left: 1px solid var(--amber-bio);
    opacity: 0.6;
}

.acanthus-tr {
    top: 8px;
    right: 8px;
    border-top: 2px solid var(--amber-bio);
    border-right: 2px solid var(--amber-bio);
}

.acanthus-tr::after {
    content: '';
    position: absolute;
    top: 4px;
    right: 4px;
    width: 10px;
    height: 10px;
    border-top: 1px solid var(--amber-bio);
    border-right: 1px solid var(--amber-bio);
    opacity: 0.6;
}

.acanthus-bl {
    bottom: 8px;
    left: 8px;
    border-bottom: 2px solid var(--amber-bio);
    border-left: 2px solid var(--amber-bio);
}

.acanthus-bl::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 4px;
    width: 10px;
    height: 10px;
    border-bottom: 1px solid var(--amber-bio);
    border-left: 1px solid var(--amber-bio);
    opacity: 0.6;
}

.acanthus-br {
    bottom: 8px;
    right: 8px;
    border-bottom: 2px solid var(--amber-bio);
    border-right: 2px solid var(--amber-bio);
}

.acanthus-br::after {
    content: '';
    position: absolute;
    bottom: 4px;
    right: 4px;
    width: 10px;
    height: 10px;
    border-bottom: 1px solid var(--amber-bio);
    border-right: 1px solid var(--amber-bio);
    opacity: 0.6;
}

/* =============================================
   SECTION-SPECIFIC STYLES
   ============================================= */

/* Shallow sections - lighter atmosphere */
.shallow-section .content-card {
    border-color: rgba(74, 111, 165, 0.2);
}

/* Mid sections - deepest, most caustic active */
.mid-section .content-card {
    border-color: rgba(59, 191, 160, 0.1);
}

/* Floor sections - warmest tones */
.floor-section .content-card {
    border-color: rgba(196, 128, 110, 0.15);
    background: rgba(22, 42, 80, 0.5);
}

.floor-section .content-card h2 {
    color: var(--thermal-glow);
}

.floor-section .depth-marker span {
    color: var(--thermal-glow);
    text-shadow: 0 0 20px rgba(196, 128, 110, 0.2);
}

/* Mosaic tile pattern for floor sections */
.floor-section {
    position: relative;
}

.floor-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: -50vw;
    right: -50vw;
    bottom: 0;
    background-image:
        repeating-conic-gradient(
            #162A50 0% 25%,
            #0A1628 25% 50%
        );
    background-size: 8px 8px;
    opacity: 0.04;
    z-index: -1;
    pointer-events: none;
}

/* Data callout / mono text */
.data-callout {
    background: rgba(10, 22, 40, 0.5);
    border: 1px solid rgba(59, 191, 160, 0.15);
    border-radius: 3px;
    padding: 16px 20px;
    margin: 24px 0;
}

.mono-text {
    font-family: var(--font-mono);
    font-size: 14px;
    font-weight: 400;
    color: var(--caustic-teal);
    letter-spacing: 0;
    line-height: 1.6;
}

/* Terminal inscription */
.terminal-inscription {
    text-align: center;
    font-family: var(--font-headline);
    font-weight: 500;
    font-style: italic;
    font-size: 1.4rem;
    color: var(--thermal-glow);
    letter-spacing: 0.05em;
    margin-top: 40px;
    opacity: 0.7;
}

/* =============================================
   LINK STYLES
   ============================================= */

a {
    color: var(--carrara-warm);
    text-decoration: none;
    position: relative;
    transition: color 300ms var(--elastic);
}

a:hover {
    color: var(--caustic-teal);
}

a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--caustic-teal);
    transition: width 300ms var(--elastic);
}

a:hover::after {
    width: 100%;
}

/* =============================================
   BIOLUMINESCENT GLOW EFFECTS
   ============================================= */

.depth-marker span {
    box-shadow: 0 0 20px rgba(212, 160, 84, 0.15);
}

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

@media (max-width: 840px) {
    .pilaster {
        display: none;
    }

    .content-column {
        max-width: 100%;
        padding: 0 20px;
    }

    .content-card {
        padding: 32px 24px;
    }
}

@media (max-width: 480px) {
    body {
        font-size: 16px;
    }

    .content-card {
        padding: 24px 18px;
    }

    .hero-title {
        letter-spacing: 0.04em;
    }

    .content-section {
        padding: 24px 0;
    }

    .water-level-marker {
        margin: 48px 0;
    }

    .greek-key-divider {
        margin: 40px auto;
    }
}

/* =============================================
   ANIMATION STAGGERING
   ============================================= */

.content-card.visible:nth-child(2) {
    transition-delay: 100ms;
}

.content-card.visible:nth-child(3) {
    transition-delay: 200ms;
}

/* =============================================
   BACKGROUND DEPTH TRANSITION
   ============================================= */

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, #162A50 0%, #0A1628 40%, #0D0B1A 100%);
    z-index: 0;
    pointer-events: none;
    transition: opacity 500ms ease;
}
