/*
Theme Name: DEVRENT
Description: Аренда аккаунтов Apple Developer и Google Play. Тема на дизайн-системе Modernist.
Version: 1.0
Text Domain: devrent
*/

/* ============ 1. Дизайн-система Modernist (токены + компоненты) ============ */
/* Modernist — design-system tokens and component classes. This file is the source of truth for the system's look; retune it here and see readme.md. */
@import url('https://fonts.googleapis.com/css2?family=Archivo:wght@400;600;800&display=swap');

:root {
  --color-bg: #f3f2f2;
  --color-surface: #eae9e9;
  --color-text: #201e1d;
  --color-accent: #ec3013;
  --color-accent-2: #e15b47;
  --color-divider: color-mix(in srgb, #201e1d 40%, transparent);

  /* Tonal ramps — generated in OKLCH on one shared lightness scale, so the
     same step of any role matches the others in visual value. */
  --color-neutral-100: #f8f4f4;
  --color-neutral-200: #eae7e7;
  --color-neutral-300: #d7d3d3;
  --color-neutral-400: #bab6b6;
  --color-neutral-500: #9b9797;
  --color-neutral-600: #7d7979;
  --color-neutral-700: #605d5d;
  --color-neutral-800: #444141;
  --color-neutral-900: #2d2b2b;

  --color-accent-100: #fff2ef;
  --color-accent-200: #ffe0d9;
  --color-accent-300: #ffc4b8;
  --color-accent-400: #ff9783;
  --color-accent-500: #ff563c;
  --color-accent-600: #dd2b0f;
  --color-accent-700: #ae1800;
  --color-accent-800: #7c1405;
  --color-accent-900: #4d170e;

  --color-accent-2-100: #fff2ef;
  --color-accent-2-200: #ffe0da;
  --color-accent-2-300: #ffc4b9;
  --color-accent-2-400: #ff9784;
  --color-accent-2-500: #ef6853;
  --color-accent-2-600: #c94b39;
  --color-accent-2-700: #9e3526;
  --color-accent-2-800: #71261b;
  --color-accent-2-900: #471d16;

  --font-heading: "Archivo", system-ui, sans-serif;
  --font-heading-weight: 800;
  --font-body: "Archivo", system-ui, sans-serif;

  --space-1: 4.0px;
  --space-2: 8.0px;
  --space-3: 12.0px;
  --space-4: 16.0px;
  --space-6: 24.0px;
  --space-8: 32.0px;

  --radius-sm: 0px;
  --radius-md: 0px;
  --radius-lg: 0px;

  /* Elevation — derived from the ground: soft ink-tinted shadows on a
     light theme, a hairline edge + ambient darkness on a dark one. */
  --shadow-sm: 0 1px 2px color-mix(in srgb, #2d2b2b 14%, transparent);
  --shadow-md: 0 3px 10px color-mix(in srgb, #2d2b2b 16%, transparent);
  --shadow-lg: 0 12px 32px color-mix(in srgb, #2d2b2b 22%, transparent);
}

body {
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
}
h1, h2, h3, h4 { font-family: var(--font-heading); font-weight: var(--font-heading-weight); }

.grayscale{filter:grayscale(1) contrast(1.08)}

/* ══════════════════════════════════════════════════════════════════════════
   Components — built with the tokens above. Plain CSS
   on plain HTML: no JavaScript, no build step. Each class is documented in
   readme.md and demonstrated in foundations/ and components/.
   ══════════════════════════════════════════════════════════════════════ */

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; font-size: 15px; line-height: 1.55; font-weight: 400; }
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  line-height: 1.12; letter-spacing: -0.015em; margin: 0 0 var(--space-2);
}
h1 { font-size: 42px; }
h2 { font-size: 32px; }
h3 { font-size: 25px; }
h4 { font-size: 20px; }
h5 { font-size: 16px; }
h6 { font-size: 13px; }
h6 { letter-spacing: 0.08em; text-transform: uppercase; }
p { margin: 0 0 var(--space-3); }
a { color: var(--color-accent); text-underline-offset: 3px; }
img { display: block; max-width: 100%; }
figure { margin: 0; }
figcaption {
  font-size: 11px; margin-top: var(--space-1);
  color: color-mix(in srgb, var(--color-text) 55%, transparent);
}
.text-muted { color: color-mix(in srgb, var(--color-text) 55%, transparent); }
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 2px; }
::selection { background: color-mix(in srgb, var(--color-accent) 30%, transparent); }

/* — rules — */
.hr {
  height: 2px; border: 0; margin: var(--space-4) 0;
  background: var(--color-divider);
}

/* — buttons — */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  cursor: pointer; text-decoration: none;
  font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: 14px; line-height: 1.2; color: var(--color-text); /* matches the .input's 14px —
     the pair sits side by side in sign-up rows */
  background: transparent; border: 1px solid transparent;
  padding: var(--space-2) calc(var(--space-3) * 1.2);
  border-radius: var(--radius-md);
}
.btn svg { display: block; }
.btn:disabled { opacity: 0.45; cursor: not-allowed; }
.btn-primary { background: var(--color-accent); color: var(--color-bg); }
.btn-primary:hover { background: var(--color-accent-600); }
.btn-primary:active { background: var(--color-accent-700); }
.btn-secondary { border-color: var(--color-divider); }
.btn-secondary:hover { background: color-mix(in srgb, var(--color-text) 7%, transparent); }
.btn-secondary:active { background: color-mix(in srgb, var(--color-text) 14%, transparent); }
.btn-ghost { color: var(--color-accent); padding-inline: var(--space-1); }
.btn-ghost:hover { background: color-mix(in srgb, var(--color-accent) 10%, transparent); }
.btn-ghost:active { background: color-mix(in srgb, var(--color-accent) 18%, transparent); }
.btn-icon { width: 36px; height: 36px; padding: 0; }
.btn-block { width: 100%; margin-top: var(--space-2); justify-content: flex-start; text-align: left; }

