/* ── flow8 light theme for sub-pages ─────────────────────────────
   Loaded after each page's own styles. The pages were written for a
   dark canvas and colour everything through the tokens in style.css,
   so the page body is re-themed by re-pointing those tokens inside
   <main>. Navigation and footer stay dark and frame the light page,
   as on the homepage.
   ────────────────────────────────────────────────────────────── */

main {
  --navy:     #f5f6fb;
  --navy-2:   #ffffff;
  --navy-3:   #ffffff;
  --navy-4:   #eef0f7;
  --white:    #111322;
  --gray-50:  #1b1e33;
  --gray-200: #33374d;
  --gray-300: #4a4e66;
  --gray-400: #555a74;
  --red-dim:  #c41028;
  --red-glow: rgba(250,36,60,.08);
  --green:    #1f8a3b;
  --gold:     #8a5a00;
  --line:     rgba(17,19,34,.13);
  background: #f5f6fb;
  color: #111322;
}

/* Lines and soft fills were drawn in translucent white. */
body:not(.v2) main *, body:not(.v2) main *::before, body:not(.v2) main *::after { border-color: var(--line) !important; }
main :is(section, div, article, li, a, details, table, th, td, pre, blockquote)[style*="rgba(255,255,255"] { border-color: var(--line) !important; }

/* Buttons */
main .btn-p { color: #fff; border-radius: 100px; }
main .btn-g { color: #111322; border: 1px solid rgba(17,19,34,.28) !important; border-radius: 100px; }
main .btn-g:hover { background: rgba(17,19,34,.05); }

/* Type: one face, heavier and tighter, as on the homepage */
main h1 { font-weight: 800 !important; letter-spacing: -.04em !important; line-height: 1 !important; text-wrap: balance; }
main h2, main .section-h { font-weight: 800 !important; letter-spacing: -.035em !important; line-height: 1.04 !important; text-wrap: balance; }
main h3, main h4 { letter-spacing: -.015em; }
main h1 span, main h2 span, main .accent { -webkit-text-fill-color: currentColor; background: none !important; color: var(--red) !important; }
main .section-sub, main .lead { color: #555a74; }

/* The pill label above headings becomes a plain line of text */
main .eyebrow {
  background: none; border: none !important; padding: 0; border-radius: 0;
  text-transform: none; letter-spacing: 0; font-size: 15px; font-weight: 700;
  color: #c41028; margin-bottom: 16px;
}
main .eyebrow svg { display: none; }

/* No glows behind heroes and call-to-action bands */
main .page-hero::before,
main [class*="hero"]::before,
main [class*="cta"]::before { display: none !important; }

/* Cards sit on the page as white sheets */
main [class*="card"], main [class*="tile"], main [class*="panel"] { box-shadow: none; }
main [class*="card"]:hover { transform: none !important; }

/* Emoji used as icons */
.dd-icon { display: none !important; }
main :is(.usecase-icon, .surface-icon, .pillar-icon, .feature-icon, .arch-icon,
         .trigger-card-icon, .intel-icon, .testing-icon, .deploy-icon,
         .g-icon, .gc-icon, .sc-icon, .ind-icon, .case-icon, .feat-icon,
         .card-icon, .step-icon, .icon) { display: none !important; }

/* Blocks that are meant to stay dark (code, terminals) keep the dark tokens */
main :is(pre, .code-block, .terminal, .code-window, .term, .flow-code, .cli, [class*="terminal"], [class*="code-"]) {
  --navy: #111322; --navy-2: #161929; --navy-3: #1c2038; --navy-4: #222640;
  --white: #ffffff; --gray-50: #eeeff5; --gray-200: #d3d5e7; --gray-300: #b8baca; --gray-400: #9b9dab;
  --red-dim: #f0565d; --green: #52c41a; --gold: #faad14;
  --line: rgba(255,255,255,.1);
}

/* The closing call-to-action is a dark band, as on the homepage */
main > section:last-of-type[class*="cta"],
main section[class*="cta"]:last-of-type {
  --navy: #111322; --navy-2: #161929; --navy-3: #1c2038;
  --white: #ffffff; --gray-200: #d3d5e7; --gray-300: #b8baca; --gray-400: #a9adbf;
  --red-dim: #f0565d; --line: rgba(255,255,255,.14);
  background: #111322 !important; color: #fff;
}
main section[class*="cta"]:last-of-type .btn-g { color: #fff; border-color: rgba(255,255,255,.3) !important; }
main section[class*="cta"]:last-of-type :is(h1, h2, h3) { color: #fff; }

/* Section dots on the right edge */
.sections-sidebar .ss-dot { background: rgba(128,130,150,.5); }
.sections-sidebar .ss-label, .sections-sidebar a.ss-active .ss-label { color: #8d90a5; }

/* Small tags and badges that were coloured for a dark canvas */
main :is(.perm-tag, .compliance-badge, .audit-badge, .log-badge, .bz-pill, .ss-tag, .hy-kick, .approval-btn) { color: #33374d; }
main :is(.diagram-box, .mcp-box) { color: #111322; }
main .bz-cloud, main .ai { color: #2f54eb; }

/* More emoji-only icon holders found across the pages */
main :is(.ss-ico, .vc-ico, .vf-ico, .pi, .workflow-emoji, .sc-ico, .ly-ico, .mcp-icon-wrap, .integration-icon) { display: none !important; }

/* Pages that style the label themselves still get the plain version */
main .eyebrow, main [class*="eyebrow"], main [class*="hero-tag"], main [class*="badge-pill"] {
  background: none !important; border: none !important; padding: 0 !important; border-radius: 0 !important;
  text-transform: none !important; letter-spacing: 0 !important; font-size: 15px !important; font-weight: 700 !important;
  color: #c41028 !important;
}

/* Final contrast fixes */
main :is(.perm-tag, .compliance-badge, .audit-badge, .log-badge, .bz-pill, .ss-tag, .hy-kick, .approval-btn, .ss-n) { color: #33374d !important; }
main .bz-cloud, main .ai { color: #2f54eb !important; }
main section[class*="cta"]:last-of-type :is(.section-sub, .lead, p) { color: #b8baca !important; }
