/* ══════════════════════════════════════════════════════════════════
   Millennium Torque & Tensioning — Main Stylesheet
   milltorc.com
   ══════════════════════════════════════════════════════════════════ */

/* ── Fonts ────────────────────────────────────────────────────── */
/* Self-hosted copies of the Google Fonts files (Inter: SIL OFL 1.1, Roboto Slab: Apache 2.0 - licences in /fonts/).
   Rules copied from Google's own css2 response, latin + latin-ext subsets only (BUILD_LOG Step 29). */
/* latin-ext */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/inter-v20-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/inter-v20-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* latin-ext */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url('../fonts/inter-v20-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url('../fonts/inter-v20-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* latin-ext */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url('../fonts/inter-v20-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url('../fonts/inter-v20-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* latin-ext */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url('../fonts/inter-v20-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url('../fonts/inter-v20-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* latin-ext */
@font-face {
    font-family: 'Roboto Slab';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/roboto-slab-v36-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
    font-family: 'Roboto Slab';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/roboto-slab-v36-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* latin-ext */
@font-face {
    font-family: 'Roboto Slab';
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url('../fonts/roboto-slab-v36-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
    font-family: 'Roboto Slab';
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url('../fonts/roboto-slab-v36-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* latin-ext */
@font-face {
    font-family: 'Roboto Slab';
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url('../fonts/roboto-slab-v36-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
    font-family: 'Roboto Slab';
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url('../fonts/roboto-slab-v36-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ── Reset ────────────────────────────────────────────────────── */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 17px;
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 1rem;
    line-height: 1.7;
    color: var(--text);
    background-color: var(--white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img, picture, video, svg {
    display: block;
    max-width: 100%;
    height: auto;
}

a {
    color: var(--red);
    text-decoration: none;
    transition: color 0.2s ease;
}
a:hover {
    color: var(--red-dark);
}

ul, ol {
    list-style: none;
}

button, input, textarea, select {
    font: inherit;
    color: inherit;
}

table {
    border-collapse: collapse;
    width: 100%;
}

/* ── Custom Properties ────────────────────────────────────────── */
:root {
    /* Brand Colors — MTT Official Corporate Palette (PMS 1805 C / 421 C / Black 6 C) */
    --red:          #B2292E;  /* PMS 1805 C — Primary brand red */
    --red-dark:     #8A1F23;  /* Darker red for hover/active states */
    --red-light:    #C94449;  /* Lighter red for focus rings */
    --red-on-dark:  #D9575C;  /* Red TEXT on black (footer) - #B2292E there is 3.25:1, this is 5.47:1 */
    --charcoal:     #000000;  /* PMS Black 6 C — pure black for nav, hero, footer */
    --brand-gray:   #B0B3B2;  /* PMS 421 C — official brand gray */
    --med-gray:     #656666;  /* Medium gray — body text, subheads */

    /* Neutrals */
    --white:        #FFFFFF;
    --off-white:    #F7F7F7;
    --light-gray:   #F1F1F1;  /* Section backgrounds */
    --mid-gray:     #B0B3B2;  /* Brand gray — accents */
    --dark-gray:    #444444;
    --near-black:   #1a1d1e;

    /* Semantic */
    --text:         #333333;
    --text-light:   #656666;
    --text-on-dark: #E8E8E8;
    --border:       #DDDDDD;
    --success:      #27ae60;
    --error:        #c0392b;
    --warning:      #f39c12;

    /* Typography */
    --font-sans:    'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-serif:   'Roboto Slab', Georgia, 'Times New Roman', serif;

    /* Spacing Scale */
    --space-xs:     0.25rem;   /*  4px */
    --space-sm:     0.5rem;    /*  8px */
    --space-md:     1rem;      /* 17px */
    --space-lg:     1.5rem;    /* 25px */
    --space-xl:     2rem;      /* 34px */
    --space-2xl:    3rem;      /* 51px */
    --space-3xl:    4rem;      /* 68px */
    --space-4xl:    6rem;      /* 102px */

    /* Layout */
    --container-max:  1200px;
    --container-pad:  clamp(1.25rem, 4vw, 3rem);

    /* Transitions */
    --transition-fast:  0.15s ease;
    --transition:       0.25s ease;
    --transition-slow:  0.4s ease;

    /* Shadows */
    --shadow-sm:    0 1px 3px rgba(0, 0, 0, 0.08);
    --shadow-md:    0 4px 12px rgba(0, 0, 0, 0.1);
    --shadow-lg:    0 8px 30px rgba(0, 0, 0, 0.12);
}

/* ── Typography ───────────────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-serif);
    font-weight: 700;
    line-height: 1.2;
    color: var(--charcoal);
}

h1 {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: var(--space-lg);
}

h2 {
    font-size: clamp(1.6rem, 3vw, 2.25rem);
    margin-bottom: var(--space-md);
}

h3 {
    font-size: clamp(1.25rem, 2.5vw, 1.5rem);
    margin-bottom: var(--space-sm);
}

h4 {
    font-size: 1.15rem;
    margin-bottom: var(--space-sm);
}

p {
    margin-bottom: var(--space-md);
}

p:last-child {
    margin-bottom: 0;
}

.lead {
    font-size: 1.15rem;
    line-height: 1.8;
    color: var(--dark-gray);
}

strong {
    font-weight: 600;
}

small, .text-sm {
    font-size: 0.875rem;
}

.eyebrow {
    font-family: var(--font-sans);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--white);
    background-color: var(--red);
    padding: 3px 12px;
    border-radius: 2px;
    margin-bottom: 6px;
    display: inline-block;
    line-height: 1.4;
}


/* ── Layout ───────────────────────────────────────────────────── */
.container {
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding-left: var(--container-pad);
    padding-right: var(--container-pad);
}

.container--narrow {
    max-width: 800px;
}

.container--wide {
    max-width: 1400px;
}

.section {
    padding: 50px 0;
}

.section--sm {
    padding: var(--space-2xl) 0;
}

.section--lg {
    padding: var(--space-4xl) 0;
}

/* Warm-tint section (used for Industries on homepage to break up white) */
.section--warm {
    background-color: #F5F0F0;
}

/* Dark slate section — warm dark bg for card contrast without pure black harshness */
.section--slate {
    background-color: #2E3338;
}

.section--red {
    background-color: var(--red);
    color: var(--text-on-dark);
}
.section--red h2,
.section--red h3 {
    color: var(--white);
}

.section--charcoal {
    background-color: var(--charcoal);
    color: var(--text-on-dark);
}
.section--charcoal h2,
.section--charcoal h3 {
    color: var(--white);
}

.section--light {
    background-color: var(--off-white);
}

.section--gray {
    background-color: var(--light-gray);
}

/* Grid system */
.grid {
    display: grid;
    gap: var(--space-xl);
}

.grid--2 {
    grid-template-columns: repeat(2, 1fr);
}

.grid--3 {
    grid-template-columns: repeat(3, 1fr);
}

.grid--4 {
    grid-template-columns: repeat(4, 1fr);
}

.grid--6-4 {
    grid-template-columns: 3fr 2fr;
}

.grid--4-6 {
    grid-template-columns: 2fr 3fr;
}

/* Flex utilities */
.flex {
    display: flex;
}

.flex--center {
    align-items: center;
    justify-content: center;
}

.flex--between {
    justify-content: space-between;
    align-items: center;
}

.flex--wrap {
    flex-wrap: wrap;
}

.flex--col {
    flex-direction: column;
}

.gap-sm { gap: var(--space-sm); }
.gap-md { gap: var(--space-md); }
.gap-lg { gap: var(--space-lg); }
.gap-xl { gap: var(--space-xl); }

/* Text alignment */
.text-center { text-align: center; }
.text-left   { text-align: left; }

/* Button group — horizontal on desktop, stacks on mobile */
.btn-group {
    display: flex;
    justify-content: center;
    gap: var(--space-md);
    flex-wrap: wrap;
}

/* ── Buttons ──────────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5em;
    padding: 0.75em 1.75em;
    font-family: var(--font-sans);
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    text-decoration: none;
    border: 2px solid transparent;
    border-radius: 3px;
    cursor: pointer;
    transition: all var(--transition);
    line-height: 1;
}

.btn:focus-visible {
    outline: 3px solid var(--red-light);
    outline-offset: 2px;
}

.btn--primary {
    background-color: var(--red);
    color: var(--white);
    border-color: var(--red);
}
.btn--primary:hover {
    background-color: var(--red-dark);
    border-color: var(--red-dark);
    color: var(--white);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn--gold {
    background-color: var(--red);
    color: var(--white);
    border-color: var(--red);
}
.btn--gold:hover {
    background-color: var(--red-dark);
    border-color: var(--red-dark);
    color: var(--white);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn--outline {
    background-color: transparent;
    color: var(--red);
    border-color: var(--red);
}
.btn--outline:hover {
    background-color: var(--red);
    color: var(--white);
    transform: translateY(-1px);
}

.btn--outline-white {
    background-color: transparent;
    color: var(--white);
    border-color: var(--white);
}
.btn--outline-white:hover {
    background-color: var(--white);
    color: var(--charcoal);
}

.btn--lg {
    padding: 1em 2.25em;
    font-size: 1rem;
}

.btn--sm {
    padding: 0.5em 1.25em;
    font-size: 0.8rem;
}

/* ── Main — flex column so breadcrumbs can sit below the hero ── */
main {
    display: flex;
    flex-direction: column;
}

main > .hero {
    order: -1; /* Hero always renders first, above breadcrumbs */
}

/* ── Breadcrumbs ──────────────────────────────────────────────── */
.breadcrumbs {
    background-color: var(--off-white);
    border-bottom: 1px solid var(--border);
    padding: var(--space-sm) 0;
}

.breadcrumbs ol {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4em;
    font-size: 0.82rem;
    color: var(--text-light);
}

.breadcrumbs li:not(:last-child)::after {
    content: '/';
    margin-left: 0.4em;
    color: var(--mid-gray);
}

.breadcrumbs a {
    color: var(--text-light);
    text-decoration: none;
}
.breadcrumbs a:hover {
    color: var(--red);
    text-decoration: underline;
}

.breadcrumbs [aria-current="page"] {
    color: var(--charcoal);
    font-weight: 500;
}

/* ── Hero Section ─────────────────────────────────────────────── */
.hero {
    position: relative;
    background-color: var(--charcoal);
    color: var(--white);
    padding: var(--space-4xl) 0;
    overflow: hidden;
}

.hero--sm {
    min-height: 260px;            /* was height: 260px - taller text clipped; now the hero grows instead */
    padding: var(--space-lg) 0;   /* 25px floor above/below the text (phones keep .hero's padding, set below) */
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Centre the text block itself: the last line's bottom margin sat inside the centred box (desktop only) */
@media (min-width: 769px) {
    .hero--sm .hero__content > :last-child {
        margin-bottom: 0;
    }
}

.hero__bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero__bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    opacity: 0.55;
}

.hero__content {
    position: relative;
    z-index: 1;
    max-width: 720px;
}

.hero h1 {
    color: var(--white);
    margin-bottom: var(--space-md);
}

.hero .lead {
    color: var(--text-on-dark);
    margin-bottom: var(--space-xl);
}

/* Hero eyebrow: override pill — plain text with shadow for photo contrast */
.hero .eyebrow {
    color: var(--white);
    background-color: transparent;
    padding: 0;
    border-radius: 0;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
}

/* ── Cards ────────────────────────────────────────────────────── */
.card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 4px;
    overflow: hidden;
    transition: box-shadow var(--transition), transform var(--transition);
}

.card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.card__img {
    aspect-ratio: 16 / 10;
    overflow: hidden;
}

.card__img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.card:hover .card__img img {
    transform: scale(1.03);
}

.card__body {
    padding: var(--space-lg);
}

.card__title {
    font-family: var(--font-serif);
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: var(--space-sm);
}

.card__title a {
    color: var(--charcoal);
    text-decoration: none;
}
.card__title a:hover {
    color: var(--red);
}

.card__text {
    font-size: 0.92rem;
    color: var(--dark-gray);
    line-height: 1.65;
}

/* Horizontal card variant */
.card--horizontal {
    display: grid;
    grid-template-columns: 280px 1fr;
}

.card--horizontal .card__img {
    aspect-ratio: auto;
    height: 100%;
}

/* ── Service/Product Hub Grids ────────────────────────────────── */
.hub-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: var(--space-xl);
}

/* Link card: like a card but the whole thing is a link */
.link-card {
    display: block;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: var(--space-lg);
    text-decoration: none;
    color: var(--text);
    transition: all var(--transition);
    border-left: 5px solid var(--red);
}

.link-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
    border-left-color: var(--red-dark);
    color: var(--text);
}

.link-card__title {
    font-family: var(--font-serif);
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--charcoal);
    margin-bottom: var(--space-xs);
}

.link-card__desc {
    font-size: 0.9rem;
    color: var(--dark-gray);
    line-height: 1.6;
    margin-bottom: var(--space-sm);
}

.link-card__arrow {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--red);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    display: inline-block;
    line-height: 1.25;
}

.link-card:hover .link-card__arrow {
    color: var(--red-dark);
}

/* ── Shared inline header layout (icon + title side by side) ── */
.link-card__header {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    margin-bottom: var(--space-sm);
}

/* ── OPTION A1: Red top border + gray outline ────────────────── */
.link-card--option-a {
    display: block;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: var(--space-lg);
    padding-top: calc(var(--space-lg) + 4px);
    text-decoration: none;
    color: var(--text);
    transition: all var(--transition);
    border-top: 4px solid var(--red);
    position: relative;
}
.link-card--option-a:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
    color: var(--text);
}
.link-card--option-a .link-card__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: #FBF0F0;
    border-radius: 6px;
    flex-shrink: 0;
}
.link-card--option-a .link-card__icon svg {
    width: 22px;
    height: 22px;
    fill: none;
    stroke: var(--red);
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.link-card--option-a .link-card__title {
    font-family: var(--font-serif);
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--charcoal);
    line-height: 1.25;
}
.link-card--option-a .link-card__desc {
    font-size: 0.9rem;
    color: var(--dark-gray);
    line-height: 1.6;
    margin-bottom: var(--space-sm);
}
.link-card--option-a .link-card__arrow {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--red);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* ── Feature List (for service/product detail pages) ──────────── */
.feature-list {
    list-style: none;
    padding: 0;
}

.feature-list li {
    position: relative;
    padding-left: 1.75em;
    margin-bottom: var(--space-sm);
    line-height: 1.6;
}

.feature-list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.55em;
    width: 8px;
    height: 8px;
    background-color: var(--red);
    border-radius: 50%;
}

/* ── Content Sections (split image + text) ────────────────────── */
.split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-2xl);
    align-items: start;
}

.split--reverse {
    direction: rtl;
}

.split--reverse > * {
    direction: ltr;
}

.split__img {
    border-radius: 4px;
    overflow: hidden;
}

.split__img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.split__text h2 {
    margin-bottom: var(--space-md);
}

/* When the h2 is the first element in the text column (not lifted above
   the split), zero its top margin so the heading lines up with the top
   of the paired image instead of sitting ~51px lower. */
.split__text h2:first-child {
    margin-top: 0;
}

.split__text p {
    color: var(--dark-gray);
}

/* ── Spec Tables (product pages) ──────────────────────────────── */
.spec-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
    margin: var(--space-lg) 0;
}

