/* Design Tokens - Light Mode */
:root {
  color-scheme: light;
  --bg: #ffffff;
  --page-gradient: #ffffff;
  --surface: #ffffff;
  --surface-muted: #fafafa;
  --surface-elevated: #ffffff;
  --surface-overlay: #ffffff;
  --border: #e8e8e8;
  --border-strong: #dfdfdf;
  --text: #000000;
  --text-muted: #666666;
  --heading: #000000;
  --primary: #e05322;
  --primary-soft: rgba(224, 83, 34, 0.08);
  --primary-gradient: #e05322;
  --accent: #e05322;
  --accent-soft: rgba(224, 83, 34, 0.08);
  --success: #4caf50;
  --success-soft: rgba(76, 175, 80, 0.08);
  --danger: #df514c;
  --danger-soft: rgba(223, 81, 76, 0.08);
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.09);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08), 0 1px 3px rgba(0, 0, 0, 0.05);
  --shadow-lg: 0 12px 28px rgba(0, 0, 0, 0.10), 0 4px 8px rgba(0, 0, 0, 0.05);
  --chart-1: #e05322;
  --chart-2: #3b82f6;
  --chart-3: #4caf50;
  --chart-4: #9b9b9b;
  --chart-5: #df514c;
  --chart-fill: rgba(224, 83, 34, 0.08);
  --chart-grid: rgba(232, 232, 232, 0.8);
  --toast-bg: #222222;
  --toast-border: #333333;
  --notification-surface: #ffffff;
  --notification-border: #e8e8e8;
  --notification-divider: #f0f0f0;
  --notification-hover: rgba(224, 83, 34, 0.04);
  --notification-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  --overlay: rgba(0, 0, 0, 0.4);
  --input-bg: #ffffff;
  --input-border: #e8e8e8;
  --input-shadow: 0 0 0 2px rgba(224, 83, 34, 0.15);
  --row-hover: #fafafa;
  --toggle-bg: #ffffff;
  --toggle-track: #e8e8e8;
  --toggle-thumb: #9b9b9b;
  --radius-sm: 4px;
  --radius-md: 4px;
  --radius-lg: 4px;
  --space-1: 6px;
  --space-2: 10px;
  --space-3: 14px;
  --space-4: 18px;
  --space-5: 24px;
  --space-6: 32px;
  --ease: 150ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --ease-slow: 200ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Design Tokens - Dark Mode */
html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #161922;
  --page-gradient: #161922;
  --surface: #191c24;
  --surface-muted: #212431;
  --surface-elevated: #1e222b;
  --surface-overlay: #1e222b;
  --border: #2d323f;
  --border-strong: #383e4d;
  --text: #cbd5e1;
  --text-muted: #8e9db0;
  --heading: #ffffff;
  --primary: #f05a28;
  --primary-soft: rgba(240, 90, 40, 0.1);
  --primary-gradient: #f05a28;
  --accent: #f05a28;
  --accent-soft: rgba(240, 90, 40, 0.1);
  --success: #00b852;
  --success-soft: rgba(0, 184, 82, 0.1);
  --danger: #ff5722;
  --danger-soft: rgba(255, 87, 34, 0.1);
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.45);
  --shadow-lg: 0 12px 36px rgba(0, 0, 0, 0.6);
  --chart-1: #f05a28;
  --chart-2: #5cc8ff;
  --chart-3: #00b852;
  --chart-4: #8e9db0;
  --chart-5: #ff5722;
  --chart-fill: rgba(240, 90, 40, 0.12);
  --chart-grid: rgba(45, 50, 63, 0.5);
  --toast-bg: #1e222b;
  --toast-border: #2d323f;
  --notification-surface: #191c24;
  --notification-border: #2d323f;
  --notification-divider: #282d39;
  --notification-hover: rgba(240, 90, 40, 0.05);
  --notification-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
  --overlay: rgba(0, 0, 0, 0.6);
  --input-bg: #161922;
  --input-border: #2d323f;
  --input-shadow: 0 0 0 2px rgba(240, 90, 40, 0.18);
  --row-hover: #212431;
  --toggle-bg: #191c24;
  --toggle-track: #2d323f;
  --toggle-thumb: #8e9db0;
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  min-height: 100%;
}

body {
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  background: var(--page-gradient);
  color: var(--text);
  transition: background var(--ease-slow), color var(--ease-slow);
}

html.theme-transitioning *,
html.theme-transitioning *::before,
html.theme-transitioning *::after {
  transition-duration: 220ms !important;
  transition-timing-function: ease !important;
}

html.theme-transitioning body {
  animation: theme-fade 220ms ease;
}

@keyframes theme-fade {
  from { opacity: 0.96; }
  to { opacity: 1; }
}

h1, h2, h3, h4, h5, h6 {
  color: var(--heading);
  font-weight: 700;
  margin-top: 0;
  margin-bottom: 0.5em;
}

/* App Shell Loading Overlay */
.app-shell-loading {
  position: fixed;
  inset: 0;
  background: var(--bg);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity var(--ease) var(--ease-slow);
}

.app-shell-loading__content {
  text-align: center;
}

.app-shell-loading__dot {
  width: 24px;
  height: 24px;
  background: var(--primary);
  border-radius: 50%;
  margin: 0 auto 16px;
  animation: pulse 1.2s infinite ease-in-out;
}

.app-shell-loading__text {
  font-weight: 700;
  font-size: 16px;
  color: var(--heading);
  letter-spacing: 0.5px;
}

.app-shell-loading__timer {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 8px;
}

@keyframes pulse {
  0%, 100% { transform: scale(0.6); opacity: 0.5; }
  50% { transform: scale(1.1); opacity: 1; }
}

/* Layout Shell structure */
.layout-root {
  display: flex;
  min-height: 100vh;
}

/* Left Sidebar */
.sidebar {
  width: 275px;
  background: var(--surface);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  height: 100vh;
  position: sticky;
  top: 0;
  z-index: 100;
  transition: width 0.28s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar-brand {
  padding: 18px 16px;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  user-select: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  transition: background var(--ease), padding 0.28s ease;
}

.sidebar-brand:hover {
  background: var(--row-hover);
}

/* Logo Styling */
.sms-logo-wrap {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  user-select: none;
  width: 100%;
}

.sms-text-wrap {
  position: relative;
  overflow: hidden;
  border-radius: 4px;
  padding: 0 2px;
}

.sms-logo-text {
  display: block;
  font-family: 'Orbitron', 'Plus Jakarta Sans', sans-serif;
  font-size: 1.55rem;
  font-weight: 900;
  letter-spacing: 0.16em;
  color: var(--primary);
  line-height: 1.1;
  white-space: nowrap;
  transition: font-size 0.28s ease;
}

.sms-logo--brand .sms-logo-text {
  font-size: 3.4rem;
  letter-spacing: 0.22em;
}

.sms-dv-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  opacity: 0.85;
  transition: opacity 0.25s ease;
  margin-top: 1px;
}

.sms-logo--brand .sms-dv-badge {
  opacity: 0.9;
  margin-top: 6px;
  gap: 7px;
}

.sms-dv-badge:hover { opacity: 1; }

.sms-dv-by {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 0.55rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: lowercase;
  color: var(--text-muted);
  white-space: nowrap;
}

.sms-logo--brand .sms-dv-by {
  font-size: 0.72rem;
}

.sms-dv-img {
  width: 52px;
  height: auto;
  display: block;
}

.sms-logo--brand .sms-dv-img {
  width: 84px;
}

html[data-theme="dark"] .sms-dv-badge {
  opacity: 1;
}

/* Hide Section Category Headings */
.sidebar-nav-category {
  display: none !important;
}

/* Expanded Sidebar Navigation */
.sidebar-nav {
  padding: 18px 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex-grow: 1;
  overflow-y: auto;
  overflow-x: hidden;
  transition: padding 0.28s ease;
}

.sidebar-link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  width: 100%;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  border-radius: var(--radius-sm);
  background: transparent;
  border-left: 3px solid transparent;
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  cursor: pointer;
  white-space: nowrap;
}

.sidebar-icon-wrap {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.sidebar-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  stroke: currentColor;
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), stroke 0.2s ease;
}

.sidebar-link-text {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: opacity 0.25s ease;
}

/* Hover Animation */
.sidebar-link:hover {
  background: var(--surface-muted);
  transform: translateX(4px);
  color: var(--primary);
}

.sidebar-link:hover .sidebar-icon {
  transform: scale(1.15);
}

.sidebar-link:hover .sidebar-link-text {
  color: var(--heading);
}

/* Active Section State with Glow */
.sidebar-link.is-active {
  background: var(--primary-soft);
  color: var(--primary);
  border-left-color: var(--primary);
  box-shadow: 0 2px 10px rgba(224, 83, 34, 0.12);
}

.sidebar-link.is-active .sidebar-icon-wrap {
  background: rgba(224, 83, 34, 0.14);
}

.sidebar-link.is-active .sidebar-icon {
  stroke: var(--primary);
  filter: drop-shadow(0 2px 4px rgba(224, 83, 34, 0.3));
}

.sidebar-link.is-active .sidebar-link-text {
  color: var(--primary);
  font-weight: 700;
}

