.cart-header {
  background: #2c3e50;
  padding: 15px 20px;
  color: #fff;
}

.cart-header__inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 20px;
}

.cart-header__inner h2 {
  margin: 0;
  font-weight: 400;
  font-size: 22px;
}

.back-link {
  color: #fff;
  text-decoration: none;
  font-size: 14px;
  opacity: 0.8;
}

.back-link:hover {
  opacity: 1;
}

.cart-wrap {
  max-width: 1200px;
  margin: 30px auto;
  padding: 0 20px;
}

/* Пустая корзина / успех */
.cart-empty,
.order-success {
  background: #fff;
  text-align: center;
  padding: 60px 40px;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
}

.order-success__icon {
  font-size: 56px;
  margin-bottom: 16px;
}

.order-success__icon {
  width: 72px;
  height: 72px;
  background: #27ae60;
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  margin: 0 auto 16px;
}

.cart-empty h3,
.order-success h2 {
  margin: 0 0 10px;
  color: #2c3e50;
}

.cart-empty p,
.order-success p {
  color: #7f8c8d;
  margin-bottom: 24px;
}

.cart-layout {
  display: flex;
  gap: 30px;
  align-items: flex-start;
}

.cart-items {
  flex: 1;
  min-width: 0;
  background: #fff;
  border-radius: 8px;
  padding: 24px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
}

.cart-items h3,
.order-form-wrap h3 {
  margin: 0 0 20px;
  color: #2c3e50;
  font-size: 18px;
  font-weight: 600;
  border-bottom: 2px solid #f0f0f0;
  padding-bottom: 12px;
}

/* Товар в корзине */
.cart-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid #f0f0f0;
  position: relative;
}

.cart-item img {
  width: 72px;
  height: 72px;
  object-fit: contain;
  background: #f8f8f8;
  border: 1px solid #eee;
  border-radius: 4px;
  flex-shrink: 0;
}

.cart-item__info {
  flex: 1;
  min-width: 0;
}

.cart-item__title {
  font-size: 14px;
  font-weight: 600;
  color: #2c3e50;
  margin-bottom: 3px;
}

.cart-item__sku {
  font-size: 12px;
  color: #95a5a6;
  margin-bottom: 4px;
}

.cart-item__price-unit {
  font-size: 13px;
  color: #7f8c8d;
}

.price-on-request {
  color: #e67e22;
  font-weight: 600;
}

/* Степер +/- в стиле мини-корзины (cart-flyout) */
.cart-item__qty {
  display: inline-flex;
  align-items: center;
  border: 1px solid #e6e6e8;
  overflow: hidden;
  height: 40px;
  flex-shrink: 0;
}

.qty-btn {
  width: 40px;
  height: 40px;
  border: none;
  background: #f6f6f7;
  color: #1c1c1e;
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}

.qty-btn:hover {
  background: #e6e6e8;
}

.qty-input {
  width: 54px;
  text-align: center;
  border: none;
  background: transparent;
  padding: 0;
  font-size: 16px;
  font-weight: 600;
  color: #1c1c1e;
  -moz-appearance: textfield;
}
.qty-input::-webkit-outer-spin-button,
.qty-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.cart-item__subtotal {
  width: 110px;
  text-align: right;
  font-weight: 700;
  color: #e67e22;
  font-size: 15px;
  flex-shrink: 0;
}

.cart-item__remove {
  color: #bdc3c7;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
  padding: 4px 6px;
  flex-shrink: 0;
  transition: color 0.2s;
}
.cart-item__remove svg {
  width: 20px;
  height: 20px;
  display: block;
}

.cart-item__remove:hover {
  color: #c0392b;
}

.cart-actions {
  margin-top: 16px;
  text-align: right;
}

.btn-update {
  background: none;
  border: 1px solid #bdc3c7;
  padding: 8px 18px;
  border-radius: 4px;
  font-size: 13px;
  cursor: pointer;
  color: #7f8c8d;
  transition: all 0.2s;
}

.btn-update:hover {
  border-color: #2c3e50;
  color: #2c3e50;
}

.btn-clear {
  display: inline-block;
  padding: 13px 24px;
  border: none;
  border-radius: 0;
  background: #e67e22;
  color: #fff;
  font-size: 18px;
  font-weight: 400;
  cursor: pointer;
  text-align: center;
  transition: background 0.2s;
}
.btn-clear:hover {
  background: #d46f14;
}

/* Форма заказа */
.order-form-wrap {
  width: 380px;
  flex-shrink: 0;
  background: #fff;
  border-radius: 8px;
  padding: 24px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
  position: sticky;
  top: 20px;
}

.form-section {
  margin-bottom: 16px;
}

.section-label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: #34495e;
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.radio-group {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.radio-group.vertical {
  flex-direction: column;
  gap: 6px;
}

.radio-label {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 14px;
  cursor: pointer;
  padding: 6px 10px;
  border: 1px solid #e0e0e0;
  border-radius: 4px;
  transition:
    border-color 0.2s,
    background 0.2s;
  user-select: none;
}

.radio-label:has(input:checked) {
  border-color: #f58220;
  background: #fff8f3;
  color: #b45309;
}

.radio-label input[type="radio"] {
  appearance: none;
  -webkit-appearance: none;
  box-sizing: border-box;
  width: 16px;
  height: 16px;
  min-width: 16px;
  padding: 0;
  margin: 0;
  flex-shrink: 0;
  border: 2px solid #1c1c1e;
  border-radius: 50%;
  cursor: pointer;
}

.radio-label input[type="radio"]:checked {
  border-color: #f58220;
  background: radial-gradient(circle, #f58220 0 4px, transparent 4.5px);
}

.form-field {
  margin-bottom: 14px;
}

.form-field label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #34495e;
  margin-bottom: 5px;
}

.form-field input,
.form-field textarea {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 14px;
  transition: border-color 0.2s;
}

.form-field input:focus,
.form-field textarea:focus {
  outline: none;
  border-color: #e67e22;
}

.form-field textarea {
  resize: vertical;
}

.order-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 0;
  border-top: 2px solid #f0f0f0;
  margin: 14px 0;
  font-size: 16px;
}

