/* ═══════════════════════════════════════════════════════════════════════════
   LP PORTAL v2.0 — assets/css/lp-portal.css
   AlphaVault AI · Limited Partner Intelligence Platform
   Light Mode (default) · Dark Mode · 100% Responsive
   ═══════════════════════════════════════════════════════════════════════════ */

/* ─────────────────────────────────────────────
   CSS CUSTOM PROPERTIES — LIGHT MODE (DEFAULT)
───────────────────────────────────────────── */
:root {
  /* Brand */
  --lp-primary:        #0f766e;
  --lp-primary-hover:  #0d6b64;
  --lp-primary-light:  rgba(15,118,110,.1);
  --lp-secondary:      #0891b2;
  --lp-purple:         #8b5cf6;
  --lp-blue:           #3b82f6;
  --lp-green:          #10b981;
  --lp-amber:          #f59e0b;
  --lp-red:            #ef4444;
  --lp-pink:           #ec4899;
  --lp-orange:         #f97316;
  --lp-cyan:           #06b6d4;

  /* Layout */
  --lp-sidebar-w:      240px;
  --lp-sidebar-w-col:  64px;
  --lp-header-h:       56px;

  /* Backgrounds */
  --lp-bg:             #f1f5f9;
  --lp-bg-alt:         #f8fafc;
  --lp-card-bg:        #ffffff;
  --lp-header-bg:      #ffffff;

  /* ── SIDEBAR LIGHT MODE (blanc) ── */
  --lp-sidebar-bg:          #ffffff;
  --lp-sidebar-border:      rgba(0,0,0,.08);
  --lp-sidebar-hover:       rgba(0,0,0,.04);
  --lp-sidebar-active:      rgba(15,118,110,.1);
  --lp-sidebar-text:        #475569;
  --lp-sidebar-text-active: #0f766e;
  --lp-sidebar-icon:        #94a3b8;
  --lp-sidebar-icon-active: #0f766e;
  --lp-sidebar-label-color: #94a3b8;
  --lp-sidebar-footer-border: rgba(0,0,0,.07);
  --lp-sidebar-dropdown-bg: #ffffff;
  --lp-sidebar-dropdown-border: rgba(0,0,0,.1);
  --lp-sidebar-dropdown-shadow: 0 -8px 32px rgba(0,0,0,.12);
  --lp-sidebar-user-hover:  rgba(0,0,0,.04);
  --lp-sidebar-toggle-bg:   #ffffff;
  --lp-sidebar-toggle-shadow: 0 2px 10px rgba(0,0,0,.18);

  /* Text */
  --lp-text:           #0f172a;
  --lp-text-muted:     #64748b;
  --lp-text-dim:       #94a3b8;
  --lp-text-inverse:   #ffffff;

  /* Borders */
  --lp-border:         rgba(0,0,0,.07);
  --lp-border-strong:  rgba(0,0,0,.12);

  /* Inputs */
  --lp-input-bg:       #f8fafc;
  --lp-input-border:   #e2e8f0;
  --lp-input-focus:    rgba(15,118,110,.3);

  /* Shadows */
  --lp-shadow-sm:      0 1px 3px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
  --lp-shadow:         0 4px 16px rgba(0,0,0,.08);
  --lp-shadow-lg:      0 8px 32px rgba(0,0,0,.12);
  --lp-shadow-xl:      0 20px 60px rgba(0,0,0,.15);

  /* Radius */
  --lp-radius:         8px;
  --lp-radius-lg:      12px;
  --lp-radius-xl:      16px;

  /* Transitions */
  --lp-transition:     all .2s ease;
  --lp-transition-slow:all .35s ease;

  /* Scrollbar */
  --lp-scrollbar-bg:   #e2e8f0;
  --lp-scrollbar-thumb:#cbd5e1;
}

/* ─────────────────────────────────────────────
 DARK MODE OVERRIDES
───────────────────────────────────────────── */
body.lp-dark {
  --lp-bg:             #0f172a;
  --lp-bg-alt:         #1e293b;
  --lp-card-bg:        #1e293b;
  --lp-header-bg:      #1e293b;

  /* ── SIDEBAR DARK MODE ── */
  --lp-sidebar-bg:          #020617;
  --lp-sidebar-border:      rgba(255,255,255,.04);
  --lp-sidebar-hover:       rgba(255,255,255,.06);
  --lp-sidebar-active:      rgba(15,118,110,.3);
  --lp-sidebar-text:        rgba(255,255,255,.6);
  --lp-sidebar-text-active: #ffffff;
  --lp-sidebar-icon:        rgba(255,255,255,.4);
  --lp-sidebar-icon-active: #10b981;
  --lp-sidebar-label-color: rgba(255,255,255,.25);
  --lp-sidebar-footer-border: rgba(255,255,255,.06);
  --lp-sidebar-dropdown-bg: #0f172a;
  --lp-sidebar-dropdown-border: rgba(255,255,255,.1);
  --lp-sidebar-dropdown-shadow: 0 -10px 40px rgba(0,0,0,.5);
  --lp-sidebar-user-hover:  rgba(255,255,255,.06);
  --lp-sidebar-toggle-bg:   #1e293b;
  --lp-sidebar-toggle-shadow: 0 2px 10px rgba(0,0,0,.5);

  --lp-text:           #e2e8f0;
  --lp-text-muted:     #94a3b8;
  --lp-text-dim:       #64748b;
  --lp-border:         rgba(255,255,255,.07);
  --lp-border-strong:  rgba(255,255,255,.12);
  --lp-input-bg:       #0f172a;
  --lp-input-border:   #334155;
  --lp-input-focus:    rgba(15,118,110,.4);
  --lp-shadow-sm:      0 1px 3px rgba(0,0,0,.3);
  --lp-shadow:         0 4px 16px rgba(0,0,0,.4);
  --lp-shadow-lg:      0 8px 32px rgba(0,0,0,.5);
  --lp-scrollbar-bg:   #1e293b;
  --lp-scrollbar-thumb:#334155;
}

/* ─────────────────────────────────────────────
 RESET & BASE
───────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body.lp-page {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 13px;
  line-height: 1.5;
  color: var(--lp-text);
  background: var(--lp-bg);
  overflow: hidden;
  height: 100vh;
  transition: background .3s ease, color .3s ease;
}

/* Custom Scrollbar */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: var(--lp-scrollbar-bg); }
::-webkit-scrollbar-thumb { background: var(--lp-scrollbar-thumb); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: var(--lp-primary); }

/* ─────────────────────────────────────────────
 APP SHELL
───────────────────────────────────────────── */
#lpApp {
  display: flex;
  height: 100vh;
  overflow: hidden;
  position: relative;
}

/* ─────────────────────────────────────────────
 MOBILE BACKDROP
───────────────────────────────────────────── */
#lpMobileBackdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.5);
  z-index: 999;
  backdrop-filter: blur(2px);
}

/* ═══════════════════════════════════════════
 SIDEBAR
═══════════════════════════════════════════ */
#lpSidebar {
  width: var(--lp-sidebar-w);
  min-width: var(--lp-sidebar-w);
  height: 100vh;
  background: var(--lp-sidebar-bg);
  display: flex;
  flex-direction: column;
  position: relative;
  flex-shrink: 0;
  transition: width .25s ease, min-width .25s ease, background .3s ease;
  overflow: hidden;
  z-index: 100;
  border-right: 1px solid var(--lp-sidebar-border);
  box-shadow: 2px 0 12px rgba(0,0,0,.06);
}

body.lp-dark #lpSidebar {
  box-shadow: none;
}

/* Collapsed */
#lpSidebar.collapsed {
  width: var(--lp-sidebar-w-col);
  min-width: var(--lp-sidebar-w-col);
}
#lpSidebar.collapsed .lp-sidebar-text,
#lpSidebar.collapsed .lp-new-btn-text,
#lpSidebar.collapsed .lp-nav-badge,
#lpSidebar.collapsed .lp-nav-label,
#lpSidebar.collapsed .lp-logo-text,
#lpSidebar.collapsed .lp-user-info,
#lpSidebar.collapsed #lpUserPlan,
#lpSidebar.collapsed #lpUserChevron {
  display: none !important;
  opacity: 0;
}
#lpSidebar.collapsed .lp-logo-icon { display: block !important; }
#lpSidebar.collapsed .lp-new-btn {
  padding: 10px;
  justify-content: center;
}
#lpSidebar.collapsed .lp-nav-item {
  padding: 10px;
  justify-content: center;
}
#lpSidebar.collapsed .lp-sidebar-user-trigger {
  padding: 8px;
  justify-content: center;
}

/* Logo */
.lp-sidebar-logo-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 18px 16px 14px;
  text-decoration: none;
  flex-shrink: 0;
  border-bottom: 1px solid var(--lp-sidebar-border);
}
.lp-logo-text {
  height: 22px;
  width: auto;
  object-fit: contain;
  transition: opacity .2s;
}
.lp-logo-icon {
  width: 28px;
  height: 28px;
  object-fit: contain;
  flex-shrink: 0;
  display: none;
}

