/* Category-only additions. TDM's header/footer and homepage styles stay authoritative. */
.tsl-catalog {
    padding-top: 16px;
    padding-bottom: 40px;
    min-height: 50vh;
    color: #222
}

.tsl-catalog .rank-math-breadcrumb {
    font-size: 14px;
    color: #666;
    margin: 0 0 18px;
    line-height: 1.7
}

.tsl-catalog .rank-math-breadcrumb p {
    margin: 0
}

.tsl-catalog .rank-math-breadcrumb .separator {
    margin: 0 8px;
    color: #aaa
}

.tsl-catalog .rank-math-breadcrumb a {
    color: #555
}

.tsl-catalog .rank-math-breadcrumb a:hover {
    color: #bd8000
}

.tsl-catalog .tsl-catalog-title {
    font-size: 26px;
    line-height: 1.35;
    font-weight: 600;
    margin: 0 0 24px;
    color: #222
}

.tsl-catalog h2 {
    font-size: 22px;
    line-height: 1.4;
    margin: 0 0 18px;
    font-weight: 600
}

.tsl-catalog .child-categories {
    margin: 0 0 30px
}

.tsl-catalog .catalog-section {
    align-content: space-between
}

.tsl-catalog .catalog-section__caption {
    font-size: 14px;
    line-height: 1.4;
    min-height: 52px;
    margin: 0
}

.tsl-catalog .catalog-section__image img {
    width: auto;
    max-width: 100%;
    height: auto
}

.tsl-category-brands,
.tsl-catalog-blogs,
.tsl-category-description,
.tsl-catalog-products {
    margin-top: 30px
}

.tsl-brand-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 12px
}

.tsl-brand-card {
    border: 1px solid #e3e3e3;
    background: #fff;
    min-height: 86px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    text-align: center;
    color: #333;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.3;
    overflow-wrap: anywhere
}

.tsl-brand-card img {
    display: block;
    width: 100%;
    height: 60px;
    object-fit: contain
}

.tsl-brand-card:hover {
    border-color: #f9b700;
    color: #ab7500
}

.tsl-blog-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px
}

.tsl-blog-card {
    border: 1px solid #e6e6e6;
    background: white
}

.tsl-blog-card img {
    width: 100%;
    height: 175px;
    object-fit: cover;
    display: block
}

.tsl-blog-card h3 {
    font-size: 16px;
    line-height: 1.5;
    font-weight: 600;
    margin: 0;
    padding: 15px;
    color: #333
}

.tsl-blog-card a:hover h3 {
    color: #aa7500
}

.tsl-category-description {
    border-top: 1px solid #eee;
    padding-top: 24px;
    font-size: 16px;
    line-height: 1.8;
    overflow-wrap: anywhere
}

.tsl-category-description h2,
.tsl-category-description h3 {
    margin: 22px 0 12px
}

.tsl-category-description img {
    max-width: 100%;
    height: auto
}

.tsl-category-description table {
    display: block;
    max-width: 100%;
    overflow: auto
}

.tsl-category-description a {
    color: #956700;
    text-decoration: underline
}

.tsl-catalog-filters {
    display: flex;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 14px;
    padding: 20px;
    background: #f7f7f7;
    border: 1px solid #e6e6e6;
    margin-bottom: 16px
}

.tsl-catalog-filters label {
    display: block;
    font-size: 14px;
    font-weight: 400;
    margin: 0 0 5px;
    line-height: 1.4
}

.tsl-catalog-filters input[type=number],
.tsl-catalog-filters select {
    height: 42px;
    border: 1px solid #ccc;
    border-radius: 3px;
    background: #fff;
    padding: 8px 10px;
    font-size: 14px;
    color: #222;
    max-width: 100%;
    box-sizing: border-box
}

.tsl-price-filter {
    width: 145px
}

.tsl-price-filter input {
    width: 100%
}

.tsl-sort-filter {
    min-width: 165px
}

.tsl-sort-filter select {
    width: 100%
}

.tsl-catalog-filters .tsl-checkbox-filter {
    display: flex;
    gap: 7px;
    align-items: center;
    min-height: 42px;
    margin: 0;
    cursor: pointer
}

.tsl-catalog input[type=checkbox] {
    width: 16px;
    height: 16px;
    margin: 0;
    accent-color: #c48a00
}

.tsl-brand-filter {
    position: relative;
    min-width: 158px;
    align-self: flex-end
}

.tsl-brand-filter summary {
    cursor: pointer;
    min-height: 42px;
    border: 1px solid #ccc;
    border-radius: 3px;
    background: #fff;
    padding: 10px 12px;
    font-size: 14px
}

.tsl-brand-filter fieldset {
    position: absolute;
    z-index: 12;
    top: 100%;
    left: 0;
    min-width: 250px;
    max-height: 320px;
    overflow: auto;
    margin: 5px 0 0;
    background: white;
    border: 1px solid #ddd;
    box-shadow: 0 5px 14px #0002;
    padding: 12px
}

