* { box-sizing: border-box; }
html, body { margin: 0; background: #111; color: #ddd;
  font: 15px/1.4 system-ui, -apple-system, "Segoe UI", sans-serif; }
main { max-width: 980px; margin: 0 auto; padding: 12px 8px; text-align: center; }
h1 { margin: 4px 0 12px; font-size: 22px; color: #ffd800; }
h1 small { color: #aaa; font-size: 14px; font-weight: normal; }
h2 { font-size: 16px; margin: 0 0 6px; color: #ffd800; }

#screen-wrap { position: relative; display: inline-block; background: #000;
  min-width: 320px; min-height: 240px; line-height: 0; }
#jsspeccy canvas { image-rendering: pixelated; image-rendering: crisp-edges; display: block; }
#start { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; cursor: pointer;
  background: rgba(0,0,0,.75); color: #fff; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 8px; font: inherit; line-height: 1.3; padding: 12px; }
#start .big { font-size: 26px; font-weight: bold; color: #ffd800; }
#start .small { font-size: 14px; color: #bbb; }
#start:hover .big, #start:focus .big { text-decoration: underline; }
#status { position: absolute; left: 0; right: 0; bottom: 0; padding: 8px; line-height: 1.3;
  background: rgba(160,0,0,.9); color: #fff; font-size: 14px; }

#buttons { margin: 14px auto 6px; max-width: 760px; }
.group { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-bottom: 10px; }
.group-title { width: 100%; font-size: 12px; text-transform: uppercase; letter-spacing: .1em; color: #888; }
.btn { min-width: 84px; min-height: 52px; padding: 6px 10px; border-radius: 8px;
  border: 2px solid #666; background: #2a2a2a; color: #fff; font: bold 16px/1.1 system-ui, -apple-system, "Segoe UI", sans-serif;
  touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; cursor: pointer; }
.btn .k { display: block; font-size: 11px; font-weight: normal; color: #aaa; margin-top: 2px; }
.group[data-group="mode"] .btn { border-color: #3a6fd8; }
.btn.down { background: #ffd800; color: #000; border-color: #ffd800; }
.btn.down .k { color: #333; }

#guide { margin: 14px auto 0; max-width: 520px; text-align: left; }
#guide table { width: 100%; border-collapse: collapse; }
#guide th, #guide td { padding: 4px 8px; border-bottom: 1px solid #333; }
#guide th { color: #999; font-weight: normal; text-align: left; }
#guide td.key { font: bold 15px ui-monospace, Menlo, Consolas, monospace; color: #ffd800; }
#guide .note { color: #999; font-size: 13px; }
footer { text-align: center; color: #888; font-size: 13px; padding: 18px 8px 24px; }
footer a { color: #aac8ff; }
