/**
 * Company Page - Web3 Theme
 *
 * Design: Ethereal, calm, uncluttered
 * Aesthetic: Dark glassmorphism with soft cyan/teal accents
 * Typography: Plus Jakarta Sans
 */

/* ═══════════════════════════════════════════════════════════════
   CSS Variables - Web3 Palette
   ═══════════════════════════════════════════════════════════════ */
.web3-theme {
  --w3-bg-deep: #000000;
  --w3-bg-surface: #0a0a0a;
  --w3-bg-card: rgba(10, 10, 10, 0.8);
  --w3-bg-card-hover: rgba(18, 18, 18, 0.9);
  --w3-glass: rgba(255, 255, 255, 0.03);
  --w3-glass-border: rgba(255, 255, 255, 0.08);
  --w3-glass-highlight: rgba(255, 255, 255, 0.05);

  --w3-text-primary: #f1f5f9;
  --w3-text-secondary: #94a3b8;
  --w3-text-muted: #64748b;

  --w3-accent-cyan: #22d3ee;
  --w3-accent-cyan-soft: rgba(34, 211, 238, 0.15);
  --w3-accent-purple: #a78bfa;
  --w3-accent-purple-soft: rgba(167, 139, 250, 0.15);
  --w3-accent-emerald: #34d399;
  --w3-accent-emerald-soft: rgba(52, 211, 153, 0.15);

  --w3-glow-cyan: 0 0 30px rgba(34, 211, 238, 0.2);
  --w3-glow-purple: 0 0 30px rgba(167, 139, 250, 0.15);

  --w3-radius-sm: 8px;
  --w3-radius-md: 12px;
  --w3-radius-lg: 16px;
  --w3-radius-xl: 24px;

  --w3-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --w3-transition-fast: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ═══════════════════════════════════════════════════════════════
   Typography - Plus Jakarta Sans
   ═══════════════════════════════════════════════════════════════ */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700&display=swap');

.web3-theme {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  font-feature-settings: 'cv11' 1; /* Stylistic alternates */
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.web3-theme h1, .web3-theme h2, .web3-theme h3,
.web3-theme h4, .web3-theme h5, .web3-theme h6 {
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--w3-text-primary);
}

.web3-theme .section-title {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--w3-text-muted);
  margin-bottom: 1rem;
}

/* ═══════════════════════════════════════════════════════════════
   Page Background - Full Dark Theme (HIGH SPECIFICITY)
   These rules MUST override app.css cached styles
   ═══════════════════════════════════════════════════════════════ */

/* Root body override - highest priority */
html body.web3-theme.company-page-body {
  background: #000000 !important;
  background-color: #000000 !important;
  min-height: 100vh;
}

/* Wrapper with gradient overlay */
html body.web3-theme .wrapper.company-page-wrapper {
  background:
    radial-gradient(ellipse 80% 50% at 50% -20%, rgba(34, 211, 238, 0.08), transparent),
    radial-gradient(ellipse 60% 40% at 80% 60%, rgba(167, 139, 250, 0.05), transparent),
    #000000 !important;
  background-color: #000000 !important;
}

/* Override ALL light backgrounds in the theme - very specific selectors */
html body.web3-theme .wrapper .main,
html body.web3-theme .wrapper .main .content,
html body.web3-theme .wrapper main,
html body.web3-theme .main,
html body.web3-theme .content,
html body.web3-theme main.content,
.web3-theme .main,
.web3-theme .content,
.web3-theme main,
.web3-theme .container-fluid,
.web3-theme .row,
.web3-theme .col-lg-8,
.web3-theme .col-lg-4,
.web3-theme .right-rail {
  background: transparent !important;
  background-color: transparent !important;
}

/* Wrapper without company-page-wrapper class */
html body.web3-theme .wrapper {
  background: #000000 !important;
  background-color: #000000 !important;
}

/* Remove navbar shadow on company page */
html body.web3-theme .navbar,
html body.web3-theme .navbar-bg,
html body.web3-theme nav.navbar {
  box-shadow: none !important;
  background: transparent !important;
}

/* ═══════════════════════════════════════════════════════════════
   Hero Section - Refined
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .company-hero {
  position: relative;
  height: 200px;
  background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
  overflow: hidden;
}

.web3-theme .company-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 30% 20%, rgba(34, 211, 238, 0.12) 0%, transparent 50%),
    radial-gradient(circle at 70% 80%, rgba(167, 139, 250, 0.08) 0%, transparent 40%);
  pointer-events: none;
}

.web3-theme .company-hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 120px;
  background: linear-gradient(to top, var(--w3-bg-deep), transparent);
  pointer-events: none;
}

/* Hero with map */
.web3-theme .company-hero-map {
  height: 280px;
}

/* Hero with space/galaxy background (no map) */
.web3-theme .company-hero-space {
  height: 280px;
  background: transparent !important;
}

/* Remove the gradient pseudo-elements when using space background */
.web3-theme .company-hero-space::before {
  display: none;
}

.web3-theme .company-hero-space .hero-space-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  z-index: 0;
}

.web3-theme .company-hero-space .hero-space-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg,
    rgba(0, 0, 0, 0.3) 0%,
    rgba(0, 0, 0, 0.1) 40%,
    var(--w3-bg-deep) 100%
  );
  pointer-events: none;
  z-index: 1;
}

.web3-theme .company-hero-map .map-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 40%, var(--w3-bg-deep) 100%);
  pointer-events: none;
}

/* ═══════════════════════════════════════════════════════════════
   Glass Card - Core Component
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .glass-card {
  background: var(--w3-bg-card);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--w3-glass-border);
  border-radius: var(--w3-radius-lg);
  transition: var(--w3-transition);
}

.web3-theme .glass-card:hover {
  background: var(--w3-bg-card-hover);
  border-color: rgba(255, 255, 255, 0.12);
}

.web3-theme .glass-card-glow {
  box-shadow: var(--w3-glow-cyan);
}

/* Shine effect - gradient line on top border */
.web3-theme .glass-card-shine {
  position: relative;
  overflow: hidden;
}

.web3-theme .glass-card-shine::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg,
    transparent,
    rgba(34, 211, 238, 0.5),
    rgba(167, 139, 250, 0.5),
    transparent
  );
}

.web3-theme .glass-card-header {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--w3-glass-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.web3-theme .glass-card-body {
  padding: 1.5rem;
}

.web3-theme .glass-card-footer {
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--w3-glass-border);
  background: var(--w3-glass);
}

/* ═══════════════════════════════════════════════════════════════
   Company Profile Card - Floating
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .company-profile-card {
  background: var(--w3-bg-card);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--w3-glass-border);
  border-radius: var(--w3-radius-xl);
  margin-top: -80px;
  position: relative;
  z-index: 10;
  overflow: hidden;
}

.web3-theme .company-profile-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg,
    transparent,
    rgba(34, 211, 238, 0.5),
    rgba(167, 139, 250, 0.5),
    transparent
  );
}

.web3-theme .company-avatar-wrapper {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--w3-accent-cyan), var(--w3-accent-purple));
  padding: 3px;
  box-shadow: var(--w3-glow-cyan);
}

.web3-theme .company-avatar-wrapper img,
.web3-theme .company-avatar-wrapper .avatar-placeholder {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  background: var(--w3-bg-surface);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  font-weight: 600;
  color: var(--w3-text-secondary);
}

.web3-theme .company-name {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--w3-text-primary);
  margin: 0;
}

/* ═══════════════════════════════════════════════════════════════
   Social Links - Minimal
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .social-links {
  display: flex;
  gap: 0.5rem;
}

.web3-theme .social-link {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--w3-radius-sm);
  background: var(--w3-glass);
  border: 1px solid var(--w3-glass-border);
  color: var(--w3-text-secondary);
  transition: var(--w3-transition-fast);
  text-decoration: none;
}

.web3-theme .social-link:hover {
  background: var(--w3-accent-cyan-soft);
  border-color: var(--w3-accent-cyan);
  color: var(--w3-accent-cyan);
  transform: translateY(-2px);
}

/* ═══════════════════════════════════════════════════════════════
   Tabs - Clean Underline
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .nav-tabs-web3 {
  display: flex;
  gap: 0.5rem;
  padding: 0 1.5rem;
  border-top: 1px solid var(--w3-glass-border);
  background: var(--w3-glass);
}

.web3-theme .nav-tabs-web3 .nav-link {
  position: relative;
  padding: 1rem 1.25rem;
  color: var(--w3-text-muted);
  font-weight: 500;
  font-size: 0.875rem;
  border: none;
  background: transparent;
  transition: var(--w3-transition-fast);
}

.web3-theme .nav-tabs-web3 .nav-link:hover {
  color: var(--w3-text-secondary);
}

.web3-theme .nav-tabs-web3 .nav-link.active {
  color: var(--w3-accent-cyan);
}

.web3-theme .nav-tabs-web3 .nav-link.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 1rem;
  right: 1rem;
  height: 2px;
  background: linear-gradient(90deg, var(--w3-accent-cyan), var(--w3-accent-purple));
  border-radius: 1px;
}

/* ═══════════════════════════════════════════════════════════════
   Buttons - Web3 Style
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .btn-web3 {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.625rem 1.25rem;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: var(--w3-radius-md);
  border: 1px solid var(--w3-glass-border);
  background: var(--w3-glass);
  color: var(--w3-text-secondary);
  transition: var(--w3-transition-fast);
  cursor: pointer;
}

.web3-theme .btn-web3:hover {
  background: var(--w3-glass-highlight);
  border-color: rgba(255, 255, 255, 0.15);
  color: var(--w3-text-primary);
}

.web3-theme .btn-web3-primary {
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.2), rgba(167, 139, 250, 0.2));
  border-color: rgba(34, 211, 238, 0.3);
  color: var(--w3-accent-cyan);
}

.web3-theme .btn-web3-primary:hover {
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.3), rgba(167, 139, 250, 0.3));
  border-color: var(--w3-accent-cyan);
  box-shadow: var(--w3-glow-cyan);
}

/* Solid cyan button with white text */
.web3-theme .btn-web3-solid {
  background: linear-gradient(135deg, #00bfff 0%, #0099cc 100%);
  border: none;
  color: #ffffff;
  font-weight: 500;
}

.web3-theme .btn-web3-solid:hover {
  background: linear-gradient(135deg, #00d4ff 0%, #00aadd 100%);
  color: #ffffff;
  box-shadow: 0 0 20px rgba(0, 191, 255, 0.4);
}

.web3-theme .btn-web3-solid .ledo-icon,
.web3-theme .btn-web3-solid svg {
  color: #ffffff !important;
  filter: none !important;
}

.web3-theme .btn-web3-sm {
  padding: 0.5rem 1rem;
  font-size: 0.8125rem;
}

/* Web3 Outline Buttons */
.web3-theme .btn-web3-outline {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.5);
  color: #fff;
  border-radius: var(--w3-radius-md);
}

.web3-theme .btn-web3-outline:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: #fff;
  color: #fff;
}

/* Delete/Danger button - white outline, red on hover */
.web3-theme .btn-web3-danger,
.web3-theme .delete-btn-hover {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.5);
  color: #fff;
  border-radius: var(--w3-radius-md);
  transition: var(--w3-transition-fast);
}

.web3-theme .btn-web3-danger:hover,
.web3-theme .delete-btn-hover:hover {
  background: #ef4444;
  border-color: #ef4444;
  color: #fff;
}

/* Success button - green variant */
.web3-theme .btn-web3-success {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.2), rgba(16, 185, 129, 0.2));
  border-color: rgba(34, 197, 94, 0.3);
  color: #22c55e;
  border-radius: var(--w3-radius-md);
}

.web3-theme .btn-web3-success:hover {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.3), rgba(16, 185, 129, 0.3));
  border-color: #22c55e;
  box-shadow: 0 0 20px rgba(34, 197, 94, 0.3);
}

/* ═══════════════════════════════════════════════════════════════
   Modals - Web3 Dark Style
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .modal-dark .modal-content {
  background-color: #1c1c1e;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--w3-radius-lg);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.web3-theme .modal-dark .modal-header {
  background-color: rgba(0, 0, 0, 0.3);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding: 1rem 1.25rem;
}

.web3-theme .modal-dark .modal-title {
  color: var(--w3-text-primary);
  font-weight: 600;
}

.web3-theme .modal-dark .modal-header .btn-close {
  filter: invert(1) grayscale(100%) brightness(200%);
  opacity: 0.6;
}

.web3-theme .modal-dark .modal-header .btn-close:hover {
  opacity: 1;
}

.web3-theme .modal-dark .modal-body {
  background-color: #1c1c1e;
  color: var(--w3-text-primary);
  padding: 1.25rem;
}

.web3-theme .modal-dark .modal-body .text-muted {
  color: var(--w3-text-secondary) !important;
}

.web3-theme .modal-dark .modal-footer {
  background-color: rgba(0, 0, 0, 0.2);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 1rem 1.25rem;
}

.web3-theme .modal-dark .modal-footer .btn-secondary {
  background-color: #2c2c2e;
  border-color: rgba(255, 255, 255, 0.1);
  color: var(--w3-text-primary);
}

.web3-theme .modal-dark .modal-footer .btn-secondary:hover {
  background-color: #3c3c3e;
  border-color: rgba(255, 255, 255, 0.15);
}

.web3-theme .modal-dark .form-control,
.web3-theme .modal-dark .form-select {
  background-color: #2c2c2e;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--w3-text-primary);
  border-radius: var(--w3-radius-sm);
}

.web3-theme .modal-dark .form-control:focus,
.web3-theme .modal-dark .form-select:focus {
  background-color: #2c2c2e;
  border-color: var(--w3-accent-cyan);
  box-shadow: 0 0 0 2px rgba(34, 211, 238, 0.15);
  color: var(--w3-text-primary);
}

.web3-theme .modal-dark .form-control::placeholder {
  color: var(--w3-text-muted);
}

.web3-theme .modal-dark .form-label {
  color: var(--w3-text-secondary);
  font-size: 0.875rem;
  font-weight: 500;
}

/* Tag badges in dark modal */
.web3-theme .modal-dark .badge {
  cursor: pointer;
  transition: var(--w3-transition-fast);
}

.web3-theme .modal-dark .badge:hover {
  transform: scale(1.05);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* ═══════════════════════════════════════════════════════════════
   Info Grid - Clean Data Display
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
}

.web3-theme .info-item {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.web3-theme .info-label {
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--w3-text-muted);
}

.web3-theme .info-value {
  font-size: 0.9375rem;
  color: var(--w3-text-primary);
}

.web3-theme .info-value a {
  color: var(--w3-accent-cyan);
  text-decoration: none;
  transition: var(--w3-transition-fast);
}

.web3-theme .info-value a:hover {
  color: var(--w3-text-primary);
  text-decoration: underline;
}

/* Full-width info items */
.web3-theme .info-item.info-item-full {
  grid-column: 1 / -1;
}

/* Description text styling */
.web3-theme .info-value.info-description {
  line-height: 1.6;
  color: var(--w3-text-secondary);
}

/* Info link styling */
.web3-theme .info-link {
  color: var(--w3-accent-cyan) !important;
  text-decoration: none;
  transition: var(--w3-transition-fast);
}

.web3-theme .info-link:hover {
  color: var(--w3-text-primary) !important;
}

/* Social Links Row */
.web3-theme .social-links-row {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.web3-theme .social-link-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--w3-text-secondary);
  font-size: 1.125rem;
  transition: var(--w3-transition);
  text-decoration: none;
}

.web3-theme .social-link-btn:hover {
  background: rgba(34, 211, 238, 0.1);
  border-color: var(--w3-accent-cyan);
  color: var(--w3-accent-cyan);
  transform: translateY(-2px);
}

/* Profile Hint - Prompt to complete profile */
.web3-theme .profile-hint {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 1.5rem;
  padding: 16px;
  background: rgba(34, 211, 238, 0.05);
  border: 1px solid rgba(34, 211, 238, 0.15);
  border-radius: 12px;
}

.web3-theme .profile-hint-icon {
  flex-shrink: 0;
  color: var(--w3-accent-cyan);
}

.web3-theme .profile-hint-text {
  flex: 1;
  font-size: 0.875rem;
  color: var(--w3-text-secondary);
}

.web3-theme .btn-web3-ghost {
  background: transparent;
  border-color: var(--w3-accent-cyan);
  color: var(--w3-accent-cyan);
}

.web3-theme .btn-web3-ghost:hover {
  background: rgba(34, 211, 238, 0.1);
}

/* ═══════════════════════════════════════════════════════════════
   Stats Cards - Sidebar
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .stat-card {
  background: var(--w3-glass);
  border: 1px solid var(--w3-glass-border);
  border-radius: var(--w3-radius-md);
  padding: 1.25rem;
  transition: var(--w3-transition);
}

.web3-theme .stat-card:hover {
  border-color: rgba(255, 255, 255, 0.12);
  transform: translateY(-2px);
}

.web3-theme .stat-value {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--w3-text-primary);
  line-height: 1.2;
}

.web3-theme .stat-label {
  font-size: 0.8125rem;
  color: var(--w3-text-muted);
  margin-top: 0.25rem;
}

.web3-theme .stat-trend {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.75rem;
  font-weight: 500;
  padding: 0.25rem 0.5rem;
  border-radius: var(--w3-radius-sm);
  margin-top: 0.5rem;
}

.web3-theme .stat-trend-up {
  background: var(--w3-accent-emerald-soft);
  color: var(--w3-accent-emerald);
}

.web3-theme .stat-trend-down {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
}

/* ═══════════════════════════════════════════════════════════════
   Notes - Clean List
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .note-item {
  padding: 1rem;
  border-radius: var(--w3-radius-md);
  background: var(--w3-glass);
  border: 1px solid transparent;
  margin-bottom: 0.75rem;
  transition: var(--w3-transition-fast);
}

.web3-theme .note-item:hover {
  border-color: var(--w3-glass-border);
}

.web3-theme .note-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.8125rem;
  color: var(--w3-text-muted);
  margin-bottom: 0.5rem;
}

.web3-theme .note-content {
  color: var(--w3-text-secondary);
  font-size: 0.9375rem;
  line-height: 1.6;
}

.web3-theme .note-pinned {
  border-left: 2px solid var(--w3-accent-cyan);
  background: var(--w3-accent-cyan-soft);
}

/* ═══════════════════════════════════════════════════════════════
   Contacts - Avatar List
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .contact-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1rem;
  border-radius: var(--w3-radius-md);
  transition: var(--w3-transition-fast);
}

.web3-theme .contact-item:hover {
  background: var(--w3-glass);
}

.web3-theme .contact-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--w3-accent-purple-soft), var(--w3-accent-cyan-soft));
  border: 1px solid var(--w3-glass-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--w3-text-secondary);
  flex-shrink: 0;
}

.web3-theme .contact-info {
  flex: 1;
  min-width: 0;
}

.web3-theme .contact-name {
  font-weight: 600;
  color: var(--w3-text-primary);
  margin-bottom: 0.125rem;
}

.web3-theme .contact-role {
  display: inline-block;
  font-size: 0.75rem;
  padding: 0.125rem 0.5rem;
  background: var(--w3-accent-purple-soft);
  color: var(--w3-accent-purple);
  border-radius: var(--w3-radius-sm);
  margin-bottom: 0.5rem;
}

.web3-theme .contact-details {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.8125rem;
  color: var(--w3-text-muted);
}

.web3-theme .contact-details a {
  color: var(--w3-text-muted);
  text-decoration: none;
  transition: var(--w3-transition-fast);
}

.web3-theme .contact-details a:hover {
  color: var(--w3-accent-cyan);
}

/* ═══════════════════════════════════════════════════════════════
   Team Members - List Style
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .team-list {
  display: flex;
  flex-direction: column;
}

.web3-theme .team-member-item {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--w3-glass-border);
  transition: var(--w3-transition-fast);
}

.web3-theme .team-member-item:last-child {
  border-bottom: none;
}

.web3-theme .team-member-item:hover {
  background: var(--w3-glass);
}

.web3-theme .team-member-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.web3-theme .team-member-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--w3-glass-border);
  flex-shrink: 0;
}

.web3-theme .team-member-avatar-placeholder {
  background: linear-gradient(135deg, var(--w3-accent-purple-soft), var(--w3-accent-cyan-soft));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 1rem;
  color: var(--w3-text-secondary);
}

.web3-theme .team-member-info {
  flex: 1;
  min-width: 0;
}

.web3-theme .team-member-name {
  font-weight: 600;
  font-size: 0.9375rem;
  color: var(--w3-text-primary);
  margin-bottom: 0.125rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.web3-theme .team-member-email {
  font-size: 0.8125rem;
  color: var(--w3-text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.web3-theme .team-member-badges {
  display: flex;
  gap: 0.375rem;
  flex-wrap: wrap;
  flex-shrink: 0;
}

.web3-theme .team-member-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-left: 64px; /* Align with content after avatar */
}

