/* ==========================================================================
   OJT Management System — UI stylesheet (presentation only)
   Sections: 1 Tokens · 2 Base · 3 Topbar · 4 Layout & sidebar · 5 Content
             6 Cards & KPI · 7 Tables · 8 Buttons · 9 Forms · 10 Alerts/badges
             11 Pagination · 12 Auth pages · 13 Landing · 14 Dialog
             15 Responsive · 16 Accessibility & motion · 17 Print
   ========================================================================== */

/* 1. Tokens ---------------------------------------------------------------- */
:root{
  --bg:#f4f6fb;--card:#fff;--ink:#1e2a3a;--muted:#5a6a80;
  --brand:#1a56db;--brand2:#0e3aa5;--brand-soft:#e8effd;
  --ok:#0e7c3e;--bad:#c81e1e;--warn:#9a6700;--info:#1a56db;
  --line:#e3e8f2;--line-strong:#cbd4e4;
  --r:12px;--r-sm:8px;
  --shadow-sm:0 1px 2px rgba(20,34,58,.06);
  --shadow-md:0 8px 24px rgba(20,34,58,.12);
  --focus:0 0 0 3px rgba(26,86,219,.30);
  --topbar-h:56px;--sidebar-w:240px;
  --font:system-ui,-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;
}

/* 2. Base ------------------------------------------------------------------ */
*,*::before,*::after{box-sizing:border-box}
html{-webkit-text-size-adjust:100%;text-size-adjust:100%;scroll-padding-top:calc(var(--topbar-h) + 12px)}
body{margin:0;font-family:var(--font);font-size:15px;line-height:1.5;background:var(--bg);color:var(--ink);
  overflow-wrap:break-word;-webkit-font-smoothing:antialiased}
