/**
 * Khối danh mục trang chủ — Views/Home/Components/_CategoryHome.cshtml
 * Nạp từ partial (không gộp site.css) để tách biệt theo component.
 * Giả định partial nằm trong .home-page (Views/Home/Index.cshtml).
 */

.home-page .home-category-block .card-categories {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(15, 23, 42, 0.06);
}

.home-page .home-category-block .card-header h1 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--color-text, #222);
    letter-spacing: -0.02em;
}

/* Đoạn mở đầu bám intent tìm kiếm (GSC); tránh nhồi danh sách từ khóa */
.home-page .home-category-block .home-seo-lead {
    font-size: 0.875rem;
    line-height: 1.65;
    color: #5a646e;
    margin: 0 0 1rem;
}

.home-page .home-category-block .home-seo-lead strong {
    color: #222;
    font-weight: 600;
}

.home-page .home-category-block .home-seo-lead em {
    font-style: normal;
    color: var(--color-brand-primary, #008848);
    font-weight: 500;
}

.home-page #slide-category .list-category {
    justify-content: flex-start !important;
}

.home-page .home-category-block .category-item {
    flex: 0 0 auto;
}

.home-page .home-category-block .category-item a {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0.5rem 0.35rem;
    border-radius: 10px;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.home-page .home-category-block .category-item a:hover {
    background-color: rgba(0, 136, 72, 0.06);
    transform: translateY(-2px);
}

.home-page .home-category-block .category-item a:focus-visible {
    outline: 2px solid var(--color-brand-primary, #008848);
    outline-offset: 2px;
}

.home-page .home-category-block .category-item img {
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.home-page .home-category-block .category-item a:hover img {
    border-color: var(--color-brand-primary, #008848);
    box-shadow: 0 4px 14px rgba(0, 136, 72, 0.15);
}

.home-page .home-category-block .category-item p {
    margin-top: 0.35rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: #5a646e;
    line-height: 1.3;
    text-align: center;
}

@media only screen and (max-width: 767px) {
    .home-page #slide-category .list-category {
        justify-content: center !important;
    }

    .home-page .home-category-block .list-category li img {
        width: 76px;
        height: 76px;
    }

    .home-page .home-category-block .category-item p {
        max-width: 92px;
        font-size: 0.75rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .home-page .home-category-block .category-item a:hover {
        transform: none;
    }
}
