/* ==========================================================================
   Call Center AI & Audio Explorer - Premium Glassmorphism Dark Theme
   ========================================================================== */

:root {
    --bg-primary: #0b0f19;
    --bg-secondary: #111827;
    --bg-card: #131d31;
    --bg-card-hover: #1a2742;
    --bg-sidebar: #0f172a;
    --border-color: rgba(255, 255, 255, 0.08);
    --border-glow: rgba(99, 102, 241, 0.3);
    
    --primary: #6366f1;
    --primary-glow: rgba(99, 102, 241, 0.4);
    --secondary: #06b6d4;
    --accent: #8b5cf6;
    --success: #10b981;
    --success-glow: rgba(16, 185, 129, 0.3);
    --warning: #f59e0b;
    --danger: #ef4444;
    --danger-glow: rgba(239, 68, 68, 0.3);
    
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --text-dim: #64748b;
    
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    
    --sidebar-width: 360px;
    --transition-speed: 0.25s;
}

/* ==========================================================================
   Iconsax Universal Linear Icons
   ========================================================================== */
.isax,
svg.isax {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.15em;
    height: 1.15em;
    vertical-align: -0.18em;
    stroke: currentColor;
    fill: none;
    flex-shrink: 0;
}
.isax-sm { width: 1em; height: 1em; vertical-align: -0.14em; }
.isax-md { width: 1.25em; height: 1.25em; vertical-align: -0.18em; }
.isax-lg { width: 1.5em; height: 1.5em; vertical-align: -0.22em; }
.isax-xl { width: 1.85em; height: 1.85em; vertical-align: -0.25em; }

/* Accessible Screen-Reader Utility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* ==========================================================================
   Russian (Cyrillic) Custom Typography — Golos Text
   ========================================================================== */
html[lang="ru"] {
    --font-family: 'Golos Text', 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

html[lang="ru"] body,
html[lang="ru"] button,
html[lang="ru"] input,
html[lang="ru"] select,
html[lang="ru"] textarea,
html[lang="ru"] h1, html[lang="ru"] h2, html[lang="ru"] h3, html[lang="ru"] h4,
html[lang="ru"] .kpi-card,
html[lang="ru"] .nav-tab,
html[lang="ru"] .sidebar-title,
html[lang="ru"] .section-title,
html[lang="ru"] table,
html[lang="ru"] th,
html[lang="ru"] td {
    font-family: 'Golos Text', 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* ==========================================================================
   Global Custom Dark Theme Scrollbars
   Oq rangli fon (scrollbar-track) to'liq fonga mos qorong'i qilindi
   ========================================================================== */
html, body, div, table, tbody, * {
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.22) #0b1120;
}

/* WebKit (Chrome, Edge, Safari, Brave, Opera) */
::-webkit-scrollbar {
    width: 7px;
    height: 7px;
}

::-webkit-scrollbar-track {
    background: #0b1120 !important; /* Qorong'i fon, oq rang yo'qotildi */
    border-radius: 8px;
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2) !important;
    border-radius: 8px;
    border: 1px solid #0b1120;
    transition: background 0.2s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: #3b82f6 !important; /* Hoverda neon ko'k */
}

::-webkit-scrollbar-thumb:active {
    background: #2563eb !important;
}

::-webkit-scrollbar-corner {
    background: #0b1120 !important;
}

/* Specific scroll containers */
#tabOperatorLogsContainer::-webkit-scrollbar-track,
.data-table-wrapper::-webkit-scrollbar-track,
.fluent-calendar-popup::-webkit-scrollbar-track {
    background: #0b1120 !important;
}

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

body {
    font-family: var(--font-family);
    background-color: var(--bg-primary);
    color: var(--text-main);
    line-height: 1.5;
    overflow-x: hidden;
    min-height: 100vh;
    background-image: 
        radial-gradient(at 0% 0%, rgba(99, 102, 241, 0.12) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(6, 182, 212, 0.08) 0px, transparent 50%);
    background-attachment: fixed;
}

/* App Wrapper */
.app-container {
    display: flex;
    width: 100vw;
    height: 100vh;
    overflow: hidden;
}

/* Main Content Area */
.main-area {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100vh;
    overflow-y: auto;
    padding-right: var(--sidebar-width);
}

/* Header */
.top-navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 28px;
    min-height: 74px;
    box-sizing: border-box;
    flex-shrink: 0;
    /* backdrop-filter olib tashlandi: sticky header ostida scroll qilinganda har freymda
       qayta xiralashtirish (blur) kuchsiz GPU'larda scroll "tortishishi"ga sabab bo'lardi.
       O'rniga deyarli qattiq fon bilan bir xil ko'rinish saqlanadi. */
    background: rgba(15, 23, 42, 0.97);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 300;
}

.brand-section {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-badge {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    background: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border: none;
    box-shadow: none;
}

.logo-badge img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 10px;
    display: block;
    border: none;
}

.brand-info h1 {
    font-size: 18px;
    font-weight: 700;
    letter-spacing: -0.5px;
    background: linear-gradient(90deg, #ffffff, #cbd5e1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

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

/* Status Badges */
.status-pill-group {
    display: flex;
    gap: 10px;
    align-items: center;
}

.status-pill {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 500;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: var(--text-dim);
}

.status-pill.online .status-dot {
    background-color: var(--success);
    box-shadow: 0 0 10px var(--success-glow);
    animation: pulse 2s infinite;
}

.status-pill.offline .status-dot {
    background-color: var(--danger);
    box-shadow: 0 0 10px var(--danger-glow);
}

/* Settings Button in Navbar */
.settings-nav-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    background: rgba(59, 130, 246, 0.12);
    border: 1px solid rgba(59, 130, 246, 0.35);
    color: #93c5fd;
    cursor: pointer;
    transition: all 0.2s ease;
}

.settings-nav-btn:hover {
    background: rgba(59, 130, 246, 0.25);
    border-color: rgba(59, 130, 246, 0.6);
    color: #fff;
    transform: translateY(-1px);
}

.agent-ver-badge {
    background: rgba(16, 185, 129, 0.18);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.4);
    padding: 1px 6px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 700;
    margin-left: 4px;
}

@keyframes pulse {
    0% { transform: scale(0.95); opacity: 0.8; }
    50% { transform: scale(1.2); opacity: 1; }
    100% { transform: scale(0.95); opacity: 0.8; }
}

/* Global Select & Option Dropdown Dark Styling */
select, 
select option {
    background-color: #0f172a !important;
    color: #ffffff !important;
}

select option {
    padding: 8px 12px;
}

select option:checked, 
select option:hover {
    background-color: #2563eb !important;
    color: #ffffff !important;
}

/* Nav Tabs */
.nav-tabs {
    display: flex;
    gap: 8px;
    background: rgba(0, 0, 0, 0.2);
    padding: 4px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
}

.tab-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    background: transparent;
    border: none;
    text-decoration: none;
    color: var(--text-muted);
    font-size: 13px;
    font-weight: 600;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition-speed);
}

.tab-btn:hover {
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.05);
}

.tab-btn.active {
    color: #fff;
    background: var(--primary);
    box-shadow: 0 4px 12px var(--primary-glow);
}

/* Content Container */
.page-content {
    padding: 28px;
    display: none;
}

.page-content.active {
    display: block;
    animation: fadeIn 0.3s ease-in-out;
}

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

/* KPI Cards Grid */
.kpi-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}

@media (max-width: 1300px) {
    .kpi-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .kpi-grid {
        grid-template-columns: 1fr;
    }
}

.kpi-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 20px 22px;
    min-height: 145px;
    height: auto;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    gap: 16px;
    position: relative;
    overflow: hidden;
    transition: transform var(--transition-speed), border-color var(--transition-speed);
}

.kpi-card:hover {
    transform: translateY(-2px);
    border-color: var(--border-glow);
}

.kpi-icon {
    width: 62px;
    height: 62px;
    min-width: 62px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent !important;
}

.kpi-icon img {
    width: 54px;
    height: 54px;
    object-fit: contain;
    filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.45));
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.kpi-card:hover .kpi-icon img {
    transform: scale(1.12);
}

/* KPI Cards Top Colored Borders */
.kpi-card.blue {
    border-top: 3px solid #3b82f6;
}
.kpi-card.cyan {
    border-top: 3px solid #06b6d4;
}
.kpi-card.purple {
    border-top: 3px solid #a855f7;
}
.kpi-card.green {
    border-top: 3px solid #10b981;
}
.kpi-card.amber {
    border-top: 3px solid #f59e0b;
}
.kpi-card.orange {
    border-top: 3px solid #f97316;
}
.kpi-card.red {
    border-top: 3px solid #ef4444;
}
.kpi-card.indigo {
    border-top: 3px solid #6366f1;
}
.kpi-card.teal {
    border-top: 3px solid #14b8a6;
}

