/* =========================================================================
   Enso Dynamics — the inner pages' layout (site redesign, phase 2)
   The technical leadership, SDLC transformation, case study, privacy and
   missing pages. The palette, header, footer, buttons and section grounds
   come from site.css; the case study's charts and method diagram are in
   case-study.css, linked after this file.
   ========================================================================= */

/* Each ground sets the text, rule, accent and illustration colors its content uses, so the same
   component reads on cream or white and on navy or the dark gradient. A light card inside a dark
   section takes a light ground class and gets the light set back. */
main, .ground-cream, .ground-paper, .ground-white {
  --text: var(--ink);
  --text-body: var(--ink-body);
  --text-soft: var(--ink-soft);
  --rule: rgba(20, 23, 28, 0.2);
  --accent: var(--gold-text);
  --mark: var(--gold-line);
  --emphasis: var(--navy);
  --tile-bg: var(--white);
  --tile-line: transparent;
  --tint-1: var(--navy);
  --tint-2: rgba(20, 23, 28, 0.46);
  --tint-3: rgba(20, 23, 28, 0.24);
  --tint-4: rgba(20, 23, 28, 0.12);
}
.ground-navy, .ground-gradient {
  --text: var(--ivory);
  --text-body: #C3CAD6;
  --text-soft: var(--ivory-cool);
  --rule: rgba(242, 237, 227, 0.3);
  --accent: var(--gold);
  --mark: var(--gold);
  --emphasis: var(--gold);
  --tile-bg: rgba(8, 16, 30, 0.62);
  --tile-line: rgba(242, 237, 227, 0.14);
  --tint-1: var(--ivory);
  --tint-2: rgba(242, 237, 227, 0.56);
  --tint-3: rgba(242, 237, 227, 0.3);
  --tint-4: rgba(242, 237, 227, 0.16);
}

main { line-height: 1.6; }
main h1, main h2, main h3 { font-family: var(--serif); font-weight: 400; color: var(--text); }
main strong { font-weight: 600; color: var(--text); }
.nowrap { white-space: nowrap; }

/* ---------- Sections, titles and the labels that are kept ---------- */

.band { padding: clamp(72px, 7.4vw, 112px) 0; color: var(--text-body); }
.band > .shell { position: relative; }

/* A kept section label: small sentence case text after a short gold rule, as the homepage draws
   its assessment label (AC-LOOK-04, AC-PAGE-02). */
.section-label { display: flex; align-items: center; gap: 12px; font-size: 14.5px; font-weight: 500; line-height: 1.5; color: var(--text-body); }
.section-label-line { flex: none; width: 28px; height: 2px; background: var(--mark); }
.section-label + .section-title, .section-label + .page-title { margin-top: 18px; }

.section-title { max-width: 22ch; font-size: clamp(36px, 4.6vw, 66px); line-height: 1.02; letter-spacing: -0.022em; text-wrap: balance; }
.section-title em, .page-title em { font-style: italic; color: var(--emphasis); }
.section-lead { margin-top: 26px; max-width: 60ch; font-size: clamp(17px, 1.4vw, 19px); line-height: 1.65; }
.note-label { font-size: 14px; font-weight: 600; line-height: 1.5; color: var(--text); }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 14px; margin-top: 36px; }
.split { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(340px, 100%), 1fr)); gap: 32px clamp(40px, 6vw, 96px); align-items: start; }
.split-end { align-items: end; }
.split .section-lead { margin-top: 0; }
.pair { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(420px, 100%), 1fr)); gap: 20px clamp(32px, 5vw, 72px); margin-top: 30px; }
.pair .section-lead { margin-top: 0; }

/* ---------- The opening band: dark blue gradient, the page's own headline ---------- */

