/* Section 2 Wrapper */
.section-2-wrapper {
    margin-bottom: 15px;
    padding: 30px 0;
    background-color: color-mix(in srgb, var(--primary-color) 6%, white);
}

/* Ad Banner */
.s2-ad-banner {
    margin-bottom: 30px;
    text-align: center;
}

.s2-ad-banner img {
    max-width: 100%;
    height: auto;
    display: inline-block;
}

/* Attractive Header Block without full background */
.s2-header-block {
    margin-bottom: 25px;
    text-align: center;
}

.s2-title {
    /* Managed by .center-unique-title in style.css */
}

/* 4-Column Grid */
.section-2-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.s2-post-item {
    display: flex;
    flex-direction: column;
}

.s2-post-image {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 ratio */
    overflow: hidden;
    margin-bottom: 12px;
}

.s2-post-image a {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.s2-post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    transition: transform 0.3s ease;
}

.s2-post-item:hover .s2-post-image img {
    transform: scale(1.05);
}

.s2-post-title {
    font-size: 19.504px;
    line-height: 1.4;
    margin: 0 0 10px 0;
}

.s2-post-title a {
    color: var(--text-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.s2-post-title a:hover {
    color: var(--primary-color);
}

/* Responsive */
@media (max-width: 1024px) {
    .section-2-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }
}

@media (max-width: 768px) {
    .section-2-grid {
        grid-template-columns: 1fr;
    }
    
    .s2-post-item {
        display: grid;
        grid-template-columns: 1fr 120px;
        gap: 15px;
        align-items: center;
        border-bottom: 1px solid #d1d5db;
        padding-bottom: 15px;
        margin-bottom: 0;
    }

    .s2-post-item:last-child {
        border-bottom: none;
        padding-bottom: 0;
    }

    .s2-post-image {
        grid-column: 2;
        grid-row: 1;
        margin-bottom: 0;
    }

    .s2-post-title {
        font-size: 17px;
        grid-column: 1;
        grid-row: 1;
        margin-bottom: 0;
    }
}