.spec-table thead {
    background-color: var(--charcoal);
    color: var(--white);
}

.spec-table th {
    padding: 0.75em 1em;
    text-align: left;
    font-weight: 600;
    font-family: var(--font-sans);
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.spec-table td {
    padding: 0.75em 1em;
    border-bottom: 1px solid var(--border);
}

.spec-table tbody tr:nth-child(even) {
    background-color: var(--off-white);
}

.spec-table tbody tr:hover {
    background-color: var(--light-gray);
}

/* Wide spec tables scroll sideways inside this box on narrow screens instead of widening the whole page.
   The box takes the table's vertical margin, so spacing is unchanged where the table fits. */
.table-scroll {
    overflow-x: auto;
    margin: var(--space-lg) 0;
}

.table-scroll > .spec-table {
    margin: 0;
}

.table-scroll:focus-visible {
    outline: 3px solid var(--red-light);
    outline-offset: 2px;
}

@media (min-width: 1024px) {
    /* model numbers (MTA2-05...) stop breaking at the hyphen - only tables whose first column is all codes
       (class added by apply_layout.py; Nord-Lock's long product names keep wrapping) */
    .spec-table--codes td:first-child {
        white-space: nowrap;
    }

    /* engine tool-set parts lists: the same column widths in every table so the stacked tables line up */
    .spec-table--parts {
        table-layout: fixed;
    }

    .spec-table--parts th:nth-child(1) {
        width: 5rem;
    }

    .spec-table--parts th:nth-child(2) {
        width: 18.5rem;   /* the longest cell, "TDF-M036-37-04 / TDF-M036-37-05", needs 18rem on one line */
    }
}

/* ── CTA Banner ───────────────────────────────────────────────── */
.cta-banner {
    background-color: var(--red);
    color: var(--white);
    padding: var(--space-2xl) 0;
    text-align: center;
}

.cta-banner h2 {
    color: var(--white);
    margin-bottom: var(--space-sm);
}

.cta-banner p {
    color: var(--text-on-dark);
    margin-bottom: var(--space-lg);
    font-size: 1.1rem;
}

.cta-banner .btn--primary {
    background-color: var(--white);
    border-color: var(--white);
    color: var(--red);
}

.cta-banner .btn--primary:hover {
    background-color: var(--off-white);
    border-color: var(--off-white);
    color: var(--red-dark);
}

.cta-banner .btn:focus-visible {
    outline-color: var(--white);   /* the default red-light ring was invisible on the red band */
}

.cta-banner--alt {
    background-color: var(--charcoal);
    color: var(--white);
}
.cta-banner--alt h2 {
    color: var(--white);
}
.cta-banner--alt p {
    color: var(--text-on-dark);
}

/* ── Contact Form ─────────────────────────────────────────────── */
.contact-form {
    max-width: 640px;
}

.form-group {
    margin-bottom: var(--space-lg);
}

.form-group label {
    display: block;
    font-weight: 500;
    font-size: 0.9rem;
    margin-bottom: var(--space-xs);
    color: var(--charcoal);
}

.form-group label .required {
    color: var(--error);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.7em 0.9em;
    border: 1px solid var(--mid-gray);
    border-radius: 3px;
    background: var(--white);
    font-size: 1rem;
    transition: border-color var(--transition-fast);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--red);
    box-shadow: 0 0 0 3px rgba(178, 41, 46, 0.15);
}

