/* ==========================================================================
   Perfect Moments — design system (dark theme)
   Reproduces the real Tilda-based production site: Merriweather serif,
   dark graphite backgrounds, ghost (outline) buttons, coral accent links,
   turquoise floating chat button.
   ========================================================================== */

:root {
  --color-bg: #292929;          /* main section background (graphite) */
  --color-bg-soft: #333333;     /* alternating section background */
  --color-bg-about: #363636;    /* description-block background, shared by unified blocks */
  --color-footer: #454545;      /* footer background (lighter grey) */
  --color-header: #292929;

  --color-text: #ffffff;
  --color-text-secondary: #b0b0b0;
  --color-text-muted: #8a8a8a;

  --color-border: rgba(255, 255, 255, 0.22);
  --color-border-soft: rgba(255, 255, 255, 0.1);
  --color-surface: rgba(255, 255, 255, 0.05);

  --color-accent: #9a7b3f;      /* premium dark gold (links & hovers) */
  --color-accent-2: #fa876b;

  --color-whatsapp: #27d061;
  --color-telegram: #1d98dc;
  --color-vk: #4c75a3;

  --font-serif: 'Merriweather', Georgia, 'Times New Roman', serif;

  --container-width: 1200px;
  --radius: 8px;
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body, h1, h2, h3, h4, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img {
  max-width: 100%;
  display: block;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
  -webkit-user-drag: none;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }

html {
  scrollbar-gutter: stable;
}

body {
  font-family: var(--font-serif);
  font-weight: 300;
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 400;
  color: var(--color-text);
  text-transform: uppercase;
  line-height: 1.1;
  overflow-wrap: break-word;
  word-break: break-word;
}

.container {
  width: 100%;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 20px;
}

.section {
  padding: 51px 0;
  background: var(--color-bg);
}

.section--muted {
  background: var(--color-bg-soft);
}

.section--about-bg,
.section--categories,
.section--posts-grid,
.section--smi {
  background: var(--color-bg-about);
}

.section--images,
.section--description,
.section--gallery-categories,
.section--video-categories,
.section--pricing,
.section--article,
.section--posts-grid,
.section--smi,
.section--about-bg,
.section--categories,
.section--faq,
.section--category-slider,
.section--posts-slider,
.section--gallery-slider,
.section--video-album-slider,
.stats-section,
.advantages,
.reviews-section {
  padding-top: 0;
}

.section--divider {
  padding: 0;
  height: 51px;
}

.section--divider.block--dark {
  background: var(--color-bg-about);
}

.section--divider.block--light {
  background: #ffffff;
}

.section--divider.block--grey {
  background: #ebebeb;
}

.section-heading {
  font-size: clamp(22px, 3vw, 32px);
  text-align: center;
  margin-bottom: 40px;
}

.services .section-heading,
.stats-section .section-heading,
.photos-section .section-heading,
.videos-section .section-heading,
.section--categories .section-heading,
.section--services .section-heading,
.section--elements .section-heading,
.section--images .section-heading,
.section--posts-grid .section-heading {
  text-align: left;
  font-size: clamp(25px, 3.45vw, 37px);
}

/* `images` block heading: fixed 40px/400/1.2 on desktop, 24px on mobile (see the
   max-width: 720px override below) — overrides the clamp() above. */
.section--images .section-heading {
  font-size: 40px;
  font-weight: 400;
  line-height: 1.2;
  margin-bottom: 20px;
}

/* `video_all` ("Видео — альбомы") heading→cards gap matched to the `images`
   block's standard 20px (was inheriting the generic 40px, twice the target). */
.section--video-categories .section-heading {
  margin-bottom: 20px;
}

/* Standard 20px heading→content gap (same reference as `images`/`video_all`/
   `team-section` above) — site-wide audit, every remaining heading+content
   block was still inheriting the generic 40px `.section-heading` default. */
.section--categories .section-heading,
.section--services .section-heading,
.section--elements .section-heading,
.section--posts-grid .section-heading,
.section--faq .section-heading,
.section--smi .section-heading,
.section--description .section-heading,
.section--category-slider .section-heading,
.section--posts-slider .section-heading,
.section--gallery-slider .section-heading,
.section--video-album-slider .section-heading,
.stats-section .section-heading,
.advantages .section-heading,
.reviews-section .section-heading {
  margin-bottom: 20px;
}

.reviews-section .section-heading,
.press-section .section-heading {
  text-align: left;
}

.section--description .section-heading,
.section--faq .section-heading,
.section--smi .section-heading {
  text-align: left;
}

/* FAQ block caps come from CSS only — the stored title is normal case (the global
   `h1,h2,h3,h4` rule already uppercases it; stated explicitly so the block doesn't
   depend on that rule). The question label has its own rule below. */
.section--faq .section-heading {
  text-transform: uppercase;
}

.section-subheading {
  font-family: var(--font-serif);
  font-weight: 400;
  text-transform: uppercase;
  text-align: center;
  font-size: clamp(16px, 2vw, 22px);
  letter-spacing: 0.03em;
  color: #1a1a1a;
  margin-top: -30px;
  margin-bottom: 40px;
}

.section-lead {
  text-align: center;
  max-width: 720px;
  margin: -20px auto 40px;
  color: var(--color-text-secondary);
}

/* ---- Buttons (ghost style) ---- */
.btn {
  display: inline-block;
  max-width: 100%;
  font-family: var(--font-serif);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  font-size: 21px;
  padding: 25px 60px;
  border-radius: var(--radius);
  border: 2px solid var(--color-text);
  background: rgba(0, 0, 0, 0.3);
  color: var(--color-text);
  text-align: center;
  -webkit-appearance: none;
  appearance: none;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.btn:hover {
  background: var(--color-text);
  color: var(--color-bg);
}

.btn--outline {
  border-color: var(--color-border);
}

.btn--block {
  display: block;
  width: 100%;
}

.btn-wrap {
  text-align: center;
  margin-top: 32px;
}

/* «Показать ещё» (images block pagination, templates/site/blocks/images.html).
   A secondary control under the photo grid, so it gets a regular button size
   instead of the shared 21px/25×60 hero/CTA size — same family/weight/case/
   letter-spacing/radius/2px border. Fixed line-height + min-width keep the box
   identical when the label swaps to the shorter «Загрузка…» (no layout shift).
   Hovers are scoped per theme: the base `.btn:hover` white fill would vanish on
   the light (#fff) section. */
/* gallery-load-more.js removes the button after the last batch — drop its now
   empty wrapper too so the grid ends on the section's own bottom padding. */
.btn-wrap:not(:has(*)) {
  display: none;
}

.btn-wrap .btn[data-load-more] {
  font-size: 16px;
  line-height: 1.5;
  padding: 14px 36px;
  min-width: 260px;
  white-space: nowrap;
}

.btn-wrap .btn[data-load-more]:disabled {
  opacity: 0.7;
  cursor: default;
}

.btn-wrap .btn[data-load-more]:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
}

/* Dark: 50% white border (4.8:1 on #292929; the --color-border 22% outline was
   2:1); hover/focus = the site's inverted white fill. */
.section--images.block--dark .btn[data-load-more] {
  border-color: rgba(255, 255, 255, 0.5);
}

.section--images.block--dark .btn[data-load-more]:hover:not(:disabled),
.section--images.block--dark .btn[data-load-more]:focus-visible {
  background: var(--color-text);
  border-color: var(--color-text);
  color: var(--color-bg);
}

/* Light: same soft CTA as .section--more-ideas / light intro / «Кнопка»
   (1px #e6e6e6 border, #4a4a4a text); hover = their soft gold tint + accent
   border, but with a deeper gold text so 16px bold stays ≥4.5:1 on the tint
   (the plain accent the 21px siblings use is 3.6:1 there). Images blocks have
   no grey theme (Block.BLOCKS_WITH_GREY_THEME). */
.section--images.block--light .btn[data-load-more] {
  border: 1px solid #e6e6e6;
  color: #4a4a4a;
  background: rgba(0, 0, 0, 0.04);
}

.section--images.block--light .btn[data-load-more]:hover:not(:disabled),
.section--images.block--light .btn[data-load-more]:focus-visible {
  background: rgba(154, 123, 63, 0.1);
  border-color: var(--color-accent);
  color: #7d6230;
}

/* While loading the hover look is suppressed (the pointer is still on it). */
.section--images .btn[data-load-more]:disabled:hover {
  background: rgba(0, 0, 0, 0.3);
  color: var(--color-text);
}

.section--images.block--light .btn[data-load-more]:disabled:hover {
  background: rgba(0, 0, 0, 0.04);
  color: #4a4a4a;
}

@media (max-width: 640px) {
  /* Same 14px/0.02em as the site's mobile buttons (.section--button), a bit
     less padding since this one is inline, not full-width. */
  .btn-wrap {
    margin-top: 24px;
  }

  .btn-wrap .btn[data-load-more] {
    font-size: 14px;
    letter-spacing: 0.02em;
    padding: 13px 28px;
    min-width: 220px;
  }
}

/* ---- Кнопка (full-width button block) ---- */
.section--button {
  text-align: center;
  /* No top padding: the block sits flush against the previous block's own
     bottom spacing instead of stacking a second gap on top of it. */
  padding-top: 0;
}

/* Light colour scheme (see breadcrumbs for the source colours) — only
   background/text colours change, sizing/layout stays identical. */
.section--button.block--light {
  background: #ffffff;
}

.section--button.block--light .btn,
.section--button.block--grey .btn {
  /* Same soft CTA as `.section--more-ideas.block--light .btn` and the light intro. */
  border: 1px solid #e6e6e6;
  color: #4a4a4a;
  background: rgba(0, 0, 0, 0.04);
}

/* Soft gold-tinted highlight instead of a hard white-to-black fill. */
.section--button.block--light .btn:hover {
  background: rgba(154, 123, 63, 0.1);
  border-color: var(--color-accent);
  color: var(--color-accent);
}

/* Grey colour scheme (the divider's #ebebeb surface) — a light surface, so it reuses the
   light ink above; only the background differs, plus hovers use the AA-safe darker gold
   #7d6230 (4.8:1 on #ebebeb; the regular #9a7b3f accent drops to 3.3:1 there). */
.section--button.block--grey {
  background: #ebebeb;
}

.section--button.block--grey .btn:hover {
  background: rgba(154, 123, 63, 0.1);
  border-color: #7d6230;
  color: #7d6230;
}

@media (max-width: 640px) {
  /* Smaller font so the (uppercase, letter-spaced) button text stays on one
     line instead of wrapping onto a second, which makes the block bulky. */
  .section--button .btn,
  .more-ideas__cta .btn {
    font-size: 14px;
    letter-spacing: 0.02em;
    padding: 16px 20px;
    white-space: nowrap;
  }
}

/* ---- Breadcrumbs ---- */
.breadcrumbs-block.block--dark {
  background: var(--color-bg-about);
}

.breadcrumbs-block.block--light {
  background: #ffffff;
}

.breadcrumbs-block.block--grey {
  background: #ebebeb;
}

.breadcrumbs {
  padding: 20px 0;
  font-size: 13px;
  color: var(--color-text-muted);
}

.breadcrumbs a {
  color: var(--color-text-muted);
}

.breadcrumbs a:hover {
  color: var(--color-accent);
}

.breadcrumbs .sep {
  margin: 0 8px;
}

/* Light colour scheme (see home's .services block for the source colours) — only
   background/text colours change, sizing/layout stays identical. */
.block--light .breadcrumbs,
.block--light .breadcrumbs a,
.block--grey .breadcrumbs,
.block--grey .breadcrumbs a {
  color: #1a1a1a;
}

.block--light .breadcrumbs a:hover {
  color: var(--color-accent);
}

.block--grey .breadcrumbs a:hover {
  color: #7d6230;
}

/* ==========================================================================
   Header
   ========================================================================== */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--color-header);
  border-bottom: 1px solid var(--color-border-soft);
  transition: background-color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.site-header--transparent {
  background: transparent;
  border-bottom-color: transparent;
}

.site-header.is-scrolled {
  background: #595959;
  border-bottom-color: var(--color-border-soft);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

main {
  padding-top: 104px;
}

/* Pages that lead with a full-bleed hero pull it back up under the
   fixed transparent header, so it overlays the hero exactly like home. */
main > .hero:first-child {
  margin-top: -104px;
}

/* Block anchor targets (hero button "На блок на этой странице") — offset the
   scroll landing spot so the fixed header doesn't cover the block's top. */
[id^="block-"] {
  scroll-margin-top: 104px;
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 24px;
  padding-bottom: 24px;
  gap: 16px;
}

.logo {
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 24px;
  letter-spacing: 0.12em;
  color: var(--color-text);
  text-transform: uppercase;
  white-space: nowrap;
  line-height: 1.1;
}

.logo__tagline {
  display: block;
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: 13px;
  letter-spacing: 0;
  text-transform: none;
  color: var(--color-text-secondary);
  margin-top: 2px;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 28px;
  margin-left: auto;
}

.site-phone {
  font-size: 19px;
  font-weight: 700;
  color: var(--color-text);
  white-space: nowrap;
}

.header-icons {
  display: flex;
  align-items: center;
  gap: 16px;
}

.header-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  color: var(--color-text);
  opacity: 0.9;
  transition: opacity 0.15s ease;
}

.header-icon:hover {
  opacity: 1;
}

.header-icon svg {
  width: 100%;
  height: 100%;
}

.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 26px;
  height: 22px;
  background: none;
  border: none;
  padding: 0;
}

.nav-toggle span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--color-text);
}

.site-nav__backdrop {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(0, 0, 0, 0.5);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.site-nav__backdrop.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.site-nav {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 300px;
  max-width: 85vw;
  z-index: 1001;
  display: flex;
  background: var(--color-footer);
  transform: translateX(100%);
  transition: transform 0.3s ease;
  overflow-y: auto;
}

.site-nav.is-open {
  transform: translateX(0);
}

.site-nav__close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  color: var(--color-text);
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
}

.site-nav__inner {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 32px;
  padding: 84px 24px 40px;
  text-align: left;
}

.site-nav__links {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 18px;
}

.site-nav__links a {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(18px, 2.4vw, 22px);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-text);
}

.site-nav__links a:hover {
  color: var(--color-accent);
}

.site-nav__tagline {
  font-family: var(--font-serif);
  font-style: normal;
  font-weight: 400;
  font-size: 14px;
  color: var(--color-text-secondary);
  margin-top: auto;
}

.site-nav__social {
  display: flex;
  align-items: center;
  gap: 28px;
}

.site-nav__social .header-icon {
  width: 26px;
  height: 26px;
}

/* ==========================================================================
   Hero — two-layer composition (background + cutout)
   ========================================================================== */

.hero {
  position: relative;
  overflow: hidden;
  width: 100%;
  min-height: 800px;
  background: #111;
}

.hero__bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
  -webkit-user-drag: none;
  pointer-events: none;
}

/* Anchored to .hero__content (fixed 1200px, centered) instead of the
   full-bleed .hero so it doesn't drift relative to the text/button on
   browser zoom. Box keeps cutout.png's 1.5:1 aspect ratio so
   object-fit:contain fills it with no letterboxing. Pinned via
   right/bottom to .hero__content's right boundary. */
.hero__cutout {
  position: absolute;
  z-index: -1;
  max-width: none;
  width: 1142.48px;
  height: 761.66px;
  object-fit: contain;
  object-position: bottom right;
  right: -310px;
  bottom: -124px;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
  -webkit-user-drag: none;
  pointer-events: none;
}

.hero__scrim {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 30%;
  z-index: 1;
  background: linear-gradient(0turn, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 1) 100%);
}

.hero__cutout-fade {
  display: none;
}

.hero__content {
  position: relative;
  z-index: 2;
  height: 100%;
  min-height: 800px;
  display: grid;
  align-content: center;
  justify-items: start;
  padding: 100px 20px 60px;
  max-width: var(--container-width);
  margin: 0 auto;
}

/* Wraps <h1 class="hero__title"> + the optional .hero__sticker badge. Kept transparent to
   layout (display:contents — generates no box of its own, so .hero__title/.hero__sticker
   stay direct children of .hero__content's grid exactly as before) everywhere except the
   ≤768px breakpoint below, where it becomes the sticker's positioned anchor so the badge
   overlaps the title plate's corner instead of floating relative to the whole hero. */
.hero__title-wrap {
  display: contents;
}

.hero__title {
  font-size: clamp(30px, 4vw, 50px);
  font-weight: 400;
  line-height: 1.1;
  max-width: 760px;
  color: var(--color-text);
  margin-bottom: 32px;
  hyphens: auto;
}

.hero__list {
  margin-bottom: 40px;
}

.hero__list li {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: clamp(18px, 2vw, 24px);
  font-weight: 400;
  color: var(--color-text);
  margin-bottom: 14px;
}

.hero__list li::before {
  content: "";
  flex: none;
  width: 22px;
  height: 22px;
  background: url('/static/img/bullet.svg') no-repeat center / contain;
}

.hero__cta-wrap {
  position: relative;
  display: inline-block;
}

/* The popup trigger is a <button>; the URL triggers are <a>. Both carry `.autoflash`
   (overflow:hidden, added by main.js), which puts an inline-block <a>'s baseline at its
   bottom edge — leaving the line's strut descent (7.59px at 16px/1.6 Merriweather) below
   it. A <button> always keeps its text baseline, so restore that gap to keep the hero
   layout identical either way. Desktop only: on mobile .hero__cta is display:flex. */
