/* أنماط أساسية */
.ape-edit-wrapper {
    max-width: 900px;
    margin: 0 auto;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
    overflow: hidden;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.ape-edit-header {
    padding: 20px;
    background: #0073aa;
    color: white;
}

.ape-edit-header h2 {
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.ape-notice, .ape-error {
    padding: 15px;
    margin: 20px 0;
    border-radius: 4px;
    text-align: center;
}

.ape-notice {
    background: #f0f7fc;
    border-left: 4px solid #0073aa;
}

.ape-error {
    background: #fcf0f0;
    border-left: 4px solid #dc3232;
}

/* نظام الشبكة */
.ape-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    padding: 25px;
    box-shadow: 2px 2px 2px 2px #eee;
}

@media (max-width: 768px) {
    .ape-form-grid {
        grid-template-columns: 1fr;
    }
}

.ape-form-group {
    margin-bottom: 20px;
}

/* حقول الإدخال */
.ape-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 8px;
}

.ape-input, .ape-select, .ape-textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 15px;
    transition: all 0.3s;
}

.ape-input:focus, .ape-select:focus, .ape-textarea:focus {
    border-color: #0073aa;
    box-shadow: 0 0 0 2px rgba(0,115,170,0.2);
    outline: none;
}

.ape-textarea {
    min-height: 120px;
    resize: vertical;
}

/* رفع الملفات */
.ape-file-upload {
    position: relative;
}

.ape-upload-label {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px;
    background: #f5f5f5;
    border: 2px dashed #ddd;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s;
}

.ape-upload-label:hover {
    border-color: #0073aa;
    background: #f0f7fc;
}

.ape-file-input {
    position: absolute;
    opacity: 0;
    width: 0.1px;
    height: 0.1px;
}

.ape-preview {
    margin-top: 10px;
}

.ape-preview-image {
    max-width: 100%;
    max-height: 150px;
    border-radius: 4px;
    border: 1px solid #eee;
}

.ape-file-info {
    margin-top: 10px;
    font-size: 14px;
}

/* قسم الاتصال */
.ape-contact-section {
    padding: 0 25px 25px;
    border-top: 1px solid #eee;
}

.ape-contact-section h3 {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.ape-contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

/* تذييل النموذج */
.ape-form-footer {
    padding: 20px 25px;
    background: #f9f9f9;
    border-top: 1px solid #eee;
    text-align: right;
}

.ape-submit-button {
    background: #0073aa;
    color: white;
    border: none;
    padding: 12px 25px;
    font-size: 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.ape-submit-button:hover {
    background: #005e8a;
    transform: translateY(-2px);
}




/* =============================================
   Adoma File Manager - Main Stylesheet
   Version: 1.2
   Author: Adam Maged
============================================= */

/* =====================
   Base Styles
===================== */

.page-id-49734 .media img {
	height: 100px !important;
}









.afm-file-page {
    display: flex;
    justify-content: center;
    background: #f5f5f5;
    padding: 30px 0;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
  min-height: 580px !important;

}

.afm-file-container {
    background: #fff;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.1);
    width: 95%;
    max-width: 900px;
    margin: 0 auto;
}

.afm_file-template-default2 #footer-page2 {
	bottom: 0 !important;
	position: fixed !important;
	width: 100% !important;
}

#top.page-id-49690 {direction:ltr !important;}

/* =====================
   Typography
===================== */
.afm-file-title {
    text-align: center;
    font-size: 28px;
    #margin-bottom: 30px;
    color: #2c3e50;
    #padding-bottom: 15px;
    #border-bottom: 1px solid #eee;
}

.afm-file-card strong {
    color: #2c3e50;
    font-weight: 600;
}

.afm-description {
    margin-top: 20px;
    padding: 15px;
    background: #f9f9f9;
    border-radius: 5px;
    border-left: 4px solid #0073aa;
}

/* =====================
   Layout Components
===================== */
.afm-file-card {
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
    direction: ltr !important;
}

.afm-file-left {
    flex: 1;
    min-width: 200px;
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

.afm-file-right {
    flex: 2;
    min-width: 250px;
}

/* =====================
   Logo Styles
===================== */
.afm-logo {
    max-width: 100%;
    max-height: 200px;
    border-radius: 5px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    object-fit: contain;
}

/* =====================
   File Actions
===================== */
.afm-file-actions {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #eee;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
}

.afm-file-name {
    font-weight: bold;
    color: #333;
    flex: 1;
    min-width: 200px;
    word-break: break-all;
}

.afm-action-buttons {
    display: flex;
    gap: 15px;
}

.afm-preview-btn,
.afm-download-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    text-decoration: none;
    transition: all 0.3s ease;
}

.afm-preview-btn {
    background: #3498db;
    color: white;
}

.afm-download-btn {
    background: #2ecc71;
    color: white;
}

.afm-preview-btn:hover {
    background: #2980b9;
    transform: translateY(-2px);
}

.afm-download-btn:hover {
    background: #27ae60;
    transform: translateY(-2px);
}

/* =====================
   Responsive Design
===================== */
@media (max-width: 768px) {
    .afm-file-card {
        flex-direction: column;
	direction: ltr !important;
    }
    
    .afm-file-left,
    .afm-file-right {
        flex: 1 1 100%;
    }
    
    .afm-file-actions {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .afm-action-buttons {
        margin-top: 10px;
    }
}

/* =====================
   Form Styles (for upload form)
===================== */
#afm-upload-form {
    max-width: 800px;
    margin: 0 auto;
    padding: 30px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

#afm-upload-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #2c3e50;
}

#afm-upload-form input[type="text"],
#afm-upload-form input[type="email"],
#afm-upload-form input[type="url"],
#afm-upload-form select,
#afm-upload-form textarea {
    width: 100%;
    padding: 10px 15px;
    margin-bottom: 20px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    transition: border-color 0.3s;
    text-align: left !important;
}

