/* Layout: black bands (header, hero, sections, support, footer) frame a cream reading surface.
   One committed look in every viewer theme: it is the organisation's identity. Two colours only. Hairline panels, mono labels, one marker highlight, sharp 6px corners. */
:root {
  color-scheme: light;
  /* reading surface */
  --paper: #f3e9d2; --ink: #0a0a09; --muted: #55514a; --line: rgba(10, 10, 9, .18); --card: #f9f2e2; --soft: rgba(10, 10, 9, .055);
  --mark-bg: #0a0a09; --mark-fg: #f3e9d2;
  /* bands keep the same look in both themes */
  --band: #0a0a09; --band-ink: #f3e9d2; --band-muted: #a39c8b; --band-line: rgba(243, 233, 210, .18); --band-card: #141412; --band-soft: rgba(243, 233, 210, .065);
  /* type */
  --body: "IBM Plex Sans Arabic", "Segoe UI", Tahoma, Arial, sans-serif;
  --mono: "IBM Plex Mono", "IBM Plex Sans Arabic", "Segoe UI", Tahoma, monospace;
  --t-xs: .78rem; --t-sm: .9rem; --t-lg: 1.14rem; --t-xl: 1.42rem;
  --t-2xl: clamp(1.6rem, 3.2vw, 2.3rem); --t-3xl: clamp(2.1rem, 5.6vw, 3.9rem);
  --r: 6px; --r-lg: 12px; --bar: 62px;
  --gut-l: max(clamp(16px, 4vw, 32px), env(safe-area-inset-left, 0px));
  --gut-r: max(clamp(16px, 4vw, 32px), env(safe-area-inset-right, 0px));
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { font-size: 16px; -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--body); font-size: 1rem; line-height: 1.85; -webkit-font-smoothing: antialiased; }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 60; background: var(--band); }
h1, h2, h3, h4, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
h1, h2, h3 { line-height: 1.35; font-weight: 700; text-wrap: balance; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 4px; }
button { font: inherit; color: inherit; cursor: pointer; background: none; border: 0; padding: 0; }
input { font: inherit; color: inherit; }
img, svg { display: block; max-width: 100%; }
svg { fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.ltr { direction: ltr; unicode-bidi: isolate; }

.wrap { width: 100%; max-width: 1180px; margin-inline: auto; padding-left: var(--gut-l); padding-right: var(--gut-r); }
.band { color-scheme: dark; --paper: var(--band); --ink: var(--band-ink); --muted: var(--band-muted); --line: var(--band-line); --card: var(--band-card); --soft: var(--band-soft); --mark-bg: var(--band-ink); --mark-fg: var(--band); background: var(--paper); color: var(--ink); }
.surface { background: var(--paper); color: var(--ink); }
.inv { --paper: var(--mark-bg); --ink: var(--mark-fg); --muted: color-mix(in srgb, var(--mark-fg) 72%, transparent); --line: color-mix(in srgb, var(--mark-fg) 24%, transparent); --soft: color-mix(in srgb, var(--mark-fg) 9%, transparent); --card: var(--mark-bg); background: var(--paper); color: var(--ink); }
.dots { background-image: radial-gradient(var(--line) 1px, transparent 1px); background-size: 22px 22px; }
.pad { padding-block: clamp(52px, 8vw, 96px); }

/* ---------- small parts ---------- */
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font: 500 var(--t-sm) var(--body); color: var(--muted); }
.eyebrow i { width: 7px; height: 7px; border-radius: 50%; background: var(--ink); flex: none; }
.mark { background: var(--mark-bg); color: var(--mark-fg); padding: .02em .28em .1em; border-radius: var(--r); box-decoration-break: clone; -webkit-box-decoration-break: clone; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 44px; padding: 8px 18px; border: 1px solid var(--line); border-radius: var(--r); font-weight: 600; font-size: var(--t-sm); text-decoration: none; transition: background .2s, color .2s, border-color .2s; }
.btn:hover { border-color: var(--ink); }
.btn-solid { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.btn-solid:hover { background: transparent; color: var(--ink); }
.btn svg { width: 16px; height: 16px; flex: none; }
.ico { display: inline-grid; place-items: center; width: 22px; height: 22px; flex: none; }
.ico svg { width: 100%; height: 100%; }
.ui { display: inline-block; padding: 0 .42em; border: 1px solid var(--line); border-radius: 4px; background: var(--soft); font: 500 .86em var(--mono); line-height: 1.6; white-space: nowrap; unicode-bidi: isolate; }
kbd { display: inline-block; min-width: 1.9em; padding: 0 .5em; border: 1px solid var(--ink); border-bottom-width: 3px; border-radius: 5px; font: 500 .84em var(--mono); line-height: 1.7; text-align: center; unicode-bidi: isolate; }
.todo { display: inline-block; padding: 0 .5em; border: 1px dashed var(--ink); border-radius: 4px; font-size: .86em; line-height: 1.7; }
.sec-head { display: grid; gap: 10px; max-width: 46rem; margin-bottom: clamp(26px, 4vw, 44px); }
.sec-head h2 { font-size: var(--t-2xl); }
.sec-head p:not(.eyebrow) { color: var(--muted); }

/* ---------- header ---------- */
.top { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50; border-bottom: 1px solid var(--line); }
.top-row { display: flex; align-items: center; gap: 14px; min-height: var(--bar); }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; min-width: 0; }
.brand-mark { display: grid; place-items: center; width: 36px; height: 36px; border-radius: var(--r); background: var(--ink); color: var(--paper); flex: none; overflow: hidden; }
.brand-mark svg { width: 20px; height: 20px; stroke-width: 1.9; }
.brand-mark img { width: 100%; height: 100%; object-fit: cover; }
.brand-txt { display: grid; line-height: 1.3; min-width: 0; }
.brand-txt b { font-size: 1rem; white-space: nowrap; }
.brand-txt small { font-size: var(--t-xs); color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nav { display: flex; gap: 2px; margin-inline: auto; }
.nav a { padding: 8px 12px; border-radius: var(--r); font-size: var(--t-sm); color: var(--muted); text-decoration: none; white-space: nowrap; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--ink); background: var(--soft); }
.top-tools { display: flex; align-items: center; gap: 8px; margin-inline-start: auto; }
.nav + .top-tools { margin-inline-start: 0; }
.icon-btn { display: inline-grid; place-items: center; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: var(--r); }
.icon-btn:hover { border-color: var(--ink); }
.icon-btn svg { width: 19px; height: 19px; }
.burger { display: none; }
@media (max-width: 1020px) {
  .nav { display: none; position: absolute; inset-inline: 0; top: 100%; flex-direction: column; gap: 0; margin: 0; padding: 8px var(--gut-r) 14px var(--gut-l); background: var(--paper); border-bottom: 1px solid var(--line); }
  .nav.open { display: flex; }
  .nav a { padding: 12px 6px; border-bottom: 1px solid var(--line); border-radius: 0; font-size: 1rem; color: var(--ink); }
  .nav a:last-child { border-bottom: 0; }
  .burger { display: inline-grid; }
}
@media (max-width: 560px) { .top-cta span { display: none; } .top-cta { width: 44px; padding: 0; } .brand-txt small { display: none; } }

