/* Factor IT boilerplate styles. Palette tokens in :root below; rationale in CLAUDE.md. */

:root {
    --navy: #6c6e72;
    --navy-2: #7d7f83;
    --cyan: #5A7FA8;
    --cyan-ink: #ffffff;
    --req: #D64545;
    --ok: #2E7D57;
    --ink: #0E1A33;
    --mute: #5A6A85;
    --line: #E5E9F0;
    --bg: #FFFFFF;
    --bg-soft: #F5F7FB;
    --radius: 10px;
    --radius-lg: 18px;
    --shadow: 0 6px 24px rgba(108, 110, 114, 0.10);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
    margin: 0;
    font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--ink);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--cyan); text-decoration: none; }
a:hover, a:focus-visible { text-decoration: underline; }

h1, h2, h3, h4 { margin: 0 0 0.6em; line-height: 1.15; letter-spacing: -0.01em; }
h1 { font-size: clamp(2rem, 3.6vw, 3.25rem); font-weight: 700; }
h2 { font-size: clamp(1.6rem, 2.6vw, 2.25rem); font-weight: 700; }
h3 { font-size: 1.15rem; font-weight: 600; }
h4 { font-size: 0.95rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; }
p { margin: 0 0 1em; }
ul { margin: 0; padding: 0; list-style: none; }

/* ---------- Accessibility: main landmark + skip link ---------- */
main { display: block; }
main:focus { outline: none; }
.skip-link {
    position: absolute;
    left: 0.5rem;
    top: -3.5rem;
    z-index: 2000;
    padding: 0.6rem 1rem;
    background: var(--ink);
    color: #fff;
    border-radius: 0 0 8px 8px;
    transition: top 0.2s ease;
}
.skip-link:focus { top: 0; text-decoration: none; }

.container {
    width: 100%;
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* ---------- Buttons & links ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.85rem 1.25rem;
    font-weight: 600;
    border-radius: 999px;
    border: 0;
    cursor: pointer;
    transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
/* Glass-style primary button (matches the pill nav aesthetic) */
.btn-primary {
    background: rgba(20, 22, 28, 0.88);
    -webkit-backdrop-filter: blur(10px) saturate(140%);
    backdrop-filter: blur(10px) saturate(140%);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.12);
    font-weight: 600;
}
.btn-primary:hover {
    text-decoration: none;
    background: rgba(10, 12, 18, 0.96);
    border-color: rgba(255, 255, 255, 0.28);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.14);
}

/* Header CTA sits inside the dark pill, invert it to white-glass for contrast */
.header-cta.btn-primary {
    background: rgba(255, 255, 255, 0.92);
    color: var(--ink);
    border-color: rgba(255, 255, 255, 0.50);
}
.header-cta.btn-primary:hover {
    background: #ffffff;
    border-color: #ffffff;
}

/* Right-pointing chevron for CTAs (drop-in replacement for the old &rarr; span) */
.btn-chev {
    display: inline-block;
    width: 0.45em;
    height: 0.45em;
    border-right: 2px solid currentColor;
    border-top: 2px solid currentColor;
    transform: rotate(45deg) translateY(1px);
    margin-left: 0.5em;
    transition: margin-left 0.2s ease;
}
.btn-primary:hover .btn-chev,
.link-arrow:hover .btn-chev { margin-left: 0.75em; }
.btn-sm { padding: 0.6rem 1rem; font-size: 0.9rem; }

/* Restores [hidden], which .btn's display:inline-flex would otherwise override. */
.btn[hidden] { display: none; }

/* Plus / minus glyph for the blog View More / View Less buttons */
.btn-pm {
    display: block;
    width: 1.05em;
    height: 1.05em;
    flex: none;
}

.link-arrow {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-weight: 600;
    color: var(--cyan);
}

/* ---------- Header / Nav (floating glass pill) ---------- */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 50;
    padding: 1rem 0 0;
    background: transparent;
    color: #fff;
    pointer-events: none;
}
.header-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    width: fit-content;
    max-width: calc(100% - 2rem);
    margin: 0 auto;
    padding: 0.5rem 0.75rem 0.5rem 1.25rem;
    pointer-events: auto;
    background: rgba(30, 32, 36, 0.65);
    -webkit-backdrop-filter: blur(14px) saturate(140%);
    backdrop-filter: blur(14px) saturate(140%);
    border: 1px solid rgba(255, 255, 255, 0.10);
    border-radius: 999px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.28);
}
.brand {
    color: #fff;
    font-weight: 800;
    font-size: 1.25rem;
    letter-spacing: -0.02em;
    display: inline-flex;
    align-items: center;
}
.brand:hover { text-decoration: none; }
.brand-dot { color: var(--cyan); }
.brand-logo {
    display: block;
    height: 36px;
    width: auto;
}
.site-footer .brand-logo { height: 42px; }

.primary-nav ul {
    display: flex;
    gap: 1.75rem;
    list-style: none;
    margin: 0;
    padding: 0;
}
.primary-nav a {
    color: #fff;
    font-size: 0.95rem;
    opacity: 0.85;
}
.primary-nav a:hover { opacity: 1; text-decoration: none; }

/* Duplicate of the header CTA on desktop; restored in the mobile drawer, where the CTA is hidden. */
.primary-nav li:has(> a[href$="contact.html"]) { display: none; }