.web3-theme .team-control-label {
  font-size: 0.8125rem;
  color: var(--w3-text-muted);
  margin: 0;
}

.web3-theme .team-member-actions {
  display: flex;
  gap: 0.25rem;
}

/* Team member controls - form elements */
.web3-theme .team-member-controls .form-select {
  background-color: var(--w3-bg-surface);
  border-color: var(--w3-glass-border);
  color: var(--w3-text-primary);
  font-size: 0.8125rem;
  padding: 0.375rem 2rem 0.375rem 0.75rem;
  min-width: 110px;
}

.web3-theme .team-member-controls .form-select:focus {
  border-color: var(--w3-accent-cyan);
  box-shadow: 0 0 0 3px var(--w3-accent-cyan-soft);
}

.web3-theme .team-member-controls .form-select option {
  background-color: var(--w3-bg-surface);
  color: var(--w3-text-primary);
}

/* Team Grid (legacy support) */
.web3-theme .team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 1rem;
}

.web3-theme .team-member {
  text-align: center;
  padding: 1rem;
  border-radius: var(--w3-radius-md);
  background: var(--w3-glass);
  border: 1px solid var(--w3-glass-border);
  transition: var(--w3-transition);
}

.web3-theme .team-member:hover {
  border-color: rgba(255, 255, 255, 0.15);
  transform: translateY(-2px);
}

.web3-theme .team-member-role {
  font-size: 0.75rem;
  color: var(--w3-text-muted);
}

/* ═══════════════════════════════════════════════════════════════
   Forms - Web3 Style
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .form-control-web3 {
  background: var(--w3-bg-surface);
  border: 1px solid var(--w3-glass-border);
  border-radius: var(--w3-radius-md);
  padding: 0.75rem 1rem;
  font-size: 0.9375rem;
  color: var(--w3-text-primary);
  transition: var(--w3-transition-fast);
}

.web3-theme .form-control-web3:focus {
  background: var(--w3-bg-surface);
  border-color: var(--w3-accent-cyan);
  box-shadow: 0 0 0 3px var(--w3-accent-cyan-soft);
  outline: none;
}

.web3-theme .form-control-web3::placeholder {
  color: var(--w3-text-muted);
}

.web3-theme .form-label-web3 {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--w3-text-secondary);
  margin-bottom: 0.5rem;
}

/* ═══════════════════════════════════════════════════════════════
   Ledo AI Card - Special Treatment
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .ledo-card {
  background: linear-gradient(135deg,
    rgba(34, 211, 238, 0.08),
    rgba(167, 139, 250, 0.08)
  );
  border: 1px solid rgba(34, 211, 238, 0.2);
  border-radius: var(--w3-radius-lg);
  position: relative;
  overflow: hidden;
}

.web3-theme .ledo-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg,
    transparent,
    var(--w3-accent-cyan),
    var(--w3-accent-purple),
    transparent
  );
}

.web3-theme .ledo-card-header {
  padding: 1rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

/* Ledo Icon - Large, high contrast cyan, animated glow (NO square background) */
.web3-theme .ledo-icon,
.web3-theme svg.ledo-icon {
  color: var(--w3-accent-cyan);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Ledo icon wrapper in card header - animated glow */
.web3-theme .ledo-card-header .ledo-icon {
  animation: ledo-breathe 4s ease-in-out infinite;
}

.web3-theme .ledo-card-header .ledo-icon svg,
.web3-theme .ledo-card-header svg.ledo-icon {
  width: 32px !important;
  height: 32px !important;
  filter: drop-shadow(0 0 10px rgba(34, 211, 238, 0.7));
}

/* All Ledo SVG icons - high contrast cyan with glow */
.web3-theme svg.ledo-icon {
  color: var(--w3-accent-cyan);
  filter: drop-shadow(0 0 6px rgba(34, 211, 238, 0.5));
  transition: filter 0.3s ease;
}

/* Ledo icons in buttons - slightly larger and glowing */
.web3-theme .btn-web3 svg.ledo-icon,
.web3-theme button svg.ledo-icon {
  filter: drop-shadow(0 0 4px rgba(34, 211, 238, 0.6));
}

.web3-theme .btn-web3:hover svg.ledo-icon,
.web3-theme button:hover svg.ledo-icon {
  filter: drop-shadow(0 0 8px rgba(34, 211, 238, 0.9));
}

/* Gentle breathing animation for Ledo icon */
@keyframes ledo-breathe {
  0%, 100% {
    filter: drop-shadow(0 0 8px rgba(34, 211, 238, 0.5));
    transform: scale(1);
  }
  50% {
    filter: drop-shadow(0 0 16px rgba(34, 211, 238, 0.8)) drop-shadow(0 0 24px rgba(167, 139, 250, 0.3));
    transform: scale(1.02);
  }
}

/* Ledo spinner animation (for loading states) */
@keyframes ledo-spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.web3-theme .ledo-spinner {
  color: var(--w3-accent-cyan);
}

.web3-theme .ledo-spinner-halo,
.web3-theme .ledo-spinner circle:first-child {
  animation: ledo-spin 1.2s linear infinite;
  transform-origin: center;
}

/* ═══════════════════════════════════════════════════════════════
   Utility Classes
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .text-gradient {
  background: linear-gradient(135deg, var(--w3-accent-cyan), var(--w3-accent-purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.web3-theme .divider {
  height: 1px;
  background: var(--w3-glass-border);
  margin: 1.5rem 0;
}

.web3-theme .badge-web3 {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.25rem 0.625rem;
  font-size: 0.75rem;
  font-weight: 500;
  border-radius: var(--w3-radius-sm);
  background: var(--w3-glass);
  border: 1px solid var(--w3-glass-border);
  color: var(--w3-text-secondary);
}

.web3-theme .badge-web3-cyan {
  background: var(--w3-accent-cyan-soft);
  border-color: rgba(34, 211, 238, 0.3);
  color: var(--w3-accent-cyan);
}

.web3-theme .badge-web3-purple {
  background: var(--w3-accent-purple-soft);
  border-color: rgba(167, 139, 250, 0.3);
  color: var(--w3-accent-purple);
}

/* ═══════════════════════════════════════════════════════════════
   Animations
   ═══════════════════════════════════════════════════════════════ */
@keyframes w3-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

@keyframes w3-shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.web3-theme .loading-shimmer {
  background: linear-gradient(90deg,
    var(--w3-glass) 25%,
    var(--w3-glass-highlight) 50%,
    var(--w3-glass) 75%
  );
  background-size: 200% 100%;
  animation: w3-shimmer 1.5s infinite;
}

/* ═══════════════════════════════════════════════════════════════
   Responsive Adjustments
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 991.98px) {
  .web3-theme .company-profile-card {
    margin-top: -60px;
  }

  .web3-theme .company-avatar-wrapper {
    width: 72px;
    height: 72px;
  }

  .web3-theme .company-name {
    font-size: 1.5rem;
  }

  .web3-theme .info-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 575.98px) {
  .web3-theme .company-hero {
    height: 160px;
  }

  .web3-theme .glass-card-body {
    padding: 1rem;
  }

  .web3-theme .nav-tabs-web3 {
    padding: 0 1rem;
    overflow-x: auto;
  }

  .web3-theme .nav-tabs-web3 .nav-link {
    padding: 0.875rem 1rem;
    white-space: nowrap;
  }
}

/* ═══════════════════════════════════════════════════════════════
   Stat Card - Enhanced
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .stat-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
}

.web3-theme .stat-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--w3-radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.125rem;
}

.web3-theme .stat-icon-cyan {
  background: var(--w3-accent-cyan-soft);
  color: var(--w3-accent-cyan);
}

.web3-theme .stat-icon-purple {
  background: var(--w3-accent-purple-soft);
  color: var(--w3-accent-purple);
}

.web3-theme .stat-trend-flat {
  background: var(--w3-glass);
  color: var(--w3-text-muted);
}

.web3-theme .trend-label {
  color: var(--w3-text-muted);
  margin-left: 0.25rem;
}

/* ═══════════════════════════════════════════════════════════════
   Notes - Enhanced Styles
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .notes-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.web3-theme .note-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.web3-theme .note-author {
  color: var(--w3-text-secondary);
  font-weight: 500;
}

.web3-theme .note-author::before {
  content: '•';
  margin: 0 0.5rem;
  color: var(--w3-text-muted);
}

.web3-theme .note-badge {
  display: inline-block;
  padding: 0.125rem 0.5rem;
  font-size: 0.6875rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: var(--w3-radius-sm);
  background: var(--w3-glass);
  color: var(--w3-text-muted);
  margin-left: 0.5rem;
}

.web3-theme .note-badge-pinned {
  background: rgba(234, 179, 8, 0.15);
  color: #fbbf24;
}

.web3-theme .note-actions {
  display: flex;
  gap: 0.25rem;
}

.web3-theme .note-action-btn {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--w3-radius-sm);
  border: 1px solid transparent;
  background: transparent;
  color: var(--w3-text-muted);
  cursor: pointer;
  transition: var(--w3-transition-fast);
}

.web3-theme .note-action-btn:hover {
  background: var(--w3-glass);
  border-color: var(--w3-glass-border);
  color: var(--w3-text-secondary);
}

.web3-theme .note-action-btn-danger:hover {
  background: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.3);
  color: #f87171;
}

.web3-theme .note-body {
  color: var(--w3-text-secondary);
  font-size: 0.9375rem;
  line-height: 1.6;
  white-space: pre-wrap;
}

/* ═══════════════════════════════════════════════════════════════
   Contacts - Enhanced Styles
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .contacts-list {
  display: flex;
  flex-direction: column;
}

.web3-theme .contact-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--w3-glass-border);
  flex-wrap: wrap;
}

.web3-theme .contact-item:last-child {
  border-bottom: none;
}

.web3-theme .contact-actions {
  display: flex;
  gap: 0.25rem;
  margin-left: auto;
}

.web3-theme .contact-detail {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  color: var(--w3-text-muted);
  text-decoration: none;
  transition: var(--w3-transition-fast);
}

.web3-theme .contact-detail:hover {
  color: var(--w3-accent-cyan);
}

.web3-theme .contact-detail i {
  font-size: 0.875rem;
}

/* ═══════════════════════════════════════════════════════════════
   Empty State
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .empty-state {
  color: var(--w3-text-muted);
  font-size: 0.9375rem;
  margin: 0;
}

.web3-theme .empty-state-container {
  padding: 3rem 1.5rem;
  text-align: center;
}

.web3-theme .empty-state-container i {
  font-size: 3rem;
  color: var(--w3-text-muted);
  margin-bottom: 1rem;
  display: block;
  opacity: 0.5;
}

.web3-theme .empty-state-container p {
  color: var(--w3-text-muted);
  font-size: 0.9375rem;
  margin: 0;
}

/* ═══════════════════════════════════════════════════════════════
   Activity List - Timeline Style
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .activity-list ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.web3-theme .activity-list li {
  display: flex;
  gap: 0.75rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--w3-glass-border);
}

.web3-theme .activity-list li:last-child {
  border-bottom: none;
}

.web3-theme .activity-list i.bi {
  color: var(--w3-accent-cyan);
  margin-top: 0.125rem;
}

.web3-theme .activity-list strong {
  color: var(--w3-text-primary);
}

.web3-theme .activity-list a {
  color: var(--w3-accent-cyan);
  text-decoration: none;
}

.web3-theme .activity-list a:hover {
  text-decoration: underline;
}

.web3-theme .activity-list .text-muted {
  color: var(--w3-text-muted) !important;
}

.web3-theme .activity-list .flex-grow-1 {
  color: var(--w3-text-secondary);
}

/* ═══════════════════════════════════════════════════════════════
   Tab Pane Content Fix
   ═══════════════════════════════════════════════════════════════ */
.web3-theme .tab-content {
  padding-top: 1.5rem;
}

/* Make sure Bootstrap cards in non-updated tabs still look decent */
.web3-theme .tab-pane .card {
  background: var(--w3-bg-card);
  border: 1px solid var(--w3-glass-border);
  border-radius: var(--w3-radius-lg);
}

.web3-theme .tab-pane .card-header {
  background: var(--w3-glass);
  border-bottom: 1px solid var(--w3-glass-border);
  color: var(--w3-text-primary);
}

.web3-theme .tab-pane .card-body {
  color: var(--w3-text-secondary);
}

.web3-theme .tab-pane .card-title {
  color: var(--w3-text-primary);
}

.web3-theme .tab-pane .card-footer {
  background: var(--w3-glass);
  border-top: 1px solid var(--w3-glass-border);
}

/* Form controls in tabs */
.web3-theme .tab-pane .form-control {
  background: var(--w3-bg-surface);
  border-color: var(--w3-glass-border);
  color: var(--w3-text-primary);
}

.web3-theme .tab-pane .form-control:focus {
  background: var(--w3-bg-surface);
  border-color: var(--w3-accent-cyan);
  box-shadow: 0 0 0 3px var(--w3-accent-cyan-soft);
  color: var(--w3-text-primary);
}

.web3-theme .tab-pane .form-select {
  background-color: var(--w3-bg-surface);
  border-color: var(--w3-glass-border);
  color: var(--w3-text-primary);
}

.web3-theme .tab-pane .form-label {
  color: var(--w3-text-secondary);
}

.web3-theme .tab-pane .input-group-text {
  background: var(--w3-glass);
  border-color: var(--w3-glass-border);
  color: var(--w3-text-muted);
}

.web3-theme .tab-pane .btn-primary {
  background: linear-gradient(135deg, var(--w3-accent-cyan), var(--w3-accent-purple));
  border: none;
}

.web3-theme .tab-pane .btn-outline-primary {
  border-color: var(--w3-accent-cyan);
  color: var(--w3-accent-cyan);
}

.web3-theme .tab-pane .btn-outline-primary:hover {
  background: var(--w3-accent-cyan-soft);
}

.web3-theme .tab-pane .alert-info {
  background: var(--w3-accent-cyan-soft);
  border-color: rgba(34, 211, 238, 0.2);
  color: var(--w3-text-primary);
}

.web3-theme .tab-pane .table {
  color: var(--w3-text-secondary);
}

.web3-theme .tab-pane .table thead th {
  color: var(--w3-text-muted);
  border-bottom-color: var(--w3-glass-border);
}

.web3-theme .tab-pane .table td {
  border-bottom-color: var(--w3-glass-border);
}

.web3-theme .tab-pane .list-group-item {
  background: transparent;
  border-color: var(--w3-glass-border);
  color: var(--w3-text-secondary);
}

.web3-theme .tab-pane .list-group-item:hover {
  background: var(--w3-glass);
}

/* Siri border wrapper (AI suggestions) */
.web3-theme .siri-border-wrapper {
  background: linear-gradient(135deg,
    rgba(34, 211, 238, 0.1),
    rgba(167, 139, 250, 0.1)
  );
  border: 1px solid rgba(34, 211, 238, 0.2);
  border-radius: var(--w3-radius-lg);
  padding: 2px;
}

.web3-theme .siri-border-wrapper .card {
  border: none;
  background: var(--w3-bg-card);
}

/* ═══════════════════════════════════════════════════════════════
   Slide-Out Edit Panel (Right Side)
   ═══════════════════════════════════════════════════════════════ */

/* Backdrop */
.web3-theme .edit-panel-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 1050;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s cubic-bezier(0.32, 0.72, 0, 1);
}

.web3-theme .edit-panel-backdrop.show {
  opacity: 1;
  visibility: visible;
}

/* Panel Container */
.web3-theme .edit-panel {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  max-width: 500px;
  background: #1c1c1e;
  z-index: 1051;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
  border-radius: 20px 0 0 20px;
  box-shadow: -10px 0 40px rgba(0, 0, 0, 0.5);
}

.web3-theme .edit-panel.show {
  transform: translateX(0);
}

/* Panel Header */
.web3-theme .edit-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid #2c2c2e;
  flex-shrink: 0;
}

.web3-theme .edit-panel-title {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #fff;
  font-weight: 600;
  font-size: 1.25rem;
  margin: 0;
}

.web3-theme .edit-panel-title i {
  color: var(--w3-accent-cyan);
}

.web3-theme .edit-panel-close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: #2c2c2e;
  color: #8e8e93;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.web3-theme .edit-panel-close:hover {
  background: #3a3a3c;
  color: #fff;
}

/* Panel Body (Scrollable) */
.web3-theme .edit-panel-body {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
}

/* Section Groups */
.web3-theme .edit-panel-section {
  margin-bottom: 32px;
}

.web3-theme .edit-panel-section:last-child {
  margin-bottom: 0;
}

.web3-theme .edit-panel-section-title {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--w3-accent-cyan);
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 1px solid #2c2c2e;
}

/* Form Controls */
.web3-theme .edit-panel .form-group {
  margin-bottom: 20px;
}

.web3-theme .edit-panel .form-group:last-child {
  margin-bottom: 0;
}

.web3-theme .edit-panel .form-label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #a0a0a5;
  margin-bottom: 8px;
}

.web3-theme .edit-panel .form-control,
.web3-theme .edit-panel .form-select {
  width: 100%;
  padding: 12px 16px;
  font-size: 0.9375rem;
  color: #fff;
  background: #2c2c2e;
  border: 1px solid #48484a;
  border-radius: 10px;
  transition: all 0.2s ease;
}

.web3-theme .edit-panel .form-control:focus,
.web3-theme .edit-panel .form-select:focus {
  outline: none;
  border-color: var(--w3-accent-cyan);
  box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.15);
  background: #2c2c2e;
}

.web3-theme .edit-panel .form-control::placeholder {
  color: #636366;
}

.web3-theme .edit-panel textarea.form-control {
  min-height: 100px;
  resize: vertical;
}

/* Logo Upload Area */
.web3-theme .edit-panel .logo-upload-area {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  background: #2c2c2e;
  border: 1px dashed #48484a;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.web3-theme .edit-panel .logo-upload-area:hover {
  border-color: var(--w3-accent-cyan);
  background: rgba(34, 211, 238, 0.05);
}