#afm-upload-form input[type="text"]:focus,
#afm-upload-form input[type="email"]:focus,
#afm-upload-form input[type="url"]:focus,
#afm-upload-form select:focus,
#afm-upload-form textarea:focus {
    border-color: #0073aa;
    outline: none;
}

#afm-upload-form textarea {
    min-height: 120px;
    resize: vertical;
}

#afm-upload-form input[type="file"] {
    margin-bottom: 20px;
}

#afm-upload-form input[type="submit"] {
    background: #0073aa;
    color: white;
    border: none;
    padding: 12px 25px;
    font-size: 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.3s;
}

#afm-upload-form input[type="submit"]:hover {
    background: #005e8a;
}

.afm-description-content {
    white-space: pre-line; /* يحترم الأسطر الجديدة والمسافات */
    line-height: 1.6;
    margin-top: 10px;
}

.typewriter-content {
    white-space: pre-wrap; /* يحافظ على المسافات والأسطر */
    line-height: 1.6;
}

.typewriter-content br {
    display: block;
    content: "";
    margin-bottom: 12px;
}



/* Full-width Group */
.afm-full-width-group {
    padding: 0 25px;
    margin: 20px 0;
    grid-column: 1 / -1;
}

.afm-full-width-group .afm-textarea {
    min-height: 150px;
    width: 100%;
}

/* Responsive Adjustments */
@media (max-width: 782px) {
    .afm-full-width-group {
        padding: 0 15px;
    }
    
    .afm-form-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
}

/* Enhanced Textarea Styling */
.afm-textarea {
    transition: all 0.3s ease;
    border: 1px solid #ddd;
    padding: 12px;
}

.afm-textarea:focus {
    border-color: #0073aa;
    box-shadow: 0 0 0 1px #0073aa;
}


/* تنسيق التصنيفات المتدرجة */
.afm-category-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

@media (max-width: 600px) {
    .afm-category-group {
        grid-template-columns: 1fr;
    }
}

.afm-subcategory-loading {
    position: relative;
}

.afm-subcategory-loading::after {
    content: "";
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    border: 2px solid #ddd;
    border-top-color: #0073aa;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: translateY(-50%) rotate(360deg); }
}

/* هيكل أساسي */
.afm-upload-wrapper {
    max-width: 900px;
    margin: 0 auto;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
    overflow: hidden;
}

.afm-upload-header {
    padding: 20px;
    background: #0073aa;
    color: white;
    position: relative;
}

.afm-upload-header h2 {
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.afm-progress-bar {
    height: 4px;
    background: rgba(255,255,255,0.3);
    margin-top: 15px;
    border-radius: 2px;
    overflow: hidden;
}

.afm-progress-fill {
    height: 100%;
    width: 0;
    background: #fff;
    transition: width 0.3s ease;
}

/* نظام الشبكة */
.afm-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    padding: 25px;
}

@media (max-width: 768px) {
    .afm-form-grid {
        grid-template-columns: 1fr;
    }
}

.afm-form-group {
    margin-bottom: 20px;
}

/* حقول الإدخال */
.afm-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 8px;
}

.afm-input, .afm-select, .afm-textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 15px;
    transition: all 0.3s;
}

.afm-input:focus, .afm-select:focus, .afm-textarea:focus {
    border-color: #0073aa;
    box-shadow: 0 0 0 2px rgba(0,115,170,0.2);
    outline: none;
}