/* ---------- search ---------- */
.search { position: relative; display: flex; align-items: center; gap: 12px; padding: 0 16px; min-height: 58px; border: 1px solid var(--ink); border-radius: var(--r-lg); background: var(--card); }
.search > svg { width: 20px; height: 20px; flex: none; color: var(--muted); }
.search input { flex: 1; min-width: 0; height: 56px; border: 0; outline: 0; background: transparent; font-size: 1.02rem; }
.search input::placeholder { color: var(--muted); opacity: 1; }
.search input::-webkit-search-cancel-button { display: none; }
.search kbd { border-color: var(--line); color: var(--muted); }
.results { position: absolute; inset-inline: -1px; top: calc(100% + 8px); z-index: 20; max-height: min(60vh, 420px); overflow: auto; border: 1px solid var(--ink); border-radius: var(--r-lg); background: var(--card); box-shadow: 0 24px 50px rgba(0, 0, 0, .35); }
.results li a { display: grid; gap: 2px; padding: 12px 16px; border-bottom: 1px solid var(--line); text-decoration: none; }
.results li:last-child a { border-bottom: 0; }
.results li a:hover, .results li.on a { background: var(--ink); color: var(--paper); }
.results li a:hover small, .results li.on small { color: inherit; opacity: .75; }
.results b { font-weight: 600; }
.results small { font-size: var(--t-xs); color: var(--muted); }
.results .none { padding: 16px; color: var(--muted); font-size: var(--t-sm); }
.search-ov { position: fixed; inset: 0; z-index: 80; display: grid; align-items: start; padding: calc(env(safe-area-inset-top, 0px) + 12vh) var(--gut-r) 24px var(--gut-l); background: rgba(0, 0, 0, .62); }
.search-ov .search { width: 100%; max-width: 640px; margin-inline: auto; }
.search-ov .results { position: static; margin-top: 8px; box-shadow: none; }
.search-ov .ov-box { width: 100%; max-width: 640px; margin-inline: auto; }

