/*
 * Chatwood Labs — core site stylesheet
 * Refactored August 2026 for the current six-page site.
 *
 * Structure:
 *  1. Design tokens + reset
 *  2. Site shell (header, navigation, footer)
 *  3. Shared controls + subpage hero
 *  4. Home
 *  5. Technology + Open Source shared product/project patterns
 *  6. Technology
 *  7. Open Source
 *  8. Research
 *  9. Services
 * 10. Contact
 * 11. News/article compatibility
 * 12. Responsive + reduced motion
 */

/* ─────────────────────────────────────────────────────────────
   1. Design tokens + reset
   ───────────────────────────────────────────────────────────── */

:root {
    --primary-light: #f8f9fa;
    --secondary-light: #e8eef4;
    --surface-soft: rgba(240, 244, 247, 0.72);
    --surface-work: rgba(232, 238, 244, 0.85);

    --accent-orange: #ff6b35;
    --accent-orange-dark: #e65a2e;
    --accent-blue: #4a9eff;
    --accent-cyan: #00d4ff;

    --text-primary: #1a1d29;
    --text-secondary: #4a5568;
    --text-muted: #6b7c93;
    --dark-bg: #1a1d29;

    --border-subtle: rgba(0, 0, 0, 0.08);
    --border-control: rgba(0, 0, 0, 0.12);

    --font-display: 'Orbitron', sans-serif;
    --font-body: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, sans-serif;

    --content-width: 900px;
    --hero-width: 1200px;
    --wide-width: 1400px;

    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;

    --section-x: 2rem;
    --section-x-mobile: 1.5rem;
}

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

html {
    scroll-behavior: smooth;
}

body {
    min-width: 320px;
    overflow-x: hidden;
    font-family: var(--font-body);
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--primary-light);
    background-image: url('/images/bg.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    background-repeat: no-repeat;
}

img,
svg,
video {
    max-width: 100%;
}

img {
    height: auto;
}

button,
input,
select,
textarea {
    font: inherit;
}

button {
    color: inherit;
}

a {
    text-underline-offset: 0.18em;
}

/* ─────────────────────────────────────────────────────────────
   2. Site shell
   Header and footer markup are supplied by header.js/footer.js
   on pages that use the shared shell.
   ───────────────────────────────────────────────────────────── */

.navbar {
    position: fixed;
    inset: 0 0 auto;
    z-index: 1000;
    background: rgba(248, 249, 250, 0.95);
    border-bottom: 1px solid var(--border-subtle);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
}

.nav-container {
    max-width: var(--wide-width);
    margin: 0 auto;
    padding: 1.5rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo-container {
    z-index: 1001;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: inherit;
    text-decoration: none;
    transition: opacity 0.25s ease;
}

.logo-link:hover {
    opacity: 0.8;
}

.logo {
    width: 50px;
    height: 50px;
}

.logo-text {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: 0.5px;
    color: var(--text-primary);
}

.logo-name {
    font-size: 1rem;
    font-weight: 700;
}

.logo-tagline {
    font-size: 0.55rem;
    font-weight: 400;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    color: var(--text-muted);
}

.nav-menu {
    display: flex;
    gap: 2.5rem;
    list-style: none;
}

.nav-menu li a {
    position: relative;
    color: var(--text-secondary);
    font-size: 0.95rem;
    font-weight: 400;
    text-decoration: none;
    transition: color 0.25s ease;
}

.nav-menu li a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -5px;
    width: 0;
    height: 2px;
    background: var(--accent-orange);
    transition: width 0.25s ease;
}

.nav-menu li a:hover {
    color: var(--text-primary);
}

.nav-menu li a:hover::after {
    width: 100%;
}

.menu-toggle {
    z-index: 1003;
    display: none;
    flex-direction: column;
    gap: 5px;
    padding: 0.5rem;
    border: 0;
    background: none;
    cursor: pointer;
}

