/* Navigator Pro Process Hub - layout and page frame. Colours come from colours.css. */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--page); color: var(--ink); font-family: var(--font-text); font-size: 16px; line-height: 1.45; overflow-wrap: break-word; }
a { color: var(--bar); }
a:hover { color: var(--bar-dark); }
strong, b { font-weight: 600; }
h1, h2, h3 { font-family: var(--font-head); margin: 0; }
p { margin: 0; }
:focus-visible { outline: 3px solid #f2a413; outline-offset: 2px; }
.code { font-family: var(--font-code); }
.hidden { display: none !important; }

/* ---------- top bar ---------- */
.topbar { background: var(--bar); color: #fff; }
.topbar-in { max-width: 1280px; margin: 0 auto; padding: 0 24px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 28px; min-height: 60px; }
.brand { color: #fff; text-decoration: none; font-family: var(--font-head); font-weight: 700; font-size: 20px; letter-spacing: .06em; white-space: nowrap; }
.brand span { font-weight: 500; color: var(--bar-soft); }
.brand:hover { color: #fff; }
.brand { display: inline-flex; align-items: center; padding: 6px 0; }
.brand img { display: block; height: 30px; width: auto; }
.families { display: flex; flex-wrap: wrap; gap: 4px; flex: 1 1 auto; }
.families a, .families span { padding: 8px 14px; text-decoration: none; border-radius: 6px; }
.families a { color: #fff; font-weight: 600; }
.families a:hover { background: rgba(255,255,255,.12); color: #fff; }
.families a[aria-current="page"] { background: #fff; color: var(--bar); }
.families span { color: var(--bar-greyed); }
.tools { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; }
.tools a { display: inline-flex; align-items: center; gap: 7px; color: #fff; text-decoration: none; padding: 8px 10px; border-radius: 6px; white-space: nowrap; }
.tools a:hover { background: rgba(255,255,255,.12); color: #fff; }
.tools a[aria-current="page"] { background: #fff; color: var(--bar); font-weight: 600; }

/* ---------- icons: always beside a label, in the colour of the text around them ---------- */
.ic { flex: none; display: block; }
.tile > .ic { color: var(--bar); }
.tiles:not(.big) .tile.blue > .ic { color: var(--acc2); }
.tile.green > .ic { color: var(--acc6-ink); }
.tiles.big .tile > .ic { color: var(--bar); }
.tile.off > .ic, .tiles.big .tile.off > .ic { color: #8a93a0; }

/* ---------- project-type strip ---------- */
.subbar { background: #fff; border-bottom: 1px solid var(--line); }
.subbar-in { max-width: 1280px; margin: 0 auto; padding: 10px 24px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; font-size: 14px; }
.subbar .pick { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border: 1px solid #127D80; border-radius: 6px; text-decoration: none; color: #0e6266; font-weight: 600; }
.subbar .pick::after { content: ""; width: 0; height: 0; border-left: 4px solid transparent; border-right: 4px solid transparent; border-top: 5px solid currentColor; }
.subbar .hint { color: var(--ink-2); }

/* ---------- level trail ---------- */
.trail { background: var(--current); border-bottom: 2px solid var(--line-strong); }
.trail-in { max-width: 1280px; margin: 0 auto; padding: 14px 24px; display: flex; flex-wrap: wrap; align-items: stretch; gap: 10px 8px; }
.trail .step { display: flex; flex-direction: column; gap: 2px; padding: 6px 12px; text-decoration: none; color: var(--ink); border: 2px solid transparent; border-radius: 6px; min-width: 0; }
.trail a.step:hover { background: rgba(255,255,255,.45); }
.trail .step .lvl { font-family: var(--font-code); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink); opacity: .78; }
.trail .step .nm { font-weight: 600; }
.trail .step.here { background: #fff; border-color: var(--trail-edge, var(--bar)); }
.trail .step.here .lvl { opacity: 1; }
.trail .sep { align-self: center; font-size: 20px; opacity: .7; }
.trail.light-text:not(.x) .step:not(.here), .trail.light-text .sep { color: #fff; }
.trail.light-text .step:not(.here) .lvl { color: #fff; opacity: .9; }

/* ---------- page body ---------- */
.shell { max-width: 1280px; margin: 0 auto; padding: 28px 24px 64px; display: flex; flex-wrap: wrap; gap: 32px; }
.shell > main { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 28px; }
.plain { max-width: 1120px; margin: 0 auto; padding: 40px 24px 64px; display: flex; flex-direction: column; gap: 32px; }
.plain.home { padding-top: 56px; gap: 36px; }
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: 14px; color: var(--ink-2); }
.head { display: flex; flex-direction: column; gap: 10px; }
.head h1 { font-weight: 700; font-size: 34px; line-height: 1.15; }
.plain .head h1 { font-size: 36px; }
.home .head h1 { font-size: 40px; }
.lead { font-size: 18px; color: var(--ink-2); max-width: 760px; }
.home .lead { font-size: 19px; max-width: 720px; }
.small { font-size: 14px; color: var(--ink-2); }
h2.sec { font-weight: 600; font-size: 22px; }
.prose { display: flex; flex-direction: column; gap: 12px; max-width: 760px; }
.prose ul { margin: 0; padding-left: 22px; display: flex; flex-direction: column; gap: 6px; }

/* ---------- left menu ---------- */
.menu { flex: 1 1 220px; max-width: 260px; display: flex; flex-direction: column; gap: 22px; font-size: 15px; min-width: 0; }
.menu .grp { display: flex; flex-direction: column; gap: 2px; }
.menu .cap { padding: 0 12px 6px; font-family: var(--font-code); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); }
.menu a, .menu .off { display: flex; align-items: center; gap: 10px; padding: 8px 12px; text-decoration: none; color: var(--ink); border-radius: 6px; }
.menu a:hover { background: rgba(69,50,104,.07); }
.menu a[aria-current="page"] { background: var(--current); color: var(--bar); font-weight: 600; }
.menu .off { color: #7a8391; }
.menu .off em { margin-left: auto; font-style: normal; font-size: 12px; white-space: nowrap; }
.menu .sw { flex: none; width: 12px; height: 12px; border-radius: 3px; border: 1px solid; }
.menu .mc { flex: none; font-family: var(--font-code); font-size: 12px; min-width: 30px; }
@media (max-width: 599px) { .menu { max-width: none; flex-basis: 100%; } }

/* ---------- section bar: jump links, not tabs ---------- */
.secbar { position: sticky; top: 0; z-index: 5; display: flex; flex-wrap: nowrap; overflow-x: auto; align-items: stretch; background: #fff; border-bottom: 2px solid var(--line-strong); }
.secbar a { flex: none; padding: 13px 18px 10px; color: var(--ink-2); text-decoration: none; border-bottom: 3px solid transparent; margin-bottom: -2px; white-space: nowrap; }
.secbar a:hover { color: var(--bar); }
.secbar a[aria-current="true"] { background: var(--current); color: var(--bar); font-weight: 700; border-bottom-color: var(--bar); }
section.block { display: flex; flex-direction: column; gap: 12px; scroll-margin-top: 64px; }

/* ---------- tiles ---------- */
.tiles { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); }
.tiles.big { gap: 20px; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); }
.tiles.three { grid-template-columns: repeat(auto-fill, minmax(min(250px, 100%), 1fr)); }
.tile { display: flex; flex-direction: column; gap: 10px; padding: 22px; border-radius: 10px; text-decoration: none; color: var(--ink); min-height: 190px; box-shadow: var(--card-shadow); min-width: 0; }
.tile .t { font-family: var(--font-head); font-weight: 600; font-size: 22px; line-height: 1.2; }
.tile .d { color: var(--ink-2); font-size: 15px; }
.tile .go { margin-top: auto; font-weight: 600; }
.tile .tag { font-family: var(--font-code); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; }
.tile.blue  { background: var(--acc2-ll); border: 2px solid var(--acc2); }
.tile.blue .go, .tile.blue .tag { color: var(--acc2-ink); }
.tile.green { background: var(--acc6-ll); border: 2px solid var(--acc6); }
.tile.green .go, .tile.green .tag { color: var(--acc6-ink); }
.tile.off { background: var(--greyed); border: 1px dashed var(--line-grey); color: var(--ink-2); }
.tile.off .go { font-weight: 400; font-size: 14px; }
a.tile:hover { color: var(--ink); box-shadow: 0 2px 4px rgba(28,36,48,.10), 0 10px 24px -12px rgba(28,36,48,.30); }
.tiles.big .tile { gap: 12px; padding: 28px; min-height: 240px; border-width: 1px; border-top-width: 8px; }
.tiles.big .tile .t { font-size: 26px; }
.tiles.big .tile .d { font-size: 16px; }
.tiles.big .tile .go { color: var(--bar); }
.tiles.big .tile.off { border-top: 6px solid var(--line-grey); }
.tile.small { min-height: 150px; padding: 18px 20px; }
.tile.small .t { font-size: 19px; }
.tile.wide { min-height: 0; flex-direction: row; flex-wrap: wrap; align-items: center; gap: 10px 24px; padding: 22px 26px; }
.tile.wide .txt { flex: 1 1 320px; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.tile.wide .go { margin: 0; }
.rowlabel { font-family: var(--font-code); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); padding-bottom: 8px; border-bottom: 1px solid var(--line-strong); }
.rowgroup { display: flex; flex-direction: column; gap: 14px; }

/* reference tiles on a project-type page */
.tile.ref { min-height: 140px; padding: 0; border: 1px solid; overflow: hidden; gap: 0; }
.tile.ref .band { height: 7px; }
.tile.ref .in { padding: 20px 18px 22px; display: flex; flex-direction: column; gap: 6px; }
.tile.ref .t { font-size: 19px; }

/* ---------- cards and the phase row ---------- */
.card { background: var(--card); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--card-shadow); padding: 24px; }
.scroll-x { overflow-x: auto; }
.phase-row { display: grid; grid-template-columns: repeat(var(--n, 8), minmax(166px, 1fr)); gap: 10px; }
.phase-box { display: flex; flex-direction: column; gap: 10px; padding: 14px 12px; min-height: 150px; border-radius: 8px; border: 2px solid; text-decoration: none; color: var(--ink); min-width: 0; }
.phase-box .c { font-family: var(--font-code); font-size: 12px; letter-spacing: .08em; }
.phase-box .n { font-family: var(--font-head); font-weight: 600; font-size: 16px; line-height: 1.2; hyphens: auto; -webkit-hyphens: auto; }
.phase-box.light-text { color: #fff; }
a.phase-box:hover { filter: brightness(.97); color: var(--ink); }
a.phase-box.light-text:hover { color: #fff; }

/* ---------- search box on the home page ---------- */
.searchbox { display: flex; flex-direction: column; gap: 6px; max-width: 720px; }
.searchbox label { font-weight: 600; font-size: 14px; color: var(--ink-2); }
.searchbox input { height: 52px; padding: 0 18px; font: inherit; font-size: 17px; color: var(--ink); background: #fff; border: 1px solid var(--line-grey); border-radius: 8px; width: 100%; }

/* ---------- messages ---------- */
.notice { padding: 14px 16px; border-radius: 8px; border: 1px solid var(--line-strong); background: #fff; max-width: 760px; }
.notice.prep { background: var(--greyed); border-style: dashed; border-color: var(--line-grey); color: var(--ink-2); }
.notice.problem { background: var(--problem-bg); border-color: var(--problem); color: #5f1111; }
.notice.problem strong { display: block; margin-bottom: 2px; }
.notice.problem .code { font-size: 14px; }
.chip-tbs { display: inline-block; padding: 1px 8px; border-radius: 10px; background: var(--tbs-bg); color: var(--tbs-ink); font-size: 13px; font-weight: 600; }
.proposed { border: 1.5px dashed var(--proposed); border-radius: 6px; padding: 1px 6px; }

/* ---------- footer ---------- */
.foot { max-width: 1280px; margin: 0 auto; padding: 0 24px 40px; font-size: 14px; color: var(--ink-2); }

/* ---------- health page ---------- */
.health { max-width: 1120px; margin: 0 auto; padding: 32px 24px 64px; display: flex; flex-direction: column; gap: 24px; }
.verdict { padding: 18px 22px; border-radius: 10px; font-family: var(--font-head); font-weight: 600; font-size: 22px; border: 2px solid; }
.verdict.ok { background: var(--ok-bg); border-color: var(--ok); color: #1c5233; }
.verdict.bad { background: var(--problem-bg); border-color: var(--problem); color: #5f1111; }
.verdict small { display: block; font-family: var(--font-text); font-weight: 400; font-size: 15px; margin-top: 4px; }
.tablewrap { overflow-x: auto; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--card-shadow); }
table.grid { border-collapse: collapse; width: 100%; min-width: 560px; }
table.grid th { background: var(--table-head); color: #fff; text-align: left; font-weight: 600; padding: 10px 14px; font-size: 14px; }
table.grid td { padding: 9px 14px; border-top: 1px solid var(--line); vertical-align: top; font-size: 15px; }
table.grid td.f { font-family: var(--font-code); font-size: 13px; overflow-wrap: anywhere; }

/* ---------- shared table styles: every table on the Hub ---------- */
table.grid tr.band > th, table.grid tr.band > td { background: var(--band-bg); border-left: 4px solid var(--table-head); color: var(--band-ink); font-family: var(--font-head); font-size: 13px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; text-align: left; padding: 8px 14px; }
table.grid tr.band .note { margin-left: 12px; font-family: var(--font-text); font-size: 14px; font-weight: 400; letter-spacing: 0; text-transform: none; color: var(--ink-2); }
table.grid tr.sub > td:first-child, table.grid tr.sub > th:first-child { position: relative; padding-left: 44px; }
table.grid tr.sub > td:first-child::before, table.grid tr.sub > th:first-child::before { content: ""; position: absolute; left: 22px; top: 0; width: 12px; height: 1.15em; margin-top: 2px; border-left: 2px solid var(--elbow); border-bottom: 2px solid var(--elbow); border-bottom-left-radius: 4px; }
table.grid td.num, table.grid th.num { text-align: right; white-space: nowrap; }
table.grid td.num { font-family: var(--font-code); font-size: 14px; font-variant-numeric: tabular-nums; }
table.grid thead.soft th { background: var(--table-head-soft); color: var(--ink); }
table.grid tr.certify > * { background: var(--cert-bg); }
table.grid tr.certify > :first-child { box-shadow: inset 4px 0 0 var(--cert); }
table.grid tr.certifier > * { background: var(--cert-sub-bg); border-top-color: var(--cert-sub-line); }
table.grid tr.approve > * { background: var(--approve-bg); }
table.grid tr.approve > :first-child { box-shadow: inset 4px 0 0 var(--approve); }
.tier { display: inline-block; padding: 1px 9px; border-radius: 10px; font-size: 13px; font-weight: 600; white-space: nowrap; color: var(--tier-light-ink); }
.tier.t1 { background: var(--tier-1); } .tier.t2 { background: var(--tier-2); } .tier.t3 { background: var(--tier-3); }
.tier.t4 { background: var(--tier-4); color: var(--tier-dark-ink); } .tier.t5 { background: var(--tier-5); color: var(--tier-dark-ink); }
.tier.joint { background: var(--tier-joint); color: var(--tier-dark-ink); } .tier.committee { background: var(--tier-committee); color: #fff; }
.chip-set { display: inline-block; padding: 1px 8px; border-radius: 10px; background: var(--set-bg); color: var(--set-ink); font-size: 13px; font-weight: 600; }
.chip-placeholder { display: inline-block; padding: 0 8px; border-radius: 10px; background: var(--placeholder-bg); color: var(--placeholder-ink); border: 1px dashed var(--placeholder-line); font-size: 13px; font-weight: 600; }
.st { display: inline-block; padding: 1px 9px; border-radius: 10px; font-size: 13px; font-weight: 600; white-space: nowrap; }
.st.ok { background: var(--ok-bg); color: #1c5233; }
.st.bad { background: var(--problem-bg); color: #5f1111; }
.st.off { background: #eeece7; color: var(--ink-2); }
.st.note { background: var(--tbs-bg); color: var(--tbs-ink); }

@media (max-width: 480px) {
  .topbar-in, .subbar-in, .trail-in, .shell, .plain, .foot, .health { padding-left: 16px; padding-right: 16px; }
  .home .head h1 { font-size: 34px; }
  .plain .head h1 { font-size: 30px; }
  .head h1 { font-size: 28px; }
  .card { padding: 16px; }
}

/* ---------- value-chain pages drawn from the fact files ---------- */
.meta { display: flex; flex-wrap: wrap; gap: 6px 22px; font-size: 15px; color: var(--ink-2); }
.meta strong { color: var(--ink); }
.ownerline { font-size: 15px; color: var(--ink-2); max-width: 900px; }
.ownerline strong { color: var(--ink); }
.ownerline .cell { display: inline; } .ownerline .cell p { display: inline; }
.ownerline .cell ul { margin: 4px 0 0; }
.h2note { font-family: var(--font-code); font-size: 12px; font-weight: 400; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); margin-left: 6px; }
.h3 { font-family: var(--font-head); font-weight: 600; font-size: 17px; margin: 0 0 8px; }
.card > p + p, .card > .cell + p { margin-top: 8px; }
.cell { display: flex; flex-direction: column; gap: 6px; }
.cell ul { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 4px; }
.codelink { font-family: var(--font-code); font-size: .92em; white-space: nowrap; }
table.grid .code, .rolegrp .code, .pills a { font-family: var(--font-code); font-size: 13px; }
.code.small { font-size: 12px; color: var(--ink-2); }
table.grid td .small { margin-top: 4px; }
table.grid td .small.rule { font-style: normal; }
table.grid td .steps { display: flex; flex-wrap: wrap; gap: 2px 14px; margin-top: 8px; }
table.grid td .apv { margin: 2px 0 4px; }
table.grid td .lim { color: var(--ink-2); font-size: 14px; }
table.grid td.at { font-size: 14px; }
table.grid.soft-head thead th { background: var(--table-head-soft); color: var(--ink); }
table.grid.soft-head thead th.num, table.grid thead th.num { text-align: right; }
table.grid.soft-head thead th.num .ltr { margin-left: auto; }
table.grid.acts td, table.grid.lines td { padding-top: 12px; padding-bottom: 12px; }
table.grid td.time { white-space: normal; }
table.grid td.time > span { display: block; }
.tkind { font-size: 13px; color: var(--ink-2); } .tkind.hard { font-weight: 700; color: var(--ink); }
.tmeasure { font-size: 13px; color: var(--ink-2); }
.stepno { display: inline-flex; align-items: center; justify-content: center; min-width: 28px; height: 28px; padding: 0 6px; border-radius: 14px; color: #fff; font-weight: 700; font-size: 13px; }
.hookpill { display: inline-block; padding: 1px 8px; border-radius: 10px; border: 1px solid var(--line-grey); background: var(--greyed); color: var(--ink-2); font-size: 12px; font-weight: 600; }
.bandic { display: inline-flex; align-items: center; gap: 8px; }

/* RASCI letters (fixed colours) */
.ltr { display: inline-flex; align-items: center; justify-content: center; min-width: 30px; height: 26px; padding: 0 6px; border-radius: 5px; font-weight: 700; font-size: 13px; color: #fff; }
.ltr.a { background: var(--rasci-a); } .ltr.r { background: var(--rasci-r); } .ltr.ar { background: var(--rasci-ar); }
.ltr.s { background: var(--rasci-s); } .ltr.c { background: var(--rasci-c); color: var(--ink); } .ltr.i { background: var(--rasci-i); } .ltr.x { background: #7a8391; }
.wholist { display: flex; flex-wrap: wrap; gap: 6px 14px; }
.who { display: inline-flex; align-items: center; gap: 6px; }

/* inputs and outputs */
.iogrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 16px; }
.io { background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--card-shadow); overflow: hidden; }
.io-h { padding: 10px 18px; font-family: var(--font-head); font-weight: 700; font-size: 14px; letter-spacing: .07em; text-transform: uppercase; border-top: 5px solid; }
.io.need .io-h { background: var(--acc2-l); border-top-color: var(--acc2); } .io.make .io-h { background: var(--acc6-l); border-top-color: var(--acc6); }
.io-b { padding: 16px 18px 20px; }

/* the phase on a page */
.pgroup { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; padding: 8px 14px; background: var(--band-bg); border-left: 4px solid var(--table-head); margin-top: 6px; }
.pg-l { font-family: var(--font-head); font-weight: 700; font-size: 13px; letter-spacing: .07em; text-transform: uppercase; color: var(--band-ink); }
.pg-n { font-size: 14px; color: var(--ink-2); }
.pwrap { padding-bottom: 10px; }
.pflow { display: flex; gap: 12px; align-items: flex-start; }
.pcol { flex: none; width: 214px; display: flex; flex-direction: column; gap: 8px; }
.phead { display: flex; flex-direction: column; gap: 6px; padding: 10px 12px 14px; border-top: 6px solid; text-decoration: none; color: var(--ink); min-height: 92px; }
.phead .c, .psub .c { font-family: var(--font-code); font-size: 12px; letter-spacing: .06em; }
.phead .n { font-family: var(--font-head); font-weight: 700; font-size: 16px; line-height: 1.2; }
.psub { display: flex; flex-direction: column; gap: 4px; padding: 9px 12px 11px; background: #fff; border: 1.5px solid; border-radius: 6px; text-decoration: none; color: var(--ink); font-size: 14px; line-height: 1.3; }
.psub.hook { border-style: dashed; background: var(--greyed); color: var(--ink-2); }
a.phead:hover, a.psub:hover { filter: brightness(.97); color: var(--ink); }
.pgate { display: flex; align-items: flex-start; gap: 8px; padding: 12px; background: var(--approve-bg); border: 2px solid var(--approve); border-radius: 6px; font-family: var(--font-head); font-weight: 700; font-size: 15px; line-height: 1.25; color: var(--bar); }
.pnote { font-size: 13px; color: var(--ink-2); }
.pseam { padding: 10px 12px; border: 1.5px dashed var(--line-grey); border-radius: 6px; background: var(--greyed); font-size: 13px; color: var(--ink-2); }

/* the menu of a phase */
.menu .mc2 { flex: none; font-family: var(--font-code); font-size: 12px; min-width: 44px; color: var(--ink-2); }
.menu a { align-items: baseline; }
.menu a.open { font-weight: 600; }
.menu .subs { display: flex; flex-direction: column; gap: 2px; margin: 2px 0 6px 12px; padding-left: 8px; border-left: 2px solid var(--edge, var(--bar)); font-size: 14px; }
.menu .subs .mc2 { min-width: 56px; }
.pager { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 24px; padding-top: 18px; border-top: 1px solid var(--line-strong); font-weight: 600; }
.pager a { text-decoration: none; } .pager .next { margin-left: auto; text-align: right; }

/* controls */
.picker { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 14px; color: var(--ink-2); max-width: 380px; }
.mxbar .picker { flex: 1 1 260px; }
.picker select { height: 46px; padding: 0 12px; font: inherit; font-size: 16px; color: var(--ink); background: #fff; border: 1px solid var(--line-grey); border-radius: 8px; width: 100%; }
.check { display: inline-flex; align-items: center; gap: 8px; font-size: 15px; }
.mxbar { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 14px 24px; }
.legend { display: flex; flex-wrap: wrap; gap: 8px 16px; font-size: 14px; align-items: center; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.pills { display: flex; flex-wrap: wrap; gap: 6px; }
.pills a { padding: 6px 12px; border: 1px solid var(--line-grey); border-radius: 16px; text-decoration: none; color: var(--ink); background: #fff; }
.pills a[aria-current="page"] { background: var(--bar); border-color: var(--bar); color: #fff; font-weight: 600; }

/* responsibility matrix */
.mxwrap { overflow: auto; max-height: 82vh; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--card-shadow); }
table.mx { border-collapse: separate; border-spacing: 0; font-size: 14px; }
table.mx th, table.mx td { border-right: 1px solid #eef0f2; border-bottom: 1px solid var(--line); }
table.mx thead th { position: sticky; z-index: 3; }
table.mx thead tr:first-child th { top: 0; height: 52px; }
table.mx thead tr:nth-child(2) th { top: 52px; }
table.mx .corner { left: 0; z-index: 4; background: #fff; text-align: left; vertical-align: bottom; padding: 12px 14px; min-width: 230px; width: 280px; border-right: 2px solid var(--line-strong); border-bottom: 2px solid var(--ink); }
table.mx .bandh { color: #fff; font-family: var(--font-head); font-weight: 600; font-size: 14px; padding: 6px 8px; text-align: center; line-height: 1.2; }
table.mx .roleh { height: 250px; width: 44px; min-width: 44px; vertical-align: bottom; padding: 8px 0; background: #eef0f3; border-bottom: 2px solid var(--ink); }
table.mx .roleh span { display: inline-block; writing-mode: vertical-rl; transform: rotate(180deg); white-space: nowrap; font-weight: 600; font-size: 13px; max-height: 234px; overflow: hidden; text-overflow: ellipsis; }
table.mx .roleh.on { box-shadow: inset 0 -5px 0 var(--bar); }
table.mx td { text-align: center; padding: 6px 4px; height: 46px; }
table.mx td.on { background: var(--current); }
table.mx .rowh { position: sticky; left: 0; z-index: 2; background: #fff; text-align: left; font-weight: 400; padding: 8px 14px; border-right: 2px solid var(--line-strong); display: table-cell; }
table.mx .rowh .code { display: block; font-size: 12px; color: var(--ink-2); letter-spacing: .06em; }
table.mx .rowh a { color: var(--ink); text-decoration: none; } table.mx .rowh a:hover { text-decoration: underline; }
table.mx .pband th, table.mx .hband th { position: sticky; left: 0; text-align: left; padding: 9px 14px; font-family: var(--font-head); font-weight: 600; font-size: 15px; }
table.mx .pband th { background: var(--table-head-soft); } table.mx .pband a { color: var(--ink); text-decoration: none; }
table.mx .hband th { background: #eef0f3; color: var(--ink-2); font-size: 14px; font-weight: 500; }
table.mx .lv { font-family: var(--font-code); font-size: 12px; font-weight: 400; letter-spacing: .08em; margin-right: 6px; }
table.mx tr.dimrow td, table.mx tr.dimrow .rowh { opacity: .38; }
@media (max-width: 599px) { table.mx .corner { min-width: 150px; width: 150px; } table.mx .rowh { max-width: 150px; } }

/* a role across the phases */
.sw2 { display: inline-block; width: 14px; height: 14px; border-radius: 3px; border: 1px solid; margin-right: 8px; vertical-align: baseline; }
.rolegrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); gap: 14px; align-items: start; }
.rolegrp { background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--card-shadow); overflow: hidden; }
.rg-h { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 10px 14px; }
.rg-h span:last-child { margin-left: auto; font-size: 13px; color: var(--ink-2); }
.rolegrp.a .rg-h { background: var(--rasci-a-tint); } .rolegrp.r .rg-h { background: var(--rasci-r-tint); } .rolegrp.ar .rg-h { background: var(--rasci-ar-tint); }
.rolegrp.s .rg-h { background: var(--rasci-s-tint); } .rolegrp.c .rg-h { background: var(--rasci-c-tint); } .rolegrp.i .rg-h { background: var(--rasci-i-tint); }
.rg-l { list-style: none; margin: 0; padding: 6px 14px 12px; display: flex; flex-direction: column; }
.rg-l li { padding: 6px 0; border-top: 1px solid var(--line); } .rg-l li:first-child { border-top: 0; }
.rg-l a { text-decoration: none; color: var(--ink); } .rg-l a:hover { text-decoration: underline; }
.rg-l .code { color: var(--ink-2); margin-right: 6px; }

/* ---------- wording beside the facts ---------- */
.wcard .prose { max-width: 860px; }
.wcard + .wcard, .wcard + .card, .card + .wcard, .chartcard + .small, .wcard + .tablewrap { margin-top: 14px; }
.wnote { margin-top: 4px; font-size: 14px; color: var(--ink-2); border-left: 3px solid var(--bar-soft); padding-left: 8px; }

/* ---------- charts (engine/chart.js) ---------- */
/* A chart is drawn at a readable size and scrolls both ways inside its own frame; it never shrinks to fit. */
.chartcard { padding: 0; overflow: hidden; position: relative; z-index: 0; isolation: isolate; }
.chartcard .chartscroll { overflow: scroll; max-height: 78vh; overscroll-behavior: contain; scrollbar-width: auto; scrollbar-color: #8b93a3 #eceef2; }
/* the scroll bars of a chart are always shown, on every device: a chart is never shrunk and never cut */
.chartcard .chartscroll::-webkit-scrollbar { width: 14px; height: 14px; -webkit-appearance: none; }
.chartcard .chartscroll::-webkit-scrollbar-track { background: #eceef2; }
.chartcard .chartscroll::-webkit-scrollbar-thumb { background: #8b93a3; border-radius: 7px; border: 3px solid #eceef2; }
.chartcard .chartscroll::-webkit-scrollbar-corner { background: #eceef2; }
.chartlegend { margin: 4px 0 12px; }
.chart { position: relative; font-size: 15px; line-height: 20px; }
.ch-lane { position: absolute; left: 0; right: 0; background: #fff; border-bottom: 1px solid var(--line); }
.ch-lane.alt { background: #f5f6f7; }
.ch-lbl { position: sticky; left: 0; z-index: 3; height: 100%; box-sizing: border-box; padding: 18px 14px; background: #e9ecf1; border-right: 4px solid var(--bar); display: flex; flex-direction: column; justify-content: flex-start; gap: 2px; }
.ch-lane.alt .ch-lbl { background: #e2e6ec; }
.ch-lbl strong { font-family: var(--font-head); font-weight: 600; font-size: 16px; line-height: 1.25; }
.ch-lbl span { font-size: 13px; color: var(--ink-2); }
.ch-lines { position: absolute; left: 0; top: 0; z-index: 1; pointer-events: none; }
.ch-lines polyline { fill: none; stroke: #1c2430; stroke-width: 1.8; stroke-linejoin: round; }
.ch-lines polyline.dash { stroke-dasharray: 6 5; }
.ch-lines marker path { fill: #1c2430; }
.ch-group { position: absolute; z-index: 0; border: 1.5px dashed #7b8494; border-radius: 10px; background: rgba(69,50,104,.04); }
.ch-group span { position: absolute; left: 10px; top: 3px; line-height: 20px; font-size: 13px; color: var(--ink-2); white-space: nowrap; }
.ch-tag { position: absolute; z-index: 2; transform: translate(-50%, -150%); background: rgba(255,255,255,.92); padding: 0 5px; border-radius: 4px; font-size: 13px; color: var(--ink-2); white-space: nowrap; }
.ch-tag.v { transform: translate(8px, -50%); }
.ch-node { position: absolute; z-index: 2; box-sizing: border-box; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; gap: 2px; padding: 8px 12px; background: #fff; border: 2px solid #2b2540; border-radius: 6px; color: var(--ink); text-decoration: none; overflow: visible; }
a.ch-node:hover, a.ch-node:focus-visible { box-shadow: 0 0 0 3px var(--bar-soft); }
.ch-node .c { font-family: var(--font-code); font-size: 13px; line-height: 16px; color: var(--ink-2); display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.ch-node .n { font-size: 15px; line-height: 20px; }
/* a decision or a gate: a diamond, with its code and the model's own words beside it */
.ch-node.decision, .ch-node.gate { flex-direction: row; align-items: center; justify-content: flex-start; text-align: left; gap: 10px; padding: 0; background: transparent; border: 0; border-radius: 0; overflow: visible; }
.ch-node .dia { position: relative; flex: 0 0 64px; width: 64px; height: 64px; display: flex; align-items: center; justify-content: center; }
.ch-node .dia i { position: absolute; inset: 0; clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); background: #F6C56B; }
.ch-node.gate .dia i { background: var(--bar); }
.ch-node .dia svg { position: relative; color: #3d2f0c; }
.ch-node.gate .dia svg { color: #fff; }
.ch-node .tx { display: flex; flex-direction: column; gap: 2px; min-width: 0; background: rgba(255,255,255,.86); border-radius: 4px; padding: 2px 4px; }
.ch-lane.alt ~ .ch-node .tx { background: rgba(255,255,255,.86); }
.ch-node.decision .n, .ch-node.gate .n { font-size: 14px; line-height: 20px; font-weight: 600; }
.ch-node.certification { background: var(--cert-bg); border-color: var(--cert); }
.ch-node.certification .n { font-weight: 600; }
.ch-node.ext { border-style: dashed; border-width: 1.5px; background: #fbfaf7; }
.lg { display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px; }
.lg.decision { background: #F6C56B; clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); }
.lg.gate { background: var(--bar); color: #fff; clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); }
.lg.decision svg, .lg.gate svg { width: 11px; height: 11px; }
.lg.certification { background: var(--cert-bg); border: 1.5px solid var(--cert); border-radius: 3px; box-sizing: border-box; width: 26px; height: 18px; }
.lg.group { border: 1.5px dashed #7b8494; border-radius: 4px; box-sizing: border-box; width: 26px; height: 18px; }
.lg.dash { height: 0; width: 26px; border-top: 2px dashed #1c2430; }

/* ---------- the value-chain diagram on a project type's opening page ---------- */
.vc-diagram { align-items: start; }
.vc-col { position: relative; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.vc-col .phase-box { height: 150px; }
.vc-col.next::after { content: ""; position: absolute; top: 67px; right: -11px; width: 0; height: 0; border-left: 9px solid #1c2430; border-top: 7px solid transparent; border-bottom: 7px solid transparent; z-index: 1; }
.vc-gates { display: flex; flex-direction: column; gap: 6px; }
.vc-gate { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink); text-decoration: none; font-size: 14px; line-height: 1.25; }
.vc-gate:hover, .vc-gate:focus-visible { border-color: var(--bar); }
.vc-gate .dia { position: relative; flex: 0 0 26px; width: 26px; height: 26px; display: flex; align-items: center; justify-content: center; color: #fff; }
.vc-gate .dia i { position: absolute; inset: 0; background: var(--bar); clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); }
.vc-gate .dia svg { position: relative; width: 12px; height: 12px; }
.vc-gate .at { display: block; font-family: var(--font-code); font-size: 12px; color: var(--ink-2); }

/* anything that scrolls sideways (the value-chain diagram, the phase on a page, wide tables) shows its scroll bar on every device */
.scroll-x { scrollbar-width: auto; scrollbar-color: #8b93a3 #eceef2; }
.scroll-x::-webkit-scrollbar { height: 14px; -webkit-appearance: none; }
.scroll-x::-webkit-scrollbar-track { background: #eceef2; }
.scroll-x::-webkit-scrollbar-thumb { background: #8b93a3; border-radius: 7px; border: 3px solid #eceef2; }

/* ===== Authority lines and unit operations ===== */
[hidden] { display: none !important; }
.mute { color: #7a8391; }
.eg { display: inline-block; color: var(--ink-2); font-size: 14px; }
.small-in { font-size: 14px; color: var(--ink-2); }
.tname { color: var(--ink-2); font-size: 14px; }
.kind { display: inline-block; padding: 2px 10px; border-radius: 11px; font-size: 13px; font-weight: 600; color: #fff; white-space: nowrap; line-height: 1.35; }
.kind.policy { background: var(--kind-policy); } .kind.concession { background: var(--kind-concession); } .kind.rule { background: var(--kind-rule); }
.kind.above { background: var(--kind-above); } .kind.system { background: var(--kind-system); }
.pillq { display: inline-block; padding: 1px 10px; border-radius: 11px; font-size: 13px; border: 1px solid var(--line-grey); color: var(--ink-2); background: #fff; white-space: nowrap; }
.cardhead { border-top: 6px solid var(--bar); display: flex; flex-direction: column; gap: 10px; }
.cardhead.k-policy { border-top-color: var(--kind-policy); } .cardhead.k-concession { border-top-color: var(--kind-concession); } .cardhead.k-rule { border-top-color: var(--kind-rule); }
.cardhead.k-above { border-top-color: var(--kind-above); } .cardhead.k-system { border-top-color: var(--kind-system); }
.cardhead h1 { font-weight: 700; font-size: 30px; line-height: 1.2; }
.cardhead .ids { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.cardhead .ids .code { color: var(--ink-2); font-size: 14px; }
.cardhead .lead { max-width: 860px; }
.cardhead .lead.prose p { font-size: 18px; }
.card.simple { border-top: 6px solid var(--bar); display: flex; flex-direction: column; gap: 12px; }
.card.simple.k-policy { border-top-color: var(--kind-policy); } .card.simple.k-concession { border-top-color: var(--kind-concession); } .card.simple.k-rule { border-top-color: var(--kind-rule); }
.card.simple.k-above { border-top-color: var(--kind-above); } .card.simple.k-system { border-top-color: var(--kind-system); }
.card.simple h3 { font-family: var(--font-head); font-weight: 600; font-size: 21px; line-height: 1.25; }
.card.simple .ids { display: flex; gap: 8px; align-items: center; }
.card.simple + .card.simple { margin-top: 16px; }
main h4 { font-family: var(--font-code); font-weight: 500; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); margin-top: 6px; }
h3.subh { font-family: var(--font-head); font-weight: 600; font-size: 20px; line-height: 1.25; padding-top: 14px; border-top: 2px solid var(--line-strong); }
h3.subh .code { font-size: 14px; color: var(--ink-2); margin-right: 6px; }
section.block.sub { gap: 10px; }
.two { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(420px, 100%), 1fr)); gap: 28px 24px; align-items: start; }
.two > section { min-width: 0; }
.two table.grid { min-width: 0; }
table.grid.facts th[scope="row"] { background: #f6f5f2; color: var(--ink); font-weight: 600; width: 17%; border-top: 1px solid var(--line); font-size: 15px; vertical-align: top; }
table.grid.facts td { width: 33%; }
table.grid.facts tr:first-child > * { border-top: 0; }
table.grid td.no { font-family: var(--font-code); font-size: 13px; color: var(--ink-2); white-space: nowrap; }
table.grid td.step { white-space: nowrap; }
table.grid td.step .sw { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; }
table.grid td.step .sw svg { flex: none; color: var(--ink-2); }
table.grid.steps tr.sub > td.step { position: relative; padding-left: 44px; }
table.grid.steps tr.sub > td.step::before { content: ""; position: absolute; left: 22px; top: 0; width: 12px; height: 1.1em; margin-top: 4px; border-left: 2px solid #9fb4c7; border-bottom: 2px solid #9fb4c7; }
table.grid.steps tr.sub > td.step .sw { font-weight: 400; color: var(--ink-2); }
table.grid.steps tr.sub > td:first-child { padding-left: 14px; }
table.grid.steps tr.sub > td:first-child::before { content: none; }
table.grid tr.certifier > :first-child { box-shadow: inset 4px 0 0 var(--cert); }
table.grid.approvers tr.sub > td:first-child::before { content: none; }
table.grid.approvers tr.sub > td:nth-child(2) { position: relative; padding-left: 40px; }
table.grid.approvers tr.sub > td:nth-child(2)::before { content: ""; position: absolute; left: 18px; top: 0; width: 12px; height: 1.1em; margin-top: 4px; border-left: 2px solid #9fb4c7; border-bottom: 2px solid #9fb4c7; }
table.grid tr.none > td { background: #fafaf8; }
table.grid td.num.dash { color: #9aa3b0; }
table.grid tr.ceiling > td:first-child { box-shadow: inset 4px 0 0 var(--kind-above); }
table.grid.io3 td ul { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 4px; }
table.grid tr.band .proposed.mk { font-family: var(--font-text); font-size: 13px; font-weight: 600; letter-spacing: 0; text-transform: none; margin-left: 10px; background: #fff; }
.proposed.mk { font-size: 13px; font-weight: 600; color: #8a3d08; white-space: nowrap; }
h4 .proposed.mk { font-family: var(--font-text); letter-spacing: 0; text-transform: none; margin-left: 6px; }
table.grid.lines-table td, table.grid.moves-table td { padding-top: 11px; padding-bottom: 11px; }
section.block > .tablewrap + .tablewrap { margin-top: 2px; }

/* filters above a table */
.lt-controls, .mv-top { display: flex; flex-wrap: wrap; gap: 12px 16px; align-items: flex-end; }
.mv-controls { display: flex; flex-direction: column; gap: 12px; }
.flt { display: flex; flex-direction: column; gap: 4px; font-size: 13px; font-weight: 600; color: var(--ink-2); flex: 1 1 170px; max-width: 260px; min-width: 0; }
.flt.wide { flex: 2 1 260px; max-width: 420px; }
.flt select, .flt input { height: 44px; padding: 0 12px; font: inherit; font-size: 16px; font-weight: 400; color: var(--ink); background: #fff; border: 1px solid var(--line-grey); border-radius: 8px; width: 100%; min-width: 0; }
.lt-count { flex: 1 1 100%; }
.mv-kinds { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.mv-kinds .flt-l { font-size: 14px; font-weight: 600; color: var(--ink-2); }
.kindbtn { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px 4px 4px; border: 1px solid var(--line-grey); border-radius: 16px; background: #fff; font: inherit; font-size: 14px; color: var(--ink-2); cursor: pointer; }
.kindbtn[aria-pressed="true"] { border-color: var(--bar); box-shadow: 0 0 0 2px var(--bar-soft); color: var(--ink); font-weight: 600; }
.guide { padding: 16px 20px; border-top: 5px solid var(--bar); display: flex; flex-direction: column; gap: 10px; }
.guide summary { font-family: var(--font-head); font-weight: 600; font-size: 17px; cursor: pointer; }
.guide[open] summary { margin-bottom: 8px; }
table.kinds { border-collapse: collapse; margin-top: 10px; }
table.kinds td { padding: 4px 14px 4px 0; vertical-align: top; font-size: 15px; }

/* the chooser of Delegation of Authority */
.tiles.blocks { grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); }
.blocktile { min-height: 0; }
.blocktile a.t { color: var(--ink); text-decoration: none; }
.blocktile a.t:hover { text-decoration: underline; }
.grouplist { list-style: none; margin: 4px 0 6px; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.grouplist a { display: flex; justify-content: space-between; gap: 12px; padding: 6px 10px; border-radius: 6px; text-decoration: none; color: var(--ink); background: rgba(255,255,255,.7); }
.grouplist a:hover { background: #fff; box-shadow: 0 0 0 1px var(--acc6); }
.grouplist .gc { font-family: var(--font-code); font-size: 13px; color: var(--ink-2); }
.tile.ref2 { background: #fff; border: 1px solid var(--line); min-height: 120px; }
.tile.ref2 .go { color: var(--acc2-ink); }

/* the chessboard */
.boardcard .chartscroll { max-height: 82vh; }
table.board { border-collapse: separate; border-spacing: 0; table-layout: fixed; width: 1756px; font-size: 15px; }
table.board th, table.board td { border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); vertical-align: top; text-align: left; }
table.board thead th { position: sticky; top: 0; z-index: 3; padding: 10px 12px; width: 256px; border-top: 5px solid; font-weight: 400; }
table.board thead th strong, table.board th.lev strong { display: block; font-family: var(--font-head); font-weight: 600; font-size: 17px; line-height: 1.25; }
table.board thead th span, table.board th.lev span { display: block; font-size: 13px; color: var(--ink-2); }
table.board thead th.corner { left: 0; z-index: 4; width: 220px; background: #e9ecf1; border-top-color: var(--bar); }
table.board thead th.corner span { font-size: 13px; color: var(--ink); font-weight: 600; }
table.board th.lev { position: sticky; left: 0; z-index: 2; width: 220px; padding: 12px; background: #ece7f4; border-right: 4px solid var(--bar); font-weight: 400; }
table.board td { padding: 8px; background: #fff; }
table.board tbody tr:nth-child(even) td { background: #f5f6f7; }
.nomove { display: block; padding: 6px; font-size: 13px; }
a.mv { display: flex; flex-direction: column; gap: 4px; padding: 8px 10px; margin-bottom: 8px; border: 1px solid var(--line-strong); border-radius: 8px; background: #fff; text-decoration: none; color: var(--ink); }
a.mv:last-child { margin-bottom: 0; }
a.mv:hover, a.mv:focus-visible { border-color: var(--bar); box-shadow: 0 0 0 2px var(--bar-soft); }
a.mv .top { display: flex; justify-content: space-between; align-items: center; gap: 6px; }
a.mv .code { font-size: 12px; color: var(--ink-2); }
a.mv .kind { font-size: 12px; padding: 1px 8px; }
a.mv .lb { font-size: 15px; line-height: 1.3; }
a.mv.dim { opacity: .22; }

/* unit operations flowcharts */
.ch-node .tg { display: inline-block; margin-top: 2px; padding: 0 6px; border: 1.5px dashed var(--proposed); border-radius: 5px; font-size: 13px; line-height: 18px; font-weight: 600; color: #8a3d08; background: #fff; align-self: center; }
.ch-node.decision .tg { align-self: flex-start; }
.ch-node.is-proposed:not(.decision) { border: 2px dashed var(--proposed); }
.ch-node.k-start, .ch-node.k-end { border-radius: 26px; }
.ch-node.k-system { background: #f3f4f6; }
.lg.dashline { width: 26px; height: 0; border: 0; border-top: 2px dashed #1c2430; border-radius: 0; background: none; }
.lg.prop { width: 18px; height: 14px; border: 2px dashed var(--proposed); border-radius: 4px; background: #fff; }
@media (max-width: 599px) {
  .cardhead h1 { font-size: 24px; }
  table.grid.facts th[scope="row"], table.grid.facts td { width: auto; }
  .flt, .flt.wide { max-width: none; flex-basis: 100%; }
}

/* a system hook, wherever its code appears */
.hookref { display: inline-flex; flex-direction: column; align-items: flex-start; gap: 3px; max-width: 100%; margin: 4px 0; padding: 7px 10px; border: 1px solid var(--line-strong); border-left: 4px solid var(--placeholder-line); border-radius: 8px; background: #fbfaf8; white-space: normal; text-align: left; vertical-align: top; font-weight: 400; font-size: 14px; line-height: 1.4; color: var(--ink); }
.hookref .hk-c { font-family: var(--font-code); font-size: 12px; color: var(--ink-2); }
.hookref .hk-n { font-weight: 600; }
.hookref .hk-d { color: var(--ink-2); }
.chip-link { display: inline-block; padding: 1px 8px; border-radius: 10px; background: var(--placeholder-bg); color: var(--placeholder-ink); border: 1px dashed var(--placeholder-line); font-size: 13px; font-weight: 600; }

/* ===== Documents and Templates ===== */
.doc-find { display: flex; flex-direction: column; gap: 6px; max-width: 460px; }
.doc-find label { font-weight: 600; font-size: 14px; color: var(--ink-2); }
.doc-find input { height: 48px; padding: 0 16px; font: inherit; color: var(--ink); background: #fff; border: 1px solid var(--line-grey); border-radius: 8px; width: 100%; }
.plans { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(250px, 100%), 1fr)); gap: 14px; margin-top: 12px; }
.plan { background: #fff; border: 1px solid var(--line-strong); border-radius: 10px; overflow: hidden; display: flex; flex-direction: column; box-shadow: var(--card-shadow); }
.plan[hidden], [data-doc-sec][hidden] { display: none; }
.plan-band { display: flex; justify-content: space-between; gap: 10px; padding: 8px 16px; font-family: var(--font-code); font-size: 13px; border-bottom: 1px solid transparent; color: var(--ink); }
.plan-band a { color: inherit; }
.plan-band.light-text, .plan-band.light-text a { color: #fff; }
.plan-in { display: flex; flex-direction: column; gap: 8px; padding: 14px 16px 16px; flex: 1; }
.plan-t { font-family: var(--font-head); font-weight: 700; font-size: 19px; line-height: 1.2; }
.plan-k { font-size: 14px; color: var(--ink-2); }
.plan-act { margin-top: auto; padding-top: 8px; display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.doc-prep { display: inline-flex; align-items: center; min-height: 32px; padding: 4px 12px; background: var(--greyed); border: 1px dashed var(--line-grey); border-radius: 8px; color: var(--ink-2); font-size: 14px; }
.plan-act .doc-prep { min-height: 44px; font-size: 16px; padding: 0 14px; }
.doc-miss { display: inline-block; padding: 4px 10px; background: var(--problem-bg); border: 1px solid var(--problem); border-radius: 8px; color: #5f1111; font-size: 14px; overflow-wrap: anywhere; }
.doc-get { display: inline-flex; align-items: center; gap: 8px; min-height: 36px; padding: 0 12px; background: var(--bar); color: #fff; font-weight: 700; text-decoration: none; border-radius: 8px; }
.doc-get:hover { background: var(--bar-dark); color: #fff; }
.plan-act .doc-get { min-height: 44px; padding: 0 14px; }
.doc-facts { display: block; font-size: 13px; color: var(--ink-2); margin-top: 4px; }
.ph-chip { display: inline-block; padding: 2px 8px; border: 1px solid transparent; border-radius: 4px; font-family: var(--font-code); font-size: 12px; color: var(--ink); }
.ph-chip.light-text { color: #fff; }
.doc-all { font-size: 14px; color: var(--ink-2); }
table.grid.docs { min-width: 820px; }
table.grid.docs td { padding-top: 12px; padding-bottom: 12px; }

/* ===== Settings ===== */
main.plain.wide { max-width: 1320px; }
.sethead { display: flex; flex-direction: column; gap: 10px; padding: 24px 26px; }
.sethead h1 { display: flex; align-items: center; gap: 12px; font-weight: 700; font-size: 34px; line-height: 1.15; }
.sethead h1 .ic { color: var(--bar); flex: none; }
.sethead .lead { max-width: 860px; }
.set-get { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-top: 6px; }
.getbtn { display: inline-flex; align-items: center; gap: 12px; min-height: 52px; padding: 8px 16px; background: var(--table-head); color: #fff; border: 0; border-radius: 8px; font: inherit; text-align: left; cursor: pointer; }
.getbtn:hover { background: #0f5580; }
.getbtn span { display: flex; flex-direction: column; line-height: 1.2; }
.getbtn small { font-size: 13px; opacity: .92; }
.set-controls { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; }
.set-controls .flt-l { font-size: 14px; font-weight: 600; color: var(--ink-2); }
.set-controls .pills { display: flex; flex-wrap: wrap; gap: 8px; }
.set-controls .pill { min-height: 40px; padding: 0 16px; border-radius: 20px; border: 1px solid var(--line-grey); background: #fff; color: var(--ink); font: inherit; font-size: 15px; cursor: pointer; }
.set-controls .pill[aria-pressed="true"] { background: var(--bar); border-color: var(--bar); color: #fff; font-weight: 600; }
.set-controls .flt { flex: 0 1 240px; flex-direction: row; align-items: center; gap: 8px; }
.set-controls .set-count { flex-basis: 100%; }
.sst { display: inline-block; padding: 1px 9px; border-radius: 10px; font-size: 13px; font-weight: 600; white-space: nowrap; }
.sst.st-set { background: var(--set-bg); color: var(--set-ink); }
.sst.st-tbs { background: var(--tbs-bg); color: var(--tbs-ink); }
.sst.st-placeholder { background: var(--placeholder-bg); color: var(--placeholder-ink); border: 1px dashed var(--placeholder-line); }
table.grid.settings { min-width: 900px; }
table.grid.settings.sum { min-width: 560px; }
table.grid.settings tr[hidden] { display: none; }
table.grid.settings tr.grp > td { background: #f6f8fa; border-top: 1px solid var(--line-strong); font-size: 14px; color: var(--ink-2); padding-top: 7px; padding-bottom: 7px; }
table.grid.settings tr.grp > td .codelink, table.grid.settings tr.grp > td .code { font-weight: 600; margin-right: 6px; }
table.grid.settings tr.in > td:first-child { padding-left: 30px; }
table.grid.settings tr.sub.in > td:first-child { padding-left: 52px; }
table.grid.settings tr.sub.in > td:first-child::before { left: 30px; }
table.grid.settings tr.total > td { background: #f6f8fa; border-top: 2px solid var(--line-strong); }
table.grid.settings td .tier { margin-right: 4px; }
table.grid.settings td .hookref { margin-top: 4px; }
@media (max-width: 599px) { .sethead { padding: 18px 16px; } .sethead h1 { font-size: 28px; } .getbtn { flex: 1 1 100%; } .set-controls .flt { flex-basis: 100%; } }

/* ===== Glossary ===== */
.head h1.with-ic { display: flex; align-items: center; gap: 12px; }
.head h1.with-ic > .ic { color: var(--bar); flex: none; }
table.grid.glossary { min-width: 720px; }
table.grid.glossary tr[hidden], [data-g-sec][hidden], .g-hooks > div[hidden] { display: none; }
table.grid.glossary .g-term { font-family: var(--font-head); font-size: 16px; }
table.grid.glossary .g-mean p + p, table.grid.glossary .g-mean ul { margin-top: 6px; }
.g-hooks { display: flex; flex-direction: column; gap: 12px; }
.to-settings { white-space: nowrap; }
table.grid td.num .chip-tbs, table.grid td.num .proposed { font-family: var(--font-text); }

/* ===== Search ===== */
.search-page .sr-g { display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.sr-l { list-style: none; margin: 0; padding: 0; width: 100%; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--card-shadow); }
.sr-l[hidden] { display: none; }
.sr { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; padding: 11px 16px; border-top: 1px solid var(--line); }
.sr:first-child { border-top: 0; }
.sr .sr-t { font-weight: 600; }
.sr .sr-m { flex-basis: 100%; font-size: 14px; color: var(--ink-2); }
.search-page .pill { min-height: 40px; padding: 0 16px; border-radius: 20px; border: 1px solid var(--line-grey); background: #fff; color: var(--ink); font: inherit; font-size: 15px; cursor: pointer; }
table.grid.settings:not(.sum) th:not([style]) { min-width: 230px; }
table.grid.settings.s1 { min-width: 1080px; }

/* ---------- User Guide and About ---------- */
table.grid.words { min-width: 0; }
table.grid.words td:first-child { white-space: nowrap; }
table.grid.words.wrap td:first-child { white-space: normal; }
.gprose { max-width: none; }
.gprose > * { max-width: 860px; }
.gprose > .chartcard, .gprose > .mclock-card { max-width: 100%; }
.gprose h3 { font-family: var(--font-head); font-weight: 600; font-size: 18px; margin-top: 8px; }
.gprose .gn { font-family: var(--font-code); font-size: 0.95em; font-weight: 500; }
.gprose .ltr, .gprose .kind, .gprose .tier { vertical-align: baseline; }
.gprose .hookref { display: flex; }
.head h1 .chno { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; height: 44px; margin-right: 14px; border-radius: 10px; background: var(--bar); color: #fff; font-size: 24px; vertical-align: middle; }
.demo { background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--card-shadow); overflow-x: auto; padding: 0; }
.demo .trail { border-radius: 12px; }
.demo .secbar.still { position: static; border-bottom: 0; }
.secbar.still span { flex: none; padding: 13px 18px 10px; color: var(--ink-2); border-bottom: 3px solid transparent; white-space: nowrap; }
.secbar.still span.on { background: var(--current); color: var(--bar); font-weight: 700; border-bottom-color: var(--bar); }
.phase-chips { display: flex; flex-wrap: wrap; gap: 8px; padding: 16px; }
.pchip { display: inline-block; padding: 6px 12px; border: 1px solid; border-radius: 8px; color: var(--ink); text-decoration: none; font-size: 14px; }
.pchip.light-text { color: #fff; }
.pchip .c { font-family: var(--font-code); font-size: 13px; font-weight: 500; }
table.grid.steps-demo tr.row-certify td { background: var(--cert-bg); }
table.grid.steps-demo tr.row-approve td { background: var(--approve-bg, #ece7f4); }
.demo-legend { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; }
.gtile .d { font-size: 15px; }
.pager { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; margin-top: 8px; }
.pager a { flex: 0 1 380px; display: flex; flex-direction: column; gap: 2px; padding: 14px 18px; background: #fff; border: 1px solid var(--line); border-radius: 12px; text-decoration: none; color: var(--ink); }
.pager a:hover { border-color: var(--bar); }
.pager a.nx { text-align: right; margin-left: auto; }
.about-page { display: flex; flex-direction: column; gap: 18px; max-width: 980px; }
.about-one { padding: 28px 30px; }
.about-top { display: flex; flex-direction: column; gap: 10px; }
.about-row { display: flex; flex-wrap: wrap; gap: 14px 40px; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); }
.about-row > div { flex: 1 1 300px; min-width: 0; }
.about-cap { font-family: var(--font-code); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); margin-bottom: 6px; }
.about-fine { font-size: 14px; line-height: 1.5; color: var(--ink-2); }
.about-fine p + p { margin-top: 2px; }
.about-fine ul { list-style: none; margin: 0; padding: 0; }
.about-fine.first-strong p:first-child { font-weight: 600; color: var(--ink); }
.about-fine a { overflow-wrap: anywhere; }
.about-credits { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
.gprose h3[id] { scroll-margin-top: 64px; }
table.grid.gatetable td { font-size: 14px; }
table.grid.gatetable .gstep + .gstep { margin-top: 8px; padding-top: 8px; border-top: 1px dashed var(--line); }
table.grid.gatetable .cell ul { margin: 0; padding-left: 18px; }
table.grid.gatetable td:last-child { display: table-cell; white-space: nowrap; }
table.grid.gatetable .ltr { min-width: 26px; height: 22px; font-size: 12px; }
.gprose .chartcard { max-width: none; }
.gprose .ch-node .tg { border: 1px solid #9aa5b3; background: #eef0f3; color: var(--ink-2); }
.mclock-card { padding: 18px; max-width: none; display: flex; flex-direction: column; gap: 12px; }
.mclock { display: grid; grid-template-columns: repeat(var(--n), minmax(94px, 1fr)); gap: 6px; min-width: calc(var(--n) * 100px); padding-bottom: 4px; }
.mcol { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.mphase { display: flex; flex-direction: column; gap: 3px; min-height: 104px; padding: 8px 8px; border: 1px solid; border-radius: 8px; color: var(--ink); text-decoration: none; }
.mphase.light-text { color: #fff; }
.mphase .c { font-family: var(--font-code); font-size: 12px; }
.mphase .n { font-weight: 600; font-size: 14px; line-height: 18px; }
.mphase .g { align-self: flex-start; margin-top: auto; display: inline-flex; align-items: center; gap: 4px; padding: 0 8px; border-radius: 9px; background: rgba(255,255,255,.8); color: var(--ink); font-size: 13px; font-weight: 600; }
.mticks { display: flex; flex-wrap: wrap; gap: 4px; align-content: flex-start; position: relative; padding-top: 8px; border-top: 3px solid var(--line-strong, #cfc8ba); }
.mtick { font-family: var(--font-code); font-size: 13px; padding: 1px 6px; border: 1px solid #9aa5b3; border-radius: 6px; background: #fff; color: var(--ink); text-decoration: none; }
.mtick:hover { border-color: var(--bar); background: var(--current); }
.mnone { font-size: 13px; color: #7a8391; }
.mspan { margin: 0; }
.mspan .ic { display: inline; vertical-align: -2px; }
.mline { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: flex-start; padding: 8px 10px; border: 1px solid var(--line); border-left: 8px solid; border-radius: 6px; }
.mlp { flex: 0 0 200px; display: flex; flex-direction: column; font-weight: 600; font-size: 14px; color: var(--ink); text-decoration: none; }
.mlp .c { font-family: var(--font-code); font-size: 12px; font-weight: 500; }
.mpills { flex: 1 1 420px; display: flex; flex-wrap: wrap; gap: 6px 8px; min-width: 0; }
.mpill { display: inline-flex; flex-wrap: wrap; align-items: baseline; gap: 2px 7px; padding: 3px 10px; border: 1px solid #d9d3c7; border-radius: 14px; background: #faf9f6; font-size: 14px; scroll-margin-top: 72px; }
.mpill b { font-family: var(--font-code); font-weight: 500; font-size: 13px; }
.mpill .ic { align-self: center; }
.mpill .codelink { font-size: 12px; }
.mpill:target, .mpill.on { border-color: var(--bar); background: var(--current); }
table.grid.gatetable tr[id] { scroll-margin-top: 64px; }
table.grid.mstable .gstep + .gstep { margin-top: 8px; padding-top: 8px; border-top: 1px dashed var(--line); }
table.grid.mstable tr[id] { scroll-margin-top: 64px; }
table.grid.mstable { table-layout: fixed; }
.lg.extbox { width: 26px; height: 18px; border: 1.5px dashed #6b7480; border-radius: 3px; background: #faf9f6; box-sizing: border-box; }
.fixedflow .chartscroll { max-height: none; padding: 8px; }
.gprose > .fixedflow { width: max-content; max-width: 100%; }
svg.fflow { display: block; font-family: var(--font-text); }
.fflow .ffl { fill: none; stroke: #1c2430; stroke-width: 1.6; }
.fflow .ffs { stroke: #1c2430; stroke-width: 1.5; fill: #fff; }
.fflow .ffs.start { fill: #fff; }
.fflow .ffs.decision { fill: #F6C56B; stroke: #b98a1f; }
.fflow .ffs.main { fill: #453268; stroke: #453268; }
.fflow .ffs.done { fill: #127D80; stroke: #127D80; }
.fflow .ffs.stop { fill: #B3261E; stroke: #B3261E; }
.fflow .ffs.warn { fill: #C2710C; stroke: #C2710C; }
.fflow .ffs.bar { fill: #eef0f3; stroke: #9aa5b3; }
.fflow .fft { font-size: 13.5px; font-weight: 600; text-anchor: middle; fill: #1c2430; }
.fflow .fft.main, .fflow .fft.done, .fflow .fft.stop, .fflow .fft.warn { fill: #fff; }
.fflow .ffb { font-size: 13px; font-weight: 700; text-anchor: middle; fill: #fff; }
.fflow .ffb.dark { fill: #1c2430; }
.fflow .ffy { font-size: 13px; text-anchor: middle; fill: #4a5566; paint-order: stroke; stroke: #fff; stroke-width: 4px; }
table.grid.ladder-all td { font-size: 14px; }
table.grid.ladder-all { min-width: 880px; }
table.grid.steps-demo td.stepname { display: table-cell; white-space: nowrap; }
table.grid.steps-demo td.stepname .ic { vertical-align: -4px; margin-right: 6px; }
table.grid th a.onhead { color: #fff; }
.gprose > .tablewrap:has(table.ladder-all) { max-width: 100%; }
table.grid.ladder-all .chip-tbs { white-space: nowrap; }
table.grid.steps-demo td.stepname .ic { display: inline; }
