:root {
  color-scheme: light;
  --ink: #17231e;
  --muted: #718078;
  --line: #e7ece8;
  --surface: #ffffff;
  --canvas: #f4f7f4;
  --green: #1e7655;
  --green-dark: #15563e;
  --green-soft: #e8f4ed;
  --orange: #f0a34a;
  --red: #c84d45;
  --sidebar: #14251f;
  --sidebar-muted: #aabbb2;
  --shadow: 0 12px 35px rgba(26, 48, 37, .07);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
html { min-width: 320px; background: var(--canvas); }
body { margin: 0; color: var(--ink); background: var(--canvas); font-size: 14px; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 3px solid rgba(30,118,85,.25); outline-offset: 2px;
}
.app-shell { min-height: 100vh; display: flex; }
.sidebar { width: 258px; flex: 0 0 258px; background: var(--sidebar); color: #fff; min-height: 100vh; }
.sidebar-inner { display: flex; flex-direction: column; min-height: 100vh; padding: 22px 14px 18px; }
.brand { display: flex; align-items: center; gap: 11px; padding: 3px 10px 24px; }
.brand-mark { width: 39px; height: 39px; display: grid; place-items: center; border-radius: 13px; background: #f2a34d; color: #1a2a22; font-weight: 900; font-size: 17px; }
.brand-name { font-size: 19px; font-weight: 800; letter-spacing: -.5px; }
.brand-caption { display: block; margin-top: 2px; color: var(--sidebar-muted); font-size: 10px; letter-spacing: 1.2px; text-transform: uppercase; }
.nav-label { color: #82978b; font-size: 10px; font-weight: 800; letter-spacing: 1.4px; padding: 9px 12px 10px; text-transform: uppercase; }
.nav-list { display: grid; gap: 4px; overflow-y: auto; padding: 0 2px 10px; }
.nav-link { display: flex; align-items: center; gap: 12px; min-height: 43px; padding: 9px 11px; border: 0; border-radius: 10px; color: #c6d2cb; background: transparent; text-align: left; width: 100%; transition: background .15s, color .15s; }
.nav-link:hover { background: rgba(255,255,255,.08); color: #fff; }
.nav-link.active { background: #244d3c; color: #fff; box-shadow: inset 3px 0 #f0a34a; }
.nav-icon { width: 22px; text-align: center; font-size: 17px; }
.nav-text { font-size: 12.5px; font-weight: 600; }
.sidebar-bottom { margin-top: auto; padding: 13px 9px 0; border-top: 1px solid rgba(255,255,255,.1); color: var(--sidebar-muted); font-size: 11px; line-height: 1.6; }
.sidebar-bottom strong { color: #fff; font-weight: 700; }
.app-main { flex: 1; min-width: 0; display: flex; flex-direction: column; min-height: 100vh; }
.topbar { height: 76px; flex: 0 0 76px; display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 0 32px; background: var(--surface); border-bottom: 1px solid var(--line); }
.topbar-left, .topbar-right { display: flex; align-items: center; gap: 14px; min-width: 0; }
.page-heading { margin: 0; font-size: 19px; font-weight: 800; letter-spacing: -.4px; }
.page-subheading { margin: 3px 0 0; color: var(--muted); font-size: 11px; }
.icon-button { width: 42px; height: 42px; border: 1px solid var(--line); background: #fff; border-radius: 12px; color: var(--ink); display: inline-grid; place-items: center; font-size: 18px; }
.icon-button:hover { background: var(--canvas); }
.mobile-menu-button { display: none; }
.status-pill { display: inline-flex; align-items: center; gap: 7px; padding: 8px 11px; border: 1px solid #dcece2; background: #f2faf5; color: var(--green-dark); border-radius: 30px; font-size: 11px; font-weight: 700; white-space: nowrap; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: #35a66e; }
.user-chip { display: flex; align-items: center; gap: 9px; padding-left: 13px; border-left: 1px solid var(--line); }
.avatar { width: 35px; height: 35px; border-radius: 50%; background: #f9e9d7; color: #875321; display: grid; place-items: center; font-weight: 800; }
.user-name { font-size: 12px; font-weight: 700; }
.user-role { color: var(--muted); font-size: 10px; margin-top: 2px; }
.main-content { flex: 1; width: 100%; max-width: 1600px; margin: 0 auto; padding: 29px 32px 36px; }
.app-footer { display: flex; justify-content: space-between; gap: 15px; padding: 14px 32px; color: #8a9890; font-size: 10px; border-top: 1px solid var(--line); background: #fff; }
.welcome-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin-bottom: 23px; }
.eyebrow { color: var(--green); font-size: 10px; font-weight: 800; letter-spacing: 1.5px; text-transform: uppercase; }
.welcome-title { margin: 7px 0 5px; font-size: clamp(23px, 3vw, 29px); line-height: 1.15; letter-spacing: -.8px; }
.welcome-copy { margin: 0; color: var(--muted); font-size: 12px; }
.date-label { color: var(--muted); font-size: 11px; white-space: nowrap; }
.stats-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 14px; margin-bottom: 19px; }
.stat-card, .panel, .module-card { background: var(--surface); border: 1px solid var(--line); border-radius: 15px; box-shadow: 0 3px 12px rgba(24,47,35,.025); }
.stat-card { padding: 17px 18px; min-height: 123px; }
.stat-top { display: flex; justify-content: space-between; align-items: center; color: var(--muted); font-size: 11px; font-weight: 600; }
.stat-icon { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 10px; background: var(--green-soft); font-size: 16px; }
.stat-value { margin-top: 14px; font-size: 24px; font-weight: 800; letter-spacing: -.7px; }
.stat-note { margin-top: 3px; color: #8b9891; font-size: 10px; }
.dashboard-grid { display: grid; grid-template-columns: minmax(0,1.45fr) minmax(270px,.85fr); gap: 16px; }
.panel { padding: 19px; }
.panel-heading { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 17px; }
.panel-title { margin: 0; font-size: 14px; font-weight: 800; }
.panel-subtitle { margin: 4px 0 0; color: var(--muted); font-size: 10px; }
.panel-action { border: 0; background: transparent; color: var(--green); font-size: 11px; font-weight: 700; }
.empty-chart { min-height: 190px; border-radius: 11px; background: linear-gradient(180deg,#f7faf7,#fff); display: flex; align-items: center; justify-content: center; flex-direction: column; color: #8b9991; text-align: center; gap: 7px; }
.empty-chart-icon { font-size: 27px; }
.empty-chart strong { color: #4b5d52; font-size: 12px; }
.empty-chart span { font-size: 10px; }
.quick-actions { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; }
.quick-action { min-height: 82px; border: 1px solid var(--line); border-radius: 12px; background: #fff; padding: 13px; text-align: left; transition: border .15s, transform .15s; }
.quick-action:hover { border-color: #9fc8ae; transform: translateY(-1px); }
.quick-action-icon { display: block; font-size: 19px; margin-bottom: 7px; }
.quick-action strong { display: block; font-size: 11px; }
.quick-action span:last-child { color: var(--muted); font-size: 9px; }
.section-heading { margin: 25px 0 12px; font-size: 14px; font-weight: 800; }
.module-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 12px; }
.module-card { padding: 15px; min-height: 112px; text-align: left; transition: border .15s, transform .15s; cursor: pointer; }
.module-card:hover { border-color: #a6cbb4; transform: translateY(-2px); }
.module-card-icon { display: block; font-size: 21px; margin-bottom: 10px; }
.module-card strong { display: block; font-size: 11px; }
.module-card small { display: block; color: var(--muted); font-size: 9px; margin-top: 4px; line-height: 1.4; }
.module-intro { display: flex; align-items: flex-start; gap: 15px; margin-bottom: 21px; }
.module-hero-icon { width: 54px; height: 54px; flex: 0 0 54px; display: grid; place-items: center; background: var(--green-soft); border-radius: 15px; font-size: 26px; }
.module-description { color: var(--muted); line-height: 1.6; max-width: 680px; font-size: 12px; }
.info-banner { display: flex; align-items: flex-start; gap: 12px; background: #f0f7f2; border: 1px solid #dcece1; border-radius: 12px; padding: 15px; color: #315b43; margin-bottom: 17px; }
.info-banner strong { display: block; font-size: 12px; margin-bottom: 4px; }
.info-banner p { margin: 0; color: #5f7867; font-size: 11px; line-height: 1.5; }
.placeholder-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 13px; }
.placeholder-card { border: 1px solid var(--line); background: #fff; border-radius: 13px; padding: 16px; min-height: 112px; }
.placeholder-card span { display: block; font-size: 19px; margin-bottom: 10px; }
.placeholder-card strong { display: block; font-size: 11px; }
.placeholder-card p { color: var(--muted); font-size: 10px; line-height: 1.5; margin: 5px 0 0; }
.primary-button, .secondary-button { min-height: 43px; border-radius: 10px; padding: 0 16px; font-weight: 700; font-size: 12px; border: 1px solid transparent; }
.primary-button { background: var(--green); color: #fff; }
.primary-button:hover { background: var(--green-dark); }
.secondary-button { background: #fff; color: var(--ink); border-color: var(--line); }
.secondary-button:hover { background: var(--canvas); }
.search-input { height: 40px; border: 1px solid var(--line); border-radius: 10px; padding: 0 12px; background: #fff; min-width: 180px; }
.toast-region { position: fixed; right: 20px; bottom: 20px; z-index: 1000; display: grid; gap: 9px; }
.toast { min-width: 230px; max-width: min(360px,calc(100vw - 40px)); padding: 13px 16px; border-radius: 11px; color: #fff; background: #20382c; box-shadow: var(--shadow); font-size: 12px; animation: toast-in .2s ease-out; }
.toast.error { background: #a63d37; }
.toast.warning { background: #8c5b1e; }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.modal-overlay { position: fixed; inset: 0; z-index: 900; display: grid; place-items: center; padding: 20px; background: rgba(13,27,20,.48); }
.modal { width: min(460px,100%); border-radius: 16px; background: #fff; box-shadow: 0 25px 80px rgba(0,0,0,.2); overflow: hidden; }
.modal-header { display: flex; justify-content: space-between; align-items: center; padding: 17px 20px; border-bottom: 1px solid var(--line); }
.modal-header h2 { margin: 0; font-size: 15px; }
.modal-body { padding: 19px 20px; color: #526258; font-size: 12px; line-height: 1.6; }
.modal-footer { display: flex; justify-content: flex-end; gap: 9px; padding: 0 20px 19px; }
.loading-state { padding: 50px; text-align: center; color: var(--muted); }
.muted { color: var(--muted); }
.small-note { color: var(--muted); font-size: 10px; line-height: 1.5; }
