:root {
  --client-width: 430px;
  --client-viewport-width: min(100vw, var(--client-width));
}
/* Single fixed wallpaper for every route; cards retain their own surfaces. */
body{background:#e9eef3!important}
#app{position:relative;isolation:isolate;min-height:100svh}
#app::before{content:'';position:fixed;z-index:-1;top:0;bottom:0;left:50%;transform:translateX(-50%);width:min(100%,var(--client-width));background:#f0f4f8 url('/images/page-background.jpg') center top/cover no-repeat;pointer-events:none}
body #app :is(.dashboard,.shell){background:transparent!important;box-shadow:none}
body #app .dashboard>main,body #app .dashboard>.account-page,body #app .dashboard>.news-page{background:transparent!important}
body #app .shell>.auth-main{background:transparent!important}
body #app :is(.reference-header,.client-page-header,.reference-dock){background:#ffffffbf!important;backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px)}
body #app .startup-resume{background:transparent!important}
body #app .startup-screen{background:transparent!important;color:#354456}
body #app .startup-screen :is(.startup-title,.startup-kicker){color:#354456}
body #app .startup-screen :is(.startup-subtitle,.startup-status,.startup-progress){color:#6e7c8f}
body #app .startup-screen .startup-grid{opacity:.12}

body #app .startup-screen :is(.startup-tagline,.startup-progress-heading){color:#667587}
body #app .startup-screen .startup-percent{color:#ce2735}
body #app .startup-screen .startup-progress{background:#6a77832b}

/* Readable medium-weight text across client pages. */
body #app{font-weight:500}
button,input,select,textarea{font-weight:500}

/* Shared product lists and records reveal the same wallpaper. */
body #app .placement-page{background:transparent!important}
body #app :is(.reference-offer,.placement-card){background:#ffffff80!important;border-color:#ffffffb3!important;box-shadow:none}
body #app .reference-offer dl{background:transparent}
body #app .placement-tabs{background:#ffffff80}
body #app .placement-tabs button.active{background:#ffffffd9}
body #app .reference-offer header small{font-size:16px;font-weight:600;color:#636d7b}
body #app .placement-card header small{font-size:16px;font-weight:600;color:#636d7b}

/* Credit lending uses the supplied vivid red swatch. */
body #app .loan-page{--sk-red:#e0022b}
body #app .loan-page .loan-credit{background:#e0022b;color:#fff;box-shadow:0 5px 16px #e0022b12}
body #app .loan-page .loan-credit :is(dt,div>span,small){color:#ffffffe0}
body #app .loan-page .placement-primary{background:#e0022b}
body #app .loan-page :is(.placement-detail,.placement-tabs>button.active){color:#e0022b}
body #app .loan-page .placement-tabs>button.active:after{background:#e0022b}
body #app .loan-page .placement-badge{color:#e0022b;background:#e0022b0d}
body #app .loan-page input:focus{outline:2px solid #e0022b26;border-color:#e0022b}

/* Loan history and details share the lending palette. */
body #app .loan-page .placement-card{border:1px solid #ffffffb3!important;border-radius:14px;background:#ffffff8f!important;box-shadow:0 3px 12px #26334504!important}
body #app .loan-page .placement-card header{border-bottom-color:#dce1e780}
body #app .loan-page .placement-card header small{font-size:13px;font-weight:500;color:#858e9a;overflow-wrap:anywhere}
body #app .loan-page .placement-price strong{color:#e0022b;font-size:27px;font-weight:700;overflow-wrap:anywhere}
body #app .loan-page .placement-price strong small{color:#858e9a;font-size:13px}
body #app .loan-page :is(.placement-info dt,.placement-note,.loan-repayment small,.loan-repayment>span){color:#7d8795}
body #app .loan-page .placement-info dd{color:#303945;font-weight:600}
body #app .loan-page .placement-detail{font-weight:600}
body #app .loan-page .loan-rejection{background:#e0022b09;border:1px solid #e0022b12;color:#c22a43;border-radius:10px}
body #app .loan-page .loan-repayment{border-bottom-color:#dce1e780}
body #app .loan-page .placement-confirm{background:#e0022b09;color:#b2213a}

/* Reference login: warm gold light, large centered brand, crimson controls. */
body #app:has(>.shell)::before{background:radial-gradient(ellipse at 52% 28%,#fffdf6 0%,#fff8e6 33%,transparent 70%),radial-gradient(ellipse at 0% 90%,#fffdf1 0%,transparent 38%),linear-gradient(145deg,#e8cb86 0%,#fff4d8 38%,#edcf91 76%,#f9e8bc 100%)}
body #app>.shell{position:relative;overflow:hidden;min-height:100svh}
body #app>.shell:before,body #app>.shell:after{content:'';position:absolute;pointer-events:none;width:170%;height:35%;left:-38%;border:2px solid #fff8d9;border-radius:50%;transform:rotate(-22deg);box-shadow:0 -8px 24px #fffbedb3,0 5px 14px #dcb65d33;z-index:-1}
body #app>.shell:before{top:-19%}
body #app>.shell:after{bottom:-14%;height:32%;transform:rotate(-18deg);border-width:3px;box-shadow:0 -5px 18px #fffdf5,0 -13px 35px #f9df9b80}
body #app .shell .brand{padding:12px 24px 0;min-height:42px}
body #app .shell .auth-main{padding:12px 30px 45px;position:relative}
body #app .shell .auth-brand{display:flex;justify-content:center;margin:0 0 23px;padding:0}
body #app .shell .auth-brand>span{display:none}
body #app .shell .auth-brand .reference-brand{width:144px;height:144px;border-radius:38px;border:1px solid #ead093;box-shadow:0 5px 15px #b995421c;background:#fffdf7}
body #app .shell .tabs{margin:0 0 25px;gap:24px}
body #app .shell .tabs button{font-size:23px;font-weight:500;color:#29251e;padding:12px 0;min-height:52px}
body #app .shell .tabs button.active{color:#e0022b;font-weight:700}
body #app .shell .tabs button.active:after{background:#e0022b;width:60px;left:calc(50% - 30px);height:4px}
body #app .shell form>label{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
body #app .shell :is(.auth-input-row,.password-wrap){background:#ffffffd9;border:1px solid #ffffffad;border-radius:10px;min-height:53px;margin-bottom:13px;box-shadow:none}
body #app .shell :is(.auth-input-row,.password-wrap)>svg{color:#e0022b;width:22px;height:22px}
body #app .shell input:not([type=checkbox]){background:#ffffffd9;border:0;min-height:53px;font-size:18px;color:#333}
body #app .shell :is(.auth-input-row,.password-wrap) input{background:transparent}
body #app .shell input::placeholder{color:#b8b7b4;font-weight:400}
body #app .shell .password-wrap button{color:#b3b6bc}
body #app .shell .primary{background:#e0022b;border-radius:11px;min-height:55px;font-size:23px;font-weight:650;margin-top:20px}
body #app .shell .primary>span{display:none}
body #app .shell .remember-login-wrap{margin-top:3px}
body #app .shell .remember-login{color:#9b7442;font-size:14px;min-height:25px}
body #app .shell .remember-login input{accent-color:#e0022b}
body #app .shell .auth-register-link{display:block;margin:21px auto 0;font-size:19px;color:#e0022b;font-weight:500;min-height:36px}
body #app .shell .auth-language-trigger{background:#ffffff75;color:#8a693c}
@media(max-width:360px){body #app .shell .auth-main{padding-inline:24px}body #app .shell .auth-brand .reference-brand{width:128px;height:128px}}
body #app .shell .auth-register-link{background:none;border:0;padding:0;box-shadow:none;font-family:inherit;cursor:pointer}
body #app .shell .primary{background:#e0022b!important}

/* Wider authentication fields on mobile, with a consistent safe inset. */
body #app .shell .auth-main{padding-left:20px;padding-right:20px}
body #app .shell .auth-main form{width:100%;max-width:none;margin-left:0;margin-right:0;box-sizing:border-box}
@media(max-width:360px){body #app .shell .auth-main{padding-left:16px;padding-right:16px}}
body #app>.shell{padding-left:0;padding-right:0;box-sizing:border-box}

/* Polished gold authentication composition. */
body #app:has(>.shell)::before{background:radial-gradient(ellipse at 50% 24%,#fffdf7 0%,#fff9eb 32%,transparent 67%),radial-gradient(ellipse at 100% 66%,#fffdf3 0%,transparent 48%),linear-gradient(145deg,#dfbd73 0%,#fae9c0 22%,#fff5de 53%,#e8c788 100%)}
body #app>.shell{isolation:isolate}
body #app>.shell:before{top:-23%;left:-43%;width:190%;height:42%;border-color:#fff7d6;box-shadow:0 5px 12px #fdf6d9,0 12px 32px #c79a3f1a;opacity:.85}
body #app>.shell:after{bottom:-24%;left:-25%;height:39%;width:180%;border-color:#fff8df;box-shadow:0 -3px 12px #fffdf2,0 -16px 36px #e1b65b24}
body #app .shell .brand{padding:16px 22px 0;min-height:48px}
body #app .shell .auth-main{padding-top:14px;padding-bottom:42px}
body #app .shell .auth-brand{position:relative;margin:0 0 27px;padding:6px 0 13px}
body #app .shell .auth-brand:before{content:'';position:absolute;width:178px;height:178px;top:-10px;border:1px solid #d4ad5729;border-radius:50%;background:radial-gradient(circle,#fffaf199,transparent 70%);z-index:-1}
body #app .shell .auth-brand .reference-brand{width:136px;height:136px;border-radius:34px;border:1px solid #fff7dc;box-shadow:0 12px 28px #a77d301c,0 0 0 7px #ffffff38}
body #app .shell .tabs{max-width:280px;margin:0 auto 26px;gap:48px;border-bottom:1px solid #cfb57b24}
body #app .shell .tabs button{font-size:22px;letter-spacing:1px;min-height:54px;color:#8d7c60}
body #app .shell .tabs button.active:after{height:3px;width:36px;left:calc(50% - 18px);border-radius:4px}
body #app .shell :is(.auth-input-row,.password-wrap){min-height:58px;margin-bottom:16px;border:1px solid #ffffffed;background:#fffcf5e8;border-radius:13px;box-shadow:0 5px 16px #98783a08,inset 0 1px 0 #fff;transition:border-color .18s,box-shadow .18s}
body #app .shell :is(.auth-input-row,.password-wrap):focus-within{border-color:#dca5a3;box-shadow:0 0 0 3px #e0022b06,0 6px 20px #98783a08;outline:none}
body #app .shell :is(.auth-input-row,.password-wrap)>svg{color:#dd173b;width:22px;height:22px;opacity:.9}
body #app .shell input:not([type=checkbox]){min-height:58px;font-size:18px;border-radius:13px;background:#fffcf5e8}
body #app .shell :is(.auth-input-row,.password-wrap) input{background:transparent;border-radius:0}
body #app .shell .primary{min-height:56px;margin-top:22px;border-radius:13px;background:linear-gradient(110deg,#eb1239,#df0029)!important;border:1px solid #ee2649;box-shadow:0 7px 17px #d6002620,inset 0 1px 0 #ffffff26;font-size:22px;letter-spacing:2px;transition:transform .16s,box-shadow .16s}
body #app .shell .primary:active:not(:disabled){transform:translateY(1px);box-shadow:0 3px 9px #d600261c}
body #app .shell .remember-login{color:#8c795c;font-size:14px;font-weight:500;gap:7px}
body #app .shell .remember-login input{width:15px;height:15px;flex-basis:15px;min-height:15px}
body #app .shell .auth-register-link{font-size:17px;letter-spacing:1px;margin-top:23px;color:#bf2340}
body #app .shell .field-hint{color:#99856a;font-size:13px;line-height:1.7}
body #app .shell .auth-language-trigger{border:1px solid #ffffff80;border-radius:20px;padding:8px 12px;background:#ffffff66;box-shadow:0 2px 10px #9a7a3a04}
@media(max-height:740px){body #app .shell .auth-brand .reference-brand{width:112px;height:112px;border-radius:29px}body #app .shell .auth-brand:before{width:150px;height:150px}body #app .shell .auth-brand{margin-bottom:14px}body #app .shell .auth-main{padding-top:5px}}
body #app .shell .auth-main{max-width:none;width:100%;box-sizing:border-box}

/* Building splash reference; illustration stays behind live progress. */
body #app .startup-screen{background:#9dc7ed url('/images/startup-building.webp') center/cover no-repeat!important;color:#fff;min-height:100svh}
body #app .startup-screen:before,body #app .startup-grid,body #app .startup-identity{display:none}
body #app .startup-bottom{left:14.5%;right:14.5%;bottom:calc(7.5svh + env(safe-area-inset-bottom));text-align:center}
body #app .startup-progress-heading{display:none}
body #app .startup-screen .startup-progress{position:relative;height:23px;border:1px solid #ffffffb3;border-radius:20px;background:#e6e9edeb;box-shadow:0 2px 8px #132c4020;overflow:hidden}
body #app .startup-screen .startup-progress>i{background:#f00030;box-shadow:none;border-radius:20px}
body #app .startup-bar-percent{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;color:white;font-size:15px;font-weight:650;line-height:1;font-style:normal;text-shadow:0 1px 2px #86102730;font-variant-numeric:tabular-nums}
body #app .startup-market{bottom:calc(14svh + env(safe-area-inset-bottom));left:13%;width:74%;height:105px;opacity:.8}
body #app .startup-market-line{stroke:#fff3ba;stroke-width:2;filter:drop-shadow(0 0 4px #e89938a0)}
body #app .startup-candles{fill:#fff2b480;stroke:#fff5ceaa}
body #app .startup-market-grid{stroke:#ffffff16}
body #app .startup-market-area{opacity:.25}
body #app .startup-error{background:#ffffffdf;color:#9f1531;padding:12px;border-radius:10px}
body #app .startup-screen .startup-retry{background:#e0022b;color:white;border-color:#ffffff80}

/* High-contrast decorative market rise on the photographic splash. */
body #app .startup-market{opacity:1;height:120px;bottom:calc(14svh + env(safe-area-inset-bottom));background:linear-gradient(180deg,#fffdf7cc,#ffffffa6);border-radius:12px;box-shadow:0 3px 20px #243e5520;mask-image:none;padding:10px 8px;box-sizing:border-box}
body #app .startup-market-line{stroke:#ed0036;stroke-width:3;filter:drop-shadow(0 1px 3px #ffffffd9)}
body #app .startup-candles{fill:#e900365e;stroke:#d80031;stroke-width:1.4}
body #app .startup-market-grid{stroke:#5d789620}
body #app .startup-market-area{fill:#ed003612;opacity:1}

/* Final splash: concise copy instead of the decorative stock chart. */
body #app .startup-loading-copy{margin:0 0 12px;color:#fff;font-size:12px;letter-spacing:.5px;text-shadow:0 1px 5px #163553b3}

/* Refresh recovery is opaque: never reveal the route wallpaper underneath. */
body #app:has(>.startup-resume)::before,body #app:has(>.startup-screen)::before{display:none}
body #app .startup-resume{position:fixed;inset:0;z-index:1000;width:min(100%,480px);max-width:480px;min-height:100svh;background:#f6f8fa!important;color:#7b8795;margin:0 auto}
body #app .startup-resume-spinner{border-color:#dfe4eb;border-top-color:#e0022b}

/* Shared quote convention: red gains, blue losses. */
body #app{--quote-up:#e53935;--quote-down:#2283df}
body #app :is(.up,.rise){color:var(--quote-up)!important}
body #app :is(.down,.fall){color:var(--quote-down)!important}

/* Opaque navigation surfaces; scrolling content never bleeds through. */
body #app :is(.reference-header,.client-page-header){background:#fbfaf8!important;backdrop-filter:none!important;-webkit-backdrop-filter:none!important;border-bottom:1px solid #e6e4e1;box-shadow:0 2px 8px #303b4c04}
body #app .reference-dock{background:#fbfaf8!important;backdrop-filter:none!important;-webkit-backdrop-filter:none!important;border-top:1px solid #e6e4e1;box-shadow:0 -3px 14px #303b4c07}
body #app .stock-search-header.client-page-header{background:#fbfaf8!important}

/* Keep login and confirmation password icons on the same vertical center. */
body #app .shell :is(.auth-input-row,.password-wrap)>svg{top:50%;transform:translateY(-50%);left:14px;width:22px;height:22px}
body #app .shell .password-wrap button{position:absolute;top:50%;right:5px;transform:translateY(-50%);width:42px;height:42px;min-height:42px;padding:10px;display:grid;place-items:center}
body #app .shell .password-wrap button>svg{display:block;position:static;width:22px;height:22px;margin:0;transform:none}
body #app .shell .password-wrap input{padding-left:47px;padding-right:49px}

/* One outer focus ring and consistent geometry for all credential fields. */
body #app .shell :is(.auth-input-row,.password-wrap){box-sizing:border-box;height:58px;min-height:58px;padding:0;position:relative;overflow:hidden}
body #app .shell :is(.auth-input-row,.password-wrap)>input{display:block;box-sizing:border-box;width:100%;height:56px!important;min-height:56px!important;max-height:56px;margin:0!important;padding-top:15px!important;padding-bottom:15px!important;line-height:26px;border:0!important;border-radius:12px!important;background:transparent!important;outline:none!important;box-shadow:none!important;appearance:none;-webkit-appearance:none}
body #app .shell :is(.auth-input-row,.password-wrap)>input:focus{outline:none!important;box-shadow:none!important;border:0!important}
body #app .shell :is(.auth-input-row,.password-wrap):focus-within{border-color:#dc9da6;box-shadow:0 0 0 3px #e0022b0a;outline:none}

/* Prevent the document from drifting horizontally without blocking inner carousels. */
html,body{max-width:100%;overscroll-behavior-x:none}
html{overflow-x:hidden}
@supports(overflow:clip){html,body{overflow-x:clip}}
body #app{width:100%;min-width:0;max-width:100%}
body #app :is(.dashboard,.shell){width:100%;min-width:0}
body #app .dashboard>main{min-width:0}

/* Only the outer route shell reserves viewport and dock space. */
body #app .reference-shell{box-sizing:border-box;min-height:100dvh;padding-bottom:0}
body #app .reference-shell.has-bottom-nav{padding-bottom:calc(65px + env(safe-area-inset-bottom))}
body #app .reference-shell>main,body #app .reference-shell>.account-page,body #app .reference-shell>.news-page{min-height:0!important}
html,body{overscroll-behavior-y:none}
/* Root must not inherit article spacing from broad page styles. */
html body #app{margin:0;padding:0;min-height:100dvh}

/* Suppress mobile browser tap flash; component selected/focus states remain. */
html{-webkit-tap-highlight-color:transparent}
button,a,input,select,textarea,label,[role=button],[role=tab],[role=option]{-webkit-tap-highlight-color:transparent}

body #app :is(.startup-screen,.startup-resume){width:min(100%,var(--client-width));max-width:var(--client-width)}
