@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500;600;700&family=Outfit:wght@400;500;600;700;800&display=swap');

/* ==========================================================================
   AI AGENT CONSOLE - PRODUCTION SAAS DESIGN SYSTEM
   ========================================================================== */

:root {
  color-scheme: light;
  
  /* Font Stacks */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-display: 'Outfit', 'Inter', -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;

  /* Spacing Tokens */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;

  /* Base Light Theme Tokens (Refined for high contrast & elegance) */
  --bg-app: #f6f8fc;
  --bg-app-rgb: 246, 248, 252;
  --bg-surface: #ffffff;
  --bg-surface-elevated: #ffffff;
  --bg-surface-soft: #f1f5f9;
  --bg-surface-hover: #e2e8f0;
  
  --text-main: #1e293b;
  --text-heading: #0f172a;
  --text-muted: #64748b;
  --text-subtle: #94a3b8;
  
  --border-subtle: #e2e8f0;
  --border-strong: #cbd5e1;
  --border-glass: rgba(226, 232, 240, 0.85);
  
  /* Accent Tokens (Default: Emerald Teal) */
  --brand: #0d9488;
  --brand-hover: #0f766e;
  --brand-light: #14b8a6;
  --brand-soft: #f0fdfa;
  --brand-soft-border: #ccfbf1;
  --brand-glow: rgba(13, 148, 136, 0.22);
  --brand-rgb: 13, 148, 136;
  --brand-contrast: #ffffff;

  /* Semantic Status Colors */
  --color-success: #10b981;
  --color-success-hover: #059669;
  --color-success-soft: #ecfdf5;
  --color-success-border: #a7f3d0;
  
  --color-warning: #f59e0b;
  --color-warning-hover: #d97706;
  --color-warning-soft: #fffbeb;
  --color-warning-border: #fde68a;
  
  --color-danger: #ef4444;
  --color-danger-hover: #dc2626;
  --color-danger-soft: #fef2f2;
  --color-danger-border: #fecaca;
  
  --color-info: #0ea5e9;
  --color-info-hover: #0284c7;
  --color-info-soft: #f0f9ff;
  --color-info-border: #bae6fd;
  
  --color-purple: #8b5cf6;
  --color-purple-soft: #f5f3ff;
  --color-purple-border: #ddd6fe;
  
  /* Elevation & Shadows */
  --shadow-xs: 0 1px 2px 0 rgba(15, 23, 42, 0.04);
  --shadow-sm: 0 2px 6px -1px rgba(15, 23, 42, 0.06), 0 1px 4px -1px rgba(15, 23, 42, 0.03);
  --shadow-md: 0 8px 18px -2px rgba(15, 23, 42, 0.08), 0 3px 6px -2px rgba(15, 23, 42, 0.03);
  --shadow-lg: 0 18px 28px -4px rgba(15, 23, 42, 0.09), 0 6px 10px -3px rgba(15, 23, 42, 0.03);
  --shadow-xl: 0 24px 38px -6px rgba(15, 23, 42, 0.12);
  --shadow-glow: 0 0 24px var(--brand-glow);
  
  /* Geometry & Radii */
  --radius-xs: 6px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-full: 9999px;
  
  --sidebar-w: 270px;
  --topbar-h: 68px;
  --transition-fast: 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ==========================================================================
   COLOR PALETTES (ACCENTS)
   ========================================================================== */

/* Blue / Indigo */
:root[data-accent="blue"] {
  --brand: #2563eb;
  --brand-hover: #1d4ed8;
  --brand-light: #3b82f6;
  --brand-soft: #eff6ff;
  --brand-soft-border: #dbeafe;
  --brand-glow: rgba(37, 99, 235, 0.25);
  --brand-rgb: 37, 99, 235;
}

/* Violet / Cyber Purple */
:root[data-accent="violet"] {
  --brand: #7c3aed;
  --brand-hover: #6d28d9;
  --brand-light: #8b5cf6;
  --brand-soft: #f5f3ff;
  --brand-soft-border: #ede9fe;
  --brand-glow: rgba(124, 58, 237, 0.25);
  --brand-rgb: 124, 58, 237;
}

/* Rose / Crimson */
:root[data-accent="rose"] {
  --brand: #e11d48;
  --brand-hover: #be123c;
  --brand-light: #f43f5e;
  --brand-soft: #fff1f2;
  --brand-soft-border: #ffe4e6;
  --brand-glow: rgba(225, 29, 72, 0.25);
  --brand-rgb: 225, 29, 72;
}

/* Amber / Warm Gold */
:root[data-accent="amber"] {
  --brand: #d97706;
  --brand-hover: #b45309;
  --brand-light: #f59e0b;
  --brand-soft: #fffbeb;
  --brand-soft-border: #fef3c7;
  --brand-glow: rgba(217, 119, 6, 0.25);
  --brand-rgb: 217, 119, 6;
}

/* Cyan / Tech Aqua */
:root[data-accent="cyan"] {
  --brand: #0891b2;
  --brand-hover: #0e7490;
  --brand-light: #06b6d4;
  --brand-soft: #ecfeff;
  --brand-soft-border: #cffafe;
  --brand-glow: rgba(8, 145, 178, 0.25);
  --brand-rgb: 8, 145, 178;
}

/* Slate / Obsidian Modern */
:root[data-accent="slate"] {
  --brand: #475569;
  --brand-hover: #334155;
  --brand-light: #64748b;
  --brand-soft: #f8fafc;
  --brand-soft-border: #e2e8f0;
  --brand-glow: rgba(71, 85, 105, 0.25);
  --brand-rgb: 71, 85, 105;
}

/* ==========================================================================
   DARK MODE & MIDNIGHT THEMES
   ========================================================================== */

:root[data-theme="dark"] {
  color-scheme: dark;
  
  --bg-app: #060913;
  --bg-app-rgb: 6, 9, 19;
  --bg-surface: rgba(12, 18, 38, 0.48);
  --bg-surface-elevated: rgba(16, 25, 52, 0.58);
  --bg-surface-soft: rgba(14, 22, 46, 0.42);
  --bg-surface-hover: rgba(26, 38, 76, 0.65);
  
  --text-main: #e2e8f0;
  --text-heading: #ffffff;
  --text-muted: #94a3b8;
  --text-subtle: #64748b;
  
  --border-subtle: rgba(255, 255, 255, 0.12);
  --border-strong: rgba(255, 255, 255, 0.22);
  --border-glass: rgba(255, 255, 255, 0.16);
  
  --brand: #38bdf8;
  --brand-hover: #0ea5e9;
  --brand-light: #7dd3fc;
  --brand-soft: rgba(56, 189, 248, 0.15);
  --brand-soft-border: rgba(56, 189, 248, 0.35);
  --brand-glow: rgba(56, 189, 248, 0.45);
  --brand-rgb: 56, 189, 248;
  
  --color-success-soft: rgba(16, 185, 129, 0.15);
  --color-success-border: rgba(16, 185, 129, 0.35);
  --color-warning-soft: rgba(245, 158, 11, 0.15);
  --color-warning-border: rgba(245, 158, 11, 0.35);
  --color-danger-soft: rgba(239, 68, 68, 0.15);
  --color-danger-border: rgba(239, 68, 68, 0.35);
  --color-info-soft: rgba(14, 165, 233, 0.15);
  --color-info-border: rgba(14, 165, 233, 0.35);
  --color-purple-soft: rgba(139, 92, 246, 0.15);
  --color-purple-border: rgba(139, 92, 246, 0.35);
  
  --shadow-xs: 0 1px 2px 0 rgba(0, 0, 0, 0.5);
  --shadow-sm: 0 2px 8px -1px rgba(0, 0, 0, 0.6);
  --shadow-md: 0 12px 28px -3px rgba(0, 0, 0, 0.7), 0 0 1px 1px rgba(255, 255, 255, 0.05);
  --shadow-lg: 0 24px 48px -5px rgba(0, 0, 0, 0.8), 0 0 20px -2px var(--brand-glow);
}

:root[data-theme="midnight"] {
  color-scheme: dark;
  
  --bg-app: #030611;
  --bg-app-rgb: 3, 6, 17;
  --bg-surface: rgba(10, 15, 36, 0.48);
  --bg-surface-elevated: rgba(16, 23, 54, 0.58);
  --bg-surface-soft: rgba(13, 20, 46, 0.42);
  --bg-surface-hover: rgba(23, 33, 74, 0.65);
  
  --text-main: #f1f5f9;
  --text-heading: #ffffff;
  --text-muted: #94a3b8;
  --text-subtle: #64748b;
  
  --border-subtle: rgba(255, 255, 255, 0.12);
  --border-strong: rgba(255, 255, 255, 0.22);
  --border-glass: rgba(255, 255, 255, 0.16);
  
  --brand-soft: rgba(var(--brand-rgb), 0.2);
  --brand-soft-border: rgba(var(--brand-rgb), 0.4);
  --brand-glow: rgba(var(--brand-rgb), 0.55);
  
  --shadow-md: 0 14px 34px -3px rgba(0, 0, 0, 0.85), 0 0 1px 1px rgba(255, 255, 255, 0.06);
  --shadow-lg: 0 28px 56px -5px rgba(0, 0, 0, 0.95), 0 0 24px -2px var(--brand-glow);
}

/* ==========================================================================
   RESET & GLOBAL STYLES
   ========================================================================== */

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

html {
  font-family: var(--font-sans);
  font-size: 14.5px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-app);
  background-image: 
    radial-gradient(circle 700px at 15% 15%, rgba(var(--brand-rgb), 0.28) 0%, transparent 70%),
    radial-gradient(circle 800px at 88% 22%, rgba(var(--brand-rgb), 0.24) 0%, transparent 65%),
    radial-gradient(circle 850px at 50% 85%, rgba(var(--brand-rgb), 0.18) 0%, transparent 70%),
    radial-gradient(ellipse 90% 45% at 50% -5%, rgba(var(--brand-rgb), 0.22) 0%, transparent 70%);
  background-attachment: fixed;
  color: var(--text-main);
  height: 100vh;
  max-height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

body.role-company-admin,
body.role-super-admin {
  color-scheme: light !important;
  background-color: #f4f6fa !important;
  background-image: 
    radial-gradient(circle 850px at 12% 10%, rgba(219, 234, 254, 0.65) 0%, transparent 60%),
    radial-gradient(circle 950px at 85% 18%, rgba(238, 242, 255, 0.75) 0%, transparent 65%),
    radial-gradient(circle 900px at 50% 85%, rgba(241, 245, 249, 0.85) 0%, transparent 70%),
    radial-gradient(ellipse 95% 50% at 50% -2%, rgba(255, 255, 255, 0.95) 0%, transparent 60%),
    linear-gradient(180deg, #f8fafc 0%, #f1f5f9 50%, #e9eef5 100%) !important;
  background-attachment: fixed !important;
  color: #0f172a !important;
}

/* SVG Sprite Container */
.svg-sprite {
  display: none !important;
}

.icon {
  width: 1.25rem;
  height: 1.25rem;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
  display: inline-block;
  vertical-align: middle;
  flex-shrink: 0;
}

.inline-icon {
  width: 1rem;
  height: 1rem;
  display: inline-block;
  vertical-align: -0.125em;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
  flex-shrink: 0;
}

a {
  color: var(--brand);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--brand-hover);
}

/* ==========================================================================
   CORE LAYOUT SHELL (Apple iOS 26 Viewport Frame Fit)
   ========================================================================== */

.shell {
  display: flex;
  height: 100vh;
  max-height: 100vh;
  width: 100%;
  position: relative;
  overflow: hidden;
}

.nav-toggle {
  display: none;
}

/* Mobile Sidebar Backdrop Overlay */
.sidebar-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(2, 6, 23, 0.65);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 38;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-normal);
}

/* Sidebar - Apple iOS 26 Frosted Translucent Glass */
.sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.14) 0%, rgba(255, 255, 255, 0.04) 30%, rgba(255, 255, 255, 0.01) 70%, rgba(10, 16, 36, 0.35) 100%), rgba(7, 11, 26, 0.32);
  backdrop-filter: blur(40px) saturate(240%) brightness(112%);
  -webkit-backdrop-filter: blur(40px) saturate(240%) brightness(112%);
  border-right: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow: 14px 0 45px rgba(0, 0, 0, 0.38), inset -1px 0 1.5px rgba(255, 255, 255, 0.2);
  display: flex;
  flex-direction: column;
  position: relative;
  height: 100vh;
  z-index: 40;
  transition: transform var(--transition-normal);
}

.sidebar-inner {
  padding: 1.25rem 1rem;
  display: flex;
  flex-direction: column;
  height: 100%;
  gap: 1.25rem;
  overflow-y: auto;
}

/* Brand Identity */
.brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  text-decoration: none;
  color: var(--text-heading);
  padding: 0.4rem 0.6rem;
  border-radius: var(--radius-md);
  transition: background var(--transition-fast);
  flex-shrink: 0;
}

.brand:hover {
  background: var(--bg-surface-soft);
}

.brand-mark {
  width: 2.4rem;
  height: 2.4rem;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, var(--brand), var(--brand-light));
  color: var(--brand-contrast);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px var(--brand-glow);
  position: relative;
}

.brand-mark .icon {
  width: 1.3rem;
  height: 1.3rem;
}

.brand-copy {
  display: flex;
  flex-direction: column;
}

.brand-copy strong {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
  color: var(--text-heading);
  line-height: 1.2;
}

.brand-copy small {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

/* Active Workspace Card */
.workspace-card {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 0.85rem;
  background: var(--bg-surface-soft);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  text-decoration: none;
  color: var(--text-main);
  transition: all var(--transition-fast);
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
}

.workspace-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--brand);
  opacity: 0.9;
}

.workspace-card {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 0.85rem;
  border-radius: var(--radius-md);
  background: rgba(15, 23, 42, 0.65);
  border: 1px solid rgba(56, 189, 248, 0.2);
  text-decoration: none;
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.workspace-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: linear-gradient(180deg, #38bdf8 0%, #818cf8 100%);
  box-shadow: 0 0 10px rgba(56, 189, 248, 0.6);
  opacity: 0.9;
}

.workspace-card:hover {
  border-color: rgba(56, 189, 248, 0.45);
  background: rgba(15, 23, 42, 0.85);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45), 0 0 16px rgba(56, 189, 248, 0.15);
}

.workspace-avatar {
  width: 2.2rem;
  height: 2.2rem;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.2) 0%, rgba(129, 140, 248, 0.25) 100%);
  border: 1px solid rgba(56, 189, 248, 0.3);
  color: #38bdf8;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 0 10px rgba(56, 189, 248, 0.2);
}

.workspace-card span {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.workspace-card small {
  font-size: 0.68rem;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.workspace-card strong {
  font-size: 0.88rem;
  color: var(--text-heading);
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Nav Menu */
.nav {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  flex: 1;
}

.nav a {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.88rem;
  text-decoration: none;
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  border-left: 3px solid transparent;
}

.nav a .nav-icon {
  width: 1.25rem;
  height: 1.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-subtle);
  transition: all var(--transition-fast);
}

.nav a:hover {
  color: #f8fafc;
  background: rgba(56, 189, 248, 0.08);
  transform: translateX(4px);
  border-left-color: rgba(56, 189, 248, 0.4);
}

.nav a:hover .nav-icon {
  color: #38bdf8;
  filter: drop-shadow(0 0 6px rgba(56, 189, 248, 0.5));
}

.nav a.active {
  color: #38bdf8;
  background: linear-gradient(90deg, rgba(56, 189, 248, 0.16) 0%, rgba(56, 189, 248, 0.03) 100%);
  font-weight: 600;
  border-left: 3px solid #38bdf8;
  box-shadow: inset 0 0 16px rgba(56, 189, 248, 0.08), 0 0 12px rgba(56, 189, 248, 0.15);
}

.nav a.active .nav-icon {
  color: #38bdf8;
  filter: drop-shadow(0 0 8px rgba(56, 189, 248, 0.6));
}

.nav-section-title {
  font-size: 0.7rem;
  color: #38bdf8;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.85rem 0.85rem 0.35rem 0.85rem;
  margin-top: 0.75rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Sidebar Footer / Logout */
.logout {
  margin-top: auto;
  padding-top: 0.85rem;
  border-top: 1px solid var(--border-subtle);
}

/* ==========================================================================
   MAIN CONTENT AREA & TOPBAR
   ========================================================================== */

.main {
  flex: 1;
  display: flex;
  flex-direction: column;
  height: 100vh;
  max-height: 100vh;
  min-width: 0;
  overflow: hidden;
  position: relative;
}

.topbar {
  height: 54px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.14) 0%, rgba(255, 255, 255, 0.03) 40%, rgba(10, 15, 32, 0.35) 100%), rgba(7, 11, 25, 0.30);
  backdrop-filter: blur(40px) saturate(240%) brightness(112%);
  -webkit-backdrop-filter: blur(40px) saturate(240%) brightness(112%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.32), inset 0 -1px 1.5px rgba(255, 255, 255, 0.18);
  position: sticky;
  top: 0;
  z-index: 30;
  padding: 0 1.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-shrink: 0;
}

.topbar-title {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.breadcrumb {
  font-size: 0.74rem;
  color: var(--text-muted);
  font-weight: 500;
  letter-spacing: 0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.topbar-title h1 {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-heading);
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

/* Status Indicator Beacon */
.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-full);
  background: var(--color-success-soft);
  border: 1px solid var(--color-success-border);
  color: var(--color-success);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.status-dot {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: var(--color-success);
  box-shadow: 0 0 8px var(--color-success);
  position: relative;
  flex-shrink: 0;
}

.status-dot::before {
  content: '';
  position: absolute;
  inset: -3.5px;
  border-radius: 50%;
  border: 1.5px solid var(--color-success);
  animation: radarPingDot 2.2s cubic-bezier(0, 0, 0.2, 1) infinite;
}

@keyframes radarPingDot {
  0% { transform: scale(0.8); opacity: 1; }
  75%, 100% { transform: scale(2.6); opacity: 0; }
}

/* Quick Theme Toggle Button */
.theme-quick-btn {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: var(--text-muted);
  width: 2.25rem;
  height: 2.25rem;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.theme-quick-btn:hover {
  color: var(--text-heading);
  border-color: rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.12);
}

/* User Profile Chip - Apple Glass Capsule */
.profile-chip {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.3rem 0.85rem 0.3rem 0.35rem;
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-full);
  color: var(--text-heading);
  font-size: 0.82rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.profile-chip:hover {
  border-color: rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.1);
}

.profile-avatar {
  width: 1.85rem;
  height: 1.85rem;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brand), var(--brand-light));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mobile-menu {
  display: none;
}

/* Page Enter Animation & Viewport Fit (Never Compressing, Always Scrollable) */
.page-enter {
  padding: 1.25rem 1.75rem 6rem 1.75rem !important;
  flex: 1 1 0% !important;
  min-height: 0 !important;
  max-height: calc(100vh - 54px) !important;
  height: 100% !important;
  max-width: 1440px;
  width: 100%;
  margin: 0 auto;
  display: flex !important;
  flex-direction: column !important;
  gap: 1.35rem;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  box-sizing: border-box !important;
  -webkit-overflow-scrolling: touch !important;
  animation: fadeIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.page-enter > * {
  flex-shrink: 0 !important;
  min-height: fit-content !important;
  height: auto !important;
  box-sizing: border-box !important;
  overflow: visible !important;
}

.page-enter.chat-page-enter,
.page-enter:has(.chat-shell) {
  height: calc(100vh - 54px) !important;
  max-height: calc(100vh - 54px) !important;
  min-height: 0 !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  display: flex !important;
  flex-direction: column !important;
  padding: 0.85rem 1.4rem 1.25rem 1.4rem !important;
  gap: 0.75rem !important;
  box-sizing: border-box !important;
}

/* Apple iOS Visible & Sleek Scrollbar */
.page-enter::-webkit-scrollbar,
.chat-log::-webkit-scrollbar,
.content-preview::-webkit-scrollbar {
  width: 7px !important;
  height: 7px !important;
}
.page-enter::-webkit-scrollbar-track,
.chat-log::-webkit-scrollbar-track,
.content-preview::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.03) !important;
  border-radius: 9999px !important;
}
.page-enter::-webkit-scrollbar-thumb,
.chat-log::-webkit-scrollbar-thumb,
.content-preview::-webkit-scrollbar-thumb {
  background: rgba(15, 23, 42, 0.22) !important;
  border-radius: 9999px !important;
  border: 1.5px solid transparent !important;
  background-clip: content-box !important;
}
.page-enter::-webkit-scrollbar-thumb:hover,
.chat-log::-webkit-scrollbar-thumb:hover,
.content-preview::-webkit-scrollbar-thumb:hover {
  background: rgba(15, 23, 42, 0.42) !important;
  border: 1.5px solid transparent !important;
  background-clip: content-box !important;
}

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

