:root{
  --ink: #16233F;
  --ink-soft: #22335A;
  --paper: #F6F7FA;
  --blueprint: #E9F0FA;
  --copper: #BF6B3D;
  --blue: #2F6FED;
  --text: #1D2536;
  --text-muted: #5B6478;
  --hairline: #D8DEE8;
  --grid-line: rgba(22,35,63,0.07);
  --max-w: 42rem;
}

*{ box-sizing: border-box; }
html{ scroll-behavior: smooth; }

body{
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font-family: 'IBM Plex Sans', -apple-system, sans-serif;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, .display{
  font-family: 'Space Grotesk', 'IBM Plex Sans', sans-serif;
  color: var(--ink);
  margin: 0;
  font-weight: 600;
}

code, .mono{ font-family: 'JetBrains Mono', ui-monospace, monospace; }

a{ color: var(--blue); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover{ color: var(--copper); }
a:focus-visible, button:focus-visible{ outline: 2px solid var(--copper); outline-offset: 3px; }

/* ---------- Nav ---------- */
.nav{
  position: sticky; top: 0; z-index: 10;
  background: rgba(246,247,250,0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--hairline);
}
.nav-inner{
  max-width: 64rem; margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex; align-items: center; justify-content: space-between;
}
.brand{ display: flex; align-items: center; gap: 0.55rem; text-decoration: none; }
.brand svg{ width: 22px; height: 22px; }
.brand span{ font-family: 'Space Grotesk', sans-serif; font-weight: 600; font-size: 1.15rem; color: var(--ink); }
.nav-links{ display: flex; gap: 1.75rem; list-style: none; margin: 0; padding: 0; }
.nav-links a{ color: var(--ink); font-size: 0.95rem; text-decoration: none; }
.nav-links a:hover{ color: var(--copper); }

/* ---------- Home hero: light blueprint grid ---------- */
.hero{
  position: relative;
  background-color: var(--blueprint);
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 28px 28px;
  padding: 5.5rem 1.5rem 5rem;
  border-bottom: 1px solid var(--hairline);
}
.hero-inner{
  max-width: 64rem; margin: 0 auto;
  display: grid; grid-template-columns: 1.3fr 1fr; gap: 2rem; align-items: center;
}
.hero h1{
  font-size: clamp(2.2rem, 5vw, 3.2rem);
  line-height: 1.15;
  max-width: 13ch;
}
.hero .mono-label{
  display: inline-block; margin-bottom: 1rem;
  font-size: 0.85rem; color: var(--copper);
}
.hero p{
  color: var(--text-muted);
  max-width: 36ch;
  margin-top: 1.25rem;
  font-size: 1.05rem;
}
.hero-btn{
  display: inline-block;
  margin-top: 2rem;
  background: var(--copper);
  color: #FBF6F1;
  font-weight: 600;
  padding: 0.75rem 1.4rem;
  border-radius: 3px;
  text-decoration: none;
  font-size: 0.95rem;
}
.hero-btn:hover{ background: #A85A31; color: #fff; }
.hero-mark{ justify-self: center; width: 100%; max-width: 220px; }

/* ---------- Small page hero (inner pages) ---------- */
.page-hero{
  background-color: var(--blueprint);
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 28px 28px;
  padding: 3.5rem 1.5rem 3rem;
  border-bottom: 1px solid var(--hairline);
}
.page-hero-inner{ max-width: var(--max-w); margin: 0 auto; }
.page-hero .eyebrow{ font-family: 'JetBrains Mono', monospace; color: var(--copper); font-size: 0.82rem; margin-bottom: 0.6rem; display: inline-block; }
.page-hero h1{ font-size: clamp(1.8rem, 4vw, 2.4rem); line-height: 1.2; }
.page-hero p{ color: var(--text-muted); margin-top: 0.9rem; max-width: 40ch; }
.back-link{ color: var(--text-muted); font-size: 0.9rem; text-decoration: none; display: inline-block; margin-bottom: 1rem; }
.back-link:hover{ color: var(--copper); }

/* ---------- Sections / main content ---------- */
main{ max-width: var(--max-w); margin: 0 auto; padding: 0 1.5rem; }
.section-label{
  max-width: 64rem; margin: 4.5rem auto 0; padding: 0 1.5rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.82rem; color: var(--text-muted);
}

/* article preview list (home page) */
.preview{ padding: 2.4rem 0; border-bottom: 1px solid var(--hairline); }
.preview:last-of-type{ border-bottom: none; padding-bottom: 3rem; }
.preview .meta{ font-family: 'JetBrains Mono', monospace; font-size: 0.8rem; color: var(--text-muted); margin-bottom: 0.5rem; }
.preview h2{ font-size: 1.45rem; line-height: 1.3; margin-bottom: 0.6rem; }
.preview h2 a{ color: var(--ink); text-decoration: none; }
.preview h2 a:hover{ color: var(--copper); }
.preview p{ margin: 0 0 0.7rem; color: var(--text); }
.preview .read-more{ font-size: 0.9rem; font-weight: 500; }

/* full article page */
.article-meta{ font-size: 0.85rem; color: var(--text-muted); margin-bottom: 0.5rem; }
.article-body{ padding: 2.5rem 0 1rem; }
.article-body p{ margin: 0 0 1.1rem; }
.article-body ol, .article-body ul{ margin: 0 0 1.1rem; padding-left: 1.3rem; }
.article-body li{ margin-bottom: 0.5rem; }
.article-body strong{ color: var(--ink); }
.article-body h3{ font-size: 1.15rem; margin: 1.8rem 0 0.8rem; }
.article-body code{ background: var(--blueprint); padding: 0.1rem 0.4rem; border-radius: 3px; font-size: 0.9em; }

.more-notes{
  border-top: 1px solid var(--hairline);
  padding: 2rem 0 3rem;
  font-size: 0.95rem;
}
.more-notes p:first-child{ font-family: 'JetBrains Mono', monospace; font-size: 0.8rem; color: var(--text-muted); margin: 0 0 0.7rem; }

/* generic prose pages: about / privacy */
.page-content{ padding: 2.5rem 0 3rem; }
.page-content h2{ font-size: 1.25rem; margin: 2rem 0 0.8rem; }
.page-content h2:first-child{ margin-top: 0; }
.page-content p{ margin: 0 0 1.1rem; }
.page-content ul{ margin: 0 0 1.1rem; padding-left: 1.3rem; }
.page-content li{ margin-bottom: 0.5rem; }

/* about band on homepage — the one dark, bold moment */
.about-band{
  background: var(--ink-soft);
  color: #E7EAF3;
  padding: 4rem 1.5rem;
  margin-top: 2rem;
}
.about-band-inner{ max-width: var(--max-w); margin: 0 auto; }
.about-band h2{ color: #FBFAF6; font-size: 1.55rem; margin-bottom: 1rem; }
.about-band p{ color: #C4CBE0; margin: 0 0 1rem; }
.about-band a{ color: #E8A87C; }

/* contact snippet / page */
.contact-block{ max-width: var(--max-w); margin: 0 auto; padding: 3.5rem 1.5rem 1rem; }
.contact-block h2{ font-size: 1.35rem; margin-bottom: 0.75rem; }
.contact-block p{ color: var(--text-muted); }

footer{
  border-top: 1px solid var(--hairline);
  margin-top: 2.5rem;
  padding: 1.75rem 1.5rem 2.5rem;
}
.footer-inner{
  max-width: 64rem; margin: 0 auto;
  display: flex; flex-wrap: wrap; gap: 0.75rem 1.5rem;
  align-items: center; justify-content: space-between;
  color: var(--text-muted); font-size: 0.85rem;
}
.footer-inner a{ color: var(--text-muted); }
.footer-links{ display: flex; gap: 1.2rem; list-style: none; margin: 0; padding: 0; }

@media (max-width: 720px){
  .hero-inner{ grid-template-columns: 1fr; }
  .hero-mark{ display: none; }
  .nav-links{ gap: 1rem; }
}

@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior: auto; }
}
