/* استمارة التسجيل — ألوان وهوية لجنة الأمل (تُحمّل بعد main.css) */
:root {
  --white-color: #ffffff;
  --danger-color: #c0392b;
}

/* صفحة التسجيل: منطقة المحتوى */
.registration-page-wrap {
  max-width: 1000px;
  margin: 0 auto;
  padding: 6rem 1rem 3rem;
}

/* هيرو الاستمارة بألوان الموقع */
.registration-hero {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
  color: #fff;
  padding: 1.5rem 1rem;
  text-align: center;
  border-radius: 0 0 1rem 1rem;
  box-shadow: 0 4px 15px rgba(26, 95, 74, 0.25);
}
.registration-hero .hero-title {
  font-weight: 800;
  margin: 0 0 0.35rem;
  font-size: 1.6rem;
  color: #fff;
}
.registration-hero .hero-inner {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 1rem;
}
.registration-hero .hero-note {
  display: block;
  font-size: 0.875rem;
  opacity: 0.95;
}

/* حاوية الاستمارة */
.registration-container {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
  padding: 28px;
  border: 1px solid var(--primary-lighter);
  margin-top: -12px;
  position: relative;
  z-index: 1;
}

/* شريط التقدم */
.progress-container { margin-bottom: 28px; }
.progress {
  height: 8px;
  border-radius: 8px;
  background: #e9ecef;
  overflow: hidden;
}
.progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
  transition: width 0.6s ease;
  border-radius: 8px;
}
.step-indicator {
  display: flex;
  justify-content: space-between;
  margin-top: 18px;
  gap: 0.5rem;
  flex-wrap: wrap;
}
/* حقول التاريخ: ثلاثة دروب داون (يوم / شهر / سنة) */
.date-dropdowns {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.date-dropdowns select {
  flex: 1;
  min-width: 4rem;
  padding: 0.5rem 0.4rem;
  border: 1px solid var(--primary-lighter, #c8e6c9);
  border-radius: 8px;
  font-family: inherit;
  font-size: 1rem;
}
.date-dropdowns select:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(26, 95, 74, 0.2);
}

.step {
  text-align: center;
  flex: 1;
  min-width: 70px;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  transition: all 0.3s ease;
}
.step:hover .step-number {
  background: var(--primary-light);
  color: #fff;
  border-color: var(--primary-light);
}
.step-number {
  width: 36px;
  height: 36px;
  background: #e9ecef;
  color: #6c757d;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 8px;
  font-weight: 700;
  border: 3px solid #e9ecef;
  font-size: 0.9rem;
  transition: all 0.3s ease;
}
.step.active .step-number {
  background: var(--primary-color);
  color: #fff;
  border-color: var(--secondary-color);
}
.step-title {
  font-size: 0.75rem;
  color: #6c757d;
  font-weight: 500;
}
.step.active .step-title { color: var(--primary-color); font-weight: 600; }

/* أقسام النموذج */
.form { margin: 0; padding: 0; }
.form-step {
  display: none;
  animation: regFadeIn 0.4s ease;
}
.form-step.active { display: block; }
@keyframes regFadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
.form-section { margin-bottom: 0; padding-bottom: 1.5rem; }
.form-section:last-of-type { padding-bottom: 0; }

.form-header {
  text-align: center;
  margin-bottom: 28px;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid rgba(26, 95, 74, 0.12);
}
.form-header .section-title {
  color: var(--primary-dark);
  font-weight: 800;
  margin: 0 0 0.6rem;
  font-size: 1.45rem;
  letter-spacing: -0.02em;
  line-height: 1.35;
  display: block;
}
.form-header .section-title::after {
  content: '';
  display: block;
  width: 48px;
  height: 3px;
  background: linear-gradient(90deg, var(--secondary-color), var(--primary-color));
  margin: 0.5rem auto 0;
  border-radius: 2px;
  position: relative;
  right: auto;
  bottom: auto;
}
.form-header-p {
  color: #555;
  font-size: 0.95rem;
  margin: 0;
  line-height: 1.6;
  max-width: 32em;
  margin-right: auto;
  margin-left: auto;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0 1.5rem;
}
@media (min-width: 640px) {
  .form-grid { grid-template-columns: 1fr 1fr; }
  .full-width { grid-column: 1 / -1; }
}

.field-group { margin-bottom: 1rem; }
.field-group:last-child { margin-bottom: 0; }

.form-label,
.registration-container label {
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--dark-color);
  display: block;
  font-size: 0.95rem;
}
.form-label i,
.registration-container label i { color: var(--primary-color); }
.required { color: var(--danger-color); margin-right: 0.2rem; }

