/* The quinvium.com website: the brand's light look. A warm white page, white cards with a soft shadow and a hairline,
   blue as the main accent, gold only in the mark. Flat colours without gradients or glow. */
@font-face { font-family: "Quinvium Symbol"; src: url("/Quinvium-Symbol.ttf") format("truetype"); font-display: block; }
:root {
  --page: #fafaf7;
  --tint: #f2f5f9;
  --card: #ffffff;
  --ink: #0f172a;
  --ink-2: #3b4a5e;
  --ink-3: #5b6a7d;
  --hair: #e6e9ee;
  --accent: #0b63c4;
  --accent-hover: #0952a3;
  --accent-soft: #e8f1fc;
  --accent-2: #0e8a6b;
  --on-accent: #ffffff;
  --gold: #ffcd02;
  --warn: #8a5300;
  --warn-soft: #fff3dc;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.05), 0 2px 8px rgba(15, 23, 42, 0.04);
  --shadow: 0 2px 4px rgba(15, 23, 42, 0.04), 0 12px 32px rgba(15, 23, 42, 0.08);
  --r: 20px;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--page); color: var(--ink); font: 17px/1.6 var(--sans); }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); text-decoration: underline; text-underline-offset: 3px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3, h4 { margin: 0; line-height: 1.12; letter-spacing: -0.02em; color: var(--ink); }
