/* ==========================================================
   Glory Services - main stylesheet

   Mobile-first: the base styles are for phones. Media queries
   (min-width) further down add the layout for bigger screens.

   The look follows wetspot.com.au, which Mahdi asked for: a big
   photo at the top, an off-white page with white rounded cards,
   small "pill" labels above two-colour headings, and dark
   sections. The colours are Glory's own logo colours.
   ========================================================== */


/* ---------- 1. Variables ---------- */
:root {
    --color-ink: #161616;          /* headings, and text on light backgrounds */
    --color-text: #474747;         /* body text */
    --color-muted: #686868;        /* small print */
    --color-bg: #f4f4f2;           /* off-white page background */
    --color-white: #ffffff;        /* cards */
    --color-line: #e0e0dc;         /* thin divider lines */
    --color-dark: #171717;         /* dark sections */
    --color-darker: #0e0e0e;       /* footer */

    /* The two colours of the logo (images/logo/logo-mark.png) */
    --color-accent: #c80815;       /* red: buttons, and highlighted words on light backgrounds */
    --color-accent-dark: #a00611;  /* button hover */
    --color-blue: #6d8ae6;         /* blue: highlighted words on dark backgrounds */

    /* Cal Sans only comes in one weight. That's why headings use
       font-weight: 400; asking for bold would make the browser fake it.
       Its spaces are very narrow, so everything in Cal Sans also gets
       a little extra word-spacing ("Our work", not "Ourwork"). */
    --font-heading: "Cal Sans", system-ui, sans-serif;
    --heading-word-spacing: 0.12em;
    --font-body: "Golos Text", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

    --space-xs: 0.5rem;
    --space-s: 1rem;
    --space-m: 1.5rem;
    --space-l: 3rem;
    --space-xl: 5rem;

    --radius: 20px;                /* cards and photos */
    --radius-small: 10px;          /* form fields */
    --max-width: 1240px;
    --header-height: 84px;         /* room the top photo leaves for the header */
}


/* ---------- 2. Base ---------- */
*,
*::before,
*::after {
    box-sizing: border-box;
}

/* Smooth scrolling for the "scroll down" arrow, unless the visitor
   has asked their device for less movement */
@media (prefers-reduced-motion: no-preference) {
    html {
        scroll-behavior: smooth;
    }
}

/* Needed by Lenis, the smooth mouse-wheel scrolling (see js/main.js).
   Taken from Lenis's own lenis.css; its other rules are for features
   this site doesn't use. */
html.lenis,
html.lenis body {
    height: auto;
}

body {
    margin: 0;
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.65;
    color: var(--color-text);
    background: var(--color-bg);
}

img {
    display: block;
    max-width: 100%;
    height: auto;
}

h1,
h2,
h3 {
    margin: 0 0 var(--space-s);
    font-family: var(--font-heading);
    font-weight: 400;
    line-height: 1.1;
    word-spacing: var(--heading-word-spacing);
    color: var(--color-ink);
}

/* clamp(min, preferred, max): text grows with the screen width */
h1 {
    font-size: clamp(2.75rem, 8vw, 5.5rem);
    line-height: 1;
    text-transform: uppercase;
}

h2 { font-size: clamp(2rem, 5vw, 3.25rem); }
h3 { font-size: 1.4rem; }

p {
    margin: 0 0 var(--space-s);
}

a {
    color: var(--color-accent);
}

/* Outline shown when someone moves through the page with the
   Tab key. Dark sections switch --focus-color to white. */
:focus-visible {
    outline: 3px solid var(--focus-color, var(--color-accent));
    outline-offset: 3px;
}

/* Words in a heading shown in the logo colour, e.g. "Get a <span class="highlight">free</span> quote" */
.highlight {
    color: var(--color-accent);
}

/* Line icons drawn with SVG in the HTML. They take the text colour. */
.icon {
    flex-shrink: 0;
    width: 1.5rem;
    height: 1.5rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
}


