.pwa-toolbar {
  display: none;
}

@media (max-width: 768px) {
  .pwa-toolbar {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    background: var(--bs-light-bg-subtle);
    border-top: 1px solid var(--bs-border-color);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.08);
    padding-bottom: env(safe-area-inset-bottom, 0px);
    height: calc(80px + env(safe-area-inset-bottom, 0px));
    align-items: stretch;
  }
}

/* push page content above toolbar */

@media (max-width: 768px) {
  body {
    padding-bottom: calc(60px + env(safe-area-inset-bottom, 0px));
  }
}

@media (max-width: 768px) {
  .pwa-toolbar__btn {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px 4px;
    text-decoration: none;
    color: var(--bs-primary);
    font-family: Anta, sans-serif;
    font-size: 10px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    transition: color 0.15s ease, transform 0.1s ease;
    -webkit-tap-highlight-color: transparent;
  }
}

@media (max-width: 768px) {
  .pwa-toolbar__btn svg {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
  }
}

@media (max-width: 768px) {
  .pwa-toolbar__btn.active {
    color: var(--bs-danger);
    margin-top: 0;
    gap: 0;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 20px;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.2);
  }
}

@media (max-width: 768px) {
  .pwa-toolbar__btn:focus-visible {
    color: var(--bs-primary);
    outline: none;
  }
}

@media (max-width: 768px) {
  .pwa-toolbar__btn:active {
    transform: scale(0.9);
    color: var(--bs-dark);
  }
}

/* active dot indicator */

@media (max-width: 768px) {
  .pwa-toolbar__btn.active::after {
    content: '';
    display: block;
    width: 40px;
    height: 2px;
    border-radius: 50%;
    background: var(--bs-danger);
    margin-top: 0;
  }
}

/* cart icon wrapper + badge */

@media (max-width: 768px) {
  .pwa-cart-wrap {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
  }
}

@media (max-width: 768px) {
  .pwa-cart-badge {
    position: absolute;
    top: -6px;
    right: -8px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    border-radius: 8px;
    background: var(--bs-primary);
    color: var(--bs-primary-bg-subtle);
    font-size: 9px;
    font-family: Anta, sans-serif;
    line-height: 16px;
    text-align: center;
    display: none;
  }
}

@media (max-width: 768px) {
  .pwa-cart-badge.has-items {
    display: block;
  }
}

/* Ensure the theme menu appears above the toolbar */

.pwa-toolbar .dropup .dropdown-menu {
  bottom: 100%;
  top: auto;
  margin-bottom: 15px;
  /*transform: translateX(-25%);*/
  z-index: 10000;
}

/* Fix icon sizing to match others exactly */

.btn-theme-trigger svg {
  width: 24px;
  height: 24px;
  stroke-width: 2.2;
}

/* Remove Bootstrap default button shadows */

.btn-theme-trigger:focus {
  box-shadow: none;
  outline: none;
}

/* 1. Stop the blue "tap" highlight on mobile */

.pwa-toolbar__btn, .btn-theme-trigger, .dropdown-item {
  /*-webkit-tap-highlight-color: transparent !important;*/
  /*outline: none !important;*/
  /*box-shadow: none !important;*/
}

/* 2. Style the theme trigger button to match others */

.btn-theme-trigger {
  background: none;
  border: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  padding: 0;
  font-family: inherit;
  font-size: inherit;
}

/* 3. Ensure the Dropup is positioned correctly */

.theme-switcher.dropup {
  position: relative;
}

.pwa-toolbar .dropdown-menu {
  bottom: 110% !important;
  top: auto !important;
  transform: translateX(-30%) !important;
  margin-bottom: 10px;
  border-radius: 12px;
  border: 1px solid var(--bs-border-color);
  box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

/* -----------------------------------------------
   THEME SWITCHER DROPDOWN — use theme vars, beat Bootstrap
   ----------------------------------------------- */

/* The dropdown items — default state */

.dropdown-item[data-bs-theme-value] {
  color: var(--bs-primary);
  background-color: transparent;
}

/* Hover state — subtle highlight, no Bootstrap blue takeover */

.dropdown-item[data-bs-theme-value]:hover, .dropdown-item[data-bs-theme-value]:focus {
  color: var(--bs-body-bg);
  background-color: var(--bs-body-color);
}

/* Active (selected theme) — use primary color only for the text, not a solid bg */

.dropdown-item[data-bs-theme-value].active, .dropdown-item[data-bs-theme-value]:active {
  color: var(--bs-border-color-translucent) !important;
  font-weight: 600;
}

