/* ============================================
   concepts.news - Blobitecture Design System
   Cool-grays palette with watercolor washes
   ============================================ */

/* --- CSS Variables --- */
:root {
    --bg-base: #F4F5F7;
    --bg-alt: #E8EBF0;
    --text-primary: #2D3142;
    --text-secondary: #6B7394;
    --wash-periwinkle: #C5CAE9;
    --wash-lavender: #D1C4E9;
    --wash-cerulean: #B3D4E8;
    --wash-sage: #C8D5D0;
    --accent-coral: #E8A598;
    --interactive-teal: #7AADBA;
    --blob-shadow: rgba(45, 49, 66, 0.06);
    --blob-surface: #FFFFFF;
}

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

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: 'Source Sans 3', 'Source Sans Pro', sans-serif;
    font-weight: 400;
    font-size: 1.1rem;
    line-height: 1.7;
    color: var(--text-primary);
    background-color: var(--bg-base);
    overflow-x: hidden;
}

/* --- SVG Filters (hidden) --- */
.svg-filters {
    position: absolute;
    width: 0;
    height: 0;
    overflow: hidden;
}

/* --- Floating Pill Navigation --- */
#pill-nav {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    display: flex;
    gap: 0.5rem;
    padding: 0.6rem 1.5rem;
    background: rgba(255, 255, 255, 0.78);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 9999px;
    box-shadow: 0 4px 40px rgba(45, 49, 66, 0.08);
    animation: nav-bob 4s ease-in-out infinite;
}

@keyframes nav-bob {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(-3px); }
}

.nav-link {
    font-family: 'Source Sans 3', sans-serif;
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-decoration: none;
    padding: 0.3rem 0.7rem;
    border-radius: 9999px;
    transition: color 0.3s ease, transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1), background-color 0.3s ease;
    display: inline-block;
    letter-spacing: 0.01em;
}

.nav-link:hover {
    color: var(--text-primary);
    transform: scale(1.08);
}

.nav-link.active {
    color: var(--interactive-teal);
    background: rgba(122, 173, 186, 0.12);
}

/* --- Decorative Bubble Layer --- */
#bubble-layer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 5;
    overflow: hidden;
}

.bubble {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    will-change: transform;
    transition: transform 0.4s ease-out;
}

.bubble:nth-child(1) {
    background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.3), rgba(197, 202, 233, 0.1));
    animation: bubble-float-1 8s ease-in-out infinite;
}
.bubble:nth-child(2) {
    background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.3), rgba(209, 196, 233, 0.1));
    animation: bubble-float-2 7s ease-in-out infinite 0.5s;
}
.bubble:nth-child(3) {
    background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.3), rgba(179, 212, 232, 0.1));
    animation: bubble-float-1 9s ease-in-out infinite 1s;
}
.bubble:nth-child(4) {
    background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.3), rgba(200, 213, 208, 0.1));
    animation: bubble-float-2 6.5s ease-in-out infinite 1.5s;
}
.bubble:nth-child(5) {
    background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.3), rgba(197, 202, 233, 0.1));
    animation: bubble-float-1 10s ease-in-out infinite 0.8s;
}
.bubble:nth-child(6) {
    background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.3), rgba(232, 165, 152, 0.1));
    animation: bubble-float-2 8.5s ease-in-out infinite 2s;
}
.bubble:nth-child(7) {
    background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.3), rgba(209, 196, 233, 0.1));
    animation: bubble-float-1 7.5s ease-in-out infinite 0.3s;
}
.bubble:nth-child(8) {
    background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.3), rgba(179, 212, 232, 0.1));
    animation: bubble-float-2 9.5s ease-in-out infinite 1.2s;
}
.bubble:nth-child(9) {
    background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.3), rgba(200, 213, 208, 0.1));
    animation: bubble-float-1 6s ease-in-out infinite 0.7s;
}
.bubble:nth-child(10) {
    background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.3), rgba(197, 202, 233, 0.1));
    animation: bubble-float-2 8s ease-in-out infinite 1.8s;
}
.bubble:nth-child(11) {
    background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.3), rgba(232, 165, 152, 0.1));
    animation: bubble-float-1 7s ease-in-out infinite 2.5s;
}
.bubble:nth-child(12) {
    background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.3), rgba(179, 212, 232, 0.1));
    animation: bubble-float-2 10s ease-in-out infinite 0.2s;
}