.menu-toggle span {
    width: 25px;
    height: 2px;
    background: var(--text-primary);
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(7px, 7px);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

footer {
    padding: 1.5rem 1rem;
    background: rgba(235, 240, 244, 0.72);
    border-top: 1px solid rgba(14, 27, 45, 0.28);
}

.footer-content {
    max-width: var(--wide-width);
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    color: var(--text-muted);
    font-size: 0.7rem;
    text-align: center;
}

.footer-social {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.footer-social a {
    display: flex;
    align-items: center;
    color: var(--text-muted);
    transition: color 0.2s ease, transform 0.2s ease;
}

.footer-social a:hover {
    color: var(--accent-orange);
    transform: translateY(-2px);
}

.footer-links {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    color: var(--text-muted);
    font-size: 0.72rem;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-links a:hover {
    color: var(--accent-orange);
}

.footer-links a:focus-visible {
    outline: 3px solid rgba(255, 107, 53, 0.45);
    outline-offset: 3px;
}

.footer-link-separator {
    color: rgba(107, 124, 147, 0.65);
}

/* ─────────────────────────────────────────────────────────────
   3. Shared controls + subpage hero
   ───────────────────────────────────────────────────────────── */

.site-button {
    min-height: 52px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.9rem 2.25rem;
    border: 2px solid currentColor;
    border-radius: var(--radius-md);
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 600;
    line-height: 1;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition:
        background-color 0.25s ease,
        border-color 0.25s ease,
        color 0.25s ease,
        transform 0.25s ease,
        box-shadow 0.25s ease;
}

.site-button-light {
    color: var(--dark-bg);
    background: #fff;
}

.site-button-light:hover {
    color: #fff;
    background: var(--accent-orange);
    border-color: var(--accent-orange);
    transform: translateY(-2px);
}

.site-button-accent {
    color: #fff;
    background: var(--accent-orange);
    border-color: var(--accent-orange);
}

.site-button-accent:hover {
    color: var(--dark-bg);
    background: #fff;
    border-color: #fff;
    transform: translateY(-2px);
}

:where(
    .site-button,
    .capability-card,
    .technology-action-link,
    .open-source-project-link,
    .service-action-link,
    .research-resource-link,
    .contact-intro-copy a,
    .contact-routes-copy a,
    .nav-menu a,
    .logo-link
):focus-visible {
    outline: 3px solid rgba(255, 107, 53, 0.45);
    outline-offset: 3px;
}

.subpage-hero {
    min-height: 40vh;
    padding: 140px var(--section-x) 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    background-color: var(--primary-light);
    background-image: url('/images/space-bg.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    background-repeat: no-repeat;
}

.subpage-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(
        to right,
        rgba(248, 249, 250, 0.95) 0%,
        rgba(248, 249, 250, 0.85) 50%,
        rgba(248, 249, 250, 0.75) 100%
    );
}

.subpage-hero-content {
    z-index: 1;
    width: 100%;
    max-width: var(--hero-width);
}

.breadcrumb {
    margin-bottom: 1.5rem;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.breadcrumb a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.25s ease;
}

.breadcrumb a:hover {
    color: var(--accent-orange);
}

.breadcrumb-separator {
    margin: 0 0.5rem;
    color: var(--text-muted);
}

.breadcrumb-current {
    color: var(--text-primary);
    font-weight: 500;
}

.subpage-title {
    margin-bottom: 1rem;
    font-family: var(--font-display);
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 900;
    line-height: 1.2;
    color: var(--text-primary);
}

.subpage-subtitle {
    max-width: 720px;
    color: var(--text-secondary);
    font-size: clamp(1rem, 2vw, 1.3rem);
    font-weight: 400;
    line-height: 1.6;
}

/* ─────────────────────────────────────────────────────────────
   4. Home
   ───────────────────────────────────────────────────────────── */

.home-hero {
    min-height: clamp(360px, 46vh, 500px);
    padding: 200px 0 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    background-image: url('/images/home_wave_banner.jpg');
    background-size: cover;
    background-position: top;
    background-repeat: no-repeat;
}

.home-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(
        to right,
        rgba(248, 249, 250, 0.9) 0%,
        rgba(248, 249, 250, 0.6) 50%,
        rgba(248, 249, 250, 0.3) 100%
    );
}

.home-hero-content {
    z-index: 1;
    width: min(var(--wide-width), calc(100% - 4rem));
    animation: fade-in-up 0.8s ease-out both;
}

.home-hero-title {
    max-width: 15ch;
    margin-bottom: 2rem;
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -1px;
    color: var(--text-primary);
}

.home-hero-subtitle {
    max-width: 850px;
    color: var(--text-secondary);
    font-size: clamp(1rem, 2vw, 1.25rem);
    font-weight: 400;
    line-height: 1.8;
}

.home-capabilities {
    padding: 40px var(--section-x);
    background: var(--surface-soft);
}

.capabilities-grid {
    max-width: var(--wide-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
}

.capability-card {
    position: relative;
    overflow: hidden;
    display: block;
    padding: 2rem;
    color: inherit;
    text-align: center;
    text-decoration: none;
    background: #fff;
    border: 1px solid var(--border-subtle);
    border-left: 4px solid var(--accent-orange);
    border-radius: var(--radius-lg);
    transition:
        transform 0.3s ease,
        border-color 0.3s ease,
        box-shadow 0.3s ease;
}

.capability-card::before {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0;
    background: radial-gradient(
        circle at center,
        rgba(255, 107, 53, 0.05) 0%,
        transparent 70%
    );
    transition: opacity 0.3s ease;
}

.capability-card:hover {
    transform: translateY(-8px);
    border-color: var(--accent-orange);
    box-shadow: 0 18px 45px rgba(255, 107, 53, 0.14);
}

.capability-card:hover::before {
    opacity: 1;
}

.capability-card h3 {
    position: relative;
    z-index: 1;
    margin-bottom: 1rem;
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.4;
    color: var(--text-primary);
}

.capability-subtitle {
    position: relative;
    z-index: 1;
    margin: 0;
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
}

.capability-subtitle + .capability-subtitle {
    margin-top: 1.25rem;
}

.home-technology-overview,
.quarterly-updates,
.services-contact-cta {
    position: relative;
    background-color: var(--dark-bg);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.home-technology-overview::before,
.quarterly-updates::before,
.services-contact-cta::before {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.home-technology-overview {
    padding: 60px var(--section-x);
    background-image: url('/images/banner.jpg');
}

.home-technology-overview::before {
    background: rgba(26, 29, 41, 0.7);
}

.home-technology-content {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.home-technology-content h2 {
    margin-bottom: 2rem;
    color: #fff;
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 4vw, 3rem);
    font-weight: 700;
    line-height: 1.3;
}

.home-technology-content p {
    margin: 0;
    color: #fff;
    font-size: 1.1rem;
    line-height: 1.7;
}

.cta-buttons {
    margin-top: 1.5rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
}

.home-work-with-chatwood {
    padding: 60px var(--section-x);
    background: var(--surface-work);
}

.home-work-container {
    max-width: var(--wide-width);
    margin: 0 auto;
    padding: 0 2rem;
}

.home-work-layout {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 3rem;
}

.home-work-copy {
    flex: 0 0 66.667%;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    text-align: left;
}

.home-work-copy h2 {
    margin-bottom: 1rem;
    color: var(--text-primary);
    font-family: var(--font-display);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    line-height: 1.3;
}

.home-work-copy p {
    margin: 0;
    color: var(--text-secondary);
    font-size: clamp(1.1rem, 2vw, 1.4rem);
    line-height: 1.7;
}

.home-work-actions {
    flex: 0 0 33.333%;
    text-align: center;
}

.home-work-actions .cta-buttons {
    margin-top: 0;
}

.quarterly-updates {
    padding: 40px var(--section-x);
    background-image: url('/images/space-bg.jpg');
    text-align: center;
}

.quarterly-updates::before,
.services-contact-cta::before {
    background: rgba(26, 29, 41, 0.85);
}

.quarterly-updates-container {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
}

.quarterly-updates h2 {
    margin-bottom: 1rem;
    color: #fff;
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    font-weight: 700;
}

.quarterly-updates p {
    margin-bottom: 1rem;
    color: #e8eef4;
    font-size: 1.2rem;
    line-height: 1.6;
}

.quarterly-updates-form {
    margin-top: 1rem;
    display: grid;
    grid-template-columns: minmax(0, 380px) 150px;
    align-items: stretch;
    justify-content: center;
    gap: 1.5rem;
}

.quarterly-updates-email,
.quarterly-updates-submit {
    height: 58px;
    min-height: 58px;
}

.quarterly-updates-email {
    width: 100%;
    padding: 0 20px;
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(255, 255, 255, 0.45);
    border-radius: var(--radius-sm);
    outline: none;
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1;
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.quarterly-updates-email::placeholder {
    color: var(--text-secondary);
    opacity: 1;
    font-size: 1rem;
}

.quarterly-updates-email:hover {
    border-color: rgba(255, 255, 255, 0.8);
}

.quarterly-updates-email:focus {
    border-color: var(--accent-orange);
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.16);
}

.quarterly-updates-submit {
    width: 150px;
    padding-inline: 1.5rem;
}

.quarterly-updates-note {
    margin-top: 0.35rem;
    color: #e8eef4;
    font-size: 0.8rem !important;
    line-height: 1.6 !important;
}

/* ─────────────────────────────────────────────────────────────
   5. Technology + Open Source shared patterns
   ───────────────────────────────────────────────────────────── */

.technology-product-section,
.open-source-project-section {
    padding: 40px var(--section-x);
    background: var(--primary-light);
}

.technology-product-layout,
.open-source-project-layout {
    max-width: var(--content-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 3fr) minmax(280px, 2fr);
    align-items: center;
    gap: 3rem;
}

.technology-product-copy,
.open-source-project-copy {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

:where(.technology-product-copy, .open-source-project-copy) h2 {
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    font-family: var(--font-display);
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 700;
    line-height: 1.3;
}

:where(.technology-product-copy, .open-source-project-copy) p {
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
    font-size: 1.1rem;
    line-height: 1.8;
}

:where(.technology-product-copy, .open-source-project-copy) p:last-child {
    margin-bottom: 0;
}

.technology-product-visual,
.open-source-project-visual {
    width: 100%;
    min-width: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    gap: 0.5rem;
}

.technology-product-visual img,
.open-source-project-visual img {
    display: block;
    max-width: 100%;
    margin: 0 auto;
    padding: 10%;
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
}


.technology-product-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
    margin-top: 0.25rem;
}

.technology-action-link,
.open-source-project-link,
.service-action-link {
    display: inline-block;
    color: var(--accent-orange);
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    border-bottom: 2px solid transparent;
    transition: border-color 0.25s ease;
}

.technology-action-link:hover,
.open-source-project-link:hover,
.service-action-link:hover {
    border-bottom-color: var(--accent-orange);
}

.technology-feature-card,
.open-source-support-card,
.services-process-card {
    position: relative;
    overflow: hidden;
    display: block;
    padding: 2rem;
    color: inherit;
    text-align: center;
    background: #fff;
    border: 1px solid var(--border-subtle);
    border-left: 4px solid var(--accent-orange);
    border-radius: var(--radius-lg);
}

:where(
    .technology-feature-card,
    .open-source-support-card,
    .services-process-card
) h3 {
    margin-bottom: 1rem;
    color: var(--text-primary);
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.4;
}

.technology-feature-copy,
.open-source-support-copy,
.services-process-copy {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* ─────────────────────────────────────────────────────────────
   6. Technology
   ───────────────────────────────────────────────────────────── */

.technology-product-copy h3 {
    margin: 2rem 0 1rem;
    color: var(--text-primary);
    font-family: var(--font-display);
    font-size: clamp(1.2rem, 2.5vw, 1.5rem);
    font-weight: 600;
    line-height: 1.3;
}

.technology-feature-section {
    padding: 40px var(--section-x) 80px;
    background: var(--secondary-light);
}

.technology-feature-grid {
    max-width: var(--wide-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
}

/* ─────────────────────────────────────────────────────────────
   7. Open Source
   ───────────────────────────────────────────────────────────── */

.open-source-project-section-alt {
    padding-bottom: 80px;
    background: var(--secondary-light);
}

.open-source-project-section-reverse .open-source-project-layout {
    grid-template-columns: minmax(280px, 2fr) minmax(0, 3fr);
}

.open-source-project-copy-right {
    text-align: right;
}

.open-source-project-status {
    align-self: flex-start;
    display: inline-block;
    margin-bottom: -5px;
    font-size: 1rem;
}

.open-source-project-copy-right .open-source-project-status {
    align-self: flex-end;
}

.open-source-project-status-available {
    color: green;
}

.open-source-project-status-development {
    color: orange;
}

.open-source-support-section {
    padding: 40px var(--section-x) 80px;
    background: var(--secondary-light);
}

.open-source-support-grid {
    max-width: var(--wide-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
}

.open-source-support-copy + .open-source-support-copy {
    margin-top: 1.25rem;
}

/* ─────────────────────────────────────────────────────────────
   8. Research
   ───────────────────────────────────────────────────────────── */

.research-programme-section {
    padding: 80px var(--section-x) 4rem;
    background: var(--primary-light);
}

.research-programme-container,
.research-resources-container,
.services-offerings-container,
.contact-intro-container,
.contact-form-container,
.contact-routes-container {
    max-width: var(--content-width);
    margin: 0 auto;
}

.research-topic {
    margin-bottom: 4rem;
}

.research-methodology {
    margin-bottom: 0;
}

:where(.research-topic, .research-methodology, .service-offering) h2 {
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    font-family: var(--font-display);
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 700;
    line-height: 1.3;
}

:where(.research-topic, .research-methodology, .service-offering) p {
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
    font-size: 1.1rem;
    line-height: 1.8;
}

:where(.research-topic, .research-methodology) p:last-child {
    margin-bottom: 0;
}

.research-evidence-visual {
    margin-bottom: 4rem;
    text-align: center;
}

.research-evidence-figure {
    margin: 2.5rem 0;
}

.research-evidence-figure img {
    display: block;
    max-width: 100%;
    margin: 0 auto;
    padding: 2%;
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
}

.research-evidence-figure figcaption {
    margin-top: 0.75rem;
    color: var(--text-muted);
    font-size: 0.875rem;
    font-style: italic;
    line-height: 1.6;
    text-align: center;
}

.research-resources-section {
    padding: 0 var(--section-x) 80px;
    background: var(--primary-light);
}

.research-resources-panel {
    padding: 2rem;
    background: var(--secondary-light);
    border-left: 4px solid var(--accent-orange);
    border-radius: var(--radius-md);
}

.research-resources-panel h3 {
    margin: 0 0 1.5rem;
    color: var(--text-primary);
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 600;
}

.research-resource-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.research-resource-link {
    display: block;
    padding: 1rem;
    color: inherit;
    text-decoration: none;
    background: #fff;
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    transition:
        transform 0.25s ease,
        border-color 0.25s ease,
        box-shadow 0.25s ease;
}

.research-resource-link:hover {
    transform: translateY(-2px);
    border-color: var(--accent-orange);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.research-resource-title {
    display: block;
    margin-bottom: 0.25rem;
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 600;
}

.research-resource-description {
    display: block;
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.5;
}

/* ─────────────────────────────────────────────────────────────
   9. Services
   ───────────────────────────────────────────────────────────── */

.services-offerings-section {
    padding: 80px var(--section-x) 4rem;
    background: var(--primary-light);
}

.service-offering {
    margin-bottom: 4rem;
}

.service-offering:last-child {
    margin-bottom: 0;
}

.service-offering p:last-of-type {
    margin-bottom: 1.5rem;
}

.services-process-section {
    padding: 40px var(--section-x);
    background: var(--surface-soft);
}

.services-process-grid {
    max-width: var(--wide-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 3rem;
}

.services-contact-cta {
    padding: 80px var(--section-x);
    background-image: url('/images/space-bg.jpg');
    text-align: center;
}

.services-contact-cta-container {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
}

.services-contact-cta h2 {
    margin-bottom: 1rem;
    color: #fff;
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    font-weight: 700;
}

.services-contact-cta p {
    margin-bottom: 1.5rem;
    color: #e8eef4;
    font-size: 1.2rem;
    line-height: 1.6;
}

.services-contact-cta-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
}

/* ─────────────────────────────────────────────────────────────
   10. Contact
   ───────────────────────────────────────────────────────────── */

.contact-intro-section,
.contact-form-section {
    padding: 40px var(--section-x);
    background: var(--primary-light);
}

.contact-routes-section {
    padding: 40px var(--section-x) 80px;
    background: var(--primary-light);
}

.contact-intro-copy p,
.contact-routes-copy p {
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
    font-size: 1.1rem;
    line-height: 1.8;
}

.contact-intro-copy p:last-child,
.contact-routes-copy p:last-child {
    margin-bottom: 0;
}

.contact-intro-copy a,
.contact-routes-copy a {
    color: var(--accent-orange);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.25s ease;
}

.contact-intro-copy a:hover,
.contact-routes-copy a:hover {
    border-bottom-color: var(--accent-orange);
}

.contact-phone-link {
    color: var(--text-secondary) !important;
}

.contact-routes-copy h2 {
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    font-family: var(--font-display);
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 700;
    line-height: 1.3;
}

.contact-form-shell {
    margin: 0;
}

#flash {
    min-height: 400px;
}

#contact-form,
.contact-enquiry-form {
    max-width: var(--content-width);
    margin: 0 auto;
}

#contact-form label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 600;
}

#contact-form input[type='text'],
#contact-form input[type='email'],
#contact-form textarea,
#contact-form select {
    width: 100%;
    color: var(--text-primary);
    background-color: #fff;
    border: 1px solid var(--border-control);
    border-radius: var(--radius-sm);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

#contact-form input[type='text'],
#contact-form input[type='email'],
#contact-form textarea {
    padding: 0.875rem 1rem;
}

#contact-form select {
    padding: 0.875rem 3rem 0.875rem 1rem;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    background-image:
        linear-gradient(45deg, transparent 50%, var(--text-secondary) 50%),
        linear-gradient(135deg, var(--text-secondary) 50%, transparent 50%);
    background-position:
        calc(100% - 18px) 50%,
        calc(100% - 13px) 50%;
    background-size: 5px 5px, 5px 5px;
    background-repeat: no-repeat;
}

#contact-form :where(input[type='text'], input[type='email'], textarea, select):hover {
    border-color: rgba(255, 107, 53, 0.65);
}

#contact-form :where(input[type='text'], input[type='email'], textarea, select):focus {
    outline: none;
    border-color: var(--accent-orange);
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.1);
}

#contact-form select:invalid {
    color: var(--text-muted);
}

#contact-form select option {
    color: var(--text-primary);
    background: #fff;
}