.web3-theme .edit-panel .logo-preview {
  width: 64px;
  height: 64px;
  border-radius: 12px;
  background: #3a3a3c;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}

.web3-theme .edit-panel .logo-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.web3-theme .edit-panel .logo-preview i {
  font-size: 1.5rem;
  color: #636366;
}

.web3-theme .edit-panel .logo-upload-text {
  flex: 1;
}

.web3-theme .edit-panel .logo-upload-text strong {
  display: block;
  color: #fff;
  font-size: 0.9375rem;
  margin-bottom: 4px;
}

.web3-theme .edit-panel .logo-upload-text span {
  font-size: 0.8125rem;
  color: #636366;
}

/* Input Groups with Icons */
.web3-theme .edit-panel .input-icon-group {
  position: relative;
}

.web3-theme .edit-panel .input-icon-group i {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #636366;
  font-size: 1rem;
  pointer-events: none;
}

.web3-theme .edit-panel .input-icon-group .form-control {
  padding-left: 44px;
}

/* Panel Footer */
.web3-theme .edit-panel-footer {
  display: flex;
  gap: 12px;
  padding: 20px 24px;
  border-top: 1px solid #2c2c2e;
  background: #1c1c1e;
  flex-shrink: 0;
}

.web3-theme .edit-panel-footer .btn-web3 {
  flex: 1;
  justify-content: center;
  padding: 14px 24px;
  font-size: 0.9375rem;
  font-weight: 600;
}

/* Custom scrollbar for panel */
.web3-theme .edit-panel-body::-webkit-scrollbar {
  width: 6px;
}

.web3-theme .edit-panel-body::-webkit-scrollbar-track {
  background: transparent;
}

.web3-theme .edit-panel-body::-webkit-scrollbar-thumb {
  background: #48484a;
  border-radius: 3px;
}

.web3-theme .edit-panel-body::-webkit-scrollbar-thumb:hover {
  background: #636366;
}

/* Section Groups (alternate class names) */
.web3-theme .edit-panel .edit-section {
  margin-bottom: 32px;
}

.web3-theme .edit-panel .edit-section:last-child {
  margin-bottom: 0;
}

.web3-theme .edit-panel .edit-section-title {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--w3-accent-cyan);
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 1px solid #2c2c2e;
}

/* Form Fields (alternate class names) */
.web3-theme .edit-panel .edit-field {
  margin-bottom: 20px;
}

.web3-theme .edit-panel .edit-field:last-child {
  margin-bottom: 0;
}

.web3-theme .edit-panel .edit-label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #a0a0a5;
  margin-bottom: 8px;
}

.web3-theme .edit-panel .edit-input,
.web3-theme .edit-panel .edit-textarea {
  width: 100%;
  padding: 12px 16px;
  font-size: 0.9375rem;
  color: #fff;
  background: #2c2c2e;
  border: 1px solid #48484a;
  border-radius: 10px;
  transition: all 0.2s ease;
}

.web3-theme .edit-panel .edit-input:focus,
.web3-theme .edit-panel .edit-textarea:focus {
  outline: none;
  border-color: var(--w3-accent-cyan);
  box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.15);
  background: #2c2c2e;
}

.web3-theme .edit-panel .edit-input::placeholder {
  color: #636366;
}

.web3-theme .edit-panel .edit-textarea {
  min-height: 100px;
  resize: vertical;
}

.web3-theme .edit-panel .edit-hint {
  display: block;
  font-size: 0.75rem;
  color: #636366;
  margin: 8px 0;
}

/* Row Layout for Multiple Fields */
.web3-theme .edit-panel .edit-row {
  display: flex;
  gap: 16px;
}

.web3-theme .edit-panel .edit-row .edit-field {
  flex: 1;
}

.web3-theme .edit-panel .edit-row .edit-field.flex-1 {
  flex: 1;
}

.web3-theme .edit-panel .edit-row .edit-field.flex-2 {
  flex: 2;
}

/* Logo Preview */
.web3-theme .edit-panel .logo-preview-wrapper {
  margin-bottom: 12px;
}

.web3-theme .edit-panel .logo-preview {
  max-width: 80px;
  max-height: 80px;
  border-radius: 10px;
  background: #3a3a3c;
}

/* Mobile Adjustments */
@media (max-width: 575.98px) {
  .web3-theme .edit-panel {
    max-width: 100%;
    border-radius: 0;
  }

  .web3-theme .edit-panel-header {
    padding: 16px 20px;
  }

  .web3-theme .edit-panel-body {
    padding: 20px;
  }

  .web3-theme .edit-panel-footer {
    padding: 16px 20px;
  }

  .web3-theme .edit-panel .edit-row {
    flex-direction: column;
    gap: 0;
  }
}

/* ═══════════════════════════════════════════════════════════════
   Customize Tab - Dark Theme Override
   All Bootstrap cards and forms should be dark themed
   ═══════════════════════════════════════════════════════════════ */

/* Override all cards in Customize tab */
.web3-theme #tab-customize .card {
  background: rgba(28, 28, 30, 0.95) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: 16px !important;
  color: var(--w3-text-primary) !important;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.web3-theme #tab-customize .card-header {
  background: rgba(255, 255, 255, 0.03) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
  color: var(--w3-text-primary) !important;
  padding: 16px 20px;
}

.web3-theme #tab-customize .card-header .card-title {
  color: var(--w3-text-primary) !important;
  font-weight: 600;
}

.web3-theme #tab-customize .card-body {
  background: transparent !important;
  color: var(--w3-text-secondary) !important;
  padding: 20px;
}

.web3-theme #tab-customize .card-footer {
  background: rgba(255, 255, 255, 0.02) !important;
  border-top: 1px solid rgba(255, 255, 255, 0.06) !important;
  color: var(--w3-text-muted) !important;
}

/* Form controls in Customize tab */
.web3-theme #tab-customize .form-control,
.web3-theme #tab-customize .form-select {
  background: #2c2c2e !important;
  border: 1px solid #48484a !important;
  color: #fff !important;
  border-radius: 8px;
}

.web3-theme #tab-customize .form-control:focus,
.web3-theme #tab-customize .form-select:focus {
  background: #2c2c2e !important;
  border-color: var(--w3-accent-cyan) !important;
  box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.15) !important;
  color: #fff !important;
}

.web3-theme #tab-customize .form-control::placeholder {
  color: #636366 !important;
}

.web3-theme #tab-customize .form-label {
  color: var(--w3-text-secondary) !important;
  font-weight: 500;
}

.web3-theme #tab-customize .form-text,
.web3-theme #tab-customize small.text-muted {
  color: var(--w3-text-muted) !important;
}

/* Input groups */
.web3-theme #tab-customize .input-group-text {
  background: #3a3a3c !important;
  border: 1px solid #48484a !important;
  color: var(--w3-text-secondary) !important;
}

/* Buttons in Customize tab */
.web3-theme #tab-customize .btn-outline-secondary {
  border-color: #48484a !important;
  color: var(--w3-text-secondary) !important;
}

.web3-theme #tab-customize .btn-outline-secondary:hover {
  background: #3a3a3c !important;
  border-color: #636366 !important;
  color: #fff !important;
}

.web3-theme #tab-customize .btn-outline-primary {
  border-color: var(--w3-accent-cyan) !important;
  color: var(--w3-accent-cyan) !important;
}

.web3-theme #tab-customize .btn-outline-primary:hover {
  background: var(--w3-accent-cyan) !important;
  color: #000 !important;
}

.web3-theme #tab-customize .btn-outline-success {
  border-color: #34c759 !important;
  color: #34c759 !important;
}

.web3-theme #tab-customize .btn-outline-success:hover {
  background: #34c759 !important;
  color: #000 !important;
}

.web3-theme #tab-customize .btn-outline-danger {
  border-color: #ff453a !important;
  color: #ff453a !important;
}

.web3-theme #tab-customize .btn-outline-danger:hover {
  background: #ff453a !important;
  color: #fff !important;
}

.web3-theme #tab-customize .btn-primary {
  background: var(--w3-accent-cyan) !important;
  border-color: var(--w3-accent-cyan) !important;
  color: #000 !important;
}

.web3-theme #tab-customize .btn-light {
  background: #3a3a3c !important;
  border-color: #48484a !important;
  color: var(--w3-text-secondary) !important;
}

.web3-theme #tab-customize .btn-light:hover {
  background: #48484a !important;
  color: #fff !important;
}

/* Alerts in Customize tab */
.web3-theme #tab-customize .alert-info {
  background: rgba(34, 211, 238, 0.1) !important;
  border-color: rgba(34, 211, 238, 0.2) !important;
  color: var(--w3-text-secondary) !important;
}

.web3-theme #tab-customize .alert-info a {
  color: var(--w3-accent-cyan) !important;
}

.web3-theme #tab-customize .alert-warning {
  background: rgba(255, 204, 0, 0.1) !important;
  border-color: rgba(255, 204, 0, 0.2) !important;
  color: #ffd60a !important;
}

/* Tables in Customize tab */
.web3-theme #tab-customize .table {
  color: var(--w3-text-secondary) !important;
  --bs-table-bg: transparent;
  --bs-table-striped-bg: rgba(255, 255, 255, 0.02);
  --bs-table-hover-bg: rgba(255, 255, 255, 0.04);
}

.web3-theme #tab-customize .table th {
  color: var(--w3-text-primary) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
  font-weight: 600;
}

.web3-theme #tab-customize .table td {
  border-color: rgba(255, 255, 255, 0.06) !important;
  color: var(--w3-text-secondary) !important;
}

/* Badges */
.web3-theme #tab-customize .badge.bg-success {
  background: #34c759 !important;
}

.web3-theme #tab-customize .badge.bg-primary {
  background: var(--w3-accent-cyan) !important;
  color: #000 !important;
}

/* Switches */
.web3-theme #tab-customize .form-check-input {
  background-color: #48484a !important;
  border-color: #636366 !important;
}

.web3-theme #tab-customize .form-check-input:checked {
  background-color: var(--w3-accent-cyan) !important;
  border-color: var(--w3-accent-cyan) !important;
}

.web3-theme #tab-customize .form-check-label {
  color: var(--w3-text-primary) !important;
}

/* HR separators */
.web3-theme #tab-customize hr {
  border-color: rgba(255, 255, 255, 0.1) !important;
  opacity: 1;
}

/* Status Cards (Lead Statuses, Lead Types) */
.web3-theme #tab-customize .status-card {
  background: rgba(44, 44, 46, 0.8) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: 12px !important;
}

.web3-theme #tab-customize .status-card .form-label {
  color: var(--w3-text-muted) !important;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.web3-theme #tab-customize .status-card .form-control {
  background: #1c1c1e !important;
}

/* Color picker - properly filled */
.web3-theme #tab-customize .form-control-color,
.web3-theme #tab-customize input[type="color"] {
  width: 40px !important;
  height: 40px !important;
  min-width: 40px !important;
  min-height: 40px !important;
  padding: 2px !important;
  border: 2px solid rgba(255, 255, 255, 0.15) !important;
  border-radius: 8px !important;
  background: transparent !important;
  cursor: pointer;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

.web3-theme #tab-customize .form-control-color::-webkit-color-swatch-wrapper,
.web3-theme #tab-customize input[type="color"]::-webkit-color-swatch-wrapper {
  padding: 0;
}

.web3-theme #tab-customize .form-control-color::-webkit-color-swatch,
.web3-theme #tab-customize input[type="color"]::-webkit-color-swatch {
  border: none;
  border-radius: 5px;
}

.web3-theme #tab-customize .form-control-color::-moz-color-swatch,
.web3-theme #tab-customize input[type="color"]::-moz-color-swatch {
  border: none;
  border-radius: 5px;
}

.web3-theme #tab-customize .form-control-color:hover,
.web3-theme #tab-customize input[type="color"]:hover {
  border-color: var(--w3-accent-cyan) !important;
}

.web3-theme #tab-customize .form-control-color:focus,
.web3-theme #tab-customize input[type="color"]:focus {
  outline: none;
  border-color: var(--w3-accent-cyan) !important;
  box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.15) !important;
}

.web3-theme #tab-customize .status-card code {
  color: var(--w3-text-muted) !important;
  background: transparent !important;
}

/* H6 headings */
.web3-theme #tab-customize h6 {
  color: var(--w3-text-primary) !important;
  font-weight: 600;
}

/* Empty state / text-muted paragraphs */
.web3-theme #tab-customize p.text-muted {
  color: var(--w3-text-muted) !important;
}

/* Tags list styling */
.web3-theme #tab-customize #custom-tags-list,
.web3-theme #tab-customize #default-tags-list {
  color: var(--w3-text-secondary) !important;
}

/* Custom Tag Items - Compact Dark Style */
.web3-theme #tab-customize .tag-item {
  background: rgba(44, 44, 46, 0.6) !important;
  border: 1px solid rgba(255, 255, 255, 0.06) !important;
  border-radius: 10px !important;
  padding: 12px 16px !important;
  margin-bottom: 8px !important;
  transition: var(--w3-transition);
}

.web3-theme #tab-customize .tag-item:hover {
  background: rgba(44, 44, 46, 0.9) !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
}

.web3-theme #tab-customize .tag-item .badge {
  font-size: 0.8125rem !important;
  padding: 0.4em 0.8em !important;
  font-weight: 500;
}

.web3-theme #tab-customize .tag-item small.text-muted {
  font-size: 0.8125rem !important;
  color: var(--w3-text-muted) !important;
}

.web3-theme #tab-customize .tag-item .btn-group .btn {
  padding: 0.25rem 0.5rem !important;
  font-size: 0.75rem !important;
}

.web3-theme #tab-customize .tag-item .btn-outline-secondary {
  border-color: rgba(255, 255, 255, 0.1) !important;
  color: var(--w3-text-muted) !important;
  background: transparent !important;
}

.web3-theme #tab-customize .tag-item .btn-outline-secondary:hover {
  background: rgba(255, 255, 255, 0.1) !important;
  color: var(--w3-text-primary) !important;
}

.web3-theme #tab-customize .tag-item .btn-outline-danger {
  border-color: rgba(255, 69, 58, 0.3) !important;
  color: #ff453a !important;
  background: transparent !important;
}

.web3-theme #tab-customize .tag-item .btn-outline-danger:hover {
  background: rgba(255, 69, 58, 0.15) !important;
}

/* Default Tags - Compact Display */
.web3-theme #tab-customize #default-tags-list .badge {
  font-size: 0.8125rem !important;
  padding: 0.4em 0.8em !important;
  font-weight: 500;
}

/* Ledo spinner in loading state */
.web3-theme #tab-customize .ledo-spinner {
  color: var(--w3-accent-cyan) !important;
}

/* ═══════════════════════════════════════════════════════════════
   Billing Tab - Dark Theme Override
   ═══════════════════════════════════════════════════════════════ */

/* Override all cards in Billing tab */
.web3-theme #tab-billing .card {
  background: rgba(28, 28, 30, 0.95) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: 16px !important;
  color: var(--w3-text-primary) !important;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.web3-theme #tab-billing .card-header {
  background: rgba(255, 255, 255, 0.03) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
  color: var(--w3-text-primary) !important;
  padding: 16px 20px;
  border-radius: 16px 16px 0 0 !important;
}

.web3-theme #tab-billing .card-header .card-title {
  color: var(--w3-text-primary) !important;
  font-weight: 600;
}

.web3-theme #tab-billing .card-body {
  background: transparent !important;
  color: var(--w3-text-secondary) !important;
}

/* Tables in Billing tab */
.web3-theme #tab-billing .table {
  color: var(--w3-text-secondary) !important;
  --bs-table-bg: transparent;
  margin-bottom: 0;
}

.web3-theme #tab-billing .table th {
  color: var(--w3-text-primary) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.02) !important;
}

.web3-theme #tab-billing .table td {
  border-color: rgba(255, 255, 255, 0.06) !important;
  color: var(--w3-text-secondary) !important;
}

.web3-theme #tab-billing .table tbody tr:hover {
  background: rgba(255, 255, 255, 0.03) !important;
}

/* Billing summary card */
.web3-theme #tab-billing #billingSummary {
  color: var(--w3-text-secondary) !important;
}

.web3-theme #tab-billing .text-muted {
  color: var(--w3-text-muted) !important;
}

/* Badges in billing */
.web3-theme #tab-billing .badge {
  font-weight: 500;
}

.web3-theme #tab-billing .badge.bg-success {
  background: #34c759 !important;
}

.web3-theme #tab-billing .badge.bg-warning {
  background: #ff9f0a !important;
  color: #000 !important;
}

.web3-theme #tab-billing .badge.bg-danger {
  background: #ff453a !important;
}

.web3-theme #tab-billing .badge.bg-secondary {
  background: #636366 !important;
}

/* Buttons in Billing tab */
.web3-theme #tab-billing .btn-outline-primary {
  border-color: var(--w3-accent-cyan) !important;
  color: var(--w3-accent-cyan) !important;
}

.web3-theme #tab-billing .btn-outline-primary:hover {
  background: var(--w3-accent-cyan) !important;
  color: #000 !important;
}

.web3-theme #tab-billing .btn-sm {
  padding: 0.375rem 0.75rem;
  font-size: 0.8125rem;
}

/* ═══════════════════════════════════════════════════════════════
   Mobile Responsive - Status Cards & Lead Types
   ═══════════════════════════════════════════════════════════════ */

/* Status/Lead Type Card - Stack layout on mobile */
@media (max-width: 767.98px) {
  /* Card container - stack vertically */
  .web3-theme #tab-customize .status-card {
    flex-direction: column !important;
    gap: 12px !important;
    padding: 16px !important;
  }

  /* Order controls - horizontal on mobile */
  .web3-theme #tab-customize .status-order {
    flex-direction: row !important;
    justify-content: flex-start !important;
    gap: 8px !important;
    order: -1;
  }

  .web3-theme #tab-customize .status-order .btn {
    width: 32px !important;
    height: 32px !important;
  }

  /* Status body takes full width */
  .web3-theme #tab-customize .status-body {
    width: 100% !important;
    gap: 12px !important;
  }

  /* Status row - wrap to multiple lines */
  .web3-theme #tab-customize .status-row {
    flex-wrap: wrap !important;
    gap: 12px !important;
  }

  /* Name field - full width on mobile */
  .web3-theme #tab-customize .status-field {
    flex: 1 1 100% !important;
    min-width: 0 !important;
  }

  /* Active/Default toggles - side by side */
  .web3-theme #tab-customize .status-active-wrap {
    flex: 0 0 auto !important;
    min-width: 60px !important;
  }

  /* Color field - full width */
  .web3-theme #tab-customize .status-row:last-child .status-field {
    flex: 1 1 100% !important;
  }

  /* Actions - full width row */
  .web3-theme #tab-customize .status-actions {
    flex: 1 1 100% !important;
    margin-left: 0 !important;
    justify-content: flex-start !important;
    margin-top: 8px !important;
  }

  .web3-theme #tab-customize .status-actions .btn {
    flex: 1 !important;
    max-width: 120px !important;
  }

  /* Inputs - larger touch targets */
  .web3-theme #tab-customize .status-card .form-control {
    font-size: 16px !important; /* Prevents iOS zoom on focus */
    padding: 10px 12px !important;
  }

  /* Color picker - larger on mobile */
  .web3-theme #tab-customize .form-control-color,
  .web3-theme #tab-customize input[type="color"] {
    width: 48px !important;
    height: 48px !important;
  }

  /* Tag items - stack on mobile */
  .web3-theme #tab-customize .tag-item {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 10px !important;
  }

  .web3-theme #tab-customize .tag-item .d-flex {
    width: 100% !important;
    justify-content: space-between !important;
  }

  .web3-theme #tab-customize .tag-item .btn-group {
    margin-top: 8px !important;
  }
}

