:root {
    /* Callmatic & Vocalyn Light SaaS Palette */
    --bg-page: #f8fafc;
    --bg-card: #ffffff;
    --bg-hover: #f1f5f9;
    --border-color: #eaecf0;
    --border-focus: #7c3aed;
    
    --primary: #7c3aed; /* Callmatic Signature Violet */
    --primary-hover: #6d28d9;
    --primary-subtle: #f4f3ff;
    
    --emerald: #10b981;
    --emerald-hover: #059669;
    --emerald-subtle: #ecfdf5;
    
    --warning: #f59e0b;
    --warning-subtle: #fffbeb;
    --danger: #ef4444;
    --danger-subtle: #fef2f2;
    --purple: #8b5cf6;
    --purple-subtle: #f5f3ff;
    
    --text-primary: #101828;
    --text-secondary: #344054;
    --text-muted: #667085;
    --text-light: #98a2b3;
    
    --shadow-sm: 0 1px 2px rgba(16, 24, 40, 0.05);
    --shadow-md: 0 4px 12px -2px rgba(16, 24, 40, 0.08), 0 2px 6px -2px rgba(16, 24, 40, 0.04);
    --shadow-lg: 0 12px 24px -4px rgba(16, 24, 40, 0.12), 0 4px 8px -2px rgba(16, 24, 40, 0.06);
    
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 14px;
    --radius-xl: 18px;
    
    --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
}

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

body.light-theme {
    background-color: var(--bg-page);
    color: var(--text-primary);
    font-family: var(--font-sans);
    line-height: 1.5;
    height: 100vh;
    overflow: hidden;
}

/* Master Layout Wrapper (Left Sidebar + Main Content) */
.layout-wrapper {
    display: flex;
    height: 100vh;
    width: 100vw;
    overflow: hidden;
}

/* =========================================================
   1. Professional Left Sidebar (Callmatic / Vocalyn Style)
   ========================================================= */
.sidebar {
    width: 260px;
    min-width: 260px;
    background: #ffffff;
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100vh;
    overflow-y: auto;
    z-index: 20;
}

.sidebar-top {
    padding: 20px 16px 12px 16px;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 8px 18px 8px;
    border-bottom: 1px solid var(--border-color);
}

.brand-logo-wrap {
    width: 38px;
    height: 38px;
    background: linear-gradient(135deg, #7c3aed, #4f46e5);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    box-shadow: 0 2px 8px rgba(124, 58, 237, 0.3);
}

.brand-info h2 {
    font-size: 18px;
    font-weight: 800;
    letter-spacing: -0.5px;
    color: #101828;
    display: flex;
    align-items: center;
    gap: 4px;
}

.ai-badge {
    color: #7c3aed;
    font-size: 14px;
}

.brand-sub {
    font-size: 11px;
    color: var(--text-muted);
    display: block;
}

/* Workspace User Pill */
.workspace-pill {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f8fafc;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 8px 12px;
    margin: 14px 4px 18px 4px;
}

.workspace-avatar {
    width: 30px;
    height: 30px;
    background: #7c3aed;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 700;
}

.workspace-details {
    flex: 1;
    overflow: hidden;
}

.workspace-details strong {
    display: block;
    font-size: 12.5px;
    font-weight: 700;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.workspace-details span {
    font-size: 11px;
    color: var(--text-muted);
    display: block;
}

.btn-workspace-switch {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 14px;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.btn-workspace-switch:hover { opacity: 1; }

/* Navigation Group */
.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.nav-section-label {
    font-size: 10.5px;
    font-weight: 700;
    color: var(--text-light);
    letter-spacing: 0.8px;
    padding: 12px 12px 4px 12px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8.5px 12px;
    border-radius: var(--radius-sm);
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s ease;
    text-align: left;
    width: 100%;
}

.nav-item:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.nav-item.active {
    background: var(--primary-subtle);
    color: var(--primary);
    font-weight: 700;
}

.nav-icon {
    font-size: 15px;
}

/* Sidebar Bottom (Wallet Card) */
.sidebar-bottom {
    padding: 16px;
    border-top: 1px solid var(--border-color);
    background: #ffffff;
}

.sidebar-wallet-card {
    background: #f8fafc;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 12px 14px;
}

.wallet-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11.5px;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.wallet-progress-bar {
    height: 6px;
    background: #eaecf0;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 8px;
}

.wallet-progress-fill {
    height: 100%;
    background: var(--primary);
    border-radius: 4px;
}

.wallet-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11.5px;
}

.wallet-meta span { color: var(--text-muted); }
.wallet-meta strong { color: var(--text-primary); font-weight: 700; }

.sidebar-user-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 10px;
    padding-top: 6px;
}

.btn-logout-subtle {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
}

.btn-logout-subtle:hover { color: var(--danger); }

/* =========================================================
   2. Main Wrapper (Top Navigation & Views)
   ========================================================= */
.main-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100vh;
    overflow: hidden;
    background: var(--bg-page);
}