/* ==========================================================================
   PANELS, CARDS & SECTIONS (Apple iOS 26 Frosted Translucent Glass)
   ========================================================================== */

.panel, .card {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.16) 0%, rgba(255, 255, 255, 0.05) 35%, rgba(255, 255, 255, 0.01) 70%, rgba(56, 189, 248, 0.06) 100%), rgba(10, 16, 36, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 20px;
  padding: 1.35rem;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45), inset 0 1.5px 2px 0 rgba(255, 255, 255, 0.55), inset 0 -1px 1.5px 0 rgba(0, 0, 0, 0.25);
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
  position: relative;
  overflow: visible;
  flex-shrink: 0;
  min-height: fit-content;
  height: auto;
  backdrop-filter: blur(40px) saturate(240%) brightness(112%);
  -webkit-backdrop-filter: blur(40px) saturate(240%) brightness(112%);
  transition: border-color var(--transition-normal), box-shadow var(--transition-normal), transform var(--transition-fast);
}

.panel::before, .card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1.5px;
  background: linear-gradient(90deg, transparent, rgba(var(--brand-rgb), 0.8), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.panel:hover::before, .card:hover::before {
  opacity: 1;
}

.panel:hover, .card:hover {
  border-color: rgba(var(--brand-rgb), 0.4);
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.5), inset 0 1px 1px rgba(255, 255, 255, 0.22);
}

.card-hover:hover {
  border-color: #38bdf8;
  transform: translateY(-3px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55), 0 0 24px rgba(56, 189, 248, 0.18);
}

.panel-head, .card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.section-kicker {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--brand);
  margin-bottom: 0.15rem;
  display: inline-block;
}

.panel-head h2, .card-header h3, .panel-head h3 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text-heading);
}

.subtitle {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 0.2rem;
  line-height: 1.45;
}

.stat-icon {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--radius-md);
  background: var(--brand-soft);
  color: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* Page Header */
.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
  padding-bottom: 0.25rem;
}

.page-title {
  font-family: var(--font-display);
  font-size: 1.7rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text-heading);
  line-height: 1.2;
}

.page-header p {
  color: var(--text-muted);
  font-size: 0.92rem;
  margin-top: 0.25rem;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

/* Grid Layouts */
.grid {
  display: grid;
  gap: 1.5rem;
}

.grid.two {
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
}

.grid.three {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.grid.four {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.grid.sidebar-grid {
  grid-template-columns: 320px 1fr;
}

/* Stat Cards & Metrics */
.metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
}

.metric-card {
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.08) 0%, rgba(255, 255, 255, 0.015) 40%, rgba(13, 19, 40, 0.48) 100%), rgba(9, 14, 28, 0.44);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.35rem;
  display: flex;
  align-items: center;
  gap: 1.1rem;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.4), inset 0 1px 1.5px rgba(255, 255, 255, 0.28);
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(28px) saturate(200%) contrast(106%);
  -webkit-backdrop-filter: blur(28px) saturate(200%) contrast(106%);
}

.metric-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1.5px;
  background: linear-gradient(90deg, transparent, #38bdf8, transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.metric-card:hover {
  border-color: rgba(56, 189, 248, 0.45);
  transform: translateY(-3px);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.55), 0 0 20px rgba(56, 189, 248, 0.2);
}

.metric-card:hover::before {
  opacity: 1;
}

.metric-icon {
  width: 3.2rem;
  height: 3.2rem;
  min-width: 3.2rem;
  min-height: 3.2rem;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 0 16px rgba(0, 0, 0, 0.25);
  transition: all 0.25s ease;
}

.metric-card:hover .metric-icon {
  transform: scale(1.08) rotate(3deg);
}

.metric-icon .icon {
  width: 1.65rem;
  height: 1.65rem;
}

.metric-label {
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  display: block;
}

.metric-value {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text-heading);
  line-height: 1.15;
  margin-top: 0.2rem;
  margin-bottom: 0;
}

/* ==========================================================================
   BUTTONS & FORM CONTROLS
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.6rem 1.15rem;
  border-radius: 10px;
  font-family: var(--font-sans);
  font-size: 0.86rem;
  font-weight: 600;
  line-height: 1.2;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all var(--transition-fast);
  text-decoration: none;
  white-space: nowrap;
  user-select: none;
}

.btn-primary {
  background: linear-gradient(135deg, #1d4ed8 0%, #0284c7 100%);
  color: #ffffff !important;
  border: 1px solid rgba(56, 189, 248, 0.45);
  box-shadow: 0 4px 18px rgba(37, 99, 235, 0.4), inset 0 1px 1px rgba(255, 255, 255, 0.35);
  position: relative;
  overflow: hidden;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 50%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.25), transparent);
  animation: buttonGleamSweep 4.5s ease-in-out infinite;
  pointer-events: none;
}

.btn-primary:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(37, 99, 235, 0.6), 0 0 20px rgba(56, 189, 248, 0.5);
  border-color: #38bdf8;
  color: #ffffff !important;
}

.btn-primary:active:not(:disabled) {
  transform: translateY(0);
}

.btn-secondary {
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #e2e8f0;
  backdrop-filter: blur(12px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.btn-secondary:hover:not(:disabled) {
  background: rgba(26, 38, 68, 0.85);
  border-color: rgba(56, 189, 248, 0.45);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.4), 0 0 14px rgba(56, 189, 248, 0.2);
}

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
}

.btn-ghost:hover:not(:disabled) {
  background: rgba(56, 189, 248, 0.1);
  color: #38bdf8;
}

.btn-danger, .btn-stop {
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.35);
  color: #f87171;
}

.btn-danger:hover:not(:disabled), .btn-stop:hover:not(:disabled) {
  background: rgba(239, 68, 68, 0.25);
  border-color: #ef4444;
  color: #ffffff;
  box-shadow: 0 4px 16px rgba(239, 68, 68, 0.4);
  transform: translateY(-1.5px);
}

.btn-rollback {
  background: var(--color-warning-soft);
  color: #b45309;
  border: 1px solid var(--color-warning-border);
}

:root[data-theme="dark"] .btn-rollback,
:root[data-theme="midnight"] .btn-rollback {
  color: #fbbf24;
}

.btn-rollback:hover:not(:disabled) {
  background: var(--color-warning);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.35);
  transform: translateY(-1px);
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

.btn-full {
  width: 100%;
}

.btn-sm {
  padding: 0.4rem 0.75rem;
  font-size: 0.78rem;
  border-radius: var(--radius-xs);
}

/* Forms, Inputs & Groups */
.stack {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.form-label, label {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-heading);
}

input:not([type="radio"]):not([type="checkbox"]), textarea, select, .input {
  font-family: var(--font-sans);
  font-size: 0.88rem;
  padding: 0.65rem 0.9rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface-soft);
  color: var(--text-main);
  outline: none;
  transition: all var(--transition-fast);
  width: 100%;
}

input:not([type="radio"]):not([type="checkbox"]):focus, textarea:focus, select:focus, .input:focus {
  border-color: var(--brand);
  background: var(--bg-surface);
  box-shadow: 0 0 0 3px var(--brand-soft);
}

input::placeholder, textarea::placeholder {
  color: var(--text-subtle);
}

/* ==========================================================================
   BADGES, PILLS & STATUS TAGS
   ========================================================================== */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  background: var(--bg-surface-soft);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
}

.badge.ready, .badge.COMPLETED, .badge.completed, .badge.active, .badge-success {
  background: var(--color-success-soft);
  border-color: var(--color-success-border);
  color: var(--color-success);
}

.badge.QUEUED, .badge.queued, .badge.pending, .badge-warning {
  background: var(--color-warning-soft);
  border-color: var(--color-warning-border);
  color: var(--color-warning);
}

.badge.CRAWLING, .badge.EXTRACTING, .badge.DEDUPLICATING, .badge.CLEANING, 
.badge.CHUNKING, .badge.EMBEDDING, .badge.STORING, .badge.processing, .badge-primary {
  background: var(--brand-soft);
  border-color: var(--brand-soft-border);
  color: var(--brand);
}

.badge.FAILED, .badge.failed, .badge.error, .badge.ROLLBACK_FAILED, .badge-danger {
  background: var(--color-danger-soft);
  border-color: var(--color-danger-border);
  color: var(--color-danger);
}

.badge.STOPPED, .badge.STOPPING {
  background: var(--color-warning-soft);
  color: var(--color-warning);
  border: 1px solid var(--color-warning-border);
}

.badge.ROLLED_BACK {
  background: var(--color-purple-soft);
  color: var(--color-purple);
  border: 1px solid var(--color-purple-border);
}

.badge.badge-neutral {
  background: var(--bg-surface-hover);
  color: var(--text-muted);
}

/* User Role Badges */
.role-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: var(--radius-xs);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.role-tag.super-admin {
  background: rgba(168, 85, 247, 0.15);
  color: #c084fc;
  border: 1px solid rgba(168, 85, 247, 0.3);
}

.role-tag.company-admin {
  background: var(--brand-soft);
  color: var(--brand);
  border: 1px solid var(--brand-soft-border);
}

.role-tag.member {
  background: var(--bg-surface-soft);
  color: var(--text-muted);
  border: 1px solid var(--border-subtle);
}

/* ==========================================================================
   TABLES & DATA LISTS
   ========================================================================== */

.table-wrap, .table-container {
  width: 100%;
  overflow-x: auto;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.06) 0%, rgba(13, 19, 40, 0.48) 100%), rgba(8, 12, 26, 0.42);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4), inset 0 1px 1.5px rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(32px) saturate(210%) contrast(106%);
  -webkit-backdrop-filter: blur(32px) saturate(210%) contrast(106%);
}

table, .table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.88rem;
}

thead th, .table thead th {
  background: rgba(16, 24, 52, 0.75);
  padding: 0.95rem 1.15rem;
  font-weight: 700;
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #94a3b8;
  border-bottom: 1px solid var(--border-subtle);
  white-space: nowrap;
}

tbody td, .table tbody td {
  padding: 1rem 1.15rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  color: var(--text-main);
  vertical-align: middle;
  transition: background 0.2s ease;
}

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

tbody tr:hover td, .table tbody tr:hover td {
  background: rgba(56, 189, 248, 0.08);
  color: #ffffff;
}

.row-title {
  font-weight: 700;
  color: #ffffff;
  display: block;
}

.row-subtitle {
  font-size: 0.76rem;
  color: var(--text-muted);
  display: block;
  margin-top: 0.15rem;
}

td small {
  font-size: 0.76rem;
  color: #64748b;
  display: block;
  margin-top: 0.15rem;
  font-family: var(--font-mono);
}

/* Enhanced Workspace & Data List Rows */
.list-row {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.06) 0%, rgba(255, 255, 255, 0.015) 40%, rgba(14, 21, 46, 0.48) 100%), rgba(9, 14, 32, 0.42);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 16px;
  padding: 1.1rem 1.35rem;
  margin-bottom: 0.85rem;
  backdrop-filter: blur(28px) saturate(200%);
  -webkit-backdrop-filter: blur(28px) saturate(200%);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35), inset 0 1px 1px rgba(255, 255, 255, 0.22);
  transition: all 0.26s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}

.list-row:hover {
  background: rgba(18, 28, 64, 0.9);
  border-color: rgba(56, 189, 248, 0.45);
  transform: translateY(-2.5px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5), 0 0 20px rgba(56, 189, 248, 0.18);
}

.company-avatar {
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.25), rgba(56, 189, 248, 0.2));
  border: 1px solid rgba(56, 189, 248, 0.35);
  color: #38bdf8;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 14px rgba(37, 99, 235, 0.25);
  flex-shrink: 0;
}

.table-actions {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
}

.table-actions button, .table-actions a {
  padding: 0.35rem 0.65rem;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: var(--radius-xs);
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  color: var(--text-main);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.table-actions button:hover, .table-actions a:hover {
  border-color: var(--border-strong);
  background: var(--bg-surface-hover);
}

.table-actions button[data-delete]:hover {
  background: var(--color-danger-soft);
  border-color: var(--color-danger-border);
  color: var(--color-danger);
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 0;
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ==========================================================================
   WORKSPACE LIST & CARDS
   ========================================================================== */

.workspace-list {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.list-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.9rem 1.15rem;
  background: var(--bg-surface-soft);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  text-decoration: none;
  color: var(--text-main);
  transition: all var(--transition-fast);
}

.list-row:hover {
  border-color: var(--brand-light);
  background: var(--bg-surface);
  transform: translateX(3px);
  box-shadow: var(--shadow-sm);
}

.company-avatar {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: var(--radius-sm);
  background: var(--brand-soft);
  color: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.row-main {
  flex: 1;
  min-width: 0;
}

.chevron {
  color: var(--text-subtle);
  transition: transform var(--transition-fast);
}

.list-row:hover .chevron {
  color: var(--brand);
  transform: translateX(2px);
}

.details {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 0.75rem;
  font-size: 0.85rem;
}

.details dt {
  color: var(--text-muted);
  font-weight: 500;
}

.details dd {
  color: var(--text-heading);
  font-weight: 600;
}

/* ==========================================================================
   PIPELINE HUD, TIMELINE & DROPZONE
   ========================================================================== */

.dropzone {
  border: 2px dashed var(--border-strong);
  border-radius: var(--radius-md);
  padding: 1.75rem 1.25rem;
  text-align: center;
  background: var(--bg-surface-soft);
  transition: all var(--transition-fast);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.dropzone:hover,
.dropzone.dragover {
  border-color: var(--brand);
  background: var(--brand-soft);
}

.dropzone .dropzone-icon {
  width: 2.5rem;
  height: 2.5rem;
  color: var(--brand);
}

.hud-metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.hud-metric-box {
  background: var(--bg-surface-soft);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 0.65rem 0.85rem;
  display: flex;
  flex-direction: column;
}

.hud-metric-box small {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: uppercase;
  font-weight: 600;
}

.hud-metric-box strong {
  font-family: var(--font-display);
  font-size: 1.15rem;
  color: var(--text-heading);
  margin-top: 0.15rem;
}

.stage-list {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  overflow-x: auto;
  padding: 0.75rem 0.25rem;
}

.stage-list div {
  padding: 0.45rem 0.85rem;
  border-radius: var(--radius-full);
  background: var(--bg-surface-soft);
  border: 1px solid var(--border-subtle);
  color: var(--text-subtle);
  font-size: 0.74rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
  transition: all var(--transition-fast);
}

.stage-list div.active {
  background: var(--brand);
  border-color: var(--brand);
  color: var(--brand-contrast);
  box-shadow: 0 0 14px var(--brand-glow);
  transform: scale(1.04);
}

.stage-list div.done {
  background: var(--color-success-soft);
  border-color: var(--color-success-border);
  color: var(--color-success);
}

.loading-strip {
  height: 3px;
  width: 100%;
  background: var(--border-subtle);
  border-radius: var(--radius-full);
  overflow: hidden;
  position: relative;
}

.loading-strip span {
  display: block;
  height: 100%;
  width: 40%;
  background: linear-gradient(90deg, transparent, var(--brand), transparent);
  animation: loading-slide 1.2s infinite;
}

@keyframes loading-slide {
  from { transform: translateX(-100%); }
  to { transform: translateX(350%); }
}

.response-box {
  background: var(--bg-surface-soft);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-main);
  max-height: 240px;
  overflow-y: auto;
  white-space: pre-wrap;
  word-break: break-all;
}

.timeline {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.activity-item {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  padding: 0.75rem;
  background: var(--bg-surface-soft);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  font-size: 0.82rem;
}

.activity-dot {
  width: 2rem;
  height: 2rem;
  border-radius: var(--radius-sm);
  background: var(--brand-soft);
  color: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* ==========================================================================
   NEURAL AI AGENT CHAT CONSOLE
   ========================================================================== */

.agent-chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

/* Base Chat Container */
.auth-detection-card {
  background: linear-gradient(135deg, rgba(var(--brand-rgb), 0.12), rgba(var(--brand-rgb), 0.03));
  border: 1px solid var(--brand-soft-border);
  border-radius: var(--radius-md);
  padding: 0.85rem 1rem;
  margin-top: 0.6rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.auth-detection-title {
  font-weight: 700;
  font-size: 0.8rem;
  color: var(--brand);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.auth-field-tag {
  display: inline-block;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  padding: 0.15rem 0.45rem;
  border-radius: var(--radius-xs);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-main);
  margin-right: 0.3rem;
  margin-top: 0.2rem;
}

/* ==========================================================================
   MODAL DIALOGS
   ========================================================================== */

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(2, 6, 23, 0.68);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.modal-dialog {
  background: rgba(14, 21, 46, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 24px;
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.7), inset 0 1px 1px rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(36px) saturate(190%) contrast(105%);
  -webkit-backdrop-filter: blur(36px) saturate(190%) contrast(105%);
  max-width: 600px;
  width: 100%;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: scale(0.94);
  transition: transform 0.24s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-dialog form {
  display: flex;
  flex-direction: column;
  flex: 1;
  overflow: hidden;
}

.modal-overlay.open .modal-dialog {
  transform: scale(1);
}

.modal-header {
  padding: 1.15rem 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  background: rgba(255, 255, 255, 0.03);
}

.modal-title {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-heading);
  margin: 0;
}

.modal-body {
  padding: 1.5rem;
  overflow-y: auto;
  flex: 1;
}

.modal-footer {
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
  background: var(--bg-surface-soft);
}

/* ==========================================================================
   PLANS, SUBSCRIPTIONS & PRICING
   ========================================================================== */

.plan-grid, .pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
}

.plan-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 1.85rem 1.6rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  position: relative;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: all var(--transition-normal);
}

.plan-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, #38bdf8, transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.plan-card:hover {
  border-color: rgba(56, 189, 248, 0.45);
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6), 0 0 24px rgba(56, 189, 248, 0.2);
}

.plan-card:hover::before {
  opacity: 1;
}

.plan-card.active, .plan-card.selected {
  border: 1.5px solid #38bdf8;
  background: linear-gradient(180deg, rgba(56, 189, 248, 0.08), transparent), var(--bg-surface);
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.5), 0 0 24px rgba(56, 189, 248, 0.25);
}

.plan-card.active::before {
  opacity: 1;
}

.plan-card.featured::after {
  content: 'POPULAR';
  position: absolute;
  top: -12px;
  right: 20px;
  background: linear-gradient(135deg, #1d4ed8, #0284c7);
  color: #ffffff;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-full);
  letter-spacing: 0.08em;
  border: 1px solid rgba(56, 189, 248, 0.45);
  box-shadow: 0 0 14px rgba(37, 99, 235, 0.4);
}

.plan-price-box {
  display: flex;
  align-items: baseline;
  gap: 0.35rem;
}

.plan-price {
  font-family: var(--font-display);
  font-size: 2.3rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.02em;
  text-shadow: 0 0 24px rgba(56, 189, 248, 0.35);
}

.plan-interval {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.plan-features-list {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  padding-top: 0.75rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.plan-feature-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.84rem;
  color: var(--text-main);
}

.plan-feature-item .icon {
  color: var(--brand);
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
}

.inactive-card {
  opacity: 0.65;
  filter: grayscale(0.25);
  border-style: dashed !important;
}

/* ==========================================================================
   THEME STUDIO & PALETTES
   ========================================================================== */

.appearance-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.75rem;
}

.appearance-grid h3 {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-heading);
  margin-bottom: 0.85rem;
}

.segmented {
  display: inline-flex;
  gap: 0.35rem;
  padding: 0.35rem;
  background: var(--bg-surface-soft);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  width: 100%;
}

.segmented button {
  flex: 1;
  padding: 0.55rem 0.85rem;
  border-radius: var(--radius-sm);
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  transition: all var(--transition-fast);
}

.segmented button:hover {
  color: var(--text-heading);
}

.segmented button.selected {
  background: var(--bg-surface);
  border-color: var(--border-subtle);
  color: var(--brand);
  box-shadow: var(--shadow-sm);
}

.palette-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
  gap: 0.6rem;
}