/* Tablet adjustments */
@media (max-width: 991.98px) and (min-width: 768px) {
  .web3-theme #tab-customize .status-row {
    gap: 8px !important;
  }

  .web3-theme #tab-customize .status-field {
    flex: 1 1 40% !important;
  }

  .web3-theme #tab-customize .status-active-wrap {
    flex: 0 0 auto !important;
  }
}

/* ═══════════════════════════════════════════════════════════════
   Mobile Responsive - Edit Panel Logo Upload
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 575.98px) {
  .web3-theme .edit-panel .logo-upload-area {
    flex-direction: column !important;
    text-align: center !important;
    padding: 20px !important;
  }

  .web3-theme .edit-panel .logo-preview {
    width: 80px !important;
    height: 80px !important;
    margin-bottom: 12px !important;
  }

  .web3-theme .edit-panel .logo-upload-text {
    text-align: center !important;
  }
}

/* ═══════════════════════════════════════════════════════════════
   Mobile Responsive - Company Profile Card
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 575.98px) {
  .web3-theme .company-profile-card {
    margin-top: -50px;
  }

  .web3-theme .company-avatar-wrapper {
    width: 64px !important;
    height: 64px !important;
    flex-shrink: 0 !important;
  }

  .web3-theme .company-name {
    font-size: 1.25rem !important;
    word-break: break-word;
  }

  /* Social links - wrap */
  .web3-theme .social-links-row {
    flex-wrap: wrap !important;
  }

  .web3-theme .social-link-btn {
    width: 36px !important;
    height: 36px !important;
  }

  /* Info grid - single column */
  .web3-theme .info-grid {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }

  /* Profile hint - stack */
  .web3-theme .profile-hint {
    flex-direction: column !important;
    text-align: center !important;
    gap: 12px !important;
  }

  .web3-theme .profile-hint .btn-web3 {
    width: 100% !important;
    justify-content: center !important;
  }
}

/* ═══════════════════════════════════════════════════════════════
   PAGE-SPECIFIC BACKGROUNDS
   All pages using the Web3 theme share these patterns
   ═══════════════════════════════════════════════════════════════ */

/* Profile Page */
html body.web3-theme.profile-page-body {
  background: #000000 !important;
}

html body.web3-theme .wrapper.profile-page-wrapper {
  background:
    radial-gradient(ellipse 80% 50% at 50% -20%, rgba(34, 211, 238, 0.08), transparent),
    radial-gradient(ellipse 60% 40% at 80% 60%, rgba(167, 139, 250, 0.05), transparent),
    #000000 !important;
}

/* Users Page */
.web3-theme.users-page-body {
  background: #000000 !important;
}

.web3-theme.users-page-body .wrapper,
.web3-theme.users-page-body .main,
.web3-theme.users-page-body .content {
  background: transparent !important;
}

.web3-theme.users-page-body .action-bar {
  margin-top: -30px;
}

/* Leads Page */
.web3-theme.leads-page-body {
  background: #000000 !important;
}

.web3-theme.leads-page-body .wrapper,
.web3-theme.leads-page-body .main,
.web3-theme.leads-page-body .content {
  background: transparent !important;
}

.web3-theme.leads-page-body .action-bar {
  margin-top: -30px;
}

/* Tasks Page */
.web3-theme.tasks-page-body {
  background: #000000 !important;
}

.web3-theme.tasks-page-body .wrapper,
.web3-theme.tasks-page-body .main,
.web3-theme.tasks-page-body .content {
  background: transparent !important;
}

/* Notifications Page */
.web3-theme.notifications-page-body {
  background: #000000 !important;
}

.web3-theme.notifications-page-body .wrapper,
.web3-theme.notifications-page-body .main,
.web3-theme.notifications-page-body .content {
  background: transparent !important;
}

/* Notifications List */
.web3-theme .ios-notifications-list {
  background: transparent;
  padding-bottom: 40px;
}

.web3-theme .notification-list {
  list-style: none;
  padding: 0;
  margin: 0;
  background: rgba(28, 28, 30, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  overflow: hidden;
}

.web3-theme .notification-item {
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

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

.web3-theme .notification-link {
  display: flex;
  align-items: flex-start;
  padding: 14px 16px;
  text-decoration: none;
  transition: background-color 0.15s ease;
}

.web3-theme .notification-link:hover {
  background-color: rgba(255, 255, 255, 0.03);
}

.web3-theme .notification-indicator {
  width: 12px;
  flex-shrink: 0;
  padding-top: 6px;
}

.web3-theme .unread-dot {
  display: block;
  width: 8px;
  height: 8px;
  background: #22d3ee;
  border-radius: 50%;
  box-shadow: 0 0 8px rgba(34, 211, 238, 0.5);
}

.web3-theme .notification-icon {
  width: 36px;
  height: 36px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 12px;
  flex-shrink: 0;
}

.web3-theme .notification-icon i {
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.5);
}

.web3-theme .notification-item.unread .notification-icon {
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.3), rgba(167, 139, 250, 0.3));
}

.web3-theme .notification-item.unread .notification-icon i {
  color: #fff;
}

.web3-theme .notification-content {
  flex: 1;
  min-width: 0;
}

.web3-theme .notification-title {
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
  line-height: 1.3;
  word-break: break-word;
}

.web3-theme .notification-item:not(.unread) .notification-title {
  color: rgba(255, 255, 255, 0.5);
  font-weight: 400;
}

.web3-theme .notification-meta {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 2px;
  line-height: 1.4;
}

.web3-theme .notification-time {
  font-size: 0.8rem;
  color: #22d3ee;
  margin-top: 4px;
  font-weight: 500;
}

.web3-theme .notification-chevron {
  flex-shrink: 0;
  margin-left: 8px;
  color: rgba(255, 255, 255, 0.3);
  display: flex;
  align-items: center;
}

/* Notifications Page Pagination */
.web3-theme.notifications-page-body .pagination .page-link {
  background: rgba(28, 28, 30, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.7);
}

.web3-theme.notifications-page-body .pagination .page-link:hover {
  background: rgba(28, 28, 30, 0.9);
  border-color: rgba(255, 255, 255, 0.15);
  color: #fff;
}

.web3-theme.notifications-page-body .pagination .page-item.active .page-link {
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.3), rgba(167, 139, 250, 0.3));
  border-color: rgba(34, 211, 238, 0.5);
  color: #fff;
}

.web3-theme.notifications-page-body .pagination .page-item.disabled .page-link {
  background: rgba(28, 28, 30, 0.5);
  border-color: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.3);
}

/* Calendar Page */
.web3-theme.calendar-page-body {
  background: #000000 !important;
}

.web3-theme.calendar-page-body .wrapper,
.web3-theme.calendar-page-body .main,
.web3-theme.calendar-page-body .content {
  background: transparent !important;
}

/* Companies Page */
.web3-theme.companies-page-body {
  background: #000000 !important;
}

.web3-theme.companies-page-body .wrapper,
.web3-theme.companies-page-body .main,
.web3-theme.companies-page-body .content {
  background: transparent !important;
}

.web3-theme.companies-page-body .action-bar {
  margin-top: -30px;
}

/* ═══════════════════════════════════════════════════════════════
   GENERIC HERO SECTION - Space Background
   Reusable hero component for list pages
   ═══════════════════════════════════════════════════════════════ */

.web3-theme .page-hero {
  position: relative;
  height: 180px;
  overflow: hidden;
}

.web3-theme .page-hero .hero-space-bg,
.web3-theme .profile-hero .hero-space-bg,
.web3-theme .users-hero .hero-space-bg,
.web3-theme .leads-hero .hero-space-bg,
.web3-theme .companies-hero .hero-space-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 40%;
}

.web3-theme .page-hero .hero-overlay,
.web3-theme .profile-hero .hero-space-overlay,
.web3-theme .users-hero .hero-overlay,
.web3-theme .leads-hero .hero-overlay,
.web3-theme .companies-hero .hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg,
    rgba(0, 0, 0, 0.4) 0%,
    rgba(0, 0, 0, 0.2) 50%,
    #000000 100%
  );
}

.web3-theme .page-hero .hero-content,
.web3-theme .users-hero .hero-content,
.web3-theme .leads-hero .hero-content,
.web3-theme .companies-hero .hero-content {
  position: absolute;
  bottom: 20px;
  left: 24px;
  z-index: 1;
}

.web3-theme .page-hero .hero-title,
.web3-theme .users-hero .hero-title,
.web3-theme .leads-hero .hero-title,
.web3-theme .companies-hero .hero-title {
  font-size: 1.75rem;
  font-weight: 700;
  color: #ffffff;
  margin: 0;
  letter-spacing: -0.02em;
}

.web3-theme .page-hero .hero-subtitle,
.web3-theme .users-hero .hero-subtitle,
.web3-theme .leads-hero .hero-subtitle,
.web3-theme .companies-hero .hero-subtitle {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.6);
  margin: 2px 0 0 0;
}

/* Profile Hero - slightly different height */
.web3-theme .profile-hero {
  position: relative;
  height: 200px;
  overflow: hidden;
}

/* Users & Leads Hero - standard height */
.web3-theme .users-hero,
.web3-theme .leads-hero,
.web3-theme .companies-hero {
  position: relative;
  height: 180px;
  overflow: hidden;
}

/* ═══════════════════════════════════════════════════════════════
   ACTION BAR - Common Header Bar Pattern
   Used across Users, Leads, Tasks pages
   ═══════════════════════════════════════════════════════════════ */

.web3-theme .action-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 16px 0;
  position: relative;
  z-index: 2;
}

/* Overlap hero when used after hero section */
.web3-theme .action-bar.overlap-hero {
  margin-top: -30px;
}

.web3-theme .page-title {
  display: flex;
  align-items: center;
  gap: 12px;
}

.web3-theme .page-title h1 {
  font-size: 1.75rem;
  font-weight: 700;
  color: #ffffff;
  margin: 0;
}

.web3-theme .item-count,
.web3-theme .leads-count {
  background: linear-gradient(135deg, #22d3ee, #a78bfa);
  color: #000;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 20px;
}

/* ═══════════════════════════════════════════════════════════════
   SEARCH BOX - Common Search Input
   ═══════════════════════════════════════════════════════════════ */

.web3-theme .search-box {
  position: relative;
  flex: 1;
  max-width: 400px;
}

.web3-theme .search-box > i {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(255, 255, 255, 0.4);
  font-size: 0.9rem;
  pointer-events: none;
}

.web3-theme .search-input {
  width: 100%;
  background: rgba(28, 28, 30, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 10px 14px 10px 40px;
  color: #ffffff;
  font-size: 0.875rem;
  transition: all 0.2s ease;
}

.web3-theme .search-input:focus {
  outline: none;
  border-color: rgba(34, 211, 238, 0.5);
  box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.1);
}

.web3-theme .search-input::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

/* ═══════════════════════════════════════════════════════════════
   BUTTON VARIANTS - Action & Bulk Buttons
   ═══════════════════════════════════════════════════════════════ */

.web3-theme .btn-action {
  display: inline-flex;
  align-items: center;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.7);
}

.web3-theme .btn-action:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.web3-theme .btn-view {
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.7);
}

.web3-theme .btn-view:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.web3-theme .btn-toggle {
  background: rgba(34, 211, 238, 0.15);
  color: #22d3ee;
}

.web3-theme .btn-toggle:hover {
  background: rgba(34, 211, 238, 0.25);
  color: #22d3ee;
}

.web3-theme .btn-activate {
  background: rgba(52, 199, 89, 0.15);
  color: #34c759;
}

.web3-theme .btn-activate:hover {
  background: rgba(52, 199, 89, 0.25);
}

.web3-theme .btn-deactivate {
  background: rgba(255, 149, 0, 0.15);
  color: #ff9500;
}

.web3-theme .btn-deactivate:hover {
  background: rgba(255, 149, 0, 0.25);
}

.web3-theme .btn-delete {
  background: rgba(255, 69, 58, 0.1);
  color: #ff453a;
}

.web3-theme .btn-delete:hover {
  background: rgba(255, 69, 58, 0.2);
}

/* Bulk Action Button Variants */
.web3-theme .btn-bulk {
  background: rgba(255, 193, 7, 0.15);
  color: #ffc107;
}

.web3-theme .btn-bulk:hover {
  background: rgba(255, 193, 7, 0.25);
}

.web3-theme .btn-bulk-danger {
  background: rgba(255, 69, 58, 0.15);
  color: #ff453a;
}

.web3-theme .btn-bulk-danger:hover {
  background: rgba(255, 69, 58, 0.25);
}

.web3-theme .btn-bulk-success {
  background: rgba(52, 199, 89, 0.15);
  color: #34c759;
}

.web3-theme .btn-bulk-success:hover {
  background: rgba(52, 199, 89, 0.25);
}

.web3-theme .btn-bulk-info {
  background: rgba(34, 211, 238, 0.15);
  color: #22d3ee;
}

.web3-theme .btn-bulk-info:hover {
  background: rgba(34, 211, 238, 0.25);
}

.web3-theme .btn-bulk-export {
  background: rgba(167, 139, 250, 0.15);
  color: #a78bfa;
}

.web3-theme .btn-bulk-export:hover {
  background: rgba(167, 139, 250, 0.25);
}

.web3-theme .btn-web3-danger {
  background: rgba(239, 68, 68, 0.15) !important;
  border-color: rgba(239, 68, 68, 0.3) !important;
  color: #f87171 !important;
}

.web3-theme .btn-web3-danger:hover {
  background: rgba(239, 68, 68, 0.25) !important;
  border-color: rgba(239, 68, 68, 0.5) !important;
}

.web3-theme .btn-save {
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.2), rgba(167, 139, 250, 0.2));
  border: 1px solid rgba(34, 211, 238, 0.3);
  color: #22d3ee;
  padding: 8px 16px;
  border-radius: 8px;
  font-weight: 500;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.web3-theme .btn-save:hover {
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.3), rgba(167, 139, 250, 0.3));
  border-color: #22d3ee;
  box-shadow: 0 0 15px rgba(34, 211, 238, 0.2);
}

.web3-theme .btn-save.saved {
  background: rgba(52, 199, 89, 0.2);
  border-color: rgba(52, 199, 89, 0.3);
  color: #34c759;
}

/* ═══════════════════════════════════════════════════════════════
   FILTER CHIPS - Status/Type Filters
   ═══════════════════════════════════════════════════════════════ */

.web3-theme .filters-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 24px;
  align-items: center;
}

.web3-theme .filter-group {
  display: flex;
  gap: 6px;
}

.web3-theme .filter-chip {
  display: inline-flex;
  align-items: center;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 0.8rem;
  font-weight: 500;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.6);
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}

.web3-theme .filter-chip:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.8);
}

.web3-theme .filter-chip.active {
  background: rgba(34, 211, 238, 0.15);
  border-color: rgba(34, 211, 238, 0.3);
  color: #22d3ee;
}

.web3-theme .chip-count {
  background: rgba(255, 255, 255, 0.1);
  padding: 2px 8px;
  border-radius: 10px;
  margin-left: 6px;
  font-size: 0.7rem;
}

.web3-theme .filter-chip.active .chip-count {
  background: rgba(34, 211, 238, 0.3);
}

.web3-theme .filter-select {
  background: rgba(28, 28, 30, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 8px 12px;
  color: #fff;
  font-size: 0.85rem;
}

.web3-theme .filter-select:focus {
  outline: none;
  border-color: rgba(34, 211, 238, 0.5);
  box-shadow: 0 0 0 2px rgba(34, 211, 238, 0.1);
}

.web3-theme .filter-select option {
  background: #1c1c1e;
  color: #fff;
}

/* ═══════════════════════════════════════════════════════════════
   ACCORDION LIST ITEMS - Common Pattern
   Used in Users, Leads, Companies for expandable items
   ═══════════════════════════════════════════════════════════════ */

.web3-theme .user-accordion,
.web3-theme .leads-accordion,
.web3-theme .company-accordion {
  padding-bottom: 40px;
}

.web3-theme .user-accordion .accordion-item,
.web3-theme .leads-accordion .accordion-item,
.web3-theme .company-accordion .accordion-item {
  background: rgba(28, 28, 30, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px !important;
  margin-bottom: 8px;
  overflow: hidden;
}

.web3-theme .user-accordion .accordion-item:hover,
.web3-theme .leads-accordion .accordion-item:hover,
.web3-theme .company-accordion .accordion-item:hover {
  border-color: rgba(255, 255, 255, 0.12);
}

.web3-theme .user-accordion .accordion-button,
.web3-theme .leads-accordion .accordion-button,
.web3-theme .company-accordion .accordion-button {
  background: transparent !important;
  color: #fff !important;
  border: none;
  box-shadow: none !important;
  padding: 16px;
}

.web3-theme .user-accordion .accordion-button:hover,
.web3-theme .leads-accordion .accordion-button:hover,
.web3-theme .company-accordion .accordion-button:hover {
  background: rgba(255, 255, 255, 0.02) !important;
}

.web3-theme .user-accordion .accordion-button:not(.collapsed),
.web3-theme .leads-accordion .accordion-button:not(.collapsed),
.web3-theme .company-accordion .accordion-button:not(.collapsed) {
  background: rgba(255, 255, 255, 0.03) !important;
}

.web3-theme .user-accordion .accordion-button::after,
.web3-theme .leads-accordion .accordion-button::after,
.web3-theme .company-accordion .accordion-button::after {
  filter: invert(1);
  opacity: 0.5;
}

.web3-theme .user-accordion .accordion-button:not(.collapsed)::after,
.web3-theme .leads-accordion .accordion-button:not(.collapsed)::after,
.web3-theme .company-accordion .accordion-button:not(.collapsed)::after {
  opacity: 0.8;
}

.web3-theme .user-accordion .accordion-collapse,
.web3-theme .leads-accordion .accordion-collapse,
.web3-theme .company-accordion .accordion-collapse {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.web3-theme .user-accordion .accordion-body,
.web3-theme .leads-accordion .accordion-body,
.web3-theme .company-accordion .accordion-body {
  padding: 20px;
  background: rgba(0, 0, 0, 0.2);
}

/* Form elements inside accordion bodies */
.web3-theme .user-accordion .accordion-body .form-label,
.web3-theme .leads-accordion .accordion-body .form-label,
.web3-theme .company-accordion .accordion-body .form-label {
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.8rem;
}

.web3-theme .user-accordion .accordion-body .form-select,
.web3-theme .user-accordion .accordion-body .form-control,
.web3-theme .leads-accordion .accordion-body .form-select,
.web3-theme .leads-accordion .accordion-body .form-control,
.web3-theme .company-accordion .accordion-body .form-select,
.web3-theme .company-accordion .accordion-body .form-control {
  background: rgba(44, 44, 46, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #fff;
  border-radius: 8px;
}

.web3-theme .user-accordion .accordion-body .form-select:focus,
.web3-theme .user-accordion .accordion-body .form-control:focus,
.web3-theme .leads-accordion .accordion-body .form-select:focus,
.web3-theme .leads-accordion .accordion-body .form-control:focus,
.web3-theme .company-accordion .accordion-body .form-select:focus,
.web3-theme .company-accordion .accordion-body .form-control:focus {
  background: rgba(44, 44, 46, 0.9);
  border-color: rgba(34, 211, 238, 0.5);
  box-shadow: 0 0 0 2px rgba(34, 211, 238, 0.1);
  color: #fff;
}

.web3-theme .user-accordion .accordion-body .form-select option,
.web3-theme .leads-accordion .accordion-body .form-select option,
.web3-theme .company-accordion .accordion-body .form-select option {
  background: #1c1c1e;
  color: #fff;
}

/* ═══════════════════════════════════════════════════════════════
   ROUNDED SQUARE AVATARS - Web3 Standard
   All avatars should be rounded squares (10px radius), not circles
   ═══════════════════════════════════════════════════════════════ */

.web3-theme .user-avatar,
.web3-theme .lead-avatar,
.web3-theme .company-avatar,
.web3-theme .company-mini-avatar {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.15), rgba(167, 139, 250, 0.15));
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
  font-size: 0.9rem;
  font-weight: 600;
  color: #22d3ee;
}

.web3-theme .user-avatar img,
.web3-theme .lead-avatar img,
.web3-theme .company-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Profile Avatar - slightly larger with gradient border */
.web3-theme .profile-avatar-wrapper {
  width: 80px;
  height: 80px;
  border-radius: 10px;
  padding: 3px;
  background: linear-gradient(135deg, var(--w3-accent-cyan), var(--w3-accent-purple));
  flex-shrink: 0;
}

.web3-theme .profile-avatar-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 8px;
}

.web3-theme .profile-avatar-wrapper .avatar-placeholder {
  width: 100%;
  height: 100%;
  border-radius: 8px;
  background: var(--w3-bg-surface);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--w3-accent-cyan);
}

