/* Max Dragon (Thailand) Research & Development  */


/* =================================================================
   MVP ESSENTIALS: Layout, Sizing, Typography, Color Templates,
   Breakpoints, Grids, Components & HTML Structural Helpers
   ================================================================ */

/* Animations inside a section scrolled out of view are paused
   (class set by jscript/pause-offscreen.js) */
.is-offscreen,
.is-offscreen *,
.is-offscreen *::before,
.is-offscreen *::after {
  animation-play-state: paused !important;
}

:root {
  /* --- 1. TYPOGRAPHY & SCALING --- */
  /* System font stack: each device's built-in UI font, nothing to download
     (Segoe UI on Windows, San Francisco on Apple, Roboto on Android/ChromeOS) */
  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  
  --text-xs: 0.75rem;   /* 12px */
  --text-sm: 0.875rem;  /* 14px */
  --text-base: 1rem;    /* 16px */
  --text-lg: 1.125rem;  /* 18px */
  --text-xl: 1.25rem;   /* 20px */
  --text-2xl: 1.5rem;   /* 24px */
  --text-3xl: 2rem;     /* 32px */
  --text-4xl: 2.75rem;  /* 44px */
  --text-5xl: 3.5rem;   /* 56px */

  --leading-tight: 1.2;
  --leading-normal: 1.5;
  --leading-relaxed: 1.75;

  /* --- 2. SPACING SCALE --- */
  --space-1: 0.25rem;   /* 4px */
  --space-2: 0.5rem;    /* 8px */
  --space-3: 0.75rem;   /* 12px */
  --space-4: 1rem;      /* 16px */
  --space-6: 1.5rem;    /* 24px */
  --space-8: 2rem;      /* 32px */
  --space-12: 3rem;     /* 48px */
  --space-16: 4rem;     /* 64px */
  --space-24: 6rem;     /* 96px */

  /* --- 3. LAYOUT & SIZING SKELETON --- */
  --container-max: 1200px;
  --container-padding: 1.5rem;
  --section-spacing-y: clamp(4rem, 8vw, 7rem);
  --gap-sm: 1rem;
  --gap-md: 2rem;
  --gap-lg: 3rem;

  /* --- 4. COLOR TOKENS --- */
  --bg-canvas: #f6f7f9;
  --bg-surface: #ffffff;
  --bg-subtle: #eef2f7;
  --bg-dark: #18181b;
  --bg-dark-surface: #27272a;
  --text-main: #0f172a;
  --text-muted: #475569;
  --text-on-dark: #f8fafc;
  --text-on-dark-muted: #cbd5e1;
  --border-color: #e2e8f0;
  --border-dark: rgba(255, 255, 255, 0.12);
  --accent-primary: #ff0000;
  --accent-primary-strong: #e60000;
  --accent-hover: #cc0000;
  /* Secondary: dark navy — grounds the bright red and matches the slate palette */
  --accent-secondary: #0b1f3a;
  --accent-secondary-hover: #16345c;
}

/* =================================================================
   MODERN CSS RESET
   ================================================================ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 100%;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  background-color: var(--bg-canvas, #ffffff);
  color: var(--text-main, #111111);
}

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

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

a {
  color: inherit;
  text-decoration: none;
}

/* =================================================================
   TYPOGRAPHY: HEADINGS & PARAGRAPHS
   ================================================================ */

h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: var(--leading-tight);
  color: var(--text-main, inherit);
}

h1 {
  font-size: var(--text-4xl);
  letter-spacing: -0.02em;
  margin-bottom: var(--space-4);
}

h2 {
  font-size: var(--text-3xl);
  letter-spacing: -0.01em;
  margin-bottom: var(--space-3);
}

h3 {
  font-size: var(--text-2xl);
  margin-bottom: var(--space-3);
}

h4 {
  font-size: var(--text-xl);
  margin-bottom: var(--space-2);
}

h5 {
  font-size: var(--text-lg);
  margin-bottom: var(--space-2);
}

h6 {
  font-size: var(--text-base);
  margin-bottom: var(--space-2);
}

p {
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  color: var(--text-muted, #555555);
  margin-bottom: var(--space-4);
}

p:last-child,
h1:last-child,
h2:last-child,
h3:last-child,
h4:last-child,
h5:last-child,
h6:last-child {
  margin-bottom: 0;
}

/* =================================================================
   LAYOUT WRAPPERS & SECTIONS
   ================================================================ */

.wrap,
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--container-padding);
  padding-right: var(--container-padding);
}

.section {
  padding-top: var(--section-spacing-y);
  padding-bottom: var(--section-spacing-y);
  width: 100%;
}

/* =================================================================
   LAYOUT GRIDS & COMPONENTS
   ================================================================ */

.grid-2 {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--gap-md);
  align-items: center;
}

.grid-3 {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--gap-md);
}

.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--gap-md);
}

