:root {
    --bm-black: #121212;
    --bm-white: #FFFFFF;
    --bm-yellow: #FFC107;
    --bm-yellow-hover: #ffcd38;
    --bm-gray-bg: #F7F7F8;
    --bm-gray-text: #6c757d;
    --bm-border: #e8e8e8;
    --bm-radius: 14px;
    --bm-radius-sm: 10px;
    --bm-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    --bm-shadow-hover: 0 10px 30px rgba(0, 0, 0, 0.10);
    --bm-container: 1180px;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: 'Segoe UI', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--bm-black);
    background: var(--bm-white);
    line-height: 1.5;
    overflow-x: hidden;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

img,
svg,
video,
iframe {
    max-width: 100%;
}

img {
    display: block;
}

a {
    color: inherit;
}

.container {
    width: 100%;
    max-width: var(--bm-container);
}

/* ---------- Acessibilidade / foco ---------- */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 3px solid rgba(255, 193, 7, .45);
    outline-offset: 2px;
}

/* ---------- Botões ---------- */
.btn-bm-yellow {
    background: var(--bm-yellow);
    color: var(--bm-black);
    font-weight: 700;
    border: none;
    border-radius: var(--bm-radius-sm);
    transition: transform .15s ease, box-shadow .15s ease, background-color .15s ease;
}

.btn-bm-yellow:hover {
    background: var(--bm-yellow-hover);
    color: var(--bm-black);
    transform: translateY(-1px);
    box-shadow: var(--bm-shadow);
}

/* ---------- Header ---------- */
.bm-topbar {
    background: var(--bm-black);
    color: var(--bm-white);
    padding: 6px 0;
    font-size: .85rem;
}

.bm-header-main {
    background: var(--bm-white);
}

.bm-logo {
    font-size: clamp(1.35rem, 2vw, 1.6rem);
    font-weight: 800;
    color: var(--bm-black);
    letter-spacing: .5px;
    text-decoration: none;
    white-space: nowrap;
}

.bm-logo span {
    color: var(--bm-yellow);
}

.bm-search .form-control {
    min-height: 42px;
    border-radius: 10px 0 0 10px;
    border: 1px solid #e5e5e5;
}

.bm-search .btn-bm-yellow {
    min-height: 42px;
    border-radius: 0 10px 10px 0;
}

.bm-categories-nav {
    background: var(--bm-black);
    overflow-x: auto;
    scrollbar-width: none;
}

.bm-categories-nav::-webkit-scrollbar {
    display: none;
}

.bm-categories-nav ul {
    min-width: max-content;
}

.bm-categories-nav ul li a {
    color: var(--bm-white);
    text-decoration: none;
    font-size: .9rem;
    white-space: nowrap;
}

.bm-categories-nav ul li a:hover {
    color: var(--bm-yellow);
}

/* ---------- Hero ---------- */
.bm-hero {
    background: var(--bm-black);
    padding: clamp(24px, 4vw, 40px) 0;
}

.bm-hero-slide {
    background: linear-gradient(135deg, #1a1a1a, #000);
    border-radius: var(--bm-radius);
    padding: clamp(34px, 6vw, 60px) clamp(22px, 4vw, 40px);
    color: var(--bm-white);
}

.bm-hero-slide h1 {
    font-size: clamp(1.8rem, 4vw, 2.4rem);
    line-height: 1.15;
    font-weight: 800;
    max-width: 600px;
}

.bm-hero-slide h1 span {
    color: var(--bm-yellow);
}

.bm-hero-slide p {
    color: #d2d2d2;
    margin-bottom: 24px;
    max-width: 500px;
}

/* ---------- Sections ---------- */
.bm-section-alt {
    background: var(--bm-gray-bg);
}

.bm-section-title {
    font-size: clamp(1.15rem, 2.2vw, 1.4rem);
    line-height: 1.25;
    font-weight: 800;
    margin: 0;
}

.bm-see-all {
    font-size: .9rem;
    text-decoration: none;
    font-weight: 600;
    color: var(--bm-black);
    white-space: nowrap;
}

.bm-see-all:hover {
    color: #8a6500;
}

/* ---------- Product Card ---------- */
.bm-product-card {
    display: block;
    background: var(--bm-white);
    border-radius: var(--bm-radius);
    overflow: hidden;
    box-shadow: var(--bm-shadow);
    transition: transform .2s ease, box-shadow .2s ease;
    height: 100%;
    content-visibility: auto;
    contain-intrinsic-size: 380px;
}

.bm-product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--bm-shadow-hover);
}

