/* Royal Coin saloon · visual layer. Game state and motion live in their own modules. */
html { background: #100e0b; }
body.refresh-design {
  --saloon-ink: #17140f;
  --saloon-panel: #211c16;
  --saloon-border: #6f553332;
  --saloon-brass: #c6a16a;
  --saloon-ivory: #f0e2c9;
  --saloon-muted: #ad9c84;
  background: var(--saloon-ink);
  color: var(--saloon-ivory);
  padding-bottom: calc(82px + env(safe-area-inset-bottom));
  box-shadow: 0 0 80px #0005;
}
.refresh-design .grain { opacity: .012; }
.refresh-design .topbar {
  height: 64px;
  padding: 0 18px;
  border-bottom: 1px solid #9b76442b;
  background: #17140fbd;
}
.refresh-design .brand { gap: 9px; }
.refresh-design .brand-seal { width: 35px; height: 35px; box-shadow: inset 0 0 0 2px #20180f, inset 0 0 0 3px #765c3c; }
.refresh-design .brand-seal::after { display: none; }
.refresh-design .brand-seal img { width: 21px; height: 21px; }
.refresh-design .brand-name { font-size: 11px; letter-spacing: .07em; color: #e6d6b9; }
.refresh-design .account { min-width: 0; text-align: right; }
.refresh-design .balance-label { font-size: 8px; letter-spacing: .07em; color: #9e8b70; }
.refresh-design .balance-value { justify-content: flex-end; font-size: 13px; color: #e9d9b8; }
.refresh-design .balance-value .coin-icon { display: none; }
.refresh-design .app-status { display: none; align-items: center; gap: 6px; color: #ad9c83; font-size: 10px; }
.refresh-design .app-status i { width: 5px; height: 5px; border-radius: 50%; background: #817057; }
.refresh-design .app-status[data-connected="true"] i { background: #95a77c; box-shadow: 0 0 6px #a6ba7620; }
.refresh-design[data-current-view="saloon"] .account { display: none; }
.refresh-design[data-current-view="saloon"] .app-status { display: flex; }

/* Profile and wallet sit on the artwork in separate translucent panels. */
.refresh-design #view-saloon { padding: 16px 16px 10px; }
/* Keep the backdrop panels and artwork in one clipped paint area. */
.saloon-welcome { position: relative; isolation: isolate; contain: paint; display: flex; overflow: hidden; min-height: 326px; margin: 0; padding: 14px; border: 1px solid #bc9c646b; border-radius: 15px; background: #30251b; }
.saloon-welcome-art { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 35%; z-index: 0; pointer-events: none; }
.saloon-welcome::before { content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none; background: linear-gradient(180deg,#100e0b24 0%,transparent 40%,#0d100a69 100%); }
.saloon-welcome-title { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.home-summary { position: relative; z-index: 2; display: flex; flex-direction: column; justify-content: space-between; gap: 74px; width: 100%; min-width: 0; }
.refresh-design .home-profile { align-self: flex-start; max-width: calc(100% - 48px); min-width: 0; margin: 0; padding: 10px 12px; gap: 10px; border: 1px solid #dec29438; border-radius: 10px; background: linear-gradient(140deg,#e6cfa30e,#19171070); box-shadow: inset 0 1px #f5dfbd17,0 3px 15px #0002; -webkit-backdrop-filter: blur(9px); backdrop-filter: blur(9px); }
.refresh-design .home-profile .profile-avatar { width: 37px; height: 37px; border: 1px solid #d6b47665; background: #352c195e; box-shadow: inset 0 0 0 3px #17140d2e; flex: none; }
.refresh-design .home-profile .profile-avatar svg { width: 20px; height: 20px; color: #ead0a2; stroke: currentColor; }
.refresh-design .home-profile-copy { min-width: 0; gap: 5px; }
.refresh-design .home-profile-copy strong { max-width: 100%; overflow-wrap: anywhere; font-size: 18px; line-height: 1.15; color: #f4e7d2; text-shadow: 0 1px 4px #0005; }
.refresh-design .home-profile-copy small { color: #d1bea0; font-size: 9px; line-height: 1.3; }
.refresh-design .demo-badge { display: none; }
.refresh-design .mini-wallet { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; min-width: 0; min-height: 0; margin: auto 0 0; padding: 16px; border: 1px solid #dec29440; border-radius: 11px; background: linear-gradient(130deg,#f1d5a411,#15191091); box-shadow: inset 0 1px #f5dfbd1c,0 5px 20px #0002; text-align: left; -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
.refresh-design .wallet-copy { flex: 1; min-width: 0; }
.wallet-label { font-size: 10px; letter-spacing: .04em; color: #dac5a4; }
.refresh-design .wallet-value { justify-content: flex-start; flex-wrap: wrap; gap: 5px 7px; margin: 7px 0 0; color: #fff0d3; font-size: clamp(27px,7.6vw,36px); line-height: 1.05; font-variant-numeric: tabular-nums; text-shadow: 0 2px 7px #0004; }
.refresh-design #wallet-balance { min-width: 0; max-width: 100%; overflow-wrap: anywhere; }
.refresh-design .wallet-currency { align-self: baseline; font-size: 13px; color: #e4c895; }
.refresh-design .wallet-copy p { margin: 6px 0 0; color: #c2b091; font-size: 8px; line-height: 1.5; }
.refresh-design .wallet-play { flex: none; display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 11px 12px; border: 1px solid #e9cc924f; border-radius: 8px; background: linear-gradient(145deg,#e8c8912b,#bda3690c); color: #f6e4bd; font-size: 13px; box-shadow: inset 0 1px #ffebc926,0 2px 8px #0002; cursor: pointer; transition: background .18s,border-color .18s; }
.refresh-design .wallet-play svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.refresh-design .wallet-play:hover { background: #e6c48b38; border-color: #f4d99f8c; }
.refresh-design .wallet-play:active { background: #e6c48b49; }
.saloon-welcome-seal { position: absolute; z-index: 2; top: 15px; right: 15px; width: 35px; height: 35px; display: grid; place-items: center; border: 1px solid #e1c89255; border-radius: 50%; background: #20170f40; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.saloon-welcome-seal img { width: 20px; height: 20px; }

.refresh-design .management { padding: 0; margin: 12px 0 27px; }
.refresh-design .manage-grid { gap: 7px; padding: 0; border: 0; border-radius: 0; background: none; }
.refresh-design .manage-tile { position: relative; isolation: isolate; gap: 7px; min-height: 68px; padding: 10px 0; border: 1px solid #dec29430; border-radius: 10px; background: linear-gradient(145deg,#e5c79714,#a68b5505); color: #d4bea0; font-size: 10px; box-shadow: inset 0 1px #f2daba12; transition: background .18s,border-color .18s; }
.refresh-design .manage-tile + .manage-tile { border-left: 1px solid #dec29430; }
.refresh-design .manage-icon { width: 27px; height: 24px; border: 0; border-radius: 0; background: none; color: #bc9965; }
.refresh-design .manage-icon svg { width: 22px; height: 22px; stroke-width: 1.55; }
.refresh-design .manage-tile:hover { background: #cfa7741f; border-color: #dec2946b; color: #f0d49f; }
.refresh-design .manage-tile:active .manage-icon { background: none; }

/* Two columns throughout the mini app. Art and titles remain actual separate elements. */
.section-kicker { display: block; margin-bottom: 5px; color: #a98a5e; font-size: 8px; letter-spacing: .11em; }
.refresh-design .games-section { padding: 0; margin: 0; }
.refresh-design .games-section .section-heading { margin: 0 0 14px; align-items: center; gap: 10px; }
.refresh-design .games-section .section-heading h2 { margin: 0; color: #eddec2; font-size: 25px; line-height: 1.1; font-weight: 400; }
.refresh-design .games-section .section-heading .text-button { display: inline-flex; align-items: center; gap: 5px; flex: none; min-height: 38px; padding: 7px 10px; border: 1px solid #dec29428; background: #d9b9840c; border-radius: 7px; color: #d7bc90; font-size: 11px; letter-spacing: 0; text-transform: none; }
.refresh-design .text-button svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.refresh-design .game-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 14px 12px; }
.refresh-design .game-grid > .game-card { order: initial; }
.refresh-design .games-section .game-grid > .game-card:nth-child(-n+4) { display: flex; }
.refresh-design .games-section .game-grid > .game-card:nth-child(n+5) { display: none; }
.refresh-design .game-card {
  display: flex; flex-direction: column; width: 100%; min-width: 0; min-height: 0; height: auto; aspect-ratio: auto;
  padding: 0; border: 1px solid #8a693947; border-radius: 10px; background: #cba66b09;
  box-shadow: 0 3px 10px #0002; color: #f1dfbd; isolation: isolate; transform: none;
  transition: border-color .2s, background .2s;
}
.refresh-design .game-card::before { display: none; }
.refresh-design .game-card:hover { transform: none; background: #c7a16b14; border-color: #ac8753a3; }
.refresh-design .game-card:active { transform: none; background: #c7a16b22; box-shadow: inset 0 0 0 1px #a58047; }
.refresh-design .game-card:focus-visible { outline: 2px solid #d5ad6e; outline-offset: 3px; }
.game-art { position: relative; display: block; flex: none; width: 100%; height: auto; aspect-ratio: 1.35; overflow: hidden; background: #2d241c; }
.refresh-design .game-art::before { display: none; }
.game-art::after { content: ''; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(0deg,#221d1699,transparent 26%); box-shadow: inset 0 1px #e7c89813; }
.refresh-design .game-art img { display: block; position: relative; width: 100%; height: 100%; margin: 0; object-fit: cover; object-position: center; transition: transform .35s ease; }
@media(hover:hover) { .refresh-design .game-card:hover .game-art img { transform: scale(1.035); } }
.refresh-design .game-duration { position: absolute; top: 8px; right: 8px; z-index: 1; padding: 5px 7px; border: 1px solid #c0a47945; border-radius: 4px; color: #dfcfb2; background: #18140f91; -webkit-backdrop-filter: blur(7px); backdrop-filter: blur(7px); font-size: 8px; line-height: 1; letter-spacing: .02em; }
.game-card-copy { display: flex; flex: 1; flex-direction: column; gap: 5px; width: 100%; padding: 11px 11px 10px; }
.refresh-design .game-name { position: static; display: block; color: #f0dfbf; font-size: clamp(17px,4.8vw,23px); line-height: 1.12; letter-spacing: .005em; text-shadow: none; overflow-wrap: anywhere; }
.refresh-design .game-desc { position: static; display: block; max-width: none; min-height: 2.7em; color: #b6a184; font-size: 10px; line-height: 1.35; }
.refresh-design .players { display: flex; align-items: center; gap: 5px; margin-top: auto; padding: 9px 0 0; border: 0; border-top: 1px solid #9b784025; background: none; color: #9c927b; font-size: 9px; line-height: 1.2; letter-spacing: 0; text-transform: none; }
.refresh-design .players i { display: block; width: 4px; height: 4px; margin: 0; box-shadow: none; border-radius: 50%; background: #847055; }
.refresh-design .game-card.has-players .players i { background: #9cae79; }
.refresh-design .game-card.has-players .players { color: #b9b996; }
.refresh-design .game-card.is-upcoming .game-art img { opacity: .55; filter: saturate(.5); }
.refresh-design .game-card.is-upcoming .game-name { color: #c2b195; }
.refresh-design #view-games { padding: 27px 16px 14px; }
.catalog-heading { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.catalog-heading h1 { margin: 0; font-size: 34px; line-height: 1.15; font-weight: 400; color: #eddec1; }
.catalog-count { flex: none; padding: 6px 8px; border: 1px solid #95714140; border-radius: 5px; color: #b69b73; font-size: 10px; }
.catalog-caption { max-width: 380px; margin: 9px 0 22px; color: #ad9a7e; font-size: 11px; line-height: 1.55; }

.refresh-design .home-event { min-height: 0; margin: 24px 0 0; padding: 16px 13px; gap: 12px; border: 1px solid #92713e35; border-radius: 8px; background: linear-gradient(140deg,#a4ae7620,#71805607); box-shadow: inset 0 1px #d9e1bc0d; }
.refresh-design .event-stamp { width: 32px; height: 32px; border: 0; background: none; color: #b19565; }
.refresh-design .event-copy h2 { margin: 0 0 4px; font-size: 16px; font-weight: 400; color: #d8c5a1; }
.refresh-design .event-copy p { font-size: 10px; line-height: 1.4; color: #a29175; }
.coming-soon { margin-left: auto; color: #b49b73; font-size: 9px; }
.lobby-footnote { margin: 18px 0 3px; color: #92816a; font-size: 9px; line-height: 1.5; text-align: center; }
.lobby-footnote > span { margin: 0 5px; }
.lobby-footnote button { padding: 7px 2px; border: 0; background: none; color: #c0a274; font-size: inherit; cursor: pointer; }
.refresh-design .more-list button { border-color: #8b693841; background: #c9aa7210; color: #d5c2a3; box-shadow: none; min-height: 58px; }
.refresh-design .profile-card { border-color: #8b693841; border-radius: 10px; background: #241e16; box-shadow: none; }

/* All tabs share the same active state, including Games. */
.refresh-design .mobile-nav { height: calc(70px + env(safe-area-inset-bottom)); padding: 7px 12px calc(7px + env(safe-area-inset-bottom)); align-items: center; background: #191610bd; -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); border-top: 1px solid #b8955d39; box-shadow: 0 -6px 20px #0002; }
.refresh-design .mobile-nav button,
.refresh-design .mobile-nav button.nav-game { position: relative; width: 25%; min-width: 0; min-height: 49px; height: 49px; margin: 0; padding: 5px 2px; gap: 5px; border: 0 !important; border-radius: 7px; background: transparent !important; color: #97866c; box-shadow: none !important; }
.refresh-design .mobile-nav button.active,
.refresh-design .mobile-nav button.nav-game.active { background: #d6b37b24 !important; color: #e5c48a; }
.refresh-design .mobile-nav button.active::after { content: ''; position: absolute; top: 0; left: calc(50% - 9px); width: 18px; height: 2px; border-radius: 0 0 2px 2px; background: #cfaa6d; }
.refresh-design .mobile-nav button svg,
.refresh-design .mobile-nav button.nav-game svg { width: 21px; height: 21px; padding: 0; border: 0; background: none; box-shadow: none; color: currentColor; stroke: currentColor; stroke-width: 1.6; }
.refresh-design .mobile-nav button span,
.refresh-design .mobile-nav button.nav-game span { margin: 0; font-size: 9px; color: inherit; text-shadow: none; }
.refresh-design .mobile-nav button:active { transform: none; }
.refresh-design .mobile-nav button:focus-visible { outline: 2px solid #d5ad6e; outline-offset: 1px; }
@media(min-width:480px) {
  .refresh-design #view-saloon,.refresh-design #view-games { padding-inline: 24px; }
  .refresh-design .topbar { padding-inline: 24px; }
  .home-summary { gap: 88px; }
  .refresh-design .home-profile .profile-avatar { width: 44px; height: 44px; }
  .saloon-welcome { min-height: 358px; padding: 19px; }
  .saloon-welcome-seal { top: 20px; right: 20px; }
  .refresh-design .mini-wallet { padding: 20px; }
  .refresh-design .wallet-play { min-height: 48px; padding-inline: 18px; }
  .refresh-design .game-grid { gap: 18px 16px; }
  .game-art { aspect-ratio: 1.55; }
  .game-card-copy { padding: 14px; }
  .refresh-design .game-desc { font-size: 11px; min-height: 1.4em; }
  .refresh-design .players { font-size: 10px; }
}
@media(max-width:359px) {
  .home-summary { gap: 68px; }
  .refresh-design .home-profile { gap: 7px; }
  .refresh-design .home-profile .profile-avatar { width: 33px; height: 33px; }
  .refresh-design .home-profile-copy strong { font-size: 15px; }
  .refresh-design .mini-wallet { gap: 8px; padding: 12px; }
  .refresh-design .wallet-value { font-size: 26px; }
  .saloon-welcome { min-height: 306px; padding: 11px; }
  .refresh-design .wallet-play { padding-inline: 9px; gap: 5px; }
  .refresh-design .home-profile { padding: 9px; }
  .refresh-design .game-grid { gap: 12px 10px; }
  .game-card-copy { padding: 10px 9px; }
  .refresh-design .game-desc { font-size: 9px; }
}
@media(prefers-reduced-motion:reduce) {
  .refresh-design .game-card,.refresh-design .game-art img,.refresh-design .wallet-play,.refresh-design .manage-tile { transition: none; }
}
