/* V265: mobile-only category navigation. One shared rule set for all four pages.
   Flexible header/nav rows replace the legacy 38px rows. Desktop/tablet untouched. */
@media (max-width: 650px) {
  body.gb-order-page > header.gb-order-header {
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: auto auto !important;
    grid-auto-rows: auto !important;
    align-items: start !important;
    align-content: start !important;
    row-gap: 12px !important;
    column-gap: 0 !important;
    padding: 10px 10px 12px !important;
  }

  body.gb-order-page > header.gb-order-header .gb-header-left {
    grid-column: 1 !important;
    grid-row: 1 !important;
    height: auto !important;
    min-height: 0 !important;
    align-self: start !important;
    margin: 0 !important;
  }

  body.gb-order-page > header.gb-order-header nav.order-page-nav {
    grid-column: 1 !important;
    grid-row: 2 !important;
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    grid-template-rows: repeat(2, minmax(48px, auto)) !important;
    grid-auto-rows: minmax(48px, auto) !important;
    align-items: stretch !important;
    align-self: start !important;
    align-content: start !important;
    justify-content: stretch !important;
    gap: 10px !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    padding: 0 !important;
    margin: 0 !important;
    overflow: visible !important;
    border: 0 !important;
    background: transparent !important;
  }

  body.gb-order-page > header.gb-order-header .order-page-link {
    box-sizing: border-box !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    align-self: stretch !important;
    min-width: 0 !important;
    width: 100% !important;
    height: auto !important;
    min-height: 48px !important;
    max-height: none !important;
    padding: 10px !important;
    margin: 0 !important;
    gap: 8px !important;
    border: 1.5px solid #dce4d3 !important;
    border-radius: 18px !important;
    background: #fff !important;
    color: #173225 !important;
    box-shadow: none !important;
    text-align: left !important;
    text-decoration: none !important;
    white-space: nowrap !important;
  }

  body.gb-order-page > header.gb-order-header .order-page-link .order-page-icon {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 26px !important;
    height: 26px !important;
    flex: 0 0 26px !important;
    color: #173225 !important;
  }

  body.gb-order-page > header.gb-order-header .order-page-link .order-page-icon svg {
    display: block !important;
    width: 26px !important;
    height: 26px !important;
    stroke: currentColor !important;
    stroke-width: 2.3 !important;
    fill: none !important;
  }

  body.gb-order-page > header.gb-order-header .order-page-link .order-page-label {
    display: block !important;
    min-width: 0 !important;
    font: 700 clamp(10px, 3.15vw, 12px)/1.2 Arial, Helvetica, sans-serif !important;
    letter-spacing: .015em !important;
    text-transform: uppercase !important;
    white-space: nowrap !important;
    color: #173225 !important;
    overflow: visible !important;
    text-overflow: clip !important;
  }

  /* Real text rather than generated-content labels; the desktop label stays intact. */
  body.gb-order-page > header.gb-order-header .order-page-label .gb-nav-desktop-label {
    display: none !important;
  }
  body.gb-order-page > header.gb-order-header .order-page-label .gb-nav-mobile-label[hidden] {
    display: inline !important;
  }

  body.gb-order-page > header.gb-order-header .order-page-link:hover {
    background: #f5f8f1 !important;
    border-color: #dce4d3 !important;
    color: #173225 !important;
  }
  body.gb-order-page > header.gb-order-header .order-page-link.active,
  body.gb-order-page > header.gb-order-header .order-page-link[aria-current="page"],
  body.gb-order-page > header.gb-order-header .order-page-link.active:hover,
  body.gb-order-page > header.gb-order-header .order-page-link[aria-current="page"]:hover {
    background: #dfe9d4 !important;
    border-color: #dfe9d4 !important;
    color: #173225 !important;
    box-shadow: none !important;
  }
  body.gb-order-page > header.gb-order-header .order-page-link::before,
  body.gb-order-page > header.gb-order-header .order-page-link::after,
  body.gb-order-page > header.gb-order-header .order-page-link .order-page-label::before,
  body.gb-order-page > header.gb-order-header .order-page-link .order-page-label::after {
    content: none !important;
  }
  body.gb-order-page > header.gb-order-header .order-page-link:focus-visible {
    outline: 2px solid #159447 !important;
    outline-offset: 3px !important;
  }
}


/* V1017: mobile-only universal Greenbeat logo alignment.
   Align the left edge of the wordmark with the visible left edge of the
   SALAD + GRAIN icon in the first category card. Desktop/tablet unchanged. */
@media (max-width: 650px) {
  body.gb-order-page > header.gb-order-header .logo {
    margin-left: 17.5px !important;
  }
}
