/* RatesLab UI-1/UI-2: presentation layer only. No pricing or auth changes. */
body[data-auth-gate="pending"] .fil-workspace-layout { visibility: hidden; }

/* Keep the existing authenticated main and all its model-owned sections unchanged. */
.fil-workspace-layout {
  display:grid;
  grid-template-columns:224px minmax(0,1fr);
  gap:clamp(18px,2vw,32px);
  width:100%;
  max-width:var(--site-content-width,1680px);
  padding-inline:var(--site-gutter,24px);
  margin-inline:auto;
  align-items:start;
}
.fil-workspace-layout > .fil-shell { width:100%; max-width:none; min-width:0; padding-inline:0; }
.fil-workspace-sidebar {
  position:sticky;
  top:108px;
  align-self:start;
  overflow-y:auto;
  max-height:calc(100dvh - 128px);
  min-width:0;
  margin-top:38px;
  background:var(--rl-surface,#fff);
  border:1px solid var(--rl-border,#dae5f0);
  border-radius:16px;
  padding:18px 12px;
  box-shadow:var(--rl-shadow,0 5px 24px rgba(18,44,73,.06));
}
.fil-workspace-kicker {
  display:block;
  padding:0 12px;
  font-size:11px;
  font-weight:800;
  text-transform:uppercase;
  letter-spacing:.09em;
  color:var(--rl-muted,#596d84);
  margin:0 0 13px;
}
.fil-workspace-links { display:grid; gap:4px; }
.fil-workspace-links a {
  display:flex;
  align-items:center;
  gap:9px;
  padding:11px 12px;
  color:#3b5774;
  font-size:13.5px;
  line-height:1.35;
  font-weight:650;
  border-radius:10px;
  border:1px solid transparent;
  text-decoration:none;
}
.fil-workspace-links a:hover,
.fil-workspace-links a[aria-current="location"] {
  background:#edf4fc;
  color:#134978;
}
.fil-workspace-links a[aria-current="location"] {
  border-color:#d1e3f7;
  font-weight:800;
}
.fil-workspace-links a:focus-visible {
  outline:3px solid var(--rl-focus,#4a90e2);
  outline-offset:2px;
}
.fil-workspace-links .fil-workspace-number {
  font-size:11px;
  color:#7e91a4;
  font-variant-numeric:tabular-nums;
  flex:0 0 17px;
}
.fil-workspace-separator { height:1px; background:#e5edf5; margin:13px 11px; }
.fil-workspace-secondary a { color:#5a738d; }
.fil-workspace-note {
  margin:15px 11px 0;
  font-size:12px;
  line-height:1.5;
  color:#657b91;
}
.fil-workspace-layout .fil-shell :is(.fil-panel-heading p,.fil-controls-note,.fil-table-note,.fil-link-method,.fil4c1-disclosure) {
  font-size:14px;
  line-height:1.65;
}
.fil-workspace-layout .fil-shell :is(.fil-field label,.fil-filters label,.fil-filters span,.fil4c1-etf-control label) {
  font-size:13.5px;
}
.fil-workspace-layout .fil-shell :is(.fil-table th,.fil-link-table th,.fil-stress-table th,.fil4c1-table th) {
  font-size:12px;
  line-height:1.45;
}
.fil-workspace-layout .fil-shell :is(.fil-table td,.fil-link-table td,.fil-stress-table td,.fil4c1-table td) {
  font-size:13.5px;
  line-height:1.5;
}
.fil-workspace-layout .fil-shell :is(.fil-kpis small,.fil-link-kpis small,.fil4c1-kpi small) {
  font-size:12px;
}
.fil-workspace-layout .fil-shell :is(.fil-field select,.fil4c1-etf-control select) {font-size:14px;}
.fil-workspace-layout .fil-shell :is(.fil-panel,.fil4c1-box,.fil4c1-kpi) {border-color:var(--rl-border,#dae5f0);}
.fil-workspace-layout [id] {scroll-margin-top:112px;}

/* Preserve the Advisor's independent layout; bring controls and supporting text
   onto the shared readability scale without changing forms or calculations. */
body.advisor-app .advisor-header-nav a {font-size:13.5px;}
body.advisor-app :is(.advisor-step strong,.advisor-section-head p,.advisor-intro p) {font-size:14px;}
body.advisor-app :is(.advisor-field label,.advisor-field select,.advisor-field-hint) {font-size:13px;}
body.advisor-app :is(.advisor-step small,.advisor-sidebar-bottom p) {font-size:12px;}
body.advisor-app :is(.advisor-form-grid,.advisor-asof) {border-color:var(--rl-border,#dae5f0);}
body.advisor-app :is(.advisor-step,.advisor-header-nav a,.advisor-reset):focus-visible {
  outline:3px solid var(--rl-focus,#4a90e2);
  outline-offset:3px;
}
@media(max-width:1190px) {
  .fil-workspace-layout {grid-template-columns:minmax(0,1fr);gap:0;}
  .fil-workspace-sidebar {
    position:static;
    max-height:none;
    margin-top:17px;
    padding:11px;
    overflow-x:auto;
    overflow-y:visible;
    border-radius:12px;
  }
  .fil-workspace-kicker,.fil-workspace-separator,.fil-workspace-note {display:none;}
  .fil-workspace-links {display:flex;align-items:center;gap:5px;width:max-content;}
  .fil-workspace-links a {white-space:nowrap; padding:10px 12px;}
  .fil-workspace-secondary {margin-top:5px;border-top:1px solid #e5edf5;padding-top:5px;}
  .fil-workspace-layout [id] {scroll-margin-top:96px;}
}
@media(max-width:650px) {
  .fil-workspace-layout {padding-inline:18px;}
  .fil-workspace-sidebar {margin-top:9px;}
  .fil-workspace-layout .fil-shell :is(.fil-table td,.fil-link-table td,.fil-stress-table td,.fil4c1-table td) {font-size:13px;}
  .fil-workspace-layout .fil-shell :is(.fil-panel-heading p,.fil-controls-note,.fil-table-note,.fil-link-method,.fil4c1-disclosure) {font-size:13.5px;}
}
