/* ALIVA — ногтевая студия */
:root {
  --bg: #f8f4f0;
  --bg-card: #fffcfa;
  --ink: #1a1614;
  --muted: #5c5651;
  --line: #e8e1d9;
  --accent: #c17a85;
  --accent-dark: #a35d6a;
  --accent-soft: #f5e8eb;
  --gold: #c4a86a;
  --champagne: #e8d5c4;
  --radius: 16px;
  --radius-lg: 24px;
  --shadow: 0 22px 56px rgba(26, 22, 20, 0.09);
  --shadow-sm: 0 10px 30px rgba(26, 22, 20, 0.06);
  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-body: "Mulish", system-ui, sans-serif;
  --max: 1140px;
  --ease-out-expo: cubic-bezier(0.19, 1, 0.22, 1);
  --ease-soft: cubic-bezier(0.33, 1, 0.68, 1);
  --parallax-x: 0px;
  --parallax-y: 0px;
  --scroll-y: 0px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
}

body.is-loading {
  overflow: hidden;
}

/* Cookie не поверх прелоадера */
body.is-loading .cookie-banner {
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* Полноэкранный прелоадер (только системные шрифты — без скачка при подгрузке Google Fonts) */
.page-loader {
  position: fixed;
  inset: 0;
  z-index: 10050;
  display: grid;
  place-items: center;
  padding: 1.5rem;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background:
    radial-gradient(ellipse 80% 55% at 50% 35%, rgba(245, 232, 236, 0.65), transparent 55%),
    linear-gradient(180deg, #faf6f3 0%, #f4ede8 45%, #faf6f3 100%);
  transition:
    opacity 0.32s var(--ease-soft),
    visibility 0.32s var(--ease-soft);
}

.page-loader--leave {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.page-loader__inner {
  text-align: center;
  max-width: 22rem;
}

.page-loader__brand {
  position: relative;
  display: grid;
  place-items: center;
  width: min(168px, 44vw);
  height: min(168px, 44vw);
  margin: 0 auto 1.15rem;
}

.page-loader__svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.page-loader__arc {
  /* stroke-dashoffset задаётся скриптом от прогресса загрузки страницы */
  will-change: stroke-dashoffset;
}

.page-loader__logo {
  position: relative;
  z-index: 1;
  margin: 0;
  font-family: ui-serif, "Palatino Linotype", Palatino, "Book Antiqua", Georgia, "Times New Roman", serif;
  font-synthesis: none;
  font-size: clamp(1.35rem, 4.2vw, 1.85rem);
  font-weight: 700;
  letter-spacing: 0.24em;
  text-indent: 0.24em;
  color: var(--ink);
}

.page-loader__tagline {
  margin: 0;
  font-family: inherit;
  font-size: clamp(0.92rem, 2.6vw, 1.05rem);
  font-weight: 500;
  color: var(--muted);
  letter-spacing: 0.04em;
}

@media (prefers-reduced-motion: reduce) {
  .page-loader__arc {
    will-change: auto;
  }

  .page-loader {
    transition-duration: 0.2s;
  }
}

/* Лёгкая «плёнка» и зерно — editorial beauty-эстетика */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(ellipse 100% 80% at 50% -20%, rgba(245, 232, 236, 0.55), transparent 50%),
    radial-gradient(ellipse 60% 50% at 100% 50%, rgba(232, 213, 196, 0.2), transparent 45%);
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9998;
  opacity: 0.045;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

main,
.header,
.footer {
  position: relative;
  z-index: 1;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--accent-dark);
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}

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

.container {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

/* Header */
.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(252, 248, 244, 0.72);
  backdrop-filter: saturate(160%) blur(16px);
  -webkit-backdrop-filter: saturate(160%) blur(16px);
  border-bottom: 1px solid rgba(232, 225, 217, 0.65);
  transition:
    background 0.45s var(--ease-soft),
    box-shadow 0.45s var(--ease-soft),
    border-color 0.45s var(--ease-soft);
}

.header.is-scrolled {
  background: rgba(255, 252, 249, 0.88);
  box-shadow: 0 12px 40px rgba(26, 22, 20, 0.06);
  border-bottom-color: transparent;
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-width: 0;
  padding: 0.72rem 0;
  transition: padding 0.4s var(--ease-soft);
}

.header.is-scrolled .header__inner {
  padding: 0.5rem 0;
}

.logo {
  font-family: var(--font-display);
  font-size: 1.58rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  color: var(--ink);
  text-decoration: none;
}

.logo--muted {
  color: var(--muted);
}

.logo:hover {
  color: var(--accent-dark);
}

.nav {
  display: flex;
  gap: clamp(1rem, 3vw, 2rem);
}

.nav a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.92rem;
  position: relative;
}

.nav a:not(.btn)::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, var(--accent), var(--gold));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease-out-expo);
}

.nav a:not(.btn):hover {
  color: var(--ink);
}

.nav a:not(.btn):hover::after {
  transform: scaleX(1);
}

.nav a[aria-current="page"] {
  color: var(--ink);
}

.nav a[aria-current="page"]::after {
  transform: scaleX(1);
}

.burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
}

.burger span {
  display: block;
  height: 2px;
  background: var(--ink);
  border-radius: 1px;
  transition: transform 0.2s, opacity 0.2s;
}

/* Buttons */
.btn {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.9rem;
  padding: 0.72rem 1.35rem;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  transition:
    transform 0.35s var(--ease-soft),
    box-shadow 0.35s var(--ease-soft),
    background 0.25s ease,
    border-color 0.25s ease;
  will-change: transform;
}

.btn--magnetic {
  transition:
    transform 0.45s var(--ease-soft),
    box-shadow 0.35s var(--ease-soft),
    background 0.25s ease;
}

a.btn {
  box-sizing: border-box;
}

