:root {
  color-scheme: light dark;
  --bg: #f5f4fc; --surface: #fff; --fg: #1a1830; --muted: #615c7a;
  --accent: #5b47e0; --on-accent: #fff; --tint: #e5e1ff; --border: #d7d3e6;
  --focus: #5b47e0; --control-border: #8a88a6;
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 100%;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #110e1c; --surface: #1e192b; --fg: #ebe7f5; --muted: #bab3cf;
    --accent: #b9abff; --on-accent: #201847; --tint: #302649; --border: #494057;
    --focus: #cabdff; --control-border: #91839f;
  }
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--fg); font-size: 1rem; line-height: 1.7; }
[hidden] { display: none !important; }
/* The whole bilingual guide works if JavaScript is disabled or fails to load. */
html[data-enhanced] [data-lang] { display: none; }
html[data-enhanced][data-active="ru"] [data-lang="ru"], html[data-enhanced][data-active="en"] [data-lang="en"] { display: block; }
a { color: var(--accent); text-underline-offset: .2em; }
a:hover { text-decoration-thickness: 2px; }
button, summary, a { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; }
[tabindex="-1"]:focus { outline: none; }
.skip { position: fixed; top: -120px; left: 16px; z-index: 10; padding: 12px 18px; background: var(--surface); border-radius: 10px; }
.skip:focus { top: 12px; }
.page { max-width: 1160px; margin: auto; padding: 20px clamp(16px, 4vw, 40px) 64px; }
.site-header, .actions, .languages { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; }
.site-header { justify-content: space-between; padding-bottom: 20px; border-bottom: 1px solid var(--border); }
.brand { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; color: var(--fg); font-weight: 750; text-decoration: none; }
.languages { gap: 6px; }
.languages a { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 8px 14px; border: 1px solid var(--control-border); border-radius: 12px; font: inherit; line-height: 1.4; background: var(--surface); color: var(--fg); text-decoration: none; }
.languages a[aria-current="true"] { background: var(--tint); border-color: var(--accent); color: var(--accent); font-weight: 650; }
.hero { padding: clamp(28px, 6vw, 64px) 0 36px; max-width: 800px; }
.eyebrow { color: var(--accent); font-size: .875rem; font-weight: 650; margin: 0 0 16px; }
h1 { font-size: clamp(2rem, 5.4vw, 3.5rem); font-weight: 750; line-height: 1.12; letter-spacing: -.045em; margin: 0 0 24px; }
.lead { max-width: 650px; font-size: 1.125rem; color: var(--muted); margin-bottom: 24px; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 18px; min-height: 48px; max-width: 100%; padding: 12px 20px; border: 1px solid var(--border); border-radius: 14px; font-weight: 650; line-height: 1.45; text-decoration: none; }
.primary { background: var(--accent); color: var(--on-accent); border-color: transparent; }
.secondary { background: var(--surface); color: var(--fg); border-color: var(--control-border); }
.button:hover { filter: brightness(.95); }
.guide-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; }
.contents { align-self: start; border: 1px solid var(--border); border-radius: 16px; background: var(--surface); overflow-wrap: anywhere; }
summary { min-height: 48px; padding: 14px 18px; cursor: pointer; line-height: 1.5; font-weight: 650; }
summary::marker { color: var(--accent); }
summary[id] { scroll-margin-top: 24px; }
.contents ol { list-style: none; margin: 0; padding: 0 10px 10px; }
.contents a { display: block; min-height: 44px; padding: 10px 12px; color: var(--muted); text-decoration: none; border-radius: 10px; line-height: 1.5; }
.contents a[aria-current="location"] { background: var(--tint); color: var(--fg); font-weight: 650; box-shadow: inset 3px 0 var(--accent); }
.contents a:hover, .contents a:focus-visible { background: var(--tint); color: var(--fg); }
article { min-width: 0; overflow-wrap: anywhere; }
article > section { margin-bottom: 38px; }
h2 { font-size: clamp(1.4rem, 2.5vw, 1.8rem); line-height: 1.3; letter-spacing: -.02em; margin: 0 0 16px; scroll-margin-top: 24px; }
h3 { font-size: 1.05rem; line-height: 1.45; margin: 0 0 8px; }
p { margin: 0 0 16px; }
p:last-child { margin-bottom: 0; }
.note, .card { padding: 20px; border: 1px solid var(--border); border-radius: 16px; background: var(--surface); }
.note { margin: 24px 0; border-inline-start: 4px solid var(--accent); }
.note h3 { color: var(--accent); }
.choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: 16px; margin: 24px 0; }
.steps { padding: 0; list-style: none; counter-reset: steps; }
.steps li { position: relative; padding: 0 0 24px 50px; counter-increment: steps; }
.steps li:last-child { padding-bottom: 0; }
.steps li::before { content: counter(steps); position: absolute; inset-inline-start: 0; top: 0; width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; background: var(--tint); color: var(--accent); font-weight: 700; }
.muted { color: var(--muted); }
.storage { margin: 24px 0; }
.storage > div { padding: 18px 0; border-bottom: 1px solid var(--border); }
.storage > div:first-child { border-top: 1px solid var(--border); }
dt { font-weight: 700; margin-bottom: 6px; }
dd { margin: 0; color: var(--muted); }
code { font: .875em/1.6 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; padding: 2px 5px; background: var(--tint); border-radius: 5px; overflow-wrap: anywhere; }
pre { max-width: 100%; padding: 16px; overflow-x: auto; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); }
pre code { white-space: pre; background: transparent; padding: 0; font-size: .85rem; }
.advanced, .troubleshooting details { border: 1px solid var(--border); border-radius: 14px; margin: 12px 0; background: var(--surface); }
.advanced > p, .troubleshooting p { padding: 0 18px 18px; margin: 0; }
.advanced > pre { margin: 0 18px 18px; }
.guide-footer { border-top: 1px solid var(--border); padding-top: 28px; margin-top: 48px; }
.guide-footer > p { font-size: 1.3rem; font-weight: 650; }
.back-top { display: inline-block; padding: 12px 4px; min-height: 48px; }
@media (min-width: 900px) and (min-height: 600px) {
  .guide-layout { grid-template-columns: 235px minmax(0, 1fr); gap: 48px; }
  .contents { position: sticky; top: 24px; max-height: calc(100vh - 48px); overflow-y: auto; }
}
@media (max-width: 380px) {
  .languages { width: 100%; }
  .languages a { flex: 1; }
  .hero .button { width: 100%; }
}
@media (forced-colors: active) {
  .button, .languages a, .note { border: 1px solid ButtonText; }
  .languages a[aria-current="true"] { outline: 2px solid Highlight; }
  .contents a[aria-current="location"] { outline: 1px solid Highlight; outline-offset: -2px; }
}
@media print {
  :root {
    color-scheme: light;
    --bg: #fff; --surface: #fff; --fg: #1a1830; --muted: #615c7a;
    --accent: #5b47e0; --on-accent: #fff; --tint: #e5e1ff; --border: #d7d3e6;
  }
  body { background: white; color: black; }
  .site-header, .skip, .contents, .actions { display: none !important; }
  .guide-layout { display: block; }
  .hero { padding: 0 0 24px; }
  article > section { break-inside: avoid; }
  .page { padding: 0; max-width: none; }
}

/* Search is progressive enhancement; the complete guide remains readable offline. */
.guide-search { display: none; margin: 0 0 32px; padding: 20px; border: 1px solid var(--border); border-radius: 16px; background: var(--surface); }
html[data-enhanced] .guide-search { display: grid; gap: 12px; }
.guide-search label { font-weight: 650; }
.search-controls { display: flex; flex-wrap: wrap; gap: 12px; }
.search-controls input { flex: 1 1 240px; min-width: 0; width: 100%; }
.search-controls input, .search-controls button { min-height: 48px; border: 1px solid var(--control-border); border-radius: 10px; padding: 10px 14px; font: inherit; color: var(--fg); background: var(--surface); }
.search-controls button { cursor: pointer; }
.search-controls button:disabled { cursor: default; color: var(--muted); }
.guide-search p { margin: 0; overflow-wrap: anywhere; }
/* Keep the live region available before its first update, without an empty row. */
.guide-search [role="status"]:empty { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.search-results { list-style: none; padding: 0; margin: 0; }
.search-results a { display: block; min-height: 44px; padding: 10px 0; overflow-wrap: anywhere; }
@media print { html[data-enhanced] .guide-search { display: none; } }
