/* ============================================================
   Origins of Light — koszyk + checkout (design: koszyk.tsx)
   ============================================================ */

/* ---------- Hero (breadcrumb bez tytułu) ---------- */
.ool-carthero__ghost {
  visibility: hidden;
  user-select: none;
  font-size: 2.25rem;
  line-height: 1.2;
}
@media (min-width: 1024px) {
  .ool-carthero__ghost { font-size: 3rem; }
}

/* ---------- Kroki checkoutu ---------- */
.ool-cartsteps { padding-top: 2.5rem; }
@media (min-width: 1024px) { .ool-cartsteps { padding-top: 3rem; } }

.ool-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.ool-steps__item { display: flex; align-items: center; gap: 0.5rem; min-width: 0; }
.ool-steps__step { display: flex; align-items: center; gap: 0.5rem; min-width: 0; }
.ool-steps__dot {
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 9999px;
  border: 2px solid var(--border);
  background: var(--background);
  color: var(--muted-foreground);
  font-size: 0.75rem;
  font-weight: 500;
  transition: all var(--transition-elegant);
}
.ool-steps__dot.is-current { border-color: var(--gold); color: var(--gold); }
.ool-steps__dot.is-done { border-color: var(--gold); background: var(--gold); color: var(--primary-foreground); }
.ool-steps__label {
  display: none;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  font-size: 10px;
  white-space: nowrap;
  color: var(--muted-foreground);
}
.ool-steps__label.is-current { display: inline; color: var(--foreground); }
.ool-steps__label.is-done { display: inline; color: color-mix(in srgb, var(--foreground) 80%, transparent); }
.ool-steps__line { height: 1px; width: 1.5rem; flex-shrink: 0; background: var(--border); }
.ool-steps__item.is-done .ool-steps__line { background: var(--gold); }
@media (min-width: 640px) {
  .ool-steps { gap: 1rem; }
  .ool-steps__item { gap: 1rem; }
  .ool-steps__label { display: inline; font-size: 11px; }
  .ool-steps__line { width: 3rem; }
}

/* ---------- Sekcja główna ---------- */
.ool-cartbody { padding-top: 2.5rem; padding-bottom: 2.5rem; }
@media (min-width: 1024px) {
  .ool-cartbody { padding-top: 2.5rem; padding-bottom: 3.5rem; }
}
.ool-cartgrid { display: grid; gap: 2rem; align-items: start; }
@media (min-width: 1024px) {
  .ool-cartgrid { grid-template-columns: 1.4fr 1fr; gap: 3rem; }
}

/* ---------- Pasek darmowej dostawy ---------- */
.ool-cartship {
  margin-bottom: 1.5rem;
  border: 2px solid var(--border);
  background: var(--pearl);
  padding: 1.25rem;
}
.ool-cartship__text { margin: 0; font-size: 0.875rem; color: color-mix(in srgb, var(--foreground) 85%, transparent); }
.ool-cartship__text--free { display: flex; align-items: center; gap: 0.5rem; }
.ool-cartship__text--free svg { color: var(--gold); flex-shrink: 0; }
.ool-cartship__amount { font-family: var(--font-display); font-size: 1rem; color: var(--gold); }
.ool-cartship__em { font-style: italic; font-family: var(--font-display); color: var(--gold); }
.ool-cartship__bar { margin-top: 0.75rem; height: 0.25rem; width: 100%; background: var(--marble); overflow: hidden; }
.ool-cartship__fill { height: 100%; background: var(--gradient-gold); transition: width 0.5s ease; }

/* ---------- Tabela pozycji ---------- */
.ool-cartbox { border: 2px solid var(--border); background: var(--background); }
.ool-cartbox__head { display: none; }
@media (min-width: 640px) {
  .ool-cartbox__head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 120px 120px 40px;
    gap: 1rem;
    padding: 1rem 1.5rem;
    border-bottom: 2px solid var(--border);
    font-size: 10px;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--muted-foreground);
  }
  .ool-cartbox__head-center { text-align: center; }
  .ool-cartbox__head-right { text-align: right; }
}

.ool-cartbox .cart-items,
.ool-cartitems { list-style: none; margin: 0; padding: 0; }
.ool-cartbox .cart-item,
.ool-cartline { padding: 0; border-bottom: 0; }
.ool-cartline + .ool-cartline { border-top: 2px solid var(--border); }

