/* ===== Responsive Styles for Mobile & Tablet ===== */

/* ========== Tablet (768px - 991px) ========== */
@media (max-width: 991px) {
    /* Page Header */
    .page-header {
        padding: 60px 0 40px;
    }
    
    .page-title {
        font-size: 2rem;
    }
    
    /* News Cards */
    .news-card {
        margin-bottom: 20px;
    }
    
    .news-card-title {
        font-size: 1.3rem;
    }
    
    /* News Detail */
    .news-detail-meta {
        flex-wrap: wrap;
        gap: 10px;
    }
    
    .news-detail-content {
        font-size: 1rem;
        line-height: 1.7;
    }
    
    .news-detail-content h2 {
        font-size: 1.8rem;
    }
    
    .news-detail-content h3 {
        font-size: 1.5rem;
    }
    
    /* Page Content */
    .page-text {
        font-size: 1rem;
        line-height: 1.7;
    }
    
    .page-text h2 {
        font-size: 1.8rem;
    }
    
    .page-text h3 {
        font-size: 1.5rem;
    }
    
    /* Social Share */
    .share-buttons {
        gap: 0.75rem;
    }
    
    .share-btn {
        padding: 0.6rem 1.2rem;
        font-size: 0.9rem;
    }
}

/* ========== Mobile (max-width: 767px) ========== */
@media (max-width: 767px) {
    /* Page Header */
    .page-header {
        padding: 40px 0 30px;
    }
    
    .page-title {
        font-size: 1.5rem;
        line-height: 1.3;
    }
    
    .page-breadcrumb {
        font-size: 0.85rem;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    /* News Grid */
    .news-grid {
        gap: 20px;
    }
    
    .news-card {
        margin-bottom: 15px;
    }
    
    .news-card-image {
        height: 180px;
    }
    
    .news-card-title {
        font-size: 1.1rem;
        line-height: 1.4;
    }
    
    .news-card-excerpt {
        font-size: 0.9rem;
        line-height: 1.5;
    }
    
    .news-card-date {
        font-size: 0.75rem;
        padding: 5px 10px;
    }
    
    /* News Detail */
    .news-detail-header {
        padding: 30px 0;
    }
    
    .news-detail-title {
        font-size: 1.6rem;
        line-height: 1.3;
        margin-bottom: 15px;
    }
    
    .news-detail-meta {
        font-size: 0.85rem;
        gap: 8px;
    }
    
    .news-detail-meta-item {
        padding: 6px 12px;
    }
    
    .news-detail-content {
        font-size: 0.95rem;
        line-height: 1.6;
        padding: 20px 15px;
    }
    
    .news-detail-content h2 {
        font-size: 1.4rem;
        margin-top: 25px;
        margin-bottom: 15px;
    }
    
    .news-detail-content h3 {
        font-size: 1.2rem;
        margin-top: 20px;
        margin-bottom: 12px;
    }
    
    .news-detail-content p {
        margin-bottom: 15px;
    }
    
    .news-detail-content img {
        margin: 15px 0;
        border-radius: 8px;
    }
    
    .news-detail-content ul,
    .news-detail-content ol {
        padding-right: 20px;
        margin-bottom: 15px;
    }
    
    .news-detail-content li {
        margin-bottom: 8px;
    }
    
    /* Page Content */
    .page-content {
        padding: 30px 0;
    }
    
    .page-image {
        height: 250px;
        margin-bottom: 20px;
        border-radius: 8px;
    }
    
    .page-text {
        font-size: 0.95rem;
        line-height: 1.6;
        padding: 15px;
    }
    
    .page-text h2 {
        font-size: 1.4rem;
        margin-top: 25px;
        margin-bottom: 15px;
    }
    
    .page-text h3 {
        font-size: 1.2rem;
        margin-top: 20px;
        margin-bottom: 12px;
    }
    
    .page-text p {
        margin-bottom: 15px;
    }
    
    .page-text img {
        margin: 15px 0;
        border-radius: 8px;
    }
    
    .page-text ul,
    .page-text ol {
        padding-right: 20px;
        margin-bottom: 15px;
    }
    
    .page-text li {
        margin-bottom: 8px;
    }
    
    /* Social Share */
    .social-share {
        padding: 1.5rem 1rem;
        margin-top: 2rem;
    }
    
    .social-share h5 {
        font-size: 1.1rem;
        margin-bottom: 1rem;
    }
    
    .share-buttons {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    .share-btn {
        width: 100%;
        justify-content: center;
        padding: 0.75rem 1rem;
        font-size: 0.9rem;
    }
    
    /* Related News */
    .related-news {
        padding: 30px 0;
    }
    
    .related-news h3 {
        font-size: 1.4rem;
        margin-bottom: 20px;
    }
    
    /* Pagination */
    .pagination {
        font-size: 0.9rem;
        gap: 5px;
    }
    
    .pagination .page-link {
        padding: 6px 12px;
        font-size: 0.85rem;
    }
    
    /* Filters */
    .news-filters {
        flex-direction: column;
        gap: 15px;
    }
    
    .news-filters .form-select,
    .news-filters .form-control {
        width: 100%;
    }
    
    /* Back Button */
    .btn-back {
        font-size: 0.9rem;
        padding: 8px 16px;
    }
    
    /* Image Caption */
    .image-caption {
        font-size: 0.85rem;
        padding: 8px 12px;
    }
}

/* ========== Small Mobile (max-width: 575px) ========== */
@media (max-width: 575px) {
    .page-title {
        font-size: 1.3rem;
    }
    
    .news-detail-title {
        font-size: 1.4rem;
    }
    
    .news-card-title {
        font-size: 1rem;
    }
    
    .news-detail-content,
    .page-text {
        font-size: 0.9rem;
        padding: 15px 10px;
    }
    
    .news-detail-content h2,
    .page-text h2 {
        font-size: 1.2rem;
    }
    
    .news-detail-content h3,
    .page-text h3 {
        font-size: 1.1rem;
    }
}

/* ========== Touch Device Optimizations ========== */
@media (hover: none) and (pointer: coarse) {
    /* إزالة تأثيرات hover على الأجهزة اللمسية */
    .news-card:hover {
        transform: none;
    }
    
    .news-detail-image-wrapper:hover {
        transform: none;
    }
    
    .share-btn:hover {
        transform: none;
    }
    
    /* زيادة حجم الأزرار للمس */
    .btn,
    .share-btn,
    .pagination .page-link {
        min-height: 44px;
        min-width: 44px;
    }
}

/* ========== Landscape Mode Mobile ========== */
@media (max-width: 767px) and (orientation: landscape) {
    .news-detail-image-wrapper {
        height: 250px;
    }
    
    .page-image {
        height: 200px;
    }
    
    .page-header {
        padding: 30px 0 20px;
    }
}

/* ========== Print Styles ========== */
@media print {
    .page-header,
    .social-share,
    .related-news,
    .btn-back,
    .pagination {
        display: none;
    }
    
    .news-detail-content,
    .page-text {
        font-size: 12pt;
        line-height: 1.5;
    }
}