/* Hover Accent Glow */
.kpi-card.blue:hover { border-top-color: #60a5fa; box-shadow: 0 6px 20px rgba(59, 130, 246, 0.18); }
.kpi-card.cyan:hover { border-top-color: #22d3ee; box-shadow: 0 6px 20px rgba(6, 182, 212, 0.18); }
.kpi-card.purple:hover { border-top-color: #c084fc; box-shadow: 0 6px 20px rgba(168, 85, 247, 0.18); }
.kpi-card.green:hover { border-top-color: #34d399; box-shadow: 0 6px 20px rgba(16, 185, 129, 0.18); }
.kpi-card.amber:hover { border-top-color: #fbbf24; box-shadow: 0 6px 20px rgba(245, 158, 11, 0.18); }
.kpi-card.orange:hover { border-top-color: #fb923c; box-shadow: 0 6px 20px rgba(249, 115, 22, 0.18); }
.kpi-card.red:hover { border-top-color: #f87171; box-shadow: 0 6px 20px rgba(239, 68, 68, 0.18); }
.kpi-card.indigo:hover { border-top-color: #818cf8; box-shadow: 0 6px 20px rgba(99, 102, 241, 0.18); }
.kpi-card.teal:hover { border-top-color: #2dd4bf; box-shadow: 0 6px 20px rgba(20, 184, 166, 0.18); }

.kpi-card.blue .kpi-icon { color: var(--primary); }
.kpi-card.cyan .kpi-icon { color: var(--secondary); }
.kpi-card.purple .kpi-icon { color: #c084fc; }
.kpi-card.green .kpi-icon { color: var(--success); }
.kpi-card.red .kpi-icon { color: var(--danger); }
.kpi-card.amber .kpi-icon { color: var(--warning); }

/* Card ichidagi text rangi borderiga mos ravishda */
.kpi-card.blue .kpi-details p { color: #60a5fa; }
.kpi-card.cyan .kpi-details p { color: #22d3ee; }
.kpi-card.purple .kpi-details p { color: #c084fc; }
.kpi-card.green .kpi-details p { color: #34d399; }
.kpi-card.amber .kpi-details p { color: #fbbf24; }
.kpi-card.indigo .kpi-details p { color: #818cf8; }
.kpi-card.red .kpi-details p { color: #f87171; }

.kpi-details {
    display: flex;
    flex-direction: column;
    justify-content: center;
    flex: 1;
}

.kpi-details p {
    font-size: 11.5px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.4px;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: flex;
    align-items: center;
    margin-bottom: 4px;
}

.kpi-details h3 {
    font-size: 26px;
    font-weight: 700;
    margin-top: 0;
    line-height: 1.2;
}

.kpi-badge {
    font-size: 11px;
    padding: 2px 6px;
    border-radius: 4px;
    margin-left: 6px;
}

.kpi-badge.success { background: rgba(16, 185, 129, 0.2); color: #34d399; }
.kpi-badge.danger { background: rgba(239, 68, 68, 0.2); color: #f87171; }
.kpi-badge.warning { background: rgba(245, 158, 11, 0.2); color: #fbbf24; }
.kpi-badge.purple { background: rgba(168, 85, 247, 0.2); color: #c084fc; border: 1px solid rgba(168, 85, 247, 0.3); }

/* ==========================================================================
   KPI PARENT SECTION FOCUS ZOOM MOTION DESIGN (Apple / Stripe FLIP Style)
   ========================================================================== */

.kpi-parent-section {
    position: relative;
    margin-bottom: 24px;
    transition: transform 450ms cubic-bezier(0.16, 1, 0.3, 1), box-shadow 450ms cubic-bezier(0.16, 1, 0.3, 1);
}

/* Toolbar positioned above sections */
.kpi-parent-toolbar,
.charts-parent-toolbar,
.section-parent-toolbar {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    margin-bottom: 8px;
    padding: 0 4px;
}

/* Elegant Eye Focus Button (Universal for KPI, Charts, Operators) */
.kpi-parent-zoom-btn,
.section-focus-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 14px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #94a3b8;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    outline: none;
    backdrop-filter: blur(8px);
}
.kpi-parent-zoom-btn svg,
.section-focus-btn svg {
    width: 15px;
    height: 15px;
    color: currentColor;
    transition: transform 0.25s ease, color 0.25s ease;
}
.kpi-parent-zoom-btn:hover,
.section-focus-btn:hover {
    background: rgba(56, 189, 248, 0.15);
    border-color: rgba(56, 189, 248, 0.45);
    color: #38bdf8;
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(56, 189, 248, 0.25);
}
.kpi-parent-zoom-btn:hover svg,
.section-focus-btn:hover svg {
    transform: scale(1.1);
}

/* Backdrop for Focus Zoom */
#kpiFocusBackdrop,
#sectionFocusBackdrop,
.section-focus-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(5, 9, 24, 0.82);
    backdrop-filter: blur(16px) brightness(0.28);
    -webkit-backdrop-filter: blur(16px) brightness(0.28);
    z-index: 10040;
    opacity: 0;
    pointer-events: none;
    transition: opacity 400ms cubic-bezier(0.16, 1, 0.3, 1), backdrop-filter 400ms cubic-bezier(0.16, 1, 0.3, 1);
}
#kpiFocusBackdrop.active,
#sectionFocusBackdrop.active,
.section-focus-backdrop.active {
    opacity: 1;
    pointer-events: auto;
}

/* Background Dimming & Blur when ANY Section Focus Zoom is Active */
body.kpi-focus-active .top-navbar,
body.kpi-focus-active .date-filter-bar,
body.kpi-focus-active .right-sidebar,
body.kpi-focus-active .sidebar-floating-expand-btn,
body.kpi-focus-active .charts-parent-section,
body.kpi-focus-active .operators-parent-section,
body.section-focus-active .top-navbar,
body.section-focus-active .date-filter-bar,
body.section-focus-active .right-sidebar,
body.section-focus-active .sidebar-floating-expand-btn,
body.section-focus-active .kpi-parent-section:not(.section-focused),
body.section-focus-active .charts-parent-section:not(.section-focused),
body.section-focus-active .operators-parent-section:not(.section-focused) {
    transition: filter 400ms cubic-bezier(0.16, 1, 0.3, 1), opacity 400ms cubic-bezier(0.16, 1, 0.3, 1) !important;
    filter: blur(8px) grayscale(40%) !important;
    opacity: 0.12 !important;
    user-select: none !important;
    pointer-events: none !important;
}

/* Focused Section va uning ichidagi barcha elementlar TO'LIQ tiniq, yorug' va 100% ko'rinadi */
.section-focused,
.section-focused *,
.section-focused .glass-panel,
.section-focused .charts-grid,
.section-focused .chart-wrapper,
.section-focused canvas,
.section-focused .highcharts-container,
.section-focused .highcharts-root,
.section-focused svg {
    filter: none !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    user-select: auto !important;
}

/* Universal Focused Section (Elevated, Centered, Scaled to Screen) */
.section-focused,
.kpi-parent-section.kpi-parent-focused {
    position: fixed !important;
    z-index: 10050 !important;
    margin: 0 !important;
    border-radius: 26px !important;
    background: linear-gradient(145deg, rgba(16, 24, 44, 0.97) 0%, rgba(9, 15, 30, 0.98) 100%) !important;
    border: 1.5px solid rgba(56, 189, 248, 0.45) !important;
    box-shadow: 0 0 100px rgba(0, 0, 0, 0.95), 0 30px 90px rgba(56, 189, 248, 0.25) !important;
    backdrop-filter: blur(24px) !important;
    -webkit-backdrop-filter: blur(24px) !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
}

/* Close Button Style inside Focused Section */
.section-focused .section-focus-btn,
.section-focused .kpi-parent-zoom-btn,
.kpi-parent-section.kpi-parent-focused .kpi-parent-zoom-btn {
    padding: 7px 16px;
    background: rgba(239, 68, 68, 0.15);
    border-color: rgba(239, 68, 68, 0.4);
    color: #f87171;
    font-size: 13px;
}
.section-focused .section-focus-btn:hover,
.section-focused .kpi-parent-zoom-btn:hover,
.kpi-parent-section.kpi-parent-focused .kpi-parent-zoom-btn:hover {
    background: rgba(239, 68, 68, 0.28);
    border-color: #ef4444;
    color: #fff;
    box-shadow: 0 4px 16px rgba(239, 68, 68, 0.35);
}

/* ================== SPECIFIC SECTION ZOOM LAYOUTS ================== */

/* 1. KPI SECTION (4x2 Plita Grid) */
.kpi-parent-section.section-focused,
.kpi-parent-section.kpi-parent-focused {
    padding: 22px 28px 24px 28px !important;
    display: flex !important;
    flex-direction: column !important;
}
.kpi-parent-section.section-focused .kpi-parent-toolbar,
.kpi-parent-section.kpi-parent-focused .kpi-parent-toolbar {
    margin-bottom: 14px !important;
    flex-shrink: 0 !important;
}

/* 2. CHARTS SECTION (Dinamika + Taqsimot High-Res Widescreen) */
.charts-parent-section {
    position: relative;
    margin-bottom: 28px;
    transition: transform 450ms cubic-bezier(0.16, 1, 0.3, 1), box-shadow 450ms cubic-bezier(0.16, 1, 0.3, 1);
}
.charts-parent-section.section-focused {
    display: flex !important;
    flex-direction: column !important;
    padding: 22px 28px 24px 28px !important;
}
.charts-parent-section.section-focused .charts-parent-toolbar {
    margin-bottom: 14px !important;
    flex-shrink: 0 !important;
}
.charts-parent-section.section-focused .charts-grid {
    flex: 1 1 auto !important;
    display: grid !important;
    grid-template-columns: minmax(0, 2fr) minmax(0, 1.15fr) !important;
    gap: 22px !important;
    margin-bottom: 0 !important;
    height: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
}
.charts-parent-section.section-focused .charts-grid > * {
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
}
.charts-parent-section.section-focused .glass-panel {
    height: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    box-sizing: border-box !important;
    padding: 18px 22px !important;
    border-color: rgba(255, 255, 255, 0.12) !important;
    box-shadow: 0 8px 26px rgba(0, 0, 0, 0.4) !important;
}
.charts-parent-section.section-focused .chart-wrapper {
    flex: 1 1 auto !important;
    height: 100% !important;
    min-height: 320px !important;
    position: relative !important;
}
.charts-parent-section.section-focused #callDistributionChartContainer,
.charts-parent-section.section-focused #callDistribution2DContainer {
    height: 100% !important;
    min-height: 320px !important;
}

/* 3. OPERATORS SECTION (Expanded Grid) */
.operators-parent-section {
    position: relative;
    transition: transform 450ms cubic-bezier(0.16, 1, 0.3, 1), box-shadow 450ms cubic-bezier(0.16, 1, 0.3, 1);
}
.operators-parent-section.section-focused {
    display: flex !important;
    flex-direction: column !important;
    padding: 22px 28px 24px 28px !important;
}
.operators-parent-section.section-focused .panel-header {
    margin-bottom: 16px !important;
    flex-shrink: 0 !important;
}
.operators-parent-section.section-focused .operator-grid {
    flex: 1 1 auto !important;
    overflow-y: auto !important;
    max-height: 100% !important;
    padding-right: 6px !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 16px 20px !important;
}
.operators-parent-section.section-focused .operator-grid::-webkit-scrollbar {
    width: 6px;
}
.operators-parent-section.section-focused .operator-grid::-webkit-scrollbar-thumb {
    background: rgba(56, 189, 248, 0.3);
    border-radius: 4px;
}

/* 4x2 plita grid butun bo'shliqni proporsional to'ldiradi */
.kpi-parent-section.kpi-parent-focused .kpi-grid {
    flex: 1 1 auto !important;
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    grid-template-rows: repeat(2, 1fr) !important;
    gap: 16px 20px !important;
    margin-bottom: 0 !important;
    height: 100% !important;
    width: 100% !important;
}

.kpi-parent-section.kpi-parent-focused .kpi-card {
    min-height: 0 !important;
    height: 100% !important;
    box-sizing: border-box !important;
    box-shadow: 0 8px 26px rgba(0, 0, 0, 0.45) !important;
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: clamp(14px, 1.6vh, 22px) clamp(16px, 1.8vw, 24px) !important;
    border-radius: 18px !important;
    display: flex !important;
    align-items: center !important;
    gap: clamp(14px, 1.6vw, 22px) !important;
}

/* Kartochkalar tepasidagi rangli border chiziqlari (Zoom holatida saqlanadi va yorqin ko'rinadi) */
.kpi-parent-section.kpi-parent-focused .kpi-card.blue { border-top: 3.5px solid #3b82f6 !important; }
.kpi-parent-section.kpi-parent-focused .kpi-card.cyan { border-top: 3.5px solid #06b6d4 !important; }
.kpi-parent-section.kpi-parent-focused .kpi-card.purple { border-top: 3.5px solid #a855f7 !important; }
.kpi-parent-section.kpi-parent-focused .kpi-card.green { border-top: 3.5px solid #10b981 !important; }
.kpi-parent-section.kpi-parent-focused .kpi-card.amber { border-top: 3.5px solid #f59e0b !important; }
.kpi-parent-section.kpi-parent-focused .kpi-card.orange { border-top: 3.5px solid #f97316 !important; }
.kpi-parent-section.kpi-parent-focused .kpi-card.red { border-top: 3.5px solid #ef4444 !important; }
.kpi-parent-section.kpi-parent-focused .kpi-card.indigo { border-top: 3.5px solid #6366f1 !important; }
.kpi-parent-section.kpi-parent-focused .kpi-card.teal { border-top: 3.5px solid #14b8a6 !important; }

.kpi-parent-section.kpi-parent-focused .kpi-icon {
    width: clamp(56px, 4.2vw, 72px) !important;
    height: clamp(56px, 4.2vw, 72px) !important;
    min-width: clamp(56px, 4.2vw, 72px) !important;
}

.kpi-parent-section.kpi-parent-focused .kpi-icon img {
    width: clamp(52px, 3.8vw, 66px) !important;
    height: clamp(52px, 3.8vw, 66px) !important;
}

.kpi-parent-section.kpi-parent-focused .kpi-icon svg {
    width: clamp(40px, 3.2vw, 54px) !important;
    height: clamp(40px, 3.2vw, 54px) !important;
}

.kpi-parent-section.kpi-parent-focused .kpi-details p {
    font-size: clamp(11.5px, 0.82vw, 13px) !important;
    letter-spacing: 0.5px !important;
    margin-bottom: 4px !important;
}

.kpi-parent-section.kpi-parent-focused .kpi-details h3 {
    font-size: clamp(26px, 2.3vw, 38px) !important;
    line-height: 1.15 !important;
    margin-bottom: 4px !important;
}

.kpi-parent-section.kpi-parent-focused .kpi-details h3 span[style*="font-size: 13px"] {
    font-size: clamp(13px, 0.95vw, 15px) !important;
}

.kpi-parent-section.kpi-parent-focused .kpi-badge {
    font-size: clamp(11px, 0.8vw, 13px) !important;
    padding: 3px 8px !important;
}

.kpi-parent-section.kpi-parent-focused .kpi-details div[style*="font-size: 11px"] {
    font-size: clamp(11.5px, 0.8vw, 12.5px) !important;
}

/* 5-talik Mijozlar Soni Switch Buttons (J, K, CH, O', N) */
.client-type-badge {
    font-size: 10px;
    font-weight: 700;
    color: #38bdf8;
    background: rgba(56, 189, 248, 0.12);
    border: 1px solid rgba(56, 189, 248, 0.28);
    border-radius: 5px;
    padding: 1px 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.client-kpi-switch {
    display: inline-flex;
    align-items: center;
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 3px;
    gap: 4px;
    width: fit-content;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.4);
}

.client-switch-btn {
    border: none;
    background: transparent;
    color: #94a3b8;
    font-size: 11px;
    font-weight: 700;
    min-width: 28px;
    min-height: 28px;
    padding: 3px 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    line-height: 1;
}

.client-switch-btn:hover {
    color: #38bdf8;
    background: rgba(56, 189, 248, 0.15);
}

.client-switch-btn.active {
    background: linear-gradient(135deg, #0284c7, #0369a1);
    color: #ffffff;
    box-shadow: 0 2px 6px rgba(2, 132, 199, 0.4);
}

/* Focused / Zoom holatida switch tugmalarining chiroyli masshtablanishi */
.kpi-parent-section.section-focused .client-kpi-switch,
.kpi-parent-section.kpi-parent-focused .client-kpi-switch {
    padding: 3px !important;
    gap: 4px !important;
    border-radius: 10px !important;
}

.kpi-parent-section.section-focused .client-switch-btn,
.kpi-parent-section.kpi-parent-focused .client-switch-btn {
    font-size: 13px !important;
    padding: 4px 10px !important;
    border-radius: 8px !important;
}

.kpi-parent-section.section-focused .client-type-badge,
.kpi-parent-section.kpi-parent-focused .client-type-badge {
    font-size: 12px !important;
    padding: 2px 8px !important;
}

/* Charts Layout */
.charts-grid {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 1.15fr);
    gap: 20px;
    margin-bottom: 28px;
    width: 100%;
    box-sizing: border-box;
}

.charts-grid > * {
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
}

@media (max-width: 1200px) {
    .charts-grid { grid-template-columns: 1fr; }
}

.glass-panel {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 22px;
    min-width: 0 !important;
    box-sizing: border-box !important;
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 18px;
}

.panel-title {
    font-size: 16px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.chart-wrapper {
    position: relative;
    height: 280px;
    width: 100%;
    min-width: 0 !important;
    max-width: 100% !important;
    overflow: hidden;
}

#callVolumeChart {
    width: 100% !important;
    max-width: 100% !important;
    height: 100% !important;
}

#callDistributionChartContainer,
#callDistribution2DContainer {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    overflow: hidden;
}

#callDistributionChartContainer .highcharts-container,
#callDistributionChartContainer svg {
    max-width: 100% !important;
    width: 100% !important;
}

/* Windows-like Audio Explorer */
.explorer-container {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.explorer-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    background: rgba(15, 23, 42, 0.6);
    padding: 12px 16px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
}

.explorer-nav-buttons .btn-nav-icon {
    transition: all 0.2s ease;
    color: var(--text-muted);
}

.explorer-nav-buttons .btn-nav-icon:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.12) !important;
    color: #fff !important;
    transform: scale(1.05);
}

.explorer-nav-buttons .btn-nav-icon:active:not(:disabled) {
    transform: scale(0.95);
}

.explorer-nav-buttons .btn-nav-icon:disabled {
    opacity: 0.25 !important;
    cursor: not-allowed !important;
    pointer-events: none;
}

.breadcrumb-nav {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--text-muted);
    overflow-x: auto;
}

.breadcrumb-item {
    cursor: pointer;
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    transition: all 0.2s;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 4px;
}

.breadcrumb-item:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.breadcrumb-item.active {
    color: var(--primary);
    font-weight: 600;
}

.search-box {
    position: relative;
    min-width: 240px;
}

.search-box input {
    width: 100%;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border-color);
    padding: 8px 14px 8px 34px;
    border-radius: var(--radius-sm);
    color: #fff;
    font-size: 13px;
    outline: none;
    transition: border-color 0.2s;
}

.search-box input:focus {
    border-color: var(--primary);
}

.search-icon {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--text-dim);
    pointer-events: none;
}

/* Explorer Grid / Table */
.explorer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 14px;
    margin-bottom: 20px;
}

.folder-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 6px;
    cursor: pointer;
    transition: all var(--transition-speed);
}

.folder-card:hover {
    background: rgba(99, 102, 241, 0.1);
    border-color: var(--primary);
    transform: translateY(-3px);
}

.folder-icon {
    font-size: 36px;
    color: #f59e0b;
}

.folder-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-main);
    word-break: break-word;
}

.folder-subtitle {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: -2px;
    font-weight: 400;
}

.folder-meta-row {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 4px;
}

.folder-size {
    font-size: 11px;
    font-weight: 600;
    color: #38bdf8;
    background: rgba(56, 189, 248, 0.12);
    border: 1px solid rgba(56, 189, 248, 0.28);
    padding: 2px 7px;
    border-radius: 6px;
    letter-spacing: 0.2px;
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
    font-family: 'Inter', monospace;
    transition: all 0.2s ease;
}

.folder-card:hover .folder-size {
    border-color: rgba(56, 189, 248, 0.55);
    background: rgba(56, 189, 248, 0.22);
    color: #7dd3fc;
    box-shadow: 0 0 10px rgba(56, 189, 248, 0.2);
}

.folder-time {
    font-size: 10px;
    font-weight: 500;
    color: #a78bfa;
    background: rgba(167, 139, 250, 0.12);
    border: 1px solid rgba(167, 139, 250, 0.28);
    padding: 2px 6px;
    border-radius: 6px;
    letter-spacing: 0.2px;
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
    font-family: 'Inter', monospace;
    transition: all 0.2s ease;
}

.folder-card:hover .folder-time {
    border-color: rgba(167, 139, 250, 0.55);
    background: rgba(167, 139, 250, 0.22);
    color: #c4b5fd;
    box-shadow: 0 0 10px rgba(167, 139, 250, 0.2);
}

/* Custom Data Table */
.data-table-wrapper {
    width: 100%;
    overflow-x: auto;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
}

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

.data-table th {
    background: rgba(30, 41, 59, 0.85);
    padding: 12px 14px;
    color: var(--text-muted);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    border-bottom: 1px solid var(--border-color);
    white-space: nowrap;
    text-align: center;
    vertical-align: middle;
}

.data-table td {
    padding: 11px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-main);
    vertical-align: middle;
    white-space: nowrap;
    text-align: center;
}

/* Hujayra ichidagi flex bloklar ham markazda tursin */
.data-table td > div,
.data-table th > div {
    justify-content: center;
}

/* Chapga tekislash kerak bo'lgan ustunlar uchun yordamchi klass */
.data-table th.cell-left,
.data-table td.cell-left {
    text-align: left;
}

.data-table td.cell-left > div {
    justify-content: flex-start;
}

/* Barcha qatorlarda bir xil 3px chap chegara: rangli qatorlar
   (chiquvchi / transfer / javobsiz) matnni 3px surib yubormasligi uchun */
.data-table tbody tr {
    transition: background 0.15s ease, filter 0.15s ease;
    border-left: 3px solid transparent;
}

.data-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.04);
    filter: brightness(1.15);
}

/* Badges */
.badge {
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
}

.badge-success { background: rgba(16, 185, 129, 0.15); color: #34d399; }
.badge-danger { background: rgba(239, 68, 68, 0.15); color: #f87171; }
.badge-info { background: rgba(6, 182, 212, 0.15); color: #38bdf8; }
.badge-warning { background: rgba(245, 158, 11, 0.15); color: #fbbf24; }
.badge-purple { background: rgba(168, 85, 247, 0.18); border: 1px solid rgba(168, 85, 247, 0.4); color: #c084fc; }
.badge-indigo { background: rgba(99, 102, 241, 0.2); border: 1px solid rgba(99, 102, 241, 0.45); color: #818cf8; }
.badge-cyan { background: rgba(14, 165, 233, 0.18); border: 1px solid rgba(14, 165, 233, 0.45); color: #38bdf8; }

.badge-dir-icon {
    display: inline-block;
    width: 13px;
    height: 13px;
    background-color: currentColor;
    -webkit-mask-size: contain;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
    vertical-align: -1.5px;
    flex-shrink: 0;
    margin-right: 2px;
}

.badge-dir-icon.inbound {
    -webkit-mask-image: url('/img/icon-kiruvchi.png');
    mask-image: url('/img/icon-kiruvchi.png');
}

.badge-dir-icon.outbound {
    -webkit-mask-image: url('/img/icon-chiquvchi.png');
    mask-image: url('/img/icon-chiquvchi.png');
}

tr.row-transfer {
    background: rgba(14, 165, 233, 0.08) !important;
    border-left: 3px solid #0ea5e9 !important;
}

/* Phone Cell Alignment Component */
.phone-cell {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: 0.3px;
    transition: all 0.2s ease;
}

.phone-cell.is-expanded {
    display: inline-flex;
    align-items: flex-start;
    white-space: normal !important;
}

.phone-cell .phone-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 6px;
    background: rgba(56, 189, 248, 0.15);
    color: #38bdf8;
    font-size: 12px;
    flex-shrink: 0;
}

.phone-cell.is-expanded .phone-icon {
    margin-top: 2px;
}

.phone-cell.outbound .phone-icon {
    background: rgba(168, 85, 247, 0.2);
    color: #c084fc;
}

/* Caller Cell Content (Truncate & Expandable) */
.caller-cell-content {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    max-width: 220px;
    vertical-align: middle;
    text-align: left;
}

.caller-cell-content .caller-text {
    display: inline-block;
    color: #f8fafc;
    cursor: pointer;
    transition: color 0.15s ease;
}

.caller-cell-content .caller-text:hover {
    color: #38bdf8;
    text-decoration: underline;
}

.caller-expand-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1px 7px;
    height: 19px;
    min-width: 24px;
    border-radius: 5px;
    font-size: 11px;
    font-weight: 800;
    line-height: 1;
    background: rgba(56, 189, 248, 0.18);
    border: 1px solid rgba(56, 189, 248, 0.45);
    color: #38bdf8;
    cursor: pointer;
    vertical-align: middle;
    transition: all 0.18s ease;
    user-select: none;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
    flex-shrink: 0;
    letter-spacing: 1px;
}

.caller-expand-btn:hover {
    background: rgba(56, 189, 248, 0.35);
    border-color: #38bdf8;
    color: #ffffff;
    transform: scale(1.08);
    box-shadow: 0 2px 8px rgba(56, 189, 248, 0.4);
}

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

/* Yoyilgan (Expanded) holat - balandlikka yoyiladi (height) */
.caller-cell-content.is-expanded {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    white-space: normal !important;
    word-break: break-word;
    overflow-wrap: break-word;
    max-width: 260px;
    line-height: 1.4;
    padding: 3px 0;
    animation: fadeInExpand 0.2s ease;
}

.caller-cell-content.is-expanded .caller-text {
    white-space: normal !important;
    word-break: break-word;
    overflow-wrap: break-word;
    font-size: 12px;
    font-weight: 600;
    color: #ffffff;
    cursor: pointer;
    text-align: left;
}

.caller-cell-content.is-expanded .caller-expand-btn {
    margin-top: 6px;
    background: rgba(148, 163, 184, 0.16);
    border-color: rgba(148, 163, 184, 0.35);
    color: #cbd5e1;
    font-size: 10px;
    height: 18px;
    padding: 0 7px;
    letter-spacing: 0.3px;
}

.caller-cell-content.is-expanded .caller-expand-btn:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.45);
    color: #fca5a5;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3);
}

.data-table td.cell-expanded,
.data-table td:has(.phone-cell.is-expanded) {
    white-space: normal !important;
}

@keyframes fadeInExpand {
    from {
        opacity: 0.7;
        transform: translateY(-2px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Action Buttons */
.btn-action {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--border-color);
    color: #fff;
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s;
}

.btn-action:hover {
    background: var(--primary);
    border-color: var(--primary);
    box-shadow: 0 2px 8px var(--primary-glow);
}

.btn-action.btn-audio-playing {
    background: rgba(239, 68, 68, 0.2) !important;
    border-color: rgba(239, 68, 68, 0.6) !important;
    color: #f87171 !important;
    box-shadow: 0 0 12px rgba(239, 68, 68, 0.35) !important;
}

.btn-action.btn-audio-playing:hover {
    background: rgba(239, 68, 68, 0.35) !important;
    border-color: #ef4444 !important;
    color: #fff !important;
    box-shadow: 0 0 16px rgba(239, 68, 68, 0.5) !important;
}

.btn-action:disabled {
    opacity: 0.6;
    cursor: wait;
}

.btn-danger {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.4);
    color: #fca5a5;
}

.btn-danger:hover {
    background: var(--danger);
    color: #fff;
}

/* ==========================================================================
   Modern Numeric Pagination
   ========================================================================== */
.pagination-controls-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 16px;
    padding: 0 4px;
    flex-wrap: wrap;
    gap: 12px;
}

.pagination-bar {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.pagination-numbers-container {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    user-select: none;
}

.page-btn {
    min-width: 32px;
    height: 32px;
    padding: 0 7px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-muted);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    outline: none;
    box-sizing: border-box;
}

.page-btn:hover:not(:disabled):not(.active) {
    background: rgba(56, 189, 248, 0.12);
    border-color: rgba(56, 189, 248, 0.4);
    color: #38bdf8;
    transform: translateY(-1px);
}

.page-btn.active {
    background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
    border: 1px solid rgba(56, 189, 248, 0.6);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(2, 132, 199, 0.45);
    cursor: default;
    font-weight: 700;
}

.page-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

.page-ellipsis {
    min-width: 24px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--text-dim);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1.5px;
    user-select: none;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.2s;
    padding: 0 2px;
}

.page-ellipsis:hover {
    color: #38bdf8;
    background: rgba(56, 189, 248, 0.1);
}

.page-nav-btn {
    height: 32px;
    padding: 0 12px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--text-main);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    outline: none;
    box-sizing: border-box;
}

.page-nav-btn svg {
    flex-shrink: 0;
}

.page-nav-btn:hover:not(:disabled) {
    background: rgba(56, 189, 248, 0.15);
    border-color: rgba(56, 189, 248, 0.4);
    color: #38bdf8;
}

.page-nav-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
    color: var(--text-dim);
    background: rgba(255, 255, 255, 0.02);
    border-color: rgba(255, 255, 255, 0.05);
}

/* ==========================================================================
   Right Sticky Sidebar (Live Channels & Waveform Audio Player)
   ========================================================================== */

.right-sidebar {
    position: fixed;
    top: 0;
    right: 0;
    width: var(--sidebar-width);
    height: 100vh;
    background: var(--bg-sidebar);
    border-left: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    z-index: 350;
    box-shadow: -8px 0 24px rgba(0, 0, 0, 0.4);
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.35s ease;
}

/* Sidebar ochib-yopiladigan rejim (Collapsible Sidebar) */
.main-area {
    padding-right: 0 !important;
    transition: padding-right 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Katta keng ekranlarda (1536px+) sidebar ochiq bo'lsa padding beriladi,
   lekin noutbuk va 1080p ekranlarda umuman siqib tiqiltirmasligi uchun 0 qoladi va overlay panel bo'ladi */
@media (min-width: 1536px) {
    body:not(.sidebar-collapsed) .main-area {
        padding-right: var(--sidebar-width) !important;
    }
}
@media (max-width: 1535px) {
    body:not(.sidebar-collapsed) .main-area {
        padding-right: 0 !important;
    }
}

body.sidebar-collapsed .main-area {
    padding-right: 0 !important;
}

body.sidebar-collapsed .right-sidebar {
    transform: translateX(100%) !important;
    box-shadow: none !important;
    pointer-events: none;
}

body:not(.sidebar-collapsed) .right-sidebar {
    transform: translateX(0) !important;
    box-shadow: -12px 0 36px rgba(0, 0, 0, 0.65) !important;
}

/* Sidebar ichidagi yopish tugmasi */
.sidebar-collapse-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #94a3b8;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    padding: 0;
}
.sidebar-collapse-btn:hover {
    background: rgba(56, 189, 248, 0.15);
    border-color: rgba(56, 189, 248, 0.4);
    color: #38bdf8;
    transform: translateX(2px);
}

/* Sidebar yopilganda o'ng ekranda paydo bo'ladigan suzuvchi (floating) ochish tugmasi */
.sidebar-floating-expand-btn {
    position: fixed;
    top: 50%;
    right: 0;
    transform: translateY(-50%) translateX(100%);
    z-index: 340;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 7px;
    padding: 14px 8px;
    background: rgba(15, 23, 42, 0.94);
    border: 1px solid rgba(56, 189, 248, 0.45);
    border-right: none;
    border-radius: 12px 0 0 12px;
    color: #38bdf8;
    cursor: pointer;
    box-shadow: -6px 0 24px rgba(0, 0, 0, 0.55), 0 0 16px rgba(56, 189, 248, 0.22);
    backdrop-filter: blur(14px);
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), background 0.2s ease, opacity 0.3s ease;
    opacity: 0;
    pointer-events: none;
}
.sidebar-floating-expand-btn .floating-text {
    writing-mode: vertical-rl;
    text-orientation: mixed;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: #94a3b8;
}
.sidebar-floating-expand-btn:hover {
    background: rgba(30, 41, 59, 0.98);
    border-color: #38bdf8;
    color: #38bdf8;
}
.sidebar-floating-expand-btn:hover .floating-text {
    color: #38bdf8;
}
body.sidebar-collapsed .sidebar-floating-expand-btn {
    transform: translateY(-50%) translateX(0);
    opacity: 1;
    pointer-events: auto;
}

/* Top Navbar'dagi Jonli Monitor tugmasi */
.navbar-sidebar-toggle-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 12px;
    border-radius: 9px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #cbd5e1;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.navbar-sidebar-toggle-btn:hover {
    background: rgba(56, 189, 248, 0.15);
    border-color: rgba(56, 189, 248, 0.4);
    color: #38bdf8;
}
body:not(.sidebar-collapsed) .navbar-sidebar-toggle-btn {
    background: rgba(56, 189, 248, 0.18);
    border-color: rgba(56, 189, 248, 0.55);
    color: #38bdf8;
    box-shadow: 0 0 12px rgba(56, 189, 248, 0.25);
}
body.sidebar-collapsed .navbar-sidebar-toggle-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #94a3b8;
    box-shadow: none;
}
.live-dot-pulse {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #10b981;
    box-shadow: 0 0 8px #10b981;
    display: inline-block;
}

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

.sidebar-header h2 {
    font-size: 15px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
}

.sidebar-body {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Yagona silliq va ixcham scrollbar */
.sidebar-body::-webkit-scrollbar {
    width: 5px;
}
.sidebar-body::-webkit-scrollbar-track {
    background: transparent;
}
.sidebar-body::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 4px;
}
.sidebar-body::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Callback Sticky Filter Header (Scroll qilganda joyida qoladi, kartochkalar tagidan o'tadi) */
.callback-sticky-header {
    position: sticky;
    top: 0;
    z-index: 25;
    background: var(--bg-sidebar);
    margin: 0 -14px;
    padding: 8px 14px 8px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.45);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

/* Compact Live Channel Cards & Queue */
.queue-panel {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.12), rgba(15, 23, 42, 0.7));
    border: 1px solid rgba(99, 102, 241, 0.4);
    border-top: 2px solid #818cf8;
    border-radius: var(--radius-md);
    padding: 12px;
    margin-bottom: 12px;
    box-shadow: 0 4px 16px rgba(99, 102, 241, 0.08);
}

.queue-panel-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    font-weight: 700;
    color: #818cf8;
    margin-bottom: 8px;
}

.queue-items-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
    max-height: 120px;
    overflow-y: auto;
}

.queue-caller-pill {
    background: rgba(99, 102, 241, 0.14);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: var(--radius-sm);
    padding: 6px 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
    color: #e0e7ff;
}

.compact-channel-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 8px 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    transition: all 0.15s;
}

.compact-channel-card:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: var(--border-glow);
}

.compact-channel-card.talking {
    border-left: 3px solid var(--success);
    background: rgba(16, 185, 129, 0.04);
}

.compact-channel-card.ringing {
    border-left: 3px solid var(--warning);
    background: rgba(245, 158, 11, 0.04);
}

.chan-left {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.chan-number {
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    font-family: monospace;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.chan-op {
    font-size: 11px;
    color: var(--secondary);
    display: flex;
    align-items: center;
    gap: 4px;
}

.chan-right {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.btn-mini-hangup {
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid rgba(239, 68, 68, 0.4);
    color: #fca5a5;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.15s;
}

.btn-mini-hangup:hover {
    background: var(--danger);
    color: #fff;
}

/* ==========================================================================
   Active Conversations Swipe-Right & Swipe-In Animations
   ========================================================================== */
@keyframes swipeOutRight {
    0% {
        transform: translateX(0);
        opacity: 1;
        max-height: 80px;
        margin-bottom: 0px;
        box-shadow: 0 0 0 rgba(0, 0, 0, 0);
    }
    30% {
        transform: translateX(35px);
        opacity: 0.95;
        border-color: rgba(239, 68, 68, 0.45);
        background: rgba(239, 68, 68, 0.1);
        box-shadow: 0 4px 14px rgba(239, 68, 68, 0.25);
    }
    70% {
        transform: translateX(115%);
        opacity: 0.2;
        max-height: 80px;
        margin-bottom: 0px;
        padding-top: 8px;
        padding-bottom: 8px;
    }
    100% {
        transform: translateX(140%);
        opacity: 0;
        max-height: 0;
        padding-top: 0;
        padding-bottom: 0;
        margin-top: 0;
        margin-bottom: -6px;
        border-width: 0;
        border: none;
    }
}

.compact-channel-card.swiping-out {
    animation: swipeOutRight 1.2s cubic-bezier(0.25, 1, 0.5, 1) forwards !important;
    pointer-events: none !important;
    overflow: hidden !important;
    will-change: transform, opacity, max-height;
}

@keyframes swipeInLeft {
    0% {
        transform: translateX(-25px);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

.compact-channel-card.swiping-in {
    animation: swipeInLeft 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Dedicated Audio Player Box */
.audio-player-box {
    background: linear-gradient(180deg, rgba(30, 41, 59, 0.9), rgba(15, 23, 42, 0.95));
    border: 1px solid var(--primary-glow);
    border-radius: var(--radius-md);
    padding: 12px 14px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

.player-title {
    font-size: 12px;
    font-weight: 600;
    color: var(--secondary);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.player-file-info {
    font-size: 11px;
    color: var(--text-muted);
    margin-bottom: 8px;
    word-break: break-all;
    background: rgba(0, 0, 0, 0.3);
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    max-height: 40px;
    overflow: hidden;
}

.player-timeline-wrapper {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 8px;
}

.progress-bar-container {
    width: 100%;
    height: 5px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    cursor: pointer;
    position: relative;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    border-radius: 999px;
    width: 0%;
    transition: width 0.1s linear;
}

.player-time-display {
    display: flex;
    justify-content: space-between;
    font-size: 10px;
    color: var(--text-dim);
    font-variant-numeric: tabular-nums;
}

.player-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
}

.btn-play {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--primary);
    border: none;
    color: #fff;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 2px 8px var(--primary-glow);
    transition: transform 0.15s;
}

.btn-play:hover {
    transform: scale(1.06);
}

.rate-select {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    font-size: 11px;
    outline: none;
    cursor: pointer;
}

/* Operator Grid */
.operator-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(285px, 1fr));
    gap: 16px;
    /* Ma'lumot fetch bo'lguncha ham joy band qilinadi (pastdagi skeleton kartalar orqali) —
       aks holda karta yo'q paytda balandligi 0 bo'lib, keyin ma'lumot kelganda butun sahifa
       pastga "sakraydi" (Cumulative Layout Shift). */
    min-height: 210px;
}

/* Operator Guruhi Switch / Tabs (Asosiy / 2-darajali / Barchasi) */
.operator-group-tabs {
    display: inline-flex;
    align-items: center;
    background: rgba(15, 23, 42, 0.75);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 3px;
    gap: 4px;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.4);
}

.op-group-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 5px 12px;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
    background: transparent;
    border: 1px solid transparent;
    border-radius: 7px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    user-select: none;
}

.op-group-btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.06);
}

.op-group-btn.active {
    color: #fff;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.35), rgba(59, 130, 246, 0.28));
    border-color: rgba(99, 102, 241, 0.55);
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.25);
}

.op-group-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 6px currentColor;
}

.op-group-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 9px;
    font-size: 10.5px;
    font-weight: 700;
    background: rgba(255, 255, 255, 0.08);
    color: #cbd5e1;
}

.op-group-btn.active .op-group-count {
    background: rgba(99, 102, 241, 0.45);
    color: #fff;
}

/* Operatorlar hali yuklanmagan paytdagi skeleton (joy tutuvchi) karta */
.operator-card.skeleton {
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-height: 210px;
    pointer-events: none;
}

.operator-card.skeleton .skeleton-line {
    border-radius: 6px;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.05) 25%, rgba(255, 255, 255, 0.1) 37%, rgba(255, 255, 255, 0.05) 63%);
    background-size: 400% 100%;
    animation: skeletonShimmer 1.6s ease-in-out infinite;
}

