.tetris-page .page-description {
  margin-bottom: 1rem;
}

.tetris-layout {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 1.5rem;
  justify-content: center;
}

.tetris-side {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  min-width: 120px;
}

.tetris-panel {
  background: #0d0d0d;
  border: 1px solid #333;
  border-radius: 8px;
  padding: 0.75rem 1rem;
}

.tetris-panel h3 {
  color: #a0a0a0;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.5rem;
}

.tetris-hud {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  color: #e0e0e0;
  font-size: 1rem;
}

.tetris-hud strong {
  color: #fff;
}

.tetris-main {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  background: #0d0d0d;
}

#tetrisCanvas {
  display: block;
  background: #0d0d0d;
}

.tetris-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.8);
  transition: opacity 0.2s;
}

.tetris-overlay.hidden {
  pointer-events: none;
  opacity: 0;
}

.tetris-overlay-text {
  color: #fff;
  font-size: 1.25rem;
  margin-bottom: 1rem;
  text-align: center;
  padding: 0 1rem;
}

.tetris-restart-btn {
  padding: 0.6rem 1.25rem;
  font-size: 1rem;
  font-weight: 600;
  color: #1a1a1a;
  background: #c9a227;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}

.tetris-restart-btn:hover {
  background: #e0b83a;
}

.tetris-controls {
  margin-top: 1rem;
  padding: 0.75rem 1rem;
  background: rgba(0, 0, 0, 0.2);
  border-radius: 6px;
  color: #a0a0a0;
  font-size: 0.85rem;
  max-width: 520px;
}

.tetris-controls p {
  margin-bottom: 0.35rem;
}

.tetris-controls kbd {
  display: inline-block;
  padding: 0.15rem 0.4rem;
  background: #333;
  border-radius: 4px;
  font-family: inherit;
  font-size: 0.8em;
}

@media (max-width: 640px) {
  .tetris-layout {
    flex-direction: column;
    align-items: center;
  }
  .tetris-side {
    flex-direction: row;
    min-width: auto;
    width: 100%;
    justify-content: center;
  }
}