.page-open { padding: clamp(52px, 5.6vw, 88px) 0 clamp(64px, 7vw, 104px); color: var(--text-body); }
.brush-open { right: clamp(-260px, -14vw, -110px); top: clamp(-330px, -19vw, -130px); width: clamp(340px, 46vw, 700px); opacity: 0.09; }
.brush-close { right: clamp(-200px, -8vw, -60px); bottom: clamp(-260px, -12vw, -110px); width: clamp(320px, 44vw, 640px); opacity: 0.12; }
.page-title { font-size: clamp(42px, 5.4vw, 78px); line-height: 0.98; letter-spacing: -0.026em; text-wrap: balance; }
.page-title .title-line { display: block; }
.page-lead { max-width: 58ch; font-size: clamp(18px, 1.5vw, 20.5px); line-height: 1.55; color: var(--text-body); }
.page-title + .page-lead { margin-top: 28px; }
.page-open-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(440px, 100%), 1fr)); gap: 44px clamp(40px, 6vw, 96px); align-items: start; margin-top: clamp(30px, 3.2vw, 48px); }

/* A dark card inside a dark section, as the homepage's sample results card. */
.panel { margin: 0; padding: clamp(20px, 2.6vw, 32px); background: rgba(8, 16, 30, 0.62); border: 1px solid rgba(242, 237, 227, 0.14); }

/* ---------- Tiles, points and steps ---------- */

.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(520px, 100%), 1fr)); gap: 20px; margin-top: clamp(36px, 4vw, 52px); }
.tiles-four { grid-template-columns: repeat(auto-fit, minmax(min(250px, 100%), 1fr)); }
.tiles-three { grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); }
.tile { padding: clamp(24px, 2.6vw, 36px); background: var(--tile-bg); border: 1px solid var(--tile-line); }
.tile-title { font-size: clamp(26px, 2.2vw, 30px); line-height: 1.08; letter-spacing: -0.012em; }
.tile-title + p { margin-top: 12px; }
.tile p { font-size: 15.5px; line-height: 1.6; }

.points { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: 36px clamp(28px, 3vw, 44px); margin-top: clamp(36px, 4vw, 52px); }
.point { padding-top: 22px; border-top: 1px solid var(--rule); }
.point h3 { font-size: clamp(26px, 2.2vw, 30px); line-height: 1.08; letter-spacing: -0.012em; }
.point p { margin-top: 12px; font-size: 15.5px; line-height: 1.6; }

.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(230px, 100%), 1fr)); gap: 36px 28px; margin-top: clamp(40px, 4.2vw, 60px); }
.step-item { display: flex; flex-direction: column; gap: 14px; }
.step-head { display: flex; align-items: center; gap: 12px; }
.step-num { flex: none; display: flex; align-items: center; justify-content: center; width: 44px; height: 44px; border: 1px solid var(--rule); border-radius: 50%; font-family: var(--serif); font-size: 24px; line-height: 1; color: var(--text); }
.step-item-accent .step-num { border-color: var(--mark); background: var(--mark); color: var(--black); }
.step-rule { flex: 1; height: 1px; background: var(--rule); }
.step-lanes { flex: 1; display: flex; flex-direction: column; gap: 4px; }
.step-lanes span { height: 2px; background: var(--mark); }
.step-lanes span:nth-child(2) { width: 80%; background: var(--tint-2); }
.step-lanes span:nth-child(3) { width: 92%; background: var(--tint-1); }
.step-title { font-size: 28px; line-height: 1.08; letter-spacing: -0.012em; }
.step-item p { font-size: 15.5px; line-height: 1.6; }

/* ---------- The closing call to action ---------- */

.close-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px 48px; }
.close-row .section-lead { margin-top: 14px; }

/* ---------- Technical leadership: where the leverage comes from ---------- */