/* — forms — */
.field > label {
  display: block; font-size: 12px; margin-bottom: 5px;
  color: color-mix(in srgb, var(--color-text) 70%, transparent);
}
.input {
  width: 100%; min-height: 36px; padding: 6px 10px; font: inherit;
  font-size: 14px; color: var(--color-text); caret-color: var(--color-accent);
  background: var(--color-surface);
  border: 1px solid var(--color-divider); border-radius: var(--radius-md);
}
.input:hover { border-color: color-mix(in srgb, var(--color-text) 45%, transparent); }
.input:focus-visible { border-color: var(--color-accent); outline-offset: 0; }
textarea.input { min-height: 90px; resize: vertical; }
.radio { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-size: 14px; }
.radio input, .seg-opt input {
  position: absolute; opacity: 0; width: 0; height: 0; pointer-events: none;
}
.radio .dot {
  width: 16px; height: 16px; flex: none; border-radius: 50%;
  border: 1.5px solid var(--color-divider);
}
.radio:hover .dot { border-color: var(--color-accent); }
.radio input:checked + .dot {
  border-color: var(--color-accent); background: var(--color-accent);
  box-shadow: inset 0 0 0 4px var(--color-bg);
}
.radio input:focus-visible + .dot { outline: 2px solid var(--color-accent); outline-offset: 2px; }
.seg {
  display: inline-flex; overflow: hidden;
  border: 1px solid var(--color-divider); border-radius: var(--radius-md);
}
.seg-opt {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 12px; font-size: 13px; cursor: pointer;
}
.seg-opt + .seg-opt { border-left: 1px solid var(--color-divider); }
.seg-opt:has(input:checked) { background: var(--color-accent); color: var(--color-bg); }
.seg-opt:not(:has(input:checked)):hover { background: color-mix(in srgb, var(--color-text) 7%, transparent); }
.seg-opt:has(input:focus-visible) { outline: 2px solid var(--color-accent); outline-offset: -2px; }

/* — cards — */
.card {
  display: flex; flex-direction: column; gap: var(--space-2);
  padding: var(--space-3); border-radius: var(--radius-md); background: var(--color-surface);
}
.card-kicker { font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--color-accent); }
.card-title {
  font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: 17px; line-height: 1.2;
}
.card-body { margin: 0; font-size: 13px; opacity: 0.8; flex: 1; }
.card-meta {
  display: flex; align-items: center; gap: 6px; font-size: 11px;
  color: color-mix(in srgb, var(--color-text) 50%, transparent);
}
.elev-sm { box-shadow: var(--shadow-sm); }
.elev-md { box-shadow: var(--shadow-md); }
.elev-lg { box-shadow: var(--shadow-lg); }

