/* Herbawell — KOSZYK (strona /koszyk/ + mini-koszyk drawer). 1:1 z makietą Premium.
   Zasady styleguide: zero zaokrągleń/cieni, linie 1px var(--hw-line), Jost, ceny „118,99 zł". */

/* ---------- Wspólne ---------- */
.hw-cart { padding: 26px 56px 90px; }
.hw-crumbs {
  display: flex; align-items: center; gap: 8px;
  font-size: 10px; font-weight: 700; letter-spacing: .11em; text-transform: uppercase;
  color: var(--hw-text-muted);
}
.hw-crumbs a { color: var(--hw-text-muted); text-decoration: none; }
.hw-crumbs a:hover { color: var(--hw-green); }
.hw-crumbs__cur { color: var(--hw-green); }

.hw-cart__head {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 30px;
  padding: 34px 0 26px; border-bottom: 1px solid rgba(16,38,28,.14);
}
.hw-cart__title {
  margin: 0; font-family: var(--hw-font); font-size: 56px; font-weight: 500;
  letter-spacing: -.02em; color: var(--hw-green); line-height: 1;
}
.hw-cart__count {
  font-size: 10px; font-weight: 700; letter-spacing: .11em; text-transform: uppercase;
  color: var(--hw-text-muted); white-space: nowrap;
}

/* ---------- Siatka: pozycje + podsumowanie ---------- */
.hw-cart__grid {
  display: grid; grid-template-columns: minmax(0,1fr) 380px; gap: 56px;
  padding: 36px 0 0; align-items: start;
}
.hw-cart__main { display: flex; flex-direction: column; min-width: 0; }
.hw-cart__form { display: flex; flex-direction: column; }

.hw-cart__row {
  display: grid; grid-template-columns: 96px minmax(0,1fr) auto; gap: 24px;
  padding: 24px 0; border-bottom: 1px solid var(--hw-line); align-items: center;
}
.hw-cart__thumb { aspect-ratio: 4/5; background: var(--hw-sage); overflow: hidden; }
.hw-cart__thumb img { width: 100%; height: 100%; object-fit: contain; mix-blend-mode: multiply; }
.hw-cart__thumb-ph { display: block; width: 100%; height: 100%; background: var(--hw-tint-1); }

