/* ==========================================================================
   ACS RWANDA — "GROUND TRUTH" UI LIBRARY
   Editorial dark aesthetic grounded in geotechnical subject matter:
   soil strata, boreholes, depth readings.

   FILE ORDER — keep new rules in their section.
     1.  Variables      — design tokens, the single source of truth
     2.  Reset & base
     3.  Typography     — .eyebrow .hero-heading .section-heading .card-heading
                          .lead .body-text .small-text
     4.  Layout         — .container .section .section-header .grid .grid-2..4
     5.  Utilities      — single-purpose helpers
     6.  Components     — .btn .card .icon .image-* .link-arrow .feature-list
     7.  Header         — top bar, navbar, mobile menu
     8.  Hero
     8b. Page header   — banner for sub-pages
     9.  Trust / stats
     10. About
     11. Services
     11b. Featured Projects
     11c. Why Choose ACS
     11d. Clients & Partners
     11e. Contact page
     12. Footer
     13. Animations     — reveal primitive + @keyframes
     14. Media queries  — ALL responsive rules live here

   TWO RULES THAT KEEP THIS A LIBRARY
     1. No raw colors, spacing, radii, shadows or durations below section 1.
        If a value is missing, add a token — never a literal.
     2. Sections (7-12) position and compose components. They never restyle
        one. A section needing a new look gets a component *variant*, and
        variants are built by overriding the --btn-* / --card-* knobs rather
        than redeclaring background, border, padding or hover.
   ========================================================================== */


/* ==========================================================================
   1. VARIABLES
   ========================================================================== */
:root {

    /* ---- Raw palette -------------------------------------------------
       The brand's actual pigments. Never referenced directly outside this
       block — always go through the semantic aliases below.             */
    --ink: #0D0C0A;              /* near-black warm charcoal */
    --ink-soft: #16140F;         /* secondary dark surface */
    --cream: #EDE6D5;            /* high-contrast text on dark */
    --stone: #9C9384;            /* muted body text on dark */
    --paper: #F6F3EC;            /* warm off-white */
    --charcoal: #221F1A;         /* headline text on light */
    --slate: #6B6459;            /* body text on light */
    --clay: #C1602C;             /* primary accent */
    --clay-dark: #A34E22;
    --gold: #B8933F;             /* secondary accent */
    --moss: #5C7A52;             /* status: positive */
    --sand: #C9A66B;             /* status: caution */

    /* ---- Semantic colors — the public API ---------------------------- */
    --primary-color: var(--clay);
    --primary-hover: var(--clay-dark);
    --secondary-color: var(--gold);

    --text-light: var(--cream);      /* headings on dark surfaces */
    --text-muted: var(--stone);      /* body copy on dark surfaces */
    --text-dark: var(--charcoal);    /* headings on light surfaces */
    --text-slate: var(--slate);      /* body copy on light surfaces */

    --background-dark: var(--ink);
    --background-light: var(--paper);
    --logo-chip: #FFFFFF;            /* white chip behind partner logos */
    --surface: var(--ink);           /* default component surface */
    --surface-alt: var(--ink-soft);  /* raised / nested surface */
    --surface-hover: rgba(237, 230, 213, 0.06);

    --success: var(--moss);
    --warning: var(--sand);

    /* hairlines, derived from --cream so they read as light-on-dark */
    --border-color: rgba(237, 230, 213, 0.12);
    --border-soft: rgba(237, 230, 213, 0.08);
    --border-strong: rgba(237, 230, 213, 0.30);

    /* strata illustration tones */
    --strata-1: #3D3226;
    --strata-2: #8B5E34;
    --strata-3: #C9A66B;
    --strata-4: #4A4640;

    /* ---- Typography --------------------------------------------------- */
    --font-heading: 'Fraunces', serif;
    --font-body: 'Inter', sans-serif;

    /* fluid where it matters, fixed where it must stay legible */
    --fs-2xs: 10px;   /* scroll label, borehole depth ticks */
    --fs-xs: 11px;    /* top bar, strata labels */
    --fs-sm: 13px;    /* eyebrow labels */
    --fs-md: 14px;    /* nav links, meta, small UI */
    --fs-btn: 14.5px; /* button label */
    --fs-card: 15.5px;/* card body copy */
    --fs-base: clamp(1rem, 0.4vw + 0.9rem, 1.12rem);
    --fs-lg: 17px;    /* intro / lead paragraphs */
    --fs-h3: clamp(1.3rem, 1.1vw + 1rem, 1.55rem);
    --fs-xl: clamp(1.9rem, 2.6vw, 2.9rem);          /* section headings */
    --fs-page: clamp(2.2rem, 1.4rem + 2.6vw, 3.3rem);/* sub-page title */
    --fs-xxl: clamp(2.6rem, 4.5vw + 1rem, 4.6rem);  /* hero heading */
    --fs-stat: clamp(1.8rem, 2.4vw, 2.4rem);
    --fs-menu: 1.6rem;  /* mobile menu links */

    --fw-light: 300;
    --fw-regular: 400;
    --fw-medium: 500;
    --fw-semibold: 600;

    --lh-tight: 1.12;
    --lh-heading: 1.2;
    --lh-body: 1.7;
    --lh-copy: 1.75;
    --tracking-label: 3px;
    --tracking-caps: 2.5px;
    --tracking-tick: 1.5px;
    --tracking-wide: 0.3px;

    /* line length — override per context via --measure */
    --measure-heading: 620px;
    --measure-copy: 560px;

    /* ---- Spacing (4px base) ------------------------------------------- */
    --space-2xs: 4px;
    --space-xs: 8px;
    --space-sm: 12px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 32px;
    --space-2xl: 48px;
    --space-3xl: 64px;
    --space-4xl: 96px;

    /* vertical rhythm shared by every section */
    --space-section: clamp(88px, 10vw, 140px);
    --space-head: clamp(48px, 6vw, 80px);   /* section-header -> content */
    --space-heading: var(--space-lg);       /* between stacked heading parts */

    /* ---- Radius -------------------------------------------------------- */
    --radius-sm: 4px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-pill: 999px;

    /* ---- Shadows ------------------------------------------------------- */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.28);
    --shadow-md: 0 14px 34px rgba(0, 0, 0, 0.40);
    --shadow-lg: 0 26px 60px rgba(0, 0, 0, 0.50);
    --shadow-accent: 0 12px 28px rgba(193, 96, 44, 0.30);
    --shadow-logo: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.5));

    /* ---- Motion --------------------------------------------------------- */
    --ease: cubic-bezier(0.4, 0, 0.2, 1);
    --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
    --ease-drill: cubic-bezier(0.65, 0, 0.35, 1);
    --transition-fast: 0.2s var(--ease);
    --transition: 0.3s var(--ease);          /* every hover, everywhere */
    --transition-slow: 0.6s var(--ease);     /* image zoom only — see §6 */
    --transition-reveal: 0.7s var(--ease-out);

    /* ---- Hover system — one vocabulary for every interactive response --- */
    --lift-sm: -2px;      /* buttons, logo */
    --lift-md: -6px;      /* cards */
    --nudge: 4px;         /* inline link arrows */
    --img-zoom: 1.05;     /* every image zoom, everywhere */

    /* ---- Icons ---------------------------------------------------------- */
    --icon-sm: 11px;
    --icon-md: 15px;
    --icon-lg: 16px;
    --icon-xl: 24px;

    /* ---- Layout --------------------------------------------------------- */
    --max-width: 1400px;
    --gutter: min(92%, var(--max-width));
    --nav-h: 74px;
    --nav-gap: 34px;
    --card-media-h: 220px;
}


/* ==========================================================================
   2. RESET & BASE
   ========================================================================== */
* { margin: 0; padding: 0; box-sizing: border-box; }

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--nav-h) + var(--space-lg));
}

body {
    font-family: var(--font-body);
    font-size: var(--fs-base);
    line-height: var(--lh-body);
    color: var(--text-light);
    background: var(--background-dark);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { display: block; max-width: 100%; height: auto; }
button { font: inherit; color: inherit; }

/* keyboard focus stays visible everywhere, on one accent */
:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: 3px;
    border-radius: var(--radius-sm);
}


/* ==========================================================================
   3. TYPOGRAPHY
   Seven text roles. No section below styles a font-size directly — if none
   of these fit, add a role here rather than a one-off rule.
   ========================================================================== */

/* ---- Headings -------------------------------------------------------- */
.hero-heading,
.section-heading,
.card-heading,
.stat-heading {
    font-family: var(--font-heading);
    font-weight: var(--fw-medium);
    color: var(--text-light);
}

.hero-heading {
    font-size: var(--fs-xxl);
    line-height: var(--lh-tight);
    letter-spacing: -0.5px;
    font-optical-sizing: auto;
}
.hero-heading em {
    font-style: italic;
    color: var(--strata-3);
}

.section-heading {
    font-size: var(--fs-xl);
    line-height: var(--lh-heading);
    max-width: var(--measure, var(--measure-heading));
}

.card-heading {
    font-size: var(--fs-h3);
    line-height: var(--lh-heading);
}

/* numeric display — .stat-card's headline */
.stat-heading {
    font-size: var(--fs-stat);
    font-variant-numeric: tabular-nums;  /* stops count-up from jittering */
    transition: color var(--transition);
}

/* ---- Body copy --------------------------------------------------------
   .lead      intro paragraph under a heading
   .body-text default paragraph inside cards and dense blocks
   .small-text meta, labels, captions                                     */
.lead {
    font-size: var(--lead-fs, var(--fs-lg));
    color: var(--text-muted);
    max-width: var(--measure, var(--measure-copy));
}

.body-text {
    font-size: var(--fs-card);
    line-height: var(--lh-copy);
    color: var(--text-muted);
}

.small-text {
    font-size: var(--fs-md);
    font-weight: var(--fw-medium);
    letter-spacing: var(--tracking-wide);
    color: var(--text-muted);
}

/* ---- Labels ----------------------------------------------------------- */
.eyebrow {
    display: inline-block;
    color: var(--secondary-color);
    font-size: var(--fs-sm);
    font-weight: var(--fw-medium);
    letter-spacing: var(--tracking-label);
    text-transform: uppercase;
}

/* tighter, quieter caps — nav strip, scroll cue, depth readouts */
.label-caps {
    font-size: var(--fs-xs);
    font-weight: var(--fw-medium);
    letter-spacing: var(--tracking-caps);
    text-transform: uppercase;
}


