/* level map */
.menu:focus {
  outline: none;
}
.menu {
  position: fixed;
  inset: 0;
  z-index: 8;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: radial-gradient(70% 38% at 50% 16%, var(--cobalt-2), transparent 72%), var(--cobalt);
}
.mwrap {
  max-width: 480px;
  margin: 0 auto;
  padding: max(16px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right))
    max(28px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
}
.mhead {
  display: flex;
  align-items: center;
  gap: 10px;
}
.mhead h2 {
  flex: 1;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: clamp(30px, 8vw, 40px);
  font-weight: 700;
  line-height: 1.05;
}
.mplay {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 18px;
}
.mplay .key {
  flex: 1;
  min-height: 52px;
  font-size: 18px;
}
.mplay span {
  flex: none;
  max-width: 44%;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.3;
  text-align: right;
}
.chap {
  margin-top: 22px;
}
.chead {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 10px;
}
.chead h3 {
  margin: 0;
  font-size: 19px;
  font-weight: 700;
}
.chead span {
  color: var(--muted);
  font-size: 14px;
}
.chead .cs {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 4px;
  color: #fff;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.chead .cs svg {
  width: 15px;
  height: 15px;
}
.strip {
  position: relative;
  width: min(100%, 448px);
  margin: 0 auto;
  aspect-ratio: 417/86;
}
.node {
  position: absolute;
  left: calc(var(--k) * 11.271%);
  top: 0;
  width: 21.103%;
  height: 67.442%;
  padding: 0;
  border: 0;
  background: none;
  color: var(--c-ink);
  font: inherit;
  cursor: pointer;
  clip-path: polygon(50% 0, 100% 44.83%, 100% 55.17%, 50% 100%, 0 55.17%, 0 44.83%);
  transition: transform 0.12s;
  touch-action: manipulation;
}
.node.odd {
  top: 32.558%;
}
.node .nb {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}
.node .sd {
  fill: var(--c-side);
}
.node .tp {
  fill: var(--c-top);
}
.node .rg {
  fill: none;
  stroke: none;
  stroke-width: 2.6;
}
.node .lab {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 89.66%;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 2px;
  pointer-events: none;
}
.node b {
  font-size: 20px;
  font-weight: 700;
  line-height: 1;
}
.node .ns {
  display: flex;
  gap: 1px;
}
.node .ns svg {
  width: 10px;
  height: 10px;
}
.node .ns .on {
  fill: var(--c-star);
}
.node .ns .off {
  fill: var(--c-off);
}
.node.cur .tp,
.node.open .tp {
  fill: var(--porcelain);
}
.node.cur .sd,
.node.open .sd {
  fill: var(--edge);
}
.node.cur b,
.node.open b {
  color: var(--deep);
}
.node.cur .rg {
  stroke: #ecc04a;
}
.node.lock {
  cursor: default;
}
.node.lock .tp {
  fill: rgba(255, 255, 255, 0.13);
}
.node.lock .sd {
  fill: rgba(255, 255, 255, 0.06);
}
.node.lock b {
  color: rgba(255, 255, 255, 0.42);
}
.node:focus-visible {
  outline: none;
}
.node:focus-visible .rg {
  stroke: #fff;
  stroke-width: 3.4;
}
@media (hover: hover) {
  .node:not(:disabled):hover {
    transform: translateY(-3px);
  }
}
.node:not(:disabled):active {
  transform: translateY(2px);
}
.endh {
  margin-top: 20px;
}
.endless {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}
.eb {
  display: grid;
  justify-items: center;
  gap: 2px;
  padding: 9px 4px 8px;
}
.eb svg {
  width: 36px;
  height: 27px;
}
.eb b {
  font-size: 16px;
  line-height: 1.1;
}
.eb span {
  font-size: 13px;
  font-weight: 500;
  color: var(--label);
  font-variant-numeric: tabular-nums;
}
.eb.on {
  background: #fff0bd;
}
@media (prefers-reduced-motion: reduce) {
  .hinting .dir,
  .next.pop .mini,
  .bigstars .st-on {
    animation: none;
  }
  .result,
  .key,
  .dir,
  .node {
    transition: none;
  }
}
