/* ==========================================================================
   Fareworks Salon & Spa Management CRM
   Premium Modern Body UI with High-Contrast Canvas
   - Canvas: Soft Cool Slate (#F4F6FB) for rich visual depth & card separation
   - Cards: Crisp Elevated Pure White (#FFFFFF) with multi-layered shadows
   - Accents: Fareworks Electric Blue (#010ED0), Mint Emerald (#10B981)
   - Header: Exactly as requested (Flush top, full-width, zero changes)
   - Typography: Plus Jakarta Sans
   ========================================================================== */

:root {
  /* Brand Tokens */
  --fareworks-blue: #010ED0;
  --fareworks-blue-hover: #000B9E;
  --fareworks-blue-light: rgba(1, 14, 208, 0.04);
  --fareworks-blue-subtle: rgba(1, 14, 208, 0.07);
  --fareworks-blue-border: rgba(1, 14, 208, 0.12);

  /* Neutrals */
  --navy-dark: #0A0D31;
  --text-muted: #64748B;
  --text-light: #94A3B8;
  --bg-page: #F4F6FB;
  --bg-card: #FFFFFF;

  /* Semantic Status Colors */
  --status-new-bg: #EEF2FF;
  --status-new-text: #010ED0;
  --status-new-border: #C7D2FE;

  --status-converted-bg: #ECFDF5;
  --status-converted-text: #059669;
  --status-converted-border: #A7F3D0;

  --status-qualified-bg: #FFFBEB;
  --status-qualified-text: #D97706;
  --status-qualified-border: #FDE68A;

  --status-not-qualified-bg: #FEF2F2;
  --status-not-qualified-text: #DC2626;
  --status-not-qualified-border: #FECACA;

  /* Tag Badges */
  --tag-meta-bg: #FFE4E6;
  --tag-meta-text: #E11D48;
  --tag-google-bg: #EEF2FF;
  --tag-google-text: #010ED0;
  --tag-whatsapp-bg: #ECFDF5;
  --tag-whatsapp-text: #059669;
  --tag-call-bg: #F1F5F9;
  --tag-call-text: #475569;
  --tag-walkin-bg: #FFF7ED;
  --tag-walkin-text: #C2410C;
  --tag-website-bg: #F3E8FF;
  --tag-website-text: #7E22CE;
  --tag-location-text: #0284C7;

  /* WhatsApp Button */
  --btn-whatsapp: #10B981;
  --btn-whatsapp-hover: #059669;

  /* Borders & Shadows */
  --border-subtle: rgba(1, 14, 208, 0.08);
  --border-card: #E2E8F0;
  --shadow-header: 0 1px 4px rgba(10, 13, 49, 0.03);
  --shadow-card: 0 1px 3px rgba(15, 23, 42, 0.04), 0 3px 8px rgba(15, 23, 42, 0.02);
  --shadow-hover: 0 4px 16px rgba(1, 14, 208, 0.08), 0 2px 6px rgba(15, 23, 42, 0.04);

  /* Geometry */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-pill: 9999px;

  /* Typography */
  --font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: var(--font-family);
  -webkit-font-smoothing: antialiased;
}

body {
  background-color: var(--bg-page);
  color: var(--navy-dark);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  width: 100%;
  overflow-x: hidden;
}

/* =========================================
   Full-Screen Connected Dashboard Wrapper
   ========================================= */
.dashboard-container {
  width: 100%;
  max-width: 100%;
  margin: 0;
  padding: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* =========================================
   Header Flush at Top Edge (UNCHANGED as requested)
   ========================================= */
header.app-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #ffffff;
  padding: 14px 36px;
  border-radius: 0;
  border-top: none;
  border-left: none;
  border-right: none;
  border-bottom: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-header);
  transition: all 0.3s ease;
  width: 100%;
  gap: 20px;
  position: sticky;
  top: 0;
  z-index: 100;
}

.logo-container {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.logo-img {
  height: 38px;
  width: auto;
  display: block;
}

/* Header Navigation Bar (Integrated in Header) */
.header-nav {
  display: flex;
  align-items: center;
  background: var(--fareworks-blue-light);
  padding: 5px;
  border-radius: 12px;
  border: 1px solid rgba(1, 14, 208, 0.05);
  gap: 4px;
  box-shadow: inset 0 2px 4px rgba(10, 13, 49, 0.02);
  flex-wrap: nowrap;
}

.nav-item {
  display: inline-flex;
  align-items: center;
  padding: 8px 15px;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--navy-dark);
  border-radius: 8px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  gap: 6px;
  white-space: nowrap;
  border: 1px solid transparent;
}

.nav-item svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 0.2s ease;
}

.nav-item:hover {
  color: var(--fareworks-blue);
  background: rgba(1, 14, 208, 0.03);
}

.nav-item:hover svg {
  transform: translateY(-1px);
}

.nav-item.active {
  background-color: var(--fareworks-blue);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(1, 14, 208, 0.25);
}

/* User Account Profile in Header Right */
.user-menu-wrapper {
  position: relative;
  flex-shrink: 0;
}

.user-profile-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #FFFFFF;
  border: 1px solid var(--border-card);
  padding: 6px 14px 6px 8px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 1px 3px rgba(10, 13, 49, 0.04);
}

.user-profile-btn:hover {
  border-color: var(--fareworks-blue);
  background: var(--fareworks-blue-light);
  box-shadow: 0 2px 8px rgba(1, 14, 208, 0.08);
}

.user-avatar-circle {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: linear-gradient(135deg, #010ED0 0%, #2563EB 100%);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.88rem;
  box-shadow: 0 2px 6px rgba(1, 14, 208, 0.25);
  flex-shrink: 0;
}

.user-avatar-circle svg {
  width: 18px;
  height: 18px;
}

.user-name-label {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--navy-dark);
  white-space: nowrap;
}

.dropdown-chevron {
  width: 14px;
  height: 14px;
  color: var(--text-muted);
  transition: transform 0.2s ease;
}

.user-profile-btn[aria-expanded="true"] .dropdown-chevron {
  transform: rotate(180deg);
}

/* User Dropdown Menu */
.user-dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 250px;
  background: #FFFFFF;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  box-shadow: 0 10px 25px -5px rgba(10, 13, 49, 0.12), 0 8px 10px -6px rgba(10, 13, 49, 0.06);
  padding: 8px 0;
  display: none;
  z-index: 200;
  animation: fadeInSlide 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.user-dropdown-menu.active {
  display: block;
}

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

.dropdown-user-header {
  padding: 10px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.dropdown-user-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--fareworks-blue-light);
  color: var(--fareworks-blue);
  font-weight: 800;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1px solid rgba(1, 14, 208, 0.15);
}

.dropdown-user-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.dropdown-user-name {
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--navy-dark);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dropdown-user-role {
  font-size: 0.74rem;
  color: var(--text-muted);
  font-weight: 600;
}

.dropdown-divider {
  height: 1px;
  background: #EDF2F7;
  margin: 6px 0;
}

.dropdown-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--navy-dark);
  text-decoration: none;
  cursor: pointer;
  transition: all 0.15s ease;
  border: none;
  background: transparent;
  width: 100%;
  text-align: left;
}

.dropdown-item svg {
  width: 16px;
  height: 16px;
  color: var(--text-muted);
  flex-shrink: 0;
  transition: color 0.15s ease;
}

.dropdown-item:hover {
  background: #F8FAFD;
  color: var(--fareworks-blue);
}

.dropdown-item:hover svg {
  color: var(--fareworks-blue);
}

.dropdown-item-danger {
  color: #DC2626;
}

.dropdown-item-danger svg {
  color: #DC2626;
}

.dropdown-item-danger:hover {
  background: #FEF2F2;
  color: #B91C1C;
}

.dropdown-item-danger:hover svg {
  color: #B91C1C;
}

/* =========================================
   Elevated Body Workspace on Slate Canvas
   ========================================= */
.workspace-card {
  background: transparent;
  padding: 28px 36px 40px 36px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 100%;
  flex: 1;
}

/* Page Title Row */
.page-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.title-badge-wrap {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.page-title {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--navy-dark);
  letter-spacing: -0.02em;
}

.live-count-badge {
  background: #FFFFFF;
  border: 1px solid var(--border-card);
  color: var(--fareworks-blue);
  font-size: 0.78rem;
  font-weight: 700;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-pill);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.btn-add-lead {
  background-color: var(--fareworks-blue);
  color: #ffffff;
  border: none;
  padding: 0.65rem 1.4rem;
  border-radius: 10px;
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  box-shadow: 0 4px 14px rgba(1, 14, 208, 0.25);
  transition: all 0.2s ease;
}

.btn-add-lead:hover {
  background-color: var(--fareworks-blue-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(1, 14, 208, 0.35);
}

.btn-add-lead svg {
  width: 16px;
  height: 16px;
}

/* =========================================
   Metric Summary Cards (Elevated SaaS Style)
   ========================================= */
.metrics-row {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
}

.metric-box {
  background: #ffffff;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 14px 20px;
  cursor: pointer;
  box-shadow: var(--shadow-card);
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
}

.metric-box:hover {
  border-color: #CBD5E1;
  box-shadow: var(--shadow-hover);
  transform: translateY(-1px);
}

.metric-box.active {
  border: 2px solid var(--fareworks-blue);
  box-shadow: 0 4px 14px rgba(1, 14, 208, 0.12);
  background: #ffffff;
}

.metric-num {
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--navy-dark);
  line-height: 1.1;
  margin-bottom: 3px;
  letter-spacing: -0.02em;
}

.metric-box.active .metric-num {
  color: var(--fareworks-blue);
}

.metric-label {
  font-size: 0.84rem;
  color: var(--text-muted);
  font-weight: 600;
}

/* =========================================
   Filters & Search Toolbar
   ========================================= */
.filters-row {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 14px;
}

.search-and-filter-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
}

.search-field-wrapper {
  position: relative;
  flex: 1 1 auto;
}

.search-input {
  width: 100%;
  height: 42px;
  padding: 0 1rem 0 2.4rem;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-sm);
  background-color: #ffffff;
  font-size: 0.88rem;
  color: var(--navy-dark);
  outline: none;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.02);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.search-input:focus {
  border-color: var(--fareworks-blue);
  box-shadow: 0 0 0 3px rgba(1, 14, 208, 0.1);
}

.search-input::placeholder {
  color: var(--text-light);
}

.search-icon-svg {
  position: absolute;
  left: 0.85rem;
  top: 50%;
  transform: translateY(-50%);
  width: 15px;
  height: 15px;
  color: var(--text-light);
  pointer-events: none;
}

/* Filter Toggle Button */
.btn-filter-toggle {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 42px;
  padding: 0 14px;
  background: #FFFFFF;
  border: 1.5px solid var(--border-card);
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--navy-dark);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
  flex-shrink: 0;
  box-shadow: 0 1px 3px rgba(10, 13, 49, 0.04);
}

.btn-filter-toggle:hover {
  border-color: var(--fareworks-blue);
  color: var(--fareworks-blue);
  background: var(--fareworks-blue-light);
}

.btn-filter-toggle.active,
.btn-filter-toggle.has-filters {
  background: #EEF2FF;
  border-color: var(--fareworks-blue);
  color: var(--fareworks-blue);
}

.filter-toggle-icon {
  width: 15px;
  height: 15px;
  stroke: currentColor;
}

.filter-active-dot {
  width: 7px;
  height: 7px;
  background: var(--fareworks-blue);
  border-radius: 50%;
  display: inline-block;
}

.filters-collapsible-tray {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
}

.filter-select {
  flex: 1 1 auto;
  height: 42px;
  padding: 0 2rem 0 0.85rem;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-sm);
  background-color: #ffffff;
  font-size: 0.86rem;
  color: var(--navy-dark);
  font-weight: 600;
  cursor: pointer;
  outline: none;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.02);
  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 20 20' fill='%23010ED0'%3E%3Cpath fill-rule='evenodd' d='M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z' clip-rule='evenodd'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.8rem center;
  transition: border-color 0.2s;
}