/* — tags — */
.tag {
  display: inline-flex; align-items: center; font-size: 11px;
  letter-spacing: 0.02em; padding: 3px 10px;
  border-radius: calc(var(--radius-md) * 0.75);
}
.tag-accent { background: var(--color-accent-100); color: var(--color-accent-800); }
.tag-accent-2 { background: var(--color-accent-2-100); color: var(--color-accent-2-800); }
.tag-neutral { background: var(--color-neutral-100); color: var(--color-neutral-800); }
.tag-outline { border: 1px solid var(--color-accent); color: var(--color-accent); }

/* — navigation — */
.nav {
  display: flex; align-items: center; gap: var(--space-4);
  padding: var(--space-3) var(--space-4);
  border-bottom: 2px solid var(--color-divider);
}
.nav-brand {
  font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: 18px; margin-right: auto;
}
.nav a { color: inherit; text-decoration: none; font-size: 14px; }
.nav a:hover, .nav a[aria-current='page'] { color: var(--color-accent); }

/* — tables — */
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th {
  text-align: left; font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase;
  color: color-mix(in srgb, var(--color-text) 60%, transparent);
  padding: var(--space-2); border-bottom: 2px solid var(--color-divider);
}
.table td {
  padding: var(--space-2);
  border-bottom: 1px solid var(--color-divider);
}
.table tbody tr:hover { background: color-mix(in srgb, var(--color-text) 4%, transparent); }

/* — dialog — */
.dialog-backdrop {
  position: fixed; inset: 0; display: grid; place-items: center;
  padding: var(--space-4);
  background: color-mix(in srgb, var(--color-neutral-900) 50%, transparent);
}
.dialog {
  width: min(440px, 100%); display: flex; flex-direction: column; gap: var(--space-3);
  padding: var(--space-4); border-radius: var(--radius-lg);
  background: var(--color-surface); box-shadow: var(--shadow-lg);
}
.dialog-title {
  font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: 20px;
}
.dialog-body { font-size: 14px; opacity: 0.85; }
.dialog-actions { display: flex; justify-content: flex-end; gap: var(--space-2); margin-top: var(--space-2); }



/* ============ 2. Лендинг ============ */

/* Template scaffolding — page layout and web-scale sizing only; every color,
   font, radius and shadow comes from ../../styles.css. The voice is the
   deck's, re-derived for a scrolling page: the grid SHOWS — 2px
   rules draw the structure — red is spent as a mark, and its one field
   moment is the poster close (the deck's divider logic: the red page sets
   nothing small).

   THE RHYTHM: a 28px leading unit (17px Archivo body at ~1.65), 14px
   half-step; line-heights and block margins in unit multiples, heads
   cap-trimmed, ?baselines/B to review. The deck's seat-pinning relaxes to
   per-block discipline on a fluid page. The system's own interface
   components (nav, buttons, inputs) keep their styles.css leading — the
   rhythm governs the page's text, not the controls.

   THE LANDING LAWS (shared by all six systems' landing templates):
   #1 display headers break per sentence (.line spans); #2 the landing
   advertises an invented product played straight — modernist's is Takt,
   timetables that run like Switzerland; #3 spacing is cluster-scoped
   (display leading ratio-governed ≈1.06 for Archivo's tight caps — the
   display-block lattice exemption — tight single-unit gaps inside a text
   cluster, the air between sections); #4 no hero eyebrow — the nav brand
   names the product.

   Optical left alignment: the deck's measured Archivo 800 value carries
   verbatim (-0.058em where caps lead a display line; em-scaled). */
:root {
  --leading: 28px;
  --half: 14px;
  --edge: clamp(20px, 5vw, 72px);
  --measure: 58ch;
}
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; text-wrap: pretty; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 var(--edge); }
/* the component demo pads the masthead with its own spacing; on the page the
   masthead's contents take the page gutter and sit on the wrap's text axis
   (padding-only — full-width paint such as a masthead rule is untouched) */
