:root {
  --bg: #05090b;
  --panel: #101820;
  --panel-2: #0b1216;
  --line: rgba(255,255,255,.12);
  --text: #effbf3;
  --muted: rgba(239,251,243,.68);
  --green: #27e864;
  --green-strong: #36ff78;
  --green-soft: rgba(39,232,100,.13);
  --shadow: 0 30px 90px rgba(0,0,0,.42);
  --radius: 28px;
  color-scheme: dark;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html, body { min-height: 100%; }

body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at 8% 0%, rgba(39,232,100,.18), transparent 28%),
    radial-gradient(circle at 92% 12%, rgba(125,255,138,.10), transparent 24%),
    linear-gradient(150deg, #020504, #06110d 45%, #071912);
}

a { color: inherit; text-decoration: none; }

.checkout-shell {
  width: min(1200px, 100%);
  margin: 0 auto;
  padding: 24px;
}

.checkout-top {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  margin-bottom: 28px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 900;
  letter-spacing: .04em;
}

.brand-icon {
  width: 46px;
  height: 46px;
  object-fit: contain;
  filter: drop-shadow(0 0 18px rgba(39,232,100,.18));
}

.top-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

select, input {
  width: 100%;
  min-height: 48px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.055);
  color: var(--text);
  padding: 0 14px;
  outline: none;
  font: inherit;
}

select option { background: #0b1216; color: var(--text); }

select:focus, input:focus {
  border-color: rgba(39,232,100,.7);
  box-shadow: 0 0 0 3px rgba(39,232,100,.14);
}

.lang-select {
  width: auto;
  min-width: 220px;
}

.checkout-grid {
  display: grid;
  grid-template-columns: minmax(0, .95fr) minmax(360px, .85fr);
  gap: 24px;
  align-items: start;
}

.card {
  background: linear-gradient(180deg, rgba(255,255,255,.075), rgba(255,255,255,.035));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: clamp(22px, 4vw, 34px);
}

.account-card h1 {
  margin: 0;
  font-family: "Space Grotesk", Inter, sans-serif;
  font-size: clamp(32px, 5vw, 54px);
  line-height: 1;
  letter-spacing: -.05em;
}

h2 {
  margin: 0 0 14px;
  font-family: "Space Grotesk", Inter, sans-serif;
  font-size: clamp(20px, 2.4vw, 28px);
  letter-spacing: -.04em;
}

p {
  color: var(--muted);
  line-height: 1.55;
}

.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin: 18px 0 24px;
}

.step {
  position: relative;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 12px;
  color: var(--muted);
  font-size: 11px;
  text-align: center;
  font-weight: 800;
}

.step:not(:last-child)::after {
  content: '›';
  position: absolute;
  right: -15px;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(239,251,243,.45);
  font-weight: 900;
}

.step.active {
  color: #031008;
  background: var(--green);
  border-color: var(--green);
}

.step.completed {
  border-color: rgba(125, 211, 252, .55);
  color: rgba(224, 242, 254, .92);
}

.step.completed:not(:last-child)::after {
  color: #7dd3fc;
}

.form-stack {
  display: grid;
  gap: 14px;
}

label {
  display: grid;
  gap: 8px;
  color: rgba(239,251,243,.9);
  font-weight: 760;
  font-size: 14px;
}

.btn {
  min-height: 50px;
  border-radius: 17px;
  border: 1px solid transparent;
  padding: 0 20px;
  font-weight: 900;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font: inherit;
}

.btn-primary {
  background: var(--green);
  color: #041008;
}

.btn-primary:hover {
  background: var(--green-strong);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 20px;
}

.actions.center {
  justify-content: center;
}

.status {
  margin-top: 14px;
  color: var(--muted);
  min-height: 22px;
}

.plan-card {
  position: sticky;
  top: 20px;
}

.plan-card h2 {
  margin: 16px 0 6px;
}

.price {
  font-family: "Space Grotesk", Inter, sans-serif;
  font-size: clamp(22px, 3.2vw, 30px);
  line-height: 1;
  color: var(--green);
  font-weight: 950;
  letter-spacing: -.05em;
  margin: 14px 0 18px;
}

.plan-options,
.cycle-options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 16px;
}

.plan-options:empty,
.cycle-options:empty {
  display: none;
}