/* New Fund Button */
.lp-new-wrap {
  padding: 12px 12px 8px;
  flex-shrink: 0;
}
.lp-new-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  background: linear-gradient(135deg, var(--lp-primary), #0d9488);
  color: #fff;
  border: none;
  border-radius: var(--lp-radius-lg);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: var(--lp-transition);
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(15,118,110,.35);
}
.lp-new-btn:hover {
  background: linear-gradient(135deg, #0d9488, #0f766e);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(15,118,110,.45);
}
.lp-new-btn i { font-size: 11px; flex-shrink: 0; }

/* Sidebar Scroll */
.lp-sidebar-scroll {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding-bottom: 8px;
}

/* Nav */
.lp-nav { padding: 4px 0; }
.lp-nav-section { margin-bottom: 4px; }
.lp-nav-label {
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .8px;
  text-transform: uppercase;
  color: var(--lp-sidebar-label-color);
  padding: 10px 16px 4px;
  white-space: nowrap;
  overflow: hidden;
}
.lp-nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  margin: 1px 8px;
  border-radius: var(--lp-radius-lg);
  cursor: pointer;
  transition: var(--lp-transition);
  color: var(--lp-sidebar-text);
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  position: relative;
}
.lp-nav-item:hover {
  background: var(--lp-sidebar-hover);
  color: var(--lp-text);
}
body.lp-dark .lp-nav-item:hover {
  color: rgba(255,255,255,.9);
}
.lp-nav-item.active {
  background: var(--lp-sidebar-active);
  color: var(--lp-sidebar-text-active);
}
body.lp-dark .lp-nav-item.active {
  color: #fff;
}
.lp-nav-item.active .lp-nav-item-icon {
  color: var(--lp-sidebar-icon-active);
}
.lp-nav-item-icon {
  width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  flex-shrink: 0;
  color: var(--lp-sidebar-icon);
}
.lp-sidebar-text {
  font-size: 12px;
  font-weight: 600;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
}
.lp-nav-badge {
  font-size: 9px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 10px;
  background: var(--lp-red);
  color: #fff;
  min-width: 18px;
  text-align: center;
  flex-shrink: 0;
}

/* Recent Funds */
.lp-recent-fund {
  margin: 1px 8px;
  padding: 7px 10px;
  border-radius: 8px;
}
.lp-fund-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

/* Sidebar Footer */
.lp-sidebar-footer {
  padding: 8px 8px 10px;
  border-top: 1px solid var(--lp-sidebar-footer-border);
  position: relative;
  flex-shrink: 0;
}

/* User Trigger */
.lp-sidebar-user-trigger {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: var(--lp-radius-lg);
  cursor: pointer;
  transition: var(--lp-transition);
}
.lp-sidebar-user-trigger:hover {
  background: var(--lp-sidebar-user-hover);
}

/* User Dropdown (upward) */
.lp-sidebar-user-dropdown {
  position: absolute;
  bottom: calc(100% + 6px);
  left: 8px;
  right: 8px;
  background: var(--lp-sidebar-dropdown-bg);
  border: 1px solid var(--lp-sidebar-dropdown-border);
  border-radius: var(--lp-radius-xl);
  padding: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: var(--lp-transition);
  z-index: 200;
  box-shadow: var(--lp-sidebar-dropdown-shadow);
}
.lp-sidebar-user-dropdown.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.lp-sidebar-dropdown-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 8px 10px;
  border-bottom: 1px solid var(--lp-sidebar-border);
  margin-bottom: 6px;
}
.lp-sidebar-dropdown-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border-radius: var(--lp-radius);
  font-size: 12px;
  font-weight: 600;
  color: var(--lp-sidebar-text);
  text-decoration: none;
  cursor: pointer;
  transition: var(--lp-transition);
}
.lp-sidebar-dropdown-link:hover {
  background: var(--lp-sidebar-hover);
  color: var(--lp-text);
}
body.lp-dark .lp-sidebar-dropdown-link { color: rgba(255,255,255,.7); }
body.lp-dark .lp-sidebar-dropdown-link:hover { color: #fff; }
.lp-sidebar-dropdown-link i { width: 14px; font-size: 12px; }
.lp-sidebar-dropdown-logout {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border-radius: var(--lp-radius);
  font-size: 12px;
  font-weight: 600;
  color: var(--lp-red);
  background: none;
  border: none;
  cursor: pointer;
  width: 100%;
  margin-top: 4px;
  transition: var(--lp-transition);
}
.lp-sidebar-dropdown-logout:hover {
  background: rgba(239,68,68,.1);
}

/* ─────────────────────────────────────────────
 SIDEBAR TOGGLE — Cercle 100% visible
───────────────────────────────────────────── */
.lp-sidebar-toggle {
  position: absolute;
  top: 50%;
  right: -14px;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  background: var(--lp-sidebar-toggle-bg);
  border: 1.5px solid var(--lp-sidebar-border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 110;
  font-size: 10px;
  color: var(--lp-text-muted);
  box-shadow: var(--lp-sidebar-toggle-shadow);
  transition: var(--lp-transition);
  flex-shrink: 0;
}
/* Light mode : cercle blanc bien visible */
body:not(.lp-dark) .lp-sidebar-toggle {
  background: #ffffff;
  border-color: #e2e8f0;
  color: #64748b;
  box-shadow: 0 2px 10px rgba(0,0,0,.18), 0 0 0 1px rgba(0,0,0,.06);
}
/* Dark mode : cercle sombre bien visible */
body.lp-dark .lp-sidebar-toggle {
  background: #1e293b;
  border-color: rgba(255,255,255,.15);
  color: #94a3b8;
  box-shadow: 0 2px 10px rgba(0,0,0,.55), 0 0 0 1px rgba(255,255,255,.05);
}
.lp-sidebar-toggle:hover {
  background: var(--lp-primary) !important;
  color: #fff !important;
  border-color: var(--lp-primary) !important;
  box-shadow: 0 4px 16px rgba(15,118,110,.5) !important;
  transform: translateY(-50%) scale(1.08);
}

/* Mobile Close Button */
.lp-mobile-close {
  display: none;
  position: absolute;
  top: 12px;
  right: 12px;
  width: 28px;
  height: 28px;
  border: none;
  background: rgba(0,0,0,.08);
  color: var(--lp-text-muted);
  border-radius: 6px;
  cursor: pointer;
  font-size: 12px;
  align-items: center;
  justify-content: center;
  z-index: 10;
}
body.lp-dark .lp-mobile-close {
  background: rgba(255,255,255,.1);
  color: rgba(255,255,255,.7);
}

/* ═══════════════════════════════════════════
 MAIN
═══════════════════════════════════════════ */
#lpMain {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-width: 0;
}

/* ═══════════════════════════════════════════
 HEADER
═══════════════════════════════════════════ */
#lpHeader {
  height: var(--lp-header-h);
  min-height: var(--lp-header-h);
  background: var(--lp-header-bg);
  border-bottom: 1px solid var(--lp-border);
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 16px;
  flex-shrink: 0;
  position: relative;
  z-index: 50;
  transition: background .3s ease;
}

.lp-header-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 6px 10px;
  border: none;
  background: none;
  color: var(--lp-text-muted);
  border-radius: var(--lp-radius);
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  transition: var(--lp-transition);
  white-space: nowrap;
  flex-shrink: 0;
}
.lp-header-btn:hover {
  background: var(--lp-bg-alt);
  color: var(--lp-text);
}
.lp-btn-icon {
  width: 34px;
  height: 34px;
  padding: 0;
  border-radius: 8px;
  font-size: 14px;
  position: relative;
}

/* Breadcrumb */
.lp-breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}
.lp-breadcrumb-current {
  font-size: 14px;
  font-weight: 800;
  color: var(--lp-text);
}

/* Search */
.lp-search-wrap {
  flex: 1;
  max-width: 420px;
  position: relative;
}
.lp-search-icon {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--lp-text-muted);
  font-size: 12px;
  pointer-events: none;
}
.lp-search-input {
  width: 100%;
  padding: 7px 12px 7px 32px;
  border: 1.5px solid var(--lp-input-border);
  border-radius: var(--lp-radius-lg);
  background: var(--lp-input-bg);
  color: var(--lp-text);
  font-size: 12px;
  font-family: inherit;
  outline: none;
  transition: var(--lp-transition);
}
.lp-search-input:focus {
  border-color: var(--lp-primary);
  box-shadow: 0 0 0 3px var(--lp-input-focus);
}
.lp-search-input::placeholder { color: var(--lp-text-dim); }

/* Search Dropdown */
.lp-search-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: var(--lp-card-bg);
  border: 1px solid var(--lp-border-strong);
  border-radius: var(--lp-radius-xl);
  box-shadow: var(--lp-shadow-xl);
  z-index: 1000;
  overflow: hidden;
  max-height: 360px;
  overflow-y: auto;
}
.lp-search-result-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  transition: var(--lp-transition);
  border-bottom: 1px solid var(--lp-border);
}
.lp-search-result-item:last-child { border-bottom: none; }
.lp-search-result-item:hover { background: var(--lp-bg-alt); }
.lp-search-res-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  flex-shrink: 0;
}
.lp-search-res-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--lp-text);
}
.lp-search-res-sub {
  font-size: 10px;
  color: var(--lp-text-muted);
  margin-top: 1px;
}

/* Header Controls */
.lp-header-controls {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
  flex-shrink: 0;
}

