/* ==========================================================================
   Marvus Advisory — reset, self-hosted fonts, base typography, utilities
   ========================================================================== */

/* ---------- Fonts. Self-hosted, no external requests. --------------------- */
@font-face {
  font-family: "Golos Text";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("../fonts/golos-text-500-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Golos Text";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("../fonts/golos-text-500-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Cyrillic is shipped ahead of the RU stage; unicode-range keeps it unloaded
   on the English site. */
@font-face {
  font-family: "Golos Text";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("../fonts/golos-text-500-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

@font-face {
  font-family: "Liter";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/liter-400-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Liter";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/liter-400-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Liter";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/liter-400-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 96px;
}

body,
h1, h2, h3, h4, h5, h6,
p, figure, blockquote, dl, dd, ul, ol {
  margin: 0;
}

ul[class], ol[class] { list-style: none; padding: 0; }

body {
  min-height: 100vh;
  background-color: var(--c-white);
  color: var(--c-blue);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

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

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

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

table { border-collapse: collapse; width: 100%; }

/* ---------- Headings ------------------------------------------------------ */
h1, h2, h3, h4, h5, h6, .u-display {
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: 0;
  text-wrap: balance;
}

h1, .u-h1 {
  font-size: var(--fs-display);
  line-height: var(--lh-display);
  /* 0.9 leading clips descenders on some engines — reserve the space back. */
  padding-block-end: 0.06em;
}
h2, .u-h2 {
  font-size: var(--fs-h2);
  line-height: var(--lh-display);
  padding-block-end: 0.06em;
}
h3, .u-h3 { font-size: var(--fs-h3); line-height: var(--lh-heading); }
h4, .u-h4 { font-size: var(--fs-h4); line-height: var(--lh-heading); }

p { max-width: var(--measure); }

a { color: inherit; }

strong, b { font-weight: 400; font-family: var(--font-display); }

/* ---------- Type utilities ------------------------------------------------ */
.u-lead {
  font-size: var(--fs-lead);
  line-height: var(--lh-body);
  color: var(--ink-muted);
}
.u-small { font-size: var(--fs-small); }

.u-caption,
.u-label {
  font-family: var(--font-display);
  font-size: var(--fs-caption);
  line-height: 1.2;
  letter-spacing: var(--ls-caption);
  text-transform: uppercase;
}

.u-muted { color: var(--ink-muted); }
.u-faint { color: var(--ink-faint); }
.u-accent { color: var(--c-orange); }
.u-measure-narrow { max-width: 46ch; }
.u-nowrap { white-space: nowrap; }

/* ---------- Accessibility helpers ---------------------------------------- */
.u-visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  inset-block-start: 0;
  inset-inline-start: 0;
  z-index: 200;
  transform: translateY(-120%);
  padding: var(--s-2) var(--s-3);
  background: var(--c-orange);
  color: var(--c-blue);
  font-family: var(--font-display);
  font-size: var(--fs-small);
  transition: transform var(--dur) var(--ease);
}
.skip-link:focus { transform: translateY(0); }

/* Focus ring: orange for brand, with a dark outer edge so the ring itself
   clears 3:1 against white surfaces. */
:focus-visible {
  outline: 3px solid var(--c-orange);
  outline-offset: 2px;
  box-shadow: 0 0 0 1px var(--c-blue);
}
.is-dark :focus-visible,
.is-dark:focus-visible {
  box-shadow: 0 0 0 1px var(--c-white);
}
:focus:not(:focus-visible) { outline: none; }

/* ---------- Scroll reveal ------------------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity var(--dur-slow) var(--ease), transform var(--dur-slow) var(--ease);
  transition-delay: var(--reveal-delay, 0ms);
}
.reveal.is-visible { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .reveal { opacity: 1; transform: none; }
}

::selection { background: var(--c-orange); color: var(--c-blue); }