/* Callmatic Yellow Compliance Banner */
.compliance-banner {
    background: #fefce8;
    border-bottom: 1px solid #fef08a;
    color: #854d0e;
    font-size: 12px;
    font-weight: 500;
    padding: 7px 28px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.compliance-banner strong { font-weight: 700; }

/* Top Navbar */
.top-navbar {
    height: 64px;
    min-height: 64px;
    background: #ffffff;
    border-bottom: 1px solid var(--border-color);
    padding: 0 28px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.navbar-left .page-title {
    font-size: 19px;
    font-weight: 800;
    color: var(--text-primary);
    letter-spacing: -0.4px;
}

.navbar-left .page-subtitle {
    font-size: 12px;
    color: var(--text-muted);
}

.navbar-right {
    display: flex;
    align-items: center;
    gap: 14px;
}

.telecom-badge {
    background: #f8fafc;
    border: 1px solid var(--border-color);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    color: #027a48;
    display: flex;
    align-items: center;
    gap: 6px;
}

.pulse-dot {
    width: 7px;
    height: 7px;
    background: #10b981;
    border-radius: 50%;
    box-shadow: 0 0 6px #10b981;
}

.active-toggle-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11.5px;
    font-weight: 700;
    color: #10b981;
}

/* Toggle Switch */
.switch {
    position: relative;
    display: inline-block;
    width: 38px;
    height: 20px;
}

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

.slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: #cbd5e1;
    transition: .3s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 14px;
    width: 14px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .3s;
}

