* { margin: 0; padding: 0; box-sizing: border-box; }
:root {
  --cream: hsl(50 33% 96%);
  --green: hsl(95 65% 45%);
  --green-d: hsl(95 65% 38%);
  --green-tint: hsl(95 60% 94%);
  --dark: hsl(240 25% 10%);
  --ink: hsl(240 25% 10%);
  --muted: hsl(240 8% 45%);
  --line: hsl(50 15% 86%);
  --red: hsl(0 84% 60%);
}
body { font-family: 'Inter', system-ui, sans-serif; background: var(--cream); color: var(--ink); line-height: 1.5; -webkit-font-smoothing: antialiased; }

/* ===== HEADER ===== */
.ck-top {
  display: flex; align-items: center; gap: 10px;
  max-width: 480px; margin: 0 auto; padding: 14px 16px;
}
.ck-back { font-size: 1.4rem; color: var(--ink); text-decoration: none; line-height: 1; }
.ck-top h1 { flex: 1; text-align: center; font-size: 1.05rem; font-weight: 800; }
.ck-safe { font-size: .76rem; color: var(--muted); font-weight: 600; white-space: nowrap; }

.ck-wrap { max-width: 480px; margin: 0 auto; padding: 6px 16px 70px; }

/* ===== CARD ===== */
.ck-card {
  background: #fff; border: 1px solid var(--line); border-radius: 18px;
  padding: 20px; margin-bottom: 16px; box-shadow: 0 4px 20px -8px hsl(240 25% 10% / .08);
}

/* ===== RESUMO ===== */
.buy-title { color: var(--green-d); font-weight: 800; font-size: .95rem; margin-bottom: 14px; }
.buy-row { display: flex; gap: 14px; align-items: center; }
.buy-row img { width: 72px; height: 72px; object-fit: contain; background: hsl(50 20% 92%); border-radius: 12px; flex-shrink: 0; }
.buy-info strong { display: block; font-size: 1rem; font-weight: 800; line-height: 1.2; }
.buy-prices { display: flex; align-items: baseline; gap: 8px; margin: 4px 0; }
.buy-old { color: #a7a49a; text-decoration: line-through; font-size: .85rem; }
.buy-now { color: var(--green-d); font-size: 1.3rem; font-weight: 900; }
.buy-save { color: var(--green-d); font-size: .8rem; font-weight: 600; }

/* ===== STEP HEAD (pílula numerada) ===== */
.step-head {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--green-tint); border-radius: 999px;
  padding: 5px 18px 5px 5px; margin-bottom: 18px;
}
.step-num {
  width: 30px; height: 30px; border-radius: 50%; background: var(--green);
  color: #fff; font-weight: 800; font-size: .95rem;
  display: grid; place-items: center;
}
.step-title { font-weight: 800; font-size: 1rem; color: var(--ink); }

