/* ============================================================================
   Storefront v2 layer (site.css). Loaded after style.css + shop.css on every
   page: compact header, rounded image wells, pill controls, catalog toolbar,
   product page polish and the mobile buy bar. Home-only pieces live in home.css.
   ========================================================================== */
:root {
  --v2-ink: #111111;
  --v2-mute: #6a6a6a;
  --v2-well: #f4f4f2;
  --v2-line: #e8e8e5;
}

/* ── Top bar ── */
.topbar-inner { padding-top: 6px; padding-bottom: 6px; }
#rate-display { white-space: nowrap; }
.topbar-tools .currency-select { border-radius: 999px; padding: 3px 10px; }

/* ── Header: one compact row + nav ── */
.site-header { background: rgba(255,255,255,.88); border-bottom-color: var(--v2-line); }
.header-inner { padding-top: 10px; padding-bottom: 10px; gap: 24px; }
.site-header .header-logo img { height: 54px !important; width: auto !important; }
.header-search {
  border: 0; border-radius: 999px; background: var(--v2-well); padding: 0 18px; height: 44px; max-width: 460px;
  transition: background .15s, box-shadow .15s;
}
.header-search:focus-within { background: #fff; box-shadow: 0 0 0 1.5px var(--v2-ink); }
.b2b-pill { border-radius: 999px !important; }
.cart-btn { border-radius: 999px; padding: 11px 18px; }
.cart-btn .cart-badge { border-radius: 999px; }
.cat-nav { border-bottom: 0; background: transparent; }
.cat-nav-inner { gap: 2px; padding-bottom: 8px; }
.cat-link { padding: 8px 14px; border-bottom: 0; border-radius: 999px; font-size: 14px; }
.cat-link:hover { background: var(--v2-well); color: var(--v2-ink); }
.cat-link.active { background: var(--v2-ink); color: #fff; }
.cat-link.accent:not(.active) { color: var(--v2-ink); }
@media (max-width: 860px) {
  .header-inner { padding-top: 8px; padding-bottom: 8px; }
  .site-header .header-logo img { height: 44px !important; width: auto !important; }
}

/* ── Buttons ── */
.btn-shop, .btn-brand, .btn-outline2 { border-radius: 999px; }
.btn-add { border-radius: 999px; }
.qty-stepper { border-radius: 999px; overflow: hidden; }
.mnav-search { border-radius: 999px; border: 0; background: var(--v2-well); }

/* ── Product cards everywhere ── */
.pcard-imgwrap { border-radius: 18px; background: var(--v2-well); }
.pcard-imgwrap img { mix-blend-mode: multiply; padding: 6px; }
.pcard:hover { transform: none; }
.pbadge { border-radius: 999px; padding: 5px 10px; }
.pcard-body { padding: 14px 4px 4px; }

/* ── Catalog ── */
.cat2-head { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; margin-bottom: 14px; }
.cat2-head .collection-count { margin: 0; }
.cat2-tabs { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 0 0 14px; padding-bottom: 2px; }
.cat2-tabs::-webkit-scrollbar { display: none; }
.cat2-tab {
  flex-shrink: 0; height: 38px; padding: 0 16px; display: inline-flex; align-items: center; border-radius: 999px;
  background: var(--v2-well); color: var(--v2-ink); font-size: 14px; font-weight: 600; text-decoration: none; white-space: nowrap;
}
.cat2-tab:hover { background: #ebebe7; }
.cat2-tab.on { background: var(--v2-ink); color: #fff; }
.cat2-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  padding: 14px 0; margin-bottom: 22px; border-top: 1px solid var(--v2-line); border-bottom: 1px solid var(--v2-line);
}
.cat2-pills { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.cat2-pill {
  height: 36px; padding: 0 14px; display: inline-flex; align-items: center; gap: 6px; border-radius: 999px;
  border: 1.5px solid var(--v2-line); background: #fff; font-size: 13.5px; font-weight: 600; cursor: pointer; user-select: none;
  list-style: none;
}
.cat2-pill::-webkit-details-marker { display: none; }
.cat2-pill input { position: absolute; opacity: 0; pointer-events: none; }
.cat2-pill small { font-size: 12px; color: var(--v2-mute); font-weight: 500; }
.cat2-pill:hover { border-color: #c9c9c4; }
.cat2-pill.on { border-color: var(--v2-ink); background: var(--v2-ink); color: #fff; }
.cat2-pill.on small { color: rgba(255,255,255,.7); }
.cat2-pill svg { width: 15px; height: 15px; }
.cat2-price { position: relative; }
.cat2-pop {
  position: absolute; top: calc(100% + 8px); left: 0; z-index: 20; width: 270px; padding: 16px; border-radius: 16px;
  background: #fff; box-shadow: 0 12px 40px rgba(0,0,0,.14); display: flex; flex-direction: column; gap: 12px;
}
.cat2-pop .price-range { display: flex; align-items: center; gap: 8px; }
.cat2-pop .price-range input { width: 100%; height: 40px; border: 1.5px solid var(--v2-line); border-radius: 10px; padding: 0 10px; font: inherit; font-size: 14px; }
.cat2-pop-actions { display: flex; gap: 8px; }
.cat2-pop-actions .btn { flex: 1; padding: 9px 12px; font-size: 13px; }
.cat2-sort { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--v2-mute); }
.cat2-sort select, .cat2 .sort-select {
  height: 36px; border-radius: 999px; border: 1.5px solid var(--v2-line); padding: 0 32px 0 14px; font: inherit; font-size: 13.5px;
  font-weight: 600; color: var(--v2-ink); background: #fff; cursor: pointer;
}
.cat2 .product-grid2 { gap: 32px 20px; }
.pagination a, .pagination span { border-radius: 999px; min-width: 40px; }
@media (max-width: 620px) {
  .cat2-bar { padding: 10px 0; gap: 10px; }
  .cat2-pills { flex-wrap: nowrap; overflow-x: visible; }
  .cat2-sort span { display: none; }
  .cat2-pop { width: min(300px, calc(100vw - 36px)); }
  .cat2 .product-grid2 { gap: 26px 12px; }
}

/* ── Product page ── */
.pdp2 .pdp-grid { max-width: 1180px; gap: 56px; }
.pdp2-gallery { position: sticky; top: 140px; }
.pdp2-main { border-radius: 24px; }
.pdp2-thumbs { display: flex; gap: 10px; margin-top: 12px; flex-wrap: wrap; }
.pdp2-thumb {
  width: 68px; height: 68px; object-fit: contain; border-radius: 12px; background: var(--v2-well); padding: 4px;
  cursor: pointer; mix-blend-mode: multiply; outline: 2px solid transparent; outline-offset: 2px; transition: outline-color .15s;
}
.pdp2-thumb:hover { outline-color: #c9c9c4; }
.pdp2-thumb.on { outline-color: var(--v2-ink); }
.pdp2-info h1 { font-weight: 700 !important; letter-spacing: -0.035em !important; font-size: clamp(26px, 3.2vw, 38px) !important; }
.pdp2-info .qty-stepper { height: 52px !important; }
.pdp2-info .cart-form .btn-shop { height: 52px; font-size: 16px !important; }
.pdp2-assure { list-style: none; margin: 8px 0 0; padding: 18px 0 0; border-top: 1px solid var(--v2-line); display: grid; gap: 14px; }
.pdp2-assure li { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; line-height: 1.5; color: var(--v2-mute); }
.pdp2-assure li b { color: var(--v2-ink); font-weight: 600; }
.pdp2-assure svg { width: 20px; height: 20px; flex-shrink: 0; color: var(--v2-ink); margin-top: 1px; }
.pdp2-bar { display: none; }
@media (max-width: 820px) {
  .pdp2 .pdp-grid { gap: 22px; }
  .pdp2-gallery { position: static; }
  .pdp2-main { border-radius: 20px; }
  .pdp2-bar {
    display: flex; position: fixed; left: 10px; right: 10px; bottom: calc(10px + env(safe-area-inset-bottom)); z-index: 60;
    align-items: center; gap: 12px; padding: 10px 10px 10px 18px; border-radius: 999px;
    background: rgba(17,17,17,.94); color: #fff; box-shadow: 0 10px 30px rgba(0,0,0,.25);
    transform: translateY(140%); transition: transform .3s cubic-bezier(.2,.7,.2,1);
  }
  .pdp2-bar.on { transform: none; }
  .pdp2-bar-info { flex: 1; min-width: 0; }
  .pdp2-bar-name { font-size: 12.5px; color: rgba(255,255,255,.7); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .pdp2-bar-price { font-size: 16px; font-weight: 700; }
  .pdp2-bar-btn { height: 44px; padding: 0 20px; border-radius: 999px; border: 0; background: #fff; color: var(--v2-ink); font: inherit; font-size: 14.5px; font-weight: 700; cursor: pointer; white-space: nowrap; }
}
@media (prefers-reduced-motion: reduce) { .pdp2-bar { transition: none; } }

/* the header already lists the categories on desktop; the pill tabs are for phones */
@media (min-width: 861px) { .cat2-tabs { display: none; } }
@media (max-width: 620px) {
  .cat2-bar { flex-wrap: nowrap; }
  .cat2-pills { flex: 1; min-width: 0; }
  .cat2-sort select { max-width: 120px; padding-right: 26px; }
}

/* Hover shows the second picture: fade the first one out so the two never
   blend into each other (both are multiplied onto the grey well). */
.pcard-img-main { transition: opacity .3s ease, transform .4s cubic-bezier(.2,.7,.2,1); }
.pcard:hover .pcard-imgwrap:has(.pcard-img-alt) .pcard-img-main { opacity: 0; }
.pcard:hover .pcard-imgwrap img { transform: none; }
@media (hover: none) { .pcard-img-alt { display: none; } }

/* ── Cart page ── */
.cart2 { max-width: 1160px; }
.cart2-grid { display: grid; grid-template-columns: minmax(0,1fr) 380px; gap: 48px; align-items: start; }
.cart2-ship { padding: 16px 18px; border-radius: 16px; background: var(--v2-well); margin-bottom: 8px; }
.cart2-ship-msg { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--v2-mute); }
.cart2-ship-msg b { color: var(--v2-ink); }
.cart2-ship-msg svg { width: 18px; height: 18px; color: var(--v2-ink); flex-shrink: 0; }
.cart2-ship-track { height: 6px; border-radius: 6px; background: #e2e2de; margin-top: 12px; overflow: hidden; }
.cart2-ship-track span { display: block; height: 100%; border-radius: 6px; background: var(--v2-ink); transition: width .4s ease; }
.cart2-ship.done .cart2-ship-track span { background: #2f7a45; }
.cart2-list { list-style: none; margin: 0; padding: 0; }
.cart2-item { display: grid; grid-template-columns: 112px minmax(0,1fr) auto; gap: 20px; align-items: start; padding: 22px 0; border-bottom: 1px solid var(--v2-line); }
.cart2-img { display: block; width: 112px; height: 112px; border-radius: 16px; background: var(--v2-well); overflow: hidden; }
.cart2-img img { width: 100%; height: 100%; object-fit: contain; padding: 8px; mix-blend-mode: multiply; }
.cart2-info { min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.cart2-name { color: var(--v2-ink); font-weight: 600; font-size: 15.5px; line-height: 1.4; text-decoration: none; }
.cart2-name:hover { text-decoration: underline; }
.cart2-each { font-size: 13.5px; color: var(--v2-mute); }
.cart2-each .price-converted { color: #9a9a9a; }
.cart2-row { display: flex; align-items: center; gap: 16px; margin-top: 8px; }
.cart2-qty { display: inline-flex; align-items: center; height: 40px; border: 1.5px solid var(--v2-line); border-radius: 999px; overflow: hidden; }
.cart2-qty form { display: flex; }
.cart2-qty button { width: 40px; height: 38px; border: 0; background: none; font: inherit; font-size: 17px; color: var(--v2-mute); cursor: pointer; }
.cart2-qty button:hover { color: var(--v2-ink); background: var(--v2-well); }
.cart2-qty span { min-width: 30px; text-align: center; font-weight: 600; font-size: 14.5px; }
.cart2-remove { border: 0; background: none; padding: 0; font: inherit; font-size: 13px; color: var(--v2-mute); text-decoration: underline; cursor: pointer; }
.cart2-remove:hover { color: var(--v2-ink); }
.cart2-sub { font-weight: 700; font-size: 16px; white-space: nowrap; padding-top: 2px; }
.cart2-back { display: inline-flex; align-items: center; gap: 6px; margin-top: 22px; font-size: 14px; font-weight: 600; color: var(--v2-ink); text-decoration: none; }
.cart2-back svg { width: 16px; height: 16px; }
.cart2-sum { position: sticky; top: 130px; padding: 26px 24px; border-radius: 22px; background: var(--v2-well); }
.cart2-sum h2 { margin: 0 0 16px; font-size: 19px; font-weight: 700; letter-spacing: -0.02em; }
.cart2-line { display: flex; justify-content: space-between; padding: 6px 0; font-size: 14px; color: var(--v2-mute); }
.cart2-line > span:last-child { color: var(--v2-ink); font-weight: 600; }
.cart2-line .cart2-note { color: var(--v2-mute) !important; font-weight: 500 !important; }
.cart2-total { display: flex; justify-content: space-between; align-items: baseline; margin-top: 10px; padding-top: 14px; border-top: 1px solid #deded9; font-weight: 700; font-size: 15px; }
.cart2-total > span:last-child { text-align: right; }
.cart2-total b { display: block; font-size: 26px; letter-spacing: -0.03em; }
.cart2-total small { display: block; font-size: 12.5px; color: var(--v2-mute); font-weight: 500; }
.cart2-fine { font-size: 12px; color: var(--v2-mute); line-height: 1.6; margin: 8px 0 0; }
.cart2-fine.center { text-align: center; }
.cart2-go { display: flex !important; align-items: center; justify-content: center; width: 100%; height: 54px; margin-top: 18px; font-size: 16px !important; padding: 0 !important; }
.cart2-off { margin-top: 18px; padding: 14px; border-radius: 14px; background: #fff; font-size: 13px; color: var(--v2-mute); line-height: 1.7; }
.cart2-assure { list-style: none; margin: 18px 0 0; padding: 16px 0 0; border-top: 1px solid #deded9; display: grid; gap: 10px; }
.cart2-assure li { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--v2-mute); }
.cart2-assure svg { width: 17px; height: 17px; color: var(--v2-ink); }
.cart2-pay { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 14px; }
.cart2-pay img { height: 22px; width: auto; }
.cart2-empty { text-align: center; padding: 80px 20px; border-top: 1px solid var(--v2-line); }
.cart2-empty svg { width: 44px; height: 44px; color: #b5b5b0; }
.cart2-empty p { color: var(--v2-mute); font-size: 15px; margin: 14px 0 20px; }
@media (max-width: 860px) {
  .cart2-grid { grid-template-columns: 1fr; gap: 28px; }
  .cart2-sum { position: static; }
  .cart2-item { grid-template-columns: 84px minmax(0,1fr); gap: 14px; }
  .cart2-img { width: 84px; height: 84px; border-radius: 14px; }
  .cart2-sub { grid-column: 2; padding-top: 0; }
}
