/* KERAFORMA — Дизайн-система «Белая галерея» (#FFFFFF, архитектурный минимализм) */

@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('/fonts/manrope-cyrillic-ext.woff2') format('woff2');
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}

@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('/fonts/manrope-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('/fonts/manrope-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('/fonts/manrope-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  color-scheme: light;

  --font-sans: 'Manrope', system-ui, -apple-system, sans-serif;

  --bg: #ffffff;
  --surface: #ffffff;
  --surface-alt: #f6f6f6;
  --text: #111111;
  --text-muted: #5c5c5c;
  --border: #e5e5e5;
  --border-strong: #111111;
  --cta-bg: #111111;
  --cta-fg: #ffffff;
  --cta-hover: #292929;
  --badge-bg: #f3f3f3;
  --badge-fg: #111111;
  --accent-control: #2f5d8a;
  --error: #b92b27;
  --error-bg: #fdf0ef;
  --success: #1f6f43;
  --radius-lg: 2px;
  --radius-md: 2px;
  --radius-sm: 2px;
}

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

[hidden] {
  display: none !important;
}

html {
  container-type: scroll-state;
  scroll-behavior: smooth;
}

:target {
  scroll-margin-top: 4.5rem;
}

body {
  margin: 0;
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.55;
  accent-color: var(--accent-control);
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-underline-offset: 3px;
}

.visually-hidden:where(:not(:focus-within, :active)) {
  position: absolute !important;
  clip-path: inset(50%) !important;
  overflow: hidden !important;
  width: 1px !important;
  height: 1px !important;
  margin: -1px !important;
  padding: 0 !important;
  border: 0 !important;
  white-space: nowrap !important;
}

.container {
  width: min(1380px, calc(100% - 2.5rem));
  margin-inline: auto;
}

/* Компактная галерейная шапка с автоскрытием при скролле вниз */
.top-bar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  transition: transform 0.24s ease;
}

@container scroll-state((scrolled: bottom) and (scrollable: top)) {
  .top-bar {
    transform: translateY(-100%);
  }
}

.top-bar:focus-within {
  transform: none;
}

.top-bar.is-hidden:not(:focus-within) {
  transform: translateY(-100%);
}

.top-bar__inner {
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: inline-flex;
  align-items: baseline;
  gap: 0.7rem;
  text-decoration: none;
}

.brand__mark {
  font-weight: 700;
  letter-spacing: 0.18em;
  font-size: 0.98rem;
}

.brand__sub {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.top-nav {
  display: flex;
  gap: 1.45rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.top-nav a {
  text-decoration: none;
  transition: color 0.15s ease;
}

.top-nav a:hover {
  color: var(--text);
}

.top-bar__actions {
  display: inline-flex;
  align-items: center;
  gap: 0.9rem;
}

.top-phone {
  font-size: 0.86rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  letter-spacing: -0.01em;
}

.top-phone:hover {
  text-decoration: underline;
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.45rem 0.85rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 0.84rem;
  font-weight: 500;
  cursor: pointer;
  transition: border-color 0.15s ease;
}

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

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #2f9e66;
}

/* ГЛАВНЫЙ ШОУРУМ (БЕЛАЯ ГАЛЕРЕЯ) */
.showroom {
  display: grid;
  grid-template-columns: minmax(0, 1.28fr) minmax(380px, 0.96fr);
  gap: 2.4rem;
  padding-block: 1.6rem 3.5rem;
  align-items: start;
}

.stage-col {
  position: sticky;
  top: 76px;
}

.stage-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  background: #ffffff;
  view-transition-name: lookbook-stage;
}