/* ---------- 3. Layout helpers ---------- */
.container {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--space-s);
}

.section {
    padding: var(--space-l) 0;
}

@media (min-width: 640px) {
    .container {
        padding: 0 var(--space-m);
    }
}

@media (min-width: 1024px) {
    .section {
        padding: var(--space-xl) 0;
    }
}

/* 1 column on phones, 2 on tablets, 3 on desktop */
.grid {
    display: grid;
    gap: var(--space-m);
    margin-bottom: var(--space-l);
}

/* Photo grids (Home and Our work) already have 2 columns on phones,
   so the page is shorter to scroll. This rule must come before the
   media queries below, so they can still switch to 3 columns. */
.photo-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-s);
}

@media (min-width: 640px) {
    .grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .photo-grid {
        gap: var(--space-m);
    }
}

@media (min-width: 1024px) {
    .grid {
        grid-template-columns: repeat(3, 1fr);
    }

    /* 4 columns, for the service cards on the home page */
    .grid-4 {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Dark sections: top photo areas, the dark feature band, the
   call-to-action panel, the contact box and the footer */
.bg-dark {
    background: var(--color-dark);
    color: rgba(255, 255, 255, 0.82);
    --focus-color: var(--color-white);
}

.bg-dark h1,
.bg-dark h2,
.bg-dark h3 {
    color: var(--color-white);
}

.bg-dark .highlight {
    color: var(--color-blue);
}

/* Plain links on dark backgrounds are white. :where() keeps this rule
   weak, so classes like .btn-primary and .scroll-down still win. */
.bg-dark :where(a) {
    color: var(--color-white);
}

/* Yellow notes to Mahdi, marking content that's still missing.
   Replace the note with the real content and remove this class. */
.todo {
    background: #fef08a;
    color: #1a1a1a;
    padding: 0 0.25em;
}

/* "Preview for Mahdi" bar at the top of every page.
   Delete the banner <div> from each page before the site goes live. */
.preview-banner {
    padding: var(--space-xs) var(--space-s);
    background: #fef08a;
    color: #1a1a1a;
    font-size: 0.95rem;
    text-align: center;
}


/* ---------- 4. Section labels and intros ---------- */

/* Small label in a pill above a heading, with a red dot in front.
   justify-self and align-self stop it stretching inside a grid. */
.eyebrow {
    display: inline-flex;
    align-items: center;
    justify-self: start;
    align-self: start;
    gap: 0.5rem;
    margin: 0 0 var(--space-m);
    padding: 0.3rem 0.9rem;
    border: 1px solid var(--color-line);
    border-radius: 999px;
    background: var(--color-white);
    color: var(--color-ink);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.eyebrow::before {
    content: "";
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--color-accent);
}

.bg-dark .eyebrow {
    border-color: rgba(255, 255, 255, 0.25);
    background: transparent;
    color: var(--color-white);
}

/* Start of a section: label on the left, heading and text on the right
   (stacked on phones), under a thin line */
.intro {
    display: grid;
    gap: 0 var(--space-l);
    margin-bottom: var(--space-l);
    padding-top: var(--space-m);
    border-top: 1px solid var(--color-line);
}

.intro p:not(.eyebrow) {
    max-width: 42rem;
}

.intro p:last-child {
    margin-bottom: 0;
}

@media (min-width: 1024px) {
    .intro {
        grid-template-columns: 1fr 2.6fr;
        padding-top: var(--space-l);
    }
}


/* ---------- 5. Buttons and links ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    min-height: 48px;               /* big enough to tap on a phone */
    padding: 0.7rem 1.6rem;
    border: 2px solid transparent;
    border-radius: 999px;           /* pill shape */
    font-family: var(--font-heading);
    word-spacing: var(--heading-word-spacing);
    font-size: 1rem;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
}

.btn-primary {
    background: var(--color-accent);
    color: var(--color-white);
}

.btn-primary:hover {
    background: var(--color-accent-dark);
}

/* Black button, for light backgrounds */
.btn-dark {
    background: var(--color-ink);
    color: var(--color-white);
}

.btn-dark:hover {
    background: #3a3a3a;
}

/* Outlined button: dark on light backgrounds, white on dark ones */
.btn-outline {
    border-color: currentColor;
    background: transparent;
    color: var(--color-ink);
}

.btn-outline:hover {
    background: rgba(0, 0, 0, 0.05);
}

.bg-dark .btn-outline {
    color: var(--color-white);
}

.bg-dark .btn-outline:hover {
    background: rgba(255, 255, 255, 0.1);
}

/* Round red arrow at the end of a button, e.g. "More about us ↗" */
.btn-icon {
    display: grid;
    place-items: center;
    width: 2rem;
    height: 2rem;
    margin-right: -1rem;            /* sits closer to the button's edge */
    border-radius: 50%;
    background: var(--color-accent);
    color: var(--color-white);
}

/* Greyed out while the quote form is sending */
.btn:disabled {
    opacity: 0.6;
    cursor: wait;
}

.button-row {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-s);
}