.nav { padding-inline: max(var(--edge), calc((100% - 1200px) / 2 + var(--edge))); }
.nav a { white-space: nowrap; }
.nav a[aria-current='location'] { color: var(--color-accent); } /* in-page anchor, not
   a page link — 'location' is the truthful value; carry the component's active ink */
@media (max-width: 480px) { .nav a { display: none; } } /* phone width: the nav
   keeps brand + the one action (layout-only — the component's look is
   untouched); the full link row's min-content crosses narrow-phone widths */

/* — drawn structure: the 2px rule is the section seam (the deck's header
   band as page grammar; rules span the content column, solid — this system
   does not fade its rules) — */
.rule2 { height: 2px; border: 0; margin: 0; background: var(--color-divider); }

/* — kicker (deck grammar: uppercase, tabular, accent; no hanging dash —
   modernist marks are squares, and they belong to lists, not labels) — */
.kicker {
  display: block; font-size: 13px; line-height: var(--half);
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--color-accent-700); /* accent-colored SMALL text takes the deep step —
     6.4:1, where the base accent measures 3.8:1 (a large-text value; the
     deck's kickers are 24px, this one is 13px) */
  font-feature-settings: "tnum" 1;
  margin: 0 0 calc(var(--leading) - var(--half));
}

/* — hero — */
.hero { padding: calc(4 * var(--leading)) 0 calc(3 * var(--leading)); }
.display {
  font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: clamp(42px, 6.2vw, 84px);
  line-height: clamp(44.5px, 6.57vw, 89px); /* law #3: ratio-governed ≈1.06 —
     Archivo's 800 sits tight and all-cap-height; the display-block lattice
     exemption (no 14px step is both tighter than the old look and clear) */
  letter-spacing: -0.02em; margin: 0;
  margin-left: -0.058em; /* optical left alignment — the deck's measured Archivo 800 value */
  text-box: trim-both cap alphabetic;
}
.display .line { display: block; } /* law #1: one sentence per line */
.hero .sub { font-size: 17px; line-height: var(--leading); max-width: var(--measure);
  margin: calc(1.5 * var(--leading) - 1cap) 0 0;
  text-box: trim-both cap alphabetic; } /* 1.5 units: clears the display's descenders with cluster-tight air (law #3) */
.hero .row { display: flex; gap: var(--space-3); flex-wrap: wrap; margin-top: var(--leading); }

/* — stat row (in-grammar: red stays a MARK on the light ground — the stat
   numerals take the accent at display size, ≥3:1 as large text per the
   system's own accent rule; the red FIELD is reserved for the close) — */
.stats { padding: calc(2.5 * var(--leading)) 0; }
.stats .grid { display: grid; grid-template-columns: repeat(4, auto); justify-content: space-between; gap: calc(1.5 * var(--leading)) var(--leading); }
.stat-num { font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: clamp(34px, 3.4vw, 48px); line-height: calc(2 * var(--leading));
  color: var(--color-accent); /* display figures stay proportional — the deck's figure policy */
  margin: 0; margin-left: -0.045em; /* digits lead — the deck's "0"-population value */
  text-box: trim-both cap alphabetic; }
.stat-label { font-size: 13px; line-height: var(--half); letter-spacing: 0.08em; text-transform: uppercase;
  color: color-mix(in srgb, var(--color-text) 70%, transparent); /* small-text ink on the
     light ground: 70% measures 5.8:1 (the deck's 55% furniture mix is a
     24px large-text convention — at 13px the 4.5:1 bar applies, and 55%
     measures only 3.7:1 here) */
  margin: var(--half) 0 0; }

/* — feature rows (the deck's ruled-toc grammar: 2px rules ON the seams,
   red square marks hanging at the numbers — drawn structure, no cards) — */
.features { padding: calc(3 * var(--leading)) 0 calc(2.5 * var(--leading)); }
.feature { display: grid; grid-template-columns: minmax(64px, 160px) minmax(0, 420px) minmax(0, 1fr);
  gap: var(--leading) clamp(24px, 4vw, 72px); align-items: baseline;
  padding: calc(1.5 * var(--leading)) 0; }
