body {
    font-family: "Cairo", serif;
}

::-webkit-scrollbar {
    background-color: #ccc !important;
}

::-webkit-scrollbar-thumb {
    background-color: #e1b13e !important;
}

.logo img {
    height: max-content !important;
    margin-bottom: 20px;
    padding: 0;
    width: 150px;
    height: 150px;
}

select {
    width: 100%;
    padding: 10px;
    border: 0px solid #ccc;
    border-radius: 6px;
    font-size: 16px;
    background-color: #f7f7f7;
    cursor: pointer;
    outline: none;
    margin-bottom: 13px;
}

select:focus {
    border-color: #007bff;
    box-shadow: 0 0 5px rgba(64, 73, 82, 0.5);
}

input[type="text"],
input.form-control {
    text-align: right;
    direction: rtl;
}

img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 5%;
    margin-bottom: -10px;
}

.form-holder {
    margin-bottom: 500px;
}

.img-holder {
    display: block;
}

@media screen and (max-width: 1024px) {
    .img-holder {
        display: none !important;
    }
}

/* تعديل الـ sticky للصورة */
.img-holder {
    position: fixed;
    /* لجعل الصورة ثابتة عند التمرير */
    top: 0px;
    /* وضع الصورة في الجهة العليا */
    right: 20px;
    /* وضع الصورة على الجهة اليمنى */
    width: 700px;
    /* تحديد حجم الصورة الثابتة */
    height: auto;
}

.form-holder {
    padding-left: 20px;
    padding-right: 20px;
}

.ss {
    margin-top: 200px !important;
}

#signup-form input {
    padding: 15px;
    border-radius: 50px;
    width: 100% !important;
}

#signup-form select {
    padding: 15px;
    border-radius: 50px;
}

@media screen and (max-width: 768px) {
    input {
        width: 500px !important;
        /* تحديد عرض الفورم ليكون 90% في الشاشات الصغيرة */
        margin: 0 auto;
        /* لضمان أن الفورم يتمركز في وسط الصفحة */
    }
}

/* Success Modal Styles */
.success-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: none;
    z-index: 10000;
    align-items: center;
    justify-content: center;
}

.success-modal-content {
    background: white;
    border-radius: 20px;
    padding: 40px;
    text-align: center;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.5s ease-out;
}

@keyframes modalSlideIn {
    from {
        transform: scale(0.7) translateY(-50px);
        opacity: 0;
    }
    to {
        transform: scale(1) translateY(0);
        opacity: 1;
    }
}

.success-icon {
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, #4CAF50, #45a049);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 30px;
    font-size: 50px;
    color: white;
    animation: bounceIn 1s ease-out;
}

