@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&display=swap');

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

:root {
  --bg-blue: #0047AB;
  --bg-dark: #16171a;
  --fg: #e0e0e0;
  --fg-dim: rgba(224, 224, 224, 0.6);
  --rule: rgba(224, 224, 224, 0.28);
  --sans: 'Inter', Helvetica, Arial, sans-serif;
}

html { font-size: 16px; scroll-behavior: smooth; }
body {
  color: var(--fg);
  font-family: var(--sans);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}
body.blog-list { background: var(--bg-blue); }
body.blog-post { background: var(--bg-dark); }

.wrap {
  max-width: 880px;
  margin: 0 auto;
  padding: 56px 40px 128px;
}
body.blog-post .wrap { max-width: 760px; padding-bottom: 160px; }
@media (max-width: 640px) {
  .wrap { padding: 32px 22px 88px; }
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 80px;
}
.nav a {
  font-size: 16px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg);
  text-decoration: none;
  border-bottom: 0.5px solid var(--fg-dim);
  transition: border-color 0.2s;
}
.nav a:hover { border-bottom-color: var(--fg); }

.page-label {
  font-size: 16px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg);
  margin-bottom: 32px;
}
.page-title {
  font-size: clamp(40px, 6.5vw, 64px);
  font-weight: 300;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin-bottom: 72px;
  color: var(--fg);
}
.page-title span { font-weight: 500; }

.entries { display: block; }
.entry {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 64px;
  align-items: baseline;
  padding: 32px 0;
  border-top: 0.5px solid var(--rule);
  text-decoration: none;
  color: var(--fg);
  transition: opacity 0.2s;
}
.entry:last-child { border-bottom: 0.5px solid var(--rule); }
.entry:hover { opacity: 0.7; }
.entry-date {
  font-size: 16px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg);
}
.entry-title {
  font-size: 28px;
  font-weight: 400;
  letter-spacing: -0.005em;
  line-height: 1.4;
  color: var(--fg);
}
.entry-title span { color: var(--fg-dim); font-weight: 300; }
@media (max-width: 640px) {
  .entry { grid-template-columns: 1fr; gap: 10px; padding: 26px 0; }
  .entry-title { font-size: 24px; }
}

.post-meta {
  font-size: 16px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg-dim);
  margin-bottom: 24px;
}
.post-title {
  font-size: clamp(40px, 6.5vw, 64px);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin-bottom: 16px;
  color: var(--fg);
}
.post-subtitle {
  font-size: clamp(22px, 3vw, 30px);
  font-weight: 300;
  letter-spacing: -0.005em;
  line-height: 1.4;
  color: var(--fg-dim);
  margin-bottom: 64px;
}

.post-body { font-size: 22px; line-height: 1.7; color: var(--fg); }
.post-body p { margin-bottom: 26px; }
.post-body h2 {
  font-size: 30px;
  font-weight: 500;
  margin-top: 56px;
  margin-bottom: 22px;
  letter-spacing: -0.005em;
}
.post-body a {
  color: var(--fg);
  text-decoration: none;
  border-bottom: 0.5px solid var(--fg-dim);
  transition: border-color 0.2s;
}
.post-body a:hover { border-bottom-color: var(--fg); }

.post-body img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 32px 0;
}

.post-body strong { font-weight: 600; color: var(--fg); }

.post-body code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.88em;
  background: rgba(224, 224, 224, 0.08);
  padding: 0.1em 0.35em;
  border-radius: 3px;
  border: 0.5px solid var(--rule);
}
.post-body h2 code { font-size: 0.85em; }

.post-body pre {
  background: rgba(224, 224, 224, 0.04);
  border: 0.5px solid var(--rule);
  border-radius: 4px;
  padding: 22px 26px;
  margin: 32px 0;
  overflow-x: auto;
  font-size: 18px;
  line-height: 1.6;
}
.post-body pre code {
  background: transparent;
  border: 0;
  padding: 0;
  border-radius: 0;
  font-size: inherit;
  color: var(--fg);
}

.post-body blockquote {
  margin: 32px 0;
  padding: 6px 0 6px 24px;
  border-left: 1px solid var(--rule);
  color: var(--fg-dim);
  font-style: italic;
}

.code-block {
  position: relative;
  margin: 32px 0;
}
.code-block pre {
  margin: 0;
  max-height: 640px;
}
.code-copy {
  position: absolute;
  top: 14px;
  right: 14px;
  background: var(--bg-dark);
  color: var(--fg);
  border: 0.5px solid var(--rule);
  padding: 7px 14px;
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  border-radius: 3px;
  z-index: 1;
  transition: border-color 0.2s, color 0.2s;
}
.code-copy:hover { border-color: var(--fg); }
.code-copy.copied { color: #6fcf97; border-color: #6fcf97; }

.post-foot {
  margin-top: 96px;
  padding-top: 36px;
  border-top: 0.5px solid var(--rule);
}
.post-foot a {
  font-size: 16px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg);
  text-decoration: none;
  border-bottom: 0.5px solid var(--fg-dim);
  transition: border-color 0.2s;
}
.post-foot a:hover { border-bottom-color: var(--fg); }
