/* ================================
   MARKETBLOX — CHECKOUT PAGE
   ================================ */

/* Page layout */
.co-main {
  min-height: 100vh;
  padding: 100px 2rem 4rem;
  background: var(--bg);
}

.co-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.co-title {
  font-family: var(--font-display);
  font-size: 2.2rem;
  font-weight: 900;
  color: var(--text);
  margin-bottom: 0.4rem;
}

.co-subtitle {
  color: var(--text2);
  font-size: 1rem;
}

.co-back {
  font-size: 0.9rem !important;
}

/* Two-column wrapper */
.co-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  max-width: 1100px;
  margin: 0 auto;
}

@media (max-width: 820px) {
  .co-wrap { grid-template-columns: 1fr; }
}

/* Card */
.co-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  padding: 1.75rem;
}

.co-card-header {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 1.5rem;
}

.co-card-header svg {
  color: var(--green);
  flex-shrink: 0;
}

.co-badge {
  background: var(--green);
  color: white;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 20px;
  margin-left: auto;
  font-family: var(--font-body);
}

/* Cart items list */
.co-items-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.co-empty {
  text-align: center;
  color: var(--text3);
  padding: 2rem 0;
  font-size: 0.95rem;
}

/* Single cart item row */
.co-item-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg);
  transition: border-color 0.2s;
}

.co-item-row:hover { border-color: var(--green); }

.co-item-img {
  width: 56px;
  height: 56px;
  border-radius: 10px;
  overflow: hidden;
  background: var(--green-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  flex-shrink: 0;
  position: relative;
}

.co-item-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.co-item-qty-badge {
  position: absolute;
  bottom: -4px;
  right: -4px;
  background: var(--green);
  color: white;
  font-size: 0.65rem;
  font-weight: 700;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid white;
}

.co-item-info {
  flex: 1;
  min-width: 0;
}

.co-item-name {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.co-item-game {
  font-size: 0.8rem;
  color: var(--text2);
  margin-top: 2px;
}

.co-item-price {
  font-weight: 700;
  color: var(--green);
  font-size: 1rem;
  white-space: nowrap;
}

/* Promo code box */
.co-promo {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}

.co-promo-input {
  flex: 1;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.6rem 0.9rem;
  font-family: var(--font-body);
  font-size: 0.9rem;
  color: var(--text);
  background: var(--bg);
  outline: none;
  transition: border-color 0.2s;
}

.co-promo-input:focus { border-color: var(--green); }

.co-promo-btn {
  background: var(--green);
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  padding: 0.6rem 1.1rem;
  font-weight: 700;
  font-family: var(--font-body);
  font-size: 0.9rem;
  cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
}

.co-promo-btn:hover { background: var(--green-dark); }

/* Pricing breakdown */
.co-pricing {
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: 1rem 1.1rem;
  margin-bottom: 1.5rem;
}

.co-price-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.92rem;
  color: var(--text2);
  padding: 0.3rem 0;
}

.co-price-divider {
  height: 1px;
  background: var(--border);
  margin: 0.6rem 0;
}

.co-price-total {
  font-weight: 700;
  color: var(--text);
  font-size: 1rem;
}

.co-total-amount {
  color: var(--green);
  font-size: 1.3rem;
  font-family: var(--font-display);
  font-weight: 900;
}

/* Form fields */
.co-field {
  margin-bottom: 1.2rem;
}

.co-label {
  display: block;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.45rem;
  letter-spacing: 0.01em;
}

.co-req {
  color: #ef4444;
  margin-left: 2px;
}

.co-optional {
  font-weight: 400;
  color: var(--text3);
  font-size: 0.82rem;
  margin-left: 4px;
}

.co-input {
  width: 100%;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.7rem 1rem;
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--text);
  background: var(--white);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.co-input:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px var(--green-glow);
}

.co-input.error {
  border-color: #ef4444;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.15);
}

.co-hint {
  display: block;
  font-size: 0.8rem;
  color: var(--text3);
  margin-top: 0.3rem;
}

.co-error-msg {
  display: block;
  font-size: 0.8rem;
  color: #ef4444;
  margin-top: 0.3rem;
  font-weight: 600;
}

/* Discord button */
.co-discord-btn {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  background: #5865F2;
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  padding: 0.65rem 1.2rem;
  font-family: var(--font-body);
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
  width: 100%;
  justify-content: center;
}

.co-discord-btn:hover { background: #4752c4; transform: translateY(-1px); }
.co-discord-btn:active { transform: translateY(0); }

.co-discord-linked {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--green-light);
  border: 1.5px solid var(--green);
  border-radius: var(--radius-sm);
  padding: 0.65rem 1rem;
  font-size: 0.9rem;
  color: var(--text);
  font-weight: 500;
}

/* Pay button */
.co-pay-btn {
  width: 100%;
  background: var(--green);
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  padding: 0.9rem;
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 800;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
  margin-bottom: 1rem;
  box-shadow: var(--shadow-green);
  letter-spacing: 0.02em;
}

.co-pay-btn:hover {
  background: var(--green-dark);
  transform: translateY(-2px);
  box-shadow: 0 12px 35px rgba(0, 200, 83, 0.4);
}

.co-pay-btn:active { transform: translateY(0); }
.co-pay-btn:disabled {
  opacity: 0.65;
  cursor: not-allowed;
  transform: none;
}

/* Trust strip */
.co-trust {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  margin-bottom: 0.75rem;
}

.co-trust-item {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.75rem;
  color: var(--text2);
  font-weight: 600;
}

.co-trust-item svg { color: var(--green); }

/* Powered by */
.co-powered {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  color: var(--text3);
}

.co-powered svg { color: var(--text3); }