/* Theme Toggle */
.lp-theme-toggle {
  width: 34px;
  height: 34px;
  border: none;
  background: var(--lp-bg-alt);
  color: var(--lp-text-muted);
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--lp-transition);
}
.lp-theme-toggle:hover {
  background: var(--lp-primary-light);
  color: var(--lp-primary);
}

/* User Avatar (header) */
.lp-user-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  transition: var(--lp-transition);
}
.lp-user-avatar:hover { opacity: .85; }

/* User Menu */
.lp-user-menu {
  position: absolute;
  top: calc(100% + 4px);
  right: 12px;
  background: var(--lp-card-bg);
  border: 1px solid var(--lp-border-strong);
  border-radius: var(--lp-radius-xl);
  box-shadow: var(--lp-shadow-xl);
  z-index: 500;
  min-width: 200px;
  padding: 6px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: var(--lp-transition);
}
.lp-user-menu.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.lp-context-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: var(--lp-radius);
  font-size: 12px;
  font-weight: 600;
  color: var(--lp-text);
  cursor: pointer;
  transition: var(--lp-transition);
}
.lp-context-item:hover { background: var(--lp-bg-alt); }
.lp-context-item i { width: 14px; font-size: 12px; color: var(--lp-text-muted); }
.lp-context-item.danger { color: var(--lp-red); }
.lp-context-item.danger:hover { background: rgba(239,68,68,.08); }
.lp-context-item.danger i { color: var(--lp-red); }

/* Notification Dropdown */
.lp-notif-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  width: 320px;
  background: var(--lp-card-bg);
  border: 1px solid var(--lp-border-strong);
  border-radius: var(--lp-radius-xl);
  box-shadow: var(--lp-shadow-xl);
  z-index: 500;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: var(--lp-transition);
}
.lp-notif-dropdown.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.lp-notif-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px 10px;
  border-bottom: 1px solid var(--lp-border);
}
.lp-notif-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--lp-border);
  transition: var(--lp-transition);
}
.lp-notif-item:hover { background: var(--lp-bg-alt); }
.lp-notif-item.unread { background: rgba(15,118,110,.04); }
.lp-notif-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  flex-shrink: 0;
}
.lp-notif-body { flex: 1; min-width: 0; }
.lp-notif-title {
  font-size: 11px;
  font-weight: 700;
  color: var(--lp-text);
  margin-bottom: 2px;
}
.lp-notif-sub {
  font-size: 10px;
  color: var(--lp-text-muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.lp-notif-time {
  font-size: 9px;
  color: var(--lp-text-dim);
  margin-top: 3px;
}
.lp-notif-empty {
  padding: 20px;
  text-align: center;
  font-size: 11px;
  color: var(--lp-text-muted);
}

/* ═══════════════════════════════════════════
 CONTENT AREA
═══════════════════════════════════════════ */
#lpContent {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 20px;
  position: relative;
}

/* ═══════════════════════════════════════════
 VIEWS
═══════════════════════════════════════════ */
.lp-view {
  display: none;
  animation: lpFadeIn .2s ease;
}
.lp-view.active { display: block; }

@keyframes lpFadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.lp-view-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.lp-section-title {
  font-size: 16px;
  font-weight: 800;
  color: var(--lp-text);
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
}
.lp-section-title i { color: var(--lp-primary); }

/* ─────────────────────────────────────────────
 QUICK ACTIONS BAR
───────────────────────────────────────────── */
.lp-quick-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

/* ─────────────────────────────────────────────
 FILTER TABS
───────────────────────────────────────────── */
.lp-filter-tabs {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}
.lp-filter-tab {
  padding: 6px 14px;
  border: 1.5px solid var(--lp-border-strong);
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  color: var(--lp-text-muted);
  background: var(--lp-card-bg);
  cursor: pointer;
  transition: var(--lp-transition);
  white-space: nowrap;
}
.lp-filter-tab:hover {
  border-color: var(--lp-primary);
  color: var(--lp-primary);
}
.lp-filter-tab.active {
  background: var(--lp-primary);
  border-color: var(--lp-primary);
  color: #fff;
}

/* Toggle Group */
.lp-tgl-group {
  display: flex;
  gap: 2px;
  background: var(--lp-bg-alt);
  border: 1px solid var(--lp-border);
  border-radius: 10px;
  padding: 3px;
}
.lp-tgl {
  padding: 4px 12px;
  border: none;
  border-radius: 7px;
  font-size: 11px;
  font-weight: 700;
  color: var(--lp-text-muted);
  background: none;
  cursor: pointer;
  transition: var(--lp-transition);
  white-space: nowrap;
}
.lp-tgl:hover { color: var(--lp-text); }
.lp-tgl.active {
  background: var(--lp-card-bg);
  color: var(--lp-primary);
  box-shadow: var(--lp-shadow-sm);
}

/* ═══════════════════════════════════════════
 STATS GRID (DASHBOARD)
═══════════════════════════════════════════ */
.lp-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}
.lp-stat-card {
  background: var(--lp-card-bg);
  border: 1px solid var(--lp-border);
  border-radius: var(--lp-radius-xl);
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  transition: var(--lp-transition);
  box-shadow: var(--lp-shadow-sm);
}
.lp-stat-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--lp-shadow);
  border-color: var(--lp-primary);
}
.lp-stat-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}
.lp-stat-body { flex: 1; min-width: 0; }
.lp-stat-value {
  font-size: 20px;
  font-weight: 900;
  color: var(--lp-text);
  line-height: 1.1;
}
.lp-stat-label {
  font-size: 10px;
  font-weight: 700;
  color: var(--lp-text-muted);
  text-transform: uppercase;
  letter-spacing: .4px;
  margin-top: 2px;
}
.lp-stat-sub {
  font-size: 9px;
  color: var(--lp-text-dim);
  margin-top: 1px;
}

/* ═══════════════════════════════════════════
 DASHBOARD GRID
═══════════════════════════════════════════ */
.lp-dashboard-grid {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 16px;
  align-items: start;
}
.lp-dashboard-col { display: flex; flex-direction: column; gap: 16px; }

/* ═══════════════════════════════════════════
 CARDS
═══════════════════════════════════════════ */
.lp-card {
  background: var(--lp-card-bg);
  border: 1px solid var(--lp-border);
  border-radius: var(--lp-radius-xl);
  overflow: hidden;
  box-shadow: var(--lp-shadow-sm);
  transition: box-shadow .2s ease;
}
.lp-card:hover { box-shadow: var(--lp-shadow); }
.lp-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px 10px;
  gap: 10px;
  flex-wrap: wrap;
}
.lp-card-title {
  font-size: 12px;
  font-weight: 800;
  color: var(--lp-text);
  display: flex;
  align-items: center;
  gap: 6px;
}
.lp-card-title i { font-size: 13px; }
.lp-chart-wrap {
  padding: 0 12px 14px;
}

/* ═══════════════════════════════════════════
 MINI STATS
═══════════════════════════════════════════ */
.lp-mini-stats {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.lp-mini-stat {
  background: var(--lp-card-bg);
  border: 1px solid var(--lp-border);
  border-radius: var(--lp-radius-lg);
  padding: 12px 16px;
  flex: 1;
  min-width: 140px;
  box-shadow: var(--lp-shadow-sm);
}
.lp-mini-stat-label {
  display: block;
  font-size: 10px;
  font-weight: 700;
  color: var(--lp-text-muted);
  text-transform: uppercase;
  letter-spacing: .4px;
  margin-bottom: 4px;
}
.lp-mini-stat-value {
  display: block;
  font-size: 18px;
  font-weight: 900;
  color: var(--lp-text);
}

/* ═══════════════════════════════════════════
 TABLES
═══════════════════════════════════════════ */
.lp-table-wrap {
  overflow-x: auto;
  border-radius: 0 0 var(--lp-radius-xl) var(--lp-radius-xl);
}
.lp-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11px;
}
.lp-table thead { position: sticky; top: 0; z-index: 5; }
.lp-table th {
  padding: 8px 12px;
  text-align: left;
  font-size: 9px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .6px;
  color: var(--lp-text-muted);
  background: var(--lp-bg-alt);
  border-bottom: 1px solid var(--lp-border);
  white-space: nowrap;
}
.lp-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--lp-border);
  vertical-align: middle;
  color: var(--lp-text);
}
.lp-table tbody tr { transition: var(--lp-transition); }
.lp-table tbody tr:hover { background: var(--lp-bg-alt); }
.lp-table tbody tr:last-child td { border-bottom: none; }

/* Progress Bar */
.lp-progress-bar {
  height: 5px;
  background: var(--lp-border);
  border-radius: 10px;
  overflow: hidden;
}
.lp-progress-fill {
  height: 100%;
  border-radius: 10px;
  transition: width .5s ease;
}

/* ═══════════════════════════════════════════
 BADGES
═══════════════════════════════════════════ */
.lp-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 9px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .4px;
  white-space: nowrap;
}