/* Smooth Page Enter Animation when Switching Sections */
.main-content {
  animation: pageEnterFade 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

@keyframes pageEnterFade {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.sidebar-bottom-links {
  border-top: 1px solid var(--border);
  padding: 12px 10px;
  display: flex;
}

.sidebar-link-bottom {
  font-size: 12.5px;
  cursor: pointer;
}

/* ==========================================================================
   Sidebar Collapsed / Icon-Only State
   ========================================================================== */
.layout-root.sidebar-collapsed .sidebar {
  width: 68px;
}

.layout-root.sidebar-collapsed .sidebar-brand {
  padding: 14px 8px;
}

.layout-root.sidebar-collapsed .sms-logo-text {
  font-size: 1.15rem;
  letter-spacing: 0.05em;
}

.layout-root.sidebar-collapsed .sms-dv-badge {
  display: none;
}

.layout-root.sidebar-collapsed .sidebar-nav {
  padding: 16px 8px;
  align-items: center;
  gap: 10px;
}

.layout-root.sidebar-collapsed .sidebar-link {
  width: 44px;
  height: 44px;
  padding: 0;
  justify-content: center;
  border-radius: 12px;
  border-left: 1px solid transparent;
  transform: none;
}

.layout-root.sidebar-collapsed .sidebar-icon-wrap {
  width: 38px;
  height: 38px;
  border-radius: 10px;
}

.layout-root.sidebar-collapsed .sidebar-icon {
  width: 22px;
  height: 22px;
}

.layout-root.sidebar-collapsed .sidebar-link-text {
  display: none !important;
}

.layout-root.sidebar-collapsed .sidebar-link:hover {
  background: var(--surface-muted);
  transform: translateY(-2px) scale(1.08);
  border-color: var(--border);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
}

.layout-root.sidebar-collapsed .sidebar-link.is-active {
  background: var(--primary-soft);
  border-color: rgba(224, 83, 34, 0.35);
  box-shadow: 0 0 16px rgba(224, 83, 34, 0.22);
  animation: activeSectionPulse 2.4s infinite ease-in-out;
}

@keyframes activeSectionPulse {
  0% { box-shadow: 0 0 0 0 rgba(224, 83, 34, 0.3), 0 2px 8px rgba(224, 83, 34, 0.15); }
  50% { box-shadow: 0 0 0 6px rgba(224, 83, 34, 0), 0 4px 16px rgba(224, 83, 34, 0.3); }
  100% { box-shadow: 0 0 0 0 rgba(224, 83, 34, 0), 0 2px 8px rgba(224, 83, 34, 0.15); }
}

/* Floating Tooltips (Only active in Collapsed mode) */
.layout-root.sidebar-collapsed .sidebar-link[data-tooltip]::after {
  content: attr(data-tooltip);
  position: absolute;
  left: calc(100% + 12px);
  top: 50%;
  transform: translateY(-50%) translateX(-8px);
  background: #0f172a;
  color: #ffffff;
  font-size: 11.5px;
  font-weight: 700;
  white-space: nowrap;
  padding: 6px 12px;
  border-radius: 6px;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s cubic-bezier(0.4, 0, 0.2, 1), transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 1000;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.28);
}

.layout-root.sidebar-collapsed .sidebar-link[data-tooltip]::before {
  content: "";
  position: absolute;
  left: calc(100% + 6px);
  top: 50%;
  transform: translateY(-50%) translateX(-8px);
  border: 4px solid transparent;
  border-right-color: #0f172a;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s cubic-bezier(0.4, 0, 0.2, 1), transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 1000;
}

.layout-root.sidebar-collapsed .sidebar-link:hover[data-tooltip]::after,
.layout-root.sidebar-collapsed .sidebar-link:hover[data-tooltip]::before {
  opacity: 1;
  visibility: visible;
  transform: translateY(-50%) translateX(0);
}

.layout-root.sidebar-collapsed .sidebar-bottom-links {
  padding: 12px 8px;
  justify-content: center;
}

.layout-root.sidebar-collapsed .sidebar .sidebar-bottom-links .sidebar-link {
  width: 44px;
  height: 44px;
  padding: 0;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
}

.layout-root.sidebar-collapsed .sidebar [data-logout]:hover {
  background: var(--danger-soft);
  color: #c93a35;
  border-color: rgba(223, 81, 76, 0.25);
}

/* Right Content Panel */
.main-content {
  flex-grow: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  background: var(--surface-muted);
}

/* Top Header */
.topbar {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  min-height: 72px;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 99;
}

.topbar-title h1 {
  font-size: 18px;
  margin-bottom: 2px;
  color: var(--heading);
}

.topbar-title p {
  margin: 0;
  font-size: 12px;
  color: var(--text-muted);
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  position: relative;
}

/* Notification Bell Button */
.bell-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  cursor: pointer;
  transition: all var(--ease);
}

.bell-btn:hover {
  background: var(--row-hover);
  border-color: var(--border-strong);
  color: var(--heading);
}

.bell-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--primary);
  color: #ffffff;
  font-size: 10px;
  font-weight: 700;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
}

.layout-root.sidebar-collapsed .sidebar-nav {
  padding: 16px 8px;
  align-items: center;
  gap: 10px;
}

.layout-root.sidebar-collapsed .sidebar-link {
  width: 44px;
  height: 44px;
  padding: 0;
  justify-content: center;
  border-radius: 12px;
  border-left: 1px solid transparent;
  transform: none;
}

.layout-root.sidebar-collapsed .sidebar-icon-wrap {
  width: 38px;
  height: 38px;
  border-radius: 10px;
}

.layout-root.sidebar-collapsed .sidebar-icon {
  width: 22px;
  height: 22px;
}

.layout-root.sidebar-collapsed .sidebar-link-text {
  display: none !important;
}

.layout-root.sidebar-collapsed .sidebar-link:hover {
  background: var(--surface-muted);
  transform: translateY(-2px) scale(1.08);
  border-color: var(--border);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
}

.layout-root.sidebar-collapsed .sidebar-link.is-active {
  background: var(--primary-soft);
  border-color: rgba(224, 83, 34, 0.35);
  box-shadow: 0 0 16px rgba(224, 83, 34, 0.22);
  animation: activeSectionPulse 2.4s infinite ease-in-out;
}

@keyframes activeSectionPulse {
  0% { box-shadow: 0 0 0 0 rgba(224, 83, 34, 0.3), 0 2px 8px rgba(224, 83, 34, 0.15); }
  50% { box-shadow: 0 0 0 6px rgba(224, 83, 34, 0), 0 4px 16px rgba(224, 83, 34, 0.3); }
  100% { box-shadow: 0 0 0 0 rgba(224, 83, 34, 0), 0 2px 8px rgba(224, 83, 34, 0.15); }
}

/* Floating Tooltips (Only active in Collapsed mode) */
.layout-root.sidebar-collapsed .sidebar-link[data-tooltip]::after {
  content: attr(data-tooltip);
  position: absolute;
  left: calc(100% + 12px);
  top: 50%;
  transform: translateY(-50%) translateX(-8px);
  background: #0f172a;
  color: #ffffff;
  font-size: 11.5px;
  font-weight: 700;
  white-space: nowrap;
  padding: 6px 12px;
  border-radius: 6px;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s cubic-bezier(0.4, 0, 0.2, 1), transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 1000;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.28);
}

.layout-root.sidebar-collapsed .sidebar-link[data-tooltip]::before {
  content: "";
  position: absolute;
  left: calc(100% + 6px);
  top: 50%;
  transform: translateY(-50%) translateX(-8px);
  border: 4px solid transparent;
  border-right-color: #0f172a;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s cubic-bezier(0.4, 0, 0.2, 1), transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 1000;
}

.layout-root.sidebar-collapsed .sidebar-link:hover[data-tooltip]::after,
.layout-root.sidebar-collapsed .sidebar-link:hover[data-tooltip]::before {
  opacity: 1;
  visibility: visible;
  transform: translateY(-50%) translateX(0);
}

.layout-root.sidebar-collapsed .sidebar-bottom-links {
  padding: 12px 8px;
  justify-content: center;
}

.layout-root.sidebar-collapsed .sidebar .sidebar-bottom-links .sidebar-link {
  width: 44px;
  height: 44px;
  padding: 0;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
}

.layout-root.sidebar-collapsed .sidebar [data-logout]:hover {
  background: var(--danger-soft);
  color: #c93a35;
  border-color: rgba(223, 81, 76, 0.25);
}

/* Right Content Panel */
.main-content {
  flex-grow: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  background: var(--surface-muted);
}

/* Top Header */
.topbar {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  min-height: 72px;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 99;
}

.topbar-title h1 {
  font-size: 18px;
  margin-bottom: 2px;
  color: var(--heading);
}

.topbar-title p {
  margin: 0;
  font-size: 12px;
  color: var(--text-muted);
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  position: relative;
}

/* Notification Bell Button */
.bell-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  cursor: pointer;
  transition: all var(--ease);
}

.bell-btn:hover {
  background: var(--row-hover);
  border-color: var(--border-strong);
  color: var(--heading);
}

.bell-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--primary);
  color: #ffffff;
  font-size: 10px;
  font-weight: 700;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(224, 83, 34, 0.4);
  line-height: 1;
}

/* Theme Toggle Button */
.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0 !important;
  margin: 0 !important;
  background: transparent !important;
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
  border-radius: 50% !important;
  cursor: pointer;
  color: var(--text-muted);
  transition: all var(--ease);
}

.theme-toggle:hover,
.theme-toggle:focus,
.theme-toggle:active {
  background: var(--row-hover) !important;
  color: var(--text) !important;
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
}

