:root {
  --bg: #fff;
  --panel: #f7f7f8;
  --panel-strong: #fff;
  --line: #e7e7e9;
  --text: #090909;
  --muted: #66676d;
  --orange: #ff724d;
  --orange-dark: #f45d36;
  --orange-soft: #fff0eb;
}

* { box-sizing: border-box; }

html,
body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.45;
}

body {
  position: relative;
  isolation: isolate;
}

body::before {
  content: "";
  position: fixed;
  z-index: -1;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 8% 32%, rgba(217, 216, 255, .6), transparent 29%),
    radial-gradient(circle at 91% 24%, rgba(218, 242, 255, .68), transparent 27%),
    radial-gradient(circle at 72% 92%, rgba(255, 223, 213, .44), transparent 25%);
}

.application-layout {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, .96fr) minmax(0, 1.04fr);
}

.application-intro {
  padding: 30px 5vw 72px;
  border-right: 1px solid rgba(9, 9, 9, .08);
}

.app-logo {
  display: block;
  width: 154px;
  height: 46px;
  margin-bottom: 30px;
}

.app-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: left center;
  filter: brightness(0);
}

.program-pill {
  display: inline-block;
  padding: 8px 16px;
  border: 1px solid rgba(255, 114, 77, .28);
  border-radius: 999px;
  background: rgba(255, 255, 255, .7);
  color: var(--orange-dark);
  font-size: .74rem;
  font-weight: 850;
  letter-spacing: .16em;
  box-shadow: 0 8px 24px rgba(23, 18, 15, .04);
}

.application-intro h1 {
  max-width: 700px;
  margin: 25px 0 24px;
  font-size: clamp(2.65rem, 4vw, 4.55rem);
  line-height: 1.02;
  letter-spacing: -.052em;
}

.application-intro h1 span { color: var(--orange); }

.intro-copy {
  max-width: 680px;
  margin: 0 0 44px;
  color: var(--muted);
  font-size: 1.14rem;
}

.benefit-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.benefit-grid article {
  min-height: 240px;
  padding: 25px 26px;
  border: 1px solid rgba(9, 9, 9, .06);
  border-radius: 24px;
  background: rgba(247, 247, 248, .9);
  box-shadow: 0 14px 40px rgba(22, 20, 18, .045);
}

.benefit-grid article:nth-child(2),
.benefit-grid article:nth-child(3) {
  background: rgba(255, 255, 255, .82);
}

.benefit-grid h2 {
  margin: 0 0 18px;
  color: var(--orange-dark);
  font-size: .86rem;
  letter-spacing: .17em;
  text-transform: uppercase;
}

.benefit-grid ul {
  margin: 0;
  padding-left: 20px;
  color: #3f4044;
}

.benefit-grid li { margin: 11px 0; }
.benefit-grid li::marker { color: var(--orange); }

.wizard-panel {
  display: flex;
  align-items: center;
  padding: 36px 4vw 62px;
}

.wizard-panel form {
  width: 100%;
  max-width: 820px;
  margin: auto;
  padding: 42px 48px;
  border: 1px solid rgba(9, 9, 9, .07);
  border-radius: 26px;
  background: rgba(255, 255, 255, .91);
  box-shadow: 0 24px 70px rgba(35, 29, 26, .09);
  backdrop-filter: blur(14px);
}

.progress-meta {
  display: flex;
  justify-content: space-between;
  color: #85868b;
  font-size: .77rem;
  font-weight: 850;
  letter-spacing: .18em;
}

.progress-track {
  height: 7px;
  margin: 17px 0 33px;
  overflow: hidden;
  border-radius: 999px;
  background: #eeeef0;
}

.progress-track i {
  display: block;
  width: 25%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--orange-dark), #ff9a7f);
  transition: width .3s ease;
}

.form-step { display: none; }
.form-step.active { display: block; }

.form-step > h2 {
  margin: 0 0 5px;
  font-size: 1.8rem;
  letter-spacing: -.025em;
}

.form-step > p {
  margin: 0 0 30px;
  color: var(--muted);
}

label,
legend {
  display: block;
  margin-bottom: 22px;
  color: #242426;
  font-size: .94rem;
  font-weight: 750;
}

input,
select,
textarea {
  display: block;
  width: 100%;
  margin-top: 9px;
  padding: 13px 15px;
  border: 1px solid #dddde1;
  border-radius: 10px;
  outline: none;
  background: #fff;
  color: var(--text);
  font: inherit;
  transition: border-color .2s, box-shadow .2s;
}

textarea {
  min-height: 118px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--orange);
  box-shadow: 0 0 0 4px rgba(255, 114, 77, .13);
}