/* ═══════════════════════════════════════════════════════════════
   ROLE & STATUS BADGES
   ═══════════════════════════════════════════════════════════════ */

.web3-theme .role-badge {
  font-size: 0.65rem;
  font-weight: 500;
  padding: 2px 8px;
  border-radius: 10px;
  text-transform: capitalize;
}

.web3-theme .role-superadmin {
  background: rgba(255, 69, 58, 0.2);
  color: #ff453a;
}

.web3-theme .role-admin {
  background: rgba(34, 211, 238, 0.2);
  color: #22d3ee;
}

.web3-theme .role-manager {
  background: rgba(167, 139, 250, 0.2);
  color: #a78bfa;
}

.web3-theme .role-agent {
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.6);
}

.web3-theme .status-badge {
  font-size: 0.65rem;
  font-weight: 500;
  padding: 2px 8px;
  border-radius: 10px;
}

.web3-theme .status-inactive {
  background: rgba(255, 69, 58, 0.2);
  color: #ff453a;
}

.web3-theme .status-current {
  background: rgba(52, 199, 89, 0.2);
  color: #34c759;
}

/* Badge variants for success/cyan */
.web3-theme .badge-web3-success {
  background: rgba(52, 211, 153, 0.15);
  border-color: rgba(52, 211, 153, 0.3);
  color: var(--w3-accent-emerald);
}

/* ═══════════════════════════════════════════════════════════════
   PROFILE PAGE SPECIFIC STYLES
   ═══════════════════════════════════════════════════════════════ */

/* Profile Card - Main floating card with shine border */
.web3-theme .profile-card {
  background: var(--w3-bg-card);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--w3-glass-border);
  border-radius: var(--w3-radius-xl);
  margin-top: -80px;
  position: relative;
  z-index: 10;
  overflow: hidden;
}

.web3-theme .profile-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg,
    transparent,
    rgba(34, 211, 238, 0.5),
    rgba(167, 139, 250, 0.5),
    transparent
  );
}

.web3-theme .profile-name {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--w3-text-primary);
  margin: 0;
  letter-spacing: -0.02em;
}

.web3-theme .profile-role {
  font-size: 0.875rem;
  color: var(--w3-text-muted);
  text-transform: capitalize;
}

.web3-theme .profile-links {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.web3-theme .profile-link {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--w3-text-secondary);
  text-decoration: none;
  transition: all 0.2s ease;
}

.web3-theme .profile-link:hover {
  background: rgba(34, 211, 238, 0.1);
  border-color: var(--w3-accent-cyan);
  color: var(--w3-accent-cyan);
}

/* Settings Alerts */
.web3-theme .settings-alert {
  padding: 12px 16px;
  border-radius: 10px;
  font-size: 0.875rem;
}

.web3-theme .settings-alert-info {
  background: rgba(34, 211, 238, 0.1);
  border: 1px solid rgba(34, 211, 238, 0.2);
  color: var(--w3-text-secondary);
}

.web3-theme .settings-alert-success {
  background: rgba(52, 211, 153, 0.1);
  border: 1px solid rgba(52, 211, 153, 0.2);
  color: var(--w3-accent-emerald);
}

.web3-theme .settings-alert-warning {
  background: rgba(251, 191, 36, 0.1);
  border: 1px solid rgba(251, 191, 36, 0.2);
  color: #fbbf24;
}

.web3-theme .settings-subtitle {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--w3-text-primary);
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--w3-glass-border);
}

.web3-theme .settings-switch-item {
  padding: 12px 0;
  border-bottom: 1px solid var(--w3-glass-border);
}

.web3-theme .settings-switch-item:last-child {
  border-bottom: none;
}

.web3-theme .settings-switch-item .form-check-label strong {
  color: var(--w3-text-primary);
  font-size: 0.875rem;
}

/* OAuth Provider Items */
.web3-theme .oauth-provider-item {
  padding: 16px 0;
  border-bottom: 1px solid var(--w3-glass-border);
}

.web3-theme .oauth-provider-item:last-child {
  border-bottom: none;
}

.web3-theme .oauth-provider-item strong {
  color: var(--w3-text-primary);
}

/* Company Mini Card (in sidebar) */
.web3-theme .company-mini-card {
  padding: 16px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--w3-glass-border);
  border-radius: 12px;
}

/* Stat Row (in sidebar) */
.web3-theme .stat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
}

.web3-theme .stat-row .stat-label {
  color: var(--w3-text-muted);
  font-size: 0.875rem;
}

.web3-theme .stat-row .stat-value {
  color: var(--w3-text-primary);
  font-size: 1.25rem;
  font-weight: 700;
}

/* ═══════════════════════════════════════════════════════════════
   USERS PAGE SPECIFIC STYLES
   ═══════════════════════════════════════════════════════════════ */

.web3-theme .user-meta {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 4px;
}

.web3-theme .user-meta .separator {
  margin: 0 6px;
  opacity: 0.5;
}

/* Edit Form (in accordion body) */
.web3-theme .edit-form {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  padding: 16px;
}

.web3-theme .edit-form .form-label {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 4px;
}

.web3-theme .edit-form .form-select {
  background: rgba(28, 28, 30, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #fff;
  border-radius: 8px;
  padding: 8px 12px;
}

.web3-theme .edit-form .form-select:focus {
  background: rgba(28, 28, 30, 0.9);
  border-color: rgba(34, 211, 238, 0.5);
  box-shadow: 0 0 0 2px rgba(34, 211, 238, 0.1);
  color: #fff;
}

.web3-theme .edit-form .form-select option {
  background: #1c1c1e;
  color: #fff;
}

/* Info Row (in accordion body) */
.web3-theme .info-row {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.6);
}

.web3-theme .info-row i {
  color: rgba(255, 255, 255, 0.3);
}

/* Action Buttons Container */
.web3-theme .action-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* ═══════════════════════════════════════════════════════════════
   LEADS PAGE SPECIFIC STYLES
   ═══════════════════════════════════════════════════════════════ */

/* Filters Section */
.web3-theme .filters-section {
  margin-bottom: 20px;
}

.web3-theme .filters-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.web3-theme .filter-item {
  flex: 1;
  min-width: 150px;
  max-width: 250px;
}

/* Filters Accordion Override */
.web3-theme.leads-page-body .accordion-item.glass-card {
  background: rgba(28, 28, 30, 0.8) !important;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px !important;
}

.web3-theme.leads-page-body .accordion-button {
  background: transparent !important;
  color: #fff !important;
  box-shadow: none !important;
  font-size: 0.85rem;
  padding: 10px 14px;
}

.web3-theme.leads-page-body .accordion-button::after {
  filter: invert(1);
  opacity: 0.5;
}

.web3-theme.leads-page-body .accordion-body {
  background: transparent !important;
  padding: 12px;
}

/* Leads Header */
.web3-theme .leads-header {
  margin-bottom: 16px;
}

.web3-theme .leads-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.web3-theme .leads-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: #ffffff;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.web3-theme .leads-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* Bulk Actions Bar */
.web3-theme .bulk-actions-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 12px 16px;
  background: rgba(28, 28, 30, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  margin-bottom: 12px;
  align-items: center;
}

/* Select All Bar */
.web3-theme .select-all-bar {
  display: flex;
  align-items: center;
  padding: 8px 16px;
  background: rgba(28, 28, 30, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  margin-bottom: 8px;
}

/* Lead Row - Compact Style */
.web3-theme .lead-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: rgba(28, 28, 30, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  margin-bottom: 6px;
  transition: all 0.2s ease;
}

.web3-theme .lead-row:hover {
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(28, 28, 30, 0.9);
}

.web3-theme .lead-info {
  flex: 1;
  min-width: 0;
  text-decoration: none;
  color: inherit;
}

.web3-theme .lead-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.web3-theme .lead-name-row strong {
  color: #fff;
  font-size: 0.95rem;
}

.web3-theme .lead-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.web3-theme .lead-status-text {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
}

.web3-theme .lead-meta {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.web3-theme .lead-expand-btn {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.4);
  padding: 4px 8px;
  cursor: pointer;
  transition: color 0.2s;
}

.web3-theme .lead-expand-btn:hover {
  color: rgba(255, 255, 255, 0.7);
}

/* ═══════════════════════════════════════════════════════════════
   TASKS PAGE SPECIFIC STYLES
   ═══════════════════════════════════════════════════════════════ */

/* iOS Reminders List */
.web3-theme .ios-reminders-list {
  background: transparent;
  padding-bottom: 40px;
}

.web3-theme .date-group {
  margin-bottom: 1.5rem;
}

.web3-theme .date-header {
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  padding: 0.5rem 0;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.web3-theme .date-header.overdue {
  color: #ff453a;
}

.web3-theme .date-count {
  font-size: 0.75rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.05);
  padding: 2px 8px;
  border-radius: 10px;
}

.web3-theme .task-list {
  list-style: none;
  padding: 0;
  margin: 0;
  background: rgba(28, 28, 30, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  overflow: hidden;
}

.web3-theme .task-list .task-item {
  display: flex;
  align-items: flex-start;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  cursor: pointer;
  transition: background-color 0.15s ease;
}

.web3-theme .task-list .task-item:last-child {
  border-bottom: none;
}

.web3-theme .task-list .task-item:hover {
  background-color: rgba(255, 255, 255, 0.03);
}

.web3-theme .task-list .task-item.highlighted {
  background-color: rgba(34, 211, 238, 0.1);
}

.web3-theme .task-checkbox-wrapper {
  flex-shrink: 0;
  padding-top: 2px;
  margin-right: 12px;
}

/* iOS-style round checkbox */
.web3-theme .ios-checkbox {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.2);
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  padding: 0;
  color: transparent;
}

.web3-theme .ios-checkbox:hover {
  border-color: rgba(255, 255, 255, 0.4);
}

.web3-theme .ios-checkbox.priority-high {
  border-color: #ff453a;
}

.web3-theme .ios-checkbox.checked {
  background: #34c759;
  border-color: #34c759;
  color: #fff;
}

.web3-theme .ios-checkbox.checked i {
  font-size: 14px;
  font-weight: bold;
}

.web3-theme .task-content {
  flex: 1;
  min-width: 0;
}

.web3-theme .task-title {
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
  line-height: 1.3;
  word-break: break-word;
}

.web3-theme .task-title.completed {
  text-decoration: line-through;
  color: rgba(255, 255, 255, 0.4);
}

.web3-theme .task-notes {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 2px;
  line-height: 1.4;
}

.web3-theme .task-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 8px;
  font-size: 0.8rem;
  align-items: center;
}

.web3-theme .task-meta span,
.web3-theme .task-meta a {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: rgba(255, 255, 255, 0.5);
}

.web3-theme .task-meta .meta-priority {
  color: #ff453a;
  font-weight: 500;
}

.web3-theme .task-meta .meta-date {
  color: #ff9f0a;
  font-weight: 500;
}

.web3-theme .task-meta .meta-date.overdue {
  color: #ff453a;
  font-weight: 600;
}

.web3-theme .task-meta .meta-tag {
  background: rgba(34, 211, 238, 0.15);
  color: #22d3ee;
  padding: 3px 10px;
  border-radius: 12px;
  text-decoration: none;
  font-weight: 500;
  transition: background 0.15s;
}

.web3-theme .task-meta .meta-tag:hover {
  background: rgba(34, 211, 238, 0.25);
  color: #22d3ee;
}

.web3-theme .task-meta .meta-assignee {
  color: rgba(255, 255, 255, 0.5);
}

.web3-theme .task-meta .meta-from {
  color: rgba(99, 179, 237, 0.8);
  font-weight: 500;
}

.web3-theme .task-meta .meta-source-gemini {
  color: rgba(167, 139, 250, 0.9);
  font-weight: 500;
}

.web3-theme .task-actions {
  flex-shrink: 0;
  margin-left: 8px;
}

.web3-theme .task-actions .action-btn {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.3);
  padding: 4px;
  cursor: pointer;
  transition: color 0.15s;
}

.web3-theme .task-actions .action-btn:hover {
  color: rgba(255, 255, 255, 0.6);
}

.web3-theme .task-item.completed .task-content {
  opacity: 0.6;
}

/* ═══════════════════════════════════════════════════════════════
   TASK ACCORDION - Expandable Task View
   ═══════════════════════════════════════════════════════════════ */

.web3-theme .task-accordion-list {
  background: transparent;
  padding-bottom: 40px;
}

.web3-theme .task-accordion-list .task-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.web3-theme .task-accordion-item {
  background: rgba(28, 28, 30, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  overflow: hidden;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.web3-theme .task-accordion-item:hover {
  border-color: rgba(255, 255, 255, 0.12);
}

.web3-theme .task-accordion-item.expanded {
  border-color: rgba(34, 211, 238, 0.3);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.web3-theme .task-accordion-item.highlighted {
  border-color: rgba(34, 211, 238, 0.5);
  animation: task-highlight-pulse 2s ease-out;
}

@keyframes task-highlight-pulse {
  0% { box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.4); }
  100% { box-shadow: 0 0 0 0 rgba(34, 211, 238, 0); }
}

.web3-theme .task-accordion-item.completed {
  opacity: 0.7;
}

/* Task Header */
.web3-theme .task-header {
  display: flex;
  align-items: flex-start;
  padding: 14px 16px;
  cursor: pointer;
}

.web3-theme .task-header .task-checkbox-wrapper {
  flex-shrink: 0;
  padding-top: 2px;
}

.web3-theme .task-header .task-content {
  flex: 1;
  min-width: 0;
}

.web3-theme .task-header .task-title {
  font-size: 1rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.95);
  margin-bottom: 2px;
}

.web3-theme .task-header .task-title.completed {
  text-decoration: line-through;
  color: rgba(255, 255, 255, 0.4);
}

.web3-theme .task-header .task-preview-desc {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
  margin: 4px 0;
}

.web3-theme .task-accordion-item.expanded .task-preview-desc {
  display: none;
}

.web3-theme .task-expand-toggle {
  flex-shrink: 0;
  padding: 4px 8px;
  color: rgba(255, 255, 255, 0.4);
  transition: transform 0.2s, color 0.2s;
}

.web3-theme .task-expand-toggle:hover {
  color: rgba(255, 255, 255, 0.7);
}

.web3-theme .task-accordion-item.expanded .task-expand-toggle {
  transform: rotate(180deg);
  color: #22d3ee;
}

/* Task Details Panel */
.web3-theme .task-details {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease-out;
  background: rgba(0, 0, 0, 0.3);
  border-top: 1px solid transparent;
}

.web3-theme .task-accordion-item.expanded .task-details {
  max-height: 2000px;
  border-top-color: rgba(255, 255, 255, 0.08);
}

.web3-theme .task-details-content {
  padding: 16px 20px 20px;
}

.web3-theme .task-details-loading {
  padding: 40px;
  text-align: center;
}

.web3-theme .task-details-error {
  padding: 20px;
  text-align: center;
  color: #ff453a;
}

/* Task Detail Actions */
.web3-theme .task-detail-actions {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.web3-theme .btn-task-action {
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: rgba(255, 255, 255, 0.8);
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 0.85rem;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.web3-theme .btn-task-action:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}

.web3-theme .btn-task-delete {
  color: #ff6b6b;
}

.web3-theme .btn-task-delete:hover {
  background: rgba(255, 107, 107, 0.2);
  color: #ff453a;
}

.web3-theme .btn-task-link:hover {
  background: rgba(34, 211, 238, 0.2);
  color: #22d3ee;
}

/* Task Detail Sections */
.web3-theme .task-detail-section {
  margin-bottom: 20px;
}

.web3-theme .task-detail-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.5);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.web3-theme .task-detail-text {
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* Assignees List */
.web3-theme .task-assignees-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.web3-theme .task-assignee-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 6px;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.85);
}

.web3-theme .task-assignee-item .text-success {
  color: #30d158 !important;
}

.web3-theme .task-assignee-item .text-muted {
  color: rgba(255, 255, 255, 0.3) !important;
}

/* Related Entity Link */
.web3-theme .task-related-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  background: rgba(34, 211, 238, 0.1);
  border-radius: 8px;
  color: #22d3ee;
  text-decoration: none;
  font-size: 0.9rem;
  transition: background 0.15s;
}

.web3-theme .task-related-link:hover {
  background: rgba(34, 211, 238, 0.2);
  color: #22d3ee;
}

/* Subtasks */
.web3-theme .subtask-progress {
  font-weight: 500;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.7rem;
  background: rgba(255, 255, 255, 0.1);
  padding: 2px 8px;
  border-radius: 10px;
}

.web3-theme .subtasks-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 10px;
}

.web3-theme .subtask-empty,
.web3-theme .note-empty {
  color: rgba(255, 255, 255, 0.4);
  font-size: 0.85rem;
  font-style: italic;
  padding: 8px 0;
}

.web3-theme .subtask-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 6px;
  transition: background 0.15s;
}

.web3-theme .subtask-item:hover {
  background: rgba(255, 255, 255, 0.06);
}

.web3-theme .subtask-item.completed {
  opacity: 0.6;
}

.web3-theme .subtask-checkbox {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.3);
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s;
  flex-shrink: 0;
  padding: 0;
  color: transparent;
}

.web3-theme .subtask-checkbox:hover {
  border-color: rgba(255, 255, 255, 0.5);
}

.web3-theme .subtask-checkbox.checked {
  background: #30d158;
  border-color: #30d158;
  color: #fff;
}

.web3-theme .subtask-checkbox.checked i {
  font-size: 0.7rem;
}

.web3-theme .subtask-title {
  flex: 1;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.85);
}

.web3-theme .subtask-item.completed .subtask-title {
  text-decoration: line-through;
  color: rgba(255, 255, 255, 0.5);
}

.web3-theme .btn-subtask-delete {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.3);
  padding: 4px;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.15s, color 0.15s;
}

