/* СОЧНО — подробный разбор проекта на странице кейса (tools/case_pages.py): оглавление, разделы, списки, шаги, вопросы.
   Остальные стили кейса — встроенные в страницу (шаблон живых кейсов). Шрифт — как у всего сайта, без моноширинного. */

.case-more{max-width:760px;margin:clamp(56px,9vh,110px) auto 0;padding-top:clamp(40px,6vh,64px);border-top:1px solid var(--line)}
.case-more-head h2{font-family:var(--font-display);font-weight:700;font-size:clamp(30px,4vw,56px);line-height:1.02;letter-spacing:-.035em;margin:0 0 18px;text-wrap:balance}
.case-more-head>p{font-size:clamp(17px,1.35vw,20px);line-height:1.6;color:var(--ink-soft);margin:0}
.case-toc{display:grid;gap:2px;margin:28px 0 0;padding:20px 24px;border-radius:16px;background:#f6f2ea;list-style:none;counter-reset:toc}
.case-toc li{counter-increment:toc}
.case-toc a{display:flex;gap:14px;padding:8px 0;font-size:16px;line-height:1.35;font-weight:600;color:var(--ink);text-decoration:none;transition:color .2s var(--ease)}
.case-toc a::before{content:counter(toc,decimal-leading-zero);flex:none;width:26px;font-weight:700;color:var(--accent);font-variant-numeric:tabular-nums}
.case-toc a:hover{color:var(--accent)}
.case-sec{scroll-margin-top:110px}
.case-sec .mono{font-weight:700;font-variant-numeric:tabular-nums}
.case-block h2{text-wrap:balance}
.case-list,.case-steps{margin:0 0 1.2em;padding:0;list-style:none;display:grid;gap:12px}
.case-list li,.case-steps li{position:relative;font-size:clamp(16px,1.25vw,19px);line-height:1.55;color:var(--ink)}
.case-list li{padding-left:28px}
.case-list li::before{content:"";position:absolute;left:4px;top:.62em;width:9px;height:9px;border-radius:50%;background:var(--accent)}
.case-steps{counter-reset:st}
.case-steps li{counter-increment:st;padding:16px 18px 16px 62px;border-radius:14px;background:#f6f2ea}
.case-steps li::before{content:counter(st);position:absolute;left:18px;top:14px;width:30px;height:30px;border-radius:50%;background:var(--accent);color:#fff;
  font-size:15px;font-weight:700;line-height:30px;text-align:center}
.case-list:last-child,.case-steps:last-child{margin-bottom:0}
.case-note{padding:18px 22px;border-left:3px solid var(--accent);border-radius:0 14px 14px 0;background:#fdf3f1}
.case-faq{margin:clamp(40px,7vh,80px) 0 0}
.case-faq h2{font-family:var(--font-display);font-weight:700;font-size:clamp(26px,3.4vw,46px);letter-spacing:-.03em;line-height:1.05;margin:0 0 18px}
.case-faq details{border-bottom:1px solid var(--line)}
.case-faq summary{position:relative;display:block;padding:20px 48px 20px 0;font-size:clamp(17px,1.35vw,20px);font-weight:600;line-height:1.35;cursor:pointer;list-style:none}
.case-faq summary::-webkit-details-marker{display:none}
.case-faq summary::after{content:"+";position:absolute;right:4px;top:50%;transform:translateY(-50%);width:32px;height:32px;border-radius:50%;
  background:#f6f2ea;font-size:20px;line-height:32px;text-align:center;color:var(--ink);transition:transform .25s var(--ease),background .25s var(--ease)}
.case-faq details[open] summary::after{transform:translateY(-50%) rotate(45deg);background:var(--accent);color:#fff}
.case-faq details p{margin:0 0 20px;font-size:clamp(16px,1.25vw,18px);line-height:1.6;color:var(--ink-soft)}
.case-body a,.case-more a:not(.case-toc a){color:var(--accent);text-decoration:underline;text-underline-offset:3px}
@media (max-width:640px){
  .case-toc{padding:14px 16px}
  .case-steps li{padding:14px 14px 14px 54px}
  .case-steps li::before{left:14px;top:13px;width:28px;height:28px;line-height:28px}
}