input:checked + .slider { background-color: #10b981; }
input:checked + .slider:before { transform: translateX(18px); }
.slider.round { border-radius: 20px; }
.slider.round:before { border-radius: 50%; }

.btn-emerald {
    background: #10b981;
    color: #ffffff;
    font-weight: 600;
    border: none;
    padding: 7px 14px;
    border-radius: var(--radius-sm);
    box-shadow: 0 1px 3px rgba(16, 185, 129, 0.3);
}

.btn-emerald:hover { background: #059669; }

.user-avatar-circle {
    width: 32px;
    height: 32px;
    background: #7c3aed;
    color: white;
    font-weight: 700;
    font-size: 13px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Workspace Scroll Area */
.workspace-content {
    flex: 1;
    overflow-y: auto;
    padding: 24px 28px 48px 28px;
}

.tab-pane {
    display: none;
    animation: fadeIn 0.2s ease-out;
}

.tab-pane.active {
    display: block;
}

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

/* =========================================================
   3. Cards & Vocalyn-Style Metric Tiles
   ========================================================= */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.metric-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px 18px;
    box-shadow: var(--shadow-sm);
    transition: transform 0.15s ease;
}

.metric-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.metric-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

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

.metric-icon-badge {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
}

.metric-icon-badge.gray { background: #f2f4f7; }
.metric-icon-badge.green { background: #ecfdf5; color: #027a48; }
.metric-icon-badge.purple { background: #f4f3ff; color: #6941c6; }
.metric-icon-badge.amber { background: #fffbeb; color: #b54708; }

.metric-val {
    font-size: 26px;
    font-weight: 800;
    color: var(--text-primary);
    letter-spacing: -0.5px;
}

.text-green { color: #027a48 !important; }
.text-purple { color: #6941c6 !important; }
.text-red { color: #b42318 !important; }

.metric-sub {
    font-size: 11px;
    color: var(--text-muted);
}

/* Vocalyn Metric Row (For Call History Tab) */
.vocalyn-metrics-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px;
}

.v-metric-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 14px 16px;
    box-shadow: var(--shadow-sm);
}

.v-card-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
}

.v-num {
    font-size: 24px;
    font-weight: 800;
    color: var(--text-primary);
    margin-top: 4px;
}

.v-sub {
    font-size: 10.5px;
    color: var(--text-light);
}

/* Cards & Grid */
.content-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(440px, 1fr));
    gap: 20px;
}

.card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.card-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fafafa;
}

.card-header h3 {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-primary);
}

.card-desc {
    font-size: 11.5px;
    color: var(--text-muted);
}

.card-body {
    padding: 20px;
}

.p-0 { padding: 0 !important; }
.max-w-700 { max-width: 700px; margin: 0 auto; }

/* Forms */
.form-group {
    margin-bottom: 14px;
}

.form-group label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 5px;
}

.form-row {
    display: flex;
    gap: 12px;
}

.flex-1 { flex: 1; }

input[type="text"],
input[type="email"],
input[type="password"],
input[type="tel"],
textarea,
select {
    width: 100%;
    background: #ffffff;
    border: 1px solid #d0d5dd;
    border-radius: var(--radius-sm);
    padding: 8.5px 12px;
    color: var(--text-primary);
    font-family: var(--font-sans);
    font-size: 13px;
    outline: none;
    transition: all 0.15s ease;
    box-shadow: 0 1px 2px rgba(16, 24, 40, 0.05);
}

input:focus,
textarea:focus,
select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.15);
}

input[type="range"] {
    width: 100%;
    accent-color: var(--primary);
    cursor: pointer;
}

.field-hint {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 3px;
}

/* Dropzone */
.dropzone {
    border: 2px dashed #d0d5dd;
    border-radius: var(--radius-md);
    padding: 22px;
    text-align: center;
    background: #f8fafc;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: 16px;
}

.dropzone:hover {
    border-color: var(--primary);
    background: #f4f3ff;
}

.small-dropzone { padding: 14px; }

.dropzone-icon {
    font-size: 26px;
    margin-bottom: 6px;
}

.dropzone h4 {
    font-size: 13.5px;
    font-weight: 700;
    color: var(--text-primary);
}

.dropzone p {
    font-size: 12px;
    color: var(--text-muted);
}

.dropzone-buttons {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 10px;
}

.file-name {
    display: block;
    margin-top: 8px;
    font-size: 12px;
    font-weight: 600;
    color: #027a48;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8.5px 16px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    border: 1px solid transparent;
    transition: all 0.15s ease;
    font-family: var(--font-sans);
}

.btn-primary {
    background: var(--primary);
    color: #ffffff;
    box-shadow: 0 1px 3px rgba(124, 58, 237, 0.25);
}

.btn-primary:hover {
    background: var(--primary-hover);
}

.btn-secondary {
    background: #ffffff;
    color: var(--text-secondary);
    border-color: #d0d5dd;
    box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
    background: #f9fafb;
    border-color: #98a2b3;
}

.btn-text {
    background: none;
    border: none;
    color: var(--primary);
    cursor: pointer;
}

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

