/* Shared by the editor and both published article routes. */
:is(.editor, .reader-layout .article-body) {
  font-family: "Segoe UI", "Microsoft YaHei", system-ui, sans-serif;
  font-size: 1.075rem;
  line-height: 1.95;
  letter-spacing: 0.015em;
  overflow-wrap: anywhere;
}

:is(.editor, .reader-layout .article-body)
  :where(p, div, li, ul, ol, blockquote, h2, h3, span, b, strong, em) {
  font-family: inherit;
}

:is(.editor, .reader-layout .article-body) p,
:is(.editor, .reader-layout .article-body) > div,
:is(.editor, .reader-layout .article-body) blockquote > div,
:is(.editor, .reader-layout .article-body) li > div {
  margin: 1.05em 0;
  min-height: 1.95em;
  line-height: inherit;
}

:is(.editor, .reader-layout .article-body) h2,
:is(.editor, .reader-layout .article-body) h3 {
  line-height: 1.5;
  letter-spacing: 0;
  font-weight: 700;
}

:is(.editor, .reader-layout .article-body) h2 {
  margin: 2em 0 0.8em;
  padding-bottom: 0.45em;
  border-bottom: 1px solid var(--reader-border, rgba(100, 116, 139, 0.22));
  font-size: 1.5em;
}

:is(.editor, .reader-layout .article-body) h3 {
  margin: 1.65em 0 0.65em;
  font-size: 1.2em;
}

:is(.editor, .reader-layout .article-body) ul,
:is(.editor, .reader-layout .article-body) ol {
  padding-left: 1.6em;
  margin: 1em 0;
  line-height: inherit;
}

:is(.editor, .reader-layout .article-body) li {
  margin: 0.35em 0;
  padding-left: 0;
  line-height: inherit;
}

:is(.editor, .reader-layout .article-body) blockquote {
  margin: 1.2rem 0 !important;
  padding: 1rem 1.15rem !important;
  line-height: inherit;
}

.editor pre,
.editor pre[data-code-block],
.editor pre[data-code-block] code {
  font-family: Consolas, "Cascadia Code", monospace;
  font-size: 0.9rem;
  line-height: 1.7;
  letter-spacing: 0;
}

@media (max-width: 768px) {
  :is(.editor, .reader-layout .article-body) {
    font-size: 1rem;
  }
  :is(.editor, .reader-layout .article-body) h2 {
    font-size: 1.3em;
  }
  :is(.editor, .reader-layout .article-body) h3 {
    font-size: 1.12em;
  }
  .editor pre,
  .editor pre[data-code-block],
  .editor pre[data-code-block] code {
    font-size: 0.82rem;
  }
}
