/* The WAP document uses the same live games, shortcuts and navigation as the
   desktop site. These layouts are for the mobile document at every viewport. */
html.bh-refined-theme:has(> body[data-variant="mobile"]) { scrollbar-width: none; }
html.bh-refined-theme:has(> body[data-variant="mobile"])::-webkit-scrollbar { display: none; }
.bh-refined-theme body.bh-surface[data-variant="mobile"] .mobile-shell {
  width: 100%;
  max-width: 480px;
  margin-inline: auto;
  background: #000;
}
.bh-refined-theme .mobile-shell #main {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  max-width: none;
  margin: 0;
  padding-inline: clamp(12px, 3.5vw, 18px);
}
.bh-refined-theme .mobile-shell .site-header {
  box-sizing: border-box;
  min-height: calc(57px + env(safe-area-inset-top, 0px));
  padding: calc(4px + env(safe-area-inset-top, 0px)) clamp(12px, 3.5vw, 18px) 5px;
  padding-left: calc(8px + env(safe-area-inset-left, 0px));
  background: #000;
  border: 0;
}
.bh-refined-theme .mobile-shell .site-header .brand-crown { width: 44px; height: 44px; }
.bh-refined-theme .mobile-shell .site-header .brand-name[data-brand-style="bohui"] { font-size: 23px; }
.bh-refined-theme .mobile-shell .site-header .brand-domain { font-size: 13px; }
.bh-refined-theme .mobile-shell .site-header .header-actions .bh-profile button {
  min-height: 36px;
  padding: 6px 15px;
  border-radius: 24px;
  font-size: 13px;
}
.bh-refined-theme .mobile-shell #page-home,
.bh-refined-theme .mobile-shell #page-game {
  min-width: 0;
  margin: 0;
  padding: 0;
}

/* The announcement and navigation have their own space around the poster. */
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-areas: "welcome" "slide";
  margin: 3px 0 0;
  overflow: hidden;
  border-radius: 13px;
}
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .hero {
  grid-area: slide;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  width: 100%;
  height: auto;
  aspect-ratio: auto;
  min-height: 0;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: #000;
}
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .carousel-viewport {
  width: 100%;
  height: auto;
  aspect-ratio: 2.87;
  overflow: hidden;
  border-radius: 0 0 12px 12px;
}
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .carousel-viewport:has(.carousel-full-image) {
  aspect-ratio: 2.65 / 1;
}
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .carousel-track:has(.carousel-full-image),
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .carousel-slide:has(.carousel-full-image) {
  height: 100%;
}
/* Keep the source posters' headline, face and CTA above the decorative lower edge. */
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .carousel-full-image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .carousel-slide { border-radius: 0; }
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .announcement {
  position: static;
  grid-area: welcome;
  display: flex;
  justify-content: flex-start;
  gap: 6px;
  height: 20px;
  min-height: 0;
  margin: 0;
  padding: 0 10px;
  border: 0;
  background: linear-gradient(90deg, #32233e, #1d1722 70%);
  color: #f8efff;
  pointer-events: none;
}
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .announcement > [data-icon] { width: 14px; height: 14px; }
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .announcement p {
  min-width: 0;
  margin: 0;
  overflow: hidden;
  color: #fff;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .announcement p > span { margin-left: 8px; font-size: 10px; color: #f0e7f6; }
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .carousel-controls:not([hidden]) {
  position: relative;
  inset: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 22px;
  pointer-events: none;
}
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .carousel-arrow {
  top: 0;
  width: 26px;
  height: 22px;
  padding: 0;
  transform: none;
  border: 0;
  background: transparent;
  opacity: 0;
  pointer-events: none;
}
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .carousel-arrow:focus-visible {
  opacity: 1;
  pointer-events: auto;
  outline: 1px solid #cfafff;
  outline-offset: -2px;
}
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .carousel-pagination {
  position: static;
  display: inline-flex;
  align-items: center;
  gap: 0;
  height: 22px;
  padding: 0;
  transform: none;
  border: 0;
  background: transparent;
}
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .carousel-pagination button {
  display: grid;
  place-items: center;
  width: 18px;
  min-width: 0;
  height: 22px;
  min-height: 0;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  box-shadow: none;
  color: #c5b2ce;
  font-size: 10px;
  pointer-events: auto;
}
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .carousel-pagination [data-slide] span {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #635c68;
}
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .carousel-pagination [data-slide].is-active span { background: #d0a8ef; }
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .hero-copy { padding: 26px 35px 2px 15px; }
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .hero-title { margin: 0; font-size: 18px; }
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .hero-copy p { margin: 2px 0; }
.bh-refined-theme .mobile-shell #page-home .xhrr-home-poster .hero-cta { min-height: 24px; padding: 2px 8px; }
.bh-refined-theme .mobile-shell #page-home #home-user-card {
  margin: 7px 0 0;
  padding: 0;
  border: 0;
  background: transparent;
}
.bh-refined-theme .mobile-shell:has(.header-actions [data-action="open-login"]) #page-home #home-user-card,
.bh-refined-theme .mobile-shell #page-home:has(.bh-broadcast) .xhrr-home-poster .announcement { display: none; }
.bh-refined-theme .mobile-shell #page-home #home-user-card :is(.wallet-row,.wallet-balance,.balance-caption) {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
}
.bh-refined-theme .mobile-shell #page-home #home-user-card .wallet-balance { width: 100%; }
.bh-refined-theme .mobile-shell #page-home #home-user-card .sample-tag { display: none; }
.bh-refined-theme .mobile-shell #page-home #home-user-card #balance-value {
  min-width: 0;
  margin: 0;
  font-size: 14px;
  line-height: 1.2;
}