/* ---------- home ---------- */
.admin { border-bottom: 1px dashed var(--line); font-size: var(--t-sm); }
.admin .wrap { padding-block: 10px; display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: baseline; }
.admin code { font: 500 .86em var(--mono); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
.hero-copy { display: grid; gap: 22px; min-width: 0; }
.hero h1 { font-size: var(--t-3xl); line-height: 1.3; }
.lead { font-size: var(--t-lg); color: var(--muted); max-width: 34rem; }
.quick { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.quick span { font: 500 var(--t-xs) var(--body); color: var(--muted); margin-inline-end: 4px; }
.chip { display: inline-flex; align-items: center; min-height: 36px; padding: 4px 13px; border: 1px solid var(--line); border-radius: 100px; font-size: var(--t-sm); text-decoration: none; }
.chip:hover { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.demo { border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--card); overflow: hidden; }
.demo-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 18px; border-bottom: 1px solid var(--line); font-size: var(--t-sm); color: var(--muted); }
.demo-bar i { flex: 1; max-width: 150px; height: 4px; border-radius: 4px; background: var(--line); overflow: hidden; position: relative; }
.demo-bar i::after { content: ""; position: absolute; inset: 0; background: var(--ink); transform-origin: 100% 50%; transform: scaleX(0); animation: demoBar 11s linear infinite; }
.demo li { display: flex; align-items: center; gap: 14px; padding: 15px 18px; border-bottom: 1px solid var(--line); }
.demo li b { font: 500 var(--t-xs) var(--mono); color: var(--muted); }
.demo li span { flex: 1; min-width: 0; }
.demo li em { position: relative; width: 22px; height: 22px; border: 1.5px solid var(--line); border-radius: 5px; flex: none; }
.demo li em::after { content: ""; position: absolute; inset: 3px; border-radius: 2px; background: var(--ink); transform: scale(0); animation: demoTick 11s infinite; }
.demo li:nth-child(1) em::after { animation-delay: .6s; } .demo li:nth-child(2) em::after { animation-delay: 2.2s; }
.demo li:nth-child(3) em::after { animation-delay: 3.8s; } .demo li:nth-child(4) em::after { animation-delay: 5.4s; }
.demo-foot { display: flex; align-items: center; gap: 10px; padding: 13px 18px; font-size: var(--t-sm); color: var(--muted); }
.demo-foot .ico { width: 18px; height: 18px; }
@keyframes demoTick { 0%, 3% { transform: scale(0); } 7%, 80% { transform: scale(1); } 86%, 100% { transform: scale(0); } }
@keyframes demoBar { 0% { transform: scaleX(0); } 62%, 84% { transform: scaleX(1); } 90%, 100% { transform: scaleX(0); } }

.start-list { border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; background: var(--card); }
.start-list a { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto 24px; align-items: center; gap: 6px 18px; padding: 18px 20px; border-bottom: 1px solid var(--line); text-decoration: none; transition: background .2s, color .2s; }
.start-list li:last-child a { border-bottom: 0; }
.start-list a:hover { background: var(--ink); color: var(--paper); }
.start-list .n { font: 500 var(--t-sm) var(--mono); color: var(--muted); }
.start-list b { display: block; font-size: var(--t-lg); line-height: 1.5; }
.start-list small { display: block; font-size: var(--t-sm); color: var(--muted); line-height: 1.7; }
.start-list .time { font: 400 var(--t-xs) var(--body); color: var(--muted); white-space: nowrap; }
.start-list a:hover :is(.n, small, .time) { color: inherit; opacity: .75; }
.start-list .ico { width: 20px; height: 20px; }

.sec-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.sec-card { display: grid; grid-template-rows: auto auto 1fr auto; gap: 12px; padding: 22px; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--card); min-width: 0; }
.sec-card > .ico { width: 40px; height: 40px; padding: 9px; border: 1px solid var(--line); border-radius: var(--r); }
.sec-card h3 { font-size: var(--t-xl); }
.sec-card h3 a { text-decoration: none; }
.sec-card > p { color: var(--muted); font-size: var(--t-sm); }
.sec-card ul { display: grid; align-content: start; border-top: 1px solid var(--line); }
.sec-card li a { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: var(--t-sm); text-decoration: none; }
.sec-card li a:hover { text-decoration: underline; }
.sec-card li .ico { width: 15px; height: 15px; color: var(--muted); }
.sec-card .more { font: 500 var(--t-xs) var(--body); color: var(--muted); text-decoration: none; }
.sec-card .more:hover { color: var(--ink); }

.tip-card { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 20px 40px; align-items: end; padding: clamp(24px, 4vw, 44px); border: 1px solid var(--ink); border-radius: var(--r-lg); }
.tip-card h2 { font-size: var(--t-2xl); margin-block: 12px 10px; }
.tip-card p { max-width: 40rem; }
.tip-card .acts { display: flex; flex-wrap: wrap; gap: 10px; }

.support-grid { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(28px, 5vw, 64px); align-items: start; }
.support-grid h2 { font-size: var(--t-2xl); margin-block: 12px; }
.support-grid .lead { margin-bottom: 22px; }

.foot { border-top: 1px solid var(--line); font-size: var(--t-sm); color: var(--muted); }
.foot .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 24px; padding-block: 22px; }
.foot a { text-decoration: none; } .foot a:hover { color: var(--ink); }
.foot nav { display: flex; flex-wrap: wrap; gap: 6px 18px; }