/* "See all services →" style links */
.text-link {
    display: inline-block;
    padding: 0.5rem 0;              /* bigger tap area */
    color: var(--color-ink);
    font-family: var(--font-heading);
    word-spacing: var(--heading-word-spacing);
    font-size: 1.1rem;
    text-decoration-color: var(--color-accent);
    text-decoration-thickness: 2px;
    text-underline-offset: 6px;
}


/* ---------- 6. Header and navigation ---------- */

/* "Skip to main content" link for keyboard and screen reader users.
   It sits off-screen until it gets focus with the Tab key. */
.skip-link {
    position: absolute;
    top: -100px;
    left: var(--space-s);
    z-index: 30;
    padding: var(--space-xs) var(--space-s);
    background: var(--color-white);
    color: var(--color-ink);
    font-weight: 700;
}

.skip-link:focus {
    top: var(--space-s);
}

/* The header floats over the dark photo at the top of every page.
   "position: absolute" without a "top" keeps it where it would
   normally be (under the preview banner), but takes it out of the
   page flow, so the photo slides up underneath it. */
.site-header {
    position: absolute;
    left: 0;
    right: 0;
    z-index: 20;
    color: var(--color-white);
    --focus-color: var(--color-white);
}

.header-inner {
    display: flex;
    flex-wrap: wrap;               /* lets the open menu drop onto its own row */
    align-items: center;
    justify-content: space-between;
    gap: var(--space-xs) var(--space-s);
    min-height: var(--header-height);
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
}

/* Logo mark with the name next to it (header and footer) */
.logo {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    color: var(--color-white);
    font-family: var(--font-heading);
    word-spacing: var(--heading-word-spacing);
    font-size: 1.35rem;
    text-decoration: none;
}

.logo img {
    width: 44px;
}

.nav-toggle {
    min-height: 44px;
    padding: 0.5rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.3);
    color: var(--color-white);
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}

/* On phones the menu stays hidden until the Menu button is pressed.
   js/main.js adds the "is-open" class. */
.site-nav {
    display: none;
    width: 100%;
}

.site-nav.is-open {
    display: block;
}

.site-nav ul {
    margin: 0;
    padding: var(--space-s) var(--space-m);
    list-style: none;
    border-radius: var(--radius);
    background: var(--color-dark);
}

.nav-link {
    display: block;
    padding: 0.75rem 0;
    color: var(--color-white);
    font-family: var(--font-heading);
    word-spacing: var(--heading-word-spacing);
    font-size: 1.15rem;
    text-decoration: none;
}

.nav-link:hover {
    color: rgba(255, 255, 255, 0.7);
}