.stage-frame {
  position: relative;
  aspect-ratio: 4 / 3;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

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

.stage-frame[data-mode="studio"] img,
.stage-frame[data-mode="slab"] img {
  object-fit: contain;
  padding: 1.5rem;
  background: #ffffff;
}

.stage-badge-top {
  position: absolute;
  top: 0.9rem;
  left: 0.9rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.32rem 0.7rem;
  border-radius: var(--radius-sm);
  background: rgba(17, 17, 17, 0.78);
  backdrop-filter: blur(8px);
  color: #ffffff;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.stage-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 38px;
  height: 38px;
  border: 1px solid rgba(17, 17, 17, 0.16);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(6px);
  color: #111111;
  font-size: 1.35rem;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.stage-nav:hover {
  background: #ffffff;
  border-color: #111111;
}

.stage-nav--prev {
  left: 0.85rem;
}

.stage-nav--next {
  right: 0.85rem;
}

.stage-meta-bar {
  border-top: 1px solid var(--border);
  padding: 0.85rem 1.1rem;
  background: #ffffff;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.stage-meta-bar strong {
  display: block;
  font-size: 0.95rem;
  font-weight: 600;
}

.stage-meta-bar span {
  display: block;
  font-size: 0.79rem;
  color: var(--text-muted);
  margin-top: 0.1rem;
}

.stage-meta-bar .stage-dim-pill {
  display: inline-block;
  margin-top: 0;
  padding: 0.28rem 0.65rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-alt);
  color: var(--text);
  font-size: 0.76rem;
  font-weight: 600;
  white-space: nowrap;
}

.stage-toolbar {
  margin-top: 0.7rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.view-tabs {
  display: inline-flex;
  flex-wrap: wrap;
  padding: 2px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--surface);
}

.view-tab {
  border: none;
  background: transparent;
  color: var(--text-muted);
  padding: 0.42rem 0.72rem;
  border-radius: var(--radius-sm);
  font: inherit;
  font-size: 0.8rem;
  cursor: pointer;
  transition: color 0.15s ease, background 0.15s ease;
}

.view-tab:hover {
  color: var(--text);
}

.view-tab.is-active {
  background: var(--cta-bg);
  color: var(--cta-fg);
  font-weight: 600;
}

.share-link-btn {
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-muted);
  padding: 0.44rem 0.82rem;
  border-radius: var(--radius-md);
  font: inherit;
  font-size: 0.81rem;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.share-link-btn:hover {
  color: var(--text);
  border-color: var(--border-strong);
}

/* ПРАВАЯ КОЛОНКА — КОНФИГУРАТОР СТОЛЕШНИЦ */
.eyebrow {
  display: block;
  font-size: 0.73rem;
  text-transform: uppercase;
  letter-spacing: 0.11em;
  color: var(--text-muted);
  font-weight: 600;
}

.config-title {
  margin: 0.35rem 0 0.25rem;
  font-weight: 600;
  font-size: 1.82rem;
  line-height: 1.15;
  letter-spacing: -0.03em;
}

.config-title__kicker {
  display: block;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-muted);
  letter-spacing: 0;
  line-height: 1.35;
  margin-bottom: 0.18rem;
}

.config-title:focus {
  outline: none;
}

.config-subtitle {
  margin: 0 0 0.45rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.stone-seo-note {
  margin: 0 0 0.95rem;
  font-size: 0.84rem;
  line-height: 1.48;
  color: var(--text);
  padding-left: 0.72rem;
  border-left: 2px solid var(--border-strong);
}

.price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
  padding: 0.88rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}

.price-value {
  font-size: 1.62rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  display: block;
  line-height: 1.1;
}

.price-note {
  font-size: 0.79rem;
  color: var(--text-muted);
}

.prepay-badge {
  padding: 0.4rem 0.72rem;
  border-radius: var(--radius-sm);
  background: var(--badge-bg);
  color: var(--badge-fg);
  font-size: 0.83rem;
}

.key-promises {
  list-style: none;
  padding: 0;
  margin: 0.8rem 0 1rem;
  display: grid;
  gap: 0.28rem;
  font-size: 0.84rem;
  color: var(--text-muted);
}

.key-promises li::before {
  content: "— ";
  color: var(--text);
}

/* Плашка фиксированного подстолья */
.frame-spec-strip {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.7rem 0.85rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface-alt);
  margin-bottom: 1rem;
}

.frame-spec-strip img {
  width: 78px;
  height: 62px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: #ffffff;
  flex-shrink: 0;
}

.frame-spec-strip strong {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
}

.frame-spec-strip span {
  display: block;
  font-size: 0.77rem;
  color: var(--text-muted);
  margin-top: 0.1rem;
}

.config-block {
  border-top: 1px solid var(--border);
  padding-block: 1rem 0.9rem;
}

.config-block__head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.5rem;
  margin-bottom: 0.65rem;
}

