/* หน้าชำระเงิน — โทน ec-shop */
.ec-checkout-body .site-main {
  padding-top: 0;
}

/* ---------- login gate ---------- */
.ec-checkout-login-wrap {
  max-width: 520px;
  margin: 40px auto 56px;
  padding: 0 16px;
}

.ec-checkout-login-card {
  background: #fff;
  border: 1px solid var(--ec-line, #e2e8f0);
  border-radius: 8px;
  box-shadow: 0 12px 40px rgba(15, 39, 68, 0.08);
  overflow: hidden;
}

.ec-checkout-login-head {
  text-align: center;
  padding: 32px 28px 20px;
  background: linear-gradient(180deg, #f8fafc 0%, #fff 100%);
  border-bottom: 1px solid #eef2f7;
}

.ec-checkout-login-icon {
  width: 72px;
  height: 72px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background: linear-gradient(145deg, #0f2744 0%, #1e4976 100%);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 30px;
  box-shadow: 0 8px 24px rgba(15, 39, 68, 0.25);
}

.ec-checkout-login-title {
  margin: 0 0 8px;
  font-family: 'Kanit', sans-serif;
  font-size: 1.35rem;
  font-weight: 500;
  color: var(--ec-navy, #0f2744);
  letter-spacing: -0.02em;
}

.ec-checkout-login-lead {
  margin: 0;
  font-size: 14px;
  line-height: 1.55;
  color: var(--ec-muted, #64748b);
  max-width: 36em;
  margin-left: auto;
  margin-right: auto;
}

.ec-checkout-login-steps {
  list-style: none;
  margin: 0;
  padding: 16px 24px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 12px;
  background: #f8fafc;
  border-bottom: 1px solid #eef2f7;
}

.ec-checkout-login-steps li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: #475569;
  font-family: 'Kanit', sans-serif;
  padding: 6px 12px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
}

.ec-checkout-login-steps li i {
  color: #1e4976;
  font-size: 11px;
}

.ec-checkout-login-form {
  padding: 24px 28px 8px;
}

.ec-checkout-login-alert {
  margin-bottom: 14px;
  padding: 10px 14px;
  border-radius: 4px;
  font-size: 13px;
  font-family: 'Kanit', sans-serif;
  line-height: 1.45;
  text-align: left;
}

.ec-checkout-login-alert.is-error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #b91c1c;
}

.ec-checkout-login-alert.is-success {
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #047857;
}

.ec-input-icon {
  position: relative;
  display: flex;
  align-items: center;
}

.ec-input-icon > i:first-child {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  text-align: center;
  color: #94a3b8;
  font-size: 15px;
  line-height: 1;
  pointer-events: none;
  z-index: 1;
}

.ec-input-icon input {
  width: 100%;
  box-sizing: border-box;
  min-height: 46px;
  padding: 0 44px 0 46px;
  border: 1.5px solid var(--ec-line, #e2e8f0);
  border-radius: 6px;
  font-family: 'Kanit', sans-serif;
  font-size: 14px;
  line-height: 46px;
  color: var(--ec-text, #0f172a);
  background: #fff;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.ec-input-icon input::placeholder {
  color: #94a3b8;
  opacity: 1;
  line-height: normal;
}

.ec-input-icon input:focus {
  outline: none;
  border-color: #1e4976;
  box-shadow: 0 0 0 3px rgba(30, 73, 118, 0.12);
}

.ec-input-eye {
  position: absolute;
  top: 50%;
  right: 8px;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border: 0;
  background: transparent;
  color: #64748b;
  cursor: pointer;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ec-input-eye:hover {
  color: var(--ec-navy, #0f2744);
  background: #f1f5f9;
}

.ec-btn-login-primary {
  width: 100%;
  margin-top: 8px;
  padding: 14px 20px;
  border: 0;
  border-radius: 6px;
  background: linear-gradient(180deg, #1e4976 0%, #0f2744 100%);
  color: #fff;
  font-family: 'Kanit', sans-serif;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 4px 14px rgba(15, 39, 68, 0.28);
  transition: transform 0.15s, box-shadow 0.2s, opacity 0.2s;
}

.ec-btn-login-primary:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(15, 39, 68, 0.35);
}

.ec-btn-login-primary:active:not(:disabled) {
  transform: translateY(0);
}

.ec-btn-login-primary:disabled {
  opacity: 0.65;
  cursor: wait;
}

.ec-checkout-login-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 28px 0;
  color: #94a3b8;
  font-size: 12px;
  font-family: 'Kanit', sans-serif;
}

.ec-checkout-login-divider::before,
.ec-checkout-login-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #e2e8f0;
}

.ec-checkout-login-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px 28px 28px;
}

.ec-btn-login-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 12px 18px;
  border: 1.5px solid var(--ec-navy, #0f2744);
  border-radius: 6px;
  background: #fff;
  color: var(--ec-navy, #0f2744) !important;
  text-decoration: none;
  font-family: 'Kanit', sans-serif;
  font-size: 14px;
  font-weight: 500;
  transition: background 0.2s, color 0.2s;
}

.ec-btn-login-secondary:hover {
  background: rgba(15, 39, 68, 0.06);
}

.ec-btn-login-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 10px 18px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #64748b !important;
  text-decoration: none;
  font-family: 'Kanit', sans-serif;
  font-size: 13px;
  transition: color 0.2s, background 0.2s;
}

.ec-btn-login-ghost:hover {
  color: var(--ec-navy, #0f2744) !important;
  background: #f8fafc;
}

.ec-checkout-login-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: var(--ec-navy, #0f2744);
  color: #fff !important;
  text-decoration: none;
  border-radius: 4px;
  font-family: 'Kanit', sans-serif;
  border: 0;
  cursor: pointer;
  font-size: 14px;
}

.ec-checkout-shell {
  max-width: 1180px;
  margin: 0 auto;
  padding: 24px 16px 56px;
}

.ec-checkout-title {
  margin: 0 0 6px;
  font-size: clamp(1.2rem, 2vw, 1.5rem);
  font-weight: 500;
  color: var(--ec-navy, #0f2744);
  font-family: 'Kanit', sans-serif;
}

.ec-checkout-sub {
  margin: 0 0 24px;
  color: var(--ec-muted, #64748b);
  font-size: 14px;
}

.ec-checkout-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 380px);
  gap: 24px;
  align-items: start;
}

.ec-checkout-panel {
  background: #fff;
  border: 1px solid var(--ec-line, #e2e8f0);
  border-radius: 4px;
  padding: 20px;
  margin-bottom: 20px;
}

.ec-checkout-panel h3 {
  margin: 0 0 16px;
  font-size: 15px;
  font-weight: 500;
  color: var(--ec-navy, #0f2744);
  font-family: 'Kanit', sans-serif;
  display: flex;
  align-items: center;
  gap: 8px;
}

.ec-checkout-items {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ec-checkout-item {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding-bottom: 12px;
  border-bottom: 1px solid #f1f5f9;
}

.ec-checkout-item:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.ec-checkout-item img {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: 4px;
  background: #f1f5f9;
}

.ec-checkout-item-name {
  font-size: 14px;
  color: var(--ec-text, #0f172a);
  margin-bottom: 4px;
}

.ec-checkout-item-meta {
  font-size: 12px;
  color: var(--ec-muted, #64748b);
}

.ec-checkout-item-price {
  font-size: 14px;
  font-weight: 500;
  color: var(--ec-navy, #0f2744);
  white-space: nowrap;
}

.ec-address-lead {
  font-size: 13px;
  color: var(--ec-muted, #64748b);
  margin: -4px 0 14px;
  line-height: 1.5;
}

.ec-address-lead a {
  color: var(--ec-navy, #0f2744);
  font-weight: 500;
  text-decoration: underline;
}

.ec-address-mode {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

.ec-address-mode.is-hidden {
  display: none;
}

.ec-address-mode-btn {
  flex: 1;
  min-width: 140px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  border: none;
  border-radius: 6px;
  background: #f8fafc;
  font-family: 'Kanit', sans-serif;
  font-size: 13px;
  color: var(--ec-muted, #64748b);
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

.ec-address-mode-btn:hover {
  background: #f1f5f9;
}

.ec-address-mode-btn.is-active {
  background: rgba(15, 39, 68, 0.08);
  color: var(--ec-navy, #0f2744);
  font-weight: 500;
}

.ec-address-empty-hint {
  font-size: 13px;
  color: var(--ec-muted, #64748b);
  margin: 0 0 12px;
  padding: 12px;
  background: #f8fafc;
  border-radius: 6px;
}

.ec-address-empty-hint.is-hidden {
  display: none;
}

.ec-check-default {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--ec-muted, #64748b);
  cursor: pointer;
}

.ec-check-default input {
  width: 16px;
  height: 16px;
  accent-color: var(--ec-navy, #0f2744);
}

.ec-address-form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.ec-btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 16px;
  border: 1px solid var(--ec-line, #e2e8f0);
  border-radius: 6px;
  background: #fff;
  color: var(--ec-muted, #64748b);
  font-family: 'Kanit', sans-serif;
  font-size: 13px;
  cursor: pointer;
}

.ec-btn-ghost:hover {
  background: #f8fafc;
}

.ec-address-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
}

.ec-address-card {
  display: block;
  width: 100%;
  text-align: left;
  padding: 14px;
  border: none;
  border-radius: 6px;
  background: #f8fafc;
  cursor: pointer;
  font-family: 'Kanit', sans-serif;
  transition: background 0.2s, color 0.2s;
}

.ec-address-card:hover {
  background: #f1f5f9;
}

.ec-address-card.is-selected {
  background: rgba(15, 39, 68, 0.08);
}

.ec-address-card strong {
  display: block;
  font-size: 14px;
  color: var(--ec-navy, #0f2744);
  margin-bottom: 4px;
}

.ec-address-card span {
  font-size: 13px;
  color: var(--ec-muted, #64748b);
  line-height: 1.45;
}

.ec-address-form {
  display: grid;
  gap: 12px;
  margin-top: 12px;
  padding-top: 16px;
  border-top: 1px dashed var(--ec-line, #e2e8f0);
}

.ec-address-form.is-hidden {
  display: none;
}

.ec-field label {
  display: block;
  font-size: 12px;
  color: var(--ec-muted, #64748b);
  margin-bottom: 4px;
  font-family: 'Kanit', sans-serif;
}

.ec-field > input,
.ec-field > textarea,
.ec-field > select {
  width: 100%;
  box-sizing: border-box;
  min-height: 42px;
  padding: 10px 12px;
  border: 1px solid var(--ec-line, #e2e8f0);
  border-radius: 4px;
  font-family: 'Kanit', sans-serif;
  font-size: 14px;
  line-height: 1.45;
  background: #fff;
  color: var(--ec-text, #0f172a);
}

.ec-field > select {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%2364748b' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

.ec-field > select:disabled {
  background-color: #f8fafc;
  color: #94a3b8;
  cursor: not-allowed;
}

.ec-field > input[readonly] {
  background: #f8fafc;
  color: var(--ec-text, #0f172a);
}

.ec-field > input::placeholder,
.ec-field > textarea::placeholder {
  color: #94a3b8;
  opacity: 1;
}

.ec-field-grid2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.ec-btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  border: 1px solid var(--ec-line, #e2e8f0);
  background: #f8fafc;
  color: var(--ec-navy, #0f2744);
  border-radius: 4px;
  cursor: pointer;
  font-family: 'Kanit', sans-serif;
  font-size: 13px;
}

.ec-pay-methods {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 16px;
}

.ec-pay-method {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 72px;
  padding: 12px 10px;
  border: none;
  border-radius: 6px;
  background: #f8fafc;
  color: #64748b;
  font-family: 'Prompt', sans-serif;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.ec-pay-method i {
  font-size: 18px;
}

.ec-pay-method:hover {
  background: #f1f5f9;
}

.ec-pay-method.is-active {
  background: #eef4fb;
  color: #1e4976;
}

.ec-cod-box {
  border: 1px solid #dbeafe;
  border-radius: 6px;
  background: linear-gradient(180deg, #f8fbff 0%, #f0f7ff 100%);
  padding: 20px 18px;
  text-align: center;
}

.ec-cod-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 10px;
  border-radius: 50%;
  background: #dbeafe;
  color: #1e4976;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}

.ec-cod-title {
  margin: 0 0 6px;
  font-size: 16px;
  font-weight: 600;
  color: #0f2744;
}

.ec-cod-lead {
  margin: 0 0 14px;
  font-size: 13px;
  line-height: 1.55;
  color: #64748b;
}

.ec-cod-total {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 4px;
  background: #fff;
  border: 1px solid #e2e8f0;
  font-size: 14px;
  color: #64748b;
}

.ec-cod-total strong {
  font-size: 18px;
  color: #1e4976;
}

.ec-bank-box {
  background: #f8fafc;
  border: 1px solid #dbeafe;
  border-radius: 4px;
  padding: 16px;
  margin-bottom: 16px;
  font-size: 13px;
}

.ec-bank-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
  border-bottom: 1px solid #e2e8f0;
}

.ec-bank-row:last-child {
  border-bottom: 0;
}

.ec-bank-row--account {
  align-items: center;
}

.ec-bank-row-end {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  text-align: right;
  margin-left: auto;
}

.ec-bank-account-num {
  letter-spacing: 0.03em;
}

.ec-bank-copy {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  border: 1px solid #c4b5fd;
  background: #fff;
  color: #5b21b6;
  font-size: 13px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

.ec-bank-copy:hover {
  background: #f5f3ff;
  border-color: #7c3aed;
}

.ec-bank-copy.is-copied {
  border-color: #059669;
  color: #059669;
  background: #ecfdf5;
}

.ec-bank-row--total {
  margin-top: 4px;
  padding-top: 10px;
  border-top: 1px dashed #dbeafe;
  border-bottom: 0;
}

.ec-bank-lbl {
  color: var(--ec-muted, #64748b);
  flex-shrink: 0;
}

.ec-bank-val {
  color: var(--ec-navy, #0f2744);
  font-weight: 500;
  text-align: right;
}

.ec-bank-total {
  font-size: 18px;
  color: #1e4976;
}

.ec-slip-zone {
  border: 2px dashed #cbd5e1;
  border-radius: 4px;
  padding: 24px;
  text-align: center;
  cursor: pointer;
  position: relative;
  background: #fafbfc;
}

.ec-slip-zone input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.ec-slip-preview {
  max-width: 100%;
  max-height: 200px;
  margin-top: 12px;
  border-radius: 4px;
  display: none;
}

.ec-slip-preview.is-visible {
  display: block;
  margin-left: auto;
  margin-right: auto;
}

.ec-checkout-summary {
  position: sticky;
  top: 16px;
}

.ec-sum-row {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  font-size: 14px;
  color: var(--ec-muted, #64748b);
}

.ec-sum-row strong {
  color: var(--ec-text, #0f172a);
}

.ec-sum-total {
  display: flex;
  justify-content: space-between;
  padding: 14px 0 0;
  margin-top: 8px;
  border-top: 2px solid var(--ec-navy, #0f2744);
  font-size: 16px;
  font-weight: 500;
  color: var(--ec-navy, #0f2744);
}

.ec-checkout-submit {
  width: 100%;
  margin-top: 16px;
  padding: 14px;
  border: 0;
  border-radius: 4px;
  background: var(--ec-navy, #0f2744);
  color: #fff;
  font-family: 'Kanit', sans-serif;
  font-size: 15px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.ec-checkout-submit:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.ec-checkout-note {
  margin-top: 12px;
  font-size: 12px;
  color: var(--ec-muted, #64748b);
  line-height: 1.5;
}

/* ---------- ยืนยันคำสั่งซื้อ (modal) ---------- */
.ec-confirm-overlay {
  position: fixed;
  inset: 0;
  z-index: 8000;
  background: rgba(8, 22, 38, 0.55);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px 16px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
}

.ec-confirm-overlay.is-open {
  opacity: 1;
  pointer-events: all;
}

.ec-confirm-modal {
  position: relative;
  background: #fff;
  width: 100%;
  max-width: 560px;
  max-height: min(90vh, 720px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 24px 24px 20px;
  border-radius: 8px;
  box-shadow: 0 24px 64px rgba(8, 22, 38, 0.22);
  transform: translateY(16px) scale(0.98);
  transition: transform 0.28s cubic-bezier(0.34, 1.2, 0.64, 1);
}

.ec-confirm-overlay.is-open .ec-confirm-modal {
  transform: translateY(0) scale(1);
}

.ec-confirm-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 32px;
  height: 32px;
  border: none;
  background: #f1f5f9;
  color: #64748b;
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}

.ec-confirm-close:hover {
  background: #e2e8f0;
}

.ec-confirm-title {
  margin: 0 0 6px;
  font-family: 'Kanit', sans-serif;
  font-size: 18px;
  font-weight: 600;
  color: var(--ec-navy, #0f2744);
  display: flex;
  align-items: center;
  gap: 10px;
  padding-right: 36px;
}

.ec-confirm-title i {
  color: #059669;
}

.ec-confirm-lead {
  margin: 0 0 16px;
  font-size: 13px;
  color: var(--ec-muted, #64748b);
}

.ec-confirm-body {
  overflow-y: auto;
  max-height: min(52vh, 420px);
  margin-bottom: 18px;
  padding-right: 4px;
}

.ec-confirm-section {
  margin-bottom: 14px;
  padding: 14px;
  background: #f8fafc;
  border: 1px solid var(--ec-line, #e2e8f0);
  border-radius: 6px;
}

.ec-confirm-section h4 {
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 600;
  color: var(--ec-navy, #0f2744);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.ec-confirm-item {
  display: grid;
  grid-template-columns: 48px 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid #e2e8f0;
  font-size: 13px;
}

.ec-confirm-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.ec-confirm-item:first-child {
  padding-top: 0;
}

.ec-confirm-item img {
  width: 48px;
  height: 48px;
  object-fit: cover;
  border-radius: 4px;
  background: #fff;
}

.ec-confirm-item-name {
  font-weight: 500;
  color: var(--ec-text, #0f172a);
  line-height: 1.35;
}

.ec-confirm-item-meta {
  font-size: 12px;
  color: var(--ec-muted, #64748b);
  margin-top: 2px;
}

.ec-confirm-item-price {
  font-weight: 600;
  color: var(--ec-navy, #0f2744);
  white-space: nowrap;
}

.ec-confirm-addr {
  font-size: 13px;
  color: var(--ec-text, #0f172a);
  line-height: 1.55;
}

.ec-confirm-addr strong {
  display: block;
  margin-bottom: 4px;
  font-size: 14px;
}

.ec-confirm-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 13px;
  padding: 4px 0;
  color: var(--ec-text, #0f172a);
}

.ec-confirm-row span {
  color: var(--ec-muted, #64748b);
}

.ec-confirm-total {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  padding-top: 10px;
  border-top: 2px solid var(--ec-navy, #0f2744);
  font-size: 16px;
  font-weight: 700;
  color: var(--ec-navy, #0f2744);
}

.ec-confirm-slip {
  display: flex;
  align-items: center;
  gap: 12px;
}

.ec-confirm-slip img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 4px;
  border: 1px solid var(--ec-line, #e2e8f0);
}

.ec-confirm-slip span {
  font-size: 12px;
  color: #059669;
}

.ec-confirm-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
  padding-top: 4px;
  border-top: 1px solid var(--ec-line, #e2e8f0);
}

.ec-confirm-actions .ec-checkout-submit {
  flex: 1;
  min-width: 180px;
  margin-top: 0;
}

.ec-confirm-actions .ec-btn-ghost {
  min-width: 100px;
}

/* ---------- หน้าสำเร็จหลังสั่งซื้อ ---------- */
.ec-order-success-page {
  max-width: 520px;
  margin: 32px auto 48px;
  padding: 0 16px;
}

.ec-order-success-card {
  text-align: center;
  padding: 40px 28px 36px;
  background: #fff;
  border: 1px solid var(--ec-line, #e2e8f0);
  border-radius: 8px;
  box-shadow: 0 8px 32px rgba(15, 39, 68, 0.08);
}

.ec-order-success-icon {
  width: 72px;
  height: 72px;
  margin: 0 auto 20px;
  border-radius: 50%;
  background: #ecfdf5;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ec-order-success-icon i {
  font-size: 40px;
  color: #059669;
}

.ec-order-success-title {
  margin: 0 0 8px;
  font-family: 'Kanit', sans-serif;
  font-size: 24px;
  font-weight: 600;
  color: var(--ec-navy, #0f2744);
}

.ec-order-success-lead {
  margin: 0 0 24px;
  font-size: 14px;
  color: var(--ec-muted, #64748b);
  line-height: 1.55;
}

.ec-order-success-number {
  margin: 0 0 24px;
  padding: 16px 20px;
  background: #f8fafc;
  border: 1px dashed var(--ec-line, #e2e8f0);
  border-radius: 6px;
}

.ec-order-success-number-lbl {
  display: block;
  font-size: 11px;
  color: var(--ec-muted, #64748b);
  margin-bottom: 6px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.ec-order-success-number strong {
  font-size: 20px;
  font-weight: 700;
  color: var(--ec-navy, #0f2744);
  letter-spacing: 0.04em;
}

.ec-order-success-steps {
  list-style: none;
  margin: 0 0 28px;
  padding: 0;
  text-align: left;
}

.ec-order-success-steps li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  color: var(--ec-text, #0f172a);
  padding: 8px 0;
  border-bottom: 1px solid #f1f5f9;
}

.ec-order-success-steps li:last-child {
  border-bottom: none;
}

.ec-order-success-steps i {
  color: var(--ec-navy, #0f2744);
  margin-top: 2px;
  width: 16px;
  text-align: center;
}

.ec-order-success-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ec-order-success-actions .ec-checkout-submit {
  margin-top: 0;
  text-decoration: none;
  color: #fff;
}

.ec-order-success-actions .ec-checkout-submit:hover,
.ec-order-success-actions .ec-checkout-submit:focus {
  color: #fff;
}

.ec-order-success-secondary {
  width: 100%;
  justify-content: center;
  padding: 12px;
}

.ec-order-success-card--failed .ec-order-success-icon {
  background: #fef2f2;
}

.ec-order-success-card--failed .ec-order-success-icon i {
  color: #dc2626;
}

.ec-order-success-card--pending .ec-order-success-icon {
  background: #fffbeb;
}

.ec-order-success-card--pending .ec-order-success-icon i {
  color: #d97706;
}

.ec-order-success-steps li.pending {
  color: #92400e;
}

.ec-order-success-steps li.pending i {
  color: #d97706;
}

.ec-order-timeline-preview li.done {
  color: #059669;
}

.ec-order-timeline-preview li.done i {
  color: #059669;
}

.ec-order-timeline-preview li.current {
  font-weight: 600;
  color: #2563eb;
}

.ec-order-timeline-preview li.current i {
  color: #2563eb;
}

.ec-order-timeline-preview li.error {
  color: #dc2626;
}

.ec-order-timeline-preview li.error i {
  color: #dc2626;
}

.ec-order-timeline-preview li:not(.done):not(.current):not(.error) {
  color: #94a3b8;
}

.ec-order-timeline-preview li:not(.done):not(.current):not(.error) i {
  color: #cbd5e1;
}

@media (max-width: 520px) {
  .ec-checkout-login-head {
    padding: 24px 18px 16px;
  }

  .ec-checkout-login-form,
  .ec-checkout-login-actions {
    padding-left: 18px;
    padding-right: 18px;
  }

  .ec-checkout-login-steps {
    padding: 12px 14px;
  }
}

@media (max-width: 900px) {
  .ec-checkout-grid {
    grid-template-columns: 1fr;
  }

  .ec-checkout-summary {
    position: static;
  }

  .ec-field-grid2 {
    grid-template-columns: 1fr;
  }
}