@keyframes skeletonShimmer {
    0%   { background-position: 100% 50%; }
    100% { background-position: 0 50%; }
}

.operator-card {
    position: relative;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 18px;
    user-select: text;
    overflow: visible;
    z-index: 1;
}

.operator-card:hover {
    border-color: var(--border-glow);
    z-index: 20;
}

.operator-card:has(.star-rating-box:hover) {
    border-color: var(--border-glow);
    z-index: 50 !important;
    transform: none !important;
}

.operator-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
}

.operator-avatar {
    width: 44px;
    height: 44px;
    min-width: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    letter-spacing: -0.3px;
    color: #fff;
    flex-shrink: 0;
}

.op-stat-row {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    margin-bottom: 6px;
    color: var(--text-muted);
}

.op-stat-val {
    font-weight: 600;
    color: var(--text-main);
}

/* Gamified Operator MVP & Star Ranking */
.mvp-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 999px;
    letter-spacing: 0.2px;
}

.mvp-badge.diamond {
    background: linear-gradient(135deg, rgba(56, 189, 248, 0.25), rgba(14, 165, 233, 0.15));
    border: 1px solid rgba(56, 189, 248, 0.6);
    color: #7dd3fc;
    box-shadow: 0 0 10px rgba(56, 189, 248, 0.25);
}

