/* Jahangir Reporting Portal — modern administration layout v1.
   Presentation only. Does not override Supabase permissions or report logic. */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');
:root{
  --jgr-teal:#08786d;--jgr-teal-deep:#075e56;--jgr-teal-dark:#064f49;
  --jgr-text:#203835;--jgr-soft:#eff5f3;--jgr-border:#e1e9e6;
  --jgr-sub:#667874;--jgr-white:#fff;--jgr-shadow:0 5px 24px rgba(16,43,38,.055)
}
html{scroll-behavior:smooth}
body{font-family:Inter,'Segoe UI',Arial,sans-serif!important;background:#f5f7f7;color:var(--jgr-text)}
button,input,select{font-family:inherit}button{transition:background-color .14s,transform .14s,box-shadow .14s}
button:focus-visible,input:focus-visible,select:focus-visible,a:focus-visible{outline:3px solid #44bfa8;outline-offset:2px}
body.jgr-modern-active .wrap{max-width:none;margin:0;padding:0}
body.jgr-modern-active #appPanel{min-height:100vh;display:grid;grid-template-columns:244px minmax(0,1fr);align-items:stretch}
.jgr-sidebar{position:sticky;top:0;height:100vh;display:flex;flex-direction:column;background:linear-gradient(170deg,#087e72 0%,#06776c 60%,#08695f 100%);color:#fff;padding:26px 12px 14px;overflow-y:auto;z-index:90}
.jgr-brand{display:flex;align-items:center;gap:11px;padding:2px 12px 25px;border-bottom:1px solid #ffffff25;margin-bottom:18px}
.jgr-brand-mark{display:grid;place-items:center;width:39px;height:39px;border:1px solid #ffffff60;background:#ffffff14;border-radius:10px;color:#fff;font-size:22px;font-weight:800;letter-spacing:-.07em}
.jgr-brand-text strong{font-size:18px;line-height:1.1;display:block;letter-spacing:-.45px}.jgr-brand-text span{display:block;color:#c2e7df;font-size:10px;letter-spacing:.085em;text-transform:uppercase;margin-top:5px;font-weight:700}
.jgr-nav-section-title{padding:18px 14px 8px;font-size:10px;text-transform:uppercase;letter-spacing:.15em;font-weight:800;color:#a6d6cd}
.jgr-nav{display:flex;flex-direction:column;gap:5px}
.jgr-nav-button{display:flex;width:100%;align-items:center;gap:11px;border:0;background:transparent;color:#ddf3ef;border-radius:9px;text-align:left;font-size:13px;font-weight:600;line-height:1.25;padding:12px 13px;min-height:42px}
.jgr-nav-button svg{width:17px;height:17px;flex-shrink:0;stroke:currentColor;stroke-width:1.9;fill:none;stroke-linecap:round;stroke-linejoin:round}
.jgr-nav-button:hover{background:#ffffff18;color:#fff}.jgr-nav-button.active,.jgr-nav-button[aria-current=page]{background:#004f49;box-shadow:inset 3px 0 #abebde;color:#fff}
.jgr-nav-button .jgr-nav-count{margin-left:auto;background:#ffffff20;padding:2px 7px;border-radius:7px;font-size:10px}
.jgr-sidebar-spacer{flex:1;min-height:20px}
.jgr-sidebar-bottom{padding-top:15px;border-top:1px solid #ffffff26;margin-top:10px}
.jgr-sidebar-bottom #logoutBtn{width:100%;background:transparent;border:0;color:#fff;text-align:left;border-radius:9px;font-weight:600;padding:11px 14px}
.jgr-sidebar-bottom #logoutBtn:before{content:'↪';margin-right:12px;font-size:20px;font-weight:400;vertical-align:-1px}
.jgr-sidebar-bottom #logoutBtn:hover{background:#ffffff1c}
.jgr-sidebar-help{color:#b6ddd5;font-size:10px;line-height:1.5;padding:12px 12px 0}
.jgr-main{min-width:0;display:flex;flex-direction:column;min-height:100vh}
.jgr-topbar{background:#fff;border-bottom:1px solid var(--jgr-border);display:flex;align-items:center;justify-content:space-between;gap:14px;padding:0 30px;min-height:76px;position:sticky;top:0;z-index:50;box-shadow:0 1px 6px #0a41330a}
.jgr-topbar-left{display:flex;gap:15px;align-items:center;min-width:0;flex:1}
.jgr-mobile-menu{display:none;align-items:center;justify-content:center;padding:8px 10px;background:#fff;border:1px solid var(--jgr-border);color:#254941;font-size:18px}
.jgr-breadcrumb{font-size:12px;color:var(--jgr-sub);white-space:nowrap}.jgr-breadcrumb strong{color:var(--jgr-text);font-weight:800}.jgr-breadcrumb-divider{margin:0 9px;color:#b9c9c3}
.jgr-topbar-tools{display:flex;align-items:center;justify-content:flex-end;gap:12px;min-width:0}
.jgr-global-search{display:flex;gap:8px;align-items:center;border:1px solid var(--jgr-border);background:#f8faf9;padding:2px 5px 2px 11px;border-radius:9px;min-width:235px;max-width:350px}
.jgr-global-search:focus-within{border-color:#0c927d;box-shadow:0 0 0 2px #bceee248}
.jgr-global-search svg{width:17px;height:17px;stroke:#8da29b;stroke-width:2;fill:none;flex:none}
.jgr-global-search input{border:none!important;outline:0!important;box-shadow:none!important;background:transparent;width:205px;min-width:0;font-size:12px;padding:10px 3px}
.jgr-global-search button{padding:7px 10px;font-size:11px;background:var(--jgr-teal);border-radius:7px}
.jgr-topbar #refreshBtn{font-size:12px;padding:9px 11px;border:1px solid var(--jgr-border)}
.jgr-user-chip{display:flex;gap:10px;align-items:center;border-left:1px solid var(--jgr-border);padding-left:18px;min-width:0}
.jgr-user-avatar{display:grid;place-items:center;background:#def2ec;border:1px solid #b7dcd1;color:#076857;width:37px;height:37px;flex:none;border-radius:50%;font-size:14px;font-weight:800}
.jgr-user-info{min-width:0;max-width:180px;display:flex;flex-direction:column;gap:2px}
.jgr-user-info #userLine{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--jgr-text)!important;font-size:12px;font-weight:700;margin:0!important}
.jgr-user-info #rolePill{align-self:flex-start;padding:0;background:transparent;color:var(--jgr-teal);font-size:10px;letter-spacing:.06em}
.jgr-content{width:100%;min-width:0;max-width:1800px;margin:0 auto;padding:28px 32px 65px}
.jgr-page-intro{margin-bottom:21px;display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
.jgr-page-eyebrow{font-size:10px;letter-spacing:.13em;text-transform:uppercase;font-weight:800;color:var(--jgr-teal);margin:0 0 7px}
.jgr-page-title{font-size:25px;letter-spacing:-.65px;font-weight:800;margin:0;color:#103d36}
.jgr-page-subtitle{color:var(--jgr-sub);font-size:12px;line-height:1.65;margin:6px 0 0}
.jgr-summary-chip{font-size:11px;font-weight:700;color:#0a7561;border:1px solid #bcded5;background:#e8f5f0;border-radius:99px;padding:8px 12px}
body.jgr-modern-active #appPanel>.top,body.jgr-modern-active .portal-main-tabs{display:none!important}
body.jgr-modern-active #portalToolsSection.section,body.jgr-modern-active #portalSavedDashboard.section,body.jgr-modern-active #adminPanel.section{margin:0;min-width:0}
body.jgr-modern-active #portalToolsSection>h2,body.jgr-modern-active #portalSavedDashboard>h2,body.jgr-modern-active #adminPanel>h2{display:none}
body.jgr-modern-active #adminPanel>p{display:none}
body.jgr-modern-active #adminPanel>.tabs{display:none}
body.jgr-modern-active:not(.jgr-view-dashboard) .notice{display:none}
body.jgr-modern-active .notice{margin-bottom:20px;background:#e9f5f1;border:1px solid #cee9e1;color:#2b7165;border-left:4px solid var(--jgr-teal);padding:12px 16px;font-size:12px;line-height:1.5}
body.jgr-modern-active .panel{background:var(--jgr-white);border:1px solid var(--jgr-border);border-radius:12px;box-shadow:var(--jgr-shadow);padding:24px}
body.jgr-modern-active .grid{grid-template-columns:repeat(auto-fit,minmax(250px,1fr));gap:16px}
body.jgr-modern-active .tool{box-shadow:var(--jgr-shadow);border:1px solid var(--jgr-border);border-radius:12px;padding:20px;min-height:180px;position:relative;transition:box-shadow .15s,border-color .15s,transform .15s}
body.jgr-modern-active .tool:hover{border-color:#a5d5c9;box-shadow:0 8px 22px #114f3d15;transform:translateY(-1px)}
body.jgr-modern-active .tool h3{color:#164f43;font-size:15px;font-weight:750;line-height:1.4}
body.jgr-modern-active .tool p{font-size:12px}
body.jgr-modern-active .tool .pill{font-size:10px;letter-spacing:.07em}
body.jgr-modern-active button:not(.jgr-nav-button):not(.jgr-mobile-menu){border-radius:8px}
body.jgr-modern-active button:not(.secondary):not(.danger):not(.jgr-nav-button):not(.jgr-mobile-menu){background:var(--jgr-teal);color:#fff}
body.jgr-modern-active button:not(.secondary):not(.danger):not(.jgr-nav-button):not(.jgr-mobile-menu):hover{background:#08685e}
body.jgr-modern-active button.danger{background:#b33e3c}
body.jgr-modern-active button.secondary{background:#fff;border:1px solid #cfded8;color:#24443e}
body.jgr-modern-active button.secondary:hover{background:#edf5f1}
body.jgr-modern-active input,body.jgr-modern-active select{background:#fff;border:1px solid #cbdad4;border-radius:8px;padding:10px 12px;font-size:13px;color:#23433e;max-width:100%}
body.jgr-modern-active input[type=checkbox]{width:auto;accent-color:var(--jgr-teal)}
body.jgr-modern-active h3{color:#144e44;letter-spacing:-.2px}
body.jgr-modern-active #portalUserRoster{margin-top:0}
body.jgr-modern-active #portalUserRoster h3{margin:0 0 6px;font-size:18px}
body.jgr-modern-active #portalUserRoster p.small{line-height:1.55}
body.jgr-modern-active table{border:1px solid var(--jgr-border);border-radius:9px;border-collapse:separate;border-spacing:0;overflow:hidden;background:#fff}
body.jgr-modern-active th{background:#087c70!important;color:#fff!important;font-size:11px;letter-spacing:.03em;padding:13px 12px;font-weight:700;white-space:nowrap;border-bottom:none}
body.jgr-modern-active td{padding:12px;border-bottom:1px solid #e6edeb;font-size:12px;color:#2d4842;vertical-align:middle}
body.jgr-modern-active tbody tr:nth-child(even){background:#f6f9f8}
body.jgr-modern-active tbody tr:hover{background:#ecf7f2}
body.jgr-modern-active .pill{font-size:10px;font-weight:800;border-radius:30px}
body.jgr-modern-active .jgr-status-active{background:#daf5e4!important;color:#126f46!important}
body.jgr-modern-active .jgr-status-inactive{background:#ffe1df!important;color:#ab3b3b!important}
body.jgr-modern-active #portalUserRosterRows button{font-size:11px;padding:8px 10px;margin:2px}
body.jgr-modern-active .saved-filters label span{font-size:11px}
body.jgr-modern-active #portalSavedTable td{font-size:11px}
body.jgr-modern-active #portalSavedTable td.saved-actions{min-width:225px}
body.jgr-modern-active .saved-tablewrap{border:1px solid var(--jgr-border);border-radius:9px}
body.jgr-modern-active .saved-tablewrap th{background:#0d7d71!important}
body.jgr-modern-active details{color:var(--jgr-text)}
body.jgr-modern-active .jgr-secondary-panel{margin-top:22px;padding-top:18px;border-top:1px solid var(--jgr-border)}
body.jgr-modern-active #adminPanel .panel>h3{margin-top:4px}
body.jgr-modern-active .permgrid{margin:16px 0}
.jgr-toast{position:fixed;bottom:22px;right:22px;z-index:200;background:#104e43;color:#fff;border-radius:10px;padding:12px 16px;font-size:12px;box-shadow:0 7px 26px #0a39392b;max-width:360px}
.jgr-backdrop{display:none}
body:not(.jgr-modern-active) #loginPanel.panel.login{border-top:5px solid #08786d;box-shadow:0 16px 45px #0b37391c}
@media(max-width:1130px){.jgr-topbar{padding:0 20px}.jgr-content{padding:24px 22px}.jgr-global-search{min-width:190px}.jgr-global-search input{width:148px}.jgr-user-info{max-width:125px}}
@media(max-width:900px){body.jgr-modern-active #appPanel{grid-template-columns:73px minmax(0,1fr)}.jgr-sidebar{padding:20px 8px}.jgr-brand{padding:1px 5px 16px;justify-content:center}.jgr-brand-text,.jgr-nav-section-title,.jgr-nav-button .jgr-nav-label,.jgr-nav-count,.jgr-sidebar-help{display:none!important}.jgr-nav-button{justify-content:center;padding:13px 8px}.jgr-nav-button svg{width:21px;height:21px}.jgr-sidebar-bottom #logoutBtn{font-size:0;text-align:center}.jgr-sidebar-bottom #logoutBtn:before{margin:0;font-size:23px}.jgr-user-info{display:none}}
@media(max-width:660px){body.jgr-modern-active #appPanel{grid-template-columns:minmax(0,1fr)}.jgr-sidebar{position:fixed;left:0;top:0;bottom:0;height:100dvh;width:242px;transform:translateX(-103%);transition:transform .2s;padding:26px 12px 14px;box-shadow:9px 0 25px #062e2d35}.jgr-sidebar-open .jgr-sidebar{transform:translateX(0)}.jgr-sidebar-open .jgr-backdrop{display:block;position:fixed;inset:0;background:#042e2b99;z-index:85;border:0}.jgr-brand-text,.jgr-nav-section-title,.jgr-nav-button .jgr-nav-label,.jgr-sidebar-help{display:initial!important}.jgr-brand-text{display:block!important}.jgr-nav-button{justify-content:flex-start;padding:12px 13px}.jgr-nav-button svg{width:17px;height:17px}.jgr-topbar{padding:12px 16px;min-height:68px}.jgr-mobile-menu{display:flex}.jgr-global-search{min-width:0;max-width:none;width:100%}.jgr-global-search input{width:100%}.jgr-global-search button{padding:8px}.jgr-topbar-left{flex:none}.jgr-topbar-tools{flex:1;justify-content:flex-end}.jgr-user-chip,.jgr-topbar #refreshBtn{display:none}.jgr-content{padding:22px 14px 45px}.jgr-page-title{font-size:22px}.jgr-global-search{max-width:240px}.jgr-breadcrumb{display:none}body.jgr-modern-active .panel{padding:15px}body.jgr-modern-active table{min-width:540px}}
@media print{.jgr-sidebar,.jgr-topbar,.jgr-page-intro,.jgr-backdrop{display:none!important}body.jgr-modern-active #appPanel{display:block}.jgr-content{padding:0!important}}

/* PORTAL_USER_FULL_NAME_V1 */
.jgr-user-info .jgr-user-email{font-size:10px;line-height:1.25;color:#607b75;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:190px}
.jgr-user-info{max-width:205px}