.theme-toggle__stack {
  display: flex;
  width: 18px;
  height: 18px;
  position: relative;
}

.theme-toggle__icon {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.theme-toggle__icon svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.theme-toggle[data-theme-state="light"] .theme-toggle__icon--sun {
  opacity: 1;
  transform: scale(1);
}

.theme-toggle[data-theme-state="light"] .theme-toggle__icon--moon {
  opacity: 0;
  transform: scale(0) rotate(-45deg);
}

.theme-toggle[data-theme-state="dark"] .theme-toggle__icon--sun {
  opacity: 0;
  transform: scale(0) rotate(45deg);
}

.theme-toggle[data-theme-state="dark"] .theme-toggle__icon--moon {
  opacity: 1;
  transform: scale(1);
}

.topbar-profile {
  display: flex;
  align-items: center;
}

.role-tag {
  background: var(--primary-soft);
  color: var(--primary);
  border: 1px solid rgba(224, 83, 34, 0.25);
  font-size: 11px;
  font-weight: 700;
  height: 38px;
  padding: 0 12px;
  border-radius: var(--radius-sm);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-sizing: border-box;
}

.role-tag svg {
  color: var(--primary);
}

/* Page Outer Wrapper */
.page-container {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  max-width: 1600px;
  width: 100%;
  margin: 0 auto;
}

/* Alerts bar */
.alerts-banner {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.alert-item {
  background: var(--danger-soft);
  color: #c93a35;
  border: 1px solid rgba(223, 81, 76, 0.2);
  padding: 10px 16px;
  border-radius: var(--radius-md);
  font-size: 12px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

html[data-theme="dark"] .alert-item {
  color: #ff6b66;
}

.alert-dismiss {
  background: none;
  border: none;
  color: inherit;
  font-weight: 700;
  cursor: pointer;
  font-size: 12px;
  padding: 0;
  text-decoration: underline;
}

/* Cards */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  padding: 18px;
  position: relative;
  display: flex;
  flex-direction: column;
}

.card-head {
  border-bottom: 1px solid var(--border);
  padding-bottom: 12px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.card-head h3 {
  font-size: 14px;
  margin: 0;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.card-head p {
  margin: 2px 0 0;
  font-size: 11px;
  color: var(--text-muted);
}

/* Grid systems */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
}

.kpi-card {
  text-align: center;
  padding: 14px;
  border-radius: var(--radius-md);
}

.kpi-card p {
  margin: 0 0 6px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.kpi-card h2 {
  font-size: 24px;
  margin: 0;
  color: var(--primary);
  font-weight: 800;
}

.chart-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 18px;
}

.chart-card {
  min-height: 280px;
}

.dashboard-layout {
  display: grid;
  grid-template-columns: 3fr 1fr;
  gap: 18px;
}

@media (max-width: 1024px) {
  .dashboard-layout {
    grid-template-columns: 1fr;
  }
}

/* Tables and Filters */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 12px 18px;
}

.filter-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.filter-group label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
}

.filter-input,
.filter-select {
  background: var(--input-bg);
  border: 1px solid var(--input-border);
  border-radius: var(--radius-sm);
  padding: 6px 10px;
  font-family: inherit;
  font-size: 13px;
  color: var(--text);
  outline: none;
  min-width: 140px;
  transition: all var(--ease);
}

.filter-input:focus,
.filter-select:focus {
  border-color: var(--primary);
  box-shadow: var(--input-shadow);
}

.filter-input[type="search"] {
  min-width: 220px;
}

/* Dashboard Cohort Filter Bar */
.dashboard-filter-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 12px 18px;
  box-shadow: var(--shadow-sm);
}

.filter-group-items {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
}

.filter-item {
  display: flex;
  align-items: center;
  gap: 8px;
}

.filter-item label {
  font-size: 11px;
  font-weight: 700;
  color: var(--heading);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.btn-sm {
  padding: 6px 12px;
  font-size: 12px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  border-radius: var(--radius-sm);
  cursor: pointer;
}

/* LMS Score KPI Card Breakdown */
.kpi-card--lms {
  position: relative;
  border-color: rgba(224, 83, 34, 0.35);
}

.lms-pill-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
  margin-top: 8px;
  padding-top: 6px;
  border-top: 1px dashed var(--border);
}

.lms-pill {
  background: var(--primary-soft);
  border: 1px solid rgba(224, 83, 34, 0.15);
  border-radius: 4px;
  padding: 2px 2px;
  font-size: 9px;
  text-align: center;
  line-height: 1.15;
}

.lms-pill span {
  display: block;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 8px;
}

.lms-pill strong {
  display: block;
  color: var(--primary);
  font-weight: 800;
  font-size: 11px;
}

.modal-lg {
  max-width: 860px !important;
}

.modal-subtabs {
  display: flex;
  gap: 8px;
  border-bottom: 1px solid var(--border);
  padding: 0 20px;
  background: var(--surface-muted);
}

.modal-subtab {
  padding: 10px 16px;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--ease);
}

.modal-subtab.is-active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}


.btn-primary {
  background: var(--primary);
  color: #ffffff;
  border: 1px solid var(--primary);
  font-weight: 600;
  transition: background var(--ease);
}

.btn-primary:hover {
  background: #c84417;
  border-color: #c84417;
}

.btn-secondary {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
  font-weight: 600;
}

.btn-secondary:hover {
  background: var(--row-hover);
  border-color: var(--border-strong);
}

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid transparent;
  font-weight: 600;
}

.btn-ghost:hover {
  color: var(--heading);
  background: var(--row-hover);
}

.btn-danger {
  background: var(--danger-soft);
  color: var(--danger);
  border: 1px solid rgba(223, 81, 76, 0.2);
  font-weight: 600;
}

.btn-danger:hover {
  background: var(--danger);
  color: #ffffff;
}

.table-responsive {
  width: 100%;
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  text-align: center;
}

.data-table th {
  background: var(--surface-muted);
  color: var(--text-muted);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 10px;
  border-bottom: 1px solid var(--border);
  height: 38px;
}

.data-table td {
  padding: 10px;
  border-bottom: 1px solid var(--border);
  color: var(--text);
  height: 42px;
}

.data-table tr:last-child td {
  border-bottom: none;
}

.data-table tr:hover td {
  background: var(--row-hover);
}

/* Badge classes */
.badge {
  display: inline-flex;
  align-items: center;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  text-transform: uppercase;
}