.card {
  display: flex;
  flex-direction: column;
  padding: var(--space-6);
  border: 1px solid var(--border-color, #e5e5e5);
  background-color: var(--bg-surface, #ffffff);
  height: 100%;
}

/* =================================================================
   HTML STRUCTURAL HELPERS (Navigation, Header, Buttons, Actions)
   ================================================================ */

.site-header {
  width: 100%;
  padding-top: var(--space-4);
  padding-bottom: var(--space-4);
  border-bottom: 1px solid var(--border-color, #e5e5e5);
  background-color: var(--bg-surface, #ffffff);
}

.flex-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  margin-top: var(--space-6);
}

/* Home hero CTAs: larger and squarer than the default buttons */
.home .hero-actions .btn-primary,
.home .hero-actions .btn-secondary {
  padding: 0.95rem 1.75rem;
  font-size: var(--text-base);
  border-radius: 4px;
}

/* Button Skeletons */
.btn-primary,
.btn-secondary,
.btn-nav {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-size: var(--text-sm);
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  border-radius: 8px;
  transition: background-color 0.2s ease, color 0.2s ease,
    border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.btn-primary {
  background-color: var(--accent-primary-strong, #e60000);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(255, 0, 0, 0.25);
}

.btn-primary:hover {
  background-color: var(--accent-hover, #cc0000);
  box-shadow: 0 6px 18px rgba(255, 0, 0, 0.3);
  transform: translateY(-2px);
}

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

.btn-secondary {
  background-color: transparent;
  border-color: var(--accent-secondary, #0b1f3a);
  color: var(--accent-secondary, #0b1f3a);
}

.btn-secondary:hover {
  background-color: var(--accent-secondary-hover, #16345c);
  border-color: var(--accent-secondary-hover, #16345c);
  color: #ffffff;
  box-shadow: 0 6px 18px rgba(11, 31, 58, 0.2);
  transform: translateY(-2px);
}

.btn-secondary:active {
  background-color: var(--accent-secondary, #0b1f3a);
  border-color: var(--accent-secondary, #0b1f3a);
  box-shadow: 0 2px 8px rgba(11, 31, 58, 0.2);
  transform: translateY(0);
}

.btn-nav {
  background-color: transparent;
  border-color: var(--border-color, #cccccc);
  color: var(--text-main, #111111);
}

.btn-nav:hover {
  background-color: #f8fafc;
  border-color: #cbd5e1;
  color: var(--accent-secondary, #0b1f3a);
  transform: translateY(-1px);
}

.btn-primary:focus-visible,
.btn-secondary:focus-visible,
.btn-nav:focus-visible {
  outline: 2px solid var(--accent-secondary, #0b1f3a);
  outline-offset: 3px;
}

/* Navbar Styling */
/* The navbar is injected by jscript/navbar.js after the page loads. The
   placeholder reserves the bar's exact height up front so the page doesn't
   jump down when it appears. Keep --nav-height in step with the navbar's
   padding and tallest item (the Contact button). */
.site-header {
  --nav-height: 5.0625rem; /* 81px: 16px padding x2 + 48.4px Contact button */
}

#navbar-placeholder {
  min-height: var(--nav-height);
}

.navbar {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: var(--space-4);
  min-height: var(--nav-height);
  padding: 1rem 2rem;
  color: var(--text-main, #0f172a);
}

.logo {
  grid-column: 1;
  grid-row: 1;
  justify-self: start;
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  line-height: 0;
  transition: opacity 0.2s ease;
}

.logo:hover {
  opacity: 0.8;
}

.logo:focus-visible {
  outline: 2px solid var(--accent-secondary, #0b1f3a);
  outline-offset: 4px;
}

.logo img {
  display: block;
  height: 40px;
  width: auto;
}

.nav-links {
  grid-column: 2;
  grid-row: 1;
  justify-self: center;
  display: flex;
  align-items: center;
  list-style: none;
  gap: 1.5rem;
  margin: 0;
  padding: 0;
}

.nav-links a {
  position: relative;
  display: inline-block;
  padding: 0.4rem 0.6rem;
  border-radius: 6px;
  color: var(--text-muted, #475569);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s ease, background-color 0.2s ease;
}

.nav-links a:hover {
  color: var(--accent-secondary, #0b1f3a);
  background-color: #f1f5f9;
}

.nav-links a.active {
  color: var(--accent-primary-strong, #e60000);
  font-weight: 600;
}

.nav-links a.active::after {
  content: "";
  position: absolute;
  left: 0.6rem;
  right: 0.6rem;
  bottom: 0;
  height: 2px;
  border-radius: 999px;
  background-color: var(--accent-primary, #ff0000);
}

/* Contact CTA: sits apart from the link list, in the right-hand column */
.nav-cta {
  grid-column: 3;
  grid-row: 1;
  justify-self: end;
  padding: 0.95rem 1.75rem;
  font-size: var(--text-base);
  border-radius: 4px;
  white-space: nowrap;
}

/* On the contact page itself, keep the button but drop the lift */
.nav-cta.active {
  box-shadow: none;
}

/* Hamburger toggle: hidden on desktop, shown in the mobile media query */
.nav-toggle {
  grid-column: 3;
  grid-row: 1;
  justify-self: end;
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 0;
  background: transparent;
  border: 1px solid var(--border-color, #e5e5e5);
  border-radius: 6px;
  cursor: pointer;
}

.nav-toggle-bar {
  display: block;
  width: 20px;
  height: 2px;
  margin: 0 auto;
  background-color: var(--text-main, #0f172a);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Footer Styling */
/* Site footer: brand block + four link columns, then a bottom bar */
.site-footer {
  position: relative;
  margin-top: 3rem;
  padding: var(--space-16) 0 var(--space-8);
  background-color: var(--bg-dark, #18181b);
  color: var(--text-on-dark-muted, #cbd5e1);
  border-top: 1px solid var(--border-dark, rgba(255, 255, 255, 0.12));
}

/* Thin red accent line fading out from the left along the top edge */
.site-footer::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 0;
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, rgba(230, 0, 0, 0.7), transparent 60%);
}

.footer-inner {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-padding);
}

.footer-top {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-12);
  padding-bottom: var(--space-12);
}

.footer-brand {
  max-width: 22rem;
}

.footer-logo {
  display: inline-block;
  margin-bottom: var(--space-6);
}

.footer-logo img {
  height: 40px;
  width: auto;
}

.footer-brand p {
  margin-bottom: var(--space-6);
  font-size: var(--text-sm);
  line-height: var(--leading-relaxed);
  color: #a1a1aa;
}

.footer-cta {
  padding: 0.75rem 1.25rem;
}

.footer-nav {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-8) var(--space-6);
}

.footer-col h2 {
  margin-bottom: var(--space-4);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-on-dark, #f8fafc);
}

.footer-col ul {
  display: grid;
  gap: var(--space-3);
  list-style: none;
}

.footer-col a,
.footer-legal a {
  font-size: var(--text-sm);
  color: #a1a1aa;
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-col a:hover,
.footer-legal a:hover {
  color: #ffffff;
}

.site-footer a:focus-visible {
  outline: 2px solid var(--accent-primary-strong);
  outline-offset: 3px;
  border-radius: 4px;
}

.footer-bottom {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  padding-top: var(--space-8);
  border-top: 1px solid var(--border-dark, rgba(255, 255, 255, 0.12));
}

.footer-bottom p {
  margin: 0;
  font-size: var(--text-sm);
  color: #71717a;
}

.footer-legal {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-6);
  list-style: none;
}

@media (min-width: 48rem) {
  .footer-nav {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .footer-bottom {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

@media (min-width: 64rem) {
  .footer-top {
    grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
    gap: var(--space-16);
  }
}

/* Page Layout Styling */
.page-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 3rem 1.5rem;
  min-height: 60vh; /* Keeps footer pushed down on short content pages */
}

.about-hero {
  text-align: center;
  margin-bottom: 2.5rem;
}

.about-hero h1 {
  font-size: 2.5rem;
  color: #0f172a;
  margin-bottom: 0.5rem;
}

.subtitle {
  font-size: 1.15rem;
  color: #64748b;
}

.about-content {
  display: grid;
  gap: 2rem;
  line-height: 1.7;
  color: #334155;
}

.content-block h2 {
  font-size: 1.5rem;
  color: #1e293b;
  margin-bottom: 0.75rem;
}

.features-list {
  padding-left: 1.25rem;
}

.features-list li {
  margin-bottom: 0.5rem;
}

/* Shared Hero Styling */
.page-hero {
  text-align: center;
  margin-bottom: 3rem;
}

.page-hero h1 {
  font-size: 2.5rem;
  color: #0f172a;
  margin-bottom: 0.5rem;
}

/* Services Grid Layout */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
}

/* Service Card Styling */
.service-card {
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 1.75rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.service-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.service-icon {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.service-card h2 {
  font-size: 1.25rem;
  color: #1e293b;
  margin-bottom: 0.5rem;
}

.service-card p {
  color: #475569;
  line-height: 1.6;
  font-size: 0.95rem;
  margin: 0;
}

/* Contact Section Layout */
.contact-layout {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2.5rem;
  align-items: start;
}

.contact-info h2 {
  font-size: 1.5rem;
  color: #1e293b;
  margin-bottom: 0.75rem;
}

.contact-info p {
  color: #475569;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.info-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  color: #334155;
}

/* Contact Form Styling */
.contact-form {
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 2rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-group label {
  font-size: 0.9rem;
  font-weight: 600;
  color: #1e293b;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  font-family: inherit;
  font-size: 0.95rem;
  color: #0f172a;
  box-sizing: border-box;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #38bdf8;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.2);
}

.submit-btn {
  background-color: var(--bg-dark, #18181b);
  color: #ffffff;
  font-weight: 600;
  padding: 0.85rem;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.submit-btn:hover {
  background-color: #0f0f10;
}

/* =================================================================
   HOME PAGE SECTION THEMING (hybrid light / dark)
   ================================================================ */

/* Home page canvas is charcoal so gaps between sheets read as dark */
.home {
  background-color: var(--bg-dark);
}

/* All home sections sit on charcoal */
.home .section {
  background-color: var(--bg-dark);
}

/* Hero: light panel with side gutters */
.home .hero-section > .wrap {
  width: calc(100% - 3rem);
  max-width: 1360px; /* wider than the 1200px global container */
  min-height: 80vh;
  display: flex;
  flex-direction: column;
  justify-content: center; /* center the content vertically in the panel */
  background-color: var(--bg-surface);
  border-radius: 24px;
  padding: var(--space-16) var(--space-12);
  margin-block: var(--space-4);
  box-shadow: 0 24px 60px -24px rgba(0, 0, 0, 0.6);
}

/* Featured & recent: a light sheet, but dulled to a soft blue-grey so it no
   longer glares against the charcoal page. No white halo; just a quiet rim.
   Layout is editorial: the featured article as one large tile on the left,
   the recent articles as a divided list on the right (stacked on mobile). */
.home .featured-section {
  position: relative;
  z-index: 1;
  width: 100%;
  background-color: #d9dee4;
  background-image:
    radial-gradient(ellipse 60% 70% at 0% 0%, rgba(255, 255, 255, 0.35) 0%, transparent 70%),
    radial-gradient(ellipse 50% 60% at 100% 100%, rgba(204, 0, 0, 0.05) 0%, transparent 70%),
    linear-gradient(180deg, #dde2e8 0%, #d3d9e0 100%);
  border-radius: 28px;
  padding-top: clamp(var(--space-16), 7vw, var(--space-24));
  padding-bottom: clamp(var(--space-16), 7vw, var(--space-24));
  margin-block: var(--space-12);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.35);
}

/* Keep the content centered inside the full-width sheet */
.home .featured-section > .wrap {
  background-color: transparent;
  box-shadow: none;
  padding-top: 0;
  padding-bottom: 0;
}

/* Small uppercase label above the heading */
.home .featured-section .section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  margin: 0 0 var(--space-3);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #4f5d6e;
}

.home .featured-section .section-eyebrow::before {
  content: "";
  width: 24px;
  height: 2px;
  border-radius: 999px;
  background-color: var(--accent-primary-strong);
  opacity: 0.8;
}

/* Headings + copy: deep slate rather than black, tuned for the grey sheet */
.home .featured-section h2 {
  font-size: clamp(var(--text-3xl), 4vw, var(--text-4xl));
  letter-spacing: -0.02em;
  color: #1c2b3f;
}

.home .featured-section p {
  color: #4a586a;
}

/* Heading on the left, "View all" link on the right (stacks on mobile) */
.home .section-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--space-4) var(--space-8);
  margin-bottom: var(--space-8);
}

.home .section-header h2 {
  margin-bottom: 0;
}

/* Shared text CTA link with a sliding arrow */
.home .section-link {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--accent-secondary);
  transition: color 0.2s ease, gap 0.2s ease;
}

.home .section-link:hover {
  gap: 0.625rem;
  color: var(--accent-primary-strong);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.home .section-link:focus-visible {
  outline: 2px solid var(--accent-primary-strong);
  outline-offset: 3px;
  border-radius: 4px;
}

/* View-all link as a small outlined pill on the grey sheet */
.home .featured-section .section-link {
  padding: 0.55rem 1rem;
  border: 1px solid rgba(28, 43, 63, 0.18);
  border-radius: 999px;
  color: #1c2b3f;
  transition: color 0.2s ease, gap 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
}

.home .featured-section .section-link:hover {
  border-color: var(--accent-primary-strong);
  background-color: rgba(255, 255, 255, 0.35);
  text-decoration: none;
}

/* Article grid: one column on mobile; on desktop the featured tile fills the
   left column and the recent articles stack as rows on the right. */
.home .article-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
}

/* Shared card basics: the title link stretches over the whole card */
.home .featured-section .article-card {
  position: relative;
  display: flex;
  flex-direction: column;
}

.home .featured-section .article-card:focus-within {
  outline: 2px solid var(--accent-primary-strong);
  outline-offset: 3px;
}

.home .article-card h3 {
  margin-bottom: var(--space-2);
  font-size: var(--text-lg);
}

.home .article-card h3 a {
  color: #1c2b3f;
  transition: color 0.2s ease;
}

.home .article-card h3 a::after {
  content: "";
  position: absolute;
  inset: 0;
}

.home .article-card h3 a:focus-visible {
  outline: none;
}

.home .article-card:hover h3 a {
  color: var(--accent-primary-strong);
}

.home .featured-section .article-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-2);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #56657a;
}

.home .article-badge {
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  background-color: rgba(204, 0, 0, 0.1);
  color: #b30000;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.home .featured-section .article-card p:not(.article-meta) {
  line-height: var(--leading-relaxed);
}

/* Recent articles: open rows divided by hairlines, no tile.
   On hover a short red bar grows in on the left and the row lightens. */
.home .featured-section .article-card:not(.article-card--featured) {
  padding: var(--space-6) var(--space-6) var(--space-6) var(--space-8);
  border-top: 1px solid rgba(28, 43, 63, 0.14);
  border-radius: 12px;
  transition: background-color 0.25s ease;
}

.home .featured-section .article-card:not(.article-card--featured)::before {
  content: "";
  position: absolute;
  top: var(--space-6);
  bottom: var(--space-6);
  left: var(--space-3);
  width: 2px;
  border-radius: 999px;
  background-color: var(--accent-primary-strong);
  transform: scaleY(0);
  transition: transform 0.25s ease;
}

.home .featured-section .article-card:not(.article-card--featured):hover {
  background-color: rgba(255, 255, 255, 0.3);
}

.home .featured-section .article-card:not(.article-card--featured):hover::before {
  transform: scaleY(1);
}

/* Featured article: one large, slightly lighter tile with a soft shadow
   and a red edge on the left. Its text sits at the bottom of the tile. */
.home .featured-section .article-card--featured {
  justify-content: flex-end;
  min-height: 20rem;
  padding: var(--space-12) var(--space-8) var(--space-8);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 20px;
  background-color: #e6eaee;
  background-image:
    radial-gradient(ellipse 70% 60% at 100% 0%, rgba(204, 0, 0, 0.07) 0%, transparent 70%),
    linear-gradient(160deg, #eceff2 0%, #e1e6eb 100%);
  box-shadow: 0 18px 36px -26px rgba(15, 23, 42, 0.45);
  overflow: hidden;
  transition: box-shadow 0.25s ease, transform 0.25s ease;
}

.home .featured-section .article-card--featured::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 3px;
  background: linear-gradient(180deg, var(--accent-primary-strong) 0%, rgba(204, 0, 0, 0.15) 100%);
}

.home .featured-section .article-card--featured:hover {
  transform: translateY(-2px);
  box-shadow: 0 24px 44px -26px rgba(15, 23, 42, 0.5);
}

/* Featured cover image: edge to edge across the top of the tile (negative
   margins cancel the tile's padding). margin-bottom: auto keeps it at the top
   while the text stays at the bottom when the tile is stretched taller. */
.home .featured-card-image {
  --fc-pad-top: var(--space-12);
  --fc-pad-x: var(--space-8);
  display: block;
  width: calc(100% + 2 * var(--fc-pad-x));
  max-width: none;
  height: auto;
  aspect-ratio: 16 / 9;
  margin: calc(-1 * var(--fc-pad-top)) calc(-1 * var(--fc-pad-x)) auto;
  object-fit: cover;
  background-color: var(--accent-secondary);
}

.home .featured-card-image + .article-meta {
  margin-top: var(--space-6);
}

.home .article-card--featured h3 {
  max-width: 24ch;
  margin-bottom: var(--space-3);
  font-size: clamp(1.5rem, 3vw, 2rem);
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.home .article-card--featured p:not(.article-meta) {
  max-width: 55ch;
  font-size: var(--text-lg);
}

@media (min-width: 64rem) {
  .home .article-grid {
    grid-template-columns: 7fr 5fr;
    column-gap: var(--space-12);
    row-gap: 0;
  }

  /* Featured tile spans the rows of up to 4 recent articles on the left
     (an unused row collapses to zero height) */
  .home .article-card--featured {
    grid-column: 1;
    grid-row: 1 / span 4;
  }

  .home .featured-section .article-card:not(.article-card--featured) {
    grid-column: 2;
  }

  /* First recent row has no line above it, so the list starts flush with the tile */
  .home .featured-section .article-card--featured + .article-card {
    border-top-color: transparent;
  }
}

/* Hero: rotating keyword with a rolling red-to-navy gradient */
/* All words (visible one + invisible sizers added by rotating-words.js) stack in
   one grid cell, so the slot always fits the longest word and the heading stays put. */
.rotating-word {
  display: inline-grid;
  align-items: start;
  justify-items: start;
}

.rotating-word > .rotating-word-text,
.rotating-word > .rotating-word-sizer {
  grid-area: 1 / 1;
}

.rotating-word-sizer {
  visibility: hidden;
  padding-bottom: 0.08em;
}

.rotating-word-text {
  padding-bottom: 0.08em; /* keeps descenders inside the clipped gradient */
  background-image: linear-gradient(
    90deg,
    var(--accent-primary-strong) 0%,
    #ff5a36 25%,
    var(--accent-secondary-hover) 50%,
    #ff5a36 75%,
    var(--accent-primary-strong) 100%
  );
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  animation: gradient-roll 6s linear infinite;
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.rotating-word-text.is-leaving {
  opacity: 0;
  transform: translateY(-0.35em);
}

.rotating-word-text.is-entering {
  opacity: 0;
  transform: translateY(0.35em);
  transition: none;
}

@keyframes gradient-roll {
  to { background-position: 200% 0; }
}

/* Hero section spacing around the panel */
.home .hero-section {
  padding-top: var(--space-12);
  padding-bottom: var(--space-12);
}

/* Topic hub: a distinct dark band with a faint red wash and dot texture */
.home .topic-hub-section {
  position: relative;
  background-color: var(--bg-dark);
  background-image:
    radial-gradient(ellipse at 50% 0%, rgba(255, 0, 0, 0.12) 0%, transparent 55%),
    radial-gradient(rgba(255, 255, 255, 0.055) 1px, transparent 1px);
  background-size: auto, 22px 22px;
  background-position: center top, center top;
}

.home .topic-hub-section .section-eyebrow {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin: 0 0 var(--space-8);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-on-dark-muted);
}

.home .topic-hub-section .section-eyebrow::before {
  content: "";
  width: 28px;
  height: 2px;
  border-radius: 999px;
  background-color: var(--accent-primary);
  box-shadow: 0 0 10px rgba(255, 0, 0, 0.7);
}

/* Cards: dark glass panels that sit inside the band instead of lifting off it.
   Each card is a single link to its topic.
   On hover a red glow rises in the corner and a red line draws along the bottom. */
.home .topic-hub-section .card {
  position: relative;
  overflow: hidden;
  min-height: 15rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: var(--space-8);
  color: var(--text-on-dark);
  text-decoration: none;
  background-color: rgba(255, 255, 255, 0.03);
  background-image:
    linear-gradient(var(--accent-primary), var(--accent-primary)),
    linear-gradient(160deg, rgba(255, 255, 255, 0.07) 0%, rgba(255, 255, 255, 0) 60%);
  background-repeat: no-repeat;
  background-position: left bottom, center;
  background-size: 0% 2px, 100% 100%;
  transition:
    background-color 0.3s ease,
    background-size 0.4s ease,
    border-color 0.3s ease;
}

/* Red glow in the top-right corner, shown on hover */
.home .topic-hub-section .card::before {
  content: "";
  position: absolute;
  top: -40%;
  right: -30%;
  width: 70%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 0, 0, 0.22) 0%, transparent 70%);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.home .topic-hub-section .card:hover {
  background-color: rgba(255, 255, 255, 0.06);
  background-size: 100% 2px, 100% 100%;
  border-color: rgba(255, 255, 255, 0.2);
}

.home .topic-hub-section .card:hover::before {
  opacity: 1;
}

.home .topic-hub-section .card:focus-visible {
  outline: 2px solid var(--accent-primary);
  outline-offset: 4px;
}

/* Title and text sit at the bottom of the card, the icon at the top */
.home .topic-hub-section .card h3 {
  position: relative;
  margin-top: auto;
  margin-bottom: var(--space-2);
  font-size: var(--text-xl);
  color: var(--text-on-dark);
}

/* Small red line icon in a ringed circle */
.home .topic-hub-icon {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  margin-bottom: var(--space-8);
  border: 1px solid rgba(255, 0, 0, 0.35);
  border-radius: 50%;
  background-color: rgba(255, 0, 0, 0.08);
  color: #ff4d4d;
  transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

.home .topic-hub-section .card:hover .topic-hub-icon {
  background-color: rgba(255, 0, 0, 0.16);
  box-shadow: 0 0 18px rgba(255, 0, 0, 0.35);
}

.home .topic-hub-icon svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.home .topic-hub-section .card p {
  position: relative;
  color: var(--text-on-dark-muted);
}

/* Topic carousel: eyebrow on the left, arrow buttons on the right */
.home .topic-carousel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  margin-bottom: var(--space-8);
}

.home .topic-carousel-header .section-eyebrow {
  margin: 0;
}

.home .topic-carousel-controls {
  display: flex;
  gap: var(--space-3);
}

.home .topic-carousel-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.06);
  color: var(--text-on-dark);
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease,
    box-shadow 0.2s ease, opacity 0.2s ease;
}

.home .topic-carousel-btn svg {
  width: 20px;
  height: 20px;
}

.home .topic-carousel-btn:hover:not(:disabled) {
  background-color: var(--accent-primary-strong, #e60000);
  border-color: var(--accent-primary-strong, #e60000);
  box-shadow: 0 0 18px rgba(255, 0, 0, 0.45);
}

.home .topic-carousel-btn:focus-visible {
  outline: 2px solid var(--accent-primary);
  outline-offset: 3px;
}

.home .topic-carousel-btn:disabled {
  opacity: 0.35;
  cursor: default;
}

/* All cards fit on screen: no need for arrows */
.home .topic-carousel.is-static .topic-carousel-controls {
  visibility: hidden;
}

/* Track: one row of cards that scrolls sideways and snaps card by card.
   The padding leaves room for the hover lift, shadow and focus ring,
   and the negative margin cancels it so the cards still line up with the eyebrow. */
.home .topic-carousel-track {
  display: flex;
  gap: var(--space-6);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: var(--space-2);
  padding: var(--space-2) var(--space-2) var(--space-12);
  margin: calc(var(--space-2) * -1) calc(var(--space-2) * -1) calc(var(--space-12) * -1);
  scrollbar-width: none;
}

.home .topic-carousel-track::-webkit-scrollbar {
  display: none;
}

/* Card widths: most of the screen on phones, 2 across on tablets, 3 on desktop */
.home .topic-carousel-track .card {
  flex: 0 0 85%;
  height: auto;
  scroll-snap-align: start;
}

@media (min-width: 48rem) {
  .home .topic-carousel-track .card {
    flex-basis: calc((100% - var(--space-6)) / 2);
  }
}

@media (min-width: 64rem) {
  .home .topic-carousel-track .card {
    flex-basis: calc((100% - var(--space-6) * 2) / 3);
  }
}

/* Approach: plain charcoal band between the dotted topic band and the light
   articles sheet. A hairline panel holds the heading + diagram on the left and
   the explanation on the right, split by a thin red-fading rule on desktop. */
.home .approach-section {
  position: relative;
  overflow: hidden;
}

/* Faint red wash low on the left, behind the diagram */
.home .approach-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 45% 60% at 18% 70%, rgba(255, 0, 0, 0.08) 0%, transparent 70%);
  pointer-events: none;
}

.home .approach-panel {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-8);
  padding: var(--space-12) var(--space-8);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.045) 0%, rgba(255, 255, 255, 0.01) 100%);
}

.home .approach-section .section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  margin: 0 0 var(--space-4);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-on-dark-muted);
}

.home .approach-section .section-eyebrow::before {
  content: "";
  width: 24px;
  height: 2px;
  border-radius: 999px;
  background-color: var(--accent-primary);
  box-shadow: 0 0 10px rgba(255, 0, 0, 0.6);
}

.home .approach-section h2 {
  max-width: 14ch;
  margin-bottom: var(--space-8);
  font-size: clamp(var(--text-3xl), 4.5vw, var(--text-4xl));
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--text-on-dark);
}

.home .approach-highlight {
  background: linear-gradient(90deg, #ff6b6b 0%, var(--accent-primary) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Diagram: two outlined circles, their overlap tinted red, a glowing dot at the centre */
.home .approach-visual svg {
  display: block;
  width: 100%;
  max-width: 320px;
  height: auto;
}

.home .approach-visual .av-ring {
  fill: none;
  stroke: rgba(255, 255, 255, 0.28);
  stroke-width: 1.25;
}

.home .approach-visual .av-overlap {
  fill: rgba(255, 0, 0, 0.14);
  stroke: rgba(255, 77, 77, 0.6);
  stroke-width: 1.25;
}

.home .approach-visual .av-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  fill: var(--text-on-dark-muted);
}

.home .approach-visual .av-dot {
  fill: #ffffff;
  filter: drop-shadow(0 0 6px rgba(255, 0, 0, 0.9));
}

/* Explanation: larger lead paragraph, then the follow-up in softer grey */
.home .approach-copy {
  align-self: center;
}

.home .approach-copy p {
  max-width: 58ch;
  color: var(--text-on-dark-muted);
  line-height: var(--leading-relaxed);
}

.home .approach-copy .approach-lead {
  margin-bottom: var(--space-6);
  font-size: var(--text-lg);
  color: var(--text-on-dark);
}

@media (min-width: 64rem) {
  .home .approach-panel {
    grid-template-columns: 5fr 6fr;
    gap: var(--space-16);
    padding: var(--space-16);
  }

  .home .approach-copy {
    position: relative;
    padding-left: var(--space-16);
  }

  /* Vertical divider between the two columns, fading out at both ends */
  .home .approach-copy::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: 1px;
    background: linear-gradient(180deg, transparent 0%, rgba(255, 0, 0, 0.5) 50%, transparent 100%);
  }

  .home .approach-copy .approach-lead {
    font-size: var(--text-xl);
  }
}

/* Pain points: three open columns under the approach panel, no card boxes.
   Each has a red icon, a short bold title and one line of grey text,
   with a hairline above that turns red on hover. */
.home .pain-points {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-8);
  margin: var(--space-12) 0 0;
  padding: 0;
  list-style: none;
}

.home .pain-point {
  position: relative;
  padding-top: var(--space-6);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Red segment on the top hairline, grows across on hover */
.home .pain-point::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 0;
  width: 32px;
  height: 1px;
  background-color: var(--accent-primary);
  box-shadow: 0 0 8px rgba(255, 0, 0, 0.7);
  transition: width 0.4s ease;
}

.home .pain-point:hover::before {
  width: 100%;
}

.home .pain-point-icon {
  display: inline-flex;
  margin-bottom: var(--space-4);
  color: #ff4d4d;
}

.home .pain-point-icon svg {
  width: 26px;
  height: 26px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.home .pain-point h3 {
  margin-bottom: var(--space-2);
  font-size: var(--text-lg);
  color: var(--text-on-dark);
}

.home .pain-point p {
  max-width: 34ch;
  color: var(--text-on-dark-muted);
  line-height: var(--leading-relaxed);
}

@media (min-width: 48rem) {
  .home .pain-points {
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-8);
  }
}

@media (min-width: 64rem) {
  .home .pain-points {
    gap: var(--space-12);
    padding: 0 var(--space-8);
  }
}

/* Mini about: full dark band with a glassy, red-glowing panel */
.home .about-section {
  background:
    radial-gradient(ellipse at 50% 50%, rgba(255, 0, 0, 0.1) 0%, transparent 60%),
    var(--bg-dark);
}

.home .about-panel {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-8);
  align-items: center;
  padding: var(--space-12) var(--space-8);
  background-color: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 0, 0, 0.5);
  border-radius: 20px;
  box-shadow:
    0 0 28px rgba(255, 0, 0, 0.22),
    0 0 70px rgba(255, 0, 0, 0.1),
    inset 0 0 30px rgba(255, 0, 0, 0.05);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.home .about-section .section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  margin: 0 0 var(--space-3);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-on-dark-muted);
}

.home .about-section .section-eyebrow::before {
  content: "";
  width: 24px;
  height: 2px;
  border-radius: 999px;
  background-color: var(--accent-primary);
  box-shadow: 0 0 10px rgba(255, 0, 0, 0.6);
}

.home .about-section h2 {
  color: var(--text-on-dark);
}

.home .about-copy > p:not(.section-eyebrow) {
  max-width: 60ch;
  margin-bottom: var(--space-6);
  color: var(--text-on-dark-muted);
  line-height: var(--leading-relaxed);
}

.home .about-section .section-link {
  color: var(--text-on-dark);
}

.home .about-section .section-link:hover {
  color: #ff6b6b;
}

/* Credentials: three stacked glass tiles with a red accent rule */
.home .credential-list {
  display: grid;
  gap: var(--space-4);
  margin: 0;
  padding: 0;
  list-style: none;
}

.home .credential-list li {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  padding: var(--space-4) var(--space-6);
  border: 1px solid var(--border-dark);
  border-left: 3px solid var(--accent-primary);
  border-radius: 12px;
  background-color: rgba(255, 255, 255, 0.04);
}

.home .credential-list strong {
  font-size: var(--text-xl);
  color: var(--text-on-dark);
}

.home .credential-list span {
  font-size: var(--text-sm);
  color: var(--text-on-dark-muted);
}

@media (min-width: 64rem) {
  .home .about-panel {
    grid-template-columns: 1.3fr 1fr;
    gap: var(--space-16);
    padding: var(--space-16) var(--space-12);
  }
}

/* Closing CTA: no box. Type set straight on the dark canvas, lit by a red
   glow rising from below, with a faint dot texture that fades at the edges.
   A short red hairline at the top separates it from the about panel. */
.home .cta-section {
  position: relative;
  overflow: hidden;
  padding-top: clamp(var(--space-16), 10vw, 9rem);
  padding-bottom: clamp(var(--space-16), 10vw, 9rem);
  background:
    radial-gradient(ellipse 70% 65% at 50% 100%, rgba(255, 0, 0, 0.16) 0%, transparent 70%),
    var(--bg-dark);
}

/* Dot texture, masked so it fades out toward the edges */
.home .cta-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(255, 255, 255, 0.07) 1px, transparent 1.5px);
  background-size: 22px 22px;
  -webkit-mask-image: radial-gradient(ellipse 60% 70% at 50% 55%, #000 0%, transparent 75%);
  mask-image: radial-gradient(ellipse 60% 70% at 50% 55%, #000 0%, transparent 75%);
  pointer-events: none;
}

/* Thin red hairline at the top, fading out at both ends */
.home .cta-section::after {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: min(60%, 520px);
  height: 1px;
  transform: translateX(-50%);
  background: linear-gradient(90deg, transparent, rgba(255, 0, 0, 0.7), transparent);
  box-shadow: 0 0 12px rgba(255, 0, 0, 0.5);
}

.home .cta-panel {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.home .cta-quote {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 0;
}

/* Oversized opening quote mark sitting behind the headline */
.home .cta-quote-mark {
  display: block;
  height: 0.5em;
  margin-bottom: var(--space-4);
  font-size: clamp(6rem, 12vw, 9rem);
  font-weight: 800;
  line-height: 1;
  color: var(--accent-primary-strong);
  opacity: 0.9;
}

.home .cta-quote blockquote {
  margin: 0;
}

.home .cta-quote h2 {
  margin: 0;
  font-size: clamp(2.25rem, 6vw, 4.75rem);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.03em;
  color: var(--text-on-dark);
  text-wrap: balance;
}

.home .cta-highlight {
  color: var(--accent-primary);
  text-shadow: 0 0 32px rgba(255, 0, 0, 0.45);
}

/* Attribution: small, spaced caps with a short red rule */
.home .cta-attribution {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  margin-top: var(--space-6);
  font-size: var(--text-sm);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-on-dark-muted);
}

.home .cta-attribution::before {
  content: "";
  width: 24px;
  height: 2px;
  border-radius: 999px;
  background-color: var(--accent-primary);
  box-shadow: 0 0 10px rgba(255, 0, 0, 0.6);
}

.home .cta-subline {
  max-width: 46ch;
  margin: var(--space-12) 0 var(--space-8);
  font-size: clamp(var(--text-lg), 2vw, var(--text-xl));
  line-height: var(--leading-normal);
  color: var(--text-on-dark-muted);
}

/* The one action: big, red, with an arrow that nudges forward on hover */
.home .cta-button {
  padding: 1.1rem 2.25rem;
  font-size: var(--text-lg);
  border-radius: 4px;
  box-shadow: 0 10px 28px -6px rgba(255, 0, 0, 0.45);
}

.home .cta-button:hover {
  box-shadow: 0 14px 34px -6px rgba(255, 0, 0, 0.55);
}

.home .cta-button svg {
  width: 1.25rem;
  height: 1.25rem;
  transition: transform 0.2s ease;
}

.home .cta-button:hover svg {
  transform: translateX(4px);
}

/* Reassurance line under the button: small and quiet */
.home .cta-note {
  margin: var(--space-4) 0 0;
  font-size: var(--text-xs);
  color: #71717a;
}

/* Let the dark CTA flow into the dark footer without a light gap */
.home #footer-placeholder .site-footer {
  margin-top: 0;
}

/* Home hero: knowledge graph drawn straight onto the light hero panel
   (no window frame). Light-background colours are set further down. */
.product-visual .pv-links path {
  fill: none;
  stroke: rgba(255, 255, 255, 0.14);
  stroke-width: 1.5;
}

.product-visual .pv-flow path {
  fill: none;
  stroke: var(--accent-primary);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-dasharray: 4 12;
  animation: pv-flow 1.6s linear infinite;
}

.product-visual .pv-flow path:nth-child(2) { animation-delay: -0.4s; }
.product-visual .pv-flow path:nth-child(3) { animation-delay: -0.8s; }
.product-visual .pv-flow path:nth-child(4) { animation-delay: -1.2s; }

@keyframes pv-flow {
  to { stroke-dashoffset: -32; }
}

.product-visual .pv-node rect {
  fill: rgba(255, 255, 255, 0.06);
  stroke: rgba(255, 255, 255, 0.16);
  stroke-width: 1;
}

.product-visual .pv-node text {
  fill: var(--text-on-dark-muted);
  font-family: var(--font-sans);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-anchor: middle;
  dominant-baseline: middle;
}

.product-visual .pv-hub rect {
  fill: rgba(255, 0, 0, 0.14);
  stroke: var(--accent-primary);
  stroke-width: 1.5;
  filter: drop-shadow(0 0 10px rgba(255, 0, 0, 0.45));
}

.product-visual .pv-hub text {
  fill: #fff;
  font-size: 11px;
}

.product-visual .pv-joints circle {
  fill: #fff;
}

/* Hero article card: title bar, body lines and benchmark bars */
.product-visual .pv-doc-title {
  fill: var(--accent-primary);
}

.product-visual .pv-doc-lines rect {
  fill: rgba(255, 255, 255, 0.22);
}

.product-visual .pv-doc-bars rect {
  fill: rgba(255, 255, 255, 0.28);
}

.product-visual .pv-doc-bars .is-hot {
  fill: var(--accent-primary);
  filter: drop-shadow(0 0 6px rgba(255, 0, 0, 0.5));
}

.product-visual .pv-doc-bars line {
  stroke: rgba(255, 255, 255, 0.2);
  stroke-width: 1;
}

/* Hero graphic: open book with a glow and floating tech icons.
   Shapes use currentColor, so this one colour sets the whole graphic. */
.hero-book {
  color: var(--accent-secondary);
}

.hero-book svg {
  width: 100%;
  height: auto;
  overflow: visible;
}

.hero-book .hb-float {
  animation: hb-float 6s ease-in-out infinite;
}

.hero-book .hb-d2 { animation-delay: -1.2s; }
.hero-book .hb-d3 { animation-delay: -2.4s; }
.hero-book .hb-d4 { animation-delay: -3.6s; }
.hero-book .hb-d5 { animation-delay: -4.8s; }

@keyframes hb-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.hero-book .hb-rotor {
  transform-box: fill-box;
  transform-origin: center;
  animation: hb-rotor 0.18s linear infinite alternate;
}

@keyframes hb-rotor {
  to { transform: scaleX(0.3); }
}

.hero-book .hb-glow {
  animation: hb-glow 4s ease-in-out infinite;
}

@keyframes hb-glow {
  0%, 100% { opacity: 0.75; }
  50% { opacity: 1; }
}

.hero-book .hb-sparks circle {
  opacity: 0;
  animation: hb-spark 4s ease-in infinite;
}

.hero-book .hb-sparks circle:nth-child(2) { animation-delay: -0.7s; }
.hero-book .hb-sparks circle:nth-child(3) { animation-delay: -1.4s; }
.hero-book .hb-sparks circle:nth-child(4) { animation-delay: -2.1s; }
.hero-book .hb-sparks circle:nth-child(5) { animation-delay: -2.8s; }
.hero-book .hb-sparks circle:nth-child(6) { animation-delay: -3.5s; }

@keyframes hb-spark {
  0% { opacity: 0; transform: translateY(0); }
  20% { opacity: 0.9; }
  100% { opacity: 0; transform: translateY(-120px); }
}

/* Hero graphic: drop the dark window panel and recolour for the white hero.
   Doubled class keeps these ahead of the shared .product-visual rules below. */
.product-visual.product-visual--hero {
  aspect-ratio: 400 / 290;
  overflow: visible;
  border-radius: 0;
  background: none;
  box-shadow: none;
}

.product-visual.product-visual--hero svg {
  padding: 0;
  overflow: visible;
}

.product-visual.product-visual--hero .pv-links path {
  stroke: rgba(11, 31, 58, 0.18);
}

.product-visual.product-visual--hero .pv-node rect {
  fill: #ffffff;
  stroke: rgba(11, 31, 58, 0.2);
}

.product-visual.product-visual--hero .pv-node text {
  fill: #20344d;
}

.product-visual.product-visual--hero .pv-flow path {
  stroke: var(--accent-secondary);
}

.product-visual.product-visual--hero .pv-hub rect {
  fill: rgba(11, 31, 58, 0.04);
  stroke: var(--accent-secondary);
  filter: drop-shadow(0 8px 18px rgba(11, 31, 58, 0.18));
}

.product-visual.product-visual--hero .pv-doc-title {
  fill: var(--accent-secondary);
}

.product-visual.product-visual--hero .pv-joints circle {
  fill: var(--accent-secondary);
}

.product-visual.product-visual--hero .pv-doc-lines rect {
  fill: rgba(11, 31, 58, 0.16);
}

.product-visual.product-visual--hero .pv-doc-bars rect {
  fill: rgba(11, 31, 58, 0.2);
}

.product-visual.product-visual--hero .pv-doc-bars .is-hot {
  fill: var(--accent-secondary);
  filter: drop-shadow(0 0 4px rgba(11, 31, 58, 0.35));
}

.product-visual.product-visual--hero .pv-doc-bars line {
  stroke: rgba(11, 31, 58, 0.2);
}

/* =================================================================
   INTERIOR PAGE THEMING (about, services, contact, legal)
   Shared charcoal canvas + soft light content sheet, matching the
   homepage's hybrid light/dark rhythm.
   ================================================================ */

.inner-page {
  background-color: var(--bg-dark);
}

/* The main content becomes a floating light sheet like the home panels */
.inner-page .page-container {
  position: relative;
  z-index: 1;
  width: calc(100% - 3rem);
  max-width: 1180px;
  min-height: 0;
  margin: var(--space-12) auto;
  padding: clamp(var(--space-16), 6vw, var(--space-24)) clamp(1.5rem, 5vw, 4rem);
  background-color: #f5f7fa;
  background-image:
    radial-gradient(ellipse 70% 55% at 12% 0%, rgba(11, 31, 58, 0.055) 0%, transparent 70%),
    radial-gradient(ellipse 60% 50% at 92% 100%, rgba(230, 0, 0, 0.04) 0%, transparent 70%),
    radial-gradient(rgba(15, 23, 42, 0.03) 1px, transparent 1px),
    linear-gradient(180deg, #fafbfc 0%, #f2f5f8 100%);
  background-size: auto, auto, 24px 24px, auto;
  border-radius: 36px;
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.05),
    0 0 24px rgba(255, 255, 255, 0.18),
    0 0 70px 8px rgba(255, 255, 255, 0.1),
    0 0 140px 24px rgba(255, 255, 255, 0.04);
}

/* Page hero: left aligned, softer contrast, room to breathe */
.inner-page .page-hero,
.inner-page .about-hero {
  margin-bottom: var(--space-12);
  padding-bottom: var(--space-8);
  text-align: left;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

.inner-page .page-hero h1,
.inner-page .about-hero h1 {
  margin-bottom: var(--space-4);
  font-size: clamp(2.25rem, 5vw, 3.5rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: #20344d;
}

.inner-page .page-hero .subtitle,
.inner-page .about-hero .subtitle {
  max-width: 60ch;
  font-size: var(--text-lg);
  line-height: var(--leading-relaxed);
  color: #5b6b7f;
}

.inner-page.products-page .page-hero .subtitle {
  max-width: 72ch;
  text-wrap: pretty;
}

/* Shared eyebrow label */
.inner-page .section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  margin: 0 0 var(--space-3);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #5c6b7d;
}

.inner-page .section-eyebrow::before {
  content: "";
  width: 24px;
  height: 2px;
  border-radius: 999px;
  background-color: var(--accent-primary-strong);
  opacity: 0.75;
}

/* Content headings + copy */
.inner-page .content-block h2,
.inner-page .section-heading h2 {
  margin-bottom: var(--space-3);
  color: #20344d;
}

.inner-page .content-block h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
}

.inner-page .section-heading {
  max-width: 65ch;
  margin-bottom: var(--space-8);
}

.inner-page .section-heading h2 {
  font-size: clamp(1.75rem, 3.5vw, 2.25rem);
}

.inner-page .about-content p,
.inner-page .section-heading p {
  color: #5b6b7f;
  line-height: var(--leading-relaxed);
}

.inner-page .about-content {
  gap: var(--space-8);
  max-width: 980px;
  color: #5b6b7f;
}

.inner-page .about-content .content-block + .content-block {
  padding-top: var(--space-8);
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}

.inner-page .content-block > p {
  max-width: 70ch;
  line-height: var(--leading-relaxed);
}

.inner-page .about-content a {
  color: var(--accent-secondary);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* About: feature list becomes a set of light cards */
.inner-page .features-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--space-4);
  margin-top: var(--space-6);
  padding: 0;
  list-style: none;
}

.inner-page .features-list li {
  padding: var(--space-6);
  border: 1px solid rgba(15, 23, 42, 0.07);
  border-radius: 16px;
  background-color: #ffffff;
  background-image: linear-gradient(180deg, #ffffff 0%, #f1f5f9 100%);
  box-shadow: 0 12px 26px -22px rgba(15, 23, 42, 0.45);
  color: #5b6b7f;
  line-height: var(--leading-relaxed);
}

.inner-page .features-list strong {
  display: block;
  margin-bottom: var(--space-2);
  color: var(--accent-secondary);
}

/* About hero: purpose statement + CTAs beside a dark focus panel */
.inner-page .about-hero {
  display: grid;
  gap: 0;
  align-items: center;
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: 0;
}

.inner-page .about-lead {
  max-width: 62ch;
  margin: 0;
  font-size: var(--text-xl);
  line-height: var(--leading-relaxed);
  color: #3f4f63;
}

.inner-page .about-hero .hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  margin-top: var(--space-8);
}

.inner-page .about-hero-panel {
  position: relative;
  overflow: hidden;
  padding: clamp(1.5rem, 4vw, 2.5rem);
  border: 1px solid rgba(230, 0, 0, 0.3);
  border-radius: 24px;
  background-color: var(--bg-dark);
  background-image:
    radial-gradient(ellipse at 100% 0%, rgba(255, 0, 0, 0.22) 0%, transparent 60%),
    linear-gradient(160deg, var(--bg-dark-surface) 0%, var(--bg-dark) 75%);
  box-shadow: 0 28px 60px -34px rgba(0, 0, 0, 0.85);
  color: var(--text-on-dark);
}

.inner-page .about-panel-label {
  margin: 0 0 var(--space-4);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-on-dark-muted);
}

.inner-page .about-focus-list {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.inner-page .about-focus-list li {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--border-dark);
  font-size: var(--text-xl);
  font-weight: 600;
  color: var(--text-on-dark);
}

.inner-page .about-focus-list li::before {
  content: "";
  flex: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--accent-primary);
  box-shadow: 0 0 10px rgba(255, 0, 0, 0.6);
}

.inner-page .about-panel-note {
  margin: var(--space-6) 0 0;
  font-size: var(--text-sm);
  line-height: var(--leading-relaxed);
  color: var(--text-on-dark-muted);
}


/* Services: tinted, rounded cards with a clear next step */
/* Single stacked column: cards hold enough content to need the full width */
.inner-page .services-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
}

.inner-page .service-card {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: var(--space-8);
  border: 1px solid rgba(15, 23, 42, 0.07);
  border-radius: 18px;
  background-color: #fbfcfd;
  background-image: linear-gradient(180deg, #ffffff 0%, #eef2f7 100%);
  box-shadow: 0 14px 30px -22px rgba(15, 23, 42, 0.45);
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease,
    border-color 0.25s ease;
}

.inner-page .service-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(230, 0, 0, 0.4) 50%,
    transparent 100%
  );
}

.inner-page .service-card:hover {
  transform: translateY(-3px);
  border-color: rgba(230, 0, 0, 0.18);
  box-shadow:
    0 22px 44px -24px rgba(15, 23, 42, 0.5),
    0 0 26px rgba(230, 0, 0, 0.06);
}

.inner-page .service-card h3 {
  margin-bottom: var(--space-3);
  font-size: var(--text-xl);
  color: var(--accent-secondary);
}

.inner-page .service-card p {
  margin-bottom: var(--space-6);
  color: #5b6b7f;
  line-height: var(--leading-relaxed);
}

/* Card eyebrow (headline): undo the generic card paragraph spacing/colour */
.inner-page .service-card .section-eyebrow {
  margin-bottom: var(--space-2);
  color: #5c6b7d;
  line-height: 1.5;
}

.inner-page .service-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin-bottom: var(--space-6);
  border: 1px solid rgba(11, 31, 58, 0.1);
  border-radius: 12px;
  background: linear-gradient(145deg, rgba(11, 31, 58, 0.09), rgba(11, 31, 58, 0.03));
  color: var(--accent-primary-strong);
  font-size: var(--text-sm);
  font-weight: 700;
  letter-spacing: 0.08em;
}

.inner-page .card-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: auto;
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--accent-secondary);
  transition: color 0.2s ease;
}

