/*
 * Alfa Editorial: base.css
 * Tokens, type, layout primitives and the shared components.
 * Loaded on every view, before chrome.css and the view stylesheet.
 *
 * Naming: .ed-block, .ed-block__part, .ed-block--variant. State classes: .is-*, .has-*.
 * Global element rules are wrapped in :where(.ed) so they carry no specificity.
 */

/* ------------------------------------------------------------------ 1. Fonts */

@font-face {
  font-family: "Noto Serif";
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 62.5% 100%;
  font-display: swap;
  src: url("../fonts/noto-serif-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Noto Serif";
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 62.5% 100%;
  font-display: swap;
  src: url("../fonts/noto-serif-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: "Noto Serif";
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 62.5% 100%;
  font-display: swap;
  src: url("../fonts/noto-serif-latin-ce.woff2") format("woff2");
  unicode-range: U+0100-017F, U+0218-021B;
}
@font-face {
  font-family: "Noto Serif";
  font-style: italic;
  font-weight: 100 900;
  font-stretch: 62.5% 100%;
  font-display: swap;
  src: url("../fonts/noto-serif-italic-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Noto Serif";
  font-style: italic;
  font-weight: 100 900;
  font-stretch: 62.5% 100%;
  font-display: swap;
  src: url("../fonts/noto-serif-italic-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: "Noto Serif";
  font-style: italic;
  font-weight: 100 900;
  font-stretch: 62.5% 100%;
  font-display: swap;
  src: url("../fonts/noto-serif-italic-latin-ce.woff2") format("woff2");
  unicode-range: U+0100-017F, U+0218-021B;
}
@font-face {
  font-family: "Libre Franklin";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../fonts/libre-franklin-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Libre Franklin";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../fonts/libre-franklin-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: "Libre Franklin";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../fonts/libre-franklin-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+20A0-20AB, U+20AD-20C4, U+2113;
}

@font-face {
  font-family: "Brygada 1918";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("../fonts/brygada-1918-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Brygada 1918";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("../fonts/brygada-1918-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: "Brygada 1918";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("../fonts/brygada-1918-latin-ce.woff2") format("woff2");
  unicode-range: U+0100-017F, U+0218-021B;
}
@font-face {
  font-family: "Brygada 1918";
  font-style: italic;
  font-weight: 400 700;
  font-display: swap;
  src: url("../fonts/brygada-1918-italic-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Brygada 1918";
  font-style: italic;
  font-weight: 400 700;
  font-display: swap;
  src: url("../fonts/brygada-1918-italic-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: "Brygada 1918";
  font-style: italic;
  font-weight: 400 700;
  font-display: swap;
  src: url("../fonts/brygada-1918-italic-latin-ce.woff2") format("woff2");
  unicode-range: U+0100-017F, U+0218-021B;
}

/* ------------------------------------------------------------------ 2. Tokens */

:root {
  /* Ink and paper */
  --ed-ink: #121212;        /* headlines, strong rules */
  --ed-ink-2: #363636;      /* running text */
  --ed-ink-3: #5a5a5a;      /* summaries, secondary text */
  --ed-ink-4: #6b6b6b;      /* meta, captions (5.3:1 on white) */
  --ed-line: #dfdfdf;       /* hairlines */
  --ed-line-2: #c7c7c7;     /* column rules */
  --ed-bg: #ffffff;
  --ed-bg-2: #f7f7f5;       /* quiet bands */
  --ed-bg-3: #ebebeb;       /* image placeholders, chips */
  --ed-accent: #326891;     /* links in text, primary buttons */
  --ed-accent-2: #244b69;   /* hover of the accent */
  --ed-red: #c8102e;        /* the one colour: kickers, live times, numerals, progress */
  --ed-red-2: #a10d25;      /* its hover */
  --ed-live: var(--ed-red);
  --ed-ok: #1d7a46;

  /* Type */
  --ed-serif: "Noto Serif", "Noto Serif Fallback", Georgia, "Times New Roman", Times, serif;
  --ed-sans: "Libre Franklin", "Libre Franklin Fallback", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --ed-head: "Brygada 1918", "Brygada 1918 Fallback", Georgia, "Times New Roman", Times, serif; /* every headline */
  --ed-head-width: 100%;    /* legacy: headlines are no longer condensed */
  --ed-display-width: 70%;  /* section titles: the text serif, condensed and heavy */

  --ed-fs-xl: clamp(1.75rem, 1.4rem + 1.5vw, 2.25rem);     /* 28 → 36  lead headline */
  --ed-fs-lg: clamp(1.5rem, 1.3rem + 0.9vw, 1.875rem);     /* 24 → 30 */
  --ed-fs-md: clamp(1.3125rem, 1.22rem + 0.4vw, 1.4375rem); /* 21 → 23 */
  --ed-fs-sm: 1.1875rem;                                   /* 19 */
  --ed-fs-xs: 1.0625rem;                                   /* 17 */
  --ed-fs-dek: 0.9375rem;                                  /* 15 */
  --ed-fs-label: 0.6875rem;                                /* 11  kickers, meta */
  --ed-fs-ui: 0.8125rem;                                   /* 13  navigation, buttons */

  /* Space: 4px steps */
  --ed-s1: 4px;
  --ed-s2: 8px;
  --ed-s3: 12px;
  --ed-s4: 16px;
  --ed-s5: 20px;
  --ed-s6: 24px;
  --ed-s8: 32px;
  --ed-s10: 40px;
  --ed-s12: 48px;
  --ed-s16: 64px;

  /* Page frame */
  --ed-max: 1200px;
  --ed-gutter: 16px;
  --ed-col-pad: 16px;       /* space on each side of a column rule */
  --ed-measure: 37.5rem;    /* reading column (600px) */
  --ed-top: 0px;            /* height of the admin bar when present */

  --ed-radius: 3px;
  --ed-ease: cubic-bezier(0.2, 0, 0, 1);
  --ed-motion: cubic-bezier(0.2, 0.7, 0.2, 1); /* reveals, parallax settle, overlays (section 15) */
  --ed-motion-dur: 520ms;

  /* Rhythm (one scale for every view): between major blocks, between a rule and the text under it,
     between stories of a list. */
  --ed-block-gap: 24px;
  --ed-rule-gap: 12px;
  --ed-item-gap: 12px;
}
@media (min-width: 740px) {
  :root { --ed-gutter: 24px; }
}
@media (min-width: 1024px) {
  :root { --ed-gutter: 32px; --ed-col-pad: 12px; --ed-block-gap: 32px; --ed-rule-gap: 14px; --ed-item-gap: 14px; }
}
body.admin-bar { --ed-top: 32px; }
@media (max-width: 782px) {
  body.admin-bar { --ed-top: 46px; }
}
/* Height of the sticky compact bar (chrome.css .ed-bar: 56px + 1px rule on phones; from 1024px the
   condensed header: a 46px nameplate row, a 1px hairline, the 30px section row and its 1px rule)
   plus the admin bar. Declared on body so it follows --ed-top. */
body { --ed-sticky-top: calc(var(--ed-top) + 57px); }
@media (min-width: 1024px) {
  body { --ed-sticky-top: calc(var(--ed-top) + 78px); }
}

/* ------------------------------------------------------------------ 3. Reset */

:where(.ed), :where(.ed) *, :where(.ed) *::before, :where(.ed) *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

body.ed {
  margin: 0;
  background: var(--ed-bg);
  color: var(--ed-ink);
  font-family: var(--ed-serif);
  font-size: 1rem;
  line-height: 1.5;
  font-kerning: normal;
  font-variant-numeric: lining-nums;
  font-optical-sizing: auto;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-wrap: break-word;
}

:where(.ed) :where(h1, h2, h3, h4, h5, h6, p, figure, blockquote, dl, dd, ul, ol, pre) { margin: 0; }
:where(.ed) :where(ul, ol)[class] { padding: 0; list-style: none; }
:where(.ed) :where(h1, h2, h3, h4, h5, h6) { font-size: inherit; font-weight: inherit; }
:where(.ed) :where(img, picture, video, svg, canvas) { display: block; max-width: 100%; }
:where(.ed) :where(img, video) { height: auto; }
:where(.ed) :where(a) { color: inherit; text-decoration: none; }
:where(.ed) :where(button, input, select, textarea) { font: inherit; color: inherit; letter-spacing: inherit; }
:where(.ed) :where(button) { background: none; border: 0; padding: 0; cursor: pointer; }
:where(.ed) :where(table) { border-collapse: collapse; }
:where(.ed) :where([hidden]) { display: none !important; }

/* Focus ring and selection follow the section colour (the blue accent outside a section). */
:where(.ed) :focus-visible {
  outline: 2px solid var(--sd-focus, var(--ed-accent));
  outline-offset: 2px;
  border-radius: 1px;
}
:where(.ed) ::selection { background: var(--sd-select, #cfe0ec); color: var(--ed-ink); }
:where([class*="sd-sec-"], [data-sec]) { --sd-focus: var(--sd-c-text); --sd-select: var(--sd-line); }
@supports (color: color-mix(in oklch, red 50%, blue)) {
  :where([class*="sd-sec-"], [data-sec]) { --sd-select: color-mix(in oklch, var(--sd-c) 20%, #fff); }
}

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

/* ------------------------------------------------------------------ 4. Frame */

.ed-wrap {
  width: 100%;
  max-width: calc(var(--ed-max) + 2 * var(--ed-gutter));
  margin-inline: auto;
  padding-inline: var(--ed-gutter);
}
.ed-wrap--narrow { max-width: calc(var(--ed-measure) + 2 * var(--ed-gutter)); }
.ed-wrap--mid { max-width: calc(945px + 2 * var(--ed-gutter)); }

.ed-main { display: block; padding-bottom: var(--ed-s6); min-height: 50vh; }

.ed-vh {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0; border: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.ed-skip {
  position: absolute;
  left: 8px; top: -60px;
  z-index: 1000;
  padding: 10px 14px;
  background: var(--ed-ink);
  color: #fff;
  font: 700 var(--ed-fs-ui)/1 var(--ed-sans);
  border-radius: var(--ed-radius);
  transition: top 0.15s var(--ed-ease);
}
.ed-skip:focus { top: calc(var(--ed-top) + 8px); color: #fff; }

.ed-icon { flex: none; }

/* Rules */
.ed-rule { height: 0; margin: 0; border: 0; border-top: 1px solid var(--ed-ink); }
.ed-rule--light { border-top-color: var(--ed-line); }
.ed-rule--double { border-top: 3px double var(--ed-ink); }

/*
 * Columns divided by hairlines. Phones: stacked with horizontal rules.
 * From 740px: --2 / --3 / --4 / --5 equal columns with vertical rules
 * (4 and 5 are two columns until 1024px).
 */
.ed-cols { display: grid; grid-template-columns: minmax(0, 1fr); }
.ed-cols > * { position: relative; min-width: 0; }
.ed-cols > * + * {
  margin-top: var(--ed-item-gap);
  padding-top: var(--ed-item-gap);
  border-top: 1px solid var(--ed-line);
}
@media (min-width: 740px) {
  /* Equal gaps with the rule drawn in the middle of each gap, so every column has the same width.
     The ::before of a direct child of .ed-cols is reserved for that rule. */
  .ed-cols {
    --ed-n: 2;
    grid-template-columns: repeat(var(--ed-n), minmax(0, 1fr));
    column-gap: calc(2 * var(--ed-col-pad));
    row-gap: var(--ed-block-gap);
  }
  .ed-cols--3 { --ed-n: 3; }
  .ed-cols > *,
  .ed-cols > * + * { margin-top: 0; padding-top: 0; border-top: 0; }
  .ed-cols > *::before {
    content: "";
    position: absolute;
    top: 0; bottom: 0;
    left: calc(-1 * var(--ed-col-pad));
    border-left: 1px solid var(--ed-line-2);
    pointer-events: none;
  }
  .ed-cols > :nth-child(2n + 1)::before { display: none; }
  .ed-cols--3 > :nth-child(n)::before { display: block; }
  .ed-cols--3 > :nth-child(3n + 1)::before { display: none; }
}
@media (min-width: 1024px) {
  .ed-cols--4 { --ed-n: 4; }
  .ed-cols--5 { --ed-n: 5; }
  .ed-cols--4 > :nth-child(n)::before,
  .ed-cols--5 > :nth-child(n)::before { display: block; }
  .ed-cols--4 > :nth-child(4n + 1)::before,
  .ed-cols--5 > :nth-child(5n + 1)::before { display: none; }
}

/* Main column + rail, divided by a rule from 1024px. */
.ed-split { display: grid; grid-template-columns: minmax(0, 1fr); row-gap: var(--ed-block-gap); }
.ed-split > * { min-width: 0; }
@media (min-width: 1024px) {
  .ed-split { grid-template-columns: minmax(0, 2.2fr) minmax(0, 1fr); }
  .ed-split > :first-child { padding-right: var(--ed-col-pad); border-right: 1px solid var(--ed-line-2); }
  .ed-split > :last-child { padding-left: var(--ed-col-pad); }
  .ed-split--even { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .ed-split--wide { grid-template-columns: minmax(0, 2.9fr) minmax(0, 1fr); }
}

/* Vertical rhythm helpers */
.ed-stack > * + * { margin-top: var(--ed-stack, var(--ed-s4)); }
.ed-ruled > * + * {
  margin-top: var(--ed-stack, var(--ed-s4));
  padding-top: var(--ed-stack, var(--ed-s4));
  border-top: 1px solid var(--ed-line);
}

/* A page block: space above, strong rule on top (used between home and section packages). */
.ed-block { margin-top: var(--ed-block-gap); padding-top: var(--ed-rule-gap); border-top: 1px solid var(--ed-ink); }
.ed-block--plain { border-top: 0; padding-top: 0; }
.ed-block--tint { background: var(--ed-bg-2); border-top: 0; padding: var(--ed-block-gap) 0; }
:where(.ed-rule) + :where(*) { margin-top: var(--ed-rule-gap); }

/* Sticky on scroll (desktop only): a rail, or the shorter column of a package, stays in view under
   the compact bar while the longer column scrolls. It never grows past the viewport (it ends early
   instead of scrolling inside); phones keep the normal flow. */
@media (min-width: 1024px) and (min-height: 560px) {
  .ed-sticky {
    position: sticky;
    top: calc(var(--ed-sticky-top, 64px) + 16px);
    align-self: start;
    max-height: calc(100vh - var(--ed-sticky-top, 64px) - 32px);
    overflow: clip;
  }
}

/* ------------------------------------------------------------------ 5. Type */

/* Headline face: one rule so every headline on the site shares width, tracking and wrap. */
.ed-h,
.ed-story__headline,
.ed-ranked__headline {
  font-family: var(--ed-head);
  font-stretch: normal;
  font-weight: 500;
  line-height: 1.17;
  letter-spacing: 0;
  color: var(--ed-ink);
  text-wrap: balance;
  hyphens: manual;
}
.ed-h--xl { font-size: var(--ed-fs-xl); font-weight: 700; line-height: 1.1; letter-spacing: -0.005em; }
.ed-h--lg { font-size: var(--ed-fs-lg); font-weight: 700; line-height: 1.13; letter-spacing: -0.003em; }
.ed-h--md { font-size: var(--ed-fs-md); }
.ed-h--sm { font-size: var(--ed-fs-sm); line-height: 1.2; }
.ed-h--xs { font-size: var(--ed-fs-xs); line-height: 1.22; }

/* Section titles on section fronts: the text serif, condensed and heavy. */
.ed-display {
  font-family: var(--ed-serif);
  font-stretch: var(--ed-display-width);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.01em;
  color: var(--ed-ink);
}

/* Kicker: the category above a headline */
.ed-kicker {
  margin-bottom: 6px;
  font-family: var(--ed-sans);
  font-size: var(--ed-fs-label);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ed-red);
}
.ed-kicker a:hover { color: var(--ed-red-2); text-decoration: underline; text-underline-offset: 2px; }
.ed-kicker--ink { color: var(--ed-ink); }
.ed-kicker--live { color: var(--ed-red); }

/* A small pulsing dot for live and latest labels */
.ed-dot {
  display: inline-block;
  width: 7px; height: 7px;
  margin-right: 6px;
  border-radius: 50%;
  background: var(--ed-red);
  vertical-align: 0.06em;
  /* three soft beats after load, then it rests (the motion contract: nothing loops) */
  animation: ed-pulse 2s var(--ed-ease) 3;
}
@keyframes ed-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.35; }
}
.ed-time--live { color: var(--ed-red); }
.ed-kicker--quiet { font-weight: 500; color: var(--ed-ink-4); }

/* Small uppercase label used outside stories (rails, modules) */
.ed-label {
  font-family: var(--ed-sans);
  font-size: var(--ed-fs-label);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ed-ink);
}
.ed-label--quiet { font-weight: 500; color: var(--ed-ink-4); }

/* Meta line: time, reading time, author */
.ed-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  column-gap: 0;
  margin-top: var(--ed-s2);
  font-family: var(--ed-sans);
  font-size: var(--ed-fs-label);
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: 0.045em;
  text-transform: uppercase;
  color: var(--ed-ink-4);
}
.ed-meta > * + *::before { content: "·"; margin-inline: 0.5em; }

/* Text links inside prose-like copy */
.ed-link {
  color: var(--ed-accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}
.ed-link:hover { color: var(--ed-accent-2); }

/* ------------------------------------------------------------------ 6. Media */

.ed-media {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 3 / 2;
  background: var(--ed-bg-3);
}
.ed-media--16x9 { aspect-ratio: 16 / 9; }
.ed-media--4x3 { aspect-ratio: 4 / 3; }
.ed-media--1x1 { aspect-ratio: 1 / 1; }
.ed-media--4x5 { aspect-ratio: 4 / 5; }
.ed-media--2x3 { aspect-ratio: 2 / 3; }
.ed-media--auto { aspect-ratio: auto; }
.ed-media > img,
.ed-media .ed-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 30%;
  transition: opacity 0.2s var(--ed-ease);
}
.ed-media--auto > img { height: auto; }
/* The box's height comes from its ratio alone: a picture that is still downloading (no natural size
   yet) can never collapse it (seen on the front page lead: a 0.09 layout shift on slow networks). */
.ed-media:not(.ed-media--auto):not(.ed-media--empty) > :is(img, picture, video, .ed-img) { position: absolute; inset: 0; }
.ed-media:not(.ed-media--auto) > picture > img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; }
/* A story without a picture: the same box in a quiet wash of its section colour, with the section's
   initial in the headline face (inc/media.php aed_media_fallback_parts). */
.ed-media--empty {
  display: grid;
  place-items: center;
  background: var(--sd-c-tint, var(--ed-bg-2));
}
.ed-media__mark {
  font-family: var(--ed-head);
  font-size: clamp(1.25rem, 22cqi, 4.5rem);
  font-weight: 700;
  line-height: 1;
  color: color-mix(in srgb, var(--sd-c, var(--ed-ink)) 34%, var(--sd-c-tint, var(--ed-bg-2)));
  user-select: none;
}
.ed-media--empty { container-type: inline-size; }
.ed-media__badge {
  position: absolute;
  left: 8px; bottom: 8px;
  display: grid;
  place-items: center;
  width: 30px; height: 30px;
  border-radius: 50%;
  background: rgba(18, 18, 18, 0.72);
  color: #fff;
}
.ed-media__badge .ed-icon { margin-left: 2px; }

/* Caption under a figure */
.ed-caption {
  margin-top: 7px;
  font-family: var(--ed-sans);
  font-size: 0.75rem;
  line-height: 1.4;
  color: var(--ed-ink-4);
}
.ed-caption__credit { color: var(--ed-ink-4); letter-spacing: 0.01em; }
.ed-caption__text + .ed-caption__credit::before { content: " "; }

/* ------------------------------------------------------------------ 7. Story */

.ed-story { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.ed-story__body { min-width: 0; }
/* Hover feels physical: the headline darkens a step and a hairline in the section colour draws in
   under it from the left (180ms); the picture grows by 3 %. Ranked lists do the same. */
.ed-story__headline a,
.ed-ranked__headline a {
  display: inline;
  background-image: linear-gradient(var(--sd-c, var(--ed-ink)), var(--sd-c, var(--ed-ink)));
  background-repeat: no-repeat;
  background-position: 0 100%;
  background-size: 0% 1px;
  transition: color 0.18s var(--ed-ease), background-size 0.18s var(--ed-motion);
}
.ed-story__headline a:hover,
.ed-story:has(.ed-media:hover) .ed-story__headline a,
.ed-ranked__headline a:hover { color: var(--ed-ink-2); background-size: 100% 1px; }
.ed-story__headline a:focus-visible,
.ed-ranked__headline a:focus-visible { background-size: 100% 1px; }
.ed-story:has(.ed-story__headline a:hover) .ed-media img,
.ed-story .ed-media:hover img { opacity: 0.9; }
/* Desktop pointers: the picture of a story grows slowly by 3 % while the story is hovered (section 15
   documents .ed-zoom for media outside .ed-story); the dim above is for touch and keyboard. */
@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .ed-story .ed-media > img,
  .ed-story .ed-media .ed-img,
  .ed-zoom img {
    transition: transform 420ms var(--ed-motion), opacity 0.2s var(--ed-ease);
    backface-visibility: hidden;
  }
  .ed-story:hover .ed-media > img,
  .ed-story:hover .ed-media .ed-img,
  .ed-story:hover .ed-zoom img,
  .ed-zoom:hover img { transform: scale(1.03); }
  .ed-story:has(.ed-story__headline a:hover) .ed-media img,
  .ed-story .ed-media:hover img { opacity: 1; }
}
.ed-zoom { overflow: hidden; }

.ed-story--xl .ed-story__headline { font-size: var(--ed-fs-xl); font-weight: 700; line-height: 1.1; letter-spacing: -0.005em; }
.ed-story--lg .ed-story__headline { font-size: var(--ed-fs-lg); font-weight: 700; line-height: 1.13; letter-spacing: -0.003em; }
.ed-story--md .ed-story__headline { font-size: var(--ed-fs-md); }
.ed-story--sm .ed-story__headline { font-size: var(--ed-fs-sm); line-height: 1.2; }
.ed-story--xs .ed-story__headline { font-size: var(--ed-fs-xs); line-height: 1.22; }

/* Feature and opinion treatment: regular weight, italic */
.ed-story--light .ed-story__headline { font-weight: 400; font-style: italic; }
.ed-story--bold .ed-story__headline { font-weight: 700; }

.ed-story__dek {
  margin-top: 6px;
  font-family: var(--ed-serif);
  font-size: var(--ed-fs-dek);
  line-height: 1.42;
  color: var(--ed-ink-3);
  text-wrap: pretty;
}
.ed-story--xl .ed-story__dek { margin-top: 10px; font-size: 1.0625rem; line-height: 1.45; }
.ed-story--lg .ed-story__dek { margin-top: 8px; font-size: 1rem; }
.ed-story--xs .ed-story__dek { font-size: 0.875rem; }

/* Text left, image right. Phones: text first, then the image. */
@media (min-width: 740px) {
  .ed-story--side,
  .ed-story--side-rev {
    display: grid;
    grid-template-columns: minmax(0, var(--ed-side-text, 1fr)) minmax(0, var(--ed-side-media, 1.35fr));
    column-gap: var(--ed-s5);
    align-items: start;
  }
  .ed-story--side-rev { grid-template-columns: minmax(0, var(--ed-side-media, 1.35fr)) minmax(0, var(--ed-side-text, 1fr)); }
}

/* Small image to the right of the text, on every screen. */
.ed-story--thumb {
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--ed-thumb, 104px);
  column-gap: var(--ed-s3);
  align-items: start;
}
.ed-story--thumb:not(.has-media) { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 740px) {
  .ed-story--thumb { --ed-thumb: 120px; }
}

/* ------------------------------------------------------------------ 8. Lists */

.ed-list { margin: 0; padding: 0; list-style: none; }
.ed-list > li + li {
  margin-top: var(--ed-list-gap, var(--ed-item-gap));
  padding-top: var(--ed-list-gap, var(--ed-item-gap));
  border-top: 1px solid var(--ed-line);
}
.ed-list--tight { --ed-list-gap: 10px; }
.ed-list--loose { --ed-list-gap: 16px; }
.ed-list--plain > li + li { border-top: 0; padding-top: 0; }

/* Numbered list: most read */
.ed-ranked { margin: 0; padding: 0; list-style: none; counter-reset: ed-rank; }
.ed-ranked > li {
  display: grid;
  grid-template-columns: 1.6rem minmax(0, 1fr);
  column-gap: var(--ed-s3);
  align-items: baseline;
  counter-increment: ed-rank;
}
.ed-ranked > li + li { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--ed-line); }
.ed-ranked > li::before {
  content: counter(ed-rank);
  font-family: var(--ed-head);
  font-size: 1.625rem;
  font-weight: 700;
  line-height: 1;
  color: var(--ed-red);
  text-align: left;
}
.ed-ranked__headline { font-size: var(--ed-fs-xs); line-height: 1.22; }

/* ------------------------------------------------------------------ 9. Section head */

.ed-section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 6px var(--ed-s5);
  margin-bottom: var(--ed-rule-gap);
}
.ed-section-head__title {
  font-family: var(--ed-sans);
  font-size: 1.0625rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.005em;
  color: var(--ed-ink);
}
.ed-section-head__title a { display: inline-flex; align-items: center; gap: 3px; }
.ed-section-head__title a:hover { color: var(--ed-ink-3); }
.ed-section-head__title .ed-icon { position: relative; top: 0.5px; transition: transform 0.15s var(--ed-ease); }
.ed-section-head__title a:hover .ed-icon { transform: translateX(2px); }
.ed-section-head__links { min-width: 0; }
.ed-section-head__links ul {
  display: flex;
  flex-wrap: wrap;
  gap: 4px var(--ed-s4);
  margin: 0; padding: 0;
  list-style: none;
  font-family: var(--ed-sans);
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1.3;
  color: var(--ed-ink-3);
}
.ed-section-head__links a:hover { color: var(--ed-ink); text-decoration: underline; text-underline-offset: 3px; }

/* ------------------------------------------------------------------ 10. Controls */

.ed-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 36px;
  padding: 8px 14px;
  border: 1px solid var(--ed-ink);
  border-radius: var(--ed-radius);
  background: transparent;
  color: var(--ed-ink);
  font-family: var(--ed-sans);
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.15s var(--ed-ease), color 0.15s var(--ed-ease), border-color 0.15s var(--ed-ease);
}
.ed-btn:hover { background: var(--ed-ink); color: #fff; }
.ed-btn--primary { border-color: var(--ed-accent); background: var(--ed-accent); color: #fff; }
.ed-btn--primary:hover { border-color: var(--ed-accent-2); background: var(--ed-accent-2); color: #fff; }
.ed-btn--quiet { border-color: var(--ed-line-2); font-weight: 600; }
.ed-btn--quiet:hover { border-color: var(--ed-ink); background: transparent; color: var(--ed-ink); }
.ed-btn--block { width: 100%; }
.ed-btn--sm { min-height: 28px; padding: 6px 10px; font-size: 0.6875rem; }
.ed-btn[disabled], .ed-btn[aria-disabled="true"] { opacity: 0.5; cursor: default; pointer-events: none; }
/* Pressed: every control sinks a pixel and tightens a little (transform only, 120ms). */
.ed-btn, .ed-iconbtn, .ed-chip, .ed-pagination a { transition-property: background-color, color, border-color, transform; }
.ed-btn:active, .ed-iconbtn:active, .ed-chip:active, .ed-pagination a:active { transform: translateY(1px) scale(0.98); transition-duration: 0.08s; }
/* Touch screens: 44px targets for every control (the look on a mouse is unchanged). */
@media (pointer: coarse) {
  .ed-btn:not(.ed-btn--sm), .ed-iconbtn { min-height: 44px; }
  .ed-iconbtn { width: 44px; height: 44px; }
  .ed-chip { min-height: 40px; }
  .ed-pagination a, .ed-pagination span { min-width: 44px; min-height: 44px; }
}

/* Round icon button (tools, share) */
.ed-iconbtn {
  display: inline-grid;
  place-items: center;
  width: 36px; height: 36px;
  border: 1px solid var(--ed-line-2);
  border-radius: 50%;
  color: var(--ed-ink);
  transition: border-color 0.15s var(--ed-ease), background-color 0.15s var(--ed-ease);
}
.ed-iconbtn:hover { border-color: var(--ed-ink); background: var(--ed-bg-2); }
.ed-iconbtn.is-on { border-color: var(--ed-ink); background: var(--ed-ink); color: #fff; }

.ed-input,
.ed-select {
  width: 100%;
  min-height: 40px;
  padding: 8px 12px;
  border: 1px solid var(--ed-line-2);
  border-radius: var(--ed-radius);
  background: #fff;
  color: var(--ed-ink);
  font-family: var(--ed-sans);
  font-size: 1rem;
  line-height: 1.3;
}
.ed-input::placeholder { color: var(--ed-ink-4); opacity: 1; }
.ed-input:hover, .ed-select:hover { border-color: var(--ed-ink-4); }
.ed-input:focus, .ed-select:focus { outline: 2px solid var(--ed-accent); outline-offset: 0; border-color: var(--ed-accent); }

/* Chip: filters, sub-sections */
.ed-chip {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 5px 12px;
  border: 1px solid var(--ed-line-2);
  border-radius: 999px;
  font-family: var(--ed-sans);
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.2;
  color: var(--ed-ink);
  white-space: nowrap;
  transition: border-color 0.15s var(--ed-ease), background-color 0.15s var(--ed-ease), color 0.15s var(--ed-ease);
}
.ed-chip:hover { border-color: var(--ed-ink); }
.ed-chip.is-current, .ed-chip[aria-current], .ed-chip[aria-pressed="true"] { border-color: var(--ed-ink); background: var(--ed-ink); color: #fff; }

/* ------------------------------------------------------------------ 11. Navigation aids */

.ed-breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  margin: 0; padding: 0;
  list-style: none;
  font-family: var(--ed-sans);
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1.4;
  color: var(--ed-ink-4);
}
.ed-breadcrumbs li + li::before { content: "/"; margin-inline: 0.55em; color: var(--ed-line-2); }
.ed-breadcrumbs a { display: inline-flex; align-items: center; min-height: 32px; transition: color 0.18s var(--ed-ease); }
.ed-breadcrumbs a:hover { color: var(--ed-ink); text-decoration: underline; text-decoration-color: var(--sd-c, var(--ed-ink)); text-underline-offset: 3px; }
/* "You are here": the last crumb in ink, the section's crumb in its colour. */
.ed-breadcrumbs [aria-current] { color: var(--ed-ink); font-weight: 600; }
.ed-breadcrumbs [data-sec] a { color: var(--sd-c-text); }
.ed-breadcrumbs [aria-current] span {
  display: inline-block;
  max-width: 17.8em;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  vertical-align: bottom;
}

.ed-pagination { margin-top: var(--ed-s10); padding-top: var(--ed-s5); border-top: 1px solid var(--ed-ink); }
.ed-pagination ul {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 0; padding: 0;
  list-style: none;
  font-family: var(--ed-sans);
  font-size: var(--ed-fs-ui);
  font-weight: 600;
}
.ed-pagination a,
.ed-pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-width: 38px;
  min-height: 38px;
  padding: 0 10px;
  border: 1px solid transparent;
  border-radius: var(--ed-radius);
  color: var(--ed-ink);
}
.ed-pagination a:hover { border-color: var(--ed-ink); }
.ed-pagination .current { border-color: var(--ed-ink); background: var(--ed-ink); color: #fff; }
.ed-pagination .dots { min-width: 0; padding: 0 2px; color: var(--ed-ink-4); }

/* ------------------------------------------------------------------ 12. Slots, ads, empty states */

.ed-slot:empty { display: none; }

.ed-ad {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: var(--ed-s4) 0;
  border-block: 1px solid var(--ed-line);
  text-align: center;
}
.ed-ad__label {
  font-family: var(--ed-sans);
  font-size: 0.625rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ed-ink-4);
}
.ed-ad img { max-width: 100%; height: auto; }

.ed-empty {
  padding: var(--ed-s10) 0;
  border-block: 1px solid var(--ed-line);
  text-align: center;
  color: var(--ed-ink-3);
}
.ed-empty__title { margin-bottom: 6px; font-family: var(--ed-head); font-size: var(--ed-fs-md); font-weight: 500; color: var(--ed-ink); }
/* A helpful empty state: where else to go (the section's other sub-sections), as 44px links. */
.ed-empty__links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0 var(--ed-s5);
  margin: var(--ed-s4) 0 0;
  padding: 0;
  list-style: none;
  font-family: var(--ed-sans);
  font-size: var(--ed-fs-ui);
  font-weight: 600;
}
.ed-empty__links a { display: inline-flex; align-items: center; min-height: 44px; color: var(--sd-c-text, var(--ed-ink)); text-decoration: underline; text-decoration-color: transparent; text-decoration-thickness: 2px; text-underline-offset: 5px; transition: text-decoration-color 0.18s var(--ed-ease); }
.ed-empty__links a:hover, .ed-empty__links a:focus-visible { text-decoration-color: var(--sd-c, var(--ed-ink)); }

/* Toast: short confirmations (link copied, story saved) */
.ed-toast {
  position: fixed;
  left: 50%; bottom: 24px;
  z-index: 900;
  transform: translate(-50%, 12px);
  padding: 10px 16px;
  border-radius: var(--ed-radius);
  background: var(--ed-ink);
  color: #fff;
  font: 600 var(--ed-fs-ui)/1.3 var(--ed-sans);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s var(--ed-ease), transform 0.2s var(--ed-ease);
}
.ed-toast.is-visible { opacity: 1; transform: translate(-50%, 0); }

/* ------------------------------------------------------------------ 13. Print */

@media print {
  body.ed { color: #000; font-size: 11pt; }
  .ed-header, .ed-footer, .ed-skip, .ed-ad, .ed-slot, .ed-pagination, .ed-toast, #wpadminbar { display: none !important; }
  .ed-wrap { max-width: none; padding: 0; }
  .ed-main { padding: 0; }
  a { color: #000 !important; text-decoration: none !important; }
}

/* ------------------------------------------------------------------ 14. Wordmark */

/* The logo, set in the headline face. Animated in two colours, ink and red:
   a red "7" and "Dena" arrive; after a pause the numeral lifts away and "Sedum" is set
   letter by letter, each landing red and cooling to ink; a red hairline passes under the
   name and is gone. About three and a half seconds; the end state is plain ink. */
.ed-wordmark {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  gap: 0.24em;
  font-family: var(--ed-head);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.012em;
  white-space: nowrap;
  color: var(--ed-ink);
  --ed-wm-ease: cubic-bezier(0.22, 1, 0.36, 1);
}
.ed-wordmark--light { color: #fff; }
.ed-wordmark__a { position: relative; display: inline-block; }
.ed-wordmark__7 { position: absolute; left: 0; top: 0; color: var(--ed-red); opacity: 0; }
.ed-wordmark__s { display: inline-block; overflow: hidden; vertical-align: bottom; max-width: 4em; padding-bottom: 0.08em; margin-bottom: -0.08em; }
.ed-wordmark__l { display: inline-block; }
.ed-wordmark__rule {
  position: absolute;
  left: 0; right: 0; bottom: -0.2em;
  height: 2px;
  background: var(--ed-red);
  transform: scaleX(0);
  transform-origin: left center;
  opacity: 0;
}
@media (prefers-reduced-motion: no-preference) {
  html:not(.ed-logo-seen) .ed-wordmark.is-animated .ed-wordmark__7 {
    animation: ed-wm-seven-in 700ms var(--ed-wm-ease) 150ms backwards, ed-wm-seven-out 650ms var(--ed-wm-ease) 1700ms forwards;
    opacity: 1;
  }
  html:not(.ed-logo-seen) .ed-wordmark.is-animated .ed-wordmark__b .ed-wordmark__l {
    animation: ed-wm-rise 800ms var(--ed-wm-ease) calc(300ms + var(--i) * 70ms) backwards;
  }
  html:not(.ed-logo-seen) .ed-wordmark.is-animated .ed-wordmark__s {
    animation: ed-wm-open 1150ms cubic-bezier(0.45, 0, 0.55, 1) 1900ms backwards;
  }
  html:not(.ed-logo-seen) .ed-wordmark.is-animated .ed-wordmark__s .ed-wordmark__l {
    animation: ed-wm-set 950ms var(--ed-wm-ease) calc(1850ms + var(--i) * 110ms) backwards;
  }
  html:not(.ed-logo-seen) .ed-wordmark.is-animated .ed-wordmark__rule {
    animation: ed-wm-rule 1300ms var(--ed-wm-ease) 2500ms both;
  }
}
@keyframes ed-wm-seven-in {
  from { opacity: 0; transform: translateY(0.3em) scale(0.92); }
  to { opacity: 1; transform: none; }
}
@keyframes ed-wm-seven-out {
  from { opacity: 1; transform: none; }
  to { opacity: 0; transform: translateY(-0.45em); }
}
@keyframes ed-wm-rise {
  from { opacity: 0; transform: translateY(0.28em); }
  to { opacity: 1; transform: none; }
}
@keyframes ed-wm-open {
  from { max-width: 0.56em; }
  to { max-width: 4em; }
}
@keyframes ed-wm-set {
  0% { opacity: 0; transform: translateY(0.4em); color: var(--ed-red); }
  45% { opacity: 1; transform: none; color: var(--ed-red); }
  100% { opacity: 1; transform: none; color: inherit; }
}
@keyframes ed-wm-rule {
  0% { transform: scaleX(0); transform-origin: left center; opacity: 1; }
  55% { transform: scaleX(1); transform-origin: left center; opacity: 1; }
  56% { transform: scaleX(1); transform-origin: right center; opacity: 1; }
  100% { transform: scaleX(0); transform-origin: right center; opacity: 1; }
}

/* ------------------------------------------------------------------ СЕДУМ ДЕНА: the nine section colours
 * --sd-c     the section's brand colour (fills, rules, marks, large type)
 * --sd-c-text the same hue, safe for small text on white (4.5:1)
 * --sd-on    text on a fill of --sd-c
 * --sd-c-tint a quiet wash of the colour for bands and panels
 * Outside any section the colour is ink. Put data-sec="<key>" on an element (or use the body class
 * sd-sec-<key>, set on a section's own pages) and everything inside takes that section's colour. */
:root {
  --sd-c: var(--ed-ink);
  --sd-c-text: var(--ed-ink);
  --sd-on: #fff;
  --sd-c-tint: var(--ed-bg-2);
  --sd-politika: #18345B;
  --sd-ekonomija: #087B62;
  --sd-tehnologija: #6544C8;
  --sd-kultura: #A32D48;
  --sd-sport: #E66A19;
  --sd-magazin: #087F91;
  --sd-kujna: #D49A16;
  --sd-igri: #2471D2;
  --sd-play: #C02C83;
}
.sd-sec-politika, [data-sec="politika"] { --sd-c: #18345B; --sd-c-text: #18345B; --sd-on: #fff; }
.sd-sec-ekonomija, [data-sec="ekonomija"] { --sd-c: #087B62; --sd-c-text: #076A55; --sd-on: #fff; }
.sd-sec-tehnologija, [data-sec="tehnologija"] { --sd-c: #6544C8; --sd-c-text: #5A3BB8; --sd-on: #fff; }
.sd-sec-kultura, [data-sec="kultura"] { --sd-c: #A32D48; --sd-c-text: #A32D48; --sd-on: #fff; }
.sd-sec-sport, [data-sec="sport"] { --sd-c: #E66A19; --sd-c-text: #AE4708; --sd-on: #fff; }
.sd-sec-magazin, [data-sec="magazin"] { --sd-c: #087F91; --sd-c-text: #066C7B; --sd-on: #fff; }
.sd-sec-kujna, [data-sec="kujna"] { --sd-c: #D49A16; --sd-c-text: #8A6100; --sd-on: #1F1603; }
.sd-sec-igri, [data-sec="igri"] { --sd-c: #2471D2; --sd-c-text: #1D62BA; --sd-on: #fff; }
.sd-sec-play, [data-sec="play"] { --sd-c: #C02C83; --sd-c-text: #B02677; --sd-on: #fff; }
[class*="sd-sec-"], [data-sec] { --sd-c-tint: color-mix(in srgb, var(--sd-c) 7%, #fff); }

/* Washes (precomputed, so they work without color-mix): --sd-c-wash is the section colour at 4.5 %
   on white, a barely-there paper tint for full-bleed bands and panels behind a whole block;
   --sd-c-wash-2 is 9 %, the one stronger surface a screen may have. Outside a section both are a
   neutral paper. Use them as var(--sd-c-wash, transparent). Never behind single stories in a list;
   text colours and hairlines stay as they are. */
:root { --sd-c-wash: #fafaf8; --sd-c-wash-2: var(--ed-bg-2); }
.sd-sec-politika, [data-sec="politika"] { --sd-c-wash: #f5f6f8; --sd-c-wash-2: #eaedf0; }
.sd-sec-ekonomija, [data-sec="ekonomija"] { --sd-c-wash: #f4f9f8; --sd-c-wash-2: #e9f3f1; }
.sd-sec-tehnologija, [data-sec="tehnologija"] { --sd-c-wash: #f8f7fd; --sd-c-wash-2: #f1eefa; }
.sd-sec-kultura, [data-sec="kultura"] { --sd-c-wash: #fbf6f7; --sd-c-wash-2: #f7ecef; }
.sd-sec-sport, [data-sec="sport"] { --sd-c-wash: #fef8f5; --sd-c-wash-2: #fdf2ea; }
.sd-sec-magazin, [data-sec="magazin"] { --sd-c-wash: #f4f9fa; --sd-c-wash-2: #e9f3f5; }
.sd-sec-kujna, [data-sec="kujna"] { --sd-c-wash: #fdfaf5; --sd-c-wash-2: #fbf6ea; }
.sd-sec-igri, [data-sec="igri"] { --sd-c-wash: #f5f9fd; --sd-c-wash-2: #ebf2fb; }
.sd-sec-play, [data-sec="play"] { --sd-c-wash: #fcf6f9; --sd-c-wash-2: #f9ecf4; }

/* Refined colour (owner, 2026-11-26), precomputed so it works everywhere:
   --sd-c-2   the section colour turned 25 degrees round the oklch hue circle (the faint second hue
              of a glow); neutral grey outside a section.
   --sd-line  a hairline that sits on a wash: the section colour at 22 % on white (grey outside).
   --sd-dark  a deep, slightly coloured near-black for dark surfaces (never #000); --sd-on-dark text on it. */
:root { --sd-c-2: #8a8a8a; --sd-line: var(--ed-line); --sd-dark: #15131a; --sd-on-dark: #f4f1f6; }
.sd-sec-politika, [data-sec="politika"] { --sd-c-2: #2f2e5a; --sd-line: #c7cfda; --sd-dark: #0f1420; }
.sd-sec-ekonomija, [data-sec="ekonomija"] { --sd-c-2: #03787a; --sd-line: #cfe1da; --sd-dark: #0d1714; }
.sd-sec-tehnologija, [data-sec="tehnologija"] { --sd-c-2: #8a32ae; --sd-line: #d9d7f6; --sd-dark: #14111f; }
.sd-sec-kultura, [data-sec="kultura"] { --sd-c-2: #a3340f; --sd-line: #efd1d4; --sd-dark: #1a1013; }
.sd-sec-sport, [data-sec="sport"] { --sd-c-2: #c88305; --sd-line: #fde0d1; --sd-dark: #1b130e; }
.sd-sec-magazin, [data-sec="magazin"] { --sd-c-2: #3279a1; --sd-line: #d0e2e6; --sd-dark: #0e1618; }
.sd-sec-kujna, [data-sec="kujna"] { --sd-c-2: #b3aa22; --sd-line: #f6e9d4; --sd-dark: #19150c; }
.sd-sec-igri, [data-sec="igri"] { --sd-c-2: #6661d1; --sd-line: #d0e0f8; --sd-dark: #0f1320; }
.sd-sec-play, [data-sec="play"] { --sd-c-2: #cc264c; --sd-line: #f6d3e3; --sd-dark: #150c16; }

/* Gradient tokens (declared in every scope, so they follow the nearest section). Fallbacks first
   (the old hex washes); inside @supports the refined oklch versions with a soft glow.
   --sd-grad-top   a section's page top: wash-2 at the very top, through wash, to white, with a
                   faint glow of the second hue in the top right corner. For a view's first band
                   directly under the header (the header itself ends in wash-2).
   --sd-grad-band  a band across the page that fades sideways (wash-2 at the left to a paler right),
                   so it never reads as a flat stripe.
   --sd-grad-dark  a dark surface: --sd-dark with a magenta-to-violet glow (PLAY), never pure black. */
:root, [class*="sd-sec-"], [data-sec] {
  --sd-grad-top: linear-gradient(180deg, var(--sd-c-wash-2) 0%, var(--sd-c-wash) 45%, var(--ed-bg) 100%);
  --sd-grad-band: linear-gradient(90deg, var(--sd-c-wash-2) 0%, var(--sd-c-wash) 60%, var(--sd-c-wash) 100%);
  --sd-grad-dark: radial-gradient(90% 120% at 0% 0%, #3a1236 0%, transparent 60%), radial-gradient(80% 120% at 100% 100%, #23164a 0%, transparent 60%), var(--sd-dark);
}
@supports (color: color-mix(in oklch, red 50%, blue)) {
  :root, [class*="sd-sec-"], [data-sec] {
    --sd-grad-top:
      radial-gradient(70% 140% at 100% 0%, color-mix(in oklch, var(--sd-c-2) 9%, transparent) 0%, transparent 70%),
      linear-gradient(180deg, var(--sd-c-wash-2) 0%, var(--sd-c-wash) 45%, color-mix(in oklch, var(--sd-c-wash) 40%, var(--ed-bg)) 75%, var(--ed-bg) 100%);
    --sd-grad-band:
      radial-gradient(60% 160% at 0% 50%, color-mix(in oklch, var(--sd-c) 5%, transparent) 0%, transparent 70%),
      radial-gradient(45% 140% at 100% 0%, color-mix(in oklch, var(--sd-c-2) 6%, transparent) 0%, transparent 70%),
      linear-gradient(90deg, var(--sd-c-wash-2) 0%, var(--sd-c-wash) 55%, color-mix(in oklch, var(--sd-c-wash) 60%, var(--ed-bg)) 100%);
    --sd-grad-dark:
      radial-gradient(80% 110% at 0% 0%, color-mix(in oklch, #c02c83 34%, transparent) 0%, transparent 62%),
      radial-gradient(70% 120% at 100% 100%, color-mix(in oklch, #6544c8 30%, transparent) 0%, transparent 60%),
      var(--sd-dark);
  }
  [class*="sd-sec-"], [data-sec] { --sd-line: color-mix(in oklch, var(--sd-c) 22%, #fff); }
}

/* Ready-made wash surfaces. .sd-wash: a full-bleed band (put it on a full-width element and keep an
   .ed-wrap inside); --strong uses wash-2; .sd-wash-top: the page-top gradient (--sd-grad-top);
   .sd-wash-band: the sideways band (--sd-grad-band); .sd-dark: the dark surface. Hairlines on a
   wash take --sd-line. */
.sd-wash { background: var(--sd-c-wash, transparent); }
.sd-wash--strong { background: var(--sd-c-wash-2, transparent); }
.sd-wash-top { background: var(--sd-grad-top); }
.sd-wash-band { background: var(--sd-grad-band); }
.sd-dark { background: var(--sd-grad-dark); color: var(--sd-on-dark); }
:where(.sd-wash, .sd-wash--strong, .sd-wash-top, .sd-wash-band) :where(.ed-rule--light, .ed-list > li + li, .ed-cols > * + *) { border-color: var(--sd-line); }

/* Kickers take the colour of the section they stand in; live and urgent labels stay red. */
[data-sec] > .ed-kicker:not(.ed-kicker--live):not(.ed-kicker--quiet):not(.ed-kicker--ink),
[data-sec] .ed-story__body > .ed-kicker:not(.ed-kicker--live):not(.ed-kicker--quiet):not(.ed-kicker--ink) { color: var(--sd-c-text); }
[data-sec] .ed-kicker:not(.ed-kicker--live):not(.ed-kicker--quiet):not(.ed-kicker--ink) a:hover { color: var(--sd-c); }

/* Badge of the newsroom's own work (Ексклузивно, Интервју, Анализа...) */
.sd-badge {
  display: inline-block;
  margin: 0 8px 6px 0;
  padding: 3px 7px 2px;
  font-family: var(--ed-sans);
  font-size: 0.625rem;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--sd-on);
  background: var(--sd-c);
  border-radius: 2px;
}

/* ------------------------------------------------------------------ 15. Motion (the shared contract)
 * Calm, editorial, never a demo: transform and opacity (plus one clip-path wipe for pictures),
 * 180 to 520ms on --ed-motion, nothing loops, the first screen never animates in. core.js switches
 * it on by adding html.js-motion once its IntersectionObserver runs; without JS, without
 * IntersectionObserver and under prefers-reduced-motion nothing is ever hidden or moved. An element
 * the observer has not reached within 2.5s of being scrolled past is shown anyway (core.js).
 *
 * data-reveal            fades up 12px when it first enters the viewport (520ms).
 * data-reveal="stagger"  its direct children do that instead, in reading order (70ms steps, at most 6).
 * data-reveal="image"    a picture opens with a short wipe from the top (clip-path) while it settles
 *                        from 1.04 to 1; put it on the media box (.ed-media or a figure).
 * data-reveal="rule"     a hairline / rule draws in from the left (scaleX).
 * style="--i:N"          a manual step for any [data-reveal] element or a stagger child (capped at 6).
 * Inside a revealed block, ranked-list numerals and section-head titles slide in 6px from the left.
 * data-parallax="0.12"   (0.05 to 0.2) wrapper whose layer (the [data-parallax-layer] child, else the
 *                        first img/picture/video, else the first child) drifts with the scroll, from
 *                        1024px, only while in view. The wrapper clips; the layer is scaled to hide
 *                        the edges. A [data-parallax] inside another is a second depth (a caption, a
 *                        wash behind the picture): it moves itself at its own rate, measured by the
 *                        outer wrapper, never scaled. Where the browser has scroll-driven animations
 *                        (animation-timeline: view()) the CSS below drives it and core.js only sets
 *                        --plx-amp / --plx-s; elsewhere core.js drives it. Never both.
 * data-indicator         on a row of tabs or links: an active bar slides between items (core.js).
 * .ed-zoom               a media wrapper whose picture grows by 3 % on hover (desktop pointers).
 */
:root { --ed-step: 70ms; }
html.js-motion [data-reveal]:not([data-reveal="stagger"]):not([data-reveal="image"]):not([data-reveal="rule"]):not(.is-in),
html.js-motion [data-reveal="stagger"]:not(.is-in) > * {
  opacity: 0;
  transform: translate3d(0, 12px, 0);
}
html.js-motion [data-reveal]:not([data-reveal="stagger"]):not(.is-done),
html.js-motion [data-reveal="stagger"]:not(.is-done) > * {
  transition: opacity var(--ed-motion-dur) var(--ed-motion), transform var(--ed-motion-dur) var(--ed-motion), clip-path var(--ed-motion-dur) var(--ed-motion);
  transition-delay: calc(min(var(--i, 0), 6) * var(--ed-step));
}
/* Pictures: a wipe from the top and a settle from 1.04. */
html.js-motion [data-reveal="image"]:not(.is-in) { clip-path: inset(0 0 100% 0); }
html.js-motion [data-reveal="image"] :is(img, video) { transition: transform var(--ed-motion-dur) var(--ed-motion), opacity 0.2s var(--ed-ease); transition-delay: calc(min(var(--i, 0), 6) * var(--ed-step)); }
html.js-motion [data-reveal="image"]:not(.is-in) :is(img, video) { transform: scale(1.04); }
html.js-motion [data-reveal="image"].is-in:not(.is-done) { clip-path: inset(0 0 0 0); }
/* Rules draw in from the left. */
html.js-motion [data-reveal="rule"] { transform-origin: 0 50%; }
html.js-motion [data-reveal="rule"]:not(.is-in) { transform: scaleX(0); }
/* Inside a block that reveals: numerals and section labels slide 6px. */
html.js-motion [data-reveal] :is(.ed-ranked > li)::before,
html.js-motion [data-reveal] .ed-section-head__title { transition: opacity 420ms var(--ed-motion), transform 420ms var(--ed-motion); transition-delay: calc(min(var(--i, 0), 6) * var(--ed-step) + 120ms); }
html.js-motion [data-reveal]:not(.is-in) :is(.ed-ranked > li)::before,
html.js-motion [data-reveal]:not(.is-in) .ed-section-head__title,
html.js-motion [data-reveal="stagger"]:not(.is-in) > * .ed-section-head__title { opacity: 0; transform: translate3d(-6px, 0, 0); }
html.js-motion [data-reveal].is-done :is(.ed-ranked > li)::before,
html.js-motion [data-reveal].is-done .ed-section-head__title { transition: none; }

:where([data-parallax]) { position: relative; overflow: hidden; }
:where([data-parallax] [data-parallax]) { overflow: visible; }
:where([data-parallax] [data-parallax-layer]) { transform-origin: 50% 50%; }

/* Scroll-driven parallax (core.js marks the box with data-plx-box and the layer with data-plx-on,
   and sets --plx-amp in px and --plx-s, only where animation-timeline: view() is supported). */
@supports (animation-timeline: view()) {
  @media (min-width: 1024px) and (prefers-reduced-motion: no-preference) {
    html.js-plx-css [data-plx-box] { view-timeline: --ed-plx block; }
    html.js-plx-css [data-plx-on] {
      animation: ed-plx linear both;
      animation-timeline: --ed-plx;
      animation-range: cover 0% cover 100%;
      will-change: transform;
    }
  }
}
@keyframes ed-plx {
  from { transform: translate3d(0, calc(-1 * var(--plx-amp, 0px)), 0) scale(var(--plx-s, 1)); }
  to { transform: translate3d(0, var(--plx-amp, 0px), 0) scale(var(--plx-s, 1)); }
}

/* Pictures fade in when they have decoded instead of popping (lazy pictures only: never the first
   screen's, never the LCP image; core.js marks them). */
html.js-motion img.ed-fadein:not(.is-loaded) { opacity: 0; }
html.js-motion img.ed-fadein { transition: opacity 360ms var(--ed-motion), transform 420ms var(--ed-motion); }

/* The sliding indicator of a [data-indicator] row: core.js adds .has-indicator and one
   .ed-indicator bar; a row's own per-item underline can then step aside (.has-indicator ...). */
:where([data-indicator]) { position: relative; }
.ed-indicator {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100px;
  height: 2px;
  background: var(--ed-ink);
  transform-origin: 0 50%;
  pointer-events: none;
  opacity: 0;
  transition: transform 320ms var(--ed-motion), opacity 180ms var(--ed-ease), background-color 180ms var(--ed-ease);
}
.ed-indicator.is-on { opacity: 1; }
.ed-indicator.is-instant { transition: none; }

/* Back to top: a quiet round control after two screens (core.js adds it). */
.ed-totop {
  position: fixed;
  right: max(16px, env(safe-area-inset-right));
  bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 90;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--sd-line, var(--ed-line-2));
  border-radius: 50%;
  background: var(--ed-bg);
  color: var(--ed-ink);
  box-shadow: 0 1px 2px rgb(0 0 0 / 0.06);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translate3d(0, 8px, 0);
  transition: opacity 240ms var(--ed-motion), transform 320ms var(--ed-motion), visibility 0s linear 320ms, border-color 180ms var(--ed-ease), color 180ms var(--ed-ease);
}
/* Shown (core.js): on phones only while the reader scrolls back up, never over the footer, which has
   its own «Назад кон врвот». */
.ed-totop.is-on { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
.ed-totop:hover { border-color: var(--sd-c, var(--ed-ink)); color: var(--sd-c-text, var(--ed-ink)); }
.ed-totop:focus-visible { outline: 2px solid var(--sd-focus, var(--ed-accent)); outline-offset: 3px; }
.ed-totop svg { transition: transform 180ms var(--ed-motion); }
.ed-totop:hover svg { transform: translate3d(0, -2px, 0); }
.ed-totop:active { transform: translateY(1px) scale(0.96); }
@media (min-width: 1024px) {
  .ed-totop { right: 24px; bottom: 24px; }
}
@media (prefers-reduced-motion: reduce) {
  .ed-totop, .ed-totop svg { transition: none; }
  .ed-totop:hover svg, .ed-totop:active { transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  html.js-motion [data-reveal]:not(.is-in),
  html.js-motion [data-reveal="stagger"]:not(.is-in) > *,
  html.js-motion [data-reveal]:not(.is-in) :is(.ed-ranked > li)::before,
  html.js-motion [data-reveal]:not(.is-in) .ed-section-head__title,
  html.js-motion [data-reveal="image"]:not(.is-in) :is(img, video) { opacity: 1; transform: none; clip-path: none; }
  html.js-motion img.ed-fadein:not(.is-loaded) { opacity: 1; }
}
@media print {
  html.js-motion [data-reveal],
  html.js-motion [data-reveal] > *,
  html.js-motion [data-reveal] img { opacity: 1 !important; transform: none !important; clip-path: none !important; }
  html.js-motion img.ed-fadein { opacity: 1 !important; }
  .ed-totop { display: none; }
}

/* Same-origin navigation cross-fades where the browser supports it (progressive enhancement). */
@view-transition { navigation: auto; }
::view-transition-old(root),
::view-transition-new(root) { animation-duration: 0.24s; animation-timing-function: var(--ed-motion); }
@media (prefers-reduced-motion: reduce) {
  @view-transition { navigation: none; }
  ::view-transition-old(root),
  ::view-transition-new(root) { animation: none; }
}
