@media (max-width: 650px) {
  /* Profile, the shopping list and the catalog are reachable from the bottom navigation. */
  .hdr .topbar .hdr__actions { display: none; }
  .saved-page[data-saved-page] .hdr .topbar { display: block; }
  .hdr .topbar__in { display: block; min-height: 0; padding-block: 0; }
  .hdr .topbar__links {
    width: min(100%, 460px);
    margin-inline: auto;
    flex-wrap: nowrap;
    align-items: stretch;
    justify-content: space-between;
    gap: 8px;
    color: #56534e;
    font-size: clamp(11px, 3.1vw, 13px);
    font-weight: 600;
    line-height: 1.25;
  }
  .hdr .topbar__links > * { display: flex; align-items: center; min-height: 44px; }
  .hdr .topbar__links :focus-visible { outline: 2px solid #25211c; outline-offset: -2px; }

  .hdr .masthead .catalog-btn, .hdr .masthead .hdr__nav { display: none; }
  .hdr .masthead .masthead__content { grid-template-columns: minmax(0,1fr); }
  .hdr .masthead .search { grid-column: 1 / -1; width: 100%; }
  .hdr .search { -webkit-tap-highlight-color: transparent; }
  .hdr .search:focus-within { outline: 2px solid #1a1a1a; outline-offset: 0; }
  .hdr .search input { font-size: 16px; }
  .hdr .search input:focus { outline: none; }
  .hdr .search__btn:focus-visible { outline: 2px solid #1a1a1a; outline-offset: -3px; }

  .home-page .hdr--home .masthead { padding-bottom: 5px; }
  .home-page .hdr--home .masthead::after {
    top: calc(100% - 1px);
    bottom: auto;
    height: 12px;
    z-index: 1;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='12' viewBox='0 0 48 12'%3E%3Cpath d='M0 0h48v6Q36 17 24 6T0 6Z' fill='%23ffe600'/%3E%3C/svg%3E") repeat-x top;
  }

  .bnav {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr minmax(76px,1.2fr) 1fr;
    align-items: stretch;
    column-gap: 2px;
    padding: 3px max(3px, env(safe-area-inset-right)) calc(4px + env(safe-area-inset-bottom)) max(3px, env(safe-area-inset-left));
  }
  .bnav > :is(a, button) {
    display: grid;
    grid-template-rows: 34px auto;
    justify-items: center;
    align-content: center;
    align-items: center;
    gap: 1px;
    min-height: 56px;
    padding: 2px 0;
    border-radius: 6px;
    color: #55524d;
    font-size: clamp(10px, 2.7vw, 12px);
    font-weight: 650;
    line-height: 1.12;
    text-align: center;
  }
  .bnav > .on { color: #171410; font-weight: 800; }
  .bnav > :focus-visible { outline: 2px solid #1a1a1a; outline-offset: -2px; }
  .bnav svg { width: 22px; height: 22px; }
  .bnav .bnav__rc .bubble {
    width: 34px;
    height: 34px;
    margin: 0;
    border-width: 1.5px;
    box-shadow: none;
  }
  .bnav .bubble > .rc-die { width: 25px; height: 25px; }
  .bnav .bnav__shopping { grid-template-columns: minmax(0,1fr); }
  .bnav__shopping > svg {
    grid-area: 1 / 1;
    align-self: end;
    width: 26px; height: 26px;
  }
  .bnav__shopping .sum {
    position: static;
    grid-area: 1 / 1;
    align-self: start;
    justify-self: center;
    max-width: 100%;
    margin: -1px 0 0 4px;
    padding: 2px 4px;
    border: 1px solid #fff;
    background: var(--orange);
    color: #201812;
    font-size: 10px;
    font-weight: 800;
    line-height: 1;
    font-variant-numeric: tabular-nums;
  }
  /* Commerce pages hide [hidden] with !important. Reveal only the visual mobile sum. */
  .bnav__shopping .sum [data-cart-sum="compact"][hidden] { display: inline !important; }
  .bnav__shopping .sum [data-cart-sum=""] {
    position: absolute; width: 1px; height: 1px; padding: 0;
    overflow: hidden; clip-path: inset(50%); white-space: nowrap;
  }

  body:has(> .bnav) { padding-bottom: 0; }
  .footer { margin-top: 20px; border-top: 0; }
  .footer .wrap { padding: 12px 16px calc(66px + env(safe-area-inset-bottom)); }
  .footer__main { display: block; }
  .footer__brand { display: flex; align-items: center; gap: 16px; padding-bottom: 8px; }
  .footer__brand .logo { display: flex; align-items: center; min-height: 44px; }
  .footer__brand .logo img { width: 104px; }
  .footer__brand p { margin: 0; font-size: 12px; line-height: 1.35; }
  .footer__group { border-top: 1px solid #514f46; }
  .footer__disclosure > summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 44px;
    padding-right: 5px;
    list-style: none;
    cursor: pointer;
  }
  .footer__disclosure > summary::-webkit-details-marker { display: none; }
  .footer__disclosure > summary::after {
    content: "";
    width: 8px;
    height: 8px;
    border: solid currentColor;
    border-width: 0 1.5px 1.5px 0;
    transform: translateY(-2px) rotate(45deg);
  }
  .footer__disclosure[open] > summary::after { transform: translateY(2px) rotate(225deg); }
  .footer__group h2 { margin: 0; font-size: 15px; }
  .footer .footer__disclosure ul {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 14px;
    padding-bottom: 4px;
  }
  .footer__group li :is(a, button) {
    display: flex;
    width: 100%;
    min-height: 44px;
    align-items: center;
    padding-block: 4px;
    font-size: 13px;
  }
  .footer :focus-visible { outline-offset: -2px; }
  .footer__meta { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); column-gap: 8px; margin: 0; padding: 0; }
}
@media (max-width: 650px) {
  .bnav .bnav__rc .bubble { width: 45px; height: 45px; align-self: end; margin-bottom: 1px; }
  .bnav .bnav__rc .rc-die { width: 33px; height: 33px; }
  .pcard .stock-note, .home-shelf .stock-note, .home-spotlight-stock { display: none; }
  .carousel > .pcard--selectable, #grid > .pcard--selectable, .home-shelf .carousel > .pcard--selectable {
    display: grid; align-self: stretch; grid-row: auto; grid-template-rows: auto 1fr auto; align-items: start;
  }
  .home-shelf .carousel { grid-template-rows: auto; }
  .home-shelf .carousel > .pcard > .pcard__body { grid-row: 2; display: flex; flex-direction: column; }
  .carousel > .pcard--selectable > [data-add], #grid > .pcard--selectable > [data-add] { grid-row: 3; align-self: end; }
  main:has(.product) > .side-open-btn { display: grid; place-items: center; width: 44px; height: 44px; padding: 0; }
  main:has(.product) > .side-open-btn .filter-symbol { display: block; width: 22px; height: 22px; }
  main:has(.product) .filter-label, .layout:has(.product) > #side :is(.scats,[data-rc],.side-catalog-prefix) { display: none; }
  .side__head b { text-transform: capitalize; }
}