@media (min-width: 769px) {
  .hero__cta-wrap:has(> button.hero__cta) {
    padding-bottom: 7.59375px;
  }
}

.hero__cta {
  align-self: flex-start;
  position: relative;
  z-index: 2;
}

/* ==========================================================================
   Hero load sequence — header, then images, then title/advantages, then CTA.
   Opacity/transform only so nothing shifts layout; each element keeps its
   final layout box throughout. .hero__list li keeps its own mobile stagger
   (defined in the ≤768px block) instead of the ul-level fade below.

   Delays are kept short (≤0.35s total) on purpose: .hero has a solid dark
   background reserved as a placeholder while the bg image streams in (see
   .hero above), so if the text animation is delayed too, the visitor stares
   at a full-screen near-black box with nothing on it — the "чёрный экран"
   bug from 2026-10-13 (docs/image-optimisation.md). The text must never
   wait on the image or on a long timer; only this brief polish fade remains.
   ========================================================================== */
@keyframes heroFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes heroFadeUp {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

.site-header {
  opacity: 0;
  animation: heroFadeIn 0.3s ease-out both;
}

.hero__bg {
  opacity: 0;
  animation: heroFadeIn 0.4s ease-out 0.1s both;
}

.hero__cutout {
  opacity: 0;
  animation: heroFadeIn 0.4s ease-out 0.2s both;
}

.hero__title {
  animation: heroFadeUp 0.35s ease-out 0.1s both;
}

.hero__list {
  animation: heroFadeUp 0.35s ease-out 0.2s both;
}

.hero__cta-wrap {
  animation: heroFadeUp 0.35s ease-out 0.3s both;
}

/* ---- original "autoflash" flash effect (from client's Tilda cabinet) ---- */
.autoflash {
  position: relative;
  overflow: hidden;
  -webkit-transform: translate3d(0,0,0);
  transform: translate3d(0,0,0);
}

.flash {
  content: "";
  background-color: rgba(255, 255, 255, 0.5);
  height: 100%;
  width: 3em;
  display: block;
  position: absolute;
  top: 0;
  left: -4.5em;
  -webkit-transform: skewX(-45deg) translateX(0);
  transform: skewX(-45deg) translateX(0);
  -webkit-transition: none;
  transition: none;
}

.lighting {
  -webkit-animation: moving 3.6s ease-in-out infinite;
  -moz-animation: moving 3.6s ease-in-out infinite;
  -ms-animation: moving 3.6s ease-in-out infinite;
  -o-animation: moving 3.6s ease-in-out infinite;
  animation: moving 3.6s ease-in-out infinite;
}

@keyframes moving {
  30% {
    -webkit-transform: skewX(-45deg) translateX(33.5em);
    transform: skewX(-45deg) translateX(33.5em);
  }
  100% {
    -webkit-transform: skewX(-45deg) translateX(33.5em);
    transform: skewX(-45deg) translateX(33.5em);
  }
}

@media (prefers-reduced-motion: reduce) {
  .lighting { animation: none; }
  .site-header,
  .site-nav,
  .site-nav__backdrop {
    transition: none;
  }
  .site-header,
  .hero__bg,
  .hero__cutout,
  .hero__title,
  .hero__list,
  .hero__cta-wrap {
    animation: none;
    opacity: 1;
    transform: none;
  }
}

/* ---- grain/noise overlay (from client's Tilda cabinet) ---- */
:root { --app-height: 100%; }
.page__noise {
  position: fixed;
  display: flex;
  top: 0; left: 0; right: 0; bottom: 0;
  width: 100%;
  height: 100%;
  height: var(--app-height);
  background-image: url('/static/img/noise.jpg');
  background-size: 170px;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
  z-index: 9999;
}
.page__noise--visible { opacity: 0.05; }
@media (prefers-reduced-motion: reduce) { .page__noise { display: none; } }

/* ==========================================================================
   Body scroll lock (while the nav drawer is open)
   ========================================================================== */

body.nav-open {
  overflow: hidden;
}

.hero__arrow {
  position: absolute;
  left: 436px;
  top: 363px;
  width: 186px;
  height: auto;
  pointer-events: none;
  z-index: 1;
}

/* ==========================================================================
   About
   ========================================================================== */

.about {
  background: var(--color-bg-about);
}

/* Light colour scheme (see breadcrumbs for the source colours) — only
   background/text colours change, sizing/layout stays identical. */
.about.block--light {
  background: #ffffff;
}

/* Grey scheme: light ink/tile on the divider's #ebebeb surface. */
.about.block--grey {
  background: #ebebeb;
}

.about.block--light .section-heading,
.about.block--light .about__item p,
.about.block--grey .section-heading,
.about.block--grey .about__item p {
  color: #1a1a1a;
}

/* Light-theme icon tile — a barely-there gold wash + hairline ring (the dark
   gradient tile below was only ever tuned for the dark `--color-bg-about`
   section). The icon's own stroke is a flat accent gold baked in by
   `get_icon_svg()` in apps/content/icons.py; client feedback called the old
   cream/tan gradient tile too heavy/gold alongside it, so this is now a flat
   near-transparent tint instead of a gradient "disc". */
.about.block--light .about__img,
.about.block--grey .about__img {
  background: rgba(154, 123, 63, 0.08);
}

.about__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
}

/* Dark-theme icon tile — same treatment as the light tile above (see commits
   0a9c053/ad6fe4b): dropped the heavy gold-gradient disc for the site's standard
   translucent dark "surface" tint (same token `.element-card` uses for its own
   card background), no border. The icon's stroke stays `currentColor` (unlike the
   baked flat gold used for light — this `color` just needs to differ from
   `var(--color-accent)` because that gold reads as too dark/muddy against the
   dark background), so it picks up `#c9a768` — the lighter stop of the site's own
   gold gradient (used elsewhere for gold-on-dark, e.g. `.l2-intro--ornament`). */
.about__img {
  float: left;
  width: 56px;
  height: 56px;
  margin: 0 8px 0 0;
  border-radius: var(--radius);
  background: var(--color-surface);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #c9a768;
}

.about__img svg {
  width: 48px;
  height: 48px;
  /* Thinner line to match the refined light-theme stroke (1.15, see
     `LIGHT_THEME_STROKE_WIDTH` in apps/content/icons.py) — overrides the dark
     branch's baked `stroke-width="1.5"` attribute; for the light branch this is
     a no-op (already 1.15 baked in), so light stays visually byte-identical. */
  stroke-width: 1.15;
}

.about__img--a {
  animation: about-float 5s ease-in-out infinite;
}

.about__img--b {
  animation: about-float 5s ease-in-out 1.5s infinite;
}

.about__img--c {
  animation: about-float 5s ease-in-out .75s infinite;
}

.about__img--d {
  animation: about-float 5s ease-in-out 2.25s infinite;
}

.about__img--e {
  animation: about-float 5s ease-in-out 3s infinite;
}

.about__item--intro,
.about__item--outro {
  grid-column: 1 / -1;
}

/* "1_1_3" variant: two full-width rows, then a centered heading, then a 3-column
   row — a different shape from the `.about__grid` 2-column layout above, so it
   gets its own containers instead of reusing `.about__grid`. */
.about__rows {
  display: flex;
  flex-direction: column;
  gap: 48px;
  margin-bottom: 40px;
}

.about__heading--center {
  text-align: center;
}

.about__cols3 {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 48px;
}

/* "h2_2col" variant: same as `.about__cols3` with two columns. */
.about__cols2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
}

/* "h2_3col"/"h2_2col" variants' centred h2: needs the section scope to outrank the
   `.section--description .section-heading` left-align, which `.about__heading--center`
   alone loses to. */
.section--description .about__heading--h2-3col {
  text-align: center;
}

/* "h2_3col" variant: rich-text intro above the heading, rich-text columns in
   `.about__cols3`. The editor can leave text outside any <p>, so the type styles
   `.about__item p` gives the other variants are set on the containers here. */
.about__intro {
  margin-bottom: 40px;
}

.about__intro,
.about__item--rich {
  color: var(--color-text);
  font-size: 20px;
  font-weight: 400;
  line-height: 1.2;
}

.about.block--light .about__intro,
.about.block--light .about__item--rich,
.about.block--grey .about__intro,
.about.block--grey .about__item--rich {
  color: #1a1a1a;
}

.about__intro p,
.about__item--rich p {
  font-size: inherit;
  margin: 0 0 16px;
}

.about__intro > :last-child,
.about__item--rich > :last-child {
  margin-bottom: 0;
}

/* A list started on an empty line leaves the browser an empty <p> around it. */
.about__intro p:empty,
.about__item--rich p:empty {
  display: none;
}

/* Same opt-back-in as `.faq-item__answer-inner`: the global list reset, `a` reset and
   body weight 300 would otherwise hide the editor's lists, links and bold. */
.about__intro ul,
.about__intro ol,
.about__item--rich ul,
.about__item--rich ol {
  padding-left: 22px;
  margin: 0 0 16px;
}

.about__intro ul,
.about__item--rich ul {
  list-style: disc;
}

.about__intro ol,
.about__item--rich ol {
  list-style: decimal;
}

.about__intro li,
.about__item--rich li {
  margin: 4px 0;
}

.about__intro a,
.about__item--rich a {
  text-decoration: underline;
}

.about__intro strong,
.about__intro b,
.about__item--rich strong,
.about__item--rich b {
  font-weight: 700;
}

@media (max-width: 768px) {
  .about__intro,
  .about__item--rich {
    font-size: 18px;
  }
}

@keyframes about-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

@media (prefers-reduced-motion: reduce) {
  .about__img {
    animation: none;
  }
}

.about__item p {
  color: var(--color-text);
  font-size: 20px;
  font-weight: 400;
  line-height: 1.2;
  margin: 0;
}

@media (max-width: 768px) {
  .about__item p {
    font-size: 18px;
  }
}

/* ==========================================================================
   Services grid
   ========================================================================== */

.card-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.card-grid--3 { grid-template-columns: repeat(3, 1fr); }
.card-grid--2 { grid-template-columns: repeat(2, 1fr); }

.service-card {
  border: 1px solid var(--color-border-soft);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--color-surface);
  display: flex;
  flex-direction: column;
  transition: border-color 0.15s ease, transform 0.15s ease;
}

.service-card:hover {
  border-color: var(--color-border);
  transform: translateY(-2px);
}

.service-card__media {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: linear-gradient(135deg, #3a3a3a, #232323);
}

.service-card__media--square {
  aspect-ratio: 1 / 1;
}

/* Photo-album cards (`/photo/` — gallery_categories.html, and the `images` block's
   "galleries" variant): photos read as secondary to the square category cards and sit
   between them and video in the shape system — categories 1:1 → photos 3:2 → video 16:9.
   The generated album cover is pre-cropped 3:2 to match (panel/views.py:
   GALLERY_ALBUM_CROP_SIZES), so this box shows it uncropped. */
.service-card__media--photo {
  aspect-ratio: 3 / 2;
}

/* Video-album cards (video gallery level 1, templates/site/blocks/video_all.html) render a
   horizontal video-preview shape, wider than the 3:2 photo-album cards above — the generated
   cover itself is also pre-cropped 16:9 (see panel/views.py:GALLERY_ALBUM_VIDEO_CROP_SIZES). */
.service-card__media--video {
  aspect-ratio: 16 / 9;
}

/* `smi_*` block cards (templates/site/blocks/smi_report.html and friends) — the old site's
   press-mention covers were a wide ~2:1 format (client reference measured 1166x575 =
   2.03:1), unlike the 4:3 default above. Covers are generated at that ratio too (see
   SMI_CARD_COVER_SIZE in panel/views.py). */
.service-card__media--wide {
  aspect-ratio: 2 / 1;
}

.service-card__media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.service-card__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(69, 69, 69, 0.2);
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.service-card:hover .service-card__media::after {
  opacity: 0;
}

.service-card__badge {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 2;
  display: inline-block;
  background: var(--color-accent);
  color: #ffffff;
  font-family: var(--font-serif);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 7px 14px;
  border-radius: 999px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
  pointer-events: none;
  transform: scale(0.85);
  transform-origin: top left;
}

.service-card__badge--icon {
  width: 34px;
  height: 34px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
}

.service-card__badge--icon svg {
  width: 18px;
  height: 18px;
  color: #ffffff;
}

.service-card__body {
  padding: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.service-card__title {
  font-size: 15px;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 8px;
  color: var(--color-text);
}

/* `posts_grid` block card's topic/category label — BlogPost.topic, shown above the title. */
.service-card__topic {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-accent);
  margin-bottom: 6px;
}

/* `posts` block card's excerpt — BlogPost.article_lead, the attached `article` block's
   lead/`subtitle` field, if any (see templates/site/blocks/posts.html). */
.service-card__text {
  font-size: 14px;
  line-height: 1.5;
  color: var(--color-text-secondary);
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.service-card__link {
  margin-top: auto;
  font-size: 13px;
  color: var(--color-accent);
  font-weight: 700;
  text-transform: uppercase;
}

.section--images .service-card__link,
.section--gallery-categories .service-card__link,
.section--video-categories .service-card__link,
.section--more-ideas .service-card__link,
.section--posts-grid .service-card__link,
.section--services .service-card__link,
.section--categories .service-card__link,
.services .service-card__link,
.video-card__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.section--images .service-card__label,
.section--gallery-categories .service-card__label,
.section--video-categories .service-card__label,
.section--more-ideas .service-card__label,
.section--posts-grid .service-card__label,
.section--services .service-card__label,
.section--categories .service-card__label,
.services .service-card__label,
.video-card__link .service-card__label {
  line-height: 1;
}

.service-card__arrow {
  display: block;
  width: 1em;
  height: 1em;
  flex-shrink: 0;
  animation: service-card-arrow-sweep 2.2s ease-in-out infinite;
}

@keyframes service-card-arrow-sweep {
  0%, 100% { transform: translateX(-3px); }
  50% { transform: translateX(3px); }
}

@media (prefers-reduced-motion: reduce) {
  .service-card__arrow {
    animation: none;
  }
}

/* ---- Services: white version (V1) ---- */
.services {
  background: #ffffff;
}

.services .section-heading {
  color: #1a1a1a;
}

.services .service-card {
  background: #ffffff;
  border-color: #e6e6e6;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
}

.services .service-card:hover {
  border-color: #c9c9c9;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.services .service-card__title {
  color: #1a1a1a;
}

.services .service-card__media {
  background: linear-gradient(135deg, #f4f4f4, #e7e7e7);
}

/* `category_slider` block's dark theme — the home's own hardcoded "Какое событие..."
   section (also `.services`) stays white-only/untouched; these overrides are scoped to
   `.section--category-slider.block--dark` (3 classes) so they out-specify the `.services`/
   `.services .service-card*` white rules above (2 classes) without touching `.services`
   itself. Values reused verbatim from the site's other dark standard blocks (`.service-card`
   defaults + `--color-bg-about`, same tokens `smi_report`/`video_all`/`smi_pick` render
   with) — no new colours invented. `.service-card__media` and the «Подробнее»
   label/arrow/slider-arrow need no override: their un-themed defaults already match (dark
   gradient placeholder, `--color-accent` gold, white slider-arrow circle — same as every
   other dark/light slider on the site). */
.section--category-slider.block--dark,
.section--posts-slider.block--dark {
  background: var(--color-bg-about);
}

.section--category-slider.block--dark .section-heading,
.section--posts-slider.block--dark .section-heading {
  color: var(--color-text);
}

.section--category-slider.block--dark .service-card:not(.service-card--cta),
.section--posts-slider.block--dark .service-card:not(.service-card--cta) {
  background: var(--color-surface);
  border-color: var(--color-border-soft);
  box-shadow: none;
}

.section--category-slider.block--dark .service-card:not(.service-card--cta):hover,
.section--posts-slider.block--dark .service-card:not(.service-card--cta):hover {
  border-color: var(--color-border);
  box-shadow: none;
}

.section--category-slider.block--dark .service-card__title,
.section--posts-slider.block--dark .service-card__title {
  color: var(--color-text);
}

/* `category_slider` block's hardcoded trailing CTA card («Каталог мероприятий» →
   /catalog, see category_slider.html) — a 1:1 rebuild of `gallery_slider`'s
   `.photo-card--cta` recipe (same grey-595959 card, same icon/text/button layout) onto
   the `.service-card` family, since this block's cards are `.service-card`, not
   `.photo-card`. `.services .service-card`'s white background/border (2 classes, line
   ~1188) would otherwise beat a bare single-class `.service-card--cta`, so this is
   compounded to `.service-card.service-card--cta` (2 classes) and placed after it in the
   file so source order settles the tie. Deliberately NOT themed (see the `:not(
   .service-card--cta)` exclusions on the dark rules above) — same grey card reads fine on
   both the white `.services` background and the dark `--color-bg-about` background,
   exactly like `.photo-card--cta` is already left un-themed in `gallery_slider`. */
.service-card.service-card--cta {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  gap: 18px;
  background: #595959;
  border-color: #595959;
  padding: 40px 30px;
}

.service-card.service-card--cta:hover {
  background: #595959;
  border-color: #595959;
}

.service-card__cta-icon {
  width: 46px;
  height: 46px;
  color: #ffffff;
  flex-shrink: 0;
}

.service-card__cta-text {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 400;
  text-transform: uppercase;
  line-height: 1.4;
  color: #ffffff;
}

.service-card__cta-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-family: var(--font-serif);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  font-size: 15px;
  padding: 13px 36px;
  border-radius: var(--radius);
  border: 2px solid #ffffff;
  background: rgba(0, 0, 0, 0.3);
  color: #ffffff;
  text-align: center;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.service-card__cta-btn:hover {
  background: #ffffff;
  color: #292929;
}

/* `video_album_slider` block's dark theme — same recipe as `.section--category-slider.
   block--dark` just above: `.videos-section` is hardcoded white/light-only (it's also the
   home's former hardcoded video section's class), so these overrides are scoped to
   `.section--video-album-slider.block--dark` (3 classes) to out-specify it (2 classes)
   without touching `.videos-section` itself. Values reused verbatim from the site's other
   dark standard blocks — no new colours invented. The play-button overlay and the
   «Смотреть видео» label/arrow/slider-arrow need no override: their un-themed defaults
   already match every other dark/light slider on the site. `.video-card__media`'s light
   gradient does: it shows on a no-cover card and behind a deferred cover until it loads,
   so dark uses the same placeholder as `.service-card__media`. */
.section--video-album-slider.block--dark {
  background: var(--color-bg-about);
}

.section--video-album-slider.block--dark .section-heading {
  color: var(--color-text);
}

.section--video-album-slider.block--dark .video-card {
  background: var(--color-surface);
  border-color: var(--color-border-soft);
  box-shadow: none;
}

.section--video-album-slider.block--dark .video-card:hover {
  border-color: var(--color-border);
  box-shadow: none;
}

.section--video-album-slider.block--dark .video-card__title {
  color: var(--color-text);
}

.section--video-album-slider.block--dark .video-card__media {
  background: linear-gradient(135deg, #3a3a3a, #232323);
}

/* `video_slider` block («Слайдер с видео») — reuses `.section--video-album-slider` above for
   padding/heading gap/dark theme; a card is one video. A VK card holds the live VK player
   (it paints its own cover/play button, so no dimming overlay and no pointer cursor); a file
   card's media box opens the popup player. */
.section--video-slider .video-card { cursor: default; }
.section--video-slider .video-card--file .video-card__media { cursor: pointer; }
.section--video-slider .video-card__media iframe {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  border: 0; display: block;
}
.section--video-slider .video-card--embed .video-card__media::after { display: none; }

/* ---- Services: horizontal slider ---- */
.services-slider {
  position: relative;
}

.services .card-grid,
.section--more-ideas .card-grid {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  gap: 24px;
  padding-bottom: 8px;
  scroll-behavior: smooth;
  scrollbar-width: none;
}

.services .card-grid::-webkit-scrollbar,
.section--more-ideas .card-grid::-webkit-scrollbar {
  display: none;
}

.services .service-card,
.section--more-ideas .service-card {
  flex: 0 0 340px;
  scroll-snap-align: start;
}

.slider-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid #ddd;
  color: var(--color-accent);
  font-size: 24px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.15s ease;
}

.slider-arrow:hover {
  border-color: #999;
}

.slider-arrow--prev {
  left: -23px;
}

.slider-arrow--next {
  right: -23px;
}

@media (max-width: 720px) {
  .slider-arrow {
    display: none;
  }

  .services .service-card,
  .section--more-ideas .service-card {
    flex: 0 0 82vw;
  }
}

/* Tablet/sub-desktop: container is flush with the viewport (no auto side
   margins), so the arrows' desktop offset (-23px) would stick out past the
   edge. Pull them back inside the container until desktop margins return. */
@media (min-width: 721px) and (max-width: 1200px) {
  .slider-arrow--prev {
    left: 4px;
  }

  .slider-arrow--next {
    right: 4px;
  }
}

/* ==========================================================================
   Stats
   ========================================================================== */

.stats-section.block--light {
  background: #ffffff;
}

.stats-section.block--light .section-heading {
  color: #1a1a1a;
}

.stats-section.block--dark {
  background: var(--color-bg-about);
}

.stats-section.block--dark .section-heading {
  color: var(--color-text);
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  text-align: left;
}

.stat:not(:last-child) {
  border-right: 1px solid #d9d9d9;
}

.stats-section.block--dark .stat:not(:last-child) {
  border-right-color: var(--color-border-soft);
}

.stat__number {
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: clamp(24px, 4.5vw, 43px);
  color: var(--color-accent);
  overflow-wrap: break-word;
  word-break: break-word;
}

.stat__label {
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  color: #000000;
  margin-top: 8px;
  overflow-wrap: break-word;
  word-break: break-word;
}

.stats-section.block--dark .stat__label {
  color: var(--color-text-secondary);
}

/* ==========================================================================
   Forms
   ========================================================================== */

/* Anti-spam honeypot: off-screen (NOT display:none — bots skip hidden inputs, real
   browsers ignore an off-screen field) and out of the tab order (tabindex=-1). */
.hp-field {
  position: absolute;
  left: -9999px;
  top: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.lead-form {
  max-width: 560px;
  margin: 0 auto;
}

.form-row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 16px;
}

.form-field {
  flex: 1 1 220px;
}

.form-field input,
.form-field textarea {
  width: 100%;
  font-family: var(--font-serif);
  font-size: 14px;
  padding: 14px 16px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  background: transparent;
  color: var(--color-text);
}

.form-field input::placeholder,
.form-field textarea::placeholder {
  color: var(--color-text-muted);
}

.form-consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 12px;
  color: var(--color-text-muted);
  text-align: left;
  margin-top: 16px;
  cursor: pointer;
}

.form-consent__text a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.form-consent__text a:hover {
  color: var(--color-accent);
}

.form-consent__check {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  margin-top: 1px;
  accent-color: var(--color-accent);
  cursor: pointer;
}

.form-field.is-error input {
  border-color: #e5484d;
}

.form-field--underline.is-error input {
  border-bottom-color: #e5484d;
}

.lead-form__success {
  font-family: var(--font-serif);
  font-size: 16px;
  line-height: 1.5;
  text-align: center;
  color: var(--color-text);
  padding: 24px 0;
}

/* ---- Lead section 1 (full-width bg image + filter) ---- */
.lead-section {
  position: relative;
  min-height: 680px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 60px 20px;
}

.lead-section__bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  pointer-events: none;
}

.lead-section__filter {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 30%;
  z-index: 1;
  background: linear-gradient(0turn, rgba(69, 69, 69, 0) 0%, rgba(69, 69, 69, 1) 100%);
}

.lead-section__content {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--container-width);
  margin: 0 auto;
  text-align: center;
  color: var(--color-text);
}