.mvp-badge.gold {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.25), rgba(234, 179, 8, 0.15));
    border: 1px solid rgba(245, 158, 11, 0.6);
    color: #fcd34d;
    box-shadow: 0 0 10px rgba(245, 158, 11, 0.2);
}

.mvp-badge.silver {
    background: linear-gradient(135deg, rgba(148, 163, 184, 0.25), rgba(203, 213, 225, 0.15));
    border: 1px solid rgba(148, 163, 184, 0.5);
    color: #e2e8f0;
}

.mvp-badge.bronze {
    background: linear-gradient(135deg, rgba(217, 119, 6, 0.2), rgba(180, 83, 9, 0.15));
    border: 1px solid rgba(217, 119, 6, 0.4);
    color: #fdba74;
}

.mvp-badge.npc {
    background: rgba(100, 116, 139, 0.18);
    border: 1px solid rgba(148, 163, 184, 0.35);
    color: #94a3b8;
}

.operator-meta-sub {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 2px 4px;
    margin-top: 2px;
}

.star-rating-box {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fbbf24;
    cursor: help;
    padding: 2px 4px;
    border-radius: 6px;
    transition: background 0.15s ease;
    white-space: nowrap;
    margin-left: auto;
    user-select: none;
}

.star-rating-box:hover {
    background: rgba(251, 191, 36, 0.15);
    z-index: 25;
}

/* Yulduzlar klasteri (1, 2, 3, 4, 5 ta yulduz) */
.stars-cluster {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.stars-cluster .star-item {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.7));
}

/* 1 ta yulduz */
.stars-cluster.stars-count-1 .star-single {
    font-size: 13px;
    filter: drop-shadow(0 0 3px rgba(251, 191, 36, 0.6));
}

/* 2 ta yulduz: Yonma-yon */
.stars-cluster.stars-count-2 .star-row {
    display: flex;
    align-items: center;
    gap: 3px;
    font-size: 11.5px;
}

/* 3 ta yulduz:
     x
   x   x
*/
.stars-cluster.stars-count-3 {
    gap: 1px;
}
.stars-cluster.stars-count-3 .star-row-top {
    display: flex;
    justify-content: center;
    font-size: 11.5px;
    margin-bottom: -1px;
}
.stars-cluster.stars-count-3 .star-row-top .star-peak {
    transform: scale(1.1);
    filter: drop-shadow(0 0 4px rgba(251, 191, 36, 0.8));
}
.stars-cluster.stars-count-3 .star-row-bottom {
    display: flex;
    justify-content: center;
    gap: 7px;
    font-size: 10.5px;
}

/* 4 ta yulduz: Romb (Diamond) shakli
      x
   x    x
      x
*/
.stars-cluster.stars-count-4 {
    gap: 0;
    line-height: 0.85;
}
.stars-cluster.stars-count-4 .star-row-top {
    display: flex;
    justify-content: center;
    font-size: 11px;
    margin-bottom: -1.5px;
}
.stars-cluster.stars-count-4 .star-row-mid {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 9px;
    font-size: 11px;
}
.stars-cluster.stars-count-4 .star-row-bottom {
    display: flex;
    justify-content: center;
    font-size: 11px;
    margin-top: -1.5px;
}
.stars-cluster.stars-count-4 .star-item {
    font-size: 11px;
    filter: drop-shadow(0 0 3.5px rgba(251, 191, 36, 0.85));
}

/* 5 ta yulduz: Kamalaksimon (Arch)
      x (Diamond star)
   xx   xx
*/
.stars-cluster.stars-count-5 {
    gap: 1px;
}
.stars-cluster.stars-count-5 .star-row-top {
    display: flex;
    justify-content: center;
    margin-bottom: 0px;
}
.stars-cluster.stars-count-5 .star-row-top .star-peak {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}
.stars-cluster.stars-count-5 .star-row-top .star-peak .diamond-star-svg {
    width: 16px;
    height: 16px;
    display: block;
    filter: drop-shadow(0 0 5px rgba(56, 189, 248, 0.95)) drop-shadow(0 0 9px rgba(14, 165, 233, 0.6));
    animation: diamondStarSparkle 3s ease-in-out infinite alternate;
}
@keyframes diamondStarSparkle {
    0% {
        filter: drop-shadow(0 0 3px rgba(56, 189, 248, 0.9)) drop-shadow(0 0 6px rgba(14, 165, 233, 0.5));
        transform: scale(1);
    }
    100% {
        filter: drop-shadow(0 0 6px rgba(56, 189, 248, 1)) drop-shadow(0 0 10px rgba(56, 189, 248, 0.8));
        transform: scale(1.08);
    }
}
.stars-cluster.stars-count-5 .star-row-bottom {
    display: flex;
    align-items: center;
    gap: 7px;
    margin-top: 1px;
}
.stars-cluster.stars-count-5 .star-wing {
    display: flex;
    align-items: center;
    gap: 2px;
    font-size: 12px;
}
.stars-cluster.stars-count-5 .star-wing .star-item {
    font-size: 12px;
    filter: drop-shadow(0 0 3.5px rgba(251, 191, 36, 0.9));
}
.stars-cluster.stars-count-5 .wing-left .star-outer {
    transform: translateY(2px) rotate(-12deg);
}
.stars-cluster.stars-count-5 .wing-left .star-inner {
    transform: translateY(0px) rotate(-4deg);
}
.stars-cluster.stars-count-5 .wing-right .star-inner {
    transform: translateY(0px) rotate(4deg);
}
.stars-cluster.stars-count-5 .wing-right .star-outer {
    transform: translateY(2px) rotate(12deg);
}

.star-rating-tooltip {
    visibility: hidden;
    opacity: 0;
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 275px;
    background: #0f172a;
    border: 1px solid rgba(251, 191, 36, 0.45);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.85), 0 0 18px rgba(251, 191, 36, 0.2);
    border-radius: 10px;
    padding: 12px;
    color: #f1f5f9;
    font-size: 11px;
    line-height: 1.4;
    z-index: 9999;
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
    transform: translateY(-6px);
    pointer-events: none;
    text-align: left;
    backdrop-filter: blur(12px);
}

.star-rating-box:hover .star-rating-tooltip {
    visibility: visible;
    opacity: 1;
    transform: translateY(0);
}

.star-tooltip-header {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 700;
    color: #fbbf24;
    margin-bottom: 6px;
}

.star-tooltip-current {
    font-size: 11px;
    color: #e2e8f0;
    margin-bottom: 8px;
}

.star-progress-note {
    margin-top: 3px;
    font-size: 10.5px;
    color: #38bdf8;
    font-weight: 600;
}

.star-tooltip-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
    margin: 8px 0;
}

.star-tooltip-levels {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.star-level-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 4px 6px;
    border-radius: 6px;
    font-size: 10.5px;
    color: #94a3b8;
    transition: background 0.15s ease;
}

.star-level-row.current-level {
    background: rgba(251, 191, 36, 0.18);
    border: 1px solid rgba(251, 191, 36, 0.45);
    color: #fbbf24;
    font-weight: 700;
}

.star-level-row .level-stars {
    min-width: 65px;
    color: #fbbf24;
    font-size: 10px;
    letter-spacing: 0.5px;
}

.star-level-row .level-range {
    font-family: monospace;
    font-weight: 600;
    color: #e2e8f0;
}

.star-level-row .level-desc {
    font-size: 10px;
}

/* ==========================================================================
   1-o'rin: MVP Diamond Operator Card & Laurel Frame (Ice-Cyan Edition)
   ========================================================================== */
.operator-card.mvp-diamond {
    position: relative;
    background: radial-gradient(ellipse at 50% -10%, rgba(56, 189, 248, 0.22) 0%, rgba(15, 23, 42, 0.98) 80%) !important;
    border: 1.5px solid rgba(56, 189, 248, 0.85) !important;
    box-shadow: 0 6px 28px rgba(14, 165, 233, 0.28), 0 0 16px rgba(56, 189, 248, 0.2), inset 0 0 22px rgba(56, 189, 248, 0.1) !important;
    animation: mvpDiamondGlowPulse 4s ease-in-out infinite;
}