/* ==========================================================================
   4. LAYOUT
   ========================================================================== */
.container {
    width: var(--gutter);
    margin-inline: auto;
}

/* Every section inherits the same vertical rhythm — no per-section padding. */
.section {
    padding: var(--space-section) 0;
    background: var(--background-dark);
    border-top: 1px solid var(--border-soft);
}

/* alternate band — for CTA / testimonial sections that need separation */
.section-alt { background: var(--surface-alt); }

/* eyebrow -> heading -> lead, with one gap to the content that follows */
.section-header {
    max-width: 760px;
    margin-bottom: var(--space-head);
}
.section-header > * + * { margin-top: var(--space-heading); }

.section-header.centered {
    text-align: center;
    margin-inline: auto;
}
.section-header.centered .section-heading,
.section-header.centered .lead { margin-inline: auto; }

/* Grid primitives. The gap is shared; only the column count varies. */
.grid {
    display: grid;
    gap: var(--space-lg);
}
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }


/* ==========================================================================
   5. UTILITIES
   ========================================================================== */
.flex        { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-col    { flex-direction: column; }
.items-center{ align-items: center; }
.wrap        { flex-wrap: wrap; }

.text-center { text-align: center; }
.hidden      { display: none !important; }
.no-select   { pointer-events: none; }
.stack-tight { gap: var(--space-xs); }
.stack       { gap: var(--space-md); }
.stack-loose { gap: var(--space-lg); }

/* row of buttons — hero, CTA bands, anywhere actions cluster */
.actions { display: flex; flex-wrap: wrap; gap: var(--space-md); }
.actions.centered { justify-content: center; }

/* visible to screen readers only */
.sr-only {
    position: absolute;
    width: 1px; height: 1px;
    margin: -1px; padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}


/* ==========================================================================
   6. COMPONENTS
   ========================================================================== */

/* ---- Button ----------------------------------------------------------
   .btn carries geometry + motion. Colour variants set colour only; size
   variants retune the three --btn-* knobs. The two compose freely, so
   .btn.btn-outline.btn-sm needs no extra rule.                           */
.btn {
    --btn-py: 15px;
    --btn-px: 32px;
    --btn-fs: var(--fs-btn);

    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-xs);
    padding: var(--btn-py) var(--btn-px);
    border: 1px solid transparent;
    border-radius: var(--radius-sm);
    font-family: var(--font-body);
    font-size: var(--btn-fs);
    font-weight: var(--fw-semibold);
    letter-spacing: 0.2px;
    line-height: 1;
    cursor: pointer;
    transition: background var(--transition), border-color var(--transition),
                color var(--transition), transform var(--transition),
                box-shadow var(--transition);
}
.btn:hover { transform: translateY(var(--lift-sm)); }

.btn-primary {
    background: var(--primary-color);
    color: var(--text-light);
    box-shadow: var(--shadow-sm);
}
.btn-primary:hover {
    background: var(--primary-hover);
    box-shadow: var(--shadow-accent);
}

.btn-outline {
    background: transparent;
    color: var(--text-light);
    border-color: var(--border-strong);
    font-weight: var(--fw-medium);
}
.btn-outline:hover {
    border-color: var(--text-light);
    background: var(--surface-hover);
}

.btn-dark {
    background: var(--surface-alt);
    color: var(--text-light);
    border-color: var(--border-color);
}
.btn-dark:hover {
    background: var(--surface-hover);
    border-color: var(--border-strong);
}

/* for use on light bands — a footer or an inverted CTA */
.btn-light {
    background: var(--background-light);
    color: var(--text-dark);
    box-shadow: var(--shadow-sm);
}
.btn-light:hover {
    background: var(--text-light);
    box-shadow: var(--shadow-md);
}

/* dashed ghost — a quiet CTA for dense bars */
.btn-ghost {
    background: transparent;
    color: var(--text-light);
    border: 1px dashed var(--border-strong);
    font-weight: var(--fw-medium);
    letter-spacing: var(--tracking-wide);
}
.btn-ghost:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    background: rgba(193, 96, 44, 0.08);
}

.btn-sm    { --btn-py: 12px; --btn-px: 26px; --btn-fs: var(--fs-md); }
.btn-lg    { --btn-py: 18px; --btn-px: 40px; --btn-fs: var(--fs-lg); }
.btn-block { width: 100%; }

/* ---- Card -------------------------------------------------------------
   One surface for every card on the site. Variants override the --card-*
   knobs instead of redeclaring background / border / padding / hover.    */
.card {
    --card-bg: var(--surface);
    --card-border: 1px solid var(--border-color);
    --card-border-hover: var(--border-strong);
    --card-radius: var(--radius-md);
    --card-pad: var(--space-xl);
    --card-lift: var(--lift-md);
    --card-shadow: var(--shadow-md);

    background: var(--card-bg);
    border: var(--card-border);
    border-radius: var(--card-radius);
    overflow: hidden;
    transition: transform var(--transition), box-shadow var(--transition),
                border-color var(--transition), background var(--transition);
}
.card:hover {
    transform: translateY(var(--card-lift));
    box-shadow: var(--card-shadow);
    border-color: var(--card-border-hover);
}

/* padding lives on the body so full-bleed media can sit flush against the
   card edge. One value on all four sides — see the card-spacing note in §11. */
.card-body { padding: var(--card-pad); }

/* media at the top of a card — .service-card and .project-card share it */
.card-media {
    height: var(--card-media-h);
    width: 100%;
    object-fit: cover;
}

/* ---- Card variants ----------------------------------------------------
   Each is a handful of knob overrides. .project-card and .testimonial-card
   are declared ahead of the sections that will use them.                 */

/* borderless — reads as a grid cell, not a raised surface.
   --card-border-hover stays at the resting colour so variants drawing their
   own rails (the stat divider) don't lose them on hover. */
.stat-card {
    --card-bg: transparent;
    --card-border: none;
    --card-border-hover: var(--border-color);
    --card-radius: 0;
    --card-lift: 0;
    --card-shadow: none;
}

/* image-led card — same surface as .service-card, taller media */
.project-card { --card-media-h: 260px; }

/* quote card — no media, raised surface, no lift so quotes read as static */
.testimonial-card {
    --card-bg: var(--surface-alt);
    --card-lift: 0;
    --card-pad: var(--space-2xl);
}

/* static panel — a card that holds content (a form, a callout) without the
   hover lift/border-brighten. Used for the contact form. */
.card-static {
    --card-lift: 0;
    --card-border-hover: var(--border-color);
    --card-shadow: var(--shadow-md);
}

/* ---- Icon -------------------------------------------------------------- */
.icon    { font-size: var(--icon-md); line-height: 1; }
.icon-sm { font-size: var(--icon-sm); }
.icon-lg { font-size: var(--icon-lg); }
.icon-xl { font-size: var(--icon-xl); }
.icon-accent { color: var(--primary-color); }

/* ---- Icon badge — medallion holding an icon (feature cards, CTA) ------- */
.icon-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    border-radius: var(--radius-md);
    background: var(--surface-alt);
    border: 1px solid var(--border-color);
    color: var(--primary-color);
    transition: border-color var(--transition), color var(--transition);
}
/* picks up the shared card hover, like .stat-heading does */
.card:hover .icon-badge { border-color: var(--border-strong); }

/* ---- Image -------------------------------------------------------------
   .image-hover zooms when its .card or .image-frame ancestor is hovered —
   one zoom value site-wide, so every image feels like the same interaction.
   Image zoom is the one hover that keeps --transition-slow: at 1.05 scale a
   0.3s zoom reads as a jolt. Change --transition-slow to unify if preferred. */
.image-cover {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.image-contain { width: 100%; object-fit: contain; }
.image-rounded { border-radius: var(--radius-md); }
.image-shadow  { box-shadow: var(--shadow-md); }

.image-frame {
    position: relative;
    overflow: hidden;
}
.image-hover { transition: transform var(--transition-slow), filter var(--transition-slow); }
.card:hover .image-hover,
.image-frame:hover .image-hover { transform: scale(var(--img-zoom)); }

/* muted until touched — used on service imagery */
.image-muted { filter: grayscale(15%); }
.card:hover .image-muted,
.image-frame:hover .image-muted { filter: grayscale(0%); }

/* ---- Inline "read more" link with a nudging arrow ----------------------- */
.link-arrow {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    color: var(--primary-color);
    font-size: var(--fs-md);
    font-weight: var(--fw-semibold);
    letter-spacing: 0.2px;
}
.link-arrow i { transition: transform var(--transition); }
.link-arrow:hover i { transform: translateX(var(--nudge)); }

/* ---- Card badge — small label over card media (projects, gallery) ------- */
.card-badge {
    position: absolute;
    top: var(--space-md);
    left: var(--space-md);
    z-index: 1;
    padding: 6px var(--space-sm);
    background: rgba(13, 12, 10, 0.72);
    backdrop-filter: blur(4px);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-pill);
    color: var(--secondary-color);
    font-size: var(--fs-xs);
    font-weight: var(--fw-medium);
    letter-spacing: var(--tracking-caps);
    text-transform: uppercase;
}

/* ---- Card meta — icon + text row (location, date, client) --------------- */
.card-meta {
    display: flex;
    align-items: center;
    gap: var(--space-xs);
}
.card-meta i { color: var(--secondary-color); }

/* ---- Feature list — checkmark rows -------------------------------------- */
.feature-list {
    display: flex;
    flex-direction: column;
    border-top: 1px solid var(--border-color);
}
.feature {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    padding: var(--space-md) 0;
    border-bottom: 1px solid var(--border-color);
    font-weight: var(--fw-medium);
    color: var(--text-light);
}

/* ---- Form controls ------------------------------------------------------
   Dark-surface inputs. Focus brightens the border; the global :focus-visible
   ring still handles keyboard users. Reusable by any form (contact, quote). */
.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-lg);
}
.field { display: flex; flex-direction: column; gap: var(--space-xs); }
.field.full { grid-column: 1 / -1; }
.field label {
    font-size: var(--fs-md);
    font-weight: var(--fw-medium);
    color: var(--text-light);
    letter-spacing: var(--tracking-wide);
}
.field label .req { color: var(--primary-color); }

