/* Официальный сайт «Робосомы». Один лёгкий файл без внешних библиотек и шрифтов. */
:root {
  --bg: #070b12;
  --bg-deep: #04070c;
  --bg-soft: #0d1521;
  --panel: rgba(14, 23, 36, .94);
  --panel-solid: #101a29;
  --line: #28425f;
  --line-soft: rgba(90, 210, 255, .16);
  --cyan: #65d7ff;
  --cyan-bright: #a8ebff;
  --cyan-dim: #348db5;
  --mars: #e2763d;
  --mars-soft: #f2aa78;
  --green: #83f2a5;
  --yellow: #ffd88a;
  --error: #ff9d8d;
  --text: #e5eef8;
  --text-soft: #c6d4e4;
  --muted: #9fb1c6;
  --radius: 16px;
  --radius-small: 11px;
  --shadow: 0 18px 50px rgba(0, 0, 0, .28);
  --wrap: 1180px;
  --read: 76ch;
  --header-h: 66px;
}

* { box-sizing: border-box; min-width: 0; }
html { overflow-x: clip; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 20px); }
body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.67 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  -webkit-text-size-adjust: 100%;
}
body.menu-open { overflow: hidden; }
img, svg, video, canvas, iframe { max-width: 100%; }
img { height: auto; }
p, li, td, th, dd, dt, figcaption, h1, h2, h3, h4, summary, code { overflow-wrap: break-word; }
button, input, textarea, select { font: inherit; }
a { text-underline-offset: .18em; }
main a:not(.btn):not(.card):not(.brand), footer a { color: var(--cyan); text-decoration-color: var(--cyan-dim); }
main a:not(.btn):not(.card):hover, footer a:hover { color: var(--cyan-bright); }

:focus-visible { outline: 3px solid var(--cyan); outline-offset: 3px; border-radius: 6px; }
.skip {
  position: fixed; left: 14px; top: 10px; z-index: 100; padding: 10px 14px;
  transform: translateY(-160%); border-radius: 9px; background: var(--cyan);
  color: #06121b; font-weight: 700; text-decoration: none;
}
.skip:focus { transform: translateY(0); }
.wrap { width: min(var(--wrap), calc(100% - 36px)); margin-inline: auto; }
.read { max-width: var(--read); }
.read-surface {
  padding: clamp(20px, 4vw, 38px); border: 1px solid var(--line-soft);
  border-radius: var(--radius); background: linear-gradient(145deg, rgba(13, 21, 33, .97), rgba(8, 14, 23, .96));
  box-shadow: var(--shadow);
}
.muted { color: var(--muted); }
.eyebrow, .tag {
  display: inline-flex; align-items: center; gap: 8px; margin-bottom: 15px; padding: 5px 11px;
  border: 1px solid var(--cyan-dim); border-radius: 999px; color: var(--cyan);
  font-size: 12px; font-weight: 650; letter-spacing: .12em; line-height: 1.4; text-transform: uppercase;
}
.tag svg, .eyebrow svg { width: 15px; height: 15px; flex: none; }
.kicker { color: var(--mars-soft); font-weight: 700; }
.lead { max-width: 70ch; color: var(--text-soft); font-size: clamp(17px, 2.1vw, 20px); }
.trust { margin-top: 10px; color: var(--muted); font-size: 14px; }
.small { font-size: 14px; }

#space {
  position: fixed; inset: 0; z-index: -3; max-width: 100vw; overflow: hidden; pointer-events: none;
  background: radial-gradient(ellipse 55% 38% at 12% 10%, rgba(90, 210, 255, .09), transparent 72%),
    radial-gradient(ellipse 52% 44% at 88% 82%, rgba(224, 116, 60, .10), transparent 74%), var(--bg);
}
#space canvas { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .72; will-change: transform; }
#horizon {
  position: fixed; right: 0; bottom: 0; left: 0; z-index: -2; height: 34vh; pointer-events: none;
  background: linear-gradient(to top, rgba(224, 116, 60, .13), rgba(224, 116, 60, .025) 52%, transparent);
}

