/* ============================================================
   PDLC Interactive — PDLC App
   Design system aligned to the deck (green/blue/navy)
   Typography: Inter (body), Instrument Serif (accents)
   ============================================================ */

:root {
  --green: #76b942;
  --green-dk: #4e8f27;
  --green-lt: #e9f3dc;
  --blue: #00a8e1;
  --blue-dk: #007baa;
  --blue-lt: #d9eff9;
  --navy: #00355f;
  --navy-dk: #002240;
  --navy-lt: #dde4ec;

  --gold: #f5a623;
  --gold-lt: #fdecc8;

  --ink: #1c1b19;
  --ink-2: #3a3834;
  --ink-3: #605e58;
  --line: #d4d1ca;
  --surface: #ffffff;
  --surface-2: #fafaf7;
  --bg: #f6f4ee;

  --radius: 10px;
  --radius-lg: 14px;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04), 0 1px 3px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08), 0 2px 4px rgba(0, 0, 0, 0.04);
  --shadow-lg: 0 20px 48px rgba(0, 53, 95, 0.16), 0 8px 20px rgba(0, 53, 95, 0.08);
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: 1720px;
  margin: 0 auto;
  padding: 32px 40px 72px;
}

/* ---------- Header ---------- */
header {
  margin-bottom: 32px;
}

.eyebrow {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 10px;
}

h1 {
  font-family: 'Instrument Serif', Georgia, serif;
  font-size: 44px;
  line-height: 1.05;
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin-bottom: 12px;
}

.subtitle {
  font-size: 16px;
  color: var(--ink-2);
  line-height: 1.55;
  max-width: none;
}

.subtitle strong {
  color: var(--ink);
  font-weight: 600;
}

.hint {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
  padding: 8px 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 13px;
  color: var(--ink-2);
  font-weight: 500;
}

.hint svg {
  width: 14px;
  height: 14px;
  color: var(--green-dk);
}

/* ---------- Phase strip (DEFINE/CREATE/DELIVER) ---------- */
.phase-strip {
  display: grid;
  grid-template-columns: 2fr 2fr 2fr;
  gap: 20px;
  margin-bottom: 6px;
}

.phase-header {
  position: relative;
  padding: 10px 24px;
  border-radius: var(--radius);
  color: white;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  text-align: left;
  border: none;
  font-family: inherit;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  gap: 14px;
  min-height: 0;
}

.phase-header:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.phase-header.define {
  background: var(--green);
}
.phase-header.create {
  background: var(--blue);
}
.phase-header.deliver {
  background: var(--navy);
}

.phase-number {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.22);
  border: 1.5px solid white;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 22px;
  flex-shrink: 0;
}

.phase-title {
  font-size: 30px;
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1;
}

.phase-click {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.85);
  opacity: 0;
  transition: opacity 0.18s ease;
}

.phase-header:hover .phase-click {
  opacity: 1;
}

/* ---------- Steps grid ---------- */
.steps {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 12px;
  margin-top: 16px;
  align-items: stretch;
}

.decision-matrix-note {
  margin: 12px 0 0 0;
  font-size: 13px;
  color: var(--ink-2);
  line-height: 1.5;
}
.decision-matrix-note strong {
  color: var(--ink);
  font-weight: 700;
}

.step {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0;
  cursor: pointer;
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease,
    border-color 0.18s ease;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  text-align: left;
  font-family: inherit;
}

.step:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.step[data-phase='DEFINE']:hover {
  border-color: var(--green-dk);
}

.step[data-phase='CREATE']:hover {
  border-color: var(--blue-dk);
}

.step[data-phase='DELIVER']:hover {
  border-color: var(--navy);
}

.step-header {
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  border-bottom: 1px solid var(--line);
}

.step-letter {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  color: white;
  font-weight: 700;
  font-size: 13px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.step[data-phase='DEFINE'] .step-letter {
  background: var(--green);
}
.step[data-phase='CREATE'] .step-letter {
  background: var(--blue);
}
.step[data-phase='DELIVER'] .step-letter {
  background: var(--navy);
}

.step-label {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--ink);
}

.step-body {
  padding: 14px 16px 14px;
  flex: 1;
  display: grid;
  grid-template-rows:
    auto             /* subtitle */
    auto             /* WHAT HAPPENS label */
    auto             /* WHAT HAPPENS text (prose, wraps) */
    auto             /* STAGE GATE label */
    auto             /* gate value line */
    1fr;             /* spacer, fills remaining height */
  gap: 8px;
  font-size: 12.5px;
}

.step-subtitle {
  font-style: italic;
  color: var(--ink-2);
  font-size: 11.5px;
  line-height: 1.3;
  text-align: left;
  /* Reserve 2 lines of vertical space universally so STAGE GATE rows line up
     across all six tiles even when a subtitle (e.g. READY's) wraps. */
  min-height: 30px;
  max-height: 30px;
  overflow: hidden;
}

.step-section-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-top: 6px;
}

.step[data-phase='DEFINE'] .step-section-label.happens {
  color: var(--green-dk);
}

.step[data-phase='CREATE'] .step-section-label.happens {
  color: var(--blue-dk);
}

.step[data-phase='DELIVER'] .step-section-label.happens {
  color: var(--navy);
}

.step-stage-gate {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.3;
  align-self: start;
}

.step-brief-section {
  font-size: 12.5px;
  font-weight: 600;
}

.step[data-phase='DEFINE'] .step-brief-section {
  color: var(--green-dk);
}
.step[data-phase='CREATE'] .step-brief-section {
  color: var(--blue-dk);
}
.step[data-phase='DELIVER'] .step-brief-section {
  color: var(--navy);
}

.step-happens {
  color: var(--ink-2);
  font-size: 11px;
  line-height: 1.4;
  align-self: start;
  list-style: none;
  padding: 0;
  margin: 0;
  /* Fixed 4-item block height so STAGE GATE row lines up across all six tiles.
     4 lines * (11px * 1.4) + 3 * 4px bottom-margin gaps = 61.6 + 12 = 73.6px */
  min-height: 74px;
  max-height: 74px;
  overflow: hidden;
}

