/* =====================================
   INFO PAGE - دليل رقمي للمقاول الذاتي
   ===================================== */

/* المتغيرات - نفس ألوان الموقع */
:root {
    --primary-color: #1C9E97;
    --secondary-color: #2d3748;
    --accent-color: #4fd1c7;
    --text-primary: #2d3748;
    --text-secondary: #718096;
    --background-light: #f8fafc;
    --background-white: #ffffff;
    --border-color: #e2e8f0;
    --success-color: #48bb78;
    --warning-color: #ed8936;
    --error-color: #f56565;
    --ai-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --ai-gradient-hover: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
    --ai-gradient-light: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
}

/* الإعدادات الأساسية */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: auto;
}

/* تم نقل أنماط الهايدر إلى modern-header-offline.css */

/* Container Layout */
.main-container {
    display: flex;
    min-height: 100vh;
    gap: 0;
}

/* الشريط الجانبي المحدث */
.sidebar {
    width: 320px;
    background: linear-gradient(180deg, #1a202c 0%, #2d3748 100%);
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    overflow-y: auto;
    z-index: 1000;
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ضبط الشريط الجانبي للعمل مع الهايدر الموحد */
.has-modern-header .sidebar {
    top: 70px !important;
    height: calc(100vh - 70px) !important;
    z-index: 999 !important;
}

.has-modern-header .sidebar.active {
    top: 70px !important;
    height: calc(100vh - 70px) !important;
}

/* ضبط الشريط الجانبي للزوار غير المسجلين */
.guest-layout .sidebar {
    top: 80px !important;
    height: calc(100vh - 80px) !important;
    z-index: 999 !important;
}

.guest-layout .sidebar.active {
    top: 80px !important;
    height: calc(100vh - 80px) !important;
}

.sidebar-header {
    padding: 2rem 1.5rem;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
}

.sidebar-header::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
}

.sidebar-header h3 {
    color: white;
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.sidebar-header .subtitle {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.9rem;
    font-weight: 500;
}

.sidebar-content {
    padding: 1rem 0;
}

.sidebar-section {
    position: relative;
    margin: 0.5rem 1rem;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar-section:hover {
    transform: translateX(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

.sidebar-section.active {
    background: var(--ai-gradient);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
}

.sidebar-section.active .section-link {
    background: transparent;
    color: white;
}

.sidebar-section.active .section-desc {
    color: rgba(255, 255, 255, 0.9);
}

.section-link {
    display: flex;
    align-items: center;
    padding: 1rem 1.25rem;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    position: relative;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    backdrop-filter: blur(10px);
}

.section-link:hover {
    color: white;
    background: rgba(255, 255, 255, 0.1);
    text-decoration: none;
}

.section-link::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 0;
    height: 100%;
    background: var(--ai-gradient);
    transition: width 0.3s ease;
    z-index: -1;
    border-radius: 12px;
}

.section-link:hover::before {
    width: 100%;
}

.section-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    border-radius: 10px;
    margin-left: 1rem;
    font-size: 1.2rem;
    position: relative;
    z-index: 1;
    transition: all 0.3s ease;
}

.section-link:hover .section-icon {
    transform: scale(1.1);
}

.section-content {
    flex: 1;
}

.section-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.2rem;
    transition: all 0.3s ease;
}

.section-desc {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.4;
    transition: all 0.3s ease;
}

/* المحتوى الرئيسي */
.content-area {
    flex: 1;
    margin-right: 320px;
    padding: 2rem;
    background: transparent;
    min-height: 100vh;
}

/* المحتوى الرئيسي لصفحة info */
.info-content-area {
    flex: 1;
    margin-right: 320px;
    padding: 2rem;
    background: transparent;
    min-height: 100vh;
    transition: margin-right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ضبط المحتوى للعمل مع الهايدر الموحد */
.has-modern-header .info-content-area {
    margin-right: 320px !important;
}

/* ضبط المحتوى للزوار غير المسجلين */
.guest-layout .info-content-area {
    margin-right: 320px !important;
}

@media (max-width: 1199px) {
    .has-modern-header .info-content-area {
        margin-right: 0 !important;
        width: 100% !important;
        max-width: 100vw !important;
    }
    
    .guest-layout .info-content-area {
        margin-right: 0 !important;
        width: 100% !important;
        max-width: 100vw !important;
    }
}

.content-header {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.85) 100%);
    backdrop-filter: blur(20px);
    border-radius: 20px;
    padding: 2.5rem;
    margin-bottom: 2rem;
    text-align: center;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    position: relative;
    overflow: hidden;
}

.content-header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(28, 158, 151, 0.1) 0%, transparent 70%);
    animation: rotate 20s linear infinite;
    pointer-events: none;
    z-index: 0;
}