.web3-theme .subtask-item:hover .btn-subtask-delete {
  opacity: 1;
}

.web3-theme .btn-subtask-delete:hover {
  color: #ff453a;
}

/* Add Subtask Form */
.web3-theme .add-subtask-form {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.web3-theme .subtask-input {
  flex: 1;
  background: rgba(44, 44, 46, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 8px 12px;
  color: #fff;
  font-size: 0.9rem;
}

.web3-theme .subtask-input:focus {
  outline: none;
  border-color: rgba(34, 211, 238, 0.5);
}

.web3-theme .subtask-input::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.web3-theme .btn-add-subtask {
  background: rgba(34, 211, 238, 0.2);
  border: none;
  color: #22d3ee;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.web3-theme .btn-add-subtask:hover {
  background: rgba(34, 211, 238, 0.3);
}

/* Notes */
.web3-theme .task-notes-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 12px;
}

.web3-theme .task-note-item {
  background: rgba(255, 255, 255, 0.03);
  border-radius: 8px;
  padding: 12px;
}

.web3-theme .note-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}

.web3-theme .note-author {
  font-size: 0.8rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.7);
}

.web3-theme .note-time {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.4);
}

.web3-theme .btn-note-delete {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.3);
  padding: 2px 6px;
  cursor: pointer;
  margin-left: auto;
  opacity: 0;
  transition: opacity 0.15s, color 0.15s;
}

.web3-theme .task-note-item:hover .btn-note-delete {
  opacity: 1;
}

.web3-theme .btn-note-delete:hover {
  color: #ff453a;
}

.web3-theme .note-content {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.5;
}

/* Add Note Form */
.web3-theme .add-note-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.web3-theme .note-input {
  background: rgba(44, 44, 46, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 10px 12px;
  color: #fff;
  font-size: 0.9rem;
  resize: vertical;
  min-height: 60px;
}

.web3-theme .note-input:focus {
  outline: none;
  border-color: rgba(34, 211, 238, 0.5);
}

.web3-theme .note-input::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.web3-theme .btn-add-note {
  align-self: flex-end;
  background: rgba(34, 211, 238, 0.2);
  border: none;
  color: #22d3ee;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s;
}

.web3-theme .btn-add-note:hover {
  background: rgba(34, 211, 238, 0.3);
}

/* Task Detail Footer */
/* Task Attribution / Source Section */
.web3-theme .task-attribution {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.web3-theme .task-source-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 500;
}

.web3-theme .task-source-badge.gemini {
  background: rgba(167, 139, 250, 0.12);
  color: rgba(167, 139, 250, 0.95);
}

.web3-theme .task-source-badge.gemini a {
  color: rgba(167, 139, 250, 0.95);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.web3-theme .task-source-badge.gemini a:hover {
  color: #a78bfa;
}

.web3-theme .task-source-badge.assigned {
  background: rgba(99, 179, 237, 0.12);
  color: rgba(99, 179, 237, 0.95);
}

.web3-theme .task-detail-footer {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.4);
}

/* Meta tag indicator (non-clickable in header) */
.web3-theme .meta-tag-indicator {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.8rem;
  color: #22d3ee;
}

/* ═══════════════════════════════════════════════════════════════
   PAGINATION - Web3 Theme
   ═══════════════════════════════════════════════════════════════ */

.web3-theme .pagination .page-link {
  background: rgba(28, 28, 30, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.7);
}

.web3-theme .pagination .page-link:hover {
  background: rgba(28, 28, 30, 0.9);
  border-color: rgba(255, 255, 255, 0.15);
  color: #fff;
}

.web3-theme .pagination .page-item.active .page-link {
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.3), rgba(167, 139, 250, 0.3));
  border-color: rgba(34, 211, 238, 0.5);
  color: #fff;
}

.web3-theme .pagination .page-item.disabled .page-link {
  background: rgba(28, 28, 30, 0.5);
  border-color: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.3);
}

/* ═══════════════════════════════════════════════════════════════
   EMPTY STATE - Common Pattern
   ═══════════════════════════════════════════════════════════════ */

.web3-theme .empty-state-box {
  text-align: center;
  padding: 60px 20px;
}

.web3-theme .empty-state-box i {
  font-size: 4rem;
  color: rgba(255, 255, 255, 0.1);
  margin-bottom: 16px;
  display: block;
}

.web3-theme .empty-state-box p {
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 20px;
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE OVERRIDES - All Pages
   ═══════════════════════════════════════════════════════════════ */

@media (max-width: 768px) {
  /* Profile */
  .web3-theme .profile-card {
    margin-top: -60px;
  }

  .web3-theme .profile-avatar-wrapper {
    width: 64px;
    height: 64px;
  }

  .web3-theme .profile-name {
    font-size: 1.25rem;
  }

  /* Users/Leads/Companies Hero */
  .web3-theme .users-hero,
  .web3-theme .leads-hero,
  .web3-theme .companies-hero {
    height: 140px;
  }

  .web3-theme .users-hero .hero-title,
  .web3-theme .leads-hero .hero-title,
  .web3-theme .companies-hero .hero-title {
    font-size: 1.5rem;
  }

  /* Action Bar */
  .web3-theme .action-bar {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .web3-theme .search-box {
    max-width: none;
  }

  /* Accordion */
  .web3-theme .user-accordion .accordion-button,
  .web3-theme .leads-accordion .accordion-button,
  .web3-theme .company-accordion .accordion-button {
    padding: 12px;
  }

  .web3-theme .user-avatar,
  .web3-theme .lead-avatar,
  .web3-theme .company-avatar {
    width: 38px;
    height: 38px;
  }

  /* Filters */
  .web3-theme .filters-bar {
    flex-direction: column;
    align-items: flex-start;
  }

  .web3-theme .filter-group {
    flex-wrap: wrap;
  }

  /* Edit Form */
  .web3-theme .edit-form .row {
    gap: 8px;
  }
}

/* ═══════════════════════════════════════════════════════════════
   Lead Mention Autocomplete Dropdown
   ═══════════════════════════════════════════════════════════════ */
.lead-mention-dropdown {
  position: absolute;
  z-index: 9999;
  background: #1c1c1e;
  border: 1px solid #48484a;
  border-radius: 10px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  max-height: 240px;
  overflow-y: auto;
  padding: 4px 0;
}

.lead-mention-item {
  display: flex;
  flex-direction: column;
  padding: 10px 14px;
  cursor: pointer;
  transition: background-color 0.15s ease;
}

.lead-mention-item:hover,
.lead-mention-item.selected {
  background: rgba(10, 132, 255, 0.15);
}

.lead-mention-name {
  font-weight: 500;
  color: #f1f5f9;
  font-size: 0.9rem;
}

.lead-mention-email {
  font-size: 0.75rem;
  color: #8e8e93;
  margin-top: 2px;
}

/* Lead mention link in task display */
.lead-mention-link {
  color: #0a84ff;
  text-decoration: none;
  font-weight: 500;
}

.lead-mention-link:hover {
  color: #409cff;
  text-decoration: underline;
}

/* ═══════════════════════════════════════════════════════════════
   Dashboard Hero Section
   ═══════════════════════════════════════════════════════════════ */

/* Hero h1 — large, bold, with subtle text shadow for readability */
.web3-theme .hero-title {
  font-size: 2.5rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: #fff;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.5);
  line-height: 1.15;
}

/* Focus mode hero h1 — slightly smaller but still prominent */
.web3-theme .hero-title-focus {
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #fff;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.5);
  line-height: 1.2;
}

/* Hero subtitle text — bright enough to read over the space background */
.web3-theme .hero-subtitle {
  color: rgba(255, 255, 255, 0.85);
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.4);
}

/* Hero outline button — give it a glass background so it's visible */
.web3-theme .btn-web3-hero {
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #fff;
  border-radius: var(--w3-radius-md);
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

.web3-theme .btn-web3-hero:hover {
  background: rgba(255, 255, 255, 0.22);
  border-color: rgba(255, 255, 255, 0.5);
  color: #fff;
  box-shadow: 0 0 16px rgba(255, 255, 255, 0.1);
}

/* Focus mode toggle label in hero */
.web3-theme .hero-focus-label {
  color: rgba(255, 255, 255, 0.8);
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
}

@media (max-width: 768px) {
  .web3-theme .hero-title {
    font-size: 1.75rem;
  }

  .web3-theme .hero-title-focus {
    font-size: 1.35rem;
  }
}

/* ═══════════════════════════════════════════════════════════════
   Reports Page - Web3 Theme
   ═══════════════════════════════════════════════════════════════ */

/* Page background */
.reports-page-body .content {
  background: radial-gradient(ellipse at 50% 0%, rgba(34, 211, 238, 0.03), transparent 50%), var(--w3-bg-deep) !important;
}

/* Glass card overrides for Bootstrap .card */
.reports-page-body .card {
  background: var(--w3-bg-card) !important;
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--w3-glass-border) !important;
  border-radius: var(--w3-radius-lg) !important;
  color: var(--w3-text-primary);
}

.reports-page-body .card-header {
  background: rgba(255, 255, 255, 0.02) !important;
  border-bottom: 1px solid var(--w3-glass-border) !important;
  color: var(--w3-text-primary) !important;
  border-radius: var(--w3-radius-lg) var(--w3-radius-lg) 0 0 !important;
}

.reports-page-body .card-title {
  color: var(--w3-text-primary) !important;
  font-weight: 600;
}

.reports-page-body .card-footer {
  background: var(--w3-glass) !important;
  border-top: 1px solid var(--w3-glass-border) !important;
  border-radius: 0 0 var(--w3-radius-lg) var(--w3-radius-lg) !important;
}

.reports-page-body .card-body {
  color: var(--w3-text-primary);
}

/* Results card gradient accent */
.reports-page-body .report-results-card {
  position: relative;
  overflow: hidden;
}

.reports-page-body .report-results-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg,
    transparent,
    var(--w3-accent-cyan),
    var(--w3-accent-purple),
    transparent
  );
}

/* Text overrides */
.reports-page-body .text-muted,
.reports-page-body .card .text-muted {
  color: var(--w3-text-secondary) !important;
}

/* Tables */
.reports-page-body .table {
  color: var(--w3-text-primary);
  --bs-table-bg: transparent;
}

.reports-page-body .table-dark,
.reports-page-body .table-dark th {
  background-color: rgba(255, 255, 255, 0.04) !important;
  color: var(--w3-text-primary) !important;
  border-color: var(--w3-glass-border);
}

.reports-page-body .table-light,
.reports-page-body .table-light th {
  background-color: rgba(255, 255, 255, 0.05) !important;
  color: var(--w3-text-primary) !important;
}

.reports-page-body .table-secondary,
.reports-page-body .table-secondary > * {
  --bs-table-bg: rgba(255, 255, 255, 0.06) !important;
  --bs-table-color: var(--w3-text-primary) !important;
  background-color: rgba(255, 255, 255, 0.06) !important;
  color: var(--w3-text-primary) !important;
}

.reports-page-body .table-secondary td {
  color: var(--w3-text-primary) !important;
}

/* Table footers (totals rows) */
.reports-page-body .table tfoot {
  background-color: rgba(255, 255, 255, 0.06);
  color: var(--w3-text-primary);
  border-top: 1px solid var(--w3-glass-border);
}

.reports-page-body .table tfoot td {
  color: var(--w3-text-primary);
  border-color: var(--w3-glass-border);
}

.reports-page-body .table-hover tbody tr:hover {
  background-color: rgba(34, 211, 238, 0.05);
  color: var(--w3-text-primary);
}

.reports-page-body .table td,
.reports-page-body .table th {
  border-color: var(--w3-glass-border);
  padding: 0.75rem;
}

/* Clickable table rows */
.reports-page-body .cursor-pointer { cursor: pointer; }
.reports-page-body .cursor-pointer:hover { background-color: rgba(34, 211, 238, 0.05) !important; }

/* Form controls */
.reports-page-body .form-control,
.reports-page-body .form-select {
  background-color: rgba(0, 0, 0, 0.4);
  color: var(--w3-text-primary);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--w3-radius-sm);
}

.reports-page-body .form-control:focus,
.reports-page-body .form-select:focus {
  background-color: rgba(0, 0, 0, 0.5);
  color: var(--w3-text-primary);
  border-color: var(--w3-accent-cyan);
  box-shadow: 0 0 0 0.2rem rgba(34, 211, 238, 0.15);
}

/* Ledo Search Bar */
.reports-page-body .ledo-search-container,
.reports-page-body .templates-container {
  max-width: 800px;
  margin: 0 auto;
}

.reports-page-body .ledo-search-bar {
  display: flex;
  align-items: center;
  background: var(--w3-bg-card);
  border: 1px solid var(--w3-glass-border);
  border-radius: var(--w3-radius-xl);
  padding: 8px 8px 8px 16px;
  transition: var(--w3-transition-fast);
}

.reports-page-body .ledo-search-bar:focus-within {
  border-color: var(--w3-accent-cyan);
  box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.15);
}

.reports-page-body .ledo-avatar {
  flex-shrink: 0;
  color: var(--w3-accent-cyan);
  margin-right: 12px;
}

.reports-page-body .ledo-search-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--w3-text-primary);
  font-size: 1rem;
  padding: 8px 0;
}

.reports-page-body .ledo-search-input::placeholder {
  color: var(--w3-text-muted);
}

.reports-page-body .ledo-generate-btn {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--w3-accent-cyan), #0099cc);
  border: none;
  color: #fff;
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--w3-transition-fast);
}

.reports-page-body .ledo-generate-btn:hover {
  background: linear-gradient(135deg, #00d4ff, #00aadd);
  box-shadow: 0 0 20px rgba(34, 211, 238, 0.4);
}

.reports-page-body .ledo-generate-btn:active {
  transform: scale(0.95);
}

.reports-page-body .ledo-generate-btn:disabled {
  background: rgba(255, 255, 255, 0.08);
  cursor: not-allowed;
}

.reports-page-body .ledo-generate-btn .spinner-border {
  width: 18px;
  height: 18px;
  border-width: 2px;
}

/* Template buttons */
.reports-page-body .report-template-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 1rem;
  font-size: 0.8125rem;
  font-weight: 500;
  border-radius: 20px;
  border: 1px solid var(--w3-glass-border);
  background: var(--w3-glass);
  color: var(--w3-text-secondary);
  transition: var(--w3-transition-fast);
  cursor: pointer;
}

.reports-page-body .report-template-btn:hover {
  background: var(--w3-glass-highlight);
  border-color: rgba(255, 255, 255, 0.15);
  color: var(--w3-text-primary);
}

.reports-page-body .report-template-btn.saved {
  border-color: rgba(34, 211, 238, 0.3);
  color: var(--w3-accent-cyan);
}

.reports-page-body .report-template-btn.saved:hover {
  background: rgba(34, 211, 238, 0.1);
  border-color: var(--w3-accent-cyan);
}

/* View toggle & date range buttons */
.reports-page-body .btn-outline-secondary {
  background: transparent;
  border-color: var(--w3-glass-border);
  color: var(--w3-text-secondary);
}

.reports-page-body .btn-outline-secondary:hover,
.reports-page-body .btn-outline-secondary.active {
  background: var(--w3-glass-highlight);
  border-color: rgba(255, 255, 255, 0.15);
  color: var(--w3-text-primary);
}

/* Primary action buttons */
.reports-page-body .report-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.75rem;
  font-size: 0.8125rem;
  font-weight: 500;
  border-radius: var(--w3-radius-sm);
  transition: var(--w3-transition-fast);
  cursor: pointer;
  border: 1px solid;
}

.reports-page-body .report-action-btn.export {
  border-color: rgba(34, 211, 238, 0.3);
  color: var(--w3-accent-cyan);
  background: transparent;
}

.reports-page-body .report-action-btn.export:hover {
  background: rgba(34, 211, 238, 0.1);
  border-color: var(--w3-accent-cyan);
}

.reports-page-body .report-action-btn.save {
  border-color: rgba(34, 197, 94, 0.3);
  color: var(--w3-accent-emerald);
  background: transparent;
}

.reports-page-body .report-action-btn.save:hover {
  background: rgba(34, 197, 94, 0.1);
  border-color: var(--w3-accent-emerald);
}

/* Persistent report export buttons */
.reports-page-body .report-export-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.375rem 0.5rem;
  font-size: 0.8125rem;
  border-radius: var(--w3-radius-sm);
  border: 1px solid var(--w3-glass-border);
  background: transparent;
  color: var(--w3-text-secondary);
  transition: var(--w3-transition-fast);
  cursor: pointer;
}

.reports-page-body .report-export-btn:hover {
  background: var(--w3-glass-highlight);
  border-color: rgba(255, 255, 255, 0.15);
  color: var(--w3-text-primary);
}

/* Date range selector */
.reports-page-body .date-range-selector {
  border-color: var(--w3-glass-border) !important;
}

.reports-page-body .date-range-selector .form-control {
  max-width: 140px;
}

/* Report view toggle */
.reports-page-body .report-view-toggle .btn {
  background: transparent;
  border-color: var(--w3-glass-border);
  color: var(--w3-text-secondary);
}

.reports-page-body .report-view-toggle .btn:hover,
.reports-page-body .report-view-toggle .btn.active {
  background: var(--w3-glass-highlight);
  color: var(--w3-accent-cyan);
  border-color: rgba(34, 211, 238, 0.3);
}

.reports-page-body .report-view-toggle .btn.btn-primary {
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.2), rgba(167, 139, 250, 0.2));
  border-color: rgba(34, 211, 238, 0.3);
  color: var(--w3-accent-cyan);
}

/* Date preset buttons */
.reports-page-body .date-preset {
  background: transparent;
  border-color: var(--w3-glass-border);
  color: var(--w3-text-secondary);
}

.reports-page-body .date-preset:hover {
  background: var(--w3-glass-highlight);
  color: var(--w3-text-primary);
}

.reports-page-body .date-preset.active {
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.2), rgba(167, 139, 250, 0.2));
  border-color: rgba(34, 211, 238, 0.3);
  color: var(--w3-accent-cyan);
}

/* Error card */
.reports-page-body .report-error-card {
  border: 1px solid rgba(239, 68, 68, 0.3) !important;
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.05), var(--w3-bg-card)) !important;
}

/* Modal */
.reports-page-body .modal-content {
  background-color: #1c1c1e;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--w3-radius-lg);
  color: var(--w3-text-primary);
}

.reports-page-body .modal-header {
  border-bottom: 1px solid var(--w3-glass-border);
}

.reports-page-body .modal-footer {
  border-top: 1px solid var(--w3-glass-border);
}

.reports-page-body .modal-content .form-control {
  background-color: rgba(0, 0, 0, 0.4);
  color: var(--w3-text-primary);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.reports-page-body .modal-content .form-label {
  color: var(--w3-text-secondary);
}

/* Section headers */
.reports-page-body .report-section-title {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--w3-text-muted);
}

