/* ✅ تنسيق عام لنموذج الاتصال */
#customContactForm {
    max-width: 400px;
    margin: auto;
    padding: 20px;
    border-radius: 5px;
    background-color: #f9f9f9;
}

#customContactForm input,
#customContactForm select,
.phone-container {
    margin-bottom: 10px;
}

#customContactForm button {
    background-color: var(--theme-button-background-initial-color);
    color: white;
    padding: 10px;
    border: none;
    border-radius: var(--theme-button-border-radius, 3px);
    cursor: pointer;
    width: 100%;
    transition: background-color 0.3s ease-in-out;
}

#customContactForm button:hover {
    background-color: var(--theme-button-background-hover-color);
}

/* ✅ تنسيق الإشعارات */
.custom-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background-color: rgba(72, 72, 72, 0.9);
    color: white;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.1);
    z-index: 9999;
    transition: opacity 0.5s ease-in-out, transform 0.3s ease-in-out;
}

/* ألوان الإشعارات */
.custom-notification.success {
    background-color: rgba(40, 167, 69, 0.9);
}

.custom-notification.error {
    background-color: rgba(220, 53, 69, 0.9);
}

/* تأثير الاختفاء */
.custom-notification.fade-out {
    opacity: 0;
    transform: translateY(-10px);
}

/* ✅ أيقونة التحميل داخل زر الإرسال */
.spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid white;
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
    margin-right: 8px;
    vertical-align: middle;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ✅ ضبط عرض قائمة الدول لتناسب عرض الحقل */
.iti {
    width: 100%;
    position: relative;
}

.iti__country-list {
    position: absolute;
    left: 0;
    border-radius: 4px;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.2);
    background-color: white;
    z-index: 9999;
    max-height: 250px;
    overflow-y: auto;
    min-width: 100%;
}

/* ✅ تحسين محاذاة الأعلام داخل القائمة */
.iti__country {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    font-size: 14px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* تحسين تفاعل المستخدم مع القائمة */
.iti__country:hover,
.iti__country.iti__highlight {
    background-color: #f5f5f5;
    cursor: pointer;
}

/* ✅ ضبط الحاوية لتكون مرنة */
.input-container {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
}

/* ✅ ضبط تنسيق حقل الإدخال */
.input-container input {
    width: 100%;
    padding: 10px;
    padding-right: 45px; /* ترك مساحة كافية للأيقونة */
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 16px;
}

/* ✅ ضبط الأيقونة داخل الحقل */
.input-container .input-icon {
    position: absolute;
    right: 15px; /* إبعاد الأيقونة قليلاً عن الحافة اليمنى */
    top: 50%;
    transform: translateY(-50%);
    width: 18px; /* ضبط حجم الأيقونة */
    height: 18px;
    pointer-events: none; /* منع التأثير على الإدخال */
}

/* ✅ تحسين placeholder */
.input-container input::placeholder,
.phone-container input::placeholder {
    font-size: 12px;
    color: #999;
    opacity: 1;
    padding-right: 25px;
}

/* جعل placeholder يظهر على اليمين */
#phone::placeholder {
    text-align: right;
    direction: rtl;
}

/* عند الكتابة، يعود الاتجاه لليسار */
#phone {
    text-align: left;
    direction: ltr;
}
