/* Base Layout & Look-Agnostic Component Styles
   All colors, shadows, radii, fonts, borders, and spacing come from theme tokens. */

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

html {
  width: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: var(--leading-body);
  color: var(--text-soft);
  background-color: var(--canvas);
  background-image: var(--canvas-bg);
  background-size: var(--canvas-bg-size);
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}

body.is-nav-open {
  overflow: hidden;
}

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

img {
  height: auto;
}

h1, h2, h3, h4 {
  margin: 0 0 var(--space-3);
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  line-height: var(--leading-tight);
  letter-spacing: var(--tracking-tight);
  text-shadow: var(--text-shadow-chisel);
}

h1 { font-size: var(--text-3xl); }
h2 { font-size: var(--text-2xl); }
h3 { font-size: var(--text-xl); line-height: var(--leading-snug); }
h4 { font-size: var(--text-lg); line-height: var(--leading-snug); }

p {
  margin: 0 0 var(--space-4);
}

p:last-child {
  margin-bottom: 0;
}

a {
  color: var(--text-accent);
  text-underline-offset: 0.2em;
}

a:hover {
  color: var(--text);
}

:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

/* Skip link */
.skip-link {
  position: fixed;
  left: -9999px;
  top: var(--space-3);
  z-index: 200;
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-pill);
  background: var(--surface-pill);
  color: var(--text);
  font-weight: 700;
  text-decoration: none;
  box-shadow: var(--shadow-btn);
}

.skip-link:focus {
  left: var(--space-3);
}

/* Trap & accessibility helpers */
.sr-trap {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.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;
}

/* Containers & Sections */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding-inline: var(--space-4);
}

@media (min-width: 40rem) {
  .container {
    padding-inline: var(--space-5);
  }
}

.section {
  padding-block: var(--space-6);
}

@media (min-width: 48rem) {
  .section {
    padding-block: var(--space-8);
  }
}

main {
  padding-bottom: var(--space-7);
}

/* Surface Primitives */
.slab {
  background: var(--surface-slab);
  border-radius: var(--radius-slab);
  border-top: 2px solid var(--border-light);
  border-left: 2px solid var(--border-light);
  border-bottom: 2px solid var(--border-strong);
  border-right: 2px solid var(--border-strong);
  box-shadow: var(--shadow-slab);
  backdrop-filter: blur(var(--blur-glass));
  -webkit-backdrop-filter: blur(var(--blur-glass));
  padding: var(--space-5);
}

@media (min-width: 48rem) {
  .slab {
    padding: var(--space-7);
  }
}

.well {
  background: var(--surface-well);
  border-radius: var(--radius-well);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-pressed);
  padding: var(--space-4);
}

.plate {
  background: var(--surface-plate);
  border-radius: var(--radius-plate);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-plate);
  padding: var(--space-5);
}