@keyframes rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.content-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    background: var(--ai-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
    position: relative;
    z-index: 1;
}

.content-header p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}


.search-input-wrapper {
    position: relative;
    max-width: 500px;
    margin: 0 auto;
}

.search-input {
    width: 100%;
    padding: 1rem 1.5rem 1rem 3.5rem;
    border: 2px solid var(--border-color);
    border-radius: 50px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
}

.search-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(28, 158, 151, 0.1);
    background: white;
}

.search-icon {
    position: absolute;
    right: 1.5rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.search-input:focus + .search-icon {
    color: var(--primary-color);
}

/* مساحة الأسئلة الجديدة */
.questions-container {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-top: 2rem;
}

.question-card {
    animation: fadeInHorizontal 0.6s ease-out;
    display: flex
;
    align-items: stretch;
    gap: 20px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 20px;
    margin-bottom: 20px;
    border-right: 4px solid #3b82f6;
    transition: all 0.3s ease;
    max-width: 85%;
}

.question-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.85) 100%);
    backdrop-filter: blur(20px);
    border-radius: 16px;
    padding: 1.5rem;
    position: relative;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    max-width: 800px;
    margin: 0 auto;
    width: 100%;
}

.question-card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    height: 3px;
    background: var(--ai-gradient);
    transition: all 0.3s ease;
}

.question-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.12);
}

.question-card:hover::before {
    height: 4px;
    background: var(--ai-gradient-hover);
}

.question-header {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.question-icon {
    width: 45px;
    height: 45px;
    border-radius: 10px;
    background: var(--ai-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.1rem;
    margin-left: 1rem;
    flex-shrink: 0;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.question-card:hover .question-icon {
    transform: scale(1.05);
    box-shadow: 0 6px 16px rgba(102, 126, 234, 0.4);
}

.question-info {
    flex: 1;
}

.question-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.4;
    margin-bottom: 0.5rem;
    transition: all 0.3s ease;
}

.question-card:hover .question-title {
    color: var(--primary-color);
}

.question-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.question-category {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 500;
    box-shadow: 0 2px 6px rgba(28, 158, 151, 0.3);
    transition: all 0.3s ease;
}

.question-card:hover .question-category {
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(28, 158, 151, 0.4);
}

.question-views {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    color: var(--text-secondary);
    transition: all 0.3s ease;
}

.question-card:hover .question-views {
    color: var(--primary-color);
}

.question-summary {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.question-card:hover .question-summary {
    color: var(--text-primary);
}

.question-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    margin-top: auto;
}

.read-more-btn {
    background: var(--ai-gradient);
    color: white;
    border: none;
    padding: 0.6rem 1.2rem;
    border-radius: 20px;
    font-weight: 500;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    transition: all 0.3s ease;
    box-shadow: 0 3px 10px rgba(102, 126, 234, 0.3);
    position: relative;
    overflow: hidden;
    font-size: 0.9rem;
}

.read-more-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s ease;
}

.read-more-btn:hover::before {
    left: 100%;
}

.read-more-btn:hover {
    background: var(--ai-gradient-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
    color: white;
    text-decoration: none;
}

/* حالة عدم وجود نتائج */
.no-results {
    text-align: center;
    padding: 4rem 2rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.85) 100%);
    backdrop-filter: blur(20px);
    border-radius: 20px;
    margin-top: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
}

