:root{--bg:#f5f7fa;--card:#fff;--text:#172033;--muted:#687386;--line:#dfe5ec;--accent:#17385f;--accent2:#245b96;--ok:#16794b;--warn:#9a6700;--danger:#b42318}*{box-sizing:border-box}html{font-family:system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif;background:var(--bg);color:var(--text)}body{margin:0}.topbar{min-height:60px;background:var(--accent);color:white;display:flex;align-items:center;justify-content:space-between;padding:10px 18px;position:sticky;top:0;z-index:5}.brand{color:white;text-decoration:none;font-weight:800;font-size:1.2rem;letter-spacing:.04em}.top-user{display:flex;gap:14px;align-items:center;font-size:.9rem}.top-user a{color:white}.container{width:min(1120px,calc(100% - 28px));margin:22px auto}.narrow{width:min(560px,calc(100% - 28px))}.hero{padding:34px 0 16px}.hero h1{font-size:clamp(1.6rem,4vw,2.5rem);margin:.2em 0}.hero p{color:var(--muted);font-size:1.05rem}.grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:14px}.card{background:var(--card);border:1px solid var(--line);border-radius:16px;padding:18px}.card h2,.card h3{margin-top:0}.module{min-height:150px}.module.disabled{opacity:.62}.badge{display:inline-block;padding:4px 9px;border-radius:999px;font-size:.78rem;background:#eaf0f7;color:var(--accent)}.badge.ok{background:#e8f6ef;color:var(--ok)}.badge.warn{background:#fff5d8;color:var(--warn)}.button,button{appearance:none;border:0;border-radius:11px;background:var(--accent);color:white;padding:12px 16px;font:inherit;font-weight:650;cursor:pointer;text-decoration:none;display:inline-flex;align-items:center;justify-content:center;gap:8px}.button.secondary,button.secondary{background:#e8eef5;color:var(--accent)}.button.danger,button.danger{background:var(--danger)}.button.ghost{background:transparent;color:var(--accent);border:1px solid var(--line)}.actions{display:flex;gap:10px;flex-wrap:wrap}.stack{display:grid;gap:13px}.field label{display:block;font-weight:650;margin-bottom:6px}.field input,.field select,.field textarea{width:100%;padding:12px;border:1px solid #cfd7e1;border-radius:10px;background:white;color:var(--text);font:inherit}.field small{display:block;color:var(--muted);margin-top:5px}.alert{padding:12px 14px;border-radius:11px;margin:12px 0;background:#eef3f8}.alert.success{background:#e8f6ef;color:#0c5f3a}.alert.warn{background:#fff5d8;color:#7d5200}.alert.danger{background:#feeceb;color:#8f1d14}.table-wrap{overflow:auto;background:white;border:1px solid var(--line);border-radius:14px}table{border-collapse:collapse;width:100%;min-width:780px}th,td{text-align:left;padding:10px 12px;border-bottom:1px solid var(--line);vertical-align:top}th{background:#f0f4f8;font-size:.86rem}.muted{color:var(--muted)}.kpi{font-size:1.7rem;font-weight:800}.footer{color:var(--muted);text-align:center;font-size:.82rem;padding:28px 16px}.nav{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:18px}.nav a{padding:9px 12px;border-radius:10px;background:white;border:1px solid var(--line);color:var(--accent);text-decoration:none}.list{display:grid;gap:8px}.list-item{padding:11px 12px;background:white;border:1px solid var(--line);border-radius:10px}.help-steps{padding-left:20px}.login-name{font-size:1.35rem;font-weight:800;margin-bottom:6px}.status-dot{width:10px;height:10px;border-radius:50%;display:inline-block;background:#9aa5b1;margin-right:6px}.status-dot.ok{background:var(--ok)}.status-dot.warn{background:#d99a00}.status-dot.danger{background:var(--danger)}@media(max-width:640px){.top-user span{display:none}.container{width:min(100% - 18px,1120px);margin:14px auto}.card{padding:15px}.button,button{width:100%}.actions{display:grid}.hero{padding-top:18px}table{font-size:.9rem}}
.small-text{font-size:.78rem}.filter-grid{display:grid;grid-template-columns:minmax(220px,1fr) minmax(180px,.6fr) auto;gap:12px;align-items:end;margin-bottom:14px}.audit-filters{display:grid;grid-template-columns:repeat(4,minmax(150px,1fr));gap:12px;align-items:end;margin-bottom:14px}.filter-actions{display:flex;gap:8px;align-items:end}.audit-json{white-space:pre-wrap;word-break:break-word;max-width:520px;font-size:.76rem;background:#f6f8fb;border:1px solid var(--line);padding:8px;border-radius:8px}details{margin-top:5px}summary{cursor:pointer;color:var(--accent);font-size:.82rem}@media(max-width:850px){.audit-filters{grid-template-columns:repeat(2,minmax(140px,1fr))}.filter-grid{grid-template-columns:1fr 1fr}.filter-actions{grid-column:1/-1}}@media(max-width:520px){.audit-filters,.filter-grid{grid-template-columns:1fr}.filter-actions{display:grid}.small-text{display:block;max-width:240px;overflow:hidden;text-overflow:ellipsis}}

/* Schedule module v0.2.0 */
.wide-container{width:min(1480px,calc(100% - 24px))}.schedule-editor-wrap{max-width:100%;position:relative}.schedule-grid{min-width:max-content;font-size:.83rem}.schedule-grid th,.schedule-grid td{padding:6px;text-align:center}.schedule-grid .sticky-name{position:sticky;left:0;z-index:3;min-width:190px;max-width:220px;text-align:left;background:#fff}.schedule-grid thead .sticky-name{z-index:5;background:#f0f4f8}.schedule-grid .sticky-stat{position:sticky;left:190px;z-index:3;min-width:170px;max-width:210px;text-align:left;background:#fff}.schedule-grid thead .sticky-stat{z-index:5;background:#f0f4f8}.schedule-grid .sticky-name small{display:block;color:var(--muted);font-weight:400;margin-top:3px}.day-head{min-width:54px}.day-head span,.day-head small{display:block}.day-head small{color:var(--muted);font-weight:500}.schedule-cell{min-width:58px}.schedule-cell select{min-width:54px;border:1px solid #cfd7e1;border-radius:7px;padding:7px 4px;background:#fff;font:inherit}.schedule-grid .weekend{background:#f7f1e7}.schedule-grid .pref-mismatch{background:#fff0cf;box-shadow:inset 0 0 0 2px #d99a00}.pref-mark{display:block;color:#8a5a00;margin-top:3px;font-size:.68rem}.schedule-counts{font-size:.73rem;line-height:1.35;color:var(--accent);font-weight:650}.schedule-pref-wrap table{min-width:620px}.signature-pad-wrap{border:2px dashed #aab5c2;border-radius:12px;background:#fff;overflow:hidden;touch-action:none}.signature-pad-wrap canvas{display:block;width:100%;height:220px;touch-action:none}.view-grid .schedule-cell{font-size:.78rem}.view-grid .sticky-name{min-width:190px}.schedule-grid tbody tr:hover td{background-color:#f8fbff}.schedule-grid tbody tr:hover td.weekend{background-color:#f5eddf}.schedule-grid tbody tr:hover td.pref-mismatch{background-color:#ffe8b8}@media(max-width:700px){.wide-container{width:calc(100% - 10px)}.schedule-grid .sticky-name{min-width:145px;max-width:145px}.schedule-grid .sticky-stat{left:145px;min-width:130px;max-width:130px}.schedule-grid th,.schedule-grid td{padding:4px}.day-head{min-width:48px}.schedule-cell{min-width:50px}.schedule-cell select{padding:7px 2px}.signature-pad-wrap canvas{height:180px}}

/* Schedule refinements v0.2.3 */
.schedule-grid .holiday-day{background:#eef0ff}
.schedule-grid thead .holiday-day{background:#dfe3ff}
.holiday-label{color:#5636a4!important;font-weight:800!important}
.schedule-grid td.proposal-exists{background:#ffe4e1!important;box-shadow:inset 0 0 0 2px #d92d20}
.schedule-grid td.proposal-exists.weekend{background:#f9d9d5!important}
.proposal-mark{display:block;color:#a61b12;font-weight:800;margin-top:3px;font-size:.68rem}
.reserved-mark{display:block;color:#245b96;font-weight:750;margin-top:3px;font-size:.68rem}

/* Documente & semnături v0.3.0 */
.document-image-wrap{background:#eef2f6;border:1px solid var(--line);border-radius:14px;padding:10px;overflow:auto;text-align:center}
.document-image-wrap img{max-width:100%;height:auto;display:block;margin:auto;border-radius:8px;background:#fff}
.document-pdf-frame{width:100%;height:min(72vh,820px);border:1px solid var(--line);border-radius:12px;background:#fff}
.document-hash{font-family:ui-monospace,SFMono-Regular,Consolas,monospace;word-break:break-all;font-size:.75rem}
.doc-private{border-left:5px solid var(--accent)}
@media(max-width:700px){.document-pdf-frame{height:62vh}}

.recipient-list{display:grid;grid-template-columns:repeat(auto-fit,minmax(250px,1fr));gap:8px;max-height:440px;overflow:auto;padding:8px;border:1px solid var(--line);border-radius:12px;background:#f8fafc}
.recipient-option{display:flex;align-items:flex-start;gap:10px;padding:10px;background:#fff;border:1px solid var(--line);border-radius:10px;cursor:pointer}
.recipient-option input{width:auto;margin-top:3px}
.recipient-option span{display:grid;gap:2px}
.recipient-option small{color:var(--muted)}

/* Document signing placement v0.3.2 */
.signature-place-wrap{position:relative;display:inline-block;max-width:100%;cursor:crosshair;overflow:hidden}
.signature-place-wrap img{display:block;max-width:100%;height:auto}
.signature-place-box{position:absolute;border:2px dashed #1264a3;background:rgba(18,100,163,.10);color:#0b4978;font-size:.72rem;font-weight:800;display:flex;align-items:center;justify-content:center;pointer-events:none;box-sizing:border-box;min-width:60px;min-height:24px}


/* Documente v0.3.3 */
.paste-upload-zone{border:2px dashed #9fb0c7;border-radius:16px;padding:24px;text-align:center;display:grid;gap:10px;justify-items:center;background:#f8fbff;outline:none;cursor:text}
.paste-upload-zone:focus,.paste-upload-zone.dragover{border-color:#1c4f82;background:#eef6ff;box-shadow:0 0 0 3px rgba(28,79,130,.10)}
.paste-upload-zone .selected-file{font-weight:750;color:#1d2b40;word-break:break-word}
.clipboard-preview-wrap{max-width:420px;border:1px solid #d8e0eb;border-radius:12px;padding:8px;background:#fff}
.clipboard-preview-wrap img{display:block;max-width:100%;max-height:420px;margin:auto}

/* Schedule generator/import/reset v0.4.0 */
.schedule-site{font-size:.68rem;margin-top:3px;max-width:68px}.danger-zone{border:1px solid #f3b4ad}.button.danger,button.danger{background:#b42318;color:#fff}.button.danger:hover,button.danger:hover{background:#8f1c13}
.schedule-ready-import .schedule-import-person{min-width:210px;max-width:260px}.schedule-import-person strong,.schedule-import-person select,.schedule-import-person small{display:block;margin-bottom:6px}.schedule-import-person select{width:100%}.schedule-ready-import .schedule-import-toggle{font-size:.75rem;padding:7px 9px;margin:4px 0 6px}.schedule-ready-import [hidden]{display:none!important}.schedule-import-excluded td{background:#f2f3f5}.schedule-import-excluded strong{text-decoration:line-through;color:var(--muted)}.schedule-import-excluded input{color:var(--muted);background:#f2f3f5}


/* Excel-like schedule UI v0.4.1 */
.schedule-grid.excel-grid,.schedule-grid.editor-grid,.schedule-grid.pref-grid{border-collapse:collapse!important;border:2px solid #374151!important;background:#fff}
.schedule-grid.excel-grid th,.schedule-grid.excel-grid td,.schedule-grid.editor-grid th,.schedule-grid.editor-grid td,.schedule-grid.pref-grid th,.schedule-grid.pref-grid td{border:1px solid #6b7280!important;padding:3px!important}
.schedule-grid .sticky-stat{min-width:230px;max-width:300px;background:#f8fafc;font-size:.76rem;line-height:1.25}
.schedule-grid td.stat-bad,.schedule-grid .stat-bad{background:#fee2e2!important;color:#991b1b!important;font-weight:800}
.coverage-row td{border-top:2px solid #111827!important;font-size:.68rem}
.coverage-cell small{display:block;white-space:normal;line-height:1.05;margin-top:2px}
.coverage-ok{background:#dcfce7!important;color:#166534}
.coverage-bad{background:#fecaca!important;color:#991b1b!important;box-shadow:inset 0 0 0 2px #dc2626}
.text-danger{color:#b91c1c;font-weight:800}
.schedule-grid select{min-width:45px;border:0;background:transparent;font-weight:700;padding:2px}
.schedule-grid .weekend{background:#f3f4f6!important}
@media(max-width:700px){.schedule-grid .sticky-stat{min-width:180px}.schedule-grid th,.schedule-grid td{font-size:.7rem}}

/* Live schedule validation v0.4.2 */
.schedule-grid td.live-conflict{background:#ffd6d6!important;box-shadow:inset 0 0 0 3px #c62828!important}
.schedule-grid td.live-warning{background:#fff2c7!important;box-shadow:inset 0 0 0 2px #c68400!important}
.live-conflict-card{position:sticky;top:4rem;z-index:8}
.live-error-text{border-left:4px solid #c62828}.live-warn-text{border-left:4px solid #c68400}
.site-fixed{display:inline-block;font-size:.7rem;margin-top:3px;padding:2px 5px;border:1px solid #9ca3af;border-radius:4px;background:#f3f4f6}

/* Schedule visual refinements v0.4.3 */
.schedule-grid .weekend{background:#ffd9a8!important}
.schedule-grid thead .weekend{background:#ffc978!important;color:#5a3100!important}
.schedule-grid tbody tr:hover td.weekend{background:#ffd093!important}
.schedule-grid .action-day{background:#dff4df!important}
.schedule-grid thead .action-day{background:#bfe8c2!important;color:#174d22!important}
.schedule-grid tbody tr:hover td.action-day{background:#d2efd5!important}
.schedule-grid td.code-c,.schedule-grid th.code-c{background:#fff2a8!important;color:#5f4b00!important}
.schedule-grid td.code-ced,.schedule-grid th.code-ced{background:#f9df8d!important;color:#6b5000!important}
.schedule-grid td.code-cep,.schedule-grid th.code-cep{background:#c9a27d!important;color:#3d260f!important}
.schedule-grid td.code-b,.schedule-grid th.code-b{background:#f5a3a3!important;color:#7a1111!important}
.schedule-grid td.code-c select,.schedule-grid td.code-ced select,.schedule-grid td.code-cep select,.schedule-grid td.code-b select{color:inherit!important}
.live-conflict-card{position:static!important;top:auto!important;z-index:auto!important;padding:10px 14px!important}
.live-conflict-toolbar{display:flex;gap:10px;align-items:center;justify-content:space-between;flex-wrap:wrap}
.live-conflict-toolbar .alert{margin:0;flex:1;min-width:260px}
.live-conflict-details{margin-top:10px;max-height:260px;overflow:auto}
.live-conflict-details[hidden]{display:none!important}
.live-conflict-card .button,.live-conflict-card button{padding:9px 12px}
@media(max-width:700px){.live-conflict-toolbar{display:grid}.live-conflict-toolbar .alert{min-width:0}}
/* Conflictele/acoperirea au prioritate vizuală peste culorile informative. */
.schedule-grid td.coverage-bad{background:#fecaca!important;color:#991b1b!important;box-shadow:inset 0 0 0 2px #dc2626!important}
.schedule-grid td.live-conflict{background:#ffd6d6!important;color:#7a1111!important;box-shadow:inset 0 0 0 3px #c62828!important}
.schedule-grid td.live-warning{background:#fff2c7!important;color:#6b4b00!important;box-shadow:inset 0 0 0 2px #c68400!important}

/* AI + SMART FOL v0.5.0 */
.smartfol-review-layout{display:grid;grid-template-columns:minmax(360px,.9fr) minmax(520px,1.3fr);gap:16px;align-items:start}.smartfol-review-layout>section{min-width:0}.smartfol-form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.smartfol-form-grid .sf-wide{grid-column:1/-1}.smartfol-form-grid textarea{width:100%;padding:12px;border:1px solid #cfd7e1;border-radius:10px;font:inherit}.smartfol-source-meta{font-size:.78rem;color:var(--muted)}
@media(max-width:950px){.smartfol-review-layout{grid-template-columns:1fr}.smartfol-form-grid{grid-template-columns:1fr}.smartfol-form-grid .sf-wide{grid-column:auto}}

/* Schedule realtime validation v0.5.7 */
.schedule-grid td.live-ok{box-shadow:inset 0 0 0 2px #16a34a!important}
.schedule-grid td.coverage-ok.live-ok{background:#dcfce7!important;color:#166534!important;box-shadow:inset 0 0 0 2px #16a34a!important}
#ai-review-card{scroll-margin-top:80px}
#ai-review-btn[disabled]{opacity:.65;cursor:wait}

/* Global refresh + SUPERADMIN impersonation v0.8.0 */
.top-refresh{padding:7px 10px;border-radius:9px;background:rgba(255,255,255,.14);border:1px solid rgba(255,255,255,.35);color:#fff;font-size:.78rem;white-space:nowrap}
.top-refresh:hover{background:rgba(255,255,255,.24)}
.impersonation-bar{position:sticky;top:60px;z-index:12;background:#7c2d12;color:#fff;padding:8px 16px;display:flex;gap:14px;align-items:center;justify-content:center;flex-wrap:wrap;box-shadow:0 2px 8px rgba(0,0,0,.16)}
.impersonation-bar form{margin:0}.impersonation-bar button{padding:7px 11px;background:#fff;color:#7c2d12}
@media(max-width:640px){.top-refresh{width:auto!important;padding:7px 9px}.impersonation-bar{top:60px;font-size:.86rem}.impersonation-bar button{width:auto!important}}
.parallel-progress{height:14px;border-radius:999px;background:#e5e7eb;overflow:hidden}.parallel-progress>span{display:block;height:100%;background:#16a34a;transition:width .25s ease}
.recipient-quick-actions{margin-bottom:8px}.recipient-quick-actions button{padding:8px 10px;font-size:.82rem}

/* Grafic v2 · editor direct tip Excel */
.schedule-edit-toolbar{position:sticky;top:68px;z-index:8;background:#f8fafc;border:1px solid #cbd5e1;border-radius:14px;padding:10px 12px;margin-bottom:10px;display:flex;gap:10px;align-items:center;flex-wrap:wrap;box-shadow:0 4px 14px rgba(15,23,42,.08)}
.schedule-edit-toolbar .actions{margin:0}.schedule-edit-toolbar .quick-code,.schedule-edit-toolbar .quick-site{min-width:42px;padding:7px 10px}
.schedule-direct-input{width:48px;min-width:48px;border:0!important;outline:0;background:transparent!important;text-align:center;font:inherit;font-weight:800;color:inherit;padding:5px 2px!important;text-transform:uppercase;border-radius:0!important;box-shadow:none!important}
.schedule-code-cell .schedule-direct-input{width:48px}.schedule-direct-input:focus{background:rgba(255,255,255,.78)!important;box-shadow:inset 0 0 0 2px #2563eb!important}
.schedule-grid td.cell-selected{box-shadow:inset 0 0 0 3px #2563eb!important;position:relative}.schedule-grid td.cell-selected.live-conflict{box-shadow:inset 0 0 0 3px #dc2626!important}
.schedule-grid td.fixed-origin{background-image:linear-gradient(135deg,rgba(37,99,235,.08) 0,rgba(37,99,235,.08) 7px,transparent 7px,transparent 14px)}
.fixed-mark{display:block;font-size:.56rem;color:#1d4ed8;line-height:1.05;font-weight:800}.proposal-mark,.reserved-mark{display:block;font-size:.56rem;line-height:1.05}.proposal-mark{color:#9a3412}.reserved-mark{color:#166534}
.schedule-direct-input.input-invalid{background:#fee2e2!important;color:#991b1b!important;box-shadow:inset 0 0 0 2px #dc2626!important}
.direct-grid .schedule-cell{padding:0!important}.direct-grid .schedule-direct-input{width:100%;min-width:48px}
.progress-shell{height:18px;background:#e5e7eb;border-radius:999px;overflow:hidden}.progress-bar{height:100%;background:#2563eb;transition:width .18s ease}
.schedule-grid td.code-c .schedule-direct-input,.schedule-grid td.code-ced .schedule-direct-input,.schedule-grid td.code-cep .schedule-direct-input,.schedule-grid td.code-b .schedule-direct-input{color:inherit!important}
@media(max-width:700px){.schedule-edit-toolbar{top:60px}.schedule-direct-input{min-width:42px;width:42px;font-size:.72rem;padding:5px 1px!important}}
/* Contorul rămâne la finalul rândului, ca în modelul Excel; numai numele rămâne înghețat. */
.schedule-grid .sticky-stat,.schedule-grid thead .sticky-stat{position:static!important;left:auto!important;z-index:auto!important;min-width:190px;max-width:280px}


/* CMVD v1.0.1 · grafic lunar încadrat + sărbători propagate vizual */
@media(min-width:1000px){
  .wide-container{width:calc(100% - 12px);max-width:none;margin-left:auto;margin-right:auto}
  .schedule-editor-wrap{overflow-x:hidden}
  .schedule-editor-wrap .schedule-grid{width:100%!important;min-width:0!important;table-layout:fixed;font-size:clamp(.62rem,.72vw,.80rem)}
  .schedule-editor-wrap .schedule-grid .sticky-name{width:176px!important;min-width:176px!important;max-width:176px!important}
  .schedule-editor-wrap .schedule-grid .sticky-stat{width:132px!important;min-width:132px!important;max-width:132px!important}
  .schedule-editor-wrap .schedule-grid .day-head,.schedule-editor-wrap .schedule-grid .schedule-cell,.schedule-editor-wrap .schedule-grid .schedule-code-cell,.schedule-editor-wrap .schedule-grid .coverage-cell{min-width:0!important;width:auto!important;padding:2px 1px!important;overflow:hidden}
  .schedule-editor-wrap .schedule-direct-input{width:100%!important;min-width:0!important;padding:5px 0!important;font-size:inherit}
  .schedule-editor-wrap .day-head span{font-size:.88em}.schedule-editor-wrap .day-head small{font-size:.76em;line-height:1.05}
  .schedule-editor-wrap .fixed-mark,.schedule-editor-wrap .proposal-mark,.schedule-editor-wrap .pref-mark,.schedule-editor-wrap .reserved-mark{font-size:.48rem;white-space:nowrap;overflow:hidden;text-overflow:clip}
  .schedule-editor-wrap .coverage-cell small{display:none}
  .schedule-editor-wrap .coverage-cell strong{font-size:.72rem}
}
@media(min-width:1000px) and (max-width:1400px){
  .schedule-editor-wrap .schedule-grid .sticky-name{width:150px!important;min-width:150px!important;max-width:150px!important;font-size:.70rem}
  .schedule-editor-wrap .schedule-grid .sticky-stat{width:108px!important;min-width:108px!important;max-width:108px!important;font-size:.66rem}
  .schedule-editor-wrap .schedule-grid{font-size:.66rem}
}
.schedule-editor-wrap .holiday-day{background:#eef0ff!important}
.schedule-editor-wrap thead .holiday-day{background:#dfe3ff!important}

/* CMVD v1.2.0 · Mesaje urgente */
.emergency-card{background:#c40000!important;color:#fff!important;border-color:#980000!important}
.emergency-card h1,.emergency-card h2,.emergency-card strong,.emergency-card a{color:#fff!important}
.emergency-card .muted{color:#ffe8e8!important}
.emergency-card .badge{background:#fff!important;color:#a40000!important;border-color:#fff!important}
.emergency-card .button.danger,.emergency-card button.danger{background:#fff!important;color:#a40000!important;border-color:#fff!important}

/* Acasă: butoane grupate, pentru telefon și laptop. */
.cmvd-home .hero{padding:16px 0 12px}.cmvd-home .hero h1{font-size:clamp(1.35rem,4vw,2rem)}
.home-groups{display:grid;gap:24px}.home-group{border-top:2px solid #c8dafa;padding-top:20px}.home-group h2{font-size:1.15rem;color:#0a1551;margin:0 0 16px}
.home-buttons{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px}
.home-tile{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;min-height:162px;min-width:0;padding:22px 14px;background:#fff;border:1.5px solid #d4ddf7;border-radius:20px;color:#0a1551;text-align:center;text-decoration:none;box-sizing:border-box;transition:border-color .15s,box-shadow .15s,transform .15s}
.home-tile:hover{border-color:#1795e4;box-shadow:0 5px 18px #17385f10;transform:translateY(-2px)}.home-tile:focus-visible{outline:3px solid #087fca;outline-offset:4px}
.home-icon{color:#ff6100;display:grid;place-items:center}.home-icon svg{width:42px;height:42px}.home-label{font-size:1.03rem;font-weight:750;line-height:1.3;overflow-wrap:anywhere}.home-hint{font-size:.79rem;line-height:1.35;color:#607089}
.home-tile.is-disabled{background:#f8fafc;border-style:dashed;color:#717b8d}.home-tile.is-disabled .home-icon{color:#99a6b7}.home-tile.is-disabled:hover{box-shadow:none;transform:none;border-color:#d4ddf7}
@media(max-width:940px){.home-buttons{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:640px){.home-buttons{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.home-tile{min-height:156px;padding:20px 10px;border-radius:18px;gap:12px}.home-label{font-size:.93rem}.home-icon svg{width:38px;height:38px}.home-group h2{font-size:1.05rem}.home-groups{gap:20px}}

/* CMVD 1.3.0 — shared application design and nominal overtime. */
:root{--bg:#f3f6fa;--line:#dce5ef;--accent:#17385f;--accent2:#146bba;--radius:16px}
html{font-size:16px;line-height:1.45}body{background:linear-gradient(180deg,#eef3fa 0,#f6f8fb 420px);min-height:100vh}a{color:#185c99}h1,h2,h3{line-height:1.2;letter-spacing:-.015em}h2{font-size:1.3rem}.hero{padding-top:24px}.hero p{max-width:72ch}.card,.step-card{box-shadow:0 2px 10px #17385f06}.grid,.stack,.actions,.card,.field,main,label{min-width:0}.grid{grid-template-columns:repeat(auto-fit,minmax(min(100%,230px),1fr))}.table-wrap{max-width:100%;overscroll-behavior-x:contain}.table-wrap td{overflow-wrap:anywhere}.card p{margin:.25em 0 .7em}img{max-width:100%}
input:not([type=checkbox]):not([type=radio]):not([type=hidden]):not([type=range]):not([type=color]),select,textarea{font:inherit;color:var(--text);border:1px solid #c6d3e0;border-radius:10px;padding:10px 12px;background:#fff;min-height:44px;max-width:100%;box-sizing:border-box}textarea{resize:vertical}input:focus-visible,select:focus-visible,textarea:focus-visible,button:focus-visible,.button:focus-visible,a:focus-visible,summary:focus-visible{outline:3px solid #3a91db;outline-offset:3px}
input[type=checkbox],input[type=radio]{appearance:auto!important;display:inline-block!important;width:22px!important;height:22px!important;min-width:22px!important;max-width:22px!important;min-height:22px!important;max-height:22px!important;padding:0!important;margin:2px 7px 2px 0!important;vertical-align:middle;flex:0 0 22px;accent-color:#146bba;cursor:pointer;box-shadow:none!important;border-radius:4px}input[type=radio]{border-radius:50%}.check-label{display:flex!important;align-items:flex-start;gap:8px;font-weight:500;padding:9px 0;cursor:pointer;line-height:1.45}.check-label input{margin-top:2px!important}.check-label span{min-width:0}
.button,button{min-height:44px;font-size:.92rem;line-height:1.25;border-radius:12px;padding:11px 15px;transition:background .15s,box-shadow .15s;white-space:normal;overflow-wrap:anywhere}.button:hover,button:hover{box-shadow:0 3px 10px #17385f1a}.button svg,button svg{width:23px;height:23px;flex-shrink:0}.topbar{gap:14px;min-height:60px;background:#163754;box-shadow:0 2px 12px #0d263222;z-index:50}.top-user{margin-left:auto;gap:12px}.top-refresh{min-height:34px;padding:7px 10px;font-size:.76rem;width:auto}.app-menu{margin:0}.app-menu>summary{display:flex;align-items:center;gap:8px;color:white;font-weight:650;font-size:.86rem;padding:8px 12px;border:1px solid #ffffff40;border-radius:10px;list-style:none;min-height:40px}.app-menu>summary::-webkit-details-marker{display:none}.app-menu>summary svg{width:21px;height:21px}.app-menu[open]>summary{background:#ffffff18}.app-menu-panel{position:fixed;top:66px;left:50%;transform:translateX(-50%);width:min(960px,calc(100% - 20px));max-height:calc(100dvh - 88px);overflow-y:auto;background:white;color:var(--text);border:1px solid var(--line);box-shadow:0 20px 60px #08274233;border-radius:18px;padding:18px;z-index:60;overscroll-behavior:contain}.app-menu-panel section+section{margin-top:22px}.app-menu-panel h2{font-size:.82rem;text-transform:uppercase;letter-spacing:.05em;color:var(--muted);margin:0 0 9px}.app-menu-tiles{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px}.app-menu-tiles a{display:flex;align-items:center;gap:9px;color:var(--accent);background:#f5f8fc;border:1px solid #e1e8f0;padding:12px;border-radius:12px;text-decoration:none;font-size:.88rem;min-height:60px}.app-menu-tiles a:hover{background:#e8f3fc;border-color:#b3d6f1}.app-menu-tiles svg{width:25px;height:25px;color:#147ac0;flex-shrink:0}
.nav{gap:8px}.nav a{min-height:42px;display:inline-flex;align-items:center;justify-content:center;font-size:.87rem}.nav a[aria-current=page]{background:#17385f;color:#fff;border-color:#17385f}.module-index .grid>.card h2{font-size:1.15rem}.module-index .grid>.card p{font-size:.9rem}.module-index .grid>.card{padding:18px}.module-tiles{margin-bottom:22px}.module-tiles .home-tile{min-height:146px}
.ot-counters{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;margin:16px 0}.ot-counter{display:flex;gap:17px;align-items:flex-start;padding:23px}.ot-counter-icon{width:49px;height:49px;background:#edf5fc;color:#1877b6;border-radius:14px;display:grid;place-items:center;flex:0 0 49px}.ot-counter-icon svg{width:29px;height:29px}.ot-counter .kpi{font-size:2.2rem;font-variant-numeric:tabular-nums;line-height:1.2;margin:8px 0}.ot-counter .kpi small{font-size:1rem;font-weight:500}.ot-counter p{font-size:.89rem}.ot-negative .kpi{color:#a95816}.ot-primary-actions{margin:18px 0 24px}.ot-tabs{padding:10px 0}.ot-case-grid{display:grid;grid-template-columns:1.2fr .8fr;gap:16px}.ot-section{margin-top:20px}.ot-signature-image{display:block;width:100%;max-width:350px;max-height:120px;object-fit:contain;border:1px solid var(--line);border-radius:12px;padding:8px;background:#fff;margin:10px 0}.ot-signature canvas{display:block;width:100%;height:150px;touch-action:none;border:2px dashed #99b4cb;border-radius:12px;background:#fff}.ot-decision-buttons{display:grid;grid-template-columns:repeat(auto-fit,minmax(190px,1fr));gap:10px}.ot-document-row{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:15px 0;border-bottom:1px solid var(--line);overflow-wrap:anywhere}.ot-document-row>div{min-width:0}.ot-document-row .actions{flex-shrink:0}.ot-import-map{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.ot-import-person{background:#f7f9fc;border:1px solid var(--line);border-radius:12px;padding:12px}.ot-import-person strong{display:block;margin-bottom:8px}.ot-import-person .badge{margin-bottom:8px}.ot-pagination{margin-top:16px;align-items:center;justify-content:space-between}.ot-history td:nth-last-child(2){max-width:440px;white-space:pre-line}
@media(max-width:800px){.app-menu-tiles{grid-template-columns:repeat(3,minmax(0,1fr))}.ot-counter{gap:12px;padding:17px}.ot-case-grid{grid-template-columns:1fr}}
@media(max-width:640px){html{font-size:16px}.container{width:calc(100% - 24px)}.wide-container{width:calc(100% - 12px)}.topbar{padding:9px 12px;gap:10px}.brand{font-size:1.05rem}.top-user{gap:10px}.top-user a{font-size:.82rem}.top-refresh{font-size:0;width:34px;padding:5px}.top-refresh:before{content:'↻';font-size:21px}.app-menu-panel{padding:13px}.app-menu-tiles{grid-template-columns:repeat(2,minmax(0,1fr))}.app-menu-tiles a{flex-direction:column;text-align:center;gap:8px;padding:14px 8px;font-size:.85rem}.app-menu-tiles svg{width:30px;height:30px}.hero{padding-top:16px}.hero h1{font-size:1.75rem}.hero p{font-size:1rem}.actions{display:flex;flex-wrap:wrap;gap:8px}.actions>.button,.actions>button{flex:1 1 145px;width:auto}.actions>form,.actions>label{flex:1 1 200px;max-width:100%}.actions form>button{width:auto}.card{padding:16px}.ot-counters{grid-template-columns:1fr;gap:12px}.ot-counter .kpi{font-size:2rem}.ot-counter-icon{width:44px;height:44px;flex-basis:44px}.ot-import-map{grid-template-columns:1fr}.ot-document-row{flex-direction:column;align-items:stretch}.ot-document-row .actions{flex-shrink:1}.ot-primary-actions{display:grid;grid-template-columns:1fr 1fr}.ot-primary-actions a{font-size:.82rem;padding:12px 9px;flex-direction:column;text-align:center;width:100%}.ot-tabs{display:flex;flex-wrap:wrap;gap:7px}.ot-tabs a{flex:1 1 100px;padding:9px 10px}.ot-decision-buttons{grid-template-columns:1fr}.module-index .grid{grid-template-columns:1fr}.module-index .module-tiles{grid-template-columns:repeat(2,minmax(0,1fr))}.module-tiles .home-tile{min-height:134px}.ot-pagination{display:flex}.ot-pagination span{order:-1;flex-basis:100%;text-align:center}.table-wrap button,.table-wrap .button{min-width:88px;width:auto}.daily-simple .sig-card{min-width:0}}
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important;transition:none!important}}
.schedule-grid select,.schedule-grid input:not([type=checkbox]):not([type=radio]){min-height:30px;padding:3px 4px;font-size:inherit}
.ot-balance-basis{border:1px solid #bbd3e5;border-radius:12px;background:#f6faff;padding:14px;min-width:0}.ot-balance-basis legend{font-weight:650;color:var(--accent);font-size:.95rem;padding:0 7px}.ot-balance-basis p{font-size:.9rem}
/* Approval requests keep their full width even when navigation inserts rows. */
.container.ot-case-layout{width:calc(100% - 32px);max-width:1600px;display:block}
.ot-case-sidebar{position:sticky;top:var(--ot-case-sticky-top,80px);z-index:20;margin-bottom:16px;padding:8px 0;background:#edf9f9;border-bottom:1px solid #b9dedd}
.ot-case-content{min-width:0}.ot-case-layout .ot-case-grid{grid-template-columns:minmax(0,1fr)}
.ot-case-balance{display:flex;align-items:center;gap:16px;min-width:0}
.ot-case-balance-values{display:flex;gap:8px;flex:0 0 auto;margin:0}
.ot-case-balance-values>div{display:flex;flex-direction:column;justify-content:space-between;width:100px;height:100px;box-sizing:border-box;padding:8px;border:1px solid #bdd8eb;border-radius:10px;background:#e8f2ff;color:#185c99}
.ot-case-balance-values>div+div{background:#ddf6ee;border-color:#aad9cd;color:#087564}
.ot-case-balance-values>div.ot-case-debt{background:#fff0dd;border-color:#e4c9a5;color:#905211}
.ot-case-balance-values dt{font-size:12px;line-height:1.2;font-weight:650}
.ot-case-balance-values dt small{display:block;font-size:10px;line-height:1.2;font-weight:400;margin-top:3px}
.ot-case-balance-values dd{margin:3px 0 0;padding:0;background:transparent;font-size:24px;line-height:1.15;font-weight:750;font-variant-numeric:tabular-nums;white-space:nowrap}
.ot-case-balance-values dd span{font-size:12px;font-weight:600}
.ot-case-balance-context{min-width:0;max-width:520px;font-size:.86rem;line-height:1.35}
.ot-case-balance-name{margin:0;font-weight:700;overflow-wrap:anywhere}
.ot-case-balance-context p{margin:4px 0 0}.ot-case-balance-context small{font-size:.75rem;color:var(--muted)}
.ot-case-work-pay,.ot-case-balance-note{font-size:.75rem;color:var(--muted)}
@media(max-width:640px){.container.ot-case-layout{width:calc(100% - 20px)}.ot-case-balance{gap:10px}.ot-case-balance-values>div{width:90px;height:90px;padding:7px}.ot-case-balance-values dd{font-size:22px}.ot-case-balance-context{font-size:.75rem}.ot-case-balance-context small{font-size:.68rem}.ot-case-sidebar{margin-bottom:10px}}
@media print{.ot-case-sidebar{position:static;background:white}}