.step-happens li {
  padding: 0;
  margin: 0 0 4px 0;
  line-height: 1.4;
  text-indent: 0;
  padding-left: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: clip;
}

.step-happens li::before {
  content: '•  ';
  color: var(--ink-3);
  font-weight: 700;
}



.step-meta-row {
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-size: 11px;
  color: var(--ink-2);
  padding-top: 8px;
  border-top: 1px dashed var(--line);
  line-height: 1.35;
}
.step-meta-row .meta-line {
  display: block;
}
.step-meta-row .meta-label {
  color: var(--ink-3);
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-right: 4px;
}
.step-meta-row strong {
  color: var(--ink);
  font-weight: 600;
}

/* Gate card checklist */
.gate-checklist {
  list-style: none;
  padding: 0;
  margin: 4px 0 0 0;
  font-size: 11.5px;
  color: var(--ink-2);
  line-height: 1.4;
}
.gate-checklist li {
  position: relative;
  padding-left: 12px;
  margin-bottom: 6px;
}
.gate-checklist li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 6px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--ink-3);
}

.step-meta-row span strong {
  color: var(--ink);
  font-weight: 600;
}

.click-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-3);
  opacity: 0;
  transition: opacity 0.18s ease;
}

.step:hover .click-badge {
  opacity: 1;
}

/* ---------- Detail overlay ---------- */
.overlay-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(28, 27, 25, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.24s ease;
  z-index: 100;
}

.overlay-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

.overlay {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -46%) scale(0.98);
  width: min(1160px, calc(100vw - 48px));
  max-height: calc(100vh - 48px);
  background: var(--surface);
  border-radius: 16px;
  box-shadow: var(--shadow-lg);
  z-index: 101;
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 0.24s ease,
    transform 0.24s cubic-bezier(0.2, 0.9, 0.3, 1);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.overlay.open {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, -50%) scale(1);
}

.overlay-header {
  padding: 22px 32px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: white;
  flex-shrink: 0;
}

.overlay-header.define {
  background: linear-gradient(120deg, var(--green) 0%, var(--green-dk) 100%);
}
.overlay-header.create {
  background: linear-gradient(120deg, var(--blue) 0%, var(--blue-dk) 100%);
}
.overlay-header.deliver {
  background: linear-gradient(120deg, var(--navy) 0%, var(--navy-dk) 100%);
}

.overlay-head-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.overlay-letter {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.24);
  border: 2px solid white;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 18px;
  flex-shrink: 0;
}

.overlay-phase-chip {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: rgba(255, 255, 255, 0.75);
  margin-bottom: 4px;
}

.overlay-title {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.overlay-subtitle {
  font-size: 14px;
  opacity: 0.9;
  margin-top: 2px;
  font-weight: 500;
}

.overlay-close {
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 8px;
  color: white;
  padding: 8px 12px;
  cursor: pointer;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  transition: background 0.15s ease;
}

.overlay-close:hover {
  background: rgba(255, 255, 255, 0.28);
}

.overlay-body {
  padding: 28px 32px 32px;
  overflow-y: auto;
  overflow-x: hidden;
  flex: 1;
  min-width: 0;
  max-width: 100%;
}

.overlay-purpose {
  font-family: 'Instrument Serif', Georgia, serif;
  font-size: 22px;
  line-height: 1.35;
  color: var(--ink);
  font-weight: 400;
  margin-bottom: 22px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--line);
  max-width: 900px;
}

.overlay-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 22px;
  margin-bottom: 22px;
  min-width: 0;
}

.overlay-card {
  background: var(--surface-2);
  border: 1px solid var(--line);
  min-width: 0;
  border-radius: var(--radius);
  padding: 16px 18px;
}

.overlay-card.accent-define {
  border-left: 3px solid var(--green);
}
.overlay-card.accent-create {
  border-left: 3px solid var(--blue);
}
.overlay-card.accent-deliver {
  border-left: 3px solid var(--navy);
}

.overlay-card h3 {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 10px;
}

.overlay-card ul {
  list-style: none;
  padding: 0;
}

.overlay-card ul li {
  position: relative;
  padding-left: 14px;
  font-size: 13px;
  color: var(--ink-2);
  line-height: 1.5;
  margin-bottom: 5px;
}

.overlay-card ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 8px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--ink-3);
}

.overlay-card.accent-define ul li::before {
  background: var(--green-dk);
}
.overlay-card.accent-create ul li::before {
  background: var(--blue-dk);
}
.overlay-card.accent-deliver ul li::before {
  background: var(--navy);
}

/* RAPID mini-grid (legacy, retained for compatibility) */
.rapid-grid {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 5px 12px;
  font-size: 12.5px;
  color: var(--ink-2);
}

.rapid-grid dt {
  font-weight: 700;
  color: var(--ink);
  letter-spacing: 0.02em;
}

/* RAPID per-item table */
.rapid-card h3 {
  margin-bottom: 12px;
}

.rapid-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.rapid-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11.5px;
  table-layout: auto;
}

.rapid-table th,
.rapid-table td {
  padding: 6px 6px;
  text-align: center;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

.rapid-table thead th {
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-3);
  background: var(--surface-2);
  border-bottom: 1px solid var(--line);
  padding: 6px 4px;
}

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

.rapid-table th[scope='row'] {
  text-align: left;
  font-weight: 600;
  color: var(--ink);
  position: sticky;
  left: 0;
  background: var(--surface);
  white-space: nowrap;
}

.rapid-item-code {
  color: var(--ink-3);
  font-weight: 700;
  margin-right: 6px;
}

.rapid-item-label {
  font-weight: 500;
  color: var(--ink-2);
}

.rapid-cell {
  color: var(--ink-2);
  font-weight: 500;
}

.rapid-cell.is-none {
  color: var(--ink-3);
  opacity: 0.6;
}