/* Yuqori nozik olmos/cyan nur chizig'i */
.operator-card.mvp-diamond::before {
    content: '';
    position: absolute;
    top: 0;
    left: 12%;
    right: 12%;
    height: 2px;
    background: linear-gradient(90deg, transparent, #38bdf8, #f0f9ff, #38bdf8, transparent);
    box-shadow: 0 0 14px #38bdf8;
    border-radius: 2px;
    pointer-events: none;
    z-index: 2;
}

.operator-card.mvp-diamond:hover {
    border-color: #38bdf8 !important;
    box-shadow: 0 10px 38px rgba(14, 165, 233, 0.45), 0 0 26px rgba(56, 189, 248, 0.35), inset 0 0 30px rgba(56, 189, 248, 0.16) !important;
    transform: none !important;
}

@keyframes mvpDiamondGlowPulse {
    0%, 100% {
        box-shadow: 0 6px 28px rgba(14, 165, 233, 0.24), 0 0 16px rgba(56, 189, 248, 0.18), inset 0 0 22px rgba(56, 189, 248, 0.08);
        border-color: rgba(56, 189, 248, 0.8);
    }
    50% {
        box-shadow: 0 8px 38px rgba(14, 165, 233, 0.4), 0 0 26px rgba(56, 189, 248, 0.32), inset 0 0 32px rgba(56, 189, 248, 0.16);
        border-color: rgba(186, 230, 253, 0.98);
    }
}

/* MVP Diamond Avatar - Cyan Ring & Floating Crown */
.operator-card.mvp-diamond .operator-avatar {
    background: linear-gradient(135deg, #0284c7, #0369a1) !important;
    box-shadow: 0 0 0 2.5px rgba(56, 189, 248, 0.95), 0 0 18px rgba(14, 165, 233, 0.65) !important;
    position: relative;
}

.operator-card.mvp-diamond .operator-avatar::after {
    content: '';
    position: absolute;
    top: -15px;
    right: -11px;
    width: 29px;
    height: 22px;
    background: url('/img/crown-diamond.png') center / contain no-repeat;
    filter: drop-shadow(0 2px 7px rgba(56, 189, 248, 0.85)) drop-shadow(0 1px 3px rgba(0, 0, 0, 0.9));
    animation: mvpCrownBob 2.8s ease-in-out infinite;
    pointer-events: none;
    z-index: 5;
}

/* ==========================================================================
   2-o'rin: MVP Gold Operator Card & Laurel Frame (Classic Gold Edition)
   ========================================================================== */
.operator-card.mvp-gold {
    position: relative;
    background: radial-gradient(ellipse at 50% -10%, rgba(245, 158, 11, 0.18) 0%, rgba(17, 24, 39, 0.96) 80%) !important;
    border: 1.5px solid rgba(245, 158, 11, 0.82) !important;
    box-shadow: 0 6px 28px rgba(245, 158, 11, 0.24), 0 0 16px rgba(245, 158, 11, 0.16), inset 0 0 22px rgba(245, 158, 11, 0.08) !important;
    animation: mvpCardGlowPulse 4s ease-in-out infinite;
}

/* Yuqori nozik oltin nur chizig'i */
.operator-card.mvp-gold::before {
    content: '';
    position: absolute;
    top: 0;
    left: 12%;
    right: 12%;
    height: 2px;
    background: linear-gradient(90deg, transparent, #fbbf24, #fffbeb, #fbbf24, transparent);
    box-shadow: 0 0 12px #fbbf24;
    border-radius: 2px;
    pointer-events: none;
    z-index: 2;
}

.operator-card.mvp-gold:hover {
    border-color: #fbbf24 !important;
    box-shadow: 0 10px 36px rgba(245, 158, 11, 0.4), 0 0 24px rgba(245, 158, 11, 0.3), inset 0 0 28px rgba(245, 158, 11, 0.14) !important;
    transform: none !important;
}

@keyframes mvpCardGlowPulse {
    0%, 100% {
        box-shadow: 0 6px 28px rgba(245, 158, 11, 0.22), 0 0 16px rgba(245, 158, 11, 0.16), inset 0 0 22px rgba(245, 158, 11, 0.08);
        border-color: rgba(245, 158, 11, 0.78);
    }
    50% {
        box-shadow: 0 8px 36px rgba(245, 158, 11, 0.36), 0 0 24px rgba(245, 158, 11, 0.28), inset 0 0 30px rgba(245, 158, 11, 0.14);
        border-color: rgba(251, 191, 36, 0.98);
    }
}

/* MVP Avatar - Gold Ring & Floating Crown */
.operator-card.mvp-gold .operator-avatar {
    background: linear-gradient(135deg, #f59e0b, #b45309) !important;
    box-shadow: 0 0 0 2.5px rgba(251, 191, 36, 0.9), 0 0 16px rgba(245, 158, 11, 0.55) !important;
    position: relative;
}

.operator-card.mvp-gold .operator-avatar::after {
    content: '';
    position: absolute;
    top: -15px;
    right: -11px;
    width: 29px;
    height: 22px;
    background: url('/img/crown-gold.png') center / contain no-repeat;
    filter: drop-shadow(0 2px 6px rgba(245, 158, 11, 0.7)) drop-shadow(0 1px 3px rgba(0, 0, 0, 0.9));
    animation: mvpCrownBob 2.8s ease-in-out infinite;
    pointer-events: none;
    z-index: 5;
}

@keyframes mvpCrownBob {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-2.5px) rotate(6deg); }
}

/* 2-o'rin: Silver Card & Avatar */
.operator-card.mvp-silver {
    position: relative;
    background: radial-gradient(ellipse at 50% -10%, rgba(226, 232, 240, 0.16) 0%, rgba(17, 24, 39, 0.96) 80%) !important;
    border: 1.5px solid rgba(203, 213, 225, 0.75) !important;
    box-shadow: 0 6px 26px rgba(148, 163, 184, 0.22), 0 0 14px rgba(203, 213, 225, 0.15), inset 0 0 20px rgba(226, 232, 240, 0.06) !important;
    animation: mvpSilverGlowPulse 4s ease-in-out infinite 0.5s;
}

.operator-card.mvp-silver::before {
    content: '';
    position: absolute;
    top: 0;
    left: 12%;
    right: 12%;
    height: 2px;
    background: linear-gradient(90deg, transparent, #cbd5e1, #ffffff, #cbd5e1, transparent);
    box-shadow: 0 0 12px #e2e8f0;
    border-radius: 2px;
    pointer-events: none;
    z-index: 2;
}

.operator-card.mvp-silver:hover {
    border-color: #f1f5f9 !important;
    box-shadow: 0 10px 34px rgba(203, 213, 225, 0.38), 0 0 22px rgba(226, 232, 240, 0.28), inset 0 0 26px rgba(226, 232, 240, 0.12) !important;
    transform: none !important;
}

@keyframes mvpSilverGlowPulse {
    0%, 100% {
        box-shadow: 0 6px 26px rgba(148, 163, 184, 0.2), 0 0 14px rgba(203, 213, 225, 0.14), inset 0 0 20px rgba(226, 232, 240, 0.06);
        border-color: rgba(203, 213, 225, 0.7);
    }
    50% {
        box-shadow: 0 8px 34px rgba(203, 213, 225, 0.34), 0 0 22px rgba(226, 232, 240, 0.26), inset 0 0 28px rgba(226, 232, 240, 0.12);
        border-color: rgba(248, 250, 252, 0.95);
    }
}

.operator-card.mvp-silver .operator-avatar {
    background: linear-gradient(135deg, #94a3b8, #475569) !important;
    box-shadow: 0 0 0 2.5px rgba(241, 245, 249, 0.95), 0 0 16px rgba(203, 213, 225, 0.6) !important;
    position: relative;
}

.operator-card.mvp-silver .operator-avatar::after {
    content: '';
    position: absolute;
    top: -14px;
    right: -10px;
    width: 25px;
    height: 23px;
    background: url('/img/crown-silver.png') center / contain no-repeat;
    filter: drop-shadow(0 2px 5px rgba(226, 232, 240, 0.7)) drop-shadow(0 1px 3px rgba(0, 0, 0, 0.9));
    animation: mvpCrownBob 2.8s ease-in-out infinite 0.4s;
    pointer-events: none;
    z-index: 5;
}

/* 3-o'rin: Bronze Card & Avatar */
.operator-card.mvp-bronze {
    position: relative;
    background: radial-gradient(ellipse at 50% -10%, rgba(217, 119, 6, 0.16) 0%, rgba(17, 24, 39, 0.96) 80%) !important;
    border: 1.5px solid rgba(217, 119, 6, 0.75) !important;
    box-shadow: 0 6px 26px rgba(217, 119, 6, 0.22), 0 0 14px rgba(180, 83, 9, 0.15), inset 0 0 20px rgba(217, 119, 6, 0.06) !important;
    animation: mvpBronzeGlowPulse 4s ease-in-out infinite 1s;
}

.operator-card.mvp-bronze::before {
    content: '';
    position: absolute;
    top: 0;
    left: 12%;
    right: 12%;
    height: 2px;
    background: linear-gradient(90deg, transparent, #d97706, #fed7aa, #d97706, transparent);
    box-shadow: 0 0 12px #d97706;
    border-radius: 2px;
    pointer-events: none;
    z-index: 2;
}

.operator-card.mvp-bronze:hover {
    border-color: #f59e0b !important;
    box-shadow: 0 10px 34px rgba(217, 119, 6, 0.38), 0 0 22px rgba(245, 158, 11, 0.28), inset 0 0 26px rgba(217, 119, 6, 0.12) !important;
    transform: none !important;
}

@keyframes mvpBronzeGlowPulse {
    0%, 100% {
        box-shadow: 0 6px 26px rgba(217, 119, 6, 0.2), 0 0 14px rgba(180, 83, 9, 0.14), inset 0 0 20px rgba(217, 119, 6, 0.06);
        border-color: rgba(217, 119, 6, 0.7);
    }
    50% {
        box-shadow: 0 8px 34px rgba(217, 119, 6, 0.34), 0 0 22px rgba(245, 158, 11, 0.26), inset 0 0 28px rgba(217, 119, 6, 0.12);
        border-color: rgba(251, 191, 36, 0.95);
    }
}

.operator-card.mvp-bronze .operator-avatar {
    background: linear-gradient(135deg, #d97706, #78350f) !important;
    box-shadow: 0 0 0 2.5px rgba(245, 158, 11, 0.9), 0 0 16px rgba(217, 119, 6, 0.55) !important;
    position: relative;
}

.operator-card.mvp-bronze .operator-avatar::after {
    content: '';
    position: absolute;
    top: -14px;
    right: -10px;
    width: 25px;
    height: 23px;
    background: url('/img/crown-bronze.png') center / contain no-repeat;
    filter: drop-shadow(0 2px 5px rgba(217, 119, 6, 0.7)) drop-shadow(0 1px 3px rgba(0, 0, 0, 0.9));
    animation: mvpCrownBob 2.8s ease-in-out infinite 0.8s;
    pointer-events: none;
    z-index: 5;
}

/* MVP Laurel Wreath Badge (1-rasm: 3 yulduzli oltin lavr chambari) */
.mvp-wreath-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    vertical-align: middle;
    transition: transform 0.2s ease, filter 0.2s ease;
    filter: drop-shadow(0 2px 8px rgba(245, 158, 11, 0.7));
}

.mvp-wreath-badge:hover {
    transform: scale(1.15);
    filter: drop-shadow(0 4px 14px rgba(245, 158, 11, 0.98));
}

.mvp-wreath-badge.diamond-wreath {
    filter: drop-shadow(0 2px 8px rgba(56, 189, 248, 0.8));
}

.mvp-wreath-badge.diamond-wreath:hover {
    transform: scale(1.15);
    filter: drop-shadow(0 4px 14px rgba(56, 189, 248, 1));
}

.mvp-wreath-badge.gold-wreath {
    filter: drop-shadow(0 2px 8px rgba(245, 158, 11, 0.7));
}

.mvp-wreath-badge.gold-wreath:hover {
    transform: scale(1.15);
    filter: drop-shadow(0 4px 14px rgba(245, 158, 11, 0.98));
}

.mvp-wreath-badge.silver-wreath {
    filter: drop-shadow(0 2px 8px rgba(203, 213, 225, 0.7));
}

.mvp-wreath-badge.silver-wreath:hover {
    transform: scale(1.15);
    filter: drop-shadow(0 4px 14px rgba(241, 245, 249, 0.98));
}

.mvp-wreath-badge.bronze-wreath {
    filter: drop-shadow(0 2px 8px rgba(217, 119, 6, 0.7));
}

.mvp-wreath-badge.bronze-wreath:hover {
    transform: scale(1.15);
    filter: drop-shadow(0 4px 14px rgba(245, 158, 11, 0.98));
}

.mvp-wreath-svg {
    display: block;
}

/* ==========================================================================
   Operator Status Colors (Active: Green / Offline: Red)
   ========================================================================== */
.operator-card.status-active,
.operator-card.status-ready {
    background: linear-gradient(145deg, rgba(16, 185, 129, 0.13) 0%, rgba(15, 23, 42, 0.9) 100%);
    border: 1.5px solid rgba(16, 185, 129, 0.55);
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.12), inset 0 0 16px rgba(16, 185, 129, 0.04);
}

.operator-card.status-active:hover,
.operator-card.status-ready:hover {
    border-color: #10b981;
    box-shadow: 0 8px 26px rgba(16, 185, 129, 0.28), inset 0 0 20px rgba(16, 185, 129, 0.08);
}

.operator-card.status-talking {
    background: linear-gradient(145deg, rgba(14, 165, 233, 0.16) 0%, rgba(16, 185, 129, 0.08) 50%, rgba(15, 23, 42, 0.9) 100%);
    border: 1.5px solid rgba(56, 189, 248, 0.65);
    box-shadow: 0 4px 20px rgba(14, 165, 233, 0.16), inset 0 0 16px rgba(56, 189, 248, 0.05);
}

.operator-card.status-talking:hover {
    border-color: #38bdf8;
    box-shadow: 0 8px 26px rgba(14, 165, 233, 0.3);
}

.operator-card.status-offline {
    background: linear-gradient(145deg, rgba(239, 68, 68, 0.12) 0%, rgba(15, 23, 42, 0.92) 100%);
    border: 1.5px solid rgba(239, 68, 68, 0.5);
    box-shadow: 0 4px 18px rgba(239, 68, 68, 0.1), inset 0 0 16px rgba(239, 68, 68, 0.04);
}

.operator-card.status-offline:hover {
    border-color: #ef4444;
    box-shadow: 0 8px 26px rgba(239, 68, 68, 0.25);
}

/* Operator karta holat pillari (Kutmoqda / Suhbatda / Jiringlamoqda / Offline) —
   kartaning o'zidagi border/glow rangi bilan bir xil sxema ishlatiladi. */
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    white-space: nowrap;
}

.badge-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: currentColor;
    flex-shrink: 0;
}

.badge-dot.pulse {
    animation: pulse 1.6s ease-in-out infinite;
}

.badge-dot.pulse-ring {
    animation: pulse 0.7s ease-in-out infinite;
}

.status-badge.badge-ready {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.4);
    color: #34d399;
}

.status-badge.badge-talking {
    background: rgba(14, 165, 233, 0.15);
    border: 1px solid rgba(56, 189, 248, 0.4);
    color: #38bdf8;
}

.status-badge.badge-ringing {
    background: rgba(245, 158, 11, 0.15);
    border: 1px solid rgba(245, 158, 11, 0.4);
    color: #fbbf24;
}

.status-badge.badge-offline {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.4);
    color: #f87171;
}

.status-badge.badge-paused {
    background: rgba(245, 158, 11, 0.15);
    border: 1px solid rgba(245, 158, 11, 0.45);
    color: #fbbf24;
}

.operator-card.status-paused {
    border-color: rgba(245, 158, 11, 0.35);
}

.badge-dot.pulse-pause {
    background: #f59e0b;
    box-shadow: 0 0 8px #f59e0b;
}

/* Operator Card & Detail Modal Pause/Unpause Button */
.op-card-pause-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid rgba(245, 158, 11, 0.45);
    background: rgba(245, 158, 11, 0.12);
    color: #fbbf24;
    white-space: nowrap;
    user-select: none;
    line-height: 1.2;
}
.op-card-pause-btn:hover {
    background: rgba(245, 158, 11, 0.28);
    border-color: #f59e0b;
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(245, 158, 11, 0.35);
}
.op-card-pause-btn.is-paused {
    border-color: rgba(16, 185, 129, 0.55);
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
}
.op-card-pause-btn.is-paused:hover {
    background: rgba(16, 185, 129, 0.35);
    border-color: #10b981;
    box-shadow: 0 3px 10px rgba(16, 185, 129, 0.35);
}

.btn-detail-pause {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    font-size: 12px;
    font-weight: 700;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid rgba(245, 158, 11, 0.5);
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.2), rgba(217, 119, 6, 0.2));
    color: #fbbf24;
    user-select: none;
}
.btn-detail-pause:hover {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.35), rgba(217, 119, 6, 0.35));
    border-color: #f59e0b;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
    transform: translateY(-1px);
}
.btn-detail-pause.unpause {
    border-color: rgba(16, 185, 129, 0.5);
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.25), rgba(5, 150, 105, 0.25));
    color: #6ee7b7;
}
.btn-detail-pause.unpause:hover {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.4), rgba(5, 150, 105, 0.4));
    border-color: #10b981;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

/* Jonli suhbat taymeri (Suhbatda holati tagidagi taymer) */
.talking-live-timer {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    font-weight: 700;
    font-family: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace, sans-serif;
    color: #60a5fa;
    background: rgba(30, 58, 138, 0.45);
    border: 1px solid rgba(96, 165, 250, 0.4);
    padding: 2px 7px;
    border-radius: 6px;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.25);
    white-space: nowrap;
}

.talking-live-timer .timer-icon {
    font-size: 10px;
    line-height: 1;
}

.talking-live-timer .timer-digits {
    line-height: 1;
}

/* 3 daqiqadan oshgan suhbat (Ogohlantirish — sariq) */
.talking-live-timer.timer-warning {
    color: #fcd34d;
    background: rgba(146, 64, 14, 0.45);
    border-color: rgba(245, 158, 11, 0.6);
    box-shadow: 0 2px 10px rgba(245, 158, 11, 0.3);
}

/* 7 daqiqadan oshgan uzoq suhbat (Xavf/Diqqat — qizil pulsatsiya) */
.talking-live-timer.timer-danger {
    color: #fca5a5;
    background: rgba(153, 27, 27, 0.55);
    border-color: rgba(239, 68, 68, 0.7);
    box-shadow: 0 2px 12px rgba(239, 68, 68, 0.4);
    animation: talkingTimerPulse 1.4s ease-in-out infinite;
}

@keyframes talkingTimerPulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 2px 12px rgba(239, 68, 68, 0.4);
    }
    50% {
        transform: scale(1.04);
        box-shadow: 0 2px 18px rgba(239, 68, 68, 0.7);
    }
}

/* Red Circular End Call Button */
.btn-end-call {
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: transform 0.15s ease, filter 0.15s ease;
}

.btn-end-call:hover {
    transform: scale(1.1);
    filter: brightness(1.15) drop-shadow(0 0 8px rgba(239, 68, 68, 0.7));
}

.btn-end-call:active {
    transform: scale(0.92);
}