.feature + .feature { border-top: 2px solid var(--color-divider); } /* the ruled seam — solid, the system's weight */
.f-num { position: relative; font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: 15px; line-height: var(--leading); color: var(--color-text);
  font-feature-settings: "tnum" 1; margin: 0; text-box: trim-both cap alphabetic; }
.f-num::before { content: ""; position: absolute; left: -24px; top: calc(0.5cap - 5px);
  width: 10px; height: 10px; background: var(--color-accent); } /* the deck's 10px red square,
     hanging left of the number's axis — at narrow widths the gutter folds it away */
@media (max-width: 1280px) { .f-num::before { display: none; } }
.f-title { font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: 24px; line-height: var(--leading); letter-spacing: -0.01em;
  margin: 0; text-box: trim-both cap alphabetic; }
.f-copy { font-size: 15.5px; line-height: var(--leading); margin: 0;
  color: color-mix(in srgb, var(--color-text) 78%, transparent);
  max-width: 52ch; text-box: trim-both cap alphabetic; }

/* — imagery split (grayscale photograph — the system prints in black and
   white; the box pins the bundled asset's 951×665 ratio so swaps
   cover-crop into the same frame) — */
.split { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: var(--leading) clamp(24px, 5vw, 96px); align-items: center;
  padding: calc(2 * var(--leading)) 0 calc(3 * var(--leading)); }
.split-title { font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: 32px; line-height: calc(1.5 * var(--leading)); letter-spacing: -0.015em;
  margin: 0; text-box: trim-both cap alphabetic; }
.split-copy .note { font-size: 15.5px; line-height: var(--leading);
  color: color-mix(in srgb, var(--color-text) 78%, transparent);
  margin: calc(var(--leading) - 1cap) 0 0; max-width: 48ch; text-box: trim-both cap alphabetic; }
.split-figure { margin: 0; }
.split-figure image-slot { width: 100%; aspect-ratio: 951 / 665; }

/* — quote (hanging punctuation, the deck's measured Archivo advances) — */
.quote { padding: calc(2.5 * var(--leading)) 0 calc(3.5 * var(--leading)); }
.quote blockquote {
  font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: clamp(24px, 2.6vw, 34px); line-height: calc(1.5 * var(--leading));
  letter-spacing: -0.015em; max-width: 32ch; margin: 0;
  text-indent: -0.496em; /* hang the opening “ (the deck's measured advance in the 800) */
  text-box: trim-both cap alphabetic;
}
.quote figcaption { font-size: 15.5px; line-height: var(--leading);
  color: color-mix(in srgb, var(--color-text) 70%, transparent); /* 5.8:1 — see .stat-label */
  margin: calc(2 * var(--leading) - 1cap) 0 0; /* two grid units below the quote's
     last baseline — one reads as part of the quote block; the attribution needs air */
  text-indent: -1.209em; /* hang the leading em-dash + space (measured in the Regular) */
  text-box: trim-both cap alphabetic; }

@media (max-width: 720px) {
  /* the phone gutter (--edge bottoms out at 20px) is narrower than the hung
     marks' measured advances, so a hung “ or em-dash would press into or past
     the viewport edge — seat the quote flush below this width; the hang
     returns with the wider gutter */
  .quote blockquote, .quote figcaption { text-indent: 0; }
}

/* — the red poster close (the deck's divider logic: the accent's one field
   moment, type reversed to the paper token). COPY on the red is
   display-grade only — paper display type measures 3.8:1, the deck
   dividers' own derivation. The one small element is the ghost button, a
   CONTROL: paper-on-red measures the same 3.8:1, which meets the system's
   documented interface-chrome bar (the readme tunes the accent pair to at
   least 3:1 — "enough for icons, large text and interface chrome, not for
   body copy") — the same bar the system's own accent-filled primary button
   label rides everywhere. */
.close { background: var(--color-accent); color: var(--color-bg); }
.close .wrap { padding-top: calc(3 * var(--leading)); padding-bottom: calc(3 * var(--leading)); }
.close h3 { font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: clamp(34px, 4.2vw, 56px); line-height: clamp(36px, 4.45vw, 59.4px); /* ≈1.06 —
     display-grade, so it carries the display-block lattice exemption (the
     rhythm probe excludes .display and .close h3 alike) */
  letter-spacing: -0.015em; margin: 0; margin-left: -0.058em;
  text-box: trim-both cap alphabetic; }