.badge-active { background: rgba(22, 163, 74, 0.12); color: #16a34a; border: 1px solid rgba(22, 163, 74, 0.3); }
.badge-inactive { background: rgba(239, 68, 68, 0.12); color: #dc2626; border: 1px solid rgba(239, 68, 68, 0.3); }
.badge-completed { background: rgba(22, 163, 74, 0.12); color: #16a34a; border: 1px solid rgba(22, 163, 74, 0.3); }
.badge-dropped { background: rgba(239, 68, 68, 0.12); color: #dc2626; border: 1px solid rgba(239, 68, 68, 0.3); }

.badge-satisfactory { background: rgba(22, 163, 74, 0.12); color: #16a34a; border: 1px solid rgba(22, 163, 74, 0.3); }
.badge-neutral { background: rgba(22, 163, 74, 0.12); color: #16a34a; border: 1px solid rgba(22, 163, 74, 0.3); }
.badge-unsatisfied { background: rgba(239, 68, 68, 0.12); color: #dc2626; border: 1px solid rgba(239, 68, 68, 0.3); }

.badge-pending { background: rgba(239, 68, 68, 0.12); color: #dc2626; border: 1px solid rgba(239, 68, 68, 0.3); }
.badge-overdue { background: rgba(239, 68, 68, 0.12); color: #dc2626; border: 1px solid rgba(239, 68, 68, 0.3); }

/* Right Slide-out Drawer (Student 360) */
.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: var(--overlay);
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.drawer-backdrop.is-open {
  opacity: 1;
  visibility: visible;
}

.drawer {
  position: fixed;
  top: 0;
  right: -550px;
  width: 520px;
  height: 100%;
  background: var(--surface);
  z-index: 1001;
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  transition: right 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.drawer.is-open {
  right: 0;
}

.drawer-head {
  padding: 18px 24px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.drawer-title h2 {
  font-size: 16px;
  margin: 0;
}

.drawer-title p {
  margin: 2px 0 0;
  font-size: 11px;
  color: var(--text-muted);
}

.drawer-close {
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
}

.drawer-body {
  flex-grow: 1;
  overflow-y: auto;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Modals */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: var(--overlay);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s ease;
}

.modal-backdrop.is-open {
  opacity: 1;
  visibility: visible;
}

.modal {
  background: var(--surface-overlay);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 540px;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: width 0.15s ease, height 0.15s ease;
}

.modal.modal-resizable {
  resize: both;
  overflow: hidden;
  min-width: 480px;
  min-height: 380px;
  max-width: 96vw;
  max-height: 94vh;
}

.modal.modal-resizable.is-maximized {
  width: 95vw !important;
  height: 92vh !important;
  max-width: 95vw !important;
  max-height: 92vh !important;
  resize: none !important;
}

.modal-head {
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  user-select: none;
  flex-shrink: 0;
}

.modal-head-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.modal-action-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  transition: all var(--ease);
}

.modal-action-btn:hover {
  background: var(--row-hover);
  color: var(--heading);
}

.modal-head h3 {
  font-size: 15px;
  margin: 0;
}

.modal-body {
  padding: 20px;
  overflow-y: auto;
  flex: 1 1 auto;
  min-height: 0;
  max-height: 75vh;
}

.modal-resizable .modal-body {
  max-height: none;
}

.modal-foot {
  padding: 12px 20px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-shrink: 0;
}

.modal-resize-grip {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 16px;
  height: 16px;
  cursor: nwse-resize;
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  padding: 2px;
  color: var(--text-muted);
  pointer-events: none;
  z-index: 10;
}

.modal-resize-grip svg {
  width: 11px;
  height: 11px;
  opacity: 0.6;
}

/* Form Styles */
.form-group {
  margin-bottom: 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
}

.form-control {
  background: var(--input-bg);
  border: 1px solid var(--input-border);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  font-family: inherit;
  font-size: 13px;
  color: var(--text);
  outline: none;
  transition: all var(--ease);
}

.form-control:focus {
  border-color: var(--primary);
  box-shadow: var(--input-shadow);
}

/* Tabs */
.tablist {
  display: flex;
  border-bottom: 1px solid var(--border);
  gap: 16px;
  margin-bottom: 16px;
}

.tab {
  border: none;
  background: none;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  padding: 8px 4px 12px;
  cursor: pointer;
  position: relative;
}

.tab.is-active {
  color: var(--primary);
}

.tab.is-active::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--primary);
}

.tabpanel {
  display: none;
}

.tabpanel.is-active {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Timeline Components */
.timeline {
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 19px;
  top: 6px;
  bottom: 6px;
  width: 2px;
  background: var(--border);
}

.timeline-event {
  display: flex;
  gap: 16px;
  position: relative;
}

.timeline-event-marker {
  width: 8px;
  height: 8px;
  background: var(--primary);
  border-radius: 50%;
  margin-left: 16px;
  margin-top: 5px;
  z-index: 1;
}

.timeline-event-content {
  font-size: 12px;
}

.timeline-event-date {
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.timeline-event-text {
  color: var(--text);
}

/* Performance matrices */
.matrix-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
  gap: 10px;
}

.matrix-item {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 8px 4px;
  text-align: center;
  background: var(--surface-muted);
}

.matrix-label {
  font-size: 10px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 4px;
}

.matrix-value {
  font-size: 14px;
  font-weight: 700;
  color: var(--heading);
}

.matrix-value.pass { color: var(--success); }
.matrix-value.fail { color: var(--danger); }

/* Hero Landing & Modal Login (replicated from i-cms style structure) */
.hero {
  position: relative;
  background-color: var(--bg);
  color: var(--text);
  padding: 48px 16px;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  transition: background var(--ease-slow), color var(--ease-slow);
}

.hero-content {
  max-width: 600px;
  width: 100%;
}

.hero-toolbar {
  position: absolute;
  top: 24px;
  left: 24px;
  z-index: 10;
  display: flex;
  justify-content: flex-start;
  margin-bottom: 0;
}

.hero-logo {
  margin-bottom: 36px;
}

.hero-title {
  font-size: 36px;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--primary);
}

.hero-subtitle {
  font-size: 18px;
  margin-bottom: 16px;
  color: var(--text-muted);
}

.hero-description {
  margin-bottom: 32px;
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

.hero-actions .btn {
  padding: 12px 24px;
  font-size: 14px;
  font-weight: 700;
  border-radius: var(--radius-md);
  cursor: pointer;
  border: none;
  transition: all var(--ease);
}

.hero-actions .btn-primary {
  background: var(--primary);
  color: #fff;
}

.hero-actions .btn-primary:hover {
  background: #c84417;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.hero-actions .btn-secondary {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border-strong);
}

.hero-actions .btn-secondary:hover {
  background: var(--row-hover);
  transform: translateY(-2px);
}

/* Modal System (i-cms layout) */
.modal-overlay {
  position: fixed;
  inset: 0;
  background-color: var(--overlay);
  z-index: 1000;
  transition: opacity var(--ease);
}

.modal-container {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  max-width: 480px;
  width: 90%;
  z-index: 1001;
  display: flex;
  flex-direction: column;
  animation: modal-zoom-in 0.25s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

@keyframes modal-zoom-in {
  from { opacity: 0; transform: translate(-50%, -45%) scale(0.96); }
  to { opacity: 1; transform: translate(-50%, -50%) scale(1); }
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
}

.modal-title {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.modal-close {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-close:hover {
  color: var(--heading);
}

.modal-body {
  padding: 20px;
}

.modal-footer {
  padding: 0 20px 20px;
  text-align: center;
}

.help-text {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 10px;
  margin-bottom: 0;
  line-height: 1.4;
}

.help-text a {
  color: var(--primary);
  text-decoration: underline;
  font-weight: 600;
}

/* Modal Hints */
.modal-footer-hints {
  margin-top: 16px;
  padding: 10px;
  border: 1px dashed var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-muted);
  font-size: 11px;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.5;
}

.modal-footer-hints code {
  background: var(--border);
  padding: 2px 4px;
  border-radius: var(--radius-sm);
  color: var(--primary);
  font-family: monospace;
}

/* Header Bell Icon unread badge */
.bell-btn {
  position: relative;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  border-radius: var(--radius-sm);
  transition: all var(--ease);
}

.bell-btn:hover {
  color: var(--heading);
  background: var(--row-hover);
}

.bell-badge {
  position: absolute;
  top: 2px;
  right: 2px;
  background: var(--danger);
  color: #ffffff;
  font-size: 9px;
  font-weight: 700;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bell-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  width: 330px;
  background: var(--surface-overlay);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  margin-top: 8px;
  display: none;
  z-index: 101;
}

.bell-dropdown.is-open {
  display: block;
  animation: slide-dropdown 0.18s ease-out;
}

@keyframes slide-dropdown {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.bell-dropdown-header {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  font-weight: 700;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.bell-clear-all {
  font-family: inherit;
  font-size: 11px;
  font-weight: 600;
  color: var(--primary);
  background: var(--primary-soft);
  border: 1px solid rgba(224, 83, 34, 0.2);
  border-radius: var(--radius-sm);
  padding: 3px 8px;
  cursor: pointer;
  transition: all var(--ease);
}

.bell-clear-all:hover {
  background: var(--primary);
  color: #fff;
}

.bell-close-btn {
  background: transparent;
  border: none;
  font-size: 18px;
  line-height: 1;
  color: var(--text-muted);
  cursor: pointer;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  transition: all var(--ease);
  display: flex;
  align-items: center;
  justify-content: center;
}

.bell-close-btn:hover {
  background: var(--row-hover);
  color: var(--heading);
}

.bell-dropdown-body {
  max-height: 280px;
  overflow-y: auto;
}

.bell-notification-item {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  font-size: 12px;
  line-height: 1.4;
  cursor: pointer;
  transition: background var(--ease);
}

.bell-notification-item:hover {
  background: var(--row-hover);
}

.bell-notification-item:last-child {
  border-bottom: none;
}

/* ====================================================
   I-SMS PERFORMANCE & 360 FEEDBACK SYSTEM ADDONS
   ==================================================== */

.badge-elite {
  background: rgba(22, 163, 74, 0.12);
  color: #16a34a;
  border: 1px solid rgba(22, 163, 74, 0.3);
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
html[data-theme="dark"] .badge-elite {
  background: rgba(22, 163, 74, 0.22);
  color: #4ade80;
  border-color: rgba(22, 163, 74, 0.4);
}

.badge-placement {
  background: rgba(22, 163, 74, 0.12);
  color: #16a34a;
  border: 1px solid rgba(22, 163, 74, 0.3);
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
html[data-theme="dark"] .badge-placement {
  background: rgba(22, 163, 74, 0.22);
  color: #4ade80;
  border-color: rgba(22, 163, 74, 0.4);
}

.badge-risk {
  background: rgba(239, 68, 68, 0.12);
  color: #dc2626;
  border: 1px solid rgba(239, 68, 68, 0.3);
  font-weight: 700;
}
html[data-theme="dark"] .badge-risk {
  background: rgba(239, 68, 68, 0.22);
  color: #f87171;
}

.badge-knowledge-best {
  background: rgba(22, 163, 74, 0.15);
  color: #16a34a;
  border: 1px solid rgba(22, 163, 74, 0.3);
}
.badge-knowledge-good {
  background: rgba(22, 163, 74, 0.15);
  color: #16a34a;
  border: 1px solid rgba(22, 163, 74, 0.3);
}
.badge-knowledge-avg {
  background: rgba(239, 68, 68, 0.15);
  color: #dc2626;
  border: 1px solid rgba(239, 68, 68, 0.3);
}
.badge-knowledge-low {
  background: rgba(239, 68, 68, 0.15);
  color: #dc2626;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.assignment-dots {
  display: inline-flex;
  gap: 4px;
  align-items: center;
}
.assignment-dot {
  width: 18px;
  height: 18px;
  border-radius: 3px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 9px;
  font-weight: 700;
}
.assignment-dot.done {
  background: rgba(16, 185, 129, 0.2);
  color: #059669;
  border: 1px solid rgba(16, 185, 129, 0.4);
}
.assignment-dot.pending {
  background: rgba(239, 68, 68, 0.15);
  color: #dc2626;
  border: 1px solid rgba(239, 68, 68, 0.3);
}
html[data-theme="dark"] .assignment-dot.done {
  background: rgba(16, 185, 129, 0.3);
  color: #34d399;
}
html[data-theme="dark"] .assignment-dot.pending {
  background: rgba(239, 68, 68, 0.25);
  color: #f87171;
}

.rating-stars {
  color: #f59e0b;
  font-size: 13px;
  letter-spacing: 1px;
}

/* ====================================================
   Product screens: workflow-first i-SMS experience
   ==================================================== */

.page-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.toolbar-group {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.section-title {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.section-title h2,
.section-title h3 {
  margin: 0;
  font-size: 15px;
  color: var(--heading);
}

.section-title p {
  margin: 0;
  font-size: 12px;
  color: var(--text-muted);
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(160px, 1fr));
  gap: 14px;
}

.metric-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  padding: 16px;
}

.metric-label {
  margin: 0 0 8px;
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.metric-value {
  margin: 0;
  color: var(--heading);
  font-size: 26px;
  font-weight: 800;
  line-height: 1;
}

.metric-value small {
  font-size: 13px;
  color: var(--text-muted);
}

.metric-note {
  margin: 8px 0 0;
  color: var(--text-muted);
  font-size: 11px;
}

.workbench-grid {
  display: grid;
  grid-template-columns: minmax(240px, 300px) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.student-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.student-list button,
.record-card {
  width: 100%;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  border-radius: var(--radius-md);
  padding: 12px;
  text-align: left;
  font-family: inherit;
  cursor: pointer;
  transition: all var(--ease);
}

.student-list button:hover,
.record-card:hover {
  border-color: var(--border-strong);
  background: var(--row-hover);
}

.student-list button.is-active {
  border-color: rgba(224, 83, 34, 0.45);
  background: var(--primary-soft);
}

.student-name-row,
.record-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.student-name-row strong,
.record-card-head strong {
  color: var(--heading);
  font-size: 13px;
}

.student-meta,
.record-meta {
  margin-top: 5px;
  color: var(--text-muted);
  font-size: 11px;
}

.student-microstats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-top: 10px;
}

.student-microstats span {
  background: var(--surface-muted);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 6px 4px;
  text-align: center;
  font-size: 10px;
  color: var(--text-muted);
}

.student-microstats strong {
  display: block;
  color: var(--heading);
  font-size: 12px;
}

.profile-banner {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  padding: 18px;
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(300px, 1fr);
  gap: 18px;
  align-items: start;
}

.profile-title h2 {
  margin: 0 0 4px;
  font-size: 24px;
}

.profile-title p {
  margin: 0;
  color: var(--text-muted);
  font-size: 12px;
}

.status-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.rule-panel {
  display: grid;
  gap: 8px;
}

.rule-item {
  background: var(--surface-muted);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px;
}

.rule-item span {
  display: block;
  color: var(--text-muted);
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  margin-bottom: 4px;
}

.rule-item strong {
  color: var(--heading);
  font-size: 12px;
}

.module-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 12px;
}

.module-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.module-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.module-card h3 {
  margin: 0;
  font-size: 13px;
}

.module-score {
  color: var(--heading);
  font-size: 20px;
  font-weight: 800;
}

.progress-row {
  display: grid;
  gap: 5px;
}

.progress-label {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 700;
}

.progress-track {
  height: 7px;
  background: var(--surface-muted);
  border: 1px solid var(--border);
  border-radius: 999px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--primary);
  border-radius: 999px;
}

.progress-fill.good { background: var(--success); }
.progress-fill.risk { background: var(--danger); }
.progress-fill.info { background: var(--success); }

.compact-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.compact-table th {
  text-align: left;
  color: var(--text-muted);
  font-size: 10px;
  text-transform: uppercase;
  padding: 9px 10px;
  border-bottom: 1px solid var(--border);
  background: var(--surface-muted);
}

.compact-table td {
  padding: 10px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.compact-table tr:last-child td {
  border-bottom: 0;
}

.table-actions {
  display: flex;
  justify-content: flex-end;
}

.student-name-link {
  color: var(--heading, #0f172a);
  text-decoration: none;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: color 0.15s ease, text-decoration 0.15s ease;
  cursor: pointer;
}

.student-name-link:hover {
  color: var(--primary, #0284c7);
  text-decoration: underline;
}

.student-name-link:focus-visible {
  outline: 2px solid var(--primary, #0284c7);
  outline-offset: 2px;
  border-radius: 2px;
}

.feedback-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(260px, 1fr));
  gap: 14px;
  align-items: start;
}

.feedback-lane {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  min-height: 320px;
  display: flex;
  flex-direction: column;
}

.feedback-lane-head {
  padding: 14px;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
}

.feedback-lane-head h3 {
  margin: 0;
  font-size: 14px;
}

.feedback-lane-head p {
  margin: 3px 0 0;
  color: var(--text-muted);
  font-size: 11px;
}

.feedback-lane-body {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.record-score {
  color: var(--primary);
  font-weight: 800;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(320px, 1fr));
  gap: 18px;
}

.card-grid-full {
  grid-column: 1 / -1;
}

.insight-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.insight-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 10px;
  background: var(--surface-muted);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}

.bar-list {
  display: grid;
  gap: 10px;
}

.bar-row {
  display: grid;
  grid-template-columns: minmax(110px, 160px) minmax(0, 1fr) 42px;
  gap: 10px;
  align-items: center;
  font-size: 12px;
}

.empty-state {
  padding: 24px;
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-md);
  text-align: center;
  color: var(--text-muted);
  background: var(--surface-muted);
}

.student-directory-card {
  min-height: 420px;
}

.student-directory-table th,
.student-directory-table td {
  white-space: nowrap;
}

.student-directory-table th:first-child,
.student-directory-table td:first-child {
  min-width: 220px;
}

.student-directory-table th:nth-child(8),
.student-directory-table td:nth-child(8) {
  min-width: 150px;
}

.student-directory-table a.btn-primary {
  text-decoration: none;
  justify-content: center;
}

.feedback-tabs-card {
  min-height: 460px;
}

.feedback-tablist {
  flex-wrap: wrap;
}

.feedback-list-table th,
.feedback-list-table td {
  white-space: nowrap;
}

.feedback-list-table th:first-child,
.feedback-list-table td:first-child {
  min-width: 160px;
}

.feedback-comment-cell {
  min-width: 280px;
  max-width: 440px;
  white-space: normal !important;
  line-height: 1.45;
  color: var(--text-muted);
}

/* Calling & Telephony Analytics Styles */
.calling-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
}

@media (min-width: 1400px) {
  .calling-kpi-grid {
    grid-template-columns: repeat(7, 1fr);
  }
}

.chart-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.chart-tab-btn {
  background: var(--surface-muted);
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 5px 12px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: all var(--ease);
  font-family: inherit;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.chart-tab-btn:hover {
  background: var(--row-hover);
  color: var(--heading);
  border-color: var(--border-strong);
}

.chart-tab-btn.is-active {
  background: var(--primary);
  color: #ffffff;
  border-color: var(--primary);
  box-shadow: 0 2px 6px rgba(224, 83, 34, 0.25);
}

.chart-legend-wrap {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px dashed var(--border);
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
}

.chart-legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}

.legend-dot.series-1 { background: #ef4444; }
.legend-dot.series-2 { background: #16a34a; }
.legend-dot.series-3 { background: #16a34a; }
.chart-svg-box {
  width: 100%;
  position: relative;
  min-height: 280px;
  overflow: visible;
  padding-top: 12px;
}

.chart-svg-box svg {
  width: 100%;
  height: auto;
  display: block;
  overflow: visible;
}

.svg-grid-line {
  stroke: var(--border);
  stroke-width: 1;
  stroke-dasharray: 4 4;
}

.svg-axis-line {
  stroke: var(--border-strong);
  stroke-width: 1;
}

.svg-axis-text {
  fill: var(--text-muted);
  font-size: 10px;
  font-family: inherit;
  font-weight: 600;
}

.svg-point {
  fill: var(--surface);
  stroke-width: 2.5;
  transition: r 0.15s ease, stroke-width 0.15s ease;
  cursor: pointer;
}

.svg-point:hover {
  r: 6;
  stroke-width: 3.5;
}

.svg-column-bar {
  transition: opacity 0.15s ease, transform 0.15s ease;
  cursor: pointer;
}

.svg-column-bar:hover {
  opacity: 0.85;
}

.chart-tooltip-bubble {
  position: absolute;
  pointer-events: none;
  background: var(--surface-elevated);
  color: var(--heading);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  font-size: 11px;
  font-weight: 600;
  box-shadow: var(--shadow-md);
  z-index: 100;
  opacity: 0;
  transform: translate(-50%, -100%);
  margin-top: -10px;
  transition: opacity 0.15s ease;
  white-space: nowrap;
}

.chart-tooltip-bubble.is-visible {
  opacity: 1;
}

.donut-chart-box {
  width: 100%;
  position: relative;
  min-height: 320px;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

.donut-segment {
  transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.15s ease, stroke-width 0.2s ease;
  cursor: pointer;
  transform-origin: center;
}

.donut-segment:hover {
  opacity: 0.9;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,0.18));
}

.donut-leader-line {
  stroke: var(--text-muted);
  stroke-width: 1;
  fill: none;
  opacity: 0.6;
}

.donut-label-main {
  font-size: 11px;
  font-weight: 700;
  font-family: inherit;
  fill: var(--heading);
}

.donut-label-sub {
  font-size: 10px;
  font-weight: 600;
  font-family: inherit;
  fill: var(--text-muted);
}

.donut-center-title {
  font-size: 11px;
  font-weight: 700;
  fill: var(--text-muted);
  text-anchor: middle;
}

.donut-center-value {
  font-size: 20px;
  font-weight: 800;
  fill: var(--heading);
  text-anchor: middle;
}

.readiness-kpi-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 700;
}

.readiness-kpi-badge.pass {
  background: rgba(22, 163, 74, 0.12);
  color: #16a34a;
  border: 1px solid rgba(22, 163, 74, 0.3);
}

.readiness-kpi-badge.fail {
  background: rgba(239, 68, 68, 0.12);
  color: #dc2626;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.custom-multiselect {
  position: relative;
  display: inline-block;
}

.multiselect-btn {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 210px;
  padding: 7px 14px;
  font-size: 12px;
  font-weight: 600;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--heading);
  cursor: pointer;
  transition: all 0.15s ease;
}

.multiselect-btn:hover {
  border-color: var(--primary);
}

.multiselect-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 230px;
  background: var(--surface-elevated);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  padding: 8px 6px;
  z-index: 200;
  display: none;
}

.custom-multiselect.is-open .multiselect-menu {
  display: block;
}

.multiselect-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 600;
  color: var(--heading);
  border-radius: var(--radius-sm);
  cursor: pointer;
  user-select: none;
  transition: background 0.1s ease;
}

.multiselect-option:hover {
  background: var(--surface-muted);
}

.multiselect-option input[type="checkbox"] {
  cursor: pointer;
  accent-color: var(--primary);
  width: 15px;
  height: 15px;
}

.multiselect-divider {
  height: 1px;
  background: var(--border);
  margin: 6px 4px;
}

@media (max-width: 1100px) {
  .metric-grid,
  .calling-kpi-grid,
  .feedback-board,
  .dashboard-grid,
  .profile-banner,
  .top-faculty-grid {
    grid-template-columns: 1fr;
  }

  .workbench-grid {
    grid-template-columns: 1fr;
  }
}

/* Faculty Feedback & Top 3 Display */
.top-faculty-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 20px;
}

.faculty-podium-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: var(--shadow-sm);
  transition: transform var(--ease), box-shadow var(--ease), border-color var(--ease);
}

.faculty-podium-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-strong);
}

.faculty-podium-card.rank-1 {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.09) 0%, var(--surface) 100%);
  border-color: rgba(245, 158, 11, 0.45);
}

.faculty-podium-card.rank-2 {
  background: linear-gradient(135deg, rgba(148, 163, 184, 0.09) 0%, var(--surface) 100%);
  border-color: rgba(148, 163, 184, 0.45);
}

.faculty-podium-card.rank-3 {
  background: linear-gradient(135deg, rgba(217, 119, 6, 0.08) 0%, var(--surface) 100%);
  border-color: rgba(217, 119, 6, 0.4);
}

.faculty-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.faculty-rank-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.faculty-rank-badge.rank-1 {
  background: rgba(245, 158, 11, 0.2);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.faculty-rank-badge.rank-2 {
  background: rgba(148, 163, 184, 0.2);
  color: #94a3b8;
  border: 1px solid rgba(148, 163, 184, 0.4);
}

.faculty-rank-badge.rank-3 {
  background: rgba(217, 119, 6, 0.2);
  color: #d97706;
  border: 1px solid rgba(217, 119, 6, 0.35);
}

.faculty-name-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--heading);
  margin: 0;
}

.faculty-rating-block {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.faculty-rating-val {
  font-size: 28px;
  font-weight: 800;
  line-height: 1;
  color: #f59e0b;
}

.faculty-rating-stars {
  font-size: 14px;
  color: #f59e0b;
  letter-spacing: 2px;
}

.faculty-positive-meter {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.faculty-meter-label {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
}

.faculty-meter-label strong {
  color: var(--success);
}

.faculty-substats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--border);
  font-size: 11px;
}

.faculty-substat-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.faculty-substat-item span {
  color: var(--text-muted);
}

.faculty-substat-item strong {
  color: var(--heading);
  font-weight: 600;
}

/* Faculty Feedback Redesign Layout */
.faculty-donut-layout {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 18px;
  align-items: stretch;
  margin-top: 4px;
}

@media (max-width: 1080px) {
  .faculty-donut-layout {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

.faculty-donut-pane,
.faculty-cards-pane {
  display: flex;
  flex-direction: column;
  background: var(--surface-muted);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px 18px;
}

.faculty-pane-head {
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}

.faculty-pane-head h4 {
  font-size: 13px;
  font-weight: 700;
  color: var(--heading);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin: 0 0 2px 0;
  display: flex;
  align-items: center;
  gap: 6px;
}

.faculty-pane-head p {
  font-size: 11px;
  color: var(--text-muted);
  margin: 0;
}

.faculty-donut-box {
  width: 100%;
  flex: 1;
  min-height: 330px;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

.faculty-top-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
  justify-content: space-between;
}

.faculty-top-item {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 11px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: all var(--ease);
  position: relative;
}

.faculty-top-item:hover {
  background: var(--row-hover);
  border-color: var(--border-strong);
  transform: translateY(-1px);
}

.faculty-top-item.rank-1 {
  border-left: 4px solid #f59e0b;
}

.faculty-top-item.rank-2 {
  border-left: 4px solid #0284c7;
}

.faculty-top-item.rank-3 {
  border-left: 4px solid #10b981;
}

.faculty-item-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.faculty-item-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  color: var(--heading);
  font-size: 13.5px;
}

.faculty-color-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  display: inline-block;
}

.faculty-item-stats {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
}

.faculty-rating-chip {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  font-weight: 700;
  color: #f59e0b;
}

.faculty-item-meter {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.faculty-item-subtags {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: var(--text-muted);
  padding-top: 5px;
  border-top: 1px dashed var(--border);
}

.faculty-item-subtags strong {
  color: var(--heading);
  font-weight: 600;
}

/* ==========================================================================
   SIDEBAR SUB-CATEGORIES
   ========================================================================== */
.sidebar-nav-category {
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-muted);
  padding: 6px 12px 2px;
  opacity: 0.8;
}

.sidebar-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

/* ==========================================================================
   STUDENT PERFORMANCE DASHBOARD (REFERENCE 1)
   ========================================================================== */
.sp-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  gap: 16px;
  flex-wrap: wrap;
}

.sp-header-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.sp-header-title-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}

.sp-header-icon {
  width: 28px;
  height: 28px;
  color: #1e3a8a;
}

html[data-theme="dark"] .sp-header-icon {
  color: #60a5fa;
}

.sp-dashboard-title {
  font-size: 18px;
  font-weight: 900;
  letter-spacing: 0.5px;
  color: #0f172a;
  margin: 0;
  text-transform: uppercase;
}

html[data-theme="dark"] .sp-dashboard-title {
  color: #f8fafc;
}

.sp-header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.sp-date-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  color: #334155;
}

html[data-theme="dark"] .sp-date-badge {
  background: #1e293b;
  border-color: #334155;
  color: #cbd5e1;
}

/* Search box in Topbar */
.sp-search-box-wrap {
  position: relative;
  display: flex;
  align-items: center;
  width: 280px;
}

.sp-search-icon {
  position: absolute;
  left: 10px;
  color: var(--text-muted);
  pointer-events: none;
}

.sp-search-input {
  width: 100%;
  padding: 7px 12px 7px 32px;
  font-size: 12.5px;
  font-weight: 500;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  outline: none;
  transition: border-color var(--ease);
}

.sp-search-input:focus {
  border-color: var(--primary);
  box-shadow: var(--input-shadow);
}

.sp-search-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
  max-height: 260px;
  overflow-y: auto;
  z-index: 1000;
}

