/*
 * Responsive sizing parity layer.
 *
 * The legacy styles sized the home cards from the viewport (8vw) and capped
 * them at 150px. In a split desktop window that made the entire lobby look
 * zoomed out. This layer keeps controls readable and lets horizontal rails
 * reveal fewer, larger cards, matching the behaviour of modern casino UIs.
 */

:root {
  --wanted-desktop-gutter: clamp(32px, 3.25vw, 48px);
  --wanted-tablet-gutter: clamp(20px, 3vw, 28px);
  --wanted-mobile-gutter: clamp(12px, 4vw, 16px);
  --wanted-home-card-width: clamp(156px, 9vw, 168px);
  --wanted-home-card-gap: clamp(12px, 1vw, 16px);
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

.hp,
.hp.content-wrap {
  --hp-max: 1600px;
  max-width: min(100%, var(--hp-max));
}

.hp {
  container: wanted-home / inline-size;
}

.hp-banners {
  gap: 16px;
}

.hp-banner {
  width: 100% !important;
  max-width: none !important;
  height: clamp(156px, 13vw, 220px);
  min-height: 0 !important;
  max-height: none !important;
  aspect-ratio: auto;
}

.hp-tabs {
  max-width: 100%;
  scroll-snap-type: x proximity;
}

.hp-tab {
  min-height: 40px;
  scroll-snap-align: start;
}

.hp-section {
  margin-bottom: 40px;
}

.hp-section-head {
  align-items: center;
  flex-wrap: nowrap;
  gap: 12px;
  margin-bottom: 16px;
}

.hp-section-title {
  font-size: 18px;
  line-height: 1.25;
}

.hp-section-title .ic {
  width: 32px;
  height: 32px;
}

.hp-section-title .ic svg {
  width: 18px;
  height: 18px;
}

.hp-section-actions {
  flex: 0 0 auto;
  width: auto;
  margin-left: auto;
  justify-content: flex-end;
}

.hp-see-all {
  min-height: 38px;
  padding: 8px 16px;
  font-size: 14px;
}

.hp-nav-btn {
  width: 38px;
  height: 38px;
}

.hp-row {
  gap: var(--wanted-home-card-gap);
  padding-bottom: 10px;
  scroll-padding-inline: 2px;
  scroll-snap-type: x proximity;
  touch-action: pan-x;
}

.hp-card {
  flex: 0 0 var(--wanted-home-card-width) !important;
  width: var(--wanted-home-card-width) !important;
  min-width: var(--wanted-home-card-width) !important;
  aspect-ratio: 5 / 7;
  border-radius: 11px;
  scroll-snap-align: start;
}

.hp-card-art {
  border-radius: inherit;
}

/* Slightly roomier footer so it keeps the same visual scale as the lobby. */
.wf-footer__inner {
  max-width: 1400px;
  padding: 40px 32px 28px;
}

.wf-footer__top {
  gap: 38px 44px;
}

#app .wf-footer .wf-footer__logo {
  width: 162px;
  height: 38px;
}

.wf-footer__brand {
  gap: 16px;
}

.wf-footer__tag {
  max-width: 285px;
  font-size: 13.5px;
}

.wf-footer__socials {
  gap: 11px;
}

.wf-footer__soc {
  width: 41px;
  height: 41px;
}

.wf-footer__cols {
  gap: 28px 24px;
}

.wf-footer__col ul {
  gap: 10px;
}

.wf-footer__h,
.wf-footer__settings-h {
  font-size: 12px;
}

.wf-footer__a {
  font-size: 14px;
  line-height: 1.4;
}

.wf-footer__fx {
  padding: 11px 14px;
  font-size: 13px;
}

.wf-footer__legal p {
  font-size: 11.5px;
  line-height: 1.7;
}

.wf-footer__rate,
.wf-footer__copy {
  font-size: 13px;
}

@media (min-width: 1126px) {
  #app {
    --wanted-sidebar-width: 240px;
    --header-height: 78px;
  }

  #app > .main > .header {
    padding: 12px 28px !important;
  }

  #app > .main main {
    padding: 24px var(--wanted-desktop-gutter) !important;
  }

  #app > .sidebar > .tc-wrapper > .inner > .item {
    min-height: 46px !important;
    font-size: 14px !important;
  }

  #app > .sidebar > .tc-wrapper > .inner > .sb-section-label {
    font-size: 11px !important;
  }
}