/* Clickable KPI Cards & Operator Cards */
.clickable-kpi {
    cursor: pointer;
    transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.clickable-kpi:hover {
    transform: translateY(-2px);
    border-color: rgba(59, 130, 246, 0.6);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.operator-card.clickable-card {
    cursor: pointer;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.operator-card.clickable-card:hover {
    border-color: rgba(59, 130, 246, 0.7);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
}

/* Static Operator Card (/operators sahifasi uchun o'zgarmas, toza kartochkalar) */
.operator-card.static-operator-card {
    position: relative;
    background: var(--card-bg, #1e293b);
    border: 1px solid var(--border-color, rgba(255, 255, 255, 0.08));
    border-radius: var(--radius-sm, 8px);
    padding: 16px;
    transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
    display: flex;
    flex-direction: column;
    gap: 8px;
    animation: none !important;
}

.operator-card.static-operator-card:hover {
    transform: translateY(-2px);
    border-color: rgba(59, 130, 246, 0.5);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35);
}

.operator-card.static-operator-card.is-selected {
    border: 2px solid var(--primary, #3b82f6) !important;
    background: rgba(59, 130, 246, 0.08) !important;
    box-shadow: 0 0 16px rgba(59, 130, 246, 0.35) !important;
}

/* ==========================================================================
   Operator Card — Live Call Animations (Jiringlanmoqda / Suhbatda)
   Qo'ng'iroq kelganda yoki suhbat ketayotganda kartaning chekkasida
   pulsatsiyalanuvchi yorug'lik chizig'i ko'rsatiladi.
   ========================================================================== */

/* Kartaning chap chekkasidagi jonli chiziq */
.call-live-strip {
    position: absolute;
    left: 0;
    top: 10%;
    bottom: 10%;
    width: 5px;
    border-radius: 0 6px 6px 0;
    pointer-events: none;
    z-index: 3;
}

.call-live-strip.ringing {
    background: linear-gradient(180deg, #fbbf24, #ea580c, #fbbf24);
    box-shadow: 0 0 12px rgba(245, 158, 11, 0.9), 0 0 26px rgba(245, 158, 11, 0.45);
    animation: edgeStripPulse 0.9s ease-in-out infinite;
}

.call-live-strip.outbound-ringing {
    background: linear-gradient(180deg, #38bdf8, #0284c7, #38bdf8);
    box-shadow: 0 0 12px rgba(14, 165, 233, 0.9), 0 0 26px rgba(14, 165, 233, 0.45);
    animation: edgeStripPulse 0.9s ease-in-out infinite;
}

.call-live-strip.talking {
    background: linear-gradient(180deg, #7dd3fc, #0ea5e9, #7dd3fc);
    box-shadow: 0 0 10px rgba(56, 189, 248, 0.85), 0 0 22px rgba(14, 165, 233, 0.4);
    animation: edgeStripPulse 1.8s ease-in-out infinite;
}

/* Jiringlanayotgan / suhbatdagi kartalarning porlashi (glow) endi statik box-shadow
   bilan chizilgan ::after qatlamining faqat opacity'sini animatsiya qiladi — bu GPU
   kompozitor darajasida ishlaydi va har freymda qayta chizishni (repaint) talab qilmaydi,
   shuning uchun bir nechta karta bir vaqtda porlaganda ham protsessorni og'ir yuklamaydi. */
.operator-card.call-ringing {
    border-color: rgba(245, 158, 11, 0.7) !important;
}

.operator-card.call-outbound-ringing {
    border-color: rgba(14, 165, 233, 0.85) !important;
}

.operator-card.call-talking {
    border-color: rgba(14, 165, 233, 0.7) !important;
}

.operator-card.call-ringing::after,
.operator-card.call-outbound-ringing::after,
.operator-card.call-talking::after {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    pointer-events: none;
    will-change: opacity;
}

.operator-card.call-ringing::after {
    box-shadow: 0 0 22px 2px rgba(245, 158, 11, 0.4), inset 0 0 18px rgba(245, 158, 11, 0.15);
    animation: cardGlowPulse 1s ease-in-out infinite;
}

.operator-card.call-outbound-ringing::after {
    box-shadow: 0 0 22px 2px rgba(14, 165, 233, 0.5), inset 0 0 18px rgba(14, 165, 233, 0.2);
    animation: cardGlowPulse 1s ease-in-out infinite;
}

.operator-card.call-talking::after {
    box-shadow: 0 0 18px 1px rgba(14, 165, 233, 0.28), inset 0 0 14px rgba(14, 165, 233, 0.1);
    animation: cardGlowPulse 2.4s ease-in-out infinite;
}

.operator-card.next-in-line:not(.call-ringing):not(.call-outbound-ringing):not(.call-talking) {
    border-color: rgba(245, 158, 11, 0.65) !important;
    box-shadow: 0 4px 22px rgba(245, 158, 11, 0.18) !important;
}

.operator-card.next-in-line:not(.call-ringing):not(.call-outbound-ringing):not(.call-talking):hover {
    border-color: rgba(245, 158, 11, 0.9) !important;
    box-shadow: 0 6px 28px rgba(245, 158, 11, 0.32) !important;
}

/* Jiringlash badge (blink qiluvchi) */
.call-badge-ringing {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 11px;
    padding: 3px 10px;
    border-radius: 999px;
    font-weight: 700;
    white-space: nowrap;
    background: rgba(245, 158, 11, 0.18);
    border: 1px solid rgba(245, 158, 11, 0.5);
    color: #fbbf24;
    animation: callBadgeBlink 0.9s ease-in-out infinite;
}

/* ==========================================================================
   Keyingi qo'ng'iroq bashorati (Next in Line - 100% Predict) Oltin burchak belgisi
   ========================================================================== */
.next-call-corner-badge {
    position: absolute;
    top: -11px;
    right: 14px;
    z-index: 15;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    filter: drop-shadow(0 2px 9px rgba(245, 158, 11, 0.75));
    animation: nextCallBadgeFloat 2.4s ease-in-out infinite;
    pointer-events: auto;
    transition: transform 0.2s ease, filter 0.2s ease;
}

.next-call-corner-badge:hover {
    transform: scale(1.18);
    filter: drop-shadow(0 4px 16px rgba(245, 158, 11, 0.98));
}

.next-call-corner-badge.is-ringing {
    animation: nextCallRingingPulse 0.8s ease-in-out infinite;
    filter: drop-shadow(0 0 12px rgba(245, 158, 11, 1));
}

@keyframes nextCallRingingPulse {
    0%, 100% {
        transform: scale(1.06) translateY(0);
        filter: drop-shadow(0 0 10px rgba(245, 158, 11, 0.8));
    }
    50% {
        transform: scale(1.22) translateY(-3px);
        filter: drop-shadow(0 0 18px rgba(245, 158, 11, 1));
    }
}

@keyframes nextCallBadgeFloat {
    0%, 100% {
        transform: translateY(0);
        filter: drop-shadow(0 2px 9px rgba(245, 158, 11, 0.75));
    }
    50% {
        transform: translateY(-2px);
        filter: drop-shadow(0 4px 15px rgba(245, 158, 11, 0.95));
    }
}


@keyframes edgeStripPulse {
    0%, 100% { opacity: 1; transform: scaleY(1); }
    50%      { opacity: 0.45; transform: scaleY(0.82); }
}

/* callRingGlow/callTalkGlow (box-shadow animatsiyasi) o'rniga endi cardGlowPulse ishlatiladi —
   pastga qarang. Faqat opacity animatsiya qilinadi, box-shadow qiymati statik. */
@keyframes cardGlowPulse {
    0%, 100% { opacity: 0.35; }
    50%      { opacity: 1; }
}

@keyframes callBadgeBlink {
    0%, 100% { opacity: 1; }
    50%      { opacity: 0.55; }
}

/* Detail Modal Styles */
.detail-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
    text-align: center;
}

.detail-table th {
    text-align: center;
    vertical-align: middle;
    padding: 12px 14px;
    background: rgba(30, 41, 59, 0.85);
    color: var(--text-muted);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    border-bottom: 1px solid var(--border-color);
    white-space: nowrap;
}

.detail-table td {
    padding: 10px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-main);
    vertical-align: middle;
    white-space: nowrap;
    text-align: center;
}

.detail-table td > div,
.detail-table th > div {
    justify-content: center;
}

.detail-table th.cell-left,
.detail-table td.cell-left {
    text-align: left;
}

/* Ekrandan tashqaridagi qatorlarning layout/paint ishini brauzerga o'tkazib yuborish
   (arzon "virtualizatsiya") — uzun jadval (yuzlab qator) scroll qilinganda kuchsiz
   kompyuterlarda "tortishib qolish"ni kamaytiradi. Qo'llab-quvvatlamaydigan brauzerda
   sodda ravishda e'tiborga olinmaydi, hech narsa buzilmaydi. */
.detail-table tbody tr {
    content-visibility: auto;
    contain-intrinsic-size: auto 42px;
}

.detail-table tr:hover td {
    background: rgba(59, 130, 246, 0.08);
}

.detail-table th[onclick]:hover {
    color: #fff;
    background: rgba(59, 130, 246, 0.18);
}

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

.spinner {
    display: inline-block;
    width: 26px;
    height: 26px;
    border: 3px solid rgba(56, 189, 248, 0.2);
    border-top-color: #38bdf8;
    border-radius: 50%;
    animation: spin 0.8s linear infinite !important;
    box-sizing: border-box;
}

.spinner.spinner-lg {
    width: 44px;
    height: 44px;
    border-width: 3.5px;
    border-top-color: #38bdf8;
    box-shadow: 0 0 18px rgba(56, 189, 248, 0.3);
}

.spinner.spinner-sm {
    width: 16px;
    height: 16px;
    border-width: 2px;
}

/* ==========================================================================
   Date Filter Toolbar & Windows/Fluent Inspired Dark Calendar
   ========================================================================== */
.date-filter-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 10px 20px;
    margin-bottom: 22px;
    background: rgba(15, 23, 42, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
    position: relative;
    z-index: 40;
    flex-wrap: wrap;
}

.date-filter-left {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.date-filter-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.cal-dropdown-container {
    position: relative;
}

.cal-trigger-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 9px 18px;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.8), rgba(15, 23, 42, 0.9));
    border: 1px solid rgba(59, 130, 246, 0.35);
    border-radius: var(--radius-md);
    color: #ffffff;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    transition: all 0.2s ease;
}

.cal-trigger-btn:hover {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(30, 41, 59, 0.9));
    border-color: rgba(59, 130, 246, 0.6);
    box-shadow: 0 0 14px rgba(59, 130, 246, 0.25);
    transform: translateY(-1px);
}

.cal-trigger-icon {
    font-size: 16px;
}

.cal-selected-label {
    letter-spacing: 0.2px;
}

.cal-trigger-arrow {
    font-size: 10px;
    color: var(--text-muted);
    transition: transform 0.2s ease;
}

.cal-trigger-btn.active .cal-trigger-arrow {
    transform: rotate(180deg);
}

/* Quick Filter Pills */
.cal-quick-group {
    display: flex;
    gap: 6px;
    background: rgba(30, 41, 59, 0.5);
    padding: 4px;
    border-radius: var(--radius-md);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.cal-quick-pill {
    padding: 5px 14px;
    border-radius: var(--radius-sm);
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.cal-quick-pill:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.06);
}

.cal-quick-pill.active {
    background: #4f46e5;
    color: #ffffff;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(79, 70, 229, 0.4);
}

/* Live / Archive Mode Badges */
.cal-mode-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    background: rgba(16, 185, 129, 0.12);
    border: 1px solid rgba(16, 185, 129, 0.35);
    color: #34d399;
}

.cal-mode-badge.archive {
    background: rgba(245, 158, 11, 0.15);
    border-color: rgba(245, 158, 11, 0.4);
    color: #fbbf24;
}

.cal-mode-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #10b981;
    box-shadow: 0 0 8px #10b981;
    animation: pulseGlow 2s infinite ease-in-out;
}

.cal-mode-badge.archive .cal-mode-dot {
    background: #f59e0b;
    box-shadow: 0 0 8px #f59e0b;
    animation: none;
}

.btn-back-today {
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    background: rgba(59, 130, 246, 0.2);
    border: 1px solid rgba(59, 130, 246, 0.4);
    color: #60a5fa;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-back-today:hover {
    background: rgba(59, 130, 246, 0.35);
    color: #ffffff;
    transform: translateY(-1px);
}

/* Export tugmasi FAQAT /operators sahifasida ko'rinadi */
html:not([data-tab="operators"]) #btnExportExcel {
    display: none !important;
}
html[data-tab="operators"] #btnExportExcel {
    display: inline-flex !important;
}

.cal-status-hint {
    font-size: 12px;
    color: var(--text-muted);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.cal-refresh-btn {
    padding: 6px 14px;
    font-size: 12px;
    border-radius: var(--radius-sm);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.cal-spin-icon {
    display: inline-block;
    line-height: 1;
}

.cal-refresh-btn.is-loading .cal-spin-icon {
    animation: fluentSpin 0.75s linear infinite;
}

/* Progress Bar on Date Filter Bar */
.date-filter-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    width: 100%;
    background: linear-gradient(90deg, #3b82f6, #06b6d4, #10b981, #3b82f6);
    background-size: 200% 100%;
    animation: calProgressFlow 1.2s linear infinite;
    border-bottom-left-radius: var(--radius-lg);
    border-bottom-right-radius: var(--radius-lg);
    display: none;
    z-index: 10;
}

@keyframes calProgressFlow {
    0% { background-position: 100% 0; }
    100% { background-position: -100% 0; }
}

/* Fluent Spinning Wheel */
.fluent-spinner {
    display: inline-block;
    width: 13px;
    height: 13px;
    border: 2px solid rgba(56, 189, 248, 0.25);
    border-top-color: #38bdf8;
    border-radius: 50%;
    animation: fluentSpin 0.7s linear infinite;
    vertical-align: middle;
}

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

.cal-loading-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 3px 10px;
    border-radius: 999px;
    background: rgba(56, 189, 248, 0.12);
    border: 1px solid rgba(56, 189, 248, 0.35);
    color: #38bdf8;
    font-size: 12px;
    font-weight: 500;
    animation: fadeIn 0.2s ease;
}

/* KPI Cards loading pulse state */
.kpi-grid.is-loading .kpi-card {
    opacity: 0.65;
    filter: brightness(0.9);
    transition: opacity 0.2s ease, filter 0.2s ease;
    position: relative;
    pointer-events: none;
}

.kpi-grid.is-loading .kpi-card::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.08), transparent);
    background-size: 200% 100%;
    animation: calShimmer 1.3s infinite;
}

/* Operator cards are strictly static - no shimmer, no pulses, no animations */
#tabOperatorsGrid .operator-card,
#tabOperatorsGrid.is-loading .operator-card,
.operator-card.static-operator-card {
    opacity: 1 !important;
    filter: none !important;
    animation: none !important;
    pointer-events: auto !important;
}

#tabOperatorsGrid .operator-card::after,
#tabOperatorsGrid.is-loading .operator-card::after,
.operator-card.static-operator-card::after {
    display: none !important;
    content: none !important;
    animation: none !important;
}

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

/* Number pop animation when data updates */
@keyframes numberPop {
    0% { transform: scale(0.95); opacity: 0.7; }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); opacity: 1; }
}

.number-pop {
    animation: numberPop 0.35s ease-out;
}

/* Modal Center Loading Box & Spinner Ring */
.modal-loading-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 260px;
    padding: 40px;
    width: 100%;
    margin: 0 auto;
    text-align: center;
}

.modal-spinner-ring {
    width: 44px;
    height: 44px;
    border: 3px solid rgba(59, 130, 246, 0.15);
    border-top-color: #3b82f6;
    border-right-color: #06b6d4;
    border-radius: 50%;
    animation: fluentSpin 0.8s cubic-bezier(0.4, 0, 0.2, 1) infinite;
    margin-bottom: 14px;
}

.modal-loading-text {
    font-size: 13px;
    color: var(--text-muted);
    font-weight: 500;
    letter-spacing: 0.3px;
}

/* ==========================================================================
   Windows/Fluent Dark Calendar Popup (Matching Image 2)
   ========================================================================== */
.fluent-calendar-popup {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    width: 320px;
    background: rgba(20, 24, 32, 0.98);
    backdrop-filter: blur(28px);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(0, 0, 0, 0.5);
    padding: 20px 20px 16px;
    z-index: 9999;
    user-select: none;
    animation: calFadeIn 0.15s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes calFadeIn {
    from { opacity: 0; transform: translateY(-8px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.cal-popup-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding-bottom: 14px;
    margin-bottom: 14px;
}

.cal-native-date-input {
    width: 100%;
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 6px;
    padding: 6px 10px;
    font-size: 13px;
    color: #f1f5f9;
    outline: none;
    font-family: inherit;
    transition: all 0.2s;
    color-scheme: dark;
}

.cal-native-date-input:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.25);
}

.cal-selected-display {
    font-size: 15px;
    font-weight: 700;
    color: #60a5fa;
    letter-spacing: -0.2px;
}

.cal-month-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
}

.cal-month-title {
    font-size: 14px;
    font-weight: 600;
    color: #ffffff;
    letter-spacing: -0.2px;
}

.cal-nav-buttons {
    display: flex;
    gap: 4px;
}

.cal-nav-btn {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 4px;
    color: #cbd5e1;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.15s ease;
}

.cal-nav-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.15);
}

.cal-weekdays-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    color: #94a3b8;
    margin-bottom: 8px;
}

.cal-days-matrix {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 3px;
    margin-bottom: 14px;
}