.form-group textarea {
    min-height: 150px;
    resize: vertical;
}

.form-group input.error,
.form-group textarea.error,
.form-group select.error {
    border-color: var(--error);
}

.form-error {
    color: var(--error);
    font-size: 0.82rem;
    margin-top: var(--space-xs);
}

/* Honeypot — hidden from users */
.hp-field {
    position: absolute;
    left: -9999px;
    opacity: 0;
    height: 0;
    overflow: hidden;
}

.form-status {
    padding: var(--space-md);
    border-radius: 3px;
    margin-bottom: var(--space-lg);
    font-size: 0.92rem;
}

.form-status--success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.form-status--error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* ── Location Cards ───────────────────────────────────────────── */
.location-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 4px;
    border-top: 3px solid var(--red);
    overflow: hidden;   /* clip the branch photo to the card radius */
}

/* Branch photo. Fixed 3:2 box so every card in the row lines up whether or
   not a photo exists for that branch. */
.location-card__media {
    aspect-ratio: 3 / 2;
    background: var(--light-gray);
}

.location-card__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Branch with no photo supplied yet — a flat brand panel, deliberately
   readable as "no photo" rather than a stand-in for one. */
.location-card__media--nophoto {
    background: var(--light-gray);
    min-height: 8rem;   /* floor for browsers without aspect-ratio */
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Muted on purpose: a missing photo should read as quiet, not become the
   loudest element in the grid. */
.location-card__state {
    font-family: var(--font-serif);
    font-size: 2.2rem;
    font-weight: 600;
    line-height: 1;
    letter-spacing: 0.08em;
    color: var(--med-gray);
}

.location-card__body {
    padding: var(--space-lg);
}

.location-card__name {
    font-family: var(--font-serif);
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--charcoal);
    margin-bottom: var(--space-sm);
}

