* {
  box-sizing: border-box;
}

:root {
  color-scheme: light;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--page-bg);
  color: var(--text);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body.theme-nativz {
  --font-display: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-body: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --brand: #00adef;
  --brand-strong: #0090cc;
  --brand-soft: #e6f7fe;
  --dark: #060e1a;
  --navy: #0a1628;
  --page-bg: #f4f8fb;
  --surface: #ffffff;
  --surface-alt: #edf7fb;
  --text: #0a1628;
  --body: #334155;
  --muted: #718096;
  --border: #d9e7f0;
  --shadow: 0 22px 70px rgba(10, 22, 40, 0.14);
  --display-weight: 700;
  --heading-transform: none;
  --heading-letter: 0;
  --metric-weight: 700;
  --button-radius: 6px;
}

body.theme-ac {
  --font-display: 'Roboto', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  --font-body: 'Rubik', 'Roboto', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --brand: #36d1c2;
  --brand-strong: #2bb8aa;
  --brand-soft: #e6f9f7;
  --dark: #00161f;
  --navy: #001631;
  --page-bg: #f4f6f9;
  --surface: #ffffff;
  --surface-alt: #eef5f6;
  --text: #00161f;
  --body: #3d4852;
  --muted: #7b8794;
  --border: #ccd6df;
  --shadow: 0 22px 70px rgba(0, 22, 31, 0.13);
  --display-weight: 300;
  --heading-transform: none;
  --heading-letter: 0.01em;
  --metric-weight: 300;
  --button-radius: 0;
}

a {
  color: inherit;
}

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

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2 {
  font-family: var(--font-display);
  font-weight: var(--display-weight);
  letter-spacing: var(--heading-letter);
  text-transform: var(--heading-transform);
}

h1 {
  margin: 14px 0 18px;
  max-width: 780px;
  color: var(--text);
  font-size: clamp(36px, 5vw, 64px);
  line-height: 1.04;
}

h2 {
  margin: 12px 0 14px;
  color: var(--text);
  font-size: clamp(28px, 3.5vw, 46px);
  line-height: 1.12;
}

h3 {
  margin: 0 0 10px;
  color: var(--text);
  font: 600 18px/1.25 var(--font-body);
}

body.theme-ac h3 {
  font-weight: 500;
}

.template-shell {
  min-height: 100vh;
  overflow-x: hidden;
}

.template-nav {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(16px);
}

.nav-inner {
  width: min(1120px, calc(100% - 40px));
  min-height: 66px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand-lockup {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.brand-lockup img {
  width: auto;
  height: 32px;
  object-fit: contain;
}

.brand-lockup span,
.template-tag,
.label,
.eyebrow,
.card-link,
.blueprint-header,
.doc-kicker,
.metric span,
.site-footer {
  font-family: var(--font-body);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.brand-lockup span {
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  font-weight: 500;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-links a,
.button {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: var(--button-radius);
  padding: 0 16px;
  background: var(--brand);
  color: var(--dark);
  font: 600 12px/1 var(--font-body);
  letter-spacing: 0.08em;
  text-decoration: none;
  text-transform: uppercase;
  white-space: nowrap;
}

.nav-links a.secondary,
.button.secondary {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}

.hero {
  padding: 46px 20px 52px;
  background:
    linear-gradient(90deg, transparent 0 31px, rgba(0, 0, 0, 0.035) 31px 32px),
    linear-gradient(180deg, transparent 0 31px, rgba(0, 0, 0, 0.035) 31px 32px),
    linear-gradient(var(--page-bg), var(--page-bg));
  background-size: auto, 32px 32px, 32px 32px;
}

.hero-shell {
  width: min(1120px, 100%);
  margin: 0 auto;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.hero-bar {
  min-height: 86px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 24px clamp(22px, 4vw, 42px);
  background: var(--dark);
  color: rgba(255, 255, 255, 0.72);
}

.hero-bar img {
  width: auto;
  max-width: 240px;
  height: 38px;
  object-fit: contain;
}

.hero-bar span {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(330px, 0.72fr);
  gap: clamp(28px, 5vw, 58px);
  align-items: start;
  padding: clamp(34px, 6vw, 58px);
}

.hero-copy p,
.body-copy,
.muted {
  color: var(--body);
  font-size: 16px;
  line-height: 1.7;
}

.hero-copy p {
  max-width: 700px;
  margin-bottom: 0;
  font-size: clamp(17px, 2vw, 20px);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 30px;
}

.eyebrow,
.label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--brand-strong);
  font-size: 11px;
  font-weight: 600;
}

.label::before {
  content: '';
  width: 24px;
  height: 2px;
  background: var(--brand);
}

.blueprint-card {
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.08);
}

.blueprint-header {
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 0 18px;
  background: var(--dark);
  color: rgba(255, 255, 255, 0.74);
  font-size: 10px;
  font-weight: 600;
}

.blueprint-document {
  padding: 22px;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.025) 1px, transparent 1px),
    linear-gradient(180deg, rgba(0, 0, 0, 0.025) 1px, transparent 1px),
    #ffffff;
  background-size: 22px 22px;
}

