
:root {
  --paper: #FAFAF8;
  --paper-2: #F3F2EE;
  --ink: #16181D;
  --gray: #5B6470;
  --gray-light: #8A919C;
  --blue: oklch(0.50 0.11 250);
  --blue-bright: oklch(0.58 0.11 250);
  --blue-wash: oklch(0.95 0.015 250);
  --navy: #0F1B2D;
  --hairline: #E5E4DF;
  --font-ui: 'Space Grotesk', sans-serif;
  --font-body: 'Source Serif 4', Georgia, serif;
  --font-mono: 'IBM Plex Mono', monospace;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; background: var(--paper); color: var(--ink);
  font-family: var(--font-body); font-size: 18px; line-height: 1.65; }
a { color: inherit; }
::selection { background: oklch(0.85 0.06 250); }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 32px; }

.site-header { position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: blur(8px); border-bottom: 1px solid var(--hairline); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.logo { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.logo .mark { display: grid; grid-template-columns: repeat(2, 12px); grid-template-rows: repeat(2, 12px); gap: 3px; }
.logo .mark span { display: block; background: var(--blue); }
.logo .mark span.hollow { background: transparent; border: 2px solid var(--blue); }
.logo .word { font-family: var(--font-ui); font-size: 19px; letter-spacing: 0.03em; line-height: 1; white-space: nowrap; }
.logo .word strong { font-weight: 700; color: var(--ink); }
.logo .word em { font-style: normal; font-weight: 400; color: var(--blue); }
.site-nav { display: flex; align-items: center; gap: 28px; }
.site-nav a { font-family: var(--font-ui); font-size: 15px; font-weight: 500; text-decoration: none; color: var(--gray); transition: color 120ms ease; }
.site-nav a:hover { color: var(--ink); }
.site-nav a.active { color: var(--ink); }

.hero { padding: 88px 0 72px; border-bottom: 1px solid var(--hairline); }
.hero .wrap { display: grid; grid-template-columns: 1fr auto; gap: 64px; align-items: center; }
.hero .kicker { font-family: var(--font-mono); font-size: 13px; font-weight: 500; letter-spacing: 0.18em; text-transform: uppercase; color: var(--blue); margin: 0 0 20px; }
.hero h1 { font-family: var(--font-ui); font-size: clamp(40px, 5.4vw, 60px); font-weight: 700; letter-spacing: -0.015em; line-height: 1.06; margin: 0 0 22px; text-wrap: balance; }
.hero h1 .accent { color: var(--blue); }
.hero .tagline { font-family: var(--font-body); font-size: 21px; line-height: 1.55; color: var(--gray); max-width: 540px; margin: 0; text-wrap: pretty; }
.hero-motif { display: grid; grid-template-columns: repeat(4, 34px); grid-template-rows: repeat(4, 34px); gap: 9px; }
.hero-motif span { display: block; }
.hero-motif .f { background: var(--blue); }
.hero-motif .h { border: 3px solid var(--blue); }
.hero-motif .w { background: var(--blue-wash); }
.hero-motif .g { border: 3px solid var(--hairline); }

.posts { padding: 64px 0 88px; }
.posts .section-label { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 36px; }
.posts .section-label h2 { font-family: var(--font-mono); font-size: 13px; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; color: var(--ink); margin: 0; }
.posts .section-label a { font-family: var(--font-mono); font-size: 13px; color: var(--gray); text-decoration: none; }
.posts .section-label a:hover { color: var(--blue); }
.post-card { display: grid; grid-template-columns: 168px 1fr; gap: 40px; padding: 40px 0; border-top: 1px solid var(--hairline); text-decoration: none; }
.post-card:last-child { border-bottom: 1px solid var(--hairline); }
.post-card .meta { font-family: var(--font-mono); font-size: 13px; line-height: 1.8; color: var(--gray-light); padding-top: 6px; }
.post-card .meta .date { color: var(--gray); }
.post-card h3 { font-family: var(--font-ui); font-size: 27px; font-weight: 600; letter-spacing: -0.01em; line-height: 1.22; margin: 0 0 14px; text-wrap: balance; transition: color 120ms ease; }
.post-card:hover h3 { color: var(--blue); }
.post-card .excerpt { font-size: 17px; line-height: 1.6; color: var(--gray); margin: 0 0 18px; max-width: 680px; text-wrap: pretty; }
.post-card .read-more { font-family: var(--font-ui); font-size: 15px; font-weight: 600; color: var(--blue); display: inline-flex; align-items: center; gap: 8px; }
.post-card .read-more::after { content: "\2192"; transition: transform 120ms ease; }
.post-card:hover .read-more::after { transform: translateX(4px); }

.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.tag { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.04em; color: var(--gray); border: 1px solid var(--hairline); background: var(--paper); padding: 4px 10px; white-space: nowrap; }

.subscribe { background: var(--navy); color: var(--paper); padding: 64px 0; }
.subscribe .wrap { display: grid; grid-template-columns: 1fr auto; gap: 48px; align-items: center; }
.subscribe h2 { font-family: var(--font-ui); font-size: 28px; font-weight: 600; letter-spacing: -0.01em; margin: 0 0 10px; }
.subscribe p { font-size: 17px; color: #9DA9BC; margin: 0; max-width: 480px; }
.subscribe form { display: flex; gap: 10px; }
.subscribe input { font-family: var(--font-ui); font-size: 15px; padding: 12px 16px; width: 280px; background: #1A2A42; border: 1px solid #2C3E5C; color: var(--paper); outline: none; }
.subscribe input::placeholder { color: #6B7A93; }
.subscribe input:focus { border-color: var(--blue-bright); }
.subscribe button { font-family: var(--font-ui); font-size: 15px; font-weight: 600; padding: 12px 22px; background: var(--blue-bright); color: var(--paper); border: none; cursor: pointer; }
.subscribe button:hover { background: oklch(0.64 0.11 250); }

.site-footer { border-top: 1px solid var(--hairline); padding: 40px 0 48px; }
.site-footer .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.site-footer .copy { font-family: var(--font-ui); font-size: 14px; color: var(--gray-light); }
.site-footer nav { display: flex; gap: 24px; }
.site-footer nav a { font-family: var(--font-ui); font-size: 14px; color: var(--gray); text-decoration: none; }
.site-footer nav a:hover { color: var(--blue); }

.article-header { padding: 72px 0 0; }
.article-header .wrap, .article-body .wrap { max-width: 760px; }
.breadcrumb { font-family: var(--font-mono); font-size: 13px; letter-spacing: 0.06em; color: var(--gray-light); margin: 0 0 28px; }
.breadcrumb a { color: var(--blue); text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }
.article-header h1 { font-family: var(--font-ui); font-size: clamp(32px, 4.4vw, 46px); font-weight: 700; letter-spacing: -0.015em; line-height: 1.12; margin: 0 0 24px; text-wrap: balance; }
.article-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; font-family: var(--font-mono); font-size: 14px; color: var(--gray); }
.article-meta .sep { color: var(--hairline); }
.article-header .tags { margin: 22px 0 0; }
.article-header .rule { display: flex; align-items: center; gap: 12px; margin-top: 40px; }
.article-header .rule .line { flex: 1; height: 1px; background: var(--hairline); }
.article-header .rule .blocks { display: grid; grid-template-columns: repeat(2, 8px); grid-template-rows: repeat(2, 8px); gap: 2px; }
.article-header .rule .blocks span { background: var(--blue); }
.article-header .rule .blocks span.hollow { background: transparent; border: 1.5px solid var(--blue); }

.article-body { padding: 44px 0 72px; }
.article-body .lede { font-size: 22px; line-height: 1.6; color: var(--ink); }
.article-body p { margin: 0 0 26px; text-wrap: pretty; }
.article-body h1 { font-family: var(--font-ui); font-size: clamp(32px, 4.4vw, 46px); font-weight: 700; letter-spacing: -0.015em; line-height: 1.12; margin: 0 0 24px; }
.article-body h2 { font-family: var(--font-ui); font-size: 29px; font-weight: 600; letter-spacing: -0.01em; line-height: 1.25; margin: 52px 0 18px; }
.article-body h3 { font-family: var(--font-ui); font-size: 21px; font-weight: 600; margin: 38px 0 14px; }
.article-body a { color: var(--blue); text-decoration-thickness: 1px; text-underline-offset: 3px; }
.article-body strong { font-weight: 600; }
.article-body ol, .article-body ul { margin: 0 0 26px; padding-left: 26px; }
.article-body li { margin-bottom: 14px; text-wrap: pretty; }
.article-body li::marker { font-family: var(--font-mono); font-size: 15px; color: var(--blue); font-weight: 600; }
.article-body blockquote { border-left: 3px solid var(--blue); background: var(--blue-wash); margin: 32px 0; padding: 16px 24px; }
.article-body blockquote p { margin: 0; }
.article-body code { font-family: var(--font-mono); font-size: 0.9em; background: var(--paper-2); padding: 2px 6px; border-radius: 3px; }
.article-body pre { background: var(--paper-2); padding: 18px 20px; overflow-x: auto; }
.article-body pre code { background: none; padding: 0; }
.article-body img { max-width: 100%; height: auto; }
.diagram { margin: 40px 0; }
.diagram svg { display: block; margin: 0 auto; }
.diagram figcaption { font-family: var(--font-mono); font-size: 12.5px; line-height: 1.6; color: var(--gray); text-align: center; margin-top: 14px; }
.article-footer { border-top: 1px solid var(--hairline); margin-top: 40px; padding-top: 36px; }
.article-footer .back { font-family: var(--font-ui); font-size: 15px; font-weight: 600; color: var(--blue); text-decoration: none; }
.article-footer .back:hover { text-decoration: underline; }

@media (max-width: 880px) {
  .hero .wrap { grid-template-columns: 1fr; }
  .hero-motif { display: none; }
  .post-card { grid-template-columns: 1fr; gap: 12px; }
  .subscribe .wrap { grid-template-columns: 1fr; }
  .subscribe input { width: 100%; }
  .subscribe form { flex-direction: column; }
  .site-footer .wrap { flex-direction: column; align-items: flex-start; }
}
