/**
 * BienHabillé - Mega Menu Desktop CSS
 * Style Celio - Full width dropdown avec colonnes
 */

/* ============================================== */
/* NAVBAR */
/* ============================================== */
.bhd-navbar {
    position: relative;
    border-bottom: 1px solid #e5e7eb;
    background: #fff;
    z-index: 100;
}

.bhd-navbar > .bh-container {
    display: flex;
    justify-content: center;
}

/* ============================================== */
/* MENU NAV */
/* ============================================== */
.bhd-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    list-style: none;
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.bhd-nav__item {
    position: static;
}

.bhd-nav__item > a {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 18px 24px;
    font-size: 14px;
    font-weight: 600;
    color: #1d2327;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    position: relative;
    transition: color 0.2s;
}

/* Underline */
.bhd-nav__item > a::after {
    content: '';
    position: absolute;
    bottom: 14px;
    left: 24px;
    right: 24px;
    height: 2px;
    background: #1d2327;
    transform: scaleX(0);
    transition: transform 0.2s;
}

.bhd-nav__item > a:hover::after,
.bhd-nav__item.is-active > a::after {
    transform: scaleX(1);
}

/* Soldes en rouge (premier item) */
.bhd-nav__item:first-child > a {
    color: #dc2626;
}

.bhd-nav__item:first-child > a::after {
    background: #dc2626;
}

/* Arrow */
.bhd-nav__item > a .bh-menu-arrow {
    transition: transform 0.2s;
    margin-left: 2px;
}

.bhd-nav__item:hover > a .bh-menu-arrow {
    transform: rotate(180deg);
}

/* ============================================== */
/* MEGA MENU DROPDOWN */
/* ============================================== */
.bh-mega-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    background: #fff;
    border-top: 1px solid #e5e7eb;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.25s ease, visibility 0.25s ease, transform 0.25s ease;
    z-index: 1000;
    
    /* Scrollable */
    max-height: calc(100vh - 180px);
    overflow-y: auto;
    overflow-x: hidden;
}

.bhd-nav__item:hover > .bh-mega-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* ============================================== */
/* MEGA MENU INNER */
/* ============================================== */
.bh-mega-menu__inner {
    max-width: 1400px;
    margin: 0 auto;
    padding: 32px 40px 40px;
    display: flex;
    gap: 0;
}

/* ============================================== */
/* COLONNES */
/* ============================================== */
.bh-mega-menu__column {
    flex: 1;
    min-width: 160px;
    max-width: 220px;
    padding: 0 24px;
    border-left: 1px solid #f0f0f0;
}

.bh-mega-menu__column:first-child {
    padding-left: 0;
    border-left: none;
}

/* Colonne Offres (plus large) */
.bh-mega-menu__column--offers,
.bh-mega-menu__column--highlights {
    min-width: 200px;
    max-width: 280px;
}