.plan-options button,
.cycle-options button {
  min-height: 38px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.06);
  color: var(--text);
  font-weight: 850;
  cursor: pointer;
  font: inherit;
  font-size: 14px;
  padding: 0 18px;
}


.plan-options button:disabled,
.cycle-options button:disabled,
.plan-options button.disabled,
.cycle-options button.disabled {
  opacity: .38;
  cursor: not-allowed;
  filter: grayscale(.35);
}

.plan-options button.active,
.cycle-options button.active {
  background: var(--green);
  color: #041008;
  border-color: var(--green);
}

.features {
  list-style: none;
  padding: 18px 0 0;
  margin: 0;
  display: grid;
  gap: 11px;
  border-top: 1px solid var(--line);
}

.features li {
  display: flex;
  gap: 10px;
  color: rgba(239,251,243,.86);
  line-height: 1.35;
}

.features li::before {
  content: '✓';
  color: var(--green);
  font-weight: 950;
  flex: 0 0 auto;
}

.payment-mini-summary {
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 18px;
  display: grid;
  gap: 8px;
  background: rgba(255,255,255,.05);
}

.payment-mini-summary span {
  color: var(--muted);
  font-weight: 800;
}

.payment-mini-summary strong {
  color: var(--green);
  font-size: 28px;
  font-family: "Space Grotesk", Inter, sans-serif;
}

.payment-mini-summary small {
  color: var(--muted);
}

.hidden { display: none !important; }

.success-panel {
  text-align: center;
  max-width: 720px;
  margin: 48px auto 0;
}

.success-icon {
  width: 72px;
  height: 72px;
  border-radius: 24px;
  display: grid;
  place-items: center;
  margin: 0 auto 18px;
  background: var(--green-soft);
  color: var(--green);
  font-size: 36px;
  font-weight: 950;
}

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

  .plan-card {
    position: static;
  }
}

@media (max-width: 640px) {
  .checkout-shell {
    padding: 16px;
  }

  .checkout-top {
    align-items: flex-start;
    flex-direction: column;
  }

  .lang-select {
    width: 100%;
  }

  .steps {
    grid-template-columns: repeat(2, 1fr);
  }

}

.billing-section {
  margin-top: 18px;
}

.section-divider {
  height: 1px;
  background: var(--line);
  margin: 4px 0 18px;
}

.billing-grid {
  display: grid;
  gap: 14px;
}

.payment-method-field {
  display: grid;
  gap: 8px;
}

.field-label {
  color: rgba(239,251,243,.9);
  font-weight: 760;
  font-size: 14px;
}

.payment-methods {
  display: grid;
  gap: 10px;
}

.payment-method-button {
  min-height: 52px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.055);
  color: var(--text);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 14px;
  font: inherit;
  font-weight: 850;
  text-align: left;
}

.payment-method-button:hover,
.payment-method-button.active {
  border-color: rgba(39,232,100,.78);
  background: rgba(39,232,100,.13);
}

.payment-method-button img {
  width: 30px;
  height: 30px;
  object-fit: contain;
  border-radius: 8px;
  background: rgba(255,255,255,.92);
  padding: 4px;
}


.billing-note {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.billing-disabled {
  opacity: .48;
}

.billing-disabled select,
.billing-disabled .payment-method-button {
  cursor: not-allowed;
}

.billing-disabled .payment-method-button:hover,
.billing-disabled .payment-method-button.active {
  border-color: var(--line);
  background: rgba(255,255,255,.055);
}



.success-icon.processing {
  color: #effbf3;
  background: rgba(255,255,255,.09);
}

.success-icon.warning {
  color: #ffd166;
  background: rgba(255,209,102,.12);
}





/* V189: validação, senha, reenvio e plano personalizado */
.btn-secondary {
  background: rgba(255,255,255,.075);
  color: var(--text);
  border-color: var(--line);
}

.btn-secondary:hover {
  border-color: rgba(39,232,100,.66);
  background: rgba(39,232,100,.11);
}

.status.error {
  color: #ff7b7b;
  font-weight: 850;
}

.field-error input,
.field-error select,
input.field-error,
select.field-error {
  border-color: rgba(255,92,92,.92) !important;
  box-shadow: 0 0 0 3px rgba(255,92,92,.16) !important;
}

.field-error-message {
  color: #ff8f8f;
  font-size: 12px;
  font-weight: 850;
  line-height: 1.35;
}

.password-control {
  position: relative;
  display: block;
}

.password-control input {
  padding-right: 52px;
}

.password-toggle {
  position: absolute;
  top: 50%;
  right: 8px;
  transform: translateY(-50%);
  width: 38px;
  height: 38px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.08);
  color: var(--text);
  cursor: pointer;
  display: grid;
  place-items: center;
}

