:root {
    --brand-dark: #22140A;        /* Dark Brown */
    --brand-brown: #6B4423;       /* Footer & Accent Brown */
    --brand-light: #FBF8F5;
    --text-light: #FFFFFF;
    --gold-accent: #D4AF37;       /* Rich Gold for Oval Frame */
    --dark-sand: #9F7D4F;         /* Dark Sand */
    --cafe-noir: #4B3621;         /* Café Noir */
    /* Bright matte palette: used for random hover borders + image-loading placeholders */
    --bright-1: #D97757;          /* terracotta */
    --bright-2: #4E8E8E;          /* teal */
    --bright-3: #C9A227;          /* mustard gold */
    --bright-4: #8E6FA8;          /* muted violet */
    --bright-5: #5B8C5A;          /* sage green */
    --bright-6: #C1666B;          /* muted coral */
    --font-center: 'Open Sans', sans-serif;
    --font-montserrat: 'Montserrat', sans-serif;      /* ExtraLight 200 */
    --font-script: 'Petit Formal Script', cursive;     /* 'Coming Soon' labels */
    --font-baskerville: 'Baskervville', serif;
    --font-jolly: 'Jolly Lodger', cursive;
    --font-tenor: 'Tenor Sans', sans-serif;
    /* Page colours (easy to change here) */
    --hero-colour: #513333;       /* Title bars on About / Contact / Privacy. NOTE: supplied as "51333" - confirm */
    --contact-sand: #A89583;      /* Behind the contact form and the legal text */
    --about-sand: #A89583;        /* Behind the About bio */
    --on-light-sand: #22140A;     /* Very dark brown text on the light sand colour */
    --header-h: 72px;             /* Height of the white header bar */
}

html {
    font-synthesis: none;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

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

body {
    background-color: var(--brand-light);
    color: var(--brand-dark);
    font-family: var(--font-center);
    line-height: 1.6;
    overflow-x: hidden;
}

/* ===================================================
   HEADER & SCREEN-CENTERED NAVIGATION
   =================================================== */
.main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 0 50px;
    height: var(--header-h);
    display: flex;
    align-items: center;
    background-color: transparent;
    transition: background-color 1.5s ease;
}

.main-header:hover {
    background-color: #FFFFFF;
}

.header-container {
    width: 100%;
    max-width: 1800px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
}

/* Header Left: Montserrat ExtraLight 200 */
.header-left {
    flex-shrink: 0;
}

.header-left .header-brand-name {
    text-decoration: none;
    color: var(--text-light);
    font-family: var(--font-montserrat);
    font-weight: 200;
    font-size: clamp(0.875rem, 1.5vw, 1.375rem);
    letter-spacing: 1.5px;
    line-height: 1;
    transition: color 1.5s ease;
}

.main-header:hover .header-left .header-brand-name {
    color: var(--brand-dark);
}

/* Header Center: positioned to the true centre of the screen, vertically centered */
.header-center {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
}

.header-right {
    flex-shrink: 0;
}

/* Scroll Direction Fade Class for Center Links and Right Logo */
.scroll-fade {
    transition: opacity 0.5s ease;
    opacity: 1;
}

.main-header.hide-nav .scroll-fade {
    opacity: 0;
    pointer-events: none;
}

/* Hovering always reveals the links again, even while scrolled down */
.main-header.hide-nav:hover .scroll-fade {
    opacity: 1;
    pointer-events: auto;
}

.main-nav ul {
    display: flex;
    list-style: none;
    gap: 45px;
}

.nav-link {
    text-decoration: none;
    color: var(--text-light);
    font-family: var(--font-center);
    font-weight: 400;
    font-size: clamp(0.8125rem, 1.042vw, 0.9375rem);
    letter-spacing: 2px;
    transition: color 1.5s ease;
}

.main-header:hover .nav-link {
    color: var(--brand-dark);
}