/* One quick-action strip combines wallet controls and configured shortcuts.
   Less frequent shortcuts are still available by swiping or keyboard focus. */
.bh-refined-theme .mobile-shell #page-home .xhrr-home-actions {
  display: flex;
  gap: 3px;
  align-items: start;
  max-width: 100%;
  margin: 5px 0 9px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scroll-snap-type: x proximity;
  scrollbar-width: none;
}
.bh-refined-theme .mobile-shell #page-home .xhrr-home-actions .wallet-actions,
.bh-refined-theme .mobile-shell #page-home .xhrr-home-actions #home-shortcuts:not([hidden]) { display: contents; }
.bh-refined-theme .mobile-shell #page-home .xhrr-home-actions :is(.wallet-actions, #home-shortcuts) > button {
  box-sizing: border-box;
  display: flex;
  flex: 0 0 calc((100% - 12px) / 5);
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 5px;
  height: auto;
  min-height: 62px;
  min-width: 0;
  margin: 0;
  padding: 2px 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  color: #f4eef8;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.4;
  scroll-snap-align: start;
}
.bh-refined-theme .mobile-shell #page-home .xhrr-home-actions #home-shortcuts > [data-nav] { order: 1; }
.bh-refined-theme .mobile-shell #page-home .xhrr-home-actions #home-shortcuts > [data-action="agent-center"] { order: 2; }
.bh-refined-theme .mobile-shell #page-home .xhrr-home-actions #home-shortcuts > [data-action="my-vip"] { order: 3; }
.bh-refined-theme .mobile-shell #page-home .xhrr-home-actions #home-shortcuts > [data-action="service"] { order: 4; }
.bh-refined-theme body.bh-surface[data-variant="mobile"] .mobile-shell #page-home .xhrr-home-actions .wallet-actions button[data-action] [data-icon],
.bh-refined-theme .mobile-shell #page-home .xhrr-home-actions #home-shortcuts .bh-shortcut-icon,
.bh-refined-theme .mobile-shell #page-home .xhrr-home-actions #home-shortcuts :is([data-nav], [data-action="agent-center"]) .bh-shortcut-icon > [data-icon] {
  flex: 0 0 39px;
  width: 39px;
  height: 39px;
  padding: 0;
  border: 0;
  border-radius: 9px;
}
.bh-refined-theme .mobile-shell #page-home .xhrr-home-actions #home-shortcuts .bh-shortcut-icon { background: #18141c; }
.bh-refined-theme .mobile-shell #page-home .xhrr-home-actions #home-shortcuts .bh-shortcut-icon > .artwork { width: 100%; height: 100%; object-fit: contain; }

