/* ============================================================
   checkout.css — Checkout page styles
   ============================================================ */

/* ── Page wrapper ──────────────────────────────────────────── */
.ls-checkout-page {
  min-height: 100vh;
  background: var(--navy);
}

/* ── Hero ──────────────────────────────────────────────────── */
.checkout-hero {
  position: relative;
  padding: 80px 24px 48px;
  overflow: hidden;
  text-align: center;
}

.checkout-hero-bg-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(74,166,255,.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(74,166,255,.06) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
}

.checkout-hero-inner {
  position: relative;
  max-width: 600px;
  margin: 0 auto;
}

.checkout-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .12em;
  color: var(--blue);
  text-transform: uppercase;
  margin-bottom: 16px;
}

.checkout-eyebrow-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--blue);
  box-shadow: 0 0 8px var(--blue);
}

.checkout-hero-title {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  color: #fff;
  line-height: 1.1;
  margin: 0 0 14px;
}

.checkout-hero-title .accent { color: var(--blue); }

.checkout-hero-sub {
  font-size: 1rem;
  color: rgba(255,255,255,.6);
  margin: 0;
  line-height: 1.6;
}

/* ── Main layout ───────────────────────────────────────────── */
.checkout-main {
  padding: 0 24px 80px;
}

.checkout-grid {
  max-width: 1000px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 32px;
  align-items: start;
}

/* ── Form wrap ─────────────────────────────────────────────── */
.checkout-form-wrap {
  background: var(--navy-2);
  border: 1px solid rgba(74,166,255,.12);
  border-radius: 16px;
  padding: 32px;
}

/* ── Form sections ─────────────────────────────────────────── */
.co-section {
  margin-bottom: 28px;
}

.co-section:last-child {
  margin-bottom: 0;
}

.co-section + .co-section {
  padding-top: 28px;
  border-top: 1px solid rgba(255,255,255,.06);
}

.co-section-label {
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: rgba(255,255,255,.4);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}

/* ── Meta plan fixed display (no toggle) ───────────────────── */
.plan-display-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  border-radius: 10px;
  border: 2px solid var(--blue);
  background: rgba(74,166,255,.06);
}

.plan-display-meta-icon {
  width: 40px;
  height: 40px;
  background: rgba(74,166,255,.1);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.plan-display-meta-name {
  font-size: .95rem;
  font-weight: 700;
  color: #fff;
}

.plan-display-meta-desc {
  font-size: .78rem;
  color: rgba(255,255,255,.5);
  margin-top: 2px;
}

.plan-display-meta-price {
  margin-left: auto;
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--blue);
  white-space: nowrap;
  flex-shrink: 0;
}

.plan-display-meta-price span {
  font-size: .75rem;
  font-weight: 400;
  color: rgba(255,255,255,.45);
}

/* summary line note (small label inside line item) */
.summary-line-note {
  font-size: .75em;
  color: rgba(255,255,255,.35);
  margin-left: 4px;
}

/* ── Plan toggle ───────────────────────────────────────────── */
.plan-toggle {
  display: flex;
  gap: 12px;
}

.plan-toggle-btn {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 18px;
  border-radius: 10px;
  border: 2px solid rgba(255,255,255,.1);
  background: transparent;
  color: rgba(255,255,255,.6);
  font-size: .9rem;
  font-weight: 600;
  font-family: inherit;
  text-decoration: none;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  transition: border-color .2s, background .2s, color .2s;
  position: relative;
}

.plan-toggle-btn:hover {
  border-color: rgba(74,166,255,.4);
  color: #fff;
}

.plan-toggle-btn.active {
  border-color: var(--blue);
  background: rgba(74,166,255,.08);
  color: #fff;
}

.ptb-price {
  font-size: .8rem;
  font-weight: 700;
  color: var(--blue);
}

.ptb-badge {
  position: absolute;
  top: -10px;
  right: 14px;
  background: var(--blue);
  color: #000;
  font-size: .62rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 20px;
}

/* ── Platform selector ─────────────────────────────────────── */
.platform-radio-group {
  display: flex;
  gap: 10px;
}

.platform-radio-pill {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 8px;
  border: 2px solid rgba(255,255,255,.1);
  background: transparent;
  color: rgba(255,255,255,.6);
  font-size: .875rem;
  font-weight: 500;
  cursor: pointer;
  transition: border-color .2s, color .2s, background .2s;
}

.platform-radio-pill input[type="radio"] {
  display: none;
}

.platform-radio-pill:has(input:checked) {
  border-color: var(--blue);
  background: rgba(74,166,255,.08);
  color: #fff;
}

