:root {
    --navy-950: #041a33;
    --navy-900: #062443;
    --navy-800: #08345f;
    --navy-700: #0a4f86;
    --cyan-500: #18bfdc;
    --cyan-100: #dcf8fc;
    --copper: #c99a73;
    --ink: #102a43;
    --muted: #61748a;
    --line: #d9e3ec;
    --surface: #ffffff;
    --surface-soft: #f5f8fb;
    --danger: #b42318;
    --success: #08785c;
    --shadow: 0 30px 80px rgba(3, 29, 57, .2);
    --radius-lg: 26px;
    --radius-md: 16px;
    --radius-sm: 10px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    min-width: 320px;
    color: var(--ink);
    background: var(--navy-950);
    font-family: "Poppins", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
}

button, input, select { font: inherit; }

a { color: inherit; }

.shell {
    width: min(1200px, calc(100% - 40px));
    margin-inline: auto;
}

.skip-link {
    position: fixed;
    z-index: 100;
    top: 12px;
    left: 12px;
    padding: 10px 16px;
    border-radius: 8px;
    color: #fff;
    background: var(--navy-950);
    transform: translateY(-160%);
}

.skip-link:focus { transform: translateY(0); }

.site-header {
    position: relative;
    z-index: 5;
    border-bottom: 1px solid rgba(255,255,255,.12);
    background: var(--navy-950);
}