.close h3 .line { display: block; }
.close .row { display: flex; gap: var(--space-3); flex-wrap: wrap; margin-top: calc(1.5 * var(--leading)); }
.close .btn-ghost { color: var(--color-bg); border-color: var(--color-bg); } /* paper outline on the red field */
footer { padding: calc(2 * var(--leading)) 0; font-size: 13px; line-height: var(--leading);
  color: color-mix(in srgb, var(--color-text) 70%, transparent); /* 5.8:1 — see .stat-label */ }

/* — responsive collapse — */
/* the feature grid's fixed-max columns (160 + 420 + gaps) crush the copy
   column in the tablet band, so it collapses earlier than the page */
@media (max-width: 880px) {
  .feature { grid-template-columns: 1fr; gap: var(--half); }
  .f-copy { max-width: var(--measure); }
}
@media (max-width: 720px) {
  .hero { padding-top: calc(2.5 * var(--leading)); }
  .stats .grid { grid-template-columns: repeat(2, 1fr); justify-content: start; }
  .split { grid-template-columns: 1fr; }
  .split-figure { order: -1; }
}

/* — articles (blog teaser: ruled cells, the same seam grammar as .plan) — */
.articles { padding: calc(2.5 * var(--leading)) 0 calc(3 * var(--leading)); }
.art-head { display: flex; justify-content: space-between; align-items: baseline;
  gap: var(--leading); flex-wrap: wrap; }
.art-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: calc(1.5 * var(--leading)) clamp(24px, 4vw, 72px); margin-top: var(--half); }
.art { border-top: 2px solid var(--color-divider); padding-top: var(--leading); }
.art-meta { font-size: 13px; line-height: var(--half); letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--color-accent-700);
  font-feature-settings: "tnum" 1; margin: 0 0 var(--half); }
.art-title { font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: 19px; line-height: var(--leading); letter-spacing: -0.01em; margin: 0; }
.art-title a { color: var(--color-text); text-decoration: none;
  border-bottom: 2px solid transparent; }
.art-title a:hover { color: var(--color-accent); border-bottom-color: var(--color-accent); }
.art-dek { font-size: 15.5px; line-height: var(--leading); margin: var(--half) 0 0;
  color: color-mix(in srgb, var(--color-text) 78%, transparent); }
.art-topics { display: flex; flex-wrap: wrap; gap: var(--space-2, 8px);
  margin-top: calc(1.5 * var(--leading)); }
@media (max-width: 880px) { .art-grid { grid-template-columns: 1fr; } }

/* — bilingual copy: every string ships RU + EN, one visible at a time.
   .t wrappers are display:contents so they never touch layout. — */
.t { display: contents; }
html[data-lang="ru"] .t[lang="en"], html[data-lang="en"] .t[lang="ru"] { display: none; }
.lang { font-feature-settings: "tnum" 1; }

/* — plans (ruled cells, no cards: the seam does the work) — */
.plans { padding: calc(2.5 * var(--leading)) 0 calc(3 * var(--leading)); }
.plan-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--leading) clamp(24px, 4vw, 72px); margin-top: var(--half); }
.plan { border-top: 2px solid var(--color-divider); padding-top: var(--leading); }
.plan-name { font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: 24px; line-height: var(--leading); letter-spacing: -0.01em; margin: 0;
  text-box: trim-both cap alphabetic; }
.plan-price { font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: clamp(34px, 3.2vw, 44px); line-height: calc(2 * var(--leading));
  color: var(--color-accent); margin: var(--half) 0 0; margin-left: -0.045em; }
.plan-price .per { font-family: var(--font-body); font-weight: 400; font-size: 15px;
  color: color-mix(in srgb, var(--color-text) 70%, transparent); letter-spacing: 0; }
.plan-list { list-style: none; margin: var(--half) 0 var(--leading); padding: 0; }
.plan-list li { position: relative; padding-left: 22px; font-size: 15.5px; line-height: var(--leading);
  color: color-mix(in srgb, var(--color-text) 78%, transparent); }