/* Categories form a single swipeable row in both the lobby and the homepage. */
.bh-refined-theme .mobile-shell #page-home #categories,
.bh-refined-theme .mobile-shell #page-game #bh-lobby-categories {
  box-sizing: border-box;
  display: flex;
  flex-flow: row nowrap;
  align-items: center;
  gap: 2px;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  margin: 0;
  padding: 3px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scroll-snap-type: x proximity;
  scrollbar-width: none;
  border: 1px solid #413a45;
  border-radius: 30px;
  background: #171519;
  box-shadow: none;
}
.bh-refined-theme body.bh-surface[data-variant="mobile"] .mobile-shell #page-home #categories .category,
.bh-refined-theme .mobile-shell #page-game #bh-lobby-categories > button {
  display: flex;
  flex: 0 0 auto;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: auto;
  min-height: 32px;
  height: 32px;
  padding: 4px 10px;
  border: 0;
  border-radius: 20px;
  background: transparent;
  color: #eae3ee;
  font-size: 12px;
  line-height: 1;
  white-space: nowrap;
  scroll-snap-align: center;
}
.bh-refined-theme body.bh-surface[data-variant="mobile"] .mobile-shell #page-home #categories .category-all:not([aria-pressed="false"]),
.bh-refined-theme .mobile-shell #page-game #bh-lobby-categories > button.is-active { background: #4d355e; color: #fff; }
.bh-refined-theme body.bh-surface[data-variant="mobile"] .mobile-shell #page-home #categories .category-art,
.bh-refined-theme .mobile-shell #page-game #bh-lobby-categories > button > .category-mini-art {
  display: block;
  flex: 0 0 auto;
  width: 19px;
  height: 19px;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
}
.bh-refined-theme .mobile-shell #page-game .category-mini-art img { width: 100%; height: 100%; object-fit: contain; }
.bh-refined-theme body.bh-surface[data-variant="mobile"] .mobile-shell #page-home #categories .category:not(:has(.category-label)) .category-art { width: 57px; height: 28px; }
.bh-refined-theme .mobile-shell #page-game #bh-lobby-categories .sidebar-title { display: none; }
.bh-refined-theme .mobile-shell #page-home :is(.games-section, .activities-section) { margin: 14px 0 19px; padding: 0; }
.bh-refined-theme .mobile-shell #page-home #activity-grid {
  container-type: inline-size;
  row-gap: 8px;
}
.bh-refined-theme .mobile-shell #page-home #activity-grid > .activity-card--image {
  width: 100%;
  justify-self: stretch;
}
.bh-refined-theme .mobile-shell #page-home #activity-grid .activity-art > .artwork {
  max-height: 53cqw;
  object-fit: cover;
  object-position: center 55%;
}
.bh-refined-theme .mobile-shell #page-home .section-heading {
  min-height: 30px;
  margin: 0 0 7px;
  padding: 0;
  border: 0;
}
.bh-refined-theme .mobile-shell #page-home .section-heading::after,
.bh-refined-theme .mobile-shell #page-home .section-heading .section-eyebrow,
.bh-refined-theme .mobile-shell #page-game .portal-heading::after { display: none; }
.bh-refined-theme .mobile-shell #page-home .section-heading h2 { margin: 0; font-size: 18px; line-height: 1.35; }
.bh-refined-theme .mobile-shell #page-home .section-heading .text-button { min-height: 30px; color: #c9bacf; font-size: 12px; }

