/* =========================================================
   GRANTS — USF design system (tokens from the 2026-09-29 reference) + app components (gr- prefix)
   ========================================================= */
:root {
    /* UI spec 2026-09-29 (shared by the Overview and the table pages) */
    --usf-green: #00543C; --usf-green-dark: #00543C; --usf-green-hover: #00412F; --usf-green-light: #EAF7F1;
    --blue: #2563EB; --blue-light: #EFF6FF; --success: #16A34A; --success-light: #ECFDF5; --warning: #F59E0B; --warning-light: #FFFBEB;
    --danger: #DC2626; --danger-light: #FEF2F2; --purple: #7C3AED; --purple-light: #F5F3FF;
    --page-bg: #F8FAF9; --background: #F8FAF9; --surface: #FFFFFF; --surface-soft: #F8FAFC;
    --text-primary: #111827; --text-secondary: #64748B; --text-muted: #94A3B8;
    --border: #E2E8F0; --border-light: #EEF2F4; --control-border: #CBD5E1;
    --success-bg: #ECFDF5; --info: #2563EB; --info-bg: #EFF6FF; --purple-bg: #F5F3FF; --warning-bg: #FFFBEB; --danger-bg: #FEF2F2; --gold: #CFC493;
    --radius-sm: 7px; --radius-md: 10px; --radius-lg: 12px;
    --shadow-card: 0 1px 3px rgba(15, 23, 42, .04); --shadow-hover: 0 4px 12px rgba(15, 23, 42, .06); --shadow-pop: 0 8px 24px rgba(15, 23, 42, .10);
    --content-width: 1440px;
}
* { box-sizing: border-box; }
body.gr-body { margin: 0; background: var(--page-bg); color: var(--text-primary); font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif; font-size: 14px; line-height: 1.45; }
a { color: var(--usf-green); }
.grants-container { width: calc(100% - 48px); max-width: var(--content-width); margin: 0 auto; }

