/* Emara Custom Forms (scoped) */
.ecf-wrap{font-family:inherit; direction:rtl;}
.ecf-form{
  max-width:600px;
  margin:0 auto;
  /* Navy gradient for the whole form container */
  background: linear-gradient(90deg, #0b1f4b 0%, #123a7a 100%);
  border:1px solid rgba(255,255,255,0.14);
  border-radius:22px;
  padding:18px 18px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.22);
}

/* Compact grid so the full form fits in the first view */
.ecf-fields{display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px;}
.ecf-field{margin-bottom:0;}
.ecf-field--textarea,
.ecf-field--phone,
.ecf-field--file,
.ecf-field--checkbox,
.ecf-field--radio{grid-column:1 / -1;}

.ecf-label{display:block; color:#fff; font-weight:800; margin-bottom:6px; font-size:13px;}
.ecf-req{display:none !important;}
.ecf-input,.ecf-select,.ecf-textarea{
  width:100%;
  background:rgba(0,0,0,0.22);
  border:1px solid rgba(255,255,255,0.18);
  border-radius:14px;
  padding:9px 12px;
  color:#fff;
  outline:none;
  transition: box-shadow .2s ease,border-color .2s ease,transform .2s ease;
}
.ecf-textarea{min-height:80px; resize:vertical;}
.ecf-input:focus,.ecf-select:focus,.ecf-textarea:focus{border-color:rgba(255,138,0,0.55); box-shadow:0 0 0 3px rgba(255,138,0,0.18);}

/* Make dropdowns readable (some themes force white dropdown background) */
.ecf-select{background:#fff !important; color:#000 !important;}
.ecf-select option{background:#fff; color:#000;}


.ecf-choice{display:flex; flex-wrap:wrap; gap:10px;}
.ecf-radio,.ecf-check{display:flex; align-items:center; gap:8px; background:rgba(255,255,255,0.06); border:1px solid rgba(255,255,255,0.12); padding:10px 12px; border-radius:14px; color:#fff;}
.ecf-radio input,.ecf-check input{accent-color:#ff8a00;}

.ecf-phone{display:flex; gap:10px; align-items:stretch;}
.ecf-phone__code{max-width:140px;}

.ecf-btn{
  width:100%;
  border:0;
  cursor:pointer;
  padding:11px 16px;
  border-radius:16px;
  font-weight:900;
  font-size:15px;
  color:#fff;
  /* Restore original button color */
  background: linear-gradient(90deg, #ff8a00 0%, #ff5f00 100%);
  transition: transform .2s ease, box-shadow .2s ease;
}
.ecf-btn:hover{transform:translateY(-2px); box-shadow:0 16px 40px rgba(255,138,0,0.22);}

/* Validation UI */
.ecf-invalid{border-color:rgba(255,60,60,0.8) !important; box-shadow:0 0 0 3px rgba(255,60,60,0.18) !important;}
.ecf-error-msg{margin-top:8px; font-size:12px; color:#fff; background:rgba(255,60,60,0.16); border:1px solid rgba(255,60,60,0.22); padding:8px 10px; border-radius:12px;}

.ecf-alert{max-width:600px; margin:0 auto 12px; padding:12px 14px; border-radius:16px; border:1px solid rgba(255,255,255,0.16);}
.ecf-alert--success{background:rgba(0,200,120,0.14); color:#eafff6;}
.ecf-alert--error{background:rgba(255,60,60,0.14); color:#fff;}

.ecf-help{margin-top:8px; font-size:12px; opacity:.85; color:#e9eef6;}
.ecf-file{padding:10px 14px;}
.ecf-captcha{margin:14px 0 18px;}

/* Make submit/captcha span full width after grid */
.ecf-captcha, .ecf-btn{grid-column:1 / -1;}

@media (max-width:600px){
  .ecf-form{padding:18px 14px; border-radius:18px; max-width:100%;}
  .ecf-fields{grid-template-columns:1fr;}
  .ecf-phone{flex-direction:column;}
  .ecf-phone__code{max-width:100%;}
}
