/* =========================================================
   ACCANTA AUTH MODAL — FINAL & SYNCED
========================================================= */

/* ---------- Backdrop ---------- */
.acc-modal-backdrop {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(10px);
  z-index: 999999;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.18s ease, visibility 0.18s ease;
}

.acc-modal-backdrop.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* ---------- Modal ---------- */
.acc-modal {
  position: relative;
  width: 100%;
  max-width: 420px;
  padding: 22px 22px 18px;

  background: #ffffff;
  border-radius: 18px;
  box-shadow: 0 22px 60px rgba(15, 23, 42, 0.35);

  direction: rtl;
  text-align: right;
}

/* ---------- Close ---------- */
.acc-modal-close {
  position: absolute;
  top: 10px;
  left: 10px;

  width: 28px;
  height: 28px;
  border-radius: 999px;
  border: none;

  background: #f3f4f6;
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
}

/* ---------- Header ---------- */
.acc-modal h2 {
  margin: 0 0 6px;
  font-size: 20px;
  font-weight: 800;
  color: #0b1f17;
}

.acc-modal-sub {
  margin: 0 0 12px;
  font-size: 14px;
  color: #6b7280;
}

/* ---------- Steps ---------- */
.acc-auth-step {
  display: none;
}

.acc-auth-step--active {
  display: block;
}

/* ---------- Inputs ---------- */
.acc-auth-label {
  display: block;
  margin-bottom: 10px;
  font-size: 14px;
}

.acc-auth-label input {
  width: 100%;
  margin-top: 6px;
  padding: 10px 12px;

  border-radius: 12px;
  border: 1px solid #d1d5db;

  font-size: 15px;
  direction: ltr;
  text-align: left;
}

.acc-auth-label input:focus {
  outline: none;
  border-color: #16a34a;
  box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.18);
}

/* ---------- Helper Text ---------- */
.acc-auth-hint {
  margin: 0 0 14px;
  font-size: 12px;
  color: #6b7280;
}

.acc-auth-hint a {
  color: #16a34a;
  text-decoration: underline;
}

/* ---------- Buttons ---------- */
.acc-auth-btn {
  width: 100%;
  padding: 11px 14px;

  border: 0;
  border-radius: 12px;

  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
}

.acc-auth-btn--primary {
  background: linear-gradient(135deg, #22c55e, #16a34a);
  color: #0b1f17;
  box-shadow: 0 14px 32px rgba(22, 163, 74, 0.25);
}

/* ---------- OTP ---------- */
.acc-auth-otp-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.acc-auth-otp-inputs {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  margin-bottom: 10px;
}

.acc-auth-otp-inputs input {
  width: 42px;
  height: 42px;

  border-radius: 10px;
  border: 1px solid #d1d5db;

  text-align: center;
  font-size: 18px;
  font-weight: 700;
}

/* ---------- Error ---------- */
.acc-auth-otp-inputs.is-error {
  animation: acc-shake 0.35s ease;
}

.acc-auth-otp-inputs.is-error input {
  border-color: #e53935;
}

.acc-auth-error {
  margin-top: 8px;
  min-height: 1.2em;
  font-size: 13px;
  color: #e53935;
}

/* ---------- Footer ---------- */
.acc-auth-footer-note {
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px solid #e5e7eb;
  font-size: 11px;
  color: #9ca3af;
}

/* ---------- Animation ---------- */
@keyframes acc-shake {
  0% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-6px);
  }
  50% {
    transform: translateX(6px);
  }
  75% {
    transform: translateX(-4px);
  }
  100% {
    transform: translateX(0);
  }
}

/* ---------- Mobile ---------- */
@media (max-width: 480px) {
  .acc-modal {
    max-width: 100%;
    padding: 18px 16px 14px;
  }
}