#contact-form textarea {
    min-height: 150px;
    resize: vertical;
    line-height: 1.6;
}

#contact-form input:invalid:not(:placeholder-shown),
#contact-form textarea:invalid:not(:placeholder-shown) {
    border-color: rgba(255, 107, 53, 0.4);
}

#contact-form input:valid:not(:placeholder-shown),
#contact-form textarea:valid:not(:placeholder-shown) {
    border-color: rgba(0, 0, 0, 0.2);
}

.contact-honeypot,
#contact-form input[name='website'] {
    position: absolute;
    left: -5000px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.contact-form-row {
    margin-bottom: 1.5rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.contact-form-row > div {
    display: flex;
    flex-direction: column;
}

.contact-message-field {
    margin-top: 12px;
    margin-bottom: 20px;
}

.contact-form-actions {
    margin-top: 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}

.contact-turnstile,
.cf-turnstile {
    flex-shrink: 0;
}

.updates-turnstile {
    grid-column: 1 / -1;
    width: min(100%, 380px);
    justify-self: center;
}

.contact-newsletter-offer-form .updates-turnstile {
    justify-self: start;
}

.btn {
    display: inline-block;
    padding: 0.875rem 2rem;
    border: 0;
    border-radius: var(--radius-sm);
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition:
        background-color 0.25s ease,
        transform 0.25s ease,
        box-shadow 0.25s ease;
}

.btn.primary {
    color: #fff;
    background: var(--accent-orange);
}

.btn.primary:hover {
    background: var(--accent-orange-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 53, 0.3);
}

.btn.primary:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(255, 107, 53, 0.3);
}