.rapid-cell.is-decide {
  color: var(--navy);
  font-weight: 800;
  background: var(--navy-lt);
}

.rapid-legend {
  font-size: 11px;
  color: var(--ink-3);
  margin-top: 8px;
  line-height: 1.5;
}

.rapid-legend strong {
  color: var(--ink);
}

/* Meta strip */
.overlay-meta {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 22px;
}

.overlay-meta-item {
  padding: 14px 16px;
  border-right: 1px solid var(--line);
}

.overlay-meta-item:last-child {
  border-right: none;
}

.overlay-meta-item .label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 4px;
}

.overlay-meta-item .value {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.35;
}

/* AI leverage callout */
.overlay-ai {
  background: linear-gradient(135deg, rgba(1, 105, 111, 0.08) 0%, rgba(1, 105, 111, 0.02) 100%);
  border: 1px solid rgba(1, 105, 111, 0.25);
  border-radius: var(--radius);
  padding: 18px 20px;
  margin-bottom: 20px;
}

.overlay-ai h3 {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #01696f;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.overlay-ai h3::before {
  content: '';
  width: 18px;
  height: 18px;
  background: #01696f;
  mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path d="M12 2L14 8L20 10L14 12L12 18L10 12L4 10L10 8Z"/><path d="M18 15L18.7 17L20.5 17.5L18.7 18L18 20L17.3 18L15.5 17.5L17.3 17Z"/></svg>')
    center/contain no-repeat;
  -webkit-mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path d="M12 2L14 8L20 10L14 12L12 18L10 12L4 10L10 8Z"/><path d="M18 15L18.7 17L20.5 17.5L18.7 18L18 20L17.3 18L15.5 17.5L17.3 17Z"/></svg>')
    center/contain no-repeat;
}

.overlay-ai ul {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 6px;
}

.overlay-ai li {
  padding-left: 14px;
  position: relative;
  font-size: 13.5px;
  color: var(--ink-2);
  line-height: 1.5;
}

.overlay-ai li::before {
  content: '→';
  position: absolute;
  left: 0;
  top: 0;
  color: #01696f;
  font-weight: 700;
}

/* Pitfalls */
.overlay-pitfalls {
  background: #fef7ed;
  border: 1px solid #fbd08a;
  border-radius: var(--radius);
  padding: 18px 20px;
}

.overlay-pitfalls h3 {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #964219;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.overlay-pitfalls h3::before {
  content: '⚠';
  font-size: 14px;
}

.overlay-pitfalls ul {
  list-style: none;
  padding: 0;
}

.overlay-pitfalls li {
  padding-left: 14px;
  position: relative;
  font-size: 13px;
  color: #4a4844;
  line-height: 1.5;
  margin-bottom: 4px;
}

.overlay-pitfalls li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 8px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #964219;
}

/* Footer strip */
footer {
  margin-top: 48px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
}

footer .footer-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: 0.01em;
}

footer .footer-updated {
  font-size: 12px;
  color: var(--ink-3);
}

/* ---------- Stage gates summary section ---------- */
.gates-section {
  margin-top: 56px;
  padding-top: 40px;
  border-top: 1px solid var(--line);
}

/* When the gates section sits at the top (right below the phase strip),
   we drop the big top separator and use compact spacing. */
.gates-section-top {
  margin-top: 32px;
  padding-top: 0;
  border-top: none;
  margin-bottom: 40px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--line);
}

/* ---------- Per-gate palette ----------
   Each gate gets a distinct color, and the top-row .gate-card is styled
   to match its inline .sec-tile.gate-tile counterpart in each section. */
:root {
  --gate-g1: #a3d977; /* light green  — FRAME  */
  --gate-g1-lt: #eff7e3;
  --gate-g2: #4e8f27; /* deep green   — DISCOVER */
  --gate-g2-lt: #e0eecc;
  --gate-g3: #7fd0eb; /* light blue   — DESIGN */
  --gate-g3-lt: #e4f5fc;
  --gate-g4: #00a8e1; /* deep blue    — READY */
  --gate-g4-lt: #d3edf9;
  --gate-g5: #005a8a; /* indigo blue  — LAUNCH */
  --gate-g5-lt: #d5e2ec;
  --gate-loop: #00355f; /* navy       — LOOP (LEARN) */
  --gate-loop-lt: #d8dfe8;
}

/* Top-row gate cards — border-top and eyebrow tint per gate.
   Higher specificity than .gate-card.phase-DEFINE etc. so the per-gate
   color wins over the phase-family color. */
.gate-card.phase-DEFINE[data-gate-code='G1'],
.gate-card[data-gate-code='G1'] { border-top-color: var(--gate-g1); background: var(--gate-g1-lt); }
.gate-card.phase-DEFINE[data-gate-code='G2'],
.gate-card[data-gate-code='G2'] { border-top-color: var(--gate-g2); background: var(--gate-g2-lt); }
.gate-card.phase-CREATE[data-gate-code='G3'],
.gate-card[data-gate-code='G3'] { border-top-color: var(--gate-g3); background: var(--gate-g3-lt); }
.gate-card.phase-CREATE[data-gate-code='G4'],
.gate-card[data-gate-code='G4'] { border-top-color: var(--gate-g4); background: var(--gate-g4-lt); }
.gate-card.phase-DELIVER[data-gate-code='G5'],
.gate-card[data-gate-code='G5'] { border-top-color: var(--gate-g5); background: var(--gate-g5-lt); }
.gate-card.phase-DELIVER[data-gate-code='↻'],
.gate-card[data-gate-code='↻'] { border-top-color: var(--gate-loop); background: var(--gate-loop-lt); }

.gate-card[data-gate-code='G1'] .gate-code-label { color: var(--gate-g2); }
.gate-card[data-gate-code='G2'] .gate-code-label { color: var(--gate-g2); }
.gate-card[data-gate-code='G3'] .gate-code-label { color: var(--gate-g4); }
.gate-card[data-gate-code='G4'] .gate-code-label { color: var(--gate-g5); }
.gate-card[data-gate-code='G5'] .gate-code-label { color: var(--gate-g5); }
.gate-card[data-gate-code='↻'] .gate-code-label { color: var(--gate-loop); }

