/* KRIM Global Interface System v1
   Shared visual and accessibility baseline. Keep workflow-specific layout and logic in each workspace.
*/
:root{
  --krim-ink:#10233f;
  --krim-navy:#0a1b34;
  --krim-navy-2:#12345b;
  --krim-blue:#2867f6;
  --krim-cyan:#47d7e5;
  --krim-muted:#64748b;
  --krim-line:#dfe7f1;
  --krim-paper:#f5f8fc;
  --krim-surface:#ffffff;
  --krim-success:#087f65;
  --krim-warning:#9a5b08;
  --krim-danger:#b42335;
  --krim-radius:16px;
  --krim-shadow:0 12px 34px rgba(7,24,49,.08);
  --krim-focus:0 0 0 3px rgba(40,103,246,.22);
  /* Compatibility aliases normalize legacy workspace palettes to the same brand system. */
  --navy:#0a1b34;
  --navy2:#12345b;
  --navy-2:#12345b;
  --blue:#2867f6;
  --primary:#2867f6;
  --accent:#47d7e5;
  --cyan:#47d7e5;
  --ink:#10233f;
  --text:#10233f;
  --muted:#64748b;
  --line:#dfe7f1;
  --border:#dfe7f1;
  --paper:#f5f8fc;
  --bg:#f5f8fc;
  --white:#ffffff;
  --surface:#ffffff;
  --shadow:0 12px 34px rgba(7,24,49,.08);
  --radius:16px;
}
body.krim-global-ui{
  font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  color:var(--krim-ink);
  line-height:1.55;
  -webkit-font-smoothing:antialiased;
  text-rendering:optimizeLegibility;
}
body.krim-global-ui :where(img,svg,video,canvas){max-width:100%}
body.krim-global-ui :where(button,input,select,textarea){font:inherit}
body.krim-global-ui :where(button,[role="button"],input[type="button"],input[type="submit"],input[type="reset"]){touch-action:manipulation}
body.krim-global-ui :where(a,button,input,select,textarea,[tabindex]):focus-visible{
  outline:3px solid var(--krim-cyan);
  outline-offset:3px;
}
body.krim-global-ui :where(input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="color"]),select,textarea){
  max-width:100%;
  border-radius:10px;
}
body.krim-global-ui :where(input,select,textarea):disabled,
body.krim-global-ui :where(button):disabled{
  cursor:not-allowed;
  opacity:.68;
}
body.krim-global-ui :where(label){line-height:1.4}
body.krim-global-ui :where(table){border-collapse:separate;border-spacing:0}
body.krim-global-ui :where(th){font-weight:800}
body.krim-global-ui :where(td,th){overflow-wrap:anywhere}
body.krim-global-ui :where(pre,code){overflow-wrap:anywhere}
body.krim-global-ui :where(.card,.panel,.metric-card,.stat-card,.workspace-card,.module-card,.section-card,.dashboard-card){
  border-radius:var(--krim-radius);
}
body.krim-global-ui :where(.muted,.helper-text,.form-hint,.hint,.subtext){color:var(--krim-muted)}
body.krim-global-ui :where(.badge,.status-badge,[class*="status-"]){max-width:100%;overflow-wrap:anywhere}
body.krim-global-ui :where(.table-wrap,.table-responsive,.table-container,.data-table-wrap){max-width:100%;overflow-x:auto;-webkit-overflow-scrolling:touch}
body.krim-global-ui :where(.btn,button,.button,[role="button"],input[type="submit"]){min-height:40px}
body.krim-global-ui :where(.btn-sm,.button-small){min-height:34px}
body.krim-global-ui :where(.alert,[role="alert"],[aria-live]){overflow-wrap:anywhere}
body.krim-global-ui :where(main,section,article,aside){min-width:0}
body.krim-global-ui .krim-page-eyebrow{
  color:var(--krim-blue);font-size:.72rem;font-weight:850;letter-spacing:.14em;text-transform:uppercase
}
body.krim-global-ui .krim-page-intro{color:var(--krim-muted);max-width:72ch}
body.krim-global-ui .krim-empty-state{
  padding:clamp(22px,4vw,36px);border:1px dashed var(--krim-line);border-radius:var(--krim-radius);
  background:var(--krim-paper);text-align:center;color:var(--krim-muted)
}
body.krim-global-ui .krim-surface{
  background:var(--krim-surface);border:1px solid var(--krim-line);border-radius:var(--krim-radius);
  box-shadow:var(--krim-shadow)
}
body.krim-global-ui .krim-skip-link{
  position:absolute;left:12px;top:-100px;z-index:9999;padding:12px 16px;background:#fff;color:var(--krim-navy);
  border:2px solid var(--krim-blue);border-radius:10px
}
body.krim-global-ui .krim-skip-link:focus{top:12px}
@media(max-width:760px){
  body.krim-global-ui :where(.container,.wrap,.page-container,.workspace-container){max-width:100%}
  body.krim-global-ui :where(input,select,textarea){font-size:16px}
  body.krim-global-ui :where(table){font-size:.88em}
  body.krim-global-ui :where(.table-wrap,.table-responsive,.table-container,.data-table-wrap){display:block}
}
@media(prefers-reduced-motion:reduce){
  body.krim-global-ui *,body.krim-global-ui *::before,body.krim-global-ui *::after{
    scroll-behavior:auto!important;animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important
  }
}