/* KPI-style metric display */
.reports-page-body .metric-highlight {
  font-size: 2rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--w3-accent-cyan), var(--w3-accent-purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Badges */
.reports-page-body .badge {
  font-weight: 500;
  padding: 0.4em 0.8em;
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .reports-page-body .ledo-search-bar {
    padding: 6px 6px 6px 12px;
  }

  .reports-page-body .ledo-avatar {
    margin-right: 8px;
  }

  .reports-page-body .ledo-avatar svg {
    width: 24px;
    height: 24px;
  }

  .reports-page-body .ledo-search-input {
    font-size: 0.95rem;
    padding: 6px 0;
  }

  .reports-page-body .ledo-generate-btn {
    width: 36px;
    height: 36px;
    font-size: 1rem;
  }

  #templatesSection .d-flex.justify-content-between {
    flex-direction: column;
    gap: 12px;
  }

  .reports-page-body #templateButtons {
    overflow-x: auto;
    flex-wrap: nowrap !important;
    padding-bottom: 8px;
    -webkit-overflow-scrolling: touch;
  }

  .reports-page-body #templateButtons .btn,
  .reports-page-body #templateButtons .report-template-btn {
    flex-shrink: 0;
    white-space: nowrap;
  }

  .reports-page-body .card-header .d-flex.gap-2 {
    flex-wrap: wrap;
  }

  .reports-page-body .date-range-selector > .d-flex {
    flex-direction: column;
    align-items: flex-start !important;
  }

  .reports-page-body .date-range-selector .btn-group {
    overflow-x: auto;
    max-width: 100%;
    flex-wrap: nowrap;
  }

  .reports-page-body .date-range-selector .btn-group .btn {
    flex-shrink: 0;
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
  }

  .reports-page-body .date-range-selector .ms-auto {
    margin-left: 0 !important;
    margin-top: 8px;
    width: 100%;
  }

  .reports-page-body .date-range-selector .form-control {
    flex: 1;
    max-width: none;
  }

  .reports-page-body #chartContainer {
    height: 300px !important;
  }

  .reports-page-body .content h1.h3 {
    font-size: 1.5rem;
  }
}

@media (max-width: 576px) {
  .reports-page-body .ledo-search-input::placeholder {
    font-size: 0.9rem;
  }

  .reports-page-body #templateButtons .btn,
  .reports-page-body #templateButtons .report-template-btn {
    font-size: 0.85rem;
    padding: 0.35rem 0.65rem;
  }

  .reports-page-body .card-header {
    flex-direction: column;
    align-items: flex-start !important;
    gap: 12px;
  }

  .reports-page-body .card-header > div:last-child {
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
  }

  .reports-page-body .card-header .btn {
    flex: 1;
    min-width: 80px;
  }

  .reports-page-body #chartContainer {
    height: 250px !important;
  }
}

/* =============================================
   DEALS PAGE
   ============================================= */

/* --- Deals Tabs --- */
.deals-page-body .deals-tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid var(--w3-glass-border);
  margin-bottom: 1.25rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.deals-page-body .deals-tabs .deals-tab-link {
  position: relative;
  padding: 0.875rem 1.25rem;
  color: var(--w3-text-muted);
  font-weight: 500;
  font-size: 0.875rem;
  border: none;
  background: transparent;
  cursor: pointer;
  transition: var(--w3-transition-fast);
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.deals-page-body .deals-tabs .deals-tab-link:hover {
  color: var(--w3-text-secondary);
}

.deals-page-body .deals-tabs .deals-tab-link.active {
  color: var(--w3-accent-cyan);
}

.deals-page-body .deals-tabs .deals-tab-link.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 1rem;
  right: 1rem;
  height: 2px;
  background: linear-gradient(90deg, var(--w3-accent-cyan), var(--w3-accent-purple));
  border-radius: 1px;
}

.deals-page-body .deals-tab-content {
  display: none;
}

.deals-page-body .deals-tab-content.active {
  display: block;
}

/* --- Board Tab: Pipeline Header --- */
.deals-page-body .deals-board-wrapper {
  display: flex;
  flex-direction: column;
  height: calc(100vh - 220px);
  overflow: hidden;
}

.deals-page-body .pipeline-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 0 1rem;
  flex-wrap: wrap;
  gap: 1rem;
  border-bottom: 1px solid var(--w3-glass-border);
  margin-bottom: 1rem;
}

.deals-page-body .pipeline-select-wrapper {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.deals-page-body .pipeline-select {
  background: var(--w3-glass);
  border: 1px solid var(--w3-glass-border);
  border-radius: var(--w3-radius-sm);
  padding: 0.4rem 0.75rem;
  color: var(--w3-text-primary);
  font-size: 0.85rem;
  font-weight: 500;
  min-width: 140px;
}

.deals-page-body .pipeline-stats {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.deals-page-body .pipeline-stats .ps-stat {
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.6rem;
  background: var(--w3-glass);
  border-radius: 6px;
  white-space: nowrap;
  gap: 0.4rem;
}

.deals-page-body .pipeline-stats .ps-label {
  font-size: 0.7rem;
  color: var(--w3-text-muted);
}

.deals-page-body .pipeline-stats .ps-value {
  font-size: 0.8rem;
  color: var(--w3-text-primary);
  font-weight: 600;
}

/* --- Board Tab: Kanban Board --- */
.deals-page-body .board-container {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  overflow-y: hidden;
  flex: 1;
  padding-bottom: 1rem;
  -webkit-overflow-scrolling: touch;
}

.deals-page-body .stage-column {
  min-width: 300px;
  max-width: 320px;
  flex: 0 0 300px;
  display: flex;
  flex-direction: column;
  background: var(--stage-bg, rgba(255,255,255,0.02));
  border-radius: var(--w3-radius-md);
  border: 1px solid var(--stage-border, var(--w3-glass-border));
  transition: var(--w3-transition-fast);
}

.deals-page-body .stage-column:hover {
  border-color: var(--stage-border-hover, rgba(255,255,255,0.1));
}

.deals-page-body .stage-header {
  padding: 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--stage-border, var(--w3-glass-border));
  background: var(--stage-header-bg, transparent);
  border-radius: var(--w3-radius-md) var(--w3-radius-md) 0 0;
}

.deals-page-body .stage-header-left {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.deals-page-body .stage-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.deals-page-body .stage-name {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--w3-text-primary);
}

.deals-page-body .stage-count {
  font-size: 0.75rem;
  color: var(--w3-text-secondary);
  background: var(--stage-border, rgba(255,255,255,0.1));
  padding: 2px 8px;
  border-radius: 10px;
}

.deals-page-body .stage-value {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--w3-text-secondary);
}

.deals-page-body .stage-deals {
  flex: 1;
  overflow-y: auto;
  padding: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  min-height: 100px;
}

.deals-page-body .stage-deals.drag-over {
  background: rgba(99, 102, 241, 0.1);
  border-radius: var(--w3-radius-sm);
}

/* --- Board Tab: Deal Card --- */
.deals-page-body .deal-card {
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--w3-glass-border);
  border-radius: 10px;
  padding: 0.875rem;
  cursor: grab;
  transition: var(--w3-transition-fast);
  backdrop-filter: blur(4px);
}

.deals-page-body .deal-card:hover {
  background: rgba(0, 0, 0, 0.4);
  border-color: rgba(255,255,255,0.2);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.deals-page-body .deal-card.dragging {
  opacity: 0.5;
  transform: scale(0.98);
}

.deals-page-body .deal-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 0.5rem;
}

.deals-page-body .deal-name {
  font-weight: 500;
  font-size: 0.9rem;
  color: var(--w3-text-primary);
  cursor: pointer;
}

.deals-page-body .deal-name:hover {
  color: var(--w3-accent-cyan);
}

.deals-page-body .deal-value {
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--w3-accent-emerald);
}

.deals-page-body .deal-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.75rem;
  color: var(--w3-text-muted);
}

.deals-page-body .deal-contact {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.deals-page-body .deal-days {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.deals-page-body .deal-days.stale {
  color: #f59e0b;
}

.deals-page-body .deal-owner {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(99,102,241,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  font-weight: 600;
  color: var(--w3-text-primary);
  margin-left: auto;
}

.deals-page-body .deal-owner img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}

/* Mobile Move Button */
.deals-page-body .deal-move-btn {
  display: none;
  background: rgba(99, 102, 241, 0.2);
  border: 1px solid rgba(99, 102, 241, 0.3);
  border-radius: 6px;
  color: #a5b4fc;
  font-size: 0.7rem;
  padding: 4px 8px;
  cursor: pointer;
  margin-left: auto;
  white-space: nowrap;
}

.deals-page-body .deal-move-btn:hover,
.deals-page-body .deal-move-btn:active {
  background: rgba(99, 102, 241, 0.35);
  color: var(--w3-text-primary);
}

@media (pointer: coarse) {
  .deals-page-body .deal-move-btn {
    display: flex;
    align-items: center;
    gap: 4px;
  }
  .deals-page-body .deal-card {
    cursor: pointer;
  }
  .deals-page-body .deal-owner {
    margin-left: 0;
  }
}

/* Mobile Stage Selector Popup */
.deals-page-body .stage-selector-popup {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(28, 28, 30, 0.98);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid var(--w3-glass-border);
  border-radius: 20px 20px 0 0;
  padding: 1rem;
  z-index: 10000;
  transform: translateY(100%);
  transition: transform 0.3s ease;
}

.deals-page-body .stage-selector-popup.show {
  transform: translateY(0);
}

.deals-page-body .stage-selector-popup .popup-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--w3-glass-border);
}

.deals-page-body .stage-selector-popup .popup-title {
  font-weight: 600;
  color: var(--w3-text-primary);
  font-size: 1rem;
}

.deals-page-body .stage-selector-popup .popup-close {
  background: transparent;
  border: none;
  color: var(--w3-text-muted);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0;
  line-height: 1;
}

.deals-page-body .stage-selector-popup .stage-option {
  display: flex;
  align-items: center;
  padding: 0.875rem 1rem;
  background: var(--w3-glass);
  border: 1px solid var(--w3-glass-border);
  border-radius: 10px;
  margin-bottom: 0.5rem;
  cursor: pointer;
  transition: var(--w3-transition-fast);
}

.deals-page-body .stage-selector-popup .stage-option:hover,
.deals-page-body .stage-selector-popup .stage-option:active {
  background: rgba(99, 102, 241, 0.15);
  border-color: rgba(99, 102, 241, 0.3);
}

.deals-page-body .stage-selector-popup .stage-option.current {
  background: rgba(99, 102, 241, 0.2);
  border-color: rgba(99, 102, 241, 0.4);
}

.deals-page-body .stage-selector-popup .stage-option .stage-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 0.75rem;
}

.deals-page-body .stage-selector-popup .stage-option .stage-name {
  flex: 1;
  color: var(--w3-text-primary);
  font-weight: 500;
}

.deals-page-body .stage-selector-popup .stage-option .stage-prob {
  color: var(--w3-text-muted);
  font-size: 0.8rem;
}

.deals-page-body .stage-selector-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 9999;
  opacity: 0;
  visibility: hidden;
  transition: var(--w3-transition);
}

.deals-page-body .stage-selector-backdrop.show {
  opacity: 1;
  visibility: visible;
}

/* --- Pipelines Tab: Pipeline Cards --- */
.deals-page-body .pipeline-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
  padding: 1rem 0;
}

.deals-page-body .pipeline-card {
  background: var(--w3-glass);
  border: 1px solid var(--w3-glass-border);
  border-radius: var(--w3-radius-lg);
  padding: 1.5rem;
  cursor: pointer;
  transition: var(--w3-transition);
  position: relative;
  overflow: hidden;
}

.deals-page-body .pipeline-card:hover {
  background: var(--w3-bg-card-hover);
  border-color: rgba(99,102,241,0.4);
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}

.deals-page-body .pipeline-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.deals-page-body .pipeline-card-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.deals-page-body .pipeline-card-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  flex-shrink: 0;
}

.deals-page-body .pipeline-card-name {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--w3-text-primary);
  margin: 0;
}

.deals-page-body .pipeline-card-badge {
  font-size: 0.65rem;
  padding: 3px 8px;
  border-radius: 6px;
  background: rgba(99,102,241,0.2);
  color: #818cf8;
}

.deals-page-body .pipeline-card-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.deals-page-body .pipeline-stat {
  text-align: center;
  padding: 0.75rem;
  background: var(--w3-glass);
  border-radius: var(--w3-radius-sm);
}

.deals-page-body .pipeline-stat-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--w3-text-primary);
  line-height: 1.2;
}

.deals-page-body .pipeline-stat-label {
  font-size: 0.75rem;
  color: var(--w3-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.deals-page-body .pipeline-card-stages {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.deals-page-body .pipeline-stage-chip {
  font-size: 0.75rem;
  padding: 4px 10px;
  border-radius: 12px;
  background: var(--w3-glass);
  color: var(--w3-text-secondary);
  border: 1px solid var(--w3-glass-border);
}

.deals-page-body .pipeline-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--w3-glass-border);
}

.deals-page-body .pipeline-card-action {
  font-size: 0.85rem;
  color: #818cf8;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* New Pipeline Card */
.deals-page-body .pipeline-card-new {
  background: rgba(99,102,241,0.05);
  border: 2px dashed rgba(99,102,241,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 220px;
}

.deals-page-body .pipeline-card-new:hover {
  background: rgba(99,102,241,0.1);
  border-color: rgba(99,102,241,0.5);
}

.deals-page-body .pipeline-card-new-content {
  text-align: center;
  color: var(--w3-text-secondary);
}

.deals-page-body .pipeline-card-new-content i {
  font-size: 2.5rem;
  color: #818cf8;
  margin-bottom: 0.75rem;
  display: block;
}

.deals-page-body .pipeline-card-new-content h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--w3-text-primary);
  margin-bottom: 0.5rem;
}

.deals-page-body .pipeline-card-new-content p {
  font-size: 0.85rem;
  color: var(--w3-text-muted);
  margin: 0;
}

/* Empty state */
.deals-page-body .empty-pipeline-state {
  text-align: center;
  padding: 3rem;
  color: var(--w3-text-muted);
}

.deals-page-body .empty-pipeline-state > i {
  font-size: 3rem;
  margin-bottom: 1rem;
  opacity: 0.5;
  display: block;
}

/* --- Deal Panel --- */
.deals-page-body .deal-panel-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 1050;
  opacity: 0;
  visibility: hidden;
  transition: var(--w3-transition);
}

.deals-page-body .deal-panel-backdrop.show {
  opacity: 1;
  visibility: visible;
}

body.panel-open {
  overflow: hidden;
}

.deals-page-body .deal-panel {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  max-width: 540px;
  background: #1c1c1e;
  z-index: 1051;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: -4px 0 24px rgba(0, 0, 0, 0.3);
}

.deals-page-body .deal-panel.show {
  transform: translateX(0);
}

.deals-page-body .deal-panel form {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

.deals-page-body .deal-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid #2c2c2e;
  flex-shrink: 0;
}

.deals-page-body .deal-panel-title {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--w3-text-primary);
  font-weight: 600;
  font-size: 1.25rem;
  margin: 0;
}

.deals-page-body .deal-panel-title i {
  color: var(--w3-accent-cyan);
}

.deals-page-body .deal-panel-close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: #2c2c2e;
  color: #8e8e93;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--w3-transition-fast);
}

.deals-page-body .deal-panel-close:hover {
  background: #3a3a3c;
  color: var(--w3-text-primary);
}

/* Deal Panel Tabs */
.deals-page-body .deal-panel-tabs {
  display: flex;
  gap: 0;
  padding: 0 24px;
  border-bottom: 1px solid #2c2c2e;
  flex-shrink: 0;
  overflow-x: auto;
}

.deals-page-body .deal-panel-tabs .tab-btn {
  padding: 12px 16px;
  background: transparent;
  border: none;
  color: var(--w3-text-muted);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  transition: var(--w3-transition-fast);
}

.deals-page-body .deal-panel-tabs .tab-btn:hover {
  color: var(--w3-text-secondary);
}

.deals-page-body .deal-panel-tabs .tab-btn.active {
  color: var(--w3-text-primary);
  border-bottom-color: var(--w3-accent-cyan);
}

.deals-page-body .deal-panel-tabs .tab-count {
  font-size: 0.7rem;
  background: var(--w3-glass);
  padding: 2px 8px;
  border-radius: 10px;
}

/* Deal Panel Body */
.deals-page-body .deal-panel-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 24px;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}

.deals-page-body .deal-panel-body::-webkit-scrollbar {
  width: 6px;
}

.deals-page-body .deal-panel-body::-webkit-scrollbar-track {
  background: transparent;
}

.deals-page-body .deal-panel-body::-webkit-scrollbar-thumb {
  background: #48484a;
  border-radius: 3px;
}

/* Deal Panel Sections */
.deals-page-body .deal-section {
  margin-bottom: 28px;
}

.deals-page-body .deal-section:last-child {
  margin-bottom: 0;
}

.deals-page-body .deal-section-title {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--w3-accent-cyan);
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 1px solid #2c2c2e;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.deals-page-body .section-count {
  font-size: 0.7rem;
  background: var(--w3-accent-cyan-soft);
  color: var(--w3-accent-cyan);
  padding: 2px 10px;
  border-radius: 10px;
  font-weight: 500;
}

/* Add URL Row */
.deals-page-body .add-url-row {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
  align-items: center;
}

.deals-page-body .add-url-row input {
  flex: 1;
  padding: 10px 14px;
  font-size: 0.85rem;
  color: var(--w3-text-primary);
  background: rgba(44, 44, 46, 0.8);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--w3-glass-border);
  border-radius: 10px;
  transition: var(--w3-transition-fast);
}

.deals-page-body .add-url-row input:first-child {
  flex: 2;
}

.deals-page-body .add-url-row input::placeholder {
  color: rgba(255, 255, 255, 0.35);
}

.deals-page-body .add-url-row input:hover {
  border-color: rgba(255, 255, 255, 0.15);
  background: rgba(58, 58, 60, 0.9);
}

.deals-page-body .add-url-row input:focus {
  outline: none;
  border-color: var(--w3-accent-cyan);
  box-shadow: 0 0 0 3px var(--w3-accent-cyan-soft);
}

.deals-page-body .btn-add {
  padding: 10px 14px;
  background: var(--w3-accent-cyan-soft);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(34, 211, 238, 0.3);
  border-radius: 10px;
  color: var(--w3-accent-cyan);
  cursor: pointer;
  transition: var(--w3-transition-fast);
  height: 40px;
  min-width: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.deals-page-body .btn-add:hover {
  background: rgba(34, 211, 238, 0.25);
  border-color: rgba(34, 211, 238, 0.5);
  transform: translateY(-1px);
}

.deals-page-body .btn-add i {
  font-size: 1rem;
}

/* Upload Area */
.deals-page-body .upload-area {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  border: 2px dashed rgba(255, 255, 255, 0.12);
  border-radius: var(--w3-radius-md);
  background: rgba(44, 44, 46, 0.4);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  cursor: pointer;
  transition: var(--w3-transition-fast);
  margin-bottom: 12px;
  text-align: center;
}

.deals-page-body .upload-area:hover {
  border-color: rgba(34, 211, 238, 0.5);
  background: rgba(34, 211, 238, 0.08);
}

.deals-page-body .upload-area i {
  font-size: 2rem;
  color: var(--w3-text-muted);
  margin-bottom: 8px;
  transition: color 0.2s ease;
}

.deals-page-body .upload-area:hover i {
  color: var(--w3-accent-cyan);
}

.deals-page-body .upload-area span {
  color: var(--w3-text-secondary);
  font-size: 0.875rem;
}

.deals-page-body .upload-area small {
  color: var(--w3-text-muted);
  font-size: 0.75rem;
  margin-top: 4px;
}

/* Deal Panel Form Fields */
.deals-page-body .deal-panel .form-group {
  margin-bottom: 18px;
}

.deals-page-body .deal-panel .form-group:last-child {
  margin-bottom: 0;
}

.deals-page-body .deal-panel .form-group label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #a0a0a5;
  margin-bottom: 8px;
}

