/* ========================================
   moot.ing — Light Academia Horizontal-Scroll
   Design Language: Scholarly Deliberative
   ======================================== */

/* --- CSS Custom Properties --- */
:root {
    --cream-white: #FFFBF5;
    --slate-charcoal: #2B2B2B;
    --warm-taupe: #8B7355;
    --soft-pearl: #D4C5B9;
    --deep-terracotta: #A85A3A;
    --soft-sand: #F5E6D3;
    --warm-blush: #E8D4C8;
    --pale-peach: #E0C8B8;
    --warm-ivory: #FAF7F3;
    --muted-bronze: #9B8B7E;

    --font-headline: 'Crimson Text', Georgia, serif;
    --font-body: 'Source Serif 4', 'Georgia', serif;
    --font-annotation: 'Source Sans 3', 'Helvetica Neue', sans-serif;
    --font-quote: 'EB Garamond', 'Georgia', serif;

    --card-shadow: 0 4px 16px rgba(0, 0, 0, 0.04), 0 1px 4px rgba(0, 0, 0, 0.02);
    --card-border: 1px solid var(--muted-bronze);
}

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    background-color: var(--cream-white);
    color: var(--slate-charcoal);
    font-family: var(--font-body);
    font-weight: 400;
    font-size: clamp(0.95rem, 1.1vw, 1.15rem);
    line-height: 1.7;
    overflow-x: hidden;
}

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

/* --- Floating Mini-Header / Navigation --- */
#mini-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 0.5rem 1.5rem;
    height: 40px;
    background: rgba(255, 251, 245, 0.92);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-bottom: 1px solid rgba(212, 197, 185, 0.4);
    transition: opacity 0.4s ease;
}

#current-section-title {
    font-family: var(--font-headline);
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--slate-charcoal);
    letter-spacing: -0.01em;
    white-space: nowrap;
}

#nav-pills {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    scrollbar-width: none;
}

#nav-pills::-webkit-scrollbar {
    display: none;
}

.nav-pill {
    font-family: var(--font-annotation);
    font-weight: 400;
    font-size: clamp(0.7rem, 0.85vw, 0.8rem);
    letter-spacing: 0.025em;
    color: var(--warm-taupe);
    background: transparent;
    border: 1px solid transparent;
    border-radius: 12px;
    padding: 0.2rem 0.65rem;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.3s ease;
}

.nav-pill:hover {
    color: var(--deep-terracotta);
    border-color: var(--soft-pearl);
}

.nav-pill.active {
    color: var(--deep-terracotta);
    border-color: var(--deep-terracotta);
    font-weight: 600;
}

/* --- Left Margin Indicator Bar --- */
#margin-bar {
    position: fixed;
    left: 0;
    top: 40px;
    width: 8px;
    height: calc(100vh - 40px);
    z-index: 90;
    background: linear-gradient(
        to bottom,
        var(--soft-pearl),
        var(--warm-taupe),
        var(--deep-terracotta)
    );
    opacity: 0.6;
    transition: opacity 0.5s ease;
}

/* --- HERO SECTION --- */
#hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 80px 2rem 4rem;
    overflow: hidden;
}

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

.seal-motif {
    display: flex;
    justify-content: center;
    margin-bottom: 2.5rem;
}

.seal-circle {
    width: 80px;
    height: 80px;
}

.seal-large .seal-circle {
    width: 120px;
    height: 120px;
}

.hero-title {
    font-family: var(--font-headline);
    font-weight: 600;
    font-size: clamp(2.2rem, 5vw, 4rem);
    line-height: 1.2;
    letter-spacing: -0.01em;
    color: var(--slate-charcoal);
    margin-bottom: 1.5rem;
}

.hero-subtitle {
    font-family: var(--font-body);
    font-weight: 400;
    font-size: clamp(1rem, 1.3vw, 1.2rem);
    line-height: 1.7;
    color: var(--warm-taupe);
    max-width: 560px;
    margin: 0 auto 2.5rem;
}

.marble-divider {
    display: flex;
    justify-content: center;
    margin: 2rem 0;
}

.divider-svg {
    width: min(100%, 600px);
    height: 20px;
}

.scroll-hint {
    margin-top: 3rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    opacity: 0.6;
    animation: gentle-bounce 3s ease-in-out infinite;
}