.palette-grid button {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 0.75rem;
  background: var(--bg-surface-soft);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: var(--text-main);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.palette-grid button span {
  width: 1rem;
  height: 1rem;
  border-radius: 50%;
  background: var(--swatch);
  box-shadow: 0 0 6px var(--swatch);
  flex-shrink: 0;
}

.palette-grid button:hover {
  border-color: var(--border-strong);
  background: var(--bg-surface-hover);
  transform: translateY(-1px);
}

.palette-grid button.selected {
  border-color: var(--brand);
  background: var(--brand-soft);
  color: var(--brand);
  box-shadow: 0 0 0 2px var(--brand-soft-border);
}

.theme-preview-card {
  margin-top: 1rem;
  padding: 1.25rem;
  border-radius: var(--radius-md);
  background: var(--bg-surface-soft);
  border: 1px dashed var(--border-strong);
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.theme-preview-elements {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

/* ==========================================================================
   RETRIEVAL & CHUNK CARDS
   ========================================================================== */

.content-preview {
  background: var(--bg-surface-soft);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-main);
  max-height: 400px;
  overflow-y: auto;
  white-space: pre-wrap;
}

.chunk-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1rem;
}

.chunk-card {
  background: var(--bg-surface-soft);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  transition: all var(--transition-fast);
}

.chunk-card:hover {
  border-color: var(--brand-light);
  background: var(--bg-surface);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.chunk-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.75rem;
  font-family: var(--font-mono);
  color: var(--text-muted);
}

.chunk-body {
  font-size: 0.82rem;
  line-height: 1.5;
  color: var(--text-main);
  display: -webkit-box;
  -webkit-line-clamp: 4;
  line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.retrieval-card {
  background: var(--bg-surface-soft);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1rem 1.15rem;
  margin-bottom: 0.85rem;
  transition: all var(--transition-fast);
}

.retrieval-card:hover {
  border-color: var(--brand-light);
  box-shadow: var(--shadow-sm);
}

.retrieval-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
  flex-wrap: wrap;
}

.retrieval-card-title {
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--text-heading);
}

.score-badge-group {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.score-badge {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  padding: 0.2rem 0.5rem;
  border-radius: var(--radius-xs);
  font-weight: 600;
}

.score-badge.total {
  background: var(--brand-soft);
  color: var(--brand);
  border: 1px solid var(--brand-soft-border);
}

.score-badge.sub {
  background: var(--bg-surface);
  color: var(--text-muted);
  border: 1px solid var(--border-subtle);
}

.retrieval-text {
  font-size: 0.84rem;
  color: var(--text-main);
  line-height: 1.55;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 0.75rem;
  margin-top: 0.5rem;
  white-space: pre-wrap;
  word-break: break-word;
}

/* ==========================================================================
   EMPTY STATES & NOTIFICATIONS
   ========================================================================== */

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3rem 1.5rem;
  gap: 0.75rem;
}

.empty-icon {
  width: 3.5rem;
  height: 3.5rem;
  border-radius: var(--radius-xl);
  background: var(--brand-soft);
  color: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.25rem;
}

.empty-icon .icon {
  width: 1.85rem;
  height: 1.85rem;
}

.empty-state h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-heading);
}

.empty-state p {
  font-size: 0.88rem;
  color: var(--text-muted);
  max-width: 400px;
}

.alert {
  padding: 0.85rem 1.15rem;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 500;
  background: var(--color-danger-soft);
  border: 1px solid var(--color-danger-border);
  color: var(--color-danger);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.alert.success {
  background: var(--color-success-soft);
  border-color: var(--color-success-border);
  color: var(--color-success);
}

.notice {
  padding: 0.85rem 1.15rem;
  border-radius: var(--radius-md);
  font-size: 0.82rem;
  background: var(--bg-surface-soft);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
}

.search {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  max-width: 320px;
  width: 100%;
}

.search input {
  padding: 0.55rem 0.85rem;
  font-size: 0.82rem;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* ==========================================================================
   AUTH PORTAL & ONBOARDING
   ========================================================================== */

.auth-body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.auth-card {
  width: 100%;
  max-width: 450px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 2.5rem 2.25rem;
  box-shadow: var(--shadow-xl);
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  position: relative;
  overflow: hidden;
}

.auth-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--brand), var(--brand-light));
}

.auth-card h1 {
  font-family: var(--font-display);
  font-size: 1.65rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text-heading);
  line-height: 1.2;
}

.auth-card p {
  color: var(--text-muted);
  font-size: 0.88rem;
}

.auth-brand {
  margin-bottom: 0.5rem;
}

/* Onboarding Step Indicators */
.onboarding-container {
  max-width: 720px;
  margin: 3.5rem auto;
  padding: 2.25rem;
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  border: 1px solid var(--border-subtle);
}

.step-indicator {
  display: flex;
  justify-content: space-between;
  margin-bottom: 2.5rem;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 1.25rem;
  gap: 0.5rem;
}

.step {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.65rem;
  border-radius: var(--radius-full);
  background: var(--bg-surface-soft);
  border: 1px solid var(--border-subtle);
}

.step.active {
  color: var(--brand);
  background: var(--brand-soft);
  border-color: var(--brand-soft-border);
  box-shadow: 0 0 10px var(--brand-glow);
}

.step.completed {
  color: var(--color-success);
  background: var(--color-success-soft);
  border-color: var(--color-success-border);
}

.onboarding-shell {
  max-width: 720px;
  margin: 0 auto;
  width: 100%;
}

.onboarding-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 24px;
  padding: 2.5rem;
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  gap: 2rem;
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.onboarding-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, #38bdf8, transparent);
  box-shadow: 0 0 12px #38bdf8;
}

.onboarding-step {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
}

.onboarding-step h2 {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.01em;
}

.source-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 1rem;
}

.source-options label {
  padding: 1.25rem 1.4rem;
  border: 1.5px solid var(--border-subtle, rgba(0, 0, 0, 0.08));
  border-radius: var(--radius-lg, 18px);
  background: var(--glass-2-bg, rgba(255, 255, 255, 0.82));
  backdrop-filter: blur(20px);
  cursor: pointer;
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  align-items: center;
  gap: 0.85rem;
  font-weight: 600;
  font-size: 0.95rem;
  color: #0F172A;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.03);
}

.source-options label:hover {
  border-color: var(--role-accent-border, rgba(244, 63, 94, 0.4));
  background: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.07);
}

.source-options label.recommended,
.source-options label:has(input:checked) {
  border-color: var(--role-accent, #4f46e5) !important;
  background: var(--role-accent-soft, rgba(99, 102, 241, 0.08)) !important;
  box-shadow: 0 0 0 1px var(--role-accent, #4f46e5), 0 8px 20px var(--role-accent-glow, rgba(99, 102, 241, 0.15)) !important;
  color: #0F172A !important;
}

.source-options input[type="radio"],
input[type="radio"] {
  display: inline-block !important;
  width: 18px !important;
  height: 18px !important;
  min-width: 18px !important;
  max-width: 18px !important;
  margin: 0 !important;
  padding: 0 !important;
  border-radius: 50% !important;
  border: 2px solid #94a3b8 !important;
  background: #ffffff !important;
  box-shadow: none !important;
  accent-color: var(--role-accent, #4f46e5) !important;
  cursor: pointer !important;
  flex-shrink: 0 !important;
}

/* Home / Control Center Specific */
.home-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding: 3.5rem 2.5rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  position: relative;
  overflow: hidden;
}

.home-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 90% 10%, rgba(var(--brand-rgb), 0.15), transparent 60%);
  pointer-events: none;
}

.home-copy {
  max-width: 680px;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  position: relative;
  z-index: 1;
}

.home-copy h1 {
  font-family: var(--font-display);
  font-size: 2.4rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--text-heading);
  line-height: 1.15;
}

.home-copy p {
  font-size: 1.05rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.home-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
}

.home-action-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  text-decoration: none;
  color: var(--text-main);
  box-shadow: var(--shadow-xs);
  transition: all var(--transition-fast);
}

.home-action-card:hover {
  border-color: var(--brand);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.home-action-card.primary-card {
  background: linear-gradient(135deg, rgba(var(--brand-rgb), 0.08), transparent), var(--bg-surface);
  border-color: var(--brand-soft-border);
}

.home-action-icon {
  width: 3.2rem;
  height: 3.2rem;
  border-radius: var(--radius-lg);
  background: var(--brand-soft);
  color: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.home-action-icon .icon {
  width: 1.65rem;
  height: 1.65rem;
}

.home-action-info {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  flex: 1;
}

.home-action-info small {
  font-size: 0.72rem;
  color: var(--brand);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.home-action-info strong {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-heading);
}

.home-action-info p {
  font-size: 0.84rem;
  color: var(--text-muted);
  margin-top: 0.2rem;
  line-height: 1.45;
}

/* Most Asked Questions & Question Items */
.most-asked-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.question-item {
  background: var(--bg-surface-soft);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.9rem 1.15rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  transition: all var(--transition-fast);
}

.question-item:hover {
  border-color: var(--brand-light);
  background: var(--bg-surface);
  transform: translateX(2px);
}

.question-text {
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--text-heading);
}

.question-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

.question-count-badge {
  background: var(--brand-soft);
  border: 1px solid var(--brand-soft-border);
  color: var(--brand);
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.75rem;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-full);
}

/* Developer & API Console */
.developer-shell {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 1.5rem;
  align-items: start;
}

.endpoint-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.endpoint-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-sm);
  background: var(--bg-surface-soft);
  border: 1px solid var(--border-subtle);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
  color: var(--text-main);
}

.endpoint-item:hover {
  border-color: var(--brand-light);
  background: var(--bg-surface-hover);
}

.endpoint-item.active {
  background: var(--brand-soft);
  border-color: var(--brand-soft-border);
  color: var(--brand);
}

.method-badge {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.15rem 0.45rem;
  border-radius: var(--radius-xs);
  background: var(--color-success-soft);
  color: var(--color-success);
  border: 1px solid var(--color-success-border);
}

/* ==========================================================================
   RESPONSIVE DESIGN (MOBILE & TABLET)
   ========================================================================== */

@media (max-width: 1024px) {
  .chat-shell {
    grid-template-columns: 1fr;
    height: auto;
  }
  
  .grid.sidebar-grid {
    grid-template-columns: 1fr;
  }

  .developer-shell {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  :root {
    --sidebar-w: 270px;
  }
  
  .sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    transform: translateX(-100%);
    box-shadow: var(--shadow-xl);
    z-index: 50;
  }
  
  .nav-toggle:checked ~ .sidebar {
    transform: translateX(0);
  }

  .nav-toggle:checked ~ .sidebar-backdrop {
    display: block;
    opacity: 1;
    pointer-events: auto;
  }
  
  .mobile-menu {
    display: inline-flex;
  }
  
  .topbar {
    padding: 0 1rem;
  }
  
  .page-enter {
    padding: 1.25rem 1rem;
  }
  
  .home-hero {
    flex-direction: column;
    padding: 2rem 1.5rem;
  }
  
  .home-copy h1 {
    font-size: 1.85rem;
  }

  .grid.two, .grid.three, .grid.four {
    grid-template-columns: 1fr;
  }

  .step-indicator {
    flex-direction: column;
    gap: 0.5rem;
  }
}

/* Sleek Scrollbars */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: var(--border-strong);
  border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--brand);
}

/* ==========================================================================
   NEXT-GEN CYBER ANIMATIONS & INTERACTIVE HUD COMPONENTS
   ========================================================================== */

/* 1. Moving Stripes for Laser Progress Bars */
@keyframes movingStripes {
  0% { background-position: 0 0; }
  100% { background-position: 40px 0; }
}

@keyframes typingWave {
  0%, 60%, 100% {
    transform: translateY(0);
    opacity: 0.35;
  }
  30% {
    transform: translateY(-6px);
    opacity: 1;
  }
}

@keyframes borderLaserScan {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(200%); }
}

@keyframes beaconGlowPulse {
  0%, 100% {
    box-shadow: 0 0 8px rgba(56, 189, 248, 0.4), inset 0 0 8px rgba(56, 189, 248, 0.2);
  }
  50% {
    box-shadow: 0 0 20px rgba(56, 189, 248, 0.8), inset 0 0 14px rgba(56, 189, 248, 0.4);
  }
}

/* Moving Stripes Progress Bar */
.progress-bar-striped,
.loading-strip > div,
.hud-progress-fill {
  background-image: linear-gradient(
    45deg,
    rgba(255, 255, 255, 0.18) 25%,
    transparent 25%,
    transparent 50%,
    rgba(255, 255, 255, 0.18) 50%,
    rgba(255, 255, 255, 0.18) 75%,
    transparent 75%,
    transparent
  ) !important;
  background-size: 24px 24px !important;
  animation: movingStripes 1.2s linear infinite !important;
}

/* Enhanced Loading Strip HUD */
.loading-strip {
  width: 100%;
  height: 8px;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: var(--radius-full);
  overflow: hidden;
  position: relative;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.4);
}

.loading-strip span {
  display: block;
  height: 100%;
  width: 100%;
  background: linear-gradient(90deg, #38bdf8, #818cf8, #38bdf8);
  background-size: 200% 100%;
  animation: movingStripes 1.5s linear infinite;
  box-shadow: 0 0 12px rgba(56, 189, 248, 0.6);
}

/* ==========================================================================
   NEURAL AI CHAT CONSOLE - APPLE IOS 26 FROSTED GLASS & FRAME FIT
   ========================================================================== */

/* Chat HUD Header Bar - Apple Glass Toolbar */
.chat-hud-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.6rem 1.25rem;
  border-radius: 20px;
  background: rgba(14, 21, 44, 0.52);
  backdrop-filter: blur(28px) saturate(190%) contrast(105%);
  -webkit-backdrop-filter: blur(28px) saturate(190%) contrast(105%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35), inset 0 1px 1px rgba(255, 255, 255, 0.18);
  margin-bottom: 0.75rem;
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
}

.chat-agent-badge {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.chat-agent-avatar {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.25), rgba(14, 165, 233, 0.1));
  border: 1.5px solid #38bdf8;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #38bdf8;
  position: relative;
  box-shadow: 0 0 14px rgba(56, 189, 248, 0.35);
  flex-shrink: 0;
}

.chat-agent-avatar .avatar-radar-ring {
  position: absolute;
  inset: -4px;
  border-radius: 15px;
  border: 1px dashed rgba(56, 189, 248, 0.4);
  animation: spinSlow 16s linear infinite;
  pointer-events: none;
}

.chat-agent-info h2 {
  font-size: 1.2rem;
  font-family: var(--font-display);
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.02em;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.chat-agent-info p {
  font-size: 0.78rem;
  color: #94a3b8;
  margin: 0.15rem 0 0 0;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.chat-hud-actions {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
}

.chat-hud-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.42rem 0.85rem;
  font-size: 0.78rem;
  font-weight: 600;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #cbd5e1;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.1);
}

.chat-hud-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.25);
  color: #ffffff;
  transform: translateY(-1.5px);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.chat-hud-btn.primary {
  background: linear-gradient(135deg, #0284c7 0%, #0ea5e9 50%, #38bdf8 100%);
  border-color: rgba(255, 255, 255, 0.25);
  color: #ffffff;
  font-weight: 700;
  box-shadow: 0 4px 16px rgba(14, 165, 233, 0.35), inset 0 1px 1px rgba(255, 255, 255, 0.3);
}

.chat-hud-btn.primary:hover {
  box-shadow: 0 6px 22px rgba(56, 189, 248, 0.5);
  transform: translateY(-2px);
}

/* Chat Shell Layout - 100% Viewport Frame Fit */
.chat-shell {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 1rem;
  flex: 1;
  min-height: 0;
  height: 100%;
  overflow: hidden;
}

.chat-panel {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  height: 100%;
  padding: 0.9rem 1.15rem 0.85rem 1.15rem;
  overflow: hidden;
  background: var(--bg-surface, #ffffff);
  border: 1px solid var(--border-subtle, rgba(226, 232, 240, 0.95));
  border-radius: 20px;
  box-shadow: 0 4px 24px rgba(15, 23, 42, 0.04), 0 1px 2px rgba(15, 23, 42, 0.02);
  position: relative;
  transition: background-color 0.25s ease, border-color 0.25s ease;
}

:root[data-theme="dark"] .chat-panel {
  background: rgba(10, 16, 35, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.48), inset 0 1px 1.5px rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(32px) saturate(180%);
  -webkit-backdrop-filter: blur(32px) saturate(180%);
}

/* Quick Prompts Container */
.quick-prompts {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding-bottom: 0.65rem;
  border-bottom: 1px solid rgba(226, 232, 240, 0.85);
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  flex-shrink: 0;
}

:root[data-theme="dark"] .quick-prompts {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.quick-prompts::-webkit-scrollbar {
  display: none;
}

.quick-prompts-label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #2563eb;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  white-space: nowrap;
  padding-right: 0.25rem;
}

:root[data-theme="dark"] .quick-prompts-label {
  color: #38bdf8;
}

.prompt-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: #f8fafc;
  border: 1px solid rgba(203, 213, 225, 0.85);
  border-radius: var(--radius-full);
  padding: 0.32rem 0.78rem;
  font-size: 0.76rem;
  font-weight: 600;
  color: #334155;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  flex-shrink: 0;
}

.prompt-chip .chip-icon {
  font-size: 0.82rem;
}

.prompt-chip .chip-arrow {
  opacity: 0;
  transform: translateX(-4px);
  transition: all 0.2s ease;
  font-size: 0.72rem;
  color: #2563eb;
}

.prompt-chip:hover {
  background: #eff6ff;
  border-color: #3b82f6;
  color: #1d4ed8;
  transform: translateY(-1px);
  box-shadow: 0 3px 10px rgba(37, 99, 235, 0.12);
}

.prompt-chip:hover .chip-arrow {
  opacity: 1;
  transform: translateX(0);
}

:root[data-theme="dark"] .prompt-chip {
  background: rgba(15, 23, 42, 0.75);
  border-color: rgba(56, 189, 248, 0.22);
  color: #cbd5e1;
}

:root[data-theme="dark"] .prompt-chip .chip-arrow {
  color: #38bdf8;
}

:root[data-theme="dark"] .prompt-chip:hover {
  background: rgba(56, 189, 248, 0.15);
  border-color: #38bdf8;
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(56, 189, 248, 0.25);
}

/* Chat Message Log Stream */
.chat-log {
  position: relative;
  z-index: 2;
  pointer-events: auto;
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
  padding: 0.85rem 0.4rem 0.85rem 0;
  scroll-behavior: smooth;
  background: transparent;
}

.chat-log::-webkit-scrollbar {
  width: 6px;
}
.chat-log::-webkit-scrollbar-track {
  background: rgba(15, 23, 42, 0.05);
  border-radius: 3px;
}
:root[data-theme="dark"] .chat-log::-webkit-scrollbar-track {
  background: rgba(15, 23, 42, 0.4);
}
.chat-log::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.4);
  border-radius: 3px;
}
:root[data-theme="dark"] .chat-log::-webkit-scrollbar-thumb {
  background: rgba(56, 189, 248, 0.25);
}
.chat-log::-webkit-scrollbar-thumb:hover {
  background: rgba(100, 116, 139, 0.6);
}
:root[data-theme="dark"] .chat-log::-webkit-scrollbar-thumb:hover {
  background: rgba(56, 189, 248, 0.5);
}

/* ==========================================================================
   ELEGANT AI CHAT STAGE & EMPTY STATE SYSTEM
   ========================================================================== */
.chat-stage {
  flex: 1;
  min-height: 0;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border-radius: 14px;
  background: radial-gradient(circle at 50% 12%, rgba(99, 102, 241, 0.04) 0%, rgba(248, 250, 252, 0.5) 60%, transparent 100%), #ffffff;
  background-image: radial-gradient(rgba(148, 163, 184, 0.16) 1px, transparent 1px);
  background-size: 24px 24px;
}

:root[data-theme="dark"] .chat-stage {
  background: radial-gradient(circle at 50% 15%, rgba(56, 189, 248, 0.05) 0%, rgba(11, 17, 33, 0.8) 60%, #070b19 100%);
  background-image: radial-gradient(rgba(56, 189, 248, 0.12) 1px, transparent 1px);
  background-size: 24px 24px;
}

/* Empty State Backdrop: Perfectly fitted and centered, disappears completely on active chat */
.chat-hologram-backdrop {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.25rem 1.5rem 1.5rem 1.5rem;
  z-index: 1;
  pointer-events: auto;
  overflow-y: auto;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

/* Zero ghosting or overlap during active chat */
.chat-stage.chat-active .chat-hologram-backdrop {
  display: none !important;
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

.empty-state-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 540px;
  width: 100%;
  margin: auto;
}

/* Professional AI Agent Hero Emblem */
.ai-hero-emblem-wrap {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0.25rem 0 0.85rem 0;
  position: relative;
}

.ai-hero-halo {
  position: absolute;
  width: 90px;
  height: 90px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.18) 0%, rgba(99, 102, 241, 0.1) 45%, transparent 70%);
  filter: blur(14px);
  animation: aiHeroPulse 4s ease-in-out infinite alternate;
  pointer-events: none;
}