.tsl-brand-filter fieldset label {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 36px;
    margin: 0;
    cursor: pointer
}

.tsl-filter-submit {
    min-height: 42px;
    background: #f9b700;
    color: #222;
    font-weight: 600;
    border: 1px solid #dfaa16;
    border-radius: 3px;
    padding: 8px 17px;
    font-size: 14px;
    cursor: pointer
}

.tsl-filter-submit:hover {
    background: #efad00
}

.tsl-catalog-filters>a {
    font-size: 14px;
    min-height: 42px;
    display: flex;
    align-items: center;
    text-decoration: underline;
    color: #555
}

.tsl-product-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px
}

.tsl-product-card {
    border: 1px solid #e5e5e5;
    border-radius: 2px;
    background: #fff;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    min-width: 0
}

.tsl-product-card:hover {
    border-color: #e7b347;
    box-shadow: 0 3px 12px #0000000d
}

.tsl-product-image {
    display: block;
    position: relative;
    background: #fff;
    padding: 12px;
    aspect-ratio: 1
}

.tsl-product-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain
}

.tsl-sale-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 1;
    background: #c83329;
    color: #fff;
    font-size: 12px;
    padding: 3px 8px;
    border-radius: 2px
}

.tsl-product-info {
    padding: 14px;
    display: flex;
    flex: 1;
    flex-direction: column
}

.tsl-product-info h3 {
    font-size: 15px;
    line-height: 1.5;
    font-weight: 500;
    margin: 0 0 8px
}

.tsl-product-info h3 a {
    color: #222
}

.tsl-product-info h3 a:hover {
    color: #a77400
}

.tsl-product-sku {
    font-size: 12px;
    color: #777;
    margin: 0 0 8px;
    overflow-wrap: anywhere
}

.tsl-product-price {
    font-size: 17px;
    color: #c62828;
    font-weight: 700;
    line-height: 1.5;
    margin-top: auto
}

.tsl-product-price del {
    font-size: 13px;
    color: #888;
    font-weight: 400;
    margin-right: 6px
}

.tsl-product-price ins {
    text-decoration: none;
    background: transparent
}

.tsl-product-detail {
    font-size: 13px;
    color: #6a6a6a;
    border-top: 1px solid #eee;
    margin-top: 12px;
    padding-top: 10px;
    display: flex;
    justify-content: space-between
}

.tsl-result-count {
    font-size: 14px;
    color: #666;
    margin: 15px 0
}

.tsl-pagination {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 7px;
    margin: 26px 0
}

.tsl-pagination a,
.tsl-pagination span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    min-height: 42px;
    padding: 6px;
    color: #333
}

.tsl-pagination a {
    border: 1px solid #ddd;
    background: white
}

.tsl-pagination a[aria-current=page] {
    background: #f9b700;
    border-color: #f9b700;
    font-weight: 600
}

.tsl-catalog-empty {
    border: 1px dashed #ddd;
    text-align: center;
    padding: 40px 20px;
    font-size: 16px
}

.tsl-catalog-empty a {
    color: #946700;
    text-decoration: underline
}

.tsl-filter-error {
    padding: 12px;
    background: #fff1ef;
    color: #a5261d;
    border: 1px solid #edc3bf;
    font-size: 14px
}

.tsl-filter-error[hidden] {
    display: none
}

.tsl-catalog [data-catalog-results] {
    transition: opacity .15s;
    min-height: 150px
}

.tsl-catalog .is-loading [data-catalog-results] {
    opacity: .45;
    pointer-events: none
}

.tsl-catalog a:focus-visible,
.tsl-catalog button:focus-visible,
.tsl-catalog input:focus-visible,
.tsl-catalog select:focus-visible,
.tsl-catalog summary:focus-visible {
    outline: 3px solid #2478c7;
    outline-offset: 3px
}

.tsl-brand-alphabet {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin: 0 0 28px;
    font-size: 16px
}

.tsl-brand-alphabet a {
    padding: 8px;
    min-width: 36px;
    text-align: center;
    background: #f5f5f5;
    color: #333
}

.tsl-brand-group {
    margin: 25px 0;
    scroll-margin-top: 24px
}

.tsl-brand-group>h2 {
    background: #f5f5f5;
    padding: 10px 14px
}

.tsl-brand-context {
    font-size: 15px;
    line-height: 1.6
}

.tsl-brand-context a {
    text-decoration: underline;
    color: #956700
}

@media(max-width:1199px) {
    .tsl-brand-grid {
        grid-template-columns: repeat(6, minmax(0, 1fr))
    }

    .tsl-product-grid {
        gap: 12px
    }
}