/* =========================================================================
   1. SITE HEADER & NAVIGATION
   ========================================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  padding-block: var(--space-3);
}

.header-dock {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-pill);
  background: var(--surface-raised);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-dock);
}

@media (min-width: 64rem) {
  .header-dock {
    padding: var(--space-2) var(--space-4);
  }
}

.site-brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  min-height: 2.75rem;
  padding-inline: var(--space-2);
  border-radius: var(--radius-pill);
  text-decoration: none;
  color: var(--text);
  font-weight: 700;
  font-size: var(--text-sm);
  letter-spacing: var(--tracking-tight);
  white-space: nowrap;
  flex-shrink: 0;
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border-radius: var(--radius-pill);
  background: var(--accent-gradient);
  color: var(--text-on-accent);
  font-size: var(--text-xs);
  font-weight: 700;
  box-shadow: var(--shadow-disc);
}

.nav-desktop {
  display: none;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-shrink: 0;
}

.site-header .header-cta {
  display: none;
}

@media (min-width: 64rem) {
  .nav-desktop {
    display: block;
  }

  .site-header .header-cta {
    display: inline-flex;
  }

  .mobile-nav {
    display: none;
  }
}

.nav-list {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-item {
  position: relative;
}

.nav-link,
.nav-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-1);
  min-height: 2.75rem;
  padding: 0 var(--space-4);
  border-radius: var(--radius-pill);
  background: var(--surface-pill);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-btn);
  color: var(--text);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  list-style: none;
  transition: transform var(--duration-fast) var(--ease-spring), box-shadow var(--duration-fast) ease, color var(--duration-fast) ease;
}

.nav-trigger::-webkit-details-marker {
  display: none;
}

.nav-link:hover,
.nav-trigger:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-btn-hover);
  color: var(--text-accent);
}

.nav-link[aria-current="page"],
.nav-dropdown[open] > .nav-trigger,
.nav-dropdown[data-active="true"] > .nav-trigger {
  background: var(--surface-pill-active);
  box-shadow: var(--shadow-btn-active);
  color: var(--text-accent);
}

.nav-chevron {
  transition: transform var(--duration-fast) ease;
}

.nav-dropdown[open] .nav-chevron {
  transform: rotate(180deg);
}

.nav-menu {
  position: absolute;
  top: calc(100% + var(--space-2));
  left: 0;
  min-width: 15.5rem;
  margin: 0;
  padding: var(--space-2);
  list-style: none;
  border-radius: var(--radius-card);
  background: var(--surface-dropdown);
  border: 1px solid var(--border-dropdown);
  box-shadow: var(--shadow-dropdown);
  z-index: 80;
}

.nav-menu-link {
  display: flex;
  align-items: center;
  min-height: 2.75rem;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-input);
  color: var(--text);
  font-size: var(--text-sm);
  font-weight: 400;
  text-decoration: none;
  transition: background-color var(--duration-fast) ease, color var(--duration-fast) ease;
}

.nav-menu-overview {
  font-weight: 700;
  border-bottom: 1px solid var(--border-subtle);
  border-radius: var(--radius-input) var(--radius-input) 0 0;
  margin-bottom: var(--space-1);
}

.nav-menu-link:hover,
.nav-menu-link[aria-current="page"] {
  background: var(--surface-accent-soft);
  color: var(--text-accent);
}

/* Mobile Menu (pure CSS <details> fallback + JS focus trap & Escape) */
.mobile-nav-toggle {
  position: relative;
  z-index: 120;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.75rem;
  min-height: 2.75rem;
  border-radius: var(--radius-pill);
  background: var(--surface-pill);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-btn);
  color: var(--text);
  cursor: pointer;
  list-style: none;
}

.mobile-nav-toggle::-webkit-details-marker {
  display: none;
}

.mobile-nav-toggle .icon-close {
  display: none;
}

.mobile-nav[open] .mobile-nav-toggle .icon-menu {
  display: none;
}

.mobile-nav[open] .mobile-nav-toggle .icon-close {
  display: block;
}

.mobile-nav-panel {
  display: none;
}

.mobile-nav[open] .mobile-nav-panel {
  display: flex;
  flex-direction: column;
  position: fixed;
  inset: 0;
  z-index: 100;
  background: var(--surface-overlay);
  backdrop-filter: blur(var(--blur-overlay));
  -webkit-backdrop-filter: blur(var(--blur-overlay));
  overflow-y: auto;
  padding: var(--space-4);
}

.mobile-nav-inner {
  width: 100%;
  max-width: 32rem;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
  padding-bottom: var(--space-6);
}

.mobile-nav-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 2.75rem;
  padding-right: 3.5rem;
}

.mobile-nav-title {
  font-weight: 700;
  font-size: var(--text-lg);
  color: var(--text);
}

html:not(.js-ready) .mobile-nav-close {
  display: none;
}

.mobile-nav-body {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.mobile-nav-group {
  background: var(--surface-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-raised);
  padding: var(--space-4);
}

.mobile-nav-heading {
  margin: 0 0 var(--space-2);
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-accent);
}

.mobile-nav-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  list-style: none;
  margin: 0;
  padding: 0;
}

.mobile-nav-link {
  display: flex;
  align-items: center;
  min-height: 2.75rem;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-input);
  color: var(--text);
  font-weight: 700;
  font-size: var(--text-base);
  text-decoration: none;
}

.mobile-nav-link:hover,
.mobile-nav-link[aria-current="page"] {
  background: var(--surface-accent-soft);
  color: var(--text-accent);
}

.mobile-nav-foot {
  padding-top: var(--space-2);
}

/* =========================================================================
   2. SITE FOOTER
   ========================================================================= */
.site-footer {
  padding-block: var(--space-6) var(--space-7);
}

.footer-slab {
  background: var(--surface-slab);
  border-radius: var(--radius-slab);
  border-top: 2px solid var(--border-light);
  border-left: 2px solid var(--border-light);
  border-bottom: 2px solid var(--border-strong);
  border-right: 2px solid var(--border-strong);
  box-shadow: var(--shadow-slab);
  padding: var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
}