.step-label {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

.step-current {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Двойные фильтры: оттенок + поверхность */
.stone-filters,
.finish-filters {
  display: flex;
  gap: 0.35rem;
  flex-wrap: wrap;
  margin-bottom: 0.5rem;
}

.finish-filters {
  margin-bottom: 0.8rem;
}

.filter-chip,
.finish-chip {
  padding: 0.3rem 0.65rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-muted);
  font: inherit;
  font-size: 0.77rem;
  cursor: pointer;
  transition: border-color 0.14s ease, color 0.14s ease, background 0.14s ease;
}

.filter-chip:hover,
.finish-chip:hover {
  border-color: var(--border-strong);
  color: var(--text);
}

.filter-chip.is-active,
.finish-chip.is-active {
  background: var(--cta-bg);
  color: var(--cta-fg);
  border-color: var(--cta-bg);
  font-weight: 600;
}

/* Сетка индивидуальных карточек слэбов 160×80 (Матовая и Глянец Люкс раздельно) */
.stones-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.5rem;
  max-height: 410px;
  overflow-y: auto;
  padding-right: 0.2rem;
}

.stone-card {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  padding: 0.38rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  transition: border-color 0.14s ease, background 0.14s ease;
}

.stone-card[hidden] {
  display: none;
}

.stone-card:hover {
  border-color: #888888;
}

.stone-card.is-selected {
  border-color: var(--border-strong);
  box-shadow: inset 0 0 0 1px var(--border-strong);
  background: var(--surface-alt);
}

.stone-card__thumb {
  position: relative;
  display: block;
  aspect-ratio: 2 / 1;
  overflow: hidden;
  border-radius: 5px;
  background: #ffffff;
  margin-bottom: 0.36rem;
}

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

.stone-card__badge {
  position: absolute;
  right: 4px;
  bottom: 4px;
  padding: 1px 5px;
  font-size: 0.63rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  border-radius: 2px;
  background: rgba(17, 17, 17, 0.78);
  color: #ffffff;
}

.stone-card__badge--glossy {
  background: rgba(255, 255, 255, 0.92);
  color: #111111;
  border: 1px solid rgba(17, 17, 17, 0.18);
}

.stone-card__badge--satin {
  background: rgba(65, 58, 48, 0.86);
  color: #ffffff;
}

.stone-card__name {
  font-size: 0.76rem;
  font-weight: 600;
  line-height: 1.2;
}

.stone-card__coll {
  font-size: 0.67rem;
  color: var(--text-muted);
  margin-top: 2px;
  letter-spacing: 0.03em;
}

/* Кнопки заказа */
.cta-stack {
  display: grid;
  gap: 0.6rem;
  padding-top: 0.35rem;
}

.btn-primary {
  width: 100%;
  padding: 0.95rem 1.2rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--cta-bg);
  background: var(--cta-bg);
  color: var(--cta-fg);
  font: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  transition: background-color 0.15s ease;
}

.btn-primary:hover {
  background: var(--cta-hover);
}

.btn-primary small {
  font-weight: 400;
  font-size: 0.75rem;
  opacity: 0.82;
}

.btn-secondary-lead {
  width: 100%;
  padding: 0.75rem 1.05rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-strong);
  background: var(--surface-alt);
  color: var(--text);
  font: inherit;
  font-weight: 600;
  font-size: 0.87rem;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.12rem;
  transition: background-color 0.15s ease;
}

.btn-secondary-lead:hover {
  background: #ececec;
}

.btn-secondary-lead small {
  font-weight: 400;
  font-size: 0.74rem;
  color: var(--text-muted);
}

.cta-secondary-row {
  display: flex;
  gap: 0.55rem;
}

.btn-outline {
  flex: 1;
  padding: 0.68rem 0.95rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 0.84rem;
  font-weight: 500;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: border-color 0.15s ease;
}

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

/* СЕКЦИИ НИЖЕ ПЕРВОГО ЭКРАНА */
.section {
  padding-block: 3.5rem;
  border-top: 1px solid var(--border);
}

.section-head {
  max-width: 720px;
  margin-bottom: 2rem;
}

.section-head h2 {
  margin: 0.35rem 0 0;
  font-weight: 600;
  font-size: 1.72rem;
  letter-spacing: -0.028em;
  line-height: 1.16;
}