.inner-page .card-link:hover {
  color: var(--accent-primary-strong);
}

/* Service card: 4-point list */
.inner-page .service-points {
  display: grid;
  gap: var(--space-2);
  margin: 0 0 var(--space-6);
  padding: var(--space-4) 0 0;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
  list-style: none;
}

.inner-page .service-points li {
  position: relative;
  padding-left: 1.25rem;
  font-size: var(--text-sm);
  line-height: var(--leading-relaxed);
  color: #5b6b7f;
}

.inner-page .service-points li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.6em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: rgba(230, 0, 0, 0.55);
}

/* Service card: flat text link "Learn more →", pinned to the card bottom */
.inner-page .card-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  align-self: flex-start;
  margin-top: auto;
  padding: 0;
  background: none;
  color: var(--accent-secondary);
  font-size: var(--text-sm);
  font-weight: 600;
  text-decoration: none;
  transition:
    color 0.2s ease,
    gap 0.2s ease;
}

.inner-page .card-btn:hover {
  color: var(--accent-primary-strong);
  gap: 0.625rem;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.inner-page .card-btn:focus-visible {
  outline: 2px solid var(--accent-primary-strong);
  outline-offset: 3px;
  border-radius: 4px;
}

/* Service card, desktop: intro + link on the left, offerings list on the right.
   Below 64rem the card keeps its default stacked (flex column) layout. */
@media (min-width: 64rem) {
  .inner-page .service-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    grid-template-rows: 1fr auto; /* extra height goes to row 1, so the link sits at the bottom */
    column-gap: var(--space-8);
  }

  .inner-page .service-card-body {
    grid-column: 1;
    grid-row: 1;
  }

  .inner-page .service-card .service-points {
    grid-column: 2;
    grid-row: 1 / span 2;
    align-self: start;
    margin: 0;
    padding: 0 0 0 var(--space-8);
    border-top: 0;
    border-left: 1px solid rgba(15, 23, 42, 0.08);
  }

  .inner-page .service-card .card-btn {
    grid-column: 1;
    grid-row: 2;
    margin-top: 0;
  }
}

