/* ══ PÁGINA CARRINHO ═════════════════════════════════════════ */

.cart-page {
  background: #f7f7f7;
  min-height: 60vh;
  padding: 32px 28px 64px;
}

.cart-page-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: 32px;
  align-items: start;
}

/* ── LADO ESQUERDO ───────────────────────────────────────── */
.cart-left { }

.cart-page-title {
  font-size: 22px;
  font-weight: 700;
  margin: 0 0 24px;
  color: #1a1a1a;
}

/* VAZIO */
.cart-empty {
  background: #fff;
  border-radius: 12px;
  padding: 64px 32px;
  text-align: center;
  box-shadow: 0 1px 4px rgba(0,0,0,.06);
}
.cart-empty-icon { font-size: 52px; margin-bottom: 16px; }
.cart-empty p { font-size: 18px; color: #555; margin: 0 0 24px; }
.cart-empty-btn {
  display: inline-block;
  background: #1aad4e;
  color: #fff;
  padding: 14px 32px;
  border-radius: 8px;
  font-weight: 700;
  text-decoration: none;
  font-size: 15px;
  transition: background .2s;
}
.cart-empty-btn:hover { background: #158a3e; }

/* CABEÇALHO DA LISTA */
.cart-items-header {
  display: grid;
  grid-template-columns: 1fr 120px 140px 120px;
  gap: 16px;
  padding: 10px 20px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  color: #888;
  letter-spacing: .04em;
  border-bottom: 2px solid #eee;
  background: #fff;
  border-radius: 12px 12px 0 0;
}

/* ITEM */
.cart-item-row {
  display: grid;
  grid-template-columns: 1fr 120px 140px 120px;
  gap: 16px;
  align-items: center;
  padding: 20px;
  background: #fff;
  border-bottom: 1px solid #f0f0f0;
}
.cart-item-row:last-child { border-bottom: none; border-radius: 0 0 12px 12px; }

.cart-item-prod {
  display: flex;
  align-items: center;
  gap: 16px;
}
.cart-item-prod img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 8px;
  background: #f5f5f5;
  flex-shrink: 0;
}
.cart-item-details { display: flex; flex-direction: column; gap: 4px; }
.cart-item-name { font-size: 14px; font-weight: 600; color: #1a1a1a; line-height: 1.4; }
.cart-item-link { font-size: 12px; color: #1aad4e; text-decoration: none; }
.cart-item-link:hover { text-decoration: underline; }

.cart-item-price-col,
.cart-item-qty-col,
.cart-item-total-col {
  font-size: 15px;
  font-weight: 600;
  color: #1a1a1a;
}
.cart-item-total-col {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* CONTROLE QUANTIDADE */
.qty-ctrl {
  display: flex;
  align-items: center;
  border: 1.5px solid #ddd;
  border-radius: 8px;
  overflow: hidden;
  width: fit-content;
}
.qty-ctrl button {
  background: #f5f5f5;
  border: none;
  width: 34px;
  height: 34px;
  font-size: 18px;
  cursor: pointer;
  color: #333;
  transition: background .15s;
  display: flex; align-items: center; justify-content: center;
}
.qty-ctrl button:hover { background: #eee; }
.qty-ctrl span {
  width: 42px;
  text-align: center;
  font-size: 15px;
  font-weight: 600;
}

/* REMOVER */
.cart-remove {
  background: none;
  border: none;
  color: #bbb;
  font-size: 16px;
  cursor: pointer;
  padding: 4px;
  line-height: 1;
  transition: color .15s;
}
.cart-remove:hover { color: #e03030; }

/* CONTINUAR COMPRANDO */
.cart-continue { padding: 16px 20px; }
.cart-continue-link {
  font-size: 13px;
  color: #1aad4e;
  text-decoration: none;
  font-weight: 600;
}
.cart-continue-link:hover { text-decoration: underline; }

/* ── LADO DIREITO: RESUMO ────────────────────────────────── */
.cart-right { position: sticky; top: 120px; }

.cart-summary-box {
  background: #fff;
  border-radius: 12px;
  padding: 24px;
  box-shadow: 0 1px 4px rgba(0,0,0,.08);
}
.cart-summary-box h2 {
  font-size: 18px;
  font-weight: 700;
  margin: 0 0 20px;
  color: #1a1a1a;
  padding-bottom: 16px;
  border-bottom: 2px solid #f0f0f0;
}

/* CUPOM */
.coupon-row {
  display: flex;
  gap: 8px;
  margin-bottom: 8px;
}
.coupon-input {
  flex: 1;
  border: 1.5px solid #ddd;
  border-radius: 8px;
  padding: 10px 14px;
  font-family: var(--font);
  font-size: 13px;
  outline: none;
  transition: border-color .2s;
}
.coupon-input:focus { border-color: #1aad4e; }
.coupon-btn {
  background: #1a1a1a;
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 10px 16px;
  font-family: var(--font);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: background .2s;
  white-space: nowrap;
}
.coupon-btn:hover { background: #333; }
.coupon-msg { font-size: 12px; margin-bottom: 12px; min-height: 18px; }
.coupon-msg.success { color: #1aad4e; }
.coupon-msg.error { color: #e03030; }

/* LINHAS DE TOTAL */
.summary-rows { margin: 16px 0; }
.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  font-size: 14px;
  color: #444;
  border-bottom: 1px solid #f5f5f5;
}
.summary-ship { }
.ship-free { color: #1aad4e; font-weight: 700; font-size: 13px; }
.discount-val { color: #1aad4e; font-weight: 700; }
.summary-total {
  font-size: 18px;
  font-weight: 800;
  color: #1a1a1a;
  border-bottom: none;
  padding-top: 14px;
  margin-top: 4px;
}

/* PIX */
.pix-info {
  background: #fff8f0;
  border: 1.5px solid #e07840;
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 13px;
  color: #555;
  margin-bottom: 12px;
  line-height: 1.5;
}
.pix-total { margin-top: 6px; font-size: 15px; color: #1a1a1a; }

/* PARCELAMENTO */
.inst-info {
  font-size: 12px;
  color: #888;
  text-align: center;
  margin-bottom: 16px;
}

/* BOTÕES */
.cart-checkout-btn-main {
  width: 100%;
  background: #1aad4e;
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 16px;
  font-family: var(--font);
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
  transition: background .2s;
  margin-bottom: 10px;
  display: block;
  text-align: center;
}
.cart-checkout-btn-main:hover { background: #158a3e; }

.cart-wa-btn-main {
  width: 100%;
  background: #25d366;
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 14px;
  font-family: var(--font);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  transition: background .2s;
  margin-bottom: 20px;
}
.cart-wa-btn-main:hover { background: #1db954; }

/* SELOS */
.trust-badges {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 20px;
}
.trust-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: #555;
  background: #f9f9f9;
  border-radius: 6px;
  padding: 8px 10px;
}

/* PAGAMENTOS */
.payment-methods { border-top: 1px solid #f0f0f0; padding-top: 16px; }
.payment-methods p { font-size: 12px; color: #888; margin: 0 0 10px; text-transform: uppercase; letter-spacing: .04em; font-weight: 600; }
.payment-icons-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.pay-icon {
  background: #f0f0f0;
  border-radius: 4px;
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 700;
  color: #444;
}
.pay-pix { background: #00bdae; color: #fff; }

/* ── RECOMENDADOS ────────────────────────────────────────── */
.cart-recommended {
  background: #fff;
  padding: 48px 28px;
  border-top: 2px solid #f0f0f0;
}
.cr-inner { max-width: 1280px; margin: 0 auto; }
.cr-inner h2 { font-size: 22px; font-weight: 800; margin: 0 0 28px; color: #1a1a1a; }
.cr-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.cr-card {
  text-decoration: none;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 1px 4px rgba(0,0,0,.07);
  transition: transform .2s, box-shadow .2s;
  display: block;
}
.cr-card:hover { transform: translateY(-3px); box-shadow: 0 6px 18px rgba(0,0,0,.12); }
.cr-img img { width: 100%; aspect-ratio: 4/3; object-fit: cover; display: block; }
.cr-info { padding: 14px; display: flex; flex-direction: column; gap: 4px; }
.cr-name { font-size: 13px; font-weight: 600; color: #1a1a1a; line-height: 1.4; }
.cr-badge { display: inline-block; background: #1aad4e; color: #fff; font-size: 11px; font-weight: 700; border-radius: 4px; padding: 2px 7px; }
.cr-price { font-size: 15px; font-weight: 800; color: #1aad4e; }

/* ── BREADCRUMB (reutiliza colecao.css) ──────────────────── */
.breadcrumb { padding: 12px 28px; font-size: 13px; color: #888; border-bottom: 1px solid #eee; background: #fff; }
.bc-inner { max-width: 1280px; margin: 0 auto; }
.bc-inner a { color: #888; text-decoration: none; }
.bc-inner a:hover { color: #e07840; }
.bc-inner span { margin: 0 6px; }

/* ── RESPONSIVE ──────────────────────────────────────────── */
@media (max-width: 900px) {
  .cart-page-inner { grid-template-columns: 1fr; }
  .cart-right { position: static; }
  .cart-items-header { display: none; }
  .cart-item-row { grid-template-columns: 1fr 1fr; grid-template-rows: auto auto; }
  .cart-item-prod { grid-column: 1 / -1; }
  .cr-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .cart-page { padding: 16px 12px 40px; }
  .cart-page-inner { gap: 16px; }
  .cart-items-title { font-size: 20px; }
  .cart-item-row { display: flex; flex-direction: column; gap: 10px; padding: 14px 0; }
  .cart-item-prod { display: flex; gap: 12px; align-items: flex-start; }
  .cart-item-img { width: 70px; height: 70px; border-radius: 6px; flex-shrink: 0; object-fit: cover; }
  .cr-img img { aspect-ratio: unset; height: 120px; }
  .cart-item-name { font-size: 13px; line-height: 1.3; }
  .cart-item-link { font-size: 11px; }
  .cart-item-price-col, .cart-item-total-col { font-size: 13px; }
  .cart-item-qty-col { display: flex; align-items: center; gap: 8px; }
  .qty-ctrl button { width: 30px; height: 30px; font-size: 16px; }
  .qty-ctrl span { font-size: 14px; min-width: 24px; }
  .cart-summary-box { padding: 16px 14px; }
  .cart-summary-title { font-size: 16px; }
  .summary-label, .summary-value { font-size: 13px; }
  .cart-checkout-btn-main { width: 100%; padding: 14px; font-size: 14px; }
  .cart-continue-link { font-size: 13px; }
  .coupon-row { flex-direction: column; }
  .coupon-input, .coupon-btn { width: 100%; }
  .cr-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .cr-card { border-radius: 8px; }
  .cr-name { font-size: 12px; }
}
@media (max-width: 400px) {
  .cart-page { padding: 12px 10px 32px; }
  .cart-item-img { width: 56px; height: 56px; }
  .cart-item-name { font-size: 12px; }
  .cr-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .cart-checkout-btn-main { font-size: 13px; padding: 12px; }
}
@media (max-width: 600px) {
  .cart-item-img { width: 70px !important; height: 70px !important; object-fit: cover; flex-shrink: 0; }
  .cr-img img   { height: 120px !important; width: 100%; object-fit: cover; aspect-ratio: unset !important; }
}

/* ── MODAL CHECKOUT ──────────────────────────────────────── */
.checkout-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.6);
  z-index: 9000;
}
.checkout-modal {
  position: fixed;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  background: #fff;
  border-radius: 16px;
  padding: 32px 28px 28px;
  width: 94%;
  max-width: 540px;
  max-height: 92vh;
  overflow-y: auto;
  z-index: 9001;
  flex-direction: column;
  gap: 0;
  box-shadow: 0 24px 64px rgba(0,0,0,.22);
}
.chk-x {
  position: absolute; top: 14px; right: 16px;
  background: none; border: none; font-size: 18px; color: #999; cursor: pointer;
}
.chk-x:hover { color: #333; }
.checkout-modal h2 { font-size: 20px; font-weight: 800; margin: 0 0 12px; color: #1a1a1a; }
.chk-subtotal-bar { background: #f0faf4; border-radius: 8px; padding: 10px 14px; font-size: 15px; color: #444; margin-bottom: 20px; }
.chk-subtotal-bar strong { color: #1aad4e; font-size: 18px; }

.chk-section { margin-bottom: 18px; }
.chk-label { display: block; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: #888; margin-bottom: 8px; }

/* Métodos */
.chk-methods { display: flex; gap: 8px; }
.chk-method {
  flex: 1; padding: 10px 8px; border: 2px solid #e0e0e0; border-radius: 10px;
  background: #fff; cursor: pointer; font-family: var(--font); font-size: 13px;
  font-weight: 600; color: #555; transition: all .15s; display: flex;
  align-items: center; justify-content: center; gap: 4px; flex-direction: column;
}
.chk-method:hover { border-color: #1aad4e; color: #1aad4e; }
.chk-method.active { border-color: #1aad4e; background: #f0faf4; color: #1aad4e; }
.chk-method-icon { font-size: 18px; }
.chk-method-tag { background: #e07840; color: #fff; font-size: 10px; border-radius: 4px; padding: 1px 5px; }

/* Formulário */
.chk-form { display: flex; flex-direction: column; gap: 8px; }
.chk-row { display: flex; gap: 8px; }
.chk-field { flex: 1; }
.chk-field input {
  width: 100%; padding: 10px 12px; border: 1.5px solid #ddd; border-radius: 8px;
  font-family: var(--font); font-size: 13px; outline: none; transition: border-color .2s;
  box-sizing: border-box;
}
.chk-field input:focus { border-color: #1aad4e; }
.chk-field input::placeholder { color: #bbb; }

/* Erro */
.chk-error { background: #fff0f0; border: 1px solid #ffcccc; border-radius: 8px; padding: 10px 14px; font-size: 13px; color: #c0392b; margin-bottom: 12px; }

/* Botão confirmar */
.chk-confirm-btn {
  width: 100%; background: #1aad4e; color: #fff; border: none; border-radius: 10px;
  padding: 16px; font-family: var(--font); font-size: 16px; font-weight: 800;
  cursor: pointer; transition: background .2s; margin-bottom: 10px;
}
.chk-confirm-btn:hover { background: #158a3e; }
.chk-confirm-btn:disabled { background: #aaa; cursor: not-allowed; }

.chk-secure { text-align: center; font-size: 12px; color: #aaa; margin: 0; }

/* PIX parcelado */
.chk-pix-inst {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  background: #fffbf0;
  border: 1.5px solid #f0c040;
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 13px;
  color: #7a5c00;
  font-weight: 600;
  margin-bottom: 16px;
  line-height: 1.5;
}
.chk-pix-inst-icon { font-size: 16px; flex-shrink: 0; margin-top: 1px; }
