/* Stone Bridge Capital — brand stylesheet.
 *
 * Re-expressed from the brand's own delivered site (a compiled React/Tailwind
 * bundle; this repo has no build step and the application runs on the shared
 * vanilla engine). Its vocabulary, kept distinct from the other brands here:
 *
 *   - DARK. Every marketing band is deep navy (#0d2238 / #0a1b2d / #0e2238),
 *     separated by a 1px sky-950 rule; text is white and slate. The only light
 *     surface is the application card, which sits white on navy.
 *   - SQUARE. No border radius anywhere — buttons, inputs, cards, options.
 *     Lavor is rounded and light; do not converge them.
 *   - SKY-300 (#7dd3fc) micro-caps eyebrows are the only accent colour; the
 *     primary button is white with near-black text, inverted on the form.
 *   - Plus Jakarta Sans at 600 for headings (not 800), a serif wordmark.
 *   - A narrow 1024px column throughout.
 */
:root {
  --navy: #0d2238;
  --navy-2: #0a1b2d;
  --navy-3: #0e2238;
  --navy-page: #0b1b2d;
  --navy-foot: #071320;
  --rule: #082f49;          /* sky-950 */
  --rule-soft: rgba(12, 74, 110, .4);  /* sky-900 / 40 */
  --sky: #7dd3fc;           /* sky-300 */
  --sky-2: #38bdf8;
  --slate-200: #e2e8f0;
  --slate-300: #cbd5e1;
  --slate-400: #94a3b8;
  --ink: #09090b;           /* zinc-950 */
  --z900: #18181b;
  --z800: #27272a;
  --z700: #3f3f46;
  --z600: #52525b;
  --z500: #71717a;
  --z400: #a1a1aa;
  --z300: #d4d4d8;
  --z200: #e4e4e7;
  --z100: #f4f4f5;
  --z50: #fafafa;
  --danger: #dc2626;
  --sans: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --serif: Georgia, "Times New Roman", serif;
  --gut: 24px;
}