.section-lead {
  margin: 0.55rem 0 0;
  font-size: 0.94rem;
  color: var(--text-muted);
}

/* Макро-узлы литого алюминиевого подстолья */
.macro-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.1rem;
}

.macro-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.macro-card__img {
  position: relative;
  aspect-ratio: 1 / 1;
  background: var(--surface-alt);
  border-bottom: 1px solid var(--border);
  overflow: hidden;
}

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

.macro-card__num {
  position: absolute;
  top: 0.7rem;
  left: 0.7rem;
  padding: 0.2rem 0.5rem;
  font-size: 0.72rem;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}

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

.macro-card__body h3 {
  margin: 0 0 0.45rem;
  font-size: 0.98rem;
  font-weight: 600;
}

.macro-card__body p {
  margin: 0;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.1rem;
}

.feature-card,
.step-card {
  padding: 1.35rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

.feature-num,
.step-card__num {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 0.22rem 0.55rem;
  border-radius: var(--radius-sm);
  background: var(--badge-bg);
  color: var(--badge-fg);
  margin-bottom: 0.75rem;
}

.feature-card h3,
.step-card h3 {
  margin: 0 0 0.5rem;
  font-size: 1rem;
}

.feature-card p,
.step-card p {
  margin: 0;
  font-size: 0.87rem;
  color: var(--text-muted);
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.1rem;
}

/* FAQ details */
.faq-list {
  max-width: 860px;
  display: grid;
  gap: 0.6rem;
}

.faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface);
  padding: 1rem 1.2rem;
}