@keyframes bubble-float-1 {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-15px) scale(1.02); }
}

@keyframes bubble-float-2 {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(12px) scale(0.98); }
}

/* --- Concept Pod Sections --- */
.concept-pod {
    position: relative;
    min-height: 100vh;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* --- Watercolor Background Layers --- */
.watercolor-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    opacity: 0.85;
}

.pod-wash-1 .watercolor-bg {
    background:
        radial-gradient(ellipse 90% 80% at 25% 30%, rgba(197, 202, 233, 0.14) 0%, transparent 70%),
        radial-gradient(ellipse 110% 100% at 80% 60%, rgba(179, 212, 232, 0.12) 0%, transparent 65%),
        radial-gradient(ellipse 80% 90% at 50% 80%, rgba(209, 196, 233, 0.1) 0%, transparent 60%),
        radial-gradient(ellipse 120% 110% at 10% 10%, rgba(200, 213, 208, 0.08) 0%, transparent 55%),
        linear-gradient(180deg, var(--bg-base) 0%, var(--bg-alt) 100%);
}

.pod-wash-2 .watercolor-bg {
    background:
        radial-gradient(ellipse 100% 90% at 70% 20%, rgba(209, 196, 233, 0.15) 0%, transparent 65%),
        radial-gradient(ellipse 85% 110% at 20% 70%, rgba(197, 202, 233, 0.12) 0%, transparent 70%),
        radial-gradient(ellipse 95% 85% at 55% 45%, rgba(200, 213, 208, 0.1) 0%, transparent 60%),
        radial-gradient(ellipse 110% 100% at 90% 90%, rgba(179, 212, 232, 0.08) 0%, transparent 55%),
        linear-gradient(180deg, var(--bg-alt) 0%, var(--bg-base) 100%);
}

.pod-wash-3 .watercolor-bg {
    background:
        radial-gradient(ellipse 95% 100% at 35% 25%, rgba(179, 212, 232, 0.15) 0%, transparent 65%),
        radial-gradient(ellipse 100% 85% at 75% 65%, rgba(200, 213, 208, 0.13) 0%, transparent 70%),
        radial-gradient(ellipse 80% 95% at 15% 80%, rgba(209, 196, 233, 0.1) 0%, transparent 60%),
        radial-gradient(ellipse 115% 90% at 60% 10%, rgba(197, 202, 233, 0.08) 0%, transparent 55%),
        linear-gradient(180deg, var(--bg-base) 0%, var(--bg-alt) 100%);
}

.pod-wash-4 .watercolor-bg {
    background:
        radial-gradient(ellipse 105% 95% at 45% 40%, rgba(200, 213, 208, 0.14) 0%, transparent 65%),
        radial-gradient(ellipse 90% 105% at 80% 20%, rgba(197, 202, 233, 0.12) 0%, transparent 70%),
        radial-gradient(ellipse 85% 80% at 25% 75%, rgba(179, 212, 232, 0.11) 0%, transparent 60%),
        radial-gradient(ellipse 110% 100% at 60% 90%, rgba(232, 165, 152, 0.06) 0%, transparent 55%),
        linear-gradient(180deg, var(--bg-alt) 0%, var(--bg-base) 100%);
}

.pod-wash-5 .watercolor-bg {
    background:
        radial-gradient(ellipse 100% 90% at 60% 30%, rgba(209, 196, 233, 0.14) 0%, transparent 65%),
        radial-gradient(ellipse 90% 100% at 15% 55%, rgba(179, 212, 232, 0.13) 0%, transparent 70%),
        radial-gradient(ellipse 80% 85% at 85% 80%, rgba(200, 213, 208, 0.1) 0%, transparent 60%),
        radial-gradient(ellipse 115% 95% at 40% 10%, rgba(197, 202, 233, 0.08) 0%, transparent 55%),
        linear-gradient(180deg, var(--bg-base) 0%, var(--bg-alt) 100%);
}