@media (min-width: 48rem) {
  .footer-slab {
    padding: var(--space-7);
  }
}

.footer-top {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  padding-bottom: var(--space-5);
  border-bottom: 1px solid var(--border-subtle);
}

@media (min-width: 48rem) {
  .footer-top {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.footer-brand-block {
  max-width: 28rem;
}

.footer-tagline {
  margin-top: var(--space-2);
  font-size: var(--text-sm);
  color: var(--text-muted);
}

.footer-cta-box {
  background: var(--surface-well);
  border-radius: var(--radius-well);
  box-shadow: var(--shadow-pressed);
  border: 1px solid var(--border-subtle);
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-3);
}

.footer-cta-title {
  margin: 0;
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--text);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-5);
}

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

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

.footer-col-title {
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-accent);
  margin: 0 0 var(--space-3);
}

.footer-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.footer-link {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  font-size: var(--text-sm);
  color: var(--text-soft);
  text-decoration: none;
}

@media (min-width: 64rem) {
  .footer-link {
    min-height: 2.25rem;
  }
}

.footer-link:hover {
  color: var(--text-accent);
  text-decoration: underline;
}

.footer-bottom {
  padding-top: var(--space-4);
  border-top: 1px solid var(--border-subtle);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--space-3);
}

.footer-copy {
  font-size: var(--text-sm);
  color: var(--text-muted);
}

/* =========================================================================
   3. BREADCRUMB
   ========================================================================= */
.breadcrumb {
  margin-bottom: var(--space-4);
}

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

.breadcrumb-item {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
}

.breadcrumb-item a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  color: var(--text-accent);
  text-decoration: none;
  font-weight: 700;
}

.breadcrumb-item a:hover {
  text-decoration: underline;
}

.breadcrumb-sep {
  color: var(--text-muted);
}

/* =========================================================================
   4. HERO & INNER PAGE HERO
   ========================================================================= */
.hero {
  padding-block: var(--space-4) var(--space-6);
}

.hero-slab {
  background: var(--surface-slab);
  border-radius: var(--radius-slab);
  border-top: 2px solid var(--border-light);
  border-left: 2px solid var(--border-light);
  border-bottom: 2px solid var(--border-strong);
  border-right: 2px solid var(--border-strong);
  box-shadow: var(--shadow-slab);
  padding: var(--space-5);
}

@media (min-width: 48rem) {
  .hero-slab {
    padding: var(--space-7);
  }
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
  align-items: center;
}

@media (min-width: 64rem) {
  .hero-grid {
    grid-template-columns: 1.05fr 0.95fr;
    gap: var(--space-7);
  }
}

.hero-body {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-5);
  min-width: 0;
}

.hero-plate {
  width: 100%;
  background: var(--surface-plate);
  border-radius: var(--radius-plate);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-plate);
  padding: var(--space-5);
}

@media (min-width: 48rem) {
  .hero-plate {
    padding: var(--space-6);
  }
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  margin: 0 0 var(--space-3);
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-accent);
}

.eyebrow::before {
  content: "";
  width: 0.5rem;
  height: 0.5rem;
  border-radius: var(--radius-pill);
  background: var(--accent);
  box-shadow: var(--shadow-status-glow);
}

.hero-title {
  margin-bottom: var(--space-4);
}

.hero-lead {
  font-size: var(--text-lg);
  color: var(--text-soft);
  margin: 0;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  width: 100%;
}

.hero-media {
  min-width: 0;
  width: 100%;
}

.media-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  border-radius: var(--radius-well);
  background: var(--surface-well);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-pressed);
  padding: var(--space-3);
  overflow: hidden;
}

@media (min-width: 64rem) {
  .media-frame {
    aspect-ratio: 16 / 9;
  }
}

.media-inner {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: calc(var(--radius-well) - var(--space-2));
  overflow: hidden;
}

.media-poster,
.media-video,
.media-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}

.media-video {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity var(--duration-base) ease;
}

.media-frame.is-playing .media-video {
  opacity: 1;
}

/* Smaller Page Hero for inner pages */
.page-hero {
  padding-block: var(--space-4) var(--space-5);
}

