/* KZ Theme partial: cps.css
   Owner: HP-04. Home CPS band, CPS summary panel, CPS detail page, finder and tables.
   Every colour is a theme token via the aliases in base.css. The cores deck/rail and lifecycle loop CSS moved to _unused/css/ (HP-12A, 2026-10-27). */

/* ---------- Home: CPS band ---------- */
.band.layers { background: radial-gradient(70% 55% at 85% 8%, color-mix(in srgb, var(--peach) 95%, transparent), transparent 70%), var(--paper); }
/* ---------- CPS finder and detail page ---------- */
.cps-finder { background: var(--white); color: var(--ink); border: 1px solid var(--hairline); border-radius: var(--radius); padding: clamp(16px, 4vw, 32px); max-width: 100%; }
.cps-finder__title { font: 700 var(--fs-h3)/1.15 var(--f-head); margin: 0 0 8px; color: var(--ink); }
.cps-finder__lede, .cps-finder__note { font-size: var(--fs-small); color: var(--slate); margin: 0 0 20px; max-width: 46rem; }
.cps-finder__note { margin: 16px 0 0; }
.cps-finder__cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 24px; }
.cps-col__h { font: 700 var(--fs-body)/1.25 var(--f-head); letter-spacing: .01em; color: var(--ink); margin: 0 0 4px; }
.cps-col__q { font-size: var(--fs-small); line-height: 1.45; color: var(--slate); margin: 0 0 12px; max-width: 34rem; } /* DRAFT: KZ edit pass */
.cps-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.cps-list li { font-size: var(--fs-small); color: var(--ink); padding: 8px 0; }

/* R-CHIP-1: every icon sits in a round disc inside its chip, apart from the label. Construction ported from the Leap Code
   founder-load chips (.lc-band / .lc-band__i: 24px white disc, 1px ring at 8% black, chip padding 6px 16px 6px 7px, gap 8px);
   scaled to a 44px tap target (32px disc, 18px icon), label nudged right by 0.5em so disc, gap and text stay balanced. */
.cps-disc { flex: none; display: inline-grid; place-items: center; inline-size: 1.75em; block-size: 1.75em; border-radius: 50%; background: var(--white); color: var(--ink); font-size: 1em; line-height: 1; box-shadow: 0 0 0 1px rgb(0 0 0 / .1); }
.cps-chip .cps-disc { inline-size: 32px; block-size: 32px; font-size: 18px; }

/* Chips take the node's exact registry colour (ruling N11, R-COL-1 exception): --node-color / --node-ink come from kz_cps_node_style().
   Hover: node-colour border and underlined label. Selected: filled with the node colour, label in --node-ink, check mark and aria-checked. */
.cps-chip { --node-color: var(--orange); --node-ink: var(--ink); appearance: none; display: inline-flex; align-items: center; gap: calc(8px + .5em); font: 500 var(--fs-small)/1.2 var(--f-body); min-height: 44px; padding: 5px 16px 5px 6px; border-radius: 999px; border: 2px solid var(--steel); background: var(--white); color: var(--ink); cursor: pointer; text-align: left; max-width: 100%; }
.cps-chip__label { min-width: 0; overflow-wrap: anywhere; }
.cps-chip__tick { display: none; flex: none; font-weight: 700; margin-inline-start: -2px; }
.cps-chip:hover { border-color: var(--node-color); }
.cps-chip:hover .cps-chip__label { text-decoration: underline; text-decoration-color: var(--node-color); text-decoration-thickness: 2px; text-underline-offset: .22em; }
.cps-chip:hover .cps-disc { box-shadow: 0 0 0 2px var(--node-color); }
.cps-chip[aria-checked="true"] { background: var(--node-color); color: var(--node-ink); border-color: var(--node-color); font-weight: 700; }
.cps-chip[aria-checked="true"] .cps-chip__tick { display: inline; }
.cps-chip[aria-checked="true"]:hover .cps-chip__label { text-decoration-color: currentColor; }
.cps-chip[aria-checked="true"] .cps-disc { box-shadow: 0 0 0 2px var(--node-ink); }
.cps-chip:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; box-shadow: 0 0 0 6px var(--white); }
.cps-out__label { font: 600 var(--fs-micro)/1.3 var(--f-head); letter-spacing: .06em; text-transform: uppercase; color: var(--slate); margin: 28px 0 6px; }
.cps-out { margin: 0; background: var(--peach); border-radius: var(--radius); padding: 16px 20px; }
.cps-out__part { text-decoration: underline; text-decoration-color: var(--node-color, var(--orange)); text-decoration-thickness: 4px; text-underline-offset: .2em; }
.cps-out__addr { font: 700 clamp(1.0625rem, .9rem + 1.2vw, 1.5rem)/1.35 var(--f-head); color: var(--ink); overflow-wrap: anywhere; word-break: break-word; }
@media (prefers-reduced-motion: no-preference) { .cps-chip, .cps-out { transition: background-color .15s var(--ease), color .15s var(--ease), border-color .15s var(--ease); }
@media (prefers-contrast: more) { .cps-chip { border-width: 3px; } } }

/* System page */
.cps-detail { overflow-x: clip; }
.cps-prose { max-width: 46rem; }
.cps-prose p, .cps-prose li { font-size: var(--fs-body); }
.cps-h2 { font: 700 var(--fs-h2)/1.1 var(--f-head); margin: 0 0 20px; }
.cps-tablewrap { overflow-x: auto; margin-bottom: 40px; border: 1px solid var(--hairline); border-radius: var(--radius); background: var(--white); }
.cps-table { width: 100%; border-collapse: collapse; font-size: var(--fs-small); min-width: 0; }
.cps-table caption { text-align: left; font: 700 1.125rem/1.3 var(--f-head); padding: 16px; }
.cps-table th, .cps-table td { text-align: left; vertical-align: top; padding: 12px 16px; border-top: 1px solid var(--hairline); overflow-wrap: anywhere; }
.cps-table th { font-weight: 600; color: var(--ink); }
@media (max-width: 520px) { .cps-table th, .cps-table td { padding: 10px 12px; } }

/* Registry icons: aria-hidden emoji in chips and tables */
.cps-table__ico { margin-inline-end: .75em; vertical-align: middle; }
.cps-table__code { font-family: ui-monospace, Menlo, monospace; font-size: .875em; color: var(--slate); white-space: nowrap; }
/* Home summary panel */
.cps-sum { display: grid; gap: 16px; max-width: 46rem; margin: 0 0 28px; }
.cps-sum__lead { margin: 0; }
.cps-sum__axes { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.cps-sum__axes li { font-size: var(--fs-body); }
.cps-sum__ex { margin: 0; font-size: var(--fs-small); color: var(--slate); }
.cps-sum__ex code { font-weight: 700; color: var(--ink); overflow-wrap: anywhere; }
.cps-sum__cta { margin: 8px 0 0; }
.cps-sum__cta-wrap { text-align: center; margin: 24px 0 0; }
.cps-find .cps-finder { margin-bottom: 0; }
/* Phase F E13: the CPS title is the shared light hero (gc.css .hero, .h-display); its old dark-band rules are gone. */
@media (max-width: 520px) { .cps-table :is(th, td):nth-child(2) { display: none; } } /* codes (gl01..) are shown from 521px up; narrow screens keep icon + name + description */
@media (max-width: 520px) { .cps-table th, .cps-table td { padding: 10px 8px; } .cps-table th[scope="row"] { overflow-wrap: break-word; hyphens: auto; } }

/* HP-06: the address example must wrap at 320px instead of clipping */
.cps-detail code { overflow-wrap: anywhere; }