/* KRIM readable type baseline across workspace pages. */
body.krim-global-ui{font-size:16px;line-height:1.6}
body.krim-global-ui :where(p,li,.krim-page-intro){font-size:15px;line-height:1.7}
body.krim-global-ui :where(small,.muted,.subtle,.helper,.help-text,.description,.subtitle){font-size:13px;line-height:1.6}
body.krim-global-ui :where(label,th,td){font-size:13px;line-height:1.55}
body.krim-global-ui .krim-page-eyebrow{font-size:12px}
body.krim-global-ui :where(button,.btn,.button,[role="button"],input,select,textarea){font-size:14px}
@media(max-width:760px){
 body.krim-global-ui{font-size:16px}
 body.krim-global-ui :where(p,li,.krim-page-intro){font-size:15px}
 body.krim-global-ui :where(small,.muted,.subtle,.helper,.help-text,.description,.subtitle){font-size:13px}
 body.krim-global-ui :where(label,th,td){font-size:13px}
 body.krim-global-ui :where(input,select,textarea){font-size:16px}
}


/* KRIM clarity upgrade — minimum readable sizes for all global workspaces. */
body.krim-global-ui{font-size:17px!important;line-height:1.65!important}
body.krim-global-ui :where(p,li,.krim-page-intro){font-size:16px!important;line-height:1.7!important}
body.krim-global-ui :where(small,.muted,.subtle,.helper,.help-text,.description,.subtitle){font-size:14px!important;line-height:1.6!important}
body.krim-global-ui :where(label,th,td){font-size:15px!important;line-height:1.6!important}
body.krim-global-ui .krim-page-eyebrow{font-size:13px!important}
body.krim-global-ui :where(button,.btn,.button,[role="button"],input,select,textarea){font-size:16px!important}
body.krim-global-ui :where(button,.btn,.button,[role="button"],input[type="submit"]){min-height:48px}
@media(max-width:760px){
 body.krim-global-ui{font-size:17px!important}
 body.krim-global-ui :where(p,li,.krim-page-intro){font-size:16px!important}
 body.krim-global-ui :where(small,.muted,.subtle,.helper,.help-text,.description,.subtitle){font-size:14px!important}
 body.krim-global-ui :where(label,th,td){font-size:14px!important}
 body.krim-global-ui :where(input,select,textarea){font-size:16px!important;min-height:46px}
}


/* KRIM unified workspace readability and depth refinement */
body.krim-global-shell,body.krim-global-ui{font-size:16px;line-height:1.6}
body.krim-global-shell :where(h1,h2,h3),body.krim-global-ui :where(h1,h2,h3){letter-spacing:-.035em;line-height:1.18}
body.krim-global-shell :where(h1),body.krim-global-ui :where(h1){font-size:clamp(28px,3.4vw,38px);font-weight:800}
body.krim-global-shell :where(.card,.panel,.workspace-card,.metric,.stat,.section-card),body.krim-global-ui :where(.card,.panel,.workspace-card,.metric,.stat,.section-card){box-shadow:0 12px 30px rgba(7,24,49,.09);border-radius:16px}
body.krim-global-shell :where(button,[role="button"],input[type="submit"]),body.krim-global-ui :where(button,[role="button"],input[type="submit"]){min-height:44px;font-weight:700}
body.krim-global-shell :where(input,select,textarea),body.krim-global-ui :where(input,select,textarea){min-height:44px;font-size:16px}
body.krim-global-shell :where(label,th),body.krim-global-ui :where(label,th){font-weight:700}
body.krim-global-shell :where(small,.muted,.subtle),body.krim-global-ui :where(small,.muted,.subtle){line-height:1.5}
@media(max-width:700px){body.krim-global-shell,body.krim-global-ui{font-size:16px}body.krim-global-shell :where(button,[role="button"],input[type="submit"]),body.krim-global-ui :where(button,[role="button"],input[type="submit"]){min-height:48px}}

