/* Стили внутренностей старых статей Знаний.
   Заперты внутрь .legacy, чтобы не спорить с новым оформлением. */

.legacy /* ============ статья ============ */


.toc{background:var(--sunk); border:1px solid var(--line); border-radius:var(--r-in); padding:22px 24px}
.legacy .toc__t{font-size:.7rem; font-weight:800; letter-spacing:.15em; text-transform:uppercase;
  color:var(--ink-soft); margin-bottom:13px}
.legacy .toc ol{margin:0; padding:0; list-style:none; counter-reset:t; columns:2; column-gap:32px}
.legacy .toc li{counter-increment:t; margin-bottom:9px; break-inside:avoid; font-size:.93rem}
.legacy .toc li::before{content:counter(t,decimal-leading-zero); font-family:var(--mono);
  font-size:.75rem; color:var(--accent-deep); font-weight:700; margin-right:9px}
.legacy .toc a{text-decoration:none; font-weight:600}
.legacy .toc a:hover{text-decoration:underline; text-decoration-color:var(--accent); background:none}

.legacy section{padding:44px 0 4px; border-top:1px solid var(--line); margin-top:42px}
.legacy .s__head{display:flex; gap:14px; align-items:flex-start; margin-bottom:20px}
.legacy .s__n{font-family:var(--mono); font-size:.76rem; font-weight:700; color:var(--accent-deep);
  background:var(--accent-wash); border-radius:5px; padding:4px 8px; margin-top:6px; white-space:nowrap}
.legacy h2{font-size:clamp(1.5rem,3.1vw,2.15rem); max-width:20ch}
.legacy h3{font-size:1.15rem; font-weight:700; margin:32px 0 12px; letter-spacing:-.02em}
.legacy h4{font-size:.73rem; font-weight:800; letter-spacing:.14em; text-transform:uppercase;
  color:var(--ink-soft); margin:28px 0 12px}

.legacy .belt{display:grid; grid-template-columns:repeat(auto-fit,minmax(148px,1fr)); gap:1px;
  background:var(--line); border:1px solid var(--line); border-radius:var(--r-in); overflow:hidden; margin:24px 0 10px}
.legacy .st{background:var(--card); padding:15px 15px 17px}
.legacy .st__n{font-family:var(--mono); font-size:.69rem; font-weight:700; color:var(--accent-deep)}
.legacy .st__t{font-weight:700; font-size:.96rem; margin:5px 0; line-height:1.25}
.legacy .st__d{font-size:.81rem; line-height:1.42; color:var(--ink-soft)}
.legacy .st--human{background:var(--accent-wash)}
.legacy .st--loop{background:var(--go-wash)}
.legacy .note{font-size:.85rem; color:var(--ink-soft); margin:0 0 6px}

.legacy .tw{overflow-x:auto; margin:22px 0 10px; border:1px solid var(--line); border-radius:var(--r-in); background:var(--card)}
.legacy table{border-collapse:collapse; width:100%; min-width:640px; font-size:.89rem}
.legacy th{text-align:left; font-size:.67rem; letter-spacing:.12em; text-transform:uppercase;
  color:var(--ink-soft); font-weight:800; padding:12px 15px;
  border-bottom:2px solid var(--line); background:var(--sunk); white-space:nowrap}
.legacy td{padding:12px 15px; border-bottom:1px solid var(--line-soft); vertical-align:top; line-height:1.48}
.legacy tr:last-child td{border-bottom:none}
.legacy td.n{font-weight:700}
.legacy td.pr{font-family:var(--mono); font-size:.81rem; font-variant-numeric:tabular-nums; white-space:nowrap}
.legacy .dim{color:var(--ink-soft); font-size:.9em}
.legacy .tag{display:inline-block; font-size:.65rem; font-weight:800; letter-spacing:.08em;
  text-transform:uppercase; padding:4px 9px; border-radius:5px; white-space:nowrap}