.input, .select, .textarea {
    width: 100%;
    padding: 13px var(--space-md);
    background: var(--surface-alt);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-light);
    font-family: var(--font-body);
    font-size: var(--fs-card);
    transition: border-color var(--transition), background var(--transition);
}
.input::placeholder, .textarea::placeholder { color: var(--text-muted); opacity: 0.7; }
.input:focus, .select:focus, .textarea:focus {
    border-color: var(--primary-color);
    background: var(--surface);
}
.textarea { min-height: 150px; resize: vertical; line-height: var(--lh-body); }

/* custom chevron for the select (native arrow hidden) */
.select {
    appearance: none;
    -webkit-appearance: none;
    padding-right: var(--space-2xl);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='none' stroke='%239C9384' stroke-width='1.5' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right var(--space-md) center;
    cursor: pointer;
}
.select option { background: var(--ink); color: var(--text-light); }

/* small status line shown after submit */
.form-status {
    margin-top: var(--space-md);
    font-size: var(--fs-md);
    line-height: var(--lh-body);
    color: var(--text-muted);
}
.form-status.error { color: var(--warning); }

/* ---- Contact list — icon medallion + label/value rows ------------------- */
.contact-list { display: flex; flex-direction: column; gap: var(--space-lg); }
.contact-item { display: flex; align-items: flex-start; gap: var(--space-md); }
.contact-item .icon-badge { flex-shrink: 0; }
.contact-item .label {
    display: block;
    margin-bottom: 2px;
    font-size: var(--fs-sm);
    font-weight: var(--fw-medium);
    letter-spacing: var(--tracking-wide);
    text-transform: uppercase;
    color: var(--text-muted);
}
.contact-item .value { color: var(--text-light); font-size: var(--fs-card); line-height: var(--lh-body); }
.contact-item a.value { transition: color var(--transition); }
.contact-item a.value:hover { color: var(--primary-color); }

/* ---- Depth tick — the borehole readout, shared by hero + strata ---------- */
.depth-tick {
    position: absolute;
    color: var(--text-muted);
    font-size: var(--fs-xs);
    letter-spacing: var(--tracking-tick);
    text-transform: uppercase;
    white-space: nowrap;
}
.depth-tick .value {
    color: var(--text-light);
    font-weight: var(--fw-semibold);
}


/* ==========================================================================
   7. HEADER — sticky, transparent over hero -> solid on scroll
   ========================================================================== */
.site-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: transparent;
    transition: background var(--transition), box-shadow var(--transition),
                backdrop-filter var(--transition);
}
.site-nav.scrolled {
    background: rgba(13, 12, 10, 0.90);
    backdrop-filter: blur(10px);
    box-shadow: 0 1px 0 var(--border-soft), var(--shadow-sm);
}

/* utility tagline strip — collapses away once scrolled */
.top-bar {
    text-align: center;
    padding: 10px 0;
    border-bottom: 1px solid var(--border-soft);
    overflow: hidden;
    max-height: 44px;
    opacity: 1;
    transition: max-height var(--transition), opacity var(--transition),
                padding var(--transition), border-color var(--transition);
}
.site-nav.scrolled .top-bar {
    max-height: 0;
    padding: 0;
    opacity: 0;
    border-color: transparent;
}
.top-bar span { color: var(--secondary-color); }
.top-bar i { margin-right: 6px; }

.site-header { padding: 14px 0; transition: padding var(--transition); }
.site-nav.scrolled .site-header { padding: 10px 0; }

.navbar {
    position: relative;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: var(--space-lg);
}

.nav-group { display: flex; align-items: center; gap: var(--nav-gap); }
.nav-group-left  { justify-content: flex-start; }
.nav-group-right { justify-content: flex-end; }

.brand-group { display: flex; align-items: center; justify-content: center; gap: var(--space-md); }

/* "Proudly Rwandan" mark sitting beside the logo (hidden once the nav collapses) */
.brand-flag { display: inline-flex; align-items: center; gap: var(--space-xs); }
.brand-flag > img { height: 26px; width: auto; }
.brand-flag > span {
    font-size: var(--fs-md);
    font-weight: var(--fw-medium);
    letter-spacing: var(--tracking-wide);
    color: var(--text-muted);
    white-space: nowrap;
}

.logo {
    display: inline-flex;
    align-items: center;
    transition: transform var(--transition);
}
.logo:hover { transform: translateY(var(--lift-sm)); }
/* dark-mode logo: light text on a transparent ground, reads on the dark nav */
.logo img {
    width: 200px;
    transition: width var(--transition);
}
.site-nav.scrolled .logo img { width: 176px; }

.nav-links { display: flex; gap: var(--nav-gap); }
.nav-links a {
    position: relative;
    color: var(--text-muted);
    font-size: var(--fs-md);
    font-weight: var(--fw-medium);
    letter-spacing: var(--tracking-wide);
    transition: color var(--transition);
}
.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 100%;
    height: 1px;
    background: var(--primary-color);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--transition);
}
.nav-links a:hover,
.nav-links a.active { color: var(--text-light); }
.nav-links a:hover::after,
.nav-links a.active::after { transform: scaleX(1); }

/* hamburger — revealed at the nav breakpoint (see section 14) */
.nav-toggle {
    display: none;
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    padding: 0;
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    cursor: pointer;
}
.nav-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    margin: var(--space-2xs) auto;
    background: var(--text-light);
    border-radius: 2px;
    transition: transform var(--transition), opacity var(--transition);
}
.nav-toggle.active span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle.active span:nth-child(2) { opacity: 0; }
.nav-toggle.active span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* full-screen mobile menu */
.mobile-menu {
    position: fixed;
    inset: 0;
    z-index: 999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: var(--space-lg);
    padding: var(--space-4xl) var(--space-lg);
    background: rgba(13, 12, 10, 0.98);
    backdrop-filter: blur(6px);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-12px);
    transition: opacity var(--transition), transform var(--transition),
                visibility var(--transition);
}
.mobile-menu.open {
    opacity: 1;
    visibility: visible;
    transform: none;
}
.mobile-menu ul {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-xl);
}
.mobile-menu a {
    color: var(--text-light);
    font-family: var(--font-heading);
    font-size: var(--fs-menu);
    font-weight: var(--fw-medium);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 6px 16px;
}
.mobile-menu a:hover,
.mobile-menu a.active { color: var(--primary-color); }
.mobile-menu .btn { margin-top: var(--space-md); }


/* ==========================================================================
   8. HERO
   ========================================================================== */
.hero {
    position: relative;
    width: 100%;
    min-height: 780px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: var(--background-dark);
    isolation: isolate;   /* keep negative-z bg layers above hero's own bg */
}

.hero-bg { position: absolute; inset: 0; z-index: -3; overflow: hidden; }

.hero-video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.55) saturate(0.9) contrast(1.03);
}

/* strata-toned wash at the base of the hero */
.hero-ambient-gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg,
        transparent 45%,
        rgba(139, 94, 52, 0.10) 72%,
        rgba(74, 70, 64, 0.22) 100%);
}

.overlay {
    position: absolute;
    inset: 0;
    z-index: -2;
    background:
        linear-gradient(to right, rgba(13, 12, 10, 0.85), rgba(13, 12, 10, 0.55)),
        linear-gradient(to bottom, rgba(13, 12, 10, 0.45), rgba(13, 12, 10, 0.2) 40%, rgba(13, 12, 10, 0.78));
}

/* faint topographic contour texture */
.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: -1;
    opacity: 0.35;
    pointer-events: none;
    background-image:
        repeating-radial-gradient(circle at 20% 30%, rgba(237,230,213,0.05) 0px, rgba(237,230,213,0.05) 1px, transparent 1px, transparent 34px),
        repeating-radial-gradient(circle at 80% 70%, rgba(237,230,213,0.04) 0px, rgba(237,230,213,0.04) 1px, transparent 1px, transparent 46px);
}

/* ---- Drilling rig: animated signature element ---- */
.drill-rig { position: absolute; left: 82%; top: 30%; bottom: 10%; width: 1px; }
.drill-track { position: absolute; inset: 0; border-left: 1px dashed rgba(237,230,213,0.22); }
.drill-bit {
    position: absolute;
    top: 0;
    left: 50%;
    margin-left: -7px;
    width: 0; height: 0;
    border-left: 7px solid transparent;
    border-right: 7px solid transparent;
    border-top: 14px solid var(--secondary-color);
    filter: drop-shadow(0 0 6px rgba(184,147,63,0.55));
    animation: drillDescend 12s var(--ease-drill) infinite,
               drillSpin 0.9s linear infinite;
}
.drill-impact {
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    width: 16px; height: 16px;
    border: 1px solid var(--secondary-color);
    border-radius: 50%;
    opacity: 0;
    animation: impactPulse 12s ease infinite;
}
.drill-rig .depth-tick {
    left: -16px;
    transform: translate(-100%, -50%);
    font-size: var(--fs-2xs);
    opacity: 0.35;
}
.drill-rig .depth-tick .value { margin-right: var(--space-2xs); }
.tick-0 { animation: glow0 12s ease infinite; }
.tick-1 { animation: glow1 12s ease infinite; }
.tick-2 { animation: glow2 12s ease infinite; }
.tick-3 { animation: glow3 12s ease infinite; }

/* ---- Hero content ---- */
.hero-content-container {
    position: relative;
    flex: 1;
    display: flex;
    align-items: center;
    padding: calc(var(--nav-h) + var(--space-2xl)) 0 var(--space-2xl);
}
.hero-content { max-width: 820px; width: 100%; }

.hero-eyebrow {
    display: block;
    margin-bottom: var(--space-lg);
}
.hero-heading { margin-bottom: var(--space-xl); }
.hero-text {
    --lead-fs: var(--fs-base);
    --measure: var(--measure-heading);
    margin-bottom: var(--space-2xl);
}
.hero-buttons { display: flex; flex-wrap: wrap; gap: var(--space-md); }

/* scroll indicator */
.scroll {
    position: absolute;
    bottom: 25px;
    left: 50%;
    z-index: 3;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-xs);
    color: var(--text-muted);
    pointer-events: none;
    animation: bounceIndicator 2.2s infinite ease-in-out;
}
.scroll span {
    font-size: var(--fs-2xs);
    opacity: 0.75;
}