/* Inline gate tile that appears as the first tile in each step’s section grid.
   Matches the top-row gate card for the same gate. */
.sec-tile.gate-tile {
  border-style: solid;
  border-top-width: 4px;
}
.sec-tile.gate-tile .sec-code {
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.sec-tile.gate-tile .sec-label {
  font-weight: 700;
}

.sec-tile.gate-tile[data-gate-code='G1'] { border-top-color: var(--gate-g1); background: var(--gate-g1-lt); }
.sec-tile.gate-tile[data-gate-code='G2'] { border-top-color: var(--gate-g2); background: var(--gate-g2-lt); }
.sec-tile.gate-tile[data-gate-code='G3'] { border-top-color: var(--gate-g3); background: var(--gate-g3-lt); }
.sec-tile.gate-tile[data-gate-code='G4'] { border-top-color: var(--gate-g4); background: var(--gate-g4-lt); }
.sec-tile.gate-tile[data-gate-code='G5'] { border-top-color: var(--gate-g5); background: var(--gate-g5-lt); }
.sec-tile.gate-tile[data-gate-code='↻'] { border-top-color: var(--gate-loop); background: var(--gate-loop-lt); }

.sec-tile.gate-tile[data-gate-code='G1'] .sec-code { color: var(--gate-g2); }
.sec-tile.gate-tile[data-gate-code='G2'] .sec-code { color: var(--gate-g2); }
.sec-tile.gate-tile[data-gate-code='G3'] .sec-code { color: var(--gate-g4); }
.sec-tile.gate-tile[data-gate-code='G4'] .sec-code { color: var(--gate-g5); }
.sec-tile.gate-tile[data-gate-code='G5'] .sec-code { color: var(--gate-g5); }
.sec-tile.gate-tile[data-gate-code='↻'] .sec-code { color: var(--gate-loop); }

.gates-header {
  margin-bottom: 22px;
  max-width: 900px;
}

.gates-eyebrow {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 8px;
}

.gates-title {
  font-family: 'Instrument Serif', Georgia, serif;
  font-size: 32px;
  line-height: 1.1;
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin-bottom: 10px;
}

.gates-sub {
  font-size: 15px;
  color: var(--ink-2);
  line-height: 1.55;
}

.gates-row {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 12px;
  position: relative;
  align-items: stretch;
}

.gate-focus {
  font-size: 12px;
  color: var(--ink-2);
  line-height: 1.4;
  margin-top: 6px;
  padding-top: 6px;
  border-top: 1px dashed var(--line);
  width: 100%;
  flex: 1 1 auto;
}

.gate-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
  position: relative;
  display: grid;
  grid-template-rows:
    auto              /* code label (G1 / G2 / ↻ Loop) */
    2.4em             /* gate name — fixed for alignment */
    1fr;              /* decision text at bottom */
  gap: 8px;
  align-items: start;
  border-top: 4px solid;
  text-align: left;
  font: inherit;
  color: inherit;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.gate-card > * {
  text-align: left;
  width: 100%;
}

.gate-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(28, 27, 25, 0.08);
  border-color: var(--ink-3);
}

.gate-card:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

.gate-card:hover .click-badge {
  opacity: 1;
}

.checklist-lead {
  font-size: 13px;
  color: var(--ink-2);
  margin: 0 0 10px 0;
  line-height: 1.5;
}

.gate-card.phase-DEFINE {
  border-top-color: var(--green);
}
.gate-card.phase-CREATE {
  border-top-color: var(--blue);
}
.gate-card.phase-DELIVER {
  border-top-color: var(--navy);
}

.gate-code-label {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
  min-height: 16px;
  margin-bottom: 8px;
  text-align: left;
}

.gate-card.phase-DEFINE .gate-code-label {
  color: var(--green-dk);
}
.gate-card.phase-CREATE .gate-code-label {
  color: var(--blue-dk);
}
.gate-card.phase-DELIVER .gate-code-label {
  color: var(--navy);
}

.gate-name {
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.005em;
  line-height: 1.2;
  margin-bottom: 0;
  text-align: left;
  min-height: calc(16px * 1.2);
}

.gate-owner,
.gate-approvers {
  font-size: 12px;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.3;
  margin-bottom: 4px;
}

.gate-approvers {
  margin-bottom: 10px;
  font-weight: 500;
  color: var(--ink-2);
}

.gate-tag {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-right: 4px;
}

.gate-decision {
  font-size: 11.5px;
  color: var(--ink-2);
  line-height: 1.4;
  padding-top: 10px;
  border-top: 1px dashed var(--line);
}

/* ---------- Phase detail overlay ---------- */
.overlay-purpose.phase-overlay {
  font-size: 24px;
}

.phase-detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  margin-bottom: 22px;
}

.phase-detail-card {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 20px;
}

.phase-detail-card.accent-define {
  border-left: 3px solid var(--green);
}
.phase-detail-card.accent-create {
  border-left: 3px solid var(--blue);
}
.phase-detail-card.accent-deliver {
  border-left: 3px solid var(--navy);
}

.phase-detail-card h3 {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 10px;
}

.phase-detail-card p {
  font-size: 14px;
  color: var(--ink-2);
  line-height: 1.55;
}

.phase-substeps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
  margin-top: 8px;
}

.phase-substep-mini {
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.15s ease;
}

.phase-substep-mini:hover {
  background: var(--bg);
  transform: translateX(2px);
}

