/**
 * RTL (Right-to-Left) Styles
 * For Arabic and Kurdish Sorani languages
 */

/* Apply RTL when body has rtl class */
body.rtl {
    direction: rtl;
    text-align: right;
}

/* ========== Text Alignment ========== */
body.rtl header,
body.rtl .card h2,
body.rtl .step-desc,
body.rtl footer {
    text-align: center; /* Keep centered elements centered */
}

/* ========== Buttons ========== */
body.rtl .btn {
    flex-direction: row-reverse; /* Reverse icon and text order */
}

/* ========== OTP Container ========== */
body.rtl .otp-container {
    flex-direction: row-reverse; /* OTP boxes flow right to left */
}

/* ========== Language Modal ========== */
body.rtl .language-btn {
    text-align: center;
}

/* ========== Messages ========== */
body.rtl .message {
    text-align: right;
}

/* ========== Forms ========== */
body.rtl input[type="email"],
body.rtl input[type="text"]:not(.otp-input) {
    text-align: right;
}

body.rtl input[type="email"]::placeholder,
body.rtl input[type="text"]::placeholder {
    text-align: right;
}

/* ========== Animations ========== */
body.rtl .spinner {
    margin-right: 0;
    margin-left: 10px;
}

/* ========== Language Switcher ========== */
body.rtl .language-switcher {
    direction: rtl;
}

/* ========== Font Adjustments ========== */
body.rtl {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif, 'Arial Unicode MS';
}

/* Better font rendering for Arabic */
body.rtl[lang="ar"],
body.rtl[lang="ku"] {
    font-family: 'Segoe UI', 'Tahoma', 'Arial', 'Helvetica', sans-serif;
    letter-spacing: 0;
}

/* Adjust line height for Arabic script */
body.rtl[lang="ar"] h1,
body.rtl[lang="ar"] h2,
body.rtl[lang="ku"] h1,
body.rtl[lang="ku"] h2 {
    line-height: 1.8;
}

/* ========== Keep Numbers LTR ========== */
body.rtl .otp-input {
    direction: ltr;
    text-align: center;
}

/* ========== Success Animation ========== */
body.rtl .success-animation {
    direction: ltr; /* Keep checkmark animation LTR */
}
