:root {
  --bg: #f4f6f8;
  --surface: #ffffff;
  --surface-soft: #f9fbfc;
  --text: #263241;
  --muted: #637083;
  --line: #dce2ea;
  --line-strong: #758292;
  --green: #1f8d41;
  --green-dark: #0d6b2b;
  --green-soft: #eaf6e8;
  --yellow: #ffe252;
  --red: #d83b38;
  --blue: #2563eb;
  --shadow: 0 14px 35px rgba(28, 42, 59, 0.12);
  --radius: 8px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: var(--bg);
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

body.modal-open {
  overflow: hidden;
}

button,
input,
textarea {
  font: inherit;
}

button {
  border: 0;
}

button:not(:disabled) {
  cursor: pointer;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
}

noscript {
  display: block;
  padding: 16px;
  background: #fff3cd;
  color: #664d03;
  text-align: center;
  font-weight: 800;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid #edf0f4;
  backdrop-filter: blur(12px);
}

.topbar__inner {
  width: min(100%, 920px);
  height: 68px;
  margin: 0 auto;
  padding: 0 clamp(14px, 4vw, 24px);
  display: grid;
  grid-template-columns: 44px 1fr auto;
  align-items: center;
  gap: 8px;
}

.topbar__logo {
  width: 46px;
  height: 46px;
  justify-self: center;
  object-fit: contain;
}

.icon-btn {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  display: inline-grid;
  place-items: center;
  background: #f0f3f7;
  color: var(--text);
}

.icon-btn svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.icon-btn--ghost {
  background: transparent;
}

.orders-link {
  min-height: 38px;
  border-radius: 999px;
  padding: 0 14px;
  color: #344054;
  background: #eef3f9;
  font-size: 0.85rem;
  font-weight: 800;
  white-space: nowrap;
}

.checkout-steps {
  position: sticky;
  top: 68px;
  z-index: 25;
  background: rgba(244, 246, 248, 0.94);
  border-bottom: 1px solid #e8edf2;
  backdrop-filter: blur(10px);
}

.checkout-steps__inner {
  width: min(100%, 920px);
  margin: 0 auto;
  padding: 10px clamp(14px, 4vw, 24px);
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.step-dot {
  min-width: 0;
  min-height: 34px;
  border-radius: 999px;
  background: #e8edf2;
  color: #667085;
  font-size: 0.78rem;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
}

.step-dot.is-active {
  background: var(--green);
  color: #fff;
}

.step-dot.is-complete {
  background: #d8f1dd;
  color: var(--green-dark);
}

.checkout-shell {
  width: min(100%, 920px);
  margin: 0 auto;
  padding: 16px clamp(12px, 4vw, 24px) 34px;
}

.page-step {
  display: none;
}

.page-step.is-active {
  display: block;
}

.offer-card,
.checkout-card {
  background: var(--surface);
  border: 1px solid #e7ebf0;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.offer-card {
  max-width: 650px;
  margin: 0 auto;
}

.banner-frame {
  background: #d7efe5;
  overflow: hidden;
}

.banner-frame img {
  width: 100%;
  height: auto;
  object-fit: contain;
}

.offer-body {
  padding: clamp(16px, 4vw, 26px);
}

.offer-title {
  display: grid;
  gap: 10px;
}

.offer-title h1 {
  margin: 0;
  font-size: clamp(1.55rem, 3.5vw, 2.45rem);
  line-height: 1.08;
  font-weight: 900;
  color: #1f2937;
}

.price-chip {
  width: fit-content;
  max-width: 100%;
  border-radius: 999px;
  padding: 8px 12px;
  background: var(--yellow);
  color: #202124;
  font-weight: 900;
  box-shadow: inset 0 -2px 0 rgba(0, 0, 0, 0.08);
}

.trust-row {
  margin-top: 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.trust-row span {
  border: 1px solid #dfe6ed;
  border-radius: 999px;
  padding: 7px 10px;
  background: #fbfcfe;
  color: #415061;
  font-size: 0.78rem;
  font-weight: 800;
}

.quantity-panel {
  margin-top: 22px;
}

.section-title {
  display: grid;
  gap: 4px;
}

.section-title h2 {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: clamp(1.15rem, 2.6vw, 1.45rem);
  line-height: 1.15;
  color: #3b4553;
  font-weight: 900;
}

.section-title svg {
  width: 22px;
  height: 22px;
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.section-title p {
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 700;
}

.section-title p.is-ready {
  color: var(--green-dark);
}

.plan-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 16px;
}

.plan-card {
  position: relative;
  min-width: 0;
  min-height: 146px;
  padding: 18px 14px 14px;
  border: 2px solid var(--line-strong);
  border-radius: var(--radius);
  background: #fff;
  color: var(--text);
  display: grid;
  justify-items: start;
  align-content: space-between;
  gap: 10px;
  text-align: left;
  transition: transform 0.16s ease, border-color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease;
}

.plan-card strong {
  font-size: clamp(1.05rem, 4vw, 1.32rem);
  line-height: 1.05;
  font-weight: 900;
}

.plan-card .bonus {
  display: grid;
  grid-template-columns: 24px 1fr;
  gap: 8px;
  align-items: center;
  color: #4c596a;
  font-size: clamp(0.76rem, 2.7vw, 0.88rem);
  line-height: 1.2;
  font-weight: 900;
}

.cash-bill {
  width: 24px;
  height: 16px;
  border-radius: 2px;
  background: var(--green-dark);
  position: relative;
}

.cash-bill::after {
  content: "$";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 900;
}

.plan-price {
  color: #647084;
  font-size: clamp(0.92rem, 3vw, 1.05rem);
}

.plan-price b {
  color: #4c596a;
  font-size: clamp(1.08rem, 3.4vw, 1.32rem);
}

.featured-ribbon {
  position: absolute;
  top: -13px;
  left: 16px;
  right: 16px;
  height: 27px;
  display: grid;
  place-items: center;
  background: var(--red);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 900;
  border-radius: 4px 4px 0 0;
}

.featured-ribbon::before {
  content: "";
  width: 0;
  height: 0;
  border-left: 11px solid transparent;
  border-right: 11px solid transparent;
  border-top: 11px solid var(--red);
  position: absolute;
  bottom: -10px;
}

.plan-card.is-featured,
.plan-card.is-selected {
  background: var(--green-soft);
  border-color: #506070;
}

.plan-card.is-selected {
  box-shadow: 0 0 0 3px rgba(31, 141, 65, 0.16);
  transform: translateY(-1px);
}

.manual-panel {
  margin-top: 18px;
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr) 52px;
  align-items: stretch;
  gap: 10px;
}

.qty-btn {
  min-height: 62px;
  border-radius: var(--radius);
  background: #1f2937;
  color: #fff;
  display: grid;
  place-items: center;
}

.qty-btn svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.qty-field {
  min-width: 0;
  border: 2px solid #d8dee7;
  border-radius: var(--radius);
  background: #fff;
  padding: 8px 12px;
  display: grid;
  gap: 2px;
}

.qty-field span {
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 900;
}

.qty-field input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
  font-size: 1.45rem;
  line-height: 1.15;
  font-weight: 900;
}

.min-help {
  margin: 10px 0 0;
  color: #606c7a;
  font-size: 0.88rem;
  font-weight: 700;
}

.summary-bar {
  margin-top: 16px;
  border: 1px solid #dfe6ed;
  border-radius: var(--radius);
  background: var(--surface-soft);
  display: grid;
  grid-template-columns: 1fr 1fr;
  overflow: hidden;
}

.summary-bar div {
  padding: 13px 14px;
  display: grid;
  gap: 4px;
}

.summary-bar div + div {
  border-left: 1px solid #dfe6ed;
}

.summary-bar span,
.mobile-buybar span {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.summary-bar strong,
.mobile-buybar strong {
  color: #1f2937;
  font-size: 1.14rem;
  line-height: 1.1;
}

.primary-button {
  width: 100%;
  min-height: 52px;
  margin-top: 16px;
  border-radius: var(--radius);
  background: var(--green);
  color: #fff;
  font-weight: 900;
  box-shadow: 0 12px 24px rgba(31, 141, 65, 0.24);
}

.primary-button:hover:not(:disabled) {
  background: var(--green-dark);
}

.primary-button:disabled {
  background: #cbd5e1;
  color: #667085;
  box-shadow: none;
  cursor: not-allowed;
}

.checkout-card {
  max-width: 560px;
  margin: 0 auto;
  padding: clamp(18px, 5vw, 28px);
}

.checkout-card__head {
  display: grid;
  gap: 6px;
  margin-bottom: 18px;
}

.checkout-card__head h2,
.success-card h2 {
  margin: 0;
  color: #2f3a4b;
  font-size: clamp(1.35rem, 5vw, 1.9rem);
  line-height: 1.12;
  font-weight: 900;
}

.checkout-card__head p,
.success-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.98rem;
  font-weight: 650;
}

.buyer-form {
  display: grid;
  gap: 13px;
}

.buyer-form label,
.pix-copy {
  display: grid;
  gap: 6px;
}

.buyer-form span,
.pix-copy span {
  color: #3f4b5d;
  font-size: 0.86rem;
  font-weight: 900;
}

.buyer-form input,
.pix-copy textarea {
  width: 100%;
  border: 2px solid #d9e0e8;
  border-radius: var(--radius);
  background: #fff;
  color: #1f2937;
  outline: 0;
}

.buyer-form input {
  min-height: 50px;
  padding: 0 13px;
}

.buyer-form input:focus,
.pix-copy textarea:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(31, 141, 65, 0.14);
}