.hw-cart__info { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.hw-cart__name {
  font-family: var(--hw-font); font-size: 22px; font-weight: 500; color: var(--hw-green); line-height: 1.15;
}
.hw-cart__name a { color: inherit; text-decoration: none; }
.hw-cart__name a:hover { color: var(--hw-brass-dark); }
.hw-cart__variant { font-size: 12.5px; color: #6B7A70; }
.hw-cart__variant .wc-item-meta { list-style: none; margin: 0; padding: 0; }
.hw-cart__variant .wc-item-meta p { margin: 0; }
.hw-cart__avail {
  font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--hw-brass-dark);
}

.hw-cart__controls { display: flex; align-items: center; gap: 16px; margin-top: 4px; flex-wrap: wrap; }
.hw-cart__unit { font-size: 12px; color: var(--hw-text-muted); }
.hw-cart__remove {
  border: 0; background: transparent; font-family: inherit; font-size: 10px; font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase; color: var(--hw-text-muted); cursor: pointer; text-decoration: none;
}
.hw-cart__remove:hover { color: var(--hw-green); }
.hw-cart__line {
  font-family: var(--hw-font); font-size: 26px; font-weight: 500; color: var(--hw-green); white-space: nowrap;
}

/* Ilość — makieta: obwódka 1px, przyciski 38px */
.hw-qty { display: inline-flex; align-items: center; border: 1px solid rgba(16,38,28,.2); }
.hw-qty__btn {
  width: 38px; height: 38px; border: 0; background: transparent; color: var(--hw-green);
  font-size: 16px; line-height: 1; cursor: pointer; display: inline-flex; align-items: center; justify-content: center;
}
.hw-qty__btn:hover { background: var(--hw-bone-dark); }
.hw-qty .qty {
  width: 46px; min-width: 46px; text-align: center; border: 0; background: transparent;
  font-family: inherit; font-size: 14px; font-weight: 600; color: var(--hw-green);
  -moz-appearance: textfield; appearance: textfield;
}
.hw-qty .qty::-webkit-outer-spin-button,
.hw-qty .qty::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.hw-qty__val { min-width: 26px; text-align: center; font-size: 14px; font-weight: 600; color: var(--hw-green); }

/* ukryty natywny przycisk aktualizacji — zmiana ilości leci JS-em (auto-update) */
.hw-cart__actions-row { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* Promo zestawu */
.hw-cart__bundle {
  display: flex; align-items: center; gap: 24px; margin-top: 28px; padding: 26px; background: var(--hw-bone-dark);
}
.hw-cart__bundle-ph {
  width: 64px; height: 80px; flex: 0 0 64px;
  background: repeating-linear-gradient(45deg,#E2E4DA 0 8px,#EAEBE3 8px 16px);
}
.hw-cart__bundle-body { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.hw-cart__bundle-title { font-family: var(--hw-font); font-size: 20px; font-weight: 500; color: var(--hw-green); }
.hw-cart__bundle-text { font-size: 13px; color: var(--hw-text-soft); }
.hw-cart__bundle-cta { margin-left: auto; white-space: nowrap; padding: 0 24px; height: 52px; }

/* Podsumowanie (sticky) */
.hw-cart__aside { min-width: 0; }
.hw-summary {
  display: flex; flex-direction: column; padding: 30px; border: 1px solid rgba(16,38,28,.16);
  position: sticky; top: 92px;
}
.hw-summary__label {
  font-size: 10px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--hw-brass-dark);
  padding-bottom: 18px;
}
.hw-summary__row {
  display: flex; justify-content: space-between; padding: 12px 0; border-top: 1px solid var(--hw-line);
  font-size: 14px; color: var(--hw-text);
}
.hw-summary__row--discount span:last-child { color: var(--hw-brass-dark); }
.hw-summary__total {
  display: flex; align-items: baseline; justify-content: space-between;
  padding: 18px 0 22px; border-top: 1px solid var(--hw-line-strong); margin-top: 6px;
}
.hw-summary__total-label { font-size: 10px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--hw-green); }
.hw-summary__total-val { font-family: var(--hw-font); font-size: 34px; font-weight: 500; color: var(--hw-green); letter-spacing: -.01em; }
.hw-summary__total-val .amount { font-weight: 500; }

.hw-summary__coupon { display: flex; margin-bottom: 14px; }
.hw-summary__coupon-input {
  flex: 1; min-width: 0; padding: 14px 16px; border: 1px solid rgba(16,38,28,.24); border-right: 0;
  background: transparent; font-family: inherit; font-size: 13px; color: var(--hw-green);
}
.hw-summary__coupon-input::placeholder { color: #6B7A70; }
.hw-summary__coupon-btn {
  padding: 14px 18px; border: 1px solid var(--hw-green); background: transparent; color: var(--hw-green);
  font-family: inherit; font-size: 9.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; cursor: pointer;
}
.hw-summary__coupon-btn:hover { background: var(--hw-green); color: var(--hw-bone); }
.hw-summary__checkout { margin-top: 0; }
.hw-summary__continue {
  margin-top: 8px; padding: 16px; text-align: center; background: transparent; color: var(--hw-text-soft);
  font-family: inherit; font-size: 10px; font-weight: 700; letter-spacing: .11em; text-transform: uppercase;
  text-decoration: none;
}
.hw-summary__continue:hover { color: var(--hw-green); }
.hw-summary__perks { display: flex; flex-direction: column; margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--hw-line); }
.hw-summary__perks span { padding: 7px 0; font-size: 11.5px; color: var(--hw-text-soft); }

/* Cross-sell */
.hw-cart__cross { padding: 70px 0 0; }
.hw-cart__cross-title {
  margin: 0; padding-bottom: 24px; border-bottom: 1px solid rgba(16,38,28,.14);
  font-family: var(--hw-font); font-size: 36px; font-weight: 500; letter-spacing: -.015em; color: var(--hw-green);
}
.hw-cart__cross .cross-sells ul.products,
.hw-cart__cross-grid {
  display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 24px; padding: 32px 0 0; margin: 0; list-style: none;
}

/* ---------- Pusty koszyk ---------- */
.hw-empty { padding: 60px 0 40px; max-width: 640px; }
.hw-empty__title {
  margin: 0 0 16px; font-family: var(--hw-font); font-size: 38px; font-weight: 500; letter-spacing: -.02em;
  color: var(--hw-green); line-height: 1.05;
}
.hw-empty__text { margin: 0 0 6px; max-width: 440px; font-size: 15px; line-height: 1.8; color: var(--hw-text-soft); }
.hw-empty__actions { display: flex; gap: 12px; margin-top: 22px; flex-wrap: wrap; }

/* ---------- Mini-koszyk (drawer) ---------- */
.hw-drawer { position: fixed; inset: 0; z-index: 60; display: none; }
.hw-drawer.is-open { display: block; }
.hw-drawer__overlay { position: absolute; inset: 0; background: rgba(16,38,28,.32); }
.hw-drawer__panel {
  position: absolute; top: 0; right: 0; display: flex; flex-direction: column;
  width: 440px; max-width: 92vw; height: 100vh; background: var(--hw-bone);
  border-left: 1px solid rgba(16,38,28,.18);
  transform: translateX(100%); transition: transform .3s ease;
}
.hw-drawer.is-open .hw-drawer__panel { transform: translateX(0); }
.hw-drawer__head {
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  /* Góra 42px: makieta miała nad tytułem eyebrow (usunięty 2026-08-26) — bez niego 26px kleiło tytuł do krawędzi. */
  padding: 42px 30px 26px; border-bottom: 1px solid rgba(16,38,28,.14);
}
.hw-drawer__eyebrow { font-size: 9.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--hw-brass-dark); }
.hw-drawer__title { font-family: var(--hw-font); font-size: 26px; font-weight: 500; color: var(--hw-green); display: block; }
.hw-drawer__close { border: 0; background: transparent; font-size: 18px; color: var(--hw-text-muted); cursor: pointer; line-height: 1; }
.hw-drawer__close:hover { color: var(--hw-green); }
.hw-drawer__body { flex: 1; overflow-y: auto; padding: 0 30px; }

.hw-mini__list { list-style: none; margin: 0; padding: 0; }
.hw-mini__item { display: grid; grid-template-columns: 62px minmax(0,1fr); gap: 14px; padding: 20px 0; border-bottom: 1px solid var(--hw-line); }
.hw-mini__thumb { aspect-ratio: 4/5; background: var(--hw-sage); overflow: hidden; }
.hw-mini__thumb img { width: 100%; height: 100%; object-fit: contain; mix-blend-mode: multiply; }
.hw-mini__thumb-ph { display: block; width: 100%; height: 100%; background: var(--hw-tint-1); }
.hw-mini__body { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.hw-mini__top { display: flex; gap: 10px; }
.hw-mini__name { font-family: var(--hw-font); font-size: 16px; font-weight: 500; color: var(--hw-green); line-height: 1.2; }
.hw-mini__name a { color: inherit; text-decoration: none; }
.hw-mini__del { margin-left: auto; border: 0; background: transparent; font-size: 13px; color: var(--hw-text-muted); cursor: pointer; text-decoration: none; line-height: 1; }
.hw-mini__del:hover { color: var(--hw-green); }
.hw-mini__variant { font-size: 11.5px; color: #6B7A70; }
.hw-mini__variant .wc-item-meta { list-style: none; margin: 0; padding: 0; }
.hw-mini__controls { display: flex; align-items: center; gap: 10px; }
.hw-qty--mini .hw-qty__btn { width: 32px; height: 32px; font-size: 14px; }
.hw-qty--mini .hw-qty__val { min-width: 20px; }
.hw-mini__line { margin-left: auto; font-family: var(--hw-font); font-size: 18px; font-weight: 500; color: var(--hw-green); }
.hw-mini__empty { padding: 40px 0; text-align: center; color: var(--hw-text-soft); font-size: 14px; }

/* Box „Taniej w zestawie" (makieta: kremowy box z przyciskiem ramkowym) */
.hw-mini__bundle {
  display: flex; flex-direction: column; gap: 10px;
  margin: 18px 0 24px; padding: 20px; background: var(--hw-bone-dark);
}
.hw-mini__bundle-label {
  font-size: 9.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--hw-brass-dark);
}
.hw-mini__bundle-text { font-size: 13.5px; line-height: 1.7; color: #3B4A41; }
.hw-mini__bundle-cta {
  padding: 13px; border: 1px solid var(--hw-green); background: transparent; color: var(--hw-green);
  font-family: inherit; font-size: 9.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; cursor: pointer;
}
.hw-mini__bundle-cta:hover { background: var(--hw-green); color: var(--hw-bone); }
.hw-mini__bundle-cta[disabled] { opacity: .6; cursor: default; }

.hw-drawer__foot,
.hw-mini__foot { display: flex; flex-direction: column; gap: 12px; padding: 24px 30px 28px; border-top: 1px solid rgba(16,38,28,.16); }
.hw-mini__ship { display: flex; justify-content: space-between; font-size: 13px; color: var(--hw-text); }
.hw-mini__total { display: flex; align-items: baseline; justify-content: space-between; }
.hw-mini__total-label { font-size: 10px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--hw-green); }
.hw-mini__total-val { font-family: var(--hw-font); font-size: 30px; font-weight: 500; color: var(--hw-green); }
.hw-mini__continue {
  padding: 14px; border: 0; background: transparent; color: var(--hw-text-soft);
  font-family: inherit; font-size: 10px; font-weight: 700; letter-spacing: .11em; text-transform: uppercase; cursor: pointer;
  display: block; text-align: center; text-decoration: none;
}
.hw-mini__continue:hover { color: var(--hw-green); }

/* ---------- Mobile 390 ---------- */
@media (max-width: 900px) {
  .hw-cart__grid { grid-template-columns: minmax(0,1fr); gap: 34px; }
  .hw-summary { position: static; }
  .hw-cart__cross .cross-sells ul.products,
  .hw-cart__cross-grid { grid-template-columns: repeat(2, minmax(0,1fr)); gap: 14px; }
}
@media (max-width: 600px) {
  .hw-cart { padding: 20px 22px 70px; }
  .hw-cart__title { font-size: 40px; }
  .hw-cart__row { grid-template-columns: 72px minmax(0,1fr); grid-template-rows: auto auto; gap: 8px 14px; }
  .hw-cart__thumb { grid-row: 1 / span 2; }
  .hw-cart__line { grid-column: 2; font-size: 20px; }
  .hw-cart__name { font-size: 18px; }
  .hw-cart__bundle { flex-direction: column; align-items: flex-start; }
  .hw-cart__bundle-cta { margin-left: 0; width: 100%; }
  .hw-empty__title { font-size: 30px; }
  .hw-empty__actions .hw-btn { flex: 1; }

  /* Drawer jako bottom sheet (makieta mobile: cartOpen) */
  .hw-drawer__panel {
    top: auto; bottom: 0; right: 0; left: 0; width: 100%; max-width: 100%;
    height: auto; max-height: 86vh; border-left: 0; border-top: 1px solid rgba(16,38,28,.18);
    transform: translateY(100%);
  }
  .hw-drawer.is-open .hw-drawer__panel { transform: translateY(0); }
  .hw-drawer__head { padding: 34px 22px 20px; }
  .hw-drawer__title { font-size: 22px; }
  .hw-drawer__body { padding: 0 22px; }
  .hw-drawer__foot, .hw-mini__foot { padding: 18px 22px 22px; }
}

/* Komunikat po "Dodaj wszystko do koszyka" z Ulubionych. */
.hw-cart__flash {
  margin: 18px 0 0;
  padding: 14px 18px;
  border: 1px solid rgba(16, 38, 28, .18);
  border-left: 3px solid var(--hw-brass);
  background: var(--hw-bone-dark, #EFEDE6);
  font-size: 13.5px;
  color: var(--hw-text);
}
