/* ===== RESET ===== */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ===== BASE ===== */
body {
  font-family: Arial, sans-serif;
  background: #f8f6f3;
  color: #2f2a26;
  line-height: 1.5;
}

h1, h2, h3, h4 {
  margin-bottom: 10px;
}

/* ===== LAYOUT ===== */
.container {
  width: min(960px, 92%);
  margin: 32px auto;
}

/* ===== COMPONENTS ===== */

/* Cards */
.card {
  background: #fff;
  border: 1px solid #e7dfd7;
  border-radius: 16px;
  padding: 20px;
  margin-bottom: 18px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.05);
}

/* Inputs */
label {
  display: block;
  margin: 12px 0 6px;
  font-weight: 600;
}

input,
select {
  width: 100%;
  max-width: 280px;
  padding: 10px 12px;
  border: 1px solid #d6cec6;
  border-radius: 10px;
  background: #fff;
  font: inherit;
}

/* Buttons */
button {
  cursor: pointer;
  border: 1px solid #d6cec6;
  background: #fff;
  border-radius: 999px;
  padding: 10px 16px;
  font: inherit;
  transition: 0.15s ease;
}

button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

button:hover {
  transform: translateY(-1px);
}

#generateBtn {
  background: #2f2a26;
  color: #fff;
  border-color: #2f2a26;
}

/* Button group */
.action-group {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

/* Palette */
.palette-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.palette-btn.active {
  border-color: #8b5e83;
  background: #f3e8f1;
  font-weight: 700;
}

/* Image preview */
.image-preview {
  margin-top: 12px;
}

.image-preview img {
  max-width: 100%;
  border-radius: 12px;
}

/* Pattern grid */
#patternGrid {
  margin-top: 12px;
  overflow-x: auto;
}

/* Instructions */
#writtenInstructions {
  margin-top: 18px;
}

/* Status message */
.status-message {
  margin-top: 12px;
  padding: 12px;
  border-radius: 10px;
}

/* Helper text */
.helper {
  color: #6b625b;
  font-size: 14px;
}
