/* Base shell - only shows on small screens by default */
.pgm-mnav-shell {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.material-symbols-outlined {
  font-variation-settings: 'FILL' 0, 'wght' 300, 'GRAD' 0, 'opsz' 24;
}

/* Header */
.pgm-mnav-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 56px;
  padding: 0 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: #ffffff;
  border-bottom: 1px solid #e3e3e3;
  z-index: 9999;
  transition: background-color 0.18s ease-out, border-color 0.18s ease-out, height 0.18s ease-out;
}

.pgm-mnav-header-left,
.pgm-mnav-header-right,
.pgm-mnav-header-center {
  display: flex;
  align-items: center;
  gap: 8px;
}

.pgm-mnav-header-left {
  justify-content: flex-start;
}

.pgm-mnav-header-center {
  flex: 1;
  justify-content: center;
}

.pgm-mnav-header-right {
  justify-content: flex-end;
}

.pgm-mnav-logo {
  display: flex;
  align-items: center;
  max-height: 32px;
}

.pgm-mnav-logo img {
  max-height: 28px;
  width: auto;
}

.pgm-mnav-logo-text {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.pgm-mnav-icon-btn {
  border: none;
  background: transparent;
  padding: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
}

.pgm-mnav-icon-btn .material-symbols-outlined {
  font-size: 22px;
}

.pgm-mnav-cart-link {
  position: relative;
}

.pgm-mnav-cart-count {
  position: absolute;
  top: 1px;
  right: 0;
  min-width: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background-color: #d32f2f;
  color: #ffffff;
  font-size: 10px;
  line-height: 16px;
  text-align: center;
}

/* Search bar (removed in current layout, styles kept for compatibility) */

/* Drawer (hamburger menu) */
.pgm-mnav-drawer {
  position: fixed;
  top: 56px;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.18s ease-out;
  z-index: 9998;
}

.pgm-mnav-drawer.is-open {
  pointer-events: auto;
  opacity: 1;
}

.pgm-mnav-drawer-backdrop {
  flex: 1;
  background-color: rgba(0, 0, 0, 0.18);
}

.pgm-mnav-drawer-panel {
  width: 260px;
  max-width: 80%;
  background-color: #ffffff;
  border-right: 1px solid #e3e3e3;
  padding: 8px 0;
  overflow-y: auto;
}

.pgm-mnav-drawer-menu {
  list-style: none;
  margin: 0;
  padding: 0;
}

.pgm-mnav-drawer-menu li a {
  display: block;
  padding: 10px 16px;
  text-decoration: none;
  color: #111111;
  font-size: 14px;
}

.pgm-mnav-drawer-menu li a:hover {
  background-color: #f5f5f5;
}

/* Bottom navigation */
.pgm-mnav-bottom {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 56px;
  border-top: 1px solid #e3e3e3;
  background-color: #ffffff;
  display: flex;
  justify-content: space-around;
  align-items: center;
  z-index: 9999;
  transition: background-color 0.18s ease-out, border-color 0.18s ease-out, height 0.18s ease-out;
}

.pgm-mnav-bottom-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  text-decoration: none;
  color: #8b8f9a;
  background: transparent;
  border: none;
  transition: color 0.18s ease-out;
}

.pgm-mnav-bottom-item .material-symbols-outlined {
  font-size: 22px;
  margin-bottom: 2px;
}

.pgm-mnav-bottom-item.is-active {
  color: #000000;
}

.pgm-mnav-bottom-item.is-active .material-symbols-outlined {
  font-variation-settings: 'FILL' 1, 'wght' 400, 'GRAD' 0, 'opsz' 24;
}

/* Compact variant: slightly shorter header and bottom bar */
.pgm-mnav-variant-compact .pgm-mnav-header {
  height: 48px;
}

.pgm-mnav-variant-compact .pgm-mnav-bottom {
  height: 48px;
}

.pgm-mnav-variant-compact .pgm-mnav-bottom-item {
  font-size: 9px;
}

.pgm-mnav-bottom-cart-count {
  position: absolute;
  top: 4px;
  right: 18px;
  min-width: 14px;
  padding: 0 3px;
  border-radius: 999px;
  background-color: #d32f2f;
  color: #ffffff;
  font-size: 9px;
  line-height: 14px;
  text-align: center;
}

/* App-like overlay: on mobile, hide the theme's own header/footer */
@media (max-width: 767px) {
  body.pgm-mnav-overlay header,
  body.pgm-mnav-overlay footer,
  body.pgm-mnav-overlay .site-header,
  body.pgm-mnav-overlay .site-footer,
  body.pgm-mnav-overlay #masthead,
  body.pgm-mnav-overlay #colophon {
    display: none !important;
  }

  body.pgm-mnav-overlay {
    padding-top: 56px;  /* space for plugin header */
    padding-bottom: 56px; /* space for bottom nav */
  }
}

/* Adjust overlay spacing for compact variant */
@media (max-width: 767px) {
  body.pgm-mnav-overlay .pgm-mnav-variant-compact ~ * {
    /* no-op selector placeholder to keep specificity low */
  }

  body.pgm-mnav-overlay.pgm-mnav-compact-spacing {
    padding-top: 48px;
    padding-bottom: 48px;
  }
}
