/* ========== RESET ========== */
#bmp-mobile-nav .bmp-item {
  text-decoration: none;
  color: inherit;
}

/* ========== CONTAINER BARRE MOBILE ========== */
.bmp-mobile-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 8px 6px;
  z-index: 999999;
  box-shadow: 0 -2px 8px rgba(0,0,0,0.08);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
  background: #fff;
  padding-bottom: calc(8px + env(safe-area-inset-bottom, 0px));
}

/* ========== ITEMS ========== */
.bmp-item {
  flex: 1;
  text-align: center;
  font-size: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  position: relative;
  cursor: pointer;
  transition: color .2s ease, transform .2s ease;
}

.bmp-item .bmp-ico {
  font-size: 20px;
  display: block;
  margin-bottom: 4px;
}

.bmp-item .bmp-label {
  display: block;
  line-height: 1;
  font-size: 12px;
}

.bmp-item.is-active {
  color: #0a6cff;
}

.bmp-item:focus-visible {
  outline: 2px solid rgba(10, 108, 255, 0.5);
  outline-offset: 2px;
  border-radius: 8px;
}

.bmp-mobile-nav.bmp-no-labels .bmp-label {
  display: none;
}

.bmp-mobile-nav.bmp-no-labels .bmp-item .bmp-ico {
  margin-bottom: 0;
}

.bmp-mobile-nav.bmp-icon-small .bmp-item .bmp-ico {
  font-size: 16px;
}

.bmp-mobile-nav.bmp-icon-medium .bmp-item .bmp-ico {
  font-size: 20px;
}

.bmp-mobile-nav.bmp-icon-large .bmp-item .bmp-ico {
  font-size: 24px;
}

/* ========== BADGES (compteur panier) ========== */
#bmp-mobile-nav .bmp-cart .bmp-badge,
#bmp-mobile-nav .bmp-cart .bmp-cart-count {
  position: absolute;
  top: 4px;
  right: 14px;
  background: #e02424;
  color: #fff;
  padding: 2px 6px;
  border-radius: 50%;
  font-size: 11px;
  font-weight: bold;
  line-height: 1;
  min-width: 18px;
  text-align: center;
  z-index: 50;
}

/* ========== MODAL (panier, recherche, login, category) ========== */
.bmp-modal {
  position: fixed;
  left: 0;
  right: 0;
  top: 0;
  bottom: 0;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.35);
  z-index: 1000000;
  opacity: 0;
  transition: opacity .24s ease;
}

.bmp-modal.open {
  display: flex;
  opacity: 1;
}

body.bmp-modal-open {
  overflow: hidden;
}

.bmp-modal .bmp-modal-inner {
  background: #fff;
  width: 90%;
  max-width: 520px;
  padding: 16px;
  border-radius: 8px;
  position: relative;
  transform: translateY(10px);
  transition: transform .24s ease;
}

.bmp-modal.open .bmp-modal-inner {
  transform: translateY(0);
}

.bmp-modal.is-fade .bmp-modal-inner {
  transform: none;
}

.bmp-modal.is-slide .bmp-modal-inner {
  transform: translateY(16px);
}

.bmp-modal.is-slide.open .bmp-modal-inner {
  transform: translateY(0);
}

.bmp-close {
  position: absolute;
  right: 8px;
  top: 8px;
  background: transparent;
  border: none;
  font-size: 20px;
  cursor: pointer;
}

/* ========== SEARCH RESULTS ========== */
.bmp-search-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.bmp-search-list li {
  display: flex;
  gap: 8px;
  padding: 8px 0;
  border-bottom: 1px solid #eee;
}

.bmp-search-list img {
  width: 48px;
  height: 48px;
  object-fit: cover;
}

/* ========== RESPONSIVE SAFE SPACE ========== */
@media (max-width:768px){
  body { padding-bottom: 72px; }
}

@media (min-width:769px){
  .bmp-mobile-nav {
    max-width: 760px;
    margin: 0 auto;
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    border-radius: 12px 12px 0 0;
  }
}

/* ========== WHATSAPP ICON ========== */
.bmp-whatsapp .bmp-ico {
  color: #25D366;
  font-size: 22px;
}

/* ========== LOGIN MODAL STYLES ========== */
#bmp-login-form {
    display: flex;
    flex-direction: column;
}
#bmp-login-form h3 {
    margin-top: 0;
}
#bmp-login-form p.form-row {
    margin: 0 0 1em;
}
#bmp-login-form label {
    display: block;
    font-weight: bold;
}
#bmp-login-form input[type="text"],
#bmp-login-form input[type="password"] {
    width: 100%;
    padding: 8px;
    box-sizing: border-box;
}
#bmp-login-form .bmp-login-btn {
    background-color: #0073aa;
    color: #fff;
    border: none;
    padding: 10px 15px;
    cursor: pointer;
    width: 100%;
    font-weight: bold;
}
#bmp-login-form .bmp-login-status {
    margin-bottom: 15px;
    padding: 10px;
    text-align: center;
    border-radius: 4px;
}
#bmp-login-form .bmp-login-status.error {
    background-color: #ffebe8;
    color: #d63638;
}
#bmp-login-form .bmp-login-status.success {
    background-color: #dff0d8;
    color: #468847;
}

/* ========== CATEGORY MODAL STYLES ========== */
.bmp-category-menu {
    width: 100%;
}
.bmp-category-menu > ul {
    list-style: none;
    padding: 0;
    margin: 0;
}
.bmp-category-menu > ul > li {
    font-size: 16px;
    font-weight: bold;
    color: #333;
    padding: 10px 15px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
}
.bmp-category-menu > ul > li.menu-item-has-children .sub-menu {
    display: none;
    padding-left: 20px;
    font-weight: normal;
    font-size: 14px;
}
.bmp-category-menu > ul > li.open > .sub-menu {
    display: block;
}
.bmp-category-menu a {
    text-decoration: none;
    color: inherit;
    display: block;
    width: 100%;
}
.bmp-category-menu .sub-menu a {
    font-weight: normal;
    color: #555;
    padding: 8px 0;
}
.bmp-category-menu .menu-item-has-children > a {
    position: relative;
    width: 100%;
}
.bmp-category-menu .menu-item-has-children > a:after {
    content: '▼';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%) rotate(-90deg);
    transition: transform 0.3s ease;
    font-size: 12px;
}
.bmp-category-menu .menu-item-has-children.open > a:after {
    transform: translateY(-50%) rotate(0deg);
}

/* Style de l'image du menu si elle est dans la navigation */
.bmp-category-menu img {
    height: 24px;
    width: auto;
    margin-right: 10px;
    vertical-align: middle;
}