.pod-wash-6 .watercolor-bg {
    background:
        radial-gradient(ellipse 95% 105% at 75% 35%, rgba(179, 212, 232, 0.15) 0%, transparent 65%),
        radial-gradient(ellipse 105% 90% at 30% 70%, rgba(209, 196, 233, 0.12) 0%, transparent 70%),
        radial-gradient(ellipse 85% 95% at 55% 15%, rgba(232, 165, 152, 0.08) 0%, transparent 60%),
        radial-gradient(ellipse 110% 85% at 10% 50%, rgba(200, 213, 208, 0.1) 0%, transparent 55%),
        linear-gradient(180deg, var(--bg-alt) 0%, var(--bg-base) 100%);
}

.pod-wash-7 .watercolor-bg {
    background:
        radial-gradient(ellipse 100% 100% at 50% 50%, rgba(197, 202, 233, 0.13) 0%, transparent 65%),
        radial-gradient(ellipse 90% 90% at 20% 30%, rgba(200, 213, 208, 0.12) 0%, transparent 70%),
        radial-gradient(ellipse 85% 85% at 80% 70%, rgba(179, 212, 232, 0.1) 0%, transparent 60%),
        radial-gradient(ellipse 110% 95% at 50% 90%, rgba(209, 196, 233, 0.08) 0%, transparent 55%),
        linear-gradient(180deg, var(--bg-base) 0%, var(--bg-alt) 100%);
}

/* --- Paper grain overlay on sections --- */
.concept-pod::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    opacity: 0.04;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='4'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)' opacity='0.5'/%3E%3C/svg%3E");
    background-repeat: repeat;
    pointer-events: none;
}

/* --- Blob Containers --- */
.blob-container {
    position: relative;
    z-index: 10;
    background: rgba(255, 255, 255, 0.78);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 12px 60px rgba(45, 49, 66, 0.06);
    padding: 3rem;
    max-width: 800px;
    width: 65%;
    opacity: 0.9;
    transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.5s ease;
    will-change: transform;
}

.blob-container:hover {
    transform: scale(1.015);
}

.blob-container.in-view {
    opacity: 1;
}

/* Blob shape variations */
.blob-shape-1 { border-radius: 42% 58% 55% 45% / 50% 42% 58% 50%; }
.blob-shape-2 { border-radius: 55% 45% 40% 60% / 45% 55% 45% 55%; }
.blob-shape-3 { border-radius: 45% 55% 60% 40% / 55% 45% 55% 45%; }
.blob-shape-4 { border-radius: 50% 50% 45% 55% / 40% 60% 40% 60%; }
.blob-shape-5 { border-radius: 60% 40% 50% 50% / 50% 50% 60% 40%; }
.blob-shape-6 { border-radius: 40% 60% 55% 45% / 55% 45% 50% 50%; }
.blob-shape-7 { border-radius: 48% 52% 50% 50% / 52% 48% 52% 48%; }

/* Blob positioning - alternating left, right, center */
.blob-center {
    margin-left: auto;
    margin-right: auto;
}

.blob-left {
    margin-left: 8%;
    margin-right: auto;
}

.blob-right {
    margin-left: auto;
    margin-right: 8%;
}

/* --- Blob Content (scroll reveal targets) --- */
.blob-content {
    position: relative;
    z-index: 2;
}