.location-card__address {
    font-size: 0.9rem;
    color: var(--dark-gray);
    line-height: 1.6;
    margin-bottom: var(--space-sm);
}

.location-card__region {
    font-size: 0.82rem;
    color: var(--text-light);
    font-style: italic;
}

/* ── Industry Page Tiles ──────────────────────────────────────── */
.industry-tile {
    display: block;
    position: relative;
    aspect-ratio: 16 / 9;
    border-radius: 4px;
    overflow: hidden;
    text-decoration: none;
    color: var(--white);
}

.industry-tile img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.industry-tile:hover img {
    transform: scale(1.05);
}

.industry-tile__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, transparent 60%);
    display: flex;
    align-items: flex-end;
    padding: var(--space-lg);
}

.industry-tile__title {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--white);
}

/* ── Stat Row (about / homepage) ──────────────────────────────── */
.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: var(--space-xl);
    text-align: center;
    padding: 0;
}

.stat__number {
    font-family: var(--font-serif);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    color: var(--white);
    line-height: 1.1;
}

.stat__label {
    font-size: 0.9rem;
    color: var(--white);
    margin-top: var(--space-xs);
    letter-spacing: 0.03em;
}

/* ── Photo Break ─────────────────────────────────────────────── */
.photo-break {
    position: relative;
    background-color: var(--charcoal);
    color: var(--white);
    padding: var(--space-4xl) 0;
    overflow: hidden;
    text-align: center;
}

