:root {
  --font-sans: "IBM Plex Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  --bg-page: #F6F4FF;
  --surface: #FFFFFF;
  --ink: #071F36;
  --text-secondary: #4A5B70;
  --primary: #0068B5;
  --primary-hover: #004F8A;
  --border: #D2DEEB;

  --muted: var(--text-secondary);
  --line: var(--border);
  --line-strong: var(--border);
  --blue: var(--primary);
  --blue-hover: var(--primary-hover);
  --paper: var(--surface);
  --soft: var(--bg-page);
  --success: #0f7a46;
  --danger: #b42318;
  --shadow: 0 18px 44px rgba(7, 31, 54, .08);
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  font-family: var(--font-sans);
  color: var(--ink);
  background: #f6f4ff;
}

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

button,
input,
select {
  font: inherit;
}

.onboarding-header {
  position: sticky;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 100;
  height: 86px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 0 clamp(20px, 3vw, 48px);
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.brand-logo {
  width: min(270px, 58vw);
  height: auto;
  display: block;
}

.site-link {
  color: var(--muted);
  font-weight: 700;
}

.onboarding-shell {
  width: min(100%, 1880px);
  margin: 0 auto;
  padding: 34px clamp(20px, 3vw, 48px) 48px;
}

.stepper {
  display: grid;
  grid-template-columns: repeat(5, minmax(180px, 1fr));
  gap: 18px;
  overflow-x: auto;
  padding-bottom: 14px;
}

.step-link {
  min-width: 180px;
  display: flex;
  align-items: center;
  gap: 14px;
  border: 0;
  background: transparent;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}

.step-link span {
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  color: var(--ink);
  font-size: 30px;
  line-height: 1;
}

.step-link strong {
  color: var(--ink);
  font-size: clamp(18px, 1.45vw, 28px);
  font-weight: 500;
  line-height: 1.2;
}

.step-link.active span,
.step-link.complete span {
  border-color: var(--blue);
  background: var(--blue);
  color: #fff;
}

.step-link.active strong,
.step-link.complete strong {
  color: var(--blue);
}

.progress-track {
  height: 12px;
  margin: 4px 0 32px;
  background: #cfd0d4;
  overflow: hidden;
}

.progress-track span {
  display: block;
  width: 20%;
  height: 100%;
  background: var(--blue);
  transition: width .22s ease;
}

.wizard {
  display: grid;
  gap: 24px;
}

.panel {
  display: none;
  min-height: 400px;
  padding: clamp(10px, 1.5vw, 18px) 0 0;
}

.panel.active {
  display: block;
}

.panel-head {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
}

.panel-head.left {
  display: block;
}

h1,
h2 {
  margin: 0;
  color: #05070a;
  line-height: 1.1;
}

h1 {
  font-size: clamp(30px, 2.2vw, 42px);
  font-weight: 700;
}

h2 {
  font-size: clamp(22px, 1.7vw, 30px);
}

p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: clamp(17px, 1.25vw, 23px);
  line-height: 1.35;
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 26px 36px;
}

.field-grid.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

label {
  display: grid;
  gap: 8px;
  color: #1f2933;
  font-weight: 700;
}

label small {
  color: #555b64;
  font-size: 15px;
  font-weight: 600;
}

input,
select {
  width: 100%;
  min-height: 46px;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
  color: var(--ink);
  outline: none;
  font-weight: 500;
}

input:focus,
select:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(11, 143, 240, .12);
  background: #fff;
}

input[type="file"] {
  display: flex;
  align-items: center;
  padding: 15px;
}

.captcha-block {
  width: min(100%, 420px);
  margin-top: 36px;
}

.captcha-widget {
  min-height: 78px;
}

.captcha-help {
  margin-top: 10px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
}

.captcha-help.error {
  color: var(--danger);
}

.captcha-help.success {
  color: var(--success);
}

.agreement-box {
  max-height: min(62vh, 640px);
  overflow: auto;
  margin: 0 0 22px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: #fff;
  padding: 24px clamp(16px, 2vw, 28px);
}

