:root {
  --accent: #FF6B00;
  --gray-200: #E5E7EB;
}

#shopping-cart .table-bordered{
   width:100%;
}

#shopping-cart h2{
   margin-top:20px;
}

// ---

.btn-primary {
  display: inline-block; padding: 14px 32px; border-radius: 12px;
  background: var(--accent); color: #fff; text-decoration: none;
  font-weight: 700; font-size: 15px;
  transition: background .2s;
}

.cart-back-link {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; color: var(--accent); text-decoration: none; font-weight: 600;
}
.cart-back-link:hover { text-decoration: underline; }

.cart-page { padding: 16px; max-width: 1120px; margin: 0 auto; }
.cart-title { font-size: 22px; font-weight: 800; margin-bottom: 16px; }
.cart-title-count { font-weight: 400; color: var(--gray-400); font-size: 18px; }

/* Empty cart */
.cart-empty {
  text-align: center; padding: 48px 16px;
}
.cart-empty-icon { font-size: 56px; margin-bottom: 16px; }
.cart-empty h2 { font-size: 20px; margin-bottom: 8px; }
.cart-empty p { color: var(--gray-400); margin-bottom: 24px; font-size: 14px; }
.btn-primary {
  display: inline-block; padding: 14px 32px; border-radius: 12px;
  background: var(--accent); color: #fff; text-decoration: none;
  font-weight: 700; font-size: 15px;
  transition: background .2s;
}
.btn-primary:hover { background: #e55a00; }

/* Cart layout */
.cart-content { display: flex; flex-direction: column; gap: 0; }
.cart-main { display: flex; flex-direction: column; gap: 0; }

/* Sections */
.cart-section {
  padding: 20px 0; border-bottom: 1px solid var(--gray-100);
}
.cart-section:first-child { padding-top: 0; }
.cart-section h2 { font-size: 17px; font-weight: 700; margin-bottom: 14px; }
.cart-section-head {
  display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px;
}
.cart-section-head h2 { margin-bottom: 0; }
.cart-clear-btn {
  border: none; background: none; color: #EF4444; font-size: 13px;
  cursor: pointer; font-weight: 600; font-family: inherit;
}

/* Cart item */
.cart-item {
  display: grid;
  grid-template-columns: 48px 1fr auto auto;
  grid-template-rows: auto;
  gap: 10px; align-items: center;
  padding: 12px 0; border-bottom: 1px solid var(--gray-100);
}
.cart-item:last-child { border-bottom: none; }
.cart-item-img {
  width: 48px; height: 48px; border-radius: 10px;
  background: var(--gray-50); display: flex; align-items: center; justify-content: center;
  font-size: 24px;
}
.cart-item-info { min-width: 0; }
.cart-item-name {
  font-size: 14px; font-weight: 600; line-height: 1.3;
  overflow: hidden; text-overflow: ellipsis;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.cart-item-price { font-size: 13px; color: var(--gray-400); margin-top: 2px; }
.cart-item-qty {
  display: flex; align-items: center; gap: 0;
  border: 1px solid var(--gray-200); border-radius: 8px; overflow: hidden;
}
.qty-btn {
  width: 32px; height: 32px; border: none; background: none;
  cursor: pointer; font-size: 16px; font-family: inherit;
  display: flex; align-items: center; justify-content: center;
  transition: background .15s;
}
.qty-btn:hover { background: var(--gray-50); }
.qty-val {
  width: 28px; text-align: center; font-size: 14px; font-weight: 600;
  border-left: 1px solid var(--gray-200); border-right: 1px solid var(--gray-200);
  line-height: 32px;
}
.cart-item-subtotal {
  font-size: 14px; font-weight: 700; white-space: nowrap;
  display: none;
}
.cart-item-del {
  border: none; background: none; cursor: pointer; color: var(--gray-300);
  padding: 4px; transition: color .15s;
}
.cart-item-del:hover { color: #EF4444; }

/* Form */
.form-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
.form-field { display: flex; flex-direction: column; gap: 4px; }
.form-field label {
  font-size: 13px; font-weight: 600; color: var(--gray-500);
}
.form-field input, .form-field select {
  padding: 12px 14px; border: 1.5px solid var(--gray-200); border-radius: 10px;
  font-size: 15px; font-family: inherit; background: #fff;
  transition: border-color .2s, box-shadow .2s;
  -webkit-appearance: none; appearance: none;
}
.form-field .select2 {
  padding-right: 36px;
  padding: 12px 14px; border: 1.5px solid var(--gray-200); border-radius: 10px;
  font-size: 15px; font-family: inherit; background: #fff;
  transition: border-color .2s, box-shadow .2s;
  -webkit-appearance: none; appearance: none;
}
.form-field input:focus, .form-field select:focus, .form-field .select2-container--open {
  outline: none; border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(255,107,0,.12);
}
.select2-dropdown {
   border: 1.5px solid var(--gray-200);
}
.form-field .select2-container--default .select2-selection--single{
  border: none;
}
.form-field .select2-container--default .select2-selection--single .select2-selection__arrow {
   top: 15px; right: 13px;
}
.form-field.has-error input, .form-field.has-error select, .form-field.has-error .select2-container {
  border-color: #EF4444;
  box-shadow: 0 0 0 3px rgba(239,68,68,.12);
}
.field-error {
  font-size: 12px; color: #EF4444; min-height: 0;
}

/* Delivery options */
.delivery-options { display: flex; flex-direction: column; gap: 10px; margin-top: 14px; }
.delivery-option {
  display: block; cursor: pointer;
  border: 1.5px solid var(--gray-200); border-radius: 12px;
  transition: border-color .2s, box-shadow .2s;
}
.delivery-option input { position: absolute; opacity: 0; width: 0; height: 0; }
.delivery-option.active {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(255,107,0,.12);
}
.delivery-option-body {
  display: flex; align-items: center; gap: 12px; padding: 14px;
}
.delivery-option-icon { font-size: 24px; flex-shrink: 0; }
.delivery-option-info { flex: 1; min-width: 0; }
.delivery-option-info strong { display: block; font-size: 14px; }
.delivery-option-info div { font-size: 12px; color: var(--gray-400); padding-top: 5px; }
.delivery-option-info span { font-size: 12px; color: var(--gray-400); }
.delivery-option-price {
  font-size: 14px; font-weight: 700; color: var(--accent); white-space: nowrap;
}
.delivery-options.inactive{
    cursor: not-allowed !important;
    filter: grayscale(100%);
}
.delivery-options.inactive .delivery-option{
    cursor: not-allowed !important;
}
/* Payment */
.payment-options { display: flex; flex-direction: column; gap: 8px; }
.payment-option {
  display: block; cursor: pointer;
  border: 1.5px solid var(--gray-200); border-radius: 10px;
  transition: border-color .2s;
}
.payment-option input { position: absolute; opacity: 0; width: 0; height: 0; }
.payment-option.active { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(255,107,0,.12); }
.payment-option-body {
  display: flex; align-items: center; gap: 10px; padding: 12px 14px;
  font-size: 14px; font-weight: 600;
}
.payment-icon { font-size: 20px; }

/* Promo */
.promo-row { display: flex; gap: 8px; }
.promo-input {
  flex: 1; padding: 12px 14px; border: 1.5px solid var(--gray-200); border-radius: 10px;
  font-size: 15px; font-family: inherit;
  transition: border-color .2s;
}
.promo-input:focus { outline: none; border-color: var(--accent); }
.promo-btn {
  padding: 12px 20px; border: none; border-radius: 10px;
  background: var(--dark); color: #fff; font-weight: 700; font-size: 14px;
  cursor: pointer; font-family: inherit; white-space: nowrap;
  transition: background .2s;
}
.promo-btn:hover { background: #333; }
.promo-msg { font-size: 13px; margin-top: 8px; }
.promo-ok { color: #16a34a; }
.promo-err { color: #EF4444; }

/* Sidebar summary */
.cart-sidebar { margin-top: 8px; }
.cart-summary {
  background: #F9FAFB; border-radius: 16px; padding: 20px;
  position: sticky; top: 80px;
}
.cart-summary h3 { font-size: 18px; font-weight: 800; margin-bottom: 14px; }
.summary-row {
  display: flex; justify-content: space-between; font-size: 14px; padding: 6px 0;
}
.summary-row.summary-total { font-size: 18px; font-weight: 800; padding: 10px 0 0; }
.promo-discount span:last-child { color: #16a34a; font-weight: 600; }
.btn-order {
  display: block; width: 100%; padding: 16px; border: none; border-radius: 12px;
  background: var(--accent); color: #fff;
  font-size: 16px; font-weight: 700; cursor: pointer; font-family: inherit;
  margin-top: 16px; transition: background .2s, transform .15s;
}
.btn-order:hover { background: #e55a00; }
.btn-order:active { transform: scale(.98); }
.summary-note {
  font-size: 11px; color: var(--gray-400); margin-top: 12px; line-height: 1.4;
}





@media (min-width: 1024px) {
  .cart-page { padding: 24px 32px; }
  .cart-title { font-size: 28px; }
  .form-grid { grid-template-columns: 1fr 1fr; }
  .cart-item { grid-template-columns: 56px 1fr auto auto auto; }
  .cart-item-img { width: 56px; height: 56px; font-size: 28px; }
  .cart-item-subtotal { display: block; }
  .delivery-options { flex-direction: row; }
  .delivery-option { flex: 1; }
  .payment-options { flex-direction: row; flex-wrap: wrap; }
  .payment-option { flex: 1; min-width: 140px; }
  .cart-content {
    flex-direction: row; gap: 32px;
  }
  .cart-main { flex: 1; min-width: 0; }
  .cart-sidebar { width: 340px; flex-shrink: 0; margin-top: 0; }
}