@font-face {
  font-family: 'Ubuntu Sans';
  src: url('/fonts/UbuntuSans-V.woff2') format('woff2');
  font-weight: 100 800;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'JetBrains Mono';
  src: url('/fonts/JetBrainsMono.woff2') format('woff2');
  font-weight: 100 800;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Ubuntu';
  src: url('/fonts/Ubuntu.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}


/* ---------- Reset ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

* {
  margin: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  color: var(--fg);
  background: var(--bg);
  min-height: 100dvh;
  overflow-x: clip;
  font-feature-settings: "ss01" on, "cv11" on;
  transition: background-color .35s var(--ease-out), color .35s var(--ease-out);
}

img,
svg,
video,
canvas {
  display: block;
  max-width: 100%;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

/* ---------- Typography scale ---------- */
.eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.08;
  text-wrap: balance;
}

/* Keep brand/logo always using Sansation */
.brand-name {
  font-family: var(--font-sans);
}

h1 {
  font-size: clamp(38px, 6.4vw, 76px);
  letter-spacing: -0.035em;
}

h2 {
  font-size: clamp(30px, 3.5vw, 52px);
  letter-spacing: -0.03em;
}

h3 {
  font-size: clamp(22px, 2.2vw, 30px);
}

h4 {
  font-size: clamp(17px, 1.4vw, 20px);
}

p,
li {
  text-wrap: pretty;
}

.lead {
  font-size: clamp(17px, 1.4vw, 21px);
  color: var(--fg-muted);
  line-height: 1.55;
  max-width: 60ch;
}

.mono {
  font-family: var(--font-mono);
  font-feature-settings: "calt" on;
}

::selection {
  background: var(--accent);
  color: #0a1226;
}

/* Lang-specific tweaks: Cyrillic at 700 in Sansation can run wide */
:root[lang="ru"] h1 {
  letter-spacing: -0.025em;
}