@media(max-width:991px) {
    .tsl-brand-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr))
    }

    .tsl-product-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr))
    }

    .tsl-blog-grid {
        gap: 12px
    }

    .tsl-blog-card img {
        height: 135px
    }
}

@media(max-width:767px) {
    .tsl-catalog {
        padding-top: 12px
    }

    .tsl-catalog .tsl-catalog-title {
        font-size: 23px;
        margin-bottom: 18px
    }

    .tsl-catalog h2 {
        font-size: 20px
    }

    .tsl-catalog .catalog-section__caption {
        font-size: 13px;
        min-height: 50px;
        padding: 7px
    }

    .tsl-brand-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px
    }

    .tsl-brand-card {
        font-size: 14px;
        min-height: 70px;
        padding: 8px
    }

    .tsl-brand-card img {
        height: 48px
    }

    .tsl-product-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px
    }

    .tsl-product-info {
        padding: 10px
    }

    .tsl-product-info h3 {
        font-size: 14px
    }

    .tsl-product-price {
        font-size: 15px
    }

    .tsl-product-price del {
        display: block;
        font-size: 12px
    }

    .tsl-product-image {
        padding: 8px
    }

    .tsl-catalog-filters {
        gap: 12px;
        padding: 14px
    }

    .tsl-price-filter {
        width: calc(50% - 6px)
    }

    .tsl-sort-filter {
        flex: 1
    }

    .tsl-brand-filter {
        width: 100%
    }

    .tsl-brand-filter fieldset {
        position: static;
        width: 100%;
        box-sizing: border-box;
        box-shadow: none;
        min-width: 0
    }

    .tsl-blog-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr))
    }

    .tsl-blog-card img {
        height: 110px
    }

    .tsl-blog-card h3 {
        padding: 10px;
        font-size: 14px
    }

    .tsl-category-description {
        font-size: 15px
    }

    .tsl-catalog .rank-math-breadcrumb {
        font-size: 13px
    }
}

.tsl-catalog .screen-reader-text {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0
}

@media(prefers-reduced-motion:reduce) {
    .tsl-catalog * {
        transition: none !important;
        scroll-behavior: auto !important
    }
}

/* Blog thumbnails and expandable category description */
.tsl-catalog-blogs .tsl-blog-card>a {
    display: block
}

.tsl-catalog-blogs .tsl-blog-card img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 282/160;
    object-fit: cover
}

.tsl-catalog-blogs .tsl-blog-card img.tsl-blog-placeholder {
    object-fit: contain;
    padding: 20px;
    background: #f5f5f5;
    box-sizing: border-box
}

.tsl-description-content {
    display: flow-root;
    min-width: 0
}

.tsl-description-content iframe {
    display: block;
    width: 100%;
    max-width: 800px;
    height: auto;
    aspect-ratio: 16/9;
    margin: 20px auto;
    border: 0
}

.tsl-description-content iframe:not([src]) {
    display: none
}

.tsl-description-content img {
    display: block;
    max-width: 100%;
    height: auto;
    margin-left: auto;
    margin-right: auto
}

.tsl-category-description.is-collapsed .tsl-description-content {
    max-height: 420px;
    overflow: hidden
}

.tsl-description-actions {
    position: relative;
    text-align: center;
    padding: 12px 0 8px;
    background: #fff
}

.tsl-description-actions[hidden] {
    display: none
}

.tsl-category-description.is-collapsed .tsl-description-actions:before {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 0;
    right: 0;
    height: 90px;
    background: linear-gradient(to bottom, transparent, #fff);
    pointer-events: none
}

.tsl-description-actions button {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-width: 150px;
    padding: 9px 22px;
    border: 1px solid #F4B400;
    border-radius: 4px;
    background: #F4B400;
    color: #2C2C2C;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.tsl-description-actions button:hover {
    background: #a5261d;
    color: #fff;
}

.tsl-description-actions button span {
    width: 7px;
    height: 7px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg);
    margin-top: -4px
}

.tsl-description-actions button[aria-expanded=true] span {
    transform: rotate(225deg);
    margin-top: 4px
}

@media(max-width:767px) {
    .tsl-category-description.is-collapsed .tsl-description-content {
        max-height: 300px
    }

    .tsl-catalog-blogs .tsl-blog-card img.tsl-blog-placeholder {
        padding: 12px
    }
}

/* Blog cards: fixed image frame and smooth hover. */
.tsl-catalog-blogs .tsl-blog-thumb {
    display: block;
    overflow: hidden;
    aspect-ratio: 282/160;
}

.tsl-catalog-blogs .tsl-blog-thumb img {
    width: 100%;
    height: 100%;
    transition: transform .3s ease;
}

@media (hover:hover) and (pointer:fine) and (prefers-reduced-motion:no-preference) {
    .tsl-catalog-blogs .tsl-blog-card:hover .tsl-blog-thumb img:not(.tsl-blog-placeholder) {
        transform: scale(1.035);
    }
}