.doc-toolbar {
  display: flex;
  gap: 6px;
  margin-bottom: 20px;
}

.doc-toolbar span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border);
}

.doc-kicker {
  margin-bottom: 10px;
  color: var(--brand-strong);
  font-size: 10px;
  font-weight: 700;
}

.doc-title,
.doc-copy,
.doc-bars span::before {
  display: block;
  border-radius: 999px;
}

.doc-title {
  width: 76%;
  height: 22px;
  margin-bottom: 12px;
  background: var(--text);
}

.doc-copy {
  width: 58%;
  height: 9px;
  margin-bottom: 20px;
  background: var(--border);
}

.doc-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 20px;
}

.doc-metrics div {
  min-height: 58px;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.86);
}

.doc-metrics strong {
  display: block;
  color: var(--brand-strong);
  font: var(--metric-weight) 20px/1 var(--font-display);
}

.doc-metrics span {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 600;
  line-height: 1.2;
  text-transform: uppercase;
}

.doc-bars {
  display: grid;
  gap: 8px;
  margin-bottom: 20px;
}

.doc-bars span {
  height: 8px;
  border-radius: 999px;
  background: var(--brand-soft);
}

.doc-bars span::before {
  content: '';
  width: var(--fill);
  height: 100%;
  background: var(--brand);
}

.doc-steps {
  display: grid;
  gap: 8px;
}

.doc-step {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.9);
}

.doc-step > span,
.module-number,
.row-number,
.card-number,
.quality-grid article > span {
  display: grid;
  place-items: center;
  color: var(--brand-strong);
  background: var(--brand-soft);
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
}

.doc-step > span {
  width: 28px;
  height: 28px;
  border-radius: 6px;
}

