/* Six-item mobile navigation, matching the supplied rounded white reference. */
:root {
  --wst-mobile-nav-height: 66px;
  --wst-mobile-nav-safe-area: env(safe-area-inset-bottom, 0px);
}
.wst-mobile-bottom-nav,
.wst-mobile-bottom-spacer,
.wst-mobile-bottom-panel {
  display: none !important;
}
@media (max-width: 767px) {
  html {
    scroll-padding-bottom: calc(var(--wst-mobile-nav-height) + var(--wst-mobile-nav-safe-area) + 12px);
  }
  .wst-mobile-bottom-spacer {
    display: block !important;
    height: calc(var(--wst-mobile-nav-height) + var(--wst-mobile-nav-safe-area));
    width: 100%;
    flex: 0 0 auto;
  }
  .wst-mobile-bottom-nav {
    display: grid !important;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    position: fixed;
    inset: auto 0 0;
    z-index: 900;
    box-sizing: border-box;
    width: 100%;
    height: calc(var(--wst-mobile-nav-height) + var(--wst-mobile-nav-safe-area));
    margin: 0;
    padding: 6px 4px calc(6px + var(--wst-mobile-nav-safe-area));
    background: #fff;
    border: 1px solid #eeeae3;
    border-bottom: 0;
    border-radius: 18px 18px 0 0;
    box-shadow: 0 -3px 18px rgb(0 0 0 / 8%);
    color: #555;
    font-family: inherit;
  }
  .wst-mobile-bottom-nav .wst-mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-width: 0;
    min-height: 44px;
    width: auto;
    height: auto;
    margin: 0;
    padding: 3px 1px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #555;
    font: inherit;
    text-decoration: none;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
  }
  .wst-mobile-bottom-nav .wst-mobile-nav-item[aria-current="page"],
  .wst-mobile-bottom-nav .wst-mobile-nav-item[aria-expanded="true"],
  .wst-mobile-bottom-nav .wst-mobile-nav-item:hover {
    color: #005c50;
  }
  .wst-mobile-nav-icon {
    display: block;
    position: relative;
    width: 23px;
    height: 23px;
    flex: 0 0 23px;
  }
  .wst-mobile-nav-icon svg {
    display: block;
    width: 100%;
    height: 100%;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.45;
    stroke-linecap: round;
    stroke-linejoin: round;
  }
  .wst-mobile-nav-label {
    font-size: 10px;
    font-weight: 400;
    line-height: 1.2;
    white-space: nowrap;
  }
  .wst-mobile-cart-count {
    position: absolute;
    top: -5px;
    right: -9px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    min-width: 16px;
    height: 16px;
    padding: 0 3px;
    border-radius: 9px;
    background: #bc902f;
    color: #fff;
    font-size: 9px;
    font-weight: 600;
    line-height: 1;
  }
  .wst-mobile-cart-count[data-count="0"] { display: none; }
  .wst-mobile-bottom-panel[open] {
    display: block !important;
    position: fixed;
    inset: auto 12px calc(var(--wst-mobile-nav-height) + var(--wst-mobile-nav-safe-area) + 10px);
    box-sizing: border-box;
    width: auto;
    max-width: none;
    max-height: calc(100vh - var(--wst-mobile-nav-height) - var(--wst-mobile-nav-safe-area) - 34px);
    max-height: calc(100dvh - var(--wst-mobile-nav-height) - var(--wst-mobile-nav-safe-area) - 34px);
    overflow: auto;
    margin: 0;
    padding: 20px;
    border: 1px solid #eeeae3;
    border-radius: 18px;
    background: #fff;
    color: #005c50;
    font-family: inherit;
    box-shadow: 0 10px 40px rgb(0 0 0 / 18%);
  }
  .wst-mobile-bottom-panel::backdrop { background: rgb(0 0 0 / 35%); }
  body.wst-mobile-panel-open { overflow: hidden; }
  .wst-mobile-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
  }
  .wst-mobile-panel-header h2 { margin: 0; font-size: 20px; line-height: 1.3; }
  .wst-mobile-panel-header button {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: #f1eee8;
    color: #005c50;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
  }
  .wst-mobile-panel-menu,
  .wst-mobile-panel-menu ul { margin: 0; padding: 0; list-style: none; }
  .wst-mobile-panel-menu ul { padding-left: 16px; }
  .wst-mobile-panel-menu li { margin: 0; padding: 0; }
  .wst-mobile-panel-menu a {
    display: block;
    padding: 12px 0;
    border-bottom: 1px solid #eeeae3;
    color: #005c50;
    font-size: 15px;
    line-height: 1.4;
    text-decoration: none;
  }
  .wst-mobile-bottom-panel .woocommerce-product-search { display: flex; flex-wrap: wrap; gap: 10px; }
  .wst-mobile-bottom-panel input[type="search"] {
    box-sizing: border-box;
    flex: 1 1 180px;
    min-width: 0;
    max-width: 100%;
    padding: 12px;
    border: 1px solid #d4d0c8;
    border-radius: 8px;
    background: #fff;
    color: #222;
    font: inherit;
    font-size: 16px;
  }
  .wst-mobile-bottom-panel .woocommerce-product-search button {
    min-height: 44px;
    padding: 10px 16px;
    border: 0;
    border-radius: 8px;
    background: #005c50;
    color: #fff;
    font: inherit;
    cursor: pointer;
  }
  .wst-mobile-bottom-nav :focus-visible,
  .wst-mobile-bottom-panel :focus-visible { outline: 2px solid #005c50; outline-offset: 2px; }
  /*
   * Oxygen off-canvas drawers (cart, menu) sit in a lower stacking context,
   * so the fixed nav would cover their footer (e.g. the Checkout button).
   * Slide the nav away while any off-canvas drawer is open.
   */
  .wst-mobile-bottom-nav {
    transition: transform 0.25s ease, visibility 0.25s;
  }
  body:has([id*="off-canvas"][id$="-inner"][aria-hidden="false"]) .wst-mobile-bottom-nav,
  body:has(.sticky-cart[aria-expanded="true"]) .wst-mobile-bottom-nav {
    transform: translateY(100%);
    visibility: hidden;
    pointer-events: none;
  }
}
