:root {
    --text: #1f1a14;
    --muted: #5e5348;
    --panel: rgba(255, 251, 244, 0.86);
    --line: rgba(208, 186, 152, 0.55);
    --accent: #b04e2e;
    --brand-gold-start: #d8a93a;
    --brand-gold-end: #8a5a13;
    --shadow: 0 20px 44px rgba(39, 24, 10, 0.2);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--text);
    font-family: "Fraunces", Georgia, serif;
    line-height: 1.5;
    background: #f4ebde;
    overflow-x: hidden;
}

.wip-banner {
    width: 100%;
    text-align: center;
    padding: 0.5rem 0.8rem;
    font-family: "Oswald", "Arial Narrow", sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.78rem;
    color: #5e3a19;
    background: rgba(242, 217, 174, 0.78);
    border-bottom: 1px solid rgba(193, 156, 102, 0.55);
}

h1,
h2,
h3,
.brand,
.btn,
.site-nav a {
    font-family: "Oswald", "Arial Narrow", sans-serif;
    letter-spacing: 0.03em;
}

.hero {
    min-height: 100vh;
    padding: 1.4rem clamp(1rem, 2.5vw, 2.5rem) 5rem;
    max-width: 1920px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
    background:
        linear-gradient(120deg, rgba(244, 235, 222, 0.58), rgba(244, 235, 222, 0.26)),
        url("../img/backgrounds/chastity-cortijo-4RzMYZ0lx-0-unsplash.jpg") center/cover no-repeat;
}

.hero-bg-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(0.95) contrast(1.05);
    transform: scale(1.05);
}

.hero-bg-video-media {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(0.95) contrast(1.05);
    transform: scale(1.05);
}

.hero::before,
.section::before {
    content: "";
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transform: scale(1.05);
    filter: blur(10px);
    transition: opacity 800ms ease, transform 800ms ease, filter 800ms ease;
    pointer-events: none;
    z-index: 0;
}

.hero.reveal.visible::before {
    opacity: 0.52;
    transform: scale(1);
    filter: blur(0);
}

.section.reveal.visible::before {
    opacity: 0.22;
    transform: scale(1);
    filter: blur(0);
}

.hero > :not(.hero-bg),
.section > * {
    position: relative;
    z-index: 2;
}

.hero::before {
    background: linear-gradient(120deg, rgba(244, 235, 222, 0.62), rgba(244, 235, 222, 0.28));
}

.services::before {
    background-image:
        linear-gradient(120deg, rgba(244, 235, 222, 0.22), rgba(244, 235, 222, 0.18)),
        url("../img/backgrounds/fred-kleber-FEr2pzZ1qAY-unsplash.jpg");
}

.work::before {
    background-image:
        linear-gradient(120deg, rgba(244, 235, 222, 0.22), rgba(244, 235, 222, 0.18)),
        url("../img/backgrounds/jonathan-borba-fUSb6H6oeis-unsplash.jpg");
}

.featured::before {
    background-image:
        linear-gradient(120deg, rgba(244, 235, 222, 0.22), rgba(244, 235, 222, 0.18)),
        url("../img/backgrounds/lukas-bato-9vWhrKcn2pE-unsplash.jpg");
}

.craft::before {
    background-image:
        linear-gradient(120deg, rgba(244, 235, 222, 0.22), rgba(244, 235, 222, 0.18)),
        url("../img/3d_panels/20230324_100625.jpg");
}

.site-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    position: sticky;
    top: 0;
    z-index: 6;
    background: rgba(245, 235, 220, 0.72);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(223, 207, 183, 0.65);
    border-radius: 18px;
    padding: 0.9rem 1rem;
}

.brand {
    text-decoration: none;
    font-size: clamp(1.3rem, 2vw, 1.6rem);
    font-weight: 700;
    letter-spacing: 0.08em;
    background: linear-gradient(135deg, var(--brand-gold-start) 0%, #f4df97 45%, var(--brand-gold-end) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-transform: uppercase;
}

.nav-links {
    display: flex;
    gap: 1rem;
}

.site-nav a {
    color: var(--text);
    text-decoration: none;
    text-transform: uppercase;
    font-size: 0.88rem;
}

.lang-wrap {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.lang-wrap label {
    font-family: "Oswald", sans-serif;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #4e463f;
}

.lang-wrap select {
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.8);
    border-radius: 999px;
    padding: 0.3rem 0.62rem;
}

.hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
    gap: 1.5rem;
    align-items: center;
    margin-top: clamp(3rem, 8vh, 6rem);
    position: relative;
    z-index: 3;
}

