/* === RESET & TOKENS === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
:root {
  --bg: #f1ede5;
  --ink: #0f0f0f;
  --hot: #1a2a8c;
  --muted: rgba(15,15,15,0.55);
  --line: rgba(15,15,15,0.16);
}
body {
  background: var(--bg);
  color: var(--ink);
  font-family: 'Inter', -apple-system, sans-serif;
  overflow-x: hidden;
  cursor: none;
  line-height: 1.5;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }

/* === CURSOR === */
.cursor {
  position: fixed;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--ink);
  pointer-events: none;
  z-index: 9999;
  mix-blend-mode: difference;
  transition: width 0.25s, height 0.25s;
  transform: translate(-50%, -50%);
}
.cursor.big { width: 64px; height: 64px; }
@media (max-width: 900px) {
  body { cursor: auto; }
  .cursor { display: none; }
}

/* === GRAIN === */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 0.06 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  pointer-events: none;
  z-index: 5;
  opacity: 0.55;
  mix-blend-mode: multiply;
}

/* === TOP BAR === */
.topbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.4rem 2rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  mix-blend-mode: difference;
  color: var(--bg);
}
.topbar .logo {
  display: inline-flex;
  align-items: center;
  line-height: 0;
  text-transform: none;
}
.topbar .logo img {
  width: 40px;
  height: 40px;
  display: block;
  filter: invert(1);
}
.topbar nav { display: flex; gap: 2rem; align-items: center; }
.topbar nav a { transition: opacity 0.3s; }
.topbar nav a:hover { opacity: 0.6; }
.topbar nav a.active { color: #ff8aa8; }
.topbar .lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding-left: 1.2rem;
  border-left: 1px solid currentColor;
  opacity: 0.85;
}
.topbar .lang-switch a { font-weight: 500; }
.topbar .lang-switch .current { opacity: 0.5; pointer-events: none; }
.topbar .lang-switch .sep { opacity: 0.4; }
@media (max-width: 768px) {
  .topbar nav > a { display: none; }
  .topbar nav .lang-switch {
    padding-left: 0;
    border-left: none;
  }
  .topbar { padding: 1rem 1.2rem; }
}

/* === EYEBROW === */
.section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 1.2rem;
}
.section-eyebrow .bar {
  width: 22px; height: 2px;
  background: var(--hot);
  display: inline-block;
}

/* === BREADCRUMB === */
.breadcrumb {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 2rem;
  display: flex;
  gap: 0.6rem;
  align-items: center;
}
.breadcrumb a:hover { color: var(--hot); }

/* === ARCHIVE === */
.archive {
  padding: 8rem 2rem 5rem;
  max-width: 1200px;
  margin: 0 auto;
}
.archive-head { margin-bottom: 4rem; }
.archive-title {
  font-family: 'Fraunces', serif;
  font-weight: 300;
  font-size: clamp(2.4rem, 6vw, 5rem);
  line-height: 1;
  letter-spacing: -0.035em;
  margin-bottom: 1.5rem;
  max-width: 1000px;
}
.archive-title .accent { color: var(--hot); font-style: italic; font-weight: 400; }
.archive-title .it { font-style: italic; }
.archive-sub {
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--muted);
  max-width: 640px;
}
.tag-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 3rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--line);
}
.tag-btn {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.5rem 1rem;
  border: 1px solid var(--ink);
  border-radius: 100px;
  background: transparent;
  color: var(--ink);
  cursor: none;
  transition: background 0.3s, color 0.3s;
}
.tag-btn:hover { background: var(--ink); color: var(--bg); }
.tag-btn.active { background: var(--hot); color: var(--bg); border-color: var(--hot); }

