/* =========================================================
   Child Education Donation Manager – Frontend Styles
   Two-step flow inspired by common NGO donation UX
   Loaded only when [cedm_donation_form] shortcode is present
   ========================================================= */

.cedm-wrap {
  max-width: 900px;
  margin: 24px auto;
  padding: 24px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.04);
  font-family: -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Oxygen,Ubuntu,Cantarell,"Helvetica Neue",Arial,sans-serif;
}

.cedm-row {
  margin-bottom: 14px;
}

.cedm-row label {
  display: block;
  margin-bottom: 6px;
  font-weight: 600;
  font-size: 14px;
  color: #111827;
}

.cedm-row input[type="text"],
.cedm-row input[type="email"],
.cedm-row input[type="number"],
.cedm-row select {
  width: 100%;
  padding: 12px 12px;
  border: 1px solid #d1d5db;
  border-radius: 10px;
  font-size: 14px;
  background: #fff;
  box-sizing: border-box;
}

.cedm-row input:focus,
.cedm-row select:focus {
  outline: none;
  border-color: #22c55e;
  box-shadow: 0 0 0 3px rgba(34,197,94,0.15);
}

/* Amount input with visible currency symbol */
.cedm-amount-input {
  display: flex;
  align-items: center;
  gap: 10px;
}

.cedm-currency-symbol {
  min-width: 28px;
  padding: 0 10px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #d1d5db;
  border-radius: 10px;
  background: #f9fafb;
  font-weight: 700;
  color: #111827;
}

.cedm-amount-input input[type="number"] {
  flex: 1;
}

.cedm-toggle-row {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

/* Impact copy block above amount selector */
.cedm-impact {
  border: 1px solid #e5e7eb;
  background: #f9fafb;
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 14px;
}

.cedm-impact-title {
  margin: 0 0 6px 0;
  font-size: 18px;
  line-height: 1.2;
  color: #111827;
}

.cedm-impact-subtitle {
  margin: 0 0 10px 0;
  font-size: 14px;
  color: #374151;
}

.cedm-impact-list {
  margin: 0 0 10px 18px;
  padding: 0;
  color: #111827;
}

.cedm-impact-list li {
  margin: 4px 0;
  font-size: 13.5px;
  color: #111827;
}

.cedm-impact-trust {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 12.5px;
  color: #4b5563;
}

.cedm-impact-trust .cedm-dot {
  opacity: 0.6;
}

.cedm-toggle {
  display: flex;
  gap: 16px;
  align-items: center;
}

.cedm-radio {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  font-weight: 600;
  cursor: pointer;
  user-select: none;
}

.cedm-radio input { transform: scale(1.1); }

.cedm-currency {
  min-width: 260px;
}

.cedm-amount-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.cedm-preset {
  width: 100%;
  padding: 12px;
  border: 1px solid #d1d5db;
  border-radius: 10px;
  background: #fff;
  font-weight: 700;
  cursor: pointer;
}

.cedm-preset.is-selected {
  border-color: #22c55e;
  box-shadow: 0 0 0 3px rgba(34,197,94,0.15);
}

.cedm-btn {
  display: inline-block;
  width: 100%;
  padding: 14px;
  border: none;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}

.cedm-btn-primary {
  background: #22c55e;
  color: #fff;
}

/* Inline validation errors */
.cedm-field-error {
  color: #d32f2f;
  font-size: 12px;
  line-height: 1.2;
  margin-top: 6px;
}

.cedm-name-row {
  display: flex;
  gap: 14px;
}

.cedm-name-row .cedm-col {
  flex: 1 1 0;
}

@media (max-width: 520px) {
  .cedm-name-row {
    flex-direction: column;
  }
}

.cedm-btn-primary:hover {
  background: #16a34a;
}

.cedm-btn:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.cedm-check {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 14px;
}

.cedm-back {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  background: transparent;
  border: none;
  color: #111827;
  font-weight: 700;
  cursor: pointer;
  margin-bottom: 8px;
}

@media (max-width: 720px) {
  .cedm-wrap { padding: 16px; margin: 16px 12px; }
  .cedm-toggle-row { flex-direction: column; align-items: flex-start; }
  .cedm-currency { width: 100%; min-width: 0; }
  .cedm-amount-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