/* ═══════════════════════════════════════════
 FUND CARDS GRID
═══════════════════════════════════════════ */
.lp-funds-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 16px;
}
.lp-fund-card {
  background: var(--lp-card-bg);
  border: 1px solid var(--lp-border);
  border-radius: var(--lp-radius-xl);
  overflow: hidden;
  cursor: pointer;
  transition: var(--lp-transition);
  box-shadow: var(--lp-shadow-sm);
  display: flex;
  flex-direction: column;
}
.lp-fund-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--lp-shadow-lg);
  border-color: rgba(15,118,110,.25);
}
.lp-fund-card-top {
  padding: 16px;
  flex: 1;
  border-left: 4px solid var(--lp-primary);
}
.lp-fund-card-bottom {
  padding: 10px 16px;
  border-top: 1px solid var(--lp-border);
  background: var(--lp-bg-alt);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.lp-fund-name {
  font-size: 14px;
  font-weight: 800;
  color: var(--lp-text);
  margin-bottom: 2px;
}
.lp-fund-metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  margin-top: 12px;
}
.lp-fund-metric { text-align: center; }
.lp-fund-metric-val {
  font-size: 14px;
  font-weight: 900;
  color: var(--lp-text);
}
.lp-fund-metric-lbl {
  font-size: 8px;
  color: var(--lp-text-muted);
  text-transform: uppercase;
  letter-spacing: .3px;
  margin-top: 1px;
}

/* ═══════════════════════════════════════════
 DOCUMENT VAULT GRID
═══════════════════════════════════════════ */
.lp-doc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
}
.lp-doc-card {
  background: var(--lp-card-bg);
  border: 1px solid var(--lp-border);
  border-radius: var(--lp-radius-xl);
  padding: 14px;
  display: flex;
  gap: 12px;
  cursor: pointer;
  transition: var(--lp-transition);
  box-shadow: var(--lp-shadow-sm);
}
.lp-doc-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--lp-shadow);
  border-color: var(--lp-primary);
}
.lp-doc-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}
.lp-doc-body { flex: 1; min-width: 0; }
.lp-doc-name {
  font-size: 11px;
  font-weight: 700;
  color: var(--lp-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  margin-bottom: 4px;
}
.lp-doc-meta {
  font-size: 9px;
  color: var(--lp-text-muted);
  margin-bottom: 2px;
}

/* ═══════════════════════════════════════════
 ACTIVITY ITEMS
═══════════════════════════════════════════ */
.lp-activity-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 16px;
  border-bottom: 1px solid var(--lp-border);
  transition: var(--lp-transition);
}
.lp-activity-item:last-child { border-bottom: none; }
.lp-activity-item:hover { background: var(--lp-bg-alt); }
.lp-activity-icon {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════
 CAPITAL CALL ITEMS
═══════════════════════════════════════════ */
.lp-call-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  border-bottom: 1px solid var(--lp-border);
  transition: var(--lp-transition);
}
.lp-call-item:last-child { border-bottom: none; }
.lp-call-item:hover { background: var(--lp-bg-alt); }
.lp-call-item-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════
 COMMUNICATIONS
═══════════════════════════════════════════ */
.lp-comms-layout {
  display: grid;
  grid-template-columns: 260px 1fr 220px;
  gap: 0;
  height: calc(100vh - var(--lp-header-h) - 80px);
  background: var(--lp-card-bg);
  border: 1px solid var(--lp-border);
  border-radius: var(--lp-radius-xl);
  overflow: hidden;
  box-shadow: var(--lp-shadow-sm);
}
.lp-comms-sidebar {
  border-right: 1px solid var(--lp-border);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.lp-comms-sidebar-toolbar {
  display: flex;
  gap: 6px;
  align-items: center;
  padding: 12px;
  border-bottom: 1px solid var(--lp-border);
  flex-shrink: 0;
}
.lp-conv-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 10px 12px;
  cursor: pointer;
  border-bottom: 1px solid var(--lp-border);
  transition: var(--lp-transition);
}
.lp-conv-item:hover { background: var(--lp-bg-alt); }
.lp-conv-item.unread { background: rgba(15,118,110,.04); }
#lpConversationsList { flex: 1; overflow-y: auto; }
.lp-comms-main {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.lp-conv-header {
  padding: 14px 16px 12px;
  border-bottom: 1px solid var(--lp-border);
  flex-shrink: 0;
}
.lp-conv-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
}
.lp-conv-reply {
  padding: 12px;
  border-top: 1px solid var(--lp-border);
  flex-shrink: 0;
}
.lp-msg-bubble {
  max-width: 80%;
  padding: 10px 14px;
  border-radius: var(--lp-radius-lg);
  margin-bottom: 12px;
}
.lp-msg-gp {
  background: var(--lp-primary-light);
  border: 1px solid rgba(15,118,110,.15);
  margin-left: auto;
}
.lp-comms-broadcast {
  border-left: 1px solid var(--lp-border);
  padding: 16px;
  background: var(--lp-bg-alt);
}

/* ═══════════════════════════════════════════
 WATERFALL
═══════════════════════════════════════════ */
.lp-waterfall-result { padding: 16px; }
.lp-wf-summary-bar {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}
.lp-wf-sum-item {
  background: var(--lp-bg-alt);
  border-radius: var(--lp-radius-lg);
  padding: 12px;
  text-align: center;
}
.lp-wf-sum-label {
  font-size: 9px;
  font-weight: 700;
  color: var(--lp-text-muted);
  text-transform: uppercase;
  letter-spacing: .4px;
  margin-bottom: 4px;
}
.lp-wf-sum-val {
  font-size: 18px;
  font-weight: 900;
  color: var(--lp-text);
}
.lp-wf-sum-val.primary { color: var(--lp-primary); }
.lp-wf-bar-wrap {
  display: flex;
  height: 10px;
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 16px;
  gap: 2px;
}
.lp-wf-bar-seg {
  height: 100%;
  border-radius: 3px;
  transition: width .5s ease;
}
.lp-wf-steps { display: flex; flex-direction: column; gap: 8px; }
.lp-wf-step {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: var(--lp-bg-alt);
  border-radius: var(--lp-radius-lg);
  padding: 12px;
}
.lp-wf-step-num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 900;
  color: #fff;
  flex-shrink: 0;
}
.lp-wf-step-body { flex: 1; }
.lp-wf-step-title {
  font-size: 12px;
  font-weight: 800;
  color: var(--lp-text);
  margin-bottom: 2px;
}
.lp-wf-step-desc {
  font-size: 10px;
  color: var(--lp-text-muted);
  margin-bottom: 2px;
}
.lp-wf-step-total {
  font-size: 10px;
  color: var(--lp-text);
}

/* ═══════════════════════════════════════════
 REPORTING GRID
═══════════════════════════════════════════ */
.lp-report-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 14px;
}
.lp-report-card {
  background: var(--lp-card-bg);
  border: 1px solid var(--lp-border);
  border-radius: var(--lp-radius-xl);
  padding: 18px;
  transition: var(--lp-transition);
  box-shadow: var(--lp-shadow-sm);
}
.lp-report-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--lp-shadow);
}
.lp-qa-icon {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ═══════════════════════════════════════════
 EMPTY STATE
═══════════════════════════════════════════ */
.lp-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  text-align: center;
}
.lp-empty-state > i {
  font-size: 40px;
  color: var(--lp-border-strong);
  margin-bottom: 16px;
  opacity: .5;
}
.lp-empty-title {
  font-size: 15px;
  font-weight: 800;
  color: var(--lp-text-muted);
  margin-bottom: 6px;
}
.lp-empty-sub {
  font-size: 12px;
  color: var(--lp-text-dim);
  max-width: 300px;
  line-height: 1.6;
  margin-bottom: 16px;
}

/* ═══════════════════════════════════════════
 SPINNER / LOADING
═══════════════════════════════════════════ */
.lp-spinner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--lp-text-muted);
  font-size: 11px;
}
.lp-ring {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2.5px solid var(--lp-border-strong);
  border-top-color: var(--lp-primary);
  border-radius: 50%;
  animation: lpSpin .75s linear infinite;
  flex-shrink: 0;
}
@keyframes lpSpin { to { transform: rotate(360deg); } }

/* ═══════════════════════════════════════════
 TOAST
═══════════════════════════════════════════ */
.lp-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  border-radius: var(--lp-radius-xl);
  background: var(--lp-card-bg);
  box-shadow: var(--lp-shadow-xl);
  border: 1px solid var(--lp-border-strong);
  font-size: 12px;
  font-weight: 700;
  color: var(--lp-text);
  z-index: 9999;
  max-width: 360px;
  transform: translateY(20px);
  opacity: 0;
  transition: transform .3s ease, opacity .3s ease;
}
.lp-toast.show {
  transform: translateY(0);
  opacity: 1;
}
.lp-toast i { font-size: 16px; flex-shrink: 0; }

/* ═══════════════════════════════════════════
 BUTTONS
═══════════════════════════════════════════ */
.lp-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: var(--lp-radius-lg);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  border: 1.5px solid transparent;
  transition: var(--lp-transition);
  white-space: nowrap;
  font-family: inherit;
  text-decoration: none;
  flex-shrink: 0;
}
.lp-btn:disabled {
  opacity: .5;
  cursor: not-allowed;
  transform: none !important;
}