.sp-search-item {
  padding: 8px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  transition: background var(--ease);
}

.sp-search-item:last-child {
  border-bottom: none;
}

.sp-search-item:hover {
  background: var(--row-hover);
}

.sp-search-item-main {
  display: flex;
  flex-direction: column;
}

.sp-search-item-name {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--heading);
}

.sp-search-item-id {
  font-size: 11px;
  color: var(--text-muted);
}

.sp-search-item-batch {
  font-size: 11px;
  font-weight: 700;
  background: #f1f5f9;
  padding: 2px 6px;
  border-radius: 3px;
  color: #334155;
}

html[data-theme="dark"] .sp-search-item-batch {
  background: #1e293b;
  color: #94a3b8;
}

.sp-search-no-res {
  padding: 12px;
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
}

/* Dashboard Layout Grid */
.sp-dashboard-layout {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 14px 20px;
  max-width: 1600px;
  margin: 0 auto;
  width: 100%;
}

.sp-top-grid {
  display: grid;
  grid-template-columns: 290px 1fr;
  gap: 12px;
  align-items: stretch;
}

.sp-card-banner-header {
  background: #0f2744;
  color: #ffffff;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.6px;
  padding: 6px 10px;
  text-align: center;
  border-top-left-radius: var(--radius-sm);
  border-top-right-radius: var(--radius-sm);
}

