/* ---- Reset & base ---- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --text:    #1a1a1a;
  --muted:   #6b7280;
  --accent:  #2563eb;
  --border:  #e5e7eb;
  --bg:      #ffffff;
  --mono:    'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', monospace;
  --sans:    -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--sans);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* ---- Layout ---- */
.container {
  max-width: 680px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ---- Header ---- */
header {
  padding: 3rem 0 2rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 3rem;
}

header h1 {
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 0.75rem;
}

nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.25rem;
}

nav a {
  font-size: 0.875rem;
  color: var(--muted);
  font-family: var(--mono);
}

nav a:hover {
  color: var(--accent);
  text-decoration: none;
}

/* ---- Sections ---- */
section {
  margin-bottom: 3.5rem;
}

section h2 {
  font-size: 0.75rem;
  font-family: var(--mono);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-bottom: 1.25rem;
}

section p {
  font-size: 1rem;
  color: var(--text);
  margin-bottom: 0.75rem;
  max-width: 60ch;
}

.section-note {
  font-size: 0.875rem;
  color: var(--muted);
  margin-bottom: 1rem;
}

/* ---- Writing list ---- */
.post-list {
  list-style: none;
}

.post-list li {
  display: flex;
  align-items: baseline;
  gap: 1.25rem;
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--border);
}

.post-list li:first-child {
  border-top: 1px solid var(--border);
}

.date {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--muted);
  white-space: nowrap;
  min-width: 5rem;
}

.post-list a {
  font-size: 0.9375rem;
  color: var(--text);
}

.post-list a:hover {
  color: var(--accent);
}

.see-more {
  display: inline-block;
  margin-top: 0.75rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--muted);
}

.see-more:hover {
  color: var(--accent);
  text-decoration: none;
}

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

section h2 a:hover {
  color: var(--accent);
}

/* ---- Into list ---- */
.into-list {
  list-style: none;
}

.into-list li {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.4rem;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.9375rem;
}

.into-list li:first-child {
  border-top: 1px solid var(--border);
}

.into-label {
  font-family: var(--mono);
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  min-width: 4.5rem;
}

.item-title {
  color: var(--text);
  font-weight: 500;
}

.item-author {
  color: var(--muted);
  font-size: 0.875rem;
}

/* ---- Footer ---- */
footer {
  padding: 2rem 0 3rem;
  border-top: 1px solid var(--border);
  margin-top: 1rem;
}

footer p {
  font-size: 0.8125rem;
  color: var(--muted);
}

footer a {
  color: var(--muted);
}

footer a:hover {
  color: var(--accent);
}

/* ---- Blog post ---- */
.post {
  margin-bottom: 3.5rem;
}

.post-header {
  margin-bottom: 2.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}

.post-header h2 {
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
  color: var(--text);
}

.post-meta {
  font-size: 0.9375rem;
  color: var(--muted);
  margin-bottom: 0.5rem;
}

.post-date {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--muted);
}

.post-body p {
  font-size: 1rem;
  color: var(--text);
  margin-bottom: 1.25rem;
  max-width: 60ch;
  line-height: 1.75;
}

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

.post-footer a {
  font-family: var(--mono);
  font-size: 0.8125rem;
  color: var(--muted);
}

.post-footer a:hover {
  color: var(--accent);
  text-decoration: none;
}

/* ---- Responsive ---- */
@media (max-width: 480px) {
  header {
    padding: 2rem 0 1.5rem;
  }

  .post-list li {
    flex-direction: column;
    gap: 0.2rem;
  }

  .item-list li {
    gap: 0.3rem;
  }
}