.no-results-icon {
    font-size: 4rem;
    background: var(--ai-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1.5rem;
}

.no-results h3 {
    font-size: 1.5rem;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.no-results p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* تم نقل أنماط الهايدر إلى modern-header-offline.css */

/* زر أقسام الدليل للجوال */
.mobile-guide-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1001;
    box-shadow: 0 4px 15px rgba(28, 158, 151, 0.3);
    transition: all 0.3s ease;
    cursor: pointer;
}

.mobile-guide-toggle:hover {
    background: var(--accent-color);
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(28, 158, 151, 0.4);
}

/* تحسينات للأجهزة المحمولة */
@media (max-width: 768px) {
    /* تم نقل أنماط الهايدر إلى modern-header-offline.css */
    
    .mobile-guide-toggle {
        display: flex;
    }

    .sidebar {
        width: 280px;
        transform: translateX(100%);
        transition: transform 0.3s ease;
    }

    .sidebar.active {
        transform: translateX(0);
    }

    .content-area {
        margin-right: 0;
        padding: 1rem;
        padding-bottom: 2rem;
    }

    .content-header {
        padding: 1.5rem;
        margin-bottom: 1.5rem;
    }

    .content-header h1 {
        font-size: 2rem;
    }

    .question-card {
        padding: 1.2rem;
        max-width: 100%;
        margin-bottom: 1.5rem;
    }

    .question-header {
        flex-direction: row;
        align-items: center;
        margin-bottom: 1rem;
    }

    .question-icon {
        margin-left: 1rem;
        margin-bottom: 0;
    }

    .question-title {
        font-size: 1.1rem;
    }

    .question-summary {
        font-size: 0.9rem;
    }

    .sidebar-content {
        padding: 0.5rem 0;
    }

    .sidebar-section {
        margin: 0.25rem 0.5rem;
    }

    .section-link {
        padding: 0.8rem 1rem;
    }

    .section-icon {
        width: 40px;
        height: 40px;
        margin-left: 0.8rem;
    }

    .section-title {
        font-size: 1rem;
    }

    .section-desc {
        font-size: 0.8rem;
    }

    /* تم نقل أنماط الهايدر إلى modern-header-offline.css */

    .d-flex.gap-2 {
        flex-direction: column;
        gap: 0.5rem;
        width: 100%;
        margin-top: 1rem;
    }

    .btn {
        width: 100%;
        text-align: center;
    }

    .question-category {
        font-size: 0.7rem;
        padding: 0.2rem 0.6rem;
    }

    .question-views {
        font-size: 0.75rem;
    }

    .question-actions {
        margin-top: 1rem;
    }

    /* تحسينات للتخطيط العام */
    .questions-container {
        gap: 1.2rem;
        padding-bottom: 2rem;
    }

    .no-results {
        padding: 2rem 1rem;
        margin-top: 1rem;
    }

    .no-results h3 {
        font-size: 1.3rem;
    }

    .no-results p {
        font-size: 1rem;
    }

    .search-input-wrapper {
        margin-bottom: 1.5rem;
    }

    .search-input {
        font-size: 0.9rem;
        padding: 0.8rem 1.2rem 0.8rem 3rem;
    }
}

@media (max-width: 480px) {
    .content-header {
        padding: 1rem;
    }

    .content-header h1 {
        font-size: 1.5rem;
    }

    .content-header p {
        font-size: 1rem;
    }

    .search-container {
        padding: 1.5rem;
    }

    .search-input {
        padding: 0.8rem 1.2rem 0.8rem 3rem;
    }

    .question-card {
        padding: 1rem;
    }

    .question-title {
        font-size: 1rem;
    }

    .question-summary {
        font-size: 0.85rem;
    }

    .read-more-btn {
        padding: 0.5rem 1rem;
        font-size: 0.85rem;
    }

    .question-meta {
        flex-direction: row;
        align-items: center;
        gap: 0.8rem;
        flex-wrap: wrap;
    }
}

/* تحسينات الشريط الجانبي */
.sidebar::-webkit-scrollbar {
    width: 6px;
}

.sidebar::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
}