.btn:active {
  transform: scale(0.98);
}

.btn--primary {
  background: var(--ink);
  color: var(--bg);
}

.btn--primary:hover {
  background: #292524;
  color: var(--bg);
}

.btn--accent {
  background: linear-gradient(135deg, #d18996 0%, var(--accent-dark) 50%, #8f4a58 100%);
  background-size: 200% 200%;
  color: #fff;
  box-shadow: 0 12px 32px rgba(163, 93, 106, 0.35);
  position: relative;
  overflow: hidden;
}

.btn--accent::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    110deg,
    transparent 30%,
    rgba(255, 255, 255, 0.22) 45%,
    transparent 55%
  );
  transform: translateX(-120%);
  transition: transform 0.7s var(--ease-out-expo);
}

.btn--accent:hover {
  box-shadow: 0 14px 40px rgba(163, 93, 106, 0.42);
  color: #fff;
  background-position: 100% 50%;
}

.btn--accent:hover::before {
  transform: translateX(120%);
}

.btn--ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line);
}

.btn--ghost:hover {
  border-color: var(--accent);
  color: var(--accent-dark);
}

.btn--lg {
  padding: 0.92rem 1.85rem;
  font-size: 0.95rem;
}

/* Hero */
.hero {
  /* Ширина контента совпадает с горизонтальными полями «окна» */
  --hero-window-inline: 7.5%;
  --hero-window-min-h: min(400px, 52vh);
  /* Лёгкий подъём «окна» на десктопе (раньше давало смещение положение ::after + parallax) */
  --hero-window-lift: clamp(0.75rem, 2.2vh, 2rem);
  --hero-cta-gap: 1rem;
  position: relative;
  min-height: min(88vh, 780px);
  display: flex;
  align-items: center;
  padding: 5rem 0 4rem;
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 120% 80% at 80% -10%, rgba(213, 150, 160, 0.2), transparent 55%),
    radial-gradient(ellipse 70% 50% at 10% 100%, rgba(212, 189, 160, 0.18), transparent 50%),
    linear-gradient(180deg, #faf6f3 0%, #f4ede6 42%, #faf6f3 100%);
  z-index: 0;
  transform: translate3d(var(--parallax-x), calc(var(--parallax-y) * 0.35 + var(--scroll-y)), 0);
  will-change: transform;
}

.hero-fluid {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  pointer-events: auto;
  z-index: 0;
  opacity: 1;
}

.hero-fluid-touch {
  display: none;
}

/* Сенсор: скролл по центру; жидкость — только с боковых полос (не над текстом и кнопками) */
@media (hover: none) and (pointer: coarse) {
  .hero-fluid {
    pointer-events: none;
    touch-action: pan-y;
  }

  .hero-fluid-touch {
    display: block;
    position: absolute;
    top: 0;
    bottom: 0;
    z-index: 2;
    pointer-events: auto;
    touch-action: none;
  }

  .hero-fluid-touch--left {
    left: 0;
    width: min(28vw, 7rem);
  }

  .hero-fluid-touch--right {
    right: 0;
    width: min(28vw, 7rem);
  }
}

.hero__mesh {
  position: absolute;
  inset: -12% -8%;
  pointer-events: none;
  overflow: visible;
  z-index: 1;
  transform: translate3d(calc(var(--parallax-x) * 1.2), calc(var(--parallax-y) * 1.1), 0);
}

.hero__blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(72px);
  opacity: 0.5;
  mix-blend-mode: multiply;
  animation: blob-drift 22s ease-in-out infinite;
}

.hero__blob--a {
  width: min(480px, 55vw);
  height: min(480px, 55vw);
  top: 5%;
  right: -5%;
  background: radial-gradient(circle at 30% 30%, rgba(255, 220, 230, 0.9), rgba(193, 122, 133, 0.35) 60%, transparent 70%);
  animation-delay: 0s;
}

.hero__blob--b {
  width: min(420px, 50vw);
  height: min(420px, 50vw);
  bottom: 0;
  left: -8%;
  background: radial-gradient(circle at 60% 40%, rgba(255, 244, 230, 0.95), rgba(196, 168, 106, 0.25) 55%, transparent 70%);
  animation-delay: -7s;
  animation-duration: 26s;
}

.hero__blob--c {
  width: min(320px, 40vw);
  height: min(320px, 40vw);
  top: 40%;
  left: 35%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.85), rgba(232, 213, 196, 0.2) 50%, transparent 65%);
  opacity: 0.35;
  filter: blur(56px);
  animation-delay: -12s;
  animation-duration: 19s;
}

@keyframes blob-drift {
  0%,
  100% {
    transform: scale(1) translate(0, 0);
  }
  33% {
    transform: scale(1.05) translate(3%, -2%);
  }
  66% {
    transform: scale(0.96) translate(-2%, 3%);
  }
}

.hero__content {
  position: relative;
  z-index: 10;
  isolation: isolate;
  text-align: center;
  /* Мобильная: карточка = ширина колонки с кнопками (как сейчас) */
  width: min(560px, calc(100% - 2 * var(--hero-window-inline)));
  max-width: min(560px, calc(100% - 2 * var(--hero-window-inline)));
  min-width: 0;
  margin-inline: auto;
  padding-inline: clamp(0.875rem, 3.2vw, 1.35rem);
  padding-top: clamp(1rem, 3.2vw, 1.35rem);
  /* Ровно как gap между кнопками CTA — внутри белой карточки (::before) */
  padding-bottom: var(--hero-cta-gap);
  box-sizing: border-box;
  transform: translate3d(calc(var(--parallax-x) * 0.08), calc(var(--parallax-y) * 0.08), 0);
  transition: transform 0.12s linear;
  pointer-events: none;
}

