/**
 * Homepage Styles for Astra Child Theme
 * 
 * This stylesheet contains all the styles for the custom homepage template
 * designed to match the Arabic news website layout in the screenshot.
 */

/* General Layout */
.homepage-wrapper {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
    direction: rtl; /* For Arabic content */
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;
    background-color: #f5f7fa;
    color: #3a3a3a;
}

/* Common Styles */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    border-bottom: 2px solid #e3e3e3;
    margin-bottom: 15px;
    background-color: #fff;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.section-header h3 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 700;
    color: #0056b3;
    position: relative;
    padding-right: 10px;
}

.section-header h3:before {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 70%;
    background-color: #0056b3;
}

.section-header.main-header h3 {
    color: #0073aa;
}

.view-all {
    font-size: 0.8rem;
    color: #666;
    text-decoration: none;
}

.view-all:hover {
    color: #0073aa;
    text-decoration: underline;
}

.post-thumbnail {
    overflow: hidden;
    border-radius: 4px;
    position: relative;
    background-color: #f0f0f0; /* Placeholder color while images load */
}

.post-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.post-thumbnail:hover img {
    transform: scale(1.05);
}

.post-content h2,
.post-content h3,
.post-content h4 {
    margin: 0.5rem 0;
    line-height: 1.3;
}

.excerpt {
    font-size: 0.9rem;
    line-height: 1.4;
    margin-bottom: 0;
    color: #666;
}

/* Top Navigation Menu */
.top-nav-menu {
    margin-bottom: 20px;
    background-color: #f8f8f8;
    border-radius: 5px;
}

.top-menu-items {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    overflow-x: auto;
}

.top-menu-items li {
    margin: 0;
    padding: 0;
}

.top-menu-items a {
    display: block;
    padding: 10px 15px;
    color: #333;
    text-decoration: none;
    font-weight: 600;
    white-space: nowrap;
}

.top-menu-items a:hover {
    background-color: #eee;
}

/* Main Featured Section with 3-Column Layout */
.main-featured-section {
    display: grid;
    grid-template-columns: 1fr 2fr 1fr;
    gap: 15px;
    margin-bottom: 30px;
}

/* Left Featured Article */
.featured-left {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    background-color: #000;
    transition: transform 0.3s ease;
}

.featured-left:hover {
    transform: translateY(-5px);
}

.featured-item {
    position: relative;
    height: 480px;
    overflow: hidden;
    border-radius: 12px;
}

.featured-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.7s ease, opacity 0.5s ease;
    opacity: 0.9;
}

.featured-item:hover img {
    transform: scale(1.05);
    opacity: 1;
}

.featured-item::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 75%;
    background: linear-gradient(to top, 
        rgba(0,0,0,0.95) 0%, 
        rgba(0,0,0,0.8) 30%, 
        rgba(0,0,0,0.6) 50%, 
        rgba(0,0,0,0.2) 80%,
        rgba(0,0,0,0) 100%);
    opacity: 0.9;
    transition: opacity 0.3s ease;
}

.featured-item .post-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 2rem;
    z-index: 2;
    transform: translateY(5px);
    transition: transform 0.3s ease;
}

.featured-item:hover .post-content {
    transform: translateY(0);
}

.featured-item .post-title {
    margin: 0 0 1rem;
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1.3;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.8);
    font-family: 'Tajawal', 'Cairo', 'Droid Arabic Kufi', sans-serif;
    padding-bottom: 0.5rem;
    position: relative;
}

.featured-item .post-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 50px;
    height: 3px;
    background: #007bff;
    transition: width 0.3s ease;
}

.featured-item:hover .post-title::after {
    width: 80px;
}

