/* =====================================================================
   VERTEX PROJECT MANAGEMENT — STYLESHEET
   Ported 1:1 from the original vertex-task(3).html prototype so the
   visual design (navy/teal palette, cards, buttons, forms) is preserved
   exactly. This file currently covers the design tokens + Login page;
   Phase 3 appends the app shell (sidebar/header), dashboard, and all
   remaining page/component styles to this same file.
   ===================================================================== */

/* ===== VERTEX DESIGN TOKENS ===== */
:root {
  --navy:       #1B2A6B;
  --navy-dark:  #111C4E;
  --navy-light: #2A3F8F;
  --teal:       #00B5C8;
  --teal-dark:  #0090A0;
  --teal-light: #33C8D8;
  --white:      #FFFFFF;
  --off-white:  #F4F6FB;
  --gray-100:   #EEF0F6;
  --gray-200:   #DDE1EE;
  --gray-400:   #9BA4C2;
  --gray-600:   #5C6588;
  --gray-800:   #2E3557;
  --text:       #1A2040;
  --danger:     #E03B3B;
  --warning:    #F59E0B;
  --success:    #10B981;
  --purple:     #7C3AED;

  --sidebar-w:  233.28px;
  --header-h:   58.32px;
  --radius:     7.56px;
  --radius-lg:  11.88px;
  --shadow-sm:  0 1px 4.32px rgba(27,42,107,.10);
  --shadow-md:  0 4.32px 17.28px rgba(27,42,107,.14);
  --shadow-lg:  0 8.64px 34.56px rgba(27,42,107,.18);

  --font:       'Segoe UI', system-ui, -apple-system, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: var(--font);
  background: var(--off-white);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
}

/* ===== LOGIN PAGE ===== */
#login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--navy-dark) 0%, var(--navy) 50%, var(--navy-light) 100%);
  position: relative;
  overflow: hidden;
}
#login-page::before {
  content: '';
  position: absolute;
  width: 583.2px; height: 583.2px;
  background: radial-gradient(circle, rgba(0,181,200,.18) 0%, transparent 70%);
  top: -120px; right: -120px;
  border-radius: 50%;
}
#login-page::after {
  content: '';
  position: absolute;
  width: 388.8px; height: 388.8px;
  background: radial-gradient(circle, rgba(0,181,200,.10) 0%, transparent 70%);
  bottom: -96px; left: -96px;
  border-radius: 50%;
}
.login-card {
  background: rgba(255,255,255,.97);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 46.68px 42.72px;
  width: 408.24px;
  max-width: 95vw;
  position: relative;
  z-index: 1;
  animation: slideUp .4s ease;
}
@keyframes slideUp { from { opacity:0; transform:translateY(25.92px); } to { opacity:1; transform:translateY(0); } }
.login-logo { text-align: center; margin-bottom: 27.24px; }
.login-logo img { height: 77.76px; object-fit: contain; }
.login-tagline { text-align: center; font-size: 0.78rem; color: var(--gray-600); letter-spacing: .08em; text-transform: uppercase; margin-bottom: 5.88px; }
.login-divider {
  border: none;
  border-top: 1px solid var(--gray-200);
  margin: 0 0 27.24px;
}
.login-title { font-size: 1.07rem; font-weight: 600; color: var(--navy); text-align: center; margin-bottom: 23.28px; letter-spacing:.02em; }
.form-group { margin-bottom: 17.52px; }
.form-group label { display: block; font-size: 0.8rem; font-weight: 600; color: var(--gray-600); margin-bottom: 5.88px; text-transform: uppercase; letter-spacing: .06em; }
.form-group input, .form-group select, .form-group textarea {
  width: 100%; padding: 10.68px 13.56px;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius);
  font-size: 0.92rem; color: var(--text);
  background: var(--white);
  transition: border-color .2s, box-shadow .2s;
  font-family: var(--font);
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3.24px rgba(0,181,200,.15);
}
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7.8px;
  padding: 10.68px 21.36px;
  border: none; border-radius: var(--radius);
  font-size: 0.89rem; font-weight: 600; cursor: pointer;
  transition: all .2s; font-family: var(--font);
  text-decoration: none;
}
.btn:disabled { opacity: .6; cursor: not-allowed; }
.btn-primary {
  background: linear-gradient(135deg, var(--teal) 0%, var(--teal-dark) 100%);
  color: var(--white);
  box-shadow: 0 2px 8.64px rgba(0,181,200,.3);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 4.32px 17.28px rgba(0,181,200,.4); }
.btn-navy {
  background: var(--navy);
  color: var(--white);
}
.btn-navy:hover { background: var(--navy-dark); }
.btn-ghost {
  background: transparent; color: var(--navy);
  border: 1.5px solid var(--gray-200);
}
.btn-ghost:hover { background: var(--gray-100); }
.btn-danger { background: var(--danger); color: var(--white); }
.btn-sm { padding: 6.84px 13.56px; font-size: 0.81rem; }
.btn-full { width: 100%; }
.mt-16 { margin-top: 15.6px; }
.login-footer { text-align: center; margin-top: 19.44px; font-size: 0.8rem; color: var(--gray-400); }
.error-msg { color: var(--danger); font-size: 0.8rem; margin-top: 3.84px; min-height: 1.1em; }

/* =====================================================================
   PHASE 3 — MAIN APP SHELL (sidebar, header, dashboard, responsive)
   ===================================================================== */

