/* ==================== SHOP BY BRAND ==================== */
.dt-brands {
    --dt-orange: #ff7a00;
    --dt-ink: #1a1a1a;
    --dt-muted: #7a7a7a;
    --dt-line: #ececec;
    --dt-ease: cubic-bezier(0.22, 1, 0.36, 1);

    max-width: 1320px;
    margin: 64px auto 0;
    padding: 0 24px;
    font-family: 'Plus Jakarta Sans', sans-serif;
}

.dt-brands__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 20px;
}

.dt-brands__list {
    display: grid;
    grid-template-columns: repeat(8, minmax(0, 1fr));
    gap: 16px;
    margin: 0;
    padding: 0;
    list-style: none;
}

/* ---------- Tile ---------- */
.dt-brand {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    background: #fff;
    border: 1px solid var(--dt-line);
    border-radius: 14px;
    overflow: hidden;
    color: var(--dt-ink);
    text-decoration: none;
    transition: transform 0.35s var(--dt-ease), box-shadow 0.35s ease, border-color 0.35s ease;
}

.dt-brand:hover {
    color: var(--dt-ink);
    text-decoration: none;
    transform: translateY(-4px);
    border-color: rgba(255, 122, 0, 0.45);
    box-shadow: 0 18px 32px -22px rgba(255, 122, 0, 0.6);
}

.dt-brand:focus-visible {
    outline: 2px solid var(--dt-orange);
    outline-offset: 3px;
}

.dt-brand__logo {
    display: grid;
    place-items: center;
    height: 96px;
    padding: 16px 18px;
}

.dt-brand__logo img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    mix-blend-mode: multiply;      /* white logo backgrounds melt into the tile */
    transition: transform 0.45s var(--dt-ease);
}

.dt-brand:hover .dt-brand__logo img,
.dt-brand:hover .dt-brand__wordmark {
    transform: scale(1.08);
}

/* Brands without a logo: styled name instead */
.dt-brand__wordmark {
    font-size: 1.15rem;
    font-weight: 800;
    letter-spacing: -0.01em;
    text-align: center;
    line-height: 1.1;
    transition: transform 0.45s var(--dt-ease);
}

/* Name + count strip along the bottom */
.dt-brand__meta {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1px;
    padding: 8px 10px;
    text-align: center;
    border-top: 1px solid var(--dt-line);
    background: #fafafa;
    font-size: 0.68rem;
    transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

.dt-brand__name {
    max-width: 100%;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dt-brand__count {
    font-size: 0.64rem;
    color: var(--dt-muted);
    transition: color 0.3s ease;
}

.dt-brand:hover .dt-brand__meta {
    background: var(--dt-orange);
    border-color: var(--dt-orange);
    color: #fff;
}

.dt-brand:hover .dt-brand__count {
    color: rgba(255, 255, 255, 0.85);
}

.dt-brands__empty {
    padding: 32px;
    border: 1px dashed var(--dt-line);
    border-radius: 16px;
    text-align: center;
    color: var(--dt-muted);
}

/* ---------- Laptop: 6 per row ---------- */
@media (max-width: 1199.98px) {
    .dt-brands__list {
        grid-template-columns: repeat(6, minmax(0, 1fr));
    }
}

/* ---------- Tablet: 4 per row ---------- */
@media (max-width: 991.98px) {
    .dt-brands {
        margin-top: 56px;
    }

    .dt-brands__list {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 14px;
    }
}

/* ---------- Mobile: swipeable row with snap (same as categories) ---------- */
@media (max-width: 575.98px) {
    .dt-brands {
        margin-top: 40px;
        padding: 0;
    }

    .dt-brands__head {
        padding: 0 16px;
        margin-bottom: 14px;
    }

    .dt-brands__list {
        display: flex;
        gap: 12px;
        padding: 4px 16px 18px;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        scroll-padding: 0 16px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .dt-brands__list::-webkit-scrollbar {
        display: none;
    }

    .dt-brands__item {
        flex: 0 0 38%;
        scroll-snap-align: start;
    }

    .dt-brand {
        border-radius: 12px;
    }

    .dt-brand:hover {
        transform: none;
        box-shadow: none;
    }

    .dt-brand:active {
        transform: scale(0.97);
    }

    .dt-brand__logo {
        height: 84px;
        padding: 14px;
    }

    .dt-brand__meta {
        padding: 7px 8px;
    }
}
