/**
 * Ecole LIVE DZ – Contact Page Frontend Stylesheet
 * RTL Native, Clean Educational UI
 */

:root {
  --elc-primary: #059669;
  --elc-primary-hover: #047857;
  --elc-accent: #2563eb;
  --elc-card-radius: 16px;
  --elc-bg-light: #f8fafc;
  --elc-border: #e2e8f0;
  --elc-text-main: #0f172a;
  --elc-text-muted: #64748b;
  --elc-shadow: 0 4px 20px -2px rgba(0, 0, 0, 0.05), 0 2px 6px -1px rgba(0, 0, 0, 0.03);
  --elc-shadow-hover: 0 10px 25px -3px rgba(0, 0, 0, 0.08), 0 4px 10px -2px rgba(0, 0, 0, 0.04);
}

.ecole-contact-wrapper {
  direction: rtl;
  text-align: right;
  font-family: 'Cairo', system-ui, -apple-system, sans-serif;
  color: var(--elc-text-main);
  line-height: 1.6;
  width: 100%;
  margin: 0 auto;
  padding: 24px 0 60px 0;
  box-sizing: border-box;
}

/* Full-Width Breakout: escapes narrow theme page containers */
.ecole-contact-wrapper.elc-full-width-breakout {
  width: 100vw !important;
  max-width: 100vw !important;
  position: relative !important;
  left: 50% !important;
  right: 50% !important;
  margin-left: -50vw !important;
  margin-right: -50vw !important;
  box-sizing: border-box !important;
}

/* Centered inner responsive container */
.ecole-contact-wrapper .elc-container {
  width: 100%;
  max-width: 1360px;
  margin-left: auto;
  margin-right: auto;
  padding-left: clamp(16px, 3.5vw, 44px);
  padding-right: clamp(16px, 3.5vw, 44px);
  box-sizing: border-box;
}

.ecole-contact-wrapper *,
.ecole-contact-wrapper *::before,
.ecole-contact-wrapper *::after {
  box-sizing: border-box;
}

/* ================= HERO SECTION ================= */
.elc-hero-section {
  text-align: center;
  padding: 48px 24px;
  background: linear-gradient(180deg, #f0fdf4 0%, #ffffff 100%);
  border-radius: var(--elc-card-radius);
  border: 1px solid #dcfce7;
  margin-bottom: 40px;
  position: relative;
  overflow: hidden;
}

.elc-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  background: #dcfce7;
  color: #166534;
  border-radius: 9999px;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 16px;
}

.elc-badge-dot {
  width: 8px;
  height: 8px;
  background: #16a34a;
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.25);
  animation: elcPulse 2s infinite;
}

@keyframes elcPulse {
  0% { transform: scale(0.95); opacity: 0.8; }
  50% { transform: scale(1.15); opacity: 1; }
  100% { transform: scale(0.95); opacity: 0.8; }
}

.elc-hero-title {
  font-size: 32px;
  font-weight: 800;
  color: #064e3b;
  margin: 0 0 14px 0;
  line-height: 1.3;
}

.elc-hero-desc {
  font-size: 17px;
  color: #334155;
  max-width: 680px;
  margin: 0 auto 28px auto;
  line-height: 1.7;
}

.elc-hero-stats {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
  margin-top: 24px;
}

.elc-stat-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #ffffff;
  padding: 10px 18px;
  border-radius: 9999px;
  border: 1px solid #e2e8f0;
  font-size: 14px;
  color: #475569;
  box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}

.elc-stat-icon {
  font-size: 16px;
}

/* ================= SECTION HEADERS ================= */
.elc-section-header {
  text-align: center;
  margin-bottom: 28px;
}

.elc-section-title {
  font-size: 24px;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 6px 0;
}

.elc-section-subtitle {
  font-size: 15px;
  color: var(--elc-text-muted);
  margin: 0;
}

/* ================= METHODS GRID ================= */
.elc-methods-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  margin-bottom: 50px;
}

.elc-method-card {
  background: #ffffff;
  border: 1px solid var(--elc-border);
  border-radius: var(--elc-card-radius);
  padding: 24px;
  display: flex;
  flex-direction: column;
  transition: all 0.25s ease;
  box-shadow: var(--elc-shadow);
  position: relative;
}

.elc-method-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--elc-shadow-hover);
  border-color: #cbd5e1;
}

.elc-method-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.elc-method-icon-wrap {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f1f5f9;
}

.elc-icon {
  width: 26px;
  height: 26px;
}

.elc-method-whatsapp .elc-method-icon-wrap {
  background: #e8f5e9;
  color: #25d366;
}

.elc-method-telegram .elc-method-icon-wrap {
  background: #e0f2fe;
  color: #0284c7;
}

.elc-method-users .elc-method-icon-wrap {
  background: #fef3c7;
  color: #d97706;
}