.afm-textarea {
    min-height: 120px;
    resize: vertical;
}

/* رفع الملفات */
.afm-file-upload {
    position: relative;
}

.afm-upload-label {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px;
    background: #f5f5f5;
    border: 2px dashed #ddd;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s;
}

.afm-upload-label:hover {
    border-color: #0073aa;
    background: #f0f7fc;
}

.afm-file-input {
    position: absolute;
    opacity: 0;
    width: 0.1px;
    height: 0.1px;
}

.afm-preview {
    margin-top: 10px;
}

.afm-preview-image {
    max-width: 100%;
    max-height: 150px;
    border-radius: 4px;
    border: 1px solid #eee;
}

.afm-file-info {
    margin-top: 10px;
    font-size: 14px;
}

/* قسم الاتصال */
.afm-contact-section {
    padding: 0 25px 25px;
    border-top: 1px solid #eee;
}

.afm-contact-section h3 {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.afm-contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

/* تذييل النموذج */
.afm-form-footer {
    padding: 20px 25px;
    background: #f9f9f9;
    border-top: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.afm-submit-button {
    background: #0073aa;
    color: white;
    border: none;
    padding: 12px 25px;
    font-size: 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.afm-submit-button:hover {
    background: #005e8a;
    transform: translateY(-2px);
}

.afm-required-hint {
    font-size: 13px;
    color: #666;
}

/* أيقونات دشبورد */
.dashicons {
    font-size: 18px;
    width: auto;
    height: auto;
}



/* Full-width Group */
.afm-full-width-group {
    padding: 0 25px;
    margin: 20px 0;
    grid-column: 1 / -1;
}

.afm-full-width-group .afm-textarea {
    min-height: 150px;
    width: 100%;
}

/* Responsive Adjustments */
@media (max-width: 782px) {
    .afm-full-width-group {
        padding: 0 15px;
    }
    
    .afm-form-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
}

/* Enhanced Textarea Styling */
.afm-textarea {
    transition: all 0.3s ease;
    border: 1px solid #ddd;
    padding: 12px;
}

.afm-textarea:focus {
    border-color: #0073aa;
    box-shadow: 0 0 0 1px #0073aa;
}


.typewriter-content {
    white-space: pre-wrap; /* يحافظ على المسافات والأسطر */
    line-height: 1.6;
    margin-top: 10px;
}

.typewriter-content br {
    display: block;
    content: "";
    margin-bottom: 12px; /* زيادة المسافة بين الأسطر */
}

.typewriter-cursor::after {
    content: "|";
    animation: blink 1s infinite;
    color: #0073aa;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}


.afm-edit-link-container {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid #eee;
}

.afm-edit-link {
    display: inline-block;
    padding: 8px 15px;
    background-color: #2271b1;
    color: white !important;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
}

.afm-edit-link:hover {
    background-color: #135e96;
}

.afm-edit-link .dashicons {
    font-size: 16px;
    vertical-align: middle;
    margin-left: 5px;
}
.typewriter-content strong {
    font-weight: bold;
    color: #2c3e50; /* لون داكن للجزء البولد */
}

.typewriter-content {
    white-space: pre-wrap;
    line-height: 1.6;
}



.afm-description .typewriter-content {
    direction: ltr; /* أو rtl حسب اللغة */
    line-height: 1.6;
    text-align: left;
    white-space: pre-wrap; /* للحفاظ على الأسطر */
    text-indent: -1em;     /* يرفع السطر الأول */
    padding-left: 1em;     /* يُدخل الأسطر التالية */
}

.afm-description {
    background: #f9f9f9;
    border-radius: 8px;
    padding: 1em 1.5em;
    border-left: 5px solid #006699;
    font-family: sans-serif;
    color: #333;
}

.typewriter-content p {
    margin: 0 0 0.7em;
    text-align: left;
    line-height: 1.6;
    text-indent: -1.5em;
    padding-left: 1.5em;
    white-space: pre-wrap;
}

.typewriter-content strong {
    font-weight: 700;
    color: #1e3a5f;
}




.typewriter-content p {
    position: relative;
    margin: 0 0 0.7em;
    text-align: left;
    line-height: 1.6;
    text-indent: -1.5em;
    padding-left: 2em; /* زادنا المسافة عشان البولت */
    white-space: pre-wrap;
}

.typewriter-content p::before {
    content: "•";
    position: absolute;
    left: 0;
    top: 0;
    color: #006699; /* لون البولت */
    font-weight: bold;
    font-size: 1em;
    line-height: 1.6;
}

.afm-edit-btn-container {
    margin: 25px 0;
    text-align: center;
}

.afm-edit-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: #2184f7;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.afm-edit-btn:hover {
    background: #1a6bc9;
    transform: translateY(-2px);
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.afm-edit-btn .dashicons {
    font-size: 16px;
    height: auto;
    width: auto;
}


/* تنسيق قسم الصورة */
.afm-file-left {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
}

/* تنسيق زر التعديل */
.afm-edit-btn-container {
    width: 100%;
    text-align: center;
    margin-top: 10px;
}

.afm-edit-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 8px 15px;
    width: 80%;
    max-width: 200px;
    background: #2184f7;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.3s ease;
    font-size: 14px;
}

.afm-edit-btn:hover {
    background: #1a6bc9;
    transform: translateY(-2px);
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.afm-edit-btn .dashicons {
    font-size: 16px;
    height: auto;
    width: auto;
}

/* تنسيقات متعدد التصنيفات */
.afm-multiselect-container {
    max-height: 200px;
    overflow-y: auto;
    border: 1px solid #ddd;
    padding: 10px;
    border-radius: 4px;
    background: #f9f9f9;
}

.afm-checkbox-label {
    display: block;
    padding: 8px;
    margin: 2px 0;
    background: #fff;
    border-radius: 3px;
    cursor: pointer;
}

.afm-checkbox-label:hover {
    background: #f0f0f0;
}






.afm-select[multiple] {
    height: auto;
    min-height: 100px;
    padding: 5px;
}

.afm-select[multiple] option {
    padding: 5px;
    margin: 2px 0;
}

/* تنسيقات متعددة الاختيار */
.afm-multiselect-container {
    max-height: 200px;
    overflow-y: auto;
    border: 1px solid #ddd;
    padding: 10px;
    border-radius: 4px;
    background: #f9f9f9;
    margin-top: 5px;
}

.afm-checkbox-label {
    display: block;
    padding: 8px 10px;
    margin: 2px 0;
    background: #fff;
    border-radius: 3px;
    cursor: pointer;
    transition: all 0.2s;
}

.afm-checkbox-label:hover {
    background: #f0f0f0;
}

.afm-checkbox-label input {
    margin-right: 8px;
}

.afm-no-subcategories {
    color: #666;
    font-style: italic;
    text-align: center;
    padding: 15px;
}

/* شريط التمرير */
.afm-multiselect-container::-webkit-scrollbar {
    width: 8px;
}

.afm-multiselect-container::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.afm-multiselect-container::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
}

.afm-multiselect-container::-webkit-scrollbar-thumb:hover {
    background: #aaa;
}









.ape-edit-wrapper {
    max-width: 1000px;
    margin: 40px auto;
    background: #fefefe;
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.07);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.ape-edit-header h2 {
    font-size: 26px;
    margin-bottom: 30px;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 10px;
}

.ape-form-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    margin-bottom: 30px;
}

.ape-form-column {
    flex: 1 1 48%;
    min-width: 300px;
}

.ape-form-group {
    margin-bottom: 24px;
    direction: ltr !important;
}

.ape-label {
    display: block;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
}

.ape-input,
.ape-select,
.ape-textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #d1d1d1;
    border-radius: 10px;
    font-size: 15px;
    transition: border-color 0.3s ease;
    box-sizing: border-box;
}

.ape-input:focus,
.ape-select:focus,
.ape-textarea:focus {
    border-color: #0073aa;
    outline: none;
}

.ape-textarea {
    resize: vertical;
    min-height: 120px;
}

.ape-contact-section {
    margin-top: 40px;
}

.ape-contact-section h3 {
    font-size: 20px;
    color: #0073aa;
    margin-bottom: 20px;
}

.ape-contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
}