h2 { font-size: clamp(30px, 3.6vw, 44px); margin: 64px 0 16px; letter-spacing: -0.03em; }
.sec h2:first-child, .sec-head h2 { margin-top: 0; }
h3 { font-size: 19px; margin-bottom: 8px; letter-spacing: -0.01em; }
p { margin: 0 0 16px; }
code { font-family: var(--mono); font-size: 0.86em; background: var(--tint); padding: 2px 6px; border-radius: 6px; overflow-wrap: anywhere; }
pre { background: var(--card); border: 1px solid var(--hair); border-radius: 16px; padding: 20px 22px; overflow-x: auto; margin: 0 0 24px; box-shadow: var(--shadow-sm); }
pre code { background: none; padding: 0; font-size: 14px; line-height: 1.75; color: #1d3557; overflow-wrap: normal; }
sup { font-size: 0.65em; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.skip { position: absolute; inset-inline-start: -999px; top: 8px; background: var(--accent); color: var(--on-accent); padding: 8px 14px; border-radius: 8px; z-index: 50; }
.skip:focus { inset-inline-start: 8px; }
.muted { color: var(--ink-2); }
.small { font-size: 14.5px; }
.narrow { max-width: 46em; }
.placeholder { color: var(--warn); background: var(--warn-soft); padding: 1px 8px; border-radius: 6px; font-style: normal; }
.tag { display: inline-block; font-size: 12.5px; font-weight: 650; color: var(--warn); background: var(--warn-soft); padding: 2px 8px; border-radius: 999px; margin-inline-start: 4px; white-space: nowrap; }
.ic { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; display: inline-block; vertical-align: -6px; }

/* header */
.top { position: sticky; top: 0; z-index: 30; background: var(--card); border-bottom: 1px solid transparent; transition: border-color 0.2s; }
.top.scrolled { border-bottom-color: var(--hair); }
.top-in { display: flex; align-items: center; gap: 32px; height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 750; font-size: 18px; letter-spacing: -0.01em; flex: 0 0 auto; }
.brand:hover { color: var(--ink); text-decoration: none; }
.brand img { border-radius: 8px; }
.nav { flex: 1; display: flex; justify-content: center; }
.nav-in { display: flex; align-items: center; gap: 4px; }
.nav-dl { display: none !important; }
.ng { position: relative; }
.ng-btn { display: inline-flex; align-items: center; gap: 4px; height: 64px; padding: 0 12px; background: none; border: 0; font: 550 15px var(--sans); color: var(--ink-2); cursor: pointer; position: relative; }
.ng-btn:hover, .ng-btn[aria-expanded="true"] { color: var(--ink); text-decoration: none; }
.ng-btn.here { color: var(--ink); }
.ng-btn.here::after { content: ""; position: absolute; inset-inline-start: 12px; inset-inline-end: 12px; bottom: 0; height: 2px; background: var(--accent); border-radius: 2px; }
.ng-btn .chev { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: transform 0.15s; }
.ng-btn[aria-expanded="true"] .chev { transform: rotate(180deg); }
.ng-btn .ext { width: 14px; height: 14px; vertical-align: 0; opacity: 0.7; }
.ng-panel { display: none; position: absolute; top: 58px; inset-inline-start: -12px; min-width: 340px; background: var(--card); border: 1px solid var(--hair); border-radius: 16px; box-shadow: 0 16px 40px rgba(15, 23, 42, 0.12); padding: 8px; }
.ng-btn[aria-expanded="true"] + .ng-panel { display: grid; }
@media (hover: hover) and (min-width: 941px) {
  .ng:hover .ng-panel { display: grid; }
  .ng.shut .ng-panel { display: none; }
  .ng-btn[aria-expanded="true"] + .ng-panel { display: grid; }
}
.ni { display: flex; gap: 14px; align-items: flex-start; padding: 12px; border-radius: 12px; color: var(--ink); }
.ni:hover, .ni:focus-visible { background: var(--tint); text-decoration: none; color: var(--ink); }
.ni .ic { width: 36px; height: 36px; padding: 8px; border-radius: 10px; background: var(--accent-soft); color: var(--accent); flex: 0 0 auto; }
.ni strong { display: block; font-size: 15px; font-weight: 650; }
.ni small { display: block; font-size: 13.5px; color: var(--ink-3); line-height: 1.4; margin-top: 2px; }
.ni[aria-current="page"] strong { color: var(--accent); }
.tools { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.menu { display: none; width: 44px; height: 44px; border: 1px solid var(--hair); border-radius: 12px; background: var(--card); cursor: pointer; padding: 14px 12px; flex-direction: column; justify-content: space-between; }
.menu span { display: block; height: 2px; background: var(--ink); border-radius: 2px; transition: transform 0.2s, opacity 0.2s; }
.menu[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.menu[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
body.locked { overflow: hidden; }

/* buttons: one system for the whole site */
.btn { --h: 44px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: var(--h); padding: 0 18px; border-radius: 12px; border: 1px solid transparent; font: 600 15px/1 var(--sans); cursor: pointer; white-space: nowrap; text-decoration: none !important; transition: background 0.15s, border-color 0.15s, color 0.15s; }
.btn.md { --h: 44px; }
.btn.lg { --h: 52px; padding: 0 24px; font-size: 16px; }
.btn .ic { width: 18px; height: 18px; vertical-align: 0; transition: transform 0.15s; }
.btn:hover .ic { transform: translateX(3px); }
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.btn.primary { background: var(--accent); color: var(--card); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18), 0 1px 2px rgba(15, 23, 42, 0.12); }
.btn.primary:hover { background: var(--accent-hover); color: var(--card); }
.btn.secondary { background: var(--card); color: var(--ink); border-color: #d5dbe3; }
.btn.secondary:hover { border-color: #9aa7b7; color: var(--ink); }
.btn.link { height: auto; padding: 0; border: 0; background: none; color: var(--accent); }
.btn.link:hover { color: var(--accent-hover); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: 0.5; cursor: not-allowed; pointer-events: none; }
.row-btns { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin: 8px 0 0; }
.link { background: none; border: 0; padding: 0; font: inherit; font-weight: 650; color: var(--accent); cursor: pointer; }
.more { font-weight: 650; display: inline-flex; align-items: center; gap: 6px; }
.more .ic { width: 18px; height: 18px; vertical-align: 0; transition: transform 0.15s; }
.more:hover .ic { transform: translateX(3px); }
.msg { min-height: 1.4em; font-size: 14.5px; color: var(--ink-3); margin: 12px 0 0; }

/* home */
.hero { overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: center; padding-top: 80px; padding-bottom: 72px; }
.status-pill { display: inline-flex; align-items: center; gap: 10px; background: var(--card); border: 1px solid var(--hair); border-radius: 999px; padding: 7px 14px 7px 12px; font-size: 14px; font-weight: 600; color: var(--ink-2); box-shadow: var(--shadow-sm); margin-bottom: 28px; }
.hero h1 { font-size: clamp(40px, 6vw, 72px); letter-spacing: -0.045em; line-height: 1.02; margin-bottom: 24px; max-width: 11em; }
.hero .lead { color: var(--ink-2); font-size: clamp(18px, 1.7vw, 21px); max-width: 30em; margin-bottom: 32px; }
.hero-facts { list-style: none; padding: 0; margin: 32px 0 0; display: flex; flex-wrap: wrap; gap: 8px 22px; color: var(--ink-3); font-size: 15px; }
.hero-facts li { display: flex; align-items: center; gap: 8px; }
.hero-facts li::before { content: ""; width: 7px; height: 7px; border-radius: 2px; background: var(--accent); transform: rotate(45deg); }
.hero-art { display: flex; justify-content: center; }
.art { width: min(520px, 100%); height: auto; overflow: visible; }
.art .p1 { fill: #e9f1fb; }
.art .p2 { fill: #d6e6f8; }
.art .p3 { fill: var(--card); stroke: #c8dcf3; stroke-width: 1.5; }
.art .f1 { fill: #cfe3f7; }
.art .f2 { fill: #fbe6bd; }
.art .f3 { fill: #d9efe7; }
.art .f4 { fill: #cfe3f7; }
.art .o { fill: var(--accent); }
.art .o2 { fill: var(--accent-2); }
.art .mark { fill: var(--gold); }
.art .drift, .art .drift2, .art .orbit, .art .float, .art .float2 { transform-box: view-box; transform-origin: 240px 225px; }
.art .float, .art .float2 { transform-box: fill-box; transform-origin: center; }
@media (prefers-reduced-motion: no-preference) {
  .art .drift { animation: spin 120s linear infinite; }
  .art .drift2 { animation: spin 90s linear infinite reverse; }
  .art .orbit { animation: spin 40s linear infinite; }
  .art .float { animation: bob 7s ease-in-out infinite; }
  .art .float2 { animation: bob 9s ease-in-out infinite reverse; }
  .card, .appcard { transition: transform 0.2s, box-shadow 0.2s; }
}
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes bob { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-10px) rotate(8deg); } }

/* live status */
.dot { width: 9px; height: 9px; border-radius: 50%; background: #9aa8b8; flex: 0 0 auto; }
.dot.on { background: #12b76a; box-shadow: 0 0 0 4px #d1fadf; }
.dot.off { background: #e07a5f; }
.statbar-wrap { padding-bottom: 24px; }
.statbar { display: grid; grid-template-columns: repeat(4, 1fr); background: var(--card); border: 1px solid var(--hair); border-radius: var(--r); box-shadow: var(--shadow); }
.statbar > div { padding: 24px 28px; }
.statbar > div + div { border-inline-start: 1px solid var(--hair); }
.statbar span { display: block; font-size: 14px; color: var(--ink-3); font-weight: 550; }
.statbar strong { display: block; font-size: clamp(22px, 2.4vw, 30px); font-weight: 700; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; margin-top: 4px; min-height: 1.3em; }
.sk:empty::before, .sk.loading::before { content: ""; display: inline-block; width: 70%; height: 0.9em; border-radius: 6px; background: var(--tint); }
.live-note { font-size: 14px; color: var(--ink-3); margin: 14px 4px 0; }

/* sekce */
.sec { padding: 96px 0; }
.sec.tint { background: var(--tint); }
.sec-head { max-width: 720px; margin-bottom: 40px; }
.sec-head p { color: var(--ink-2); font-size: 19px; margin: 0; }
.sec-head.row { max-width: none; display: flex; align-items: end; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.split { display: grid; grid-template-columns: 1fr 1.1fr; gap: 64px; align-items: center; }
.panel { background: var(--card); border: 1px solid var(--hair); border-radius: var(--r); padding: 28px; box-shadow: var(--shadow); }
.panel .kv { box-shadow: none; border: 0; padding: 0; margin: 0; }
.page-head { padding: 80px 0 48px; border-bottom: 1px solid var(--hair); background: var(--card); }
.page-head h1 { font-size: clamp(38px, 5vw, 60px); letter-spacing: -0.04em; margin-bottom: 14px; }
.page-head .lead { font-size: clamp(18px, 1.6vw, 21px); color: var(--ink-2); max-width: 38em; margin: 0; }
.page-head + .sec { padding-top: 64px; }
.prose { max-width: 820px; }

/* karty */
.cards { display: grid; gap: 20px; margin-bottom: 28px; }
.c2 { grid-template-columns: repeat(2, 1fr); }
.c3 { grid-template-columns: repeat(3, 1fr); }
.c4 { grid-template-columns: repeat(4, 1fr); }
.card { background: var(--card); border: 1px solid var(--hair); border-radius: var(--r); padding: 28px; box-shadow: var(--shadow-sm); }
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.card .ic { width: 48px; height: 48px; padding: 12px; border-radius: 14px; background: var(--accent-soft); color: var(--accent); margin-bottom: 20px; display: block; }
.card p { color: var(--ink-2); margin: 0; font-size: 16px; }
.cards.big .card { padding: 34px; }

.steps3 { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.steps3 li { background: var(--card); border: 1px solid var(--hair); border-radius: var(--r); padding: 30px; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; align-items: flex-start; }
.steps3 .n { width: 40px; height: 40px; border-radius: 12px; background: var(--ink); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 750; margin-bottom: 20px; }
.steps3 p { color: var(--ink-2); flex: 1; }
.steps3 li { min-width: 0; }
.steps3 pre { max-width: 100%; margin: 12px 0 0; padding: 14px 16px; }
.steps3 pre code { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 13px; }
.steps3 a { font-weight: 650; display: inline-flex; align-items: center; gap: 6px; }
.steps3 a .ic { width: 18px; height: 18px; vertical-align: 0; }

.nums { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin: 28px 0 28px; }
.nums div { background: var(--card); border: 1px solid var(--hair); border-radius: 16px; padding: 18px 20px; }
.nums strong { display: block; font-size: 26px; letter-spacing: -0.02em; }
.nums span { color: var(--ink-3); font-size: 14.5px; }

.blocklist { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.blocklist .empty { grid-column: 1 / -1; background: var(--card); border: 1px dashed var(--hair); border-radius: var(--r); padding: 28px; color: var(--ink-3); text-align: center; margin: 0; }
.blk { display: grid; grid-template-columns: auto 1fr; gap: 2px 16px; align-items: center; background: var(--card); border: 1px solid var(--hair); border-radius: 16px; padding: 18px 20px; color: var(--ink); box-shadow: var(--shadow-sm); }
.blk:hover { text-decoration: none; box-shadow: var(--shadow); color: var(--ink); }
.blk .cube { grid-row: span 2; width: 44px; height: 44px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); display: flex; align-items: center; justify-content: center; }
.blk b { font: 700 16px var(--mono); }
.blk span { color: var(--ink-3); font-size: 14px; }

.appgrid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.appcard { background: var(--card); border: 1px solid var(--hair); border-radius: 18px; padding: 22px; display: grid; gap: 6px; align-content: start; color: var(--ink); box-shadow: var(--shadow-sm); }
.appcard:hover { text-decoration: none; transform: translateY(-3px); box-shadow: var(--shadow); color: var(--ink); }
.appcard .ic { width: 42px; height: 42px; padding: 10px; border-radius: 12px; background: var(--tint); color: var(--accent); margin-bottom: 8px; }
.appcard span { color: var(--ink-3); font-size: 14.5px; line-height: 1.5; }

.cta-box { background: var(--accent-soft); border-radius: 28px; padding: 56px; display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.cta-box h2 { margin: 0 0 8px; }
.cta-box p { color: var(--ink-2); margin: 0; font-size: 19px; }

/* graf */
.chart { margin: 0; }
.chart svg { width: 100%; height: auto; display: block; }
.chart text { font: 12px var(--mono); fill: var(--ink-3); }
.chart .gl { stroke: var(--hair); stroke-width: 1; }
.chart .hv { stroke: var(--accent); stroke-width: 1; stroke-dasharray: 4 5; opacity: 0.5; }
.chart .ln { fill: none; stroke: var(--accent); stroke-width: 3; stroke-linejoin: round; }
.chart .area { fill: var(--accent-soft); }
.chart figcaption { font-size: 14px; color: var(--ink-3); margin-top: 12px; }
.chart-big { margin: 40px 0; }

.stats-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.stats-row div { min-width: 0; overflow-wrap: anywhere; background: var(--card); border: 1px solid var(--hair); border-radius: var(--r); padding: 26px; box-shadow: var(--shadow-sm); }
.stats-row strong { display: block; font-size: clamp(28px, 3vw, 40px); letter-spacing: -0.03em; }
.stats-row span { color: var(--ink-2); }

/* tabulky a hodnoty */
.kv, .table { background: var(--card); border: 1px solid var(--hair); border-radius: var(--r); padding: 6px 26px; margin-bottom: 28px; box-shadow: var(--shadow-sm); }
.kv > div, .table .tr { display: grid; grid-template-columns: 150px 1fr 1fr; gap: 18px; padding: 14px 0; align-items: center; }
.kv.two > div { grid-template-columns: 200px 1fr; }
.kv > div + div, .table .tr + .tr { border-top: 1px solid var(--hair); }
.kv > div > span:first-child, .table .tr > span:first-child { color: var(--ink-2); }
.kv-h, .tr.th { font-size: 13.5px; font-weight: 650; color: var(--ink-3) !important; }
.kv code, .table code { background: none; padding: 0; font-size: 14px; }
.table .tr { grid-template-columns: repeat(5, 1fr); }
.table.mono .tr { grid-template-columns: 260px 1fr; }

.apps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 28px; }
.app { background: var(--card); border: 1px solid var(--hair); border-radius: 18px; padding: 22px 24px; display: grid; gap: 6px; align-content: start; box-shadow: var(--shadow-sm); }
.app span { color: var(--ink-2); font-size: 15.5px; }
.app a { font-size: 14px; justify-self: start; }

.pills { display: flex; flex-wrap: wrap; gap: 10px; margin: 26px 0; }
.pills span { background: var(--card); border: 1px solid var(--hair); border-radius: 999px; padding: 9px 18px; font-weight: 550; }

.ticks { list-style: none; padding: 0; margin: 0 0 28px; display: grid; gap: 12px; }
.ticks li { position: relative; padding-inline-start: 34px; }
.ticks li::before { content: ""; position: absolute; inset-inline-start: 0; top: 4px; width: 20px; height: 20px; border-radius: 50%; background: var(--accent-soft); }
.ticks li::after { content: ""; position: absolute; inset-inline-start: 7px; top: 8px; width: 5px; height: 9px; border: solid var(--accent); border-width: 0 2px 2px 0; transform: rotate(45deg); }
.ticks.no li::before { background: #fdeee8; }
.ticks.no li::after { inset-inline-start: 6px; top: 13px; width: 8px; height: 0; border-width: 0 0 2px 0; border-color: #b4441f; transform: none; }
.numbered { padding-inline-start: 22px; margin: 0 0 28px; display: grid; gap: 10px; }

.timeline { list-style: none; padding: 0; margin: 0; max-width: 860px; }
.timeline li { position: relative; padding: 0 0 36px 48px; display: grid; gap: 6px; }
.timeline li::before { content: ""; position: absolute; inset-inline-start: 9px; top: 6px; bottom: -6px; width: 2px; background: var(--hair); }
.timeline li:last-child::before { display: none; }
.timeline li::after { content: ""; position: absolute; inset-inline-start: 0; top: 2px; width: 20px; height: 20px; border-radius: 50%; background: var(--card); box-shadow: inset 0 0 0 3px var(--accent); }
.timeline li.done::after { background: var(--accent); }
.timeline strong { font-size: 20px; }
.timeline span { color: var(--ink-2); }

.qa { background: var(--card); border: 1px solid var(--hair); border-radius: 16px; margin-bottom: 12px; box-shadow: var(--shadow-sm); }
.qa summary { cursor: pointer; padding: 20px 24px; font-weight: 650; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.qa summary::-webkit-details-marker { display: none; }
.qa summary::after { content: "+"; font: 400 24px/1 var(--sans); color: var(--accent); }
.qa[open] summary::after { content: "−"; }
.qa > div { padding: 0 24px 22px; color: var(--ink-2); }
.narrow-wrap { max-width: 860px; }

/* footer */
.foot { background: var(--card); border-top: 1px solid var(--hair); color: var(--ink-3); padding: 64px 0 28px; }
.foot-grid { display: grid; grid-template-columns: 1.6fr repeat(4, 1fr); gap: 32px; }
.foot-brand p { margin-top: 16px; font-size: 14.5px; max-width: 26em; }
.foot h4 { color: var(--ink); font-size: 14px; margin-bottom: 14px; }
.foot-grid > div { display: flex; flex-direction: column; gap: 10px; }
.foot-grid > div > a { color: var(--ink-2); font-size: 15px; }
.foot-grid > div > a:hover { color: var(--accent); }
.foot-brand { display: block !important; }
.foot-base { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 48px; padding-top: 22px; border-top: 1px solid var(--hair); font-size: 13.5px; }

.notfound { min-height: 100vh; display: flex; align-items: center; text-align: center; }
.notfound h1 { font-size: 96px; letter-spacing: -0.05em; margin: 18px 0 8px; }
.notfound img { border-radius: 14px; }
.notfound .row-btns { justify-content: center; }

/* widths */
@media (max-width: 1100px) {
  .c4, .appgrid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 940px) {
  .hero-grid, .split { grid-template-columns: 1fr; }
  .hero-grid { padding-top: 40px; padding-bottom: 48px; gap: 24px; }
  /* on narrow screens the headline comes first; the illustration follows, small */
  .hero-art { order: 2; }
  .art { width: min(240px, 60%); }
  .statbar { grid-template-columns: 1fr 1fr; }
  .statbar > div:nth-child(3) { border-inline-start: 0; }
  .statbar > div:nth-child(n+3) { border-top: 1px solid var(--hair); }
  .steps3, .blocklist, .c3, .apps { grid-template-columns: 1fr; }
  .stats-row { grid-template-columns: 1fr 1fr; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .foot-brand { grid-column: 1 / -1; }
  .table .tr { grid-template-columns: 1.4fr 1fr 1fr; }
  .table .tr > :nth-child(4), .table .tr > :nth-child(5) { display: none; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .wrap { padding: 0 16px; }
  .sec { padding: 64px 0; }
  .c2, .c4, .appgrid { grid-template-columns: 1fr; }
  .statbar > div { padding: 18px 18px; }
  .panel { padding: 18px; }
  .cta-box { padding: 32px 24px; }
  .kv, .table { padding: 4px 18px; }
  .kv > div, .kv.two > div { grid-template-columns: 1fr; gap: 2px; }
  .kv-h { display: none !important; }
  .kv > div > :nth-child(2):not(:last-child)::before { content: "Mainnet: "; color: var(--ink-3); font-family: var(--sans); }
  .kv:not(.two) > div > :nth-child(3)::before { content: "Testnet: "; color: var(--ink-3); font-family: var(--sans); }
  .table.mono .tr { grid-template-columns: 1fr; gap: 2px; }
  .card { padding: 22px; }
  .hero .row-btns .btn { flex: 1 1 100%; justify-content: center; }
  pre code { white-space: pre-wrap; overflow-wrap: anywhere; }
  .stats-row { gap: 10px; }
  .stats-row div { padding: 18px; }
}
/* grid content may shrink (long addresses and code) */
.split > *, .kv > div > *, .table .tr > *, .hero-grid > * { min-width: 0; }
.kv a, .kv code { overflow-wrap: anywhere; }
.panel .kv > div { grid-template-columns: 96px 1fr 1fr; gap: 12px; }
.panel .kv code, .panel .kv a { font-size: 13px; }
/* download */
.note-box { display: flex; gap: 16px; align-items: flex-start; background: var(--warn-soft); border-radius: 16px; padding: 20px 22px; margin-bottom: 32px; }
.note-box .ic { width: 28px; height: 28px; color: var(--warn); flex: 0 0 auto; }
.note-box p { margin: 4px 0 0; color: var(--ink-2); }
.dlgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(330px, 100%), 1fr)); gap: 20px; margin-bottom: 20px; }
.dl { background: var(--card); border: 1px solid var(--hair); border-radius: var(--r); padding: 26px; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.dl-top { display: flex; gap: 14px; align-items: center; }
.dl-top .ic { width: 44px; height: 44px; padding: 10px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); flex: 0 0 auto; }
.dl-top h3 { margin: 0; }
.dl p { color: var(--ink-2); margin: 0; flex: 1; }
.dl .size { font-weight: 500; opacity: 0.8; }
.sha summary { cursor: pointer; font-size: 14px; color: var(--ink-3); }
.sha code { display: block; margin: 8px 0 4px; font-size: 12px; overflow-wrap: anywhere; }

/* mobile menu: full-height panel */
@media (max-width: 940px) {
  .menu { display: flex; }
  .head-dl { display: none !important; }
  .tools { margin-inline-start: auto; }
  .nav { position: fixed; top: 64px; inset-inline-start: 0; inset-inline-end: 0; bottom: 0; background: var(--card); display: flex; flex-direction: column; justify-content: space-between; padding: 8px 16px 20px; overflow-y: auto; transform: translateX(100%); visibility: hidden; transition: transform 0.25s ease, visibility 0.25s; border-top: 1px solid var(--hair); }
  .nav.open { transform: none; visibility: visible; }
  .nav-in { flex-direction: column; align-items: stretch; gap: 0; }
  .ng { border-bottom: 1px solid var(--hair); }
  .ng-btn { width: 100%; height: 56px; padding: 0 4px; justify-content: space-between; font-size: 18px; color: var(--ink); }
  .ng-btn.here::after { display: none; }
  .ng-panel { position: static; display: none; min-width: 0; border: 0; box-shadow: none; padding: 0 0 10px; }
  .ni { min-height: 48px; padding: 10px 4px; }
  .nav-dl { display: inline-flex !important; width: 100%; margin-top: 20px; }
}
@media (max-width: 640px) {
  .dl .btn { width: 100%; }
}


/* ---- tiles (bento), coloured surfaces by topic ---- */
:root {
  --t-blue: #eaf2fd; --t-blue-2: #d3e4fa; --t-blue-ink: #0b5cb8;
  --t-amber: #fdf3e0; --t-amber-2: #f8e0b0; --t-amber-ink: #7a4a00;
  --t-green: #e5f5ed; --t-green-2: #c6e9d7; --t-green-ink: #0a6448;
  --t-neutral: #f1efea; --t-neutral-2: #e2ddd3; --t-neutral-ink: #3b4a5e;
}
.bento { display: grid; grid-template-columns: repeat(12, 1fr); gap: 16px; }
.span-2 { grid-column: span 2; } .span-3 { grid-column: span 3; } .span-4 { grid-column: span 4; }
.span-6 { grid-column: span 6; } .span-8 { grid-column: span 8; } .rows-2 { grid-row: span 2; }
.tile { position: relative; border-radius: 20px; padding: 28px; display: flex; flex-direction: column; gap: 8px; color: var(--ink); min-width: 0; }
.tile h3 { font-size: 20px; margin: 0; }
.tile p { color: var(--ink-2); margin: 0; }
.tile-ic { width: 52px; height: 52px; border-radius: 16px; display: flex; align-items: center; justify-content: center; margin-bottom: 12px; }
.tile-ic .ic { width: 26px; height: 26px; vertical-align: 0; }
.t-blue { background: var(--t-blue); } .t-blue .tile-ic { background: var(--t-blue-2); color: var(--t-blue-ink); }
.t-amber { background: var(--t-amber); } .t-amber .tile-ic { background: var(--t-amber-2); color: var(--t-amber-ink); }
.t-green { background: var(--t-green); } .t-green .tile-ic { background: var(--t-green-2); color: var(--t-green-ink); }
.t-neutral { background: var(--t-neutral); } .t-neutral .tile-ic { background: var(--t-neutral-2); color: var(--t-neutral-ink); }
.tint .t-neutral { background: var(--card); }
a.tile:hover { text-decoration: none; color: var(--ink); }
.tile.go { padding-inline-end: 64px; }
.go-arrow { position: absolute; top: 24px; inset-inline-end: 24px; width: 36px; height: 36px; border-radius: 50%; background: rgba(255, 255, 255, 0.75); display: flex; align-items: center; justify-content: center; color: var(--ink); }
.go-arrow .ic { width: 18px; height: 18px; vertical-align: 0; transition: transform 0.15s; }
a.tile:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
@media (prefers-reduced-motion: no-preference) {
  a.tile { transition: transform 0.18s ease, box-shadow 0.18s ease; }
  a.tile:hover { transform: translateY(-2px); box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08); }
  a.tile:hover .go-arrow .ic { transform: translateX(2px); }
}
.tile.num { justify-content: flex-end; padding: 22px; }
.tile.num strong { font-size: clamp(26px, 2.6vw, 34px); letter-spacing: -0.03em; line-height: 1; }
.tile.num span { color: var(--t-amber-ink); font-size: 14px; font-weight: 550; }
.tile .chart { margin-top: 8px; }
.tile .chart .area { fill: #fbe4b8; } .tile .chart .ln, .tile .chart .hv { stroke: #b5730d; } .tile .chart .gl { stroke: #f2dfb9; }
.tile .chart text, .tile .chart figcaption { color: #6b4a14; fill: #6b4a14; }
pre.mini { background: rgba(255, 255, 255, 0.8); border: 0; box-shadow: none; margin: 12px 0 4px; padding: 16px 18px; border-radius: 14px; }
pre.mini code { font-size: 13px; }

/* live numbers: one wide tile */
.statbar { background: var(--card); border: 1px solid var(--hair); box-shadow: none; border-radius: 20px; }

/* stepper */
.stepper { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; position: relative; }
.stepper::before { content: ""; position: absolute; top: 22px; inset-inline-start: 22px; inset-inline-end: calc(33.33% - 22px); height: 2px; background: var(--t-blue-2); }
.stepper li { position: relative; display: flex; flex-direction: column; gap: 16px; }
.stepper .n { width: 46px; height: 46px; border-radius: 50%; background: var(--accent); color: var(--card); font-weight: 750; font-size: 18px; display: flex; align-items: center; justify-content: center; box-shadow: 0 0 0 6px var(--tint); position: relative; z-index: 1; }
.stepper h3 { margin-bottom: 6px; }
.stepper p { color: var(--ink-2); margin: 0 0 10px; }

/* network apps: compact list */
.applist { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.appitem { display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; gap: 4px 14px; align-items: center; background: var(--t-neutral); border-radius: 16px; padding: 14px 16px; min-width: 0; }
.ai-ic { grid-row: span 2; width: 40px; height: 40px; border-radius: 12px; background: var(--card); color: var(--t-blue-ink); display: flex; align-items: center; justify-content: center; }
.ai-ic .ic { width: 20px; height: 20px; vertical-align: 0; }
.ai-txt { min-width: 0; }
.ai-txt a { color: var(--ink); }
.ai-txt strong { font-size: 15.5px; }
.ai-txt small { display: block; color: var(--ink-3); font-size: 13.5px; line-height: 1.35; }
.copy { grid-column: 2; justify-self: start; display: inline-flex; align-items: center; gap: 6px; background: var(--card); border: 0; border-radius: 8px; padding: 4px 8px; cursor: pointer; color: var(--ink-2); }
.copy code { background: none; padding: 0; font-size: 12.5px; }
.copy .ic { width: 14px; height: 14px; vertical-align: 0; }
.copy:hover { color: var(--accent); }
.copy.done { color: var(--t-green-ink); }

/* cards on inner pages in the same spirit */
.card { background: var(--t-neutral); border: 0; box-shadow: none; border-radius: 20px; }
.card:hover { transform: none; box-shadow: none; }
.card .ic { background: var(--t-neutral-2); color: var(--t-neutral-ink); border-radius: 16px; }
.c4 .card:nth-child(1) .ic, .c2 .card:nth-child(1) .ic, .c3 .card:nth-child(1) .ic { background: var(--t-blue-2); color: var(--t-blue-ink); }
.dl { background: var(--t-blue); border: 0; box-shadow: none; border-radius: 20px; }
.dl-top .ic { background: var(--t-blue-2); color: var(--t-blue-ink); }
.kv, .table, .qa { box-shadow: none; }
.blk { box-shadow: none; border: 0; }

@media (max-width: 940px) {
  .bento { grid-template-columns: repeat(6, 1fr); }
  .span-8, .span-6 { grid-column: span 6; } .span-3 { grid-column: span 3; } .span-2 { grid-column: span 3; }
  .rows-2 { grid-row: auto; }
  .applist { grid-template-columns: 1fr 1fr; }
  .stepper { grid-template-columns: 1fr; gap: 24px; }
  .stepper::before { top: 22px; bottom: 22px; inset-inline-start: 22px; inset-inline-end: auto; width: 2px; height: auto; }
  .stepper li { flex-direction: row; align-items: flex-start; }
  .stepper .n { flex: 0 0 auto; }
}
@media (max-width: 640px) {
  .bento { grid-template-columns: 1fr; }
  .bento > * { grid-column: auto !important; }
  .applist { grid-template-columns: 1fr; }
  .tile { padding: 22px; }
  .tile.go { padding-inline-end: 60px; }
}

/* ---- all boxes on the site in the tile style (13 Nov 23:35): coloured surfaces without frames or shadows ---- */
.card, .dl, .kv, .table, .qa, .app, .appcard, .stats-row div, .panel, .nums div, .blk, .statbar, .steps3 li, pre, .pills span, .chart-wrap.big, .note-box, .cta-box {
  border: 0 !important; box-shadow: none !important; border-radius: 20px;
}
/* cards and tiles alternate in topic colours */
.cards .card:nth-child(4n+1), .dlgrid .dl:nth-child(4n+1), .apps .app:nth-child(4n+1) { background: var(--t-blue); }
.cards .card:nth-child(4n+2), .dlgrid .dl:nth-child(4n+2), .apps .app:nth-child(4n+2) { background: var(--t-amber); }
.cards .card:nth-child(4n+3), .dlgrid .dl:nth-child(4n+3), .apps .app:nth-child(4n+3) { background: var(--t-green); }
.cards .card:nth-child(4n+4), .dlgrid .dl:nth-child(4n+4), .apps .app:nth-child(4n+4) { background: var(--t-neutral); }
.cards .card:nth-child(4n+1) .ic, .dlgrid .dl:nth-child(4n+1) .dl-top .ic { background: var(--t-blue-2); color: var(--t-blue-ink); }
.cards .card:nth-child(4n+2) .ic, .dlgrid .dl:nth-child(4n+2) .dl-top .ic { background: var(--t-amber-2); color: var(--t-amber-ink); }
.cards .card:nth-child(4n+3) .ic, .dlgrid .dl:nth-child(4n+3) .dl-top .ic { background: var(--t-green-2); color: var(--t-green-ink); }
.cards .card:nth-child(4n+4) .ic, .dlgrid .dl:nth-child(4n+4) .dl-top .ic { background: var(--t-neutral-2); color: var(--t-neutral-ink); }
.card .ic { width: 52px; height: 52px; padding: 13px; border-radius: 16px; margin-bottom: 18px; }
.card { padding: 28px; }
/* tables, questions, code and panels on a neutral surface */
.kv, .table, .qa, pre, .panel { background: var(--t-neutral); }
.tint .kv, .tint .table, .tint .qa, .tint pre, .tint .panel { background: var(--card); }
.panel .kv { background: transparent !important; }
.kv > div + div, .table .tr + .tr { border-top-color: rgba(15, 23, 42, 0.07); }
pre code { color: #23324a; }
/* tokenomics numbers and charts in amber */
.stats-row div { background: var(--t-amber); }
.stats-row span { color: var(--t-amber-ink); }
.chart-big { background: var(--t-amber) !important; }
.chart-big .chart .area { fill: #fbe4b8; } .chart-big .chart .ln, .chart-big .chart .hv { stroke: #b5730d; } .chart-big .chart .gl { stroke: #f2dfb9; }
/* live numbers and blocks in blue */
.statbar { background: var(--t-blue); }
.statbar > div + div { border-inline-start-color: rgba(11, 92, 184, 0.14); }
.statbar span { color: var(--t-blue-ink); }
.blk { background: var(--card); }
.blk .cube { background: var(--t-blue); color: var(--t-blue-ink); }
.blocklist .empty { border: 0; background: var(--card); border-radius: 20px; }
.appitem .ai-ic { color: var(--t-blue-ink); }
.dl .btn.primary { align-self: flex-start; }
@media (max-width: 640px) { .dl .btn.primary { align-self: stretch; } }
.chart-big .chart text { font-size: 8px; } .chart-big .chart svg { max-height: 360px; }

/* whitepaper */
.wp-grid { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 56px; align-items: start; }
.wp-toc { position: sticky; top: 88px; display: flex; flex-direction: column; gap: 2px; font-size: 14.5px; }
.wp-toc-h { font-weight: 700; margin: 0 0 8px; }
.wp-toc a { color: var(--ink-2); padding: 5px 10px; border-radius: 8px; }
.wp-toc a:hover { background: var(--t-neutral); color: var(--ink); text-decoration: none; }
.wp-toc .wp-pdf { margin-top: 14px; align-self: flex-start; color: var(--ink); }
.wp { max-width: 760px; font-size: 17.5px; line-height: 1.7; }
.wp h2 { font-size: 30px; margin: 56px 0 16px; scroll-margin-top: 90px; }
.wp h2:first-of-type { margin-top: 0; }
.wp h3 { font-size: 21px; margin: 32px 0 10px; scroll-margin-top: 90px; }
.wp p, .wp li { color: #26354a; }
.wp ul, .wp ol { padding-inline-start: 22px; margin: 0 0 18px; display: grid; gap: 6px; }
.wp pre { margin: 16px 0 22px; }
.wp-table { overflow-x: auto; margin: 16px 0 24px; background: var(--t-neutral); border-radius: 16px; padding: 4px 18px; }
.wp-table table { border-collapse: collapse; width: 100%; font-size: 15px; }
.wp-table th { text-align: start; font-size: 13.5px; color: var(--ink-3); font-weight: 650; padding: 12px 10px 10px 0; }
.wp-table td { padding: 11px 10px 11px 0; border-top: 1px solid rgba(15, 23, 42, 0.07); vertical-align: top; }
.wp-table code { background: none; padding: 0; }
@media (max-width: 940px) { .wp-grid { grid-template-columns: 1fr; gap: 24px; } .wp-toc { position: static; display: none; } }
@media print {
  .top, .foot, .wp-toc, .skip { display: none !important; }
  body { background: var(--card); font-size: 11pt; }
  .page-head { padding: 0 0 12pt; border: 0; }
  .sec { padding: 0; }
  .wp-grid { display: block; }
  .wp { max-width: none; font-size: 10.5pt; }
  .wp h2 { font-size: 16pt; margin-top: 20pt; break-after: avoid; }
  .wp h3 { font-size: 12.5pt; break-after: avoid; }
  .wp-table, .wp pre { break-inside: avoid; }
  a { color: inherit; }
}
.wp-grid > * { min-width: 0; } .wp p code, .wp li code { overflow-wrap: anywhere; word-break: break-all; }

/* smaller font (13 Nov 23:50, user's request) */
body { font-size: 16px; }
h2 { font-size: clamp(26px, 2.8vw, 34px); }
h3, .tile h3 { font-size: 18px; }
.hero h1 { font-size: clamp(34px, 4.6vw, 56px); letter-spacing: -0.04em; }
.hero .lead { font-size: clamp(16px, 1.4vw, 18px); }
.page-head h1 { font-size: clamp(32px, 4vw, 46px); }
.page-head .lead, .sec-head p, .cta-box p { font-size: 17px; }
.statbar strong { font-size: clamp(20px, 2vw, 26px); }
.tile.num strong { font-size: clamp(22px, 2.2vw, 28px); }
.stats-row strong { font-size: clamp(24px, 2.4vw, 32px); }
.card p, .tile p, .steps3 p, .stepper p, .app span { font-size: 15px; }
.wp { font-size: 16px; }
.wp h2 { font-size: 26px; }
.wp h3 { font-size: 19px; }
.btn.lg { font-size: 15px; }
.nums strong { font-size: 22px; }
.notfound h1 { font-size: 72px; }

/* footer, new design (14 Nov) */
.foot { background: var(--tint); border-top: 0; color: var(--ink-2); padding: 72px 0 28px; margin-top: 0; }
.foot-top { display: grid; grid-template-columns: minmax(280px, 1.1fr) 2fr; gap: 64px; }
.foot-brand .brand { font-size: 20px; }
.foot-brand .brand img { border-radius: 10px; }
.foot-brand p { margin: 16px 0 0; font-size: 15px; max-width: 28em; color: var(--ink-2); }
.foot-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.foot-chips span { background: var(--card); border-radius: 999px; padding: 5px 12px; font-size: 13px; font-weight: 600; color: var(--ink-2); }
.foot-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.foot-actions .ic { width: 18px; height: 18px; }
.foot-cols { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.foot-cols > div { display: flex; flex-direction: column; gap: 10px; }
.foot-cols h4 { font-size: 13px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--ink-3); margin: 0 0 6px; }
.foot-cols a { color: var(--ink); font-size: 15px; }
.foot-cols a:hover { color: var(--accent); }
.foot-status { display: inline-flex; align-items: center; gap: 10px; margin-top: 48px; background: var(--card); border-radius: 999px; padding: 8px 16px; font-size: 14px; color: var(--ink-2); }
.foot-status a { color: var(--ink-2); font-family: var(--mono); font-size: 13px; }
.foot-status .sep { color: var(--ink-3); }
.foot-base { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-top: 24px; padding-top: 22px; border-top: 1px solid rgba(15, 23, 42, 0.08); font-size: 13.5px; color: var(--ink-3); }
.foot-base a { color: var(--ink-2); text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 940px) { .foot-top { grid-template-columns: 1fr; gap: 40px; } .foot-cols { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 420px) { .foot-actions .btn { flex: 1 1 auto; } }

/* The currency: name, ticker and the symbol from Quinvium-Symbol.ttf (U+E000, also on the letter Q). */
.qu-sym { font-family: "Quinvium Symbol"; font-weight: 400; font-style: normal; line-height: 1; }
.coin-id { display: flex; align-items: center; gap: 28px; margin-bottom: 28px; }
.coin-id > .qu-sym { font-size: 96px; flex: 0 0 auto; color: var(--gold); background: #0b1622; border-radius: 28px; padding: 22px 26px; }
.coin-id .kv { margin: 0; }
.coin-id .kv { flex: 1; min-width: 0; }
@media (max-width: 640px) { .coin-id { flex-direction: column; align-items: flex-start; gap: 12px; } .coin-id .kv { width: 100%; } .coin-id > .qu-sym { font-size: 64px; padding: 16px 18px; border-radius: 20px; } }

/* Touch screens of any size: iOS zooms into any field with text under 16 px. */
@media (pointer: coarse) { input, select, textarea { font-size: 16px !important; } }


/* ---- dark mode: the same layout on a deep navy page. theme.js sets data-theme before the first paint ---- */
:root[data-theme="dark"] {
  --page: #000000; --tint: #141414; --card: #0c0c0c; --ink: #f4f4f5; --ink-2: #c4c4c8; --ink-3: #8c8c92; --hair: #262626;
  --accent: #3d8be0; --accent-hover: #63a3ea; --accent-soft: #0f1a27; --accent-2: #2fbf94; --on-accent: #ffffff;
  --warn: #f0b45a; --warn-soft: #221a0b;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.6); --shadow: 0 2px 4px rgba(0, 0, 0, 0.6), 0 12px 32px rgba(0, 0, 0, 0.7);
  --t-blue: #0b131d; --t-blue-2: #122033; --t-blue-ink: #7db8f5;
  --t-amber: #17120a; --t-amber-2: #2a200d; --t-amber-ink: #f0c060;
  --t-green: #08160f; --t-green-2: #0f2a1d; --t-green-ink: #5fd4a8;
  --t-neutral: #111111; --t-neutral-2: #1d1d1d; --t-neutral-ink: #c4c4c8;
  color-scheme: dark;
}
:root[data-theme="dark"] .art .p1 { fill: #0f0f10; }
:root[data-theme="dark"] .art .p2 { fill: #18181a; }
:root[data-theme="dark"] .art .p3 { fill: #050505; stroke: #2c2c2e; }
:root[data-theme="dark"] .art .f1, :root[data-theme="dark"] .art .f4 { fill: #1f1f22; }
:root[data-theme="dark"] .art .f2 { fill: #2a200d; }
:root[data-theme="dark"] .art .f3 { fill: #0f2a1d; }
:root[data-theme="dark"] .top { background: #000000; }

/* ---- header tools: language and theme ---- */
.tool-btn { display: inline-flex; align-items: center; gap: 6px; height: 40px; min-width: 40px; justify-content: center; padding: 0 10px; border: 0; border-radius: 12px; background: transparent; color: var(--ink-2); font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; }
.tool-btn:hover { background: var(--tint); color: var(--ink); }
.tool-btn .ic { width: 18px; height: 18px; vertical-align: 0; }
.theme-btn .moon, :root[data-theme="dark"] .theme-btn .sun { display: none; }
:root[data-theme="dark"] .theme-btn .moon { display: inline; }
.lang-menu { position: relative; }
.lang-panel { position: absolute; z-index: 60; top: calc(100% + 8px); inset-inline-end: 0; display: none; min-width: 180px; padding: 6px; border-radius: 16px; background: var(--card); box-shadow: var(--shadow); }
.lang-menu.open .lang-panel { display: grid; }
.lang-panel a { display: flex; justify-content: space-between; gap: 12px; padding: 9px 12px; border-radius: 10px; color: var(--ink); font-size: 15px; }
.lang-panel a:hover { background: var(--tint); text-decoration: none; }
.lang-panel a[aria-current="true"] { color: var(--accent); font-weight: 600; }
.lang-panel a small { color: var(--ink-3); font-size: 12px; text-transform: uppercase; }
@media (max-width: 480px) { .tool-btn .lang-code { display: none; } }

/* ---- hero: live chip and the chain of latest blocks under the mark ---- */
.live-chip { display: inline-flex; align-items: center; gap: 10px; margin-bottom: 28px; padding: 6px 8px 6px 14px; border-radius: 999px; background: var(--card); box-shadow: var(--shadow-sm); color: var(--ink); font-size: 14px; font-weight: 600; }
.live-chip:hover { text-decoration: none; color: var(--ink); box-shadow: var(--shadow); }
.live-dot { width: 8px; height: 8px; flex: none; border-radius: 50%; background: var(--ink-3); }
.live-dot.on { background: #16a34a; }
.live-label { color: var(--ink); }
.live-block { padding: 3px 10px; border-radius: 999px; background: var(--accent-soft); color: var(--accent); font-variant-numeric: tabular-nums; font-weight: 600; }
.live-block b { font-weight: 700; }
.live-go { display: inline-flex; width: 26px; height: 26px; align-items: center; justify-content: center; border-radius: 50%; background: var(--tint); color: var(--ink-2); }
.live-go .ic { width: 14px; height: 14px; vertical-align: 0; }
.hero-art { flex-direction: column; align-items: center; gap: 4px; }
.chain { width: min(480px, 100%); }
.chain-title { display: block; margin: 0 0 8px 4px; color: var(--ink-3); font-size: 13px; font-weight: 600; }
.chain-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; min-height: 62px; }
.chain-row a { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border-radius: 14px; background: var(--card); box-shadow: var(--shadow-sm); color: var(--ink); font-variant-numeric: tabular-nums; }
.chain-row a:hover { text-decoration: none; box-shadow: var(--shadow); }
.chain-row b { font-size: 15px; }
.chain-row small { color: var(--ink-3); font-size: 12px; }
.chain-row a.new { animation: chain-in 0.6s ease both; }
@keyframes chain-in { from { opacity: 0; transform: translateX(-18px) scale(0.96); } to { opacity: 1; transform: none; } }

/* ---- statistics under the hero: tiles with an icon ---- */
.statbar { gap: 0; }
.statbar > div { position: relative; padding-inline-start: 72px; }
.st-ic { position: absolute; top: 24px; inset-inline-start: 24px; display: flex; width: 36px; height: 36px; align-items: center; justify-content: center; border-radius: 12px; background: var(--accent-soft); color: var(--accent); }
.st-ic .ic { width: 18px; height: 18px; vertical-align: 0; }

/* ---- motion, home page only: the hero rises in, the art drifts with the scroll (site.js), sections and tiles fly up as they enter ---- */
@media (prefers-reduced-motion: no-preference) {
  .js .home-page .hero-copy > * { animation: rise 0.8s cubic-bezier(.2, .7, .2, 1) both; }
  .js .home-page .hero-copy > :nth-child(2) { animation-delay: 0.1s; }
  .js .home-page .hero-copy > :nth-child(3) { animation-delay: 0.2s; }
  .js .home-page .hero-copy > :nth-child(4) { animation-delay: 0.3s; }
  .js .home-page .hero-art { animation: fade 1.1s ease 0.2s both; }
  .home-page .hero-art > div:first-child, .home-page .chain { will-change: transform; }
  .js .home-page .statbar > div { animation: rise 0.7s cubic-bezier(.2, .7, .2, 1) both; }
  .js .home-page .statbar > div:nth-child(2) { animation-delay: 0.08s; }
  .js .home-page .statbar > div:nth-child(3) { animation-delay: 0.16s; }
  .js .home-page .statbar > div:nth-child(4) { animation-delay: 0.24s; }
  .js .home-page .reveal .sec-head { opacity: 0; transform: translateY(40px); transition: opacity 0.8s ease, transform 0.9s cubic-bezier(.2, .7, .2, 1); }
  .js .home-page .reveal.in .sec-head { opacity: 1; transform: none; }
  .js .home-page .reveal :is(.bento > *, .stepper > li, .blocklist > *, .applist > *, details.qa, .cta-box) { opacity: 0; transform: translateY(90px) scale(0.92); transition: opacity 0.9s ease, transform 1.15s cubic-bezier(.16, .84, .3, 1); }
  .js .home-page .reveal.in :is(.bento > *, .stepper > li, .blocklist > *, .applist > *, details.qa, .cta-box) { opacity: 1; transform: none; }
  .js .home-page .reveal.in :is(.bento > *, .stepper > li, .blocklist > *, .applist > *, details.qa):nth-child(1) { transition-delay: 0.12s; }
  .js .home-page .reveal.in :is(.bento > *, .stepper > li, .blocklist > *, .applist > *, details.qa):nth-child(2) { transition-delay: 0.2s; }
  .js .home-page .reveal.in :is(.bento > *, .stepper > li, .blocklist > *, .applist > *, details.qa):nth-child(3) { transition-delay: 0.28s; }
  .js .home-page .reveal.in :is(.bento > *, .stepper > li, .blocklist > *, .applist > *, details.qa):nth-child(4) { transition-delay: 0.36s; }
  .js .home-page .reveal.in :is(.bento > *, .stepper > li, .blocklist > *, .applist > *, details.qa):nth-child(5) { transition-delay: 0.44s; }
  .js .home-page .reveal.in :is(.bento > *, .stepper > li, .blocklist > *, .applist > *, details.qa):nth-child(n+6) { transition-delay: 0.52s; }
}
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
[dir="rtl"] .live-go .ic, [dir="rtl"] .btn .ic { transform: scaleX(-1); }
.hero-art > div:first-child { width: min(520px, 100%); display: flex; justify-content: center; }
@media (max-width: 940px) { .live-chip { margin-top: 20px; } }
/* Right to left: numbers with units ("17.4 s", "33,112 QU") keep their order. */
[dir="rtl"] .statbar strong, [dir="rtl"] .chain-row b, [dir="rtl"] .chain-row small, [dir="rtl"] .live-block, [dir="rtl"] code { direction: ltr; unicode-bidi: isolate; }
[dir="rtl"] .statbar strong { text-align: end; }
@media (max-width: 560px) {
  .statbar > div { padding: 18px 16px; }
  .st-ic { position: static; width: 30px; height: 30px; margin-bottom: 10px; border-radius: 10px; }
  .statbar strong { font-size: 22px; overflow-wrap: anywhere; }
  .chain-row { gap: 6px; }
  .chain-row a { padding: 8px; }
  .chain-row b { font-size: 13px; }
}
:root[data-theme="dark"] pre.mini, :root[data-theme="dark"] .go-arrow { background: rgba(255, 255, 255, 0.07); }
:root[data-theme="dark"] pre.mini code { color: var(--ink-2); }