.agreement-loading,
.agreement-error {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
}

.agreement-error {
  color: var(--danger);
}

.agreement-box .rich-text-block h2,
.agreement-box .w-richtext h2 {
  margin: 28px 0 12px;
  color: var(--ink);
  font-size: clamp(18px, 1.5vw, 22px);
  font-weight: 700;
  line-height: 1.35;
}

.agreement-box .rich-text-block h3,
.agreement-box .w-richtext h3,
.agreement-box .rich-text-block h6,
.agreement-box .w-richtext h6 {
  margin: 22px 0 10px;
  color: var(--ink);
  font-size: 16px;
  font-weight: 700;
}

.agreement-box .rich-text-block p,
.agreement-box .w-richtext p,
.agreement-box .paragraph-3,
.agreement-box .paragraph-4,
.agreement-box .address {
  margin: 0 0 12px;
  color: #4a4f57;
  font-size: 15px;
  line-height: 1.6;
}

.agreement-box .paragraph-4 {
  margin-top: 24px;
  font-size: 17px;
  font-weight: 700;
  color: var(--ink);
}

.agreement-box .heading-23 {
  margin: 0;
  color: #15194d;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.45;
}

.agreement-box .table-content-wraper {
  margin: 18px 0 28px;
  border: 1px solid #222;
}

.agreement-box .table-content {
  display: grid;
  grid-template-columns: minmax(180px, 28%) minmax(0, 1fr);
  border-top: 1px solid #222;
}

.agreement-box .table-content:first-child {
  border-top: 0;
}

.agreement-box .table-left,
.agreement-box .table-right {
  padding: 18px;
  border-right: 1px solid #222;
}

.agreement-box .table-right {
  border-right: 0;
}

.agreement-box .table-content.space-0 {
  grid-template-columns: 90px minmax(0, 1.4fr) minmax(120px, .7fr) minmax(120px, .7fr);
}

.agreement-box .table-content.space-0 .table-right.border {
  border-right: 1px solid #222;
}

.agreement-box .table-content.space-0 .table-right.border:last-child {
  border-right: 0;
}

.agreement-box .list {
  margin: 0;
  padding-left: 0;
  list-style: none;
}

.agreement-box .agreement-schedule,
.agreement-box .service-wrap,
.agreement-box .content-table-box {
  margin-top: 24px;
}

.agreement-box .agreement-schedule--block {
  margin: 16px 0 24px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
}

.agreement-box .text-block-14,
.agreement-box .text-block-15 {
  margin: 0 0 10px;
  font-size: 15px;
  font-weight: 600;
}

.agreement-box .signature {
  margin-top: 18px;
}

.agreement-box a {
  color: var(--blue);
  text-decoration: underline;
}

.agreement-box strong,
.agreement-box em {
  font-weight: 700;
}

.check-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  color: #4a4f57;
  font-size: clamp(20px, 1.7vw, 30px);
  font-weight: 500;
}

.check-row input {
  width: 20px;
  min-height: 20px;
  height: 20px;
  margin-top: 7px;
  accent-color: var(--blue);
}

.split-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(380px, .72fr);
  gap: clamp(36px, 6vw, 86px);
  align-items: start;
}

.action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin: 36px 0 24px;
}

.btn {
  min-height: 58px;
  min-width: 190px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 12px 22px;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  cursor: pointer;
}

.btn.primary {
  background: var(--blue);
  color: #fff;
}

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

.btn.secondary {
  border-color: var(--blue);
  background: #fff;
  color: var(--blue);
}

.btn.compact {
  min-width: 0;
  min-height: 46px;
  margin-top: 14px;
  font-size: 16px;
}

.btn:disabled {
  border-color: #d8dde5;
  background: #e7ebf0;
  color: #9aa2ad;
  cursor: not-allowed;
}

.helper-text {
  max-width: 760px;
  color: #808080;
}

