/*
 * UA: smila.in.ua — оформлення міського сайту поверх теми ядра (nt-news.css).
 * UA: Палітра, логотип і дрібниці взяті з діючого сайту на InstantCMS 2, щоб після
 * UA: переходу на ядро allMarket читач бачив той самий «Смілянський базар»:
 * UA: бірюзово-зелений #2b9578 (напис «СМІЛЯНСЬКИЙ» у логотипі), червоний #c0392b («БАЗАР»),
 * UA: графітовий текст #363636 і світле тло #f5f6f6.
 * EN: smila.in.ua — the city site's look on top of the core's theme (nt-news.css).
 * UA: Файл підключено в template/b2b-b2c/header.htm одразу після nt-news.css.
 * UA: 2026-11-25
 */

:root {
  --nt-accent:    #2b9578;          /* UA: бірюза логотипа — посилання, кнопки, рубрики */
  --nt-accent-h:  #217a62;
  --nt-ink:       #363636;          /* UA: графітовий текст старого сайту */
  --nt-ink-2:     #5a6166;
  --nt-surface-2: #f5f6f6;
  --nt-line:      #dfe3e4;
  --nt-line-2:    #eceeee;
  /* UA: Діючий сайт набрано гротеском (Arial, sans-serif) — засічок немає ніде.
     UA: Тема ядра тримає заголовки на --nt-serif, тож достатньо перевизначити саму змінну:
     UA: разом із нею без засічок стають і логотип, і заголовки блоків, і заголовки матеріалів.
     EN: The live site is set in a sans (Arial, sans-serif) — no serifs anywhere. The core's theme
     EN: keeps its headings on --nt-serif, so redefining that one variable is enough: the logo,
     EN: the block headings and the article headlines all turn sans with it. */
  --nt-serif:     "Segoe UI", Roboto, Arial, "Helvetica Neue", Helvetica, sans-serif;
  --nt-sans:      "Segoe UI", Roboto, Arial, "Helvetica Neue", Helvetica, sans-serif;
  --sm-red:       #c0392b;          /* UA: червоний «БАЗАР» — другий акцент */
  --sm-red-h:     #a33125;
  --nt-shadow:    0 1px 2px rgba(54,54,54,.06), 0 8px 24px rgba(54,54,54,.07);
}

:root[data-am-theme="dark"] {
  --nt-accent:    #45b795;
  --nt-accent-h:  #5fc7a8;
  --sm-red:       #e05a4c;
  --sm-red-h:     #ef7568;
  /* UA: світлі значення з :root вище писалися під денну тему, але в ній же й лишалися
     UA: вночі: у nt-news.css темна палітра оголошена як [data-am-theme="dark"], і цей файл,
     UA: підключений пізніше, перебивав її з тією самою вагою. Тому повертаємо темні
     UA: поверхні, текст і лінії — інакше в темній темі світлішали цілі блоки.
     EN: the light values in the :root above were written for the day theme but stayed on at
     EN: night: nt-news.css declares the dark palette as [data-am-theme="dark"], and this file,
     EN: loaded later, overrode it at equal weight. The dark surfaces, text and lines come back
     EN: here — otherwise whole blocks turned light in the dark theme. */
  --nt-ink:       #eceef1;
  --nt-ink-2:     #a8b0bb;
  --nt-surface-2: #1c2025;
  --nt-line:      #2a2f36;
  --nt-line-2:    #22262c;
  --nt-shadow:    0 1px 2px rgba(0,0,0,.4), 0 10px 30px rgba(0,0,0,.35);
}

/* UA: логотип smila-bazar.webp — 585×200 (≈2.9:1); висота підібрана так, щоб напис
   UA: «СМІЛЯНСЬКИЙ БАЗАР» читався так само, як на діючому сайті
   EN: the smila-bazar.webp logo is 585×200 (≈2.9:1); the height is picked so the wordmark
   EN: reads the way it does on the live site */
/* UA: логотип без власного фону — крізь нього видно шапку й панораму, тож під знак
   UA: кладемо м'яку світлу тінь: на світлій шапці вона дає обʼєм, на темному тлі
   UA: підвалу — легке сяйво, і напис не зливається з тлом.
   EN: the logo has no background of its own, so a soft light shadow goes under the mark:
   EN: on the light header it gives depth, on the footer's dark graphite a gentle glow. */
.nt-brand__img {
  max-height: 64px; width: auto;
  filter: drop-shadow(0 1px 1px rgba(255, 255, 255, .95))
          drop-shadow(0 0 5px rgba(255, 255, 255, .75))
          drop-shadow(0 2px 3px rgba(0, 0, 0, .14));
}
@media (max-width: 720px) { .nt-brand__img { max-height: 46px; } }
/* UA: у підвалі тінь світліша й ширша — знак темний, графіт теж */
.nt-brand--foot .nt-brand__img {
  height: auto; max-height: 56px;
  filter: drop-shadow(0 0 2px rgba(255, 255, 255, .95))
          drop-shadow(0 0 4px rgba(255, 255, 255, .85))
          drop-shadow(0 0 10px rgba(255, 255, 255, .5));
}