.ool-cartline__grid {
  display: grid;
  grid-template-columns: 5rem minmax(0, 1fr) auto;
  gap: 1rem;
  padding: 1.25rem;
  align-items: center;
}
.ool-cartline__img { grid-column: 1; grid-row: 1; }
.ool-cartline__info { grid-column: 2 / span 2; grid-row: 1; min-width: 0; }
.ool-cartline__qty { grid-column: 2; grid-row: 2; justify-self: end; }
.ool-cartline__total { display: none; }
.ool-cartline__actions { grid-column: 3; grid-row: 2; }
@media (min-width: 640px) {
  .ool-cartline__grid {
    grid-template-columns: 5rem minmax(0, 1fr) 120px 120px 40px;
    padding: 1.25rem 1.5rem;
  }
  .ool-cartline__info { grid-column: 2; }
  .ool-cartline__qty { grid-column: 3; grid-row: 1; justify-self: center; }
  .ool-cartline__total {
    display: block;
    grid-column: 4;
    grid-row: 1;
    margin: 0;
    font-family: var(--font-display);
    font-size: 1.125rem;
    font-weight: 400;
    color: var(--foreground);
    text-align: right;
  }
  .ool-cartline__actions { grid-column: 5; grid-row: 1; }
  .ool-cartline__mobileprice { display: none; }
}

.ool-cartline__img {
  width: 5rem;
  height: 5rem;
  background: #fff;
  border: 1px solid var(--border);
  overflow: hidden;
}
.ool-cartline__img a { display: block; width: 100%; height: 100%; }
.ool-cartline__img img { width: 100%; height: 100%; object-fit: cover; display: block; }

.ool-cartline__name {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.375;
  color: var(--foreground);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.ool-cartline__name a.label,
.ool-cartline__name a {
  color: inherit;
  text-decoration: none;
  font-family: inherit;
  font-size: inherit;
  font-weight: inherit;
  padding: 0;
}
.ool-cartline__variant { margin: 0.25rem 0 0; font-size: 0.75rem; color: var(--muted-foreground); }
.ool-cartline__discount { margin: 0.25rem 0 0; font-size: 0.75rem; }
.ool-cartline__discount .regular-price { text-decoration: line-through; color: var(--muted-foreground); }
.ool-cartline__discount .discount { color: var(--gold); margin-left: 0.375rem; }
.ool-cartline__mobileprice { margin: 0.5rem 0 0; font-size: 0.875rem; }
.ool-cartline__mobileqty { color: var(--muted-foreground); }
.ool-cartline__mobileval { font-weight: 500; }
.ool-cartline__custom { font-size: 0.75rem; color: var(--gold); text-decoration: underline; }
.ool-cartline__giftqty { font-family: var(--font-display); font-size: 1rem; }

/* Stepper ilości (markup generowany przez touchspin z theme.js).
   Selektory celowo o wysokiej specyficzności — nadpisują theme.css (classic). */
.ool-cartline__qty .input-group.bootstrap-touchspin {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  float: none;
  margin: 0;
  border: 1px solid var(--border);
  background: var(--background);
  height: 2.25rem;
  width: 100px;
}
.ool-cartline__qty .input-group.bootstrap-touchspin.focus { outline: 0; }
.ool-cartline__qty .bootstrap-touchspin .input-group-btn-vertical { display: contents; float: none; }
.ool-cartline__qty .bootstrap-touchspin .bootstrap-touchspin-prefix,
.ool-cartline__qty .bootstrap-touchspin .bootstrap-touchspin-postfix { display: none; }
.ool-cartline__qty .input-group .js-cart-line-product-quantity,
.ool-cartline__qty .js-cart-line-product-quantity {
  flex: 1 1 auto;
  float: none;
  width: 1%;
  min-width: 0;
  height: 100%;
  order: 0;
  border: 0;
  background: transparent;
  text-align: center;
  font-family: var(--font-display);
  font-size: 0.875rem;
  color: var(--foreground);
  padding: 0;
  margin: 0;
  outline: none;
  box-shadow: none;
  appearance: textfield;
  -moz-appearance: textfield;
  border-radius: 0;
}
.ool-cartline__qty .js-cart-line-product-quantity::-webkit-outer-spin-button,
.ool-cartline__qty .js-cart-line-product-quantity::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.ool-cartline__qty .bootstrap-touchspin .btn-touchspin,
.ool-cartline__qty .bootstrap-touchspin .input-group-btn-vertical > .btn {
  width: 2rem;
  max-width: 2rem;
  height: 100%;
  flex-shrink: 0;
  float: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  color: color-mix(in srgb, var(--foreground) 70%, transparent);
  cursor: pointer;
  padding: 0;
  margin: 0;
  border-radius: 0;
  transition: color var(--transition-elegant);
}
.ool-cartline__qty .bootstrap-touchspin .input-group-btn-vertical > .bootstrap-touchspin-down { order: -1; margin: 0; }
.ool-cartline__qty .bootstrap-touchspin .input-group-btn-vertical > .bootstrap-touchspin-up { order: 1; margin: 0; }
.ool-cartline__qty .bootstrap-touchspin .input-group-btn-vertical i {
  position: static;
  top: auto;
  left: auto;
  font-family: var(--font-body), sans-serif;
  font-size: 1rem;
  font-weight: 400;
  width: auto;
  height: auto;
  line-height: 1;
}
.ool-cartline__qty .bootstrap-touchspin .material-icons.touchspin-up::after { content: "+"; }
.ool-cartline__qty .bootstrap-touchspin .material-icons.touchspin-down::after { content: "−"; }
@media (min-width: 640px) {
  .ool-cartline__qty .input-group.bootstrap-touchspin { height: 2.5rem; width: 110px; }
  .ool-cartline__qty .bootstrap-touchspin .btn-touchspin,
  .ool-cartline__qty .bootstrap-touchspin .input-group-btn-vertical > .btn { width: 2.25rem; max-width: 2.25rem; }
  .ool-cartline__qty .input-group .js-cart-line-product-quantity { font-size: 1rem; }
}
/* Fallback zanim JS opakuje input */
.ool-cartline__qty > .js-cart-line-product-quantity {
  height: 2.25rem;
  width: 100px;
  border: 1px solid var(--border);
}
.ool-cartline__qty .bootstrap-touchspin .js-cart-line-product-quantity { height: 100%; width: 1%; border: 0; }

.ool-cartline__actions { display: flex; align-items: center; justify-content: flex-end; }
.ool-cartline__actions .remove-from-cart,
.ool-cartline__remove {
  width: 2.25rem;
  height: 2.25rem;
  margin: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--muted-foreground);
  transition: color var(--transition-elegant);
}