.faq-card {
  display: grid;
  gap: 14px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .96), rgba(248, 250, 252, .96)),
    #fff;
  box-shadow: 0 18px 44px rgba(15, 23, 42, .06);
  position: sticky;
  top: 24px;
}

.faq-card h2 {
  margin-bottom: 2px;
}

.side-kicker {
  width: fit-content;
  padding: 6px 9px;
  border: 1px solid rgba(11, 143, 240, .22);
  border-radius: 999px;
  background: rgba(11, 143, 240, .07);
  color: var(--blue);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.assurance-panel,
.optional-banner {
  padding: 16px;
  border: 1px solid #cfe0f2;
  border-radius: 12px;
  background: #f2f7fc;
}

.assurance-panel strong,
.optional-banner strong {
  display: block;
  color: var(--ink);
  font-size: 16px;
  line-height: 1.2;
}

.assurance-panel p {
  margin-top: 7px;
  color: #536274;
  font-size: 15px;
  line-height: 1.45;
  font-weight: 500;
}

.optional-banner {
  display: grid;
  gap: 5px;
  margin: 0 0 24px;
  background: #f6fbff;
}

.optional-banner span {
  color: #536274;
  font-weight: 600;
  line-height: 1.4;
}

details {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: #565573;
  overflow: hidden;
}

summary {
  min-height: 62px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 16px 18px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.25;
  list-style: none;
}

summary::-webkit-details-marker {
  display: none;
}

summary::after {
  content: "v";
  color: #111;
  font-size: 18px;
  font-weight: 800;
}

details[open] summary::after {
  transform: rotate(180deg);
}

details p {
  padding: 0 18px 18px;
  color: #566274;
  font-size: 15px;
  line-height: 1.5;
  font-weight: 500;
}

.social-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
  margin: 26px 0;
}

.bank-frame-wrap {
  height: min(58vh, 620px);
  min-height: 430px;
  margin-top: 28px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
  box-shadow: var(--shadow);
}

.bank-frame-wrap iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

.success-message {
  display: none;
  margin-top: 16px;
  padding: 14px 16px;
  border: 1px solid #abd7bf;
  border-radius: 10px;
  background: #eff8f2;
  color: var(--success);
  font-weight: 700;
}

.success-message.show {
  display: block;
}

.manual-bank {
  margin-top: 24px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}

.manual-bank h2 {
  margin-bottom: 18px;
}

.bank-document-row {
  margin-top: 20px;
  padding: 18px 0 0;
  border-top: 1px solid var(--line);
}

.form-error {
  display: none;
  padding: 14px 16px;
  border: 1px solid #f1b4ad;
  border-radius: 10px;
  background: #fff2f0;
  color: var(--danger);
  font-weight: 700;
}

.form-error.show {
  display: block;
}

.wizard-actions {
  display: flex;
  gap: 14px;
  align-items: center;
  padding-top: 4px;
}

.wizard-actions #submitButton {
  display: none;
}

.wizard-actions.submitting #continueButton {
  display: none;
}

.wizard-actions.submitting #submitButton {
  display: inline-flex;
}

.stepper.is-hidden,
.progress-track.is-hidden,
.stepper.is-hidden,
.progress-track.is-hidden {
  display: none !important;
}

.wizard-actions.interest-step,
.wizard-actions.interest-step {
  max-width: 640px;
  width: 100%;
  margin: 8px auto 0;
  justify-content: flex-end;
}

.interest-card,
.interest-card {
  max-width: 640px;
  margin: 48px auto 0;
  padding: 48px 40px 36px;
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--shadow);
}

.interest-card h1,
.interest-card h1 {
  margin: 0 0 14px;
  font-size: clamp(28px, 3vw, 36px);
  line-height: 1.2;
}

.interest-card>p,
.interest-card>p {
  margin: 0 0 28px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.55;
}

.choice-group,
.choice-group {
  margin: 0;
  padding: 0;
  border: 0;
}