.form-error {
  min-height: 20px;
  margin: 0;
  color: #b42318;
  font-size: 0.9rem;
  font-weight: 800;
}

.payment-method {
  border: 2px solid #d8e6da;
  border-radius: var(--radius);
  padding: 14px;
  display: grid;
  grid-template-columns: 60px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  background: #f5fff6;
}

.pix-mark {
  min-height: 42px;
  border-radius: var(--radius);
  display: grid;
  place-items: center;
  background: #00b686;
  color: #fff;
  font-weight: 900;
}

.payment-method strong {
  display: block;
  line-height: 1.15;
}

.payment-method small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-weight: 700;
}

.order-summary {
  margin-top: 16px;
  border: 1px solid #dde5ee;
  border-radius: var(--radius);
  padding: 14px;
  background: #fbfcfe;
}

.order-summary h3 {
  margin: 0 0 10px;
  font-size: 1rem;
}

.order-summary dl {
  margin: 0;
  display: grid;
  gap: 10px;
}

.order-summary dl div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: #465367;
}

.order-summary dt,
.order-summary dd {
  margin: 0;
}

.order-summary dd {
  color: #1f2937;
  font-weight: 900;
  text-align: right;
}

.upsell-button {
  width: 100%;
  min-height: 44px;
  margin-top: 14px;
  border-radius: var(--radius);
  border: 1px solid #badbc3;
  background: #eaf8ee;
  color: var(--green-dark);
  font-weight: 900;
}