.sum { display: flex; flex-direction: column; margin-top: 14px; }
.sum-row { display: grid; grid-template-columns: 104px minmax(0, 1fr); gap: 18px; align-items: center; padding: 14px 18px; border: 1px solid rgba(242, 237, 227, 0.16); background: rgba(242, 237, 227, 0.04); }
.sum-name { font-size: 16px; font-weight: 600; line-height: 1.3; color: var(--text); }
.sum-note { margin-top: 3px; font-size: 14px; line-height: 1.5; color: var(--text-soft); }
.sum-op { display: flex; align-items: center; justify-content: center; height: 26px; font-size: 22px; font-weight: 300; line-height: 1; color: var(--mark); }
.sum-more { margin-top: 10px; font-size: 15px; }
.icon-center { display: flex; justify-content: center; }
.icon-person { display: flex; align-items: flex-end; justify-content: center; width: 48px; height: 48px; border-radius: 50%; background: var(--tint-4); overflow: hidden; }
.icon-person svg { fill: var(--tint-1); }
.icon-doc { display: flex; flex-direction: column; gap: 5px; width: 46px; padding: 9px 8px; border: 1.5px solid var(--tint-1); border-radius: 2px; }
.icon-doc span { height: 3px; border-radius: 2px; background: var(--tint-3); }
.icon-doc span:nth-child(1) { width: 70%; height: 4px; background: var(--tint-1); }
.icon-doc span:nth-child(3) { width: 85%; }
.icon-doc span:nth-child(4) { width: 92%; background: var(--mark); }
.icon-doc span:nth-child(5) { width: 60%; }
.icon-split { display: flex; flex-direction: column; gap: 6px; }
.icon-split-whole { height: 12px; border-radius: 2px; background: var(--tint-3); }
.icon-split-arrow { display: flex; justify-content: center; color: var(--mark); }
.icon-lanes { display: flex; flex-direction: column; gap: 5px; }
.icon-lane-row { display: flex; align-items: center; gap: 5px; }
.icon-lane { flex: 1; display: flex; gap: 2px; height: 8px; }
.icon-split .icon-lane { flex: none; gap: 3px; height: 12px; }
.seg { flex-basis: 0; flex-shrink: 1; height: 100%; border-radius: 2px; background: var(--tint-2); }
.seg-1 { background: var(--tint-1); }
.seg-3 { background: var(--tint-3); }
.icon-check { flex: none; display: flex; align-items: center; justify-content: center; width: 13px; height: 13px; border-radius: 50%; background: var(--mark); color: var(--black); }
.icon-check-open { background: var(--tint-3); }

/* Technical leadership: the three situations it fits. */
.fit-list li { display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: 12px; align-items: baseline; padding: 22px 0; border-top: 1px solid var(--rule); font-size: 17px; line-height: 1.55; }
.fit-list li:last-child { border-bottom: 1px solid var(--rule); }
.fit-num { font-family: var(--serif); font-size: 26px; line-height: 1; color: var(--accent); }

