@font-face {
  font-family: Nunito;
  src: url('./assets/Nunito.ttf') format('truetype');
  font-style: normal;
  font-weight: 200 1000;
  font-display: swap;
}
:root {
  font-family: Nunito, Arial, sans-serif;
  color: #f8fbff;
  background: #040d2e;
  font-synthesis: none;
  --cyan: #39dcff;
  --muted: #a8c1ff;
  --coral: #ff806e;
  --line: rgba(135, 164, 255, 0.38);
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  overscroll-behavior: none;
}
button,
input,
textarea {
  font: inherit;
}
button {
  cursor: pointer;
  color: inherit;
  border: 0;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
button:disabled {
  opacity: 0.48;
  cursor: default;
}
button:focus-visible,
input:focus-visible {
  outline: 3px solid #57e6ff;
  outline-offset: 3px;
}
button:active:not(:disabled) {
  transform: translateY(2px);
}
[hidden] {
  display: none !important;
}
h1,
h2,
h3,
p {
  margin: 0;
}
h1 {
  font-size: clamp(34px, 9vw, 48px);
  font-weight: 1000;
  line-height: 1.12;
  letter-spacing: -1px;
  text-shadow: 0 2px 0 #5b73c0;
}
h2 {
  font-size: 25px;
  font-weight: 1000;
  line-height: 1.1;
}
h3 {
  font-size: 19px;
}
small {
  font-size: 13px;
  color: var(--muted);
}
a {
  color: #52dcff;
}
#app {
  position: relative;
  width: 100%;
  max-width: 480px;
  height: 100dvh;
  min-height: 600px;
  margin: auto;
  overflow: hidden;
  background:
    radial-gradient(ellipse at 65% 7%, #1045c3 0, transparent 36%),
    radial-gradient(ellipse at 15% 50%, #124bab66, transparent 35%),
    linear-gradient(140deg, #101d55, #0b205e 53%, #101c51);
  box-shadow: 0 0 100px #0a215c;
}
#pages {
  height: calc(100% - 88px - env(safe-area-inset-bottom));
  overflow: auto;
  scrollbar-width: none;
  scroll-behavior: smooth;
}
#pages::-webkit-scrollbar {
  display: none;
}
.page {
  padding: 8px 16px 24px;
}
.art {
  display: block;
  flex-shrink: 0;
  background-repeat: no-repeat;
  background-size: cover;
  pointer-events: none;
}
.round {
  width: 45px;
  height: 45px;
  border-radius: 15px;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, #4878e3, #122e89);
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  box-shadow:
    inset 0 1px 3px #92c9ff99,
    0 4px 9px #030e5266;
  font-size: 35px;
  line-height: 1;
  flex-shrink: 0;
}
.round .art {
  width: 100%;
  height: 100%;
  border-radius: inherit;
}
.round:has(.art) {
  background: none;
  border: 0;
  box-shadow: none;
}
.panel {
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 22px;
  background: linear-gradient(135deg, #293f8799, #1c327f88);
  box-shadow:
    inset 0 1px 0 #a0b8ff20,
    0 6px 22px #03114722;
}
.coral,
.blue,
.cyan {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 15px;
  min-height: 48px;
  border-radius: 24px;
  font-size: 17px;
  font-weight: 900;
  text-shadow: 0 1px 2px #0002;
}
.coral {
  background: linear-gradient(#ffb599, #ff816e 40%, #ff675f);
  border: 1.5px solid #ffd7bf;
  box-shadow:
    inset 0 0 4px 2px #ffe3cf88,
    0 4px 0 #b7496a,
    0 4px 20px #ff726b44;
}
.blue {
  background: linear-gradient(140deg, #247de3, #173ba0 70%);
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  box-shadow:
    inset 0 1px 5px #87dfff88,
    0 3px 0 #0a216e;
}
.cyan {
  color: #063b85;
  background: linear-gradient(#77eaff, #2dd2f4);
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  box-shadow:
    inset 0 1px 3px #defcff88,
    0 0 16px #1bbaf544;
}
.wide {
  width: 100%;
  margin-top: 14px;
}
.text-button {
  background: transparent;
  color: #a9d1ff;
  font-weight: 800;
  padding: 12px;
}
.page-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 10px 0 16px;
  gap: 10px;
}
.page-heading h1 {
  flex: 1;
}
.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.section-title h2 {
  font-size: 22px;
}
.fine {
  font-size: 12px;
  line-height: 1.5;
  color: var(--muted);
  margin: 14px 0 4px;
}
.empty-state {
  padding: 20px;
  text-align: center;
  line-height: 1.6;
  color: #c2d3ff;
}
.empty-state b {
  display: block;
  font-size: 20px;
  color: #fff;
}
.star {
  font-style: normal;
  color: #ff907e;
  text-shadow: 0 0 8px #ff8c9d66;
}
.coin {
  width: 27px;
  height: 27px;
  border-radius: 50%;
  background: linear-gradient(145deg, #ffe8aa, #ffaf4b);
  border: 2px solid #ffe7b6;
  color: #9d531f;
  display: inline-grid;
  place-items: center;
  font-size: 16px;
  font-weight: 1000;
  box-shadow: 0 2px 0 #b56536;
}
.mini-bars {
  width: 19px;
  height: 18px;
  display: inline-block;
  background: linear-gradient(0deg, #358dff, #71edff);
  clip-path: polygon(
    0 65%,
    23% 65%,
    23% 100%,
    35% 100%,
    35% 35%,
    59% 35%,
    59% 100%,
    72% 100%,
    72% 0,
    100% 0,
    100% 100%,
    0 100%
  );
}
.portrait {
  border-radius: 50%;
  background-color: #145bcc;
  border: 2px solid #60c7ff;
  box-shadow: 0 0 12px #1ba9ff66;
  display: block;
  flex-shrink: 0;
  width: 54px;
  height: 54px;
  background-repeat: no-repeat;
}
#accountHeader {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 18px 18px 8px;
}
#accountHeader > .portrait {
  width: 72px;
  height: 72px;
}
.account-info {
  flex: 1;
  min-width: 0;
}
.account-info > b {
  font-size: 24px;
  font-weight: 1000;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}
.account-tags {
  display: flex;
  gap: 8px;
  align-items: center;
}
.tag {
  font-size: 11px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  background: linear-gradient(#2350a780, #172862);
  padding: 4px 8px;
  border-radius: 18px;
}
.tag .star {
  color: #6fe6ff;
  font-size: 18px;
}
#accountHeader .round {
  width: 40px;
  height: 40px;
  border-radius: 12px;
}
.home-visual {
  margin: -1px -16px -2px;
  position: relative;
}
.home-logo {
  width: 90%;
  margin: 0 auto -9px;
  aspect-ratio: 680/207;
  mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
}
.home-hero {
  width: 100%;
  aspect-ratio: 853/524;
  mask-image: linear-gradient(transparent, #000 6%, #000 94%, transparent);
}
.play-art {
  width: 100%;
  aspect-ratio: 738/177;
  margin: 0 0 12px;
  background-color: transparent;
  border-radius: 50px;
  filter: drop-shadow(0 4px 10px #ff687550);
  pointer-events: auto;
}
.home-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}
.image-card {
  border-radius: 20px;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  background: linear-gradient(145deg, #244cba, #172e80);
  position: relative;
  overflow: hidden;
  padding: 0 0 14px;
  box-shadow: inset 0 1px 0 #b2daff44;
}
.image-card > .art {
  width: 100%;
  aspect-ratio: 386/212;
}
.image-card b {
  display: block;
  font-size: 21px;
  text-align: left;
  padding: 0 13px;
  line-height: 1;
}
.circle-arrow {
  position: absolute;
  bottom: 10px;
  right: 12px;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  width: 27px;
  height: 27px;
  border-radius: 50%;
  background: #1e53b9;
  font-size: 28px;
  line-height: 22px;
}
.stats {
  display: flex;
  justify-content: space-evenly;
  padding: 12px 0;
  margin-top: 12px;
}
.stats > div {
  display: grid;
  grid-template-columns: 36px auto;
  column-gap: 7px;
  align-items: center;
  flex: 1;
  justify-content: center;
  border-right: 1px solid #6a8ce344;
}
.stats > div:last-child {
  border: 0;
}
.stats .art {
  width: 32px;
  height: 35px;
  grid-row: 1/3;
}
.stats b {
  font-size: 27px;
  font-weight: 1000;
  line-height: 1.05;
}
.stats small {
  font-size: 13px;
}
.balance-strip {
  display: flex;
  gap: 9px;
  align-items: center;
  width: 100%;
  padding: 12px 16px;
  margin-top: 12px;
  background: #14276588;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 16px;
}
.balance-strip .add {
  margin-left: auto;
  color: #4fdfff;
  font-size: 25px;
}
.balance-strip > span:not(.coin):not(.add) {
  font-size: 12px;
  color: var(--muted);
}
#bottomNav {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 7px 7px calc(9px + env(safe-area-inset-bottom));
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-bottom: 0;
  border-radius: 25px 25px 0 0;
  background: linear-gradient(145deg, #182968, #0c1c4e);
  z-index: 20;
  box-shadow: 0 -5px 18px #06144744;
}
#bottomNav button {
  background: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-width: 0;
  flex: 1;
  padding: 6px 0;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 800;
  color: #b2c8ff;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  line-height: 1.2;
}
#bottomNav .art {
  width: 37px;
  height: 37px;
  border-radius: 35%;
  mask-image: radial-gradient(ellipse, #000 53%, transparent 76%);
}
#bottomNav .active {
  background: linear-gradient(#1967e8aa, #1353cb);
  color: #fff;
  border-color: #45baff;
  box-shadow:
    inset 0 0 9px #489bff,
    0 0 15px #1295ff88;
}
#bottomNav .active .art {
  filter: drop-shadow(0 0 4px #3dedff);
}
.segmented {
  display: flex;
  padding: 3px;
  background: #23398699;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 24px;
  gap: 3px;
  margin: 10px 0;
}
.segmented button {
  flex: 1;
  background: none;
  color: #c0d0ff;
  font-size: 15px;
  font-weight: 900;
  padding: 9px 5px;
  border-radius: 20px;
  white-space: nowrap;
}
.segmented .chosen {
  background: linear-gradient(#6ee9ff, #29c5f4);
  color: #04377f;
  box-shadow:
    0 0 8px #32d2ff77,
    inset 0 1px 1px #e0fbff;
}
.search {
  display: flex;
  align-items: center;
  gap: 7px;
  background: #283e8288;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 24px;
  padding: 0 10px;
  max-width: 48%;
}
.search span {
  font-size: 28px;
  color: #b9d0ff;
}
.search input {
  font-size: 13px !important;
  background: none !important;
  border: 0 !important;
  padding: 8px 0 !important;
  min-width: 0;
}
.club-hero {
  position: relative;
  margin: -8px -16px 0;
  min-height: 205px;
  display: flex;
  align-items: flex-end;
}
.club-hero > .art {
  width: 59%;
  aspect-ratio: 500/486;
  mask-image: linear-gradient(90deg, #000 85%, transparent);
}
.club-identity {
  position: relative;
  flex: 1;
  margin-left: -9%;
  padding-right: 14px;
  padding-bottom: 14px;
  min-width: 0;
}
.club-identity h2 {
  font-size: 29px;
  overflow-wrap: anywhere;
}
.club-identity p {
  font-size: 14px;
  color: #b2c8ff;
  margin-top: 6px;
}
.club-counters {
  display: flex;
  gap: 6px;
  margin-top: 12px;
}
.club-counters > div {
  padding: 9px 8px;
  border-radius: 17px;
  background: #223c8d99;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  text-align: center;
  flex: 1;
}
.club-counters b {
  font-size: 17px;
  white-space: nowrap;
}
.club-counters small {
  display: block;
  font-size: 10px;
}
.member-list {
  padding: 9px;
}
.member-row,
.rank-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  margin-bottom: 5px;
  background: linear-gradient(120deg, #30478cbb, #293e8199);
  border-radius: 18px;
  min-height: 68px;
  overflow: hidden;
}
.member-row .portrait {
  width: 54px;
  height: 54px;
}
.member-row .row-name {
  flex: 1;
  min-width: 0;
}
.member-row b {
  display: block;
  font-size: 19px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.member-row small {
  font-size: 11px;
  color: #59dfff;
}
.member-score {
  font-size: 17px;
  font-weight: 900;
  white-space: nowrap;
}
.member-score .star {
  font-size: 22px;
}
.member-row.self {
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
}
.club-invite {
  margin: 10px 0 4px;
}
.club-tabs button {
  font-size: 14px;
}
.club-about {
  padding: 20px;
  line-height: 1.7;
}
.club-about .text-button {
  display: block;
  margin-top: 12px;
  color: #ffab9c;
}
.club-chat {
  padding: 12px;
  min-height: 200px;
  max-height: 300px;
  overflow: auto;
}
.chat-message {
  margin: 8px 0;
  padding: 10px 13px;
  background: #263f9388;
  border-radius: 14px;
  overflow-wrap: anywhere;
}
.chat-message b {
  font-size: 12px;
  color: #60dfff;
}
.chat-message p {
  font-size: 14px;
}
.chat-message small {
  font-size: 10px;
}
.chat-form {
  display: flex;
  gap: 7px;
  margin-top: 8px;
}
.chat-form input {
  min-width: 0;
}
.club-result {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 12px;
  border-bottom: 1px solid #5377ce44;
}
.club-result small {
  display: block;
}
.club-result .blue {
  min-height: 36px;
  padding: 7px 12px;
  font-size: 13px;
}
.create-club {
  padding: 18px;
}
#rankingPage {
  padding-top: 22px;
}
.rank-tabs {
  max-width: 76%;
  margin-top: 16px;
}
.podium {
  position: relative;
  margin: -3px -16px 0;
  aspect-ratio: 1402/1122;
  overflow: hidden;
}
.podium > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.podium-label {
  position: absolute;
  bottom: 11%;
  width: 25%;
  text-align: center;
  padding: 7px 2px;
  background: linear-gradient(#20439bb0, #193681e0);
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 13px;
  box-shadow: 0 3px 9px #07185066;
}
.podium-label.first {
  left: 36%;
  bottom: 15%;
}
.podium-label.second {
  left: 11%;
  bottom: 10%;
}
.podium-label.third {
  right: 10%;
  bottom: 9%;
}
.podium-label > strong {
  position: absolute;
  top: -37px;
  left: 0;
  right: 0;
  font-size: 29px;
  color: #ffd0ae;
  text-shadow: 0 0 7px #ff8d80;
}
.podium-label b {
  display: block;
  font-size: 15px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.podium-label span {
  font-size: 14px;
  font-weight: 1000;
}
.rank-row {
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  margin: 7px 0;
  padding: 9px 14px;
}
.rank-row .place {
  font-size: 23px;
  font-weight: 1000;
  min-width: 26px;
}
.rank-row .portrait {
  width: 48px;
  height: 48px;
}
.rank-row .row-name {
  flex: 1;
  font-size: 20px;
  font-weight: 900;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.rank-row > strong {
  font-size: 20px;
  white-space: nowrap;
}
.own-rank .rank-row {
  border: 1.5px solid #51dfff;
  background: linear-gradient(130deg, #1261ce, #16337e);
  box-shadow: 0 0 13px #18c6ff77;
}
.own-rank small {
  display: block;
  font-size: 12px;
  font-weight: 700;
}
.rank-list:empty {
  display: none;
}
.collection-title {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 39px;
  margin: 12px -3px 16px;
  gap: 9px;
}
.collection-title > .art {
  width: 52px;
  height: 48px;
}
.collection-showcase {
  display: flex;
  align-items: center;
  margin: 10px -16px 0;
  height: 230px;
  position: relative;
}
.collection-showcase > .arrow {
  z-index: 2;
  position: absolute;
  width: 35px;
  height: 35px;
  border-radius: 50%;
  font-size: 30px;
  left: 10px;
  background: #10265d99;
}
#nextStyle {
  right: 10px;
  left: auto;
}
#collectionHero {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.theme-hero {
  width: 78%;
  aspect-ratio: 609/386;
  background-repeat: no-repeat;
  mask-image: radial-gradient(ellipse, #000 58%, transparent 79%);
}
.theme-hero.theme-card-art {
  width: 88%;
  aspect-ratio: 374/210;
  border-radius: 30px;
  mask-image: radial-gradient(ellipse, #000 52%, transparent 75%);
}
.table-preview {
  width: 76%;
  height: 95%;
  border-radius: 45px;
  background: url('./assets/reference-art/table-empty-blue.webp') center/100% 130%;
  border: 2px solid #6ce3ff;
  box-shadow:
    0 0 20px #158aff,
    0 9px 0 #0f2c85;
  transform: perspective(600px) rotateX(20deg);
}
.style-name {
  text-align: center;
  font-size: 28px;
}
.equip {
  margin: 6px auto 9px;
  padding: 6px 18px;
  min-height: 30px;
  font-size: 15px;
  max-width: 85%;
}
.dots {
  display: flex;
  gap: 7px;
  justify-content: center;
  margin: 8px;
}
.dots i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #3e509b;
}
.dots .active {
  background: #42dfff;
}
.style-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 12px;
}
.style-card {
  border-radius: 22px;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  overflow: hidden;
  background: linear-gradient(145deg, #243e94, #192c72);
  padding: 0 0 10px;
  position: relative;
}
.style-card > .art {
  width: 100%;
  aspect-ratio: 374/210;
}
.style-card h3 {
  font-size: 19px;
}
.style-card small {
  font-size: 12px;
  display: inline-block;
  border-radius: 12px;
  padding: 3px 9px;
  background: #5c6dcc55;
  margin-top: 3px;
}
.style-card.selected {
  border: 2px solid #46e2ff;
  box-shadow: 0 0 12px #2bd5ff66;
}
.style-card.selected small {
  color: #00366c;
  background: #42dcff;
}
.style-card.locked:after {
  content: '♙';
  position: absolute;
  right: 9px;
  top: 8px;
  color: #dce9ff;
  font-size: 17px;
}
.style-card > .table-card {
  width: 100%;
  height: 95px;
  padding: 12px;
}
.table-card > i {
  display: block;
  height: 100%;
  border-radius: 20px;
  border: 2px solid #62dfff;
  background: radial-gradient(#225fde, #09236a);
  box-shadow:
    0 3px 0 #102568,
    0 0 8px #387cff;
}
.theme-space {
  filter: hue-rotate(28deg);
}
.theme-coral {
  filter: hue-rotate(125deg);
}
.theme-ice {
  filter: hue-rotate(-15deg) brightness(1.2);
}
#profilePage {
  padding-top: 8px;
}
#profilePage .page-heading h1 {
  font-size: 42px;
}
.profile-hero {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 16px -5px 0;
}
.profile-portrait {
  padding: 0;
  background: none;
  width: 48%;
  position: relative;
  flex-shrink: 0;
}
.profile-portrait .portrait {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  border: 5px solid #61dfff;
  box-shadow:
    0 0 20px #1a8dff,
    0 4px 0 #206dce;
}
.level-bubble {
  position: absolute;
  bottom: 0;
  right: -1px;
  background: linear-gradient(#ffb28d, #ff706e);
  border: 2px solid #ffbca9;
  border-radius: 50%;
  width: 43px;
  height: 43px;
  display: grid;
  place-items: center;
  font-size: 24px;
  font-weight: 1000;
  box-shadow: 0 2px 1px #ac3e70;
}
.profile-details {
  flex: 1;
  min-width: 0;
}
.profile-details h2 {
  font-size: 28px;
  overflow-wrap: anywhere;
}
.profile-details > small {
  font-size: 12px;
}
.level-card {
  padding: 12px;
  margin-top: 11px;
  border-radius: 20px;
}
.level-card > b {
  font-size: 17px;
  white-space: nowrap;
}
.level-card em {
  color: #ff9b88;
  font-size: 23px;
  font-style: normal;
}
.level-card small {
  font-size: 11px;
  white-space: nowrap;
}
.progress {
  height: 15px;
  border-radius: 20px;
  background: #132361;
  box-shadow: inset 0 2px 5px #050d39aa;
  margin: 6px 0;
}
.progress i {
  display: block;
  border-radius: inherit;
  height: 100%;
  min-width: 3px;
  max-width: 100%;
  background: linear-gradient(#ffca9d, #ff7a79);
  box-shadow: inset 0 1px 1px #ffe9cb;
}
.profile-stats {
  margin-top: 20px;
  padding: 16px 0;
}
.profile-stats > div {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.profile-stats .art {
  height: 30px;
  width: 34px;
}
.profile-stats b {
  font-size: 31px;
}
.profile-stats small {
  font-size: 15px;
}
.achievements {
  padding: 14px 10px;
  margin-top: 12px;
}
.section-title > span {
  font-size: 12px;
  color: #b8caff;
}
.achievements h2 {
  font-size: 24px;
}
#achievementCards {
  display: flex;
  gap: 7px;
  margin-top: 12px;
}
.achievement {
  flex: 1;
  min-width: 0;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 19px;
  background: #2a439355;
  padding: 7px 0;
  text-align: center;
}
.achievement > .art {
  width: 100%;
  aspect-ratio: 224/199;
  border-radius: 15px;
  mask-image: radial-gradient(ellipse, #000 50%, transparent 76%);
}
.achievement b {
  font-size: 12px;
  display: block;
  white-space: nowrap;
}
.achievement small {
  font-size: 9px;
}
.achievement.locked > .art {
  filter: saturate(0.55) brightness(0.7);
}
.profile-menu {
  margin-top: 13px;
  padding: 0 12px;
}
.profile-menu button {
  display: flex;
  align-items: center;
  gap: 15px;
  background: none;
  width: 100%;
  padding: 12px 0;
  border-bottom: 1px solid #7184ca44;
}
.profile-menu button:last-child {
  border: 0;
}
.profile-menu .art {
  width: 44px;
  height: 44px;
  border-radius: 12px;
}
.profile-menu b {
  font-size: 20px;
  flex: 1;
  text-align: left;
}
.profile-menu button > span:last-child {
  font-size: 35px;
  color: #b9d3ff;
}
#lobby {
  height: 100%;
  overflow: auto;
  padding: 12px 20px 26px;
}
.room-illustration {
  width: 75%;
  aspect-ratio: 476/292;
  margin: 0 auto;
  mask-image: radial-gradient(ellipse, #000 50%, transparent 78%);
}
.room-code {
  text-align: center;
  padding: 14px;
}
.room-code > button {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 14px;
  width: 100%;
  background: none;
  margin: 4px 0;
}
.room-code b {
  font-size: 32px;
  color: #68e8ff;
  letter-spacing: 3px;
}
.room-code span {
  font-size: 12px;
  color: #b9d0ff;
}
.room-code p {
  font-size: 12px;
  color: #bcd1ff;
}
.lobby-seat {
  display: flex;
  align-items: center;
  gap: 12px;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 18px;
  background: #29468b77;
  width: 100%;
  padding: 12px;
  margin-top: 9px;
}
.lobby-seat b {
  font-size: 20px;
  display: block;
}
.lobby-seat small {
  display: block;
}
.empty-avatar {
  width: 50px;
  height: 50px;
  border: 1px dashed #6acaff;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 30px;
}
#gameUI {
  position: absolute;
  inset: 0;
  isolation: isolate;
  --board-top: 157px;
  --board-bottom: 235px;
}
#scene {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  touch-action: none;
}
#tableBackdrop {
  position: absolute;
  left: 0;
  right: 0;
  top: 145px;
  bottom: 215px;
  background: url('./assets/reference-art/table-empty-blue.webp') center/100% 130%;
  z-index: 0;
  border-radius: 40px;
  box-shadow: 0 0 25px #093bca88;
}
#gameUI .game-header {
  position: absolute;
  left: 14px;
  right: 14px;
  top: 13px;
  display: flex;
  gap: 7px;
  align-items: center;
  justify-content: space-between;
  z-index: 4;
  pointer-events: none;
}
#gameUI button {
  pointer-events: auto;
}
.game-header > div {
  text-align: center;
  min-width: 0;
  flex: 1;
}
.game-header h1 {
  font-size: 23px;
  white-space: nowrap;
  text-shadow: 0 2px 0 #607ec1;
  letter-spacing: 0;
}
.game-header .round {
  width: 37px;
  height: 37px;
  border-radius: 50%;
  font-size: 32px;
}
#gameCode {
  font-size: 10px;
  background: none;
  color: #9fc8ff;
  font-weight: 800;
  letter-spacing: 1px;
  padding: 2px;
}
#scorePill {
  position: absolute;
  top: 71px;
  left: 50%;
  transform: translateX(-50%);
  min-width: 94px;
  padding: 2px 15px;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  background: #132877;
  border-radius: 20px;
  display: flex;
  gap: 8px;
  justify-content: center;
  z-index: 4;
  font-weight: 1000;
  font-size: 24px;
  line-height: 1.2;
}
#scorePill > span:nth-child(1) {
  color: #6eeaff;
}
#scorePill > span:nth-child(3) {
  color: #ff9583;
}
#players {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 4;
}
.player {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 9px;
  max-width: 68%;
  border-radius: 24px;
}
.player .portrait {
  width: 53px;
  height: 53px;
  border-width: 2px;
}
.player .name {
  display: block;
  font-size: 18px;
  font-weight: 1000;
  max-width: 135px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.player small {
  font-size: 11px;
  display: block;
  line-height: 1.3;
}
.player .role {
  font-size: 8px;
  color: #68dcff;
  display: block;
}
.player.active .portrait {
  box-shadow: 0 0 11px #42e7ff;
  border-color: #77f3ff;
}
.seat-north,
.seat-northwest {
  left: 16px;
  top: 90px;
  flex-direction: column;
  gap: 1px;
  max-width: 26%;
  text-align: center;
}
.seat-north .portrait,
.seat-northwest .portrait {
  width: 55px;
  height: 55px;
}
.seat-north .name,
.seat-northwest .name {
  font-size: 13px;
  max-width: 90px;
}
.seat-north small,
.seat-northwest small {
  display: none;
}
.seat-north .role,
.seat-northwest .role {
  display: none;
}
.seat-northeast {
  right: 16px;
  top: 105px;
}
.seat-northeast .portrait {
  width: 36px;
  height: 36px;
}
.seat-northeast .name {
  font-size: 12px;
}
.seat-northeast small,
.seat-northeast .role {
  display: none;
}
.seat-south {
  left: 18px;
  bottom: 150px;
}
.seat-south .portrait {
  width: 67px;
  height: 67px;
}
.seat-south .role {
  display: none;
}
.seat-south .name {
  font-size: 22px;
}
.seat-south small {
  font-size: 12px;
}
.seat-west,
.seat-east {
  top: calc(50% - 45px);
  flex-direction: column;
  gap: 2px;
  max-width: 45px;
  text-align: center;
}
.seat-west {
  left: 1px;
}
.seat-east {
  right: 1px;
}
.seat-west .portrait,
.seat-east .portrait {
  width: 33px;
  height: 33px;
}
.seat-west .name,
.seat-east .name {
  font-size: 9px;
  max-width: 42px;
}
.seat-west small,
.seat-east small {
  font-size: 8px;
}
.seat-west .role,
.seat-east .role {
  display: none;
}
#app[data-count='4'] .seat-north {
  left: 50%;
  transform: translateX(-50%);
  top: 103px;
  flex-direction: row;
  max-width: 80%;
  text-align: left;
  gap: 7px;
}
#app[data-count='4'] .seat-north .portrait {
  width: 40px;
  height: 40px;
}
#app[data-count='4'] .seat-north .role {
  display: block;
}
#app[data-count='4'] #opponentHand {
  display: none;
}
#opponentHand {
  position: absolute;
  top: 111px;
  left: 30%;
  right: 13px;
  height: 42px;
  display: flex;
  justify-content: center;
  gap: 3px;
  z-index: 3;
  overflow: hidden;
  pointer-events: none;
}
#opponentHand .art {
  width: 21px;
  height: 42px;
  border-radius: 5px;
}
#stock {
  position: absolute;
  top: 113px;
  right: 11px;
  display: flex;
  align-items: center;
  gap: 4px;
  z-index: 4;
  background: none;
  padding: 0;
}
#stock > .art {
  width: 20px;
  height: 40px;
  border-radius: 4px;
  box-shadow:
    1px 2px #134aac,
    2px 4px #2355bf;
}
#stock small {
  font-size: 10px;
  color: #e1eeff;
  background: #132675;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 10px;
  padding: 3px 5px;
}
#opponentHand {
  right: 75px;
}
#turnClock {
  position: absolute;
  right: 25px;
  bottom: 145px;
  width: 72px;
  text-align: center;
  z-index: 4;
  pointer-events: none;
}
#turnClock > div {
  background: conic-gradient(#ff9a88 var(--clock-progress, 100%), #35d7ff 0);
  padding: 5px;
  border-radius: 50%;
  height: 69px;
  box-shadow: 0 0 11px #0f60d277;
}
#turnClock b {
  height: 100%;
  display: grid;
  place-items: center;
  background: #122568;
  border-radius: 50%;
  font-size: 23px;
  font-weight: 1000;
  letter-spacing: -1px;
}
#turnClock small {
  font-size: 14px;
  font-weight: 1000;
  color: #ff9a88;
  white-space: nowrap;
  display: block;
  margin-top: 3px;
}
#turnClock.waiting small {
  color: #7ddfff;
}
#turnClock.urgent > div {
  filter: drop-shadow(0 0 6px #ff736f);
}
#playStatus {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 127px;
  z-index: 4;
  pointer-events: none;
  text-align: center;
  color: #bce3ff;
  font-size: 10px;
  height: 17px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