.phase-substep-mini .letter {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  color: white;
  font-weight: 700;
  font-size: 12px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.phase-substep-mini.define .letter {
  background: var(--green);
}
.phase-substep-mini.create .letter {
  background: var(--blue);
}
.phase-substep-mini.deliver .letter {
  background: var(--navy);
}

.phase-substep-mini .name {
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: 0.04em;
}

.phase-substep-mini .caret {
  margin-left: auto;
  color: var(--ink-3);
  font-size: 14px;
}

/* ---------- Responsive ---------- */
@media (max-width: 1200px) {
  .steps {
    grid-template-columns: repeat(3, 1fr);
  }
  .gates-row {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 900px) {
  .steps {
    grid-template-columns: repeat(2, 1fr);
  }
  .gates-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 1200px) {
  .phase-strip {
    grid-template-columns: 1fr;
  }
  .overlay-grid {
    grid-template-columns: 1fr 1fr;
  }
  .overlay-meta {
    grid-template-columns: repeat(3, 1fr);
  }
  .overlay-meta-item:nth-child(3n) {
    border-right: none;
  }
  .phase-detail-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .container {
    padding: 24px 16px 40px;
  }
  h1 {
    font-size: 30px;
  }
  .gates-row {
    grid-template-columns: 1fr 1fr;
  }
  .steps {
    grid-template-columns: 1fr;
  }
  .overlay-grid {
    grid-template-columns: 1fr;
  }
  .overlay-meta {
    grid-template-columns: 1fr 1fr;
  }
  .overlay-meta-item {
    border-right: none;
    border-bottom: 1px solid var(--line);
  }
  .overlay {
    width: calc(100vw - 16px);
    max-height: calc(100vh - 16px);
  }
  .overlay-body {
    padding: 20px;
  }
  .overlay-header {
    padding: 18px 20px;
  }
}

/* ============================================================
   Password gate (auth.js) — convenience lock, not security
   ============================================================ */
body.pdlc-locked #page-root {
  display: none;
}

body.pdlc-locked {
  background: var(--bg);
}

#pdlc-gate {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  padding: 24px;
}

.pdlc-gate-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(28, 27, 25, 0.55);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.pdlc-gate-card {
  position: relative;
  width: min(430px, 100%);
  background: var(--surface);
  border-radius: 16px;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.pdlc-gate-bar {
  height: 6px;
  background: linear-gradient(90deg, var(--green) 0%, var(--blue) 55%, var(--navy) 100%);
}

.pdlc-gate-inner {
  padding: 28px 30px 24px;
}

.pdlc-gate-mark {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: var(--green-lt);
  color: var(--green-dk);
  display: grid;
  place-items: center;
  margin-bottom: 16px;
}

.pdlc-gate-mark svg {
  width: 22px;
  height: 22px;
}

.pdlc-gate-eyebrow {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 6px;
}

.pdlc-gate-title {
  font-family: 'Instrument Serif', Georgia, serif;
  font-size: 27px;
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin-bottom: 8px;
}

.pdlc-gate-sub {
  font-size: 14px;
  color: var(--ink-2);
  line-height: 1.5;
  margin-bottom: 18px;
}

.pdlc-gate-label {
  display: block;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 6px;
}

.pdlc-gate-input {
  width: 100%;
  font-family: inherit;
  font-size: 15px;
  color: var(--ink);
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-2);
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.pdlc-gate-input:focus {
  border-color: var(--green-dk);
  box-shadow: 0 0 0 3px rgba(118, 185, 66, 0.18);
}

.pdlc-gate-error {
  min-height: 18px;
  font-size: 12.5px;
  font-weight: 600;
  color: #a12c7b;
  margin-top: 7px;
}

.pdlc-gate-submit {
  width: 100%;
  margin-top: 6px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  color: white;
  background: var(--navy);
  border: none;
  border-radius: var(--radius);
  padding: 11px 16px;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.15s ease;
}

.pdlc-gate-submit:hover {
  background: var(--navy-dk);
  transform: translateY(-1px);
}

.pdlc-gate-note {
  margin-top: 14px;
  font-size: 11px;
  color: var(--ink-3);
  line-height: 1.4;
}

@keyframes pdlc-shake {
  10%, 90% { transform: translateX(-2px); }
  20%, 80% { transform: translateX(4px); }
  30%, 50%, 70% { transform: translateX(-7px); }
  40%, 60% { transform: translateX(7px); }
}

.pdlc-gate-card.shake {
  animation: pdlc-shake 0.5s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
}

@media (prefers-reduced-motion: reduce) {
  .pdlc-gate-card.shake {
    animation: none;
  }
}

/* ============================================================
   Top nav bar (process.html + brief.html)
   ============================================================ */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 90;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}

.site-nav-inner {
  max-width: 1720px;
  margin: 0 auto;
  padding: 10px 40px;
  height: 54px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.nav-home {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-2);
  text-decoration: none;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.nav-home:hover {
  color: var(--green-dk);
}

.nav-pills {
  display: flex;
  gap: 8px;
  flex-wrap: nowrap;
}

.nav-pill {
  font-size: 12.5px;
  font-weight: 600;
  text-decoration: none;
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--ink-2);
  background: var(--surface);
  white-space: nowrap;
  transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}

.nav-pill:hover {
  border-color: var(--green-dk);
  color: var(--green-dk);
}

.nav-pill.is-active {
  background: var(--navy);
  border-color: var(--navy);
  color: white;
}

.nav-pill.is-active:hover {
  background: var(--navy-dk);
  color: white;
}

/* ============================================================
   Landing page — executive summary quadrants
   ============================================================ */
.container.landing {
  max-width: 1440px;
}

/* On the landing page, keep the top nav aligned to the same 1440px content width. */
body:has(.container.landing) .site-nav-inner {
  max-width: 1440px;
}

.landing-header {
  margin-bottom: 30px;
  max-width: 1180px;
}

.landing-header h1 {
  font-size: 40px;
  line-height: 1.12;
  margin-bottom: 0;
}

.quad-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 26px 30px;
  align-items: stretch;
}

.quad {
  display: flex;
  flex-direction: column;
}

.quad-bar {
  background: var(--green-lt);
  border-left: 5px solid var(--green);
  border-radius: 4px;
  padding: 11px 16px;
  margin-bottom: 10px;
}

.quad-bar h2 {
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--ink);
  text-transform: uppercase;
}