/* Десктоп: широкая карточка как у старого .hero__bg::after; колонка текста/кнопок по-прежнему ~560px */
@media (min-width: 721px) {
  .hero__content {
    width: calc(100% - 2 * var(--hero-window-inline));
    max-width: none;
    min-height: var(--hero-window-min-h);
    padding-inline: clamp(1.25rem, 6vw, 3rem);
    padding-top: clamp(1.25rem, 4vw, 2rem);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transform: translate3d(
      calc(var(--parallax-x) * 0.08),
      calc(var(--parallax-y) * 0.08 - var(--hero-window-lift)),
      0
    );
  }

  .hero__content > * {
    max-width: 560px;
    width: min(100%, 560px);
    margin-inline: auto;
    box-sizing: border-box;
  }
}

.hero__content::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(238, 230, 222, 0.95);
  background:
    repeating-linear-gradient(
      -8deg,
      transparent,
      transparent 12px,
      rgba(231, 226, 220, 0.35) 12px,
      rgba(231, 226, 220, 0.35) 13px
    ),
    linear-gradient(145deg, #fffefb 0%, #f7f1eb 100%);
  box-shadow: var(--shadow);
  pointer-events: none;
}

.hero__content a,
.hero__content button {
  pointer-events: auto;
}

.hero__eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.35em;
  font-size: 0.72rem;
  color: var(--accent-dark);
  font-weight: 600;
  margin: 0 0 0.85rem;
  /* Компенсация «хвоста» letter-spacing — визуально ровнее по центру */
  padding-inline: 0.35em;
  box-sizing: border-box;
}

.hero__title {
  font-family: var(--font-display);
  font-size: clamp(3rem, 10vw, 5.5rem);
  font-weight: 700;
  line-height: 1.05;
  margin: 0 0 1rem;
  letter-spacing: 0.12em;
  padding-inline: 0.12em;
  box-sizing: border-box;
}

.hero__title--gradient .hero__title-inner {
  display: inline-block;
  background: linear-gradient(
    118deg,
    var(--ink) 0%,
    var(--ink) 32%,
    var(--accent-dark) 52%,
    #c49a72 72%,
    var(--accent) 92%,
    var(--ink) 120%
  );
  background-size: 220% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: title-shimmer 8s ease-in-out infinite;
}

@keyframes title-shimmer {
  0%,
  100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

.hero__subtitle {
  font-size: 1.1rem;
  color: var(--muted);
  margin: 0 0 2.25rem;
  font-weight: 400;
}

.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--hero-cta-gap);
  justify-content: center;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

.hero__cta .btn {
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
}

.hero__scroll {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  width: 24px;
  height: 40px;
  border: 2px solid var(--line);
  border-radius: 12px;
  z-index: 11;
}

.hero__scroll::before {
  content: "";
  position: absolute;
  top: 8px;
  left: 50%;
  transform: translateX(-50%);
  width: 4px;
  height: 8px;
  background: var(--accent);
  border-radius: 2px;
  animation: scroll-hint 1.8s ease-in-out infinite;
}

@keyframes scroll-hint {
  0%,
  100% {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
  50% {
    opacity: 0.35;
    transform: translateX(-50%) translateY(10px);
  }
}

/* Появление героя: только при включённом JS (см. <html class="js">) */
html.js body:not(.page-ready) .hero__appear {
  opacity: 0;
  transform: translateY(36px);
  filter: blur(10px);
}

html.js body.page-ready .hero__appear {
  animation: hero-pop 1.05s var(--ease-out-expo) forwards;
}

.hero__appear[data-hero-delay="1"] {
  animation-delay: 0.08s;
}
.hero__appear[data-hero-delay="2"] {
  animation-delay: 0.2s;
}
.hero__appear[data-hero-delay="3"] {
  animation-delay: 0.34s;
}
.hero__appear[data-hero-delay="4"] {
  animation-delay: 0.48s;
}

@keyframes hero-pop {
  to {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
  }
}

/* Скролл-раскрытие блоков */
.anim-reveal {
  opacity: 0;
  transform: translate3d(0, 40px, 0) scale(0.98);
  filter: blur(8px);
  transition:
    opacity 0.85s var(--ease-out-expo),
    transform 0.85s var(--ease-out-expo),
    filter 0.85s var(--ease-out-expo);
  transition-delay: 0s;
}

.anim-reveal.is-visible {
  opacity: 1;
  transform: translate3d(0, 0, 0) scale(1);
  filter: blur(0);
}

.anim-reveal--delay-sm {
  transition-delay: 0.1s;
}

.anim-reveal--delay-md {
  transition-delay: 0.18s;
}

.anim-reveal--delay-lg {
  transition-delay: 0.26s;
}

.anim-reveal--stagger {
  transition-delay: calc(0.08s * var(--stagger, 0));
}

.anim-reveal--scale.is-visible {
  transform: translate3d(0, 0, 0) scale(1);
}

.anim-reveal--scale {
  transform: translate3d(0, 32px, 0) scale(0.94);
}

/* Sections */
.section {
  padding: clamp(4rem, 8vw, 6.5rem) 0;
}

.section__head {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 3rem;
}

.section__head--left {
  text-align: left;
  margin-left: 0;
}

.section__label {
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.28em;
  color: var(--gold);
  font-weight: 700;
  margin-bottom: 0.65rem;
}

.section__title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4.5vw, 2.85rem);
  font-weight: 600;
  line-height: 1.18;
  margin: 0 0 1rem;
}

.section__title--brush {
  display: flex;
  justify-content: center;
  width: 100%;
  margin-bottom: 1.15rem;
  text-align: center;
}

.section__title-brush-wrap {
  position: relative;
  display: inline-block;
  padding-bottom: 0.38em;
  padding-inline: 0.15em 1.75em;
  text-align: center;
}

.section__title-brush-row {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0.04em;
  width: 100%;
  height: 1.25em;
  min-height: 22px;
  max-height: 32px;
  pointer-events: none;
}

