/* ============================================================
   КАПРИН — настоящее стекло в кнопках (glass-2, 22.10.2026)
   Материал: полупрозрачная заливка (альфа 0.35–0.62) + размытие фона,
   светлая грань сверху, тёмная — снизу, блик по верхней половине.
   Файл подключается последним, поэтому перекрывает decor.css и инлайн-стили.
   ============================================================ */

/* ---------- общий материал ---------- */
.btn,
.hdr-tool,
.view-btn,
.promo-band-btn,
button.kp-quick-btn {
  position: relative;
  isolation: isolate;
  -webkit-backdrop-filter: blur(16px) saturate(170%);
  backdrop-filter: blur(16px) saturate(170%);
  border-width: 1px;
  border-style: solid;
  background-clip: padding-box;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .55),
    inset 0 -1px 0 rgba(0, 0, 0, .10),
    0 8px 22px rgba(15, 23, 42, .14);
  transition: background-color .2s ease, border-color .2s ease, box-shadow .2s ease,
              transform .18s ease, filter .2s ease;
}

/* блик: верхняя половина светлее — именно он читается как стекло */
.btn::before,
.hdr-tool::before,
.view-btn::before,
.promo-band-btn::before,
button.kp-quick-btn::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .40) 0%, rgba(255, 255, 255, .12) 36%, rgba(255, 255, 255, 0) 54%),
    radial-gradient(150% 100% at 16% -20%, rgba(255, 255, 255, .34), rgba(255, 255, 255, 0) 60%);
}

/* ---------- чёрное стекло: «В корзину», основные действия ---------- */
.btn-primary,
.btn-dark,
button.btn[data-cart-add] {
  background-color: rgba(18, 18, 22, .58) !important;
  background-image: linear-gradient(155deg, rgba(70, 70, 78, .52), rgba(12, 12, 15, .72) 60%) !important;
  color: #fff !important;
  border-color: rgba(255, 255, 255, .26) !important;
  text-shadow: 0 1px 1px rgba(0, 0, 0, .32);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .34),
    inset 0 -1px 0 rgba(0, 0, 0, .22),
    0 10px 26px rgba(10, 14, 20, .24) !important;
}

/* ---------- голубое стекло: акценты, поиск, «Получить цену» ---------- */
.btn-copper,
.btn-orange,
.hero .btn-orange,
.hero-search .btn-copper,
.seo-landing-hero .hero-cta .btn-orange,
.search-box button {
  background-color: rgba(73, 144, 208, .52) !important;
  background-image: linear-gradient(155deg, rgba(173, 220, 252, .52), rgba(61, 139, 201, .62) 62%) !important;
  color: #fff !important;
  border-color: rgba(255, 255, 255, .46) !important;
  text-shadow: 0 1px 2px rgba(9, 37, 64, .32);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .66),
    inset 0 -1px 0 rgba(9, 37, 64, .18),
    0 10px 26px rgba(61, 139, 201, .24) !important;
}

/* ---------- молочное стекло на светлом фоне ---------- */
.btn-white {
  background-color: rgba(255, 255, 255, .38) !important;
  background-image: linear-gradient(155deg, rgba(255, 255, 255, .82), rgba(255, 255, 255, .24)) !important;
  color: var(--navy) !important;
  border-color: rgba(255, 255, 255, .90) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .98),
    inset 0 -1px 0 rgba(15, 23, 42, .06),
    0 8px 22px rgba(15, 23, 42, .12) !important;
}

/* ---------- молочное стекло на фото (первый экран) ---------- */
.hero .hero-cta .btn-white {
  background-color: rgba(255, 255, 255, .14) !important;
  background-image: linear-gradient(155deg, rgba(255, 255, 255, .30), rgba(255, 255, 255, .06)) !important;
  color: #fff !important;
  border-color: rgba(255, 255, 255, .55) !important;
  -webkit-backdrop-filter: blur(18px) saturate(180%) !important;
  backdrop-filter: blur(18px) saturate(180%) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .62),
    inset 0 -1px 0 rgba(0, 0, 0, .20),
    0 12px 30px rgba(4, 15, 26, .32) !important;
  text-shadow: 0 1px 10px rgba(0, 0, 0, .42);
}

/* ---------- прозрачное стекло с тонкой гранью ---------- */
.btn-outline {
  background-color: rgba(255, 255, 255, .30) !important;
  background-image: linear-gradient(155deg, rgba(255, 255, 255, .70), rgba(255, 255, 255, .18)) !important;
  color: var(--navy) !important;
  border-color: rgba(23, 23, 23, .16) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .94),
    inset 0 -1px 0 rgba(15, 23, 42, .06),
    0 6px 18px rgba(15, 23, 42, .08) !important;
}

