/* Size to the browser viewport; center only when intrinsic content fits. */
.onboarding{width:100%;max-width:604px;min-height:100svh;display:grid;align-items:center;container-type:inline-size}
.screen{width:100%;min-height:0!important;padding:32px max(32px,env(safe-area-inset-right)) 32px max(32px,env(safe-area-inset-left));overflow:visible}
.screen h1,.security h1,.bank h1{font-size:clamp(32px,3.6vw,42px)}
.subtitle,.security .subtitle,.bank .subtitle{font-size:19px}
.back,.ready .back{width:44px;height:44px;margin-bottom:24px;position:static}
.screen form{margin-top:24px}
.field{margin-bottom:18px}.field label,.bank .field label{font-size:17px;margin-bottom:8px}
.field input,.field select,.bank .field input,.bank .field select{height:52px;font-size:17px}
.primary,.bank .primary,.ready-actions .primary,.outline-continue{min-height:52px;font-size:21px}
.profile form{flex:none}.profile .photo-block{margin-top:22px}
.profile .photo-picker{width:140px;height:140px}.profile .photo-picker>svg{width:104px;height:104px;inset:17px}
.photo-caption{font-size:21px}.optional{font-size:17px;margin-top:7px}
.profile .field:last-of-type{margin-bottom:0}.profile .primary{margin-top:26px}
.security .back,.bank .back{margin-bottom:24px}.security .primary{margin-top:26px}
.password-wrap{height:52px}.password-wrap input{height:100%;font-size:17px}
.bank header{margin:0}.bank .field-pair{gap:24px}.bank .primary{margin-top:22px}.skip{margin-top:18px}
.select-arrow{bottom:17px}.local-note{font-size:13px}
.welcome .connection-art{width:min(100%,354px,38svh);max-height:none;margin:12px auto 0;aspect-ratio:942/900}
.welcome .description{max-width:580px;margin:18px auto 0;font-size:19px}.welcome .outline-continue{width:100%;margin:32px 0 0}
.ready .celebration-art{width:min(100%,406px,43svh);margin:-44px auto 0;aspect-ratio:942/725;z-index:0}
.ready .back{left:auto;top:auto;position:relative;z-index:2;margin:0}.ready-copy{margin-top:16px}.ready-actions{margin:0;padding:28px 0 0}.ready-copy>p{font-size:19px;margin:24px 0 0}.ready h2{font-size:28px}
@media all{
 :where(:root[data-layout="mobile"]) .onboarding{max-width:536px}:where(:root[data-layout="mobile"]) .screen{padding:24px max(24px,env(safe-area-inset-right)) max(28px,env(safe-area-inset-bottom)) max(24px,env(safe-area-inset-left))}
 :where(:root[data-layout="mobile"]) .screen h1,:where(:root[data-layout="mobile"]) .security h1,:where(:root[data-layout="mobile"]) .bank h1{font-size:clamp(26px,6.9vw,30px);letter-spacing:-.8px}:where(:root[data-layout="mobile"]) .subtitle,:where(:root[data-layout="mobile"]) .security .subtitle,:where(:root[data-layout="mobile"]) .bank .subtitle{font-size:17px;line-height:1.4}
 :where(:root[data-layout="mobile"]) .back,:where(:root[data-layout="mobile"]) .ready .back{width:44px;height:44px;margin-bottom:24px}:where(:root[data-layout="mobile"]) .field label,:where(:root[data-layout="mobile"]) .bank .field label{font-size:16px}:where(:root[data-layout="mobile"]) .field input,:where(:root[data-layout="mobile"]) .field select,:where(:root[data-layout="mobile"]) .bank .field input,:where(:root[data-layout="mobile"]) .bank .field select{height:50px;font-size:16px}
 :where(:root[data-layout="mobile"]) .primary,:where(:root[data-layout="mobile"]) .bank .primary,:where(:root[data-layout="mobile"]) .ready-actions .primary,:where(:root[data-layout="mobile"]) .outline-continue{min-height:50px;font-size:19px}:where(:root[data-layout="mobile"]) .screen form{margin-top:26px}
 :where(:root[data-layout="mobile"]) .profile .photo-picker{width:120px;height:120px}:where(:root[data-layout="mobile"]) .profile .photo-picker>svg{width:92px;height:92px;inset:13px}:where(:root[data-layout="mobile"]) .camera{width:44px;height:44px}:where(:root[data-layout="mobile"]) .profile .photo-block{margin-top:26px}:where(:root[data-layout="mobile"]) .photo-caption{font-size:19px}:where(:root[data-layout="mobile"]) .optional{font-size:16px}
 :where(:root[data-layout="mobile"]) .profile .primary,:where(:root[data-layout="mobile"]) .security .primary{margin-top:26px}:where(:root[data-layout="mobile"]) .security .back,:where(:root[data-layout="mobile"]) .bank .back{margin-bottom:24px}:where(:root[data-layout="mobile"]) .password-wrap{height:52px}:where(:root[data-layout="mobile"]) .password-wrap input{height:100%;font-size:16px}:where(:root[data-layout="mobile"]) .bank .field-pair{gap:16px}:where(:root[data-layout="mobile"]) .select-arrow{bottom:14px}:where(:root[data-layout="mobile"]) .local-note{font-size:12px}
 :where(:root[data-layout="mobile"]) .welcome .connection-art{width:calc(100% + 48px);max-width:480px;margin:12px -24px 0}:where(:root[data-layout="mobile"]) .welcome .description{font-size:17px}:where(:root[data-layout="mobile"]) .welcome .outline-continue{margin-top:22px}:where(:root[data-layout="mobile"]) .welcome .brand{font-size:21px}
 :where(:root[data-layout="mobile"]) .ready .celebration-art{width:calc(100% + 48px);max-width:none;margin:-68px -24px 0}:where(:root[data-layout="mobile"]) .ready .back{margin:0}:where(:root[data-layout="mobile"]) .ready-copy>p{font-size:17px}:where(:root[data-layout="mobile"]) .ready h2{font-size:24px}:where(:root[data-layout="mobile"]) .ready-actions{padding-top:28px}
}
@media(max-height:600px){
 .onboarding{align-items:start}.screen{padding-top:24px;padding-bottom:max(28px,env(safe-area-inset-bottom))}.back,.security .back,.bank .back{margin-bottom:20px}
 .profile .photo-picker{width:120px;height:120px}.profile .photo-picker>svg{width:92px;height:92px;inset:13px}.profile .photo-block{margin-top:22px}
 .welcome .connection-art{width:min(100%,300px);margin:12px auto 0}.ready .celebration-art{width:min(100%,340px);margin:-44px auto 0}
}
@media (max-width:350px){:where(:root[data-layout="mobile"]) .screen{padding-inline:20px}:where(:root[data-layout="mobile"]) .field-pair{grid-template-columns:1fr!important;gap:0!important}:where(:root[data-layout="mobile"]) .welcome .connection-art,:where(:root[data-layout="mobile"]) .ready .celebration-art{width:calc(100% + 40px);margin-inline:-20px}}

