:root {
  --ink: #1b1f23;
  --muted: #5b6470;
  --line: #dde1e6;
  --surface: #ffffff;
  --bg: #f3f5f7;
  --accent: #0a4d8c;
  --accent-hover: #073a6b;
  --success: #1b7a4d;
  --error: #b3261e;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  font-family: -apple-system, "Segoe UI", "Tahoma", Arial, sans-serif;
  color: var(--ink);
  padding: 24px;
  direction: rtl;
  text-align: right;
}

.checkout-card {
  width: 100%;
  max-width: 420px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 28px 24px;
}

.badge {
  display: inline-block;
  font-size: 12px;
  color: var(--accent);
  background: #eaf2fa;
  border-radius: 999px;
  padding: 4px 10px;
  margin: 0 0 12px;
}

h1 {
  font-size: 22px;
  margin: 0 0 6px;
}

.amount-line {
  color: var(--muted);
  margin: 0 0 22px;
  font-size: 14px;
}

label {
  display: block;
  font-size: 13px;
  color: var(--muted);
  margin: 14px 0 6px;
}

.field-container {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px 12px;
  min-height: 42px;
  background: var(--surface);
}

.row {
  display: flex;
  gap: 12px;
}

.col {
  flex: 1;
  min-width: 0;
}

button {
  width: 100%;
  margin-top: 22px;
  padding: 12px;
  border: none;
  border-radius: 6px;
  background: var(--accent);
  color: #fff;
  font-size: 15px;
  cursor: pointer;
}

button:hover {
  background: var(--accent-hover);
}

#result-message {
  min-height: 20px;
  margin-top: 16px;
  font-size: 14px;
  text-align: center;
}

#result-message.success { color: var(--success); }
#result-message.error { color: var(--error); }
.hidden { display: none !important; }
.status-box { padding: 12px; border-radius: 8px; background: #f3f4f6; margin: 12px 0; font-size: 14px; }
.status-box.error { background: #fdecea; color: #b3261e; }
.status-box.success { background: #e6f4ea; color: #1e7e34; font-weight: bold; }
.cart-items-list { list-style: none; padding: 0; margin: 0 0 12px 0; }
.cart-items-list li { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid #eee; font-size: 14px; }
.totals-row { display: flex; justify-content: space-between; padding: 8px 0; font-size: 15px; }
.totals-row.grand-total { border-top: 1px solid #ddd; margin-top: 4px; padding-top: 10px; font-size: 17px; }
#address-form label, #payment-section label { display: block; margin-bottom: 12px; font-size: 14px; }
#address-form input, #address-form select { width: 100%; padding: 10px; margin-top: 4px; border: 1px solid #ccc; border-radius: 6px; box-sizing: border-box; font-size: 15px; }
.card-row { display: flex; gap: 12px; }
.card-row label { flex: 1; }
.link-button { background: none; border: none; color: #0066cc; text-decoration: underline; cursor: pointer; font-size: 13px; padding: 0; }
#address-submit-btn, #pay-button { width: 100%; padding: 14px; border: none; border-radius: 8px; background: #1a1a2e; color: white; font-size: 16px; cursor: pointer; margin-top: 8px; }
#pay-button:disabled, #address-submit-btn:disabled { opacity: 0.5; cursor: not-allowed; }
.required-mark { color: #b3261e; }
#continue-to-payment-btn, #pay-button {
  width: 100%;
  padding: 14px;
  border: none;
  border-radius: 8px;
  background: #1a1a2e;
  color: white;
  font-size: 16px;
  cursor: pointer;
  margin-top: 8px;
}

#continue-to-payment-btn:disabled, #pay-button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  background: #9a9a9a;
}

#shipping-summary-section {
  background: #f0f7ff;
  border: 1px solid #b6d4fe;
  border-radius: 8px;
  padding: 10px 14px;
  margin: 10px 0;
}

.status-box.warning { background: #fff3cd; color: #856404; }