.section__title-brush-track {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
}

.section__title-brush-clip {
  position: absolute;
  left: 0;
  bottom: 0.14em;
  width: 0;
  height: 0.46em;
  min-height: 12px;
  max-height: 18px;
  overflow: hidden;
}

.section__title-brush {
  display: block;
  width: 0;
  height: 100%;
  overflow: visible;
  filter: drop-shadow(0 1px 2px rgba(193, 122, 133, 0.16));
}

.section__title-brush-tool {
  position: absolute;
  left: 0;
  bottom: 0.06em;
  width: 2em;
  height: 1.22em;
  min-width: 30px;
  min-height: 20px;
  max-width: 44px;
  max-height: 28px;
  overflow: visible;
  filter: drop-shadow(0 1px 1px rgba(26, 22, 20, 0.12));
}

.section__title-brush-row.is-animating .section__title-brush-clip,
.section__title-brush-row.is-animating .section__title-brush-tool {
  will-change: width, left;
}

.section__desc {
  margin: 0;
  color: var(--muted);
}

.about {
  background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.6));
}

.about .section__head {
  text-align: center;
  max-width: 720px;
}

.about__grid {
  display: grid;
  gap: clamp(2rem, 4vw, 3rem);
  grid-template-columns: 1fr 1fr;
  align-items: start;
}

.about__text .lead {
  font-size: 1.2rem;
  color: var(--ink);
}

.about__text p {
  color: var(--muted);
}

.about__list {
  margin: 1.5rem 0 0;
  padding-left: 1.1rem;
  color: var(--muted);
}

.about__list li {
  margin-bottom: 0.55rem;
}

.about__card {
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.92), rgba(252, 247, 244, 0.98));
  padding: 2rem 2rem 2.25rem;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(232, 225, 217, 0.85);
  box-shadow:
    var(--shadow-sm),
    inset 0 1px 0 rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(8px);
  transition: transform 0.45s var(--ease-soft), box-shadow 0.45s var(--ease-soft);
}

.about__card.is-visible:hover {
  box-shadow: var(--shadow);
}

.about__card blockquote {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-style: italic;
  font-weight: 500;
  line-height: 1.45;
  color: var(--ink);
}

.about__card cite {
  display: block;
  margin-top: 1.25rem;
  font-style: normal;
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  color: var(--accent-dark);
  text-transform: uppercase;
}

/* Services */
.services {
  background:
    radial-gradient(ellipse 60% 40% at 100% 0%, rgba(183, 110, 121, 0.08), transparent),
    var(--bg);
}

.services__panels {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1rem, 2.5vw, 1.5rem);
  align-items: stretch;
}

.service-panel {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
  background: linear-gradient(180deg, #fffcfa 0%, #faf5f1 100%);
  border-radius: calc(var(--radius) + 2px);
  padding: clamp(0.85rem, 2vw, 1.15rem) clamp(0.85rem, 1.75vw, 1.1rem) clamp(0.85rem, 1.75vw, 1rem);
  border: 1px solid rgba(232, 225, 217, 0.9);
}

.service-panel__carousel-wrap {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.service-panel__hint {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent);
  white-space: nowrap;
}

.service-panel__hint--solo {
  text-transform: none;
  letter-spacing: 0;
  font-weight: 500;
  color: var(--muted);
}

.service-panel__hint-icon {
  display: inline-block;
  margin-right: 0.2rem;
  font-size: 0.9em;
  letter-spacing: 0.12em;
  animation: service-hint-nudge 2.4s ease-in-out infinite;
}

@keyframes service-hint-nudge {
  0%,
  100% {
    transform: translateX(0);
  }
  50% {
    transform: translateX(3px);
  }
}

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

.service-panel__edge {
  position: absolute;
  top: 0;
  bottom: 0;
  width: clamp(1.5rem, 4vw, 2rem);
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.service-panel__edge--left {
  left: 0;
  background: linear-gradient(to right, rgba(255, 252, 250, 0.98) 35%, transparent);
}

.service-panel__edge--right {
  right: 0;
  background: linear-gradient(to left, rgba(255, 252, 250, 0.98) 35%, transparent);
}

.service-panel.is-at-start .service-panel__edge--left {
  opacity: 0;
}

.service-panel.is-at-end .service-panel__edge--right {
  opacity: 0;
}

.service-panel__chev {
  font-size: 1.35rem;
  line-height: 1;
  color: rgba(193, 122, 133, 0.55);
  font-weight: 600;
}

.service-panel__viewport {
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scroll-padding-inline: 0;
  overscroll-behavior-x: contain;
  overscroll-behavior-y: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  cursor: grab;
  touch-action: pan-x pan-y;
  padding-block: 0.08rem 0.2rem;
  width: 100%;
  max-width: 100%;
  flex: 1 1 auto;
  min-height: 0;
}

.service-panel__viewport::-webkit-scrollbar {
  display: none;
}

.service-panel__viewport.is-dragging {
  cursor: grabbing;
  scroll-snap-type: none;
  scroll-behavior: auto;
  user-select: none;
}

.service-panel__track {
  display: flex;
  align-items: stretch;
  gap: clamp(0.85rem, 2.5vw, 1.25rem);
  width: max-content;
  height: 100%;
  padding-inline: 0;
}

.service-panel__slide {
  flex: 0 0 auto;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  display: flex;
  align-items: stretch;
  align-self: stretch;
  box-sizing: border-box;
  min-width: 0;
  height: 100%;
}

.service-panel__slide-inner {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  min-height: 0;
  padding: 0;
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(232, 225, 217, 0.95);
  border-radius: calc(var(--radius) - 2px);
  transition:
    border-color 0.3s ease,
    box-shadow 0.35s var(--ease-soft);
}

.service-panel__slide.is-active .service-panel__slide-inner {
  border-color: rgba(193, 122, 133, 0.35);
  box-shadow: 0 14px 36px rgba(26, 22, 20, 0.07);
}

.service-panel__media {
  position: relative;
  flex: 0 0 auto;
  aspect-ratio: 6 / 7;
  overflow: hidden;
  background: linear-gradient(145deg, #f7f1eb, #efe5dc);
}

.service-panel__photo {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  transform: scale(1.01);
  transition: transform 0.55s var(--ease-soft);
}

.service-panel__slide.is-active .service-panel__photo {
  transform: scale(1.03);
}

.service-panel__body {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  gap: 0.4rem;
  padding: 0.75rem 0.85rem 0.85rem;
}

.service-panel--solo .service-panel__slide-inner {
  flex: 1 1 auto;
  height: 100%;
}

.service-panel--solo .service-panel__viewport {
  overflow: hidden;
  cursor: default;
  flex: 0 1 auto;
  display: block;
}

.service-panel--solo .service-panel__track {
  width: 100%;
  flex: 0 1 auto;
  display: flex;
}

.service-panel--solo .service-panel__slide {
  width: 100%;
  flex: 0 1 auto;
  display: flex;
}

.service-panel--solo .service-panel__edge {
  display: none;
}

.service-panel__name {
  margin: 0;
  min-height: 2.2em;
  font-family: var(--font-display);
  font-size: clamp(1.05rem, 2vw, 1.2rem);
  font-weight: 600;
  line-height: 1.25;
  color: var(--ink);
}

.service-panel__desc {
  margin: 0;
  flex: 1 1 auto;
  min-height: 2.7em;
  font-size: 0.82rem;
  line-height: 1.5;
  color: var(--muted);
}

.service-panel__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.35rem 0.75rem;
  margin-top: auto;
  padding-top: 0.15rem;
}

.service-panel__price {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.2;
}

.service-panel__duration {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent-dark);
  background: rgba(245, 232, 236, 0.75);
  padding: 0.28rem 0.55rem;
  border-radius: 999px;
}

.service-panel__book {
  width: 100%;
  margin-top: 0.25rem;
  padding: 0.6rem 1rem;
  font-size: 0.85rem;
}

@media (prefers-reduced-motion: reduce) {
  .service-panel__photo {
    transform: none;
    transition: none;
  }

  .service-panel__slide.is-active .service-panel__photo {
    transform: none;
  }
}

.service-panel__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-shrink: 0;
  margin-top: auto;
  padding-top: 0.5rem;
  border-top: 1px solid rgba(232, 225, 217, 0.85);
}