/* Small visual refinement; keep native layout and comfortable touch targets. */
.welcome .outline-continue{width:90%;min-height:50px;margin-inline:auto;font-size:21px}
@media all{:where(:root[data-layout="mobile"]) .welcome .outline-continue{min-height:48px;font-size:19px}:where(:root[data-layout="mobile"]) .welcome .connection-art,:where(:root[data-layout="mobile"]) .ready .celebration-art{width:calc(94% + 48px);margin-inline:calc(-24px + 3%)}:where(:root[data-layout="mobile"]) .screen form{margin-top:24px}:where(:root[data-layout="mobile"]) .profile .photo-block{margin-top:24px}}
@media (max-width:350px){:where(:root[data-layout="mobile"]) .welcome .connection-art,:where(:root[data-layout="mobile"]) .ready .celebration-art{width:calc(94% + 40px);margin-inline:calc(-20px + 3%)}}

/* Keep the form bars compact without scaling the page or reducing touch targets. */
@media all{:where(:root[data-layout="mobile"]) .screen form{width:96%;margin-inline:auto}:where(:root[data-layout="mobile"]) .screen form{margin-top:20px}:where(:root[data-layout="mobile"]) .profile .photo-block{margin-top:20px}:where(:root[data-layout="mobile"]) .field input,:where(:root[data-layout="mobile"]) .field select,:where(:root[data-layout="mobile"]) .password-wrap input{font-size:16px}:where(:root[data-layout="mobile"]) .primary,:where(:root[data-layout="mobile"]) .bank .primary,:where(:root[data-layout="mobile"]) .ready-actions .primary{min-height:48px}}

/* Updated approved welcome artwork: expose only the photograph; copy stays live HTML. */
.welcome .connection-art{width:min(100%,450px,48svh);aspect-ratio:670/530;margin:0 auto;max-height:none;mask-image:linear-gradient(#000 94%,transparent)}
.welcome .connection-art img{width:249.253731%;max-width:none;height:auto;left:-74.626866%;top:0}
.welcome .description{max-width:480px}
@media all{:where(:root[data-layout="mobile"]) .welcome .connection-art{width:calc(100% + 32px);margin:0 -16px;max-width:none}:where(:root[data-layout="mobile"]) .welcome .description{max-width:400px}}
@media(max-height:600px){.welcome .connection-art{width:min(100%,330px);margin:0 auto}}

/* Centre short screens without clipping long forms or safe areas. */
@media all{
 :root[data-layout="mobile"] .onboarding{min-height:100svh;display:flex;flex-direction:column;justify-content:center;padding-top:max(56px,env(safe-area-inset-top));padding-bottom:max(24px,env(safe-area-inset-bottom))}
 :root[data-layout="mobile"] .onboarding .screen{width:100%;margin-inline:auto;padding:20px 24px}
 :root[data-layout="mobile"] .onboarding .screen form{margin-inline:auto}
}
@media (max-height:600px){:root[data-layout="mobile"] .onboarding{justify-content:flex-start}}