/* ---------- Kontynuuj zakupy ---------- */
.ool-cartcontinue { margin-top: 1.5rem; }
.ool-cartcontinue a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: var(--foreground);
  text-decoration: none;
  transition: color var(--transition-elegant);
}

/* ---------- Sidebar podsumowania ---------- */
.ool-cartside { display: grid; gap: 1.25rem; align-self: start; }
@media (min-width: 1024px) {
  .ool-cartside { position: sticky; top: 7rem; }
}

.ool-cartsum { border: 2px solid var(--border); background: var(--pearl); }
.ool-cartsum__head { padding: 1.25rem 1.5rem; border-bottom: 2px solid var(--border); }
.ool-cartsum__head h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 400;
  color: var(--foreground);
}
.ool-cartsum__head em { font-style: italic; }

/* Kod rabatowy */
.ool-cartsum .block-promo,
.ool-promo { margin: 0; }
.ool-promo { padding: 1.25rem 1.5rem; border-bottom: 2px solid var(--border); }
.ool-promo__label {
  display: block;
  font-size: 10px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--muted-foreground);
  margin: 0 0 0.5rem;
  font-weight: 400;
  text-align: left; /* nadpisuje label{text-align:right} z theme.css */
}
.ool-promo__form { display: flex; }
.ool-promo__field { position: relative; flex: 1; min-width: 0; }
.ool-promo__field svg {
  position: absolute;
  left: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted-foreground);
  pointer-events: none;
}
.ool-promo__field .promo-input {
  width: 100%;
  height: 2.75rem;
  margin: 0;
  padding: 0 0.75rem 0 2.25rem;
  text-indent: 0;
  border: 2px solid var(--border);
  background: var(--background);
  font-size: 0.875rem;
  color: var(--foreground);
  outline: none;
  border-radius: 0;
  transition: border-color var(--transition-elegant);
}
.ool-promo__field .promo-input:focus { border-color: var(--gold); }
.ool-promo__form .ool-promo__btn,
.ool-promo__btn {
  height: 2.75rem;
  margin: 0;
  padding: 0 1.25rem;
  background: var(--foreground);
  color: var(--background);
  font-size: 10px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  border: 2px solid var(--foreground);
  border-radius: 0;
  cursor: pointer;
  flex-shrink: 0;
  transition: all var(--transition-elegant);
}
.ool-promo__added { list-style: none; margin: 0.5rem 0 0; padding: 0; }
.ool-promo__addedline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin: 0.25rem 0 0;
  padding: 0;
  font-size: 0.75rem;
  color: var(--gold);
}
.ool-promo__addedline .label { font-size: 0.75rem; font-weight: 400; color: var(--gold); }
.ool-promo__code { font-weight: 500; }
.ool-promo__remove { display: inline-flex; color: var(--muted-foreground); flex-shrink: 0; }
.ool-promo__error { display: none; }
.ool-promo__offers { margin: 0.75rem 0 0.25rem; font-size: 0.75rem; color: var(--muted-foreground); }
.ool-promo__discounts { list-style: none; margin: 0; padding: 0; font-size: 0.75rem; }
.ool-promo__discountline { padding: 0; margin: 0; }
.ool-promo__discountline .label { font-size: 0.75rem; font-weight: 400; color: var(--muted-foreground); }
.ool-promo__discountline .code { color: var(--gold); cursor: pointer; text-decoration: underline; }