#quickEnds {
  position: absolute;
  z-index: 5;
  bottom: 126px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  justify-content: center;
  pointer-events: auto;
}
#quickEnds > button {
  background: #1266cd;
  color: #fff;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 17px;
  padding: 5px 13px;
  font-weight: 1000;
  font-size: 13px;
  box-shadow: 0 0 8px #22cfff;
}
#quickEnds:not([hidden]) ~ .game-actions {
}
#gameUI:has(#quickEnds:not([hidden])) #playStatus {
  visibility: hidden;
}
.game-actions {
  position: absolute;
  left: 15px;
  right: 15px;
  bottom: calc(13px + env(safe-area-inset-bottom));
  display: flex;
  align-items: center;
  gap: 8px;
  z-index: 4;
}
.game-actions > .blue {
  flex: 1;
  font-size: 13px;
  min-height: 44px;
  padding: 7px 8px;
  border-radius: 24px;
}
.game-actions > .coral {
  flex: 1.4;
  font-size: 13px;
  min-height: 44px;
  padding: 7px 8px;
}
.game-actions .art {
  width: 23px;
  height: 26px;
}
.game-actions .round {
  width: 42px;
  height: 44px;
  border-radius: 50%;
}
.game-actions .round .art {
  width: 100%;
  height: 100%;
}
#toast {
  position: absolute;
  z-index: 100;
  left: 17px;
  right: 17px;
  top: 8px;
  transform: translateY(-160%);
  transition: transform 0.2s;
  padding: 11px 15px;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 16px;
  background: #10275af5;
  font-size: 13px;
  font-weight: 800;
  box-shadow: 0 6px 18px #03082c99;
  pointer-events: none;
}
#toast.show {
  transform: translateY(0);
}
#connection {
  position: absolute;
  z-index: 90;
  left: 0;
  right: 0;
  top: 0;
  padding: 5px 12px;
  text-align: center;
  background: #ff9a86;
  color: #18336c;
  font-size: 11px;
  font-weight: 900;
}
dialog {
  width: calc(100% - 28px);
  max-width: 440px;
  max-height: calc(100dvh - 48px);
  overflow: auto;
  overscroll-behavior: contain;
  color: #f3f7ff;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 28px;
  background:
    radial-gradient(ellipse at 80% 0, #244dafa0, transparent 70%),
    linear-gradient(150deg, #1b347e, #101e55);
  padding: 22px;
  box-shadow: 0 0 40px #07164388;
}
dialog::backdrop {
  background: #020b32b9;
  backdrop-filter: blur(7px);
}
dialog .sheet-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}
dialog .round.close {
  width: 33px;
  height: 33px;
  font-size: 25px;
  border-radius: 50%;
}
dialog label:not(.toggle-row) {
  font-size: 13px;
  font-weight: 900;
  display: block;
  margin: 15px 0 5px;
  color: #c7d7ff;
}
dialog h2 {
  font-size: 29px;
}
dialog h3 {
  margin: 16px 0 7px;
}
dialog p {
  font-size: 14px;
  color: #c5d6ff;
  line-height: 1.65;
  margin: 8px 0;
}
dialog .segmented button {
  font-size: 13px;
  padding: 9px 4px;
}
input,
textarea {
  color: #f8fbff;
  background: #12235e;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 15px;
  padding: 11px 13px;
  width: 100%;
  outline: none;
  font-size: 16px;
}
input::placeholder {
  color: #9db4ed;
}
input[type='checkbox'] {
  width: 21px;
  height: 21px;
  accent-color: #38d8ff;
}
.toggle-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 0;
  border-bottom: 1px solid #5c75bb55;
}
.join-row {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}
.join-row input {
  min-width: 0;
  text-transform: uppercase;
}
.join-row button {
  min-width: 78px;
  font-size: 14px;
}
details {
  padding: 15px 0;
  color: #b1ceff;
  font-size: 13px;
}
.score-line,
.history-line {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 12px 4px;
  border-bottom: 1px solid #5a71bc66;
}
.history-line b {
  font-size: 16px;
}
.history-line small {
  display: block;
}
.history-line .won {
  color: #60e2ff;
}
.history-line .lost {
  color: #ff9d95;
}
.wallet-total {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  font-size: 40px;
  font-weight: 1000;
  margin: 20px;
}
.wallet-total .coin {
  width: 47px;
  height: 47px;
  font-size: 25px;
}
.bonus-card {
  padding: 15px;
}
.eyebrow {
  font-size: 11px;
  color: #74deff;
  font-weight: 900;
  letter-spacing: 1px;
  margin: 8px 0;
}
#avatarChoice {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-top: 18px;
}
#avatarChoice > button {
  background: none;
  padding: 2px;
  border-radius: 50%;
  border: 2px solid transparent;
}
#avatarChoice > button.chosen {
  border-color: #61efff;
  background: #2786e666;
}
#avatarChoice .portrait {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
}
.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[data-screen='game'] #pages,
#app[data-screen='game'] #bottomNav,
#app[data-screen='room'] #pages,
#app[data-screen='room'] #bottomNav {
  display: none;
}
#app[data-screen='profile'] #accountHeader,
#app[data-screen='club'] #accountHeader,
#app[data-screen='ranking'] #accountHeader {
  display: none;
}
@media (min-width: 481px) {
  body {
    background: radial-gradient(ellipse at center, #0c1b47, #020719);
  }
  #app {
    border-left: 1px solid #26457b;
    border-right: 1px solid #26457b;
  }
}
@media (max-height: 700px) {
  #accountHeader {
    padding-top: 10px;
  }
  .home-logo {
    width: 83%;
    margin-bottom: -14px;
  }
  .home-hero {
    aspect-ratio: 853/470;
  }
  .player.seat-south .portrait {
    width: 55px;
    height: 55px;
  }
  .seat-south .name {
    font-size: 18px;
  }
  .seat-south small {
    font-size: 10px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}