/* =================================================================
   LEGAL CENTER: grouped document cards
   ================================================================ */

.inner-page .legal-doc-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr));
  gap: var(--space-4);
  margin: var(--space-6) 0 0;
  padding: 0;
  list-style: none;
}

.inner-page .legal-doc {
  position: relative;
  padding: var(--space-6);
  border: 1px solid rgba(15, 23, 42, 0.07);
  border-radius: 16px;
  background-color: #fbfcfd;
  background-image: linear-gradient(180deg, #ffffff 0%, #eef2f7 100%);
  box-shadow: 0 14px 30px -22px rgba(15, 23, 42, 0.45);
  transition:
    transform 0.25s ease,
    border-color 0.25s ease;
}

.inner-page .legal-doc:hover {
  transform: translateY(-2px);
  border-color: rgba(230, 0, 0, 0.18);
}

.inner-page .legal-doc h3 {
  margin-bottom: var(--space-2);
  font-size: var(--text-lg);
}

/* Whole card is clickable via the title link */
.inner-page .about-content .legal-doc h3 a {
  color: var(--accent-secondary);
  text-decoration: none;
}

.inner-page .legal-doc h3 a::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
}

.inner-page .legal-doc h3 a:focus-visible {
  outline: none;
}

.inner-page .legal-doc:focus-within {
  outline: 2px solid var(--accent-primary-strong);
  outline-offset: 3px;
}

.inner-page .legal-doc p {
  margin: 0;
  font-size: var(--text-sm);
}

.inner-page .legal-doc .legal-doc-meta {
  margin-top: var(--space-3);
  font-size: 0.75rem;
  color: #7a8899;
}

/* =================================================================
   LEGAL DOCUMENT PAGES (pages/legal/*.html)
   Hero with version details, contents list, numbered clauses.
   ================================================================ */

.legal-doc-page .legal-breadcrumb {
  margin-bottom: var(--space-6);
  font-size: var(--text-sm);
  color: #7a8899;
}

.legal-doc-page .legal-breadcrumb a {
  color: var(--accent-secondary);
  font-weight: 500;
  text-decoration: none;
}

.legal-doc-page .legal-breadcrumb a:hover {
  color: var(--accent-primary-strong);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Version / issued / issued by strip under the title */
.legal-doc-page .legal-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4) var(--space-8);
  margin: var(--space-6) 0 0;
}

.legal-doc-page .legal-meta dt {
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #7a8899;
}

.legal-doc-page .legal-meta dd {
  margin: 0;
  font-weight: 600;
  color: #20344d;
}

/* Contents: a collapsible card on small screens */
.legal-doc-page .legal-toc {
  margin-bottom: var(--space-12);
  padding: var(--space-4) var(--space-6);
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 16px;
  background-color: rgba(255, 255, 255, 0.7);
}

.legal-doc-page .legal-toc summary {
  cursor: pointer;
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #5c6b7d;
}

.legal-doc-page .legal-toc ol {
  display: grid;
  gap: var(--space-2);
  margin: var(--space-4) 0 var(--space-2);
  padding: 0;
  list-style: none;
  font-size: var(--text-sm);
}

.legal-doc-page .legal-toc a {
  display: flex;
  gap: 0.5rem;
  font-weight: 500;
  color: var(--accent-secondary);
  text-decoration: none;
}

.legal-doc-page .legal-toc a:hover {
  color: var(--accent-primary-strong);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.legal-doc-page .legal-toc .clause-num {
  flex: none;
  min-width: 1.75rem;
  color: #7a8899;
}

/* Document body */
.legal-doc-page .legal-body {
  max-width: 46rem;
  color: #3d4d61;
  line-height: var(--leading-relaxed);
}

.legal-doc-page .legal-section {
  scroll-margin-top: var(--space-8);
}

.legal-doc-page .legal-section + .legal-section {
  margin-top: var(--space-12);
  padding-top: var(--space-8);
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}

.legal-doc-page .legal-body h2 {
  margin-bottom: var(--space-4);
  font-size: clamp(1.375rem, 2.5vw, 1.75rem);
  color: #20344d;
}

.legal-doc-page .legal-body h3 {
  margin: var(--space-8) 0 var(--space-3);
  font-size: var(--text-lg);
  color: #20344d;
  scroll-margin-top: var(--space-8);
}

.legal-doc-page .legal-body .clause-num {
  margin-right: 0.25rem;
  color: var(--accent-primary-strong);
}

.legal-doc-page .legal-body p,
.legal-doc-page .legal-body ul,
.legal-doc-page .legal-body dl {
  margin: 0 0 var(--space-4);
}

.legal-doc-page .legal-body strong {
  color: #20344d;
}

.legal-doc-page .legal-body a {
  color: var(--accent-secondary);
  text-decoration: underline;
  text-underline-offset: 3px;
  overflow-wrap: anywhere;
}

.legal-doc-page .legal-body a:hover {
  color: var(--accent-primary-strong);
}

/* Numbered clause: number hangs in the left margin */
.legal-doc-page .legal-clause {
  position: relative;
  padding-left: 3rem;
  scroll-margin-top: var(--space-8);
}

.legal-doc-page .legal-clause .clause-num {
  position: absolute;
  left: 0;
  font-weight: 600;
}

.legal-doc-page .legal-clause:target {
  border-radius: 8px;
  background-color: rgba(230, 0, 0, 0.05);
  box-shadow: 0 0 0 0.5rem rgba(230, 0, 0, 0.05);
}

/* Bulleted lists */
.legal-doc-page .legal-list {
  display: grid;
  gap: var(--space-2);
  padding: 0;
  list-style: none;
}

.legal-doc-page .legal-list li {
  position: relative;
  padding-left: 1.25rem;
}

.legal-doc-page .legal-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.7em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: rgba(230, 0, 0, 0.55);
}

/* Definitions */
.legal-doc-page .legal-defs {
  display: grid;
  gap: var(--space-4);
}

.legal-doc-page .legal-defs dt {
  font-weight: 700;
  color: #20344d;
}

.legal-doc-page .legal-defs dd {
  margin: 0;
}

/* Tables scroll sideways on narrow screens instead of the page */
.legal-doc-page .legal-table-wrap {
  margin: var(--space-4) 0 var(--space-6);
  overflow-x: auto;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 12px;
  background-color: #ffffff;
}

.legal-doc-page .legal-table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--text-sm);
  line-height: var(--leading-normal);
}

.legal-doc-page .legal-table th,
.legal-doc-page .legal-table td {
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid rgba(15, 23, 42, 0.07);
  text-align: left;
  vertical-align: top;
}

.legal-doc-page .legal-table thead th,
.legal-doc-page .legal-table thead td {
  background-color: #eef2f7;
  font-weight: 600;
  color: #20344d;
  white-space: nowrap;
}

.legal-doc-page .legal-table tbody th {
  font-weight: 600;
  color: #20344d;
}

.legal-doc-page .legal-table tbody tr:last-child > * {
  border-bottom: 0;
}

/* Closing note */
.legal-doc-page .legal-doc-footer {
  margin-top: var(--space-12);
  padding-top: var(--space-6);
  border-top: 1px solid rgba(15, 23, 42, 0.08);
  font-size: var(--text-sm);
  color: #5b6b7f;
}

.legal-doc-page .legal-doc-footer p {
  margin-bottom: var(--space-2);
}

/* Wide screens: contents move to a sticky right-hand column, like articles */
@media (min-width: 64rem) {
  .legal-doc-page .legal-layout {
    display: grid;
    grid-template-columns: minmax(0, 46rem) minmax(13rem, 16rem);
    grid-template-areas: "body toc";
    column-gap: var(--space-12);
  }

  .legal-doc-page .legal-body { grid-area: body; }

  .legal-doc-page .legal-toc {
    grid-area: toc;
    align-self: start;
    position: sticky;
    top: var(--space-8);
    max-height: calc(100vh - var(--space-16));
    overflow-y: auto;
    margin: 0;
    padding: var(--space-2) var(--space-4);
    border: 0;
    border-left: 1px solid rgba(15, 23, 42, 0.1);
    border-radius: 0;
    background: none;
  }

  /* Always open here, so the summary is just a label */
  .legal-doc-page .legal-toc summary {
    cursor: default;
    pointer-events: none;
    list-style: none;
  }

  .legal-doc-page .legal-toc summary::-webkit-details-marker {
    display: none;
  }
}

/* Print: drop the site chrome and contents, keep the document */
@media print {
  .legal-doc-page .site-header,
  .legal-doc-page #footer-placeholder,
  .legal-doc-page .legal-toc,
  .legal-doc-page .legal-breadcrumb {
    display: none;
  }

  .legal-doc-page .page-container {
    margin: 0;
    padding: 0;
    background: none;
    box-shadow: none;
  }

  .legal-doc-page .legal-layout {
    display: block;
  }

  .legal-doc-page .legal-body {
    max-width: none;
  }
}

/* =================================================================
   RESOURCE HUB: Topics + Articles pages
   ================================================================ */

/* Topics: full-width cards stacked in a single column (reuses .service-card styling) */
.inner-page .topics-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
}

/* Topic card: graphic on top on small screens; text left, graphic right from 48rem */
.inner-page .service-card.topic-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-areas:
    "art"
    "body"
    "btn";
  scroll-margin-top: var(--space-8);
}

.inner-page .topic-card .service-card-body { grid-area: body; }
.inner-page .topic-card .card-btn { grid-area: btn; margin-top: 0; }

.inner-page .topic-art {
  grid-area: art;
  width: 100%;
  max-width: 16rem;
  margin-bottom: var(--space-6);
  color: var(--accent-secondary); /* currentColor for the SVG, same palette as the home hero */
}

.inner-page .topic-art svg {
  display: block;
  width: 100%;
  height: auto;
}

@media (min-width: 48rem) {
  /* Text column capped at a comfortable line length; the graphic sits centred
     in the remaining space so it never crowds the card edge */
  .inner-page .service-card.topic-card {
    grid-template-columns: minmax(0, 34rem) minmax(12rem, 1fr);
    grid-template-rows: 1fr auto;
    grid-template-areas:
      "body art"
      "btn  art";
    column-gap: var(--space-12);
    padding: var(--space-8) var(--space-12);
  }

  .inner-page .topic-card .service-card-body p {
    margin-bottom: var(--space-6);
  }

  .inner-page .topic-art {
    max-width: 15rem;
    margin-bottom: 0;
    align-self: center;
    justify-self: center;
  }
}

/* Articles: quick jump links to each topic group */
.inner-page .topic-jump {
  margin-bottom: var(--space-12);
}

.inner-page .topic-jump ul {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin: 0;
  padding: 0;
  list-style: none;
}

.inner-page .topic-jump a {
  display: inline-block;
  padding: var(--space-2) var(--space-4);
  border: 1px solid rgba(15, 23, 42, 0.1);
  border-radius: 999px;
  background-color: #ffffff;
  color: var(--accent-secondary);
  font-size: var(--text-sm);
  font-weight: 600;
  text-decoration: none;
  transition:
    border-color 0.2s ease,
    color 0.2s ease;
}

.inner-page .topic-jump a:hover {
  border-color: rgba(230, 0, 0, 0.3);
  color: var(--accent-primary-strong);
}

.inner-page .topic-jump a:focus-visible {
  outline: 2px solid var(--accent-primary-strong);
  outline-offset: 3px;
  border-radius: 999px;
}

/* Articles: one group per topic */
.inner-page .article-group {
  padding-block: var(--space-8);
  border-top: 1px solid rgba(15, 23, 42, 0.08);
  scroll-margin-top: var(--space-8);
}

.inner-page .article-group h2 {
  margin-bottom: var(--space-6);
  font-size: var(--text-2xl);
  color: #20344d;
}

.inner-page .article-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 18rem), 1fr));
  gap: var(--space-6);
}