/* The page you're on: underlined in red */
.nav-link[aria-current="page"] {
    text-decoration: underline;
    text-decoration-color: var(--color-accent);
    text-decoration-thickness: 2px;
    text-underline-offset: 8px;
}

/* Quote and call buttons inside the phone menu */
.nav-cta .btn {
    width: 100%;
    margin-top: var(--space-xs);
}

.site-nav .btn-outline {
    color: var(--color-white);
}

/* Phone number and quote button on the right of the header.
   Wide screens only: phones get them in the menu instead. */
.header-actions {
    display: none;
}

.header-phone {
    display: none;
    align-items: center;
    gap: 0.6rem;
    color: var(--color-white);
    line-height: 1.25;
    text-decoration: none;
}

.header-phone small {
    display: block;
    font-size: 0.8rem;
    opacity: 0.8;
}

.header-phone strong {
    font-family: var(--font-heading);
    word-spacing: var(--heading-word-spacing);
    font-size: 1.1rem;
    font-weight: 400;
}

/* Wide screens: links in one row, no Menu button */
@media (min-width: 1024px) {
    .header-inner {
        flex-wrap: nowrap;
    }

    .nav-toggle,
    .nav-cta {
        display: none;
    }

    .site-nav {
        display: block;
        width: auto;
        margin-left: var(--space-l);
        margin-right: auto;        /* pushes the header actions to the right */
    }

    .site-nav ul {
        display: flex;
        gap: var(--space-m);
        padding: 0;
        background: none;
    }

    .nav-link {
        padding: 0.5rem 0;
        font-size: 1.05rem;
    }

    .header-actions {
        display: flex;
        align-items: center;
        gap: var(--space-m);
    }
}

/* The phone number only fits next to the menu on wider screens */
@media (min-width: 1200px) {
    .header-phone {
        display: flex;
    }
}


/* ---------- 7. Big photo at the top (Home) ---------- */
.hero {
    position: relative;
    display: flex;
    align-items: center;
    min-height: clamp(560px, 88vh, 880px);
    padding: calc(var(--header-height) + var(--space-l)) 0 var(--space-xl);
    overflow: hidden;
}

/* The job photo fills the whole area, behind the text.
   Also used by the page headers below. */
.hero-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Dark layer over the photo so the white text stays readable.
   It's darkest on the left, where the text is. */
.hero::after,
.page-header::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(10, 10, 10, 0.85) 0%, rgba(10, 10, 10, 0.6) 55%, rgba(10, 10, 10, 0.4) 100%);
}

/* Keeps the text above the photo and the dark layer */
.hero-content,
.page-header .container {
    position: relative;
    z-index: 1;
}

.hero h1 {
    max-width: 10em;
}

.hero-text {
    max-width: 38rem;
    margin-bottom: var(--space-l);
    font-size: clamp(1.15rem, 2.4vw, 1.5rem);
    color: rgba(255, 255, 255, 0.92);
}

/* White round "scroll down" arrow at the bottom of the photo */
.scroll-down {
    position: absolute;
    z-index: 1;
    left: 50%;
    bottom: var(--space-m);
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--color-white);
    color: var(--color-accent);
    font-size: 1.25rem;
    text-decoration: none;
    transform: translateX(-50%);
}

@media (min-width: 1024px) {
    .hero {
        padding-top: calc(var(--header-height) + var(--space-xl));
    }
}


/* ---------- 8. Page headers (top of every page except Home) ---------- */
.page-header {
    position: relative;
    padding: calc(var(--header-height) + var(--space-l)) 0 var(--space-l);
    overflow: hidden;
}

.page-header h1 {
    font-size: clamp(2.5rem, 7vw, 4.5rem);
}

.page-header p {
    max-width: 38rem;
    margin-bottom: var(--space-m);
    font-size: 1.15rem;
    color: rgba(255, 255, 255, 0.92);
}

@media (min-width: 1024px) {
    .page-header {
        padding: calc(var(--header-height) + var(--space-xl)) 0 var(--space-xl);
    }
}


