:root {
  --bg: #f4f2ee;
  --surface: rgba(255, 255, 255, 0.72);
  --text: #161616;
  --muted: #5c5c5c;
  --faint: #8a8a8a;
  --border: #d8d2ca;
  --border-strong: #bdb5ab;
  --link: #0f62fe;
  --link-hover: #0043ce;
  --max-width: 1080px;
  --radius: 14px;
  --shadow: 0 8px 30px rgba(0, 0, 0, 0.04);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

table {
    border-collapse: collapse;
}

tr {
  border-bottom: 1px solid #ddd;
}

body {
  margin: 0;
  font-family: "IBM Plex Mono", monospace;
  background:
    linear-gradient(to bottom, rgba(255,255,255,0.35), rgba(255,255,255,0)) no-repeat,
    var(--bg);
  color: var(--text);
  line-height: 1.75;
  letter-spacing: -0.01em;
}

a {
  color: var(--link);
  text-underline-offset: 0.14em;
}

a:hover,
a:focus {
  color: var(--link-hover);
}

.skip-link {
  position: absolute;
  left: -9999px;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
  background: var(--text);
  color: #ffffff;
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  z-index: 1000;
}

.wrap {
  width: min(100% - 2rem, var(--max-width));
  margin: 0 auto;
}

.site-header {
  padding: 3.5rem 0 1.75rem;
}

.header-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}

.site-name {
  margin: 0 0 1rem;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--faint);
}

.site-home {
  color: inherit;
  text-decoration: none;
}

.site-home:hover,
.site-home:focus {
  color: var(--link);
}

h1 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 2.0rem);
  line-height: 1.5;
  letter-spacing: -0.04em;
  /* max-width: 12ch; */
}

.intro {
  margin: 1rem 0 0;
  max-width: 54ch;
  color: var(--muted);
  font-size: 0.96rem;
}

.site-nav {
  display: flex;
  gap: 1rem;
  padding-top: 0.3rem;
  white-space: nowrap;
  font-size: 0.95rem;
}

.site-nav a {
  text-decoration: none;
  color: var(--text);
  padding-bottom: 0.15rem;
  border-bottom: 1px solid transparent;
}

.site-nav a:hover,
.site-nav a:focus,
.site-nav a[aria-current="page"] {
  color: var(--link);
  border-bottom-color: currentColor;
}

.post-list,
.post-full,
.tag-section {
  padding: 1.5rem 0 4rem;
}

.post-item,
.tag-item {
  padding: 1.35rem 0;
  border-bottom: 1px solid var(--border);
}

.post-item:first-child {
  padding-top: 0.5rem;
}

.post-meta {
  margin: 0 0 0.55rem;
  font-size: 0.84rem;
  color: var(--faint);
}

.post-meta a {
  color: inherit;
  text-decoration: none;
}

.post-meta a:hover,
.post-meta a:focus {
  color: var(--link);
  text-decoration: underline;
}

.post-item h2,
.tag-item h2 {
  margin: 0 0 0.5rem;
  font-size: 1.15rem;
  line-height: 1.35;
  font-weight: 500;
}

.post-item h2 a,
.tag-item h2 a {
  text-decoration: none;
  color: inherit;
}

.post-item h2 a:hover,
.post-item h2 a:focus,
.tag-item h2 a:hover,
.tag-item h2 a:focus {
  color: var(--link);
  text-decoration: underline;
}

.post-summary,
.tag-item p {
  margin: 0;
  color: var(--muted);
  max-width: 62ch;
  font-size: 0.95rem;
}

.post-header {
  margin-bottom: 2rem;
  padding: 1.0rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
  backdrop-filter: blur(6px);
}

.post-title {
  margin: 0 0 0.9rem;
  font-size: clamp(1.9rem, 4.5vw, 2.8rem);
  line-height: 1.12;
  letter-spacing: -0.04em;
}

.post-lede {
  margin: 0;
  /* max-width: 62ch; */
  color: var(--muted);
}

.post-content {
  /* max-width: 65ch; */
}

.post-content h3 {
  margin: 2.2rem 0 0.8rem;
  font-size: 1.02rem;
  line-height: 1.4;
}

.post-content p {
  margin: 0 0 1.2rem;
}

.post-content ul {
  margin: 0 0 1.5rem 1.25rem;
  padding: 0;
}

.post-content li {
  margin-bottom: 0.55rem;
}

.post-content blockquote {
  margin: 2rem 0;
  padding: 0.25rem 0 0.25rem 1rem;
  border-left: 2px solid var(--border-strong);
  color: var(--muted);
}

.post-footer {
  margin-top: 2.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}

.tag-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.tag-item {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.site-footer {
  padding: 1.5rem 0 2rem;
  border-top: 1px solid var(--border);
  margin-top: 2rem;
}

.footer-note {
  margin: 0;
  color: var(--faint);
  font-size: 0.84rem;
}

.footer-note a {
  color: inherit;
  text-decoration: none;
}

.footer-note a:hover,
.footer-note a:focus {
  color: var(--link);
  text-decoration: underline;
}

@media (max-width: 640px) {
  .site-header {
    padding-top: 2.4rem;
  }

  .header-row {
    flex-direction: column;
    gap: 1rem;
    padding-bottom: 1.25rem;
  }

  .site-nav {
    padding-top: 0;
  }

  h1 {
    max-width: none;
  }

  .post-item,
  .tag-item {
    padding: 1.15rem 0;
  }

  .post-item h2,
  .tag-item h2 {
    font-size: 1.02rem;
  }

  .post-header {
    padding: 1.1rem;
  }
}
