/* metaeden-net/public/met-hiscore.css  (TASK-1728[Q])
   ==========================================================================
   THE ARCADE HIGH SCORE PANEL, TABLE AND ATTRACT CARD (met-hiscore.js,
   met-hiscore.entry.js).  One structure for every game; a game themes it
   through the --mhs-* custom properties, which met-hiscore.js writes inline
   from the game's theme after holding every readable pair at 4.5:1.  The
   defaults below are the same numbers as DEFAULT_THEME there.

   Text is 12px or larger everywhere a player reads it.  States never move
   layout: the lit slot's border is reserved transparent and only coloured.
   The panel is a FIXED size and the table a fixed ten rows that scroll inside
   their own frame.  The overlay is at z-index 1000003, the top of the open
   COVERS band (browser-frame.css, THE Z SCALE): it is raised from inside an
   open arcade cabinet, which sits at 1000001.
   ========================================================================== */
.mhs-scope {
  --mhs-backdrop: rgba(2, 8, 12, 0.82);
  --mhs-bg: #061218;
  --mhs-fg: #d8fbff;
  --mhs-dim: #9ec8cf;
  --mhs-accent: #ffdd00;
  --mhs-hi-bg: #ffdd00;
  --mhs-hi-fg: #061218;
  --mhs-key-bg: #10303a;
  --mhs-key-fg: #d8fbff;
  --mhs-border: #00f8ff;
  --mhs-font: 'IBM Plex Mono', 'Courier New', monospace;
  --mhs-font-head: 'Bebas Neue', 'IBM Plex Mono', monospace;
  --mhs-radius: 6px;
  --mhs-frame: solid;
}
.mhs-scope [hidden], .mhs-scope[hidden] { display: none !important; }
.mhs-scope h2, .mhs-scope p, .mhs-scope table, .mhs-scope th, .mhs-scope td, .mhs-scope button {
  font-variant: normal; text-transform: none; text-shadow: none; box-shadow: none;
}
.mhs-scope table, .mhs-scope th, .mhs-scope td { background: transparent; border: 0; }

.mhs-scope.mhs-overlay {
  position: fixed; inset: 0; z-index: 1000003;
  display: flex; align-items: center; justify-content: center;
  padding: 8px; box-sizing: border-box;
  background: var(--mhs-backdrop);
}
.mhs-scope .mhs-panel {
  width: min(460px, 100%); height: min(580px, calc(100vh - 16px));
  box-sizing: border-box; display: flex; flex-direction: column;
  padding: 14px 16px 12px; overflow: hidden;
  background: var(--mhs-bg); color: var(--mhs-fg);
  border: 3px var(--mhs-frame) var(--mhs-border); border-radius: var(--mhs-radius);
  font: 14px/1.35 var(--mhs-font);
}
.mhs-scope .mhs-head {
  margin: 0; height: 26px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis;
  text-align: center; font: 22px/26px var(--mhs-font-head); letter-spacing: 1px; color: var(--mhs-fg);
}
.mhs-scope .mhs-big {
  margin: 6px 0 0; height: 28px; text-align: center; white-space: nowrap; overflow: hidden;
  font: 700 20px/28px var(--mhs-font-head); letter-spacing: 2px; color: var(--mhs-accent);
}
.mhs-scope .mhs-yours { margin: 0; height: 20px; text-align: center; font-size: 14px; color: var(--mhs-dim); }
.mhs-scope .mhs-entry, .mhs-scope .mhs-board { flex: 1 1 auto; min-height: 0; overflow-y: auto; margin-top: 8px; }
.mhs-scope .mhs-prompt { margin: 0 0 6px; text-align: center; font-size: 13px; color: var(--mhs-dim); }

.mhs-scope .mhs-slots { display: flex; justify-content: center; gap: 14px; }
.mhs-scope .mhs-slot {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 4px; border: 2px solid transparent; border-radius: var(--mhs-radius);
}
.mhs-scope .mhs-slot.mhs-cur { border-color: var(--mhs-accent); }
.mhs-scope .mhs-ch {
  width: 56px; height: 62px; padding: 0; cursor: pointer; touch-action: none;
  font: 40px/62px var(--mhs-font-head); text-align: center;
  background: var(--mhs-key-bg); color: var(--mhs-key-fg); border: 1px solid var(--mhs-border); border-radius: 4px;
}
.mhs-scope .mhs-arrow {
  width: 56px; height: 28px; padding: 0; cursor: pointer;
  font: 700 14px/26px var(--mhs-font); background: var(--mhs-key-bg); color: var(--mhs-key-fg);
  border: 1px solid var(--mhs-border); border-radius: 4px;
}
.mhs-scope .mhs-hint { margin: 6px 0; text-align: center; font-size: 12px; color: var(--mhs-dim); }
.mhs-scope .mhs-keys { display: grid; grid-template-columns: repeat(9, 1fr); gap: 4px; }
.mhs-scope .mhs-key {
  height: 32px; padding: 0; cursor: pointer;
  font: 700 14px/30px var(--mhs-font); background: var(--mhs-key-bg); color: var(--mhs-key-fg);
  border: 1px solid var(--mhs-border); border-radius: 3px;
}
.mhs-scope .mhs-key-wide { grid-column: span 2; }
.mhs-scope .mhs-key-ok { background: var(--mhs-hi-bg); color: var(--mhs-hi-fg); }

