/* Topic pages (/tematy/*) and their index: one readable column, nothing competing
   with the text except one test link at the end. */
.topic-body { background: var(--app-canvas); color: var(--app-ink); }
.topic-page { width: min(calc(100% - 32px), 760px); margin: 0 auto; padding: 28px 0 88px; }
.topic-page :where(h1, h2, p, ul, ol) { margin-top: 0; }
.topic-crumbs { display: flex; flex-wrap: wrap; gap: 8px; color: var(--app-muted); font-size: 13px; font-weight: 650; }
.topic-crumbs a { color: var(--app-ink); text-decoration: none; }
.topic-crumbs a:hover { text-decoration: underline; text-underline-offset: 3px; }
.topic-hero { padding: 26px 0 8px; }
.topic-eyebrow { margin: 0 0 14px; color: #777771; font-size: 13px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.topic-hero h1 { margin: 0; font-size: clamp(38px, 5vw, 56px); font-weight: 690; line-height: 1.02; letter-spacing: -.05em; }
.topic-lead { margin: 20px 0 0; color: var(--app-muted); font-size: 18px; line-height: 1.7; }
.topic-page article > section { padding-top: 44px; }
.topic-page h2 { margin: 0 0 14px; font-size: 26px; font-weight: 680; line-height: 1.15; letter-spacing: -.03em; }
.topic-page article > section > p { margin: 0 0 14px; color: #3d3d39; font-size: 16px; line-height: 1.8; }
.topic-example { display: grid; gap: 8px; margin-top: 36px; padding: 22px 24px; border-left: 3px solid #171714; border-radius: 0 12px 12px 0; background: #fff; }
.topic-example strong { font-size: 15px; }
.topic-example p { margin: 0; color: var(--app-muted); font-size: 15px; line-height: 1.7; }
.topic-traps { margin: 0; padding: 0; border-top: 1px solid var(--app-line-strong); list-style: none; }
.topic-traps li { position: relative; padding: 16px 8px 16px 28px; border-bottom: 1px solid var(--app-line); color: #3d3d39; font-size: 15px; line-height: 1.65; }
.topic-traps li::before { position: absolute; top: 24px; left: 6px; width: 7px; height: 7px; border-radius: 50%; background: #171714; content: ""; }
.topic-question { margin-top: 14px; padding: 20px 22px; border: 1px solid var(--app-line); border-radius: 12px; background: #fff; }
.topic-question > p { margin: 0 0 12px; font-size: 16px; font-weight: 650; line-height: 1.5; }
.topic-question > p span { color: var(--app-muted); }
.topic-question ol { display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; }
.topic-question li { display: grid; grid-template-columns: 28px 1fr; align-items: baseline; color: #3d3d39; font-size: 15px; line-height: 1.5; }
.topic-question li b { color: var(--app-muted); font-size: 13px; }
.topic-question details { margin-top: 14px; border-top: 1px solid var(--app-line); }
.topic-question summary { padding: 12px 0 0; color: var(--app-ink); font-size: 14px; font-weight: 720; cursor: pointer; }
.topic-question details p { margin: 10px 0 0; color: var(--app-muted); font-size: 15px; line-height: 1.6; }
.topic-question details strong { color: var(--app-ink); }
.topic-cta { display: flex; align-items: center; justify-content: space-between; gap: 18px 28px; margin-top: 52px; padding: 28px; border-radius: 14px; background: #171714; color: #fff; }
.topic-page article > .topic-cta { padding-top: 28px; }
.topic-cta h2 { margin: 0 0 8px; color: #fff; font-size: 24px; }
.topic-cta p { margin: 0; color: #b5b4ad; font-size: 15px; line-height: 1.6; }
.topic-button { min-height: 48px; display: inline-flex; flex: 0 0 auto; align-items: center; justify-content: center; padding: 0 20px; border-radius: 10px; background: #fff; color: #171714; font-size: 15px; font-weight: 750; text-decoration: none; }
.topic-button:hover { background: #ececea; }
.topic-related { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 28px; }
.topic-related span { margin-right: 4px; color: var(--app-muted); font-size: 13px; font-weight: 700; }
.topic-related a { min-height: 34px; display: inline-flex; align-items: center; padding: 0 12px; border: 1px solid var(--app-line-strong); border-radius: 9px; color: var(--app-ink); font-size: 13px; font-weight: 650; text-decoration: none; }
.topic-related a:hover { background: #fff; }
.topic-index .topic-hero { padding-top: 8px; }
.topic-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 34px; }
.topic-card { display: grid; align-content: start; gap: 8px; padding: 20px 22px; border: 1px solid var(--app-line); border-radius: 12px; background: #fff; color: var(--app-ink); text-decoration: none; transition: border-color 160ms ease, transform 160ms ease; }
.topic-card:hover { border-color: var(--app-ink); transform: translateY(-1px); }
.topic-card strong { font-size: 17px; letter-spacing: -.02em; }
.topic-card span { color: var(--app-muted); font-size: 14px; line-height: 1.55; }

@media (max-width: 640px) {
  .topic-page { width: calc(100% - 32px); padding-top: 18px; }
  .topic-lead { font-size: 16px; }
  .topic-page h2 { font-size: 23px; }
  .topic-question { padding: 18px; }
  .topic-cta { flex-direction: column; align-items: stretch; padding: 24px; }
  .topic-grid { grid-template-columns: 1fr; }
}
