.fc-wrap,
.fc-wrap * {
  box-sizing: border-box;
}

.fc-wrap {
  --fc-green: #87B43E;
  --fc-green-dark: #5f8a2a;
  --fc-green-light: #a6cc5a;
  --fc-ink: #1f2a1b;
  --fc-muted: #6b6b6b;
  --fc-card: #ffffff;
  --fc-soft: #f4f8e8;
  --fc-border: #eaf1d8;
  position: fixed;
  right: 24px;
  bottom: 90px;
  z-index: 9999;
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
}

.fc-overlay {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  background: rgba(0, 0, 0, .38);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  -webkit-transition: opacity .25s, visibility .25s;
  -moz-transition: opacity .25s, visibility .25s;
  transition: opacity .25s, visibility .25s;
}

.fc-popup {
  position: absolute;
  right: 0;
  bottom: 82px;
  width: 420px;
  max-width: calc(100vw - 32px);
  max-height: calc(100vh - 120px);
  background: var(--fc-card);
  border: 1px solid rgba(63, 63, 63, .12);
  border-radius: 8px;
  box-shadow: 0 22px 55px rgba(0, 0, 0, .24);
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  -webkit-transform: translateY(16px);
  -moz-transform: translateY(16px);
  transform: translateY(16px);
  -webkit-transition: opacity .25s, visibility .25s, transform .25s;
  -moz-transition: opacity .25s, visibility .25s, transform .25s;
  transition: opacity .25s, visibility .25s, transform .25s;
}

