/* ==========================================================================
   Кошик, оформлення замовлення, підбір авто, зворотний дзвінок
   ========================================================================== */

/* --------------------------------------------------------------------------
   Кошик
   -------------------------------------------------------------------------- */
.cart-list {
  display: flex;
  flex-direction: column;
}

.citem {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: var(--s-4);
  padding: var(--s-4) 0;
  box-shadow: inset 0 -1px 0 var(--c-line);
}

.citem:first-child {
  padding-top: 0;
}

.citem:last-child {
  box-shadow: none;
}

.citem__media {
  display: grid;
  place-items: center;
  width: 76px;
  height: 76px;
  border-radius: var(--r-lg);
  background: var(--c-media);
  color: #c3c9d3;
  overflow: hidden;
  /* multiply лише всередині мініатюри: без ізоляції Chrome змішує її з розмиттям модалки, і blur зникає */
  isolation: isolate;
}

.citem__media img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 6px;
  mix-blend-mode: multiply;
}

.citem__media svg.lucide {
  width: 28px;
  height: 28px;
  stroke-width: 1.25;
}

.citem__body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.citem__top {
  display: flex;
  align-items: flex-start;
  gap: var(--s-2);
}

.citem__title {
  flex: 1 1 auto;
  min-width: 0;
  font-size: var(--fs-14);
  font-weight: var(--fw-semibold);
  line-height: 1.4;
  transition: color var(--t-fast);
}

a.citem__title:hover {
  color: var(--c-accent);
}

.citem__remove {
  margin: -4px 0 0;
}

.citem__meta {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: var(--fs-13);
  color: var(--c-text-3);
}

.citem__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-2);
}

.citem__bottom .stepper {
  height: var(--control-h-sm);
  width: 108px;
}

.citem__bottom .stepper__btn {
  width: 32px;
}

.citem__price {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  font-variant-numeric: tabular-nums;
}

.citem__now {
  display: flex;
  align-items: baseline;
  gap: 6px;
  white-space: nowrap;
}

.citem__sum {
  font-size: var(--fs-16);
  font-weight: var(--fw-bold);
  white-space: nowrap;
}

.citem__sum.is-sale {
  color: var(--c-danger);
}

/* Стара ціна до знижки — закреслена, дрібніше */
.citem__old {
  font-size: var(--fs-12);
  font-weight: var(--fw-regular);
  color: var(--c-text-3);
  text-decoration-thickness: 1px;
  margin-right: 6px;
}

.citem__now .citem__old {
  margin-right: 0;
}

.citem__unit {
  font-size: var(--fs-12);
  color: var(--c-text-3);
  white-space: nowrap;
}

.summary {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  font-size: var(--fs-14);
}

.summary__row {
  display: flex;
  justify-content: space-between;
  gap: var(--s-3);
  color: var(--c-text-2);
}

.summary__row b {
  font-weight: var(--fw-semibold);
  color: var(--c-text);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.summary__row--discount b {
  color: var(--c-danger);
}

.summary__total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--s-3);
  padding-top: var(--s-3);
  box-shadow: inset 0 1px 0 var(--c-line);
  font-size: var(--fs-15);
  font-weight: var(--fw-bold);
}

.modal__foot--stack .summary__total:first-child {
  padding-top: 0;
  box-shadow: none;
}

.summary__total b {
  font-size: var(--fs-22);
  font-variant-numeric: tabular-nums;
}

.modal__foot--stack {
  flex-direction: column;
  align-items: stretch;
  gap: var(--s-3);
}

/* --------------------------------------------------------------------------
   Оформлення замовлення
   -------------------------------------------------------------------------- */
.co {
  display: flex;
  flex-direction: column;
  gap: var(--s-8);
}

.co__section {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}

.co__section-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: var(--fs-16);
  font-weight: var(--fw-bold);
}

.co__step {
  display: grid;
  place-items: center;
  flex: none;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--c-accent);
  color: var(--c-text-inv);
  font-size: var(--fs-13);
  font-weight: var(--fw-bold);
  line-height: 1;
  box-shadow: var(--sh-accent);
}

.co__options {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}

.co__order {
  border-radius: var(--r-lg);
  background: var(--c-surface-2);
  padding: 0 14px;
}

.co__order .acc__head {
  min-height: 50px;
  font-weight: var(--fw-semibold);
}

.co__order .acc__head > svg.lucide:first-child {
  color: var(--c-accent);
}

.co__order-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-bottom: 14px;
  font-size: var(--fs-13);
}

.co__order-item {
  display: flex;
  justify-content: space-between;
  gap: var(--s-3);
  color: var(--c-text-2);
}

.co__order-item span:first-child {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.co__order-item b {
  font-weight: var(--fw-semibold);
  color: var(--c-text);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.co__agree {
  font-size: var(--fs-12);
  color: var(--c-text-3);
  text-align: center;
}

.co__agree a {
  color: var(--c-text-2);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.np-mark {
  height: 18px;
  width: auto;
}

/* --------------------------------------------------------------------------
   Підбір авто
   -------------------------------------------------------------------------- */
.vgrid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--s-4);
}

.or-sep {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  font-size: var(--fs-13);
  color: var(--c-text-3);
}

.or-sep::before,
.or-sep::after {
  content: "";
  flex: 1 1 auto;
  height: 1px;
  background: var(--c-line);
}

.vin-row {
  display: flex;
  gap: var(--s-2);
}

.vin-row .input {
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.vin-row .btn {
  height: var(--input-h);
}

.garage {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* Нещодавні авто — сірі чипи без тіні (вони всередині білої панелі) */
.garage .chip {
  background: var(--c-surface-2);
  box-shadow: none;
}

.garage .chip:hover {
  background: var(--c-active);
  color: var(--c-text);
}

@media (max-width: 479px) {
  .vgrid,
  .field-row {
    grid-template-columns: minmax(0, 1fr);
  }
}