/* ── Add-on checkbox card ──────────────────────────────────── */
.addon-checkbox-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border-radius: 10px;
  border: 2px solid rgba(255,255,255,.1);
  background: transparent;
  cursor: pointer;
  transition: border-color .2s, background .2s;
  user-select: none;
}

.addon-checkbox-card:hover {
  border-color: rgba(74,166,255,.35);
}

.addon-checkbox-card.is-checked {
  border-color: var(--blue);
  background: rgba(74,166,255,.07);
}

.addon-checkbox-card input[type="checkbox"] {
  display: none;
}

.addon-card-icon {
  flex-shrink: 0;
  opacity: .7;
}

.addon-checkbox-card.is-checked .addon-card-icon {
  opacity: 1;
}

.addon-card-text {
  flex: 1;
}

.addon-card-name {
  font-size: .9rem;
  font-weight: 600;
  color: rgba(255,255,255,.85);
  margin-bottom: 2px;
}

.addon-card-detail {
  font-size: .75rem;
  color: rgba(255,255,255,.4);
  line-height: 1.4;
}

.addon-card-price {
  font-size: .95rem;
  font-weight: 700;
  color: var(--blue);
  flex-shrink: 0;
}

.addon-card-check {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,.15);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: transparent;
  transition: background .2s, border-color .2s, color .2s;
}

.addon-checkbox-card.is-checked .addon-card-check {
  background: var(--blue);
  border-color: var(--blue);
  color: #000;
}

.summary-line--addon {
  color: var(--blue);
  font-weight: 600;
}

/* ── Field rows ────────────────────────────────────────────── */
.co-row {
  margin-bottom: 14px;
}

.co-row:last-child { margin-bottom: 0; }

.co-row--two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.co-row--three {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 14px;
}

/* ── Fields ────────────────────────────────────────────────── */
.co-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.co-field label {
  font-size: .8rem;
  font-weight: 600;
  color: rgba(255,255,255,.7);
}

.co-field input {
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 8px;
  padding: 11px 14px;
  color: #fff;
  font-size: .925rem;
  font-family: inherit;
  transition: border-color .2s, box-shadow .2s;
  width: 100%;
  box-sizing: border-box;
}

.co-field input::placeholder { color: rgba(255,255,255,.25); }

.co-field input:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(74,166,255,.15);
}

.co-field.has-error input {
  border-color: #f87171;
}

.req { color: var(--blue); }
.opt { color: rgba(255,255,255,.3); font-size: .75em; font-weight: 400; }

.field-error {
  font-size: .75rem;
  color: #f87171;
  min-height: 1em;
  line-height: 1;
}

/* ── Card number wrap ──────────────────────────────────────── */
.card-number-wrap {
  position: relative;
}

.card-number-wrap input {
  padding-right: 48px;
}

.card-type-icon {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: .7rem;
  font-weight: 700;
  color: rgba(255,255,255,.4);
  pointer-events: none;
  letter-spacing: .04em;
}

/* ── Payment section ───────────────────────────────────────── */
.co-section--payment {
  /* nothing special yet */
}

.co-secure-badge {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: .68rem;
  color: rgba(255,255,255,.35);
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
}

/* ── Submit area ───────────────────────────────────────────── */
.co-submit-wrap {
  margin-top: 28px;
  padding-top: 28px;
  border-top: 1px solid rgba(255,255,255,.06);
}

.btn-checkout-submit {
  width: 100%;
  padding: 16px 24px;
  border: none;
  border-radius: 10px;
  background: var(--blue);
  color: #000;
  font-size: 1rem;
  font-weight: 800;
  font-family: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: opacity .2s, transform .15s;
  position: relative;
  overflow: hidden;
}

.btn-checkout-submit:hover { opacity: .9; transform: translateY(-1px); }
.btn-checkout-submit:active { transform: translateY(0); }

.btn-checkout-submit:disabled {
  opacity: .55;
  cursor: not-allowed;
  transform: none;
}

.btn-checkout-submit.is-loading .btn-label { opacity: 0; }
.btn-checkout-submit.is-loading .btn-spinner { opacity: 1; }

.btn-spinner {
  opacity: 0;
  width: 20px;
  height: 20px;
  border: 2.5px solid rgba(0,0,0,.3);
  border-top-color: #000;
  border-radius: 50%;
  position: absolute;
  animation: co-spin .7s linear infinite;
}

@keyframes co-spin { to { transform: rotate(360deg); } }

.co-legal {
  margin: 14px 0 0;
  font-size: .78rem;
  color: rgba(255,255,255,.35);
  line-height: 1.5;
  text-align: center;
}

.co-form-status {
  margin-top: 12px;
  font-size: .875rem;
  text-align: center;
  min-height: 1.2em;
  color: #f87171;
}

.co-form-status:empty { display: none; }

