.ap-category-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 30px;
    justify-content: center;
}

.ap-category-filter-btn {
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    padding: 8px 15px;
    font-size: 16px;
    color: #666;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
}

.ap-category-filter-btn:hover {
    color: #0073aa;
}

.ap-category-filter-btn.active {
    color: #0073aa;
    border-bottom-color: #0073aa;
}

.ap-latest-posts-grid-3fafae8e {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    transition: opacity 0.3s ease;
}

.ap-latest-posts-grid-3fafae8e.loading {
    opacity: 0.5;
    pointer-events: none;
}

.ap-latest-posts-grid-3fafae8e .ap-post-item {
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    background: #fff;
}

.ap-post-item.fade-in {
    animation: fadeIn 0.5s ease forwards;
}

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

.ap-latest-posts-grid-3fafae8e .ap-post-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.ap-latest-posts-grid-3fafae8e .ap-post-link {
    text-decoration: none;
    color: inherit;
    display: block;
    height: 100%;
}

.ap-latest-posts-grid-3fafae8e .ap-post-img,
.ap-latest-posts-grid-3fafae8e .ap-post-img-placeholder {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

.ap-latest-posts-grid-3fafae8e .ap-post-img-placeholder {
    background-color: #f5f5f5;
}

.ap-latest-posts-grid-3fafae8e .ap-post-meta-wrap {
    padding: 15px 20px 0;
    display: flex;
    gap: 10px;
    align-items: center;
    font-size: 12px;
    color: #888;
}

.ap-latest-posts-grid-3fafae8e .ap-post-category {
    text-transform: uppercase;
    font-weight: 600;
}

.ap-latest-posts-grid-3fafae8e .ap-post-title {
    padding: 10px 20px;
    margin: 0;
    font-size: 20px;
    line-height: 1.3;
}

.ap-latest-posts-grid-3fafae8e .ap-post-excerpt {
    padding: 0 20px 20px;
    font-size: 14px;
    color: #666;
    line-height: 1.6;
}

.ap-latest-posts-grid-3fafae8e .ap-read-more-btn {
    display: inline-block;
    margin: 0 20px 20px;
    padding: 8px 16px;
    background-color: #0073aa;
    color: #fff;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    transition: background-color 0.2s ease;
}

.ap-latest-posts-grid-3fafae8e .ap-post-item:hover .ap-read-more-btn {
    background-color: #005177;
}

.ap-posts-loader {
    text-align: center;
    padding: 40px 0;
}

.ap-spinner {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid rgba(0, 115, 170, 0.2);
    border-radius: 50%;
    border-top-color: #0073aa;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}