.sidebar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 3px;
}

.sidebar::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
}

/* تأثيرات الحركة */
.fade-in {
    animation: fadeIn 0.6s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.slide-in-right {
    animation: slideInRight 0.6s ease-out;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.slide-in-left {
    animation: slideInLeft 0.6s ease-out;
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* تأثيرات الذكاء الاصطناعي */
.ai-glow {
    box-shadow: 0 0 20px rgba(102, 126, 234, 0.3);
}

.pulse-animation {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(102, 126, 234, 0.4);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(102, 126, 234, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(102, 126, 234, 0);
    }
}

/* تأثيرات إضافية للتفاعل */
.floating-animation {
    animation: floating 3s ease-in-out infinite;
}

@keyframes floating {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-5px);
    }
}

.shimmer-effect {
    background: linear-gradient(45deg, transparent 30%, rgba(255, 255, 255, 0.3) 50%, transparent 70%);
    background-size: 200% 100%;
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

/* تحسينات إضافية للأداء */
.question-card,
.sidebar-section,
.search-container,
.content-header {
    will-change: transform, opacity;
}

/* تحسينات للطباعة */
@media print {
    .sidebar,
    .mobile-menu-toggle,
    .search-container {
        display: none;
    }

    .content-area {
        margin-right: 0;
        padding: 1rem;
    }

    .question-card {
        page-break-inside: avoid;
        box-shadow: none;
        border: 1px solid #ddd;
    }

    .read-more-btn {
        display: none;
    }
}

/* تحسينات للوضع الليلي */
@media (prefers-color-scheme: dark) {
    :root {
        --text-primary: #f7fafc;
        --text-secondary: #cbd5e0;
        --background-light: #1a202c;
        --background-white: #2d3748;
        --border-color: #4a5568;
    }

    body {
        background: linear-gradient(135deg, #1a202c 0%, #2d3748 100%);
    }

    .content-header,
    .search-container,
    .question-card,
    .no-results {
        border-color: rgba(255, 255, 255, 0.1);
    }

    .search-input {
        background: rgba(45, 55, 72, 0.9);
        border-color: var(--border-color);
        color: var(--text-primary);
    }

    .search-input:focus {
        background: var(--background-white);
    }

    /* تم نقل أنماط الهايدر إلى modern-header-offline.css */

    /* تم نقل أنماط الهايدر إلى modern-header-offline.css */
}

/* تحسينات أيقونات البطاقات */
.question-icon i {
    font-size: 1.1rem;
}

/* تأثيرات إضافية للاستجابة */
.question-card:focus-within {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* تحسينات إضافية للنص */
.question-summary {
    text-align: justify;
    hyphens: auto;
}

/* تأثيرات تحسين الأداء */
.question-card {
    transform: translateZ(0);
    backface-visibility: hidden;
}

/* تحسينات للمرونة */
.questions-container {
    min-height: 400px;
}

/* تأثيرات للحركة المتقدمة */
.question-card:nth-child(odd) {
    animation-delay: 0.1s;
}

.question-card:nth-child(even) {
    animation-delay: 0.2s;
}

/* تحسينات للوصول */
.question-card:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

.read-more-btn:focus {
    outline: 2px solid white;
    outline-offset: 2px;
}

/* تحسينات للخط */


/* تأثيرات الحدود */
.question-card {
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.question-card:hover {
    border-color: rgba(28, 158, 151, 0.3);
}

/* تحسينات المساحة */
.question-actions {
    min-height: 40px;
}

/* تأثيرات للتفاعل المتقدم */
.question-card:active {
    transform: translateY(-2px);
}

/* تحسينات للأداء على الأجهزة المحمولة */
@media (max-width: 768px) {
    .question-card:hover {
        transform: none;
    }
    
    .question-card:active {
        transform: scale(0.98);
    }
}

/* تحسينات للمحتوى */
.question-summary {
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* تأثيرات للتحميل */
.question-card.loading {
    opacity: 0.7;
    pointer-events: none;
}

/* تحسينات للألوان */
.question-meta {
    color: var(--text-secondary);
}

.question-card:hover .question-meta {
    color: var(--primary-color);
}

/* تأثيرات للتنسيق */
.question-header {
    align-items: center;
}

/* تحسينات للشكل */
.question-card {
    border-radius: 12px;
}

/* تأثيرات للانتقال */
.question-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* تحسينات للاستقرار */
.question-card {
    position: relative;
    z-index: 1;
}

/* =====================================
   PAGINATION SYSTEM
   ===================================== */

.pagination-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 2rem 0;
    gap: 1rem;
}

.pagination {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.85) 100%);
    backdrop-filter: blur(20px);
    border-radius: 50px;
    padding: 0.8rem 1.5rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.pagination-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0.5rem;
    border: none;
    border-radius: 50%;
    background: transparent;
    color: var(--text-secondary);
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.pagination-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: var(--ai-gradient);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: all 0.3s ease;
    z-index: -1;
}

.pagination-btn:hover::before {
    width: 100%;
    height: 100%;
}

.pagination-btn:hover {
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
}

.pagination-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

.pagination-btn.active {
    background: var(--ai-gradient);
    color: white;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.pagination-btn.active::before {
    width: 100%;
    height: 100%;
}

.pagination-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin: 0 1rem;
    padding: 0.5rem 1rem;
    background: rgba(28, 158, 151, 0.1);
    border-radius: 20px;
}

.pagination-dots {
    display: flex;
    align-items: center;
    gap: 0.2rem;
    margin: 0 0.5rem;
}

.pagination-dots::before {
    content: '...';
    color: var(--text-secondary);
    font-weight: 500;
}

/* تحسينات pagination للموبايل */
@media (max-width: 768px) {
    .pagination-container {
        margin: 1.5rem 0;
        flex-direction: column;
        gap: 1rem;
    }
    
    .pagination {
        padding: 0.6rem 1rem;
        gap: 0.3rem;
    }
    
    .pagination-btn {
        min-width: 36px;
        height: 36px;
        font-size: 0.9rem;
    }
    
    .pagination-info {
        font-size: 0.8rem;
        margin: 0;
        padding: 0.4rem 0.8rem;
    }
    
    /* إخفاء بعض الأزرار على الموبايل */
    .pagination-btn.mobile-hidden {
        display: none;
    }
}

@media (max-width: 480px) {
    .pagination {
        padding: 0.5rem 0.8rem;
    }
    
    .pagination-btn {
        min-width: 32px;
        height: 32px;
        font-size: 0.8rem;
    }
    
    .pagination-info {
        font-size: 0.75rem;
        padding: 0.3rem 0.6rem;
    }
}

/* تحسينات للأسئلة المشابهة والأكثر مشاهدة */
.similar-questions,
.popular-questions {
    margin: 2rem 0;
}

.similar-questions h3,
.popular-questions h3 {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--primary-color);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.similar-questions h3 i,
.popular-questions h3 i {
    background: var(--ai-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.similar-question-item,
.popular-question-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.85) 100%);
    backdrop-filter: blur(20px);
    border-radius: 12px;
    margin-bottom: 0.8rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
    text-decoration: none;
}

.similar-question-item:hover,
.popular-question-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    text-decoration: none;
}

.similar-question-item .question-number,
.popular-question-item .question-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    background: var(--ai-gradient);
    color: white;
    border-radius: 50%;
    font-weight: 600;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.similar-question-item .question-title,
.popular-question-item .question-title {
    flex: 1;
    color: var(--text-primary);
    font-weight: 500;
    line-height: 1.4;
}

.similar-question-item:hover .question-title,
.popular-question-item:hover .question-title {
    color: var(--primary-color);
}

/* تحسينات للموبايل للأسئلة المشابهة */
@media (max-width: 768px) {
    .similar-questions,
    .popular-questions {
        margin: 1.5rem 0;
    }
    
    .similar-questions h3,
    .popular-questions h3 {
        font-size: 1.2rem;
    }
    
    .similar-question-item,
    .popular-question-item {
        padding: 0.8rem;
        gap: 0.8rem;
    }
    
    .similar-question-item .question-number,
    .popular-question-item .question-number {
        width: 28px;
        height: 28px;
        font-size: 0.8rem;
    }
    
    .similar-question-item .question-title,
    .popular-question-item .question-title {
        font-size: 0.9rem;
    }
}

/* تحسينات للأزرار الاجتماعية */
.social-buttons {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    margin: 1.5rem 0;
    padding: 1rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.85) 100%);
    backdrop-filter: blur(20px);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.social-buttons h4 {
    color: var(--text-primary);
    font-weight: 600;
    margin: 0;
    margin-left: 1rem;
}

