/* Professional CRM Design System */
:root {
    /* Primary Color Scheme */
    --primary-color: #007bff;
    --secondary-color: #6c757d;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --info-color: #17a2b8;
    --dark-color: #4a5568;
    --light-color: #f8f9fa;
    
    /* Background & Surface Colors */
    --primary-background: #f8f9fa;
    --card-background: #ffffff;
    --dark-elements: #4a5568;
    --light-accents: #e9ecef;
    --border-color: #dee2e6;
    
    /* Status Colors with Backgrounds */
    --new-bg: #e7f3ff;
    --new-text: #0056b3;
    --contacted-bg: #fff3cd;
    --contacted-text: #856404;
    --qualified-bg: #d1edff;
    --qualified-text: #155724;
    --closed-bg: #f8d7da;
    --closed-text: #721c24;
    
    /* Design System Properties */
    --border-radius: 0.5rem;
    --border-radius-sm: 0.375rem;
    --box-shadow: 0 0.15rem 1.75rem 0 rgba(33, 40, 50, 0.15);
    --box-shadow-hover: 0 0.25rem 2rem 0 rgba(33, 40, 50, 0.25);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-fast: all 0.15s ease-in-out;
    
    /* Typography */
    --font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    --font-mono: 'Courier New', Courier, monospace;
    --font-weight-medium: 500;
    --font-weight-semibold: 600;
    --letter-spacing: 0.025em;
}

/* Global Styles & Typography */
body {
    font-family: 'Inter', var(--font-family);
    line-height: 1.6;
    color: #4a5568;
    background-color: var(--primary-background);
    font-weight: 400;
}

/* Typography Hierarchy */
h1, h2, h3, h4, h5, h6 {
    font-weight: var(--font-weight-semibold);
    color: #2d3748;
    margin-bottom: 0.5rem;
}

.fw-medium {
    font-weight: var(--font-weight-medium) !important;
}

.text-uppercase {
    letter-spacing: var(--letter-spacing);
}

/* Monospace for technical data */
.font-mono, .phone-number, .call-sid {
    font-family: var(--font-mono);
    letter-spacing: 0.05em;
}

/* Table Header Styling */
.table thead th {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%) !important;
    color: white !important;
    border: none !important;
    padding: 1.25rem 1rem !important;
    font-weight: 600;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Equal Width Column Control - Apply to all tables */
.table {
    table-layout: fixed;
    width: 100%;
}

.table th,
.table td {
    width: auto !important;
    min-width: 0;
    word-wrap: break-word;
}

/* All table columns equal width - no special cases */
.table th,
.table td {
    width: auto !important;
}

/* Removed duplicate - already handled above */

/* Removed duplicate rule - handled by global table styling below */

/* Override for lead management table */
.lead-management-table.table th, 
.lead-management-table.table td {
    padding: 0.5rem 0.4rem;
    white-space: normal;
}

/* Specific Column Width Controls */
/* Equal width for all table columns - removing fixed widths */
.col-lead-name, .col-cold-lead, .col-user,
.col-company, .col-assigned, .col-contact, 
.col-phone, .col-date, .col-actions,
.col-communication, .col-recipient {
    width: auto !important;
    max-width: none !important;
}

/* Maintain center alignment for specific column types */
.col-status, .col-role,
.col-contact, .col-phone, 
.col-date, .col-actions {
    text-align: center;
}

/* Text truncation for long content */
.table td > div {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 100%;
}

.table td strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    display: block;
}

.table td small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #6c757d;
    display: block;
}

/* Simplified table styling */
.table td {
    line-height: 1.4;
}

.table .text-muted {
    font-size: 0.875rem;
}

/* Compact button groups */
.btn-group-sm .btn {
    padding: 0.25rem 0.4rem;
    font-size: 0.75rem;
}

/* Badge optimization */
.badge {
    font-size: 0.75rem;
    padding: 0.35em 0.65em;
    white-space: nowrap;
}

/* Responsive table behavior - equal columns at all screen sizes */
@media (max-width: 1200px) {
    .table {
        font-size: 0.8125rem;
    }
    
    .table th,
    .table td {
        width: auto !important;
        max-width: none !important;
    }
}

/* App Container & Layout */
.app-container {
    display: flex;
    flex-direction: column;
    height: 100vh;
    padding-top: 60px; /* Account for fixed navbar */
}

.app-body {
    display: flex;
    flex-direction: row;
    flex: 1;
    overflow: hidden;
}

/* Top Navigation Bar */
.top-navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1030;
    height: 60px;
}

.navbar-brand {
    font-weight: 600;
    font-size: 1.25rem;
}



/* Modern Sidebar Navigation */
.sidebar {
    width: 250px;
    min-width: 250px;
    background-color: var(--primary-background);
    border-right: 1px solid var(--border-color);
    overflow-y: auto;
    z-index: 1000;
    position: relative;
    height: 100%;
}

.sidebar-header {
    padding: 1.5rem 1rem;
    background-color: var(--card-background);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--box-shadow);
}

.sidebar-title {
    color: #4a5568;
    margin-bottom: 0;
    font-weight: var(--font-weight-semibold);
    font-size: 1.1rem;
}

.sidebar-body {
    padding: 1rem 0;
    height: 100%;
    overflow-y: auto;
}

.sidebar .nav-link {
    color: var(--secondary-color);
    padding: 0.875rem 1.5rem;
    border-radius: 0;
    font-weight: var(--font-weight-medium);
    transition: var(--transition-fast);
    border-left: 3px solid transparent;
    margin: 0 0.5rem;
    border-radius: var(--border-radius-sm);
}

.sidebar .nav-link:hover {
    color: var(--primary-color);
    background-color: rgba(0, 123, 255, 0.1);
    border-left-color: var(--primary-color);
    transform: translateX(4px);
}