.doc-step strong,
.doc-step em {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.doc-step strong {
  color: var(--brand-strong);
  font-size: 10px;
  font-style: normal;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.doc-step em {
  margin-top: 4px;
  color: var(--text);
  font-size: 12px;
  font-style: normal;
  line-height: 1.25;
}

.metric-strip {
  background: var(--dark);
  color: #ffffff;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  border-bottom: 1px solid color-mix(in srgb, var(--brand) 32%, transparent);
}

.metric-grid {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.metric {
  min-height: 106px;
  display: grid;
  align-content: center;
  gap: 8px;
  padding: 22px;
  border-left: 1px solid rgba(255, 255, 255, 0.1);
}

.metric:last-child {
  border-right: 1px solid rgba(255, 255, 255, 0.1);
}

.metric strong {
  color: var(--brand);
  font: var(--metric-weight) 32px/1 var(--font-display);
}

.metric span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 10px;
  font-weight: 600;
  line-height: 1.35;
}

.section {
  padding: clamp(62px, 8vw, 96px) 20px;
}

.section.compact {
  padding: 44px 20px 0;
}

.section.alt {
  background: var(--surface-alt);
}

.section.dark,
.cta-band,
.site-footer {
  background: var(--dark);
  color: #ffffff;
}

.section.dark h2,
.section.dark h3,
.cta-band h2 {
  color: #ffffff;
}

.section.dark .body-copy,
.section.dark .muted {
  color: rgba(255, 255, 255, 0.72);
}

.section-inner {
  width: min(1120px, 100%);
  margin: 0 auto;
}

.section-head {
  max-width: 760px;
  margin-bottom: 34px;
}

.section-head p {
  margin-bottom: 0;
}

.card-grid,
.module-grid,
.quality-grid,
.intent-grid {
  display: grid;
  gap: 16px;
}

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

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

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

.template-card,
.module-card,
.intent-panel,
.section-row,
.quality-grid article {
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 8px 26px rgba(0, 0, 0, 0.04);
}

.template-card {
  min-height: 318px;
  display: grid;
  grid-template-rows: auto 1fr auto auto;
  gap: 18px;
  padding: 22px;
  text-decoration: none;
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease;
}

.template-card:hover {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, var(--brand) 58%, var(--border));
  box-shadow: var(--shadow);
}

.card-number,
.module-number,
.row-number,
.quality-grid article > span {
  width: 34px;
  height: 34px;
  border-radius: 6px;
}

.template-card-body {
  display: grid;
  align-content: start;
}

.template-tag {
  margin-bottom: 12px;
  color: var(--brand-strong);
  font-size: 10px;
  font-weight: 700;
}

.template-card p,
.module-card p,
.intent-panel p,
.quality-grid p {
  margin-bottom: 0;
}

.card-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.card-metrics span {
  min-height: 54px;
  display: grid;
  align-content: center;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 600;
  line-height: 1.25;
  text-transform: uppercase;
}

.card-metrics strong {
  margin-bottom: 4px;
  color: var(--text);
  font-family: var(--font-display);
  font-size: 17px;
  line-height: 1;
}

.card-link {
  color: var(--brand-strong);
  font-size: 11px;
  font-weight: 700;
}

.module-card,
.intent-panel,
.quality-grid article {
  padding: 24px;
}

.module-card {
  min-height: 176px;
}

.module-number {
  margin-bottom: 18px;
}

.intent-panel p {
  color: var(--text);
  font-size: 18px;
  line-height: 1.55;
}

.timeline {
  display: grid;
  gap: 14px;
}

.section-row {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr) minmax(260px, 0.55fr);
  gap: 22px;
  align-items: start;
  padding: 24px;
}

.row-number {
  width: 42px;
  height: 42px;
}

.row-copy p {
  margin-bottom: 0;
}

.row-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.row-list li {
  position: relative;
  padding-left: 18px;
  color: var(--body);
  font-size: 14px;
  line-height: 1.55;
}

.row-list li::before {
  content: '';
  position: absolute;
  top: 0.62em;
  left: 0;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--brand);
}

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

.quality-grid article {
  min-height: 220px;
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.16);
}

.quality-grid article > span {
  margin-bottom: 18px;
  color: var(--dark);
  background: var(--brand);
}

.quality-grid p {
  color: rgba(255, 255, 255, 0.72);
  font-size: 14px;
  line-height: 1.65;
}