.sp-profile-card {
  padding: 0 !important;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.sp-profile-body {
  padding: 10px 12px;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  flex: 1;
}

.sp-avatar-circle {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #e0e7ff;
  color: #2563eb;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid #bfdbfe;
  flex-shrink: 0;
}

html[data-theme="dark"] .sp-avatar-circle {
  background: #1e293b;
  color: #60a5fa;
  border-color: #3b82f6;
}

.sp-profile-details {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px 8px;
  width: 100%;
}

.sp-profile-item {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.sp-profile-lbl {
  font-size: 9.5px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
}

.sp-profile-val {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sp-name-val {
  font-size: 12.5px;
  font-weight: 800;
  color: #0f172a;
}

html[data-theme="dark"] .sp-name-val {
  color: #f8fafc;
}

.sp-course-val {
  color: #2563eb;
  font-weight: 700;
}

/* 6 KPI Cards Grid */
.sp-kpis-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 10px;
}

.sp-kpi-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  box-shadow: var(--shadow-sm);
}

.sp-kpi-head {
  margin-bottom: 0;
}

.sp-kpi-title {
  font-size: 10px;
  font-weight: 800;
  color: var(--text-muted);
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.sp-kpi-body {
  display: flex;
  align-items: center;
  gap: 10px;
}

.sp-kpi-icon-wrap {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.icon-green { background: #d1fae5; color: #059669; }
.icon-blue { background: #dbeafe; color: #2563eb; }
.icon-purple { background: #ede9fe; color: #7c3aed; }
.icon-gold { background: #fef3c7; color: #d97706; }
.icon-darkgreen { background: #dcfce7; color: #15803d; }
.icon-teal { background: #ccfbf1; color: #0d9488; }
.icon-orange { background: #ffedd5; color: #ea580c; }

html[data-theme="dark"] .icon-green { background: #064e3b; color: #34d399; }
html[data-theme="dark"] .icon-blue { background: #1e3a8a; color: #60a5fa; }
html[data-theme="dark"] .icon-purple { background: #4c1d95; color: #a78bfa; }
html[data-theme="dark"] .icon-gold { background: #78350f; color: #fbbf24; }
html[data-theme="dark"] .icon-darkgreen { background: #14532d; color: #4ade80; }
html[data-theme="dark"] .icon-teal { background: #134e4a; color: #2dd4bf; }
html[data-theme="dark"] .icon-orange { background: #7c2d12; color: #fb923c; }

.sp-kpi-text-wrap {
  display: flex;
  flex-direction: column;
}

.sp-kpi-value {
  font-size: 19px;
  font-weight: 800;
  line-height: 1.1;
}

.sp-kpi-subtext {
  font-size: 9.5px;
  color: var(--text-muted);
  font-weight: 500;
  margin-top: 1px;
}

.text-green { color: #059669; }
.text-blue { color: #2563eb; }
.text-purple { color: #7c3aed; }
.text-gold { color: #d97706; }
.text-teal { color: #0d9488; }
.text-rose { color: #e11d48; }
.text-lime { color: #65a30d; }
.text-red { color: #dc2626; }
.text-orange { color: #ea580c; }

.sp-kpi-status-badge {
  font-size: 13.5px;
  font-weight: 800;
  letter-spacing: 0.5px;
}

.badge-elite-selected { color: #059669; }
.badge-elite-notselected { color: #e11d48; }
.badge-placement-yes { color: #0d9488; }
.badge-placement-no { color: #ea580c; }

/* Middle Section Grid */
.sp-mid-grid {
  display: grid;
  grid-template-columns: 260px 1fr 280px;
  gap: 14px;
}

.sp-summary-card {
  padding: 0 !important;
  overflow: hidden;
  height: 100%;
}

.sp-summary-list {
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.sp-summary-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px dashed var(--border);
}

.sp-summary-row:last-child {
  border-bottom: none;
}

.sp-summary-label-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 600;
}

.sp-summary-value {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--heading);
}

/* Center Table */
.sp-table-card {
  padding: 0 !important;
  overflow: hidden;
}

.sp-table-header-bar {
  background: #0f2744;
  color: #ffffff;
  padding: 10px 16px;
  display: flex;
  align-items: center;
}

.sp-table-header-bar h3 {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.6px;
  margin: 0;
  color: #ffffff;
}

.sp-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  text-align: center;
}

.sp-table th {
  background: #f8fafc;
  color: #475569;
  font-weight: 700;
  font-size: 11px;
  padding: 8px 10px;
  border-bottom: 1px solid #e2e8f0;
  text-align: center;
}

html[data-theme="dark"] .sp-table th {
  background: #1e293b;
  color: #94a3b8;
  border-color: #334155;
}

.sp-table td {
  padding: 8px 10px;
  border-bottom: 1px solid var(--border);
  color: var(--text);
}

.sp-table-overall-row {
  background: #f1f5f9;
  font-weight: 800;
  color: #0f172a;
}

html[data-theme="dark"] .sp-table-overall-row {
  background: #1e293b;
  color: #f8fafc;
}

.sp-level-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 10.5px;
  font-weight: 700;
}

.badge-excellent { background: #d1fae5; color: #047857; }
.badge-verygood { background: #e0f2fe; color: #0284c7; }
.badge-good { background: #fef3c7; color: #b45309; }
.badge-needsfocus { background: #fee2e2; color: #b91c1c; }

html[data-theme="dark"] .badge-excellent { background: #064e3b; color: #6ee7b7; }
html[data-theme="dark"] .badge-verygood { background: #0c4a6e; color: #7dd3fc; }
html[data-theme="dark"] .badge-good { background: #78350f; color: #fde68a; }
html[data-theme="dark"] .badge-needsfocus { background: #7f1d1d; color: #fca5a5; }

/* Donut & Status Subcolumn */
.sp-donut-card, .sp-status-card {
  padding: 0 !important;
  overflow: hidden;
}

.sp-donut-head {
  background: #0f2744;
  color: #ffffff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.6px;
  padding: 8px 12px;
  text-align: center;
}

.sp-donut-body {
  padding: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.sp-donut-svg-wrap {
  position: relative;
  width: 130px;
  height: 130px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sp-donut-center {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.sp-donut-number {
  font-size: 24px;
  font-weight: 900;
  color: #0f172a;
}

html[data-theme="dark"] .sp-donut-number {
  color: #f8fafc;
}

.sp-donut-label {
  font-size: 10px;
  font-weight: 600;
  color: var(--text-muted);
}

.sp-donut-legend {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 100%;
}

.sp-legend-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
}

.sp-legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 6px;
}

.bg-green { background: #10b981; }
.bg-blue { background: #2563eb; }
.bg-purple { background: #8b5cf6; }
.bg-gold { background: #f59e0b; }
.bg-lime { background: #84cc16; }
.bg-red { background: #ef4444; }

.sp-legend-text {
  flex: 1;
  color: var(--text-muted);
  font-weight: 600;
}

.sp-legend-val {
  font-weight: 800;
  color: var(--heading);
}

.sp-status-body {
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.sp-status-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
}

.sp-status-label-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  color: var(--text-muted);
}

.sp-status-icon-circle {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sp-status-tag {
  font-size: 11px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 4px;
}

.tag-elite { background: #d1fae5; color: #047857; }
.tag-placement { background: #ccfbf1; color: #0f766e; }
.tag-readiness { background: #ede9fe; color: #6d28d9; }
.tag-ontrack { background: #ffedd5; color: #c2410c; }
.tag-notselected { background: #fee2e2; color: #b91c1c; }

html[data-theme="dark"] .tag-elite { background: #064e3b; color: #6ee7b7; }
html[data-theme="dark"] .tag-placement { background: #134e4a; color: #5eead4; }
html[data-theme="dark"] .tag-readiness { background: #4c1d95; color: #c4b5fd; }
html[data-theme="dark"] .tag-ontrack { background: #7c2d12; color: #fdba74; }

/* Bottom Charts Grid */
.sp-charts-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.sp-chart-card {
  padding: 12px !important;
  display: flex;
  flex-direction: column;
}

.sp-chart-title {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 8px;
  text-transform: uppercase;
}

.sp-chart-svg-container {
  width: 100%;
  height: 140px;
}

.sp-chart-tooltip {
  position: absolute;
  display: none;
  background: #0f172a;
  color: #ffffff;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  pointer-events: none;
  z-index: 1000;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

/* Batch Summary Footer Bar */
.sp-batch-summary-bar {
  padding: 12px 18px !important;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.sp-summary-badge-group {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.sp-summary-pill-main {
  background: #0f2744;
  color: #ffffff;
  padding: 6px 12px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 6px;
  letter-spacing: 0.5px;
}

.sp-metric-col {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.sp-metric-col-lbl {
  font-size: 10px;
  font-weight: 700;
  color: var(--text-muted);
}

.sp-metric-col-val {
  font-size: 13.5px;
  font-weight: 800;
  color: var(--heading);
}

.sp-criteria-callout {
  display: flex;
  align-items: center;
  gap: 8px;
  border-left: 2px solid var(--border);
  padding-left: 14px;
  font-size: 10px;
  color: var(--text-muted);
}

.sp-star-icon {
  font-size: 16px;
  color: #0f2744;
}

html[data-theme="dark"] .sp-star-icon {
  color: #60a5fa;
}


/* ==========================================================================
   STUDENT REVIEW DASHBOARD (REFERENCE 2)
   ========================================================================== */
.sr-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  gap: 16px;
  flex-wrap: wrap;
}

.sr-header-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.sr-brand-badge {
  display: flex;
  align-items: center;
  gap: 10px;
}

.sr-dv-logo {
  height: 38px;
  width: auto;
  object-fit: contain;
}

.sr-brand-text {
  display: flex;
  flex-direction: column;
}

.sr-brand-name {
  font-size: 14px;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.1;
}

html[data-theme="dark"] .sr-brand-name {
  color: #f8fafc;
}

.sr-brand-tagline {
  font-size: 9.5px;
  font-weight: 600;
  color: var(--primary);
}

.sr-title-group {
  display: flex;
  flex-direction: column;
}

.sr-dashboard-title {
  font-size: 19px;
  font-weight: 900;
  letter-spacing: 0.5px;
  color: #0f2744;
  margin: 0;
  text-transform: uppercase;
}

html[data-theme="dark"] .sr-dashboard-title {
  color: #60a5fa;
}

.sr-dashboard-subtitle {
  font-size: 11px;
  color: #2563eb;
  font-weight: 600;
  margin: 2px 0 0;
  display: flex;
  align-items: center;
  gap: 4px;
}

html[data-theme="dark"] .sr-dashboard-subtitle {
  color: #93c5fd;
}

.sr-header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Review Dashboard Grid */
.sr-dashboard-layout {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 16px 20px;
  max-width: 1600px;
  margin: 0 auto;
  width: 100%;
}

.sr-kpi-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
}

.sr-kpi-card {
  padding: 12px 16px !important;
  display: flex;
  align-items: center;
  gap: 14px;
  border-radius: var(--radius-sm);
}

.sr-kpi-icon-wrap {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.sr-kpi-content {
  display: flex;
  flex-direction: column;
}

.sr-kpi-label {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
}

.sr-kpi-val {
  font-size: 24px;
  font-weight: 900;
  line-height: 1.1;
  display: flex;
  align-items: baseline;
  gap: 4px;
}

.sr-kpi-unit {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
}

.sr-kpi-sub-pct {
  font-size: 13px;
  font-weight: 600;
}

.sr-kpi-sub {
  font-size: 10.5px;
  color: var(--text-muted);
  font-weight: 500;
}

/* Reviews Table Card */
.sr-table-card {
  padding: 0 !important;
  overflow: hidden;
}

.sr-table-header-bar {
  background: #0f2744;
  color: #ffffff;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.sr-table-title {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.6px;
}

.sr-table-filters {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.sr-select, .sr-input {
  padding: 5px 10px;
  font-size: 12px;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  color: #0f172a;
}

html[data-theme="dark"] .sr-select, html[data-theme="dark"] .sr-input {
  background: #1e293b;
  border-color: #334155;
  color: #f8fafc;
}

.sr-reviews-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  text-align: center;
}

.sr-reviews-table th {
  background: #0284c7;
  color: #ffffff;
  font-weight: 700;
  font-size: 11px;
  padding: 8px 10px;
  border-bottom: 1px solid #0369a1;
  text-align: center;
}

.sr-reviews-table td {
  padding: 8px 10px;
  border-bottom: 1px solid var(--border);
  color: var(--text);
}

.sr-reviews-table tbody tr:hover {
  background: var(--row-hover);
}

.sr-batch-tag {
  background: #f1f5f9;
  color: #334155;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 11px;
}

html[data-theme="dark"] .sr-batch-tag {
  background: #1e293b;
  color: #94a3b8;
}

.sr-stars-wrap {
  display: inline-flex;
  align-items: center;
  gap: 1px;
  font-size: 13px;
  color: #f59e0b;
}

.sr-star.empty {
  color: #cbd5e1;
}

.sr-rating-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-weight: 800;
  font-size: 11.5px;
}

.badge-rate-high { background: #dcfce7; color: #15803d; }
.badge-rate-mid { background: #fef3c7; color: #b45309; }
.badge-rate-low { background: #fee2e2; color: #b91c1c; }

html[data-theme="dark"] .badge-rate-high { background: #14532d; color: #86efac; }
html[data-theme="dark"] .badge-rate-mid { background: #78350f; color: #fde68a; }
html[data-theme="dark"] .badge-rate-low { background: #7f1d1d; color: #fca5a5; }

.sr-review-summary-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.sr-sentiment-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.icon-positive { color: #10b981; }
.icon-neutral { color: #f59e0b; }
.icon-negative { color: #ef4444; }

.sr-review-text {
  font-size: 12px;
  color: var(--text);
}

/* Pagination Bar in Student Review Table */
.sr-pagination-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  background: var(--surface);
  border-top: 1px solid var(--border);
  gap: 12px;
  flex-wrap: wrap;
}

.sr-page-info {
  font-size: 11.5px;
  color: var(--text-muted);
}

.sr-page-info strong {
  color: var(--heading);
  font-weight: 700;
}

.sr-page-nav {
  display: flex;
  align-items: center;
  gap: 4px;
}

.sr-page-btn {
  padding: 4px 9px;
  font-size: 11.5px;
  font-weight: 700;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  cursor: pointer;
  transition: all var(--ease);
  min-width: 28px;
  text-align: center;
}

.sr-page-btn:hover:not(:disabled) {
  background: var(--row-hover);
  border-color: var(--border-strong);
}

.sr-page-btn.is-active {
  background: #0284c7;
  border-color: #0284c7;
  color: #ffffff;
}

.sr-page-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.sr-page-dots {
  padding: 0 4px;
  font-size: 11px;
  color: var(--text-muted);
}

/* Bottom Analytics Grid */
.sr-analytics-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.sr-analytic-card {
  padding: 12px 14px !important;
  display: flex;
  flex-direction: column;
}

.sr-analytic-head {
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 10px;
  text-transform: uppercase;
}

/* Donut in Reviews */
.sr-dist-body {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-content: center;
  height: 100%;
}

.sr-dist-donut-wrap {
  position: relative;
  width: 130px;
  height: 130px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.sr-dist-center {
  position: absolute;
  text-align: center;
}

.sr-dist-total-val {
  font-size: 22px;
  font-weight: 900;
  color: #0f172a;
}

html[data-theme="dark"] .sr-dist-total-val {
  color: #f8fafc;
}

.sr-dist-total-lbl {
  font-size: 9px;
  color: var(--text-muted);
  font-weight: 600;
}

.sr-dist-legend {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.sr-legend-row {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 10.5px;
}

.sr-legend-color {
  width: 8px;
  height: 8px;
  border-radius: 2px;
  flex-shrink: 0;
}

.sr-legend-label {
  color: var(--text-muted);
  font-weight: 600;
}

.sr-legend-pct {
  font-weight: 800;
  margin-left: auto;
}

/* Category Bars */
.sr-category-bars-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 4px 6px;
}

.sr-cat-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
}

.sr-cat-info {
  display: flex;
  align-items: center;
  gap: 4px;
  width: 90px;
  font-weight: 600;
  color: var(--text);
  font-size: 10.5px;
}

.sr-cat-bar-track {
  flex: 1;
  height: 8px;
  background: var(--border);
  border-radius: 4px;
  overflow: hidden;
}

.sr-cat-bar-fill {
  height: 100%;
  border-radius: 4px;
}

.sr-cat-val {
  width: 24px;
  text-align: right;
  font-weight: 700;
  color: var(--heading);
  font-size: 11px;
}

.sr-cat-axis {
  display: flex;
  justify-content: space-between;
  margin-left: 98px;
  margin-right: 28px;
  font-size: 9px;
  color: var(--text-muted);
  padding-top: 4px;
}

/* Batch Bars */
.sr-batch-bars-body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 4px 6px;
}

.sr-batch-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 10.5px;
}

.sr-batch-name {
  width: 60px;
  font-weight: 700;
  color: var(--text);
}

.sr-batch-track {
  flex: 1;
  height: 8px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
}

.sr-batch-fill {
  height: 100%;
  background: #2563eb;
  border-radius: 2px;
}

.sr-batch-val {
  width: 20px;
  text-align: right;
  font-weight: 700;
  font-size: 10.5px;
  color: var(--heading);
}

.sr-batch-axis {
  display: flex;
  justify-content: space-between;
  margin-left: 68px;
  margin-right: 24px;
  font-size: 8.5px;
  color: var(--text-muted);
  padding-top: 4px;
}

.sr-batch-axis-title {
  text-align: center;
  font-size: 9.5px;
  color: var(--text-muted);
  font-weight: 600;
  margin-top: 2px;
}

/* Trend in Reviews */
.sr-trend-svg-box {
  width: 100%;
  height: 150px;
}

/* Footer in Reviews */
.sr-footer-card {
  padding: 12px 18px !important;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  text-align: center;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.sr-footer-star {
  font-size: 20px;
  color: #0f2744;
}

html[data-theme="dark"] .sr-footer-star {
  color: #60a5fa;
}

.sr-footer-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 12.5px;
  color: var(--text);
}

.sr-footer-text strong {
  color: #0f2744;
  font-size: 13.5px;
}

html[data-theme="dark"] .sr-footer-text strong {
  color: #f8fafc;
}

/* ==========================================================================
   RESPONSIVE MEDIA QUERIES FOR DASHBOARDS
   ========================================================================== */
@media (max-width: 1200px) {
  .sp-top-grid, .sp-mid-grid {
    grid-template-columns: 1fr;
  }

  .sp-kpis-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .sp-charts-grid, .sr-analytics-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .sr-kpi-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .sp-kpis-grid, .sr-kpi-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .sp-charts-grid, .sr-analytics-grid {
    grid-template-columns: 1fr;
  }

  .sp-header, .sr-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .sp-header-actions, .sr-header-actions {
    width: 100%;
    justify-content: space-between;
    flex-wrap: wrap;
  }

  .sp-batch-summary-bar {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 480px) {
  .sp-kpis-grid, .sr-kpi-grid {
    grid-template-columns: 1fr;
  }
}