@keyframes aiHeroPulse {
  0% { transform: scale(0.92); opacity: 0.6; }
  100% { transform: scale(1.12); opacity: 0.95; filter: blur(18px); }
}

.ai-hero-badge {
  position: relative;
  width: 66px;
  height: 66px;
  border-radius: 18px;
  background: linear-gradient(145deg, #ffffff 0%, #f8faff 55%, #eef2ff 100%);
  border: 1px solid rgba(199, 210, 254, 0.85);
  box-shadow: 
    0 10px 25px -4px rgba(37, 99, 235, 0.14),
    0 4px 10px -2px rgba(99, 102, 241, 0.08),
    inset 0 1px 2px rgba(255, 255, 255, 0.95);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease;
  animation: aiHeroFloat 5s ease-in-out infinite;
}

.ai-hero-badge:hover {
  transform: translateY(-3px) scale(1.03);
  box-shadow: 
    0 16px 32px -4px rgba(37, 99, 235, 0.2),
    0 6px 14px -2px rgba(99, 102, 241, 0.12),
    inset 0 1px 2px rgba(255, 255, 255, 0.95);
}

@keyframes aiHeroFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}

:root[data-theme="dark"] .ai-hero-badge {
  background: linear-gradient(145deg, rgba(30, 41, 59, 0.85) 0%, rgba(15, 23, 42, 0.95) 100%);
  border: 1px solid rgba(99, 102, 241, 0.35);
  box-shadow: 
    0 12px 28px -4px rgba(0, 0, 0, 0.55),
    0 0 20px rgba(99, 102, 241, 0.25),
    inset 0 1px 1px rgba(255, 255, 255, 0.1);
}

:root[data-theme="dark"] .ai-hero-halo {
  background: radial-gradient(circle, rgba(168, 85, 247, 0.28) 0%, rgba(99, 102, 241, 0.18) 45%, transparent 70%);
}

.ai-hero-icon {
  width: 44px;
  height: 44px;
  display: block;
}

.ai-hero-ring-rotate {
  transform-origin: 24px 24px;
  animation: aiHeroRingSpin 24s linear infinite;
}

@keyframes aiHeroRingSpin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.ai-hero-status-pip {
  position: absolute;
  bottom: -2px;
  right: -2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #10b981;
  border: 2.5px solid #ffffff;
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.55);
  display: block;
}

:root[data-theme="dark"] .ai-hero-status-pip {
  border-color: #0f172a;
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.75);
}

/* Updated Brand Pill - Polished, Symmetrical & High-End */
.bot-brand-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.28rem 0.85rem;
  border-radius: var(--radius-full, 9999px);
  background: rgba(37, 99, 235, 0.07);
  border: 1px solid rgba(37, 99, 235, 0.2);
  margin-bottom: 0.75rem;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #2563eb;
  box-shadow: 0 1px 3px rgba(37, 99, 235, 0.08);
  transition: all 0.2s ease;
}

:root[data-theme="dark"] .bot-brand-pill {
  background: rgba(99, 102, 241, 0.15);
  border-color: rgba(99, 102, 241, 0.35);
  color: #c084fc;
  box-shadow: 0 0 12px rgba(168, 85, 247, 0.15);
}

.bot-pill-sparkle {
  width: 12px;
  height: 12px;
  flex-shrink: 0;
  color: #3b82f6;
}

:root[data-theme="dark"] .bot-pill-sparkle {
  color: #c084fc;
}

/* Empty State Typography */
.bot-main-title {
  font-size: 1.35rem;
  font-family: var(--font-display);
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.025em;
  margin: 0 0 0.35rem 0;
  line-height: 1.25;
}

:root[data-theme="dark"] .bot-main-title {
  color: #ffffff;
  text-shadow: 0 0 25px rgba(255, 255, 255, 0.15);
}

.bot-welcome-text {
  font-size: 0.85rem;
  color: #64748b;
  max-width: 460px;
  line-height: 1.48;
  margin: 0 0 1rem 0;
}

:root[data-theme="dark"] .bot-welcome-text {
  color: #94a3b8;
}

.brand-text-accent {
  color: #2563eb;
  font-weight: 700;
}

:root[data-theme="dark"] .brand-text-accent {
  color: #38bdf8;
}

/* 2x2 Interactive Empty State Suggestions Grid */
.bot-empty-suggestions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem;
  width: 100%;
  max-width: 500px;
  margin-bottom: 0.95rem;
}

@media (max-width: 600px) {
  .bot-empty-suggestions {
    grid-template-columns: 1fr;
  }
}

.empty-suggestion-chip {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.55rem 0.8rem;
  border-radius: 12px;
  background: #ffffff;
  border: 1px solid rgba(226, 232, 240, 0.95);
  color: #334155;
  font-size: 0.78rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.empty-suggestion-chip .sugg-icon {
  font-size: 0.92rem;
  flex-shrink: 0;
}

.empty-suggestion-chip .sugg-text {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.empty-suggestion-chip:hover {
  background: #f8faff;
  border-color: #3b82f6;
  color: #1d4ed8;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.1);
}

:root[data-theme="dark"] .empty-suggestion-chip {
  background: rgba(15, 23, 42, 0.75);
  border-color: rgba(56, 189, 248, 0.2);
  color: #cbd5e1;
  box-shadow: none;
}

:root[data-theme="dark"] .empty-suggestion-chip:hover {
  background: rgba(56, 189, 248, 0.15);
  border-color: #38bdf8;
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(56, 189, 248, 0.22);
}

/* Integration Badges Bar */
.bot-integrations-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.integration-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-full);
  background: #f1f5f9;
  border: 1px solid rgba(203, 213, 225, 0.75);
  color: #64748b;
  font-family: var(--font-mono);
  transition: all 0.2s ease;
}

.integration-pill:hover {
  background: #e2e8f0;
  color: #334155;
}

:root[data-theme="dark"] .integration-pill {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #94a3b8;
}

:root[data-theme="dark"] .integration-pill:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  border-color: rgba(56, 189, 248, 0.3);
}

/* Message Cards */
.chat-message {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1.1rem 1.35rem;
  border-radius: 16px;
  position: relative;
  font-size: 0.92rem;
  line-height: 1.65;
  max-width: 88%;
  animation: chatMsgEntrance 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

@keyframes chatMsgEntrance {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.chat-message.assistant {
  align-self: flex-start;
  background: #ffffff;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-left: 3.5px solid #2563eb;
  color: #1e293b;
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.04);
}

:root[data-theme="dark"] .chat-message.assistant {
  background: linear-gradient(135deg, rgba(13, 19, 40, 0.92) 0%, rgba(15, 23, 42, 0.9) 100%);
  border: 1px solid rgba(56, 189, 248, 0.28);
  border-left: 3.5px solid #38bdf8;
  color: #e2e8f0;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35), 0 0 16px rgba(56, 189, 248, 0.08);
}

.chat-message.user {
  align-self: flex-end;
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  border: 1px solid rgba(37, 99, 235, 0.3);
  border-right: 3.5px solid #1e40af;
  color: #ffffff !important;
  box-shadow: 0 4px 16px rgba(37, 99, 235, 0.22);
}

:root[data-theme="dark"] .chat-message.user {
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.28) 0%, rgba(37, 99, 235, 0.35) 100%);
  border: 1px solid rgba(56, 189, 248, 0.45);
  border-right: 3.5px solid #38bdf8;
  color: #ffffff !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35), 0 0 20px rgba(56, 189, 248, 0.16);
}

/* Force pure white text inside User message bubble against role-based overrides */
.chat-message.user,
.chat-message.user p,
.chat-message.user .chat-msg-body,
.chat-message.user span,
.chat-message.user strong,
body.role-company-admin .chat-message.user p,
body.role-company-admin .chat-message.user .chat-msg-body,
body.role-company-admin .chat-message.user span,
body.role-super-admin .chat-message.user p,
body.role-super-admin .chat-message.user .chat-msg-body,
body.role-super-admin .chat-message.user span {
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
}

.chat-message.user .chat-msg-meta span,
body.role-company-admin .chat-message.user .chat-msg-meta span,
body.role-super-admin .chat-message.user .chat-msg-meta span {
  color: rgba(255, 255, 255, 0.85) !important;
  -webkit-text-fill-color: rgba(255, 255, 255, 0.85) !important;
}

/* Force crisp contrast for Assistant message text */
.chat-message.assistant,
.chat-message.assistant p,
.chat-message.assistant .chat-msg-body,
body.role-company-admin .chat-message.assistant p,
body.role-company-admin .chat-message.assistant .chat-msg-body,
body.role-super-admin .chat-message.assistant p,
body.role-super-admin .chat-message.assistant .chat-msg-body {
  color: #0f172a !important;
  -webkit-text-fill-color: #0f172a !important;
}

.chat-message.assistant strong,
body.role-company-admin .chat-message.assistant strong {
  color: #0f172a !important;
  font-weight: 700;
}

:root[data-theme="dark"] .chat-message.assistant,
:root[data-theme="dark"] .chat-message.assistant p,
:root[data-theme="dark"] .chat-message.assistant .chat-msg-body,
:root[data-theme="dark"] body.role-company-admin .chat-message.assistant p,
:root[data-theme="dark"] body.role-super-admin .chat-message.assistant p {
  color: #f1f5f9 !important;
  -webkit-text-fill-color: #f1f5f9 !important;
}

:root[data-theme="dark"] .chat-message.assistant strong,
:root[data-theme="dark"] body.role-company-admin .chat-message.assistant strong {
  color: #ffffff !important;
}

.chat-msg-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.15rem;
}