/* ---- Strata cross-section (signature divider) ---- */
.strata {
    position: relative;
    width: 100%;
    line-height: 0;
    background: var(--background-dark);
}
.strata svg { display: block; width: 100%; height: auto; }
.strata-labels {
    position: absolute;
    inset: 0;
    width: var(--gutter);
    margin-inline: auto;
    pointer-events: none;
}
.strata-labels .depth-tick {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}
.strata-labels .depth-tick::before {
    content: '';
    width: 18px;
    height: 1px;
    background: var(--border-strong);
}


/* ==========================================================================
   8b. PAGE HEADER — banner for sub-pages (about, contact, gallery, …)
   The lightweight counterpart to the video hero: clears the fixed nav, sets
   the page title + breadcrumb. Reused by every standalone page.
   ========================================================================== */
.page-header {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 100vh;      /* fills the first screen so the strata sits below the fold */
    min-height: 100svh;     /* honours mobile browser chrome where supported */
    padding: calc(var(--nav-h) + var(--space-2xl)) 0 var(--space-3xl);
    background: var(--surface-alt);
    border-bottom: 1px solid var(--border-soft);
    overflow: hidden;
    isolation: isolate;
}
/* faint contour texture — same visual language as the hero */
.page-header::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: -1;
    opacity: 0.5;
    pointer-events: none;
    background-image:
        repeating-radial-gradient(circle at 85% 15%, rgba(237,230,213,0.045) 0px, rgba(237,230,213,0.045) 1px, transparent 1px, transparent 40px);
}
.page-header .eyebrow { display: block; margin-bottom: var(--space-md); }
.page-header .section-heading { font-size: var(--fs-page); max-width: 16ch; }
.page-header .lead { margin-top: var(--space-lg); }


/* ==========================================================================
   9. TRUST / STATS
   ========================================================================== */
.stats-grid {
    margin-top: var(--space-3xl);
    border-top: 1px solid var(--border-color);
    gap: 0;   /* the dividers do the separating */
}
.stat-card { padding: var(--card-pad) var(--card-pad) 0; }
.stat-card:not(:last-child) { border-right: 1px solid var(--border-color); }
.stat-heading { margin-bottom: var(--space-sm); }
.stat-card:hover .stat-heading { color: var(--secondary-color); }


/* ==========================================================================
   10. ABOUT
   ========================================================================== */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-4xl);
    align-items: center;
}
.about-image { border-radius: var(--radius-md); }
.about-image::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: var(--radius-md);
    box-shadow: inset 0 0 0 1px var(--border-color);
}

/* same heading rhythm as .section-header, then one gap before each block */
.about-content > * + * { margin-top: var(--space-heading); }
.about-content .section-heading { --measure: none; }
.about-content .lead { --measure: 520px; }
.about-content .feature-list,
.about-content .btn { margin-top: var(--space-2xl); }


/* ==========================================================================
   11. SERVICES
   ========================================================================== */
.services-grid { margin-top: var(--space-3xl); }
.service-card .card-heading { margin-bottom: var(--space-sm); }
.service-card .body-text { margin-bottom: var(--space-lg); }

/* ---- Services PAGE: alternating image/detail rows ----------------------
   Each row is a .grid.grid-2; .reverse flips the image to the right on
   desktop. On mobile (grid collapses) the image is forced first — see §14. */
.svc-rows {
    display: flex;
    flex-direction: column;
    gap: var(--space-4xl);
    margin-top: var(--space-3xl);
}
.svc-row {
    align-items: center;
    column-gap: var(--space-4xl);
    scroll-margin-top: calc(var(--nav-h) + var(--space-lg));  /* deep-link offset */
}
.svc-row.reverse .svc-media { order: 2; }
.svc-media { border-radius: var(--radius-md); }
.svc-body .card-heading { margin-bottom: var(--space-md); }
.svc-body .body-text { margin-bottom: var(--space-lg); }

/* lighter "what's included" list — no rails, unlike .feature-list */
.svc-includes {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
    margin-bottom: var(--space-xl);
}
.svc-includes li {
    display: flex;
    align-items: flex-start;
    gap: var(--space-sm);
    color: var(--text-muted);
    font-size: var(--fs-card);
}
.svc-includes i { margin-top: 6px; color: var(--secondary-color); }


/* ==========================================================================
   11b. FEATURED PROJECTS
   Composes .card + .project-card + .card-badge + .card-meta. The only rules
   here are spacing between the card's own parts — no new look, no colours.
   ========================================================================== */
.projects-grid { margin-top: var(--space-3xl); }

/* positioned wrapper for the media + its badge (reuses .image-frame) */
.project-media { height: var(--card-media-h); }
.project-media .card-media { height: 100%; }

.project-card .card-heading { margin-bottom: var(--space-xs); }
.project-card .card-meta { margin-bottom: 0; }
.project-card .body-text {
    margin-bottom: 0;
    font-size: var(--fs-sm);
    line-height: 1.65;
}

/* Status pill (top-right of cover) */
.project-status-pill {
    position: absolute;
    top: var(--space-md);
    right: var(--space-md);
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: var(--radius-pill);
    background: rgba(13, 12, 10, 0.84);
    backdrop-filter: blur(6px);
    border: 1px solid var(--border-color);
    font-size: var(--fs-2xs);
    font-weight: var(--fw-semibold);
    letter-spacing: var(--tracking-tick);
    text-transform: uppercase;
    color: var(--text-light);
}
.project-status-pill::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--secondary-color);
}
.project-status-pill.is-ongoing {
    border-color: rgba(193, 96, 44, 0.55);
    color: var(--primary-light);
}
.project-status-pill.is-ongoing::before {
    background: var(--primary-color);
    box-shadow: 0 0 8px var(--primary-color);
}

/* Client tag above title */
.project-client-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 6px;
    font-size: var(--fs-2xs);
    font-weight: var(--fw-semibold);
    letter-spacing: var(--tracking-tick);
    text-transform: uppercase;
    color: var(--secondary-color);
}

/* Location + Year row */
.project-meta-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--space-md);
    margin-bottom: var(--space-sm);
    padding-bottom: var(--space-sm);
    border-bottom: 1px solid var(--border-soft);
}

/* Scope of work line */
.project-service-scope {
    margin-bottom: var(--space-xs);
    font-size: var(--fs-xs);
    color: var(--text-light);
    line-height: 1.5;
}
.project-service-scope strong {
    color: var(--secondary-color);
    font-weight: var(--fw-semibold);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    font-size: var(--fs-2xs);
    margin-right: 4px;
}

/* ---- Projects PAGE: clickable gallery cards ----------------------------- */
.project-card.is-clickable { cursor: pointer; scroll-margin-top: calc(var(--nav-h) + var(--space-lg)); }

/* media-count chip, bottom-left of the cover */
.project-count {
    position: absolute;
    left: var(--space-md);
    bottom: var(--space-md);
    z-index: 1;
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    padding: 5px var(--space-sm);
    background: rgba(13, 12, 10, 0.72);
    backdrop-filter: blur(4px);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-pill);
    color: var(--text-light);
    font-size: var(--fs-xs);
    font-weight: var(--fw-medium);
    letter-spacing: var(--tracking-wide);
}
.project-count i { color: var(--secondary-color); }

/* "expand" cue that fades in over the cover on hover/focus */
.project-view {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(13, 12, 10, 0.45);
    color: var(--text-light);
    font-size: 1.4rem;
    opacity: 0;
    transition: opacity var(--transition);
}
.project-card.is-clickable:hover .project-view,
.project-card.is-clickable:focus-visible .project-view { opacity: 1; }

/* coming-soon cards read as pending, not interactive */
.project-card.coming-soon .card-media { filter: grayscale(35%) brightness(0.8); }
.project-card.coming-soon .project-count { color: var(--text-muted); }

/* trailing action, centred below the grid — for "View all projects" */
.section-cta {
    margin-top: var(--space-2xl);
    text-align: center;
}

/* ---- Technical Project Register Table ----------------------------------- */
.project-table-wrap {
    margin-top: var(--space-2xl);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    background: var(--surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    position: relative;
}
.project-register-table {
    width: 100%;
    min-width: 920px;
    border-collapse: collapse;
    text-align: left;
    font-size: var(--fs-xs);
}
.project-register-table thead th {
    padding: 14px 16px;
    background: var(--surface-raised);
    border-bottom: 1px solid var(--border-strong);
    color: var(--secondary-color);
    font-size: var(--fs-2xs);
    font-weight: var(--fw-semibold);
    letter-spacing: var(--tracking-tick);
    text-transform: uppercase;
    white-space: nowrap;
}
.project-register-table tbody tr {
    border-bottom: 1px solid var(--border-soft);
    transition: background var(--transition);
}
.project-register-table tbody tr:last-child {
    border-bottom: none;
}
.project-register-table tbody tr:hover {
    background: rgba(193, 96, 44, 0.06);
}
.project-register-table td {
    padding: 14px 16px;
    color: var(--text-muted);
    vertical-align: top;
    line-height: 1.55;
}
.project-register-table .col-num {
    font-family: var(--font-heading);
    font-weight: var(--fw-semibold);
    color: var(--secondary-color);
    font-variant-numeric: tabular-nums;
}
.project-register-table .col-name a {
    color: var(--text-light);
    font-weight: var(--fw-semibold);
    text-decoration: none;
    transition: color var(--transition);
}
.project-register-table .col-name a:hover {
    color: var(--primary-light);
}
.project-register-table .col-client {
    color: var(--text-light);
    font-weight: var(--fw-medium);
}
.project-register-table .col-year {
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
    color: var(--text-light);
}
.table-status {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 9px;
    border-radius: var(--radius-pill);
    font-size: var(--fs-2xs);
    font-weight: var(--fw-semibold);
    letter-spacing: var(--tracking-wide);
    text-transform: uppercase;
    white-space: nowrap;
    background: rgba(184, 147, 63, 0.12);
    border: 1px solid rgba(184, 147, 63, 0.32);
    color: var(--secondary-color);
}
.table-status.is-ongoing {
    background: rgba(193, 96, 44, 0.15);
    border-color: rgba(193, 96, 44, 0.45);
    color: var(--primary-light);
}

/* ==========================================================================
   LIGHTBOX — fullscreen project gallery (projects page)
   Injected once by the Lightbox module; slides are built on open.
   ========================================================================== */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(var(--space-md), 4vw, var(--space-2xl));
    background: rgba(9, 8, 7, 0.94);
    backdrop-filter: blur(6px);
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--transition), visibility var(--transition);
}
.lightbox.open { opacity: 1; visibility: visible; }