.form-message {
    margin-bottom: 1.5rem;
    padding: 1rem 1.5rem;
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 0.95rem;
    line-height: 1.6;
}

.form-message.success {
    background: rgba(255, 107, 53, 0.08);
    border: 1px solid rgba(255, 107, 53, 0.2);
}

.form-message.error {
    background: rgba(0, 0, 0, 0.03);
    border: 1px solid rgba(0, 0, 0, 0.15);
}

.btn.loading {
    position: relative;
    color: transparent;
    pointer-events: none;
}

.btn.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 16px;
    height: 16px;
    margin: -8px 0 0 -8px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: button-spin 0.6s linear infinite;
}

/* ─────────────────────────────────────────────────────────────
   11. Updates + legacy article pages
   Legacy /news/<slug>/ URLs remain live, but use the current
   Updates article template and return to /updates/.
   ───────────────────────────────────────────────────────────── */


/* Updates landing page */

.updates-feature-section {
    padding: 40px var(--section-x);
    background: var(--primary-light);
}

.updates-feature-container {
    max-width: var(--content-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 3fr) minmax(280px, 2fr);
    gap: 3rem;
    align-items: center;
}

.updates-feature-copy {
    min-width: 0;
}

.updates-feature-meta,
.updates-card-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.75rem;
}

.updates-feature-category,
.updates-card-category {
    color: var(--accent-orange);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.updates-feature-date,
.updates-card-date {
    color: var(--text-muted);
    font-size: 0.8rem;
    letter-spacing: 0.04em;
}

.updates-feature-title {
    margin-bottom: 1.25rem;
    color: var(--text-primary);
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 4vw, 2.6rem);
    font-weight: 700;
    line-height: 1.25;
}

