/* Functional header search and cart; same restrained white/black/orange system. */
.shop-cart-count { position: absolute; top: -1px; right: -2px; color: var(--orange); font-size: 11px; font-weight: 600; }
.shop-cart-count[hidden] { display: none; }
.header-search { position: relative; z-index: 10; }
.shop-search-results { padding-top: 15px; }
.shop-search-status { font-size: 13px; margin: 0 0 12px; }
#search-results { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; max-height: min(480px, 60svh); overflow: auto; padding: 4px; margin-inline: -4px; overscroll-behavior: contain; }
.shop-search-result { display: flex; align-items: center; gap: 16px; min-width: 0; min-height: 95px; background: #101010; border: 1px solid transparent; border-radius: 12px; padding: 14px; }
.shop-search-result:hover, .shop-search-result:focus-visible { border-color: var(--orange); }
.shop-result-photo { flex: 0 0 65px; width: 65px; padding: 8px; border-radius: 9px; background: #fff; color: var(--ink); }
.shop-result-photo .crop { background: #fff; }
.shop-placeholder { display: grid; place-items: center; height: 50px; }
.shop-result-copy { min-width: 0; flex: 1; }
.shop-result-copy strong { font-size: 15px; font-weight: 500; line-height: 1.4; overflow-wrap: anywhere; }
.shop-result-copy > span { display: block; margin-top: 5px; font-size: 12px; line-height: 1.5; }
.shop-result-price { font-size: 15px; white-space: nowrap; }
.shop-search-result > .icon { width: 18px; height: 18px; color: var(--orange); }
.shop-no-results { grid-column: 1 / -1; font-size: 14px; line-height: 1.8; margin: 0; padding: 12px 0; }
.shop-cart-dialog {
  position: fixed; inset: 0 0 0 auto; margin: 0; padding: 0; border: 0;
  width: min(510px, 100%); max-width: 100%; height: 100%; height: 100dvh; max-height: 100dvh;
  background: #fff; color: var(--ink); border-radius: 18px 0 0 18px;
  box-shadow: -20px 0 80px #0005; overflow: hidden; font-family: 'Barlow', sans-serif;
}
.shop-cart-dialog[open] { display: flex; flex-direction: column; }
.shop-cart-dialog::backdrop { background: #000b; }
.shop-cart-header { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 24px 28px 20px; flex: none; }
.shop-cart-header h2 { font-size: 28px; font-weight: 500; letter-spacing: -.6px; margin: 0; }
.shop-cart-header h2 span { font-size: 16px; letter-spacing: 0; }
.shop-close { width: 44px; height: 44px; flex: none; background: transparent; color: var(--ink); font-size: 31px; line-height: 1; border-radius: 9px; }
.shop-close:hover { color: var(--orange); }
.shop-cart-items { flex: 1; min-height: 0; padding: 0 28px; overflow-y: auto; overscroll-behavior: contain; }
.shop-cart-item { display: flex; align-items: start; gap: 21px; padding: 23px 0; }
.shop-cart-photo { width: 100px; flex: none; padding: 8px; background: #fff; }
.shop-cart-photo .crop { background: #fff; }
.shop-cart-info { min-width: 0; flex: 1; }
.shop-cart-info h3 { font-size: 19px; font-weight: 500; line-height: 1.35; letter-spacing: -.3px; margin: 0; overflow-wrap: anywhere; }
.shop-cart-info p { font-size: 13px; margin: 8px 0 12px; }
.shop-cart-info > strong { font-size: 22px; font-weight: 500; white-space: nowrap; }
.shop-cart-controls { display: flex; gap: 12px; justify-content: space-between; align-items: center; flex-wrap: wrap; margin-top: 17px; }
.shop-quantity { display: flex; align-items: center; gap: 12px; }
.shop-quantity button { width: 44px; height: 44px; border: 1px solid #17191b25; border-radius: 9px; background: #fff; color: var(--ink); font-size: 20px; }
.shop-quantity button:hover:not(:disabled) { border-color: var(--orange); }
.shop-quantity button:disabled { opacity: .35; cursor: default; }
.shop-quantity > span { min-width: 17px; text-align: center; font-size: 15px; }
.shop-remove { min-height: 44px; padding: 8px 0; background: none; color: var(--ink); font-size: 12px; text-decoration: underline; text-underline-offset: 4px; }
.shop-remove:hover { color: var(--orange); }
.shop-cart-footer { flex: none; padding: 24px 28px max(28px, env(safe-area-inset-bottom)); background: #fff; }
.shop-cart-footer[hidden] { display: none; }
.shop-cart-total { display: flex; justify-content: space-between; align-items: baseline; gap: 15px; }
.shop-cart-total > span { font-size: 15px; }
.shop-cart-total strong { font-size: 29px; font-weight: 500; letter-spacing: -.7px; white-space: nowrap; }
.shop-cart-footer > p { font-size: 12px; line-height: 1.6; margin: 12px 0 23px; }
.shop-button { display: flex; align-items: center; justify-content: space-between; gap: 18px; min-height: 52px; padding: 14px 18px; border-radius: 12px; background: var(--ink); color: #fff; font-size: 15px; font-weight: 500; line-height: 1.5; }
.shop-button:hover { background: var(--orange); }
.shop-button .icon { width: 19px; height: 19px; }
.shop-cart-empty { display: flex; flex-direction: column; align-items: stretch; padding: 48px 0 25px; }
.shop-cart-empty > .icon { width: 44px; height: 44px; margin-bottom: 28px; color: var(--orange); }
.shop-cart-empty h3 { font-size: 28px; font-weight: 500; letter-spacing: -.7px; margin: 0 0 12px; }
.shop-cart-empty p { font-size: 15px; line-height: 1.7; margin: 0 0 28px; }
.shop-text-link { display: inline-flex; align-items: center; min-height: 44px; margin-top: 12px; font-size: 14px; }
.shop-text-link:hover { color: var(--orange); }
#checkout-summary { min-width: 0; position: sticky; top: 24px; }
#checkout-summary .order-summary { position: static; }
.checkout-line { padding: 16px 0 20px; }
.checkout-line .order-item { margin: 0 0 14px; }
.checkout-line .shop-cart-controls { margin-top: 0; }
.checkout-line .shop-remove { font-size: 12px; }
.checkout-line .shop-quantity > span { font-size: 14px; }
@media (max-width: 1100px) {
  #checkout-summary { position: static; order: -1; }
  .shop-search-result { gap: 12px; }
}
@media (max-width: 700px) {
  #search-results { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 480px) {
  .shop-cart-dialog { border-radius: 0; }
  .shop-cart-header { padding: 18px 20px; }
  .shop-cart-items { padding-inline: 20px; }
  .shop-cart-item { gap: 14px; }
  .shop-cart-photo { width: 75px; padding: 4px; }
  .shop-cart-info h3 { font-size: 18px; }
  .shop-cart-footer { padding: 20px 20px max(22px, env(safe-area-inset-bottom)); }
  .shop-cart-total strong { font-size: 27px; }
  .shop-search-result { flex-wrap: wrap; padding: 12px; }
  .shop-result-photo { flex-basis: 53px; width: 53px; padding: 5px; }
  .shop-result-price { font-size: 13px; }
  .shop-search-result > .icon { display: none; }
}