*, *::before, *::after { box-sizing: border-box; border-radius: 0; }
/* LOAD-BEARING. The engine hides the Back button, the file list, the submit
   progress bar and the held-value boxes with el.hidden, and an author
   `display:` rule silently beats the attribute. */
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: 96px; }
body {
  margin: 0;
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  color: #fff;
  background: var(--navy-page);
  -webkit-font-smoothing: antialiased;
  -webkit-text-size-adjust: 100%;
}
::selection { background: #0c4a6e; color: #fff; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--sky); }
h1, h2, h3 { font-weight: 600; letter-spacing: -.02em; margin: 0 0 .5em; line-height: 1.2; color: #fff; }
p { margin: 0 0 1em; }
:focus-visible { outline: 2px solid var(--sky); outline-offset: 2px; }

.wrap { width: min(1024px, 100% - (var(--gut) * 2)); margin-inline: auto; }
.skip-link { position: absolute; left: -9999px; top: 0; background: #fff; color: var(--ink); padding: 10px 16px; z-index: 100; }
.skip-link:focus { left: 0; }

/* ----- Header ----- */
.site-header { position: sticky; top: 0; z-index: 40; background: rgba(13, 34, 56, .95); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--rule); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 80px; }
/* The /confirm page renders .header-inner without a .wrap around it. */
.site-header > .header-inner { width: min(1024px, 100% - (var(--gut) * 2)); margin-inline: auto; }
.logo { display: inline-flex; align-items: center; gap: 14px; text-decoration: none; color: #fff; padding: 4px 0; }
.logo:hover { opacity: .9; }
.logo img { width: 64px; height: 40px; }
.logo-text { display: flex; flex-direction: column; justify-content: center; }
.logo .word { font-family: var(--serif); font-weight: 700; font-size: 18px; line-height: 1; letter-spacing: .075em; text-transform: uppercase; color: #fff; }
.logo .logo-sub { display: flex; align-items: center; gap: 8px; margin-top: 4px; font-size: 10px; font-weight: 600; line-height: 1; letter-spacing: .32em; text-transform: uppercase; color: #fff; }
.logo .logo-sub i { flex: 1; height: 1px; background: #fff; opacity: .7; }
.nav { display: flex; align-items: center; gap: 32px; font-size: 14px; font-weight: 500; }
.nav a { color: var(--slate-300); text-decoration: none; }
.nav a:hover, .nav .nav-current { color: #fff; }
.nav .nav-current { font-weight: 600; }
.nav .nav-cta { color: #fff; font-weight: 600; }
.header-mail { font-size: 14px; font-weight: 500; color: var(--sky); text-decoration: none; }
.header-mail:hover { color: #fff; text-decoration: underline; text-underline-offset: 4px; }

/* ----- Buttons: square ----- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; cursor: pointer; font: inherit; font-size: 14px; font-weight: 600; padding: 14px 28px; text-decoration: none; transition: background .2s, color .2s; }
.btn-white { background: #fff; color: var(--ink); box-shadow: 0 10px 15px rgba(0, 0, 0, .2); }
.btn-white:hover { background: #f1f5f9; }
.btn-ink { background: var(--z900); color: #fff; }
.btn-ink:hover { background: var(--z800); }
.btn-ghost { background: #fff; color: var(--z700); border: 1px solid var(--z300); }
.btn-ghost:hover { border-color: var(--z900); color: var(--z900); }
.btn-arrow::after { content: "\2192"; }
.btn:disabled { opacity: .6; cursor: wait; }
.text-link { font-size: 14px; font-weight: 500; color: var(--slate-200); text-decoration: none; }
.text-link:hover { color: #fff; text-decoration: underline; text-underline-offset: 4px; }

.eyebrow { display: block; margin-bottom: 12px; font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--sky); }

/* ----- Hero ----- */
.hero { position: relative; overflow: hidden; background: var(--navy); border-bottom: 1px solid var(--rule); }
.hero-bg { position: absolute; inset: 0; }
.hero-bg img { width: 100%; height: 100%; object-fit: cover; object-position: center; opacity: .7; filter: brightness(1.05) contrast(1.05); }
.hero-bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to right, rgba(13, 34, 56, .85), rgba(14, 39, 66, .65), rgba(18, 49, 83, .45)); }
.hero-inner { position: relative; z-index: 1; padding: 128px 0; }
.hero-copy { max-width: 48rem; }
.hero .eyebrow { margin-bottom: 24px; }
.hero h1 { font-size: clamp(30px, 4.6vw, 48px); line-height: 1.15; letter-spacing: -.025em; margin-bottom: 32px; text-shadow: 0 1px 2px rgba(0, 0, 0, .1); }
.hero .lede { font-size: clamp(16px, 1.6vw, 18px); color: var(--slate-200); line-height: 1.65; max-width: 42rem; margin-bottom: 40px; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 24px; }

/* ----- Bands ----- */
.band { padding: 128px 0; border-bottom: 1px solid var(--rule); }
.band-why { background: var(--navy-3); }
.band-products { background: var(--navy-2); }
.band-head { max-width: 42rem; margin-bottom: 64px; }
.band-head h2 { font-size: clamp(24px, 2.8vw, 30px); letter-spacing: -.02em; margin-bottom: 16px; }
.band-head p { color: var(--slate-300); font-size: 16px; margin: 0; }
.cols-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 48px; }
.col { border-top: 1px solid rgba(7, 89, 133, .4); padding-top: 24px; }
.col h3 { font-size: 16px; margin-bottom: 12px; }
.col h3 a { color: var(--sky-2); text-decoration: none; margin-left: 4px; }
.col h3 a:hover { text-decoration: underline; }
.col p { font-size: 14px; color: var(--slate-300); margin: 0; }
.rows { border-top: 1px solid var(--rule-soft); border-bottom: 1px solid var(--rule-soft); }
.row { display: grid; grid-template-columns: 4fr 8fr; gap: 32px; align-items: baseline; padding: 40px 0; }
.row + .row { border-top: 1px solid var(--rule-soft); }
.row h3 { font-size: 18px; margin: 0; }
.row p { font-size: 16px; color: var(--slate-300); margin: 0; }
.row .apply-link { display: inline-block; margin-top: 12px; font-size: 13px; font-weight: 600; color: var(--sky); text-decoration: none; }
.row .apply-link:hover { color: #fff; text-decoration: underline; text-underline-offset: 4px; }
.closer { padding: 96px 0; background: var(--navy); border-bottom: 1px solid var(--rule); }
.closer-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; }
.closer h2 { font-size: clamp(22px, 2.6vw, 28px); margin: 0 0 8px; }
.closer p { color: var(--slate-300); margin: 0; }

/* ----- Apply page: white card on navy ----- */
.canvas { background: transparent; }
.apply-top { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 16px 32px; padding: 64px 0 40px; }
.apply-top > div { max-width: 42rem; }
.back-link { flex-basis: 100%; margin-bottom: 24px; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--slate-400); text-decoration: none; }
.back-link:hover { color: #fff; }
.apply-top h1 { font-size: clamp(28px, 3.4vw, 36px); margin-bottom: 16px; }
.lede { color: var(--slate-300); max-width: 64ch; margin: 0; }
.apply-main { padding-bottom: 24px; }
.welcome { display: none; background: #fff; color: var(--z900); border: 1px solid var(--z200); padding: 28px; margin-bottom: 24px; }
.welcome.is-active { display: block; }
.welcome-pill { display: block; margin-bottom: 8px; font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--z500); }
.welcome-title { font-size: 22px; font-weight: 600; margin: 0 0 6px; color: var(--z900); }
.welcome-sub { color: var(--z600); margin: 0; }

.sbform { background: #fff; color: var(--z900); border: 1px solid var(--z200); box-shadow: 0 25px 50px rgba(0, 0, 0, .25); }
.sbform h3 { color: var(--z900); }
.sbform-progress { display: flex; align-items: center; gap: 16px; padding: 20px 48px; border-bottom: 1px solid var(--z200); background: var(--z50); }
.sbform-bar { flex: 1; height: 6px; background: var(--z200); overflow: hidden; }
.sbform-fill { display: block; height: 100%; width: 0; background: var(--z900); transition: width .3s ease; }
.sbform-count { font-size: 12px; font-weight: 500; color: var(--z700); font-variant-numeric: tabular-nums; }
.sbform-step { display: none; padding: 48px 48px 8px; border: 0; margin: 0; min-width: 0; }
.sbform-step.is-active { display: block; }
.sbform-tag { display: inline-block; font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--z500); }
.sbform-num { float: right; padding: 0; font-size: 12px; font-weight: 500; color: var(--z400); }
/* .sbform-state is the SUBMITTING / SUCCESS panel, not a heading — it must be
   hidden until the engine activates it. */
.sbform-state { display: none; padding: 56px 24px; text-align: center; }
.sbform-state.is-active { display: block; }
.sbform-state h3 { font-size: clamp(21px, 2.4vw, 24px); margin: 0 0 10px; }
.sbform-state p { color: var(--z600); max-width: 34rem; margin: 0 auto 20px; }
.sbform-step h3 { clear: both; font-size: clamp(20px, 2.4vw, 24px); letter-spacing: -.02em; margin: 8px 0 6px; }
.sbform-help { color: var(--z600); font-size: 14px; margin: 0 0 24px; }
.sbform-err { color: var(--danger); font-size: 12.5px; min-height: 18px; margin: 10px 0 0; }
.sbform-nav { display: flex; gap: 12px; align-items: center; padding: 16px 48px 40px; }
.sbform-nav .btn-ink { margin-left: auto; padding: 14px 32px; }

/* ----- Fields ----- */
.field { margin-bottom: 20px; }
.lbl { display: block; margin-bottom: 8px; font-size: 14px; font-weight: 500; color: var(--z800); }
.inp { width: 100%; font: inherit; font-size: 14px; color: var(--z900); background: #fff; border: 1px solid var(--z300); padding: 12px 16px; }
.inp:focus { outline: none; border-color: var(--z900); }
.inp[readonly], .inp.is-locked { background: var(--z100); color: var(--z500); }
.inp.is-held { border-color: var(--z900); background: var(--z50); }
.hint { font-size: 12px; color: var(--z500); }
.field-grid { display: grid; gap: 0 24px; }
.field-grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.field-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.legal { font-size: 12.5px; color: var(--z600); line-height: 1.65; margin-bottom: 16px; padding: 16px; background: var(--z50); border: 1px solid var(--z200); }

/* ----- Options ----- */
.opts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.opt { position: relative; display: flex; align-items: center; gap: 12px; padding: 14px 16px; cursor: pointer; border: 1px solid var(--z300); background: #fff; transition: border-color .15s, background .15s; }
.opt:hover { border-color: var(--z500); }
.opt input { position: absolute; opacity: 0; width: 0; height: 0; }
.opt:has(input:focus-visible) { outline: 2px solid var(--z900); outline-offset: 2px; }
.opt:has(input:checked) { border-color: var(--z900); background: var(--z50); box-shadow: inset 0 0 0 1px var(--z900); }
.opt-key { flex: 0 0 24px; height: 24px; display: grid; place-items: center; border: 1px solid var(--z300); color: var(--z500); font-size: 11px; font-weight: 600; }
.opt:has(input:checked) .opt-key { background: var(--z900); border-color: var(--z900); color: #fff; }
.opt-text { font-weight: 600; font-size: 14px; color: var(--z900); }
.opt-note { display: block; font-weight: 400; font-size: 12.5px; color: var(--z500); }

/* ----- Sliders. The engine writes the fill as --pct on the input. ----- */
.slider-wrap { padding: 4px 0 2px; }
.slider-val { font-size: 34px; font-weight: 600; letter-spacing: -.02em; color: var(--z900); }
.slider-cap { margin-left: 8px; font-size: 13px; color: var(--z500); }
.slider { width: 100%; appearance: none; -webkit-appearance: none; height: 6px; margin: 18px 0 8px; background: linear-gradient(to right, var(--z900) 0 var(--pct, 35%), var(--z200) var(--pct, 35%) 100%); }
.slider::-webkit-slider-thumb { -webkit-appearance: none; appearance: none; width: 20px; height: 20px; background: #fff; border: 3px solid var(--z900); cursor: pointer; }
.slider::-moz-range-thumb { width: 20px; height: 20px; border-radius: 0; background: #fff; border: 3px solid var(--z900); cursor: pointer; }
.slider-ends { display: flex; justify-content: space-between; font-size: 12px; color: var(--z500); }

/* ----- MCA rows ----- */
.mca-rows { display: grid; gap: 8px; margin-bottom: 12px; }
.mca-row { display: grid; grid-template-columns: 1fr 1fr auto; gap: 8px; align-items: center; }

/* ----- Uploads ----- */
.drop { position: relative; display: block; border: 2px dashed var(--z300); padding: 32px; text-align: center; cursor: pointer; background: var(--z50); color: var(--z700); }
.drop:hover, .drop.is-dragging { border-color: var(--z900); background: #fff; }
.drop.has-files { border-style: solid; }
.drop p { margin: 0 0 4px; color: var(--z900); }
.drop small { color: var(--z500); }
.drop input[type="file"] { position: absolute; opacity: 0; width: 0; height: 0; }
.filelist { list-style: none; margin: 14px 0 0; padding: 0; }
.upbar { height: 6px; background: var(--z200); overflow: hidden; margin: 12px auto; max-width: 320px; }
.upbar > i { display: block; height: 100%; width: 0; background: var(--z900); transition: width .2s ease; }
.file-item { display: grid; grid-template-columns: 1fr auto auto; gap: 12px; align-items: center; padding: 12px 16px; border: 1px solid var(--z200); background: #fff; margin-bottom: 8px; position: relative; overflow: hidden; }
.file-name { font-size: 14px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-size { font-size: 12px; color: var(--z500); }
.file-x { background: none; border: 0; color: var(--z400); font-size: 18px; line-height: 1; cursor: pointer; padding: 0 2px; }
.file-x:hover { color: var(--danger); }
.file-bar { position: absolute; left: 0; bottom: 0; height: 3px; width: 0; background: var(--z500); transition: width .2s ease; }
.file-item.is-done .file-bar { width: 100% !important; background: var(--z900); }
.file-item.is-failed .file-bar { background: var(--danger); }

/* ----- Held ("on file") ----- */
.held-note { background: var(--z50); border: 1px solid var(--z200); padding: 14px 16px; margin-bottom: 14px; font-size: 14px; color: var(--z700); }
.held-chip { display: inline-flex; align-items: center; gap: 8px; background: var(--z900); color: #fff; padding: 4px 12px; font-size: 12px; font-weight: 600; }
.keep-row { display: flex; align-items: center; gap: 10px; margin-top: 8px; font-size: 14px; color: var(--z700); }

/* ----- Signature ----- */
.sign-box { border: 1px solid var(--z300); padding: 14px; background: #fff; position: relative; }
.sign-pad { width: 100%; height: 190px; touch-action: none; display: block; cursor: crosshair; }
.sign-rule { display: block; border-top: 1px solid var(--z700); margin: 0 14px; }
.sign-hint { position: absolute; left: 0; right: 0; top: 46%; text-align: center; color: var(--z300); font-size: 14px; pointer-events: none; }
.sign-actions { display: flex; justify-content: space-between; align-items: center; margin: 10px 0 16px; font-size: 14px; color: var(--z600); }
.sign-clear { background: none; border: 0; color: var(--z500); font: inherit; cursor: pointer; text-decoration: underline; }

/* ----- Banner / submitting / success ----- */
.banner { padding: 16px; margin-bottom: 16px; font-size: 14px; display: none; }
.banner.is-active { display: block; background: #fef2f2; border: 1px solid #fecaca; color: #b91c1c; }
.spinner { width: 36px; height: 36px; margin: 0 auto 16px; border-radius: 50%; border: 3px solid var(--z200); border-top-color: var(--z900); animation: spin .9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.success-mark { width: 48px; height: 48px; margin: 0 auto 24px; border-radius: 50%; background: var(--z900); color: #fff; display: grid; place-items: center; font-size: 22px; }

/* ----- Rail ----- */
.rail-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.rail-item { font-size: 12px; font-weight: 500; color: var(--slate-400); border: 1px solid var(--rule-soft); padding: 4px 12px; }
.rail-item.is-current { background: #fff; border-color: #fff; color: var(--ink); }
.rail-item.is-done { color: var(--sky); border-color: rgba(125, 211, 252, .4); }
.rail-fine { font-size: 12.5px; color: var(--slate-400); margin: 0 0 96px; }

/* ----- Footer ----- */
.site-footer { background: var(--navy-foot); color: var(--slate-300); padding: 80px 0; border-top: 1px solid var(--rule); }
.footer-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; padding-bottom: 48px; border-bottom: 1px solid var(--rule); }
.footer-name { display: block; font-size: 16px; font-weight: 600; letter-spacing: -.01em; color: #fff; }
.footer-tag { display: block; margin-top: 4px; font-size: 12px; color: var(--slate-400); }
.footer-links { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 32px; font-size: 12.5px; font-weight: 500; }
.site-footer a { color: var(--slate-300); text-decoration: none; }
.site-footer a:hover { color: #fff; }
.footer-links .mail { color: var(--sky); text-decoration: underline; text-underline-offset: 4px; }
.footer-fine { padding-top: 40px; font-size: 12px; line-height: 1.7; color: var(--slate-400); }
.footer-fine p { max-width: 56rem; margin-bottom: 16px; }
.footer-fine b { color: var(--slate-200); font-weight: 600; }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--rule); }
.footer-legal { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.footer-legal a { text-decoration: underline; text-underline-offset: 4px; }

/* ----- Legal / 404 pages ----- */
.page-head { padding: 96px 0 48px; border-bottom: 1px solid var(--rule); }
.page-head h1 { font-size: clamp(28px, 3.6vw, 40px); }
.page-head .lede { font-size: 16px; }
.legal-rows { padding: 24px 0 96px; }
.legal-rows .row { padding: 32px 0; }
.legal-rows .row + .row { border-top: 1px solid var(--rule-soft); }
.legal-rows .row h2 { font-size: 16px; font-weight: 600; margin: 0; }
.legal-rows .row p { font-size: 15px; }

@media (max-width: 860px) {
  .header-mail { display: none; }
  .header-inner { flex-wrap: wrap; min-height: 0; padding: 14px 0; gap: 10px 24px; }
  .nav { gap: 8px 20px; flex-wrap: wrap; font-size: 13.5px; }
  .cols-3 { grid-template-columns: 1fr; gap: 32px; }
  .row { grid-template-columns: 1fr; gap: 12px; }
}
@media (max-width: 640px) {
  .hero-inner { padding: 96px 0; }
  .band { padding: 96px 0; }
  .band-head { margin-bottom: 40px; }
  .hero-actions { flex-direction: column; align-items: flex-start; }
  .opts, .field-grid-2, .field-grid-3, .mca-row { grid-template-columns: 1fr; }
  .sbform-progress { padding: 16px 24px; }
  .sbform-step { padding: 32px 24px 6px; }
  .sbform-nav { padding: 12px 24px 28px; }
  .sbform-nav .hint { display: none; }
}