.cal-day-cell {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 500;
    color: #f1f5f9;
    border-radius: 4px;
    cursor: pointer;
    position: relative;
    border: 1px solid transparent;
    transition: all 0.12s ease;
}

.cal-day-cell:hover {
    background: rgba(255, 255, 255, 0.12);
}

.cal-day-cell.other-month {
    color: #475569;
}

.cal-day-cell.other-month:hover {
    color: #94a3b8;
    background: rgba(255, 255, 255, 0.05);
}

/* Today style: distinct subtle border box (like 13 in image 2) */
.cal-day-cell.is-today {
    border: 1px solid rgba(255, 255, 255, 0.4);
    font-weight: 600;
}

/* Selected style: Bright vibrant blue box (like 7 in image 2) */
.cal-day-cell.is-selected {
    background: #0078d4 !important;
    border: 2px solid #38bdf8 !important;
    color: #ffffff !important;
    font-weight: 700;
    box-shadow: 0 0 12px rgba(0, 120, 212, 0.6);
}

.cal-popup-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding-top: 12px;
}

.cal-footer-btn {
    padding: 5px 12px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 4px;
    color: #cbd5e1;
    font-size: 11px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s ease;
}

.cal-footer-btn:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #ffffff;
}

.cal-footer-btn.cal-close-btn {
    background: transparent;
    border-color: transparent;
    color: #94a3b8;
}

.cal-footer-btn.cal-close-btn:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
}

/* ==========================================================================
   MODERN STUDIO MUSIC PLAYER (Audio Explorer)
   Ultra-modern, cyberpunk/studio DAW aesthetics with interactive controls
   ========================================================================== */
.modern-music-player-card {
    animation: playerSlideFade 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    overflow: hidden;
    width: 100%;
    box-sizing: border-box;
    flex-shrink: 0;
    min-height: fit-content;
    background: linear-gradient(145deg, rgba(15, 23, 42, 0.96) 0%, rgba(26, 36, 56, 0.92) 50%, rgba(15, 23, 42, 0.98) 100%);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 16px;
    padding: 22px 26px;
    margin-bottom: 24px;
    box-shadow: 0 16px 40px -10px rgba(0, 0, 0, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.1);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.modern-music-player-card:hover {
    border-color: rgba(99, 102, 241, 0.5);
    box-shadow: 0 20px 45px -8px rgba(0, 0, 0, 0.8), 0 0 25px rgba(99, 102, 241, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.modern-music-player-card.is-playing {
    border-color: rgba(56, 189, 248, 0.55);
    box-shadow: 0 20px 50px -8px rgba(0, 0, 0, 0.85), 0 0 35px rgba(56, 189, 248, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.player-ambient-glow {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: radial-gradient(circle at 15% 20%, rgba(56, 189, 248, 0.08), transparent 40%),
                radial-gradient(circle at 85% 80%, rgba(139, 92, 246, 0.08), transparent 45%);
    z-index: 0;
}

/* Header row */
.player-top-header {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 16px;
}

.player-badge-group {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.player-studio-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 4px 11px;
    background: rgba(56, 189, 248, 0.12);
    border: 1px solid rgba(56, 189, 248, 0.3);
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    color: #38bdf8;
    letter-spacing: 0.8px;
}

/* Dynamic Equalizer Bars Animation */
.equalizer-icon-anim {
    display: inline-flex;
    align-items: flex-end;
    gap: 2px;
    height: 14px;
}

.eq-bar {
    width: 2.5px;
    height: 4px;
    border-radius: 1px;
    background: #38bdf8;
    transition: height 0.2s ease;
}

.modern-music-player-card.is-playing .eq-bar.eq-1 { animation: eqJump 0.6s ease-in-out infinite alternate; }
.modern-music-player-card.is-playing .eq-bar.eq-2 { animation: eqJump 0.4s ease-in-out 0.15s infinite alternate; }
.modern-music-player-card.is-playing .eq-bar.eq-3 { animation: eqJump 0.7s ease-in-out 0.3s infinite alternate; }
.modern-music-player-card.is-playing .eq-bar.eq-4 { animation: eqJump 0.5s ease-in-out 0.1s infinite alternate; }

@keyframes eqJump {
    0% { height: 3px; background: #38bdf8; }
    50% { height: 13px; background: #818cf8; }
    100% { height: 7px; background: #c084fc; }
}

.player-format-badge {
    font-size: 11px;
    font-weight: 600;
    padding: 3px 9px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #94a3b8;
}

.player-time-badge-box {
    display: inline-flex;
    align-items: baseline;
    gap: 5px;
    font-family: 'Inter', monospace;
    background: rgba(10, 15, 26, 0.75);
    padding: 5px 14px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: inset 0 1px 4px rgba(0, 0, 0, 0.5);
}

.player-time-elapsed {
    font-size: 16px;
    font-weight: 700;
    color: #38bdf8;
    font-variant-numeric: tabular-nums;
}

.player-time-divider {
    color: #64748b;
    font-size: 12px;
}

.player-time-total {
    font-size: 13px;
    font-weight: 600;
    color: #94a3b8;
    font-variant-numeric: tabular-nums;
}

/* Track Information Bar with Vinyl Disc */
.player-track-info-bar {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
}

.player-art-disk {
    width: 52px;
    height: 52px;
    min-width: 52px;
    border-radius: 50%;
    background: repeating-radial-gradient(circle, #0b0f19, #0b0f19 3px, #1e293b 4px, #0b0f19 5px);
    border: 2px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: box-shadow 0.3s ease;
}

.disk-center {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.4);
}

.modern-music-player-card.is-playing .player-art-disk {
    animation: spinVinyl 5s linear infinite;
    box-shadow: 0 0 20px rgba(56, 189, 248, 0.5), 0 4px 14px rgba(0, 0, 0, 0.6);
    border-color: rgba(56, 189, 248, 0.6);
}

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

.player-meta-details {
    flex: 1;
    min-width: 0;
}

.player-track-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.player-file-title {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 700;
    color: #ffffff;
    margin: 0;
    font-family: monospace;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: 0.2px;
}

.player-file-title svg,
.player-file-title .isax {
    width: 17px;
    height: 17px;
    flex-shrink: 0;
    color: #38bdf8;
    vertical-align: middle;
}

.player-status-subtitle {
    font-size: 12px;
    color: #94a3b8;
    margin-top: 3px;
    font-weight: 500;
}

.btn-player-download {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 12px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.14);
    color: #f1f5f9;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.btn-player-download:hover {
    background: rgba(56, 189, 248, 0.18);
    border-color: rgba(56, 189, 248, 0.45);
    color: #38bdf8;
    box-shadow: 0 2px 10px rgba(56, 189, 248, 0.2);
}

/* WaveSurfer Deck */
.player-waveform-deck {
    position: relative;
    z-index: 1;
    background: rgba(8, 12, 22, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 14px 16px 10px;
    margin-bottom: 18px;
    box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.7);
    transition: border-color 0.25s ease;
}

.modern-music-player-card.is-playing .player-waveform-deck {
    border-color: rgba(56, 189, 248, 0.3);
}

.waveform-timeline-ruler {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
    font-family: monospace;
    color: #94a3b8;
    margin-bottom: 6px;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.08);
    padding-bottom: 5px;
    letter-spacing: 0.3px;
}

.waveform-timeline-ruler .ruler-start {
    color: #38bdf8;
    font-weight: 700;
}

.waveform-timeline-ruler .ruler-end {
    color: #a5b4fc;
    font-weight: 700;
}

.waveform-timeline-ruler .ruler-center-track {
    flex: 1;
    margin: 0 14px;
    height: 1px;
    background: linear-gradient(90deg, rgba(56, 189, 248, 0.25) 0%, rgba(255, 255, 255, 0.05) 50%, rgba(165, 180, 252, 0.25) 100%);
}

.waveform-canvas {
    width: 100%;
    min-height: 86px;
}

.waveform-loading-overlay {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: rgba(10, 15, 26, 0.85);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 13px;
    color: #38bdf8;
    font-weight: 600;
}

.wave-loading-spinner {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(56, 189, 248, 0.25);
    border-top-color: #38bdf8;
    border-radius: 50%;
    animation: fluentSpin 0.75s linear infinite;
}

/* Controls Deck */
.player-controls-deck {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.player-control-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Volume controls */
.volume-group {
    min-width: 180px;
}

.volume-slider-box {
    display: flex;
    align-items: center;
    gap: 8px;
}

.modern-range-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 90px;
    height: 5px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    outline: none;
    cursor: pointer;
    transition: background 0.2s;
}

.modern-range-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 13px;
    height: 13px;
    border-radius: 50%;
    background: #38bdf8;
    box-shadow: 0 0 8px #38bdf8;
    cursor: pointer;
    transition: transform 0.15s ease;
}

.modern-range-slider::-webkit-slider-thumb:hover {
    transform: scale(1.25);
}

.volume-value-label {
    font-size: 11px;
    font-weight: 600;
    color: #94a3b8;
    font-family: monospace;
    width: 32px;
}

/* Primary Transport Buttons */
.primary-transport {
    gap: 12px;
}

.btn-control-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #cbd5e1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-control-icon:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.25);
    transform: scale(1.06);
}

.btn-control-icon.active {
    background: rgba(16, 185, 129, 0.18);
    border-color: rgba(16, 185, 129, 0.5);
    color: #34d399;
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.35);
}

.btn-transport-step {
    padding: 6px 14px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #cbd5e1;
    font-size: 12px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-transport-step:hover {
    background: rgba(59, 130, 246, 0.18);
    border-color: rgba(59, 130, 246, 0.4);
    color: #60a5fa;
    transform: translateY(-1px);
}

/* Hero Play/Pause Button */
.btn-hero-play {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6 0%, #6366f1 50%, #8b5cf6 100%);
    border: none;
    color: #ffffff;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.55), 0 0 0 2px rgba(255, 255, 255, 0.15);
    transition: all 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.btn-hero-play:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 28px rgba(99, 102, 241, 0.75), 0 0 0 3px rgba(255, 255, 255, 0.25);
}

.btn-hero-play:active {
    transform: scale(0.94);
}

.modern-music-player-card.is-playing .btn-hero-play {
    box-shadow: 0 0 24px rgba(56, 189, 248, 0.65), 0 0 0 2px rgba(56, 189, 248, 0.4);
}

/* Speed Pills */
.speed-group {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.speed-label {
    font-size: 12px;
    color: #94a3b8;
    font-weight: 500;
}

.speed-pill-selector {
    display: inline-flex;
    background: rgba(10, 15, 26, 0.75);
    padding: 3px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    gap: 3px;
}

.speed-pill {
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    color: #94a3b8;
    background: transparent;
    border: none;
    cursor: pointer;
    transition: all 0.18s ease;
}

.speed-pill:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
}

.speed-pill.active {
    background: linear-gradient(135deg, #2563eb, #3b82f6);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.4);
}

.btn-player-close {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #94a3b8;
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-player-close:hover {
    background: rgba(239, 68, 68, 0.22);
    border-color: rgba(239, 68, 68, 0.55);
    color: #f87171;
    transform: scale(1.08);
}

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

/* ==========================================================================
   Recent Calls Real-time Filters (Dashboard)
   ========================================================================== */
.recent-filters-toolbar {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.recent-filter-item {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.recent-filter-item input:focus,
.recent-filter-item select:focus {
    border-color: #3b82f6 !important;
    box-shadow: 0 0 12px rgba(59, 130, 246, 0.3) !important;
}

.recent-filter-item select option {
    background: #0f172a;
    color: #e2e8f0;
    padding: 6px 10px;
}

#btnClearRecentFilters:hover {
    background: rgba(239, 68, 68, 0.28) !important;
    border-color: rgba(239, 68, 68, 0.6) !important;
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.35);
    transform: translateY(-1px);
}

.sortable-th {
    cursor: pointer !important;
    user-select: none;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.sortable-th:hover {
    color: #38bdf8 !important;
    background: rgba(56, 189, 248, 0.08);
}

.sort-icon {
    display: inline-block;
    width: 12px;
    text-align: center;
    margin-left: 4px;
    font-size: 11px;
    opacity: 0.4;
    transition: opacity 0.2s ease, color 0.2s ease;
    vertical-align: middle;
}

/* Saralash belgisi sarlavha matnini chapga surmasligi uchun
   chap tomonda xuddi shunday ko'rinmas bo'shliq qoldiramiz */
.data-table th.sortable-th::before,
.detail-table th.sortable-th::before {
    content: '';
    display: inline-block;
    width: 16px;
}

/* Custom Date Box DD.MM.YYYY Display */
.custom-date-box {
    position: relative;
}

.custom-date-box:hover > div,
.custom-date-box:focus-within > div {
    border-color: #3b82f6 !important;
    background: rgba(30, 41, 59, 1) !important;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.25) !important;
}

/* Export Choice Modal (3 ta tugma) */
.export-choice-btn {
    width: 100%;
    outline: none;
    box-sizing: border-box;
    position: relative;
    overflow: hidden;
    background: rgba(30, 41, 59, 0.85) !important;
    border: 1px solid rgba(255, 255, 255, 0.14) !important;
    border-radius: 12px;
    padding: 16px 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    text-align: left;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.export-choice-btn:hover {
    background: rgba(30, 41, 59, 0.98) !important;
    border-color: rgba(59, 130, 246, 0.5) !important;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45), 0 0 14px rgba(59, 130, 246, 0.15);
}

.export-choice-btn:hover .choice-arrow {
    transform: translateX(4px);
    color: #fff !important;
}

.export-choice-btn:active {
    transform: translateY(0);
}

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

/* ==========================================================================
   Header Language Switcher
   ========================================================================== */
.lang-switch-container {
    display: inline-flex;
    align-items: center;
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(59, 130, 246, 0.35);
    border-radius: 20px;
    padding: 3px 6px;
    gap: 2px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    user-select: none;
    backdrop-filter: blur(8px);
}

.lang-btn {
    background: transparent;
    border: none;
    color: var(--text-dim, #94a3b8);
    font-size: 11px;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    outline: none;
    letter-spacing: 0.5px;
    line-height: 1;
}

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

.lang-btn.active {
    background: linear-gradient(135deg, #0284c7 0%, #2563eb 100%);
    color: #ffffff !important;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.45);
}

.lang-separator {
    color: rgba(148, 163, 184, 0.35);
    font-size: 11px;
    font-weight: 600;
}

/* ==========================================================================
   Header User Profile Avatar & Downward Dropdown Menu
   ========================================================================== */
.user-profile-menu {
    position: relative;
    display: inline-flex;
    align-items: center;
    user-select: none;
    flex-shrink: 0;
}

.user-profile-avatar-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(30, 41, 59, 0.7);
    border: 1px solid rgba(147, 197, 253, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #93c5fd;
    cursor: pointer;
    outline: none;
    padding: 0;
    transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.user-profile-avatar-btn:hover,
.user-profile-menu.open .user-profile-avatar-btn {
    background: rgba(37, 99, 235, 0.25);
    border-color: rgba(147, 197, 253, 0.6);
    color: #ffffff;
    box-shadow: 0 0 12px rgba(59, 130, 246, 0.35);
    transform: scale(1.05);
}

.user-profile-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 200px;
    background: rgba(15, 23, 42, 0.94);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5), 0 0 1px rgba(255, 255, 255, 0.15);
    padding: 6px;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px) scale(0.97);
    transition: opacity 0.2s cubic-bezier(0.16, 1, 0.3, 1), 
                transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), 
                visibility 0.2s;
    pointer-events: none;
}

.user-profile-menu.open .user-profile-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

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

.user-dropdown-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(59, 130, 246, 0.2);
    border: 1px solid rgba(59, 130, 246, 0.35);
    color: #60a5fa;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.user-dropdown-info {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.user-dropdown-name {
    font-size: 13px;
    font-weight: 600;
    color: #f1f5f9;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.user-dropdown-role {
    font-size: 11px;
    color: #94a3b8;
    text-transform: capitalize;
}

.user-dropdown-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.08);
    margin: 4px 0 6px 0;
}

.user-dropdown-items {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.user-dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 8px 10px;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: #cbd5e1;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    text-align: left;
    transition: all 0.15s ease;
    outline: none;
}

.user-dropdown-item:hover {
    background: rgba(255, 255, 255, 0.07);
    color: #ffffff;
}

.user-dropdown-item.logout {
    color: #f87171;
}

.user-dropdown-item.logout:hover {
    background: rgba(239, 68, 68, 0.15);
    color: #fca5a5;
}

/* Real-time Bog'lanishi kerak bo'lgan mijozlar - Jonli suhbat indikatori */
@keyframes cbPulse {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
    70% { transform: scale(1.08); box-shadow: 0 0 0 6px rgba(16, 185, 129, 0); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

@keyframes cbCardGlow {
    0%, 100% {
        border-color: rgba(16, 185, 129, 0.6);
        box-shadow: 0 0 10px rgba(16, 185, 129, 0.2);
    }
    50% {
        border-color: rgba(16, 185, 129, 1);
        box-shadow: 0 0 20px rgba(16, 185, 129, 0.45);
    }
}

@keyframes cbDotPulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.35; transform: scale(0.8); }
}

.callback-card-talking {
    border-color: rgba(16, 185, 129, 0.85) !important;
    border-left: 3.5px solid #10b981 !important;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.16), rgba(15, 23, 42, 0.92)) !important;
    animation: cbCardGlow 2.5s infinite ease-in-out;
}

.callback-active-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: rgba(16, 185, 129, 0.25);
    border: 1px solid rgba(16, 185, 129, 0.6);
    padding: 1px 7px;
    border-radius: 12px;
    font-size: 10px;
    color: #34d399;
    font-weight: 700;
    letter-spacing: 0.2px;
}

.callback-active-badge img {
    width: 13px;
    height: 13px;
    border-radius: 50%;
    object-fit: contain;
    animation: cbPulse 1.6s infinite ease-in-out;
}

.callback-active-subrow {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(16, 185, 129, 0.14);
    border: 1px solid rgba(16, 185, 129, 0.35);
    border-radius: 5px;
    padding: 2px 7px;
    font-size: 10px;
    color: #6ee7b7;
    font-weight: 600;
}

.callback-active-subrow .active-dot {
    display: inline-block;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #10b981;
    box-shadow: 0 0 5px #10b981;
    animation: cbDotPulse 1.2s infinite;
}

/* ==========================================================================
   PRODUCTION DEPLOY & AUTO-REFRESH NOTIFICATION BANNER
   ========================================================================== */
.deploy-update-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100000;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.98) 0%, rgba(30, 58, 138, 0.96) 50%, rgba(16, 185, 129, 0.95) 100%);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 2px solid #38bdf8;
    box-shadow: 0 10px 35px -5px rgba(0, 0, 0, 0.8), 0 0 25px rgba(56, 189, 248, 0.4);
    animation: slideDownDeployBanner 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    padding: 10px 24px;
    color: #ffffff;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