/* ---------- contacts ---------- */
.contacts { border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--card); overflow: hidden; }
.contacts > div { display: grid; grid-template-columns: minmax(96px, 150px) minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.contacts > div:last-child { border-bottom: 0; }
.contacts dt { font-size: var(--t-sm); color: var(--muted); }
.contacts dd { margin: 0; font-weight: 600; min-width: 0; overflow-wrap: anywhere; }
.copy { display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 2px 10px; border: 1px solid var(--line); border-radius: var(--r); font-size: var(--t-xs); white-space: nowrap; }
.copy:hover { border-color: var(--ink); }
.copy svg { width: 14px; height: 14px; }

/* ---------- inner page hero ---------- */
.p-hero .wrap { padding-block: clamp(34px, 5vw, 60px); display: grid; gap: 16px; }
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: var(--t-sm); color: var(--muted); }
.crumbs a { text-decoration: none; } .crumbs a:hover { color: var(--ink); text-decoration: underline; }
.crumbs span[aria-hidden] { opacity: .6; }
.p-hero h1 { font-size: clamp(1.8rem, 4.4vw, 3rem); max-width: 22ch; }
.p-hero .lead { max-width: 44rem; }
.meta { display: flex; flex-wrap: wrap; gap: 8px; }
.meta > span { display: inline-flex; align-items: center; gap: 8px; min-height: 34px; padding: 3px 12px; border: 1px solid var(--line); border-radius: 100px; font-size: var(--t-sm); }
.meta .ico { width: 15px; height: 15px; color: var(--muted); }

.rows { border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--card); overflow: hidden; }
.rows a { display: grid; grid-template-columns: minmax(0, 1fr) auto 22px; align-items: center; gap: 6px 18px; padding: 18px 20px; border-bottom: 1px solid var(--line); text-decoration: none; transition: background .2s, color .2s; }
.rows li:last-child a { border-bottom: 0; }
.rows a:hover { background: var(--ink); color: var(--paper); }
.rows b { display: block; font-size: var(--t-lg); }
.rows small { display: block; font-size: var(--t-sm); color: var(--muted); line-height: 1.7; }
.rows .time { font: 400 var(--t-xs) var(--body); color: var(--muted); white-space: nowrap; }
.rows a:hover :is(small, .time) { color: inherit; opacity: .75; }

/* ---------- guide ---------- */
.g-grid { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: clamp(28px, 4vw, 56px); align-items: start; padding-block: clamp(30px, 5vw, 56px) clamp(52px, 8vw, 96px); }
.g-main { display: grid; gap: 22px; min-width: 0; }
.g-side { position: sticky; top: calc(var(--bar) + env(safe-area-inset-top, 0px) + 20px); display: grid; gap: 14px; }
.side-box { border: 1px solid var(--line); border-radius: var(--r-lg); padding: 16px 18px; }
.side-box h2 { font: 500 var(--t-sm) var(--body); color: var(--muted); margin-bottom: 8px; }
.side-box li a { display: block; padding: 7px 0; border-bottom: 1px solid var(--line); font-size: var(--t-sm); text-decoration: none; line-height: 1.6; }
.side-box li:last-child a { border-bottom: 0; }
.side-box li a:hover { text-decoration: underline; }
.side-box li a[aria-current="page"] { font-weight: 700; }
.side-box p { font-size: var(--t-sm); color: var(--muted); }
.side-box .btn { width: 100%; margin-top: 12px; }
.needs { border: 1px solid var(--line); border-radius: var(--r-lg); padding: 16px 18px; }
.needs h2 { font: 500 var(--t-sm) var(--body); color: var(--muted); margin-bottom: 6px; }
.needs li { display: flex; gap: 10px; align-items: baseline; }
.needs li::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--ink); flex: none; transform: translateY(-2px); }
.progress { display: flex; align-items: center; gap: 14px; font-size: var(--t-sm); }
.progress .p-bar { flex: 1; height: 6px; border-radius: 6px; background: var(--line); overflow: hidden; }
.progress .p-bar i { display: block; height: 100%; width: 0; background: var(--ink); transition: width .35s; }
.progress .p-text { font: 500 var(--t-sm) var(--body); white-space: nowrap; }
.progress .p-reset { font-size: var(--t-xs); text-decoration: underline; color: var(--muted); }
.b-title { font-size: var(--t-xl); margin-top: 14px; }
.steps { display: grid; gap: 12px; }
.step { position: relative; display: grid; grid-template-columns: 46px minmax(0, 1fr); gap: 0 18px; padding: 20px 20px 22px; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--card); }
.step-num { display: grid; place-items: center; width: 46px; height: 46px; border: 1px solid var(--line); border-radius: var(--r); font: 500 var(--t-sm) var(--mono); transition: background .25s, color .25s; }
.step.done { border-color: var(--ink); }
.step.done .step-num { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.step-body { display: grid; gap: 16px; min-width: 0; }
.step-text { display: grid; gap: 6px; min-width: 0; padding-inline-end: 76px; }
.step h3 { font-size: var(--t-lg); line-height: 1.6; }
.step-check { position: absolute; top: 20px; inset-inline-end: 20px; display: inline-flex; align-items: center; gap: 8px; min-height: 34px; padding: 2px 10px; border: 1px solid var(--line); border-radius: var(--r); font-size: var(--t-xs); cursor: pointer; user-select: none; }
.step-check input { appearance: none; -webkit-appearance: none; width: 16px; height: 16px; margin: 0; border: 1.5px solid var(--ink); border-radius: 4px; display: grid; place-items: center; cursor: pointer; }
.step-check input::after { content: ""; width: 8px; height: 8px; border-radius: 2px; background: var(--paper); transform: scale(0); transition: transform .15s; }
.step-check input:checked { background: var(--ink); }
.step-check input:checked::after { transform: scale(1); }
.step-check:has(input:focus-visible) { outline: 2px solid currentColor; outline-offset: 3px; }
.step-art { display: grid; gap: 8px; min-width: 0; }
.step-art figcaption, .art-block figcaption { font: 400 var(--t-xs) var(--body); color: var(--muted); }
.step-art.shot img { border: 1px solid var(--line); border-radius: var(--r); }
@media (min-width: 860px) { .step.has-art .step-body { grid-template-columns: minmax(0, 1fr) minmax(250px, 320px); gap: 26px; align-items: start; } .step.has-art .step-text { padding-inline-end: 0; } .step.has-art .step-art { padding-top: 44px; } }
.done-strip { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 20px; border-radius: var(--r-lg); }
.done-strip b { display: flex; align-items: center; gap: 10px; }

.note { display: grid; grid-template-columns: 24px minmax(0, 1fr); gap: 12px; padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--r-lg); }
.note .ico { width: 24px; height: 24px; margin-top: 3px; }
.note b { display: block; }
.note p { color: var(--muted); }
.note.inv { border-color: var(--paper); }