.chat-msg-author {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.chat-message.assistant .chat-msg-author {
  color: #2563eb !important;
  -webkit-text-fill-color: #2563eb !important;
}

:root[data-theme="dark"] .chat-message.assistant .chat-msg-author {
  color: #38bdf8 !important;
  -webkit-text-fill-color: #38bdf8 !important;
}

.chat-message.user .chat-msg-author {
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
}

:root[data-theme="dark"] .chat-message.user .chat-msg-author {
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
}

.chat-msg-author-icon {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.chat-message.assistant .chat-msg-author-icon {
  background: rgba(37, 99, 235, 0.1);
  border: 1px solid rgba(37, 99, 235, 0.25);
  color: #2563eb;
}

:root[data-theme="dark"] .chat-message.assistant .chat-msg-author-icon {
  background: rgba(56, 189, 248, 0.15);
  border: 1px solid rgba(56, 189, 248, 0.3);
  color: #38bdf8;
}

.chat-message.user .chat-msg-author-icon {
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #ffffff;
}

.chat-msg-meta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.chat-rag-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.68rem;
  font-weight: 600;
  padding: 0.18rem 0.5rem;
  border-radius: var(--radius-full);
  background: rgba(16, 185, 129, 0.12);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.msg-copy-btn {
  background: transparent;
  border: none;
  color: #94a3b8;
  cursor: pointer;
  padding: 0.2rem 0.35rem;
  border-radius: 4px;
  font-size: 0.75rem;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  transition: all 0.2s ease;
}

.msg-copy-btn:hover {
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.12);
}

/* Typing / Reasoning Indicator */
.chat-pending-card {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.5rem 0.2rem;
}

.typing-radar {
  position: relative;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.typing-radar::before {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1.5px solid rgba(56, 189, 248, 0.5);
  animation: radarWave 1.8s cubic-bezier(0.1, 0.8, 0.3, 1) infinite;
}

@keyframes radarWave {
  0% { transform: scale(0.6); opacity: 0.8; }
  100% { transform: scale(1.8); opacity: 0; }
}

.typing-dots-wave {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.typing-dot {
  width: 7px;
  height: 7px;
  background: #38bdf8;
  border-radius: 50%;
  box-shadow: 0 0 8px rgba(56, 189, 248, 0.7);
  animation: typingBounce 1.4s infinite ease-in-out;
}

.typing-dot:nth-child(2) { animation-delay: 0.2s; }
.typing-dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes typingBounce {
  0%, 80%, 100% { transform: translateY(0); opacity: 0.4; }
  40% { transform: translateY(-7px); opacity: 1; box-shadow: 0 0 12px #38bdf8; }
}

.typing-status-text {
  font-size: 0.82rem;
  font-family: var(--font-mono);
  color: #38bdf8;
  letter-spacing: 0.02em;
}

/* Chat Input Bar Dock */
.chat-form {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: auto;
  padding-top: 0.8rem;
  border-top: 1px solid rgba(226, 232, 240, 0.85);
  position: relative;
  flex-shrink: 0;
  background: transparent;
}

:root[data-theme="dark"] .chat-form {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

/* Animated Cyber Glow Frame for Text Input */
.chat-input-glow-frame {
  position: relative;
  flex: 1;
  border-radius: var(--radius-full);
  padding: 2px;
  background: linear-gradient(90deg, rgba(37, 99, 235, 0.25) 0%, rgba(14, 165, 233, 0.4) 25%, rgba(99, 102, 241, 0.35) 50%, rgba(37, 99, 235, 0.5) 75%, rgba(14, 165, 233, 0.25) 100%);
  background-size: 300% 100%;
  animation: cyberBorderTrace 5s linear infinite;
  box-shadow: 0 2px 10px rgba(37, 99, 235, 0.08);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

:root[data-theme="dark"] .chat-input-glow-frame {
  background: linear-gradient(90deg, rgba(56, 189, 248, 0.3) 0%, rgba(14, 165, 233, 0.5) 25%, rgba(99, 102, 241, 0.4) 50%, rgba(56, 189, 248, 0.6) 75%, rgba(14, 165, 233, 0.3) 100%);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.4), 0 0 12px rgba(56, 189, 248, 0.12);
}

@keyframes cyberBorderTrace {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.chat-input-glow-frame:hover {
  background: linear-gradient(90deg, #3b82f6, #0ea5e9, #818cf8, #3b82f6);
  background-size: 250% 100%;
  animation: cyberBorderTrace 2.5s linear infinite;
  box-shadow: 0 3px 14px rgba(37, 99, 235, 0.15);
  transform: translateY(-1px);
}

:root[data-theme="dark"] .chat-input-glow-frame:hover {
  background: linear-gradient(90deg, #38bdf8, #0ea5e9, #818cf8, #38bdf8);
  box-shadow: 0 4px 22px rgba(0, 0, 0, 0.5), 0 0 20px rgba(56, 189, 248, 0.35);
}

.chat-input-glow-frame:focus-within {
  background: linear-gradient(90deg, #2563eb, #0284c7, #6366f1, #2563eb);
  background-size: 200% 100%;
  animation: cyberBorderTrace 1.8s linear infinite;
  box-shadow: 0 4px 18px rgba(37, 99, 235, 0.22);
  transform: translateY(-1px);
}

:root[data-theme="dark"] .chat-input-glow-frame:focus-within {
  background: linear-gradient(90deg, #38bdf8, #00f2fe, #6366f1, #38bdf8);
  box-shadow: 0 6px 28px rgba(0, 0, 0, 0.55), 0 0 26px rgba(56, 189, 248, 0.45);
}

.chat-input-wrapper {
  flex: 1;
  position: relative;
  display: flex;
  align-items: center;
  background: #ffffff;
  border-radius: var(--radius-full);
}

:root[data-theme="dark"] .chat-input-wrapper {
  background: rgba(11, 17, 33, 0.96);
}

.chat-input-wrapper .chat-input-icon {
  position: absolute;
  left: 1.15rem;
  color: #64748b;
  pointer-events: none;
  display: flex;
  align-items: center;
  transition: all 0.3s ease;
  animation: iconPulseBreath 3s ease-in-out infinite;
}

@keyframes iconPulseBreath {
  0%, 100% { transform: scale(1); color: #64748b; filter: drop-shadow(0 0 0 transparent); }
  50% { transform: scale(1.1); color: #2563eb; filter: drop-shadow(0 0 6px rgba(37, 99, 235, 0.4)); }
}

:root[data-theme="dark"] @keyframes iconPulseBreath {
  0%, 100% { transform: scale(1); color: #64748b; filter: drop-shadow(0 0 0 transparent); }
  50% { transform: scale(1.1); color: #38bdf8; filter: drop-shadow(0 0 6px rgba(56, 189, 248, 0.5)); }
}

.chat-input-glow-frame:focus-within .chat-input-icon {
  color: #2563eb;
  filter: drop-shadow(0 0 6px rgba(37, 99, 235, 0.5));
  animation: none;
}

:root[data-theme="dark"] .chat-input-glow-frame:focus-within .chat-input-icon {
  color: #38bdf8;
  filter: drop-shadow(0 0 8px rgba(56, 189, 248, 0.7));
  animation: none;
}

.chat-form input {
  width: 100%;
  background: transparent;
  border: none;
  border-radius: var(--radius-full);
  padding: 0.85rem 4.5rem 0.85rem 3rem;
  font-size: 0.92rem;
  color: #0f172a;
  outline: none;
  font-family: inherit;
  box-shadow: none;
}

:root[data-theme="dark"] .chat-form input {
  color: #ffffff;
}

.chat-form input::placeholder {
  color: #94a3b8;
  transition: color 0.2s ease;
}

.chat-form input:focus::placeholder {
  color: #64748b;
}

:root[data-theme="dark"] .chat-form input::placeholder {
  color: #64748b;
}

:root[data-theme="dark"] .chat-form input:focus::placeholder {
  color: #94a3b8;
}

/* Soundwave / Activity indicator inside input */
.input-active-wave {
  position: absolute;
  right: 2.8rem;
  display: flex;
  align-items: center;
  gap: 3px;
  height: 18px;
  opacity: 0.35;
  transition: opacity 0.25s ease;
  pointer-events: none;
}

.chat-input-glow-frame:focus-within .input-active-wave {
  opacity: 1;
}

.wave-bar {
  width: 3px;
  height: 6px;
  background: #38bdf8;
  border-radius: 2px;
  box-shadow: 0 0 4px #38bdf8;
  animation: waveBarDance 1.2s ease-in-out infinite alternate;
}

.wave-bar:nth-child(1) { animation-delay: 0s; height: 8px; }
.wave-bar:nth-child(2) { animation-delay: 0.2s; height: 14px; }
.wave-bar:nth-child(3) { animation-delay: 0.4s; height: 10px; }

@keyframes waveBarDance {
  0% { transform: scaleY(0.4); }
  100% { transform: scaleY(1.3); }
}

/* One-Click Input Clear Button */
.input-clear-btn {
  position: absolute;
  right: 1rem;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #94a3b8;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: none;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.72rem;
  transition: all 0.2s ease;
  animation: popIn 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.input-clear-btn.visible {
  display: flex;
}

.input-clear-btn:hover {
  background: rgba(239, 68, 68, 0.2);
  border-color: rgba(239, 68, 68, 0.4);
  color: #f87171;
  transform: scale(1.1);
}

@keyframes popIn {
  from { transform: scale(0); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

/* Send Button Polish & Active Flight */
.chat-send-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  background: linear-gradient(135deg, #0284c7 0%, #0ea5e9 50%, #38bdf8 100%);
  border: 1px solid #38bdf8;
  border-radius: var(--radius-full);
  padding: 0.8rem 1.45rem;
  font-size: 0.88rem;
  font-weight: 700;
  color: #ffffff;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 18px rgba(14, 165, 233, 0.4);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  flex-shrink: 0;
}

.chat-send-btn .send-icon {
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.chat-send-btn:hover .send-icon {
  transform: translateX(3px) translateY(-2px);
}

.chat-send-btn.sending .send-icon {
  animation: rocketFly 0.6s ease forwards;
}

@keyframes rocketFly {
  0% { transform: translate(0, 0) scale(1); opacity: 1; }
  50% { transform: translate(14px, -14px) scale(0.6); opacity: 0; }
  51% { transform: translate(-14px, 14px) scale(0.6); opacity: 0; }
  100% { transform: translate(0, 0) scale(1); opacity: 1; }
}

.chat-send-btn::after {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(60deg, transparent 40%, rgba(255, 255, 255, 0.25) 50%, transparent 60%);
  transform: rotate(25deg);
  animation: sendGleam 4s infinite linear;
}

@keyframes sendGleam {
  0% { transform: translateX(-100%) rotate(25deg); }
  20%, 100% { transform: translateX(100%) rotate(25deg); }
}

.chat-send-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(56, 189, 248, 0.55);
}

.chat-send-btn:active {
  transform: translateY(1px);
}

.chat-kbd-hint {
  font-size: 0.68rem;
  font-family: var(--font-mono);
  background: rgba(0, 0, 0, 0.25);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  margin-left: 0.2rem;
}

/* ==========================================================================
   RETRIEVAL HUD - RIGHT SIDEBAR TELEMETRY
   ========================================================================== */
.retrieval-hud {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  height: 100%;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.07) 0%, rgba(255, 255, 255, 0.015) 35%, rgba(10, 16, 35, 0.48) 100%), rgba(7, 11, 25, 0.42);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 22px;
  padding: 1rem 1.2rem;
  box-shadow: 0 22px 55px rgba(0, 0, 0, 0.48), inset 0 1px 1.5px rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(36px) saturate(210%) contrast(108%);
  -webkit-backdrop-filter: blur(36px) saturate(210%) contrast(108%);
  position: relative;
  overflow: hidden;
}

.retrieval-hud-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding-bottom: 0.9rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 0.9rem;
}

.retrieval-hud-title h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: #ffffff;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.retrieval-hud-title span {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #38bdf8;
}

/* Radar Scan Graphic in Empty State */
.radar-hud-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1rem 0.5rem;
  text-align: center;
  gap: 0.85rem;
}

.radar-screen {
  width: 130px;
  height: 130px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(14, 165, 233, 0.12) 0%, rgba(13, 19, 40, 0.95) 75%);
  border: 1.5px solid rgba(56, 189, 248, 0.35);
  position: relative;
  overflow: hidden;
  box-shadow: 0 0 25px rgba(56, 189, 248, 0.15), inset 0 0 20px rgba(56, 189, 248, 0.1);
}

.radar-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px dashed rgba(56, 189, 248, 0.25);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.radar-ring.r1 { width: 45px; height: 45px; }
.radar-ring.r2 { width: 85px; height: 85px; }

.radar-crosshair-h, .radar-crosshair-v {
  position: absolute;
  background: rgba(56, 189, 248, 0.18);
}
.radar-crosshair-h { top: 50%; left: 0; right: 0; height: 1px; }
.radar-crosshair-v { left: 50%; top: 0; bottom: 0; width: 1px; }

.radar-sweep-beam {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 65px;
  height: 65px;
  transform-origin: 0 0;
  background: conic-gradient(from 0deg, rgba(56, 189, 248, 0.55) 0deg, transparent 60deg);
  animation: radarSweep 3.2s linear infinite;
  border-radius: 0 65px 0 0;
}

@keyframes radarSweep {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.radar-blip {
  position: absolute;
  width: 6px;
  height: 6px;
  background: #38bdf8;
  border-radius: 50%;
  box-shadow: 0 0 8px #38bdf8;
  animation: blipPulse 3.2s infinite ease-in-out;
}

.radar-blip.b1 { top: 28%; left: 62%; animation-delay: 0.4s; }
.radar-blip.b2 { top: 68%; left: 34%; animation-delay: 1.6s; }
.radar-blip.b3 { top: 38%; left: 24%; animation-delay: 2.2s; }

@keyframes blipPulse {
  0%, 70%, 100% { opacity: 0.3; transform: scale(0.8); }
  20% { opacity: 1; transform: scale(1.4); box-shadow: 0 0 12px #38bdf8; }
}

.telemetry-specs {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  margin-top: 0.4rem;
}

.spec-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.45rem 0.75rem;
  border-radius: var(--radius-sm);
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 0.78rem;
}

.spec-label {
  color: #94a3b8;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.spec-value {
  color: #38bdf8;
  font-family: var(--font-mono);
  font-weight: 600;
}

/* Citation Source Cards (Populated) */
.citation-card {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  padding: 0.85rem 0.95rem;
  border-radius: var(--radius-md);
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(56, 189, 248, 0.22);
  margin-bottom: 0.75rem;
  animation: citationEntrance 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  transition: all 0.2s ease;
}

@keyframes citationEntrance {
  from { opacity: 0; transform: translateX(12px); }
  to { opacity: 1; transform: translateX(0); }
}

.citation-card:hover {
  border-color: #38bdf8;
  background: rgba(15, 23, 42, 0.95);
  box-shadow: 0 4px 18px rgba(56, 189, 248, 0.15);
  transform: translateY(-1px);
}

.citation-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.citation-title-wrap {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  overflow: hidden;
}

.citation-score-bar {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.2rem;
}

.score-track {
  flex: 1;
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
}

.score-fill {
  height: 100%;
  background: linear-gradient(90deg, #0ea5e9, #10b981);
  border-radius: 2px;
}

.citation-snippet {
  font-size: 0.76rem;
  line-height: 1.45;
  color: #cbd5e1;
  background: rgba(0, 0, 0, 0.25);
  padding: 0.6rem 0.75rem;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  font-family: var(--font-mono);
}

/* High-Tech Dropzone for File Uploads */
.dropzone {
  border: 2px dashed rgba(56, 189, 248, 0.35);
  background: rgba(15, 23, 42, 0.5);
  border-radius: var(--radius-md);
  padding: 2.25rem 1.5rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  cursor: pointer;
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.dropzone:hover, .dropzone.dragover {
  border-color: #38bdf8;
  background: rgba(56, 189, 248, 0.08);
  box-shadow: 0 0 24px rgba(56, 189, 248, 0.2), inset 0 0 16px rgba(56, 189, 248, 0.05);
  transform: translateY(-2px);
}

.dropzone-icon {
  width: 2.5rem;
  height: 2.5rem;
  color: #38bdf8;
  filter: drop-shadow(0 0 8px rgba(56, 189, 248, 0.5));
  transition: transform var(--transition-fast);
}

.dropzone:hover .dropzone-icon {
  transform: scale(1.1) translateY(-3px);
}

/* Real-Time Pipeline Stage Tracker HUD (Liquid Glass Modern AI SaaS) */
.stage-list {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 8px !important;
  margin: 1rem 0 !important;
  padding: 0 !important;
  align-items: stretch !important;
  justify-content: flex-start !important;
}

.stage-list > div,
.stage-list div {
  flex: 1 1 calc(25% - 8px) !important;
  min-width: 125px !important;
  padding: 10px 14px !important;
  font-size: 11.5px !important;
  font-weight: 700 !important;
  text-align: center !important;
  border-radius: 9999px !important;
  background: rgba(255, 255, 255, 0.82) !important;
  backdrop-filter: blur(16px) !important;
  -webkit-backdrop-filter: blur(16px) !important;
  border: 1px solid rgba(226, 232, 240, 0.85) !important;
  color: #334155 !important;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.03) !important;
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1) !important;
  text-transform: uppercase !important;
  letter-spacing: 0.04em !important;
  white-space: nowrap !important;
  overflow: visible !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}

.stage-list > div:hover,
.stage-list div:hover {
  background: #ffffff !important;
  border-color: rgba(37, 99, 235, 0.35) !important;
  color: #2563EB !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.08) !important;
}

.stage-list > div.active,
.stage-list div.active {
  background: linear-gradient(135deg, #2563EB 0%, #1D4ED8 100%) !important;
  border-color: #2563EB !important;
  color: #FFFFFF !important;
  box-shadow: 0 4px 16px rgba(37, 99, 235, 0.40) !important;
  transform: translateY(-1.5px) scale(1.02) !important;
}

.stage-list > div.completed,
.stage-list > div.done,
.stage-list div.completed,
.stage-list div.done {
  background: rgba(16, 185, 129, 0.12) !important;
  border-color: rgba(16, 185, 129, 0.35) !important;
  color: #059669 !important;
  font-weight: 700 !important;
}

/* Ingestion HUD Metrics Tiles (Liquid Glass Modern AI SaaS) */
.hud-metrics {
  display: grid !important;
  grid-template-columns: repeat(3, 1fr) !important;
  gap: 12px !important;
  margin-bottom: 1rem !important;
}

.hud-metric-box {
  background: rgba(255, 255, 255, 0.82) !important;
  backdrop-filter: blur(20px) saturate(130%) !important;
  -webkit-backdrop-filter: blur(20px) saturate(130%) !important;
  border: 1px solid rgba(226, 232, 240, 0.85) !important;
  border-radius: 14px !important;
  padding: 14px 16px !important;
  text-align: center !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.95), 0 4px 14px rgba(15, 23, 42, 0.03) !important;
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.hud-metric-box:hover {
  background: rgba(255, 255, 255, 0.95) !important;
  border-color: rgba(37, 99, 235, 0.4) !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.10) !important;
}

.hud-metric-box small {
  font-size: 11px !important;
  color: #64748B !important;
  text-transform: uppercase !important;
  font-weight: 700 !important;
  letter-spacing: 0.06em !important;
  display: block !important;
  margin-bottom: 4px !important;
}

.hud-metric-box strong {
  font-size: 22px !important;
  font-family: 'Plus Jakarta Sans', var(--font-mono), sans-serif !important;
  font-weight: 800 !important;
  color: #0F172A !important;
  display: block !important;
  letter-spacing: -0.02em !important;
}

/* 1-Click Embed Snippet Card Enhancement */
.embed-code-box {
  position: relative;
  background: rgba(7, 11, 20, 0.85);
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: var(--radius-md);
  padding: 1rem 1.25rem;
  font-family: var(--font-mono);
  font-size: 0.84rem;
  color: #38bdf8;
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.5), 0 0 14px rgba(56, 189, 248, 0.08);
  overflow-x: auto;
}

/* Checklist Items Hover Effect */
.checklist-item {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  padding: 0.9rem 1rem;
  background: rgba(15, 23, 42, 0.6);
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.06);
  transition: all var(--transition-fast);
}

.checklist-item:hover {
  border-color: rgba(56, 189, 248, 0.3);
  background: rgba(15, 23, 42, 0.85);
  transform: translateX(3px);
}

/* ==========================================================================
   ROLE-BASED THEME ENGINE:
   SUPER ADMIN (Amber / Gold Master) vs COMPANY ADMIN (Neon Cyan / Sky Blue)
   ========================================================================== */

/* ──────────────────────────────────────────────────────────────────────────
   1. SUPER ADMIN THEME (Apple iOS 26 Liquid Frosted Glass — Velvet Crimson & Wine)
   ────────────────────────────────────────────────────────────────────────── */
body.role-super-admin,
[data-admin-role="super_admin"] {
  --brand: #4f46e5;
  --brand-light: #818cf8;
  --brand-hover: #4338ca;
  --brand-dark: #3730a3;
  --brand-rgb: 79, 70, 229;
  --brand-soft: rgba(79, 70, 229, 0.12);
  --brand-soft-border: rgba(99, 102, 241, 0.32);
  --brand-glow: rgba(99, 102, 241, 0.35);

  --accent-ruby: #4f46e5;
  --accent-ruby-light: #818cf8;
  --accent-ruby-glow: rgba(99, 102, 241, 0.35);
}

/* Super Admin Liquid Frosted Glass Sidebar (Designer Arfin Style) */
body.role-super-admin .sidebar {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.07) 0%, rgba(255, 255, 255, 0.02) 40%, rgba(22, 10, 16, 0.75) 100%), rgba(12, 6, 9, 0.7) !important;
  backdrop-filter: blur(40px) saturate(180%) brightness(105%) !important;
  -webkit-backdrop-filter: blur(40px) saturate(180%) brightness(105%) !important;
  border-right: 1px solid rgba(255, 255, 255, 0.1) !important;
  box-shadow: 14px 0 45px rgba(0, 0, 0, 0.5), inset -1px 0 1px rgba(255, 255, 255, 0.12) !important;
}

/* Super Admin Topbar - Optical Frosted Crimson Rim */
body.role-super-admin .topbar {
  background: rgba(13, 7, 10, 0.65) !important;
  backdrop-filter: blur(30px) saturate(180%) !important;
  -webkit-backdrop-filter: blur(30px) saturate(180%) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.09) !important;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.35) !important;
}

/* Super Admin Sidebar Navigation Links */
body.role-super-admin .nav a {
  color: #94a3b8;
  border-radius: 12px;
  margin-bottom: 0.35rem;
  padding: 0.72rem 1rem;
  border-left: none;
  font-weight: 500;
  transition: all var(--transition-fast);
}

body.role-super-admin .nav a:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.07);
  border-left: none;
  transform: translateX(2px);
}

body.role-super-admin .nav a:hover .nav-icon {
  color: #818cf8;
  filter: drop-shadow(0 0 8px rgba(99, 102, 241, 0.5));
}

/* Super Admin Active Navigation Pill (Exact Coral-Rose Radiant Capsule with Chevron) */
body.role-super-admin .nav a.active {
  color: #ffffff !important;
  background: linear-gradient(90deg, rgba(79, 70, 229, 0.85) 0%, rgba(99, 102, 241, 0.65) 60%, rgba(67, 56, 202, 0.25) 100%) !important;
  border: 1px solid rgba(99, 102, 241, 0.38) !important;
  border-left: 1px solid rgba(99, 102, 241, 0.38) !important;
  border-radius: 12px !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.35), 0 4px 18px rgba(79, 70, 229, 0.35) !important;
  font-weight: 600;
  display: flex;
  align-items: center;
}

body.role-super-admin .nav a.active .nav-icon {
  color: #ffffff !important;
  filter: drop-shadow(0 0 8px rgba(99, 102, 241, 0.8)) !important;
}

body.role-super-admin .nav a.active::after {
  content: '';
  width: 6.5px;
  height: 6.5px;
  border-top: 2px solid rgba(255, 255, 255, 0.85);
  border-right: 2px solid rgba(255, 255, 255, 0.85);
  transform: rotate(45deg);
  margin-left: auto;
  margin-right: 0.35rem;
  flex-shrink: 0;
}

body.role-super-admin .nav-section-title {
  color: #818cf8;
  font-weight: 700;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-top-color: rgba(255, 255, 255, 0.08);
}

/* Super Admin Sidebar User Profile Pill Card (Matching "Lets arfin") */
body.role-super-admin .sidebar-user-card {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.75rem 0.95rem;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.07) 0%, rgba(255, 255, 255, 0.02) 50%, rgba(225, 29, 72, 0.06) 100%), rgba(18, 10, 14, 0.6) !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.15) !important;
  backdrop-filter: blur(25px) saturate(180%);
  -webkit-backdrop-filter: blur(25px) saturate(180%);
  margin-top: auto;
  transition: all var(--transition-normal);
}

body.role-super-admin .sidebar-user-card:hover {
  border-color: rgba(244, 63, 94, 0.4);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5), 0 0 18px rgba(225, 29, 72, 0.2);
  transform: translateY(-2px);
}

body.role-super-admin .sidebar-user-avatar {
  width: 2.35rem;
  height: 2.35rem;
  border-radius: 50%;
  background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-weight: 700;
  box-shadow: 0 0 14px rgba(99, 102, 241, 0.45), inset 0 1px 1px rgba(255, 255, 255, 0.5);
  flex-shrink: 0;
}

body.role-super-admin .sidebar-user-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
}

body.role-super-admin .sidebar-user-name {
  font-size: 0.86rem;
  font-weight: 600;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

body.role-super-admin .sidebar-user-role {
  font-size: 0.72rem;
  color: #fda4af;
  font-weight: 500;
}

body.role-super-admin .sidebar-logout-mini-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: rgba(255, 235, 242, 0.75);
  width: 2.1rem;
  height: 2.1rem;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

body.role-super-admin .sidebar-logout-mini-btn:hover {
  background: rgba(99, 102, 241, 0.25);
  border-color: rgba(99, 102, 241, 0.5);
  color: #ffffff;
  box-shadow: 0 0 12px rgba(99, 102, 241, 0.4);
}

/* Super Admin Primary Buttons */
body.role-super-admin .btn-primary {
  background: linear-gradient(135deg, #4f46e5 0%, #4338ca 60%, #3730a3 100%) !important;
  color: #ffffff !important;
  font-weight: 700 !important;
  border: 1px solid rgba(255, 255, 255, 0.22) !important;
  box-shadow: 0 4px 18px rgba(79, 70, 229, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.3) !important;
}

body.role-super-admin .btn-primary:hover {
  background: linear-gradient(135deg, #6366f1 0%, #4f46e5 60%, #4338ca 100%) !important;
  color: #ffffff !important;
  box-shadow: 0 8px 26px rgba(79, 70, 229, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.45) !important;
  transform: translateY(-2px);
}

/* Super Admin Laser Beams & Panels */
body.role-super-admin .laser-emitter,
body.role-super-admin .ops-laser-emitter,
body.role-super-admin .panel::before,
body.role-super-admin .card::before {
  background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.85), #ffffff, rgba(99, 102, 241, 0.85), transparent) !important;
  box-shadow: 0 0 18px rgba(79, 70, 229, 0.7) !important;
}

body.role-super-admin .panel:hover,
body.role-super-admin .card:hover {
  border-color: rgba(244, 63, 94, 0.35) !important;
}

body.role-super-admin .card-hover:hover {
  border-color: rgba(244, 63, 94, 0.5) !important;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55), 0 0 20px rgba(225, 29, 72, 0.15) !important;
}

/* Super Admin Active Plan Halo */
body.role-super-admin .plan-active-glow {
  border: 1.5px solid rgba(99, 102, 241, 0.65) !important;
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.5), 0 0 24px rgba(79, 70, 229, 0.25) !important;
}

body.role-super-admin .plan-active-glow::before {
  background: linear-gradient(90deg, transparent 0%, #4f46e5 50%, transparent 100%) !important;
  opacity: 1 !important;
}

@keyframes brandFloatMotionRuby {
  0%, 100% { transform: translateY(0); filter: drop-shadow(0 0 8px rgba(99, 102, 241, 0.45)); }
  50% { transform: translateY(-2px); filter: drop-shadow(0 0 14px rgba(99, 102, 241, 0.7)); }
}

body.role-super-admin .cyber-brand-mark {
  background: rgba(20, 10, 14, 0.85) !important;
  border-color: rgba(99, 102, 241, 0.35) !important;
  box-shadow: 0 0 16px rgba(79, 70, 229, 0.25), inset 0 0 8px rgba(79, 70, 229, 0.15) !important;
  animation: brandFloatMotionRuby 3.5s ease-in-out infinite !important;
}

body.role-super-admin .profile-avatar {
  background: linear-gradient(135deg, #6366f1, #4f46e5) !important;
  box-shadow: 0 0 10px rgba(99, 102, 241, 0.4) !important;
}

body.role-super-admin .section-kicker {
  color: #818cf8 !important;
  font-weight: 700;
}

body.role-super-admin .plan-price {
  color: #0F172A !important;
  text-shadow: none !important;
}

body.role-super-admin .role-tag.super-admin {
  background: rgba(99, 102, 241, 0.15) !important;
  color: #818cf8 !important;
  border: 1px solid rgba(99, 102, 241, 0.4) !important;
  box-shadow: 0 0 12px rgba(79, 70, 229, 0.25) !important;
  padding: 0.2rem 0.65rem;
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

body.role-super-admin .status-pill {
  background: rgba(16, 185, 129, 0.12) !important;
  border-color: rgba(16, 185, 129, 0.35) !important;
  color: #34d399 !important;
}

body.role-super-admin .status-dot {
  background: #10b981 !important;
  box-shadow: 0 0 8px #10b981 !important;
}

body.role-super-admin .status-dot::before {
  border-color: #10b981 !important;
}

body.role-super-admin .loading-strip span,
body.role-super-admin .progress-bar-striped {
  background-image: linear-gradient(
    45deg,
    rgba(255, 255, 255, 0.22) 25%,
    transparent 25%,
    transparent 50%,
    rgba(255, 255, 255, 0.22) 50%,
    rgba(255, 255, 255, 0.22) 75%,
    transparent 75%,
    transparent
  ) !important;
  background-color: #4f46e5 !important;
  box-shadow: 0 0 12px rgba(99, 102, 241, 0.4) !important;
}

/* Super Admin Operations Hub Hero & Components */
body.role-super-admin .ops-hero-card {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.86) 0%, rgba(248, 250, 255, 0.78) 55%, rgba(240, 246, 255, 0.72) 100%) !important;
  border-color: rgba(255, 255, 255, 0.90) !important;
  box-shadow: 0 24px 60px -15px rgba(15, 23, 42, 0.05), inset 0 1.5px 2px rgba(255, 255, 255, 0.98), inset 0 -1px 1px rgba(226, 232, 240, 0.35) !important;
  backdrop-filter: blur(32px) saturate(150%) !important;
}

body.role-super-admin .ops-hero-card::before,
body.role-super-admin .ops-laser-emitter,
body.role-super-admin .ops-laser-flare {
  display: none !important;
}

body.role-super-admin .ops-hero-title {
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Inter', system-ui, sans-serif !important;
  color: #0B132B !important;
  font-size: clamp(2.1rem, 3.2vw, 2.75rem) !important;
  font-weight: 650 !important;
  line-height: 1.18 !important;
  letter-spacing: -0.03em !important;
  margin: 0 0 1.05rem 0 !important;
  max-width: 760px !important;
}

body.role-super-admin .ops-hero-headline-accent {
  background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 45%, #4f46e5 100%) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  font-weight: 650 !important;
  display: inline-block !important;
}

body.role-super-admin .ops-status-capsule {
  background: rgba(255, 255, 255, 0.80) !important;
  border-color: rgba(226, 232, 240, 0.9) !important;
  color: #334155 !important;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.03), inset 0 1px 1px rgba(255, 255, 255, 0.95) !important;
}

body.role-super-admin .ops-radar-dot {
  background: #10b981 !important;
  box-shadow: 0 0 8px #10b981 !important;
}

body.role-super-admin .ops-radar-dot::before {
  border-color: #10b981 !important;
}

body.role-super-admin .ops-status-sub {
  color: #2563eb !important;
  font-weight: 650 !important;
}

body.role-super-admin .ops-btn-primary {
  background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 100%) !important;
  color: #ffffff !important;
  font-weight: 600 !important;
  font-size: 0.88rem !important;
  border: 1px solid rgba(255, 255, 255, 0.3) !important;
  box-shadow: 0 4px 16px rgba(37, 99, 235, 0.22), inset 0 1px 1px rgba(255, 255, 255, 0.4) !important;
}