.registration-container input[type="text"],
.registration-container input[type="number"],
.registration-container input[type="tel"],
.registration-container input[type="url"],
.registration-container input[type="date"],
.registration-container select {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid #ddd;
  font-family: inherit;
  font-size: 1rem;
  color: var(--dark-color);
  background: var(--white-color);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.registration-container input:focus,
.registration-container select:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(26, 95, 74, 0.2);
}
.registration-container input.error,
.registration-container select.error {
  border-color: var(--danger-color) !important;
}
.registration-container input::placeholder { color: #999; }

/* حقل واتساب: مفتاح دولة + رقم (بدون أصفار في البداية) */
.whatsapp-field-group .whatsapp-input-row {
  display: flex;
  flex-direction: row-reverse;
  gap: 0.5rem;
  flex-wrap: wrap;
  align-items: stretch;
}
.whatsapp-field-group .country-code-dropdown-wrap {
  position: relative;
  width: 140px;
  min-width: 140px;
  flex: 0 0 140px;
}
.whatsapp-field-group .country-code-search {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #ddd;
  border-radius: 10px;
  font-size: 1rem;
  background: #fff;
  direction: ltr;
  text-align: left;
}
.whatsapp-field-group .country-code-search:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(26, 95, 74, 0.2);
}
.whatsapp-field-group .country-code-search::placeholder {
  color: #999;
}
.whatsapp-field-group .country-code-list {
  position: absolute;
  top: 100%;
  right: 0;
  left: 0;
  margin: 0;
  padding: 0;
  list-style: none;
  max-height: 220px;
  overflow-y: auto;
  border: 1px solid #ddd;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 6px 20px rgba(0,0,0,0.12);
  z-index: 100;
  display: none;
}
.whatsapp-field-group .country-code-list[aria-hidden="false"] {
  display: block;
  margin-top: 4px;
}
.whatsapp-field-group .country-code-list li {
  padding: 10px 14px;
  cursor: pointer;
  border-bottom: 1px solid #f0f0f0;
  font-size: 0.95rem;
}
.whatsapp-field-group .country-code-list li:last-child { border-bottom: none; }
.whatsapp-field-group .country-code-list li:hover,
.whatsapp-field-group .country-code-list li[aria-selected="true"] {
  background: rgba(26, 95, 74, 0.1);
  color: var(--primary-dark);
}
.whatsapp-field-group .country-code-list li .code { font-weight: 700; margin-left: 6px; }
.whatsapp-field-group #phoneWhatsAppNumber {
  flex: 1 1 0;
  min-width: 200px;
}

