/* ===== Country Page Categories Blocks ===== */

.category-block {
    background: #fff;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 36px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    border-top: 5px solid;
    transition: all 0.3s ease;
}

.category-block:hover {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

.category-block-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 18px;
    border-bottom: 2px solid #f0f0f0;
    gap: 20px;
    flex-wrap: wrap;
}

.category-block-title-wrapper {
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1;
    min-width: 200px;
}

.category-block-title {
    font-size: 22px;
    font-weight: 800;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 12px;
    letter-spacing: 0.3px;
}

.category-block-title::before {
    content: '';
    display: inline-block;
    width: 5px;
    height: 24px;
    border-radius: 3px;
    background-color: currentColor;
    flex-shrink: 0;
}

.category-block-subtitle {
    font-size: 13px;
    color: #888;
    font-weight: 500;
    letter-spacing: 0.4px;
}

.category-block-link {
    color: #2271b1;
    text-decoration: none;
    font-weight: 700;
    font-size: 14px;
    padding: 10px 16px;
    border-radius: 6px;
    transition: all 0.2s ease;
    white-space: nowrap;
    background: #f5f9ff;
    border: 1px solid #e0e9f5;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.category-block-link:hover {
    background: #2271b1;
    color: #fff;
    border-color: #2271b1;
    box-shadow: 0 2px 8px rgba(34, 113, 177, 0.3);
}

/* Grid layout for news items */
.category-block-items {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    padding-bottom: 10px;
}

.news-card-wrapper {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    animation: fadeInUp 0.5s ease-out backwards;
}

.news-card-wrapper:hover {
    transform: translateY(-6px);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Design */
@media (max-width: 1200px) {
    .category-block {
        padding: 20px;
        margin-bottom: 28px;
    }

    .category-block-items {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 16px;
    }

    .category-block-title {
        font-size: 20px;
    }
}

@media (max-width: 768px) {
    .category-block {
        padding: 16px;
        margin-bottom: 22px;
        border-radius: 8px;
    }

    .category-block-header {
        flex-direction: column;
        align-items: flex-start;
        margin-bottom: 18px;
        padding-bottom: 14px;
        gap: 12px;
    }

    .category-block-items {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
        gap: 12px;
    }

    .category-block-title {
        font-size: 18px;
        gap: 8px;
    }

    .category-block-title::before {
        height: 20px;
    }

    .category-block-link {
        width: 100%;
        justify-content: center;
        padding: 8px 12px;
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .category-block {
        padding: 12px;
        margin-bottom: 16px;
    }

    .category-block-items {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .category-block-title {
        font-size: 16px;
    }

    .category-block-subtitle {
        font-size: 12px;
    }

    .category-block-header {
        padding-bottom: 10px;
        border-bottom: 1px solid #f0f0f0;
        margin-bottom: 14px;
    }
}

/* Loading states */
.category-block.loading {
    opacity: 0.6;
    pointer-events: none;
}

/* Empty state styling */
.category-block.empty {
    text-align: center;
    padding: 40px 20px;
    background: #f9f9f9;
}

.category-block.empty p {
    color: #999;
    font-size: 16px;
    margin: 0;
}

/* Animation for new items */
.news-card-wrapper.new-item {
    animation: slideInLeft 0.4s ease-out;
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}