.lb-stage {
    position: relative;
    max-width: min(1200px, 92vw);
    max-height: 84vh;
    display: flex;
    align-items: center;
    justify-content: center;
}
.lb-stage img,
.lb-stage video {
    max-width: 100%;
    max-height: 84vh;
    width: auto;
    height: auto;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-lg);
    background: var(--ink);
}

/* controls */
.lb-btn {
    position: absolute;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    background: rgba(13, 12, 10, 0.6);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-pill);
    color: var(--text-light);
    font-size: 1.1rem;
    cursor: pointer;
    transition: background var(--transition), border-color var(--transition), transform var(--transition);
}
.lb-btn:hover { background: var(--primary-color); border-color: var(--primary-color); }
.lb-close { top: clamp(var(--space-md), 3vw, var(--space-xl)); right: clamp(var(--space-md), 3vw, var(--space-xl)); }
.lb-prev  { left: clamp(var(--space-xs), 2vw, var(--space-xl)); top: 50%; transform: translateY(-50%); }
.lb-next  { right: clamp(var(--space-xs), 2vw, var(--space-xl)); top: 50%; transform: translateY(-50%); }
.lb-prev:hover { transform: translateY(-50%) scale(1.06); }
.lb-next:hover { transform: translateY(-50%) scale(1.06); }

/* caption: title + counter */
.lb-caption {
    position: absolute;
    left: 0;
    right: 0;
    bottom: clamp(var(--space-sm), 3vw, var(--space-xl));
    text-align: center;
    color: var(--text-muted);
    font-size: var(--fs-md);
}
.lb-caption .lb-title { color: var(--text-light); font-weight: var(--fw-medium); }
.lb-caption .lb-count { margin-left: var(--space-sm); }


/* ==========================================================================
   11c. WHY CHOOSE ACS
   Icon-medallion feature cards. No media — visual counterpoint to the two
   image-card grids above it. Composes .card + .icon-badge, nothing new.
   ========================================================================== */
.why-grid { margin-top: var(--space-3xl); }
.feature-card .icon-badge { margin-bottom: var(--space-lg); }
.feature-card .card-heading { margin-bottom: var(--space-sm); }


/* ==========================================================================
   11d. CLIENTS & PARTNERS
   A logo wall. Cells hold a company name now; swap the <span> for an
   <img class="image-contain"> when real logos arrive — the cell doesn't change.
   auto-fill/minmax is self-responsive, so this grid needs no media queries.
   ========================================================================== */
.partners-grid {
    margin-top: var(--space-3xl);
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
    gap: var(--space-md);
}
/* light chip so colour logos read on the dark site; greyscale at rest, full
   colour + lift on hover — keeps a wall of mismatched logos looking uniform */
.partner {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 104px;
    padding: var(--space-lg) var(--space-xl);
    background: var(--logo-chip);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-md);
    transition: border-color var(--transition), transform var(--transition),
                box-shadow var(--transition);
}
.partner:hover {
    border-color: var(--border-strong);
    transform: translateY(var(--lift-sm));
    box-shadow: var(--shadow-md);
}
.partner img {
    max-height: 60px;
    max-width: 100%;
    width: auto;
    filter: grayscale(100%);
    opacity: 0.82;
    transition: filter var(--transition), opacity var(--transition);
}
.partner:hover img { filter: grayscale(0%); opacity: 1; }


/* ==========================================================================
   11e. CONTACT PAGE
   Info column + form panel. Composes .contact-list + form controls + a
   .card.card-static panel — no new look, just the two-column split.
   ========================================================================== */
.contact-grid {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: var(--space-4xl);
    align-items: start;
}
.contact-info .section-heading { margin-bottom: var(--space-md); }
.contact-info .lead { margin-bottom: var(--space-2xl); }
.contact-info .contact-list { margin-bottom: var(--space-2xl); }
.contact-form .form-actions { margin-top: var(--space-xl); }

/* "Email Us" call-to-action panel (right column) */
.contact-cta { text-align: center; }
.contact-cta .icon-badge { margin-bottom: var(--space-lg); }
.contact-cta .card-heading { margin-bottom: var(--space-md); }
.contact-cta .body-text { margin-bottom: var(--space-xl); max-width: 42ch; margin-inline: auto; }
.contact-cta .btn { margin-inline: auto; }
.contact-cta-note { margin-top: var(--space-md); }


/* ==========================================================================
   11f. GALLERY PAGE — INDUSTRIAL ARCHITECTURAL PORTFOLIO
   Dark charcoal/slate surfaces with warm amber/gold accents, blueprint grid
   texture, compact hero + stratigraphy graphic, sticky SVG category dock,
   bento showcase grid with tabular discipline counters ("01/04"), and
   fullscreen media lightbox with filmstrip.
   ========================================================================== */

/* ---- 1. Industrial Hero + Stratigraphy --------------------------------- */
.page-header.gallery-hero {
    min-height: auto;
    justify-content: flex-start;
    padding: calc(var(--nav-h) + var(--space-3xl)) 0 0;
    background:
        radial-gradient(ellipse 75% 60% at 75% 20%, rgba(184, 147, 63, 0.09) 0%, transparent 70%),
        radial-gradient(ellipse 60% 50% at 15% 80%, rgba(193, 96, 44, 0.08) 0%, transparent 65%),
        var(--surface-alt);
    border-bottom: none;
}

/* Blueprint engineering grid texture */
.gallery-hero-grid-bg {
    position: absolute;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background-image:
        linear-gradient(to right, rgba(237, 230, 213, 0.035) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(237, 230, 213, 0.035) 1px, transparent 1px);
    background-size: 56px 56px;
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.9) 30%, transparent 95%);
    -webkit-mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.9) 30%, transparent 95%);
}

.gallery-hero-layout {
    display: grid;
    grid-template-columns: 1.25fr 0.75fr;
    gap: var(--space-3xl);
    align-items: end;
    padding-bottom: var(--space-3xl);
}
.gallery-hero-copy .section-heading {
    max-width: 18ch;
}
.gallery-hero-copy .lead {
    max-width: 58ch;
}

/* Summary statistics pills (Interactive Buttons) */
.gallery-stat-pills {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
    align-items: stretch;
}
.gallery-stat-pill {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    width: 100%;
    padding: 14px var(--space-lg);
    background: rgba(13, 12, 10, 0.72);
    backdrop-filter: blur(8px);
    border: 1px solid var(--border-color);
    border-left: 3px solid var(--secondary-color);
    border-radius: var(--radius-md);
    font-family: var(--font-body);
    text-align: left;
    cursor: pointer;
    transition: background var(--transition), border-color var(--transition), transform var(--transition), box-shadow var(--transition);
}
.gallery-stat-pill:hover {
    background: rgba(31, 28, 22, 0.94);
    border-color: var(--secondary-color);
    border-left-color: var(--primary-color);
    transform: translateX(-4px);
    box-shadow: 0 0 18px rgba(184, 147, 63, 0.25), 0 8px 24px rgba(0, 0, 0, 0.45);
}
.gallery-stat-pill:focus-visible {
    outline: 2px solid var(--secondary-color);
    outline-offset: 2px;
}
.gallery-stat-pill.active {
    background: linear-gradient(135deg, rgba(193, 96, 44, 0.2) 0%, rgba(184, 147, 63, 0.1) 100%);
    border-color: rgba(193, 96, 44, 0.65);
    border-left-color: var(--primary-color);
    box-shadow: 0 0 20px rgba(193, 96, 44, 0.22), 0 8px 24px rgba(0, 0, 0, 0.42);
}
.gallery-stat-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: var(--radius-sm);
    background: rgba(184, 147, 63, 0.12);
    border: 1px solid rgba(184, 147, 63, 0.28);
    color: var(--secondary-color);
    flex-shrink: 0;
    transition: background var(--transition), border-color var(--transition), color var(--transition);
}
.gallery-stat-pill:hover .gallery-stat-icon,
.gallery-stat-pill.active .gallery-stat-icon {
    background: rgba(193, 96, 44, 0.22);
    border-color: rgba(193, 96, 44, 0.55);
    color: var(--primary-light);
}
.gallery-stat-text {
    display: flex;
    align-items: baseline;
    gap: var(--space-sm);
    flex: 1;
}
.gallery-stat-text strong {
    font-family: var(--font-heading);
    font-size: clamp(1.45rem, 1.8vw, 1.85rem);
    font-weight: var(--fw-semibold);
    font-variant-numeric: tabular-nums;
    color: var(--text-light);
    line-height: 1;
}
.gallery-stat-text span {
    font-size: var(--fs-xs);
    font-weight: var(--fw-semibold);
    letter-spacing: var(--tracking-tick);
    text-transform: uppercase;
    color: var(--text-muted);
    transition: color var(--transition);
}
.gallery-stat-pill:hover .gallery-stat-text span,
.gallery-stat-pill.active .gallery-stat-text span {
    color: var(--text-light);
}
.gallery-stat-arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: var(--radius-full);
    background: rgba(244, 239, 230, 0.04);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    flex-shrink: 0;
    transition: transform var(--transition), background var(--transition), border-color var(--transition), color var(--transition);
}
.gallery-stat-pill:hover .gallery-stat-arrow,
.gallery-stat-pill.active .gallery-stat-arrow {
    transform: translateX(3px);
    background: rgba(193, 96, 44, 0.22);
    border-color: var(--primary-color);
    color: var(--text-light);
}

.gallery-strata {
    margin-top: var(--space-sm);
}

/* ---- 2. Sticky Category Filter Bar ------------------------------------- */
.gallery-section {
    padding-top: 0;
    border-top: none;
}

.gallery-sticky-nav {
    position: sticky;
    top: var(--nav-h);
    z-index: 50;
    background: rgba(13, 12, 10, 0.92);
    backdrop-filter: blur(16px);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
    transition: top var(--transition), background var(--transition);
}

.gallery-nav-inner {
    padding: 12px 0;
    overflow-x: auto;
    scrollbar-width: none;
}
.gallery-nav-inner::-webkit-scrollbar {
    display: none;
}

