/* =============================================
   miris.works - Terracotta Gallery Stylesheet
   Fonts: Fraunces, Literata, Space Grotesk" (Google Fonts)
   IntersectionObserver at 20% threshold triggers sequenced
   reveal: panel slides up (400ms)
   ============================================= */

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

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

body {
    background-color: #3A2018;
    color: #F0E0D0;
    font-family: 'Literata', Georgia, serif;
    font-weight: 400;
    font-size: clamp(15px, 1.1vw, 18px);
    line-height: 1.75;
    overflow-x: hidden;
}

/* ----- Marble Texture Mixin (reusable) ----- */
.marble-texture {
    background-color: #E8D8C8;
    background-image:
        radial-gradient(ellipse at 20% 50%, rgba(200, 160, 96, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 20%, rgba(138, 96, 72, 0.12) 0%, transparent 45%),
        radial-gradient(ellipse at 40% 80%, rgba(90, 56, 40, 0.08) 0%, transparent 55%),
        radial-gradient(ellipse at 70% 60%, rgba(200, 160, 96, 0.1) 0%, transparent 40%),
        radial-gradient(ellipse at 10% 90%, rgba(138, 96, 72, 0.06) 0%, transparent 50%),
        linear-gradient(135deg, #E8D8C8, #D8C8B8);
}

/* =============================================
   HERO SECTION
   ============================================= */
.hero {
    position: relative;
    width: 100%;
    height: 100vh;
    min-height: 600px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(180deg, #3A2018 0%, #4A2820 100%);
    overflow: hidden;
}

.marble-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.08;
    background-image:
        radial-gradient(ellipse at 25% 30%, rgba(232, 216, 200, 0.6) 0%, transparent 50%),
        radial-gradient(ellipse at 75% 60%, rgba(232, 216, 200, 0.4) 0%, transparent 55%),
        radial-gradient(ellipse at 50% 80%, rgba(200, 160, 96, 0.3) 0%, transparent 40%),
        radial-gradient(ellipse at 15% 70%, rgba(232, 216, 200, 0.35) 0%, transparent 45%),
        radial-gradient(ellipse at 85% 25%, rgba(200, 160, 96, 0.25) 0%, transparent 50%);
    pointer-events: none;
}

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

.logotype {
    font-family: 'Fraunces', Georgia, serif;
    font-size: clamp(48px, 8vw, 120px);
    font-variation-settings: 'wght' 300, 'opsz' 144;
    color: #F0E0D0;
    letter-spacing: -0.02em;
    cursor: default;
    transition: font-variation-settings 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    opacity: 0;
    animation: logotypeEntry 1.2s ease-in-out 0.3s forwards;
}

.logotype:hover {
    font-variation-settings: 'wght' 900, 'opsz' 144;
}

@keyframes logotypeEntry {
    0% {
        opacity: 0;
        font-variation-settings: 'wght' 100, 'opsz' 144;
    }
    100% {
        opacity: 1;
        font-variation-settings: 'wght' 300, 'opsz' 144;
    }
}

.hero-tagline {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(11px, 0.9vw, 14px);
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: #C8A060;
    margin-top: 1rem;
    opacity: 0;
    animation: fadeIn 0.8s ease-out 1.0s forwards;
}

/* Hero Tree */
.hero-tree {
    position: absolute;
    bottom: 5%;
    left: 50%;
    transform: translateX(-50%);
    width: clamp(250px, 30vw, 400px);
    z-index: 1;
    opacity: 0;
    animation: fadeIn 0.8s ease-out 1.5s forwards;
}

.tree-silhouette {
    width: 100%;
    height: auto;
}

/* Scroll Hint */
.scroll-hint {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    z-index: 3;
    opacity: 0;
    animation: fadeIn 0.6s ease-out 2.2s forwards;
}

.scroll-hint-text {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 11px;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: #C8A060;
    opacity: 0.6;
}

.scroll-arrow {
    animation: bobDown 2s ease-in-out infinite;
}

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

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* =============================================
   GALLERY SECTION
   ============================================= */
.gallery {
    position: relative;
    width: 100%;
}

/* ----- Project Section ----- */
.project-section {
    position: relative;
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    background: linear-gradient(180deg, #3A2018, #4A2820);
}

.project-section:nth-child(even) {
    background: linear-gradient(180deg, #4A2820, #3A2018);
}

/* ----- Botanical Accents ----- */
.botanical-accent {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 80px;
    height: 200px;
    opacity: 0;
    transition: opacity 0.6s ease-out 0.5s;
    pointer-events: none;
    color: #708860;
}

.botanical-left {
    left: clamp(1rem, 5vw, 6rem);
}

.botanical-right {
    right: clamp(1rem, 5vw, 6rem);
}

.project-section.is-revealed .botanical-accent {
    opacity: 1;
}

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

/* ----- Project Pedestal (Marble Panel) ----- */
.project-pedestal {
    width: 100%;
    max-width: 900px;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.4s ease-out, transform 0.4s ease-out;
}

.project-section.is-revealed .project-pedestal {
    opacity: 1;
    transform: translateY(0);
}

.project-card {
    background-color: #E8D8C8;
    background-image:
        radial-gradient(ellipse at 20% 50%, rgba(200, 160, 96, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 20%, rgba(138, 96, 72, 0.12) 0%, transparent 45%),
        radial-gradient(ellipse at 40% 80%, rgba(90, 56, 40, 0.08) 0%, transparent 55%),
        radial-gradient(ellipse at 70% 60%, rgba(200, 160, 96, 0.1) 0%, transparent 40%),
        radial-gradient(ellipse at 10% 90%, rgba(138, 96, 72, 0.06) 0%, transparent 50%),
        linear-gradient(135deg, #E8D8C8, #D8C8B8);
    padding: clamp(2rem, 4vw, 4rem);
    border-radius: 2px;
    box-shadow:
        0 4px 20px rgba(0, 0, 0, 0.25),
        0 1px 3px rgba(0, 0, 0, 0.15);
    position: relative;
    overflow: hidden;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, #C8A060, transparent);
    opacity: 0.6;
}

/* ----- Project Content ----- */
.project-meta {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(11px, 0.8vw, 13px);
    font-weight: 400;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #8A6048;
    display: block;
    margin-bottom: 1rem;
    opacity: 0;
    transition: opacity 0.4s ease-out 0.3s;
}

.project-section.is-revealed .project-meta {
    opacity: 1;
}

.project-title {
    font-family: 'Fraunces', Georgia, serif;
    font-size: clamp(32px, 5vw, 64px);
    font-variation-settings: 'wght' 100, 'opsz' 72;
    color: #3A2018;
    line-height: 1.15;
    margin-bottom: 1.25rem;
    transition: font-variation-settings 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.project-section.is-revealed .project-title {
    font-variation-settings: 'wght' 700, 'opsz' 72;
}

.project-description {
    font-family: 'Literata', Georgia, serif;
    font-size: clamp(15px, 1.1vw, 18px);
    font-weight: 400;
    line-height: 1.75;
    color: #5A3828;
    max-width: 680px;
    opacity: 0;
    transition: opacity 0.4s ease-out 0.3s;
}

.project-section.is-revealed .project-description {
    opacity: 1;
    transition-delay: 0.6s;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1.5rem;
    opacity: 0;
    transition: opacity 0.4s ease-out 0.3s;
}

.project-section.is-revealed .project-tags {
    opacity: 1;
    transition-delay: 0.8s;
}

.tag {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(10px, 0.7vw, 12px);
    font-weight: 400;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #8A6048;
    background: rgba(200, 160, 96, 0.15);
    border: 1px solid rgba(138, 96, 72, 0.2);
    padding: 0.3em 0.8em;
    border-radius: 1px;
}

/* =============================================
   FOOTER
   ============================================= */
.footer {
    position: relative;
    background: #3A2018;
    padding: 4rem 2rem;
    text-align: center;
    overflow: hidden;
}

.footer-botanical {
    width: 100%;
    max-width: 600px;
    margin: 0 auto 2rem;
    opacity: 0.5;
}

.footer-botanical svg {
    width: 100%;
    height: auto;
}

.footer-content {
    position: relative;
    z-index: 1;
}

.footer-logotype {
    font-family: 'Fraunces', Georgia, serif;
    font-size: clamp(24px, 3vw, 36px);
    font-variation-settings: 'wght' 500, 'opsz' 72;
    color: #F0E0D0;
    margin-bottom: 0.5rem;
}

.footer-text {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(11px, 0.8vw, 13px);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #8A6048;
    margin-bottom: 1.5rem;
}

.footer-divider {
    width: 60px;
    height: 1px;
    background: #C8A060;
    opacity: 0.4;
    margin: 0 auto 1.5rem;
}

.footer-year {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(11px, 0.8vw, 13px);
    letter-spacing: 0.2em;
    color: #8A6048;
    opacity: 0.6;
}

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 768px) {
    .botanical-accent {
        display: none;
    }

    .project-section {
        min-height: 60vh;
        padding: 3rem 1.25rem;
    }

    .project-card {
        padding: 1.75rem;
    }

    .hero-tree {
        width: 200px;
    }

    .scroll-hint {
        bottom: 1.5rem;
    }
}

@media (max-width: 480px) {
    .logotype {
        font-size: clamp(36px, 12vw, 60px);
    }

    .project-title {
        font-size: clamp(26px, 7vw, 40px);
    }

    .project-card {
        padding: 1.5rem;
    }

    .footer {
        padding: 3rem 1.25rem;
    }
}