.featured-item .post-excerpt {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1rem;
    line-height: 1.5;
    margin-bottom: 1rem;
    font-family: 'Tajawal', 'Cairo', 'Droid Arabic Kufi', sans-serif;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.featured-item:hover .post-excerpt {
    opacity: 1;
}

.featured-item .post-meta {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    font-family: 'Tajawal', 'Cairo', 'Droid Arabic Kufi', sans-serif;
}

.featured-item .post-meta i {
    color: #007bff;
    margin-left: 0.5rem;
}

/* Center Featured Slider */
.featured-center {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    background-color: #000;
}

.featured-main-slider {
    width: 100%;
    height: 480px;
    position: relative;
}

.featured-slide {
    position: relative;
    height: 480px;
    overflow: hidden;
    background-color: #000;
}

.featured-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.7s ease, opacity 0.5s ease;
    opacity: 0.9;
}

.featured-slide:hover img {
    transform: scale(1.03);
    opacity: 1;
}

.featured-slide::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 70%;
    background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.7) 40%, rgba(0,0,0,0) 100%);
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.featured-slide:hover::after {
    opacity: 0.9;
}

/* Right Featured Items */
.featured-right {
    display: flex;
    flex-direction: column;
    gap: 15px;
    background-color: transparent;
}

.featured-right-items {
    display: flex;
    flex-direction: column;
    gap: 15px;
    height: 100%;
}

.featured-right-item {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    height: calc((480px - 0px) / 3); /* Adjusted height to match new container height */
    background-color: #000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease;
}

.featured-right-item:hover {
    transform: translateY(-3px);
}

.featured-right-item .featured-image {
    height: 100%;
    position: relative;
}

.featured-right-item .featured-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.7s ease, opacity 0.5s ease;
    opacity: 0.9;
}

.featured-right-item:hover .featured-image img {
    transform: scale(1.05);
    opacity: 1;
}

.featured-right-item::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 100%;
    background: linear-gradient(to top,
        rgba(0,0,0,0.95) 0%,
        rgba(0,0,0,0.8) 40%,
        rgba(0,0,0,0.4) 70%,
        rgba(0,0,0,0.2) 85%,
        rgba(0,0,0,0) 100%);
    opacity: 0.85;
    transition: opacity 0.3s ease;
    z-index: 1;
}

.featured-right-item:hover::after {
    opacity: 0.95;
}

.featured-right-item .post-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1.25rem;
    z-index: 2;
    transform: translateY(3px);
    transition: transform 0.3s ease;
}

.featured-right-item:hover .post-content {
    transform: translateY(0);
}

.featured-right-item .post-title {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
    line-height: 1.4;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.8);
    font-family: 'Tajawal', 'Cairo', 'Droid Arabic Kufi', sans-serif;
    position: relative;
    padding-bottom: 0.5rem;
}

.featured-right-item .post-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 30px;
    height: 2px;
    background: #007bff;
    transition: width 0.3s ease;
}

.featured-right-item:hover .post-title::after {
    width: 50px;
}

.featured-right-item .post-meta {
    margin-top: 0.5rem;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-family: 'Tajawal', 'Cairo', 'Droid Arabic Kufi', sans-serif;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.featured-right-item:hover .post-meta {
    opacity: 1;
}

.featured-right-item .post-meta i {
    color: #007bff;
    margin-left: 0.25rem;
}

/* Featured Image (Right Featured Item) */
.featured-image {
    width: 100%;
    height: 100%;
    position: relative;
    background-color: #f0f0f0; /* Placeholder color while images load */
}

.featured-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease, opacity 0.3s ease;
    opacity: 0.95;
}

.featured-image:hover img {
    transform: scale(1.05);
    opacity: 1;
}

.featured-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px 15px;
    background: linear-gradient(to top, rgba(0,0,0,0.95) 0%, rgba(0,0,0,0.85) 30%, rgba(0,0,0,0.6) 60%, rgba(0,0,0,0) 100%);
    color: #fff;
    text-shadow: 0 1px 3px rgba(0,0,0,0.9);
}