/* Article card: the title link stretches over the whole card (h3 a::after),
   so clicking anywhere on the card opens the article */
.inner-page .article-card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: var(--space-6);
  border: 1px solid rgba(15, 23, 42, 0.07);
  border-radius: 16px;
  background-image: linear-gradient(180deg, #ffffff 0%, #eef2f7 100%);
  box-shadow: 0 14px 30px -22px rgba(15, 23, 42, 0.45);
  transition:
    transform 0.2s ease,
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.inner-page .article-card:hover {
  transform: translateY(-2px);
  border-color: rgba(230, 0, 0, 0.25);
  box-shadow: 0 18px 34px -22px rgba(15, 23, 42, 0.55);
}

/* Keyboard focus rings the whole card rather than just the title */
.inner-page .article-card:focus-within {
  outline: 2px solid var(--accent-primary-strong);
  outline-offset: 3px;
}

/* Card image: the article's cover, edge to edge across the top of the card.
   Markup: <img class="article-card-image" ...> as the card's first child.
   Articles without a cover yet get the placeholder instead:
   <div class="article-card-image article-card-image--placeholder" aria-hidden="true"><span>Topic</span></div> */
.inner-page .article-card-image {
  display: block;
  width: calc(100% + 2 * var(--space-6));
  max-width: none;
  height: auto;
  aspect-ratio: 16 / 9;
  margin: calc(-1 * var(--space-6)) calc(-1 * var(--space-6)) var(--space-4);
  border-radius: 16px 16px 0 0;
  object-fit: cover;
  background-color: var(--accent-secondary);
}

.inner-page .article-card-image--placeholder {
  position: relative;
  display: flex;
  align-items: flex-end;
  padding: var(--space-4) var(--space-6);
  background:
    url("../images/rnd_red.svg") no-repeat right var(--space-4) top var(--space-4) / auto 2.25rem,
    radial-gradient(ellipse at 85% 110%, rgba(230, 0, 0, 0.35) 0%, transparent 60%),
    linear-gradient(135deg, #0b1f3a 0%, #18181b 100%);
}

.inner-page .article-card-image--placeholder span {
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.85);
}

.inner-page .article-meta {
  margin-bottom: var(--space-2);
  font-size: var(--text-xs);
  color: #5c6b7d;
}

.inner-page .article-card h3 {
  margin-bottom: var(--space-2);
  font-size: 1.0625rem; /* 17px */
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: -0.005em;
  text-wrap: balance;
}

.inner-page .article-card h3 a {
  color: var(--accent-secondary);
  text-decoration: none;
  transition: color 0.2s ease;
}

.inner-page .article-card h3 a::after {
  content: "";
  position: absolute;
  inset: 0;
}

.inner-page .article-card h3 a:focus-visible {
  outline: none;
}

.inner-page .article-card:hover h3 a {
  color: var(--accent-primary-strong);
}

.inner-page .article-card p:not(.article-meta) {
  font-size: 0.9375rem; /* 15px */
  line-height: 1.65;
  color: #5b6b7f;
}

@media (prefers-reduced-motion: reduce) {
  .inner-page .article-card {
    transition: none;
  }

  .inner-page .article-card:hover {
    transform: none;
  }
}

/* Topic hub pages (pages/topichub/*.html) */
.inner-page .topic-back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  margin-bottom: var(--space-6);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--accent-secondary);
  text-decoration: none;
}

.inner-page .topic-back-link:hover {
  color: var(--accent-primary-strong);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.inner-page .topic-back-link:focus-visible {
  outline: 2px solid var(--accent-primary-strong);
  outline-offset: 3px;
  border-radius: 4px;
}

.inner-page .topic-hub-hero .section-eyebrow {
  display: flex;
}

.inner-page .topic-intro {
  max-width: 56ch; /* keeps the paragraph on the plain side of the hero image */
  font-size: var(--text-base);
  line-height: var(--leading-relaxed);
  color: #5b6b7f;
}

/* Topic hub hero: image bleeds to the card's top-right corner and fades into
   the card colour. The custom properties mirror .page-container's padding so
   the image can cancel it out and sit flush with the edge. */
.inner-page.topic-hub-page .page-container {
  --pc-pad-top: clamp(var(--space-8), 3vw, var(--space-12)); /* tighter than other inner pages */
  --pc-pad-x: clamp(1.5rem, 5vw, 4rem);
  padding-top: var(--pc-pad-top);
  overflow: hidden; /* clip the image to the rounded corner */
}

.inner-page .topic-hub-hero {
  position: relative;
  isolation: isolate;
}

/* The image is masked (faded to transparent) rather than painted over, so it
   blends into the card's own background colour with no visible seam. */
.inner-page .topic-hub-hero::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: calc(-1 * var(--pc-pad-top));
  right: calc(-1 * var(--pc-pad-x));
  bottom: 0;
  width: calc(45% + var(--pc-pad-x));
  background: url("../images/ogmdtrnd.png") right center / cover no-repeat;
  /* Eased left-to-right fade (many stops avoid a visible start line). */
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, rgba(0, 0, 0, 0.12) 15%, rgba(0, 0, 0, 0.3) 30%, rgba(0, 0, 0, 0.55) 50%, rgba(0, 0, 0, 0.8) 70%, rgba(0, 0, 0, 0.95) 90%, rgba(0, 0, 0, 1) 100%);
  mask-image: linear-gradient(90deg, transparent 0%, rgba(0, 0, 0, 0.12) 15%, rgba(0, 0, 0, 0.3) 30%, rgba(0, 0, 0, 0.55) 50%, rgba(0, 0, 0, 0.8) 70%, rgba(0, 0, 0, 0.95) 90%, rgba(0, 0, 0, 1) 100%);
  pointer-events: none;
}

/* Per-topic hero images */
.inner-page .topic-hub-hero--ai::before { background-image: url("../images/topics/phonechat.jpg"); }
.inner-page .topic-hub-hero--data::before { background-image: url("../images/topics/codedata.jpg"); background-position: left center; }
.inner-page .topic-hub-hero--cloud::before { background-image: url("../images/topics/serverroom.jpg"); }
.inner-page .topic-hub-hero--iot::before { background-image: url("../images/topics/IoT.jpg"); }
.inner-page .topic-hub-hero--security::before { background-image: url("../images/topics/log.jpg"); background-position: left center; }

@media (max-width: 47.99rem) {
  .inner-page.topic-hub-page .page-container {
    --pc-pad-top: var(--space-8);
    --pc-pad-x: var(--container-padding);
  }

  /* Text runs full width on small screens, so the image becomes a strip along
     the top edge (behind the back link) and fades out before the title. */
  .inner-page .topic-hub-hero::before {
    bottom: auto;
    height: calc(var(--pc-pad-top) + 3rem);
    width: calc(100% + 2 * var(--pc-pad-x));
    -webkit-mask-image:
      linear-gradient(90deg, transparent 0%, #000 70%),
      linear-gradient(0deg, transparent 0%, #000 60%);
    -webkit-mask-composite: source-in;
    mask-image:
      linear-gradient(90deg, transparent 0%, #000 70%),
      linear-gradient(0deg, transparent 0%, #000 60%);
    mask-composite: intersect;
  }
}

/* Topic hub: soft "see it in our products" strip at the end of the page.
   Deliberately quieter than .inner-cta: light surface, slim layout, outlined link. */
.inner-page .product-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-6) var(--space-8);
  margin-top: var(--space-8);
  padding: var(--space-6) var(--space-8);
  border: 1px solid rgba(11, 31, 58, 0.08);
  border-left: 3px solid var(--accent-primary-strong);
  border-radius: 14px;
  background-color: rgba(11, 31, 58, 0.035);
}

.inner-page .product-strip-text {
  flex: 1 1 22rem;
  max-width: 40rem;
}

.inner-page .product-strip-label {
  margin-bottom: var(--space-1, 0.25rem);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-primary-strong);
}

.inner-page .product-strip h2 {
  margin-bottom: var(--space-2);
  font-size: var(--text-xl);
  color: var(--accent-secondary);
}

.inner-page .product-strip-text p:not(.product-strip-label) {
  color: #5b6b7f;
  line-height: var(--leading-relaxed);
}

.inner-page .product-strip-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
  padding: 0.625rem 1.125rem;
  border: 1px solid rgba(11, 31, 58, 0.2);
  border-radius: 999px;
  background-color: var(--bg-surface);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--accent-secondary);
  text-decoration: none;
  transition: border-color 0.2s ease, color 0.2s ease, gap 0.2s ease;
}

.inner-page .product-strip-link:hover {
  gap: 0.75rem;
  border-color: var(--accent-primary-strong);
  color: var(--accent-primary-strong);
}

.inner-page .product-strip-link:focus-visible {
  outline: 2px solid var(--accent-primary-strong);
  outline-offset: 3px;
}

@media (max-width: 47.99rem) {
  .inner-page .product-strip {
    padding: var(--space-6);
  }
}

@media (prefers-reduced-motion: reduce) {
  .inner-page .product-strip-link {
    transition: none;
  }
}

/* The hero already draws a divider, so the first group doesn't need its own */
.inner-page .topic-hub-hero + .article-group {
  padding-top: 0;
  border-top: 0;
}

.inner-page .article-group-header {
  margin-bottom: var(--space-6);
}

.inner-page .article-group-header h2 {
  margin-bottom: var(--space-2);
}

.inner-page .article-group-context {
  max-width: 60ch;
  color: #5b6b7f;
  line-height: var(--leading-relaxed);
}

.inner-page .article-empty {
  color: #5b6b7f;
  font-style: italic;
}

/* -----------------------------------------------------------------
   Topic hub primer: plain-language context between the hero and the
   article catalog. Reads top to bottom as a short briefing:
   overview (what / why now) -> main parts -> field note -> our approach.
   The approach panel is the one dark block, so it lands as the point
   where reading turns into "talk to us".
   ----------------------------------------------------------------- */
.inner-page .topic-primer {
  display: grid;
  gap: clamp(var(--space-8), 5vw, var(--space-12));
  margin-bottom: var(--space-12);
}

.inner-page .topic-primer h2 {
  margin-bottom: var(--space-3);
  font-size: var(--text-xl);
  letter-spacing: -0.01em;
  color: #20344d;
}

.inner-page .primer-label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-2);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-primary-strong);
}

/* Overview: two cards side by side from 56rem */
.inner-page .primer-overview {
  display: grid;
  gap: var(--space-6);
}

.inner-page .primer-card {
  padding: clamp(var(--space-6), 3vw, var(--space-8));
  border: 1px solid rgba(15, 23, 42, 0.07);
  border-radius: 16px;
  background-image: linear-gradient(180deg, #ffffff 0%, #f3f6fa 100%);
  box-shadow: 0 14px 30px -24px rgba(15, 23, 42, 0.45);
}

.inner-page .primer-card p {
  color: #5b6b7f;
  line-height: var(--leading-relaxed);
}

.inner-page .primer-card p + p {
  margin-top: var(--space-4);
}

/* "Cheaper to try / same cost to trust" pair */
.inner-page .primer-tradeoff {
  display: grid;
  gap: var(--space-3);
  margin: var(--space-6) 0 0;
  padding: var(--space-6) 0 0;
  border-top: 1px dashed rgba(15, 23, 42, 0.14);
  list-style: none;
}

.inner-page .primer-tradeoff li {
  display: grid;
  grid-template-columns: 1.75rem 1fr;
  gap: var(--space-3);
  align-items: start;
  color: #5b6b7f;
  line-height: var(--leading-normal);
}

.inner-page .primer-tradeoff li::before {
  content: "\2193"; /* down arrow: cost has fallen */
  content: "\2193" / "";
  display: grid;
  place-items: center;
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 50%;
  background-color: rgba(11, 31, 58, 0.08);
  color: var(--accent-secondary);
  font-size: var(--text-sm);
  font-weight: 700;
}

.inner-page .primer-tradeoff li.is-risk::before {
  content: "="; /* cost unchanged */
  content: "=" / "";
  background-color: rgba(230, 0, 0, 0.1);
  color: var(--accent-primary-strong);
}

.inner-page .primer-tradeoff li.is-rising::before {
  content: "\2191"; /* up arrow: cost grows */
  content: "\2191" / "";
}

.inner-page .primer-tradeoff strong {
  color: var(--accent-secondary);
}

/* Main parts: icon tiles */
.inner-page .primer-parts-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 1fr));
  gap: var(--space-4);
  margin: var(--space-4) 0 0;
  padding: 0;
  list-style: none;
}

.inner-page .primer-part {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  padding: var(--space-6);
  border: 1px solid rgba(15, 23, 42, 0.07);
  border-radius: 14px;
  background-color: var(--bg-surface);
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.inner-page .primer-part:hover {
  border-color: rgba(230, 0, 0, 0.25);
  transform: translateY(-2px);
  box-shadow: 0 16px 28px -22px rgba(15, 23, 42, 0.5);
}

.inner-page .primer-part-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  margin-bottom: var(--space-2);
  border: 1px solid rgba(230, 0, 0, 0.25);
  border-radius: 50%;
  background-color: rgba(230, 0, 0, 0.06);
  color: var(--accent-primary-strong);
}

.inner-page .primer-part-icon svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.inner-page .primer-part strong {
  font-size: var(--text-base);
  color: var(--accent-secondary);
}

.inner-page .primer-part span:last-child {
  font-size: var(--text-sm);
  line-height: var(--leading-normal);
  color: #5b6b7f;
}

/* Field note: quoted observation with a red rule */
.inner-page .primer-insight {
  position: relative;
  padding: clamp(var(--space-6), 3vw, var(--space-8));
  padding-right: clamp(var(--space-6), 8vw, 7rem);
  border-left: 3px solid var(--accent-primary-strong);
  border-radius: 0 14px 14px 0;
  background-color: rgba(11, 31, 58, 0.035);
  overflow: hidden;
}

.inner-page .primer-insight::after {
  content: "\201C";
  content: "\201C" / "";
  position: absolute;
  top: -1.5rem;
  right: var(--space-6);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 9rem;
  line-height: 1;
  color: rgba(11, 31, 58, 0.07);
  pointer-events: none;
}

.inner-page .primer-insight p:not(.primer-label) {
  max-width: 68ch;
  font-size: var(--text-lg);
  line-height: var(--leading-relaxed);
  color: #20344d;
}

/* Floating action button (created by jscript/topic-fab.js).
   "Articles ↓" above the catalog; switches to "Back to top ↑" (.is-top)
   once the articles are in view. */
.articles-fab {
  position: fixed;
  right: max(var(--space-4), env(safe-area-inset-right));
  bottom: max(var(--space-4), env(safe-area-inset-bottom));
  z-index: 40;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  border-radius: 999px;
  background-color: var(--accent-secondary);
  box-shadow: 0 12px 28px -10px rgba(11, 31, 58, 0.6);
  font-family: var(--font-sans);
  font-size: var(--text-sm);
  font-weight: 600;
  color: #ffffff;
  text-decoration: none;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0s linear 0.25s, background-color 0.2s ease;
}

.articles-fab.is-visible {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0s, background-color 0.2s ease;
}

.articles-fab:hover {
  background-color: var(--accent-secondary-hover);
}

.articles-fab:focus-visible {
  outline: 2px solid var(--accent-primary-strong);
  outline-offset: 3px;
}

@media (min-width: 48rem) {
  .articles-fab {
    right: var(--space-8);
    bottom: var(--space-8);
  }
}

@media (prefers-reduced-motion: reduce) {
  .articles-fab,
  .articles-fab.is-visible {
    transform: none;
    transition: none;
  }
}

/* Our approach: dark panel with a 4-step flow (vertical on mobile).
   Sits after the article groups, just before the product strip. */
.inner-page .primer-approach {
  margin-top: var(--space-8);
  scroll-margin-top: var(--space-8);
  padding: clamp(var(--space-8), 5vw, var(--space-12));
  border-radius: 20px;
  background-color: var(--accent-secondary);
  background-image:
    radial-gradient(ellipse 55% 70% at 100% 0%, rgba(230, 0, 0, 0.2) 0%, transparent 65%),
    linear-gradient(160deg, #0b1f3a 0%, #12305a 100%);
  box-shadow: 0 30px 60px -40px rgba(11, 31, 58, 0.8);
  color: var(--text-on-dark);
}

.inner-page .primer-approach .primer-label {
  color: #ff6b6b;
}

.inner-page .primer-approach h2 {
  margin-bottom: var(--space-3);
  font-size: clamp(var(--text-2xl), 3vw, var(--text-3xl));
  letter-spacing: -0.01em;
  color: #ffffff;
}

.inner-page .primer-approach-lede {
  max-width: 60ch;
  color: var(--text-on-dark-muted);
  line-height: var(--leading-relaxed);
}

.inner-page .primer-steps {
  --step-node: 2.5rem;
  --step-gap: var(--space-8);
  display: grid;
  gap: var(--step-gap);
  margin: var(--space-8) 0 0;
  padding: 0;
  list-style: none;
}

.inner-page .primer-step {
  position: relative;
  display: grid;
  grid-template-columns: var(--step-node) 1fr;
  column-gap: var(--space-4);
  align-items: start;
}

/* Connector to the next step */
.inner-page .primer-step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: var(--step-node);
  bottom: calc(-1 * var(--step-gap));
  left: calc(var(--step-node) / 2 - 1px);
  width: 2px;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.35), rgba(255, 107, 107, 0.6));
}