/* Header Right: Logo */
.header-logo {
    height: calc(var(--header-h) * 0.75);   /* three-quarters of the white bar, vertically centred */
    width: auto;
    display: block;
    filter: brightness(0) invert(1);
    transition: filter 1.5s ease;
}

.main-header:hover .header-logo {
    filter: none;
}

/* Projects listing page: the strip behind the header is light, so the header text is dark
   (white text would disappear when the white bar fades). Once scrolled over images it turns white. */
.projects-page .main-header .header-brand-name,
.projects-page .main-header .nav-link {
    color: var(--brand-dark);
}

.projects-page .main-header .header-logo {
    filter: none;
}

.projects-page .main-header.scrolled:not(:hover) .header-brand-name,
.projects-page .main-header.scrolled:not(:hover) .nav-link {
    color: var(--text-light);
}

.projects-page .main-header.scrolled:not(:hover) .header-logo {
    filter: brightness(0) invert(1);
}

/* ===================================================
   FULL-BLEED GALLERY GRID WITH THIN SEPARATORS
   =================================================== */
.homepage-showcase-full {
    width: 100%;
    padding: 0;
    margin: 0;
}

.gallery-full-grid {
    display: flex;
    flex-direction: column;
    gap: 2px;
    width: 100%;
    background-color: #ffffff;
}

.gallery-row {
    display: flex;
    gap: 2px;
    width: 100%;
}

.gallery-slot {
    position: relative;
    flex: 1;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background-color: var(--bright-1);
}

/* Random bright matte placeholder colour while an image loads */
.gallery-row .gallery-slot:nth-of-type(6n+1) { background-color: var(--bright-1); }
.gallery-row .gallery-slot:nth-of-type(6n+2) { background-color: var(--bright-2); }
.gallery-row .gallery-slot:nth-of-type(6n+3) { background-color: var(--bright-3); }
.gallery-row .gallery-slot:nth-of-type(6n+4) { background-color: var(--bright-4); }
.gallery-row .gallery-slot:nth-of-type(6n+5) { background-color: var(--bright-5); }
.gallery-row .gallery-slot:nth-of-type(6n+6) { background-color: var(--bright-6); }

/* Rows with 2+ slots (half-width or less) use a taller ratio so the whole
   image is visible rather than only a cropped horizontal strip through the
   middle. Full-width single-slot rows keep the 16:9 cinematic ratio. */
.gallery-row-split .gallery-slot {
    aspect-ratio: 3 / 4;
}

.slot-link {
    display: block;
    width: 100%;
    height: 100%;
    position: relative;
    text-decoration: none;
}

.slot-link.unlinked {
    cursor: default;
}

.gallery-slot img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Seamless Fade Loop
   Incoming frame (.active) fades in on top; outgoing frame (.under) stays at
   full opacity beneath it, so the slot background never shows through. */
.fade-slot {
    position: relative;
}

.fade-slot .fade-img {
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
    z-index: 0;
    transition: none;
}

.fade-slot .fade-img.under {
    opacity: 1;
    z-index: 1;
}

.fade-slot .fade-img.active {
    opacity: 1;
    z-index: 2;
    transition: opacity 2s linear;
}

/* Overlays & Image Titles */
.item-overlay {
    position: absolute;
    inset: 0;
    background-color: rgba(0, 0, 0, 0);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 20px;
    z-index: 3;
    transition: background-color 1s ease;
}

/* Center Project Image Names set to Tenor Sans — fades in/out with hover */
.item-overlay h3 {
    color: var(--text-light);
    font-family: var(--font-tenor);
    font-weight: 400;
    font-size: clamp(0.8125rem, 1.042vw, 0.9375rem);
    letter-spacing: 3px;
    text-transform: uppercase;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
    line-height: 1;
    opacity: 0;
    transition: opacity 1s ease;
}

.gallery-slot:hover .item-overlay h3 {
    opacity: 1;
}