.filter-select:focus {
  border-color: var(--fareworks-blue);
  box-shadow: 0 0 0 3px rgba(1, 14, 208, 0.1);
}

@media (min-width: 901px) {
  .filters-row {
    flex-direction: row;
    align-items: center;
    gap: 12px;
  }
  .search-and-filter-bar {
    flex: 1.4 1 280px;
  }
  .btn-filter-toggle {
    display: none;
  }
  .filters-collapsible-tray {
    display: flex !important;
    flex: 2.6 1 auto;
    gap: 10px;
  }
}

/* =========================================
   Lead Cards List (High-Craft Card Styling)
   ========================================= */
.leads-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.lead-card {
  background: #ffffff;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 1.15rem 1.4rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  box-shadow: var(--shadow-card);
  transition: all 0.2s ease;
}

.lead-card:hover {
  border-color: #CBD5E1;
  box-shadow: var(--shadow-hover);
  transform: translateY(-1px);
}

/* Left Section: Avatar + Name + Tags */
.lead-left-col {
  flex: 0 0 44%;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 0.9rem;
}

.customer-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(1, 14, 208, 0.06);
  color: var(--fareworks-blue);
  font-weight: 800;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1.5px solid rgba(1, 14, 208, 0.12);
}

.lead-profile-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.lead-title-row {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
  margin-bottom: 0.25rem;
}

.customer-name {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--navy-dark);
  letter-spacing: -0.01em;
}

.tag-pill {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.18rem 0.6rem;
  border-radius: var(--radius-pill);
  line-height: 1.2;
}

.tag-meta { background-color: var(--tag-meta-bg); color: var(--tag-meta-text); }
.tag-google { background-color: var(--tag-google-bg); color: var(--tag-google-text); }
.tag-whatsapp { background-color: var(--tag-whatsapp-bg); color: var(--tag-whatsapp-text); }
.tag-call { background-color: var(--tag-call-bg); color: var(--tag-call-text); }
.tag-walkin { background-color: var(--tag-walkin-bg); color: var(--tag-walkin-text); }
.tag-website { background-color: var(--tag-website-bg); color: var(--tag-website-text); }

.channel-pill {
  font-size: 0.72rem;
  font-weight: 600;
  color: #475569;
  border: 1px solid var(--border-card);
  background-color: #F8FAFC;
  padding: 0.12rem 0.5rem;
  border-radius: var(--radius-pill);
}

.location-pill {
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--fareworks-blue);
  margin-left: 0.15rem;
}

.notes-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  font-size: 0.72rem;
  color: #64748B;
  border: 1px solid var(--border-card);
  background-color: #F8FAFC;
  border-radius: 6px;
  padding: 0.12rem 0.4rem;
}

.notes-chip svg {
  width: 12px;
  height: 12px;
}

.lead-time-sub {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.location-sub-line {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--fareworks-blue);
  margin-top: 0.2rem;
}

/* Middle Section: Service Inquiry & Actions */
.lead-middle-col {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.45rem;
}

.service-cardlet {
  font-size: 0.88rem;
  color: var(--navy-dark);
  font-weight: 600;
  background-color: #F8FAFD;
  border: 1px solid #EDF2F7;
  padding: 0.35rem 0.75rem;
  border-radius: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.actions-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-phone-pill {
  background-color: #FFFFFF;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-sm);
  padding: 0.42rem 0.85rem;
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--navy-dark);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  transition: all 0.2s ease;
}

.btn-phone-pill:hover {
  background-color: #F8FAFC;
  border-color: #CBD5E1;
}

.btn-phone-pill svg {
  width: 13px;
  height: 13px;
  fill: var(--fareworks-blue);
}

.btn-whatsapp-pill {
  background-color: var(--btn-whatsapp);
  color: #ffffff;
  border: none;
  border-radius: var(--radius-sm);
  padding: 0.42rem 0.95rem;
  font-size: 0.84rem;
  font-weight: 700;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  box-shadow: 0 2px 8px rgba(16, 185, 129, 0.25);
  transition: background-color 0.2s ease;
}

.btn-whatsapp-pill:hover {
  background-color: var(--btn-whatsapp-hover);
}

.btn-whatsapp-pill svg {
  width: 15px;
  height: 15px;
  fill: currentColor;
}

/* Right Section: Status Dropdown Pill */
.lead-right-col {
  flex: 0 0 135px;
  display: flex;
  justify-content: flex-end;
}

.status-select-pill {
  width: 130px;
  padding: 0.45rem 1.8rem 0.45rem 0.95rem;
  border-radius: var(--radius-pill);
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  outline: none;
  appearance: none;
  -webkit-appearance: none;
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
  background-size: 11px;
  border: 1px solid transparent;
  transition: all 0.2s ease;
}

/* Status variants */
.status-select-pill.status-new {
  background-color: var(--status-new-bg);
  color: var(--status-new-text);
  border-color: var(--status-new-border);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 20 20' fill='%23010ED0'%3E%3Cpath fill-rule='evenodd' d='M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z' clip-rule='evenodd'/%3E%3C/svg%3E");
}

.status-select-pill.status-converted {
  background-color: var(--status-converted-bg);
  color: var(--status-converted-text);
  border-color: var(--status-converted-border);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 20 20' fill='%23059669'%3E%3Cpath fill-rule='evenodd' d='M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z' clip-rule='evenodd'/%3E%3C/svg%3E");
}

.status-select-pill.status-qualified {
  background-color: var(--status-qualified-bg);
  color: var(--status-qualified-text);
  border-color: var(--status-qualified-border);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 20 20' fill='%23D97706'%3E%3Cpath fill-rule='evenodd' d='M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z' clip-rule='evenodd'/%3E%3C/svg%3E");
}

.status-select-pill.status-not-qualified {
  background-color: var(--status-not-qualified-bg);
  color: var(--status-not-qualified-text);
  border-color: var(--status-not-qualified-border);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 20 20' fill='%23DC2626'%3E%3Cpath fill-rule='evenodd' d='M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z' clip-rule='evenodd'/%3E%3C/svg%3E");
}

/* =========================================
   Footer (Full Width, Crisp White Surface)
   ========================================= */
footer.app-footer {
  background: #ffffff;
  border-top: 1px solid var(--border-subtle);
  padding: 18px 36px;
  text-align: center;
  margin-top: auto;
  width: 100%;
}