.inner-page .primer-step-num {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: var(--step-node);
  height: var(--step-node);
  border: 2px solid rgba(255, 255, 255, 0.4);
  border-radius: 50%;
  background-color: #0e2647;
  font-size: var(--text-sm);
  font-weight: 700;
  color: #ffffff;
}

.inner-page .primer-step:last-child .primer-step-num {
  border-color: var(--accent-primary);
  background-color: var(--accent-primary);
  box-shadow: 0 0 0 6px rgba(255, 0, 0, 0.18);
}

.inner-page .primer-step h3 {
  margin-bottom: var(--space-2);
  padding-top: 0.5rem;
  font-size: var(--text-lg);
  color: #ffffff;
}

.inner-page .primer-step p {
  color: var(--text-on-dark-muted);
  line-height: var(--leading-relaxed);
}

.inner-page .primer-approach-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4) var(--space-8);
  margin-top: var(--space-8);
  padding-top: var(--space-6);
  border-top: 1px solid var(--border-dark);
}

.inner-page .primer-approach-cta p {
  flex: 1 1 22rem;
  max-width: 52ch;
  color: var(--text-on-dark);
  line-height: var(--leading-normal);
}

.inner-page .primer-approach-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
  padding: 0.75rem 1.25rem;
  border-radius: 999px;
  background-color: var(--accent-primary-strong);
  font-size: var(--text-sm);
  font-weight: 600;
  color: #ffffff;
  text-decoration: none;
  transition: background-color 0.2s ease, gap 0.2s ease;
}

.inner-page .primer-approach-link:hover {
  gap: 0.75rem;
  background-color: var(--accent-hover);
}

.inner-page .primer-approach-link:focus-visible {
  outline: 2px solid #ffffff;
  outline-offset: 3px;
}

@media (min-width: 56rem) {
  .inner-page .primer-overview {
    grid-template-columns: 1.1fr 1fr;
  }

  .inner-page .primer-steps {
    grid-template-columns: repeat(4, 1fr);
  }

  .inner-page .primer-step {
    grid-template-columns: 1fr;
    row-gap: var(--space-4);
    padding-right: var(--space-2);
  }

  .inner-page .primer-step:not(:last-child)::after {
    top: calc(var(--step-node) / 2 - 1px);
    right: calc(-1 * var(--step-gap));
    bottom: auto;
    left: var(--step-node);
    width: auto;
    height: 2px;
    background: linear-gradient(to right, rgba(255, 255, 255, 0.35), rgba(255, 107, 107, 0.6));
  }

  .inner-page .primer-step h3 {
    padding-top: 0;
  }
}

@media (min-width: 64rem) {
  .inner-page .primer-parts-list {
    grid-template-columns: repeat(5, 1fr);
  }
}

@media (prefers-reduced-motion: reduce) {
  .inner-page .primer-part,
  .inner-page .primer-approach-link {
    transition: none;
  }

  .inner-page .primer-part:hover {
    transform: none;
  }
}

/* =================================================================
   ARTICLE PAGE (pages/articles/*.html)
   One readable column for the header and body; related cards and the
   product strip below keep the full page width.
   ================================================================ */

.article-page .article {
  max-width: 46rem;
}

/* Breadcrumb: Home › Topics › Topic hub. Shows where the article sits on the site,
   whichever page the reader arrived from. The last crumb (the topic) is highlighted. */
.article-page .breadcrumb {
  margin-bottom: var(--space-6);
}

.article-page .breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: var(--text-sm);
  font-weight: 600;
}

.article-page .breadcrumb li {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.article-page .breadcrumb li + li::before {
  content: "\203A"; /* › */
  font-weight: 400;
  color: #8a96a6;
}

.article-page .breadcrumb a {
  color: var(--accent-secondary);
  text-decoration: none;
}

.article-page .breadcrumb li:last-child a {
  color: var(--accent-primary-strong);
}

.article-page .breadcrumb a:hover {
  color: var(--accent-primary-strong);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.article-page .breadcrumb a:focus-visible {
  outline: 2px solid var(--accent-primary-strong);
  outline-offset: 3px;
  border-radius: 4px;
}

.article-page .article-header .article-meta {
  margin: var(--space-6) 0 0;
  font-size: var(--text-sm);
}

.article-page .article-author {
  font-weight: 600;
  color: #20344d;
}

/* Images: rounded, full column width; the light fill shows while loading */
.article-page .article figure {
  margin: var(--space-8) 0;
}

.article-page .article figure img {
  width: 100%;
  height: auto;
  border-radius: 16px;
  background-color: #e7ebf1;
}

/* Inline SVG diagrams: centred, capped width so the text stays readable */
.article-page .article .article-diagram svg {
  display: block;
  width: 100%;
  max-width: 40rem;
  height: auto;
  margin: 0 auto;
}

.article-page .article figcaption {
  margin-top: var(--space-3);
  font-size: var(--text-sm);
  line-height: var(--leading-normal);
  color: #5c6b7d;
}

.article-page .article-hero-image {
  margin-top: 0;
}

/* Table of contents card */
.article-page .article-toc {
  margin: var(--space-8) 0 var(--space-12);
  padding: var(--space-6);
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 16px;
  background-color: rgba(255, 255, 255, 0.7);
}

.article-page .article-toc h2 {
  margin-bottom: var(--space-3);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #5c6b7d;
}

.article-page .article-toc ol {
  display: grid;
  gap: var(--space-2);
  padding-left: 1.25rem;
  color: #5c6b7d;
}

.article-page .article-toc a {
  font-weight: 500;
  color: var(--accent-secondary);
  text-decoration: none;
}

.article-page .article-toc a:hover {
  color: var(--accent-primary-strong);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Body copy */
.article-page .article-body p,
.article-page .article-body li {
  font-size: var(--text-lg);
  line-height: var(--leading-relaxed);
  color: #3d4b5c;
}

.article-page .article-body p {
  margin-bottom: var(--space-6);
}

.article-page .article-body .article-lead {
  font-size: var(--text-xl);
  color: #20344d;
}

.article-page .article-body section {
  scroll-margin-top: var(--space-8); /* leaves space above a heading reached from the contents */
}

.article-page .article-body h2 {
  margin: var(--space-12) 0 var(--space-4);
  font-size: var(--text-3xl);
  letter-spacing: -0.01em;
  color: #20344d;
}

.article-page .article-body h3 {
  margin: var(--space-8) 0 var(--space-3);
  font-size: var(--text-xl);
  color: #20344d;
}

.article-page .article-body a {
  color: var(--accent-secondary);
  text-decoration: underline;
  text-decoration-color: rgba(230, 0, 0, 0.5);
  text-underline-offset: 3px;
}

.article-page .article-body a:hover {
  color: var(--accent-primary-strong);
}

.article-page .article-body strong {
  color: #20344d;
}

.article-page .article-body ul,
.article-page .article-body ol {
  display: grid;
  gap: var(--space-2);
  margin-bottom: var(--space-6);
  padding-left: 1.5rem;
}

.article-page .article-body li::marker {
  color: var(--accent-primary-strong);
}

/* Pull quote */
.article-page .article-body blockquote {
  margin: var(--space-8) 0;
  padding: var(--space-2) 0 var(--space-2) var(--space-6);
  border-left: 3px solid var(--accent-primary-strong);
}

.article-page .article-body blockquote p {
  margin-bottom: var(--space-3);
  font-size: var(--text-2xl);
  font-weight: 500;
  line-height: 1.4;
  color: #20344d;
}

.article-page .article-body blockquote cite {
  font-size: var(--text-sm);
  font-style: normal;
  font-weight: 600;
  color: #5c6b7d;
}

/* Key takeaways panel */
.article-page .article-body #key-takeaways {
  margin-top: var(--space-12);
  padding: var(--space-6) var(--space-8);
  border-left: 3px solid var(--accent-secondary);
  border-radius: 0 16px 16px 0;
  background-color: rgba(11, 31, 58, 0.04);
}

.article-page .article-body #key-takeaways h2 {
  margin-top: 0;
  font-size: var(--text-2xl);
}

.article-page .article-body #key-takeaways ul {
  margin-bottom: 0;
}

/* Example box: a short real-world example or use case, set apart from the main text.
   Markup: div.article-example > p.article-example-label ("Retail", "Use Case") + p */
.article-page .article-body .article-example {
  margin: var(--space-6) 0 var(--space-8);
  padding: var(--space-4) var(--space-6);
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 12px;
  background-color: rgba(11, 31, 58, 0.03);
}

.article-page .article-body .article-example-label {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-2);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1.4;
  text-transform: uppercase;
  color: var(--accent-secondary);
}

/* Small red marker before the label */
.article-page .article-body .article-example-label::before {
  content: "";
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 2px;
  background-color: var(--accent-primary-strong);
}

.article-page .article-body .article-example p:not(.article-example-label) {
  margin-bottom: 0;
  font-size: var(--text-base);
}

/* Calculation box: a worked calculation, one step per line, ending in the result.
   Markup: div.article-calc > p.article-calc-label + p.article-calc-formula (optional, the general formula)
           + p.article-calc-step (one per working line) + p.article-calc-result */
.article-page .article-body .article-calc {
  margin: var(--space-6) 0 var(--space-8);
  padding: var(--space-4) var(--space-6);
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-left: 3px solid var(--accent-secondary);
  border-radius: 0 12px 12px 0;
  background-color: var(--bg-surface);
  font-variant-numeric: tabular-nums;
}

.article-page .article-body .article-calc-label {
  margin-bottom: var(--space-3);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1.4;
  text-transform: uppercase;
  color: var(--accent-secondary);
}

.article-page .article-body .article-calc-formula {
  margin-bottom: var(--space-3);
  padding-bottom: var(--space-3);
  border-bottom: 1px dashed var(--border-color);
  font-size: var(--text-sm);
  font-style: italic;
  color: var(--text-muted);
}

.article-page .article-body .article-calc-step {
  margin-bottom: var(--space-1);
  font-size: var(--text-base);
}

.article-page .article-body .article-calc-result {
  margin-top: var(--space-3);
  margin-bottom: 0;
  padding-top: var(--space-3);
  border-top: 1px solid var(--border-color);
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--accent-secondary);
}

/* Execution plan: a panel with a vertical timeline of phases (e.g. "The 30-Day Execution Plan").
   Markup: section.execution-plan > h2 + ol.plan-phases > li.plan-phase > p.plan-phase-days + h3 + p */
.article-page .article-body .execution-plan {
  margin-top: var(--space-12);
  padding: var(--space-8);
  border-top: 3px solid var(--accent-primary-strong);
  border-radius: 0 0 16px 16px;
  background-color: rgba(11, 31, 58, 0.04);
}

.article-page .article-body .execution-plan h2 {
  margin-top: 0;
}

.article-page .article-body .plan-phases {
  --phase-node: 1rem;
  --phase-gap: var(--space-8);
  gap: var(--phase-gap);
  margin: var(--space-6) 0 0;
  padding: 0;
  list-style: none;
}

.article-page .article-body .plan-phase {
  position: relative;
  padding-left: calc(var(--phase-node) + var(--space-6));
}

/* Timeline node */
.article-page .article-body .plan-phase::before {
  content: "";
  position: absolute;
  top: 0.125rem;
  left: 0;
  width: var(--phase-node);
  height: var(--phase-node);
  border: 2px solid var(--accent-secondary);
  border-radius: 50%;
  background-color: #ffffff;
  box-sizing: border-box;
}

/* The final phase is the goal: filled red node */
.article-page .article-body .plan-phase:last-child::before {
  border-color: var(--accent-primary-strong);
  background-color: var(--accent-primary-strong);
  box-shadow: 0 0 0 5px rgba(230, 0, 0, 0.15);
}

/* Connector to the next phase */
.article-page .article-body .plan-phase:not(:last-child)::after {
  content: "";
  position: absolute;
  top: calc(0.125rem + var(--phase-node) + var(--space-1));
  bottom: calc(-1 * var(--phase-gap) + var(--space-1));
  left: calc(var(--phase-node) / 2 - 1px);
  width: 2px;
  background: linear-gradient(to bottom, rgba(11, 31, 58, 0.35), rgba(230, 0, 0, 0.45));
}

.article-page .article-body .plan-phase-days {
  margin-bottom: var(--space-1);
  font-size: var(--text-sm);
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1.4;
  text-transform: uppercase;
  color: var(--accent-primary-strong);
}

.article-page .article-body .plan-phase h3 {
  margin: 0 0 var(--space-2);
}

.article-page .article-body .plan-phase p:last-child {
  margin-bottom: 0;
}

/* Sources */
.article-page .article-footer {
  margin-top: var(--space-12);
  padding-top: var(--space-8);
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}

.article-page .article-sources h2 {
  margin-bottom: var(--space-4);
  font-size: var(--text-xl);
  color: #20344d;
}

.article-page .article-sources ol {
  display: grid;
  gap: var(--space-2);
  padding-left: 1.25rem;
  font-size: var(--text-sm);
  line-height: var(--leading-relaxed);
  color: #5c6b7d;
}

.article-page .article-sources a {
  color: var(--accent-secondary);
  text-underline-offset: 3px;
}

.article-page .article-sources a:hover {
  color: var(--accent-primary-strong);
}

/* Related articles sit below the sources with clear separation */
.article-page #related {
  margin-top: var(--space-16);
}

@media (max-width: 47.99rem) {
  .article-page .article-body h2 {
    font-size: var(--text-2xl);
  }

  .article-page .article-body #key-takeaways {
    padding: var(--space-6);
  }

  .article-page .article-body .execution-plan {
    padding: var(--space-6) var(--space-4);
  }

  .article-page .article-body .article-example {
    padding: var(--space-4);
  }

  .article-page .article-body .article-calc {
    padding: var(--space-4);
  }

  .article-page .article-body blockquote p {
    font-size: var(--text-xl);
  }
}

/* Wide screens: the contents list moves into the right-hand column and
   stays in view while the reader scrolls through the article */
@media (min-width: 64rem) {
  .article-page .article {
    display: grid;
    grid-template-columns: minmax(0, 46rem) minmax(13rem, 16rem);
    grid-template-areas:
      "header header"
      "image  toc"
      "body   toc"
      "footer toc";
    grid-template-rows: auto auto auto 1fr;
    column-gap: var(--space-12);
    max-width: none;
  }

  .article-page .article-header { grid-area: header; }
  .article-page .article-hero-image { grid-area: image; }
  .article-page .article-body { grid-area: body; }
  .article-page .article-footer { grid-area: footer; }

  .article-page .article-toc {
    grid-area: toc;
    align-self: start;
    position: sticky;
    top: var(--space-8);
    margin: 0;
    padding: var(--space-6) var(--space-6) var(--space-6) var(--space-4);
    border: 0;
    border-left: 1px solid rgba(15, 23, 42, 0.1);
    border-radius: 0;
    background: none;
  }

  .article-page .article-toc ol {
    padding-left: 1.25rem;
    font-size: var(--text-sm);
  }
}

.inner-page .page-hero .subtitle a {
  color: var(--accent-secondary);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Products: alternating showcase panels, each linking out to the product's own site */
.inner-page .product-showcase {
  display: grid;
  gap: var(--space-8);
  align-items: center;
  padding-block: var(--space-12);
  scroll-margin-top: var(--space-8);
}

.inner-page .product-showcase + .product-showcase {
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}

.inner-page .product-info h2 {
  margin-bottom: var(--space-2);
  font-size: clamp(2rem, 4vw, 2.75rem);
  letter-spacing: -0.02em;
  color: #20344d;
}

.inner-page .product-tagline {
  margin-bottom: var(--space-4);
  font-size: var(--text-lg);
  font-weight: 600;
  color: var(--accent-secondary);
}

.inner-page .product-info > p:not(.product-tagline):not(.section-eyebrow) {
  max-width: 60ch;
  color: #5b6b7f;
  line-height: var(--leading-relaxed);
}

.inner-page .product-features {
  display: grid;
  gap: var(--space-3);
  margin: var(--space-6) 0;
  padding: 0;
  list-style: none;
}

.inner-page .product-features li {
  position: relative;
  padding-left: var(--space-8);
  color: #5b6b7f;
  line-height: var(--leading-relaxed);
}

.inner-page .product-features li::before {
  content: "";
  position: absolute;
  top: 0.35em;
  left: 0;
  width: 1.1rem;
  height: 1.1rem;
  border-radius: 50%;
  background-color: rgba(230, 0, 0, 0.08);
  box-shadow: inset 0 0 0 1.5px rgba(230, 0, 0, 0.5);
}

.inner-page .product-features li::after {
  content: "";
  position: absolute;
  top: calc(0.35em + 0.4rem);
  left: 0.4rem;
  width: 0.3rem;
  height: 0.3rem;
  border-radius: 50%;
  background-color: var(--accent-primary-strong);
}

/* Per-product bullet colours, matching each product's logo */
.inner-page #dataoil .product-features li::before {
  background-color: rgba(45, 27, 78, 0.08);
  box-shadow: inset 0 0 0 1.5px rgba(45, 27, 78, 0.5);
}