.list { display: grid; gap: 0; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--card); overflow: hidden; }
.list > li { display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 14px; padding: 14px 18px; border-bottom: 1px solid var(--line); align-items: start; }
.list > li:last-child { border-bottom: 0; }
.list .li-mark { display: grid; place-items: center; width: 30px; height: 30px; border: 1px solid var(--line); border-radius: var(--r); font: 500 var(--t-xs) var(--mono); margin-top: 1px; }
.list .li-mark svg { width: 15px; height: 15px; }
.list-x .li-mark { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.list-dot .li-mark { border: 0; }
.list-dot .li-mark::after { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--ink); }
.list b { display: block; }
.list p { color: var(--muted); }
.list li > div > p:only-child { color: var(--ink); }

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 12px; }
.cards > div { display: grid; gap: 6px; align-content: start; padding: 18px; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--card); min-width: 0; }
.cards .tag { justify-self: start; max-width: 100%; padding: 0 8px; border: 1px solid var(--line); border-radius: 4px; font: 500 var(--t-xs) var(--mono); line-height: 1.8; overflow-wrap: anywhere; unicode-bidi: isolate; }
.cards b { font-size: var(--t-lg); }
.cards p { color: var(--muted); font-size: var(--t-sm); }

.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--card); }
table { width: 100%; border-collapse: collapse; font-size: var(--t-sm); }
th, td { padding: 13px 16px; text-align: start; vertical-align: top; border-bottom: 1px solid var(--line); }
th { font: 500 var(--t-xs) var(--body); color: var(--muted); white-space: nowrap; }
tr:last-child td { border-bottom: 0; }
td:first-child { font-weight: 700; white-space: nowrap; }
@media (max-width: 720px) {
  .table-wrap { border: 0; background: none; overflow: visible; }
  table, tbody, tr, td { display: block; } thead { display: none; }
  tr { border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--card); margin-bottom: 10px; padding: 6px 0; }
  td { border: 0; padding: 7px 16px; } td:first-child { font-size: var(--t-lg); }
  td:not(:first-child)::before { content: attr(data-label); display: block; font: 500 var(--t-xs) var(--body); color: var(--muted); }
}

.sample { border: 1px dashed var(--ink); border-radius: var(--r-lg); overflow: hidden; }
.sample-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 16px; border-bottom: 1px dashed var(--line); font: 500 var(--t-xs) var(--body); color: var(--muted); }
.sample-body { padding: 16px; display: grid; gap: 2px; }

.art-block { display: grid; gap: 10px; justify-items: center; padding: clamp(16px, 3vw, 28px); border: 1px solid var(--line); border-radius: var(--r-lg); }
.art-block > .m, .art-block > .m-duo { width: 100%; max-width: 560px; }

details { border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--card); }
details + details { margin-top: 8px; }
summary { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 14px 18px; font-weight: 600; cursor: pointer; list-style: none; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; font: 400 1.2rem var(--mono); flex: none; }
details[open] summary::after { content: "–"; }
details > div { padding: 0 18px 16px; color: var(--muted); }

.related { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; }
.related a { display: grid; gap: 4px; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--r-lg); text-decoration: none; }
.related a:hover { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.related small { font: 400 var(--t-xs) var(--body); color: var(--muted); }
.related a:hover small { color: inherit; opacity: .75; }
.missing-note { padding: 16px 18px; border: 1px dashed var(--line); border-radius: var(--r-lg); font-size: var(--t-sm); display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; }
.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pager a { display: grid; gap: 2px; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--r-lg); text-decoration: none; min-width: 0; }
.pager a:hover { border-color: var(--ink); }
.pager small { font: 400 var(--t-xs) var(--body); color: var(--muted); }
.pager .next { text-align: end; grid-column: 2; }
@media (max-width: 960px) { .g-grid { grid-template-columns: minmax(0, 1fr); } .g-side { position: static; } }

