/* infra.limited — Pastoral-Romantic Infrastructure */

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

:root {
    --aged-linen: #f4ece1;
    --wheat-field: #e8d5b7;
    --burnt-umber: #3d2b1a;
    --terracotta: #c2785c;
    --sage-mist: #8a9e7f;
    --loam: #5c4033;
    --honeyed-gold: #d4a857;
    --haze-lilac: #c5b8cc;
    --ease-organic: cubic-bezier(0.23, 1, 0.32, 1);
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--aged-linen);
    color: var(--burnt-umber);
    font-family: 'Source Serif 4', serif;
    font-size: clamp(1rem, 1.2vw, 1.2rem);
    line-height: 1.7;
    overflow-x: hidden;
}

/* Scene: The Approach */
.scene-approach {
    position: relative;
    height: 100vh;
    min-height: 600px;
    background: linear-gradient(170deg, #f4ece1 0%, #e8d5b7 40%, #c5b8cc22 100%);
    display: flex;
    align-items: flex-start;
    justify-content: flex-start;
    overflow: hidden;
}

.arch-monumental {
    position: absolute;
    bottom: -10%;
    left: 50%;
    transform: translateX(-50%);
    width: 70vw;
    height: 50vh;
    border-radius: 50% 50% 0 0;
    background: rgba(194, 120, 92, 0.15);
    animation: breathe 8s ease-in-out infinite;
}

@keyframes breathe {
    0%, 100% { transform: translateX(-50%) scale(1); }
    50% { transform: translateX(-50%) scale(1.02); }
}

.calligraphic-lines {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 30%;
    pointer-events: none;
}

.calligraphic-lines svg {
    width: 100%;
    height: 100%;
}

.approach-content {
    padding: clamp(3rem, 8vw, 8rem);
    padding-top: clamp(4rem, 12vh, 10rem);
    z-index: 1;
}

.wordmark {
    font-family: 'Playfair Display', serif;
    font-style: italic;
    font-weight: 400;
    font-size: clamp(3rem, 7vw, 6rem);
    letter-spacing: 0.02em;
    line-height: 1.12;
    color: var(--burnt-umber);
    margin-bottom: 1.5rem;
}

.epigraph {
    font-family: 'Source Serif 4', serif;
    font-size: clamp(1.1rem, 1.8vw, 1.4rem);
    font-weight: 300;
    max-width: min(540px, 70vw);
    color: var(--loam);
    opacity: 0.85;
}

/* Scene: The Clearing */
.scene-clearing {
    position: relative;
    min-height: 80vh;
    padding: clamp(4rem, 10vh, 8rem) clamp(2rem, 8vw, 8rem);
    overflow: hidden;
}

.clearing-shapes {
    position: absolute;
    right: 5%;
    top: 10%;
    width: 40vw;
    height: 80%;
    pointer-events: none;
}

.shape-circle {
    position: absolute;
    top: 10%;
    right: 10%;
    width: clamp(200px, 30vw, 400px);
    height: clamp(200px, 30vw, 400px);
    border-radius: 50%;
    background: rgba(197, 184, 204, 0.12);
}

.shape-rectangle {
    position: absolute;
    top: 30%;
    right: 25%;
    width: clamp(150px, 20vw, 280px);
    height: clamp(150px, 20vw, 280px);
    background: rgba(212, 168, 87, 0.08);
    transform: rotate(15deg);
}

.clearing-blocks {
    position: relative;
    z-index: 1;
    max-width: min(540px, 70vw);
}

.clearing-block {
    margin-bottom: 3rem;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s var(--ease-organic), transform 0.8s var(--ease-organic);
}

.clearing-block.visible {
    opacity: 1;
    transform: translateY(0);
}

.clearing-block:nth-child(2) { transition-delay: 120ms; }
.clearing-block:nth-child(3) { transition-delay: 240ms; }

.triangle-ornament {
    display: inline-block;
    width: 0;
    height: 0;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-bottom: 17px solid var(--sage-mist);
    margin-bottom: 0.75rem;
}

.clearing-block p {
    font-size: clamp(1rem, 1.3vw, 1.15rem);
    line-height: 1.8;
}

/* Scene: The Bridge */
.scene-bridge {
    position: relative;
    height: 100vh;
    min-height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background-color: var(--aged-linen);
}

.bridge-arch {
    position: absolute;
    bottom: 0;
    width: 35vw;
    height: 60vh;
    border-radius: 50% 50% 0 0;
    background: linear-gradient(to top, #e8d5b7, transparent);
    transition: transform 0.3s var(--ease-organic);
}

.bridge-arch-left {
    left: 10%;
}

.bridge-arch-right {
    right: 10%;
}

.bridge-text {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.bridge-phrase {
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 300;
    font-size: clamp(1rem, 2vw, 1.6rem);
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--loam);
}

/* Scene: The Garden */
.scene-garden {
    position: relative;
    min-height: 80vh;
    padding: clamp(4rem, 8vh, 8rem) clamp(2rem, 5vw, 6rem);
    overflow: hidden;
}

.garden-lines {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.garden-lines svg {
    width: 100%;
    height: 100%;
}

.garden-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    grid-template-rows: repeat(4, auto);
    gap: 2rem;
    max-width: 900px;
    margin: 0 auto;
}

.garden-card {
    position: relative;
    padding: 2rem 1.5rem;
    padding-top: 2.5rem;
    border: 1px solid var(--terracotta);
    max-width: 320px;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s var(--ease-organic), transform 0.8s var(--ease-organic);
}

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

.garden-card:nth-child(2) { transition-delay: 120ms; }
.garden-card:nth-child(3) { transition-delay: 240ms; }
.garden-card:nth-child(4) { transition-delay: 360ms; }

.card-arch {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 20px;
    border-radius: 40px 40px 0 0;
    background: var(--terracotta);
    opacity: 0.6;
}

.garden-card p {
    font-size: 0.95rem;
    line-height: 1.75;
    color: var(--burnt-umber);
}

/* Scene: The Foundation */
.scene-foundation {
    position: relative;
    min-height: 60vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: var(--loam);
    padding: 4rem 2rem;
    overflow: hidden;
}

.foundation-lines {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.foundation-lines svg {
    width: 100%;
    height: 100%;
}

.wordmark-footer {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: clamp(2rem, 4vw, 3.5rem);
    color: var(--aged-linen);
    margin-bottom: 1rem;
    letter-spacing: 0.02em;
}

.footer-copy {
    font-family: 'Josefin Sans', sans-serif;
    font-size: 0.85rem;
    color: var(--aged-linen);
    opacity: 0.7;
    margin-bottom: 2rem;
}

.footer-shapes {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.footer-circle {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--terracotta);
    opacity: 0.7;
}

.footer-triangle {
    width: 0;
    height: 0;
    border-left: 9px solid transparent;
    border-right: 9px solid transparent;
    border-bottom: 16px solid var(--sage-mist);
    opacity: 0.7;
}

.footer-arch {
    width: 20px;
    height: 10px;
    border-radius: 20px 20px 0 0;
    background: var(--honeyed-gold);
    opacity: 0.7;
}

/* Stippled texture overlay */
.scene-approach::before,
.scene-bridge::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='4' height='4'%3E%3Ccircle cx='2' cy='2' r='0.5' fill='%233d2b1a' opacity='0.03'/%3E%3C/svg%3E");
    pointer-events: none;
}

/* Responsive */
@media (max-width: 768px) {
    .garden-grid {
        grid-template-columns: 1fr;
        grid-template-rows: auto;
    }
    .garden-card {
        grid-column: auto !important;
        grid-row: auto !important;
        max-width: 100%;
    }
    .bridge-arch {
        width: 40vw;
    }
    .clearing-shapes {
        opacity: 0.5;
    }
}
