:root{--cst-blue:#0753A6;--cst-orange:#F97316;--cst-navy:#082f57;--cst-bg:#f4f7fa;--cst-text:#17324b;--cst-border:#dce6ef}
*{box-sizing:border-box}body.web-shell{margin:0;font-family:Inter,Segoe UI,Arial,sans-serif;background:linear-gradient(135deg,#eef4f9,#fff);color:var(--cst-text);min-height:100vh}.web-shell a{color:var(--cst-blue)}.auth-wrap{min-height:100vh;display:grid;place-items:center;padding:24px}.auth-card{width:min(980px,100%);display:grid;grid-template-columns:1.05fr .95fr;background:#fff;border:1px solid var(--cst-border);border-radius:24px;overflow:hidden;box-shadow:0 24px 70px rgba(8,47,87,.14)}.auth-brand{background:linear-gradient(145deg,#063f7b,#0753A6 62%,#0b67b5);padding:48px;color:#fff;position:relative;overflow:hidden}.auth-brand:after{content:'CST';position:absolute;right:-20px;bottom:-40px;font-size:160px;font-weight:1000;color:rgba(249,115,22,.38);opacity:1;letter-spacing:-12px;text-shadow:0 10px 34px rgba(249,115,22,.16);pointer-events:none;z-index:0}.auth-brand>*{position:relative;z-index:1}.auth-logo{font-weight:1000;font-size:42px;letter-spacing:-3px}.auth-kicker{font-size:11px;letter-spacing:1.8px;color:#ffd9bd;font-weight:900;margin-top:10px}.auth-brand h1{font-size:30px;line-height:1.1;margin:14px 0}.auth-brand p{color:#dcecff;line-height:1.6}.auth-badges{display:flex;gap:8px;flex-wrap:wrap;margin-top:22px}.auth-badges span{border:1px solid #ffffff38;border-radius:999px;padding:7px 10px;font-size:11px}.auth-form{padding:44px}.auth-form h2{font-size:24px;margin:0 0 4px}.muted{color:#6b8092}.field{display:grid;gap:6px;margin:16px 0}.field label{font-size:12px;font-weight:800}.field input,.field select{width:100%;padding:12px 13px;border:1px solid #cdd9e4;border-radius:10px;font-size:14px;outline:none;background:#fff}.field input:focus,.field select:focus{border-color:var(--cst-blue);box-shadow:0 0 0 3px #0753a617}.btn-web{display:inline-flex;align-items:center;justify-content:center;gap:8px;border:0;border-radius:10px;padding:12px 16px;font-weight:900;cursor:pointer;text-decoration:none}.btn-web.primary{background:var(--cst-blue);color:#fff}.btn-web.orange{background:var(--cst-orange);color:#fff}.btn-web.ghost{background:#edf4fa;color:#17476e}.btn-web.danger{background:#b42318;color:#fff}.btn-web.full{width:100%}.notice-web{padding:11px 13px;border-radius:10px;margin:12px 0;font-size:13px}.notice-web.error{background:#fff1f0;color:#a8071a;border:1px solid #ffc9c5}.notice-web.ok{background:#edf9f1;color:#136b36;border:1px solid #bde7c9}.notice-web.warn{background:#fff8e8;color:#8a5700;border:1px solid #f5d58d}.install-card{width:min(1080px,100%);background:#fff;border:1px solid var(--cst-border);border-radius:20px;box-shadow:0 20px 60px #082f5717;padding:28px}.install-head{display:flex;align-items:flex-start;justify-content:space-between;gap:18px;padding-bottom:18px;border-bottom:3px solid var(--cst-blue)}.install-head .mark{font-size:34px;font-weight:1000;color:var(--cst-blue);letter-spacing:-3px}.install-grid{display:grid;grid-template-columns:1fr 1fr;gap:16px}.install-grid .wide{grid-column:1/-1}.req-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:8px;margin:16px 0}.req{border:1px solid var(--cst-border);padding:10px;border-radius:10px;font-size:12px}.req.ok{background:#f0faf3}.req.bad{background:#fff2f0}.admin-page{max-width:1240px;margin:0 auto;padding:28px}.admin-head{display:flex;justify-content:space-between;align-items:center;gap:18px;margin-bottom:20px}.admin-head h1{margin:0}.admin-actions{display:flex;gap:8px;flex-wrap:wrap}.panel-web{background:#fff;border:1px solid var(--cst-border);border-radius:14px;padding:18px;margin-bottom:16px;box-shadow:0 8px 28px #082f570a}.table-web{width:100%;border-collapse:collapse;font-size:13px}.table-web th,.table-web td{padding:10px;border-bottom:1px solid #e6edf3;text-align:left;vertical-align:top}.table-web th{font-size:11px;text-transform:uppercase;letter-spacing:.5px;color:#60778b}.role-pill{display:inline-block;padding:4px 8px;border-radius:999px;background:#edf4fb;color:#0753A6;font-size:11px;font-weight:900}.status-on{color:#137333;font-weight:900}.status-off{color:#b42318;font-weight:900}.inline-form{display:flex;gap:8px;align-items:end;flex-wrap:wrap}.inline-form .field{margin:0;min-width:150px;flex:1}.web-user-badge{display:flex;align-items:center;gap:8px;padding:5px 9px;border:1px solid #d8e4ee;border-radius:10px;background:#fff}.web-user-badge strong{font-size:12px}.web-user-badge small{display:block;color:#72869a;font-size:9px}.web-user-links{display:flex;gap:5px}.web-user-links a{text-decoration:none;font-size:11px;padding:6px 8px;border-radius:7px;background:#edf4fa}.web-user-links a.logout{background:#fff0e6;color:#c94f00}
@media(max-width:760px){.auth-card{grid-template-columns:1fr}.auth-brand{padding:28px}.auth-form{padding:28px}.install-grid{grid-template-columns:1fr}.install-grid .wide{grid-column:auto}.req-grid{grid-template-columns:1fr 1fr}.admin-page{padding:15px}.admin-head{align-items:flex-start;flex-direction:column}.table-scroll{overflow:auto}.web-user-badge{display:flex;padding:3px 5px}.web-user-badge>div:first-child{display:none}.web-user-links a:not(.logout){display:none}.web-user-links a.logout{display:inline-flex;padding:5px 7px}}


/* ===== 2.0.1 Mobile Responsive Polish ===== */
.mobile-nav-toggle,.mobile-nav-close{display:none}
.mobile-overlay{display:none}
.auth-form form{margin-top:16px}
.auth-form .btn-web.primary{min-height:48px;font-size:15px;letter-spacing:.4px}
.auth-form .field input{min-height:46px}
.auth-card{isolation:isolate}
@media(max-width:640px){
  body.web-shell{background:#f3f7fb}
  .auth-wrap{padding:0}
  .auth-card{width:100%;min-height:100vh;border-radius:0;box-shadow:none;border:0;grid-template-columns:1fr;background:linear-gradient(180deg,#f3f7fb 0,#fff 220px)}
  .auth-brand{padding:22px 18px 18px;border-bottom:1px solid rgba(255,255,255,.12)}
  .auth-brand:after{font-size:92px;right:-8px;bottom:-18px;letter-spacing:-6px;color:rgba(249,115,22,.34)}
  .auth-logo{font-size:34px;letter-spacing:-2px}
  .auth-kicker{font-size:10px;letter-spacing:1.3px;margin-top:8px}
  .auth-brand h1{font-size:22px;line-height:1.18;margin:12px 0 8px;max-width:12.5em}
  .auth-brand p{font-size:13px;line-height:1.55;margin:0}
  .auth-badges{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:16px}
  .auth-badges span{padding:8px 10px;font-size:10px;text-align:center;background:#ffffff0d;backdrop-filter:blur(2px)}
  .auth-form{padding:18px 16px 24px;background:transparent}
  .auth-form h2{font-size:21px}
  .auth-form .muted{font-size:12px;line-height:1.5}
  .field{margin:12px 0}
  .field label{font-size:11px}
  .field input,.field select{padding:13px 12px;border-radius:12px;font-size:16px}
  .auth-form .notice-web{font-size:12px;margin:10px 0}
}
@media(max-width:380px){
  .auth-badges{grid-template-columns:1fr}
  .auth-brand h1{font-size:20px}
}
@media(max-width:900px){
  body.mobile-nav-open{overflow:hidden}
  .mobile-nav-toggle{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-width:42px;height:42px;border:1px solid #d5e1eb;border-radius:12px;background:#fff;color:var(--cst-blue);font-weight:900;box-shadow:0 8px 22px rgba(8,47,87,.07)}
  .mobile-nav-toggle svg,.mobile-nav-close svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
  .mobile-overlay{position:fixed;inset:0;background:rgba(8,30,54,.42);z-index:39;opacity:0;pointer-events:none;transition:opacity .24s ease;display:block}
  body.mobile-nav-open .mobile-overlay{opacity:1;pointer-events:auto}
  .sidebar{width:286px;max-width:88vw;transform:translateX(-108%);transition:transform .24s ease;z-index:40;padding:18px 14px 18px;box-shadow:14px 0 28px rgba(2,16,29,.26)}
  body.mobile-nav-open .sidebar{transform:translateX(0)}
  .main{margin-left:0!important;padding:14px 12px 34px!important}
  .brand{padding-right:48px;position:relative}
  .brand>div:last-child,.sidebar nav span,.side-foot small{display:block}
  .mobile-nav-close{display:inline-flex;position:absolute;top:8px;right:0;width:36px;height:36px;border:1px solid rgba(255,255,255,.22);border-radius:10px;background:rgba(255,255,255,.08);color:#fff;align-items:center;justify-content:center}
  .side-foot b{font-size:34px}
  .topbar{position:sticky;top:0;z-index:20;padding:10px 10px 12px;border:1px solid #e1ebf3;background:rgba(255,255,255,.95);backdrop-filter:blur(10px);border-radius:16px;box-shadow:0 8px 24px rgba(8,47,87,.06);flex-direction:column;align-items:stretch;gap:10px}
  .topbar>div:first-child{display:flex;gap:10px;align-items:flex-start}
  .topbar h1{font-size:22px;line-height:1.15}
  .eyebrow{font-size:9.5px;letter-spacing:1.15px}
  .top-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px;align-items:stretch}
  .top-actions>.web-user-badge{grid-column:1/-1;justify-content:space-between;padding:7px 9px;border-radius:12px;background:#f7fbff}
  .web-user-badge>div:first-child{display:block!important}
  .web-user-badge strong{font-size:12px}
  .web-user-badge small{font-size:10px}
  .web-user-links{display:flex;flex-wrap:wrap;justify-content:flex-end}
  .web-user-links a{display:inline-flex!important;padding:6px 8px;border-radius:8px;font-size:11px}
  .top-actions .sys-badge{display:inline-flex;align-items:center;justify-content:center;text-align:center;padding:8px 10px;min-height:40px}
  .top-actions>.btn{width:100%;justify-content:center;min-height:42px}
  .help-top{display:none!important}
  .quote-toolbar{top:66px}
  .hero-card.cst-command-hero{padding:18px 16px;border-radius:16px;grid-template-columns:1fr}
  .cst-command-hero .hero-copy h2{font-size:22px;line-height:1.2}
  .cst-command-hero .hero-copy p{font-size:13px;line-height:1.55}
  .cst-command-hero .watermark{font-size:108px;right:-20px;bottom:-28px;opacity:.08}
  .hero-rail{margin-top:12px}
  .hero-rail>div{grid-template-columns:64px 1fr}
  .today-actions,.grid-2,.dashboard-grid{grid-template-columns:1fr!important}
}
@media(max-width:620px){
  .top-actions{grid-template-columns:1fr}
  .top-actions>.web-user-badge,.top-actions>.btn,.top-actions>.sys-badge{grid-column:1/-1}
  .quote-toolbar{top:74px}
}


/* ===== 2.0.2 Mobile Cache + Overflow Hotfix ===== */
@media(max-width:900px){
  html,body{width:100%;max-width:100%;overflow-x:hidden}
  body.web-shell{min-width:0!important}
  .auth-wrap,.auth-card,.auth-brand,.auth-form{min-width:0!important;max-width:100%!important}
  .auth-card{overflow:hidden}
  .auth-brand h1,.auth-brand p,.auth-kicker,.auth-badges span{overflow-wrap:anywhere;word-break:normal}
  .auth-form form,.auth-form .field,.auth-form input,.auth-form button{min-width:0!important;max-width:100%!important}
}
@media(max-width:640px){
  .auth-wrap{display:block!important;min-height:100dvh!important;padding:0!important}
  .auth-card{display:flex!important;flex-direction:column!important;width:100%!important;min-height:100dvh!important;margin:0!important;border-radius:0!important}
  .auth-brand{flex:0 0 auto!important;width:100%!important;padding:20px 16px 16px!important}
  .auth-form{flex:1 1 auto!important;width:100%!important;padding:18px 16px 28px!important}
  .auth-badges{width:100%!important}
  .auth-badges span{min-width:0!important;white-space:normal!important;line-height:1.25!important}
  .auth-form .btn-web.full{display:flex!important;width:100%!important;min-height:50px!important}
}


/* ===== 2.2.0 Login UX Polish ===== */
.auth-company{margin-top:10px;max-width:430px;font-size:13px;line-height:1.45;font-weight:800;color:#fff;letter-spacing:.15px}
.auth-foot{display:flex;align-items:flex-end;justify-content:space-between;gap:12px;margin-top:18px;padding-top:12px;border-top:1px solid #e8eef4}
.auth-foot p{font-size:10.5px!important;line-height:1.5;margin:0!important}
.cache-refresh-link{border:0;background:transparent;color:#6d8294;padding:4px 0;font-size:10.5px;font-weight:700;cursor:pointer;white-space:nowrap}
.cache-refresh-link:hover{color:var(--cst-blue);text-decoration:underline}
.cache-refresh-link:disabled{opacity:.55;cursor:wait;text-decoration:none}
@media(max-width:640px){
  .auth-company{font-size:12px;line-height:1.4;margin-top:7px;max-width:310px}
  .auth-foot{align-items:flex-start;gap:8px;margin-top:14px;padding-top:10px}
  .auth-foot p{font-size:9.5px!important}
  .cache-refresh-link{font-size:10px}
}
@media(max-width:380px){.auth-foot{flex-direction:column}.cache-refresh-link{align-self:flex-start}}

/* ===== 2.2.2 Login Orange Watermark Polish ===== */
/* Login CST watermark uses Construction Orange with stronger but non-interactive contrast. */


/* ===== 2.5.3 User Logo Binding + Integrity Hardening ===== */
.auth-logo.has-custom-logo{width:min(430px,100%);margin-bottom:12px;padding:10px 12px;border-radius:14px;background:rgba(255,255,255,.97);box-shadow:0 12px 30px rgba(3,31,59,.16);letter-spacing:0}
.auth-logo.has-custom-logo img{display:block;width:100%;height:auto;max-height:86px;object-fit:contain}
@media(max-width:640px){.auth-logo.has-custom-logo{width:min(330px,100%);padding:8px 10px;border-radius:12px;margin-bottom:8px}.auth-logo.has-custom-logo img{max-height:64px}}


/* ===== 2.7.0.1 Login Company Name Polish ===== */
.auth-company{
  margin-top:13px;
  max-width:470px;
  font-size:18.5px;
  line-height:1.32;
  font-weight:900;
  color:#fff;
  letter-spacing:.35px;
  text-wrap:balance;
  text-shadow:0 2px 10px rgba(2,35,67,.18);
}
.auth-company:after{
  content:'';
  display:block;
  width:52px;
  height:3px;
  margin-top:10px;
  border-radius:999px;
  background:#F97316;
  box-shadow:0 4px 12px rgba(249,115,22,.22);
}
@media(max-width:640px){
  .auth-company{
    max-width:340px;
    margin-top:9px;
    font-size:15.5px;
    line-height:1.34;
    letter-spacing:.22px;
  }
  .auth-company:after{width:42px;height:2.5px;margin-top:7px}
}
@media(max-width:380px){.auth-company{font-size:14.5px;max-width:300px}}

/* ===== 2.9.19.2 • CST Signature Login ===== */
body.cst-login-page{
  --login-navy:#062f59;
  --login-navy-2:#0a4478;
  --login-orange:#f97316;
  --login-ink:#132b40;
  --login-muted:#6c7f91;
  margin:0;
  min-height:100vh;
  background:
    radial-gradient(circle at 15% 18%,rgba(249,115,22,.12),transparent 24rem),
    radial-gradient(circle at 87% 82%,rgba(27,111,178,.22),transparent 28rem),
    linear-gradient(145deg,#041f3a 0%,#062f59 54%,#073b69 100%);
  color:var(--login-ink);
  overflow-x:hidden;
}
body.cst-login-page:before{
  content:'';
  position:fixed;
  inset:0;
  pointer-events:none;
  opacity:.24;
  background-image:
    linear-gradient(rgba(255,255,255,.035) 1px,transparent 1px),
    linear-gradient(90deg,rgba(255,255,255,.035) 1px,transparent 1px);
  background-size:48px 48px;
  -webkit-mask-image:linear-gradient(to bottom,rgba(0,0,0,.85),transparent 86%);
  mask-image:linear-gradient(to bottom,rgba(0,0,0,.85),transparent 86%);
}
.cst-login-shell{
  position:relative;
  min-height:100vh;
  min-height:100dvh;
  display:grid;
  place-items:center;
  padding:34px 20px;
  isolation:isolate;
}
.cst-login-watermark{
  position:fixed;
  right:-.035em;
  bottom:-.18em;
  z-index:-1;
  color:rgba(255,255,255,.035);
  font-size:clamp(180px,34vw,520px);
  line-height:.78;
  font-weight:1000;
  letter-spacing:-.095em;
  user-select:none;
  pointer-events:none;
}
.cst-login-card{
  position:relative;
  width:min(460px,100%);
  background:rgba(255,255,255,.985);
  border:1px solid rgba(255,255,255,.82);
  border-radius:22px;
  box-shadow:0 28px 76px rgba(0,20,42,.34),0 3px 12px rgba(0,20,42,.12);
  overflow:hidden;
}
.cst-login-accent{
  height:5px;
  background:linear-gradient(90deg,var(--login-orange) 0 24%,var(--login-navy-2) 24% 100%);
}
.cst-login-brand{
  text-align:center;
  padding:30px 34px 20px;
}
.cst-login-logo{
  display:flex;
  align-items:center;
  justify-content:center;
  min-height:58px;
  color:var(--login-navy);
}
.cst-login-logo span{
  display:inline-block;
  font-size:54px;
  line-height:.95;
  font-weight:1000;
  letter-spacing:-4.8px;
}
.cst-login-logo.has-custom-logo img{
  display:block;
  max-width:230px;
  max-height:74px;
  width:auto;
  height:auto;
  object-fit:contain;
}
.cst-login-brandline{
  width:52px;
  height:4px;
  margin:12px auto 16px;
  border-radius:999px;
  background:var(--login-orange);
}
.cst-login-company{
  max-width:380px;
  margin:0 auto;
  font-size:13px;
  line-height:1.45;
  font-weight:850;
  letter-spacing:.18px;
  color:#213b52;
  text-transform:uppercase;
}
.cst-login-suite{
  margin-top:9px;
  font-size:10px;
  font-weight:900;
  letter-spacing:1.45px;
  color:#7b8d9d;
}
.cst-login-modules{
  display:flex;
  align-items:center;
  justify-content:center;
  flex-wrap:wrap;
  gap:7px;
  margin-top:13px;
  color:#597084;
  font-size:11px;
  font-weight:750;
}
.cst-login-modules i{
  width:3px;
  height:3px;
  border-radius:50%;
  background:var(--login-orange);
}
.cst-login-form{
  padding:22px 34px 30px;
  border-top:1px solid #e7edf2;
}
.cst-login-formhead h1{
  margin:0;
  font-size:22px;
  line-height:1.2;
  color:#102b43;
  letter-spacing:-.35px;
}
.cst-login-formhead p{
  margin:6px 0 0;
  color:var(--login-muted);
  font-size:12.5px;
  line-height:1.5;
}
.cst-login-form form{margin-top:20px}
.cst-login-field{margin:0 0 15px;gap:7px}
.cst-login-field label{
  color:#304b61;
  font-size:11.5px;
  font-weight:850;
}
.cst-login-field input{
  min-height:48px;
  padding:12px 13px;
  border:1px solid #cfdae3;
  border-radius:11px;
  background:#fbfdff;
  color:#142c41;
  font-size:14px;
  transition:border-color .16s ease,box-shadow .16s ease,background .16s ease;
}
.cst-login-field input::placeholder{color:#9aacbb}
.cst-login-field input:focus{
  background:#fff;
  border-color:#0d62a7;
  box-shadow:0 0 0 3px rgba(7,83,166,.105);
}
.cst-password-wrap{position:relative}
.cst-password-wrap input{padding-right:62px}
.cst-password-toggle{
  position:absolute;
  top:50%;
  right:8px;
  transform:translateY(-50%);
  min-width:44px;
  height:32px;
  border:0;
  border-radius:8px;
  background:#edf3f8;
  color:#456277;
  font-size:11px;
  font-weight:850;
  cursor:pointer;
}
.cst-password-toggle:hover{background:#e3edf5;color:var(--login-navy)}
.cst-password-toggle:focus-visible{outline:2px solid var(--login-orange);outline-offset:1px}
.cst-login-submit.btn-web.primary{
  min-height:50px;
  margin-top:3px;
  border-radius:11px;
  background:linear-gradient(135deg,#0753a6,#06457f);
  box-shadow:0 10px 22px rgba(7,83,166,.20);
  font-size:13px;
  letter-spacing:.75px;
  transition:transform .14s ease,box-shadow .14s ease,background .14s ease;
}
.cst-login-submit.btn-web.primary:hover{
  background:linear-gradient(135deg,#0a5db4,#073d70);
  box-shadow:0 12px 26px rgba(7,83,166,.26);
  transform:translateY(-1px);
}
.cst-login-submit.btn-web.primary:active{transform:translateY(0)}
.cst-login-error{margin:16px 0 0}
.cst-login-foot{
  display:grid;
  grid-template-columns:1fr auto;
  align-items:center;
  gap:3px 12px;
  padding:15px 34px 17px;
  background:#f7fafc;
  border-top:1px solid #e7edf2;
  color:#718496;
  font-size:9.8px;
}
.cst-login-version{
  justify-self:end;
  color:#38586f;
  font-weight:850;
}
.cst-login-foot .cache-refresh-link{
  grid-column:1/-1;
  justify-self:center;
  margin-top:4px;
  color:#8b9ba8;
  font-size:9.5px;
}
.cst-login-foot .cache-refresh-link:hover{color:var(--login-navy)}
@media(max-width:560px){
  body.cst-login-page{background:linear-gradient(160deg,#05294c 0%,#06365f 48%,#052a4c 100%)}
  body.cst-login-page:before{background-size:38px 38px;opacity:.18}
  .cst-login-shell{padding:18px 13px}
  .cst-login-card{border-radius:18px;box-shadow:0 20px 54px rgba(0,20,42,.3)}
  .cst-login-brand{padding:24px 20px 17px}
  .cst-login-logo span{font-size:48px;letter-spacing:-4px}
  .cst-login-logo.has-custom-logo img{max-width:210px;max-height:66px}
  .cst-login-brandline{margin:10px auto 13px;width:46px;height:3px}
  .cst-login-company{font-size:11.8px;max-width:320px}
  .cst-login-suite{font-size:9.2px;letter-spacing:1.1px}
  .cst-login-modules{font-size:10.3px;gap:6px;margin-top:11px}
  .cst-login-form{padding:20px 20px 24px}
  .cst-login-formhead h1{font-size:20px}
  .cst-login-formhead p{font-size:12px}
  .cst-login-field input{font-size:16px;min-height:49px}
  .cst-login-foot{padding:13px 20px 15px;font-size:9.2px}
  .cst-login-watermark{right:-.09em;bottom:-.1em;font-size:230px;color:rgba(255,255,255,.026)}
}
@media(max-width:360px){
  .cst-login-modules{gap:5px;font-size:9.7px}
  .cst-login-company{font-size:11px}
  .cst-login-form,.cst-login-brand{padding-left:17px;padding-right:17px}
  .cst-login-foot{grid-template-columns:1fr;text-align:center}
  .cst-login-version{justify-self:center}
}
@media(prefers-reduced-motion:reduce){
  .cst-login-submit.btn-web.primary,.cst-login-field input{transition:none}
}