/* ---------- top navigation ---------- */
.grants-topnav { height: 60px; background: var(--usf-green-dark); color: #fff; padding: 0 28px; border-bottom: 1px solid rgba(255,255,255,.08); position: sticky; top: 0; z-index: 1030; }
.grants-topnav-inner { max-width: var(--content-width); height: 100%; margin: 0 auto; display: flex; align-items: center; gap: 20px; }
.grants-brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; margin-right: 16px; flex-shrink: 0; }
.grants-brand:hover { color: #fff; }
.grants-brand img { height: 34px; width: auto; }
.grants-brand-name { font-size: 24px; font-weight: 800; line-height: 1; letter-spacing: -.02em; }
.grants-brand-college { font-size: 13px; opacity: .9; }
.grants-nav { display: flex; align-items: center; gap: 22px; height: 100%; }
.grants-nav a { position: relative; color: #DDEFE8; text-decoration: none; font-size: 14px; font-weight: 500; height: 60px; display: flex; align-items: center; gap: 7px; transition: color .15s ease; white-space: nowrap; }
.grants-nav a .bi { font-size: 15px; }
.grants-nav a:hover, .grants-nav a.active { color: #fff; }
.grants-nav a.active { font-weight: 600; }
.grants-nav a.active::after { content: ""; position: absolute; left: -6px; right: -6px; bottom: 0; height: 2px; background: #fff; }
.grants-search { margin-left: auto; position: relative; width: 260px; }
.grants-search input { width: 100%; height: 36px; border-radius: var(--radius-sm); border: 1px solid rgba(255,255,255,.14); background: rgba(255,255,255,.1); color: #fff; padding: 0 12px 0 34px; font-size: 12.5px; outline: none; }
.grants-search input::placeholder { color: rgba(255,255,255,.7); }
.grants-search input:focus { background: rgba(255,255,255,.16); border-color: rgba(255,255,255,.35); }
.grants-search .bi { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: rgba(255,255,255,.75); font-size: 13px; }
.grants-user { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; background: none; border: 0; padding: 0; }
.grants-user-av { width: 34px; height: 34px; border-radius: 50%; background: #3BA77E; color: #fff; font-weight: 700; font-size: 13px; display: flex; align-items: center; justify-content: center; }
.grants-user-name { font-size: 12.5px; font-weight: 600; line-height: 1.1; text-align: left; }
.grants-user-role { font-size: 11px; opacity: .75; }
.grants-user::after { margin-left: 4px; }

/* ---------- page header + filters ---------- */
.grants-page-header { padding: 26px 0 18px; display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.grants-page-title { margin: 0; font-size: 30px; line-height: 1.15; font-weight: 700; letter-spacing: -.02em; }
.grants-page-subtitle { margin-top: 5px; font-size: 14px; color: var(--text-secondary); }
.grants-filter-bar { display: grid; grid-template-columns: repeat(4, minmax(150px, 1fr)) auto auto; gap: 12px; align-items: end; padding: 14px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md); }
.filter-label { display: block; margin-bottom: 5px; font-size: 11px; font-weight: 600; color: #344054; }
.filter-select { width: 100%; height: 40px; padding: 0 11px; background: #fff; border: 1px solid #D0D5DD; border-radius: var(--radius-sm); color: var(--text-primary); font-size: 13px; outline: none; }
.filter-select:focus { border-color: var(--usf-green); box-shadow: 0 0 0 3px rgba(0,103,71,.10); }
.btn-primary-gr { height: 40px; padding: 0 18px; border: 0; border-radius: var(--radius-sm); background: var(--usf-green); color: #fff; font-size: 13px; font-weight: 600; cursor: pointer; transition: background .15s ease, box-shadow .15s ease; white-space: nowrap; }
.btn-primary-gr:hover { background: var(--usf-green-hover); box-shadow: var(--shadow-hover); color: #fff; }
.btn-link-gr { border: 0; background: transparent; color: var(--usf-green); font-size: 12px; font-weight: 600; cursor: pointer; height: 40px; padding: 0 8px; text-decoration: none; display: inline-flex; align-items: center; }

/* ---------- KPI grid ---------- */
.kpi-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; }
.kpi-card { min-height: 108px; padding: 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md); box-shadow: var(--shadow-card); display: flex; gap: 14px; align-items: flex-start; }
.kpi-card.t-green { background: linear-gradient(135deg, #EEF6FF 0%, #fff 70%); }
.kpi-icon { width: 44px; height: 44px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; border-radius: 9px; font-size: 20px; }
.kpi-label { font-size: 13px; font-weight: 600; color: var(--text-primary); }
.kpi-value { margin-top: 4px; font-size: 28px; line-height: 1.15; font-weight: 700; letter-spacing: -.02em; }
.kpi-meta { margin-top: 3px; font-size: 12px; color: var(--text-muted); }
.k-blue .kpi-icon { background: var(--info-bg); color: var(--info); }   .k-blue { background: linear-gradient(135deg, #F3F8FF, #fff 75%); }
.k-green .kpi-icon { background: var(--success-bg); color: var(--success); } .k-green { background: linear-gradient(135deg, #F1FAF5, #fff 75%); }
.k-gold .kpi-icon { background: #FBF3DB; color: #8A6A12; } .k-gold { background: linear-gradient(135deg, #FFFBEF, #fff 75%); }
.k-sky .kpi-icon { background: #E6F0FB; color: #1D5FB4; } .k-sky { background: linear-gradient(135deg, #F2F7FD, #fff 75%); }
.k-purple .kpi-icon { background: var(--purple-bg); color: var(--purple); } .k-purple { background: linear-gradient(135deg, #F8F4FF, #fff 75%); }

/* ---------- sections ---------- */
.dashboard-section { margin-top: 20px; padding: 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md); box-shadow: var(--shadow-card); }
.section-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.section-head-left { display: flex; align-items: center; gap: 12px; }
.section-icon { width: 40px; height: 40px; border-radius: 9px; background: var(--success-bg); color: var(--usf-green); display: flex; align-items: center; justify-content: center; font-size: 19px; flex-shrink: 0; }
.section-title { margin: 0; font-size: 17px; font-weight: 700; }
.section-subtitle { margin-top: 2px; font-size: 12px; color: var(--text-secondary); }
.section-tools { display: flex; align-items: center; gap: 10px; }
.section-tools .filter-select { height: 36px; width: 190px; }
.seg { display: inline-flex; border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.seg button { height: 36px; border: 0; background: #fff; padding: 0 14px; font-size: 13px; font-weight: 600; color: var(--text-secondary); display: inline-flex; align-items: center; gap: 6px; }
.seg button.on { background: var(--usf-green); color: #fff; }

/* ---------- fiscal year cards ---------- */
.fiscal-year-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
.fiscal-year-card { display: block; min-height: 112px; padding: 13px; background: #fff; border: 1px solid var(--border); border-radius: 9px; color: inherit; text-decoration: none; transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease; }
.fiscal-year-card:hover { transform: translateY(-1px); border-color: #CBD8D3; box-shadow: var(--shadow-hover); color: inherit; }
.fiscal-year-card.is-selected { border-color: var(--usf-green); box-shadow: 0 0 0 2px rgba(0,103,71,.18); }
.fiscal-year-header { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.fiscal-year { font-size: 16px; font-weight: 700; }
.fiscal-year-header .bi { margin-left: auto; color: var(--text-muted); font-size: 13px; }
.year-status { padding: 3px 7px; border-radius: 999px; font-size: 9px; font-weight: 700; line-height: 1; letter-spacing: .03em; text-transform: uppercase; }
.year-status.complete { background: var(--success-bg); color: var(--success); }
.year-status.progress { background: var(--info-bg); color: var(--info); }
.year-status.pending { background: var(--warning-bg); color: var(--warning); }
.fiscal-year-metrics { display: grid; grid-template-columns: 1fr 1fr 1.15fr; }
.year-metric { padding-right: 8px; }
.year-metric + .year-metric { padding-left: 8px; border-left: 1px solid var(--border-light); }
.year-metric-value { font-size: 17px; font-weight: 700; font-variant-numeric: tabular-nums; }
.year-metric-label { margin-top: 1px; font-size: 10.5px; color: var(--text-muted); }
.year-progress { display: flex; align-items: center; gap: 8px; margin-top: 12px; }
.year-progress-track { flex: 1; height: 7px; background: #E8EEEC; border-radius: 999px; overflow: hidden; }
.year-progress-fill { height: 100%; background: var(--usf-green); border-radius: inherit; }
.year-success { flex-shrink: 0; font-size: 10.5px; font-weight: 600; color: var(--text-secondary); }
.year-inter { margin-top: 6px; font-size: 10.5px; color: var(--purple); font-weight: 600; }
.fy-chart-wrap { position: relative; height: 320px; }

/* ---------- analytics cards ---------- */
.analytics-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-top: 14px; }
.analytics-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 16px; box-shadow: var(--shadow-card); min-width: 0; }
.analytics-card .section-header { margin-bottom: 10px; }
.analytics-card .view-all { font-size: 12px; font-weight: 600; text-decoration: underline; }
.a-table { width: 100%; font-size: 12.5px; border-collapse: collapse; }
.a-table th { font-size: 11px; font-weight: 600; color: var(--text-primary); padding: 6px 4px; border-bottom: 1px solid var(--border); white-space: nowrap; }
.a-table td { padding: 6px 4px; border-bottom: 1px solid var(--border-light); vertical-align: middle; }
.a-table tr:last-child td { border-bottom: 0; }
.a-table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.a-bar { height: 12px; background: #EEF2F0; border-radius: 3px; overflow: hidden; min-width: 70px; }
.a-bar i { display: block; height: 100%; background: var(--usf-green); border-radius: 3px; }
.a-type { font-size: 11px; color: var(--text-muted); }
.a-dot { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 6px; vertical-align: 0; }
.av { width: 26px; height: 26px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 10.5px; font-weight: 700; color: #fff; margin-right: 8px; flex-shrink: 0; object-fit: cover; vertical-align: middle; }
.a-person { display: flex; align-items: center; min-width: 0; }
.a-person a { color: var(--text-primary); text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.a-person a:hover { color: var(--usf-green); text-decoration: underline; }

/* ---------- other tabs (list pages) ---------- */
.gr-main { padding-bottom: 40px; }
.gr-footer { text-align: center; color: var(--text-muted); font-size: 12px; padding: 20px; }
.gr-page-head { display: flex; align-items: flex-end; gap: 16px; flex-wrap: wrap; padding: 26px 0 16px; }
.gr-page-head h1 { font-size: 28px; font-weight: 700; margin: 0; letter-spacing: -.02em; }
.gr-page-head .gr-sub { color: var(--text-secondary); font-size: 13.5px; margin-top: 4px; max-width: 900px; }
.gr-page-head .gr-actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }
.gr-subtabs { display: flex; gap: 6px; margin: -4px 0 14px; flex-wrap: wrap; }
.gr-subtabs a { padding: 6px 14px; border-radius: 999px; border: 1px solid var(--border); background: #fff; color: var(--text-secondary); font-size: 13px; font-weight: 600; text-decoration: none; }
.gr-subtabs a.active { background: var(--usf-green); border-color: var(--usf-green); color: #fff; }
.gr-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md); box-shadow: var(--shadow-card); margin-bottom: 18px; }
.gr-card-head { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.gr-card-head h2 { font-size: 16px; font-weight: 700; margin: 0; }
.gr-card-head .gr-sub { color: var(--text-secondary); font-size: 12.5px; }
.gr-card-body { padding: 16px 18px; }
.gr-filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: end; margin-bottom: 12px; }
.gr-filters label { font-size: 11px; font-weight: 600; color: #344054; display: block; margin-bottom: 4px; }
.gr-filters .form-select, .gr-filters .form-control { font-size: 13px; min-width: 150px; border-color: #D0D5DD; border-radius: var(--radius-sm); }
table.gr-table { font-size: 13px; }
table.gr-table thead th { font-size: 11px; font-weight: 600; color: #344054; background: var(--surface-soft); white-space: nowrap; border-bottom-color: var(--border); }
table.gr-table td { vertical-align: top; border-color: var(--border-light); }
table.gr-table td.num, table.gr-table th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
#grTable td:first-child { white-space: nowrap; }
.gr-title-link { color: var(--text-primary); font-weight: 600; text-decoration: none; cursor: pointer; }
.gr-title-link:hover { color: var(--usf-green); text-decoration: underline; }
.gr-muted { color: var(--text-secondary); } .gr-small { font-size: 12px; }
.gr-tag { display: inline-flex; align-items: center; gap: 4px; font-size: 10px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; border-radius: 999px; padding: 3px 8px; border: 1px solid transparent; background: #F2F4F3; color: var(--text-secondary); white-space: nowrap; }
.gr-tag-awarded { background: var(--success-bg); color: var(--success); }
.gr-tag-not_awarded { background: var(--danger-bg); color: var(--danger); }
.gr-tag-pending { background: #F2F4F3; color: var(--text-secondary); }
.gr-tag-inter { background: var(--purple-bg); color: var(--purple); }
.gr-tag-copi { background: var(--info-bg); color: var(--info); }
.gr-tag-user { background: var(--success-bg); color: var(--usf-green); }
.gr-people-cell { font-size: 12.5px; line-height: 1.45; }
.gr-editonly { display: none !important; }
body.gr-can-edit .gr-editonly { display: inline-flex !important; }
.gr-btn-icon { border: 1px solid var(--border); background: #fff; border-radius: 6px; padding: 2px 7px; color: var(--text-secondary); font-size: 13px; }
.gr-btn-icon:hover { color: var(--usf-green); border-color: var(--usf-green); }
.gr-btn-icon.danger:hover { color: var(--danger); border-color: var(--danger); }
.btn-gr { background: var(--usf-green); border-color: var(--usf-green); color: #fff; font-weight: 600; border-radius: var(--radius-sm); }
.btn-gr:hover { background: var(--usf-green-hover); border-color: var(--usf-green-hover); color: #fff; }
.gr-review-row { display: grid; grid-template-columns: 1fr auto 1fr auto; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--border-light); }
.gr-review-row:last-child { border-bottom: 0; }
.gr-review-side { background: var(--surface-soft); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 8px 12px; }
.gr-review-side b { display: block; }
.gr-review-actions { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.gr-detail dt { font-size: 11px; font-weight: 600; color: #344054; margin-top: 8px; }
.gr-detail dd { margin: 0; }
.gr-raw { font-size: 12px; background: var(--surface-soft); border: 1px solid var(--border); border-radius: 8px; padding: 8px 10px; }
.gr-person-row { display: grid; grid-template-columns: 1fr 190px 170px 34px; gap: 8px; margin-bottom: 6px; align-items: center; }
.gr-search-group { margin-bottom: 18px; }
.select2-container { width: 100% !important; }
.select2-container .select2-selection--single { height: 34px; border-color: #D0D5DD; }
.select2-container .select2-selection--single .select2-selection__rendered { line-height: 32px; font-size: 13.5px; }
.select2-dropdown { font-size: 13.5px; }
.modal .select2-container { z-index: 1060; }
.dt-buttons .btn, .dt-buttons .btn-secondary { background: #fff !important; color: var(--text-primary) !important; border: 1px solid #D0D5DD !important; font-size: 12.5px; }
.dt-buttons .btn:hover { border-color: var(--usf-green) !important; color: var(--usf-green) !important; }
.page-item.active .page-link { background: var(--usf-green); border-color: var(--usf-green); }
.page-link { color: var(--usf-green); }

/* ---------- responsive ---------- */
@media (max-width: 1320px) { .grants-search { width: 190px; } .grants-nav { gap: 16px; } .grants-user-text { display: none; } }
@media (max-width: 1200px) { .fiscal-year-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } .kpi-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } .grants-brand-college { display: none; } }
@media (max-width: 992px) {
    .fiscal-year-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } .analytics-grid { grid-template-columns: 1fr 1fr; } .grants-filter-bar { grid-template-columns: repeat(2, 1fr); }
    .grants-topnav { height: auto; padding: 8px 14px; } .grants-topnav-inner { flex-wrap: wrap; gap: 8px 14px; } .grants-nav { order: 3; width: 100%; overflow-x: auto; height: 40px; } .grants-nav a { height: 40px; } .grants-search { width: 100%; order: 4; margin-left: 0; }
}
@media (max-width: 700px) {
    .grants-container { width: calc(100% - 28px); } .fiscal-year-grid, .kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .analytics-grid { grid-template-columns: 1fr; }
    .grants-page-header { align-items: flex-start; flex-direction: column; } .grants-filter-bar { grid-template-columns: 1fr; }
    .gr-person-row, .gr-review-row { grid-template-columns: 1fr; } .section-tools { flex-wrap: wrap; }
}
@media (max-width: 480px) { .fiscal-year-grid, .kpi-grid { grid-template-columns: 1fr; } .grants-page-title { font-size: 25px; } }

/* =========================================================
   TABLE PAGES — External proposals / Internal awards / Pre-proposals / Awards (UI spec 2026-09-29)
   ========================================================= */
.grants-topnav { background: var(--usf-green); }
.grants-nav a:hover { color: #fff; background: transparent; }
.grants-container { padding-left: 0; padding-right: 0; }
@media (min-width: 1700px) { .grants-container { max-width: 1440px; } }
.gp-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; padding: 28px 0 16px; }
.gp-title { font-size: 32px; font-weight: 700; color: var(--text-primary); margin: 0; letter-spacing: -.02em; line-height: 1.15; }
.gp-subtitle { font-size: 14px; color: var(--text-secondary); margin: 4px 0 0; max-width: 860px; }
.gp-btn-primary { height: 40px; padding: 0 16px; border: 0; border-radius: 8px; background: var(--usf-green); color: #fff; font-size: 14px; font-weight: 600; display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; transition: all .15s ease; cursor: pointer; }
.gp-btn-primary:hover { background: var(--usf-green-hover); color: #fff; }
.gp-btn-primary:focus-visible, .gp-btn-secondary:focus-visible, .gp-icon-btn:focus-visible, .gp-tabs a:focus-visible, .gp-link:focus-visible { outline: 2px solid var(--usf-green); outline-offset: 2px; }
.gp-btn-secondary { height: 36px; padding: 0 12px; border: 1px solid var(--border); border-radius: 7px; background: #fff; color: var(--text-primary); font-size: 13px; font-weight: 500; display: inline-flex; align-items: center; gap: 7px; transition: all .15s ease; }
.gp-btn-secondary:hover { background: var(--surface-soft); border-color: var(--control-border); }
.gp-btn-secondary .bi-file-earmark-excel { color: #16A34A; }
.gp-btn-link { height: 40px; border: 0; background: transparent; color: var(--usf-green); font-size: 13px; font-weight: 600; padding: 0 10px; }
.gp-btn-link:hover { text-decoration: underline; }
.gp-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin: 4px 0 16px; }
.gp-tabs a { height: 36px; padding: 0 16px; border-radius: 18px; border: 1px solid var(--border); background: #fff; color: var(--text-secondary); font-size: 13px; font-weight: 600; display: inline-flex; align-items: center; text-decoration: none; transition: all .15s ease; }
.gp-tabs a:hover { color: var(--usf-green); border-color: var(--control-border); }
.gp-tabs a.active { background: var(--usf-green); border-color: var(--usf-green); color: #fff; }
.gp-filters { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px 14px; background: #fff; border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 16px; box-shadow: var(--shadow-card); }
.gp-f { flex: 1 1 150px; min-width: 140px; max-width: 200px; }
.gp-f-wide { max-width: 260px; flex-basis: 220px; }
.gp-f-search { max-width: 300px; flex-basis: 250px; }
.gp-f label { display: block; font-size: 12px; font-weight: 600; color: #475569; margin-bottom: 5px; }
.gp-control { width: 100%; height: 40px; border: 1px solid var(--control-border); border-radius: 7px; background: #fff; color: var(--text-primary); font-size: 14px; padding: 0 10px; outline: none; transition: border-color .15s ease, box-shadow .15s ease; }
.gp-control:focus { border-color: var(--usf-green); box-shadow: 0 0 0 3px rgba(0,84,60,.10); }
select.gp-control { appearance: auto; }
.gp-search { position: relative; }
.gp-search .bi { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--text-muted); font-size: 14px; }
.gp-search .gp-control { padding-left: 32px; }
.gp-f-actions { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.gp-kpis { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; margin: 16px 0; }
.gp-kpi { display: flex; align-items: center; gap: 12px; min-height: 90px; padding: 16px; background: #fff; border: 1px solid var(--border); border-radius: var(--radius-md); box-shadow: var(--shadow-card); }
.gp-kpi-icon { width: 44px; height: 44px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 21px; flex-shrink: 0; }
.gp-kpi-label { font-size: 13px; font-weight: 500; color: var(--text-secondary); }
.gp-kpi-value { font-size: 26px; font-weight: 700; color: var(--text-primary); line-height: 1.15; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.gp-kpi-sub { font-size: 12px; color: var(--text-secondary); }
.c-blue { background: linear-gradient(135deg, var(--blue-light), #fff 70%); } .c-blue .gp-kpi-icon { background: #DBEAFE; color: var(--blue); }
.c-mint { background: linear-gradient(135deg, #EEFBF6, #fff 70%); } .c-mint .gp-kpi-icon { background: #D5F5E8; color: #0F766E; }
.c-green { background: linear-gradient(135deg, var(--success-light), #fff 70%); } .c-green .gp-kpi-icon { background: #D1FAE5; color: var(--success); }
.c-red { background: linear-gradient(135deg, var(--danger-light), #fff 70%); } .c-red .gp-kpi-icon { background: #FEE2E2; color: var(--danger); }
.c-purple { background: linear-gradient(135deg, var(--purple-light), #fff 70%); } .c-purple .gp-kpi-icon { background: #EDE9FE; color: var(--purple); }
.c-sky { background: linear-gradient(135deg, #F0F7FF, #fff 70%); } .c-sky .gp-kpi-icon { background: #E0EDFF; color: #1D4ED8; }
.gp-table-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow-card); overflow: hidden; margin-bottom: 24px; }
.gp-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 14px 16px; border-bottom: 1px solid var(--border); }
.gp-count { font-size: 14px; color: var(--text-secondary); } .gp-count b { color: var(--text-primary); font-weight: 600; } .gp-dot { margin: 0 4px; }
.gp-tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.gp-sort-label { font-size: 13px; color: var(--text-secondary); margin-left: 4px; }
.gp-sort { width: 220px; height: 36px; font-size: 13px; }
.gp-colmenu { box-shadow: var(--shadow-pop); border-color: var(--border); padding: 6px; }
.gp-colmenu .dropdown-item { font-size: 13px; border-radius: 6px; cursor: pointer; }
.gp-scroll { overflow-x: auto; }
table.gp-table { border-collapse: collapse; min-width: 1200px; font-size: 14px; color: var(--text-primary); }
table.gp-table.dataTable { margin: 0 !important; }
table.gp-table thead th { background: var(--surface-soft); height: 44px; padding: 10px 12px; font-size: 12.5px; font-weight: 600; color: #475569; border-bottom: 1px solid var(--border) !important; white-space: nowrap; }
table.gp-table thead th.sorting_asc, table.gp-table thead th.sorting_desc { color: var(--text-primary); }
table.gp-table tbody td { padding: 12px; border-bottom: 1px solid var(--border-light); vertical-align: middle; background: #fff; transition: background-color .15s ease; }
table.gp-table tbody tr:hover td { background: var(--surface-soft); }
table.gp-table tbody tr:last-child td { border-bottom: 0; }
table.gp-table .num { text-align: right; }
table.dataTable.gp-table > tbody > tr.odd > * , table.dataTable.gp-table.table-striped > tbody > tr.odd > * { box-shadow: none; }
.gp-nowrap { white-space: nowrap; }
.gp-muted { color: var(--text-muted); }
.gp-meta { font-size: 12px; color: var(--text-secondary); margin-top: 1px; }
.gp-title-cell { min-width: 240px; max-width: 340px; }
.gp-link { color: var(--blue); font-weight: 500; text-decoration: none; }
.gp-link:hover { text-decoration: underline; color: #1D4ED8; }
.gp-pi { min-width: 120px; }
.gp-copis { font-size: 13px; color: #334155; min-width: 150px; max-width: 200px; line-height: 1.4; }
.gp-more { display: inline-block; margin-top: 2px; font-size: 12px; font-weight: 600; color: var(--blue); cursor: help; }
.gp-sponsor { color: #334155; min-width: 140px; max-width: 200px; }
.gp-amount { font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.gp-badge { display: inline-flex; align-items: center; height: 24px; padding: 0 9px; border-radius: 999px; font-size: 11px; font-weight: 600; letter-spacing: .03em; text-transform: uppercase; white-space: nowrap; }
.gp-badge.s-pending { background: var(--blue-light); color: var(--blue); }
.gp-badge.s-awarded { background: var(--success-light); color: #15803D; }
.gp-badge.s-under_review { background: var(--warning-light); color: #B45309; }
.gp-badge.s-not_awarded { background: var(--danger-light); color: var(--danger); }
.gp-tags { min-width: 150px; max-width: 220px; }
.gp-tag { display: inline-block; margin: 2px 4px 2px 0; padding: 2px 8px; border-radius: 6px; font-size: 11.5px; font-weight: 500; line-height: 1.5; white-space: nowrap; max-width: 100%; overflow: hidden; text-overflow: ellipsis; vertical-align: middle; }
.gp-tag.t-blue { background: var(--blue-light); color: #1D4ED8; } .gp-tag.t-green { background: var(--success-light); color: #047857; }
.gp-tag.t-purple { background: var(--purple-light); color: var(--purple); } .gp-tag.t-gray { background: #F1F5F9; color: #475569; }
.gp-actions { white-space: nowrap; text-align: right; }
.gp-icon-btn { width: 32px; height: 32px; border: 1px solid var(--border); background: #fff; border-radius: 6px; color: #475569; font-size: 15px; display: inline-flex; align-items: center; justify-content: center; margin-left: 4px; transition: all .15s ease; }
.gp-icon-btn:hover { background: var(--surface-soft); color: var(--usf-green); }
.gp-icon-btn.danger:hover { background: var(--danger-light); color: var(--danger); border-color: #FECACA; }
.gp-tfoot { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; padding: 12px 16px; border-top: 1px solid var(--border); font-size: 13px; color: var(--text-secondary); }
.gp-tfoot .dataTables_length label { display: flex; align-items: center; gap: 8px; margin: 0; font-weight: 400; }
.gp-tfoot .dataTables_length select { width: auto !important; height: 34px; border: 1px solid var(--control-border); border-radius: 7px; padding: 0 28px 0 10px; font-size: 13px; }
.gp-tfoot .dataTables_info { padding: 0 !important; text-align: center; }
.gp-tfoot .dataTables_paginate { justify-self: end; }
.gp-tfoot .pagination { margin: 0 !important; gap: 4px; }
.gp-tfoot .page-link { min-width: 34px; height: 34px; display: flex; align-items: center; justify-content: center; border: 1px solid var(--border) !important; border-radius: 6px !important; color: var(--text-primary); font-size: 13px; padding: 0 10px; }
.gp-tfoot .page-item.active .page-link { background: var(--usf-green); border-color: var(--usf-green) !important; color: #fff; }
.gp-tfoot .page-item.disabled .page-link { color: var(--text-muted); background: #fff; }
.gr-footer { color: var(--text-secondary); }
@media (max-width: 1399px) { .gp-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 1199px) { .gp-f, .gp-f-wide, .gp-f-search { max-width: none; } .gp-f-actions { width: 100%; justify-content: flex-end; } }
@media (max-width: 767px) {
    .grants-container { width: calc(100% - 32px); }
    .gp-header { flex-direction: column; } .gp-title { font-size: 26px; }
    .gp-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .gp-f, .gp-f-wide, .gp-f-search { flex-basis: 100%; }
    .gp-tfoot { grid-template-columns: 1fr; justify-items: center; } .gp-tfoot .dataTables_paginate { justify-self: center; }
    .gp-sort { width: 100%; }
}
@media (max-width: 480px) { .gp-kpis { grid-template-columns: 1fr; } }
/* fit + keep actions reachable (2026-09-29) */
table.gp-table { font-size: 13.5px; }
table.gp-table tbody td { padding: 10px 12px; }
.gp-title-cell { max-width: 300px; }
.gp-sponsor { max-width: 180px; }
.gp-tags { max-width: 190px; }
.gp-tag { max-width: 170px; }
table.gp-table th:last-child, table.gp-table td.gp-actions { position: sticky; right: 0; z-index: 1; }
table.gp-table td.gp-actions { background: #fff; box-shadow: -8px 0 8px -8px rgba(15,23,42,.12); }
table.gp-table th:last-child { background: var(--surface-soft); box-shadow: -8px 0 8px -8px rgba(15,23,42,.12); }
table.gp-table tbody tr:hover td.gp-actions { background: var(--surface-soft); }
table.gp-table { font-size: 13px; min-width: 1100px; }
table.gp-table thead th { padding: 10px; }
table.gp-table tbody td { padding: 10px; }
.gp-title-cell { min-width: 210px; max-width: 250px; }
.gp-copis { min-width: 130px; max-width: 150px; font-size: 12.5px; }
.gp-sponsor { min-width: 120px; max-width: 150px; }
.gp-pi { min-width: 100px; max-width: 130px; }
.gp-tags { min-width: 130px; max-width: 160px; }
.gp-tag { max-width: 150px; font-size: 11px; }
.gp-icon-btn { width: 30px; height: 30px; margin-left: 3px; }

/* =========================================================
   SPONSORS PAGE (2026-09-29)
   ========================================================= */
.gp-kpis-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.gp-info { color: var(--text-muted); cursor: help; margin-left: 4px; }
.gp-info:hover, .gp-info:focus { color: var(--usf-green); outline: none; }
.gp-table-sp { min-width: 1080px; }
.sp-cell { display: flex; align-items: center; gap: 10px; min-width: 220px; max-width: 340px; }
.sp-name { color: var(--text-primary); font-weight: 600; text-decoration: none; line-height: 1.3; }
.sp-name:hover { color: var(--usf-green); text-decoration: underline; }
.sp-mark { position: relative; width: 32px; height: 32px; flex-shrink: 0; border-radius: 8px; border: 1px solid var(--border); background: #fff; display: inline-flex; align-items: center; justify-content: center; overflow: hidden; }
.sp-mark img { display: none; width: 100%; height: 100%; object-fit: contain; padding: 4px; }
.sp-mark.has-logo img { display: block; }
.sp-mark.has-logo .sp-ini { display: none; }
.sp-ini { font-size: 11px; font-weight: 700; letter-spacing: -.01em; line-height: 1; }
.sp-mark.sp-ini-sm .sp-ini { font-size: 9.5px; } .sp-mark.sp-ini-xs .sp-ini { font-size: 8.5px; letter-spacing: -.03em; }
.sp-mark:not(.has-logo).sp-federal, .sp-mark:not(.has-logo).sp-internal { background: #ECFDF5; border-color: #C7EEDB; color: #047857; }
.sp-mark:not(.has-logo).sp-state { background: #EFF6FF; border-color: #CFE0FD; color: #1D4ED8; }
.sp-mark:not(.has-logo).sp-private { background: #F5F3FF; border-color: #E2D9FD; color: #6D28D9; }
.sp-mark:not(.has-logo).sp-other, .sp-mark:not(.has-logo).sp-federal_flow_through { background: #F1F5F9; color: #475569; }
.sp-mark:not(.has-logo).sp-unknown { background: #F8FAFC; color: #64748B; }
.sp-type { display: inline-block; padding: 3px 9px; border-radius: 999px; font-size: 11.5px; font-weight: 600; white-space: nowrap; }
.sp-type.t-fed, .sp-type.t-int { background: #ECFDF5; color: #047857; }
.sp-type.t-state { background: #EFF6FF; color: #1D4ED8; }
.sp-type.t-priv { background: #F5F3FF; color: #7C3AED; }
.sp-type.t-other, .sp-type.t-flow { background: #F1F5F9; color: #475569; }
.sp-type.t-unk { background: #F8FAFC; color: #64748B; border: 1px solid var(--border); }
.sp-strong { font-weight: 600; font-variant-numeric: tabular-nums; }
.sp-rate { display: flex; align-items: center; gap: 8px; min-width: 130px; }
.sp-rate-track { flex: 1; height: 8px; background: #E2E8F0; border-radius: 999px; overflow: hidden; }
.sp-rate-track i { display: block; height: 100%; background: #16A34A; border-radius: 999px; }
.sp-rate-val { font-size: 12.5px; font-weight: 600; color: var(--text-primary); min-width: 42px; text-align: right; font-variant-numeric: tabular-nums; }
.sp-notes { font-size: 13px; color: var(--text-secondary); max-width: 220px; }
@media (max-width: 1399px) { .gp-kpis-5 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 767px) { .gp-kpis-5 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .gp-kpis-5 { grid-template-columns: 1fr; } }

/* =========================================================
   PEOPLE PAGE (2026-09-29) — neutral / green, simpler than Sponsors
   ========================================================= */
.pe-kpi { background: #fff; }
.pe-kpi .gp-kpi-icon { background: #E8F5EF; color: #00543C; }
.gp-table-pe { min-width: 980px; }
.gp-table-pe tbody td { padding-top: 8px; padding-bottom: 8px; height: 46px; }
.pe-cell { display: flex; align-items: center; gap: 10px; min-width: 200px; }
.pe-av { width: 30px; height: 30px; border-radius: 50%; background: #E8F5EF; color: #00543C; font-size: 11px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.pe-name { color: #182230; font-weight: 600; text-decoration: none; }
.pe-name:hover { color: var(--usf-green); text-decoration: underline; }
.pe-name:focus-visible { outline: 2px solid var(--usf-green); outline-offset: 2px; }
.pe-acct { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: 6px; font-size: 11.5px; font-weight: 600; white-space: nowrap; letter-spacing: .01em; }
.pe-acct.is-linked { background: #E8F5EF; color: #087A55; }
.pe-acct.is-none { background: #F2F4F7; color: #667085; font-weight: 500; }
.pe-aff { font-size: 13px; color: #344054; }

/* =========================================================
   DEPARTMENTS & CENTERS (2026-09-29)
   ========================================================= */
.gp-kpis-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.gp-table-un { min-width: 760px; }
.gp-table-un tbody td { padding-top: 8px; padding-bottom: 8px; height: 46px; }
.un-type { display: inline-flex; align-items: center; gap: 6px; padding: 3px 9px; border-radius: 6px; font-size: 12px; font-weight: 600; white-space: nowrap; }
.un-type .bi { font-size: 12px; }
.un-department { background: #E8F5EF; color: #087A55; }
.un-center { background: #EEF4FB; color: #2F5E96; }
.un-office, .un-campus, .un-other { background: #F2F4F7; color: #475467; }
@media (max-width: 991px) { .gp-kpis-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .gp-kpis-4 { grid-template-columns: 1fr; } }
/* compact rows (≈44px) for People and Departments — no explicit cell height (padding was added on top of it) */
.gp-table-pe tbody td, .gp-table-un tbody td { height: auto; padding-top: 7px; padding-bottom: 7px; }
table.gp-table th:last-child, table.gp-table td.gp-actions { box-shadow: none; }
.gp-scroll.is-scrollable table.gp-table th:last-child, .gp-scroll.is-scrollable table.gp-table td.gp-actions { box-shadow: -8px 0 8px -8px rgba(15,23,42,.12); }
/* public (logged-out) header: Log in button in place of the user menu */
.grants-login { display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 14px; border-radius: 7px; border: 1px solid rgba(255,255,255,.35); color: #fff; font-size: 13px; font-weight: 600; text-decoration: none; white-space: nowrap; }
.grants-login:hover { background: rgba(255,255,255,.1); color: #fff; }
