/* ============================================================
   TIẾN PERFUME - CART
   Style riêng cho trang Giỏ hàng. Mọi selector scope trong .tp-cart
   để KHÔNG ảnh hưởng các trang khác.

   Font:
   - Tiêu đề  -> Playfair (var --tp-font-title)
   - Nội dung -> Inter    (var --tp-font-body)
   - Đậm tối đa: 600
   ============================================================ */

@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&family=Playfair+Display:wght@500;600&display=swap");

.tp-cart {
  --tp-gold: #c8954a;
  --tp-gold-dark: #b07e35;
  --tp-dark: #1c1c1c;
  --tp-border: #e6e6e6;
  --tp-text: #1f2937;
  --tp-muted: #6b7280;
  --tp-red: #dc2626;
  --tp-green: #16a34a;
  --tp-radius: 8px;

  --tp-font-title: "Playfair Display", "Playfair", Georgia, serif;
  --tp-font-body:
    "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica,
    Arial, sans-serif;

  background: #fff;
  color: var(--e-global-color-text);
  padding: 40px 60px;
  font-family: var(--tp-font-body);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.6;
  overflow: hidden;
}

.tp-cart * {
  box-sizing: border-box;
}

.tp-cart .tp-container {
  max-width: 100%;
  margin: 0 auto;
}
.woocommerce-billing-fields h3 {
	display: none;
}
/* ===================== BREADCRUMB + TIÊU ĐỀ ===================== */
.tp-cart__heading {
  margin: 12px 0 24px;
}

.tp-cart__heading h1 {
  font-family: var(--tp-font-title);
  font-size: 38px;
  font-weight: 600;
  line-height: 1.4;
  margin: 0 0 6px;
  text-transform: uppercase;
  color: var(--e-global-color-text);
}

.tp-cart__heading p {
  margin: 0;
  font-family: var(--tp-font-body);
  color: var(--e-global-color-text);
  font-size: 16px;
}

/* ===================== LƯỚI 2 CỘT ===================== */
.tp-cart__grid {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 30px;
  align-items: start;
}

/* ===================== BẢNG SẢN PHẨM ===================== */
.tp-cart__main {
  padding: 24px;
  border: 1px solid #e2e0db;
  border-radius: 8px;
  box-shadow: 0px 0px 20px 0px #eeeeee;
}

.tp-cart__table {
  width: 100%;
}

.tp-cart__thead,
.tp-cart__row {
  display: grid;
  grid-template-columns: 1fr 130px 150px 140px;
  align-items: center;
  gap: 12px;
}

.tp-cart__thead {
  padding: 0 0 14px;
  border-bottom: 1px solid #e6e6e6;
  font-size: 14px;
  color: var(--e-global-color-text);
  font-weight: 600;
}

.tp-cart__thead .col-price,
.tp-cart__thead .col-qty,
.tp-cart__thead .col-subtotal {
  text-align: center;
}

.tp-cart__row {
  padding: 24px 0;
  border-bottom: 1px solid var(--tp-border);
}