/* تنبيه عند الكتابة بالإنجليزية في حقل الاسم */
.english-name-toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  padding: 12px 20px;
  background: var(--danger-color, #c0392b);
  color: #fff;
  border-radius: 10px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
  font-size: 0.95rem;
  font-weight: 500;
  z-index: 9999;
  display: flex;
  align-items: center;
  opacity: 0;
  transition: opacity 0.3s ease, transform 0.3s ease;
  max-width: calc(100% - 32px);
}
.english-name-toast--show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* حقل الرابط الخارجي — استمارة التطوع */
.portfolio-url-wrap .input-url-box {
  display: flex;
  align-items: center;
  border: 1px solid #ddd;
  border-radius: 10px;
  background: var(--white-color);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.portfolio-url-wrap .input-url-box:focus-within {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(26, 95, 74, 0.2);
}
.portfolio-url-wrap .input-url-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  color: var(--primary-color);
  font-size: 1.1rem;
  border-left: 1px solid #e9ecef;
}
.portfolio-url-wrap .input-url {
  flex: 1;
  border: none;
  padding: 12px 14px;
  border-radius: 0 10px 10px 0;
  font-family: inherit;
  font-size: 1rem;
  color: var(--dark-color);
  background: transparent;
  min-width: 0;
}
.portfolio-url-wrap .input-url:focus {
  outline: none;
  box-shadow: none;
}
.portfolio-url-wrap .input-url::placeholder {
  color: #999;
}
[dir="rtl"] .portfolio-url-wrap .input-url-icon {
  border-left: none;
  border-right: 1px solid #e9ecef;
}
[dir="rtl"] .portfolio-url-wrap .input-url {
  border-radius: 10px 0 0 10px;
}

.field-error {
  font-size: 0.85rem;
  color: var(--danger-color);
  margin-top: 0.35rem;
  min-height: 1.2rem;
}

/* راديو وتشيك بوكس */
.radio-group { display: flex; gap: 2rem; margin-top: 0.5rem; flex-wrap: wrap; }
.radio-label,
.checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
  font-weight: 500;
  padding: 0.75rem 1rem;
  background: var(--light-color);
  border-radius: 10px;
  border: 1px solid #e9ecef;
  transition: all 0.2s;
}
.checkbox-label { align-items: flex-start; }
.checkbox-label span { line-height: 1.5; }
.radio-label:hover,
.checkbox-label:hover { border-color: var(--primary-color); }
.radio-label input[type="radio"],
.checkbox-label input[type="checkbox"] {
  width: 1.2rem;
  height: 1.2rem;
  accent-color: var(--primary-color);
}
.checkbox-group { margin-bottom: 1rem; }

/* بطاقات الأفراد */
.persons-container { margin-top: 1rem; }
.person-card {
  background: #fff;
  border: 1px solid #e9ecef;
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  position: relative;
  border-right: 4px solid var(--primary-color);
}
.person-card-title { margin: 0 0 1rem; font-size: 1.05rem; color: var(--primary-color); }
.applicant-readonly .person-name,
.applicant-readonly .person-age,
.applicant-readonly .person-relationship {
  background: #f0f4f5 !important;
  color: #495057;
  cursor: not-allowed;
}
.applicant-readonly .person-gender {
  background: #f0f4f5 !important;
  color: #495057;
  pointer-events: none;
  cursor: not-allowed;
}
.companion-card .person-card-title { font-size: 0.98rem; }
.person-health {
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px dashed #e9ecef;
}
.person-health .field-group { margin-bottom: 0.75rem; }

