@font-face {
  font-family: "GenJyuu";
  src: url("/qmoney/assets/_nuxt/GenJyuuGothic-Medium.Cl6Lix6y.woff2") format("woff2");
  font-display: swap;
  font-weight: 500;
}

@font-face {
  font-family: "GenJyuu";
  src: url("/qmoney/assets/_nuxt/GenJyuuGothic-Bold.BbP864ab.woff2") format("woff2");
  font-display: swap;
  font-weight: 800;
}

:root {
  color: #1a467c;
  font-family: "GenJyuu", "Noto Sans TC", system-ui, sans-serif;
  font-synthesis: none;
  --blue: #1a467c;
  --blue-soft: #437abf;
  --cyan: #00c8ee;
  --pink: #ff639d;
  --pink-deep: #c91861;
  --cream: #fffaf0;
  --brown: #452201;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  height: 100%;
  min-height: 100%;
  margin: 0;
  overscroll-behavior: none;
}

body {
  min-height: 100svh;
  min-height: 100dvh;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 10%, rgba(255, 118, 173, 0.35), transparent 34%),
    linear-gradient(145deg, #12293f, #f6b2d0 55%, #79dfff);
}

button,
input {
  font: inherit;
  touch-action: manipulation;
}

button {
  margin: 0;
  padding: 0;
  color: inherit;
  border: 0;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
input:focus-visible {
  outline: 3px solid rgba(0, 200, 238, 0.72);
  outline-offset: 2px;
}

img {
  display: block;
  max-width: 100%;
}

[hidden] {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.app-frame {
  position: relative;
  width: min(100vw, 460px);
  height: 100svh;
  height: 100dvh;
  min-height: 0;
  margin: 0 auto;
  overflow: hidden;
  background: #dff3ff;
  isolation: isolate;
  box-shadow: 0 0 70px rgba(0, 0, 0, 0.38);
}

.view {
  position: absolute;
  inset: 0;
  display: none;
}

.view.is-active {
  display: block;
}

/* Keep the login artwork out of the first paint while the persisted session is
   restored. Authenticated players now see a neutral lobby hand-off instead of
   a one-frame login page when returning from a game. */
.qmoney-boot-view {
  position: absolute;
  z-index: 1000;
  inset: 0;
  display: none;
  place-items: center;
  align-content: center;
  gap: 8px;
  background: #dff3ff;
  color: #ff5796;
  font-size: 14px;
  font-weight: 800;
}

.qmoney-boot-view img {
  width: 92px;
  height: 92px;
  object-fit: contain;
}

body.is-booting .qmoney-boot-view {
  display: grid;
}

body.is-booting .view {
  display: none !important;
}

/* Login page */
.login-page {
  overflow: hidden;
  background: #fff1f6 url("/qmoney/assets/brand/jin-baobao-login.webp") center top / cover no-repeat;
}

.login-page::after {
  position: absolute;
  inset: 0;
  content: "";
  pointer-events: none;
  background: linear-gradient(180deg, transparent 60%, rgba(255, 255, 255, 0.42));
}

.login-actions {
  position: absolute;
  z-index: 2;
  top: 42%;
  left: 50%;
  display: grid;
  width: min(78%, 320px);
  gap: 14px;
  transform: translate(-50%, -50%);
}

.pill-button {
  height: 54px;
  padding: 4px;
  border-radius: 999px;
  background: linear-gradient(180deg, #fff, #dfeaf5);
  box-shadow: 0 9px 18px rgba(69, 34, 1, 0.24), inset 0 1px 1px #fff;
  transition: transform 140ms ease;
}

.pill-button:active {
  transform: scale(0.97);
}

.pill-button span {
  display: flex;
  height: 100%;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: inherit;
  color: #fff8e4;
  font-size: 18px;
  font-weight: 800;
  text-shadow: 1px 1px rgba(69, 34, 1, 0.48);
}

.pill-button--web span {
  background: linear-gradient(180deg, #ff8fb7, #f44586);
}

.login-page-footer {
  position: absolute;
  z-index: 1;
  right: 0;
  bottom: 0;
  left: 0;
  height: 34%;
}

.footer-art {
  position: absolute;
  bottom: -1%;
  width: 57%;
}

.footer-art--left {
  left: -5%;
}

.footer-art--right {
  right: -5%;
}

/* Authenticated lobby */
.lobby {
  background: #dff3ff;
}

.lobby-scroll {
  position: absolute;
  inset: 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior-y: contain;
  scrollbar-width: thin;
  scrollbar-color: rgba(26, 70, 124, 0.42) transparent;
  -webkit-overflow-scrolling: touch;
}

.lobby-header {
  position: absolute;
  z-index: 30;
  top: 0;
  right: 0;
  left: 0;
  display: flex;
  height: 72px;
  align-items: center;
  gap: 7px;
  padding: 8px 10px 8px 12px;
  color: #fff8e4;
  background:
    linear-gradient(180deg, rgba(62, 27, 2, 0.88), rgba(18, 15, 13, 0.84)),
    url("/qmoney/assets/imgs_soc/media/header-bg.webp") center bottom / auto 100% no-repeat;
  box-shadow: 0 6px 16px rgba(23, 14, 7, 0.22);
  text-shadow: 1px 1px 0 rgba(69, 34, 1, 0.72);
}

.profile-button {
  flex: 0 0 54px;
  width: 54px;
  height: 54px;
  padding: 3px;
  overflow: hidden;
  border-radius: 50%;
  background: linear-gradient(145deg, #59e3ff, #009dc7);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.28);
  cursor: default;
}

.profile-button img {
  width: 100%;
  height: 100%;
  border: 2px solid #fff8e4;
  border-radius: 50%;
  object-fit: cover;
}

.member-summary {
  min-width: 0;
  flex: 0 1 108px;
  text-align: left;
}

.member-summary > strong {
  display: block;
  overflow: hidden;
  color: #fff8e4;
  font-size: 13px;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.member-status {
  display: flex;
  width: fit-content;
  height: 22px;
  align-items: center;
  margin-top: 3px;
  padding: 0 9px;
  color: #1a467c;
  border-radius: 12px;
  background: #fffaf0;
  font-size: 12px;
  font-weight: 800;
  text-shadow: none;
}

.balance-row {
  display: flex;
  min-width: 154px;
  max-width: 184px;
  height: 38px;
  flex: 1 1 166px;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  padding: 2px 8px 2px 2px;
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(91, 49, 19, 0.78), rgba(35, 23, 16, 0.82));
  box-shadow: inset 1px 2px 4px rgba(0, 0, 0, 0.42), 0 1px rgba(255, 255, 255, 0.3);
}

.balance-row > img:first-child {
  width: 30px;
  height: 30px;
  margin-left: 1px;
  object-fit: contain;
}

.balance-row strong {
  min-width: 0;
  flex: 1 1 auto;
  color: #fff8e4;
  font-size: clamp(13px, 3.7vw, 16px);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.03em;
  text-align: right;
  white-space: nowrap;
}

.balance-row .refresh-icon {
  width: 18px;
  height: 18px;
  filter: brightness(0) invert(1);
}

.balance-row.is-loading .refresh-icon {
  animation: spin 600ms linear infinite;
}

.header-settings {
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  padding: 2px;
}

.header-settings img {
  width: 100%;
  height: 100%;
  filter: brightness(0) invert(1);
}

.hero-carousel {
  position: relative;
  height: 256px;
  overflow: hidden;
  background: #2c1721;
}

.hero-track,
.hero-slide {
  position: absolute;
  inset: 0;
}

.hero-slide {
  overflow: hidden;
  text-align: left;
  opacity: 0;
  transition: opacity 520ms ease, transform 4.8s linear;
  transform: scale(1.035);
}

.hero-slide.is-active {
  z-index: 1;
  opacity: 1;
  transform: scale(1);
}

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-slide::after {
  position: absolute;
  inset: 24% 0 0;
  content: "";
  background: linear-gradient(transparent, rgba(4, 16, 37, 0.9));
}

.hero-slide-copy {
  position: absolute;
  z-index: 2;
  right: 18px;
  bottom: 38px;
  left: 18px;
  display: grid;
  color: #fff;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
}

.hero-slide-copy small {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  opacity: 0.86;
}

.hero-slide-copy strong {
  max-width: calc(100% - 92px);
  margin-top: 2px;
  overflow: hidden;
  font-size: 22px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hero-slide-copy em {
  position: absolute;
  right: 0;
  bottom: 1px;
  padding: 5px 12px;
  color: #fff;
  border-radius: 16px;
  background: linear-gradient(180deg, #ff83b3, #ee3d80);
  box-shadow: 0 5px 12px rgba(0, 0, 0, 0.25);
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
  text-shadow: none;
}

.carousel-dots {
  position: absolute;
  z-index: 3;
  right: 12px;
  bottom: 31px;
  display: flex;
  gap: 5px;
}

.carousel-dots button {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.54);
}

.carousel-dots button.is-active {
  width: 16px;
  border-radius: 6px;
  background: #ff72aa;
}

.announcement-ticker {
  position: relative;
  z-index: 5;
  display: flex;
  width: calc(100% - 24px);
  height: 31px;
  align-items: center;
  gap: 8px;
  margin: -31px 12px 0;
  padding: 0 10px;
  overflow: hidden;
  color: #fff8e4;
  border-radius: 4px 4px 0 0;
  background: rgba(5, 5, 5, 0.72);
  font-size: 12px;
  text-align: left;
  text-shadow: 1px 1px #452201;
}

.ticker-speaker {
  flex: 0 0 auto;
  font-size: 18px;
}

.ticker-window {
  min-width: 0;
  flex: 1;
  overflow: hidden;
  white-space: nowrap;
}

.ticker-window > span {
  display: inline-block;
  min-width: 100%;
  padding-left: 100%;
  animation: ticker 20s linear infinite;
}

.category-tabs {
  position: sticky;
  z-index: 24;
  top: 76px;
  display: flex;
  width: calc(100% - 36px);
  height: 50px;
  align-items: center;
  gap: 1px;
  margin: 0 18px 10px;
  padding: 5px 8px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 10px 14px rgba(69, 34, 1, 0.2), inset 0 1px #fff;
  backdrop-filter: blur(8px);
}

.category-tab {
  height: 40px;
  flex: 1 1 auto;
  padding: 0 4px;
  color: #1a467c;
  border-radius: 22px;
  font-size: clamp(11px, 3.3vw, 15px);
  font-weight: 800;
  white-space: nowrap;
  text-shadow: 1px 1px #fff;
}

.category-tab.is-active {
  color: #fff8e4;
  background: linear-gradient(180deg, #00d8f6, #00a5ca);
  box-shadow: 0 7px 13px rgba(0, 196, 234, 0.35), inset 0 2px rgba(255, 255, 255, 0.5);
  text-shadow: 1px 1px rgba(69, 34, 1, 0.44);
}

.category-search {
  width: 32px;
  height: 40px;
  flex: 0 0 32px;
  color: #1a467c;
  font-family: system-ui, sans-serif;
  font-size: 32px;
  font-weight: 900;
  line-height: 1;
  transform: rotate(-18deg);
}

.game-search {
  position: sticky;
  z-index: 23;
  top: 132px;
  display: flex;
  width: calc(100% - 44px);
  height: 44px;
  align-items: center;
  gap: 6px;
  margin: 0 22px 10px;
  padding: 4px 7px 4px 16px;
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 8px 16px rgba(69, 34, 1, 0.18);
}

.game-search input {
  min-width: 0;
  height: 100%;
  flex: 1;
  color: #1a467c;
  border: 0;
  outline: 0;
  background: transparent;
  font-size: 16px;
}

.game-search button {
  width: 34px;
  height: 34px;
  color: #7c4d24;
  border-radius: 50%;
  background: #f1f4f8;
  font-size: 22px;
}

.games-section {
  padding: 0 24px;
}

.section-heading {
  display: flex;
  height: 31px;
  align-items: center;
  justify-content: space-between;
  padding: 0 4px;
}

.section-heading h1 {
  margin: 0;
  color: #1a467c;
  font-size: 16px;
  font-weight: 800;
}

.section-heading span {
  color: #437abf;
  font-size: 11px;
}

.game-grid {
  display: grid;
  grid-auto-rows: minmax(104px, auto);
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.game-card {
  position: relative;
  min-width: 0;
  aspect-ratio: 1;
  animation: game-enter 340ms ease both;
  content-visibility: auto;
  contain-intrinsic-size: 110px;
}

.game-card.is-featured {
  grid-row: span 2;
  grid-column: span 2;
  aspect-ratio: auto;
}

.game-launch {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: 20px;
  background: linear-gradient(145deg, #5aaef2, #7e44b4);
  box-shadow: 0 5px 10px rgba(69, 34, 1, 0.18);
  transition: transform 130ms ease, filter 130ms ease;
}

.game-launch:active {
  filter: brightness(0.9);
  transform: scale(0.97);
}

.game-card-image,
.game-card-image img {
  width: 100%;
  height: 100%;
}

.game-card-image img {
  object-fit: cover;
}

.game-card-image::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 34%;
  content: "";
  pointer-events: none;
  background: linear-gradient(transparent, rgba(8, 25, 53, 0.72));
}

.game-card-image.is-missing-cover {
  background: linear-gradient(145deg, #51b8dc, #9247b7);
}

.game-badge {
  position: absolute;
  z-index: 2;
  top: 7px;
  left: -2px;
  padding: 2px 7px 3px 5px;
  color: #fff;
  border-radius: 0 12px 12px 0;
  background: linear-gradient(180deg, #ff3d2f, #d60000);
  font-size: 10px;
  font-weight: 800;
  text-shadow: 1px 1px rgba(69, 34, 1, 0.52);
}

.game-card-copy {
  position: absolute;
  z-index: 2;
  right: 7px;
  bottom: 6px;
  left: 7px;
  color: #fff;
  text-align: left;
  text-shadow: 1px 1px 2px #0b1b32;
}

.game-card-title {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.game-card-title {
  font-size: clamp(10px, 3.1vw, 14px);
  font-weight: 800;
}

.game-card.is-featured .game-card-title {
  font-size: 18px;
}

.empty-state {
  margin: 24px 0;
  padding: 24px;
  color: #437abf;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
  font-size: 13px;
  text-align: center;
  box-shadow: inset 0 0 0 1px rgba(67, 122, 191, 0.1);
}

.lobby-safe-space {
  height: calc(env(safe-area-inset-bottom) + 36px);
}

.side-tools {
  position: absolute;
  z-index: 27;
  right: 6px;
  bottom: calc(env(safe-area-inset-bottom) + 18px);
  display: grid;
  gap: 5px;
}

.side-tools button {
  display: grid;
  width: 54px;
  min-height: 54px;
  place-items: center;
  padding: 5px 3px;
  color: #1a467c;
  border-radius: 50%;
  background: linear-gradient(180deg, #fff, #e4edf6);
  box-shadow: 0 7px 14px rgba(69, 34, 1, 0.2);
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
}

.side-tools .scroll-top {
  min-height: 36px;
  height: 36px;
  border-radius: 13px;
  color: #995400;
  font-family: system-ui, sans-serif;
  font-size: 30px;
  line-height: 1;
}

/* Modal system shared by login and exact source-style lobby popups */
.modal-backdrop {
  position: absolute;
  z-index: 100;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 34px 18px 52px;
  background: rgba(255, 255, 255, 0.38);
  backdrop-filter: blur(9px);
  animation: backdrop-in 180ms ease both;
}

.modal-card {
  position: relative;
  width: min(100%, 370px);
  max-height: min(760px, 86svh);
  padding: 28px 22px 24px;
  color: #1a467c;
  border: 5px solid transparent;
  border-radius: 27px;
  background:
    linear-gradient(#fffaf0, #fffaf0) padding-box,
    linear-gradient(180deg, #18cdf5, #ff63aa) border-box;
  box-shadow: 0 20px 46px rgba(69, 34, 1, 0.28);
  animation: modal-enter 240ms cubic-bezier(0.2, 0.86, 0.32, 1.12) both;
}

.modal-content {
  max-height: calc(min(760px, 86svh) - 58px);
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
}

.modal-close {
  position: absolute;
  z-index: 8;
  top: 10px;
  right: 10px;
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  color: #8b4a05;
  border-radius: 50%;
  background: linear-gradient(180deg, #fff, #e7edf3);
  box-shadow: 0 4px 9px rgba(69, 34, 1, 0.18);
  font-family: system-ui, sans-serif;
  font-size: 26px;
  font-weight: 700;
  line-height: 1;
}

.modal-card.source-popup {
  width: min(calc(100% + 2px), 396px);
  height: min(760px, 84svh);
  max-height: none;
  padding: 74px 25px 48px;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: url("/qmoney/assets/imgs_soc/media/lobbypopframebg.webp") center / 100% 100% no-repeat;
  box-shadow: none;
}

.modal-card.source-popup .modal-content {
  height: 100%;
  max-height: none;
  overflow: hidden;
}

.modal-card.source-popup .modal-close {
  top: auto;
  right: 50%;
  bottom: -28px;
  width: 58px;
  height: 58px;
  color: #9a5100;
  border: 1px solid rgba(69, 34, 1, 0.05);
  background: #fff;
  box-shadow: 0 9px 18px rgba(69, 34, 1, 0.25);
  font-size: 38px;
  transform: translateX(50%);
}

.source-popup-ribbon {
  position: absolute;
  z-index: 3;
  top: -12px;
  left: 50%;
  display: flex;
  width: calc(100% - 28px);
  height: 78px;
  align-items: center;
  justify-content: center;
  padding: 4px 34px 19px;
  color: #fff8e4;
  background: url("/qmoney/assets/imgs_soc/media/lobbypopbg.webp") center / 100% 100% no-repeat;
  font-size: 19px;
  font-weight: 800;
  text-shadow: 1px 2px 0 rgba(69, 34, 1, 0.72);
  transform: translateX(-50%);
}

.ribbon-tabs {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-around;
  gap: 3px;
}

.ribbon-tabs button {
  position: relative;
  min-width: 0;
  height: 39px;
  flex: 1;
  padding: 0 5px;
  color: #fff8e4;
  border-radius: 21px;
  font-size: clamp(14px, 4.3vw, 18px);
  font-weight: 800;
  text-shadow: 1px 2px 0 rgba(69, 34, 1, 0.72);
}

.ribbon-tabs button + button::before {
  position: absolute;
  top: 8px;
  bottom: 8px;
  left: -3px;
  width: 1px;
  content: "";
  background: rgba(255, 248, 228, 0.56);
}

.ribbon-tabs button.is-active {
  background: linear-gradient(180deg, rgba(174, 31, 83, 0.7), rgba(210, 60, 104, 0.82));
  box-shadow: inset 0 2px 5px rgba(112, 16, 46, 0.2);
}

.source-popup-body {
  height: 100%;
  padding: 0 4px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: none;
}

.source-popup-body::-webkit-scrollbar {
  display: none;
}

.modal-icon {
  width: 72px;
  height: 72px;
  margin: 0 auto 8px;
  object-fit: contain;
}

.modal-title {
  margin: 0 36px 8px;
  color: #1a467c;
  font-size: 23px;
  text-align: center;
}

.modal-subtitle {
  margin: 0 0 16px;
  color: #437abf;
  font-size: 13px;
  line-height: 1.65;
  text-align: center;
}

.real-login-form {
  display: grid;
  gap: 12px;
}

.real-login-form label {
  display: grid;
  gap: 5px;
  color: #1a467c;
  font-size: 12px;
  font-weight: 800;
}

.real-login-form input {
  width: 100%;
  height: 44px;
  padding: 0 13px;
  color: #1a467c;
  border: 1px solid rgba(67, 122, 191, 0.28);
  border-radius: 12px;
  outline: 0;
  background: #f4f8fc;
  box-shadow: inset 0 2px 4px rgba(69, 34, 1, 0.08);
  font-size: 16px;
}

.captcha-row {
  display: grid;
  grid-template-columns: 1fr 92px;
  gap: 8px;
}

.captcha-row button {
  color: #fff;
  border-radius: 12px;
  background: linear-gradient(180deg, #00cfee, #009bbf);
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 4px;
  text-shadow: 1px 1px rgba(69, 34, 1, 0.42);
}

.form-error {
  margin: 0;
  color: #d32654;
  font-size: 12px;
  text-align: center;
}

.modal-button {
  width: 100%;
  height: 48px;
  margin-top: 4px;
  padding: 4px;
  border-radius: 25px;
  background: linear-gradient(180deg, #fff, #dee9f4);
  box-shadow: 0 8px 16px rgba(69, 34, 1, 0.2);
}

.modal-button span {
  display: flex;
  height: 100%;
  align-items: center;
  justify-content: center;
  color: #fff8e4;
  border-radius: inherit;
  background: linear-gradient(180deg, #00d3f1, #00a2c7);
  font-weight: 800;
  text-shadow: 1px 1px rgba(69, 34, 1, 0.45);
}

.modal-button--pink span {
  background: linear-gradient(180deg, #ff86b4, #ee3c80);
}

.modal-button:disabled {
  cursor: wait;
  filter: grayscale(0.7);
  opacity: 0.66;
}

/* Announcement popup */
.notice-kinds {
  display: flex;
  height: 73px;
  align-items: flex-end;
  justify-content: space-around;
  margin-bottom: 9px;
  padding: 0 4px;
}

.notice-kinds button {
  display: grid;
  min-width: 0;
  flex: 1;
  place-items: center;
  gap: 2px;
  color: #1a467c;
  font-size: 11px;
  font-weight: 800;
}

.notice-kinds img {
  width: 36px;
  height: 36px;
  object-fit: contain;
  transition: transform 140ms ease;
}

.notice-kinds button.is-active img {
  transform: translateY(-4px) scale(1.08);
}

.notice-kinds button.is-active span {
  padding: 4px 8px;
  color: #fff;
  border-radius: 13px;
  background: linear-gradient(180deg, #00d4ef, #00a2c5);
}

.notice-list {
  display: grid;
  gap: 7px;
  padding: 6px 2px 28px;
}

.notice-item {
  display: grid;
  min-height: 69px;
  grid-template-columns: 47px 1fr 22px;
  align-items: center;
  gap: 6px;
  padding: 8px 11px;
  border-radius: 13px;
  background: linear-gradient(180deg, #fff, #dee9f4);
  box-shadow: 0 5px 10px rgba(69, 34, 1, 0.16), inset 0 1px #fff;
  text-align: left;
}

.notice-item > img {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.notice-item-copy {
  min-width: 0;
}

.notice-item-copy strong,
.notice-item-copy time {
  display: block;
}

.notice-item-copy strong {
  color: #1a467c;
  font-size: 15px;
  line-height: 1.2;
}

.notice-item-copy time {
  margin-top: 4px;
  color: #5882af;
  font-size: 12px;
}

.notice-arrow {
  color: #1a467c;
  font-family: system-ui, sans-serif;
  font-size: 30px;
  font-weight: 600;
}

.notice-detail {
  padding: 16px 10px 32px;
  color: #1a467c;
  font-size: 14px;
  line-height: 1.9;
}

.notice-detail h3 {
  margin: 0 0 10px;
  font-size: 20px;
}

.notice-detail time {
  color: #5882af;
}

.notice-detail p {
  white-space: pre-wrap;
}

.back-pill {
  display: inline-flex;
  height: 36px;
  align-items: center;
  margin-bottom: 12px;
  padding: 0 16px;
  color: #1a467c;
  border-radius: 18px;
  background: linear-gradient(180deg, #fff, #dee9f4);
  box-shadow: 0 4px 8px rgba(69, 34, 1, 0.14);
  font-weight: 800;
}

/* Settings popup */
.settings-list {
  padding: 16px 14px 10px;
}

.setting-row {
  display: grid;
  width: 100%;
  min-height: 60px;
  grid-template-columns: 1fr auto;
  align-items: center;
  border-bottom: 1px solid rgba(139, 104, 54, 0.2);
  color: #1a467c;
  font-size: 16px;
  font-weight: 800;
  text-align: left;
}

.setting-row--button::after {
  content: "›";
  grid-column: 3;
  justify-self: end;
  color: #ff9500;
  font-family: system-ui, sans-serif;
  font-size: 35px;
  font-weight: 700;
  line-height: 1;
}

.setting-row--button {
  grid-template-columns: minmax(0, 1fr) auto 24px;
  column-gap: 8px;
}

.setting-row--button > span {
  min-width: 0;
}

.setting-row strong {
  grid-column: 2;
  color: #437abf;
  font-size: 13px;
  white-space: nowrap;
}

.audio-controls {
  display: flex;
  gap: 7px;
}

.audio-toggle {
  display: flex;
  width: 43px;
  height: 25px;
  align-items: center;
  padding: 3px;
  border-radius: 14px;
  background: #c7d3df;
  transition: background 140ms ease;
}

.audio-toggle::after {
  width: 19px;
  height: 19px;
  content: "";
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 5px rgba(69, 34, 1, 0.2);
  transition: transform 140ms ease;
}

.audio-toggle.is-on {
  background: #20c6e8;
}

.audio-toggle.is-on::after {
  transform: translateX(18px);
}

.settings-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 16px 8px;
}

.logout-pill {
  min-width: 78px;
  height: 38px;
  color: #1a467c;
  border-radius: 20px;
  background: linear-gradient(180deg, #fff, #dee9f4);
  box-shadow: 0 7px 13px rgba(69, 34, 1, 0.18);
  font-weight: 800;
}

.version-copy {
  color: #1a467c;
  font-size: 13px;
  font-weight: 800;
}

.text-page {
  padding: 5px 10px 24px;
  color: #1a467c;
  font-size: 13px;
  line-height: 1.8;
}

.text-page h3 {
  margin: 8px 0;
  font-size: 18px;
}

/* Personal center */
.personal-profile {
  display: grid;
  grid-template-columns: 91px 1fr;
  gap: 12px;
  padding: 8px 4px 12px;
}

.personal-avatar {
  width: 84px;
  height: 84px;
  padding: 4px;
  border-radius: 50%;
  background: #4380c8;
}

.personal-avatar img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}

.personal-name {
  min-width: 0;
}

.personal-name small,
.personal-name strong,
.personal-name span {
  display: block;
}

.personal-name small {
  margin-bottom: 2px;
  color: #437abf;
  font-size: 12px;
  font-weight: 800;
}

.personal-name strong {
  overflow: hidden;
  color: #1a467c;
  font-size: 21px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.personal-name span {
  overflow: hidden;
  color: #1a467c;
  font-size: 13px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.personal-mini-actions {
  display: flex;
  gap: 6px;
  margin-top: 7px;
}

.personal-mini-actions button {
  height: 32px;
  flex: 1;
  color: #1a467c;
  border-radius: 17px;
  background: linear-gradient(180deg, #fff, #dee9f4);
  box-shadow: 0 5px 9px rgba(69, 34, 1, 0.14);
  font-size: 11px;
  font-weight: 800;
}

.personal-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 14px;
}

.personal-actions button {
  height: 42px;
  color: #6b0830;
  border: 5px solid #ffd5e5;
  border-radius: 23px;
  background: linear-gradient(180deg, #ff85b4, #ff62a0);
  box-shadow: 0 9px 15px rgba(192, 40, 99, 0.2);
  font-size: 13px;
  font-weight: 800;
}

.personal-signature {
  position: relative;
  min-height: 58px;
  margin-bottom: 10px;
  padding: 10px 38px 10px 12px;
  border-radius: 10px;
  background: #d8e2ec;
  box-shadow: inset 0 2px 4px rgba(69, 34, 1, 0.12);
  font-size: 12px;
}

.personal-signature::after {
  position: absolute;
  right: 9px;
  bottom: 8px;
  content: "✎";
  font-size: 20px;
}

.vip-card {
  display: grid;
  min-height: 193px;
  grid-template-columns: 118px 1fr;
  gap: 4px;
  padding: 11px;
  border: 6px solid #fff;
  border-radius: 20px;
  background: linear-gradient(180deg, #ffc5da, #ff83b5);
  box-shadow: 0 8px 16px rgba(69, 34, 1, 0.18);
}

.vip-medal {
  text-align: center;
}

.vip-medal img {
  width: 105px;
  height: 105px;
  margin: -10px auto -5px;
  object-fit: contain;
}

.vip-medal strong {
  color: #6b0830;
  font-size: 16px;
}

.vip-info {
  display: grid;
  align-content: center;
}

.vip-info-row {
  display: grid;
  min-height: 43px;
  grid-template-columns: 72px 1fr;
  align-items: center;
  border-bottom: 1px solid rgba(138, 81, 22, 0.18);
  color: #6b0830;
  font-size: 12px;
  font-weight: 800;
}

.vip-info-row:last-child {
  border-bottom: 0;
}

.vip-info-row strong {
  overflow: hidden;
  font-size: 14px;
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.task-card {
  margin-top: 14px;
  padding: 15px;
  border-radius: 19px;
  background: linear-gradient(180deg, #fff, #e4edf6);
  box-shadow: 0 7px 14px rgba(69, 34, 1, 0.16);
}

.task-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  color: #1a467c;
  font-size: 18px;
  font-weight: 800;
}

.task-title > span {
  display: flex;
  align-items: center;
  gap: 8px;
}

.task-title img {
  width: 39px;
  height: 39px;
  object-fit: contain;
}

.task-state {
  padding: 4px 13px;
  color: #fff;
  border-radius: 16px;
  background: #f7a2c6;
  font-size: 11px;
}

.task-line {
  display: flex;
  justify-content: space-between;
  color: #437abf;
  font-size: 13px;
  font-weight: 800;
}

.progress-bar {
  height: 11px;
  margin: 10px 0 13px;
  padding: 2px;
  border-radius: 6px;
  background: #ceddec;
  box-shadow: inset 0 1px 3px rgba(69, 34, 1, 0.14);
}

.progress-fill {
  height: 100%;
  border-radius: 4px;
  background: linear-gradient(90deg, #00d1ef, #ff70aa);
  transition: width 300ms ease;
}

.placeholder-panel {
  display: grid;
  min-height: 310px;
  place-items: center;
  padding: 25px;
  color: #437abf;
  text-align: center;
}

.placeholder-panel img {
  width: 76px;
  height: 76px;
  margin: 0 auto 12px;
  object-fit: contain;
}

.history-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  margin: 10px 0 12px;
}

.history-summary span {
  min-width: 0;
  padding: 9px 5px;
  border-radius: 11px;
  background: #edf4fa;
  color: #437abf;
  font-size: 10px;
  text-align: center;
}

.history-summary strong {
  display: block;
  color: #1a467c;
  overflow: hidden;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.history-periods {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 5px;
  padding-top: 5px;
}

.history-periods button {
  height: 35px;
  color: #437abf;
  border-radius: 18px;
  background: #edf4fa;
  font-size: 11px;
  font-weight: 800;
}

.history-periods button.is-active {
  color: #fff;
  background: linear-gradient(180deg, #00d1ef, #00a1c5);
  box-shadow: 0 5px 10px rgba(0, 164, 202, 0.22);
}

.history-list {
  display: grid;
  gap: 7px;
  padding-bottom: 8px;
}

.history-row {
  display: grid;
  width: 100%;
  min-height: 76px;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  align-items: center;
  gap: 10px;
  padding: 10px 11px;
  border-radius: 11px;
  background: linear-gradient(180deg, #fff, #e4edf6);
  box-shadow: 0 3px 7px rgba(69, 34, 1, 0.1);
  font-size: 11px;
  text-align: left;
}

.history-row-money {
  text-align: right;
}

.history-row strong,
.history-row time,
.history-row small,
.history-row em {
  display: block;
}

.history-row-main,
.history-row-money {
  min-width: 0;
}

.history-row-main strong {
  overflow: hidden;
  color: #1a467c;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.history-row time,
.history-row small,
.history-row em {
  margin-top: 2px;
  color: #5882af;
  font-size: 9px;
  font-style: normal;
}

.history-row-money strong {
  font-size: 14px;
}

.history-state {
  display: grid;
  min-height: 260px;
  place-items: center;
  align-content: center;
  gap: 10px;
  color: #437abf;
  text-align: center;
}

.history-state img {
  width: 72px;
  height: 72px;
  object-fit: contain;
}

.history-state button,
.history-more {
  min-width: 108px;
  height: 38px;
  padding: 0 16px;
  color: #fff;
  border-radius: 20px;
  background: linear-gradient(180deg, #00d1ef, #00a1c5);
  box-shadow: 0 5px 10px rgba(0, 164, 202, 0.22);
  font-size: 12px;
  font-weight: 800;
}

.history-more {
  display: block;
  margin: 4px auto 24px;
}

.history-more:disabled {
  opacity: 0.55;
}

.history-inline-error {
  margin: 0 0 8px;
  color: #dc385f;
  font-size: 11px;
  text-align: center;
}

.bet-detail {
  display: grid;
  gap: 2px;
  padding: 4px 2px 24px;
}

.bet-detail > div {
  display: grid;
  min-height: 48px;
  grid-template-columns: 86px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid rgba(67, 122, 191, 0.14);
}

.bet-detail span {
  color: #5882af;
  font-size: 11px;
}

.bet-detail strong {
  overflow-wrap: anywhere;
  color: #1a467c;
  font-size: 12px;
  text-align: right;
}

.is-positive {
  color: #1ea969;
}

.is-negative {
  color: #dc385f;
}

/* Game launch and utility popups */
.modal-card--game {
  padding: 0 0 18px;
  overflow: hidden;
}

.modal-card--game .modal-close {
  color: #fff;
  background: rgba(22, 32, 48, 0.65);
}

.game-modal-cover {
  position: relative;
  aspect-ratio: 1.45;
  overflow: hidden;
}

.game-modal-cover::after {
  position: absolute;
  inset: 30% 0 0;
  content: "";
  background: linear-gradient(transparent, rgba(8, 24, 49, 0.9));
}

.game-modal-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.game-modal-cover-copy {
  position: absolute;
  z-index: 2;
  right: 18px;
  bottom: 14px;
  left: 18px;
  color: #fff;
  text-shadow: 1px 1px 3px #0b172b;
}

.game-modal-cover-copy h2 {
  margin: 2px 0 0;
  font-size: 24px;
}

.game-modal-cover-copy span {
  font-size: 11px;
  letter-spacing: 0.08em;
}

.game-modal-body {
  padding: 16px 20px 0;
}

.game-modal-body p {
  margin: 0 0 12px;
  color: #437abf;
  font-size: 12px;
  line-height: 1.65;
  text-align: center;
}

.source-loader {
  display: grid;
  width: min(80%, 300px);
  place-items: center;
  padding: 26px;
  color: #1a467c;
  border: 5px solid transparent;
  border-radius: 28px;
  background:
    linear-gradient(#fffaf0, #fffaf0) padding-box,
    linear-gradient(180deg, #13ccef, #ff68a6) border-box;
  box-shadow: 0 20px 50px rgba(69, 34, 1, 0.28);
}

.source-loader img {
  width: 92px;
  height: 92px;
  object-fit: contain;
}

.source-loader p {
  margin: 6px 0 2px;
  color: #ff5796;
  font-size: 14px;
  font-weight: 800;
}

.source-loader strong {
  font-size: 16px;
  text-align: center;
}

.loading-overlay {
  position: absolute;
  z-index: 120;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.62);
  backdrop-filter: blur(12px);
}

.toast {
  position: absolute;
  z-index: 140;
  right: 24px;
  bottom: calc(env(safe-area-inset-bottom) + 20px);
  left: 24px;
  padding: 11px 15px;
  color: #fff8e4;
  border-radius: 22px;
  background: rgba(26, 70, 124, 0.94);
  box-shadow: 0 8px 20px rgba(69, 34, 1, 0.24);
  font-size: 12px;
  font-weight: 800;
  text-align: center;
  opacity: 0;
  pointer-events: none;
  transform: translateY(14px);
  transition: opacity 180ms ease, transform 180ms ease;
}

.toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@keyframes ticker {
  to { transform: translateX(-200%); }
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@keyframes game-enter {
  from { opacity: 0; transform: translateY(10px) scale(0.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes backdrop-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes modal-enter {
  from { opacity: 0; transform: translateY(16px) scale(0.94); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@media (max-width: 370px) {
  .lobby-header {
    padding-right: 6px;
    padding-left: 7px;
  }

  .profile-button {
    width: 44px;
    height: 44px;
    flex-basis: 44px;
  }

  .balance-row {
    min-width: 146px;
    max-width: none;
    flex-basis: 150px;
  }

  .balance-row strong {
    font-size: 13px;
  }

  .balance-row > img:first-child {
    width: 26px;
    height: 26px;
  }

  .balance-row .refresh-icon {
    width: 16px;
    height: 16px;
  }

  .member-status {
    display: none;
  }

  .member-summary > strong {
    font-size: 11px;
  }

  .category-tabs {
    width: calc(100% - 20px);
    margin-right: 10px;
    margin-left: 10px;
    padding-right: 5px;
    padding-left: 5px;
  }

  .category-tab {
    padding: 0 2px;
    font-size: 10px;
  }

  .games-section {
    padding-right: 18px;
    padding-left: 18px;
  }
}

@media (min-width: 700px) {
  .app-frame {
    border-right: 1px solid rgba(255, 255, 255, 0.35);
    border-left: 1px solid rgba(255, 255, 255, 0.35);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 1ms !important;
  }
}
