:root {
  color-scheme: light;
  --bg: #fbfbfa;
  --text: #171717;
  --muted: #969696;
  --quiet: #b5b5b5;
  --faint: #eeeeee;
  --hover: #505050;
  --measure: 620px;
  --list: 620px;
  --ui: -apple-system, BlinkMacSystemFont, "SF Pro Text", "PingFang SC", "PingFang TC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--bg);
  color: var(--text);
  font-family: var(--ui);
  font-size: 16px;
  letter-spacing: 0;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body {
  margin: 0;
  min-height: 100vh;
}

a {
  color: inherit;
  text-decoration: none;
}

a:visited {
  color: inherit;
}

.shell {
  margin: 0 auto;
  max-width: var(--list);
  padding: 54px 30px 72px;
}

.top {
  align-items: baseline;
  display: grid;
  gap: 24px;
  grid-template-columns: 1fr auto;
  margin-bottom: 64px;
}

.brand {
  display: inline-block;
  font-size: 25px;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1;
}

.nav {
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  font-size: 13px;
  gap: 16px;
  line-height: 1.2;
  margin-top: 24px;
}

.nav a[aria-current="page"] {
  color: var(--text);
}

.langs {
  color: var(--quiet);
  display: flex;
  font-size: 12px;
  gap: 9px;
  justify-content: flex-end;
  line-height: 1;
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
  white-space: nowrap;
}

.top:hover .langs,
.top:focus-within .langs,
.langs.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.langs a[aria-current="true"] {
  color: #747474;
}

.brand:hover,
.nav a:hover,
.langs a:hover,
.entry:hover {
  color: var(--hover);
}

.index {
  display: grid;
  gap: 0;
  justify-items: start;
}

.entry {
  display: block;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.72;
  max-width: 100%;
  padding: 3px 0;
  width: fit-content;
}

.section-title {
  font-size: 17px;
  font-weight: 500;
  line-height: 1.3;
  margin: 0 0 36px;
}

.article-shell {
  max-width: var(--measure);
}

.article-head {
  margin-bottom: 22px;
}

.article-title {
  font-size: 23px;
  font-weight: 500;
  line-height: 1.42;
  margin: 0;
}

.article-date {
  color: var(--muted);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  line-height: 1.4;
  margin-top: 13px;
}

.article {
  font-size: 14px;
  line-height: 1.9;
}

.article p {
  margin: 0 0 1.05em;
}

.article h2,
.article h3 {
  font-size: 17px;
  font-weight: 500;
  line-height: 1.5;
  margin: 2.2em 0 0.9em;
}

.article blockquote {
  border-left: 1px solid var(--faint);
  color: #333;
  margin: 1.8em 0;
  padding-left: 1.2em;
}

.article ul,
.article ol {
  margin: 0 0 1.3em;
  padding-left: 1.4em;
}

.article li {
  margin: 0.3em 0;
}

.article hr {
  border: 0;
  border-top: 1px solid var(--faint);
  margin: 2.4em 0;
}

.article a {
  border-bottom: 1px solid var(--faint);
}

.footer {
  color: #aaa;
  font-size: 13px;
  margin-top: 96px;
}

.footer:empty {
  display: none;
}

@media (max-width: 640px) {
  html {
    font-size: 16px;
  }

  .shell {
    padding: 34px 22px 58px;
  }

  .top {
    gap: 18px;
    margin-bottom: 56px;
  }

  .brand {
    font-size: 24px;
  }

  .nav {
    gap: 15px;
    margin-top: 20px;
  }

  .entry {
    font-size: 14px;
    padding: 3px 0;
  }

  .article-title {
    font-size: 22px;
  }

  .article {
    font-size: 14px;
    line-height: 1.9;
  }
}

@media (hover: none) {
  .langs {
    opacity: 0.55;
    pointer-events: auto;
  }
}