header {
  position: sticky; top: 0; z-index: 40; border-bottom: 1px solid var(--line-soft);
  background: rgba(5, 9, 15, .9); backdrop-filter: blur(14px);
}
.nav { display: flex; min-height: var(--header-h); align-items: center; gap: 14px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; flex: none; }
.brand img, .brand svg { width: 36px; height: 36px; border-radius: 50%; flex: none; }
.brand-text b { display: block; font-size: 17px; line-height: 1.1; letter-spacing: .13em; }
.brand-text span { display: block; margin-top: 3px; color: var(--muted); font-size: 10px; letter-spacing: .18em; }
.language-switch {
  display: inline-flex; flex: none; align-items: center; gap: 2px; margin-left: auto; padding: 3px;
  border: 1px solid var(--line); border-radius: 10px; background: rgba(13, 21, 33, .78);
}
.language-switch a, .language-switch span {
  display: grid; min-width: 44px; min-height: 44px; place-items: center; padding: 4px 7px; border-radius: 7px;
  color: var(--muted); font-size: 12px; font-weight: 750; line-height: 1; text-decoration: none;
}
.language-switch a:hover { color: var(--cyan-bright); background: rgba(90,210,255,.08); }
.language-switch [aria-current="page"] { background: rgba(90,210,255,.14); color: var(--cyan-bright); }
.language-switch + .burger { margin-left: 0; }
.menu { display: flex; align-items: center; gap: 3px; margin-left: 0; }
.menu a {
  display: inline-flex; min-height: 42px; align-items: center; padding: 8px 10px; border-radius: 9px;
  color: var(--muted); font-size: 14px; text-decoration: none; white-space: nowrap;
}
.menu a:hover, .menu a.on, .menu a[aria-current="page"] { color: var(--cyan); background: rgba(90, 210, 255, .09); }
.menu .menu-cta { margin-left: 4px; border: 1px solid var(--cyan-dim); color: var(--cyan-bright); }
.burger {
  display: none; width: 46px; height: 46px; margin-left: auto; padding: 10px; border: 1px solid var(--line);
  border-radius: 10px; background: rgba(13, 21, 33, .8); color: var(--cyan); cursor: pointer;
}
.burger svg { display: block; width: 24px; height: 24px; }

main { min-height: 62vh; }
section { padding: clamp(48px, 7vw, 82px) 0 2px; }
.section-tight { padding-top: 34px; }
h1, h2, h3, h4 { margin: 0 0 14px; color: var(--text); line-height: 1.16; }
h1 { max-width: 22ch; font-size: clamp(34px, 6.2vw, 64px); letter-spacing: -.025em; }
h2 { max-width: 28ch; font-size: clamp(25px, 4vw, 39px); letter-spacing: -.015em; }
h3 { font-size: clamp(18px, 2.1vw, 21px); }
h4 { font-size: 17px; }
p { margin: 0 0 15px; color: var(--text-soft); }
ul, ol { margin: 10px 0 18px; padding-left: 1.35em; }
li { margin: 7px 0; color: var(--text-soft); }

.hero { padding-top: clamp(30px, 5vw, 62px); }
.hero-grid { display: grid; grid-template-columns: minmax(0, .92fr) minmax(420px, 1.08fr); align-items: center; gap: clamp(28px, 5vw, 64px); }
.hero h1 em { color: var(--mars-soft); font-style: normal; }
.hero-media {
  position: relative; overflow: hidden; border: 1px solid var(--line); border-radius: 22px;
  background: var(--bg-soft); box-shadow: 0 24px 80px rgba(0, 0, 0, .45), 0 0 50px rgba(90, 210, 255, .07);
}
.hero-media::after { content: ""; position: absolute; inset: 0; border: 1px solid rgba(255,255,255,.06); border-radius: inherit; pointer-events: none; }
.hero-media img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.hero-caption {
  position: absolute; right: 12px; bottom: 12px; left: 12px; margin: 0; padding: 8px 11px;
  border: 1px solid rgba(90,210,255,.22); border-radius: 9px; background: rgba(5, 9, 15, .82);
  color: var(--text-soft); font-size: 13px; backdrop-filter: blur(8px);
}
.hero-art { position: relative; }
.hero-art svg { display: block; width: 100%; }