/* Technical leadership: the same migration, a full team versus one engineer. */
.figure-card { margin: clamp(36px, 4vw, 52px) 0 0; padding: clamp(24px, 3.4vw, 44px); }
.compare-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 24px; }
.compare-title { font-size: 16.5px; font-weight: 600; color: var(--text); }
.compare-scale { font-family: var(--serif); font-style: italic; font-size: 18px; color: var(--text-soft); }
.compare-rows { display: flex; flex-direction: column; gap: 18px; margin-top: 28px; }
.compare-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; }
.compare-who { flex: 0 0 240px; }
.compare-name { font-size: 14.5px; font-weight: 600; line-height: 1.3; white-space: nowrap; color: var(--text-soft); }
.compare-name-lead { color: var(--navy); }
.compare-dots { display: flex; flex-wrap: wrap; gap: 3px; margin-top: 6px; }
.compare-dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--tint-3); }
.compare-dot-lead { background: var(--navy); }
.compare-one { display: flex; align-items: center; gap: 6px; margin-top: 6px; font-size: 13px; color: var(--text-soft); }
.compare-track { flex: 1 1 380px; min-width: 0; display: flex; align-items: center; gap: 12px; }
.compare-bar { height: 30px; border-radius: 2px; }
.compare-bar-stalled { display: flex; align-items: center; justify-content: flex-end; width: 100%; padding: 0 12px; background: repeating-linear-gradient(135deg, #CDD1D6 0, #CDD1D6 6px, #E1E4E8 6px, #E1E4E8 12px); }
.compare-bar-stalled span { padding: 2px 8px; border-radius: 2px; background: rgba(255, 255, 255, 0.92); font-size: 13px; font-weight: 600; color: var(--ink-body); }
.compare-bar-live { width: 16.7%; min-width: 44px; background: var(--navy); }
.compare-result { font-size: 13.5px; font-weight: 600; white-space: nowrap; color: var(--navy); }
.compare-axis { flex: 1 1 380px; min-width: 0; display: flex; justify-content: space-between; padding-top: 6px; border-top: 1px solid var(--rule); font-size: 12.5px; color: var(--text-soft); }

/* ---------- SDLC transformation ---------- */

/* AI bolted on, against the lifecycle rebuilt. */
.chip { display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 6px 12px; border-radius: 2px; font-size: 13.5px; font-weight: 500; line-height: 1.3; }
.chip-muted { border: 1px solid var(--tint-3); color: var(--text-soft); }
.chip-solid { background: var(--ivory); color: var(--black); }
.chip-accent { background: var(--gold); color: var(--black); }
.flow-arrow { flex: none; font-size: 16px; color: var(--tint-2); }
.flow-arrow-accent { color: var(--mark); }
.bolted { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 12px; }
.bolted-tools { display: flex; flex-direction: column; gap: 6px; }
.stage-box { width: 112px; padding: 10px 12px; border: 1px solid var(--tint-3); border-radius: 2px; }
.stage-box-name { font-size: 13px; font-weight: 600; color: var(--text); }
.stage-box-note { margin-top: 6px; font-size: 12.5px; color: var(--text-soft); }
.pile { display: flex; flex-direction: column; gap: 3px; margin-top: 8px; }
.pile span { height: 5px; border-radius: 2px; background: var(--tint-3); }
.pile .pile-over { width: 130%; background: var(--tint-1); }
.bugs { display: flex; gap: 5px; margin-top: 8px; }
.bugs span { width: 9px; height: 9px; border-radius: 50%; background: var(--tint-1); }
.rebuilt { margin-top: 26px; padding-top: 22px; border-top: 1px solid rgba(242, 237, 227, 0.16); }
.rebuilt-flow { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 12px; }

/* The line that sends a reader to the assessment: a sentence and a text link (AC-LOOK-05). */
.assess-line { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 40px; margin-top: clamp(40px, 4vw, 56px); padding-top: 22px; border-top: 1px solid var(--rule); font-size: 16.5px; line-height: 1.6; }
.assess-line a { flex: none; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; font-weight: 500; color: var(--link-fg); text-decoration: underline; text-decoration-color: var(--link-underline); text-underline-offset: 6px; }
.assess-line a:hover { color: var(--link-hover); }

/* Crawl, walk, run: three cards stepping up to the last. */
.stairs { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 16px; align-items: stretch; margin-top: clamp(40px, 4.2vw, 60px); }
.stair-card { padding: 28px 28px 30px; color: var(--text-body); }
.stair-card:nth-child(1) { margin-top: 112px; }
.stair-card:nth-child(2) { margin-top: 56px; }
.stair-card-run { border: 1px solid rgba(242, 237, 227, 0.3); border-top: 3px solid var(--gold); background: rgba(8, 16, 30, 0.5); }
.stair-tag { display: flex; align-items: center; gap: 12px; font-size: 14.5px; font-weight: 600; color: var(--text); }
.stair-tag-line { flex: none; width: 28px; height: 2px; background: var(--mark); }
.stair-title { margin-top: 16px; font-size: clamp(28px, 2.4vw, 32px); line-height: 1.06; letter-spacing: -0.014em; }
.stair-list { display: flex; flex-direction: column; gap: 16px; margin-top: 20px; }
.stair-list li { padding-top: 14px; border-top: 1px solid var(--rule); }
.stair-item-name { font-size: 15.5px; font-weight: 600; line-height: 1.4; color: var(--text); }
.stair-list li p + p { margin-top: 6px; font-size: 15px; line-height: 1.6; }
.stair-list .text-link { display: inline; min-height: 0; text-underline-offset: 4px; }
.foundations { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 32px; margin-top: 28px; padding-top: 22px; border-top: 1px solid var(--rule); }
.foundations-name { flex: none; font-size: 14.5px; font-weight: 600; color: var(--text); }
.foundations-name + p { flex: 1 1 420px; font-size: 15.5px; line-height: 1.6; }

/* What you leave with. */
.leave { margin-top: clamp(56px, 6vw, 84px); }
.leave-title { font-size: clamp(30px, 3vw, 40px); line-height: 1.04; letter-spacing: -0.018em; }
.leave-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(380px, 100%), 1fr)); gap: 14px; margin-top: 24px; }
.leave-item { display: flex; align-items: flex-start; gap: 14px; padding: 22px 24px; }
.leave-item svg { flex: none; margin-top: 4px; color: var(--mark); }
.leave-item p { font-size: 15.5px; line-height: 1.5; color: var(--text); }