.service-panel__label,
.service-panel__counter {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.service-panel__nav {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.service-panel__footer--solo {
  justify-content: flex-start;
}

.service-panel__dots {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.service-panel__dot {
  width: 0.42rem;
  height: 0.42rem;
  border-radius: 999px;
  background: rgba(193, 122, 133, 0.22);
  transition:
    transform 0.25s ease,
    background 0.25s ease,
    width 0.25s ease;
}

.service-panel__dot.is-active {
  width: 1.15rem;
  background: var(--accent);
}

.services__fallback {
  grid-column: 1 / -1;
  margin: 0;
  text-align: center;
  color: var(--muted);
}

.service-card {
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #fffcfa 0%, #faf5f1 100%);
  border-radius: var(--radius);
  padding: 1.75rem 1.45rem;
  border: 1px solid rgba(232, 225, 217, 0.9);
  transition:
    transform 0.45s var(--ease-soft),
    box-shadow 0.45s var(--ease-soft),
    border-color 0.35s ease;
  position: relative;
  overflow: hidden;
}

.service-card__category {
  display: inline-block;
  margin-bottom: 0.65rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

.service-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent-soft), var(--gold), var(--accent));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.5s var(--ease-out-expo);
}

.service-card.is-visible:hover,
.service-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
  border-color: rgba(193, 122, 133, 0.25);
}

.service-card.is-visible:hover::before,
.service-card:hover::before {
  transform: scaleX(1);
}

/* До появления в зоне видимости карточка не реагирует на hover-трансформ */
.service-card:not(.is-visible):hover {
  transform: none;
  box-shadow: none;
  border-color: rgba(232, 225, 217, 0.9);
}

.service-card:not(.is-visible):hover::before {
  transform: scaleX(0);
}

.service-card__num {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent-soft);
  margin-bottom: 0.65rem;
  line-height: 1;
}

.service-card h3 {
  margin: 0 0 0.65rem;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
}

.service-card p,
.service-card__desc {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.65;
  color: var(--muted);
}

.service-card__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.55rem 1rem;
  margin-top: 1rem;
}

.service-card__price {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--ink);
}

.service-card__duration {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--muted);
}

.service-card__book {
  width: 100%;
  margin-top: auto;
  padding-top: 1.1rem;
}

.services__cta {
  text-align: center;
  margin-top: 2.5rem;
}

/* Reviews */
.reviews {
  background: var(--ink);
  color: #f5f5f4;
}

.reviews .section__label {
  color: var(--gold);
}

.reviews .section__title {
  color: #fafaf9;
}

.reviews__carousel {
  position: relative;
  width: 100vw;
  max-width: 100vw;
  left: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  padding-block: 0.35rem;
}

.reviews__carousel::before,
.reviews__carousel::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: clamp(1.25rem, 9vw, 5rem);
  z-index: 2;
  pointer-events: none;
}

.reviews__carousel::before {
  left: 0;
  background: linear-gradient(to right, var(--ink) 12%, transparent);
}

.reviews__carousel::after {
  right: 0;
  background: linear-gradient(to left, var(--ink) 12%, transparent);
}