/* رفع الملفات */
.ocr-promo.box-highlight {
  background: var(--primary-lighter);
  border: 1px solid rgba(26, 95, 74, 0.2);
  border-radius: 10px;
  padding: 1rem 1.25rem;
  margin-bottom: 1.5rem;
}
.ocr-promo--hidden { display: none !important; }
.ocr-promo-text { margin: 0 0 0.75rem; font-weight: 500; color: var(--dark-color); }
.ocr-promo-text i { color: var(--primary-color); margin-left: 0.25rem; }
/* صندوق رفع الملفات الموحد: نفس الشكل لكل حقول الرفع (أخضر + أيقونة + نص عربي) */
.ocr-upload-box,
.file-upload-box {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.5rem;
  border: 1px dashed var(--primary-color);
  border-radius: 10px;
  background: var(--primary-lighter);
  min-height: 3rem;
  overflow: hidden;
}
/* إخفاء المظهر الافتراضي لجميع حقول الرفع داخل الاستمارة (موحد لكل الحقول) */
.registration-container .ocr-upload-box input[type="file"],
.registration-container .file-upload-box input[type="file"],
.ocr-upload-box input[type="file"],
.file-upload-box input[type="file"],
.person-photo-wrap .person-photo,
.person-chronic-report-wrap .person-chronic-report,
.person-disability-report-wrap .person-disability-report,
.person-id-document-wrap .person-id-document {
  position: absolute !important;
  opacity: 0 !important;
  width: 100% !important;
  height: 100% !important;
  min-width: 100% !important;
  min-height: 100% !important;
  top: 0 !important;
  right: 0 !important;
  left: 0 !important;
  bottom: 0 !important;
  cursor: pointer !important;
  font-size: 0 !important;
  z-index: 2;
  margin: 0;
  padding: 0;
  border: none;
  color: transparent;
}
/* إخفاء زر المتصفح الافتراضي في الحقول من نوع file (لمنع ظهور "Choose file" بالإنكليزي) */
.registration-container input[type="file"]::file-selector-button,
.file-upload-box input[type="file"]::file-selector-button,
.ocr-upload-box input[type="file"]::file-selector-button {
  opacity: 0;
  width: 0;
  height: 0;
  padding: 0;
  margin: 0;
  border: none;
  position: absolute;
  pointer-events: none;
}
.file-upload-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: var(--primary-color);
  color: #fff;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 500;
  pointer-events: none;
  white-space: nowrap;
}
.file-upload-filename {
  color: #6c757d;
  font-size: 0.9rem;
}
.file-upload-filename.has-file,
.person-photo-filename.has-file,
.person-chronic-report-filename.has-file,
.person-disability-report-filename.has-file,
.person-id-document-filename.has-file { color: var(--primary-color); font-weight: 500; }

/* ظهور تدريجي لحقل الوضع العائلي للإناث (Progressive Disclosure) */
.fade-in-up {
  animation: fadeInUp 0.35s ease-out;
}
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.file-preview { margin-top: 0.5rem; min-height: 0; }
.file-thumbnail-img {
  display: block;
  max-width: 120px;
  max-height: 90px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid #dee2e6;
}
.file-thumbnail-pdf {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.6rem;
  background: #f0f4f5;
  border-radius: 6px;
  font-size: 0.85rem;
  color: #495057;
}
.file-thumbnail-pdf i { color: var(--danger-color); font-size: 1.1rem; }

/* حقل رقم الجواز: حرف + أرقام ملتصقين */
.passport-field .passport-input-row {
  display: flex;
  gap: 0;
  direction: ltr;
  flex-wrap: wrap;
}
.passport-field .passport-input-row select,
.passport-field .passport-input-row input {
  padding: 12px 14px;
  border: 1px solid #ddd;
  font-family: inherit;
  font-size: 1rem;
  color: var(--dark-color);
  background: var(--white-color);
}
.passport-field .passport-input-row select {
  border-radius: 10px 0 0 10px;
  border-left: none;
  min-width: 4.5rem;
  width: 4.5rem;
  text-align: center;
  padding-left: 0.5rem;
  padding-right: 1.75rem;
  appearance: auto;
}
.passport-field .passport-input-row input {
  border-radius: 0 10px 10px 0;
  width: 150px;
  max-width: 100%;
}
.passport-field .passport-input-row select:focus,
.passport-field .passport-input-row input:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(26, 95, 74, 0.2);
}
.passport-field .passport-input-row select:focus {
  border-left: 1px solid var(--primary-color);
}

.acknowledgment {
  background: var(--light-color);
  padding: 1.25rem;
  border-radius: 10px;
  border: 1px solid #e9ecef;
}