body.role-super-admin .ops-btn-primary:hover {
  background: linear-gradient(135deg, #1e40af 0%, #1d4ed8 100%) !important;
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.32), inset 0 1px 1.5px rgba(255, 255, 255, 0.5) !important;
  transform: translateY(-1.5px) !important;
}

body.role-super-admin .ops-action-icon {
  background: rgba(79, 70, 229, 0.1) !important;
  border-color: rgba(99, 102, 241, 0.3) !important;
  color: #4f46e5 !important;
  box-shadow: 0 0 12px rgba(99, 102, 241, 0.15) !important;
}

body.role-super-admin .ops-action-card:hover .ops-action-chevron {
  background: rgba(79, 70, 229, 0.15) !important;
  border-color: rgba(99, 102, 241, 0.35) !important;
  color: #ffffff !important;
}

body.role-super-admin .ops-launch-section .section-kicker {
  color: #4f46e5 !important;
}

body.role-super-admin .ops-avatar-glow {
  background: rgba(79, 70, 229, 0.1) !important;
  border-color: rgba(99, 102, 241, 0.3) !important;
  color: #4f46e5 !important;
  box-shadow: 0 0 12px rgba(99, 102, 241, 0.15) !important;
}

body.role-super-admin .ops-btn-chat {
  background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%) !important;
  border: 1px solid rgba(255, 255, 255, 0.25) !important;
  color: #ffffff !important;
  font-weight: 700 !important;
  box-shadow: 0 3px 14px rgba(99, 102, 241, 0.3) !important;
}

body.role-super-admin .ops-btn-chat:hover {
  border-color: #818cf8 !important;
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.45) !important;
}

body.role-super-admin .ops-btn-glass {
  background: rgba(255, 255, 255, 0.80) !important;
  border: 1px solid rgba(0, 0, 0, 0.08) !important;
  color: #0F172A !important;
  font-weight: 600 !important;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.04) !important;
}

body.role-super-admin .ops-btn-glass:hover {
  background: #ffffff !important;
  border-color: rgba(99, 102, 241, 0.35) !important;
  color: #4f46e5 !important;
  transform: translateY(-2px);
}

body.role-super-admin .subtitle,
body.role-super-admin p,
body.role-super-admin .comp-subtitle,
body.role-super-admin .ops-hero-desc,
body.role-super-admin .ops-metric-kicker,
body.role-super-admin .ops-metric-panel .metric-label,
body.role-super-admin .ops-action-card p {
  color: var(--text-secondary, #64748B) !important;
}





/* ──────────────────────────────────────────────────────────────────────────
   2. COMPANY ADMIN THEME (Authentic Apple Liquid Glass SaaS Design System)
   ────────────────────────────────────────────────────────────────────────── */
:root,
body.role-company-admin,
[data-admin-role="company_admin"] {
  --brand: #2563eb;
  --brand-light: #3b82f6;
  --brand-hover: #1d4ed8;
  --brand-dark: #1e3a8a;
  --brand-rgb: 37, 99, 235;

  --accent-indigo: #6366f1;
  --status-emerald: #10b981;
  --status-amber: #f59e0b;

  --bg-page: #F4F7FB;
  --text-primary: #0F172A;
  --text-secondary: #475569;
  --text-muted: #64748B;

  /* 5-Level Liquid Glass Material System */
  --glass-l1-canvas: #F4F7FB;
  --glass-l2-toolbar: rgba(255, 255, 255, 0.65);
  --glass-l3-card: rgba(255, 255, 255, 0.62);
  --glass-l4-control: rgba(248, 250, 252, 0.82);
  --glass-l5-interactive: rgba(255, 255, 255, 0.88);

  --glass-border: 1px solid rgba(255, 255, 255, 0.70);
  --glass-border-subtle: 1px solid rgba(148, 163, 184, 0.18);
  --glass-specular: inset 0 1px 1px 0 rgba(255, 255, 255, 0.85);
  --glass-shadow: 0 8px 32px 0 rgba(30, 60, 100, 0.05);
  --glass-shadow-elevated: 0 12px 40px 0 rgba(30, 60, 100, 0.08);

  --glass-filter: blur(24px) saturate(130%);
}

/* ==========================================================================
   LEVEL 1: LIQUID FLOWING CANVAS (Subtle Organic Light Waves)
   ========================================================================== */
body.role-company-admin {
  background-color: #F4F7FB !important;
  background-image: 
    radial-gradient(at 15% 15%, rgba(219, 234, 254, 0.60) 0px, transparent 55%),
    radial-gradient(at 85% 20%, rgba(238, 242, 255, 0.55) 0px, transparent 50%),
    radial-gradient(at 50% 60%, rgba(241, 245, 249, 0.75) 0px, transparent 65%),
    radial-gradient(at 20% 85%, rgba(224, 242, 254, 0.45) 0px, transparent 55%),
    radial-gradient(at 80% 85%, rgba(237, 233, 254, 0.40) 0px, transparent 50%) !important;
  background-attachment: fixed !important;
  background-size: 135% 135% !important;
  animation: liquidCanvasShift 24s ease-in-out infinite alternate !important;
  color: #0F172A !important;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Inter", "Segoe UI", sans-serif !important;
  -webkit-font-smoothing: antialiased;
}

@keyframes liquidCanvasShift {
  0% {
    background-position: 0% 0%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 50% 100%;
  }
}

body.role-company-admin h1,
body.role-company-admin h2,
body.role-company-admin h3,
body.role-company-admin h4,
body.role-company-admin h5,
body.role-company-admin h6 {
  color: #0F172A !important;
  font-weight: 600;
  letter-spacing: -0.018em;
}

body.role-company-admin p,
body.role-company-admin .text-muted,
body.role-company-admin .subtitle,
body.role-company-admin .comp-subtitle {
  color: #64748B !important;
  font-weight: 400;
}

/* ==========================================================================
   LEVEL 2: FLOATING TRANSLUCENT FROSTED SIDEBAR
   ========================================================================== */
body.role-company-admin .sidebar {
  background: rgba(255, 255, 255, 0.65) !important;
  backdrop-filter: blur(24px) saturate(130%) !important;
  -webkit-backdrop-filter: blur(24px) saturate(130%) !important;
  border-right: 1px solid rgba(255, 255, 255, 0.70) !important;
  box-shadow: inset -1px 0 1px 0 rgba(255, 255, 255, 0.80), 4px 0 28px 0 rgba(30, 60, 100, 0.04) !important;
  color: #0F172A !important;
}

/* Sidebar Brand Header */
body.role-company-admin .sidebar .brand {
  padding: 20px 20px 16px 20px !important;
  border-bottom: 1px solid rgba(148, 163, 184, 0.14) !important;
}

body.role-company-admin .liquid-brand-mark {
  width: 36px !important;
  height: 36px !important;
  background: rgba(239, 246, 255, 0.85) !important;
  border: 1px solid rgba(191, 219, 254, 0.80) !important;
  border-radius: 11px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 3px 10px rgba(37, 99, 235, 0.12) !important;
}

body.role-company-admin .brand-copy strong {
  font-size: 15.5px !important;
  font-weight: 600 !important;
  color: #0F172A !important;
  letter-spacing: -0.02em !important;
}

body.role-company-admin .brand-copy small {
  font-size: 10px !important;
  font-weight: 600 !important;
  letter-spacing: 0.07em !important;
  color: #64748B !important;
  text-transform: uppercase !important;
}

/* Active Workspace Card */
body.role-company-admin .workspace-card {
  margin: 14px 12px !important;
  padding: 10px 12px !important;
  background: rgba(255, 255, 255, 0.65) !important;
  backdrop-filter: blur(16px) !important;
  -webkit-backdrop-filter: blur(16px) !important;
  border: 1px solid rgba(255, 255, 255, 0.75) !important;
  border-radius: 12px !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.8), 0 2px 8px rgba(30, 60, 100, 0.03) !important;
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
  text-decoration: none !important;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

body.role-company-admin .workspace-card:hover {
  background: rgba(255, 255, 255, 0.85) !important;
  border-color: rgba(191, 219, 254, 0.85) !important;
  transform: translateY(-1px) !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.95), 0 4px 14px rgba(37, 99, 235, 0.06) !important;
}

body.role-company-admin .workspace-avatar {
  width: 32px !important;
  height: 32px !important;
  border-radius: 9px !important;
  background: rgba(224, 238, 255, 0.85) !important;
  color: #2563eb !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  border: 1px solid rgba(191, 219, 254, 0.75) !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.6) !important;
}

body.role-company-admin .workspace-card small {
  font-size: 10px !important;
  font-weight: 600 !important;
  color: #94a3b8 !important;
  text-transform: uppercase !important;
  display: block !important;
}

body.role-company-admin .workspace-card strong {
  font-size: 13px !important;
  font-weight: 600 !important;
  color: #0F172A !important;
  display: block !important;
}

/* Nav Section Headers */
body.role-company-admin .sidebar .nav-section-title,
body.role-company-admin .sidebar .nav-label {
  color: #94a3b8 !important;
  font-size: 10.5px !important;
  font-weight: 600 !important;
  letter-spacing: 0.08em !important;
  text-transform: uppercase !important;
  padding: 18px 16px 6px 16px !important;
}

/* Navigation Links */
body.role-company-admin .sidebar .nav a,
body.role-company-admin .sidebar .nav-link {
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  padding: 8.5px 14px !important;
  margin: 2px 10px !important;
  border-radius: 10px !important;
  color: #475569 !important;
  font-size: 13.5px !important;
  font-weight: 500 !important;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1) !important;
  border: 1px solid transparent !important;
  text-decoration: none !important;
}

body.role-company-admin .sidebar .nav a svg,
body.role-company-admin .sidebar .nav-link svg {
  color: #64748B !important;
  font-size: 15px !important;
  transition: color 0.2s ease !important;
}

/* Hover Nav Link */
body.role-company-admin .sidebar .nav a:hover,
body.role-company-admin .sidebar .nav-link:hover {
  background: rgba(255, 255, 255, 0.70) !important;
  color: #0F172A !important;
  transform: translateX(2px) !important;
  box-shadow: 0 2px 6px rgba(30, 60, 100, 0.03) !important;
}

body.role-company-admin .sidebar .nav a:hover svg,
body.role-company-admin .sidebar .nav-link:hover svg {
  color: #2563eb !important;
}

/* Active Nav Link (True Liquid Glass Highlight) */
body.role-company-admin .sidebar .nav a.active,
body.role-company-admin .sidebar .nav-link.active {
  background: rgba(37, 99, 235, 0.08) !important;
  backdrop-filter: blur(16px) !important;
  -webkit-backdrop-filter: blur(16px) !important;
  border: 1px solid rgba(37, 99, 235, 0.20) !important;
  color: #1e3a8a !important;
  font-weight: 600 !important;
  box-shadow: inset 0 1px 1.5px rgba(255, 255, 255, 0.9), 0 2px 8px rgba(37, 99, 235, 0.05) !important;
}

body.role-company-admin .sidebar .nav a.active .nav-icon,
body.role-company-admin .sidebar .nav-link.active .nav-icon {
  background: rgba(37, 99, 235, 0.12) !important;
  color: #2563eb !important;
  border-radius: 7px !important;
  width: 24px !important;
  height: 24px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.6) !important;
}

body.role-company-admin .sidebar .nav a.active svg,
body.role-company-admin .sidebar .nav-link.active svg {
  color: #2563eb !important;
}

/* Sidebar Floating User Card at Bottom */
body.role-company-admin .sidebar-user-card {
  margin: 14px 12px !important;
  padding: 10px 12px !important;
  background: rgba(255, 255, 255, 0.75) !important;
  backdrop-filter: blur(16px) !important;
  -webkit-backdrop-filter: blur(16px) !important;
  border: 1px solid rgba(255, 255, 255, 0.85) !important;
  border-radius: 14px !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 4px 16px rgba(30, 60, 100, 0.04) !important;
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
}

body.role-company-admin .sidebar-user-avatar {
  width: 34px !important;
  height: 34px !important;
  border-radius: 50% !important;
  background: linear-gradient(135deg, #3b82f6 0%, #6366f1 100%) !important;
  color: #ffffff !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  flex-shrink: 0 !important;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.25) !important;
}

body.role-company-admin .sidebar-user-info {
  display: flex !important;
  flex-direction: column !important;
  overflow: hidden !important;
}

body.role-company-admin .sidebar-user-name {
  font-size: 13px !important;
  font-weight: 600 !important;
  color: #0F172A !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}

body.role-company-admin .sidebar-user-role {
  font-size: 11px !important;
  color: #64748B !important;
}

body.role-company-admin .sidebar-logout-mini-btn {
  margin-left: auto !important;
  background: transparent !important;
  border: none !important;
  color: #94a3b8 !important;
  padding: 6px !important;
  border-radius: 8px !important;
  cursor: pointer !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  transition: all 0.15s ease !important;
}

body.role-company-admin .sidebar-logout-mini-btn:hover {
  color: #ef4444 !important;
  background: rgba(254, 242, 242, 0.9) !important;
}

/* ==========================================================================
   LEVEL 2: FLOATING FROSTED TOOLBAR (Top Header)
   ========================================================================== */
body.role-company-admin .topbar {
  background: rgba(255, 255, 255, 0.65) !important;
  backdrop-filter: blur(24px) saturate(130%) !important;
  -webkit-backdrop-filter: blur(24px) saturate(130%) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.70) !important;
  box-shadow: inset 0 -1px 1px 0 rgba(148, 163, 184, 0.10), 0 4px 20px 0 rgba(30, 60, 100, 0.03) !important;
  padding: 12px 28px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  height: 64px !important;
}

/* Breadcrumbs */
body.role-company-admin .topbar-breadcrumb {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  font-size: 13px !important;
}

body.role-company-admin .breadcrumb-dim {
  color: #64748B !important;
  font-weight: 500 !important;
}

body.role-company-admin .breadcrumb-slash {
  color: #cbd5e1 !important;
  font-size: 11px !important;
}

body.role-company-admin .breadcrumb-bold {
  color: #0F172A !important;
  font-weight: 600 !important;
}

/* Topbar Actions Area */
body.role-company-admin .topbar-actions {
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
}

/* Apple/macOS Frosted Search Pill */
body.role-company-admin .topbar-search-pill {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  background: rgba(255, 255, 255, 0.72) !important;
  backdrop-filter: blur(16px) !important;
  -webkit-backdrop-filter: blur(16px) !important;
  border: 1px solid rgba(255, 255, 255, 0.85) !important;
  border-radius: 100px !important;
  padding: 6px 14px 6px 14px !important;
  font-size: 13px !important;
  color: #64748B !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 2px 8px rgba(30, 60, 100, 0.03) !important;
  cursor: pointer !important;
  min-width: 220px !important;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

body.role-company-admin .topbar-search-pill:hover {
  background: rgba(255, 255, 255, 0.92) !important;
  border-color: rgba(191, 219, 254, 0.9) !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 1), 0 4px 14px rgba(37, 99, 235, 0.08) !important;
}

body.role-company-admin .kbd-wrap {
  margin-left: auto !important;
  display: flex !important;
  gap: 3px !important;
}

body.role-company-admin .kbd-key {
  background: rgba(241, 245, 249, 0.85) !important;
  border: 1px solid rgba(203, 213, 225, 0.7) !important;
  border-radius: 5px !important;
  padding: 2px 5px !important;
  font-size: 10.5px !important;
  font-weight: 600 !important;
  color: #64748B !important;
  font-family: inherit !important;
}

/* Online Status Pill */
body.role-company-admin .status-pill {
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  background: rgba(236, 253, 245, 0.80) !important;
  border: 1px solid rgba(167, 243, 208, 0.75) !important;
  color: #065f46 !important;
  border-radius: 100px !important;
  padding: 5px 12px !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 2px 6px rgba(16, 185, 129, 0.05) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
}

body.role-company-admin .status-dot {
  width: 7px !important;
  height: 7px !important;
  border-radius: 50% !important;
  background: #10b981 !important;
  box-shadow: 0 0 6px rgba(16, 185, 129, 0.5) !important;
}

/* Topbar Icon Buttons */
body.role-company-admin .theme-quick-btn,
body.role-company-admin .topbar-icon-btn {
  width: 36px !important;
  height: 36px !important;
  border-radius: 50% !important;
  background: rgba(255, 255, 255, 0.75) !important;
  backdrop-filter: blur(16px) !important;
  -webkit-backdrop-filter: blur(16px) !important;
  border: 1px solid rgba(255, 255, 255, 0.85) !important;
  color: #475569 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 2px 8px rgba(30, 60, 100, 0.03) !important;
  position: relative !important;
}

body.role-company-admin .theme-quick-btn:hover,
body.role-company-admin .topbar-icon-btn:hover {
  background: rgba(255, 255, 255, 0.95) !important;
  color: #0F172A !important;
  border-color: rgba(191, 219, 254, 0.9) !important;
  transform: translateY(-1px) !important;
}

/* Profile Chip */
body.role-company-admin .profile-chip {
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  background: rgba(255, 255, 255, 0.75) !important;
  backdrop-filter: blur(16px) !important;
  -webkit-backdrop-filter: blur(16px) !important;
  border: 1px solid rgba(255, 255, 255, 0.85) !important;
  border-radius: 100px !important;
  padding: 4px 12px 4px 5px !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 2px 8px rgba(30, 60, 100, 0.03) !important;
}

body.role-company-admin .profile-avatar {
  width: 26px !important;
  height: 26px !important;
  border-radius: 50% !important;
  background: linear-gradient(135deg, #3b82f6 0%, #6366f1 100%) !important;
  color: #ffffff !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 11px !important;
  font-weight: 600 !important;
}

body.role-company-admin .profile-chip-text {
  display: flex !important;
  flex-direction: column !important;
  line-height: 1.15 !important;
}

body.role-company-admin .profile-chip-name {
  font-size: 12.5px !important;
  font-weight: 600 !important;
  color: #0F172A !important;
}

body.role-company-admin .profile-chip-sub {
  font-size: 10px !important;
  color: #64748B !important;
}

/* ==========================================================================
   LEVEL 3: LIQUID HERO CARD & SPECULAR LIGHT REFRACTION
   ========================================================================== */
.liquid-hero-card {
  position: relative !important;
  overflow: hidden !important;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.72) 0%, rgba(255, 255, 255, 0.58) 50%, rgba(240, 246, 255, 0.48) 100%) !important;
  backdrop-filter: blur(24px) saturate(130%) !important;
  -webkit-backdrop-filter: blur(24px) saturate(130%) !important;
  border: 1px solid rgba(255, 255, 255, 0.75) !important;
  border-radius: 24px !important;
  padding: 30px 34px !important;
  box-shadow: inset 0 1.5px 1.5px 0 rgba(255, 255, 255, 0.95), inset 0 -1px 1px 0 rgba(148, 163, 184, 0.15), 0 12px 36px rgba(30, 60, 100, 0.05) !important;
  margin-bottom: 24px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 24px !important;
}

/* Flowing Light Refraction (moving through glass, no 3D orbs/balls) */
.hero-light-sheen {
  position: absolute !important;
  top: 0 !important;
  left: -100% !important;
  width: 80% !important;
  height: 100% !important;
  background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.18) 50%, transparent 100%) !important;
  transform: skewX(-20deg) !important;
  animation: heroLightRefraction 12s ease-in-out infinite !important;
  pointer-events: none !important;
  z-index: 1 !important;
}