h1,
h2,
.account-info > b,
.stats b,
.profile-details h2 {
  font-weight: 900;
}
.home-visual {
  margin-top: -3px;
}
.home-logo {
  margin-bottom: -9px;
}
.home-hero {
  aspect-ratio: 853/524;
}
.equip:disabled {
  opacity: 1;
}
#opponentHand {
  right: 96px;
}
#stock {
  right: 10px;
  gap: 3px;
}
#stock > .art {
  width: 17px;
  height: 34px;
}
#stock small {
  font-size: 9px;
  padding: 3px 4px;
}
.podium-label b {
  font-size: 13px;
}

#playStatus {
  bottom: 139px;
}
.seat-south {
  bottom: 158px;
}
#turnClock {
  bottom: 153px;
}

/* Responsive screen layouts. */
#accountHeader {
  padding: 12px 16px 5px;
}
#accountHeader > .portrait {
  width: 64px;
  height: 64px;
}
#app[data-screen='collection'] #accountHeader > .portrait {
  width: 56px;
  height: 56px;
}
#collectionPage .collection-title {
  margin: 4px -3px 8px;
}
#collectionTabs button {
  padding: 6px 5px;
}
.collection-showcase {
  height: clamp(135px, 22dvh, 180px);
  margin-top: 4px;
}
.theme-hero {
  width: 74%;
  max-height: 100%;
}
.style-name {
  font-size: 26px;
}
.equip {
  min-height: 24px;
  padding: 3px 16px;
  font-size: 14px;
  margin: 4px auto 6px;
}
.dots {
  margin: 5px;
}
.style-card {
  padding-bottom: 8px;
}
.style-card h3 {
  font-size: 18px;
  line-height: 22px;
}
.style-card small {
  font-size: 11px;
  line-height: 15px;
  padding: 2px 8px;
}
.profile-stats {
  padding: 10px 0;
}
.profile-stats > div {
  gap: 3px;
}
.profile-stats b {
  font-size: 28px;
}
.achievement small {
  display: none;
}
.achievement > .art {
  width: 90%;
  margin: auto;
}
#app[data-count='3'] #stock {
  left: 50%;
  right: auto;
  transform: translateX(-50%);
}
#app[data-table='space'] #tableBackdrop {
  filter: hue-rotate(35deg);
}
#app[data-table='coral'] #tableBackdrop {
  filter: hue-rotate(150deg);
}
#app[data-table='ice'] #tableBackdrop {
  filter: hue-rotate(-15deg) brightness(1.16);
}

