/* Правовые документы Asabi (asabi.su/privacy/, asabi.su/consent/) —
   страницы генерирует tools/legal/build-legal.ps1, docs/legal-documents.md.
   Экран — тёмная палитра лендинга; печать (она же PDF) — белый лист A4. */

@font-face {
  font-family: "Inter"; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url(../assets/fonts/inter-cyrillic.woff2) format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Inter"; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url(../assets/fonts/inter-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Inter"; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url(../assets/fonts/inter-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --bg: #0D1117;
  --bg-card: #161B22;
  --border: #30363D;
  --text: #E6EDF3;
  --text-muted: #B0B8C0;
  --accent: #3FB950;
  --accent-soft: #238636;
  --link: #58A6FF;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  background: radial-gradient(ellipse at 15% 0%, #14331f 0%, var(--bg) 45%) no-repeat, var(--bg);
  color: var(--text);
  font: 400 16px/1.6 "Inter", "Segoe UI", Roboto, system-ui, sans-serif;
  min-height: 100vh;
}
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }

.top {
  max-width: 960px; margin: 0 auto;
  padding: 20px 16px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); font-weight: 700; font-size: 18px; }
.brand:hover { text-decoration: none; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 16px; border-radius: 12px;
  background: var(--accent-soft); color: #fff; font-weight: 600; font-size: 15px;
}
.btn:hover { background: #2EA043; text-decoration: none; }
.btn svg { width: 18px; height: 18px; }

.doc {
  max-width: 960px; margin: 0 auto 24px;
  padding: 32px 40px 16px;
  background: rgba(22, 27, 34, .75);
  border: 1px solid var(--border); border-radius: 20px;
}
h1 { font-size: 32px; line-height: 1.2; font-weight: 800; color: var(--accent); }
.edition { margin-top: 8px; color: var(--text-muted); font-size: 14px; }
.intro { margin-top: 20px; }

.row {
  display: grid; grid-template-columns: 200px 1fr; gap: 24px;
  padding: 22px 0;
  border-top: 1px solid var(--border);
}
.doc > .edition + .row, .doc > .intro + .row { margin-top: 24px; }
.row h2 { font-size: 17px; line-height: 1.35; font-weight: 700; color: var(--text); }
.body > * + * { margin-top: 10px; }
.body ul, .body ol { padding-left: 22px; }
.body li + li { margin-top: 4px; }

.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; line-height: 1.45; }
th, td { text-align: left; vertical-align: top; padding: 10px 12px 10px 0; border-bottom: 1px solid var(--border); }
th { color: var(--text-muted); font-weight: 600; }

.foot {
  max-width: 960px; margin: 0 auto;
  padding: 0 16px 40px;
  color: var(--text-muted); font-size: 14px;
}
.foot > div + div { margin-top: 6px; }
.print-only { display: none; }

@media (max-width: 720px) {
  .doc { padding: 24px 16px 8px; border-radius: 16px; margin: 0 8px 24px; }
  h1 { font-size: 26px; }
  .row { grid-template-columns: 1fr; gap: 8px; }
  /* Таблица целей — карточками: подпись столбца перед значением. */
  table, thead, tbody, tr, td { display: block; }
  thead { display: none; }
  tr { padding: 10px 0; border-bottom: 1px solid var(--border); }
  td { border: 0; padding: 2px 0; }
  td::before { content: attr(data-label) ": "; color: var(--text-muted); font-weight: 600; }
}

@media print {
  @page { size: A4; margin: 16mm 16mm 18mm; }
  :root { --text: #111; --text-muted: #555; --border: #ccc; --accent: #1a7f37; --link: #0b5cad; }
  body { background: #fff; font-size: 11pt; min-height: 0; }
  .top { padding: 0 0 10mm; max-width: none; }
  .top .btn { display: none; }
  .doc { background: none; border: 0; border-radius: 0; padding: 0; max-width: none; margin: 0; }
  h1 { font-size: 22pt; }
  .row { grid-template-columns: 45mm 1fr; gap: 6mm; padding: 4mm 0; }
  .row h2 { font-size: 11.5pt; break-after: avoid; }
  .body p, .body li { orphans: 3; widows: 3; }
  table { font-size: 9.5pt; }
  tr { break-inside: avoid; }
  .foot { max-width: none; padding: 8mm 0 0; border-top: 1px solid var(--border); margin-top: 6mm; }
  .foot .links { display: none; }
  .print-only { display: block; }
}