/* SIDEBAR */
.sidebar {
  position: fixed; top: 0; left: 0; bottom: 0;
  width: var(--sidebar-w);
  background: var(--navy);
  display: flex; flex-direction: column;
  z-index: 100;
  transition: transform .3s ease;
}
.sidebar-logo {
  padding: 13.56px 17.52px;
  border-bottom: 1px solid rgba(255,255,255,.1);
  display: flex; align-items: center; gap: 9.72px;
}
.sidebar-logo img {
  height: 38.88px; object-fit: contain;
  background: var(--white); border-radius: 5.88px; padding: 3.84px 7.8px;
}
.sidebar-logo-text { color: var(--white); font-size: 0.73rem; font-weight: 600; line-height: 1.3; opacity: .85; }
.sidebar-user {
  padding: 13.56px 17.52px;
  border-bottom: 1px solid rgba(255,255,255,.1);
  display: flex; align-items: center; gap: 9.72px;
}
.avatar {
  width: 33px; height: 33px; border-radius: 50%;
  background: var(--teal); color: var(--white);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 0.83rem; flex-shrink: 0;
}
.avatar-lg { width: 42.72px; height: 42.72px; font-size: 1.07rem; }
.sidebar-user-info { flex: 1; min-width: 0; }
.sidebar-user-name { color: var(--white); font-size: 0.86rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sidebar-user-role { color: var(--teal-light); font-size: 0.73rem; text-transform: uppercase; letter-spacing: .06em; }
.sidebar-nav { flex: 1; overflow-y: auto; padding: 9.72px 0; }
.nav-section-label {
  padding: 9.72px 17.52px 3.84px;
  font-size: 0.73rem; font-weight: 700; color: rgba(255,255,255,.35);
  text-transform: uppercase; letter-spacing: .1em;
}
.nav-item {
  display: flex; align-items: center; gap: 9.72px;
  padding: 9.72px 17.52px;
  color: rgba(255,255,255,.75);
  cursor: pointer;
  transition: all .15s;
  font-size: 0.86rem;
  border-left: 3.24px solid transparent;
  user-select: none;
  text-decoration: none;
}
.nav-item:hover { background: rgba(255,255,255,.07); color: var(--white); }
.nav-item.active { background: rgba(0,181,200,.15); color: var(--teal-light); border-left-color: var(--teal); }
.nav-icon { font-size: 0.97rem; width: 19.44px; text-align: center; }
.sidebar-footer {
  padding: 13.56px 17.52px;
  border-top: 1px solid rgba(255,255,255,.1);
}
.sidebar-footer .nav-item { padding: 7.8px 0; border-left: none; }

/* MOBILE OVERLAY */
.sidebar-overlay {
  display: none;
  position: fixed; inset: 0;
  background: rgba(0,0,0,.5);
  z-index: 99;
}

/* HEADER */
.header {
  position: fixed; top: 0;
  left: var(--sidebar-w); right: 0;
  height: var(--header-h);
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  display: flex; align-items: center;
  padding: 0 23.28px;
  gap: 15.6px;
  z-index: 50;
  box-shadow: var(--shadow-sm);
}
.header-menu-btn { display: none; background: none; border: none; font-size: 1.26rem; cursor: pointer; color: var(--navy); }
.header-title { font-size: 1.07rem; font-weight: 700; color: var(--navy); flex: 1; }
.header-actions { display: flex; align-items: center; gap: 9.72px; }
.header-search {
  display: flex; align-items: center; gap: 7.8px;
  background: var(--gray-100); border-radius: 19.44px;
  padding: 6.84px 13.56px; min-width: 213.84px;
}
.header-search input { background: none; border: none; outline: none; font-size: 0.86rem; color: var(--text); width: 100%; }
.header-search-results {
  position: absolute; top: calc(100% + 8.64px); left: 0; right: 0;
  background: var(--white); border: 1px solid var(--gray-200); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg); max-height: 349.92px; overflow-y: auto; z-index: 400; display: none;
}
.header-search-results.open { display: block; }
.hsr-item { display: block; padding: 9.72px 13.56px; text-decoration: none; color: var(--text); border-bottom: 1px solid var(--gray-100); }
.hsr-item:last-child { border-bottom: none; }
.hsr-item:hover { background: var(--gray-100); }
.hsr-item-type { font-size: 0.73rem; text-transform: uppercase; letter-spacing: .06em; color: var(--gray-400); font-weight: 700; }
.hsr-item-title { font-size: 0.83rem; font-weight: 600; color: var(--navy); }
.hsr-empty { padding: 15.6px; text-align: center; color: var(--gray-400); font-size: 0.8rem; }
.badge {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 2px 7.8px; border-radius: 19.44px;
  font-size: 0.73rem; font-weight: 700;
}
.badge-teal { background: rgba(0,181,200,.15); color: var(--teal-dark); }
.badge-navy { background: rgba(27,42,107,.1); color: var(--navy); }
.badge-success { background: rgba(16,185,129,.12); color: #0D9668; }
.badge-warning { background: rgba(245,158,11,.12); color: #D97706; }
.badge-danger { background: rgba(224,59,59,.1); color: var(--danger); }
.badge-purple { background: rgba(124,58,237,.1); color: var(--purple); }
.role-admin { background: rgba(124,58,237,.1); color: var(--purple); }
.role-manager { background: rgba(27,42,107,.1); color: var(--navy); }
.role-member { background: rgba(0,181,200,.12); color: var(--teal-dark); }
.role-viewer { background: var(--gray-100); color: var(--gray-600); }
.notif-btn { position: relative; background: none; border: none; font-size: 1.17rem; cursor: pointer; color: var(--gray-600); padding: 5.88px; border-radius: var(--radius); }
.notif-btn:hover { background: var(--gray-100); }
.notif-badge {
  position: absolute; top: -2px; right: -2px;
  min-width: 15.6px; height: 15.6px; padding: 0 3.84px;
  background: var(--danger); color: var(--white);
  border-radius: 9.72px; font-size: 0.73rem; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
  line-height: 1; border: 2px solid var(--white);
}
.notif-badge.hidden { display: none; }

/* MAIN CONTENT */
.main-content {
  margin-left: var(--sidebar-w);
  margin-top: var(--header-h);
  padding: 23.28px;
  min-height: calc(100vh - var(--header-h));
}
.page-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 21.36px; flex-wrap: wrap; gap: 11.64px; }
.page-title { font-size: 1.36rem; font-weight: 800; color: var(--navy); }
.page-subtitle { font-size: 0.83rem; color: var(--gray-400); margin-top: 2px; }
.action-bar { display: flex; align-items: center; gap: 9.72px; flex-wrap: wrap; }
.empty-state { text-align: center; padding: 46.68px 23.28px; color: var(--gray-400); }
.empty-state-icon { font-size: 2.43rem; margin-bottom: 11.64px; }
.empty-state-title { font-size: 0.97rem; font-weight: 700; color: var(--gray-600); margin-bottom: 5.88px; }
.accent-line { width: 35.04px; height: 2.88px; background: var(--teal); border-radius: 2px; margin: 5.88px 0 13.56px; }

/* CARDS */
.card {
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--gray-100);
}
.card-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 17.52px 21.36px;
  border-bottom: 1px solid var(--gray-100);
}
.card-title { font-size: 0.97rem; font-weight: 700; color: var(--navy); }
.card-body { padding: 21.36px; }