.faq-item summary {
  font-weight: 600;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  font-size: 1.2rem;
  color: var(--text-muted);
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-item p {
  margin: 0.75rem 0 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Таблица характеристик и блок комплектации */
.specs-layout {
  display: grid;
  grid-template-columns: 1.3fr 0.95fr;
  gap: 1.5rem;
  align-items: start;
}

.specs-dl {
  margin: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
}

.specs-dl__row {
  display: grid;
  grid-template-columns: minmax(190px, 0.85fr) 1.25fr;
  gap: 1rem;
  padding: 0.82rem 1.15rem;
  border-bottom: 1px solid var(--border);
  font-size: 0.87rem;
}

.specs-dl__row:last-child {
  border-bottom: none;
}

.specs-dl__row dt {
  color: var(--text-muted);
  font-weight: 500;
}

.specs-dl__row dd {
  margin: 0;
  font-weight: 500;
  color: var(--text);
}

.specs-aside {
  padding: 1.4rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface-alt);
}

.specs-aside h3 {
  margin: 0.35rem 0 0.8rem;
  font-size: 1.08rem;
  line-height: 1.28;
}

.specs-checklist {
  margin: 0 0 1.15rem;
  padding-left: 1.1rem;
  display: grid;
  gap: 0.55rem;
  font-size: 0.86rem;
  color: var(--text-muted);
}

.specs-checklist strong {
  color: var(--text);
}

/* Финальный конверсионный блок */
.bottom-cta-box {
  display: grid;
  grid-template-columns: 1.35fr minmax(280px, 0.85fr);
  gap: 1.8rem;
  align-items: center;
  padding: 2rem 2.2rem;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  background: var(--surface-alt);
}

.bottom-cta-box h2 {
  margin: 0.3rem 0 0.5rem;
  font-size: 1.45rem;
  line-height: 1.2;
  letter-spacing: -0.025em;
}

.bottom-cta-box p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.bottom-cta-box__actions {
  display: grid;
  gap: 0.6rem;
}

/* Подвал */
.site-footer {
  border-top: 1px solid var(--border);
  padding-block: 2.2rem;
  margin-top: 2rem;
}

.site-footer__inner {
  display: flex;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.footer-muted {
  margin: 0.3rem 0 0;
  font-size: 0.82rem;
  color: var(--text-muted);
  max-width: 560px;
}

.footer-contacts {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.25rem;
}

.footer-phone {
  font-size: 1.02rem;
  font-weight: 700;
  text-decoration: none;
}

.footer-links {
  margin-top: 0.45rem;
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.83rem;
}

/* Липкая нижняя панель заказа на смартфонах */
.mobile-sticky-bar {
  display: none;
}

/* ДИАЛОГИ И ВЫДВИЖНАЯ ПАНЕЛЬ (prevent-page-scroll-under-modal-dialog) */
dialog:modal {
  overscroll-behavior: contain;
}

dialog::backdrop {
  overflow: hidden;
  overscroll-behavior: contain;
  background: rgba(17, 17, 17, 0.48);
  backdrop-filter: blur(3px);
}

.modal-dialog {
  width: min(520px, calc(100% - 1.5rem));
  max-height: calc(100dvh - 2rem);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  background: var(--surface);
  color: var(--text);
  padding: 1.5rem;
}

.drawer-dialog {
  margin: 0 0 0 auto;
  width: min(440px, 100%);
  height: 100dvh;
  max-height: 100dvh;
  border: none;
  border-left: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  padding: 1.25rem;
}

.drawer-dialog[open] {
  display: flex;
  flex-direction: column;
}

.modal-dialog__head,
.drawer-dialog__head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1rem;
}

.modal-dialog__head h2,
.drawer-dialog__head h2 {
  margin: 0.2rem 0 0;
  font-size: 1.22rem;
}

.icon-close {
  width: 34px;
  height: 34px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  cursor: pointer;
}

.icon-close:hover {
  border-color: var(--border-strong);
}

.order-summary-card {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.72rem;
  border-radius: var(--radius-md);
  background: var(--surface-alt);
  border: 1px solid var(--border);
  margin-bottom: 1rem;
}

.order-summary-card__img {
  width: 92px;
  height: 46px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: #ffffff;
  flex-shrink: 0;
}

.order-summary-card__info strong {
  display: block;
  font-size: 0.92rem;
}

.order-summary-card__info span {
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* Форма и отложенная валидация (:user-invalid) */
.order-form {
  display: grid;
  gap: 0.85rem;
}

.field label,
.field-label {
  display: block;
  font-size: 0.84rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.hint {
  display: block;
  font-size: 0.76rem;
  color: var(--text-muted);
  margin-bottom: 0.3rem;
}

.field input[type="text"],
.field input[type="tel"],
.admin-fields input,
.admin-fields select,
.chat-input-bar input {
  width: 100%;
  padding: 0.68rem 0.8rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font: inherit;
}

.error-msg {
  display: none;
  color: var(--error);
  font-size: 0.78rem;
  margin-top: 0.28rem;
}

:is(:user-invalid, .user-invalid-fallback) {
  border-color: var(--error);
  background-color: var(--error-bg);
}

input:is(:user-invalid, .user-invalid-fallback) + .error-msg,
.checkbox-row:has(input:is(:user-invalid, .user-invalid-fallback)) + .error-msg {
  display: block;
}

input:is(:user-valid, .user-valid-fallback) {
  border-color: var(--success);
}

.channel-radios {
  display: flex;
  gap: 0.9rem;
  flex-wrap: wrap;
  font-size: 0.85rem;
}

.channel-radios label,
.checkbox-row {
  display: inline-flex;
  align-items: flex-start;
  gap: 0.5rem;
  cursor: pointer;
  font-size: 0.85rem;
}

.checkbox-row--legal {
  font-size: 0.78rem;
  color: var(--text-muted);
}

@supports not (accent-color: var(--accent-control)) {
  .checkbox-row input[type="checkbox"] {
    position: absolute !important;
    clip-path: inset(50%) !important;
    overflow: hidden !important;
    width: 1px !important;
    height: 1px !important;
    margin: -1px !important;
    padding: 0 !important;
    border: 0 !important;
    white-space: nowrap !important;
  }

  .checkbox-row {
    position: relative;
    padding-left: 1.65rem;
  }

  .checkbox-row input[type="checkbox"] + span::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.15rem;
    width: 1.1rem;
    height: 1.1rem;
    border: 2px solid #999999;
    background: #ffffff;
    border-radius: 2px;
    box-sizing: border-box;
  }

  .checkbox-row input[type="checkbox"]:focus-visible + span::before {
    outline: 2px solid #111111;
    outline-offset: 2px;
  }

  .checkbox-row input[type="checkbox"]:checked + span::before {
    background-color: var(--accent-control, #2f5d8a);
    border-color: var(--accent-control, #2f5d8a);
  }

  .checkbox-row input[type="checkbox"]:checked + span::after {
    content: "✓";
    position: absolute;
    left: 0.2rem;
    top: 0.05rem;
    color: #ffffff;
    font-weight: 700;
    font-size: 0.82rem;
  }
}

.payment-breakdown {
  padding: 0.85rem;
  border-radius: var(--radius-md);
  background: var(--surface-alt);
  border: 1px solid var(--border);
  display: grid;
  gap: 0.35rem;
  font-size: 0.85rem;
}

.payment-breakdown__line {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
}

.payment-breakdown__line--muted {
  color: var(--text-muted);
}

.payment-breakdown__line--total {
  border-top: 1px solid var(--border);
  padding-top: 0.4rem;
  margin-top: 0.15rem;
}

.order-success {
  padding: 1rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--success);
  background: var(--bg);
}

/* Чат ИИ-консультанта */
.chat-context-pill {
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-sm);
  background: var(--badge-bg);
  color: var(--badge-fg);
  font-size: 0.8rem;
  margin-bottom: 0.75rem;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  padding-right: 0.25rem;
}

.chat-bubble {
  padding: 0.75rem 0.9rem;
  border-radius: var(--radius-md);
  font-size: 0.87rem;
  max-width: 90%;
}

.chat-bubble--bot {
  background: var(--surface-alt);
  border: 1px solid var(--border);
  align-self: flex-start;
}

.chat-bubble--user {
  background: var(--cta-bg);
  color: var(--cta-fg);
  align-self: flex-end;
}

.chat-quick-chips {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
  margin-block: 0.65rem;
}

.quick-ask {
  padding: 0.32rem 0.62rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text-muted);
  font: inherit;
  font-size: 0.76rem;
  cursor: pointer;
}

.quick-ask:hover {
  color: var(--text);
  border-color: var(--border-strong);
}

.chat-input-bar {
  display: flex;
  gap: 0.45rem;
}

.btn-send {
  padding: 0 1rem;
  border-radius: var(--radius-sm);
  border: none;
  background: var(--cta-bg);
  color: var(--cta-fg);
  font: inherit;
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
}

.chat-legal-note {
  margin: 0.45rem 0 0;
  font-size: 0.72rem;
  line-height: 1.35;
  color: var(--text-muted);
}

/* Уведомление об использовании cookie и Яндекс.Метрики (152-ФЗ) */
.cookie-banner {
  position: fixed;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  z-index: 19;
  max-width: 720px;
  margin-inline: auto;
  padding: 0.72rem 0.95rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.9rem;
  background: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  box-shadow: 0 8px 24px rgba(17, 17, 17, 0.08);
  font-size: 0.78rem;
  line-height: 1.4;
  color: var(--text-muted);
}

.cookie-banner p {
  margin: 0;
}

.cookie-banner a {
  color: var(--text);
}

.cookie-banner__btn {
  flex-shrink: 0;
  padding: 0.44rem 0.88rem;
  border: 1px solid var(--cta-bg);
  border-radius: var(--radius-sm);
  background: var(--cta-bg);
  color: var(--cta-fg);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
}

.cookie-banner__btn:hover {
  background: var(--cta-hover);
}

/* Юр. страницы и Админ-дашборд */
.legal-page {
  max-width: 820px;
  padding-block: 2.5rem 4rem;
}

.legal-lead {
  color: var(--text-muted);
}

.admin-wrap {
  padding-block: 2rem 4rem;
}

.admin-notice {
  padding: 0.85rem 1rem;
  border: 1px solid var(--success);
  border-radius: var(--radius-md);
  margin-bottom: 1.2rem;
}

.admin-grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 1.25rem;
}