.cta-band {
  padding: 70px 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.cta-inner {
  width: min(1120px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 28px;
  align-items: center;
}

.cta-inner p {
  max-width: 720px;
  margin-bottom: 0;
  color: rgba(255, 255, 255, 0.72);
}

.site-footer {
  padding: 26px 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.56);
  font-size: 10px;
}

.site-footer-inner {
  width: min(1120px, 100%);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.site-footer a {
  color: var(--brand);
  text-decoration: none;
}

@media (max-width: 980px) {
  .brand-lockup span,
  .nav-links .optional,
  .hero-bar span {
    display: none;
  }

  .hero-content,
  .section-row,
  .cta-inner {
    grid-template-columns: 1fr;
  }

  .metric-grid,
  .card-grid,
  .module-grid,
  .intent-grid,
  .quality-grid {
    grid-template-columns: 1fr;
  }

  .metric,
  .metric:last-child {
    border-right: 0;
    border-left: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
  }

  .template-card {
    min-height: 0;
  }
}

@media (max-width: 620px) {
  .nav-inner {
    width: min(100% - 28px, 1120px);
  }

  .hero {
    padding: 26px 14px 34px;
  }

  .hero-bar,
  .hero-content,
  .section-row {
    padding: 22px;
  }

  .hero-bar img {
    height: 32px;
    max-width: 190px;
  }

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

  .section {
    padding-inline: 14px;
  }
}

/* -------- Hero with image -------- */

.hero.hero--with-image {
  position: relative;
}

.hero-media {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0.18;
  pointer-events: none;
  filter: saturate(1.05);
}

.hero.hero--with-image .hero-shell {
  position: relative;
}

/* -------- Section row with image -------- */

.section-row--with-image {
  grid-template-columns: 52px minmax(0, 1.1fr) minmax(280px, 0.9fr);
}

.row-figure {
  margin: 0;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface-alt);
}

.row-figure img {
  width: 100%;
  height: 100%;
  max-height: 280px;
  object-fit: cover;
  display: block;
}

.row-figure figcaption {
  padding: 10px 14px;
  border-top: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* -------- Feature sections (charts, funnels, checklists, etc.) -------- */

.section--features {
  background: var(--surface);
}

.section--features + .section { padding-top: 0; }

.feature-grid {
  display: grid;
  gap: 20px;
}

.feature-grid--one { grid-template-columns: minmax(0, 1fr); }
.feature-grid--two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.feature-grid--three { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.feature-card {
  position: relative;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  padding: 24px;
  box-shadow: 0 8px 26px rgba(0, 0, 0, 0.04);
  display: grid;
  align-content: start;
  gap: 14px;
  color: var(--brand-strong);
}

.feature-card h3,
.feature-card h4 {
  color: var(--text);
}

.feature-card p,
.feature-card li {
  color: var(--body);
}

.feature-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--brand-strong);
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.feature-eyebrow::before {
  content: '';
  width: 18px;
  height: 2px;
  background: var(--brand);
}

.feature-conclusion {
  margin: 0;
  font-size: 16px;
  line-height: 1.6;
}

.feature-evidence {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.feature-evidence li {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 8px;
  font-size: 14px;
  line-height: 1.55;
}

.feature-evidence li > span:first-child {
  color: var(--brand);
  font-weight: 700;
}

.feature-next,
.feature-source,
.feature-note {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.feature-next strong { color: var(--text); }

.feature-confidence {
  align-self: start;
  display: inline-flex;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-strong);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.feature-confidence.is-high { background: var(--brand-soft); color: var(--brand-strong); }
.feature-confidence.is-medium { background: rgba(245, 158, 11, 0.14); color: #b45309; }
.feature-confidence.is-low { background: rgba(220, 38, 38, 0.14); color: #b91c1c; }

/* -------- KPI trend chart -------- */

.chart {
  display: grid;
  gap: 12px;
}

.chart--trend svg {
  width: 100%;
  height: auto;
  color: var(--brand);
  background: var(--surface-alt);
  border-radius: 6px;
  padding: 8px;
}

.chart-area { color: var(--brand); }
.chart-line { color: var(--brand-strong); }
.chart-dot { fill: var(--brand-strong); }

.chart-labels {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.chart-labels span {
  display: grid;
  gap: 2px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  color: var(--muted);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1.3;
}

.chart-labels strong {
  display: block;
  color: var(--text);
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: var(--metric-weight);
  letter-spacing: 0;
  text-transform: none;
}

.chart-labels .is-peak {
  border-color: color-mix(in srgb, var(--brand) 50%, var(--border));
  background: var(--brand-soft);
}

/* -------- Budget allocation -------- */

.alloc-bar {
  display: flex;
  width: 100%;
  height: 38px;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface-alt);
}

.alloc-segment {
  display: grid;
  place-items: center;
  width: var(--share);
  min-width: 28px;
  color: var(--dark);
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.alloc-segment em { font-style: normal; }

.alloc-segment--brand,
.alloc-swatch.alloc-segment--brand { background: var(--brand); }
.alloc-segment--accent,
.alloc-swatch.alloc-segment--accent { background: color-mix(in srgb, var(--brand) 60%, var(--dark)); color: #fff; }
.alloc-segment--support,
.alloc-swatch.alloc-segment--support { background: color-mix(in srgb, var(--brand) 30%, var(--surface-alt)); }
.alloc-segment--neutral,
.alloc-swatch.alloc-segment--neutral { background: var(--border); }

.alloc-legend {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.alloc-legend li {
  display: grid;
  grid-template-columns: 16px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
}

.alloc-swatch {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  margin-top: 3px;
}

.alloc-label {
  display: grid;
  gap: 2px;
  font-size: 14px;
}

.alloc-label strong { color: var(--text); }
.alloc-label em {
  color: var(--brand-strong);
  font-style: normal;
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: var(--metric-weight);
}

.alloc-note {
  grid-column: 1 / -1;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

/* -------- Channel matrix table -------- */

.matrix-scroll {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
}

.matrix-table {
  width: 100%;
  min-width: 640px;
  border-collapse: collapse;
  font-size: 14px;
}

.matrix-table th,
.matrix-table td {
  padding: 12px 14px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--border);
  color: var(--body);
}

.matrix-table thead th {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  background: var(--surface-alt);
}

.matrix-table tbody th {
  color: var(--text);
  font-weight: 600;
}

.matrix-table tbody tr:last-child td,
.matrix-table tbody tr:last-child th {
  border-bottom: 0;
}

/* -------- Status pills (shared by matrix & checklist) -------- */

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

.status-pill::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
}

.status-pill.is-ready { background: rgba(34, 197, 94, 0.14); color: #15803d; }
.status-pill.is-watch { background: rgba(245, 158, 11, 0.14); color: #b45309; }
.status-pill.is-blocked { background: rgba(220, 38, 38, 0.14); color: #b91c1c; }
.status-pill.is-neutral { background: var(--brand-soft); color: var(--brand-strong); }

/* -------- O1-O4 Funnel stages -------- */

.funnel-stages {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.funnel-stage {
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  padding: 14px 16px;
  display: grid;
  gap: 8px;
}

.funnel-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  padding: 10px 14px;
  border-radius: 6px;
  background: linear-gradient(90deg, var(--brand-soft), var(--surface-alt));
  width: var(--stage-width, 100%);
  min-width: 280px;
  transition: width 0.3s ease;
}

.funnel-code {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  background: var(--brand);
  color: var(--dark);
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
}

.funnel-name {
  flex: 1;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
}

.funnel-budget {
  margin-left: auto;
  color: var(--brand-strong);
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: var(--metric-weight);
}

.funnel-detail {
  display: grid;
  gap: 4px;
  padding: 4px 4px 0;
}

.funnel-detail p {
  margin: 0;
  font-size: 13px;
  line-height: 1.55;
}

.funnel-detail strong { color: var(--text); }
.funnel-exclusions strong { color: #b91c1c; }

/* -------- Launch checklist -------- */

.checklist {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.checklist-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
}

.checklist-copy {
  display: grid;
  gap: 2px;
}

.checklist-copy strong {
  color: var(--text);
  font-size: 14px;
  line-height: 1.4;
}

.checklist-copy span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.checklist-owner {
  color: var(--brand-strong);
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* -------- Audit findings -------- */

.findings-grid {
  display: grid;
  gap: 12px;
}

.finding {
  border: 1px solid var(--border);
  border-left: 4px solid var(--brand);
  border-radius: 6px;
  background: var(--surface);
  padding: 14px 16px;
  display: grid;
  gap: 6px;
}

.finding p { margin: 0; font-size: 13px; line-height: 1.55; }

.finding-head {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: baseline;
}

.finding-head h4 {
  margin: 0;
  font-size: 15px;
  line-height: 1.3;
}

.finding-severity {
  display: inline-flex;
  padding: 2px 8px;
  border-radius: 4px;
  background: var(--brand-soft);
  color: var(--brand-strong);
  font-family: var(--font-body);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.finding--critical { border-left-color: #b91c1c; }
.finding--critical .finding-severity { background: rgba(220, 38, 38, 0.14); color: #b91c1c; }
.finding--high { border-left-color: #ea580c; }
.finding--high .finding-severity { background: rgba(234, 88, 12, 0.14); color: #c2410c; }
.finding--medium { border-left-color: #b45309; }
.finding--medium .finding-severity { background: rgba(245, 158, 11, 0.14); color: #b45309; }
.finding--low { border-left-color: var(--brand); }
.finding--low .finding-severity { background: var(--brand-soft); color: var(--brand-strong); }

/* -------- Roadmap timeline -------- */

.roadmap {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 14px;
}

.roadmap-phase {
  position: relative;
  padding: 14px 16px 14px 22px;
  border: 1px solid var(--border);
  border-left: 3px solid var(--brand);
  border-radius: 6px;
  background: var(--surface);
}

.roadmap-phase p { margin: 6px 0; font-size: 13px; line-height: 1.55; }

.roadmap-head {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: baseline;
}

.roadmap-head h4 {
  margin: 0;
  font-size: 16px;
  line-height: 1.25;
}

.roadmap-when {
  color: var(--brand-strong);
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.roadmap-actions {
  list-style: none;
  margin: 6px 0 0;
  padding: 0;
  display: grid;
  gap: 4px;
}

.roadmap-actions li {
  position: relative;
  padding-left: 16px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--body);
}

.roadmap-actions li::before {
  content: '';
  position: absolute;
  top: 0.65em;
  left: 0;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brand);
}

/* -------- Recommendation card -------- */

.section--recommendation {
  background: var(--surface-alt);
}

.recommendation-grid {
  margin: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.recommendation-grid > div {
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
}

.recommendation-grid dt {
  margin-bottom: 6px;
  color: var(--brand-strong);
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.recommendation-grid dd {
  margin: 0;
  color: var(--body);
  font-size: 14px;
  line-height: 1.55;
}

/* -------- Proof wall (multi-group with captions) -------- */

.section--proof {
  background: var(--surface);
}

.proof-group {
  margin-bottom: 28px;
}

.proof-group:last-child { margin-bottom: 0; }

.proof-group-head {
  margin-bottom: 14px;
  display: grid;
  gap: 4px;
}

.proof-group-head h3 {
  margin: 0;
  font-size: 20px;
}

.proof-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
}

.proof-grid figure {
  margin: 0;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  background: var(--surface);
  display: grid;
  grid-template-rows: 1fr auto;
}

.proof-grid img {
  width: 100%;
  height: 100%;
  max-height: 240px;
  object-fit: cover;
  display: block;
}

.proof-grid figcaption {
  padding: 8px 12px;
  border-top: 1px solid var(--border);
  background: var(--surface-alt);
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* -------- Client logo trust bar -------- */

.section--logos {
  padding-block: clamp(48px, 6vw, 72px);
}

.logo-bar {
  list-style: none;
  margin: 0;
  padding: 16px 20px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  display: flex;
  flex-wrap: wrap;
  gap: 28px 36px;
  align-items: center;
  justify-content: center;
}

.logo-bar li {
  display: grid;
  place-items: center;
  min-width: 110px;
  height: 56px;
}

.logo-bar img {
  max-width: 140px;
  max-height: 48px;
  width: auto;
  height: auto;
  object-fit: contain;
  filter: grayscale(0.2);
  opacity: 0.92;
}

/* -------- Team strip -------- */

.section--team {
  background: var(--surface);
}

.team-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}

.team-card {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
}

.team-card img,
.team-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--brand-soft);
}

.team-info {
  display: grid;
  gap: 2px;
}

.team-info strong {
  color: var(--text);
  font-size: 15px;
  line-height: 1.25;
}

.team-info > span {
  color: var(--brand-strong);
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.team-info p {
  margin: 4px 0 0;
  font-size: 13px;
  line-height: 1.5;
}

/* -------- Mobile rules for new components -------- */

@media (max-width: 980px) {
  .section-row--with-image {
    grid-template-columns: 1fr;
  }

  .row-figure img { max-height: 220px; }

  .feature-grid--two,
  .feature-grid--three { grid-template-columns: 1fr; }

  .recommendation-grid { grid-template-columns: 1fr; }

  .alloc-legend { grid-template-columns: 1fr; }

  .funnel-bar { width: 100% !important; min-width: 0; }

  .checklist-row {
    grid-template-columns: auto minmax(0, 1fr);
  }
  .checklist-owner {
    grid-column: 1 / -1;
    justify-self: end;
  }

  .chart-labels { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  .feature-card { padding: 18px; }
  .logo-bar { gap: 18px 24px; }
  .logo-bar li { min-width: 88px; height: 44px; }
  .logo-bar img { max-width: 110px; max-height: 38px; }
  .team-card { grid-template-columns: 52px minmax(0, 1fr); }
  .team-card img,
  .team-avatar { width: 52px; height: 52px; }
}

@media print {
  .template-nav,
  .hero-actions,
  .cta-band {
    display: none !important;
  }

  body {
    background: #ffffff;
  }

  .hero-shell,
  .template-card,
  .module-card,
  .intent-panel,
  .section-row,
  .feature-card,
  .row-figure {
    box-shadow: none;
  }

  .section {
    page-break-inside: avoid;
  }
}