.btns { display: flex; flex-wrap: wrap; align-items: center; gap: 11px; margin-top: 22px; }
.btns.compact { margin-top: 4px; }
.btn {
  display: inline-flex; min-height: 48px; align-items: center; justify-content: center; gap: 9px;
  padding: 12px 20px; border: 1px solid transparent; border-radius: 11px; color: var(--text);
  font-weight: 700; line-height: 1.25; text-align: center; text-decoration: none; cursor: pointer;
}
.btn svg { width: 20px; height: 20px; flex: none; }
.btn-main { background: linear-gradient(135deg, #5ad2ff, #2a9acb); color: #04121a; box-shadow: 0 10px 28px rgba(42,154,203,.2); }
.btn-main:hover { filter: brightness(1.1); transform: translateY(-1px); }
.btn-ghost { border-color: var(--line); background: rgba(13, 21, 33, .74); color: var(--text); }
.btn-ghost:hover { border-color: var(--cyan-dim); color: var(--cyan-bright); }
.btn-mars { border-color: rgba(224,116,60,.6); background: rgba(224,116,60,.13); color: var(--mars-soft); }
.btn:disabled { opacity: .55; cursor: wait; }

.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 11px; margin: 24px 0 0; }
.fact { padding: 14px; border: 1px solid var(--line-soft); border-radius: 12px; background: rgba(13, 21, 33, .76); }
.fact b { display: block; color: var(--cyan); font-size: clamp(19px, 3vw, 25px); line-height: 1.15; }
.fact span { display: block; margin-top: 5px; color: var(--muted); font-size: 13px; line-height: 1.4; }

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(255px, 100%), 1fr)); gap: 16px; }
.card {
  padding: 21px; border: 1px solid var(--line-soft); border-radius: var(--radius);
  background: linear-gradient(145deg, rgba(16,26,41,.94), rgba(10,17,28,.9));
  box-shadow: 0 12px 36px rgba(0,0,0,.16);
}
a.card { display: block; color: inherit; text-decoration: none; transition: border-color .18s, transform .18s; }
a.card:hover { border-color: var(--cyan-dim); transform: translateY(-2px); }
.card h3 { display: flex; align-items: flex-start; gap: 10px; }
.card h3 svg { width: 25px; height: 25px; flex: none; }
.card p:last-child, .card ul:last-child { margin-bottom: 0; }
.card p { font-size: 15px; }
.card-status { border-left: 3px solid var(--green); }
.card-planned { border-left: 3px solid var(--mars); }
.state { display: inline-flex; margin-bottom: 9px; padding: 3px 8px; border-radius: 999px; background: rgba(127,240,160,.1); color: var(--green); font-size: 12px; font-weight: 700; }
.state.planned { background: rgba(224,116,60,.12); color: var(--mars-soft); }
.steps { counter-reset: step; }
.steps .card { position: relative; padding-top: 54px; }
.steps .card::before {
  counter-increment: step; content: counter(step); position: absolute; top: 17px; left: 20px;
  width: 26px; height: 26px; display: grid; place-items: center; border: 1px solid var(--cyan-dim);
  border-radius: 50%; color: var(--cyan); font-size: 13px; font-weight: 800;
}

.shots { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 15px; }
figure { margin: 0; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-soft); }
figure img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
figcaption { padding: 10px 14px; color: var(--muted); font-size: 13px; }
.figure { margin: 20px 0; }
.figure img { width: 100%; }
.feature-figure { margin: 20px 0 28px; }

.callout, .note, .warn {
  margin: 18px 0; padding: 16px 18px; border: 1px solid var(--line); border-left: 3px solid var(--cyan);
  border-radius: var(--radius-small); background: rgba(13,21,33,.92); color: var(--text-soft);
}
.warn { border-left-color: var(--mars); }
.callout strong, .note strong { color: var(--cyan-bright); }
.quote { margin: 22px 0; padding: 18px 21px; border-left: 3px solid var(--mars); background: rgba(224,116,60,.08); color: var(--text-soft); font-size: 17px; }
.quote-final { font-size: 19px; }
.lore { padding-left: 19px; border-left: 2px solid var(--mars); }
.lore h3 { color: var(--mars-soft); }
.timeline { margin: 0; padding: 0; list-style: none; }
.timeline li { position: relative; margin: 0; padding: 0 0 20px 24px; border-left: 1px solid var(--line); }
.timeline li::before { content: ""; position: absolute; top: 8px; left: -5px; width: 9px; height: 9px; border-radius: 50%; background: var(--mars); }
.timeline b { color: var(--cyan-bright); }
.era { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(250px,100%),1fr)); gap: 15px; }

