/* ═══════════════════════════════════════════════════════════════════════
   NanoFarm · СОВРЕМЕННЫЙ СЛОЙ (2026-11)
   Язык, выросший из карточки товара «цвет прибора»: мягкий фон, белые
   «острова» с тонкой линией и радиусом 20, тонированные окна под медиа,
   капсульные кнопки, кнопка-стрелка в круге, подъём + цветная тень на hover.
   Подключается последним. Шрифты и фирменные цвета — без изменений.
   ═══════════════════════════════════════════════════════════════════════ */

html body {
  --m-bg: #f4f5f5;
  --m-card: #ffffff;
  --m-window: #eef2f2;
  --m-line: rgba(55, 53, 54, 0.09);
  --m-line-2: rgba(55, 53, 54, 0.16);
  --m-text: #1f1e1f;
  --m-muted: #6f6c6a;
  --m-teal: #4da0a9;
  --m-teal-ink: #2f7f88;
  --m-teal-soft: rgba(77, 160, 169, 0.12);
  --m-r: 20px;
  --m-r-lg: 28px;
  --m-lift: 0 22px 44px -26px rgba(47, 127, 136, 0.45);
  --m-ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}
html[data-theme="dark"] body {
  --m-bg: #1a191a;
  --m-card: #242324;
  --m-window: #2e2d2e;
  --m-line: rgba(255, 255, 255, 0.08);
  --m-line-2: rgba(255, 255, 255, 0.14);
  --m-text: #f2f1f0;
  --m-muted: #a6a3a1;
  --m-teal-ink: #6fb8c0;
  --m-teal-soft: rgba(77, 160, 169, 0.16);
  --m-lift: 0 22px 44px -24px rgba(0, 0, 0, 0.8);
}

/* ── единый фон страниц, без цветных полос между секциями ── */
html body,
html body .nf-app,
html body .nf-main,
html body #page-root { background-color: var(--m-bg) !important; }
html body .nf-home-section,
html body .section--lowered,
html body .section--layer-clean,
html body .section--layer-showcase,
html body .section--layer-editorial { background: transparent !important; background-image: none !important; box-shadow: none !important; }
html body .nf-home-section::before,
html body .nf-home-section::after { display: none !important; }

/* ── заголовки секций главной ── */
html body .nf-home-section-head { align-items: flex-end !important; margin-bottom: 28px !important; }
html body .nf-home-section-head__title {
  font-size: clamp(26px, 2.4vw, 34px) !important;
  font-weight: 700 !important;
  letter-spacing: -0.02em !important;
  line-height: 1.1 !important;
  color: var(--m-text) !important;
}
html body .nf-home-section-head__sub,
html body .nf-home-section-head__text p { color: var(--m-muted) !important; }