img,svg,video{max-width:100%;height:auto}
svg{height:auto}
a{color:var(--brand);text-decoration:none}
a:hover{text-decoration:underline}
h1,h2,h3{line-height:1.25}
p{margin:0 0 .75em}
small{font-size:.85em}
b,strong{font-weight:700}
.muted{color:var(--muted);font-size:13px}
.icon{width:20px;height:20px;flex:none;stroke:currentColor;fill:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.skip-link{position:absolute;left:12px;top:-60px;z-index:100;background:#fff;color:var(--brand);padding:8px 14px;border-radius:var(--r-sm);box-shadow:var(--shadow-md);font-weight:600}
.skip-link:focus{top:8px;text-decoration:none}

/* 3. Topbar ---------------------------------------------------------------- */
.topbar{background:var(--brand);color:#fff;position:sticky;top:0;z-index:40;box-shadow:0 1px 0 rgba(0,0,0,.12)}
.topbar-inner{max-width:1320px;margin:auto;display:flex;align-items:center;gap:12px;min-height:var(--topbar-h);
  padding:8px max(16px,env(safe-area-inset-right)) 8px max(16px,env(safe-area-inset-left))}
.brand{color:#fff;font-weight:700;display:flex;gap:10px;align-items:center;font-size:17px;min-width:0}
.brand:hover{text-decoration:none}
.brand-logo{width:34px;height:34px;border-radius:50%;object-fit:cover;background:#fff;flex:none;box-shadow:0 0 0 2px rgba(255,255,255,.65)}
.brand-logo + .brand-mark--fallback{display:none}
.auth-logo{width:64px;height:64px;box-shadow:0 0 0 3px #fff,0 4px 14px rgba(29,50,90,.25)}
.auth-brand{flex-direction:column}
.brand-mark{background:#fff;border-radius:9px;width:34px;height:34px;display:inline-flex;align-items:center;justify-content:center;font-size:18px;flex:none}
.brand-text{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.topbar-actions{margin-left:auto;display:flex;gap:6px;align-items:center}
.menu-btn{display:none;align-items:center;justify-content:center;width:40px;height:40px;background:rgba(255,255,255,.14);color:#fff;border:0;border-radius:var(--r-sm);cursor:pointer;padding:0;flex:none}
.menu-btn:hover{background:rgba(255,255,255,.26)}
.menu-btn:active{background:rgba(255,255,255,.34)}
.icon-link{color:#fff;position:relative;display:inline-flex;align-items:center;justify-content:center;width:40px;height:40px;border-radius:var(--r-sm)}
.icon-link:hover{background:rgba(255,255,255,.16);text-decoration:none}
.dot{position:absolute;top:2px;right:0;min-width:18px;height:18px;background:#ffcf3f;color:#2a2200;font-size:11px;line-height:18px;text-align:center;border-radius:9px;padding:0 5px;font-weight:700}
/* profile dropdown (native <details>, works without JS) */
.user-menu{position:relative}
.user-menu>summary{list-style:none;display:flex;align-items:center;gap:8px;cursor:pointer;padding:4px 8px 4px 4px;border-radius:999px;color:#fff;user-select:none}
.user-menu>summary::-webkit-details-marker{display:none}
.user-menu>summary:hover,.user-menu[open]>summary{background:rgba(255,255,255,.16)}
.avatar{width:32px;height:32px;border-radius:50%;background:#fff;color:var(--brand);font-weight:700;font-size:13px;display:inline-flex;align-items:center;justify-content:center;flex:none}
.user-meta{display:flex;flex-direction:column;line-height:1.15;min-width:0;max-width:180px}
.user-name{font-size:13px;font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.user-role{font-size:11px;opacity:.85}
.user-menu .chev{width:16px;height:16px;transition:transform .15s}
.user-menu[open] .chev{transform:rotate(180deg)}
.user-panel{position:absolute;right:0;top:calc(100% + 8px);width:260px;max-width:calc(100vw - 24px);background:#fff;color:var(--ink);border:1px solid var(--line);border-radius:var(--r);box-shadow:var(--shadow-md);padding:6px;z-index:60}
.user-panel-head{padding:10px 12px 12px;border-bottom:1px solid var(--line);margin-bottom:6px;display:flex;flex-direction:column;gap:2px}
.user-panel-head strong{font-size:14px;overflow-wrap:anywhere}
.user-panel-head .muted{overflow-wrap:anywhere}
.user-panel-head .badge{align-self:flex-start;margin-top:6px}
.user-panel a{display:flex;align-items:center;gap:10px;padding:10px 12px;border-radius:var(--r-sm);color:var(--ink);min-height:40px}
.user-panel a:hover{background:var(--brand-soft);color:var(--brand);text-decoration:none}
.user-panel a.logout{color:var(--bad)}
.user-panel a.logout:hover{background:#fde8e8;color:var(--bad)}

/* 4. Layout & sidebar ------------------------------------------------------ */
.layout{max-width:1320px;margin:auto;display:grid;grid-template-columns:var(--sidebar-w) minmax(0,1fr);gap:20px;
  padding:20px max(16px,env(safe-area-inset-right)) 20px max(16px,env(safe-area-inset-left));align-items:start}
.sidebar{background:var(--card);border:1px solid var(--line);border-radius:var(--r);padding:10px;position:sticky;top:calc(var(--topbar-h) + 16px);
  max-height:calc(100vh - var(--topbar-h) - 32px);overflow-y:auto;box-shadow:var(--shadow-sm)}
.sidebar a{display:flex;align-items:center;gap:12px;padding:10px 12px;border-radius:var(--r-sm);color:var(--ink);margin:2px 0;min-height:42px;font-weight:500;position:relative}
.sidebar a .icon{color:var(--muted)}
.sidebar a:hover{background:var(--brand-soft);color:var(--brand);text-decoration:none}
.sidebar a:hover .icon{color:var(--brand)}
.sidebar a.active{background:var(--brand-soft);color:var(--brand);font-weight:600}
.sidebar a.active .icon{color:var(--brand)}
.sidebar a.active::before{content:"";position:absolute;left:-10px;top:8px;bottom:8px;width:3px;border-radius:0 3px 3px 0;background:var(--brand)}
.side-label{font-size:11px;letter-spacing:.06em;text-transform:uppercase;color:var(--muted);padding:6px 12px;font-weight:700}
.side-foot{margin-top:10px;font-size:12px;color:var(--muted);border-top:1px solid var(--line);padding:10px 12px 4px}
.side-close{display:none}
.nav-backdrop{display:none}
.content{min-width:0}
.content:focus{outline:0}

/* 5. Page content ---------------------------------------------------------- */
.page-head{margin:0 0 16px}
.page-head h1{margin:2px 0 0;font-size:clamp(1.3rem,1.05rem + 1vw,1.75rem);font-weight:750;letter-spacing:-.01em;overflow-wrap:anywhere}
.grid{display:grid;gap:16px}
.grid.kpi{grid-template-columns:repeat(auto-fit,minmax(170px,1fr))}
.grid.kpi.admin-kpi{grid-template-columns:repeat(4,minmax(0,1fr))}
.grid.two{grid-template-columns:repeat(auto-fit,minmax(min(100%,360px),1fr))}
.content>:is(.card,.grid,.table-wrap)+:is(.card,.grid,.table-wrap){margin-top:16px!important}
.row{display:flex;gap:12px;flex-wrap:wrap;align-items:flex-end}
.row>.field{flex:1 1 180px!important;min-width:0}
.row>[style*="flex:2"]{flex:2 1 260px!important;min-width:0}
.row>[style*="flex:3"]{flex:3 1 320px!important;min-width:0}
.row>input,.row>select{flex:1 1 180px;min-width:0;width:auto}
.row .field{margin-bottom:12px}
.row.no-print,form.row{align-items:center}
form.row>.field{margin-bottom:0}
.filters{display:grid;grid-template-columns:repeat(auto-fit,minmax(170px,1fr));gap:12px;margin-bottom:12px;align-items:end}
.filters label{margin:0;font-weight:500}
.filters label input{margin-top:4px}
.content form[style*="display:inline"]{display:inline-block!important;margin:2px 4px 2px 0}

/* 6. Cards & KPI ----------------------------------------------------------- */
.card{background:var(--card);border:1px solid var(--line);border-radius:var(--r);padding:18px;box-shadow:var(--shadow-sm);min-width:0}
.card h3{margin:0 0 12px;font-size:16px;font-weight:700}
.card>p:last-child,.card>.table-wrap:last-child{margin-bottom:0}
.card>.table-wrap+p{margin-top:12px}
.grid.kpi .card{position:relative;padding:16px 18px 16px 20px;overflow:hidden}
.grid.kpi .card::before{content:"";position:absolute;left:0;top:0;bottom:0;width:4px;background:var(--brand)}
.kpi-num{font-size:clamp(1.4rem,1.1rem + 1vw,1.85rem);font-weight:800;color:var(--brand);line-height:1.15;overflow-wrap:anywhere}
.kpi-label{color:var(--muted);font-size:13px;margin-top:4px}
.coordinator-chart{display:grid;grid-template-columns:minmax(150px,220px) minmax(0,1fr);gap:28px;align-items:center}
.coordinator-pie{display:block;width:100%;max-width:220px;aspect-ratio:1;border-radius:50%;overflow:hidden}
.coordinator-chart-legend{list-style:none;padding:0;margin:0;display:grid;gap:12px}
.coordinator-chart-legend li{display:grid;grid-template-columns:12px minmax(0,1fr) auto;gap:10px;align-items:center}
.coordinator-chart-swatch{width:12px;height:12px;border-radius:3px;background:var(--chart-color)}
.coordinator-chart-label{min-width:0}
.coordinator-chart-value{font-weight:700;white-space:nowrap}
.coordinator-chart-value .muted{font-weight:400}
.coordinator-chart-empty{margin:0;color:var(--muted);min-height:180px;display:grid;place-items:center}
@media(max-width:560px){.coordinator-chart{grid-template-columns:minmax(0,1fr);justify-items:center;gap:20px}.coordinator-chart-legend{width:100%}}
.admin-role-chart{list-style:none;padding:0;margin:0 0 14px;display:grid;gap:16px}
.admin-role-chart-item{min-width:0}
.admin-role-chart-label{display:flex;justify-content:space-between;gap:12px;margin-bottom:6px}
.admin-role-chart-label strong{font-variant-numeric:tabular-nums}
.admin-role-chart-track{height:12px;overflow:hidden;border-radius:999px;background:#26384b}
.admin-role-chart-track span{display:block;height:100%;border-radius:inherit;background:linear-gradient(90deg,#2186bd,#63d2f5)}
@media(max-width:900px){.grid.kpi.admin-kpi{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:420px){.grid.kpi.admin-kpi{grid-template-columns:minmax(0,1fr)}}
.progress{height:10px;background:#e8edf5;border-radius:6px;overflow:hidden}
.progress>div{height:100%;background:var(--brand);border-radius:6px}
.notif-item{margin:0;padding:12px 4px;border-bottom:1px solid var(--line)}
.notif-item:last-child{border-bottom:0}
.notif-item.unread{background:#f5f8ff;border-radius:var(--r-sm);padding-left:12px;padding-right:12px}

/* 7. Tables ---------------------------------------------------------------- */
.table-wrap{overflow-x:auto;-webkit-overflow-scrolling:touch;background:#fff;border:1px solid var(--line);border-radius:var(--r);box-shadow:var(--shadow-sm)}
.table-wrap:focus-visible{outline:2px solid var(--brand);outline-offset:2px}
.card .table-wrap{box-shadow:none}
table{width:100%;border-collapse:collapse;background:#fff}
th,td{padding:11px 14px;border-bottom:1px solid var(--line);text-align:left;font-size:14px;vertical-align:middle}
th{background:#f1f5fc;font-size:12px;letter-spacing:.04em;text-transform:uppercase;color:#3d4b61;white-space:nowrap;font-weight:700}
tbody tr:hover>td{background:#f8faff}
tr:last-child>td{border-bottom:0}
td .btn.small{margin:1px 0}

/* 8. Buttons --------------------------------------------------------------- */
.btn{display:inline-flex;align-items:center;justify-content:center;gap:6px;background:var(--brand);color:#fff;border:1px solid transparent;border-radius:var(--r-sm);
  padding:9px 16px;min-height:40px;font:inherit;font-size:14px;font-weight:600;line-height:1.2;cursor:pointer;text-align:center;text-decoration:none;
  transition:background-color .15s,border-color .15s,box-shadow .15s,transform .05s}
.btn:hover{background:var(--brand2);text-decoration:none;color:#fff}
.btn:active{transform:translateY(1px)}
.btn.small{padding:6px 12px;min-height:34px;font-size:13px}
.btn.outline{background:#fff;color:var(--brand);border-color:var(--brand)}
.btn.outline:hover{background:var(--brand-soft);color:var(--brand2)}
.btn.danger{background:var(--bad)}
.btn.danger:hover{background:#9b1717}
.btn.ghost{background:#eef1f6;color:var(--ink);border-color:var(--line)}
.btn.ghost:hover{background:#e0e6f0;color:var(--ink)}
.btn[disabled],.btn.is-loading{opacity:.65;cursor:not-allowed;pointer-events:none}
.btn.is-loading::after{content:"";width:14px;height:14px;border:2px solid currentColor;border-right-color:transparent;border-radius:50%;animation:spin .7s linear infinite}
input[type=submit].is-loading{opacity:.65;pointer-events:none}
@keyframes spin{to{transform:rotate(360deg)}}

/* 9. Forms ----------------------------------------------------------------- */
form .field,.field{margin-bottom:14px}
label{display:block;font-weight:600;margin-bottom:6px;font-size:13px}
label:has(input[type=checkbox]),label:has(input[type=radio]){display:flex;align-items:center;gap:8px;font-weight:500;font-size:14px}
input,select,textarea{width:100%;min-height:42px;padding:9px 12px;border:1px solid var(--line-strong);border-radius:var(--r-sm);font:inherit;font-size:14px;color:var(--ink);background:#fff;
  transition:border-color .15s,box-shadow .15s}
textarea{min-height:92px;resize:vertical}
input:hover,select:hover,textarea:hover{border-color:#9fb0cc}
input:focus,select:focus,textarea:focus{outline:0;border-color:var(--brand);box-shadow:var(--focus)}
input:user-invalid,select:user-invalid,textarea:user-invalid{border-color:var(--bad)}
input::placeholder,textarea::placeholder{color:#8493a8}
input[type=checkbox],input[type=radio]{width:18px!important;height:18px;min-height:0;padding:0;margin:0;accent-color:var(--brand);flex:none}
select{appearance:none;-webkit-appearance:none;padding-right:38px;cursor:pointer;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235a6a80' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat:no-repeat;background-position:right 12px center;background-size:16px}
input[readonly],textarea[readonly]{background:#f5f7fb;color:#526075}
input:disabled,select:disabled,textarea:disabled{background:#eef1f6;color:#7a8799;cursor:not-allowed}
fieldset{border:1px solid var(--line);border-radius:var(--r);margin:0 0 16px;padding:14px 16px 4px;min-width:0}
legend{font-weight:700;padding:0 6px;color:var(--ink);font-size:14px}
.field small.muted{display:block;margin-top:4px}
.pw-wrap{position:relative;display:block}
.pw-wrap input{padding-right:64px}
.pw-toggle{position:absolute;right:4px;top:50%;transform:translateY(-50%);background:transparent;border:0;color:var(--brand);font:inherit;font-size:13px;font-weight:600;cursor:pointer;padding:8px 10px;border-radius:var(--r-sm);min-height:34px}
.pw-toggle:hover{background:var(--brand-soft)}
.password-checklist{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:4px 12px;list-style:none;margin:8px 0 0;padding:0;color:var(--muted);font-size:12px;line-height:1.4}
.password-checklist li{display:flex;align-items:flex-start;gap:7px;min-width:0}
.password-rule-icon{width:16px;flex:none;text-align:center;color:var(--muted);font-weight:700}
.password-checklist li.is-met,.password-checklist li.is-met .password-rule-icon,.password-requirements-met{color:var(--ok)}
.password-requirements-met{grid-column:1/-1;font-weight:650}
.password-match{display:block;margin-top:5px;font-size:12px}
.password-match.is-matched{color:var(--ok)}
.password-match.is-mismatched{color:var(--bad)}
@media(max-width:420px){.password-checklist{grid-template-columns:1fr}}
.company-directory{margin:0 0 14px;border:1px solid var(--line);border-radius:var(--r-sm);padding:10px 12px;background:var(--bg)}
.company-directory summary{cursor:pointer;color:var(--ink);font-size:13px;font-weight:650}
.company-directory-list{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,220px),1fr));gap:8px;margin-top:10px}
.company-directory-item{display:grid;gap:2px;min-width:0;padding:10px;border:1px solid var(--line);border-radius:var(--r-sm);background:var(--card);font-size:12px;overflow-wrap:anywhere}
.company-directory-item strong{font-size:13px}

/* 10. Alerts & badges ------------------------------------------------------ */
.alert{position:relative;padding:12px 40px 12px 14px;border-radius:var(--r-sm);margin:0 0 14px;border:1px solid transparent;border-left-width:4px;line-height:1.45}
.alert.ok{background:#def7e8;color:#0b5c2e;border-color:#b6e8cb}
.alert.bad{background:#fde2e2;color:#8f1414;border-color:#f6bcbc}
.alert.warn{background:#fff3c4;color:#6f4b00;border-color:#f1de93}
.alert.info{background:#e0ebff;color:#12419f;border-color:#bcd2fb}
.alert-close{position:absolute;right:6px;top:6px;width:32px;height:32px;border:0;background:transparent;color:inherit;font-size:22px;line-height:1;cursor:pointer;border-radius:var(--r-sm);opacity:.7}
.alert-close:hover{opacity:1;background:rgba(0,0,0,.07)}
.badge{display:inline-block;padding:3px 10px;border-radius:20px;font-size:12px;font-weight:700;white-space:nowrap;line-height:1.4}
.badge.ok{background:#def7e8;color:var(--ok)}
.badge.bad{background:#fde2e2;color:var(--bad)}
.badge.warn{background:#fff3c4;color:var(--warn)}
.badge.info{background:#e0ebff;color:var(--info)}
.badge.muted{background:#eef1f6;color:var(--muted)}

/* 11. Pagination ----------------------------------------------------------- */
.pagination{display:flex;flex-wrap:wrap;gap:6px;align-items:center;justify-content:center;padding:12px}
.pagination .btn{min-width:38px;padding-left:10px;padding-right:10px}

/* 12. Auth pages ----------------------------------------------------------- */
body.auth-page{background:linear-gradient(180deg,#e6edfc 0,var(--bg) 360px) no-repeat,var(--bg);min-height:100vh}
.auth-wrap{width:min(100% - 32px,500px);margin:clamp(20px,6vh,64px) auto}
.auth-wrap.wide{width:min(100% - 32px,860px)}
.auth-brand{display:flex;align-items:center;justify-content:center;gap:10px;color:var(--brand2);font-weight:700;font-size:18px;margin-bottom:18px;flex-direction:column}
.auth-brand:hover{text-decoration:none}
.auth-brand .brand-mark{background:var(--brand);color:#fff;width:38px;height:38px}
.auth-wrap .card{padding:clamp(22px,5vw,36px);box-shadow:0 18px 45px rgba(29,50,90,.12);border-radius:16px}
.auth-wrap .card h2{margin:0 0 6px;font-size:clamp(1.35rem,1.1rem + 1vw,1.7rem);color:var(--brand)}
.auth-wrap .btn{width:100%;margin-top:4px;min-height:46px;font-size:15px}
.auth-wrap input{min-height:46px}
.auth-wrap .row{align-items:flex-start}
.auth-wrap .muted{line-height:1.55;margin:14px 0 0}
.auth-wrap .alert{line-height:1.45}
.auth-wrap fieldset .row{margin-bottom:0}
.otp-help{margin:0 0 20px;color:var(--muted);line-height:1.5}
.otp-input{letter-spacing:.35em;text-align:center;font-size:20px;font-weight:700}

/* 13. Landing page --------------------------------------------------------- */
.hero{text-align:center;padding:clamp(28px,6vw,56px) clamp(16px,4vw,32px);background:linear-gradient(180deg,#fff,#f5f8ff)}
.hero h1{margin:0 0 10px;font-size:clamp(1.5rem,1.1rem + 2vw,2.25rem);letter-spacing:-.015em}
.hero p{max-width:640px;margin-left:auto;margin-right:auto}
.hero .btn{margin-top:8px}
.landing-grid .card h3{display:flex;align-items:center;gap:8px}
.topbar-actions .btn.small{min-height:36px}

/* 14. Dialog --------------------------------------------------------------- */
dialog{border:0;border-radius:var(--r);box-shadow:0 20px 55px rgba(20,34,58,.28);width:min(100% - 32px,440px);padding:22px;color:var(--ink);max-height:calc(100vh - 32px);overflow:auto}
dialog::backdrop{background:rgba(18,31,52,.5)}
dialog h3{margin:0 0 8px;font-size:18px}
.dialog-actions{display:flex;justify-content:flex-end;gap:8px;flex-wrap:wrap}
.dialog-actions .btn{width:auto}
.auth-wrap .dialog-actions .btn{width:auto}

.footer{text-align:center;color:var(--muted);padding:20px 16px 28px;padding-bottom:max(28px,env(safe-area-inset-bottom))}

/* 15. Responsive ----------------------------------------------------------- */
/* Tablet landscape / small laptop */
@media (max-width:1100px){
  :root{--sidebar-w:210px}
  .layout{gap:16px}
}
/* Tablet portrait and below: off-canvas sidebar */
@media (max-width:900px){
  .layout{grid-template-columns:minmax(0,1fr);padding-top:16px}
  .menu-btn{display:inline-flex}
  .sidebar{position:fixed;left:0;top:0;bottom:0;width:min(290px,86vw);max-height:none;z-index:60;border-radius:0 var(--r) var(--r) 0;
    padding:14px 12px calc(14px + env(safe-area-inset-bottom));box-shadow:var(--shadow-md);transform:translateX(-102%);visibility:hidden;
    transition:transform .2s ease,visibility 0s linear .2s}
  body.nav-open .sidebar{transform:none;visibility:visible;transition-delay:0s}
  .sidebar a.active::before{left:-12px}
  .side-close{display:inline-flex;align-items:center;justify-content:center;position:absolute;right:8px;top:8px;width:40px;height:40px;border:0;border-radius:var(--r-sm);background:transparent;color:var(--muted);cursor:pointer}
  .side-close:hover{background:var(--brand-soft);color:var(--brand)}
  .sidebar .side-label{padding-right:48px}
  .nav-backdrop{position:fixed;inset:0;background:rgba(18,31,52,.5);z-index:50;opacity:0;visibility:hidden;transition:opacity .2s,visibility 0s linear .2s}
  body.nav-open .nav-backdrop{display:block;opacity:1;visibility:visible;transition-delay:0s}
  body.nav-open{overflow:hidden}
  .user-meta,.user-menu .chev{display:none}
  .user-menu>summary{padding:4px}
}
/* Phones */
@media (max-width:640px){
  body{font-size:15px}
  .layout{padding-left:max(12px,env(safe-area-inset-left));padding-right:max(12px,env(safe-area-inset-right))}
  .topbar-inner{gap:8px;padding-left:max(12px,env(safe-area-inset-left));padding-right:max(12px,env(safe-area-inset-right))}
  .card{padding:14px}
  .row>.field,.row>[style*="flex:"],.row>input,.row>select{flex:1 1 100%!important}
  .row>input[style*="max-width"]{max-width:none!important}
  .row>.btn,.filters>.btn,.row>button{width:100%}
  .filters{grid-template-columns:1fr}
  .grid.kpi{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
  .grid.kpi .card{padding:14px 14px 14px 18px}
  input,select,textarea{font-size:16px}  /* prevents iOS zoom-on-focus */
  .content form[style*="display:inline"]{display:block!important;margin:6px 0!important}
  .content form[style*="display:inline"] .btn{width:100%}
  .dialog-actions{flex-direction:column-reverse}
  .dialog-actions .btn{width:100%}
  .pagination{justify-content:flex-start}
}
@media (max-width:380px){
  .brand-text{display:none}
  .grid.kpi{gap:10px}
}
/* Stacked "card rows" for wide tables on phones (labels added by app.js) */
@media screen and (max-width:640px){
  table.stack,table.stack tbody{display:block;width:100%}
  table.stack tr.stack-head{display:none}
  table.stack tr{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:2px 14px;padding:12px 14px;border-bottom:1px solid var(--line)}
  table.stack tr:last-child{border-bottom:0}
  table.stack td{display:block;padding:6px 0;border:0;min-width:0;overflow-wrap:anywhere;font-size:14px;background:transparent!important}
  table.stack td[data-label]:not([data-label=""])::before{content:attr(data-label);display:block;font-size:11px;font-weight:700;letter-spacing:.04em;text-transform:uppercase;color:var(--muted);margin-bottom:1px}
  table.stack td.cell-full{grid-column:1/-1}
  table.stack td.cell-full:not([colspan]){padding-top:8px}
  table.stack .btn.small{min-height:40px}
  table.stack td input,table.stack td select{margin:3px 0}
  .table-wrap:has(>table.stack){overflow-x:visible}
}
@media (max-width:360px){
  table.stack tr{grid-template-columns:minmax(0,1fr)}
}
/* Touch targets */
@media (pointer:coarse){
  .btn,.btn.small{min-height:44px}
  .sidebar a,.user-panel a{min-height:46px}
  .pagination .btn{min-width:44px}
}

/* 16. Accessibility & motion ----------------------------------------------- */
:focus-visible{outline:2px solid var(--brand);outline-offset:2px}
.topbar :focus-visible{outline-color:#fff}
.btn:focus-visible{outline:0;box-shadow:var(--focus)}
input:focus-visible,select:focus-visible,textarea:focus-visible{outline:0}
@media (prefers-reduced-motion:reduce){
  *,*::before,*::after{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important;scroll-behavior:auto!important}
}

/* 17. Print ---------------------------------------------------------------- */
@media print{
  .sidebar,.topbar,.no-print,.nav-backdrop,.skip-link,.footer,.alert-close{display:none!important}
  body{background:#fff;font-size:12px}
  .layout{display:block;padding:0}
  .card,.table-wrap{box-shadow:none;border-color:#bbb}
  .card,table{break-inside:avoid}
  th{background:#eee!important;color:#000}
  .table-wrap{overflow:visible}
}

/* 19. Futuristic enterprise system ---------------------------------------- */
:root{
  color-scheme:dark;
  --bg:#0b1220;--card:#111c2d;--ink:#e7edf6;--muted:#9aabc0;
  --brand:#59b9ed;--brand2:#35a6df;--brand-soft:#142d42;
  --ok:#45cf9a;--bad:#ff7e88;--warn:#f2c66d;--info:#69c7f3;
  --line:#26364a;--line-strong:#34485e;
  --r:16px;--r-sm:10px;
  --shadow-sm:0 4px 14px rgba(0,0,0,.16);
  --shadow-md:0 18px 48px rgba(0,0,0,.32);
  --focus:0 0 0 3px rgba(89,185,237,.3);
  --topbar-h:68px;--sidebar-w:248px;
}
html{background:var(--bg)}
body{background:radial-gradient(ellipse at 75% -20%,rgba(49,105,151,.15),transparent 42%),var(--bg);color:var(--ink)}
a{color:#77cdf5}
.muted{color:var(--muted)}
.topbar{background:rgba(12,21,35,.96);color:var(--ink);border-bottom:1px solid #223247;box-shadow:0 8px 24px rgba(0,0,0,.16);backdrop-filter:blur(16px)}
.topbar-inner{max-width:1560px}
.brand{color:#edf5fd;font-weight:720;letter-spacing:-.025em}
.brand-mark{background:#142a3e;color:#72cdf4;box-shadow:inset 0 0 0 1px rgba(105,199,243,.18)}
.brand-logo{background:#fff}
.menu-btn{background:#152337;color:#dbe8f5;border:1px solid #2a4057}
.menu-btn:hover,.menu-btn:active{background:#1b344a;color:#8ad7fa}
.icon-link{color:#cad8e8}
.icon-link:hover{background:#172a3d;color:#80d1f6}
.dot{background:#36a9dd;color:#071321;box-shadow:0 0 12px rgba(54,169,221,.4)}
.user-menu>summary{color:#e4edf7}
.user-menu>summary:hover,.user-menu[open]>summary{background:#17283a}
.avatar{background:#17384c;color:#8cddfa;box-shadow:inset 0 0 0 1px rgba(105,199,243,.22)}
.user-role{color:#a8bacd;opacity:1}
.user-panel{background:#111c2d;color:var(--ink);border-color:#2b3d52}
.user-panel a{color:#d7e2ef}
.user-panel a:hover{background:#172d40;color:#82d5f7}
.user-panel a.logout{color:#ff929a}
.user-panel a.logout:hover{background:#3a202b;color:#ff9da4}
.layout{max-width:1560px;gap:24px;padding-top:26px;padding-bottom:30px}
.sidebar{background:linear-gradient(165deg,#111e30 0%,#0e1928 100%);color:#d4e0ee;border:1px solid #22344a;border-radius:18px;
  box-shadow:0 14px 36px rgba(0,0,0,.22)}
.side-label{color:#7f94aa;letter-spacing:.14em}
.sidebar a{color:#bdcadd;border:1px solid transparent;transition:background .16s,color .16s,border-color .16s,transform .16s}
.sidebar a .icon{color:#829bb3}
.sidebar a:hover{background:#17283b;color:#eaf7ff;border-color:#263d53;transform:translateX(2px)}
.sidebar a:hover .icon{color:#75cef4}
.sidebar a.active{color:#9be0fa;background:linear-gradient(100deg,rgba(61,157,204,.19),rgba(61,157,204,.07));border-color:rgba(89,185,237,.2);font-weight:700}
.sidebar a.active .icon{color:#75d5fa}
.sidebar a.active::before{display:block;left:-11px;top:10px;bottom:10px;width:3px;background:#54c4f0;box-shadow:0 0 12px rgba(84,196,240,.55)}
.side-foot{border-color:#25374b;color:#879bb0}
.side-close{color:#b4c5d8}
.side-close:hover{background:#1a3044;color:#8bd9f8}
.page-head{margin-bottom:22px}
.page-kicker{color:#68c9f2;letter-spacing:.16em}
.page-head h1{color:#f0f5fb;letter-spacing:-.04em}
.page-intro{color:#9bacc0}
.page-context{background:#101c2c;border-color:#2b3d51;color:#aebfd2}
.grid{gap:18px}
.card{background:linear-gradient(145deg,rgba(19,31,48,.98),rgba(16,27,43,.98));border-color:#27394e;
  box-shadow:0 6px 20px rgba(0,0,0,.13);transition:transform .18s,border-color .18s,box-shadow .18s}
.card h3{color:#e4edf7}
.grid.kpi .card{border-color:#2a3d52}
.grid.kpi .card:hover{border-color:#3b6985;box-shadow:0 10px 28px rgba(0,0,0,.22);transform:translateY(-2px)}
.grid.kpi .card::before{background:#4cb9e8;box-shadow:0 0 11px rgba(76,185,232,.3)}
.grid.kpi .card:nth-child(3n+2)::before{background:#d8ad5c;box-shadow:0 0 9px rgba(216,173,92,.2)}
.grid.kpi .card:nth-child(3n)::before{background:#8b9dd1;box-shadow:0 0 9px rgba(139,157,209,.2)}
.grid.kpi .card::after{background:rgba(73,174,222,.07)}
.kpi-num{color:#80d3f6}
.grid.kpi .card:nth-child(3n+2) .kpi-num{color:#e6c77e}
.kpi-label{color:#9dafc3}
.progress{background:#26384b}
.progress>div{background:linear-gradient(90deg,#2186bd,#63d2f5);box-shadow:0 0 12px rgba(77,190,235,.26)}
.notif-item{border-color:#26384b}
.notif-item.unread{background:#152b3d}
.table-wrap{background:#101a29;border-color:#293b50;box-shadow:0 5px 16px rgba(0,0,0,.12)}
.card .table-wrap{box-shadow:none}
table{background:#101a29}
th,td{border-bottom-color:#26364a;color:#cfdae7}
th{background:#172538;color:#9fb3c8}
tbody tr:hover>td{background:#16263a}
.btn{background:#1688bd;color:#f5fbff;box-shadow:0 3px 12px rgba(22,136,189,.18)}
.btn:hover{background:#20a0d6;color:#fff;box-shadow:0 5px 18px rgba(32,160,214,.28)}
.btn.outline{background:transparent;color:#8bd9f8;border-color:#3a718d}
.btn.outline:hover{background:#142d40;color:#b5edff;border-color:#55a9d0}
.btn.ghost{background:#1a293b;color:#cdd9e7;border-color:#31445a}
.btn.ghost:hover{background:#22364c;color:#f0f6fc}
.btn.danger{background:#a83c4b;color:#fff}
.btn.danger:hover{background:#c74e5c}
input,select,textarea{background:#0d1827;color:#e2ebf5;border-color:#34485d}
input:hover,select:hover,textarea:hover{border-color:#4a6a84}
input:focus,select:focus,textarea:focus{background:#101d2d;border-color:#56b8e7}
input::placeholder,textarea::placeholder{color:#7489a0}
input[readonly],textarea[readonly]{background:#152234;color:#a9b8ca}
input:disabled,select:disabled,textarea:disabled{background:#172334;color:#788ba1}
fieldset{border-color:#2d4055}
legend{color:#dce7f3}
.pw-toggle{color:#83d5f5}
.pw-toggle:hover{background:#172d40}
.alert.ok{background:#112b28;color:#83dfb7;border-color:#245447}
.alert.bad{background:#351d29;color:#ffabb0;border-color:#70404c}
.alert.warn{background:#332b1b;color:#f3d68c;border-color:#66522b}
.alert.info{background:#142b3c;color:#9bdcf7;border-color:#2d5870}
.badge.ok{background:#16372f;color:#85e2b9}
.badge.bad{background:#3b222b;color:#ffabb0}
.badge.warn{background:#3b321e;color:#f5d98e}
.badge.info{background:#173246;color:#96dcf8}
.badge.muted{background:#253348;color:#b4c2d2}
.pagination{color:#bdcada}
.pagination .btn.outline{background:#111d2c}
body.auth-page{background:radial-gradient(ellipse at 50% -15%,rgba(39,113,155,.24),transparent 48%),#0b1220}
.auth-wrap{color:var(--ink)}
.auth-brand{color:#e7f0fa}
.auth-brand .brand-mark{background:#132b40;color:#82d7f7}
.auth-wrap .card{background:linear-gradient(150deg,#142135,#101a2a);border:1px solid #2b4056;box-shadow:0 22px 64px rgba(0,0,0,.4)}
.auth-wrap .card h2{color:#edf5fc}
.auth-wrap .muted{color:#9aacc0}
.auth-wrap .alert{color:inherit}
.auth-wrap .alert a{color:inherit;text-decoration:underline}
.auth-wrap .field small.muted{color:#9aacc0}
.otp-help{color:#a9b9cb}
dialog{background:#111d2d;color:#e6edf6;border:1px solid #2b3f54}
dialog::backdrop{background:rgba(2,8,15,.74)}
dialog h3{color:#f0f5fb}
body:not(.auth-page) .hero{background:
  radial-gradient(circle at 89% 16%,rgba(87,203,244,.12) 0 8%,transparent 8.2%),
  radial-gradient(circle at 100% 110%,rgba(69,176,226,.18) 0 23%,transparent 23.2%),
  linear-gradient(118deg,#101a2a 0%,#14283c 58%,#12364b 100%);
  border:1px solid #2b5269;box-shadow:0 16px 38px rgba(0,0,0,.22)}
body:not(.auth-page) .hero h1{color:#f2f7fc}
body:not(.auth-page) .hero .muted{color:#b2c8d9}
body:not(.auth-page) .hero .btn{background:#178ab9;color:#f4fbff;box-shadow:0 3px 14px rgba(23,138,185,.2)}
body:not(.auth-page) .hero .btn:hover{background:#21a7d8;color:#fff}
.landing-grid .card{min-height:150px}
.footer{color:#71859c}
.skip-link{background:#142236;color:#a4e3fa}
:focus-visible{outline-color:#66d2fa}
.topbar :focus-visible{outline-color:#75d8fb}
.btn:focus-visible{box-shadow:0 0 0 3px rgba(88,199,242,.38)}
.nav-backdrop{background:rgba(2,8,15,.75)}
@media(max-width:900px){
  .sidebar{background:linear-gradient(165deg,#111e30 0%,#0e1928 100%);border-color:#26384d}
  .sidebar a.active::before{display:block;left:-12px}
}
@media(max-width:640px){
  .page-context{display:none}
  .grid.kpi .card{min-height:98px}
  .sidebar{box-shadow:18px 0 48px rgba(0,0,0,.4)}
}
@media print{
  :root{color-scheme:light}
  body{background:#fff;color:#000}
  .card,.table-wrap,table{background:#fff;color:#000}
  td{color:#000}
  .page-head h1,.card h3{color:#000}
}

/* 18. OJT workspace refresh ----------------------------------------------- */
:root{
  --bg:#f3f6fa;--card:#fff;--ink:#172b45;--muted:#68798e;
  --brand:#176b66;--brand2:#10514e;--brand-soft:#e3f3f0;
  --ok:#18794e;--bad:#b83b45;--warn:#946200;--info:#176b66;
  --line:#e2e9ef;--line-strong:#c9d5df;
  --r:16px;--r-sm:10px;
  --shadow-sm:0 2px 8px rgba(23,43,69,.045);
  --shadow-md:0 16px 36px rgba(23,43,69,.14);
  --focus:0 0 0 3px rgba(23,107,102,.22);
  --topbar-h:68px;--sidebar-w:248px;
}
body{background:var(--bg);color:var(--ink)}
a{color:var(--brand)}
.topbar{background:rgba(255,255,255,.96);color:var(--ink);box-shadow:0 1px 0 var(--line);backdrop-filter:blur(14px)}
.topbar-inner{max-width:1480px;min-height:var(--topbar-h);gap:16px}
.brand{color:var(--ink);font-size:16px;letter-spacing:-.02em}
.brand-mark{background:var(--brand-soft);color:var(--brand);border-radius:11px;width:38px;height:38px}
.brand-logo{width:38px;height:38px;border-radius:11px;box-shadow:none}
.menu-btn{background:var(--bg);color:var(--ink);border:1px solid var(--line)}
.menu-btn:hover,.menu-btn:active{background:var(--brand-soft);color:var(--brand)}
.icon-link{color:var(--ink)}
.icon-link:hover{background:var(--brand-soft);color:var(--brand)}
.dot{background:#df9b36;color:#fff}
.user-menu>summary{color:var(--ink);padding:5px 10px 5px 5px}
.user-menu>summary:hover,.user-menu[open]>summary{background:var(--bg)}
.avatar{background:#dcefeb;color:var(--brand)}
.user-role{color:var(--muted);opacity:1}
.user-panel{border-color:var(--line);box-shadow:0 18px 42px rgba(23,43,69,.16)}
.layout{max-width:1480px;gap:24px;padding-top:26px;padding-bottom:28px}
.sidebar{background:#172b45;color:#fff;border:0;border-radius:18px;padding:14px 11px;top:calc(var(--topbar-h) + 20px);
  max-height:calc(100vh - var(--topbar-h) - 40px);box-shadow:0 12px 30px rgba(18,38,61,.12)}
.side-label{color:#9eafc2;padding:10px 13px 12px;letter-spacing:.12em}
.sidebar a{color:#dbe5ef;margin:3px 0;padding:11px 13px;min-height:44px;border-radius:11px;font-size:14px;transition:background .16s,color .16s,transform .16s}
.sidebar a .icon{color:#9fb2c5}
.sidebar a:hover{background:rgba(255,255,255,.09);color:#fff;transform:translateX(2px)}
.sidebar a:hover .icon{color:#fff}
.sidebar a.active{background:#e3f3f0;color:#155d58;font-weight:700}
.sidebar a.active .icon{color:#176b66}
.sidebar a.active::before{display:none}
.side-foot{border-color:rgba(255,255,255,.12);color:#aebdcd;padding:14px 13px 5px}
.side-close{color:#fff}
.side-close:hover{background:rgba(255,255,255,.1);color:#fff}
.page-head{display:flex;align-items:center;justify-content:space-between;gap:18px;margin:0 0 22px;padding:2px 0 5px}
.page-kicker{display:block;color:var(--brand);font-size:11px;font-weight:800;letter-spacing:.14em;text-transform:uppercase}
.page-head h1{margin:5px 0 0;font-size:clamp(1.65rem,1.25rem + 1.15vw,2.1rem);font-weight:760;letter-spacing:-.045em;color:#172b45}
.page-intro{margin:6px 0 0;color:var(--muted);font-size:14px}
.page-context{flex:none;padding:9px 13px;border:1px solid var(--line);border-radius:999px;background:#fff;color:#607388;font-size:12px;font-weight:700}
.grid{gap:18px}
.grid.kpi{grid-template-columns:repeat(auto-fit,minmax(180px,1fr))}
.content>:is(.card,.grid,.table-wrap)+:is(.card,.grid,.table-wrap){margin-top:18px!important}
.card{border-color:#e5ebf1;border-radius:16px;padding:21px;box-shadow:0 3px 12px rgba(23,43,69,.045);transition:box-shadow .18s,border-color .18s,transform .18s}
.card h3{font-size:15px;letter-spacing:-.01em;color:#203750}
.grid.kpi .card{padding:19px 18px;min-height:108px;border-radius:15px}
.grid.kpi .card::before{left:0;top:17px;bottom:17px;width:3px;border-radius:0 3px 3px 0;background:var(--brand)}
.grid.kpi .card::after{content:"";position:absolute;right:-19px;bottom:-32px;width:92px;height:92px;border-radius:50%;background:rgba(23,107,102,.055)}
.grid.kpi .card:nth-child(3n+2)::before{background:#d49a3a}
.grid.kpi .card:nth-child(3n)::before{background:#7188b1}
.kpi-num{position:relative;z-index:1;color:#1b5f5b;font-size:clamp(1.55rem,1.2rem + 1vw,2rem);font-weight:780;letter-spacing:-.045em}
.kpi-label{position:relative;z-index:1;margin-top:7px;font-size:12px;font-weight:650;letter-spacing:.015em;color:#718196}
.progress{height:11px;background:#e8eeef;border-radius:99px}
.progress>div{background:linear-gradient(90deg,#176b66,#47a59a);border-radius:99px}
.notif-item.unread{background:#f0f8f6}
.table-wrap{border-color:#e4ebf0;border-radius:13px;box-shadow:0 2px 8px rgba(23,43,69,.035)}
.card .table-wrap{border-radius:11px}
th,td{padding:12px 15px;border-bottom-color:#eaf0f3}
th{background:#f5f8fa;color:#6a7b8d;font-size:10px;letter-spacing:.1em}
tbody tr:hover>td{background:#f7fbfa}
.btn{border-radius:10px;background:var(--brand);box-shadow:0 2px 5px rgba(23,107,102,.12);font-weight:650;transition:background-color .16s,border-color .16s,box-shadow .16s,transform .12s}
.btn:hover{background:var(--brand2);box-shadow:0 5px 12px rgba(23,107,102,.16);transform:translateY(-1px)}
.btn.outline{background:#fff;color:var(--brand);border-color:#bdd7d3;box-shadow:none}
.btn.outline:hover{background:var(--brand-soft);color:var(--brand2)}
.btn.ghost{background:#f3f6f8;border-color:#e3eaf0;box-shadow:none}
.btn.ghost:hover{background:#e8eff2;transform:none}
input,select,textarea{border-color:#d5e0e7;border-radius:10px;background:#fff}
input:focus,select:focus,textarea:focus{border-color:var(--brand);box-shadow:var(--focus)}
fieldset{border-color:#dce6eb;border-radius:13px}
.alert{border-radius:11px}
.badge{padding:4px 10px;font-size:11px;letter-spacing:.01em}
.badge.ok{background:#e6f5ed;color:#18794e}
.badge.bad{background:#fbeaec;color:#b83b45}
.badge.warn{background:#fff5dd;color:#946200}
.badge.info{background:#e5f3f1;color:#176b66}
.badge.muted{background:#eef2f5;color:#68798e}
.auth-wrap .card{border:1px solid #e5ebf1;box-shadow:0 20px 55px rgba(23,43,69,.12);border-radius:20px}
.auth-wrap .card h2{color:var(--ink);letter-spacing:-.035em}
body.auth-page{background:radial-gradient(ellipse at 50% 0%,#e2f2ef 0,transparent 48%),var(--bg)}
.auth-brand{color:var(--ink)}
body:not(.auth-page) .hero{border:0;border-radius:20px;text-align:left;color:#fff;background:
  radial-gradient(circle at 91% 20%,rgba(255,255,255,.14) 0 7%,transparent 7.2%),
  radial-gradient(circle at 100% 110%,rgba(100,197,179,.22) 0 21%,transparent 21.2%),
  linear-gradient(115deg,#173950 0%,#176b66 100%);box-shadow:0 16px 34px rgba(23,75,82,.16)}
body:not(.auth-page) .hero h1{max-width:760px;font-size:clamp(1.8rem,1.35rem + 1.4vw,2.5rem);letter-spacing:-.04em}
body:not(.auth-page) .hero .muted{color:#d3e8e6}
body:not(.auth-page) .hero .btn{background:#fff;color:#155d58;box-shadow:none}
body:not(.auth-page) .hero .btn:hover{background:#eaf6f4}
.grid.two.landing-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
.landing-grid .card{min-height:150px}
.landing-grid .card h3{font-size:16px}
.footer{color:#8a98a8;font-size:12px;padding-top:12px}
:focus-visible{outline-color:var(--brand)}
.topbar :focus-visible{outline-color:var(--brand)}
@media (max-width:1100px){
  .layout{gap:18px}
}
@media (max-width:900px){
  .layout{padding-top:20px}
  .sidebar{background:#172b45;border-radius:0 18px 18px 0}
  .sidebar a.active::before{display:none}
  .nav-backdrop{background:rgba(13,29,48,.56)}
}
@media (max-width:640px){
  :root{--topbar-h:60px}
  .topbar-inner{min-height:var(--topbar-h)}
  .layout{padding-top:17px}
  .page-head{align-items:flex-start;margin-bottom:18px}
  .page-head h1{font-size:1.65rem}
  .page-context{display:none}
  .card{padding:17px}
  .grid.kpi .card{min-height:98px;padding:15px 12px 15px 16px}
  .kpi-label{font-size:11px;line-height:1.35}
  .hero{padding:27px 20px}
  .landing-grid{grid-template-columns:minmax(0,1fr)}
}
@media (max-width:760px){
  .grid.two.landing-grid{grid-template-columns:minmax(0,1fr)}
}
@media print{
  .sidebar,.topbar,.no-print,.nav-backdrop,.skip-link,.footer,.alert-close{display:none!important}
  body{background:#fff;font-size:12px}
  .layout{display:block;padding:0}
  .card,.table-wrap{box-shadow:none;border-color:#bbb}
  .card,table{break-inside:avoid}
  th{background:#eee!important;color:#000}
  .table-wrap{overflow:visible}
}

/* Final palette layer keeps legacy compatibility rules on the same theme. */
:root{color-scheme:dark;--bg:#0b1220;--card:#111c2d;--ink:#e7edf6;--muted:#9aabc0;
  --brand:#59b9ed;--brand2:#35a6df;--brand-soft:#142d42;--ok:#45cf9a;--bad:#ff7e88;
  --warn:#f2c66d;--info:#69c7f3;--line:#26364a;--line-strong:#34485e;--focus:0 0 0 3px rgba(89,185,237,.3)}
body{background:radial-gradient(ellipse at 75% -20%,rgba(49,105,151,.15),transparent 42%),var(--bg);color:var(--ink)}
a{color:#77cdf5}
.topbar{background:rgba(12,21,35,.96);color:var(--ink);border-bottom:1px solid #223247;box-shadow:0 8px 24px rgba(0,0,0,.16)}
.brand,.user-menu>summary{color:#edf5fd}
.brand-mark{background:#142a3e;color:#72cdf4}
.menu-btn{background:#152337;color:#dbe8f5;border-color:#2a4057}
.icon-link{color:#cad8e8}
.avatar{background:#17384c;color:#8cddfa}
.user-panel{background:#111c2d;color:var(--ink);border-color:#2b3d52}
.layout{max-width:1560px}
.sidebar{background:linear-gradient(165deg,#111e30,#0e1928);border:1px solid #22344a}
.side-label{color:#9aabc0}
.sidebar a{color:#bdcadd;border-color:transparent}
.sidebar a .icon{color:#829bb3}
.sidebar a:hover{background:#17283b;color:#eaf7ff;border-color:#263d53}
.sidebar a.active{color:#9be0fa;background:linear-gradient(100deg,rgba(61,157,204,.19),rgba(61,157,204,.07));border-color:rgba(89,185,237,.2)}
.sidebar a.active .icon{color:#75d5fa}
.sidebar a.active::before{display:block;background:#54c4f0;box-shadow:0 0 12px rgba(84,196,240,.55)}
.side-foot{border-color:#25374b;color:#aebdcd}
.page-kicker{color:#68c9f2}
.page-head h1{color:#f0f5fb}
.page-intro{color:#9bacc0}
.page-context{background:#101c2c;border-color:#2b3d51;color:#aebfd2}
.card{background:linear-gradient(145deg,rgba(19,31,48,.98),rgba(16,27,43,.98));border-color:#27394e}
.card h3{color:#e4edf7}
.grid.kpi .card{border-color:#2a3d52}
.grid.kpi .card::before{background:#4cb9e8;box-shadow:0 0 11px rgba(76,185,232,.3)}
.grid.kpi .card::after{background:rgba(73,174,222,.07)}
.kpi-num{color:#80d3f6}
.kpi-label{color:#9dafc3}
.progress{background:#26384b}
.progress>div{background:linear-gradient(90deg,#2186bd,#63d2f5)}
.table-wrap,table{background:#101a29;border-color:#293b50}
th,td{border-bottom-color:#26364a;color:#cfdae7}
th{background:#172538;color:#9fb3c8}
tbody tr:hover>td{background:#16263a}
.btn{background:#1688bd;color:#f5fbff}
.btn:hover{background:#20a0d6;color:#fff}
.btn.outline{background:transparent;color:#8bd9f8;border-color:#3a718d}
.btn.ghost{background:#1a293b;color:#cdd9e7;border-color:#31445a}
.btn.danger{background:#a83c4b;color:#fff}
input,select,textarea{background:#0d1827;color:#e2ebf5;border-color:#34485d}
input:hover,select:hover,textarea:hover{border-color:#4a6a84}
input:focus,select:focus,textarea:focus{background:#101d2d;border-color:#56b8e7}
input::placeholder,textarea::placeholder{color:#7489a0}
input[readonly],textarea[readonly]{background:#152234;color:#a9b8ca}
input:disabled,select:disabled,textarea:disabled{background:#172334;color:#a0aec0}
fieldset{border-color:#2d4055}
legend{color:#dce7f3}
.pw-toggle{color:#83d5f5}
.alert.ok{background:#112b28;color:#83dfb7;border-color:#245447}
.alert.bad{background:#351d29;color:#ffabb0;border-color:#70404c}
.alert.warn{background:#332b1b;color:#f3d68c;border-color:#66522b}
.alert.info{background:#142b3c;color:#9bdcf7;border-color:#2d5870}
.badge.ok{background:#16372f;color:#85e2b9}
.badge.bad{background:#3b222b;color:#ffabb0}
.badge.warn{background:#3b321e;color:#f5d98e}
.badge.info{background:#173246;color:#96dcf8}
.badge.muted{background:#253348;color:#b4c2d2}
body.auth-page{background:radial-gradient(ellipse at 50% -15%,rgba(39,113,155,.24),transparent 48%),#0b1220}
.auth-brand{color:#e7f0fa}
.auth-wrap .card{background:linear-gradient(150deg,#142135,#101a2a);border-color:#2b4056;box-shadow:0 22px 64px rgba(0,0,0,.4)}
.auth-wrap .card h2{color:#edf5fc}
.auth-wrap .muted,.otp-help{color:#9aacc0}
dialog{background:#111d2d;color:#e6edf6;border-color:#2b3f54}
body:not(.auth-page) .hero{background:radial-gradient(circle at 89% 16%,rgba(87,203,244,.12) 0 8%,transparent 8.2%),
  radial-gradient(circle at 100% 110%,rgba(69,176,226,.18) 0 23%,transparent 23.2%),
  linear-gradient(118deg,#101a2a 0%,#14283c 58%,#12364b 100%);border:1px solid #2b5269}
body:not(.auth-page) .hero h1{color:#f2f7fc}
body:not(.auth-page) .hero .muted{color:#b2c8d9}
body:not(.auth-page) .hero .btn{background:#178ab9;color:#f4fbff}
.footer{color:#879bb0}
:focus-visible{outline-color:#66d2fa}
.topbar :focus-visible{outline-color:#75d8fb}
.nav-backdrop{background:rgba(2,8,15,.75)}
@media(max-width:900px){.sidebar{background:linear-gradient(165deg,#111e30,#0e1928);border-color:#26384d}
  .sidebar a.active::before{display:block}}
@media print{:root{color-scheme:light}body{background:#fff;color:#000}
  .card,.table-wrap,table{background:#fff;color:#000}td{color:#000}.page-head h1,.card h3{color:#000}}

/* Public landing page ----------------------------------------------------- */
html:has(body.landing-page){scroll-behavior:smooth;scroll-padding-top:88px}
body.landing-page{--landing-ink:#eef5fc;--landing-muted:#a5b6c9;--landing-line:#26384d;--landing-panel:#111d2c;
  min-height:100vh;overflow-x:hidden;background:#0b1220;color:var(--landing-ink)}
.landing-page a{color:inherit}
.landing-page .skip-link:focus{z-index:120}
.landing-container{width:min(1160px,calc(100% - 48px));margin-inline:auto}
.landing-nav{position:sticky;top:0;z-index:100;background:rgba(10,18,31,.9);border-bottom:1px solid rgba(134,164,194,.13);backdrop-filter:blur(18px)}
.landing-nav-inner{width:min(1240px,calc(100% - 48px));min-height:76px;margin:auto;display:flex;align-items:center;justify-content:space-between;gap:28px}
.landing-brand{display:inline-flex;align-items:center;gap:11px;color:#edf5fd;font-weight:720;letter-spacing:-.025em;text-decoration:none;white-space:nowrap}
.landing-brand:hover{text-decoration:none}
.landing-brand img{width:36px;height:36px;object-fit:cover;border-radius:11px;background:#fff}
.landing-navigation{display:flex;align-items:center;gap:clamp(18px,3vw,38px)}
.landing-navigation>a,.landing-login{font-size:13px;font-weight:550;color:#b5c3d3;text-decoration:none;transition:color .18s}
.landing-navigation>a:hover,.landing-login:hover{color:#85d7fb;text-decoration:none}
.landing-nav-actions{display:flex;align-items:center;gap:24px;margin-left:8px}
.landing-cta{display:inline-flex;align-items:center;justify-content:center;gap:12px;min-height:48px;padding:0 21px;border:1px solid #41b6e4;border-radius:10px;
  background:linear-gradient(135deg,#198fc2,#1674aa);box-shadow:0 8px 24px rgba(20,137,189,.19);color:#f5fbff!important;
  font-size:14px;font-weight:700;text-decoration:none;transition:transform .18s,box-shadow .18s,background .18s}
.landing-cta:hover{transform:translateY(-2px);background:linear-gradient(135deg,#20a5d9,#1989c0);box-shadow:0 12px 30px rgba(20,137,189,.29);text-decoration:none}
.landing-cta span{font-size:17px;line-height:1}
.landing-cta--nav{min-height:40px;padding:0 16px;font-size:13px}
.landing-menu-toggle{display:none;width:42px;height:42px;align-items:center;justify-content:center;padding:0;border:1px solid #2a3c50;border-radius:10px;background:#111f31;color:#dce9f5}
.landing-menu-toggle svg{width:21px;height:21px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round}
.landing-hero{position:relative;isolation:isolate;overflow:hidden;padding:92px 0 82px;background:radial-gradient(ellipse at 78% 42%,rgba(35,113,158,.19),transparent 38%),linear-gradient(180deg,#0d1726,#0b1220)}
.landing-hero::before{position:absolute;z-index:-1;inset:0;content:"";opacity:.17;background-image:linear-gradient(rgba(120,161,197,.13) 1px,transparent 1px),linear-gradient(90deg,rgba(120,161,197,.13) 1px,transparent 1px);background-size:56px 56px;mask-image:linear-gradient(90deg,transparent 14%,#000 100%)}
.landing-hero-glow{position:absolute;z-index:-1;top:4%;right:-190px;width:620px;height:620px;border:1px solid rgba(86,190,233,.1);border-radius:50%;box-shadow:0 0 0 64px rgba(86,190,233,.025),0 0 0 128px rgba(86,190,233,.02);pointer-events:none}
.landing-hero-grid{display:grid;grid-template-columns:minmax(0,.94fr) minmax(0,1.06fr);align-items:center;gap:56px}
.landing-hero-copy{position:relative;z-index:2}
.landing-eyebrow{display:flex;align-items:center;gap:10px;margin:0 0 22px;color:#83cde9;font-size:10px;font-weight:760;letter-spacing:.17em;line-height:1.5}
.landing-eyebrow>span{display:inline-block;width:7px;height:7px;flex:none;border-radius:50%;background:#53caee;box-shadow:0 0 12px rgba(83,202,238,.8)}
.landing-hero h1{max-width:610px;margin:0;color:#f3f7fc;font-size:clamp(2.8rem,5.2vw,4.55rem);font-weight:760;letter-spacing:-.065em;line-height:1.045}
.landing-hero h1 span{color:#67c9ed}
.landing-lead{max-width:510px;margin:24px 0 0;color:#a8b8cb;font-size:16px;line-height:1.8}
.landing-hero-actions{display:flex;align-items:center;gap:24px;flex-wrap:wrap;margin-top:30px}
.landing-secondary{display:inline-flex;align-items:center;gap:10px;color:#d1deeb!important;font-size:13px;font-weight:650;text-decoration:none}
.landing-secondary:hover{color:#83d7fa!important;text-decoration:none}
.landing-play{display:inline-flex;width:28px;height:28px;align-items:center;justify-content:center;border:1px solid #344c63;border-radius:50%;color:#83d7fa;font-size:16px;transition:background .18s,border-color .18s}
.landing-secondary:hover .landing-play{background:#173147;border-color:#4c91b3}
.landing-trust-note{display:flex;align-items:center;gap:9px;margin-top:33px;color:#8094aa;font-size:11px;letter-spacing:.015em}
.landing-trust-note span{color:#67c9ed}
.landing-preview-wrap{position:relative;min-width:0;padding:4px 0 24px}
.landing-orbit{position:absolute;z-index:-1;top:50%;left:50%;width:440px;height:440px;border:1px solid rgba(79,179,224,.14);border-radius:50%;transform:translate(-50%,-50%);pointer-events:none}
.landing-orbit--two{width:540px;height:540px;border-color:rgba(79,179,224,.075)}
.landing-preview{position:relative;overflow:hidden;border:1px solid #30465c;border-radius:15px;background:#101c2b;box-shadow:0 35px 90px rgba(0,0,0,.48),0 0 44px rgba(33,130,175,.1);transform:perspective(1200px) rotateY(-4deg) rotateX(1.4deg)}
.preview-topbar{height:42px;display:flex;align-items:center;justify-content:space-between;padding:0 15px;border-bottom:1px solid #26384c;background:#121f2f}
.preview-brand{display:flex;align-items:center;gap:8px;color:#cedbea;font-size:10px;font-weight:700}
.preview-brand-mark{display:inline-flex;width:19px;height:19px;align-items:center;justify-content:center;border:1px solid #2c718e;border-radius:6px;background:#16354a;color:#80d9f8;font-size:10px}
.preview-window-dots{display:flex;gap:5px}.preview-window-dots i{width:5px;height:5px;border-radius:50%;background:#52677c}
.preview-body{min-height:350px;display:grid;grid-template-columns:128px minmax(0,1fr)}
.preview-sidebar{padding:17px 10px;border-right:1px solid #233548;background:#0e1927}
.preview-nav-item{display:flex;align-items:center;gap:8px;margin:4px 0;padding:9px 8px;border:1px solid transparent;border-radius:6px;color:#8295a9;font-size:8px}
.preview-nav-item i{width:10px;height:10px;border:1px solid #51677c;border-radius:3px}
.preview-nav-item--active{background:#153044;border-color:#254b62;color:#9fe1fa}
.preview-nav-item--active i{border-color:#5dc7ed;background:#27789c;box-shadow:0 0 8px rgba(93,199,237,.3)}
.preview-content{min-width:0;padding:18px 17px}
.preview-heading{display:flex;justify-content:space-between;align-items:center}
.preview-heading>span{display:grid;gap:5px}.preview-heading small,.preview-panel small,.preview-activity small{color:#7e94aa;font-size:7px;letter-spacing:.12em}
.preview-heading b{color:#e3edf7;font-size:14px}
.preview-heading>i{width:24px;height:24px;border:1px solid #334a60;border-radius:50%;background:linear-gradient(135deg,#29445a,#172b3d)}
.preview-stat-row{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:9px;margin-top:17px}
.preview-stat{display:grid;gap:8px;padding:11px 10px;border:1px solid #293c50;border-radius:8px;background:#142235}
.preview-stat i{width:15px;height:15px;border:1px solid #267092;border-radius:5px;background:#173d53}
.preview-stat b{width:46%;height:8px;border-radius:5px;background:#7c94ab}
.preview-stat em{width:70%;height:5px;border-radius:5px;background:#34495e}
.preview-panels{display:grid;grid-template-columns:1.2fr 1fr;gap:9px;margin-top:10px}
.preview-panel{display:grid;align-content:start;gap:10px;min-height:115px;padding:12px;border:1px solid #293c50;border-radius:8px;background:#121f30}
.preview-panel>b{color:#dce7f3;font-size:9px}
.preview-progress{height:6px;overflow:hidden;border-radius:8px;background:#25374a}
.preview-progress i{display:block;width:64%;height:100%;border-radius:8px;background:linear-gradient(90deg,#238bb9,#61ccef)}
.preview-panel em,.preview-status-panel>span{color:#879bb0;font-size:7px;font-style:normal}
.preview-status-panel>b{display:flex;align-items:center;gap:6px}.preview-status-panel>b i{width:6px;height:6px;border-radius:50%;background:#5cce9c;box-shadow:0 0 7px rgba(92,206,156,.4)}
.preview-activity{display:grid;gap:8px;margin-top:13px;padding:10px 12px;border:1px solid #293c50;border-radius:8px;background:#121f30}
.preview-activity>span{display:flex;align-items:center;gap:8px}
.preview-activity>span i{width:6px;height:6px;border-radius:50%;background:#58bde3}
.preview-activity>span b{width:58%;height:5px;border-radius:5px;background:#30445a}
.preview-caption{display:flex;align-items:center;justify-content:center;gap:7px;margin:15px 0 0;color:#8298ac;font-size:10px}
.preview-caption span{color:#6dcbed}
.landing-section{padding:94px 0}
.landing-section-heading{max-width:640px}
.landing-section-heading .landing-eyebrow{margin-bottom:16px}
.landing-section-heading h2,.landing-final-cta h2{margin:0;color:#edf4fb;font-size:clamp(2rem,3.3vw,2.8rem);font-weight:730;letter-spacing:-.05em;line-height:1.14}
.landing-section-heading>p:not(.landing-eyebrow),.landing-final-cta-inner>div>p:not(.landing-eyebrow){margin:15px 0 0;color:#9dafc2;font-size:14px;line-height:1.8}
.landing-platform{position:relative;border-top:1px solid rgba(134,164,194,.1);border-bottom:1px solid rgba(134,164,194,.1);background:linear-gradient(180deg,#0e1826,#101b2a)}
.landing-platform .landing-section-heading{margin:0 auto 42px;text-align:center}
.landing-platform .landing-eyebrow{justify-content:center}
.landing-feature-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}
.landing-feature{min-height:198px;padding:23px;border:1px solid #27394d;border-radius:13px;background:linear-gradient(145deg,rgba(19,32,49,.94),rgba(15,26,41,.94));transition:transform .2s,border-color .2s,box-shadow .2s}
.landing-feature:hover{transform:translateY(-4px);border-color:#3b657e;box-shadow:0 13px 30px rgba(0,0,0,.2)}
.landing-feature-icon{display:inline-flex;width:41px;height:41px;align-items:center;justify-content:center;border:1px solid #294a60;border-radius:11px;background:#142a3d;color:#72d1f2}
.landing-feature-icon svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.65;stroke-linecap:round;stroke-linejoin:round}
.landing-feature h3{margin:20px 0 8px;color:#e5eef7;font-size:15px;font-weight:680}
.landing-feature p{max-width:310px;margin:0;color:#9aadc1;font-size:12px;line-height:1.75}
.landing-workflow{background:#0b1220}
.landing-workflow-grid{display:grid;grid-template-columns:.78fr 1.22fr;gap:90px;align-items:start}
.landing-workflow-heading{position:sticky;top:112px}
.landing-steps{position:relative;display:grid;gap:0;margin:0;padding:0;list-style:none}
.landing-steps::before{position:absolute;top:26px;bottom:29px;left:24px;width:1px;background:linear-gradient(#3bb7e2,#2e475e 75%,transparent);content:""}
.landing-steps li{position:relative;display:grid;grid-template-columns:50px minmax(0,1fr);gap:18px;padding:0 0 27px}
.landing-steps li:last-child{padding-bottom:0}
.landing-step-number{position:relative;z-index:1;display:flex;width:49px;height:49px;align-items:center;justify-content:center;border:1px solid #344b61;border-radius:50%;background:#101c2b;color:#83d8f8;font-size:11px;font-weight:700;box-shadow:0 0 0 6px #0b1220}
.landing-steps li:first-child .landing-step-number{border-color:#3985a6;background:#153147;box-shadow:0 0 0 6px #0b1220,0 0 20px rgba(67,183,224,.15)}
.landing-steps h3{margin:4px 0 7px;color:#e5edf6;font-size:15px;font-weight:680}
.landing-steps p{margin:0;color:#9aacc0;font-size:12px;line-height:1.75}
.landing-benefits{border-top:1px solid rgba(134,164,194,.1);background:radial-gradient(ellipse at 10% 50%,rgba(28,96,133,.12),transparent 45%),#0e1826}
.landing-benefits-grid{display:grid;grid-template-columns:1fr 1fr;gap:90px;align-items:center}
.landing-text-link{display:inline-flex;align-items:center;gap:11px;margin-top:25px;color:#80d5f5!important;font-size:13px;font-weight:680;text-decoration:none}
.landing-text-link:hover{color:#b3edff!important;text-decoration:none}
.landing-benefit-list{display:grid;gap:0;margin:0;padding:0;list-style:none}
.landing-benefit-list li{display:flex;gap:16px;padding:17px 0;border-bottom:1px solid rgba(128,154,182,.13)}
.landing-benefit-list li:last-child{border-bottom:0}
.landing-benefit-list li>span{display:flex;width:23px;height:23px;flex:none;align-items:center;justify-content:center;border:1px solid #286a83;border-radius:50%;background:#123044;color:#80d9f7;font-size:12px;font-weight:800}
.landing-benefit-list li div{display:grid;gap:5px}
.landing-benefit-list b{color:#e1ebf5;font-size:13px;font-weight:650}
.landing-benefit-list small{color:#91a5ba;font-size:11px;line-height:1.6}
.landing-final-cta{padding:52px 0;border-top:1px solid rgba(134,164,194,.1);background:linear-gradient(110deg,#112439,#102033 56%,#12334a)}
.landing-final-cta-inner{display:flex;align-items:center;justify-content:space-between;gap:35px}
.landing-final-cta .landing-eyebrow{margin-bottom:12px}
.landing-final-cta h2{font-size:clamp(1.65rem,2.7vw,2.15rem)}
.landing-final-cta-inner>div>p:not(.landing-eyebrow){margin-top:9px;font-size:12px}
.landing-final-cta .landing-hero-actions{flex:none;margin:0}
.landing-footer{padding:22px 0;background:#09111d}
.landing-footer>.landing-container{display:flex;align-items:center;justify-content:space-between;gap:20px}
.landing-footer .landing-brand{font-size:12px}
.landing-footer .landing-brand img{width:28px;height:28px;border-radius:8px}
.landing-footer small{color:#788ba0;font-size:10px}
@media(max-width:1000px){
  .landing-hero{padding:76px 0 70px}
  .landing-hero-grid{gap:35px}
  .landing-hero h1{font-size:clamp(2.6rem,5.3vw,3.8rem)}
  .landing-workflow-grid,.landing-benefits-grid{gap:54px}
}
@media(max-width:820px){
  html:has(body.landing-page){scroll-padding-top:72px}
  .landing-nav-inner{width:min(100% - 36px,1240px);min-height:68px}
  .landing-menu-toggle{display:inline-flex}
  .landing-navigation{position:absolute;top:calc(100% + 1px);left:0;right:0;display:none;align-items:stretch;gap:0;padding:9px 18px 18px;border-bottom:1px solid #26394d;background:rgba(11,19,32,.98);box-shadow:0 20px 30px rgba(0,0,0,.28)}
  .landing-navigation.is-open{display:flex;flex-direction:column}
  .landing-navigation>a{padding:13px 5px;border-bottom:1px solid rgba(128,154,182,.12)}
  .landing-nav-actions{justify-content:space-between;margin:12px 0 0;padding:8px 0 0}
  .landing-hero-grid{grid-template-columns:1fr;gap:45px}
  .landing-hero-copy{max-width:700px}
  .landing-preview-wrap{width:min(100%,650px);margin-inline:auto}
  .landing-preview{transform:none}
  .landing-orbit{width:390px;height:390px}
  .landing-orbit--two{width:480px;height:480px}
  .landing-workflow-grid,.landing-benefits-grid{grid-template-columns:1fr;gap:38px}
  .landing-workflow-heading{position:static}
  .landing-platform .landing-section-heading{margin-bottom:32px}
  .landing-feature-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .landing-final-cta-inner{align-items:flex-start;flex-direction:column}
}
@media(max-width:540px){
  .landing-container{width:calc(100% - 36px)}
  .landing-hero{padding:62px 0 52px}
  .landing-eyebrow{font-size:9px}
  .landing-hero h1{font-size:clamp(2.4rem,12vw,3.35rem)}
  .landing-lead{margin-top:18px;font-size:14px}
  .landing-hero-actions{gap:16px;margin-top:23px}
  .landing-cta{min-height:46px;padding-inline:17px;font-size:13px}
  .landing-trust-note{align-items:flex-start;max-width:300px;font-size:10px;line-height:1.6}
  .landing-preview-wrap{margin-top:0;padding-bottom:13px}
  .preview-body{min-height:285px;grid-template-columns:90px minmax(0,1fr)}
  .preview-sidebar{padding:13px 6px}
  .preview-nav-item{gap:5px;padding:8px 4px;font-size:7px}
  .preview-content{padding:13px 10px}
  .preview-heading b{font-size:12px}
  .preview-stat-row,.preview-panels{gap:6px}
  .preview-stat{padding:8px 6px}
  .preview-panel{min-height:103px;padding:9px;gap:8px}
  .preview-panel>b{font-size:8px}
  .preview-activity{padding:8px}
  .landing-orbit{width:290px;height:290px}
  .landing-orbit--two{width:360px;height:360px}
  .landing-section{padding:66px 0}
  .landing-section-heading h2{font-size:2rem}
  .landing-platform .landing-section-heading{text-align:left}
  .landing-platform .landing-eyebrow{justify-content:flex-start}
  .landing-feature-grid{grid-template-columns:1fr;gap:10px}
  .landing-feature{min-height:0;padding:18px}
  .landing-feature h3{margin-top:14px}
  .landing-steps li{grid-template-columns:42px minmax(0,1fr);gap:14px;padding-bottom:23px}
  .landing-steps::before{left:20px}
  .landing-step-number{width:41px;height:41px}
  .landing-steps h3{font-size:14px}
  .landing-benefit-list li{gap:12px}
  .landing-final-cta{padding:39px 0}
  .landing-final-cta-inner{gap:23px}
  .landing-final-cta .landing-hero-actions{align-items:flex-start}
  .landing-footer>.landing-container{align-items:flex-start;flex-direction:column;gap:11px}
}
@media(prefers-reduced-motion:reduce){
  html:has(body.landing-page){scroll-behavior:auto}
  .landing-page *, .landing-page *::before, .landing-page *::after{animation-duration:.01ms!important;transition-duration:.01ms!important}
}

/* Landing-page authentication overlays */
body.landing-auth-open{overflow:hidden}
.landing-auth-dialog{width:min(920px,calc(100vw - 28px));max-width:none;max-height:calc(100dvh - 24px);margin:auto;padding:0;overflow:hidden;border:1px solid #31485d;border-radius:20px;background:#0d1825;color:#edf5fc;box-shadow:0 28px 100px rgba(0,0,0,.6)}
.landing-auth-dialog[data-auth-type=login]{width:min(540px,calc(100vw - 28px))}
.landing-auth-dialog::backdrop{background:rgba(3,9,16,.76);backdrop-filter:blur(8px)}
.landing-auth-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:13px 18px;border-bottom:1px solid #293c4f;background:linear-gradient(120deg,#101e2d,#10283a)}
.landing-auth-heading h2{margin:0;color:#edf5fc;font-size:16px;font-weight:650}
.landing-auth-close{display:grid;width:36px;height:36px;place-items:center;border:1px solid #3b5266;border-radius:10px;background:#132436;color:#dceaf5;font-size:24px;line-height:1;cursor:pointer;transition:background .18s,border-color .18s,transform .18s}
.landing-auth-close:hover{transform:translateY(-1px);border-color:#50c4e9;background:#19364a}
.landing-auth-close:focus-visible{outline:3px solid #65d8fb;outline-offset:2px}
.landing-auth-frame{display:block;width:100%;height:440px;max-height:calc(100dvh - 90px);border:0;background:transparent}
.landing-auth-dialog[data-auth-type=register] .landing-auth-frame{height:min(78dvh,800px)}
body.auth-page.auth-overlay-page{min-height:0;background:transparent;color:#e7f0fa}
body.auth-overlay-page .auth-wrap{width:100%;margin:0 auto;padding:12px 16px 18px;color:#e7f0fa}
body.auth-overlay-page .auth-wrap.wide{width:100%}
body.auth-overlay-page .auth-brand{display:none}
body.auth-overlay-page .auth-wrap .card{border-color:#2b4056;border-radius:14px;background:linear-gradient(150deg,#142135,#101a2a);box-shadow:none}
body.auth-overlay-page .auth-wrap .card h2{color:#edf5fc}
body.auth-overlay-page .auth-wrap .muted{color:#a8b8c9}
body.auth-overlay-page .auth-wrap label,body.auth-overlay-page .auth-wrap legend{color:#dce8f3}
body.auth-overlay-page .auth-wrap input,body.auth-overlay-page .auth-wrap textarea,body.auth-overlay-page .auth-wrap select{border-color:#344a60;background:#0d1825;color:#edf5fc}
body.auth-overlay-page .auth-wrap input:focus,body.auth-overlay-page .auth-wrap textarea:focus,body.auth-overlay-page .auth-wrap select:focus{border-color:#4fc9ed;box-shadow:0 0 0 3px rgba(79,201,237,.16)}
body.auth-overlay-page .auth-wrap fieldset{border-color:#344a60}
body.auth-overlay-page .auth-wrap a{color:#71d9f6}
@media(max-width:600px){
  .landing-auth-dialog{width:calc(100vw - 20px);max-height:calc(100dvh - 20px);border-radius:15px}
  .landing-auth-heading{padding:10px 13px}
  .landing-auth-frame{height:min(68dvh,520px);max-height:calc(100dvh - 76px)}
  .landing-auth-dialog[data-auth-type=register] .landing-auth-frame{height:calc(88dvh - 58px)}
  body.auth-overlay-page .auth-wrap{padding:8px}
  body.auth-overlay-page .auth-wrap .card{padding:19px}
}
@media(prefers-reduced-motion:reduce){
  .landing-auth-close{transition:none}
}

/* 20. Green workspace theme ----------------------------------------------- */
:root{
  color-scheme:light;
  --bg:#f2f8f4;--card:#fff;--ink:#28332c;--muted:#65716a;
  --brand:#2f8058;--brand2:#246746;--brand-soft:#e8f4ec;
  --ok:#24764b;--bad:#b43e49;--warn:#946516;--info:#2f8058;
  --line:#dce9df;--line-strong:#c5d8ca;
  --shadow-sm:0 2px 8px rgba(28,66,43,.05);
  --shadow-md:0 16px 36px rgba(28,66,43,.13);
  --focus:0 0 0 3px rgba(47,128,88,.23);
}
html{background:var(--bg)}
body:not(.landing-page){background:var(--bg);color:var(--ink)}
a{color:var(--brand)}
.muted{color:var(--muted)}
.topbar{background:rgba(255,255,255,.97);color:var(--ink);border-bottom:1px solid var(--line);box-shadow:0 2px 10px rgba(28,66,43,.04)}
.brand,.user-menu>summary{color:var(--ink)}
.brand-mark,.avatar{background:#e2f2e8;color:var(--brand)}
.menu-btn{background:var(--bg);color:var(--ink);border-color:var(--line)}
.menu-btn:hover,.menu-btn:active,.icon-link:hover{background:var(--brand-soft);color:var(--brand)}
.icon-link{color:var(--ink)}
.user-menu>summary:hover,.user-menu[open]>summary{background:var(--bg)}
.user-panel{background:#fff;color:var(--ink);border-color:var(--line);box-shadow:var(--shadow-md)}
.user-panel a:hover{background:var(--brand-soft);color:var(--brand)}
.layout{max-width:1560px}
.sidebar{background:#174b36;color:#fff;border:0;box-shadow:0 12px 30px rgba(19,62,41,.16)}
.side-label{color:#c3ddcc}
.sidebar a,.sidebar a .icon{color:#fff}
.sidebar a:hover{background:rgba(255,255,255,.12);color:#fff}
.sidebar a:hover .icon{color:#fff}
.sidebar a.active{background:#2f8058;color:#fff;border-color:transparent}
.sidebar a.active .icon{color:#fff}
.sidebar a.active::before{display:none}
.side-foot{border-color:rgba(255,255,255,.18);color:#d4e5d9}
.side-close{color:#fff}
.side-close:hover{background:rgba(255,255,255,.12);color:#fff}
.page-kicker{color:var(--brand)}
.page-head h1{color:var(--ink)}
.page-intro{color:var(--muted)}
.page-context{background:#fff;border-color:var(--line);color:var(--muted)}
body:not(.auth-page):not(.landing-page) .hero{border:1px solid #d5e8da;border-radius:20px;background:linear-gradient(120deg,#e8f4ec,#f7fbf8);box-shadow:0 12px 30px rgba(28,66,43,.07);color:var(--ink)}
body:not(.auth-page):not(.landing-page) .hero h1{color:#20372a}
body:not(.auth-page):not(.landing-page) .hero .muted{color:var(--muted)}
body:not(.auth-page):not(.landing-page) .hero .btn{background:var(--brand);color:#fff}
body:not(.auth-page):not(.landing-page) .hero .btn:hover{background:var(--brand2)}
.card{background:#fff;border-color:var(--line);box-shadow:0 3px 14px rgba(28,66,43,.055)}
.card h3{color:#303b33}
.grid.kpi .card{border-color:var(--line)}
.grid.kpi .card::before{background:var(--brand);box-shadow:none}
.grid.kpi .card::after{background:rgba(47,128,88,.07)}
.grid.kpi .card:nth-child(3n+2)::before{background:#76a984}
.grid.kpi .card:nth-child(3n)::before{background:#a3c6aa}
.kpi-num{color:#2c3830}
.kpi-label{color:var(--muted)}
.card .icon,.landing-feature-icon{background:#e8f4ec;color:var(--brand)}
.progress{background:#e4eee7}
.progress>div{background:linear-gradient(90deg,#2f8058,#70b785)}
.notif-item.unread{background:#edf7f0}
.table-wrap,table{background:#fff;border-color:var(--line);box-shadow:0 2px 9px rgba(28,66,43,.04)}
th,td{border-bottom-color:#e8f0ea;color:var(--ink)}
th{background:#f1f7f2;color:#64786a}
tbody tr:hover>td{background:#f5faf6}
.btn{background:var(--brand);color:#fff;box-shadow:0 2px 6px rgba(47,128,88,.14)}
.btn:hover{background:var(--brand2);color:#fff;box-shadow:0 5px 13px rgba(47,128,88,.18)}
.btn.outline{background:#fff;color:var(--brand);border-color:#b9d5c1}
.btn.outline:hover{background:var(--brand-soft);color:var(--brand2)}
.btn.ghost{background:#f2f7f3;color:var(--ink);border-color:var(--line);box-shadow:none}
.btn.ghost:hover{background:#e8f2eb}
input,select,textarea{background:#fff;color:var(--ink);border-color:#cfdfd3}
input:hover,select:hover,textarea:hover{border-color:#a9c7b1}
input:focus,select:focus,textarea:focus{background:#fff;border-color:var(--brand);box-shadow:var(--focus)}
input::placeholder,textarea::placeholder{color:#839488}
input[readonly],textarea[readonly],input:disabled,select:disabled,textarea:disabled{background:#f2f6f3;color:#697b6e}
fieldset{border-color:var(--line)}
legend{color:var(--ink)}
.pw-toggle{color:var(--brand)}
.alert.ok{background:#e9f5ed;color:#246a43;border-color:#c5e1cd}
.alert.bad{background:#fbebec;color:#a93641;border-color:#edc8cb}
.alert.warn{background:#fff6e4;color:#80570d;border-color:#ead6a9}
.alert.info{background:#e8f4ec;color:#286b48;border-color:#c7e1ce}
.badge.ok{background:#e5f3e9;color:#246a43}
.badge.bad{background:#f9e9eb;color:#a93641}
.badge.warn{background:#fff4dc;color:#80570d}
.badge.info{background:#e6f3e9;color:#286b48}
.badge.muted{background:#eef3ef;color:#607568}
body.auth-page{background:radial-gradient(ellipse at 50% 0%,#e0f1e5 0,transparent 48%),var(--bg);color:var(--ink)}
.auth-brand{color:var(--ink)}
.auth-wrap .card{background:#fff;border-color:var(--line);box-shadow:0 20px 55px rgba(28,66,43,.12)}
.auth-wrap .card h2{color:var(--ink)}
dialog{background:#fff;color:var(--ink);border:1px solid var(--line)}
dialog::backdrop{background:rgba(24,52,35,.48)}
.footer{color:var(--muted)}
.skip-link{background:#fff;color:var(--brand)}
:focus-visible{outline-color:var(--brand)}
.topbar :focus-visible{outline-color:var(--brand)}
.nav-backdrop{background:rgba(19,47,31,.52)}
@media(max-width:900px){
  .sidebar{background:#174b36}
  .sidebar a.active::before{display:none}
}
@media print{
  :root{color-scheme:light}
  body{background:#fff;color:#000}
  .card,.table-wrap,table{background:#fff;color:#000}
  td{color:#000}
  .page-head h1,.card h3{color:#000}
}

/* Public landing page follows the workspace palette. */
body.landing-page{--landing-ink:#28332c;--landing-muted:#65716a;--landing-line:#dce9df;--landing-panel:#fff;
  background:#f2f8f4;color:#28332c}
.landing-page a{color:var(--brand)}
.landing-nav{background:rgba(255,255,255,.96);border-bottom-color:#dce9df;box-shadow:0 2px 10px rgba(28,66,43,.04)}
.landing-brand{color:#28332c}
.landing-navigation>a,.landing-login{color:#526b5a}
.landing-navigation>a:hover,.landing-login:hover{color:#246746}
.landing-cta{border-color:#2f8058;background:linear-gradient(135deg,#34885f,#246746);box-shadow:0 8px 24px rgba(47,128,88,.16);color:#fff!important}
.landing-cta:hover{background:linear-gradient(135deg,#3b966a,#2a7550);box-shadow:0 12px 30px rgba(47,128,88,.22)}
.landing-menu-toggle{border-color:#d2e3d6;background:#f3f8f4;color:#294435}
.landing-hero{background:radial-gradient(ellipse at 78% 42%,rgba(81,157,103,.13),transparent 38%),linear-gradient(180deg,#edf7ef,#e4f2e8)}
.landing-hero::before{background-image:linear-gradient(rgba(67,116,79,.09) 1px,transparent 1px),linear-gradient(90deg,rgba(67,116,79,.09) 1px,transparent 1px)}
.landing-hero-glow{border-color:rgba(47,128,88,.12);box-shadow:0 0 0 64px rgba(47,128,88,.025),0 0 0 128px rgba(47,128,88,.02)}
.landing-eyebrow{color:#2f8058}
.landing-eyebrow>span{background:#54a873;box-shadow:0 0 12px rgba(84,168,115,.35)}
.landing-hero h1,.landing-section-heading h2,.landing-final-cta h2{color:#28332c}
.landing-hero h1 span{color:#2f8058}
.landing-lead,.landing-section-heading>p:not(.landing-eyebrow),.landing-final-cta-inner>div>p:not(.landing-eyebrow){color:#65716a}
.landing-secondary{color:#46534a!important}
.landing-secondary:hover{color:#246746!important}
.landing-play{border-color:#bcd3c1;color:#2f8058}
.landing-secondary:hover .landing-play{background:#e4f2e8;border-color:#8fbd9d}
.landing-trust-note{color:#65716a}
.landing-trust-note span,.landing-text-link{color:#2f8058!important}
.landing-orbit{border-color:rgba(47,128,88,.12)}
.landing-orbit--two{border-color:rgba(47,128,88,.07)}
.landing-preview{border-color:#d6e5d9;background:#fff;box-shadow:0 24px 60px rgba(28,66,43,.16)}
.preview-topbar{border-bottom-color:#e0ebe2;background:#f5f9f6}
.preview-brand{color:#46534a}
.preview-brand-mark{border-color:#c7dfcd;background:#e8f4ec;color:#2f8058}
.preview-window-dots i{background:#a8b9ac}
.preview-sidebar{border-right-color:#e1ece3;background:#f5f9f6}
.preview-nav-item{color:#718275}
.preview-nav-item i{border-color:#b5c6b8}
.preview-nav-item--active{background:#e5f2e8;border-color:#c4dfca;color:#286b48}
.preview-nav-item--active i{border-color:#66a77a;background:#5c9b70;box-shadow:0 0 8px rgba(92,155,112,.2)}
.preview-heading small,.preview-panel small,.preview-activity small{color:#718275}
.preview-heading b{color:#303b33}
.preview-heading>i{border-color:#d2e2d5;background:linear-gradient(135deg,#e1f0e5,#f4f8f4)}
.preview-stat,.preview-panel,.preview-activity{border-color:#e0ebe2;background:#fff}
.preview-stat i{border-color:#c2ddc8;background:#e8f4ec}
.preview-stat b{background:#91a99a}
.preview-stat em{background:#d6e3d9}
.preview-panel>b{color:#46534a}
.preview-progress{background:#e3eee5}
.preview-progress i{background:linear-gradient(90deg,#2f8058,#79b98a)}
.preview-panel em,.preview-status-panel>span{color:#727d75}
.preview-status-panel>b i{background:#5b9e70;box-shadow:0 0 7px rgba(91,158,112,.25)}
.preview-activity>span i{background:#5b9e70}
.preview-activity>span b{background:#c9d9cc}
.preview-caption{color:#65716a}
.preview-caption span{color:#2f8058}
.landing-platform{border-color:#dce9df;background:#fff}
.landing-workflow{background:#f2f8f4}
.landing-benefits{border-color:#dce9df;background:radial-gradient(ellipse at 10% 50%,rgba(47,128,88,.07),transparent 45%),#fff}
.landing-feature{border-color:#dce9df;background:#fff;box-shadow:0 2px 10px rgba(28,66,43,.04)}
.landing-feature:hover{border-color:#b9d5c1;box-shadow:0 13px 30px rgba(28,66,43,.09)}
.landing-feature-icon{border-color:#d5e8da;background:#e8f4ec;color:#2f8058}
.landing-feature h3,.landing-steps h3,.landing-benefit-list b{color:#303b33}
.landing-feature p,.landing-steps p,.landing-benefit-list small{color:#65716a}
.landing-steps::before{background:linear-gradient(#70ad7f,#dce9df 75%,transparent)}
.landing-step-number{border-color:#c9dfce;background:#fff;color:#2f8058;box-shadow:0 0 0 6px #f2f8f4}
.landing-steps li:first-child .landing-step-number{border-color:#8fbd9d;background:#e8f4ec;box-shadow:0 0 0 6px #f2f8f4,0 0 20px rgba(47,128,88,.1)}
.landing-benefit-list li{border-bottom-color:#e5eee7}
.landing-benefit-list li>span{border-color:#b8d5bf;background:#e8f4ec;color:#286b48}
.landing-final-cta{border-color:#d5e6d9;background:linear-gradient(110deg,#e5f2e8,#edf7ef 56%,#e2f1e6)}
.landing-footer{background:#e8f2ea}
.landing-footer small{color:#65716a}
@media(max-width:820px){
  .landing-navigation{border-bottom-color:#dce9df;background:rgba(255,255,255,.98);box-shadow:0 20px 30px rgba(28,66,43,.12)}
  .landing-navigation>a{border-bottom-color:#e5eee7}
}

/* Landing-page authentication overlays use the same light card treatment. */
.landing-auth-dialog{border-color:#d4e5d8;background:#fff;color:#28332c;box-shadow:0 28px 80px rgba(28,66,43,.24)}
.landing-auth-dialog::backdrop{background:rgba(24,52,35,.55)}
.landing-auth-heading{border-bottom-color:#dce9df;background:linear-gradient(120deg,#f5faf6,#eaf5ed)}
.landing-auth-heading h2{color:#28332c}
.landing-auth-close{border-color:#d2e3d6;background:#f3f8f4;color:#365341}
.landing-auth-close:hover{border-color:#9fc8aa;background:#e8f4ec}
.landing-auth-close:focus-visible{outline-color:#2f8058}
body.auth-page.auth-overlay-page{color:#28332c}
body.auth-overlay-page .auth-wrap{color:#28332c}
body.auth-overlay-page .auth-wrap .card{border-color:#dce9df;background:#fff;box-shadow:none}
body.auth-overlay-page .auth-wrap .card h2{color:#28332c}
body.auth-overlay-page .auth-wrap .muted{color:#65716a}
body.auth-overlay-page .auth-wrap label,body.auth-overlay-page .auth-wrap legend{color:#303b33}
body.auth-overlay-page .auth-wrap input,body.auth-overlay-page .auth-wrap textarea,body.auth-overlay-page .auth-wrap select{border-color:#cfdfd3;background:#fff;color:#28332c}
body.auth-overlay-page .auth-wrap input:focus,body.auth-overlay-page .auth-wrap textarea:focus,body.auth-overlay-page .auth-wrap select:focus{border-color:#2f8058;box-shadow:0 0 0 3px rgba(47,128,88,.18)}
body.auth-overlay-page .auth-wrap fieldset{border-color:#dce9df}
body.auth-overlay-page .auth-wrap a{color:#2f8058}

/* Supervisor requirement overview and student details. */
.req-summary .card{min-height:96px}
.req-filter-form{margin:18px 0 10px}
.req-filter-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.req-filter-actions .btn{width:auto}
.req-result-count{margin:12px 0}
.req-student-table{margin-top:8px}
.req-student-table td{min-width:120px}
.req-student-table td:first-child{min-width:180px}
.req-student-table td:last-child{min-width:130px}
.req-progress{width:min(150px,100%);height:9px;margin:2px 0 5px;overflow:hidden;border-radius:99px;background:#e4eee7}
.req-progress>span{display:block;height:100%;border-radius:inherit;background:linear-gradient(90deg,#2f8058,#70b785)}
.req-progress-large{width:min(360px,100%);height:12px;margin:12px 0 6px}
.req-pagination{display:flex;align-items:center;justify-content:center;gap:14px;margin-top:18px}
.req-concerns,.req-concern-form,.req-detail-table{margin-top:16px}
.req-student-meta{display:flex;flex-wrap:wrap;gap:8px 22px;margin:12px 0}
.req-permission-note{margin-top:14px}
.req-history-item{padding:10px 0;margin:0;border-bottom:1px solid var(--line);line-height:1.55}
.req-history-item:last-child{border-bottom:0}
.req-detail-table td{min-width:140px}
.req-detail-table td:first-child{min-width:210px}
.placement-progress{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;min-height:280px;margin-top:12px}
.placement-progress-pie{display:grid;place-items:center;flex:none;width:min(100%,280px);aspect-ratio:1;border-radius:50%;background:conic-gradient(#2f8058 var(--placement-progress),#e4eee7 0);color:#29372e;font-size:24px;font-weight:800}
.placement-progress-pie span{padding:4px 7px;border-radius:999px;background:rgba(255,255,255,.92)}
.placement-progress p{margin:0;text-align:center}
@media(max-width:640px){
  .req-filter-actions{align-items:stretch}
  .req-filter-actions .btn{flex:1 1 140px}
  .req-pagination{justify-content:space-between}
  .req-student-meta{display:grid;gap:6px}
}
.qr-attendance-scanner>.alert{margin:14px 0}
.course-settings-search{align-items:end;gap:10px;margin:16px 0 8px}
.course-settings-search label{font-size:13px;font-weight:650;color:var(--muted)}
.course-settings-search input{flex:1 1 220px}
.course-settings-search .btn{width:auto}
.course-settings-edit{min-width:120px}
.course-settings-edit summary{display:inline-block;cursor:pointer}
.course-settings-edit-form{display:grid;min-width:190px;gap:8px;margin-top:10px}
.course-settings-edit-form label{display:grid;gap:5px;font-size:12px;color:var(--muted)}
.course-settings-edit-form .btn{width:max-content}
.placement-hours-progress{width:min(220px,100%);height:9px;margin:6px 0;overflow:hidden;border-radius:99px;background:#e4eee7}
.placement-hours-progress>span{display:block;height:100%;border-radius:inherit;background:linear-gradient(90deg,#2f8058,#70b785)}
.attendance-scan-actions,.student-qr-actions{display:flex;align-items:center;gap:9px;flex-wrap:wrap}
.attendance-scanner-layout{display:grid;grid-template-columns:minmax(0,1.3fr) minmax(240px,1fr);align-items:start;gap:22px;margin-top:18px}
.attendance-camera{display:block;width:min(100%,560px);min-height:240px;max-height:420px;object-fit:cover;border:1px solid var(--line);border-radius:12px;background:#172b45}
.attendance-camera[hidden]{display:none}
.attendance-scanner-layout .muted{margin:10px 0 0}
.attendance-usb-form{display:grid;gap:10px}
.attendance-usb-form label{font-weight:700}
.attendance-report-filters{align-items:end;gap:12px;margin:12px 0 18px}
.attendance-report-filters label{display:grid;gap:5px;color:var(--muted);font-size:13px;font-weight:650}
.attendance-report-filters .btn{width:auto}
.student-qr-print{margin-bottom:16px}
.student-qr-content{display:grid;grid-template-columns:minmax(0,1fr) 196px;align-items:center;gap:22px}
.student-qr-info h3{margin:4px 0 7px}
.student-qr-info>p.muted{margin:0 0 12px}
.student-qr-id{display:flex;align-items:baseline;gap:9px;margin:0;color:var(--muted);font-size:13px}
.student-qr-id strong{color:var(--ink);font-size:16px;letter-spacing:.04em}
.student-qr-code{display:grid;place-items:center;justify-self:end;width:196px;aspect-ratio:1;padding:7px;border:1px solid var(--line);border-radius:12px;background:#fff}
.student-qr-code canvas,.student-qr-code img{display:block;width:180px;height:180px;max-width:100%}
.student-qr-actions{margin-top:16px}
.student-qr-error{margin-top:10px!important}
.supervisor-attendance-link{display:flex;align-items:center;justify-content:space-between;gap:18px}
.supervisor-attendance-link h3,.supervisor-attendance-link p{margin-bottom:6px}
@media(max-width:700px){
  .attendance-scanner-layout{grid-template-columns:1fr}
  .attendance-report-filters{align-items:stretch}
  .attendance-report-filters label,.attendance-report-filters .btn{flex:1 1 150px}
  .student-qr-content{grid-template-columns:minmax(0,1fr) 156px;gap:14px}
  .student-qr-code{justify-self:end;width:156px}
  .student-qr-code canvas,.student-qr-code img{width:140px;height:140px}
  .supervisor-attendance-link{align-items:flex-start;flex-direction:column}
}
@media(max-width:480px){
  .student-qr-content{grid-template-columns:1fr}
  .student-qr-code{justify-self:start;width:156px}
}
/* Student QR print: applies ONLY when the QR button adds body.printing-qr (previously this hid every page when printing). */
@media print{
  body.printing-qr *{visibility:hidden!important}
  body.printing-qr .student-qr-print,body.printing-qr .student-qr-print *{visibility:visible!important}
  body.printing-qr .student-qr-print{position:absolute;inset:0;border:0;box-shadow:none}
  .student-qr-content{grid-template-columns:1fr 196px}
  .student-qr-code{justify-self:end;width:196px}
  .student-qr-code canvas,.student-qr-code img{width:180px;height:180px}
  .student-qr-actions{display:none!important}
}

/* Final authoritative print rules for report/list pages: readable black-on-white, nothing hidden, tables may span pages. */
@media print{
  :root{color-scheme:light}
  html,body{background:#fff!important;color:#000!important}
  body:not(.printing-qr) .sidebar,body:not(.printing-qr) .topbar,body:not(.printing-qr) .no-print,body:not(.printing-qr) .nav-backdrop,
  body:not(.printing-qr) .skip-link,body:not(.printing-qr) .footer,body:not(.printing-qr) .alert-close,body:not(.printing-qr) .pagination{display:none!important}
  body:not(.printing-qr) .layout{display:block!important;max-width:none!important;padding:0!important;margin:0!important}
  body:not(.printing-qr) .content{display:block!important;visibility:visible!important;opacity:1!important}
  body:not(.printing-qr) .card,body:not(.printing-qr) .table-wrap{background:#fff!important;box-shadow:none!important;overflow:visible!important;max-height:none!important;break-inside:auto!important}
  body:not(.printing-qr) table{background:#fff!important;width:100%!important;break-inside:auto!important;border-collapse:collapse}
  body:not(.printing-qr) thead{display:table-header-group}
  body:not(.printing-qr) tr{break-inside:avoid;page-break-inside:avoid}
  body:not(.printing-qr) th,body:not(.printing-qr) td{color:#000!important;background:#fff!important;border:1px solid #999!important;padding:4px 6px!important}
  body:not(.printing-qr) th{background:#eee!important;-webkit-print-color-adjust:exact;print-color-adjust:exact}
  body:not(.printing-qr) .content h1,body:not(.printing-qr) .content h2,body:not(.printing-qr) .content h3,body:not(.printing-qr) .content p,
  body:not(.printing-qr) .content span,body:not(.printing-qr) .content small,body:not(.printing-qr) .content strong,body:not(.printing-qr) .content a{color:#000!important}
}


/* 18. Help menu + PRD/TRD documentation page ------------------------------- */
.help-menu>summary{gap:6px;padding:5px 12px 5px 6px;font-weight:600;font-size:14px}
.help-ico{display:inline-flex;align-items:center;justify-content:center;width:30px;height:30px;border-radius:50%;background:var(--brand-soft);color:var(--brand)}
.help-ico .icon{width:18px;height:18px}
.help-panel{width:300px}
.doc-toolbar{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:12px;padding:12px 16px}
.doc-tabs{display:flex;flex-wrap:wrap;gap:6px}
.doc-tab{appearance:none;border:1px solid var(--line-strong);background:#fff;color:var(--ink);font:inherit;font-weight:600;font-size:14px;padding:9px 16px;border-radius:999px;cursor:pointer;min-height:40px}
.doc-tab:hover{background:var(--brand-soft);color:var(--brand2)}
.doc-tab.is-active{background:var(--brand);border-color:var(--brand);color:#fff}
.doc-tab:focus-visible{outline:none;box-shadow:var(--focus)}
.doc-actions{display:flex;flex-wrap:wrap;gap:8px}
.doc-layout{display:grid;grid-template-columns:230px minmax(0,1fr);gap:22px;align-items:start;margin-top:18px}
.doc-toc{position:sticky;top:calc(var(--topbar-h) + 18px);max-height:calc(100vh - var(--topbar-h) - 40px);overflow:auto;background:#fff;border:1px solid var(--line);border-radius:14px;padding:14px 12px}
.doc-toc strong{display:block;font-size:13px;margin:0 6px 8px;color:var(--ink)}
.doc-toc ol{list-style:none;margin:0;padding:0}
.doc-toc a{display:block;padding:7px 8px;border-radius:8px;color:var(--ink);font-size:13px;line-height:1.35}
.doc-toc a:hover{background:var(--brand-soft);color:var(--brand2);text-decoration:none}
.doc-article{padding:26px 30px;min-width:0}
.doc-head{border-bottom:1px solid var(--line);margin-bottom:6px;padding-bottom:12px}
.doc-title{margin:0 0 6px;font-size:clamp(1.4rem,1.1rem + 1vw,1.85rem);letter-spacing:-.03em;color:#172b45}
.doc-section{padding-top:4px;scroll-margin-top:calc(var(--topbar-h) + 16px)}
.doc-section h2{font-size:1.25rem;margin:26px 0 10px;color:#172b45;letter-spacing:-.02em}
.doc-section h3{font-size:1rem;margin:20px 0 8px;color:var(--brand2)}
.doc-section p,.doc-section li{max-width:78ch;line-height:1.6}
.doc-section ul{padding-left:1.2rem;margin:0 0 1rem}
.doc-section li{margin:0 0 .35rem}
.doc-table{margin:10px 0 18px}
.doc-table td{vertical-align:top}
.doc-table td.doc-key{font-weight:700}
.doc-figure{margin:14px 0 20px}
.doc-figure svg{width:100%;max-width:760px;display:block;margin:auto}
.doc-figure figcaption{text-align:center;color:var(--muted);font-size:13px;margin-top:6px}
.arch rect{stroke-width:1.5}
.arch-web rect{fill:#e8f4ec;stroke:#2f8058}.arch-pub rect{fill:#fff6e4;stroke:#946516}.arch-app rect{fill:#eef3f8;stroke:#34506f}.arch-data rect{fill:#f1ecf8;stroke:#5b3f8c}.arch-ext rect{fill:#f4f4f4;stroke:#666}
.arch-t{font:700 14px var(--font);fill:#1e2a3a}.arch-s{font:11px var(--font);fill:#44546a}
.arch-line{stroke:#34506f;stroke-width:1.6}.arch-arrow{fill:#34506f}
@media (max-width:1100px){.doc-layout{grid-template-columns:1fr}.doc-toc{position:static;max-height:none}.doc-toc ol{columns:2}}
@media (max-width:640px){.help-label{display:none}.help-menu>summary{padding:4px}.doc-article{padding:18px 14px}.doc-toc ol{columns:1}.doc-tab{flex:1 1 100%}}
@media print{
  .topbar,.sidebar,.footer,.doc-toolbar,.doc-toc,.nav-backdrop{display:none!important}
  .doc-layout{display:block;margin-top:0}.doc-article{border:0;box-shadow:none;padding:0}
  .doc-section h2,.doc-section h3{break-after:avoid}.doc-table tr{break-inside:avoid}
}

/* Dropdown links: restore legible light-theme colours (an older dark-theme rule left them near-white). */
.user-panel a{color:var(--ink)}
.user-panel a.logout{color:var(--bad)}
.user-panel a.logout:hover{background:#fde8e8;color:var(--bad)}