.sidebar .nav-link.active {
    color: white;
    background-color: var(--primary-color);
    border-left-color: var(--primary-color);
    box-shadow: var(--box-shadow);
}

.sidebar .nav-link i {
    width: 16px;
    margin-right: 0.75rem;
}

/* Main Content Area */
.main-content {
    flex: 1;
    padding: 2rem;
    background-color: #f8f9fa;
    overflow-y: auto;
    z-index: 1;
    position: relative;
    height: 100%;
}

/* Desktop-only layout - no mobile responsive needed */

/* Override Bootstrap text colors to remove black */
.text-dark {
    color: #4a5568 !important;
}

.text-muted {
    color: #a0aec0 !important;
}

/* Ensure all dashboard content stays within bounds */
.row {
    margin-left: 0;
    margin-right: 0;
    margin-bottom: 1.5rem;
}

.row [class*="col-"] {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
}

/* Recent Activity Section Spacing */
.row:last-child {
    margin-bottom: 0;
}

/* Professional Card System */
.card {
    border: none !important;
    border-radius: var(--border-radius) !important;
    box-shadow: var(--box-shadow) !important;
    background-color: var(--card-background) !important;
    transition: var(--transition) !important;
    overflow: hidden;
}

/* Removed hover effects */

.card-header {
    background-color: var(--card-background) !important;
    border-bottom: 1px solid var(--border-color) !important;
    font-weight: var(--font-weight-medium);
    padding: 1.25rem;
}

/* Card Headers - Blue Text */
.card-header h5,
.card-header .card-title {
    color: var(--primary-color) !important;
    font-weight: var(--font-weight-semibold) !important;
}

/* Remove dark colors from tables and form elements */
.table tbody tr,
.form-control,
.form-select,
input,
textarea,
select {
    border-color: #e2e8f0 !important;
}

.table tbody tr:hover {
    background-color: rgba(0, 123, 255, 0.05) !important;
}

.table tbody tr:hover td {
    background-color: rgba(0, 123, 255, 0.05) !important;
}

.form-control:focus,
.form-select:focus,
input:focus,
textarea:focus,
select:focus {
    border-color: var(--primary-color) !important;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.15) !important;
    color: #4a5568 !important;
}

/* Placeholder text and labels */
.form-control::placeholder,
input::placeholder,
textarea::placeholder {
    color: #cbd5e0 !important;
    opacity: 1;
}

.form-label,
label {
    color: #718096 !important;
    font-weight: var(--font-weight-medium);
}

/* Override Bootstrap table backgrounds */
.table-light,
.table-light > th,
.table-light > td {
    background-color: #ffffff !important;
    color: #2d3748 !important;
}

/* Removed conflicting table header background override */

.table tbody tr {
    background-color: #ffffff !important;
}

.table tbody tr:nth-of-type(odd) {
    background-color: #ffffff !important;
}

.table tbody tr:nth-of-type(even) {
    background-color: #ffffff !important;
}

/* Ensure all table cells have proper contrast */
.table td {
    background-color: #ffffff !important;
    color: #2d3748 !important;
    border-color: #e2e8f0 !important;
}

/* Apply to all sections - leads, communications, etc. */
.table-striped tbody tr:nth-of-type(odd) td,
.table-striped tbody tr:nth-of-type(even) td {
    background-color: #ffffff !important;
}

/* Override any remaining Bootstrap dark styling */
.table-dark,
.table-dark th,
.table-dark td,
.table-dark thead th,
.table-dark tbody tr {
    background-color: #ffffff !important;
    color: #2d3748 !important;
    border-color: #e2e8f0 !important;
}

/* Small text elements in tables */
.table small,
.table .text-muted {
    color: #718096 !important;
}

/* Strong text in tables */
.table strong {
    color: #2d3748 !important;
}

/* Reset form control colors to default */
.form-control,
.form-select,
input[type="text"],
input[type="email"],
input[type="password"],
input[type="search"],
input[type="tel"],
textarea,
select {
    background-color: #ffffff !important;
    color: #2d3748 !important;
    border: 1px solid #e2e8f0 !important;
}

/* All sections consistent styling */
.card-body .table,
.dashboard-section .table,
.content-section .table {
    background-color: #ffffff !important;
}

.card-body .table td,
.dashboard-section .table td,
.content-section .table td {
    background-color: #ffffff !important;
    color: #2d3748 !important;
}

/* Table responsive without horizontal scroll */
.table-responsive {
    overflow-x: auto;
    margin-bottom: 0;
}

/* Ensure tables fit within container */
.table {
    width: 100%;
    margin-bottom: 0;
    min-width: auto;
}

/* Global table cell handling - overrides Bootstrap defaults */
.table td, .table th {
    padding: 0.75rem 0.5rem !important;
    vertical-align: middle !important;
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
    white-space: normal !important;
    min-width: 0;
    line-height: 1.4;
    font-size: 0.875rem;
}

/* Modal z-index fix to appear above navigation */
.modal {
    z-index: 99999 !important;
}

.modal-backdrop {
    z-index: 99998 !important;
}

/* Override existing z-index values to ensure modals appear above everything */
.top-navbar {
    z-index: 1030 !important;
}

.sidebar {
    z-index: 1000 !important;
}

/* Force modal content above everything */
.modal-dialog {
    z-index: 100000 !important;
    position: relative;
}

/* Additional modal fixes */
.modal.show {
    z-index: 99999 !important;
}

.modal.show .modal-dialog {
    z-index: 100001 !important;
}

/* Force modal above all headers and navigation */
header, .header, .navbar-fixed-top, .fixed-top, .top-navbar, .navbar {
    z-index: 1020 !important;
}

/* Bootstrap modal backdrop and content overrides */
.modal-backdrop.show {
    z-index: 99998 !important;
}

.modal.fade.show {
    z-index: 99999 !important;
}

/* Ensure modal content is always on top */
.modal-content {
    z-index: 100002 !important;
    position: relative;
}