.bm-product-image {
    position: relative;
    aspect-ratio: 1 / 1;
    background: #f2f2f2;
    overflow: hidden;
}

.bm-product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.bm-badge-discount {
    position: absolute;
    top: 8px;
    left: 8px;
    background: var(--bm-yellow);
    color: var(--bm-black);
    font-weight: 700;
    font-size: .75rem;
    padding: 3px 8px;
    border-radius: 6px;
}

.bm-product-info {
    padding: 12px;
}

.bm-product-name {
    font-size: .9rem;
    line-height: 1.45;
    font-weight: 500;
    margin-bottom: 6px;

    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;

    line-clamp: 2;
    overflow: hidden;

    min-height: 2.6em;
    max-height: 2.9em;
}

.bm-product-rating i {
    color: var(--bm-yellow);
    font-size: .75rem;
}

.bm-price-old {
    text-decoration: line-through;
    color: #777;
    font-size: .8rem;
    margin-right: 6px;
}

.bm-price-current {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--bm-black);
}

/* ---------- Category pill ---------- */
.bm-category-pill {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    background: var(--bm-white);
    border: 1px solid #eee;
    border-radius: var(--bm-radius);
    padding: 18px 10px;
    font-size: .85rem;
    font-weight: 600;
    text-align: center;
    min-height: 100%;
}

.bm-category-pill i {
    font-size: 1.4rem;
    color: #b88400;
}

.bm-category-pill:hover {
    border-color: var(--bm-yellow);
}

/* ---------- Blog card ---------- */
.bm-article-card {
    display: block;
    background: var(--bm-white);
    border-radius: var(--bm-radius);
    overflow: hidden;
    box-shadow: var(--bm-shadow);
    height: 100%;
    content-visibility: auto;
    contain-intrinsic-size: 280px;
}

.bm-article-card img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}

.bm-article-card h3 {
    font-size: 1rem;
    line-height: 1.4;
    font-weight: 700;
    padding: 12px;
    margin: 0;
}

/* ---------- Newsletter ---------- */
.bm-newsletter {
    background: var(--bm-black);
    color: var(--bm-white);
}

.bm-newsletter h2 {
    font-weight: 800;
}

/* ---------- Footer ---------- */
.bm-footer {
    background: #f2f2f2;
}

.bm-footer h6 {
    font-weight: 700;
    margin-bottom: 12px;
}

.bm-footer ul li {
    margin-bottom: 6px;
}

.bm-footer a {
    text-decoration: none;
    color: #444;
    font-size: .9rem;
}

.bm-footer a:hover {
    color: #8a6500;
}

/* ---------- Admin ---------- */
.bm-admin-sidebar {
    background: var(--bm-black);
    min-height: 100vh;
    color: var(--bm-white);
    width: 250px;
}

.bm-admin-sidebar a {
    color: #d0d0d0;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    text-decoration: none;
    border-radius: 8px;
}

.bm-admin-sidebar a:hover,
.bm-admin-sidebar a.active {
    background: var(--bm-yellow);
    color: var(--bm-black);
}

.bm-admin-card {
    background: var(--bm-white);
    border-radius: var(--bm-radius);
    box-shadow: var(--bm-shadow);
    padding: 20px;
}