.reviews__viewport {
  overflow-x: auto;
  overflow-y: visible;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  overscroll-behavior-x: contain;
  overscroll-behavior-y: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  cursor: grab;
  touch-action: manipulation;
  padding-block: 0.65rem;
}

.reviews__viewport::-webkit-scrollbar {
  display: none;
}

.reviews__viewport.is-dragging {
  cursor: grabbing;
  scroll-snap-type: none;
  scroll-behavior: auto;
  user-select: none;
}

.reviews__track {
  display: flex;
  align-items: stretch;
  gap: clamp(0.85rem, 2.4vw, 1.2rem);
  width: max-content;
  padding-inline: max(1rem, calc((100vw - clamp(280px, 78vw, 520px)) / 2));
}

.reviews__carousel .review-card {
  flex: 0 0 clamp(280px, 78vw, 520px);
  scroll-snap-align: center;
  scroll-snap-stop: always;
  transform-origin: center center;
  will-change: transform, opacity;
  transition:
    border-color 0.45s var(--ease-soft),
    box-shadow 0.45s var(--ease-soft);
}

.reviews__carousel .review-card.is-active {
  border-color: rgba(196, 168, 106, 0.32);
  box-shadow: 0 22px 48px rgba(0, 0, 0, 0.22);
}

.reviews__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  margin: 1.35rem auto 0;
  max-width: 42rem;
}

.reviews__btn-ghost {
  color: #f5f5f4;
  border-color: rgba(255, 255, 255, 0.22);
}

.reviews__btn-ghost:hover {
  color: var(--gold);
  border-color: rgba(196, 168, 106, 0.55);
}

.reviews__source {
  margin: 1rem auto 0;
  max-width: 42rem;
  text-align: center;
  font-size: 0.82rem;
  color: #78716c;
}

.review-card {
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03));
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  padding: 1.5rem 1.35rem;
}

.review-card__stars {
  color: var(--gold);
  letter-spacing: 0.15em;
  font-size: 0.85rem;
  margin-bottom: 0.85rem;
}

.review-card p {
  margin: 0 0 1rem;
  font-size: 0.98rem;
  line-height: 1.7;
  color: #d6d3d1;
}

.review-card footer {
  font-size: 0.85rem;
  font-weight: 600;
  color: #a8a29e;
}

/* Contacts & map — карта по «Адрес», по высоте до низа кнопки «Запись онлайн» */
.contacts__layout {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  grid-template-areas:
    "intro ."
    "info map";
  column-gap: clamp(2rem, 4vw, 3.5rem);
  row-gap: clamp(1.25rem, 2.5vw, 2rem);
  align-items: stretch;
}

.contacts__intro {
  grid-area: intro;
  align-self: start;
}

.contacts__intro.section__head {
  margin: 0;
  max-width: none;
}

.contacts__info {
  grid-area: info;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.contacts__dl {
  margin: 0 0 1.5rem;
}

.contacts__info > .btn {
  flex-shrink: 0;
  align-self: flex-start;
}

.contacts__dl > div {
  margin-bottom: 1.25rem;
}

.contacts__dl dt {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--muted);
  margin-bottom: 0.35rem;
}

.contacts__dl dd {
  margin: 0;
  font-weight: 500;
}

.contacts__dl a {
  color: var(--ink);
  font-weight: 700;
}

/* Яндекс map-widget — на десктопе тянется по высоте колонки с кнопкой */
.map-wrap.map-wrap--yandex {
  grid-area: map;
  align-self: stretch;
  width: 100%;
  min-width: 0;
  height: 100%;
  min-height: 0;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border-radius: 16px;
  background: #e8e6e1;
  border: 1px solid rgba(232, 225, 217, 0.9);
  box-shadow: 0 16px 40px rgba(26, 22, 20, 0.1);
  box-sizing: border-box;
}

.map-wrap__viewport {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.map-wrap__iframe {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  border: 0;
}

/* Footer */
.footer {
  border-top: 1px solid var(--line);
  padding: 2.75rem 0;
  text-align: center;
}

.footer__inner p {
  margin: 0.35rem 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.footer__copy {
  font-size: 0.82rem !important;
  margin-top: 1.25rem !important;
}

.footer__legal {
  margin: 0.5rem 0 0 !important;
  font-size: 0.88rem !important;
}

.footer__legal a {
  color: var(--muted);
  font-weight: 500;
}

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

/* Юридические страницы */
.page-legal {
  padding-bottom: 2rem;
}

.header--simple .header__inner {
  justify-content: space-between;
}

.nav--simple {
  gap: 1rem;
}

.legal-main {
  padding-top: 1.5rem;
  padding-bottom: 3rem;
}

.legal-article {
  max-width: 42rem;
  margin: 0 auto;
}

.legal-article__title {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 600;
  line-height: 1.2;
  margin: 0 0 0.75rem;
  color: var(--ink);
}

.legal-article__meta {
  font-size: 0.85rem;
  color: var(--muted);
  margin: 0 0 2rem;
}

.legal-section {
  margin-bottom: 2rem;
}

.legal-section h2 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
  margin: 0 0 0.85rem;
  color: var(--ink);
}

.legal-section p,
.legal-section li {
  color: var(--muted);
  font-size: 0.98rem;
}

.legal-section ul {
  margin: 0.75rem 0;
  padding-left: 1.2rem;
}

.legal-section li {
  margin-bottom: 0.45rem;
}

/* Страница примеров работ */
.page-works {
  padding-bottom: 0;
}

.works-hero {
  padding: clamp(4.5rem, 10vw, 6.5rem) 0 clamp(2.5rem, 5vw, 3.5rem);
  background:
    radial-gradient(ellipse 90% 70% at 50% -10%, rgba(245, 232, 236, 0.75), transparent 55%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.55), transparent);
}

.works-hero__inner {
  max-width: 40rem;
  margin: 0 auto;
  text-align: center;
}