.admin-card {
  padding: 1.4rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface);
}

.admin-card h2 {
  margin-top: 0;
  font-size: 1.15rem;
}

.admin-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
  font-size: 0.83rem;
}

.admin-span-2 {
  grid-column: span 2;
}

.stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.65rem;
}

.stat-box {
  padding: 0.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-alt);
}

.stat-box span {
  display: block;
  font-size: 0.75rem;
  color: var(--text-muted);
}

.stat-box strong {
  font-size: 1.15rem;
}

.admin-chats {
  max-height: 250px;
  overflow-y: auto;
  display: grid;
  gap: 0.5rem;
  font-size: 0.82rem;
}

.admin-chat-item {
  padding: 0.5rem 0.65rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}

.table-scroll {
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

.admin-table th,
.admin-table td {
  text-align: left;
  padding: 0.7rem;
  border-bottom: 1px solid var(--border);
}

.supplier-pill {
  margin-top: 0.28rem;
  display: inline-block;
  padding: 0.22rem 0.55rem;
  background: #f4f6f9;
  border: 1px solid #d4dde6;
  color: #1d3b58;
  font-size: 0.77rem;
  font-weight: 600;
  border-radius: 2px;
}

.utm-pill {
  margin-top: 0.28rem;
  display: inline-block;
  padding: 0.18rem 0.48rem;
  background: #f8f5ec;
  border: 1px solid #e5d8b5;
  color: #5d4813;
  font-size: 0.74rem;
  border-radius: 2px;
}

.admin-seo-box {
  margin-top: 0.95rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-alt);
  font-size: 0.8rem;
}