/* ---------- Minha Conta ---------- */
.bm-account-sidebar {
    background: var(--bm-white);
    border: 1px solid #eee;
    border-radius: var(--bm-radius);
    box-shadow: var(--bm-shadow);
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.bm-account-sidebar a {
    color: var(--bm-black);
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    text-decoration: none;
    border-radius: 8px;
    font-size: .9rem;
    font-weight: 500;
}

.bm-account-sidebar a i {
    width: 18px;
    text-align: center;
    color: #777;
}

.bm-account-sidebar a:hover {
    background: var(--bm-gray-bg);
}

.bm-account-sidebar a.active {
    background: var(--bm-yellow);
    color: var(--bm-black);
    font-weight: 700;
}

.bm-account-sidebar a.active i {
    color: var(--bm-black);
}

/* Contraste corrigido para acessibilidade */
.bm-account-sidebar-note {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 10px 14px;
    margin-top: 6px;
    border-top: 1px solid #f0f0f0;
    font-size: .9rem;
    color: var(--bm-gray-text);
    cursor: default;
}

.bm-account-sidebar-note small {
    color: var(--bm-gray-text);
    font-weight: 400;
    font-size: .72rem;
    line-height: 1.3;
}

.bm-account-avatar {
    width: 84px;
    height: 84px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--bm-yellow);
    background: var(--bm-gray-bg);
}

.bm-stat-box {
    background: var(--bm-gray-bg);
    border-radius: 10px;
    padding: 14px;
    text-align: center;
}

.bm-stat-box strong {
    display: block;
    font-size: 1.3rem;
}

/* ---------- Responsividade global ---------- */
@media (max-width: 991.98px) {
    .bm-hero-slide {
        border-radius: 12px;
    }

    .bm-admin-sidebar {
        width: 220px;
    }
}

@media (max-width: 767.98px) {
    body {
        font-size: 15px;
    }

    .container {
        padding-left: 14px;
        padding-right: 14px;
    }

    .bm-topbar {
        font-size: .78rem;
        text-align: center;
    }

    .bm-header-main {
        padding-top: 8px;
        padding-bottom: 8px;
    }

    .bm-search {
        width: 100%;
    }

    .bm-search .form-control,
    .bm-search .btn-bm-yellow {
        min-height: 44px;
    }

    .bm-hero {
        padding: 18px 0 26px;
    }

    .bm-hero-slide {
        padding: 32px 22px;
    }

    .bm-hero-slide p {
        font-size: .92rem;
    }

    .bm-section-title {
        font-size: 1.18rem;
    }

    .bm-see-all {
        font-size: .82rem;
    }

    .bm-product-card:hover {
        transform: none;
        box-shadow: var(--bm-shadow);
    }

    .bm-product-info {
        padding: 10px;
    }

    .bm-product-name {
        font-size: .86rem;
    }

    .bm-price-current {
        font-size: 1.05rem;
    }

    .bm-category-pill {
        padding: 14px 8px;
        font-size: .8rem;
    }

    .bm-footer {
        font-size: .92rem;
    }

    .bm-admin-card {
        padding: 16px;
    }

    .bm-account-sidebar {
        box-shadow: none;
    }
}

@media (max-width: 479.98px) {
    .container {
        padding-left: 12px;
        padding-right: 12px;
    }

    .bm-logo {
        font-size: 1.3rem;
    }

    .bm-hero-slide {
        padding: 28px 18px;
    }

    .bm-product-info {
        padding: 9px;
    }

    .bm-product-name {
        font-size: .82rem;
        min-height: 2.5em;
    }

    .bm-price-old {
        font-size: .74rem;
    }

    .bm-price-current {
        font-size: 1rem;
    }

    .bm-category-pill {
        padding: 12px 6px;
        border-radius: 10px;
    }
}

/* ---------- Preferência do usuário: reduzir movimento ---------- */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
        scroll-behavior: auto !important;
    }
}

/* ==================================================
   HEADER RESPONSIVO BEUMART
   ================================================== */

.bm-header-main {
    background: var(--bm-white);
}

.bm-header-row {
    display: grid;
    grid-template-columns: auto minmax(280px, 1fr) auto;
    align-items: center;
    gap: 28px;
}

/* BUSCA */
.bm-search {
    position: relative;
    width: 100%;
    max-width: 720px;
    justify-self: center;
}

.bm-search-suggestions {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    z-index: 1050;

    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 10px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, .12);
    overflow: hidden;
}

.bm-search-suggestions a:hover {
    background: var(--bm-gray-bg);
}