.lead-section__heading {
  font-family: var(--font-serif);
  font-weight: 400;
  text-transform: uppercase;
  font-size: clamp(24px, 4vw, 48px);
  line-height: 1.1;
  margin-bottom: 16px;
  max-width: 80%;
  margin-left: auto;
  margin-right: auto;
  word-break: normal;
  overflow-wrap: break-word;
}

@media (max-width: 640px) {
  .lead-section__heading {
    max-width: 100%;
  }
}

.lead-section__subheading {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(16px, 2vw, 20px);
  color: var(--color-text);
  opacity: 0.9;
  margin-bottom: 40px;
}

.lead-form--underline {
  max-width: 390px;
  margin: 0 auto;
}

.form-field--underline {
  margin-bottom: 36px;
}

.form-field--underline input {
  width: 100%;
  font-family: var(--font-serif);
  font-size: 18px;
  padding: 0 0 8px;
  border: none;
  border-bottom: 1px solid var(--color-text);
  border-radius: 0;
  background: transparent;
  color: var(--color-text);
}

.form-field--underline input:focus,
.form-field--underline input:focus-visible {
  outline: none;
  box-shadow: none;
}

.form-field--underline input::placeholder {
  color: rgba(255, 255, 255, 0.7);
}

.lead-form--underline .btn--block {
  margin-top: 56px;
}

.lead-form--underline .btn--block:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.lead-form--underline .form-consent {
  justify-content: center;
  margin-top: 24px;
  font-size: 13px;
  color: #ffffff;
}

@media (max-width: 640px) {
  .lead-section {
    min-height: 462px;
  }
}

/* ==========================================================================
   Photo / video grids
   ========================================================================== */

.media-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

/* «Изображения — из галерей» on a service page: whole rows only, classes from
   pick_whole_rows_classes (content_tags). `of .media-grid__item` is required: the grid's last
   child is the JSON-LD <script> (images.html), which a plain :nth-last-child would count.
   720px = where `.media-grid` itself switches from 3 to 2 columns (Responsive section below). */
@media (min-width: 721px) {
  .media-grid--pick.media-grid--r3-1 > :nth-last-child(-n + 1 of .media-grid__item) { display: none; }
  .media-grid--pick.media-grid--r3-2 > :nth-last-child(-n + 2 of .media-grid__item) { display: none; }
}
@media (max-width: 720px) {
  .media-grid--pick.media-grid--r2-1 > :nth-last-child(-n + 1 of .media-grid__item) { display: none; }
}

.media-grid__item {
  aspect-ratio: 1 / 1;
  border-radius: var(--radius);
  background: linear-gradient(135deg, #3a3a3a, #202020);
  position: relative;
  overflow: hidden;
}

.media-grid__item--video {
  background: linear-gradient(160deg, #16a085 0%, #1a3a37 55%, #1a1a1a 100%);
  aspect-ratio: 16 / 9;
  cursor: pointer;
}

.media-grid__item--video img {
  object-fit: cover;
}

/* VK tiles (video_links/video_pick) embed the VK player in place — it paints its own cover
   and play button; the gradient above only shows while the iframe loads. */
.media-grid__item--embed { cursor: default; }
.media-grid__item--embed iframe {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  border: 0; display: block;
}

.media-grid__item--photo {
  aspect-ratio: 3 / 2;
}

.media-grid__item img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

/* Gallery/album photo covers are pre-cropped to this cell's exact 3:2 ratio (see
   panel/views.py's GALLERY_PHOTO_COVER_SIZE), so fill the cell edge-to-edge instead of
   letterboxing — every cover ends up the same uniform size/shape regardless of the
   source photo's orientation. */
.media-grid__item--photo img {
  object-fit: cover;
}

/* Play button overlay (old-site/Tilda-style: a play glyph on a semi-transparent
   circular backing, scales up on hover) — the glyph itself is an inline SVG in
   video_links.html/video_upload.html, not a CSS triangle, so it stays crisp at any size. */
.media-grid__play {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 84px;
  height: 84px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(26, 26, 26, 0.4);
  border: none;
  color: #ffffff;
  transition: transform 0.25s ease, background-color 0.25s ease, box-shadow 0.25s ease;
  pointer-events: none;
}

.media-grid__play svg {
  width: 45px;
  height: 45px;
  margin-left: 6px; /* optical centering: the play triangle's visual weight sits left of its box */
}

.media-grid__item--video:hover .media-grid__play {
  transform: translate(-50%, -50%) scale(1.08);
  background: rgba(26, 26, 26, 0.55);
  box-shadow: 0 0 0 8px rgba(255, 255, 255, 0.08);
}

.media-grid__item--photo { cursor: pointer; }

/* `video_links`/`video_upload` blocks' grid (the "Видео с мероприятий" level-2 album page):
   2 cards per row on desktop, 1 per row on mobile (see the max-width: 860px override below)
   — unlike the photo `images` block, which stays a 3/2-column grid via the shared
   `.media-grid` base rule above. Scoped to `.section--video` so photo grids (which also use
   `.media-grid`) are untouched; this selector's extra specificity beats the
   `@media (max-width: 640px) .media-grid` 2-col override below without needing !important. */
.section--video .media-grid {
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}

@media (max-width: 860px) {
  .section--video .media-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .media-grid__play { width: 63px; height: 63px; }
  .media-grid__play svg { width: 34px; height: 34px; margin-left: 4px; }
}

/* `images` block, "pick" variant: the «Смотреть все» link below the grid (see
   templates/site/blocks/images.html) — reuses .service-card__link/.service-card__arrow's
   colour + animated-arrow styling verbatim (already scoped to .section--images).
   Right-aligned on desktop; mobile keeps the original centered layout (see the
   max-width: 720px override below). */
.images-see-all {
  margin-top: 32px;
  text-align: right;
}

/* Light colour scheme (see home's .photos-section for the source colours) — only
   background/text colours change, sizing/layout stays identical. */
.section--images.block--light {
  background: #ffffff;
}

.section--images.block--light .section-heading {
  color: #353535;
}

.section--images.block--light .service-card__title {
  color: #1a1a1a;
}

.section--images.block--light .service-card {
  background: #ffffff;
  border-color: #e6e6e6;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
}

.section--images.block--light .service-card:hover {
  border-color: #c9c9c9;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.section--images.block--light .service-card__media {
  background: linear-gradient(135deg, #f4f4f4, #e7e7e7);
}

/* Light colour scheme (same values as .section--images.block--light above) — only
   background/text colours change, sizing/layout stays identical. Shared by `categories`,
   `posts_grid` and the 3 `smi_*` blocks (all plain card-grid blocks, no block-specific
   colours of their own). */
.section--categories.block--light,
.section--posts-grid.block--light,
.section--services.block--light,
.section--smi.block--light {
  background: #ffffff;
}

.section--categories.block--light .section-heading,
.section--categories.block--light .service-card__title,
.section--posts-grid.block--light .section-heading,
.section--posts-grid.block--light .service-card__title,
.section--services.block--light .section-heading,
.section--services.block--light .service-card__title,
.section--smi.block--light .section-heading,
.section--smi.block--light .service-card__title {
  color: #1a1a1a;
}

.section--categories.block--light .service-card,
.section--posts-grid.block--light .service-card,
.section--services.block--light .service-card,
.section--smi.block--light .service-card {
  background: #ffffff;
  border-color: #e6e6e6;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
}

.section--categories.block--light .service-card:hover,
.section--posts-grid.block--light .service-card:hover,
.section--services.block--light .service-card:hover,
.section--smi.block--light .service-card:hover {
  border-color: #c9c9c9;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.section--categories.block--light .service-card__media,
.section--posts-grid.block--light .service-card__media,
.section--services.block--light .service-card__media,
.section--smi.block--light .service-card__media {
  background: linear-gradient(135deg, #f4f4f4, #e7e7e7);
}

.section--smi.block--light .smi-card__row {
  color: #4a4a4a;
}

/* `smi_report`/`smi_podcast`/`smi_radio` card body — Дата/Название источника/Место etc.
   meta lines + the repeatable source-links list below the title (see
   templates/site/blocks/smi_report.html and friends). Reuses `.service-card`'s own
   title/link/arrow styling verbatim, these are only the parts those blocks don't have.
   Fixed text grid so rows/links don't "dance" between cards of differing content length —
   the templates now always render the title/row/links elements (even empty) and these
   min-heights reserve their slot regardless of content:
   - title: 15px font-size * inherited body line-height 1.6 = 24px/line → 3 lines = 72px.
   - row: 13px * 1.5 line-height = 19.5px/line → 1 line = 1.5em, nowrap+ellipsis keeps it
     from ever growing to a 2nd line.
   - report-only actions: 13px * 1.6 line-height = 20.8px/line → 2 lines + the 8px gap
     between them = 2 * 1.6em + 8px = 49.6px (radio/podcast only ever show one link, so
     reserving a 2-line block there would add unwanted empty space — left as-is). */
.smi-card__title {
  margin-bottom: 4px;
  line-height: 1.6;
  min-height: calc(3 * 1.6em);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

.smi-card__row {
  font-size: 13px;
  line-height: 1.5;
  color: var(--color-text-secondary);
  margin-bottom: 4px;
  min-height: 1.5em;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.smi-card__links {
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.section--smi-report .smi-card__links {
  font-size: 13px;
  min-height: calc(2 * 1.6em + 8px);
}

.smi-card__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--color-accent);
  font-weight: 700;
  text-transform: uppercase;
}

/* `more_ideas` CTA button — same light-theme override as .section--button's .btn
   (see that block above) since this button sits on the same light/white background. */
.more-ideas__cta {
  margin-top: 25.5px;
  text-align: center;
}

/* Light: a softer CTA than .section--button's ink-black one — same border as the
   slider's cards above it (`.section--categories.block--light .service-card`,
   1px solid #e6e6e6) and the light theme's secondary text grey (#4a4a4a, as
   `.smi-card__row` / article text) instead of #1a1a1a. */
.section--more-ideas.block--light .btn {
  border: 1px solid #e6e6e6;
  color: #4a4a4a;
  background: rgba(0, 0, 0, 0.04);
}

.section--more-ideas.block--light .btn:hover {
  background: rgba(154, 123, 63, 0.1);
  border-color: var(--color-accent);
  color: var(--color-accent);
}

/* Dark theme: the generic `.btn` ghost style (white border, near-black fill)
   doesn't match the category cards above it. Reuse the cards' own border/
   background variables (`.service-card` uses --color-border-soft on
   --color-surface) so the CTA reads as one of the cards instead of a
   different button style. */
.section--more-ideas.block--dark .btn {
  border-color: var(--color-border-soft);
  background: var(--color-surface);
  color: var(--color-text);
}

.section--more-ideas.block--dark .btn:hover {
  border-color: var(--color-border);
  background: rgba(154, 123, 63, 0.15);
  color: var(--color-accent);
}

/* ---- Photo gallery lightbox ---- */
body.lightbox-open { overflow: hidden; }

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: none;
  touch-action: none;
}

.lightbox.is-open { display: block; }

.lightbox__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 10, 10, 0.92);
}

.lightbox__figure {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 72px 96px;
  pointer-events: none;
}

.lightbox__img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  pointer-events: auto;
  user-select: none;
  -webkit-user-drag: none;
  touch-action: none;
}

.lightbox__close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  z-index: 1;
}

.lightbox__counter {
  position: absolute;
  top: 28px;
  left: 50%;
  transform: translateX(-50%);
  color: #fff;
  font-size: 14px;
  letter-spacing: 0.04em;
  opacity: 0.85;
  z-index: 1;
}

.lightbox__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  z-index: 1;
}