.plan-list li::before { content: ""; position: absolute; left: 0; top: calc(0.5 * var(--leading) - 5px);
  width: 10px; height: 10px; background: var(--color-accent); }

/* — reviews — */
.reviews { padding: calc(2.5 * var(--leading)) 0 calc(3 * var(--leading)); }
.review-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--leading) clamp(24px, 4vw, 72px); margin-top: var(--half); }
.review { border-top: 2px solid var(--color-divider); padding-top: var(--leading); }
.review p { font-size: 15.5px; line-height: var(--leading); margin: 0;
  color: color-mix(in srgb, var(--color-text) 85%, transparent); }
.review .who { margin-top: var(--half); font-size: 13px; line-height: var(--half);
  letter-spacing: 0.08em; text-transform: uppercase;
  color: color-mix(in srgb, var(--color-text) 70%, transparent); }

/* — application form — */
.apply { padding: calc(2.5 * var(--leading)) 0 calc(3 * var(--leading));
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: var(--leading) clamp(24px, 5vw, 96px); }
.apply .note { font-size: 15.5px; line-height: var(--leading); max-width: 40ch;
  color: color-mix(in srgb, var(--color-text) 78%, transparent);
  margin: calc(var(--leading) - 1cap) 0 0; }
.form-rows { display: grid; gap: var(--leading); }
.form-two { display: grid; grid-template-columns: 1fr 1fr; gap: var(--leading); }
.form-actions { display: flex; gap: var(--space-3); align-items: center; flex-wrap: wrap; }
.form-actions .small { font-size: 13px; line-height: var(--half);
  color: color-mix(in srgb, var(--color-text) 70%, transparent); }
@media (max-width: 880px) {
  .plan-grid, .review-grid, .apply, .form-two { grid-template-columns: 1fr; }
}

/* Review aid: the 28px rhythm drawn as hairlines — debug chrome, toggled by
   ?baselines or the B key, never part of the look. */
body[data-baselines] { position: relative; }
body[data-baselines]::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    repeating-linear-gradient(to bottom,
      color-mix(in srgb, var(--color-accent) 35%, transparent) 0 1px,
      transparent 1px var(--leading)),
    repeating-linear-gradient(to bottom,
      transparent 0 var(--half),
      color-mix(in srgb, var(--color-accent) 16%, transparent) var(--half) calc(var(--half) + 1px),
      transparent calc(var(--half) + 1px) var(--leading));
}


/* ============ 3. Архив статей ============ */

/* Archive page — same rhythm and grammar as index.html: 28px leading, 2px
   seams, red as a mark. Layout only; every color/font/space is a token. */
:root { --leading: 28px; --half: 14px; --edge: clamp(20px, 5vw, 72px); --measure: 58ch; }
body { margin: 0; text-wrap: pretty; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 var(--edge); }
.nav { padding-inline: max(var(--edge), calc((100% - 1200px) / 2 + var(--edge))); }
.nav a { white-space: nowrap; }
.nav a[aria-current="page"] { color: var(--color-accent); }
@media (max-width: 480px) { .nav a { display: none; } }
.rule2 { height: 2px; border: 0; margin: 0; background: var(--color-divider); }
.kicker { display: block; font-size: 13px; line-height: var(--half); letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--color-accent-700); font-feature-settings: "tnum" 1;
  margin: 0 0 calc(var(--leading) - var(--half)); }

.head { padding: calc(2.5 * var(--leading)) 0 calc(2 * var(--leading)); }
.head h1 { font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: clamp(38px, 5vw, 64px); line-height: clamp(40px, 5.3vw, 68px);
  letter-spacing: -0.02em; margin: 0; margin-left: -0.058em; text-box: trim-both cap alphabetic; }
.head h1 .line { display: block; }
.head .sub { font-size: 17px; line-height: var(--leading); max-width: var(--measure);
  margin: calc(1.5 * var(--leading) - 1cap) 0 0; text-box: trim-both cap alphabetic; }