.blob-content > * {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.blob-content.revealed > *:nth-child(1) { opacity: 1; transform: translateY(0); transition-delay: 0s; }
.blob-content.revealed > *:nth-child(2) { opacity: 1; transform: translateY(0); transition-delay: 0.1s; }
.blob-content.revealed > *:nth-child(3) { opacity: 1; transform: translateY(0); transition-delay: 0.2s; }
.blob-content.revealed > *:nth-child(4) { opacity: 1; transform: translateY(0); transition-delay: 0.3s; }
.blob-content.revealed > *:nth-child(5) { opacity: 1; transform: translateY(0); transition-delay: 0.4s; }
.blob-content.revealed > *:nth-child(6) { opacity: 1; transform: translateY(0); transition-delay: 0.5s; }

/* --- Typography --- */
h1 {
    font-family: 'Source Sans 3', sans-serif;
    font-weight: 700;
    font-size: 4.5rem;
    letter-spacing: -0.02em;
    line-height: 1.1;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
}

.section-heading {
    font-family: 'Nunito', sans-serif;
    font-weight: 600;
    font-size: 2.2rem;
    letter-spacing: 0.01em;
    line-height: 1.25;
    color: var(--text-primary);
    margin-bottom: 1.2rem;
}

.body-text {
    font-family: 'Source Sans 3', sans-serif;
    font-weight: 400;
    font-size: 1.1rem;
    line-height: 1.7;
    color: var(--text-primary);
    max-width: 38em;
    margin-bottom: 1rem;
}

.editorial-statement {
    font-family: 'Source Sans 3', sans-serif;
    font-weight: 400;
    font-size: 1.25rem;
    line-height: 1.7;
    color: var(--text-secondary);
    max-width: 38em;
    margin-bottom: 1.5rem;
}

.caveat-note {
    font-family: 'Caveat', cursive;
    font-weight: 400;
    font-size: 1.5rem;
    color: var(--accent-coral);
    display: inline-block;
    margin-top: 0.8rem;
    transform-origin: left center;
}

.caveat-note.revealed-note {
    animation: caveat-appear 0.6s ease-out forwards;
}

@keyframes caveat-appear {
    0% { opacity: 0; transform: rotate(2deg) scale(0.95); }
    100% { opacity: 1; transform: rotate(0deg) scale(1); }
}

/* --- Heading Watercolor Reveal --- */
.heading-reveal {
    background-size: 200% 100%;
    background-position: 100% 0;
    -webkit-background-clip: text;
    background-clip: text;
    transition: background-position 1.2s ease-out;
}

.heading-reveal.paint-in {
    background-image: linear-gradient(90deg,
        var(--text-primary) 0%,
        var(--text-primary) 50%,
        transparent 50%,
        transparent 100%
    );
    background-size: 200% 100%;
    background-position: 0% 0;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

h1.heading-reveal.paint-in {
    background-image: linear-gradient(90deg,
        var(--text-primary) 0%,
        var(--text-primary) 50%,
        rgba(45, 49, 66, 0.15) 50%,
        rgba(45, 49, 66, 0.15) 100%
    );
    background-size: 200% 100%;
    background-position: 0% 0;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

/* --- Concept Icons --- */
.concept-icon {
    width: 56px;
    height: 56px;
    margin-bottom: 1rem;
    transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.concept-icon svg {
    width: 100%;
    height: 100%;
    transition: stroke 0.5s ease;
}

.concept-icon:hover {
    transform: scale(1.15);
}

.concept-icon:hover svg {
    stroke: var(--accent-coral);
}

/* --- Blob Dividers --- */
.blob-divider {
    position: relative;
    z-index: 10;
    width: 100%;
    height: 60px;
    margin: -30px 0;
    overflow: hidden;
}

.blob-divider svg {
    width: 100%;
    height: 100%;
}

/* --- Closing Bubbles --- */
.closing-bubbles {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
    justify-content: center;
}

.mini-bubble {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.5), rgba(122, 173, 186, 0.3));
    animation: mini-bob 3s ease-in-out infinite;
}

.mini-bubble:nth-child(2) {
    width: 22px;
    height: 22px;
    animation-delay: 0.5s;
    background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.5), rgba(197, 202, 233, 0.3));
}

.mini-bubble:nth-child(3) {
    width: 14px;
    height: 14px;
    animation-delay: 1s;
    background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.5), rgba(232, 165, 152, 0.3));
}

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

/* --- Breakpoints --- */
@media (min-width: 1200px) {
    .blob-container {
        width: 65%;
        padding: 5rem;
    }

    h1 {
        font-size: 5rem;
    }

    .section-heading {
        font-size: 2.5rem;
    }
}

@media (max-width: 1199px) and (min-width: 768px) {
    .blob-container {
        width: 85%;
    }

    .blob-left,
    .blob-right {
        margin-left: 5%;
        margin-right: 5%;
    }

    h1 {
        font-size: 3.8rem;
    }
}

@media (max-width: 767px) {
    .blob-container {
        width: 92%;
        padding: 2rem;
        margin-left: 4% !important;
        margin-right: 4% !important;
    }

    .concept-pod {
        min-height: auto;
        padding: 6vh 0;
    }

    h1 {
        font-size: 2.8rem;
    }

    .section-heading {
        font-size: 1.8rem;
    }

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

    .editorial-statement {
        font-size: 1.1rem;
    }

    #pill-nav {
        padding: 0.4rem 0.8rem;
        gap: 0.2rem;
    }

    .nav-link {
        font-size: 0.72rem;
        padding: 0.25rem 0.4rem;
    }

    .blob-divider {
        height: 40px;
        margin: -20px 0;
    }
}