/* ---------- Dropdown submenu (desktop) ---------- */
.has-submenu { position: relative; }
.has-submenu > a { display: inline-flex; align-items: center; gap: 0.4rem; }
.chev {
    display: inline-block;
    width: 0.5rem;
    height: 0.5rem;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg) translate(-1px, -1px);
    opacity: 0.7;
    transition: transform 0.2s ease, opacity 0.2s ease;
}
.has-submenu:hover > a .chev,
.has-submenu:focus-within > a .chev {
    transform: rotate(225deg) translate(-1px, -1px);
    opacity: 1;
}
.submenu {
    display: block;
    position: absolute;
    top: calc(100% + 0.5rem);
    left: 50%;
    transform: translateX(-50%) translateY(-6px);
    background: rgba(255, 255, 255, 0.97);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    list-style: none;
    padding: 0.4rem;
    margin: 0;
    min-width: 240px;
    border: 1px solid rgba(108, 110, 114, 0.15);
    border-radius: var(--radius-lg);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.18);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s;
    z-index: 100;
}
.submenu::before {
    content: "";
    position: absolute;
    top: -0.5rem;
    left: 0;
    right: 0;
    height: 0.5rem;
}
.has-submenu:hover > .submenu,
.has-submenu:focus-within > .submenu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}
.submenu li { display: block; }
.submenu a {
    display: block;
    padding: 0.55rem 0.9rem;
    white-space: nowrap;
    color: var(--ink);
    border-radius: var(--radius);
    font-weight: 500;
    opacity: 1;
}
.submenu a:hover {
    background: rgba(108, 110, 114, 0.10);
    color: var(--navy);
    text-decoration: none;
}

/* ---------- Hamburger (mobile toggle) ---------- */
.nav-toggle {
    display: none;
    position: relative;
    width: 40px;
    height: 40px;
    background: transparent;
    border: 0;
    padding: 0;
    margin-left: auto;
    cursor: pointer;
    color: #fff;
}
.nav-toggle-bar {
    position: absolute;
    left: 8px;
    width: 24px;
    height: 2px;
    background: currentColor;
    border-radius: 2px;
    transition: top 0.35s ease, transform 0.45s ease, opacity 0.25s ease;
}
.nav-toggle-bar:nth-child(1) { top: 13px; }
.nav-toggle-bar:nth-child(2) { top: 19px; }
.nav-toggle-bar:nth-child(3) { top: 25px; }
.nav-toggle.is-open .nav-toggle-bar:nth-child(1) {
    top: 19px;
    transform: rotate(405deg);
}
.nav-toggle.is-open .nav-toggle-bar:nth-child(2) {
    opacity: 0;
    transform: rotate(360deg);
}
.nav-toggle.is-open .nav-toggle-bar:nth-child(3) {
    top: 19px;
    transform: rotate(-405deg);
}

/* ---------- Hero ---------- */
.hero {
    background: var(--navy);
    color: #fff;
    padding: 4.5rem 0 5.5rem;
}
.hero-grid {
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: 3rem;
    align-items: center;
}
.hero-copy h1 { color: #fff; max-width: 18ch; }
.hero-copy .lede {
    color: rgba(255,255,255,0.78);
    font-size: 1.05rem;
    max-width: 48ch;
    margin-bottom: 1.75rem;
}
.hero-media .img-placeholder { aspect-ratio: 4 / 3; }

/* Full-bleed hero variant: image fills the section, text overlays */
.hero-cover {
    position: relative;
    padding: 0;
    min-height: 560px;
    display: flex;
    align-items: center;
    overflow: hidden;
}
.hero-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 25%;
    z-index: 0;
}
.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        90deg,
        rgba(30, 32, 36, 0.92) 0%,
        rgba(30, 32, 36, 0.78) 35%,
        rgba(30, 32, 36, 0.35) 70%,
        rgba(30, 32, 36, 0.15) 100%
    );
    z-index: 1;
}
.hero-content {
    position: relative;
    z-index: 2;
    width: 100%;
    padding-top: 5rem;
    padding-bottom: 5rem;
}
.hero-cover .hero-copy { max-width: 36rem; }
.hero-cover .hero-copy h1 {
    max-width: none;
    font-size: clamp(2rem, 4vw, 3rem);
    text-shadow: 0 2px 24px rgba(0, 0, 0, 0.35);
}
.hero-cover .hero-copy .lede {
    color: rgba(255, 255, 255, 0.92);
    text-shadow: 0 1px 12px rgba(0, 0, 0, 0.4);
}

/* Staggered drop-in animation for the hero copy */
@keyframes hero-drop {
    from { opacity: 0; transform: translateY(-14px); }
    to   { opacity: 1; transform: translateY(0); }
}
.hero-cover .hero-copy > * {
    animation: hero-drop 0.7s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.hero-cover .hero-copy > *:nth-child(1) { animation-delay: 0.10s; }
.hero-cover .hero-copy > *:nth-child(2) { animation-delay: 0.25s; }
.hero-cover .hero-copy > *:nth-child(3) { animation-delay: 0.40s; }

@media (prefers-reduced-motion: reduce) {
    .hero-cover .hero-copy > * { animation: none; }
}

/* ---------- Section base ---------- */
.section { padding: 5rem 0; }
.two-col {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 3rem;
    align-items: start;
}

/* ---------- What we do ---------- */
.what-we-do { background: var(--bg); }
.what-we-do .col-intro h2 { color: var(--ink); }
.what-we-do .col-intro p { color: var(--mute); max-width: 38ch; }
.service-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}
.service-card {
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 1.5rem;
    transition: transform .15s ease, box-shadow .15s ease;
}
.service-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.service-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px; height: 44px;
    border-radius: 10px;
    background: color-mix(in srgb, var(--cyan) 14%, transparent);
    color: var(--cyan);
    margin-bottom: 1rem;
}
.service-icon svg { display: block; width: 22px; height: 22px; }
.service-card h3 { margin-bottom: 0.4rem; }
.service-card p { color: var(--mute); font-size: 0.95rem; margin: 0; }