.footer-content {
  width: 100%;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.copyright-text {
  font-weight: 600;
}

.footer-brand {
  color: var(--fareworks-blue);
  font-weight: 700;
  text-decoration: none;
}

.footer-brand:hover {
  text-decoration: underline;
}

/* =========================================
   Add Lead Modal
   ========================================= */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(10, 13, 49, 0.45);
  backdrop-filter: blur(4px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 1rem;
}

.modal-overlay.active {
  display: flex;
}

.modal-card {
  background: #ffffff;
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 500px;
  box-shadow: 0 20px 40px rgba(10, 13, 49, 0.15);
  overflow: hidden;
  border: 1px solid var(--border-card);
}

.modal-header {
  background: var(--navy-dark);
  color: #ffffff;
  padding: 1.15rem 1.4rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-header h3 {
  font-size: 1.15rem;
  font-weight: 800;
}

.btn-close {
  background: transparent;
  border: none;
  color: #94A3B8;
  font-size: 1.25rem;
  cursor: pointer;
  transition: color 0.15s;
}

.btn-close:hover {
  color: #ffffff;
}

.modal-body {
  padding: 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.input-label {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--navy-dark);
  margin-bottom: 0.25rem;
}

.form-control {
  width: 100%;
  height: 42px;
  padding: 0 0.85rem;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  outline: none;
  background-color: #FAFBFD;
}

.form-control:focus {
  border-color: var(--fareworks-blue);
  background-color: #ffffff;
  box-shadow: 0 0 0 3px rgba(1, 14, 208, 0.1);
}

.modal-footer {
  background: #FAFBFD;
  border-top: 1px solid var(--border-card);
  padding: 0.9rem 1.4rem;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.65rem;
}

.btn-cancel {
  background: #ffffff;
  border: 1px solid var(--border-card);
  color: var(--text-muted);
  padding: 0.55rem 1.1rem;
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
}

/* =========================================
   Responsive Adjustments
   ========================================= */
@media (max-width: 1100px) {
  header.app-header {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    padding: 10px 18px;
    gap: 8px 12px;
  }
  .logo-container {
    order: 1;
    display: flex;
    align-items: center;
  }
  .header-right-actions {
    order: 2;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: auto;
  }
  .header-nav {
    order: 3;
    width: 100%;
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    justify-content: flex-start;
  }
  .header-nav::-webkit-scrollbar {
    display: none;
  }
  .workspace-card {
    padding: 20px 20px 30px 20px;
  }
}

@media (max-width: 900px) {
  /* Responsive Header: Hide name & chevron, show profile avatar icon only */
  .user-name-label {
    display: none !important;
  }
  .dropdown-chevron {
    display: none !important;
  }
  .user-profile-btn {
    padding: 0 !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    border-radius: 50% !important;
  }
  .user-avatar-circle {
    width: 35px;
    height: 35px;
    border: 1px solid var(--border-card);
    box-shadow: 0 1px 3px rgba(10, 13, 49, 0.08);
  }
  .notification-btn {
    width: 35px;
    height: 35px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .lead-card {
    flex-wrap: wrap;
    gap: 1rem;
  }
  .lead-left-col {
    flex: 1 1 100%;
  }
}

@media (max-width: 768px) {
  /* Workspace card container: tight mobile padding with zero dead space above */
  .workspace-card,
  main.workspace-card {
    padding: 8px 10px 92px 10px !important;
    gap: 7px !important;
  }

  .page-title-row {
    margin-bottom: 2px !important;
  }

  .page-title {
    font-size: 1.25rem !important;
    line-height: 1.15 !important;
  }

  .live-count-badge {
    font-size: 0.68rem !important;
    padding: 2px 7px !important;
  }

  /* Compact Horizontal Scrollable Single-Row Metrics Filter Carousel */
  .metrics-row {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    gap: 7px !important;
    padding: 1px 2px 4px 2px !important;
    margin-bottom: 6px !important;
    grid-template-columns: none !important;
  }
  .metrics-row::-webkit-scrollbar {
    display: none !important;
  }

  .metric-box {
    flex: 0 0 auto !important;
    display: inline-flex !important;
    flex-direction: row !important;
    align-items: center !important;
    gap: 6px !important;
    padding: 5px 11px !important;
    border-radius: 9999px !important;
    min-height: 34px !important;
    background: #FFFFFF !important;
    border: 1.5px solid #E2E8F0 !important;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(10, 13, 49, 0.04) !important;
    transition: all 0.15s ease !important;
  }
  .metric-box:hover {
    border-color: #CBD5E1 !important;
    transform: translateY(-1px) !important;
  }
  .metric-box .metric-num {
    font-size: 0.90rem !important;
    font-weight: 800 !important;
    line-height: 1 !important;
    color: var(--navy-dark) !important;
  }
  .metric-box .metric-label {
    font-size: 0.74rem !important;
    font-weight: 600 !important;
    color: #64748B !important;
    white-space: nowrap !important;
  }
  .metric-box.active {
    background: #EEF2FF !important;
    border-color: var(--fareworks-blue) !important;
    box-shadow: 0 2px 6px rgba(1, 14, 208, 0.15) !important;
  }
  .metric-box.active .metric-num {
    color: var(--fareworks-blue) !important;
  }
  .metric-box.active .metric-label {
    color: var(--fareworks-blue) !important;
    font-weight: 700 !important;
  }

  /* Filters Row on Mobile: Search + Filter Toggle Button on Row 1, Collapsed Tray */
  .filters-row {
    display: flex !important;
    flex-direction: column !important;
    gap: 6px !important;
    margin-bottom: 8px !important;
    grid-template-columns: none !important;
  }

  .search-and-filter-bar {
    display: flex !important;
    align-items: center !important;
    gap: 7px !important;
    width: 100% !important;
  }

  .search-field-wrapper {
    flex: 1 1 auto !important;
    grid-column: auto !important;
  }

  .search-input {
    height: 38px !important;
    font-size: 0.84rem !important;
  }

  .btn-filter-toggle {
    display: inline-flex !important;
    height: 38px !important;
    padding: 0 11px !important;
    font-size: 0.78rem !important;
  }

  .filters-collapsible-tray {
    display: none !important; /* Hidden by default on mobile */
    width: 100% !important;
    flex-direction: column !important;
    gap: 8px !important;
    padding: 10px !important;
    background: #F8FAFD !important;
    border: 1.5px solid #E2E8F0 !important;
    border-radius: 10px !important;
    box-sizing: border-box !important;
    animation: slideDownFilter 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  }

  .filters-collapsible-tray.active {
    display: flex !important;
  }

  .filters-collapsible-tray .filter-select {
    width: 100% !important;
    background-color: #FFFFFF !important;
  }

  /* Leads List Container */
  .leads-list {
    display: flex !important;
    flex-direction: column !important;
    gap: 10px !important;
    padding-bottom: 24px !important;
  }

  /* Lead Card - Mobile Friendly & Polished */
  .lead-card {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 10px !important;
    padding: 12px 14px !important;
    border-radius: 12px !important;
    border: 1px solid #E2E8F0 !important;
    background: #FFFFFF !important;
    box-shadow: 0 2px 6px rgba(10, 13, 49, 0.04) !important;
  }

  .lead-left-col {
    flex: 1 1 100% !important;
    width: 100% !important;
    display: flex !important;
    align-items: flex-start !important;
    gap: 10px !important;
  }

  .lead-card .customer-avatar {
    width: 38px !important;
    height: 38px !important;
    font-size: 0.95rem !important;
    font-weight: 800 !important;
    flex-shrink: 0 !important;
    border-radius: 50% !important;
    background: rgba(1, 14, 208, 0.08) !important;
    color: var(--fareworks-blue) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
  }

  .lead-profile-text {
    flex: 1 1 auto !important;
    min-width: 0 !important;
  }

  .lead-title-row {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    gap: 6px !important;
    margin-bottom: 3px !important;
  }

  .lead-title-row .customer-name {
    font-size: 1rem !important;
    font-weight: 800 !important;
    color: var(--navy-dark) !important;
  }

  .tag-pill, .channel-pill, .location-pill {
    font-size: 0.69rem !important;
    padding: 2px 6px !important;
    border-radius: 5px !important;
  }

  .lead-time-sub {
    font-size: 0.74rem !important;
    color: #64748B !important;
  }

  .lead-middle-col {
    flex: 1 1 100% !important;
    width: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 8px !important;
  }

  .service-cardlet {
    width: 100% !important;
    font-size: 0.80rem !important;
    padding: 6px 10px !important;
    background: #F8FAFD !important;
    border: 1px solid #EDF2F7 !important;
    border-radius: 6px !important;
    color: var(--navy-dark) !important;
    box-sizing: border-box !important;
  }

  .lead-card .actions-row {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    width: 100% !important;
  }

  .btn-phone-pill {
    flex: 1 1 auto !important;
    justify-content: center !important;
    padding: 7px 10px !important;
    font-size: 0.80rem !important;
    border-radius: 8px !important;
    font-weight: 700 !important;
    text-decoration: none !important;
    background: #FFFFFF !important;
    border: 1.5px solid #E2E8F0 !important;
    color: var(--navy-dark) !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
  }

  .btn-whatsapp-pill {
    flex: 0 0 auto !important;
    justify-content: center !important;
    padding: 7px 12px !important;
    font-size: 0.80rem !important;
    border-radius: 8px !important;
    font-weight: 700 !important;
    text-decoration: none !important;
    background: #25D366 !important;
    color: #FFFFFF !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 5px !important;
    border: none !important;
  }

  .lead-right-col {
    flex: 1 1 100% !important;
    width: 100% !important;
    display: flex !important;
    align-items: center !important;
  }

  .lead-right-col .status-select-pill {
    width: 100% !important;
    text-align: center !important;
    justify-content: center !important;
    padding: 7px 12px !important;
    font-size: 0.82rem !important;
    font-weight: 700 !important;
    border-radius: 8px !important;
  }

  /* -----------------------------------------
     FOLLOW-UP CARD - MOBILE OPTIMIZATION
     ----------------------------------------- */
  .followup-card {
    display: flex !important;
    flex-direction: column !important;
    gap: 10px !important;
    padding: 12px 14px !important;
    border-radius: 12px !important;
    border: 1px solid #E2E8F0 !important;
    background: #FFFFFF !important;
    box-shadow: 0 2px 6px rgba(10, 13, 49, 0.04) !important;
  }

  .followup-top-row {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 8px !important;
    width: 100% !important;
  }

  .followup-customer-group {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    gap: 6px 8px !important;
    width: 100% !important;
    overflow: visible !important;
  }

  .customer-avatar-sm {
    width: 32px !important;
    height: 32px !important;
    font-size: 0.82rem !important;
    font-weight: 800 !important;
    flex-shrink: 0 !important;
  }

  .followup-customer-group .customer-name {
    font-size: 0.98rem !important;
    font-weight: 800 !important;
    color: var(--navy-dark) !important;
    white-space: normal !important;
  }

  .due-pill {
    font-size: 0.72rem !important;
    padding: 2px 7px !important;
    border-radius: 6px !important;
  }

  .priority-pill {
    font-size: 0.70rem !important;
    padding: 2px 6px !important;
    border-radius: 6px !important;
  }

  .service-pill-compact {
    width: 100% !important;
    max-width: 100% !important;
    font-size: 0.78rem !important;
    margin-top: 2px !important;
    box-sizing: border-box !important;
  }

  .followup-actions-group {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    gap: 6px !important;
    width: 100% !important;
  }

  .btn-phone-sm {
    flex: 1 1 auto !important;
    justify-content: center !important;
    padding: 7px 10px !important;
    font-size: 0.78rem !important;
    border-radius: 8px !important;
    border: 1.5px solid #E2E8F0 !important;
  }

  .btn-whatsapp-sm {
    flex: 0 0 auto !important;
    justify-content: center !important;
    padding: 7px 12px !important;
    font-size: 0.78rem !important;
    border-radius: 8px !important;
    background: #25D366 !important;
    color: #FFFFFF !important;
    border: none !important;
  }

  .followup-actions-group .status-select-pill {
    flex: 1 1 auto !important;
    justify-content: center !important;
    padding: 7px 10px !important;
    font-size: 0.78rem !important;
    text-align: center !important;
    border-radius: 8px !important;
  }

  .followup-bottom-row {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    gap: 6px !important;
    width: 100% !important;
    font-size: 0.76rem !important;
    padding: 6px 8px !important;
    box-sizing: border-box !important;
    border-radius: 6px !important;
  }

  .followup-note-text {
    flex: 1 1 100% !important;
    margin-bottom: 2px !important;
  }
}

@media (max-width: 650px) {
  /* Mobile Header: Ultra-compact, Logo (left) + Bell & Profile (right) on Row 1, Nav on Row 2 */
  header.app-header {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: wrap !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding: 7px 12px !important;
    gap: 6px 10px !important;
    text-align: left !important;
    position: sticky;
    top: 0;
    z-index: 100;
  }

  .logo-container {
    order: 1 !important;
    display: flex !important;
    align-items: center !important;
    flex-shrink: 0 !important;
  }

  .logo-img {
    height: 27px !important;
    max-height: 27px !important;
    width: auto !important;
    object-fit: contain !important;
    display: block !important;
  }

  .header-right-actions {
    order: 2 !important;
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    margin-left: auto !important;
    flex-shrink: 0 !important;
  }

  .user-avatar-circle,
  .notification-btn {
    width: 32px !important;
    height: 32px !important;
    font-size: 0.78rem !important;
  }

  .notification-btn svg {
    width: 17px !important;
    height: 17px !important;
  }

  /* Hide redundant top nav on mobile; bottom nav bar handles all navigation */
  .header-nav {
    display: none !important;
  }

  .footer-content {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }
}

/* =========================================
   Header Notification Icon & Dropdown Panel
   ========================================= */
.header-right-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.notification-wrapper {
  position: relative;
}

.notification-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #FFFFFF;
  border: 1px solid var(--border-card);
  color: var(--navy-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  transition: all 0.2s ease;
  box-shadow: 0 1px 3px rgba(10, 13, 49, 0.04);
}

.notification-btn:hover {
  background: var(--fareworks-blue-light);
  border-color: var(--fareworks-blue);
  color: var(--fareworks-blue);
  box-shadow: 0 2px 8px rgba(1, 14, 208, 0.1);
}

.notification-btn svg {
  width: 19px;
  height: 19px;
}

.notification-badge-dot {
  position: absolute;
  top: 7px;
  right: 8px;
  width: 9px;
  height: 9px;
  background-color: #E11D48;
  border: 2px solid #FFFFFF;
  border-radius: 50%;
}

.notification-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: -50px;
  width: 320px;
  background: #FFFFFF;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  box-shadow: 0 14px 35px -4px rgba(10, 13, 49, 0.15), 0 4px 12px rgba(10, 13, 49, 0.06);
  display: none;
  z-index: 220;
  animation: fadeInSlide 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.notification-dropdown.active {
  display: block;
}

.notif-header {
  padding: 12px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #EDF2F7;
  background: #F8FAFD;
}

.notif-title {
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--navy-dark);
}

.notif-count-tag {
  font-size: 0.72rem;
  font-weight: 700;
  background: rgba(1, 14, 208, 0.08);
  color: var(--fareworks-blue);
  padding: 2px 8px;
  border-radius: var(--radius-pill);
}

.notif-list {
  max-height: 280px;
  overflow-y: auto;
}

.notif-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 16px;
  border-bottom: 1px solid #F1F5F9;
  cursor: pointer;
  transition: background 0.15s ease;
}

.notif-item:hover {
  background: #F8FAFD;
}

.notif-item.unread {
  background: #F0F4FF;
}

.notif-item-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 2px;
}

.notif-item-icon.meta {
  background: #FFE4E6;
  color: #E11D48;
}

.notif-item-icon.whatsapp {
  background: #ECFDF5;
  color: #059669;
}

.notif-item-icon.call {
  background: #EEF2FF;
  color: #010ED0;
}

.notif-item-icon svg {
  width: 16px;
  height: 16px;
}

.notif-item-content {
  flex: 1;
  min-width: 0;
}

.notif-item-msg {
  font-size: 0.82rem;
  color: var(--navy-dark);
  line-height: 1.35;
  margin-bottom: 3px;
}

.notif-item-time {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 600;
}

.notif-footer {
  padding: 8px 16px;
  text-align: center;
  background: #FFFFFF;
  border-top: 1px solid #EDF2F7;
}

.notif-clear-btn {
  background: transparent;
  border: none;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--fareworks-blue);
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
}

.notif-clear-btn:hover {
  text-decoration: underline;
}

/* =========================================
   Direct 1-Click Sticky "+ Add Lead" Button (Right Side)
   ========================================= */