/* UA: у темній темі чорний силует логотипа зник би — ставимо його на світлу підкладку */
:root[data-am-theme="dark"] .nt-brand {
  background: #fff;
  border-radius: 10px;
  padding: 6px 12px;
}

/* UA: рубрикатор — як на старому сайті: смужка акцентом під активною рубрикою */
.nt-nav__i.is-on, .nt-nav a:hover { color: var(--nt-accent); }
.nt-kick--ed { color: var(--nt-ink); }
.nt-kick--ed::before { background: var(--sm-red); }

/* UA: «гарячі» позначки (кримінал, війна) лишаються червоними, решта — бірюзовими */
.nt-badge--hot { background: var(--sm-red); }

/* ======================================================================
 * UA: ПЕРЕНЕСЕННЯ ОФОРМЛЕННЯ ДІЮЧОГО smila.in.ua (InstantCMS 2, тема news,
 * UA: схема color-green). Зміряні значення старої теми:
 * UA:   #layout     — біла коробка 1250px із тінню 0 0 5px rgba(0,0,0,.9)
 * UA:   body        — панорама Сміли, center 0, no-repeat, fixed, на білому
 * UA:   #topmenu    — смуга #f5f6f6, 12px bold, рядок 33px, активне #2b9578
 * UA:   .widget     — білий, рамка 1px, заголовок 12px bold UPPERCASE з пунктиром
 * UA:   a.more      — зелена рамка, на наведення заливається зеленим
 * EN: The port of the live smila.in.ua design (InstantCMS 2, the "news" theme,
 * EN: the color-green scheme); the values above are measured from that theme.
 * UA: 2026-11-25
 * ====================================================================== */

:root {
  /* UA: ширина коробки: у старого сайту було 1250px, але на теперішніх екранах
     UA: лишалося забагато порожніх полів — беремо 1560px, а на вужчих вікнах
     UA: коробка сама стискається до 96% ширини вікна.
     EN: the box's width: the old site had 1250px, which leaves too much empty margin on
     EN: today's screens — 1560px, shrinking to 96% of the window on narrower ones. */
  --sm-wrap:   min(1560px, 96vw);
  --sm-bar:    #f5f6f6;       /* UA: смуга рубрик */
  --sm-bar-on: rgba(54,54,54,.82);  /* UA: та сама смуга, коли прилипла вгорі */
}

/* ---------- панорама міста під сторінкою ---------- */
/* UA: Панорама — окремий закріплений шар, а не background-attachment:fixed на body.
   UA: Закріплене тло браузер перемальовує на кожному кадрі прокрутки (та ще й масштабує
   UA: під cover), через що сторінка смикається. Псевдоелемент із position:fixed лягає
   UA: в окремий композитний шар: прокрутка рівна, а вигляд той самий.
   UA: Селектор саме body.am — у nt-news.css тло задане так само, і просте body програє вагою.
   EN: The panorama is a separate fixed layer rather than background-attachment:fixed on the body.
   EN: A fixed background is repainted on every scroll frame (and rescaled to cover), which makes
   EN: the page stutter. A position:fixed pseudo-element gets its own compositing layer: the scroll
   EN: stays smooth and the look is the same. The selector must be body.am — nt-news.css sets the
   EN: background the same way and a bare body loses on weight. */