/* Homepage hover: no image shading. The name sits in a half-transparent black box with a white border */
.title-box {
    background-color: rgba(0, 0, 0, 0.5);
    border: 1px solid #ffffff;
    padding: 16px 30px;
    max-width: 100%;
    text-align: center;
    opacity: 0;
    transition: opacity 1s ease;
}

.gallery-slot:hover .title-box {
    opacity: 1;
}

.title-box h3 {
    opacity: 1;
    text-shadow: none;
}

.coming-soon-label {
    display: block;
    margin-top: 10px;
    font-family: var(--font-script);
    font-weight: 400;
    font-size: clamp(1.1rem, 1.5vw, 1.4rem);
    line-height: 1.2;
    color: #FF0000;
    text-shadow: none;
    transition: none;
    animation: none;
}

.slot-link.unlinked img {
    filter: grayscale(0%);
    transition: filter 0.5s ease;
}

.gallery-slot:hover .slot-link.unlinked img {
    filter: grayscale(100%);
}

.coming-soon-box {
    background-color: #9F7D4F;
    color: var(--text-light);
    font-family: var(--font-center);
    font-weight: 400;
    font-size: 0.8rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    padding: 8px 18px;
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 2px;
    backdrop-filter: blur(4px);
    margin-top: 12px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.gallery-slot:hover .coming-soon-box {
    opacity: 1;
}

/* ===================================================
   STICKY FOOTER NAME (appears during scroll)
   =================================================== */
.sticky-footer-name {
    position: fixed;
    top: 0;
    left: 0;
    margin: 0;
    padding: 0;
    z-index: 999;
    white-space: nowrap;
    background-color: transparent;
    opacity: 0;
    pointer-events: none; /* never block the real footer link underneath */
    transition: opacity 0.3s ease;
}

.sticky-footer-name span {
    display: inline;
    color: var(--text-light);
    font-family: var(--font-montserrat);
    font-weight: 200;
    font-size: clamp(0.875rem, 1.5vw, 1.375rem);
    letter-spacing: 1.5px;
    line-height: 1;
}

.sticky-footer-name.visible {
    opacity: 1;
}

/* Docked: the real footer name is exactly underneath, so hide this copy */
.sticky-footer-name.docked {
    visibility: hidden;
}

/* ===================================================
   FOOTER (20% REDUCED HEIGHT & TOP SEPARATOR)
   =================================================== */
/* Pages without the footer line (Contact, About, Privacy) */
.no-footer-line .footer-top-line {
    display: none;
}

/* Homepage only: small gap between the gallery and the footer */

.footer-top-line {
    width: 100%;
    height: 2px;
    background-color: #ffffff;
    position: relative;
    z-index: 1000;
}

.main-footer {
    width: 100%;
    background-color: #513333;
    padding: 26px 50px;
}

.footer-container {
    max-width: 1800px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.footer-left-link {
    text-decoration: none;
    display: inline-block;
}

.footer-left .footer-brand-name {
    color: var(--text-light);
    font-family: var(--font-montserrat);
    font-weight: 200;
    font-size: clamp(0.875rem, 1.5vw, 1.375rem);
    letter-spacing: 1.5px;
    line-height: 1;
}

.footer-center {
    align-self: flex-end;
}

.footer-center ul {
    display: flex;
    list-style: none;
    gap: 35px;
}

.footer-link {
    text-decoration: none;
    color: var(--text-light);
    font-family: var(--font-center);
    font-weight: 400;
    font-size: clamp(0.8125rem, 1.042vw, 0.9375rem);
    letter-spacing: 2px;
    transition: opacity 0.3s ease;
}

.footer-link:hover {
    opacity: 0.75;
}

.footer-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    align-self: flex-end;
}

.footer-right-link {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    text-decoration: none;
    color: var(--text-light);
}

.footer-copyright-text,
.footer-attribution-text {
    font-family: var(--font-center);
    font-size: 12px;
    letter-spacing: 1px;
    color: rgba(255, 255, 255, 0.6);
}

.footer-right-link:hover .footer-copyright-text,
.footer-right-link:hover .footer-attribution-text {
    text-decoration: underline;
}

.tiger-tech-font {
    font-family: var(--font-jolly);
    font-size: 1.4rem;
    letter-spacing: 1px;
    line-height: 1;
}

/* ===================================================
   RESPONSIVE DESIGN
   =================================================== */
@media (max-width: 900px) {
    .main-header,
    .main-footer {
        padding: 20px;
    }

    .main-header {
        height: auto;
    }

    .header-logo {
        height: 36px;
    }

    .header-container {
        flex-direction: column;
        gap: 10px;
    }

    .header-center {
        position: static;
        transform: none;
        margin-top: 0;
    }

    .footer-container {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }

    .footer-right {
        align-items: center;
    }

    .gallery-row {
        flex-direction: column;
    }

    .gallery-slot {
        aspect-ratio: 4 / 3;
    }

    .gallery-row-split .gallery-slot {
        aspect-ratio: 4 / 3;
    }
}
/* ===================================================
   NEW PAGES: SHARED CAFÉ NOIR HERO BAND (Projects / About / Contact / Privacy)
   =================================================== */
.page-hero {
    width: 100%;
    background-color: var(--hero-colour);
    /* Top padding equals the header bar, so the header never sits over the title */
    padding: calc(var(--header-h) + 24px) 20px 24px;
    text-align: center;
    color: var(--text-light);
}

.page-title {
    font-family: var(--font-montserrat);
    font-weight: 200;
    font-size: clamp(1.75rem, 3.4vw, 3rem);
    letter-spacing: 4px;
    text-transform: uppercase;
    color: var(--text-light);
    line-height: 1;
}

/* ===================================================
   PROJECT DETAIL PAGES
   =================================================== */
.project-detail-main {
    width: 100%;
    position: relative;
}

.project-gallery {
    margin-top: 0;
}

/* Thin white divider line between gallery and blurb */
.gallery-bottom-line {
    width: 100%;
    height: 2px;
    background-color: #ffffff;
}

/* First image's overlay title is permanent (no fade, no darkening) */
.project-gallery > .gallery-row:first-of-type .gallery-slot:first-of-type .item-overlay {
    opacity: 1;
    background-color: transparent;
}

.project-gallery > .gallery-row:first-of-type .gallery-slot:first-of-type .item-overlay h3 {
    opacity: 1;
    text-shadow: none;
}

/* First image: boxed name is permanent, same box as the homepage hover */
.project-gallery > .gallery-row:first-of-type .gallery-slot:first-of-type .title-box {
    opacity: 1;
    transition: none;
}

.project-gallery > .gallery-row:first-of-type .gallery-slot:first-of-type:hover .item-overlay {
    background-color: transparent;
    opacity: 1;
}

.project-blurb {
    position: relative;
    background-color: #A89583;
    max-width: none;
    margin: 0;
    padding: 70px 30px 90px;
    text-align: left;
}

.project-blurb-inner {
    max-width: 760px;
    margin: 0 auto;
}

.prev-project-link {
    position: absolute;
    top: 70px;
    left: 30px;
    display: inline-block;
    color: var(--on-light-sand);
    font-family: var(--font-center);
    font-weight: 600;
    font-size: 0.8rem;
    letter-spacing: 2px;
    text-decoration: none;
    border-bottom: 1px solid var(--on-light-sand);
    padding-bottom: 3px;
    transition: opacity 0.3s ease;
}

.prev-project-link:hover {
    opacity: 0.65;
}

.next-project-link {
    position: absolute;
    top: 70px;
    right: 30px;
    display: inline-block;
    color: var(--on-light-sand);
    font-family: var(--font-center);
    font-weight: 600;
    font-size: 0.8rem;
    letter-spacing: 2px;
    text-decoration: none;
    border-bottom: 1px solid var(--on-light-sand);
    padding-bottom: 3px;
    transition: opacity 0.3s ease;
}

.next-project-link:hover {
    opacity: 0.65;
}

.project-title {
    font-family: var(--font-montserrat);
    font-weight: 200;
    font-size: clamp(1.5rem, 2.6vw, 2.25rem);
    letter-spacing: 3px;
    color: var(--on-light-sand);
    margin-bottom: 25px;
}

.project-body {
    font-family: 'Baskervville', serif;
    font-weight: 400;
    font-size: clamp(1rem, 1.250vw, 1.125rem);
    line-height: 1.9;
    color: var(--on-light-sand);
    margin-bottom: 35px;
}

.project-body.placeholder-text {
    font-style: italic;
    color: var(--on-light-sand);
    opacity: 0.8;
}

.project-credits {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-family: 'Baskervville', serif;
    font-size: 0.95rem;
    color: var(--on-light-sand);
    opacity: 0.9;
}

.credit-label {
    font-weight: 600;
    color: var(--on-light-sand);
    opacity: 1;
}

/* ===================================================
   PROJECTS LISTING PAGE
   =================================================== */
.projects-listing-main {
    width: 100%;
    /* Gap at the top matching the header's white bar, before images start */
    padding-top: var(--header-h);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2px;
    background-color: #ffffff;
}

.projects-card {
    position: relative;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    background-color: #ffffff;
}

/* Random bright matte border colour per card, cycling through 6 tones */
.projects-card:nth-of-type(6n+1) { --card-border-color: var(--bright-1); }
.projects-card:nth-of-type(6n+2) { --card-border-color: var(--bright-2); }
.projects-card:nth-of-type(6n+3) { --card-border-color: var(--bright-3); }
.projects-card:nth-of-type(6n+4) { --card-border-color: var(--bright-4); }
.projects-card:nth-of-type(6n+5) { --card-border-color: var(--bright-5); }
.projects-card:nth-of-type(6n+6) { --card-border-color: var(--bright-6); }

/* Border colour for each live project */
.projects-card[href="cobham-apartment.html"]   { --card-border-color: #A46B52; }
.projects-card[href="cobham-family-home.html"] { --card-border-color: #747B72; }
.projects-card[href="cobham-kitchen.html"]     { --card-border-color: #5A2C3C; }
.projects-card[href="guildford-office.html"]   { --card-border-color: #365E76; }

/* A single growing border that doesn't affect image size */
.card-image-wrap {
    position: relative;
    height: 80vh;
    overflow: visible;
}
/* Growing border: drawn as a border on an overlay (works the same in every browser) */
.card-image-wrap::after {
    content: "";
    position: absolute;
    inset: 0;
    border: 0 solid var(--card-border-color, var(--bright-1));
    box-sizing: border-box;
    pointer-events: none;
    z-index: 1;
    transition: border-width 1s ease;
}
.projects-card:hover .card-image-wrap::after {
    border-width: 16px;
}

.card-image-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Disabled projects (Coming Soon) get color→greyscale fade on hover */
.projects-card-disabled .card-image-wrap img {
    transition: filter 1s ease;
    filter: grayscale(0%);
}

.projects-card-disabled:hover .card-image-wrap img {
    filter: grayscale(100%);
}

.card-label-bar {
    background-color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1em 20px;
}

.card-label-bar h3 {
    font-family: var(--font-tenor);
    font-weight: 400;
    font-size: clamp(0.75rem, 0.972vw, 0.875rem);
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--brand-brown);
    text-align: center;
}

/* Disabled / Coming Soon card variant (no project page yet) */
.projects-card.projects-card-disabled {
    cursor: default;
}

.projects-card.projects-card-disabled .card-image-wrap img {
    filter: grayscale(0%);
    transition: filter 0.5s ease;
}

.projects-card.projects-card-disabled:hover .card-image-wrap img {
    filter: grayscale(100%);
}

.projects-card.projects-card-disabled .card-coming-soon {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    opacity: 0;
    transition: opacity 0.5s ease;
    pointer-events: none;
}

.projects-card.projects-card-disabled .card-coming-soon .title-box {
    opacity: 1;
    transition: none;
}

.projects-card.projects-card-disabled .card-coming-soon .title-box h3 {
    font-family: var(--font-tenor);
    font-weight: 400;
    font-size: clamp(0.8125rem, 1.042vw, 0.9375rem);
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--text-light);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
    line-height: 1;
    margin: 0;
}

.projects-card.projects-card-disabled:hover .card-coming-soon {
    opacity: 1;
}

/* ===================================================
   ABOUT PAGE
   =================================================== */
.about-main {
    width: 100%;
    background-color: var(--about-sand);
}

.about-main {
    display: grid;
    grid-template-columns: 40% 1fr;
    grid-template-rows: auto 1fr;
}

/* Hero bar runs the full width, as on Contact */
.about-main > .page-hero {
    grid-column: 1 / -1;
    grid-row: 1;
}

/* Photo: top meets the hero bar, bottom meets the footer, flush to the far left */
/* Photo starts under the hero bar and runs down to the footer, like Contact */
.about-main > .about-oval-frame {
    grid-column: 1;
    grid-row: 2;
    align-self: stretch;
    width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
}

.about-content-row {
    grid-column: 2;
    grid-row: 2;
    display: block;
    max-width: none;
    margin: 0;
    padding: 70px 60px 110px;
}

.about-oval-wrap {
    flex: 0 0 auto;
}

.about-oval-frame {
    width: clamp(220px, 30vw, 400px);
    height: auto;
    display: block;
}

.about-text-col {
    flex: 1;
    text-align: left;
}

.about-name {
    text-align: left;
    font-family: var(--font-montserrat);
    font-weight: 200;
    font-size: clamp(1.75rem, 3.1vw, 2.75rem);
    letter-spacing: 2px;
    line-height: 1.1;
    color: #000000;
    margin-bottom: 6px;
}

.about-role {
    font-family: var(--font-montserrat);
    font-weight: 200;
    font-size: clamp(0.95rem, 1.3vw, 1.15rem);
    letter-spacing: 3px;
    color: #000000;
    margin-bottom: 26px;
}

.about-bio {
    text-align: left;
    font-family: var(--font-montserrat);
    font-weight: 200;
    font-size: clamp(0.9375rem, 1.15vw, 1.0625rem);
    line-height: 1.9;
    color: var(--on-light-sand);
}

/* ===================================================
   CONTACT PAGE
   =================================================== */
.contact-main {
    width: 100%;
    background-color: var(--hero-colour); /* matches the page-hero band */
    padding-bottom: 0;
}

/* Bottom section: image (1/3) | contact details (top-aligned) | form,
   all on Dark Sand, sized to fit one screen beneath the hero bar */
.contact-bottom {
    margin: 0;
    display: flex;
    width: 100%;
    min-height: calc(100vh - 230px);
    background-color: var(--contact-sand);
}

.contact-bottom-image {
    flex: 0 0 33.333%;
    position: relative;
    overflow: hidden;
    margin: 0;
    min-height: 100%;
}

.contact-bottom-image img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.contact-bottom-form {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 50px clamp(24px, 6vw, 90px);
}

.contact-form {
    width: 100%;
    max-width: 600px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.form-field {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.form-field label {
    font-family: var(--font-montserrat);
    font-weight: 250;
    font-size: 0.8rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--on-light-sand);
}

.form-field input,
.form-field textarea {
    background-color: rgba(255, 255, 255, 0.35);
    border: 1px solid rgba(34, 20, 10, 0.45);
    border-radius: 2px;
    padding: 9px 12px;
    color: var(--on-light-sand);
    font-family: var(--font-montserrat);
    font-weight: 250;
    font-size: 0.9rem;
    resize: vertical;
}

.form-field input:focus,
.form-field textarea:focus {
    outline: none;
    border-color: var(--gold-accent);
}

.form-field input::placeholder,
.form-field textarea::placeholder {
    color: rgba(34, 20, 10, 0.55);
}

.form-submit-btn {
    align-self: center;
    margin-top: 6px;
    background-color: var(--gold-accent);
    color: var(--brand-dark);
    border: none;
    padding: 12px 40px;
    font-family: var(--font-montserrat);
    font-weight: 250;
    font-size: 0.85rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    cursor: pointer;
    border-radius: 2px;
    transition: opacity 0.3s ease;
}

.form-thanks {
    width: 100%;
    max-width: 600px;
    text-align: center;
    color: var(--on-light-sand);
}

.form-thanks[hidden] {
    display: none;
}

.form-thanks h3 {
    font-family: var(--font-montserrat);
    font-weight: 250;
    font-size: clamp(1.5rem, 2.4vw, 2rem);
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 10px;
}

.form-thanks p {
    font-family: var(--font-montserrat);
    font-weight: 250;
    font-size: clamp(1rem, 1.2vw, 1.125rem);
    line-height: 1.6;
}

.form-submit-btn:hover {
    opacity: 0.85;
}

/* ===================================================
   PRIVACY POLICY / LEGAL PAGE
   =================================================== */
.legal-main {
    width: 100%;
    background-color: var(--contact-sand);
}

.legal-content {
    max-width: 760px;
    margin: 0 auto;
    padding: 60px 30px 100px;
    font-family: var(--font-montserrat);
    font-weight: 200;
    color: var(--on-light-sand);
}

.legal-updated {
    font-size: 0.85rem;
    color: var(--on-light-sand);
    opacity: 0.8;
    margin-bottom: 30px;
}

.legal-content p {
    font-size: clamp(0.9375rem, 1.15vw, 1.0625rem);
    line-height: 1.9;
    margin-bottom: 20px;
}

.legal-content ul {
    margin: 0 0 20px 22px;
}

.legal-content li {
    font-size: clamp(0.9375rem, 1.15vw, 1.0625rem);
    line-height: 1.9;
    margin-bottom: 6px;
}

.legal-content h2 {
    font-family: var(--font-montserrat);
    font-weight: 200;
    font-size: 1.25rem;
    letter-spacing: 1.5px;
    color: var(--on-light-sand);
    margin: 35px 0 12px;
}

.legal-content a {
    color: var(--on-light-sand);
    text-decoration: underline;
}

.legal-content strong {
    font-weight: 200;
}

/* ===================================================
   RESPONSIVE: NEW PAGES
   =================================================== */
@media (max-width: 900px) {
    .page-hero {
        padding: 136px 20px 18px;
    }

    .prev-project-link,
    .next-project-link {
        position: static;
        display: inline-block;
        margin: 0 14px 22px;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .projects-listing-main {
        padding-top: 126px;
    }

    .about-main {
        grid-template-columns: 1fr;
        grid-template-rows: auto;
    }

    .about-main > .about-oval-frame {
        grid-column: 1;
        grid-row: auto;
        width: 100%;
        height: auto;
        min-height: 0;
        aspect-ratio: 4 / 5;
    }

    .about-main > .page-hero {
        grid-column: 1;
        grid-row: auto;
    }

    .about-content-row {
        grid-column: 1;
        grid-row: auto;
        text-align: center;
        padding: 30px 25px 80px;
    }

    .about-text-col {
        text-align: center;
    }

    .about-name {
        text-align: center;
    }

    .about-bio {
        text-align: center;
    }

    .contact-bottom {
        flex-direction: column;
        min-height: 0;
    }

    .contact-bottom-image {
        flex: 0 0 auto;
        aspect-ratio: 4 / 3;
    }

    .contact-bottom-form {
        padding: 40px 30px;
    }
}

/* ===================================================
   COOKIE CONSENT BANNER (site-wide, persists until answered)
   =================================================== */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: var(--cafe-noir);
    color: var(--text-light);
    padding: 18px 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    z-index: 2000;
    box-shadow: 0 -4px 15px rgba(0, 0, 0, 0.3);
    transition: transform 0.4s ease, opacity 0.4s ease;
    transform: translateY(0);
    opacity: 1;
}

.cookie-banner.cookie-hidden {
    transform: translateY(100%);
    opacity: 0;
    pointer-events: none;
}

.cookie-text {
    font-family: var(--font-center);
    font-weight: 400;
    font-size: 0.9rem;
    line-height: 1.4;
    max-width: 900px;
}

.cookie-privacy-link {
    color: var(--text-light);
    text-decoration: underline;
}

.cookie-actions {
    display: flex;
    gap: 12px;
    flex-shrink: 0;
}

.cookie-btn {
    font-family: var(--font-center);
    font-weight: 400;
    font-size: 0.85rem;
    padding: 10px 20px;
    border-radius: 4px;
    border: 1px solid var(--text-light);
    cursor: pointer;
    transition: all 0.2s ease;
}

.cookie-btn.btn-decline {
    background-color: transparent;
    color: var(--text-light);
}

.cookie-btn.btn-decline:hover {
    background-color: rgba(255, 255, 255, 0.15);
}

.cookie-btn.btn-accept {
    background-color: #ffffff;
    color: var(--cafe-noir);
}

.cookie-btn.btn-accept:hover {
    background-color: rgba(255, 255, 255, 0.85);
}

@media (max-width: 768px) {
    .cookie-banner {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
        padding: 16px;
    }

    .cookie-actions {
        justify-content: center;
        width: 100%;
    }

    .cookie-btn {
        flex: 1;
        padding: 10px 0;
    }
}

/*whole-image*/
/* Gallery images are shown whole (never cropped); any spare space is white, like the gaps between images */
.gallery-row .gallery-slot:nth-of-type(n) { background-color: #ffffff !important; }
.gallery-slot img.static-img, .gallery-slot img.fade-img { object-fit: contain; }

/*jia*/
/* Justified Image Arrangement: rows are shaped by justify.js (all screen sizes) */
.jia-wait .gallery-full-grid { visibility: hidden; }
.gallery-full-grid .gallery-row.jrow { flex-direction: row; aspect-ratio: var(--sum); }
.gallery-full-grid .gallery-row.jrow .gallery-slot { flex: calc(var(--ar) * 1000) 1 0; /* x1000 so a row with one portrait still fills the full width */ aspect-ratio: auto; min-width: 0; }
.gallery-full-grid .gallery-row.jrow .gallery-slot img { object-fit: cover; }

/*mobile-header*/
/* Phones have no hover, so the header is always shown on a white bar with dark text. Computers are unchanged. */
@media (max-width: 900px) {
    .main-header {
        position: sticky;
        top: 0;
        background-color: #ffffff;
        padding: 8px 14px;
        height: auto;
        transition: none;
    }
    .header-container {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: space-between;
        align-items: center;
        gap: 6px 12px;
    }
    .header-left { order: 1; }
    .header-right { order: 2; }
    .header-center {
        order: 3;
        position: static;
        transform: none;
        width: 100%;
        display: flex;
        justify-content: center;
    }
    .main-nav ul { gap: 26px; }
    .header-logo { height: 34px; filter: none !important; }
    .main-header .header-brand-name,
    .main-header .nav-link { color: var(--brand-dark) !important; }
    .main-header .scroll-fade,
    .main-header.hide-nav .scroll-fade { opacity: 1 !important; pointer-events: auto !important; }
    /* The header now sits in the page flow, so the pages no longer need space reserved under it */
    .page-hero { padding: 28px 20px 18px; }
    .projects-listing-main { padding-top: 0; }
}