/* ---------- Sustainable IT ---------- */
.sustainable {
    background: var(--navy);
    color: #fff;
}
.sustainable h2 { color: #fff; max-width: 18ch; }
.sustainable p { color: rgba(255,255,255,0.78); max-width: 52ch; }
.sustainable .img-placeholder { aspect-ratio: 4 / 3; }

/* ---------- Why choose (split) ---------- */
/* .section.why-choose (0,2,0) beats the mobile `.section { padding }` override, which would show a white gap. */
.section.why-choose { padding: 0; }
.why-grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    min-height: 480px;
}
.why-intro {
    background: var(--navy);
    color: #fff;
    display: flex;
    align-items: center;
}
.why-intro-inner {
    margin-left: auto;
    max-width: 520px;
    padding: 5rem 3rem 5rem 1.5rem;
    width: 100%;
}
.why-intro h2 { color: #fff; }
.why-intro p { color: rgba(255,255,255,0.78); }

.why-faq {
    background: var(--bg);
    display: flex;
    align-items: center;
}
.why-faq-inner {
    max-width: 640px;
    padding: 5rem 1.5rem 5rem 3rem;
    width: 100%;
}
.faq-item {
    border-bottom: 1px solid var(--line);
    padding: 1rem 0;
}
.faq-item summary {
    cursor: pointer;
    font-weight: 600;
    font-size: 1.05rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    list-style: none;
    color: var(--ink);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
    content: "+";
    color: var(--cyan);
    font-size: 1.5rem;
    font-weight: 400;
    line-height: 1;
    transition: transform 0.3s ease;
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-body { padding-top: 0.75rem; color: var(--mute); }
.faq-body p { margin: 0; }

/* Smooth drop-down animation for FAQ items (modern browsers) */
@supports (interpolate-size: allow-keywords) {
    :root { interpolate-size: allow-keywords; }

    .faq-item::details-content {
        opacity: 0;
        block-size: 0;
        overflow: clip;
        transition:
            opacity 0.25s ease,
            block-size 0.35s ease,
            content-visibility 0.35s allow-discrete;
    }
    .faq-item[open]::details-content {
        opacity: 1;
        block-size: auto;
    }
}

@media (prefers-reduced-motion: reduce) {
    .faq-item summary::after,
    .faq-item::details-content { transition: none; }
}

/* ---------- Testimonials ---------- */
.testimonials { background: var(--bg); }
.testimonials .col-intro h2 { color: var(--ink); }
.testimonials .col-intro p { color: var(--mute); }
.stars { color: var(--cyan); font-size: 1.25rem; letter-spacing: 0.15em; margin-top: 0.5rem; }
.col-quotes { display: grid; gap: 1.5rem; }
.quote {
    position: relative;
    margin: 0;
    padding: 1.5rem 1.5rem 1.5rem 2.75rem;
    background: var(--bg-soft);
    border-radius: var(--radius);
    border: 1px solid var(--line);
}
.quote-mark {
    position: absolute;
    top: 0.4rem;
    left: 0.9rem;
    font-size: 3.5rem;
    line-height: 1;
    color: var(--cyan);
    font-family: Georgia, serif;
}
.quote p { color: var(--ink); margin-bottom: 0.75rem; }
.quote footer { color: var(--mute); font-size: 0.9rem; font-weight: 600; }

/* ---------- Testimonial switcher (one at a time) ---------- */
.quote-switcher .quote { display: none; }
.quote-switcher .quote.is-active { display: block; animation: quote-fade 0.35s ease; }
@keyframes quote-fade {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: none; }
}
.quote-controls {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: 0.25rem;
}
.quote-dots {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    flex: 1;
}
.quote-dot {
    width: 9px;
    height: 9px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: var(--line);
    cursor: pointer;
    transition: background 0.15s ease, transform 0.15s ease;
}
.quote-dot:hover { background: var(--mute); }
.quote-dot.is-active { background: var(--cyan); transform: scale(1.15); }
.quote-nav {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: none;
    width: 38px;
    height: 38px;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: var(--bg-soft);
    color: var(--ink);
    cursor: pointer;
    transition: border-color 0.15s ease, color 0.15s ease;
}
.quote-nav:hover { border-color: var(--cyan); color: var(--cyan); }
.quote-nav .btn-chev { margin: 0; }
.quote-next .btn-chev { transform: rotate(45deg) translateY(1px); }
.quote-prev .btn-chev { transform: rotate(-135deg) translateY(1px); }
@media (prefers-reduced-motion: reduce) {
    .quote-switcher .quote.is-active { animation: none; }
}

/* ---------- News & Insights ---------- */
.news { background: var(--bg); }
.section-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2.5rem;
}
.section-head h2 { margin: 0; }
.news-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}
.news-card {
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.news-card .img-placeholder {
    aspect-ratio: 16 / 10;
    border-radius: 0;
    border: 0;
    border-bottom: 1px solid var(--line);
}
.news-card h3 { padding: 1.25rem 1.25rem 0.25rem; font-size: 1.05rem; line-height: 1.35; }
.news-card p { padding: 0 1.25rem 1.5rem; color: var(--mute); font-size: 0.95rem; margin: 0; }

/* ---------- Ready-to-talk CTA ---------- */
.cta-strip {
    background: var(--navy);
    color: #fff;
}
.cta-strip h2 { color: #fff; max-width: 20ch; }
.cta-strip .img-placeholder { aspect-ratio: 16 / 10; }

/* ---------- Footer ---------- */
.site-footer {
    background: var(--navy);
    color: rgba(255,255,255,0.78);
    padding-top: 3.5rem;
}
.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
    gap: 2rem;
    padding-bottom: 2.5rem;
}
.footer-brand p { max-width: 36ch; margin-top: 0.75rem; }
.footer-col h4 { color: #fff; margin-bottom: 1rem; }
.footer-col ul li { padding: 0.25rem 0; }
.footer-col a { color: rgba(255,255,255,0.78); }
.footer-col a:hover { color: #fff; }
.social {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
}
.social a {
    display: inline-flex;
    width: 36px; height: 36px;
    border-radius: 50%;
    background: rgba(255,255,255,0.08);
    align-items: center;
    justify-content: center;
    color: #fff;
    transition: background 0.2s ease, color 0.2s ease, transform 0.18s ease, box-shadow 0.2s ease;
}
.social a:hover { text-decoration: none; transform: translateY(-2px); }
.social a svg { width: 16px; height: 16px; display: block; }

/* Brand-coloured hover states (work for both .social and .social-contact) */
.social a.social-facebook:hover,
.social-contact a.social-facebook:hover {
    background: #1877F2;
    color: #fff;
    border-color: #1877F2;
    box-shadow: 0 6px 16px rgba(24, 119, 242, 0.35);
}
.social a.social-linkedin:hover,
.social-contact a.social-linkedin:hover {
    background: #0A66C2;
    color: #fff;
    border-color: #0A66C2;
    box-shadow: 0 6px 16px rgba(10, 102, 194, 0.35);
}
.social a.social-instagram:hover,
.social-contact a.social-instagram:hover {
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 6px 16px rgba(220, 39, 67, 0.35);
}

.footer-base {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
    padding-top: 1.25rem;
    padding-bottom: 1.5rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.6);
    font-size: 0.85rem;
}
.footer-base a { color: rgba(255,255,255,0.78); }

/* ---------- Real media images (use in place of .img-placeholder) ---------- */
.media-img {
    display: block;
    width: 100%;
    object-fit: cover;
    border-radius: var(--radius-lg);
}
.hero-media .media-img,
.sustainable .media-img,
.why-block .media-img,
.service-detail .media-img { aspect-ratio: 4 / 3; }
.cta-strip .media-img,
.news-card .media-img { aspect-ratio: 16 / 10; }
img.team-photo {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    display: block;
    border-radius: 0;
    border: 0;
    border-right: 1px solid var(--line);
}

/* ---------- Image placeholders ---------- */
.img-placeholder {
    background:
        repeating-linear-gradient(
            45deg,
            rgba(255,255,255,0.04) 0 10px,
            rgba(255,255,255,0.08) 10px 20px
        ),
        linear-gradient(135deg, #7d7f83, #5c5e62);
    border: 1px dashed rgba(255,255,255,0.25);
    border-radius: var(--radius-lg);
    color: rgba(255,255,255,0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}
/* on white sections, give placeholders a light variant */
.what-we-do .img-placeholder,
.testimonials .img-placeholder,
.news .img-placeholder,
.services-detail .img-placeholder,
.assessment .img-placeholder,
.trial-offers .img-placeholder,
.team-section .img-placeholder,
.contact-section .img-placeholder,
.blog-list .img-placeholder,
.post-feature .img-placeholder,
.post-related .img-placeholder,
.why-block .img-placeholder {
    background:
        repeating-linear-gradient(
            45deg,
            rgba(108,110,114,0.05) 0 10px,
            rgba(108,110,114,0.10) 10px 20px
        ),
        linear-gradient(135deg, #ececee, #d8dade);
    border-color: rgba(108,110,114,0.22);
    color: var(--mute);
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
    .hero { padding: 2.5rem 0 2.75rem; }
    .hero-cover {
        padding: 0;
        min-height: 480px;
    }
    .hero-cover .hero-bg { object-position: 70% center; }
    .hero-cover .hero-overlay {
        background: linear-gradient(
            180deg,
            rgba(30, 32, 36, 0.75) 0%,
            rgba(30, 32, 36, 0.85) 60%,
            rgba(30, 32, 36, 0.92) 100%
        );
    }
    /* The hero centres its copy, so this top padding is the only thing keeping the
       h1 clear of the fixed pill (~74px tall here) once the copy outgrows min-height. */
    .hero-cover .hero-content { padding-top: 6rem; padding-bottom: 3.5rem; }
    .hero-grid,
    .two-col,
    .why-grid,
    .news-grid,
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    /* Full-bleed colour blocks must touch; the stack gap would show a white strip between them. */
    .why-grid { gap: 0; }
    .why-intro-inner,
    .why-faq-inner {
        max-width: none;
        padding: 2.25rem 1.5rem;
    }
    .service-grid { grid-template-columns: 1fr 1fr; }

    /* Mobile density pass: trim desktop-scale spacing, since sections stack single-column. */
    .section { padding: 2.75rem 0; }
    /* Tighter reading rhythm so long copy doesn't feel endless on a phone. */
    body { line-height: 1.5; }
    p { margin-bottom: 0.85em; }
    .page-hero { padding: 6rem 0 2rem; }
    .section-head { margin-bottom: 1.75rem; }
    .section-head-centered { margin-bottom: 2rem; }
    .page-hero .lede,
    .hero-copy .lede { font-size: 1rem; }

    /* Hamburger replaces inline nav */
    .nav-toggle { display: block; }
    .header-cta { display: none; }

    /* Wider pill on mobile, brand left, hamburger right */
    .header-inner {
        min-width: min(420px, calc(100% - 2rem));
        justify-content: space-between;
        padding: 0.5rem 0.75rem 0.5rem 1.5rem;
    }

    .primary-nav {
        position: absolute;
        top: calc(100% + 0.5rem);
        left: 1rem;
        right: 1rem;
        background: rgba(30, 32, 36, 0.92);
        -webkit-backdrop-filter: blur(14px);
        backdrop-filter: blur(14px);
        border: 1px solid rgba(255, 255, 255, 0.10);
        border-radius: var(--radius-lg);
        box-shadow: 0 16px 36px rgba(0, 0, 0, 0.28);
        max-height: 0;
        overflow: hidden;
        opacity: 0;
        visibility: hidden;
        transition: max-height 0.35s ease, opacity 0.2s ease, visibility 0.35s;
    }
    .primary-nav.is-open {
        max-height: calc(100vh - 6rem);
        overflow-y: auto;
        opacity: 1;
        visibility: visible;
    }
    .primary-nav ul {
        display: block;
        gap: 0;
        padding: 0.5rem 1.5rem 1.25rem;
    }
    .primary-nav > ul > li {
        display: block;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    }
    .primary-nav > ul > li:last-child { border-bottom: 0; }
    /* CTA button is hidden on mobile, so restore the Contact item in the drawer */
    .primary-nav li:has(> a[href$="contact.html"]) { display: block; }
    .primary-nav > ul > li > a {
        display: block;
        padding: 1rem 0;
        font-size: 1.05rem;
        opacity: 1;
    }

    /* Subsections are never shown on mobile per spec */
    .submenu { display: none !important; }
    .has-submenu > a .chev { display: none; }
}

/* <=540px and <=420px sit after <=640px so the breakpoints cascade in descending width order. */

/* ---------- Inner-page layouts ---------- */

/* ---------- Eyebrow ---------- */
.eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--cyan);
    margin: 0 0 0.6rem;
}
/* Slate-blue cannot reach WCAG AA on the --navy grey at this small bold size, so light eyebrows go near-white. */
.eyebrow-light { color: color-mix(in srgb, var(--cyan) 8%, #ffffff); }

/* ---------- Page hero (inner pages, light) ---------- */
.page-hero {
    background: var(--bg-soft);
    /* extra top padding clears the fixed-position floating nav pill */
    padding: 7rem 0 3rem;
    border-bottom: 1px solid var(--line);
}
.page-hero h1 { margin: 0 0 0.5rem; }
.page-hero .lede { color: var(--mute); font-size: 1.1rem; max-width: 60ch; margin: 0; }
/* The cyber-security page-hero is the only one carrying a CTA; give it room */
.page-hero .btn { margin-top: 1.75rem; }

/* ---------- Section head (centered variant) ---------- */
/* display:block overrides the inherited flex so heading + sub stack and centre. */
.section-head-centered { display: block; text-align: center; margin-bottom: 3rem; }
.section-head-centered h2 { margin-bottom: 0.5rem; }
.section-sub { color: var(--mute); max-width: 56ch; margin: 0 auto; }

/* ---------- Services detail (long-form list) ---------- */
.service-detail {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 3rem;
    align-items: center;
    padding: 3rem 0;
    border-bottom: 1px solid var(--line);
}
.service-detail:last-child { border-bottom: 0; }
.service-detail:nth-child(even) .service-detail-media { order: 2; }
.service-detail .img-placeholder { aspect-ratio: 4 / 3; }
.service-number {
    display: inline-block;
    color: var(--cyan);
    font-weight: 700;
    letter-spacing: 0.12em;
    margin-bottom: 0.5rem;
}
.service-detail h2 { margin-bottom: 1rem; }
.sub-offerings {
    list-style: none;
    margin: 1rem 0 1.5rem;
    padding: 0;
}
.sub-offerings li {
    padding: 0.5rem 0 0.5rem 1.5rem;
    position: relative;
    border-bottom: 1px solid var(--line);
}
.sub-offerings li:last-child { border-bottom: 0; }
/* CSS-drawn chevron matching .btn-chev; the brand rule rules out unicode arrows. */
.sub-offerings li::before {
    content: "";
    position: absolute;
    left: 2px;
    top: 1em;
    width: 0.4em;
    height: 0.4em;
    border-right: 2px solid var(--cyan);
    border-top: 2px solid var(--cyan);
    transform: rotate(45deg);
}

/* ---------- Cyber security: assessment features ---------- */
.feature-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
    list-style: none;
    padding: 0;
    counter-reset: feature;
}
.feature-card {
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 1.75rem;
}
.feature-num {
    display: inline-block;
    color: var(--cyan);
    font-weight: 700;
    letter-spacing: 0.12em;
    margin-bottom: 0.75rem;
}
.feature-card h3 { font-size: 1.15rem; margin-bottom: 0.5rem; }
.feature-card p { color: var(--mute); margin: 0; font-size: 0.95rem; }

/* ---------- Cyber security: trial offers ---------- */
.trial-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}
.trial-card {
    background: var(--navy);
    color: #fff;
    border-radius: var(--radius-lg);
    padding: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.trial-card h3 { color: #fff; }
.trial-card p { color: rgba(255,255,255,0.78); margin: 0; flex: 1; }
.trial-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px; height: 44px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
}
.trial-icon svg { display: block; width: 24px; height: 24px; }
.trial-card .btn { align-self: flex-start; }

/* ---------- Cyber security: why block ---------- */
.why-block { background: var(--bg-soft); }
.why-block .img-placeholder { aspect-ratio: 4 / 3; }

/* ---------- Team ---------- */
.team-section { background: var(--bg); }
.team-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    list-style: none;
    padding: 0;
}
.team-card {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 1.5rem;
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    overflow: hidden;
}
.team-photo {
    aspect-ratio: 1 / 1;
    border-radius: 0;
    border: 0;
    border-right: 1px solid var(--line);
}
.team-info { padding: 1.5rem 1.5rem 1.5rem 0; }
.team-mascot {
    color: var(--cyan);
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-size: 0.8rem;
    margin: 0 0 0.25rem;
}
.team-info h3 { font-size: 1.4rem; margin: 0 0 0.25rem; }
.team-role { color: var(--mute); font-weight: 600; margin: 0 0 0.75rem; }
.team-bio { color: var(--ink); margin: 0; font-size: 0.95rem; }

/* ---------- Contact ---------- */
.contact-section { background: var(--bg); }
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.4fr;
    gap: 3rem;
    align-items: start;
}
.contact-info h2 { margin-bottom: 1.5rem; }
.contact-block { margin-bottom: 1.25rem; }
.contact-block h3 {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--mute);
    margin: 0 0 0.25rem;
    font-weight: 700;
}
.contact-block p { margin: 0; font-size: 1.05rem; }
.contact-block a {
    color: var(--ink);
    text-decoration: underline;
    text-decoration-color: rgba(108, 110, 114, 0.35);
    text-underline-offset: 3px;
    font-weight: 600;
}
.contact-block a:hover {
    color: var(--navy);
    text-decoration-color: var(--navy);
}
.social-contact {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
}
.social-contact a {
    display: inline-flex;
    width: 40px; height: 40px;
    border-radius: 50%;
    background: var(--bg-soft);
    border: 1px solid var(--line);
    align-items: center;
    justify-content: center;
    color: var(--navy);
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.18s ease, box-shadow 0.2s ease;
}
.social-contact a:hover { text-decoration: none; transform: translateY(-2px); }
.social-contact a svg { width: 18px; height: 18px; display: block; }

.contact-form-wrap {
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: 2rem;
}
.enquiry-form .form-intro { color: var(--mute); margin: 0 0 1.5rem; }
.form-row { margin-bottom: 1.25rem; }
.form-row label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.4rem;
    font-size: 0.95rem;
}
.form-row .req { color: var(--req); margin-left: 0.15rem; }
.form-row input,
.form-row select,
.form-row textarea {
    width: 100%;
    padding: 0.75rem 0.85rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    font: inherit;
    color: var(--ink);
}
.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
    outline: 2px solid var(--cyan);
    outline-offset: 1px;
    border-color: var(--cyan);
}
.form-row textarea { resize: vertical; min-height: 120px; }
.form-disclaimer {
    margin-top: 1.25rem;
    font-size: 0.8rem;
    color: var(--mute);
    line-height: 1.5;
}