.inner-page #dataoil .product-features li::after {
  background-color: #2d1b4e;
}

.inner-page #mercuryecho .product-features li::before {
  background-color: rgba(106, 131, 181, 0.12);
  box-shadow: inset 0 0 0 1.5px rgba(106, 131, 181, 0.6);
}

.inner-page #mercuryecho .product-features li::after {
  background-color: #6a83b5;
}

.inner-page .product-features strong {
  color: var(--accent-secondary);
}

.inner-page .product-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: var(--space-4);
  margin: 0;
  padding: var(--space-4) var(--space-6);
  border: 1px solid rgba(15, 23, 42, 0.07);
  border-radius: 14px;
  background-color: rgba(255, 255, 255, 0.7);
}

.inner-page .product-meta dt {
  margin-bottom: var(--space-1);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #5c6b7d;
}

.inner-page .product-meta dd {
  margin: 0;
  font-weight: 600;
  color: var(--accent-secondary);
}

.inner-page .product-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  margin-top: var(--space-8);
}

.product-visual {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  aspect-ratio: 4 / 3;
  border-radius: 24px;
  background:
    radial-gradient(ellipse 80% 60% at 80% 10%, rgba(230, 0, 0, 0.22) 0%, transparent 65%),
    radial-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(150deg, var(--accent-secondary) 0%, var(--bg-dark) 100%);
  background-size: auto, 20px 20px, auto;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.08),
    0 30px 60px -30px rgba(11, 31, 58, 0.6);
}

.product-window-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: var(--space-4) var(--space-6);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.product-window-bar span {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.18);
}

.product-window-bar em {
  margin-left: auto;
  font-size: var(--text-xs);
  font-style: normal;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-on-dark-muted);
}

.product-visual svg {
  flex: 1;
  width: 100%;
  padding: var(--space-6);
}

.product-visual .pv-grid line {
  stroke: rgba(255, 255, 255, 0.07);
  stroke-width: 1;
}

.product-visual .pv-bars rect {
  fill: rgba(255, 255, 255, 0.1);
}

.product-visual .pv-rings circle {
  fill: none;
  stroke: rgba(255, 255, 255, 0.1);
  stroke-width: 1.5;
}

.product-visual .pv-line {
  fill: none;
  stroke: var(--accent-primary);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
  filter: drop-shadow(0 0 6px rgba(255, 0, 0, 0.5));
}

.product-visual .pv-dot {
  fill: #fff;
  stroke: var(--accent-primary);
  stroke-width: 3;
}

/* MercuryEcho panel: light theme to match the product's own branding */
.product-visual.product-visual--mercuryecho {
  background:
    radial-gradient(ellipse 80% 60% at 80% 10%, rgba(106, 131, 181, 0.14) 0%, transparent 65%),
    radial-gradient(rgba(11, 31, 58, 0.06) 1px, transparent 1px),
    linear-gradient(150deg, #ffffff 0%, #eef1f6 100%);
  background-size: auto, 20px 20px, auto;
  box-shadow:
    inset 0 0 0 1px rgba(11, 31, 58, 0.08),
    0 30px 60px -30px rgba(106, 131, 181, 0.7);
}

.product-visual--mercuryecho .product-window-bar {
  border-bottom-color: rgba(11, 31, 58, 0.08);
}

.product-visual--mercuryecho .product-window-bar span {
  background-color: rgba(11, 31, 58, 0.15);
}

.product-visual--mercuryecho .product-window-bar em {
  color: #5c6b7d;
}

.product-visual--mercuryecho .pv-rings circle {
  stroke: rgba(11, 31, 58, 0.08);
}

/* DataOil panel: same light theme, tinted with the DataOil purple */
.product-visual.product-visual--dataoil {
  background:
    radial-gradient(ellipse 80% 60% at 80% 10%, rgba(45, 27, 78, 0.1) 0%, transparent 65%),
    radial-gradient(rgba(11, 31, 58, 0.06) 1px, transparent 1px),
    linear-gradient(150deg, #ffffff 0%, #eef1f6 100%);
  background-size: auto, 20px 20px, auto;
  box-shadow:
    inset 0 0 0 1px rgba(11, 31, 58, 0.08),
    0 30px 60px -30px rgba(45, 27, 78, 0.55);
}

.product-visual--dataoil .product-window-bar {
  border-bottom-color: rgba(11, 31, 58, 0.08);
}

.product-visual--dataoil .product-window-bar span {
  background-color: rgba(11, 31, 58, 0.15);
}

.product-visual--dataoil .product-window-bar em {
  color: #5c6b7d;
}

.product-visual--dataoil .pv-grid line {
  stroke: rgba(11, 31, 58, 0.18);
}
@media (min-width: 64rem) {
  .inner-page .product-showcase {
    grid-template-columns: 1.1fr 1fr;
    gap: var(--space-16);
  }

  .inner-page .product-showcase.is-reversed .product-visual {
    order: -1;
  }
}

/* Services: process timeline (vertical on mobile, horizontal from 48rem) */
.inner-page .process-section {
  margin-top: var(--space-16);
  padding-top: var(--space-12);
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}

.inner-page .process-timeline {
  --node-size: 3rem;
  position: relative;
  margin-top: var(--space-12);
}

.inner-page .process-track {
  position: absolute;
  top: calc(var(--node-size) / 2);
  bottom: 0;
  left: calc(var(--node-size) / 2 - 1px);
  width: 2px;
  border-radius: 2px;
  background-color: var(--border-color);
  -webkit-mask-image: linear-gradient(to bottom, #000 85%, transparent);
  mask-image: linear-gradient(to bottom, #000 85%, transparent);
}

.inner-page .process-track-fill {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--fill, 100%);
  border-radius: inherit;
  background: linear-gradient(to bottom, var(--accent-secondary), var(--accent-primary));
  transition: height 0.6s cubic-bezier(0.65, 0, 0.35, 1), width 0.6s cubic-bezier(0.65, 0, 0.35, 1);
}

.inner-page .process-steps {
  display: grid;
  gap: var(--space-8);
  margin: 0;
  padding: 0;
  list-style: none;
}

.inner-page .process-step {
  display: grid;
  grid-template-columns: var(--node-size) 1fr;
  column-gap: var(--space-6);
  align-items: start;
}

.inner-page .process-node {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: var(--node-size);
  height: var(--node-size);
  border: 2px solid var(--accent-secondary);
  border-radius: 50%;
  background-color: var(--bg-surface);
  color: var(--accent-secondary);
  font-size: var(--text-sm);
  font-weight: 700;
  letter-spacing: 0.04em;
  transition: background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}

.inner-page .process-content {
  padding-top: 0.6rem;
  transition: opacity 0.3s ease;
}

.inner-page .process-content h3 {
  margin-bottom: var(--space-2);
  font-size: var(--text-lg);
  color: var(--accent-secondary);
}

.inner-page .process-content p {
  margin: 0;
  color: #5b6b7f;
  line-height: var(--leading-relaxed);
}

.inner-page .process-step.is-pending .process-node {
  border-color: var(--border-color);
  color: var(--text-muted);
}

.inner-page .process-step.is-pending .process-content {
  opacity: 0.5;
}

.inner-page .process-step.is-active .process-node {
  border-color: var(--accent-primary);
  background-color: var(--accent-primary);
  color: #fff;
  box-shadow: 0 0 0 6px rgba(255, 0, 0, 0.12);
  transform: scale(1.06);
}

.inner-page .process-step.is-active .process-node::after {
  content: "";
  position: absolute;
  inset: -2px;
  border: 2px solid var(--accent-primary);
  border-radius: 50%;
  animation: process-pulse 1.8s ease-out infinite;
}

@keyframes process-pulse {
  from { opacity: 0.6; transform: scale(1); }
  to { opacity: 0; transform: scale(1.6); }
}

/* Reveal: only applied once process.js has enhanced the timeline */
.inner-page .process-timeline.is-enhanced .process-step {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s ease;
  transition-delay: calc(var(--i, 0) * 120ms);
}

.inner-page .process-timeline.is-visible .process-step {
  opacity: 1;
  transform: none;
}

@media (min-width: 48rem) {
  .inner-page .process-track {
    top: calc(var(--node-size) / 2 - 1px);
    right: 0;
    bottom: auto;
    left: calc(var(--node-size) / 2);
    width: auto;
    height: 2px;
    -webkit-mask-image: linear-gradient(to right, #000 85%, transparent);
    mask-image: linear-gradient(to right, #000 85%, transparent);
  }

  .inner-page .process-track-fill {
    width: var(--fill, 100%);
    height: 100%;
    background: linear-gradient(to right, var(--accent-secondary), var(--accent-primary));
  }

  .inner-page .process-steps {
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-8);
  }

  .inner-page .process-step {
    grid-template-columns: 1fr;
    row-gap: var(--space-6);
  }

  .inner-page .process-content {
    padding-top: 0;
    padding-right: var(--space-4);
  }
}

/* Contact: the form is the main event; direct details sit below in simple cards */
.inner-page .contact-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-12);
  max-width: 840px;
  margin-inline: auto;
  align-items: start;
}

.inner-page .contact-form {
  position: relative;
  overflow: hidden;
  gap: var(--space-6);
  padding: clamp(1.5rem, 4vw, 2.5rem);
  border: 1px solid rgba(230, 0, 0, 0.14);
  border-radius: 20px;
  background-color: #ffffff;
  box-shadow: 0 24px 60px -36px rgba(15, 23, 42, 0.55);
  scroll-margin-top: var(--space-8);
}

.inner-page .contact-form::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    var(--accent-primary-strong) 50%,
    transparent 100%
  );
}

/* Secondary contact details: one simple card per item */
.inner-page .contact-details {
  padding-top: var(--space-8);
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}

.inner-page .contact-details h2 {
  margin-bottom: var(--space-6);
  font-size: var(--text-xl);
  color: #20344d;
}

.inner-page .contact-details .info-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--space-4);
  margin: 0;
  padding: 0;
  list-style: none;
}

.inner-page .contact-details .info-list li {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  padding: var(--space-6);
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 16px;
  background-color: #ffffff;
  color: #20344d;
}

.inner-page .info-label {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #6b7a8d;
}

.inner-page .contact-details a {
  color: #20344d;
  font-weight: 500;
  transition: color 0.2s ease;
}

.inner-page .contact-details a:hover {
  color: var(--accent-primary-strong);
}

.inner-page .contact-form .section-eyebrow {
  margin-bottom: var(--space-2);
}

.inner-page .form-heading {
  margin-bottom: 0;
}

.inner-page .form-heading h2 {
  margin-bottom: 0;
  font-size: var(--text-2xl);
}

.inner-page .form-group label {
  color: #20344d;
  font-size: var(--text-sm);
}

.inner-page .form-group input,
.inner-page .form-group textarea {
  padding: 0.85rem 1rem;
  border: 1px solid #d8e1ea;
  border-radius: 10px;
  background-color: #f8fafc;
  color: var(--text-main);
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    background-color 0.2s ease;
}

.inner-page .form-group input::placeholder,
.inner-page .form-group textarea::placeholder {
  color: #94a3b8;
}

.inner-page .form-group input:focus,
.inner-page .form-group textarea:focus {
  background-color: #ffffff;
  border-color: var(--accent-primary-strong);
  box-shadow: 0 0 0 4px rgba(230, 0, 0, 0.12);
}

.inner-page .submit-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1rem 1.5rem;
  border-radius: 10px;
  background-color: var(--accent-primary-strong);
  font-size: var(--text-base);
  box-shadow: 0 10px 24px -10px rgba(230, 0, 0, 0.6);
}

.inner-page .submit-btn:hover {
  background-color: var(--accent-hover);
}

.inner-page .form-note {
  margin: 0;
  font-size: var(--text-sm);
  line-height: var(--leading-normal);
  color: #5b6b7f;
}

.inner-page .form-note a {
  color: var(--accent-secondary);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Interior closing CTA: dark, red-glowing panel inside the light sheet */
.inner-page .inner-cta {
  position: relative;
  overflow: hidden;
  margin-top: var(--space-16);
  padding: clamp(2rem, 5vw, 3.5rem);
  border: 1px solid rgba(230, 0, 0, 0.32);
  border-radius: 24px;
  background-color: var(--bg-dark);
  background-image:
    radial-gradient(ellipse at 85% 0%, rgba(255, 0, 0, 0.2) 0%, transparent 60%),
    linear-gradient(150deg, var(--bg-dark-surface) 0%, var(--bg-dark) 70%);
  box-shadow:
    0 28px 60px -34px rgba(0, 0, 0, 0.85),
    inset 0 0 40px rgba(255, 0, 0, 0.04);
}

.inner-page .inner-cta h2 {
  margin-bottom: var(--space-3);
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  color: var(--text-on-dark);
}

.inner-page .inner-cta p {
  max-width: 60ch;
  color: var(--text-on-dark-muted);
  line-height: var(--leading-relaxed);
}

.inner-page .inner-cta .section-eyebrow {
  color: var(--text-on-dark-muted);
}

.inner-page .inner-cta .section-eyebrow::before {
  background-color: var(--accent-primary);
  opacity: 1;
  box-shadow: 0 0 10px rgba(255, 0, 0, 0.6);
}

.inner-page .inner-cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  margin-top: var(--space-6);
}

.inner-page .btn-secondary.btn-on-dark {
  color: var(--text-on-dark);
  border-color: rgba(255, 255, 255, 0.3);
}

.inner-page .btn-secondary.btn-on-dark:hover {
  color: #ffffff;
  background-color: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.55);
  box-shadow: none;
}

/* About page philosophy: heading on the left, copy on the right */
.inner-page .about-philosophy {
  display: grid;
  gap: var(--space-6);
  margin-top: var(--space-16);
  padding-top: var(--space-12);
  border-top: 1px solid rgba(15, 23, 42, 0.1);
}

.inner-page .about-philosophy h2 {
  margin: 0;
  font-size: clamp(1.75rem, 3.5vw, 2.25rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: #20344d;
}

.inner-page .about-philosophy-copy {
  display: grid;
  gap: var(--space-4);
  max-width: 65ch;
}

.inner-page .about-philosophy-copy p {
  margin: 0;
  line-height: var(--leading-relaxed);
  color: #5b6b7f;
}

.inner-page .about-philosophy-copy p:first-child {
  font-size: var(--text-lg);
  color: #3f4f63;
}

@media (min-width: 56rem) {
  .inner-page .about-philosophy {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr);
    gap: var(--space-12);
  }

  .inner-page .about-philosophy-heading {
    position: sticky;
    top: var(--space-8);
    align-self: start;
  }
}

@media (max-width: 47.99rem) {
  .inner-page .about-philosophy {
    margin-top: var(--space-12);
    padding-top: var(--space-8);
  }
}

/* About page pillars: light and open, no cards. On desktop the four pillars
   sit in a row on one shared hairline, each anchored by a ringed line icon;
   a red pulse travels along the line. Below 64rem they stack in a 2-up grid,
   then a single column, each with its own hairline. */
.inner-page .about-pillars {
  margin-top: clamp(var(--space-16), 9vw, 8rem);
  padding-top: clamp(var(--space-12), 6vw, var(--space-24));
  padding-bottom: var(--space-8);
  border-top: 1px solid rgba(15, 23, 42, 0.1);
}

.inner-page .about-pillars-heading {
  margin-bottom: clamp(var(--space-12), 5vw, var(--space-16));
}

.inner-page .about-pillars h2 {
  margin: 0;
  font-size: clamp(1.75rem, 3.5vw, 2.25rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: #20344d;
}

.inner-page .pillar-grid {
  --pillar-icon: 3.5rem;
  --pillar-gap: var(--space-8);
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-12) var(--pillar-gap);
  margin: 0;
  padding: 0;
  list-style: none;
}

.inner-page .pillar {
  position: relative;
}

/* Shared hairline running through the middle of the icons */
.inner-page .pillar::before {
  content: "";
  position: absolute;
  top: calc(var(--pillar-icon) / 2);
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.14), rgba(15, 23, 42, 0.04));
}

/* Red pulse that travels along each segment of the line */
.inner-page .pillar::after {
  content: "";
  position: absolute;
  top: calc(var(--pillar-icon) / 2 - 1px);
  left: var(--pillar-icon);
  width: 48px;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, var(--accent-primary), transparent);
  box-shadow: 0 0 10px rgba(255, 0, 0, 0.45);
  opacity: 0;
  animation: pillar-pulse 4.8s ease-in-out infinite;
}

