/* ============================================================
   WEB OPTIMISATION — Deck 08 (v3: real programme data)
   ============================================================ */

/* S2 Programme overview */
.stage-row {
  display: grid;
  grid-template-columns: 1fr 40px 1fr 40px 1fr;
  gap: 12px;
  align-items: stretch;
  margin-top: 36px;
}
.stage-tile {
  background: rgba(245,243,238,0.06);
  border: 1px solid rgba(245,243,238,0.10);
  border-radius: 8px;
  padding: 24px 22px;
}
.stage-tile.done { background: rgba(122,152,136,0.16); border-color: rgba(122,152,136,0.40); }
.stage-tile.doing { background: rgba(201,154,74,0.14); border-color: rgba(201,154,74,0.40); }
.st-num { font-size: 11px; letter-spacing: 0.20em; color: rgba(245,243,238,0.55); font-weight: 700; margin-bottom: 14px; }
.st-icon { width: 36px; height: 36px; margin-bottom: 14px; }
.st-icon .lucide { width: 32px; height: 32px; stroke: var(--ibp-sage); stroke-width: 1.7; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.stage-tile.doing .st-icon .lucide { stroke: #E0B66E; }
.st-name { font-size: 22px; font-weight: 700; letter-spacing: -0.012em; color: var(--ibp-cream); margin-bottom: 8px; }
.st-detail { font-size: 13px; color: rgba(245,243,238,0.65); line-height: 1.4; margin-bottom: 16px; }
.st-status { font-size: 10px; letter-spacing: 0.20em; text-transform: uppercase; font-weight: 700; display: flex; align-items: center; gap: 8px; color: var(--ibp-sage); }
.stage-tile.doing .st-status { color: #E0B66E; }
.stage-tile.next .st-status { color: rgba(245,243,238,0.55); }
.st-dot { width: 7px; height: 7px; border-radius: 50%; }
.done-dot { background: var(--ibp-sage); box-shadow: 0 0 0 3px rgba(122,152,136,0.25); }
.doing-dot { background: #E0B66E; box-shadow: 0 0 0 3px rgba(224,182,110,0.20); animation: doingPulse 2200ms ease-in-out infinite; }
.next-dot { background: rgba(245,243,238,0.40); }
@keyframes doingPulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(224,182,110,0.20); }
  50%      { box-shadow: 0 0 0 6px rgba(224,182,110,0.05); }
}
.stage-arrow { display: flex; align-items: center; justify-content: center; font-size: 24px; color: rgba(245,243,238,0.40); font-weight: 600; }

/* S3 Lucene grid + mega results */
.lucern-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 18px;
  margin-top: 32px;
}
.lucern-block {
  background: rgba(255,255,255,0.65);
  border: 1px solid rgba(26,25,21,0.08);
  border-radius: 8px;
  padding: 24px 26px;
}
.lb-eyebrow {
  font-size: 11px;
  letter-spacing: 0.20em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--ibp-forest);
  display: flex; align-items: center; gap: 8px;
  margin-bottom: 18px;
}
.lb-icon { width: 18px; height: 18px; stroke: var(--ibp-forest); stroke-width: 1.8; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.lb-list { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.lb-list li { font-size: 13px; line-height: 1.5; color: var(--ibp-ink); padding-left: 16px; position: relative; }
.lb-list li::before { content: '→'; position: absolute; left: 0; top: 0; color: var(--ibp-forest); font-weight: 700; }
.lb-list li strong { color: var(--ibp-forest); font-weight: 700; }
.result-mega {
  background: var(--ibp-forest);
  border-radius: 6px;
  padding: 18px 20px;
  margin-bottom: 12px;
  color: var(--ibp-cream);
}
.result-mega:last-child { margin-bottom: 0; }
.rm-row { display: flex; align-items: baseline; gap: 14px; margin-bottom: 6px; }
.rm-from { font-size: 28px; font-weight: 700; color: rgba(245,243,238,0.50); text-decoration: line-through; letter-spacing: -0.012em; }
.rm-arrow { font-size: 22px; color: var(--ibp-sage); font-weight: 700; }
.rm-to { font-size: 38px; font-weight: 800; color: var(--ibp-sage); letter-spacing: -0.022em; }
.rm-label { font-size: 12px; color: rgba(245,243,238,0.75); letter-spacing: 0.05em; }

/* S4 Hierarchy row */
.hierarchy-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-top: 32px;
}
.hier-tile {
  background: rgba(255,255,255,0.65);
  border: 1px solid rgba(26,25,21,0.08);
  border-radius: 8px;
  padding: 22px 20px;
  text-align: left;
}
.hier-tile.hero { background: var(--ibp-forest); border-color: var(--ibp-forest); }
.hier-tile.hero .hier-num, .hier-tile.hero .hier-label, .hier-tile.hero .hier-sub { color: var(--ibp-cream); }
.hier-tile.hero .hier-sub { color: rgba(245,243,238,0.7); }
.hier-num { font-size: 36px; font-weight: 700; letter-spacing: -0.022em; color: var(--ibp-forest); line-height: 1; font-variant-numeric: tabular-nums; }
.hier-label { font-size: 13px; font-weight: 700; letter-spacing: 0.04em; color: var(--ibp-ink); margin-top: 10px; }
.hier-sub { font-size: 11px; color: var(--ibp-ink-mut); margin-top: 4px; }

/* Filter mock */
.filter-mock {
  margin-top: 24px;
  background: rgba(255,255,255,0.65);
  border: 1px solid rgba(26,25,21,0.08);
  border-radius: 8px;
  padding: 20px 22px;
}
.fm-eyebrow {
  font-size: 10px;
  letter-spacing: 0.30em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--ibp-forest);
  margin-bottom: 16px;
}
.fm-body {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 24px;
}
.fm-tree { font-size: 13px; }
.fm-row { padding: 4px 0; color: var(--ibp-ink); display: flex; align-items: center; gap: 8px; }
.fm-row.indent { padding-left: 22px; }
.fm-row.indent2 { padding-left: 44px; color: var(--ibp-ink-mut); }
.fm-check { color: var(--ibp-forest); font-weight: 700; width: 16px; }
.fm-check.checked { color: var(--ibp-forest); }
.fm-count { color: var(--ibp-ink-mut); font-size: 11px; font-variant-numeric: tabular-nums; }
.fm-facets { display: flex; flex-direction: column; gap: 10px; }
.facet-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.facet-label { font-size: 11px; font-weight: 700; letter-spacing: 0.10em; text-transform: uppercase; color: var(--ibp-forest); width: 110px; }
.facet-chip {
  background: rgba(122,152,136,0.14);
  border: 1px solid rgba(61,93,74,0.20);
  border-radius: 12px;
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 600;
  color: var(--ibp-ink);
}
.facet-chip em { font-style: normal; color: var(--ibp-ink-mut); font-weight: 500; }

