@font-face {
  font-family: 'Rubik';
  font-weight: 700;
  font-display: block;
  src: url('../assets/fonts/rubik-cyrillic-700-normal.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Rubik';
  font-weight: 700;
  font-display: block;
  src: url('../assets/fonts/rubik-latin-700-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2190-2199, U+2212, U+2215;
}
@font-face {
  font-family: 'Rubik';
  font-weight: 900;
  font-display: block;
  src: url('../assets/fonts/rubik-cyrillic-900-normal.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Rubik';
  font-weight: 900;
  font-display: block;
  src: url('../assets/fonts/rubik-latin-900-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2190-2199, U+2212, U+2215;
}

html, body {
  margin: 0;
  height: 100%;
  overflow: hidden;
  background: #0d1117;
}

#game {
  display: block;
}

.testpanel {
  position: fixed;
  left: 8px;
  top: 8px;
  width: 236px;
  max-height: calc(100vh - 16px);
  overflow-y: auto;
  padding: 8px 10px 10px;
  border-radius: 12px;
  background: rgba(13, 17, 23, 0.86);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.35);
  font: 600 13px/1.2 Rubik, system-ui, sans-serif;
  color: #e6edf3;
  z-index: 10;
}

.testpanel__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-weight: 900;
  font-size: 14px;
}

.testpanel.is-closed {
  width: auto;
  padding-bottom: 8px;
}

.testpanel.is-closed .testpanel__body,
.testpanel.is-closed .testpanel__head span {
  display: none;
}

.testpanel__group {
  margin: 10px 0 5px;
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #8b97a7;
}

.testpanel__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5px;
}

.testpanel__grid .wide {
  grid-column: 1 / -1;
}

.testpanel button {
  font: inherit;
  text-align: left;
  padding: 8px 9px;
  border: 0;
  border-radius: 8px;
  background: #222b38;
  color: inherit;
  cursor: pointer;
  white-space: nowrap;
}

.testpanel button:hover {
  background: #2f3b4d;
}

.testpanel button:active {
  transform: translateY(1px);
  background: #3a4a61;
}

.testpanel .testpanel__toggle {
  padding: 5px 9px;
  font-size: 12px;
  background: #2f3b4d;
}

.testpanel__slider {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 2px 0;
  font-size: 12px;
  color: #c3ccd8;
}

.testpanel__slider input {
  flex: 1;
  min-width: 0;
  accent-color: #ff4d8d;
  cursor: pointer;
}

.testpanel__slider output {
  width: 36px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.fatal {
  position: fixed;
  inset: 0;
  margin: 0;
  padding: 16px;
  color: #ffb4b4;
  background: #1a0d0d;
  white-space: pre-wrap;
  font: 13px/1.4 monospace;
}