.lp-btn-primary {
  background: linear-gradient(135deg, var(--lp-primary), #0d9488);
  color: #fff;
  border-color: var(--lp-primary);
  box-shadow: 0 2px 8px rgba(15,118,110,.25);
}
.lp-btn-primary:hover:not(:disabled) {
  background: linear-gradient(135deg, var(--lp-primary-hover), var(--lp-primary));
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(15,118,110,.35);
}

.lp-btn-secondary {
  background: var(--lp-card-bg);
  color: var(--lp-text);
  border-color: var(--lp-border-strong);
}
.lp-btn-secondary:hover:not(:disabled) {
  border-color: var(--lp-primary);
  color: var(--lp-primary);
  background: var(--lp-primary-light);
}

.lp-btn-ghost {
  background: none;
  color: var(--lp-text-muted);
  border-color: transparent;
}
.lp-btn-ghost:hover:not(:disabled) {
  background: var(--lp-bg-alt);
  color: var(--lp-text);
  border-color: var(--lp-border);
}

/* ═══════════════════════════════════════════
 FORM ELEMENTS
═══════════════════════════════════════════ */
.lp-input-group {
  display: flex;
  flex-direction: column;
  gap: 5px;
  flex: 1;
}
.lp-input-row {
  display: flex;
  gap: 12px;
  margin-bottom: 12px;
}
.lp-input-label {
  font-size: 10px;
  font-weight: 800;
  color: var(--lp-text-muted);
  text-transform: uppercase;
  letter-spacing: .5px;
}
.lp-input, .lp-select, .lp-textarea {
  width: 100%;
  padding: 8px 10px;
  border: 1.5px solid var(--lp-input-border);
  border-radius: var(--lp-radius);
  background: var(--lp-input-bg);
  color: var(--lp-text);
  font-size: 12px;
  font-family: inherit;
  outline: none;
  transition: var(--lp-transition);
  appearance: none;
}
.lp-input:focus, .lp-select:focus, .lp-textarea:focus {
  border-color: var(--lp-primary);
  box-shadow: 0 0 0 3px var(--lp-input-focus);
}
.lp-input::placeholder, .lp-textarea::placeholder {
  color: var(--lp-text-dim);
}
.lp-select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%2364748b'%3E%3Cpath d='M7 7l3-3 3 3m0 6l-3 3-3-3'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 8px center;
  background-size: 14px;
  padding-right: 28px;
  cursor: pointer;
}
.lp-textarea {
  resize: vertical;
  min-height: 80px;
  line-height: 1.6;
}

/* Toggle Switch */
.lp-toggle-label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  color: var(--lp-text);
  padding: 6px 0;
  user-select: none;
}
.lp-toggle-label input[type="checkbox"] { display: none; }
.lp-toggle-switch {
  position: relative;
  width: 34px;
  height: 18px;
  background: var(--lp-border-strong);
  border-radius: 18px;
  flex-shrink: 0;
  transition: var(--lp-transition);
}
.lp-toggle-switch::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 14px;
  height: 14px;
  background: #fff;
  border-radius: 50%;
  transition: var(--lp-transition);
  box-shadow: 0 1px 3px rgba(0,0,0,.2);
}
.lp-toggle-label input:checked ~ .lp-toggle-switch {
  background: var(--lp-primary);
}
.lp-toggle-label input:checked ~ .lp-toggle-switch::after {
  left: 18px;
}

/* ═══════════════════════════════════════════
 MODALS
═══════════════════════════════════════════ */
.lp-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.45);
  backdrop-filter: blur(4px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  visibility: hidden;
  transition: var(--lp-transition);
}
.lp-modal-overlay.open {
  opacity: 1;
  visibility: visible;
}
.lp-modal {
  background: var(--lp-card-bg);
  border-radius: var(--lp-radius-xl);
  box-shadow: var(--lp-shadow-xl);
  border: 1px solid var(--lp-border-strong);
  display: flex;
  flex-direction: column;
  max-height: 90vh;
  width: 100%;
  max-width: 540px;
  transform: scale(.96) translateY(12px);
  transition: transform .25s ease;
  overflow: hidden;
}
.lp-modal-overlay.open .lp-modal {
  transform: scale(1) translateY(0);
}
.lp-modal-lg { max-width: 680px; }
.lp-modal-xl { max-width: 840px; }

.lp-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px 12px;
  border-bottom: 1px solid var(--lp-border);
  flex-shrink: 0;
  gap: 10px;
}
.lp-modal-title {
  font-size: 14px;
  font-weight: 800;
  color: var(--lp-text);
  display: flex;
  align-items: center;
  gap: 8px;
}
.lp-modal-close {
  width: 28px;
  height: 28px;
  border: none;
  background: var(--lp-bg-alt);
  color: var(--lp-text-muted);
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  transition: var(--lp-transition);
  flex-shrink: 0;
}
.lp-modal-close:hover {
  background: rgba(239,68,68,.1);
  color: var(--lp-red);
}

/* Modal Tabs */
.lp-modal-tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid var(--lp-border);
  background: var(--lp-bg-alt);
  flex-shrink: 0;
  overflow-x: auto;
}
.lp-modal-tab {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  font-size: 11px;
  font-weight: 700;
  color: var(--lp-text-muted);
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  transition: var(--lp-transition);
  white-space: nowrap;
}
.lp-modal-tab:hover { color: var(--lp-text); }
.lp-modal-tab.active {
  color: var(--lp-primary);
  border-bottom-color: var(--lp-primary);
  background: var(--lp-card-bg);
}

.lp-modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px 18px;
}
.lp-modal-body .lp-input-group { margin-bottom: 12px; }
.lp-modal-body .lp-input-row { margin-bottom: 0; }
.lp-modal-body .lp-input-row .lp-input-group { margin-bottom: 12px; }

.lp-modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding: 12px 18px 14px;
  border-top: 1px solid var(--lp-border);
  flex-shrink: 0;
}

/* Modal Tab Content */
.lp-modal-tab-content { display: none; }
.lp-modal-tab-content.active { display: block; }

/* ═══════════════════════════════════════════
 CONFIRM MODAL (dynamic)
═══════════════════════════════════════════ */
.lp-modal-overlay .lp-modal[style*="420px"] {
  max-width: 420px;
}

/* ═══════════════════════════════════════════
 TEAM MEMBER ROW
═══════════════════════════════════════════ */
.lp-team-member-row {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-bottom: 8px;
}

/* ═══════════════════════════════════════════
 ACCESS CONTROL ROW
═══════════════════════════════════════════ */
.lp-access-toolbar {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

/* ═══════════════════════════════════════════
 SCROLLABLE CONTAINERS
═══════════════════════════════════════════ */
.lp-scroll-box {
  max-height: 240px;
  overflow-y: auto;
  border: 1px solid var(--lp-border);
  border-radius: var(--lp-radius-lg);
}

/* ══════════════════════════════════════════════════════════
 RESPONSIVE — TABLET (≤ 1024px)
══════════════════════════════════════════════════════════ */
@media (max-width: 1024px) {
  .lp-dashboard-grid {
      grid-template-columns: 1fr;
  }
  .lp-dashboard-col-side {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
      gap: 16px;
  }
  .lp-stats-grid {
      grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  }
  .lp-comms-layout {
      grid-template-columns: 240px 1fr;
  }
  .lp-comms-broadcast { display: none; }
}

/* ══════════════════════════════════════════════════════════
 RESPONSIVE — MOBILE (≤ 768px)
══════════════════════════════════════════════════════════ */
@media (max-width: 768px) {

  /* Sidebar — off-canvas */
  #lpSidebar {
      position: fixed;
      left: 0;
      top: 0;
      height: 100vh;
      z-index: 1000;
      transform: translateX(-100%);
      transition: transform .3s ease;
      width: var(--lp-sidebar-w) !important;
      min-width: var(--lp-sidebar-w) !important;
      box-shadow: var(--lp-shadow-xl);
  }
  #lpSidebar.mobile-open {
      transform: translateX(0);
  }
  #lpSidebar.collapsed {
      width: var(--lp-sidebar-w) !important;
      min-width: var(--lp-sidebar-w) !important;
  }
  /* Re-show text on mobile */
  #lpSidebar .lp-sidebar-text,
  #lpSidebar .lp-new-btn-text,
  #lpSidebar .lp-nav-badge,
  #lpSidebar .lp-nav-label,
  #lpSidebar .lp-user-info,
  #lpSidebar #lpUserPlan,
  #lpSidebar #lpUserChevron {
      display: flex !important;
      opacity: 1 !important;
  }
  #lpSidebar.collapsed .lp-logo-icon { display: none !important; }
  #lpSidebar .lp-logo-text { display: block !important; }
  #lpSidebar .lp-new-btn { padding: 9px 14px; justify-content: flex-start; }
  #lpSidebar .lp-nav-item { padding: 9px 12px; justify-content: flex-start; }
  #lpSidebar .lp-sidebar-user-trigger { padding: 8px 10px; justify-content: flex-start; }

  .lp-mobile-close { display: flex; }
  #lpMobileBackdrop { display: none; }

  /* Main — full width */
  #lpMain { width: 100%; }

  /* Header */
  #lpHeader { padding: 0 10px; gap: 6px; }
  .lp-breadcrumb-current { font-size: 13px; }
  .lp-search-wrap { max-width: 180px; }
  .lp-search-input { font-size: 11px; }

  /* Hide some header elements on very small screens */
  .lp-header-controls > .lp-btn-icon:nth-child(1),
  .lp-header-controls > .lp-btn-icon:nth-child(2),
  .lp-header-controls > .lp-btn-icon:nth-child(3) {
      display: none;
  }

  /* Content */
  #lpContent { padding: 12px; }

  /* Quick Actions */
  .lp-quick-actions {
      overflow-x: auto;
      padding-bottom: 4px;
      flex-wrap: nowrap;
      gap: 6px;
  }
  .lp-quick-actions .lp-btn { font-size: 11px; padding: 6px 10px; flex-shrink: 0; }
  .lp-quick-actions .lp-btn span { display: none; }

  /* Stats */
  .lp-stats-grid {
      grid-template-columns: repeat(2, 1fr);
      gap: 8px;
  }
  .lp-stat-card { padding: 10px 12px; gap: 8px; }
  .lp-stat-icon { width: 32px; height: 32px; font-size: 13px; }
  .lp-stat-value { font-size: 16px; }

  /* Dashboard Grid */
  .lp-dashboard-grid { grid-template-columns: 1fr; }
  .lp-dashboard-col-side {
      display: grid;
      grid-template-columns: 1fr;
      gap: 12px;
  }

  /* View toolbar */
  .lp-view-toolbar { flex-direction: column; align-items: flex-start; gap: 8px; }
  .lp-view-toolbar > div:last-child { width: 100%; justify-content: flex-end; }

  /* Filter tabs */
  .lp-filter-tabs { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 2px; }
  .lp-filter-tab { flex-shrink: 0; }

  /* Fund grid */
  .lp-funds-grid { grid-template-columns: 1fr; }

  /* Fund metrics */
  .lp-fund-metrics { grid-template-columns: repeat(2, 1fr); }

  /* Doc grid */
  .lp-doc-grid { grid-template-columns: 1fr; }

  /* Report grid */
  .lp-report-grid { grid-template-columns: 1fr; }

  /* Mini stats */
  .lp-mini-stats { gap: 8px; }
  .lp-mini-stat { min-width: calc(50% - 4px); }

  /* Communications */
  .lp-comms-layout {
      grid-template-columns: 1fr;
      height: auto;
  }
  .lp-comms-sidebar {
      max-height: 280px;
      border-right: none;
      border-bottom: 1px solid var(--lp-border);
  }

  /* Modals */
  .lp-modal-overlay { padding: 8px; align-items: flex-end; }
  .lp-modal {
      max-width: 100%;
      max-height: 92vh;
      border-radius: var(--lp-radius-xl) var(--lp-radius-xl) 0 0;
      transform: translateY(30px);
  }
  .lp-modal-overlay.open .lp-modal { transform: translateY(0); }
  .lp-modal-lg, .lp-modal-xl { max-width: 100%; }
  .lp-modal-body { padding: 12px 14px; }
  .lp-modal-header { padding: 12px 14px 10px; }
  .lp-modal-footer { padding: 10px 14px 12px; flex-wrap: wrap; }
  .lp-modal-footer .lp-btn { flex: 1; justify-content: center; }

  /* Modal rows */
  .lp-input-row { flex-direction: column; }

  /* Tables */
  .lp-table-wrap { font-size: 10px; }
  .lp-table th { font-size: 8px; padding: 6px 8px; }
  .lp-table td { padding: 8px; }

  /* Toast */
  .lp-toast {
      bottom: 12px;
      right: 12px;
      left: 12px;
      max-width: unset;
  }

  /* Waterfall */
  .lp-wf-summary-bar { grid-template-columns: repeat(2, 1fr); }

  /* Sidebar toggle — hide on mobile */
  .lp-sidebar-toggle { display: none; }
}