/* A full-width, single-column lobby keeps controls above the game grid. */
.bh-refined-theme .mobile-shell #page-game .portal-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 39px;
  margin: 0 0 8px;
  padding: 0;
  border: 0;
}
.bh-refined-theme .mobile-shell #page-game .portal-heading h1 { font-size: 20px; line-height: 1.25; }
.bh-refined-theme .mobile-shell #page-game .portal-heading .english-label { display: none; }
.bh-refined-theme .mobile-shell #page-game .lobby-layout,
.bh-refined-theme .mobile-shell #page-game .lobby-main {
  display: flex;
  flex-direction: column;
  gap: 9px;
  width: 100%;
  min-width: 0;
  max-width: 100%;
}
.bh-refined-theme .mobile-shell #page-game .lobby-layout { align-items: stretch; }
.bh-refined-theme .mobile-shell #page-game .lobby-main > * { min-width: 0; max-width: 100%; }
.bh-refined-theme .mobile-shell #page-game #bh-search {
  position: static;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: stretch;
  gap: 6px;
  width: 100%;
  margin: 0;
  padding: 0;
}
.bh-refined-theme .mobile-shell #page-game #bh-search .search-field {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  min-height: 36px;
  margin: 0;
  padding: 0 12px;
  border: 1px solid #3a343d;
  border-radius: 22px;
  background: #1a171d;
}
.bh-refined-theme .mobile-shell #page-game #bh-search .search-field > [data-icon] { flex: 0 0 15px; width: 15px; height: 15px; }
.bh-refined-theme .mobile-shell #page-game #bh-keyword { width: 100%; min-width: 0; height: 34px; min-height: 0; padding: 0; border: 0; font-size: 16px; }
.bh-refined-theme .mobile-shell #page-game #bh-search button { min-height: 36px; margin: 0; padding: 0 16px; border-radius: 22px; color: #fff; background: var(--portal-action); }
.bh-refined-theme .mobile-shell #page-game .library-toolbar {
  position: static;
  display: flex;
  flex-flow: row nowrap;
  justify-content: space-between;
  align-items: center;
  gap: 4px;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
}
.bh-refined-theme .mobile-shell #page-game .library-toolbar .pill-tabs {
  display: flex;
  gap: 3px;
  min-width: 0;
  margin: 0;
  padding: 2px;
  border: 0;
  border-radius: 20px;
  background: #19161e;
}
.bh-refined-theme .mobile-shell #page-game .library-toolbar .pill-tabs button {
  width: auto;
  min-height: 28px;
  padding: 0 9px;
  border: 0;
  border-radius: 16px;
  font-size: 12px;
  white-space: nowrap;
}
.bh-refined-theme .mobile-shell #page-game .library-toolbar .pill-tabs .is-active { background: #443250; color: white; }
.bh-refined-theme .mobile-shell #page-game #bh-game-count { flex: 0 0 auto; color: #c0b5c7; font-size: 11px; }
.bh-refined-theme .mobile-shell #page-game :is(#bh-game-notice,#bh-provider-result-heading,#bh-platform-notice):empty,
.bh-refined-theme .mobile-shell #page-game .bh-center-actions:not(:has(button:not([hidden]))) { display: none; }
.bh-refined-theme .mobile-shell #page-game .bh-provider-section { margin: 0; padding: 6px 0 3px; }
.bh-refined-theme .mobile-shell #page-game #bh-game-platforms { overflow-x: auto; scrollbar-width: none; }

/* Homepage recommendations scroll like the XHRR cover rail. The lobby uses a
   wraparound grid. Favorite controls sit beside the name, below the artwork. */