/* ---------- Contact form: honeypot, status, field errors ---------- */
/* Honeypot: off-screen, not display:none or hidden, both of which bots skip. Out of the tab order, aria-hidden in markup. */
.form-trap {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

/* Submission result, written by js/main.js. */
.form-status {
    margin: 1rem 0 0;
    padding: 0.75rem 0.9rem;
    border-radius: 8px;
    border: 1px solid var(--line);
    background: var(--bg-soft);
    font-size: 0.9rem;
    line-height: 1.5;
    color: var(--mute);
}
.form-status.is-ok {
    border-color: color-mix(in srgb, var(--ok) 35%, transparent);
    background: color-mix(in srgb, var(--ok) 8%, #ffffff);
    color: color-mix(in srgb, var(--ok) 80%, var(--ink));
    font-weight: 600;
}
.form-status.is-error {
    border-color: color-mix(in srgb, var(--req) 35%, transparent);
    background: color-mix(in srgb, var(--req) 7%, #ffffff);
    color: color-mix(in srgb, var(--req) 70%, var(--ink));
    font-weight: 600;
}
/* Error list on the no-JS response page from api/contact.php. */
.form-status-list {
    margin: 0.75rem 0 0;
    padding-left: 1.15rem;
    color: var(--mute);
    font-size: 0.9rem;
}

/* Per-field message, appended to the .form-row by js/main.js. */
.field-error {
    display: block;
    margin-top: 0.35rem;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--req);
}
.form-row input[aria-invalid="true"],
.form-row textarea[aria-invalid="true"] {
    border-color: var(--req);
}
/* The native select is hidden, so the invalid state shows on the pill control the visitor can see. */
.multiselect:has([aria-invalid="true"]) .ms-control {
    border-color: var(--req);
}

/* ---------- Multi-select with removable pills (contact form services) ---------- */
.multiselect { position: relative; }
/* Native <select multiple> stays in the DOM (submit source + no-JS fallback), hidden once JS builds the pills. */
.ms-source-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    border: 0;
}
.ms-control {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4rem;
    width: 100%;
    min-height: 48px;
    padding: 0.4rem 2.25rem 0.4rem 0.55rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    color: var(--ink);
    cursor: pointer;
}
.ms-control:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 1px;
    border-color: var(--cyan);
}
.ms-placeholder { color: var(--mute); padding: 0.35rem 0.3rem; }
.ms-pills { display: contents; }
.ms-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.25rem 0.35rem 0.25rem 0.7rem;
    background: color-mix(in srgb, var(--cyan) 14%, transparent);
    border: 1px solid color-mix(in srgb, var(--cyan) 30%, transparent);
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 600;
    line-height: 1.2;
}
.ms-pill-x {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.15rem;
    height: 1.15rem;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: color-mix(in srgb, var(--cyan) 22%, transparent);
    color: var(--ink);
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
}
.ms-pill-x:hover { background: var(--cyan); color: #fff; }
.ms-pill-x svg { width: 0.7rem; height: 0.7rem; display: block; }
.ms-caret {
    position: absolute;
    right: 0.9rem;
    top: 1.4rem;
    width: 0.5rem;
    height: 0.5rem;
    border-right: 2px solid var(--mute);
    border-bottom: 2px solid var(--mute);
    transform: rotate(45deg);
    pointer-events: none;
    transition: transform 0.2s ease;
}
.ms-control[aria-expanded="true"] .ms-caret {
    transform: translateY(3px) rotate(225deg);
}
.ms-menu {
    position: absolute;
    top: calc(100% + 0.35rem);
    left: 0;
    right: 0;
    z-index: 20;
    padding: 0.35rem;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 10px;
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.12);
    max-height: 260px;
    overflow-y: auto;
}
.ms-option {
    display: block;
    width: 100%;
    padding: 0.55rem 0.7rem;
    text-align: left;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: var(--ink);
    font: inherit;
    cursor: pointer;
}
.ms-option:hover,
.ms-option:focus-visible {
    background: var(--bg-soft);
    outline: none;
}
.ms-empty { padding: 0.55rem 0.7rem; color: var(--mute); font-size: 0.9rem; }

