/* lrx.st - Corporate Pastoral Design */
/* Colors: #f5f0e6 #b8943e #4a0e1b #2a0810 #8a6b5e #3b2a20 #e8ddd0 #5e7a56 */
/* Fonts: Space Grotesk (display), Cormorant Garamond (body), Inter (UI) */

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background-color: #f5f0e6;
    color: #3b2a20;
    font-family: 'Cormorant Garamond', Georgia, serif;
    line-height: 1.7;
    overflow-x: hidden;
}

/* ========================================
   TYPOGRAPHY
   ======================================== */

.section-title {
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    font-size: clamp(36px, 6vw, 96px);
    letter-spacing: -0.02em;
    color: #4a0e1b;
    margin-bottom: 0.4em;
    line-height: 1.1;
}

.body-prose {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: clamp(18px, 2.2vw, 24px);
    font-weight: 400;
    line-height: 1.75;
    color: #3b2a20;
    max-width: 65ch;
}

.body-prose + .body-prose {
    margin-top: 1.5em;
}

.chapter-number {
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: #8a6b5e;
    display: block;
    margin-bottom: 1em;
}

.chapter-number::before {
    content: 'Chapter ';
}

/* ========================================
   GLOBAL CHAPTER LAYOUT
   ======================================== */

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

/* ========================================
   CHAPTER I: THE RIDGE LINE (HERO)
   ======================================== */

.chapter--ridge {
    background-color: #f5f0e6;
    flex-direction: column;
    padding: 0;
}

.ridge-bg {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 60%;
    z-index: 1;
    pointer-events: none;
}

.mountain-silhouette {
    width: 100%;
    height: 100%;
    display: block;
}

.ridge-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 8vh 2rem 4vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
}

.ridge-edelweiss {
    width: 80px;
    height: 80px;
    margin-bottom: 2rem;
    opacity: 0;
    transform: scale(0.8);
    animation: edelweissAppear 1.8s ease-out 0.3s forwards;
}

.edelweiss-svg {
    width: 100%;
    height: 100%;
}