.inner-page .pillar:nth-child(2)::after { animation-delay: 1.2s; }
.inner-page .pillar:nth-child(3)::after { animation-delay: 2.4s; }
.inner-page .pillar:nth-child(4)::after { animation-delay: 3.6s; }

@keyframes pillar-pulse {
  0%   { opacity: 0; transform: translateX(0); }
  10%  { opacity: 1; }
  25%  { opacity: 0; transform: translateX(160px); }
  100% { opacity: 0; transform: translateX(160px); }
}

.inner-page .pillar-top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-6);
}

/* Ringed line icon: white disc sitting on the line, red stroke, soft glow */
.inner-page .pillar-icon {
  display: grid;
  place-items: center;
  width: var(--pillar-icon);
  height: var(--pillar-icon);
  border-radius: 50%;
  background-color: #ffffff;
  border: 1px solid rgba(230, 0, 0, 0.28);
  box-shadow:
    0 0 0 6px #f5f7fa,
    0 10px 24px -10px rgba(230, 0, 0, 0.45);
  color: var(--accent-primary-strong);
  transition: background-color 0.25s ease, color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

.inner-page .pillar-icon svg {
  width: 1.6rem;
  height: 1.6rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Small number sitting on the line at the right, on a matching backing */
.inner-page .pillar-number {
  padding-left: var(--space-3);
  background-color: #f5f7fa;
  font-size: var(--text-sm);
  font-weight: 700;
  letter-spacing: 0.12em;
  color: #9aa6b4;
  font-variant-numeric: tabular-nums;
  transition: color 0.25s ease;
}

.inner-page .pillar h3 {
  margin: 0 0 var(--space-3);
  font-size: var(--text-xl);
  line-height: 1.25;
  letter-spacing: -0.01em;
  color: #20344d;
}

.inner-page .pillar p {
  margin: 0;
  max-width: 40ch;
  line-height: var(--leading-relaxed);
  color: #5b6b7f;
}

/* Hover: the icon fills red and lifts, the number picks up the accent */
.inner-page .pillar:hover .pillar-icon {
  background-color: var(--accent-primary-strong);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow:
    0 0 0 6px #f5f7fa,
    0 14px 30px -10px rgba(230, 0, 0, 0.6);
}

.inner-page .pillar:hover .pillar-number {
  color: var(--accent-primary-strong);
}

@media (min-width: 48rem) {
  .inner-page .pillar-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Desktop: one row, the line runs unbroken through all four pillars */
@media (min-width: 64rem) {
  .inner-page .pillar-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .inner-page .pillar:not(:last-child)::before {
    right: calc(-1 * var(--pillar-gap));
    background: rgba(15, 23, 42, 0.14);
  }

  .inner-page .pillar:last-child::before {
    background: linear-gradient(90deg, rgba(15, 23, 42, 0.14), transparent);
  }
}

@media (max-width: 47.99rem) {
  .inner-page .about-pillars {
    margin-top: var(--space-12);
    padding-top: var(--space-8);
  }

  .inner-page .about-pillars-heading {
    margin-bottom: var(--space-8);
  }

  .inner-page .pillar-grid {
    gap: var(--space-8);
  }
}

@media (prefers-reduced-motion: reduce) {
  .inner-page .pillar::after {
    animation: none;
  }

  .inner-page .pillar-icon,
  .inner-page .pillar-number {
    transition: none;
  }

  .inner-page .pillar:hover .pillar-icon {
    transform: none;
  }
}

/* About page CTA: light and open, no panel. A plain hairline divider
   with the copy and actions left aligned beneath it */
.inner-page.about-page .inner-cta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  margin-top: var(--space-16);
  padding: var(--space-12) 0 0;
  border: 0;
  border-top: 1px solid rgba(15, 23, 42, 0.1);
  border-radius: 0;
  background: none;
  box-shadow: none;
  overflow: visible;
  text-align: left;
}

.inner-page.about-page .inner-cta h2 {
  max-width: 22ch;
  color: #20344d;
  letter-spacing: -0.02em;
}

.inner-page.about-page .inner-cta p {
  max-width: 55ch;
  color: #5b6b7f;
}

.inner-page.about-page .inner-cta .section-eyebrow {
  color: #5c6b7d;
}

.inner-page.about-page .inner-cta .section-eyebrow::before {
  background-color: var(--accent-primary-strong);
  opacity: 0.75;
  box-shadow: none;
}

.inner-page.about-page .inner-cta-actions {
  justify-content: flex-start;
  margin-top: var(--space-6);
}

@media (max-width: 47.99rem) {
  .inner-page.about-page .inner-cta {
    margin-top: var(--space-12);
    padding: var(--space-8) 0 0;
  }
}

.inner-page .card-link:focus-visible,
.inner-page .info-list a:focus-visible,
.inner-page .form-note a:focus-visible {
  outline: 2px solid var(--accent-primary-strong);
  outline-offset: 3px;
  border-radius: 4px;
}

/* Let the dark footer meet the dark canvas without a light gap */
.inner-page #footer-placeholder .site-footer {
  margin-top: 0;
}

/* Interior page CTA outside the light sheet (about.html): no box, type set on
   the dark canvas with a red glow, fading dot texture and a red hairline on
   top, matching the home page's closing CTA. */
.inner-page .page-cta {
  position: relative;
  overflow: hidden;
  padding: clamp(var(--space-16), 9vw, 8rem) var(--container-padding);
  background:
    radial-gradient(ellipse 70% 65% at 50% 100%, rgba(255, 0, 0, 0.16) 0%, transparent 70%),
    var(--bg-dark);
}

.inner-page .page-cta::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(255, 255, 255, 0.07) 1px, transparent 1.5px);
  background-size: 22px 22px;
  -webkit-mask-image: radial-gradient(ellipse 60% 70% at 50% 55%, #000 0%, transparent 75%);
  mask-image: radial-gradient(ellipse 60% 70% at 50% 55%, #000 0%, transparent 75%);
  pointer-events: none;
}

.inner-page .page-cta::after {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: min(60%, 520px);
  height: 1px;
  transform: translateX(-50%);
  background: linear-gradient(90deg, transparent, rgba(255, 0, 0, 0.7), transparent);
  box-shadow: 0 0 12px rgba(255, 0, 0, 0.5);
}

.inner-page .page-cta-inner {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: var(--container-max);
  margin: 0 auto;
  text-align: center;
}

.inner-page .page-cta h2 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 3.75rem);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.03em;
  color: var(--text-on-dark);
  text-wrap: balance;
}

/* Eyebrow above the heading, lit for the dark canvas */
.inner-page .page-cta .section-eyebrow {
  margin: 0 0 var(--space-6);
  font-size: 0.75rem;
  color: var(--text-on-dark-muted);
}

.inner-page .page-cta .section-eyebrow::before {
  background-color: var(--accent-primary);
  opacity: 1;
  box-shadow: 0 0 10px rgba(255, 0, 0, 0.6);
}

.inner-page .page-cta-highlight {
  color: var(--accent-primary);
  text-shadow: 0 0 32px rgba(255, 0, 0, 0.45);
}

.inner-page .page-cta p {
  max-width: 46ch;
  margin: var(--space-8) 0 0;
  font-size: clamp(var(--text-lg), 2vw, var(--text-xl));
  line-height: var(--leading-normal);
  color: var(--text-on-dark-muted);
}

.inner-page .page-cta-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-4);
  margin-top: var(--space-12);
}

.inner-page .page-cta .btn-primary,
.inner-page .page-cta .btn-secondary {
  padding: 1.1rem 2.25rem;
  font-size: var(--text-lg);
  border-radius: 4px;
}

.inner-page .page-cta .btn-primary {
  box-shadow: 0 10px 28px -6px rgba(255, 0, 0, 0.45);
}

.inner-page .page-cta .btn-primary:hover {
  box-shadow: 0 14px 34px -6px rgba(255, 0, 0, 0.55);
}

.inner-page .page-cta .btn-primary svg {
  width: 1.25rem;
  height: 1.25rem;
  transition: transform 0.2s ease;
}

.inner-page .page-cta .btn-primary:hover svg {
  transform: translateX(4px);
}

/* Secondary button: quiet outline on dark so the red action leads */
.inner-page .page-cta .btn-secondary {
  color: var(--text-on-dark);
  border-color: rgba(255, 255, 255, 0.3);
}

.inner-page .page-cta .btn-secondary:hover {
  color: #ffffff;
  background-color: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.55);
  box-shadow: none;
}

.inner-page .page-cta .btn-primary:focus-visible,
.inner-page .page-cta .btn-secondary:focus-visible {
  outline-color: #ffffff;
}

/* Quiet variant (products.html): for supporting pages. Same dark canvas, but
   no glow, dots or oversized type: a compact strip with copy on the left and a
   standard button on the right, set off by a plain hairline. */
.inner-page .page-cta--quiet {
  margin-top: var(--space-8);
  padding: clamp(var(--space-16), 7vw, var(--space-24)) var(--container-padding) clamp(var(--space-16), 8vw, 7rem);
  background: var(--bg-dark);
}

.inner-page .page-cta--quiet::before {
  display: none;
}

/* Hairline spans the content width instead of glowing in the centre */
.inner-page .page-cta--quiet::after {
  width: min(calc(100% - 2 * var(--container-padding)), 1180px);
  background: var(--border-dark);
  box-shadow: none;
}

.inner-page .page-cta--quiet .page-cta-inner {
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  gap: var(--space-2) var(--space-12);
  max-width: 1180px;
  padding-top: var(--space-4);
  text-align: left;
}

.inner-page .page-cta--quiet .section-eyebrow {
  margin-bottom: var(--space-2);
}

.inner-page .page-cta--quiet .section-eyebrow::before {
  box-shadow: none;
}

.inner-page .page-cta--quiet h2 {
  font-size: clamp(1.5rem, 2.5vw, 1.875rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.inner-page .page-cta--quiet p {
  max-width: 60ch;
  margin-top: var(--space-2);
  font-size: var(--text-base);
}

.inner-page .page-cta--quiet .page-cta-actions {
  justify-content: flex-start;
  margin-top: var(--space-6);
}

.inner-page .page-cta--quiet .btn-primary {
  padding: 0.95rem 1.75rem;
  font-size: var(--text-base);
  box-shadow: 0 4px 14px rgba(255, 0, 0, 0.25);
}

.inner-page .page-cta--quiet .btn-primary svg {
  width: 1.1rem;
  height: 1.1rem;
}

/* Desktop: copy on the left, button on the right in its own column */
@media (min-width: 56rem) {
  .inner-page .page-cta--quiet .page-cta-inner {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .inner-page .page-cta--quiet .page-cta-inner > :not(.page-cta-actions) {
    grid-column: 1;
  }

  .inner-page .page-cta--quiet .page-cta-actions {
    grid-column: 2;
    grid-row: 1 / span 3;
    margin-top: 0;
  }
}

@media (max-width: 47.99rem) {
  .inner-page .page-cta {
    padding-top: var(--space-16);
    padding-bottom: var(--space-16);
  }

  .inner-page .page-cta--quiet {
    padding-top: var(--space-12);
    padding-bottom: var(--space-16);
  }

  .inner-page .page-cta-actions {
    flex-direction: column;
    align-self: stretch;
    margin-top: var(--space-8);
  }
}

@media (prefers-reduced-motion: reduce) {
  .inner-page .page-cta .btn-primary svg {
    transition: none;
  }

  .inner-page .page-cta .btn-primary:hover svg {
    transform: none;
  }
}

/* =================================================================
   DEVICE RESPONSIVENESS (Media Queries - Mobile First)
   ================================================================ */

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

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

  h1 {
    font-size: var(--text-5xl);
  }
}

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

  .card-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Mobile navigation: below the 48rem desktop breakpoint the links
   collapse behind the hamburger toggle and drop down when opened. */
@media (max-width: 47.99rem) {
  .site-header {
    --nav-height: 4.25rem; /* 68px: 12px padding x2 + 44px toggle */
  }

  .navbar {
    grid-template-columns: 1fr auto auto;
    gap: var(--space-3);
    padding: 0.75rem 1.25rem;
  }

  .logo img {
    height: 34px;
  }

  /* Contact stays visible beside the hamburger instead of hiding in the menu */
  .nav-cta {
    grid-column: 2;
    min-height: 44px;
    padding: 0 1rem;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 50;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: var(--space-2) 0;
    background-color: var(--bg-surface, #ffffff);
    border-bottom: 1px solid var(--border-color, #e5e5e5);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  }

  .nav-links.is-open {
    display: flex;
  }

  .nav-links li {
    width: 100%;
  }

  .nav-links a {
    display: block;
    padding: var(--space-3) var(--space-6);
    border-radius: 0;
  }

  .nav-links a::after {
    display: none;
  }

  .nav-links a:hover {
    background-color: #f1f5f9;
  }

  .nav-links a.active {
    background-color: #fff1f1;
    box-shadow: inset 3px 0 0 var(--accent-primary-strong, #e60000);
  }
}

/* Home panels: tighter gutters and padding on small screens */
@media (max-width: 47.99rem) {
  .home .hero-section > .wrap {
    width: calc(100% - 2rem);
    padding: var(--space-12) var(--container-padding);
    margin-block: var(--space-4);
    border-radius: 18px;
  }

  .home .featured-section {
    border-radius: 24px;
    padding-top: var(--space-12);
    padding-bottom: var(--space-12);
    margin-block: var(--space-8);
  }

  .home .featured-section .article-card--featured {
    min-height: 0;
    padding: var(--space-8) var(--space-6) var(--space-6);
  }

  .home .featured-card-image {
    --fc-pad-top: var(--space-8);
    --fc-pad-x: var(--space-6);
  }

  .home .featured-section .article-card:not(.article-card--featured) {
    padding: var(--space-6) var(--space-4) var(--space-6) var(--space-6);
  }

  .home .about-panel {
    padding: var(--space-8) var(--space-6);
  }

  .home .cta-section {
    padding-top: var(--space-16);
    padding-bottom: var(--space-16);
  }

  .home .cta-subline {
    margin-top: var(--space-8);
  }

  .home .cta-button {
    width: 100%;
  }

  .home .hero-section {
    padding-top: var(--space-8);
    padding-bottom: var(--space-8);
  }

  /* Interior pages: tighter sheet gutters and stacked content */
  .inner-page .page-container {
    width: calc(100% - 2rem);
    margin-block: var(--space-8);
    padding: var(--space-12) var(--container-padding);
    border-radius: 24px;
  }

  .inner-page .page-hero,
  .inner-page .about-hero {
    margin-bottom: var(--space-8);
    padding-bottom: var(--space-6);
  }

  .inner-page .contact-layout {
    grid-template-columns: 1fr;
    gap: var(--space-8);
  }

  .inner-page .service-card {
    padding: var(--space-6);
  }

  .inner-page .contact-form {
    padding: var(--space-6);
  }

  .inner-page .contact-details {
    padding-top: var(--space-6);
  }

  .inner-page .process-section,
  .inner-page .inner-cta {
    margin-top: var(--space-12);
  }

  .inner-page .inner-cta {
    padding: var(--space-8);
    border-radius: 20px;
  }
}

/* Respect users who prefer reduced motion */
@media (prefers-reduced-motion: reduce) {
  .btn-primary,
  .btn-secondary,
  .btn-nav,
  .nav-links a,
  .logo,
  .nav-toggle-bar,
  .home .topic-hub-section .card,
  .home .topic-carousel-btn,
  .home .pain-point::before,
  .home .featured-section .article-card,
  .home .featured-section .article-card--featured,
  .home .featured-section .article-card:not(.article-card--featured),
  .home .featured-section .article-card:not(.article-card--featured)::before,
  .home .section-link,
  .home .featured-section .section-link,
  .home .cta-button svg,
  .inner-page .service-card,
  .inner-page .card-btn {
    transition: none;
  }

  .btn-primary:hover,
  .btn-secondary:hover,
  .btn-nav:hover,
  .home .topic-hub-section .card:hover,
  .home .featured-section .article-card:hover,
  .home .cta-button:hover svg {
    transform: none;
  }

  .inner-page .service-card:hover {
    transform: none;
  }

  .inner-page .process-node,
  .inner-page .process-content,
  .inner-page .process-track-fill,
  .inner-page .process-timeline.is-enhanced .process-step {
    transition: none;
  }

  .inner-page .process-timeline.is-enhanced .process-step {
    opacity: 1;
    transform: none;
  }

  .inner-page .process-step.is-active .process-node::after,
  .product-visual .pv-flow path,
  .rotating-word-text,
  .hero-book .hb-float,
  .hero-book .hb-rotor,
  .hero-book .hb-glow {
    animation: none;
  }

  .hero-book .hb-sparks circle {
    animation: none;
    opacity: 0.6;
  }
}

