html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  color: #1d1d1d;
  background: #fff;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Apple SD Gothic Neo", "Noto Sans JP", "Noto Sans KR", "Malgun Gothic", Meiryo, sans-serif;
  font-size: 16px;
  line-height: 1.75;
}

main,
footer {
  max-width: 46rem;
  margin: 0 auto;
  padding: 0 1.25rem;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: #fff;
  border-bottom: 1px solid #ddd;
}

.bar {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.3rem 1.4rem;
  max-width: 46rem;
  margin: 0 auto;
  padding: 0.65rem 1.25rem;
  font-size: 0.92rem;
}

.bar .name {
  color: #1d1d1d;
  font-weight: 700;
  text-decoration: none;
}

.menu,
.lang {
  display: flex;
  flex-wrap: wrap;
  gap: 0.2rem 0.9rem;
}

.lang {
  margin-left: auto;
  color: #888;
}

.menu a,
.lang a {
  color: #333;
  text-decoration: none;
}

.menu a:hover,
.lang a:hover {
  text-decoration: underline;
}

.lang [aria-current] {
  color: #1d1d1d;
  font-weight: 700;
}

.intro {
  padding-top: 2.5rem;
}

h2,
h3 {
  scroll-margin-top: 4rem;
}

@media (max-width: 640px) {
  .site-header {
    position: static;
  }

  .lang {
    margin-left: 0;
  }
}

h1 {
  margin: 0 0 0.75rem;
  font-size: 1.9rem;
  line-height: 1.3;
}

h2 {
  margin: 3rem 0 0.8rem;
  padding-bottom: 0.3rem;
  border-bottom: 1px solid #ddd;
  font-size: 1.3rem;
}

h3 {
  margin: 2rem 0 0.4rem;
  font-size: 1.05rem;
}

p {
  margin: 0.6rem 0;
}

a {
  color: #0a58ca;
}

.links {
  color: #666;
}

code,
pre {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.88em;
}

pre {
  margin: 1rem 0;
  padding: 0.9rem 1rem;
  overflow-x: auto;
  background: #f5f5f5;
  line-height: 1.55;
}

.table-wrap {
  overflow-x: auto;
}

table {
  margin: 0.8rem 0;
  border-collapse: collapse;
  font-size: 0.92rem;
}

th,
td {
  padding: 0.35rem 0.75rem;
  border-bottom: 1px solid #e2e2e2;
  text-align: left;
  vertical-align: top;
}

thead th {
  border-bottom: 1px solid #222;
  font-weight: 600;
  white-space: nowrap;
}

.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.small {
  color: #555;
  font-size: 0.9rem;
}

figure {
  margin: 1.5rem 0;
}

figure img {
  display: block;
  width: 100%;
  height: auto;
}

figcaption {
  margin-top: 0.4rem;
  color: #555;
  font-size: 0.9rem;
}

footer {
  margin-top: 4rem;
  padding-bottom: 3rem;
  color: #888;
  font-size: 0.85rem;
}

p code,
td code {
  overflow-wrap: anywhere;
}

tbody th {
  white-space: nowrap;
}