/* ===== CAMPOS ===== */
.ck-label { display: block; font-size: .85rem; font-weight: 700; margin: 0 0 6px 2px; color: var(--ink); }
.ck-input { position: relative; margin-bottom: 16px; }
.ck-ico {
  position: absolute; left: 14px; top: 50%; transform: translateY(-50%);
  width: 18px; height: 18px; fill: none; stroke: #aab0ba; stroke-width: 1.8;
  stroke-linecap: round; stroke-linejoin: round; pointer-events: none;
}
.ck-input input, .ck-input select {
  width: 100%; padding: 14px 14px 14px 44px;
  border: 1.5px solid var(--line); border-radius: 12px;
  font-family: inherit; font-size: .95rem; background: #fff; color: var(--ink);
  transition: border .15s, box-shadow .15s; appearance: none;
}
.ck-input select { cursor: pointer; }
.ck-input input::placeholder { color: #b3b8c0; }
.ck-input input:focus, .ck-input select:focus {
  outline: none; border-color: var(--green); box-shadow: 0 0 0 3px hsl(95 65% 45% / .14);
}
.ck-chevron { position: absolute; right: 16px; top: 50%; transform: translateY(-50%); color: #aab0ba; pointer-events: none; font-size: .9rem; }

/* ===== Validação inline (check verde / erro) ===== */
.ck-input.ok input, .ck-input.ok select { border-color: var(--green); }
.ck-input.bad input, .ck-input.bad select { border-color: var(--red); }
.ck-input.ok input { padding-right: 36px; }
.ck-input.ok:not(:has(select))::after {
  content: "✓"; position: absolute; right: 14px; top: 50%; transform: translateY(-50%);
  color: var(--green); font-weight: 800; font-size: .95rem; pointer-events: none;
}

/* ===== PAGAMENTO ===== */
.pay-method {
  display: flex; align-items: center; gap: 14px;
  border: 1.5px solid var(--green); background: var(--green-tint);
  border-radius: 14px; padding: 14px; margin-bottom: 18px;
}
.pix-badge {
  background: var(--green); color: #fff; font-weight: 800; font-size: .85rem;
  width: 50px; height: 50px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0;
}
.pay-method-info { flex: 1; }
.pay-method-info strong { display: block; font-size: 1rem; }
.pay-method-info span { color: var(--muted); font-size: .85rem; }
.pay-check { width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--green); color: var(--green); display: grid; place-items: center; font-size: .8rem; font-weight: 800; }

.pay-trust { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; text-align: center; margin-bottom: 20px; }
.pay-trust div { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.pt-ico { font-size: 1.3rem; color: var(--green); }
.pay-trust strong { font-size: .78rem; }
.pay-trust small { color: var(--muted); font-size: .68rem; }

.pay-total {
  display: flex; align-items: center; justify-content: space-between;
  border-top: 1px solid var(--line); padding-top: 16px; margin-bottom: 16px;
}
.pay-total span { color: var(--muted); font-weight: 600; }
.pay-total strong { font-size: 1.5rem; font-weight: 900; }

.ck-pay-btn {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; padding: 17px; border: none; cursor: pointer;
  background: linear-gradient(180deg, hsl(95 60% 62%), hsl(95 65% 45%));
  color: #fff; font-family: inherit; font-weight: 800; font-size: 1.05rem;
  border-radius: 14px; text-decoration: none; letter-spacing: .5px;
  box-shadow: 0 8px 20px -6px hsl(95 65% 35% / .45); transition: transform .12s;
}
.ck-pay-btn:hover { transform: translateY(-1px); }
.ck-pay-btn:disabled { opacity: .6; cursor: not-allowed; transform: none; }
.qr-ico { font-size: 1.1rem; }

.ck-error { color: var(--red); font-size: .85rem; margin-top: 10px; text-align: center; min-height: 1em; }
.pay-secure { text-align: center; color: var(--muted); font-size: .78rem; margin-top: 12px; }

/* ===== PIX / SUCESSO ===== */
.pix-box, .success-box { text-align: center; }
.pix-box h2 { font-size: 1.35rem; font-weight: 800; }
.pix-sub { color: var(--muted); font-size: .9rem; margin: 8px 0 20px; }
.pix-qr { display: flex; justify-content: center; margin-bottom: 18px; }
.pix-qr img { width: 220px; height: 220px; border: 1px solid var(--line); border-radius: 12px; padding: 8px; background: #fff; }
.pix-copy-btn { background: var(--dark); color: #fff; border: none; cursor: pointer; font-family: inherit; font-weight: 700; font-size: .95rem; padding: 14px; border-radius: 12px; width: 100%; margin-bottom: 10px; }
.pix-code { width: 100%; border: 1px dashed var(--line); border-radius: 10px; padding: 10px; font-size: .76rem; resize: none; color: var(--muted); font-family: monospace; background: var(--cream); }
.pix-waiting { display: flex; align-items: center; justify-content: center; gap: 10px; margin-top: 18px; font-weight: 600; font-size: .92rem; }
.pix-waiting strong { color: var(--green-d); }
.pix-hint { color: var(--muted); font-size: .8rem; margin-top: 8px; }
.spinner { width: 18px; height: 18px; border: 3px solid hsl(95 65% 45% / .25); border-top-color: var(--green); border-radius: 50%; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.success-check { width: 64px; height: 64px; border-radius: 50%; background: var(--green); color: #fff; font-size: 2rem; font-weight: 800; display: grid; place-items: center; margin: 0 auto 16px; }
.success-box h2 { font-size: 1.5rem; font-weight: 800; }
.success-box p { color: var(--muted); margin: 10px 0 20px; }
