/* Alpha Route Plus — an investor's research desk.
   Presentation only. Existing controls, state, and analytics are unchanged. */
:root {
  --bg-main: #ecf1eb;
  --bg-card: #fff;
  --bg-card-hover: #f4f8f4;
  --bg-surface: #eef3ed;
  --bg-surface-light: #e2eae1;
  --bg-input: #fff;
  --border-subtle: #eaf0e9;
  --border-card: #dce5db;
  --border-highlight: #32662d;
  --font-base: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-heading: 'Manrope', 'DM Sans', sans-serif;
  --text-primary: #223a20;
  --text-secondary: #546452;
  --text-muted: #536451;
  --text-dim: #586956;
  --primary: #254f21;
  --primary-hover: #183d15;
  --accent-gradient: linear-gradient(0deg, #254f21, #254f21);
  --emerald: #2c7126;
  --emerald-bg: #eaf3e9;
  --emerald-border: #d1e4cf;
  --amber: #9a7432;
  --amber-bg: #f8f1e5;
  --amber-border: #e9dcbf;
  --rose: #a6534e;
  --rose-bg: #faf0ee;
  --rose-border: #eedad6;
  --blue: #3e663a;
  --blue-bg: #eef3ed;
  --radius-sm: 5px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --shadow-card: 0 3px 14px rgba(34, 54, 42, .025);
  --shadow-sm: 0 1px 2px rgba(34, 54, 42, .025);
  --shadow-lg: 0 16px 48px rgba(23, 48, 36, .12);
}
body { background: var(--bg-main); color: var(--text-primary); font-size: 14px; }
button, input, select { font: inherit; }
button, a, input, select, summary { -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, summary:focus-visible {
  outline: 3px solid #779b74; outline-offset: 3px;
}
button:disabled { opacity: .45; cursor: not-allowed; }
.ui-icon { width: 19px; height: 19px; display: inline-block; vertical-align: middle; fill: none; stroke: currentColor; stroke-width: 1.65; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.icon-library { position: absolute; width: 0; height: 0; overflow: hidden; }
.skip-link { position: fixed; top: -60px; left: 24px; z-index: 100000; padding: 12px 18px; background: #fff; color: var(--primary); border-radius: 6px; }
.skip-link:focus-visible { top: 12px; }
.eyebrow { display: block; font-size: 11px; letter-spacing: .16em; line-height: 1.5; font-weight: 700; color: #60705e; }
/* Shell and sidebar */
.app-container { max-width: none; margin: 0; padding: 0; }
.investor-workspace { margin-left: 228px; padding: 0 36px 28px; max-width: 1760px; min-width: 0; }
.investor-workspace:focus { outline: none; }
.investor-rail { width: 228px; position: fixed; left: 0; top: 0; bottom: 0; z-index: 30; display: flex; flex-direction: column; padding: 30px 18px 22px; background: #f9fcf9; border-right: 1px solid #dee6dd; overflow-y: auto; }
.rail-brand { display: flex; align-items: center; gap: 14px; padding: 0 8px 40px; text-decoration: none; color: var(--text-primary); }
.rail-brand > span:last-child { font: 700 13px var(--font-heading); letter-spacing: -.3px; }
.rail-brand small { display: block; font: 600 7.5px var(--font-base); color: #626d61; letter-spacing: .12em; margin-top: 5px; }
.rail-label { font-size: 11px; font-weight: 700; letter-spacing: .13em; color: #656e64; padding: 0 13px 14px; }
.investor-rail .tabs-nav-bar { display: flex; flex-direction: column; align-items: stretch; gap: 5px; margin: 0; padding: 0; background: none; border: 0; box-shadow: none; overflow: visible; border-radius: 0; }
.investor-rail .tab-button { display: flex; justify-content: flex-start; align-items: center; gap: 11px; width: 100%; margin: 0; min-height: 46px; padding: 12px 13px; border: 1px solid transparent; border-radius: 7px; background: transparent; color: #5f6e5e; font: 500 12px var(--font-base); box-shadow: none; transition: background .16s, color .16s; white-space: nowrap; }
.investor-rail .tab-button::after, .investor-rail .tabs-nav-bar::after, .investor-rail .tabs-nav-bar::before { display: none; }
.investor-rail .tab-button:hover:not(:disabled) { background: #ecf3eb; color: #254f21; transform: none; }
.investor-rail .tab-button.active { color: #254f21; background: #e5f0e4; border-color: #d9e9d8; font-weight: 700; }
.investor-rail .tab-icon { display: inline-flex; font-size: inherit; }
.investor-rail .tab-pill { margin-left: auto; padding: 2px 5px; min-width: 23px; color: #4c6849; background: #f2f8f1; font-size: 11px; border: 0; }
.investor-rail .tab-button:not(.active) .tab-pill { background: transparent; color: #626d61; }
.rail-note { margin: auto 8px 28px; padding: 30px 5px 0; color: #5c6c5a; }
.rail-note-icon { display: block; color: #597157; margin-bottom: 16px; }
.rail-note strong { font: 650 12px var(--font-heading); }
.rail-note p { font-size: 11px; line-height: 1.85; margin-top: 8px; color: #626e61; }
.rail-note-line { height: 1px; background: #d8e5d7; width: 38px; margin: 20px 0 14px; }
.rail-note > span:last-child { font-size: 11px; letter-spacing: .11em; font-weight: 600; color: #636f62; }
.rail-footer { font-size: 11px; color: #656f64; display: flex; align-items: center; gap: 7px; padding: 0 8px; }
.rail-dot { width: 5px; height: 5px; background: #7fa17c; border-radius: 50%; }
/* Top bar and heading */
.app-header { margin-bottom: 18px; }
.header-main { padding: 23px 0; min-height: 92px; margin-bottom: 0; border: 0; border-bottom: 1px solid #dde6dc; border-radius: 0; box-shadow: none; background: none; gap: 16px; }
.brand-group { min-width: 0; flex: 1 1 230px; gap: 10px; }
.brand-group .brand-logo { display: none; }
.brand-title-row { align-items: center; gap: 12px; }
.brand-title { font: 650 12px var(--font-heading); letter-spacing: 0; word-spacing: .08em; color: var(--text-primary); }
.brand-subtitle { margin-top: 4px; font-size: 11px; color: #626d61; line-height: 1.6; }
.subtitle-text { color: #626d61; }
.db-status-badge { border: 0; padding: 0; gap: 4px; font-size: 11px; color: #5b7159; background: transparent; box-shadow: none; }
.db-dot { width: 4px; height: 4px; background: #729f6e; box-shadow: none; animation: none; }
.header-actions { gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.header-actions .btn { font-size: 11px; padding: 8px 11px; min-height: 34px; gap: 6px; }
.header-actions .ui-icon { width: 14px; height: 14px; }
.user-chip { border: 0; border-left: 1px solid #d6e2d5; border-radius: 0; padding: 0 0 0 14px; margin-left: 5px; background: none; gap: 8px; box-shadow: none; }
.user-avatar { width: 30px; height: 30px; border-radius: 50%; background: #ddeadc; color: #456742; font: 600 12px var(--font-heading); }
.user-email { max-width: 125px; font-size: 11px; color: #5e715c; }
.btn-signout { font-size: 11px; color: #5e6e5d; padding: 4px; }
.session-status { color: #626d61; font-size: 11px; border: 0; background: transparent; padding: 0; }
.session-status.error { color: #a6534e; }
.workspace-heading { display: flex; justify-content: space-between; gap: 20px; align-items: center; padding: 34px 0 27px; }
.workspace-heading h1 { font: 500 clamp(25px, 2.4vw, 35px)/1.25 var(--font-heading); letter-spacing: -1.25px; color: #264223; margin: 7px 0 10px; }
.workspace-heading p { color: #636f62; font-size: 12px; line-height: 1.6; }
.workspace-edition { font-size: 11px; letter-spacing: .16em; color: #5d6d5c; text-align: right; flex-shrink: 0; line-height: 1.8; }
.workspace-edition span { display: block; font-size: 11px; letter-spacing: .09em; color: #646e63; }
/* Common controls */
.btn { border-radius: 6px; padding: 9px 15px; font-size: 12px; font-weight: 550; box-shadow: none; transition: background .16s, border-color .16s; }
.btn:hover { transform: none; box-shadow: none; }
.btn-primary, .btn-add-rolling-inline { background: #254f21; color: #fff; border: 1px solid #254f21; box-shadow: none; }
.btn-primary:hover, .btn-add-rolling-inline:hover { background: #183d15; border-color: #183d15; box-shadow: none; }
.btn-secondary, .btn-outline { border: 1px solid #d2e0d1; background: #fff; color: #50644e; box-shadow: none; }
.btn-secondary:hover, .btn-outline:hover { background: #ecf4eb; border-color: #acc8aa; color: #254f21; }
.btn-sm { font-size: 11px; padding: 7px 11px; }
.btn-lg { padding: 13px 20px; font-size: 12px; }
.form-select, .ratio-input, .modal-input { border: 1px solid #d6e3d5; border-radius: 6px; background: #fff; color: #3d553b; font-size: 12px; box-shadow: none; }
.form-select:focus, .ratio-input:focus, .modal-input:focus { border-color: #789c75; box-shadow: 0 0 0 3px #e3f0e2; }
input[type='checkbox'] { accent-color: #30652b; width: 15px; height: 15px; cursor: pointer; }
/* Import area and source details */
.upload-dual-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-bottom: 0; }
.upload-card { border: 1px dashed #c6d8c4; border-radius: 9px; padding: 16px 18px; background: #f6faf6; box-shadow: none; min-width: 0; }
.upload-card::before, .upload-card::after { display: none; }
.upload-card:hover, .upload-card.dragover { border-color: #6f996b; background: #e8f3e7; transform: none; box-shadow: none; }
.upload-card.loaded-card { border: 1px solid #d4e5d3; background: #eff8ee; }
.upload-card-content { gap: 13px; align-items: center; min-width: 0; }
.upload-icon-badge { background: #e2f0e1; color: #4e724b; width: 36px; height: 40px; min-width: 36px; border-radius: 7px; border: 0; box-shadow: none; }
.upload-card-details { min-width: 0; }
.upload-card-details h4 { font: 650 11px var(--font-heading); color: #3b5139; margin: 0 0 3px; }
.upload-card-details p { font-size: 11px; color: #5f6f5e; line-height: 1.5; }
.upload-status-text { font-size: 11px; color: #5c705a; max-width: 260px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-top: 5px; }
.upload-card .btn { background: #fff; color: #3e653a; font-size: 11px; padding: 7px 10px; }
.upload-card-actions { gap: 5px; flex-wrap: wrap; justify-content: flex-end; }
.excel-verification-banner { padding: 10px 14px; margin: 0 0 24px; gap: 10px; background: #eaf4e9; border: 1px solid #d8e8d7; border-radius: 7px; box-shadow: none; align-items: center; flex-wrap: wrap; }
.verify-badge { border: 0; border-radius: 0; padding: 0; font-size: 11px; color: #487344; background: transparent; font-weight: 700; flex-shrink: 0; }
.verify-badge::before { content: '●'; padding-right: 6px; font-size: 11px; }
.verify-details { font-size: 11px; line-height: 1.6; color: #5b6d59; flex: 1 1 220px; overflow-wrap: anywhere; }
.verify-details strong { color: #537150; font-weight: 500; }
.excel-verification-banner .btn { padding: 4px 7px; border-color: #d2e4d0; background: transparent; font-size: 11px; color: #51704e; min-height: 27px; }
.excel-verification-banner .btn:hover { background: #dbedd9; }
.excel-verification-banner .btn-clear-session { color: #7d665b; }
.source-details { position: relative; font-size: 11px; color: #4f704c; }
.source-details summary { cursor: pointer; white-space: nowrap; }
.source-details[open] .verify-meta { position: absolute; right: 0; top: 25px; z-index: 40; padding: 14px; min-width: 280px; max-width: min(430px, 85vw); background: #fff; border: 1px solid #d4e3d3; box-shadow: var(--shadow-lg); border-radius: 8px; display: grid; }
.verify-chip { background: #f5faf5; border: 1px solid #e0ebdf; color: #496a46; border-radius: 5px; font-size: 11px; white-space: normal; overflow-wrap: anywhere; }
.verify-chip-sheet, .verify-chip-count { color: #567154; background: #eaf4e9; border: 0; }
.match-report-notice { border-radius: 8px; padding: 16px; margin: 0 0 20px; font-size: 11px; line-height: 1.7; }
.match-report-notice.match-warn { background: #fcf7eb; border-color: #e9dfc5; color: #7b683e; }
.match-report-notice.match-ok { background: #eaf5e9; border-color: #d1e7cf; color: #477443; }
/* Six useful numbers, one quiet strip */
.kpi-section { margin-bottom: 22px; }
.section-eyebrow { display: flex; justify-content: space-between; gap: 12px; margin: 0 0 12px; font-size: 11px; letter-spacing: .12em; font-weight: 600; color: #5b7159; }
.section-eyebrow span:last-child { color: #616e60; font-size: 11px; font-weight: 400; letter-spacing: 0; }
.kpi-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 0; background: #fff; border: 1px solid #dae6d9; border-radius: 9px; box-shadow: none; overflow: hidden; }
.kpi-card, .kpi-card-highlight { min-height: 125px; padding: 18px 17px 15px; border: 0; border-right: 1px solid #e6eee5; border-radius: 0; background: #fff; box-shadow: none; overflow: hidden; }
.kpi-card:last-child { border: 0; }
.kpi-card:hover { transform: none; box-shadow: none; }
.kpi-card::before, .kpi-card::after { display: none; }
.kpi-top { gap: 5px; margin-bottom: 12px; }
.kpi-label { font-size: 11px; text-transform: none; letter-spacing: 0; font-weight: 500; color: #5c6d5a; white-space: nowrap; }
.kpi-icon-pill { display: none; }
.kpi-main-val { font: 550 clamp(23px, 2.1vw, 31px)/1.1 var(--font-heading); letter-spacing: -1.2px; color: #365433; margin: 0 0 12px; font-variant-numeric: tabular-nums; }
.kpi-main-val.val-blue, .kpi-main-val.val-emerald { color: #33692e; }
.kpi-main-val.val-amber { color: #816845; }
.kpi-main-val.val-gold { color: #51714e; }
.kpi-bottom { gap: 4px; align-items: flex-start; flex-wrap: wrap; }
.kpi-sub-text { font-size: 11px; color: #606c5f; line-height: 1.6; }
.kpi-mini-pill, .kpi-badge-benchmark, .kpi-status-tag { font-size: 11px; line-height: 1.5; padding: 1px 4px; font-weight: 500; border: 0; border-radius: 3px; color: #586f56; background: #eef6ed; }
.kpi-status-tag.tag-amber { color: #7a6a4b; background: #faf6ec; }
#kpi-top-name { white-space: nowrap; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
/* Benchmark */
.benchmark-bar { margin-bottom: 28px; background: transparent; border: 0; border-bottom: 1px solid #d8e6d7; border-radius: 0; box-shadow: none; padding: 0 0 22px; gap: 24px; align-items: center; }
.benchmark-title-wrap { gap: 10px; }
.benchmark-bar .pill-badge { background: none; border: 0; color: #5e6c5d; font-size: 11px; font-weight: 600; letter-spacing: .08em; padding: 0; }
.benchmark-text { gap: 8px; }
.benchmark-label { color: #5a7058; font-size: 11px; font-weight: 500; }
.benchmark-val { font: 650 15px var(--font-heading); color: #487344; }
.benchmark-slider-wrap { max-width: 300px; }
.clean-slider { height: 3px; background: #d1e5cf; accent-color: #4f7f4b; }
.clean-slider::-webkit-slider-thumb { background: #53834f; border: 3px solid #f3f7f3; box-shadow: 0 0 0 1px #739c6f; width: 12px; height: 12px; }
.slider-marks { margin-top: 6px; font-size: 11px; color: #5e6e5d; }
.slider-marks .active-mark { color: #4d734a; }
.benchmark-quick-buttons { gap: 5px; margin-left: auto; }
.preset-btn { border: 1px solid #dae7d9; padding: 5px 9px; color: #586e56; background: #fff; font-size: 11px; font-weight: 500; border-radius: 4px; box-shadow: none; }
.preset-btn.active { background: #e2f0e1; border-color: #c7e0c5; color: #457241; }
/* Shortlist workspace */
.main-workspace { min-width: 0; }
#tab-best-funds { padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; }
.best-funds-wrapper { gap: 20px; }
.best-funds-header-card { border: 0; border-radius: 0; padding: 0; background: transparent; box-shadow: none; align-items: flex-start; gap: 16px; }
.best-header-left { gap: 0; max-width: 540px; flex: 1 1 300px; }
.best-header-icon { display: none; }
.best-header-left h2 { color: #3e563c; font: 550 20px/1.4 var(--font-heading); letter-spacing: -.5px; margin-bottom: 5px; }
.best-header-left p { color: #616f60; font-size: 11px; line-height: 1.7; max-width: 450px; }
.best-header-controls { gap: 12px; align-items: flex-end; }
.best-control-group .control-label { font-size: 11px; font-weight: 500; color: #5a6d58; letter-spacing: 0; text-transform: none; }
.benchmark-toggle-pills { padding: 3px; border: 1px solid #d6e6d5; background: #fff; border-radius: 5px; box-shadow: none; }
.btn-toggle-pill { padding: 6px 8px; font-size: 11px; color: #596e57; border-radius: 3px; font-weight: 500; }
.btn-toggle-pill.active { background: #e6f2e5; color: #487344; box-shadow: none; }
.best-cat-select { min-width: 155px; max-width: 230px; height: 34px; font-size: 11px; padding: 6px 24px 6px 10px; border-color: #d6e6d5; color: #4d714a; }
.best-criteria-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.criteria-card { padding: 15px 17px; border: 1px solid #d9e6d8; background: #fff; border-radius: 8px; box-shadow: none; }
.criteria-card::before, .criteria-card::after { display: none; }
.criteria-card:hover { transform: none; box-shadow: none; }
.criteria-top { margin-bottom: 10px; }
.criteria-badge-step { color: #5b7059; background: transparent; border: 0; font-size: 11px; letter-spacing: .08em; font-weight: 500; padding: 0; }
.criteria-icon, .criteria-status { display: none; }
.criteria-card h4 { color: #497245; font: 600 11px var(--font-heading); margin: 0 0 5px; }
.criteria-card p { color: #5e6c5d; font-size: 11px; line-height: 1.7; min-height: 25px; }
.criteria-metric { padding: 10px 0 0; border: 0; background: transparent; margin-top: 5px; gap: 5px; }
.criteria-lbl { font-size: 11px; color: #5a6f58; }
.criteria-metric strong { color: #447240; font: 650 17px var(--font-heading); }
.criteria-summary-card { background: #e7f2e6; border-color: #cee6cc; }
.criteria-summary-card h4 { color: #3f6d3b; }
.shortlist-count-box { margin: 4px 0 2px; gap: 7px; }
.shortlist-number { color: #3f733a; font: 600 27px var(--font-heading); }
.shortlist-label { color: #516f4e; font-size: 11px; }
.shortlist-sub { font-size: 11px; line-height: 1.6; color: #567153; }
/* A single strong focal point for the leading fund */
.champion-showcase-card { border: 1px solid #284f24; border-radius: 11px; padding: 0; background: #22491e; box-shadow: 0 5px 18px #1c3f190a; overflow: hidden; }
.champion-showcase-card::before, .champion-showcase-card::after { display: none; }
.champion-card-inner { padding: 25px 27px 22px; position: relative; }
.champion-badge-row { gap: 12px; margin-bottom: 18px; }
.champion-crown-tag { padding: 0; border: 0; background: transparent; color: #627661; font-size: 11px; font-weight: 500; letter-spacing: .04em; }
.champion-crown-tag > span:first-child { display: none; }
.champion-crown-tag::before { content: '01'; display: inline-flex; width: 23px; height: 23px; align-items: center; justify-content: center; border: 1px solid #7b957966; border-radius: 50%; color: #badab7; font-size: 11px; margin-right: 7px; }
.champion-periods-won-badge { border: 1px solid #65846255; background: #2e552a; color: #647562; font-size: 11px; padding: 5px 8px; font-weight: 400; }
.champion-main-info { align-items: center; gap: 20px; margin-bottom: 22px; }
.champion-fund-title { color: #eaf6e9; font: 500 clamp(19px, 1.9vw, 27px)/1.45 var(--font-heading); letter-spacing: -.7px; margin: 0 0 10px; text-shadow: none; }
.champion-meta-pills { gap: 13px; }
.champ-meta-pill { color: #697468; border: 0; border-radius: 0; background: none; padding: 0; font-size: 11px; }
.champ-meta-pill strong { color: #b8d0b6; font-weight: 500; }
.champion-main-info .btn-primary { background: #daedd8; color: #375135; border-color: #daedd8; font-size: 11px; font-weight: 600; padding: 10px 14px; }
.champion-main-info .btn-primary:hover { background: #e9f6e8; }
.champion-metrics-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; border-top: 1px solid #5a7d5755; padding-top: 18px; }
.champ-stat-box { border: 0; border-right: 1px solid #5a7d5744; border-radius: 0; background: transparent; padding: 0 18px; align-items: flex-start; box-shadow: none; gap: 5px; }
.champ-stat-box:first-child { padding-left: 0; }
.champ-stat-box:last-child { border-right: 0; }
.champ-stat-label { font-size: 11px; color: #657464; text-transform: none; letter-spacing: 0; font-weight: 400; }
.champ-stat-val, .champ-stat-val.gold, .champ-stat-val.green { color: #cfeacd; font: 500 26px/1.2 var(--font-heading); letter-spacing: -.6px; }
.champ-stat-box > span:last-child { font-size: 11px !important; color: #657464 !important; }
/* Period comparison */
.period-scorecard-section { padding: 0; background: none; border: 0; box-shadow: none; }
.section-heading-row { margin: 5px 0 12px; align-items: baseline; }
.section-heading-row h3 { font: 550 13px var(--font-heading); color: #477143; }
.section-sub-text { font-size: 11px; color: #5c6e5a; }
.period-cards-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.period-card { border: 1px solid #d8e7d7; background: #fff; border-radius: 8px; padding: 15px 17px; box-shadow: none; }
.period-card:hover { transform: none; box-shadow: none; }
.period-card-top { margin-bottom: 13px; gap: 8px; align-items: center; }
.period-horizon-badge { background: #eaf4e9; color: #4f704c; border: 0; font-size: 11px; padding: 4px 7px; border-radius: 4px; }
.period-winner-ret { color: #41723d; font: 550 21px var(--font-heading); letter-spacing: -.6px; }
.period-winner-name { color: #4c7049; font-size: 11px; line-height: 1.6; font-weight: 500; margin-bottom: 6px; }
.period-winner-cat { color: #5e6e5c; font-size: 11px; }
.period-tie-tag { font-size: 11px; color: #50714d; background: #eaf6e9; }
.rolling-coverage-notice { background: #faf5e8; border: 1px solid #ebe1c5; border-radius: 6px; font-size: 11px; line-height: 1.75; color: #796842; padding: 12px 15px; margin-bottom: 15px; }
/* Explorer, tables and basket */
.ratio-screener-bar { border: 1px solid #d7e7d5; background: #fff; border-radius: 8px; padding: 15px; margin-bottom: 14px; box-shadow: none; }
.screener-header-row { gap: 12px; }
.screener-title-group { gap: 7px; }
.screener-icon { color: #51724e; }
.screener-title { color: #4a7346; font-size: 11px; font-weight: 600; }
.screener-presets-group { gap: 5px; flex-wrap: wrap; }
.ratio-preset-chip, .ratio-preset-chip[data-preset='best-funds'] { border: 1px solid #d7e8d5 !important; background: #f6fbf5 !important; color: #526f4f !important; border-radius: 5px; padding: 6px 8px; font-size: 11px; font-weight: 500 !important; box-shadow: none; }
.ratio-preset-chip.active { background: #deefdd !important; border-color: #bfddbc !important; color: #3f753a !important; }
.custom-filter-drawer { border-top: 1px solid #dcecdb; background: #f6fcf6; padding: 16px 0 0; }
.filter-field-card { background: transparent; border: 0; padding: 0; }
.filter-field-card label { font-size: 11px; color: #4a7146; }
.table-controls { background: transparent; border: 0; padding: 0; box-shadow: none; margin-bottom: 14px; gap: 14px; }
.search-input-box { background: #fff; border: 1px solid #d7e7d5; border-radius: 6px; min-width: 0; }
.search-input-box input { font-size: 11px; color: #457441; padding: 10px; min-width: 0; }
.search-input-box input::placeholder { color: #5e6f5c; }
.select-box label { font-size: 11px; color: #50704d; }
.btn-toggle { background: #fff; color: #537050; border-color: #d6e7d4; font-size: 11px; }
.btn-toggle.active { background: #e6f4e5; color: #3e7539; border-color: #c9e4c7; }
.table-card { border: 1px solid #d8e6d7; border-radius: 9px; background: #fff; box-shadow: none; overflow: hidden; margin-top: 0 !important; }
.table-meta-row { background: #fff; padding: 16px 18px; border-bottom: 1px solid #e1ede0; gap: 12px; flex-wrap: wrap; }
.table-meta-row .meta-left, .table-meta-row > span { font-size: 11px; color: #487444; gap: 9px; }
.table-sub-badge { font-size: 11px; font-weight: 400; background: transparent; border: 0; color: #596e57; padding: 0; }
.table-legend { gap: 10px; }
.legend-item { font-size: 11px; }
.legend-green { color: #457541; }
.legend-red { color: #876458; }
.table-responsive { max-height: 650px; scrollbar-width: thin; scrollbar-color: #c2dac0 #f4faf3; }
.data-table { border-collapse: separate; border-spacing: 0; width: 100%; font-size: 11px; }
.data-table thead th { background: #f0f8ef; border-bottom: 1px solid #dcebdb; color: #537050; font-size: 11px; font-weight: 600; text-transform: none; letter-spacing: .01em; padding: 12px 13px; position: sticky; top: 0; white-space: nowrap; }
.data-table tbody td { border-bottom: 1px solid #eaf3e9; padding: 14px 13px; font-size: 11px; color: #4e724b; line-height: 1.6; }
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody tr:hover td { background: #f0faef; }
.data-table tbody tr:nth-child(even) { background: #f9fdf9; }
.data-table .fund-name-cell { min-width: 245px; max-width: 300px; }
.fund-name-text { white-space: normal; color: #426f3e; font-size: 11px; font-weight: 550; line-height: 1.65; }
.data-table .row-above-avg { background: #f1faf0; }
.data-table .row-below-avg { background: #fff; }
.data-table .row-selected { background: #e4f5e3; box-shadow: inset 3px 0 #679f62; }
.data-table tbody tr[style] { background: #fff !important; border-left: 0 !important; }
.data-table tbody tr[style]:first-child { background: #eaf7e9 !important; }
.category-pill { font-size: 11px; font-weight: 400; padding: 3px 6px; color: #4f6f4c; background: #eaf6e9; border: 1px solid #dbedd9; border-radius: 4px; }
.rank-badge { border: 0; background: #e9f5e8; color: #4b7048; font: 500 9px var(--font-base); border-radius: 4px; width: 25px; height: 25px; box-shadow: none !important; }
.rank-badge.rank-gold, .rank-badge.rank-1 { background: #ddf0db !important; color: #3d7238 !important; border: 0 !important; }
.rank-badge.rank-silver, .rank-badge.rank-2, .rank-badge.rank-bronze, .rank-badge.rank-3 { background: #eaf4e9 !important; color: #4c7049 !important; border: 0 !important; }
.sharpe-badge { font-size: 11px; font-weight: 500; padding: 3px 6px; border-radius: 4px; box-shadow: none; }
.sharpe-high { background: #e6f5e5; color: #43743f; border: 1px solid #d4ecd2; }
.sharpe-low { background: #fbf2ed; color: #806854; border: 1px solid #f0e2d8; }
.sharpe-na { background: #f0f6f0; color: #5f6d5e; border: 0; }
.delta-pos { color: #487244; font-weight: 400; }
.delta-neg { color: #7a6855; font-weight: 400; }
.period-win-badge, .selection-status-badge { background: #e2f4e0; border-color: #d0ebce; color: #3f723a; font-size: 11px; font-weight: 500; box-shadow: none; }
.pagination-footer { background: #fff; border-top: 1px solid #e1efe0; padding: 12px 18px; font-size: 11px; color: #587056; }
.rows-per-page .form-select { padding: 4px 7px; font-size: 11px; }
.page-num-btn, .btn-page-nav { border-color: #d9ead7; color: #4f6f4c; background: #fff; font-size: 11px; border-radius: 4px; box-shadow: none; }
.page-num-btn.active { background: #e1f2df; color: #3e7239; border-color: #c8e5c5; }
.basket-toolbar { position: sticky; top: 10px; z-index: 20; background: #254f21; border: 1px solid #254f21; border-radius: 8px; box-shadow: 0 5px 15px #254f2112; padding: 14px 18px; color: #e5f4e4; margin-bottom: 14px; }
.basket-title, .basket-title strong { color: #e2f4e0; }
.basket-chip { background: #355e31; border-color: #587d55; color: #abd1a8; font-size: 11px; }
.basket-chip strong { color: #e3f4e1; }
.basket-toolbar .btn { background: transparent; color: #c5e4c2; border: 1px solid #668f62; font-size: 11px; }
.basket-toolbar .btn-primary { background: #d4edd2; color: #3c6238; border-color: #d4edd2; }
/* Charts, source inspector, dialogs */
.charts-grid { gap: 16px; }
.chart-card, .schema-card { background: #fff; border: 1px solid #d7e7d5; border-radius: 9px; padding: 21px; box-shadow: none; }
.chart-card-header { border-bottom: 1px solid #e8f2e7; padding-bottom: 16px; margin-bottom: 20px; gap: 10px; }
.chart-card-header h3, .schema-header h3 { color: #457341; font: 550 14px/1.5 var(--font-heading); }
.chart-type-tag, .chart-type-tag.gold-tag { font-size: 11px; font-weight: 600; letter-spacing: .06em; color: #506f4d; background: none; border: 0; padding: 0; margin-bottom: 6px; }
.chart-sub { font-size: 11px; color: #586f56; }
.rolling-banner-card { background: none; border: 0; padding: 0 0 15px; box-shadow: none; }
.rolling-banner-card .banner-icon { display: none; }
.rolling-banner-card h3 { font: 550 22px var(--font-heading); color: #41743c; }
.rolling-banner-card p, .schema-header p { color: #526e50; font-size: 11px; }
.schema-field { background: #f3fbf2; border: 1px solid #daecd8; border-radius: 7px; padding: 15px; }
.schema-field label { color: #4a7047; font-size: 11px; }
.schema-field input[readonly] { color: #547151; background: #fff; }
.modal-backdrop { backdrop-filter: blur(5px); background: #1a3b1766; }
.modal-dialog { border: 1px solid #d3e6d1; border-radius: 12px; background: #fff; box-shadow: 0 25px 90px #1b3a1830; }
.modal-header { background: #f2faf1; border-bottom: 1px solid #deeedc; padding: 22px 24px; }
.modal-title-group h3 { color: #3e7539; font: 600 18px var(--font-heading); }
.modal-icon { color: #51714e; }
.modal-body { padding: 22px 24px; }
.modal-desc { color: #516f4e; font-size: 12px; line-height: 1.7; }
.modal-footer { background: #f9fdf9; border-top: 1px solid #e0efdf; padding: 17px 24px; }
.snapshot-preview-grid { gap: 10px; }
.preview-metric { border: 1px solid #d9edd7; background: #f0faef; border-radius: 6px; }
.preview-label { color: #51714e; font-size: 11px; }
.preview-val { color: #43743f; font: 600 19px var(--font-heading); }
.saved-record-card { border: 1px solid #d7ecd5; border-radius: 8px; background: #fff; box-shadow: none; }
.record-title { color: #457541; font-size: 13px; }
.record-stat-chip { background: #eff9ee; border: 0; color: #526f4f; }
.storage-info-banner { background: #e7f6e6; border-color: #cfeacd; }
.storage-info-banner, .compass-details { color: #4e724b; font-size: 11px; }
.toast { background: #fff; color: #3d7438; border-color: #d0e8ce; border-radius: 7px; box-shadow: var(--shadow-lg); font-size: 12px; }
.app-footer { border-top: 1px solid #d7e7d6; color: #576d55; font-size: 11px; padding: 20px 0 0; margin-top: 36px; background: none; }
/* Empty workspace */
.empty-state-view { max-width: none; background: #fff; border: 1px solid #d8e7d7; border-radius: 12px; padding: 50px 35px 30px; margin: 24px 0 0; box-shadow: none; text-align: center; }
.empty-icon-ring { margin: 0 auto 20px; width: 52px; height: 52px; border: 1px solid #cee8cc; background: #e8f5e7; color: #4d6f4a; box-shadow: none; border-radius: 12px; }
.empty-icon-ring .ui-icon { width: 23px; height: 23px; }
.empty-state-view h2 { color: #40733b; font: 500 27px/1.4 var(--font-heading); letter-spacing: -.7px; margin: 10px 0; }
.empty-state-view > p { color: #546e52; max-width: 505px; margin: 0 auto; font-size: 12px; line-height: 1.8; }
.empty-cta-buttons { margin: 24px 0 38px; }
.features-summary-grid { border-top: 1px solid #e3f0e2; padding-top: 26px; gap: 22px; text-align: left; }
.feature-card { border: 0; border-radius: 0; background: transparent; padding: 0 10px; box-shadow: none; }
.feature-card:hover { transform: none; box-shadow: none; }
.feat-icon { display: block; color: #51714e; margin-bottom: 10px; }
.feature-card h4 { color: #467242; font: 600 11px var(--font-heading); margin-bottom: 7px; }
.feature-card p { color: #5b7059; font-size: 11px; line-height: 1.8; }
/* Sign-in: warm editorial typography alongside a restrained form */
.auth-screen { padding: 0; background: #f7fbf7; align-items: stretch; justify-content: stretch; min-height: 100svh; }
.auth-story { position: relative; width: 54%; min-height: 100svh; padding: 42px 58px 28px; background: #20431d; color: #e4f2e3; overflow: hidden; display: flex; flex-direction: column; }
.story-brand { display: flex; align-items: center; gap: 16px; font-size: 11px; letter-spacing: .15em; font-weight: 500; z-index: 1; }
.story-brand small { display: block; font-size: 11px; color: #687467; letter-spacing: .2em; margin-top: 6px; }
.story-copy { position: relative; z-index: 1; margin-top: clamp(60px, 10vh, 125px); }
.story-copy .eyebrow { color: #657364; letter-spacing: .17em; font-size: 11px; }
.story-copy h1 { font: 400 clamp(40px, 4.4vw, 67px)/1.08 Georgia, 'Times New Roman', serif; letter-spacing: -2.5px; margin: 21px 0 22px; }
.story-copy h1 em { color: #5e765b; font-weight: 400; }
.story-copy p { color: #697368; font-size: 12px; line-height: 1.9; }
.research-art { position: absolute; right: -35px; bottom: 45px; width: 330px; height: 270px; pointer-events: none; opacity: .72; }
.art-orbit { border: 1px solid #89b18526; border-radius: 50%; position: absolute; width: 290px; height: 290px; left: 30px; top: 0; }
.orbit-two { width: 220px; height: 220px; left: 65px; top: 35px; }
.orbit-three { width: 150px; height: 150px; left: 100px; top: 70px; }
.art-line { position: absolute; left: 22px; bottom: 43px; width: 265px; height: 1px; background: #749c7077; }
.art-bars { display: flex; align-items: flex-end; gap: 15px; position: absolute; left: 25px; right: 48px; bottom: 44px; height: 160px; }
.art-bars i { flex: 1; background: #7aa77622; border: 1px solid #97c09344; border-bottom: 0; border-radius: 2px 2px 0 0; height: 25%; }
.art-bars i:nth-child(2) { height: 40%; }.art-bars i:nth-child(3) { height: 33%; }.art-bars i:nth-child(4) { height: 60%; }.art-bars i:nth-child(5) { height: 52%; }.art-bars i:nth-child(6) { height: 80%; }.art-bars i:nth-child(7) { height: 100%; background: #95c79066; }
.art-caption { position: absolute; bottom: 23px; left: 27px; color: #89b28577; font-size: 11px; letter-spacing: .18em; }
.story-footer { display: flex; justify-content: space-between; gap: 20px; align-items: end; margin-top: auto; padding-top: 95px; color: #647462; font-size: 11px; z-index: 1; }
.story-footer span { font-size: 11px; letter-spacing: .12em; color: #657364; }
.auth-card { align-self: center; width: min(365px, calc(46vw - 96px)); max-width: 365px; margin: 45px auto; padding: 0; border: 0; border-radius: 0; box-shadow: none; background: transparent; }
.auth-brand { align-items: flex-start; text-align: left; margin-bottom: 32px; }
.auth-logo { width: 53px; height: 53px; object-fit: contain; margin-bottom: 28px; border-radius: 7px; }
.auth-brand .eyebrow { font-size: 11px; color: #567154; }
.auth-title { color: #395b36; font: 500 32px/1.3 var(--font-heading); letter-spacing: -1.2px; margin: 9px 0 10px; }
.auth-sub { color: #5c6e5a; font-size: 12px; line-height: 1.7; max-width: 290px; }
.auth-field { margin-bottom: 19px; }
.auth-field label { color: #4f734c; font-size: 11px; font-weight: 500; margin-bottom: 8px; }
.auth-field input { padding: 13px 14px; min-height: 46px; font-size: 12px; border: 1px solid #d4e5d2; border-radius: 6px; color: #43733f; background: #fff; }
.auth-field input::placeholder { color: #5c6c5b; }
.auth-field input:focus { border-color: #79a975; box-shadow: 0 0 0 3px #e6f3e5; }
.auth-eye { color: #567153; font-size: 12px; right: 9px; }
.auth-submit { min-height: 46px; margin-top: 8px; font-size: 12px; background: #254f21; border-color: #254f21; }
.auth-submit::after { content: '→'; margin-left: auto; color: #596e57; font-size: 18px; }
.auth-submit { justify-content: space-between; }
.auth-footnote { margin-top: 26px; padding-top: 21px; font-size: 11px; line-height: 1.8; color: #5c6e5a; border-color: #d9e9d8; }
.auth-error { font-size: 11px; border-radius: 6px; }
/* Layout sizes and touch targets */
@media (min-width: 1900px) { .investor-workspace { margin-right: auto; margin-left: max(228px, calc((100vw - 1650px) / 2)); } }
@media (max-width: 1390px) {
  .investor-rail { width: 210px; padding-left: 12px; padding-right: 12px; }
  .investor-workspace { margin-left: 210px; padding-left: 26px; padding-right: 26px; }
  .user-email { display: none; }
  .kpi-card { padding-left: 13px; padding-right: 13px; }
  .best-header-controls { flex-wrap: nowrap; }
  .best-header-left { flex-basis: 270px; }
  .best-cat-select { max-width: 175px; min-width: 140px; }
  .upload-card { padding: 13px; }.upload-card-details p { max-width: 205px; }
}
@media (max-width: 1120px) {
  .investor-rail { width: 190px; padding-left: 10px; padding-right: 10px; }
  .investor-workspace { margin-left: 190px; padding-left: 22px; padding-right: 22px; }
  .rail-brand { gap: 9px; padding-left: 5px; }.rail-brand > span:last-child { font-size: 11px; }
  .investor-rail .tab-button { gap: 8px; font-size: 11px; padding: 12px 9px; }
  .brand-title-row .db-status-badge { display: none; }
  .header-main { gap: 12px; }.header-actions { gap: 5px; }.header-actions .btn { padding: 7px; }
  .workspace-edition { display: none; }
  .kpi-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }.kpi-card { min-height: 110px; padding: 15px 17px; }
  .kpi-card:nth-child(3) { border-right: 0; }.kpi-card:nth-child(-n+3) { border-bottom: 1px solid #e6eee5; }
  .kpi-main-val { font-size: 28px; }.kpi-bottom { flex-wrap: nowrap; }
  .upload-icon-badge { display: none; }.upload-card-content { gap: 7px; }.upload-card-details p { font-size: 11px; }
  .benchmark-bar { gap: 15px; flex-wrap: wrap; }.benchmark-slider-wrap { max-width: none; flex: 1 1 180px; }
  .benchmark-quick-buttons { margin-left: 0; }.benchmark-bar .pill-badge { display: none; }
  .best-header-left { flex: 1 1 100%; max-width: none; }.best-header-left p { max-width: none; }
  .best-header-controls { width: 100%; }.best-control-group:last-child { margin-left: auto; }
  .best-criteria-grid, .period-cards-grid { gap: 9px; }.criteria-card, .period-card { padding: 13px; }
  .criteria-card p { min-height: 28px; }.criteria-badge-step { font-size: 11px; }
  .champion-main-info { flex-wrap: wrap; }.champion-fund-title { font-size: 22px; }
  .auth-story { padding: 40px; }.story-copy h1 { font-size: 52px; }
  .auth-card { width: calc(46vw - 70px); }.research-art { opacity: .4; right: -50px; }
}
@media (max-width: 800px) {
  .investor-rail { position: relative; width: 100%; padding: 16px 20px 0; border-right: 0; border-bottom: 1px solid #d8e7d7; background: #f9fdf9; overflow: visible; }
  .rail-brand { padding: 0 0 15px; gap: 11px; }.rail-brand > span:last-child { font-size: 13px; }
  .rail-label, .rail-note, .rail-footer { display: none; }
  .investor-rail .tabs-nav-bar { flex-direction: row; overflow-x: auto; gap: 5px; padding: 0 0 10px; scrollbar-width: thin; }
  .investor-rail .tab-button { width: auto; flex: 0 0 auto; min-height: 40px; padding: 8px 11px; font-size: 11px; }
  .investor-rail .tab-pill { margin-left: 3px; }.investor-rail .ui-icon { width: 15px; height: 15px; }
  .investor-workspace { margin-left: 0; padding: 0 20px 20px; }
  .header-main { min-height: 74px; padding: 16px 0; }.brand-group { flex-basis: 185px; }.header-actions { margin-left: auto; }
  .workspace-heading { padding: 25px 0 22px; }.workspace-heading h1 { font-size: 28px; }
  .workspace-heading p { font-size: 11px; }
  .best-criteria-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .champion-card-inner { padding: 22px; }.champion-metrics-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .champ-stat-box { padding: 0 12px; }.champ-stat-val { font-size: 23px; }
  .charts-grid { grid-template-columns: 1fr; }.chart-card.full-span { grid-column: auto; }
  .auth-story { width: 47%; padding: 30px; }.story-copy h1 { font-size: 42px; letter-spacing: -1.6px; }.story-copy { margin-top: 90px; }
  .story-brand { font-size: 11px; gap: 10px; }.story-brand small { font-size: 11px; }
  .story-footer span { display: none; }.auth-card { width: calc(53vw - 64px); }.research-art { bottom: 65px; opacity: .35; }
}
@media (max-width: 580px) {
  .investor-rail { padding: 15px 14px 0; }.rail-brand { padding-bottom: 14px; }
  .investor-workspace { padding: 0 14px 20px; }.header-main { align-items: flex-start; gap: 11px; }
  .brand-group { flex: 1 1 100%; }.brand-title { font-size: 11px; }.brand-subtitle { font-size: 11px; }.brand-title-row .db-status-badge { display: inline-flex; margin-left: auto; }
  .header-actions { flex: 1 1 100%; justify-content: flex-start; gap: 6px; }.header-actions .btn { min-height: 36px; padding: 8px 10px; font-size: 11px; }
  .user-chip { margin-left: auto; padding-left: 7px; gap: 5px; }.user-avatar { width: 27px; height: 27px; }.btn-signout { font-size: 11px; }
  .workspace-heading { padding: 25px 0 21px; }.workspace-heading h1 { font-size: 25px; letter-spacing: -.9px; }.workspace-heading p { font-size: 11px; }
  .upload-dual-grid { grid-template-columns: 1fr; gap: 9px; }.upload-card { padding: 13px; }.upload-icon-badge { display: flex; width: 31px; min-width: 31px; height: 35px; }.upload-card-details h4 { font-size: 11px; }.upload-card-details p { max-width: 210px; font-size: 11px; }.upload-card .btn { min-height: 35px; padding: 7px; }
  .upload-card-content { gap: 10px; }.upload-card-actions { max-width: 135px; }
  .excel-verification-banner { padding: 11px; margin-bottom: 22px; gap: 8px; }.verify-details { flex: 1 1 75%; }.source-details { margin-right: auto; }.source-details[open] .verify-meta { left: 0; right: auto; }
  .kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }.kpi-card { min-height: 113px; padding: 16px; }.kpi-card:nth-child(3) { border-right: 1px solid #e6eee5; }.kpi-card:nth-child(2n) { border-right: 0; }.kpi-card:nth-child(-n+4) { border-bottom: 1px solid #e6eee5; }
  .kpi-label { font-size: 11px; }.kpi-main-val { font-size: 29px; }.kpi-sub-text { font-size: 11px; }.kpi-mini-pill { font-size: 11px; }
  .section-eyebrow { font-size: 11px; }.section-eyebrow span:last-child { font-size: 11px; }
  .benchmark-bar { gap: 18px; padding-bottom: 20px; margin-bottom: 24px; }.benchmark-title-wrap { flex: 1 1 100%; }.benchmark-slider-wrap { min-width: 125px; flex: 1; }.benchmark-quick-buttons { gap: 4px; }.preset-btn { padding: 7px 5px; font-size: 11px; min-height: 33px; }
  .best-header-left h2 { font-size: 19px; }.best-header-left p { font-size: 11px; }
  .best-header-controls { gap: 7px; flex-wrap: wrap; }.best-cat-select { max-width: 165px; min-width: 135px; height: 37px; font-size: 11px; }.btn-toggle-pill { font-size: 11px; min-height: 29px; padding: 6px; }
  .best-criteria-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }.criteria-card { padding: 15px; }.criteria-card h4 { font-size: 12px; }.criteria-card p { font-size: 11px; min-height: 27px; }.criteria-badge-step { font-size: 11px; }.shortlist-sub { font-size: 11px; }
  .champion-card-inner { padding: 20px 17px; }.champion-badge-row { align-items: flex-start; flex-direction: column; gap: 8px; margin-bottom: 15px; }.champion-crown-tag { font-size: 11px; }.champion-periods-won-badge { font-size: 11px; }
  .champion-fund-title { font-size: 22px; }.champion-meta-pills { gap: 7px; }.champ-meta-pill { font-size: 11px; }.champion-main-info { gap: 16px; }.champion-main-info .btn { min-height: 38px; }
  .champion-metrics-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 22px; }.champ-stat-box { padding: 0 12px; }.champ-stat-box:nth-child(3) { padding-left: 0; }.champ-stat-box:nth-child(2) { border-right: 0; }.champ-stat-val, .champ-stat-val.gold, .champ-stat-val.green { font-size: 27px; }.champ-stat-label { font-size: 11px; }
  .section-heading-row { flex-direction: column; align-items: flex-start; gap: 5px; }.section-heading-row h3 { font-size: 13px; }.period-cards-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }.period-card { padding: 14px; }.period-winner-ret { font-size: 22px; }
  .table-meta-row { padding: 13px; }.table-meta-row .meta-left { flex-wrap: wrap; }.table-meta-row .meta-right { width: 100%; }.table-meta-row .meta-right .btn { min-height: 35px; font-size: 11px; }.table-responsive { max-height: 560px; }
  .data-table .fund-name-cell { min-width: 200px; }.data-table tbody td { padding: 13px 10px; }.fund-name-text { font-size: 11px; }
  .screener-header-row { flex-direction: column; align-items: flex-start; }.ratio-preset-chip { font-size: 11px; min-height: 34px; }.screener-presets-group { gap: 6px; }.filter-drawer-grid { grid-template-columns: 1fr; }
  .table-controls { flex-direction: column; }.search-input-box { width: 100%; }.search-input-box input { min-height: 42px; width: 100%; font-size: 16px; }.filter-controls-group { width: 100%; flex-wrap: wrap; }.form-select { min-height: 36px; }
  .basket-toolbar { position: static; padding: 14px; gap: 12px; }.basket-toolbar .btn { min-height: 35px; }.basket-stats { flex-wrap: wrap; }
  .chart-card { padding: 16px; }.chart-card-header { flex-direction: column; align-items: flex-start; }.chart-canvas-box { min-width: 0; }.schema-grid { grid-template-columns: 1fr; }
  .empty-state-view { padding: 33px 19px 24px; }.empty-state-view h2 { font-size: 23px; }.empty-state-view > p { font-size: 11px; }.empty-cta-buttons { flex-direction: column; gap: 9px; margin-bottom: 28px; }.empty-cta-buttons .btn { width: 100%; min-height: 44px; }.features-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 23px 14px; }.feature-card { padding: 0; }
  .modal-dialog { width: calc(100% - 24px); max-height: 90svh; margin: auto; }.modal-body, .modal-header, .modal-footer { padding: 18px; }.snapshot-preview-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }.modal-input, .auth-field input { font-size: 16px; }
  .auth-screen { flex-direction: column; min-height: 100svh; }.auth-story { width: 100%; min-height: 0; padding: 25px 25px 29px; }.story-brand { font-size: 11px; }.story-copy { margin-top: 28px; }.story-copy .eyebrow { font-size: 11px; }.story-copy h1 { font-size: 37px; letter-spacing: -1.3px; margin: 13px 0 10px; }.story-copy h1 br:nth-child(2) { display: none; }.story-copy p, .story-footer { display: none; }.research-art { width: 195px; height: 180px; right: -60px; bottom: -5px; opacity: .35; transform: scale(.75); transform-origin: bottom right; }
  .auth-card { width: auto; max-width: none; margin: 0; padding: 30px 25px 34px; }.auth-logo { display: none; }.auth-brand { margin-bottom: 23px; }.auth-title { font-size: 27px; }.auth-brand .eyebrow { display: none; }.auth-sub { max-width: none; font-size: 12px; }.auth-field input { min-height: 48px; }.auth-submit { min-height: 47px; }.auth-footnote { font-size: 11px; }
  .app-footer { font-size: 11px; gap: 12px; flex-wrap: wrap; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }

/* Readability and the original ARP identity. */
.workspace-logo { display: block; width: 64px; height: 62px; object-fit: contain; flex-shrink: 0; background: #fff; border-radius: 6px; padding: 3px; }
.rail-brand { gap: 10px; padding-left: 0; padding-right: 0; }
.rail-brand > span:last-child { font-size: 12px; line-height: 1.5; }
.rail-brand small { font-size: 9px; letter-spacing: .05em; color: #51664f; }
.story-brand .workspace-logo { width: 80px; height: 77px; padding: 4px; }
.story-brand small { letter-spacing: .08em; }
.auth-logo { width: 76px; height: 74px; }
.data-table thead th { font-size: 11px; color: #425c40; }
.data-table tbody td, .fund-name-text { font-size: 12px; }
.kpi-label { white-space: normal; }
.kpi-bottom { flex-wrap: wrap; }
.kpi-sub-text { overflow-wrap: anywhere; }
.criteria-card p { min-height: 38px; }
.champion-main-info .btn-primary { color: #2b4629; }
.basket-toolbar .btn-primary { color: #2b4629; }
.sharpe-high, .delta-pos, .legend-green { color: #2d6228; }
.sharpe-low, .delta-neg, .legend-red { color: #934735; }
.sharpe-na { color: #586956; }
input::placeholder { color: #60705f; opacity: 1; }
@media (max-width: 1120px) and (min-width: 801px) {
  .rail-brand { flex-direction: column; align-items: flex-start; gap: 8px; padding-left: 9px; }
}
@media (max-width: 580px) {
  .workspace-logo { width: 56px; height: 54px; }
  .story-brand .workspace-logo { width: 65px; height: 63px; }
  .story-brand { letter-spacing: .08em; }
  .upload-card-content { flex-wrap: wrap; }
  .upload-card-actions { max-width: none; }
  .best-cat-select { max-width: 100%; }
}

/* Override legacy active-state colors with the same readable palette. */
.investor-rail .tab-button[data-tab="tab-best-funds"].active { box-shadow: none; }
.investor-rail .tab-button[data-tab="tab-best-funds"] .tab-pill { background: #d7ead5; color: #2e522b; box-shadow: none; }
.criteria-card .criteria-status.status-pass { background: #e9f5e8; color: #2d6228; }

/* Keep the decorative sign-in caption readable outside the faded artwork. */
.story-art-caption { color: #b9d4b7; font-size: 11px; letter-spacing: .10em; margin-top: 30px; position: relative; z-index: 1; }
@media (max-width: 580px) { .story-art-caption { display: none; } }

/* Modern investor theme: midnight navy, clear blue and teal. */
:root {
  --bg-main: #f4fcf3; --bg-card: #fff; --bg-card-hover: #f7fdf6;
  --bg-surface: #effaee; --bg-surface-light: #e6f7e4; --bg-input: #fff;
  --border-subtle: #e9f7e8; --border-card: #daefd8; --border-highlight: #51c947;
  --text-primary: #1b4617; --text-secondary: #467142; --text-muted: #567d52; --text-dim: #5f825c;
  --primary: #43c138; --primary-hover: #36992d;
  --accent-gradient: linear-gradient(120deg, #43c138, #2a7723);
  --emerald: #22611c; --emerald-bg: #e7f6f1; --emerald-border: #bde5d9;
  --amber: #926014; --amber-bg: #fff7e5; --amber-border: #eedbb0;
  --rose: #b33e55; --rose-bg: #fff0f3; --rose-border: #efc7d0;
  --blue: #43c138; --blue-bg: #f2fbf1;
  --radius-sm: 7px; --radius-md: 11px; --radius-lg: 16px;
  --shadow-card: 0 4px 18px rgba(27, 70, 23,.04);
  --shadow-lg: 0 20px 65px rgba(20, 58, 17,.17);
}
body { background: #f4fcf3; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, summary:focus-visible { outline-color: #67d05e; }
.investor-rail { background: linear-gradient(170deg,#194714 0%,#12340f 100%); border-right: 1px solid #285624; }
.rail-brand, .rail-brand > span:last-child { color: #f8fdf7; }
.rail-brand small, .rail-label { color: #add8a9; }
.rail-brand small { font-size: 10px; }
.workspace-logo { border: 1px solid #e3f3e2; border-radius: 10px; box-shadow: 0 3px 12px #0b200918; }
.investor-rail .tab-button { color: #c8e8c5; border-radius: 9px; min-height: 47px; }
.investor-rail .tab-button:hover:not(:disabled) { background: #275c22; color: #fff; }
.investor-rail .tab-button.active, .investor-rail .tab-button[data-tab="tab-best-funds"].active {
  background: #43c138; border-color: #5ccd52; color: #fff; box-shadow: 0 4px 16px #12330f30;
}
.investor-rail .tab-button .tab-pill, .investor-rail .tab-button:not(.active) .tab-pill,
.investor-rail .tab-button[data-tab="tab-best-funds"] .tab-pill { background: #2e6129; color: #dbf4d9; }
.investor-rail .tab-button.active .tab-pill, .investor-rail .tab-button[data-tab="tab-best-funds"].active .tab-pill { background: #fff; color: #2d8126; }
.rail-note, .rail-note strong { color: #daf4d7; }
.rail-note p, .rail-note > span:last-child, .rail-footer { color: #add8a9; }
.rail-note-icon { color: #457e3f; }.rail-note-line { background: #3d6f38; }.rail-dot { background: #73d46a; }
.header-main { border-bottom-color: #def1dc; }
.brand-title, .workspace-heading h1 { color: #1b4617; }
.workspace-heading h1 { font-weight: 600; letter-spacing: -1.1px; }
.workspace-heading .eyebrow { color: #2d8226; }
.workspace-heading p { color: #567d52; font-size: 13px; }
.workspace-edition { border-left: 2px solid #41a938; padding-left: 16px; }
.user-avatar { background: #e8f8e7; color: #2d8226; }
.db-status-badge { color: #22611c; }.db-dot { background: #2a7723; }
.btn { border-radius: 8px; }
.btn-primary, .btn-add-rolling-inline, .auth-submit { background: #43c138; border-color: #43c138; color: #fff; box-shadow: 0 3px 8px #43c1381a; }
.btn-primary:hover, .btn-add-rolling-inline:hover, .auth-submit:hover { background: #36992d; border-color: #36992d; }
.btn-secondary, .btn-outline { border-color: #cfe9cd; color: #3a6c35; }
.btn-secondary:hover, .btn-outline:hover { background: #f2fbf1; border-color: #a7e4a1; color: #2d8226; }
.form-select:focus, .ratio-input:focus, .modal-input:focus, .auth-field input:focus { border-color: #67d05e; box-shadow: 0 0 0 3px #43c13815; }
input[type=checkbox] { accent-color: #43c138; }
.upload-card { background: #fff; border-color: #bee3bb; border-radius: 12px; box-shadow: var(--shadow-card); }
.upload-card:hover, .upload-card.dragover { background: #f2fbf1; border-color: #67d05e; }
.upload-card.loaded-card { background: #f1f8f0; border-color: #c7e4dc; }
.upload-icon-badge { color: #2d8226; background: #f0faef; border-radius: 9px; }
.excel-verification-banner { background: #eaf6f3; border-color: #c8e4dc; border-radius: 10px; }
.verify-badge, .verify-details, .verify-details strong { color: #2c6727; }
.kpi-grid { background: transparent; border: 0; border-radius: 0; gap: 10px; overflow: visible; }
.kpi-card, .kpi-card-highlight, .kpi-card:nth-child(n) { border: 1px solid #def1dc; border-radius: 12px; box-shadow: var(--shadow-card); background: #fff; }
.kpi-card:first-child { background: #f2fbf1; border-color: #d3f2d0; }
.kpi-main-val, .kpi-main-val.val-blue { color: #2d8226; }
.kpi-main-val.val-emerald { color: #22611c; }.kpi-main-val.val-amber { color: #926014; }.kpi-main-val.val-gold { color: #846e39; }
.kpi-label { color: #477543; font-weight: 600; }
.kpi-mini-pill, .kpi-badge-benchmark, .kpi-status-tag { background: #f0faef; color: #477543; }
.clean-slider { background: #cef0cb; accent-color: #43c138; }
.clean-slider::-webkit-slider-thumb { background: #43c138; border-color: #fff; box-shadow: 0 0 0 1px #8ddc86; }
.preset-btn.active, .btn-toggle-pill.active, .btn-toggle.active { background: #effaee; color: #2d8226; border-color: #d0f0cd; }
.criteria-card { border-radius: 12px; box-shadow: var(--shadow-card); }
.criteria-summary-card { background: #eaf6f3; border-color: #c8e4dc; }
.shortlist-number { color: #22611c; }
.criteria-card .criteria-status.status-pass { background: #e7f6f1; color: #22611c; }
.champion-showcase-card { border: 1px solid #2a6624; border-radius: 16px; background: linear-gradient(120deg,#194714 0%,#1c5117 65%,#1f5a1a 100%); box-shadow: 0 10px 26px #19471414; }
.champion-fund-title { color: #fff; font-weight: 600; }
.champion-crown-tag { color: #d3f1d0; background: transparent; }
.champion-crown-tag::before { color: #98df92; border-color: #60965b; }
.champion-periods-won-badge { background: #256020; color: #dcf5ee; border-color: #44803e; }
.champ-meta-pill, .champ-stat-label { color: #c6e7c3; }
.champ-meta-pill strong, .champ-stat-box > span:last-child { color: #c7e4c4 !important; }
.champ-stat-val, .champ-stat-val.gold, .champ-stat-val.green { color: #fff; }
.champion-metrics-grid { border-color: #58895466; }.champ-stat-box { border-color: #58895466; }
.champion-main-info .btn-primary { background: #b2e7ae; border-color: #b2e7ae; color: #174213; }
.champion-main-info .btn-primary:hover { background: #d8f3d6; border-color: #d8f3d6; }
.period-card, .table-card, .chart-card, .schema-card, .ratio-screener-bar { border-radius: 12px; border-color: #def1dc; box-shadow: var(--shadow-card); }
.period-winner-ret { color: #22611c; }.period-horizon-badge { background: #f2fbf1; color: #2d8226; }
.data-table thead th { background: #effaee; color: #406f3c; border-color: #def1dc; font-weight: 650; }
.data-table tbody td { color: #467142; border-bottom-color: #ebf8ea; }
.data-table tbody tr:nth-child(even) { background: #f8fdf8; }.data-table tbody tr:hover td { background: #f2fbf1; }
.data-table .row-above-avg { background: #f0f9f6; }.data-table .row-selected { background: #f0faef; box-shadow: inset 3px 0 #43c138; }
.data-table tbody tr[style]:first-child { background: #f2fbf1 !important; }
.fund-name-text { color: #275d22; font-weight: 600; }.category-pill { background: #effaee; color: #4a7846; border-color: #def1dc; }
.sharpe-high, .delta-pos, .legend-green { color: #22611c; }.sharpe-high { background: #e7f6f1; border-color: #bde5d9; }
.sharpe-low, .delta-neg, .legend-red { color: #b33e55; }.sharpe-low { background: #fff0f3; border-color: #efc7d0; }
.sharpe-na { color: #567d52; background: #effaee; }
.rank-badge.rank-1, .rank-badge.rank-gold { background: #fff3d6 !important; color: #855b16 !important; }
.basket-toolbar { background: #1d5218; border-color: #2c6b26; border-radius: 12px; }
.basket-title, .basket-title strong { color: #fff; }.basket-chip { background: #2a6625; color: #d8f3d6; border-color: #4d8d47; }
.basket-chip strong { color: #fff; }.basket-toolbar .btn { color: #e9f8e8; border-color: #76ad71; }
.basket-toolbar .btn-primary { color: #1a4516; background: #b2e7ae; border-color: #b2e7ae; }
.modal-dialog { border-radius: 16px; border-color: #daefd8; }.modal-header { background: #f2fbf1; }.modal-backdrop { background: #143a1180; }
.modal-title-group h3 { color: #1b4617; }.toast { color: #2b5f26; border-color: #daefd8; border-left: 3px solid #43c138; }
.empty-state-view { border-radius: 16px; border-color: #daefd8; box-shadow: var(--shadow-card); }
.empty-icon-ring { background: #f0faef; color: #2d8226; border-color: #d3f2d0; }.empty-state-view h2 { color: #1b4617; }
.auth-screen { background: #f4fcf3; }.auth-story { background: radial-gradient(ellipse at 90% 85%,#215f1c 0%,transparent 55%),linear-gradient(145deg,#194714,#12340f); color: #f8fdf7; }
.story-copy h1 em { color: #97df91; }.story-copy .eyebrow { color: #aae5a5; }
.story-copy p, .story-brand small, .story-footer, .story-footer span, .story-art-caption { color: #c2e7bf; }
.art-bars i { background: #6ccb632b; border-color: #86da7e66; }.art-bars i:nth-child(7) { background: #97df9177; }.art-orbit { border-color: #87ce8033; }.art-line { background: #94da8e66; }
.auth-title { color: #1b4617; }.auth-field label { color: #406f3c; }.auth-field input { color: #275d22; border-color: #cfe9cd; border-radius: 9px; }
.auth-submit::after { color: #fff; }.auth-brand .eyebrow { color: #2d8226; }
@media (max-width: 800px) { .investor-rail { background: #174313; border-bottom-color: #2e6129; } .investor-rail .tab-button { min-height: 40px; } }
@media (max-width: 580px) { .kpi-grid { gap: 9px; }.kpi-card { padding: 15px 13px; }.workspace-heading p { font-size: 12px; } }

/* ---- Phones: compact header, card-style tables, readable period cards ---- */
@media (max-width: 640px) {
  /* styles.css turns the actions into a 2-column grid of full-width buttons that fills the
     first screen; keep them on one wrapping row instead. */
  .header-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; width: 100%; }
  .header-actions .btn { width: auto; flex: 1 1 auto; min-height: 40px; justify-content: center; }
  .header-actions .user-chip { flex: 0 0 auto; }

  .period-winner-name { white-space: normal; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }

  .table-responsive:has(> .stack-mobile) { max-height: none; overflow: visible; box-shadow: none; }
  .data-table.stack-mobile { min-width: 0; }
  .data-table.stack-mobile thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .data-table.stack-mobile, .data-table.stack-mobile tbody { display: block; width: 100%; }
  .data-table.stack-mobile tbody tr { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 14px;
    padding: 12px 14px; border-bottom: 1px solid #e4efe3; }
  .data-table.stack-mobile tbody td { display: flex; justify-content: flex-end; align-items: baseline; flex-wrap: wrap; gap: 4px 8px;
    padding: 6px 0; border-bottom: 1px dashed #eef4ed; text-align: right; min-width: 0; max-width: none; }
  .data-table.stack-mobile tbody td::before { content: attr(data-label); flex: 0 0 auto; margin-right: auto; color: #5e775c; font-weight: 600; text-align: left; }
  /* Value and its delta sit together on the right instead of spreading across the row. */
  .data-table.stack-mobile tbody td > span[style*="display:block"] { display: inline !important; }
  .data-table.stack-mobile tbody td > * { min-width: 0; }
  /* Rank, fund name and category head the card across its full width. */
  .data-table.stack-mobile tbody td:nth-child(-n+3) { grid-column: 1 / -1; justify-content: flex-start; text-align: left; border-bottom: 0; }
  .data-table.stack-mobile tbody td:nth-child(-n+3)::before { display: none; }
  .data-table.stack-mobile tbody td:nth-child(2) { font-size: 13px; }
  .data-table.stack-mobile tbody td:nth-child(2) .fund-name-text { white-space: normal; }
  .data-table.stack-mobile tbody td:last-child { grid-column: 1 / -1; }
  .data-table.stack-mobile tbody td[colspan] { grid-column: 1 / -1; justify-content: center; }
  .data-table.stack-mobile tbody td[colspan]::before { display: none; }
}
@media (max-width: 380px) {
  .data-table.stack-mobile tbody tr { grid-template-columns: minmax(0, 1fr); }
}

/* ---- Search box: icon sits in its own gutter, one focus ring on the box ---- */
.search-input-box { position: relative; display: flex; align-items: center; min-height: 40px; }
.search-input-box .search-icon { position: absolute; left: 12px; width: 16px; height: 16px; color: #627860; pointer-events: none; }
.search-input-box input { width: 100%; border: 0; background: transparent; padding: 10px 36px 10px 38px; outline: none; box-shadow: none; }
.search-input-box input::-webkit-search-cancel-button { display: none; }
.search-input-box input:focus { border: 0; box-shadow: none; }
.search-input-box:focus-within { border-color: #51c947; box-shadow: 0 0 0 3px rgba(81, 201, 71, .14); }
.search-input-box .clear-btn { position: absolute; right: 6px; width: 28px; height: 28px; align-items: center; justify-content: center; border-radius: 50%; color: #5e775c; }
.search-input-box .clear-btn:hover { background: #eff7ee; color: #284d25; }

/* ---- Tables: the page scrolls (no box-in-a-box), key columns stay pinned ---- */
.table-responsive { max-height: none; }
.data-table { min-width: 0; }
.data-table tbody td { padding: 10px 11px; }
.data-table thead th { padding: 11px; }
.data-table .fund-name-cell { min-width: 210px; max-width: 280px; }
.data-table .fund-name-text { white-space: normal; }
:where(.data-table) tbody tr { background: #fff; }

#funds-table th:nth-child(-n+3), #funds-table td:nth-child(-n+3),
.data-table.stack-mobile th:nth-child(-n+2), .data-table.stack-mobile td:nth-child(-n+2) {
  position: sticky; z-index: 1; background: inherit; }
#funds-table thead th:nth-child(-n+3), .data-table.stack-mobile thead th:nth-child(-n+2) { z-index: 3; background: #f0f8ef; }
#funds-table th:nth-child(1), #funds-table td:nth-child(1) { left: 0; width: 40px; min-width: 40px; max-width: 40px; }
#funds-table th:nth-child(2), #funds-table td:nth-child(2) { left: 40px; width: 58px; min-width: 58px; max-width: 58px; }
#funds-table th:nth-child(3), #funds-table td:nth-child(3) { left: 98px; box-shadow: inset -1px 0 #dcebdb; }
.data-table.stack-mobile th:nth-child(1), .data-table.stack-mobile td:nth-child(1) { left: 0; width: 58px; min-width: 58px; max-width: 58px; }
.data-table.stack-mobile th:nth-child(2), .data-table.stack-mobile td:nth-child(2) { left: 58px; box-shadow: inset -1px 0 #dcebdb; }

/* ---- Shared pager ---- */
.table-pager { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 16px; padding: 12px 16px; border-top: 1px solid #e4efe3; font-size: 12px; color: #587a55; }
.table-pager .pager-summary { margin-right: auto; }
.table-pager .pager-size { display: inline-flex; align-items: center; gap: 6px; }
.table-pager .pager-size select { height: 32px; min-width: 70px; }
.table-pager .pager-nav { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 4px; }
.table-pager .pager-gap { padding: 0 4px; color: #647763; }
.table-pager .page-num-btn, .table-pager .btn-page-nav { min-width: 34px; height: 34px; }

@media (max-width: 640px) {
  .data-table .fund-name-cell { min-width: 150px; max-width: 170px; }
  /* Card-style tables don't scroll sideways, so nothing needs pinning there. */
  .data-table.stack-mobile th, .data-table.stack-mobile td { position: static !important; box-shadow: none !important; width: auto !important; max-width: none !important; min-width: 0 !important; }
  .table-pager { padding: 12px; }
  .table-pager .pager-summary { width: 100%; }
  .table-pager .pager-nav { width: 100%; justify-content: space-between; }
  .table-pager .page-num-btn, .table-pager .btn-page-nav { min-width: 40px; height: 40px; }
}
#funds-table tbody tr:hover td, .data-table.stack-mobile tbody tr:hover td { background: #f0faef; }
/* Explorer row tints are translucent (and below-avg rows use opacity), which lets scrolled
   cells show through the pinned columns. Pinned cells get a solid base with the tint on top. */
#funds-table tbody td:nth-child(-n+3) { background-color: #fff; background-image: linear-gradient(var(--pin-tint, transparent), var(--pin-tint, transparent)); }
#funds-table tbody tr.row-above-avg { --pin-tint: rgba(22, 163, 74, .03); }
#funds-table tbody tr.row-selected { --pin-tint: #f3fbf3; }
#funds-table tbody tr.row-below-avg { opacity: 1; color: #607f5d; }
#funds-table tbody tr:hover td:nth-child(-n+3) { background-color: #f0faef; }
@media (max-width: 640px) {
  /* Touch "hover" sticks after a tap and paints the card cells unevenly. */
  .data-table.stack-mobile tbody tr:hover td { background: transparent; }
  /* Pin only select + name on phones so a data column still fits beside them. */
  #funds-table th:nth-child(2), #funds-table td:nth-child(2) { position: static; }
  #funds-table th:nth-child(3), #funds-table td:nth-child(3) { left: 40px; min-width: 140px; max-width: 150px; }
}

/* ---- Data Inspector: column mapping ---- */
.schema-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.schema-file-row, .schema-actions, .schema-empty { grid-column: 1 / -1; }
.schema-file-row { display: flex; flex-direction: column; gap: 4px; padding: 12px 14px; background: #f7fcf7; border: 1px solid #e1efe0; border-radius: 8px; font-size: 12px; color: #42663f; }
.schema-hint { color: #5a7758; font-size: 11.5px; }
.schema-field { display: flex; flex-direction: column; gap: 7px; }
.schema-field label { font-weight: 600; display: flex; align-items: center; gap: 6px; }
.schema-req { font-size: 10px; font-weight: 600; color: #9a4a12; background: #fff4e5; border-radius: 4px; padding: 1px 6px; }
.schema-select { width: 100%; min-height: 40px; background-color: #fff; cursor: pointer; }
.schema-select.is-changed { border-color: #51c947; box-shadow: 0 0 0 2px rgba(81, 201, 71, .12); }
.schema-select.is-invalid { border-color: #c2410c; box-shadow: 0 0 0 2px rgba(194, 65, 12, .14); }
.schema-count { font-size: 11px; color: #5e775c; }
.schema-actions { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 10px; padding-top: 4px; }
.schema-status { margin-right: auto; font-size: 12px; color: #4e724b; }
.schema-status.is-error { color: #b42318; font-weight: 600; }
.schema-empty { color: #5f7e5c; font-size: 12px; margin: 0; }
@media (max-width: 640px) {
  .schema-actions .btn { flex: 1 1 auto; min-height: 42px; }
  .schema-status { width: 100%; }
}

/* ---- New-category notice & category registry ---- */
.category-notice { display: flex; gap: 12px; align-items: flex-start; }
.category-notice[hidden] { display: none; }
.category-notice .match-report-body { flex: 1; }
.category-notice .match-report-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.category-notice li { margin: 3px 0; }
.cat-code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 11px; color: #597a56; background: #eff7ee; border-radius: 4px; padding: 1px 6px; }
.cat-funds { display: block; color: #5a7758; font-size: 11px; }
.cat-file { display: block; color: #627860; font-size: 10.5px; }
.cat-table .cat-label-input { min-width: 220px; height: 36px; background: #fff; }
.cat-table th, .cat-table td { position: static !important; width: auto !important; max-width: none !important; min-width: 0; box-shadow: none !important; }
.cat-badge { display: inline-block; font-size: 10.5px; font-weight: 600; border-radius: 10px; padding: 2px 8px; margin: 1px 2px 1px 0; white-space: nowrap; }
.cat-new { background: #e4f7e2; color: #2c8025; }
.cat-auto { background: #f2f9f1; color: #4a6947; }
.cat-warn { background: #fff4e5; color: #9a4a12; }
.cat-help { font-size: 11.5px; color: #5a7758; margin: 10px 0 0; }
@media (max-width: 640px) {
  .category-notice { flex-direction: column; }
  .cat-table .cat-label-input { min-width: 0; width: 100%; }
}

/* ---- Imported-data bar: collapsible file list ---- */
.btn-collapse-import { background: transparent; border: 0; padding: 4px 6px; font-size: 11.5px; font-weight: 600; color: #337f2d; cursor: pointer; white-space: nowrap; border-radius: 4px; }
.btn-collapse-import:hover { background: rgba(81, 201, 71, .08); }
.excel-verification-banner.is-collapsed { padding-block: 8px; }
.excel-verification-banner.is-collapsed .verify-details { flex: 0 1 auto; }

/* ---- "Hide notices": every notice banner stays out of sight ---- */
body.notices-hidden #match-report-notice,
body.notices-hidden #category-notice,
body.notices-hidden #rolling-coverage-notice,
body.notices-hidden .rolling-banner-card { display: none !important; }
#btn-toggle-notices[aria-pressed="true"] { color: #92400e; }
.section-heading-row .coverage-line { display: block; color: #9a4a12; font-weight: 600; }
.section-heading-row .coverage-line[hidden] { display: none; }

/* Light green and gold: fresh surfaces, forest text and warm accents. */
:root {
 --bg-main: #f5f8ef; --bg-card: #fffefb; --bg-surface: #edf4e4; --bg-surface-light: #e2edd7;
 --text-primary: #263e2c; --text-secondary: #455e45; --text-muted: #566852; --text-dim: #606b53;
 --primary: #35633b; --primary-hover: #274c2d; --border-highlight: #8b7225;
 --border-card: #dce6d2; --border-subtle: #e9efdf;
 --blue: #35633b; --blue-bg: #edf5e4;
 --emerald: #32683c; --emerald-bg: #e9f4e2; --emerald-border: #caddbf;
 --amber: #856019; --amber-bg: #fff5d9; --amber-border: #e8d39a;
 --accent-gradient: linear-gradient(120deg,#35633b,#a18430);
}
body, .auth-screen { background: #f5f8ef; }
.investor-rail { background: linear-gradient(165deg,#f0f7e8,#e3eed7); border-color: #cddcbd; }
.rail-brand, .rail-brand > span:last-child, .rail-note, .rail-note strong { color: #29452d; }
.rail-label, .rail-brand small, .rail-note p, .rail-note > span:last-child, .rail-footer { color: #52664a; }
.rail-note-icon { color: #856019; }.rail-note-line { background: #c8d6b8; }.rail-dot { background: #658641; }
.investor-rail .tab-button { color: #425a3d; }
.investor-rail .tab-button:hover:not(:disabled) { background: #dcebcf; color: #28452b; }
.investor-rail .tab-button.active, .investor-rail .tab-button[data-tab="tab-best-funds"].active { background: #f4e7b6; border-color: #ddc679; color: #584613; box-shadow: 0 3px 10px #78601b10; }
.investor-rail .tab-button .tab-pill, .investor-rail .tab-button:not(.active) .tab-pill, .investor-rail .tab-button[data-tab="tab-best-funds"] .tab-pill { background: #dbe8cf; color: #425a3d; }
.investor-rail .tab-button.active .tab-pill, .investor-rail .tab-button[data-tab="tab-best-funds"].active .tab-pill { background: #fff9e6; color: #705617; }
.workspace-heading h1, .brand-title, .auth-title { color: #263e2c; }
.workspace-heading .eyebrow, .auth-brand .eyebrow { color: #7d611b; }
.workspace-edition { border-left-color: #b9983c; }
.btn-primary, .btn-add-rolling-inline, .auth-submit { background: #e7ce80; border-color: #c5a34d; color: #493b16; box-shadow: 0 3px 8px #86641814; font-weight: 650; }
.btn-primary:hover, .btn-add-rolling-inline:hover, .auth-submit:hover { background: #d8b958; border-color: #af8e32; color: #372d13; }
.auth-submit::after { color: #493b16; }
.btn-secondary, .btn-outline { border-color: #ccdabc; color: #425b3c; }
.btn-secondary:hover, .btn-outline:hover { background: #eaf3df; color: #2e5232; border-color: #9eb689; }
.user-avatar { background: #e8efd9; color: #476038; }
.kpi-card:first-child { background: #edf6e4; border-color: #cddfbc; }
.kpi-main-val, .kpi-main-val.val-blue, .kpi-main-val.val-emerald { color: #35633b; }
.kpi-main-val.val-gold, .kpi-main-val.val-amber { color: #856019; }
.criteria-summary-card { background: #fff5d9; border-color: #e8d39a; }.shortlist-number { color: #856019; }
.champion-showcase-card { background: linear-gradient(120deg,#e4f0d8,#f0f6e6 60%,#fcf1cf); border-color: #c9dcb6; box-shadow: 0 8px 25px #43592c0b; }
.champion-fund-title { color: #29482e; }
.champion-crown-tag { color: #705617; }.champion-crown-tag::before { color: #705617; border-color: #c7aa58; }
.champion-periods-won-badge { background: #f7e9b7; color: #664f17; border-color: #dfc781; }
.champ-meta-pill, .champ-stat-label { color: #506548; }
.champ-meta-pill strong, .champ-stat-box > span:last-child { color: #415e3c !important; }
.champ-stat-val, .champ-stat-val.green { color: #2e5935; }.champ-stat-val.gold { color: #856019; }
.champion-metrics-grid, .champ-stat-box { border-color: #bacfac; }
.champion-main-info .btn-primary { background: #35633b; color: #fff; border-color: #35633b; }
.champion-main-info .btn-primary:hover { background: #274c2d; color: #fff; border-color: #274c2d; }
.period-horizon-badge { background: #fff4d3; color: #7a5c19; }.period-winner-ret { color: #35633b; }
.data-table thead th { background: #eef4e7; color: #425a3d; }
.data-table tbody tr[style]:first-child { background: #f6f0d9 !important; }
.basket-toolbar { background: #304f34; border-color: #476a40; }
.basket-toolbar .btn-primary { background: #e7ce80; color: #493b16; border-color: #c5a34d; }
.auth-story { background: radial-gradient(ellipse at 90% 85%,#61733d 0%,transparent 55%),linear-gradient(145deg,#23452c,#183720); }
.story-copy h1 em { color: #e7ce80; }.story-copy .eyebrow { color: #d4e9bd; }
.story-copy p, .story-brand small, .story-footer, .story-footer span, .story-art-caption { color: #d3e2c4; }
.art-bars i { background: #c6dd902b; border-color: #d0df9966; }.art-bars i:nth-child(7) { background: #e7ce8077; }
@media (max-width: 800px) { .investor-rail { background: #e8f1dc; border-bottom-color: #cddcbd; } }

.excel-verification-banner { background: #edf5e5; border-color: #d2e2bf; }
