/* ============================================================
   LEADSHOP — CSS Complet
   Breakpoints : desktop ≥ 1024px | tablet 768-1023 | mobile < 768
   ============================================================ */

/* ── Variables ───────────────────────────────────────────── */
:root {
    --primary:     #e62e04;
    --primary-dk:  #c02000;
    --secondary:   #ff6a00;
    --accent:      #ffd700;
    --dark:        #1a1a2e;
    --gray:        #6b7280;
    --gray-lt:     #f3f4f6;
    --gray-bd:     #e5e7eb;
    --white:       #ffffff;
    --success:     #10b981;
    --warning:     #f59e0b;
    --info:        #3b82f6;
    --sh:          0 2px 12px rgba(0,0,0,.08);
    --sh-md:       0 4px 24px rgba(0,0,0,.12);
    --sh-lg:       0 8px 40px rgba(0,0,0,.16);
    --r:           8px;
    --r-lg:        14px;
    --tr:          all .25s ease;
    --font:        'Sora', sans-serif;
    --body:        'DM Sans', sans-serif;
}

/* ── Reset ───────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html  { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body  { font-family: var(--body); background: #f5f5f5; color: #333; font-size: 14px; line-height: 1.6; overflow-x: hidden; }
a     { color: inherit; text-decoration: none; }
img   { max-width: 100%; height: auto; display: block; }
ul    { list-style: none; }
button{ cursor: pointer; border: none; background: none; font-family: inherit; }
input, select, textarea { font-family: inherit; }
* { min-width: 0; }

.container { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 16px; }

/* ============================================================
   TOPBAR — desktop uniquement
   ============================================================ */