/* أزرار الخطوات */
.step-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid #eee;
  flex-wrap: wrap;
}
.step-actions-end { display: flex; gap: 0.75rem; margin-right: auto; }
.registration-container .btn-custom {
  background: var(--primary-color);
  color: #fff;
  border: none;
  box-shadow: 0 4px 15px rgba(26, 95, 74, 0.3);
}
.registration-container .btn-custom:hover {
  background: var(--primary-dark);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(26, 95, 74, 0.35);
}
.registration-container .btn-outline-custom {
  border: 2px solid var(--primary-color);
  color: var(--primary-color);
  background: transparent;
}
.registration-container .btn-outline-custom:hover {
  background: var(--primary-color);
  color: #fff;
}
.btn-loading { pointer-events: none; opacity: 0.85; }
.spin-icon { animation: regSpin 0.8s linear infinite; }
@keyframes regSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}
.btn-submit-spinner { margin-right: 0.35rem; }

/* غشاء الإرسال — مؤشر واضح أثناء رفع الاستمارة */
.form-submit-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.92);
  border-radius: 16px;
  transition: opacity 0.25s ease;
}
.form-submit-overlay[hidden] {
  display: none !important;
}
.form-submit-overlay-inner {
  text-align: center;
  padding: 2rem;
}
.form-submit-spinner {
  width: 56px;
  height: 56px;
  margin: 0 auto 1.25rem;
  border: 4px solid var(--primary-lighter, #e8f2ee);
  border-top-color: var(--primary-color, #1a5f4a);
  border-radius: 50%;
  animation: regSpin 0.9s linear infinite;
}
.form-submit-overlay-text {
  margin: 0 0 0.35rem;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--primary-dark, #134736);
}
.form-submit-overlay-hint {
  margin: 0;
  font-size: 0.9rem;
  color: #6c757d;
}

/* رسالة النجاح */
.success-message {
  background: #d4edda;
  color: #155724;
  padding: 1rem 1.25rem;
  border-radius: 10px;
  margin-top: 1rem;
  border: 1px solid #c3e6cb;
  text-align: center;
  font-weight: 600;
}
.success-message p { margin: 0; display: flex; align-items: center; justify-content: center; flex-wrap: wrap; }

/* شاشة النجاح الكاملة بعد إرسال الطلب */
.success-message.success-screen {
  background: transparent;
  border: none;
  margin-top: 0;
  padding: 0;
  color: inherit;
}
.success-screen .success-icon {
  font-size: 5rem;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.1));
}
.success-screen .tracking-box {
  background: #fff;
  padding: 1.5rem 2rem;
  border-radius: 1rem;
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
  border: 2px solid var(--primary-color, #1a5f4a);
  display: inline-block;
}
.success-screen #generated-tracking-number {
  font-size: clamp(1.5rem, 5vw, 2.25rem);
  letter-spacing: 2px;
  font-family: ui-monospace, monospace;
}
.success-screen .success-actions .btn { min-width: 140px; }

/* زر وضع المطور */
.dev-mode-toggle {
  position: fixed;
  bottom: 2px;
  left: 2px;
  width: 18px;
  height: 18px;
  padding: 0;
  border: none;
  border-radius: 2px;
  background: var(--primary-color);
  opacity: 0.06;
  cursor: pointer;
  z-index: 9999;
  font-size: 0;
  transition: opacity 0.2s;
}
.dev-mode-toggle:hover { opacity: 0.2; }
.dev-mode-toggle.active { opacity: 0.35; box-shadow: 0 0 0 1px rgba(26,95,74,0.3); }

@media (max-width: 768px) {
  .registration-container { padding: 20px; margin-top: -10px; }
  .registration-hero .hero-title { font-size: 1.35rem; }
  .step-title { font-size: 0.65rem; }
}

