/* 
 * إعدادات الثيم لصفحات التفاصيل
 * Theme settings for details pages
 */

/* متغيرات الألوان للوضع الفاتح */
:root {
    --details-bg-primary: #ffffff;
    --details-bg-secondary: #f8f9fa;
    --details-bg-tertiary: #e9ecef;
    --details-text-primary: #2c3e50;
    --details-text-secondary: #555555;
    --details-text-muted: #666666;
    --details-border-color: #e9ecef;
    --details-shadow-light: rgba(0, 0, 0, 0.08);
    --details-shadow-medium: rgba(0, 0, 0, 0.15);
    --details-accent-primary: #6B41FF;
    --details-accent-secondary: #A0EA71;
    --details-success: #28a745;
    --details-info: #17a2b8;
    --details-warning: #ffc107;
    --details-danger: #dc3545;
}

/* إعادة تعريف الألوان الأساسية */
.service-details-section,
.project-details-section {
    background: linear-gradient(135deg, var(--details-bg-secondary) 0%, var(--details-bg-tertiary) 100%);
    color: var(--details-text-primary);
}

/* الخلفيات البيضاء */
.service-details-wrapper,
.project-details-wrapper,
.service-feature-item,
.feature-item,
.process-step,
.service-info-widget,
.project-info-widget,
.contact-widget,
.stat-item,
.gallery-item,
.benefits-list li {
}

/* النصوص الرئيسية */
.service-details-content h1,
.project-details-content h1,
.service-title,
.project-title {
    color: var(--details-text-primary) !important;
}

.service-details-content h2,
.project-details-content h2 {
    color: var(--details-text-primary) !important;
}

.service-details-content h3,
.project-details-content h3 {
    color: var(--details-text-primary) !important;
    border-bottom-color: var(--details-accent-primary) !important;
}

.service-details-content h4,
.project-details-content h4,
.feature-content h4,
.step-content h4 {
    color: var(--details-text-primary) !important;
}

.service-details-content h5,
.project-details-content h5,
.project-content h5,
.related-project-content h5 {
    color: var(--details-text-primary) !important;
}

.service-details-content h6,
.project-details-content h6 {
    color: var(--details-text-primary) !important;
}

/* النصوص الثانوية */
.service-details-content p,
.project-details-content p,
.service-subtitle,
.project-category,
.feature-content p,
.step-content p,
.project-content p,
.related-project-content p {
    color: var(--details-text-secondary) !important;
}

/* النصوص المكتومة */
.service-info-list .label,
.project-info-list .label {
    color: var(--details-text-muted) !important;
}

.service-info-list .value,
.project-info-list .value {
    color: var(--details-text-primary) !important;
}

/* قائمة الفوائد */
.benefits-list li {
    color: var(--details-text-secondary) !important;
    border-bottom-color: var(--details-border-color) !important;
}

.benefits-list li i {
    color: var(--details-success) !important;
}

/* أيقونات الميزات */
.feature-icon {
    background: linear-gradient(135deg, var(--details-accent-primary), var(--details-accent-secondary)) !important;
    color: #ffffff !important;
}

/* أرقام الخطوات */
.step-number {
    background: linear-gradient(135deg, var(--details-accent-primary), var(--details-accent-secondary)) !important;
    color: #ffffff !important;
}

/* شارات التقنيات */
.tech-badge {
    background: linear-gradient(135deg, var(--details-accent-primary), var(--details-accent-secondary)) !important;
    color: #ffffff !important;
}

/* الإحصائيات */
.stat-item h4 {
    color: var(--details-accent-primary) !important;
}

.stat-item p {
    color: var(--details-text-muted) !important;
}

/* الروابط */
.service-details-content a,
.project-details-content a,
.read-more {
    color: var(--details-accent-primary) !important;
}

.service-details-content a:hover,
.project-details-content a:hover,
.read-more:hover {
    color: var(--details-accent-secondary) !important;
}

.project-content h5 a,
.related-project-content h5 a {
    color: var(--details-text-primary) !important;
}

.project-content h5 a:hover,
.related-project-content h5 a:hover {
    color: var(--details-accent-primary) !important;
}