.fc-wrap.is-open .fc-overlay,
.fc-wrap.is-open .fc-popup {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.fc-wrap.is-open .fc-popup {
  -webkit-transform: translateY(0);
  -moz-transform: translateY(0);
  transform: translateY(0);
}

.fc-popup-head {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 18px 18px 16px;
  background: var(--fc-green);
  color: #ffffff;
}

.fc-popup-grip {
  display: none;
}

.fc-popup-head-text {
  flex: 1 1 auto;
  min-width: 0;
}

.fc-popup-title {
  color: #ffffff;
  font-size: 22px;
  line-height: 28px;
  font-weight: 600;
  margin: 0 0 4px;
}

.fc-popup-sub {
  color: rgba(255, 255, 255, .9);
  font-size: 14px;
  line-height: 20px;
  margin: 0;
}

.fc-close {
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(255, 255, 255, .45);
  border-radius: 50%;
  background: transparent;
  color: #ffffff;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  -webkit-transition: background .2s, border-color .2s;
  -moz-transition: background .2s, border-color .2s;
  transition: background .2s, border-color .2s;
}

.fc-close:hover,
.fc-close:focus {
  background: rgba(255, 255, 255, .16);
  border-color: #ffffff;
}

.fc-popup-body {
  max-height: calc(100vh - 230px);
  overflow-y: auto;
  padding: 6px 0;
}

.fc-shop {
  display: flex;
  gap: 14px;
  padding: 16px 18px;
  border-bottom: 1px solid #eeeeee;
}

.fc-shop:last-child {
  border-bottom: 0;
}

.fc-shop-badge {
  flex: 0 0 32px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(135, 180, 62, .14);
  color: var(--fc-green-dark);
  font-size: 16px;
  line-height: 32px;
  text-align: center;
  font-weight: 700;
}

.fc-shop-info {
  flex: 1 1 auto;
  min-width: 0;
}

.fc-shop-title {
  color: #3f3f3f;
  font-size: 18px;
  line-height: 24px;
  font-weight: 600;
  margin: 0 0 2px;
}

.fc-shop-owner,
.fc-shop-addr {
  color: #555555;
  font-size: 14px;
  line-height: 20px;
  margin: 0 0 8px;
}

.fc-shop-owner {
  color: #777777;
  margin-bottom: 4px;
}

.fc-shop-note {
  white-space: nowrap;
}

.fc-shop-phones {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.fc-phone-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 34px;
  padding: 7px 10px;
  background: var(--fc-soft);
  border: 1px solid rgba(135, 180, 62, .35);
  color: var(--fc-green-dark);
  font-size: 14px;
  line-height: 18px;
  font-weight: 600;
  text-decoration: none;
  -webkit-transition: background .2s, color .2s, border-color .2s;
  -moz-transition: background .2s, color .2s, border-color .2s;
  transition: background .2s, color .2s, border-color .2s;
}

.fc-phone-link:hover,
.fc-phone-link:focus {
  background: var(--fc-green);
  border-color: var(--fc-green);
  color: #ffffff;
  text-decoration: none;
}

.fc-phone-ico {
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
}

.fc-tooltip {
  position: absolute;
  right: 78px;
  bottom: 9px;
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: calc(100vw - 130px);
  min-height: 46px;
  padding: 11px 12px 11px 15px;
  background: var(--fc-card);
  border: 1px solid rgba(63, 63, 63, .1);
  border-radius: 8px;
  box-shadow: 0 14px 32px rgba(0, 0, 0, .18);
  color: #3f3f3f;
  pointer-events: auto;
  opacity: 1;
  visibility: visible;
  -webkit-transform: translateX(0);
  -moz-transform: translateX(0);
  transform: translateX(0);
  -webkit-transition: opacity .2s, visibility .2s, transform .2s;
  -moz-transition: opacity .2s, visibility .2s, transform .2s;
  transition: opacity .2s, visibility .2s, transform .2s;
}

.fc-tooltip::before {
  content: "";
  position: absolute;
  right: -8px;
  top: 50%;
  width: 14px;
  height: 14px;
  background: var(--fc-card);
  border-right: 1px solid rgba(63, 63, 63, .1);
  border-bottom: 1px solid rgba(63, 63, 63, .1);
  -webkit-transform: translateY(-50%) rotate(45deg);
  -moz-transform: translateY(-50%) rotate(45deg);
  transform: translateY(-50%) rotate(45deg);
}

.fc-tooltip-text {
  position: relative;
  color: #3f3f3f;
  font-size: 14px;
  line-height: 18px;
  font-weight: 600;
  white-space: nowrap;
}

.fc-tooltip-close {
  position: relative;
  -ms-flex: 0 0 22px;
  flex: 0 0 22px;
  width: 22px;
  height: 22px;
  border: 0;
  border-radius: 50%;
  background: #eeeeee;
  color: #666666;
  cursor: pointer;
  font-size: 18px;
  line-height: 20px;
  padding: 0;
}

.fc-tooltip-close:hover,
.fc-tooltip-close:focus {
  background: #dddddd;
  color: #333333;
}

.fc-wrap.is-open .fc-tooltip,
.fc-wrap.is-tooltip-hidden .fc-tooltip {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  -webkit-transform: translateX(-8px);
  -moz-transform: translateX(-8px);
  transform: translateX(-8px);
}

.fc-btn {
  position: relative;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  border: 0;
  cursor: pointer;
  color: #ffffff;
  background: linear-gradient(135deg, var(--fc-green-light) 0%, var(--fc-green) 55%, var(--fc-green-dark) 100%);
  box-shadow: 0 12px 30px rgba(135, 180, 62, 0.45), 0 4px 10px rgba(0, 0, 0, 0.10), inset 0 1px 0 rgba(255, 255, 255, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  pointer-events: auto;
  outline: none;
  overflow: visible;
  isolation: isolate;
  -webkit-tap-highlight-color: transparent;
  -webkit-transition: transform .25s ease, box-shadow .25s ease;
  -moz-transition: transform .25s ease, box-shadow .25s ease;
  transition: transform .25s ease, box-shadow .25s ease;
}

.fc-btn:hover,
.fc-btn:focus,
.fc-wrap.is-open .fc-btn {
  box-shadow: 0 14px 34px rgba(135, 180, 62, 0.55), 0 6px 12px rgba(0, 0, 0, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.35);
  -webkit-transform: translateY(-2px);
  -moz-transform: translateY(-2px);
  transform: translateY(-2px);
}

.fc-btn-icon {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.fc-btn-icon svg {
  display: block;
  width: 28px;
  height: 28px;
  color: #ffffff;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.18));
  -webkit-transform-origin: center;
  -moz-transform-origin: center;
  transform-origin: center;
  -webkit-animation: fcPhoneRing 3.4s ease-in-out infinite;
  animation: fcPhoneRing 3.4s ease-in-out infinite;
}

.fc-btn-pulse {
  position: absolute;
  top: -9px;
  right: -9px;
  bottom: -9px;
  left: -9px;
  z-index: 1;
  border: 2px solid rgba(135, 180, 62, .55);
  border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(135, 180, 62, .42);
  pointer-events: none;
  -webkit-transform-origin: center;
  -moz-transform-origin: center;
  transform-origin: center;
  will-change: opacity, transform, box-shadow;
  -webkit-animation: fcPulse 2.35s cubic-bezier(.22, .61, .36, 1) infinite;
  animation: fcPulse 2.35s cubic-bezier(.22, .61, .36, 1) infinite;
}

.fc-btn-pulse--delay {
  -webkit-animation-delay: 1.05s;
  animation-delay: 1.05s;
}

.fc-wrap.is-open .fc-btn-pulse {
  display: none;
}

.fc-wrap.is-open .fc-btn-icon svg {
  -webkit-animation: none;
  animation: none;
}

body.fc-modal-open {
  overflow: hidden;
}

@-webkit-keyframes fcPulse {
  0% {
    opacity: .85;
    -webkit-transform: scale(.78);
    transform: scale(.78);
    box-shadow: 0 0 0 0 rgba(135, 180, 62, .42);
  }
  60% {
    opacity: .28;
    box-shadow: 0 0 0 12px rgba(135, 180, 62, .14);
  }
  100% {
    opacity: 0;
    -webkit-transform: scale(1.45);
    transform: scale(1.45);
    box-shadow: 0 0 0 20px rgba(135, 180, 62, 0);
  }
}

@keyframes fcPulse {
  0% {
    opacity: .85;
    -webkit-transform: scale(.78);
    transform: scale(.78);
    box-shadow: 0 0 0 0 rgba(135, 180, 62, .42);
  }
  60% {
    opacity: .28;
    box-shadow: 0 0 0 12px rgba(135, 180, 62, .14);
  }
  100% {
    opacity: 0;
    -webkit-transform: scale(1.45);
    transform: scale(1.45);
    box-shadow: 0 0 0 20px rgba(135, 180, 62, 0);
  }
}

@-webkit-keyframes fcPhoneRing {
  0%, 78%, 100% {
    -webkit-transform: rotate(0deg) scale(1);
    transform: rotate(0deg) scale(1);
  }
  82% {
    -webkit-transform: rotate(-10deg) scale(1.04);
    transform: rotate(-10deg) scale(1.04);
  }
  86% {
    -webkit-transform: rotate(9deg) scale(1.04);
    transform: rotate(9deg) scale(1.04);
  }
  90% {
    -webkit-transform: rotate(-7deg) scale(1.02);
    transform: rotate(-7deg) scale(1.02);
  }
  94% {
    -webkit-transform: rotate(5deg) scale(1.02);
    transform: rotate(5deg) scale(1.02);
  }
}

@keyframes fcPhoneRing {
  0%, 78%, 100% {
    -webkit-transform: rotate(0deg) scale(1);
    transform: rotate(0deg) scale(1);
  }
  82% {
    -webkit-transform: rotate(-10deg) scale(1.04);
    transform: rotate(-10deg) scale(1.04);
  }
  86% {
    -webkit-transform: rotate(9deg) scale(1.04);
    transform: rotate(9deg) scale(1.04);
  }
  90% {
    -webkit-transform: rotate(-7deg) scale(1.02);
    transform: rotate(-7deg) scale(1.02);
  }
  94% {
    -webkit-transform: rotate(5deg) scale(1.02);
    transform: rotate(5deg) scale(1.02);
  }
}

@media only screen and (min-width: 0px) and (max-width: 767px) {
  .fc-wrap {
    right: 16px;
    bottom: 76px;
  }

  .fc-popup {
    position: fixed;
    left: 12px;
    right: 12px;
    bottom: 88px;
    width: auto;
    max-width: none;
    max-height: calc(100vh - 110px);
  }

  .fc-popup-head {
    padding: 16px;
  }

  .fc-popup-grip {
    position: absolute;
    top: 8px;
    left: 50%;
    display: block;
    width: 42px;
    height: 4px;
    border-radius: 4px;
    background: rgba(255, 255, 255, .55);
    -webkit-transform: translateX(-50%);
    -moz-transform: translateX(-50%);
    transform: translateX(-50%);
  }

  .fc-popup-title {
    font-size: 20px;
    line-height: 26px;
    padding-top: 6px;
  }

  .fc-popup-body {
    max-height: calc(100vh - 220px);
  }

  .fc-btn {
    width: 58px;
    height: 58px;
  }

  .fc-tooltip {
    right: 72px;
    bottom: 6px;
    max-width: calc(100vw - 104px);
  }

  .fc-tooltip-text {
    white-space: normal;
  }

  .fc-tooltip-close {
    -ms-flex: 0 0 28px;
    flex: 0 0 28px;
    width: 28px;
    height: 28px;
    font-size: 20px;
  }

  .fc-shop {
    padding: 15px 16px;
  }

  .fc-shop-phones {
    display: block;
  }

  .fc-phone-link {
    width: 100%;
    justify-content: center;
    margin-top: 8px;
  }
}

@media (max-width: 380px) {
  .fc-wrap { right: 12px; bottom: 72px; }
  .fc-btn { width: 54px; height: 54px; }
  .fc-btn-icon svg { width: 23px; height: 23px; }
  .fc-phone-link { padding: 7px 11px; font-size: 12.5px; }
}

@media (prefers-reduced-motion: reduce) {
  .fc-btn-icon,
  .fc-btn-pulse { animation: none !important; }
  .fc-popup,
  .fc-tooltip,
  .fc-overlay,
  .fc-btn { transition: none !important; }
}