.choice-group legend,
.choice-group legend {
  margin-bottom: 16px;
  font-size: 16px;
  font-weight: 700;
}

.choice-group .req,
.choice-group .req {
  color: var(--danger);
}

.choice-option,
.choice-option {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 12px;
  cursor: pointer;
  font-size: 16px;
}

.choice-option input,
.choice-option input {
  width: 20px;
  height: 20px;
  accent-color: var(--blue);
}

.completion-card {
  max-width: 920px;
  margin: 40px auto;
  padding: 42px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  text-align: center;
  box-shadow: var(--shadow);
}

.complete-icon {
  width: 72px;
  height: 64px;
  display: grid;
  place-items: center;
  margin: 0 auto 20px;
  border-radius: 999px;
  background: var(--success);
  color: #fff;
  font-size: 16px;
  font-weight: 700;
}

pre {
  max-height: 320px;
  margin: 24px 0 0;
  padding: 18px;
  overflow: auto;
  border-radius: 10px;
  background: #f6f8fa;
  color: #2f3742;
  text-align: left;
  white-space: pre-wrap;
}

@media (max-width: 1120px) {
  .stepper {
    grid-template-columns: repeat(5, 220px);
  }

  .field-grid,
  .field-grid.three,
  .split-layout,
  .social-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 680px) {
  .onboarding-header {
    height: auto;
    align-items: flex-start;
    padding-top: 18px;
    padding-bottom: 18px;
  }

  .site-link {
    display: none;
  }

  .onboarding-shell {
    padding-left: 16px;
    padding-right: 16px;
  }

  .step-link span {
    width: 44px;
    height: 44px;
    font-size: 23px;
  }

  .step-link strong {
    font-size: 17px;
  }

  .captcha-block {
    width: 100%;
  }

  .agreement-box {
    margin-left: 0;
    margin-right: 0;
  }

  .agreement-box .table-content,
  .agreement-box .table-content.space-0 {
    grid-template-columns: 1fr;
  }

  .agreement-box .table-left,
  .agreement-box .table-right,
  .agreement-box .table-content.space-0 .table-right.border {
    border-right: 0;
    border-bottom: 1px solid #222;
  }

  .agreement-box .table-right:last-child,
  .agreement-box .table-content.space-0 .table-right.border:last-child {
    border-bottom: 0;
  }

  .btn {
    width: 100%;
    min-width: 0;
  }

  .wizard-actions {
    flex-direction: column-reverse;
  }
}

[data-bank-complete].is-verified {
  background-color: #0068b5 !important;
  color: #ffffff !important;
  border-color: #0068b5 !important;
  cursor: default;
  gap: 5px;
}

[data-bank-complete].is-verified::before {
  content: "✓ ";
  font-weight: bold;
  padding-right: 2px;
}

.stepper.is-hidden,
.progress-track.is-hidden {
  display: none !important;
}

.wizard-actions.interest-step,
.wizard-actions.interest-step {
  max-width: 640px;
  width: 100%;
  margin: 8px auto 0;
  justify-content: flex-end;
}

.interest-card,
.interest-card {
  max-width: 640px;
  margin: 48px auto 0;
  padding: 48px 40px 36px;
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--shadow);
}

.interest-card h1 {
  margin: 0 0 14px;
  font-size: clamp(28px, 3vw, 36px);
  line-height: 1.2;
}

.interest-card>p {
  margin: 0 0 28px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.55;
}

.choice-group {
  margin: 0;
  padding: 0;
  border: 0;
}

.choice-group legend {
  margin-bottom: 16px;
  font-size: 16px;
  font-weight: 700;
}

.choice-group .req {
  color: var(--danger);
}

.choice-option {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 12px;
  cursor: pointer;
  font-size: 16px;
}

.choice-option input {
  width: 20px;
  height: 20px;
  accent-color: var(--blue);
}

@media (max-width: 600px) {
  .stepper {
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
  }

  .step-link {
    scroll-snap-align: center;
  }
}

.is-hidden {
  display: none !important;
}