/* Proof: three cards that are links. */
.link-tile { display: flex; flex-direction: column; gap: 10px; color: var(--text-body); transition: border-color 0.2s var(--ease); }
.link-tile:hover { border-color: var(--ink); color: var(--text-body); }
.link-tile-label { font-size: 14.5px; font-weight: 600; color: var(--accent); }
.link-tile .link-tile-text { font-size: 17px; line-height: 1.55; color: var(--text); }
.link-tile .link-tile-more { margin-top: auto; padding-top: 8px; font-size: 15px; font-weight: 500; color: var(--text); text-decoration: underline; text-decoration-color: var(--link-underline); text-underline-offset: 5px; }

/* ---------- Privacy ---------- */

.legal-layout { display: grid; grid-template-columns: minmax(230px, 0.36fr) minmax(0, 0.82fr); gap: clamp(32px, 6vw, 80px); align-items: start; }
.legal-aside { position: sticky; top: calc(var(--header-h) + 28px); padding: 4px 0 4px 20px; border-left: 2px solid var(--mark); }
.legal-aside-label { margin-bottom: 14px; font-size: 14.5px; font-weight: 600; color: var(--text); }
.legal-aside ul { display: flex; flex-direction: column; gap: 10px; }
.legal-aside li { font-size: 15.5px; line-height: 1.5; }
.legal-content { max-width: 68ch; }
.legal-updated { margin-bottom: 40px; font-size: 14.5px; color: var(--text-soft); }
.legal-content h2 { margin-top: 44px; font-size: clamp(30px, 2.8vw, 38px); line-height: 1.08; letter-spacing: -0.014em; }
.legal-content h2:first-of-type { margin-top: 0; }
.legal-content p { margin-top: 14px; font-size: 16.5px; line-height: 1.7; }

/* ---------- The page for a missing address ---------- */

.missing { min-height: 62vh; padding: clamp(88px, 10vw, 152px) 0; color: var(--text-body); }
.missing .page-title { max-width: 14ch; }
.brush-missing { right: clamp(-180px, -6vw, -40px); top: 50%; width: clamp(300px, 38vw, 560px); transform: translateY(-50%); opacity: 0.1; }

/* ---------- Phone and tablet ---------- */

@media (max-width: 960px) {
  .legal-layout { grid-template-columns: minmax(0, 1fr); }
  .legal-aside { position: static; }
}

@media (max-width: 820px) {
  .stair-card:nth-child(1), .stair-card:nth-child(2) { margin-top: 0; }
}

@media (max-width: 560px) {
  .sum-row { grid-template-columns: 84px minmax(0, 1fr); gap: 14px; padding: 14px; }
  .compare-who { flex-basis: 100%; }
}