.gallery-filters {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: max-content;
    border-radius: var(--radius-md);
    transition: box-shadow 0.4s ease;
}
@keyframes disciplineBarPulse {
    0%, 100% {
        border-color: var(--border-color);
        background: var(--surface-alt);
        box-shadow: none;
    }
    35%, 65% {
        border-color: var(--secondary-color);
        background: rgba(184, 147, 63, 0.18);
        color: var(--text-light);
        box-shadow: 0 0 0 3px rgba(184, 147, 63, 0.16);
    }
}
.gallery-filters.is-pulsing .gallery-filter:not(.active) {
    animation: disciplineBarPulse 1.5s ease-in-out;
}

.gallery-filter {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 15px;
    background: var(--surface-alt);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    font-family: var(--font-body);
    font-size: var(--fs-xs);
    font-weight: var(--fw-semibold);
    letter-spacing: 0.4px;
    white-space: nowrap;
    cursor: pointer;
    transition: background var(--transition), color var(--transition),
                border-color var(--transition), transform var(--transition),
                box-shadow var(--transition);
}
.gallery-filter-svg {
    color: var(--secondary-color);
    flex-shrink: 0;
    transition: color var(--transition), transform var(--transition);
}
.gallery-filter:hover {
    color: var(--text-light);
    border-color: rgba(184, 147, 63, 0.45);
    background: rgba(237, 230, 213, 0.05);
    transform: translateY(-1px);
}
.gallery-filter.active {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-hover) 100%);
    border-color: var(--secondary-color);
    color: var(--text-light);
    box-shadow: 0 6px 20px rgba(193, 96, 44, 0.35);
}
.gallery-filter.active .gallery-filter-svg {
    color: var(--text-light);
}
.gallery-filter-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 22px;
    height: 19px;
    padding: 0 6px;
    border-radius: 3px;
    background: rgba(237, 230, 213, 0.08);
    color: var(--text-light);
    font-size: var(--fs-2xs);
    font-weight: var(--fw-semibold);
    font-variant-numeric: tabular-nums;
    line-height: 1;
}
.gallery-filter.active .gallery-filter-count {
    background: rgba(13, 12, 10, 0.32);
    color: var(--text-light);
}

/* ---- Active Discipline Header & Controls Subbar ------------------------ */
.gallery-subbar {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: var(--space-2xl);
    margin: var(--space-2xl) 0 var(--space-xl);
    padding: var(--space-xl);
    background: linear-gradient(135deg, var(--surface-alt) 0%, rgba(22, 20, 15, 0.5) 100%);
    border: 1px solid var(--border-color);
    border-left: 3px solid var(--secondary-color);
    border-radius: var(--radius-md);
}
.gallery-subbar-info {
    max-width: 680px;
}
.gallery-subbar-title-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--space-sm);
    margin-bottom: var(--space-xs);
}
.gallery-subbar-code {
    display: inline-block;
    padding: 3px 8px;
    background: rgba(184, 147, 63, 0.14);
    border: 1px solid rgba(184, 147, 63, 0.32);
    border-radius: 3px;
    color: var(--secondary-color);
    font-size: var(--fs-2xs);
    font-weight: var(--fw-semibold);
    font-variant-numeric: tabular-nums;
    letter-spacing: var(--tracking-tick);
    text-transform: uppercase;
}
.gallery-subbar-heading {
    font-family: var(--font-heading);
    font-size: var(--fs-h3);
    font-weight: var(--fw-medium);
    color: var(--text-light);
    line-height: 1.2;
}
.gallery-subbar-desc {
    color: var(--text-muted);
    font-size: var(--fs-md);
    line-height: 1.6;
}

.gallery-subbar-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--space-md);
    flex-shrink: 0;
}

.gallery-media-tabs {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 3px;
    background: var(--surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
}
.gallery-media-tab {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: transparent;
    border: none;
    border-radius: 2px;
    color: var(--text-muted);
    font-size: var(--fs-xs);
    font-weight: var(--fw-semibold);
    letter-spacing: 0.4px;
    cursor: pointer;
    transition: background var(--transition), color var(--transition);
}
.gallery-media-tab span {
    color: var(--secondary-color);
    font-size: var(--fs-2xs);
    font-variant-numeric: tabular-nums;
}
.gallery-media-tab:hover { color: var(--text-light); }
.gallery-media-tab.active {
    background: var(--surface-alt);
    color: var(--text-light);
    box-shadow: var(--shadow-sm);
}

.gallery-readout {
    display: inline-flex;
    align-items: center;
    gap: var(--space-sm);
    font-size: var(--fs-xs);
    font-weight: var(--fw-medium);
    letter-spacing: var(--tracking-tick);
    color: var(--text-muted);
    font-variant-numeric: tabular-nums;
}
.gallery-readout strong {
    color: var(--text-light);
    font-weight: var(--fw-semibold);
}

.gallery-reset {
    padding: 4px 10px;
    background: rgba(193, 96, 44, 0.14);
    border: 1px solid var(--primary-color);
    border-radius: var(--radius-sm);
    color: var(--primary-color);
    font-size: var(--fs-2xs);
    font-weight: var(--fw-semibold);
    letter-spacing: var(--tracking-tick);
    cursor: pointer;
    transition: background var(--transition), color var(--transition);
}
.gallery-reset:hover {
    background: var(--primary-color);
    color: var(--text-light);
}

.gallery-view-switch {
    display: inline-flex;
    gap: 3px;
    padding: 3px;
    background: var(--surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
}
.gallery-view-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 28px;
    background: transparent;
    border: none;
    border-radius: 2px;
    color: var(--text-muted);
    cursor: pointer;
    transition: background var(--transition), color var(--transition);
}
.gallery-view-btn:hover { color: var(--text-light); }
.gallery-view-btn.active {
    background: var(--primary-color);
    color: var(--text-light);
}

/* ---- 3. Responsive Bento Gallery Grid ---------------------------------- */
.gallery-bento {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 255px;
    grid-auto-flow: dense;
    gap: var(--space-md);
}

.gallery-bento:not(.is-uniform) .gallery-item--featured {
    grid-column: span 2;
    grid-row: span 2;
}
.gallery-bento:not(.is-uniform) .gallery-item--wide {
    grid-column: span 2;
    grid-row: span 1;
}

.gallery-bento.is-uniform {
    grid-auto-rows: 240px;
}

/* ---- Gallery Item Card & High-Performance Hover States ----------------- */
.gallery-item {
    position: relative;
    border-radius: var(--radius-md);
    overflow: hidden;
    cursor: pointer;
    background: var(--surface-alt);
    border: 1px solid var(--border-color);
    transition: transform var(--transition), box-shadow var(--transition),
                border-color var(--transition), opacity var(--transition-fast);
}
.gallery-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 44px rgba(0, 0, 0, 0.55);
    border-color: var(--secondary-color);
}
.gallery-item:focus-visible {
    outline: 2px solid var(--secondary-color);
    outline-offset: 2px;
}
.gallery-item.is-paged-out {
    display: none;
}

.gallery-thumb {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
    background: var(--surface);
}
.gallery-thumb img,
.gallery-video-preview {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform var(--transition-slow), filter var(--transition-slow);
}
.gallery-item:hover .gallery-thumb img,
.gallery-item:hover .gallery-video-preview {
    transform: scale(1.06);
}

/* ---- Industrial Tag & Counter Overlay ("GEOTECHNICAL INVESTIGATION 01/04") ---- */
.gallery-overlay {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: var(--space-md);
    background: linear-gradient(
        to top,
        rgba(13, 12, 10, 0.90) 0%,
        rgba(13, 12, 10, 0.25) 45%,
        rgba(13, 12, 10, 0.35) 100%
    );
    pointer-events: none;
    transition: background var(--transition);
}

.gallery-overlay-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-xs);
}

/* Always-visible technical tag + tabular counter pill */
.gallery-tag-counter {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 5px 10px;
    background: rgba(13, 12, 10, 0.82);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(237, 230, 213, 0.14);
    border-radius: var(--radius-sm);
    font-size: var(--fs-2xs);
    font-weight: var(--fw-semibold);
    letter-spacing: 1.2px;
    text-transform: uppercase;
    color: var(--text-light);
    transition: border-color var(--transition), background var(--transition);
}
.gallery-item:hover .gallery-tag-counter {
    border-color: rgba(184, 147, 63, 0.55);
    background: rgba(13, 12, 10, 0.92);
}
.gallery-tag-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--secondary-color);
    flex-shrink: 0;
}
.gallery-tag-num {
    color: var(--secondary-color);
    font-variant-numeric: tabular-nums;
    padding-left: 6px;
    border-left: 1px solid var(--border-color);
}

.gallery-expand-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: var(--radius-sm);
    background: rgba(13, 12, 10, 0.78);
    border: 1px solid var(--border-strong);
    color: var(--text-light);
    font-size: var(--fs-xs);
    opacity: 0;
    transform: translateY(-4px) scale(0.92);
    transition: opacity var(--transition), transform var(--transition),
                background var(--transition), border-color var(--transition);
}
.gallery-item:hover .gallery-expand-icon,
.gallery-item:focus-visible .gallery-expand-icon {
    opacity: 1;
    transform: none;
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.gallery-overlay-bottom {
    opacity: 0;
    transform: translateY(8px);
    transition: opacity var(--transition), transform var(--transition);
}
.gallery-item:hover .gallery-overlay-bottom,
.gallery-item:focus-visible .gallery-overlay-bottom,
.gallery-bento:not(.is-uniform) .gallery-item--featured .gallery-overlay-bottom {
    opacity: 1;
    transform: none;
}
.gallery-item-caption {
    color: var(--text-light);
    font-size: var(--fs-md);
    font-weight: var(--fw-medium);
    line-height: 1.35;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.65);
}
.gallery-bento:not(.is-uniform) .gallery-item--featured .gallery-item-caption {
    font-family: var(--font-heading);
    font-size: var(--fs-h3);
}