.deals-page-body .deal-panel .form-group input,
.deals-page-body .deal-panel .form-group select,
.deals-page-body .deal-panel .form-group textarea {
  width: 100%;
  padding: 12px 16px;
  font-size: 0.9375rem;
  color: var(--w3-text-primary);
  background: #2c2c2e;
  border: 1px solid #48484a;
  border-radius: 10px;
  transition: var(--w3-transition-fast);
}

.deals-page-body .deal-panel .form-group input:focus,
.deals-page-body .deal-panel .form-group select:focus,
.deals-page-body .deal-panel .form-group textarea:focus {
  outline: none;
  border-color: var(--w3-accent-cyan);
  box-shadow: 0 0 0 3px var(--w3-accent-cyan-soft);
}

.deals-page-body .deal-panel .form-group input::placeholder,
.deals-page-body .deal-panel .form-group textarea::placeholder {
  color: #636366;
}

.deals-page-body .deal-panel .form-group textarea {
  min-height: 80px;
  resize: vertical;
}

.deals-page-body .deal-panel .form-row {
  display: flex;
  gap: 16px;
}

.deals-page-body .deal-panel .form-row .form-group {
  flex: 1;
}

/* Deal Panel Footer */
.deals-page-body .deal-panel-footer {
  display: flex;
  gap: 12px;
  padding: 20px 24px;
  border-top: 1px solid #2c2c2e;
  background: #1c1c1e;
  flex-shrink: 0;
}

.deals-page-body .deal-panel-footer button {
  flex: 1;
  padding: 14px 24px;
  font-size: 0.9375rem;
  font-weight: 600;
  border-radius: 10px;
  cursor: pointer;
  transition: var(--w3-transition-fast);
}

.deals-page-body .deal-panel-footer .btn-cancel {
  background: transparent;
  border: 1px solid #48484a;
  color: #a0a0a5;
}

.deals-page-body .deal-panel-footer .btn-cancel:hover {
  background: #2c2c2e;
  color: var(--w3-text-primary);
}

.deals-page-body .deal-panel-footer .btn-save {
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  border: none;
  color: var(--w3-text-primary);
}

.deals-page-body .deal-panel-footer .btn-save:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

/* Tab Content (inside deal panel) */
.deals-page-body .tab-content {
  display: none;
}

.deals-page-body .tab-content.active {
  display: block;
}

/* Linked Items List */
.deals-page-body .linked-items-list {
  margin-top: 12px;
}

.deals-page-body .linked-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background: rgba(44, 44, 46, 0.6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 10px;
  margin-bottom: 0.5rem;
  border: 1px solid var(--w3-glass-border);
  transition: var(--w3-transition-fast);
}

.deals-page-body .linked-item:hover {
  background: rgba(58, 58, 60, 0.7);
  border-color: rgba(255, 255, 255, 0.1);
}

.deals-page-body .linked-item-info {
  flex: 1;
  min-width: 0;
}

.deals-page-body .linked-item-name {
  font-weight: 500;
  color: var(--w3-text-primary);
  margin-bottom: 0.15rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.deals-page-body .linked-item-meta {
  font-size: 0.75rem;
  color: var(--w3-text-muted);
}

.deals-page-body .linked-item-role {
  font-size: 0.7rem;
  background: rgba(99, 102, 241, 0.2);
  color: #a5b4fc;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  margin-left: 0.5rem;
}

.deals-page-body .linked-item-remove {
  background: transparent;
  border: none;
  color: rgba(255,255,255,0.3);
  font-size: 1.2rem;
  cursor: pointer;
  padding: 0.25rem 0.5rem;
  margin-left: 0.5rem;
}

.deals-page-body .linked-item-remove:hover {
  color: #ef4444;
}

.deals-page-body .linked-items-list .empty-state {
  color: rgba(255, 255, 255, 0.35);
  font-size: 0.85rem;
  text-align: center;
  padding: 24px 16px;
  background: rgba(44, 44, 46, 0.4);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 10px;
  border: 1px dashed var(--w3-glass-border);
}

/* Add Item Form */
.deals-page-body .add-item-form {
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--w3-glass-border);
}

.deals-page-body .add-item-row {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  margin-bottom: 1rem;
}

.deals-page-body .add-item-select {
  padding: 10px 14px;
  background: rgba(44, 44, 46, 0.8);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--w3-glass-border);
  border-radius: 10px;
  color: var(--w3-text-primary);
  font-size: 0.85rem;
  transition: var(--w3-transition-fast);
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23888' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 32px;
  cursor: pointer;
}

.deals-page-body .add-item-select:hover {
  border-color: rgba(255, 255, 255, 0.15);
  background-color: rgba(58, 58, 60, 0.9);
}

.deals-page-body .add-item-select:focus {
  outline: none;
  border-color: var(--w3-accent-cyan);
  box-shadow: 0 0 0 3px var(--w3-accent-cyan-soft);
}

.deals-page-body .add-item-select option {
  background: #2c2c2e;
  color: var(--w3-text-primary);
  padding: 8px;
}

.deals-page-body .btn-add-item {
  padding: 0.5rem 1rem;
  background: rgba(99, 102, 241, 0.2);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(99, 102, 241, 0.3);
  border-radius: 10px;
  color: #a5b4fc;
  cursor: pointer;
  font-size: 0.85rem;
  white-space: nowrap;
  height: 40px;
  min-width: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--w3-transition-fast);
}

.deals-page-body .btn-add-item:hover {
  background: rgba(99, 102, 241, 0.3);
  border-color: rgba(99, 102, 241, 0.5);
  transform: translateY(-1px);
}

.deals-page-body .btn-add-item i {
  font-size: 1rem;
}

.deals-page-body .help-text {
  font-size: 0.75rem;
  color: var(--w3-text-muted);
  margin-top: 0.5rem;
}

/* URL Link Styling */
.deals-page-body .linked-item-url {
  color: #6366f1;
  text-decoration: none;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.deals-page-body .linked-item-url:hover {
  text-decoration: underline;
}

/* Document Icons */
.deals-page-body .doc-icon {
  width: 32px;
  height: 32px;
  background: var(--w3-glass);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 0.75rem;
  font-size: 0.7rem;
  color: var(--w3-text-secondary);
  font-weight: 600;
}

.deals-page-body .btn-cancel {
  padding: 0.5rem 1rem;
  background: transparent;
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: var(--w3-radius-sm);
  color: var(--w3-text-secondary);
  cursor: pointer;
}

.deals-page-body .btn-cancel:hover {
  background: var(--w3-glass);
}

.deals-page-body .btn-save {
  padding: 0.5rem 1.25rem;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  border: none;
  border-radius: var(--w3-radius-sm);
  color: var(--w3-text-primary);
  font-weight: 500;
  cursor: pointer;
}

.deals-page-body .btn-save:hover {
  filter: brightness(1.1);
}

/* Lead Search */
.deals-page-body .lead-search-wrapper {
  position: relative;
}

.deals-page-body .lead-search-wrapper input {
  width: 100%;
  padding: 12px 16px;
  background: rgba(44, 44, 46, 0.8);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--w3-glass-border);
  border-radius: 10px;
  color: var(--w3-text-primary);
  font-size: 0.9rem;
  transition: var(--w3-transition-fast);
}

.deals-page-body .lead-search-wrapper input:hover {
  border-color: rgba(255, 255, 255, 0.15);
  background: rgba(58, 58, 60, 0.9);
}

.deals-page-body .lead-search-wrapper input:focus {
  outline: none;
  border-color: var(--w3-accent-cyan);
  box-shadow: 0 0 0 3px var(--w3-accent-cyan-soft);
}

.deals-page-body .lead-search-wrapper input::placeholder {
  color: rgba(255, 255, 255, 0.35);
}

.deals-page-body .lead-search-results {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: rgba(44, 44, 46, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--w3-glass-border);
  border-radius: 10px;
  max-height: 220px;
  overflow-y: auto;
  z-index: 100;
  display: none;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255, 255, 255, 0.05);
}

.deals-page-body .lead-search-results.show {
  display: block;
}

.deals-page-body .lead-search-item {
  padding: 12px 14px;
  cursor: pointer;
  border-bottom: 1px solid var(--w3-glass-border);
  transition: var(--w3-transition-fast);
}

.deals-page-body .lead-search-item:hover {
  background: rgba(34, 211, 238, 0.12);
}

.deals-page-body .lead-search-item:last-child {
  border-bottom: none;
}

.deals-page-body .lead-search-item .lead-name {
  font-weight: 500;
  color: var(--w3-text-primary);
  font-size: 0.85rem;
}

.deals-page-body .lead-search-item .lead-detail {
  font-size: 0.75rem;
  color: var(--w3-text-muted);
}

.deals-page-body .selected-lead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 0.75rem;
  background: rgba(99, 102, 241, 0.12);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(99, 102, 241, 0.25);
  border-radius: var(--w3-radius-sm);
  margin-top: 0.5rem;
  transition: var(--w3-transition-fast);
}

.deals-page-body .selected-lead:hover {
  background: rgba(99, 102, 241, 0.18);
  border-color: rgba(99, 102, 241, 0.35);
}

.deals-page-body .selected-lead span {
  color: var(--w3-text-primary);
  font-size: 0.85rem;
}

.deals-page-body .clear-lead-btn {
  background: none;
  border: none;
  color: var(--w3-text-muted);
  font-size: 1.2rem;
  cursor: pointer;
  padding: 0 0.25rem;
  line-height: 1;
}

.deals-page-body .clear-lead-btn:hover {
  color: #ef4444;
}

/* Meeting Search */
.deals-page-body .meeting-search-wrapper {
  position: relative;
}

.deals-page-body .meeting-search-wrapper input {
  width: 100%;
  padding: 12px 16px;
  background: rgba(44, 44, 46, 0.8);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--w3-glass-border);
  border-radius: 10px;
  color: var(--w3-text-primary);
  font-size: 0.9rem;
  transition: var(--w3-transition-fast);
}

.deals-page-body .meeting-search-wrapper input:hover {
  border-color: rgba(255, 255, 255, 0.15);
  background: rgba(58, 58, 60, 0.9);
}

.deals-page-body .meeting-search-wrapper input:focus {
  outline: none;
  border-color: var(--w3-accent-purple);
  box-shadow: 0 0 0 3px var(--w3-accent-purple-soft);
}

.deals-page-body .meeting-search-wrapper input::placeholder {
  color: rgba(255, 255, 255, 0.35);
}

.deals-page-body .meeting-search-results {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: rgba(44, 44, 46, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--w3-glass-border);
  border-radius: 10px;
  max-height: 280px;
  overflow-y: auto;
  z-index: 100;
  display: none;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255, 255, 255, 0.05);
}

.deals-page-body .meeting-search-results.show {
  display: block;
}

.deals-page-body .meeting-search-item {
  padding: 12px 14px;
  cursor: pointer;
  border-bottom: 1px solid var(--w3-glass-border);
  transition: var(--w3-transition-fast);
}

.deals-page-body .meeting-search-item:hover {
  background: rgba(167, 139, 250, 0.12);
}

.deals-page-body .meeting-search-item:last-child {
  border-bottom: none;
}

.deals-page-body .meeting-search-item .meeting-title {
  font-weight: 500;
  color: var(--w3-text-primary);
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  gap: 6px;
}

.deals-page-body .meeting-search-item .meeting-title i {
  color: var(--w3-accent-purple);
  font-size: 0.8rem;
}

.deals-page-body .meeting-search-item .meeting-meta {
  font-size: 0.75rem;
  color: var(--w3-text-muted);
  margin-top: 2px;
}

.deals-page-body .meeting-search-item .meeting-meta.past {
  color: rgba(255,255,255,0.35);
}

.deals-page-body .meeting-search-item .meeting-type-badge {
  display: inline-block;
  font-size: 0.65rem;
  padding: 2px 6px;
  border-radius: 4px;
  background: var(--w3-accent-purple-soft);
  color: var(--w3-accent-purple);
  margin-left: 8px;
}

.deals-page-body .meeting-type-btn {
  padding: 6px 12px;
  font-size: 0.75rem;
  background: var(--w3-accent-purple-soft);
  border: 1px solid rgba(167, 139, 250, 0.3);
  border-radius: 6px;
  color: var(--w3-accent-purple);
  cursor: pointer;
  transition: var(--w3-transition-fast);
}

.deals-page-body .meeting-type-btn:hover {
  background: rgba(167, 139, 250, 0.3);
  border-color: rgba(167, 139, 250, 0.5);
  color: var(--w3-text-primary);
}

/* --- List Tab: Filter Bar --- */
.deals-page-body .deals-list-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  background: var(--w3-bg-card);
  border: 1px solid var(--w3-glass-border);
  border-radius: var(--w3-radius-md);
  margin-bottom: 1rem;
  align-items: center;
}

.deals-page-body .deals-list-filters select,
.deals-page-body .deals-list-filters input[type="text"] {
  padding: 0.5rem 0.75rem;
  background: var(--w3-glass);
  border: 1px solid var(--w3-glass-border);
  border-radius: var(--w3-radius-sm);
  color: var(--w3-text-primary);
  font-size: 0.8125rem;
  transition: var(--w3-transition-fast);
  min-width: 140px;
}

.deals-page-body .deals-list-filters select:focus,
.deals-page-body .deals-list-filters input[type="text"]:focus {
  outline: none;
  border-color: var(--w3-accent-cyan);
  box-shadow: 0 0 0 3px var(--w3-accent-cyan-soft);
}

.deals-page-body .deals-list-filters input[type="text"]::placeholder {
  color: var(--w3-text-muted);
}

.deals-page-body .deals-list-filters input[type="text"] {
  min-width: 200px;
}

.deals-page-body .deals-list-filters select option {
  background: #1c1c1e;
  color: var(--w3-text-primary);
}

/* --- List Tab: Deals Table --- */
.deals-page-body .deals-table-wrapper {
  background: var(--w3-bg-card);
  border: 1px solid var(--w3-glass-border);
  border-radius: var(--w3-radius-lg);
  overflow: hidden;
}

.deals-page-body .deals-table {
  width: 100%;
  border-collapse: collapse;
  color: var(--w3-text-secondary);
  --bs-table-bg: transparent;
}

.deals-page-body .deals-table thead th {
  padding: 0.875rem 1rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--w3-text-muted);
  background: var(--w3-glass);
  border-bottom: 1px solid var(--w3-glass-border);
  white-space: nowrap;
  cursor: default;
  user-select: none;
}

.deals-page-body .deals-table thead th.sortable {
  cursor: pointer;
  transition: var(--w3-transition-fast);
}

.deals-page-body .deals-table thead th.sortable:hover {
  color: var(--w3-text-secondary);
}

.deals-page-body .deals-table thead th.sortable.sort-active {
  color: var(--w3-accent-cyan);
}

.deals-page-body .deals-table thead th .sort-icon {
  display: inline-block;
  margin-left: 4px;
  font-size: 0.65rem;
  opacity: 0.5;
}

.deals-page-body .deals-table thead th.sort-active .sort-icon {
  opacity: 1;
}

.deals-page-body .deals-table tbody tr {
  border-bottom: 1px solid var(--w3-glass-border);
  transition: var(--w3-transition-fast);
  cursor: pointer;
}

.deals-page-body .deals-table tbody tr:hover {
  background: rgba(34, 211, 238, 0.05);
}

.deals-page-body .deals-table tbody tr:last-child {
  border-bottom: none;
}

.deals-page-body .deals-table tbody td {
  padding: 0.875rem 1rem;
  font-size: 0.875rem;
  vertical-align: middle;
}

.deals-page-body .deals-table .deal-name-cell {
  color: var(--w3-text-primary);
  font-weight: 500;
}

.deals-page-body .deals-table .deal-name-cell:hover {
  color: var(--w3-accent-cyan);
}

.deals-page-body .deals-table .deal-value-cell {
  color: var(--w3-accent-emerald);
  font-weight: 600;
}

.deals-page-body .deals-table .deal-stage-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 12px;
  background: var(--w3-glass);
  border: 1px solid var(--w3-glass-border);
  font-size: 0.75rem;
  color: var(--w3-text-secondary);
  white-space: nowrap;
}

.deals-page-body .deals-table .deal-stage-chip .chip-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.deals-page-body .deals-table .deal-status-badge {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.deals-page-body .deals-table .deal-status-badge.status-open {
  background: rgba(99, 102, 241, 0.15);
  color: #818cf8;
}

.deals-page-body .deals-table .deal-status-badge.status-won {
  background: var(--w3-accent-emerald-soft);
  color: var(--w3-accent-emerald);
}

.deals-page-body .deals-table .deal-status-badge.status-lost {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
}

.deals-page-body .deals-table .deal-days-cell.stale {
  color: #f59e0b;
}

.deals-page-body .deals-table .deal-owner-cell {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.deals-page-body .deals-table .deal-owner-avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(99,102,241,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.6rem;
  font-weight: 600;
  color: var(--w3-text-primary);
  flex-shrink: 0;
}

/* Empty list state */
.deals-page-body .deals-list-empty {
  text-align: center;
  padding: 3rem 1.5rem;
  color: var(--w3-text-muted);
}

.deals-page-body .deals-list-empty i {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  opacity: 0.5;
  display: block;
}

/* --- List Tab: Pagination --- */
.deals-page-body .deals-list-pagination {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
}

.deals-page-body .deals-list-pagination .pagination-info {
  font-size: 0.8125rem;
  color: var(--w3-text-muted);
}

.deals-page-body .deals-list-pagination .pagination-btns {
  display: flex;
  gap: 4px;
}

.deals-page-body .deals-list-pagination .page-btn {
  padding: 6px 12px;
  background: var(--w3-glass);
  border: 1px solid var(--w3-glass-border);
  border-radius: var(--w3-radius-sm);
  color: var(--w3-text-secondary);
  font-size: 0.8125rem;
  cursor: pointer;
  transition: var(--w3-transition-fast);
}

.deals-page-body .deals-list-pagination .page-btn:hover {
  background: var(--w3-glass-highlight);
  border-color: rgba(255,255,255,0.15);
  color: var(--w3-text-primary);
}

.deals-page-body .deals-list-pagination .page-btn.active {
  background: var(--w3-accent-cyan-soft);
  border-color: rgba(34, 211, 238, 0.3);
  color: var(--w3-accent-cyan);
}

.deals-page-body .deals-list-pagination .page-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* --- Responsive --- */
@media (max-width: 992px) {
  .deals-page-body .pipeline-stats {
    display: none;
  }
}

@media (max-width: 768px) {
  .deals-page-body .stage-column {
    min-width: 280px;
    flex: 0 0 280px;
  }

  .deals-page-body .pipeline-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .deals-page-body .form-row {
    grid-template-columns: 1fr;
  }

  .deals-page-body .pipeline-cards-grid {
    grid-template-columns: 1fr;
  }

  .deals-page-body .deals-list-filters {
    flex-direction: column;
  }

  .deals-page-body .deals-list-filters select,
  .deals-page-body .deals-list-filters input[type="text"] {
    min-width: 100%;
  }

  .deals-page-body .deals-table-wrapper {
    overflow-x: auto;
  }

  .deals-page-body .deals-table {
    min-width: 800px;
  }

  .deals-page-body .deals-list-pagination {
    flex-direction: column;
    gap: 0.75rem;
  }
}