.photo-break__bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.photo-break__bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    opacity: 0.2;
}

.photo-break__content {
    position: relative;
    z-index: 1;
    max-width: 700px;
    margin: 0 auto;
}

.photo-break h2 {
    font-family: var(--font-serif);
    color: var(--white);
    margin-bottom: var(--space-md);
}

.photo-break .lead {
    color: var(--text-on-dark);
}

/* ── Footer Styles ────────────────────────────────────────────── */
.site-footer {
    background-color: var(--charcoal);
    color: var(--text-on-dark);
    padding: var(--space-3xl) 0 var(--space-xl);
}

.site-footer__logo {
    display: block;
    margin-bottom: var(--space-lg);
}

.site-footer__logo img {
    display: block;
    width: 220px;
    height: auto;
}

.site-footer__col--brand .site-footer__availability {
    margin-bottom: var(--space-sm);
}

.site-footer__grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr 1fr;
    gap: var(--space-xl);
    margin-bottom: var(--space-2xl);
}

.site-footer__heading {
    font-family: var(--font-serif);
    font-size: 1rem;
    font-weight: 600;
    color: var(--white);
    margin-bottom: var(--space-md);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.site-footer ul li {
    margin-bottom: var(--space-xs);
}

.site-footer ul a {
    color: rgba(238, 241, 244, 0.75);
    font-size: 0.88rem;
    text-decoration: none;
    transition: color var(--transition-fast);
}

.site-footer ul a:hover {
    color: var(--white);
}

.site-footer__phone a,
.site-footer__email a {
    color: var(--text-on-dark);
    font-weight: 500;
    text-decoration: none;
}
.site-footer__phone a:hover,
.site-footer__email a:hover {
    color: var(--white);
}

.site-footer__phone {
    font-size: 1.1rem;
    margin-bottom: var(--space-sm);
}

.site-footer__email {
    margin-bottom: var(--space-md);
}

.site-footer__address {
    font-size: 0.88rem;
    line-height: 1.6;
    color: rgba(238, 241, 244, 0.75);
    margin-bottom: var(--space-md);
}

.site-footer__availability {
    font-size: 0.85rem;
    color: var(--red-on-dark);
    font-weight: 600;
}

.site-footer__bottom {
    border-top: 1px solid rgba(238, 241, 244, 0.15);
    padding-top: var(--space-lg);
    text-align: center;
    font-size: 0.82rem;
    color: rgba(238, 241, 244, 0.5);
}

.site-footer__locations {
    margin-top: var(--space-xs);
}

.site-footer__credit {
    margin-top: var(--space-xs);
}

.site-footer__credit a {
    color: rgba(238, 241, 244, 0.75);
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: color var(--transition-fast);
}

.site-footer__credit a:hover {
    color: var(--white);
}

/* ── 404 Page ─────────────────────────────────────────────────── */
.error-page {
    text-align: center;
    padding: var(--space-4xl) 0;
}

.error-page h1 {
    font-size: clamp(3rem, 8vw, 6rem);
    color: var(--red);
    margin-bottom: var(--space-sm);
}

.error-page p {
    font-size: 1.1rem;
    color: var(--dark-gray);
    margin-bottom: var(--space-lg);
}

/* ── Content Styles (for rich text areas) ─────────────────────── */
.content h2 {
    margin-top: var(--space-2xl);
}

.content h3 {
    margin-top: var(--space-xl);
}

.content ul,
.content ol {
    padding-left: 1.5em;
    margin-bottom: var(--space-md);
}

.content ul {
    list-style-type: disc;
}

/* Override when feature-list is inside .content (specificity fix) */
.content .feature-list {
    list-style: none;
    padding-left: 0;
}

.content ol {
    list-style-type: decimal;
}

.content li {
    margin-bottom: var(--space-xs);
    line-height: 1.7;
}

.content blockquote {
    border-left: 4px solid var(--red);
    padding: var(--space-md) var(--space-lg);
    background: var(--off-white);
    margin: var(--space-lg) 0;
    font-style: italic;
    color: var(--dark-gray);
}

/* ── Reveal / Scroll Animation ────────────────────────────────── */
.reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity var(--transition-slow), transform var(--transition-slow);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
}

