:root {
  color-scheme: dark;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  background: #050807;
  color: #dfffd2;
}

* {
  box-sizing: border-box;
}

body {
  display: grid;
  place-items: center;
  min-height: 100vh;
  margin: 0;
  padding: 18px;
  background: #050807;
}

.terminal {
  width: min(1180px, 100%);
  background: #07110d;
  border: 1px solid #346447;
  box-shadow: 0 0 0 1px #102419, 0 24px 70px rgba(0, 0, 0, 0.7);
}

.terminal-bar {
  display: grid;
  grid-template-columns: 84px 1fr auto;
  align-items: center;
  gap: 12px;
  min-height: 38px;
  padding: 0 12px;
  border-bottom: 1px solid #23452f;
  background: #0c1712;
  color: #84d39c;
  font-size: 13px;
}

.window-dots {
  display: flex;
  gap: 8px;
}

.window-dots span {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #28523a;
}

.window-dots span:nth-child(1) {
  background: #d75a54;
}

.window-dots span:nth-child(2) {
  background: #d7ba54;
}

.window-dots span:nth-child(3) {
  background: #55c56f;
}

.terminal-title {
  overflow: hidden;
  color: #dfffd2;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.terminal-bar a {
  color: #84d39c;
  text-decoration: none;
}

.terminal-bar a:hover {
  color: #dfffd2;
}

.screen {
  position: relative;
  background: #050807;
  padding: 10px;
}

canvas {
  display: block;
  width: 100%;
  max-height: calc(100vh - 180px);
  aspect-ratio: 3 / 2;
  background: #050807;
  image-rendering: pixelated;
}

.tools-panel,
.pop-badge,
.status-panel {
  position: absolute;
  background: rgba(7, 17, 13, 0.9);
  border: 1px solid #346447;
  color: #dfffd2;
  font-size: 14px;
}

.panel-title {
  position: absolute;
  top: -11px;
  left: 12px;
  padding: 0 6px;
  background: #07110d;
  color: #3aa768;
}

.tools-panel {
  top: 22px;
  left: 22px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  width: 126px;
  padding: 18px 10px 10px;
}

.tools-panel p {
  margin: 0;
  color: #dfffd2;
}

.pop-badge {
  top: 22px;
  right: 22px;
  display: grid;
  place-items: center;
  min-width: 76px;
  padding: 12px 8px 10px;
  background: rgba(154, 186, 88, 0.9);
  border-color: #1b3825;
  color: #10180d;
}

.pop-badge span {
  color: #fff;
  font-weight: 700;
}

.pop-badge strong {
  color: #e8ff72;
  font-size: 24px;
}

.status-panel {
  left: 22px;
  right: 22px;
  bottom: 22px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  min-height: 46px;
  padding: 17px 12px 10px;
  align-items: center;
}

.status-panel b,
#status,
#speed {
  color: #e8ff72;
  font-weight: 700;
}

.demo-note {
  color: #84d39c;
}

button {
  min-height: 22px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #dfffd2;
  font: inherit;
  font-size: 13px;
  text-align: left;
  cursor: pointer;
}

button span {
  color: #23d9ff;
}

button:hover {
  color: #e8ff72;
}

@media (max-width: 760px) {
  body {
    padding: 0;
  }

  .terminal {
    min-height: 100vh;
    border: 0;
  }

  .terminal-bar {
    grid-template-columns: 64px 1fr auto;
  }

  .screen {
    padding: 0;
  }

  canvas {
    max-height: none;
  }

  .tools-panel {
    top: 12px;
    left: 12px;
    width: 108px;
    font-size: 12px;
  }

  .pop-badge {
    top: 12px;
    right: 12px;
    min-width: 62px;
    font-size: 12px;
  }

  .status-panel {
    left: 12px;
    right: 12px;
    bottom: 12px;
    font-size: 12px;
  }
}