/* Sumy */
.ool-sumlines { padding: 1.25rem 1.5rem 0; display: grid; gap: 0.75rem; }
.ool-sumlines .cart-summary-line,
.ool-sumline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  margin: 0;
  padding: 0;
  font-size: 0.875rem;
}
.ool-sumline .label,
.ool-sumline__label { font-size: 0.875rem; font-weight: 400; color: var(--muted-foreground); margin: 0; }
.ool-sumline .value,
.ool-sumline__value { font-size: 0.875rem; font-weight: 400; color: var(--foreground); }
.ool-sumline .ool-sumline__value--gold,
.ool-sumline__value--gold { color: var(--gold); }
.ool-sumline__free { font-style: italic; font-family: var(--font-display); color: var(--gold); }
.ool-sumline__details { flex-basis: 100%; font-size: 0.75rem; color: var(--muted-foreground); }

.ool-sumtotal { padding: 0 1.5rem 1.25rem; }
.card-block.cart-summary-totals.ool-sumtotal .cart-summary-line.cart-total,
.ool-sumtotal .cart-summary-line.cart-total,
.ool-sumtotal__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 2px solid var(--border);
  padding: 1rem 0 0;
  margin-top: 1rem;
}
.card-block.cart-summary-totals.ool-sumtotal .cart-summary-line.cart-total .label,
.ool-sumtotal .cart-total .label,
.ool-sumtotal__row .label {
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 400;
  color: var(--foreground);
}
.card-block.cart-summary-totals.ool-sumtotal .cart-summary-line.cart-total .value,
.ool-sumtotal .cart-total .value,
.ool-sumtotal__row .value {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 400;
  color: var(--foreground);
}
.ool-sumtotal .cart-summary-line:not(.cart-total) { display: flex; justify-content: space-between; padding: 0.75rem 0 0; margin: 0; }
.ool-sumtotal .cart-summary-line:not(.cart-total) .label { font-size: 0.875rem; font-weight: 400; color: var(--muted-foreground); }
.ool-sumtotal .cart-summary-line:not(.cart-total) .value { font-size: 0.875rem; font-weight: 400; color: var(--foreground); }
.ool-sumtotal__vat { margin: 0.25rem 0 0; font-size: 11px; color: var(--muted-foreground); text-align: right; }