/* ---------- кнопки шапки ---------- */
.header .header-actions .hdr-tool {
  background: linear-gradient(155deg, rgba(255, 255, 255, .20), rgba(255, 255, 255, .05)) !important;
  color: #fff !important;
  border-color: rgba(255, 255, 255, .34) !important;
  -webkit-backdrop-filter: blur(14px) saturate(165%) !important;
  backdrop-filter: blur(14px) saturate(165%) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .38),
    0 6px 18px rgba(0, 0, 0, .20) !important;
}
.header .header-actions .hdr-tool-green {
  background-color: rgba(22, 163, 74, .38) !important;
  background-image: linear-gradient(155deg, rgba(120, 226, 163, .46), rgba(22, 163, 74, .52)) !important;
  color: #fff !important;
  border-color: rgba(255, 255, 255, .44) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .58),
    inset 0 -1px 0 rgba(0, 60, 26, .22),
    0 8px 22px rgba(22, 163, 74, .26) !important;
}
.header .header-actions .hdr-tool-orange {
  background-color: rgba(73, 144, 208, .46) !important;
  background-image: linear-gradient(155deg, rgba(173, 220, 252, .50), rgba(61, 139, 201, .60)) !important;
  color: #fff !important;
  border-color: rgba(255, 255, 255, .48) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .62),
    inset 0 -1px 0 rgba(9, 37, 64, .18),
    0 8px 22px rgba(61, 139, 201, .28) !important;
}
.header .icon-btn {
  background-image: linear-gradient(155deg, rgba(255, 255, 255, .16), rgba(255, 255, 255, .04)) !important;
}

/* ---------- переключатель «Список / Карточки» ---------- */
.view-toggle { background: rgba(255, 255, 255, .40); border: 1px solid rgba(23, 23, 23, .10); border-radius: 12px;
  -webkit-backdrop-filter: blur(12px) saturate(160%); backdrop-filter: blur(12px) saturate(160%); }
.view-btn {
  background: rgba(255, 255, 255, .26) !important;
  color: #334155 !important;
  border-color: transparent !important;
  box-shadow: none !important;
}
.view-btn.on {
  background-color: rgba(20, 20, 24, .56) !important;
  background-image: linear-gradient(155deg, rgba(78, 78, 86, .50), rgba(12, 12, 15, .70)) !important;
  color: #fff !important;
  border-color: rgba(255, 255, 255, .30) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .34), 0 6px 16px rgba(10, 14, 20, .22) !important;
}

/* ---------- кнопка на акционной полосе ---------- */
.promo-band-btn {
  background-color: rgba(255, 255, 255, .30) !important;
  background-image: linear-gradient(155deg, rgba(255, 255, 255, .86), rgba(255, 255, 255, .30)) !important;
  color: #c2410c !important;
  border-color: rgba(255, 255, 255, .78) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .95),
    0 10px 24px rgba(80, 20, 0, .22) !important;
}

/* ---------- плавающая кнопка «Перезвоните мне» ---------- */
body button.kp-quick-btn {
  background-color: rgba(232, 89, 12, .58) !important;
  background-image: linear-gradient(160deg, rgba(255, 176, 118, .56), rgba(232, 89, 12, .66)) !important;
  border-color: rgba(255, 255, 255, .48) !important;
  -webkit-backdrop-filter: blur(16px) saturate(170%) !important;
  backdrop-filter: blur(16px) saturate(170%) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .62),
    inset 0 -1px 0 rgba(120, 36, 0, .24),
    0 12px 28px rgba(232, 89, 12, .34) !important;
}


/* ---------- кнопки на тёмных полосах и в служебных карточках ----------
   Эти места перекрывались правилами «контраст-фикс» из style.css
   (.hero-cta .btn-white, .cta-band .btn-white, .catalog-help-card .btn-outline)
   с !important — здесь та же роль, но настоящим стеклом. */
.hero-cta .btn-white,
.seo-landing-hero .hero-cta .btn-white,
.cta-band .btn-white,
.business-cta .btn-white,
.catalog-help-card .btn-outline {
  background-color: rgba(255, 255, 255, .34) !important;
  background-image: linear-gradient(155deg, rgba(255, 255, 255, .82), rgba(255, 255, 255, .20)) !important;
  color: #111827 !important;
  border-color: rgba(255, 255, 255, .88) !important;
  -webkit-backdrop-filter: blur(16px) saturate(170%) !important;
  backdrop-filter: blur(16px) saturate(170%) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .98),
    inset 0 -1px 0 rgba(15, 23, 42, .08),
    0 10px 26px rgba(0, 0, 0, .20) !important;
  font-weight: 800 !important;
}