.updates-feature-summary {
    margin-bottom: 1.25rem;
    color: var(--text-secondary);
    font-size: 1.1rem;
    line-height: 1.8;
}

.updates-feature-link,
.updates-card-link {
    display: inline-block;
    color: var(--accent-orange);
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
}

.updates-feature-link {
    border-bottom: 2px solid transparent;
    transition: border-color 0.25s ease;
}

.updates-feature-link:hover {
    border-bottom-color: var(--accent-orange);
}

.updates-feature-visual {
    width: 100%;
    margin: 0;
}

.updates-feature-visual img {
    display: block;
    width: 100%;
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
}

.updates-archive-section {
    padding: 60px var(--section-x) 80px;
    background: var(--secondary-light);
}

.updates-archive-container {
    max-width: var(--wide-width);
    margin: 0 auto;
}

.updates-archive-heading {
    max-width: var(--content-width);
    margin: 0 auto 2rem;
    text-align: center;
}

.updates-archive-heading h2 {
    margin-bottom: 0.75rem;
    color: var(--text-primary);
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    font-weight: 700;
    line-height: 1.3;
}

.updates-archive-heading p {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.7;
}

.updates-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 2rem;
}

.updates-card {
    position: relative;
    overflow: hidden;
    min-width: 0;
    display: block;
    padding: 2rem;
    color: inherit;
    text-decoration: none;
    background: #fff;
    border: 1px solid var(--border-subtle);
    border-left: 4px solid var(--accent-orange);
    border-radius: var(--radius-lg);
    transition:
        transform 0.3s ease,
        border-color 0.3s ease,
        box-shadow 0.3s ease;
}

.updates-card::before {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0;
    background: radial-gradient(
        circle at center,
        rgba(255, 107, 53, 0.05) 0%,
        transparent 70%
    );
    transition: opacity 0.3s ease;
}

.updates-card:hover {
    transform: translateY(-8px);
    border-color: var(--accent-orange);
    box-shadow: 0 18px 45px rgba(255, 107, 53, 0.14);
}

.updates-card:hover::before {
    opacity: 1;
}

.updates-card > * {
    position: relative;
    z-index: 1;
}

.updates-card-title {
    margin-bottom: 1rem;
    color: var(--text-primary);
    font-family: var(--font-display);
    font-size: 1.35rem;
    font-weight: 700;
    line-height: 1.35;
    transition: color 0.25s ease;
}

.updates-card:hover .updates-card-title {
    color: var(--accent-orange);
}

.updates-card-summary {
    margin-bottom: 1.25rem;
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.7;
}

:where(
    .updates-feature-link,
    .updates-card
):focus-visible {
    outline: 3px solid rgba(255, 107, 53, 0.45);
    outline-offset: 3px;
}


.update-article-section {
    padding: 40px var(--section-x) 80px;
    background: var(--primary-light);
}

.update-article-container {
    max-width: var(--content-width);
    margin: 0 auto;
}

.update-article-content {
    margin: 0;
}

.update-article-content h2 {
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    font-family: var(--font-display);
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 700;
    line-height: 1.3;
}

.update-article-content h3 {
    margin: 2rem 0 1rem;
    color: var(--text-primary);
    font-family: var(--font-display);
    font-size: clamp(1.2rem, 2.5vw, 1.5rem);
    font-weight: 600;
    line-height: 1.3;
}

.update-article-content p,
.update-article-content li {
    color: var(--text-secondary);
    font-size: 1.1rem;
    line-height: 1.8;
}

.update-article-content p {
    margin-bottom: 1.5rem;
}

.update-article-content > p:last-of-type {
    margin-bottom: 0;
}

.update-article-content ul,
.update-article-content ol {
    margin: 1.5rem 0;
    padding-left: 2rem;
}

.update-article-content li {
    margin-bottom: 0.75rem;
}

.update-article-content > p a,
.update-article-content li a {
    color: var(--accent-orange);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.25s ease;
}

.update-article-content > p a:hover,
.update-article-content li a:hover {
    border-bottom-color: var(--accent-orange);
}

.update-article-meta {
    margin-bottom: 2rem;
    padding-bottom: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    border-bottom: 1px solid var(--border-subtle);
}

.update-article-back-top {
    flex-shrink: 0;
    color: var(--text-muted);
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    text-decoration: none;
    white-space: nowrap;
    transition: color 0.25s ease;
}

.update-article-back-top:hover {
    color: var(--accent-orange);
}

.update-article-meta-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.2rem;
}

.update-article-tag {
    color: var(--accent-orange);
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-align: right;
    text-transform: uppercase;
}

.update-article-date {
    color: var(--text-muted);
    font-size: 0.8rem;
    font-weight: 400;
    letter-spacing: 0.06em;
    text-align: right;
    text-transform: uppercase;
    white-space: nowrap;
}

.update-article-callout {
    margin: 2.5rem 0;
    padding: 1.25rem 1.75rem;
    background: rgba(255, 107, 53, 0.04);
    border-left: 4px solid var(--accent-orange);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.update-article-callout p {
    margin: 0 !important;
    color: var(--text-primary) !important;
    font-size: 1.05rem !important;
    font-style: italic;
    font-weight: 500 !important;
    line-height: 1.65 !important;
}

.update-article-figure,
.update-article-video {
    margin: 2.5rem 0;
}

.update-article-figure img {
    display: block;
    max-width: 100%;
    margin: 0 auto;
    padding: 2%;
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
}

.update-article-figure figcaption,
.update-article-video figcaption {
    margin-top: 0.75rem;
    color: var(--text-muted);
    font-size: 0.875rem;
    font-style: italic;
    line-height: 1.6;
    text-align: center;
}

.update-article-video-wrap {
    position: relative;
    width: 100%;
    padding-top: 56.25%;
    overflow: hidden;
    background: var(--secondary-light);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
}

.update-article-video-wrap iframe,
.update-article-video-wrap video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
    border: 0;
}

.update-article-resources {
    margin: 3rem 0 0;
    padding: 2rem;
    background: var(--secondary-light);
    border-left: 4px solid var(--accent-orange);
    border-radius: var(--radius-md);
}

.update-article-resources h3 {
    margin: 0 0 1.5rem;
    color: var(--text-primary);
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 600;
}

.update-resource-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.update-resource-link {
    display: block;
    padding: 1rem;
    color: inherit;
    text-decoration: none;
    background: #fff;
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    transition:
        transform 0.25s ease,
        border-color 0.25s ease,
        box-shadow 0.25s ease;
}