/* Override all generic table padding for lead management table */
.lead-management-table td,
.lead-management-table th {
    padding: 0.5rem 0.4rem !important;
    border-spacing: 0 !important;
    border-collapse: collapse !important;
}

/* Specific column width controls */
.table th[style*="width"], .table td[style*="width"] {
    max-width: none;
}

/* Text handling for different column types */
.table td:first-child, 
.table th:first-child {
    white-space: normal;
    word-break: break-word;
}

/* Action buttons column - prevent shrinking */
.table td:last-child,
.table th:last-child {
    white-space: nowrap;
    width: auto;
    min-width: 150px;
}

/* Button group sizing for tables - more compact */
.table .btn-group-sm .btn {
    padding: 0.2rem 0.3rem;
    font-size: 0.75rem;
    line-height: 1.2;
}

.table .btn-sm {
    padding: 0.2rem 0.3rem;
    font-size: 0.75rem;
    line-height: 1.2;
}

/* Ensure proper spacing in table containers */
.card-body .table-responsive {
    margin: -1rem -1rem 0;
    padding: 0 1rem;
    max-width: 100%;
}

/* Table column sizing classes */
.col-user { width: 28%; min-width: 200px; }
.col-role { width: 10%; min-width: 70px; }
.col-status { width: 10%; min-width: 70px; }
.col-phone { width: 15%; min-width: 120px; }
.col-date { width: 12%; min-width: 90px; }
.col-actions { width: 25%; min-width: 180px; }

/* Leads table specific columns */
.col-lead-name { width: 20%; min-width: 180px; }
.col-company { width: 16%; min-width: 140px; }
.col-assigned { width: 12%; min-width: 110px; }
.col-contact { width: 14%; min-width: 140px; }

/* Communications table columns */
.col-type { width: 8%; min-width: 70px; }
.col-recipient { width: 16%; min-width: 140px; }
.col-lead { width: 14%; min-width: 120px; }
.col-message { width: 25%; min-width: 200px; }
.col-user { width: 12%; min-width: 100px; }

/* Cold leads table columns */
.col-cold-lead { width: 20%; min-width: 180px; }
.col-source { width: 12%; min-width: 100px; }
.col-priority { width: 8%; min-width: 70px; }

/* Campaigns table columns */
.col-campaign { width: 20%; min-width: 180px; }
.col-description { width: 25%; min-width: 200px; }
.col-progress { width: 12%; min-width: 100px; }

/* Phone numbers table columns */
.col-number { width: 18%; min-width: 150px; }
.col-provider { width: 12%; min-width: 100px; }
.col-assignment { width: 15%; min-width: 120px; }

/* Files/Upload table columns */
.col-filename { width: 25%; min-width: 200px; }
.col-size { width: 10%; min-width: 80px; }
.col-uploader { width: 15%; min-width: 120px; }

/* Flexible table layout for better fit */
.table-responsive .table {
    min-width: 1100px;
    table-layout: auto;
}

/* Ensure table cells don't overflow - compact text */
.table td {
    overflow: visible;
    white-space: normal;
    word-wrap: break-word;
    line-height: 1.2;
}

/* Badge styling for tables */
.table .badge {
    font-size: 0.7rem;
    padding: 0.2em 0.4em;
    line-height: 1;
}

/* Small text in tables */
.table small {
    font-size: 0.7rem;
    line-height: 1.1;
}

/* Actions column specific styling */
.table td.col-actions,
.table th.col-actions {
    white-space: nowrap;
    width: 25%;
    min-width: 180px;
    padding: 0.5rem 0.25rem;
    text-align: center;
    overflow: visible;
}

.table td.col-actions .btn-group {
    display: flex;
    flex-wrap: nowrap;
    justify-content: center;
    gap: 2px;
}

.table td.col-actions .btn-group .btn {
    flex-shrink: 0;
    min-width: 32px;
}

/* Ensure table container has proper overflow handling */
.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* Fix table layout issues */
.table {
    margin-bottom: 0;
    width: 100%;
}

/* Button group improvements for tables */
.table .btn-group-sm {
    white-space: nowrap;
}

.table .btn-group-sm .btn {
    margin: 0;
    border-radius: 0.375rem;
}

.table .btn-group-sm .btn:not(:last-child) {
    margin-right: 2px;
}

.table td.col-user,
.table th.col-user,
.table td.col-lead-name,
.table th.col-lead-name,
.table td.col-phone,
.table th.col-phone,
.table td.col-date,
.table th.col-date {
    white-space: nowrap;
    overflow: visible;
}

/* Contact column with buttons */
.table td.col-contact,
.table th.col-contact {
    text-align: center;
    white-space: nowrap;
    padding: 0.5rem 0.25rem;
}

.table td.col-contact .btn-sm {
    padding: 0.2rem 0.4rem;
    font-size: 0.75rem;
    margin: 0 1px;
}

.table td.col-contact .d-flex {
    flex-wrap: nowrap;
    justify-content: center;
}

/* Media query for smaller screens */
@media (max-width: 768px) {
    .table td, .table th {
        padding: 0.3rem 0.2rem;
        font-size: 0.8rem;
        line-height: 1.1;
    }
    
    .table .btn-group-sm .btn {
        padding: 0.1rem 0.2rem;
        font-size: 0.7rem;
    }
    
    .table .btn-sm {
        padding: 0.1rem 0.2rem;
        font-size: 0.7rem;
    }
    
    /* Adjust column sizes for mobile */
    .col-user { width: 35%; }
    .col-role, .col-status { width: 12%; }
    .col-phone { width: 18%; }
    .col-date { width: 15%; }
    .col-actions { width: 30%; }
    
    /* Mobile table improvements */
    .table-responsive .table {
        min-width: 800px;
    }
    
    /* Leads table mobile adjustments */
    .col-lead-name { width: 25%; }
    .col-company { width: 20%; }
    .col-assigned { width: 15%; }
    .col-contact { width: 15%; }
    
    /* Communications table mobile */
    .col-type { width: 10%; }
    .col-recipient { width: 20%; }
    .col-lead { width: 15%; }
    .col-message { width: 30%; }
    .col-user { width: 15%; }
    
    /* Other tables mobile */
    .col-cold-lead { width: 25%; }
    .col-source { width: 15%; }
    .col-priority { width: 10%; }
    .col-campaign { width: 25%; }
    .col-description { width: 30%; }
    .col-progress { width: 15%; }
    .col-number { width: 25%; }
    .col-provider { width: 15%; }
    .col-assignment { width: 20%; }
    .col-filename { width: 30%; }
    .col-size { width: 12%; }
    .col-uploader { width: 18%; }
}