/* ---- Video Tile Play Ring & Badge -------------------------------------- */
.gallery-video-ph {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: var(--space-xs);
    background: radial-gradient(circle, rgba(13, 12, 10, 0.25) 0%, rgba(13, 12, 10, 0.65) 100%);
    pointer-events: none;
    transition: background var(--transition);
}
.gallery-play-ring {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: rgba(13, 12, 10, 0.78);
    border: 1.5px solid var(--secondary-color);
    color: var(--secondary-color);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    transition: transform var(--transition), background var(--transition),
                color var(--transition), border-color var(--transition);
}
.gallery-play-ring svg {
    margin-left: 2px;
}
.gallery-video-tag {
    padding: 3px 8px;
    background: rgba(13, 12, 10, 0.82);
    border: 1px solid var(--border-color);
    border-radius: 3px;
    color: var(--text-light);
    font-size: 9px;
    font-weight: var(--fw-semibold);
    letter-spacing: 2px;
}
.gallery-item:hover .gallery-play-ring {
    transform: scale(1.1);
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: var(--text-light);
}

/* ---- Pagination / Load More Bar ---------------------------------------- */
.gallery-pagination {
    margin-top: var(--space-3xl);
    padding-top: var(--space-2xl);
    border-top: 1px solid var(--border-color);
    text-align: center;
}
.gallery-progress-wrap {
    max-width: 360px;
    margin: 0 auto var(--space-lg);
}
.gallery-progress-wrap .small-text {
    font-size: var(--fs-xs);
    letter-spacing: var(--tracking-tick);
}
.gallery-progress-wrap strong {
    color: var(--secondary-color);
    font-variant-numeric: tabular-nums;
}
.gallery-progress-bar {
    width: 100%;
    height: 4px;
    margin-top: var(--space-xs);
    background: var(--surface-alt);
    border-radius: var(--radius-pill);
    overflow: hidden;
}
.gallery-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    border-radius: var(--radius-pill);
    transition: width var(--transition);
}

/* ---- 4. Lightbox Modal + Thumbnail Filmstrip --------------------------- */
.lightbox.has-strip .lb-stage {
    max-height: 70vh;
    margin-bottom: 88px;
}
.lightbox.has-strip .lb-stage img,
.lightbox.has-strip .lb-stage video {
    max-height: 70vh;
}
.lightbox.has-strip .lb-caption {
    bottom: 92px;
}
.lb-caption .lb-cat {
    display: inline-block;
    margin-right: var(--space-sm);
    padding: 3px 8px;
    background: rgba(184, 147, 63, 0.16);
    border: 1px solid rgba(184, 147, 63, 0.38);
    border-radius: 3px;
    color: var(--secondary-color);
    font-size: var(--fs-2xs);
    font-weight: var(--fw-semibold);
    letter-spacing: 1.5px;
    text-transform: uppercase;
    font-variant-numeric: tabular-nums;
}
.lb-strip {
    position: absolute;
    left: 50%;
    bottom: var(--space-md);
    transform: translateX(-50%);
    z-index: 3;
    display: flex;
    align-items: center;
    gap: var(--space-xs);
    max-width: min(1040px, 92vw);
    padding: 6px;
    background: rgba(22, 20, 15, 0.88);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow-x: auto;
    scrollbar-width: thin;
}
.lb-thumb {
    position: relative;
    flex-shrink: 0;
    width: 60px;
    height: 44px;
    border-radius: var(--radius-sm);
    overflow: hidden;
    border: 2px solid transparent;
    background: var(--surface);
    opacity: 0.5;
    cursor: pointer;
    padding: 0;
    transition: opacity var(--transition), border-color var(--transition), transform var(--transition);
}
.lb-thumb:hover { opacity: 0.88; }
.lb-thumb.active {
    opacity: 1;
    border-color: var(--secondary-color);
    transform: translateY(-2px);
}
.lb-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.lb-thumb-video {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    background: var(--strata-1);
    color: var(--secondary-color);
    font-size: var(--fs-md);
}


/* ==========================================================================
   12. FOOTER
   Composes .container + a 4-column grid over the token layer. The only new
   pieces are footer-specific layout classes — no new colours or spacing.
   ========================================================================== */
.site-footer {
    background: var(--surface-alt);
    border-top: 1px solid var(--border-color);
    padding: var(--space-4xl) 0 var(--space-xl);
}
.footer-grid {
    display: grid;
    grid-template-columns: 1.6fr 1fr 1fr 1.4fr;
    gap: var(--space-2xl);
}

.footer-logo img { width: 200px; }
.footer-tagline {
    margin-top: var(--space-lg);
    max-width: 34ch;
    color: var(--text-muted);
    font-size: var(--fs-card);
    line-height: var(--lh-copy);
}
.footer-social {
    display: flex;
    gap: var(--space-sm);
    margin-top: var(--space-lg);
}
.footer-social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    transition: color var(--transition), border-color var(--transition),
                background var(--transition), transform var(--transition);
}
.footer-social a:hover {
    color: var(--primary-color);
    border-color: var(--primary-color);
    background: rgba(193, 96, 44, 0.08);
    transform: translateY(var(--lift-sm));
}

.footer-heading {
    margin-bottom: var(--space-lg);
    color: var(--text-light);
    font-size: var(--fs-xs);
    font-weight: var(--fw-semibold);
    letter-spacing: var(--tracking-caps);
    text-transform: uppercase;
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
}
.footer-links a {
    color: var(--text-muted);
    font-size: var(--fs-card);
    transition: color var(--transition), padding-left var(--transition);
}
.footer-links a:hover {
    color: var(--primary-color);
    padding-left: var(--space-2xs);
}

.footer-contact { display: flex; flex-direction: column; gap: var(--space-md); }
.footer-contact li {
    display: flex;
    gap: var(--space-sm);
    color: var(--text-muted);
    font-size: var(--fs-card);
    line-height: var(--lh-body);
}
.footer-contact i { margin-top: 5px; color: var(--secondary-color); }
.footer-contact a { color: inherit; transition: color var(--transition); }
.footer-contact a:hover { color: var(--primary-color); }

.footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-md);
    flex-wrap: wrap;
    margin-top: var(--space-3xl);
    padding-top: var(--space-lg);
    border-top: 1px solid var(--border-color);
}
.footer-bottom p { color: var(--text-muted); font-size: var(--fs-md); }
.footer-bottom .label-caps { color: var(--secondary-color); }


/* ==========================================================================
   13. ANIMATIONS
   ========================================================================== */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity var(--transition-reveal), transform var(--transition-reveal);
    will-change: opacity, transform;
}
.reveal.is-visible {
    opacity: 1;
    transform: none;
}

@keyframes drillDescend { 0%{top:0} 66%{top:100%} 75%{top:100%} 91%{top:0} 100%{top:0} }
@keyframes drillSpin    { from{transform:rotate(0)} to{transform:rotate(360deg)} }
@keyframes impactPulse  { 0%,64%,80%,100%{opacity:0;transform:scale(0.6)} 68%,74%{opacity:1;transform:scale(1.9)} }
@keyframes glow0 { 0%,4%,100%{opacity:1} 6%{opacity:0.35} }
@keyframes glow1 { 0%,16%,100%{opacity:0.35} 18%{opacity:1} 20%{opacity:0.35} }
@keyframes glow2 { 0%,40%,100%{opacity:0.35} 42%{opacity:1} 44%{opacity:0.35} }
@keyframes glow3 { 0%,64%,100%{opacity:0.35} 66%{opacity:1} 68%{opacity:0.35} }
@keyframes bounceIndicator { 0%,100%{transform:translate(-50%,0)} 50%{transform:translate(-50%,6px)} }


/* ==========================================================================
   14. MEDIA QUERIES
   One ladder, five stops. Every region adapts at these widths and nowhere
   else, so a new section only ever adds rules to an existing block.

     1400px  — content stops growing; below this the gutter drives width
     1200px  — split nav no longer fits; 3-up grids step to 2-up
      992px  — tablet: side-by-side layouts stack
      768px  — mobile: single column, full-width actions
      576px  — small mobile: strip non-essential ornament
   ========================================================================== */

/* ---- 1200px ---------------------------------------------------------- */
@media (max-width: 1200px) {
    .nav-group { display: none; }
    .nav-toggle { display: block; }
    .brand-flag { display: none; }   /* keep the collapsed nav clean */
    .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .stats-grid { grid-template-columns: repeat(4, 1fr); }  /* stats hold 4-up */
    .gallery-bento { grid-template-columns: repeat(3, 1fr); grid-auto-rows: 225px; }
}

/* ---- 992px ----------------------------------------------------------- */
@media (max-width: 992px) {
    .about-grid { grid-template-columns: 1fr; gap: var(--space-2xl); }
    .stats-grid { grid-template-columns: repeat(2, 1fr); row-gap: var(--space-2xl); }
    .stat-card:nth-child(2) { border-right: none; }

    /* brand column spans the top, the three link columns share the row below */
    .footer-grid { grid-template-columns: 1fr 1fr; gap: var(--space-2xl); }
    .footer-brand { grid-column: 1 / -1; }

    .contact-grid { grid-template-columns: 1fr; gap: var(--space-2xl); }

    .gallery-hero-layout { grid-template-columns: 1fr; gap: var(--space-xl); }
    .gallery-stat-pills { flex-direction: row; flex-wrap: wrap; }
    .gallery-stat-pill { flex: 1 1 200px; }
    .gallery-subbar { flex-direction: column; align-items: flex-start; gap: var(--space-lg); }
    .gallery-subbar-actions { width: 100%; justify-content: space-between; }
    .gallery-bento { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 225px; }
}

/* ---- 768px ----------------------------------------------------------- */
@media (max-width: 768px) {
    .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); }

    .hero { min-height: clamp(520px, 100svh, 680px); }
    .hero-content-container { text-align: center; }
    .hero-content {
        display: flex;
        flex-direction: column;
        align-items: center;
        margin-inline: auto;
    }
    .hero-buttons { flex-direction: column; width: 100%; max-width: 320px; }
    .hero-buttons .btn { width: 100%; min-height: 44px; }

    /* stacked buttons grow the content block into the scroll cue's space
       (collides at 390x844). The cue is a pointer-device affordance anyway. */
    .scroll { display: none; }

    .section-header { text-align: center; margin-inline: auto; }
    .section-header .section-heading,
    .section-header .lead { margin-inline: auto; }

    .about-content { text-align: center; }
    .about-content .section-heading,
    .about-content .lead { margin-inline: auto; }
    .feature { justify-content: center; }

    .footer-grid { grid-template-columns: 1fr; gap: var(--space-xl); }
    .footer-brand { grid-column: auto; }
    .footer-bottom { flex-direction: column; align-items: flex-start; }

    .page-header { min-height: auto; padding: calc(var(--nav-h) + var(--space-2xl)) 0 var(--space-2xl); }
    .page-header .section-heading { max-width: none; }
    .page-header.gallery-hero { padding-bottom: 0; }

    /* image always leads on mobile — must match the desktop .reverse
       specificity (3 classes) to override its order:2 */
    .svc-row.reverse .svc-media { order: -1; }
    .svc-row { column-gap: 0; }
    .svc-media img {
        width: 100%;
        max-height: 380px;
        object-fit: cover;
    }

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

    .gallery-subbar { padding: var(--space-lg); }
    .gallery-subbar-actions { flex-direction: column; align-items: stretch; }
    .gallery-media-tabs { justify-content: center; }
    .gallery-bento:not(.is-uniform) .gallery-item--featured,
    .gallery-bento:not(.is-uniform) .gallery-item--wide {
        grid-column: span 1;
        grid-row: span 1;
    }
}

