﻿/* ============================================
   NewsDetails.css - تنسيقات صفحة تفاصيل الخبر
   ============================================ */

.news-details-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 20px;
}

/* بطاقة الخبر الرئيسية */
.news-details-card {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.95), rgba(15, 23, 42, 0.95));
    border-radius: 25px;
    padding: 30px;
    margin-bottom: 40px;
    border: 1px solid rgba(251, 191, 36, 0.3);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

/* رأس الخبر */
.news-details-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 10px;
}

.news-type-badge {
    background: rgba(251, 191, 36, 0.2);
    padding: 6px 15px;
    border-radius: 25px;
    font-size: 12px;
    color: #fbbf24;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.pinned-badge {
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
    color: #0f172a;
    padding: 6px 15px;
    border-radius: 25px;
    font-size: 12px;
    font-weight: bold;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

/* عنوان الخبر */
.news-title {
    font-size: 32px;
    font-weight: bold;
    color: #fff;
    margin-bottom: 20px;
    line-height: 1.3;
}

/* معلومات الخبر */
.news-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    padding-bottom: 20px;
    margin-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 13px;
    color: #94a3b8;
}

    .news-meta i {
        margin-left: 5px;
        color: #fbbf24;
    }

/* صورة الخبر - مصغرة ومناسبة */
.news-main-image {
    text-align: center;
    margin: 25px auto;
    padding: 10px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 20px;
}

    .news-main-image img {
        width: auto;
        max-width: 450px;
        height: auto;
        max-height: 350px;
        border-radius: 16px;
        box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
        display: inline-block;
        transition: all 0.3s ease;
        object-fit: contain;
    }

        .news-main-image img:hover {
            transform: scale(1.02);
            box-shadow: 0 12px 30px rgba(251, 191, 36, 0.2);
        }

    .news-main-image.no-image {
        background: linear-gradient(135deg, #1e293b, #0f172a);
        width: 100%;
        max-width: 450px;
        height: 250px;
        margin: 0 auto;
        border-radius: 20px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

        .news-main-image.no-image i {
            font-size: 70px;
            color: #fbbf24;
            opacity: 0.5;
        }

/* محتوى الخبر */
.news-content {
    color: #cbd5e1;
    line-height: 1.8;
    font-size: 16px;
}

    .news-content p {
        margin-bottom: 20px;
    }

    .news-content h2,
    .news-content h3 {
        color: #fbbf24;
        margin: 25px 0 15px;
    }

    .news-content ul,
    .news-content ol {
        margin: 15px 0;
        padding-right: 25px;
    }

    .news-content li {
        margin-bottom: 8px;
    }

    .news-content strong {
        color: #fbbf24;
    }

    .news-content a {
        color: #fbbf24;
        text-decoration: none;
    }

        .news-content a:hover {
            text-decoration: underline;
        }

/* مشاركة الخبر */
.news-share {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

    .news-share h4 {
        color: #94a3b8;
        font-size: 14px;
        margin-bottom: 15px;
    }

.share-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.share-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    font-size: 16px;
}

    .share-btn:hover {
        transform: translateY(-3px);
    }

    .share-btn.facebook {
        background: #1877f2;
    }

    .share-btn.twitter {
        background: #1da1f2;
    }

    .share-btn.whatsapp {
        background: #25d366;
    }

    .share-btn.telegram {
        background: #0088cc;
    }

    .share-btn.copy-link {
        background: #64748b;
    }

/* أخبار ذات صلة */
.related-news {
    background: rgba(30, 41, 59, 0.8);
    border-radius: 20px;
    padding: 25px;
    margin-bottom: 30px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.related-news-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid #fbbf24;
}

    .related-news-header i {
        font-size: 24px;
        color: #fbbf24;
    }

    .related-news-header h3 {
        font-size: 20px;
        margin: 0;
        color: #fff;
    }

.related-news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.related-news-card {
    display: flex;
    gap: 12px;
    padding: 12px;
    background: rgba(15, 23, 42, 0.5);
    border-radius: 12px;
    transition: all 0.3s ease;
}

    .related-news-card:hover {
        background: rgba(251, 191, 36, 0.1);
        transform: translateX(-5px);
    }

.related-news-image {
    width: 70px;
    height: 70px;
    flex-shrink: 0;
    border-radius: 10px;
    overflow: hidden;
    background: linear-gradient(135deg, #1e293b, #0f172a);
}

    .related-news-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .related-news-image .no-image {
        width: 100%;
        height: 100%;
        display: flex;
        align-items: center;
        justify-content: center;
    }

        .related-news-image .no-image i {
            font-size: 24px;
            color: #fbbf24;
            opacity: 0.5;
        }

.related-news-content {
    flex: 1;
}

    .related-news-content h4 {
        font-size: 14px;
        margin: 0 0 8px;
        line-height: 1.4;
    }

        .related-news-content h4 a {
            color: #fff;
            text-decoration: none;
            transition: color 0.3s ease;
        }

            .related-news-content h4 a:hover {
                color: #fbbf24;
            }

.related-news-date {
    font-size: 11px;
    color: #94a3b8;
}

    .related-news-date i {
        margin-left: 4px;
    }

/* زر العودة */
.back-to-news {
    text-align: center;
    margin-top: 20px;
}

.back-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
    color: #0f172a;
    padding: 12px 25px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
}

    .back-btn:hover {
        transform: translateX(-5px);
        box-shadow: 0 5px 20px rgba(251, 191, 36, 0.4);
        gap: 12px;
    }

/* Light Mode */
body.light-mode .news-details-card,
body.light-mode .related-news {
    background: #ffffff;
    border-color: #e2e8f0;
}

body.light-mode .news-title {
    color: #0f172a;
}

body.light-mode .news-content {
    color: #334155;
}

body.light-mode .news-meta {
    border-bottom-color: #e2e8f0;
    color: #64748b;
}

body.light-mode .news-share {
    border-top-color: #e2e8f0;
}

body.light-mode .related-news-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
}

    body.light-mode .related-news-card:hover {
        background: #fef9e3;
        border-color: #fbbf24;
    }

body.light-mode .related-news-content h4 a {
    color: #0f172a;
}

    body.light-mode .related-news-content h4 a:hover {
        color: #f59e0b;
    }

/* Responsive */
@media (max-width: 768px) {
    .news-details-card {
        padding: 20px;
    }

    .news-title {
        font-size: 24px;
    }

    .news-content {
        font-size: 14px;
    }

    .news-main-image img {
        max-width: 300px;
        max-height: 250px;
    }

    .news-main-image.no-image {
        max-width: 300px;
        height: 180px;
    }

        .news-main-image.no-image i {
            font-size: 50px;
        }

    .related-news-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .news-main-image img {
        max-width: 250px;
        max-height: 200px;
    }

    .news-main-image.no-image {
        max-width: 250px;
        height: 150px;
    }
}
