/* AI Adoption Controls Framework: additions to the adriansaxton.com stylesheet (site.css). Brand rules: one red,
   used for the bar mark and the single most important thing; panels on --tint; sections split by --rule. */

.wrap.wide { max-width: 64rem; }
main h1 { font-weight: 800; letter-spacing: -0.02em; line-height: 1.1; margin: 0.4rem 0 0; }
.intro, .post-head { padding-block: 3rem 1.6rem; }
.intro-text { color: var(--grey); font-size: 1.12rem; margin: 1rem 0 0; max-width: 40rem; }
.objective { font-size: 1.2rem; line-height: 1.5; margin: 0.6rem 0 0; }
.note { color: var(--grey); font-size: 0.92rem; }
.sub { font-weight: 600; margin: 1.2rem 0 0.2rem; }
.section .label { display: block; margin: 0.4rem 0 0.6rem; }
ul.plain { list-style: none; padding: 0; margin: 0; }
ul.plain li { padding: 0.35rem 0; border-bottom: 1px solid var(--rule); }

.actions { margin-top: 1.8rem; display: flex; flex-wrap: wrap; gap: 0.7rem; }
.button { display: inline-block; font-weight: 600; text-decoration: none; padding: 0.6rem 1.1rem; border-radius: 999px;
  background: var(--ink); color: var(--ground); border: 1px solid var(--ink); }
.button:hover { background: var(--red); border-color: var(--red); color: #fff; }
.button.quiet { background: none; color: var(--ink); border-color: var(--rule); }
.button.quiet:hover { border-color: var(--ink); color: var(--ink); }

.domains { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.8rem;
  grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr)); }
.domains a { display: grid; gap: 0.2rem; padding: 1rem 1.1rem; background: var(--tint); text-decoration: none;
  color: var(--ink); height: 100%; box-sizing: border-box; }
.domains a:hover .dname { text-decoration: underline; text-decoration-color: var(--red); }
.domains .code { font-size: 0.74rem; font-weight: 600; letter-spacing: 0.12em; color: var(--grey); }
.domains .dname { font-weight: 800; font-size: 1.08rem; line-height: 1.25; }
.domains .count { font-size: 0.86rem; color: var(--grey); }
ol.steps li { margin-bottom: 0.5rem; }

table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
th, td { text-align: left; vertical-align: top; padding: 0.55rem 0.6rem 0.55rem 0; border-bottom: 1px solid var(--rule); }
thead th { font-size: 0.74rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--grey); }
table.levels th { width: 9.5rem; font-weight: 600; white-space: nowrap; }
table.levels tr.met th, table.levels tr.met td { background: var(--tint); }
table.levels tr.met th { box-shadow: inset 3px 0 0 var(--mark); padding-left: 0.6rem; }
table.items .note-cell { color: var(--grey); font-size: 0.86rem; }
table.maps th { width: 45%; font-weight: 400; }
.strength { font-size: 0.72rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--grey);
  border: 1px solid var(--rule); border-radius: 999px; padding: 0 0.4rem; white-space: nowrap; }
.strength.direct { color: var(--ink); border-color: var(--grey); }
.wrap.wide { overflow-x: auto; }

dl.facts { display: grid; grid-template-columns: max-content 1fr; gap: 0.35rem 1.2rem; margin: 0; }
dl.facts dt { color: var(--grey); font-weight: 600; font-size: 0.9rem; }
dl.facts dd { margin: 0; }

