﻿.other-category-section {
    position: relative;
    margin: 48px 0 32px;
    padding-bottom: 22px;
}

.other-category-heading {
    margin: 0 0 10px;
    color: #171717;
    font-size: 20px;
    font-weight: 700;
    line-height: 1.8;
    text-align: right;
}

.other-category-grid {
    display: grid;
    grid-template-columns: repeat(8, minmax(0, 1fr));
    overflow: hidden;
    border: 1px solid #dedede;
    border-radius: 16px;
    background: #fff;
}

.other-category-collapsible {
    position: relative;
}

.other-category-collapsible.is-collapsed:not(.is-expanded)
.other-category-item.is-extra {
    display: none;
}

.other-category-item {
    display: flex;
    min-width: 0;
    min-height: 196px;
    padding: 16px 10px 12px;
    align-items: center;
    flex-direction: column;
    justify-content: flex-start;
    color: #1f2937;
    text-align: center;
    text-decoration: none;
    border-inline-start: 1px solid #ececec;
    border-top: 1px solid #ececec;
    transition: color .2s ease, background-color .2s ease;
}

.other-category-item:nth-child(-n+8) {
    border-top: 0;
}

.other-category-item:nth-child(8n+1) {
    border-inline-start: 0;
}

.other-category-item:hover {
    color: var(--theme-brand-color, #1260aa);
    background: #fafafa;
}

.other-category-media {
    display: flex;
    width: 126px;
    height: 126px;
    margin-bottom: 12px;
    padding: 10px;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border: 10px solid #f1f1f1;
    border-radius: 50%;
    background: #f1f1f1;
}

.other-category-media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.other-category-title {
    display: -webkit-box;
    overflow: hidden;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.75;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.other-category-more {
    --other-category-button-color: var(--theme-brand-color, #1260aa);
    position: relative;
    z-index: 2;
    display: block;
    min-width: 112px;
    min-height: 46px;
    margin: 0 auto 0;
    padding: 10px 24px;
    color: #fff;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    border: 0;
    border-radius: 0 0 18px 18px;
    background: var(--other-category-button-color);
    box-shadow: 0 7px 16px color-mix(in srgb, var(--other-category-button-color) 24%, transparent);
    transition: background-color .2s ease, box-shadow .2s ease;
}

.other-category-more:hover {
    --other-category-button-color: var(--theme-brand-color-hover, #0e4981);
}

@media (max-width: 1199.98px) {
    .other-category-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
    .other-category-item:nth-child(-n+8) { border-top: 1px solid #ececec; }
    .other-category-item:nth-child(8n+1) { border-inline-start: 1px solid #ececec; }
    .other-category-item:nth-child(-n+6) { border-top: 0; }
    .other-category-item:nth-child(6n+1) { border-inline-start: 0; }
}

@media (max-width: 991.98px) {
    .other-category-heading { margin-bottom: 24px; }
    .other-category-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .other-category-item:nth-child(-n+6) { border-top: 1px solid #ececec; }
    .other-category-item:nth-child(6n+1) { border-inline-start: 1px solid #ececec; }
    .other-category-item:nth-child(-n+4) { border-top: 0; }
    .other-category-item:nth-child(4n+1) { border-inline-start: 0; }
}

@media (max-width: 575.98px) {
    .other-category-section { margin-top: 32px; }
    .other-category-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); border-radius: 12px; }
    .other-category-item { min-height: 166px; padding: 12px 8px 10px; }
    .other-category-item:nth-child(-n+4) { border-top: 1px solid #ececec; }
    .other-category-item:nth-child(4n+1) { border-inline-start: 1px solid #ececec; }
    .other-category-item:nth-child(-n+2) { border-top: 0; }
    .other-category-item:nth-child(2n+1) { border-inline-start: 0; }
    .other-category-media { width: 104px; height: 104px; border-width: 8px; }
    .other-category-title { font-size: 13px; }
}