.lightbox__arrow--prev { left: 16px; }
.lightbox__arrow--next { right: 16px; }

@media (max-width: 720px) {
  .lightbox__figure { padding: 56px 16px; }
  .lightbox__arrow { width: 40px; height: 40px; font-size: 18px; }
  .lightbox__arrow--prev { left: 8px; }
  .lightbox__arrow--next { right: 8px; }
  .lightbox__close { top: 12px; right: 12px; }
  .lightbox__counter { top: 18px; }
}

/* ---- Video popup (VK embeds / uploaded files) — see static/js/video-lightbox.js ----
   Same chrome (backdrop/close/arrows/counter) as the photo lightbox above, reused as a
   separate `.vlightbox` component since the stage itself is a fixed 16:9 box (an iframe/
   video, not a pannable/zoomable image) rather than `.lightbox__figure`'s free-form padding. */
body.vlightbox-open { overflow: hidden; }

.vlightbox {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: none;
}

.vlightbox.is-open { display: block; }

.vlightbox__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 10, 10, 0.92);
}

.vlightbox__stage {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 72px 96px;
}

.vlightbox__box {
  width: 100%;
  max-width: 1120px;
  aspect-ratio: 16 / 9;
  background: #000;
  position: relative;
}

.vlightbox__box iframe,
.vlightbox__box video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.vlightbox__close,
.vlightbox__arrow {
  position: absolute;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  cursor: pointer;
  z-index: 1;
}

.vlightbox__close {
  top: 20px;
  right: 20px;
  width: 44px;
  height: 44px;
  font-size: 24px;
  line-height: 1;
}

.vlightbox__arrow {
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  font-size: 22px;
  line-height: 1;
}

.vlightbox__arrow--prev { left: 16px; }
.vlightbox__arrow--next { right: 16px; }

@media (max-width: 720px) {
  .vlightbox__stage { padding: 56px 16px; }
  .vlightbox__arrow { width: 40px; height: 40px; font-size: 18px; }
  .vlightbox__arrow--prev { left: 8px; }
  .vlightbox__arrow--next { right: 8px; }
  .vlightbox__close { top: 12px; right: 12px; }
}

.section-footer-link {
  text-align: center;
}

.section-footer-link a {
  font-weight: 700;
  text-transform: uppercase;
  font-size: 13px;
  color: var(--color-accent);
}

/* ---- Photos section (white, 3-col cards) ---- */
.photos-section {
  background: #ffffff;
}

.photos-section .section-heading {
  color: #1a1a1a;
}

.photos-slider {
  position: relative;
}

.photo-grid {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  gap: 24px;
  padding-bottom: 8px;
  scroll-behavior: smooth;
  scrollbar-width: none;
}

.photo-grid::-webkit-scrollbar {
  display: none;
}

.photo-card {
  flex: 0 0 340px;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  border: 1px solid #e6e6e6;
  border-radius: var(--radius);
  overflow: hidden;
  background: #ffffff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.photo-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

/* 3:2 — same shape as the `/photo/` album cards (`.service-card__media--photo`) and the
   pre-cropped album cover (panel/views.py:GALLERY_ALBUM_CROP_SIZES). */
.photo-card__media {
  position: relative;
  overflow: hidden;
  aspect-ratio: 3 / 2;
  background: linear-gradient(135deg, #f4f4f4, #e7e7e7);
}

.photo-card__media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-card__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(69, 69, 69, 0.2);
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.photo-card:hover .photo-card__media::after {
  opacity: 0;
}

.photo-card__caption {
  padding: 16px 20px 18px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.photo-card__title {
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 400;
  text-transform: uppercase;
  line-height: 1.3;
  color: #1a1a1a;
}

/* Label + animated `.service-card__arrow` on one line, like `.video-card__link`. The label
   deliberately keeps the inherited line-height (no `line-height: 1` as on the video card)
   so the row stays exactly as tall as the old text-only link — no caption/card height shift. */
.photo-card__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--color-accent);
}

.photo-card--cta {
  justify-content: center;
  align-items: center;
  text-align: center;
  gap: 18px;
  background: #595959;
  border-color: #595959;
  padding: 40px 30px;
}

.photo-card--cta:hover {
  background: #595959;
}

.photo-card__cta-icon {
  width: 46px;
  height: 46px;
  color: #ffffff;
  flex-shrink: 0;
}

.photo-card__cta-text {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 400;
  text-transform: uppercase;
  line-height: 1.4;
  color: #ffffff;
}

.photo-card__cta-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-family: var(--font-serif);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  font-size: 15px;
  padding: 13px 36px;
  border-radius: var(--radius);
  border: 2px solid #ffffff;
  background: rgba(0, 0, 0, 0.3);
  color: #ffffff;
  text-align: center;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.photo-card__cta-btn:hover {
  background: #ffffff;
  color: #292929;
}

/* `gallery_slider` block's dark theme — same recipe as `.section--category-slider.
   block--dark`/`.section--video-album-slider.block--dark` above: `.photos-section` is
   hardcoded white/light-only (it's also the home's own hardcoded photo section's class),
   so these overrides are scoped to `.section--gallery-slider.block--dark` (3 classes) to
   out-specify it (2 classes) without touching `.photos-section` itself. Values reused
   verbatim from the site's other dark standard blocks — no new colours invented.
   `.photo-card__media`'s gradient placeholder, the «Смотреть фото» label/arrow/slider-arrow,
   and `.photo-card--cta`/`.photo-card__cta-btn` (already dark-grey/white, built to sit on a
   white section) need no override: their un-themed defaults already match every other
   dark/light slider on the site and stay legible on the dark section background too. */
.section--gallery-slider.block--dark {
  background: var(--color-bg-about);
}

.section--gallery-slider.block--dark .section-heading {
  color: var(--color-text);
}

.section--gallery-slider.block--dark .photo-card:not(.photo-card--cta) {
  background: var(--color-surface);
  border-color: var(--color-border-soft);
  box-shadow: none;
}

.section--gallery-slider.block--dark .photo-card:not(.photo-card--cta):hover {
  border-color: var(--color-border);
  box-shadow: none;
}

.section--gallery-slider.block--dark .photo-card__title {
  color: var(--color-text);
}

/* ---- Videos section (white, slider, popup player) ---- */
.videos-section {
  background: #ffffff;
}

.videos-section .section-heading {
  color: #1a1a1a;
}

.videos-slider {
  position: relative;
}

.video-grid {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  gap: 24px;
  padding-bottom: 8px;
  scroll-behavior: smooth;
  scrollbar-width: none;
}

.video-grid::-webkit-scrollbar {
  display: none;
}

.video-card {
  flex: 0 0 calc(50% - 12px);
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  border: 1px solid #e6e6e6;
  border-radius: var(--radius);
  overflow: hidden;
  background: #ffffff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
  padding: 0;
  margin: 0;
  text-align: left;
  cursor: pointer;
  font: inherit;
  color: inherit;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.video-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.video-card__media {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: linear-gradient(135deg, #f4f4f4, #e7e7e7);
}

.video-card__media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.video-card__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(69, 69, 69, 0.2);
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.video-card:hover .video-card__media::after {
  opacity: 0;
}

.video-card__play {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.video-card__play::before {
  content: "";
  position: absolute;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: rgba(26, 26, 26, 0.55);
}

.video-card__play::after {
  content: "";
  position: relative;
  width: 0;
  height: 0;
  margin-left: 4px;
  border-top: 11px solid transparent;
  border-bottom: 11px solid transparent;
  border-left: 18px solid #ffffff;
}

.video-card__caption {
  padding: 16px 20px 18px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.video-card__title {
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 400;
  text-transform: uppercase;
  line-height: 1.3;
  color: #1a1a1a;
}

.video-card__link {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--color-accent);
}

/* `video_slider`'s «Смотреть видео» is a <button> (opens the popup player) — strip the UA
   button chrome so it looks exactly like the album slider's `<a class="video-card__link">`. */
button.video-card__link {
  align-self: flex-start;
  padding: 0;
  border: 0;
  background: none;
  font-family: inherit;
  letter-spacing: inherit;
  cursor: pointer;
}

/* ---- Video popup modal ---- */
.video-modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: none;
}

.video-modal.is-open {
  display: block;
}

.video-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
}

.video-modal__dialog {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 90%;
  max-width: 960px;
  aspect-ratio: 16 / 9;
}

.video-modal__close {
  position: absolute;
  top: -44px;
  right: 0;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  color: #1a1a1a;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.video-modal__frame {
  width: 100%;
  height: 100%;
}

.video-modal__frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

/* ---- Lead popup form (the "lead_form" block) ---- */
body.lead-popup-open {
  overflow: hidden;
}

.lead-popup {
  position: fixed;
  inset: 0;
  z-index: 2100;
  display: none;
}

.lead-popup.is-open {
  display: block;
}

.lead-popup__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
}

.lead-popup__dialog {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 92%;
  max-width: 520px;
}

/* Clips the rounded corners; kept separate from the scrolling element below so the
   native scrollbar never paints inside the clipped corners (that combo is what caused
   the stray light band at the bottom on mobile). */
.lead-popup__dialog-clip {
  max-height: 90vh;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--color-bg-soft);
}

.lead-popup__dialog-scroll {
  max-height: 90vh;
  overflow-y: auto;
  padding: 40px 32px;
  text-align: center;
}

.lead-popup__close {
  position: absolute;
  top: -15px;
  right: -15px;
  width: 38px;
  height: 38px;
  border: none;
  border-radius: 50%;
  background: #595959;
  color: #ffffff;
  font-size: 23px;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.45);
  z-index: 5;
}

.lead-popup__image {
  width: 100%;
  height: auto;
  aspect-ratio: 12 / 5;
  object-fit: cover;
  border-radius: var(--radius);
  margin-bottom: 24px;
  display: block;
}

.lead-popup__title {
  font-family: var(--font-serif);
  font-weight: 400;
  text-transform: uppercase;
  font-size: clamp(20px, 3vw, 28px);
  line-height: 1.2;
  margin-bottom: 24px;
}

.lead-popup__success-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 20px;
  border-radius: 50%;
  background: var(--color-accent);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lead-popup__success-icon svg {
  width: 32px;
  height: 32px;
}

.lead-popup--success .lead-form__success {
  font-size: 22px;
  line-height: 1.4;
  padding: 0;
}

@media (min-width: 641px) {
  .lead-popup__title {
    font-size: clamp(16px, 2.4vw, 22px);
  }

  .lead-popup .btn {
    font-size: 15px;
    padding: 18px 42px;
  }
}

@media (max-width: 640px) {
  /* Full-screen overlay on mobile: no floating card, no backdrop margins —
     the dialog itself fills the viewport with a black bar across the top. */
  .lead-popup__dialog {
    top: 0;
    left: 0;
    transform: none;
    width: 100%;
    max-width: none;
    height: 100%;
  }

  .lead-popup__dialog-clip {
    position: relative;
    height: 100%;
    max-height: none;
    border-radius: 0;
  }

  .lead-popup__dialog-clip::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 54px;
    background: #000000;
    z-index: 1;
  }

  .lead-popup__dialog-scroll {
    height: 100%;
    max-height: none;
    box-sizing: border-box;
    padding: calc(54px + 26px) 16px 26px;
  }

  .lead-popup__close {
    position: absolute;
    top: 0;
    right: 0;
    width: 70px;
    height: 70px;
    font-size: 30px;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
    /* icon must center on the 54px black bar, not the full 70px touch target */
    padding-bottom: 16px;
  }

  .lead-popup__image {
    margin-bottom: 20px;
  }

  .lead-popup__title {
    font-size: 16px;
    margin-bottom: 20px;
  }

  .lead-popup .form-field--underline {
    margin-bottom: 29px;
  }

  .lead-popup .form-field--underline input {
    /* kept at 16px on purpose: iOS Safari zooms the page in on focus for inputs
       below 16px, which would be a worse regression than a slightly larger field */
    font-size: 16px;
    padding-bottom: 6px;
  }

  .lead-popup .form-consent {
    font-size: 11px;
    margin-top: 20px;
  }

  .lead-popup .lead-form__success {
    font-size: 13px;
    padding: 20px 0;
  }

  .lead-popup__success-icon {
    width: 50px;
    height: 50px;
    margin: 0 auto 16px;
  }

  .lead-popup__success-icon svg {
    width: 25px;
    height: 25px;
  }

  .lead-popup--success .lead-form__success {
    font-size: 16px;
    padding: 0;
  }

  .lead-popup .btn {
    /* font-size unchanged; height is pinned to exactly 54px via line-height + padding */
    font-size: 17px;
    line-height: 1;
    padding: 16.5px 54px;
  }

  .lead-popup .btn--block {
    margin-top: 45px;
  }
}

/* ==========================================================================
   Advantages
   ========================================================================== */

.advantages.block--light {
  background: #ffffff;
}

.advantages.block--light .section-heading {
  color: #1a1a1a;
  text-align: left;
}

.advantages.block--dark {
  background: var(--color-bg-about);
}

.advantages.block--dark .section-heading {
  color: var(--color-text);
  text-align: left;
}

.advantage-list {
  display: flex;
  flex-direction: column;
}

.advantage-row {
  display: grid;
  grid-template-columns: 48px 260px 36px 1fr;
  gap: 20px;
  align-items: flex-start;
  padding: 22px 0;
  border-bottom: 1px solid #ececec;
}

.advantages.block--dark .advantage-row {
  border-bottom-color: var(--color-border-soft);
}

.advantage-row:last-child {
  border-bottom: none;
}