.scroll-hint-text {
    font-family: var(--font-annotation);
    font-weight: 400;
    font-size: 0.75rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--warm-taupe);
}

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

/* --- Watercolor Wash Backgrounds --- */
.watercolor-wash {
    position: absolute;
    pointer-events: none;
    z-index: 0;
    opacity: 0;
    transition: opacity 1.2s ease;
    border-radius: 50%;
    filter: url(#watercolor-blur);
}

.watercolor-wash.visible {
    opacity: 0.12;
}

.wash-hero {
    width: 500px;
    height: 500px;
    top: 10%;
    right: -5%;
    background: radial-gradient(ellipse, var(--soft-sand) 0%, var(--warm-blush) 50%, transparent 80%);
}

.wash-zone-1 {
    width: 400px;
    height: 300px;
    top: 15%;
    left: 5%;
    background: radial-gradient(ellipse, var(--warm-blush) 0%, var(--pale-peach) 50%, transparent 80%);
}

.wash-zone-2 {
    width: 350px;
    height: 350px;
    bottom: 10%;
    right: 10%;
    background: radial-gradient(ellipse, var(--soft-sand) 0%, var(--soft-pearl) 50%, transparent 80%);
}

.wash-zone-3 {
    width: 450px;
    height: 300px;
    top: 20%;
    right: 15%;
    background: radial-gradient(ellipse, var(--pale-peach) 0%, var(--warm-blush) 50%, transparent 80%);
}

.wash-zone-4 {
    width: 380px;
    height: 380px;
    bottom: 15%;
    left: 10%;
    background: radial-gradient(ellipse, var(--warm-blush) 0%, var(--soft-sand) 50%, transparent 80%);
}

/* --- Gradient Transitions Between Zones --- */
.gradient-transition {
    position: relative;
    padding: 75px 0;
    overflow: hidden;
}

.gradient-band {
    width: 100%;
    height: 100%;
    min-height: 50px;
    background: linear-gradient(
        135deg,
        var(--soft-sand) 0%,
        var(--warm-blush) 35%,
        var(--pale-peach) 65%,
        var(--soft-pearl) 100%
    );
    opacity: 0;
    transition: opacity 0.8s ease;
}

.gradient-band.visible {
    opacity: 1;
}

/* --- Horizontal Zone Sections --- */
.horizontal-zone {
    position: relative;
    padding: 2.5rem 0 2rem;
    overflow: hidden;
}

.zone-header {
    position: sticky;
    left: 0;
    padding: 0 2rem 1.5rem;
    z-index: 10;
}

.zone-title {
    font-family: var(--font-headline);
    font-weight: 600;
    font-size: clamp(1.4rem, 3.5vw, 2.25rem);
    letter-spacing: -0.01em;
    color: var(--slate-charcoal);
    margin-bottom: 0.3rem;
}

.zone-annotation {
    font-family: var(--font-annotation);
    font-weight: 400;
    font-size: clamp(0.8rem, 0.95vw, 0.9rem);
    letter-spacing: 0.025em;
    color: var(--warm-taupe);
    font-style: italic;
}

/* --- Horizontal Scroll Container --- */
.horizontal-scroll-container {
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: thin;
    scrollbar-color: var(--soft-pearl) transparent;
    padding: 0 2rem 1rem;
}

.horizontal-scroll-container::-webkit-scrollbar {
    height: 6px;
}

.horizontal-scroll-container::-webkit-scrollbar-track {
    background: transparent;
}

.horizontal-scroll-container::-webkit-scrollbar-thumb {
    background-color: var(--soft-pearl);
    border-radius: 3px;
}

.card-ribbon {
    display: flex;
    gap: clamp(1.5rem, 3vw, 2.5rem);
    padding-bottom: 0.5rem;
}

/* --- Argument Cards --- */
.argument-card {
    min-width: clamp(280px, 35vw, 450px);
    background: var(--cream-white);
    border: var(--card-border);
    border-radius: 4px;
    box-shadow: var(--card-shadow);
    padding: clamp(1.5rem, 2.5vw, 2.5rem);
    position: relative;
    flex-shrink: 0;
    opacity: 0;
    transform: translateX(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.argument-card.card-visible {
    opacity: 1;
    transform: translateX(0);
}

.card-tall {
    min-height: 420px;
    align-self: stretch;
}

.card-medium {
    min-height: 300px;
    align-self: center;
}

.card-short {
    min-height: 180px;
    align-self: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* --- Card Content --- */
.card-bracket {
    font-family: var(--font-headline);
    font-weight: 400;
    font-size: 1.8rem;
    color: var(--warm-taupe);
    line-height: 1;
    opacity: 0.5;
    margin-bottom: 0.5rem;
}

.bracket-close {
    margin-top: 0.5rem;
    margin-bottom: 0;
    text-align: right;
}

.card-heading {
    font-family: var(--font-headline);
    font-weight: 600;
    font-size: clamp(1.1rem, 1.5vw, 1.35rem);
    letter-spacing: -0.01em;
    color: var(--slate-charcoal);
    margin-bottom: 1rem;
}

.card-body {
    font-family: var(--font-body);
    font-weight: 400;
    font-size: clamp(0.95rem, 1.1vw, 1.15rem);
    line-height: 1.7;
    color: var(--slate-charcoal);
    margin-bottom: 1rem;
    text-align: left;
}

.card-body:last-of-type {
    margin-bottom: 0.5rem;
}

.card-metadata {
    display: block;
    font-family: var(--font-annotation);
    font-weight: 600;
    font-size: clamp(0.7rem, 0.85vw, 0.8rem);
    letter-spacing: 0.025em;
    color: var(--warm-taupe);
    margin-top: 1rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--soft-pearl);
}

/* --- Pull Quotes --- */
.pull-quote {
    padding: 1.5rem;
}

.pull-quote p {
    font-family: var(--font-quote);
    font-weight: 400;
    font-style: italic;
    font-size: clamp(1.1rem, 2vw, 1.45rem);
    line-height: 1.6;
    color: var(--deep-terracotta);
    text-align: center;
}

/* --- Horizontal Scroll Indicator --- */
.scroll-indicator {
    padding: 0.75rem 2rem 0;
}

.scroll-indicator-track {
    width: 100%;
    height: 3px;
    background: var(--soft-pearl);
    border-radius: 1.5px;
    position: relative;
    overflow: hidden;
}

.scroll-indicator-thumb {
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 0%;
    background: linear-gradient(to right, var(--warm-taupe), var(--deep-terracotta));
    border-radius: 1.5px;
    transition: width 0.1s ease;
}

/* --- Footer --- */
#site-footer {
    padding: 4rem 2rem;
    text-align: center;
}

.footer-content {
    max-width: 600px;
    margin: 0 auto;
}

.footer-text {
    font-family: var(--font-annotation);
    font-weight: 400;
    font-size: 0.85rem;
    letter-spacing: 0.025em;
    color: var(--warm-taupe);
    margin-top: 1.5rem;
}

/* --- Responsive: Mobile Vertical Stack --- */
@media (max-width: 768px) {
    #mini-header {
        padding: 0.4rem 1rem;
    }

    #nav-pills {
        gap: 0.35rem;
    }

    .nav-pill {
        font-size: 0.7rem;
        padding: 0.15rem 0.5rem;
    }

    #margin-bar {
        width: 4px;
    }

    .horizontal-scroll-container {
        overflow-x: visible;
        padding: 0 1.25rem 1rem;
    }

    .card-ribbon {
        flex-direction: column;
        gap: 1.25rem;
    }

    .argument-card {
        min-width: 100%;
        min-height: auto;
    }

    .card-tall,
    .card-medium,
    .card-short {
        min-height: auto;
    }

    .hero-title {
        font-size: clamp(1.8rem, 7vw, 2.5rem);
    }

    .gradient-transition {
        padding: 40px 0;
    }

    .zone-header {
        padding: 0 1.25rem 1rem;
    }

    .scroll-indicator {
        padding: 0.5rem 1.25rem 0;
    }

    #hero {
        padding: 60px 1.25rem 3rem;
    }

    .seal-circle {
        width: 60px;
        height: 60px;
    }
}

/* --- Marble Vein Pattern (Background Decoration) --- */
.marble-vein-pattern {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
    opacity: 0.03;
    filter: url(#marble-vein);
    background: var(--soft-pearl);
}