/* toolbar: search + rubric chips */
.toolbar { display: grid; grid-template-columns: minmax(0, 320px) minmax(0, 1fr);
  gap: var(--leading) clamp(24px, 4vw, 64px); align-items: start;
  padding: calc(1.5 * var(--leading)) 0; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips .tag { cursor: pointer; text-decoration: none; }
.chips .tag[aria-current="true"] { background: var(--color-accent); color: var(--color-bg);
  border-color: var(--color-accent); }
.count { font-size: 13px; line-height: var(--half); letter-spacing: 0.08em; text-transform: uppercase;
  color: color-mix(in srgb, var(--color-text) 70%, transparent); font-feature-settings: "tnum" 1;
  margin: var(--half) 0 0; }

/* the list: one ruled row per article */
.list { padding: 0 0 calc(2 * var(--leading)); }
.row-a { display: grid; grid-template-columns: minmax(64px, 96px) minmax(0, 1fr) minmax(0, 200px);
  gap: var(--half) clamp(24px, 4vw, 64px); align-items: baseline;
  padding: calc(1.25 * var(--leading)) 0; border-top: 2px solid var(--color-divider); }
.row-a:last-child { border-bottom: 2px solid var(--color-divider); }
.row-a .idx { font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: 15px; line-height: var(--leading); font-feature-settings: "tnum" 1; margin: 0;
  color: color-mix(in srgb, var(--color-text) 70%, transparent); }
.row-a h2 { font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: 22px; line-height: var(--leading); letter-spacing: -0.01em; margin: 0; }
.row-a h2 a { color: var(--color-text); text-decoration: none; border-bottom: 2px solid transparent; }
.row-a h2 a:hover { color: var(--color-accent); border-bottom-color: var(--color-accent); }
.row-a .dek { font-size: 15.5px; line-height: var(--leading); margin: var(--half) 0 0; max-width: 62ch;
  color: color-mix(in srgb, var(--color-text) 78%, transparent); }
.row-a .meta { font-size: 13px; line-height: var(--leading); letter-spacing: 0.08em;
  text-transform: uppercase; font-feature-settings: "tnum" 1; margin: 0;
  color: color-mix(in srgb, var(--color-text) 70%, transparent); }
.row-a .meta .cat { color: var(--color-accent-700); display: block; }
@media (max-width: 880px) {
  .toolbar { grid-template-columns: 1fr; }
  .row-a { grid-template-columns: 1fr; }
  .row-a .idx { display: none; }
  .row-a .meta { order: -1; }
}

/* pagination */
.pager { display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  padding: calc(1.5 * var(--leading)) 0 calc(3 * var(--leading)); }
.pager .spacer { flex: 1; }
.pager .dots { font-size: 14px; color: color-mix(in srgb, var(--color-text) 55%, transparent);
  padding: 0 4px; }
.pager .btn[aria-current="page"] { background: var(--color-accent); color: var(--color-bg);
  border-color: var(--color-accent); }

footer { padding: calc(2 * var(--leading)) 0; font-size: 13px; line-height: var(--leading);
  color: color-mix(in srgb, var(--color-text) 70%, transparent); }


/* ============ 4. Тело статьи (single.php) ============ */
.post-body { max-width: 68ch; padding: calc(2 * var(--leading)) 0 calc(2.5 * var(--leading)); font-size: 17px; line-height: var(--leading); }
.post-body > * { margin: 0 0 var(--leading); }
.post-body h2 { font-family: var(--font-heading); font-weight: var(--font-heading-weight); font-size: 28px; line-height: calc(1.5 * var(--leading)); letter-spacing: -0.015em; margin-top: calc(2 * var(--leading)); }
.post-body h3 { font-family: var(--font-heading); font-weight: var(--font-heading-weight); font-size: 21px; line-height: var(--leading); margin-top: calc(1.5 * var(--leading)); }
.post-body a { color: var(--color-accent-700); }
.post-body ul, .post-body ol { padding-left: 22px; }
.post-body li { margin-bottom: var(--half); }
.post-body blockquote { border-left: 2px solid var(--color-accent); padding-left: 20px; margin-left: 0; font-size: 19px; }
.post-body img { max-width: 100%; height: auto; filter: grayscale(1); }
.post-body code { font-size: 15px; background: var(--color-neutral-200); padding: 2px 5px; }
.post-body table { width: 100%; border-collapse: collapse; }
.post-body th, .post-body td { border-top: 2px solid var(--color-divider); padding: var(--half) 0; text-align: left; }
