.oc-gates {
  position: fixed;
  right: 20px;
  bottom: 192px;
  box-sizing: border-box;
  width: 300px;
  max-width: calc(100% - 40px);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.oc-gates-teaser {
  position: relative;
  z-index: 9990;
  width: 100%;
  max-width: 100%;
}

.oc-gates-teaser__open {
  display: flex;
  align-items: center;
  gap: 12px;
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow: hidden;
  margin: 0;
  padding: 10px 36px 10px 10px;
  border: 0;
  border-radius: 14px;
  background-color: #3a1208;
  background-image: url("../images/gates-popup/gates-banner.jpg");
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  box-shadow: 0 12px 32px rgba(8, 18, 48, 0.28);
  text-align: left;
  cursor: pointer;
}

.oc-gates-teaser__logo {
  width: 84px;
  height: 64px;
  flex: 0 0 84px;
  object-fit: contain;
  transform-origin: center;
}

.oc-gates-teaser__open:hover .oc-gates-teaser__logo,
.oc-gates-modal__casino:hover .oc-gates-modal__logo {
  animation: oc-gates-pulse 1.15s ease-in-out infinite;
}

@keyframes oc-gates-pulse {
  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.06);
  }
}

@media (prefers-reduced-motion: reduce) {
  .oc-gates-teaser__open:hover .oc-gates-teaser__logo,
  .oc-gates-modal__casino:hover .oc-gates-modal__logo {
    animation: none;
  }
}

.oc-gates-teaser__heading {
  display: block;
  width: auto;
  max-width: 100%;
  height: auto;
  min-width: 0;
  flex: 1 1 0;
  object-fit: contain;
}

.oc-gates-teaser__close,
.oc-gates-modal__close {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: #3c49a9;
  color: #fff;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}

.oc-gates-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(8, 18, 48, 0.62);
}

.oc-gates-modal.is-visible {
  display: flex;
}

.oc-gates-modal__panel {
  position: relative;
  width: min(520px, 100%);
  max-height: calc(100vh - 40px);
  overflow: auto;
  padding: 28px 24px 22px;
  border-radius: 16px;
  background-color: #141d59;
  background-image: url("../svg/hero-block-pattern.svg");
  background-position: 50% 50%;
  background-size: 295px;
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.35);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.oc-gates-modal__header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 0 32px 18px 0;
}

.oc-gates-modal__provider {
  width: 108px;
  height: auto;
  flex: 0 0 108px;
  object-fit: contain;
}

.oc-gates-modal__copy {
  min-width: 0;
  flex: 1 1 auto;
}

.oc-gates-modal__title {
  margin: 0 0 6px;
  color: #fff;
  font-size: 22px;
  line-height: 1.2;
}

.oc-gates-modal__intro {
  margin: 0;
  color: #fff;
  font-size: 14px;
}

.oc-gates-modal__list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.oc-gates-modal__casino {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 14px 14px 16px;
  border: 1px solid #e4e9f2;
  border-radius: 12px;
  background: #fff;
}

.oc-gates-modal__brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.oc-gates-modal__logo {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  flex: 0 0 64px;
  border-radius: 50%;
  overflow: hidden;
}

.oc-gates-modal__logo img {
  width: 44px;
  height: 44px;
  object-fit: contain;
}

.oc-gates-modal__name {
  color: #142033;
  font-size: 18px;
  font-weight: 700;
}

.oc-gates-modal__play {
  display: inline-block;
  padding: 12px 18px;
  border-radius: 4px;
  background: #0bd175;
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.oc-gates-modal__play:hover {
  background: #09b866;
  color: #fff;
}

@media (max-width: 767px) {
  .oc-gates-teaser__open {
    gap: 10px;
    padding: 8px 32px 8px 8px;
  }

  .oc-gates-teaser__logo {
    width: 64px;
    height: 48px;
    flex-basis: 64px;
  }

  .oc-gates-modal {
    align-items: flex-end;
    padding: 12px;
    padding-bottom: max(12px, env(safe-area-inset-bottom));
  }

  .oc-gates-modal__panel {
    width: 100%;
    max-height: calc(100dvh - 24px);
    padding: 22px 16px 16px;
    border-radius: 14px;
  }

  .oc-gates-modal__header {
    gap: 12px;
    margin-right: 28px;
  }

  .oc-gates-modal__provider {
    width: 84px;
    flex-basis: 84px;
  }

  .oc-gates-modal__title {
    font-size: 20px;
  }

  .oc-gates-modal__intro {
    font-size: 13px;
  }

  .oc-gates-modal__casino {
    align-items: stretch;
    flex-direction: column;
    gap: 12px;
    padding: 12px;
  }

  .oc-gates-modal__logo {
    width: 52px;
    height: 52px;
    flex-basis: 52px;
  }

  .oc-gates-modal__logo img {
    width: 36px;
    height: 36px;
  }

  .oc-gates-modal__name {
    font-size: 16px;
  }

  .oc-gates-modal__play {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 44px;
  }
}

@media (min-width: 768px) and (max-width: 1023px) {
  .oc-gates-modal__panel {
    width: min(600px, calc(100% - 48px));
  }
}

@media (min-width: 1024px) and (max-width: 1199px) {
  .oc-gates {
    bottom: 252px;
  }
}

@media (min-width: 1024px) {
  .oc-gates {
    right: 20px;
    width: 360px;
    max-width: calc(100% - 40px);
  }

  .oc-gates-teaser__open {
    min-height: 96px;
    padding: 10px 40px 10px 10px;
  }

  .oc-gates-teaser__logo {
    width: 84px;
    height: 64px;
    flex-basis: 84px;
  }

  .oc-gates-modal__panel {
    width: 560px;
    padding: 32px 28px 24px;
  }

  .oc-gates-modal__provider {
    width: 120px;
    flex-basis: 120px;
  }

  .oc-gates-modal__title {
    font-size: 26px;
  }

  .oc-gates-modal__logo {
    width: 72px;
    height: 72px;
    flex-basis: 72px;
  }

  .oc-gates-modal__logo img {
    width: 48px;
    height: 48px;
  }
}

@media (min-width: 1280px) {
  .oc-gates {
    width: 400px;
  }

  .oc-gates-teaser__open {
    min-height: 108px;
    padding: 12px 42px 12px 12px;
  }

  .oc-gates-teaser__logo {
    width: 96px;
    height: 72px;
    flex-basis: 96px;
  }
}

.cookies-not-set .oc-gates {
  bottom: 62px;
}

@media (max-width: 1023px) {
  .oc-gates,
  .cookies-not-set .oc-gates {
    top: 50%;
    right: auto;
    bottom: auto;
    left: 50%;
    width: min(420px, calc(100% - 32px));
    max-width: calc(100% - 32px);
    transform: translate(-50%, -50%);
  }
}

@media (max-width: 767px) {
  .oc-gates,
  .cookies-not-set .oc-gates {
    right: 16px;
    left: 16px;
    width: auto;
    max-width: none;
    transform: translateY(-50%);
  }
}