.quad-body {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 22px 22px;
  flex: 1;
  box-shadow: var(--shadow-sm);
}

.quad-question {
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 14px;
}

.quad-lede {
  font-size: 14.5px;
  line-height: 1.55;
  color: var(--ink-2);
  margin-bottom: 16px;
}

.quad-list {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 13px;
}

.quad-list .quad-text {
  font-size: 14.5px;
  line-height: 1.5;
  color: var(--ink-2);
}

.quad-list .quad-text strong {
  color: var(--ink);
  font-weight: 700;
}

.quad-list .quad-text em {
  color: var(--ink-3);
  font-style: italic;
}

.icon-list li {
  display: grid;
  grid-template-columns: 26px 1fr;
  gap: 12px;
  align-items: start;
}

.quad-icon {
  color: var(--green-dk);
  display: block;
  padding-top: 1px;
}

.quad-icon svg {
  width: 22px;
  height: 22px;
  display: block;
}

.dot-list li {
  position: relative;
  padding-left: 15px;
}

.dot-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 9px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--green-dk);
}

/* inline text hyperlinks inside quadrant copy */
a.inline-link {
  color: var(--green-dk);
  font-weight: 700;
  text-decoration: none;
  border-bottom: 1.5px solid rgba(78, 143, 39, 0.35);
  padding-bottom: 1px;
  transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

a.inline-link:hover,
a.inline-link:focus-visible {
  color: var(--navy);
  border-bottom-color: var(--navy);
  background: var(--green-lt);
}

/* progress / next steps columns */
.progress-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}

.progress-col-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: 0.02em;
  margin-bottom: 12px;
}

.status-list {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 11px;
}

.status-list li {
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 10px;
  align-items: start;
  font-size: 14px;
  line-height: 1.4;
  color: var(--ink-2);
}

.status-mark {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: block;
  margin-top: 1px;
  flex-shrink: 0;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 11px 11px;
}

.status-list.done .status-mark {
  background-color: var(--blue);
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'><path d='M4 12.5l5 5L20 6.5'/></svg>");
}

.status-list.pending .status-mark {
  background-color: #c9c7c1;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.4' stroke-linecap='round'><path d='M5 12h14'/></svg>");
}

.status-list li.is-next {
  color: var(--ink);
}

.status-list li.is-next strong {
  font-weight: 700;
}

.status-list li.is-next em {
  font-style: italic;
}

.next-text::after {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  margin-left: 7px;
  vertical-align: 2px;
}

.status-list.pending li.is-next .status-mark {
  background-color: var(--green);
}

/* CTA strip */
.cta-strip {
  margin-top: 56px;
  padding-top: 40px;
  border-top: 1px solid var(--line);
}

.cta-head {
  margin-bottom: 20px;
}

.cta-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.cta-card {
  display: block;
  text-decoration: none;
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 4px solid var(--green);
  border-radius: var(--radius);
  padding: 22px 24px 20px;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.cta-card.deliver {
  border-top-color: var(--navy);
}

.cta-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.cta-kicker {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 8px;
}

.cta-title {
  font-family: 'Instrument Serif', Georgia, serif;
  font-size: 27px;
  line-height: 1.1;
  color: var(--ink);
  margin-bottom: 10px;
}

.cta-sub {
  font-size: 14px;
  color: var(--ink-2);
  line-height: 1.55;
  margin-bottom: 14px;
}

.cta-go {
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--green-dk);
}

.cta-card.deliver .cta-go {
  color: var(--navy);
}

/* ============================================================
   Brief page — 30 section tiles grouped by step
   ============================================================ */
.rapid-intro-card {
  margin-top: 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 3px solid var(--navy);
  border-radius: var(--radius);
  padding: 16px 20px;
  width: 100%;
}

.rapid-intro-label {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 8px;
}

.rapid-intro-card p {
  font-size: 14px;
  color: var(--ink-2);
  line-height: 1.55;
  margin: 12px 0 0 0;
  padding-top: 12px;
  border-top: 1px dashed var(--line);
}

.rapid-key {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  margin-top: 0;
  padding-top: 0;
  border-top: none;
  font-size: 13px;
  color: var(--ink-2);
}

.rapid-key strong {
  color: var(--navy);
  font-weight: 800;
  margin-right: 3px;
}

.step-group {
  margin-top: 34px;
}