.sticky-round-btn {
  position: fixed;
  right: 28px;
  bottom: 32px;
  z-index: 999;
  background: linear-gradient(135deg, #010ED0 0%, #1522DE 100%);
  color: #FFFFFF;
  border: none;
  border-radius: 16px;
  padding: 13px 20px 13px 16px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  box-shadow: 0 10px 25px -3px rgba(1, 14, 208, 0.42), 0 4px 12px -2px rgba(1, 14, 208, 0.25);
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.sticky-round-btn:hover {
  background: linear-gradient(135deg, #010BBB 0%, #010ED0 100%);
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 14px 30px -2px rgba(1, 14, 208, 0.5), 0 6px 16px -2px rgba(1, 14, 208, 0.3);
}

.sticky-round-btn:active {
  transform: translateY(0) scale(0.98);
}

.plus-icon-svg {
  width: 20px;
  height: 20px;
}

.sticky-label-text {
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: 0.01em;
}


/* =========================================
   Follow-up Page Enhancements
   ========================================= */
.due-pill {
  font-size: 0.72rem;
  font-weight: 800;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-pill);
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  letter-spacing: 0.01em;
}

.due-pill.due-today {
  background-color: #EFF6FF;
  color: #1D4ED8;
  border: 1px solid #BFDBFE;
}

.due-pill.due-overdue {
  background-color: #FEF2F2;
  color: #DC2626;
  border: 1px solid #FECACA;
  animation: pulseDot 2s infinite;
}

.due-pill.due-upcoming {
  background-color: #F8FAFC;
  color: #475569;
  border: 1px solid #E2E8F0;
}

.due-pill.due-completed {
  background-color: #ECFDF5;
  color: #059669;
  border: 1px solid #A7F3D0;
}

.priority-pill {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
}

.priority-pill.priority-high {
  background: #FFE4E6;
  color: #E11D48;
  border: 1px solid #FECDD3;
}

.priority-pill.priority-normal {
  background: #F1F5F9;
  color: #475569;
}

.followup-note-box {
  background: #F8FAFD;
  border-left: 3px solid var(--fareworks-blue);
  padding: 0.45rem 0.8rem;
  border-radius: 0 6px 6px 0;
  font-size: 0.82rem;
  color: var(--navy-dark);
  line-height: 1.4;
  margin-top: 0.15rem;
}

.followup-note-box strong {
  color: var(--fareworks-blue);
  font-weight: 700;
}

/* Follow-up Status Select Pills */
.status-select-pill.status-pending {
  background-color: #FFFBEB;
  color: #D97706;
  border-color: #FDE68A;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 20 20' fill='%23D97706'%3E%3Cpath fill-rule='evenodd' d='M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z' clip-rule='evenodd'/%3E%3C/svg%3E");
}

.status-select-pill.status-completed {
  background-color: #ECFDF5;
  color: #059669;
  border-color: #A7F3D0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 20 20' fill='%23059669'%3E%3Cpath fill-rule='evenodd' d='M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z' clip-rule='evenodd'/%3E%3C/svg%3E");
}

.status-select-pill.status-overdue {
  background-color: #FEF2F2;
  color: #DC2626;
  border-color: #FECACA;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 20 20' fill='%23DC2626'%3E%3Cpath fill-rule='evenodd' d='M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z' clip-rule='evenodd'/%3E%3C/svg%3E");
}

.status-select-pill.status-rescheduled {
  background-color: #F3E8FF;
  color: #7E22CE;
  border-color: #E9D5FF;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 20 20' fill='%237E22CE'%3E%3Cpath fill-rule='evenodd' d='M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z' clip-rule='evenodd'/%3E%3C/svg%3E");
}

.status-select-pill.status-cancelled {
  background-color: #F1F5F9;
  color: #64748B;
  border-color: #CBD5E1;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 20 20' fill='%2364748B'%3E%3Cpath fill-rule='evenodd' d='M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z' clip-rule='evenodd'/%3E%3C/svg%3E");
}


/* =========================================
   Ultra-Compact Space-Efficient Follow-up Cards
   ========================================= */
.followup-card {
  background: #ffffff;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 9px 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  box-shadow: var(--shadow-card);
  transition: all 0.2s ease;
}

.followup-card:hover {
  border-color: #CBD5E1;
  box-shadow: var(--shadow-hover);
  transform: translateY(-1px);
}

/* Top Row: Customer info, Due badge, Priority, Service, Actions, Status */
.followup-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.followup-customer-group {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
}

.customer-avatar-sm {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(1, 14, 208, 0.06);
  color: var(--fareworks-blue);
  font-weight: 800;
  font-size: 0.76rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1.5px solid rgba(1, 14, 208, 0.12);
}

.followup-customer-group .customer-name {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--navy-dark);
  white-space: nowrap;
}

.service-pill-compact {
  font-size: 0.78rem;
  color: var(--navy-dark);
  font-weight: 600;
  background-color: #F8FAFD;
  border: 1px solid #EDF2F7;
  padding: 0.18rem 0.5rem;
  border-radius: 5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 260px;
}

.followup-actions-group {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.btn-phone-sm {
  background-color: #FFFFFF;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-sm);
  padding: 0.3rem 0.65rem;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--navy-dark);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.btn-phone-sm:hover {
  background-color: #F8FAFC;
  border-color: #CBD5E1;
}

.btn-phone-sm svg {
  width: 12px;
  height: 12px;
  fill: currentColor;
}

.btn-whatsapp-sm {
  background-color: var(--btn-whatsapp);
  border: 1px solid var(--btn-whatsapp);
  border-radius: var(--radius-sm);
  padding: 0.3rem 0.65rem;
  font-size: 0.78rem;
  font-weight: 700;
  color: #ffffff;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.btn-whatsapp-sm:hover {
  background-color: var(--btn-whatsapp-hover);
}

.btn-whatsapp-sm svg {
  width: 12px;
  height: 12px;
  fill: currentColor;
}

/* Bottom Row: Full width Note & Meta */
.followup-bottom-row {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  color: #334155;
  background: #F8FAFD;
  border-left: 3px solid var(--fareworks-blue);
  padding: 0.3rem 0.75rem;
  border-radius: 0 6px 6px 0;
  min-width: 0;
}

.note-prefix {
  font-weight: 800;
  color: var(--fareworks-blue);
  flex-shrink: 0;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.note-content {
  flex: 1 1 auto;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
  color: #1E293B;
  font-weight: 500;
}

.note-source-tag {
  flex-shrink: 0;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.12rem 0.45rem;
  border-radius: 4px;
}

.note-meta-time {
  flex-shrink: 0;
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 600;
}

/* ==========================================================================
   APPOINTMENT BOOKINGS & INTERACTIVE CALENDAR STYLES
   ========================================================================== */

/* Main Layout: 2 Columns on Desktop */
.bookings-layout {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 20px;
  align-items: start;
}

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

/* Calendar Card Container */
.calendar-card {
  background: #ffffff;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 16px;
  box-shadow: var(--shadow-card);
  position: sticky;
  top: 76px;
}

.calendar-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.calendar-month-title {
  font-size: 0.96rem;
  font-weight: 800;
  color: #0F172A;
  letter-spacing: -0.01em;
}

.calendar-nav-group {
  display: flex;
  align-items: center;
  gap: 4px;
}

.cal-nav-btn {
  background: #F1F5F9;
  border: 1px solid #E2E8F0;
  border-radius: 6px;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #334155;
  transition: all 0.15s ease;
}

.cal-nav-btn:hover {
  background: #E2E8F0;
  color: var(--fareworks-blue);
}

.cal-nav-btn svg {
  width: 14px;
  height: 14px;
  stroke-width: 2.5;
}

.cal-today-btn {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.25rem 0.55rem;
  background: #EFF6FF;
  border: 1px solid #BFDBFE;
  color: var(--fareworks-blue);
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.cal-today-btn:hover {
  background: var(--fareworks-blue);
  color: #ffffff;
}

/* Days of Week Header */
.calendar-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
  text-align: center;
  margin-bottom: 6px;
}

.cal-weekday {
  font-size: 0.72rem;
  font-weight: 700;
  color: #94A3B8;
  text-transform: uppercase;
  padding: 4px 0;
}

/* Calendar Days Grid */
.calendar-days-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.cal-day-cell {
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 0.82rem;
  font-weight: 600;
  color: #334155;
  border-radius: 8px;
  cursor: pointer;
  position: relative;
  transition: all 0.15s ease;
  user-select: none;
  background: transparent;
  border: 1px solid transparent;
}

.cal-day-cell:hover:not(.empty) {
  background: #F1F5F9;
  border-color: #E2E8F0;
}

.cal-day-cell.empty {
  cursor: default;
  color: #CBD5E1;
}

.cal-day-cell.today {
  border-color: var(--fareworks-blue);
  font-weight: 800;
  color: var(--fareworks-blue);
}

.cal-day-cell.selected {
  background: var(--fareworks-blue) !important;
  color: #ffffff !important;
  border-color: var(--fareworks-blue) !important;
  box-shadow: 0 4px 10px rgba(1, 14, 208, 0.25);
}

.cal-day-cell.selected .cal-booking-dot {
  background: #ffffff;
}

.cal-booking-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--fareworks-blue);
  position: absolute;
  bottom: 4px;
}

/* Calendar Quick Filter Chips */
.calendar-quick-filters {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid #E2E8F0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.cal-filter-chip {
  font-size: 0.74rem;
  font-weight: 700;
  padding: 0.28rem 0.65rem;
  border-radius: 20px;
  background: #F8FAFD;
  border: 1px solid #E2E8F0;
  color: #475569;
  cursor: pointer;
  transition: all 0.15s ease;
}

.cal-filter-chip:hover {
  background: #EFF6FF;
  border-color: #BFDBFE;
  color: var(--fareworks-blue);
}

.cal-filter-chip.active {
  background: var(--fareworks-blue);
  border-color: var(--fareworks-blue);
  color: #ffffff;
}

/* Calendar Selected Info Box */
.calendar-selected-summary {
  margin-top: 12px;
  padding: 10px 12px;
  background: #F8FAFD;
  border-radius: 8px;
  border-left: 3px solid var(--fareworks-blue);
  font-size: 0.78rem;
  color: #475569;
}

.cal-summary-date {
  font-weight: 800;
  color: #0F172A;
  margin-bottom: 2px;
}

.cal-summary-meta {
  color: #64748B;
  font-size: 0.74rem;
}

/* Appointment List Header & Toolbar */
.appointment-list-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  flex-wrap: wrap;
  gap: 8px;
}

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

.toolbar-title {
  font-size: 0.95rem;
  font-weight: 800;
  color: #0F172A;
}

.toolbar-count-badge {
  font-size: 0.74rem;
  font-weight: 700;
  padding: 0.15rem 0.55rem;
  border-radius: 12px;
  background: #EFF6FF;
  color: var(--fareworks-blue);
  border: 1px solid #BFDBFE;
}

/* Space-Efficient Low-Height Appointment Card (~68px - 74px) */
.appointment-card {
  background: #ffffff;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 8px 14px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  box-shadow: var(--shadow-card);
  transition: all 0.2s ease;
  margin-bottom: 8px;
}

.appointment-card:hover {
  border-color: #CBD5E1;
  box-shadow: var(--shadow-hover);
  transform: translateY(-1px);
}

.appointment-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
}

.bookings-list-container {
  min-width: 0;
  width: 100%;
}

#appointmentsListContainer {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
}

.appointment-main-group {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  flex: 1 1 auto;
  flex-wrap: wrap;
}

.customer-info-inline {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.customer-info-inline .customer-name {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--navy-dark);
  white-space: nowrap;
}

.slot-time-pill {
  flex-shrink: 0;
  font-size: 0.76rem;
  font-weight: 800;
  padding: 0.22rem 0.6rem;
  border-radius: 6px;
  background: #EFF6FF;
  border: 1px solid #BFDBFE;
  color: var(--fareworks-blue);
  white-space: nowrap;
}