.advantage-row__icon {
  width: 34px;
  height: 34px;
  margin-top: -4px;
  color: var(--color-accent);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Dark-on-dark gold fix — same recipe as `.element-card__icon`/`.about__img`
   ([[project_perfectmoments_dark_icon_refinement]]): var(--color-accent)
   (#9a7b3f) reads muddy on the dark var(--color-bg-about) background, so
   dark theme picks up the lighter gold-gradient stop instead. Icon SVG stays
   `currentColor` (icons.py's dark branch), so this is CSS-only. */
.advantages.block--dark .advantage-row__icon {
  color: #c9a768;
}

.advantage-row__icon svg {
  width: 27px;
  height: 27px;
}

.advantages.block--dark .advantage-row__icon svg {
  stroke-width: 1.15;
}

.advantage-row__arrow {
  width: 28px;
  height: 28px;
  color: var(--color-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: -1px;
  animation: arrow-sweep 1.8s ease-in-out infinite;
}

@keyframes arrow-sweep {
  0%, 100% { transform: translateX(0); }
  50% { transform: translateX(6px); }
}

@media (prefers-reduced-motion: reduce) {
  .advantage-row__arrow {
    animation: none;
  }
}

.advantage-row__arrow svg {
  width: 22px;
  height: 22px;
}

.advantage-row__title {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 700;
  text-transform: uppercase;
  line-height: 1.2;
  color: #1a1a1a;
}

.advantages.block--dark .advantage-row__title {
  color: var(--color-text);
}

.advantage-row__text {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 400;
  line-height: 1.55;
  color: #414141;
  padding-top: 0;
}

.advantages.block--dark .advantage-row__text {
  color: var(--color-text-secondary);
}

/* ==========================================================================
   Team section
   ========================================================================== */

/* Standard section rhythm (0 top / 51 bottom desktop, 0/32 mobile — see the
   `images`/`video_all` blocks) + standard 20px heading→cards gap, matched to
   the reference `images` block instead of the generic 40px default. */
.team-section {
  padding-top: 0;
}

.team-section .section-heading {
  text-align: left;
  margin-bottom: 20px;
}

.team-section.block--dark {
  background: #363636;
}

.team-section.block--dark .section-heading {
  color: #ffffff;
}

.team-slider {
  position: relative;
}

.team-grid {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  gap: 24px;
  padding-bottom: 8px;
  scroll-behavior: smooth;
  scrollbar-width: none;
}

.team-grid::-webkit-scrollbar {
  display: none;
}

.team-card {
  flex: 0 0 340px;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  border-radius: var(--radius);
  overflow: hidden;
}

.team-section.block--dark .team-card {
  border: 1px solid rgba(255, 255, 255, 0.14);
}

/* Light theme (same recipe as `.reviews-section.block--light .review-card` /
   `.section--elements.block--light .element-card`): white card on white section,
   border + soft shadow instead of a flat colour change. */
.team-section.block--light .team-card {
  border: 1px solid #e6e6e6;
  background: #ffffff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
}

.team-card__media {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1 / 1;
}

.team-card__media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.team-card__caption {
  padding: 16px 20px 18px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.team-card__name {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 700;
}

.team-card__role {
  font-size: 14px;
}

.team-section.block--dark .team-card__name {
  color: #ffffff;
}

.team-section.block--dark .team-card__role {
  color: #b0b0b0;
}

.team-section.block--light {
  background: #ffffff;
}

.team-section.block--light .section-heading {
  color: #1a1a1a;
}

.team-section.block--light .team-card__name {
  color: #1a1a1a;
}

.team-section.block--light .team-card__role {
  color: #6f6f6f;
}

/* ==========================================================================
   Reviews section
   ========================================================================== */

.reviews-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.review-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 28px;
  border-radius: var(--radius);
}

.review-card__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  row-gap: 6px;
}

.review-card__stars {
  color: var(--color-accent);
  font-size: 18px;
  letter-spacing: 3px;
}

.review-card__text {
  font-size: 15px;
  line-height: 1.6;
  flex: 1;
}

.review-card__person {
  display: flex;
  align-items: center;
  gap: 12px;
}

.review-card__avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.review-card__avatar svg {
  width: 22px;
  height: 22px;
}

.review-card__author {
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 700;
}

/* Light theme (default — matches the original home-page design): white section +
   white cards. Dark theme: section matches the site's dark sections, cards use the
   same translucent --color-surface treatment as `.element-card`. */
.reviews-section.block--light {
  background: #ffffff;
}

.reviews-section.block--light .section-heading {
  color: #1a1a1a;
}

.reviews-section.block--light .review-card {
  border: 1px solid #e6e6e6;
  background: #ffffff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
}

.reviews-section.block--light .review-card__date {
  color: #9a9a9a;
}

.reviews-section.block--light .review-card__text {
  color: #414141;
}

.reviews-section.block--light .review-card__avatar {
  background: #ececec;
  color: #8a8a8a;
}

.reviews-section.block--light .review-card__author {
  color: #1a1a1a;
}

.reviews-section.block--dark {
  background: var(--color-bg-about);
}

.reviews-section.block--dark .review-card {
  border: 1px solid var(--color-border-soft);
  background: var(--color-surface);
}

.reviews-section.block--dark .review-card__date {
  color: var(--color-text-muted);
}

.reviews-section.block--dark .review-card__text {
  color: var(--color-text-secondary);
}

.reviews-section.block--dark .review-card__avatar {
  background: rgba(255, 255, 255, 0.08);
  color: var(--color-text-secondary);
}

.reviews-section.block--dark .review-card__author {
  color: var(--color-text);
}

/* ==========================================================================
   SMI (press) section
   ========================================================================== */

.press-section {
  background: #ffffff;
}

.press-section .section-heading {
  color: #1a1a1a;
}

.press-slider {
  position: relative;
}

.press-grid {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  gap: 24px;
  padding-bottom: 8px;
  scroll-behavior: smooth;
  scrollbar-width: none;
}

.press-grid::-webkit-scrollbar {
  display: none;
}

.press-card {
  flex: 0 0 340px;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  border: 1px solid #e6e6e6;
  border-radius: var(--radius);
  overflow: hidden;
  background: #ffffff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
}

.press-card__media {
  position: relative;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, #f4f4f4, #e7e7e7);
}

/* Shared media-type sticker badge — originally `.press-card__badge` (home.html's "О нас
   говорят в СМИ" slider), generalised so the `smi_*` block cards (templates/site/blocks/
   smi_report.html and friends, BlockSmi*Card.sticker) can reuse the same look over their
   own cover box; `--tl`/`--tr` pick the corner. */
.media-badge {
  position: absolute;
  z-index: 2;
  background: rgba(0, 0, 0, 0.55);
  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 5px 11px;
  border-radius: 999px;
  pointer-events: none;
}

.media-badge--tl {
  top: 12px;
  left: 12px;
}

.media-badge--tr {
  top: 12px;
  right: 12px;
}

.press-card__body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 18px 20px 20px;
  flex: 1;
}

.press-card__title {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 700;
  line-height: 1.35;
  color: #1a1a1a;
}

.press-card__teaser {
  font-size: 14px;
  line-height: 1.55;
  color: #414141;
  flex: 1;
}

.press-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 4px;
}

.press-card__source {
  font-size: 13px;
  font-weight: 700;
  color: #1a1a1a;
}

.press-card__date {
  font-size: 13px;
  color: #9a9a9a;
}

/* ---- smi_pick block ("О нас говорят в СМИ" слайдер): horizontal slider over
   `.service-card.smi-card` (the same dual-theme card the picked cards already render with
   on /smi-o-nas/) — same scoped flex-slider recipe as `.services`/`.section--more-ideas`'
   `.card-grid` override above, just scoped to this block's own section class instead of
   inventing a new card look. Dark/light colours come for free from the existing
   `.section--smi(.block--light)` rules (this section always carries both classes). */
.smi-pick-slider {
  position: relative;
}

.section--smi-pick .card-grid {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  gap: 24px;
  padding-bottom: 8px;
  scroll-behavior: smooth;
  scrollbar-width: none;
}

.section--smi-pick .card-grid::-webkit-scrollbar {
  display: none;
}

.section--smi-pick .service-card {
  flex: 0 0 340px;
  scroll-snap-align: start;
}

@media (max-width: 720px) {
  .section--smi-pick .service-card {
    flex: 0 0 82vw;
  }
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
  background: var(--color-footer);
}

.site-footer__inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 32px;
  padding: 56px 20px 40px;
}

.logo--footer {
  font-size: 22px;
}

.footer-tagline {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 14px;
  color: var(--color-text-secondary);
  margin: 4px 0 20px;
  max-width: 240px;
  text-transform: none;
}

.footer-heading {
  font-size: 13px;
  color: var(--color-text);
  margin-bottom: 16px;
  text-transform: uppercase;
}

.footer-list li {
  margin-bottom: 10px;
  font-size: 14px;
  color: var(--color-text-secondary);
}

.footer-list a:hover {
  color: var(--color-accent);
}

.social-links {
  display: flex;
  gap: 10px;
  margin-top: 32px;
}

.social-link {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.social-link svg {
  width: 16px;
  height: 16px;
}

.social-link:hover {
  background: rgba(255, 255, 255, 0.22);
}

/* Yandex Business rating badge — third line of the brand column, same 32px
   rhythm as the logo → social-links gap above it. */
.footer-rating {
  margin-top: 32px;
}

.footer-rating iframe {
  display: block;
  max-width: 100%;
  border: 0;
}

.site-footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 16px 0;
  font-size: 12px;
  color: var(--color-text-muted);
  text-align: center;
}

/* ==========================================================================
   «Виджет контакты» — floating button, same geometry and CSS-only checkbox toggle
   as the old Tilda t898 widget. Channels fan out upwards from the toggle; the last
   channel in the panel's order sits nearest to it, so the on-screen order reads
   top-to-bottom like the panel's list.
   ========================================================================== */

.contact-widget {
  position: fixed;
  right: 65px;
  bottom: 60px;
  z-index: 2200; /* above the header, nav drawer and lead popup; the lightbox (3000) covers it */
  width: 60px;
  height: 60px;
  pointer-events: none;
}

/* Focusable (unlike the original's display:none), so the toggle works from the keyboard */
.contact-widget__input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.contact-widget__toggle {
  position: relative;
  z-index: 2;
  display: block;
  width: 60px;
  height: 60px;
  margin: 0;
  border-radius: 50%;
  background: #075e54;
  box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.3);
  cursor: pointer;
  overflow: hidden;
  pointer-events: auto;
  transition: all 0.2s ease-in-out;
  -webkit-tap-highlight-color: transparent;
}

.contact-widget__toggle:hover {
  box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.4);
}

.contact-widget__input:focus-visible + .contact-widget__toggle {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

.contact-widget__icon {
  position: absolute;
  inset: 0;
  margin: auto;
  transition: all 0.3s ease-in-out;
}

.contact-widget__icon--close {
  opacity: 0;
  visibility: hidden;
  transform: scale(0.1);
}

.contact-widget__input:checked + .contact-widget__toggle {
  background: #fff;
}

.contact-widget__input:checked + .contact-widget__toggle .contact-widget__icon--chat {
  opacity: 0;
  visibility: hidden;
  transform: scale(0.1);
}

.contact-widget__input:checked + .contact-widget__toggle .contact-widget__icon--close {
  opacity: 1;
  visibility: visible;
  transform: scale(1);
}

.contact-widget__item {
  position: absolute;
  inset: 0;
  margin: auto;
  display: block;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.3);
  opacity: 0;
  visibility: hidden;
  pointer-events: auto;
  transition: all 0.3s ease-in-out;
}

.contact-widget__item:hover {
  box-shadow: 0 0 20px 0 rgba(0, 0, 0, 0.4);
}

.contact-widget__input:checked ~ .contact-widget__item {
  opacity: 1;
  visibility: visible;
}

.contact-widget__input:checked ~ .contact-widget__item:nth-last-of-type(1) { transition-duration: 0.2s; transform: translateY(-135%); }
.contact-widget__input:checked ~ .contact-widget__item:nth-last-of-type(2) { transition-duration: 0.225s; transform: translateY(-255%); }
.contact-widget__input:checked ~ .contact-widget__item:nth-last-of-type(3) { transition-duration: 0.25s; transform: translateY(-375%); }
.contact-widget__input:checked ~ .contact-widget__item:nth-last-of-type(4) { transition-duration: 0.275s; transform: translateY(-495%); }
.contact-widget__input:checked ~ .contact-widget__item:nth-last-of-type(5) { transition-duration: 0.3s; transform: translateY(-615%); }
.contact-widget__input:checked ~ .contact-widget__item:nth-last-of-type(6) { transition-duration: 0.325s; transform: translateY(-735%); }

.contact-widget__item svg {
  display: block;
  width: 50px;
  height: 50px;
}

.contact-widget__label {
  position: absolute;
  top: 50%;
  right: 80px;
  transform: translateY(-50%);
  padding: 9px 13px;
  border-radius: 3px;
  background: #292929;
  color: #fff;
  font-size: 15px;
  line-height: 1.3;
  white-space: nowrap;
  opacity: 0.85;
  transition: opacity 0.1s linear;
}

.contact-widget__item:hover .contact-widget__label,
.contact-widget__item:focus-visible .contact-widget__label {
  opacity: 1;
}

.contact-widget__label::after {
  content: '';
  position: absolute;
  top: 50%;
  right: -20px;
  width: 0;
  height: 0;
  border: 10px solid transparent;
  border-left-color: #292929;
  transform: translateY(-50%);
}

@media (max-width: 960px) {
  .contact-widget {
    right: 10px;
    bottom: 20px;
  }

  .contact-widget__label {
    font-size: 12px;
  }

  .contact-widget__label::after {
    right: -16px;
    border-width: 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .contact-widget__toggle,
  .contact-widget__icon,
  .contact-widget__item {
    transition: none;
  }
}

/* ==========================================================================
   Generic page header (catalog / blog / photo / video / contacts)
   ========================================================================== */

.page-header {
  text-align: center;
  padding: 24px 0 48px;
}

.page-header__title {
  font-size: clamp(24px, 4vw, 36px);
}

/* Document pages (policy / offer / cookies / consent): the text fills the container's
   content width like the rest of the site's sections — no narrower reading column. */
.page-content {
  line-height: 1.7;
  white-space: pre-wrap;
}

.page-content h2,
.page-content h3 {
  margin: 32px 0 12px;
}

.page-content p {
  margin: 0 0 16px;
}

.page-content ul,
.page-content ol {
  margin: 0 0 16px;
  padding-left: 24px;
}

/* Legal requisites block — rendered inside document pages via [реквизиты] marker.
   Overrides the parent .page-content's pre-wrap + 1.7 line-height to produce a
   tidy bordered card with tight rows (no doubled gaps from preserved newlines). */
.doc-requisites {
  white-space: normal;            /* гасим pre-wrap контейнера документа — он и давал двойные отступы */
  margin: 10px 0 4px;
  padding: 20px 24px;
  border: 1px solid var(--color-border-soft);
  border-radius: 12px;
  background: var(--color-surface);
  line-height: 1.5;               /* плотнее, чем 1.7 у текста документа */
}

.doc-requisites__name {
  margin: 0 0 10px;
  color: var(--color-text);
  font-weight: 700;
}

.doc-requisites__row {
  margin: 0 0 6px;
  color: var(--color-text-secondary);
}

.doc-requisites__row:last-child {
  margin-bottom: 0;
}

.doc-requisites__num {
  color: var(--color-text);
  font-variant-numeric: lining-nums tabular-nums;
  letter-spacing: 0.01em;
}

@media (max-width: 720px) {
  .doc-requisites {
    padding: 16px 18px;
  }
  
  .doc-requisites__num {
    word-break: break-all;        /* длинные номера на узких экранах переносятся вместо создания скролла */
  }
}

.placeholder-card {
  border: 1px solid var(--color-border-soft);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--color-surface);
}

.placeholder-card__media {
  aspect-ratio: 4 / 3;
  background: linear-gradient(135deg, #3a3a3a, #202020);
}

.placeholder-card__body {
  padding: 18px;
}

.placeholder-card__title {
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--color-text);
  margin-bottom: 6px;
}

.placeholder-card__text {
  font-size: 13px;
  color: var(--color-text-secondary);
}

.contacts-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
  align-items: start;
}

.contacts-info dt {
  font-size: 12px;
  text-transform: uppercase;
  color: var(--color-text-secondary);
  margin-top: 20px;
}

.contacts-info dd {
  font-size: 16px;
  font-weight: 700;
  margin: 4px 0 0;
  color: var(--color-text);
}

/* ==========================================================================
   Shrink-safety for grid/flex children (prevents horizontal overflow)
   ========================================================================== */

.hero__content > *,
.about__grid > *,
.about__cols3 > *,
.about__cols2 > *,
.card-grid > *,
.stats > *,
.media-grid > *,
.reviews-grid > *,
.contacts-grid > *,
.site-footer__inner > * {
  min-width: 0;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 960px) {
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .card-grid--3 { grid-template-columns: repeat(2, 1fr); }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(2n) { border-right: none; }
  .reviews-grid { grid-template-columns: repeat(2, 1fr); }
  .site-footer__inner { grid-template-columns: 1fr 1fr; }
  .contacts-grid { grid-template-columns: 1fr; }
  .about__grid { grid-template-columns: 1fr; gap: 24px; }
  .about__rows { gap: 24px; margin-bottom: 24px; }
  .about__cols3 { grid-template-columns: 1fr; gap: 24px; }
  .about__cols2 { grid-template-columns: 1fr; gap: 24px; }
  .hero__arrow { display: none; }
}

/* Mobile-only: hero title wraps whole words, couple is bottom-anchored at
   ~90vw with a bottom fade, and sliders bleed to the right screen edge. */
