/* ===============================
   Main Form Wrapper
=============================== */
#custom-jewelry-form {
  max-width: 100%;
  margin: 0 auto;
  font-family: Arial, sans-serif;
}

/* ===============================
   Rows & Inputs
=============================== */
#custom-jewelry-form .form-row,
#custom-jewelry-form .form-footer {
  margin-top: 15px;
}

#custom-jewelry-form input,
#custom-jewelry-form select,
#custom-jewelry-form textarea {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 14px;
  box-sizing: border-box;
}

#custom-jewelry-form textarea {
  resize: vertical;
}

/* ===============================
   Repeater Item Box
=============================== */
.repeater-item {
  position: relative;
  background: #fafafa;
  padding: 35px 20px 25px;
  border: 1px solid #e1e1e1;
  border-radius: 6px;
  margin-bottom: 20px;
  margin-top: 20px;
}

/* ===============================
   Remove Icon
=============================== */
.remove-icon {
  position: absolute;
  top: 8px;
  right: 8px;
  font-size: 18px;
  font-weight: bold;
  color: #dc3545;
  cursor: pointer;
  transition: transform 0.2s ease, color 0.2s ease;
}

.remove-icon:hover {
  transform: scale(1.2);
  color: #b02a37;
}

/* ===============================
   FORM GRID (Category | Fields)
=============================== */
#custom-jewelry-form .form-grid {
  display: grid;
  grid-template-columns: 220px 1fr; /* Category | Fields */
  gap: 15px;
  align-items: start;
}

/* Category dropdown column */
#custom-jewelry-form .grid-item {
  width: 100%;
}

/* ===============================
   Dynamic Fields (RIGHT SIDE)
=============================== */
#custom-jewelry-form .dynamic-fields {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

#custom-jewelry-form .dynamic-fields input,
#custom-jewelry-form .dynamic-fields select {
  width: 100%;
}

/* ===============================
   Instruction Textarea
=============================== */
#custom-jewelry-form textarea.custom-textarea {
  height: 80px;
  min-height: 80px;
  max-height: 140px;
  margin-top: 15px;
}

/* ===============================
   Buttons
=============================== */
#custom-jewelry-form .form-footer {
  display: flex;
  gap: 10px;
}

#custom-jewelry-form button {
  padding: 10px 18px;
  border: none;
  border-radius: 4px;
  font-size: 14px;
  cursor: pointer;
}

#add-row {
  background: #6c757d;
  color: #fff;
}

#add-row:hover {
  background: #5a6268;
}

#custom-jewelry-form button[type="submit"] {
  background: #007bff;
  color: #fff;
}

#custom-jewelry-form button[type="submit"]:hover {
  background: #0056b3;
}

/* ===============================
   Readonly Fields
=============================== */
#custom-jewelry-form input[readonly] {
  background: #f1f1f1;
  cursor: not-allowed;
}

/* ===============================
   Responsive (Mobile)
=============================== */
@media (max-width: 768px) {

  #custom-jewelry-form .form-grid {
    grid-template-columns: 1fr;
  }

  #custom-jewelry-form .dynamic-fields {
    grid-template-columns: 1fr;
  }

  #custom-jewelry-form .form-footer {
    flex-direction: column;
  }
}