.site-header__inner {
    min-height: 82px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand img {
    display: block;
    width: auto;
    height: 47px;
}

.back-link {
    color: #fff;
    font-weight: 600;
    font-size: .92rem;
    text-decoration: none;
}

.back-link span { color: var(--cyan-500); }

.back-link:hover,
.back-link:focus-visible { text-decoration: underline; text-underline-offset: 5px; }

.hero {
    position: relative;
    overflow: hidden;
    min-height: calc(100vh - 82px);
    padding: 74px 0 90px;
    background:
        radial-gradient(circle at 4% 15%, rgba(24,191,220,.16), transparent 30%),
        radial-gradient(circle at 92% 76%, rgba(201,154,115,.13), transparent 30%),
        linear-gradient(135deg, var(--navy-950), #062e56 68%, #073864);
}

.hero::before,
.hero::after {
    content: "";
    position: absolute;
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 50%;
    pointer-events: none;
}

.hero::before { width: 620px; height: 620px; right: -310px; top: -180px; }
.hero::after { width: 400px; height: 400px; left: -250px; bottom: -210px; }

.hero__grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(260px, .72fr) minmax(640px, 1.28fr);
    align-items: start;
    gap: 64px;
}

.hero__copy {
    position: sticky;
    top: 50px;
    padding-top: 58px;
    color: #fff;
}

.eyebrow,
.step-heading > p,
.success-panel > p {
    margin: 0 0 14px;
    color: var(--copper);
    font-size: .76rem;
    font-weight: 700;
    letter-spacing: .15em;
    text-transform: uppercase;
}

.hero__copy h1 {
    max-width: 520px;
    margin: 0;
    font-family: "Secular One", "Poppins", sans-serif;
    font-size: clamp(2.6rem, 5vw, 4.65rem);
    font-weight: 400;
    line-height: .98;
    letter-spacing: -.035em;
}

.hero__copy > p:not(.eyebrow) {
    max-width: 520px;
    margin: 26px 0 0;
    color: #d6e2ee;
    font-size: 1.02rem;
    line-height: 1.75;
}

.trust-row {
    display: grid;
    gap: 11px;
    margin-top: 34px;
    color: #eef7fb;
    font-size: .88rem;
    font-weight: 500;
}

.trust-row span { display: flex; align-items: center; gap: 10px; }
.trust-row span::before {
    content: "✓";
    display: grid;
    place-items: center;
    width: 21px;
    height: 21px;
    border-radius: 50%;
    color: var(--navy-950);
    background: var(--cyan-500);
    font-size: .74rem;
    font-weight: 800;
}

.application-card {
    min-width: 0;
    padding: 34px;
    border: 1px solid rgba(255,255,255,.7);
    border-radius: var(--radius-lg);
    background: rgba(255,255,255,.985);
    box-shadow: var(--shadow);
}

.progress {
    display: grid;
    grid-template-columns: auto minmax(60px, 1fr) auto;
    align-items: center;
    gap: 18px;
    margin-bottom: 34px;
    padding-bottom: 28px;
    border-bottom: 1px solid var(--line);
}

.progress__item { display: flex; align-items: center; gap: 11px; color: #8090a2; }
.progress__item > span {
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    width: 38px;
    height: 38px;
    border: 2px solid #cbd6e0;
    border-radius: 50%;
    background: #fff;
    font-weight: 700;
}

.progress__item strong,
.progress__item small { display: block; }
.progress__item strong { color: var(--ink); font-size: .82rem; }
.progress__item small { margin-top: 2px; font-size: .69rem; }
.progress__item.is-active > span,
.progress__item.is-complete > span { border-color: var(--cyan-500); color: var(--navy-950); background: var(--cyan-100); }
.progress__item.is-complete > span { color: #fff; background: var(--success); border-color: var(--success); }

.progress__line { height: 3px; overflow: hidden; border-radius: 4px; background: #dce5ed; }
.progress__line span { display: block; width: 0; height: 100%; background: var(--cyan-500); transition: width .3s ease; }
.application-card[data-active-step="2"] .progress__line span { width: 100%; }

.alert {
    margin: 0 0 24px;
    padding: 13px 15px;
    border: 1px solid #f2b8b5;
    border-radius: var(--radius-sm);
    color: var(--danger);
    background: #fff2f1;
    font-size: .88rem;
    line-height: 1.55;
}

.alert.is-success { border-color: #96d5c2; color: var(--success); background: #effbf6; }

.step-heading { margin-bottom: 28px; }
.step-heading h2,
.success-panel h2 {
    margin: 0;
    font-family: "Secular One", "Poppins", sans-serif;
    color: var(--navy-900);
    font-size: clamp(1.75rem, 3vw, 2.35rem);
    font-weight: 400;
    line-height: 1.15;
    letter-spacing: -.02em;
}
.step-heading > span,
.success-panel > span {
    display: block;
    margin-top: 10px;
    color: var(--muted);
    font-size: .92rem;
    line-height: 1.6;
}

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 19px; }
.form-grid > .field--full { grid-column: 1 / -1; }
.field { min-width: 0; margin-bottom: 19px; }
.field label {
    display: block;
    margin-bottom: 8px;
    color: var(--navy-900);
    font-size: .84rem;
    font-weight: 650;
    line-height: 1.45;
}
.field label span { color: #d92d20; }
.field input,
.field select {
    width: 100%;
    min-height: 52px;
    padding: 13px 15px;
    border: 1px solid #cbd7e2;
    border-radius: var(--radius-sm);
    outline: none;
    color: var(--ink);
    background: var(--surface-soft);
    transition: border-color .16s ease, box-shadow .16s ease, background .16s ease;
}
.field input::placeholder { color: #91a0af; }
.field input:hover,
.field select:hover { border-color: #aebdca; }
.field input:focus,
.field select:focus { border-color: var(--cyan-500); background: #fff; box-shadow: 0 0 0 4px rgba(24,191,220,.13); }
.field input[aria-invalid="true"],
.field select[aria-invalid="true"] { border-color: #d92d20; background: #fff8f7; }
.field__error { display: block; min-height: 0; margin-top: 6px; color: var(--danger); font-size: .76rem; }
.field__error:empty { display: none; }
.field__hint { display: block; margin-top: 7px; color: var(--muted); font-size: .74rem; line-height: 1.45; }

.consent {
    display: grid;
    grid-template-columns: 20px 1fr;
    gap: 11px;
    margin: 4px 0 0;
    color: #445970;
    font-size: .79rem;
    line-height: 1.62;
    cursor: pointer;
}
.consent input { width: 18px; height: 18px; margin: 3px 0 0; accent-color: var(--navy-700); }
.consent a { color: var(--navy-700); font-weight: 600; }
.consent-error { margin-left: 31px; }

.primary-button {
    display: flex;
    width: 100%;
    min-height: 56px;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin-top: 28px;
    padding: 15px 22px;
    border: 0;
    border-radius: 11px;
    color: #fff;
    background: var(--navy-700);
    box-shadow: 0 12px 25px rgba(10,79,134,.22);
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    transition: transform .16s ease, background .16s ease, box-shadow .16s ease;
}
.primary-button:hover:not(:disabled),
.primary-button:focus-visible:not(:disabled) { transform: translateY(-1px); background: var(--navy-800); box-shadow: 0 15px 30px rgba(10,79,134,.28); }
.primary-button:disabled { cursor: not-allowed; color: #8695a4; background: #dce4eb; box-shadow: none; }
.primary-button.is-loading { cursor: wait; }

.saved-profile {
    display: grid;
    grid-template-columns: 1fr 1fr auto;
    align-items: center;
    gap: 18px;
    margin-bottom: 22px;
    padding: 15px 17px;
    border: 1px solid #d9e7ef;
    border-radius: 12px;
    background: #f2f8fb;
}
.saved-profile small,
.saved-profile strong { display: block; }
.saved-profile small { color: var(--muted); font-size: .68rem; text-transform: uppercase; letter-spacing: .08em; }
.saved-profile strong { margin-top: 3px; font-size: .82rem; overflow-wrap: anywhere; }
.saved-profile button { padding: 8px 0; border: 0; color: var(--navy-700); background: transparent; font-size: .78rem; font-weight: 700; text-decoration: underline; cursor: pointer; }

.upload-list { display: grid; gap: 14px; }
.upload-card {
    display: grid;
    grid-template-columns: 45px 1fr;
    gap: 16px;
    padding: 19px;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--surface-soft);
    transition: border-color .18s ease, background .18s ease;
}
.upload-card.is-uploading { border-color: var(--cyan-500); background: #f4fdff; }
.upload-card.is-complete { border-color: #78c8ae; background: #f3fbf7; }
.upload-card.is-error { border-color: #e7aaa5; background: #fff7f6; }
.upload-card__icon {
    display: grid;
    place-items: center;
    width: 43px;
    height: 43px;
    border-radius: 11px;
    color: var(--navy-900);
    background: var(--cyan-100);
    font-size: .76rem;
    font-weight: 800;
}
.upload-card.is-complete .upload-card__icon { color: #fff; background: var(--success); }
.upload-card__body { min-width: 0; }
.upload-card h3 { margin: 1px 0 5px; color: var(--navy-900); font-size: 1rem; }
.upload-card p,
.upload-card li { color: var(--muted); font-size: .77rem; line-height: 1.55; }
.upload-card p { margin: 0 0 12px; }
.upload-card ul { margin: -4px 0 13px; padding-left: 20px; }
.upload-card input[type="file"] { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.file-button {
    display: inline-flex;
    min-height: 38px;
    align-items: center;
    padding: 8px 14px;
    border: 1px solid #b6c5d1;
    border-radius: 8px;
    color: var(--navy-800);
    background: #fff;
    font-size: .78rem;
    font-weight: 700;
    cursor: pointer;
}
.file-button:hover,
.file-button:focus-visible { border-color: var(--navy-700); }
.upload-status { margin-top: 13px; }
.upload-status > div:first-child { display: flex; justify-content: space-between; gap: 12px; color: var(--ink); font-size: .75rem; }
.upload-status [data-upload-name] { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.upload-bar { height: 7px; margin-top: 8px; overflow: hidden; border-radius: 20px; background: #dce6ed; }
.upload-bar span { display: block; width: 0; height: 100%; border-radius: inherit; background: var(--cyan-500); transition: width .2s ease; }
.upload-card.is-complete .upload-bar span { background: var(--success); }
.upload-status p { margin: 7px 0 0; }

.upload-note {
    display: grid;
    gap: 4px;
    margin-top: 18px;
    padding: 14px 16px;
    border-left: 4px solid var(--copper);
    border-radius: 7px;
    color: #5a4a3d;
    background: #fbf6f1;
    font-size: .78rem;
    line-height: 1.55;
}

.success-panel { padding: 30px 10px 24px; text-align: center; }
.success-panel__icon { display: grid; place-items: center; width: 70px; height: 70px; margin: 0 auto 22px; border-radius: 50%; color: #fff; background: var(--success); font-size: 2rem; font-weight: 700; }
.success-panel > span { max-width: 560px; margin-inline: auto; }

.site-footer { color: #c9d5e0; background: #03172d; }
.site-footer__inner { min-height: 88px; display: flex; align-items: center; justify-content: space-between; gap: 25px; font-size: .75rem; }
.site-footer__inner > span { color: var(--copper); font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.site-footer__inner div { display: flex; gap: 20px; }
.site-footer a:hover { color: #fff; }

.noscript { position: fixed; inset: auto 20px 20px; z-index: 50; padding: 14px 18px; border-radius: 10px; color: #fff; background: var(--danger); text-align: center; }
[hidden] { display: none !important; }

@media (max-width: 1060px) {
    .hero { padding-top: 48px; }
    .hero__grid { grid-template-columns: 1fr; gap: 38px; max-width: 790px; }
    .hero__copy { position: static; padding-top: 10px; text-align: center; }
    .hero__copy h1,
    .hero__copy > p:not(.eyebrow) { margin-inline: auto; }
    .trust-row { grid-template-columns: repeat(3, auto); justify-content: center; }
}

@media (max-width: 680px) {
    .shell { width: min(100% - 24px, 620px); }
    .site-header__inner { min-height: 70px; }
    .brand img { height: 39px; }
    .back-link { font-size: .78rem; }
    .hero { padding: 38px 0 54px; }
    .hero__copy h1 { font-size: clamp(2.3rem, 12vw, 3.35rem); }
    .hero__copy > p:not(.eyebrow) { font-size: .9rem; line-height: 1.65; }
    .trust-row { grid-template-columns: 1fr; width: max-content; max-width: 100%; margin-inline: auto; text-align: left; }
    .application-card { padding: 22px 17px; border-radius: 20px; }
    .progress { grid-template-columns: 1fr 34px 1fr; gap: 8px; margin-bottom: 28px; padding-bottom: 22px; }
    .progress__item { gap: 7px; }
    .progress__item > span { width: 31px; height: 31px; font-size: .74rem; }
    .progress__item strong { font-size: .7rem; }
    .progress__item small { display: none; }
    .form-grid { grid-template-columns: 1fr; gap: 0; }
    .field { margin-bottom: 17px; }
    .field input,
    .field select { min-height: 50px; font-size: 16px; }
    .saved-profile { grid-template-columns: 1fr; gap: 10px; }
    .saved-profile button { justify-self: start; }
    .upload-card { grid-template-columns: 37px 1fr; gap: 11px; padding: 16px 14px; }
    .upload-card__icon { width: 36px; height: 36px; }
    .site-footer__inner { flex-direction: column; justify-content: center; padding: 22px 0; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
