/* Festival Shop — premium cookie notice (.fst-cookies)
   Informational 152-ФЗ notice only — does not gate Metrika. */

html.fst-cookies-done .fst-cookies {
  display: none !important;
}

.fst-cookies {
  --fst-ck-pink: #c41a5b;
  --fst-ck-pink-hot: #d82e6b;
  --fst-ck-ink: #1f1018;
  --fst-ck-muted: #5c4a52;
  --fst-ck-line: rgba(196, 26, 91, 0.14);
  --fst-ck-glass: rgba(255, 252, 253, 0.86);
  --fst-ck-shadow: 0 18px 48px rgba(31, 16, 24, 0.16), 0 4px 14px rgba(196, 26, 91, 0.1);
  /* Desktop / default: clear Chaty + to-top on the right */
  --fst-ck-bottom: calc(24px + env(safe-area-inset-bottom, 0px));
  --fst-ck-left: calc(24px + env(safe-area-inset-left, 0px));
  --fst-ck-right: auto;
  --fst-ck-max: 440px;
  --fst-ck-z: 100050;

  position: fixed;
  left: var(--fst-ck-left);
  right: var(--fst-ck-right);
  bottom: var(--fst-ck-bottom);
  z-index: var(--fst-ck-z);
  box-sizing: border-box;
  width: min(var(--fst-ck-max), calc(100vw - 48px));
  max-width: calc(100vw - 48px);
  margin: 0;
  padding: 0;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transform: translate3d(0, 14px, 0);
  transition:
    opacity 0.35s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.4s cubic-bezier(0.22, 1, 0.36, 1),
    visibility 0.35s ease;
}

.fst-cookies.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translate3d(0, 0, 0);
  pointer-events: auto;
}

.fst-cookies.is-leaving {
  opacity: 0;
  visibility: hidden;
  transform: translate3d(0, 10px, 0);
  pointer-events: none;
}

.fst-cookies__card {
  position: relative;
  box-sizing: border-box;
  padding: 18px 18px 16px;
  border-radius: 18px;
  border: 1px solid var(--fst-ck-line);
  background:
    linear-gradient(165deg, rgba(255, 255, 255, 0.94) 0%, rgba(255, 245, 249, 0.9) 48%, rgba(255, 252, 253, 0.88) 100%);
  backdrop-filter: blur(16px) saturate(1.15);
  -webkit-backdrop-filter: blur(16px) saturate(1.15);
  box-shadow: var(--fst-ck-shadow);
  color: var(--fst-ck-ink);
}

.fst-cookies__close {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(31, 16, 24, 0.04);
  color: #7a6570;
  cursor: pointer;
  appearance: none;
  -webkit-tap-highlight-color: transparent;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.fst-cookies__close:hover {
  background: rgba(196, 26, 91, 0.1);
  color: var(--fst-ck-pink);
}

.fst-cookies__close:focus {
  outline: none;
}

.fst-cookies__close:focus-visible {
  outline: 2px solid var(--fst-ck-pink);
  outline-offset: 2px;
}

.fst-cookies__row {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding-right: 28px;
}

.fst-cookies__icon {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  margin-top: 2px;
  filter: drop-shadow(0 6px 12px rgba(196, 26, 91, 0.28));
}

.fst-cookies__icon svg {
  display: block;
  width: 40px;
  height: 40px;
}

.fst-cookies__body {
  flex: 1 1 auto;
  min-width: 0;
}

.fst-cookies__title {
  margin: 0 0 6px;
  font-family: inherit;
  font-size: 16.5px;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.015em;
  color: var(--fst-ck-ink);
}

.fst-cookies__text {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--fst-ck-muted);
}

.fst-cookies__link {
  color: var(--fst-ck-pink);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
  transition: color 0.15s ease;
}

.fst-cookies__link:hover {
  color: var(--fst-ck-pink-hot);
}

.fst-cookies__actions {
  display: flex;
  margin-top: 14px;
}

.fst-cookies__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  width: 100%;
  margin: 0;
  padding: 11px 18px;
  border: 0;
  border-radius: 12px;
  cursor: pointer;
  appearance: none;
  -webkit-tap-highlight-color: transparent;
  font-family: inherit;
  font-size: 14.5px;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: #fff;
  background: linear-gradient(160deg, var(--fst-ck-pink-hot) 0%, var(--fst-ck-pink) 100%);
  box-shadow:
    0 8px 20px rgba(196, 26, 91, 0.28),
    0 1px 0 rgba(255, 255, 255, 0.18) inset;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    background 0.2s ease;
}

.fst-cookies__btn:hover {
  background: linear-gradient(160deg, #e03a78 0%, var(--fst-ck-pink) 100%);
  box-shadow:
    0 12px 26px rgba(196, 26, 91, 0.34),
    0 1px 0 rgba(255, 255, 255, 0.2) inset;
  transform: translateY(-1px);
}

.fst-cookies__btn:active {
  transform: translateY(0);
  box-shadow: 0 4px 12px rgba(196, 26, 91, 0.24);
}

.fst-cookies__btn:focus {
  outline: none;
}

.fst-cookies__btn:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
  box-shadow:
    0 0 0 5px rgba(196, 26, 91, 0.35),
    0 12px 26px rgba(196, 26, 91, 0.34);
}

/* Hide legacy My Popup cookie notice (yellow/orange preset) */
.mypopup-modal.fst-cookies-legacy-hide,
.mypopup-modal.fst-cookies-legacy-hide + .mypopup-over,
body.fst-cookies-legacy-suppressed .mypopup-modal[data-fst-cookie-legacy="1"],
body.fst-cookies-legacy-suppressed .mypopup-over.fst-cookies-legacy-over {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* Tablet / mobile: sit above #bottom-menu.fs-bnav, keep clear of Chaty/to-top */
@media (max-width: 991px) {
  .fst-cookies {
    --fst-ck-max: 560px;
    --fst-ck-left: 12px;
    --fst-ck-right: 12px;
    --fst-ck-bottom: calc(72px + env(safe-area-inset-bottom, 0px));
    width: auto;
    max-width: none;
  }

  .fst-cookies__card {
    padding: 16px 14px 14px;
    border-radius: 16px;
  }

  .fst-cookies__title {
    font-size: 16px;
  }

  .fst-cookies__text {
    font-size: 13px;
  }
}

@media (min-width: 992px) {
  .fst-cookies {
    --fst-ck-max: 460px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .fst-cookies,
  .fst-cookies__btn,
  .fst-cookies__close {
    transition: opacity 0.15s ease, visibility 0.15s ease;
    transform: none !important;
  }
}