/* ---- 576px ----------------------------------------------------------- */
@media (max-width: 576px) {
    .stats-grid { grid-template-columns: 1fr; }
    .stat-card {
        padding: var(--space-lg) 0;
        border-bottom: 1px solid var(--border-color);
    }
    .stat-card:not(:last-child) { border-right: none; }
    .strata-labels .depth-tick { display: none; }
    .gallery-stat-pills { flex-direction: column; }
    .gallery-stat-pill { flex: auto; }
    .gallery-bento { grid-template-columns: 1fr; grid-auto-rows: 220px; gap: var(--space-sm); }
    .gallery-tag-counter { padding: 4px 8px; font-size: 10px; letter-spacing: 0.8px; gap: 6px; }
    .gallery-tag-dot { display: inline-block; }
    .gallery-expand-icon,
    .gallery-overlay-bottom { display: none; }
    .lb-strip { display: none; }
    .lb-btn { width: 40px; height: 40px; }
    .lightbox.has-strip .lb-stage { margin-bottom: 0; max-height: 82vh; }
    .lightbox.has-strip .lb-caption { bottom: var(--space-md); }

    /* the drill rig's depth labels run off the left edge on narrow screens */
    .drill-rig { left: 88%; }
    .drill-rig .depth-tick { display: none; }
}

/* ---- 375px & Small Mobile -------------------------------------------- */
@media (max-width: 380px) {
    :root {
        --gutter: 94%;
    }
    .hero-heading { font-size: 2.1rem; }
    .gallery-stat-pill { padding: 10px 12px; gap: var(--space-xs); }
    .gallery-stat-arrow { display: none; }
}

/* ---- Landscape orientation on short mobile devices ------------------- */
@media (max-height: 500px) and (orientation: landscape) {
    .hero { min-height: 100svh; height: auto; padding-top: var(--nav-h); }
    .page-header { min-height: auto; padding: calc(var(--nav-h) + var(--space-md)) 0 var(--space-md); }
    .mobile-menu { justify-content: flex-start; overflow-y: auto; padding: calc(var(--nav-h) + var(--space-md)) var(--space-md); }
    .mobile-menu ul { gap: var(--space-sm); }
}

/* ---- Short viewports: the scroll cue would collide with content ------- */
@media (max-height: 680px) {
    .scroll { display: none; }
}

/* ---- Reduced motion --------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }

    .reveal {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }

    .drill-bit, .drill-impact, .drill-rig .depth-tick, .scroll {
        animation: none !important;
    }
    .drill-bit { top: 40%; }
    .drill-rig .depth-tick { opacity: 0.5; }
    .whatsapp-online-dot { animation: none !important; }
}

/* ==========================================================================
   11f. ACCREDITATION & CERTIFICATES
   Showcase for RSB Certificate of Designation & ISO/IEC 17025 compliance
   ========================================================================== */
.accreditation-banner {
    margin-top: var(--space-3xl);
    padding: var(--space-2xl);
    border-color: rgba(184, 147, 63, 0.35);
    background: linear-gradient(135deg, var(--surface) 0%, rgba(184, 147, 63, 0.06) 100%);
    cursor: pointer;
    position: relative;
    border-radius: var(--radius-md);
    transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}
.accreditation-banner:hover {
    transform: translateY(var(--card-lift));
    border-color: var(--secondary-color);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
}
.accreditation-layout {
    display: grid;
    grid-template-columns: 140px 1fr 240px;
    gap: var(--space-2xl);
    align-items: center;
}
.accreditation-badge-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: var(--space-xs);
    border-right: 1px solid var(--border-color);
    padding-right: var(--space-xl);
}
.accreditation-seal {
    width: 68px;
    height: 68px;
    border-radius: 50%;
    background: rgba(184, 147, 63, 0.12);
    border: 2px solid var(--secondary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--secondary-color);
    font-size: 1.85rem;
    box-shadow: 0 0 20px rgba(184, 147, 63, 0.2);
}
.accreditation-seal-text {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    color: var(--secondary-color);
    text-transform: uppercase;
}
.accreditation-standard {
    display: inline-block;
    padding: 2px 8px;
    border-radius: var(--radius-sm);
    background: var(--surface-alt);
    border: 1px solid var(--border-color);
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--text-light);
    letter-spacing: 0.04em;
}
.accreditation-content {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
}
.accreditation-eyebrow-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-md);
    flex-wrap: wrap;
}
.accreditation-validity-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 10px;
    border-radius: 999px;
    background: rgba(92, 122, 82, 0.15);
    border: 1px solid rgba(92, 122, 82, 0.4);
    color: #88C477;
    font-size: 0.75rem;
    font-weight: 600;
}
.accreditation-banner .card-heading {
    margin-bottom: var(--space-xs);
    color: var(--text-light);
}
.accreditation-banner .body-text {
    margin-bottom: var(--space-md);
    font-size: var(--fs-body);
}
.accreditation-meta-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-sm) var(--space-xl);
    padding-top: var(--space-sm);
    border-top: 1px solid var(--border-color);
}
.accreditation-meta-cell {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.accreditation-meta-cell .meta-label {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
}
.accreditation-meta-cell .meta-value {
    font-size: var(--fs-small);
    font-weight: 600;
    color: var(--text-light);
}
.accreditation-thumb-col {
    display: flex;
    justify-content: center;
}
.accreditation-thumb-frame {
    position: relative;
    border-radius: var(--radius-sm);
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
    background: #ffffff;
    max-width: 220px;
}
.accreditation-thumb-frame img {
    display: block;
    width: 100%;
    height: auto;
    transition: transform var(--transition-slow);
}
.accreditation-banner:hover .accreditation-thumb-frame img {
    transform: scale(1.04);
}
.accreditation-thumb-overlay {
    position: absolute;
    inset: 0;
    background: rgba(13, 12, 10, 0.75);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    color: var(--cream);
    opacity: 0;
    transition: opacity var(--transition);
    font-size: 0.75rem;
    font-weight: 600;
    text-align: center;
    padding: var(--space-sm);
}
.accreditation-banner:hover .accreditation-thumb-overlay,
.accreditation-banner:focus .accreditation-thumb-overlay {
    opacity: 1;
}
.accreditation-thumb-overlay i {
    font-size: 1.25rem;
    color: var(--secondary-color);
}

/* Service accreditation tag */
.service-accreditation-tag {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    margin-top: var(--space-md);
    padding: var(--space-xs) var(--space-md);
    border-radius: var(--radius-sm);
    background: rgba(184, 147, 63, 0.1);
    border: 1px solid rgba(184, 147, 63, 0.35);
    color: var(--secondary-color);
    font-size: var(--fs-small);
    font-weight: 600;
}

/* ==========================================================================
   11g. WHATSAPP FLOATING CTA
   Site-wide floating button connecting directly to company WhatsApp DM
   ========================================================================== */
.whatsapp-float {
    position: fixed;
    bottom: 28px;
    right: 28px;
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    transition: transform var(--transition), filter var(--transition);
}
.whatsapp-float:hover {
    transform: translateY(-3px) scale(1.02);
}
.whatsapp-float-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: #25D366;
    color: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4), 0 4px 12px rgba(0, 0, 0, 0.3);
    transition: transform var(--transition), box-shadow var(--transition);
    position: relative;
}
.whatsapp-float:hover .whatsapp-float-btn {
    box-shadow: 0 8px 26px rgba(37, 211, 102, 0.6), 0 6px 16px rgba(0, 0, 0, 0.4);
}
.whatsapp-float-tooltip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--surface);
    color: var(--text-light);
    border: 1px solid var(--border-color);
    padding: 8px 14px;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 600;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
    white-space: nowrap;
    transition: background var(--transition), border-color var(--transition);
}
.whatsapp-float:hover .whatsapp-float-tooltip {
    border-color: #25D366;
    background: var(--surface-alt);
}
.whatsapp-online-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: #25D366;
    box-shadow: 0 0 8px #25D366;
    animation: whatsappPulse 2s infinite ease-in-out;
}
@keyframes whatsappPulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.35); opacity: 0.7; }
}

/* WhatsApp button variant for Contact page & CTAs */
.btn-whatsapp {
    background-color: #25D366;
    color: #FFFFFF !important;
    border: 1px solid #20BA5A;
}
.btn-whatsapp:hover {
    background-color: #20BA5A;
    color: #FFFFFF !important;
    box-shadow: 0 4px 16px rgba(37, 211, 102, 0.4);
}
.icon-badge-whatsapp {
    background: rgba(37, 211, 102, 0.12) !important;
    color: #25D366 !important;
    border-color: rgba(37, 211, 102, 0.3) !important;
}

@media (max-width: 992px) {
    .accreditation-layout {
        grid-template-columns: 1fr;
        text-align: center;
        gap: var(--space-xl);
    }
    .accreditation-badge-col {
        border-right: none;
        border-bottom: 1px solid var(--border-color);
        padding-right: 0;
        padding-bottom: var(--space-lg);
    }
    .accreditation-eyebrow-row {
        justify-content: center;
    }
    .accreditation-meta-grid {
        grid-template-columns: 1fr 1fr;
        text-align: left;
    }
}

@media (max-width: 768px) {
    .whatsapp-float {
        bottom: 20px;
        right: 20px;
    }
    .whatsapp-float-tooltip {
        display: none;
    }
    .accreditation-meta-grid {
        grid-template-columns: 1fr;
    }
}