/* STATS GRID */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(216px,1fr)); gap: 15.6px; margin-bottom: 23.28px; }
.stat-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--gray-100);
  box-shadow: var(--shadow-sm);
  padding: 17.52px 19.44px;
  display: flex; align-items: center; gap: 13.56px;
  text-decoration: none;
  color: inherit;
}
.stat-card.clickable { cursor: pointer; transition: box-shadow .18s ease, transform .18s ease, border-color .18s ease; }
.stat-card.clickable:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); border-color: var(--teal); }
.stat-card.clickable:active { transform: translateY(0); }
.stat-card-body { flex: 1; min-width: 0; }
.stat-card-arrow { color: var(--gray-200); font-size: 1.07rem; font-weight: 700; flex-shrink: 0; transition: color .18s ease, transform .18s ease; }
.stat-card.clickable:hover .stat-card-arrow { color: var(--teal); transform: translateX(2px); }
.stat-icon {
  width: 42.72px; height: 42.72px; border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.26rem; flex-shrink: 0;
}
.stat-icon-teal { background: rgba(0,181,200,.12); }
.stat-icon-navy { background: rgba(27,42,107,.1); }
.stat-icon-success { background: rgba(16,185,129,.12); }
.stat-icon-warning { background: rgba(245,158,11,.12); }
.stat-icon-purple { background: rgba(124,58,237,.1); }
.stat-value { font-size: 1.75rem; font-weight: 800; color: var(--navy); line-height: 1; }
.stat-label { font-size: 0.76rem; color: var(--gray-400); text-transform: uppercase; letter-spacing: .06em; margin-top: 2px; }

