/* Invoice payment: the pay panel at the top of an unpaid invoice and the payment sheet (method choice, card,
   bank transfer, waiting, done). Uses the dashboard's Bootstrap/Velzon variables so it works in dark and light. */

.payhero { position: relative; overflow: hidden; border-radius: 18px; margin-bottom: 20px; border: 1px solid var(--vz-border-color); }
.payhero::before { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(600px 220px at 100% 0%, rgba(79,182,163,.16), transparent 70%); }
.payhero__in { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 28px; padding: 28px; align-items: center; }
.payhero__kick { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 12.5px; color: var(--vz-secondary-color); }
.payhero__pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; font-weight: 600; font-size: 12px;
  background: rgba(232,168,56,.14); color: #E8A838; }
.payhero__pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; animation: phPulse 1.8s ease-in-out infinite; }
.payhero__pill.is-info { background: rgba(79,182,163,.14); color: var(--vz-primary); }
@keyframes phPulse { 50% { opacity: .35; } }
.payhero__amt { margin: 14px 0 4px; font-size: clamp(34px, 5vw, 46px); line-height: 1; font-weight: 700; letter-spacing: -.03em; color: var(--vz-heading-color, var(--vz-body-color)); }
.payhero__sub { margin: 0; font-size: 14px; color: var(--vz-secondary-color); }
.payhero__gets { list-style: none; margin: 18px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 18px; }
.payhero__gets li { position: relative; padding-left: 22px; font-size: 13.5px; line-height: 1.45; color: var(--vz-body-color); }
.payhero__gets li::before { content: ""; position: absolute; left: 0; top: 3px; width: 14px; height: 14px; border-radius: 50%;
  background: rgba(79,182,163,.16) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.4l2.6 2.6L12 5.4' fill='none' stroke='%234FB6A3' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/10px no-repeat; }
.payhero__act { display: flex; flex-direction: column; gap: 10px; }
.payhero__cta { height: 54px; border-radius: 14px; font-size: 16.5px; font-weight: 600; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  box-shadow: 0 10px 24px -12px rgba(79,182,163,.8); transition: transform .15s ease, box-shadow .15s ease; }
.payhero__cta:active { transform: scale(.98); }
.payhero__alt { height: 44px; border-radius: 12px; font-weight: 500; }
.payhero__trust { margin: 2px 0 0; text-align: center; font-size: 12px; color: var(--vz-secondary-color); }
.payhero__trust i { color: var(--vz-primary); }
.payhero__note { margin: 16px 0 0; padding: 10px 14px; border-radius: 10px; font-size: 13px; background: rgba(232,168,56,.10); color: var(--vz-body-color); }

.paidhero { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 24px; padding: 22px 24px; border-radius: 18px; margin-bottom: 20px;
  border: 1px solid rgba(79,182,163,.35); background: linear-gradient(135deg, rgba(79,182,163,.14), rgba(79,182,163,.04)); }
.paidhero__ic { flex: none; width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; background: var(--vz-primary); color: #062a23; font-size: 24px; }
.paidhero__t { flex: 1; min-width: 200px; }
.paidhero__t b { display: block; font-size: 17px; color: var(--vz-heading-color, var(--vz-body-color)); }
.paidhero__t span { font-size: 13.5px; color: var(--vz-secondary-color); }
.paidhero__a { display: flex; flex-wrap: wrap; gap: 10px; }

/* ---- Sheet ---- */
.psheet { position: fixed; inset: 0; z-index: 1065; display: grid; place-items: center; padding: 16px; }
.psheet[hidden] { display: none; }
.psheet__scrim { position: absolute; inset: 0; background: rgba(8,10,12,.72); animation: psFade .2s ease; }
.psheet__panel { position: relative; width: 100%; max-width: 460px; max-height: calc(100vh - 32px); overflow: auto; border-radius: 22px;
  background: var(--vz-card-bg, #1c1d21); color: var(--vz-body-color); border: 1px solid var(--vz-border-color);
  box-shadow: 0 30px 80px -20px rgba(0,0,0,.6); animation: psUp .28s cubic-bezier(.22,1,.36,1); }
@keyframes psFade { from { opacity: 0; } }
@keyframes psUp { from { opacity: 0; transform: translateY(16px) scale(.98); } }
.psheet__x { position: absolute; top: 14px; right: 14px; z-index: 2; width: 36px; height: 36px; border: 0; border-radius: 50%; display: grid; place-items: center;
  background: var(--vz-light, rgba(255,255,255,.06)); color: var(--vz-body-color); font-size: 20px; line-height: 1; cursor: pointer; }
.psheet__sum { padding: 22px 64px 18px 24px; border-bottom: 1px dashed var(--vz-border-color); }
.psheet__sum small { display: block; font-size: 12px; letter-spacing: .04em; text-transform: uppercase; color: var(--vz-secondary-color); }
.psheet__sum b { display: block; margin-top: 6px; font-size: 30px; line-height: 1.05; letter-spacing: -.02em; color: var(--vz-heading-color, var(--vz-body-color)); }
.psheet__sum span { display: block; margin-top: 4px; font-size: 13px; color: var(--vz-secondary-color); }
.ps-step { padding: 22px 24px 24px; }
.ps-step[hidden] { display: none; }
.ps-step h3 { margin: 0 0 6px; font-size: 18px; font-weight: 600; color: var(--vz-heading-color, var(--vz-body-color)); }
.ps-step > p { margin: 0 0 16px; font-size: 14px; color: var(--vz-secondary-color); }
.ps-opts { display: grid; gap: 10px; margin: 16px 0 18px; }
.ps-opt { position: relative; display: grid; grid-template-columns: 44px minmax(0, 1fr) 22px; gap: 14px; align-items: center; width: 100%; padding: 14px 16px; text-align: left; cursor: pointer;
  border-radius: 14px; border: 1.5px solid var(--vz-border-color); background: transparent; color: inherit; transition: border-color .15s, background-color .15s, transform .15s; }
.ps-opt:active { transform: scale(.99); }
.ps-opt.is-on { border-color: var(--vz-primary); background: rgba(79,182,163,.07); }
.ps-opt__ic { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; font-size: 22px; background: rgba(79,182,163,.12); color: var(--vz-primary); }
.ps-opt b { display: flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 600; color: var(--vz-heading-color, var(--vz-body-color)); }
.ps-opt .ps-opt__d { display: block; margin-top: 3px; font-size: 13px; line-height: 1.4; color: var(--vz-secondary-color); }
.ps-opt em { font-style: normal; font-size: 11px; font-weight: 600; letter-spacing: .02em; padding: 2px 8px; border-radius: 999px; background: var(--vz-primary); color: #062a23; }
.ps-opt__r { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--vz-border-color); transition: border-color .15s, box-shadow .15s; }
.ps-opt.is-on .ps-opt__r { border-color: var(--vz-primary); box-shadow: inset 0 0 0 4px var(--vz-card-bg, #1c1d21), inset 0 0 0 12px var(--vz-primary); }
.ps-go { width: 100%; height: 52px; border-radius: 14px; font-size: 16px; font-weight: 600; display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.ps-trust { margin: 12px 0 0; text-align: center; font-size: 12px; color: var(--vz-secondary-color); }
.ps-trust i { color: var(--vz-primary); }
.ps-link { display: block; width: 100%; margin-top: 10px; padding: 8px; border: 0; background: none; font-size: 13.5px; color: var(--vz-secondary-color); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.ps-link:hover { color: var(--vz-body-color); }

.ps-rows { margin: 14px 0 0; border-radius: 14px; border: 1px solid var(--vz-border-color); overflow: hidden; }
.ps-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 16px; }
.ps-row + .ps-row { border-top: 1px solid var(--vz-border-color); }
.ps-row small { display: block; font-size: 11.5px; letter-spacing: .05em; text-transform: uppercase; color: var(--vz-secondary-color); }
.ps-row strong { display: block; margin-top: 2px; font-size: 15px; font-weight: 600; color: var(--vz-heading-color, var(--vz-body-color)); word-break: break-word; }
.ps-row--big strong { font-size: 24px; letter-spacing: .02em; font-variant-numeric: tabular-nums; }
.ps-copy { flex: none; height: 34px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--vz-border-color); background: transparent; color: var(--vz-body-color); font-size: 13px; font-weight: 500; cursor: pointer; }
.ps-copy.is-done { border-color: var(--vz-primary); color: var(--vz-primary); }
.ps-timer { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 12px; padding: 10px 14px; border-radius: 12px; font-size: 13px;
  background: rgba(232,168,56,.10); color: var(--vz-body-color); }
.ps-timer b { font-variant-numeric: tabular-nums; font-size: 15px; color: #E8A838; }
.ps-hint { margin: 12px 0 16px; font-size: 13px; color: var(--vz-secondary-color); }

.ps-center { text-align: center; padding-top: 8px; }
.ps-center h3 { margin-top: 18px; }
.ps-orb { width: 72px; height: 72px; margin: 6px auto 0; border-radius: 50%; display: grid; place-items: center; position: relative; background: rgba(79,182,163,.14); color: var(--vz-primary); font-size: 30px; }
.ps-orb::after { content: ""; position: absolute; inset: -6px; border-radius: 50%; border: 2px solid rgba(79,182,163,.4); animation: psRing 1.8s ease-out infinite; }
@keyframes psRing { from { transform: scale(.85); opacity: 1; } to { transform: scale(1.25); opacity: 0; } }
.ps-orb--done { background: var(--vz-primary); color: #062a23; animation: psPop .45s cubic-bezier(.22,1.4,.36,1); }
.ps-orb--done::after { display: none; }
.ps-orb--err { background: rgba(240,101,72,.14); color: #f06548; }
.ps-orb--err::after { display: none; }
@keyframes psPop { from { transform: scale(.4); opacity: 0; } }
.ps-actions { display: grid; gap: 10px; margin-top: 20px; }
.ps-field { margin-top: 14px; }
.ps-field label { display: block; margin-bottom: 6px; font-size: 13px; font-weight: 500; }
.ps-field input { width: 100%; height: 48px; padding: 0 14px; border-radius: 12px; font-size: 16px; }
.ps-err { margin-top: 8px; font-size: 13px; color: #f06548; }
.ps-err:empty { display: none; }

@media (max-width: 767.98px) {
  .payhero__in { grid-template-columns: minmax(0, 1fr); padding: 22px; gap: 20px; }
  .payhero__gets { grid-template-columns: minmax(0, 1fr); }
  .psheet { place-items: end stretch; padding: 0; }
  .psheet__panel { max-width: none; max-height: 92vh; border-radius: 22px 22px 0 0; padding-bottom: env(safe-area-inset-bottom); animation-name: psSlide; }
  @keyframes psSlide { from { transform: translateY(100%); } }
}
@media (prefers-reduced-motion: reduce) { .psheet__panel, .psheet__scrim, .ps-orb, .ps-orb::after, .payhero__pill::before { animation: none !important; } }
@media print { .payhero, .paidhero, .psheet { display: none !important; } }

/* ---- "Finish activating" prompt: a dashboard card (markup in paysheet.js), plus a dismiss button ---- */
.pay-strip .card-body { position: relative; }
.pay-strip__x { flex: none; width: 32px; height: 32px; margin-left: -4px; border: 0; border-radius: 50%; background: transparent; color: var(--vz-secondary-color);
  font-size: 20px; line-height: 1; cursor: pointer; }
.pay-strip__x:hover { background: rgba(127,127,127,.12); color: var(--vz-body-color); }
@media (max-width: 575.98px) {
  .pay-strip .btn-primary { width: 100%; order: 4; }
  .pay-strip__x { position: absolute; top: 8px; right: 8px; }
}
/* While an invoice is open it is the one next step: the sandbox note hides and other prompts step back. */
.has-open-invoice #dashboard-account-summary { display: none !important; }
.has-open-invoice #golive-banner .btn-primary { background: transparent; color: var(--vz-body-color); border: 1px solid var(--vz-border-color); }
.has-open-invoice #wallet-empty .btn-primary { background: transparent; color: var(--vz-body-color); border: 1px solid var(--vz-border-color); }
.has-open-invoice .sandbox-go-live-strip { display: none !important; }
.has-open-invoice #billing-upgrade-btn, .has-open-invoice #billing-update-payment-btn { background: transparent; color: var(--vz-body-color); border: 1px solid var(--vz-border-color); }
