
:root {
  color-scheme: light;
  --ink: #172c2a;
  --muted: #768581;
  --line: #e6ece9;
  --paper: #ffffff;
  --canvas: #f5f7f6;
  --green: #1f7564;
  --green-dark: #155b4e;
  --green-soft: #e8f3ef;
  --lime: #d8ed9a;
  --amber: #b87827;
  --amber-soft: #fff4df;
  --red: #f40a11;
  --red-soft: #fff0f0;
  --yellow: #ffd600;
  --blue: #4f718d;
  --blue-soft: #edf3f8;
  --shadow: 0 12px 34px rgba(24, 47, 42, .055);
  font-family: 'Poppins', 'Poppins', sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; min-height: 100vh; background: var(--canvas); color: var(--ink); }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .58; }
.hidden { display: none !important; }
.app-shell { min-height: 100vh; }

.sidebar {
  position: fixed; inset: 0 auto 0 0; z-index: 5; display: flex; width: 248px; flex-direction: column;
  padding: 27px 17px 20px; background: #173b35; color: #edf5f1;
}
.brand { display: flex; align-items: center; gap: 11px; margin: 0 8px 52px; color: inherit; text-decoration: none; }
.brand-mark { display: grid; width: 37px; height: 37px; place-items: center; border-radius: 12px; background: var(--lime); color: #173b35; font: 800 24px/1 'Poppins', sans-serif; letter-spacing: -3px; }
.brand-mark span { color: var(--green); }
.brand strong { display: block; font: 700 15px/1.25 'Poppins', sans-serif; letter-spacing: -.25px; }
.brand small { display: block; margin-top: 4px; color: #a9bfba; font-size: 11px; }
.nav-label, .eyebrow { color: #91aaa4; font-size: 9px; font-weight: 700; letter-spacing: 1.45px; }
.nav-label { margin: 0 12px 12px; }
.primary-nav { display: grid; gap: 6px; }
.nav-item { display: flex; align-items: center; gap: 12px; width: 100%; border: 0; border-radius: 10px; padding: 11px 12px; background: transparent; color: #c5d5d0; text-align: left; font-size: 12px; font-weight: 600; transition: .16s ease; }
.nav-item:hover { background: rgba(255,255,255,.08); color: #fff; }
.nav-item.is-active { background: rgba(228, 245, 238, .13); color: #fff; box-shadow: inset 3px 0 var(--lime); }
.nav-icon { display: grid; width: 19px; height: 19px; place-items: center; color: #bed3cc; font-size: 15px; }
.sidebar-bottom { margin-top: auto; padding: 14px 11px 2px; border-top: 1px solid rgba(255,255,255,.11); }
.sidebar-note { display: flex; align-items: center; gap: 8px; color: #d8e5e0; font-size: 10px; font-weight: 600; }
.online-dot { width: 7px; height: 7px; border-radius: 50%; background: #b9df80; box-shadow: 0 0 0 3px rgba(185,223,128,.13); }
.sidebar-bottom p { margin: 9px 0 0 15px; color: #91aaa4; font-size: 10px; line-height: 1.5; }

.app-main { min-height: 100vh; margin-left: 248px; }
.topbar { position: sticky; top: 0; z-index: 4; display: flex; height: 72px; align-items: center; justify-content: space-between; gap: 18px; padding: 0 clamp(25px, 4.4vw, 64px); border-bottom: 1px solid var(--line); background: rgba(255,255,255,.92); backdrop-filter: blur(14px); }
.topbar-context { display: grid; gap: 5px; color: #556561; font-size: 11px; font-weight: 600; }
.topbar-context .eyebrow { color: #99a6a1; font-size: 8px; }
.profile-switcher { display: grid; gap: 4px; color: #89958f; font-size: 9px; font-weight: 600; }
.profile-switcher select { max-width: 230px; border: 0; outline: none; background: transparent; color: var(--ink); font-size: 11px; font-weight: 700; }
.mobile-brand { display: none; align-items: center; gap: 8px; font: 700 13px 'Poppins', sans-serif; }
.mobile-brand .brand-mark { width: 30px; height: 30px; border-radius: 10px; font-size: 20px; }
.content { width: min(1120px, 100%); margin: 0 auto; padding: 38px clamp(25px, 4.4vw, 64px) 70px; }
.page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 27px; }
.heading-copy .eyebrow { color: var(--green); }
h1, h2, h3, p { margin-top: 0; }
h1 { margin: 8px 0 7px; font: 700 clamp(25px, 3vw, 34px)/1.15 'Poppins', sans-serif; letter-spacing: -1.1px; }
.page-subtitle { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.55; }
.date-chip { display: flex; align-items: center; gap: 8px; white-space: nowrap; border: 1px solid var(--line); border-radius: 9px; padding: 9px 12px; background: #fff; color: #556561; font-size: 10px; font-weight: 600; }
.date-chip span { color: var(--green); font-size: 14px; }

.hero-card { position: relative; display: flex; min-height: 153px; align-items: center; justify-content: space-between; overflow: hidden; margin-bottom: 27px; border-radius: 16px; padding: 24px 29px; background: #e5f0e9; }
.hero-card:after { position: absolute; top: -89px; right: 3%; width: 260px; height: 260px; border: 1px solid rgba(34,109,92,.12); border-radius: 50%; box-shadow: 0 0 0 24px rgba(34,109,92,.035), 0 0 0 50px rgba(34,109,92,.025); content: ''; }
.hero-copy { position: relative; z-index: 1; max-width: 460px; }
.hero-label { color: #558475; font-size: 9px; font-weight: 700; letter-spacing: 1.15px; text-transform: uppercase; }
.hero-title { margin: 8px 0 5px; font: 700 20px/1.25 'Poppins', sans-serif; letter-spacing: -.45px; }
.hero-caption { margin: 0; color: #668078; font-size: 11px; line-height: 1.5; }
.progress-wrap { position: relative; z-index: 1; display: flex; align-items: center; gap: 14px; min-width: 175px; }
.progress-ring { position: relative; display: grid; width: 59px; height: 59px; place-items: center; border-radius: 50%; background: conic-gradient(var(--green) var(--progress), rgba(31,117,100,.16) var(--progress)); color: var(--green-dark); font: 700 12px 'Poppins', sans-serif; }
.progress-ring:before { position: absolute; inset: 5px; border-radius: 50%; background: #e5f0e9; content: ''; }
.progress-ring span { position: relative; z-index: 1; }
.progress-copy strong { display: block; font: 700 17px 'Poppins', sans-serif; }
.progress-copy small { color: #668078; font-size: 10px; }

.section-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 29px 0 12px; }
.section-heading h2 { margin: 0; font: 700 15px 'Poppins', sans-serif; letter-spacing: -.3px; }
.section-heading p { margin: 4px 0 0; color: var(--muted); font-size: 10px; }
.count-pill { display: inline-flex; min-width: 22px; height: 22px; align-items: center; justify-content: center; border-radius: 7px; padding: 0 7px; background: #e9efec; color: #5b6d67; font-size: 10px; font-weight: 700; }
.task-list { display: grid; gap: 9px; }
.task-card { border: 1px solid var(--line); border-radius: 12px; padding: 16px 17px; background: var(--paper); box-shadow: 0 3px 11px rgba(26,53,45,.025); transition: border-color .16s, box-shadow .16s; }
.task-card:hover { border-color: #d5e4dd; box-shadow: var(--shadow); }
.task-card.is-complete { border-color: #d2e7dc; }
.task-top { display: flex; justify-content: space-between; gap: 16px; }
.task-copy { min-width: 0; }
.task-context { margin-bottom: 6px; color: #7b8c85; font-size: 9px; font-weight: 600; }
.task-title { margin: 0; max-width: 750px; font-size: 12px; font-weight: 700; line-height: 1.5; }
.task-meta { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 8px; }
.tag { display: inline-flex; align-items: center; border-radius: 5px; padding: 4px 7px; background: #f1f4f2; color: #728079; font-size: 8px; font-weight: 700; }
.tag.frequency { background: var(--blue-soft); color: var(--blue); }
.tag.status-done { background: var(--green-soft); color: var(--green-dark); }
.tag.status-pending { background: #f3f4f2; color: #7c8983; }
.task-state { display: flex; flex: 0 0 auto; align-items: center; gap: 6px; }
.choice-button { min-width: 71px; border: 1px solid #dfe7e3; border-radius: 7px; padding: 7px 10px; background: #fff; color: #718079; font-size: 10px; font-weight: 700; transition: .15s ease; }
.choice-button:hover { border-color: #9ac2b5; color: var(--green-dark); }
.choice-button.is-selected.yes { border-color: #abd4c4; background: var(--green-soft); color: var(--green-dark); }
.choice-button.is-selected.no { border-color: #e7bcb4; background: var(--red-soft); color: var(--red); }
.task-reason { display: none; margin-top: 13px; border-top: 1px solid #f0e6e3; padding-top: 12px; }
.task-reason.is-open { display: block; }
.task-reason label, .field-label { display: block; margin-bottom: 6px; color: #52625d; font-size: 10px; font-weight: 700; }
.task-reason textarea, .form-control { width: 100%; min-height: 37px; border: 1px solid #dfe7e3; border-radius: 7px; outline: none; padding: 9px 10px; background: #fff; color: var(--ink); font-size: 11px; transition: border .15s, box-shadow .15s; }
.task-reason textarea { min-height: 68px; resize: vertical; }
.task-reason textarea:focus, .form-control:focus { border-color: #83b8a6; box-shadow: 0 0 0 3px rgba(31,117,100,.09); }
.reason-actions { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 8px; }
.form-hint { color: #9b746a; font-size: 9px; }
.task-evidence { display: none; margin-top: 13px; border-top: 1px solid #e7edf3; padding-top: 14px; }
.task-evidence.is-open { display: grid; grid-template-columns: 1fr; gap: 7px; }
.task-evidence > div:first-child strong { display: block; color: var(--ink); font-size: 12px; }
.task-evidence > div:first-child p { margin: 4px 0 7px; color: var(--muted); font-size: 10px; }
.task-evidence .field-label { margin: 0; }
.task-evidence .evidence-or { margin-top: 3px; }
.task-evidence .evidence-file { min-height: 40px; padding: 7px; }
.evidence-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 5px; }
.evidence-recorded a, .evidence-view-link { color: var(--red); font-weight: 700; text-decoration: underline; text-underline-offset: 2px; }
.evidence-required-tag { background: #fff3d6; color: #875a00; }
.evidence-link-row { display: flex; align-items: center; gap: 7px; margin-top: 7px; }
.evidence-link-row .form-control { flex: 1; }
.evidence-link-row button { min-width: 36px; padding-inline: 8px; }
.evidence-add-link { justify-self: start; }
.evidence-links { display: grid; gap: 4px; min-width: 95px; }
.primary-button, .secondary-button, .quiet-button { display: inline-flex; min-height: 34px; align-items: center; justify-content: center; gap: 7px; border-radius: 7px; padding: 8px 12px; font-size: 10px; font-weight: 700; transition: .15s ease; }
.primary-button { border: 1px solid var(--green); background: var(--green); color: #fff; }
.primary-button:hover { border-color: var(--green-dark); background: var(--green-dark); }
.secondary-button { border: 1px solid #dfe7e3; background: #fff; color: #52625d; }
.secondary-button:hover { border-color: #b8cec4; background: #f8fbf9; }
.quiet-button { min-height: 30px; border: 1px solid transparent; background: transparent; color: var(--green-dark); }
.quiet-button:hover { background: var(--green-soft); }
.button-icon { font-size: 14px; line-height: 0; }
.save-state { display: inline-flex; align-items: center; gap: 5px; color: var(--green); font-size: 9px; font-weight: 700; }

.repeat-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 9px; }
.repeat-card { display: flex; min-height: 116px; flex-direction: column; justify-content: space-between; border: 1px solid var(--line); border-radius: 12px; padding: 15px; background: #fff; }
.repeat-card .task-title { font-size: 11px; }
.repeat-bottom { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 14px; }
.event-count { color: #74837d; font-size: 9px; }
.event-list { display: grid; gap: 5px; margin-top: 10px; border-top: 1px solid #eef2f0; padding-top: 9px; }
.event-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: #64736d; font-size: 9px; }
.event-row time { color: #85928d; font-variant-numeric: tabular-nums; }
.empty-card { border: 1px dashed #dbe4df; border-radius: 11px; padding: 17px; color: #82918b; background: rgba(255,255,255,.55); font-size: 10px; line-height: 1.55; }
.repeat-grid > .empty-card, .repeat-grid > .notice { grid-column: 1 / -1; }
.empty-icon { display: grid; width: 30px; height: 30px; place-items: center; margin-bottom: 8px; border-radius: 9px; background: #ecf3ef; color: var(--green); font-size: 15px; }
.notice { display: flex; align-items: flex-start; gap: 9px; border: 1px solid #efdfbd; border-radius: 10px; padding: 11px 13px; background: #fff9eb; color: #806538; font-size: 10px; line-height: 1.5; }

.calendar-panel, .management-panel, .history-panel, .panel { border: 1px solid var(--line); border-radius: 14px; background: #fff; box-shadow: 0 4px 16px rgba(25,50,43,.025); }
.calendar-layout { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(250px, .8fr); align-items: start; gap: 14px; }
.calendar-panel { padding: 20px; }
.calendar-toolbar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.calendar-toolbar strong { font: 700 14px 'Poppins', sans-serif; }
.month-controls { display: flex; gap: 5px; }
.icon-button { display: grid; width: 29px; height: 29px; place-items: center; border: 1px solid var(--line); border-radius: 7px; background: #fff; color: #53645e; font-size: 13px; }
.icon-button:hover { border-color: #a9cabe; color: var(--green); }
.calendar-grid { display: grid; grid-template-columns: repeat(7, minmax(0,1fr)); gap: 4px; }
.weekday { padding: 4px 0 8px; color: #91a099; text-align: center; font-size: 8px; font-weight: 700; text-transform: uppercase; }
.calendar-day { position: relative; display: flex; min-height: 55px; flex-direction: column; align-items: center; justify-content: center; gap: 5px; border: 1px solid transparent; border-radius: 8px; background: transparent; color: #50615a; font-size: 10px; }
.calendar-day:hover:not(:disabled) { border-color: #dbe8e1; background: #f7faf8; }
.calendar-day.is-selected { border-color: var(--green) !important; background: #eef6f2 !important; color: var(--green-dark); font-weight: 700; }
.calendar-day.is-today:not(.is-selected) { color: var(--green-dark); font-weight: 700; }
.calendar-day:disabled { color: #c3cbc7; }
.day-dot { width: 5px; height: 5px; border-radius: 50%; background: transparent; }
.status-complete .day-dot { background: #4b9a73; }
.status-incomplete .day-dot { background: #dfa64f; }
.status-no_records .day-dot { background: #d6ded9; }
.status-future .day-dot { background: transparent; }
.calendar-legend { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 16px; border-top: 1px solid #eff2f0; padding-top: 13px; }
.legend-item { display: inline-flex; align-items: center; gap: 5px; color: #829089; font-size: 8px; }
.legend-dot { width: 6px; height: 6px; border-radius: 50%; }
.legend-dot.complete { background: #4b9a73; }
.legend-dot.incomplete { background: #dfa64f; }
.legend-dot.no-records { background: #d6ded9; }
.history-panel { min-height: 260px; padding: 18px; }
.history-panel h2 { margin: 0 0 3px; font: 700 13px 'Poppins', sans-serif; }
.history-date-label { margin: 0 0 14px; color: #83918b; font-size: 9px; }
.history-section-label { margin: 13px 0 7px; color: #819088; font-size: 8px; font-weight: 700; letter-spacing: .8px; text-transform: uppercase; }
.history-item { border-top: 1px solid #eff2f0; padding: 10px 0; }
.history-item:first-of-type { border-top: 0; }
.history-item strong { display: block; font-size: 10px; line-height: 1.45; }
.history-item p { margin: 4px 0 0; color: #798780; font-size: 9px; line-height: 1.5; }
.history-result { display: inline-block; margin-top: 5px; border-radius: 4px; padding: 3px 6px; font-size: 8px; font-weight: 700; }
.history-result.yes { background: var(--green-soft); color: var(--green-dark); }
.history-result.no { background: var(--red-soft); color: var(--red); }

.management-summary { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 10px; margin-bottom: 14px; }
.metric-card { border: 1px solid var(--line); border-radius: 11px; padding: 14px 16px; background: #fff; }
.metric-card span { display: block; color: #86938d; font-size: 9px; }
.metric-card strong { display: block; margin-top: 5px; font: 700 20px 'Poppins', sans-serif; }
.management-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; margin-bottom: 14px; }
.panel { padding: 17px; }
.create-activity-panel { margin-bottom: 14px; }
.panel-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.panel-heading h2 { margin: 0; font: 700 13px 'Poppins', sans-serif; }
.panel-heading p { margin: 4px 0 0; color: var(--muted); font-size: 9px; line-height: 1.4; }
.form-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; }
.form-field.full { grid-column: 1/-1; }
.form-control { min-height: 35px; padding: 8px 9px; }
select.form-control { min-width: 0; }
.form-footer { display: flex; align-items: center; justify-content: flex-end; gap: 8px; margin-top: 12px; }
.checkbox-field { display: flex; align-items: center; gap: 7px; color: #61716a; font-size: 10px; font-weight: 600; }
.checkbox-field input { accent-color: var(--green); }
.profile-list { display: grid; gap: 6px; }
.profile-row { display: grid; grid-template-columns: minmax(0,1fr) minmax(120px,.8fr) auto auto; align-items: center; gap: 7px; border-top: 1px solid #eef2f0; padding: 8px 0; }
.profile-row:first-child { border-top: 0; }
.profile-row strong { font-size: 9px; }
.profile-row .form-control { min-height: 30px; font-size: 9px; }
.activity-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 16px 0 9px; }
.activity-toolbar h2 { margin: 0; font: 700 14px 'Poppins', sans-serif; }
.activity-filter { width: min(250px, 45%); }
.activity-list { display: grid; gap: 7px; }
.activity-admin-card { border: 1px solid var(--line); border-radius: 10px; background: #fff; overflow: hidden; }
.activity-admin-summary { display: grid; grid-template-columns: minmax(0,1fr) auto auto; align-items: center; gap: 10px; padding: 12px 13px; cursor: pointer; list-style: none; }
.activity-admin-summary::-webkit-details-marker { display: none; }
.activity-admin-summary:hover { background: #fbfcfb; }
.activity-readonly-summary { grid-template-columns: minmax(0,1fr) auto auto auto; cursor: default; }
.activity-readonly-summary:hover { background: #fff; }
.readonly-function-list { display: flex; flex-wrap: wrap; gap: 8px; }
.readonly-function-item { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 8px; padding: 7px 10px; color: var(--ink); background: #fff; font-size: 10px; }
.management-users-readonly { margin: 14px 0; padding: 16px; }
.absence-status { display: inline-flex; align-items: center; border-radius: 20px; padding: 5px 9px; background: var(--red-soft); color: var(--red); font-size: 10px; font-weight: 600; white-space: nowrap; }
.absence-transfer-heading { margin: 20px 0 10px; }
.absence-transfer-heading h3 { margin: 0 0 4px; color: var(--ink); font-size: 13px; }
.absence-transfer-heading p { margin: 0; color: var(--muted); font-size: 11px; }
.absence-transfer-list { display: grid; gap: 8px; }
.absence-transfer-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(220px, 310px); align-items: center; gap: 14px; border: 1px solid var(--line); border-radius: 9px; padding: 10px 12px; background: #fff; }
.absence-transfer-row span { display: grid; gap: 3px; }
.absence-transfer-row strong { color: var(--ink); font-size: 11px; }
.absence-transfer-row small { color: var(--muted); font-size: 9px; text-transform: capitalize; }
.absence-dialog { width: min(880px, calc(100% - 32px)); }
@media (max-width: 700px) { .absence-transfer-row { grid-template-columns: 1fr; gap: 8px; } }
.readonly-user-name { display: inline-flex; align-items: center; gap: 8px; color: var(--ink); white-space: nowrap; }
.readonly-user-name i { display: inline-grid; place-items: center; width: 25px; height: 25px; border-radius: 50%; background: var(--red-soft); color: var(--red); font-size: 8px; font-style: normal; font-weight: 700; }
.readonly-user-action { display: inline-flex; align-items: center; gap: 9px; max-width: 100%; min-height: 34px; padding: 3px 8px 3px 3px; border: 1px solid transparent; border-radius: 8px; background: transparent; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.readonly-user-action:hover, .readonly-user-action:focus-visible { border-color: var(--line); background: #fff; outline: none; }
.readonly-user-action .readonly-user-name { font-size: 10px; }
.activity-admin-title { min-width: 0; }
.activity-admin-title strong { display: block; font-size: 10px; line-height: 1.45; }
.activity-admin-title small { display: block; margin-top: 4px; color: #87948d; font-size: 8px; }
.status-pill { display: inline-flex; align-items: center; gap: 5px; border-radius: 5px; padding: 5px 7px; background: #f1f3f2; color: #718079; font-size: 8px; font-weight: 700; white-space: nowrap; }
.status-pill.active { background: var(--green-soft); color: var(--green-dark); }
.status-pill.draft { background: var(--amber-soft); color: var(--amber); }
.activity-admin-form { border-top: 1px solid #edf1ef; padding: 13px; background: #fbfcfb; }
.management-history-form { display: grid; grid-template-columns: 1fr 1fr auto; align-items: end; gap: 8px; }
.management-history-results { margin-top: 10px; }
.management-history-results .history-item { background: #fff; }
.helper-text { margin: 7px 0 0; color: #87948d; font-size: 8px; line-height: 1.45; }

.loading-state { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 210px; color: #7f8e87; font-size: 11px; }
.spinner { width: 16px; height: 16px; border: 2px solid #dce8e1; border-top-color: var(--green); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.toast { position: fixed; right: 24px; bottom: 22px; z-index: 20; max-width: min(370px, calc(100vw - 40px)); transform: translateY(12px); opacity: 0; pointer-events: none; border: 1px solid #cce1d7; border-radius: 9px; padding: 11px 14px; background: #eff8f3; color: #285d4c; box-shadow: var(--shadow); font-size: 10px; transition: .2s ease; }
.toast.is-visible { transform: translateY(0); opacity: 1; }
.toast.is-error { border-color: #efd0c9; background: #fff3f0; color: #934b42; }
.mobile-nav { display: none; }

@media (max-width: 1040px) {
  .sidebar { width: 220px; }
  .app-main { margin-left: 220px; }
  .content { padding-inline: 28px; }
  .topbar { padding-inline: 28px; }
  .calendar-layout { grid-template-columns: minmax(0,1fr) minmax(230px,.8fr); }
}

@media (max-width: 780px) {
  .sidebar { width: 65px; align-items: center; padding: 20px 8px; }
  .brand { margin: 0 0 42px; }
  .brand > span:last-child, .nav-label, .nav-item > span:last-child, .sidebar-bottom { display: none; }
  .nav-item { width: 44px; height: 44px; justify-content: center; padding: 0; }
  .nav-icon { font-size: 17px; }
  .app-main { margin-left: 65px; }
  .calendar-layout { grid-template-columns: 1fr; }
  .history-panel { min-height: 0; }
}

@media (max-width: 560px) {
  .sidebar { display: none; }
  .app-main { margin-left: 0; padding-bottom: 68px; }
  .topbar { height: 58px; padding: 0 16px; }
  .mobile-brand { display: flex; }
  .topbar-context { display: none; }
  .profile-switcher { gap: 2px; text-align: right; }
  .profile-switcher span { font-size: 8px; }
  .profile-switcher select { max-width: 152px; font-size: 9px; }
  .content { padding: 25px 15px 40px; }
  .page-heading { align-items: flex-start; margin-bottom: 18px; }
  h1 { font-size: 25px; }
  .page-subtitle { max-width: 280px; font-size: 10px; }
  .date-chip { display: none; }
  .hero-card { min-height: 134px; margin-bottom: 21px; padding: 18px; }
  .hero-title { font-size: 17px; }
  .hero-caption { max-width: 205px; font-size: 9px; }
  .progress-wrap { min-width: 0; gap: 8px; }
  .progress-ring { width: 47px; height: 47px; border-width: 4px; font-size: 10px; }
  .progress-copy strong { font-size: 14px; }
  .progress-copy small { font-size: 8px; }
  .section-heading { margin-top: 24px; }
  .task-card { padding: 13px 12px; }
  .task-top { flex-direction: column; gap: 11px; }
  .task-title { font-size: 11px; }
  .task-state { align-self: flex-start; }
  .choice-button { min-width: 72px; }
  .repeat-grid { grid-template-columns: 1fr; }
  .repeat-card { min-height: 102px; }
  .management-summary { gap: 6px; }
  .metric-card { padding: 10px; }
  .metric-card span { font-size: 8px; }
  .metric-card strong { font-size: 17px; }
  .management-grid { grid-template-columns: 1fr; }
  .profile-row { grid-template-columns: minmax(0,1fr) minmax(95px,.9fr); }
  .profile-row .checkbox-field { grid-column: 1/-1; }
  .activity-admin-summary { grid-template-columns: minmax(0,1fr) auto; }
  .activity-admin-summary .tag { display: none; }
  .form-grid { grid-template-columns: 1fr; }
  .form-field.full { grid-column: auto; }
  .management-history-form { grid-template-columns: 1fr 1fr; }
  .management-history-form button { grid-column: 1/-1; }
  .calendar-panel { padding: 14px 9px; }
  .calendar-day { min-height: 43px; font-size: 9px; }
  .calendar-grid { gap: 2px; }
  .calendar-legend { gap: 8px; }
  .legend-item { font-size: 7px; }
  .mobile-nav { position: fixed; inset: auto 0 0; z-index: 8; display: flex; height: 62px; justify-content: space-around; border-top: 1px solid var(--line); background: rgba(255,255,255,.96); padding: 5px 8px max(5px, env(safe-area-inset-bottom)); backdrop-filter: blur(12px); }
  .mobile-nav-item { display: grid; min-width: 68px; place-items: center; gap: 1px; border: 0; border-radius: 8px; background: transparent; color: #8a9690; }
  .mobile-nav-item span { font-size: 16px; line-height: 1; }
  .mobile-nav-item small { font-size: 8px; font-weight: 600; }
  .mobile-nav-item.is-active { color: var(--green); }
}

/* Refined SGE brand lockup */
.brand {
  min-height: 74px;
  margin-bottom: 30px;
  padding-inline: 19px;
  gap: 13px;
  background: linear-gradient(115deg, #f40a11 0%, #dc0710 100%);
}
.brand-mark {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  border: 1px solid rgba(255,255,255,.45);
  border-radius: 12px;
  background: #ffd600;
  color: #f40a11;
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -1.2px;
  box-shadow: 0 3px 9px rgba(83,0,0,.14);
}
.brand-copy strong {
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: -.2px;
}
.brand-copy small {
  margin-top: 3px;
  color: rgba(255,255,255,.76);
  font-size: 10px;
  letter-spacing: .15px;
}
@media (max-width: 780px) {
  .brand { min-height: 62px; padding-inline: 0; }
  .brand-mark { width: 38px; height: 38px; flex-basis: 38px; }
}

/* SGE login and user administration */
.is-auth .sidebar, .is-auth .topbar, .is-auth .mobile-nav { display: none !important; }
.is-auth .app-main { margin: 0; min-height: 100vh; }
.is-auth .content { max-width: none; padding: 0; }
.auth-layout { min-height: 100vh; display: grid; place-items: center; align-content: center; gap: 24px; padding: 32px 18px; background: radial-gradient(ellipse at 50% 0%, #fff1f1, transparent 53%), #f4f6f8; }
.auth-brand { display: flex; align-items: center; gap: 12px; color: #374151; font-size: 12px; font-weight: 600; letter-spacing: .12em; }
.auth-brand .brand-mark { width: 67px; height: 42px; display: flex; align-items: center; justify-content: center; gap: 3px; border-radius: 8px; color: white; background: var(--red); font: italic 800 15px/1 'Poppins', sans-serif; letter-spacing: -.7px; }
.auth-brand .brand-accent { width: 13px; height: 10px; flex-basis: 13px; }
.auth-card { width: min(100%, 438px); display: grid; gap: 15px; padding: 35px; border: 1px solid #e4e8ee; border-radius: 12px; background: white; box-shadow: 0 16px 45px rgba(27, 39, 57, .09); }
.auth-kicker { color: var(--red); font-size: 10px; font-weight: 600; letter-spacing: .14em; }
.auth-card h1 { margin: 0; color: #202a39; font-size: 24px; font-weight: 600; }
.auth-card > p { margin: -7px 0 4px; color: #788394; font-size: 13px; line-height: 1.65; }
.auth-field, .users-filters label, .user-field { display: grid; gap: 7px; color: #607087; font-size: 10px; font-weight: 500; letter-spacing: .08em; }
.auth-field input, .user-field input, .user-field select, .users-filters input, .users-filters select { width: 100%; min-height: 42px; border: 1px solid #d9e0e9; border-radius: 22px; padding: 0 14px; outline: none; background: white; color: #253044; font: 400 13px Poppins, sans-serif; letter-spacing: 0; }
.auth-field input:focus, .user-field input:focus, .users-filters input:focus, .users-filters select:focus { border-color: #6ba7ef; box-shadow: 0 0 0 3px rgba(42, 137, 241, .09); }
.auth-field input[readonly], .user-field input[readonly] { background: #f7f8fa; }
.auth-submit { width: 100%; min-height: 44px; margin-top: 2px; border-radius: 8px; background: var(--red); color: white; font-weight: 600; }
.auth-submit:hover { background: #d9080e; }
.auth-submit:disabled { opacity: .6; cursor: wait; }
.auth-error { min-height: 0; color: #be1118; font-size: 12px; }
.auth-error:not(:empty) { padding: 10px 12px; border-radius: 7px; background: #fff1f1; }
.auth-footnote { color: #919aa8; font-size: 11px; }
.topbar-user { display: grid; justify-items: end; line-height: 1.25; }
.topbar-user-name { color: #273244; font-size: 12px; font-weight: 600; }
.topbar-user-role { color: #8390a0; font-size: 10px; }
.sidebar-logout { margin: 8px 0 0; border: 0; padding: 5px 0; background: none; color: #778394; font: 400 11px Poppins, sans-serif; cursor: pointer; }
.sidebar-logout:hover { color: var(--red); }
.sector-nav-list { display: grid; gap: 4px; margin-bottom: 12px; }
.sector-choice { min-height: 39px; }
.sector-choice.is-active { color: #263449; background: #eef1f5; box-shadow: inset 3px 0 var(--red); }
.sector-card { display: flex; align-items: center; gap: 16px; margin-bottom: 12px; padding: 19px 21px; border: 1px solid #dce3eb; border-radius: 12px; background: white; box-shadow: 0 3px 12px rgba(31, 47, 67, .035); }
.sector-card-mark { display: grid; width: 42px; height: 42px; flex: 0 0 42px; place-items: center; border-radius: 11px; background: #fff0f0; color: var(--red); font-size: 18px; }
.sector-card-main { flex: 1; }
.sector-card-main .eyebrow { color: #8190a1; font-size: 9px; letter-spacing: .12em; }
.sector-card-main h2 { margin: 3px 0; color: #223046; font-size: 16px; font-weight: 600; }
.sector-card-main p { margin: 0; color: #788698; font-size: 11px; }
.sector-card-count { display: grid; min-width: 100px; text-align: center; }
.sector-card-count strong { color: #27364b; font-size: 19px; font-weight: 600; }
.sector-card-count span { color: #8290a1; font-size: 9px; }
.sector-card.is-inactive { background: #f8f9fb; opacity: .78; }
.sector-toggle-button { min-height: 35px; padding: 0 13px; border: 1px solid #d7dfe8; border-radius: 19px; background: white; color: #69798d; font: 500 10px Poppins, sans-serif; cursor: pointer; }
.sector-toggle-button:hover { border-color: var(--red); color: var(--red); }
.sector-list { display: grid; gap: 4px; }
.users-summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 4px 0 16px; }
.user-summary-card { display: flex; align-items: center; justify-content: space-between; min-height: 48px; padding: 8px 16px; border: 1px solid #d8e0ea; border-radius: 24px; background: #fff; color: #52647b; cursor: pointer; }
.user-summary-card span { font-size: 10px; letter-spacing: .12em; }
.user-summary-card strong { color: #1c2a3b; font-size: 16px; font-weight: 600; }
.user-summary-card.is-active { border: 2px solid #398df1; box-shadow: 0 2px 6px rgba(35, 113, 209, .12); }
.users-panel { overflow: hidden; border: 1px solid #d8e0ea; border-radius: 12px; background: #fff; box-shadow: 0 4px 18px rgba(29, 47, 68, .035); }
.users-filters { display: grid; grid-template-columns: minmax(210px, 1.5fr) minmax(130px, 1fr) minmax(140px, 1fr) minmax(120px, .8fr) 38px; align-items: end; gap: 13px; padding: 15px; border-bottom: 1px solid #e5e9ef; }
.users-filters label { position: relative; gap: 6px; }
.users-filters label > span { padding-left: 2px; }
.users-filters input, .users-filters select { min-height: 39px; border-radius: 21px; }
.users-filters label:first-child input { padding-left: 38px; }
.users-filters label:first-child i { position: absolute; bottom: 7px; left: 13px; color: #7e8b9b; font-size: 20px; font-style: normal; }
.filter-icon-button { width: 38px; height: 38px; border: 1px solid #d9e0e9; border-radius: 50%; background: white; color: #7f8da0; font-size: 20px; cursor: pointer; }
.users-table-wrap { overflow-x: auto; }
.users-table { width: 100%; border-collapse: collapse; white-space: nowrap; }
.users-table th { height: 39px; padding: 0 12px; background: #f5f7fa; color: #52647b; font-size: 9px; font-weight: 500; letter-spacing: .06em; text-align: left; }
.users-table th:first-child, .users-table td:first-child { padding-left: 18px; }
.users-table td { height: 47px; padding: 0 12px; border-top: 1px solid #e1e6ed; color: #66768c; font-size: 11px; }
.users-table td:first-child { color: #1f2a39; }
.users-table td:first-child strong { font-weight: 500; }
.user-avatar { display: inline-grid; width: 27px; height: 27px; margin-right: 9px; place-items: center; border-radius: 50%; background: #ffe5e6; color: #f40a11; font-size: 9px; font-weight: 600; vertical-align: middle; }
.role-pill, .status-pill { display: inline-flex; align-items: center; min-height: 19px; padding: 2px 10px; border-radius: 12px; font-size: 9px; }
.role-staff { background: #e8f8fb; color: #00849a; }
.role-management { background: #fff2c5; color: #846400; }
.status-pill.is-on { background: #dff4eb; color: #008b51; }
.status-pill.is-off { background: #edf0f4; color: #6e7b8d; }
.password-state { display: inline-grid; width: 23px; height: 23px; place-items: center; border-radius: 50%; background: #e3f5eb; color: #009450; font-size: 15px; }
.password-state.is-pending { background: #fff3dd; color: #be7d00; }
.user-actions { text-align: right; }
.user-actions button { width: 28px; height: 29px; margin-left: 3px; border: 0; border-radius: 5px; background: transparent; color: #6d7a8b; font-size: 17px; cursor: pointer; }
.user-actions button:hover { background: #f1f4f8; color: var(--red); }
.users-empty { height: 100px !important; color: #8290a1 !important; text-align: center; }
.users-table-footer { padding: 10px 16px; border-top: 1px solid #e8ebef; color: #7e8a9b; font-size: 10px; text-align: right; }
.page-create-user { min-height: 40px; padding: 0 16px; border: 0; border-radius: 22px; background: #079a56; color: white; font: 500 12px Poppins, sans-serif; cursor: pointer; }
.page-create-user:hover, .create-user-button:hover { background: #087d49; }
.user-dialog { width: min(1040px, calc(100% - 32px)); max-height: 92vh; padding: 0; border: 1px solid #e1e5eb; border-radius: 14px; background: white; box-shadow: 0 24px 70px rgba(18, 28, 42, .28); }
.user-dialog::backdrop { background: rgba(26, 32, 42, .48); backdrop-filter: blur(2px); }
.user-dialog-shell { display: grid; grid-template-rows: auto 1fr auto; max-height: 92vh; }
.user-dialog-header { display: flex; align-items: center; justify-content: space-between; padding: 19px 26px; border-bottom: 1px solid #e5e8ed; }
.user-dialog-header h2 { margin: 0; color: #202a39; font-size: 17px; font-weight: 600; }
.user-dialog-header p { margin: 4px 0 0; color: #7d8897; font-size: 11px; }
.user-dialog-body { overflow: auto; padding: 20px 26px; background: #fbfcfd; }
.user-form-section { padding: 18px; border: 1px solid #dce2e9; border-radius: 12px; background: white; }
.user-form-section h3 { margin: 0 0 18px; color: #667386; font-size: 11px; font-weight: 500; letter-spacing: .04em; }
.user-form-grid { display: grid; grid-template-columns: 1.3fr .75fr 1fr; gap: 14px; align-items: start; }
.user-form-grid > .user-field { align-self: start; grid-template-rows: 14px 42px auto; }
.user-form-grid > .user-field > span { line-height: 14px; }
.user-name-field { grid-column: span 2; }
.user-email-field { grid-column: 1 / -1; }
.user-field input { min-height: 41px; border-radius: 22px; }
.user-dialog-hint { margin: 15px 0 0; color: #7d8897; font-size: 10px; line-height: 1.5; }
.user-dialog-footer { display: flex; justify-content: flex-end; gap: 9px; padding: 14px 24px; border-top: 1px solid #e0e5eb; background: white; }
.create-user-button { min-height: 39px; padding: 0 18px; border: 0; border-radius: 22px; background: #079a56; color: white; font: 500 12px Poppins, sans-serif; cursor: pointer; }
.users-panel [hidden] { display: none; }
@media (max-width: 850px) { .users-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); } .user-form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .users-summary { gap: 6px; } .user-summary-card { padding: 7px 10px; } .user-summary-card span { font-size: 8px; } .users-filters { grid-template-columns: 1fr 1fr; padding: 11px; } .users-filters label:first-child { grid-column: span 2; } .user-dialog-header, .user-dialog-body { padding-inline: 15px; } .user-form-grid { grid-template-columns: 1fr; } .user-name-field, .user-email-field { grid-column: auto; } .page-heading { gap: 12px; align-items: flex-start; } }
@media (max-width: 560px) { .sector-card { flex-wrap: wrap; padding: 15px; } .sector-card-count { display: none; } }

/* Identidade visual SAC */
:root {
  --ink: #252323;
  --muted: #777170;
  --line: #eee9e8;
  --paper: #ffffff;
  --canvas: #faf8f7;
  --green: #f40a11;
  --green-dark: #c9080e;
  --green-soft: #fff0f0;
  --lime: #ffd600;
  --amber: #8b7100;
  --amber-soft: #fff8d6;
  --red: #f40a11;
  --red-soft: #fff0f0;
  --shadow: 0 14px 36px rgba(60, 14, 14, .08);
  font-family: 'Poppins', sans-serif;
}

body { background: var(--canvas); }
.sidebar { background: #f40a11; color: #fff; }
.brand-mark { background: #ffd600; color: #f40a11; font-family: 'Poppins', sans-serif; }
.brand-mark span { color: #fff; }
.brand small, .nav-label, .eyebrow { color: rgba(255,255,255,.72); }
.nav-item { color: rgba(255,255,255,.82); }
.nav-item:hover { background: rgba(255,255,255,.14); color: #fff; }
.nav-item.is-active { background: #fff; color: #f40a11; box-shadow: inset 4px 0 #ffd600; }
.nav-item.is-active .nav-icon { color: #f40a11; }
.nav-icon { color: rgba(255,255,255,.78); }
.online-dot { background: #ffd600; box-shadow: 0 0 0 3px rgba(255,214,0,.2); }
.topbar { background: rgba(255,255,255,.96); }
.heading-copy .eyebrow { color: #f40a11; }
h1 { letter-spacing: -.8px; }
.hero-card { border-radius: 20px; background: #f40a11; color: #fff; box-shadow: 0 16px 35px rgba(244,10,17,.16); }
.hero-card:after { border-color: rgba(255,255,255,.2); box-shadow: 0 0 0 24px rgba(255,255,255,.08), 0 0 0 50px rgba(255,255,255,.045); }
.hero-label, .hero-caption, .progress-copy small { color: rgba(255,255,255,.78); }
.hero-title { color: #fff; }
.progress-ring { background: conic-gradient(#ffd600 var(--progress), rgba(255,255,255,.26) var(--progress)); color: #fff; }
.progress-ring:before { background: #f40a11; }
.progress-copy strong { color: #fff; }
.task-card, .calendar-panel, .management-panel, .history-panel, .panel, .metric-card { border-color: #eee8e7; box-shadow: 0 5px 20px rgba(49,24,24,.035); }
.task-card { border-radius: 15px; padding: 18px 19px; }
.task-card:hover { border-color: rgba(244,10,17,.28); box-shadow: var(--shadow); }
.count-pill { background: #fff4bd; color: #665500; }
.tag.status-done, .history-result.yes, .status-pill.active { background: #fff4bd; color: #665500; }
.choice-button { border-radius: 9px; }
.choice-button:hover { border-color: #f40a11; color: #c9080e; }
.choice-button.is-selected.yes { border-color: #ffd600; background: #ffd600; color: #302900; }
.choice-button.is-selected.no { border-color: #f40a11; background: #fff0f0; color: #c9080e; }
.primary-button { border-color: #f40a11; background: #f40a11; color: #fff; }
.primary-button:hover { border-color: #c9080e; background: #c9080e; }
.quiet-button { color: #c9080e; }
.quiet-button:hover { background: #fff0f0; }
.save-state { color: #c9080e; }
.calendar-day.is-selected { border-color: #f40a11 !important; background: #fff0f0 !important; color: #c9080e; }
.calendar-day.is-today:not(.is-selected) { color: #c9080e; }
.status-complete .day-dot, .legend-dot.complete { background: #ffd600; }
.status-incomplete .day-dot, .legend-dot.incomplete { background: #f40a11; }
.icon-button:hover { border-color: #f40a11; color: #f40a11; }
.checkbox-field input { accent-color: #f40a11; }
.spinner { border-top-color: #f40a11; }
.toast { border-color: #ffd600; background: #fff9d9; color: #4d4100; }
.toast.is-error { border-color: #f6c4c5; background: #fff0f0; color: #a8070c; }
.mobile-nav-item.is-active { color: #f40a11; }
.profile-row { grid-template-columns: minmax(0,1fr) minmax(120px,.8fr) auto auto auto; }
.delete-profile-button { min-height: 30px; border: 1px solid #f5c6c7; border-radius: 7px; padding: 6px 9px; background: #fff; color: #c9080e; font: 600 9px 'Poppins', sans-serif; transition: .15s ease; }
.delete-profile-button:hover { border-color: #f40a11; background: #fff0f0; }
@media (max-width: 560px) {
  .hero-card { border-radius: 16px; }
  .task-card { padding: 15px 14px; }
  .profile-row { grid-template-columns: minmax(0,1fr) minmax(95px,.9fr); }
  .profile-row .checkbox-field { grid-column: 1/-1; }
  .profile-row > button { justify-self: start; }
}

.task-controls { display: flex; flex: 0 0 auto; align-items: center; gap: 8px; }
.guide-button { display: inline-flex; min-height: 34px; align-items: center; justify-content: center; gap: 6px; border: 1px solid #f2d64e; border-radius: 8px; padding: 7px 10px; background: #fff8d0; color: #5a4a00; font: 600 10px 'Poppins', sans-serif; white-space: nowrap; transition: .15s ease; }
.guide-button:hover { border-color: #ffd600; background: #ffd600; color: #382e00; }
.repeat-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }
.pop-dialog { width: min(1000px, calc(100vw - 32px)); height: min(860px, calc(100dvh - 32px)); max-width: none; max-height: none; margin: auto; overflow: hidden; border: 1px solid #eee3e2; border-radius: 16px; padding: 0; background: #fff; color: var(--ink); box-shadow: 0 24px 90px rgba(25,10,10,.24); }
.pop-dialog::backdrop { background: rgba(24,18,18,.58); backdrop-filter: blur(3px); }
.pop-dialog-shell { display: flex; width: 100%; height: 100%; flex-direction: column; }
.pop-dialog-header { display: flex; flex: 0 0 auto; align-items: center; justify-content: space-between; gap: 16px; border-bottom: 1px solid var(--line); padding: 15px 20px; }
.pop-dialog-header .eyebrow { margin-bottom: 3px; color: #f40a11; font-size: 8px; }
.pop-dialog-header h2 { margin: 0; font: 600 16px 'Poppins', sans-serif; }
.pop-close { flex: 0 0 auto; width: 34px; height: 34px; font-size: 22px; }
#popDialogFrame { width: 100%; min-height: 0; flex: 1 1 auto; border: 0; background: #f6f5f4; }
.pop-dialog-footer { display: flex; flex: 0 0 auto; align-items: center; justify-content: space-between; gap: 12px; border-top: 1px solid var(--line); padding: 10px 20px; }
.pop-dialog-footer p { margin: 0; color: var(--muted); font-size: 9px; }
.pop-dialog-footer a { color: #c9080e; font-size: 10px; font-weight: 600; text-decoration: none; white-space: nowrap; }
.pop-dialog-footer a:hover { text-decoration: underline; }
.evidence-folder-button { display: inline-flex; align-items: center; gap: 7px; border: 1px solid #d8e0e8; border-radius: 8px; padding: 7px 10px; background: #fff; color: #37465b; font: 600 10px 'Poppins', sans-serif; cursor: pointer; }
.evidence-folder-button:hover { border-color: #f40a11; background: #fff7f7; }
.evidence-folder-icon { color: #f2b600; font-size: 15px; line-height: 1; }
.evidence-folder-button b { display: grid; min-width: 19px; height: 19px; place-items: center; border-radius: 10px; background: #eef2f6; color: #536175; font-size: 9px; }
.evidence-dialog { width: min(1000px, calc(100vw - 32px)); height: min(780px, calc(100dvh - 32px)); max-width: none; max-height: none; margin: auto; overflow: hidden; border: 1px solid #e2e7ed; border-radius: 16px; padding: 0; background: #fff; color: var(--ink); box-shadow: 0 24px 90px rgba(25,10,10,.24); }
.evidence-dialog::backdrop { background: rgba(24,18,18,.58); backdrop-filter: blur(3px); }
.evidence-dialog-shell { display: flex; width: 100%; height: 100%; flex-direction: column; }
.evidence-dialog-header { display: flex; flex: 0 0 auto; align-items: center; gap: 14px; border-bottom: 1px solid var(--line); padding: 15px 20px; }
.evidence-dialog-header > div { flex: 1; }
.evidence-dialog-header .eyebrow { margin: 0 0 3px; color: #f40a11; font-size: 8px; }
.evidence-dialog-header h2 { margin: 0; font: 600 16px 'Poppins', sans-serif; }
.evidence-dialog-count { border-radius: 20px; padding: 6px 10px; background: #f1f3f6; color: #596579; font-size: 10px; font-weight: 600; white-space: nowrap; }
.evidence-dialog-main { display: flex; min-height: 0; flex: 1; align-items: center; gap: 12px; padding: 14px; background: #f4f6f9; }
.evidence-preview { display: grid; min-width: 0; min-height: 0; flex: 1; width: 100%; height: 100%; place-items: center; overflow: auto; border: 1px solid #e3e8ee; border-radius: 10px; background: #fff; }
.evidence-nav { display: grid; width: 42px; height: 42px; flex: 0 0 42px; place-items: center; border: 1px solid #d7dee7; border-radius: 50%; background: #fff; color: #263449; font-size: 28px; line-height: 1; cursor: pointer; }
.evidence-nav:hover:not(:disabled) { border-color: #f40a11; color: #f40a11; }
.evidence-nav:disabled { opacity: .35; cursor: default; }
.evidence-media-image { display: block; max-width: 100%; max-height: 100%; object-fit: contain; }
.evidence-media { width: 100%; max-height: 100%; background: #111; }
.evidence-media-audio { width: min(620px, 90%); }
.evidence-media-frame { width: 100%; height: 100%; border: 0; }
.evidence-link-preview, .evidence-file-preview { display: grid; max-width: min(650px, 90%); justify-items: center; gap: 10px; padding: 24px; text-align: center; }
.evidence-link-preview strong, .evidence-file-preview strong { overflow-wrap: anywhere; font-size: 15px; }
.evidence-link-preview a { max-width: 100%; overflow-wrap: anywhere; color: #c9080e; font-size: 12px; }
.evidence-link-preview p, .evidence-file-preview p { margin: 0; color: var(--muted); font-size: 11px; }
.evidence-preview-icon { display: grid; width: 58px; height: 58px; place-items: center; border-radius: 17px; background: #fff1d0; color: #c58d00; font-size: 29px; }
.evidence-dialog-footer { display: flex; flex: 0 0 auto; justify-content: flex-end; border-top: 1px solid var(--line); padding: 11px 20px; }
.evidence-dialog-footer a { color: #c9080e; font-size: 10px; font-weight: 600; text-decoration: none; }
.evidence-dialog-footer a:hover { text-decoration: underline; }
@media (max-width: 560px) {
  .task-controls { flex-wrap: wrap; }
  .task-top .task-controls { align-self: flex-start; }
  .repeat-actions { justify-content: flex-start; }
  .pop-dialog { width: calc(100vw - 16px); height: calc(100dvh - 16px); border-radius: 12px; }
  .pop-dialog-header, .pop-dialog-footer { padding-inline: 12px; }
  .pop-dialog-footer { align-items: flex-start; flex-direction: column; gap: 5px; }
  .evidence-dialog { width: calc(100vw - 16px); height: calc(100dvh - 16px); border-radius: 12px; }
  .evidence-dialog-header { padding-inline: 12px; }
  .evidence-dialog-main { gap: 6px; padding: 7px; }
  .evidence-nav { width: 32px; height: 32px; flex-basis: 32px; font-size: 23px; }
  .evidence-dialog-footer { padding-inline: 12px; }
}
.pop-file-input { padding: 6px; }
.pop-file-input::file-selector-button { margin-right: 9px; border: 1px solid #f1d64c; border-radius: 6px; padding: 5px 9px; background: #fff7cb; color: #4d4000; font: 600 9px 'Poppins', sans-serif; cursor: pointer; }
.pop-file-input::file-selector-button:hover { background: #ffd600; }

/* Painel compacto inspirado no padrão administrativo da referência. */
:root {
  --ink: #222833;
  --muted: #748092;
  --line: #dfe4eb;
  --paper: #fff;
  --canvas: #f3f5f8;
  --green: #f40a11;
  --green-dark: #c9080e;
  --green-soft: #fff0f0;
  --lime: #ffd600;
  --amber: #866b00;
  --amber-soft: #fff8d6;
  --red: #f40a11;
  --red-soft: #fff0f0;
  --blue: #50647e;
  --blue-soft: #eef2f7;
  --shadow: 0 4px 14px rgba(30, 42, 58, .055);
}

body { background: var(--canvas); }
.sidebar { width: 246px; padding: 0 14px 18px; background: #fff; color: #526075; border-right: 1px solid #e1e5ec; }
.brand { min-height: 68px; margin: 0 -14px 25px; padding: 14px 22px; background: #f40a11; color: #fff; gap: 11px; }
.brand-mark { width: 38px; height: 38px; border-radius: 10px; background: #ffd600; color: #f40a11; }
.brand-mark span { color: #fff; }
.brand small { color: rgba(255,255,255,.78); }
.nav-label { margin: 0 12px 10px; color: #909bab; }
.nav-item { min-height: 42px; border-radius: 7px; color: #657185; font-size: 12px; font-weight: 500; }
.nav-item:hover { background: #f5f6f8; color: #273144; }
.nav-item.is-active { background: #f0f2f5; color: #242d3b; box-shadow: inset 3px 0 #f40a11; font-weight: 600; }
.nav-item.is-active .nav-icon { color: #f40a11; }
.nav-icon { color: #7e8999; }
.sidebar-bottom { border-top-color: #e6e9ef; }
.sidebar-note { color: #657185; }
.sidebar-bottom p { color: #919bac; }
.online-dot { background: #ffd600; box-shadow: 0 0 0 3px rgba(255,214,0,.16); }
.app-main { margin-left: 246px; }
.topbar { height: 66px; padding-inline: clamp(22px, 3vw, 46px); background: rgba(255,255,255,.97); border-color: #e3e6ec; }
.topbar-context { color: #4c5667; }
.topbar-context .eyebrow { color: #8b95a5; }
.profile-switcher { display: flex; align-items: center; gap: 8px; border: 1px solid #e1e5eb; border-radius: 22px; padding: 8px 12px; background: #fff; }
.profile-switcher select { max-width: 200px; }
.content { width: min(1500px, 100%); padding: 30px clamp(22px, 3vw, 46px) 58px; }
.heading-copy .eyebrow { color: #f40a11; }
.page-heading { margin-bottom: 20px; }
h1 { color: #202735; }
.page-subtitle { color: #788496; }
.hero-card { min-height: 118px; margin-bottom: 23px; border: 1px solid #e1e5eb; border-radius: 10px; padding: 19px 22px; background: #fff; color: var(--ink); box-shadow: 0 2px 8px rgba(30,42,58,.025); }
.hero-card:after { display: none; }
.hero-label { color: #f40a11; }
.hero-title { margin: 6px 0 4px; color: #242b38; font-size: 18px; }
.hero-caption, .progress-copy small { color: #798597; }
.progress-wrap { gap: 12px; }
.progress-ring { width: 53px; height: 53px; background: conic-gradient(#f40a11 var(--progress), #e7eaf0 var(--progress)); color: #303846; }
.progress-ring:before { inset: 5px; background: #fff; }
.progress-copy strong { color: #242b38; font-size: 16px; }
.section-heading { margin: 24px 0 10px; }
.section-heading h2 { color: #2b3442; font-size: 14px; }
.section-heading p { color: #7d8899; }
.count-pill { min-width: 26px; border-radius: 14px; background: #fff1bd; color: #6e5900; }
.task-list, .repeat-grid { gap: 7px; }
.task-card { border-color: #dfe4eb; border-radius: 8px; padding: 12px 15px; box-shadow: 0 1px 3px rgba(30,42,58,.025); }
.task-card:hover { border-color: #c5ccd7; box-shadow: var(--shadow); }
.task-card.is-complete { border-color: #e6d577; background: #fffef9; }
.task-context { color: #7d8899; }
.task-title { color: #293241; font-size: 11px; }
.task-meta { margin-top: 6px; }
.tag { border-radius: 11px; padding: 4px 8px; }
.tag.status-done, .history-result.yes, .status-pill.active { background: #fff1bd; color: #675400; }
.tag.status-pending { background: #f0f2f5; color: #707c8d; }
.task-state { gap: 6px; }
.choice-button { min-width: 68px; border-color: #dce1e8; border-radius: 7px; padding: 7px 11px; color: #566174; }
.choice-button:hover { border-color: #f40a11; color: #c9080e; }
.choice-button.is-selected.yes { border-color: #ffd600; background: #ffd600; color: #383000; }
.choice-button.is-selected.no { border-color: #f40a11; background: #fff0f0; color: #c9080e; }
.guide-button { min-height: 32px; border-color: #f0d55a; border-radius: 7px; background: #fff9dc; font-size: 9px; }
.repeat-card { min-height: 110px; border-color: #dfe4eb; border-radius: 8px; padding: 13px 14px; box-shadow: 0 1px 3px rgba(30,42,58,.025); }
.primary-button { border-radius: 6px; }
.secondary-button, .quiet-button { border-radius: 6px; }
.management-summary { gap: 9px; }
.metric-card, .panel, .calendar-panel, .history-panel { border-color: #dfe4eb; border-radius: 9px; box-shadow: 0 2px 8px rgba(30,42,58,.025); }
.metric-card { padding: 13px 15px; }
.metric-card span { color: #7b8798; text-transform: uppercase; letter-spacing: .7px; }
.metric-card strong { color: #252d3a; }
.panel { padding: 16px; }
.panel-heading h2, .activity-toolbar h2 { color: #2a3341; }
.activity-admin-card { border-color: #dfe4eb; border-radius: 8px; }
.activity-admin-summary { padding: 11px 13px; }
.activity-admin-summary:hover { background: #f8f9fb; }
.activity-admin-form { background: #f8f9fb; }
.function-catalog-panel { margin-bottom: 16px; }
.function-create-form { display: grid; grid-template-columns: minmax(180px, 1fr) minmax(240px, 2fr) auto; align-items: end; gap: 12px; padding: 14px; border: 1px solid #e5e9ef; border-radius: 8px; background: #fafbfc; }
.function-catalog-list { display: grid; gap: 7px; margin-top: 12px; }
.function-catalog-row { display: grid; grid-template-columns: minmax(160px, 1fr) auto auto auto; align-items: center; gap: 9px; padding: 8px; border: 1px solid #e8ebf0; border-radius: 7px; background: #fff; }
.function-catalog-row .form-control { min-height: 34px; }
.function-catalog-row .secondary-button, .function-catalog-row .quiet-button { min-height: 32px; padding: 6px 11px; font-size: 10px; }
.function-catalog-panel .helper-text, .user-field .helper-text { margin: 4px 0 0; color: #778395; font-size: 10px; }
.default-password-panel { margin-bottom: 14px; border-left: 3px solid #ffd600; }
.default-password-form { display: grid; grid-template-columns: minmax(180px, 1fr) minmax(180px, 1fr) auto; align-items: end; gap: 11px; }
.default-password-panel > .helper-text { margin: 10px 0 0; color: #778395; font-size: 10px; }
.reset-password-user { margin: 0 0 14px; color: #465264; font-size: 13px; font-weight: 600; }
.reset-password-copy { display: flex; gap: 9px; }
.reset-password-copy input { font-weight: 600; letter-spacing: .5px; }
.form-control, .task-reason textarea { border-color: #d9dfe7; border-radius: 6px; }
.form-control:focus, .task-reason textarea:focus { border-color: #f40a11; box-shadow: 0 0 0 3px rgba(244,10,17,.08); }
.checkbox-field input { accent-color: #f40a11; }
.calendar-panel, .history-panel { padding: 17px; }
.calendar-day { border-radius: 7px; }
.calendar-day:hover:not(:disabled) { border-color: #e1e5eb; background: #f6f7f9; }
.calendar-day.is-selected { border-color: #f40a11 !important; background: #fff0f0 !important; color: #c9080e; }
.calendar-day.is-today:not(.is-selected) { color: #c9080e; }
.status-complete .day-dot, .legend-dot.complete { background: #ffd600; }
.status-incomplete .day-dot, .legend-dot.incomplete { background: #f40a11; }
.icon-button:hover { border-color: #f40a11; color: #f40a11; }
.mobile-nav { border-color: #e1e5eb; }
.mobile-nav-item.is-active { color: #f40a11; }
.pop-dialog { border-radius: 10px; }
.toast { border-color: #f0d55a; background: #fff9dc; color: #514500; }
.toast.is-error { border-color: #f6c4c5; background: #fff0f0; color: #a8070c; }

@media (max-width: 1040px) {
  .sidebar { width: 220px; }
  .app-main { margin-left: 220px; }
  .content { padding-inline: 25px; }
  .topbar { padding-inline: 25px; }
}
@media (max-width: 780px) {
  .sidebar { width: 64px; padding: 0 8px 16px; }
  .brand { width: calc(100% + 16px); min-height: 62px; justify-content: center; margin: 0 -8px 24px; padding: 10px 0; }
  .app-main { margin-left: 64px; }
}
@media (max-width: 560px) {
  .sidebar { display: none; }
  .app-main { margin-left: 0; padding-bottom: 68px; }
  .topbar { height: 58px; padding: 0 14px; }
  .content { padding: 23px 14px 38px; }
  .hero-card { min-height: 108px; border-radius: 9px; padding: 15px; }
  .hero-caption { max-width: 210px; font-size: 9px; }
  .task-card { border-radius: 8px; padding: 13px 12px; }
  .task-top { flex-direction: column; gap: 10px; }
  .task-controls { flex-wrap: wrap; }
  .task-top .task-controls { align-self: flex-start; }
  .repeat-grid { grid-template-columns: 1fr; }
  .metric-card { padding: 10px; }
  .management-grid { grid-template-columns: 1fr; }
  .function-create-form { grid-template-columns: 1fr; }
  .function-catalog-row { grid-template-columns: 1fr auto; }
  .function-catalog-row .status-pill { justify-self: start; }
  .default-password-form { grid-template-columns: 1fr; }
  .calendar-panel { padding: 14px 9px; }
  .calendar-day { min-height: 43px; }
}

/* SGE wordmark inspired by the supplied reference. */
.brand { min-height: 66px; margin-bottom: 25px; padding: 12px 18px; gap: 12px; background: #f40a11; }
.brand-wordmark { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 7px; color: #fff; font: italic 800 17px/1 'Poppins', sans-serif; letter-spacing: -.8px; white-space: nowrap; }
.brand-accent { display: inline-block; width: 19px; height: 14px; flex: 0 0 19px; background: #ffd600; clip-path: polygon(0 0, 91% 0, 100% 100%, 18% 66%); }
.brand-divider { width: 1px; height: 31px; flex: 0 0 1px; background: rgba(255,255,255,.48); }
.brand-copy strong { color: #fff; font-size: 9px; font-weight: 600; line-height: 1.35; letter-spacing: -.1px; white-space: nowrap; }
.brand-copy small { margin-top: 0; color: #fff; font-size: 9px; line-height: 1.35; letter-spacing: -.1px; }
.mobile-brand .brand-wordmark { color: #f40a11; font-size: 15px; }
.mobile-brand .brand-accent { width: 16px; height: 12px; flex-basis: 16px; }
@media (max-width: 780px) {
  .brand { min-height: 62px; padding-inline: 0; }
  .brand-divider, .brand-copy { display: none; }
  .brand-wordmark { font-size: 16px; }
}

.team-daily-panel { margin: 0 0 16px; padding: 18px; }
.team-daily-heading { align-items: center; gap: 18px; }
.team-daily-heading .panel-heading p { margin-bottom: 0; }
.team-daily-date { display: flex; align-items: end; gap: 8px; }
.team-daily-date .field-label { margin-bottom: 7px; }
.team-daily-date .form-control { width: auto; min-width: 145px; }
.team-daily-summary { display: flex; flex-wrap: wrap; gap: 8px; margin: 15px 0; }
.team-daily-summary span { border: 1px solid #e4e8ee; border-radius: 999px; padding: 6px 11px; background: #fbfcfd; color: #697587; font-size: 10px; }
.team-daily-summary strong { margin-right: 3px; color: #293344; font-size: 11px; }
.status-text-done { color: #118455 !important; }
.status-text-missed { color: #d9232e !important; }
.status-text-pending { color: #9a7400 !important; }
.team-daily-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 330px), 1fr)); gap: 11px; }
.team-person-card { min-width: 0; overflow: hidden; border: 1px solid #e2e6ed; border-radius: 9px; background: #fff; }
.team-person-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 9px; padding: 13px 14px; border-bottom: 1px solid #edf0f4; background: #fafbfc; }
.team-person-heading h3 { margin: 0 0 3px; color: #293344; font: 600 12px/1.4 'Poppins', sans-serif; }
.team-person-heading > div:first-child > span { color: #8993a2; font-size: 9px; }
.team-person-counts { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 4px; }
.team-person-counts b { border-radius: 999px; padding: 4px 7px; background: #fff; font-size: 8px; font-weight: 600; white-space: nowrap; }
.team-task-list { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; }
.team-task-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 11px; padding: 10px 13px; border-bottom: 1px solid #f0f2f5; }
.team-task-row:last-child { border-bottom: 0; }
.team-task-copy { min-width: 0; }
.team-task-copy strong { display: block; color: #3b4658; font-size: 10px; font-weight: 500; line-height: 1.5; }
.team-task-copy small { display: block; margin-top: 2px; color: #8b95a4; font-size: 8px; }
.team-justification { margin: 6px 0 0; border-left: 2px solid #f40a11; padding: 5px 8px; background: #fff5f5; color: #6f4244; font-size: 9px; line-height: 1.5; }
.team-justification b { color: #c4141b; }
.team-demand-observation { margin: 6px 0 0; border-left: 2px solid #7e8ca3; padding: 5px 8px; background: #f5f7fa; color: #586477; font-size: 9px; line-height: 1.5; }
.team-task-status { flex: 0 0 auto; border-radius: 999px; padding: 4px 7px; font-size: 8px; font-weight: 600; white-space: nowrap; }
.team-task-status.is-done { background: #e7f6ef; color: #118455; }
.team-task-status.is-missed { background: #fff0f0; color: #d9232e; }
.team-task-status.is-pending { background: #fff7df; color: #8c6a00; }
.team-no-tasks { margin: 0; padding: 15px; color: #8a94a3; font-size: 10px; }
.role-manager { background: #edf0ff; color: #4f55a6; }
.manager-sector-field { grid-column: 1 / -1; min-width: 0; margin: 0; border: 1px solid #dce2e9; border-radius: 10px; padding: 12px 14px 14px; background: #fafbfc; }
.manager-sector-field legend { padding: 0 5px; color: #59677a; font-size: 11px; font-weight: 600; }
.manager-sector-field .helper-text { margin: 0 0 9px; color: #788698; font-size: 10px; }
.manager-sector-choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(145px, 1fr)); gap: 7px; }
.manager-sector-option { display: flex; align-items: center; gap: 8px; min-height: 37px; border: 1px solid #e2e6ed; border-radius: 7px; padding: 7px 10px; background: #fff; color: #49566a; font-size: 11px; cursor: pointer; }
.manager-sector-option:has(input:checked) { border-color: #f3a9ac; background: #fff6f6; color: #a70b10; }
.manager-sector-option input { accent-color: #f40a11; }
.manager-filter-panel { margin-bottom: 13px; }
.manager-filters { display: grid; grid-template-columns: minmax(180px, 1fr) minmax(160px, .7fr) auto auto; align-items: end; gap: 12px; }
.manager-filters .form-field { margin: 0; }
.manager-summary { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.manager-metric-filter { display: block; width: 100%; color: var(--ink); font: inherit; text-align: left; cursor: pointer; transition: border-color .16s ease, box-shadow .16s ease, background .16s ease; }
.manager-metric-filter:hover { border-color: #c8d0dc; background: #fbfcfd; }
.manager-metric-filter.is-selected { border-color: #f40a11; box-shadow: 0 0 0 2px rgba(244,10,17,.08); }
.manager-metric-filter:focus-visible { outline: 2px solid #f40a11; outline-offset: 2px; }
.manager-export-button { min-height: 39px; white-space: nowrap; }
.manager-daily-panel { margin-top: 14px; }
.manager-recurrence-panel { margin-top: 14px; padding: 18px; }
.manager-recurrence-panel .panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.manager-recurrence-total { flex: 0 0 auto; border-radius: 999px; padding: 6px 10px; background: #fff0f0; color: #bd1016; font-size: 10px; font-weight: 600; }
.manager-recurrence-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 330px), 1fr)); gap: 10px; }
.manager-recurrence-card { overflow: hidden; border: 1px solid #e1e6ed; border-radius: 9px; background: #fff; }
.manager-recurrence-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 13px 14px; background: #fafbfc; }
.manager-recurrence-sector { color: #788699; font-size: 9px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.manager-recurrence-head h3 { margin: 3px 0; color: #293344; font-size: 12px; font-weight: 600; }
.manager-recurrence-head p { margin: 0; color: #778395; font-size: 10px; line-height: 1.45; }
.manager-recurrence-head > strong { flex: 0 0 auto; border-radius: 8px; padding: 6px 8px; background: #fff0f0; color: #bf1218; font-size: 12px; }
.manager-recurrence-head > strong small { display: block; font-size: 8px; font-weight: 500; }
.manager-recurrence-card ul { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; }
.manager-recurrence-card li { display: grid; gap: 3px; border-top: 1px solid #eff1f4; padding: 9px 13px; color: #697587; font-size: 10px; line-height: 1.45; }
.manager-recurrence-card li time { color: #b4141a; font-size: 9px; font-weight: 600; }
.manager-recurrence-empty, .manager-no-sectors { margin-bottom: 14px; }
.manager-no-sectors { border-left: 3px solid #ffd600; }
.manager-no-sectors p { margin: 5px 0 0; color: #788496; font-size: 11px; }
.checklist-table-tools { display: grid; grid-template-columns: minmax(220px, 1.3fr) minmax(200px, .8fr); gap: 12px; margin: 14px 0 10px; }
.checklist-table-tools .form-field { margin: 0; }
.checklist-day-groups { display: grid; gap: 9px; }
.checklist-day-group { overflow: hidden; border: 1px solid #e1e6ed; border-left: 4px solid #c4cbd5; border-radius: 10px; background: #fff; }
.checklist-day-group.is-complete { border-left-color: #15975d; }
.checklist-day-group.is-partial, .checklist-day-group.is-pending { border-left-color: #e4b600; }
.checklist-day-group.is-missed { border-left-color: #df3038; }
.checklist-day-group[hidden] { display: none; }
.checklist-day-summary { display: grid; grid-template-columns: minmax(220px, 1.4fr) minmax(150px, .8fr) auto; align-items: center; gap: 18px; padding: 14px 16px; cursor: pointer; list-style: none; }
.checklist-day-summary::-webkit-details-marker { display: none; }
.checklist-day-title { display: grid; gap: 4px; }
.checklist-day-title strong { color: #28354a; font-size: 12px; font-weight: 600; text-transform: capitalize; }
.checklist-day-title small { color: #748195; font-size: 10px; }
.checklist-day-progress { display: flex; align-items: center; gap: 9px; }
.checklist-day-progress-track { height: 7px; flex: 1; overflow: hidden; border-radius: 5px; background: #eef1f5; }
.checklist-day-progress-track i { display: block; height: 100%; border-radius: inherit; background: #15975d; transition: width .18s; }
.checklist-day-group.is-partial .checklist-day-progress-track i, .checklist-day-group.is-pending .checklist-day-progress-track i { background: #e4b600; }
.checklist-day-group.is-missed .checklist-day-progress-track i { background: #df3038; }
.checklist-day-progress > strong { min-width: 38px; color: #15975d; font-size: 12px; text-align: right; }
.checklist-day-group.is-partial .checklist-day-progress > strong, .checklist-day-group.is-pending .checklist-day-progress > strong { color: #9b7900; }
.checklist-day-group.is-missed .checklist-day-progress > strong { color: #c51b23; }
.checklist-day-open { display: flex; align-items: center; gap: 7px; color: #667388; font-size: 10px; font-weight: 600; white-space: nowrap; }
.checklist-day-open b { display: grid; width: 24px; height: 24px; place-items: center; border: 1px solid #e1e6ed; border-radius: 50%; color: #4d5a6e; font-size: 14px; transition: transform .15s; }
.checklist-day-group[open] .checklist-day-open b { transform: rotate(180deg); }
.checklist-day-content { border-top: 1px solid #e8ecf1; padding: 0 10px 10px; }
.checklist-table-wrap { width: 100%; overflow: auto; border: 1px solid #e2e6ed; border-radius: 10px; background: #fff; }
.checklist-table { width: 100%; min-width: 900px; border-collapse: collapse; font-size: 11px; }
.checklist-table th { position: sticky; top: 0; z-index: 1; padding: 11px 12px; background: #f5f7fa; color: #657186; font-size: 9px; font-weight: 600; letter-spacing: .04em; text-align: left; text-transform: uppercase; }
.checklist-table td { border-top: 1px solid #edf0f4; padding: 10px 12px; color: #546174; vertical-align: top; }
.checklist-table tbody tr:hover { background: #fafbfc; }
.checklist-table td.checklist-person { min-width: 150px; color: #293344; font-weight: 600; }
.checklist-table td.checklist-activity { min-width: 220px; }
.checklist-activity strong, .checklist-activity small { display: block; }
.checklist-activity strong { color: #354155; font-size: 10px; font-weight: 500; }
.checklist-activity small { margin-top: 3px; color: #8993a2; font-size: 9px; }
.checklist-time { display: block; margin-top: 3px; color: #8993a2; font-size: 9px; }
.checklist-status { display: inline-flex; align-items: center; border-radius: 999px; padding: 5px 9px; font-size: 9px; font-weight: 600; white-space: nowrap; }
.checklist-status.is-done { background: #e6f5ec; color: #147a4c; }
.checklist-status.is-missed { background: #fde8e9; color: #c51b23; }
.checklist-status.is-pending { background: #fff5cc; color: #796300; }
.checklist-table-empty { padding: 24px !important; color: #8791a0 !important; text-align: center; }
.checklist-table tr[hidden] { display: none; }
.team-daily-date { flex-wrap: wrap; }
.team-daily-date .form-control { min-width: 130px; }
.manager-filters { grid-template-columns: minmax(140px, .8fr) repeat(2, minmax(135px, .7fr)) auto auto; }
.manager-synthesis-panel { margin: 14px 0; padding: 18px; }
.manager-synthesis-panel .panel-heading { margin-bottom: 12px; }
.manager-completion-summary { display: grid; grid-template-columns: auto minmax(120px, 1fr) auto; align-items: center; gap: 12px; margin-top: 15px; border: 1px solid #e5e9ef; border-radius: 10px; padding: 12px 14px; background: #fafbfd; }
.manager-completion-summary > div:first-child { display: flex; align-items: center; gap: 12px; }
.manager-completion-summary > div:first-child span { color: #6d7889; font-size: 10px; }
.manager-completion-summary > div:first-child strong { color: #147a4c; font-size: 18px; }
.manager-completion-summary small { color: #8993a2; font-size: 9px; text-align: right; }
.manager-completion-track { height: 8px; overflow: hidden; border-radius: 999px; background: #e8edf1; }
.manager-completion-track span { display: block; height: 100%; border-radius: inherit; background: #15945b; transition: width .2s ease; }
.manager-attention { margin-top: 16px; }
.manager-attention-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.manager-attention-heading h3 { margin: 0; color: #354155; font-size: 11px; font-weight: 600; }
.manager-attention-heading > span { color: #8b95a4; font-size: 9px; }
.manager-attention-list { display: grid; gap: 6px; }
.manager-attention-row { display: grid; grid-template-columns: minmax(180px, 1fr) auto auto; align-items: center; gap: 10px; border: 1px solid #e8ebef; border-radius: 8px; padding: 8px 10px; background: #fff; }
.manager-attention-row > div strong, .manager-attention-row > div small { display: block; }
.manager-attention-row > div strong { color: #354155; font-size: 10px; font-weight: 600; }
.manager-attention-row > div small { margin-top: 2px; color: #8993a2; font-size: 9px; }
.attention-missed, .attention-pending { border-radius: 999px; padding: 5px 8px; font-size: 9px; font-weight: 600; white-space: nowrap; }
.attention-missed { background: #fde8e9; color: #c51b23; }
.attention-pending { background: #fff5cc; color: #796300; }
.manager-attention-empty { margin: 0; border-radius: 8px; padding: 12px; background: #f5fbf7; color: #147a4c; font-size: 10px; }
.adherence-filter-panel { margin-bottom: 14px; padding: 16px; }
.adherence-filters { display: grid; grid-template-columns: minmax(120px,.7fr) minmax(145px,.85fr) minmax(155px,1fr) minmax(145px,.9fr) minmax(170px,1.1fr) auto; align-items: end; gap: 12px; }
.adherence-filters .form-field { margin: 0; }
.adherence-overview { display: grid; grid-template-columns: minmax(220px,.8fr) minmax(0,2fr); gap: 14px; margin-bottom: 14px; }
.adherence-main-metric, .adherence-metric { display: flex; flex-direction: column; justify-content: center; gap: 6px; min-height: 100px; border: 1px solid #dce2ea; border-radius: 12px; padding: 17px 19px; background: #fff; }
.adherence-main-metric { border-left: 4px solid #cbd1d9; }
.adherence-main-metric.status-complete { border-left-color: #15945b; }
.adherence-main-metric.status-partial { border-left-color: #ffd600; }
.adherence-main-metric.status-zero { border-left-color: #f40a11; }
.adherence-main-metric span, .adherence-metric span { color: #748094; font-size: 10px; letter-spacing: .08em; text-transform: uppercase; }
.adherence-main-metric strong { color: #263449; font-size: 30px; line-height: 1; }
.adherence-main-metric small { color: #8993a2; font-size: 10px; }
.adherence-metrics { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 10px; }
.adherence-metric { min-height: 84px; }
.adherence-metric strong { color: #263449; font-size: 22px; }
.adherence-sector-panel, .adherence-detail-panel { padding: 18px; }
.adherence-card-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(min(100%,250px),1fr)); gap: 10px; }
.adherence-sector-card { display: grid; grid-template-columns: 1fr auto; gap: 7px 10px; min-height: 112px; border: 1px solid #dce2ea; border-left: 4px solid #cbd1d9; border-radius: 10px; padding: 14px; background: #fff; color: #273448; text-align: left; cursor: pointer; }
.adherence-sector-card:hover { box-shadow: 0 5px 15px rgba(31,45,65,.07); transform: translateY(-1px); }
.adherence-sector-card.status-complete { border-left-color: #15945b; }
.adherence-sector-card.status-partial { border-left-color: #ffd600; }
.adherence-sector-card.status-zero { border-left-color: #f40a11; }
.adherence-sector-card > span { font-size: 13px; font-weight: 600; }
.adherence-sector-card > small { grid-column: 1; color: #808b9b; font-size: 9px; }
.adherence-sector-card > strong { grid-column: 2; grid-row: 1 / span 2; align-self: center; font-size: 23px; }
.adherence-sector-card > i { grid-column: 1 / -1; color: #8892a2; font-size: 9px; font-style: normal; }
.adherence-badge { border-radius: 999px; padding: 8px 12px; color: #657084; background: #eef0f3; font-size: 13px; }
.adherence-badge.status-complete { color: #147a4c; background: #e6f5ec; }
.adherence-badge.status-partial { color: #796300; background: #fff5cc; }
.adherence-badge.status-zero { color: #c51b23; background: #fde8e9; }
.adherence-breadcrumb { display: flex; align-items: center; gap: 8px; margin: 4px 0 10px; color: #788496; font-size: 11px; }
.adherence-breadcrumb button { border: 0; padding: 4px 0; background: transparent; color: #c20b12; font: inherit; cursor: pointer; }
.adherence-activity-list { display: grid; gap: 8px; margin-top: 14px; }
.adherence-day-group { overflow: hidden; border: 1px solid #dfe5ec; border-left: 4px solid #cbd1d9; border-radius: 10px; background: #fff; }
.adherence-day-group.is-complete { border-left-color: #15945b; }
.adherence-day-group.is-partial, .adherence-day-group.is-pending { border-left-color: #ffd600; }
.adherence-day-group.is-missed { border-left-color: #f40a11; }
.adherence-day-summary { display: grid; grid-template-columns: minmax(230px, 1.2fr) minmax(150px, .7fr) auto; align-items: center; gap: 16px; padding: 13px 16px; cursor: pointer; list-style: none; }
.adherence-day-summary::-webkit-details-marker { display: none; }
.adherence-day-heading { display: grid; gap: 4px; }
.adherence-day-heading strong { color: #263449; font-size: 11px; font-weight: 600; text-transform: capitalize; }
.adherence-day-heading small { color: #8792a2; font-size: 9px; }
.adherence-day-progress { display: flex; align-items: center; gap: 8px; }
.adherence-day-progress > i { height: 7px; flex: 1; overflow: hidden; border-radius: 8px; background: #eef1f5; }
.adherence-day-progress > i > b { display: block; height: 100%; border-radius: inherit; background: #15945b; }
.adherence-day-group.is-partial .adherence-day-progress > i > b, .adherence-day-group.is-pending .adherence-day-progress > i > b { background: #ffd600; }
.adherence-day-group.is-missed .adherence-day-progress > i > b { background: #f40a11; }
.adherence-day-progress > strong { min-width: 34px; color: #15945b; font-size: 11px; text-align: right; }
.adherence-day-group.is-partial .adherence-day-progress > strong, .adherence-day-group.is-pending .adherence-day-progress > strong { color: #947700; }
.adherence-day-group.is-missed .adherence-day-progress > strong { color: #c51b23; }
.adherence-day-toggle { display: flex; align-items: center; gap: 7px; color: #788496; font-size: 9px; font-weight: 600; white-space: nowrap; }
.adherence-day-toggle b { display: grid; width: 23px; height: 23px; place-items: center; border: 1px solid #e1e6ed; border-radius: 50%; font-size: 13px; transition: transform .15s; }
.adherence-day-group[open] .adherence-day-toggle b { transform: rotate(180deg); }
.adherence-day-tasks { display: grid; gap: 8px; border-top: 1px solid #e8ecf1; padding: 10px; }
.adherence-day-tasks .adherence-activity { margin: 0; }
.adherence-activity { display: flex; justify-content: space-between; gap: 15px; border: 1px solid #e2e7ed; border-left: 4px solid #ffd600; border-radius: 8px; padding: 11px 13px; background: #fffdf4; }
.adherence-activity.status-complete { border-left-color: #15945b; background: #f5fbf7; }
.adherence-activity.status-zero { border-left-color: #f40a11; background: #fff7f7; }
.adherence-activity > div { display: grid; gap: 4px; }
.adherence-activity time, .adherence-activity small { color: #8792a2; font-size: 9px; }
.adherence-activity strong { color: #263449; font-size: 11px; }
.adherence-activity p { margin: 3px 0 0; color: #a32128; font-size: 10px; }
.adherence-activity > span { flex: 0 0 auto; align-self: center; color: #7b6500; font-size: 10px; font-weight: 600; }
.adherence-activity.status-complete > span { color: #147a4c; }
.adherence-activity.status-zero > span { color: #c51b23; }
.adherence-dashboard-grid { display: grid; grid-template-columns: minmax(0,1.65fr) minmax(340px,1fr); gap: 14px; margin-bottom: 14px; align-items: stretch; }
.adherence-chart-panel, .adherence-table-panel { min-width: 0; padding: 17px 18px; }
.adherence-chart-panel .panel-heading, .adherence-table-panel .panel-heading { align-items: flex-start; margin-bottom: 13px; }
.adherence-chart-panel .panel-heading h2, .adherence-table-panel .panel-heading h2 { margin: 0; color: #263449; font-size: 13px; }
.adherence-chart-panel .panel-heading p, .adherence-table-panel .panel-heading p { margin: 4px 0 0; color: #8792a2; font-size: 10px; }
.adherence-chart-year { border-radius: 999px; padding: 6px 10px; background: #f2f4f7; color: #657084; font-size: 10px; font-weight: 600; }
.adherence-chart-plot { display: grid; grid-template-columns: repeat(var(--bar-count,12),minmax(0,1fr)); gap: 5px; min-height: 190px; border-bottom: 1px solid #ccd3dc; padding: 0 3px; }
.adherence-month-column { display: grid; grid-template-rows: 20px minmax(0,1fr) 22px; justify-items: center; align-items: end; gap: 4px; min-width: 0; border: 0; border-radius: 7px 7px 0 0; padding: 0 1px; background: transparent; color: #6d7888; cursor: pointer; }
.adherence-month-column:hover, .adherence-month-column.is-selected { background: #f4f7fb; }
.adherence-month-column.is-selected { box-shadow: inset 0 -3px #2d8df0; color: #263449; }
.adherence-month-column:disabled { cursor: default; opacity: .42; }
.adherence-month-column:focus-visible { outline: 2px solid #2d8df0; outline-offset: 2px; }
.adherence-month-value { align-self: end; color: #566274; font-size: 9px; font-weight: 600; white-space: nowrap; }
.adherence-bar-track { display: flex; align-items: flex-end; width: min(72%,32px); height: 100%; border-radius: 5px 5px 0 0; background: #f2f4f7; overflow: hidden; }
.adherence-bar-track i { display: block; width: 100%; min-height: 2px; border-radius: 5px 5px 0 0; background: #9ba4b0; transition: height .2s ease, filter .15s ease; }
.adherence-month-column.status-complete .adherence-bar-track i, .adherence-chart-legend .status-complete { background: #15945b; }
.adherence-month-column.status-partial .adherence-bar-track i, .adherence-chart-legend .status-partial { background: #ffd600; }
.adherence-month-column.status-zero .adherence-bar-track i, .adherence-chart-legend .status-zero { background: #f40a11; }
.adherence-month-column.status-none .adherence-bar-track i, .adherence-chart-legend .status-none { background: #b8c0ca; }
.adherence-month-name { align-self: start; color: #778294; font-size: 9px; line-height: 1; text-transform: capitalize; }
.adherence-chart-legend { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 12px; color: #7e8999; font-size: 9px; }
.adherence-chart-legend span { display: inline-flex; align-items: center; gap: 5px; }
.adherence-chart-legend i, .adherence-table-sector i { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #b8c0ca; }
.adherence-table-total { border-radius: 999px; padding: 6px 9px; background: #f1f3f5; color: #6c7786; font-size: 11px; font-weight: 700; white-space: nowrap; }
.adherence-table-total.status-complete { background: #e6f5ec; color: #147a4c; }
.adherence-table-total.status-partial { background: #fff5cc; color: #796300; }
.adherence-table-total.status-zero { background: #fde8e9; color: #c51b23; }
.adherence-back-months { border: 0; padding: 0; background: transparent; color: #c20b12; font: inherit; font-size: 10px; font-weight: 600; cursor: pointer; white-space: nowrap; }
.adherence-back-months:hover { text-decoration: underline; }
.field-hint { color: #8792a2; font-size: 9px; font-weight: 400; }
.adherence-table-scroll { max-height: 205px; overflow: auto; }
.adherence-sector-table { width: 100%; border-collapse: collapse; font-size: 9px; text-align: left; }
.adherence-sector-table th, .adherence-sector-table td { border-bottom: 1px solid #edf0f3; padding: 8px 5px; white-space: nowrap; }
.adherence-sector-table thead th { color: #8892a1; font-size: 8px; font-weight: 600; text-transform: uppercase; }
.adherence-sector-table tbody th { color: #354155; font-weight: 500; }
.adherence-sector-table td { color: #6f7b8c; text-align: right; }
.adherence-sector-table td strong { font-size: 9px; }
.adherence-table-sector { display: inline-flex; align-items: center; gap: 7px; }
.adherence-table-sector i.status-complete { background: #15945b; }
.adherence-table-sector i.status-partial { background: #ffd600; }
.adherence-table-sector i.status-zero { background: #f40a11; }
.adherence-table-sector i.status-none { background: #b8c0ca; }
.status-text-complete { color: #147a4c; }
.status-text-partial { color: #8a7000; }
.status-text-zero { color: #c51b23; }
.status-text-none { color: #8993a2; }
.adherence-sector-table tfoot th, .adherence-sector-table tfoot td { border-top: 1px solid #dce2ea; border-bottom: 0; color: #263449; font-weight: 700; }
.adherence-table-empty { padding: 18px 5px !important; color: #8792a2 !important; text-align: center !important; }
.role-director { color: #285d9c; background: #e8f1ff; }
@media (max-width: 760px) {
  .adherence-filters, .adherence-overview { grid-template-columns: 1fr; }
  .adherence-dashboard-grid { grid-template-columns: 1fr; }
}
@media (min-width: 761px) and (max-width: 1120px) {
  .adherence-filters { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .adherence-filters > button { grid-column: 3; }
}
@media (max-width: 520px) {
  .adherence-metrics { grid-template-columns: 1fr; }
  .adherence-activity { flex-direction: column; }
  .adherence-chart-panel, .adherence-table-panel { padding: 13px 10px; }
  .adherence-chart-plot { gap: 2px; min-height: 160px; }
  .adherence-month-value { font-size: 7px; }
  .adherence-month-name { font-size: 7px; }
  .adherence-chart-legend { gap: 8px; }
}
@media (max-width: 680px) {
  .manager-completion-summary { grid-template-columns: 1fr; gap: 8px; }
  .manager-completion-summary small { text-align: left; }
  .manager-attention-heading { align-items: flex-start; flex-direction: column; gap: 3px; }
  .manager-attention-row { grid-template-columns: minmax(0, 1fr) auto; }
  .manager-attention-row > div { grid-column: 1 / -1; }
}
@media (max-width: 680px) {
  .team-daily-heading { align-items: stretch; flex-direction: column; }
  .team-daily-date { display: grid; grid-template-columns: 1fr auto; }
  .team-daily-date .field-label { grid-column: 1 / -1; margin-bottom: -4px; }
  .team-daily-date .form-control { width: 100%; }
  .team-daily-summary { gap: 5px; }
  .team-daily-summary span { padding: 5px 8px; font-size: 9px; }
  .team-person-heading { flex-direction: column; }
  .team-person-counts { justify-content: flex-start; }
  .manager-filters { grid-template-columns: 1fr; }
  .checklist-table-tools { grid-template-columns: 1fr; }
  .checklist-day-summary { grid-template-columns: minmax(0, 1fr) auto; gap: 8px 10px; padding: 12px; }
  .checklist-day-title { grid-column: 1 / 2; }
  .checklist-day-progress { grid-column: 1 / 2; grid-row: 2; }
  .checklist-day-open { grid-column: 2; grid-row: 1 / span 2; }
  .checklist-day-content { padding-inline: 6px; }
  .adherence-day-summary { grid-template-columns: minmax(0, 1fr) auto; gap: 8px 10px; padding: 11px; }
  .adherence-day-progress { grid-column: 1; grid-row: 2; }
  .adherence-day-toggle { grid-column: 2; grid-row: 1 / span 2; }
  .manager-filters .primary-button, .manager-filters .manager-export-button { width: 100%; }
  .manager-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Keep the app content scrollable while the sidebar remains fixed. */
html, body { min-height: 100%; }
body { overflow-y: auto; }
.app-main { height: 100vh; height: 100dvh; min-height: 0; overflow-x: hidden; overflow-y: auto; overscroll-behavior-y: contain; }
.primary-nav { min-height: 0; flex: 1 1 auto; overflow-y: auto; overscroll-behavior: contain; }
.primary-nav { display: flex; flex-direction: column; align-items: stretch; justify-content: flex-start; align-content: flex-start; gap: 6px; }
.primary-nav > .nav-item { flex: 0 0 auto; min-height: 42px; }
.sector-nav-list { display: flex; flex-direction: column; align-items: stretch; align-content: flex-start; gap: 4px; flex: 0 0 auto; margin-bottom: 12px; }
.sector-nav-list > .sector-choice { flex: 0 0 auto; min-height: 42px; }
.brand-accent { clip-path: polygon(0 0, 92% 0, 100% 100%); }

/* Calendar status colors: all yes, all no, mixed with at least one no, no answer. */
.status-complete .day-dot, .legend-dot.complete { background: #15945b; }
.status-all_no .day-dot, .legend-dot.all-no { background: #f40a11; }
.status-partial .day-dot, .legend-dot.partial { background: #ffd600; }
.status-no_records .day-dot, .legend-dot.no-records { background: #cbd1d9; }
.task-card.is-complete { border-color: #a8d8bd; background: #f5fbf7; }
.task-card.is-missed { border-color: #f2aeb1; background: #fff7f7; }
.task-card.is-pending { border-color: #d9dee5; background: #fff; }
.tag.status-done, .history-result.yes { background: #e6f5ec; color: #147a4c; }
.tag.status-missed, .history-result.no { background: #fde8e9; color: #c51b23; }
.tag.status-pending { background: #eef0f3; color: #687386; }
.choice-button.is-selected.yes { border-color: #15945b; background: #15945b; color: #fff; }
.choice-button.is-selected.no { border-color: #f40a11; background: #f40a11; color: #fff; }