/* KRIM: remove redundant identity/session strip above the main page header. */
.topbar,.topline,.announcement,.utility-bar,.announcement-bar,.site-notice-bar{display:none!important}


/* KRIM homepage-aligned operating-system theme v1.
   Shared visual language for every workspace that loads this interface contract.
   Preserve page-specific workflows, data states, and layout geometry. */
:root{
 --krim-global-navy:#061a31;--krim-global-navy-2:#0b3154;--krim-global-blue:#1769e8;
 --krim-global-cyan:#43c9df;--krim-global-violet:#365bd6;--krim-global-ink:#132b45;
 --krim-global-muted:#647b91;--krim-global-line:#d9e5ef;--krim-global-page:#f3f7fb;
 --krim-global-card:#fff;--krim-global-radius:17px;
 --krim-global-shadow:0 16px 42px rgba(5,28,51,.085);
}
body.krim-global-shell,body.krim-global-ui{
 background:radial-gradient(ellipse at 88% -8%,rgba(70,157,220,.16),transparent 34%),linear-gradient(180deg,#f4f8fc 0%,#f8fbfe 58%,#f1f6fb 100%)!important;
 color:var(--krim-global-ink)!important;
 font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif!important;
 -webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility;
}
body.krim-global-shell :where(h1,h2,h3,h4),body.krim-global-ui :where(h1,h2,h3,h4){color:var(--krim-global-navy);letter-spacing:-.035em}
body.krim-global-shell :where(.top,.topbar,.topline,.top-strip,.utility-bar),body.krim-global-ui :where(.top,.topbar,.topline,.top-strip,.utility-bar){background:linear-gradient(105deg,#041629,#0b3154 72%,#10476b)!important;color:#eaf5ff!important;border-color:#244d70!important}
body.krim-global-shell :where(.top,.topbar,.topline,.top-strip,.utility-bar) a,body.krim-global-ui :where(.top,.topbar,.topline,.top-strip,.utility-bar) a{color:#fff!important}
body.krim-global-shell :where(header,.header,.nav,[role=banner]),body.krim-global-ui :where(header,.header,.nav,[role=banner]){background:rgba(255,255,255,.97)!important;border-color:#dce7f1!important;box-shadow:0 7px 24px rgba(6,26,49,.065)!important;backdrop-filter:blur(14px)}
body.krim-global-shell :where(.hero,.page-hero,.welcome,.intro,.hero-card,.dashboard-hero),body.krim-global-ui :where(.hero,.page-hero,.welcome,.intro,.hero-card,.dashboard-hero){background:linear-gradient(118deg,#041629 0%,#0a3154 58%,#105077 100%)!important;color:#edf7ff!important;border:1px solid rgba(110,190,224,.28)!important;border-radius:22px!important;box-shadow:0 22px 54px rgba(4,24,45,.18)!important}
body.krim-global-shell :where(.hero,.page-hero,.welcome,.intro,.hero-card,.dashboard-hero) :where(h1,h2,h3,p,small,label),body.krim-global-ui :where(.hero,.page-hero,.welcome,.intro,.hero-card,.dashboard-hero) :where(h1,h2,h3,p,small,label){color:inherit!important}
body.krim-global-shell :where(.card,.panel,.metric,.stat,.quote,.payment,.section-card,.workspace-card,.detail-cell,.module-card,.dashboard-card,.tile),body.krim-global-ui :where(.card,.panel,.metric,.stat,.quote,.payment,.section-card,.workspace-card,.detail-cell,.module-card,.dashboard-card,.tile){background:#fff;border:1px solid var(--krim-global-line)!important;border-radius:var(--krim-global-radius)!important;box-shadow:0 9px 27px rgba(6,30,54,.055)!important}
body.krim-global-shell :where(.card,.panel,.workspace-card,.module-card,.dashboard-card,.tile):hover,body.krim-global-ui :where(.card,.panel,.workspace-card,.module-card,.dashboard-card,.tile):hover{border-color:#b7d2e8!important;box-shadow:0 15px 34px rgba(6,30,54,.09)!important}
body.krim-global-shell :where(button,.btn,[role=button],input[type=submit]),body.krim-global-ui :where(button,.btn,[role=button],input[type=submit]){border-radius:11px;font-weight:750;transition:background-color .18s ease,border-color .18s ease,box-shadow .18s ease,transform .18s ease}
body.krim-global-shell :where(button:not(.secondary):not(.ghost):not(.outline):not(.danger),.btn:not(.secondary):not(.ghost):not(.outline):not(.danger),input[type=submit]),body.krim-global-ui :where(button:not(.secondary):not(.ghost):not(.outline):not(.danger),.btn:not(.secondary):not(.ghost):not(.outline):not(.danger),input[type=submit]){background:linear-gradient(110deg,#1769e8,#315bd7)!important;color:#fff!important;border-color:transparent!important;box-shadow:0 7px 19px rgba(23,105,232,.18)}
body.krim-global-shell :where(.secondary,.ghost,.outline,.btn-secondary),body.krim-global-ui :where(.secondary,.ghost,.outline,.btn-secondary){background:#fff!important;color:#0b3154!important;border:1px solid #cbd9e8!important;box-shadow:none!important}
body.krim-global-shell :where(input,select,textarea),body.krim-global-ui :where(input,select,textarea){background:#fff!important;color:#132b45!important;border:1px solid #cbd9e8!important;border-radius:10px!important}
body.krim-global-shell :where(input,select,textarea):focus,body.krim-global-ui :where(input,select,textarea):focus{border-color:#1769e8!important;box-shadow:0 0 0 3px rgba(23,105,232,.14)!important;outline:0!important}
body.krim-global-shell :where(th),body.krim-global-ui :where(th){background:#edf4fa;color:#0a2d4d}
body.krim-global-shell :where(td,th),body.krim-global-ui :where(td,th){border-color:#dce7f1}
body.krim-global-shell :where(footer),body.krim-global-ui :where(footer){background:linear-gradient(120deg,#041321,#092b49)!important;color:#dceaf7!important}
body.krim-global-shell :where(footer a),body.krim-global-ui :where(footer a){color:#a9d9f7!important}
body.krim-global-shell :focus-visible,body.krim-global-ui :focus-visible{outline:3px solid #43c9df!important;outline-offset:3px}
@media(max-width:760px){
 body.krim-global-shell :where(.hero,.page-hero,.welcome,.intro,.hero-card,.dashboard-hero),body.krim-global-ui :where(.hero,.page-hero,.welcome,.intro,.hero-card,.dashboard-hero){border-radius:17px!important}
 body.krim-global-shell :where(.card,.panel,.workspace-card,.module-card,.dashboard-card,.tile),body.krim-global-ui :where(.card,.panel,.workspace-card,.module-card,.dashboard-card,.tile){border-radius:14px!important}
 body.krim-global-shell :where(button,.btn,[role=button]),body.krim-global-ui :where(button,.btn,[role=button]){min-height:44px}
}
@media(prefers-reduced-motion:reduce){body.krim-global-shell *,body.krim-global-ui *{transition:none!important;animation:none!important}}


/* KRIM homepage dark-anchor correction v2.
   Reserve deep ocean navy backgrounds for the main hero and footer only.
   All other workspace surfaces remain light, with navy used for readable text. */
body.krim-global-shell,body.krim-global-ui{
 background:radial-gradient(ellipse at 88% -8%,rgba(70,157,220,.14),transparent 34%),linear-gradient(180deg,#f4f8fc 0%,#f8fbfe 58%,#f1f6fb 100%)!important;
 color:#132b45!important;
}
body.krim-global-shell :where(.top,.topbar,.topline,.top-strip,.utility-bar),body.krim-global-ui :where(.top,.topbar,.topline,.top-strip,.utility-bar){background:#fff!important;color:#132b45!important;border-color:#dce7f1!important}
body.krim-global-shell :where(.top,.topbar,.topline,.top-strip,.utility-bar) a,body.krim-global-ui :where(.top,.topbar,.topline,.top-strip,.utility-bar) a{color:#1769e8!important}
body.krim-global-shell :where(.hero),body.krim-global-ui :where(.hero){position:relative;background:#082B4C!important;color:#fff!important;border:1px solid rgba(110,190,224,.28)!important;border-radius:22px!important;box-shadow:0 22px 54px rgba(4,24,45,.18)!important;isolation:isolate;overflow:hidden}
body.krim-global-shell :where(.hero):before,body.krim-global-ui :where(.hero):before{content:"";position:absolute;inset:0;z-index:-1;background:radial-gradient(ellipse at 78% 35%,rgba(27,117,174,.52) 0,transparent 42%),radial-gradient(ellipse at 5% 100%,rgba(12,75,121,.55) 0,transparent 45%),linear-gradient(115deg,#061C33 0%,#0A3A64 58%,#082B4C 100%)!important;opacity:1!important}
body.krim-global-shell :where(.hero):after,body.krim-global-ui :where(.hero):after{pointer-events:none}
body.krim-global-shell :where(.hero) :where(h1,h2,h3,p,small,label),body.krim-global-ui :where(.hero) :where(h1,h2,h3,p,small,label){color:inherit!important}
body.krim-global-shell :where(.hero) :where(.eyebrow,.kicker,.hero-tagline),body.krim-global-ui :where(.hero) :where(.eyebrow,.kicker,.hero-tagline){color:#9ADFFF!important}
body.krim-global-shell :where(.hero) :where(.hero-lead,.hero-note),body.krim-global-ui :where(.hero) :where(.hero-lead,.hero-note){color:#E0EDF7!important}
/* Other introductory panels are intentionally light; they are not hero banners. */
body.krim-global-shell :where(.page-hero,.welcome,.intro,.hero-card,.dashboard-hero),body.krim-global-ui :where(.page-hero,.welcome,.intro,.hero-card,.dashboard-hero){background:linear-gradient(135deg,#fff 0%,#edf6fd 100%)!important;color:#132b45!important;border:1px solid #d9e5ef!important;border-radius:18px!important;box-shadow:0 12px 32px rgba(5,28,51,.07)!important}
body.krim-global-shell :where(.page-hero,.welcome,.intro,.hero-card,.dashboard-hero) :where(h1,h2,h3,p,small,label),body.krim-global-ui :where(.page-hero,.welcome,.intro,.hero-card,.dashboard-hero) :where(h1,h2,h3,p,small,label){color:#132b45!important}
body.krim-global-shell :where(.card,.panel,.metric,.stat,.quote,.payment,.section-card,.workspace-card,.detail-cell,.module-card,.dashboard-card,.tile),body.krim-global-ui :where(.card,.panel,.metric,.stat,.quote,.payment,.section-card,.workspace-card,.detail-cell,.module-card,.dashboard-card,.tile){background:#fff!important;color:#132b45!important;border:1px solid #d9e5ef!important;border-radius:17px!important;box-shadow:0 9px 27px rgba(6,30,54,.055)!important}
body.krim-global-shell :where(.card,.panel,.metric,.stat,.quote,.payment,.section-card,.workspace-card,.detail-cell,.module-card,.dashboard-card,.tile) :where(h1,h2,h3,h4,p,small,label),body.krim-global-ui :where(.card,.panel,.metric,.stat,.quote,.payment,.section-card,.workspace-card,.detail-cell,.module-card,.dashboard-card,.tile) :where(h1,h2,h3,h4,p,small,label){color:inherit}
body.krim-global-shell :where(footer),body.krim-global-ui :where(footer){background:linear-gradient(135deg,#020D19 0%,#041A30 52%,#062B4B 100%)!important;color:#D8E8F5!important;border-top:4px solid #168FE0!important;position:relative}
body.krim-global-shell :where(footer) :where(.footer-brand,.footer-col b),body.krim-global-ui :where(footer) :where(.footer-brand,.footer-col b){color:#fff!important}
body.krim-global-shell :where(footer) :where(a,.footer-desc,.footer-brand small,.footer-bottom),body.krim-global-ui :where(footer) :where(a,.footer-desc,.footer-brand small,.footer-bottom){color:#C4D9E9!important}
body.krim-global-shell :where(footer a:hover),body.krim-global-ui :where(footer a:hover){color:#8BD7FF!important}
@media(max-width:760px){body.krim-global-shell :where(.hero),body.krim-global-ui :where(.hero){border-radius:17px!important}body.krim-global-shell :where(.page-hero,.welcome,.intro,.hero-card,.dashboard-hero),body.krim-global-ui :where(.page-hero,.welcome,.intro,.hero-card,.dashboard-hero){border-radius:15px!important}}