.password-requirements {
  margin: -4px 0 2px;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 5px;
}

.password-requirements li {
  color: #ff8f8f;
  font-size: 12px;
  font-weight: 850;
}

.password-requirements li.ok {
  color: var(--green);
}

.custom-plan-box {
  margin-top: 18px;
  border-top: 1px solid var(--line);
  padding-top: 16px;
}

.custom-plan-link {
  border: 0;
  background: transparent;
  color: var(--green);
  font: inherit;
  font-weight: 950;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.custom-plan-form {
  margin-top: 14px;
  display: grid;
  gap: 12px;
  padding: 16px;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.045);
}

.custom-plan-result {
  min-height: 22px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.custom-plan-result strong {
  color: var(--green);
}



.payment-accepted {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 2px;
}
.payment-accepted-badge {
  border: 1px solid rgba(39,232,100,.28);
  border-radius: 999px;
  padding: 6px 10px;
  background: rgba(39,232,100,.08);
  color: #dfffe9;
  font-size: 12px;
  font-weight: 850;
}


/* V192: refinamentos de fluxo comercial */
.steps { gap: 22px; margin: 14px 0 20px; }
.step { padding: 8px 12px 10px; font-size: 12px; border-radius: 16px; }
.step:not(:last-child)::after { content: '>>'; right: -18px; width: auto; height: auto; background: transparent; color: rgba(239,251,243,.58); }
.step.active { box-shadow: inset 0 -2px 0 rgba(39,232,100,.95); }
.account-card h1 { font-size: clamp(24px, 3vw, 34px); }
.payment-logo-badge { display: inline-flex; align-items: center; justify-content: center; min-width: 46px; height: 30px; padding: 4px 8px; border-radius: 9px; background: rgba(255,255,255,.96); border: 1px solid rgba(255,255,255,.28); }
.payment-logo-badge img { max-width: 36px; max-height: 20px; object-fit: contain; display: block; }
.payment-accepted { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.payment-review { margin: 14px 0 4px; padding: 14px; border: 1px solid var(--line); border-radius: 18px; background: rgba(255,255,255,.045); display: grid; gap: 12px; }
.payment-review-row { display: grid; gap: 8px; }
.payment-review-row > span { color: var(--muted); font-size: 12px; font-weight: 850; text-transform: uppercase; letter-spacing: .05em; }
.payment-review-providers { display: flex; flex-wrap: wrap; gap: 8px; }
.payment-review-provider { width: 58px; height: 38px; border-radius: 12px; border: 1px solid var(--line); background: rgba(255,255,255,.08); cursor: pointer; display: grid; place-items: center; }
.payment-review-provider.active { border-color: rgba(39,232,100,.82); background: rgba(39,232,100,.12); }
.payment-review-provider img { max-width: 42px; max-height: 24px; object-fit: contain; background: rgba(255,255,255,.96); border-radius: 8px; padding: 4px; }
.password-requirements-popover { margin: -2px 0 4px; padding: 10px 12px; border: 1px solid rgba(255,108,108,.44); background: rgba(255,73,73,.10); border-radius: 14px; display: grid; gap: 5px; }
.password-requirements-popover span { font-size: 12px; font-weight: 850; color: #ff9b9b; }
.password-requirements-popover span.ok { color: var(--green); }
.password-requirements-popover.hidden { display: none; }


/* V193 - ajuste visual do fluxo guiado e meios de pagamento */
.steps { gap: 28px; border-bottom: 0; flex-wrap: nowrap; }
.step { position: relative; padding: 8px 14px; font-size: 13px; white-space: nowrap; }
.step:not(:last-child)::after { content: '>>'; position: absolute; right: -25px; top: 50%; transform: translateY(-50%); width: auto; height: auto; background: transparent; color: rgba(239,251,243,.58); font-weight: 900; letter-spacing: -2px; }
.step.active { box-shadow: 0 0 0 1px rgba(39,232,100,.28), inset 0 -2px 0 rgba(39,232,100,.95); }
.checkout-title h1 { font-size: clamp(1.55rem, 4vw, 2.2rem); }
.plan-price, [data-plan-price], .summary-price { font-size: clamp(1.15rem, 3vw, 1.65rem); }
.payment-logo-badge { display: inline-flex; align-items: center; gap: 7px; min-width: auto; height: 34px; padding: 5px 10px; border-radius: 11px; background: #fff; border: 1px solid rgba(8,18,24,.12); color: #081218; box-shadow: 0 6px 18px rgba(0,0,0,.16); }
.payment-logo-badge img { display: none; }
.payment-logo-mark { display: inline-grid; place-items: center; min-width: 25px; height: 20px; border-radius: 6px; background: #eef5ff; color: #062452; font-size: 10px; font-weight: 950; letter-spacing: -.03em; }
.payment-logo-badge strong { font-size: 12px; font-weight: 900; letter-spacing: -.02em; color: #0b1520; }
.payment-logo-badge--pix .payment-logo-mark { background: #dffaf4; color: #057665; }
.payment-logo-badge--mercado_pago .payment-logo-mark { background: #dff3ff; color: #007eb8; }
.payment-logo-badge--visa .payment-logo-mark { background: #e9efff; color: #1434cb; }
.payment-logo-badge--mastercard .payment-logo-mark { background: #fff0e8; color: #d54212; }
.payment-logo-badge--elo .payment-logo-mark { background: #fff8d7; color: #6a5300; }
@media (max-width: 620px) { .steps { gap: 24px; overflow-x: auto; padding-bottom: 6px; } .step { font-size: 12px; padding: 7px 10px; } .step:not(:last-child)::after { right: -21px; } }


/* V194 - meios de pagamento sem logotipos simulados */
.payment-method-button img,
.payment-review-provider img,
.payment-logo-mark { display: none !important; }
.payment-method-button { gap: 8px; }
.payment-method-button span { font-weight: 900; }
.payment-review-provider { width: auto; min-width: 116px; padding: 0 14px; color: #eafff0; font-size: 13px; font-weight: 900; }
.payment-logo-badge {
  display: inline-flex;
  align-items: center;
  min-width: auto;
  height: auto;
  padding: 7px 11px;
  border-radius: 999px;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(239,251,243,.16);
  color: #eafff0;
  box-shadow: none;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: -.01em;
}
.payment-logo-badge strong { color: inherit; font-size: inherit; }
.payment-logo-badge::before { content: ''; width: 6px; height: 6px; border-radius: 999px; margin-right: 7px; background: var(--green); box-shadow: 0 0 10px rgba(39,232,100,.42); }



.plan-change-preview {
  margin: 18px 0 0;
  padding: 16px;
  border: 1px solid rgba(54, 255, 120, .28);
  border-radius: 18px;
  background: rgba(39, 232, 100, .08);
}
.plan-change-preview h3 {
  margin: 0 0 8px;
  font-size: 1rem;
}
.plan-change-preview p {
  margin: 0 0 12px;
  color: var(--muted);
  line-height: 1.45;
}
.plan-change-summary {
  display: grid;
  gap: 8px;
}
.plan-change-row {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  border-top: 1px solid rgba(255,255,255,.08);
  padding-top: 8px;
}
.plan-change-row:first-child {
  border-top: 0;
  padding-top: 0;
}
.plan-change-row span {
  color: var(--muted);
}
.plan-change-row strong {
  text-align: right;
}


/* V201 - fluxo visual dedicado para alteração de assinatura */
html.subscription-change-boot [data-panel="account"],
html.subscription-change-boot [data-panel="verify"] {
  display: none !important;
}
html.subscription-change-boot [data-title] {
  visibility: hidden;
}
html.subscription-change-ready .steps {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  max-width: 420px;
}
html.subscription-change-ready .step.hidden {
  display: none !important;
}
html.subscription-change-ready [data-panel="payment"] h2 {
  margin-top: 8px;
}