.featured-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 2rem;
    z-index: 2;
    transform: translateY(5px);
    transition: transform 0.3s ease;
}

.featured-slide:hover .featured-content {
    transform: translateY(0);
}

.featured-content h2 {
    margin: 0 0 1rem;
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.3;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.8);
    position: relative;
    font-family: 'Tajawal', 'Cairo', 'Droid Arabic Kufi', sans-serif;
    padding-bottom: 0.5rem;
}

.featured-content h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 60px;
    height: 3px;
    background: #007bff;
    transition: width 0.3s ease;
}

.featured-slide:hover .featured-content h2::after {
    width: 100px;
}

.featured-content h2:after {
    content: '';
    position: absolute;
    bottom: -5px;
    right: 0;
    width: 40px;
    height: 2px;
    background-color: #fff;
    opacity: 0.7;
}

.featured-content h3 {
    margin: 0 0 10px;
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.3;
    text-shadow: 0 1px 3px rgba(0,0,0,0.8);
    color: #fff;
}

.featured-content h4 {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.3;
    text-shadow: 0 1px 2px rgba(0,0,0,0.7);
    color: #fff;
}

.featured-content .excerpt {
    font-size: 0.9rem;
    line-height: 1.4;
    margin-bottom: 0;
    color: rgba(255,255,255,0.9);
    text-shadow: 0 1px 1px rgba(0,0,0,0.5);
}

/* Main Ad Banner */
.main-ad-banner {
    margin-bottom: 20px;
    background-color: #fff;
    padding: 15px;
    border-radius: 5px;
    text-align: center;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

/* Slick Slider Customization */
.slick-prev,
.slick-next {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 50%;
    color: white;
    z-index: 10;
    transition: all 0.3s ease;
    backdrop-filter: blur(4px);
}

.slick-prev:hover,
.slick-next:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(1.1);
}

.slick-prev {
    left: 20px;
}

.slick-next {
    right: 20px;
}

.slick-dots {
    bottom: 20px;
    z-index: 10;
}

.slick-dots li {
    margin: 0 4px;
}

.slick-dots li button {
    width: 12px;
    height: 12px;
    padding: 0;
    border-radius: 50%;
    background: #fff;
    transition: all 0.3s ease;
    opacity: 0.4;
}

.slick-dots li:not(.slick-active) button {
    background: #fff;
    opacity: 0.4;
}

.slick-dots li.slick-active button {
    background: #007bff;
    transform: scale(1.2);
}

.slick-dots li button:before {
    display: none;
}

.slick-dots li.slick-active button:before {
    color: white;
    opacity: 1;
}

/* Horizontal Tab Navigation */
.horizontal-tab-nav {
    margin-bottom: 15px;
}

.tab-container {
    background: #fff;
    border-radius: 5px;
    box-shadow: 0 1px 5px rgba(0,0,0,0.1);
    overflow: hidden;
    margin-bottom: 15px;
}

.main-tabs-header {
    display: flex;
    border-bottom: 2px solid #e9ecef;
    position: relative;
    overflow-x: auto;
    background-color: #fff;
}

.main-tab-title {
    padding: 12px 20px;
    cursor: pointer;
    white-space: nowrap;
    font-weight: 700;
    color: #495057;
    border-bottom: 3px solid transparent;
    transition: all 0.3s ease;
    position: relative;
}

.main-tab-title.active {
    color: #0056b3;
    border-bottom-color: #0056b3;
    background-color: rgba(0, 86, 179, 0.05);
    font-weight: 800;
}

.main-tab-title:hover {
    color: #0056b3;
    background-color: rgba(0, 86, 179, 0.03);
}

/* Main Content Container with 2 Columns */
.main-content-container {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
    margin-bottom: 30px;
    background-color: transparent;
}

/* Left Column Styles */
.content-left-column {
    display: flex;
    flex-direction: column;
    gap: 20px;
    background-color: transparent;
}

