:root {
  --accent: var(--color-primary, #0d6efd);
   --bg-soft: var(--bg-soft, #f7f8fa);
  --card-radius: var(--card-radius, 16px);
  --shadow-sm: 0 4px 12px rgba(0, 0, 0, .06);
  --shadow-lg: 0 14px 34px rgba(0, 0, 0, .12);
}

body {
  background: var(--bg-soft, #f7f8fa);
  font-family: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
}

/* HERO */
.hero {
  background: linear-gradient(180deg, #fff, rgba(255, 255, 255, 0));
}
.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(800px 300px at 80% 0%, rgba(13, 110, 253, .08), transparent 60%),
    radial-gradient(600px 220px at 10% 10%, rgba(25, 135, 84, .06), transparent 60%);
  mix-blend: normal;
}
.hero-visual {
  border-radius: 24px;
  overflow: hidden;
  background: #fff;
}
.hero-visual img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  aspect-ratio: 4/3;
}

/* Sections */
.section-block { margin-top: 2.5rem; }
.section-head {
  display: flex; align-items: center; justify-content: space-between; margin-bottom: 1rem;
}
.section-title { margin: 0; font-weight: 800; }

/* Cat scroll */
.cat-scroll { overflow: auto; scrollbar-width: thin; padding-bottom: .25rem; }
.cat-scroll::-webkit-scrollbar { height: 6px; }
.cat-scroll::-webkit-scrollbar-thumb { background: #e1e5ea; border-radius: 6px; }

/* Product cards */
.product {
  border: 0; border-radius: var(--card-radius, 16px);
  background: var(--color-surface, #ffffff);
  box-shadow: var(--shadow-sm);
  transition: transform .25s ease, box-shadow .25s ease;
}
.product:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.product-media { display: block; overflow: hidden;position: relative;
  border-top-left-radius: var(--card-radius); border-top-right-radius: var(--card-radius);
}
.ratio { position: relative; width: 100%; }
.ratio::before { content: ""; display: block; padding-top: 75%; } /* 4:3 */
.img-cover { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.product:hover .img-cover { transform: scale(1.045); }

.product-title { line-height: 1.3; min-height: 1.3em; }
.p-badge {
  position: absolute; top: .65rem; left: .65rem; padding: .35rem .6rem;
  font-size: .7rem; font-weight: 700; border-radius: 999px; color: #fff; letter-spacing: .02em;
}

.btn-primary { transition: transform .2s, box-shadow .2s; }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 6px 18px rgba(13,110,253,.25); }

/* Focus visible (a11y) */
a:focus-visible, button:focus-visible, select:focus-visible {
  outline: 3px solid rgba(13,110,253,.45);
  outline-offset: 2px;
  border-radius: 8px;
}

/* Responsive */
@media (max-width: 575.98px) {
  .display-5 { font-size: 2rem; }
  .hero-visual img { aspect-ratio: 16/9; }
}

/* Dark mode auto */
@media (prefers-color-scheme: dark) {
  body { background: #0b0e12; color: #e6e6e6; }
  .hero { background: linear-gradient(180deg, #0b0e12, #0b0e1200); }
  .hero-visual { background: #0f1318; }
  .product { background: #0f1318; }
  .cat-scroll::-webkit-scrollbar-thumb { background: #1e2630; }
}
.banner-img {
  height: 100%;
  object-fit: fill;
  border-radius: 0;
}

.carousel-caption {
  background: rgba(0, 0, 0, 0.35);
  padding: 2rem;
  border-radius: 1rem;
  max-width: 50%;
}

.text-shadow {
  text-shadow: 0 2px 8px rgba(0,0,0,0.8);
}

@media (max-width: 768px) {
  .banner-img {
    height: 50vh;
  }
  .carousel-caption {
    max-width: 90%;
    padding: 1.5rem;
  }
  .carousel-caption h2 {
    font-size: 1.5rem;
  }
}


  /* ==== Ligne du haut : logo + recherche + actions ==== */
  .header-actions {
    display: flex; gap: 1rem; align-items: center;
  }
  .header-action {
    display: inline-flex; align-items: center; gap: .5rem;
    padding: .35rem .6rem; border-radius: 14px; text-decoration: none;
    color: var(--bs-body-color);
  }
  .header-action:hover { background: rgba(0,0,0,.04); color: var(--bs-body-color); }
  .header-action .icon { font-size: 1.35rem; line-height: 1; }
  .header-action .label { font-weight: 500; font-size: .95rem; }
  .header-action.emphasis {
    background: rgba(0,0,0,.04);
    box-shadow: inset 0 0 0 1px rgba(0,0,0,.06);
  }

  .search-input-group .form-control {
    border-radius: 999px; padding-left: 2.5rem; height: 44px;
    box-shadow: 0 1px 0 rgba(0,0,0,.02);
  }
  .search-input-group .form-control:focus { box-shadow: 0 0 0 .2rem rgba(13,110,253,.08); }
  .search-input-group .search-icon { left: 14px; color: #9aa0a6; }

  /* ==== Ligne du bas : bouton Catégories + rubriques horizontales ==== */
  .categories-bar-full { background: var(--bs-body-bg); border-bottom: 1px solid rgba(0,0,0,.08); }
  .btn-categories {
    display: inline-flex; align-items: center; gap: .6rem;
    border: 1px solid rgba(0,0,0,.12);
    background: #fff; color: var(--bs-body-color);
    padding: .5rem .9rem; border-radius: 12px; font-weight: 600;
  }
  .btn-categories .bi { font-size: 1.05rem; }
  .btn-categories:hover { background: rgba(0,0,0,.03); }

  .categories-track {
    display: flex; align-items: center; gap: 1.1rem; overflow: auto; scrollbar-width: thin;
  }
  .category-link {
    white-space: nowrap; font-weight: 500; text-decoration: none;
    color: var(--bs-body-color); opacity: .9; padding: .35rem 0; position: relative;
  }
  .category-link:hover { opacity: 1; }
  .category-link::after {
    content:""; position:absolute; left:0; right:0; bottom:-6px; height:2px;
    background: currentColor; transform: scaleX(0); transform-origin:left; transition: transform .25s;
  }
  .category-link:hover::after { transform: scaleX(1); }

  /* Petit dropdown pour le bouton Catégories */
  .categories-dropdown {
    position: absolute; top: calc(100% + .5rem); left: 0; z-index: 1200;
    min-width: 260px; background:#fff; border-radius:12px; box-shadow:0 12px 30px rgba(0,0,0,.12);
    padding:.5rem; display:none;
  }
  .categories-dropdown a {
    display:block; padding:.5rem .6rem; border-radius:8px; color: var(--bs-body-color);
    text-decoration:none;
  }
  .categories-dropdown a:hover { background: rgba(0,0,0,.04); }

  @media (max-width: 992px) {
    .header-actions { gap: .5rem; }
    .header-action .label { display: none; } /* compacter sur mobile */
    .btn-categories span { display: none; }  /* garder seulement l’icône */
  }

  /* Forcer la caption à occuper toute la largeur et à coller en bas */
 .carousel-item { position: relative; } /* ancre pour la caption */

#homeBanner .carousel-caption {
  position: absolute;
  left: 0 !important;     /* override BS: left:15% */
  right: 0 !important;    /* override BS: right:15% */
  bottom: 0 !important;   /* colle au bas du visuel */
  max-width: 100%;
  margin: 0;
  padding: 1rem 1.25rem;  /* ajustable */
  text-align: left;
  border-top: 1px solid rgba(255,255,255,0.25); /* bordure simple */
  background: rgba(0,0,0,0.10);                 /* lisibilité */
  border-radius: 0;
  z-index: 5;
}

.toast-container {
  z-index: 1080;
}
.toast .btn {
  font-size: 0.85rem;
}
/* Dimensions stables et adaptatives */
.fnac-style {
  --pc-media-h: 200px;          /* hauteur de l'image desktop */
  --pc-media-h-sm: 170px;       /* hauteur de l'image <992px */
  --pc-actions-size: 42px;      /* diamètre icônes droite */
  --pc-gap: .5rem;
}

.product-media-wrap { background: var(--bs-body-bg); }
.product-media { display:block; width:100%; height:var(--pc-media-h); }
@media (max-width: 991.98px){ .product-media { height:var(--pc-media-h-sm); } }

.product-media .img-cover { width:100%; height:100%; object-fit:cover; transition: transform .35s ease; }
.fnac-style:hover .img-cover { transform: scale(1.03); }

.promo-ribbon { background: var(--color-danger, #dc3545); /* rouge "offre" - peut être adapté au thème */ }

/* Pile d’actions à droite (wishlist/voir) */
.action-stack .btn {
  width: var(--pc-actions-size); height: var(--pc-actions-size);
  display:grid; place-items:center; box-shadow: 0 .25rem .75rem rgba(0,0,0,.06);
}
.product-wishlist.active i { color: var(--bs-danger); }

/* Corps: grille verticale comme l’exemple */
.fnac-body {
  grid-template-rows: auto auto auto auto; /* title | rating | price | CTA */
  gap: var(--pc-gap);
  padding-top: .75rem; padding-bottom: .75rem;
}

/* Titre + sous-titre */
.product-title { min-height: calc(1em * 2.6); } /* réserve 2 lignes */
.line-clamp-2 {
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

/* Zone prix : gros prix puis ancien barré */
.price-main { line-height: 1.1; }

/* CTA plein large au bas de la card (pas en hover) */
.fnac-cta .btn-cta {
  width:100%;
  padding:.75rem 1rem;
  background: var(--color-primary, var(--color-primary, #0d6efd));
  color: #fff;
  border: none;
}
.fnac-cta .btn-cta:hover { filter: brightness(0.95); }

/* Hover global premium */
.fnac-style { transition: box-shadow .25s ease, transform .25s ease; }
.fnac-style:hover { transform: translateY(-2px); box-shadow: 0 .75rem 1.5rem rgba(0,0,0,.08); }

.page-subheader__icon {
  width: 44px;
  height: 44px;
  background: var(--bg-soft, #f4f6f8);
  color: var(--primary, var(--color-primary, #0d6efd));
  box-shadow: var(--shadow-sm, 0 1px 2px rgba(0,0,0,.06));
}

.page-subheader .breadcrumb a {
  text-decoration: none;
}

.page-subheader .breadcrumb .breadcrumb-item + .breadcrumb-item::before {
  content: "/";
}

.sp-head .badge {
  font-weight: 500;
  font-size: 0.85rem;
  background-color: var(--bg-soft, #f8f9fa);
}

.page-subheader__back a {
    opacity: 0.8;
    transition: opacity 0.15s ease, transform 0.15s ease;
}

.page-subheader__back a:hover {
    opacity: 1;
    transform: translateX(-2px);
}

.back-btn-2025 {
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--bs-secondary);
    background: rgba(0,0,0,0.04);
    transition: all 0.18s ease;
}

.back-btn-2025 i {
    font-size: 1rem;
    margin-right: 4px;
    color: var(--bs-secondary);
}

.back-btn-2025:hover {
    background: rgba(0,0,0,0.08);
    text-decoration: none;
    transform: translateX(-2px);
    color: var(--bs-dark);
}

.back-btn-2025:hover i {
    color: var(--bs-dark);
}

/* Version compacte sur mobile */
@media (max-width: 576px) {
    .back-btn-2025 .text {
        display: none;
    }
    .back-btn-2025 {
        padding: 6px 8px;
        border-radius: 50%;
    }
    .back-btn-2025 i {
        margin-right: 0;
    }
}


.promo-bar {
    background: linear-gradient(
      90deg,
      var(--color-primary, var(--color-primary, #0d6efd)),
      var(--color-accent, #ff7f50)
    );
    color: #fff;
    color: #fff;
}

.promo-bar .badge {
    letter-spacing: 0.08em;
    font-weight: 700;
}

@media (max-width: 576px) {
    .promo-bar .container {
        text-align: center;
    }
}
/* Mobile menu beautification */
.nav-mobile-btn {
  color: #111;
  text-decoration: none;
}

.nav-mobile-btn:hover {
  color: var(--color-primary, var(--color-primary, #0d6efd));
}

.nav-mobile-links .nav-link {
  font-size: 1rem;
  border-radius: 8px;
}

.nav-mobile-links .nav-link:hover {
  background: #f1f5f9;
  color: var(--color-primary, var(--color-primary, #0d6efd));
}


/* Style du collapse quand il est ouvert sur mobile */
@media (max-width: 991.98px) {
  #mainNav.show {
    background: #ffffff;
    border-radius: 18px;
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.16);
    margin-top: 0.75rem;
    padding: 0.75rem 0 1rem;
  }

  #mainNav .search-input-group {
    margin-bottom: 0.75rem;
  }

  /* Les icônes compte / panier / contact en ligne */
  .nav-main-actions {
    flex-direction: row;
    justify-content: space-around;
    align-items: center;
    width: 100%;
    padding-top: 0.25rem;
  }

  .nav-main-actions .nav-item {
    margin: 0;
  }

  .nav-main-actions .nav-link,
  .nav-main-actions .profile-toggle {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    border-radius: 999px;
    border: 1px solid #e5e7eb;
    background: #f9fafb;
    padding: 0;
  }

  .nav-main-actions .nav-link i,
  .nav-main-actions .profile-toggle i {
    font-size: 1.5rem;
  }

  .nav-main-actions .nav-link:hover,
  .nav-main-actions .profile-toggle:hover {
    background: #eff6ff;
    border-color: #dbeafe;
  }

  /* badge panier correctement positionné */
  .nav-main-actions .cart-badge {
    top: 4px;
    right: 8px;
  }
}


/* Image bannière responsive et propre */
.banner-img {
    height: 420px; /* Hauteur équilibrée 2025 */
}

/* Caption totalement indépendant */
.home-banner-caption {
    position: absolute;
    bottom: 12%;
    left: 5%;
    color: #fff;
    max-width: 480px;
}

/* Effet moderne texte */
.home-banner-caption h2,
.home-banner-caption p {
    text-shadow: 0 3px 10px rgba(0,0,0,0.45);
}
/* ============================
   FLÈCHES PREMIUM 2025
============================ */

/* Boutons */
#homeBanner .carousel-control-prev,
#homeBanner .carousel-control-next {
    width: 46px;
    height: 46px;
    top: 50%;
    transform: translateY(-50%);
    border-radius: 50%;
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255,255,255,0.45);
    background: rgba(255,255,255,0.25); /* Clair = premium */
    box-shadow: 0 10px 24px rgba(0,0,0,0.18);
    opacity: 1;
    transition: all .25s ease;
}

/* Décoller du bord */
#homeBanner .carousel-control-prev {
    left: 24px;
}
#homeBanner .carousel-control-next {
    right: 24px;
}

/* Icônes super visibles */
#homeBanner .carousel-control-prev-icon,
#homeBanner .carousel-control-next-icon {
    filter: invert(1) brightness(1.8);  /* BLANC intense */
    width: 22px;
    height: 22px;
}

/* Hover plus profond */
#homeBanner .carousel-control-prev:hover,
#homeBanner .carousel-control-next:hover {
    background: rgba(255,255,255,0.45);
    border-color: rgba(255,255,255,0.75);
    box-shadow: 0 14px 28px rgba(0,0,0,0.25);
}

/* Version mobile */
@media (max-width: 768px) {
    #homeBanner .carousel-control-prev,
    #homeBanner .carousel-control-next {
        width: 38px;
        height: 38px;
    }

    #homeBanner .carousel-control-prev {
        left: 16px;
    }
    #homeBanner .carousel-control-next {
        right: 16px;
    }
}
/* Bouton profil header */
.nav-main-actions .profile-toggle {
    width: 40px;
    height: 40px;
    border-radius: 999px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;

    background: #fff;
    border: 1px solid rgba(15, 23, 42, 0.08); /* bord très léger */
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.10);
    color: #111827;
    cursor: pointer;
    transition: all 0.18s ease;
}

/* Icône */
.nav-main-actions .profile-toggle i {
    font-size: 1.35rem;
}

/* Hover */
.nav-main-actions .profile-toggle:hover {
    border-color: rgba(15, 23, 42, 0.18);
    box-shadow: 0 8px 22px rgba(15, 23, 42, 0.16);
    transform: translateY(-1px);
}

/* Focus accessible mais propre */
.nav-main-actions .profile-toggle:focus-visible {
    outline: 2px solid rgba(37, 99, 235, 0.7);
    outline-offset: 2px;
}
