/* Approved Moneylal theme system: scoped to the existing portal. */
#portal-shell{--paper:#f5f8f7;--surface:#fff;--surface-strong:#fff;--ink:#14253f;--muted:#617087;--line:#e0e8ec;--teal:#047857;--green:#047857;--navy:#064e3b;--theme-soft:#ecfdf5;--shadow:0 2px 8px #14253f04;color:var(--ink);background:var(--paper);grid-template-columns:224px minmax(0,1fr);grid-template-rows:76px 1fr auto;letter-spacing:0}
#portal-shell[data-theme=blue]{--teal:#1d4ed8;--green:#1d4ed8;--navy:#1644b5;--theme-soft:#eff6ff;--paper:#f5f8ff}
#portal-shell[data-theme=brand]{--teal:#be1e2d;--green:#be1e2d;--navy:#1255a2;--theme-soft:#fff1f2;--paper:#f7f9fc}
#portal-shell[data-theme=indigo]{--teal:#4338ca;--green:#4338ca;--navy:#3730a3;--theme-soft:#eef2ff;--paper:#f7f7fc}
#portal-shell[data-theme=burgundy]{--teal:#9f1239;--green:#9f1239;--navy:#881337;--theme-soft:#fff1f2;--paper:#fcf7f9}
#portal-shell .topbar{grid-column:2;grid-row:1;min-height:76px;padding:14px 28px;background:#fff;gap:12px;flex-direction:row;align-items:center}
.workspace-identity{display:flex;align-items:center;gap:16px;white-space:nowrap;font-size:14px}
#environment-badge{background:var(--theme-soft);color:var(--teal);padding:7px 10px;border-radius:5px;font-size:12px}
#portal-shell .topbar-actions{gap:8px;flex-wrap:nowrap}
#portal-shell .topbar-actions button{padding:8px 10px;min-height:36px;font-size:12px}
#portal-shell .session-pill{font-size:12px;padding:7px 10px;border:0;background:var(--theme-soft);color:var(--teal);white-space:nowrap}
#portal-shell .rail{grid-column:1;grid-row:1 / 4;background:var(--navy);border:0;display:flex;flex-direction:column;gap:5px;padding:18px 12px;min-width:0;align-items:stretch}
.dashboard-brand{display:flex;flex-direction:column;align-items:center;align-self:center;background:white;border-radius:7px;width:176px;height:170px;overflow:hidden;margin:0 0 20px;text-decoration:none;padding:5px 8px 8px}
.mascot-window{display:block;height:126px;width:144px;overflow:hidden;flex-shrink:0}
.mascot-window img{display:block;width:144px;max-width:none;height:auto}
.dashboard-brand strong{font-family:Georgia,serif;color:#be1e2d;font-size:29px;line-height:1.1}
#portal-shell .rail-button{border:0;border-radius:6px;color:#eefbf6;background:transparent;display:flex;align-items:center;gap:12px;width:100%;font-weight:500;font-size:14px;min-height:47px;padding:11px 13px;white-space:normal}
#portal-shell .rail-button:hover{background:#ffffff16}
#portal-shell .rail-button.is-active{background:var(--teal);color:white;box-shadow:0 3px 10px #0000000c}
.rail-button svg{width:20px;height:20px;flex-shrink:0}
#portal-shell .workspace{grid-column:2;grid-row:2;padding:30px 28px;min-width:0}
#portal-shell .legal-footer{grid-column:2;padding:20px 28px;color:var(--muted);border-top:1px solid var(--line);font-size:11px}
#portal-shell .section-head{margin-bottom:20px}
#portal-shell .section-head .eyebrow{display:none}
#portal-shell h2{font-size:30px;line-height:1.2;letter-spacing:-.7px;margin:0 0 8px}
.dashboard-intro{margin:0;color:var(--muted);font-size:14px}
#portal-shell .review-strip{padding:8px 12px;margin-bottom:20px;background:var(--theme-soft);border:0;gap:12px;font-size:12px;justify-content:flex-start}
#portal-shell .api-pill{padding:5px 8px;min-width:max-content;font-size:11px;color:var(--teal);border:0}
.workspace-summary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;margin-bottom:28px}
.workspace-summary article{background:#fff;border:1px solid var(--line);border-radius:7px;padding:20px 16px;display:flex;gap:14px;align-items:center;min-width:0}
.workspace-summary h3{font-size:13px;margin:0 0 8px;font-weight:600}
.workspace-summary strong{font-size:25px;line-height:1}
.workspace-summary p{font-size:11px;color:var(--muted);margin:8px 0 0}
.summary-icon{width:52px;height:52px;border-radius:50%;background:var(--theme-soft);color:var(--teal);display:grid;place-items:center;flex-shrink:0}
.summary-icon svg{width:25px;height:25px}
#portal-shell .panel{background:#fff;border-color:var(--line);box-shadow:none;border-radius:8px}
#portal-shell .profile-language-panel{padding:24px;border-top:3px solid var(--teal)}
#portal-shell .profile-language-panel h3{font-size:18px;margin-bottom:5px}
#portal-shell .profile-language-panel .panel-head{margin-bottom:22px}
#portal-shell .profile-language-panel .language-module{padding:0;border:0;margin:0;min-width:0}
#portal-shell .language-choice-group{border:0;border-radius:0;padding:0;min-width:0}
#portal-shell .language-choice-group + .language-choice-group{border-left:1px solid var(--line);padding-left:20px}
#portal-shell .language-choice-group legend{font-size:12px;font-weight:600;margin-bottom:12px;padding:0;color:var(--ink)}
#portal-shell .language-grid{gap:20px}
#portal-shell .language-checklist{grid-template-columns:repeat(4,minmax(0,1fr));max-height:none;overflow:visible;gap:8px}
#portal-shell .language-choice{border:1px solid var(--line);border-radius:5px;padding:9px 7px;gap:7px;min-height:42px;font-size:11px}
#portal-shell .language-choice:has(input:checked){background:var(--theme-soft);border-color:var(--teal);color:var(--ink)}
#portal-shell .language-choice input{width:15px;min-height:15px;height:15px;margin:0}
#portal-shell .language-checklist.is-collapsed .language-choice:nth-child(n+9):not(:has(input:checked)){display:none}
#portal-shell .language-expand{border:0;background:transparent;color:var(--teal);padding:8px 0;min-height:36px;font-size:12px;font-weight:600}
#portal-shell .language-detail-card{border:0;border-top:1px solid var(--line);border-radius:0;grid-template-columns:1fr 1.2fr 1.5fr;align-items:center;gap:16px;padding:18px 0;background:transparent}
#portal-shell .language-detail-card>strong{font-size:14px}
#portal-shell .language-detail-card label{font-size:12px}
#portal-shell .language-ability-list{flex-wrap:wrap;gap:12px}
#portal-shell .language-module>.micro-note{font-size:12px;margin:16px 0}
#portal-shell .language-module>.micro-note:first-of-type{background:#eff6ff;border-radius:5px;color:#465c79;padding:12px}
#portal-shell .language-save-actions{display:flex;justify-content:flex-end;gap:12px;border-top:1px solid var(--line);padding-top:16px}
#portal-shell .language-save-actions button{min-width:110px}
#portal-shell input,#portal-shell select,#portal-shell textarea{border-color:var(--line);border-radius:5px;background:#fff;color:var(--ink)}
#portal-shell button:not(.rail-button):focus-visible,#portal-shell a:focus-visible{outline:3px solid var(--teal);outline-offset:3px}
.dashboard-theme-picker{display:flex;gap:8px;border-left:1px solid var(--line);padding-left:12px;order:-1}
#portal-shell .dashboard-theme-picker button{width:18px;height:18px;min-height:18px;padding:0;border:2px solid white;border-radius:50%;background:var(--swatch);box-shadow:0 0 0 1px #dce3eb}
#portal-shell .dashboard-theme-picker button[aria-pressed=true]{box-shadow:0 0 0 2px var(--ink)}
[data-dashboard-theme=emerald]{--swatch:#047857}[data-dashboard-theme=blue]{--swatch:#1d4ed8}[data-dashboard-theme=brand]{--swatch:#be1e2d}[data-dashboard-theme=indigo]{--swatch:#4338ca}[data-dashboard-theme=burgundy]{--swatch:#881337}
.visually-hidden{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
@media(min-width:761px) and (max-width:1200px){#portal-shell{grid-template-columns:200px minmax(0,1fr)}#portal-shell .topbar{flex-wrap:wrap;height:auto}#portal-shell{grid-template-rows:auto 1fr auto}.workspace-summary article{padding:14px 10px}.summary-icon{width:36px;height:36px}#portal-shell .language-checklist{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:760px){#portal-shell{grid-template-columns:minmax(0,1fr);grid-template-rows:auto auto 1fr auto}#portal-shell .topbar{grid-column:1;grid-row:1;flex-wrap:wrap;padding:14px 16px}.workspace-identity{width:100%;justify-content:space-between;white-space:normal;gap:8px}#portal-shell .topbar-actions{flex-wrap:wrap;justify-content:flex-start;width:100%}#portal-shell .rail{grid-column:1;grid-row:2;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:5px;padding:12px}.dashboard-brand{grid-column:1 / -1;justify-self:start;width:140px;height:116px;margin:0 0 8px}.mascot-window{width:102px;height:82px}.mascot-window img{width:102px}.dashboard-brand strong{font-size:22px}#portal-shell .rail-button{font-size:11px;padding:9px 7px;gap:6px}.rail-button svg{width:16px;height:16px}#portal-shell .workspace{grid-column:1;grid-row:3;padding:22px 16px}#portal-shell .legal-footer{grid-column:1;grid-row:4;padding:16px}#portal-shell h2{font-size:25px}.workspace-summary{grid-template-columns:1fr;gap:10px;margin-bottom:20px}.workspace-summary article{padding:14px}.workspace-summary strong{font-size:22px}#portal-shell .profile-language-panel{padding:18px 14px}#portal-shell .language-grid{grid-template-columns:1fr}#portal-shell .language-choice-group + .language-choice-group{border-left:0;border-top:1px solid var(--line);padding:18px 0 0}#portal-shell .language-checklist{grid-template-columns:repeat(2,minmax(0,1fr))}#portal-shell .language-choice{font-size:12px}#portal-shell .language-detail-card{grid-template-columns:1fr}#portal-shell .review-strip{flex-direction:row;align-items:flex-start}#portal-shell .language-save-actions{flex-wrap:wrap}.dashboard-theme-picker{padding-left:0;border:0;margin-right:8px}}
#portal-shell .language-module{gap:8px}
#portal-shell .language-module>.micro-note:first-of-type{background:transparent;padding:0;color:var(--muted);margin:4px 0;font-size:11px}
#portal-shell .language-module>.language-support-note{background:#eff6ff;border-radius:5px;color:#465c79;padding:12px;margin:6px 0}
#portal-shell .language-choice-group legend{padding:0}
.catalogue-filter-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:12px}
.catalogue-table-wrap{max-width:100%;overflow:auto;border:1px solid var(--line);border-radius:8px}
.catalogue-table{width:100%;border-collapse:collapse;font-size:13px;text-align:left;min-width:950px}
.catalogue-table caption{text-align:left;padding:12px;color:var(--muted)}
.catalogue-table th{background:var(--theme-soft,var(--surface));color:var(--ink);padding:12px;white-space:nowrap}
.catalogue-table td{padding:14px 12px;border-top:1px solid var(--line);vertical-align:top;color:var(--ink)}
.catalogue-table td:nth-child(2){min-width:280px;max-width:420px}
.catalogue-table small{display:block;margin-top:6px;color:var(--muted);font-size:11px;overflow-wrap:anywhere}
.catalogue-table tbody tr:hover{background:var(--theme-soft,var(--paper))}
#nse-master-list{min-width:0;display:block}#nse-master-list[aria-busy=true]{opacity:.6}