.bh-refined-theme .mobile-shell #page-home #game-grid {
  display: grid;
  grid-auto-flow: column;
  grid-template-columns: none;
  grid-auto-columns: clamp(108px, 34%, 146px);
  align-items: start;
  gap: 8px;
  padding: 1px 0 4px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scroll-snap-type: x proximity;
  scrollbar-width: none;
}
.bh-refined-theme .mobile-shell #page-game #bh-game-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px 8px;
}
.bh-refined-theme .mobile-shell #page-home #game-grid:has(> .bh-status) { grid-auto-columns: 100%; }
.bh-refined-theme .mobile-shell #page-game #bh-game-list > .bh-status { grid-column: 1 / -1; }
.bh-refined-theme .mobile-shell :is(#game-grid, #bh-game-list, #bh-account-favorites) .bh-game-wrap {
  position: relative;
  min-width: 0;
  scroll-snap-align: start;
}
.bh-refined-theme .mobile-shell :is(#game-grid, #bh-game-list, #bh-account-favorites) .game-card {
  display: block;
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 12px;
  background: #211a27;
  box-shadow: none;
}
.bh-refined-theme .mobile-shell :is(#game-grid, #bh-game-list, #bh-account-favorites) .game-card .game-art {
  position: relative;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  overflow: hidden;
  border: 0;
  border-radius: 12px 12px 0 0;
  background: #1e1a22;
}
.bh-refined-theme .mobile-shell :is(#game-grid, #bh-game-list, #bh-account-favorites) .game-card .artwork { object-fit: cover; transform: none; }
.bh-refined-theme .mobile-shell :is(#game-grid, #bh-game-list, #bh-account-favorites) .game-card .game-meta {
  position: static;
  display: flex;
  align-items: center;
  box-sizing: border-box;
  height: 30px;
  min-width: 0;
  padding: 0 29px;
  background: #211a27;
}
.bh-refined-theme .mobile-shell :is(#game-grid, #bh-game-list, #bh-account-favorites) .game-card .game-meta h3 {
  flex: 1;
  min-width: 0;
  margin: 0;
  overflow: hidden;
  color: #fff;
  font-size: 12px;
  line-height: 1.4;
  text-align: center;
  text-overflow: ellipsis;
  text-shadow: none;
  white-space: nowrap;
}
.bh-refined-theme .mobile-shell :is(#game-grid, #bh-game-list, #bh-account-favorites) .bh-game-wrap > .favorite-button {
  position: absolute;
  inset: auto 0 0 auto;
  display: grid;
  place-items: center;
  width: 29px;
  height: 30px;
  min-width: 0;
  min-height: 0;
  padding: 0;
  border: 0;
  border-radius: 7px;
  background: transparent;
  box-shadow: none;
}
.bh-refined-theme .mobile-shell :is(#game-grid, #bh-game-list, #bh-account-favorites) .favorite-button::after { display: none; }
.bh-refined-theme .mobile-shell :is(#game-grid, #bh-game-list, #bh-account-favorites) .favorite-button [data-icon] {
  width: 15px;
  height: 15px;
  opacity: .8;
  filter: grayscale(1) brightness(1.5);
}
.bh-refined-theme .mobile-shell :is(#game-grid, #bh-game-list, #bh-account-favorites) .favorite-button.is-saved { background: #493550; }
.bh-refined-theme .mobile-shell :is(#game-grid, #bh-game-list, #bh-account-favorites) .favorite-button.is-saved [data-icon] {
  opacity: 1;
  filter: brightness(0) saturate(100%) invert(81%) sepia(26%) saturate(1292%) hue-rotate(213deg);
}
.bh-refined-theme .mobile-shell :is(.xhrr-home-actions,#categories,#game-grid,#bh-lobby-categories,#bh-game-platforms)::-webkit-scrollbar { display: none; }
.bh-refined-theme body.bh-surface[data-variant="mobile"] .mobile-shell .bottom-nav a.is-active[aria-current="page"] { border-radius: 26px; background: #4a3659; }
.bh-refined-theme body.bh-surface[data-variant="mobile"]:has(#platformFloatingBack) .mobile-shell .site-header {
  position: sticky;
  z-index: 8;
  top: 0;
}
.bh-refined-theme body.bh-surface[data-variant="mobile"]:has(#platformFloatingBack) .mobile-shell:has(#page-home[hidden]) .site-header {
  padding-left: calc(40px + env(safe-area-inset-left, 0px));
}
.bh-refined-theme body.bh-surface[data-variant="mobile"] #platformFloatingBack {
  position: fixed;
  inset: calc(12px + env(safe-area-inset-top, 0px)) auto auto max(4px, calc((100vw - 480px) / 2 + 4px));
  width: 34px;
  height: 34px;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  color: #ccbdd5;
  font-size: 15px;
}
@media (max-width: 359px) {
  .bh-refined-theme .mobile-shell .site-header .header-actions .bh-profile button { padding-inline: 11px; }
  .bh-refined-theme .mobile-shell #page-home .xhrr-home-actions :is(.wallet-actions, #home-shortcuts) > button { flex-basis: calc((100% - 9px) / 4); }
  .bh-refined-theme .mobile-shell #page-game #bh-game-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