/* self-assessment */
.assess .domain { margin-top: 2rem; }
.assess .domain h2 { font-size: 1.3rem; font-weight: 800; margin: 0 0 0.4rem; }
.assess .ctrl { padding: 1rem 0; border-bottom: 1px solid var(--rule); }
.assess .ctrl h3 { font-size: 1.02rem; margin: 0; }
.assess .ctrl h3 .id { color: var(--grey); font-weight: 600; font-size: 0.82rem; margin-right: 0.4rem; }
.assess .ctrl p { margin: 0.3rem 0 0.6rem; color: var(--grey); font-size: 0.94rem; }
.assess details { margin: 0.2rem 0 0.6rem; font-size: 0.9rem; }
.assess details summary { cursor: pointer; color: var(--grey); }
.assess details dl { display: grid; grid-template-columns: max-content 1fr; gap: 0.3rem 0.8rem; margin: 0.5rem 0 0; }
.assess details dt { font-weight: 600; }
.assess details dd { margin: 0; }
.picker { display: flex; flex-wrap: wrap; gap: 0.35rem; border: 0; padding: 0; margin: 0; }
.picker legend { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.picker label { display: inline-flex; align-items: center; justify-content: center; min-width: 2.4rem; padding: 0.3rem 0.55rem;
  border: 1px solid var(--rule); border-radius: 999px; cursor: pointer; font-weight: 600; font-size: 0.9rem; }
.picker input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.picker input:checked + span { color: var(--ground); }
.picker label:has(input:checked) { background: var(--ink); border-color: var(--ink); color: var(--ground); }
.picker label:has(input:focus-visible) { outline: 2px solid var(--red); outline-offset: 2px; }
.assess .progress { position: sticky; top: 0; background: var(--ground); padding: 0.6rem 0; border-bottom: 1px solid var(--rule);
  display: flex; flex-wrap: wrap; gap: 0.6rem 1rem; align-items: center; z-index: 2; font-size: 0.92rem; }
.assess .progress button, .assess .tools button { font: inherit; font-weight: 600; font-size: 0.86rem; padding: 0.3rem 0.8rem;
  border-radius: 999px; border: 1px solid var(--rule); background: none; color: var(--ink); cursor: pointer; }
.assess .progress button.primary { background: var(--ink); color: var(--ground); border-color: var(--ink); }
.results { margin-top: 1.5rem; }
.results .headline { font-size: 1.15rem; }
.results .big { font-size: 2.4rem; font-weight: 800; color: var(--red); font-variant-numeric: tabular-nums; }
.results .bar-cell { width: 40%; }
.results .meter { height: 0.6rem; background: var(--tint); position: relative; }
.results .meter i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--ink); }
.results .meter b { position: absolute; top: -0.2rem; bottom: -0.2rem; width: 2px; background: var(--mark); left: 60%; }
.results td.num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.assess .tools { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 1rem; }
@media print { .site-head, .site-foot, .assess .progress, .assess .tools, .assess form { display: none; } }

/* self-assessment: stepper and results page */
.assess .start p { max-width: 40rem; }
.sub-h { font-size: 1.15rem; font-weight: 800; margin: 2rem 0 0.6rem; }
ol.sections { padding-left: 1.4rem; margin: 0; }
ol.sections li { padding: 0.45rem 0; border-bottom: 1px solid var(--rule); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.2rem 1rem; }
ol.sections li.done a { color: var(--grey); }
.tally { color: var(--grey); font-size: 0.88rem; font-variant-numeric: tabular-nums; }
.step-head { display: grid; gap: 0.5rem; padding-bottom: 0.8rem; border-bottom: 1px solid var(--rule); }
.step-head h2 { font-size: 1.6rem; font-weight: 800; margin: 0.2rem 0 0; letter-spacing: -0.01em; }
.step-meter { height: 5px; background: var(--tint); position: relative; }
.step-meter i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--mark); }
.nav-row { display: flex; flex-wrap: wrap; gap: 0.6rem; align-items: center; margin-top: 1.4rem; }
.nav-row button, .nav-row .button { font: inherit; font-weight: 600; font-size: 0.95rem; padding: 0.55rem 1.1rem; border-radius: 999px;
  border: 1px solid var(--rule); background: none; color: var(--ink); cursor: pointer; text-decoration: none; }