.btn-warning { background: var(--warning); color: #fff; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-sm { padding: 5px 10px; font-size: 12px; }
.btn-lg { padding: 11px 20px; font-size: 14px; font-weight: 700; }
.w-100 { width: 100%; }

/* Badges */
.badge {
    font-size: 11px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 12px;
    display: inline-block;
}

.badge-purple { background: #f4f3ff; color: #6941c6; }
.badge-success { background: #ecfdf5; color: #027a48; }
.badge-warning { background: #fffbeb; color: #b54708; }
.badge-danger { background: #fef2f2; color: #b42318; }
.badge-secondary { background: #f2f4f7; color: #475467; }

.live-pill {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    font-weight: 700;
    color: #027a48;
    background: #ecfdf5;
    padding: 3px 9px;
    border-radius: 12px;
}

/* =========================================================
   4. Tables (White Vocalyn-Style)
   ========================================================= */
.table-container {
    overflow-x: auto;
    width: 100%;
}

.white-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
    text-align: left;
}

.white-table th {
    background: #f9fafb;
    padding: 10px 16px;
    color: var(--text-muted);
    font-weight: 600;
    border-bottom: 1px solid var(--border-color);
}

.white-table td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-secondary);
}

.white-table tr:hover td {
    background: #f8fafc;
}

/* Search bar on top of Table */
.search-header-wrap {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.search-input-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #ffffff;
    border: 1px solid #d0d5dd;
    border-radius: var(--radius-sm);
    padding: 6px 12px;
    width: 320px;
}

.search-input-wrap input {
    border: none;
    outline: none;
    box-shadow: none;
    padding: 0;
    font-size: 13px;
}

.table-header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.filter-pills-row {
    display: flex;
    gap: 5px;
}

.filter-pill {
    background: #f2f4f7;
    border: none;
    padding: 4px 10px;
    border-radius: 16px;
    font-size: 11.5px;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
}

.filter-pill.active {
    background: var(--primary);
    color: #ffffff;
}

/* =========================================================
   5. Callmatic Voice Studio Cards (Screenshot 3)
   ========================================================= */
.section-top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.section-top-bar h2 {
    font-size: 20px;
    font-weight: 800;
    color: var(--text-primary);
}

.voice-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
}

.white-voice-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 18px 20px;
    box-shadow: var(--shadow-sm);
}

.voice-card-header {
    margin-bottom: 14px;
}

.voice-title-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.voice-title-row h4 {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-primary);
}

.tag-pill {
    font-size: 10.5px;
    font-weight: 600;
    padding: 2px 7px;
    border-radius: 4px;
}

.tag-pill.public {
    background: #f2f4f7;
    color: #475467;
}

.voice-meta-text {
    font-size: 12px;
    color: var(--text-muted);
}

.voice-controls-row {
    display: flex;
    gap: 16px;
    margin-bottom: 14px;
}

.slider-group {
    flex: 1;
}

.slider-label-row {
    display: flex;
    justify-content: space-between;
    font-size: 11.5px;
    color: var(--text-muted);
    margin-bottom: 2px;
}

.slider-label-row strong {
    color: var(--text-primary);
}

.voice-preview-box {
    display: flex;
    gap: 8px;
}

.preview-text-input {
    background: #f8fafc !important;
    border: 1px solid #eaecf0 !important;
    font-size: 12px !important;
}

.btn-purple-play {
    background: var(--primary);
    color: white;
    font-weight: 700;
    border: none;
    border-radius: var(--radius-sm);
    padding: 6px 14px;
    font-size: 12.5px;
    cursor: pointer;
    white-space: nowrap;
}

.btn-purple-play:hover { background: var(--primary-hover); }

/* =========================================================
   6. Callmatic Plans Grid (Screenshot 2)
   ========================================================= */
.callmatic-plans-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 18px;
}

.c-plan-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    box-shadow: var(--shadow-sm);
}

.c-plan-card.popular-plan {
    border: 2px solid var(--primary);
    box-shadow: 0 8px 24px -4px rgba(124, 58, 237, 0.15);
}

.popular-tag {
    position: absolute;
    top: -11px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary);
    color: white;
    font-size: 10.5px;
    font-weight: 700;
    padding: 2px 12px;
    border-radius: 12px;
}