/* Consent checkbox row (overrides the block-label default) */
.form-consent label {
    display: flex;
    gap: 0.6rem;
    align-items: flex-start;
    font-weight: 400;
    margin-bottom: 0;
    color: var(--mute);
    font-size: 0.95rem;
    cursor: pointer;
}
.form-consent input[type="checkbox"] {
    width: 1.1rem;
    height: 1.1rem;
    min-height: 0;
    margin: 0.15rem 0 0;
    padding: 0;
    border: 0;
    background: none;
    flex: none;
    accent-color: var(--cyan);
}
.form-consent input[type="checkbox"]:focus {
    outline: 2px solid var(--cyan);
    outline-offset: 2px;
}

/* ---------- Legal / policy pages ---------- */
.legal-doc { max-width: 780px; margin: 0 auto; }
.legal-doc h2 {
    font-size: 1.3rem;
    margin: 2.25rem 0 0.6rem;
}
.legal-doc h3 {
    font-size: 1.05rem;
    margin: 1.5rem 0 0.4rem;
}
.legal-doc p { color: var(--mute); }
.legal-doc ul {
    list-style: disc;
    padding-left: 1.35rem;
    margin: 0 0 1em;
    color: var(--mute);
}
.legal-doc li { margin-bottom: 0.4rem; }
.legal-doc .legal-updated {
    font-size: 0.9rem;
    color: var(--mute);
    border-bottom: 1px solid var(--line);
    padding-bottom: 1.25rem;
    margin-bottom: 1.5rem;
}
.legal-doc .legal-copyright {
    margin-top: 2.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--line);
    font-size: 0.85rem;
}