.customer-info-inline {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.therapist-badge {
  font-size: 0.72rem;
  font-weight: 700;
  color: #047857;
  background: #ECFDF5;
  border: 1px solid #A7F3D0;
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
  white-space: nowrap;
}

.station-pill {
  font-size: 0.72rem;
  font-weight: 700;
  color: #475569;
  background: #F1F5F9;
  border: 1px solid #E2E8F0;
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
  white-space: nowrap;
}

.appointment-actions-group {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

/* Bottom Strip: Date badge, Note, Payment */
.appointment-bottom-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.79rem;
  color: #334155;
  background: #F8FAFD;
  border-left: 3px solid var(--fareworks-blue);
  padding: 0.28rem 0.75rem;
  border-radius: 0 6px 6px 0;
  min-width: 0;
}

.date-badge-sm {
  flex-shrink: 0;
  font-size: 0.72rem;
  font-weight: 700;
  color: #475569;
  background: #E2E8F0;
  padding: 0.12rem 0.45rem;
  border-radius: 4px;
  white-space: nowrap;
}

.payment-badge-sm {
  flex-shrink: 0;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.12rem 0.45rem;
  border-radius: 4px;
  white-space: nowrap;
}

.payment-badge-sm.paid {
  background: #ECFDF5;
  color: #047857;
  border: 1px solid #A7F3D0;
}

.payment-badge-sm.pending {
  background: #FEF3C7;
  color: #B45309;
  border: 1px solid #FDE68A;
}

/* Status Pill Dropdown Colors */
.status-select-pill.status-confirmed {
  background: #EFF6FF;
  color: #1D4ED8;
  border-color: #BFDBFE;
}

.status-select-pill.status-in-service {
  background: #FEF3C7;
  color: #B45309;
  border-color: #FCD34D;
}

.status-select-pill.status-completed {
  background: #ECFDF5;
  color: #047857;
  border-color: #A7F3D0;
}

.status-select-pill.status-rescheduled {
  background: #F5F3FF;
  color: #6D28D9;
  border-color: #DDD6FE;
}

.status-select-pill.status-cancelled {
  background: #F1F5F9;
  color: #64748B;
  border-color: #CBD5E1;
}

/* Empty State */
.appointments-empty-state {
  text-align: center;
  padding: 3rem 1.5rem;
  background: #ffffff;
  border: 1px dashed #CBD5E1;
  border-radius: var(--radius-md);
  color: #64748B;
}

.empty-state-icon {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
}

.empty-state-title {
  font-weight: 700;
  font-size: 1rem;
  color: #1E293B;
  margin-bottom: 0.25rem;
}

.empty-state-text {
  font-size: 0.85rem;
  color: #64748B;
  margin-bottom: 1rem;
}

@media (max-width: 768px) {
  .appointment-top-row {
    flex-wrap: wrap;
    gap: 8px;
  }
  .appointment-main-group {
    flex-wrap: wrap;
  }
  .appointment-actions-group {
    width: 100%;
    justify-content: flex-start;
  }
  .appointment-bottom-row {
    flex-wrap: wrap;
    font-size: 0.76rem;
  }
}

/* ==========================================================================
   WHATSAPP WEB CHAT SYSTEM & CRM LEAD INTEGRATION (OPTIMIZED)
   ========================================================================== */

.wa-web-container {
  display: flex;
  flex: 1 1 0;
  min-height: 0;
  height: 100%;
  width: 100%;
  background: #F0F2F5;
  overflow: hidden;
  position: relative;
}

/* Scrollbar styling for WhatsApp */
.wa-chat-list::-webkit-scrollbar,
.wa-messages-container::-webkit-scrollbar {
  width: 5px;
}

.wa-chat-list::-webkit-scrollbar-track,
.wa-messages-container::-webkit-scrollbar-track {
  background: transparent;
}

.wa-chat-list::-webkit-scrollbar-thumb,
.wa-messages-container::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.16);
  border-radius: 5px;
}

.wa-chat-list::-webkit-scrollbar-thumb:hover,
.wa-messages-container::-webkit-scrollbar-thumb:hover {
  background: rgba(0, 0, 0, 0.28);
}

/* --- Left Sidebar: Chat List --- */
.wa-sidebar {
  width: 380px;
  min-width: 320px;
  max-width: 420px;
  border-right: 1px solid #E2E8F0;
  background: #FFFFFF;
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
  flex-shrink: 0;
  z-index: 10;
}

.wa-sidebar-header {
  height: 58px;
  background: #F0F2F5;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #E2E8F0;
  flex-shrink: 0;
}

.wa-my-profile {
  display: flex;
  align-items: center;
  gap: 10px;
}

.wa-my-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--fareworks-blue);
  color: #FFFFFF;
  font-weight: 800;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.wa-my-info {
  display: flex;
  flex-direction: column;
}

.wa-my-name {
  font-size: 0.88rem;
  font-weight: 700;
  color: #111B21;
}

.wa-my-status {
  font-size: 0.72rem;
  color: #16A34A;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
}

.wa-online-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #16A34A;
  display: inline-block;
}

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

.wa-icon-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  color: #54656F;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.wa-icon-btn:hover {
  background: #E2E8F0;
  color: #111B21;
}

.wa-icon-btn svg {
  width: 20px;
  height: 20px;
}

/* Search bar & filter chips */
.wa-search-section {
  padding: 8px 12px;
  background: #FFFFFF;
  border-bottom: 1px solid #F0F2F5;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex-shrink: 0;
}

.wa-search-wrapper {
  background: #F0F2F5;
  border-radius: 8px;
  display: flex;
  align-items: center;
  padding: 0 12px;
  height: 36px;
  gap: 8px;
}

.wa-search-wrapper svg {
  width: 16px;
  height: 16px;
  color: #54656F;
  flex-shrink: 0;
}

.wa-search-input {
  border: none;
  background: transparent;
  width: 100%;
  font-size: 0.85rem;
  color: #111B21;
  outline: none;
  font-family: inherit;
}

.wa-filter-chips-row {
  display: flex;
  align-items: center;
  gap: 5px;
  overflow-x: auto;
  padding-bottom: 2px;
}

.wa-filter-chips-row::-webkit-scrollbar {
  display: none;
}

.wa-chip {
  padding: 0.22rem 0.6rem;
  border-radius: 16px;
  font-size: 0.72rem;
  font-weight: 700;
  background: #F0F2F5;
  color: #54656F;
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: all 0.15s ease;
}

.wa-chip:hover {
  background: #E2E8F0;
  color: #111B21;
}

.wa-chip.active {
  background: #00A884;
  color: #FFFFFF;
}

/* Chat list */
.wa-chat-list {
  flex: 1 1 0;
  min-height: 0;
  overflow-y: auto;
  background: #FFFFFF;
}

.wa-chat-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  cursor: pointer;
  border-bottom: 1px solid #F0F2F5;
  transition: background 0.15s ease;
  position: relative;
}

.wa-chat-item:hover {
  background: #F8FAFD;
}

.wa-chat-item.active {
  background: #EFF6FF;
  border-left: 4px solid var(--fareworks-blue);
}

.wa-chat-avatar-wrap {
  position: relative;
  flex-shrink: 0;
}

.wa-chat-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #E2E8F0;
  color: #1E293B;
  font-weight: 800;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid #CBD5E1;
}

.wa-chat-avatar.female {
  background: #FCE7F3;
  color: #9D174D;
  border-color: #FBCFE8;
}

.wa-chat-avatar.male {
  background: #E0E7FF;
  color: #3730A3;
  border-color: #C7D2FE;
}

.wa-chat-content {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
  overflow: hidden;
}

.wa-chat-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.wa-chat-name {
  font-size: 0.92rem;
  font-weight: 700;
  color: #111B21;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.wa-chat-time {
  font-size: 0.72rem;
  color: #667781;
  flex-shrink: 0;
  font-weight: 600;
}

.wa-chat-item.unread .wa-chat-time {
  color: #00A884;
  font-weight: 700;
}

.wa-chat-preview-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
}

.wa-chat-preview-text {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 0.78rem;
  color: #667781;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}

.wa-chat-preview-text.unread-text {
  color: #111B21;
  font-weight: 600;
}

.wa-chat-unread-badge {
  background: #25D366;
  color: #FFFFFF;
  font-size: 0.7rem;
  font-weight: 800;
  border-radius: 12px;
  min-width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
  flex-shrink: 0;
}

/* CRM Lead Status Tag on Chat List Item */
.wa-chat-meta-row {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 2px;
}

.wa-lead-tag {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.12rem 0.5rem;
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  white-space: nowrap;
}

.wa-lead-tag.tag-new-lead {
  background: #E0F2FE;
  color: #0369A1;
  border: 1px solid #BAE6FD;
}

.wa-lead-tag.tag-contacted {
  background: #FEF3C7;
  color: #B45309;
  border: 1px solid #FDE68A;
}

.wa-lead-tag.tag-booked {
  background: #ECFDF5;
  color: #047857;
  border: 1px solid #A7F3D0;
}

.wa-lead-tag.tag-walkin {
  background: #F3E8FF;
  color: #6B21A8;
  border: 1px solid #E9D5FF;
}

.wa-lead-tag.tag-customer {
  background: #EFF6FF;
  color: #1D4ED8;
  border: 1px solid #BFDBFE;
}

.wa-lead-tag.tag-lost {
  background: #F1F5F9;
  color: #64748B;
  border: 1px solid #CBD5E1;
}

/* --- Right Side: Active Chat Area --- */
.wa-chat-area {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  height: 100%;
  background: #EFEAE2;
  position: relative;
}

/* Chat Header */
.wa-chat-topbar {
  height: 60px;
  background: #F0F2F5;
  border-bottom: 1px solid #E2E8F0;
  padding: 8px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  z-index: 5;
  flex-shrink: 0;
}

.wa-current-contact {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.wa-top-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #CBD5E1;
  color: #0F172A;
  font-weight: 800;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.wa-top-avatar.female {
  background: #FCE7F3;
  color: #9D174D;
  border: 1px solid #FBCFE8;
}

.wa-top-avatar.male {
  background: #E0E7FF;
  color: #3730A3;
  border: 1px solid #C7D2FE;
}

.wa-top-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.wa-top-name {
  font-size: 0.95rem;
  font-weight: 800;
  color: #111B21;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.wa-top-sub {
  font-size: 0.74rem;
  color: #667781;
  white-space: nowrap;
}

/* CRM Quick Lead Toolbar in Chat Header */
.wa-chat-crm-toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.wa-lead-status-select {
  height: 34px;
  padding: 0 1.8rem 0 0.8rem;
  font-size: 0.78rem;
  font-weight: 700;
  border-radius: 6px;
  border: 1.5px solid #BFDBFE;
  background-color: #EFF6FF;
  color: #1D4ED8;
  cursor: pointer;
  outline: none;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 20 20' fill='%231D4ED8'%3E%3Cpath fill-rule='evenodd' d='M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z' clip-rule='evenodd'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.7rem center;
  transition: all 0.2s ease;
}

.wa-lead-status-select:hover {
  border-color: var(--fareworks-blue);
  box-shadow: 0 2px 8px rgba(1, 14, 208, 0.15);
}

.btn-wa-make-lead {
  height: 34px;
  background: var(--fareworks-blue);
  color: #FFFFFF;
  border: none;
  padding: 0 12px;
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.15s ease;
  white-space: nowrap;
  box-shadow: 0 2px 6px rgba(1, 14, 208, 0.18);
}

.btn-wa-make-lead:hover {
  background: #010BBB;
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(1, 14, 208, 0.25);
}

.btn-wa-book-appt {
  height: 34px;
  background: #00A884;
  color: #FFFFFF;
  border: none;
  padding: 0 12px;
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.15s ease;
  white-space: nowrap;
  box-shadow: 0 2px 6px rgba(0, 168, 132, 0.18);
}

.btn-wa-book-appt:hover {
  background: #008f6f;
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(0, 168, 132, 0.25);
}

.btn-wa-call {
  width: 34px;
  height: 34px;
  background: #FFFFFF;
  border: 1.5px solid #CBD5E1;
  border-radius: 6px;
  color: #00A884;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
  text-decoration: none;
}

.btn-wa-call:hover {
  border-color: #00A884;
  background: #F0FDF4;
  color: #008f6f;
}

.btn-wa-call svg {
  width: 16px;
  height: 16px;
}

/* Chat Messages Container */
.wa-messages-container {
  flex: 1 1 0;
  min-height: 0;
  overflow-y: auto;
  padding: 18px 30px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background-color: #EFEAE2;
  background-image: url('https://user-images.githubusercontent.com/15075759/28719144-86dc0f70-73b1-11e7-911d-60d70fcded21.png');
  background-repeat: repeat;
  background-size: 380px;
  background-blend-mode: overlay;
}

/* Date Divider */
.wa-date-divider {
  align-self: center;
  background: rgba(255, 255, 255, 0.95);
  padding: 4px 14px;
  border-radius: 8px;
  font-size: 0.72rem;
  font-weight: 700;
  color: #54656F;
  box-shadow: 0 1px 2px rgba(11, 20, 26, 0.12);
  margin: 6px 0;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Message Bubble */
.wa-msg-bubble {
  max-width: 65%;
  padding: 7px 12px 6px 12px;
  border-radius: 8px;
  font-size: 0.88rem;
  line-height: 1.4;
  color: #111B21;
  position: relative;
  box-shadow: 0 1px 1px rgba(11, 20, 26, 0.13);
  word-wrap: break-word;
}

.wa-msg-incoming {
  align-self: flex-start;
  background: #FFFFFF;
  border-top-left-radius: 0;
}

.wa-msg-outgoing {
  align-self: flex-end;
  background: #D9FDD3;
  border-top-right-radius: 0;
}

.wa-msg-meta {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  margin-top: 3px;
  float: right;
  margin-left: 10px;
  vertical-align: bottom;
}

.wa-msg-time {
  font-size: 0.68rem;
  color: #667781;
}

.wa-ticks-svg {
  width: 15px;
  height: 15px;
  color: #53BDEB;
}

/* Rich Template Card inside message */
.wa-rich-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 8px;
  padding: 10px 12px;
  margin-top: 6px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.wa-rich-card-title {
  font-weight: 800;
  font-size: 0.85rem;
  color: var(--fareworks-blue);
  display: flex;
  align-items: center;
  gap: 6px;
}

.wa-rich-card-desc {
  font-size: 0.8rem;
  color: #334155;
}

.wa-rich-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px dashed #CBD5E1;
  padding-top: 6px;
  margin-top: 4px;
  font-size: 0.74rem;
  font-weight: 700;
  color: #64748B;
}

/* Chat Footer / Input area */
.wa-chat-footer {
  background: #F0F2F5;
  border-top: 1px solid #E2E8F0;
  padding: 8px 20px 14px 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 5;
  flex-shrink: 0;
}

/* Quick reply pills */
.wa-quick-replies-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 2px;
}

.wa-quick-replies-bar::-webkit-scrollbar {
  display: none;
}

.wa-quick-pill {
  font-size: 0.74rem;
  font-weight: 700;
  padding: 0.24rem 0.68rem;
  background: #FFFFFF;
  border: 1px solid #CBD5E1;
  border-radius: 14px;
  color: #334155;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: all 0.15s ease;
  box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}

.wa-quick-pill:hover {
  background: #EFF6FF;
  border-color: #BFDBFE;
  color: var(--fareworks-blue);
  transform: translateY(-1px);
}

.wa-input-row {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
}

.wa-message-input {
  flex: 1 1 auto;
  height: 44px;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 8px;
  padding: 0 16px;
  font-size: 0.92rem;
  font-family: inherit;
  color: #111B21;
  outline: none;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
  transition: border-color 0.2s ease;
}

.wa-message-input:focus {
  border-color: #00A884;
}

.wa-message-input::placeholder {
  color: #8696A0;
}

.wa-send-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #00A884;
  border: none;
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(0, 168, 132, 0.3);
}