.topbar {
    background: var(--dark); color: #ccc; font-size: 12px; padding: 6px 0;
}
.topbar-inner  { display: flex; justify-content: space-between; align-items: center; }
.topbar-left, .topbar-right { display: flex; gap: 16px; align-items: center; }
.topbar-left a, .topbar-right a { color: #bbb; display: flex; align-items: center; gap: 5px; transition: var(--tr); }
.topbar-left a:hover, .topbar-right a:hover { color: var(--accent); }
.topbar-left i, .topbar-right i { color: var(--primary); }
.topbar-promo { color: var(--success); font-weight: 600; }

/* ============================================================
   HEADER
   ============================================================ */
.main-header {
    background: var(--white);
    box-shadow: 0 2px 8px rgba(0,0,0,.08);
    position: sticky; top: 0; z-index: 900;
    padding: 10px 0;
}
.header-inner {
    display: grid;
    grid-template-columns: auto 1fr auto;
    grid-template-areas: "logo search actions";
    gap: 16px;
    align-items: center;
}
/* Logo */
.logo { grid-area: logo; display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.logo-icon {
    width: 42px; height: 42px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 10px; display: flex; align-items: center; justify-content: center;
    color: white; font-size: 18px; flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(230,46,4,.3);
}
.logo-text { display: flex; flex-direction: column; }
.logo-main { font-family: var(--font); font-weight: 800; font-size: 1.1rem; color: var(--dark); white-space: nowrap; }
.logo-sub  { font-size: 10px; color: var(--gray); white-space: nowrap; }
/* Search */
.search-bar {
    grid-area: search;
    display: flex; border: 2px solid var(--primary); border-radius: 6px; overflow: hidden;
}
.search-cat {
    border: none; border-right: 1px solid #ddd; background: #f8f8f8;
    padding: 0 10px; height: 44px; font-size: 12px; color: #555;
    outline: none; cursor: pointer; min-width: 130px; flex-shrink: 0;
}
.search-bar input {
    flex: 1; border: none; outline: none;
    padding: 0 12px; height: 44px; font-size: 13px;
}
.search-bar button {
    background: var(--primary); color: white;
    padding: 0 18px; height: 44px; font-size: 13px; font-weight: 600;
    display: flex; align-items: center; gap: 6px; flex-shrink: 0; transition: var(--tr);
}
.search-bar button:hover { background: var(--primary-dk); }
/* Actions */
.header-actions { grid-area: actions; display: flex; gap: 2px; align-items: center; }

/* Bouton générique header */
.hdr-btn {
    display: flex; flex-direction: column; align-items: center;
    padding: 6px 10px; border-radius: var(--r);
    color: #555; font-size: 11px; font-weight: 500; gap: 2px;
    transition: var(--tr); flex-shrink: 0;
}
.hdr-btn i { font-size: 18px; }
.hdr-btn:hover { background: var(--gray-lt); color: var(--primary); }

/* Panier */
.hdr-cart-wrap { position: relative; display: inline-flex; align-items: center; justify-content: center; }
.cart-badge {
    position: absolute; top: -8px; right: -10px;
    background: var(--primary); color: white;
    font-size: 10px; font-weight: 700;
    min-width: 18px; height: 18px; padding: 0 4px;
    border-radius: 9px; display: flex; align-items: center; justify-content: center;
    pointer-events: none;
}
.cart-badge:empty { display: none; }

/* Burger — masqué desktop */
.burger-btn {
    display: none; flex-direction: column; gap: 5px;
    padding: 8px; border-radius: 6px; transition: var(--tr);
}
.burger-btn span { display: block; width: 22px; height: 2px; background: var(--dark); border-radius: 2px; transition: var(--tr); }
.burger-btn.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger-btn.open span:nth-child(2) { opacity: 0; }
.burger-btn.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ============================================================
   NAV DESKTOP
   ============================================================ */
.main-nav {
    background: var(--white);
    border-top: 1px solid var(--gray-bd);
    border-bottom: 2px solid var(--primary);
    position: sticky; top: 62px; z-index: 850;
    overflow: visible;
}
.nav-inner { display: flex; align-items: stretch; height: 44px; }
/* Dropdown catégories */
.nav-cats-wrap { position: relative; flex-shrink: 0; }
.nav-cats-btn {
    height: 44px; padding: 0 16px;
    background: var(--primary); color: white;
    font-size: 13px; font-weight: 600;
    display: flex; align-items: center; gap: 8px;
    transition: var(--tr); cursor: pointer; white-space: nowrap;
}
.nav-cats-btn:hover { background: var(--primary-dk); }
.nav-cats-btn .chev { font-size: 10px; transition: transform .25s; }
.nav-cats-wrap.open .chev { transform: rotate(180deg); }
.cats-dropdown {
    display: none; position: absolute; top: 100%; left: 0;
    background: white; width: 260px;
    box-shadow: var(--sh-lg); border: 1px solid var(--gray-bd);
    border-radius: 0 0 var(--r) var(--r); z-index: 1050; overflow: hidden;
}
.nav-cats-wrap.open .cats-dropdown { display: block; }
.cat-drop-item {
    display: flex; align-items: center; gap: 10px;
    padding: 10px 14px; font-size: 13px;
    transition: var(--tr); border-bottom: 1px solid var(--gray-lt);
}
.cat-drop-item:last-child { border-bottom: none; }
.cat-drop-item:hover { background: var(--gray-lt); color: var(--primary); padding-left: 20px; }
.cat-drop-icon {
    width: 30px; height: 30px; border-radius: 6px;
    display: flex; align-items: center; justify-content: center;
    font-size: 14px; flex-shrink: 0;
}
/* Nav links */
.nav-links { display: flex; flex: 1; }
.nav-links li a {
    height: 44px; padding: 0 14px;
    display: flex; align-items: center; gap: 5px;
    font-size: 13px; font-weight: 500; color: #444; white-space: nowrap;
    transition: var(--tr);
}
.nav-links li a:hover { color: var(--primary); background: rgba(230,46,4,.05); }
.nav-links li a i { font-size: 12px; color: var(--primary); }
.nav-badge {
    margin-left: auto; padding: 0 16px;
    display: flex; align-items: center; gap: 6px;
    font-size: 12px; font-weight: 600; color: var(--success); white-space: nowrap;
}

/* ============================================================
   MENU MOBILE (drawer latéral)
   ============================================================ */
.mobile-nav {
    position: fixed; top: 0; left: -100%;
    width: min(300px, 85vw); height: 100dvh;
    background: white; z-index: 1100;
    display: flex; flex-direction: column;
    transition: left .3s ease;
    box-shadow: var(--sh-lg); overflow-y: auto;
}
.mobile-nav.open { left: 0; }
.mobile-nav-overlay {
    display: none; position: fixed; inset: 0;
    background: rgba(0,0,0,.55); z-index: 1050;
}
.mobile-nav-overlay.open { display: block; }
.mobile-nav-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 14px 16px; background: var(--dark); color: white;
    font-family: var(--font); font-size: 1rem; font-weight: 800; flex-shrink: 0;
}
.mobile-nav-close {
    color: white; font-size: 20px; padding: 4px 8px;
    background: rgba(255,255,255,.1); border-radius: 6px;
    display: flex; align-items: center; justify-content: center;
    width: 32px; height: 32px;
}
.mobile-nav-body { padding: 6px 0; }
.mob-link {
    display: flex; align-items: center; gap: 12px;
    padding: 11px 18px; font-size: 14px; font-weight: 500;
    color: #333; border-bottom: 1px solid var(--gray-lt); transition: var(--tr);
}
.mob-link:hover { background: var(--gray-lt); color: var(--primary); }
.mob-cat-icon {
    width: 30px; height: 30px; border-radius: 6px;
    display: flex; align-items: center; justify-content: center;
    font-size: 13px; flex-shrink: 0;
}
.mob-section {
    padding: 7px 18px; font-size: 10px; font-weight: 700;
    text-transform: uppercase; color: var(--gray);
    background: var(--gray-lt); letter-spacing: .5px;
}
.mob-contact { padding: 14px 18px; display: flex; flex-direction: column; gap: 8px; border-top: 2px solid var(--gray-bd); }
.mob-contact a { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; color: #444; }

/* ============================================================
   HOMEPAGE — grille top
   ============================================================ */
.home-top-grid {
    display: grid;
    grid-template-columns: 200px 1fr 180px;
    gap: 10px; height: 320px;
}
/* Sidebar catégories */
.home-cats-sidebar { display: flex; flex-direction: column; gap: 3px; overflow: hidden; }
.hcs-link {
    flex: 1; display: flex; align-items: center; gap: 8px;
    padding: 0 10px;
    background: #f8f8f8; border: 1px solid var(--gray-bd);
    border-radius: 6px; font-size: 12px; font-weight: 500; color: #333;
    transition: var(--tr); white-space: nowrap; overflow: hidden;
}
.hcs-link:hover { border-color: var(--primary); color: var(--primary); background: #fff5f5; transform: translateX(2px); }
.hcs-icon {
    width: 26px; height: 26px; border-radius: 5px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center; font-size: 12px;
}
/* Hero slider */
.hero-main { position: relative; border-radius: var(--r-lg); overflow: hidden; }
.hero-slide {
    position: absolute; inset: 0; display: none;
    align-items: center; padding: 36px;
}
.hero-slide.active { display: flex; }
.hero-slide-1 { background: linear-gradient(135deg,#1a1a2e,#e62e04); }
.hero-slide-2 { background: linear-gradient(135deg,#0f3460,#e94560); }
.hero-slide-3 { background: linear-gradient(135deg,#134e5e,#71b280); }
.hero-content { color: white; z-index: 2; max-width: 65%; }
.hero-tag {
    display: inline-block; background: var(--accent); color: var(--dark);
    font-size: 11px; font-weight: 700; padding: 3px 10px;
    border-radius: 20px; margin-bottom: 10px; text-transform: uppercase;
}
.hero-content h2 { font-family: var(--font); font-size: 1.7rem; font-weight: 800; line-height: 1.2; margin-bottom: 12px; }
.hero-content p  { font-size: 13px; opacity: .85; margin-bottom: 16px; }
.hero-cta {
    display: inline-flex; align-items: center; gap: 7px;
    background: white; color: var(--dark);
    padding: 9px 20px; border-radius: 6px;
    font-weight: 700; font-size: 13px; transition: var(--tr);
}
.hero-cta:hover { background: var(--accent); transform: translateY(-2px); }
.hero-slide-emoji { position: absolute; right: 20px; top: 50%; transform: translateY(-50%); font-size: 6rem; opacity: .12; color: white; }
.hero-dots {
    position: absolute; bottom: 12px; left: 50%; transform: translateX(-50%);
    display: flex; gap: 6px; z-index: 3;
}
.hero-dot { width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,.4); cursor: pointer; transition: var(--tr); }
.hero-dot.active { background: white; width: 22px; border-radius: 4px; }
/* Mini banners */
.hero-right { display: flex; flex-direction: column; gap: 6px; }
.hero-mini-banner {
    flex: 1; border-radius: var(--r); padding: 12px;
    color: white; display: flex; flex-direction: column; justify-content: center;
}
.hero-mini-banner h3 { font-size: .85rem; font-weight: 700; margin-bottom: 3px; }
.hero-mini-banner p  { font-size: 11px; opacity: .85; margin-bottom: 7px; }
.hero-mini-banner a  { font-size: 11px; font-weight: 700; background: rgba(255,255,255,.9); padding: 3px 10px; border-radius: 4px; color: #333; width: fit-content; }
.hmb-1 { background: linear-gradient(135deg,#f093fb,#f5576c); }
.hmb-2 { background: linear-gradient(135deg,#4facfe,#00f2fe); }
.hmb-3 { background: linear-gradient(135deg,#43e97b,#38f9d7); }

/* ============================================================
   BARRE CATÉGORIES
   ============================================================ */
.cat-bar { padding: 16px 0; }
.cat-bar-grid {
    display: grid;
    grid-template-columns: repeat(9, 1fr);
    gap: 10px;
}
.cat-bar-item {
    display: flex; flex-direction: column; align-items: center;
    padding: 12px 6px; gap: 7px;
    background: white; border: 1px solid var(--gray-bd);
    border-radius: var(--r); transition: var(--tr); cursor: pointer; text-align: center;
}
.cat-bar-item:hover { border-color: var(--primary); transform: translateY(-2px); box-shadow: var(--sh); }
.cat-bar-icon {
    width: 46px; height: 46px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 20px; transition: var(--tr);
}
.cat-bar-item:hover .cat-bar-icon { transform: scale(1.1); }
.cat-bar-name { font-size: 11px; font-weight: 600; color: #444; line-height: 1.3; }

/* ============================================================
   SECTIONS
   ============================================================ */
.section       { padding: 20px 0; }
.section-white { background: white; }
.section-header {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 16px; padding-bottom: 10px; border-bottom: 2px solid var(--gray-bd);
}
.section-title {
    display: flex; align-items: center; gap: 10px;
    font-family: var(--font); font-size: 1.1rem; font-weight: 700; color: var(--dark);
}
.section-title::before { content: ''; display: block; width: 4px; height: 20px; background: var(--primary); border-radius: 2px; }
.section-link { color: var(--primary); font-size: 12px; font-weight: 600; display: flex; align-items: center; gap: 4px; white-space: nowrap; transition: var(--tr); }
.section-link:hover { gap: 8px; }

/* ============================================================
   GRILLE PRODUITS
   ============================================================ */
.products-grid     { display: grid; grid-template-columns: repeat(5,1fr); gap: 14px; }
.products-grid.g4  { grid-template-columns: repeat(4,1fr); }
.products-grid.g6  { grid-template-columns: repeat(6,1fr); }

.product-card {
    background: white; border: 1px solid var(--gray-bd);
    border-radius: var(--r); overflow: hidden; transition: var(--tr); position: relative;
}
.product-card:hover { border-color: var(--primary); box-shadow: var(--sh-md); transform: translateY(-3px); }
.prod-img-wrap { position: relative; background: var(--gray-lt); overflow: hidden; }
.prod-img-wrap > a { display: block; }
.prod-img-wrap img { transition: transform .4s; }
.product-card:hover .prod-img-wrap img { transform: scale(1.06); }
.prod-badges { position: absolute; top: 8px; left: 8px; display: flex; flex-direction: column; gap: 4px; z-index: 2; }
.badge { font-size: 10px; font-weight: 700; padding: 2px 7px; border-radius: 3px; text-transform: uppercase; }
.badge-sale { background: var(--primary); color: white; }
.badge-new  { background: var(--success); color: white; }
.badge-hot  { background: var(--secondary); color: white; }
.prod-actions {
    position: absolute; top: 8px; right: 8px;
    display: flex; flex-direction: column; gap: 5px;
    opacity: 0; transform: translateY(-8px); transition: var(--tr); z-index: 2;
}
.product-card:hover .prod-actions { opacity: 1; transform: translateY(0); }
.prod-action-btn {
    width: 30px; height: 30px; border-radius: 50%;
    background: white; display: flex; align-items: center; justify-content: center;
    font-size: 12px; color: #555; box-shadow: 0 2px 8px rgba(0,0,0,.15); transition: var(--tr);
}
.prod-action-btn:hover { background: var(--primary); color: white; }
.prod-info { padding: 10px 12px 12px; }
.prod-cat  { font-size: 10px; color: var(--primary); margin-bottom: 3px; font-weight: 600; }
.prod-name { font-size: 13px; font-weight: 500; color: #333; line-height: 1.4; margin-bottom: 6px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.prod-price { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 6px; }
.price-now  { font-family: var(--font); font-size: .95rem; font-weight: 700; color: var(--primary); }
.price-old  { font-size: 11px; color: var(--gray); text-decoration: line-through; }
.price-pct  { font-size: 10px; font-weight: 700; color: var(--success); background: rgba(16,185,129,.1); padding: 1px 5px; border-radius: 3px; }
.prod-meta  { display: flex; align-items: center; justify-content: space-between; }
.prod-stars { display: flex; align-items: center; gap: 3px; font-size: 11px; color: var(--warning); }
.prod-stars span { color: var(--gray); margin-left: 2px; }
.prod-stock { font-size: 10px; color: var(--primary); }
.btn-add-cart {
    display: flex; align-items: center; justify-content: center; gap: 5px;
    width: calc(100% + 24px); margin: 10px -12px -12px;
    padding: 8px; font-size: 12px; font-weight: 600;
    background: var(--primary); color: white;
    border-radius: 0 0 var(--r) var(--r);
    opacity: 0; transform: translateY(4px); transition: var(--tr);
}
.product-card:hover .btn-add-cart { opacity: 1; transform: translateY(0); }
.btn-add-cart:hover { background: var(--primary-dk); }

/* ============================================================
   FLASH DEALS
   ============================================================ */
.flash-section {
    background: white; border: 2px solid var(--primary);
    border-radius: var(--r-lg); padding: 18px; margin: 16px 0;
}
.flash-header { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; flex-wrap: wrap; }
.flash-title  { font-family: var(--font); font-size: 1.1rem; font-weight: 800; color: var(--primary); display: flex; align-items: center; gap: 8px; }
.flash-clock  { display: flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 600; }
.cd-box { background: var(--dark); color: white; padding: 4px 8px; border-radius: 4px; min-width: 32px; text-align: center; font-family: var(--font); }
.cd-sep { color: var(--primary); font-weight: 700; }

/* ============================================================
   BANNIÈRES
   ============================================================ */
.banners-row { display: grid; grid-template-columns: repeat(3,1fr); gap: 12px; padding: 12px 0; }
.banner-card {
    border-radius: var(--r-lg); overflow: hidden; position: relative;
    height: 120px; display: flex; align-items: center; padding: 18px;
    cursor: pointer; transition: var(--tr);
}
.banner-card:hover { transform: translateY(-2px); box-shadow: var(--sh-md); }
.bn-1 { background: linear-gradient(135deg,#ff6a00,#ee0979); }
.bn-2 { background: linear-gradient(135deg,#11998e,#38ef7d); }
.bn-3 { background: linear-gradient(135deg,#4776e6,#8e54e9); }
.banner-content { color: white; z-index: 2; }
.banner-content h3 { font-family: var(--font); font-size: .95rem; font-weight: 700; margin-bottom: 3px; }
.banner-content p  { font-size: 11px; opacity: .9; margin-bottom: 7px; }
.banner-content a  { background: rgba(255,255,255,.9); color: #333; border-radius: 4px; padding: 4px 12px; font-size: 11px; font-weight: 700; display: inline-block; }
.banner-bg { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); font-size: 4rem; opacity: .15; color: white; }

/* ============================================================
   TRUST BADGES
   ============================================================ */
.trust-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 12px; padding: 12px 0; }
.trust-item { background: white; border-radius: var(--r); padding: 16px 12px; text-align: center; border: 1px solid var(--gray-bd); }
.trust-item i  { font-size: 1.7rem; color: var(--primary); margin-bottom: 7px; display: block; }
.trust-item h4 { font-size: 12px; font-weight: 700; margin-bottom: 3px; }
.trust-item p  { font-size: 11px; color: var(--gray); }

/* ============================================================
   PAGES INTERNES
   ============================================================ */
.breadcrumb { padding: 10px 0; display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--gray); flex-wrap: wrap; }
.breadcrumb a { color: var(--primary); }
.page-layout { display: grid; grid-template-columns: 220px 1fr; gap: 18px; padding: 16px 0; }
.sidebar { background: white; border-radius: var(--r); padding: 14px; height: fit-content; position: sticky; top: 110px; }
.sidebar-title { font-weight: 700; font-size: 13px; margin-bottom: 10px; padding-bottom: 6px; border-bottom: 2px solid var(--gray-bd); }
.sidebar-item { display: flex; align-items: center; gap: 8px; padding: 7px 4px; font-size: 12px; color: #555; border-bottom: 1px solid var(--gray-lt); cursor: pointer; transition: var(--tr); }
.sidebar-item:hover { color: var(--primary); padding-left: 8px; }
.price-range { display: flex; gap: 6px; align-items: center; margin-top: 8px; }
.toolbar { background: white; border-radius: var(--r); padding: 11px 14px; margin-bottom: 12px; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; }
.toolbar-sort { display: flex; align-items: center; gap: 8px; }
.toolbar-sort label { font-size: 12px; color: #666; }
.toolbar-sort select { padding: 6px 10px; font-size: 12px; border: 1px solid var(--gray-bd); border-radius: 4px; outline: none; }
.pagination { display: flex; gap: 4px; justify-content: center; padding: 16px 0; flex-wrap: wrap; }
.page-btn { width: 34px; height: 34px; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 13px; border: 1px solid var(--gray-bd); background: white; cursor: pointer; transition: var(--tr); }
.page-btn:hover, .page-btn.active { background: var(--primary); color: white; border-color: var(--primary); }
.empty-state { text-align: center; padding: 50px 20px; }
.empty-state i { font-size: 3rem; color: #ddd; margin-bottom: 12px; display: block; }
.empty-state h3 { color: #666; margin-bottom: 6px; }
.empty-state p  { color: #aaa; font-size: 13px; }

/* Product detail */
.prod-detail-wrap { background: white; border-radius: var(--r-lg); padding: 24px; margin-bottom: 20px; }
.prod-detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
.gallery-main { width: 100%; aspect-ratio: 1; object-fit: cover; border: 1px solid var(--gray-bd); border-radius: var(--r); margin-bottom: 8px; }
.gallery-thumbs { display: flex; gap: 8px; flex-wrap: wrap; }
.gallery-thumb { width: 60px; height: 60px; object-fit: cover; border: 1px solid var(--gray-bd); border-radius: 4px; cursor: pointer; transition: var(--tr); }
.gallery-thumb:hover, .gallery-thumb.active { border-color: var(--primary); }
.det-title { font-family: var(--font); font-size: 1.3rem; font-weight: 700; margin-bottom: 10px; }
.det-price { padding: 12px; background: var(--gray-lt); border-radius: var(--r); margin-bottom: 14px; }
.det-price-now { font-family: var(--font); font-size: 1.7rem; font-weight: 800; color: var(--primary); }
.qty-wrap { display: flex; align-items: center; border: 1px solid var(--gray-bd); border-radius: 4px; overflow: hidden; }
.qty-btn  { padding: 8px 12px; background: var(--gray-lt); font-size: 16px; transition: var(--tr); }
.qty-btn:hover { background: var(--primary); color: white; }
.qty-input { width: 42px; text-align: center; border: none; border-left: 1px solid var(--gray-bd); border-right: 1px solid var(--gray-bd); padding: 8px 4px; font-size: 13px; outline: none; }
.tab-nav { display: flex; border-bottom: 2px solid var(--gray-bd); }
.tab-nav-btn { padding: 10px 18px; font-size: 13px; font-weight: 600; color: #888; cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -2px; transition: var(--tr); }
.tab-nav-btn.active { color: var(--primary); border-bottom-color: var(--primary); }
.tab-pane { padding-top: 16px; display: none; }
.tab-pane.active { display: block; }

/* Cart */
.cart-grid { display: grid; grid-template-columns: 1fr 290px; gap: 16px; }
.cart-table { width: 100%; border-collapse: collapse; background: white; border-radius: var(--r); overflow: hidden; }
.cart-table th { background: var(--gray-lt); padding: 11px 14px; text-align: left; font-size: 11px; font-weight: 700; color: #666; text-transform: uppercase; }
.cart-table td { padding: 11px 14px; border-bottom: 1px solid var(--gray-bd); vertical-align: middle; font-size: 13px; }
.cart-prod { display: flex; align-items: center; gap: 10px; }
.cart-prod img { width: 52px; height: 52px; object-fit: cover; border-radius: 4px; flex-shrink: 0; }
.cart-summary { background: white; border: 1px solid var(--gray-bd); border-radius: var(--r); padding: 16px; position: sticky; top: 110px; }
.sum-row { display: flex; justify-content: space-between; padding: 7px 0; font-size: 13px; }
.sum-total { font-weight: 700; font-size: 1rem; border-top: 2px solid var(--gray-bd); padding-top: 10px; margin-top: 4px; color: var(--primary); }

/* Auth */
.auth-page { min-height: 80vh; display: flex; align-items: center; justify-content: center; padding: 40px 16px; }
.auth-card { background: white; border-radius: var(--r-lg); padding: 28px 24px; width: 100%; max-width: 440px; box-shadow: var(--sh-md); }
.auth-tabs { display: flex; border-bottom: 2px solid var(--gray-bd); margin-bottom: 20px; }
.auth-tab { flex: 1; text-align: center; padding: 10px; font-weight: 500; font-size: 13px; color: #888; cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -2px; transition: var(--tr); }
.auth-tab.active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 700; }
.auth-title { font-family: var(--font); font-size: 1.3rem; font-weight: 800; margin-bottom: 4px; }
.auth-sub { color: var(--gray); font-size: 13px; margin-bottom: 18px; }
.auth-divider { text-align: center; margin: 12px 0; color: #aaa; font-size: 12px; position: relative; }
.auth-divider::before, .auth-divider::after { content: ''; position: absolute; top: 50%; width: 43%; height: 1px; background: var(--gray-bd); }
.auth-divider::before { left: 0; } .auth-divider::after { right: 0; }

/* Forms */
.form-group { margin-bottom: 14px; }
.form-label { display: block; font-weight: 600; font-size: 12px; margin-bottom: 5px; color: #444; }
.form-control { width: 100%; padding: 10px 12px; border: 1.5px solid var(--gray-bd); border-radius: 6px; font-size: 13px; outline: none; transition: var(--tr); }
.form-control:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(230,46,4,.08); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

/* Buttons */
.btn { display: inline-flex; align-items: center; gap: 7px; padding: 9px 18px; border-radius: 6px; font-size: 13px; font-weight: 600; border: 2px solid transparent; cursor: pointer; transition: var(--tr); white-space: nowrap; }
.btn-primary { background: var(--primary); color: white; }
.btn-primary:hover { background: var(--primary-dk); transform: translateY(-1px); }
.btn-outline { background: white; color: var(--primary); border-color: var(--primary); }
.btn-outline:hover { background: var(--primary); color: white; }
.btn-secondary { background: #f1f5f9; color: #475569; border-color: #e2e8f0; }
.btn-dark { background: var(--dark); color: white; }
.btn-lg  { padding: 12px 24px; font-size: 14px; }
.btn-sm  { padding: 6px 12px; font-size: 12px; }
.btn-block { width: 100%; justify-content: center; }

/* Alerts / Tags */
.alert { padding: 11px 14px; border-radius: 6px; margin-bottom: 14px; font-size: 13px; display: flex; align-items: center; gap: 8px; }
.alert-success { background: rgba(16,185,129,.1); color: var(--success); border: 1px solid rgba(16,185,129,.2); }
.alert-error   { background: rgba(230,46,4,.1); color: var(--primary); border: 1px solid rgba(230,46,4,.2); }
.alert-info    { background: rgba(59,130,246,.1); color: var(--info); border: 1px solid rgba(59,130,246,.2); }
.tag { display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 20px; font-size: 11px; font-weight: 500; }
.tag-success { background: rgba(16,185,129,.1); color: var(--success); }
.tag-primary { background: rgba(230,46,4,.1); color: var(--primary); }

/* Footer */
.main-footer { background: var(--dark); color: #ccc; margin-top: 36px; }
.footer-top  { padding: 40px 0 24px; }
.footer-grid { display: grid; grid-template-columns: 260px repeat(3,1fr); gap: 28px; }
.footer-logo { font-family: var(--font); font-size: 1.1rem; font-weight: 800; color: white; display: flex; align-items: center; gap: 8px; }
.footer-logo i { color: var(--primary); }
.footer-brand p { font-size: 12px; color: #888; line-height: 1.7; margin: 10px 0 12px; }
.footer-contact { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.footer-contact a { font-size: 12px; color: #aaa; display: flex; align-items: center; gap: 7px; transition: var(--tr); }
.footer-contact a:hover { color: white; }
.footer-contact i { color: var(--primary); width: 14px; }
.social-links { display: flex; gap: 8px; }
.social-links a { width: 32px; height: 32px; border-radius: 50%; background: rgba(255,255,255,.08); color: #ccc; display: flex; align-items: center; justify-content: center; font-size: 13px; transition: var(--tr); }
.social-links a:hover { background: var(--primary); color: white; }
.footer-col h4 { color: white; font-size: 13px; font-weight: 700; margin-bottom: 12px; }
.footer-col ul li { margin-bottom: 7px; }
.footer-col ul li a { font-size: 12px; color: #888; display: flex; align-items: center; gap: 6px; transition: var(--tr); }
.footer-col ul li a:hover { color: white; padding-left: 4px; }
.payment-methods { display: flex; flex-direction: column; gap: 6px; }
.pay-item { display: flex; align-items: center; gap: 8px; font-size: 12px; color: #888; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.08); padding: 14px 0; }
.footer-bottom-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 6px; }
.footer-bottom p { font-size: 12px; color: #666; }
.footer-bottom-links { display: flex; gap: 14px; }
.footer-bottom-links a { font-size: 12px; color: #666; transition: var(--tr); }
.footer-bottom-links a:hover { color: white; }


/* ── Fiche produit : boutons panier responsive ───────────── */
.det-cart-section {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 2px;
}
.det-cart-btn {
    flex: 1;
    min-width: 160px;
    justify-content: center;
    white-space: nowrap;
}
.det-wish-btn {
    flex-shrink: 0;
    width: 46px;
    height: 46px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--r);
}
@media (max-width: 767px) {
    .det-cart-section    { gap: 8px; }
    .det-cart-btn        { min-width: 0; font-size: 13px; padding: 11px 14px; }
    .det-cart-btn span   { display: inline; }
    .det-wish-btn        { width: 44px; height: 44px; }
    .det-price-now       { font-size: 1.4rem; }
    .prod-detail-grid    { gap: 16px; }
    .prod-detail-wrap    { padding: 16px; }
    .gallery-main        { border-radius: var(--r); }
}


/* ── Wishlist feedback ───────────────────────────────────── */
.wishlist-btn.active i,
.wishlist-btn i.liked { color: var(--primary) !important; }

/* Floating */
.back-to-top { position: fixed; bottom: 78px; right: 18px; width: 40px; height: 40px; border-radius: 50%; background: var(--primary); color: white; font-size: 15px; display: none; align-items: center; justify-content: center; box-shadow: 0 4px 12px rgba(230,46,4,.4); z-index: 1000; transition: var(--tr); }
.back-to-top.show { display: flex; }
.back-to-top:hover { transform: translateY(-3px); }
.cart-toast { position: fixed; bottom: 68px; right: 18px; background: var(--success); color: white; padding: 10px 16px; border-radius: 8px; font-size: 13px; font-weight: 600; display: flex; align-items: center; gap: 8px; transform: translateX(200px); opacity: 0; transition: all .4s; z-index: 1001; box-shadow: var(--sh-md); max-width: 250px; }
.cart-toast.show { transform: translateX(0); opacity: 1; }
.wa-float { position: fixed; bottom: 18px; right: 18px; width: 50px; height: 50px; border-radius: 50%; background: #25d366; color: white; font-size: 24px; display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 16px rgba(37,211,102,.4); z-index: 1000; transition: var(--tr); }
.wa-float:hover { transform: scale(1.1); }

/* ============================================================
   RESPONSIVE — TABLET  768px – 1023px
   ============================================================ */
@media (min-width: 768px) and (max-width: 1023px) {
    .home-top-grid       { grid-template-columns: 170px 1fr; height: 260px; }
    .hero-right          { display: none; }
    .hero-content h2     { font-size: 1.35rem; }
    .products-grid       { grid-template-columns: repeat(3,1fr); gap: 12px; }
    .products-grid.g4    { grid-template-columns: repeat(3,1fr); }
    .cat-bar-grid        { grid-template-columns: repeat(5,1fr); }
    .trust-grid          { grid-template-columns: repeat(2,1fr); }
    .banners-row         { grid-template-columns: 1fr 1fr; }
    .footer-grid         { grid-template-columns: 1fr 1fr; }
    .footer-brand        { grid-column: 1 / -1; }
    .nav-badge           { display: none; }
    .topbar              { display: none; }
    .search-cat          { min-width: 110px; }
    .page-layout         { grid-template-columns: 200px 1fr; }
    .prod-detail-grid    { grid-template-columns: 1fr; }
    .cart-grid           { grid-template-columns: 1fr; }
    .cart-summary        { position: static; }
}

/* ============================================================
   RESPONSIVE — MOBILE  < 768px
   ============================================================ */
@media (max-width: 767px) {

    /* ── Masquer éléments desktop ── */
    .topbar              { display: none; }
    .home-cats-sidebar   { display: none; }
    .hero-right          { display: none; }
    .nav-badge           { display: none; }
    .search-cat          { display: none; }
    .search-bar .btn-txt { display: none; }

    /* ── Header compact 2 lignes ── */
    .main-header         { padding: 7px 0; }
    .header-inner {
        grid-template-columns: 1fr auto;
        grid-template-rows: auto auto;
        grid-template-areas:
            "logo actions"
            "search search";
        gap: 7px 8px;
    }
    .logo-icon           { width: 34px; height: 34px; font-size: 15px; border-radius: 8px; }
    .logo-main           { font-size: .9rem; }
    .logo-sub            { display: none; }

    /* Favoris masqués sur mobile, panier toujours visible */
    .hdr-wish-desktop    { display: none !important; }
    .hdr-label           { display: none; }          /* masquer le texte "Panier" */
    .hdr-btn             { padding: 4px 7px; }
    .hdr-btn i           { font-size: 20px; }
    .hdr-cart-btn        { padding: 6px 10px; }      /* panier un peu plus grand */
    .cart-badge          { top: -7px; right: -9px; min-width: 17px; height: 17px; font-size: 9px; }
    .burger-btn          { display: flex; }
    .search-bar          { grid-area: search; }
    .search-bar input    { height: 38px; font-size: 12px; }
    .search-bar button   { height: 38px; padding: 0 13px; font-size: 12px; }

    /* ── Nav entière masquée sur mobile (menu burger utilisé) ── */
    .main-nav            { display: none; }

    /* ── Hero compact ── */
    .hero-section, .home-section-top { padding: 6px 0 0; }
    .home-top-grid       { grid-template-columns: 1fr; height: 155px; }
    .hero-main           { border-radius: 8px; }
    .hero-slide          { padding: 14px 16px; }
    .hero-content h2     { font-size: 1rem; line-height: 1.2; margin-bottom: 8px; }
    .hero-content p      { display: none; }
    .hero-cta            { padding: 7px 12px; font-size: 11px; }
    .hero-tag            { font-size: 9px; padding: 2px 7px; margin-bottom: 6px; }
    .hero-slide-emoji    { font-size: 4rem; }
    .hero-dots           { bottom: 8px; }
    .hero-dot            { width: 6px; height: 6px; }
    .hero-dot.active     { width: 16px; }

    /* ── Catégories : scroll horizontal 1 ligne ── */
    .cat-bar             { padding: 8px 0; }
    .cat-bar-grid {
        display: flex;
        overflow-x: auto;
        gap: 7px;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 2px;
    }
    .cat-bar-grid::-webkit-scrollbar { display: none; }
    .cat-bar-item        { flex-shrink: 0; width: 70px; padding: 8px 4px; gap: 5px; }
    .cat-bar-icon        { width: 38px; height: 38px; font-size: 16px; }
    .cat-bar-name        { font-size: 9px; }

    /* ── Produits : 2 colonnes ── */
    .products-grid,
    .products-grid.g4,
    .products-grid.g6    { grid-template-columns: repeat(2,1fr); gap: 9px; }
    .prod-info           { padding: 7px 9px 9px; }
    .prod-name           { font-size: 11.5px; }
    .price-now           { font-size: .88rem; }
    .btn-add-cart        { font-size: 10px; padding: 6px; }

    /* ── Sections ── */
    .section             { padding: 12px 0; }
    .section-title       { font-size: .95rem; }
    .section-header      { margin-bottom: 12px; }

    /* ── Flash ── */
    .flash-section       { padding: 12px; margin: 10px 0; }
    .flash-header        { flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
    .flash-title         { font-size: .9rem; }
    .cd-box              { min-width: 26px; font-size: .75rem; padding: 3px 5px; }

    /* ── Bannières ── */
    .banners-row         { grid-template-columns: 1fr; gap: 7px; padding: 8px 0; }
    .banner-card         { height: 88px; padding: 12px 14px; }
    .banner-content h3   { font-size: .82rem; }
    .banner-content p    { display: none; }
    .banner-bg           { font-size: 3.2rem; }

    /* ── Trust ── */
    .trust-grid          { grid-template-columns: 1fr 1fr; gap: 7px; }
    .trust-item          { padding: 12px 8px; }
    .trust-item i        { font-size: 1.4rem; margin-bottom: 5px; }
    .trust-item h4       { font-size: 11px; }
    .trust-item p        { font-size: 10px; }

    /* ── Pages internes ── */
    .page-layout         { grid-template-columns: 1fr; }
    .sidebar             { display: none; }
    .prod-detail-grid    { grid-template-columns: 1fr; }
    .cart-grid           { grid-template-columns: 1fr; }
    .cart-summary        { position: static; }
    .form-row            { grid-template-columns: 1fr; }
    .auth-card           { padding: 20px 14px; }

    /* ── Footer ── */
    .footer-grid         { grid-template-columns: 1fr 1fr; gap: 16px; }
    .footer-brand        { grid-column: 1 / -1; }
    .main-footer         { margin-top: 18px; }
    .footer-top          { padding: 22px 0 14px; }
    .footer-bottom-inner { flex-direction: column; text-align: center; gap: 5px; }

    /* ── Floating ── */
    .back-to-top         { bottom: 64px; right: 12px; width: 36px; height: 36px; font-size: 13px; }
    .cart-toast          { right: 10px; bottom: 56px; font-size: 11px; padding: 8px 12px; }
    .wa-float            { bottom: 12px; right: 12px; width: 44px; height: 44px; font-size: 21px; }
}

/* ── < 400px ─────────────────────────────────────────────── */
@media (max-width: 400px) {
    .container           { padding: 0 8px; }
    .home-top-grid       { height: 140px; }
    .hero-content h2     { font-size: .92rem; }
    .cat-bar-item        { width: 62px; }
    .cat-bar-icon        { width: 34px; height: 34px; font-size: 14px; }
    .cat-bar-name        { font-size: 8.5px; }
    .products-grid       { gap: 7px; }
    .prod-info           { padding: 6px 7px 8px; }
    .prod-name           { font-size: 11px; }
    .price-now           { font-size: .82rem; }
    .footer-grid         { grid-template-columns: 1fr; }
}

/* ── Bouton favoris sur card (toujours visible) ───────────── */
.prod-wish-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 16px;
    color: #ccc;
    padding: 2px 4px;
    transition: all .2s;
    line-height: 1;
    margin-left: auto;
    flex-shrink: 0;
}
.prod-wish-btn:hover i,
.prod-wish-btn.active i { color: var(--primary); }
.prod-wish-btn.active i { font-weight: 900; }
.prod-wish-btn i.fas    { color: var(--primary); }

/* ── Bouton favoris header — couleur rouge ───────────────── */
.hdr-cart-btn .fa-heart { color: var(--primary); }