.page-hero-slab {
  background: var(--surface-slab);
  border-radius: var(--radius-slab);
  border-top: 2px solid var(--border-light);
  border-left: 2px solid var(--border-light);
  border-bottom: 2px solid var(--border-strong);
  border-right: 2px solid var(--border-strong);
  box-shadow: var(--shadow-slab);
  padding: var(--space-5);
}

@media (min-width: 48rem) {
  .page-hero-slab {
    padding: var(--space-6) var(--space-7);
  }
}

.page-hero-slab .hero-lead {
  max-width: var(--measure);
  margin-bottom: var(--space-4);
}

/* =========================================================================
   5. SECTION HEADING BLOCK
   ========================================================================= */
.section-head {
  margin-bottom: var(--space-6);
  max-width: var(--measure);
}

.section-head-center {
  margin-inline: auto;
  text-align: center;
}

.section-head-center .eyebrow {
  justify-content: center;
}

.section-head-card {
  background: var(--surface-heading);
  border-radius: var(--radius-card);
  border-top: 2px solid var(--border-light);
  border-left: 2px solid var(--border-light);
  border-bottom: 2px solid var(--border-strong);
  border-right: 2px solid var(--border-strong);
  box-shadow: var(--shadow-raised);
  padding: var(--space-5) var(--space-6);
  margin-bottom: var(--space-6);
}

.section-title {
  margin-bottom: var(--space-3);
}

.section-lead {
  font-size: var(--text-lg);
  color: var(--text-soft);
  margin: 0;
}

/* =========================================================================
   6. BUTTONS, PILLS & CHIPS
   ========================================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: 2.875rem;
  padding: var(--space-3) var(--space-5);
  border-radius: var(--radius-pill);
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform var(--duration-fast) var(--ease-spring), box-shadow var(--duration-fast) ease, background-color var(--duration-fast) ease;
}

.btn-primary {
  background: var(--accent-gradient);
  color: var(--text-on-accent);
  box-shadow: var(--shadow-cta);
}

.btn-primary:hover {
  color: var(--text-on-accent);
  transform: translateY(-2px);
  box-shadow: var(--shadow-cta-hover);
}

.btn-primary:active {
  transform: translateY(1px);
}

.btn-secondary {
  background: var(--surface-pill);
  color: var(--text);
  border-color: var(--border-light);
  box-shadow: var(--shadow-btn);
}

.btn-secondary:hover {
  color: var(--text-accent);
  transform: translateY(-1px);
  box-shadow: var(--shadow-btn-hover);
}

.btn-secondary:active {
  transform: translateY(1px);
  box-shadow: var(--shadow-btn-active);
}

.btn-quiet {
  background: var(--surface-well);
  color: var(--text);
  border-color: var(--border-subtle);
  box-shadow: var(--shadow-input);
}

.btn-quiet:hover {
  color: var(--text-accent);
  border-color: var(--border-accent);
}

.btn-sm {
  min-height: 2.75rem;
  padding: var(--space-2) var(--space-4);
  font-size: var(--text-sm);
}

.btn-block {
  width: 100%;
}

.btn[disabled] {
  opacity: 0.65;
  cursor: not-allowed;
  transform: none;
}

/* Pills & Tool Chips */
.pill {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-pill);
  background: var(--surface-disc);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-disc);
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--text);
}

.pill-accent {
  background: var(--surface-accent-soft);
  color: var(--text-accent);
  border-color: var(--border-accent);
}

.chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  list-style: none;
  margin: 0;
  padding: 0;
}

.chip {
  display: inline-flex;
  align-items: center;
  min-height: 2.25rem;
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-pill);
  background: var(--surface-well);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-input);
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--text);
}

/* =========================================================================
   7. CARDS & GRIDS
   ========================================================================= */
.grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-5);
}

.grid + h3,
.do-dont + h3,
.card + h3 {
  margin-top: var(--space-6);
}

.do-dont {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-5);
  margin-block: var(--space-6);
}

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

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

  .grid-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.card {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  min-width: 0;
  background: var(--surface-card);
  border-radius: var(--radius-card);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-raised);
  padding: var(--space-5);
  transition: transform var(--duration-fast) var(--ease-spring), box-shadow var(--duration-base) ease;
}

.card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  border-radius: var(--radius-badge);
  background: var(--surface-well);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-pressed);
  color: var(--text-accent);
  flex-shrink: 0;
}

.card-title {
  margin: 0;
  font-size: var(--text-xl);
}