/* ---------- 9. Cards ---------- */
.card {
    padding: var(--space-m);
    border-radius: var(--radius);
    background: var(--color-white);
}

/* Title and icon side by side, with a thin line under them */
.card-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: var(--space-s);
    margin-bottom: var(--space-s);
    padding-bottom: var(--space-s);
    border-bottom: 1px solid var(--color-line);
}

.card-head h2,
.card-head h3 {
    margin: 0;
}

.card-head .icon {
    width: 2.75rem;
    height: 2.75rem;
    color: var(--color-accent);
    stroke-width: 1.2;
}

.card p:last-child {
    margin-bottom: 0;
}


/* ---------- 10. Dark feature band (Home) ---------- */
.feature-dark {
    position: relative;
    overflow: hidden;
}

.feature-layout {
    position: relative;
    z-index: 1;                     /* above the faint brand name */
    display: grid;
    gap: var(--space-l);
    align-items: center;
}

.feature-photo {
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: cover;
    border-radius: var(--radius);
}

@media (min-width: 1024px) {
    .feature-layout {
        grid-template-columns: 1fr 1fr;
    }
}

/* Very large, faint brand name in the background. Decoration only:
   aria-hidden in the HTML stops screen readers reading it out. */
.watermark {
    position: absolute;
    left: var(--space-s);
    bottom: -0.2em;
    margin: 0;
    font-family: var(--font-heading);
    word-spacing: var(--heading-word-spacing);
    font-size: clamp(7rem, 26vw, 21rem);
    line-height: 1;
    color: rgba(255, 255, 255, 0.04);
    white-space: nowrap;
    pointer-events: none;
    user-select: none;
}

/* Ticked list, two columns from tablet size up */
.checklist {
    display: grid;
    gap: 0.6rem var(--space-m);
    margin: 0 0 var(--space-m);
    padding: 0;
    list-style: none;
}

.checklist li {
    display: flex;
    gap: 0.6rem;
    color: var(--color-ink);
    font-weight: 600;
}

.checklist li::before {
    content: "✓";
    color: var(--color-accent);
    font-weight: 700;
}

.bg-dark .checklist li {
    color: var(--color-white);
}

.bg-dark .checklist li::before {
    color: var(--color-blue);
}

@media (min-width: 640px) {
    .checklist {
        grid-template-columns: 1fr 1fr;
    }

    /* Next to a photo there's only room for one column */
    .split .checklist {
        grid-template-columns: 1fr;
    }
}


/* ---------- 11. Facts in big numbers ---------- */
.facts {
    display: grid;
    gap: var(--space-l) var(--space-m);
    margin: 0;
    padding: 0;
    list-style: none;
}

.fact-number {
    display: block;
    margin-bottom: var(--space-s);
    padding-bottom: var(--space-s);
    border-bottom: 1px solid var(--color-line);
    font-family: var(--font-heading);
    word-spacing: var(--heading-word-spacing);
    font-size: clamp(3rem, 6vw, 4.5rem);
    line-height: 1;
    color: var(--color-ink);
}

.fact-label {
    display: block;
    margin-bottom: 0.25rem;
    font-family: var(--font-heading);
    word-spacing: var(--heading-word-spacing);
    font-size: 1.3rem;
    color: var(--color-ink);
}

.fact-text {
    display: block;
    color: var(--color-muted);
}