.order-total strong {
  font-size: 22px;
  color: #e67e22;
}

.btn-order {
  display: inline-block;
  width: 100%;
  padding: 13px;
  background: #ff8a2a;
  color: #fff;
  border: none;
  border-radius: 4px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
  transition: background 0.2s;
}

.btn-order:hover {
  background: #5d5d5d;
}
.card-btn--analog {
  display: inline-block;
  padding: 7px 14px;
  color: #1c1c1e !important;
  text-decoration: none !important;
  font-weight: 600;
}
.card-btn--analog:hover {
  color: #d9740f !important;
}

@media (max-width: 1440px) {
  .cart-header__inner {
    padding: 0 20px;
  }
  .cart-wrap {
    padding: 0 30px;
  }
}

@media (max-width: 1200px) {
  .cart-wrap {
    padding: 0 20px;
    margin: 24px auto;
  }
  .cart-layout {
    gap: 20px;
  }

  .cart-items {
    padding: 20px;
  }
  .order-form-wrap {
    width: 340px;
    padding: 20px;
  }
  .cart-header__inner h2 {
    font-size: 20px;
  }
  .cart-item__subtotal {
    width: 90px;
  }
}

@media (max-width: 960px) {
  .cart-layout {
    flex-direction: column;
  }
  .order-form-wrap {
    width: 100%;
    position: static;
    padding: 20px;
  }

  .cart-header__inner {
    gap: 14px;
    flex-wrap: wrap;
  }
  .cart-empty,
  .order-success {
    padding: 48px 30px;
  }
  .order-success__icon {
    width: 64px;
    height: 64px;
    font-size: 30px;
  }
}

@media (max-width: 680px) {
  .cart-header {
    padding: 14px 16px;
  }
  .cart-wrap {
    padding: 0 16px;
    margin: 18px auto;
  }

  .cart-items {
    padding: 16px;
  }
  .cart-items h3,
  .order-form-wrap h3 {
    font-size: 16px;
    margin-bottom: 14px;
    padding-bottom: 10px;
  }

  .cart-item {
    gap: 12px;
    padding: 12px 0;
  }
  .cart-item img {
    width: 64px;
    height: 64px;
  }
  .cart-item__title {
    font-size: 13px;
  }
  .cart-item__subtotal {
    width: 80px;
    font-size: 14px;
  }
  .cart-item__qty {
    height: 36px;
  }
  .qty-btn {
    width: 36px;
    height: 36px;
    font-size: 15px;
  }
  .qty-input {
    width: 46px;
    font-size: 15px;
  }

  .btn-update {
    padding: 8px 14px;
    font-size: 12px;
  }
  .btn-clear {
    font-size: 16px;
    padding: 12px 20px;
  }

  .order-form-wrap {
    padding: 16px;
  }
  .section-label {
    font-size: 12px;
  }
  .radio-label {
    font-size: 13px;
    padding: 5px 8px;
    gap: 6px;
  }
  .form-field input,
  .form-field textarea {
    padding: 8px 10px;
    font-size: 13px;
  }

  .order-total {
    font-size: 15px;
    padding: 12px 0;
  }
  .order-total strong {
    font-size: 20px;
  }
  .btn-order {
    font-size: 15px;
    padding: 12px;
  }

  .cart-empty,
  .order-success {
    padding: 36px 20px;
  }
  .order-success__icon {
    width: 56px;
    height: 56px;
    font-size: 26px;
    margin-bottom: 14px;
  }
  .cart-empty h3,
  .order-success h2 {
    font-size: 18px;
  }
  .cart-empty p,
  .order-success p {
    font-size: 14px;
    margin-bottom: 20px;
  }
}

@media (max-width: 480px) {
  .cart-header {
    padding: 12px;
  }
  .cart-header__inner {
    gap: 10px;
  }
  .cart-header__inner h2 {
    font-size: 17px;
  }
  .back-link {
    font-size: 13px;
  }

  .cart-wrap {
    padding: 0 10px;
    margin: 14px auto;
  }
  .cart-items {
    padding: 12px;
  }

  .cart-item {
    flex-wrap: wrap;
    gap: 10px 12px;
    padding: 12px 0 14px;
  }
  .cart-item img {
    width: 56px;
    height: 56px;
  }
  .cart-item__info {
    flex: 1 1 calc(100% - 68px);
  }
  .cart-item__qty {
    order: 2;
  }
  .cart-item__subtotal {
    order: 3;
    margin-left: auto;
    width: auto;
  }
  .cart-item__remove {
    position: absolute;
    top: 8px;
    right: 0;
    padding: 4px;
  }

  .btn-clear {
    display: block;
    width: 100%;
    font-size: 15px;
    padding: 12px 16px;
  }

  .radio-group {
    gap: 8px;
  }
  .radio-label {
    font-size: 12px;
    padding: 5px 8px;
  }
  .form-field input,
  .form-field textarea {
    padding: 8px 10px;
    font-size: 13px;
  }

  .cart-empty,
  .order-success {
    padding: 28px 14px;
  }
}