/* AÇÕES DO HEADER */
.bm-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.bm-header-action {
    width: 42px;
    height: 42px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    color: var(--bm-black);
    background: transparent;
    border: 0;
    border-radius: 50%;
    text-decoration: none;

    transition:
        background-color .15s ease,
        color .15s ease;
}

.bm-header-action:hover {
    background: var(--bm-gray-bg);
    color: var(--bm-black);
}

.bm-user-button {
    cursor: pointer;
}

.bm-user-button.dropdown-toggle::after {
    display: none;
}

/* MENU DE CATEGORIAS */
.bm-categories-list {
    display: flex;
    align-items: center;
    gap: 28px;

    list-style: none;
    margin: 0;
    padding: 9px 0;

    overflow-x: auto;
    scrollbar-width: none;
}

.bm-categories-list::-webkit-scrollbar {
    display: none;
}

.bm-categories-list li {
    flex: 0 0 auto;
}

/* TABLET */
@media (max-width: 991.98px) {

    .bm-header-row {
        grid-template-columns: auto 1fr auto;
        gap: 18px;
    }

    .bm-search {
        max-width: none;
    }

    .bm-categories-list {
        gap: 24px;
    }
}

/* CELULAR */
@media (max-width: 767.98px) {

    .bm-header-main {
        padding-top: 10px !important;
        padding-bottom: 10px !important;
    }

    .bm-header-row {
        grid-template-columns: 1fr auto;
        gap: 10px 12px;
    }

    .bm-logo {
        grid-column: 1;
        grid-row: 1;
    }

    .bm-header-actions {
        grid-column: 2;
        grid-row: 1;
        justify-self: end;
    }

    .bm-search {
        grid-column: 1 / -1;
        grid-row: 2;
        width: 100%;
        max-width: none;
    }

    .bm-search .form-control {
        font-size: 16px;
        min-height: 44px;
    }

    .bm-search .btn {
        width: 48px;
        min-height: 44px;
    }

    .bm-header-action {
        width: 40px;
        height: 40px;
    }

    .bm-categories-list {
        gap: 22px;
        padding: 9px 0;
    }
}

/* CELULARES PEQUENOS */
@media (max-width: 380px) {

    .bm-logo {
        font-size: 1.2rem;
    }

    .bm-header-actions {
        gap: 2px;
    }

    .bm-header-action {
        width: 38px;
        height: 38px;
    }

    .bm-search .form-control {
        padding-left: 11px;
        padding-right: 8px;
    }
}

/* ==================================================
   HOME RESPONSIVA
   ================================================== */

.bm-home-section {
    width: 100%;
}

.bm-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 24px;
}

.bm-section-header .fa-wand-magic-sparkles {
    color: #b88400;
}

.bm-newsletter-form {
    display: flex;
    justify-content: center;
    gap: 10px;
    width: 100%;
    max-width: 520px;
    margin: 22px auto 0;
}

.bm-newsletter-form .form-control {
    min-width: 0;
    min-height: 44px;
}

.bm-newsletter-form .btn {
    flex: 0 0 auto;
    min-height: 44px;
}

/* TABLET */

@media (max-width: 991.98px) {

    .bm-home-section {
        padding-left: 4px;
        padding-right: 4px;
    }
}

/* CELULAR */

@media (max-width: 767.98px) {

    .bm-home-section.py-5,
    .bm-section-alt.py-5 {
        padding-top: 32px !important;
        padding-bottom: 32px !important;
    }

    .bm-section-header {
        gap: 10px;
        margin-bottom: 18px;
    }

    .bm-section-title {
        line-height: 1.25;
    }

    .bm-hero-slide .btn-lg {
        min-height: 46px;
        padding: 10px 18px;
        font-size: .95rem;
    }

    .bm-newsletter {
        padding-top: 38px !important;
        padding-bottom: 38px !important;
    }

    .bm-newsletter h2 {
        font-size: 1.35rem;
    }

    .bm-newsletter p {
        font-size: .9rem;
    }

    .bm-newsletter-form {
        flex-direction: column;
        max-width: 420px;
    }

    .bm-newsletter-form .form-control,
    .bm-newsletter-form .btn {
        width: 100%;
        min-height: 46px;
    }
}