.security-check {
  margin-top: 16px;
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  color: #3c4858;
  font-size: 0.92rem;
  line-height: 1.35;
  font-weight: 750;
}

.security-check input {
  width: 20px;
  height: 20px;
  accent-color: var(--green);
}

.pix-card {
  text-align: center;
}

.pix-status {
  border-radius: var(--radius);
  padding: 12px 14px;
  background: #fff8df;
  color: #58430a;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  font-weight: 900;
}

.pix-status strong {
  font-variant-numeric: tabular-nums;
}

.qr-code {
  width: min(260px, 78vw);
  height: auto;
  margin: 18px auto;
  border: 1px solid #dce2ea;
  border-radius: var(--radius);
  padding: 8px;
  background: #fff;
}

.pix-copy {
  margin-top: 16px;
  text-align: left;
}

.pix-copy textarea {
  min-height: 104px;
  resize: none;
  padding: 12px;
  color: #263241;
  font-size: 0.82rem;
  line-height: 1.35;
}

.pix-guide {
  margin: 18px 0 0;
  padding: 0;
  display: grid;
  gap: 10px;
  list-style: none;
  text-align: left;
}

.pix-guide li {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  color: #465367;
  font-weight: 750;
}

.pix-guide span {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: var(--green);
  color: #fff;
  font-weight: 900;
}

.success-card {
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 12px;
}

.success-card img {
  width: 64px;
  height: 64px;
}

.legal-footer {
  width: min(100%, 920px);
  margin: 0 auto;
  padding: 8px clamp(16px, 4vw, 24px) calc(28px + env(safe-area-inset-bottom));
  color: #2e3542;
}

.brand-strip {
  margin: 0 auto 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(20px, 7vw, 46px);
}

.brand-strip img {
  max-width: 96px;
  max-height: 42px;
  width: auto;
  height: auto;
  object-fit: contain;
}

.brand-strip img:nth-child(2) {
  max-width: 56px;
  max-height: 56px;
}

