/* Rubik variable, self-hosted. No third-party font request. */
@font-face {
  font-family: 'Rubik'; font-style: normal; font-weight: 300 900; font-display: swap;
  src: url('/assets/fonts/rubik-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: 'Rubik'; font-style: normal; font-weight: 300 900; font-display: swap;
  src: url('/assets/fonts/rubik-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: 'Rubik'; font-style: normal; font-weight: 300 900; font-display: swap;
  src: url('/assets/fonts/rubik-cyrillic.woff2') format('woff2');
  unicode-range: U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116;
}
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --ink: #000000;
  --paper: #FFFFFF;
  --muted: #5C5C5C;
  --line: #E2E2E2;
  --soft: #F3F3F3;
  --font: 'Rubik', ui-rounded, 'Segoe UI', system-ui, Helvetica, Arial, sans-serif;
  --wrap: 1120px;
  --measure: 66ch;
  --pill: 999px;
  --panel: 32px;
}

/* One inversion mechanism for everything black: swap the tokens. */
.invert, .row:hover, .row:focus-within {
  --ink: #FFFFFF;
  --paper: #000000;
  --muted: #BDBDBD;
  --line: #3A3A3A;
  --soft: #1C1C1C;
}

html { font-size: 100%; scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main { flex: 1; outline: none; }

a { color: inherit; }

h1, h2, h3 { font-weight: 600; letter-spacing: -0.025em; line-height: 1.12; }

:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; border-radius: 6px; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: 1.5rem; }

.skip {
  position: absolute; left: 1rem; top: -4rem; z-index: 200;
  background: #000; color: #fff; padding: .6rem 1rem; border-radius: var(--pill);
}
.skip:focus { top: 1rem; }

/* ---------- Header ---------- */
.top {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,.94);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.top__in {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: .5rem 1.5rem; padding-block: .85rem;
}
.mark {
  display: inline-flex; align-items: center; gap: .55rem;
  font-weight: 700; font-size: 1.125rem; letter-spacing: -0.03em; text-decoration: none;
}
.mark__dot { width: .9rem; height: .9rem; border-radius: 50%; background: var(--ink); }
.nav { display: flex; align-items: center; flex-wrap: wrap; gap: .25rem; }
.nav__link {
  text-decoration: none; font-weight: 500; font-size: .9375rem;
  padding: .45rem .95rem; border-radius: var(--pill);
}
.nav__link:hover { background: var(--soft); }
.nav__link[aria-current="page"] { background: var(--ink); color: var(--paper); }
.nav .btn { margin-left: .5rem; }

/* ---------- Buttons and pills ---------- */
.btn {
  display: inline-block; text-decoration: none; font: inherit; font-weight: 500; cursor: pointer;
  background: var(--ink); color: var(--paper);
  border: 1.5px solid var(--ink); border-radius: var(--pill);
  padding: .85rem 1.7rem; transition: background .15s, color .15s;
}
.btn:hover { background: var(--paper); color: var(--ink); }
.btn--ghost { background: transparent; color: var(--ink); }
.btn--ghost:hover { background: var(--ink); color: var(--paper); }
.btn--sm { padding: .45rem 1.05rem; font-size: .9375rem; }
.actions { display: flex; flex-wrap: wrap; gap: .75rem; }

.tags { list-style: none; display: flex; flex-wrap: wrap; gap: .4rem; }
.tag {
  display: inline-flex; align-items: baseline; gap: .4rem;
  text-decoration: none; font-size: .8125rem; font-weight: 500; line-height: 1.2;
  padding: .32rem .75rem; border: 1.5px solid var(--ink); border-radius: var(--pill);
  color: var(--ink); transition: background .15s, color .15s;
}
.tag:hover, .tag[aria-current="true"] { background: var(--ink); color: var(--paper); }
.tag__n { font-weight: 400; opacity: .65; }
.tags--lg .tag { font-size: 1rem; padding: .5rem 1.1rem; }

/* ---------- Page heads ---------- */
.hero { padding-block: clamp(3.5rem, 9vw, 7.5rem) clamp(2.5rem, 6vw, 5rem); }
.hero h1 {
  font-size: clamp(2.75rem, 7.6vw, 6.25rem);
  letter-spacing: -0.04em; line-height: .98; max-width: 13ch;
}
.lede { font-size: clamp(1.125rem, 1.9vw, 1.375rem); line-height: 1.5; color: var(--muted); max-width: 46ch; }
.hero .lede { margin-block: 2rem 2.5rem; }

.head { padding-block: clamp(3rem, 7vw, 5.5rem) clamp(1.75rem, 4vw, 3rem); }
.head h1 { font-size: clamp(2.4rem, 5.6vw, 4.25rem); letter-spacing: -0.035em; line-height: 1.02; max-width: 18ch; }
.head .lede { margin-top: 1.5rem; }

.crumbs { font-size: .9375rem; color: var(--muted); margin-bottom: 1.25rem; }
.crumbs a { text-underline-offset: 3px; }

.block { padding-block: clamp(2.5rem, 6vw, 4.5rem); }
.block__head { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 1rem; margin-bottom: 1.5rem; }
.block__head h2 { font-size: clamp(1.6rem, 3.2vw, 2.25rem); }
.more { font-weight: 500; text-underline-offset: 4px; }

/* ---------- Rows: the list pattern for analyses and offers ---------- */
.rows { list-style: none; border-bottom: 1px solid var(--line); }
.row {
  position: relative; display: grid; grid-template-columns: 7.5rem 1fr auto;
  gap: .5rem 1.75rem; align-items: baseline;
  padding: 1.5rem 1.25rem; margin-inline: -1.25rem;
  border-top: 1px solid var(--line);
  background: var(--paper); color: var(--ink);
  transition: background .15s, color .15s, border-radius .15s;
}
.row:hover, .row:focus-within { border-radius: 20px; border-top-color: transparent; }
.row:hover + .row, .row:focus-within + .row { border-top-color: transparent; }
.row__date { font-size: .9375rem; color: var(--muted); white-space: nowrap; }
.row__title { font-size: clamp(1.2rem, 2.1vw, 1.5rem); font-weight: 500; letter-spacing: -0.02em; line-height: 1.2; }
.row__link { text-decoration: none; }
.row__link::after { content: ''; position: absolute; inset: 0; border-radius: inherit; }
.row__link:focus-visible { outline: none; }
.row:focus-within { outline: 3px solid var(--paper); outline-offset: 3px; }
.invert .row:hover, .invert .row:focus-within {
  --ink: #000000; --paper: #FFFFFF; --muted: #5C5C5C; --line: #E2E2E2; --soft: #F3F3F3;
}
.row__excerpt { color: var(--muted); margin-top: .4rem; max-width: 60ch; font-size: 1rem; }
.row__tags { position: relative; z-index: 1; justify-content: flex-end; max-width: 15rem; }
.row__meta { font-size: .9375rem; color: var(--muted); white-space: nowrap; }

.row--offer { grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr) 8.5rem; padding-block: 2rem; }
.row--offer .row__meta { text-align: right; white-space: normal; }
.row--offer .row__title { font-size: clamp(1.4rem, 2.6vw, 1.9rem); font-weight: 600; }
.row--offer .row__excerpt { margin-top: 0; }
.row--situation { grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr) minmax(0, .75fr); }
.row--situation .row__meta { white-space: normal; }

