.checkout-page { background: var(--pale); min-height: 100dvh; }
.checkout-header { min-height: 74px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.checkout-header nav { position: static; padding: 0; background: transparent; border: 0; box-shadow: none; display: flex; gap: clamp(12px, 4vw, 30px); align-items: center; font-size: 14px; font-weight: 650; }
.checkout-header nav a { display: inline-flex; align-items: center; min-height: 36px; padding: 0; background: transparent; white-space: nowrap; }
.checkout-header nav a:hover, .checkout-link:hover { color: var(--blue); text-decoration: underline; text-underline-offset: 3px; }
.checkout-shell { max-width: 1080px; padding-block: clamp(32px, 6vw, 72px); }
.checkout-shell h1 { font-size: clamp(29px, 5vw, 48px); line-height: 1.15; letter-spacing: -.035em; }
.checkout-lead { margin-block: 12px 26px; color: var(--sub); }
.checkout-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.checkout-card { border: 1px solid var(--line); background: var(--surface, white); border-radius: 22px; box-shadow: var(--shadow); padding: clamp(20px, 4vw, 32px); }
.checkout-card h2 { font-size: 20px; }
.checkout-items, .checkout-orders { list-style: none; padding: 0; margin: 10px 0 0; }
.checkout-items li, .checkout-total, .checkout-orders a { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.checkout-items li { padding-block: 15px; border-bottom: 1px solid var(--line); }
.checkout-items li span, .checkout-orders small { display: block; color: var(--sub); font-size: 13px; line-height: 1.55; }
.checkout-items li strong:last-child, .checkout-orders b { white-space: nowrap; }
.checkout-total { padding-block: 17px; }
.checkout-total strong { font-size: clamp(24px, 4vw, 34px); font-variant-numeric: tabular-nums; }
.checkout-status { margin-block: 12px 18px; min-height: 1.5em; color: var(--sub); line-height: 1.6; }
.checkout-message { margin-bottom: 16px; padding: 12px 16px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface, #fff7f2); color: var(--ink); }
.checkout-actions { display: flex; gap: 9px; flex-wrap: wrap; }
.checkout-actions button[disabled] { opacity: .55; cursor: wait; }
.payment-code { display: grid; justify-items: center; gap: 12px; margin-bottom: 17px; }
.payment-code img { display: block; max-width: 100%; height: auto; aspect-ratio: 1; border: 1px solid var(--line); border-radius: 12px; background: white; }
.payment-countdown { color: var(--sub); font-size: 14px; }
.payment-countdown [role="timer"] { color: var(--ink); font-weight: 700; font-variant-numeric: tabular-nums; }
.checkout-support, .order-id { color: var(--sub); font-size: 14px; line-height: 1.65; border-top: 1px solid var(--line); padding-top: 16px; margin-top: 19px; }
.order-id code { display: inline-block; overflow-wrap: anywhere; }
.order-id div { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.checkout-link { padding: 5px 8px; background: transparent; border: 1px solid var(--line); border-radius: 7px; }
.checkout-recent { margin-top: 18px; }
.checkout-recent > p, #empty > p { color: var(--sub); margin-block: 10px; }
.checkout-orders a { padding: 12px 0; border-bottom: 1px solid var(--line); }
.checkout-orders a:hover strong { color: var(--blue); }
@media (max-width: 700px) {
  .checkout-header, .checkout-shell { width: calc(100% - 32px); }
  .checkout-grid { grid-template-columns: 1fr; }
}
@media (max-width: 355px) {
  .checkout-header .brand { font-size: 15px; gap: 6px; }
  .checkout-header .brand-mark { width: 30px; height: 30px; }
  .checkout-header nav { font-size: 12px; }
}

.paid-dialog {
  position: fixed;
  width: min(456px, calc(100% - 32px));
  max-height: calc(100dvh - 32px);
  margin: auto;
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: clamp(20px, 5vw, 32px);
  background: var(--surface, white);
  color: var(--ink);
  box-shadow: 0 22px 84px #12234d44;
  overscroll-behavior: contain;
}
.paid-dialog::backdrop { background: #0b163a82; }
.checkout-page:has(.paid-dialog[open]) { overflow: hidden; }
.paid-dialog h2 { margin-top: 14px; font-size: 27px; }
.paid-dialog-close { position: absolute; top: 16px; right: 16px; }
.paid-dialog-close button { width: 34px; height: 34px; font-size: 23px; line-height: 1; }
.paid-mark {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 15px;
  background: #dff5eb;
  color: #15654a;
  font-size: 24px;
  font-weight: 750;
}
#paid-note, .paid-hint, .paid-copy-status { margin-top: 8px; color: var(--sub); line-height: 1.6; }
.paid-contacts { margin: 18px 0 0; }
.paid-contacts > div { border-top: 1px solid var(--line); padding: 9px 0; }
.paid-contacts dt { font-size: 13px; color: var(--sub); }
.paid-contacts dd { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 3px 0 0; }
.paid-contacts code { min-width: 0; overflow-wrap: anywhere; }
.paid-contacts button { flex: none; }
.paid-hint, .paid-copy-status { font-size: 13px; }
.paid-copy-status { min-height: 1.6em; }