.ape-file-upload {
    background: #f0f4f8;
    padding: 15px;
    border-radius: 10px;
    border: 2px dashed #c3cfd9;
    text-align: center;
}

.ape-upload-label {
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: #0073aa;
    font-weight: 500;
    transition: color 0.3s ease;
}

.ape-upload-label:hover {
    color: #005f8d;
    text-decoration: underline;
}

.ape-preview-image {
    max-width: 100%;
    height: auto;
    margin-top: 10px;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.ape-file-meta {
    font-size: 14px;
    color: #444;
    margin-top: 12px;
}

.ape-form-footer {
    text-align: center;
    margin-top: 40px;
}

.ape-submit-button {
    background: linear-gradient(135deg, #0073aa, #005f8d);
    color: #fff;
    padding: 14px 32px;
    border: none;
    border-radius: 30px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ape-submit-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 115, 170, 0.3);
}
#ape-edit-form {
	box-shadow: #0073aa 0px 2px 2px 0px;
	padding: 40px;
	direction: ltr !important;
	text-align: left !important;
}


.ape-input, #ape_description {
	text-align: left !important;
	direction: ltr !important;
}


/* تحسين مظهر Select2 */
.select2-container--default .select2-selection--multiple {
    border: 1px solid #ddd;
    border-radius: 4px;
    min-height: 36px;
    padding: 2px;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice {
    background-color: #f5f5f5;
    border: 1px solid #ddd;
    border-radius: 3px;
    padding: 0 5px;
    margin: 3px;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice__remove {
    margin-right: 5px;
    color: #999;
}

/* تحسين المساحة البادئة للتصنيفات الفرعية */
.select2-results__option {
    padding-left: 15px !important;
}

.select2-results__option[aria-level="2"] {
    padding-left: 30px !important;
}

.select2-results__option[aria-level="3"] {
    padding-left: 45px !important;
}

/* تحسين عام لـ Select2 */
.select2-container {
    width: 100% !important;
    margin-bottom: 15px;
}

.select2-selection {
    min-height: 42px !important;
    padding: 5px 10px !important;
    font-size: 15px !important;
    line-height: 1.5 !important;
}

.select2-selection__choice {
    background: #f8f9fa !important;
    border: 1px solid #dee2e6 !important;
    border-radius: 4px !important;
    color: #333 !important;
    font-size: 14px !important;
}

.select2-selection__choice__remove {
    color: #6c757d !important;
    margin-right: 5px !important;
}

/* تحسين القائمة المنسدلة */
.select2-dropdown {
    border: 1px solid #ced4da !important;
    border-radius: 4px !important;
}

.select2-results__option {
    padding: 8px 12px !important;
    font-size: 14px !important;
}

/* المسافة البادئة للتصنيفات الفرعية */
.select2-results__option[aria-level="1"] {
    padding-left: 15px !important;
}

.select2-results__option[aria-level="2"] {
    padding-left: 30px !important;
    font-style: italic;
}

/* عند التحديد */
.select2-results__option--highlighted {
    background-color: #007bff !important;
    color: white !important;
}

.select2-search__field::placeholder {
    font-family: 'dashicons';
    content: "\f179";
}



/* مربع البحث */
.select2-search--dropdown {
    padding: 8px;
    background: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
}

.select2-search__field {
    width: 100% !important;
    padding: 6px 12px !important;
    border: 1px solid #ced4da !important;
    border-radius: 4px !important;
    font-size: 14px !important;
    text-align: right !important;
}

/* أيقونة البحث */
.select2-search__field::placeholder {
    text-align: right;
    color: #6c757d;
}

/* تعديلات خاصة باللغة العربية */
.select2-container--default .select2-results__option {
    text-align: right;
    padding-right: 20px;
}

/* المسافات البادئة للتصنيفات الفرعية */
.select2-results__option[aria-level="1"] {
    padding-right: 15px !important;
}

.select2-results__option[aria-level="2"] {
    padding-right: 30px !important;
    position: relative;
}

/* إضافة سهم للتصنيفات الفرعية */
.select2-results__option[aria-level="2"]::before {
    content: "→ ";
    position: absolute;
    right: 10px;
    color: #6c757d;
}


.select2-search.select2-search--inline {
	width: 100% !important;
}


.select2-selection__rendered {
	text-align: left !important;
	direction: ltr !important;
}


/* إعادة تعيين اتجاه النص */
.select2-container--default .select2-selection--multiple,
.select2-container--default .select2-search--inline,
.select2-container--default .select2-search__field,
.select2-container--default .select2-results__option {
    text-align: left !important;
    direction: ltr !important;
}

/* تعديل مواضع العناصر */
.select2-container--default .select2-selection__choice {
    float: left !important;
    margin-right: 5px !important;
    margin-left: 0 !important;
}

/* تعديل المسافات البادئة للتصنيفات الفرعية */
.select2-results__option[aria-level="1"] {
    padding-left: 15px !important;
    padding-right: 0 !important;
}

.select2-results__option[aria-level="2"] {
    padding-left: 30px !important;
    padding-right: 0 !important;
}

/* أيقونة السهم للتصنيفات الفرعية */
.select2-results__option[aria-level="2"]::before {
    content: "← " !important;
    left: 10px !important;
    right: auto !important;
}

/* مربع البحث */
.select2-search--dropdown .select2-search__field {
    text-align: left !important;
    padding-left: 10px !important;
    padding-right: 30px !important;
}

/* أيقونة البحث */
.select2-search--dropdown::after {
    left: 15px !important;
    right: auto !important;
}