.c-cart {
  max-width: var(--container-lg);
  margin-inline: auto;
  padding: var(--space-6) var(--gutter) clamp(var(--space-16), 8vw, var(--space-20));
}

.c-cart__heading {
  margin-bottom: var(--space-1);
  font-size: var(--text-h2);
}

.c-cart__count {
  margin-bottom: clamp(var(--space-8), 4vw, var(--space-9, 2.25rem));
  color: var(--color-text-muted);
  font-size: var(--text-small);
}

.c-cart__layout {
  display: grid;
  gap: clamp(2rem, 4vw, 2.5rem);
  grid-template-columns: repeat(1, minmax(0, 1fr));
  align-items: start;
}

@media (min-width: 56rem) {
  .c-cart__layout { grid-template-columns: 1.6fr 1fr; }
}

.c-cart-item {
  display: flex;
  gap: var(--space-5);
  background: var(--color-surface-raised);
  border: 1px solid var(--color-border);
  padding: var(--space-5);
  margin-bottom: var(--space-4);
}

.c-cart-item__image {
  flex-shrink: 0;
  width: 6rem;
  height: 7.375rem;
  background: url("../../images/product-thumb-bag.webp") center / cover no-repeat, linear-gradient(150deg, var(--color-tan-300), var(--color-tan-500));
}

/* min-width: 0 — a flex item's automatic minimum size is its content's
   min-content width, so the qty stepper and line total held this body
   wider than the space left beside the thumbnail and pushed the card
   past the viewport on phones. */
.c-cart-item__body {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.c-cart-item__top {
  display: flex;
  justify-content: space-between;
  gap: var(--space-3);
}

.c-cart-item__name { font-size: 1.25rem; margin-bottom: .25rem; }
.c-cart-item__meta { color: var(--color-text-muted); font-size: var(--text-micro); font-weight: 500; }

.c-cart-item__remove {
  background: none;
  border: 0;
  color: var(--color-text-muted);
  font-weight: 700;
  font-size: var(--text-micro);
  letter-spacing: .04em;
  text-transform: uppercase;
  cursor: pointer;
  align-self: start;
}

.c-cart-item__bottom {
  margin-top: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3) var(--space-4);
  padding-top: var(--space-4);
}

.c-cart-item__line-total {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.25rem;
}

.c-cart__continue {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--color-accent-text) !important;
  font-weight: 700;
  font-size: var(--text-small);
  margin-top: var(--space-2);
}

.c-cart-summary {
  background: var(--color-surface);
  border: 1px solid var(--color-border-header);
  padding: clamp(1.5rem, 4vw, 1.875rem);
}

.c-cart-summary__heading { margin-bottom: var(--space-5); font-size: 1.5rem; }

.c-cart-summary__rows {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  padding-bottom: var(--space-5);
  border-bottom: 1px solid var(--color-border-muted);
  font-size: var(--text-small);
  color: var(--color-text-secondary);
}

.c-cart-summary__row { display: flex; justify-content: space-between; }
.c-cart-summary__row strong { color: var(--color-ink); }
.c-cart-summary__ship-free { color: var(--color-success-text) !important; }

.c-cart-summary__nudge {
  background: var(--color-badge-bg);
  color: var(--color-accent-hover) !important;
  font-size: var(--text-micro);
  font-weight: 600;
  padding: var(--space-3) var(--space-4);
  margin-top: var(--space-4);
}

.c-cart-summary__total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding-block: var(--space-5);
}

.c-cart-summary__total-label { font-weight: 800; font-size: 1.0625rem; }
.c-cart-summary__total-value { font-family: var(--font-display); font-weight: 800; font-size: 1.75rem; }

.c-cart-summary__promo {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-bottom: var(--space-5);
}

.c-cart-summary__promo input {
  flex: 1 1 8rem;
  min-width: 0;
  border: 1px solid var(--color-border-input);
  background: var(--color-white);
  padding: var(--space-3) var(--space-4);
  font-family: var(--font-body);
  font-size: var(--text-small);
}

.c-cart-summary__promo button {
  flex: 0 1 auto;
  min-height: 2.75rem;
  background: var(--color-ink);
  color: var(--color-white);
  border: 0;
  font-weight: 700;
  font-size: var(--text-micro);
  letter-spacing: .05em;
  text-transform: uppercase;
  padding-inline: var(--space-5);
  cursor: pointer;
}

.c-cart-summary__secure {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  margin-top: var(--space-4);
  color: var(--color-text-muted);
  font-size: var(--text-micro);
  text-align: center;
}

.c-cart-summary__secure svg {
  width: .8125rem;
  height: .8125rem;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

.c-cart-empty {
  text-align: center;
  max-width: 35rem;
  margin: 0 auto;
  background: var(--color-surface-raised);
  border: 1px solid var(--color-border);
  padding: clamp(3rem, 8vw, 4.5rem) var(--space-8);
}

.c-cart-empty__icon {
  display: inline-grid;
  width: 4.375rem;
  height: 4.375rem;
  place-items: center;
  margin: 0 auto var(--space-5);
  border-radius: var(--radius-pill);
  background: var(--color-badge-bg);
  color: var(--color-accent-text);
}

.c-cart-empty__icon svg { width: 2rem; height: 2rem; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; fill: none; }
.c-cart-empty h2 { margin-bottom: var(--space-3); font-size: 1.75rem; }
.c-cart-empty p { margin-bottom: var(--space-6); color: var(--color-text-tertiary); }

@media (max-width: 30rem) {
  .c-cart-item {
    gap: var(--space-4);
    padding: var(--space-4);
  }

  .c-cart-item__image {
    width: 4.5rem;
    height: 5.5rem;
  }

  .c-cart-item__name {
    font-size: 1.0625rem;
  }
}