.c-plan-header h3 {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
}

.c-price {
    font-size: 26px;
    font-weight: 800;
    color: var(--text-primary);
    margin: 8px 0;
}

.c-period {
    font-size: 11.5px;
    font-weight: 500;
    color: var(--text-muted);
}

.c-features {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 20px 0 24px 0;
}

.c-feature-row {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    color: var(--text-secondary);
}

.c-btn-action {
    border-radius: var(--radius-sm);
    font-weight: 600;
}

.btn-purple-cta {
    background: var(--primary);
    color: white;
    border: none;
    box-shadow: 0 1px 3px rgba(124, 58, 237, 0.3);
}

.btn-purple-cta:hover { background: var(--primary-hover); }

/* Wallet Recharge Row */
.wallet-recharge-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.wallet-large-val {
    font-size: 34px;
    font-weight: 800;
    color: #027a48;
}

.recharge-buttons-row {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* Dedicated DIDs */
.did-number-box {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8fafc;
    border: 1px solid var(--border-color);
    padding: 16px;
    border-radius: var(--radius-md);
}

.did-left {
    display: flex;
    align-items: center;
    gap: 14px;
}

.did-icon {
    font-size: 24px;
    background: #ecfdf5;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
}

.did-number-text {
    font-size: 17px;
    font-weight: 800;
    color: var(--text-primary);
}

.did-meta {
    font-size: 12px;
    color: var(--text-muted);
}

.did-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

.did-cost {
    font-weight: 700;
    color: var(--text-primary);
    font-size: 13px;
}

.benefits-list {
    list-style: none;
}

.benefits-list li {
    padding: 8px 0;
    border-bottom: 1px solid var(--border-color);
    font-size: 13px;
    color: var(--text-secondary);
}

.industry-chips {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 6px;
}

.chip {
    background: #f2f4f7;
    border: 1px solid #eaecf0;
    color: var(--text-secondary);
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
}

.chip.active, .chip:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* Latency list */
.latency-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.lat-row {
    display: flex;
    justify-content: space-between;
    font-size: 12.5px;
    color: var(--text-secondary);
}

.lat-row.total {
    border-top: 1px solid var(--border-color);
    padding-top: 6px;
    font-weight: 700;
}

/* Modals */
.modal-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100vw; height: 100vh;
    background: rgba(16, 24, 40, 0.6);
    backdrop-filter: blur(4px);
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-content {
    background: #ffffff;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
}

.transcript-dialog-content { max-width: 620px; }
.auth-dialog-content { max-width: 440px; }

.modal-header {
    padding: 16px 22px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 { font-size: 16px; font-weight: 700; }

.modal-close {
    background: none;
    border: none;
    font-size: 22px;
    color: var(--text-muted);
    cursor: pointer;
}

.modal-body { padding: 20px 22px; }

.modal-footer {
    padding: 12px 22px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    background: #fafafa;
}

/* Interactive Chat Bubbles */
.transcript-messages-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 380px;
    overflow-y: auto;
    margin-top: 12px;
    padding: 6px 2px;
}

.chat-bubble {
    max-width: 82%;
    padding: 9px 14px;
    border-radius: 14px;
    font-size: 13px;
    line-height: 1.45;
}

.chat-bubble.assistant {
    align-self: flex-start;
    background: #f4f3ff;
    border: 1px solid #d8b4fe;
    color: #4c1d95;
    border-bottom-left-radius: 2px;
}

.chat-bubble.user {
    align-self: flex-end;
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    color: #0f172a;
    border-bottom-right-radius: 2px;
}

.bubble-sender {
    display: block;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 2px;
}

.chat-bubble.assistant .bubble-sender { color: #7c3aed; }
.chat-bubble.user .bubble-sender { color: #0284c7; }

.modal-audio-player-box {
    background: #f8fafc;
    border: 1px solid var(--border-color);
    padding: 10px 14px;
    border-radius: var(--radius-sm);
}

.auth-tabs {
    display: flex;
    gap: 6px;
    margin-bottom: 16px;
}

.auth-tab {
    flex: 1;
    padding: 8px;
    background: #f2f4f7;
    border: 1px solid #eaecf0;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-weight: 600;
    cursor: pointer;
}

.auth-tab.active {
    background: var(--primary);
    color: white;
}

.divider {
    height: 1px;
    background: var(--border-color);
    margin: 16px 0;
}

.mt-2 { margin-top: 8px; }
.mt-3 { margin-top: 14px; }
.mt-4 { margin-top: 20px; }
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.text-sm { font-size: 12px; }

/* Responsive adjustments */
@media (max-width: 900px) {
    .sidebar { width: 70px; min-width: 70px; }
    .brand-info, .workspace-details, .nav-label, .nav-section-label, .sidebar-wallet-card, .sidebar-user-footer { display: none; }
    .nav-item { justify-content: center; }
    .content-grid { grid-template-columns: 1fr; }
}

/* =========================================================
   7. Vocalyn & Callmatic Pixel-Perfect Refinements
   ========================================================= */
.v-icon-circle {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #f1f5f9;
    color: #475467;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    border: 1px solid #e2e8f0;
}
.v-icon-circle.green { background: #ecfdf5; color: #027a48; border-color: #a7f3d0; }
.v-icon-circle.blue { background: #f0f9ff; color: #0284c7; border-color: #bae6fd; }
.v-icon-circle.purple { background: #f5f3ff; color: #7c3aed; border-color: #ddd6fe; }
.v-icon-circle.red { background: #fef2f2; color: #dc2626; border-color: #fecaca; }

.table-type-pill {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 2.5px 8px;
    font-size: 11.5px;
    font-weight: 600;
    color: var(--text-secondary);
}
.lead-name-text {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: var(--text-primary);
}
.lead-phone-sub {
    display: block;
    font-size: 11px;
    color: var(--text-muted);
    font-family: var(--font-mono);
}
.duration-badge {
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
}
.flow-tag {
    background: #f8fafc;
    border: 1px solid #eaecf0;
    border-radius: 6px;
    padding: 2px 7px;
    font-size: 11px;
    color: var(--text-muted);
}
.cost-text {
    color: #027a48;
    font-size: 12.5px;
    font-weight: 700;
}
.table-action-btns {
    display: flex;
    align-items: center;
    gap: 6px;
}
.vocalyn-pagination-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 18px;
    border-top: 1px solid var(--border-color);
    background: #ffffff;
    font-size: 12.5px;
    color: var(--text-muted);
}
.pagination-page-pills {
    display: flex;
    align-items: center;
    gap: 4px;
}
.page-arrow-btn, .page-num-pill {
    border: 1px solid var(--border-color);
    background: #ffffff;
    border-radius: 6px;
    padding: 4px 10px;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.15s ease;
}
.page-num-pill.active {
    background: #0f172a;
    color: #ffffff;
    border-color: #0f172a;
}
.page-arrow-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

/* Callmatic Voice Studio Filter Bar */
.voice-header-title-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
}
.voice-header-icon {
    width: 38px;
    height: 38px;
    background: #7c3aed;
    color: white;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 17px;
    box-shadow: 0 2px 8px rgba(124, 58, 237, 0.25);
}
.voice-filters-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 10px 16px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 10px;
}
.voice-filter-tabs {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.v-tab {
    background: transparent;
    border: 1px solid transparent;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12.5px;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
}
.v-tab:hover { background: #f8fafc; }
.v-tab.active {
    background: #f4f3ff;
    color: var(--primary);
    border-color: #d8b4fe;
}
.v-select-filter {
    background: #ffffff;
    border: 1px solid #d0d5dd;
    border-radius: 20px;
    padding: 4px 10px;
    font-size: 12px;
    color: var(--text-secondary);
    font-weight: 500;
    cursor: pointer;
}
.voice-count-indicators {
    display: flex;
    align-items: center;
    gap: 8px;
}
.v-indicator-badge {
    background: #f8fafc;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 3px 9px;
    font-size: 11.5px;
    color: var(--text-muted);
}
.v-indicator-badge strong { color: var(--text-primary); }

/* Campaign AI Copilot Box */
.copilot-assistant-box {
    background: #faf5ff;
    border: 1px solid #e9d5ff;
    border-radius: var(--radius-md);
    padding: 16px;
    margin-bottom: 18px;
}
.copilot-title-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}
.copilot-badge-icon {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    background: #7c3aed;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
}
.copilot-sub {
    font-size: 11.5px;
    color: #6b21a8;
}
.copilot-curly-hint {
    background: #ffffff;
    border: 1px solid #f3e8ff;
    border-radius: var(--radius-sm);
    padding: 8px 12px;
    font-size: 11.5px;
    color: #581c87;
    margin-bottom: 12px;
}
.copilot-curly-hint code {
    background: #f3e8ff;
    padding: 1px 4px;
    border-radius: 4px;
    font-family: var(--font-mono);
    color: #7c3aed;
}
.languages-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11.5px;
    color: var(--text-muted);
    margin-bottom: 6px;
}
.languages-top a {
    color: #7c3aed;
    text-decoration: none;
    font-weight: 600;
}
.languages-top a:hover { text-decoration: underline; }
.language-chips-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 12px;
}
.lang-chip {
    background: #ffffff;
    border: 1px solid #d8b4fe;
    border-radius: 16px;
    padding: 4px 10px;
    font-size: 11.5px;
    font-weight: 500;
    color: #4c1d95;
    cursor: pointer;
    transition: all 0.15s ease;
}
.lang-chip:hover, .lang-chip.active {
    background: #7c3aed;
    color: #ffffff;
    border-color: #7c3aed;
}
.copilot-input-box {
    display: flex;
    gap: 8px;
}
.copilot-input-box input {
    background: #ffffff;
    border: 1px solid #d8b4fe;
    font-size: 12.5px;
}

/* Callmatic WhatsApp Support Floating Pill */
.whatsapp-support-pill {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 30px;
    padding: 6px 6px 6px 14px;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 6px 20px rgba(16, 24, 40, 0.12);
    text-decoration: none;
    z-index: 100;
    transition: all 0.2s ease;
}
.whatsapp-support-pill:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(16, 24, 40, 0.16);
}
.whatsapp-pill-text {
    font-size: 11.5px;
    line-height: 1.25;
    color: var(--text-secondary);
}
.whatsapp-pill-text strong {
    display: block;
    color: var(--text-primary);
    font-weight: 700;
}
.whatsapp-green-badge {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #25d366;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(37, 211, 102, 0.4);
}

/* =========================================================
   AI Stack Quota & Health Status Indicator & Modal
   ========================================================= */
.ai-health-pill-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    border-radius: 20px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    font-size: 12px;
    font-weight: 600;
    color: #334155;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
}
.ai-health-pill-wrap:hover {
    background: #f1f5f9;
    border-color: #cbd5e1;
    transform: translateY(-1px);
}
.ai-health-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #94a3b8;
    display: inline-block;
    transition: background-color 0.3s ease;
}
.ai-health-dot.dot-ready {
    background: #10b981;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}
.ai-health-dot.dot-warning {
    background: #f59e0b;
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.2);
}
.ai-health-dot.dot-blocked {
    background: #ef4444;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.25);
    animation: healthPulse 1.8s infinite;
}
@keyframes healthPulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.2); opacity: 0.8; }
}

.health-service-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 12px 16px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.health-service-card.service-ok {
    border-color: #a7f3d0;
    background: #f0fdf4;
}
.health-service-card.service-error {
    border-color: #fecaca;
    background: #fef2f2;
}
.health-service-card.service-warning {
    border-color: #fde68a;
    background: #fffbeb;
}