.empty { padding: 2rem 0; color: var(--muted); }

/* ---------- Black panel ---------- */
.panel {
  background: var(--paper); color: var(--ink);
  border-radius: var(--panel); padding: clamp(2rem, 5vw, 4.5rem);
}
.panel h2 { font-size: clamp(1.9rem, 4.4vw, 3.25rem); letter-spacing: -0.035em; max-width: 18ch; }
.panel .lede { margin-block: 1.25rem 2.25rem; }
.panel .rows { margin-top: 2.5rem; }
.panel--soft { background: var(--soft); }
.panel--soft h2 { font-size: clamp(1.4rem, 2.6vw, 1.9rem); letter-spacing: -0.025em; max-width: 26ch; }

/* ---------- Article ---------- */
.article__meta { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1.5rem; margin-top: 1.75rem; color: var(--muted); font-size: .9375rem; }
.prose { max-width: var(--measure); font-size: 1.125rem; line-height: 1.7; }
.prose > * + * { margin-top: 1.4rem; }
.prose h2 { font-size: 1.65rem; margin-top: 3rem; }
.prose ul { padding-left: 1.25rem; }
.prose li + li { margin-top: .5rem; }
.prose li::marker { color: var(--ink); }
.prose blockquote {
  font-size: clamp(1.35rem, 2.6vw, 1.75rem); font-weight: 500; line-height: 1.3; letter-spacing: -0.02em;
  padding-left: 1.5rem; border-left: 6px solid var(--ink); margin-block: 2.5rem;
}
.prose a { text-underline-offset: 3px; }

