/* Design system section (06.11.2026, second pass). Data: debi-ds/design-system/tokens and the colour audit of 18.06.2026.
   Three blocks: primitives under roles (with the contrast note), type by size and weight, the two temperaments of the same tokens.
   The first pass also had an audit block and a contrast block; Lev turned them down (backup/2026-11-06-system-v1/). */

.ds-b { margin-top: 104px; }
.txt + .ds-b { margin-top: 80px; }
.ds-h { max-width: 640px; }
.ds-n { display: block; font: 500 14px/1 var(--pop); color: var(--g); }
.ds-h h3 { margin-top: 10px; font: 500 26px/1.25 var(--pop); letter-spacing: -.015em; }
.ds-h p { margin-top: 12px; font-size: 17px; line-height: 1.6; color: var(--ink-2); }

.ds-card { position: relative; margin-top: 30px; padding: 28px; border-radius: 28px; background: #fff; box-shadow: var(--shadow); container-type: inline-size; }
.ds-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; }
.ds-seg { display: inline-flex; padding: 4px; border-radius: 14px; background: #F3F3F3; }
.ds-seg button { padding: 9px 16px; border-radius: 10px; font: 500 14px/1 var(--sans); color: var(--ink-2); transition: background-color .2s, color .2s, box-shadow .2s; }
.ds-seg button[aria-pressed="true"] { background: #fff; color: var(--ink); box-shadow: 0 1px 3px rgb(17 17 17 / .1); }
.ds-seg button:focus-visible { outline: 2px solid var(--g); outline-offset: 2px; }
.ds-cap { min-height: 1.5em; font-size: 14px; line-height: 1.5; color: var(--ink-2); }
@media (max-width: 700px) {
  .ds-b { margin-top: 80px; }
  .ds-card { padding: 18px; border-radius: 22px; }
  .ds-h h3 { font-size: 22px; }
  .ds-seg button { padding: 8px 12px; font-size: 13px; }
}

/* ── 01 primitives under roles: pick a swatch, lines run to the roles that use it */
.map { display: grid; grid-template-columns: 1fr minmax(240px, 300px); align-items: center; gap: 32px 120px; }
.prims { position: relative; z-index: 1; display: grid; gap: 14px; }
.prims > li { display: grid; grid-template-columns: 74px 1fr; align-items: start; }
.pf { padding-top: 13px; font-size: 13px; color: var(--muted); }
.pr { display: flex; flex-wrap: wrap; gap: 6px; }
.sw { padding: 0; display: grid; justify-items: center; gap: 5px; width: 52px; }
.sw i { width: 44px; height: 44px; border-radius: 12px; background: var(--v); box-shadow: inset 0 0 0 1px rgb(17 17 17 / .06); transition: transform .25s cubic-bezier(.2,.7,.2,1), box-shadow .25s; }
.sw span { font-size: 11.5px; color: var(--muted); }
.sw:hover i { transform: translateY(-2px); }
.sw[aria-pressed="true"] i { box-shadow: inset 0 0 0 1px rgb(17 17 17 / .06), 0 0 0 2px #fff, 0 0 0 4px var(--ink); }
.sw[aria-pressed="true"] span { color: var(--ink); font-weight: 600; }
.sw:focus-visible { outline: 0; }
.sw:focus-visible i { box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--g); }
.links { position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.links path { fill: none; stroke: var(--lc, #05857B); stroke-width: 1.5; opacity: .5; }
.roles { position: relative; z-index: 1; display: flex; flex-direction: column; justify-content: center; min-height: 430px; }   /* the tallest list (Blue/500, 12 roles), so the card keeps its height */
.ro-h { display: flex; align-items: baseline; gap: 10px; }
.ro-p { font: 500 19px/1.2 var(--pop); }
.ro-n { font-size: 14px; color: var(--muted); }
.ro-l { display: grid; justify-items: start; gap: 7px; margin-top: 14px; }
.ro-note { max-width: 300px; margin-top: 16px; padding: 12px 14px; border-radius: 14px; background: var(--g-50); font-size: 13.5px; line-height: 1.5; color: var(--ink-2); }
.ro-note:empty { display: none; }
.ro-l li { padding: 6px 12px; border-radius: 10px; background: #F4F5F5; font-size: 13.5px; font-weight: 500; color: var(--ink); }
@media (prefers-reduced-motion: no-preference) {
  .ro-l li { animation: ro-in .45s cubic-bezier(.2,.7,.2,1) both; animation-delay: calc(var(--i, 0) * 30ms); }
  @keyframes ro-in { from { opacity: 0; transform: translateX(8px); } }
}
@media (max-width: 900px) {
  .map { grid-template-columns: 1fr; gap: 28px; }
  .links { display: none; }
  .roles { min-height: 0; }
  .ro-l { display: flex; flex-wrap: wrap; }
}
@media (max-width: 520px) {
  .prims > li { grid-template-columns: 1fr; gap: 6px; }
  .pf { padding-top: 0; }
  .sw { width: 44px; }
  .sw i { width: 38px; height: 38px; border-radius: 10px; }
}

/* ── 02 type: one specimen for the picked heading style (desktop or mobile size), and the text matrix next to it */
.ty { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 32px 56px; margin-top: 24px; }
.ty-spec { height: 84px; overflow: hidden; font: 700 var(--d)/var(--dl) var(--sans); white-space: nowrap; text-overflow: ellipsis; display: flex; align-items: flex-end; transition: font-size .4s cubic-bezier(.2,.7,.2,1), line-height .4s cubic-bezier(.2,.7,.2,1); }
.type[data-v="m"] .ty-spec { font-size: var(--m); line-height: var(--ml); }
.ty-list { margin-top: 14px; border-top: 1px solid var(--line); }
.ty-list button { display: grid; grid-template-columns: 1fr auto; align-items: center; width: 100%; padding: 9px 10px; border-bottom: 1px solid var(--line); border-radius: 0; text-align: left; font-size: 14px; transition: background-color .2s; }
.ty-list b { font-weight: 500; }
.ty-list em { font-style: normal; font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; }
.ty-list button:hover, .ty-list button[aria-pressed="true"] { background: var(--g-50); }
.ty-list button[aria-pressed="true"] b { font-weight: 600; }
.ty-list button:focus-visible { outline: 2px solid var(--g); outline-offset: -2px; }
.type[data-v="d"] .mv, .type[data-v="m"] .dv { display: none; }
.mx { display: grid; grid-template-columns: 72px repeat(3, minmax(0, 1fr)); align-content: start; }
.mx > span { display: flex; flex-direction: column; justify-content: center; min-height: 44px; padding: 6px 10px; border-bottom: 1px solid var(--line); }
.mx-c, .mx-w { min-height: 32px !important; font-size: 13px; color: var(--muted); }
.mx-s { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.mx-s b { font-size: 13.5px; font-weight: 600; color: var(--ink); }
.mx-t { position: relative; isolation: isolate; font: var(--fw) var(--fs)/var(--lh) var(--sans); white-space: nowrap; cursor: default; outline: 0; }
.mx-t::before { content: ''; position: absolute; z-index: -1; inset: 3px 2px; border-radius: 9px; background: var(--g-50); opacity: 0; transition: opacity .2s; }   /* the highlight, so the row lines stay straight */
.mx-t:hover::before, .mx-t:focus-visible::before, .mx-t.on::before { opacity: 1; }
@media (max-width: 960px) { .ty { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 520px) {
  .ty-spec { height: 64px; }
  .mx { grid-template-columns: 52px repeat(3, minmax(0, 1fr)); }
  .mx > span { padding: 6px 4px; }
  .mx-t { white-space: normal; }
}

/* ── 03 two temperaments: the same card, platform or landing and website */
.tp { display: grid; grid-template-columns: 1.15fr 1fr; align-items: center; gap: 28px 48px; margin-top: 24px; }
.tp-stage { position: relative; display: grid; place-items: center; min-height: 360px; padding: 40px 24px; border-radius: 20px; background: #F9F9F9; overflow: hidden; isolation: isolate; }
.tp-stage::before { content: ''; position: absolute; inset: 0; z-index: -1; background: linear-gradient(135deg, #E9F8F7 0%, #4DA19F 100%); opacity: 0; transition: opacity .6s; }
.tp-stage::after { content: ''; position: absolute; z-index: -1; right: 6%; top: 10%; width: 190px; height: 190px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #00BDB0, #0289E0); opacity: 0; transform: scale(.8); transition: opacity .6s, transform .8s cubic-bezier(.2,.7,.2,1); }
.temper[data-v="l"] .tp-stage::before { opacity: 1; }
.temper[data-v="l"] .tp-stage::after { opacity: .8; transform: none; }
.tp-card { display: grid; justify-items: start; width: min(100%, 340px); padding: 24px; border-radius: 16px; background: #fff; box-shadow: 0 0 0 1px #EBEBEB, 0 4px 20px rgb(0 0 0 / .08); transition: border-radius .5s cubic-bezier(.2,.7,.2,1), box-shadow .5s, background-color .5s; }
.temper[data-v="l"] .tp-card { border-radius: 32px; background: rgb(255 255 255 / .55); -webkit-backdrop-filter: blur(28px) saturate(150%); backdrop-filter: blur(28px) saturate(150%); box-shadow: 0 0 0 1px rgb(255 255 255 / .65), 0 4px 8px rgb(0 0 0 / .05); }
.tp-chip { padding: 4px 10px; border-radius: 8px; background: #DFF2F1; color: #03736B; font-size: 12px; font-weight: 600; transition: border-radius .5s; }
.tp-name { margin-top: 16px; font: 700 20px/1.3 var(--sans); }
.tp-cap { margin-top: 14px; font-size: 13px; color: #5F6368; }
.tp-val { font: 700 36px/1.15 var(--sans); letter-spacing: -.02em; }
.tp-btns { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.tp-btns > span { display: inline-flex; align-items: center; height: 40px; padding: 0 16px; border-radius: 12px; font-size: 14px; font-weight: 600; transition: border-radius .5s; }
.tp-b1 { background: #05857B; color: #fff; }
.tp-b2 { background: #EAF8F7; color: #03736B; }
.temper[data-v="l"] .tp-chip, .temper[data-v="l"] .tp-btns > span { border-radius: 999px; }
.tp-read > div { display: grid; grid-template-columns: 140px 1fr; gap: 16px; padding: 12px 0; border-top: 1px solid var(--line); }
.tp-read > div:first-child { border-top: 0; }
.tp-read dt { font-size: 13.5px; color: var(--muted); }
.tp-read dd { font-size: 15px; font-weight: 500; }
.temper[data-v="p"] .vl, .temper[data-v="l"] .vp { display: none; }
.tp-read .same dd { color: var(--g-ink); }
.rad { display: flex; flex-wrap: wrap; gap: 16px 26px; margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--line); }
.rad li { display: grid; justify-items: center; gap: 8px; font-size: 12.5px; color: var(--muted); opacity: .3; transition: opacity .4s; }
.rad i { width: 48px; height: 48px; border-top: 2px solid var(--ink); border-left: 2px solid var(--ink); border-top-left-radius: var(--r); }   /* one corner, so 24 and 32 don't turn into circles */
.rad-cap { margin-top: 14px; font-size: 13.5px; color: var(--ink-2); }
.temper[data-v="p"] .rad-cap .vl, .temper[data-v="l"] .rad-cap .vp { display: none; }
.temper[data-v="p"] .rad .in-p, .temper[data-v="l"] .rad .in-l { opacity: 1; }
@media (max-width: 900px) { .tp { grid-template-columns: 1fr; } }
@media (max-width: 520px) {
  .tp-stage { min-height: 300px; padding: 28px 16px; }
  .tp-read > div { grid-template-columns: 1fr; gap: 2px; }
  .rad { gap: 14px 18px; }
  .rad i { width: 36px; height: 36px; }
}
@media (prefers-reduced-motion: reduce) {
  .ty-spec, .tp-card, .tp-chip, .tp-btns > span, .tp-stage::before, .tp-stage::after { transition: none !important; }
}

/* still frames (?still): everything in its end state */
.ds-still #system *, .ds-still #system *::before, .ds-still #system *::after { transition: none !important; animation: none !important; }
