/* IST Finance v3.2 unified blue design system
   Applies to public, owner, staff and master-admin pages.
   Status styles (success, danger, warning) keep distinct semantic meaning. */
:root {
  --ist-blue: #0070c9;
  --ist-blue-dark: #084c94;
  --ist-blue-hover: #055fa9;
  --ist-ink: #173b5b;
  --ist-slate: #55718c;
  --ist-soft: #edf6ff;
  --ist-canvas: #f6f9fd;
  --ist-border: #d9e6f2;
  --ist-radius: 13px;
  --finance-blue: var(--ist-blue);
  --finance-deep: var(--ist-ink);
  --finance-border: var(--ist-border);
  --finance-muted: var(--ist-slate);
  --blue: var(--ist-blue);
  --navy: var(--ist-ink);
  --muted: var(--ist-slate);
  --bs-primary: var(--ist-blue);
  --bs-primary-rgb: 0,112,201;
  --bs-link-color: var(--ist-blue);
  --bs-link-hover-color: var(--ist-blue-dark);
  --bs-border-color: var(--ist-border);
  --bs-body-color: var(--ist-ink);
  --bs-secondary-color: var(--ist-slate);
}
html {scroll-padding-top:96px}
body {color:var(--ist-ink);background:var(--ist-canvas)}
.public {background:#fff}
a {color:var(--ist-blue)}
a:hover {color:var(--ist-blue-dark)}
.btn {border-radius:10px;font-weight:650;transition:background-color .15s ease,border-color .15s ease,box-shadow .15s ease}
.btn-primary {
  --bs-btn-color:#fff;--bs-btn-bg:var(--ist-blue);--bs-btn-border-color:var(--ist-blue);
  --bs-btn-hover-color:#fff;--bs-btn-hover-bg:var(--ist-blue-dark);--bs-btn-hover-border-color:var(--ist-blue-dark);
  --bs-btn-focus-shadow-rgb:0,112,201;
  --bs-btn-active-color:#fff;--bs-btn-active-bg:var(--ist-blue-dark);--bs-btn-active-border-color:var(--ist-blue-dark);
  --bs-btn-disabled-bg:var(--ist-blue);--bs-btn-disabled-border-color:var(--ist-blue);
}
.btn-outline-primary {
  --bs-btn-color:var(--ist-blue);--bs-btn-border-color:var(--ist-blue);
  --bs-btn-hover-bg:var(--ist-blue);--bs-btn-hover-border-color:var(--ist-blue);
  --bs-btn-hover-color:#fff;--bs-btn-active-bg:var(--ist-blue-dark);--bs-btn-active-border-color:var(--ist-blue-dark);
  --bs-btn-focus-shadow-rgb:0,112,201;
}
.btn-light {background:var(--ist-soft);border-color:var(--ist-border);color:var(--ist-blue-dark)}
.btn-light:hover {background:#dceeff;color:var(--ist-blue-dark)}
.btn-outline-secondary {--bs-btn-color:var(--ist-blue-dark);--bs-btn-border-color:#a8cde9;--bs-btn-hover-bg:var(--ist-soft);--bs-btn-hover-color:var(--ist-blue-dark);--bs-btn-hover-border-color:var(--ist-blue)}
.card {background:#fff;border:1px solid var(--ist-border);border-radius:var(--ist-radius);box-shadow:0 8px 25px rgba(13,68,117,.045)}
.card h1,.card h2,h1,h2,h3 {color:var(--ist-ink)}
.metric {color:var(--ist-blue-dark)}
.metric-label,.subtitle,.small-note {color:var(--ist-slate)}
.eyebrow,.feature-symbol,.step-circle {color:var(--ist-blue)}
.form-label {color:#3a5975;font-weight:600}
.form-control,.form-select {border-color:#bfd5e7;color:var(--ist-ink);background:#fff}
.form-control:focus,.form-select:focus {border-color:var(--ist-blue);box-shadow:0 0 0 .2rem rgba(0,112,201,.13)}
.form-control::placeholder {color:#8ba2b5}
.form-check-input:checked {background-color:var(--ist-blue);border-color:var(--ist-blue)}
.table {--bs-table-color:var(--ist-ink);--bs-table-border-color:var(--ist-border);background:#fff}
.table th {color:#31516c;background:var(--ist-soft);font-weight:700}
.table tr:hover td {background:#f6faff}
.table-responsive {border-radius:10px}
.badge.bg-primary,.bg-primary {background-color:var(--ist-blue)!important}
.text-primary {color:var(--ist-blue)!important}
.border-primary {border-color:var(--ist-blue)!important}
.alert-info,.muted-tip,.guide-banner {background:var(--ist-soft);border-color:#cce3f6;color:#215079}
/* Navigation is always one row on desktop, and uses a vertical mobile panel. */
.site-header {position:sticky;top:0;z-index:45;background:#fff;border-color:var(--ist-border)}
.public .marketing-header {display:flex;align-items:center;flex-wrap:nowrap}
.public-brand {white-space:nowrap}
.public-brand img {height:auto;max-height:55px}
.public-menu-wrap {min-width:0}
.public .public-nav {flex-wrap:nowrap}
.public-nav a {color:#355e7e;font-weight:650;white-space:nowrap}
.public-nav a:hover,.public-nav a[aria-current=page] {color:var(--ist-blue)}
.public .public-nav a[aria-current=page] {box-shadow:inset 0 -2px var(--ist-blue)}
.public-actions {flex-wrap:nowrap}
#sidebar {background:#fff;border-right:1px solid var(--ist-border);box-shadow:5px 0 25px rgba(19,60,95,.025)}
#sidebar .brand {color:var(--ist-blue-dark)}
#sidebar .brand img {max-height:72px}
#sidebar .navitem {transition:background-color .15s ease,color .15s ease}
#sidebar .navitem.active,#sidebar .navitem:hover {background:var(--ist-soft);color:var(--ist-blue-dark)}
.workspace-header {position:sticky;top:0;z-index:25;min-width:0}
.workspace-title {color:var(--ist-blue-dark)}
.workspace main {overflow-wrap:anywhere}
.workspace .grid > * {min-width:0}
.site-footer {background:#f4f8fc;border-color:var(--ist-border)}
.footer-grid h2 {color:var(--ist-blue-dark)}
.footer-grid a:not(.footer-brand) {color:#3e647f}
.footer-grid a:hover {color:var(--ist-blue)}
.finance-hero-preview {border-color:#c8e2f6;background:linear-gradient(145deg,var(--ist-soft),#fff 68%)}
.preview-dot {background:var(--ist-blue)}
.preview-bars b {background:linear-gradient(90deg,var(--ist-blue-dark),var(--ist-blue))}
.preview-foot div {background:var(--ist-soft);color:var(--ist-blue-dark)}
.feature-tile,.info-tile,.journey-step,.feature-side {border-color:var(--ist-border)}
.feature-symbol,.step-circle,.preview-row span {background:var(--ist-soft);color:var(--ist-blue)}
.public .cta-panel {background:linear-gradient(120deg,var(--ist-blue-dark),var(--ist-blue));color:#fff}
.public .cta-panel h1,.public .cta-panel h2 {color:#fff}
/* Dedicated company and master administrator sign-in layouts. */
.auth-layout {display:grid;grid-template-columns:minmax(0,1fr) minmax(330px,450px);align-items:center;gap:clamp(28px,6vw,90px);min-height:min(640px,75vh);padding:40px 0 72px}
.auth-intro {max-width:600px}
.auth-intro h1 {font-size:clamp(31px,4.5vw,52px);line-height:1.15;margin:16px 0}
.auth-intro p {font-size:16px;color:var(--ist-slate);line-height:1.75}
.auth-note {background:var(--ist-soft);border:1px solid var(--ist-border);padding:17px 18px;border-radius:12px;color:var(--ist-blue-dark);font-size:13px;font-weight:600;margin-top:26px}
.auth-note span {margin-right:7px}
.auth-card {padding:clamp(22px,3vw,35px)!important;margin:0;box-shadow:0 20px 55px rgba(13,68,117,.09)}
.auth-card h2 {font-size:24px}
.auth-card .form-label {margin-top:15px}
.auth-card .btn {min-height:47px}
/* Master-admin overview and quick navigation. */
.admin-page-title {display:flex;align-items:center;justify-content:space-between;gap:18px;flex-wrap:wrap;margin-bottom:12px}
.admin-page-title h1 {margin:7px 0 0}
.admin-role-pill {background:var(--ist-soft);color:var(--ist-blue-dark);border:1px solid #b9dbf2;border-radius:999px;padding:7px 13px;font-weight:750;font-size:12px}
.admin-quicklinks {display:flex;gap:8px;overflow-x:auto;padding:5px 0 14px;margin:5px 0 16px;scrollbar-width:thin}
.admin-quicklinks a {flex:0 0 auto;white-space:nowrap;font-weight:650;font-size:13px;padding:9px 15px;border:1px solid var(--ist-border);border-radius:9px;background:#fff;color:var(--ist-blue-dark)}
.admin-quicklinks a:hover,.admin-quicklinks a[aria-current=page] {background:var(--ist-blue);border-color:var(--ist-blue);color:#fff}
/* Responsive tables, forms, marketing & admin navigation. */
@media(max-width:1100px) {
  .workspace main {padding:22px}
  .workspace .grid {grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:1050px) {
  .public .public-menu-wrap {align-items:stretch}
  .public .public-nav a[aria-current=page] {box-shadow:none;background:var(--ist-soft)}
  .public-actions {flex-wrap:wrap}
}
@media(max-width:860px) {
  .workspace main {padding:19px}
  .workspace-header {gap:9px}
  .workspace-title {max-width:none;flex:1;font-size:13px}
  .workspace-user {display:none}
  .workspace-account {margin:0}
  .auth-layout {grid-template-columns:1fr;min-height:auto;padding:40px 0 55px;gap:25px}
  .auth-intro {max-width:700px}
}
@media(max-width:640px) {
  .workspace main {padding:14px}
  .workspace .grid {grid-template-columns:1fr}
  .auth-layout {padding:25px 0 35px}
  .auth-intro h1 {font-size:30px}
  .auth-intro p {font-size:14px}
  .auth-card {padding:20px!important}
  .admin-page-title {align-items:flex-start}
  .site-header {scroll-margin-top:0}
  .workspace-header .btn {white-space:nowrap}
  .public-brand img {max-height:48px}
}
@media(prefers-reduced-motion:reduce) {html {scroll-behavior:auto}.btn,.feature-tile,#sidebar .navitem {transition:none}}
