:root {
  --black: #090b0b;
  --panel: rgba(15, 19, 19, .9);
  --line: #3b4442;
  --paper: #daddd5;
  --muted: #929a95;
  --yellow: #e2bb3f;
  --mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --sans: "Arial Narrow", "Roboto Condensed", "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { color-scheme: dark; }

body {
  margin: 0;
  color: var(--paper);
  background: var(--black);
  font-family: var(--sans);
}

body::after {
  content: "";
  position: fixed;
  z-index: 20;
  inset: 0;
  pointer-events: none;
  opacity: .2;
  background: repeating-linear-gradient(0deg, transparent 0 3px, rgba(200,220,208,.035) 3px 4px);
}

a { color: inherit; }
::selection { color: var(--black); background: var(--yellow); }

#complex-plane {
  position: fixed;
  z-index: 0;
  inset: 0;
  width: 100vw;
  height: 100vh;
  background: radial-gradient(circle at 50% 45%, #17201e, var(--black) 64%);
}

.site-header, .post-shell, .index-shell, footer { position: relative; z-index: 1; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  min-height: 50px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(18px, 4vw, 58px);
  border-bottom: 1px solid var(--line);
  background: rgba(8,10,10,.9);
  backdrop-filter: blur(12px);
  font: 10px/1 var(--mono);
  letter-spacing: .14em;
  text-transform: uppercase;
}

.site-name { font-weight: 700; text-decoration: none; }
.site-name span { color: var(--yellow); }
.site-header nav { display: flex; gap: 28px; }
.site-header nav a { color: var(--muted); text-decoration: none; }
.site-header nav a:hover, .site-header nav a[aria-current="page"] { color: var(--yellow); }

.post-shell, .index-shell {
  max-width: 1120px;
  min-height: 100vh;
  margin: 0 auto;
  border-right: 1px solid var(--line);
  border-left: 1px solid var(--line);
  background: rgba(9,11,11,.62);
}

.post { background: rgba(12,15,15,.78); backdrop-filter: blur(6px); }

.post-header {
  padding: clamp(45px, 8vw, 110px) clamp(24px, 8vw, 110px) clamp(38px, 6vw, 80px);
  border-bottom: 1px solid var(--line);
}

.back-link {
  display: inline-block;
  margin-bottom: 70px;
  color: var(--yellow);
  font: 10px/1 var(--mono);
  letter-spacing: .12em;
  text-decoration: none;
  text-transform: uppercase;
}

.post-header h1, .index-shell > h1 {
  margin: 0;
  font-size: clamp(52px, 9vw, 116px);
  line-height: .88;
  letter-spacing: -.065em;
  text-transform: uppercase;
}

.dek {
  max-width: 760px;
  margin: 38px 0 0;
  color: #b7bdb8;
  font-size: clamp(18px, 2.3vw, 27px);
  line-height: 1.45;
}

.post-meta { display: flex; gap: 24px; margin-top: 35px; color: var(--muted); font: 10px/1 var(--mono); text-transform: uppercase; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 22px 0 0; list-style: none; }
.tags li { padding: 7px 9px; border: 1px solid var(--line); color: var(--muted); font: 9px/1 var(--mono); text-transform: uppercase; }

.post-content {
  max-width: 820px;
  margin: 0 auto;
  padding: clamp(55px, 9vw, 120px) clamp(22px, 6vw, 70px);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(17px, 1.65vw, 20px);
  line-height: 1.78;
}

.post-content h2, .post-content h3, .post-content h4 { font-family: var(--sans); line-height: 1.05; letter-spacing: -.035em; }
.post-content h2 { margin: 2.1em 0 .7em; font-size: clamp(34px, 5vw, 54px); }
.post-content h3 { margin: 1.9em 0 .65em; color: var(--yellow); font-size: clamp(25px, 3vw, 34px); }
.post-content p { margin: 1.25em 0; }
.post-content a { color: var(--yellow); text-underline-offset: 3px; }
.post-content img { width: 100%; height: auto; display: block; margin: 2.4em 0; border: 1px solid var(--line); }
.post-content pre { overflow-x: auto; margin: 2em 0; padding: 22px; border: 1px solid var(--line); background: #0b0e0e; font: 13px/1.65 var(--mono); }
.post-content code { font-family: var(--mono); font-size: .86em; }
.post-content :not(pre) > code { padding: .12em .3em; background: #202625; }
.post-content blockquote { margin: 2em 0; padding-left: 24px; border-left: 2px solid var(--yellow); color: #b9c0ba; }
.post-content hr { margin: 3.5em 0; border: 0; border-top: 1px solid var(--line); }

.index-shell { padding-bottom: 13vh; }
.index-shell > h1 { padding: clamp(70px, 12vw, 160px) clamp(24px, 6vw, 80px); border-bottom: 1px solid var(--line); }
.post-grid { padding: clamp(35px, 7vw, 90px) clamp(18px, 5vw, 62px); }
.post-card { border: 1px solid var(--line); border-bottom: 0; background: var(--panel); backdrop-filter: blur(7px); }
.post-card:last-child { border-bottom: 1px solid var(--line); }
.post-card a { display: block; padding: clamp(25px, 5vw, 58px); text-decoration: none; }
.post-card time { color: var(--yellow); font: 9px/1 var(--mono); text-transform: uppercase; }
.post-card h2 { margin: 24px 0 16px; font-size: clamp(30px, 5vw, 58px); line-height: .95; letter-spacing: -.045em; text-transform: uppercase; }
.post-card p { max-width: 720px; margin: 0; color: var(--muted); font: 13px/1.65 var(--mono); }
.post-card:hover { background: rgba(25,30,29,.94); }
.post-card:hover h2 { color: var(--yellow); }

footer { min-height: 80px; display: grid; place-items: center; border-top: 1px solid var(--line); background: rgba(8,10,10,.92); font: 10px/1 var(--mono); }
footer a { color: var(--muted); text-decoration: none; }

@media (max-width: 600px) {
  .site-header { padding: 0 14px; }
  .site-header nav { gap: 14px; }
  .post-shell, .index-shell { border: 0; }
  .back-link { margin-bottom: 48px; }
  .post-header h1, .index-shell > h1 { font-size: 50px; }
  .post-meta { flex-direction: column; gap: 10px; }
}