/* Cột sản phẩm: ảnh + thông tin */
.tp-cart__row .col-product {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.tp-cart__thumb img {
  width: 375px;
  height: 145px;
  object-fit: cover;
  display: block;
}

.tp-cart__info {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.tp-cart__brand {
  color: var(--tp-gold);
  font-size: 14px;
  font-weight: 400;
  line-height: 1.4;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.tp-cart__name {
  font-family: var(--tp-font-title);
  font-size: 18px;
  font-weight: 600;
  color: var(--e-global-color-text);
  text-decoration: none;
  line-height: 1.4;
  text-transform: uppercase;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tp-cart__name:hover {
  color: var(--tp-gold);
}

.tp-cart__meta {
  font-size: 13px;
  color: var(--tp-muted);
}

.tp-cart__meta p {
  margin: 0;
}

.tp-cart__badge {
  display: flex;
  align-items: center;
  font-size: 14px;
  line-height: 1.6;
  color: var(--tp-gold-dark);
  margin-top: 8px;
  gap: 8px;
}

.tp-cart__badge svg {
  width: 16px;
  height: 16px;
}

.tp-cart__actions {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-top: 8px;
  font-size: 14px;
  line-height: 1.6;
}

.tp-cart__actions a {
  color: var(--e-global-color-text);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.tp-cart__actions a:hover {
  color: var(--tp-gold);
}

.tp-cart__remove:hover {
  color: var(--tp-red);
}

.tp-cart__actions a svg {
  width: 18px;
  height: 18px;
}

/* Cột giá / thành tiền */
.tp-cart__row .col-price,
.tp-cart__row .col-subtotal {
  text-align: center;
  font-weight: 600;
}

.tp-cart__row .col-subtotal {
  color: var(--tp-gold-dark);
  font-weight: 600;
  font-size: 16px;
}

.tp-cart__row .col-price del {
  color: var(--tp-muted);
  font-weight: 400;
  font-size: 13px;
  display: block;
}

/* Stepper số lượng */
.tp-cart__row .col-qty {
  display: flex;
  justify-content: center;
}

.tp-qty {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--tp-border);
  border-radius: var(--tp-radius);
  overflow: hidden;
}

.tp-qty__btn {
  width: 40px;
  height: 40px;
  border: 0;
  color: var(--e-global-color-text);
  font-family: var(--tp-font-body);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  transition: background 0.15s ease;
}

.tp-qty__btn:hover {
  background: #ededf0;
  color: var(--tp-gold-dark);
}

.tp-qty__input {
  width: 40px !important;
  height: 40px;
  border: 0 !important;
  text-align: center;
  font-family: var(--tp-font-body);
  font-size: 16px;
  font-weight: 600;
  background: #fff;
  -moz-appearance: textfield;
  appearance: textfield;
}

.tp-qty__input::-webkit-outer-spin-button,
.tp-qty__input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* ===================== THANH NÚT DƯỚI BẢNG ===================== */
.tp-cart__toolbar {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  margin-top: 22px;
}

/* ===================== NÚT CHUNG ===================== */
.tp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--tp-radius);
  font-family: var(--tp-font-body);
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid var(--tp-gold);
  background: #fff;
  color: var(--tp-gold-dark);
  transition: all 0.3s ease;
}

.tp-btn--ghost:hover {
  background: var(--tp-gold);
  color: #fff;
}

.tp-btn--primary {
  border: 0;
  background: linear-gradient(180deg, #d3a258 0%, var(--tp-gold) 100%);
  color: #fff;
}

.tp-btn--primary:hover {
  filter: brightness(1.05);
  color: #fff;
}

.tp-btn[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
}

/* ===================== CARD TÓM TẮT (cột phải) ===================== */
.tp-cart .tp-card {
  background: #fff;
  border: 1px solid var(--tp-border);
  border-radius: var(--tp-radius);
  overflow: hidden;
  position: sticky;
  top: 20px;
  padding: 24px;
  box-shadow: 0px 0px 20px 0px #eeeeee;
}

.tp-cart .tp-card__head {
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: #fff;
  color: var(--e-global-color-text);
  font-family: var(--tp-font-title);
  font-weight: 600;
  font-size: 18px;
  line-height: 1.4;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.tp-cart .tp-card__head::after {
  content: "";
  display: inline-flex;
  width: 36px;
  height: 2px;
  background-color: var(--e-global-color-secondary);
}

.tp-sum__row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 9px 0;
  font-size: 14.5px;
}

.tp-sum__row span:first-child {
  color: var(--tp-muted);
}

.tp-sum__row span:last-child {
  font-weight: 600;
}

.tp-sum__row--discount span:last-child {
  color: var(--tp-red);
  font-weight: 600;
}

.tp-free {
  color: var(--tp-gold-dark);
  font-weight: 600;
}

/* Mã giảm giá */
.tp-coupon {
  display: flex;
  margin: 12px 0 4px;
  border: 1px solid var(--tp-border);
  border-radius: var(--tp-radius);
  overflow: hidden;
}

.tp-coupon__input {
  flex: 1 1 auto;
  border: 0;
  padding: 12px 14px;
  font-family: var(--tp-font-body);
  font-size: 14px;
  outline: none;
  min-width: 0;
}

.tp-coupon__btn {
  flex: 0 0 auto;
  border: 0;
  background: #faf3e8;
  color: var(--tp-gold-dark);
  font-family: var(--tp-font-body);
  font-weight: 600;
  font-size: 13px;
  padding: 0 18px;
  cursor: pointer;
  letter-spacing: 0.3px;
  transition: background 0.15s ease;
}

.tp-coupon__btn:hover {
  background: #f3e6cf;
}

/* Thành tiền */
.tp-sum__total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 0;
  margin-top: 6px;
  border-top: 1px solid var(--tp-border);
}

.tp-sum__total-label {
  display: block;
  font-family: var(--tp-font-body);
  font-weight: 600;
  font-size: 16px;
  text-transform: uppercase;
}

.tp-sum__total small {
  color: var(--tp-muted);
  font-size: 14px;
}

.tp-sum__total-value {
  color: var(--tp-gold-dark);
  font-weight: 600;
  font-size: 24px;
  white-space: nowrap;
}

/* Quyền lợi */
.tp-sum__perks {
  list-style: none;
  margin: 4px 0 18px;
  padding: 16px;
  background: #faf7f1;
  border: 1px solid #efe6d6;
  border-radius: var(--tp-radius);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.tp-sum__perks li {
  display: flex;
  align-items: center;
  gap: 14px;
}

.tp-sum__perks .ico {
  font-size: 18px;
  line-height: 1.2;
}

.tp-sum__perks b {
  display: block;
  font-weight: 600;
  font-size: 14px;
}

.tp-sum__perks small {
  color: var(--tp-muted);
  font-size: 14px;
}

.tp-checkout-btn {
  width: 100%;
  padding: 16px;
  font-size: 15px;
}

.tp-sum__secure {
	display: flex;
    text-align: center;
    color: var(--tp-muted);
    font-size: 14px;
    margin: 12px 0 0;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

/* ===================== GIỎ HÀNG TRỐNG ===================== */
.tp-cart__empty {
  text-align: center;
  background: #fff;
  border: 1px solid var(--tp-border);
  border-radius: var(--tp-radius);
  padding: 56px 24px;
}

.tp-cart__empty p {
  margin: 0 0 18px;
  font-size: 16px;
  color: var(--tp-muted);
}

/* ===================== THÔNG BÁO WOOCOMMERCE ===================== */
.tp-cart .woocommerce-message,
.tp-cart .woocommerce-error,
.tp-cart .woocommerce-info {
  list-style: none;
  margin: 0 0 20px;
  padding: 14px 18px;
  border-radius: var(--tp-radius);
  background: #fff;
  border: 1px solid var(--tp-border);
  border-left: 4px solid var(--tp-gold);
}

.tp-cart .woocommerce-error {
  border-left-color: var(--tp-red);
}

/* ===================== RESPONSIVE ===================== */
@media (max-width: 1024px) {
  .tp-cart {
    padding: 28px 24px 56px;
  }

  .tp-cart__grid {
    grid-template-columns: 1fr;
  }

  .tp-cart .tp-card {
    position: static;
  }

  .tp-suggest__card {
    flex-basis: calc(33.333% - 14px);
  }
}

@media (max-width: 760px) {
  .tp-cart__heading h1 {
    font-size: 28px;
  }

  /* Bảng -> dạng thẻ cho mobile */
  .tp-cart__thead {
    display: none;
  }

  .tp-cart__row {
    grid-template-columns: 1fr 1fr;
    gap: 14px 12px;
  }

  .tp-cart__row .col-product {
    grid-column: 1 / -1;
  }

  .tp-cart__row .col-price,
  .tp-cart__row .col-qty,
  .tp-cart__row .col-subtotal {
    text-align: left;
    justify-content: flex-start;
  }

  .tp-cart__row .col-price::before,
  .tp-cart__row .col-subtotal::before {
    content: attr(data-title) ": ";
    color: var(--tp-muted);
    font-weight: 500;
    font-size: 12.5px;
    display: block;
  }

  .tp-cart__toolbar {
    flex-direction: column;
  }

  .tp-cart__toolbar .tp-btn {
    width: 100%;
  }

  .tp-suggest__card {
    flex-basis: calc(50% - 10px);
    min-width: 160px;
  }

  .tp-suggest__viewport {
    padding: 0 12px;
  }

  .tp-suggest__nav {
    display: none;
  }
}