.hero .btn-primary,
.cta-band .btn-primary {
  background-color: rgba(255, 255, 255, .34) !important;
  background-image: linear-gradient(155deg, rgba(255, 255, 255, .84), rgba(255, 255, 255, .22)) !important;
  color: #111827 !important;
  border-color: rgba(255, 255, 255, .88) !important;
  text-shadow: none !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .98),
    inset 0 -1px 0 rgba(15, 23, 42, .08),
    0 10px 26px rgba(0, 0, 0, .20) !important;
}

@media (hover: hover) and (pointer: fine) {
  .hero-cta .btn-white:hover,
  .seo-landing-hero .hero-cta .btn-white:hover,
  .cta-band .btn-white:hover,
  .business-cta .btn-white:hover,
  .catalog-help-card .btn-outline:hover,
  .hero .btn-primary:hover,
  .cta-band .btn-primary:hover {
    background-color: rgba(255, 255, 255, .52) !important;
    color: #0a0a0a !important;
    border-color: #fff !important;
  }
}

/* ---------- наведение и нажатие ---------- */
@media (hover: hover) and (pointer: fine) {
  .btn:hover, .hdr-tool:hover, .view-btn:hover, .promo-band-btn:hover, button.kp-quick-btn:hover {
    transform: translateY(-1px);
    filter: brightness(1.07) saturate(1.06);
  }
  .btn-primary:hover, .btn-dark:hover, button.btn[data-cart-add]:hover {
    background-color: rgba(26, 26, 32, .72) !important;
    border-color: rgba(255, 255, 255, .36) !important;
  }
  .btn-copper:hover, .btn-orange:hover, .hero .btn-orange:hover,
  .hero-search .btn-copper:hover, .seo-landing-hero .hero-cta .btn-orange:hover {
    background-color: rgba(73, 144, 208, .66) !important;
    border-color: rgba(255, 255, 255, .62) !important;
  }
  .btn-white:hover {
    background-color: rgba(255, 255, 255, .56) !important;
    border-color: #fff !important;
  }
  .hero .hero-cta .btn-white:hover {
    background-color: rgba(255, 255, 255, .24) !important;
    border-color: rgba(255, 255, 255, .72) !important;
  }
  .btn-outline:hover {
    background-color: rgba(255, 255, 255, .54) !important;
    border-color: rgba(23, 23, 23, .28) !important;
  }
}

.btn:active, .hdr-tool:active, .view-btn:active, .promo-band-btn:active, button.kp-quick-btn:active {
  transform: translateY(0) scale(.995);
  filter: brightness(.97);
  box-shadow:
    inset 0 2px 8px rgba(0, 0, 0, .20),
    inset 0 1px 0 rgba(255, 255, 255, .16) !important;
}

.btn:focus-visible, .hdr-tool:focus-visible, .view-btn:focus-visible {
  outline: 2px solid rgba(91, 164, 224, .9);
  outline-offset: 2px;
}

/* ---------- страховка: нет backdrop-filter — плотные кнопки ---------- */
@supports not ((backdrop-filter: blur(2px)) or (-webkit-backdrop-filter: blur(2px))) {
  .btn-primary, .btn-dark, button.btn[data-cart-add] { background: #171717 !important; }
  .btn-copper, .btn-orange, .hero .btn-orange, .seo-landing-hero .hero-cta .btn-orange { background: #3d8bc9 !important; }
  .btn-white { background: #fff !important; }
  .hero .hero-cta .btn-white { background: rgba(255, 255, 255, .20) !important; }
  .btn-outline { background: #fff !important; }
  .header .header-actions .hdr-tool-green { background: #16a34a !important; }
  .btn::before, .hdr-tool::before, .view-btn::before,
  .promo-band-btn::before, button.kp-quick-btn::before { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .btn, .hdr-tool, .view-btn, .promo-band-btn, button.kp-quick-btn {
    transition: background-color .2s ease, border-color .2s ease, box-shadow .2s ease;
  }
  .btn:hover, .hdr-tool:hover, .view-btn:hover, .promo-band-btn:hover, button.kp-quick-btn:hover { transform: none; }
}