.collection-showcase {
  height: clamp(130px, 19dvh, 161px);
}
.style-cards {
  gap: 8px;
  margin-top: 10px;
}

#gameUI {
  --hand-extra: 0px;
  --hand-half: 0px;
}
#tableBackdrop {
  bottom: calc(215px + var(--hand-extra));
}
.seat-south {
  bottom: calc(158px + var(--hand-extra));
}
#turnClock {
  width: 120px;
  right: 3px;
  bottom: calc(153px + var(--hand-extra));
}
#turnClock > div {
  width: 69px;
  margin: auto;
}
#turnClock small {
  font-size: 12px;
}
#playStatus {
  bottom: calc(139px + var(--hand-extra));
}
#quickEnds {
  bottom: calc(138px + var(--hand-extra));
}
.seat-west,
.seat-east {
  top: calc(50% - 45px - var(--hand-half));
}

.collection-modal #collectionPage {
  padding: 0;
}
.collection-modal .collection-title {
  display: none;
}
.collection-modal .collection-showcase {
  height: 155px;
}
.collection-modal #collectionPage .style-cards {
  margin-bottom: 5px;
}

.member-row.self .portrait {
  position: relative;
}
.member-row.self .portrait:after {
  content: '';
  position: absolute;
  width: 10px;
  height: 10px;
  right: -1px;
  bottom: 0;
  border-radius: 50%;
  border: 2px solid #244591;
  background: #36e3f3;
}
.rank-row > strong:first-letter,
.member-score:first-letter {
  color: #ff947f;
}
/* Individual illustration files, no screenshot sprites. */
.art {
  position: relative;
  background: none;
}
.art > img {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
}
.portrait {
  background-size: 100% 100%;
  background-position: center;
}
.avatar-0 {
  background-image: url('./assets/ui-v7/avatar0.webp');
}
.avatar-1 {
  background-image: url('./assets/ui-v7/avatar1.webp');
}
.avatar-2 {
  background-image: url('./assets/ui-v7/avatar2.webp');
}
.avatar-3 {
  background-image: url('./assets/ui-v7/avatar3.webp');
}
.avatar-4 {
  background-image: url('./assets/ui-v7/avatar4.webp');
}
.avatar-5 {
  background-image: url('./assets/ui-v7/avatar5.webp');
}
.avatar-6 {
  background-image: url('./assets/ui-v7/avatar6.webp');
}
.avatar-7 {
  background-image: url('./assets/ui-v7/avatar7.webp');
}
.profile-portrait .avatar-0 {
  background-image: url('./assets/ui-v7/profileAvatar0.webp');
}
.home-logo {
  mask-image: none;
}
.play-art {
  aspect-ratio: auto;
  min-height: 74px;
  font-size: 38px;
  gap: 18px;
  margin: 0 0 15px;
  border-radius: 42px;
  pointer-events: auto;
}
.play-art > .art {
  width: 42px;
  height: 42px;
  filter: drop-shadow(0 3px 1px #c85457);
}
#bottomNav .art {
  mask-image: none;
}
.quick-match {
  padding: 20px;
  margin: 8px 0 18px;
}
.quick-match h2 {
  font-size: 25px;
}
.quick-match p {
  font-size: 13px;
  color: #bbd8ff;
  margin-top: 8px;
}
.quick-match .text-button {
  margin-top: 6px;
  padding: 8px;
  font-size: 13px;
}
.online-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.online-actions button {
  font-size: 15px;
  padding: 13px 8px;
}
.rooms-title {
  margin: 25px 0 12px;
}
.rooms-title small {
  display: block;
  margin-top: 5px;
}
.rooms-title .round {
  width: 36px;
  height: 36px;
  font-size: 24px;
}
.live-badge {
  font-size: 10px;
  background: #14d8bd22;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 20px;
  padding: 6px 9px;
  color: #72ffdf;
  white-space: nowrap;
}
.room-filters {
  display: flex;
  gap: 8px;
  margin-bottom: 13px;
}
.room-filters select {
  font: inherit;
  font-size: 13px;
  color: #dce8ff;
  background: #1d3479;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 12px;
  padding: 10px;
  width: 50%;
}
.public-table {
  padding: 16px;
  margin-bottom: 12px;
}
.table-card-head,
.table-card-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}
.table-card-head h3 {
  font-size: 20px;
}
.table-card-head small {
  font-size: 11px;
}
.seat-count {
  background: #244fa7;
  border-radius: 12px;
  color: #69e7ff;
  font-size: 19px;
  font-weight: 900;
  padding: 5px 10px;
}
.table-card-seats {
  display: flex;
  gap: 8px;
  padding: 16px 0;
}
.table-card-seat {
  flex: 1;
  min-width: 0;
  text-align: center;
}
.table-card-seat > .portrait,
.table-card-seat > .empty-avatar {
  margin: 0 auto 6px;
  width: 45px;
  height: 45px;
}
.table-card-seat small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
}
.table-card-foot {
  border-top: 1px solid #6a89d444;
  padding-top: 12px;
  font-size: 13px;
  color: #a9d9ff;
}
.table-card-foot button {
  padding: 8px 22px;
  min-height: 36px;
  font-size: 14px;
}
.waiting-message {
  padding: 15px 8px 0;
  color: #bcd4ff;
  font-size: 14px;
  line-height: 1.5;
  text-align: center;
}
#toggleRoomVisibility {
  margin: 0;
  padding: 10px;
}
#app[data-screen='online'] #accountHeader {
  display: none;
}
@media (max-height: 700px) {
  .play-art {
    min-height: 65px;
    font-size: 34px;
  }
  .quick-match {
    padding: 16px;
  }
  .quick-match .wide {
    margin-top: 10px;
  }
}

