.auto-toc:empty { display: none; }

:root {
  --bg: rgba(15, 17, 19);
  --fg: rgba(235,219,178,1);
  --link: rgba(200,219,178,1);
}
html,body {
    background: var(--bg);
    color: var(--fg);
    font-family: var(--font-serif-g);
}
h2 {
  font-family: var(--font-serif-caps);
}
h3,h4 {
  text-transform: capitalize;
}
h2,h3 {
  text-align: center;
}
h4 {
  padding-left: 0.3em;
}
a {
  color: var(--link);
  margin: 1.5px;
  text-decoration: none;
}
a:hover{
  text-decoration: underline;
}
p::first-letter,li::first-letter {
  text-transform: uppercase;
}
li {
    list-style: disclosure-closed;
    /* display: flow-root list-item; */
}
/* BLOCKQUOTE */
blockquote {
  text-align: justify;
  hyphens: auto;
  border-left: 1px solid rgba(235,219,178,.7);
  padding: 0 10px 0 10px;
}

/* LEFT MENU */
#container {
    margin: 0 auto;
}
#flex {
    display: flex;
}

aside {
    background: var(--bg);
    border-right: 1px solid beige;
    padding: 15px;
}
aside h2 {
	color: var(--fg-light);
}

aside pre code {
    overflow-x: scroll !important;
    max-width: 210px !important;
}

aside#leftSidebar{
    width: 300px;
}
main {
    flex: 1;
    order: 2;
    padding: 15px;
    column-count: 2;
}

main li {
    list-style: square;
}

#leftSidebar {
    order: 1;
}

.post-right-list {
  display: flex;
  float: right;
}
.hidden {
  display: none;
}

/* FOOTNOTE (Cobalt.rs / pulldown-cmark) */
section.footnotes,
.footnotes {
  column-count: 1;
  break-before: column;
  margin-top: 0.6em;
  line-height: 1.35;
}
.footnotes ol {
  list-style: decimal;
  padding-left: 1.25em;
  margin: 0.25em 0 0;
}
.footnotes li {
  list-style: inherit;
  margin-bottom: 0.15em;
}
.footnote-definition {
  font-size: 0.8em;
  display: flex;
  align-items: baseline;
  gap: 0.2em;
  margin: 0;
}
.footnote-definition-label {
  flex-shrink: 0;
  font-size: 1em;
  vertical-align: sub;
  font-variant-position: sub;
}
.footnote-definition-label::after {
  content: ".";
}
sup.footnote-ref a {
  text-decoration: none;
}
sup.footnote-ref a:hover {
  text-decoration: underline;
}

/* 脚注选中态 — Swiss：中性、克制 */
.footnotes :target,
.footnotes li:target,
.footnote-definition:target {
  scroll-margin-top: 15vh;
  background: rgba(235, 219, 178, 0.06);
  border-left: 1px solid rgba(235, 219, 178, 0.2);
  padding-left: 0.5em;
  margin-left: -0.5em;
}

code span {
    color: var(--fg) !important;
    font-family: var(--font-serif-g);
}
pre {
    background-color: var(--bg) !important;
}
pre code {
    overflow-x: auto;
    white-space: pre-wrap;
}
hr,.notes-header {
    border-bottom: 1px solid rgba(235,219,178,.7);
}
hr {
  width:40%;
}
.mjx-chtml .mjx-noError {
	color: beige !important;
  border: none !important;
}

/* ── TOC ── */
.auto-toc ul { list-style: none; padding: 0; margin: 0.5em 0; }
.auto-toc > ul { border-left: 1px solid rgba(235,219,178,0.15); padding-left: 0.5em; }
.auto-toc ul ul { padding-left: 0.8em; margin: 0; }
.auto-toc li { margin: 0.2em 0; list-style: none; }
.auto-toc li::before { content: none; }
.auto-toc a { display: block; font-size: 0.82em; color: rgba(235,219,178,0.6); text-decoration: none; padding: 1px 0; }
.auto-toc a:hover { color: var(--link); }
.auto-toc a.active { color: var(--fg); }
.auto-toc ul ul a { font-size: 0.76em; color: rgba(235,219,178,0.45); }
.auto-toc ul ul a:hover { color: var(--link); }