@media (min-width: 480px) {
    .facts {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .facts {
        grid-template-columns: repeat(4, 1fr);
    }
}


/* ---------- 12. Job photos ---------- */
/* Every photo in a grid or next to text is cropped to the same 4:3 shape */
.grid img,
.split img,
.photo-placeholder {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: var(--radius);
}

.photo-placeholder {
    display: grid;
    place-items: center;
}

/* Our work page: each job is a <figure> with a link to the big copy */
.grid figure {
    margin: 0;
}

.grid figure a {
    position: relative;             /* for the "3 photos" label */
    display: block;
}

/* A job's extra photos are hidden links for the photo viewer. The rule
   above would show them, because it beats the browser's own [hidden] rule. */
.grid figure a[hidden] {
    display: none;
}

/* "3 photos" on the first photo of a job that has more */
.photo-count {
    position: absolute;
    right: 0.6rem;
    bottom: 0.6rem;
    padding: 0.2rem 0.65rem;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.65);
    color: var(--color-white);
    font-size: 0.8rem;
    font-weight: 600;
}

/* A job's title and short write-up under its photo */
.project figcaption {
    margin-top: var(--space-xs);
    font-size: 0.95rem;
}

.project-title {
    display: block;
    color: var(--color-ink);
    font-family: var(--font-heading);
    word-spacing: var(--heading-word-spacing);
    font-size: 1.05rem;
    font-weight: 400;
}

/* At most 3 lines here: the photo viewer shows the whole write-up */
.project-text {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    color: var(--color-muted);
}


/* ---------- 13. Photo + text side by side (Services, About) ---------- */
/* Stacked on phones, two columns on wider screens */
.split {
    display: grid;
    gap: var(--space-m) var(--space-l);
    align-items: center;
}

/* Small red number above each service, e.g. "01" */
.service-number {
    margin-bottom: var(--space-xs);
    font-family: var(--font-heading);
    word-spacing: var(--heading-word-spacing);
    font-size: 1.2rem;
    color: var(--color-accent);
}

/* Space between the services on the Services page */
.service-list > * + * {
    margin-top: var(--space-xl);
}

@media (min-width: 900px) {
    .split {
        grid-template-columns: 1fr 1fr;
    }

    /* Every second service has its photo on the right */
    .split-reverse > img {
        order: 2;
    }
}


/* ---------- 14. Steps ("How it works", Home) ---------- */
.steps {
    display: grid;
    gap: var(--space-m);
    margin: 0;
    padding: 0;
    list-style: none;
}

.step {
    position: relative;
    overflow: hidden;
    min-height: 14rem;
    padding: var(--space-m);
    border-radius: var(--radius);
    background: var(--color-white);
}

.step h3,
.step p {
    position: relative;             /* above the big faded number */
    z-index: 1;
}

/* Big faded number in the bottom corner of each step */
.step-number {
    position: absolute;
    right: var(--space-s);
    bottom: -0.12em;
    font-family: var(--font-heading);
    word-spacing: var(--heading-word-spacing);
    font-size: 6rem;
    line-height: 1;
    color: #ebebe7;
}

