:root {
  --ink: #172726;
  --muted: #71807d;
  --line: #e3e9e7;
  --surface: #ffffff;
  --canvas: #f4f7f6;
  --brand-950: #092d2d;
  --brand-900: #123c3b;
  --brand-800: #17514e;
  --brand-700: #1f6762;
  --brand-600: #2f8279;
  --brand-200: #b9ded8;
  --brand-100: #e4f2ef;
  --green: #2f8663;
  --green-bg: #e8f6ef;
  --blue: #4f72a9;
  --blue-bg: #edf2fa;
  --amber: #aa772a;
  --amber-bg: #fbf2df;
  --red: #b65b50;
  --red-bg: #fbecea;
  --purple: #775c9d;
  --purple-bg: #f1edf7;
  --shadow: 0 8px 28px rgba(22, 53, 51, .07);
  --radius: 15px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--canvas); font-family: "Segoe UI", Tahoma, Arial, sans-serif; font-size: 14px; }
button, input, select, textarea { font: inherit; }
button { color: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.svg-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.app-shell { min-height: 100vh; display: flex; }
.sidebar { position: fixed; inset: 0 0 0 auto; z-index: 40; width: 258px; min-height: 100vh; padding: 26px 18px 18px; color: rgba(255,255,255,.8); background: linear-gradient(180deg, var(--brand-950), #0d3433 65%, #0b2f2f); display: flex; flex-direction: column; }
.brand { display: flex; align-items: center; gap: 11px; padding: 0 10px 27px; color: white; }
.brand strong { display: block; font-size: 23px; letter-spacing: 3px; }
.brand small { display: block; margin-top: 3px; color: rgba(255,255,255,.55); font-size: 11px; }
.brand-mark { width: 41px; height: 41px; position: relative; display: inline-flex; align-items: end; justify-content: center; gap: 3px; padding: 8px; border-radius: 12px; background: linear-gradient(145deg, #61b2a4, #31756f); box-shadow: inset 0 1px rgba(255,255,255,.3); transform: rotate(-3deg); }
.brand-mark span { display: block; width: 5px; border-radius: 4px; background: white; transform: rotate(15deg); }
.brand-mark span:nth-child(1){ height: 11px; }
.brand-mark span:nth-child(2){ height: 20px; }
.brand-mark span:nth-child(3){ height: 15px; }
.main-nav { display: grid; gap: 5px; }
.nav-item { width: 100%; min-height: 46px; display: flex; align-items: center; gap: 12px; padding: 0 13px; border: 0; border-radius: 10px; background: transparent; color: rgba(255,255,255,.68); cursor: pointer; text-align: right; transition: .2s ease; }
.nav-item svg { width: 19px; height: 19px; }
.nav-item:hover { background: rgba(255,255,255,.06); color: white; }
.nav-item.active { color: white; background: linear-gradient(90deg, rgba(91,170,156,.3), rgba(91,170,156,.13)); box-shadow: inset -3px 0 #68b4a6; }
.nav-item b { margin-right: auto; min-width: 23px; height: 20px; padding: 1px 6px; border-radius: 7px; background: rgba(255,255,255,.12); font-size: 11px; text-align: center; }
.nav-separator { height: 1px; margin: 17px 10px; background: rgba(255,255,255,.09); }
.sidebar-foot { margin-top: auto; }
.support-card { display: flex; align-items: center; gap: 9px; padding: 11px; border: 1px solid rgba(255,255,255,.1); border-radius: 12px; background: rgba(255,255,255,.05); }
.support-card .support-icon { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 9px; background: rgba(101,181,165,.25); color: #9bd6cb; font-weight: 700; }
.support-card div { flex: 1; }
.support-card strong, .support-card small { display: block; }
.support-card strong { color: white; font-size: 12px; }
.support-card small { margin-top: 3px; color: rgba(255,255,255,.48); font-size: 10px; }
.support-card svg { width: 14px; transform: rotate(180deg); }
.sidebar-version { padding-top: 16px; text-align: center; color: rgba(255,255,255,.28); font-size: 10px; }
.main-area { min-width: 0; width: calc(100% - 258px); margin-right: 258px; }
.topbar { height: 73px; position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 20px; padding: 0 31px; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.94); backdrop-filter: blur(14px); }
.top-search { width: min(480px, 45vw); height: 41px; display: flex; align-items: center; gap: 9px; padding: 0 13px; border: 1px solid var(--line); border-radius: 10px; background: #f8faf9; }
.top-search svg { width: 18px; color: #82908d; }
.top-search input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; color: var(--ink); }
.top-search input::placeholder { color: #98a4a1; }
kbd { padding: 2px 6px; border: 1px solid #d8dfdd; border-radius: 5px; background: white; color: #8b9693; font-size: 10px; }
.top-actions { display: flex; align-items: center; gap: 17px; margin-right: auto; }
.icon-button, .more-button, .small-icon { display: grid; place-items: center; border: 0; background: transparent; cursor: pointer; }
.icon-button { width: 39px; height: 39px; border: 1px solid var(--line); border-radius: 10px; color: #596865; }
.notification-button { position: relative; }
.notification-button span { position: absolute; top: 7px; left: 7px; width: 7px; height: 7px; border: 2px solid white; border-radius: 50%; background: #d4695b; }
.user-menu { display: flex; align-items: center; gap: 9px; cursor: pointer; }
.user-menu > div:nth-child(2) { min-width: 95px; }
.user-menu strong, .user-menu small { display: block; }
.user-menu strong { font-size: 12px; }
.user-menu small { margin-top: 3px; color: var(--muted); font-size: 10px; }
.user-menu > svg { width: 13px; color: #8c9896; transform: rotate(90deg); }
.avatar { display: grid; place-items: center; flex: 0 0 auto; width: 37px; height: 37px; border-radius: 11px; background: #dcece8; color: var(--brand-800); font-weight: 700; font-size: 12px; }
.avatar-admin { background: linear-gradient(145deg, #dcece8, #c6dfd9); }
.menu-button { display: none; }
.content { padding: 28px 31px 50px; }
.view { display: none; max-width: 1500px; margin: 0 auto; animation: fadeIn .25s ease; }
.view.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 24px; }
.page-head.compact { align-items: center; }
.eyebrow { margin: 0 0 7px !important; color: var(--brand-600) !important; font-weight: 700; font-size: 11px !important; letter-spacing: .4px; }
.page-head h1 { margin: 0; font-size: 25px; letter-spacing: -.4px; }
.page-head p { margin: 8px 0 0; color: var(--muted); font-size: 13px; }
.head-actions { display: flex; gap: 9px; }
.btn { min-height: 40px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 0 15px; border: 1px solid transparent; border-radius: 9px; cursor: pointer; font-weight: 600; font-size: 12px; transition: .18s ease; }
.btn:hover { transform: translateY(-1px); }
.btn svg { width: 16px; height: 16px; }
.btn-primary { border-color: var(--brand-800); background: var(--brand-800); color: white; box-shadow: 0 5px 12px rgba(18,60,59,.16); }
.btn-primary:hover { background: var(--brand-700); }
.btn-ghost { border-color: var(--line); background: white; color: #42514e; }
.btn-dark { background: var(--ink); color: white; }
.btn-small { min-height: 35px; padding: 0 11px; }
.stats-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 16px; }
.stat-card { min-height: 137px; position: relative; display: grid; grid-template-columns: 47px 1fr; gap: 12px; padding: 19px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: 0 2px 8px rgba(24,55,52,.025); }
.stat-icon, .summary-icon, .quick-icon, .report-icon { display: grid; place-items: center; border-radius: 12px; }
.stat-icon { width: 46px; height: 46px; }
.stat-icon svg { width: 21px; }
.mint { background: var(--brand-100); color: var(--brand-700); }
.blue { background: var(--blue-bg); color: var(--blue); }
.sand { background: var(--amber-bg); color: var(--amber); }
.coral { background: var(--red-bg); color: var(--red); }
.stat-card > div:nth-child(2) > span { display: block; margin-bottom: 6px; color: var(--muted); font-size: 11px; }
.stat-card strong { font-size: 25px; line-height: 1; }
.stat-card strong em { font-size: 13px; font-style: normal; }
.stat-card small { display: block; margin-top: 9px; color: #87928f; font-size: 10px; }
.stat-card small i { margin-left: 3px; font-style: normal; }
.up { color: var(--green); }
.mini-link { position: absolute; right: 19px; bottom: 14px; padding: 0; border: 0; background: transparent; color: var(--brand-600); font-size: 10px; cursor: pointer; }
.dashboard-grid { display: grid; grid-template-columns: minmax(340px, .85fr) minmax(480px, 1.35fr); gap: 16px; margin-bottom: 16px; }
.panel { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: 0 2px 8px rgba(24,55,52,.025); }
.panel-head { min-height: 68px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 20px; border-bottom: 1px solid #edf1f0; }
.panel-head h2 { margin: 0; font-size: 15px; }
.panel-head p { margin: 5px 0 0; color: var(--muted); font-size: 10px; }
.more-button { width: 31px; height: 31px; border-radius: 8px; color: #86928f; }
.more-button:hover, .small-icon:hover { background: #f1f5f4; }
.coverage-wrap { display: grid; grid-template-columns: 164px 1fr; align-items: center; gap: 18px; padding: 24px 22px 16px; }
.donut { --p: 80; width: 145px; height: 145px; position: relative; display: grid; place-items: center; border-radius: 50%; background: conic-gradient(var(--brand-600) calc(var(--p) * 1%), #e8efed 0); }
.donut::before { content: ""; position: absolute; inset: 13px; border-radius: 50%; background: white; }
.donut > div { position: relative; text-align: center; }
.donut strong, .donut span { display: block; }
.donut strong { font-size: 30px; }
.donut span { margin-top: 3px; color: var(--muted); font-size: 10px; }
.coverage-list { display: grid; gap: 12px; }
.coverage-list > div { display: flex; align-items: center; gap: 9px; }
.coverage-list .dot { width: 9px; height: 9px; border-radius: 3px; }
.c1 { background: var(--brand-600); }.c2 { background: var(--red); }.c3 { background: #d8dfdd; }
.coverage-list p { flex: 1; margin: 0; }
.coverage-list strong, .coverage-list small { display: block; }
.coverage-list strong { font-size: 11px; }.coverage-list small { margin-top: 3px; color: var(--muted); font-size: 9px; }
.coverage-list b { font-size: 14px; }
.coverage-alert { display: flex; align-items: center; gap: 9px; margin: 0 20px 20px; padding: 10px 12px; border: 1px solid #f0dfb9; border-radius: 9px; background: #fffaf0; }
.coverage-alert > span { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 8px; background: var(--amber-bg); color: var(--amber); font-weight: 800; }
.coverage-alert p { flex: 1; margin: 0; }.coverage-alert strong, .coverage-alert small { display: block; font-size: 9px; }.coverage-alert small { margin-top: 3px; color: var(--muted); }
.coverage-alert button { border: 0; background: transparent; color: var(--amber); font-size: 9px; font-weight: 700; cursor: pointer; }
.legend { display: flex; gap: 12px; color: var(--muted); font-size: 9px; }
.legend span { display: flex; align-items: center; gap: 5px; }.legend i { width: 8px; height: 8px; border-radius: 3px; }.present { background: var(--brand-600); }.absent { background: #df8f82; }
.chart-area { height: 235px; display: grid; grid-template-columns: 34px 1fr; padding: 25px 24px 15px; direction: ltr; }
.y-labels { height: 173px; display: flex; flex-direction: column; justify-content: space-between; color: #9ca7a4; font-size: 8px; text-align: left; }
.bar-grid { height: 190px; display: grid; grid-template-columns: repeat(5, 1fr); border-bottom: 1px solid #dce4e2; background: repeating-linear-gradient(to bottom, #edf1f0 0 1px, transparent 1px 34.6px); }
.day { display: grid; grid-template-rows: 173px 17px; place-items: end center; }
.bars { height: 173px; display: flex; align-items: end; justify-content: center; gap: 4px; }
.bars i, .bars b { width: 13px; height: var(--h); border-radius: 4px 4px 1px 1px; }
.bars i { background: linear-gradient(#5da59a, var(--brand-600)); }.bars b { background: #eaa498; }
.day span { padding-top: 8px; color: var(--muted); font-size: 8px; direction: rtl; }
.bottom-grid { grid-template-columns: 1.35fr .85fr; }
.text-button { border: 0; background: transparent; color: var(--brand-600); cursor: pointer; font-size: 10px; font-weight: 600; }
.activity-list { padding: 5px 20px 12px; }
.activity-row { display: flex; align-items: center; gap: 11px; padding: 10px 0; border-bottom: 1px solid #eff2f1; }
.activity-row:last-child { border: 0; }
.activity-icon { display: grid; place-items: center; width: 33px; height: 33px; border-radius: 9px; }.activity-icon svg { width: 15px; }.activity-icon.green { background: var(--green-bg); color: var(--green); }.activity-icon.blue { background: var(--blue-bg); color: var(--blue); }.activity-icon.amber { background: var(--amber-bg); color: var(--amber); }.activity-icon.purple { background: var(--purple-bg); color: var(--purple); }
.activity-row p { flex: 1; margin: 0; }.activity-row strong, .activity-row small { display: block; }.activity-row strong { font-size: 10px; }.activity-row small { margin-top: 4px; color: var(--muted); font-size: 9px; }.activity-row time { color: #95a09d; font-size: 8px; }
.quick-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 17px; }
.quick-grid button { min-height: 92px; padding: 13px; border: 1px solid var(--line); border-radius: 11px; background: #fff; text-align: right; cursor: pointer; transition: .18s; }.quick-grid button:hover { border-color: var(--brand-200); transform: translateY(-2px); box-shadow: var(--shadow); }
.quick-icon { width: 31px; height: 31px; margin-bottom: 9px; }.quick-icon svg { width: 15px; }.quick-grid strong, .quick-grid small { display: block; }.quick-grid strong { font-size: 10px; }.quick-grid small { margin-top: 3px; color: var(--muted); font-size: 8px; }

/* permissions */
.rule-banner { display: flex; align-items: center; gap: 13px; margin-bottom: 16px; padding: 14px 17px; border: 1px solid #cfe4df; border-radius: 13px; background: linear-gradient(90deg, #eef8f5, #f8fbfa); }
.rule-mark { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 11px; background: var(--brand-800); color: white; font-size: 17px; font-weight: 800; }
.rule-banner > div:nth-child(2) { flex: 1; }.rule-banner strong { font-size: 12px; }.rule-banner p { margin: 4px 0 0; color: #61706d; font-size: 10px; }.rule-banner p b { color: var(--brand-700); }
.rule-equation { display: flex; align-items: center; gap: 6px; direction: rtl; }.rule-equation span, .rule-equation em { padding: 6px 8px; border-radius: 7px; background: white; font-size: 9px; font-style: normal; }.rule-equation b { color: var(--brand-600); }.rule-equation em { background: var(--brand-800); color: white; }
.permissions-layout { display: grid; grid-template-columns: 285px minmax(0, 1fr); gap: 16px; align-items: start; }
.users-panel { position: sticky; top: 91px; overflow: hidden; }
.users-panel-head { display: flex; align-items: center; justify-content: space-between; padding: 17px; }.users-panel-head > div { display: flex; align-items: center; gap: 8px; }.users-panel-head h2 { margin: 0; font-size: 14px; }.users-panel-head span { padding: 3px 7px; border-radius: 6px; background: #edf3f1; color: var(--muted); font-size: 8px; }
.small-icon { width: 31px; height: 31px; border-radius: 8px; color: #6f7e7b; }.small-icon svg { width: 15px; }
.inline-search { min-height: 38px; display: flex; align-items: center; gap: 8px; margin: 0 15px; padding: 0 11px; border: 1px solid var(--line); border-radius: 8px; background: #f9fbfa; }.inline-search svg { width: 15px; color: #8f9b98; }.inline-search input { width: 100%; border: 0; outline: 0; background: transparent; font-size: 11px; }.inline-search.wide { width: min(390px, 100%); margin: 0; }
.role-tabs { display: flex; gap: 4px; margin: 12px 15px 7px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }.role-tabs button { flex: 1; min-height: 28px; border: 0; border-radius: 7px; background: transparent; color: var(--muted); font-size: 9px; cursor: pointer; }.role-tabs button.active { background: var(--brand-100); color: var(--brand-800); font-weight: 700; }
.user-list { max-height: 610px; overflow: auto; padding: 4px 8px 10px; }.user-list::-webkit-scrollbar { width: 4px; }.user-list::-webkit-scrollbar-thumb { border-radius: 6px; background: #d8e1df; }
.user-row { width: 100%; display: flex; align-items: center; gap: 9px; padding: 10px 9px; border: 0; border-radius: 10px; background: transparent; cursor: pointer; text-align: right; }.user-row:hover { background: #f6f9f8; }.user-row.active { background: var(--brand-100); }.user-row p { flex: 1; margin: 0; }.user-row strong, .user-row small { display: block; }.user-row strong { font-size: 10px; }.user-row small { margin-top: 3px; color: var(--muted); font-size: 8px; }.user-row .avatar { width: 34px; height: 34px; border-radius: 10px; }.user-row > span:last-child { width: 6px; height: 6px; border-radius: 50%; background: #5cac85; }.user-row.disabled > span:last-child { background: #aeb8b6; }
.permission-editor { display: grid; gap: 14px; }
.profile-panel { display: flex; align-items: center; justify-content: space-between; padding: 17px 19px; }.profile-main { display: flex; align-items: center; gap: 12px; }.avatar-large { width: 48px; height: 48px; border-radius: 13px; font-size: 14px; }.name-line { display: flex; align-items: center; gap: 9px; }.name-line h2 { margin: 0; font-size: 16px; }.profile-main p { margin: 4px 0; color: #5d6b68; font-size: 10px; direction: rtl; }.profile-main small { color: #929d9a; font-size: 9px; }.profile-actions { display: flex; gap: 6px; }
.status { display: inline-flex; align-items: center; gap: 4px; width: max-content; padding: 4px 8px; border-radius: 20px; font-size: 9px; font-weight: 600; }.status::before { content: ""; width: 5px; height: 5px; border-radius: 50%; }.status.active { background: var(--green-bg); color: var(--green); }.status.active::before { background: var(--green); }.status.private { background: var(--red-bg); color: var(--red); }.status.private::before { background: var(--red); }.status.warning { background: var(--amber-bg); color: var(--amber); }.status.warning::before { background: var(--amber); }
.scope-panel, .functional-panel { padding-bottom: 18px; }
.section-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; padding: 18px 20px 14px; }.section-head > div:first-child { display: flex; gap: 10px; }.section-number { display: grid; place-items: center; width: 25px; height: 25px; border-radius: 8px; background: var(--brand-100); color: var(--brand-700); font-weight: 800; font-size: 10px; }.section-head h2 { margin: 1px 0 0; font-size: 13px; }.section-head p { margin: 5px 0 0; color: var(--muted); font-size: 9px; }.selection-count { padding: 6px 10px; border-radius: 8px; background: #f1f5f4; color: var(--muted); font-size: 9px; }.selection-count b { color: var(--brand-700); font-size: 12px; }
.scope-tools { display: flex; align-items: center; gap: 8px; padding: 0 20px 12px; }.scope-tools .inline-search { flex: 1; margin: 0; }
.association-check-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding: 0 20px; }
.association-check { position: relative; display: flex; align-items: center; gap: 9px; min-height: 54px; padding: 9px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; }.association-check:hover { border-color: var(--brand-200); }.association-check.selected { border-color: #a9d2ca; background: #f2faf8; }.association-check.locked { cursor: not-allowed; opacity: .72; background: #fafafa; }.association-check input { position: absolute; opacity: 0; pointer-events: none; }.custom-check { display: grid; place-items: center; width: 18px; height: 18px; border: 1px solid #c9d4d1; border-radius: 5px; color: white; }.selected .custom-check { border-color: var(--brand-600); background: var(--brand-600); }.custom-check svg { width: 12px; opacity: 0; }.selected .custom-check svg { opacity: 1; }.association-check p { flex: 1; margin: 0; }.association-check strong, .association-check small { display: block; }.association-check strong { font-size: 9px; }.association-check small { margin-top: 3px; color: var(--muted); font-size: 7px; }.association-check > svg { width: 14px; color: var(--red); }
.permission-groups { display: grid; gap: 10px; padding: 0 20px; }.permission-group { overflow: hidden; border: 1px solid var(--line); border-radius: 11px; }.permission-group-head { display: flex; align-items: center; gap: 9px; padding: 10px 12px; background: #f8faf9; }.permission-group-head span { display: grid; place-items: center; width: 27px; height: 27px; border-radius: 8px; background: var(--brand-100); color: var(--brand-700); }.permission-group-head span svg { width: 14px; }.permission-group-head strong { font-size: 10px; }.permission-group-head small { margin-right: auto; color: var(--muted); font-size: 8px; }
.permission-items { display: grid; grid-template-columns: 1fr 1fr; }.permission-item { min-height: 54px; display: flex; align-items: center; gap: 9px; padding: 9px 12px; border-top: 1px solid #edf1f0; }.permission-item:nth-child(odd) { border-left: 1px solid #edf1f0; }.permission-item p { flex: 1; margin: 0; }.permission-item strong, .permission-item small { display: block; }.permission-item strong { font-size: 9px; }.permission-item small { margin-top: 3px; color: var(--muted); font-size: 7px; }.permission-item.locked { background: #fcfcfc; }.permission-item .lock-label { display: flex; align-items: center; gap: 4px; color: var(--red); font-size: 8px; }.permission-item .lock-label svg { width: 12px; }
.switch { position: relative; width: 34px; height: 19px; flex: 0 0 auto; }.switch input { opacity: 0; width: 0; height: 0; }.slider { position: absolute; inset: 0; border-radius: 20px; background: #cfd8d6; cursor: pointer; transition: .2s; }.slider::before { content: ""; position: absolute; width: 13px; height: 13px; top: 3px; right: 3px; border-radius: 50%; background: white; transition: .2s; box-shadow: 0 1px 3px rgba(0,0,0,.2); }.switch input:checked + .slider { background: var(--brand-600); }.switch input:checked + .slider::before { transform: translateX(-15px); }.switch input:disabled + .slider { cursor: not-allowed; opacity: .45; }
.save-bar { position: sticky; bottom: 12px; z-index: 10; display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 15px; border: 1px solid #c9deda; border-radius: 12px; background: rgba(255,255,255,.96); box-shadow: 0 12px 36px rgba(17,55,53,.15); backdrop-filter: blur(12px); }.save-bar > div { display: flex; align-items: center; gap: 9px; }.unsaved-dot { width: 8px; height: 8px; border-radius: 50%; background: #d58a4b; box-shadow: 0 0 0 4px #fbefe4; }.save-bar p { margin: 0; }.save-bar strong, .save-bar small { display: block; }.save-bar strong { font-size: 10px; }.save-bar small { margin-top: 3px; color: var(--muted); font-size: 8px; }

/* tables and secondary pages */
.summary-strip { display: grid; grid-template-columns: repeat(4, 1fr); margin-bottom: 16px; border: 1px solid var(--line); border-radius: var(--radius); background: white; }.summary-strip > div { display: flex; align-items: center; gap: 12px; padding: 16px 20px; border-left: 1px solid var(--line); }.summary-strip > div:last-child { border-left: 0; }.summary-icon { width: 38px; height: 38px; }.summary-icon svg { width: 18px; }.summary-strip p { margin: 0; }.summary-strip small, .summary-strip strong { display: block; }.summary-strip small { color: var(--muted); font-size: 9px; }.summary-strip strong { margin-top: 3px; font-size: 19px; }
.data-panel { overflow: hidden; }.table-toolbar { min-height: 68px; display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 13px 18px; border-bottom: 1px solid var(--line); }.table-toolbar > div { display: flex; gap: 7px; }
.table-wrap { overflow-x: auto; } table { width: 100%; border-collapse: collapse; white-space: nowrap; } th { padding: 11px 16px; background: #f8faf9; color: #7e8c89; font-size: 9px; font-weight: 600; text-align: right; } td { height: 62px; padding: 9px 16px; border-top: 1px solid #edf1f0; color: #4d5c59; font-size: 10px; } tbody tr:hover { background: #fbfcfc; }
.entity { display: flex; align-items: center; gap: 9px; }.entity-logo { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; font-weight: 800; }.e1 { background: var(--brand-100); color: var(--brand-700); }.e2 { background: var(--blue-bg); color: var(--blue); }.e3 { background: var(--red-bg); color: var(--red); }.e4 { background: var(--amber-bg); color: var(--amber); }.e5 { background: var(--purple-bg); color: var(--purple); }.entity p { margin: 0; }.entity strong, .entity small { display: block; }.entity strong { color: var(--ink); font-size: 10px; }.entity small { margin-top: 4px; color: var(--muted); font-size: 8px; }.avatar-stack { display: flex; direction: ltr; justify-content: flex-end; }.avatar-stack span { display: grid; place-items: center; width: 28px; height: 28px; margin-left: -7px; border: 2px solid white; border-radius: 9px; background: #dcece8; color: var(--brand-700); font-size: 7px; font-weight: 700; }.private-cell { display: flex; align-items: center; gap: 5px; color: var(--red); }.private-cell svg { width: 13px; }.muted { color: #99a4a2; }
.table-footer { min-height: 58px; display: flex; align-items: center; justify-content: space-between; padding: 11px 18px; border-top: 1px solid var(--line); color: var(--muted); font-size: 9px; }.pagination { display: flex; gap: 4px; direction: rtl; }.pagination button { min-width: 29px; height: 29px; padding: 0 8px; border: 1px solid var(--line); border-radius: 7px; background: white; color: #677572; cursor: pointer; font-size: 9px; }.pagination button.active { border-color: var(--brand-700); background: var(--brand-700); color: white; }.pagination button:disabled { opacity: .45; }
.admin-only-note, .scope-proof { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; padding: 13px 16px; border: 1px solid #efd3ce; border-radius: 12px; background: #fff7f6; color: var(--red); }.admin-only-note > svg { width: 22px; }.admin-only-note p, .scope-proof p { margin: 0; }.admin-only-note strong, .admin-only-note span { display: block; }.admin-only-note strong { font-size: 10px; }.admin-only-note span { margin-top: 3px; color: #7b6966; font-size: 9px; }
.filter-card { margin-bottom: 14px; padding: 16px; }.filter-card > div { display: grid; grid-template-columns: 1fr 1.35fr 1fr auto; gap: 10px; align-items: end; }.filter-card label, .form-grid label, .full-label { display: grid; gap: 6px; color: #677572; font-size: 9px; font-weight: 600; }.filter-card input, .filter-card select, .form-grid input, .form-grid select, .full-label textarea { width: 100%; height: 39px; padding: 0 10px; border: 1px solid var(--line); border-radius: 8px; outline: 0; background: #fff; color: var(--ink); font-size: 10px; }.filter-card input:focus, .filter-card select:focus, .form-grid input:focus, .form-grid select:focus, .full-label textarea:focus { border-color: var(--brand-600); box-shadow: 0 0 0 3px var(--brand-100); }
.attendance-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 14px; }.attendance-cards > div { position: relative; padding: 14px 17px; border: 1px solid var(--line); border-radius: 12px; background: white; }.attendance-cards span { display: block; color: var(--muted); font-size: 9px; }.attendance-cards strong { display: inline-block; margin-top: 6px; font-size: 19px; }.attendance-cards small { position: absolute; left: 15px; bottom: 16px; color: var(--muted); font-size: 8px; }.green-text { color: var(--green); }.amber-text { color: var(--amber); }.red-text { color: var(--red); }
.scope-proof { border-color: #cde4df; background: #f0f8f6; color: var(--ink); }.scope-proof-icon { display: grid; place-items: center; width: 39px; height: 39px; border-radius: 11px; background: var(--brand-100); color: var(--brand-700); }.scope-proof > div:nth-child(2) { flex: 1; }.scope-proof strong { font-size: 11px; }.scope-proof p { margin-top: 4px; color: var(--muted); font-size: 9px; }.scope-proof p b { color: var(--brand-700); }
.report-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 16px; }.report-card { min-height: 206px; display: flex; flex-direction: column; align-items: flex-start; padding: 19px; border: 1px solid var(--line); border-radius: var(--radius); background: white; }.report-icon { width: 42px; height: 42px; margin-bottom: 20px; }.report-icon svg { width: 20px; }.report-card h3 { margin: 0; font-size: 13px; }.report-card p { min-height: 35px; margin: 7px 0 15px; color: var(--muted); font-size: 9px; line-height: 1.8; white-space: normal; }.report-card .btn { width: 100%; margin-top: auto; }.report-card .btn svg { margin-right: auto; transform: rotate(180deg); }.recent-reports { overflow: hidden; }.file-name { display: flex; align-items: center; gap: 8px; }.file-name span { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 7px; background: var(--green-bg); color: var(--green); font-size: 8px; font-weight: 800; }
.audit-card { overflow: hidden; }.audit-filters { display: flex; gap: 8px; padding: 14px 17px; border-bottom: 1px solid var(--line); }.audit-filters .inline-search { flex: 1; }.audit-list { padding: 6px 20px 18px; }.audit-entry { display: grid; grid-template-columns: 39px 1fr auto; gap: 12px; padding: 15px 0; border-bottom: 1px solid #edf1f0; }.audit-entry:last-child { border: 0; }.audit-entry .activity-icon { width: 38px; height: 38px; }.audit-entry h3 { margin: 1px 0 5px; font-size: 10px; }.audit-entry p { margin: 0; color: var(--muted); font-size: 9px; }.audit-entry p b { color: var(--ink); }.audit-entry .change { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; padding: 5px 8px; border-radius: 7px; background: #f5f7f7; font-size: 8px; }.audit-entry .change del { color: var(--red); }.audit-entry .change ins { color: var(--green); text-decoration: none; }.audit-entry time { color: #909b98; font-size: 8px; text-align: left; }
.settings-layout { display: grid; grid-template-columns: 230px 1fr; gap: 14px; align-items: start; }.settings-nav { display: grid; padding: 8px; }.settings-nav button { min-height: 41px; padding: 0 11px; border: 0; border-radius: 8px; background: transparent; color: var(--muted); cursor: pointer; text-align: right; font-size: 10px; }.settings-nav button.active { background: var(--brand-100); color: var(--brand-800); font-weight: 700; }.settings-form { padding: 5px 21px 24px; }.section-head.plain { padding-right: 0; padding-left: 0; border-bottom: 1px solid var(--line); }.section-head.plain > div:first-child { display: block; }.logo-upload { display: flex; align-items: center; gap: 14px; padding: 20px 0; }.brand-mark.large { width: 64px; height: 64px; }.logo-upload strong { font-size: 11px; }.logo-upload p { margin: 4px 0 9px; color: var(--muted); font-size: 8px; }.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; }.full-label { margin-top: 15px; }.full-label textarea { height: 90px; padding-top: 10px; resize: vertical; }

/* modal and feedback */
.modal-backdrop { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 20px; background: rgba(5,30,29,.55); backdrop-filter: blur(4px); }.modal-backdrop[hidden] { display: none; }.modal { width: min(600px, 100%); overflow: hidden; border-radius: 17px; background: white; box-shadow: 0 30px 80px rgba(5,30,29,.3); animation: modalIn .2s ease; }@keyframes modalIn { from { opacity: 0; transform: scale(.97) translateY(6px); } }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 20px 22px 16px; border-bottom: 1px solid var(--line); }.modal-head h2 { margin: 0; font-size: 17px; }.modal-body { padding: 21px 22px; }.modal-note { display: flex; align-items: center; gap: 10px; margin-top: 17px; padding: 11px; border-radius: 10px; background: #f1f8f6; color: var(--brand-700); }.modal-note svg { width: 18px; }.modal-note p { margin: 0; }.modal-note strong, .modal-note span { display: block; }.modal-note strong { font-size: 10px; }.modal-note span { margin-top: 3px; color: var(--muted); font-size: 8px; }.modal-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 14px 22px; border-top: 1px solid var(--line); background: #fafbfb; }
.toast { position: fixed; z-index: 120; left: 28px; bottom: 28px; min-width: 310px; display: flex; align-items: center; gap: 10px; padding: 13px 15px; border: 1px solid #cce1dc; border-radius: 12px; background: white; box-shadow: 0 16px 45px rgba(15,55,52,.18); opacity: 0; transform: translateY(15px); pointer-events: none; transition: .25s; }.toast.show { opacity: 1; transform: none; }.toast > span { display: grid; place-items: center; width: 31px; height: 31px; border-radius: 9px; background: var(--green-bg); color: var(--green); }.toast > span svg { width: 16px; }.toast strong, .toast small { display: block; }.toast strong { font-size: 10px; }.toast small { margin-top: 3px; color: var(--muted); font-size: 8px; }
.sidebar-overlay { display: none; }

@media (max-width: 1180px) {
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .dashboard-grid, .bottom-grid { grid-template-columns: 1fr; }
  .permissions-layout { grid-template-columns: 250px minmax(0, 1fr); }
  .association-check-grid { grid-template-columns: 1fr 1fr; }
  .report-grid { grid-template-columns: 1fr 1fr; }
  .rule-equation { display: none; }
}
@media (max-width: 880px) {
  .sidebar { transform: translateX(100%); transition: .25s ease; box-shadow: -15px 0 50px rgba(0,0,0,.25); }.sidebar.open { transform: none; }.sidebar-overlay { position: fixed; inset: 0; z-index: 35; background: rgba(6,26,25,.4); }.sidebar-overlay.show { display: block; }
  .main-area { width: 100%; margin-right: 0; }.menu-button { display: grid; }.topbar { padding: 0 18px; }.content { padding: 22px 18px 40px; }.top-search { flex: 1; width: auto; }.top-search kbd { display: none; }
  .permissions-layout { grid-template-columns: 1fr; }.users-panel { position: static; }.user-list { max-height: 250px; }.summary-strip { grid-template-columns: 1fr 1fr; }.summary-strip > div:nth-child(2) { border-left: 0; }.summary-strip > div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }.filter-card > div { grid-template-columns: 1fr 1fr; }.settings-layout { grid-template-columns: 1fr; }.settings-nav { display: flex; overflow-x: auto; }.settings-nav button { min-width: 130px; }
}
@media (max-width: 620px) {
  .topbar { gap: 8px; }.top-search { display: none; }.top-actions { margin-right: auto; }.user-menu > div:nth-child(2), .user-menu > svg { display: none; }.page-head { align-items: flex-start !important; flex-direction: column; }.head-actions { width: 100%; }.head-actions .btn { flex: 1; }.stats-grid, .summary-strip, .attendance-cards, .report-grid { grid-template-columns: 1fr; }.summary-strip > div { border-left: 0; border-bottom: 1px solid var(--line); }.summary-strip > div:last-child { border-bottom: 0; }.coverage-wrap { grid-template-columns: 1fr; justify-items: center; }.coverage-list { width: 100%; }.chart-area { padding-right: 10px; padding-left: 10px; }.quick-grid { grid-template-columns: 1fr; }.rule-banner { align-items: flex-start; }.permissions-layout { display: block; }.permission-editor { margin-top: 14px; }.profile-panel { align-items: flex-start; flex-direction: column; gap: 13px; }.association-check-grid, .permission-items, .form-grid { grid-template-columns: 1fr; }.permission-item:nth-child(odd) { border-left: 0; }.save-bar { align-items: stretch; flex-direction: column; }.save-bar > div:last-child .btn { flex: 1; }.table-toolbar, .audit-filters { align-items: stretch; flex-direction: column; }.table-toolbar .inline-search, .audit-filters .inline-search { width: 100%; }.filter-card > div { grid-template-columns: 1fr; }.scope-proof { align-items: flex-start; flex-wrap: wrap; }.audit-entry { grid-template-columns: 36px 1fr; }.audit-entry time { grid-column: 2; text-align: right; }.toast { right: 14px; left: 14px; bottom: 14px; min-width: 0; }
}
