:root {
  --smoke-glass:linear-gradient(154deg,#c4e7dd29 0%,#8eb8ae0d 26%,transparent 47%),linear-gradient(174deg,#253a38ed,#162725f5 75%,#273836f2);
  --glass-black:linear-gradient(156deg,#d5efe020,transparent 34%),linear-gradient(177deg,#273938f4,#142321f8 80%,#293a37f5);
  --glass-button:linear-gradient(158deg,#c9f3e427,transparent 44%),linear-gradient(180deg,#3d5350f5,#273c39fa 62%,#2d423efa);
  --glass-light:linear-gradient(154deg,#ffffff73,transparent 45%),linear-gradient(175deg,#b2d5c9,#8ebcaf 58%,#a8cdbf);
  --glaze-edge:#99b3a68c;
  --glaze-shadow:inset 0 1px #e4fff157,inset 1px 0 #c1ebdf20,inset 0 -1px #89aea74d,0 3px 9px #0713114a;
  --mat-felt:url('/materials/mat-filt.webp');
  --painted-steel:var(--smoke-glass);
}
body #video-dialog.jukebox,body dialog[open],
body.active-play :is(#game-info-rail,#social-rail):not([hidden]){
  background:var(--glass-black);border-color:var(--glaze-edge);box-shadow:var(--glaze-shadow)
}
body dialog[open]{box-shadow:var(--glaze-shadow),0 22px 60px #06100e88}
body #video-dialog.jukebox{border-width:1px;box-shadow:var(--glaze-shadow),0 8px 24px #06100e77}
body .jukebox :is(.juke-head,.juke-tabs,.juke-display),body.active-play :is(#game-info-rail,#social-rail) .play-panel-head,
body :is(.room-head,.room-console,.room-company,.room-chat,.local-tool,.member-record,.machine-deck,.score-filters,.room-standing li,.night-setup,.chip-tray,.pig-dashboard,.hand-lounge,.activity-bar),
body #public-page :is(.floor-game,.salon-game,.game-detail.has-cover,.activity-help[open]>div),body .crew-guide[open]{
  background:var(--smoke-glass);border-color:var(--glaze-edge);box-shadow:var(--glaze-shadow)
}
body :is(.machine,.floor-grid article,.activity-door),body #tool-menu a,body .retro-cabinet .cabinet-marquee,body .salon-index article{background:var(--smoke-glass);border-color:var(--glaze-edge);box-shadow:var(--glaze-shadow)}
body.room-screen .room-head,body .hand-header strong{background:var(--glass-button);color:#f2ebd8;border-color:var(--glaze-edge);box-shadow:var(--glaze-shadow)}
body :is(dialog,.jukebox,.activity-bar,.play-panel-head,.quick-chat,.pig-actions,.exchange-actions,.forecast-actions,.game-detail,.floor-grid,.salon-index,.table-controls,.rummy-choices,.local-tool,.night-setup) button:not(:disabled):not([role=tab]){
  background:var(--glass-button);border:1px solid var(--glaze-edge);color:#f4f3e9;box-shadow:var(--glaze-shadow)
}
body :is(dialog,.jukebox,.activity-bar,.play-panel-head,.quick-chat,.pig-actions,.exchange-actions,.forecast-actions,.table-controls,.local-tool) button:not(:disabled):not([role=tab]):active{box-shadow:inset 0 2px 3px #07151177,0 1px #bedaaf33}
body .jukebox .juke-tabs button[aria-selected=true],body dialog button[type=submit]:not(.secondary):not(:disabled){
  background:var(--glass-light);border-color:#d7ead9;color:#142923;box-shadow:var(--glaze-shadow)
}
body.activity-screen .hygge-room,body.table-screen .local-tool,
body.active-play #room-layout.with-company,body .hand-lounge .hand-stage,body .hand-lounge .hand-rail,
body .game-deck :is(.card-lounge,.salon-table,.backgammon-board),body.active-play #room .quiz-card,
body :is(.public-scoreboard,.score-marquee,.match-result,.empty-scoreboard,.night:not(.night-setup),#video-library){
  background:var(--felt-tint,#24443a) var(--mat-felt) repeat center/205px 205px;background-blend-mode:soft-light
}
body.active-play #room-layout.with-company,body.activity-screen .hygge-room,body.table-screen .local-tool{--felt-tint:#1b312a}
body :is(.quiz-card,.score-marquee,.match-result,.empty-scoreboard,.public-scoreboard,.card-lounge,.salon-table){
  border-color:#78988b;box-shadow:inset 0 0 0 1px #cbe2cf49,inset 0 2px 6px #091c165c,0 2px 6px #09141058
}
body :is(.score-marquee,.match-result,.night:not(.night-setup),.empty-scoreboard,.public-scoreboard){border-width:3px}
body :is(.score-marquee,.match-result,.night:not(.night-setup))::before,body :is(.score-marquee,.match-result,.night:not(.night-setup))::after{display:none}
body .hand-lounge .forecast-table,body .salon-table[data-kind=baccarat]{--felt-tint:#513039}
body .salon-table[data-kind=trekort]{--felt-tint:#293d48}
body .public-scoreboard tr td,body .public-scoreboard th,body .table-meta strong,body .digit-strip{border-color:#6d877c}
body .digit-strip{background:var(--glass-black);box-shadow:0 1px #cce6d752,inset 0 1px 3px #071211b3}
body :is(dialog,.jukebox,.catalog-filters,.activity-palette) :is(input:not([type=checkbox],[type=radio],[type=range],[type=color]),textarea,select){
  background:#162924ec;color:#f3eee1;border-color:#759187;box-shadow:inset 0 1px 3px #0c1714ad,0 1px #e6f6e521
}
@media(prefers-reduced-transparency:reduce){
  :root{--smoke-glass:linear-gradient(150deg,#344643,#20332f);--glass-black:linear-gradient(155deg,#2d413b,#1c2c29);--glass-button:linear-gradient(#40544d,#2a4039)}
}
@media(forced-colors:active){
  body :is(dialog,button,select,input,textarea,.playing-card){box-shadow:none}
  body .hand-header strong{background:Canvas;color:CanvasText}
}

body .hero [data-action=friend]{color:#fff5e8;background:linear-gradient(155deg,#ffd6bd42,transparent 46%),linear-gradient(174deg,#af4839,#8b342e 74%,#a24b40);border:1px solid #ce8c7c;box-shadow:var(--glaze-shadow)}

/* The paper stock follows the award into the wallet and the match result. */
.reward-slip {
  --stock-light:#f4e3b4;--stock-dark:#d8bc84;--ink:#4c3524;--press:#8b6643;--stub:clamp(68px,23%,94px);
  width:min(100%,344px);margin:0;filter:drop-shadow(0 2px 1px #10181373) drop-shadow(0 4px 4px #10181335);
}
.reward-slip[data-stock=bronze]{--stock-light:#f2cfaa;--stock-dark:#d8a078;--ink:#542c22;--press:#91563f}
.reward-slip[data-stock=silver]{--stock-light:#e1e8df;--stock-dark:#b4c8c2;--ink:#23413d;--press:#617f75}
.reward-slip[data-stock=gold]{--stock-light:#f7dfa6;--stock-dark:#e0b45d;--ink:#533915;--press:#99752b}
.reward-paper {
  position:relative;isolation:isolate;display:grid;grid-template-columns:minmax(0,1fr) var(--stub);min-height:92px;
  color:var(--ink);text-align:left;background-color:var(--stock-light);
  background-image:url('/materials/ticket-stock.webp'),linear-gradient(105deg,var(--stock-light),var(--stock-dark) 120%);
  background-size:154px 154px,100% 100%;background-blend-mode:soft-light,normal;
  clip-path:polygon(0 3%,1% 0,99% 0,100% 3%,100% 6%,99% 9%,100% 12%,100% 19%,99% 22%,100% 25%,100% 32%,99% 35%,100% 38%,100% 45%,99% 48%,100% 51%,100% 58%,99% 61%,100% 64%,100% 71%,99% 74%,100% 77%,100% 84%,99% 87%,100% 90%,100% 97%,99% 100%,1% 100%,0 97%,0 90%,1% 87%,0 84%,0 77%,1% 74%,0 71%,0 64%,1% 61%,0 58%,0 51%,1% 48%,0 45%,0 38%,1% 35%,0 32%,0 25%,1% 22%,0 19%,0 12%,1% 9%,0 6%);
  mask:radial-gradient(circle 5px at calc(100% - var(--stub)) 0,transparent 4px,#000 5px) top/100% 51% no-repeat,radial-gradient(circle 5px at calc(100% - var(--stub)) 100%,transparent 4px,#000 5px) bottom/100% 51% no-repeat;
}
.reward-paper::before {
  content:'';position:absolute;z-index:-1;inset:6px 8px;border:1px solid var(--press);border-radius:3px;
  box-shadow:inset 0 0 0 2px #f9efd547,inset 0 0 0 3px color-mix(in srgb,var(--press) 33%,transparent);
}
.reward-imprint {
  display:grid;align-content:center;justify-items:start;min-width:0;gap:1px;padding:12px clamp(13px,5%,22px);
  background:repeating-radial-gradient(ellipse 96px 52px at 112% 63%,transparent 0 8px,color-mix(in srgb,var(--press) 12%,transparent) 8.5px 9px,transparent 9.5px 12px);
}
.reward-imprint>span,.reward-imprint>small,.reward-stub>span {
  margin:0;color:var(--ink);font-family:var(--condensed,Arial,sans-serif);text-transform:uppercase;letter-spacing:.13em;
}
.reward-imprint>span{font-size:.73rem;font-weight:800;line-height:1.15;overflow-wrap:anywhere}
.reward-imprint>strong{font:700 clamp(1.25rem,4.2vw,1.68rem)/1.07 Georgia,'Times New Roman',serif;letter-spacing:-.04em;color:var(--ink);overflow-wrap:anywhere}
.reward-imprint>small{margin-top:5px;font:600 .65rem/1.1 ui-monospace,monospace;letter-spacing:.08em}
.reward-stub {
  min-width:0;display:grid;align-content:center;justify-items:center;padding:9px 8px 9px 4px;
  background:repeating-linear-gradient(to bottom,var(--press) 0 3px,#fff7 3px 4px,transparent 4px 8px) left center/1px calc(100% - 9px) no-repeat,linear-gradient(90deg,#402a181c,transparent 5px,#f7f1d72b);
}
.reward-stub>b{margin:0;color:var(--ink);font:800 clamp(1.65rem,5.6vw,2.35rem)/1 var(--condensed,Arial,sans-serif);font-variant-numeric:tabular-nums;text-shadow:0 1px #fff6}
.reward-stub>span{font-size:.72rem;font-weight:800;line-height:1.2}
.wallet-total{flex:0 0 auto;display:grid;justify-items:center;gap:4px;color:#f0e8ce}.wallet-total>small{font-size:.74rem;white-space:nowrap}
.wallet-latest{display:grid;gap:7px;margin:13px 0 18px}.wallet-latest h4{margin:0}
.wallet-ledger{margin-top:13px}.wallet-ledger>ul{list-style:none;margin:8px 0 0;padding:0}
.wallet-ledger li{display:grid;gap:7px;padding:8px 0;border-top:1px solid #8c9b8c54}
.wallet-transfer{display:flex;justify-content:space-between;gap:12px}.wallet-transfer strong{white-space:nowrap}
.wallet-ledger .reward-slip{max-width:288px}
.reward-chips{display:flex;align-items:center;justify-content:flex-start;flex-wrap:wrap;gap:10px 15px;color:inherit}
.reward-chips>span:last-child{display:grid;justify-items:start;gap:2px}.reward-chips>span:last-child small{font-size:.78rem}
.reward-chip-set{display:flex;flex-wrap:wrap;align-items:center;gap:5px}.purse-chip{display:grid;justify-items:center;gap:4px}.purse-chip>small{font-size:.72rem}
.purse-chip .salon-chip{display:grid;place-items:center;width:38px;aspect-ratio:1;background:repeating-conic-gradient(from 12deg,var(--edge) 0 12deg,var(--chip) 12deg var(--step));border:1px solid #514c40;border-radius:50%;box-shadow:inset 1px 1px 1px #fff9,inset -1px -2px 2px #0006,0 2px #413d32,0 3px 4px #15201699}
.purse-chip .salon-chip b{display:grid;place-items:center;width:73%;aspect-ratio:1;border:1px dashed #a99e86;border-radius:50%;background:radial-gradient(ellipse at 35% 25%,#fcf8e7,#dcceac);color:#343028;font:800 .95rem/1 var(--condensed,Arial,sans-serif)}
@media(forced-colors:active){.reward-slip,.reward-chips{filter:none}.reward-paper{mask:none;clip-path:none;border:2px solid CanvasText;background:Canvas;color:CanvasText}.reward-imprint>span,.reward-imprint>strong,.reward-imprint>small,.reward-stub>b,.reward-stub>span{color:CanvasText}.reward-stub{border-left:1px dashed CanvasText}}
body .hero :is(.secondary,[data-action=to-catalog]){background:var(--glass-button);color:#f3efe3;border-color:var(--glaze-edge);box-shadow:var(--glaze-shadow)}

#intro .hero{
  display:grid;grid-template-columns:minmax(0,.95fr) minmax(0,1.05fr);gap:0;min-height:0;padding:0;
  overflow:hidden;border-color:#49615c;background:radial-gradient(ellipse at 78% 72%,#123537,#0b2528 49%,#101f20 93%)
}
#intro .hero-copy{grid-area:1/1;width:100%;max-width:600px;padding:clamp(24px,3.4vw,52px)}
.hall-hero-art{grid-area:1/2;position:relative;display:block;width:min(100%,clamp(425px,44.375vw,650px));height:clamp(340px,35.5vw,520px);place-self:center;overflow:hidden}
.hall-hero-art img{display:block;width:100%;height:100%;object-fit:contain;mask-image:linear-gradient(90deg,transparent,#000 5%,#000 97%,transparent)}
@media(max-width:680px){
  #intro .hero{grid-template-columns:1fr}
  #intro .hero-copy{padding:22px 20px 9px}
  .hall-hero-art{grid-area:2/1;height:auto;width:min(100%,440px);aspect-ratio:732/614;justify-self:center}
  .hall-hero-art img{mask-image:linear-gradient(180deg,transparent,#000 2.5%,#000 98.5%,transparent)}
  #intro.entry-open .hall-hero-art{display:none}
}

/* The fixed house navigation shares its gutter with the game and floor pages. */
body #app-header,body #app-footer{
  --hall-gutter:max(clamp(20px,3.6vw,56px),calc((100% - 1328px)/2),env(safe-area-inset-left),env(safe-area-inset-right));
  padding-inline:var(--hall-gutter);
  background:linear-gradient(175deg,#202c2b,#182322 88%);
  border-color:#a5b8a829;box-shadow:none
}
body #app-header{min-height:60px}
#app-header .brand{font:800 1.47rem/1 var(--condensed);letter-spacing:.01em;text-transform:none;gap:9px}
#app-header .brand img{width:32px;height:32px;box-shadow:none;border-color:#d3c5a449}
#app-header #floor-nav{column-gap:clamp(4px,1.15vw,19px)}
#floor-nav a:has(>small){font-weight:600}
#floor-nav a>small{color:#b5aa91;letter-spacing:.09em}
#app-header #floor-nav a[aria-current]{color:#f5dcac}
#app-header #floor-nav a[aria-current]::after{
  content:"";position:absolute;inset:auto 5px 0;height:2px;background:#dcb777
}
#hall-utilities{gap:clamp(5px,.65vw,10px)}
#hall-pages-links{display:flex;align-items:center;gap:1px}
#hall-pages-button{display:none}
#hall-utilities :is(#scores-nav,#admin-nav,#return-room,#account-button,#master-switch){
  min-height:36px;padding:6px 9px;border:1px solid transparent;border-radius:7px;
  box-shadow:none;text-decoration:none;
  font:600 .83rem/1.15 system-ui,sans-serif;white-space:nowrap
}
#hall-utilities #scores-nav,#hall-utilities #admin-nav {color:#dce2db;background:transparent}
#hall-utilities #return-room {color:#dce2db;background:#1c2827}
#hall-utilities #master-switch{
  background:linear-gradient(#f1dcaf,#dfc391);color:#30291d;border-color:#e4c79c
}
#hall-utilities #account-button{color:#dce2db;border-color:#a4b4a53b;background:#24302e}
#hall-utilities :is(#scores-nav,#admin-nav,#return-room,#account-button):is(:hover,:focus-visible,[aria-current]){
  background:#293633;color:#fff3db
}
#hall-utilities #master-switch:hover{background:#f6dfb4}
body #app-footer{
  min-height:45px;padding-block:4px max(4px,env(safe-area-inset-bottom));gap:4px 14px;
  color:#bbc7c0;background:#182221;font:500 .76rem/1.25 system-ui,sans-serif
}
#app-footer :is(#account-status,#room-status):empty{display:none}
#app-footer #connection-status{display:inline-flex;gap:7px;align-items:center;color:#c0c9c3;white-space:nowrap}
#connection-status::before{content:"";width:7px;height:7px;border:1px solid #9ba69f;border-radius:50%}
#connection-status[data-connected=true]::before{background:#a4cf9c;border-color:#a4cf9c}
#app-footer #open-video,#app-footer #sound-button{
  min-height:34px;padding:4px 11px;border:1px solid #a6b3a82c;border-radius:7px;
  background:#1d2826;box-shadow:none;font:600 .77rem/1.2 system-ui,sans-serif;white-space:nowrap;flex-shrink:0
}
#app-footer #open-video{color:#f1d7a8}
#app-footer #sound-button{color:#e2e6df}
#app-footer :is(#open-video,#sound-button):hover{background:#27322f}
@media(min-width:900px){
  body #app-header{grid-template-columns:auto minmax(0,1fr) auto;gap:clamp(12px,2vw,36px)}
  #hall-pages-links{padding-inline-end:6px;margin-inline-end:1px;border-inline-end:1px solid #ccd5c829}
}
@media(min-width:900px) and (max-width:1150px){
  body #app-header{--hall-gutter:16px;gap:8px}
  #app-header #floor-nav{column-gap:4px}
  #app-header #floor-nav a{padding-inline:2px}
  #app-header .brand{font-size:1.22rem;gap:6px}
  #hall-utilities{gap:1px}
  #hall-utilities :is(#scores-nav,#admin-nav,#return-room,#account-button,#master-switch){padding-inline:6px;font-size:.79rem}
}
@media(max-width:899px){
  body #app-header,body #app-footer{--hall-gutter:max(10px,env(safe-area-inset-left),env(safe-area-inset-right))}
  #app-header{row-gap:0}
  #app-header .brand{font-size:1.2rem;gap:6px}
  #app-header .brand img{width:27px;height:27px}
  #app-header #floor-nav{column-gap:0}
  #hall-utilities{gap:3px;padding-block:3px}
  #hall-utilities :is(#account-button,#return-room,#master-switch){min-height:34px;padding:4px 7px;font-size:.77rem}
  .hall-pages{position:relative}
  #hall-pages-button{
    display:grid;place-items:center;min-height:36px;min-width:32px;padding:0;border:0;
    border-radius:6px;background:#1d2928;color:#dce2db;box-shadow:none;font:700 .82rem/1 system-ui,sans-serif;letter-spacing:1px
  }
  #hall-pages-button[aria-expanded=true]{background:#2c3836}
  #hall-pages-links{
    display:none;position:absolute;z-index:1;top:100%;inset-inline-end:0;min-width:136px;padding:5px;
    border:1px solid #62716b;border-radius:9px;background:#24312f;box-shadow:0 9px 20px #07120f59
  }
  #hall-pages-button[aria-expanded=true]+#hall-pages-links{display:grid}
  #hall-utilities #hall-pages-links a{justify-content:flex-start;min-height:40px;font-size:.86rem}
}
@media(max-width:620px){
  body:not(.active-play,.table-screen,.activity-screen) #app-footer{flex-wrap:nowrap;gap:6px}
  body:not(.active-play,.table-screen,.activity-screen) #app-footer #room-status{
    white-space:nowrap;min-width:0;overflow:hidden;text-overflow:ellipsis
  }
  body:not(.active-play,.table-screen,.activity-screen) #account-status{display:none}
  body:not(.active-play,.table-screen,.activity-screen) #play-status{display:none}
  #app-footer #footer-message:not(:empty){position:absolute;bottom:100%;left:0;right:0;padding:6px 12px;background:#26332d}
}
@media(max-width:370px){
  #app-header:has(#master-switch:not([hidden])) .brand span{display:none}
  #app-header #floor-nav{grid-template-columns:repeat(5,minmax(0,1fr)) minmax(0,1.42fr)}
  body #app-footer #sound-button,body #app-footer #open-video{padding-inline:7px}
  body.active-play #app-footer{gap:2px 4px;padding-inline:5px}
  body.active-play #play-panel-actions{gap:3px}
  body.active-play #app-footer button{padding-inline:5px}
  body.active-play #app-footer #open-video{margin-left:0}
}
@media(max-width:479px){
  #hall-utilities:has(#master-switch:not([hidden])) #hall-pages-links{inset-inline-start:0;inset-inline-end:auto}
}
@media(min-width:371px) and (max-width:415px){
  #hall-utilities{gap:1px}
  #hall-utilities :is(#master-switch,#return-room,#account-button){padding-inline:5px}
}
@media(min-width:371px) and (max-width:379px){
  #app-header:has(#master-switch:not([hidden])) .brand{gap:4px;font-size:1.03rem}
}
@media(min-width:580px) and (orientation:landscape) and (max-height:540px){
  body:is(.active-play,.activity-screen,.table-screen) #app-header,body:is(.active-play,.activity-screen,.table-screen) #app-footer{min-height:0}
  body:is(.active-play,.activity-screen,.table-screen) #hall-utilities{padding-block:0}
}
