/* ============================================================
   PHARM'ALPHA FORMATIONS — Forms
   ============================================================ */

.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--gray-700);
  margin-bottom: 6px;
}

.form-label .required {
  color: var(--red);
  margin-left: 2px;
}

.form-hint {
  font-size: 12px;
  color: var(--gray-400);
  margin-top: 4px;
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--gray-300);
  border-radius: var(--radius);
  font-family: var(--font);
  font-size: 14px;
  color: var(--gray-800);
  background: var(--white);
  transition: border-color var(--transition), box-shadow var(--transition);
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--orange);
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.1);
}

.form-input::placeholder { color: var(--gray-400); }

.form-textarea {
  resize: vertical;
  min-height: 100px;
}

.form-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236b7280' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

.form-checkbox {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
}

.form-checkbox input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: var(--orange);
  cursor: pointer;
  flex-shrink: 0;
}

.form-checkbox span {
  font-size: 14px;
  color: var(--gray-700);
  line-height: 1.5;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-row-3 {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 16px;
}

.form-section {
  margin-bottom: 32px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--gray-200);
}

.form-section-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--black);
  margin-bottom: 16px;
}

.form-error {
  border-color: var(--red) !important;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1) !important;
}

.form-error-text {
  font-size: 12px;
  color: var(--red);
  margin-top: 4px;
}

/* ---- Participant block (repeatable) ---- */
.participant-block {
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin-bottom: 16px;
  position: relative;
}

.participant-block-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.participant-block-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--gray-700);
}

.participant-remove {
  background: none;
  border: none;
  color: var(--gray-400);
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: all var(--transition);
}

.participant-remove:hover {
  color: var(--red);
  background: var(--red-light);
}

.add-participant-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 14px;
  border: 2px dashed var(--gray-300);
  border-radius: var(--radius-lg);
  background: transparent;
  color: var(--gray-500);
  font-family: var(--font);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
}

.add-participant-btn:hover {
  border-color: var(--orange);
  color: var(--orange);
  background: var(--orange-light);
}

/* ---- Quiz specific ---- */
.quiz-question {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 16px;
}

.quiz-question-number {
  font-size: 12px;
  font-weight: 700;
  color: var(--orange);
  text-transform: uppercase;
  margin-bottom: 8px;
}

.quiz-question-text {
  font-size: 15px;
  font-weight: 600;
  color: var(--black);
  margin-bottom: 16px;
  line-height: 1.5;
}

.quiz-option {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  margin-bottom: 8px;
  cursor: pointer;
  transition: all var(--transition);
}

.quiz-option:hover {
  border-color: var(--orange);
  background: var(--orange-light);
}

.quiz-option.selected {
  border-color: var(--orange);
  background: var(--orange-light);
}

.quiz-option input[type="radio"] {
  accent-color: var(--orange);
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.quiz-option label {
  font-size: 14px;
  color: var(--gray-700);
  cursor: pointer;
  flex: 1;
}

/* ---- Satisfaction specific ---- */
.likert-scale {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.likert-option {
  flex: 1;
  text-align: center;
}

.likert-option input[type="radio"] { display: none; }

.likert-option label {
  display: block;
  padding: 10px 8px;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  color: var(--gray-600);
  transition: all var(--transition);
}

.likert-option input:checked + label {
  background: var(--orange);
  color: var(--white);
  border-color: var(--orange);
}

.likert-option label:hover {
  border-color: var(--orange);
}

/* ---- Progress bar (quiz) ---- */
.progress-bar {
  width: 100%;
  height: 6px;
  background: var(--gray-200);
  border-radius: 3px;
  margin-bottom: 24px;
  overflow: hidden;
}

.progress-bar-fill {
  height: 100%;
  background: var(--orange);
  border-radius: 3px;
  transition: width 0.3s ease;
}

/* ---- Responsive forms ---- */
@media (max-width: 768px) {
  .form-row, .form-row-3 {
    grid-template-columns: 1fr;
  }

  .likert-scale {
    flex-direction: column;
  }
}
