/* Browse page (/view?w=category|brand|type) — every rule is scoped to .aeb-browse */
.aeb-browse {
    --b-red: #fd312e;
    --b-red-dark: #e3211e;
    --b-ink: #1c1c1c;
    --b-text: #525252;
    --b-muted: #7a7a7a;
    --b-line: #ececec;
    --b-light: #f7f8fa;
    font-family: 'Rubik', sans-serif;
    color: var(--b-text);
    background: var(--b-light);
}
.aeb-browse *, .aeb-browse *::before, .aeb-browse *::after { box-sizing: border-box; }
.aeb-browse a { text-decoration: none; }
.aeb-browse p { margin: 0; color: var(--b-text); font-size: 15px; line-height: 1.7; }
.aeb-browse ul { margin: 0; padding: 0; list-style: none; }

/* ---------- Banner ---------- */
.aeb-browse .aeb-browse-hero {
    position: relative;
    overflow: hidden;
    padding: 60px 0 52px;
    background-color: #151515;
    background-size: cover;
    background-position: center;
}
.aeb-browse .aeb-browse-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(100deg, rgba(14, 14, 14, .94) 0%, rgba(14, 14, 14, .82) 45%, rgba(120, 18, 16, .55) 100%);
}
.aeb-browse .aeb-browse-hero .container { position: relative; z-index: 1; }
.aeb-browse .aeb-browse-crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 18px; font-size: 13.5px; }
.aeb-browse .aeb-browse-crumbs li { display: inline-flex; align-items: center; gap: 8px; color: rgba(255, 255, 255, .85); }
.aeb-browse .aeb-browse-crumbs li + li::before { content: '/'; color: rgba(255, 255, 255, .35); }
.aeb-browse .aeb-browse-crumbs a { color: rgba(255, 255, 255, .6); transition: color .2s; }
.aeb-browse .aeb-browse-crumbs a:hover { color: #fff; }
.aeb-browse .aeb-browse-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    color: var(--b-red);
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
}
.aeb-browse .aeb-browse-eyebrow::before { content: ''; width: 28px; height: 3px; border-radius: 3px; background: var(--b-red); }
.aeb-browse .aeb-browse-hero h1 { margin: 0 0 12px; color: #fff; font-size: 44px; font-weight: 700; line-height: 1.15; }
.aeb-browse .aeb-browse-hero p { max-width: 620px; color: rgba(255, 255, 255, .72); font-size: 16px; }

/* ---------- Toolbar ---------- */
.aeb-browse .aeb-browse-body { padding: 36px 0 64px; }
.aeb-browse .aeb-browse-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 14px 20px;
    margin-bottom: 14px;
}
.aeb-browse .aeb-browse-tabs {
    display: inline-flex;
    gap: 4px;
    padding: 5px;
    background: #fff;
    border: 1px solid var(--b-line);
    border-radius: 12px;
}
.aeb-browse .aeb-browse-tabs a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 40px;
    padding: 0 18px;
    border-radius: 9px;
    color: var(--b-text);
    font-size: 14px;
    font-weight: 600;
    transition: background .2s, color .2s;
}
.aeb-browse .aeb-browse-tabs a i { font-size: 13px; }
.aeb-browse .aeb-browse-tabs a:hover { color: var(--b-red); }
.aeb-browse .aeb-browse-tabs a.is-active { background: var(--b-red); color: #fff; }
.aeb-browse .aeb-browse-search {
    display: flex;
    align-items: center;
    flex: 0 1 340px;
    height: 50px;
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--b-line);
    border-radius: 12px;
    transition: border-color .2s, box-shadow .2s;
}
.aeb-browse .aeb-browse-search:focus-within { border-color: var(--b-red); box-shadow: 0 0 0 3px rgba(253, 49, 46, .12); }
.aeb-browse .aeb-browse-search i { padding: 0 4px 0 18px; color: var(--b-muted); font-size: 15px; }
.aeb-browse .aeb-browse-search input {
    flex: 1 1 auto;
    min-width: 0;
    height: 100%;
    padding: 0 16px 0 10px;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--b-ink);
    font-size: 15px;
}
.aeb-browse .aeb-browse-search input::placeholder { color: #a3a3a3; }
.aeb-browse .aeb-browse-count { margin-bottom: 20px; color: var(--b-muted); font-size: 14px; }
.aeb-browse .aeb-browse-count strong { color: var(--b-ink); font-weight: 600; }

/* ---------- Cards ---------- */
.aeb-browse .aeb-browse-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.aeb-browse .aeb-browse-grid--brand { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.aeb-browse .aeb-bcard {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--b-line);
    border-radius: 14px;
    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.aeb-browse .aeb-bcard:hover {
    transform: translateY(-4px);
    border-color: rgba(253, 49, 46, .35);
    box-shadow: 0 18px 36px -18px rgba(0, 0, 0, .28);
}
.aeb-browse .aeb-bcard[hidden] { display: none; }
.aeb-browse .aeb-bcard-media {
    position: relative;
    display: block;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    background: #fff;
    border-bottom: 1px solid #f2f2f2;
}
.aeb-browse .aeb-browse-grid--brand .aeb-bcard-media { aspect-ratio: 3 / 2; }
.aeb-browse .aeb-bcard-media img {
    position: absolute;
    top: 16px;
    left: 16px;
    width: calc(100% - 32px);
    height: calc(100% - 32px);
    object-fit: contain;
    transition: transform .35s ease;
}
.aeb-browse .aeb-browse-grid--brand .aeb-bcard-media img { top: 22px; left: 22px; width: calc(100% - 44px); height: calc(100% - 44px); }
.aeb-browse .aeb-bcard:hover .aeb-bcard-media img { transform: scale(1.05); }
.aeb-browse .aeb-bcard-initial {
    position: absolute;
    inset: 14px;
    display: none;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: linear-gradient(135deg, rgba(253, 49, 46, .1), rgba(253, 49, 46, .03));
    color: var(--b-red);
    font-size: 40px;
    font-weight: 700;
    text-transform: uppercase;
}
.aeb-browse .aeb-bcard-media.is-missing img { display: none; }
.aeb-browse .aeb-bcard-media.is-missing .aeb-bcard-initial { display: flex; }
.aeb-browse .aeb-bcard-body {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 14px 16px;
}
.aeb-browse .aeb-bcard-name {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    color: var(--b-ink);
    font-size: 15px;
    font-weight: 600;
    line-height: 1.35;
    text-transform: capitalize;
    transition: color .2s;
}
.aeb-browse .aeb-bcard-arrow {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--b-light);
    color: var(--b-ink);
    font-size: 11px;
    transition: background .2s, color .2s, transform .2s;
}
.aeb-browse .aeb-bcard:hover .aeb-bcard-name { color: var(--b-red); }
.aeb-browse .aeb-bcard:hover .aeb-bcard-arrow { background: var(--b-red); color: #fff; transform: translateX(2px); }
.aeb-browse .aeb-browse-grid--brand .aeb-bcard-body { justify-content: center; padding: 12px 14px; text-align: center; }
.aeb-browse .aeb-browse-grid--brand .aeb-bcard-name { font-size: 14px; }
.aeb-browse .aeb-browse-grid--brand .aeb-bcard-arrow { display: none; }

/* ---------- Empty state ---------- */
.aeb-browse .aeb-browse-empty {
    padding: 48px 24px;
    background: #fff;
    border: 1px dashed #dcdcdc;
    border-radius: 16px;
    text-align: center;
}
.aeb-browse .aeb-browse-empty[hidden] { display: none; }
.aeb-browse .aeb-browse-empty i { display: block; margin-bottom: 12px; color: var(--b-red); font-size: 26px; }
.aeb-browse .aeb-browse-empty h3 { margin: 0 0 6px; color: var(--b-ink); font-size: 19px; font-weight: 700; }
.aeb-browse .aeb-browse-empty p { color: var(--b-muted); }
.aeb-browse .aeb-browse-empty a { color: var(--b-red); font-weight: 600; }

/* ---------- Responsive ---------- */
@media (max-width: 1199.98px) {
    .aeb-browse .aeb-browse-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .aeb-browse .aeb-browse-grid--brand { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 991.98px) {
    .aeb-browse .aeb-browse-hero h1 { font-size: 36px; }
    .aeb-browse .aeb-browse-search { flex: 1 1 260px; }
}

@media (max-width: 767.98px) {
    .aeb-browse .aeb-browse-grid--brand { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 574.98px) {
    .aeb-browse { padding-top: var(--aeb-fixed-nav-h, 95px); }
}

@media (max-width: 575.98px) {
    .aeb-browse .aeb-browse-hero { padding: 36px 0 32px; }
    .aeb-browse .aeb-browse-hero h1 { font-size: 28px; }
    .aeb-browse .aeb-browse-hero p { font-size: 14.5px; }
    .aeb-browse .aeb-browse-crumbs { margin-bottom: 12px; font-size: 12.5px; }
    .aeb-browse .aeb-browse-body { padding: 24px 0 44px; }
    .aeb-browse .aeb-browse-tabs { display: flex; width: 100%; }
    .aeb-browse .aeb-browse-tabs a { flex: 1 1 0; justify-content: center; padding: 0 8px; font-size: 13px; }
    .aeb-browse .aeb-browse-search { flex-basis: 100%; height: 46px; }
    .aeb-browse .aeb-browse-grid,
    .aeb-browse .aeb-browse-grid--brand { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
    .aeb-browse .aeb-bcard-media img { top: 10px; left: 10px; width: calc(100% - 20px); height: calc(100% - 20px); }
    .aeb-browse .aeb-browse-grid--brand .aeb-bcard-media img { top: 14px; left: 14px; width: calc(100% - 28px); height: calc(100% - 28px); }
    .aeb-browse .aeb-bcard-body { padding: 11px 12px; }
    .aeb-browse .aeb-bcard-name { font-size: 13.5px; }
    .aeb-browse .aeb-bcard-arrow { width: 26px; height: 26px; font-size: 10px; }
}