.update-resource-link:hover {
    transform: translateY(-2px);
    border-color: var(--accent-orange);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.update-resource-title {
    display: block;
    margin-bottom: 0.25rem;
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 600;
}

.update-resource-description {
    display: block;
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.5;
}

.update-article-back {
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-subtle);
}

.update-article-back a {
    color: var(--text-muted);
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-decoration: none;
    text-transform: uppercase;
    transition: color 0.25s ease;
}

.update-article-back a:hover {
    color: var(--accent-orange);
}

.update-article-back a::before {
    content: '← ';
}

/* ─────────────────────────────────────────────────────────────
   12. Responsive + reduced motion
   ───────────────────────────────────────────────────────────── */

@media (max-width: 968px) {
    .navbar {
        --mobile-header-height: 98px;
    }

    .nav-menu {
        position: fixed;
        top: var(--mobile-header-height);
        right: -100%;
        width: 280px;
        height: calc(100vh - var(--mobile-header-height));
        padding: 2rem;
        flex-direction: column;
        gap: 2rem;
        background: rgba(248, 249, 250, 0.98);
        border-left: 1px solid rgba(0, 0, 0, 0.1);
        -webkit-backdrop-filter: blur(20px);
        backdrop-filter: blur(20px);
        transition: right 0.35s ease;
        overflow-y: auto;
        overscroll-behavior: contain;
    }

    .nav-menu.active {
        right: 0;
    }

    .menu-toggle {
        display: flex;
    }

    .services-process-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 2rem;
    }
}

@media (max-width: 768px) {
    body {
        background-attachment: scroll;
    }

    .subpage-hero {
        min-height: 35vh;
        padding: 120px var(--section-x-mobile) 40px;
        background-attachment: scroll;
    }

    .home-hero {
        min-height: 70vh;
        padding-top: 140px;
        justify-content: flex-start;
    }

    .home-hero-content {
        width: calc(100% - 3rem);
    }

    .home-work-with-chatwood {
        padding: 40px var(--section-x-mobile);
        background: var(--surface-soft);
    }

    .home-work-container {
        padding: 0;
    }

    .home-work-layout {
        flex-direction: column;
        gap: 2rem;
    }

    .home-work-copy,
    .home-work-actions {
        flex: none;
        width: 100%;
    }

    .capabilities-grid,
    .technology-feature-grid,
    .open-source-support-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .technology-product-section,
    .open-source-project-section {
        padding: 20px var(--section-x-mobile);
    }

    .technology-product-layout,
    .open-source-project-layout {
        max-width: 100%;
        display: flex;
        flex-direction: column;
        align-items: stretch;
        gap: 2rem;
    }

    .technology-product-copy,
    .open-source-project-copy {
        order: 1;
        width: 100%;
    }

    .technology-product-visual,
    .open-source-project-visual {
        order: 2;
        width: 100%;
    }

    .open-source-project-copy-right {
        text-align: left;
    }

    .open-source-project-copy-right .open-source-project-status {
        align-self: flex-start;
    }

    .technology-feature-section,
    .open-source-support-section {
        padding: 20px var(--section-x-mobile) 60px;
    }

    .open-source-project-section-alt {
        padding-bottom: 60px;
    }

    :where(.technology-product-copy, .open-source-project-copy) h2,
    :where(.research-topic, .research-methodology, .service-offering) h2 {
        font-size: 1.5rem;
    }

    :where(.technology-product-copy, .open-source-project-copy) p,
    :where(.research-topic, .research-methodology, .service-offering) p,
    .contact-intro-copy p,
    .contact-routes-copy p {
        font-size: 1rem;
    }

    .research-programme-section {
        padding: 20px var(--section-x-mobile) 3rem;
    }

    .research-programme-container,
    .research-resources-container,
    .services-offerings-container,
    .contact-intro-container,
    .contact-form-container,
    .contact-routes-container {
        max-width: 100%;
    }

    .research-topic {
        margin-bottom: 3rem;
    }

    .research-evidence-visual {
        margin-bottom: 3rem;
    }

    .research-resources-section {
        padding: 0 var(--section-x-mobile) 60px;
    }

    .research-resources-panel {
        padding: 1.5rem;
    }

    .services-offerings-section {
        padding: 20px var(--section-x-mobile) 3rem;
    }

    .service-offering {
        margin-bottom: 3rem;
    }

    .services-process-section {
        padding: 20px var(--section-x-mobile) 60px;
    }

    .services-process-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .services-contact-cta {
        padding: 60px var(--section-x-mobile);
    }

    .services-contact-cta-actions {
        flex-direction: column;
        align-items: center;
    }

    .contact-intro-section,
    .contact-form-section {
        padding: 20px var(--section-x-mobile);
    }

    .contact-routes-section {
        padding: 20px var(--section-x-mobile) 60px;
    }

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

    .contact-form-actions {
        flex-direction: column-reverse;
        align-items: stretch;
    }

    .contact-submit-button {
        width: 100%;
    }

    .contact-turnstile {
        align-self: center;
    }

    .updates-feature-section {
        padding: 20px var(--section-x-mobile) 40px;
    }

    .updates-feature-container {
        max-width: 100%;
        display: flex;
        flex-direction: column;
        align-items: stretch;
        gap: 2rem;
    }

    .updates-feature-copy {
        order: 1;
        width: 100%;
    }

    .updates-feature-visual {
        order: 2;
        width: 100%;
    }

    .updates-archive-section {
        padding: 40px var(--section-x-mobile) 60px;
    }

    .updates-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .update-article-section {
        padding: 20px var(--section-x-mobile) 60px;
    }

    .update-article-container {
        max-width: 100%;
    }

    .update-article-content p,
    .update-article-content li {
        font-size: 1rem;
    }

    .update-article-meta {
        align-items: flex-start;
    }

    .update-article-resources {
        padding: 1.5rem;
    }
}