.elc-method-mail .elc-method-icon-wrap {
  background: #f3e8ff;
  color: #9333ea;
}

.elc-method-badge {
  font-size: 12px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 9999px;
  background: #f1f5f9;
  color: #475569;
}

.elc-method-body {
  flex-grow: 1;
  margin-bottom: 20px;
}

.elc-method-title {
  font-size: 18px;
  font-weight: 700;
  margin: 0 0 8px 0;
  color: #1e293b;
}

.elc-method-desc {
  font-size: 14px;
  color: var(--elc-text-muted);
  margin: 0;
  line-height: 1.5;
}

.elc-method-btn {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  color: #1e293b;
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.2s ease;
}

.elc-method-btn:hover {
  background: var(--elc-primary);
  color: #ffffff;
  border-color: var(--elc-primary);
}

.elc-btn-arrow {
  width: 16px;
  height: 16px;
  transition: transform 0.2s ease;
}

.elc-method-btn:hover .elc-btn-arrow {
  transform: translateX(-4px);
}

/* ================= CONTACT FORM ================= */
.elc-form-section {
  margin-bottom: 50px;
}

.elc-form-card {
  background: #ffffff;
  border: 1px solid var(--elc-border);
  border-radius: var(--elc-card-radius);
  padding: 36px 32px;
  box-shadow: var(--elc-shadow);
  max-width: 800px;
  margin: 0 auto;
}

.elc-form-header {
  text-align: center;
  margin-bottom: 28px;
}

.elc-form-icon-pill {
  width: 52px;
  height: 52px;
  background: #ecfdf5;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  margin-bottom: 12px;
}

.elc-form-title {
  font-size: 26px;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 6px 0;
}

.elc-form-subtitle {
  font-size: 15px;
  color: var(--elc-text-muted);
  margin: 0;
}

/* Smart Guidance Box */
.elc-smart-guidance {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 24px;
  animation: elcFadeIn 0.3s ease;
}

.elc-smart-inner {
  display: flex;
  align-items: center;
  gap: 14px;
}

.elc-smart-icon {
  font-size: 24px;
  flex-shrink: 0;
}

.elc-smart-content {
  flex-grow: 1;
}

.elc-smart-text {
  font-size: 14px;
  color: #1e40af;
  font-weight: 600;
}

.elc-smart-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #2563eb;
  color: #ffffff;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  flex-shrink: 0;
  transition: background 0.2s ease;
}

.elc-smart-cta-btn:hover {
  background: #1d4ed8;
}

/* Form Fields */
.elc-fields-row {
  display: flex;
  gap: 16px;
  margin-bottom: 18px;
}

.elc-col-half {
  flex: 1;
  min-width: 0;
}

.elc-col-full {
  width: 100%;
}

.elc-field-group {
  margin-bottom: 18px;
}

.elc-label {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 6px;
}

.elc-required {
  color: #ef4444;
}

.elc-optional {
  font-size: 12px;
  font-weight: normal;
  color: #94a3b8;
}

.elc-input-wrap {
  position: relative;
}

.elc-input,
.elc-select,
.elc-textarea {
  width: 100%;
  padding: 12px 42px 12px 14px;
  font-family: inherit;
  font-size: 15px;
  color: #0f172a;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  outline: none;
  transition: all 0.2s ease;
}

.elc-select {
  padding-left: 36px;
  appearance: none;
  cursor: pointer;
}

.elc-select-wrap {
  position: relative;
}

.elc-select-arrow {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  font-size: 10px;
  color: #64748b;
}

.elc-textarea {
  padding: 12px 14px;
  resize: vertical;
}

.elc-input:focus,
.elc-select:focus,
.elc-textarea:focus {
  background: #ffffff;
  border-color: var(--elc-primary);
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.15);
}

.elc-input-icon {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  font-size: 16px;
  opacity: 0.7;
}

.elc-field-error {
  display: block;
  font-size: 13px;
  color: #ef4444;
  margin-top: 4px;
  font-weight: 500;
}

.elc-submit-wrap {
  text-align: center;
  margin-top: 24px;
}

.elc-submit-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  max-width: 320px;
  padding: 14px 24px;
  background: var(--elc-primary);
  color: #ffffff;
  border: none;
  border-radius: 12px;
  font-family: inherit;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(5, 150, 105, 0.3);
  transition: all 0.2s ease;
}

.elc-submit-btn:hover {
  background: var(--elc-primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(5, 150, 105, 0.4);
}

.elc-submit-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.elc-btn-spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #ffffff;
  border-radius: 50%;
  animation: elcSpin 0.7s linear infinite;
}

@keyframes elcSpin {
  to { transform: rotate(360deg); }
}