.hero-content h1 {
    font-size: clamp(2rem, 7vw, 4.4rem);
    line-height: 0.96;
    margin: 0;
    max-width: 14ch;
}

.eyebrow {
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 0.82rem;
    color: #2c5f4d;
}

.lead {
    max-width: 65ch;
    color: var(--muted);
    margin: 1.2rem 0 2rem;
}

.hero-actions {
    display: flex;
    gap: 0.7rem;
    flex-wrap: wrap;
}

.btn {
    display: inline-block;
    text-decoration: none;
    color: #fff;
    background: linear-gradient(120deg, var(--accent), #c26a43);
    padding: 0.75rem 1.1rem;
    border-radius: 999px;
    text-transform: uppercase;
    font-size: 0.84rem;
    box-shadow: 0 10px 24px rgba(176, 78, 46, 0.26);
}

.btn-outline {
    color: var(--text);
    background: rgba(255, 251, 244, 0.62);
    border: 1px solid var(--line);
    box-shadow: none;
}

.hero-media {
    display: grid;
    gap: 0.9rem;
}

.hero-media-main,
.hero-media-stack img,
.project-card img,
.craft-card img,
.gallery-card img {
    width: 100%;
    display: block;
    object-fit: cover;
    border-radius: 18px;
}

.hero-media-main {
    overflow: hidden;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.hero-media-main img {
    height: 340px;
}

.hero-media-main figcaption {
    padding: 0.75rem 0.9rem;
    font-size: 0.78rem;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    color: #4a423b;
}

.hero-media-stack {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.9rem;
}

.hero-media-stack img {
    height: 178px;
    box-shadow: var(--shadow);
}

.hero-grid {
    position: relative;
    z-index: 3;
}

.section {
    padding: clamp(2.7rem, 8vw, 6rem) clamp(1rem, 2.5vw, 2.5rem);
    max-width: 1920px;
    margin: 0 auto;
    position: relative;
}

.section-head {
    max-width: 760px;
    margin-bottom: 1.4rem;
}

h2 {
    margin: 0;
    font-size: clamp(1.5rem, 4vw, 2.7rem);
    line-height: 1.05;
}

.card-grid,
.timeline,
.project-grid,
.craft-grid,
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.card-grid,
.gallery-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card,
.step,
.project-card,
.craft-card,
.gallery-card {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 1rem;
    box-shadow: var(--shadow);
}

.step span {
    font-family: "Oswald", sans-serif;
    color: #245b48;
    font-size: 2rem;
}

.project-card,
.craft-card {
    display: grid;
    gap: 0.7rem;
}

.project-card img,
.craft-card img,
.gallery-card img {
    height: 260px;
}

.project-card h3,
.craft-card h3,
.gallery-card h3 {
    margin: 0;
}

.project-card p,
.craft-card p,
.card p,
.step p,
.gallery-card p {
    margin: 0.3rem 0 0;
    color: var(--muted);
}

.site-footer {
    border-top: 1px solid var(--line);
    text-align: center;
    padding: 1.25rem;
    color: var(--muted);
    max-width: 1920px;
    margin: 0 auto;
}

/* Blur transition for section images */
.section img {
    filter: blur(8px);
    transform: scale(1.025);
    transition: filter 700ms ease, transform 700ms ease;
}

.reveal.visible img,
.section img.visible,
.hero-media.reveal.visible img {
    filter: blur(0);
    transform: scale(1);
}

.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 700ms ease, transform 700ms ease;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 980px) {
    .hero-grid,
    .card-grid,
    .timeline,
    .project-grid,
    .craft-grid,
    .gallery-grid {
        grid-template-columns: 1fr;
    }

    .hero-media-main img,
    .project-card img,
    .craft-card img,
    .hero-media-stack img,
    .gallery-card img {
        height: 220px;
    }

    .hero-media-stack {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .hero-bg-video-media {
        display: none;
    }

    .hero.reveal.visible::before {
        opacity: 0.68;
    }
}

@media (max-width: 640px) {
    .site-nav {
        align-items: flex-start;
    }

    .nav-links {
        gap: 0.7rem;
    }

    .site-nav a {
        font-size: 0.74rem;
    }

    .lang-wrap {
        width: 100%;
        justify-content: flex-end;
    }
}