@keyframes slideDownDeployBanner {
    from {
        transform: translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.deploy-banner-content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

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

.deploy-banner-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.3);
    font-size: 20px;
    animation: rocketBob 2s infinite ease-in-out;
}

@keyframes rocketBob {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-3px) rotate(8deg); }
}

.deploy-banner-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.deploy-banner-title {
    font-size: 14px;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: -0.2px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.4);
}

.deploy-banner-sub {
    font-size: 12px;
    color: #bae6fd;
    font-weight: 500;
}

.deploy-banner-sub .countdown-sec {
    display: inline-block;
    min-width: 18px;
    text-align: center;
    font-weight: 800;
    font-size: 13px;
    color: #38bdf8;
    background: rgba(15, 23, 42, 0.7);
    padding: 1px 6px;
    border-radius: 4px;
    border: 1px solid rgba(56, 189, 248, 0.4);
}

.deploy-banner-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn-deploy-reload {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 7px 18px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.4);
    transition: all 0.2s ease;
}

.btn-deploy-reload:hover {
    transform: translateY(-1px) scale(1.02);
    box-shadow: 0 6px 18px rgba(16, 185, 129, 0.6);
    background: linear-gradient(135deg, #34d399 0%, #10b981 100%);
}

.btn-deploy-reload:active {
    transform: translateY(1px) scale(0.98);
}

.btn-deploy-reload svg {
    animation: rotateSlow 4s linear infinite;
}

@keyframes rotateSlow {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.btn-deploy-dismiss {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.12);
    color: #e2e8f0;
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 7px 12px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-deploy-dismiss:hover {
    background: rgba(255, 255, 255, 0.22);
    color: #ffffff;
}

/* ==========================================================================
   Mijozlar Boshqaruvi (Clients Management) Styling
   ========================================================================== */

/* Language filter pills */
.clients-lang-filters {
    display: flex;
    gap: 6px;
    align-items: center;
    flex-wrap: wrap;
}

.lang-filter-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--text-dim, #94a3b8);
    border-radius: 20px;
    padding: 5px 13px;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    white-space: nowrap;
    user-select: none;
}

.lang-filter-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.22);
}

.lang-filter-btn.active {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.3), rgba(79, 70, 229, 0.2));
    border-color: rgba(99, 102, 241, 0.55);
    color: #a5b4fc;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.2);
}

/* Language Badges */
.client-lang-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 9px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.2px;
    line-height: 1.3;
}

.client-lang-badge.lang-uz {
    background: rgba(59, 130, 246, 0.15);
    border: 1px solid rgba(59, 130, 246, 0.35);
    color: #60a5fa;
}

.client-lang-badge.lang-ru {
    background: rgba(168, 85, 247, 0.15);
    border: 1px solid rgba(168, 85, 247, 0.35);
    color: #c084fc;
}

.client-lang-badge.lang-en {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.35);
    color: #34d399;
}

.client-lang-badge.lang-other {
    background: rgba(245, 158, 11, 0.15);
    border: 1px solid rgba(245, 158, 11, 0.35);
    color: #fbbf24;
}

.client-lang-badge.lang-none {
    background: rgba(148, 163, 184, 0.1);
    border: 1px solid rgba(148, 163, 184, 0.2);
    color: #94a3b8;
    font-weight: 500;
}

/* Top Active Callers Grid & Card */
.top-active-clients-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
    gap: 14px;
}

.top-active-card {
    position: relative;
    background: linear-gradient(145deg, rgba(30, 41, 59, 0.7), rgba(15, 23, 42, 0.8));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 14px 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    backdrop-filter: blur(8px);
}

.top-active-card:hover {
    transform: translateY(-2px);
    border-color: rgba(99, 102, 241, 0.4);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35), 0 0 16px rgba(99, 102, 241, 0.15);
}

.top-active-card .card-rank-badge {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
}

.top-active-card.rank-1 .card-rank-badge {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: #fff;
    box-shadow: 0 0 12px rgba(245, 158, 11, 0.45);
}

.top-active-card.rank-2 .card-rank-badge {
    background: linear-gradient(135deg, #94a3b8, #64748b);
    color: #fff;
    box-shadow: 0 0 10px rgba(148, 163, 184, 0.35);
}

.top-active-card.rank-3 .card-rank-badge {
    background: linear-gradient(135deg, #b45309, #78350f);
    color: #fef3c7;
    box-shadow: 0 0 10px rgba(180, 83, 9, 0.35);
}

.top-active-card.rank-other .card-rank-badge {
    background: rgba(255, 255, 255, 0.08);
    color: #94a3b8;
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.top-active-card .top-card-meta {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    background: rgba(0, 0, 0, 0.25);
    border-radius: 8px;
    padding: 8px 10px;
    border: 1px solid rgba(255, 255, 255, 0.04);
}

.top-active-card .meta-item {
    display: flex;
    flex-direction: column;
}

.top-active-card .meta-label {
    font-size: 10.5px;
    color: var(--text-muted, #64748b);
    text-transform: uppercase;
    letter-spacing: 0.3px;
    font-weight: 600;
}

.top-active-card .meta-val {
    font-size: 13px;
    font-weight: 700;
    color: #e2e8f0;
    margin-top: 2px;
}

/* Action buttons in Table */
.client-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 7px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #cbd5e1;
    cursor: pointer;
    transition: all 0.15s ease;
}

.client-action-btn:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    transform: translateY(-1px);
}

.client-action-btn.edit:hover {
    background: rgba(99, 102, 241, 0.2);
    border-color: rgba(99, 102, 241, 0.4);
    color: #818cf8;
}

.client-action-btn.history:hover {
    background: rgba(59, 130, 246, 0.2);
    border-color: rgba(59, 130, 246, 0.4);
    color: #60a5fa;
}

.client-action-btn.delete:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.4);
    color: #f87171;
}

/* Silliq jonli qo'ng'iroq qo'shilishi (Micro-animation) */
@keyframes liveCallNewRowHighlight {
    0% {
        background-color: rgba(59, 130, 246, 0.28) !important;
        transform: translateY(-6px);
        opacity: 0.8;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

.live-call-new-row {
    animation: liveCallNewRowHighlight 2s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* ==========================================================================
   TIZIM SOZLAMALARI MODALI (System Settings Glass Modal & RBAC)
   ========================================================================== */
.settings-modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(10, 15, 29, 0.75);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.25s;
    padding: 16px;
    box-sizing: border-box;
}

.settings-modal-backdrop.open {
    opacity: 1;
    visibility: visible;
}

.settings-modal-card {
    background: linear-gradient(160deg, #1e293b 0%, #0f172a 100%);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 18px;
    width: 100%;
    max-width: 680px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.65), 0 0 1px rgba(255, 255, 255, 0.2);
    transform: scale(0.96) translateY(10px);
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: hidden;
}

.settings-modal-backdrop.open .settings-modal-card {
    transform: scale(1) translateY(0);
}

.settings-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 22px 14px 22px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.settings-header-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.settings-header-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: rgba(59, 130, 246, 0.15);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: #60a5fa;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.settings-header-title h2 {
    margin: 0;
    font-size: 17px;
    font-weight: 700;
    color: #f8fafc;
}

.settings-header-sub {
    margin: 2px 0 0 0;
    font-size: 12px;
    color: #94a3b8;
}

.settings-close-btn {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.04);
    color: #94a3b8;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.18s;
}

.settings-close-btn:hover {
    background: rgba(239, 68, 68, 0.15);
    border-color: rgba(239, 68, 68, 0.35);
    color: #f87171;
}

/* Tabs Navigation */
.settings-tabs-nav {
    display: flex;
    background: rgba(15, 23, 42, 0.6);
    padding: 6px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    gap: 8px;
    overflow-x: auto;
}

.settings-tab-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 10px;
    border: 1px solid transparent;
    background: transparent;
    color: #94a3b8;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.settings-tab-btn:hover {
    color: #f1f5f9;
    background: rgba(255, 255, 255, 0.04);
}

.settings-tab-btn.active {
    background: rgba(59, 130, 246, 0.2);
    border-color: rgba(59, 130, 246, 0.4);
    color: #93c5fd;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.15);
}

/* Tab Content Panes */
.settings-tab-pane {
    display: none;
    padding: 18px 22px;
    overflow-y: auto;
    max-height: calc(90vh - 140px);
}

.settings-tab-pane.active {
    display: block;
    animation: fadeInTab 0.2s ease;
}

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

.settings-section-card {
    background: rgba(15, 23, 42, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 14px;
    padding: 16px;
}

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

.settings-card-header h4 {
    margin: 0;
    font-size: 14px;
    font-weight: 700;
    color: #f1f5f9;
}

.settings-card-header p {
    margin: 3px 0 0 0;
    font-size: 12px;
    color: #94a3b8;
}

.settings-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

@media (max-width: 600px) {
    .settings-form-row {
        grid-template-columns: 1fr;
    }
}

.settings-form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.settings-form-group label {
    font-size: 12px;
    font-weight: 600;
    color: #cbd5e1;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.badge-threshold-val {
    font-size: 11px;
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
    padding: 2px 8px;
    border-radius: 6px;
    font-weight: 700;
}

.range-slider-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
}

.range-slider-wrapper input[type="range"] {
    flex: 1;
    accent-color: #3b82f6;
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    cursor: pointer;
}

.range-min, .range-max {
    font-size: 11px;
    color: #64748b;
    font-weight: 600;
}

.form-hint {
    font-size: 11px;
    color: #64748b;
    line-height: 1.4;
}

.settings-select,
.settings-input {
    width: 100%;
    background: rgba(30, 41, 59, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 9px 12px;
    color: #f1f5f9;
    font-size: 13px;
    outline: none;
    box-sizing: border-box;
    transition: all 0.2s;
}

.settings-select:focus,
.settings-input:focus {
    border-color: rgba(59, 130, 246, 0.5);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.settings-card-actions {
    margin-top: 16px;
    display: flex;
    justify-content: flex-end;
}

.btn-settings-save {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 18px;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    border: 1px solid rgba(96, 165, 250, 0.4);
    border-radius: 10px;
    color: #ffffff;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
    transition: all 0.2s;
}

.btn-settings-save:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(37, 99, 235, 0.45);
}

/* Exclude List Styling */
.exclude-search-bar {
    margin-bottom: 12px;
}

.exclude-operators-list {
    max-height: 240px;
    overflow-y: auto;
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.4);
    padding: 6px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.exclude-op-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    transition: all 0.15s;
}

.exclude-op-item:hover {
    background: rgba(30, 41, 59, 0.8);
    border-color: rgba(255, 255, 255, 0.1);
}

.exclude-op-info {
    display: flex;
    align-items: center;
    gap: 8px;
}

.exclude-op-badge {
    font-size: 11px;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 6px;
    background: rgba(147, 197, 253, 0.15);
    color: #93c5fd;
}

.exclude-op-name {
    font-size: 13px;
    color: #e2e8f0;
    font-weight: 500;
}

/* Custom Switch for Exclude List */
.switch-label {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
}

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

.switch-slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background-color: rgba(239, 68, 68, 0.3);
    border: 1px solid rgba(239, 68, 68, 0.5);
    border-radius: 24px;
    transition: 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.switch-slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 3px;
    bottom: 3px;
    background-color: #f87171;
    border-radius: 50%;
    transition: 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.switch-label input:checked + .switch-slider {
    background-color: rgba(16, 185, 129, 0.25);
    border-color: rgba(16, 185, 129, 0.5);
}

.switch-label input:checked + .switch-slider:before {
    transform: translateX(20px);
    background-color: #34d399;
}

/* Users & RBAC Tab */
.new-user-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.user-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 12px;
}

@media (max-width: 600px) {
    .user-form-grid {
        grid-template-columns: 1fr;
    }
}

.user-form-submit {
    display: flex;
    justify-content: flex-end;
}

.btn-user-create {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: rgba(16, 185, 129, 0.2);
    border: 1px solid rgba(16, 185, 129, 0.4);
    border-radius: 10px;
    color: #34d399;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-user-create:hover {
    background: rgba(16, 185, 129, 0.35);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.25);
}

.users-table-wrapper {
    overflow-x: auto;
}

.settings-users-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.settings-users-table th {
    text-align: left;
    padding: 8px 10px;
    color: #94a3b8;
    font-weight: 600;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 12px;
}

.settings-users-table td {
    padding: 10px 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: #e2e8f0;
}

.role-tag {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
    text-transform: capitalize;
}

.role-tag.superuser {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
    border: 1px solid rgba(59, 130, 246, 0.35);
}

.role-tag.operator {
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.35);
}

.user-action-btn {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    padding: 4px 8px;
    font-size: 11px;
    cursor: pointer;
    color: #cbd5e1;
    transition: all 0.15s;
    margin-left: 4px;
}

.user-action-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.user-action-btn.delete {
    color: #f87171;
    border-color: rgba(239, 68, 68, 0.3);
}

.user-action-btn.delete:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.5);
}

.settings-loading {
    padding: 16px;
    text-align: center;
    color: #94a3b8;
    font-size: 12px;
}