/* quiz + self check */
.quiz, .selfcheck { display: grid; gap: 14px; padding: clamp(18px, 3vw, 28px); border: 1px solid var(--ink); border-radius: var(--r-lg); }
.quiz h2, .selfcheck h2 { font-size: var(--t-xl); }
.quiz > p, .selfcheck > p { color: var(--muted); }
.quiz-item { display: grid; gap: 12px; padding-top: 14px; border-top: 1px solid var(--line); }
.quiz-actions { display: flex; gap: 10px; }
.quiz-actions button { flex: 1; min-height: 46px; border: 1px solid var(--ink); border-radius: var(--r); font-weight: 600; }
.quiz-actions button:hover:not(:disabled), .quiz-actions button.picked { background: var(--ink); color: var(--paper); }
.quiz-actions button:disabled { cursor: default; opacity: .45; }
.quiz-actions button.picked:disabled { opacity: 1; }
.quiz-result { padding: 12px 16px; border-radius: var(--r); }
.quiz-result b { display: flex; align-items: center; gap: 8px; }
.quiz-result p { color: var(--muted); font-size: var(--t-sm); }
.quiz-score { font-weight: 700; }
.selfcheck li label { display: flex; gap: 12px; align-items: flex-start; padding: 11px 0; border-top: 1px solid var(--line); cursor: pointer; }
.selfcheck input { appearance: none; -webkit-appearance: none; flex: none; width: 22px; height: 22px; margin: 4px 0 0; border: 1.5px solid var(--ink); border-radius: 5px; display: grid; place-items: center; cursor: pointer; }
.selfcheck input::after { content: ""; width: 11px; height: 11px; border-radius: 2px; background: var(--paper); transform: scale(0); transition: transform .15s; }
.selfcheck input:checked { background: var(--ink); }
.selfcheck input:checked::after { transform: scale(1); }
.sc-result { padding: 14px 16px; border: 1px dashed var(--line); border-radius: var(--r); font-weight: 600; }
.sc-result.inv { border-style: solid; }

/* tips */
.tips-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 12px; }
.tip { display: grid; gap: 6px; align-content: start; padding: 18px; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--card); }
.tip .n { font: 500 var(--t-xs) var(--body); color: var(--muted); }
.tip b { font-size: var(--t-lg); line-height: 1.6; }
.tip p { color: var(--muted); font-size: var(--t-sm); }
.tip a { font-size: var(--t-sm); }