@media (min-width: 1600px) {
  :root {
    --wanted-home-card-width: clamp(164px, 9vw, 176px);
  }

  #app > .main main {
    padding-top: 30px !important;
    padding-bottom: 30px !important;
  }
}

@media (max-width: 1125px) {
  :root {
    --wanted-home-card-width: clamp(150px, 19vw, 160px);
  }

  #app > .main main {
    padding: 20px var(--wanted-tablet-gutter) calc(104px + env(safe-area-inset-bottom, 0px)) !important;
  }

  .hp-banner {
    min-height: clamp(150px, 19vw, 180px);
  }
}

@media (max-width: 768px) {
  :root {
    --wanted-home-card-width: clamp(142px, 22vw, 154px);
    --wanted-home-card-gap: 12px;
  }

  #app > .main > .header {
    padding: 8px var(--wanted-mobile-gutter) !important;
  }

  #app > .main main {
    padding: 16px var(--wanted-mobile-gutter) calc(100px + env(safe-area-inset-bottom, 0px)) !important;
  }

  .header__right {
    flex-direction: row !important;
    align-items: center !important;
  }

  .hp-banners {
    gap: 12px;
    margin-bottom: 24px;
  }

  .hp-section {
    margin-bottom: 30px;
  }

  .hp-section-title {
    font-size: 17px;
  }

  .hp-see-all {
    min-height: 36px;
    padding: 7px 13px;
    font-size: 13px;
  }

  .hp-nav-btn {
    width: 36px;
    height: 36px;
  }

  .wf-footer__inner {
    padding: 30px 18px 24px;
  }

  #app .wf-footer .wf-footer__logo {
    width: 156px;
    height: 36px;
  }

  .wf-footer__top {
    gap: 28px;
  }

  .wf-footer__a {
    font-size: 13.5px;
  }
}

@media (max-width: 560px) {
  :root {
    --wanted-home-card-width: clamp(136px, 40vw, 152px);
    --wanted-home-card-gap: 10px;
  }

  #app > .main main {
    padding-top: 14px !important;
  }

  .hp-banners {
    grid-template-columns: 1fr;
  }

  .hp-banner {
    min-height: clamp(142px, 40vw, 172px);
    max-height: 172px;
    aspect-ratio: 16 / 7;
  }

  .hp-tabs {
    margin-bottom: 26px;
  }

  .hp-tab {
    padding: 9px 14px;
  }

  .hp-section-head {
    align-items: center;
    flex-wrap: nowrap;
    gap: 10px;
  }

  .hp-section-actions {
    min-width: 0;
  }

  .hp-see-all {
    max-width: 128px;
    overflow: hidden;
    text-overflow: ellipsis;
  }
}

@media (max-width: 390px) {
  :root {
    --wanted-home-card-width: clamp(132px, 42vw, 146px);
  }

  .hp-section-title {
    gap: 8px;
    font-size: 16px;
  }

  .hp-section-title .ic {
    width: 30px;
    height: 30px;
  }

  .hp-section-actions {
    gap: 6px;
  }

  .hp-see-all {
    max-width: 106px;
    padding-inline: 10px;
  }

  .hp-nav-btn {
    display: none;
  }
}

/* Home layout reacts to its real content width, including split-screen panes. */
@container wanted-home (max-width: 900px) {
  .hp-card {
    flex-basis: clamp(150px, 18cqw, 156px) !important;
    width: clamp(150px, 18cqw, 156px) !important;
    min-width: clamp(150px, 18cqw, 156px) !important;
  }

  .hp-banners {
    gap: 12px;
  }
}

@container wanted-home (max-width: 660px) {
  .hp-banners {
    grid-template-columns: 1fr;
  }

  .hp-banner {
    min-height: clamp(142px, 34cqw, 172px);
    max-height: 172px;
    aspect-ratio: 16 / 7;
  }

  .hp-card {
    flex-basis: clamp(136px, 40cqw, 152px) !important;
    width: clamp(136px, 40cqw, 152px) !important;
    min-width: clamp(136px, 40cqw, 152px) !important;
  }
}

@media (hover: none) {
  .hp-row {
    scroll-snap-type: x mandatory;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hp-row {
    scroll-behavior: auto;
  }
}