@keyframes heroLightRefraction {
  0%, 65% { left: -100%; opacity: 0; }
  70% { opacity: 0.8; }
  85% { left: 140%; opacity: 0.8; }
  90%, 100% { left: 140%; opacity: 0; }
}

/* Subtle ambient liquid wave glow behind hero */
.hero-liquid-wave {
  position: absolute !important;
  top: -40px !important;
  right: -30px !important;
  width: 420px !important;
  height: 300px !important;
  background: radial-gradient(circle at 60% 40%, rgba(59, 130, 246, 0.12) 0%, rgba(99, 102, 241, 0.07) 40%, rgba(240, 246, 255, 0.02) 75%, transparent 90%) !important;
  border-radius: 50% !important;
  filter: blur(40px) !important;
  pointer-events: none !important;
  z-index: 0 !important;
}

.hero-content {
  position: relative !important;
  z-index: 2 !important;
  max-width: 680px !important;
}

.hero-meta-row {
  display: flex !important;
  align-items: center !important;
  flex-wrap: wrap !important;
  gap: 10px !important;
  margin-bottom: 8px !important;
}

.hero-kicker {
  font-size: 11px !important;
  font-weight: 600 !important;
  letter-spacing: 0.08em !important;
  color: #2563eb !important;
  text-transform: uppercase !important;
}

.hero-sep {
  color: #cbd5e1 !important;
  font-size: 12px !important;
}

.hero-id-pill {
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  background: rgba(255, 255, 255, 0.70) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1px solid rgba(226, 232, 240, 0.85) !important;
  border-radius: 8px !important;
  padding: 3px 8px !important;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace !important;
  font-size: 11.5px !important;
  color: #475569 !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.8) !important;
}

.id-copy-mini-btn {
  background: transparent !important;
  border: none !important;
  color: #94a3b8 !important;
  cursor: pointer !important;
  padding: 2px !important;
  display: flex !important;
  align-items: center !important;
}

.id-copy-mini-btn:hover {
  color: #2563eb !important;
}

.hero-title {
  font-size: 28px !important;
  font-weight: 600 !important;
  color: #0F172A !important;
  letter-spacing: -0.025em !important;
  margin: 0 0 8px 0 !important;
}

.hero-description {
  font-size: 14px !important;
  color: #64748B !important;
  line-height: 1.55 !important;
  margin: 0 !important;
}

.hero-actions {
  position: relative !important;
  z-index: 2 !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: flex-end !important;
  gap: 12px !important;
  flex-shrink: 0 !important;
}

/* Status Ready Pill (Muted Emerald Glass) */
.status-ready-pill {
  display: inline-flex !important;
  align-items: center !important;
  gap: 7px !important;
  background: rgba(236, 253, 245, 0.80) !important;
  border: 1px solid rgba(167, 243, 208, 0.75) !important;
  color: #065f46 !important;
  border-radius: 100px !important;
  padding: 5px 13px !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 2px 6px rgba(16, 185, 129, 0.05) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
}

.status-dot-emerald {
  width: 7px !important;
  height: 7px !important;
  border-radius: 50% !important;
  background: #10B981 !important;
  box-shadow: 0 0 6px rgba(16, 185, 129, 0.5) !important;
}

/* ==========================================================================
   LEVEL 5: BUTTONS (Premium Blue Glass & Frosted Secondary)
   ========================================================================== */
.btn-navy,
.btn.btn-navy {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%) !important;
  color: #ffffff !important;
  border-radius: 11px !important;
  padding: 10px 22px !important;
  font-weight: 600 !important;
  font-size: 13.5px !important;
  border: 1px solid rgba(255, 255, 255, 0.25) !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.35), 0 4px 14px rgba(37, 99, 235, 0.28) !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  text-decoration: none !important;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.btn-navy:hover,
.btn.btn-navy:hover {
  background: linear-gradient(135deg, #1d4ed8 0%, #1e40af 100%) !important;
  transform: translateY(-1px) !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.45), 0 6px 20px rgba(37, 99, 235, 0.36) !important;
}

.btn-soft-blue,
.btn.btn-soft-blue {
  background: rgba(37, 99, 235, 0.92) !important;
  color: #ffffff !important;
  border-radius: 10px !important;
  padding: 8px 18px !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  border: 1px solid rgba(255, 255, 255, 0.25) !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.30), 0 3px 10px rgba(37, 99, 235, 0.22) !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  text-decoration: none !important;
  transition: all 0.2s ease !important;
}

.btn-soft-blue:hover,
.btn.btn-soft-blue:hover {
  background: #1d4ed8 !important;
  transform: translateY(-1px) !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.40), 0 5px 16px rgba(37, 99, 235, 0.30) !important;
}

.btn-glass-secondary,
.btn.btn-glass-secondary {
  background: rgba(255, 255, 255, 0.75) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  border: 1px solid rgba(255, 255, 255, 0.85) !important;
  color: #334155 !important;
  border-radius: 10px !important;
  padding: 8px 16px !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  text-decoration: none !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 2px 8px rgba(30, 60, 100, 0.03) !important;
  transition: all 0.2s ease !important;
}

.btn-glass-secondary:hover,
.btn.btn-glass-secondary:hover {
  background: rgba(255, 255, 255, 0.95) !important;
  border-color: rgba(191, 219, 254, 0.9) !important;
  color: #0F172A !important;
  transform: translateY(-1px) !important;
}

/* ==========================================================================
   LEVEL 3 & 4: EMBED & AI ACTIVATION PANELS
   ========================================================================== */
.liquid-panel {
  background: rgba(255, 255, 255, 0.62) !important;
  backdrop-filter: blur(24px) saturate(130%) !important;
  -webkit-backdrop-filter: blur(24px) saturate(130%) !important;
  border: 1px solid rgba(255, 255, 255, 0.70) !important;
  border-radius: 20px !important;
  padding: 24px 28px !important;
  box-shadow: inset 0 1px 1px 0 rgba(255, 255, 255, 0.85), 0 8px 30px 0 rgba(30, 60, 100, 0.05) !important;
  margin-bottom: 20px !important;
  position: relative !important;
  overflow: hidden !important;
}

.embed-top-row {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 16px !important;
  flex-wrap: wrap !important;
}

.embed-info-wrap {
  display: flex !important;
  align-items: center !important;
  gap: 14px !important;
}

.glass-icon-box {
  width: 42px !important;
  height: 42px !important;
  border-radius: 12px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 18px !important;
  font-weight: 600 !important;
  flex-shrink: 0 !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.8) !important;
}

.blue-glass-icon {
  background: rgba(219, 234, 254, 0.75) !important;
  color: #2563eb !important;
  border: 1px solid rgba(191, 219, 254, 0.85) !important;
}

.purple-glass-icon {
  background: rgba(238, 242, 255, 0.80) !important;
  color: #6366f1 !important;
  border: 1px solid rgba(224, 231, 255, 0.90) !important;
}

.embed-title {
  font-size: 16px !important;
  font-weight: 600 !important;
  color: #0F172A !important;
  margin: 0 0 2px 0 !important;
}

.embed-subtitle {
  font-size: 13px !important;
  color: #64748B !important;
  margin: 0 !important;
}

.embed-actions-wrap {
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
}

/* Level 4: Developer Code Snippet Panel (Subtle blue-gray contrast) */
.developer-code-panel {
  background: rgba(241, 245, 249, 0.85) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  border: 1px solid rgba(203, 213, 225, 0.70) !important;
  border-radius: 12px !important;
  padding: 10px 14px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 12px !important;
  margin-top: 16px !important;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.02) !important;
}

.developer-code-text {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace !important;
  font-size: 12px !important;
  color: #2563eb !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}

.code-copy-btn {
  background: transparent !important;
  border: none !important;
  color: #94a3b8 !important;
  cursor: pointer !important;
  padding: 4px !important;
  border-radius: 6px !important;
  transition: all 0.15s ease !important;
  flex-shrink: 0 !important;
}

.code-copy-btn:hover {
  color: #0F172A !important;
  background: rgba(226, 232, 240, 0.6) !important;
}

/* Activate Card */
.activate-card {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 20px !important;
  flex-wrap: wrap !important;
}

.activate-liquid-glow {
  position: absolute !important;
  top: -30px !important;
  right: -20px !important;
  width: 280px !important;
  height: 180px !important;
  background: radial-gradient(circle at 50% 50%, rgba(99, 102, 241, 0.10) 0%, rgba(37, 99, 235, 0.05) 50%, transparent 80%) !important;
  filter: blur(30px) !important;
  pointer-events: none !important;
  z-index: 0 !important;
}

.activate-info-wrap {
  position: relative !important;
  z-index: 1 !important;
  display: flex !important;
  align-items: center !important;
  gap: 14px !important;
}

.activate-actions-wrap {
  position: relative !important;
  z-index: 1 !important;
}

.activate-title {
  font-size: 16px !important;
  font-weight: 600 !important;
  color: #0F172A !important;
  margin: 0 0 2px 0 !important;
}

.activate-subtitle {
  font-size: 13px !important;
  color: #64748B !important;
  margin: 0 !important;
}

/* ==========================================================================
   LEVEL 3: 4-COLUMN METRIC CARDS (Mini Liquid Glass with Tint & Reflection)
   ========================================================================== */
.metrics-grid {
  display: grid !important;
  grid-template-columns: repeat(4, 1fr) !important;
  gap: 18px !important;
  margin: 24px 0 !important;
}

@media (max-width: 1180px) {
  .metrics-grid {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

@media (max-width: 640px) {
  .metrics-grid {
    grid-template-columns: 1fr !important;
  }
}

.metric-liquid-card {
  background: rgba(255, 255, 255, 0.64) !important;
  backdrop-filter: blur(24px) saturate(130%) !important;
  -webkit-backdrop-filter: blur(24px) saturate(130%) !important;
  border: 1px solid rgba(255, 255, 255, 0.75) !important;
  border-radius: 18px !important;
  padding: 22px !important;
  position: relative !important;
  overflow: hidden !important;
  box-shadow: inset 0 1px 1px 0 rgba(255, 255, 255, 0.85), 0 8px 24px rgba(30, 60, 100, 0.04) !important;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s ease, background 0.2s ease !important;
  display: flex !important;
  flex-direction: column !important;
  justify-content: space-between !important;
}

.metric-liquid-card:hover {
  transform: translateY(-2px) !important;
  background: rgba(255, 255, 255, 0.72) !important;
  box-shadow: inset 0 1px 1.5px 0 rgba(255, 255, 255, 0.95), 0 12px 32px rgba(30, 60, 100, 0.07) !important;
}

.metric-header {
  display: flex !important;
  align-items: flex-start !important;
  gap: 14px !important;
  margin-bottom: 16px !important;
}

.metric-icon-box {
  width: 38px !important;
  height: 38px !important;
  border-radius: 10px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 16px !important;
  flex-shrink: 0 !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.8) !important;
}

.metric-icon-box.icon-blue {
  background: rgba(224, 238, 255, 0.85) !important;
  color: #2563eb !important;
  border: 1px solid rgba(191, 219, 254, 0.85) !important;
}

.metric-icon-box.icon-emerald {
  background: rgba(209, 250, 229, 0.85) !important;
  color: #059669 !important;
  border: 1px solid rgba(167, 243, 208, 0.85) !important;
}

.metric-icon-box.icon-sky {
  background: rgba(224, 242, 254, 0.85) !important;
  color: #0284c7 !important;
  border: 1px solid rgba(186, 230, 253, 0.85) !important;
}

.metric-icon-box.icon-amber {
  background: rgba(254, 243, 199, 0.85) !important;
  color: #d97706 !important;
  border: 1px solid rgba(253, 230, 138, 0.85) !important;
}

.metric-meta {
  flex: 1 !important;
}

.metric-label {
  font-size: 10.5px !important;
  font-weight: 600 !important;
  letter-spacing: 0.06em !important;
  text-transform: uppercase !important;
  display: block !important;
  margin-bottom: 4px !important;
}

.label-blue { color: #2563eb !important; }
.label-emerald { color: #059669 !important; }
.label-sky { color: #0284c7 !important; }
.label-amber { color: #d97706 !important; }

.metric-value {
  display: flex !important;
  align-items: baseline !important;
  gap: 4px !important;
}

.metric-number {
  font-size: 28px !important;
  font-weight: 700 !important;
  color: #0F172A !important;
  line-height: 1.1 !important;
  letter-spacing: -0.025em !important;
}

.metric-total {
  font-size: 13px !important;
  color: #94a3b8 !important;
  font-weight: 500 !important;
}

.tier-name {
  font-size: 22px !important;
  font-weight: 700 !important;
  color: #0F172A !important;
}

.metric-progress-wrap {
  width: 100% !important;
  margin-top: auto !important;
}

/* Refined Minimal 4px Progress Bar */
.metric-bar-bg {
  height: 4px !important;
  width: 100% !important;
  background: rgba(226, 232, 240, 0.75) !important;
  border-radius: 100px !important;
  overflow: hidden !important;
  position: relative !important;
}

.metric-bar-fill {
  height: 100% !important;
  border-radius: 100px !important;
  transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.fill-blue { background: #2563eb !important; }
.fill-emerald { background: #10b981 !important; }
.fill-sky { background: #0284c7 !important; }
.fill-amber { background: #f59e0b !important; }

/* Subtle Liquid Reflection */
.metric-wave-glow {
  height: 2px !important;
  width: 50% !important;
  filter: blur(3px) !important;
  opacity: 0.40 !important;
  border-radius: 100px !important;
  margin-top: 2px !important;
}

.glow-blue { background: #2563eb !important; }
.glow-emerald { background: #10b981 !important; }
.glow-sky { background: #0ea5e9 !important; }
.glow-amber { background: #f59e0b !important; }

.metric-footer-link {
  margin-top: auto !important;
  padding-top: 4px !important;
}

.tier-upgrade-link {
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  color: #d97706 !important;
  text-decoration: none !important;
  transition: all 0.15s ease !important;
}

.tier-upgrade-link:hover {
  color: #b45309 !important;
  transform: translateX(2px) !important;
}

.tier-arrow {
  font-size: 11px !important;
}

/* ==========================================================================
   LEVEL 3 & 4: SUBPANELS (Activity Feed & Setup Checklist)
   ========================================================================== */
.columns-grid {
  display: grid !important;
  grid-template-columns: 1.4fr 1fr !important;
  gap: 20px !important;
  margin-top: 24px !important;
}

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

.subpanel-header {
  margin-bottom: 16px !important;
}

.subpanel-kicker {
  font-size: 10.5px !important;
  font-weight: 600 !important;
  letter-spacing: 0.08em !important;
  color: #2563eb !important;
  text-transform: uppercase !important;
  display: block !important;
  margin-bottom: 2px !important;
}

.subpanel-title {
  font-size: 16px !important;
  font-weight: 600 !important;
  color: #0F172A !important;
  margin: 0 0 2px 0 !important;
}

.subpanel-desc {
  font-size: 12.5px !important;
  color: #64748B !important;
  margin: 0 !important;
}

.table-wrap {
  overflow-x: auto !important;
}

.activity-tag {
  display: inline-block !important;
  padding: 3px 8px !important;
  border-radius: 6px !important;
  background: rgba(255, 255, 255, 0.70) !important;
  border: 1px solid rgba(226, 232, 240, 0.85) !important;
  font-size: 12px !important;
  font-weight: 500 !important;
  color: #334155 !important;
  text-transform: capitalize !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.8) !important;
}

.checklist-stack {
  display: flex !important;
  flex-direction: column !important;
  gap: 8px !important;
}

.checklist-item-row {
  display: flex !important;
  align-items: flex-start !important;
  gap: 12px !important;
  padding: 12px 14px !important;
  border-radius: 12px !important;
  background: rgba(248, 250, 252, 0.75) !important;
  border: 1px solid rgba(226, 232, 240, 0.80) !important;
  transition: all 0.15s ease !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.6) !important;
}

.checklist-item-row:hover {
  background: rgba(255, 255, 255, 0.92) !important;
  border-color: rgba(191, 219, 254, 0.8) !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 2px 8px rgba(37, 99, 235, 0.04) !important;
}

.check-icon {
  width: 22px !important;
  height: 22px !important;
  border-radius: 50% !important;
  background: rgba(209, 250, 229, 0.85) !important;
  border: 1px solid rgba(167, 243, 208, 0.85) !important;
  color: #059669 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  flex-shrink: 0 !important;
  margin-top: 1px !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.8) !important;
}

.pending-icon {
  width: 22px !important;
  height: 22px !important;
  border-radius: 50% !important;
  background: rgba(241, 245, 249, 0.85) !important;
  border: 1px solid rgba(226, 232, 240, 0.85) !important;
  color: #94a3b8 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 10px !important;
  flex-shrink: 0 !important;
  margin-top: 1px !important;
}

.checklist-meta {
  flex: 1 !important;
}

.checklist-meta strong {
  display: block !important;
  font-size: 13.5px !important;
  font-weight: 600 !important;
  color: #0F172A !important;
  margin-bottom: 2px !important;
}

.checklist-meta p {
  font-size: 12px !important;
  color: #64748B !important;
  margin: 0 !important;
  line-height: 1.4 !important;
}

.checklist-link {
  display: inline-block !important;
  font-size: 11.5px !important;
  font-weight: 600 !important;
  color: #2563eb !important;
  text-decoration: none !important;
  margin-top: 4px !important;
}

.checklist-link:hover {
  text-decoration: underline !important;
}

/* ==========================================================================
   TABLES & FORMS (Subtle Specular Liquid Glass)
   ========================================================================== */
body.role-company-admin .table-container,
body.role-company-admin .panel-table {
  background: rgba(255, 255, 255, 0.64) !important;
  backdrop-filter: blur(24px) saturate(130%) !important;
  -webkit-backdrop-filter: blur(24px) saturate(130%) !important;
  border: 1px solid rgba(255, 255, 255, 0.75) !important;
  border-radius: 18px !important;
  overflow: hidden !important;
  box-shadow: inset 0 1px 1px 0 rgba(255, 255, 255, 0.85), 0 8px 24px rgba(30, 60, 100, 0.04) !important;
}

body.role-company-admin .table thead th {
  background: rgba(248, 250, 252, 0.70) !important;
  color: #64748B !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.05em !important;
  border-bottom: 1px solid rgba(226, 232, 240, 0.75) !important;
  padding: 12px 18px !important;
}

body.role-company-admin .table tbody td {
  border-bottom: 1px solid rgba(226, 232, 240, 0.55) !important;
  color: #334155 !important;
  font-size: 13.5px !important;
  padding: 14px 18px !important;
}

body.role-company-admin .table tbody tr:hover td {
  background: rgba(255, 255, 255, 0.60) !important;
  color: #0F172A !important;
}

/* Form Inputs */
body.role-company-admin input,
body.role-company-admin select,
body.role-company-admin textarea {
  background: rgba(255, 255, 255, 0.75) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  border: 1px solid rgba(226, 232, 240, 0.85) !important;
  color: #0F172A !important;
  border-radius: 10px !important;
  padding: 8px 14px !important;
  font-size: 13.5px !important;
  transition: all 0.15s ease !important;
  box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.02) !important;
}

body.role-company-admin input:focus,
body.role-company-admin select:focus,
body.role-company-admin textarea:focus {
  background: rgba(255, 255, 255, 0.95) !important;
  border-color: #3b82f6 !important;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15) !important;
  outline: none !important;
}

/* Modals */
body.role-company-admin .modal-dialog,
body.role-company-admin .modal-content {
  background: rgba(255, 255, 255, 0.80) !important;
  backdrop-filter: blur(30px) saturate(140%) !important;
  -webkit-backdrop-filter: blur(30px) saturate(140%) !important;
  border: 1px solid rgba(255, 255, 255, 0.90) !important;
  border-radius: 20px !important;
  box-shadow: inset 0 1.5px 1.5px rgba(255, 255, 255, 0.95), 0 25px 60px rgba(15, 23, 42, 0.10) !important;
}

/* SaaS Footer */
.saas-footer {
  margin-top: 48px !important;
  padding-top: 24px !important;
  border-top: 1px solid rgba(226, 232, 240, 0.65) !important;
  text-align: center !important;
  color: #94a3b8 !important;
  font-size: 12px !important;
  padding-bottom: 28px !important;
}


/* ==========================================================================
   3. UNIVERSAL LIQUID GLASS SUBPAGE SYSTEM & LAYOUT ENHANCEMENTS
   ========================================================================== */

/* --- Strict Desktop Sidebar & Pinned Header Layout --- */
.sidebar {
  height: 100vh !important;
  max-height: 100vh !important;
  position: sticky !important;
  top: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  overflow: hidden !important;
  z-index: 40 !important;
}

.sidebar-header {
  flex-shrink: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  padding: 16px 14px 10px 14px !important;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16) !important;
  background: transparent !important;
}

.sidebar-header .brand {
  padding: 4px 6px 10px 6px !important;
  border-bottom: none !important;
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  text-decoration: none !important;
}

.sidebar-header .brand:hover {
  background: rgba(255, 255, 255, 0.4) !important;
  border-radius: 12px !important;
}

.sidebar-header .workspace-card {
  margin: 6px 0 0 0 !important;
}

.sidebar-scrollable-nav {
  flex: 1 1 0 !important;
  min-height: 0 !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  padding: 12px 10px !important;
  display: flex !important;
  flex-direction: column !important;
  scrollbar-width: thin !important;
  scrollbar-color: rgba(148, 163, 184, 0.3) transparent !important;
}

.sidebar-scrollable-nav::-webkit-scrollbar {
  width: 4px !important;
}

.sidebar-scrollable-nav::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.3) !important;
  border-radius: 4px !important;
}

.sidebar-scrollable-nav::-webkit-scrollbar-track {
  background: transparent !important;
}

.sidebar-scrollable-nav .nav {
  display: flex !important;
  flex-direction: column !important;
  gap: 3px !important;
}

.sidebar-user-card {
  flex-shrink: 0 !important;
  margin-top: auto !important;
  padding: 14px 16px !important;
  border-top: 1px solid rgba(148, 163, 184, 0.14) !important;
}

/* --- Mobile Menu Suppression on Desktop --- */
@media (min-width: 901px) {
  .mobile-menu,
  label.mobile-menu,
  .topbar label[for="nav-toggle"] {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
    width: 0 !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
  }
}

@media (max-width: 900px) {
  .mobile-menu {
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    background: rgba(255, 255, 255, 0.85) !important;
    backdrop-filter: blur(12px) !important;
    border: 1px solid rgba(226, 232, 240, 0.9) !important;
    border-radius: 10px !important;
    padding: 6px 12px !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    color: #0F172A !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04) !important;
    cursor: pointer !important;
  }
}

/* --- Hero Banner Universal Liquid Glass (Zero Cutoff & Pure Clarity) --- */
.panel-header-hero,
.page-hero-card {
  position: relative !important;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.88) 0%, rgba(240, 246, 255, 0.70) 100%) !important;
  backdrop-filter: blur(28px) saturate(140%) !important;
  -webkit-backdrop-filter: blur(28px) saturate(140%) !important;
  border: 1px solid rgba(255, 255, 255, 0.90) !important;
  border-radius: 22px !important;
  padding: 28px 32px !important;
  box-shadow: inset 0 1.5px 2px 0 rgba(255, 255, 255, 0.95), 0 12px 36px 0 rgba(30, 60, 100, 0.05) !important;
  margin-bottom: 24px !important;
  height: auto !important;
  min-height: fit-content !important;
  overflow: visible !important;
  display: block !important;
}

.panel-header-hero::before {
  content: "" !important;
  position: absolute !important;
  top: -40px !important;
  right: -40px !important;
  width: 220px !important;
  height: 220px !important;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.12) 0%, transparent 70%) !important;
  pointer-events: none !important;
  z-index: 1 !important;
}

/* Suppression of dark cyber remnants */
.header-laser-line,
.hero-laser-line,
.laser-strip,
.glow-strip {
  display: none !important;
}

/* Heading & Text Enforcements on Liquid Glass */
.panel-header-hero h1,
.panel-header-hero h2,
.panel-header-hero h3,
.page-hero-card h1,
.page-hero-card h2,
.page-hero-card h3 {
  color: #0F172A !important;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "SF Pro Display", "Inter", sans-serif !important;
  font-weight: 800 !important;
  font-size: 1.85rem !important;
  line-height: 1.3 !important;
  letter-spacing: -0.03em !important;
  margin: 4px 0 8px 0 !important;
  overflow: visible !important;
}

.panel-header-hero p,
.page-hero-card p {
  color: #475569 !important;
  font-size: 14.5px !important;
  line-height: 1.6 !important;
  font-weight: 450 !important;
  margin-top: 4px !important;
  max-width: 820px !important;
  overflow: visible !important;
}

.panel-header-hero .section-kicker,
.page-hero-card .section-kicker {
  color: #2563eb !important;
  font-weight: 700 !important;
  letter-spacing: 0.08em !important;
  text-transform: uppercase !important;
  font-size: 11px !important;
  display: inline-flex !important;
  align-items: center !important;
}

/* --- General Panels, Cards & Containers Across All Subpages --- */
.panel,
.card,
.table-wrap,
.table-container,
.stat-card,
.metric-card,
.metrics-card,
.chart-card,
.form-panel,
.settings-panel,
.chat-shell,
.faq-item,
.plan-card,
.doc-card {
  background: rgba(255, 255, 255, 0.65) !important;
  backdrop-filter: blur(24px) saturate(130%) !important;
  -webkit-backdrop-filter: blur(24px) saturate(130%) !important;
  border: 1px solid rgba(255, 255, 255, 0.78) !important;
  border-radius: 18px !important;
  box-shadow: inset 0 1px 1.5px 0 rgba(255, 255, 255, 0.92), 0 8px 30px 0 rgba(30, 60, 100, 0.04) !important;
  color: #0F172A !important;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.panel-head {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  padding: 16px 20px !important;
  border-bottom: 1px solid rgba(226, 232, 240, 0.6) !important;
}

.panel-head h2,
.panel-head h3,
.panel-head h4 {
  color: #0F172A !important;
  font-size: 16px !important;
  font-weight: 600 !important;
  margin: 0 !important;
}

.panel-head .section-kicker {
  font-size: 11px !important;
  color: #2563eb !important;
  font-weight: 600 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.06em !important;
  display: block !important;
  margin-bottom: 2px !important;
}

.panel-body,
.card-body {
  padding: 20px !important;
  color: #334155 !important;
}

/* --- Tables & Data Grids --- */
.table-wrap,
.table-container {
  overflow: hidden !important;
}

table,
.table {
  width: 100% !important;
  border-collapse: separate !important;
  border-spacing: 0 !important;
}

table thead th,
.table thead th {
  background: rgba(248, 250, 252, 0.75) !important;
  color: #64748B !important;
  font-size: 11.5px !important;
  font-weight: 600 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.05em !important;
  padding: 12px 18px !important;
  border-bottom: 1px solid rgba(226, 232, 240, 0.8) !important;
  text-align: left !important;
}

table tbody td,
.table tbody td {
  padding: 14px 18px !important;
  color: #334155 !important;
  font-size: 13.5px !important;
  border-bottom: 1px solid rgba(226, 232, 240, 0.5) !important;
  background: transparent !important;
  vertical-align: middle !important;
}

table tbody tr:hover td,
.table tbody tr:hover td {
  background: rgba(255, 255, 255, 0.6) !important;
  color: #0F172A !important;
}

table tbody tr:last-child td,
.table tbody tr:last-child td {
  border-bottom: none !important;
}

/* --- Buttons System --- */
.btn {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", sans-serif !important;
  font-weight: 500 !important;
  border-radius: 12px !important;
  padding: 9px 18px !important;
  font-size: 13.5px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  text-decoration: none !important;
  cursor: pointer !important;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.btn-primary,
.btn-navy {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%) !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
  box-shadow: inset 0 1px 1px 0 rgba(255, 255, 255, 0.35), 0 4px 14px 0 rgba(37, 99, 235, 0.25) !important;
}

.btn-primary:hover,
.btn-navy:hover {
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%) !important;
  box-shadow: inset 0 1px 1px 0 rgba(255, 255, 255, 0.45), 0 6px 18px 0 rgba(37, 99, 235, 0.35) !important;
  transform: translateY(-1px) !important;
  color: #ffffff !important;
}

.btn-secondary,
.btn-glass-secondary {
  background: rgba(255, 255, 255, 0.75) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  border: 1px solid rgba(203, 213, 225, 0.8) !important;
  color: #1e293b !important;
  box-shadow: inset 0 1px 1px 0 rgba(255, 255, 255, 0.8), 0 2px 8px 0 rgba(0, 0, 0, 0.03) !important;
}

.btn-secondary:hover,
.btn-glass-secondary:hover {
  background: rgba(255, 255, 255, 0.95) !important;
  border-color: rgba(148, 163, 184, 0.8) !important;
  transform: translateY(-1px) !important;
  color: #0F172A !important;
}

.btn-soft-blue {
  background: #2563eb !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.25) !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.35), 0 4px 14px rgba(37, 99, 235, 0.28) !important;
}

.btn-soft-blue:hover {
  background: #1d4ed8 !important;
  transform: translateY(-1px) !important;
  color: #ffffff !important;
}

.btn-danger {
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%) !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.3), 0 4px 14px rgba(239, 68, 68, 0.25) !important;
}

.btn-danger:hover {
  background: linear-gradient(135deg, #f87171 0%, #ef4444 100%) !important;
  transform: translateY(-1px) !important;
  color: #ffffff !important;
}

.btn-sm {
  padding: 6px 13px !important;
  font-size: 12.5px !important;
  border-radius: 9px !important;
}

/* --- Form Controls & Inputs --- */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="url"],
input[type="number"],
input[type="search"],
input[type="tel"],
select,
textarea {
  background: rgba(255, 255, 255, 0.82) !important;
  backdrop-filter: blur(14px) !important;
  -webkit-backdrop-filter: blur(14px) !important;
  border: 1px solid rgba(203, 213, 225, 0.85) !important;
  border-radius: 11px !important;
  color: #0F172A !important;
  padding: 10px 14px !important;
  font-size: 13.5px !important;
  transition: all 0.2s ease !important;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.02) !important;
  width: 100% !important;
  box-sizing: border-box !important;
}