/* استمارة التطوع — هيرو بعرض الصفحة وتحسين بصري */
.volunteer-page-wrap {
  max-width: none;
  padding: 6rem 0 3rem;
}
.volunteer-hero {
  position: relative;
  width: 100%;
  min-height: 180px;
  padding: 1.5rem 1rem;
  color: #fff;
  text-align: center;
  overflow: hidden;
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 50%, #1e7a5e 100%);
  box-shadow: 0 8px 32px rgba(26, 95, 74, 0.25);
}
.volunteer-hero-bg {
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.04'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  opacity: 0.6;
  pointer-events: none;
}
.volunteer-hero .container {
  position: relative;
  z-index: 1;
  max-width: 900px;
  margin: 0 auto;
}
.volunteer-hero-inner {
  max-width: 42em;
  margin: 0 auto;
}
.volunteer-hero-badge {
  display: inline-block;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.35rem 1rem;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  margin-bottom: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.3);
}
.volunteer-hero-title {
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 800;
  margin: 0 0 0.5rem;
  line-height: 1.3;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}
.volunteer-hero-greeting {
  font-size: 1.1rem;
  opacity: 0.95;
  margin: 0 0 1rem;
  font-weight: 600;
}
.volunteer-hero-desc {
  font-size: 0.95rem;
  line-height: 1.75;
  opacity: 0.95;
  margin: 0;
  color: rgba(255, 255, 255, 0.95);
}
.volunteer-container {
  max-width: 1000px;
  margin-right: auto;
  margin-left: auto;
  margin-top: -24px;
  padding-right: 1rem;
  padding-left: 1rem;
}
@media (max-width: 768px) {
  .volunteer-hero {
    min-height: 160px;
    padding: 1.25rem 1rem;
  }
  .volunteer-hero-title {
    font-size: 1.35rem;
  }
  .volunteer-hero-desc {
    font-size: 0.9rem;
  }
}

/* نافذة الحقول الفارغة (مجموع + تسميات + نقر للتوجيه) */
.empty-fields-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  padding: 1rem;
  animation: regFadeIn 0.2s ease;
}
.empty-fields-modal {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
  max-width: 480px;
  width: 100%;
  max-height: 85vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--primary-lighter);
}
.empty-fields-title {
  margin: 0;
  padding: 1.25rem 1.25rem 0;
  font-size: 1.25rem;
  color: var(--primary-color);
  font-weight: 700;
}
.empty-fields-count {
  margin: 0.5rem 1.25rem 0;
  font-size: 1rem;
  color: var(--dark-color);
}
.empty-fields-count strong {
  color: var(--primary-color);
}
.empty-fields-hint {
  margin: 0.35rem 1.25rem 0;
  font-size: 0.9rem;
  color: #6c757d;
}
.empty-fields-list {
  list-style: none;
  margin: 1rem 1.25rem 0;
  padding: 0;
  overflow-y: auto;
  flex: 1;
  min-height: 0;
}
.empty-fields-item {
  padding: 0.75rem 1rem;
  margin-bottom: 0.5rem;
  background: var(--primary-lighter);
  border-radius: 10px;
  border: 1px solid rgba(26, 95, 74, 0.15);
  cursor: pointer;
  font-weight: 500;
  color: var(--dark-color);
  transition: background 0.2s, border-color 0.2s;
}
.empty-fields-item:hover {
  background: rgba(26, 95, 74, 0.15);
  border-color: var(--primary-color);
  color: var(--primary-dark);
}
.empty-fields-close {
  margin: 1rem 1.25rem 1.25rem;
  align-self: stretch;
}

/* نافذة الرسائل (نجاح / تنبيه / خطأ) — أنيقة مع أيقونة */
.message-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10001;
  padding: 1rem;
  animation: regFadeIn 0.25s ease;
}
.message-modal-overlay[hidden] {
  display: none !important;
}
.message-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(4px);
}
.message-modal {
  position: relative;
  background: #fff;
  border-radius: 20px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.18), 0 0 0 1px rgba(255, 255, 255, 0.5) inset;
  max-width: 440px;
  width: 100%;
  padding: 2rem 1.75rem;
  text-align: center;
  border: 1px solid rgba(26, 95, 74, 0.12);
  animation: messageModalSlideIn 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}