.card-body {
    padding: 1.5rem;
}

/* Status-based card borders */
.card-status-new {
    border-left: 4px solid var(--info-color) !important;
}

.card-status-contacted {
    border-left: 4px solid var(--warning-color) !important;
}

.card-status-qualified {
    border-left: 4px solid var(--success-color) !important;
}

.card-status-closed {
    border-left: 4px solid var(--danger-color) !important;
}

/* Professional Button System */
.btn {
    font-weight: var(--font-weight-medium) !important;
    border-radius: var(--border-radius-sm) !important;
    padding: 0.5rem 1rem !important;
    transition: var(--transition) !important;
    letter-spacing: 0.025em;
}

/* Removed button hover effects */

.btn-primary {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
}

.btn-success {
    background-color: var(--success-color) !important;
    border-color: var(--success-color) !important;
}

.btn-warning {
    background-color: var(--warning-color) !important;
    border-color: var(--warning-color) !important;
}

.btn-danger {
    background-color: var(--danger-color) !important;
    border-color: var(--danger-color) !important;
}

.btn-sm {
    font-size: 0.875rem !important;
    padding: 0.375rem 0.75rem !important;
}

/* Status Badges & Indicators */
.badge {
    font-size: 0.75em !important;
    font-weight: var(--font-weight-medium) !important;
    padding: 0.5em 0.75em !important;
    border-radius: var(--border-radius-sm) !important;
    text-transform: uppercase;
    letter-spacing: var(--letter-spacing);
}

.status-new {
    background-color: var(--new-bg) !important;
    color: var(--new-text) !important;
}

.status-contacted {
    background-color: var(--contacted-bg) !important;
    color: var(--contacted-text) !important;
}

.status-qualified {
    background-color: var(--qualified-bg) !important;
    color: var(--qualified-text) !important;
}

.status-closed {
    background-color: var(--closed-bg) !important;
    color: var(--closed-text) !important;
}

/* Dashboard Statistics Cards */
.stat-card {
    background: linear-gradient(135deg, var(--card-background) 0%, #f8f9fa 100%);
    border-left: 4px solid var(--primary-color);
    transition: var(--transition);
    position: relative;
    z-index: 2;
    margin-bottom: 1rem;
}

/* Removed stat-card hover effects */

.stat-number {
    font-size: 2.5rem;
    font-weight: var(--font-weight-semibold);
    color: var(--primary-color);
    line-height: 1;
}

.stat-label {
    color: var(--secondary-color);
    font-weight: var(--font-weight-medium);
    text-transform: uppercase;
    letter-spacing: var(--letter-spacing);
    font-size: 0.875rem;
}

/* Professional Table System */
.table {
    background-color: var(--card-background);
}

.table th {
    background-color: var(--primary-background);
    border-bottom: 2px solid var(--border-color);
    color: var(--dark-color);
    font-weight: var(--font-weight-semibold);
    text-transform: uppercase;
    letter-spacing: var(--letter-spacing);
    font-size: 0.875rem;
    padding: 1rem 0.75rem;
}

.table td {
    padding: 1rem 0.75rem;
    vertical-align: middle;
    border-bottom: 1px solid var(--light-accents);
}

.table tbody tr:hover {
    background-color: rgba(0, 123, 255, 0.05);
    transform: scale(1.01);
    transition: var(--transition-fast);
}

/* Communication Visual Elements */
.message-thread {
    max-height: 400px;
    overflow-y: auto;
    padding: 1rem;
    background-color: var(--primary-background);
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
}

.message-item {
    background-color: var(--card-background);
    padding: 0.875rem;
    margin-bottom: 0.75rem;
    border-radius: var(--border-radius-sm);
    box-shadow: var(--box-shadow);
    border-left: 3px solid var(--secondary-color);
}

.message-outbound {
    border-left-color: var(--primary-color) !important;
}

.message-inbound {
    border-left-color: var(--success-color) !important;
}

.message-email {
    border-left-color: var(--warning-color) !important;
}

.message-meta {
    font-size: 0.875rem;
    color: var(--secondary-color);
    margin-bottom: 0.5rem;
}

.message-content {
    color: var(--dark-color);
    font-weight: var(--font-weight-medium);
}

/* Call Center Interface */
.call-widget {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 300px;
    background-color: var(--card-background);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-hover);
    z-index: 1040;
    border: 1px solid var(--border-color);
}