/* CTA */
.ool-cartcta { padding: 0 1.5rem 1.5rem; margin: 0; }
.ool-cartbtn-gold {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  height: 3rem;
  padding: 0 2rem;
  background: var(--gold);
  color: var(--primary-foreground);
  text-transform: uppercase;
  letter-spacing: 0.25em;
  font-size: 0.75rem;
  font-weight: 500;
  text-decoration: none;
  border: 0;
  border-radius: 0;
  cursor: pointer;
  transition: opacity var(--transition-elegant), background var(--transition-elegant);
}
.ool-cartbtn-gold svg { flex-shrink: 0; }
.ool-cartbtn-gold--block { width: 100%; height: 3.5rem; margin-top: 0; padding: 0 0.5rem; white-space: nowrap; }
.ool-cartcta__alert + .ool-cartbtn-gold--block { margin-top: 0.75rem; }
.ool-cartbtn-gold[disabled] { opacity: 0.5; cursor: not-allowed; }
.ool-cartcta__ssl {
  margin: 0.75rem 0 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  font-size: 11px;
  color: var(--muted-foreground);
}
.ool-cartcta__ssl svg { flex-shrink: 0; }
.ool-cartcta__alert {
  margin: 1rem 0 0;
  border: 2px solid var(--border);
  background: var(--background);
  padding: 0.75rem 1rem;
  font-size: 0.8125rem;
  color: var(--foreground);
}

/* ---------- Zaufanie + płatności ---------- */
.ool-carttrust {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  border: 2px solid var(--border);
  background: var(--background);
  padding: 1rem;
  margin: 0;
  list-style: none;
  text-align: center;
}
.ool-carttrust li {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  font-size: 11px;
  color: color-mix(in srgb, var(--foreground) 80%, transparent);
}
.ool-carttrust svg { color: var(--gold); flex-shrink: 0; }

.ool-cartpay { border: 2px solid var(--border); background: var(--background); padding: 1rem; }
.ool-cartpay__label {
  margin: 0 0 0.75rem;
  font-size: 10px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--muted-foreground);
  text-align: center;
}
.ool-cartpay__badges {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-size: 10px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--foreground) 70%, transparent);
}
.ool-cartpay__badges span { padding: 0.25rem 0.625rem; border: 1px solid var(--border); background: var(--pearl); }

/* ---------- Pusty koszyk ---------- */
.ool-cartempty {
  border: 2px solid var(--border);
  background: var(--background);
  padding: 3rem;
  text-align: center;
}
@media (min-width: 1024px) { .ool-cartempty { padding: 5rem; } }
.ool-cartempty__eyebrow,
.ool-cartnoitems__eyebrow {
  margin: 0 0 0.75rem;
  font-size: 0.75rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--gold);
}
.ool-cartempty__title,
.ool-cartnoitems__title {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-size: 1.875rem;
  font-weight: 400;
  color: var(--foreground);
}
@media (min-width: 1024px) {
  .ool-cartempty__title { font-size: 2.25rem; }
}
.ool-cartempty__title em,
.ool-cartnoitems__title em { font-style: italic; }
.ool-cartempty__text,
.ool-cartnoitems__text { margin: 0 0 2rem; color: var(--muted-foreground); font-size: 1rem; }

/* Pusty stan po ajaxowym usunięciu ostatniej pozycji */
.ool-cartbox--noitems { padding: 3rem 1.5rem; text-align: center; }
.ool-cartnoitems__title { font-size: 1.5rem; }

/* ---------- Sidebar checkoutu (cart-summary-*) ---------- */
.ool-cartsum__block { padding: 1.25rem 1.5rem 0; }
.ool-cartsum--checkout .ool-sumlines { padding: 0.75rem 0 0; }
.ool-sumprods__count { margin: 0; font-size: 0.875rem; color: var(--foreground); }
.ool-sumprods__toggle { margin: 0.25rem 0 0; }
.ool-sumprods__toggle a {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted-foreground);
  text-decoration: none;
}
.ool-sumprods__list { list-style: none; margin: 0.75rem 0 0; padding: 0; }
.ool-sumprods__item { display: flex; gap: 0.75rem; padding: 0.5rem 0; }
.ool-sumprod__img img { width: 3rem; height: 3rem; object-fit: cover; border: 1px solid var(--border); background: #fff; }
.ool-sumprod__body { flex: 1; min-width: 0; font-size: 0.8125rem; }
.ool-sumprod__name a { font-family: var(--font-display); font-size: 0.9375rem; color: var(--foreground); text-decoration: none; }
.ool-sumprod__qty { color: var(--muted-foreground); margin-left: 0.375rem; }
.ool-sumprod__price { float: right; color: var(--foreground); }
.ool-sumprod__variant { font-size: 0.75rem; color: var(--muted-foreground); }