.elc-privacy-notice {
  font-size: 13px;
  color: #94a3b8;
  margin-top: 14px;
  margin-bottom: 0;
}

/* Success Box */
.elc-success-box {
  text-align: center;
  padding: 36px 20px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 14px;
  animation: elcFadeIn 0.3s ease;
}

.elc-success-icon-ring {
  width: 64px;
  height: 64px;
  background: #22c55e;
  color: #ffffff;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  box-shadow: 0 4px 12px rgba(34, 197, 94, 0.3);
}

.elc-success-title {
  font-size: 22px;
  font-weight: 800;
  color: #15803d;
  margin: 0 0 10px 0;
}

.elc-success-desc {
  font-size: 15px;
  color: #166534;
  max-width: 500px;
  margin: 0 auto 20px auto;
  line-height: 1.6;
}

.elc-reset-form-btn {
  background: #ffffff;
  border: 1px solid #86efac;
  color: #15803d;
  padding: 8px 20px;
  border-radius: 8px;
  font-family: inherit;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
}

.elc-alert {
  padding: 14px 18px;
  border-radius: 10px;
  margin-bottom: 20px;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.elc-alert.error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #b91c1c;
}

@keyframes elcFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ================= FAQ SECTION ================= */
.elc-faq-section {
  max-width: 800px;
  margin: 0 auto 50px auto;
}

.elc-faq-accordion {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.elc-faq-item {
  background: #ffffff;
  border: 1px solid var(--elc-border);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.2s ease;
}

.elc-faq-item.active {
  border-color: #cbd5e1;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.elc-faq-question {
  width: 100%;
  padding: 16px 20px;
  background: none;
  border: none;
  font-family: inherit;
  font-size: 16px;
  font-weight: 700;
  color: #1e293b;
  text-align: right;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  gap: 12px;
}

.elc-faq-toggle-icon {
  font-size: 20px;
  font-weight: bold;
  color: var(--elc-primary);
  transition: transform 0.2s ease;
}

.elc-faq-item.active .elc-faq-toggle-icon {
  transform: rotate(45deg);
}

.elc-faq-answer {
  display: none;
  padding: 0 20px 18px 20px;
  font-size: 15px;
  color: #475569;
  line-height: 1.7;
}

.elc-faq-answer-inner p {
  margin: 0;
}

/* ================= CTA SECTION ================= */
.elc-cta-section {
  margin-top: 40px;
}

.elc-cta-box {
  background: linear-gradient(135deg, #064e3b 0%, #059669 100%);
  border-radius: var(--elc-card-radius);
  padding: 42px 32px;
  color: #ffffff;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  box-shadow: 0 10px 30px -5px rgba(6, 78, 59, 0.4);
}

.elc-cta-content {
  flex: 1;
  min-width: 280px;
}

.elc-cta-pill {
  display: inline-block;
  padding: 4px 12px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 9999px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 12px;
}

.elc-cta-title {
  font-size: 26px;
  font-weight: 800;
  color: #ffffff;
  margin: 0 0 10px 0;
}

.elc-cta-desc {
  font-size: 16px;
  opacity: 0.9;
  margin: 0;
  line-height: 1.6;
}

.elc-cta-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.elc-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 24px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.2s ease;
}

/* ================= DESKTOP OPTIMIZATION (min-width: 1024px) ================= */
@media (min-width: 1024px) {
  .ecole-contact-wrapper {
    padding-top: 36px;
    padding-bottom: 90px;
  }
  .elc-hero-section {
    padding: 60px 48px;
    margin-bottom: 48px;
  }
  .elc-hero-title {
    font-size: 38px;
    line-height: 1.25;
  }
  .elc-hero-desc {
    font-size: 19px;
    max-width: 780px;
    margin-bottom: 32px;
  }
  .elc-hero-stats {
    gap: 20px;
  }
  .elc-stat-item {
    padding: 12px 22px;
    font-size: 15px;
  }
  .elc-methods-grid {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
    margin-bottom: 56px;
  }
  .elc-method-card {
    padding: 32px 26px;
  }
  .elc-form-section {
    max-width: 960px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 60px;
  }
  .elc-form-card {
    padding: 44px 40px;
  }
  .elc-form-title {
    font-size: 28px;
  }
  .elc-faq-section {
    max-width: 960px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 60px;
  }
}

/* ================= RESPONSIVE (max-width: 768px) ================= */
@media (max-width: 768px) {
  .elc-fields-row {
    flex-direction: column;
    gap: 0;
  }
  .elc-form-card {
    padding: 24px 18px;
  }
  .elc-hero-title {
    font-size: 26px;
  }
  .elc-hero-desc {
    font-size: 15px;
  }
  .elc-hero-section {
    padding: 32px 16px;
  }
  .elc-smart-inner {
    flex-direction: column;
    text-align: center;
  }
}
