/* ═══════════════════════════════════════════
   KATE INTERIORS — RESIDENTIAL PORTFOLIO
   Responsive: phone / tablet / desktop / wide
═══════════════════════════════════════════ */

/* ── TOKENS ─────────────────────────────── */
:root {
    --white: #FAFAF8;
    --off-white: #F3F0EB;
    --greige: #E8E3DC;
    --stone: #C4BBB0;
    --stone-mid: #9C9188;
    --charcoal: #2E2C2A;
    --ink: #1A1816;

    --font-sans: 'Inter', system-ui, sans-serif;
    --font-serif: 'Cormorant Garamond', Georgia, serif;

    --gap: 6px;
    --pad: clamp(1rem, 4vw, 4rem);
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ── RESET ──────────────────────────────── */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    background: var(--white);
    color: var(--charcoal);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

figure {
    margin: 0;
}

img {
    display: block;
    max-width: 100%;
    height: auto;
}

/* ── UTILITIES ──────────────────────────── */
.container {
    width: min(100%, 1600px);
    margin-inline: auto;
    padding-inline: var(--pad);
}

.eyebrow {
    display: inline-block;
    font-size: 0.6rem;
    font-weight: 500;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--stone-mid);
}

/* ── NAV ────────────────────────────────── */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 200;
    padding-block: 0.75rem;
    background: rgba(250, 250, 248, 0.97);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--greige);
}

.nav {
    display: flex;
    align-items: center;
}

.nav__logo-img {
    height: 80px;
    width: auto;
    object-fit: contain;
    display: block;
}

/* ── HERO ────────────────────────────────── */
.hero {
    position: relative;
    height: 100svh;
    min-height: 480px;
    overflow: hidden;
}

.hero__img {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    transform: scale(1.05);
    transition: transform 10s var(--ease);
    will-change: transform;
}

body.ready .hero__img {
    transform: scale(1);
}

.hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom,
            rgba(220, 216, 210, 0.80) 0%,
            rgba(220, 216, 210, 0.30) 45%,
            transparent 100%);
}

.hero__content {
    position: absolute;
    bottom: 10%;
    left: var(--pad);
    z-index: 10;
    max-width: 700px;
}

.hero__content .eyebrow {
    margin-bottom: 1rem;
    font-size: 0.8rem;
    letter-spacing: 0.22em;
    color: var(--charcoal);
    font-weight: 500;
}

.hero__content h1 {
    font-family: var(--font-serif);
    font-size: clamp(2.8rem, 7vw, 7rem);
    font-weight: 300;
    line-height: 1.02;
    color: var(--white);
    letter-spacing: -0.01em;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.25);
}

.hero__content h1 em {
    font-style: italic;
    opacity: 0.75;
    font-weight: 300;
}

/* ── PORTFOLIO ───────────────────────────── */
.portfolio {
    padding-top: 100px;
    /* clear fixed nav — adjusted for 80px logo */
    padding-bottom: clamp(3rem, 6vw, 8rem);
}

/* ── PROJECT BLOCK ──────────────────────── */
.proj-block {
    margin-bottom: clamp(2.5rem, 5vw, 6rem);
}

.proj-header {
    padding-block: 1.2rem 0.8rem;
    border-top: 1px solid var(--greige);
    display: flex;
    align-items: baseline;
    gap: 1.2rem;
    flex-wrap: wrap;
}

.proj-eyebrow {
    font-size: 0.6rem;
    font-weight: 500;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--stone);
    flex-shrink: 0;
}

.proj-name {
    font-family: var(--font-serif);
    font-size: clamp(1.2rem, 2.5vw, 2.4rem);
    font-weight: 300;
    color: var(--charcoal);
    letter-spacing: -0.01em;
    flex: 1;
    min-width: 0;
}

.proj-location {
    font-size: 0.65rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--stone-mid);
    flex-shrink: 0;
}

/* ── PROJ GRIDS ─────────────────────────── */
.proj-grid {
    padding-inline: var(--gap);
    margin-bottom: var(--gap);
}

/* Full width */
.proj-grid--1 {
    /* just padding, img fills naturally */
}

/* 2 equal columns */
.proj-grid--2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--gap);
}

/* 4 columns */
.proj-grid--4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--gap);
}

/* Video centred */
.proj-grid--video {
    display: flex;
    justify-content: center;
    padding-inline: var(--gap);
}

/* ── IMAGE CELL ─────────────────────────── */
.img-cell {
    background: var(--off-white);
    overflow: hidden;
}

.img-cell img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.7s var(--ease);
}

.img-cell:hover img {
    transform: scale(1.02);
}

/* ── VIDEO ───────────────────────────────── */
.proj-video {
    display: block;
    width: 60%;
    max-width: 860px;
    height: auto;
}

.video-cell {
    overflow: hidden;
}

.proj-video--inline {
    display: block;
    width: 100%;
    height: auto;
}

/* ════════════════════════════════════════════
   RESPONSIVE BREAKPOINTS
════════════════════════════════════════════ */

/* ── WIDESCREEN ≥ 1600px ──────────────────
   Wider container, larger grids             */
@media (min-width: 1600px) {
    :root {
        --gap: 8px;
    }

    .proj-grid--4 {
        grid-template-columns: repeat(4, 1fr);
    }

    .proj-name {
        font-size: 2.6rem;
    }
}

/* ── TABLET LANDSCAPE 1025px – 1280px ──── */
@media (max-width: 1280px) and (min-width: 1025px) {
    .proj-grid--4 {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* ── TABLET PORTRAIT 641px – 1024px ────── */
@media (max-width: 1024px) {
    :root {
        --gap: 5px;
    }

    .nav__logo-img {
        height: 60px;
    }

    .portfolio {
        padding-top: 84px;
    }

    /* 4-col becomes 2-col on tablet */
    .proj-grid--4 {
        grid-template-columns: repeat(2, 1fr);
    }

    .proj-video {
        width: 80%;
    }

    .hero__content h1 {
        font-size: clamp(2.4rem, 6vw, 4.5rem);
    }
}

/* ── MOBILE LARGE 481px – 640px ─────────── */
@media (max-width: 640px) {
    :root {
        --gap: 4px;
        --pad: 1rem;
    }

    .nav__logo-img {
        height: 48px;
    }

    .portfolio {
        padding-top: 72px;
    }

    /* All grids go single column */
    .proj-grid--2,
    .proj-grid--4 {
        grid-template-columns: 1fr;
    }

    .proj-header {
        flex-direction: column;
        gap: 0.2rem;
        padding-block: 0.8rem 0.5rem;
    }

    .proj-location {
        margin-top: 0.1rem;
    }

    .proj-video {
        width: 100%;
    }

    .hero__content h1 {
        font-size: clamp(2rem, 10vw, 3rem);
    }

    .hero__content .eyebrow {
        font-size: 0.65rem;
    }
}

/* ── MOBILE SMALL ≤ 480px ───────────────── */
@media (max-width: 480px) {
    :root {
        --gap: 3px;
        --pad: 0.8rem;
    }

    .nav__logo-img {
        height: 40px;
    }

    .portfolio {
        padding-top: 64px;
    }

    .proj-name {
        font-size: 1.15rem;
    }

    .hero__content h1 {
        font-size: clamp(1.8rem, 11vw, 2.5rem);
    }

    .hero {
        min-height: 420px;
    }
}