input::placeholder,
textarea::placeholder {
  color: #94a3b8 !important;
}

input:focus,
select:focus,
textarea:focus {
  background: #ffffff !important;
  border-color: #3b82f6 !important;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.16), inset 0 1px 2px rgba(0, 0, 0, 0.02) !important;
  outline: none !important;
}

label {
  display: block !important;
  font-size: 13px !important;
  font-weight: 500 !important;
  color: #334155 !important;
  margin-bottom: 6px !important;
}

/* --- Badges & Status Tags --- */
.badge,
.tag,
.status-pill,
.status-tag {
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  padding: 4px 10px !important;
  border-radius: 20px !important;
  font-size: 12px !important;
  font-weight: 500 !important;
}

.badge-success,
.status-success {
  background: rgba(209, 250, 229, 0.8) !important;
  color: #065f46 !important;
  border: 1px solid rgba(110, 231, 183, 0.7) !important;
}

.badge-warning,
.status-warning {
  background: rgba(254, 243, 199, 0.8) !important;
  color: #92400e !important;
  border: 1px solid rgba(252, 211, 77, 0.7) !important;
}

.badge-info,
.status-info {
  background: rgba(224, 242, 254, 0.8) !important;
  color: #075985 !important;
  border: 1px solid rgba(186, 230, 253, 0.7) !important;
}

/* --- Scraping & Crawler Subpage (.scraping.html) --- */
.dropzone {
  background: rgba(255, 255, 255, 0.55) !important;
  backdrop-filter: blur(16px) !important;
  border: 2px dashed rgba(148, 163, 184, 0.4) !important;
  border-radius: 16px !important;
  padding: 32px 20px !important;
  text-align: center !important;
  transition: all 0.2s ease !important;
  cursor: pointer !important;
}

.dropzone:hover,
.dropzone.dragover {
  background: rgba(239, 246, 255, 0.7) !important;
  border-color: #3b82f6 !important;
}

.stage-list {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 8px !important;
}

.stage-item {
  background: rgba(255, 255, 255, 0.6) !important;
  border: 1px solid rgba(226, 232, 240, 0.75) !important;
  border-radius: 12px !important;
  padding: 10px 14px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  font-size: 13px !important;
}

/* --- Knowledge & Documents Subpage (knowledge.html) --- */
.doc-search-bar {
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  margin-bottom: 16px !important;
}

.doc-meta {
  font-size: 12px !important;
  color: #64748B !important;
}

/* --- Chat Playground Subpage Layout Alignment --- */
.chat-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(320px, 1fr);
  gap: 1.25rem;
  flex: 1;
  min-height: 540px;
  height: calc(100vh - 210px);
  max-height: 960px;
  overflow: hidden;
  align-items: stretch;
}

@media (max-width: 1024px) {
  .chat-shell {
    grid-template-columns: 1fr;
    height: auto;
    overflow: visible;
  }
}

.chat-hud-header {
  background: var(--bg-surface, #ffffff);
  border: 1px solid var(--border-subtle, rgba(226, 232, 240, 0.85));
  border-radius: 16px;
  padding: 0.85rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.03);
}

:root[data-theme="dark"] .chat-hud-header {
  background: rgba(10, 16, 35, 0.7);
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);
}

/* --- Curated FAQs Subpage (faqs.html) --- */
.faq-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr)) !important;
  gap: 16px !important;
}

.faq-card {
  background: rgba(255, 255, 255, 0.65) !important;
  backdrop-filter: blur(20px) !important;
  border: 1px solid rgba(255, 255, 255, 0.8) !important;
  border-radius: 16px !important;
  padding: 18px 20px !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 6px 24px rgba(30, 60, 100, 0.03) !important;
  transition: all 0.2s ease !important;
}

.faq-card:hover {
  transform: translateY(-2px) !important;
  background: rgba(255, 255, 255, 0.85) !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 1), 0 12px 32px rgba(30, 60, 100, 0.06) !important;
}

.faq-question {
  font-size: 15px !important;
  font-weight: 600 !important;
  color: #0F172A !important;
  margin-bottom: 8px !important;
}

.faq-answer {
  font-size: 13.5px !important;
  color: #475569 !important;
  line-height: 1.55 !important;
}

/* --- Analytics Subpage (analytics.html) --- */
.analytics-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)) !important;
  gap: 16px !important;
  margin-bottom: 20px !important;
}

.analytics-stat-card {
  background: rgba(255, 255, 255, 0.65) !important;
  backdrop-filter: blur(20px) !important;
  border: 1px solid rgba(255, 255, 255, 0.8) !important;
  border-radius: 16px !important;
  padding: 20px !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 6px 20px rgba(30, 60, 100, 0.03) !important;
}

.analytics-stat-value {
  font-size: 26px !important;
  font-weight: 700 !important;
  color: #0F172A !important;
  letter-spacing: -0.02em !important;
  margin: 6px 0 2px 0 !important;
}

.analytics-stat-label {
  font-size: 12px !important;
  font-weight: 600 !important;
  color: #64748B !important;
  text-transform: uppercase !important;
  letter-spacing: 0.05em !important;
}

/* --- Subscription Subpage (subscription.html) --- */
.subscription-plans-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)) !important;
  gap: 20px !important;
  margin-top: 20px !important;
}

.plan-card-liquid {
  background: rgba(255, 255, 255, 0.7) !important;
  backdrop-filter: blur(24px) !important;
  border: 1px solid rgba(255, 255, 255, 0.85) !important;
  border-radius: 20px !important;
  padding: 26px !important;
  box-shadow: inset 0 1.5px 1.5px rgba(255, 255, 255, 0.95), 0 10px 36px rgba(30, 60, 100, 0.05) !important;
  display: flex !important;
  flex-direction: column !important;
  justify-content: space-between !important;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.plan-card-liquid.active {
  border: 2px solid #3b82f6 !important;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.88), rgba(239, 246, 255, 0.7)) !important;
  box-shadow: 0 14px 44px rgba(37, 99, 235, 0.12) !important;
}

.plan-card-liquid:hover {
  transform: translateY(-4px) !important;
  box-shadow: 0 16px 44px rgba(30, 60, 100, 0.08) !important;
}

/* --- Settings Subpage (settings.html) --- */
.settings-section-card {
  background: rgba(255, 255, 255, 0.65) !important;
  backdrop-filter: blur(24px) !important;
  border: 1px solid rgba(255, 255, 255, 0.8) !important;
  border-radius: 18px !important;
  padding: 24px !important;
  margin-bottom: 20px !important;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.9), 0 8px 28px rgba(30, 60, 100, 0.03) !important;
}

/* --- Auth Pages (auth.html, onboarding.html) --- */
body.auth-body,
body.auth-page,
body.role-auth {
  height: auto !important;
  min-height: 100vh !important;
  max-height: none !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 2rem 1rem !important;
  background-color: #F4F7FB !important;
  background-image: 
    radial-gradient(at 20% 20%, rgba(219, 234, 254, 0.65) 0px, transparent 55%),
    radial-gradient(at 80% 25%, rgba(238, 242, 255, 0.60) 0px, transparent 50%),
    radial-gradient(at 50% 70%, rgba(241, 245, 249, 0.8) 0px, transparent 65%) !important;
  color: #0F172A !important;
}

.auth-card,
.login-card {
  background: rgba(255, 255, 255, 0.92) !important;
  backdrop-filter: blur(32px) saturate(140%) !important;
  -webkit-backdrop-filter: blur(32px) saturate(140%) !important;
  border: 1px solid rgba(255, 255, 255, 0.95) !important;
  border-radius: 24px !important;
  padding: 32px 28px !important;
  box-shadow: inset 0 1.5px 1.5px rgba(255, 255, 255, 0.98), 0 20px 60px rgba(15, 23, 42, 0.08) !important;
  max-width: 440px !important;
  width: 100% !important;
  margin: auto !important;
  overflow: visible !important;
}

.auth-card h1,
.auth-card h2,
.login-card h1,
.login-card h2 {
  color: #0F172A !important;
  font-weight: 700 !important;
  letter-spacing: -0.025em !important;
}

.auth-card p,
.login-card p {
  color: #475569 !important;
  font-size: 14px !important;
}

/* --- Universal Overrides for Leftover Inline White/Light Text on Subpages --- */
body.role-company-admin .panel-header-hero [style*="color: #ffffff"],
body.role-company-admin .panel-header-hero [style*="color:#ffffff"],
body.role-company-admin .panel-header-hero [style*="color: white"],
body.role-company-admin .panel-header-hero [style*="color:white"],
body.role-super-admin .panel-header-hero [style*="color: #ffffff"],
body.role-super-admin .panel-header-hero [style*="color:#ffffff"] {
  color: #0F172A !important;
}

body.role-company-admin .panel-header-hero [style*="color: #94a3b8"],
body.role-super-admin .panel-header-hero [style*="color: #94a3b8"] {
  color: #475569 !important;
}

/* ==========================================================================
   PERMANENT FIX: THEME STUDIO (TOP CARD) & DEVELOPER SPECS (BOTTOM CARD)
   ========================================================================== */

.theme-studio-panel,
section.panel:has(.appearance-grid),
.panel:has(.appearance-grid) {
  display: flex !important;
  flex-direction: column !important;
  flex-shrink: 0 !important;
  min-height: 400px !important;
  height: auto !important;
  overflow: visible !important;
  padding: 1.75rem 2rem !important;
  margin-bottom: 1.5rem !important;
  background: rgba(255, 255, 255, 0.72) !important;
  backdrop-filter: blur(28px) saturate(140%) !important;
  -webkit-backdrop-filter: blur(28px) saturate(140%) !important;
  border: 1px solid rgba(255, 255, 255, 0.88) !important;
  border-radius: 22px !important;
  box-shadow: inset 0 1.5px 2px rgba(255, 255, 255, 0.95), 0 10px 32px rgba(30, 60, 100, 0.05) !important;
}

.developer-specs-panel,
section.panel:has(.endpoint-list),
section.panel:has(details code) {
  display: flex !important;
  flex-direction: column !important;
  margin-top: 1.5rem !important;
  margin-bottom: 6rem !important;
  flex-shrink: 0 !important;
  min-height: fit-content !important;
  height: auto !important;
  overflow: visible !important;
  padding: 1.75rem 2rem !important;
  background: rgba(255, 255, 255, 0.72) !important;
  backdrop-filter: blur(28px) saturate(140%) !important;
  -webkit-backdrop-filter: blur(28px) saturate(140%) !important;
  border: 1px solid rgba(255, 255, 255, 0.88) !important;
  border-radius: 22px !important;
  box-shadow: inset 0 1.5px 2px rgba(255, 255, 255, 0.95), 0 10px 32px rgba(30, 60, 100, 0.05) !important;
}

.developer-shell {
  display: grid !important;
  grid-template-columns: 280px 1fr !important;
  gap: 1.5rem !important;
  align-items: start !important;
  flex-shrink: 0 !important;
  min-height: fit-content !important;
  height: auto !important;
}

@media (max-width: 1024px) {
  .developer-shell {
    grid-template-columns: 1fr !important;
  }
}


