/* Taller Torrents — base layer */
@font-face {
  font-family: "DM Mono"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("../fonts/dm-mono-400.woff2") format("woff2");
}
@font-face {
  font-family: "DM Mono"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("../fonts/dm-mono-500.woff2") format("woff2");
}
/* Self-hosted Helvetica Neue (Latin subset) — Roman→400, Bold→700.
   Named "Helvetica Neue" so --font-grotesque resolves to these files on every OS,
   instead of falling back to Arial off-Mac. */
@font-face {
  font-family: "Helvetica Neue"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("../fonts/helvetica-neue-400.woff2") format("woff2");
}
@font-face {
  font-family: "Helvetica Neue"; font-style: normal; font-weight: 700; font-display: swap;
  src: url("../fonts/helvetica-neue-700.woff2") format("woff2");
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-mono);
  font-size: var(--fz-body);
  line-height: 1.35;
  letter-spacing: 0;
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
  transition: background-color var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease);
}
img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
:where(h1, h2, h3, h4, h5, h6, p, li, figcaption, a, button, span) {
  min-width: 0;
  overflow-wrap: anywhere;
}
:focus-visible { outline: 2px solid var(--fg); outline-offset: 2px; }

/* Family utilities */
.u-grotesque { font-family: var(--font-grotesque); }
.u-mono { font-family: var(--font-mono); }

/* Layout primitives */
.l-container { width: 100%; padding-inline: var(--gutter); }
.l-grid {
  display: grid;
  grid-template-columns: repeat(var(--grid-cols), 1fr);
  gap: var(--grid-gap);
}
@media (max-width: 1199px) { .l-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 767px)  { .l-grid { grid-template-columns: repeat(2, 1fr); } }

/* Lenis smooth scroll (only applied while Lenis is running; classes added to <html>) */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-stopped { overflow: hidden; }
.lenis.lenis-smooth iframe { pointer-events: none; }

/* Scrollbars — themed, transparent track, hover-reveal thumb.
   scrollbar-color is inherited, so setting it on html cascades to every
   scrolling box (the page itself, .about-page__column, anything future)
   without per-element rules; the bare ::-webkit-scrollbar selectors do the
   same for Chrome/Edge/Safari, which don't support scrollbar-color. */
html {
  scrollbar-width: thin;
  scrollbar-color: transparent transparent;
}
html:hover, html:focus-within {
  scrollbar-color: color-mix(in srgb, var(--fg) 35%, transparent) transparent;
}
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  background-color: transparent;
  border: 2px solid transparent;
  background-clip: padding-box;
  border-radius: 999px;
  transition: background-color var(--dur-fast) var(--ease);
}
:hover::-webkit-scrollbar-thumb, :focus-within::-webkit-scrollbar-thumb {
  background-color: color-mix(in srgb, var(--fg) 35%, transparent);
}
::-webkit-scrollbar-thumb:active {
  background-color: color-mix(in srgb, var(--fg) 50%, transparent);
}