html { background: #fff; }
body.am { background: transparent; }
body.am::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background: #fff url("../images/bg-smila.webp") center center no-repeat;
  background-size: cover;
  pointer-events: none;
}
:root[data-am-theme="dark"] html { background: #101215; }
:root[data-am-theme="dark"] body.am::before { background-color: #101215; opacity: .5; }

/* ---------- біла коробка сторінки ---------- */
/* UA: сама коробка прозора — між білими картками видно панораму, як на діючому сайті
   EN: the box itself is transparent — the panorama shows between the white cards, as on the live site */
.sm-page {
  max-width: var(--sm-wrap);
  margin: 0 auto;
  box-shadow: 0 0 5px rgba(0,0,0,.9);
  background: transparent;
}
/* UA: смуги шапки й підвалу лишаються суцільними */
/* UA: шапка напівпрозора — крізь неї, як і крізь підвал, просвічує панорама міста.
   UA: Молочно-білий із 82% непрозорості: текст лишається контрастним, а місто вгадується.
   EN: the header is semi-transparent — the city's panorama shows through it, as through the footer.
   EN: Milky white at 82% opacity: the text stays contrasty while the city shows behind. */
.nt-top, .nt-mast { background: rgba(255, 255, 255, .82); }

/* UA: блоки стрічки — білі картки з рамкою, як .widget старої теми */
.nt-lead__main, .nt-strip, .nt-ad {
  background: var(--nt-surface);
  border: 1px solid var(--nt-line);
  padding: 15px;
}
/* UA: .nt-lead — лише сітка «головне + колонка», рамки на ній не треба */
.nt-lead { margin-bottom: 20px; }
.nt-strip { margin-bottom: 20px; }
.nt-main { padding-top: 14px; padding-bottom: 14px; }
/* UA: проміжок між смугою меню й першою карткою — там видно панораму */
.sm-page > main, .sm-page > .nt-page { padding-left: 10px; padding-right: 10px; }
/* UA: смуги всередині коробки більше не на всю ширину екрана */
.sm-page .nt-wrap { max-width: calc(var(--sm-wrap) - 40px); }

/* UA: Шапка, смуга рубрик і біжучий рядок стоять ПОЗА коробкою і йдуть на всю ширину вікна:
   UA: сама смуга суцільна від краю до краю, а вміст у ній притиснутий до країв з полями 24px.
   EN: The header, the rubric bar and the ticker live OUTSIDE the box and span the whole window:
   EN: the bar runs edge to edge while its content sits against the edges with 24px gutters. */
.nt-top__in, .nt-mast__in, .nt-nav__in, .nt-foot__in, .nt-foot__bot {
  max-width: none;
  padding-left: max(24px, env(safe-area-inset-left));
  padding-right: max(24px, env(safe-area-inset-right));
}
.sm-tick { padding-left: 0; }
.sm-tick__v { padding-right: 24px; }
/* UA: на дуже широких екранах не розтягуємо нескінченно — меню стає нечитним */
@media (min-width: 1900px) {
  .nt-top__in, .nt-mast__in, .nt-nav__in, .nt-foot__in, .nt-foot__bot { max-width: 1840px; margin: 0 auto; }
}
/* UA: на вузькому екрані коробка притискається до країв — але панорама лишається:
   UA: вона видно між білими картками так само, як на діючому сайті.
   EN: on a narrow screen the box meets the edges, yet the panorama stays: it shows
   EN: between the white cards exactly as it does on the live site. */
/* UA: коли коробка впирається в краї вікна, тінь по боках ні до чого */
@media (max-width: 1620px) { .sm-page { box-shadow: none; } }

/* ---------- верхній рядок: дата, посилання, соцмережі ---------- */
.nt-top__in { gap: 10px; }
.sm-soc { display: inline-flex; gap: 6px; margin-left: auto; align-items: center; }
.sm-soc a {
  display: inline-flex; width: 22px; height: 22px; border-radius: 50%;
  align-items: center; justify-content: center;
  background: var(--nt-surface-2); color: var(--nt-ink-2);
  transition: background .15s, color .15s;
}
.sm-soc a:hover { background: var(--nt-accent); color: #fff; }
.sm-soc svg { width: 13px; height: 13px; }

/* ---------- смуга рубрик, як #topmenu старої теми ---------- */
.nt-nav {
  background: rgba(245, 246, 246, .86);
  border-top: 1px solid var(--nt-line);
  border-bottom: 1px solid var(--nt-line);
}
.nt-nav__in { min-height: 33px; }
.nt-nav a {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .01em;
  line-height: 33px;
  padding: 0 15px;
  color: #5f5f5f;
}
.nt-nav a:hover, .nt-nav a.is-on { color: var(--nt-accent); background: #fff; }
/* UA: у темній темі шапка теж напівпрозора, але темна — інакше вийшов би молочний пласт */
:root[data-am-theme="dark"] .nt-top,
:root[data-am-theme="dark"] .nt-mast,
:root[data-am-theme="dark"] .sm-tick { background: rgba(22, 25, 29, .82); }
:root[data-am-theme="dark"] .nt-nav { background: rgba(30, 34, 39, .86); }
:root[data-am-theme="dark"] .nt-nav a { color: var(--nt-ink-2); }
:root[data-am-theme="dark"] .nt-nav a:hover,
:root[data-am-theme="dark"] .nt-nav a.is-on { background: var(--nt-surface); }

/* UA: «Сервіси міста» в меню — акцентом, як СЕРВІСИ на старому сайті */
.nt-nav__pb, .nt-nav__ads { color: var(--sm-red) !important; }
.nt-nav__pb:hover, .nt-nav__ads:hover { color: #fff !important; background: var(--sm-red) !important; }

/* ---------- біжучий рядок останніх новин ---------- */
.sm-tick {
  display: flex; align-items: center; gap: 12px;
  border-top: 1px solid var(--nt-line);
  background: rgba(255, 255, 255, .82);
  overflow: hidden;
}
.sm-tick__l {
  flex: none; font-size: 11px; font-weight: 700; text-transform: uppercase;
  letter-spacing: .04em; color: #fff; background: var(--sm-red);
  padding: 7px 12px;
}
.sm-tick__v { overflow: hidden; flex: 1; }
/* UA: Швидкість руху рядка — у точках за секунду (--sm-tick-speed): sm-tick.js рахує з неї
   UA: тривалість кола за справжньою шириною стрічки, тож довгі заголовки більше її не сповільнюють.
   UA: 34s у самому animation — запасний варіант, якщо скрипт не завантажився.
   EN: The strip's speed is in points per second (--sm-tick-speed): sm-tick.js works the lap time out
   EN: of it and of the strip's real width, so long headlines no longer slow it down.
   EN: The 34s in animation itself is the fallback for when the script has not loaded. */
.sm-tick__r { --sm-tick-speed: 200; display: flex; gap: 34px; white-space: nowrap; animation: sm-run 34s linear infinite; will-change: transform; }
.sm-tick:hover .sm-tick__r { animation-play-state: paused; }
.sm-tick__r a { font-size: 13px; color: var(--nt-ink-2); padding: 7px 0; text-decoration: none; }
.sm-tick__v { padding-right: 20px; }
.sm-tick__r a:hover { color: var(--nt-accent); }
@keyframes sm-run { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .sm-tick__r { animation: none; } }
@media (max-width: 720px) { .sm-tick { display: none; } }

/* ---------- блоки головної як віджети старої теми ---------- */
.nt-sec, .nt-block, .nt-rail, .nt-ad {
  background: var(--nt-surface);
}
.nt-sec {
  border: 1px solid var(--nt-line);
  padding: 0 15px 15px;
  margin: 0 0 20px;
  border-radius: 0;
}
/* UA: у темі ядра над заголовком блоку йде чорна смуга 3px — у старому оформленні її нема */
.nt-sec__h {
  border-top: 0;
  margin: 0 0 12px;
  padding: 10px 0 5px;
  border-bottom: 1px dotted var(--nt-line);
}
/* UA: назва блоку — 12px UPPERCASE, як .widget_title старої теми (а не серіфні 24px) */
.nt-sec__t, .nt-rail__h {
  font-family: var(--nt-sans);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .02em;
}
.nt-sec__t a { color: var(--nt-ink); }
.nt-sec__t a:hover { color: var(--nt-accent); }
.nt-rail__h { padding: 5px 0; border-bottom: 1px dotted var(--nt-line); }
.nt-rail {
  border: 1px solid var(--nt-line);
  padding: 0 15px 15px;
}

/* ---------- кнопка «ще», як a.more (лише посилання «усі», не назва блоку) ---------- */
.nt-sec__a, .nt-rail__h a {
  font-size: 12px;
  font-weight: 400;
  text-transform: none;
  border: 1px solid var(--nt-accent);
  border-radius: 2px;
  padding: 2px 8px;
  color: var(--nt-accent);
}
.nt-sec__a:hover, .nt-rail__h a:hover { background: var(--nt-accent); color: #fff; }

/* ---------- підвал: графітовий, як у старої теми ---------- */
/* UA: підвал напівпрозорий — крізь графіт просвічує панорама міста
   EN: the footer is semi-transparent — the city's panorama shows through the graphite */
.nt-foot {
  background: rgba(48, 48, 48, .78);
  color: #e3e5e5;
  border-top: 3px solid var(--nt-accent);
  margin-top: 40px;
}
.nt-foot a { color: #e8eaea; }
.nt-foot h3 { color: #fff; border-bottom: 1px dotted rgba(255,255,255,.22); padding-bottom: 6px; }
.nt-foot a:hover { color: #6fd3b4; }
.nt-foot__brand p { color: #cfd2d2; }
.nt-foot__bot { border-top: 1px solid rgba(255,255,255,.18); color: #c6c9c9; }
.nt-foot__bot a { color: #c6c9c9; }
/* UA: у підвалі логотип на білій плашці — інакше чорний силует зникає на графіті */
/* UA: нижній логотип теж без підкладки — біла плашка на графіті була милицею,
   UA: поки знак мав власний фон. Тепер його тримає світле сяйво по контуру. */
.nt-brand--foot { background: none; padding: 0; display: inline-block; }
:root[data-am-theme="dark"] .nt-foot { background: rgba(16, 19, 22, .78); }

/* ---------- випадайки меню, як у #topmenu старої теми ---------- */
/* UA: базова смуга рубрик — горизонтальний скрол (overflow-x:auto), а він обрізає все,
   UA: що виходить за межі смуги, тож випадайка просто не була видна. Пунктів лише п'ять —
   UA: скрол не потрібен: даємо смузі видимі краї, а на вузькому екрані вона переноситься.
   EN: The base rubric strip scrolls horizontally (overflow-x:auto), and that clips anything
   EN: leaving the strip, so the dropdown was simply invisible. There are only five items —
   EN: no scrolling is needed: the strip gets visible overflow and wraps on a narrow screen. */
.sm-menu { flex-wrap: wrap; overflow: visible; }
.sm-m { position: relative; display: inline-flex; }
.sm-m > a { display: inline-flex; align-items: center; gap: 5px; }
.sm-m__c {
  width: 0; height: 0; border: 4px solid transparent;
  border-top-color: currentColor; margin-top: 3px;
}
.sm-m__d {
  position: absolute; left: 0; top: 100%; z-index: 600;
  display: none; min-width: 210px;
  background: var(--sm-bar);
  border: 1px solid #a4adad;
  border-top: 2px solid var(--nt-accent);
  box-shadow: 0 6px 14px rgba(0,0,0,.18);
  padding: 4px 0;
}
.sm-m:hover .sm-m__d, .sm-m:focus-within .sm-m__d, .sm-m.is-open .sm-m__d { display: block; }
/* UA: стрілка повертається, коли випадайку розгорнуто пальцем */
.sm-m.is-open .sm-m__c { transform: rotate(180deg); }
.sm-m__d a {
  display: block; line-height: 28px; padding: 0 12px;
  font-size: 12px; font-weight: 700; text-transform: uppercase;
  white-space: nowrap;
}
.sm-m__d a:hover, .sm-m__d a.is-on { background: #fff; color: var(--nt-accent); }
:root[data-am-theme="dark"] .sm-m__d { background: var(--nt-surface-2); border-color: var(--nt-line); }
:root[data-am-theme="dark"] .sm-m__d a:hover { background: var(--nt-surface); }

/* UA: на вузькому екрані смуга меню горизонтально прокручується, а не ламається */
/* UA: телефон — смуга переноситься на два рядки, випадайка розкривається на всю ширину
   EN: On a phone the strip wraps onto two rows and the dropdown opens across the full width */
@media (max-width: 900px) {
  .sm-menu { overflow: visible; }
  .sm-m { position: static; }
  .sm-m__d {
    left: 0; right: 0; width: auto; min-width: 0;
    max-height: 60vh; overflow-y: auto;
    column-count: 2; column-gap: 0;
  }
  .sm-m__d a { font-size: 11px; white-space: normal; }
}

/* ---------- шапка: логотип ліворуч, як на діючому сайті ---------- */
@media (min-width: 721px) {
  .nt-mast__in { grid-template-columns: auto 1fr auto; padding-block: 14px 12px; }
  .nt-brand { order: 1; justify-self: start; text-align: left; }
  .nt-mast__l { order: 2; justify-self: end; max-width: 360px; width: 100%; }
  .nt-mast__r { order: 3; justify-self: end; }
}

/* ---------- посилання: графіт, зелений на наведення (як a в color-green.css) ---------- */
.nt-main a, .nt-h a, .nt-list a, .nt-live a { color: var(--nt-ink); }
.nt-main a:hover, .nt-h a:hover, .nt-list a:hover, .nt-live a:hover { color: var(--nt-accent); }
.nt-kick { color: var(--nt-accent); }
.nt-kick:hover { color: var(--nt-accent-h); }

/* ---------- сторінка матеріалу: текст на білій картці над панорамою ---------- */
.nt-art__main, .nt-box, .nt-crumbs {
  background: var(--nt-surface);
  border: 1px solid var(--nt-line);
  padding: 15px;
}
.nt-crumbs { margin-bottom: 20px; padding: 8px 15px; font-size: 12px; }
.nt-art__cols { padding-top: 20px; }
.nt-box { margin-bottom: 20px; }
.nt-box__h, .nt-aside h3 {
  font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .02em;
  padding: 5px 0; border-bottom: 1px dotted var(--nt-line); margin: 0 0 12px;
}

/* ---------- решта розділів (проблеми, оголошення, довідка, сторінки) ---------- */
.am-main, .am-legacy .columns-container {
  background: var(--nt-surface);
  border: 1px solid var(--nt-line);
  padding: 18px;
  margin-top: 20px;
  margin-bottom: 20px;
}
/* UA: у цих розділах уже є власні картки — подвійних рамок не робимо */
.am-main .pb-card, .am-main .hp-topic, .am-main .ct-card { border-color: var(--nt-line); }

/* ======================================================================
 * UA: Головний блок новин — слайдер діючого сайту: велике фото з написом
 * UA: унизу й стовпчик із пʼяти мініатюр праворуч (widget_content_slider).
 * EN: The main news block — the live site's slider: a big photo with the
 * EN: caption at its foot and a column of five thumbnails at the right.
 * ====================================================================== */
.sm-hero {
  display: grid;
  grid-template-columns: minmax(0, 2.4fr) minmax(0, 1fr);
  background: var(--nt-surface);
  border: 1px solid var(--nt-line);
  padding: 15px;
  gap: 15px;
  margin-bottom: 20px;
}
.sm-hero__big { position: relative; overflow: hidden; background: #000; aspect-ratio: 16 / 9; }
.sm-hero__s {
  position: absolute; inset: 0; display: block; text-decoration: none;
  opacity: 0; visibility: hidden; transition: opacity .45s ease;
}
.sm-hero__s.is-on { opacity: 1; visibility: visible; }
.sm-hero__s img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sm-hero__cap {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 2;
  padding: 44px 18px 16px;
  background: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,.78) 65%);
  color: #fff;
}
.sm-hero__k {
  display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase; background: var(--sm-red); padding: 2px 8px; margin-bottom: 8px;
}
.sm-hero__cap strong {
  display: block; font-family: var(--nt-serif); font-size: 26px; line-height: 1.22; font-weight: 700;
}
.sm-hero__cap i {
  display: block; font-style: normal; font-size: 13.5px; line-height: 1.45;
  color: rgba(255,255,255,.84); margin-top: 7px;
}
.sm-hero__cap time { color: rgba(255,255,255,.6); margin-left: 6px; font-size: 12.5px; }
.sm-hero__s:hover .sm-hero__cap strong { color: #8ee3c4; }

.sm-hero__list { display: grid; grid-template-rows: repeat(5, minmax(0, 1fr)); gap: 8px; }
.sm-hero__t {
  display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 9px; align-items: center;
  background: none; border: 0; border-left: 3px solid transparent;
  padding: 4px 4px 4px 7px; text-align: left; cursor: pointer; font: inherit; color: inherit;
  transition: background .15s, border-color .15s;
}
.sm-hero__t:hover { background: var(--nt-surface-2); }
.sm-hero__t.is-on { background: var(--nt-surface-2); border-left-color: var(--nt-accent); }
.sm-hero__th { display: block; aspect-ratio: 5 / 3; overflow: hidden; background: var(--nt-surface-2); }
.sm-hero__th img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sm-hero__tt { font-size: 12.5px; line-height: 1.32; color: var(--nt-ink); }
.sm-hero__t.is-on .sm-hero__tt { color: var(--nt-accent); font-weight: 600; }

@media (max-width: 900px) {
  .sm-hero { grid-template-columns: minmax(0, 1fr); }
  .sm-hero__list { grid-template-rows: none; grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .sm-hero__t { grid-template-columns: minmax(0, 1fr); border-left: 0; border-top: 3px solid transparent; }
  .sm-hero__t.is-on { border-top-color: var(--nt-accent); }
  .sm-hero__cap strong { font-size: 19px; }
  .sm-hero__cap i { display: none; }
}
@media (max-width: 560px) {
  .sm-hero__list { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .sm-hero__tt { display: none; }
}

/* ---------- дочищення залишків базової теми ---------- */
/* UA: у смузі рубрик ядро лишає прозору смужку 3px під пунктом і зсув -2px */
.nt-nav a { border-bottom: 0; margin-bottom: 0; }
/* UA: колонка «Останні» вже в рамці — лінія ліворуч від ядра зайва */
.nt-rail { border-left: 1px solid var(--nt-line); padding-left: 15px; }
.nt-rail__h { margin: 0 0 10px; }
.nt-sec__t { margin: 0; }
/* UA: «хлібні крихти» стали карткою — відступ знизу беремо свій */
.nt-crumbs { margin: 0 0 20px; }

/* ---------- гротеск у заголовках: дрібні поправки після зміни гарнітури ---------- */
.nt-h, .nt-art__h, .nt-phead h1, .nt-sec__t, .sm-hero__cap strong {
  letter-spacing: -.01em;
}
.nt-art__h, .nt-phead h1 { font-weight: 700; }

/* ===================================================================
   UA: Рубрики по вкладках — як віджет widget_tabbed на діючому smila.in.ua:
   UA: смуга назв рубрик угорі картки, активна підсвічена, під нею вміст рубрики.
   EN: The rubrics in tabs — like the widget_tabbed widget on the live smila.in.ua:
   EN: a strip of rubric names atop the card, the active one lit, the rubric's content below.
   =================================================================== */
.sm-tabw { padding: 0; }
.sm-tabw__nav {
  display: flex; flex-wrap: wrap; gap: 0;
  background: var(--sm-bar);
  border-bottom: 1px solid #e3e5e5;
}
.sm-tabw__b {
  appearance: none; -webkit-appearance: none;
  border: 0; border-right: 1px solid #e3e5e5;
  background: transparent; cursor: pointer;
  padding: 0 16px; height: 36px; line-height: 36px;
  font: 700 12px/36px var(--nt-sans);
  text-transform: uppercase; letter-spacing: .04em;
  color: var(--nt-ink); white-space: nowrap;
  transition: background .15s, color .15s;
}
.sm-tabw__b:hover { color: var(--nt-accent); }
/* UA: активна вкладка — як на діючому сайті: білий «язичок» із зеленою рискою зверху */
.sm-tabw__b.is-on {
  background: #fff; color: var(--nt-accent);
  box-shadow: inset 0 3px 0 var(--nt-accent);
}
.sm-tabw__b:focus-visible { outline: 2px solid var(--nt-accent); outline-offset: -2px; }

.sm-tabw__p { padding: 16px; }
.sm-tabw__p[hidden] { display: none; }
.sm-tabw__all {
  display: inline-block; margin-top: 4px;
}
/* UA: усередині вкладки картка рубрики вже без власної рамки — рамку тримає сама вкладка */
.sm-tabw .nt-block { border: 0; padding: 0; }

/* UA: телефон — смуга вкладок прокручується вбік, як стрічка рубрик у шапці */
@media (max-width: 720px) {
  .sm-tabw__nav {
    flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .sm-tabw__nav::-webkit-scrollbar { display: none; }
  .sm-tabw__p { padding: 12px; }
}

/* ===================================================================
   UA: Підкладка під матеріали на сторінках списку (рубрика, теги, пошук, блоги):
   UA: заголовок, смуга сортування й сама стрічка стоять на білих картках над панорамою —
   UA: раніше текст лежав просто на фоні міста, як на сторінці матеріалу до правки.
   EN: The plate under the material on listing pages (rubric, tags, search, blogs):
   EN: the heading, the sort strip and the feed itself stand on white cards over the panorama.
   =================================================================== */
.nt-page > .nt-phead,
.nt-page > .nt-sorts,
.nt-cols > div:first-child {
  background: var(--nt-surface);
  border: 1px solid var(--nt-line);
  padding: 15px;
}
/* UA: заголовок рубрики — без «газетної» чорної риски, картка її вже замінює */
.nt-page > .nt-phead {
  border-bottom: 1px solid var(--nt-line);
  padding-bottom: 15px;
  margin-bottom: 20px;
}
/* UA: коли під заголовком стоїть смуга сортування — зшиваємо їх в одну картку */
.nt-page > .nt-phead:has(+ .nt-sorts) { border-bottom: 0; margin-bottom: 0; }
.nt-page > .nt-sorts { border-top: 0; margin: 0 0 20px; padding: 10px 15px; }
/* UA: банер усередині колонки вже на картці — без другої рамки в рамці */
.nt-cols > div:first-child > .nt-ad {
  background: transparent; border: 0; padding: 14px 0 0; margin: 0;
}
.nt-cols > div:first-child > .nt-pager { margin-bottom: 0; }
@media (max-width: 720px) {
  .nt-page > .nt-phead, .nt-page > .nt-sorts, .nt-cols > div:first-child { padding: 12px; }
}

/* ===================================================================
   UA: Перший ряд головної, як на діючому smila.in.ua: ліворуч вузька колонка
   UA: «Коментарі» (віджет col-4), праворуч головні новини (col-8).
   EN: The home page's first row, as on the live smila.in.ua: the narrow "Comments"
   EN: column on the left (the col-4 widget), the top news on the right (col-8).
   =================================================================== */
/* UA: обидві картки одного зросту: нижні краї «Коментарів» і головних новин збігаються.
   EN: both cards are the same height: the bottom edges of "Comments" and the top news line up. */
/* UA: «Коментарі» ліворуч від головних новин: було 1fr+2fr (третина ширини), стало 2fr+7fr —
   на третину вужче (2/9 ширини), решту віддано головному блоку новин */
.sm-top { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 7fr); gap: 20px; align-items: stretch; margin: 0 0 20px; }
.sm-top--solo { grid-template-columns: minmax(0, 1fr); }
/* UA: велике фото тягнеться за висотою ряду, стрічка мініатюр лишається п'ятьма рівними рядками */
.sm-top .sm-hero { margin: 0; align-content: stretch; }
.sm-top .sm-hero__big { aspect-ratio: auto; min-height: 320px; }

.sm-comm { border: 1px solid var(--nt-line); background: var(--nt-surface); padding: 0 12px 10px;
  display: flex; flex-direction: column; }
.sm-comm__h { display: flex; align-items: baseline; justify-content: space-between; gap: 8px;
  padding: 10px 0 5px; margin-bottom: 8px; border-bottom: 1px dotted var(--nt-line); }
.sm-comm__h h2 { margin: 0; font: 700 12px/1.3 var(--nt-sans); text-transform: uppercase; letter-spacing: .04em; }
.sm-comm__h h2 a { color: var(--nt-ink); text-decoration: none; }
.sm-comm__h h2 a:hover { color: var(--nt-accent); }
.sm-comm__a { font-size: 11px; color: var(--nt-accent); text-decoration: none; white-space: nowrap; }
/* UA: п'ять записів розходяться по всій висоті картки, щоб низ збігся з новинами */
.sm-comm__l { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px;
  flex: 1 1 auto; align-content: space-between; }
.sm-comm__l li + li { border-top: 1px dotted var(--nt-line); padding-top: 10px; }
/* UA: колонка вужча на третину — мініатюра теж менша, щоб заголовку лишалося місце */
.sm-comm__l a { display: grid; grid-template-columns: 62px minmax(0, 1fr); gap: 8px; text-decoration: none; color: inherit; }
.sm-comm__l a:only-child { align-items: start; }
.sm-comm__c { display: block; aspect-ratio: 5 / 3; overflow: hidden; background: var(--nt-surface-2); }
.sm-comm__c img { width: 100%; height: 100%; object-fit: cover; display: block; }
/* UA: без світлини текст займає всю ширину картки */
.sm-comm__l a:not(:has(.sm-comm__c)) { grid-template-columns: minmax(0, 1fr); }
.sm-comm__t { display: block; min-width: 0; }
.sm-comm__t b { display: block; font: 700 13px/1.3 var(--nt-sans); color: var(--nt-ink); }
.sm-comm__l a:hover .sm-comm__t b { color: var(--nt-accent); }
.sm-comm__t i { display: block; font-style: normal; font-size: 12px; line-height: 1.35; color: var(--nt-ink-2); margin-top: 3px; }
.sm-comm__t time { display: block; font-size: 11px; color: var(--nt-ink-3); margin-top: 3px; }

/* UA: планшет і телефон — «Коментарі» стають під головними новинами */
@media (max-width: 900px) {
  .sm-top { grid-template-columns: minmax(0, 1fr); }
  .sm-comm { order: 2; }
  .sm-top .sm-hero { order: 1; }
  /* UA: у стовпчик вирівнювати нема з чим — велике фото повертає свої пропорції */
  .sm-top .sm-hero__big { aspect-ratio: 16 / 9; min-height: 0; }
}

/* ===================================================================
   UA: Розділювач розділів — той самий, що .block_name1…5 у діючому smila.in.ua:
   UA: тонка лінія на всю ширину з кольоровим «язичком» ліворуч. Кольори з
   UA: color-green.css старої теми: 1 помаранчевий, 2 графіт, 3 блакитний,
   UA: 4 сірий, 5 зелений. Назву розділу можна писати в язичку, можна лишати порожнім.
   EN: A section divider — the same as .block_name1…5 on the live smila.in.ua:
   EN: a thin full-width line with a coloured tab on the left. The colours come from the
   EN: old theme's color-green.css. The tab may carry the section's name or stay empty.
   =================================================================== */
.sm-div {
  overflow: hidden;
  margin: 26px 0 12px;
  border-width: 0 0 1px;
  border-style: solid;
  border-color: #363636;
}
.sm-div span {
  display: block; float: left; overflow: hidden;
  font: 700 12px/1.2 var(--nt-sans);
  letter-spacing: .04em; text-transform: uppercase;
  margin-right: 2px; padding: 8px;
  min-width: 8px; min-height: 16px;
  background: #363636; color: #fff;
}
.sm-div a { color: #fff; text-decoration: none; }
.sm-div--1 { border-color: #d35400; } .sm-div--1 span { background: #d35400; }
.sm-div--2 { border-color: #363636; } .sm-div--2 span { background: #363636; }
.sm-div--3 { border-color: #6ca7dd; } .sm-div--3 span { background: #6ca7dd; }
.sm-div--4 { border-color: #777;    } .sm-div--4 span { background: #777;    }
.sm-div--5 { border-color: var(--nt-accent); } .sm-div--5 span { background: var(--nt-accent); }
/* UA: перший розділювач на сторінці не відсуває вміст від шапки */
.nt-main > .sm-div:first-child { margin-top: 10px; }
:root[data-am-theme="dark"] .sm-div--2 { border-color: #8b9090; }
:root[data-am-theme="dark"] .sm-div--2 span { background: #5a6060; }

/* ---------- блок «Головне»: по одній новині з кожної рубрики ---------- */
/* UA: по одній найсвіжішій новині з кожної рубрики — дві колонки під головними новинами
   EN: one freshest item from every rubric — two columns under the top news */
.sm-rubs { border-top: 1px solid var(--nt-line); padding-top: 14px; }
.sm-rubs__h {
  margin: 0 0 12px; font: 700 12px/1.3 var(--nt-sans); text-transform: uppercase;
  letter-spacing: .04em; color: var(--nt-ink-2);
}
.sm-rubs__h span { border-bottom: 2px solid var(--sm-red); padding-bottom: 4px; }
.sm-rubs__g { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 26px; }
.sm-rub { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 12px; align-items: start; }
.sm-rub:not(:has(.sm-rub__c)) { grid-template-columns: minmax(0, 1fr); }
.sm-rub__c { display: block; aspect-ratio: 5 / 3; overflow: hidden; background: var(--nt-surface-2); }
.sm-rub__c img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sm-rub__t { min-width: 0; }
.sm-rub .nt-kick { display: inline-block; margin-bottom: 2px; }
.sm-rub .nt-h { font-size: 15px; line-height: 1.3; margin: 0 0 4px; }
.sm-rub .nt-meta { margin: 0; font-size: 11px; }
@media (max-width: 720px) {
  .sm-rubs__g { grid-template-columns: minmax(0, 1fr); }
}