.wa-send-btn:hover {
  background: #008f6f;
  transform: scale(1.05);
}

.wa-send-btn svg {
  width: 19px;
  height: 19px;
  fill: currentColor;
}

.wa-back-btn {
  display: none;
}

.wa-floating-btn {
  display: none;
}

.wa-floating-btn svg {
  width: 18px;
  height: 18px;
}

/* Responsive WhatsApp Web */
@media (max-width: 900px) {
  .wa-sidebar {
    width: 300px;
  }
  .wa-chat-crm-toolbar .btn-wa-book-appt {
    display: none;
  }
}

@media (max-width: 768px) {
  /* WhatsApp Master-Detail Container on Mobile */
  .dashboard-container {
    height: calc(100dvh - 68px) !important;
    max-height: calc(100vh - 68px) !important;
    overflow: hidden !important;
  }

  .wa-web-container {
    position: relative !important;
    width: 100% !important;
    height: calc(100% - 44px) !important;
    flex: 1 1 auto !important;
    overflow: hidden !important;
  }

  /* Screen 1: Sidebar (Contacts / Chat List) */
  .wa-sidebar {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 100% !important;
    position: absolute !important;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10 !important;
    background: #FFFFFF !important;
    display: flex !important;
    flex-direction: column !important;
    border-right: none !important;
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
  }

  /* Screen 2: Single Conversation Pane */
  .wa-chat-area {
    position: absolute !important;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100% !important;
    height: 100% !important;
    z-index: 20 !important;
    background: #EFEAE2 !important;
    display: flex !important;
    flex-direction: column !important;
    transform: translateX(100%) !important;
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
  }

  /* Active Chat Mode on Mobile (Transitions smoothly from Contacts List to Chat) */
  .wa-web-container.show-chat .wa-sidebar {
    transform: translateX(-20%) !important;
    pointer-events: none !important;
  }

  .wa-web-container.show-chat .wa-chat-area {
    transform: translateX(0) !important;
    pointer-events: auto !important;
  }

  /* Chat Top Bar on Mobile */
  .wa-chat-topbar {
    height: 52px !important;
    padding: 6px 10px !important;
    background: #F0F2F5 !important;
    border-bottom: 1px solid #E2E8F0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 8px !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .wa-back-btn {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 32px !important;
    height: 32px !important;
    border-radius: 50% !important;
    border: none !important;
    background: transparent !important;
    color: #1E293B !important;
    cursor: pointer !important;
    flex-shrink: 0 !important;
    padding: 0 !important;
  }

  .wa-back-btn svg {
    width: 20px !important;
    height: 20px !important;
  }

  .wa-current-contact {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    flex: 1 1 auto !important;
    min-width: 0 !important;
    overflow: hidden !important;
  }

  .wa-top-avatar {
    width: 36px !important;
    height: 36px !important;
    font-size: 0.85rem !important;
    font-weight: 800 !important;
    flex-shrink: 0 !important;
  }

  .wa-top-info {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    overflow: hidden !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 1px !important;
  }

  .wa-top-name {
    font-size: 0.90rem !important;
    font-weight: 800 !important;
    color: #111B21 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  .wa-top-sub {
    font-size: 0.70rem !important;
    color: #64748B !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  .wa-chat-crm-toolbar {
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    flex-shrink: 0 !important;
  }

  .wa-lead-status-pill {
    height: 30px !important;
    padding: 0 8px !important;
    font-size: 0.72rem !important;
    font-weight: 700 !important;
    border-radius: 9999px !important;
    border: 1.5px solid #CBD5E1 !important;
    background: #FFFFFF !important;
    color: #1E293B !important;
    cursor: pointer !important;
  }

  .btn-wa-call {
    width: 32px !important;
    height: 32px !important;
    border-radius: 50% !important;
    background: #FFFFFF !important;
    border: 1.5px solid #E2E8F0 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: var(--fareworks-blue) !important;
    flex-shrink: 0 !important;
  }

  .btn-wa-call svg {
    width: 16px !important;
    height: 16px !important;
  }

  .btn-wa-make-lead.desktop-only,
  .btn-wa-book-appt.desktop-only {
    display: none !important;
  }

  /* Floating Action Button (New Chat in Contacts List) */
  .wa-floating-btn {
    position: absolute !important;
    bottom: 24px !important;
    right: 18px !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    background: #00A884 !important;
    color: #FFFFFF !important;
    border: none !important;
    padding: 10px 18px !important;
    border-radius: 24px !important;
    font-family: inherit !important;
    font-size: 0.84rem !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    box-shadow: 0 4px 14px rgba(0, 168, 132, 0.45) !important;
    z-index: 25 !important;
    transition: transform 0.2s ease, box-shadow 0.2s ease !important;
  }

  .wa-floating-btn:active {
    transform: scale(0.95) !important;
  }

  .wa-floating-btn svg {
    width: 18px !important;
    height: 18px !important;
  }

  /* Chat Footer on Mobile */
  .wa-chat-footer {
    padding: 6px 10px 8px 10px !important;
    gap: 6px !important;
    background: #F0F2F5 !important;
  }

  .wa-quick-replies-bar {
    padding-bottom: 2px !important;
    gap: 4px !important;
  }

  .wa-quick-pill {
    font-size: 0.70rem !important;
    padding: 3px 8px !important;
  }

  .wa-input-row {
    gap: 6px !important;
  }

  .wa-message-input {
    height: 38px !important;
    font-size: 0.84rem !important;
  }

  .wa-send-btn {
    width: 38px !important;
    height: 38px !important;
  }
}

/* ==========================================================================
   4 STICKY CORNER BUTTONS DOCK (WHATSAPP, FOLLOW-UP, BOOKINGS, ADD LEAD)
   ========================================================================== */

/* ==========================================================================
   STICKY CORNER ICON DOCK (SINGLE COLUMN, ICON-ONLY, NO TEXT)
   ========================================================================== */

.sticky-corner-dock {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column; /* SINGLE VERTICAL COLUMN */
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.90);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  padding: 8px 6px;
  border-radius: 32px;
  border: 1px solid rgba(203, 213, 225, 0.85);
  box-shadow: 0 12px 30px -4px rgba(15, 23, 42, 0.20), 0 4px 12px -2px rgba(15, 23, 42, 0.10);
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.sticky-corner-dock:hover {
  box-shadow: 0 16px 36px -4px rgba(15, 23, 42, 0.26), 0 6px 16px -2px rgba(15, 23, 42, 0.14);
  background: rgba(255, 255, 255, 0.96);
}

.dock-btn {
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 50%; /* CIRCLE ICON BUTTON */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #FFFFFF;
  text-decoration: none;
  border: none;
  cursor: pointer;
  position: relative;
  transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-sizing: border-box;
}

.dock-btn:hover {
  transform: scale(1.12);
}

.dock-btn:active {
  transform: scale(0.96);
}

/* Strictly hide text labels as requested */
.dock-btn-label {
  display: none !important;
}

