/* ==========================================================================
   quirk.one -- Glassmorphic Meditation Garden
   Colors: #F0E6FF, #2D1B69, #E8A838, #6B4D8A, #FFD666
   Fonts: Cormorant Garamond (display), Inter (body)
   ========================================================================== */

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    font-weight: 400;
    font-size: 1rem;
    line-height: 1.8;
    color: #6B4D8A;
    background: #F0E6FF;
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

/* --- Organic Blob Shapes --- */
.blob {
    position: fixed;
    border-radius: 50% 40% 60% 30%;
    opacity: 0.35;
    filter: blur(60px);
    pointer-events: none;
    z-index: 0;
    will-change: transform, border-radius;
}

.blob-1 {
    width: 500px;
    height: 500px;
    background: linear-gradient(135deg, #E8A838, #FFD666);
    top: -100px;
    left: -100px;
    animation: blobDrift1 25s ease-in-out infinite;
}

.blob-2 {
    width: 400px;
    height: 400px;
    background: linear-gradient(225deg, #6B4D8A, #2D1B69);
    top: 30%;
    right: -80px;
    animation: blobDrift2 30s ease-in-out infinite;
}

.blob-3 {
    width: 350px;
    height: 350px;
    background: linear-gradient(180deg, #FFD666, #E8A838);
    bottom: 20%;
    left: 10%;
    animation: blobDrift3 20s ease-in-out infinite;
}

.blob-4 {
    width: 300px;
    height: 300px;
    background: linear-gradient(90deg, #2D1B69, #6B4D8A);
    top: 60%;
    right: 20%;
    animation: blobDrift4 28s ease-in-out infinite;
}

.blob-5 {
    width: 250px;
    height: 250px;
    background: linear-gradient(315deg, #E8A838, #F0E6FF);
    top: 10%;
    left: 50%;
    animation: blobDrift5 22s ease-in-out infinite;
}

/* Blob drift animations with morphing border-radius */
@keyframes blobDrift1 {
    0%   { transform: translate(0, 0) rotate(0deg); border-radius: 50% 40% 60% 30%; }
    25%  { transform: translate(80px, 60px) rotate(45deg); border-radius: 30% 60% 40% 50%; }
    50%  { transform: translate(40px, 120px) rotate(90deg); border-radius: 60% 30% 50% 40%; }
    75%  { transform: translate(100px, 40px) rotate(135deg); border-radius: 40% 50% 30% 60%; }
    100% { transform: translate(0, 0) rotate(0deg); border-radius: 50% 40% 60% 30%; }
}

@keyframes blobDrift2 {
    0%   { transform: translate(0, 0) rotate(0deg); border-radius: 40% 60% 30% 50%; }
    25%  { transform: translate(-60px, 80px) rotate(-30deg); border-radius: 60% 30% 50% 40%; }
    50%  { transform: translate(-100px, 40px) rotate(-60deg); border-radius: 30% 50% 60% 40%; }
    75%  { transform: translate(-40px, 100px) rotate(-90deg); border-radius: 50% 40% 30% 60%; }
    100% { transform: translate(0, 0) rotate(0deg); border-radius: 40% 60% 30% 50%; }
}

@keyframes blobDrift3 {
    0%   { transform: translate(0, 0) scale(1); border-radius: 60% 30% 50% 40%; }
    33%  { transform: translate(60px, -40px) scale(1.05); border-radius: 40% 50% 30% 60%; }
    66%  { transform: translate(-30px, -80px) scale(0.95); border-radius: 50% 40% 60% 30%; }
    100% { transform: translate(0, 0) scale(1); border-radius: 60% 30% 50% 40%; }
}

@keyframes blobDrift4 {
    0%   { transform: translate(0, 0) rotate(0deg); border-radius: 30% 50% 40% 60%; }
    50%  { transform: translate(-70px, -50px) rotate(60deg); border-radius: 50% 30% 60% 40%; }
    100% { transform: translate(0, 0) rotate(0deg); border-radius: 30% 50% 40% 60%; }
}

@keyframes blobDrift5 {
    0%   { transform: translate(0, 0) scale(1); border-radius: 50% 40% 60% 30%; }
    25%  { transform: translate(-50px, 60px) scale(1.1); border-radius: 30% 60% 40% 50%; }
    50%  { transform: translate(30px, 100px) scale(0.9); border-radius: 60% 30% 50% 40%; }
    75%  { transform: translate(60px, 30px) scale(1.05); border-radius: 40% 50% 30% 60%; }
    100% { transform: translate(0, 0) scale(1); border-radius: 50% 40% 60% 30%; }
}

/* --- Glass Panel Base --- */
.glass-panel {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    padding: 2.5rem;
    position: relative;
    z-index: 1;
    box-shadow: 0 0 40px rgba(232, 168, 56, 0.15);
    transition: transform 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275),
                box-shadow 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.glass-panel:hover {
    transform: translateY(-6px) scale(1.015);
    box-shadow: 0 0 60px rgba(232, 168, 56, 0.25),
                0 20px 40px rgba(45, 27, 105, 0.1);
}

/* --- Typography --- */
.section-heading {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 600;
    font-size: clamp(2rem, 4vw, 3.5rem);
    color: #2D1B69;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.panel-label {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 600;
    font-size: clamp(1.4rem, 2.5vw, 2rem);
    color: #2D1B69;
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

.body-text {
    color: #6B4D8A;
    font-size: 1rem;
    line-height: 1.8;
    font-weight: 400;
}

/* --- Header --- */
.site-header {
    padding: 3rem 4rem 1rem;
    position: relative;
    z-index: 2;
}

.header-panel {
    display: inline-block;
    padding: 1.5rem 3rem;
}

.site-title {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 700;
    font-size: clamp(2.5rem, 5vw, 4rem);
    color: #2D1B69;
    letter-spacing: -0.02em;
}

.site-tagline {
    font-family: 'Inter', sans-serif;
    font-weight: 300;
    font-size: 0.9rem;
    color: #6B4D8A;
    letter-spacing: 0.1em;
    text-transform: lowercase;
    margin-top: 0.25rem;
}

/* --- Magazine Grid Layout --- */
.magazine-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 3rem;
    row-gap: 3rem;
    padding: 2rem 4rem 4rem;
    position: relative;
    z-index: 1;
    max-width: 1400px;
    margin: 0 auto;
}

/* Hero spans full width */
.hero-panel {
    grid-column: 1 / -1;
    text-align: center;
    padding: 4rem 3rem;
}

.hero-panel .body-text {
    max-width: 700px;
    margin: 0 auto;
    font-size: 1.1rem;
}

/* Two-column panels */
.panel-contemplation,
.panel-presence {
    grid-column: span 1;
}

/* Three-column row */
.panel-harmony,
.panel-flow,
.panel-depth {
    grid-column: span 1;
}

/* Force three-column for the trio */
.panel-harmony {
    grid-column: 1 / 2;
}

/* Feature panel spans full width */
.feature-panel {
    grid-column: 1 / -1;
}

/* Bottom two-column */
.panel-practice,
.panel-return {
    grid-column: span 1;
}

/* Three-column override: use subgrid-like approach */
@supports (grid-template-columns: repeat(3, 1fr)) {
    .magazine-grid {
        grid-template-columns: repeat(6, 1fr);
    }

    .hero-panel {
        grid-column: 1 / -1;
    }

    .panel-contemplation {
        grid-column: 1 / 4;
    }

    .panel-presence {
        grid-column: 4 / 7;
    }

    .panel-harmony {
        grid-column: 1 / 3;
    }

    .panel-flow {
        grid-column: 3 / 5;
    }

    .panel-depth {
        grid-column: 5 / 7;
    }

    .feature-panel {
        grid-column: 1 / -1;
    }

    .panel-practice {
        grid-column: 1 / 4;
    }

    .panel-return {
        grid-column: 4 / 7;
    }
}

/* --- Accent Elements --- */
.accent-tag {
    display: inline-block;
    margin-top: 1.5rem;
    padding: 0.4rem 1.2rem;
    font-family: 'Inter', sans-serif;
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: #2D1B69;
    background: rgba(232, 168, 56, 0.2);
    border: 1px solid rgba(232, 168, 56, 0.3);
    border-radius: 100px;
}

.glow-circle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: radial-gradient(circle, #FFD666 0%, rgba(232, 168, 56, 0.3) 60%, transparent 100%);
    margin-bottom: 1.5rem;
    box-shadow: 0 0 30px rgba(232, 168, 56, 0.3);
    animation: glowPulse 4s ease-in-out infinite;
}

@keyframes glowPulse {
    0%, 100% { box-shadow: 0 0 30px rgba(232, 168, 56, 0.3); transform: scale(1); }
    50%      { box-shadow: 0 0 50px rgba(232, 168, 56, 0.5); transform: scale(1.05); }
}

.amber-line {
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #E8A838, #FFD666);
    border-radius: 3px;
    margin-top: 1.5rem;
}

/* --- Feature Columns --- */
.feature-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    margin-top: 1.5rem;
}

.feature-panel .section-heading {
    text-align: center;
}

/* --- Footer --- */
.site-footer {
    padding: 2rem 4rem 3rem;
    text-align: center;
    position: relative;
    z-index: 2;
}

.footer-panel {
    display: inline-block;
    padding: 1rem 2.5rem;
}

.footer-text {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 600;
    font-size: 1.2rem;
    color: #2D1B69;
    letter-spacing: 0.05em;
}

/* --- Responsive --- */
@media (max-width: 900px) {
    .magazine-grid {
        grid-template-columns: 1fr !important;
        padding: 1.5rem;
        gap: 2rem;
    }

    .hero-panel,
    .panel-contemplation,
    .panel-presence,
    .panel-harmony,
    .panel-flow,
    .panel-depth,
    .feature-panel,
    .panel-practice,
    .panel-return {
        grid-column: 1 / -1 !important;
    }

    .site-header,
    .site-footer {
        padding-left: 1.5rem;
        padding-right: 1.5rem;
    }

    .feature-columns {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .blob {
        opacity: 0.2;
    }

    .blob-1 { width: 300px; height: 300px; }
    .blob-2 { width: 250px; height: 250px; }
    .blob-3 { width: 200px; height: 200px; }
    .blob-4 { width: 180px; height: 180px; }
    .blob-5 { width: 150px; height: 150px; }
}

@media (max-width: 600px) {
    .glass-panel {
        padding: 1.5rem;
        border-radius: 14px;
    }

    .site-title {
        font-size: 2rem;
    }

    .hero-panel {
        padding: 2.5rem 1.5rem;
    }
}