.compare { width: 100%; margin: 18px 0; border-collapse: separate; border-spacing: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 12px; }
.compare th, .compare td { padding: 12px 13px; border-bottom: 1px solid var(--line-soft); text-align: left; vertical-align: top; }
.compare th { background: rgba(90,210,255,.08); color: var(--cyan-bright); }
.compare tr:last-child td { border-bottom: 0; }
.badge-real, .badge-model, .badge-lore { display: inline-flex; padding: 2px 7px; border-radius: 999px; font-size: 12px; font-weight: 750; white-space: nowrap; }
.badge-real { background: rgba(127,240,160,.12); color: var(--green); }
.badge-model { background: rgba(90,210,255,.12); color: var(--cyan); }
.badge-lore { background: rgba(224,116,60,.14); color: var(--mars-soft); }

.diagram { display: grid; grid-template-columns: repeat(4, 1fr); align-items: stretch; gap: 22px; margin: 22px 0; }
.diagram-step { position: relative; display: grid; place-items: center; min-height: 112px; padding: 15px; border: 1px solid var(--line); border-radius: 13px; background: var(--panel); text-align: center; }
.diagram-step:not(:last-child)::after { content: "→"; position: absolute; right: -19px; top: 50%; color: var(--mars-soft); font-size: 22px; transform: translateY(-50%); }
.diagram-step b { display: block; color: var(--cyan-bright); }
.diagram-step span { display: block; color: var(--muted); font-size: 13px; }
.diagram-step b, .diagram-step span { overflow-wrap: anywhere; }

.toc { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(235px, 100%), 1fr)); gap: 8px; margin: 15px 0 0; }
.toc a { display: flex; min-height: 44px; align-items: center; padding: 10px 12px; border: 1px solid var(--line-soft); border-radius: 9px; background: rgba(13,21,33,.78); color: var(--text-soft); text-decoration: none; }
.toc a:hover { border-color: var(--cyan-dim); color: var(--cyan-bright); }
.toc a[hidden] { display: none; }
.filter-label { display: block; margin-top: 22px; color: var(--text); font-weight: 700; }
.toc-filter { width: min(100%, 640px); min-height: 48px; margin-top: 8px; padding: 11px 13px; border: 1px solid var(--line); border-radius: 9px; background: rgba(5,9,15,.9); color: var(--text); font: inherit; }
.toc-filter::placeholder { color: var(--muted); }
.toc-filter:focus { border-color: var(--cyan); outline: 2px solid rgba(90,210,255,.24); outline-offset: 2px; }
.guide-page section[id] { scroll-margin-top: calc(var(--header-h) + 16px); }
.guide-page section[id] > .wrap { max-width: min(var(--wrap), 100% - 36px); padding: clamp(18px, 3vw, 34px); border: 1px solid var(--line-soft); border-radius: 15px; background: rgba(9,15,24,.9); box-shadow: var(--shadow); }
#toc-filter { max-width: 430px; margin: 18px 0 2px; }
kbd { display: inline-block; padding: 1px 7px; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 6px; background: rgba(255,255,255,.04); color: var(--text); font-family: inherit; font-size: .92em; }
.keys { width: 100%; margin: 14px 0; border-collapse: collapse; font-size: 15px; }
.keys td, .keys th { padding: 8px 10px; border-bottom: 1px solid var(--line-soft); vertical-align: top; }
.keys td:first-child, .keys th:first-child { color: var(--text); }

.release, .changelog { margin: 20px 0; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: rgba(13,21,33,.9); }
.release-line { display: grid; grid-template-columns: minmax(125px, .35fr) 1fr; gap: 16px; padding: 11px 16px; border-bottom: 1px solid var(--line-soft); }
.release-line:last-child { border-bottom: 0; }
.release-line b { color: var(--cyan-bright); }
.ver { padding: 20px; border-bottom: 1px solid var(--line-soft); }
.ver:last-child { border-bottom: 0; }
.ver time { display: block; margin-top: 5px; font-size: 13px; font-weight: 400; }
.hash { display: grid; grid-template-columns: minmax(105px, auto) 1fr auto; align-items: center; gap: 10px; margin-top: 10px; }
.hash code { padding: 7px 9px; border-radius: 7px; background: #050a11; color: var(--muted); font-size: 12px; word-break: break-all; }
.copy-btn { min-height: 40px; padding: 7px 11px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg-soft); color: var(--cyan); cursor: pointer; }
.dl-count { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: 14px; }
.dl-count[hidden] { display: none; }
.dl-count svg { width: 15px; height: 15px; }
.dl-count b { color: var(--text); font-variant-numeric: tabular-nums; }
.store-counts { display: flex; flex-wrap: wrap; gap: 13px; min-height: 20px; margin-top: 9px; }
.download-note { margin-top: 20px; }