.social-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    text-decoration: none;
    color: white;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.social-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: all 0.3s ease;
}

.social-btn:hover::before {
    width: 100%;
    height: 100%;
}

.social-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.social-btn.facebook {
    background: #1877f2;
}

.social-btn.twitter {
    background: #1da1f2;
}

.social-btn.whatsapp {
    background: #25d366;
}

.social-btn.telegram {
    background: #0088cc;
}

.social-btn.copy {
    background: var(--primary-color);
}

/* تحسينات للموبايل للأزرار الاجتماعية */
@media (max-width: 768px) {
    .social-buttons {
        flex-wrap: wrap;
        gap: 0.6rem;
        padding: 0.8rem;
    }
    
    .social-buttons h4 {
        width: 100%;
        margin: 0 0 0.5rem 0;
        font-size: 0.9rem;
    }
    
    .social-btn {
        width: 36px;
        height: 36px;
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .social-buttons {
        gap: 0.5rem;
    }
    
    .social-btn {
        width: 34px;
        height: 34px;
        font-size: 0.9rem;
    }
}

/* ===============================
   MOBILE RESPONSIVE HEADER
   =============================== */

/* Mobile Header Styles */
.mobile-header {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
    z-index: 1001;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
}

.mobile-header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    padding: 0 1rem;
}

