* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  min-height: 100%;
  background: #101722;
  color: #eaf2f8;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body {
  display: flex;
  justify-content: center;
  padding: 20px;
}

.game-shell {
  width: min(1900px, 100%);
}

.game-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 20px;
  margin-bottom: 14px;
}

h1 {
  margin: 0;
  font-size: 2rem;
}

.game-header p {
  margin: 4px 0 0;
  color: #9fb0c1;
}

.status {
  display: flex;
  gap: 18px;
  color: #c8d5e1;
  font-size: 0.95rem;
  white-space: nowrap;
}

.game-area {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  min-height: 520px;
  overflow: hidden;
  border: 2px solid #344454;
  border-radius: 12px;
  background: #b8d9e8;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.3);
}

canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.message {
  position: absolute;
  left: 50%;
  top: 18px;
  transform: translateX(-50%);
  padding: 10px 16px;
  border-radius: 999px;
  background: rgba(16, 23, 34, 0.88);
  color: white;
  font-weight: 600;
  pointer-events: none;
}

.controls {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  margin-top: 14px;
  color: #b9c8d5;
  font-size: 0.95rem;
}

kbd {
  display: inline-flex;
  min-width: 28px;
  height: 28px;
  justify-content: center;
  align-items: center;
  padding: 0 7px;
  margin-right: 5px;
  border: 1px solid #536575;
  border-bottom-width: 3px;
  border-radius: 6px;
  background: #263342;
  color: #fff;
  font-weight: 700;
}

.hint {
  margin-left: auto;
  color: #8193a4;
}

@media (max-width: 700px) {
  body {
    padding: 10px;
  }

  .game-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .status {
    white-space: normal;
  }

  .game-area {
    min-height: 300px;
  }

  .hint {
    width: 100%;
    margin-left: 0;
  }
}