.call-widget-header {
    background: linear-gradient(135deg, var(--primary-color), #0056b3);
    color: white;
    padding: 1rem;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
    font-weight: var(--font-weight-semibold);
}

.call-widget-body {
    padding: 1.5rem;
}

.keypad {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    margin: 1rem 0;
}

.keypad-btn {
    aspect-ratio: 1;
    border: 1px solid var(--border-color);
    background-color: var(--card-background);
    border-radius: 50%;
    font-size: 1.25rem;
    font-weight: var(--font-weight-semibold);
    color: var(--dark-color);
    transition: var(--transition-fast);
    cursor: pointer;
}

.keypad-btn:hover {
    background-color: var(--primary-color);
    color: white;
    transform: scale(1.1);
}

.phone-display {
    background-color: var(--primary-background);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-sm);
    padding: 0.75rem;
    text-align: center;
    font-family: var(--font-mono);
    font-size: 1.1rem;
    letter-spacing: 0.1em;
    min-height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.call-actions {
    display: flex;
    gap: 0.75rem;
    margin-top: 1rem;
}

.call-btn {
    flex: 1;
    padding: 0.75rem;
    border: none;
    border-radius: 50px;
    font-weight: var(--font-weight-semibold);
    transition: var(--transition);
    cursor: pointer;
}

.call-btn-primary {
    background: linear-gradient(135deg, var(--success-color), #1e7e34);
    color: white;
}

.call-btn-danger {
    background: linear-gradient(135deg, var(--danger-color), #c82333);
    color: white;
}

/* Removed call button hover effects */

/* Incoming Call Alert */
.incoming-call-alert {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: var(--card-background);
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-hover);
    z-index: 1050;
    border: 3px solid var(--danger-color);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(220, 53, 69, 0.7); }
    70% { box-shadow: 0 0 0 15px rgba(220, 53, 69, 0); }
    100% { box-shadow: 0 0 0 0 rgba(220, 53, 69, 0); }
}

.caller-info {
    text-align: center;
    margin-bottom: 1.5rem;
}

.caller-number {
    font-size: 1.5rem;
    font-family: var(--font-mono);
    color: var(--dark-color);
    font-weight: var(--font-weight-semibold);
    margin-bottom: 0.5rem;
}

.caller-name {
    color: var(--secondary-color);
    font-weight: var(--font-weight-medium);
}

/* Professional Forms */
.form-control, .form-select {
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-sm);
    padding: 0.75rem;
    font-size: 0.95rem;
    transition: var(--transition-fast);
    background-color: var(--card-background);
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.15);
    background-color: var(--card-background);
}

.form-label {
    font-weight: var(--font-weight-medium);
    color: var(--dark-color);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: var(--letter-spacing);
}

.form-text {
    color: var(--secondary-color);
    font-size: 0.875rem;
}

/* Professional Alert System */
.alert {
    border: none;
    border-radius: var(--border-radius);
    padding: 1rem 1.25rem;
    margin-bottom: 1rem;
    font-weight: var(--font-weight-medium);
    border-left: 4px solid;
}

.alert-success {
    background-color: rgba(40, 167, 69, 0.1);
    border-left-color: var(--success-color);
    color: #2d5016;
}

.alert-danger {
    background-color: rgba(220, 53, 69, 0.1);
    border-left-color: var(--danger-color);
    color: #721c24;
}

.alert-warning {
    background-color: rgba(255, 193, 7, 0.1);
    border-left-color: var(--warning-color);
    color: #856404;
}

.alert-info {
    background-color: rgba(23, 162, 184, 0.1);
    border-left-color: var(--info-color);
    color: #2c5282;
}

/* Loading States & Animations */
.loading-spinner {
    display: inline-block;
    width: 1.5rem;
    height: 1.5rem;
    border: 2px solid var(--light-accents);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.fade-in {
    animation: fadeIn 0.3s ease-in-out;
}

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

/* Empty State Styling */
.empty-state {
    text-align: center;
    padding: 3rem 2rem;
    color: var(--secondary-color);
}

.empty-state-icon {
    font-size: 3rem;
    color: var(--light-accents);
    margin-bottom: 1rem;
}

.empty-state-text {
    font-size: 1.1rem;
    font-weight: var(--font-weight-medium);
    margin-bottom: 0.5rem;
}

.empty-state-help {
    font-size: 0.95rem;
    color: var(--secondary-color);
}

/* Utility Classes */
.text-muted-custom {
    color: var(--secondary-color) !important;
}

.bg-light-custom {
    background-color: var(--primary-background) !important;
}

.border-custom {
    border-color: var(--border-color) !important;
}

.shadow-custom {
    box-shadow: var(--box-shadow) !important;
}

.rounded-custom {
    border-radius: var(--border-radius) !important;
}

/* Incoming Call Notification Animation */
.pulse-animation {
    animation: pulse-glow 2s infinite;
}

@keyframes pulse-glow {
    0% { 
        box-shadow: 0 0 0 0 rgba(220, 53, 69, 0.7);
        transform: scale(1);
    }
    50% { 
        box-shadow: 0 0 0 8px rgba(220, 53, 69, 0);
        transform: scale(1.1);
    }
    100% { 
        box-shadow: 0 0 0 0 rgba(220, 53, 69, 0);
        transform: scale(1);
    }
}

/* Enhanced Navigation Bar */
.top-navbar {
    background: linear-gradient(135deg, var(--primary-color) 0%, #0056b3 100%) !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 999;
    height: 60px;
}

.navbar-brand {
    font-weight: var(--font-weight-semibold);
    font-size: 1.25rem;
    transition: var(--transition-fast);
}

.navbar-brand:hover {
    
}

/* Enhanced Dropdown */
.dropdown-menu {
    border: none;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-hover);
    padding: 0.5rem 0;
    margin-top: 0.5rem;
    z-index: 1000;
}

.dropdown-item {
    padding: 0.75rem 1.5rem;
    font-weight: var(--font-weight-medium);
    transition: var(--transition-fast);
}

.dropdown-item:hover {
    background-color: rgba(0, 123, 255, 0.1);
    color: var(--primary-color);
    transform: translateX(4px);
}

/* Professional Page Headers */
.page-header {
    background: linear-gradient(135deg, rgba(0, 123, 255, 0.05) 0%, rgba(0, 123, 255, 0.02) 100%);
    border-radius: var(--border-radius);
    padding: 2rem;
    margin-bottom: 2rem;
    border-left: 4px solid var(--primary-color);
}

.page-title {
    color: var(--primary-color);
    font-weight: var(--font-weight-semibold);
    margin-bottom: 0.5rem;
}

.page-subtitle {
    color: var(--secondary-color);
    font-size: 1.1rem;
    margin-bottom: 0;
}

/* Professional Modal Styling */
.modal-content {
    border: none;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-hover);
}