/* ---------- Blog listing ---------- */
.blog-list { background: var(--bg); }
.blog-more {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 2.5rem;
}
.post-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.75rem;
    list-style: none;
    padding: 0;
    margin: 0 0 3rem;
}
.post-card {
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    transition: transform .15s ease, box-shadow .15s ease;
}
.post-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.post-card a {
    display: block;
    color: var(--ink);
    text-decoration: none;
}
.post-card a:hover { text-decoration: none; }
.post-thumb {
    aspect-ratio: 16 / 10;
    border-radius: 0;
    border: 0;
    border-bottom: 1px solid var(--line);
}
.post-card .post-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1.25rem 1.25rem 0.5rem;
    font-size: 0.8rem;
    color: var(--mute);
}
.post-cat {
    background: var(--cyan);
    color: var(--cyan-ink);
    padding: 0.15rem 0.55rem;
    border-radius: 999px;
    font-weight: 700;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}
.post-card h2 {
    padding: 0 1.25rem;
    font-size: 1.15rem;
    line-height: 1.35;
    margin: 0.25rem 0 0.5rem;
}
.post-card p {
    padding: 0 1.25rem 1.5rem;
    color: var(--mute);
    font-size: 0.95rem;
    margin: 0;
}

/* ---------- Pagination ---------- */
.pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}
.page-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 0.85rem;
    border-radius: 8px;
    border: 1px solid var(--line);
    background: var(--bg);
    color: var(--ink);
    font-weight: 600;
}
.page-link:hover { border-color: var(--cyan); color: var(--cyan); text-decoration: none; }
.page-link.is-current {
    background: var(--cyan);
    border-color: var(--cyan);
    color: var(--cyan-ink);
}