.step-group-head {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.step-group .step-letter {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  color: white;
  font-weight: 700;
  font-size: 13px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.step-group[data-phase='DEFINE'] .step-letter {
  background: var(--green);
}
.step-group[data-phase='CREATE'] .step-letter {
  background: var(--blue);
}
.step-group[data-phase='DELIVER'] .step-letter {
  background: var(--navy);
}

.step-group-label {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--ink);
}

.step-group-sub {
  font-size: 13px;
  font-style: italic;
  color: var(--ink-2);
}

.step-group-meta {
  margin-left: auto;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.step-group-intro {
  font-size: 13.5px;
  color: var(--ink-2);
  line-height: 1.55;
  margin: 12px 0 14px;
  max-width: 1080px;
}

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

.sec-tile {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px 11px 9px;
  text-align: left;
  font-family: inherit;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-height: 130px;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

/* Row alignment: give each row a consistent header height and a common blurb height
   so tiles across a Master-Product-Brief step group line up cleanly. */
.sec-tile .sec-tile-top { min-height: 18px; }
.sec-tile .sec-label { min-height: 2.5em; }
.sec-tile .sec-blurb { flex: 1; }

.sec-tile:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.sec-tile[data-phase='DEFINE']:hover {
  border-color: var(--green-dk);
}
.sec-tile[data-phase='CREATE']:hover {
  border-color: var(--blue-dk);
}
.sec-tile[data-phase='DELIVER']:hover {
  border-color: var(--navy);
}

.sec-tile-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.sec-code {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--ink-3);
}

.sec-tile[data-phase='DEFINE'] .sec-code {
  color: var(--green-dk);
}
.sec-tile[data-phase='CREATE'] .sec-code {
  color: var(--blue-dk);
}
.sec-tile[data-phase='DELIVER'] .sec-code {
  color: var(--navy);
}

.sec-label {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.22;
}

.sec-blurb {
  font-size: 10.5px;
  line-height: 1.35;
  color: var(--ink-2);
  margin-top: 2px;
}

.sec-owner {
  margin-top: auto;
  padding-top: 6px;
  border-top: 1px dashed var(--line);
  font-size: 10.5px;
  color: var(--ink-3);
}

.sec-owner strong {
  color: var(--ink-2);
  font-weight: 700;
}

.flag-badge {
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 2px 7px;
  border-radius: 999px;
  white-space: nowrap;
}

.flag-badge.flag-new {
  background: var(--green-lt);
  color: var(--green-dk);
}

.flag-badge.flag-cond {
  background: var(--gold-lt);
  color: #8a5a06;
}

.flag-callout {
  border-radius: var(--radius);
  padding: 12px 16px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 22px;
}

.flag-callout.flag-new {
  background: var(--green-lt);
  border: 1px solid rgba(78, 143, 39, 0.4);
  color: var(--green-dk);
}

.flag-callout.flag-cond {
  background: var(--gold-lt);
  border: 1px solid #e6bd6c;
  color: #8a5a06;
}

/* overlay extras used by brief-app.js */
.overlay-card.accent-neutral {
  border-left: 3px solid var(--ink-3);
}

.overlay-grid.two-up {
  grid-template-columns: 1fr 1fr;
}

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

ul.checklist li {
  position: relative;
  padding-left: 26px;
  font-size: 13.5px;
  color: var(--ink-2);
  line-height: 1.5;
}

ul.checklist li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 2px;
  width: 15px;
  height: 15px;
  border: 1.5px solid var(--ink-3);
  border-radius: 3px;
  background: var(--surface);
}

.decision-line {
  background: var(--navy-lt);
  border: 1px solid rgba(0, 53, 95, 0.28);
  border-radius: var(--radius);
  padding: 12px 16px;
  font-size: 13.5px;
  color: var(--ink);
  line-height: 1.5;
  margin-bottom: 22px;
}

.decision-tag {
  display: inline-block;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--navy);
  margin-right: 8px;
}

.step-context-note {
  margin-top: 4px;
  font-size: 13px;
  color: var(--ink-3);
  line-height: 1.55;
  padding-top: 16px;
  border-top: 1px dashed var(--line);
}

.phase-step-block {
  margin-top: 14px;
}

.phase-step-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.phase-step-head .letter {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  color: white;
  font-weight: 700;
  font-size: 12px;
  display: grid;
  place-items: center;
}

.phase-step-head .letter.define {
  background: var(--green);
}
.phase-step-head .letter.create {
  background: var(--blue);
}
.phase-step-head .letter.deliver {
  background: var(--navy);
}

.phase-step-head .name {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--ink);
}

.phase-step-head .gate {
  margin-left: auto;
  font-size: 11px;
  font-weight: 600;
  color: var(--ink-3);
}

.phase-section-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 8px;
}

.phase-section-link {
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 9px 11px;
  font-family: inherit;
  font-size: 12.5px;
  color: var(--ink-2);
  text-align: left;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 7px;
  transition: background 0.15s ease, transform 0.15s ease;
}

.phase-section-link:hover {
  background: var(--bg);
  transform: translateX(2px);
}

.phase-section-link .c {
  font-weight: 800;
  color: var(--ink-3);
}

.phase-section-link .caret {
  margin-left: auto;
  color: var(--ink-3);
}

/* ---------- Responsive: new components ---------- */
@media (max-width: 1400px) {
  .sec-grid {
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 6px;
  }
  .sec-tile { padding: 8px 9px 8px; min-height: 128px; }
  .sec-label { font-size: 11.5px; }
  .sec-blurb { font-size: 10px; }
  .sec-owner { font-size: 10px; }
}