@media (max-width: 768px) {
  .logo img {
    height: 43px !important;
  }

  /* .logo is the tallest item in .site-header__inner, so it already sits
     flush at the top under align-items: center. Switching to flex-start
     lifts .header-right (and its taller child, .header-icons) up to match
     that top edge, while .header-icons keeps align-items: center so the
     shorter burger stays vertically centered against the TG/WA icons. */
  .site-header__inner {
    align-items: flex-start;
  }

  /* .hero__title-wrap becomes the sticker's positioned ancestor here (instead of
     .hero__content) so top:-10px/right:-6px resolves against the title plate's own box,
     not the whole hero content area — width:100% matches .hero__title's own width:100%
     below so both boxes coincide and the sticker lands on the plate's corner. */
  .hero__title-wrap {
    display: block;
    position: relative;
    width: 100%;
    margin-top: 27px;
    margin-bottom: 32px;
  }

  /* .hero__title's own margin (above) and display:inline-block (below) both need to move
     to/be neutralized on the wrap: grid items establish their own formatting context, so
     a margin left on .hero__title here would stay INSIDE .hero__title-wrap's box instead
     of collapsing through to it (unlike when .hero__title was the bare grid item) — that
     left the wrap's top edge (the sticker's -10px anchor) sitting a margin's-width above
     the title's actual visual top. Zeroing the margin here (now carried by the wrap
     instead, above) and forcing block (removing the inline-formatting-context line-box
     strut) makes the wrap's box coincide exactly with the title's own box. */
  .hero__title-wrap > .hero__title {
    display: block;
    margin: 0;
  }

  .hero__title {
    overflow-wrap: normal;
    word-break: normal;
    hyphens: none;
    font-size: clamp(20px, 6.1vw, 27px);
    text-align: center;
    margin-top: 27px;
    width: 100%;
    display: inline-block;
    position: relative;
    background: rgba(0, 0, 0, 0.35);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: 8px;
    padding: 10px 14px;
  }

  .hero__title::after {
    content: "";
    position: absolute;
    top: -10px;
    right: -6px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: #9a7b3f;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='white' d='M12 2L8.5 9L2 5L4 17L20 17L22 5L15.5 9Z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 17px 17px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
    pointer-events: none;
  }

  .hero__title-accent {
    color: #9a7b3f;
  }

  .hero__cutout {
    top: auto;
    left: 50%;
    right: auto;
    bottom: 20px;
    width: min(173.95vw, 750px);
    max-width: min(173.95vw, 750px);
    height: auto;
    transform: translateX(calc(-55.74% + 60px));
    object-position: bottom center;
  }

  /* Compact hero layout (normally only applied ≤720px) is needed for the
     full 320-768px mobile range so the title stays top-anchored and the
     couple never overlaps it. */
  .hero {
    min-height: 670px;
  }

  .hero__content {
    min-height: 670px;
    align-content: start;
    padding: 72px 20px 24px;
  }

  .hero__list-cta-group {
    margin-top: 240px;
  }

  /* Group spans the full content width (= the title plate's width), so the
     button and the advantages share that width and left-align to each other. */
  .hero__list-cta-group {
    display: flex;
    flex-direction: column;
    width: 100%;
    justify-self: center;
  }

  .hero__list {
    width: 100%;
    /* Whole-ul fade (base rule) is replaced by the per-item stagger below. */
    opacity: 1;
    animation: none;
    /* Visual-only shift (doesn't affect flow/siblings): advantages sit 70px
       higher than the group's flow position, while .hero__cta-wrap below
       stays exactly where the group's margin-top puts it. */
    position: relative;
    top: -70px;
  }

  .hero__cta-wrap {
    width: 100%;
    margin-top: -15px;
    /* Starts once the last advantage chip has slid in (see li delays below). */
    animation-delay: 0.5s;
  }

  .hero__list li {
    font-size: 16px;
    margin-bottom: 6px;
    opacity: 0;
    transform: translateX(-60px);
    animation: heroAdvIn 0.4s ease-out forwards;
  }

  /* Base delay lines up with the title fade so the group appears only after
     the header and hero images have faded in. */
  .hero__list li:nth-child(1) { animation-delay: 0.2s; }
  .hero__list li:nth-child(2) { animation-delay: 0.3s; }
  .hero__list li:nth-child(3) { animation-delay: 0.4s; }

  @keyframes heroAdvIn {
    from {
      opacity: 0;
      transform: translateX(-60px);
    }
    to {
      opacity: 1;
      transform: translateX(0);
    }
  }

  .hero__list li::before {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M24 12.0001L7.2 24L-2.09812e-07 19.2001L-8.39254e-07 4.8001L7.2 -7.04873e-07L24 12.0001ZM19.9186 11.9841L7.65335 20.745L2.39681 17.2406L2.39681 6.72749L7.65335 3.22322L19.9186 11.9841Z' fill='%23ffffff'/%3E%3C/svg%3E") no-repeat center / contain;
  }

  .hero__cta {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    box-sizing: border-box;
    text-align: center;
    font-size: 15px;
    padding: 18px 16px;
    letter-spacing: 0.02em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  /* Couple's visible height is ~98vw at this render width; fade covers ~40% of that. */
  .hero__cutout-fade {
    display: block;
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 52vw;
    z-index: -1;
    pointer-events: none;
    background: linear-gradient(to bottom, rgba(17, 17, 17, 0) 0%, rgba(17, 17, 17, 0.92) 70%, #111111 100%);
  }

  .services-slider,
  .photos-slider,
  .videos-slider,
  .team-slider,
  .press-slider {
    margin-right: -20px;
  }
}

@media (max-width: 768px) and (prefers-reduced-motion: reduce) {
  .hero__list li {
    opacity: 1;
    transform: none;
    animation: none;
  }
}

@media (max-width: 720px) {
  .site-phone { display: none; }

  .hero { min-height: 670px; }
  .hero__content {
    min-height: 670px;
    align-content: start;
    padding: 72px 20px 24px;
  }
  .hero__list-cta-group { margin-top: 240px; }

  .card-grid,
  .card-grid--3 { grid-template-columns: 1fr; }

  /* `services` block: 2-up on mobile (instead of the 1-col default above) — card
     width roughly halves vs. the /photo/ gallery cards, so title/link shrink to
     match (those stay full-width/1-col on mobile and keep the larger 15px/13px). */
  .section--services .card-grid--3 {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
  .section--services .service-card__body { padding: 12px; }
  .section--services .service-card__title { font-size: 12.5px; line-height: 1.3; margin-bottom: 6px; }
  .section--services .service-card__link { font-size: 11px; gap: 4px; }

  .stats { grid-template-columns: 1fr 1fr; gap: 16px; }
  .advantage-row { grid-template-columns: 42px 1fr; gap: 12px; padding: 18px 0; }
  .advantage-row__arrow { display: none; }
  .advantage-row__text { grid-column: 1 / -1; padding-top: 0; }
  /* Mobile type scale for the lines — same pair as the FAQ rows (question 15px
     uppercase / answer 14px, see `.faq-item__question-text` 640px rule). The
     22px/700 desktop title equalled the 22px section heading and out-weighed it;
     weight drops to the heading's 400 so a line title never reads louder. */
  .advantages .advantage-row__title { font-size: 15px; font-weight: 400; line-height: 1.35; }
  .advantages .advantage-row__text { font-size: 14px; }
  .media-grid { grid-template-columns: repeat(2, 1fr); }
  .photo-card { flex-basis: 82vw; }
  .video-card { flex-basis: 100%; }
  /* `video_slider` block: one card at 84% of the track, so the next card's left edge peeks
     past the 24px gap (~32px sliver on a 390px phone) and the row reads as swipeable.
     Snap stays `start`; main.js steps by card width + gap, so arrows still land on a card. */
  .section--video-slider .video-card { flex-basis: 84%; }
  .reviews-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .review-card { padding: 16px; }
  .press-card { flex-basis: 82vw; }
  .team-card { flex-basis: 82vw; }
  .site-footer__inner { grid-template-columns: 1fr; }
  .section { padding: 32px 0; }
  .section--images,
  .section--description,
  .section--gallery-categories,
  .section--video-categories,
  .section--pricing,
  .section--posts-grid,
  .section--smi,
  .section--about-bg,
  .section--categories,
  .section--faq,
  .section--category-slider,
  .section--posts-slider,
  .section--gallery-slider,
  .section--video-album-slider,
  .stats-section,
  .advantages,
  .reviews-section,
  .section--article,
  .section--button,
  .team-section { padding-top: 0; }
  .section--divider { padding: 0; height: 32px; }
  .more-ideas__cta { margin-top: 16px; }
  .images-see-all { text-align: center; }
  .section--images .section-heading { font-size: 24px; }

  /* `images` block, mobile 2-col grid: drop the last photo when the total count is
     odd, so the last row never ends with a single orphan cell + empty hole. A lone
     photo (total = 1) is kept — the :not(:nth-child(1 of …)) excludes that case since
     there's no hole to fix. Desktop (3-col) always shows every photo. Every position is
     counted `of .media-grid__item`, not by plain DOM child: images.html puts the JSON-LD
     <script> inside the grid (so a plain :nth-last-child(1) is the script and never
     matches), and on album pages «Показать ещё» appends more photos *after* that script
     (so a plain :nth-child(odd) is off by one). Applies to every `images` block on every
     page type — they all render via images.html's `.section--images` wrapper.
     `:not(.section--video)` excludes the video grid, which is still forced to 1 column at
     this width (see the `max-width: 860px` override above) — there's never an orphan cell
     to fix there, so this would otherwise just hide the last video whenever the count is odd. */
  .section--images:not(.section--video) .media-grid > :nth-last-child(1 of .media-grid__item):nth-child(odd of .media-grid__item):not(:nth-child(1 of .media-grid__item)) {
    display: none;
  }
}

@media (max-width: 600px) {
  .stats { grid-template-columns: 1fr 1fr; gap: 12px; }
  .reviews-grid { grid-template-columns: 1fr; }
}

@media (max-width: 360px) {
  .stats { grid-template-columns: 1fr; }
  .stat:not(:last-child) { border-right: none; border-bottom: 1px solid #d9d9d9; padding-bottom: 16px; margin-bottom: 8px; }
}

/* ==========================================================================
   Level-2 category landing page (hero without background image + elements)
   ========================================================================== */
.l2-hero {
  background: var(--color-bg);
  padding: 64px 0 48px;
}

.l2-hero__title {
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 400;
  line-height: 1.15;
  max-width: 820px;
  color: var(--color-text);
  margin-bottom: 16px;
  hyphens: auto;
}

.l2-hero .hero__list-cta-group {
  margin-top: 0;
}

/* ==========================================================================
   Category landing blocks (block constructor: hero / description / intro / elements)
   ========================================================================== */

/* Hero block — same markup/classes as the home hero, minus the cutout.
   Desktop cover is swapped for a mobile cover below 768px when provided.
   Unlike home's curated bg.png, the cover here is an arbitrary admin upload,
   so on top of home's header-area gradient (kept identical, top 30%) this
   adds a full-height darkening layer so title/advantages/button stay
   readable no matter how bright the photo is. */
.hero--l2 .hero__scrim {
  height: 100%;
  background:
    linear-gradient(0turn, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 1) 100%) top / 100% 30% no-repeat,
    linear-gradient(180deg, rgba(0, 0, 0, 0.25) 0%, rgba(0, 0, 0, 0.45) 100%) no-repeat;
}

/* Hero block's mobile title-plate sticker is admin-controlled (same mechanism as Hero
   FULL above) — it replaces the generic hardcoded crown ::after on the plain
   .hero__title (still used as-is by the non-block-driven home page hero). */
.hero--l2 .hero__sticker {
  display: none;
}

@media (max-width: 768px) {
  .hero--l2 .hero__title::after {
    display: none;
  }

  .hero--l2 .hero__sticker {
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: -10px;
    right: -6px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: #9a7b3f;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
    pointer-events: none;
  }
}

/* Мини Hero block — same background mechanics as Hero (.hero--l2 above), but a
   short horizontal banner of a FIXED height (not Hero's tall fixed min-height,
   and not sized from the image's aspect-ratio) and a top-only darkening
   gradient (not l2's full-height dim, which would flatten a banner this
   short) so the heading stays readable without hiding the photo. Crop
   targets match this strip's shape (see MINI_HERO_CROP_SIZES in panel/views.py). */
.hero--mini {
  min-height: 0;
  height: 420px;
}

.hero--mini .hero__content {
  min-height: 0;
  height: 100%;
  align-content: center;
  padding: 32px 20px;
}

.hero--mini .hero__title {
  text-transform: uppercase;
  margin-bottom: 0;
}

.hero--mini .hero__scrim {
  height: 65%;
  background: linear-gradient(0turn, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.85) 100%);
}

@media (max-width: 768px) {
  .hero--mini {
    min-height: 0;
    height: 220px;
  }

  .hero--mini .hero__content {
    min-height: 0;
    height: 100%;
    padding: 20px 20px;
  }

  /* Client request: mini hero stays plain text on mobile, no plate/sticker. */
  .hero--mini .hero__title {
    background: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border-radius: 0;
    padding: 0;
  }

  .hero--mini .hero__title::after {
    display: none;
  }
}

/* Hero blog block — same background mechanics as Hero/Мини Hero (.hero--l2 above), sized
   to match the old site's blog-post hero (Tilda T396 record, measured via curl on
   https://perfectmoments.ru/10-krasivyh-sposobov-sdelat-predlozhenie-devushke): fixed
   height 523px desktop (the old site's default artboard height), ~320px mobile (between
   the old site's 282px/≤479px and 387px/480-639px breakpoints). Unlike Мини Hero it also
   renders an optional «Тезис» thesis line below the H1 and supports the dark/light theme
   picker (Block.BLOCKS_WITH_THEMES) instead of staying dark-only. */
.hero--blog {
  min-height: 0;
  height: 523px;
}

.hero--blog .hero__content {
  min-height: 0;
  height: 100%;
  align-content: center;
  padding: 40px 20px;
}

.hero--blog .hero__title {
  margin-bottom: 16px;
}

.hero--blog .hero__thesis {
  max-width: 760px;
  font-size: clamp(16px, 2vw, 20px);
  font-weight: 400;
  line-height: 1.4;
  color: var(--color-text);
}

/* Light theme still needs the top darkening band kept (just lighter) — the site header
   overlaid on the hero always renders white text/logo, regardless of this block's theme. */
.hero--blog.block--light .hero__scrim {
  height: 100%;
  background:
    linear-gradient(0turn, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.5) 100%) top / 100% 30% no-repeat,
    linear-gradient(0deg, rgba(255, 255, 255, 0.92) 0%, rgba(255, 255, 255, 0) 55%) no-repeat;
}

.hero--blog.block--light .hero__title {
  color: #1a1a1a;
}

.hero--blog.block--light .hero__thesis {
  color: #4a4a4a;
}

@media (max-width: 768px) {
  .hero--blog {
    min-height: 0;
    height: 320px;
  }

  .hero--blog .hero__content {
    min-height: 0;
    height: 100%;
    padding: 24px 20px;
  }

  /* Same client-requested stripping of the generic mobile .hero__title plate/sticker
     (see .hero--mini above) — a blog post heading + thesis reads better as plain text. */
  .hero--blog .hero__title {
    background: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border-radius: 0;
    padding: 0;
    margin-top: 0;
  }

  .hero--blog .hero__title::after {
    display: none;
  }

  .hero--blog .hero__thesis {
    text-align: center;
    margin: 0 auto;
  }
}

/* Hero FULL block — reuses the bare .hero class with NO size/background modifier, i.e.
   the exact same background mechanics (bg.webp + cutout.webp + gradients + plate) as the
   home page's own hero (see templates/site/home.html) — per client requirement these
   stay pixel-identical and are never themed or overridden below. .hero--full only scopes
   the admin-chosen mobile sticker (a real element, since its icon is dynamic — unlike the
   hardcoded crown ::after on the plain .hero__title) and a light-theme text/readability
   treatment, same idea as .hero--blog.block--light above. */
.hero--full .hero__sticker {
  display: none;
}

@media (max-width: 768px) {
  /* The chosen sticker replaces the generic hardcoded crown ::after for this block type. */
  .hero--full .hero__title::after {
    display: none;
  }

  .hero--full .hero__sticker {
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: -10px;
    right: -6px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: #9a7b3f;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
    pointer-events: none;
  }
}

/* Light theme: unlike every other themed block, Hero FULL's photo/gradients are a fixed,
   non-admin-controlled asset (client requirement — see the comment above) already tuned
   for white text, so there's no safe way to flip to dark text across the whole desktop
   hero without an extra dimming/lightening layer thick enough to visibly alter the
   "подложка" gradient itself — which is exactly what must NOT change. Tested with a
   bottom-anchored light wash (like .hero--blog.block--light above): the upper-left title
   area, where the photo is darkest and busiest, stayed unreadable with dark text. So the
   theme step only affects the one surface that's already an opaque UI plate rather than
   bare photo — the mobile title/sticker plate — leaving the desktop hero visually
   identical in both themes. */
@media (max-width: 768px) {
  .hero--full.block--light .hero__title {
    background: rgba(255, 255, 255, 0.75);
    color: #1a1a1a;
  }

  .hero--full.block--light .hero__sticker {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
  }
}

.l2-description__text {
  max-width: 820px;
  color: var(--color-text);
}

.l2-description__text p:not(:last-child) {
  margin-bottom: 16px;
}

/* Standard section rhythm (same as `.section` + the per-block `padding-top: 0` override
   used by images/faq/video/etc.): 0 top / 51px bottom desktop, 0 / 32px mobile. The
   former uniform `72px 0` was sized for the (now removed) photo-background banner. */
.l2-intro {
  position: relative;
  overflow: hidden;
  padding: 0 0 51px;
  background: var(--color-bg-about);
}

@media (max-width: 720px) {
  .l2-intro {
    padding-bottom: 32px;
  }
}

/* Fixed background (the block has no photo upload): a quiet premium ornament — a soft
   gold sheen plus a pair of linked-ring outlines (nods to the "marriage proposal" brand)
   in the site's gold gradient (#c9a768 → #9a7b3f → #6b5329). Pure CSS/inline SVG: no
   extra request, crisp at any zoom. */
.l2-intro--ornament::before {
  content: "";
  position: absolute;
  /* Inset (not inset:0) so the ornament's own box never reaches the block's true
     edges — guarantees a pure-base-colour border even before the mask below runs,
     so two same-coloured blocks stacked together show no seam at the boundary. */
  inset: 48px;
  z-index: 0;
  pointer-events: none;
  /* The sheen's own 2-stop fade (colour -> "transparent 70%") used to be a plain
     linear ramp: alpha stays flat for r<0 (nothing, it's the centre) then drops
     at a constant rate all the way to 0 at r=70%, where it then goes flat again
     (CSS extends the last stop). Flat->linear->flat has zero derivative on both
     flat sides but a NONZERO one throughout the ramp — most noticeably the kink
     right at r=70% (slope jumps from negative to 0) reads as a visible "cloud
     edge" around the sheen. Smoothstep below keeps the centre (r=0) at full
     peak alpha and reaches exactly 0 at r=70% with zero slope on both ends, so
     the fade has no derivative discontinuity anywhere — this was the actual
     source of the "band"/"boundary" the client screenshotted (not the block's
     true edge, which the ::after vignette further down already matched to the
     neighbour's colour). */
  background-image:
    radial-gradient(ellipse 55% 60% at 80% 20%,
      rgba(201, 167, 104, 0.1400) 0%,
      rgba(201, 167, 104, 0.1361) 7%,
      rgba(201, 167, 104, 0.1254) 14%,
      rgba(201, 167, 104, 0.1098) 21%,
      rgba(201, 167, 104, 0.0907) 28%,
      rgba(201, 167, 104, 0.0700) 35%,
      rgba(201, 167, 104, 0.0493) 42%,
      rgba(201, 167, 104, 0.0302) 49%,
      rgba(201, 167, 104, 0.0146) 56%,
      rgba(201, 167, 104, 0.0039) 63%,
      transparent 70%),
    url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 480 480%27%3E%3Cdefs%3E%3ClinearGradient id=%27g%27 x1=%270%25%27 y1=%270%25%27 x2=%27100%25%27 y2=%27100%25%27%3E%3Cstop offset=%270%25%27 stop-color=%27%23c9a768%27/%3E%3Cstop offset=%2750%25%27 stop-color=%27%239a7b3f%27/%3E%3Cstop offset=%27100%25%27 stop-color=%27%236b5329%27/%3E%3C/linearGradient%3E%3C/defs%3E%3Cg fill=%27none%27 stroke=%27url%28%23g%29%27 stroke-width=%271.4%27 stroke-opacity=%270.42%27%3E%3Ccircle cx=%27190%27 cy=%27280%27 r=%27110%27/%3E%3Ccircle cx=%27190%27 cy=%27280%27 r=%2797%27/%3E%3Ccircle cx=%27300%27 cy=%27200%27 r=%27110%27/%3E%3Ccircle cx=%27300%27 cy=%27200%27 r=%2797%27/%3E%3C/g%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center, right bottom;
  background-size: auto, 340px;
  /* Soft falloff on top of the inset: fades the ornament out well before its own
     (already-inset) box edges, so there is no hard rectangle visible either.
     Real root cause of the still-visible "band"/"boundary" the client kept
     screenshotting: `ellipse 80% 80%` sizes the mask's radii as 80% of the
     ::before box's FULL width/height — i.e. 1.6x the centre-to-edge distance —
     so inside the actual box the mask radius never gets anywhere near its own
     100% stop and the content barely fades at all before hitting the box's
     hard rectangular clip (nothing is painted outside a pseudo-element's own
     box). The previous fix (::after vignette, still below) only guarantees the
     *block's* true outer edge matches the neighbour — it never touched this
     inner 48px-inset box's own boundary, which is what was actually visible.
     `farthest-side` (== `closest-side` here since the gradient is centred)
     makes the mask's radius exactly match the box's half-width/half-height, so
     its 100% stop lands exactly at the box edge and corners (√2x farther) are
     already past 100%/fully transparent — genuinely zero at every edge instead
     of "mostly opaque, then clipped". The 55-100% fade is additionally a
     smoothstep curve (zero slope at both ends) rather than a linear ramp, so
     there's no secondary kink where the fade begins either. */
  -webkit-mask-image: radial-gradient(ellipse farthest-side at center,
    #000 55%,
    rgba(0, 0, 0, 0.966) 60%,
    rgba(0, 0, 0, 0.874) 65%,
    rgba(0, 0, 0, 0.741) 70%,
    rgba(0, 0, 0, 0.583) 75%,
    rgba(0, 0, 0, 0.417) 80%,
    rgba(0, 0, 0, 0.259) 85%,
    rgba(0, 0, 0, 0.126) 90%,
    rgba(0, 0, 0, 0.034) 95%,
    transparent 100%);
  mask-image: radial-gradient(ellipse farthest-side at center,
    #000 55%,
    rgba(0, 0, 0, 0.966) 60%,
    rgba(0, 0, 0, 0.874) 65%,
    rgba(0, 0, 0, 0.741) 70%,
    rgba(0, 0, 0, 0.583) 75%,
    rgba(0, 0, 0, 0.417) 80%,
    rgba(0, 0, 0, 0.259) 85%,
    rgba(0, 0, 0, 0.126) 90%,
    rgba(0, 0, 0, 0.034) 95%,
    transparent 100%);
}

@media (max-width: 768px) {
  .l2-intro--ornament::before {
    inset: 24px;
    background-position: center, right 90%;
    background-size: auto, 190px;
  }
}

/* Belt-and-braces edge guarantee: the ::before mask above fades the gradient/rings out
   gradually, but an elliptical percentage-sized mask doesn't reach 0 opacity in a
   perfectly predictable number of pixels from a short, wide box's straight edges — so
   a trace of colour can still survive right up to the block's true border, reading as
   a seam against a same-coloured neighbour (worst at the top-right, where the sheen is
   centred). This inset box-shadow paints the block's own base colour back in as a hard
   guarantee, independent of the mask math: the true edge pixel is always pure base
   colour, fading inward over a fixed, predictable pixel distance. */
.l2-intro--ornament::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  box-shadow: inset 0 0 70px 10px var(--color-bg-about);
}