/* ── капсульная кнопка «все …» со стрелкой в круге ── */
html body .nf-home-link-secondary,
html body .nf-home-section .nf-home-link-secondary.nf-home-link-secondary.nf-home-link-secondary {
  height: 42px !important;
  padding: 0 6px 0 18px !important;
  gap: 12px !important;
  border-radius: 999px !important;
  background: var(--m-card) !important;
  border: 1px solid var(--m-line) !important;
  box-shadow: none !important;
  color: var(--m-text) !important;
  font-size: 13.5px !important;
  font-weight: 600 !important;
  transition: border-color 0.3s, transform 0.3s var(--m-ease) !important;
}
html body .nf-home-link-secondary::after {
  content: "→";
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--m-teal-soft);
  color: var(--m-teal-ink);
  font-size: 14px;
  transition: background-color 0.3s, color 0.3s;
}
html body .nf-home-link-secondary svg,
html body .nf-home-link-secondary .nf-home-link-secondary__arrow { display: none !important; }
html body .nf-home-link-secondary:hover { border-color: rgba(77, 160, 169, 0.5) !important; }
html body .nf-home-link-secondary:hover::after { background: var(--m-teal); color: #fff; }

/* ── главный экран ── */
html body section.nf-hero.nf-hero--brand,
html body .nf-home-firstscreen.nf-first-screen .nf-hero.nf-hero--brand,
html body .nf-first-screen > .nf-hero.nf-hero--brand,
html body .nf-home-firstscreen {
  background: var(--m-bg) !important;
  background-color: var(--m-bg) !important;
  box-shadow: none !important;
  border: 0 !important;
}
html:not([data-theme="dark"]) body .nf-hero-wm-wash {
  background:
    radial-gradient(ellipse 70% 80% at 78% 40%, rgba(77, 160, 169, 0.12), transparent 62%),
    var(--m-bg) !important;
}
html body .nf-hero__years-pill {
  display: inline-flex !important;
  align-items: center;
  gap: 8px;
  padding: 7px 14px 7px 10px !important;
  border-radius: 999px !important;
  background: var(--m-card) !important;
  border: 1px solid var(--m-line) !important;
  color: var(--m-text) !important;
  font-weight: 600 !important;
}
html body .nf-hero__years-pill::before {
  content: "" !important;
  position: static !important;
  width: 8px !important;
  height: 8px !important;
  border-radius: 50% !important;
  background: var(--m-teal) !important;
  box-shadow: 0 0 0 4px var(--m-teal-soft) !important;
  inset: auto !important;
}
html body .nf-hero-btn {
  height: 50px !important;
  border-radius: 999px !important;
  font-weight: 600 !important;
  transition: transform 0.3s var(--m-ease), box-shadow 0.3s, background-color 0.3s !important;
}
html body .nf-hero-btn--primary {
  background: var(--m-teal) !important;
  background-image: none !important;
  border: 0 !important;
  color: #fff !important;
  box-shadow: 0 14px 30px -14px rgba(77, 160, 169, 0.8) !important;
}
html body .nf-hero-btn--primary:hover { transform: translateY(-2px); }
html body .nf-hero-btn--secondary {
  background: var(--m-card) !important;
  border: 1px solid var(--m-line-2) !important;
  color: var(--m-text) !important;
  box-shadow: none !important;
}
html body .nf-hero-btn--secondary:hover { border-color: rgba(77, 160, 169, 0.55) !important; }

/* ── плитки направлений (главная) ── */
html body .pfg-card.pfg-card--tile {
  border-radius: var(--m-r) !important;
  background: var(--m-card) !important;
  border: 1px solid var(--m-line) !important;
  box-shadow: none !important;
  padding: 22px !important;
  transition: transform 0.35s var(--m-ease), box-shadow 0.35s, border-color 0.35s !important;
}
html body .pfg-card.pfg-card--tile::after { display: none !important; }
html body .pfg-card--tile .pfg-card__icon {
  width: 48px !important;
  height: 48px !important;
  border-radius: 14px !important;
  background: var(--m-teal-soft) !important;
  color: var(--m-teal-ink) !important;
  box-shadow: none !important;
  border: 0 !important;
}
html body .pfg-card--tile .pfg-card__wm { opacity: 0.5; }
html body .pfg-card--tile .pfg-card__name { font-size: 17px !important; font-weight: 650 !important; letter-spacing: -0.01em; color: var(--m-text) !important; }
html body .pfg-card--tile .pfg-card__desc { color: var(--m-muted) !important; }
@media (hover: hover) {
  html body .pfg-card.pfg-card--tile:hover {
    transform: translateY(-4px);
    border-color: rgba(77, 160, 169, 0.45) !important;
    box-shadow: var(--m-lift) !important;
  }
  html body .pfg-card.pfg-card--tile:hover .pfg-card__icon { background: var(--m-teal) !important; color: #fff !important; }
}

/* ── партнёры: слайдер на главной ── */
html body .nf-ps {
  border-radius: var(--m-r-lg) !important;
  background: var(--m-card) !important;
  border: 1px solid var(--m-line) !important;
  box-shadow: none !important;
  overflow: hidden;
}
html body .nf-ps__tag {
  border-radius: 999px !important;
  padding: 5px 11px !important;
  background: var(--m-teal-soft) !important;
  color: var(--m-teal-ink) !important;
  border: 0 !important;
  font-weight: 600 !important;
}
html body .nf-ps__name { font-size: 24px !important; font-weight: 700 !important; letter-spacing: -0.02em !important; color: var(--m-text) !important; }
html body .nf-ps__desc { color: var(--m-muted) !important; }
html body .nf-ps__logo {
  border-radius: 18px !important;
  background: var(--m-window) !important;
  padding: 18px !important;
  border: 0 !important;
}
html body .nf-ps__cta {
  height: 42px !important;
  padding: 0 20px !important;
  border-radius: 999px !important;
  background: var(--m-text) !important;
  color: var(--m-card) !important;
  border: 0 !important;
  box-shadow: none !important;
  font-weight: 600 !important;
}
html body .nf-ps__cta:hover { background: var(--m-teal) !important; color: #fff !important; }
html body .nf-ps__dot { border-radius: 999px !important; transition: width 0.3s var(--m-ease), background-color 0.3s !important; }
html body .nf-ps__dot.is-active { width: 22px !important; background: var(--m-teal) !important; }

/* ── новости на главной ── */
html body .nf-hn-featured {
  border-radius: var(--m-r-lg) !important;
  background: var(--m-card) !important;
  border: 1px solid var(--m-line) !important;
  box-shadow: none !important;
  overflow: hidden !important;
  transition: transform 0.35s var(--m-ease), box-shadow 0.35s, border-color 0.35s !important;
}
@media (hover: hover) {
  html body .nf-hn-featured:hover { transform: translateY(-4px); border-color: rgba(77, 160, 169, 0.4) !important; box-shadow: var(--m-lift) !important; }
}
html body .nf-hn-item {
  padding: 14px 14px !important;
  margin: 0 -14px !important;
  border-radius: 16px !important;
  border: 0 !important;
  transition: background-color 0.25s !important;
}
html body .nf-hn-item::before { display: none !important; }
html body .nf-hn-item:hover { background: var(--m-card) !important; }

/* ── подвал: тёмный «остров» с закруглением ── */
html body .nf-footer {
  margin: 48px 16px 16px !important;
  border-radius: var(--m-r-lg) !important;
  overflow: hidden !important;
  background: #1f1e1f !important;
  border: 0 !important;
}
html[data-theme="dark"] body .nf-footer { background: #141314 !important; border: 1px solid rgba(255, 255, 255, 0.06) !important; }
html body .nf-footer-cta-panel {
  border-radius: var(--m-r) !important;
  background: rgba(255, 255, 255, 0.05) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: none !important;
}
html body .nf-footer-cta-panel button,
html body .nf-footer-cta-panel .nf-btn { border-radius: 999px !important; }

/* ── общие карточки разделов: один язык острова ── */
html body .nf-prt,
html body .nf-pm-card,
html body .nf-ps2-head,
html body .nf-ps2-other,
html body .news-featured-card,
html body .nf-about-audience-item,
html body .nf-about-value,
html body .nf-about-mission-note,
html body .nf-contact-card,
html body .nf-map-card,
html body .nf-contacts-hub,
html body .nf-contacts-info-extra,
html body .nf-epdp-group,
html body .nf-epdp-relcard,
html body header.news-page-hero {
  border-radius: var(--m-r) !important;
  border: 1px solid var(--m-line) !important;
  box-shadow: none !important;
}
html body .nf-prt,
html body .nf-pm-card,
html body .nf-ps2-other,
html body .news-featured-card,
html body .nf-epdp-relcard {
  transition: transform 0.35s var(--m-ease), box-shadow 0.35s, border-color 0.35s !important;
}
@media (hover: hover) {
  html body .nf-prt:hover,
  html body .nf-pm-card:hover,
  html body .nf-ps2-other:hover,
  html body .news-featured-card:hover,
  html body .nf-epdp-relcard:hover {
    transform: translateY(-4px);
    border-color: rgba(77, 160, 169, 0.45) !important;
    box-shadow: var(--m-lift) !important;
  }
}
html body .nf-about-hero,
html body .nf-ps2-head { border-radius: var(--m-r-lg) !important; }

/* ── кнопки по сайту: капсулы ── */
html body .nf-btn,
html body .nf-epdp-cta,
html body .nf-pc__more,
html body #quickQuoteBtn,
html body .nf-catalog-strip__back,
html body .pfg-card__cta,
html body .nf-add-request { border-radius: 999px !important; }

/* ── поля ввода и модальные окна ── */
html body .nf-modal-inner,
html body .nf-qq-shell { border-radius: var(--m-r-lg) !important; overflow: hidden; }
html body .nf-input,
html body .nf-qq-input,
html body .nf-modal-inner textarea,
html body .nf-qq-shell textarea { border-radius: 14px !important; }
html body .nf-cart-panel { border-radius: var(--m-r-lg) 0 0 var(--m-r-lg) !important; }

/* ── страница товара: вторичные блоки ── */
html body .nf-epdp-seg,
html body .nf-epdp-app,
html body .nf-epdp-chip { border-radius: 999px !important; }
html body .nf-epdp-mode { border-radius: 16px !important; }
html body .nf-epdp-stage,
html body .nf-hs__frame { border-radius: var(--m-r-lg) !important; }

/* ═══ «Популярная продукция»: без рамки, мягкие края, линия прокрутки ═══ */
html body .nf-popular__carousel-wrap {
  display: flex !important;
  flex-direction: column !important;
  padding: 0 !important;
  background: none !important;
  border: 0 !important;
  box-shadow: none !important;
  overflow: visible !important;
}
html body .nf-popular__carousel-wrap::before,
html body .nf-popular__carousel-wrap::after { display: none !important; }
html body .nf-popular__viewport.nf-popular__viewport--carousel {
  padding: 18px 0 30px !important;
  margin: -18px 0 -30px !important;
  overflow: hidden !important;
  touch-action: pan-y;
  cursor: grab;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 4%, #000 96%, transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0, #000 4%, #000 96%, transparent 100%);
}
html body .nf-popular__viewport.is-dragging { cursor: grabbing; }
html body .nf-popular__viewport.is-dragging .nf-dc { pointer-events: none; }
html body .nf-popular__track.nf-popular__track--carousel { padding: 0 !important; user-select: none; -webkit-user-select: none; }
html body .nf-popular__track .nf-dc img { -webkit-user-drag: none; user-select: none; }

/* строка под каретой: линия прогресса + две маленькие стрелки */
html body .nf-popular__nav {
  position: static !important;
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  margin-top: 26px !important;
  padding: 0 !important;
  transform: none !important;
  pointer-events: auto !important;
}
html body .nf-popular__progress {
  position: relative;
  flex: 1;
  height: 3px;
  margin-right: 16px;
  border-radius: 999px;
  background: var(--m-line);
  overflow: hidden;
}
html body .nf-popular__progress span {
  position: absolute;
  top: 0;
  bottom: 0;
  border-radius: 999px;
  background: var(--m-teal);
}
html body .nf-popular__nav .nf-popular__nav-btn.nf-popular__nav-btn {
  position: static !important;
  transform: none !important;
  width: 40px !important;
  height: 40px !important;
  min-width: 40px !important;
  margin: 0 !important;
  opacity: 1 !important;
}

/* страница товара: сцена с фото не шире экрана (на телефоне была фиксированная 480px) */
html body .nf-epdp-hero__media { min-width: 0 !important; }
html body .nf-epdp-hero__media .nf-epdp-stage { width: 100% !important; max-width: 100% !important; }

/* анимация смены языка: весь текст в одной строчной обёртке */
html body .nf-i18n-run { display: inline !important; white-space: inherit; }