@media (min-width: 640px) {
    .steps {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Desktop: four in a row, each a little lower than the one before */
@media (min-width: 1024px) {
    .steps {
        grid-template-columns: repeat(4, 1fr);
        align-items: start;
    }

    .step:nth-child(2) { margin-top: 3rem; }
    .step:nth-child(3) { margin-top: 6rem; }
    .step:nth-child(4) { margin-top: 9rem; }
}


/* ---------- 15. Call-to-action panel (bottom of most pages) ---------- */
.cta-panel {
    position: relative;
    overflow: hidden;
    padding: var(--space-l) var(--space-m);
    border-radius: var(--radius);
    text-align: center;
}

/* Keeps the text and buttons above the faint brand name */
.cta-panel > :not(.watermark) {
    position: relative;
    z-index: 1;
}

.cta-panel .button-row {
    justify-content: center;
}

.cta-panel .watermark {
    left: 50%;
    transform: translateX(-50%);
}

@media (min-width: 1024px) {
    .cta-panel {
        padding: var(--space-xl) var(--space-l);
    }
}


/* ---------- 16. Footer ---------- */
.site-footer {
    padding: var(--space-xl) 0 var(--space-m);
    background: var(--color-darker);
    font-size: 0.95rem;
}

.footer-grid {
    display: grid;
    gap: var(--space-l);
}

.footer-about .logo {
    margin-bottom: var(--space-s);
}

.footer-about p {
    max-width: 24rem;
}

.footer-heading {
    margin-bottom: var(--space-s);
    font-size: 1.15rem;
}

.footer-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.footer-list li {
    margin-bottom: var(--space-xs);
}

.footer-bottom {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: var(--space-xs) var(--space-m);
    margin-top: var(--space-l);
    padding-top: var(--space-m);
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    color: rgba(255, 255, 255, 0.6);
}

.footer-bottom p {
    margin: 0;
}

@media (min-width: 640px) {
    .footer-grid {
        grid-template-columns: 2fr 1.5fr 1fr;
    }
}


/* ---------- 17. Contact page and quote form ---------- */
.contact-layout {
    display: grid;
    gap: var(--space-m);
}

/* Wide screens: form on the left, contact details on the right */
@media (min-width: 1024px) {
    .contact-layout {
        grid-template-columns: 1.6fr 1fr;
        align-items: start;
    }
}

.quote-form {
    padding: var(--space-m);
    border-radius: var(--radius);
    background: var(--color-white);
}

@media (min-width: 640px) {
    .quote-form {
        padding: var(--space-l);
    }
}

.form-field {
    margin-bottom: var(--space-m);
}

.form-field label {
    display: block;
    margin-bottom: 0.3rem;
    color: var(--color-ink);
    font-weight: 600;
}

.optional {
    font-weight: 400;
    color: var(--color-muted);
}

.field-hint {
    margin: 0 0 var(--space-xs);
    color: var(--color-muted);
    font-size: 0.95rem;
}

/* font-size of at least 16px stops iPhones zooming in when a field is tapped.
   The border is dark enough to see clearly (3:1 contrast or more). */
.form-field input,
.form-field select,
.form-field textarea {
    width: 100%;
    min-height: 48px;
    padding: 0.7rem 0.9rem;
    border: 1.5px solid #8c8c88;
    border-radius: var(--radius-small);
    background: var(--color-white);
    color: var(--color-ink);
    font: inherit;
    font-size: 1rem;
}

.form-field textarea {
    resize: vertical;
}

/* Spam trap field: hidden from people (see contact.html) */
.botcheck {
    display: none;
}

.form-status {
    margin: var(--space-s) 0 0;
    font-weight: 700;
}

.contact-details {
    padding: var(--space-m);
    border-radius: var(--radius);
}

@media (min-width: 640px) {
    .contact-details {
        padding: var(--space-l);
    }
}

/* One line per way to reach us: icon, small label, then the details */
.contact-list {
    margin: 0 0 var(--space-m);
    padding: 0;
    list-style: none;
}

.contact-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.9rem;
    margin-bottom: var(--space-s);
}

.contact-list .icon {
    margin-top: 0.2rem;
    color: var(--color-blue);
}

.contact-list small {
    display: block;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.8rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}


/* ---------- 18. About page: company details ---------- */
/* <dl> is a list of label (dt) + value (dd) pairs. Each pair is
   wrapped in a <div> so it can be shown as a card. */
.details {
    display: grid;
    gap: var(--space-m);
    margin: 0;
}

.details div {
    padding: var(--space-m);
    border-radius: var(--radius);
    background: var(--color-white);
}

.details dt {
    color: var(--color-muted);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.details dd {
    margin: 0.25rem 0 0;
    font-family: var(--font-heading);
    word-spacing: var(--heading-word-spacing);
    font-size: 1.3rem;
    color: var(--color-ink);
}

@media (min-width: 640px) {
    .details {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* 3 columns: company, ABN and licence on top; location and areas below */
@media (min-width: 1024px) {
    .details {
        grid-template-columns: repeat(3, 1fr);
    }
}


/* ---------- 19. Call and quote bar (phones and tablets) ---------- */
/* Stays at the bottom of the screen, so calling is always one tap away.
   Wide screens don't need it: the header has the same buttons there. */
.mobile-bar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 25;                    /* above the header (20) */
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-xs);
    padding: var(--space-xs) var(--space-s);
    /* env(...) is the iPhone's home-bar area, so the buttons sit above it */
    padding-bottom: calc(var(--space-xs) + env(safe-area-inset-bottom));
    box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.15);
}

.mobile-bar .btn {
    padding-left: var(--space-s);
    padding-right: var(--space-s);
}

/* While someone is typing in the quote form, hide the bar so it
   can't cover the field they're filling in */
body:has(.quote-form:focus-within) .mobile-bar {
    display: none;
}

/* Extra space at the bottom of the footer, so the bar never covers it */
.site-footer {
    padding-bottom: calc(var(--space-m) + 5rem);
}

/* The ↓ arrow on the home page photo sits higher, clear of the bar */
.scroll-down {
    bottom: calc(var(--space-m) + 4rem);
}

@media (min-width: 1024px) {
    .mobile-bar {
        display: none;
    }

    .site-footer {
        padding-bottom: var(--space-m);
    }

    .scroll-down {
        bottom: var(--space-m);
    }
}


/* ---------- 20. Photo viewer (Our work) ---------- */
/* A full-screen <dialog> that shows one photo at a time (js/gallery.js) */
.lightbox {
    width: 100%;
    max-width: none;
    height: 100%;
    max-height: none;
    margin: 0;
    padding: 4.5rem var(--space-s);   /* room for the round buttons */
    border: 0;
    background: rgba(14, 14, 14, 0.96);
    color: var(--color-white);
    overscroll-behavior: contain;     /* swiping doesn't scroll the page behind */
    --focus-color: var(--color-white);
}

/* Only while it's open: a closed <dialog> must stay hidden */
.lightbox[open] {
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox::backdrop {
    background: transparent;          /* the dialog itself is the dark layer */
}

.lightbox-figure {
    margin: 0;
    text-align: center;
}

.lightbox-image {
    max-width: 100%;
    max-height: calc(100vh - 12rem);  /* leaves room for the caption and buttons */
    margin: 0 auto;
    border-radius: var(--radius);
}

.lightbox-caption {
    max-width: 40rem;
    margin: var(--space-s) auto 0;
    color: rgba(255, 255, 255, 0.82);
    font-size: 0.95rem;
}

/* Job title, write-up and "Photo 4 of 31", each on its own line */
.lightbox-caption strong,
.lightbox-caption span {
    display: block;
}

.lightbox-caption strong {
    color: var(--color-white);
    font-family: var(--font-heading);
    word-spacing: var(--heading-word-spacing);
    font-size: 1.1rem;
    font-weight: 400;
}

.lightbox-caption span:last-child {
    margin-top: 0.35rem;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.85rem;
}

/* Round buttons: close at the top right, previous and next at the bottom */
.lightbox-close,
.lightbox-prev,
.lightbox-next {
    position: absolute;
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    color: var(--color-white);
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
}

.lightbox-close:hover,
.lightbox-prev:hover,
.lightbox-next:hover {
    background: rgba(255, 255, 255, 0.2);
}

.lightbox-close {
    top: var(--space-s);
    right: var(--space-s);
}

.lightbox-prev {
    bottom: var(--space-s);
    left: var(--space-s);
}

.lightbox-next {
    bottom: var(--space-s);
    right: var(--space-s);
}

/* Wide screens: previous and next halfway down the sides */
@media (min-width: 1024px) {
    .lightbox {
        padding: 4.5rem 6rem;
    }

    .lightbox-prev,
    .lightbox-next {
        top: 50%;
        bottom: auto;
        transform: translateY(-50%);
    }

    .lightbox-prev {
        left: var(--space-m);
    }

    .lightbox-next {
        right: var(--space-m);
    }
}