.l2-intro.block--light.l2-intro--ornament::after {
  box-shadow: inset 0 0 70px 10px #ffffff;
}

@media (max-width: 768px) {
  .l2-intro--ornament::after {
    box-shadow: inset 0 0 40px 6px var(--color-bg-about);
  }

  .l2-intro.block--light.l2-intro--ornament::after {
    box-shadow: inset 0 0 40px 6px #ffffff;
  }
}

.l2-intro__content {
  position: relative;
  z-index: 2;
}

.l2-intro__title {
  font-size: clamp(26px, 3.4vw, 38px);
  font-weight: 400;
  /* No max-width: the title must span the full content column, exactly like the
     article body headings (`.article-body__heading`), so its box is as wide as the
     `.container` inner width (1200px − 2×20px = 1160px). A former `max-width: 820px`
     left an unexplained empty band on the right of the title (client report 21.11.2026). */
  margin-bottom: 20px;
  color: var(--color-text);
}

.l2-intro__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
}

/* Gap above the button lives on the button wrapper, so a block without a button doesn't
   carry a trailing 32px on top of its bottom padding. */
.l2-intro__cta-wrap {
  margin-top: 32px;
}

.l2-intro__col p:not(:last-child) {
  margin-bottom: 16px;
}

@media (max-width: 768px) {
  .l2-intro__grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  /* Smaller font so the (uppercase, letter-spaced) button text stays on one
     line instead of wrapping onto a second, which makes the block bulky. */
  .l2-intro__cta-wrap .btn {
    font-size: 14px;
    letter-spacing: 0.02em;
    padding: 16px 20px;
    white-space: nowrap;
  }
}

/* Light colour scheme — background/text/button/ornament colours only, layout unchanged
   (same recipe as `.section--elements.block--light`). */
.l2-intro.block--light {
  background: #ffffff;
}

.l2-intro.block--light .l2-intro__title {
  color: #1a1a1a;
}

.l2-intro.block--light .l2-intro__col {
  color: #555555;
}

/* Same soft CTA as `.section--more-ideas.block--light .btn` (and the «Кнопка» block). */
.l2-intro.block--light .l2-intro__cta-wrap .btn {
  border: 1px solid #e6e6e6;
  color: #4a4a4a;
  background: rgba(0, 0, 0, 0.04);
}

.l2-intro.block--light .l2-intro__cta-wrap .btn:hover {
  background: rgba(154, 123, 63, 0.1);
  border-color: var(--color-accent);
  color: var(--color-accent);
}

/* Same gold ring/sheen ornament, nudged a bit darker/more opaque so it stays visible
   (not washed out) against the white background instead of the dark one. */
.l2-intro.block--light.l2-intro--ornament::before {
  background-image:
    radial-gradient(ellipse 55% 60% at 80% 20%,
      rgba(154, 123, 63, 0.1200) 0%,
      rgba(154, 123, 63, 0.1166) 7%,
      rgba(154, 123, 63, 0.1075) 14%,
      rgba(154, 123, 63, 0.0941) 21%,
      rgba(154, 123, 63, 0.0778) 28%,
      rgba(154, 123, 63, 0.0600) 35%,
      rgba(154, 123, 63, 0.0422) 42%,
      rgba(154, 123, 63, 0.0259) 49%,
      rgba(154, 123, 63, 0.0125) 56%,
      rgba(154, 123, 63, 0.0034) 63%,
      transparent 70%),
    url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 480 480%27%3E%3Cdefs%3E%3ClinearGradient id=%27g%27 x1=%270%25%27 y1=%270%25%27 x2=%27100%25%27 y2=%27100%25%27%3E%3Cstop offset=%270%25%27 stop-color=%27%23c9a768%27/%3E%3Cstop offset=%2750%25%27 stop-color=%27%239a7b3f%27/%3E%3Cstop offset=%27100%25%27 stop-color=%27%236b5329%27/%3E%3C/linearGradient%3E%3C/defs%3E%3Cg fill=%27none%27 stroke=%27url%28%23g%29%27 stroke-width=%271.4%27 stroke-opacity=%270.58%27%3E%3Ccircle cx=%27190%27 cy=%27280%27 r=%27110%27/%3E%3Ccircle cx=%27190%27 cy=%27280%27 r=%2797%27/%3E%3Ccircle cx=%27300%27 cy=%27200%27 r=%27110%27/%3E%3Ccircle cx=%27300%27 cy=%27200%27 r=%2797%27/%3E%3C/g%3E%3C/svg%3E");
}

.element-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

@media (max-width: 992px) {
  .element-cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .element-cards {
    grid-template-columns: 1fr;
  }
}

.element-card {
  padding: 28px 24px;
  border: 1px solid var(--color-border-soft);
  border-radius: var(--radius);
  background: var(--color-surface);
}

.element-card__icon {
  width: 44px;
  height: 44px;
  margin-bottom: 16px;
  /* Lighter refined gold (`#c9a768`, the light stop of the site's own gold
     gradient) instead of `var(--color-accent)` (`#9a7b3f`) — same dark-theme
     icon fix as `.about__img` above, that gold reads too dark on this dark
     card background. Light theme is unaffected (its SVG bakes its own flat
     `#9a7b3f` stroke, ignoring `currentColor`/this `color` entirely). */
  color: #c9a768;
  display: flex;
  align-items: center;
  justify-content: center;
}

.element-card__icon svg {
  width: 32px;
  height: 32px;
  /* Thinner line, same reasoning as `.about__img svg` above. */
  stroke-width: 1.15;
}

/* Card titles are <h3> (H2 block title → H3 per element, same level as the FAQ
   questions) — neutralise what the global `h1,h2,h3,h4` rule / UA h3 defaults set
   so the result is identical to the former plain <div> (body line-height 1.6, normal
   wrapping, no top margin). */
.element-card__title {
  margin: 0 0 8px;
  font-family: inherit;
  font-size: 17px;
  font-weight: 700;
  line-height: inherit;
  text-transform: uppercase;
  overflow-wrap: inherit;
  word-break: inherit;
  color: var(--color-text);
}

.element-card__text {
  font-size: 15px;
  color: var(--color-text-secondary);
}

/* Light colour scheme — only background/text/border colours change, sizing/layout
   stays identical (same pattern as `.section--categories.block--light`'s service-card). */
.section--elements.block--light {
  background: #ffffff;
}

.section--elements.block--light .section-heading {
  color: #1a1a1a;
}

.section--elements.block--light .element-card {
  background: #ffffff;
  border-color: #e6e6e6;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
}

.section--elements.block--light .element-card__title {
  color: #1a1a1a;
}

.section--elements.block--light .element-card__text {
  color: #555555;
}

/* ---- «Блок с ценами» — 3 fixed-colour pricing tiles (graphite/silver/gold), each
   carrying its own --tile-bg/--tile-fg independent of the section theme below — only
   the section background + heading colour change between light/dark. Light keeps the
   original #ebebeb (grey, not pure white) so the coloured tiles stay the focal point;
   dark reuses the standard var(--color-bg-about) + var(--color-text) pair. */
.section--pricing.block--light {
  background: #ebebeb;
}

.section--pricing.block--light .section-heading {
  color: #353535;
}

.section--pricing.block--dark {
  background: var(--color-bg-about);
}

.section--pricing.block--dark .section-heading {
  color: var(--color-text);
}

.section--pricing .section-heading {
  text-align: left;
  font-size: 30px;
  font-weight: 400;
  line-height: 1.2;
  margin-bottom: 20px;
}

@media (max-width: 768px) {
  .section--pricing .section-heading {
    font-size: 24px;
  }
}

.pricing-tiles {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  align-items: stretch;
}

@media (max-width: 992px) {
  .pricing-tiles { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
  .pricing-tiles { grid-template-columns: 1fr; }
}

.pricing-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 44px 32px 22px;
  border-radius: var(--radius);
  background: var(--tile-bg);
  color: var(--tile-fg);
}

/* Hex values sampled 1:1 from the old site (perfectmoments.ru/vertolet, record
   #rec793106214): graphite #414141/white text, silver #dadada/dark text,
   gold #d7cab0/dark text — the same plate→text pairing the old Tilda page used. */