.nav-row button.primary { background: var(--ink); color: var(--ground); border-color: var(--ink); }
.nav-row button.primary:hover { background: var(--red); border-color: var(--red); color: #fff; }
.nav-row button.quiet:hover, .nav-row .button.quiet:hover { border-color: var(--ink); }
.warn { color: var(--red); font-weight: 600; min-height: 1.2em; margin: 1rem 0 0; }
.assess .target { margin-top: 0.5rem; }
.assess select { font: inherit; font-size: 0.86rem; color: var(--ink); background: var(--ground); border: 1px solid var(--rule); border-radius: 6px; padding: 0.15rem 0.4rem; }
.assess details dt.met, .assess details dd.met { font-weight: 600; }
.table-wrap { overflow-x: auto; }

/* control search */
.search { margin-top: 1.6rem; display: grid; gap: 0.4rem; max-width: 40rem; }
.search input { font: inherit; font-size: 1.05rem; padding: 0.65rem 0.9rem; border: 1px solid var(--divider, var(--grey)); border-radius: 8px;
  background: var(--ground); color: var(--ink); width: 100%; box-sizing: border-box; }
.search input:focus { outline: 2px solid var(--red); outline-offset: 1px; border-color: var(--ink); }
#search-results .entry h3 { margin: 0.15rem 0; }

/* sortable roadmap */
table.roadmap th button.sort { font: inherit; font-size: 0.74rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--grey); background: none; border: 0; padding: 0; cursor: pointer; text-align: left; }
table.roadmap th button.sort:hover, table.roadmap th[aria-sort="ascending"] button.sort, table.roadmap th[aria-sort="descending"] button.sort { color: var(--ink); }
.sort-mark { font-size: 0.7rem; }

/* source links */
a[rel="external"]::after { content: " ↗"; font-size: 0.8em; color: var(--grey); }
.more { font-size: 0.82rem; color: var(--grey); margin-left: 0.4rem; }
.source-link { margin: 0.8rem 0 0; font-weight: 600; }

/* criteria and method */
ol.criteria { padding-left: 0; list-style: none; margin: 0; }
ol.criteria li { padding: 0.5rem 0; border-bottom: 1px solid var(--rule); }
.cid { font-weight: 600; font-size: 0.82rem; color: var(--grey); margin-right: 0.35rem; font-variant-numeric: tabular-nums; }
.overlay { font-size: 0.7rem; font-weight: 600; letter-spacing: 0.06em; border: 1px solid var(--grey); border-radius: 999px;
  padding: 0 0.4rem; color: var(--ink); white-space: nowrap; }
.prose h1 { font-size: 1.6rem; margin-top: 0.4rem; }
.prose h2 { font-size: 1.2rem; font-weight: 800; margin: 1.8rem 0 0.4rem; }
.prose h3 { font-size: 1.05rem; margin: 1.4rem 0 0.3rem; }
.prose table { margin: 0.6rem 0 1rem; }
.prose li { margin-bottom: 0.3rem; }

/* v1.0 results: distribution bars and target reasons */
.dist { position: relative; display: flex; height: 0.9rem; background: var(--tint); }
.dist i { display: block; height: 100%; background: var(--ink); }
.dist i.l0 { opacity: 0.12; } .dist i.l1 { opacity: 0.25; } .dist i.l2 { opacity: 0.4; }
.dist i.l3 { opacity: 0.7; } .dist i.l4 { opacity: 0.85; } .dist i.l5 { opacity: 1; }
.dist .base-mark { position: absolute; top: -0.25rem; bottom: -0.25rem; width: 2px; background: var(--mark); margin-left: -1px; }
.dist-table .bar-cell { width: 45%; }
.assess input.why { font: inherit; font-size: 0.86rem; margin-left: 0.5rem; padding: 0.2rem 0.5rem; border: 1px solid var(--rule);
  border-radius: 6px; background: var(--ground); color: var(--ink); width: min(22rem, 100%); }