/* ---------- Single post ---------- */
.post-hero {
    background: var(--bg);
    /* matches .page-hero: extra top padding clears the fixed floating nav pill */
    padding: 7rem 0 1.5rem;
}
.post-breadcrumb { margin: 0 0 1.5rem; font-size: 0.9rem; }
.post-breadcrumb a { color: var(--mute); }
.post-breadcrumb a:hover { color: var(--cyan); text-decoration: none; }
.post-hero .post-meta {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    color: var(--mute);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}
.post-title {
    max-width: 24ch;
    margin: 0 0 1rem;
    line-height: 1.15;
}
.post-deck { color: var(--mute); font-size: 1.15rem; max-width: 56ch; margin: 0; }

.post-feature { padding: 1.5rem 0 2.5rem; }
.img-post-feature { aspect-ratio: 3 / 2; object-position: center 20%; }

.post-article {
    background: var(--bg);
    padding: 1rem 0 4rem;
}
.post-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 3rem;
    align-items: start;
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 1.5rem;
}
.post-body { font-size: 1.05rem; line-height: 1.75; }
.post-body > * { max-width: 64ch; }
.post-body h2 { margin-top: 2rem; }
.post-body h3 { margin-top: 1.5rem; }
.post-body blockquote {
    border-left: 4px solid var(--cyan);
    padding: 0.5rem 0 0.5rem 1.5rem;
    margin: 1.5rem 0;
    color: var(--ink);
    font-size: 1.1rem;
}
.post-body blockquote p { margin: 0; }

.post-sidebar { position: sticky; top: 100px; display: grid; gap: 1rem; }
.sidebar-card {
    background: var(--bg-soft);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 1.5rem;
}
.sidebar-card h4 {
    color: var(--ink);
    text-transform: none;
    letter-spacing: 0;
    font-size: 1rem;
    margin: 0 0 0.5rem;
}
.sidebar-card p { color: var(--mute); margin: 0 0 0.85rem; font-size: 0.95rem; }
.sidebar-card ul { list-style: none; padding: 0; margin: 0; }
.sidebar-card ul li { padding: 0.25rem 0; }
.sidebar-card ul li a { color: var(--cyan); font-weight: 600; }

.post-related { background: var(--bg-soft); }
.post-related h2 { margin-bottom: 2rem; }