.dock-btn-icon-wrap {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.dock-btn-icon-wrap svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.dock-btn-booking svg,
.dock-btn-lead svg {
  stroke: #FFFFFF;
}

/* 1. WhatsApp Button (Green with Red Pulse Badge) */
.dock-btn-whatsapp {
  background: linear-gradient(135deg, #25D366 0%, #059669 100%);
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.40);
}

.dock-btn-whatsapp:hover {
  background: linear-gradient(135deg, #20BD5A 0%, #047857 100%);
  box-shadow: 0 6px 16px rgba(37, 211, 102, 0.55);
}

/* 2. Follow-ups Button (Amber with Pending Badge) */
.dock-btn-followup {
  background: linear-gradient(135deg, #F59E0B 0%, #D97706 100%);
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.40);
}

.dock-btn-followup:hover {
  background: linear-gradient(135deg, #D97706 0%, #B45309 100%);
  box-shadow: 0 6px 16px rgba(245, 158, 11, 0.55);
}

/* 3. Bookings Button (Purple / Indigo) */
.dock-btn-booking {
  background: linear-gradient(135deg, #6366F1 0%, #4F46E5 100%);
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.40);
}

.dock-btn-booking:hover {
  background: linear-gradient(135deg, #4F46E5 0%, #4338CA 100%);
  box-shadow: 0 6px 16px rgba(99, 102, 241, 0.55);
}

/* 4. Add Lead Button (Fareworks Blue) */
.dock-btn-lead {
  background: linear-gradient(135deg, #010ED0 0%, #1522DE 100%);
  box-shadow: 0 4px 12px rgba(1, 14, 208, 0.40);
}

.dock-btn-lead:hover {
  background: linear-gradient(135deg, #010BBB 0%, #010ED0 100%);
  box-shadow: 0 6px 16px rgba(1, 14, 208, 0.55);
}

/* Notification Badges on Circular Dock Buttons */
.dock-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  font-size: 0.65rem;
  font-weight: 800;
  border-radius: 10px;
  min-width: 17px;
  height: 17px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  color: #FFFFFF;
  border: 1.5px solid #FFFFFF;
  box-shadow: 0 2px 6px rgba(0,0,0,0.30);
  line-height: 1;
  pointer-events: none;
}

.dock-badge.badge-red {
  background: #EF4444;
  animation: dockPulse 2s infinite;
}

.dock-badge.badge-amber {
  background: #DC2626;
}

@keyframes dockPulse {
  0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.7); }
  70% { transform: scale(1.12); box-shadow: 0 0 0 6px rgba(239, 68, 68, 0); }
  100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); }
}

/* Responsive adjustment for small screens */
@media (max-width: 768px) {
  .sticky-corner-dock {
    right: 14px;
    bottom: 16px;
    gap: 8px;
    padding: 6px 5px;
  }
  .dock-btn {
    width: 40px;
    height: 40px;
  }
  .dock-btn-icon-wrap svg {
    width: 18px;
    height: 18px;
  }
}

/* On WhatsApp Web CRM page, elevate vertical dock so typing input remains 100% visible */
.sticky-corner-dock.dock-wa-page {
  bottom: 84px;
  right: 20px;
}

@media (max-width: 768px) {
  .sticky-corner-dock.dock-wa-page {
    bottom: 88px;
    right: 12px;
  }
}

/* ==========================================================================
   MANAGEMENT HUB DROPDOWN & MODAL (REPORTS, SERVICES, PACKAGES, STAFF, INVENTORY)
   ========================================================================== */

.nav-dropdown-wrapper {
  position: relative;
  display: inline-flex;
}

.nav-dropdown-btn {
  background: transparent;
  border: none;
  font-family: inherit;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}

.nav-dropdown-btn .dropdown-chevron {
  width: 13px;
  height: 13px;
  transition: transform 0.2s ease;
}

.nav-dropdown-btn[aria-expanded="true"] .dropdown-chevron {
  transform: rotate(180deg);
}

.nav-dropdown-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 295px;
  background: #FFFFFF;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  box-shadow: 0 16px 36px -6px rgba(10, 13, 49, 0.18), 0 6px 14px -3px rgba(10, 13, 49, 0.08);
  padding: 6px 0;
  display: none;
  z-index: 300;
  animation: fadeInSlide 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-dropdown-menu.active {
  display: block;
}

.manage-dropdown-header {
  padding: 8px 16px 6px 16px;
  border-bottom: 1px solid #F1F5F9;
  margin-bottom: 4px;
}

.manage-dropdown-title {
  font-size: 0.70rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}

.manage-dropdown-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 16px;
  color: var(--navy-dark);
  text-decoration: none;
  transition: all 0.15s ease;
}

.manage-dropdown-item:hover {
  background: #F8FAFC;
}

.manage-item-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.manage-item-icon svg {
  width: 17px;
  height: 17px;
}

.manage-item-info {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.manage-item-name {
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--navy-dark);
}

.manage-item-desc {
  font-size: 0.72rem;
  color: var(--text-muted);
}

/* Manage Hub Modal Card */
.manage-hub-modal .modal-card {
  max-width: 860px;
  width: 95%;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  padding: 0;
  overflow: hidden;
  border-radius: var(--radius-lg);
}

.manage-hub-header {
  padding: 16px 24px;
  border-bottom: 1px solid #E2E8F0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #FAFAFD;
}

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

.manage-hub-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--navy-dark);
  margin: 0;
}

.manage-hub-nav {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 20px;
  background: #FFFFFF;
  border-bottom: 1px solid #E2E8F0;
  overflow-x: auto;
}

.manage-tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 14px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-muted);
  border-radius: 8px;
  border: none;
  background: transparent;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.manage-tab-btn:hover {
  color: var(--fareworks-blue);
  background: var(--fareworks-blue-light);
}

.manage-tab-btn.active {
  color: var(--fareworks-blue);
  background: var(--fareworks-blue-light);
  font-weight: 800;
}

.manage-tab-btn svg {
  width: 15px;
  height: 15px;
}

.manage-hub-body {
  padding: 22px 24px;
  overflow-y: auto;
  flex: 1 1 0;
  min-height: 320px;
}

.manage-tab-pane {
  display: none;
}

.manage-tab-pane.active {
  display: block;
  animation: fadeInSlide 0.2s ease;
}

/* Hub Mini Table / Cards */
.hub-grid-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.hub-metric-card {
  background: #F8FAFC;
  border: 1px solid #E2E8F0;
  border-radius: 10px;
  padding: 14px 16px;
}

.hub-metric-card .num {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--navy-dark);
}

.hub-metric-card .label {
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-top: 2px;
}

.hub-list-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border: 1px solid #E2E8F0;
  border-radius: 8px;
  margin-bottom: 8px;
  background: #FFFFFF;
  transition: background 0.15s ease;
}

.hub-list-row:hover {
  background: #F8FAFC;
}

.hub-row-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.hub-row-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--navy-dark);
}

.hub-row-sub {
  font-size: 0.74rem;
  color: var(--text-muted);
}

.hub-badge {
  font-size: 0.72rem;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 6px;
}

.hub-badge-green {
  background: #ECFDF5;
  color: #059669;
}

.hub-badge-blue {
  background: var(--fareworks-blue-light);
  color: var(--fareworks-blue);
}

.hub-badge-amber {
  background: #FEF3C7;
  color: #D97706;
}

/* ==========================================================================
   CLEAN LEFT-SIDE STICKY SIDEBAR (MATCHING USER REFERENCE DESIGN)
   ========================================================================== */

.sidebar-overlay-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  z-index: 99998;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.sidebar-overlay-backdrop.active {
  opacity: 1;
  visibility: visible;
}

.app-left-sidebar {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: 250px;
  background: #FFFFFF;
  border-right: 1px solid #E2E8F0;
  z-index: 99999;
  box-shadow: 12px 0 35px rgba(10, 13, 49, 0.16);
  display: flex;
  flex-direction: column;
  transform: translateX(-100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  overflow-y: auto;
}

.app-left-sidebar.active {
  transform: translateX(0);
}

.left-sidebar-header {
  padding: 20px 18px 16px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.left-sidebar-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.left-sidebar-brand-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, #4F46E5 0%, #3730A3 100%);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 4px 10px rgba(79, 70, 229, 0.3);
}

.left-sidebar-brand-icon svg {
  width: 19px;
  height: 19px;
}

.left-sidebar-title {
  font-size: 1.12rem;
  font-weight: 800;
  color: #0F172A;
  letter-spacing: -0.01em;
}

.left-sidebar-close {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: 1px solid #E2E8F0;
  background: #F8FAFC;
  color: #64748B;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.9rem;
  transition: all 0.15s ease;
}

.left-sidebar-close:hover {
  background: #FEE2E2;
  color: #EF4444;
  border-color: #FECACA;
}

.left-sidebar-body {
  padding: 8px 12px 20px 12px;
  flex: 1 1 0;
  display: flex;
  flex-direction: column;
}

.sidebar-menu-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.sidebar-menu-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 0.92rem;
  font-weight: 600;
  color: #334155;
  text-decoration: none;
  transition: all 0.15s ease;
  cursor: pointer;
}

.sidebar-menu-item:hover {
  background: #F8FAFC;
  color: #0F172A;
}

.sidebar-menu-item.active {
  background: #F0F3FF;
  color: #4F46E5;
  font-weight: 700;
}

.sidebar-menu-item svg {
  width: 19px;
  height: 19px;
  color: #64748B;
  flex-shrink: 0;
  transition: color 0.15s ease;
}

.sidebar-menu-item.active svg {
  color: #4F46E5;
}

.sidebar-menu-item:hover svg {
  color: #1E293B;
}

/* Nav icon-only button in top navigation bar */
.nav-icon-only-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 8px 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  color: var(--navy-dark);
  transition: all 0.15s ease;
}

.nav-icon-only-btn:hover {
  background: rgba(1, 14, 208, 0.08);
  color: var(--fareworks-blue);
}

.nav-icon-only-btn.active {
  background: var(--fareworks-blue);
  color: #FFFFFF;
}

.nav-icon-only-btn svg {
  width: 18px;
  height: 18px;
}

/* ==========================================================================
   SETUP PAGE LAYOUT (STICKY SIDEBAR PART OF THE PAGE + RIGHT CONTENT)
   ========================================================================== */

.setup-layout-wrapper {
  display: flex;
  flex: 1 1 0;
  min-height: 0;
  height: calc(100vh - 66px);
  width: 100%;
  overflow: hidden;
  background: #F8FAFC;
}

/* Left Sticky Sidebar - Permanent part of the page layout */
.setup-sticky-sidebar {
  width: 250px;
  min-width: 250px;
  background: #FFFFFF;
  border-right: 1px solid #E2E8F0;
  display: flex;
  flex-direction: column;
  padding: 24px 14px 24px 16px;
  height: 100%;
  overflow-y: auto;
  flex-shrink: 0;
}

.sidebar-header-box {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
  padding: 0 4px;
}

.sidebar-brand-badge {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, #4F46E5 0%, #3730A3 100%);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 4px 10px rgba(79, 70, 229, 0.28);
}

.sidebar-brand-badge svg {
  width: 18px;
  height: 18px;
}

.sidebar-brand-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: #0F172A;
  letter-spacing: -0.01em;
}

.sidebar-nav-menu {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.sidebar-menu-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 0.92rem;
  font-weight: 600;
  color: #334155;
  background: transparent;
  border: none;
  cursor: pointer;
  text-align: left;
  transition: all 0.15s ease;
  font-family: inherit;
}

.sidebar-menu-btn:hover {
  background: #F1F5F9;
  color: #0F172A;
}

.sidebar-menu-btn.active {
  background: #F0F3FF;
  color: #4F46E5;
  font-weight: 700;
}

.sidebar-menu-btn svg {
  width: 19px;
  height: 19px;
  color: #64748B;
  flex-shrink: 0;
  transition: color 0.15s ease;
}

.sidebar-menu-btn.active svg {
  color: #4F46E5;
}

.sidebar-menu-btn:hover svg {
  color: #0F172A;
}

/* Right Content Area */
.setup-main-content {
  flex: 1 1 0;
  min-width: 0;
  height: 100%;
  overflow-y: auto;
  padding: 24px 32px 60px 32px;
}

.setup-pane {
  display: none;
}

.setup-pane.active {
  display: block;
  animation: fadeIn 0.2s ease;
}

.setup-view-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 12px;
}

.setup-view-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--navy-dark);
  margin: 0 0 4px 0;
}

.setup-view-subtitle {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin: 0;
}

/* Filter pills row in setup */
.setup-pills-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  overflow-x: auto;
}

.setup-filter-pill {
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid #E2E8F0;
  background: #FFFFFF;
  color: #475569;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.setup-filter-pill:hover {
  border-color: #CBD5E1;
  color: var(--navy-dark);
}

.setup-filter-pill.active {
  background: var(--navy-dark);
  color: #FFFFFF;
  border-color: var(--navy-dark);
}

/* Service Card / Table Row styles in Setup */
.setup-grid-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 16px;
  margin-top: 14px;
}

.setup-item-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  padding: 18px 20px;
  box-shadow: 0 2px 6px rgba(10, 13, 49, 0.03);
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.setup-item-card:hover {
  box-shadow: 0 8px 20px rgba(10, 13, 49, 0.08);
  border-color: #CBD5E1;
  transform: translateY(-2px);
}

.setup-item-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

.setup-item-name {
  font-size: 1rem;
  font-weight: 800;
  color: var(--navy-dark);
}

.setup-item-desc {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.45;
  margin-bottom: 14px;
}

.setup-item-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid #F1F5F9;
  padding-top: 12px;
  margin-top: auto;
}

.setup-item-price {
  font-size: 1.15rem;
  font-weight: 800;
  color: #059669;
}

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

.setup-pill {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
  background: #F1F5F9;
  color: #475569;
}