/* TABLES */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 0.86rem; }
thead tr { background: var(--gray-100); }
th { padding: 10.68px 13.56px; text-align: left; font-size: 0.73rem; font-weight: 700; color: var(--gray-600); text-transform: uppercase; letter-spacing: .07em; white-space: nowrap; }
th.sortable { cursor: pointer; user-select: none; }
th.sortable:hover { color: var(--navy); }
th.sortable.sort-active { color: var(--teal-dark); }
.sort-indicator { display: inline-block; width: .8em; font-size: .95em; }
.section-heading { font-size: 0.92rem; font-weight: 700; color: var(--navy); text-transform: uppercase; letter-spacing: .05em; margin: 4.32px 0 10.8px; }
td { padding: 11.64px 13.56px; border-bottom: 1px solid var(--gray-100); color: var(--text); vertical-align: middle; }
#team-perf-table .team-group-row { background: var(--gray-50, #f4f5f9); cursor: pointer; }
#team-perf-table .team-group-row:hover { background: var(--gray-100, #eceef4); }
#team-perf-table .team-group-caret { display: inline-block; width: 1em; color: var(--gray-400); }
#team-perf-table .team-project-row td:nth-child(3) { padding-left: 30.24px; }
.team-you-badge { display: inline-block; margin-left: 6.48px; padding: 1px 7.56px; border-radius: 10.8px; font-size: 0.7rem; font-weight: 700; background: var(--teal); color: #fff; vertical-align: middle; }
#team-perf-table td:nth-child(3) { max-width: 172.8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
tr:hover td { background: rgba(0,181,200,.03); }

/* STATUS PILLS / PRIORITY DOTS */
.status-pill {
  display: inline-flex; align-items: center; gap: 4.8px;
  padding: 2.88px 9.72px; border-radius: 19.44px;
  font-size: 0.73rem; font-weight: 700;
  white-space: nowrap;
}
.status-todo { background: var(--gray-100); color: var(--gray-600); }
.status-assigned { background: rgba(27,42,107,.1); color: var(--navy); }
.status-accept { background: rgba(0,181,200,.1); color: var(--teal-dark); }
.status-in-progress { background: rgba(0,181,200,.15); color: var(--teal-dark); }
.status-review { background: rgba(245,158,11,.15); color: #B45309; }
.status-done { background: rgba(16,185,129,.12); color: #047857; }
.status-blocked { background: rgba(224,59,59,.12); color: var(--danger); }
.priority-dot { width: 7.8px; height: 7.8px; border-radius: 50%; flex-shrink: 0; display: inline-block; }
.priority-high { background: var(--danger); }
.priority-medium { background: var(--warning); }
.priority-low { background: var(--success); }

/* DASHBOARD LAYOUT */
.dash-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 19.44px; }
.dash-col-2 { grid-column: span 2; }
@media (max-width: 810px) { .dash-grid { grid-template-columns: 1fr 1fr; } .dash-col-2 { grid-column: span 1; } }
@media (max-width: 540px) { .dash-grid { grid-template-columns: 1fr; } }

/* ACTIVITY CHART */
.chart-type-selector { display: flex; gap: 3.84px; }
.chart-type-btn {
  width: 29.16px; height: 29.16px; border-radius: var(--radius);
  border: 1px solid var(--gray-200); background: var(--white);
  color: var(--gray-400); font-size: 0.92rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .15s, color .15s, border-color .15s;
}
.chart-type-btn:hover { background: var(--gray-100); color: var(--navy); }
.chart-type-btn.active { background: var(--teal); border-color: var(--teal); color: var(--white); }
.activity-svg { width: 100%; height: auto; display: block; max-height: 233.28px; }
.activity-svg-pie { max-width: 252.72px; margin: 0 auto; }
.chart-legend { display: flex; flex-wrap: wrap; gap: 9.72px 15.6px; margin-top: 9.72px; justify-content: center; }
.chart-legend-item { display: inline-flex; align-items: center; gap: 5.88px; font-size: 0.73rem; color: var(--gray-600); }
.chart-legend-dot { width: 8.76px; height: 8.76px; border-radius: 50%; flex-shrink: 0; }
.chart-empty-state { text-align: center; color: var(--gray-400); font-size: 0.83rem; padding: 38.88px 9.72px; }
@media (max-width: 576px) { .activity-svg { max-height: 162px; } }

/* MOBILE BOTTOM NAV */
.mobile-nav {
  display: none;
  position: fixed; bottom: 0; left: 0; right: 0;
  background: var(--white);
  border-top: 1px solid var(--gray-200);
  padding: 5.88px 0 env(safe-area-inset-bottom);
  z-index: 90;
  justify-content: space-around;
}
.mobile-nav-item {
  display: flex; flex-direction: column; align-items: center;
  padding: 5.88px 11.64px; font-size: 0.73rem; color: var(--gray-400);
  cursor: pointer; gap: 2px; text-decoration: none;
}
.mobile-nav-item .mn-icon { font-size: 1.17rem; }
.mobile-nav-item.active { color: var(--teal-dark); }

/* UTILITIES */
.flex { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.gap-8 { gap: 7.8px; }
.gap-12 { gap: 11.64px; }
.mt-8 { margin-top: 7.8px; }
.mt-24 { margin-top: 23.28px; }
.mb-16 { margin-bottom: 15.6px; }
.mb-24 { margin-bottom: 23.28px; }
.text-sm { font-size: 0.8rem; }
.text-muted { color: var(--gray-400); }
.text-navy { color: var(--navy); }
.fw-700 { font-weight: 700; }
.truncate { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.divider { border: none; border-top: 1px solid var(--gray-200); margin: 19.44px 0; }
.hidden { display: none !important; }

/* TOAST */
#toast { position: fixed; bottom: 97.2px; right: 25.92px; z-index: 999; display: none; }
.toast-box { background: var(--navy); color: var(--white); padding: 11.64px 17.52px; border-radius: var(--radius); box-shadow: var(--shadow-lg); display: flex; align-items: center; gap: 9.72px; font-size: 0.83rem; font-weight: 600; }

/* =====================================================================
   PHASE 4 — MODALS, FORMS, PROGRESS BARS (Projects module)
   ===================================================================== */
.modal-overlay {
  display: none; position: fixed; inset: 0;
  background: rgba(17,28,78,.45); backdrop-filter: blur(2px);
  z-index: 200; align-items: center; justify-content: center;
  padding: 19.44px;
}
.modal-overlay.open { display: flex; }
.modal {
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  width: 100%; max-width: 544.32px;
  max-height: 90vh; overflow-y: auto;
  animation: slideUp .25s ease;
}
.modal-lg { max-width: 758.16px; }
.modal-header { padding: 19.44px 23.28px; border-bottom: 1px solid var(--gray-200); display: flex; align-items: center; justify-content: space-between; }
.modal-title { font-size: 1.02rem; font-weight: 700; color: var(--navy); }
.modal-close { background: none; border: none; font-size: 1.26rem; cursor: pointer; color: var(--gray-400); padding: 3.84px; border-radius: 3.84px; }
.modal-close:hover { color: var(--navy); background: var(--gray-100); }
.modal-body { padding: 23.28px; }
.modal-footer { padding: 15.6px 23.28px; border-top: 1px solid var(--gray-200); display: flex; justify-content: flex-end; gap: 9.72px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 15.6px; }
@media (max-width: 450px) { .form-row { grid-template-columns: 1fr; } }
.form-error { color: var(--danger); font-size: 0.78rem; margin-top: 9.72px; min-height: 1.1em; }

.progress-bar { height: 5.88px; background: var(--gray-200); border-radius: 2.88px; overflow: hidden; }
.progress-fill { height: 100%; border-radius: 2.88px; background: linear-gradient(90deg, var(--teal) 0%, var(--navy-light) 100%); transition: width .3s; }

.project-card { cursor: default; }
.project-card-body { padding: 17.52px 19.44px 11.64px; }
.project-card-footer { padding: 9.72px 19.44px; border-top: 1px solid var(--gray-200); display: flex; justify-content: flex-end; align-items: center; gap: 5.88px; }
.project-filter-select {
  padding: 8.76px 13.56px; border: 1.5px solid var(--gray-200); border-radius: var(--radius);
  font-size: 0.83rem; color: var(--text); background: var(--white); font-family: var(--font);
}

/* Notification dropdown panel (header bell) */
.notification-panel {
  display: none;
  position: absolute; top: calc(100% + 10.8px); right: 0;
  width: 330.48px; max-width: 90vw;
  background: var(--white); border: 1px solid var(--gray-200); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg); z-index: 300;
  max-height: 408.24px; overflow: hidden; flex-direction: column;
}
.notification-panel.open { display: flex; }
.notif-panel-header { padding: 13.56px 17.52px; border-bottom: 1px solid var(--gray-100); display: flex; align-items: center; justify-content: space-between; }
.notif-panel-title { font-weight: 700; color: var(--navy); font-size: 0.89rem; }
.notif-panel-list { overflow-y: auto; flex: 1; }
.notif-item { display: flex; gap: 9.72px; padding: 11.64px 17.52px; border-bottom: 1px solid var(--gray-100); }
.notif-item.unread { background: rgba(0,181,200,.04); }
.notif-item-icon { font-size: 1.07rem; flex-shrink: 0; }
.notif-item-body { flex: 1; min-width: 0; }
.notif-item-title { font-size: 0.82rem; font-weight: 700; color: var(--navy); display: flex; align-items: center; gap: 5.88px; }
.notif-unread-dot { width: 5.88px; height: 5.88px; border-radius: 50%; background: var(--teal); display: inline-block; }
.notif-item-msg { font-size: 0.76rem; color: var(--gray-600); margin-top: 2px; }
.notif-item-meta { font-size: 0.73rem; color: var(--gray-400); margin-top: 3.84px; }
.notif-empty { text-align: center; padding: 35.04px 19.44px; color: var(--gray-400); }
.notif-empty-icon { font-size: 1.75rem; margin-bottom: 7.8px; }
.notif-empty-title { font-size: 0.83rem; font-weight: 600; color: var(--gray-600); }
.notif-panel-footer { padding: 9.72px 17.52px; border-top: 1px solid var(--gray-100); text-align: center; }
.notif-panel-footer a { font-size: 0.78rem; color: var(--teal-dark); font-weight: 600; text-decoration: none; }
.notif-panel-footer a:hover { text-decoration: underline; }
@media (max-width: 691.2px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .sidebar-overlay { display: block; opacity: 0; pointer-events: none; transition: opacity .3s; }
  .sidebar-overlay.open { opacity: 1; pointer-events: all; }
  .header { left: 0; }
  .header-menu-btn { display: flex; }
  .header-search { display: none; }
  .main-content { margin-left: 0; padding: 15.6px; padding-bottom: 68.04px; }
  .stats-grid { grid-template-columns: repeat(2,1fr); }
  .mobile-nav { display: flex; }
}
@media (max-width: 432px) {
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .stat-value { font-size: 1.36rem; }
  .login-card { padding: 31.08px 21.36px; }
}

/* ===== Simple authenticated placeholder (used until Phase 3 builds the
   full app shell / dashboard) ===== */
.placeholder-shell {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--off-white);
}
.placeholder-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: 38.88px 35.04px;
  width: 466.56px;
  max-width: 92vw;
  text-align: center;
}
.placeholder-card h1 { color: var(--navy); font-size: 1.26rem; margin-bottom: 7.8px; }
.placeholder-card p { color: var(--gray-600); font-size: 0.89rem; margin-bottom: 19.44px; line-height: 1.5; }
.placeholder-avatar {
  width: 54.48px; height: 54.48px; border-radius: 50%;
  background: var(--navy); color: var(--white);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 1.07rem; margin: 0 auto 15.6px;
}

/* =====================================================================
   PHASE 5 — TASKS: multi-select assignee picker, workflow stepper,
   status/priority chips, task detail modal, reason modal
   ===================================================================== */
.chip {
  display: inline-flex; align-items: center; gap: 3.84px;
  padding: 2.88px 9.72px; border-radius: 19.44px;
  font-size: 0.73rem; font-weight: 600;
  background: var(--gray-100); color: var(--gray-600);
}

/* Multi-select assignee picker */
.msel { position: relative; }
.msel-chips { min-height: 40.8px; border: 1.5px solid var(--gray-200); border-radius: var(--radius); padding: 5.88px 7.8px; display: flex; flex-wrap: wrap; gap: 5.88px; align-items: center; cursor: pointer; background: var(--white); }
.msel-chips:hover { border-color: var(--teal); }
.msel-placeholder { color: var(--gray-400); font-size: 0.83rem; padding: 2px 3.84px; }
.msel-chip { display: inline-flex; align-items: center; gap: 4.8px; background: var(--gray-100); border: 1px solid var(--gray-200); color: var(--navy); font-size: 0.76rem; font-weight: 600; padding: 3.84px 5.88px 3.84px 9.72px; border-radius: 19.44px; }
.msel-chip button { background: none; border: none; cursor: pointer; color: var(--gray-400); font-size: 0.83rem; line-height: 1; padding: 2px; border-radius: 50%; }
.msel-chip button:hover { background: var(--gray-200); color: var(--danger); }
.msel-dropdown { position: absolute; top: calc(100% + 6.48px); left: 0; right: 0; background: var(--white); border: 1px solid var(--gray-200); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); z-index: 400; max-height: 272.16px; display: flex; flex-direction: column; }
.msel-search-row { padding: 9.72px; border-bottom: 1px solid var(--gray-200); flex-shrink: 0; }
.msel-search-row input { width: 100%; border: 1.5px solid var(--gray-200); border-radius: var(--radius); padding: 6.84px 9.72px; font-size: 0.8rem; }
.msel-search-row input:focus { outline: none; border-color: var(--teal); }
.msel-actions { display: flex; gap: 13.56px; padding: 7.8px 9.72px; border-bottom: 1px solid var(--gray-200); flex-shrink: 0; }
.msel-link { background: none; border: none; color: var(--teal-dark); font-size: 0.74rem; font-weight: 700; cursor: pointer; padding: 0; }
.msel-link:hover { text-decoration: underline; }
.msel-options { overflow-y: auto; flex: 1; }
.msel-option { display: flex; align-items: center; gap: 9.72px; padding: 8.76px 11.64px; cursor: pointer; font-size: 0.82rem; }
.msel-option:hover { background: var(--gray-100); }
.msel-option input { width: 14.64px; height: 14.64px; accent-color: var(--teal); flex-shrink: 0; }
.msel-option-name { flex: 1; color: var(--navy); font-weight: 600; }
.msel-option-role { color: var(--gray-400); font-size: 0.73rem; text-transform: capitalize; }
.msel-empty { padding: 15.6px; text-align: center; color: var(--gray-400); font-size: 0.78rem; }