/* ويدجت الاتصال */
.contact-widget {
    background: linear-gradient(135deg, var(--details-accent-primary), var(--details-accent-secondary)) !important;
    color: #ffffff !important;
}

.contact-widget h4 {
    color: #ffffff !important;
    border-bottom-color: rgba(255, 255, 255, 0.3) !important;
}

.contact-widget p {
    color: rgba(255, 255, 255, 0.9) !important;
}

/* الأقسام ذات الخلفيات المتدرجة */

.service-features,
.project-features,
.service-benefits,
.service-process,
.project-gallery,
.project-results {
    background-color: var(--details-bg-primary) !important;
}

/* الشريط الجانبي */
.service-sidebar,
.project-sidebar {
    background-color: var(--details-bg-secondary) !important;
}

/* تأثيرات التمرير */
.service-feature-item:hover,
.feature-item:hover,
.process-step:hover,
.related-project-card:hover,
.related-project-item:hover,
.stat-item:hover {
    border-color: var(--details-accent-primary) !important;
    box-shadow: 0 15px 35px var(--details-shadow-medium) !important;
}

.benefits-list li:hover {
    border-color: var(--details-accent-primary) !important;
    box-shadow: 0 5px 15px rgba(107, 65, 255, 0.2) !important;
}

/* معرض الصور */
.gallery-overlay {
    background: rgba(107, 65, 255, 0.8) !important;
}

.popup-image {
    color: #ffffff !important;
}

/* مؤشر التقدم */
.reading-progress {
    background-color: rgba(0, 0, 0, 0.1) !important;
}

.reading-progress-fill {
    background: linear-gradient(90deg, var(--details-accent-primary), var(--details-accent-secondary)) !important;
}

/* تحسينات للطباعة */
@media print {
    .service-details-section,
    .project-details-section,
    .service-details-wrapper,
    .project-details-wrapper {
        color: #000000 !important;
    }
    
    .service-details-content *,
    .project-details-content * {
        color: #000000 !important;
    }
}

/* تحسينات للوضع عالي التباين */
@media (prefers-contrast: high) {
    :root {
        --details-text-primary: #000000;
        --details-text-secondary: #333333;
        --details-text-muted: #666666;
        --details-border-color: #cccccc;
        --details-bg-primary: #ffffff;
        --details-bg-secondary: #f5f5f5;
    }
    
    .service-feature-item,
    .feature-item,
    .process-step,
    .related-project-card,
    .related-project-item,
    .stat-item {
        border: 2px solid var(--details-border-color) !important;
    }
}

/* تحسينات لتقليل الحركة */
@media (prefers-reduced-motion: reduce) {
    .service-feature-item,
    .feature-item,
    .process-step,
    .related-project-card,
    .related-project-item,
    .stat-item,
    .benefits-list li,
    .share-btn {
        transition: none !important;
        animation: none !important;
    }
    
    .service-main-image img,
    .project-main-image img,
    .gallery-item img {
        transition: none !important;
    }
}

/* تحسينات للشاشات الصغيرة */
@media (max-width: 768px) {
    .service-details-content,
    .project-details-content {
        font-size: 14px;
    }
    
    .service-details-content h2,
    .project-details-content h2 {
        font-size: 1.8rem;
    }
    
    .service-details-content h3,
    .project-details-content h3 {
        font-size: 1.4rem;
    }
    
    .service-details-content h4,
    .project-details-content h4 {
        font-size: 1.2rem;
    }
}

/* ضمان الوضوح في جميع الحالات */
.service-details-section *,
.project-details-section * {
    text-shadow: none !important;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* إصلاح مشاكل التباين المحتملة */
.service-details-content,
.project-details-content {
    background-color: transparent !important;
}

/* التأكد من وضوح النصوص على جميع الخلفيات */
.service-details-wrapper *,
.project-details-wrapper * {
    color: inherit;
}

/* إعادة تعيين أي ألوان بيضاء قد تسبب مشاكل */
.service-details-section .text-white,
.project-details-section .text-white {
    color: var(--details-text-primary) !important;
}

/* ضمان التباين الجيد للعناصر التفاعلية */
button, .btn, .gt-theme-btn {
    color: #ffffff !important;
}

button:hover, .btn:hover, .gt-theme-btn:hover {
    color: #ffffff !important;
}