/* ══════════════════════════════════════════════════════════
 RESPONSIVE — SMALL MOBILE (≤ 480px)
══════════════════════════════════════════════════════════ */
@media (max-width: 480px) {
  .lp-stats-grid { grid-template-columns: repeat(2, 1fr); }
  .lp-search-wrap { max-width: 130px; }
  .lp-search-input { padding: 6px 8px 6px 28px; font-size: 11px; }
  .lp-breadcrumb-current { font-size: 12px; max-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .lp-fund-metrics { grid-template-columns: repeat(2, 1fr); }
  .lp-mini-stat { min-width: 100%; }
  .lp-wf-summary-bar { grid-template-columns: 1fr; }
}

/* ══════════════════════════════════════════════════════════
 RESPONSIVE — LARGE SCREENS (≥ 1280px)
══════════════════════════════════════════════════════════ */
@media (min-width: 1280px) {
  .lp-stats-grid {
      grid-template-columns: repeat(8, 1fr);
  }
  .lp-dashboard-grid {
      grid-template-columns: 1fr 340px;
  }
}

@media (min-width: 1600px) {
  .lp-funds-grid {
      grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  }
  .lp-report-grid {
      grid-template-columns: repeat(4, 1fr);
  }
}

/* ══════════════════════════════════════════════════════════
 DARK MODE SPECIFIC ADJUSTMENTS
══════════════════════════════════════════════════════════ */
body.lp-dark .lp-fund-card:hover { border-color: rgba(15,118,110,.4); }
body.lp-dark .lp-stat-card:hover { border-color: rgba(15,118,110,.3); }
body.lp-dark .lp-btn-secondary { background: #1e293b; }
body.lp-dark .lp-btn-secondary:hover:not(:disabled) { background: rgba(15,118,110,.15); }
body.lp-dark .lp-notif-dropdown { background: #1e293b; }
body.lp-dark .lp-user-menu { background: #1e293b; }
body.lp-dark .lp-search-dropdown { background: #1e293b; }
body.lp-dark .lp-modal { background: #1e293b; }
body.lp-dark .lp-modal-tabs { background: #0f172a; }
body.lp-dark .lp-modal-tab.active { background: #1e293b; }
body.lp-dark .lp-table th { background: #0f172a; }
body.lp-dark .lp-comms-broadcast { background: #0f172a; }
body.lp-dark .lp-wf-step { background: #0f172a; }
body.lp-dark .lp-wf-sum-item { background: #0f172a; }
body.lp-dark .lp-tgl-group { background: #0f172a; }
body.lp-dark .lp-tgl.active { background: #1e293b; }
body.lp-dark .lp-select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%2394a3b8'%3E%3Cpath d='M7 7l3-3 3 3m0 6l-3 3-3-3'/%3E%3C/svg%3E");
}
body.lp-dark .lp-progress-bar { background: rgba(255,255,255,.08); }
body.lp-dark .lp-msg-gp { background: rgba(15,118,110,.15); border-color: rgba(15,118,110,.25); }
body.lp-dark #lpDocDropZone { background: rgba(15,118,110,.05); }
body.lp-dark .lp-fund-card-bottom { background: #0f172a; }
body.lp-dark .lp-report-card { background: #1e293b; }
body.lp-dark .lp-doc-card { background: #1e293b; }
body.lp-dark .lp-conv-item.unread { background: rgba(15,118,110,.08); }
body.lp-dark .lp-sidebar-user-dropdown { background: #0f172a; }

/* ══════════════════════════════════════════════════════════
 PRINT (minimal)
══════════════════════════════════════════════════════════ */
@media print {
  #lpSidebar, #lpHeader, .lp-quick-actions, .lp-view-toolbar { display: none !important; }
  #lpMain { margin: 0; }
  #lpContent { padding: 0; overflow: visible; }
  .lp-view { display: block !important; }
  .lp-card { box-shadow: none; border: 1px solid #ddd; }
}

/* Collab Panel open state */
.lp-collab-panel.open {
  display: flex !important;
  transform: translateX(0) !important;
}
/* Presence avatars */
.lp-presence-avatar {
  width: 28px; height: 28px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 10px; font-weight: 800; color: #fff;
  border: 2px solid var(--lp-header-bg);
  position: relative; cursor: default; transition: z-index .1s;
}
.lp-presence-dot {
  position: absolute; bottom: 0; right: 0;
  width: 8px; height: 8px; border-radius: 50%;
  background: #10b981; border: 2px solid var(--lp-header-bg);
}
/* Context badges */
.lp-context-badge {
  display: flex; align-items: center; gap: 6px;
  font-size: 11px; font-weight: 600; color: var(--lp-text);
  padding: 4px 10px; border-radius: 20px;
  background: var(--lp-bg-alt); border: 1px solid var(--lp-border);
}
.lp-role-pill {
  font-size: 9px; font-weight: 800; padding: 1px 6px;
  border-radius: 8px;
}
/* Mention dropdown */
.lp-mention-dropdown {
  position: absolute; bottom: 100%; left: 0; right: 0;
  background: var(--lp-card-bg); border: 1px solid var(--lp-border);
  border-radius: 10px; box-shadow: 0 4px 16px rgba(0,0,0,.12);
  z-index: 100; max-height: 200px; overflow-y: auto;
}
.lp-mention-item {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 12px; cursor: pointer; transition: background .15s;
}
.lp-mention-item:hover { background: var(--lp-bg-alt); }
/* Comment bubbles */
.lp-comment-bubble { margin-bottom: 10px; }
.lp-comment-mine .lp-comment-bubble-text { color: #fff; }
/* Task cards */
.lp-task-card {
  background: var(--lp-card-bg); border-radius: 12px;
  padding: 14px 16px; border: 1px solid var(--lp-border);
  transition: box-shadow .2s;
}
.lp-task-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,.08); }
.lp-task-completed { opacity: .65; }
/* Invitation banner */
.lp-invitation-banner { animation: slideDown .3s ease; }
@keyframes slideDown { from { transform: translateY(-10px); opacity: 0; } }
/* Member row */
.lp-member-row {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 0; border-bottom: 1px solid var(--lp-border);
}
/* User picker */
.lp-user-picker-results {
  border: 1px solid var(--lp-border); border-radius: 10px;
  max-height: 240px; overflow-y: auto; margin-top: 4px;
}
.lp-user-picker-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; cursor: pointer; transition: background .15s;
  border-bottom: 1px solid var(--lp-border);
}
.lp-user-picker-item:last-child { border-bottom: none; }
.lp-user-picker-item:hover { background: var(--lp-bg-alt); }
.lp-user-picker-item.selected {
  background: rgba(15,118,110,.08);
  border-left: 3px solid var(--lp-primary);
}

/* ── LP Portal Collaborative — Panels ───────── */
#lpCollabNotifPanel           { display: none; flex-direction: column; }
#lpCollabNotifPanel.open      { display: flex; }
#lpActivityFeedPanel          { display: flex !important; flex-direction: column; }
#lpActivityFeedPanel.open     { transform: translateX(0) !important; }

/* ── Mention @autocomplete ───────────────────── */
.lp-mention-dropdown {
  position:absolute; bottom:100%; left:0; right:0;
  background:var(--lp-card-bg);
  border:1px solid var(--lp-border);
  border-radius:10px;
  box-shadow:0 4px 16px rgba(0,0,0,.12);
  z-index:200; max-height:200px; overflow-y:auto;
}
.lp-mention-item {
  display:flex; align-items:center; gap:8px;
  padding:8px 12px; cursor:pointer; font-size:11px;
  border-bottom:1px solid var(--lp-border);
  color:var(--lp-text);
}
.lp-mention-item:last-child { border-bottom:none; }
.lp-mention-item:hover { background:var(--lp-bg-alt); }

/* ── User Picker (invite member modal) ────────── */
.lp-user-picker-results {
  max-height:220px; overflow-y:auto;
  border:1px solid var(--lp-border); border-radius:10px;
}
.lp-user-picker-item {
  display:flex; align-items:center; gap:10px;
  padding:10px 12px; cursor:pointer;
  border-bottom:1px solid var(--lp-border);
  transition:background .15s;
}
.lp-user-picker-item:last-child { border-bottom:none; }
.lp-user-picker-item:hover    { background:var(--lp-bg-alt); }
.lp-user-picker-item.selected { background:rgba(15,118,110,.08); }

/* ── Task card ───────────────────────────────── */
.lp-task-card {
  background:var(--lp-card-bg);
  border-radius:12px; padding:14px 16px;
  border:1px solid var(--lp-border);
  border-left:3px solid #7c3aed;
  transition:box-shadow .2s;
}
.lp-task-card:hover { box-shadow:0 4px 16px rgba(0,0,0,.08); }
.lp-task-card.lp-task-completed { opacity:.6; }

/* ── Comment bubble ──────────────────────────── */
.lp-comment-bubble       { margin-bottom:12px; }
.lp-comment-bubble-text  { display:inline; }

/* ── Member row in panel ─────────────────────── */
.lp-member-row {
  display:flex; align-items:center; gap:10px;
  padding:10px 0; border-bottom:1px solid var(--lp-border);
}
.lp-member-row:last-child { border-bottom:none; }

/* ── Role option labels ──────────────────────── */
.lp-role-option,
.lp-role-option-picker { transition:all .2s; }

/* ── Assignee avatar ring ─────────────────────── */
.lp-task-assignee-option { transition:border .15s, transform .15s; }

/* ── Context badge ───────────────────────────── */
.lp-context-badge {
  display:flex; align-items:center; gap:6px;
  font-size:11px; font-weight:700;
  color:var(--lp-text);
  padding:4px 10px; border-radius:20px;
  background:var(--lp-bg-alt);
  border:1px solid var(--lp-border);
}
.lp-context-badge.lp-context-shared {
  background:rgba(59,130,246,.08);
  border-color:rgba(59,130,246,.25);
}
.lp-role-pill {
  font-size:9px; font-weight:800;
  padding:2px 7px; border-radius:10px;
}

/* ── Activity feed item ──────────────────────── */
.lp-activity-feed-item  { display:flex; align-items:flex-start; gap:10px; padding:8px 0; border-bottom:1px solid var(--lp-border); }
.lp-activity-feed-item:last-child { border-bottom:none; }
.lp-activity-self .lp-activity-icon { outline:2px solid var(--lp-primary); }

/* ── Presence avatar ─────────────────────────── */
.lp-presence-avatar {
  width:28px; height:28px; border-radius:50%;
  display:flex; align-items:center; justify-content:center;
  font-size:10px; font-weight:800; color:#fff;
  border:2px solid var(--lp-header-bg);
  position:relative; cursor:pointer;
}
.lp-presence-dot {
  position:absolute; bottom:0; right:0;
  width:8px; height:8px; border-radius:50%;
  background:#10b981; border:2px solid var(--lp-header-bg);
}
.lp-presence-more { background:#64748b; font-size:9px; }

/* ── Invitation banner ───────────────────────── */
.lp-invitation-banner { pointer-events:auto; }

/* ── Collab notif item ───────────────────────── */
.lp-collab-notif-item {
  display:flex; align-items:flex-start; gap:10px;
  padding:10px 14px; cursor:pointer;
  border-bottom:1px solid var(--lp-border);
  transition:background .15s;
}
.lp-collab-notif-item:hover  { background:var(--lp-bg-alt); }
.lp-collab-notif-item.unread { background:rgba(15,118,110,.05); }
.lp-collab-notif-item:last-child { border-bottom:none; }

/* ── Modal tab content ───────────────────────── */
.lp-modal-tab-content        { display:none; }
.lp-modal-tab-content.active { display:block; }

/* ══════════════════════════════════════════════════════════
   LP PORTAL — DASHBOARD CHARTS RESPONSIVE MOBILE v2
   Remplace entièrement le CSS précédent
══════════════════════════════════════════════════════════ */

/* ─────────────────────────────────────────────────────────
   GLOBAL — Conteneurs graphiques fluides (toutes tailles)
───────────────────────────────────────────────────────── */

/* Tous les wrappers intermédiaires à 100% */
.lp-chart-wrap,
.lp-chart-wrap > div,
.lp-chart-wrap > div > div,
.lp-chart-wrap > div > div > div {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
}

/* Highcharts — container */
.highcharts-container {
    width: 100% !important;
    overflow: hidden !important;
}

/* Highcharts — SVG : override attribut inline width="XXXpx" */
.highcharts-container > svg,
.highcharts-root {
    width: 100% !important;
    max-width: 100% !important;
}

/* Chart.js — canvas */
.lp-chart-wrap canvas {
    max-width: 100% !important;
    display: block !important;
    box-sizing: border-box !important;
}

/* ══════════════════════════════════════════════════════════
   TABLET ≤ 1024px
══════════════════════════════════════════════════════════ */
@media (max-width: 1024px) {

    /* Dashboard : 1 seule colonne */
    .lp-dashboard-grid {
        grid-template-columns: 1fr !important;
        gap: 14px !important;
    }

    .lp-dashboard-col {
        gap: 14px !important;
    }

    /* Hauteurs charts réduites */
    .lp-chart-wrap canvas {
        max-height: 240px !important;
    }

    .highcharts-container > svg {
        max-height: 240px !important;
    }
}

/* ══════════════════════════════════════════════════════════
   MOBILE ≤ 768px
══════════════════════════════════════════════════════════ */
@media (max-width: 768px) {

    /* ── Dashboard layout : flex colonne (plus fiable que grid) ── */
    .lp-dashboard-grid {
        display: flex !important;
        flex-direction: column !important;
        gap: 10px !important;
        width: 100% !important;
        overflow: hidden !important;
    }

    .lp-dashboard-col {
        display: flex !important;
        flex-direction: column !important;
        gap: 10px !important;
        width: 100% !important;
        min-width: 0 !important;
        max-width: 100% !important;
    }

    /* ── Toutes les cards du dashboard ── */
    .lp-dashboard-grid .lp-card,
    .lp-dashboard-col .lp-card,
    #lpDashboardView .lp-card {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        overflow: hidden !important;
        box-sizing: border-box !important;
    }

    /* ── Card header compact ── */
    #lpDashboardView .lp-card-header {
        padding: 10px 12px 8px !important;
        flex-wrap: nowrap !important;
        gap: 6px !important;
    }

    #lpDashboardView .lp-card-title {
        font-size: 11px !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    #lpDashboardView .lp-card-title i {
        font-size: 12px !important;
        flex-shrink: 0 !important;
    }

    /* ── Chart wrappers ── */
    .lp-chart-wrap {
        padding: 0 6px 10px !important;
        overflow: hidden !important;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    /* ─────────────────────────────────────────
       FUND PERFORMANCE — line/area chart
    ───────────────────────────────────────── */
    .lp-chart-wrap canvas {
        width: 100% !important;
        max-width: 100% !important;
        height: 180px !important;
        max-height: 180px !important;
    }

    /* ─────────────────────────────────────────
       HIGHCHARTS (Cash Flow, LP Commitment,
       LP Composition, KYC Status)
    ───────────────────────────────────────── */
    .highcharts-container {
        width: 100% !important;
        max-width: 100% !important;
        overflow: hidden !important;
        box-sizing: border-box !important;
    }

    .highcharts-container > svg {
        width: 100% !important;
        max-width: 100% !important;
        height: 180px !important;
        max-height: 180px !important;
        overflow: hidden !important;
    }

    /* Highcharts — textes axes */
    .highcharts-axis-labels text,
    .highcharts-xaxis-labels text,
    .highcharts-yaxis-labels text {
        font-size: 9px !important;
    }

    /* Highcharts — data labels */
    .highcharts-data-label text,
    .highcharts-data-label span {
        font-size: 9px !important;
    }

    /* Highcharts — légende compacte */
    .highcharts-legend-item text {
        font-size: 9px !important;
    }

    .highcharts-legend {
        max-width: 100% !important;
    }

    /* Highcharts — tooltip */
    .highcharts-tooltip text {
        font-size: 10px !important;
    }

    /* ─────────────────────────────────────────
       LP COMPOSITION — pie / donut chart
    ───────────────────────────────────────── */
    .highcharts-pie-series .highcharts-data-label text {
        font-size: 9px !important;
    }

    /* ─────────────────────────────────────────
       KYC STATUS — bar / pie chart
    ───────────────────────────────────────── */
    .highcharts-bar-series text,
    .highcharts-column-series text {
        font-size: 9px !important;
    }

    /* ─────────────────────────────────────────
       RECENT ACTIVITY — liste
    ───────────────────────────────────────── */
    .lp-activity-item {
        padding: 7px 10px !important;
        gap: 8px !important;
        flex-wrap: nowrap !important;
    }

    .lp-activity-icon {
        width: 26px !important;
        height: 26px !important;
        font-size: 10px !important;
        flex-shrink: 0 !important;
        border-radius: 6px !important;
    }

    /* Texte activity tronqué */
    .lp-activity-item > div {
        min-width: 0 !important;
        overflow: hidden !important;
    }

    .lp-activity-item span,
    .lp-activity-item p {
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        max-width: 100% !important;
        font-size: 11px !important;
    }

    /* ─────────────────────────────────────────
       UPCOMING CALLS — liste
    ───────────────────────────────────────── */
    .lp-call-item {
        padding: 7px 10px !important;
        gap: 6px !important;
        flex-wrap: wrap !important;
    }

    .lp-call-item-dot {
        flex-shrink: 0 !important;
    }

    /* ─────────────────────────────────────────
       TABLES (dans les cards)
    ───────────────────────────────────────── */
    .lp-table-wrap {
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
    }

    .lp-table {
        min-width: 420px !important;
    }

    /* ─────────────────────────────────────────
       STATS GRID en haut du dashboard
    ───────────────────────────────────────── */
    .lp-stats-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px !important;
    }

    .lp-stat-card {
        padding: 10px 10px !important;
        gap: 8px !important;
    }

    .lp-stat-icon {
        width: 32px !important;
        height: 32px !important;
        font-size: 13px !important;
    }

    .lp-stat-value {
        font-size: 16px !important;
    }

    .lp-stat-label {
        font-size: 9px !important;
    }

    /* ─────────────────────────────────────────
       MINI STATS
    ───────────────────────────────────────── */
    .lp-mini-stats {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px !important;
    }

    .lp-mini-stat {
        min-width: 0 !important;
        padding: 10px 12px !important;
        box-sizing: border-box !important;
    }

    .lp-mini-stat-value {
        font-size: 16px !important;
    }

    .lp-mini-stat-label {
        font-size: 9px !important;
    }
}

/* ══════════════════════════════════════════════════════════
   SMALL MOBILE ≤ 480px
══════════════════════════════════════════════════════════ */
@media (max-width: 480px) {

    /* Charts encore plus compacts */
    .lp-chart-wrap canvas {
        height: 155px !important;
        max-height: 155px !important;
    }

    .highcharts-container > svg {
        height: 155px !important;
        max-height: 155px !important;
    }

    /* Légendes masquées (libère de la place) */
    .highcharts-legend {
        display: none !important;
    }

    /* Card header très compact */
    #lpDashboardView .lp-card-header {
        padding: 8px 10px 6px !important;
    }

    #lpDashboardView .lp-card-title {
        font-size: 10px !important;
    }

    /* Stats 2 colonnes maintenues */
    .lp-stats-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 6px !important;
    }

    .lp-stat-card {
        padding: 8px !important;
        gap: 6px !important;
    }

    .lp-stat-value {
        font-size: 14px !important;
    }

    /* Mini stats : 1 colonne sur très petit */
    .lp-mini-stats {
        grid-template-columns: 1fr !important;
    }

    /* Activity + Calls : texte réduit */
    .lp-activity-item span,
    .lp-activity-item p,
    .lp-call-item span {
        font-size: 10px !important;
    }
}

/* ══════════════════════════════════════════════════════════
   LP PORTAL — HEADER UNE LIGNE MOBILE
══════════════════════════════════════════════════════════ */

@media (max-width: 768px) {

  /* ── Header : nowrap forcé ── */
  #lpHeader {
      padding: 0 8px !important;
      gap: 5px !important;
      flex-wrap: nowrap !important;
      overflow: visible !important;
      align-items: center !important;
  }

  /* ── Bouton menu hamburger ── */
  #lpHeader > .lp-header-btn:first-child,
  #lpHeader > button:first-child {
      width: 32px !important;
      height: 32px !important;
      padding: 0 !important;
      flex-shrink: 0 !important;
      font-size: 14px !important;
  }

  /* ── Breadcrumb : tronqué ── */
  .lp-breadcrumb {
      flex-shrink: 1 !important;
      min-width: 0 !important;
      max-width: 100px !important;
      overflow: hidden !important;
  }

  .lp-breadcrumb-current {
      font-size: 12px !important;
      font-weight: 800 !important;
      white-space: nowrap !important;
      overflow: hidden !important;
      text-overflow: ellipsis !important;
      max-width: 100px !important;
      display: block !important;
  }

  /* ── Search : compressé ── */
  .lp-search-wrap {
      flex: 1 1 auto !important;
      max-width: 160px !important;
      min-width: 70px !important;
      position: relative !important;
  }

  .lp-search-input {
      padding: 5px 8px 5px 26px !important;
      font-size: 11px !important;
      height: 32px !important;
      border-radius: 8px !important;
  }

  .lp-search-icon {
      left: 8px !important;
      font-size: 10px !important;
  }

  /* ── Controls : compactés ── */
  .lp-header-controls {
      display: flex !important;
      align-items: center !important;
      gap: 3px !important;
      flex-shrink: 0 !important;
      margin-left: auto !important;
  }

  /* Masquer tous les boutons icônes non-essentiels */
  .lp-header-controls .lp-btn-icon {
      display: none !important;
  }

  /* Garder uniquement theme toggle */
  .lp-theme-toggle {
      display: flex !important;
      width: 30px !important;
      height: 30px !important;
      font-size: 13px !important;
      flex-shrink: 0 !important;
      border-radius: 8px !important;
  }

  /* Garder uniquement l'avatar user */
  .lp-user-avatar {
      display: block !important;
      width: 30px !important;
      height: 30px !important;
      flex-shrink: 0 !important;
  }
}

/* ══════════════════════════════════════════════════════════
 SMALL MOBILE ≤ 480px
══════════════════════════════════════════════════════════ */
@media (max-width: 480px) {

  #lpHeader {
      padding: 0 6px !important;
      gap: 4px !important;
  }

  /* Breadcrumb encore plus court */
  .lp-breadcrumb {
      max-width: 75px !important;
  }

  .lp-breadcrumb-current {
      font-size: 11px !important;
      max-width: 75px !important;
  }

  /* Search minimal */
  .lp-search-wrap {
      max-width: 110px !important;
      min-width: 60px !important;
  }

  .lp-search-input {
      padding: 4px 6px 4px 22px !important;
      font-size: 10px !important;
      height: 30px !important;
  }

  .lp-search-icon {
      left: 7px !important;
      font-size: 9px !important;
  }

  /* Boutons plus petits */
  .lp-theme-toggle {
      width: 28px !important;
      height: 28px !important;
      font-size: 12px !important;
  }

  .lp-user-avatar {
      width: 28px !important;
      height: 28px !important;
  }

  .lp-header-controls {
      gap: 2px !important;
  }
}

/* ══════════════════════════════════════════════════════════
 TRÈS PETIT ≤ 360px
══════════════════════════════════════════════════════════ */
@media (max-width: 360px) {

  #lpHeader {
      padding: 0 5px !important;
      gap: 3px !important;
  }

  /* Masquer le breadcrumb, garder seulement l'icône page */
  .lp-breadcrumb-current {
      display: none !important;
  }

  /* Search encore réduit */
  .lp-search-wrap {
      max-width: 90px !important;
      min-width: 50px !important;
  }

  .lp-search-input {
      padding: 4px 4px 4px 20px !important;
      font-size: 10px !important;
  }

  .lp-theme-toggle {
      width: 26px !important;
      height: 26px !important;
      font-size: 11px !important;
  }

  .lp-user-avatar {
      width: 26px !important;
      height: 26px !important;
  }
}

/* ─────────────────────────────────────────────
 END — lp-portal.css v2.0
 AlphaVault AI LP Intelligence Platform
───────────────────────────────────────────── */