/* Assignee stack (table/board/detail) */
.assignee-stack { display: flex; flex-wrap: wrap; gap: 3.84px; align-items: center; }
.assignee-chip-sm { display: inline-flex; align-items: center; gap: 3.84px; background: var(--gray-100); border: 1px solid var(--gray-200); border-radius: 13.56px; padding: 2px 7.8px 2px 2px; font-size: 0.73rem; font-weight: 600; color: var(--navy); white-space: nowrap; }
.assignee-chip-sm .avatar { width: 17.52px; height: 17.52px; font-size: 0.73rem; }
.assignee-more-link { background: none; border: none; color: var(--teal-dark); font-size: 0.73rem; font-weight: 700; cursor: pointer; padding: 2px 3.84px; }
.assignee-more-link:hover { text-decoration: underline; }

/* Chat badge (button lives now; full chat panel arrives in Phase 8) */
.chat-unread-badge { background: var(--danger); color: var(--white); font-size: 0.73rem; font-weight: 800; border-radius: 9.72px; min-width: 15.6px; height: 15.6px; padding: 0 3.84px; display: inline-flex; align-items: center; justify-content: center; line-height: 1; }
.chat-table-btn { position: relative; display: inline-flex; align-items: center; gap: 3.84px; }
.chat-table-btn .chat-unread-badge { position: absolute; top: -7.2px; right: -7.2px; }

/* Task Detail modal (tabs, workflow stepper, responses, timeline) */
.modal-xl { max-width: 913.68px; }
.td-tabs { display: flex; gap: 3.84px; padding: 0 23.28px; border-bottom: 1px solid var(--gray-200); flex-shrink: 0; }
.td-tab { background: none; border: none; padding: 13.56px 5.88px; margin-right: 19.44px; font-size: 0.86rem; font-weight: 600; color: var(--gray-400); cursor: pointer; border-bottom: 2px solid transparent; display: flex; align-items: center; gap: 5.88px; }
.td-tab.active { color: var(--navy); border-bottom-color: var(--teal); }

.wf-stepper { display: flex; flex-wrap: wrap; align-items: center; gap: 0; margin-bottom: 3.84px; }
.wf-step { display: flex; align-items: center; gap: 5.88px; padding: 4.8px 9.72px; border-radius: 19.44px; font-size: 0.73rem; font-weight: 700; color: var(--gray-400); background: var(--gray-100); white-space: nowrap; }
.wf-step.active { background: var(--teal); color: var(--white); }
.wf-step.past { background: rgba(16,185,129,.12); color: #047857; }
.wf-arrow { color: var(--gray-300); font-size: 0.78rem; padding: 0 3.84px; }
.wf-blocked-banner { margin-top: 7.8px; background: rgba(224,59,59,.08); border: 1px solid rgba(224,59,59,.25); color: var(--danger); border-radius: var(--radius); padding: 7.8px 11.64px; font-size: 0.78rem; font-weight: 600; }
.wf-actions { display: flex; flex-wrap: wrap; gap: 7.8px; margin-top: 11.64px; }
.wf-response-list { display: flex; flex-direction: column; gap: 7.8px; }
.wf-response-row { display: flex; align-items: center; justify-content: space-between; gap: 9.72px; background: var(--gray-100); border-radius: var(--radius); padding: 7.8px 11.64px; }
.wf-response-status { font-size: 0.73rem; font-weight: 700; padding: 2.88px 8.76px; border-radius: 13.56px; white-space: nowrap; }
.wf-response-accepted { background: rgba(16,185,129,.14); color: #047857; }
.wf-response-rejected { background: rgba(224,59,59,.12); color: var(--danger); }
.wf-response-pending { background: rgba(245,158,11,.14); color: #B45309; }
.wf-timeline { display: flex; flex-direction: column; gap: 13.56px; margin-top: 3.84px; }
.wf-timeline-item { display: flex; gap: 9.72px; }
.wf-timeline-dot { width: 8.76px; height: 8.76px; border-radius: 50%; background: var(--teal); flex-shrink: 0; margin-top: 4.8px; }
.wf-timeline-body { font-size: 0.8rem; }
.wf-timeline-title { font-weight: 700; color: var(--navy); }
.wf-timeline-meta { font-size: 0.73rem; color: var(--gray-400); margin-top: 1px; }
.wf-timeline-reason { font-size: 0.76rem; color: var(--gray-600); margin-top: 2.88px; font-style: italic; }

/* =====================================================================
   PHASE 6 — KANBAN BOARD (drag-and-drop) + TIMELINE/GANTT
   ===================================================================== */
.board-wrap { display: flex; gap: 15.6px; overflow-x: auto; padding-bottom: 11.64px; }
.board-col {
  background: var(--gray-100);
  border-radius: var(--radius-lg);
  padding: 11.64px;
  min-width: 252.72px; width: 252.72px; flex-shrink: 0;
}
.board-col-header { display: flex; align-items: center; justify-content: space-between; padding: 3.84px 3.84px 9.72px; }
.board-col-title { font-weight: 700; font-size: 0.86rem; color: var(--navy); }
.board-col-body { min-height: 38.88px; transition: background .15s ease; border-radius: var(--radius); }
.task-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 11.64px 13.56px;
  margin-bottom: 9.72px;
  box-shadow: var(--shadow-sm);
  cursor: grab;
  transition: box-shadow .15s, transform .15s;
}
.task-card:active { cursor: grabbing; }
.task-card:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); }
.task-card-title { font-size: 0.86rem; font-weight: 600; color: var(--navy); margin-bottom: 7.8px; }
.task-card-meta { display: flex; align-items: center; gap: 7.8px; flex-wrap: wrap; }