.card-text {
  color: var(--text-soft);
  margin: 0;
}

.card-link {
  text-decoration: none;
  color: inherit;
  justify-content: space-between;
}

.card-link:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-raised-hover);
  color: inherit;
}

.card-arrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  margin-top: auto;
  padding-top: var(--space-2);
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--text-accent);
}

/* =========================================================================
   8. ANSWER BOX
   ========================================================================= */
.answer-box {
  background: var(--surface-card);
  border-radius: var(--radius-card);
  border: 1px solid var(--border-light);
  border-left: 4px solid var(--accent);
  box-shadow: var(--shadow-raised);
  padding: var(--space-5);
  margin-block: var(--space-5);
}

.answer-box-label {
  display: inline-block;
  margin-bottom: var(--space-2);
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-accent);
}

.answer-box-text {
  font-size: var(--text-lg);
  color: var(--text);
  margin: 0;
}

/* =========================================================================
   9. NUMBERED STEPS (4-step Process)
   ========================================================================= */
.steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-5);
}

@media (min-width: 60rem) {
  .steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.step-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: var(--space-5);
  min-width: 0;
  background: var(--surface-card);
  border-radius: var(--radius-card);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-raised);
  padding: var(--space-5);
}

@media (min-width: 36rem) {
  .step-card {
    flex-direction: row;
    align-items: stretch;
  }
}

.step-body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.step-head {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: var(--radius-pill);
  background: var(--surface-disc);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-disc);
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--text-accent);
  flex-shrink: 0;
}

.step-title {
  margin: 0;
}

.step-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-4);
  border-radius: var(--radius-well);
  background: var(--surface-well);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-pressed);
  text-align: center;
  flex-shrink: 0;
}

@media (min-width: 36rem) {
  .step-tile {
    width: 10.5rem;
  }
}

.step-tile-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3.5rem;
  height: 3.5rem;
  border-radius: var(--radius-pill);
  background: var(--surface-disc);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-disc);
  color: var(--text-accent);
}

.step-tile-label {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-accent);
}

/* =========================================================================
   10. WORKFLOW DEMO (Signature Piece)
   ========================================================================= */
.wf {
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
}

.wf-bar {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  background: var(--surface-card);
  border-radius: var(--radius-card);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-raised);
  padding: var(--space-4) var(--space-5);
}

@media (min-width: 56rem) {
  .wf-bar {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.wf-meta {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-width: 0;
}

.wf-badge-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: var(--radius-badge);
  background: var(--surface-disc);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-disc);
  color: var(--text-accent);
  flex-shrink: 0;
}

.wf-title {
  margin: 0;
  font-size: var(--text-lg);
}

.wf-sub {
  margin: 0;
  font-size: var(--text-sm);
  color: var(--text-muted);
}

.wf-metrics {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
}

.wf-metric {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-pill);
  background: var(--surface-well);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-input);
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.wf-metric strong {
  color: var(--text);
}

.wf-status-dot {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: var(--radius-pill);
  background: var(--wire-active);
  box-shadow: var(--shadow-status-glow);
}

.wf-viewport {
  background: var(--surface-slab);
  border-radius: var(--radius-slab);
  border-top: 2px solid var(--border-light);
  border-left: 2px solid var(--border-light);
  border-bottom: 2px solid var(--border-strong);
  border-right: 2px solid var(--border-strong);
  box-shadow: var(--shadow-slab);
  padding: var(--space-5);
}

@media (min-width: 48rem) {
  .wf-viewport {
    padding: var(--space-6);
  }
}

.wf-stage {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: var(--space-3);
}

@media (min-width: 56rem) {
  .wf-stage {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 0;
  }
}

.wf-node {
  position: relative;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: var(--space-3);
  background: var(--surface-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-raised);
  padding: var(--space-4);
  min-width: 0;
}

@media (min-width: 56rem) {
  .wf-node {
    flex-direction: column;
    text-align: center;
    background: transparent;
    border: 0;
    box-shadow: none;
    padding: var(--space-2);
    width: 11.5rem;
    flex-shrink: 0;
  }
}

.wf-node-tag {
  display: inline-block;
  padding: 0.125rem 0.5rem;
  border-radius: var(--radius-badge);
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: var(--accent-tag-ai);
  color: var(--text-on-tag);
  margin-bottom: var(--space-1);
}

.wf-node-trigger .wf-node-tag {
  background: var(--accent-tag-trigger);
}