.legal-footer p {
  margin: 0;
  font-size: clamp(0.74rem, 2.5vw, 0.9rem);
  line-height: 1.55;
  text-align: justify;
  font-weight: 700;
}

.legal-actions {
  margin-top: 12px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

.legal-actions button,
.legal-actions a {
  min-height: 34px;
  border-radius: 999px;
  padding: 7px 11px;
  background: #e8edf2;
  color: #344054;
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 900;
}

.mobile-buybar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 35;
  padding: 10px clamp(12px, 4vw, 18px) calc(10px + env(safe-area-inset-bottom));
  background: rgba(255, 255, 255, 0.96);
  border-top: 1px solid #dfe6ed;
  display: none;
  grid-template-columns: minmax(0, 1fr) minmax(126px, 42%);
  gap: 12px;
  align-items: center;
  box-shadow: 0 -12px 25px rgba(28, 42, 59, 0.1);
}

.mobile-buybar .primary-button {
  margin: 0;
  min-height: 46px;
}

.modal {
  width: min(92vw, 540px);
  max-height: min(82vh, 680px);
  border: 0;
  border-radius: var(--radius);
  padding: 0;
  background: #fff;
  color: var(--text);
  box-shadow: 0 30px 80px rgba(15, 23, 42, 0.28);
}

.modal::backdrop {
  background: rgba(15, 23, 42, 0.54);
}

.modal__head {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  background: #fff;
  border-bottom: 1px solid #e7ebf0;
}

.modal__head h2 {
  margin: 0;
  font-size: 1.25rem;
}

.orders-list,
.legal-modal-text {
  padding: 16px;
  overflow: auto;
}

.order-item {
  border: 1px solid #e0e6ee;
  border-radius: var(--radius);
  padding: 12px;
  display: grid;
  gap: 8px;
  background: #fbfcfe;
}

.order-item + .order-item {
  margin-top: 10px;
}

.order-item strong,
.order-item span {
  overflow-wrap: anywhere;
}

.empty-state {
  color: var(--muted);
  font-weight: 800;
}

.legal-modal-text {
  color: #3f4b5d;
  line-height: 1.55;
  font-weight: 650;
}

.legal-modal-text p {
  margin: 0 0 12px;
}

.legal-modal-text p:last-child {
  margin-bottom: 0;
}

@media (min-width: 760px) {
  .checkout-shell {
    padding-top: 22px;
  }

  .offer-body {
    padding-top: 24px;
  }

  .primary-button {
    min-height: 56px;
  }
}

@media (max-width: 640px) {
  body.has-mobile-buybar {
    padding-bottom: 74px;
  }

  .topbar__inner {
    height: 62px;
    grid-template-columns: 40px 1fr auto;
  }

  .topbar__logo {
    width: 42px;
    height: 42px;
  }

  .checkout-steps {
    top: 62px;
  }

  .checkout-steps__inner {
    gap: 6px;
  }

  .step-dot {
    min-height: 30px;
    font-size: 0.7rem;
  }

  .checkout-shell {
    padding-top: 12px;
  }

  .offer-card,
  .checkout-card {
    box-shadow: 0 8px 22px rgba(28, 42, 59, 0.08);
  }

  .plan-grid {
    gap: 12px;
  }

  .plan-card {
    min-height: 138px;
    padding: 17px 11px 12px;
  }

  .featured-ribbon {
    left: 10px;
    right: 10px;
  }

  .orders-link {
    max-width: 112px;
    padding: 0 10px;
    font-size: 0.76rem;
  }

  .mobile-buybar {
    display: grid;
  }

  .mobile-buybar.is-hidden {
    display: none;
  }
}

@media (max-width: 390px) {
  .offer-body {
    padding-inline: 12px;
  }

  .plan-grid {
    gap: 10px;
  }

  .plan-card {
    min-height: 134px;
    padding: 16px 9px 10px;
  }

  .plan-card .bonus {
    grid-template-columns: 20px 1fr;
    gap: 6px;
  }

  .cash-bill {
    width: 20px;
    height: 14px;
  }

  .manual-panel {
    grid-template-columns: 48px minmax(0, 1fr) 48px;
    gap: 8px;
  }

  .summary-bar strong,
  .mobile-buybar strong {
    font-size: 1rem;
  }
}

@media (max-width: 340px) {
  .step-dot {
    font-size: 0.64rem;
  }

  .plan-card strong {
    font-size: 0.98rem;
  }

  .plan-price b {
    font-size: 1rem;
  }
}