/* Timeline / Gantt (project-level bars) */
.gantt-wrap { overflow-x: auto; }
.gantt-table { min-width: 874.8px; }
.gantt-row { display: grid; grid-template-columns: 237.6px 1fr; border-bottom: 1px solid var(--gray-100); }
.gantt-row:hover .gantt-info { background: rgba(0,181,200,.04); }
.gantt-info { padding: 9.72px 13.56px; display: flex; align-items: center; gap: 7.8px; font-size: 0.83rem; }
.gantt-chart { padding: 9.72px 7.8px; position: relative; display: flex; align-items: center; }
.gantt-bar { height: 21.36px; border-radius: 3.84px; background: linear-gradient(90deg, var(--teal) 0%, var(--navy-light) 100%); position: absolute; opacity: .85; }
.gantt-header { display: grid; grid-template-columns: 237.6px 1fr; background: var(--gray-100); border-radius: var(--radius) var(--radius) 0 0; }
.gantt-months { display: flex; }
.gantt-month { font-size: 0.73rem; font-weight: 700; color: var(--gray-600); text-transform: uppercase; letter-spacing: .06em; padding: 7.8px; flex: 1; text-align: center; }

@media (max-width: 691.2px) {
  .board-wrap { padding-bottom: 7.08px; }
  .gantt-wrap { font-size: 0.76rem; }
}

/* =====================================================================
   PHASE 7 — NOTIFICATIONS PAGE
   ===================================================================== */
.notif-filter-chip { padding: 4.8px 13.56px; border-radius: 19.44px; font-size: 0.78rem; font-weight: 600; background: var(--gray-100); color: var(--gray-600); cursor: pointer; border: none; white-space: nowrap; }
.notif-filter-chip.active { background: var(--teal); color: var(--white); }
.notif-priority-high { border-left: 3.24px solid var(--warning); }
.notif-page-list .notif-item { padding: 13.56px 17.52px; }

/* =====================================================================
   PHASE 8 — TASK CHAT
   ===================================================================== */
.chat-wrap { display: flex; flex-direction: column; height: 544.32px; max-height: 70vh; }
.chat-header-mini { display: flex; align-items: flex-start; justify-content: space-between; gap: 11.64px; padding: 13.56px 23.28px; border-bottom: 1px solid var(--gray-200); flex-shrink: 0; }
.chat-header-title { font-weight: 700; font-size: 0.83rem; color: var(--navy); }
.chat-header-sub { font-size: 0.78rem; color: var(--gray-600); margin-top: 2px; }
.chat-header-participants { font-size: 0.73rem; color: var(--gray-400); margin-top: 3.84px; }

.chat-messages { flex: 1; overflow-y: auto; padding: 17.52px 23.28px; background: linear-gradient(var(--gray-100), var(--gray-100)); display: flex; flex-direction: column; gap: 2px; position: relative; }
.chat-date-sep { text-align: center; margin: 13.56px 0 9.72px; }
.chat-date-sep span { background: var(--white); border: 1px solid var(--gray-200); color: var(--gray-600); font-size: 0.73rem; font-weight: 700; padding: 3.84px 11.64px; border-radius: 19.44px; box-shadow: var(--shadow-md); }
.chat-row { display: flex; margin-bottom: 7.8px; }
.chat-row.mine { justify-content: flex-end; }
.chat-bubble { max-width: 72%; padding: 7.8px 11.64px 5.88px; border-radius: 11.64px; font-size: 0.83rem; line-height: 1.4; box-shadow: 0 1px 2px rgba(27,42,107,.08); }
.chat-bubble.theirs { background: var(--white); color: var(--navy); border-bottom-left-radius: 3.24px; }
.chat-bubble.mine { background: var(--teal); color: var(--white); border-bottom-right-radius: 3.24px; }
.chat-sender-name { font-size: 0.73rem; font-weight: 700; color: var(--teal-dark); margin-bottom: 2px; }
.chat-bubble-text { white-space: pre-wrap; word-break: break-word; }
.chat-bubble-time { font-size: 0.73rem; opacity: .7; text-align: right; margin-top: 3.84px; }
.chat-attachments { display: flex; flex-direction: column; gap: 5.88px; margin-top: 5.88px; }
.chat-image-attachment { max-width: 213.84px; max-height: 213.84px; border-radius: 7.8px; display: block; object-fit: cover; }
.chat-attachment-chip { display: flex; align-items: center; gap: 7.8px; background: rgba(255,255,255,.18); border: 1px solid rgba(255,255,255,.3); border-radius: 7.8px; padding: 6.84px 9.72px; font-size: 0.76rem; text-decoration: none; color: inherit; }
.chat-bubble.theirs .chat-attachment-chip { background: var(--gray-100); border-color: var(--gray-200); color: var(--navy); }
.chat-attachment-size { opacity: .75; font-size: 0.73rem; margin-left: auto; white-space: nowrap; }

.chat-jump-latest { position: absolute; bottom: 12.96px; left: 50%; transform: translateX(-50%); background: var(--navy); color: var(--white); font-size: 0.73rem; font-weight: 700; padding: 6.84px 15.6px; border-radius: 19.44px; cursor: pointer; box-shadow: var(--shadow-lg); }

.chat-empty { margin: auto; text-align: center; color: var(--gray-400); padding: 29.16px; }
.chat-empty-icon { font-size: 2.14rem; margin-bottom: 7.8px; }
.chat-empty-title { font-size: 0.87rem; font-weight: 700; color: var(--gray-600); margin-bottom: 3.84px; }

