/* Approved contact concept; scoped to #header_contact and its Fancybox instance. */
.tr-callback-layer .fancybox-bg { background: #000; }
.tr-callback-layer.fancybox-is-open .fancybox-bg { opacity: .76; }
.tr-callback-layer .fancybox-slide--html { padding: 28px; }
#header_contact.tr-callback {
  position: relative; width: 624px; min-width: 0; max-width: 100%; padding: 0; overflow: hidden;
  border-radius: 16px; color: #fff; background: #262626;
  font-family: "Manrope", sans-serif; box-shadow: 0 34px 90px rgba(0,0,0,.44);
}
#header_contact::after {
  content: ""; position: absolute; right: -86px; bottom: -112px; width: 260px; height: 260px;
  border: 1px solid rgba(251,167,107,.17); border-radius: 50%; pointer-events: none;
}
#header_contact .tr-callback-body {
  position: relative; padding: 50px; overflow-y: auto; overscroll-behavior: contain;
  max-height: calc(100vh - 56px); max-height: calc(100dvh - 56px);
  scrollbar-width: thin; scrollbar-color: #904a27 #303030;
}
#header_contact .tr-callback-body::-webkit-scrollbar { width: 6px; }
#header_contact .tr-callback-body::-webkit-scrollbar-thumb { background: #904a27; border-radius: 6px; }
#header_contact .tr-callback-close {
  position: absolute; top: 18px; right: 18px; z-index: 3; display: grid;
  width: 42px; height: 42px; padding: 0; place-items: center; border: 0; border-radius: 50%;
  color: #fff; background: #262626; cursor: pointer; transition: background-color 180ms ease;
}
#header_contact .tr-callback-close:hover { background: #3a3a3a; }
#header_contact .tr-callback-close svg { width: 20px; height: 20px; }
#header_contact .tr-callback-title {
  max-width: 500px; margin: 0; text-align: left; text-wrap: balance;
  font-size: clamp(34px,5vw,44px); font-weight: 750; line-height: 1.08; letter-spacing: -.035em;
}
#header_contact .tr-callback-lead { max-width: 500px; margin: 18px 0 0; color: rgba(255,255,255,.72); font-size: 16px; line-height: 1.55; }
#header_contact .tr-callback-channels { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; margin-top: 34px; }
#header_contact .tr-callback-channel {
  position: relative; display: grid; grid-template-columns: 48px minmax(0,1fr) 28px;
  gap: 14px; align-items: center; min-height: 108px; padding: 20px; overflow: hidden;
  border: 1px solid transparent; border-radius: 15px; color: #262626; background: #fff;
  text-align: left; text-decoration: none; box-shadow: 0 12px 28px rgba(0,0,0,.14);
  transition: transform 200ms cubic-bezier(.16,1,.3,1), box-shadow 200ms ease, background-color 200ms ease, border-color 200ms ease;
}
#header_contact .tr-callback-channel:hover { transform: translateY(-4px); box-shadow: 0 20px 38px rgba(0,0,0,.24); }
#header_contact .tr-callback-channel--telegram:hover { border-color: rgba(34,158,217,.42); background: #f5fbfe; }
#header_contact .tr-callback-channel--max:hover { border-color: rgba(102,87,255,.38); background: #f8f7ff; }
#header_contact .tr-callback-icon { display: grid; width: 48px; height: 48px; place-items: center; border-radius: 13px; }
#header_contact .tr-callback-channel--telegram .tr-callback-icon { background: rgba(34,158,217,.1); }
#header_contact .tr-callback-channel--max .tr-callback-icon { background: rgba(102,87,255,.09); }
#header_contact .tr-callback-icon img { display: block; width: 30px; height: 30px; object-fit: contain; }
#header_contact .tr-callback-channel--max .tr-callback-icon img { width: 31px; height: 31px; border-radius: 9px; }
#header_contact .tr-callback-label { display: block; font-size: 17px; font-weight: 800; line-height: 1.15; letter-spacing: -.015em; }
#header_contact .tr-callback-action { display: block; margin-top: 6px; color: rgba(38,38,38,.58); font-size: 12px; font-weight: 650; line-height: 1.2; }
#header_contact .tr-callback-arrow { display: grid; width: 28px; height: 28px; place-items: center; border-radius: 50%; color: #904a27; background: rgba(144,74,39,.09); transition: transform 200ms cubic-bezier(.16,1,.3,1), color 200ms ease, background-color 200ms ease; }
#header_contact .tr-callback-channel:hover .tr-callback-arrow { color: #fff; background: #904a27; transform: translateX(3px); }
#header_contact .tr-callback-arrow svg { width: 15px; height: 15px; }
#header_contact .tr-callback-divider { position: relative; z-index: 1; display: flex; align-items: center; gap: 14px; margin: 28px 0 18px; color: rgba(255,255,255,.46); font-size: 12px; font-weight: 700; }
#header_contact .tr-callback-divider::before, #header_contact .tr-callback-divider::after { content: ""; height: 1px; flex: 1; background: rgba(255,255,255,.14); }
#header_contact .tr-callback-phone { position: relative; z-index: 1; display: flex; width: 100%; min-height: 64px; align-items: center; justify-content: space-between; padding: 0 18px; border: 1px solid rgba(255,255,255,.14); border-radius: 14px; color: #fff; background: rgba(255,255,255,.045); text-decoration: none; transition: border-color 180ms ease, background-color 180ms ease; }
#header_contact .tr-callback-phone:hover { border-color: rgba(251,167,107,.56); background: rgba(251,167,107,.08); }
#header_contact .tr-callback-phone-main { display: flex; align-items: center; gap: 12px; font-size: 15px; font-weight: 750; }
#header_contact .tr-callback-phone-main svg { flex: 0 0 22px; width: 22px; height: 22px; color: #fba76b; }
#header_contact .tr-callback-phone-hint { color: rgba(255,255,255,.52); font-size: 12px; font-weight: 650; }
#header_contact a:focus-visible, #header_contact button:focus-visible { outline: 3px solid #fba76b; outline-offset: 4px; }
#header_contact ::selection { color: #fff; background: #904a27; }
@media (max-width:720px) {
  .tr-callback-layer .fancybox-slide--html { display: flex; align-items: flex-end; justify-content: center; padding: 14px 10px 10px; }
  .tr-callback-layer .fancybox-slide--html::before { display: none; }
  #header_contact.tr-callback { width: 100%; border-radius: 20px 20px 14px 14px; }
  #header_contact .tr-callback-body { padding: 36px 22px 24px; max-height: calc(100vh - 24px); max-height: calc(100dvh - 24px); }
  #header_contact::before { content: ""; position: absolute; z-index: 2; top: 9px; left: 50%; width: 42px; height: 4px; border-radius: 999px; background: rgba(255,255,255,.26); transform: translateX(-50%); }
  #header_contact .tr-callback-close { top: 22px; right: 14px; }
  #header_contact .tr-callback-title { max-width: calc(100% - 46px); font-size: clamp(29px,9vw,36px); }
  #header_contact .tr-callback-lead { margin-top: 14px; font-size: 15px; }
  #header_contact .tr-callback-channels { grid-template-columns: 1fr; gap: 10px; margin-top: 26px; }
  #header_contact .tr-callback-channel { min-height: 82px; grid-template-columns: 46px minmax(0,1fr) 28px; padding: 16px; }
  #header_contact .tr-callback-icon { width: 46px; height: 46px; }
  #header_contact .tr-callback-divider { margin: 20px 0 14px; }
  #header_contact .tr-callback-phone { min-height: 58px; }
  #header_contact .tr-callback-phone-hint { display: none; }
}
@media (max-width:390px) {
  .tr-callback-layer .fancybox-slide--html { padding: 8px 6px 6px; }
  #header_contact .tr-callback-body { padding: 34px 18px 20px; max-height: calc(100vh - 14px); max-height: calc(100dvh - 14px); }
}
@media (prefers-reduced-motion:reduce) {
  #header_contact *, #header_contact::before, #header_contact::after, .tr-callback-layer .fancybox-bg { transition-duration: 1ms !important; animation-duration: 1ms !important; }
}


/* Keep returned focus without retaining the shared button's focus fill. */
.header__button a.btn-secondary[href="#header_contact"]:focus:not(:hover):not(:active),
.mobmenu__button a.btn-secondary[href="#header_contact"]:focus:not(:hover):not(:active) {
  background: transparent; color: #FAA66A;
}
.header__button a.btn-secondary[href="#header_contact"]:focus-visible,
.mobmenu__button a.btn-secondary[href="#header_contact"]:focus-visible {
  outline: 3px solid #FAA66A; outline-offset: 4px;
}
@media (hover: none) {
  .header__button a.btn-secondary[href="#header_contact"]:focus:not(:active),
  .mobmenu__button a.btn-secondary[href="#header_contact"]:focus:not(:active) {
    background: transparent; color: #FAA66A;
  }
}