/* Featured Tab Content */
.tab-content-area {
    position: relative;
    margin-bottom: 20px;
}

.main-tab-content {
    display: none;
}

.main-tab-content.active {
    display: block;
}

.tab-featured-article {
    position: relative;
    overflow: hidden;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    background-color: #fff;
}

.tab-featured-article .post-thumbnail {
    height: 400px;
    border-radius: 5px 5px 0 0;
}

.tab-featured-article .post-content {
    padding: 20px;
    background: #fff;
    color: #333;
}

.tab-featured-article h2 {
    font-size: 1.8rem;
    margin-bottom: 10px;
    color: #0056b3;
}

/* Featured Avocado Section (large image) */
.featured-avocado-section {
    margin-bottom: 20px;
    background: #fff;
    border-radius: 5px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    overflow: hidden;
}

.large-feature-image {
    height: 300px;
    overflow: hidden;
    position: relative;
}

.large-feature-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.feature-content {
    padding: 15px;
    background: #fff;
}

.feature-content h2 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    font-weight: 700;
}

/* Category Blocks Section */
.category-blocks-section {
    margin-bottom: 20px;
    padding: 5px;
}

.category-block-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.category-block {
    background: #fff;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-block:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.block-header {
    padding: 10px 15px;
    background: #f9f9f9;
    border-bottom: 1px solid #e3e3e3;
    background: linear-gradient(to right, #f9f9f9, #fff);
}

.block-header h3 {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
    color: #0056b3;
    position: relative;
    padding-right: 10px;
}

.block-header h3:before {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 70%;
    background-color: #0056b3;
}

.block-content {
    padding: 15px;
}

.block-content .post-thumbnail {
    height: 140px;
    margin-bottom: 10px;
}

.mid-page-ad {
    margin: 20px 0;
    background: #f8f8f8;
    padding: 15px;
    text-align: center;
    border-radius: 5px;
}

/* Advertisement Banner */
.main-ad-banner {
    margin: 20px 0;
    text-align: center;
}

.main-ad-banner .ad-container {
    max-width: 100%;
    margin: 0 auto;
    overflow: hidden;
}

.main-ad-banner .ad-placeholder {
    background-color: #f5f5f5;
    border: 1px dashed #ccc;
    padding: 20px;
    color: #666;
    font-family: 'Tajawal', 'Cairo', 'Droid Arabic Kufi', sans-serif;
    font-size: 16px;
    text-align: center;
    direction: rtl;
}

/* Main Content Area */
.main-content-area {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

.primary-content {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.content-section {
    background: #fff;
    border-radius: 5px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    overflow: hidden;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    border-bottom: 2px solid #f0f0f0;
}

.section-header h3 {
    margin: 0;
    font-size: 1.2rem;
    font-weight: 700;
    color: #333;
}

.view-all {
    font-size: 0.8rem;
    color: #666;
    text-decoration: none;
}

.view-all:hover {
    color: #0073aa;
}

/* Slider Section */
.slider-section {
    margin-bottom: 30px;
}

.section-slider {
    padding: 15px;
}

.slider-item {
    padding: 0 10px;
}

.slider-item .post-thumbnail {
    height: 180px;
    margin-bottom: 10px;
    overflow: hidden;
    border-radius: 5px;
}

/* Multi-Photo Grid Section */
.multi-photo-grid-section {
    margin-bottom: 30px;
}

.multi-photo-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
}

.multi-photo-item {
    background: #fff;
    border-radius: 5px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    overflow: hidden;
}

.multi-photo-item .post-thumbnail {
    height: 160px;
}

.multi-photo-item .post-content {
    padding: 10px 15px;
}

.multi-photo-item h4 {
    font-size: 0.9rem;
    margin: 0;
    line-height: 1.3;
}

/* Bottom Three Sections */
.bottom-three-sections {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.bottom-section {
    background: #fff;
    border-radius: 5px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    overflow: hidden;
}

.bottom-section-item {
    display: flex;
    flex-direction: column;
}

.bottom-section-item .post-thumbnail {
    height: 200px;
}

.bottom-section-item .post-content {
    padding: 15px;
}

.bottom-section-item h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
}

/* Final Featured Section */
.final-featured-section {
    margin-bottom: 30px;
}

.final-featured-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
}

.final-featured-item {
    background: #fff;
    border-radius: 5px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    overflow: hidden;
}

.final-featured-item .post-thumbnail {
    height: 160px;
}

.final-featured-item .post-content {
    padding: 10px 15px;
}

.final-featured-item h4 {
    font-size: 0.9rem;
    margin: 0;
    line-height: 1.3;
}

.post-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.post-thumbnail:hover img {
    transform: scale(1.05);
}

.post-content h4 {
    font-size: 1rem;
    margin: 0;
    line-height: 1.4;
}

/* Sidebar Content */
.sidebar-content {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.ad-banner {
    background: #f8f8f8;
    border-radius: 5px;
    padding: 15px;
    text-align: center;
    margin-bottom: 30px;
}

.sidebar-section {
    background: #fff;
    border-radius: 5px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    overflow: hidden;
}

.sidebar-posts {
    padding: 15px;
}

.sidebar-post {
    display: flex;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #f0f0f0;
}

.sidebar-post:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.sidebar-post .post-thumbnail {
    width: 80px;
    height: 80px;
    margin-left: 15px;
    flex-shrink: 0;
    border-radius: 5px;
    overflow: hidden;
}

.sidebar-post .post-content {
    flex-grow: 1;
}

.sidebar-post h4 {
    font-size: 0.9rem;
    margin: 0;
    line-height: 1.4;
}

/* Bottom Slider Section */
.bottom-slider-section {
    margin-bottom: 30px;
    background: #fff;
    border-radius: 5px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    overflow: hidden;
}

.bottom-slider {
    padding: 15px;
}

/* Bottom Sections Grid */
.bottom-sections-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    margin-bottom: 30px;
}

.bottom-section {
    background: #fff;
    border-radius: 5px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    overflow: hidden;
}

.bottom-section .section-posts {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

.bottom-section .post-item {
    display: flex;
    flex-direction: column;
}

.bottom-section .post-thumbnail {
    height: 120px;
    margin-bottom: 10px;
    border-radius: 5px;
    overflow: hidden;
}

/* Widgets */
.widget {
    background: #fff;
    border-radius: 5px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    overflow: hidden;
    margin-bottom: 30px;
}

.widget:last-child {
    margin-bottom: 0;
}

.widget-title {
    padding: 15px;
    margin: 0;
    border-bottom: 2px solid #f0f0f0;
    font-size: 1.2rem;
    font-weight: 700;
}

.widget-title:focus,
.widget-title:hover {
    color: #0073aa;
}

/* Horizontal News List for Image Grid Section */
.news-list-horizontal {
    display: flex;
    flex-direction: column;
    gap: 15px;
    background-color: #fff;
    border-radius: 5px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    padding: 15px;
}

.news-item-horizontal {
    display: flex;
    border-bottom: 1px solid #eee;
    padding-bottom: 15px;
    margin-bottom: 5px;
}

.news-item-horizontal:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.news-item-horizontal a {
    display: flex;
    width: 100%;
    text-decoration: none;
    color: inherit;
}

.horizontal-thumbnail {
    width: 120px;
    height: 80px;
    flex-shrink: 0;
    margin-left: 15px;
    border-radius: 4px;
    overflow: hidden;
}

.horizontal-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.horizontal-thumbnail:hover img {
    transform: scale(1.05);
}

.horizontal-news-title {
    flex: 1;
    display: flex;
    align-items: center;
}

.horizontal-news-title h4 {
    margin: 0;
    font-size: 1rem;
    line-height: 1.5;
    font-weight: 600;
    color: #333;
    text-align: right;
}

.rtl-title {
    font-family: 'Tajawal', 'Cairo', 'Droid Arabic Kufi', sans-serif;
    direction: rtl;
    text-align: right;
}

/* Responsive Styles */
@media (max-width: 991px) {
    .featured-posts-container {
        grid-template-columns: 1fr;
    }
    
    .featured-main {
        grid-column: 1;
        grid-row: 1;
        height: 300px;
    }
    
    .featured-secondary {
        display: none;
    }
    
    .main-content-area {
        grid-template-columns: 1fr;
    }
    
    .bottom-sections {
        grid-template-columns: 1fr;
    }
    
    .main-featured-section {
        grid-template-columns: 1fr;
        grid-template-rows: auto;
    }
    
    .featured-left,
    .featured-center,
    .featured-right {
        grid-column: 1;
        margin-bottom: 20px;
    }
    
    .category-block-container {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .multi-photo-grid,
    .final-featured-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .news-item-horizontal {
        flex-direction: column;
    }
    
    .horizontal-thumbnail {
        width: 100%;
        height: 160px;
        margin-left: 0;
        margin-bottom: 10px;
    }
}

@media (max-width: 767px) {
    .section-posts {
        grid-template-columns: 1fr;
    }
    
    .main-post {
        grid-column: 1;
    }
    
    .bottom-section .section-posts {
        grid-template-columns: 1fr;
    }
    
    .category-block-container,
    .multi-photo-grid,
    .final-featured-grid,
    .bottom-sections-grid {
        grid-template-columns: 1fr;
    }
    
    .main-content-container {
        grid-template-columns: 1fr;
    }
}

/* Additional styles for ads */
.responad1 {
    margin-bottom: 20px;
    text-align: center;
}

/* Schema markup for better SEO */
[itemscope], [itemtype] {
    display: block;
}

/* Improve accessibility */
a:focus {
    outline: 2px solid #0073aa;
}

/* Improve page speed */
img {
    max-width: 100%;
    height: auto;
}

/* Sidebar News List Styles */
.sidebar-news-list {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
    overflow: hidden;
}

.sidebar-news-list .list-header {
    background-color: #f8f9fa;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.sidebar-news-list .list-header h3 {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600;
    color: #2c3e50;
    font-family: 'Tajawal', 'Cairo', 'Droid Arabic Kufi', sans-serif;
}

.sidebar-news-list .list-header .view-all {
    color: #007bff;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s ease;
    font-family: 'Tajawal', 'Cairo', 'Droid Arabic Kufi', sans-serif;
}

.sidebar-news-list .list-header .view-all:hover {
    color: #0056b3;
}

.sidebar-news-list .news-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.sidebar-news-list .news-list li {
    border-bottom: 1px solid #e9ecef;
}

.sidebar-news-list .news-list li:last-child {
    border-bottom: none;
}

.sidebar-news-list .news-list a {
    display: block;
    padding: 1rem 1.5rem;
    text-decoration: none;
    transition: background-color 0.2s ease;
}

.sidebar-news-list .news-list a:hover {
    background-color: #f8f9fa;
}

.sidebar-news-list .news-title h4 {
    margin: 0;
    font-size: 1rem;
    font-weight: 500;
    color: #2c3e50;
    line-height: 1.4;
    font-family: 'Tajawal', 'Cairo', 'Droid Arabic Kufi', sans-serif;
}

/* RTL specific adjustments */
.rtl .sidebar-news-list .list-header {
    text-align: right;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .sidebar-news-list .list-header {
        padding: 0.75rem 1rem;
    }

    .sidebar-news-list .list-header h3 {
        font-size: 1.1rem;
    }

    .sidebar-news-list .news-list a {
        padding: 0.75rem 1rem;
    }

    .sidebar-news-list .news-title h4 {
        font-size: 0.95rem;
    }
}
