/* ================================================================
   typography.css — Base type rules
   Body, headings, links, code, utilities.
   ================================================================ */

body {
  font-family: var(--ff-sans);
  font-size: var(--fs-2);
  font-weight: 400;
  line-height: var(--lh-body);
  letter-spacing: var(--ls-body);
  color: var(--c-fg);
  background-color: var(--c-bg);
  font-feature-settings: "kern" 1, "liga" 1, "calt" 1;
  overflow-x: hidden;
}

/* ── Headings ── */

h1, h2, h3, h4, h5, h6 {
  font-family: var(--ff-sans);
  font-weight: 700;
  letter-spacing: var(--ls-tight);
  line-height: var(--lh-tight);
}

h1 {
  font-size: var(--fs-2);
  line-height: var(--lh-display);
}

h2 {
  font-size: var(--fs-2);
}

h3 {
  font-size: var(--fs-2);
}

h4 {
  font-size: var(--fs-2);
  font-weight: 700;
}

h5, h6 {
  font-size: var(--fs-2);
  font-family: var(--ff-sans);
  font-weight: 400;
  letter-spacing: var(--ls-meta);
  text-transform: uppercase;
}

/* ── Body text ── */

p {
  max-width: var(--measure);
}

p + p {
  margin-top: var(--sp-3);
}

/* ── Links ── */

a {
  text-decoration: underline;
  text-decoration-color: var(--c-dim);
  text-underline-offset: 0.15em;
  text-decoration-thickness: 1px;
  transition: text-decoration-color var(--dur-fast) var(--ease-out);
}

a:hover {
  text-decoration-color: var(--c-accent);
}

/* ── Code and mono ── */

code, kbd, samp, pre {
  font-family: var(--ff-sans);
  font-size: var(--fs-2);
  line-height: var(--lh-body);
}

pre {
  padding: var(--sp-3);
  background: var(--c-ghost);
  overflow-x: auto;
  border-left: 2px solid var(--c-rule);
}

code {
  padding: 0.1em 0.3em;
  background: var(--c-ghost);
}

pre code {
  padding: 0;
  background: none;
}

/* ── Blockquote ── */

blockquote {
  padding-left: var(--sp-3);
  border-left: 2px solid var(--c-rule);
  color: var(--c-dim);
}

/* ── Lists (when styled) ── */

.prose ul,
.prose ol {
  padding-left: var(--sp-3);
}

.prose ul { list-style-type: "– "; }
.prose ol { list-style-type: decimal; }

.prose li + li {
  margin-top: var(--sp-1);
}

/* ── Horizontal rule ── */

hr {
  border: none;
  border-top: 1px solid var(--c-rule);
  margin-block: var(--sp-6);
}

/* ── Utility classes ── */

.text-mono {
  font-family: var(--ff-mono);
  font-size: var(--fs-2);
  letter-spacing: var(--ls-meta);
}

.text-meta {
  font-family: var(--ff-sans);
  font-size: var(--fs-3);
  letter-spacing: var(--ls-meta);
  color: var(--c-dim);
}

.text-display {
  font-size: var(--fs-vw-title);
  line-height: var(--lh-display);
  letter-spacing: var(--ls-tight);
  font-weight: 700;
}

.text-dim {
  color: var(--c-dim);
}

.text-accent {
  color: var(--c-accent);
}

/* Type-color utilities */
.text-stu { color: var(--c-stu); }
.text-pro { color: var(--c-pro); }
.text-dic { color: var(--c-dic); }
.text-dsp { color: var(--c-dsp); }