/* ---------- Responsive (new components) ---------- */
@media (max-width: 960px) {
    .service-detail,
    .team-card,
    .contact-grid,
    .post-layout {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    .service-detail:nth-child(even) .service-detail-media { order: 0; }
    /* Must be `img.team-photo` (0,1,1) to beat the base rule's aspect-ratio and border. */
    img.team-photo { border-right: 0; border-bottom: 1px solid var(--line); aspect-ratio: 16 / 10; }
    .team-info { padding: 0 1.5rem 1.5rem; }
    .team-grid,
    .feature-list,
    .trial-grid,
    .post-list {
        grid-template-columns: 1fr 1fr;
    }
    .post-sidebar { position: static; }
    /* Long-form article body reads shorter on mobile. */
    .post-body { font-size: 1rem; line-height: 1.6; }
    .post-deck { font-size: 1.05rem; }
}

/* ---------- Phones (<=640px) ----------
   Card sets that read at half width stay grids rather than stacks. Copy dropped
   here is only display:none, so crawlers and the no-CSS fallback still see it. */
@media (max-width: 640px) {
    .two-col { gap: 1.25rem; }

    /* All six services stay a 2-up grid of icon + label; descriptions hide (full copy on services.html). */
    .service-grid { grid-template-columns: 1fr 1fr; gap: 0.75rem; }
    .service-card { padding: 1.1rem 0.75rem; text-align: center; }
    .service-card p { display: none; }
    .service-card h3 { font-size: 0.95rem; line-height: 1.3; margin: 0; }
    .service-icon {
        width: 38px;
        height: 38px;
        border-radius: 9px;
        margin: 0 auto 0.65rem;
    }
    .service-icon svg { width: 19px; height: 19px; }

    /* Horizontal thumbnail + copy row: about a third of the stacked height, no copy lost. */
    .team-grid { grid-template-columns: 1fr; gap: 1rem; }
    .team-card { grid-template-columns: 104px 1fr; gap: 0; }
    img.team-photo {
        height: 100%;
        aspect-ratio: 1 / 1;
        border-right: 1px solid var(--line);
        border-bottom: 0;
    }
    .team-info { padding: 1rem 1.1rem; }
    .team-info h3 { font-size: 1.15rem; }
    .team-role { margin-bottom: 0.4rem; font-size: 0.9rem; }
    .team-bio { font-size: 0.9rem; }

    /* Assessment features are short enough to read 2-up once the padding drops. */
    .feature-list { grid-template-columns: 1fr 1fr; gap: 0.75rem; }
    .feature-card { padding: 1.1rem; }
    .feature-num { font-size: 0.85rem; margin-bottom: 0.4rem; }
    .feature-card h3 { font-size: 1rem; }
    .feature-card p { font-size: 0.85rem; }

    /* Only two trial cards, so these stay full width minus the desktop padding. */
    .trial-grid { grid-template-columns: 1fr; gap: 1rem; }
    .trial-card { padding: 1.5rem; gap: 0.85rem; }

    /* Blog listing: one card per row with tighter internals. */
    .post-list { grid-template-columns: 1fr; gap: 1.25rem; margin-bottom: 2rem; }
    .post-card .post-meta { padding: 1rem 1rem 0.4rem; }
    .post-card h2 { padding: 0 1rem; font-size: 1.05rem; }
    .post-card p { padding: 0 1rem 1.15rem; font-size: 0.9rem; }

    /* Home News grid: show a single article on phones (full list via "View All"). */
    .news .news-grid .news-card:nth-child(n + 2) { display: none; }

    /* 16:10 rather than 4:3 gives back roughly a quarter of the height wherever it is used. */
    .hero-media .media-img,
    .sustainable .media-img,
    .why-block .media-img,
    .service-detail .media-img { aspect-ratio: 16 / 10; }

    /* Hero and page chrome */
    .hero-cover { min-height: 420px; }
    /* Top padding stays at the 6rem set above: the pill is taller, not shorter, on phones. */
    .hero-cover .hero-content { padding-bottom: 3rem; }
    .page-hero { padding: 5.5rem 0 1.75rem; }
    .post-hero { padding: 5.5rem 0 1.25rem; }
    .post-feature { padding: 1rem 0 1.75rem; }
    .service-detail { padding: 2rem 0; }

    /* These rows decide the services page's length on a phone. */
    .sub-offerings { margin: 0.85rem 0 1.15rem; }
    .sub-offerings li { padding: 0.4rem 0 0.4rem 1.35rem; font-size: 0.95rem; }

    /* Contact form */
    .contact-form-wrap { padding: 1.25rem; }
    .form-row { margin-bottom: 1rem; }

    /* Two columns with the brand spanning the top roughly halves the tallest phone block; taller hit areas too. */
    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 1.5rem 1rem;
        padding-bottom: 2rem;
    }
    .footer-brand { grid-column: 1 / -1; }
    .footer-brand p { max-width: none; }
    .footer-col h4 { margin-bottom: 0.6rem; }
    .footer-col ul li { padding: 0.4rem 0; }
    .footer-base { justify-content: center; text-align: center; }
}

/* ---------- Small phones (<=540px) ---------- */
@media (max-width: 540px) {
    h1 { font-size: 2rem; }
    h2 { font-size: 1.6rem; }
    .header-inner { padding: 0.75rem 1rem; }
    /* Small phones: tighten section rhythm one more step to cut scroll length. */
    .section { padding: 2.25rem 0; }
    /* :not(.hero-cover) so the full-bleed home hero never gets its padding back. */
    .hero:not(.hero-cover) { padding: 2.25rem 0 2.5rem; }
}

/* ---------- Very small phones (<=420px) ---------- */
@media (max-width: 420px) {
    .container,
    .post-layout {
        padding-left: 1.15rem;
        padding-right: 1.15rem;
    }
    h1 { font-size: 1.75rem; }
    h2 { font-size: 1.4rem; }
    .hero-cover { min-height: 380px; }
    /* :not(.btn-sm) or this would land after .btn-sm in the cascade and undo it */
    .btn:not(.btn-sm) { padding: 0.75rem 1.1rem; }

    .service-card { padding: 0.9rem 0.55rem; }
    .service-card h3 { font-size: 0.88rem; }
    /* Feature cards carry a paragraph, so they give up the 2-up grid here. */
    .feature-list { grid-template-columns: 1fr; }
    .trial-card { padding: 1.25rem; }
    .team-card { grid-template-columns: 88px 1fr; }
    .team-info { padding: 0.85rem 0.9rem; }
    .quote { padding: 1.25rem 1.15rem 1.25rem 2.5rem; }
    .contact-form-wrap { padding: 1rem; }
}

/* ---------- Decorative layer ----------
   Dot-grid on .page-hero and .site-footer only. Pure CSS keyed to existing
   classes so no markup is added, paints behind content, color-mix tints only.
   Nothing animates; add a prefers-reduced-motion guard if that ever changes. */
:root {
    --deco-dot: color-mix(in srgb, var(--cyan) 38%, transparent);    /* dots on the light .page-hero */
    --deco-dot-light: color-mix(in srgb, #ffffff 14%, transparent);  /* dots on the dark --navy footer */
}

/* Clip the decoration and keep content above it */
.page-hero,
.site-footer {
    position: relative;
    overflow: hidden;
}
.page-hero > .container,
.site-footer > .container {
    position: relative;
    z-index: 1;
}

/* Dot-grid faded into the top-right whitespace */
.page-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background-image: radial-gradient(circle, var(--deco-dot) 1px, transparent 1.6px);
    background-size: 22px 22px;
    -webkit-mask-image: radial-gradient(130% 130% at 100% 0%, #000 0%, transparent 65%);
    mask-image: radial-gradient(130% 130% at 100% 0%, #000 0%, transparent 65%);
}
.site-footer::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background-image: radial-gradient(circle, var(--deco-dot-light) 1px, transparent 1.6px);
    background-size: 22px 22px;
    -webkit-mask-image: radial-gradient(130% 130% at 100% 0%, #000 0%, transparent 65%);
    mask-image: radial-gradient(130% 130% at 100% 0%, #000 0%, transparent 65%);
}