.wf-node-action .wf-node-tag {
  background: var(--surface-accent-soft);
  color: var(--text-accent);
  border: 1px solid var(--border-accent);
}

.wf-coin {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 4.5rem;
  height: 4.5rem;
  border-radius: var(--radius-pill);
  background: var(--surface-disc);
  border: 2px solid var(--border-light);
  box-shadow: var(--shadow-node-active);
  flex-shrink: 0;
}

.wf-coin-well {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  border-radius: var(--radius-pill);
  background: var(--surface-well);
  box-shadow: var(--shadow-pressed);
  color: var(--text-accent);
}

.wf-port {
  display: none;
}

@media (min-width: 56rem) {
  .wf-port {
    display: block;
    position: absolute;
    top: 50%;
    width: 0.75rem;
    height: 0.75rem;
    border-radius: var(--radius-pill);
    background: var(--surface-disc);
    border: 2px solid var(--wire-active);
    transform: translateY(-50%);
  }

  .wf-port-in { left: -0.45rem; }
  .wf-port-out { right: -0.45rem; }
}

.wf-node-copy {
  min-width: 0;
}

.wf-node-label {
  margin: 0;
  font-size: var(--text-base);
  font-weight: 700;
  color: var(--text);
}

.wf-node-desc {
  margin: var(--space-1) 0 0;
  font-size: var(--text-xs);
  color: var(--text-muted);
}

/* Connectors between Trigger -> AI -> Actions */
.wf-connector {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 2rem;
}

.wf-wire-desktop {
  display: none;
}

.wf-wire-mobile {
  width: 1.5rem;
  height: 2rem;
}

@media (min-width: 56rem) {
  .wf-connector {
    flex: 1;
    height: auto;
    min-width: 3rem;
  }

  .wf-wire-desktop {
    display: block;
    width: 100%;
    height: 100%;
    overflow: visible;
  }

  .wf-wire-mobile {
    display: none;
  }

  .wf-connector-fan {
    min-width: 5rem;
    height: 16rem;
  }
}

.wf-wire-base {
  fill: none;
  stroke: var(--wire-color);
  stroke-width: 2.5;
  stroke-linecap: round;
  opacity: 0.6;
}

.wf-wire-pulse {
  fill: none;
  stroke: var(--wire-active);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-dasharray: 18 44;
}

@media (prefers-reduced-motion: no-preference) {
  @keyframes wfFlow {
    from { stroke-dashoffset: 62; }
    to { stroke-dashoffset: 0; }
  }

  .wf-wire-pulse {
    animation: wfFlow 1.8s linear infinite;
  }

  .wf-status-dot {
    animation: wfDotPulse 1.6s ease-in-out infinite;
  }

  @keyframes wfDotPulse {
    0%, 100% { transform: scale(0.9); opacity: 0.75; }
    50% { transform: scale(1.25); opacity: 1; }
  }
}

.wf-branches {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

@media (min-width: 56rem) {
  .wf-branches {
    gap: var(--space-3);
    flex-shrink: 0;
  }

  .wf-branches .wf-node {
    flex-direction: row;
    text-align: left;
    width: 15.5rem;
    background: var(--surface-card);
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-raised);
    padding: var(--space-3) var(--space-4);
  }

  .wf-branches .wf-coin {
    width: 3.25rem;
    height: 3.25rem;
  }

  .wf-branches .wf-coin-well {
    width: 2.25rem;
    height: 2.25rem;
  }
}

/* =========================================================================
   11. LISTS & RESPONSIVE COMPARISON TABLE
   ========================================================================= */
.checklist,
.deliverables {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.checklist-item,
.deliverable-item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
}

.check-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.5rem;
  height: 1.5rem;
  margin-top: 0.15rem;
  border-radius: var(--radius-pill);
  background: var(--surface-well);
  box-shadow: var(--shadow-input);
  color: var(--text-accent);
  flex-shrink: 0;
}

.deliverable-item {
  background: var(--surface-well);
  border-radius: var(--radius-input);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-input);
  padding: var(--space-3) var(--space-4);
}

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

.do-box,
.dont-box {
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-raised);
  padding: var(--space-5);
  min-width: 0;
}

.do-box {
  background: var(--surface-do);
  border: 1px solid var(--border-accent);
}

.dont-box {
  background: var(--surface-dont);
  border: 1px solid var(--border-danger);
}