.mhs-scope .mhs-tablebox { height: 275px; overflow-y: auto; }
.mhs-scope .mhs-table { width: 100%; border-collapse: collapse; table-layout: fixed; font: 14px var(--mhs-font); }
.mhs-scope .mhs-table th, .mhs-scope .mhs-table td {
  height: 24px; padding: 0 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-align: left;
}
.mhs-scope .mhs-headrow th { font: 700 12px var(--mhs-font); letter-spacing: 1px; color: var(--mhs-dim); border-bottom: 1px solid var(--mhs-border); }
.mhs-scope .mhs-table .mhs-c0 { width: 2.4em; color: var(--mhs-dim); }
.mhs-scope .mhs-table .mhs-c2 { width: 6.6em; text-align: right; }
.mhs-scope .mhs-table .mhs-c3 { width: 4.4em; text-align: right; color: var(--mhs-dim); font-size: 12px; }
.mhs-scope .mhs-ini { font-weight: 700; letter-spacing: 2px; }
.mhs-scope .mhs-handle { font-size: 12px; color: var(--mhs-dim); }
.mhs-scope .mhs-sprite { width: 16px; height: 16px; margin: 0 4px 0 6px; vertical-align: -3px; image-rendering: pixelated; }
.mhs-scope .mhs-blank td { color: var(--mhs-dim); }
.mhs-scope .mhs-you .mhs-ini { text-decoration: underline; text-underline-offset: 3px; }
.mhs-scope .mhs-table tr.mhs-lit td, .mhs-scope .mhs-table tr.mhs-lit .mhs-handle { background: var(--mhs-hi-bg); color: var(--mhs-hi-fg); }
.mhs-scope .mhs-tablenote { margin: 6px 0 0; height: 18px; font-size: 13px; color: var(--mhs-dim); }

.mhs-scope .mhs-status { margin: 6px 0 0; height: 36px; overflow: hidden; text-align: center; font-size: 13px; color: var(--mhs-fg); }
.mhs-scope .mhs-acts { display: flex; justify-content: center; gap: 10px; margin-top: 4px; }
.mhs-scope .mhs-btn {
  min-width: 104px; height: 36px; padding: 0 14px; cursor: pointer;
  font: 700 14px var(--mhs-font); letter-spacing: 1px;
  background: var(--mhs-key-bg); color: var(--mhs-key-fg); border: 1px solid var(--mhs-border); border-radius: 4px;
}
.mhs-scope .mhs-btn-go { background: var(--mhs-hi-bg); color: var(--mhs-hi-fg); }
.mhs-scope button:focus-visible { outline: 2px solid var(--mhs-accent); outline-offset: 2px; }

/* THE ATTRACT CARD a title screen mounts: one board's top five, centred over
   the title, shown and hidden in turn with the demo behind it. */
.mhs-scope.mhs-attract {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 5;
  width: min(340px, 92%); box-sizing: border-box; padding: 10px 14px 12px;
  background: var(--mhs-bg); color: var(--mhs-fg);
  border: 3px var(--mhs-frame) var(--mhs-border); border-radius: var(--mhs-radius);
  font: 14px/1.3 var(--mhs-font); pointer-events: none;
}
.mhs-scope .mhs-attract-head { margin: 0; text-align: center; font: 24px/1.1 var(--mhs-font-head); letter-spacing: 3px; color: var(--mhs-accent); }
.mhs-scope .mhs-attract-board { margin: 2px 0 6px; height: 18px; text-align: center; font-size: 13px; color: var(--mhs-dim); }
.mhs-scope.mhs-attract .mhs-tablebox { height: 150px; overflow: hidden; }

@media (max-width: 480px) {
  .mhs-scope .mhs-panel { padding: 10px 10px 8px; }
  .mhs-scope .mhs-ch { width: 50px; height: 56px; font-size: 36px; line-height: 56px; }
  .mhs-scope .mhs-arrow { width: 50px; height: 30px; }
  .mhs-scope .mhs-key { height: 34px; }
  .mhs-scope .mhs-table .mhs-c3, .mhs-scope .mhs-handle { display: none; }
}