@media (max-width: 820px) {
  .setup-layout-wrapper {
    flex-direction: column;
    height: auto;
    overflow-y: auto;
  }
  .setup-sticky-sidebar {
    width: 100%;
    min-width: 100%;
    height: auto;
    border-right: none;
    border-bottom: 1px solid #E2E8F0;
    padding: 6px 12px;
  }
  .setup-sticky-sidebar .sidebar-section-title {
    display: none !important;
  }
  .sidebar-header-box {
    display: none !important;
  }
  .sidebar-nav-menu {
    flex-direction: row;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    gap: 6px;
    padding: 2px 0;
  }
  .sidebar-nav-menu::-webkit-scrollbar {
    display: none;
  }
  .sidebar-menu-btn {
    width: auto;
    white-space: nowrap;
    padding: 6px 12px;
    font-size: 0.8rem;
    border-radius: 8px;
  }
  .setup-main-content {
    padding: 14px 12px 60px 12px;
  }
}

/* ==========================================================================
   ENHANCED SETUP & OPERATIONS SUITE STYLES (v2.1)
   ========================================================================== */

.sidebar-section-title {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #94A3B8;
  padding: 14px 10px 4px 10px;
}

.sidebar-menu-badge {
  margin-left: auto;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 9999px;
  background: #F1F5F9;
  color: #64748B;
  transition: all 0.15s ease;
}

.sidebar-menu-btn.active .sidebar-menu-badge {
  background: #E0E7FF;
  color: #4F46E5;
}

/* Metric KPI grid & cards */
.setup-metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.setup-metric-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  padding: 16px 18px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.03);
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: transform 0.15s ease;
}

.setup-metric-card:hover {
  transform: translateY(-1px);
}

.setup-metric-val {
  font-size: 1.55rem;
  font-weight: 800;
  color: #0F172A;
  line-height: 1.2;
}

.setup-metric-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: #64748B;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.setup-metric-trend {
  font-size: 0.75rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.setup-metric-trend.positive { color: #059669; }
.setup-metric-trend.neutral { color: #64748B; }

/* Setup Data Tables */
.setup-table-wrapper {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  overflow-x: auto;
  box-shadow: 0 1px 3px rgba(0,0,0,0.03);
  margin-bottom: 24px;
}

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

.setup-table th {
  background: #F8FAFC;
  padding: 12px 16px;
  font-size: 0.74rem;
  font-weight: 700;
  color: #64748B;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-bottom: 1px solid #E2E8F0;
  white-space: nowrap;
}

.setup-table td {
  padding: 14px 16px;
  border-bottom: 1px solid #F1F5F9;
  color: #1E293B;
  vertical-align: middle;
}

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

.setup-table tr:hover td {
  background: #F8FAFC;
}

/* Toggle Switch for Workflows */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
  flex-shrink: 0;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  cursor: pointer;
  top: 0; left: 0; right: 0; bottom: 0;
  background-color: #CBD5E1;
  transition: .2s;
  border-radius: 24px;
}

.toggle-slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: .2s;
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.toggle-switch input:checked + .toggle-slider {
  background-color: #22C55E;
}

.toggle-switch input:checked + .toggle-slider:before {
  transform: translateX(20px);
}

/* WhatsApp Template card */
.template-grid-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 18px;
}

.template-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: all 0.2s ease;
}

.template-card:hover {
  border-color: #CBD5E1;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.template-preview-bubble {
  background: #F0FDF4;
  border-radius: 8px 8px 8px 0;
  padding: 12px 14px;
  font-size: 0.83rem;
  line-height: 1.5;
  color: #111827;
  border: 1px solid #BBF7D0;
  font-family: inherit;
}

.template-preview-bubble strong {
  color: #065F46;
}

/* Workflow cards */
.workflow-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: all 0.2s ease;
  margin-bottom: 14px;
}

.workflow-card:hover {
  border-color: #CBD5E1;
  box-shadow: 0 4px 12px rgba(0,0,0,0.04);
}

.workflow-step-chain {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.workflow-step-badge {
  background: #F8FAFC;
  border: 1px solid #E2E8F0;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 0.78rem;
  font-weight: 600;
  color: #334155;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.workflow-arrow {
  color: #94A3B8;
  font-weight: bold;
}

/* Staff & Contacts cards */
.staff-grid-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 18px;
}

.staff-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: all 0.2s ease;
}

.staff-card:hover {
  border-color: #CBD5E1;
  box-shadow: 0 4px 12px rgba(0,0,0,0.04);
}

.staff-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
}

.staff-avatar-circle {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, #010ED0 0%, #3B82F6 100%);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.95rem;
  flex-shrink: 0;
}

/* ==========================================================================
   MOBILE BOTTOM NAVIGATION BAR (Luxury App Experience)
   ========================================================================== */
.mobile-bottom-nav {
  display: none;
}

@media (max-width: 768px) {
  /* Hide desktop header-nav on mobile since bottom footer menu takes over */
  .header-nav {
    display: none !important;
  }

  /* Hide floating corner dock on mobile to eliminate overlap */
  .sticky-corner-dock {
    display: none !important;
  }

  /* Provide bottom clearance for fixed mobile navigation bar */
  body {
    padding-bottom: 78px !important;
  }

  .setup-layout-wrapper {
    margin-bottom: 78px !important;
    height: calc(100vh - 56px - 78px) !important;
  }

  .wa-chat-footer {
    bottom: 68px !important;
  }

  /* Refined Header on Mobile */
  header.app-header {
    display: flex !important;
    flex-direction: row !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding: 10px 18px !important;
    height: 56px !important;
    min-height: 56px !important;
    background: #FFFFFF !important;
    border-bottom: 1px solid rgba(226, 232, 240, 0.9) !important;
    box-shadow: 0 1px 4px rgba(15, 23, 42, 0.04) !important;
    position: sticky !important;
    top: 0 !important;
    z-index: 100 !important;
  }

  .logo-container {
    display: flex !important;
    align-items: center !important;
    flex-shrink: 0 !important;
  }

  .logo-img {
    height: 30px !important;
    max-height: 30px !important;
    width: auto !important;
    object-fit: contain !important;
    display: block !important;
  }

  .header-right-actions {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    margin-left: auto !important;
    flex-shrink: 0 !important;
  }

  /* Refined Notification Button */
  .notification-btn {
    width: 38px !important;
    height: 38px !important;
    border-radius: 50% !important;
    background: #F8FAFC !important;
    border: 1px solid #E2E8F0 !important;
    color: #334155 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04) !important;
    transition: all 0.15s ease !important;
    padding: 0 !important;
  }

  .notification-btn:active {
    background: #F1F5F9 !important;
    transform: scale(0.96) !important;
  }

  .notification-btn svg {
    width: 19px !important;
    height: 19px !important;
    stroke-width: 2 !important;
  }

  .notification-badge-dot {
    width: 8px !important;
    height: 8px !important;
    background: #EF4444 !important;
    border: 2px solid #FFFFFF !important;
    border-radius: 50% !important;
    top: 8px !important;
    right: 8px !important;
  }

  /* Refined Profile Avatar */
  .user-profile-btn {
    padding: 0 !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    border-radius: 50% !important;
  }

  .user-avatar-circle {
    width: 38px !important;
    height: 38px !important;
    border-radius: 50% !important;
    background: linear-gradient(135deg, #010ED0 0%, #3B82F6 100%) !important;
    color: #FFFFFF !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border: 2px solid #FFFFFF !important;
    box-shadow: 0 2px 8px rgba(1, 14, 208, 0.28) !important;
    font-weight: 800 !important;
    font-size: 0.85rem !important;
    letter-spacing: 0.02em !important;
    transition: transform 0.15s ease !important;
  }

  .user-avatar-circle:active {
    transform: scale(0.96) !important;
  }

  .user-avatar-circle svg {
    width: 19px !important;
    height: 19px !important;
    stroke: #FFFFFF !important;
  }

  /* Mobile Bottom Navigation Bar */
  .mobile-bottom-nav {
    display: flex !important;
    align-items: center !important;
    justify-content: space-around !important;
    position: fixed !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    height: 68px !important;
    background: rgba(255, 255, 255, 0.98) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    border-top: 1px solid rgba(226, 232, 240, 0.9) !important;
    border-radius: 20px 20px 0 0 !important;
    box-shadow: 0 -8px 25px rgba(15, 23, 42, 0.08) !important;
    z-index: 9999 !important;
    padding: 0 10px max(8px, env(safe-area-inset-bottom)) !important;
  }

  .mobile-nav-item {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    flex: 1 !important;
    height: 100% !important;
    text-decoration: none !important;
    color: #64748B !important;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
    position: relative !important;
    padding-top: 4px !important;
    user-select: none !important;
    -webkit-tap-highlight-color: transparent !important;
  }

  .mobile-nav-icon-wrap {
    position: relative !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 28px !important;
    height: 28px !important;
  }

  .mobile-nav-item svg {
    width: 22px !important;
    height: 22px !important;
    color: #64748B !important;
    stroke-width: 1.9 !important;
    transition: all 0.2s ease !important;
  }

  .mobile-nav-label {
    font-size: 0.69rem !important;
    font-weight: 600 !important;
    margin-top: 3px !important;
    letter-spacing: -0.01em !important;
    color: #64748B !important;
    transition: color 0.15s ease !important;
  }

  /* Active Nav State */
  .mobile-nav-item.active svg {
    color: var(--fareworks-blue) !important;
    stroke-width: 2.3 !important;
    transform: translateY(-1px) !important;
  }

  .mobile-nav-item.active .mobile-nav-label {
    font-weight: 800 !important;
    color: var(--fareworks-blue) !important;
  }



  /* Follow-ups & Alerts Badge */
  .mobile-nav-badge {
    position: absolute !important;
    top: -2px !important;
    right: -4px !important;
    min-width: 16px !important;
    height: 16px !important;
    padding: 0 4px !important;
    background: #F59E0B !important;
    color: #FFFFFF !important;
    font-size: 0.62rem !important;
    font-weight: 800 !important;
    border-radius: 9999px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border: 2px solid #FFFFFF !important;
    box-shadow: 0 2px 4px rgba(245, 158, 11, 0.3) !important;
  }

  /* Elevated Center Chat Button */
  .mobile-nav-center-item {
    position: relative !important;
    top: -16px !important;
    padding-top: 0 !important;
  }

  .mobile-nav-center-btn {
    width: 54px !important;
    height: 54px !important;
    border-radius: 50% !important;
    background: linear-gradient(135deg, #010ED0 0%, #2563EB 100%) !important;
    color: #FFFFFF !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-shadow: 0 10px 24px rgba(1, 14, 208, 0.40), 0 3px 8px rgba(1, 14, 208, 0.22) !important;
    border: 3.5px solid #FFFFFF !important;
    position: relative !important;
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.2s ease !important;
  }

  .mobile-nav-center-btn:active {
    transform: scale(0.93) !important;
    box-shadow: 0 5px 14px rgba(1, 14, 208, 0.35) !important;
  }

  .mobile-nav-center-btn svg {
    width: 25px !important;
    height: 25px !important;
    fill: #FFFFFF !important;
    color: #FFFFFF !important;
  }

  .mobile-nav-center-item .mobile-nav-label {
    margin-top: 3px !important;
    font-weight: 700 !important;
    color: #1E293B !important;
    font-size: 0.70rem !important;
  }

  .mobile-nav-center-item.active .mobile-nav-label {
    color: var(--fareworks-blue) !important;
    font-weight: 800 !important;
  }

  .mobile-nav-center-item.active::after {
    display: none !important;
  }

  .mobile-center-badge {
    position: absolute !important;
    top: -2px !important;
    right: -2px !important;
    min-width: 18px !important;
    height: 18px !important;
    padding: 0 4px !important;
    background: #EF4444 !important;
    color: #FFFFFF !important;
    font-size: 0.64rem !important;
    font-weight: 800 !important;
    border-radius: 9999px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border: 2px solid #FFFFFF !important;
    box-shadow: 0 2px 6px rgba(239, 68, 68, 0.4) !important;
  }
}