@media (max-width: 1100px) {
  .sec-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .quad-grid {
    grid-template-columns: 1fr;
  }
  .cta-cards {
    grid-template-columns: 1fr;
  }
  .site-nav-inner {
    padding: 10px 24px;
  }
  .overlay-grid.two-up {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .landing-header h1 {
    font-size: 29px;
  }
  .sec-grid {
    grid-template-columns: 1fr 1fr;
  }
  .progress-cols {
    grid-template-columns: 1fr;
  }
  .site-nav-inner {
    padding: 8px 16px;
    height: auto;
    min-height: 54px;
    flex-wrap: wrap;
    gap: 8px;
  }
  .nav-pills {
    flex-wrap: wrap;
    row-gap: 6px;
  }
  .nav-pill {
    font-size: 11.5px;
    padding: 6px 11px;
  }
  .step-group-meta {
    margin-left: 0;
    width: 100%;
  }
  .pdlc-gate-inner {
    padding: 22px 20px 20px;
  }
  .pdlc-gate-title {
    font-size: 23px;
  }
}

@media (max-width: 720px) {
  .overlay-title {
    font-size: 19px;
    line-height: 1.2;
  }
  .overlay-subtitle {
    font-size: 12.5px;
  }
  .overlay-header {
    align-items: flex-start;
  }
}

/* Mobile: neutralize inline `grid-column: span 2` on overlay cards so the
   single-column grid doesn't create a squeezed implicit second column. */
@media (max-width: 720px) {
  .overlay-grid > .overlay-card {
    grid-column: auto !important;
  }
}

/* Toolset solution-set line: fits on one line, flush left, no hanging indent */
.quad-list .quad-text {
  container-type: inline-size;
  display: block;
}

.quad-list .quad-text .toolset-line {
  display: block;
  white-space: nowrap;
  font-size: min(14.5px, 2.65cqw);
  line-height: 1.5;
  text-indent: 0;
  padding-left: 0;
  margin-left: 0;
}

@media (max-width: 640px) {
  .quad-list .quad-text .toolset-line {
    white-space: normal;
    font-size: 13px;
  }
}

/* Download link inside .hint pill (process + brief pages) */
.hint .hint-link {
  color: var(--ink-2);
  text-decoration: none;
  font-weight: 600;
}
.hint .hint-link:hover {
  color: var(--green-dk);
}

/* ============ AI Toolkit page ============ */
.tk-panels {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 26px 30px;
  align-items: stretch;
}

.tk-panels > .quad {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.tk-panels > .quad > .quad-bar {
  flex: 0 0 auto;
}

.tk-panels > .quad > .quad-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.tk-figure {
  justify-content: flex-start;
  container-type: inline-size;
  width: 100%;
  text-align: left;
  font: inherit;
  cursor: zoom-in;
  padding: 18px 22px 22px;
  position: relative;
  text-decoration: none;
  color: inherit;
}

.tk-figure img {
  display: block;
  margin-bottom: 14px;
  width: 100%;
  height: auto;
}

.tk-figure .tk-tile-cue {
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.tk-tile {
  transition: border-color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.tk-tile:hover,
.tk-tile:focus-visible {
  border-color: var(--green);
  box-shadow: 0 10px 24px rgba(28, 27, 25, 0.1);
  transform: translateY(-2px);
}

.tk-tile-cue {
  display: block;
  margin-top: 10px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--green-dk);
}

.tk-tile:hover .tk-tile-cue {
  color: var(--navy);
}

/* Define / Create / Deliver bars above the six sub-steps */
.tk-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.42%;
  margin-bottom: 0.42%;
}

.tk-step {
  display: flex;
  align-items: center;
  gap: 10px;
  border-radius: 4px;
  padding: 0.55em 0.8em;
  color: #fff;
  font-family: 'Inter', sans-serif;
  font-size: clamp(8px, 2.45cqw, 17px);
  font-weight: 700;
  letter-spacing: 0.04em;
}

.tk-step i {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.75em;
  height: 1.75em;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.24);
  border: 1.5px solid rgba(255, 255, 255, 0.85);
  font-style: normal;
  font-size: 0.8em;
  font-weight: 700;
}

.tk-step.s-define {
  background: var(--green);
}
.tk-step.s-create {
  background: var(--blue);
}
.tk-step.s-deliver {
  background: var(--navy);
}

/* Logo wall — two columns, Power BI centered on its own row (per mockup) */
.tk-logos {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  align-items: center;
  justify-items: center;
  gap: 8px 24px;
  margin: 14px 0 4px;
  padding: 12px 6px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.tk-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 34px;
  width: 100%;
}

.tk-logo img {
  display: block;
  width: auto;
  height: 30px;
  max-width: 100%;
  object-fit: contain;
}

.tk-logo-figma img {
  height: 26px;
}

.tk-logo-ado img {
  height: 32px;
}

.tk-logo-pbi {
  grid-column: 1 / -1;
  gap: 12px;
}

.tk-logo-pbi img {
  height: 26px;
}

.tk-logo-pbi span {
  font-family: 'Inter', sans-serif;
  font-size: 22px;
  font-weight: 500;
  color: #252423;
  line-height: 1;
}

/* Single-line header for the long mapping title */
.quad-bar {
  container-type: inline-size;
}

/* all four toolkit headers share one size and stay on one line */
.tk-panels .quad-bar h2 {
  white-space: nowrap;
  font-size: max(12.3px, min(15px, 2.6cqw));
  letter-spacing: 0.012em;
}

/* Lightbox */
.tk-lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 28px;
  background: rgba(16, 15, 14, 0.82);
  cursor: zoom-out;
}

.tk-lightbox[hidden] {
  display: none;
}

.tk-lb-inner {
  container-type: inline-size;
  width: min(1500px, 96vw);
  max-height: 92vh;
  overflow: auto;
  background: #fff;
  border-radius: 6px;
  padding: 16px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}

.tk-lb-inner img {
  display: block;
  width: 100%;
  height: auto;
}

.tk-lb-close {
  position: absolute;
  top: 16px;
  right: 22px;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
}

.tk-lb-close:hover {
  background: rgba(255, 255, 255, 0.28);
}

@media (max-width: 720px) {
  .tk-logos {
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
  }
  .tk-logo img {
    height: 32px;
  }
  .tk-logo-pbi img {
    height: 27px;
  }
  .tk-logo-pbi span {
    font-size: 21px;
  }
  .tk-step {
    padding: 7px 9px;
    letter-spacing: 0.02em;
  }
  .tk-figure {
    padding: 14px 16px 16px;
  }
}

@media (max-width: 1099px) {
  .tk-panels {
    grid-template-columns: 1fr;
  }

  .tk-panels .quad-bar h2 {
    white-space: normal;
    font-size: 15px;
  }

  .tk-logo img {
    height: 34px;
  }

  .tk-logo-figma img {
    height: 29px;
  }

  .tk-logo-ado img {
    height: 36px;
  }

  .tk-logo-pbi img {
    height: 29px;
  }

  .tk-logo-pbi span {
    font-size: 24px;
  }
}

/* ---- AI Toolkit: download button inside the PDLC Overview tile ---- */
.tk-ov-dl {
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.tk-ov-dl .hint {
  margin-top: 12px;
}
.hint.tk-dl-sm {
  padding: 6px 13px;
  font-size: 12.5px;
  gap: 8px;
  align-self: flex-start;
}
.hint.tk-dl-sm svg {
  width: 13px;
  height: 13px;
}

/* ---- AI Toolkit: "Where the toolkit plugs in" tile ---- */
.quad-body.tk-plug {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 18px 22px 22px;
}
.tk-plug .cta-card {
  flex: 1 1 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 16px 20px 15px;
  min-width: 0;
}
.tk-plug .cta-title {
  font-size: 25px;
  margin-bottom: 8px;
}
.tk-plug .cta-sub {
  margin-bottom: 12px;
}
@media (max-width: 1099px) {
  .tk-plug .cta-card {
    padding: 18px 20px 16px;
  }
}