@media (max-width: 640px) {
    .navbar {
        --mobile-header-height: 72px;
    }

    .nav-container {
        padding: 1rem 1.5rem;
    }

    .logo {
        width: 40px;
        height: 40px;
    }

    .logo-text {
        font-size: 0.9rem;
    }

    .home-hero {
        padding: 100px var(--section-x-mobile) 0;
    }

    .home-hero-content {
        width: 100%;
    }

    .home-capabilities,
    .home-technology-overview,
    .quarterly-updates {
        padding-left: var(--section-x-mobile);
        padding-right: var(--section-x-mobile);
    }

    .capability-card {
        padding: 2rem 1.5rem;
    }

    .quarterly-updates-form {
        width: min(100%, 320px);
        margin-left: auto;
        margin-right: auto;
        grid-template-columns: minmax(0, 1fr);
        gap: 1.25rem;
    }

    .quarterly-updates-email,
    #contact-form input[type='text'],
    #contact-form input[type='email'],
    #contact-form textarea,
    #contact-form select {
        font-size: 16px;
    }

    .quarterly-updates-email::placeholder {
        font-size: 16px;
    }

    .quarterly-updates-submit {
        width: 150px;
        justify-self: center;
    }

    .subpage-title {
        font-size: 2rem;
    }

    .subpage-subtitle {
        font-size: 1rem;
    }

    .breadcrumb {
        font-size: 0.85rem;
    }

    .updates-feature-meta,
    .updates-card-meta {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.25rem;
    }

    .updates-card {
        padding: 1.5rem;
    }

    .update-article-meta {
        flex-direction: column;
        gap: 0.75rem;
    }

    .update-article-meta-right {
        align-items: flex-start;
    }

    .update-article-tag,
    .update-article-date {
        text-align: left;
    }

    #contact-form label {
        font-size: 0.9rem;
    }

    .btn {
        padding: 0.75rem 1.5rem;
        font-size: 0.95rem;
    }
}

/* ─────────────────────────────────────────────────────────────
   Stoker product page
   ───────────────────────────────────────────────────────────── */

.stoker-hero .subpage-subtitle {
    max-width: 880px;
}

.stoker-status {
    display: inline-block;
    margin-bottom: 1rem;
    color: var(--accent-orange);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.stoker-overview-section,
.stoker-evidence-section,
.stoker-visual-section,
.stoker-scope-section {
    padding: 60px var(--section-x);
    background: var(--primary-light);
}

.stoker-capabilities-section,
.stoker-physics-section {
    padding: 60px var(--section-x);
    background: var(--secondary-light);
}

.stoker-overview-container,
.stoker-evidence-container,
.stoker-visual-container,
.stoker-scope-container,
.stoker-section-container {
    max-width: var(--wide-width);
    margin: 0 auto;
}

.stoker-overview-container {
    display: grid;
    grid-template-columns: minmax(0, 3fr) minmax(260px, 2fr);
    gap: 4rem;
    align-items: center;
}

.stoker-overview-copy {
    max-width: 780px;
}

.stoker-kicker {
    margin-bottom: 0.7rem !important;
    color: var(--accent-orange) !important;
    font-size: 0.76rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.1em;
    line-height: 1.4 !important;
    text-transform: uppercase;
}

.stoker-overview-copy h2,
.stoker-section-heading h2,
.stoker-evidence-copy h2,
.stoker-visual-copy h2,
.stoker-scope-container h2,
.stoker-release-container h2 {
    margin-bottom: 1.25rem;
    color: var(--text-primary);
    font-family: var(--font-display);
    font-size: clamp(1.7rem, 3.5vw, 2.5rem);
    font-weight: 700;
    line-height: 1.3;
}

.stoker-overview-copy p,
.stoker-section-heading p,
.stoker-evidence-copy p,
.stoker-visual-copy p,
.stoker-scope-copy p,
.stoker-release-container > p {
    margin-bottom: 1.25rem;
    color: var(--text-secondary);
    font-size: 1.05rem;
    line-height: 1.8;
}

.stoker-overview-copy p:last-of-type,
.stoker-evidence-copy p:last-child,
.stoker-visual-copy p:last-child,
.stoker-scope-copy p:last-child {
    margin-bottom: 0;
}

.stoker-overview-actions {
    margin-top: 2rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1.5rem;
}

.stoker-secondary-link {
    color: var(--accent-orange);
    font-weight: 600;
    text-decoration: none;
    border-bottom: 2px solid transparent;
    transition: border-color 0.25s ease;
}

.stoker-secondary-link:hover {
    border-bottom-color: var(--accent-orange);
}

.stoker-logo-panel {
    margin: 0;
    padding: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
}

.stoker-logo-panel img {
    width: min(100%, 320px);
    display: block;
}

.stoker-section-heading {
    max-width: 820px;
    margin: 0 auto 2.5rem;
    text-align: center;
}

.stoker-section-heading-left {
    margin-left: 0;
    text-align: left;
}

.stoker-capability-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 2rem;
}

.stoker-capability-card {
    padding: 2rem;
    background: #fff;
    border: 1px solid var(--border-subtle);
    border-left: 4px solid var(--accent-orange);
    border-radius: var(--radius-lg);
}

.stoker-capability-card h3 {
    margin-bottom: 1rem;
    color: var(--text-primary);
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.4;
}

.stoker-capability-card p {
    margin: 0;
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.7;
}

.stoker-evidence-container,
.stoker-visual-container {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 1fr);
    gap: 4rem;
    align-items: center;
}

.stoker-screenshot {
    margin: 0;
}

.stoker-screenshot img {
    width: 100%;
    display: block;
    padding: 1.5rem;
    background: #fff;
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
}

.stoker-screenshot figcaption {
    margin-top: 0.75rem;
    color: var(--text-muted);
    font-size: 0.85rem;
    font-style: italic;
    line-height: 1.6;
    text-align: center;
}

.stoker-model-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.25rem 2rem;
}