.assess input.why[hidden] { display: none; }
.assess details ol.criteria { margin-top: 0.4rem; }

/* overlay filter on the controls page */
.overlay-filter { margin-top: 1.2rem; display: grid; gap: 0.4rem; }
.chips { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.chip { font: inherit; font-size: 0.88rem; font-weight: 600; padding: 0.3rem 0.8rem; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--rule); background: none; color: var(--ink); }
.chip:hover { border-color: var(--ink); }
.chip.on { background: var(--ink); color: var(--ground); border-color: var(--ink); }
ul.ov-crit { list-style: none; padding: 0; margin: 0.4rem 0 0; font-size: 0.92rem; }
ul.ov-crit li { padding: 0.25rem 0; }
.domains .desc { font-size: 0.88rem; color: var(--grey); line-height: 1.4; }
a.overlay { text-decoration: none; }
a.overlay:hover { border-color: var(--red); }

/* results: one square per control */
.progress-line { font-weight: 600; margin: 0 0 0.4rem; }
.cells { display: flex; flex-wrap: wrap; gap: 4px; }
.cell { display: inline-grid; place-items: center; width: 1.6rem; height: 1.6rem; border-radius: 4px; font-size: 0.78rem;
  font-weight: 600; font-style: normal; text-decoration: none; box-sizing: border-box; font-variant-numeric: tabular-nums; }
a.cell:hover { outline: 2px solid var(--red); outline-offset: 1px; }
/* level scale: diverging red (short of the foundation) to neutral (3) to blue (beyond); validated for colour-blind
   separation in both modes with the dataviz palette validator, 9 Nov 2026. The number in each square carries the level too. */
:root { --lv0: #5E0711; --lv1: #C8102E; --lv2: #EE8592; --lv3: #F0EFEC; --lv4: #6F9BD6; --lv5: #1F4E8C;
  --lv0-t: #FFFFFF; --lv1-t: #FFFFFF; --lv2-t: #1A1A1A; --lv3-t: #1A1A1A; --lv4-t: #1A1A1A; --lv5-t: #FFFFFF; --lv3-b: #1A1A1A; }
:root[data-theme="dark"] { --lv0: #8E0E22; --lv1: #E0455A; --lv2: #F6B3BB; --lv3: #383835; --lv4: #7FA8E0; --lv5: #C9DCF5;
  --lv0-t: #FFFFFF; --lv1-t: #141414; --lv2-t: #141414; --lv3-t: #F2F2F2; --lv4-t: #141414; --lv5-t: #141414; --lv3-b: #F2F2F2; }
.cell.l0 { background: var(--lv0); color: var(--lv0-t); }
.cell.l1 { background: var(--lv1); color: var(--lv1-t); }
.cell.l2 { background: var(--lv2); color: var(--lv2-t); }
.cell.l3 { background: var(--lv3); color: var(--lv3-t); border: 2px solid var(--lv3-b); }
.cell.l4 { background: var(--lv4); color: var(--lv4-t); }
.cell.l5 { background: var(--lv5); color: var(--lv5-t); }
.cell.below { background: var(--tint); color: var(--ink); border: 1px solid var(--divider, var(--grey)); }
.cell.unsure { border: 1px dashed var(--grey); color: var(--grey); }
.cell.na { color: var(--grey); border: 1px solid var(--rule); }
.cell.todo { border: 1px solid var(--rule); }
.cell-key { display: flex; flex-wrap: wrap; gap: 0.5rem 1.2rem; font-size: 0.86rem; color: var(--grey); margin-bottom: 0.6rem; }
.cell-key span { display: inline-flex; align-items: center; gap: 0.4rem; }
.dist-table .cells-cell { width: 55%; }

.next-level summary { cursor: pointer; font-weight: 600; }

/* About: source names in the notices */
#notice li strong { color: var(--red); }