@keyframes edelweissAppear {
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.ridge-meta {
    font-family: 'Inter', sans-serif;
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: #8a6b5e;
    margin-bottom: 1.5rem;
    opacity: 0;
    animation: fadeUp 1s ease-out 0.6s forwards;
}

.ridge-title {
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    font-size: clamp(64px, 12vw, 180px);
    letter-spacing: -0.03em;
    color: #4a0e1b;
    line-height: 1;
    margin-bottom: 0.3em;
    opacity: 0;
    animation: fadeUp 1.2s ease-out 0.9s forwards;
}

.ridge-title-dot {
    color: #b8943e;
}

.ridge-subtitle {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: clamp(18px, 2.5vw, 28px);
    font-weight: 400;
    font-style: italic;
    color: #8a6b5e;
    line-height: 1.6;
    max-width: 480px;
    opacity: 0;
    animation: fadeUp 1s ease-out 1.2s forwards;
}

.ridge-scroll-indicator {
    position: absolute;
    bottom: 4vh;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    opacity: 0;
    animation: fadeUp 1s ease-out 1.8s forwards;
}

.scroll-text {
    font-family: 'Inter', sans-serif;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: #8a6b5e;
}

.scroll-arrow {
    width: 16px;
    height: 28px;
    animation: scrollBounce 2s ease-in-out infinite;
}

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

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.ridge-diagonal {
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 80px;
    background: linear-gradient(to bottom right, transparent 49.5%, #e8ddd0 50%);
    z-index: 3;
}

/* ========================================
   CHAPTER II: THE MEADOW
   ======================================== */

.chapter--meadow {
    background-color: #e8ddd0;
    padding: 10vh 2rem;
    position: relative;
}

.meadow-fern {
    position: absolute;
    top: 10%;
    width: 60px;
    height: auto;
    z-index: 1;
    opacity: 0.4;
}

.meadow-fern--left {
    left: 2%;
}

.meadow-fern--right {
    right: 2%;
}

.meadow-content {
    position: relative;
    z-index: 2;
    max-width: 1000px;
    margin: 0 auto;
    padding: 4rem 0;
}

.meadow-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 4rem;
    align-items: center;
    margin-top: 2rem;
}

.meadow-illustration {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.meadow-illustration svg {
    width: 240px;
    height: 240px;
    transform: translateX(40px);
}

/* ========================================
   CHAPTER III: THE ARCHIVE
   ======================================== */

.chapter--archive {
    background-color: #f5f0e6;
    flex-direction: column;
    padding: 10vh 2rem 6vh;
}

.archive-content {
    max-width: 1100px;
    margin: 0 auto;
    text-align: center;
}

.archive-intro {
    margin: 0 auto 4rem;
    text-align: center;
}

.archive-specimens {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2.5rem;
    margin-top: 2rem;
}

.specimen-card {
    background: #e8ddd0;
    border: 1px solid rgba(184, 148, 62, 0.2);
    padding: 2.5rem 2rem;
    text-align: center;
    position: relative;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.specimen-card::before {
    content: '';
    position: absolute;
    top: 8px;
    left: 8px;
    right: -4px;
    bottom: -4px;
    border: 1px dashed rgba(138, 107, 94, 0.2);
    pointer-events: none;
}

.specimen-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(42, 8, 16, 0.08);
}

.specimen-illustration {
    width: 100px;
    height: 100px;
    margin: 0 auto 1.5rem;
}

.specimen-illustration svg {
    width: 100%;
    height: 100%;
}

.specimen-name {
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    font-size: 20px;
    letter-spacing: -0.01em;
    color: #4a0e1b;
    margin-bottom: 0.8rem;
}

.specimen-description {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 17px;
    line-height: 1.65;
    color: #3b2a20;
    margin-bottom: 1.2rem;
}

.specimen-latin {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-style: italic;
    font-size: 14px;
    color: #8a6b5e;
    letter-spacing: 0.05em;
}

.archive-border-decoration {
    width: 100%;
    margin-top: 4rem;
}

.archive-border-decoration svg {
    width: 100%;
    height: 40px;
    display: block;
}

/* ========================================
   CHAPTER IV: THE SUMMIT PATH
   ======================================== */

.chapter--summit {
    background-color: #e8ddd0;
    flex-direction: column;
    padding: 10vh 2rem;
    position: relative;
}

.summit-content {
    max-width: 900px;
    margin: 0 auto;
    width: 100%;
}

.summit-intro {
    margin-bottom: 4rem;
}

.summit-path {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.summit-step {
    display: grid;
    grid-template-columns: 80px 1fr;
    gap: 2rem;
    padding: 2.5rem 0;
    border-bottom: 1px solid rgba(184, 148, 62, 0.15);
    position: relative;
}

.summit-step:last-child {
    border-bottom: none;
}

.step-marker {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}

.step-number {
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    font-size: 28px;
    color: #b8943e;
    line-height: 1;
}

.step-line {
    width: 1px;
    flex: 1;
    background: linear-gradient(to bottom, #b8943e, transparent);
    margin-top: 0.8rem;
    min-height: 30px;
}

.step-content {
    padding-top: 0.2rem;
}

.step-title {
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    font-size: clamp(20px, 2.5vw, 28px);
    letter-spacing: -0.01em;
    color: #4a0e1b;
    margin-bottom: 0.6rem;
}

.summit-mountain-accent {
    position: absolute;
    bottom: 2rem;
    right: 2rem;
    width: 300px;
    height: 150px;
    opacity: 0.5;
    pointer-events: none;
}

.summit-mountain-accent svg {
    width: 100%;
    height: 100%;
}

/* ========================================
   CHAPTER V: THE VALLEY (FOOTER)
   ======================================== */

.chapter--valley {
    background-color: #2a0810;
    min-height: 80vh;
    flex-direction: column;
    padding: 10vh 2rem 4vh;
    position: relative;
}

.valley-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.valley-edelweiss {
    width: 60px;
    height: 60px;
    margin: 0 auto 2rem;
}

.valley-edelweiss svg {
    width: 100%;
    height: 100%;
}

.valley-title {
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    font-size: clamp(32px, 5vw, 64px);
    letter-spacing: -0.02em;
    color: #e8ddd0;
    margin-bottom: 1.5rem;
    line-height: 1.1;
}

.valley-text.body-prose {
    color: #8a6b5e;
    margin: 0 auto 2.5rem;
    font-size: clamp(16px, 2vw, 22px);
}

.valley-cta {
    margin-bottom: 4rem;
}

.valley-link {
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: #b8943e;
    text-decoration: none;
    padding: 0.8em 2em;
    border: 1px solid rgba(184, 148, 62, 0.4);
    transition: all 0.4s ease;
    display: inline-block;
}

.valley-link:hover {
    background-color: rgba(184, 148, 62, 0.1);
    border-color: #b8943e;
    color: #e8ddd0;
}

.valley-footer {
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    color: #8a6b5e;
    margin-bottom: 0.8rem;
}

.valley-separator {
    margin: 0 0.6em;
    opacity: 0.5;
}

.valley-domain {
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    color: #e8ddd0;
}

.valley-tagline {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-style: italic;
}

.valley-colophon {
    font-family: 'Inter', sans-serif;
    font-size: 11px;
    color: rgba(138, 107, 94, 0.6);
    letter-spacing: 0.1em;
}

.valley-mountains {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 40%;
    pointer-events: none;
    z-index: 1;
}

.valley-mountains svg {
    width: 100%;
    height: 100%;
    display: block;
}

/* ========================================
   REVEAL ANIMATIONS
   ======================================== */

.reveal-section {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.9s ease-out, transform 0.9s ease-out;
}

.reveal-section.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered card reveals */
.specimen-card {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out, box-shadow 0.4s ease;
}

.specimen-card.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Summit step reveals */
.summit-step {
    opacity: 0;
    transform: translateX(-20px);
    transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

.summit-step.revealed {
    opacity: 1;
    transform: translateX(0);
}

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

@media (max-width: 768px) {
    .meadow-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .meadow-illustration svg {
        transform: none;
        width: 180px;
        height: 180px;
    }

    .archive-specimens {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .summit-step {
        grid-template-columns: 60px 1fr;
        gap: 1rem;
    }

    .meadow-fern {
        display: none;
    }

    .summit-mountain-accent {
        display: none;
    }

    .ridge-edelweiss {
        width: 60px;
        height: 60px;
    }
}

@media (max-width: 480px) {
    .chapter {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .specimen-card {
        padding: 2rem 1.2rem;
    }

    .specimen-card::before {
        display: none;
    }
}