
/* Each room skin is a text-free painting. The live controls share the coordinates of its faces. */
.tower-room {
  display:grid; place-items:center; position:relative; isolation:isolate; min-height:100svh;
  font-family:-apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", system-ui, sans-serif;
  color:#271532; background:#241449 var(--surround) center / cover no-repeat;
}

.hall-room { --skin:url("rooms/hall-wide.408fc7782c8f.webp"); --surround:url("rooms/hall-room.a59b2456f2a2.webp"); }
.room-stage { position:relative; width:min(100%,150svh); aspect-ratio:3/2; container-type:inline-size; isolation:isolate; }
.room-art { position:absolute; inset:0; z-index:-1; background:var(--skin) center / contain no-repeat; }
.room-stage :is(.room-title,.room-link,.books,.week-ribbon,.my-ribbon,.score-region,.ranking-rule) {
  position:absolute; left:var(--x); top:var(--y); width:var(--w); height:var(--h);
}
.room-title,.room-link,.week-ribbon,.my-ribbon,.ranking-rule { display:flex; align-items:center; justify-content:center; }
.room-title {
  margin:0; color:#ffe7a1; font-weight:950; font-size:var(--type);
  line-height:1; letter-spacing:-.055em; white-space:nowrap;
  -webkit-text-stroke:.075em #371238; paint-order:stroke fill; text-shadow:0 .052em #fcad36,0 .09em #481747;
}
.room-link { padding:0; border:0; font:inherit; font-size:var(--type); font-weight:850; letter-spacing:-.042em; line-height:1; text-decoration:none; white-space:nowrap; background:transparent; color:#30152d; border-radius:1.5cqw; }
.room-link span { display:grid; place-items:center; position:absolute; inset:3% var(--right,4%) 12% var(--left,4%); }
.room-stage .books { display:flex; align-items:stretch; gap:0; padding:0; border:0; border-radius:0; background:transparent; }
.room-stage .books a { display:grid; place-items:center; width:50%; min-height:0; padding:0; border-radius:.55em; color:white; text-decoration:none; font-size:var(--type); font-weight:850; white-space:nowrap; line-height:1; }
.room-stage .books a[aria-current] { color:#26132b; background:transparent url("rooms/selected.2d8380ea99c0.webp") center / 100% 100% no-repeat; }
.room-stage :is(.room-link,.books a):hover { filter:brightness(1.08); text-decoration:underline; text-underline-offset:.14em; }
.room-stage :is(button,a,[tabindex]):focus-visible,.room-share:focus-visible { outline:3px solid #6cfff5; outline-offset:2px; box-shadow:0 0 0 5px #34146b; }
.room-stage button:active { translate:0 1px; }
.room-share { position:absolute; right:max(6px,env(safe-area-inset-right)); bottom:max(4px,env(safe-area-inset-bottom)); padding:.45em .8em; background:#32175d; border:1px solid #dbc8ff; border-radius:1em; font-weight:750; color:white; text-decoration:none; font-size:.83rem; }
.hall-room .room-title { --x:34.2%;--y:9%;--w:32%;--h:10.1%;--type:5.35cqw; }
.hall-room .books { --x:70.8%;--y:13.5%;--w:21.2%;--h:6.3%;--type:2.05cqw; }
.week-ribbon { --x:30%;--y:21.8%;--w:49%;--h:5.3%; gap:4%; font-size:1.67cqw; line-height:1.1; font-weight:800; letter-spacing:-.04em; white-space:nowrap; }
.reset-day { border-left:1px solid currentColor; padding-left:4%; }
.my-ribbon { --x:28.3%;--y:28.5%;--w:54.4%;--h:6.5%; color:white; font-size:2.3cqw; font-weight:850; gap:.7em; line-height:1; white-space:nowrap; }
.my-ribbon strong { color:#ffe4a8; }
.score-region { --x:27.7%;--y:36.7%;--w:56%;--h:33.35%; overflow-y:auto; overscroll-behavior:contain; scrollbar-color:#9872ce #372259; scrollbar-width:thin; border-radius:.8cqw; container-type:size; }
.scores { width:100%; border:0; border-spacing:0; border-collapse:separate; table-layout:fixed; color:#281533; font-size:2.03cqw; font-size:3.62cqi; font-variant-numeric:tabular-nums; font-weight:760; line-height:1.12; }
.scores .rank-col { width:17%; }.scores .name-col { width:35%; }.scores .floor-col { width:24%; }.scores .time-col { width:24%; }
.scores th,.scores td { padding:0 1px; border:none; text-align:center; font-size:inherit; white-space:nowrap; vertical-align:middle; }
.scores thead { position:sticky; top:0; z-index:1; }
.scores thead th { height:16.8cqh; background:#452180; color:white; font-weight:800; font-size:.92em; }
.scores tbody :is(th,td) { height:20.8cqh; border-bottom:1px solid #c6acb7; }
.scores tbody th { color:inherit; font-weight:750; letter-spacing:-.04em; }
.scores tbody .mine { color:#321533; }
.scores tbody tr[data-place="1"] { background:#ffdc75; }
.place { display:inline-grid; place-items:center; min-width:68%; min-height:1.48em; font-weight:850; white-space:nowrap; }
.scores tr:is([data-place="1"],[data-place="2"],[data-place="3"]) .place { background:var(--badge) center / 100% 100% no-repeat; }
.scores tr[data-place="1"] .place { --badge:url("rooms/rank-gold.0e67cd3523d0.webp"); }
.scores tr[data-place="2"] .place { --badge:url("rooms/rank-silver.a7d778103b8a.webp"); }
.scores tr[data-place="3"] .place { --badge:url("rooms/rank-bronze.b06f0a9a6374.webp"); }
.me { margin-left:.27em; border-radius:.25em; padding:.05em .19em; color:white; background:#5e347d; font-size:.56em; vertical-align:middle; }
.ranking-rule { --x:25.6%;--y:74%;--w:60%;--h:4.4%; font-size:max(14px,1.15cqw); font-weight:700; line-height:1.15; color:#fff5e4; }
.ranking-rule span { background:#351b51ed; border-radius:1em; padding:.32em .85em; }
.empty-board { margin-top:17cqh; height:83cqh; display:flex; align-items:center; justify-content:center; flex-direction:column; gap:.45em; text-align:center; color:#41234c; }
.empty-board h2 { font-size:5.5cqi; }.empty-board p { font-size:max(14px,3.7cqi); font-weight:600; }
.hall-room .other-room { --x:10.9%;--y:83.6%;--w:21.8%;--h:11.1%;--type:2.6cqw;--left:36%; }
.hall-room .challenge { --x:36.25%;--y:82%;--w:31.8%;--h:12.6%;--type:3.32cqw;--left:23%; }
.hall-room .entrance { --x:73.1%;--y:83.65%;--w:14.6%;--h:11.1%; }
.hall-room .entrance span { clip-path:inset(50%); }

@media (aspect-ratio > 1.55) { .room-art { mask-image:linear-gradient(to right,transparent,black 3%,black 97%,transparent); } }
@media (min-aspect-ratio:5/6) and (max-aspect-ratio:1.44) { .room-art { mask-image:linear-gradient(to bottom,transparent,black 3.5%,black 97%,transparent); } }
@media (max-aspect-ratio:5/6) {
  .room-stage { width:min(100%,56.28svh); aspect-ratio:941/1672; }

  .hall-room { --skin:url("rooms/hall-tall.3ff9f664001b.webp"); }
  .hall-room .room-title { --x:17%;--y:13.2%;--w:66%;--h:7.5%;--type:9.3cqw; }
  .hall-room .books { --x:19.5%;--y:22.9%;--w:61.3%;--h:4.25%;--type:4.6cqw; }
  .week-ribbon { --x:17.5%;--y:28%;--w:69%;--h:3.9%;gap:3%;font-size:max(14px,2.75cqw); }
  .reset-day { border:0; padding-left:3%; }
  .my-ribbon { --x:23%;--y:50%;--w:70%;--h:4.9%;font-size:4.35cqw;gap:.55em; }
  .score-region { --x:4.9%;--y:56.1%;--w:90.3%;--h:24.3%; }
  .scores { font-size:4.48cqi; }
  .scores thead th { height:17cqh; }
  .scores .rank-col { width:16%; }.scores .name-col { width:40%; }.scores .floor-col { width:17%; }.scores .time-col { width:27%; }
  .ranking-rule { --x:7%;--y:82.9%;--w:86%;--h:3.4%;font-size:max(14px,2.85cqw); }
  .ranking-rule span { padding:.15em .65em; }
  .hall-room .other-room { --x:1%;--y:86.2%;--w:24.7%;--h:11.6%;--type:4.8cqw;--left:2%; }
  .hall-room .other-room span { inset:52% 2% 9%; }
  .hall-room .challenge { --x:27%;--y:86.3%;--w:46.6%;--h:11.1%;--type:5.55cqw;--left:20%; }
  .hall-room .entrance { --x:74.9%;--y:86.2%;--w:23.5%;--h:11.5%; }
  .room-stage :is(.books a,.entrance,.other-room)::before { content:"";position:absolute; inset:-5px 0; }
  .room-stage .books a { position:relative; }
}
@media (max-aspect-ratio:.53) { .room-art { mask-image:linear-gradient(to bottom,transparent,black 2%,black 98%,transparent); } }
@media (min-aspect-ratio:.60) and (max-aspect-ratio:5/6) { .room-art { mask-image:linear-gradient(to right,transparent,black 3%,black 97%,transparent); } }