/* S5 Attribute library grid */
.attr-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 32px;
}
.attr-tile {
  background: rgba(245,243,238,0.06);
  border: 1px solid rgba(245,243,238,0.10);
  border-radius: 6px;
  padding: 16px 18px;
}
.attr-tile.hero { background: rgba(122,152,136,0.18); border-color: rgba(122,152,136,0.40); grid-column: span 3; }
.at-source { font-size: 13px; font-weight: 700; letter-spacing: -0.005em; color: var(--ibp-cream); margin-bottom: 6px; }
.attr-tile.hero .at-source { color: var(--ibp-sage); font-size: 15px; }
.at-stat { font-size: 11px; color: rgba(245,243,238,0.65); line-height: 1.4; font-variant-numeric: tabular-nums; }
.at-stat strong { color: var(--ibp-cream); }
.cw-line {
  margin-top: 16px;
  background: rgba(122,152,136,0.10);
  border: 1px dashed rgba(122,152,136,0.30);
  border-radius: 6px;
  padding: 14px 18px;
  display: flex;
  gap: 14px;
  align-items: center;
}
.cw-icon { width: 22px; height: 22px; stroke: var(--ibp-sage); stroke-width: 1.8; fill: none; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.cw-name { font-size: 13px; font-weight: 700; color: var(--ibp-cream); }
.cw-detail { font-size: 11px; color: rgba(245,243,238,0.65); margin-top: 3px; font-variant-numeric: tabular-nums; }

/* S6 Onboarding flow */
.onboarding-flow {
  display: grid;
  grid-template-columns: 1fr 24px 1fr 24px 1fr 24px 1fr;
  gap: 10px;
  margin-top: 32px;
  align-items: stretch;
}
.of-step {
  background: rgba(255,255,255,0.65);
  border: 1px solid rgba(26,25,21,0.08);
  border-radius: 8px;
  padding: 20px 18px;
}
.of-step.shipped { background: var(--ibp-forest); border-color: var(--ibp-forest); }
.of-step.shipped .of-num, .of-step.shipped .of-name, .of-step.shipped .of-detail { color: var(--ibp-cream); }
.of-step.shipped .of-num { color: rgba(245,243,238,0.55); }
.of-step.shipped .of-detail { color: rgba(245,243,238,0.75); }
.of-step.shipped .of-icon .lucide { stroke: var(--ibp-sage); }
.of-num { font-size: 11px; letter-spacing: 0.20em; color: var(--ibp-forest); font-weight: 700; margin-bottom: 12px; }
.of-icon { width: 28px; height: 28px; margin-bottom: 12px; }
.of-icon .lucide { width: 24px; height: 24px; stroke: var(--ibp-forest); stroke-width: 1.7; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.of-name { font-size: 15px; font-weight: 700; letter-spacing: -0.005em; color: var(--ibp-ink); margin-bottom: 8px; }
.of-detail { font-size: 11px; color: var(--ibp-ink-mut); line-height: 1.4; }
.of-arrow { display: flex; align-items: center; justify-content: center; font-size: 20px; color: var(--ibp-forest); font-weight: 700; }

.ai-stats {
  margin-top: 24px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}
.ai-stat {
  background: rgba(122,152,136,0.10);
  border: 1px dashed rgba(122,152,136,0.30);
  border-radius: 6px;
  padding: 14px 16px;
}
.as-figure { font-size: 22px; font-weight: 700; letter-spacing: -0.012em; color: var(--ibp-forest); line-height: 1; font-variant-numeric: tabular-nums; }
.as-label { font-size: 10px; color: var(--ibp-ink-mut); line-height: 1.45; margin-top: 6px; letter-spacing: 0.03em; }

/* S7 Archetypes + lift banner */
.archetype-row {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
  margin-top: 32px;
}
.arch-tile {
  background: rgba(255,255,255,0.65);
  border: 1px solid rgba(26,25,21,0.08);
  border-radius: 8px;
  padding: 16px 14px;
}
.ar-num { font-size: 11px; letter-spacing: 0.20em; color: var(--ibp-forest); font-weight: 700; margin-bottom: 8px; }
.ar-name { font-size: 13px; font-weight: 700; letter-spacing: -0.005em; color: var(--ibp-ink); margin-bottom: 6px; line-height: 1.3; }
.ar-note { font-size: 10px; color: var(--ibp-ink-mut); line-height: 1.4; }

.lift-banner {
  margin-top: 24px;
  background: var(--ibp-forest);
  border-radius: 8px;
  padding: 24px 28px;
  color: var(--ibp-cream);
}
.lb-line { display: flex; align-items: center; gap: 24px; }
.lb-figure { font-size: 56px; font-weight: 700; letter-spacing: -0.022em; color: var(--ibp-cream); line-height: 1; }
.lb-figure .unit { font-size: 18px; font-weight: 600; color: var(--ibp-sage); letter-spacing: 0; }
.lb-detail { flex: 1; }
.lb-label { font-size: 10px; letter-spacing: 0.30em; text-transform: uppercase; font-weight: 700; color: rgba(245,243,238,0.55); }
.lb-sub { font-size: 14px; color: rgba(245,243,238,0.85); margin-top: 6px; line-height: 1.4; }
.lb-prereq {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(245,243,238,0.10);
  font-size: 11px;
  color: rgba(245,243,238,0.65);
  font-style: italic;
}

/* S8 Compound row */
.compound-row {
  display: grid;
  grid-template-columns: 1fr 24px 1fr 24px 1fr 24px 1.1fr;
  gap: 10px;
  margin-top: 40px;
  align-items: stretch;
}
.compound-tile {
  background: rgba(255,255,255,0.65);
  border: 1px solid rgba(26,25,21,0.08);
  border-radius: 8px;
  padding: 22px 20px;
  text-align: center;
}
.compound-tile.total { background: var(--ibp-forest); border-color: var(--ibp-forest); }
.compound-tile.total .ct-stage, .compound-tile.total .ct-name, .compound-tile.total .ct-lift, .compound-tile.total .ct-note { color: var(--ibp-cream); }
.compound-tile.total .ct-stage { color: rgba(245,243,238,0.55); }
.compound-tile.total .ct-note { color: rgba(245,243,238,0.75); }
.ct-stage { font-size: 10px; letter-spacing: 0.20em; text-transform: uppercase; font-weight: 700; color: var(--ibp-forest); margin-bottom: 6px; }
.ct-name { font-size: 14px; font-weight: 700; letter-spacing: -0.005em; color: var(--ibp-ink); margin-bottom: 14px; }
.ct-lift { font-size: 32px; font-weight: 700; letter-spacing: -0.022em; color: var(--ibp-forest); line-height: 1; margin-bottom: 6px; }
.ct-note { font-size: 10px; color: var(--ibp-ink-mut); line-height: 1.4; }
.ct-plus, .ct-equals { display: flex; align-items: center; justify-content: center; font-size: 22px; color: var(--ibp-forest); font-weight: 600; }

/* Mobile */
@media (max-width: 980px) {
  .stage-row { grid-template-columns: 1fr; gap: 14px; }
  .stage-arrow { transform: rotate(90deg); margin: 0 auto; }
  .lucern-grid { grid-template-columns: 1fr; }
  .hierarchy-row { grid-template-columns: repeat(2, 1fr); }
  .fm-body { grid-template-columns: 1fr; }
  .attr-grid { grid-template-columns: 1fr; }
  .attr-tile.hero { grid-column: span 1; }
  .onboarding-flow { grid-template-columns: 1fr; }
  .of-arrow { transform: rotate(90deg); margin: 0 auto; }
  .ai-stats { grid-template-columns: repeat(2, 1fr); }
  .archetype-row { grid-template-columns: repeat(2, 1fr); }
  .lb-line { flex-direction: column; align-items: flex-start; }
  .compound-row { grid-template-columns: 1fr; gap: 14px; }
  .ct-plus, .ct-equals { transform: rotate(90deg); margin: 0 auto; }
}