.mobile-header-left,
.mobile-header-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.mobile-header-center {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: white;
    font-weight: 600;
    font-size: 1.1rem;
}

.mobile-menu-toggle,
.mobile-sidebar-toggle {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    border-radius: 8px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

/* تم نقل أنماط الهايدر إلى modern-header-offline.css */

/* Mobile Navigation Menu */
.mobile-nav {
    position: fixed;
    top: 0;
    left: -100%;
    width: 280px;
    height: 100vh;
    background: white;
    box-shadow: 4px 0 20px rgba(0, 0, 0, 0.25);
    transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1200;
    overflow-y: auto;
}

.mobile-nav.show {
    left: 0;
}

.mobile-nav-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem;
    background: var(--primary-color);
    color: white;
}

.mobile-nav-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    font-size: 1.1rem;
}

.mobile-nav-close {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.25rem;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.mobile-nav-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.mobile-nav-content {
    padding: 1rem;
}

.mobile-nav-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.mobile-nav-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.mobile-nav-link:hover,
.mobile-nav-link.active {
    background: rgba(28, 158, 151, 0.1);
    color: var(--primary-color);
}

.mobile-auth-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-top: auto;
}

.mobile-auth-buttons .btn {
    width: 100%;
    text-align: center;
}

/* Mobile Overlay */
.mobile-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1100;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.mobile-overlay.show {
    opacity: 1;
    visibility: visible;
}

/* Mobile Responsive Styles */
@media (max-width: 768px) {
    /* تم نقل أنماط الهايدر إلى modern-header-offline.css */
    
    .mobile-header {
        display: block;
    }
    
    .content-area {
        margin-top: 60px;
    }
    
    .sidebar {
        top: 60px;
        height: calc(100vh - 60px);
    }
    
    /* تم نقل أنماط الهايدر إلى modern-header-offline.css */
}

/* تم نقل أنماط الهايدر إلى modern-header-offline.css */

/* تم نقل أنماط الهايدر إلى modern-header-offline.css */