/* ── Success state ─────────────────────────────────────────── */
.checkout-success {
  text-align: center;
  padding: 48px 24px;
}

.checkout-success .success-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: rgba(74,166,255,.12);
  border: 2px solid var(--blue);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
  color: var(--blue);
}

.checkout-success h2 {
  font-size: 2rem;
  font-weight: 800;
  color: #fff;
  margin: 0 0 12px;
}

.success-sub {
  color: rgba(255,255,255,.55);
  font-size: 1rem;
  line-height: 1.6;
  margin: 0 0 28px;
  max-width: 440px;
  margin-left: auto;
  margin-right: auto;
}

/* ── Summary sidebar ───────────────────────────────────────── */
.checkout-summary {
  position: sticky;
  top: 90px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.summary-card {
  background: var(--navy-card);
  border: 1px solid rgba(74,166,255,.12);
  border-radius: 14px;
  padding: 24px;
}

.summary-header {
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: rgba(255,255,255,.4);
  margin-bottom: 20px;
}

.summary-plan {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid rgba(255,255,255,.06);
}

.summary-plan-icons {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
  margin-top: 2px;
}

.summary-plan-name {
  font-size: .925rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 3px;
}

.summary-plan-desc {
  font-size: .78rem;
  color: rgba(255,255,255,.45);
  line-height: 1.4;
}

.summary-line-items {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 20px;
}

.summary-line {
  display: flex;
  justify-content: space-between;
  font-size: .875rem;
  color: rgba(255,255,255,.7);
}

.summary-line--muted { opacity: .6; font-size: .82rem; }

.summary-waived { color: #4ade80; }
.summary-waived s { color: rgba(255,255,255,.3); }

.summary-total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding-top: 16px;
  border-top: 1px solid rgba(255,255,255,.1);
  font-size: .875rem;
  font-weight: 600;
  color: rgba(255,255,255,.8);
}

.summary-total-amount {
  font-size: 1.4rem;
  font-weight: 800;
  color: #fff;
}

.summary-renewal {
  margin-top: 10px;
  font-size: .75rem;
  color: rgba(255,255,255,.35);
  text-align: right;
}

.summary-includes {
  background: var(--navy-card);
  border: 1px solid rgba(74,166,255,.08);
  border-radius: 12px;
  padding: 20px;
}

.summary-includes-head {
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: rgba(255,255,255,.4);
  margin-bottom: 14px;
}

.summary-includes ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.summary-includes li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .825rem;
  color: rgba(255,255,255,.65);
}

.summary-includes li svg { flex-shrink: 0; }

.summary-trust {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.trust-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .78rem;
  color: rgba(255,255,255,.35);
}

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 768px) {
  .checkout-grid {
    grid-template-columns: 1fr;
  }

  .checkout-summary {
    position: static;
    order: -1;
  }

  .checkout-form-wrap {
    padding: 24px 20px;
  }

  .co-row--two,
  .co-row--three {
    grid-template-columns: 1fr;
  }

  .plan-toggle {
    flex-direction: column;
  }

  .checkout-hero {
    padding: 60px 20px 32px;
  }
}

@media (max-width: 480px) {
  .platform-radio-group {
    flex-direction: column;
  }
}

/* ── CRM Credentials (post-payment success state) ─────────── */
.crm-creds {
  width: 100%;
  max-width: 440px;
  margin: 24px auto 20px;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(74,166,255,.25);
  border-radius: 12px;
  padding: 20px 24px;
  text-align: left;
}

.creds-warning {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .8rem;
  color: #f5a623;
  margin-bottom: 18px;
  line-height: 1.4;
}

.cred-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid rgba(255,255,255,.08);
}

.cred-label {
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--text-muted, #888);
  min-width: 76px;
}

.cred-val {
  font-size: .95rem;
  font-weight: 600;
  color: #fff;
  font-family: 'Courier New', Courier, monospace;
  letter-spacing: .04em;
  word-break: break-all;
}

.cred-pass-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  justify-content: flex-end;
}

.btn-copy-cred {
  flex-shrink: 0;
  background: var(--blue, #4AA6FF);
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 5px 14px;
  font-size: .78rem;
  font-weight: 700;
  cursor: pointer;
  transition: opacity .15s;
}
.btn-copy-cred:hover { opacity: .85; }

.btn-goto-crm {
  display: block;
  margin-top: 20px;
  text-align: center;
  background: var(--blue, #4AA6FF);
  color: #fff;
  text-decoration: none;
  border-radius: 8px;
  padding: 13px 24px;
  font-size: .95rem;
  font-weight: 700;
  letter-spacing: .02em;
  transition: opacity .15s;
}
.btn-goto-crm:hover { opacity: .88; }