/* ---------- illustrations ---------- */
.m { font-size: .8rem; line-height: 1.6; color: var(--ink); text-align: start; }
.m-win { border: 1px solid var(--ink); border-radius: 10px; background: var(--paper); overflow: hidden; }
.m-top { display: flex; align-items: center; gap: 5px; padding: 8px 10px; border-bottom: 1px solid var(--line); direction: ltr; }
.m-top i { width: 7px; height: 7px; border-radius: 50%; background: var(--line); }
.m-top span { margin-left: 8px; font: 400 .68rem var(--mono); color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.m-body { display: grid; gap: 9px; padding: 14px; }
.m-phone { width: 176px; max-width: 100%; margin-inline: auto; padding: 9px 8px 14px; border: 1.5px solid var(--ink); border-radius: 24px; background: var(--paper); }
.m-notch { width: 46px; height: 5px; border-radius: 5px; background: var(--line); margin: 3px auto 8px; }
.m-phone .m-body { padding: 8px 6px; }
.m-duo { display: grid; grid-template-columns: minmax(0, 1fr) 18px minmax(0, auto); align-items: center; gap: 8px; direction: ltr; }
.m-duo > .m { direction: rtl; }
.m-duo .m-phone { width: 128px; }
.m-arrow { height: 1.5px; background: repeating-linear-gradient(90deg, var(--ink) 0 4px, transparent 4px 8px); }
.m-h { font-weight: 700; font-size: .9rem; }
.m-p { color: var(--muted); font-size: .74rem; }
.m-lab { font-size: .7rem; color: var(--muted); margin-bottom: -5px; }
.m .center, .m-center { text-align: center; justify-self: center; }
.m-field { padding: 6px 9px; border: 1px solid var(--line); border-radius: 5px; background: var(--card); font: 400 .72rem var(--mono); color: var(--muted); direction: ltr; text-align: left; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.m-field.ar { direction: rtl; text-align: right; font-family: var(--body); }
.m-field.tall { min-height: 46px; white-space: normal; }
.m-field.center { text-align: center; font-size: 1rem; font-weight: 500; color: var(--ink); letter-spacing: .12em; }
.m-btn { display: inline-flex; align-items: center; justify-content: center; padding: 4px 11px; border: 1px solid var(--line); border-radius: 5px; font-size: .72rem; font-weight: 600; white-space: nowrap; }
.m-btn.on { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.m-btn.wide { display: flex; width: 100%; }
.m-link { font-size: .74rem; text-decoration: underline; padding: 1px 4px; }
.m-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.m-row.end { justify-content: flex-end; }
.m-phone .m-row > * { flex: 1; }
.m-bar { display: flex; gap: 6px; flex-wrap: wrap; }
.m-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.m-cols > div { display: grid; gap: 9px; align-content: start; min-width: 0; }
.m-menu { border: 1px solid var(--line); border-radius: 6px; overflow: hidden; background: var(--card); align-content: start; }
.m-menu.narrow { max-width: 170px; }
.m-menu > div { display: flex; justify-content: space-between; gap: 8px; padding: 6px 10px; border-bottom: 1px solid var(--line); font-size: .72rem; }
.m-menu > div:last-child { border-bottom: 0; }
.m-menu .sel { background: var(--ink); color: var(--paper); font-weight: 600; }
.m-menu .off { text-decoration: line-through; color: var(--muted); }
.m-menu em { font-style: normal; opacity: .75; }
.m-line { display: flex; justify-content: space-between; gap: 10px; padding: 7px 0; border-top: 1px solid var(--line); font-size: .74rem; }
.m-line em { font-style: normal; color: var(--muted); font-size: .7rem; white-space: nowrap; }
.m-line.dim span { color: var(--muted); }
.m-line.bad span { text-decoration: line-through; }
.m-line.good { font-weight: 700; padding: 7px 8px; border: 1px solid var(--ink); border-radius: 5px; }
.m-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 7px; }
.m-tile { display: grid; gap: 1px; align-content: start; padding: 8px; border: 1px solid var(--line); border-radius: 6px; background: var(--card); min-width: 0; }
.m-tile b { font-size: .7rem; } .m-tile span { font-size: .66rem; color: var(--muted); }
.m-tile em { font: 500 .62rem var(--mono); font-style: normal; text-decoration: underline; margin-top: 4px; }
.m-app { display: flex; align-items: center; gap: 9px; }
.m-app > div { display: grid; min-width: 0; }
.m-app b { font-size: .7rem; line-height: 1.4; } .m-app small { font-size: .6rem; color: var(--muted); }
.m-ico { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 8px; background: var(--ink); color: var(--paper); flex: none; }
.m-ico svg { width: 18px; height: 18px; }
.m-qr { width: 104px; height: 104px; fill: var(--ink); stroke: none; background: var(--card); border-radius: 4px; }
.m-cam { position: relative; aspect-ratio: 1; border-radius: 8px; background: var(--soft); }
.m-cam i { position: absolute; width: 16px; height: 16px; border: 2px solid var(--ink); }
.m-cam i:nth-child(1) { top: 10px; left: 10px; border-right: 0; border-bottom: 0; } .m-cam i:nth-child(2) { top: 10px; right: 10px; border-left: 0; border-bottom: 0; }
.m-cam i:nth-child(3) { bottom: 10px; left: 10px; border-right: 0; border-top: 0; } .m-cam i:nth-child(4) { bottom: 10px; right: 10px; border-left: 0; border-top: 0; }
.m-num { font: 600 2.1rem var(--mono); letter-spacing: .14em; text-align: center; line-height: 1.3; }
.m-toggle { position: relative; width: 34px; height: 19px; border-radius: 19px; border: 1.5px solid var(--ink); flex: none; }
.m-toggle::after { content: ""; position: absolute; top: 2px; right: 2px; width: 12px; height: 12px; border-radius: 50%; background: var(--ink); }
.m-toggle.on { background: var(--ink); } .m-toggle.on::after { right: auto; left: 2px; background: var(--paper); }
.m-hl { position: relative; outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 5px; }
.m-hl::after { content: ""; position: absolute; inset: -5px; border: 2px solid var(--ink); border-radius: 8px; opacity: 0; animation: hl 2.4s ease-out infinite; pointer-events: none; }
.m-toggle.m-hl::after { inset: -6px; top: -6px; right: -6px; width: auto; height: auto; background: none; border-radius: 19px; }
@keyframes hl { 0% { opacity: .7; transform: scale(1); } 70%, 100% { opacity: 0; transform: scale(1.14); } }
.m-pin { display: inline-grid; place-items: center; width: 20px; height: 20px; margin-inline-start: 6px; border-radius: 50%; background: var(--ink); color: var(--paper); font: 600 .68rem var(--mono); font-style: normal; vertical-align: middle; flex: none; }
.m-mail { border: 1px solid var(--ink); border-radius: 10px; background: var(--paper); overflow: hidden; font-size: .86rem; }
.mm-head { display: grid; gap: 4px; padding: 12px 14px; border-bottom: 1px solid var(--line); background: var(--card); }
.mm-row { display: grid; grid-template-columns: 50px minmax(0, 1fr); gap: 8px; align-items: baseline; }
.mm-k { font-size: .72rem; color: var(--muted); }
.mm-v { min-width: 0; overflow-wrap: anywhere; }
.mm-addr { display: block; font: 400 .7rem var(--mono); color: var(--muted); unicode-bidi: isolate; }
.mm-body { display: grid; gap: 10px; padding: 14px; }
.mm-link { display: inline-block; padding: 4px 14px; border-radius: 5px; background: var(--ink); color: var(--paper); font-weight: 600; }
.mm-tip { display: grid; gap: 1px; justify-self: start; max-width: 100%; padding: 6px 10px; border: 1px dashed var(--ink); border-radius: 5px; font-size: .7rem; }
.mm-tip span { color: var(--muted); } .mm-tip b { font: 500 .74rem var(--mono); overflow-wrap: anywhere; }
.mm-att { display: flex; align-items: center; gap: 8px; justify-self: start; padding: 5px 10px; border: 1px solid var(--line); border-radius: 5px; font: 400 .74rem var(--mono); }
.mm-att svg { width: 15px; height: 15px; }
.m-compare { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; }
.m-cmp { display: grid; gap: 7px; align-content: start; padding: 14px; border: 1px dashed var(--line); border-radius: 10px; }
.m-cmp.good { border: 1.5px solid var(--ink); }
.m-cmp-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-weight: 700; font-size: .9rem; }
.m-cmp code { justify-self: start; max-width: 100%; padding: 2px 9px; border: 1px solid var(--line); border-radius: 5px; background: var(--card); font: 500 .78rem var(--mono); overflow-wrap: anywhere; }
.m-cmp:not(.good) code { text-decoration: line-through; color: var(--muted); }
.m-cmp p { font-size: .74rem; color: var(--muted); }
.m-meter { flex: 1; max-width: 110px; height: 6px; border-radius: 6px; background: var(--line); overflow: hidden; direction: ltr; }
.m-meter i { display: block; height: 100%; background: var(--ink); }
.m-keys { display: grid; gap: 16px; justify-items: center; }
.m-keyrow { display: flex; align-items: center; gap: 12px; font: 500 1.2rem var(--mono); }
.m-keyrow kbd { min-width: 62px; padding: 10px 14px; font-size: 1.05rem; border-radius: 9px; }
.m-locked { display: flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 100px; background: var(--ink); color: var(--paper); font-size: .78rem; font-weight: 600; }
.m-locked svg { width: 15px; height: 15px; }
.m-flow { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; align-items: start; position: relative; }
.m-flow > div { display: grid; gap: 8px; justify-items: center; text-align: center; font-size: .82rem; font-weight: 600; position: relative; z-index: 1; }
.m-flow b { display: grid; place-items: center; width: 46px; height: 46px; border: 1.5px solid var(--ink); border-radius: 9px; background: var(--paper); font: 500 .8rem var(--mono); }
.m-flow > div:first-child b { background: var(--ink); color: var(--paper); }
.m-flow > i { display: none; }
.m-flow::before { content: ""; position: absolute; top: 23px; inset-inline: 12.5%; height: 1.5px; background: repeating-linear-gradient(90deg, var(--ink) 0 5px, transparent 5px 10px); }

/* ---------- settings table + extra illustration parts ---------- */
.kv > div { grid-template-columns: minmax(120px, 230px) minmax(0, 1fr) auto; }
.kv dd { font-weight: 500; }
.m-gear { display: inline-grid; place-items: center; width: 26px; height: 26px; border: 1px solid var(--line); border-radius: 5px; }
.m-gear svg { width: 15px; height: 15px; }
.m-check { display: inline-grid; place-items: center; width: 14px; height: 14px; border-radius: 3px; background: var(--ink); flex: none; }
.m-check::after { content: ""; width: 6px; height: 6px; border-radius: 1px; background: var(--paper); }
.m-cols.wide-first { grid-template-columns: minmax(0, 1fr) 62px; }
.m-cols > .m-field { display: block; }
.m-num.sm { font-size: 1.15rem; letter-spacing: .06em; }
.m-meter.wide { max-width: none; width: 100%; flex: none; }
@media (max-width: 620px) { .kv > div { grid-template-columns: minmax(0, 1fr) auto; } }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .hero-grid, .support-grid { grid-template-columns: minmax(0, 1fr); }
  .sec-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tip-card { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 620px) {
  .sec-grid { grid-template-columns: minmax(0, 1fr); }
  .start-list a { grid-template-columns: 34px minmax(0, 1fr) 20px; padding: 16px; }
  .start-list .time { display: none; }
  .rows a { grid-template-columns: minmax(0, 1fr) 20px; padding: 16px; } .rows .time { display: none; }
  .step { grid-template-columns: minmax(0, 1fr); padding: 16px; }
  .step-num { width: 38px; height: 38px; margin-bottom: 12px; }
  .step-text { padding-inline-end: 0; }
  .step-check { top: 16px; inset-inline-end: 16px; }
  .contacts > div { grid-template-columns: minmax(0, 1fr) auto; } .contacts dt { grid-column: 1 / -1; margin-bottom: -8px; }
  .pager { grid-template-columns: minmax(0, 1fr); } .pager .next { grid-column: auto; text-align: start; }
  .search kbd { display: none; }
  .m-flow { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 0; } .m-flow::before { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .demo li em::after { transform: scale(1); }
}
@media print {
  .top, .g-side, .pager, .step-check, .progress, .missing-note, .foot, .search-ov { display: none !important; }
  .band, .surface, .inv { background: #fff !important; color: #000 !important; --ink: #000; --paper: #fff; --muted: #333; --line: #999; --card: #fff; }
  .g-grid { display: block; } .step, .note, .list, details { break-inside: avoid; }
  details > div { display: block; }
}