/* CELULARES MENORES */

@media (max-width: 420px) {

    .bm-section-header {
        align-items: flex-end;
    }

    .bm-section-title {
        font-size: 1.08rem;
    }

    .bm-see-all {
        font-size: .78rem;
    }

    .bm-hero-slide h1 {
        font-size: 1.65rem;
    }
}

/* ==================================================
   FOOTER RESPONSIVO
   ================================================== */

.bm-footer {
    background: #f2f2f2;
}

.bm-footer-description {
    max-width: 380px;
    line-height: 1.6;
}

.bm-footer h6 {
    margin-bottom: 14px;
}

.bm-footer ul li {
    margin-bottom: 7px;
}

.bm-footer a {
    transition: color .15s ease;
}

.bm-footer-newsletter {
    display: flex;
    gap: 8px;
    width: 100%;
}

.bm-footer-newsletter .form-control {
    min-width: 0;
    min-height: 44px;
}

.bm-footer-newsletter .btn {
    flex: 0 0 auto;
    min-height: 44px;
}

.bm-footer-bottom {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    text-align: center;
}

.bm-footer-bottom p {
    margin: 0;
    line-height: 1.5;
}

/* TABLET */
@media (max-width: 991.98px) {

    .bm-footer-bottom {
        align-items: center;
        justify-content: center;
        text-align: center;
        gap: 4px;
    }
}

/* CELULAR */
@media (max-width: 767.98px) {

    .bm-footer .container {
        padding-top: 36px !important;
        padding-bottom: 28px !important;
    }

    .bm-footer-description {
        max-width: 100%;
    }

    .bm-footer-newsletter {
        flex-direction: column;
    }

    .bm-footer-newsletter .form-control,
    .bm-footer-newsletter .btn {
        width: 100%;
        min-height: 46px;
    }

    .bm-footer-bottom {
        align-items: center;
        text-align: center;
    }
}

/* ==================================================
   PÁGINA DE CATEGORIA
   ================================================== */

.bm-category-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 20px;
    margin-bottom: 24px;
}

.bm-category-title {
    margin: 0;
    font-size: clamp(1.35rem, 2.5vw, 1.8rem);
    line-height: 1.2;
    font-weight: 800;
}

.bm-category-description {
    max-width: 760px;
    margin-top: 8px;
    font-size: .92rem;
    line-height: 1.6;
    color: #666;
}

.bm-category-count {
    flex: 0 0 auto;
    white-space: nowrap;
}

.bm-category-pagination {
    margin-top: 34px;
}

.bm-category-pagination .page-link {
    color: var(--bm-black);
    border-color: #e4e4e4;
    min-height: 42px;

    display: flex;
    align-items: center;
    justify-content: center;
}

.bm-category-pagination .page-link:hover {
    color: var(--bm-black);
    background: var(--bm-yellow);
    border-color: var(--bm-yellow);
}

.bm-category-empty {
    max-width: 520px;
    margin: 54px auto;
    padding: 32px 20px;
}

.bm-category-empty i {
    display: block;
    margin-bottom: 16px;

    font-size: 2.2rem;
    color: #bbb;
}

.bm-category-empty h2 {
    font-size: 1.25rem;
    font-weight: 700;
}

/* TABLET */
@media (max-width: 991.98px) {

    .bm-category-header {
        align-items: flex-start;
    }
}

/* CELULAR */
@media (max-width: 767.98px) {

    .bm-category-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
        margin-bottom: 18px;
    }

    .bm-category-title {
        font-size: 1.35rem;
    }

    .bm-category-description {
        font-size: .88rem;
    }

    .bm-category-count {
        white-space: normal;
    }

    .bm-category-pagination {
        margin-top: 26px;
    }

    .bm-category-pagination .pagination {
        gap: 4px;
    }

    .bm-category-pagination .page-link {
        min-height: 40px;
        padding: 8px 11px;
        font-size: .85rem;
    }

    .bm-category-empty {
        margin: 34px auto;
    }
}