/* v8: readable game seats, restrained score notices, illustrated rewards and results. */
#app[data-table='cloud'] #tableBackdrop {
  background-image: url('./assets/ui-v8/table-cloud.webp');
  filter: none;
}
#app[data-table='space'] #tableBackdrop {
  background-image: url('./assets/ui-v8/table-space.webp');
  filter: none;
}
#app[data-table='coral'] #tableBackdrop {
  background-image: url('./assets/ui-v8/table-coral.webp');
  filter: none;
}
#app[data-table='ice'] #tableBackdrop {
  background-image: url('./assets/ui-v8/table-ice.webp');
  filter: none;
}
#tableBackdrop {
  background-size: 100% 100%;
  border-radius: 28px;
  top: 153px;
  bottom: calc(215px + var(--hand-extra));
}
.player {
  pointer-events: auto;
  cursor: pointer;
  background: linear-gradient(135deg, #193a86ed, #0a1d4cee);
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  padding: 5px 8px;
  box-shadow: 0 4px 12px #0004;
  text-align: left;
}
.player.active {
  border-color: #65edff;
  box-shadow: 0 0 12px #2bcbff55;
}
.player .name {
  font-size: 14px;
  max-width: 105px;
}
.player small {
  color: #d3e4ff;
  font-size: 10px;
}
.player .role {
  color: #6eeaff;
  letter-spacing: 0.3px;
}
.seat-north,
.seat-northwest {
  top: 96px;
  left: 13px;
  max-width: 40%;
  flex-direction: row;
  text-align: left;
  gap: 6px;
}
.seat-north .portrait,
.seat-northwest .portrait {
  width: 40px;
  height: 40px;
}
.seat-north .name,
.seat-northwest .name {
  font-size: 13px;
  max-width: 75px;
}
.seat-northeast {
  top: 103px;
  right: 13px;
  gap: 5px;
  max-width: 40%;
}
.seat-northeast .portrait {
  width: 32px;
  height: 32px;
}
.seat-south {
  padding: 5px 8px;
  left: 14px;
  bottom: calc(158px + var(--hand-extra));
  max-width: 65%;
}
.seat-south .portrait {
  width: 48px;
  height: 48px;
}
.seat-south .name {
  font-size: 18px;
}
.seat-south small {
  font-size: 10px;
}
.seat-west,
.seat-east {
  top: calc(50% - 48px - var(--hand-half));
  padding: 5px 3px;
  max-width: 56px;
  border-radius: 16px;
  text-align: center;
  background: #102b69ed;
}
.seat-west {
  left: 3px;
}
.seat-east {
  right: 3px;
}
.seat-west .portrait,
.seat-east .portrait {
  width: 34px;
  height: 34px;
}
.seat-west .name,
.seat-east .name {
  max-width: 48px;
  font-size: 10px;
}
.seat-west small,
.seat-east small {
  font-size: 8px;
}
#app[data-count='4'] .seat-north {
  top: 102px;
  padding: 4px 9px;
  max-width: 65%;
}
#app[data-count='4'] .seat-north .portrait {
  width: 33px;
  height: 33px;
}
#scorePill {
  position: absolute;
  overflow: visible;
}
#scorePill .score-pop {
  position: absolute;
  right: -12px;
  top: 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 5px 11px;
  border-radius: 14px;
  background: #092158ed;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  box-shadow: 0 0 12px #2cd9ff44;
  animation: score-rise 1.8s ease-out forwards;
  white-space: nowrap;
  pointer-events: none;
}
.score-pop small {
  font-size: 10px;
  max-width: 95px;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #d8efff;
}
.score-pop b {
  font-size: 22px;
  color: #6ef6dd;
}
@keyframes score-rise {
  0% {
    opacity: 0;
    transform: translateY(6px) scale(0.8);
  }
  15%,
  75% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
  100% {
    opacity: 0;
    transform: translateY(-12px);
  }
}
#toast {
  top: auto;
  bottom: 100px;
  font-size: 13px;
  width: auto;
  left: 25px;
  right: 25px;
  text-align: center;
  transform: translateY(230px);
  background: #102858f5;
  max-height: 100px;
  overflow: hidden;
}
#toast.show {
  transform: translateY(0);
}
#app[data-screen='game'] #toast {
  bottom: 65px;
  left: 30px;
  right: 30px;
  padding: 8px 12px;
}
#languageChoice {
  font: inherit;
  width: 100%;
  padding: 12px;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 12px;
  background: #142a65;
  color: #fff;
}
.legal-links {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: 16px 0;
  font-size: 11px;
}
.danger-text {
  color: #ffac9f;
}
.rewards-banner {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  margin-top: 12px;
  padding: 8px 12px;
  text-align: left;
  background: linear-gradient(120deg, #263d91, #214a98);
}
.rewards-banner img {
  width: 60px;
  height: 60px;
  object-fit: contain;
  filter: drop-shadow(0 0 8px #55d4ff66);
}
.rewards-banner > span:nth-child(2) {
  flex: 1;
}
.rewards-banner b {
  display: block;
  font-size: 17px;
}
.rewards-banner small {
  display: block;
  font-size: 11px;
}
.rewards-banner > span:last-child {
  font-size: 30px;
}
.chest-stage {
  position: relative;
  display: grid;
  place-items: center;
  height: 160px;
  background: radial-gradient(ellipse, #3fc8ff33, transparent 65%);
}
.chest-stage img {
  height: 155px;
  width: 200px;
  object-fit: contain;
  filter: drop-shadow(0 0 15px #2bc8ff44);
  animation: chest-breathe 3s ease-in-out infinite;
}
.chest-stage img.opened {
  animation: chest-open 0.8s ease-out;
}
.chest-spark {
  position: absolute;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #c2f8ff;
  box-shadow:
    40px -35px 9px #78eaff,
    -70px -25px 10px #ffe09d,
    65px 45px 8px #6ae7ff;
  pointer-events: none;
}
@keyframes chest-breathe {
  50% {
    transform: translateY(-4px);
    filter: drop-shadow(0 0 22px #69eaff77);
  }
}
@keyframes chest-open {
  30% {
    transform: scale(1.12) rotate(-4deg);
  }
  60% {
    transform: scale(1.07) rotate(4deg);
  }
  100% {
    transform: scale(1);
  }
}
#dailyDays {
  display: flex;
  gap: 4px;
  margin: 12px 0;
}
.daily-day {
  flex: 1;
  min-width: 0;
  padding: 8px 1px;
  background: #24417e;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 10px;
  text-align: center;
}
.daily-day small {
  font-size: 9px;
  white-space: nowrap;
}
.daily-day b {
  display: block;
  font-size: 14px;
  color: #ffe2a1;
}
.daily-day.claimed {
  border-color: #55f5db;
  background: #17687c;
}
.quest-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 1px solid #5274bf66;
}
.quest-card > div {
  flex: 1;
}
.quest-card b {
  display: block;
  font-size: 13px;
}
.quest-card small {
  display: block;
  font-size: 11px;
}
.quest-card button {
  font-size: 12px;
  padding: 8px 11px;
  min-height: 34px;
}
progress {
  width: 100%;
  height: 7px;
  accent-color: #49dbef;
  border: 0;
  border-radius: 9px;
  overflow: hidden;
  background: #0c2259;
}
progress::-webkit-progress-bar {
  background: #0c2259;
}
progress::-webkit-progress-value {
  background: linear-gradient(90deg, #2ad9e9, #a0f5ff);
}
.ad-reward-note {
  padding: 14px;
  margin-top: 18px;
}
.ad-reward-note h3 {
  font-size: 18px;
  margin: 0;
}
.ad-reward-note p {
  font-size: 12px;
}
.public-profile {
  text-align: center;
}
.public-profile .portrait {
  width: 100px;
  height: 100px;
  margin: 5px auto 14px;
}
#playerFacts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 20px;
}
#playerFacts > div {
  background: #213f8088;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  padding: 14px;
  border-radius: 14px;
  text-align: center;
}
#playerFacts b,
#playerFacts small {
  display: block;
}
#playerFacts b {
  font-size: 23px;
}
#result {
  max-width: 450px;
}
#resultHands {
  margin-top: 15px;
}
.reveal-hand {
  padding: 12px;
  border-radius: 16px;
  background: #1b3875;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  margin-bottom: 9px;
  animation: reveal-in 0.35s both;
}
.reveal-hand:nth-child(2) {
  animation-delay: 0.1s;
}
.reveal-hand:nth-child(3) {
  animation-delay: 0.2s;
}
.reveal-hand:nth-child(4) {
  animation-delay: 0.3s;
}
.reveal-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  font-size: 14px;
}
.reveal-head strong {
  color: #7de9ff;
}
.winning-hand {
  border-color: #79e9d4;
}
.revealed-tiles {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
  margin-top: 10px;
}
.mini-domino {
  display: flex;
  flex-direction: column;
  width: 29px;
  height: 54px;
  background: linear-gradient(135deg, #fff, #dae7f6);
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 5px;
  box-shadow: 0 3px 0 #278ac6;
  flex-shrink: 0;
  padding: 3px;
}
.pip-half {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(3, 1fr);
  gap: 1px;
  flex: 1;
  padding: 2px;
}
.pip-half:first-child {
  border-bottom: 1px solid #769db7;
}
.pip-half i {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #122f75;
  visibility: hidden;
  align-self: center;
  justify-self: center;
}
.pip-half[data-value='1'] i:nth-child(5),
.pip-half[data-value='2'] i:nth-child(1),
.pip-half[data-value='2'] i:nth-child(9),
.pip-half[data-value='3'] i:nth-child(1),
.pip-half[data-value='3'] i:nth-child(5),
.pip-half[data-value='3'] i:nth-child(9),
.pip-half[data-value='4'] i:nth-child(1),
.pip-half[data-value='4'] i:nth-child(3),
.pip-half[data-value='4'] i:nth-child(7),
.pip-half[data-value='4'] i:nth-child(9),
.pip-half[data-value='5'] i:nth-child(odd),
.pip-half[data-value='6'] i:nth-child(3n + 1),
.pip-half[data-value='6'] i:nth-child(3n) {
  visibility: visible;
}
.team-totals {
  display: flex;
  gap: 8px;
  justify-content: space-between;
  padding: 12px;
  color: #86ebff;
  background: #132a62;
  border-radius: 12px;
  font-weight: 900;
  font-size: 13px;
}
@keyframes reveal-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
.table-card-image {
  width: 100%;
  height: 120px;
  object-fit: cover;
  object-position: center;
  display: block;
  border-radius: 18px 18px 0 0;
}
.table-showcase-image {
  height: 100%;
  width: 100%;
  max-width: 200px;
  object-fit: contain;
  filter: drop-shadow(0 9px 10px #0005);
}
.rank-row.self {
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  background: linear-gradient(120deg, #1c62c2, #174c9c);
  box-shadow: 0 0 12px #2bbfff33;
}
.rank-row.self .row-name {
  color: #81f3ff;
}
@media (max-width: 380px) {
  .seat-south .portrait {
    width: 42px;
    height: 42px;
  }
  .seat-south .name {
    font-size: 16px;
  }
  .seat-south {
    max-width: 63%;
  }
  .seat-west,
  .seat-east {
    max-width: 47px;
  }
  .seat-west .name,
  .seat-east .name {
    max-width: 40px;
  }
  .seat-west .portrait,
  .seat-east .portrait {
    width: 28px;
    height: 28px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .chest-stage img,
  .score-pop,
  .reveal-hand {
    animation: none !important;
  }
}

#app[data-count='2'] #opponentHand {
  left: 42%;
  right: 84px;
  gap: 2px;
  height: 34px;
}
#app[data-count='2'] #opponentHand .art {
  width: 16px;
  height: 33px;
}
.seat-west,
.seat-east {
  max-width: 45px;
}
.seat-west .name,
.seat-east .name {
  max-width: 38px;
  font-size: 9px;
}
#globalWordmark {
  display: block;
  text-align: center;
  padding: 0 10px 4px;
}
#globalWordmark span {
  display: block;
  font-size: 16px;
  font-weight: 800;
  color: #bcecff;
}
.home-visual .home-logo {
  display: block;
  width: 94%;
  aspect-ratio: 3/1;
  margin: 0 auto;
}
.home-visual .home-hero {
  mask-image: none;
}
.table-card-image {
  height: 145px;
  object-fit: contain;
  padding: 5px;
  background: radial-gradient(ellipse, #2457a0, #10245a);
}
.result-close {
  position: absolute;
  right: 15px;
  top: 15px;
}
#resultTitle {
  padding-right: 25px;
}
.reveal-role {
  display: block;
  font-size: 10px;
  color: #9cb9e9;
  margin-top: 3px;
}
.team-totals {
  flex-direction: column;
  gap: 10px;
}
.team-totals > div {
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.team-totals .team-names {
  font-size: 11px;
  color: #b9d5ff;
}
.result-award {
  margin: 10px 0;
  padding: 10px;
  border: 0;
  box-shadow:
    inset 0 1px 0 #c9eaff25,
    0 4px 14px #020a2b35;
  border-radius: 12px;
  color: #8ef5dc;
  font-weight: 900;
  text-align: center;
}
.result-award small {
  display: block;
  font-size: 11px;
  margin-top: 5px;
  color: #bcd8f5;
}
.rank-row .row-name > span {
  display: block;
}
.rank-row .row-name > small {
  display: block;
  font-size: 11px;
  color: #b8dfff;
  line-height: 1.2;
}