.works-hero__label {
  margin: 0 0 0.85rem;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.28em;
  color: var(--gold);
  font-weight: 700;
}

.works-hero__title {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-size: clamp(2.35rem, 6vw, 3.5rem);
  font-weight: 600;
  line-height: 1.12;
  color: var(--ink);
}

.works-hero__lead {
  margin: 0;
  font-size: clamp(1.02rem, 2.2vw, 1.12rem);
  color: var(--muted);
}

.works-gallery {
  padding-top: 0;
}

.works-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1rem, 2.5vw, 1.5rem);
}

.work-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(232, 225, 217, 0.9);
  background: var(--bg-card);
  box-shadow: var(--shadow-sm);
  transition: transform 0.45s var(--ease-soft), box-shadow 0.45s var(--ease-soft);
}

.work-card.is-visible:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.work-card__open {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: zoom-in;
  overflow: hidden;
}

.work-card__image {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  transition: transform 0.55s var(--ease-soft);
}

.work-card.is-visible:hover .work-card__image {
  transform: scale(1.03);
}

.work-card__body {
  padding: 1.1rem 1.15rem 1.25rem;
}

.work-card__tag {
  display: inline-block;
  margin-bottom: 0.55rem;
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-dark);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.work-card__title {
  margin: 0 0 0.45rem;
  font-family: var(--font-display);
  font-size: 1.28rem;
  font-weight: 600;
  line-height: 1.25;
  color: var(--ink);
}

.work-card__desc {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--muted);
}

.works-gallery__cta {
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
  padding: clamp(1.75rem, 4vw, 2.25rem);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(193, 122, 133, 0.22);
  background:
    linear-gradient(135deg, rgba(245, 232, 236, 0.55), rgba(255, 252, 249, 0.95)),
    var(--bg-card);
  text-align: center;
  box-shadow: var(--shadow-sm);
}

.works-gallery__cta p {
  margin: 0 auto 1.15rem;
  max-width: 34rem;
  color: var(--muted);
}

.work-lightbox {
  width: min(100% - 2rem, 52rem);
  max-height: calc(100vh - 2rem);
  padding: 0;
  border: 0;
  border-radius: var(--radius-lg);
  background: transparent;
  overflow: visible;
}

.work-lightbox::backdrop {
  background: rgba(26, 22, 20, 0.72);
  backdrop-filter: blur(6px);
}

.work-lightbox__inner {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--bg-card);
  box-shadow: var(--shadow);
}

.work-lightbox__close {
  position: absolute;
  top: 0.65rem;
  right: 0.65rem;
  z-index: 2;
  width: 2.25rem;
  height: 2.25rem;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 252, 249, 0.92);
  color: var(--ink);
  font-size: 1.45rem;
  line-height: 1;
  cursor: pointer;
}

.work-lightbox__image {
  display: block;
  width: 100%;
  max-height: min(72vh, 720px);
  object-fit: contain;
  background: #f3ebe3;
}

.work-lightbox__caption {
  padding: 1rem 1.25rem 1.25rem;
}

.work-lightbox__tag {
  display: inline-block;
  margin-bottom: 0.45rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-dark);
}

.work-lightbox__title {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--ink);
}

.work-lightbox__desc {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--muted);
}

/* YCLIENTS: круглая кнопка записи — видна только после первого экрана (класс aliva-ycl-fab-visible в script.js) */
body:not(.aliva-ycl-fab-visible) .yButton,
body:not(.aliva-ycl-fab-visible) [data-superbutton] {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

/* Баннер cookie */
.cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10060;
  padding: 1rem 0 calc(1rem + env(safe-area-inset-bottom, 0));
  background: rgba(252, 248, 244, 0.97);
  border-top: 1px solid var(--line);
  box-shadow: 0 -8px 32px rgba(26, 22, 20, 0.08);
  backdrop-filter: blur(10px);
}

body.cookie-consent-done .cookie-banner {
  display: none !important;
}

.cookie-banner__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.cookie-banner__text {
  margin: 0;
  flex: 1 1 16rem;
  font-size: 0.88rem;
  line-height: 1.55;
  color: var(--muted);
}

.cookie-banner__text a {
  font-weight: 600;
}

.cookie-banner__actions {
  flex-shrink: 0;
}

/* Страница 404 */
.page-404 {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.error-404 {
  position: relative;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(2.5rem, 8vw, 5rem) 0;
  overflow: hidden;
}

.error-404__bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 80% 60% at 70% 20%, rgba(213, 150, 160, 0.22), transparent 55%),
    radial-gradient(ellipse 50% 45% at 15% 80%, rgba(196, 168, 106, 0.14), transparent 50%),
    linear-gradient(180deg, var(--bg) 0%, #f4ede8 50%, var(--bg) 100%);
}

.error-404__orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(64px);
  opacity: 0.45;
}

.error-404__orb--a {
  width: min(340px, 70vw);
  height: min(340px, 70vw);
  top: -5%;
  right: -10%;
  background: radial-gradient(circle, rgba(255, 210, 220, 0.9), rgba(193, 122, 133, 0.25) 60%, transparent 70%);
}

.error-404__orb--b {
  width: min(280px, 55vw);
  height: min(280px, 55vw);
  bottom: 5%;
  left: -8%;
  background: radial-gradient(circle, rgba(255, 244, 230, 0.95), rgba(196, 168, 106, 0.2) 55%, transparent 70%);
}

.error-404__inner {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 36rem;
  margin-inline: auto;
}

.error-404__eyebrow {
  margin: 0 0 0.5rem;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.32em;
  font-weight: 700;
  color: var(--accent-dark);
}