/* ── Responsive ───────────────────────────────────────────────── */

/* Tablet */
@media (max-width: 1024px) {
    .grid--4 {
        grid-template-columns: repeat(2, 1fr);
    }

    .grid--6-4,
    .grid--4-6 {
        grid-template-columns: 1fr;
    }

    .split {
        grid-template-columns: 1fr;
        gap: var(--space-xl);
    }

    .split--reverse {
        direction: ltr;
    }

    .card--horizontal {
        grid-template-columns: 1fr;
    }

    .card--horizontal .card__img {
        aspect-ratio: 16 / 10;
    }

    .site-footer__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

a[href^="tel:"],
.nowrap {
    white-space: nowrap;
}

/* a button row in body copy wraps instead of overflowing (careers "How to Apply": no-wrap phone button + a second button) */
.content > .flex:has(> .btn) {
    flex-wrap: wrap;
}

/* Small tablets: the 3-up industry/product link cards don't fit (card min-content > column) - 2-up instead */
@media (min-width: 769px) and (max-width: 900px) {
    .grid--3:has(> .link-card--option-a) {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Mobile */
@media (max-width: 768px) {
    html {
        font-size: 16px;
    }

    .section {
        padding: var(--space-2xl) 0;
    }

    .section--lg {
        padding: var(--space-3xl) 0;
    }

    .hero {
        padding: var(--space-2xl) 0;
    }

    .grid--2,
    .grid--3 {
        grid-template-columns: 1fr;
    }

    .hub-grid {
        grid-template-columns: 1fr;
    }

    .stats {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--space-lg);
    }

    .site-footer__grid {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
    }

    .cta-banner {
        padding: var(--space-xl) 0;
    }

    /* Stack button pairs on mobile */
    .hero .flex,
    .cta-banner .flex,
    .btn-group {
        flex-direction: column;
    }

    .hero .flex {
        align-items: flex-start;
    }

    .hero--sm {
        height: auto;
        min-height: 200px;
    }

    .cta-banner .flex,
    .btn-group {
        align-items: center;
    }
}

/* Small mobile */
@media (max-width: 480px) {
    html {
        font-size: 15px;
    }

    .stats {
        grid-template-columns: 1fr;
    }
}

/* ── Print Styles ─────────────────────────────────────────────── */
@media print {
    .top-bar,
    .site-header,
    .site-footer,
    .breadcrumbs,
    .cta-banner,
    .btn {
        display: none !important;
    }

    body {
        color: #000;
        background: #fff;
        font-size: 12pt;
    }

    a {
        color: #000;
        text-decoration: underline;
    }

    h1, h2, h3 {
        page-break-after: avoid;
    }

    img {
        max-width: 100% !important;
    }
}