form { display: grid; max-width: 720px; gap: 12px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
label { display: grid; gap: 6px; color: var(--text-soft); font-size: 14px; }
input, textarea, select { width: 100%; min-height: 48px; padding: 12px 13px; border: 1px solid var(--line); border-radius: 10px; background: rgba(6,11,18,.94); color: var(--text); }
input:focus, textarea:focus, select:focus { border-color: var(--cyan); outline: 2px solid rgba(90,210,255,.2); outline-offset: 1px; }
textarea { min-height: 132px; resize: vertical; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.form-msg { min-height: 24px; color: var(--muted); font-size: 14px; }
.form-msg.ok { color: var(--green); }
.form-msg.err { color: var(--error); }

details { margin: 10px 0; overflow: hidden; border: 1px solid var(--line-soft); border-radius: 11px; background: rgba(13,21,33,.8); }
summary { min-height: 48px; padding: 13px 45px 13px 15px; color: var(--text); font-weight: 700; cursor: pointer; position: relative; }
summary::after { content: "+"; position: absolute; right: 16px; top: 10px; color: var(--cyan); font-size: 23px; }
details[open] summary::after { content: "−"; }
details > :not(summary) { margin-right: 15px; margin-left: 15px; }
details > :last-child { margin-bottom: 15px; }

.page-next { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin-top: 34px; padding-top: 24px; border-top: 1px solid var(--line-soft); }
.page-next a { display: block; padding: 15px; border: 1px solid var(--line-soft); border-radius: 11px; background: rgba(13,21,33,.72); color: var(--text); text-decoration: none; }
.page-next a:hover { border-color: var(--cyan-dim); }
.page-next small { display: block; color: var(--muted); }
.social-links { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(210px,100%),1fr)); gap: 12px; }

.press-hero { align-items: center; }
.press-mark {
  display: grid; max-width: 470px; margin-inline: auto; place-items: center; padding: clamp(22px, 5vw, 46px);
  border: 1px solid var(--line); border-radius: 24px;
  background: radial-gradient(circle at 50% 44%, rgba(226,118,61,.17), transparent 60%), var(--bg-soft);
  box-shadow: var(--shadow);
}
.press-mark img { display: block; width: min(100%, 360px); aspect-ratio: 1; object-fit: contain; }
.press-assets { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 16px; }
.section-inline { margin-top: 24px; }
.press-asset { display: flex; min-height: 100%; flex-direction: column; }
.press-asset-preview {
  display: grid; min-height: 210px; margin: -5px -5px 18px; place-items: center; padding: 18px;
  border: 1px solid var(--line-soft); border-radius: 12px;
  background: linear-gradient(135deg, rgba(255,255,255,.045), rgba(90,210,255,.035));
}
.press-asset-preview.checker {
  background-color: #162131;
  background-image: linear-gradient(45deg, rgba(255,255,255,.045) 25%, transparent 25%),
    linear-gradient(-45deg, rgba(255,255,255,.045) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, rgba(255,255,255,.045) 75%),
    linear-gradient(-45deg, transparent 75%, rgba(255,255,255,.045) 75%);
  background-position: 0 0, 0 10px, 10px -10px, -10px 0;
  background-size: 20px 20px;
}
.press-asset-preview img { display: block; width: 100%; max-height: 230px; object-fit: contain; }
.press-asset .btns { margin-top: auto; padding-top: 4px; }
.press-copy { margin: 16px 0 0; padding: clamp(18px, 3vw, 28px); border: 1px solid var(--line-soft); border-radius: var(--radius); background: rgba(13,21,33,.82); }
.press-copy p:last-child { margin-bottom: 0; }
.press-links { display: grid; gap: 8px; margin-top: 16px; }
.press-links a { width: fit-content; }

.fade { opacity: 1; transform: none; }
.js .fade { opacity: 0; transform: translateY(16px); transition: opacity .5s ease, transform .5s ease; }
.js .fade.in { opacity: 1; transform: none; }

footer { margin-top: 74px; padding: 30px 0 calc(34px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line-soft); background: rgba(4,8,14,.86); }
.footer-grid { display: grid; grid-template-columns: 1.1fr .9fr .9fr; gap: 24px; }
.footer-title { color: var(--text); font-weight: 800; }
.footer-links { display: grid; gap: 7px; }
.footer-links a { min-height: 34px; display: inline-flex; align-items: center; }
.footer-meta { margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line-soft); color: var(--muted); font-size: 13px; }