@keyframes bounceIn {
    0% {
        transform: scale(0.3);
        opacity: 0;
    }
    50% {
        transform: scale(1.05);
    }
    70% {
        transform: scale(0.9);
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.email-highlight {
    background: #f8f9fa;
    border: 2px solid #e1b13e;
    border-radius: 10px;
    padding: 20px;
    margin: 20px 0;
}

.email-highlight h4 {
    color: #e1b13e;
    margin-bottom: 10px;
}

.continue-btn {
    background: linear-gradient(135deg, #e1b13e 0%, #d4a029 100%);
    color: white;
    padding: 15px 40px;
    border: none;
    border-radius: 50px;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    margin-top: 20px;
    transition: all 0.3s ease;
}

.continue-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(225, 177, 62, 0.4);
}

/* إخفاء حقل عدد الأبناء */
.children-field {
    display: none;
    transition: all 0.3s ease;
}

.children-field.show {
    display: block;
}

/* إخفاء حقول بيانات الولي */
.guardian-fields {
    display: none;
    transition: all 0.3s ease;
    margin-bottom: 15px;
    padding: 20px;
    border: 2px solid #e1b13e;
    border-radius: 15px;
    background: linear-gradient(135deg, #fff8e1 0%, #fefefe 100%);
    box-shadow: 0 4px 15px rgba(225, 177, 62, 0.1);
}

.guardian-fields.show {
    display: block;
    animation: guardianFieldsSlideIn 0.5s ease-out;
}

@keyframes guardianFieldsSlideIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.guardian-header {
    text-align: center;
    margin-bottom: 20px;
    border-bottom: 2px solid #e1b13e;
    padding-bottom: 15px;
}

.guardian-header h4 {
    color: #e1b13e;
    font-size: 20px;
    font-weight: bold;
    margin: 0 0 10px 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.guardian-header .guardian-note {
    color: #666;
    font-size: 14px;
    margin: 0;
    font-style: italic;
}

.guardian-fields input {
    background: white;
    border: 2px solid #e9ecef;
    transition: all 0.3s ease;
}

.guardian-fields input:focus {
    border-color: #e1b13e;
    box-shadow: 0 0 10px rgba(225, 177, 62, 0.3);
    background: #fefefe;
}

.guardian-fields input.error {
    border-color: #dc3545;
    background: #fff5f5;
    animation: shake 0.5s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

/* تنسيق حقل العمر للقراءة فقط */
input[readonly] {
    background-color: #e9ecef !important;
    cursor: not-allowed;
    color: #6c757d;
}

/* تنسيق Modal شروط الاستخدام */
.terms-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    z-index: 10001;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.terms-modal-content {
    background: white;
    border-radius: 15px;
    padding: 30px;
    max-width: 800px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.5s ease-out;
    direction: rtl;
    text-align: right;
}

.terms-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    border-bottom: 2px solid #e1b13e;
    padding-bottom: 15px;
}

.terms-modal-header h2 {
    color: #e1b13e;
    margin: 0;
    font-size: 24px;
}

.close-modal {
    background: none;
    border: none;
    font-size: 30px;
    cursor: pointer;
    color: #666;
    padding: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.close-modal:hover {
    background: #f5f5f5;
    color: #e1b13e;
}

.terms-content {
    line-height: 1.8;
    color: #333;
    font-size: 16px;
}

.terms-content h3 {
    color: #e1b13e;
    margin: 25px 0 15px 0;
    font-size: 20px;
}

.terms-content p {
    margin-bottom: 15px;
}

.terms-content ul {
    margin-right: 20px;
    margin-bottom: 15px;
}

.terms-content li {
    margin-bottom: 8px;
}

.modal-footer {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #eee;
    text-align: center;
}

.accept-terms-btn {
    background: linear-gradient(135deg, #e1b13e 0%, #d4a029 100%);
    color: white;
    padding: 12px 30px;
    border: none;
    border-radius: 50px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.accept-terms-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(225, 177, 62, 0.4);
}

/* تصميم checkbox مخصص على شكل علامة صح */
.custom-checkbox {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    margin-bottom: 20px;
    cursor: pointer;
    user-select: none;
    padding: 15px;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    background: #f8f9fa;
    transition: all 0.3s ease;
}

.custom-checkbox:hover {
    border-color: #e1b13e;
    background: #fefefe;
}

.custom-checkbox.checked {
    border-color: #e1b13e;
    background: #fff8e1;
}

/* إخفاء checkbox الافتراضي */
.custom-checkbox input[type="checkbox"] {
    display: none;
}

/* تصميم checkbox مخصص */
.checkmark {
    width: 25px;
    height: 25px;
    border: 2px solid #ccc;
    border-radius: 6px;
    margin-left: 15px;
    position: relative;
    transition: all 0.3s ease;
    background: white;
    cursor: pointer;
}

.checkmark:hover {
    border-color: #e1b13e;
    box-shadow: 0 0 10px rgba(225, 177, 62, 0.3);
}

/* علامة الصح */
.checkmark::after {
    content: "✓";
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%) scale(0);
    color: white;
    font-size: 16px;
    font-weight: bold;
    transition: all 0.3s ease;
}

/* عند التحديد */
.custom-checkbox input[type="checkbox"]:checked + .checkmark {
    background: linear-gradient(135deg, #e1b13e 0%, #d4a029 100%);
    border-color: #e1b13e;
    box-shadow: 0 4px 15px rgba(225, 177, 62, 0.4);
}

.custom-checkbox input[type="checkbox"]:checked + .checkmark::after {
    transform: translate(-50%, -50%) scale(1);
}

.checkbox-text {
    font-size: 15px;
    color: #555;
    line-height: 1.5;
    font-weight: 500;
}

.terms-link {
    color: #e1b13e !important;
    text-decoration: underline;
    font-weight: bold;
    transition: color 0.3s ease;
}

.terms-link:hover {
    color: #d4a029 !important;
    text-decoration: none;
}

/* تأكد من ظهور checkbox في جميع المتصفحات */
input[type="checkbox"] {
    -webkit-appearance: checkbox;
    -moz-appearance: checkbox;
    appearance: checkbox;
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* تنسيق حقل كلمة المرور مع أيقونة العين */
.password-field {
    position: relative;
    margin-bottom: 13px;
}

.password-toggle {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: #666;
    z-index: 10;
}

.password-toggle:hover {
    color: #333;
}

/* تنسيق حقل الاختيار مع الإدخال */
.select-or-input {
    position: relative;
    margin-bottom: 13px;
}

.select-or-input select,
.select-or-input input {
    margin-bottom: 0;
}

.manual-input {
    display: none;
    margin-top: 5px;
}

.manual-input.show {
    display: block;
}

.toggle-manual {
    font-size: 12px;
    color: #007bff;
    cursor: pointer;
    text-decoration: underline;
    margin-top: 5px;
    display: block;
}

/* تنسيق خاص لحقول بيانات الولي في الموبايل */
@media screen and (max-width: 768px) {
    .guardian-fields {
        padding: 15px;
        margin: 10px 0;
    }

    .guardian-header h4 {
        font-size: 18px;
    }

    .guardian-header .guardian-note {
        font-size: 12px;
    }

    .guardian-fields input {
        padding: 12px;
        font-size: 14px;
    }
}

/* تأثيرات بصرية إضافية لحقول بيانات الولي */
.guardian-fields input:valid {
    border-color: #28a745;
}

.guardian-fields input:valid:focus {
    border-color: #28a745;
    box-shadow: 0 0 10px rgba(40, 167, 69, 0.3);
}

/* رسالة تحذيرية عندما تكون البيانات مطلوبة */
.guardian-required-warning {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    border: 2px solid #ffc107;
    border-radius: 10px;
    padding: 15px;
    margin: 10px 0;
    text-align: center;
    color: #856404;
    font-weight: bold;
    animation: warningPulse 2s infinite;
}

@keyframes warningPulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 193, 7, 0.4);
    }
    50% {
        transform: scale(1.02);
        box-shadow: 0 0 0 10px rgba(255, 193, 7, 0);
    }
}

/* تحسين التباعد للعناصر */
.form-content .form-items > * {
    margin-bottom: 15px;
}

/* تنسيق خاص للأيقونات في حقول بيانات الولي */
.guardian-fields .fa {
    color: #e1b13e;
}

/* تأثير hover لحقول بيانات الولي */
.guardian-fields input:hover {
    border-color: #e1b13e;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(225, 177, 62, 0.2);
}