::placeholder { color: #a2a2a7; }

select {
  display: block;
  width: 100%;
  margin-top: 9px;
  padding: 13px 42px 13px 15px;
  border: 1px solid #dddde1;
  border-radius: 10px;
  outline: none;
  background: #fff;
  color: var(--text);
  font: inherit;
}

.conditional-fields[hidden] { display: none; }

.bank-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 14px;
  padding-top: 2px;
}

.two-col,
.source-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.two-col label { margin-bottom: 12px; }

fieldset {
  margin: 0 0 22px;
  padding: 0;
  border: 0;
}

.source-grid label,
.radio-row label,
.confirm-list label {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0;
  padding: 12px 14px;
  border: 1px solid #e1e1e4;
  border-radius: 11px;
  background: #fafafa;
  color: #3f4044;
  font-weight: 550;
  transition: border-color .2s, background .2s;
}

.source-grid label:has(input:checked),
.radio-row label:has(input:checked),
.confirm-list label:has(input:checked) {
  border-color: rgba(255, 114, 77, .58);
  background: var(--orange-soft);
}

.source-grid input,
.radio-row input,
.confirm-list input,
.final-confirm input {
  flex: none;
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--orange);
}

.radio-row {
  display: flex;
  gap: 12px;
}

.confirm-list {
  display: grid;
  gap: 13px;
}

.review-box {
  margin-bottom: 28px;
  padding: 24px;
  border: 1px solid #e3e3e5;
  border-radius: 15px;
  background: var(--panel);
  color: #44454a;
}

.terms-box {
  max-height: 500px;
  overflow-y: auto;
  margin-bottom: 24px;
  padding: 24px 25px;
  border: 1px solid #e3e3e5;
  border-radius: 16px;
  background: var(--panel);
  color: #44454a;
  scrollbar-color: var(--orange) #e8e8ea;
  scrollbar-width: thin;
}

.terms-box h3 {
  margin: 0 0 6px;
  color: var(--text);
  font-size: 1.04rem;
}

.terms-box h4 {
  margin: 28px 0 10px;
  color: var(--orange-dark);
  font-size: .79rem;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.terms-box p {
  margin: 0 0 13px;
  font-size: .88rem;
  line-height: 1.62;
}

.terms-box a { color: var(--orange-dark); }

.acceptance {
  margin-top: 30px;
  padding: 18px;
  border: 1px solid rgba(255, 114, 77, .28);
  border-radius: 13px;
  background: var(--orange-soft);
}

.acceptance h4 { margin-top: 0; }
.acceptance p { margin-bottom: 0; }

.final-confirm {
  align-items: center;
  padding: 14px 16px;
  border: 1px solid #e1e1e4;
  border-radius: 11px;
  background: #fafafa;
}

.form-actions {
  display: flex;
  justify-content: space-between;
  margin-top: 28px;
}

.form-actions button {
  padding: 13px 22px;
  border-radius: 9px;
  font-weight: 850;
  letter-spacing: .045em;
  cursor: pointer;
  transition: transform .18s, box-shadow .18s, background .18s;
}

.form-actions button:hover { transform: translateY(-1px); }

.back {
  border: 1px solid #dddddf;
  background: #f5f5f6;
  color: #36363a;
}

.continue {
  margin-left: auto;
  border: 0;
  background: var(--orange);
  color: #fff;
  box-shadow: 0 12px 28px rgba(255, 99, 61, .23);
}

.continue:hover {
  background: #ff8463;
  box-shadow: 0 14px 32px rgba(255, 99, 61, .28);
}

.success {
  display: none;
  margin-top: 20px;
  padding: 16px;
  border: 1px solid #e3e3e5;
  border-radius: 10px;
  background: #f7f7f8;
  color: #44454a;
}

.success.is-success {
  border-color: #9ed8b1;
  background: #eaf8ef;
  color: #176b35;
}

.success.is-error {
  border-color: #f0b0a0;
  background: #fff0eb;
  color: #9b351d;
}

.final-confirm {
  display: flex;
  gap: 12px;
}

@media (max-width: 1050px) {
  .application-layout { grid-template-columns: 1fr; }
  .application-intro {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .benefit-grid article { min-height: auto; }
  .wizard-panel { align-items: flex-start; }
}

@media (max-width: 640px) {
  .application-intro { padding: 22px 18px 40px; }
  .application-intro h1 { font-size: 2.55rem; }
  .benefit-grid,
  .two-col,
  .source-grid,
  .bank-fields { grid-template-columns: 1fr; }
  .benefit-grid { gap: 12px; }
  .wizard-panel { padding: 20px 12px 40px; }
  .wizard-panel form { padding: 27px 18px; }
  .source-grid { gap: 9px; }
}
