/* ==================================================
   Category
================================================== */

.category-main {
    background: #fff;
}

.category-container {
    width: min(calc(100% - 40px), 1180px);
    margin: 0 auto;
    padding: 72px 0;
}

/* Breadcrumb */

.category-breadcrumb {
    width: 100%;
    padding: 6px max(20px, calc((100vw - 1180px) / 2));
    background: rgba(181, 147, 81, 0.06);
}

.category-breadcrumb__list {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.category-breadcrumb__item {
    color: #5A5A5A;
    font-family: var(--font-serif);
    font-size: 1.4rem;
    font-weight: 400;
    line-height: 1.5;
}

.category-breadcrumb__item:not(:last-child)::after {
    margin-left: 8px;
    color: rgba(181, 147, 81, 0.75);
    font-size: 1.2rem;
    content: "/";
}

.category-breadcrumb__item a {
    color: #5A5A5A;
    text-decoration: none;
}

.category-breadcrumb__item a:hover {
    color: #B59351;
}

.category-breadcrumb__home {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.category-breadcrumb__home-icon {
    display: block;
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
    fill: none;
    stroke: #B59351;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.category-breadcrumb__home span {
    position: relative;
    top: 3px;
}

/* Header */

.category-header {
    margin-bottom: 32px;
    text-align: center;
}

.category-header__label {
    margin: 0 0 8px;
    color: #B59351;
    font-size: 1.3rem;
    font-weight: 500;
    line-height: 1;
    letter-spacing: 0.18em;
}

.category-header__title {
    margin: 0;
    color: #3A3A3A;
    font-family: var(--font-serif);
    font-size: 3.2rem;
    font-weight: 400;
    line-height: 1.5;
    letter-spacing: 0.08em;
}

.category-header__description {
    max-width: 680px;
    margin: 20px auto 0;
    color: #666;
    font-size: 1.6rem;
    line-height: 1.9;
}

/* Posts */

.category-posts {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 32px 28px;
}

.category-post {
    min-width: 0;
}

.category-post__link {
    display: block;
    color: inherit;
    text-decoration: none;
}

.category-post__thumbnail {
    overflow: hidden;
}

.category-post__thumbnail img {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    height: auto;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.category-post__link:hover .category-post__thumbnail img {
    transform: scale(1.04);
}

.category-post__body {
    padding-top: 12px;
}

.category-post__date {
    display: block;
    margin-bottom: 6px;
    color: #888;
    font-size: 1.2rem;
    line-height: 1.4;
}

.category-post__title {
    margin: 0;
    color: #3A3A3A;
    font-family: var(--font-serif);
    font-size: 1.8rem;
    font-weight: 500;
    line-height: 1.5;
    transition: color 0.3s ease;
}

.category-post__link:hover .category-post__title {
    color: #B59351;
}

/* Empty */

.category-empty {
    margin: 0;
    color: #666;
    font-size: 1.6rem;
    line-height: 1.8;
    text-align: center;
}

/* Pagination */

.navigation.pagination {
    margin-top: 48px;
}

.nav-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

.page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    height: 42px;
    padding: 0 12px;
    border: 1px solid rgba(181, 147, 81, 0.65);
    background: #fff;
    color: #B59351;
    font-size: 1.4rem;
    line-height: 1;
    text-decoration: none;
}

.page-numbers.prev,
.page-numbers.next {
    min-width: 58px;
}

.page-numbers.current {
    background: #B59351;
    color: #fff;
}

.page-numbers:hover {
    border-color: #B59351;
    background: rgba(181, 147, 81, 0.05);
    color: #B59351;
}

.page-numbers.current:hover {
    background: #B59351;
    color: #fff;
}

/* Tablet
-------------------------------------------------- */

@media (min-width: 768px) and (max-width: 1199px) {

    .category-posts {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

}

/* Smartphone
-------------------------------------------------- */

@media (max-width: 767px) {

    .category-posts {
        grid-template-columns: 1fr;
    }

    .category-container {
        padding-top: 48px;
        padding-bottom: 40px;
    }

    .category-header {
        margin-bottom: 24px;
    }

    /* Breadcrumb */

    .category-breadcrumb {
        padding-top: 4px;
        padding-bottom: 4px;
        padding-left: 20px;
        padding-right: 20px;
    }

    .category-breadcrumb__item {
        font-size: 1.1rem;
    }

    /* Pagination */

    .navigation.pagination {
        margin-top: 32px;
    }

}