.modal-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, #0056b3 100%);
    color: white;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
    padding: 1.5rem;
}

.modal-title {
    font-weight: var(--font-weight-semibold);
}

.btn-close {
    filter: brightness(0) invert(1);
}

.modal-body {
    padding: 2rem;
}

.modal-footer {
    padding: 1.5rem 2rem;
    border-top: 1px solid var(--border-color);
}

/* Professional Shadow Box Overlay */
.shadow-box-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 10500;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
}

.shadow-box-container {
    max-width: 900px;
    max-height: 90vh;
    width: 95%;
    overflow-y: auto;
}

.shadow-box-content {
    background: rgba(255, 255, 255, 0.98);
    border-radius: 16px;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.25);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    position: relative;
    z-index: 10501;
}

.shadow-box-header {
    background: linear-gradient(135deg, var(--primary-color), #4a90e2);
    color: white;
    padding: 1.5rem 2rem;
    border-radius: 16px 16px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.shadow-box-title {
    margin: 0;
    font-weight: 600;
    font-size: 1.25rem;
}

.shadow-box-close {
    background: none;
    border: none;
    color: white;
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 6px;
    transition: background 0.2s;
}

.shadow-box-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.shadow-box-body {
    padding: 2rem;
}

.shadow-box-footer {
    padding: 1.5rem 2rem;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 0 0 16px 16px;
    background: rgba(248, 249, 250, 0.8);
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}
    
    .sidebar.show {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
}

/* Header and Navigation */
.dropdown-menu {
    border: none;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    border-radius: var(--border-radius);
}

/* Cards */
.card {
    border: none;
    box-shadow: var(--box-shadow);
    border-radius: var(--border-radius);
    margin-bottom: 1.5rem;
    transition: var(--transition);
}

.card:hover {
    box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.1);
}

.card-header {
    background-color: var(--light-color);
    border-bottom: 1px solid #dee2e6;
    font-weight: 600;
    padding: 1rem 1.25rem;
}

.card-body {
    padding: 1.25rem;
}

/* Buttons */
.btn {
    font-weight: 500;
    border-radius: var(--border-radius);
    padding: 0.5rem 1rem;
    transition: var(--transition);
    border: none;
}

.btn:hover {
    
    box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.1);
}

.btn-sm {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

.btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1.125rem;
}

/* Tables */
.table {
    margin-bottom: 0;
}

.table th {
    font-weight: 600;
    color: var(--dark-color);
    border-top: none;
    padding: 1rem 0.75rem;
}

.table td {
    padding: 0.75rem;
    vertical-align: middle;
}

.table-hover tbody tr:hover {
    background-color: rgba(0, 0, 0, 0.025);
}

.table-responsive {
    border-radius: var(--border-radius);
}

/* Forms */
.form-control, .form-select {
    border-radius: var(--border-radius);
    border: 1px solid #ced4da;
    padding: 0.5rem 0.75rem;
    transition: var(--transition);
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

.form-label {
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: var(--dark-color);
}

.form-text {
    color: #6c757d;
    font-size: 0.875rem;
}

/* Input Groups */
.input-group-text {
    background-color: var(--light-color);
    border: 1px solid #ced4da;
    color: var(--dark-color);
    font-weight: 500;
}

/* Badges */
.badge {
    font-weight: 500;
    padding: 0.375rem 0.5rem;
    border-radius: 0.25rem;
}

/* Alerts */
.alert {
    border: none;
    border-radius: var(--border-radius);
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem;
}

.alert-success {
    background-color: #d1e7dd;
    color: #0f5132;
}

.alert-danger {
    background-color: #f8d7da;
    color: #842029;
}

.alert-warning {
    background-color: #fff3cd;
    color: #664d03;
}

.alert-info {
    background-color: #d1ecf1;
    color: #055160;
}

/* Modal */
.modal-content {
    border: none;
    border-radius: var(--border-radius);
    box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.175);
}

.modal-header {
    border-bottom: 1px solid #dee2e6;
    padding: 1.25rem;
}

.modal-body {
    padding: 1.25rem;
}

.modal-footer {
    border-top: 1px solid #dee2e6;
    padding: 1rem 1.25rem;
}

/* Pagination */
.pagination {
    margin-bottom: 0;
}

.page-link {
    border: none;
    padding: 0.5rem 0.75rem;
    margin: 0 0.125rem;
    border-radius: var(--border-radius);
    color: var(--primary-color);
    transition: var(--transition);
}

.page-link:hover {
    background-color: var(--light-color);
    color: var(--primary-color);
}

