/* ==============================
   Cart Page Styles
   ============================== */

/* !important: this is a utility class meant to unconditionally hide an
   element regardless of what else styles its display (e.g. .co-action-btn's
   display: inline-block in checkout_style.css, loaded later — without this,
   equal-specificity + later cascade order would silently win over .hidden). */
.hidden { display: none !important; }

.ct-main {
  padding: 36px 0 64px;
  max-width: 860px;
}

.ct-status {
  text-align: center;
  color: #888;
  padding: 80px 20px;
  font-size: 1.1rem;
}

.ct-status a {
  color: #bfa059;
  font-weight: 600;
}

.ct-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 28px;
}

.ct-row {
  display: grid;
  grid-template-columns: 96px 1fr auto;
  gap: 18px;
  align-items: start;
  padding: 18px;
  border: 1px solid #e8d9a0;
  border-radius: 12px;
  background: #fff;
}

.ct-row-unavailable {
  opacity: 0.6;
  background: #f7f7f7;
}

.ct-row-thumb img,
.ct-row-thumb-empty {
  width: 96px;
  height: 96px;
  border-radius: 8px;
  object-fit: contain;
  background: #fdf6e3;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
}

.ct-row-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ct-row-name {
  font-weight: 700;
  color: #333;
  text-decoration: none;
  font-size: 1.05rem;
}

.ct-row-name:hover { color: #bfa059; }

.ct-row-name-disabled {
  color: #999;
  cursor: default;
}

.ct-row-variant {
  color: #7a5c20;
  font-size: 0.85rem;
}

.ct-qty {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 4px;
}

.ct-qty-fixed {
  color: #888;
  font-size: 0.85rem;
}

.ct-qty-btn {
  width: 26px;
  height: 26px;
  border: 1px solid #bfa059;
  border-radius: 6px;
  background: #fff;
  color: #bfa059;
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
}

.ct-qty-btn:hover {
  background: #bfa059;
  color: #fff;
}

.ct-qty-val {
  min-width: 18px;
  text-align: center;
  font-weight: 600;
}

.ct-row-price-col {
  text-align: right;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
  min-width: 160px;
}

.ct-row-price {
  font-weight: 700;
  color: #333;
}

.ct-row-price-each {
  font-weight: 400;
  color: #999;
  font-size: 0.78rem;
}

.ct-row-line-total {
  font-size: 1.1rem;
  font-weight: 700;
  color: #bfa059;
}

.ct-unavailable-note {
  color: #b23b3b;
  font-size: 0.85rem;
  font-weight: 600;
}

.ct-price-changed {
  background: #fff3cd;
  border: 1px solid #f5d26b;
  border-radius: 6px;
  padding: 6px 8px;
  font-size: 0.78rem;
  color: #7a5c20;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
  text-align: right;
}

.ct-update-price-btn {
  border: 1px solid #bfa059;
  background: #fff;
  color: #bfa059;
  border-radius: 6px;
  padding: 3px 8px;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
}

.ct-update-price-btn:hover {
  background: #bfa059;
  color: #fff;
}

.ct-price-note {
  font-size: 0.75rem;
  color: #999;
}

.ct-remove-btn {
  border: none;
  background: none;
  color: #b23b3b;
  font-size: 0.8rem;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
}

.ct-summary {
  border-top: 2px solid #bfa059;
  padding-top: 20px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 16px;
}

.ct-summary-row {
  display: flex;
  gap: 24px;
  font-size: 1rem;
}

.ct-summary-total {
  font-size: 1.4rem;
  font-weight: 700;
  color: #333;
}

.ct-checkout-btn {
  display: inline-block;
  padding: 13px 28px;
  border: none;
  border-radius: 8px;
  background: #bfa059;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 700;
  font-family: 'Montserrat', sans-serif;
  text-decoration: none;
  cursor: pointer;
}

.ct-checkout-btn:hover { background: #a68a48; }

.ct-checkout-btn.disabled {
  background: #ccc;
  color: #666;
  cursor: not-allowed;
  pointer-events: none;
}

@media (max-width: 640px) {
  .ct-row {
    grid-template-columns: 72px 1fr;
  }
  .ct-row-price-col {
    grid-column: 1 / -1;
    align-items: flex-start;
    text-align: left;
  }
  .ct-row-thumb img,
  .ct-row-thumb-empty {
    width: 72px;
    height: 72px;
  }
}