/* Titre de colonne */
.bh-mega-menu__column-title {
    font-size: 14px;
    font-weight: 700;
    color: #1d2327;
    margin: 0 0 16px 0;
    padding-bottom: 12px;
    border-bottom: 2px solid #1d2327;
    display: inline-block;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.bh-mega-menu__column-title a {
    color: inherit;
    text-decoration: none;
}

/* Titre rouge */
.bh-mega-menu__column-title--red {
    color: #dc2626;
    border-bottom-color: #dc2626;
}

/* Liste de liens */
.bh-mega-menu__column-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.bh-mega-menu__column-list li {
    margin-bottom: 12px;
}

.bh-mega-menu__column-list a {
    font-size: 14px;
    color: #4b5563;
    text-decoration: none;
    transition: color 0.15s;
    display: inline-block;
}

.bh-mega-menu__column-list a:hover {
    color: #1d2327;
}

/* Liens rouges (Offres) */
.bh-mega-menu__column--offers .bh-mega-menu__column-list a {
    color: #dc2626;
    font-weight: 500;
}

.bh-mega-menu__column--offers .bh-mega-menu__column-list a:hover {
    color: #b91c1c;
}

/* ============================================== */
/* HIGHLIGHTS (En ce moment) */
/* ============================================== */
.bh-mega-menu__highlights-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.bh-mega-menu__highlight {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #4b5563;
    text-decoration: none;
    transition: color 0.15s;
}

.bh-mega-menu__highlight:hover {
    color: #1d2327;
}

/* ============================================== */
/* BADGES */
/* ============================================== */
.bh-mega-menu__badge {
    display: inline-block;
    padding: 3px 8px;
    font-size: 10px;
    font-weight: 600;
    border-radius: 3px;
    text-transform: lowercase;
    white-space: nowrap;
}

.bh-mega-menu__badge--default,
.bh-mega-menu__badge--new {
    background: #1d2327;
    color: #fff;
}

.bh-mega-menu__badge--thermal {
    background: #65a30d;
    color: #fff;
}

.bh-mega-menu__badge--sale {
    background: #dc2626;
    color: #fff;
}

/* ============================================== */
/* BOUTON CTA */
/* ============================================== */
.bh-mega-menu__cta {
    display: flex;
    align-items: flex-end;
    padding-left: 24px;
    margin-left: auto;
}

.bh-mega-menu__cta-button {
    display: inline-block;
    padding: 14px 32px;
    background: #1d2327;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s;
}

.bh-mega-menu__cta-button:hover {
    background: #374151;
}

/* ============================================== */
/* CARTES VISUELLES */
/* ============================================== */
.bh-mega-menu__cards {
    display: flex;
    gap: 16px;
    padding: 0 24px;
}

.bh-mega-menu__card {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 200px;
    background: #f9fafb;
    text-decoration: none;
    overflow: hidden;
    transition: transform 0.2s;
}

.bh-mega-menu__card:hover {
    transform: translateY(-4px);
}

.bh-mega-menu__card-image {
    height: 160px;
    background-size: cover;
    background-position: center;
}

.bh-mega-menu__card-content {
    padding: 16px;
}

.bh-mega-menu__card-letter {
    font-size: 48px;
    font-weight: 700;
    color: #1d2327;
    line-height: 1;
}

.bh-mega-menu__card-text {
    margin-top: 8px;
}

.bh-mega-menu__card-keyword {
    font-size: 12px;
    color: #6b7280;
}

.bh-mega-menu__card-category {
    font-size: 14px;
    font-weight: 600;
    color: #1d2327;
}

.bh-mega-menu__card-subcategory {
    display: block;
    font-size: 12px;
    color: #6b7280;
    margin-top: 4px;
}

.bh-mega-menu__card-price {
    display: block;
    font-size: 13px;
    color: #1d2327;
    margin-top: 8px;
}

.bh-mega-menu__card-cta {
    display: block;
    padding: 12px 16px;
    background: #1d2327;
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    text-align: center;
}

/* ============================================== */
/* GRILLE MARQUES */
/* ============================================== */
.bh-mega-menu__brand-grid {
    display: grid;
    grid-template-columns: repeat(var(--grid-columns, 4), 1fr);
    gap: 12px;
    padding: 0 24px;
}

.bh-mega-menu__brand-item {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: #f9fafb;
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    color: #1d2327;
    transition: background 0.15s;
}

.bh-mega-menu__brand-item:hover {
    background: #f3f4f6;
}

.bh-mega-menu__brand-item img {
    max-width: 100%;
    max-height: 40px;
    object-fit: contain;
}

/* ============================================== */
/* SCROLLBAR */
/* ============================================== */
.bh-mega-menu::-webkit-scrollbar {
    width: 6px;
}

.bh-mega-menu::-webkit-scrollbar-track {
    background: #f3f4f6;
}

.bh-mega-menu::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 3px;
}

/* ============================================== */
/* RESPONSIVE */
/* ============================================== */
@media (max-width: 1200px) {
    .bh-mega-menu__column {
        min-width: 140px;
        padding: 0 16px;
    }
}

@media (max-width: 991px) {
    .bh-mega-menu {
        display: none !important;
    }
}