.stoker-model-item {
    padding: 1.25rem 0;
    display: grid;
    grid-template-columns: minmax(130px, 0.6fr) minmax(0, 1.4fr);
    gap: 1.5rem;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.stoker-model-item strong {
    color: var(--text-primary);
    font-family: var(--font-display);
    font-size: 0.95rem;
}

.stoker-model-item span {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.65;
}

.stoker-scope-section {
    padding-top: 40px;
    padding-bottom: 80px;
}

.stoker-scope-container {
    display: grid;
    grid-template-columns: minmax(220px, 0.8fr) minmax(0, 1.2fr);
    gap: 4rem;
    align-items: start;
}

.stoker-release-section {
    padding: 70px var(--section-x);
    position: relative;
    background-color: var(--dark-bg);
    background-image: url('/images/space-bg.jpg');
    background-size: cover;
    background-position: center;
    text-align: center;
}

.stoker-release-section::before {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: rgba(26, 29, 41, 0.86);
}

.stoker-release-container {
    position: relative;
    z-index: 1;
    max-width: 820px;
    margin: 0 auto;
}

.stoker-release-container h2 {
    color: #fff;
}

.stoker-release-container > p {
    color: #e8eef4;
}

.stoker-release-actions {
    margin-top: 2rem;
    display: flex;
    justify-content: center;
}

:where(
    .stoker-secondary-link,
    .stoker-overview-actions .site-button,
    .stoker-release-actions .site-button
):focus-visible {
    outline: 3px solid rgba(255, 107, 53, 0.45);
    outline-offset: 3px;
}

@media (max-width: 968px) {
    .stoker-capability-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 768px) {
    .stoker-overview-section,
    .stoker-capabilities-section,
    .stoker-evidence-section,
    .stoker-physics-section,
    .stoker-visual-section,
    .stoker-scope-section {
        padding: 40px var(--section-x-mobile);
    }

    .stoker-overview-container,
    .stoker-evidence-container,
    .stoker-visual-container,
    .stoker-scope-container {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        gap: 2rem;
    }

    .stoker-logo-panel {
        padding: 2rem;
    }

    .stoker-capability-grid,
    .stoker-model-grid {
        grid-template-columns: 1fr;
    }

    .stoker-model-item {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }

    .stoker-section-heading {
        text-align: left;
    }

    .stoker-release-section {
        padding: 60px var(--section-x-mobile);
    }
}

@media (max-width: 640px) {
    .stoker-overview-actions {
        align-items: flex-start;
        flex-direction: column;
    }

    .stoker-overview-actions .site-button,
    .stoker-release-actions .site-button {
        width: min(100%, 290px);
    }

    .stoker-capability-card {
        padding: 1.5rem;
    }

    .stoker-screenshot img {
        padding: 1rem;
    }
}

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

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

@keyframes fade-in-up {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes button-spin {
    to {
        transform: rotate(360deg);
    }
}

/* ─────────────────────────────────────────────────────────────
   13. Form interaction states
   Shared by the homepage Quarterly Updates form and the
   post-contact subscription offer.
   ───────────────────────────────────────────────────────────── */

.updates-honeypot {
    position: absolute;
    left: -5000px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.quarterly-updates-note.is-success {
    color: #ffffff;
    font-weight: 600;
}

.quarterly-updates-note.is-error {
    color: #ffd4c4;
    font-weight: 500;
}

.quarterly-updates-submit.loading {
    position: relative;
    color: transparent;
    pointer-events: none;
}

.quarterly-updates-submit.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 16px;
    height: 16px;
    margin: -8px 0 0 -8px;
    border: 2px solid rgba(26, 29, 41, 0.25);
    border-top-color: var(--dark-bg);
    border-radius: 50%;
    animation: button-spin 0.6s linear infinite;
}

.quarterly-updates-submit:disabled,
.contact-newsletter-offer-form button:disabled {
    cursor: default;
    opacity: 0.8;
}

.contact-success {
    max-width: var(--content-width);
    margin: 0 auto;
}

.contact-newsletter-offer {
    margin-top: 2rem;
    padding: 2rem;
    background: var(--secondary-light);
    border-left: 4px solid var(--accent-orange);
    border-radius: var(--radius-md);
}

.contact-newsletter-offer h2 {
    margin-bottom: 0.75rem;
    color: var(--text-primary);
    font-family: var(--font-display);
    font-size: clamp(1.4rem, 3vw, 1.8rem);
    font-weight: 700;
    line-height: 1.3;
}

.contact-newsletter-offer > p {
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.7;
}

.contact-newsletter-offer-form {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 1rem;
    align-items: center;
}

.contact-newsletter-offer-email {
    width: 100%;
    min-height: 48px;
    padding: 0.75rem 1rem;
    color: var(--text-primary);
    background: #fff;
    border: 1px solid var(--border-control);
    border-radius: var(--radius-sm);
    outline: none;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.contact-newsletter-offer-email:hover {
    border-color: rgba(255, 107, 53, 0.65);
}

.contact-newsletter-offer-email:focus {
    border-color: var(--accent-orange);
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.1);
}

.contact-newsletter-offer-note {
    grid-column: 1 / -1;
    margin: 0;
    color: var(--text-muted);
    font-size: 0.85rem;
    line-height: 1.6;
}

.contact-newsletter-offer-note.is-success {
    color: var(--text-primary);
    font-weight: 600;
}

.contact-newsletter-offer-note.is-error {
    color: #a83f22;
    font-weight: 500;
}

@media (max-width: 640px) {
    .contact-newsletter-offer {
        padding: 1.5rem;
    }

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

    .contact-newsletter-offer-form .btn {
        width: 100%;
    }

    .contact-newsletter-offer-email {
        font-size: 16px;
    }
}

/* ─────────────────────────────────────────────────────────────
   14. Error pages
   ───────────────────────────────────────────────────────────── */

.error-page {
    min-height: 100vh;
}

.error-page-main {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.error-page-section {
    flex: 1;
    min-height: 620px;
    padding: 180px 2rem 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    background:
        linear-gradient(
            to right,
            rgba(248, 249, 250, 0.96) 0%,
            rgba(248, 249, 250, 0.90) 55%,
            rgba(248, 249, 250, 0.82) 100%
        ),
        url('/images/space-bg.jpg') center / cover no-repeat;
}

.error-page-container {
    width: min(100%, 900px);
    margin: 0 auto;
    text-align: center;
}

.error-page-code {
    margin: 0 0 0.5rem;
    font-family: var(--font-display);
    font-size: clamp(5rem, 16vw, 10rem);
    font-weight: 900;
    line-height: 0.95;
    letter-spacing: -0.04em;
    color: var(--accent-orange);
}

.error-page-title {
    margin: 0 0 1.25rem;
    font-family: var(--font-display);
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 900;
    line-height: 1.15;
    color: var(--text-primary);
}

.error-page-message {
    max-width: 620px;
    margin: 0 auto;
    font-size: clamp(1rem, 2vw, 1.2rem);
    line-height: 1.8;
    color: var(--text-secondary);
}

.error-page-actions {
    margin-top: 2rem;
    display: flex;
    justify-content: center;
}

.error-page-actions .site-button {
    margin: 0;
}

@media (max-width: 640px) {
    .error-page-section {
        min-height: 560px;
        padding: 130px 1.5rem 70px;
    }

    .error-page-actions {
        width: 100%;
    }

    .error-page-actions .site-button {
        width: min(100%, 260px);
    }
}



/* Privacy links at data-collection points */

.quarterly-updates-note a,
.contact-newsletter-offer-note a {
    color: inherit;
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 0.18em;
}

.quarterly-updates-note a:hover,
.contact-newsletter-offer-note a:hover {
    color: var(--accent-orange);
}
