/* JV Casino game catalogue cards. */
.featured-games__track {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  grid-template-rows: repeat(2, auto);
  gap: 19px 14px;
  padding-block: 11px 14px;
}

.featured-game {
  --game-radius: 13px 13px 13px 3px;
  --game-depth: #341f4c;
  position: relative;
  height: clamp(174px, 16vw, 231px);
  min-width: 0;
  color: var(--text);
  isolation: isolate;
  transition: transform 240ms cubic-bezier(0.2, 0.7, 0.2, 1);
}

.featured-game::before {
  content: "";
  position: absolute;
  inset: 6px 0 -6px;
  border-radius: var(--game-radius);
  background: var(--game-depth);
  box-shadow: 0 6px 16px #0009;
}

.featured-game__face {
  position: absolute;
  inset: 0;
  margin: 0;
  container-type: inline-size;
  isolation: isolate;
  overflow: hidden;
  border-radius: var(--game-radius);
  background: #1b1028;
}

.featured-game__art {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.featured-game__kind {
  position: absolute;
  z-index: 1;
  top: 13px;
  left: 14px;
  padding: 2px 8px;
  border-radius: 5px;
  background: #2a1235;
  color: #ffd4f0;
  font-size: 10px;
  font-weight: 800;
}

.featured-game__caption {
  position: absolute;
  inset: 18% 0 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 10px 10px 13px;
  background: linear-gradient(transparent 15%, #190d2a42 47%, #190d31 98%);
  pointer-events: none;
}

.featured-game__title {
  font-size: clamp(13px, 9.2cqw, 20px);
  font-weight: 820;
  line-height: 1.12;
  overflow-wrap: anywhere;
  letter-spacing: -.04em;
}

.featured-game__provider {
  margin-top: 5px;
  color: #e5c4e7;
  font-size: 10px;
  font-weight: 650;
  line-height: 1.15;
}

.featured-game__play {
  position: absolute;
  z-index: 2;
  inset: 0;
  display: grid;
  place-items: center;
  padding-bottom: 6%;
  text-decoration: none;
}

.featured-game__play .featured-game__button {
  min-height: 38px;
  padding-inline: 19px;
  opacity: 0;
  transform: scale(.9);
  transition: opacity 200ms ease, transform 240ms ease;
}

.featured-game__play:focus-visible {
  outline: 2px solid #ffb8e8;
  outline-offset: -4px;
  border-radius: var(--game-radius);
}

.featured-game:focus-within {
  transform: translateY(-10px);
}

.featured-game:focus-within .featured-game__button {
  opacity: 1;
  transform: scale(1);
}

@media (hover: hover) and (pointer: fine) {
  .featured-game:hover {
    transform: translateY(-10px);
  }

  .featured-game:hover .featured-game__button {
    opacity: 1;
    transform: scale(1);
  }
}

@media (hover: none) {
  .featured-game__play .featured-game__button {
    opacity: 1;
    transform: none;
  }
}

@media (max-width: 930px) {
  .featured-games__track {
    grid-template-columns: repeat(6, minmax(140px, 1fr));
    gap: 17px 10px;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scrollbar-color: #926fa5 #20152a;
    scrollbar-width: thin;
    scroll-padding-inline: 3px;
  }
}

@media (max-width: 700px) {
  .featured-games__track {
    grid-template-columns: repeat(6, clamp(137px, 39vw, 180px));
  }

  .featured-game {
    --game-radius: 9px 9px 9px 3px;
    height: clamp(162px, 45vw, 203px);
  }

  .featured-game__kind {
    top: 7px;
    left: 7px;
    padding: 2px 6px;
    font-size: 9px;
  }

  .featured-game__caption {
    padding: 7px 8px 10px;
  }

  .featured-game__play .featured-game__button {
    min-height: 32px;
    padding-inline: 14px;
    font-size: 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .featured-game,
  .featured-game__play .featured-game__button {
    transition: none;
  }

  .featured-game:hover,
  .featured-game:focus-within {
    transform: none;
  }
}

/* The popover shares its anchor with the language control. */
.language-selector {
  position: relative;
  flex: 0 0 auto;
}

.language-popover:not([hidden]) {
  display: block;
}

.language-popover[hidden] {
  display: none;
}

.language-popover {
  position: absolute;
  z-index: 30;
  top: calc(100% + 9px);
  right: 0;
  width: min(218px, calc(100vw - 26px));
  max-height: min(455px, calc(100dvh - 90px));
  padding: 12px;
  overflow-y: auto;
  border: 1px solid #664370;
  border-radius: 13px;
  background: #21152c;
  box-shadow: 0 14px 42px #0009;
}

.language-popover-title {
  padding: 5px 8px 9px;
  color: #cdbad5;
  font-size: 12px;
  font-weight: 720;
}

.language-list {
  display: grid;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.language-option {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  min-height: 36px;
  padding: 9px;
  border-radius: 6px;
  color: var(--text);
  font-size: 14px;
  line-height: 1.25;
  text-decoration: none;
}

.language-option:hover:not([aria-disabled="true"]),
.language-option.is-current {
  background: #492043;
  color: #ffe2f8;
}

.language-option.is-current {
  font-weight: 700;
}

.language-status:not(:empty) {
  margin-top: 9px;
  padding: 6px 8px 3px;
  color: #d9c6e0;
  font-size: 12px;
  line-height: 1.42;
}

@media (max-width: 700px) {
  .language-popover {
    right: -60px;
  }
}

/* Keep the PeraBet dialog's overlay and local scrolling with the approved panel design. */
.ai-panel[open] {
  display: block;
  position: fixed;
  inset: auto 22px 87px auto;
  width: min(365px, calc(100vw - 34px));
  max-height: calc(100dvh - 106px);
  margin: 0;
  overflow: auto;
  color: var(--text);
}

.ai-panel::backdrop {
  background: #08040d60;
}

.ai-panel .ai-head .btn,
.ai-launch {
  cursor: pointer;
}

#assistant-status:not(:empty),
#assistant-answer:not(:empty) {
  display: block;
  margin: 11px 0 0;
  padding: 9px 11px;
  border: 1px solid #664370;
  border-radius: 7px;
  background: #21152c;
  color: #f1ddf5;
  font-size: 13px;
  line-height: 1.45;
}

#assistant-status:empty,
#assistant-answer:empty {
  margin: 0;
}

.ai-panel .topics a:focus-visible,
.language-option:focus-visible {
  outline: 2px solid #ffb8e8;
  outline-offset: -2px;
}

@media (max-width: 930px) {
  .ai-panel[open] {
    inset: auto 12px 65px auto;
    max-height: calc(100dvh - 83px);
  }
}

@media (max-width: 700px) {
  .ai-panel[open] {
    inset: auto 13px 62px auto;
    max-height: calc(100dvh - 80px);
  }
}