.legacy .tag--go{background:var(--go-wash); color:var(--go)}
.legacy .tag--warn{background:var(--warn-wash); color:var(--warn)}
.legacy .tag--stop{background:var(--stop-wash); color:var(--stop)}

.legacy .box{border:1px solid var(--line); border-left:5px solid var(--accent);
  background:var(--card); border-radius:10px; padding:20px 22px; margin:24px 0}
.legacy .box--stop{border-left-color:var(--stop)}
.legacy .box--go{border-left-color:var(--go)}
.legacy .box p:last-child{margin-bottom:0}
.legacy .box__l{display:block; font-size:.67rem; font-weight:800; letter-spacing:.14em;
  text-transform:uppercase; color:var(--ink-soft); margin-bottom:10px}

.legacy .cards{display:grid; grid-template-columns:repeat(auto-fit,minmax(250px,1fr)); gap:14px; margin:24px 0}
.legacy .card{background:var(--card); border:1px solid var(--line); border-radius:var(--r-in); padding:19px 20px}
.legacy .card h4{margin:0 0 9px; color:var(--accent-deep)}
.legacy .card p{font-size:.9rem; line-height:1.55; margin-bottom:.7em}
.legacy .card p:last-child{margin-bottom:0}

.legacy ul.cl{list-style:none; padding:0; margin:16px 0}
.legacy ul.cl li{padding:0 0 11px 24px; position:relative}
.legacy ul.cl li::before{content:""; position:absolute; left:2px; top:.66em;
  width:8px; height:8px; border-radius:2px; background:var(--accent)}
.legacy ul.cl li.no::before{background:var(--stop)}
.legacy ul.cl li.yes::before{background:var(--go)}

.legacy ol.steps{list-style:none; counter-reset:s; padding:0; margin:18px 0}
.legacy ol.steps li{counter-increment:s; position:relative; padding:0 0 16px 46px}
.legacy ol.steps li::before{content:counter(s); position:absolute; left:0; top:-2px;
  width:30px; height:30px; display:flex; align-items:center; justify-content:center;
  font-family:var(--mono); font-size:.79rem; font-weight:700; color:var(--ink);
  background:var(--accent); border-radius:50%}

/* полоса прогресса чтения */

/* правки после переезда на новое оформление */
.legacy section{border-top:1px solid var(--line);margin-top:clamp(40px,5vw,58px);
  padding:clamp(32px,4vw,46px) 0 0}
.legacy .s__head{display:flex;gap:14px;align-items:baseline;margin-bottom:18px}
.legacy .s__head h2{margin:0}
.legacy .s__n{margin-top:0;font-family:var(--title);font-weight:800;background:var(--accent);
  color:var(--ink);border-radius:999px;padding:4px 10px;font-size:.7rem}
.legacy .toc{background:var(--card);border:0;border-radius:var(--r-card);padding:24px 26px;
  box-shadow:0 1px 2px rgba(20,20,15,.05),0 10px 26px -18px rgba(20,20,15,.24)}
.legacy .toc__t{font-family:var(--title);font-weight:800;color:var(--ink-faint)}
.legacy .box{border:0;border-left:5px solid var(--accent);border-radius:var(--r-card);
  box-shadow:0 1px 2px rgba(20,20,15,.05),0 10px 26px -18px rgba(20,20,15,.24)}
.legacy .card{border:0;border-radius:var(--r-card);
  box-shadow:0 1px 2px rgba(20,20,15,.05),0 8px 22px -16px rgba(20,20,15,.24)}
.legacy .tw,.legacy .belt{border:0;border-radius:var(--r-card);overflow:hidden;
  box-shadow:0 1px 2px rgba(20,20,15,.05),0 10px 26px -18px rgba(20,20,15,.24)}
.legacy .tag{border-radius:999px}
.legacy ol.steps li::before{font-family:var(--title);font-weight:800}
