/* SLT SME Incentive System: multi-page PHP frontend, approved blue flat design. */
:root { --portal-bg:var(--canvas);--portal-surface:var(--white);--portal-input:#fff;--portal-subtle:#f6f9fd;--portal-focus:#e8f2ff;--portal-text:var(--ink);--portal-muted:var(--muted);--portal-edge:var(--border);--portal-tag:#e9f2ff;--portal-tag-text:#0756ad; }
:root[data-theme="dark"] { --portal-bg:#0b1322;--portal-surface:#15243a;--portal-input:#1b2b42;--portal-subtle:#1b2d43;--portal-focus:#213b59;--portal-text:#edf5ff;--portal-muted:#9fb4cf;--portal-edge:#2d425a;--portal-tag:#1c3759;--portal-tag-text:#b0d7ff; }
.portal-page, .portal-page input, .portal-page select, .portal-page textarea, .auth-page input {font-family:Inter,"Segoe UI",Arial,sans-serif}
.portal-page .main-content { max-width:1840px; }
.portal-heading {align-items:center; margin-bottom:17px}
.portal-heading .heading-left {min-width:0}
.page-id {flex-shrink:0;padding:7px 11px;border:1px solid var(--portal-edge);background:var(--portal-surface);border-radius:7px;color:var(--portal-muted);font-size:11px;font-weight:800;letter-spacing:.4px}
.portal-metrics {display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin:0 0 17px}
.portal-metric {background:var(--portal-surface);border:1px solid var(--portal-edge);border-radius:11px;padding:17px 18px;min-height:91px;display:flex;flex-direction:column;justify-content:center;gap:8px;box-shadow:var(--shadow)}
.portal-metric-label {font-size:11.5px;font-weight:650;color:var(--portal-muted)}
.portal-metric-value {font-size:22px;font-weight:800;letter-spacing:-.5px;color:var(--portal-text);line-height:1.16;overflow-wrap:anywhere}
.portal-panel{padding:21px 22px 19px;margin-bottom:17px;min-width:0;background:var(--portal-surface)!important}
.portal-panel-head{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:17px}
.portal-panel-head h2,.portal-panel h2{font-size:15.5px;margin:0 0 5px;font-weight:780;color:var(--portal-text);letter-spacing:-.25px}
.portal-panel-head p,.portal-panel > p{margin:0;color:var(--portal-muted);font-size:11.5px;line-height:1.6}
.portal-toolbar{display:flex;justify-content:space-between;align-items:flex-end;gap:14px;margin:16px 0 14px;flex-wrap:wrap}
.toolbar-filters,.toolbar-actions{display:flex;align-items:flex-end;flex-wrap:wrap;gap:9px}
.search-field{display:flex;align-items:center;gap:8px;background:var(--portal-input);height:39px;border:1px solid var(--border-strong);border-radius:7px;padding:0 10px;color:var(--muted);min-width:250px}
.search-field input{width:100%;border:0;outline:0;color:var(--portal-text);background:transparent;font-size:12px;min-width:0}
.search-field:focus-within{outline:2px solid var(--primary);outline-offset:1px}
.search-field svg.icon{width:16px;height:16px}
.toolbar-field{display:flex;flex-direction:column;gap:5px;font-size:10.5px;font-weight:750;color:var(--portal-muted)}
.toolbar-field select,.form-field input,.form-field select,.form-field textarea {border:1px solid var(--border-strong);border-radius:7px;color:var(--portal-text);background:var(--portal-input);padding:10px 12px;font-size:12px;min-height:39px;max-width:100%;outline:0}
.toolbar-field select{min-width:124px;max-width:192px}
.form-field input:focus,.form-field textarea:focus,.form-field select:focus,.toolbar-field select:focus{border-color:var(--primary);outline:2px solid var(--portal-focus)}
.toolbar-actions .button{min-height:38px}
.mini-tag,.status-chip{display:inline-flex;align-items:center;justify-content:center;white-space:nowrap;background:var(--portal-tag);color:var(--portal-tag-text);border:1px solid var(--portal-edge);border-radius:6px;padding:6px 10px;font-size:10.5px;font-weight:800}
.status-chip{background:var(--portal-tag)}
.portal-table-scroll{overflow:auto;border:1px solid var(--portal-edge);border-radius:8px}
.portal-table{border-collapse:collapse;width:100%;min-width:750px;text-align:left;font-size:11.5px}
.portal-table th{padding:13px 13px;color:var(--portal-muted);background:var(--portal-subtle);border-bottom:1px solid var(--portal-edge);font-weight:750;white-space:nowrap;text-align:left}
.portal-table td{padding:12px 13px;color:var(--text);border-bottom:1px solid var(--portal-edge);vertical-align:middle;text-align:left;line-height:1.38}
.portal-table tbody tr:last-child td{border-bottom:0}
.portal-table tbody tr:hover td{background:var(--portal-focus)}
.portal-table .empty-table{padding:34px;text-align:center;color:var(--portal-muted)}
.sort-header{display:flex;gap:7px;align-items:center;border:0;background:transparent;padding:0;font:inherit;font-weight:inherit;color:inherit;text-align:left;cursor:pointer}
.sort-glyph{font-size:13px;color:var(--portal-muted);opacity:.65}
.row-link,.subtle-link{background:none;border:0;color:var(--primary);font-weight:750;font-size:11px;padding:3px;cursor:pointer;text-decoration:none;white-space:nowrap}
.row-link:hover,.subtle-link:hover{text-decoration:underline}
.table-footer{display:flex;align-items:center;justify-content:space-between;gap:14px;margin:15px 0 0;color:var(--portal-muted);font-size:10.5px;flex-wrap:wrap}
.pagination-actions{display:flex;align-items:center;gap:9px}
.pagination-actions select{border:1px solid var(--portal-edge);background:var(--portal-input);color:var(--portal-text);border-radius:6px;padding:7px}
.pagination-actions .button:disabled{opacity:.48}
.tab-strip{display:flex;align-items:flex-end;gap:2px;overflow-x:auto;border-bottom:1px solid var(--portal-edge);margin:1px 0 16px;white-space:nowrap;scrollbar-width:thin}
.tab-button{appearance:none;background:transparent;border:0;border-bottom:2px solid transparent;color:var(--portal-muted);font-size:12px;font-weight:710;padding:13px 15px;cursor:pointer;margin-bottom:-1px}
.tab-button:hover{color:var(--primary);background:var(--portal-focus)}
.tab-button.active{color:var(--primary);border-bottom-color:var(--primary)}
.info-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.info-grid.three-up{grid-template-columns:repeat(3,minmax(0,1fr))}
.info-item{padding:15px 16px;background:var(--portal-subtle);border:1px solid var(--portal-edge);border-radius:8px;min-height:86px;display:flex;flex-direction:column;gap:8px}
.info-item span{font-size:11px;color:var(--portal-muted);font-weight:700}
.info-item strong{font-size:12.5px;color:var(--portal-text);font-weight:720;overflow-wrap:anywhere}
.subtle-note{display:flex;align-items:flex-start;gap:11px;background:var(--portal-focus);border:1px solid var(--portal-edge);border-radius:8px;padding:13px 14px;margin-top:17px;color:var(--text);font-size:11px}
.subtle-note .icon{color:var(--primary);width:18px;height:18px}
.subtle-note p{margin:0;line-height:1.6}
.small-note{font-size:11px;color:var(--portal-muted);margin:10px 0 0;line-height:1.5}
.two-col-layout{display:grid;grid-template-columns:1.35fr 1fr;gap:16px;align-items:start}
.validation-details{grid-template-columns:1fr 1fr}
.two-col-layout > .portal-panel{height:100%}
.requirements-list{display:flex;flex-direction:column;gap:0}
.requirements-list > div{padding:14px 0;border-bottom:1px solid var(--portal-edge)}
.requirements-list > div:last-child{border-bottom:0}
.requirements-list strong{display:block;font-size:12px;color:var(--portal-text);margin-bottom:5px}
.requirements-list small{display:block;font-size:11px;line-height:1.6;color:var(--portal-muted)}
.portal-form{display:flex;flex-direction:column;gap:17px}
.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.form-field{display:flex;flex-direction:column;gap:8px;font-size:11.5px;font-weight:720;color:var(--portal-text)}
.form-field textarea{resize:vertical;min-height:86px}
.form-buttons,.bottom-actions{display:flex;align-items:center;justify-content:flex-end;flex-wrap:wrap;gap:10px;margin-top:15px}
.upload-drop{display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;gap:10px;border:1px dashed #8ebbe9;border-radius:10px;background:var(--portal-subtle);padding:30px 19px;cursor:pointer;transition:border-color .15s}
.upload-drop:hover,.upload-drop.is-dragover{border-color:var(--primary);background:var(--portal-focus)}
.upload-drop svg.icon{height:33px;width:33px;color:var(--primary)}
.upload-drop strong{font-size:13px;color:var(--portal-text)}
.upload-drop span{font-size:11px;color:var(--portal-muted)}
.upload-drop input{font-size:11px;max-width:100%;color:var(--portal-muted)}
.upload-preview{background:var(--portal-subtle);border:1px solid var(--portal-edge);padding:12px 13px;border-radius:7px;color:var(--portal-muted);font-size:11px}
.workflow-overview{padding-bottom:22px}
.workflow-steps{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:4px;margin:18px 0 21px}
.workflow-step{display:flex;flex-direction:column;align-items:center;text-align:center;gap:7px;position:relative}
.workflow-step:not(:last-child)::after{position:absolute;content:"";height:2px;background:var(--border-strong);left:calc(50% + 21px);right:calc(-50% + 21px);top:15px}
.workflow-step.complete:not(:last-child)::after{background:#377ecb}
.workflow-step-dot{display:grid;place-items:center;width:32px;height:32px;background:var(--portal-tag);color:var(--primary);font-size:11px;font-weight:800;border:1px solid #75a8df;border-radius:50%;z-index:1}
.workflow-step strong{font-size:11px;color:var(--portal-text);font-weight:750}
.workflow-step small{font-size:10px;color:var(--portal-muted)}
.locked-note,.approved-callout{display:flex;gap:12px;align-items:center;background:var(--portal-focus);border:1px solid var(--portal-edge);border-radius:9px;padding:14px 16px;color:var(--portal-text);margin-bottom:15px}
.locked-note .icon,.approved-callout .icon{color:var(--primary);width:24px;height:24px}
.locked-note p{margin:0;font-size:11.5px;line-height:1.6}
.approved-callout div{display:flex;flex-direction:column;gap:5px}
.approved-callout strong{font-size:12px}.approved-callout span{font-size:11px;color:var(--portal-muted)}
.three-note-strip{display:grid;grid-template-columns:repeat(3,1fr);gap:11px;margin-bottom:16px}
.three-note-strip span{border:1px solid var(--portal-edge);border-radius:8px;background:var(--portal-surface);padding:11px 13px;font-size:11px;color:var(--portal-muted)}
.three-note-strip strong{color:var(--portal-text);margin-right:8px}
.approval-controls{display:flex;flex-direction:column;gap:14px}
.approval-controls .checks{display:flex;flex-direction:column;gap:12px;margin:5px 0}
.approval-controls .checks label,.small-checkbox{display:flex;align-items:center;gap:9px;font-size:11.5px;color:var(--portal-text)}
.approval-controls .checks input{accent-color:#075fc1;height:17px;width:17px}
.auth-page{background:var(--portal-bg);color:var(--portal-text)}
.auth-shell{min-height:100vh;display:grid;grid-template-columns:minmax(330px,.86fr) minmax(400px,1.15fr)}
.auth-side{display:flex;flex-direction:column;justify-content:space-between;background:#edf5ff;padding:50px max(30px,7vw);color:#122e54}
.auth-side img{width:190px;height:auto}
.auth-side h1{font-size:clamp(28px,3.5vw,47px);font-weight:810;line-height:1.14;letter-spacing:-1.4px;max-width:510px;margin:14px 0}
.auth-side p{font-size:14px;color:#4d6789;max-width:420px;line-height:1.7}
.auth-side small{color:#748cac;font-size:11px}
.auth-eyebrow{color:#075fc1;font-size:11px;letter-spacing:1.4px;font-weight:800}
.auth-main{display:flex;justify-content:center;align-items:center;padding:60px 30px;position:relative}
.auth-switch{position:absolute;right:26px;top:24px}
.auth-card{width:min(430px,100%);background:var(--portal-surface);border:1px solid var(--portal-edge);border-radius:14px;padding:37px 35px;box-shadow:0 8px 28px rgba(18,47,82,.04)}
.auth-card h2{font-size:25px;color:var(--portal-text);font-weight:820;margin:17px 0 7px;letter-spacing:-.6px}
.auth-card p{font-size:12px;line-height:1.6;color:var(--portal-muted);margin:0 0 18px}
.auth-card form{display:flex;flex-direction:column;gap:15px}
.auth-row{display:flex;align-items:center;justify-content:space-between;gap:8px;font-size:11px}
.auth-row a,.auth-links a,.auth-back{color:var(--primary);font-weight:750;text-decoration:none;font-size:11px}
.auth-submit{min-height:44px;width:100%;font-size:12px}
.auth-back{text-align:center;margin:5px 0}
.auth-links{border-top:1px solid var(--portal-edge);padding-top:19px;margin-top:20px;text-align:center}
.auth-feedback{margin:12px 0;color:var(--primary);font-size:11.5px;font-weight:700;min-height:0}
:root[data-theme=dark] .auth-side{background:#101e33;color:#eaf3ff}
:root[data-theme=dark] .auth-side p{color:#a6bfdc}
:root[data-theme=dark] .auth-eyebrow{color:#8bc4ff}
:root[data-theme=dark] .auth-side img{background:white;border-radius:9px;padding:7px}
.modal-body .form-grid,.modal-body .portal-form{gap:12px}
.modal-body .form-field{margin-bottom:11px}
.modal-body .info-grid{margin-top:6px}
.modal-body .modal-actionbar{display:flex;gap:9px;justify-content:flex-end;margin-top:15px}
.modal-body .confirm-warning{background:var(--portal-focus);border:1px solid var(--portal-edge);border-radius:7px;padding:12px;line-height:1.55;font-size:11px;color:var(--portal-text)}
.global-footer{display:flex;justify-content:space-between;gap:12px;padding:15px 27px 15px calc(var(--sidebar) + 27px);background:var(--portal-surface);border-top:1px solid var(--portal-edge);font-size:10.5px;color:var(--portal-muted)}
.nav-group{width:100%}
.nav-parent.parent-active{background:#f0f6ff;color:#0756b1;font-weight:760}
.nav-parent.parent-active .icon{color:#0756b1}
.nav-group.expanded .nav-chevron{transform:rotate(90deg)}
.nav-submenu{display:flex;flex-direction:column;margin:4px 0 7px 33px;border-left:1px solid var(--portal-edge);padding:2px 0 2px 11px;gap:2px}
.nav-subitem{font-size:11.5px;line-height:1.3;padding:9px 9px 9px 12px;border-radius:6px;color:var(--portal-muted)}
.nav-subitem:hover{background:var(--portal-focus);color:var(--primary)}
.nav-subitem.active{font-weight:780;background:var(--portal-tag);color:var(--primary)}
:root[data-theme=dark] .nav-parent.parent-active{background:#1c3552;color:#e5f1ff}
:root[data-theme=dark] .nav-parent.parent-active .icon{color:#c5e1ff}
:root[data-theme=dark] .nav-subitem{color:#afc2dc}
:root[data-theme=dark] .nav-subitem:hover{color:#fff}
:root[data-theme=dark] .nav-subitem.active{color:#b8dcff;background:#1b395d}
:root[data-theme=dark] .portal-table th{background:var(--portal-subtle)}
:root[data-theme=dark] .portal-table td{color:var(--text)}
:root[data-theme=dark] .portal-table tbody tr:hover td{background:#1d3551}
:root[data-theme=dark] .upload-drop{border-color:#4975a4}
:root[data-theme=dark] .locked-note,.portal-page[data-page-key=dashboard] .locked-note{color:var(--portal-text)}
@media(max-width:1330px){.portal-panel{padding:18px 17px}.portal-metrics{gap:10px}.portal-metric{padding:14px 12px}.portal-metric-value{font-size:19px}.search-field{min-width:195px}.toolbar-filters{gap:8px}}
@media(max-width:1050px){.portal-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.two-col-layout{grid-template-columns:1fr}.info-grid.three-up{grid-template-columns:repeat(2,minmax(0,1fr))}.workflow-steps{grid-template-columns:repeat(3,minmax(0,1fr));row-gap:18px}.workflow-step:not(:last-child)::after{display:none}.three-note-strip{grid-template-columns:1fr}.portal-toolbar{flex-direction:column;align-items:stretch}}
@media(max-width:800px){.global-footer{padding-left:18px}.auth-shell{grid-template-columns:1fr}.auth-side{min-height:270px;padding:30px;gap:36px}.auth-side h1{font-size:27px}.auth-main{padding:40px 20px}.auth-switch{right:18px;top:10px}.portal-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.portal-panel-head{flex-wrap:wrap}}
@media(max-width:540px){.portal-heading h1{font-size:22px}.portal-heading .page-id{display:none}.portal-metrics{gap:9px}.portal-metric{min-height:85px}.portal-metric-value{font-size:16px}.portal-metric-label{font-size:10px}.toolbar-filters,.toolbar-actions{width:100%}.search-field{width:100%;min-width:0}.toolbar-field{flex:1}.toolbar-field select{min-width:0;width:100%}.portal-toolbar .button{flex:1}.info-grid,.info-grid.three-up,.form-grid{grid-template-columns:1fr}.portal-panel{padding:16px 12px}.table-footer{align-items:flex-start;flex-direction:column}.pagination-actions{flex-wrap:wrap}.tab-button{padding:12px 10px;font-size:11px}.workflow-steps{grid-template-columns:repeat(2,minmax(0,1fr))}.auth-card{padding:27px 20px}.auth-side{min-height:240px}.global-footer{flex-direction:column}.auth-side img{width:160px}}
@media print{.topbar,.sidebar,.mobile-overlay,.demo-banner,.portal-toolbar,.global-footer,.bottom-actions,.content-footer{display:none!important}.main-content{margin:0!important;width:100%!important;padding:10px!important}.panel{box-shadow:none;break-inside:avoid}.portal-table{font-size:10px}}

/* Keep toolbars orderly on laptops and print-size canvases. */
.portal-toolbar{display:flex;flex-direction:column;align-items:stretch;gap:10px}
.toolbar-filters{justify-content:flex-start}
.toolbar-actions{justify-content:flex-end;width:100%;gap:8px}
.toolbar-actions .button{flex:0 0 auto}
@media(max-width:540px){.toolbar-actions .button{flex:1 1 auto}}
