body {
  margin: 0;
  font-family: sans-serif;
  display: flex;
  background: #121212;
  color: #fff;
  height: 100vh;
  overflow: hidden;
}
.controls {
  width: 260px;
  padding: 20px;
  background: #1e1e1e;
  display: flex;
  flex-direction: column;
  gap: 12px;
  z-index: 10;
  border-right: 1px solid #333;
  overflow-y: auto;
}
h3 {
  margin-top: 0;
  color: #aaa;
  text-transform: uppercase;
  font-size: 14px;
  letter-spacing: 1px;
  margin-bottom: 5px;
}
label {
  display: flex;
  flex-direction: column;
  font-size: 13px;
  color: #ccc;
  gap: 4px;
}
input {
  padding: 8px;
  background: #2a2a2a;
  border: 1px solid #444;
  color: #fff;
  border-radius: 4px;
  font-size: 14px;
}
input[type="range"] {
  padding: 0;
  cursor: pointer;
}

.palette-container {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 5px;
}
.palette-container input[type="color"] {
  padding: 0;
  height: 40px;
  flex: 1 1 18%;
  min-width: 30px;
  border: none;
  cursor: pointer;
  background: transparent;
}
.palette-controls {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
}
.palette-controls button {
  flex: 1;
  padding: 8px;
}

button {
  padding: 12px;
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-weight: bold;
  font-size: 14px;
  transition: background 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
#generate {
  background: #007bff;
}
#generate:hover {
  background: #0056b3;
}
.btn-download {
  background: #28a745;
  margin-top: auto;
}
.btn-download:hover {
  background: #218838;
}

.canvas-container {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  background: #0f0f0f;
}
canvas {
  max-width: 100%;
  max-height: 100%;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7);
  background: #000;
  border-radius: 4px;
}