/* ---------- Offer details ---------- */
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 0 2rem; border-top: 2px solid var(--ink); }
.facts div { padding-block: 1.1rem; border-bottom: 1px solid var(--line); }
.facts dt { font-size: .9375rem; color: var(--muted); }
.facts dd { font-size: 1.2rem; font-weight: 500; letter-spacing: -0.015em; }

.steps { list-style: none; counter-reset: s; display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 2.25rem 2rem; }
.steps li { counter-increment: s; }
.steps li::before {
  content: counter(s); display: grid; place-items: center;
  width: 3rem; height: 3rem; border-radius: 50%;
  background: var(--ink); color: var(--paper); font-weight: 600; font-size: 1.125rem; margin-bottom: 1.1rem;
}
.steps h3 { font-size: 1.2rem; margin-bottom: .4rem; }
.steps p { color: var(--muted); font-size: 1rem; }

.gets { list-style: none; columns: 2 280px; column-gap: 3rem; }
.gets li { break-inside: avoid; padding: .9rem 0 .9rem 2rem; border-bottom: 1px solid var(--line); position: relative; }
.gets li::before { content: ''; position: absolute; left: 0; top: 1.45rem; width: .75rem; height: .75rem; border-radius: 50%; background: var(--ink); }

.faq details { border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 1.5rem;
  padding-block: 1.35rem; font-size: 1.2rem; font-weight: 500; letter-spacing: -0.015em;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; font-size: 1.75rem; font-weight: 400; line-height: 1; transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { color: var(--muted); max-width: var(--measure); padding-bottom: 1.5rem; }

.pager { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 1rem; border-top: 1px solid var(--line); padding-top: 1.5rem; }
.pager a { font-weight: 500; text-underline-offset: 4px; }
.pager span { display: block; font-size: .875rem; font-weight: 400; color: var(--muted); }

.about { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 2rem 4rem; }
.about h2 { font-size: 1.5rem; }
.about p.role { color: var(--muted); margin-top: .35rem; }
.about__photo { width: 100%; height: auto; border-radius: 24px; margin-bottom: 1.5rem; filter: grayscale(100%) contrast(1.05); }

/* ---------- Footer ---------- */
.foot { border-top: 1px solid var(--line); margin-top: clamp(3rem, 7vw, 6rem); padding-block: 3rem; font-size: .9375rem; }
.foot__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 2rem; }
.foot h2 { font-size: .9375rem; font-weight: 500; letter-spacing: 0; color: var(--muted); margin-bottom: .75rem; }
.foot ul { list-style: none; }
.foot li + li { margin-top: .35rem; }
.foot a { text-decoration: none; }
.foot a:hover { text-decoration: underline; text-underline-offset: 3px; }
.foot__legal { margin-top: 2.5rem; color: var(--muted); font-size: .875rem; }

/* ---------- Small screens ---------- */
@media (max-width: 760px) {
  .row, .row--offer, .row--situation { grid-template-columns: 1fr; }
  .row__tags { justify-content: flex-start; max-width: none; margin-top: .5rem; }
  .row--offer .row__meta { text-align: left; }
  .about { grid-template-columns: 1fr; }
  .nav .btn { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}

/* ---------- Utilities ---------- */
.block--flush { padding-top: 0; }
.mt-2 { margin-top: 2rem; }
.mb-2 { margin-bottom: 2rem; }
.ink { color: var(--ink); }
.foot__blurb { margin-top: .75rem; color: var(--muted); max-width: 28ch; }
.pager__next { text-align: right; margin-left: auto; }
.prose img { max-width: 100%; height: auto; border-radius: 12px; }
.prose pre { overflow-x: auto; padding: 1rem 1.25rem; background: var(--soft); border-radius: 12px; font-size: .9375rem; }
.nav__link--lang { border: 1.5px solid var(--line); margin-left: .25rem; font-size: .8125rem; padding: .35rem .7rem; }
.nav__link--lang:hover { border-color: var(--ink); }