.page-item.active .page-link {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

/* Dashboard Cards */
.dashboard-card {
    background: linear-gradient(135deg, var(--primary-color), #0056b3);
    color: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.dashboard-card h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.dashboard-card p {
    font-size: 1rem;
    opacity: 0.9;
    margin-bottom: 0.5rem;
}

.dashboard-card small {
    font-size: 0.875rem;
    opacity: 0.8;
}

/* Status Badges */
.status-new { background-color: var(--primary-color) !important; }
.status-contacted { background-color: var(--info-color) !important; color: #2d3748 !important; }
.status-qualified { background-color: var(--warning-color) !important; color: #2d3748 !important; }
.status-proposal { background-color: #6c757d !important; }
.status-closed-won { background-color: var(--success-color) !important; }
.status-closed-lost { background-color: var(--danger-color) !important; }
.status-inactive { background-color: var(--light-color) !important; color: #4a5568 !important; }

/* Lead Timeline */
.timeline {
    position: relative;
    padding-left: 1.5rem;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0.5rem;
    top: 0;
    bottom: 0;
    width: 2px;
    background-color: #dee2e6;
}

.timeline-item {
    position: relative;
    padding-bottom: 1rem;
}

.timeline-marker {
    position: absolute;
    left: -1rem;
    top: 0.25rem;
    width: 0.75rem;
    height: 0.75rem;
    border-radius: 50%;
    background-color: var(--primary-color);
    border: 2px solid white;
    box-shadow: 0 0 0 2px #dee2e6;
}

.timeline-content {
    background-color: white;
    padding: 0.75rem;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    margin-left: 0.5rem;
}

/* Message Preview */
.message-preview {
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* File Icons */
.file-icon {
    font-size: 1.25rem;
    margin-right: 0.5rem;
}

/* Loading States */
.loading {
    display: inline-block;
    width: 1rem;
    height: 1rem;
    border: 2px solid transparent;
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Responsive Adjustments */
@media (max-width: 768px) {
    .container-fluid {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    .card-body {
        padding: 1rem;
    }
    
    .table-responsive {
        font-size: 0.875rem;
    }
    
    .btn-group .btn {
        padding: 0.375rem 0.5rem;
        font-size: 0.75rem;
    }
    
    .dashboard-card h2 {
        font-size: 2rem;
    }
    
    .modal-body {
        padding: 1rem;
    }
}

@media (max-width: 576px) {
    .d-flex.justify-content-between {
        flex-direction: column;
        gap: 1rem;
    }
    
    .btn-group {
        flex-direction: column;
    }
    
    .card-header .d-flex {
        flex-direction: column;
        align-items: flex-start !important;
        gap: 0.5rem;
    }
}

/* Print Styles */
@media print {
    .navbar,
    .btn,
    .pagination,
    .modal,
    .alert {
        display: none !important;
    }
    
    .card {
        box-shadow: none;
        border: 1px solid #dee2e6;
    }
    
    body {
        background-color: white;
    }
}

/* Dark Mode Support (Optional) */
@media (prefers-color-scheme: dark) {
    :root {
        --dark-color: #f8f9fa;
        --light-color: #212529;
    }
    
    body {
        background-color: #1a1a1a;
        color: var(--dark-color);
    }
    
    .card {
        background-color: #2d2d2d;
        color: var(--dark-color);
    }
    
    .card-header {
        background-color: #3d3d3d;
        border-bottom-color: #4d4d4d;
    }
    
    .table {
        --bs-table-bg: #2d2d2d;
        --bs-table-color: var(--dark-color);
    }
    
    .form-control,
    .form-select {
        background-color: #3d3d3d;
        border-color: #4d4d4d;
        color: var(--dark-color);
    }
    
    .input-group-text {
        background-color: #3d3d3d;
        border-color: #4d4d4d;
        color: var(--dark-color);
    }
}

/* Custom Utilities */
.text-truncate-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.border-start-primary {
    border-left: 4px solid var(--primary-color) !important;
}

.border-start-success {
    border-left: 4px solid var(--success-color) !important;
}

.border-start-warning {
    border-left: 4px solid var(--warning-color) !important;
}

.border-start-danger {
    border-left: 4px solid var(--danger-color) !important;
}

.border-start-info {
    border-left: 4px solid var(--info-color) !important;
}

/* Animation Classes */
.fade-in {
    animation: fadeIn 0.3s ease-in;
}

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

.slide-in {
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from { transform: translateX(-100%); }
    to { transform: translateX(0); }
}

/* Hover Effects */
.hover-lift:hover {
    
    transition: var(--transition);
}

.hover-shadow:hover {
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    transition: var(--transition);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--light-color);
}

::-webkit-scrollbar-thumb {
    background: #ced4da;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #adb5bd;
}

/* Focus Styles */
.form-control:focus,
.form-select:focus,
.btn:focus {
    outline: none;
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

/* Error States */
.form-control.is-invalid,
.form-select.is-invalid {
    border-color: var(--danger-color);
}

.form-control.is-invalid:focus,
.form-select.is-invalid:focus {
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25);
}

/* Success States */
.form-control.is-valid,
.form-select.is-valid {
    border-color: var(--success-color);
}

.form-control.is-valid:focus,
.form-select.is-valid:focus {
    box-shadow: 0 0 0 0.2rem rgba(25, 135, 84, 0.25);
}

/* Softphone Widget Styles */
.softphone-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 280px;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
    z-index: 1060;
    transition: all 0.3s ease;
}

.softphone-widget.collapsed .softphone-body {
    display: none;
}

.softphone-header {
    background: linear-gradient(135deg, var(--primary-color), #4a90e2);
    color: white;
    padding: 8px 12px;
    border-radius: 10px 10px 0 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    user-select: none;
}

.softphone-widget.collapsed .softphone-header {
    border-radius: 10px;
}

.softphone-title {
    font-weight: 600;
    font-size: 13px;
}

.softphone-toggle {
    transition: transform 0.3s ease;
}

.softphone-widget.collapsed .softphone-toggle {
    transform: rotate(180deg);
}

.softphone-body {
    padding: 12px;
    background: #ffffff;
    border-radius: 0 0 10px 10px;
}

.softphone-status {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
    padding: 6px 10px;
    background: #f8f9fa;
    border-radius: 6px;
}

.status-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-right: 6px;
    animation: pulse 2s infinite;
}

.status-indicator.online {
    background: #28a745;
}

.status-indicator.offline {
    background: #dc3545;
    animation: none;
}

.status-indicator.busy {
    background: #ffc107;
}

.status-text {
    font-size: 11px;
    font-weight: 500;
    color: var(--text-muted);
}

.softphone-dialer input {
    text-align: center;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.dialer-btn {
    aspect-ratio: 1;
    font-size: 12px;
    font-weight: 600;
    border-radius: 6px;
    margin-bottom: 3px;
    padding: 6px;
}

.dialer-btn:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.softphone-call-info {
    text-align: center;
    padding: 15px;
    background: var(--light-bg);
    border-radius: 6px;
    margin-top: 12px;
}

.calling-animation {
    position: relative;
    margin: 0 auto 12px;
    width: 50px;
    height: 50px;
}

.pulse-ring {
    position: absolute;
    border: 2px solid var(--success-color);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: pulse-ring 2s cubic-bezier(0.455, 0.03, 0.515, 0.955) infinite;
}

.pulse-ring:nth-child(2) {
    animation-delay: 0.7s;
}

.pulse-ring:nth-child(3) {
    animation-delay: 1.4s;
}

@keyframes pulse-ring {
    0% {
        transform: scale(0.8);
        opacity: 1;
    }
    100% {
        transform: scale(1.4);
        opacity: 0;
    }
}

.call-number {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 3px;
}

.call-duration {
    font-size: 12px;
    color: var(--text-muted);
    font-family: 'Courier New', monospace;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .softphone-widget {
        width: 250px;
        right: 10px;
        bottom: 10px;
    }
}

/* Modern Lead Table - Card-Based Layout */
.modern-lead-table {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1rem;
}

.lead-card-modern {
    display: flex;
    align-items: stretch;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04);
    transition: all 0.2s ease;
    gap: 2rem;
}

.lead-card-modern:hover {
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.1);
    border-color: #007bff;
}

/* Lead Information Section */
.lead-info-section {
    flex: 1;
    min-width: 0;
}

.lead-primary-info {
    margin-bottom: 1rem;
}

.lead-primary-info .lead-name {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2d3748;
    margin: 0 0 0.5rem 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.lead-primary-info .lead-name i {
    font-size: 1.2rem;
}

.lead-primary-info .lead-company {
    color: #718096;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.lead-contact-info {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.contact-detail {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
}

.contact-detail i {
    width: 16px;
    text-align: center;
    flex-shrink: 0;
}

/* Assignment Section */
.lead-assignment-section {
    flex: 0 0 200px;
    padding-left: 2rem;
    border-left: 1px solid #e2e8f0;
}

.assignment-label {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    color: #718096;
    margin-bottom: 0.5rem;
    letter-spacing: 0.05em;
}

.assigned-user,
.unassigned-user {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
}

/* Actions Section */
.lead-actions-section {
    flex: 0 0 300px;
    padding-left: 2rem;
    border-left: 1px solid #e2e8f0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.primary-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.secondary-actions {
    display: flex;
    gap: 0.5rem;
}

.action-btn {
    padding: 0.5rem 1rem;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    color: #4a5568;
    font-size: 0.875rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.action-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    text-decoration: none;
    color: #2d3748;
}

.action-btn.call-btn {
    background: #48bb78;
    color: #ffffff;
    border-color: #48bb78;
}

.action-btn.call-btn:hover {
    background: #38a169;
    color: #ffffff;
}

.action-btn.sms-btn {
    background: #4299e1;
    color: #ffffff;
    border-color: #4299e1;
}

.action-btn.sms-btn:hover {
    background: #3182ce;
    color: #ffffff;
}

.action-btn.email-btn {
    background: #ed8936;
    color: #ffffff;
    border-color: #ed8936;
}

.action-btn.email-btn:hover {
    background: #dd6b20;
    color: #ffffff;
}

.action-btn.edit-btn,
.action-btn.history-btn {
    background: #f7fafc;
    border-color: #cbd5e0;
    width: 40px;
    height: 40px;
    padding: 0;
    justify-content: center;
    border-radius: 50%;
}

.action-btn.edit-btn:hover,
.action-btn.history-btn:hover {
    background: #edf2f7;
    border-color: #a0aec0;
}

.lead-card {
    padding: 0.25rem 0;
    margin: 0;
}

.lead-header .lead-name {
    font-size: 1rem;
    font-weight: 600;
    color: var(--heading-color);
    margin-bottom: 0.25rem;
    margin-right: 0;
}

.lead-company {
    font-size: 0.875rem;
    font-weight: 500;
    margin-right: 0;
}

.lead-contact-details {
    margin-top: 0.5rem;
    margin-right: 0;
}

.contact-item {
    font-size: 0.85rem;
    display: flex;
    align-items: center;
}

.contact-value {
    color: var(--text-color);
    font-weight: 500;
}

.status-pill {
    font-size: 0.75rem;
    padding: 0.5rem 0.75rem;
    border-radius: 1rem;
}

.assigned-user, .unassigned-user {
    font-size: 0.875rem;
    font-weight: 500;
}

.action-buttons-container {
    padding: 0.25rem 0;
}

.primary-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.2rem;
    margin-bottom: 0.35rem;
}

.action-btn {
    font-size: 0.8rem;
    padding: 0.375rem 0.75rem;
    border-radius: 0.375rem;
    font-weight: 500;
    white-space: nowrap;
}

.secondary-actions {
    display: flex;
    justify-content: flex-start;
}

.lead-row {
    border-bottom: 1px solid var(--border-color);
}

.lead-row:hover {
    background-color: rgba(var(--primary-rgb), 0.02);
}

/* Action button hover effects */
.action-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Z-index Override to Ensure Shadow Box Appears Above Navigation */
.navbar, .navbar-nav, .dropdown-menu {
    z-index: 1040 !important;
}

.shadow-box-overlay,
.shadow-box-container,
.shadow-box-content {
    z-index: 10500 !important;
}

/* Record Sale Modal specific fix */
#recordSaleModal {
    z-index: 999999 !important;
}

#recordSaleModal .modal-dialog {
    z-index: 999999 !important;
}

#recordSaleModal .modal-content {
    z-index: 999999 !important;
}

#recordSaleModal + .modal-backdrop {
    z-index: 999998 !important;
}