.do-dont-title {
  margin-bottom: var(--space-3);
  font-size: var(--text-lg);
}

.do-box .do-dont-title { color: var(--text-accent); }
.dont-box .do-dont-title { color: var(--text-danger); }

.do-dont-list {
  margin: 0;
  padding-left: var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

/* Responsive table scrolling inside its own box */
.table-wrap {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: var(--radius-card);
  background: var(--surface-card);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-raised);
}

.data-table {
  width: 100%;
  min-width: 34rem;
  border-collapse: collapse;
  text-align: left;
  font-size: var(--text-sm);
}

.data-table th,
.data-table td {
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border-subtle);
  vertical-align: top;
}

.data-table thead th {
  background: var(--surface-table-head);
  color: var(--text);
  font-weight: 700;
}

.data-table tbody tr:last-child td {
  border-bottom: 0;
}

/* =========================================================================
   12. QUESTION BLOCKS (FAQ)
   ========================================================================= */
.faq {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  margin-block: var(--space-6);
}

.faq-item {
  background: var(--surface-card);
  border-radius: var(--radius-card);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-raised);
  padding: var(--space-2) var(--space-5);
}

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  min-height: 3rem;
  padding-block: var(--space-3);
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--text);
  cursor: pointer;
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border-radius: var(--radius-pill);
  background: var(--surface-well);
  box-shadow: var(--shadow-input);
  color: var(--text-accent);
  font-size: var(--text-lg);
  flex-shrink: 0;
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-answer {
  padding: 0 0 var(--space-4);
  color: var(--text-soft);
}

/* =========================================================================
   13. CALL TO ACTION BAND
   ========================================================================= */
.cta-band {
  padding-block: var(--space-6);
}

.cta-slab {
  background: var(--surface-slab);
  border-radius: var(--radius-slab);
  border-top: 2px solid var(--border-light);
  border-left: 2px solid var(--border-light);
  border-bottom: 2px solid var(--border-strong);
  border-right: 2px solid var(--border-strong);
  box-shadow: var(--shadow-slab);
  padding: var(--space-5);
  text-align: center;
}

@media (min-width: 48rem) {
  .cta-slab {
    padding: var(--space-7);
  }
}

.cta-plate {
  max-width: 44rem;
  margin: 0 auto var(--space-5);
  background: var(--surface-plate);
  border-radius: var(--radius-plate);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-plate);
  padding: var(--space-5);
}

.cta-title {
  margin-bottom: var(--space-3);
}

.cta-lead {
  font-size: var(--text-lg);
  color: var(--text-soft);
  margin: 0;
}

.cta-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-3);
}

/* =========================================================================
   14. LEAD FORM
   ========================================================================= */
.lead-form {
  background: var(--surface-card);
  border-radius: var(--radius-card);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-raised);
  padding: var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

@media (min-width: 48rem) {
  .lead-form {
    padding: var(--space-6);
  }
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
}

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

.field {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  min-width: 0;
}

.field-label {
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--text);
}

.field-optional {
  font-weight: 400;
  color: var(--text-muted);
}

.field-control {
  width: 100%;
  min-height: 2.875rem;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-input);
  background: var(--surface-input);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-input);
  color: var(--text);
  font-family: var(--font-body);
  font-size: var(--text-base);
  transition: border-color var(--duration-fast) ease, box-shadow var(--duration-fast) ease;
}

.field-control:focus {
  outline: none;
  border-color: var(--border-accent);
  box-shadow: var(--shadow-input-focus);
}

.field-control[aria-invalid="true"] {
  border-color: var(--border-danger);
}

.field-error {
  margin: 0;
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--text-danger);
}

.field-textarea {
  min-height: 7.5rem;
  resize: vertical;
  padding-block: var(--space-3);
}

.form-footer {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.cf-turnstile {
  line-height: 0;
  min-height: 0;
  width: fit-content;
  max-width: 100%;
}

.cf-turnstile:empty {
  display: none;
}

.form-consent {
  font-size: var(--text-xs);
  color: var(--text-muted);
  margin: 0;
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
}

.form-status {
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-input);
  font-size: var(--text-sm);
  font-weight: 700;
}

.form-status-error {
  background: var(--surface-dont);
  border: 1px solid var(--border-danger);
  color: var(--text-danger);
}

.form-status-success {
  background: var(--surface-do);
  border: 1px solid var(--border-accent);
  color: var(--text-accent);
}