.pricing-tile--graphite { --tile-bg: #414141; --tile-fg: #ffffff; }
.pricing-tile--silver { --tile-bg: #dadada; --tile-fg: #353535; }
.pricing-tile--gold { --tile-bg: #d7cab0; --tile-fg: #353535; }

.pricing-tile__sticker {
  position: absolute;
  top: -14px;
  right: -8px;
  z-index: 2;
  background: linear-gradient(135deg, #c9a768, #9a7b3f 55%, #6b5329);
  color: #ffffff;
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.02em;
  padding: 9px 16px;
  border-radius: 999px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
}

.pricing-tile__title {
  /* The global `h1,h2,h3,h4{color:var(--color-text)}` rule declares its own `color`,
     so plain inheritance from `.pricing-tile--*` doesn't apply unless stated explicitly
     here — without this, titles render white on every tile, unreadable on silver/gold. */
  color: inherit;
  font-size: 22px;
  margin-bottom: 18px;
  padding-right: 56px;
}

.pricing-tile__price-row {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.pricing-tile__price {
  font-size: 30px;
  font-weight: 700;
}

.pricing-tile__price-old {
  font-size: 18px;
  font-weight: 300;
  color: #9f9f9f;
  text-decoration: line-through;
}

.pricing-tile__slogan {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 18px;
}

.pricing-tile__list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 28px;
}

.pricing-tile__list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 15px;
  font-weight: 300;
  line-height: 1.4;
}

.pricing-tile__list li::before {
  content: "";
  flex: none;
  width: 16px;
  height: 16px;
  margin-top: 2px;
  background-color: currentColor;
  -webkit-mask: url('/static/img/bullet.svg') no-repeat center / contain;
  mask: url('/static/img/bullet.svg') no-repeat center / contain;
}

.pricing-tile__btn {
  margin-top: auto;
  display: block;
  width: 100%;
  text-align: center;
  font-family: var(--font-serif);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  font-size: 16px;
  padding: 16px 20px;
  border-radius: var(--radius);
  border: 2px solid var(--tile-fg);
  color: var(--tile-fg);
  background: transparent;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.pricing-tile__btn:hover {
  background: var(--tile-fg);
  color: var(--tile-bg);
}

.l3-gallery {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.l3-gallery__item {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: var(--radius);
  background: linear-gradient(135deg, #3a3a3a, #232323);
}

.l3-gallery__item img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@media (max-width: 900px) {
  .l3-gallery { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 520px) {
  .l3-gallery { grid-template-columns: 1fr 1fr; gap: 12px; }
}

/* ---- FAQ (вопрос-ответ) accordion ---- */
.faq-accordion {
  width: 100%;
}

.faq-item {
  border-top: 1px solid var(--color-border-soft);
}

.faq-item:last-child {
  border-bottom: 1px solid var(--color-border-soft);
}

/* Each question is wrapped in an <h3> (accessible accordion pattern: heading > button)
   — reset everything the global `h1,h2,h3,h4` rule sets so the wrapper adds no visual
   change; the button keeps inheriting body's font/weight/line-height exactly as before
   (`button { font: inherit }`). */
.faq-item__heading {
  margin: 0;
  font: inherit;
  font-weight: inherit;
  line-height: inherit;
  color: inherit;
  text-transform: none;
  overflow-wrap: inherit;
  word-break: inherit;
}

.faq-item__question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  width: 100%;
  padding: 22px 4px;
  background: none;
  border: none;
  text-align: left;
  color: var(--color-text);
  font-family: var(--font-serif);
  transition: color 0.15s ease;
}

.faq-item__question:hover {
  color: var(--color-accent);
}

.faq-item__question-main {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  flex: 1;
  min-width: 0;
}

/* Fixed brand gold, independent of the question's own hover colour (text goes
   to `--color-accent` on hover) — the icon reads as a permanent decorative
   mark, not an interactive control. `currentColor` picks up this `color` for
   the dark-theme SVG (baked by `get_icon_svg()`); the light theme bakes its
   own flat `#9a7b3f` stroke directly into the markup instead (same split as
   `.about__img` / `.about__img svg` above). */
.faq-item__brand-icon {
  flex: none;
  width: 18px;
  height: 18px;
  margin-top: 7px;
  color: #c9a768;
  transition: transform 0.2s ease;
}

.faq-item__brand-icon svg {
  display: block;
  width: 100%;
  height: 100%;
  stroke-width: 1.3;
}

.faq-item__question:hover .faq-item__brand-icon {
  transform: scale(1.12);
}

/* Always render the question in caps regardless of how the admin typed it in
   the panel — a presentation-only transform, the stored title is normal case. */
.faq-item__question-text {
  font-size: 24px;
  line-height: 1.35;
  text-transform: uppercase;
}

.faq-item__icon {
  position: relative;
  flex: none;
  width: 20px;
  height: 20px;
}

.faq-item__icon-svg {
  display: block;
  transition: transform 0.25s ease;
}

.faq-item__question[aria-expanded="true"] .faq-item__icon-svg {
  transform: rotate(180deg);
}

.faq-item__answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.faq-item__answer-inner {
  padding: 0 4px 22px;
  color: var(--color-text-secondary);
  font-size: 16px;
  line-height: 1.55;
}

/* The global `ul, ol { padding: 0; list-style: none; }` reset (top of this file) is
   intentional elsewhere, so the rich-text FAQ answer editor's lists need their own
   scoped opt-back-in or admin-typed bullets/numbers render as plain, unindented text. */
.faq-item__answer-inner ul,
.faq-item__answer-inner ol {
  padding-left: 22px;
  margin: 8px 0;
}

.faq-item__answer-inner ul {
  list-style: disc;
}

.faq-item__answer-inner ol {
  list-style: decimal;
}

.faq-item__answer-inner li {
  margin: 4px 0;
}

.faq-item__answer-inner li:first-child {
  margin-top: 0;
}

.faq-item__answer-inner li:last-child {
  margin-bottom: 0;
}

/* `body`'s font-weight: 300 makes the browser's default `strong/b { font-weight:
   bolder }` resolve to only 400 (the CSS spec's bolder-step from a <400 base) —
   visually indistinguishable from normal text — so bold needs an explicit weight. */
.faq-item__answer-inner strong,
.faq-item__answer-inner b {
  font-weight: 700;
}

/* Light colour scheme — only background/text colours change (see breadcrumbs for the
   source colours), sizing/layout stays identical. */
.section--faq.block--light {
  background: #ffffff;
}

.section--faq.block--light .section-heading {
  color: #1a1a1a;
}

.section--faq.block--light .faq-item {
  border-top-color: rgba(0, 0, 0, 0.12);
}

.section--faq.block--light .faq-item:last-child {
  border-bottom-color: rgba(0, 0, 0, 0.12);
}

.section--faq.block--light .faq-item__question {
  color: #1a1a1a;
}

.section--faq.block--light .faq-item__question:hover {
  color: var(--color-accent);
}

.section--faq.block--light .faq-item__answer-inner {
  color: #555555;
}

/* Grey colour scheme (the divider's #ebebeb surface) — a light surface, so it reuses the
   light ink above; only the background differs, plus the question hover use the AA-safe darker gold
   #7d6230 (4.8:1 on #ebebeb; the regular #9a7b3f accent drops to 3.3:1 there). */
.section--faq.block--grey {
  background: #ebebeb;
}

.section--faq.block--grey .section-heading,
.section--faq.block--grey .faq-item__question {
  color: #1a1a1a;
}

/* 0.15 (not light's 0.12) so the hairlines keep the same visible weight on grey as on white. */
.section--faq.block--grey .faq-item {
  border-top-color: rgba(0, 0, 0, 0.15);
}

.section--faq.block--grey .faq-item:last-child {
  border-bottom-color: rgba(0, 0, 0, 0.15);
}

.section--faq.block--grey .faq-item__question:hover {
  color: #7d6230;
}

.section--faq.block--grey .faq-item__answer-inner {
  color: #555555;
}

@media (max-width: 640px) {
  .faq-item__question {
    padding: 16px 2px;
    gap: 12px;
  }

  .faq-item__question-main {
    gap: 10px;
  }

  .faq-item__brand-icon {
    width: 14px;
    height: 14px;
    margin-top: 3px;
  }

  .faq-item__question-text {
    font-size: 15px;
  }

  .faq-item__answer-inner {
    padding: 0 2px 16px;
    font-size: 14px;
  }
}

/* ==========================================================================
   `article` block — blog post body (title, lead, cover, paragraphs + galleries)
   ========================================================================== */

.article-body__title {
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 16px;
  color: var(--color-text);
}

.article-body__lead {
  font-size: 18px;
  line-height: 1.6;
  color: var(--color-text-secondary);
  margin-bottom: 28px;
}

.article-body__cover {
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 32px;
  aspect-ratio: 16 / 9;
}

.article-body__cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.article-body__paragraph {
  margin-bottom: 32px;
}

.article-body__paragraph:last-child {
  margin-bottom: 0;
}

.article-body__heading {
  font-size: clamp(20px, 2.4vw, 26px);
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 12px;
  color: var(--color-text);
}

.article-body__text {
  font-size: 16px;
  line-height: 1.7;
  color: var(--color-text);
}

/* The global `ul, ol { padding: 0; list-style: none; }` reset (top of this file) is
   intentional elsewhere, so the rich-text paragraph text editor's lists need their own
   scoped opt-back-in or admin-typed bullets/numbers render as plain, unindented text —
   same fix as `.faq-item__answer-inner` (see that rule for the full rationale). */
.article-body__text ul,
.article-body__text ol {
  padding-left: 22px;
  margin: 8px 0;
}

.article-body__text ul {
  list-style: disc;
}

.article-body__text ol {
  list-style: decimal;
}

.article-body__text li {
  margin: 4px 0;
}

.article-body__text li:first-child {
  margin-top: 0;
}

.article-body__text li:last-child {
  margin-bottom: 0;
}

/* `body`'s font-weight: 300 makes the browser's default `strong/b { font-weight: bolder }`
   resolve to only 400 — visually indistinguishable from normal text — same fix as
   `.faq-item__answer-inner strong/b`. */
.article-body__text strong,
.article-body__text b {
  font-weight: 700;
}

/* Paragraph gallery: one-at-a-time main photo (full content width) + prev/next arrows +
   a thumbnail strip — replaces the old flat `.media-grid` photo wall. `.article-gallery__main`
   keeps the `.media-grid`/`.media-grid__item--photo` classes so lightbox.js's existing
   delegated click listener picks it up for free (see static/js/lightbox.js); slides are
   stacked with opacity/visibility (never `display:none`) so lightbox.js's visibility-based
   item count still sees every photo regardless of which slide is active. Slide/thumb
   switching itself is static/js/article-gallery.js. */
.article-gallery {
  margin-top: 16px;
}

.article-gallery__main {
  position: relative;
  display: block;
  aspect-ratio: 3 / 2;
  border-radius: var(--radius);
  overflow: hidden;
  background: linear-gradient(135deg, #3a3a3a, #202020);
}

.article-gallery__slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease;
}

.article-gallery__slide.is-active {
  opacity: 1;
  visibility: visible;
  z-index: 1;
}

.article-gallery__slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.article-gallery__main:focus {
  outline: none;
}

.article-gallery__main:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.article-gallery__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.35);
  color: #fff;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  transition: background 0.2s ease;
}

.article-gallery__arrow:hover {
  background: rgba(0, 0, 0, 0.55);
}

.article-gallery__arrow--prev {
  left: 12px;
}

.article-gallery__arrow--next {
  right: 12px;
}

.article-gallery__strip {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  overflow-x: auto;
  scroll-behavior: smooth;
  padding-bottom: 2px;
}

.article-gallery__thumb {
  flex: 0 0 72px;
  width: 72px;
  aspect-ratio: 3 / 2;
  border-radius: 8px;
  overflow: hidden;
  border: 2px solid transparent;
  padding: 0;
  cursor: pointer;
  opacity: 0.55;
  background: none;
  transition: opacity 0.2s ease, border-color 0.2s ease;
}

.article-gallery__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.article-gallery__thumb:hover {
  opacity: 0.85;
}

.article-gallery__thumb.is-active {
  opacity: 1;
  border-color: var(--color-accent);
}

/* Light colour scheme — only text/background colours change, sizing/layout stays
   identical (same convention as .section--images.block--light etc). */
.section--article.block--light {
  background: #ffffff;
}

/* Grey scheme: light ink on the divider's #ebebeb surface. */
.section--article.block--grey {
  background: #ebebeb;
}

.section--article.block--light .article-body__title,
.section--article.block--light .article-body__heading,
.section--article.block--grey .article-body__title,
.section--article.block--grey .article-body__heading {
  color: #1a1a1a;
}

.section--article.block--light .article-body__lead,
.section--article.block--light .article-body__text,
.section--article.block--grey .article-body__lead,
.section--article.block--grey .article-body__text {
  color: #4a4a4a;
}

@media (max-width: 768px) {
  .article-body__cover {
    margin-bottom: 24px;
  }

  .article-body__paragraph {
    margin-bottom: 24px;
  }

  .article-gallery__arrow {
    width: 36px;
    height: 36px;
    font-size: 16px;
  }

  .article-gallery__arrow--prev {
    left: 8px;
  }

  .article-gallery__arrow--next {
    right: 8px;
  }

  .article-gallery__thumb {
    flex-basis: 56px;
    width: 56px;
  }
}

/* ==========================================================================
   «О нас — основатель» (about_founder) — founder intro: portrait (pulled from
   the team block, see content_tags.founder_photo_url) + caption on the left,
   lead / paragraphs / accent line / СМИ link on the right. Standard section
   rhythm (0 top / 51 bottom, 0/32 mobile) and the 20px heading gap.
   ========================================================================== */
.about-founder,
.wedding-budget {
  padding-top: 0;
}

.about-founder .section-heading,
.wedding-budget .section-heading {
  text-align: left;
  font-size: clamp(25px, 3.45vw, 37px);
  margin-bottom: 20px;
}

.about-founder.block--dark,
.wedding-budget.block--dark {
  background: var(--color-bg-about);
}

.about-founder.block--light,
.wedding-budget.block--light {
  background: #ffffff;
}

.about-founder.block--light .section-heading,
.wedding-budget.block--light .section-heading {
  color: #1a1a1a;
}

.about-founder__grid {
  display: grid;
  grid-template-columns: minmax(0, 380px) minmax(0, 1fr);
  gap: 64px;
  align-items: start;
}

.about-founder__grid--no-photo {
  grid-template-columns: minmax(0, 1fr);
}

.about-founder__grid--no-photo .about-founder__body {
  max-width: 860px;
}

.about-founder__person {
  margin: 0;
  padding: 0 0 0 16px;
}

/* Thin gold frame offset behind the portrait — the site's gold-on-dark stop
   (#c9a768) on dark, the regular accent on light. */
.about-founder__frame {
  position: relative;
}

.about-founder__frame::before {
  content: "";
  position: absolute;
  inset: 16px 16px -16px -16px;
  border: 1px solid #c9a768;
  border-radius: var(--radius);
  pointer-events: none;
}

.about-founder.block--light .about-founder__frame::before {
  border-color: var(--color-accent);
}

.about-founder__photo {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 5;
  height: auto;
  object-fit: cover;
  object-position: center top;
  border-radius: var(--radius);
}

.about-founder__caption {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 36px;
}

.about-founder__name {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-text);
}

.about-founder__role {
  font-size: 14px;
  font-weight: 400;
  line-height: 1.5;
  color: var(--color-text-secondary);
}

.about-founder__caption--inline {
  margin-top: 0;
  padding-left: 18px;
  border-left: 2px solid #c9a768;
}

.about-founder__body {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.about-founder__lead {
  font-size: 22px;
  font-weight: 400;
  line-height: 1.45;
  color: var(--color-text);
}

.about-founder__p {
  font-size: 18px;
  font-weight: 400;
  line-height: 1.6;
  color: var(--color-text-secondary);
}

/* The short motto paragraph — set apart as a gold-ruled pull line. */
.about-founder__accent {
  padding-left: 18px;
  border-left: 2px solid #c9a768;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.5;
  color: #c9a768;
}

.about-founder__smi {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  align-self: flex-start;
  margin-top: 10px;
  padding-top: 18px;
  border-top: 1px solid var(--color-border-soft);
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #c9a768;
}

.about-founder__smi svg {
  width: 22px;
  height: 22px;
  flex: none;
  animation: arrow-sweep 1.8s ease-in-out infinite;
}

.about-founder__smi:hover {
  color: var(--color-text);
}

@media (prefers-reduced-motion: reduce) {
  .about-founder__smi svg { animation: none; }
}

.about-founder.block--light .about-founder__lead,
.about-founder.block--light .about-founder__name {
  color: #1a1a1a;
}

.about-founder.block--light .about-founder__p {
  color: #414141;
}

.about-founder.block--light .about-founder__role {
  color: #6b6b6b;
}

.about-founder.block--light .about-founder__accent,
.about-founder.block--light .about-founder__smi {
  color: var(--color-accent);
}

.about-founder.block--light .about-founder__accent,
.about-founder.block--light .about-founder__caption--inline {
  border-left-color: var(--color-accent);
}

.about-founder.block--light .about-founder__smi {
  border-top-color: #ececec;
}

.about-founder.block--light .about-founder__smi:hover {
  color: #1a1a1a;
}

/* ==========================================================================
   «Бюджет на свадьбу» (wedding_budget) — intro + 3 metric cards. Visual
   language of the «нас выбирают» stats (gold serif figures, uppercase 700
   labels) lifted into cards: a gold rule that draws in on reveal, the prefix
   and unit set apart from the figure, figures counting up (count-up.js).
   ========================================================================== */
.wedding-budget__intro {
  max-width: 900px;
  margin-bottom: 36px;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.6;
  color: var(--color-text-secondary);
}

.wedding-budget.block--light .wedding-budget__intro {
  color: #414141;
}

.wedding-budget__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.budget-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 36px 32px 32px;
  border: 1px solid var(--color-border-soft);
  border-radius: var(--radius);
  background: var(--color-surface);
  overflow: hidden;
}

.budget-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #c9a768, #9a7b3f);
  transform-origin: left center;
  transition: transform 1.2s cubic-bezier(0.22, 0.61, 0.36, 1) 0.3s;
}

html.reveal-ready .budget-card:not(.is-revealed)::before {
  transform: scaleX(0);
}

.budget-card__figure {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  column-gap: 10px;
  color: #c9a768;
}

.budget-card__prefix {
  font-size: 18px;
  font-weight: 400;
  color: var(--color-text-secondary);
}

.budget-card__value {
  font-size: clamp(44px, 5vw, 64px);
  font-weight: 700;
  line-height: 1;
  font-variant-numeric: lining-nums tabular-nums;
}

.budget-card__unit {
  font-size: 22px;
  font-weight: 400;
}

.budget-card__label {
  padding-top: 16px;
  border-top: 1px solid var(--color-border-soft);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.45;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--color-text);
}

.wedding-budget.block--light .budget-card {
  border-color: #ececec;
  background: #faf8f4;
}

.wedding-budget.block--light .budget-card__figure {
  color: var(--color-accent);
}

.wedding-budget.block--light .budget-card__prefix {
  color: #6b6b6b;
}

.wedding-budget.block--light .budget-card__label {
  border-top-color: #e6e0d4;
  color: #1a1a1a;
}

@media (max-width: 960px) {
  .about-founder__grid { grid-template-columns: minmax(0, 300px) minmax(0, 1fr); gap: 44px; }
  .budget-card { padding: 28px 22px 24px; }
}

@media (max-width: 720px) {
  .about-founder,
  .wedding-budget { padding-top: 0; }

  /* Mobile: compact founder "signature" — portrait + caption side by side under
     the heading, then the text. */
  .about-founder__grid { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .about-founder__person {
    display: grid;
    grid-template-columns: 128px minmax(0, 1fr);
    gap: 24px;
    align-items: center;
    padding: 0 0 10px 10px;
  }
  .about-founder__frame::before { inset: 10px 10px -10px -10px; }
  .about-founder__caption { margin-top: 0; }
  .about-founder__name { font-size: 15px; }
  .about-founder__role { font-size: 13px; }
  .about-founder__body { gap: 14px; }
  .about-founder__lead { font-size: 18px; line-height: 1.45; }
  .about-founder__p { font-size: 15px; }
  .about-founder__accent { font-size: 15px; padding-left: 14px; }
  .about-founder__caption--inline { padding-left: 14px; }
  .about-founder__smi { font-size: 13px; }

  .wedding-budget__intro { font-size: 15px; margin-bottom: 24px; }
  .wedding-budget__grid { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .budget-card { gap: 12px; padding: 24px 20px 20px; }
  .budget-card__value { font-size: 44px; }
  .budget-card__unit { font-size: 18px; }
  .budget-card__prefix { font-size: 15px; }
  .budget-card__label { padding-top: 12px; font-size: 13px; }
}

/* Scroll-reveal — standard-block property, applies wherever a block template
   writes the `.reveal` class (see static/js/scroll-reveal.js). .reveal stays
   fully visible by default: no JS / failed JS / old browser never hides
   content. html.reveal-ready is added only after the JS module confirms
   IntersectionObserver support and no reduced-motion preference. */
.reveal {
  opacity: 1;
  transform: none;
}

html.reveal-ready .reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 1.1s cubic-bezier(0.22, 0.61, 0.36, 1), transform 1.1s cubic-bezier(0.22, 0.61, 0.36, 1);
  transition-delay: 0ms;
  will-change: opacity, transform;
}

html.reveal-ready .reveal--fade {
  transform: none;
}

html.reveal-ready .reveal--zoom {
  transform: scale(0.96);
}

html.reveal-ready .reveal.is-revealed {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html.reveal-ready .reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}