.error-404__code {
  margin: 0 0 0.75rem;
  font-family: var(--font-display);
  font-size: clamp(5.5rem, 22vw, 10rem);
  font-weight: 700;
  line-height: 0.95;
  letter-spacing: 0.06em;
  background: linear-gradient(
    118deg,
    var(--ink) 0%,
    var(--accent-dark) 38%,
    #c49a72 58%,
    var(--accent) 78%,
    var(--ink) 100%
  );
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: error-404-shimmer 10s ease-in-out infinite;
}

@keyframes error-404-shimmer {
  0%,
  100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

.error-404__title {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 600;
  color: var(--ink);
}

.error-404__text {
  margin: 0 0 2rem;
  font-size: 1.05rem;
  line-height: 1.65;
  color: var(--muted);
}

.error-404__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
  min-width: 0;
  max-width: 100%;
}

.error-404__actions .btn {
  min-width: 0;
}

.footer--compact {
  padding: 1.75rem 0;
}

.footer--compact .footer__inner {
  text-align: center;
}

.footer--compact .footer__copy {
  margin-top: 0.75rem !important;
}

@media (prefers-reduced-motion: reduce) {
  .error-404__code {
    animation: none;
    background: linear-gradient(118deg, var(--ink), var(--accent-dark));
    background-size: 100%;
  }
}

@media (min-width: 721px) and (max-width: 1080px) {
  .works-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Mobile */
@media (max-width: 960px) {
  .services__panels {
    grid-template-columns: 1fr;
    gap: 1.1rem;
  }

  .service-panel {
    min-width: 0;
    overflow: hidden;
    height: auto;
    padding: 0.75rem 0.8rem 0.75rem;
  }

  .service-panel__carousel-wrap {
    min-width: 0;
    overflow: hidden;
    flex: 0 1 auto;
  }

  .service-panel__viewport {
    margin-inline: 0;
    touch-action: pan-x pan-y;
    flex: 0 1 auto;
  }

  .service-panel__media {
    aspect-ratio: 1 / 1;
    max-height: clamp(210px, 36vh, 300px);
    width: 100%;
  }

  .service-panel__photo {
    max-height: clamp(210px, 36vh, 300px);
  }

  .service-panel__track {
    gap: 0.75rem;
    align-items: stretch;
    height: auto;
  }

  .service-panel__slide,
  .service-panel__slide-inner {
    height: auto;
  }

  .service-panel__hint {
    font-size: 0.76rem;
  }

  .service-panel__body {
    padding: 0.65rem 0.75rem 0.75rem;
    gap: 0.35rem;
  }

  .service-panel__name {
    min-height: 0;
    font-size: 1.05rem;
  }

  .service-panel__desc {
    min-height: 0;
    font-size: 0.8rem;
    line-height: 1.45;
  }

  .service-panel__footer {
    padding-top: 0.45rem;
  }

  .services .section__head {
    margin-bottom: 1.5rem;
  }

  .about__grid {
    grid-template-columns: 1fr;
  }

  .works-grid {
    grid-template-columns: 1fr;
  }

  .contacts__layout {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "intro"
      "info"
      "map";
    column-gap: 0;
    row-gap: clamp(1.25rem, 4vw, 1.75rem);
    align-items: stretch;
  }

  .contacts__info > .btn {
    align-self: stretch;
    width: 100%;
    justify-content: center;
  }

  .map-wrap.map-wrap--yandex {
    width: 100%;
    height: auto;
    min-height: clamp(280px, 72vw, 380px);
    aspect-ratio: 560 / 400;
    max-height: none;
    align-self: stretch;
  }
}

@media (max-width: 720px) {
  .nav {
    position: fixed;
    inset: 58px 0 auto 0;
    background: rgba(250, 247, 244, 0.98);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    align-items: center;
    padding: 1rem;
    gap: 0.75rem;
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.28s ease, opacity 0.28s ease;
  }

  .nav.is-open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  /* навигационные текстовые ссылки не должны наследовать стиль кнопки у соседей */
  .nav a:not(.btn) {
    padding: 0.35rem 0;
  }

  .burger {
    display: flex;
    flex-shrink: 0;
  }

  .burger.is-active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }

  .burger.is-active span:nth-child(2) {
    opacity: 0;
  }

  .burger.is-active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }

  .header__inner {
    justify-content: flex-start;
    gap: 0.35rem;
  }

  .header__book {
    flex-shrink: 1;
    min-width: 0;
    margin-left: auto;
    margin-right: 0;
    padding-inline: 0.75rem;
    font-size: 0.82rem;
  }

  .hero__cta {
    flex-direction: column;
    align-items: stretch;
  }

  .hero__cta .btn {
    width: 100%;
  }
}

@media (max-width: 520px) {
  .hero {
    padding-top: 4rem;
  }
}

/* Уважение к системной настройке «уменьшить движение» */
@media (prefers-reduced-motion: reduce) {
  .hero-fluid {
    display: none !important;
  }

  .hero-fluid-touch {
    display: none !important;
    pointer-events: none !important;
  }

  body::after {
    display: none;
  }

  .hero__blob {
    animation: none !important;
  }

  .hero__title--gradient .hero__title-inner {
    animation: none !important;
    background: linear-gradient(118deg, var(--ink), var(--accent-dark));
    background-size: 100%;
  }

  html.js body.page-ready .hero__appear,
  html.js body:not(.page-ready) .hero__appear {
    animation: none !important;
    opacity: 1;
    transform: none;
    filter: none;
  }

  .anim-reveal {
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
    transition: none !important;
  }

  .hero__bg,
  .hero__content,
  .hero__mesh {
    transform: none !important;
    transition: none !important;
  }

  .btn--accent::before {
    display: none;
  }

  .section__title-brush-row {
    animation: none !important;
  }

  .section__title-brush-row .section__title-brush-clip,
  .section__title-brush-row .section__title-brush-tool {
    will-change: auto;
  }

  .btn--magnetic {
    transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease;
  }

  .reviews__carousel .review-card {
    transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
  }
}