/* =========================================================================
   15. ARTICLE LAYOUT (Guides)
   ========================================================================= */
.article-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
  align-items: start;
}

@media (min-width: 64rem) {
  .article-layout {
    grid-template-columns: 18rem minmax(0, 1fr);
  }
}

.toc {
  background: var(--surface-card);
  border-radius: var(--radius-card);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-raised);
  padding: var(--space-5);
}

@media (min-width: 64rem) {
  .toc {
    position: sticky;
    top: 5.5rem;
  }
}

.toc-title {
  margin-bottom: var(--space-3);
  font-size: var(--text-sm);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-accent);
}

.toc-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.toc-link {
  display: inline-flex;
  align-items: center;
  min-height: 2.5rem;
  font-size: var(--text-sm);
  color: var(--text-soft);
  text-decoration: none;
}

.toc-link:hover {
  color: var(--text-accent);
  text-decoration: underline;
}

.article-body {
  min-width: 0;
  max-width: var(--measure);
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  margin-bottom: var(--space-5);
  font-size: var(--text-sm);
  color: var(--text-muted);
}

.prose > * + * {
  margin-top: var(--space-4);
}

.prose h2,
.prose h3 {
  margin-top: var(--space-6);
}

.prose ul,
.prose ol {
  padding-left: var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.callout-quote {
  margin: var(--space-5) 0;
  padding: var(--space-4) var(--space-5);
  border-radius: var(--radius-well);
  border-left: 4px solid var(--accent);
  background: var(--surface-well);
  box-shadow: var(--shadow-pressed);
}

.callout-quote-text {
  font-size: var(--text-lg);
  color: var(--text);
  margin: 0 0 var(--space-2);
}

.callout-quote-source {
  font-size: var(--text-sm);
  color: var(--text-muted);
}

.prose code {
  font-family: var(--font-mono);
  font-size: 0.9em;
  padding: 0.125rem 0.375rem;
  border-radius: var(--radius-xs);
  background: var(--surface-well);
  border: 1px solid var(--border-subtle);
}

.prose pre {
  margin: var(--space-5) 0;
  padding: var(--space-4);
  border-radius: var(--radius-well);
  background: var(--surface-well);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-pressed);
  overflow-x: auto;
}

.prose pre code {
  padding: 0;
  border: 0;
  background: transparent;
}

.author-box {
  margin-top: var(--space-6);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  background: var(--surface-card);
  border-radius: var(--radius-card);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-raised);
  padding: var(--space-5);
}

@media (min-width: 34rem) {
  .author-box {
    flex-direction: row;
    align-items: center;
  }
}

.author-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 5rem;
  height: 5rem;
  border-radius: var(--radius-pill);
  background: var(--accent-gradient);
  color: var(--text-on-accent);
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 700;
  letter-spacing: var(--tracking-tight);
  border: 2px solid var(--border-light);
  box-shadow: var(--shadow-disc);
  flex-shrink: 0;
}

.author-name {
  margin: 0 0 var(--space-1);
  font-size: var(--text-lg);
}

.author-role {
  margin: 0 0 var(--space-2);
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-accent);
}

/* =========================================================================
   16. UTILITY & LEGAL LAYOUTS
   ========================================================================= */
.utility-card {
  max-width: 40rem;
  margin: var(--space-6) auto;
  text-align: center;
  background: var(--surface-slab);
  border-radius: var(--radius-slab);
  border-top: 2px solid var(--border-light);
  border-left: 2px solid var(--border-light);
  border-bottom: 2px solid var(--border-strong);
  border-right: 2px solid var(--border-strong);
  box-shadow: var(--shadow-slab);
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-4);
}

.utility-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-3);
}

.legal-doc {
  max-width: var(--measure);
  margin: var(--space-6) auto 0;
  background: var(--surface-card);
  border-radius: var(--radius-card);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-raised);
  padding: var(--space-5);
}

@media (min-width: 48rem) {
  .legal-doc {
    padding: var(--space-7);
  }
}

/* Optional JS-enhanced Scroll Reveal (never hides text without JS) */
html.has-reveal .reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity var(--duration-base) ease, transform var(--duration-base) var(--ease-spring);
}

html.has-reveal .reveal.is-visible {
  opacity: 1;
  transform: none;
}

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

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  html.has-reveal .reveal {
    opacity: 1;
    transform: none;
  }
}