#toTop { position: fixed; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); z-index: 35; display: grid; width: 46px; height: 46px; place-items: center; border: 1px solid var(--line); border-radius: 50%; background: rgba(5,9,15,.92); color: var(--cyan); opacity: 0; pointer-events: none; cursor: pointer; transition: opacity .2s; }
#toTop.show { opacity: 1; pointer-events: auto; }
#toTop svg { width: 20px; height: 20px; }

@media (max-width: 980px) {
  /* backdrop-filter создаёт содержащий блок для position:fixed в Chromium. Без этой
     отмены мобильное меню ограничивалось высотой шапки и показывало один пункт. */
  header { background: rgba(5, 9, 15, .98); backdrop-filter: none; }
  .burger { display: block; }
  .menu { position: fixed; top: var(--header-h); right: 0; bottom: 0; left: 0; z-index: 45; display: none; align-content: start; align-items: stretch; overflow-y: auto; padding: 16px max(18px, calc((100vw - var(--wrap)) / 2)); background: #05090f; }
  .menu.open { display: grid; grid-auto-rows: min-content; gap: 5px; }
  .menu a { min-height: 50px; padding: 12px 14px; font-size: 17px; }
  .menu .menu-cta { margin-left: 0; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-media { max-width: 760px; }
  .diagram { grid-template-columns: repeat(2, 1fr); }
  .diagram-step:not(:last-child) { padding-right: 36px; }
  .diagram-step:not(:last-child)::after { right: 6px; }
  .diagram-step:nth-child(2)::after { display: none; }
  .hash { grid-template-columns: 1fr; }
  .hash > span { grid-column: auto; }
  .copy-btn { width: 100%; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 700px) {
  :root { --header-h: 62px; }
  .wrap { width: min(100% - 28px, var(--wrap)); }
  .brand-text b { font-size: 15px; }
  section { padding-top: 48px; }
  h1 { font-size: clamp(33px, 11vw, 48px); }
  .facts { grid-template-columns: 1fr; }
  .fact { display: grid; grid-template-columns: minmax(105px,.45fr) 1fr; align-items: center; gap: 11px; }
  .fact span { margin-top: 0; }
  .form-grid, .page-next, .footer-grid { grid-template-columns: 1fr; }
  .release-line { grid-template-columns: 1fr; gap: 3px; }
  .hash { grid-template-columns: 1fr auto; }
  .hash > span { grid-column: 1 / -1; }
  .compare { display: block; overflow: visible; border: 0; background: transparent; }
  .compare thead { display: none; }
  .compare tbody { display: grid; gap: 10px; }
  .compare tr { display: grid; gap: 5px; padding: 12px; border: 1px solid var(--line-soft); border-radius: 10px; background: rgba(13,21,33,.82); }
  .compare td { display: block; padding: 2px 0; border: 0; }
  .compare .badge-real, .compare .badge-model, .compare .badge-lore { white-space: normal; }
  .keys { display: block; overflow-x: auto; }
  .keys td:first-child { white-space: normal; }
  #settings .keys { overflow: visible; }
  #settings .keys tbody { display: grid; gap: 8px; }
  #settings .keys tr { display: block; padding: 10px 12px; border: 1px solid var(--line-soft); border-radius: 9px; background: rgba(13,21,33,.72); }
  #settings .keys td { display: block; padding: 2px 0; border: 0; overflow-wrap: anywhere; }
  .read-surface { padding: 18px; }
}

@media (max-width: 460px) {
  .nav { gap: 8px; }
  .btns .btn { width: 100%; }
  .hero-caption { position: static; border: 0; border-top: 1px solid var(--line-soft); border-radius: 0; background: var(--panel-solid); }
  .diagram { grid-template-columns: 1fr; gap: 18px; }
  .diagram-step:not(:last-child) { padding-right: 15px; }
  .diagram-step:not(:last-child)::after { display: block; right: 50%; top: auto; bottom: -21px; transform: translateX(50%) rotate(90deg); }
  .fact { grid-template-columns: 1fr; }
  .hash { grid-template-columns: 1fr; }
  .copy-btn { width: 100%; }
}

@media (max-width: 360px) {
  .brand-text { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { scroll-behavior: auto !important; animation: none !important; transition-duration: .01ms !important; }
  .js .fade { opacity: 1; transform: none; }
}

@media (prefers-contrast: more) {
  :root { --muted: #bed0e3; --line: #4e769c; }
  #space canvas { opacity: .35; }
}