.chat-no-permission { padding: 13.56px 23.28px; text-align: center; font-size: 0.78rem; color: var(--gray-400); border-top: 1px solid var(--gray-200); flex-shrink: 0; }

.chat-attach-preview-bar { display: flex; gap: 7.8px; padding: 9.72px 23.28px 0; flex-wrap: wrap; flex-shrink: 0; }
.chat-preview-item { display: flex; align-items: center; gap: 7.8px; background: var(--gray-100); border: 1px solid var(--gray-200); border-radius: var(--radius); padding: 5.88px 7.8px; max-width: 213.84px; }
.chat-preview-thumb { width: 31.08px; height: 31.08px; border-radius: 5.88px; object-fit: cover; flex-shrink: 0; }
.chat-preview-doc { width: 31.08px; height: 31.08px; border-radius: 5.88px; background: var(--white); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.chat-preview-meta { min-width: 0; }
.chat-preview-name { font-size: 0.73rem; font-weight: 600; color: var(--navy); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 116.64px; }
.chat-preview-size { font-size: 0.73rem; color: var(--gray-400); }
.chat-preview-remove { background: none; border: none; cursor: pointer; color: var(--gray-400); font-size: 0.78rem; margin-left: 3.84px; }
.chat-preview-remove:hover { color: var(--danger); }

.chat-composer { display: flex; align-items: flex-end; gap: 7.8px; padding: 11.64px 23.28px; border-top: 1px solid var(--gray-200); flex-shrink: 0; }
.chat-attach-wrap { position: relative; flex-shrink: 0; }
.chat-attach-btn { background: var(--gray-100); border: none; width: 35.04px; height: 35.04px; border-radius: 50%; font-size: 1.02rem; cursor: pointer; flex-shrink: 0; display: flex; align-items: center; justify-content: center; padding: 0; }
.chat-attach-btn:hover { background: var(--gray-200); }

/* WhatsApp-style popup: Camera / Photos & Document, floating just above the attach button */
.chat-attach-menu { position: absolute; bottom: calc(100% + 9.72px); left: 0; background: var(--white); border-radius: 11.64px; box-shadow: var(--shadow-lg); padding: 5.88px; display: flex; flex-direction: column; gap: 2px; min-width: 199.8px; z-index: 40; border: 1px solid var(--gray-200); }
.chat-attach-menu.hidden { display: none; }
.chat-attach-menu-item { display: flex; align-items: center; gap: 9.72px; background: none; border: none; text-align: left; padding: 8.76px 11.64px; border-radius: 7.8px; font-size: 0.83rem; font-weight: 600; color: var(--navy); cursor: pointer; white-space: nowrap; }
.chat-attach-menu-item:hover { background: var(--gray-100); }
.chat-attach-menu-icon { font-size: 1.07rem; line-height: 1; }

/* Camera capture modal */
.chat-camera-modal { position: fixed; inset: 0; background: rgba(13,19,33,.82); z-index: 1000; display: flex; align-items: center; justify-content: center; }
.chat-camera-modal.hidden { display: none; }
.chat-camera-box { position: relative; background: #000; border-radius: 11.64px; overflow: hidden; width: min(90vw, 518.4px); max-height: 85vh; display: flex; flex-direction: column; }
.chat-camera-video { width: 100%; max-height: 70vh; background: #000; display: block; object-fit: contain; }
.chat-camera-close { position: absolute; top: 11.64px; right: 11.64px; background: rgba(255,255,255,.18); border: none; color: var(--white); width: 35.04px; height: 35.04px; border-radius: 50%; font-size: 0.97rem; cursor: pointer; z-index: 2; }
.chat-camera-controls { display: flex; align-items: center; justify-content: center; padding: 19.44px; background: #000; }
.chat-camera-capture { width: 66.12px; height: 66.12px; border-radius: 50%; background: var(--white); border: 4.32px solid rgba(255,255,255,.5); cursor: pointer; padding: 0; }
.chat-camera-capture:hover { border-color: rgba(255,255,255,.8); }
.chat-text-input { flex: 1; resize: none; border: 1.5px solid var(--gray-200); border-radius: 17.52px; padding: 8.76px 13.56px; font-size: 0.83rem; font-family: inherit; max-height: 116.64px; line-height: 1.4; }
.chat-text-input:focus { outline: none; border-color: var(--teal); }
.chat-send-btn { background: var(--teal); color: var(--white); border: none; width: 35.04px; height: 35.04px; border-radius: 50%; font-size: 0.97rem; cursor: pointer; flex-shrink: 0; }
.chat-send-btn:hover { background: var(--teal-dark); }
.chat-highlight { animation: chatHighlight 1.8s ease; }
@keyframes chatHighlight { 0%{background:rgba(0,181,200,.25);} 100%{background:transparent;} }

@media (max-width: 576px) {
  .chat-wrap { height: 100%; max-height: none; }
  .chat-bubble { max-width: 85%; }
  .chat-header-mini, .chat-messages, .chat-composer, .chat-attach-preview-bar { padding-left: 13.56px; padding-right: 13.56px; }
}

/* =====================================================================
   PHASE 9 — TEAMS, USER MANAGEMENT, SETTINGS, PROFILE
   ===================================================================== */
.profile-header {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 100%);
  border-radius: var(--radius-lg);
  padding: 27.24px;
  display: flex; align-items: center; gap: 19.44px;
  margin-bottom: 21.36px; color: var(--white);
}
.profile-name { font-size: 1.26rem; font-weight: 800; }
.profile-role { font-size: 0.8rem; color: var(--teal-light); margin-top: 2px; }

.team-card-body { padding: 19.44px; display: flex; align-items: center; gap: 13.56px; }
.team-card-footer { padding: 11.64px 19.44px; border-top: 1px solid var(--gray-200); display: flex; justify-content: space-between; align-items: center; }

/* =====================================================================
   NOTIFICATION POLLING — stacking toast alerts (distinct from the
   existing single-slot #toast used for action confirmations like
   "Task deleted" — multiple notifications can arrive in one poll cycle
   and each needs its own dismissible card).
   ===================================================================== */
#notif-toast-stack {
  position: fixed; top: 82.08px; right: 21.6px;
  z-index: 500;
  display: flex; flex-direction: column; gap: 9.72px;
  width: 330.48px; max-width: calc(100vw - 38.88px);
  pointer-events: none;
}
.notif-toast {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-left: 3.24px solid var(--teal);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 11.64px 13.56px;
  display: flex; gap: 9.72px; align-items: flex-start;
  cursor: pointer;
  pointer-events: all;
  animation: notifToastIn .25s ease;
}
.notif-toast.notif-toast-high { border-left-color: var(--warning); }
.notif-toast:hover { box-shadow: var(--shadow-lg), 0 0 0 1px var(--teal); }
.notif-toast-icon { font-size: 1.12rem; flex-shrink: 0; margin-top: 1px; }
.notif-toast-body { flex: 1; min-width: 0; }
.notif-toast-title { font-size: 0.82rem; font-weight: 700; color: var(--navy); }
.notif-toast-msg { font-size: 0.78rem; color: var(--gray-600); margin-top: 2px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.notif-toast-time { font-size: 0.73rem; color: var(--gray-400); margin-top: 3.84px; }
.notif-toast-close { background: none; border: none; color: var(--gray-400); font-size: 0.83rem; cursor: pointer; padding: 2px 3.84px; flex-shrink: 0; }
.notif-toast-close:hover { color: var(--danger); }
@keyframes notifToastIn { from { opacity: 0; transform: translateX(17.28px); } to { opacity: 1; transform: translateX(0); } }
@keyframes notifToastOut { from { opacity: 1; } to { opacity: 0; transform: translateX(17.28px); } }
.notif-toast.notif-toast-leaving { animation: notifToastOut .2s ease forwards; }

@media (max-width: 432px) {
  #notif-toast-stack { top: auto; bottom: 84.24px; right: 10.8px; left: 10.8px; width: auto; }
}

/* =====================================================================
   MASTER TABLE (Admin → Master Table) — reuses existing card/table/
   badge/modal/btn classes almost entirely; only the category-tab strip
   and the role read-only notice need a couple of small additions.
   ===================================================================== */
.mdata-tabs { display: flex; gap: 5.88px; flex-wrap: wrap; margin-bottom: 15.6px; }
.mdata-tab {
  padding: 7.8px 15.6px; border-radius: 19.44px; font-size: 0.81rem; font-weight: 600;
  background: var(--gray-100); color: var(--gray-600); cursor: pointer; border: none;
}
.mdata-tab.active { background: var(--navy); color: var(--white); }
.mdata-readonly-note {
  background: rgba(0,181,200,.06); border: 1px solid rgba(0,181,200,.2);
  border-radius: var(--radius); padding: 11.64px 15.6px; font-size: 0.81rem;
  color: var(--gray-600); margin-bottom: 15.6px; display: flex; gap: 9.72px; align-items: flex-start;
}

/* =====================================================================
   DASHBOARD — compact 7-card task-status summary. A separate modifier
   class (not a change to the shared .stats-grid/.stat-card base rules)
   so the Reports page's 6-card row, which reuses those same base
   classes, is completely unaffected.
   ===================================================================== */
.stats-grid.stats-grid-compact { grid-template-columns: repeat(auto-fit, minmax(159.84px,1fr)); gap: 11.64px; margin-bottom: 19.44px; }
.stats-grid-compact .stat-card { padding: 12.6px 13.56px; gap: 9.72px; }
.stats-grid-compact .stat-icon { width: 33px; height: 33px; font-size: 1.02rem; border-radius: 7.8px; }
.stats-grid-compact .stat-value { font-size: 1.31rem; }
.stats-grid-compact .stat-label { font-size: 0.73rem; }

/* Dashboard status colours (Option B: tinted card). Opt-in via the
   .stat-tinted class + one .stat-status-* modifier that supplies --c
   (solid colour) and --t (soft tint); the shared .stat-card base rules,
   and every other page's stat cards (Reports etc.), are untouched. */
.stat-tinted { background: var(--t); border-color: color-mix(in srgb, var(--c) 35%, transparent); }
.stat-tinted .stat-icon { background: var(--c); color: #fff; }
.stat-tinted .stat-value { color: var(--c); }
.stat-tinted .stat-label { color: var(--gray-600); }
.stat-tinted .stat-card-arrow { color: color-mix(in srgb, var(--c) 45%, transparent); }
.stat-card.stat-tinted.clickable:hover { border-color: var(--c); }
.stat-card.stat-tinted.clickable:hover .stat-card-arrow { color: var(--c); }
.stat-status-pending  { --c: #DB2777; --t: rgba(219,39,119,.12); }
.stat-status-mytasks  { --c: #1B2A6B; --t: rgba(27,42,107,.10); }
.stat-status-assigned { --c: #2563EB; --t: rgba(37,99,235,.12); }
.stat-status-accepted { --c: #0D9488; --t: rgba(13,148,136,.12); }
.stat-status-progress { --c: #7C3AED; --t: rgba(124,58,237,.12); }
.stat-status-myreview { --c: #EA580C; --t: rgba(234,88,12,.12); }
.stat-status-review   { --c: #F59E0B; --t: rgba(245,158,11,.16); }
.stat-status-blocked  { --c: #E03B3B; --t: rgba(224,59,59,.12); }
.stat-status-done     { --c: #10B981; --t: rgba(16,185,129,.14); }


/* =====================================================================
   COMPACT LINE SPACING (2026-10-06)
   Tighter vertical rhythm everywhere so more rows/data fit on screen:
   table rows (Tasks, My Tasks, Reports, Master Table, Users, ...), list
   items, forms, cards. Appended last on purpose — it only overrides the
   vertical spacing of the rules above; fonts, colours and horizontal
   spacing are unchanged.
   ===================================================================== */
body { line-height: 1.25; }
th { padding-top: 6.48px; padding-bottom: 6.48px; }
td { padding-top: 6.48px; padding-bottom: 6.48px; }
.form-group { margin-bottom: 12.96px; }
.form-group label { margin-bottom: 4.32px; }
.page-header { margin-bottom: 15.12px; }
.card-header { padding-top: 10.8px; padding-bottom: 10.8px; }
.card-body { padding: 17.28px; }
.modal-header { padding-top: 14.04px; padding-bottom: 14.04px; }
.modal-body { padding-top: 17.28px; padding-bottom: 17.28px; }
.modal-footer { padding-top: 10.8px; padding-bottom: 10.8px; }
.notif-item { padding-top: 7.56px; padding-bottom: 7.56px; }
.msel-option { padding-top: 5.4px; padding-bottom: 5.4px; }
.td-tab { padding-top: 8.64px; padding-bottom: 8.64px; }
.chat-row { margin-bottom: 5.4px; }
.chat-bubble { line-height: 1.3; }
.task-card-title { margin-bottom: 5.4px; }
.stats-grid { margin-bottom: 17.28px; }
.section-heading { margin: 2px 0 8.4px; }

/* My Review card: image icon on a white tile with a status-coloured ring */
.stat-tinted .stat-icon.stat-icon-img { background: #fff; border: 2px solid var(--c); padding: 4px; }
.stat-icon-img img { width: 100%; height: 100%; object-fit: contain; display: block; }