.admin-seo-box ul {
  margin: 0.45rem 0 0;
  padding-left: 1.1rem;
  display: grid;
  gap: 0.3rem;
  color: var(--text-muted);
}

.pub-badge {
  display: inline-block;
  padding: 0.16rem 0.45rem;
  font-size: 0.72rem;
  border-radius: 2px;
  background: var(--surface-alt);
  color: var(--text-muted);
  border: 1px solid var(--border);
}

.pub-badge--on {
  background: #eef7f1;
  color: #1c6b3d;
  border-color: #bdddc8;
  font-weight: 600;
}

@media (prefers-reduced-motion: reduce) {
  ::view-transition-group(*),
  ::view-transition-old(*),
  ::view-transition-new(*) {
    animation: none !important;
  }
}

@media (max-width: 1080px) {
  .showroom {
    grid-template-columns: 1fr;
  }
  .stage-col {
    position: static;
  }
  .macro-grid,
  .features-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .steps-grid,
  .specs-layout,
  .bottom-cta-box,
  .admin-grid {
    grid-template-columns: 1fr;
  }
  .footer-contacts {
    align-items: flex-start;
  }
}

@media (max-width: 768px) {
  body {
    padding-bottom: 4.5rem;
  }
  .top-nav {
    display: none;
  }
  .mobile-sticky-bar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 18;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.6rem 1rem calc(0.6rem + env(safe-area-inset-bottom, 0px));
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(12px);
    border-top: 1px solid var(--border-strong);
    transform: translateY(105%);
    transition: transform 0.22s ease;
  }
  .mobile-sticky-bar.is-visible {
    transform: translateY(0);
  }
  .mobile-sticky-bar__meta {
    min-width: 0;
  }
  .mobile-sticky-bar__meta strong {
    display: block;
    font-size: 0.82rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .mobile-sticky-bar__meta span {
    display: block;
    font-size: 0.74rem;
    color: var(--text-muted);
  }
  .mobile-sticky-bar__btns {
    display: inline-flex;
    gap: 0.4rem;
    flex-shrink: 0;
  }
  .btn-sticky-video,
  .btn-sticky-order {
    padding: 0.55rem 0.8rem;
    border-radius: var(--radius-sm);
    font: inherit;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
  }
  .btn-sticky-video {
    border: 1px solid var(--border-strong);
    background: var(--surface);
    color: var(--text);
  }
  .btn-sticky-order {
    border: 1px solid var(--cta-bg);
    background: var(--cta-bg);
    color: var(--cta-fg);
  }
  .cookie-banner {
    left: 0.65rem;
    right: 0.65rem;
    bottom: calc(4.35rem + env(safe-area-inset-bottom, 0px));
    padding: 0.62rem 0.78rem;
    font-size: 0.74rem;
  }
}

@media (max-width: 640px) {
  .brand__sub {
    display: none;
  }
  .top-phone {
    font-size: 0.78rem;
  }
  .stones-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-height: 360px;
  }
  .specs-dl__row {
    grid-template-columns: 1fr;
    gap: 0.2rem;
  }
  .bottom-cta-box {
    padding: 1.35rem;
  }
  .macro-grid,
  .features-grid,
  .admin-fields {
    grid-template-columns: 1fr;
  }
  .admin-span-2 {
    grid-column: span 1;
  }
  .cta-secondary-row {
    flex-direction: column;
  }
}