.archive-list { display: flex; flex-direction: column; }
.archive-item {
  display: grid;
  grid-template-columns: 1fr 2fr 200px;
  gap: 2rem;
  padding: 2.5rem 0;
  border-bottom: 1px solid var(--line);
  transition: padding 0.4s;
  position: relative;
}
.archive-item::before {
  content: '';
  position: absolute;
  left: 0; top: 50%;
  width: 0; height: 6px;
  background: var(--hot);
  border-radius: 100px;
  transform: translateY(-50%);
  transition: width 0.3s;
}
.archive-item:hover { padding-left: 1.5rem; padding-right: 1rem; }
.archive-item:hover::before { width: 8px; }
.archive-item:hover h2 { color: var(--hot); }
.archive-meta {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}
.archive-meta .tag { color: var(--hot); font-weight: 500; }
.archive-item h2 {
  font-family: 'Fraunces', serif;
  font-weight: 400;
  font-size: clamp(1.5rem, 3vw, 2.4rem);
  line-height: 1.1;
  letter-spacing: -0.025em;
  transition: color 0.3s;
}
.archive-item h2 .it { font-style: italic; }
.archive-item p {
  grid-column: 2 / 3;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--muted);
  margin-top: 0.8rem;
}
.archive-readmore {
  align-self: end;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
@media (max-width: 900px) {
  .archive-item { grid-template-columns: 1fr; gap: 0.8rem; }
  .archive-item p { grid-column: 1; margin-top: 0; }
  .archive-meta { flex-direction: row; gap: 1rem; }
}

/* === ARTICLE === */
.article {
  max-width: 1200px;
  margin: 0 auto;
  padding: 8rem 2rem 5rem;
}
.article-header { margin-bottom: 4rem; max-width: 880px; }
.article-meta-top {
  display: flex;
  gap: 1.5rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 1.5rem;
}
.article-meta-top .tag { color: var(--hot); font-weight: 500; }
.article-h1 {
  font-family: 'Fraunces', serif;
  font-weight: 300;
  font-size: clamp(2.2rem, 6vw, 5rem);
  line-height: 1;
  letter-spacing: -0.035em;
  margin-bottom: 2rem;
}
.article-h1 .it { font-style: italic; }
.article-h1 .accent { color: var(--hot); font-style: italic; font-weight: 400; }
.article-lead {
  font-family: 'Fraunces', serif;
  font-weight: 300;
  font-style: italic;
  font-size: clamp(1.2rem, 2.2vw, 1.7rem);
  line-height: 1.4;
  color: var(--ink);
  max-width: 800px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 1.5rem 0;
  margin-top: 2rem;
}

.article-body {
  max-width: 720px;
  font-size: 1.1rem;
  line-height: 1.8;
}
.article-body > * { margin-bottom: 1.5rem; }
.article-body h2 {
  font-family: 'Fraunces', serif;
  font-weight: 400;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-top: 3rem;
  margin-bottom: 1rem;
}
.article-body h2 .it { font-style: italic; }
.article-body h3 {
  font-family: 'Fraunces', serif;
  font-weight: 500;
  font-size: 1.35rem;
  line-height: 1.3;
  margin-top: 2.2rem;
  margin-bottom: 0.8rem;
}
.article-body p strong { font-weight: 600; }
.article-body em { font-style: italic; }
.article-body a {
  color: var(--hot);
  border-bottom: 1px solid var(--hot);
  transition: opacity 0.3s;
}
.article-body a:hover { opacity: 0.6; }
.article-body ul, .article-body ol {
  padding-left: 1.5rem;
  margin-bottom: 1.8rem;
}
.article-body li { margin-bottom: 0.6rem; }
.article-body ul li::marker { color: var(--hot); }
.article-body blockquote {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-size: 1.4rem;
  line-height: 1.4;
  border-left: 3px solid var(--hot);
  padding: 0.5rem 0 0.5rem 1.5rem;
  margin: 2rem 0;
  color: var(--ink);
}
.article-body hr {
  border: none;
  height: 1px;
  background: var(--line);
  margin: 3rem 0;
}

.article-share {
  margin-top: 4rem;
  padding-top: 2.5rem;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
}
.article-share-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}
.article-share-links {
  display: flex;
  gap: 1.5rem;
}
.article-share-links a {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border-bottom: 1px solid var(--ink);
  padding-bottom: 0.3rem;
  transition: color 0.3s, border-color 0.3s;
}
.article-share-links a:hover { color: var(--hot); border-color: var(--hot); }

/* RELATED */
.related {
  max-width: 1200px;
  margin: 0 auto;
  padding: 5rem 2rem 6rem;
  border-top: 1px solid var(--line);
}
.related h3 {
  font-family: 'Fraunces', serif;
  font-weight: 300;
  font-style: italic;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  letter-spacing: -0.02em;
  margin-bottom: 2.5rem;
}
.related-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}
.related-card {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  padding: 1.8rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  transition: border-color 0.3s, transform 0.4s;
}
.related-card:hover { border-color: var(--hot); transform: translateY(-3px); }
.related-card .meta {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}
.related-card .meta .tag { color: var(--hot); font-weight: 500; }
.related-card h4 {
  font-family: 'Fraunces', serif;
  font-weight: 400;
  font-size: 1.3rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
}
.related-card h4 .it { font-style: italic; }
@media (max-width: 768px) {
  .related-grid { grid-template-columns: 1fr; }
}

/* === CTA AT BOTTOM === */
.article-cta {
  background: var(--ink);
  color: var(--bg);
  border-radius: 16px;
  padding: 3rem 2.5rem;
  margin-top: 4rem;
  text-align: center;
}
.article-cta h3 {
  font-family: 'Fraunces', serif;
  font-weight: 300;
  font-size: clamp(1.6rem, 3.5vw, 2.4rem);
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: 0.8rem;
}
.article-cta h3 .it { font-style: italic; }
.article-cta p {
  font-size: 1rem;
  opacity: 0.8;
  margin-bottom: 1.5rem;
  max-width: 540px;
  margin-left: auto;
  margin-right: auto;
}
.article-cta a {
  display: inline-block;
  padding: 0.9rem 1.6rem;
  background: var(--hot);
  border-radius: 100px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  transition: background 0.3s, transform 0.3s;
}
.article-cta a:hover { transform: translateY(-2px); background: #2540b8; }

/* === AUTHOR BIO BOX === */
.author-bio {
  max-width: 1200px;
  margin: 4rem auto 0;
  padding: 2.5rem 2rem;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 2rem;
  align-items: start;
}
.author-bio-photo {
  width: 110px;
  height: 110px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--ink);
}
.author-bio-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.author-bio-content .author-bio-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.7rem;
}
.author-bio-content h3 {
  font-family: 'Fraunces', serif;
  font-weight: 400;
  font-size: 1.6rem;
  letter-spacing: -0.02em;
  margin-bottom: 0.6rem;
  line-height: 1.1;
}
.author-bio-content h3 .it { font-style: italic; }
.author-bio-content p {
  font-size: 0.98rem;
  line-height: 1.6;
  color: var(--ink);
  margin-bottom: 1rem;
  max-width: 720px;
}
.author-bio-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.2rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.author-bio-links a {
  border-bottom: 1px solid var(--ink);
  padding-bottom: 0.2rem;
  transition: color 0.3s, border-color 0.3s;
}
.author-bio-links a:hover { color: var(--hot); border-color: var(--hot); }
@media (max-width: 768px) {
  .author-bio {
    grid-template-columns: 1fr;
    text-align: left;
    padding: 2rem 1.5rem;
  }
  .author-bio-photo { width: 80px; height: 80px; }
}

/* === FOOTER === */
footer {
  padding: 2.5rem 2rem;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}
@media (max-width: 768px) {
  footer { flex-direction: column; gap: 0.8rem; text-align: center; }
}