@keyframes messageModalSlideIn {
  from {
    opacity: 0;
    transform: scale(0.92) translateY(-12px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}
.message-modal-icon-wrap {
  width: 72px;
  height: 72px;
  margin: 0 auto 1.25rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.message-modal-icon {
  font-size: 2.25rem;
  color: #fff;
}
.message-modal-overlay.message-modal--success .message-modal-icon-wrap {
  background: linear-gradient(145deg, #1a5f4a 0%, #2d7a5f 100%);
  box-shadow: 0 8px 24px rgba(26, 95, 74, 0.35);
}
.message-modal-overlay.message-modal--warning .message-modal-icon-wrap {
  background: linear-gradient(145deg, #b8860b 0%, #c9a227 100%);
  box-shadow: 0 8px 24px rgba(184, 134, 11, 0.35);
}
.message-modal-overlay.message-modal--error .message-modal-icon-wrap {
  background: linear-gradient(145deg, #a52a2a 0%, #c0392b 100%);
  box-shadow: 0 8px 24px rgba(192, 57, 43, 0.35);
}
.message-modal-title {
  margin: 0 0 0.75rem;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary-dark, #134736);
}
.message-modal-overlay.message-modal--error .message-modal-title {
  color: #8b2500;
}
.message-modal-body {
  margin: 0 0 1.5rem;
  font-size: 1rem;
  line-height: 1.65;
  color: #495057;
}
.message-modal-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 140px;
  padding: 0.7rem 1.5rem;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(145deg, var(--primary-color) 0%, var(--primary-dark) 100%);
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 4px 14px rgba(26, 95, 74, 0.3);
}
.message-modal-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(26, 95, 74, 0.4);
  color: #fff;
}
.message-modal-overlay.message-modal--error .message-modal-btn {
  background: linear-gradient(145deg, #c0392b 0%, #a52a2a 100%);
  box-shadow: 0 4px 14px rgba(192, 57, 43, 0.3);
}
.message-modal-overlay.message-modal--error .message-modal-btn:hover {
  box-shadow: 0 6px 20px rgba(192, 57, 43, 0.4);
}

/* إخفاء خطوة المرافقين من الشريط والمحتوى عند الطلب الفردي */
.step-companions.step-skip-individual {
  display: none !important;
}
.form-section.step-skip-individual {
  display: none !important;
}

.subsection-title {
  font-size: 1.1rem;
  color: var(--primary-dark, #1a5f4a);
}

@media (max-width: 480px) {
  .step-indicator { flex-direction: column; align-items: stretch; }
  .step { min-width: auto; display: flex; align-items: center; gap: 0.75rem; text-align: right; }
  .step-number { margin: 0; flex-shrink: 0; }
  .step-title { margin: 0; }
}

/* استمارة التطوع — بطاقات اختيار المسار */
.track-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
}
.track-card {
  cursor: pointer;
  margin: 0;
}
.track-card input { position: absolute; opacity: 0; pointer-events: none; }
.track-card-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 1.25rem 1rem;
  border: 2px solid #e9ecef;
  border-radius: 12px;
  background: #fff;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}
.track-card:hover .track-card-inner { border-color: var(--primary-light); background: rgba(26, 95, 74, 0.04); }
.track-card input:checked + .track-card-inner {
  border-color: var(--primary-color);
  background: rgba(26, 95, 74, 0.08);
  box-shadow: 0 0 0 1px var(--primary-color);
}
.track-icon {
  font-size: 1.75rem;
  color: var(--primary-color);
  margin-bottom: 0.5rem;
}
.track-card-inner strong { display: block; font-size: 0.95rem; margin-bottom: 0.25rem; }
.track-card-inner small { font-size: 0.8rem; color: #6c757d; line-height: 1.3; }
