.drawer-open {
  overflow: hidden;
}

.drawer-layer {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgb(0 0 0 / 42%);
  display: flex;
  justify-content: flex-start;
}

.theme-drawer {
  width: min(480px, 100%);
  height: 100%;
  background: #fff;
  box-shadow: 15px 0 50px rgb(0 0 0 / 20%);
  overflow-y: auto;
  animation: drawer-in 0.25s ease both;
}

.drawer-head {
  height: 72px;
  padding: 0 20px;
  border-bottom: 1px solid #eee;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.drawer-head strong {
  font-size: 1.2rem;
}

.icon-action {
  position: relative;
  width: 44px;
  height: 44px;
  min-height: 44px;
  border: 0;
  background: transparent;
  display: grid;
  place-items: center;
  border-radius: 50%;
}

.icon-action:hover {
  background: #f3f3f3;
}

.icon-action svg {
  width: 22px;
  height: 22px;
}

.mobile-menu,
.drawer-search,
.drawer-cart {
  padding: 24px;
  display: grid;
  align-content: start;
  gap: 8px;
}

.mobile-menu > a,
.mobile-menu summary {
  min-height: 52px;
  display: flex;
  align-items: center;
  font-size: 1.12rem;
  font-weight: 700;
  border-bottom: 1px solid #eee;
}

.nested-menu {
  padding-inline: 16px;
}

.nested-menu a {
  display: flex;
  min-height: 44px;
  align-items: center;
}

.drawer-search label {
  font-size: 1.6rem;
  font-weight: 600;
}

.drawer-search input {
  width: 100%;
  border: 0;
  border-bottom: 1px solid #111;
  padding: 12px 4px;
  font-size: 1.1rem;
  min-height: 44px;
}

.search-results {
  display: grid;
}

.search-results a {
  display: flex;
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px solid #eee;
  align-items: center;
}

.search-results img,
.search-results__placeholder {
  width: 64px;
  height: 80px;
  object-fit: cover;
  background: #eee;
  flex-shrink: 0;
}

.search-results span {
  display: grid;
  gap: 4px;
}

.search-results small {
  color: #666;
}

.search-results a.is-oos img {
  opacity: 0.72;
}

.search-results__oos {
  color: #111;
  font-weight: 700;
}

.drawer-cart-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  padding: 16px 0;
  border-bottom: 1px solid #eee;
}

.drawer-cart-row div {
  display: grid;
  gap: 4px;
}

.drawer-cart-row small {
  color: #777;
}

.drawer-cart-row select {
  width: 68px;
  min-height: 44px;
}

.drawer-cart-row button {
  border: 0;
  background: transparent;
  text-decoration: underline;
  min-height: auto;
}

.drawer-total {
  display: flex;
  justify-content: space-between;
  padding: 20px 0;
}

.drawer-cart .btn-primary {
  width: 100%;
}

.text-link {
  text-align: center;
  text-decoration: underline;
}

.drawer-empty {
  min-height: 70vh;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 18px;
  text-align: center;
}

.drawer-empty svg {
  width: 42px;
}

.form-error {
  color: #9f1d1d;
}

.form-success {
  color: #176b3a;
}

.cart-upsell-slider__slide {
  width: min(158px, 42vw);
}

.cart-upsell-card a {
  color: inherit;
  text-decoration: none;
}

.cart-upsell-card a:hover {
  text-decoration: underline;
}

.cart-upsell-card__media {
  position: relative;
}

.cart-upsell-card__quick-add {
  position: absolute;
  inset-block-start: 0.4rem;
  inset-inline-end: 0.4rem;
  z-index: 2;
  width: 32px;
  height: 32px;
}

@keyframes drawer-in {
  from {
    transform: translateX(-100%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .theme-drawer {
    animation: none;
  }
}
