:root {
            --site-header-height: 72px;
            
            /* Default Theme Variables (ItHoppn) */
            --primary-color: #667eea;
            --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            --bg-body: linear-gradient(135deg, #f8f8f8 0%, #d3c4e2 100%);
            --bg-content: #ffffff;
            --card-bg: #ffffff;
            --navbar-bg: #ffffff;
            --sidebar-bg: #ffffff;
            --text-color: #333333;
            --text-muted: #6c757d;
            --border-color: #eee;
            --card-radius: 15px;
            --card-shadow: 0 5px 15px rgba(0,0,0,0.1);

            --main-font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
            --bubble-bg: #222222;
            --bubble-text: #ffffff;
        }

        /* Theme: Discord */
        [data-theme="discord"] {
            --primary-color: #5865F2;
            --primary-gradient: #5865F2;
            --bg-body: #36393f;
            --bg-content: #2f3136;
            --card-bg: #2f3136;
            --navbar-bg: #202225;
            --sidebar-bg: #2f3136;
            --text-color: #dcddde;
            --text-muted: #b9bbbe;
            --border-color: #202225;
            --card-shadow: 0 4px 15px rgba(0,0,0,0.2);
        }
        /* Discord Dark Mode Overrides */
        [data-theme="discord"] .bg-white { background-color: var(--card-bg) !important; color: var(--text-color) !important; }
        [data-theme="discord"] .bg-light { background-color: #40444b !important; color: var(--text-color) !important; }
        [data-theme="discord"] .text-dark { color: #ffffff !important; }
        [data-theme="discord"] .text-muted { color: #b9bbbe !important; }
        [data-theme="discord"] .border { border-color: #202225 !important; }
        [data-theme="discord"] .navbar-light .navbar-brand { color: #ffffff !important; }
        [data-theme="discord"] .navbar-light .nav-link { color: rgba(255,255,255,0.7) !important; }
        [data-theme="discord"] .dropdown-menu { background-color: #18191c; border-color: #202225; }
        [data-theme="discord"] .dropdown-item { color: #dcddde; }
        [data-theme="discord"] .dropdown-item:hover { background-color: #40444b; }
        [data-theme="discord"] .sidebar-nav-btn { color: #b9bbbe; }
        [data-theme="discord"] .sidebar-nav-btn:hover { background-color: #3ba55c; color: white; }
        [data-theme="discord"] .sidebar-nav-btn.active { background-color: #5865F2; color: white; }

        /* Discord Messenger Overrides */
        [data-theme="discord"] .messenger-wrapper { background-color: #36393f !important; border: 1px solid #202225 !important; box-shadow: none !important; }
        [data-theme="discord"] .side-contacts { background-color: #2f3136 !important; border-right: 1px solid #202225 !important; }
        [data-theme="discord"] .side-header { color: #fff !important; border-bottom: 1px solid #202225 !important; background-color: #2f3136 !important; }
        [data-theme="discord"] .contact-card { color: #b9bbbe !important; border-bottom: 1px solid #2f3136 !important; }
        [data-theme="discord"] .contact-card:hover { background-color: #32353b !important; }
        [data-theme="discord"] .contact-card.active { background-color: #42464D !important; color: #fff !important; }
        [data-theme="discord"] .chat-main { background-color: #36393f !important; }
        [data-theme="discord"] .chat-header { background-color: #36393f !important; border-bottom: 1px solid #26272d !important; color: #fff !important; }
        [data-theme="discord"] .message-received { background-color: #2f3136 !important; color: #dcddde !important; }
        [data-theme="discord"] .message-sent { background-color: #5865F2 !important; color: #fff !important; }
        [data-theme="discord"] .chat-input-area { background-color: #36393f !important; border-top: 1px solid #26272d !important; }
        [data-theme="discord"] .chat-input-wrapper { background-color: #40444b !important; color: #dcddde !important; }
        [data-theme="discord"] #messageInput { color: #dcddde !important; }
        [data-theme="discord"] .rabbit-avatar { background-color: #2f3136 !important; border-color: #202225 !important; color: #b9bbbe !important; }

        /* Discord Music Overrides */
        [data-theme="discord"] .track-item { background-color: #2f3136 !important; border: 1px solid #202225 !important; }
        [data-theme="discord"] .track-item h6 { color: #fff !important; }
        [data-theme="discord"] .track-item small { color: #b9bbbe !important; }
        [data-theme="discord"] .music-tabs { background-color: #2f3136 !important; }
        [data-theme="discord"] .music-tabs .nav-link { color: #b9bbbe !important; }
        [data-theme="discord"] .music-tabs .nav-link.active { background: #5865F2 !important; color: #fff !important; box-shadow: none !important; }
        [data-theme="discord"] .btn-play-main { background-color: #5865F2 !important; }
        [data-theme="discord"] .btn-play-main:hover { background-color: #4752c4 !important; }

        /* Theme: New Beginning */
        [data-theme="new_beginning"] {
            --primary-color: #00B4D8;
            --primary-gradient: linear-gradient(135deg, #48CAE4 0%, #0077B6 100%);
            --bg-body: linear-gradient(-45deg, #F0F8FF, #E6F2FF, #E0F7FA, #F0F8FF);
            --bg-content: rgba(255, 255, 255, 0.75);
            --card-bg: rgba(255, 255, 255, 0.75);
            --navbar-bg: rgba(255, 255, 255, 0.85);
            --sidebar-bg: rgba(255, 255, 255, 0.75);
            --text-color: #023E8A;
            --text-muted: #0077B6;
            --border-color: rgba(255, 255, 255, 0.6);
            --card-radius: 24px;
            --card-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.1);
        }
        
        /* Mobile Top Navbar & Sidebar */
        .mobile-top-navbar {
            background: var(--navbar-bg) !important;
            border-bottom: 1px solid var(--border-color);
        }
        .offcanvas {
            background: var(--sidebar-bg) !important;
            color: var(--text-color) !important;
        }
        
        [data-theme="new_beginning"] body {
            background-size: 400% 400% !important;
            animation: gradientWave 15s ease infinite !important;
        }
        
        [data-theme="new_beginning"] .card,
        [data-theme="new_beginning"] .navbar,
        [data-theme="new_beginning"] .left-sidebar-nav,
        [data-theme="new_beginning"] .post-card,
        [data-theme="new_beginning"] .mobile-top-navbar,
        [data-theme="new_beginning"] .modal-content,
        [data-theme="new_beginning"] .dropdown-menu,
        [data-theme="new_beginning"] .bottom-navbar {
            backdrop-filter: blur(12px);
            -webkit-backdrop-filter: blur(12px);
            border: 1px solid rgba(255, 255, 255, 0.5) !important;
        }
        
        [data-theme="new_beginning"] .bg-white { background-color: var(--card-bg) !important; }
        [data-theme="new_beginning"] .bg-light { background-color: rgba(255, 255, 255, 0.4) !important; }
        [data-theme="new_beginning"] .text-dark { color: #023E8A !important; }
        [data-theme="new_beginning"] .text-muted { color: #0077B6 !important; }
        
        @keyframes gradientWave {
            0% { background-position: 0% 50%; }
            50% { background-position: 100% 50%; }
            100% { background-position: 0% 50%; }
        }

        * {
            -webkit-tap-highlight-color: transparent; /* Убирает серое выделение при нажатии на мобильных */
        }
        
        /* Generic fix for profile stats overflow on mobile */
        @media (max-width: 768px) {
            .d-flex.gap-3, .d-flex.gap-4, .d-flex.gap-5 { flex-wrap: wrap; }
            .text-truncate { max-width: 100%; }
            img { max-width: 100%; height: auto; }
        }

        body { 
            background: var(--bg-body) !important;
            color: var(--text-color);
            min-height: 100vh;
            padding-top: calc(var(--site-header-height) + 12px);
            padding-bottom: 0;
            overscroll-behavior-y: none; /* Отключает "резиновый" скролл всей страницы */
            overflow-x: hidden; /* Исправляет вылезание контента (профиля) за края */
            width: 100%;
        }
        body.music-player-docked {
            padding-bottom: 86px !important;
        }
        body.call-active {
            overflow: hidden !important;
            height: 100% !important;
        }
        .app-navbar {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            z-index: 1030;
            background: var(--navbar-bg) !important;
        }
        .post-card { 
            background: var(--card-bg) !important; 
            border-radius: var(--card-radius) !important; 
            padding: 20px; 
            margin-bottom: 20px; 
            box-shadow: var(--card-shadow) !important;
            transition: transform 0.2s;
        }
        .post-card:hover {
            transform: translateY(-3px);
        }
        .post-text {
            white-space: pre-wrap;
            word-break: break-word;
        }
        /* Online Indicator */
        .online-indicator {
            width: 12px;
            height: 12px;
            background-color: #28a745;
            border-radius: 50%;
            border: 2px solid white;
            position: absolute;
            bottom: 0;
            right: 0;
        }
        /* Fix for scrolling in modals (long posts) */
        .modal-body {
            max-height: calc(100vh - 160px);
            overflow-y: auto;
            -webkit-overflow-scrolling: touch;
        }
        textarea.form-control {
            max-height: 40vh;
            overflow-y: auto !important;
        }
        .avatar { 
            width: 50px; 
            height: 50px; 
            border-radius: 50%; 
            object-fit: cover; 
            border: 2px solid var(--primary-color);
        }
        .nav-pills .nav-link.active {
            background: var(--primary-color) !important;
            color: white !important;
        }
        .search-bar {
            background: transparent;
            border-radius: 50px;
            padding: 8px 20px;
            margin: 0 10px;
            box-shadow: none;
            position: relative;
            transition: all 0.2s ease;
        }
        .search-bar:hover {
            background: #f0f2f5;
        }
        .search-bar:focus-within {
            background: #fff;
            box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.15);
        }
        #searchResults {
            background: white;
            border-radius: 10px;
            overflow: hidden;
            border: 1px solid #eee;
            margin-top: 10px;
        }
        html {
            scroll-behavior: smooth;
        }

        /* Стиль для всплывающих уведомлений (Toasts) */
        .toast-container {
            z-index: 2147483640; /* Выше чем call-interface-layer (2147483000) */
            pointer-events: none; /* Чтобы контейнер не блокировал клики под ним */
        }
        .custom-toast {
            border: none !important;
            border-radius: 12px !important;
            box-shadow: 0 10px 30px rgba(0,0,0,0.15) !important;
            background: rgba(20, 20, 20, 0.95) !important;
            pointer-events: auto; /* Возвращаем клики самим уведомлениям */
        }

        /* РЎС‚РёР»Рё РіР»РѕР±Р°Р»СЊРЅРѕРіРѕ РїР»РµРµСЂР° */
        #global-player-bar {
            transition: opacity 0.2s ease, transform 0.2s ease;
        }
        #global-player-bar .player-shell {
            min-height: 48px;
            width: min(940px, calc(100vw - 24px));
            margin: 0 auto;
            padding: 0 8px;
        }
        @media (min-width: 992px) {
        #global-player-bar.player-mode-header {
            position: static;
            z-index: auto;
            width: 440px;
            min-width: 440px;
            max-width: 440px;
            margin-left: 12px;
            padding: 0 !important;
            border: none;
            border-radius: 0;
            background: transparent;
            backdrop-filter: none;
            box-shadow: none;
            flex: 0 0 440px;
        }
        #global-player-bar.player-mode-header .player-shell {
            width: 100%;
            min-height: 34px;
            max-width: none;
            margin: 0;
            padding: 0;
            display: grid;
            grid-template-columns: auto minmax(0, 1fr) auto auto;
            align-items: center;
            gap: 0.35rem !important;
        }
        #global-player-bar.player-mode-header .player-main-controls {
            display: flex;
            align-items: center;
            gap: 0.08rem;
            flex-shrink: 0;
        }
        #global-player-bar.player-mode-header .player-details {
            margin-right: 0 !important;
            min-width: 0;
            overflow: hidden;
            display: block;
        }
        #global-player-bar.player-mode-header .player-details > .d-flex {
            margin-bottom: 3px !important;
            min-width: 0;
        }
        #global-player-bar.player-mode-header #player-track-title {
            max-width: none !important;
            font-size: 0.69rem;
            font-weight: 700 !important;
            letter-spacing: 0.055em;
            text-transform: uppercase;
            color: #4f61c8;
            line-height: 1.1;
        }
        #global-player-bar.player-mode-header #player-time {
            display: none !important;
        }
        #global-player-bar.player-mode-header #visualizer-container {
            width: 100%;
            height: 7px;
            border-radius: 999px;
            margin-top: 0;
        }
        #global-player-bar.player-mode-header .player-volume-wrap {
            min-width: 82px !important;
            margin-left: 0 !important;
            flex-shrink: 0;
        }
        #global-player-bar.player-mode-header #volume-slider {
            width: 62px;
            height: 14px;
            padding: 0;
            margin: 0;
            appearance: none;
            -webkit-appearance: none;
            background: transparent;
            outline: none;
        }
        #global-player-bar.player-mode-header #volume-slider::-webkit-slider-runnable-track {
            height: 3px;
            border-radius: 999px;
            background: linear-gradient(90deg, #7b90f0 0%, #a6b6f7 100%);
        }
        #global-player-bar.player-mode-header #volume-slider::-webkit-slider-thumb {
            -webkit-appearance: none;
            width: 9px;
            height: 9px;
            border-radius: 50%;
            border: 1px solid #5f74d8;
            background: #ffffff;
            margin-top: -3px;
            box-shadow: 0 0 0 1px rgba(102, 126, 234, 0.08);
        }
        #global-player-bar.player-mode-header #volume-slider::-moz-range-track {
            height: 3px;
            border-radius: 999px;
            border: none;
            background: linear-gradient(90deg, #7b90f0 0%, #a6b6f7 100%);
        }
        #global-player-bar.player-mode-header #volume-slider::-moz-range-thumb {
            width: 9px;
            height: 9px;
            border-radius: 50%;
            border: 1px solid #5f74d8;
            background: #ffffff;
            box-shadow: 0 0 0 1px rgba(102, 126, 234, 0.08);
        }
        #global-player-bar.player-mode-header #volume-slider::-moz-range-progress {
            height: 3px;
            border-radius: 999px;
            background: #667eea;
        }
        #global-player-bar.player-mode-header #volume-icon {
            font-size: 0.95rem !important;
            margin-right: 0.35rem !important;
        }
        #global-player-bar.player-mode-header .player-control-btn {
            font-size: 1.15rem;
            width: 26px;
            height: 26px;
            padding: 0;
            border-radius: 7px;
        }
        #global-player-bar.player-mode-header #master-play-btn {
            width: 26px !important;
            height: 26px !important;
            border: none !important;
            border-radius: 7px !important;
            background: transparent !important;
            box-shadow: none !important;
            color: #667eea !important;
            padding: 0 !important;
            display: inline-flex;
            align-items: center;
            justify-content: center;
        }
        #global-player-bar.player-mode-header #master-play-icon {
            font-size: 1.15rem !important;
            line-height: 1;
        }
        #global-player-bar.player-mode-header #master-play-btn:hover,
        #global-player-bar.player-mode-header .player-control-btn:hover {
            background: #f3f5ff;
            color: #5262c8;
            transform: none;
        }
        #global-player-bar.player-mode-header #master-play-btn:focus-visible,
        #global-player-bar.player-mode-header .player-control-btn:focus-visible {
            outline: 2px solid rgba(102, 126, 234, 0.35);
            outline-offset: 1px;
        }
        #global-player-bar.player-mode-header .player-extra-btn {
            width: 26px;
            height: 26px;
            border: none;
            background: transparent;
            box-shadow: none;
            border-radius: 7px;
        }
        #global-player-bar.player-mode-header .player-extra-controls {
            margin-left: 0 !important;
            flex-shrink: 0;
            position: relative;
            z-index: 2;
        }
        }
        #global-player-bar.player-mode-header .player-extra-btn:hover {
            background: #f3f5ff;
            border-color: transparent;
        }
        #global-player-bar.player-mode-bottom {
            position: fixed;
            z-index: 1048;
            left: 0;
            right: 0;
            bottom: 0;
            width: 100%;
            background: rgba(255, 255, 255, 0.97);
            border-left: none;
            border-right: none;
            border-bottom: none;
            border-top: 1px solid #e8ebf5;
            border-radius: 0;
            backdrop-filter: blur(8px);
            box-shadow: 0 -12px 30px rgba(37, 48, 106, 0.14);
            padding: 8px 0 !important;
        }
        /* Mobile: Move player above bottom navbar to prevent overlap */
        @media (max-width: 991px) {
            #global-player-bar.player-mode-bottom {
                bottom: calc(60px + env(safe-area-inset-bottom)) !important;
                border-bottom: 1px solid #e8ebf5;
            }
        }
        #global-player-bar.player-mode-bottom .player-shell {
            max-width: 940px;
        }
        #global-player-bar.player-mode-bottom #master-play-btn {
            width: 40px;
            height: 40px;
            border: none;
            border-radius: 50%;
            background: #667eea;
            color: #fff;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            box-shadow: 0 6px 14px rgba(102, 126, 234, 0.3);
        }
        #global-player-bar.player-mode-bottom #master-play-icon {
            font-size: 1.2rem;
            line-height: 1;
        }
        #global-player-bar .player-extra-btn {
            width: 32px;
            height: 32px;
            border: 1px solid #dfe3ef;
            border-radius: 10px;
            color: #667eea;
            background: #fff;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            transition: 0.2s ease;
        }
        #global-player-bar .player-extra-btn:hover {
            background: #f3f5ff;
            border-color: #667eea;
        }
        #global-player-bar .player-extra-btn i {
            font-size: 1rem;
            line-height: 1;
        }
        #global-player-bar.player-compact {
            padding: 8px 0 !important;
        }
        #global-player-bar.player-compact #visualizer-container,
        #global-player-bar.player-compact .player-volume-wrap {
            display: none !important;
        }
        #global-player-bar.player-compact #player-time {
            display: none !important;
        }
        #global-player-bar.player-compact .player-shell {
            min-height: 44px;
        }
        body.player-compact-mode {
            padding-bottom: 56px !important;
        }
        @media (max-width: 991px) {
            body.music-player-docked {
                padding-bottom: calc(86px + 65px + env(safe-area-inset-bottom)) !important;
            }
        }

        /* РљРћРќРўР•Р™РќР•Р  Р”Р›РЇ Р’РћР›РќР« Р˜ РџР РћР“Р Р•РЎРЎРђ */
        #visualizer-container {
            position: relative;
            height: 30px;
            cursor: pointer;
            width: 100%;
            background: rgba(0, 0, 0, 0.02);
            border-radius: 8px;
            overflow: hidden;
        }
        
        #waveform-canvas {
            width: 100%;
            height: 100%;
            display: block;
        }

        .player-control-btn {
            background: none;
            border: none;
            color: #667eea;
            font-size: 1.7rem;
            transition: 0.2s;
            display: flex;
            align-items: center;
            justify-content: center;
        }
        .player-control-btn:hover {
            color: #764ba2;
            transform: scale(1.1);
        }

        #volume-slider {
            width: 80px;
            height: 5px;
            cursor: pointer;
        }
        .player-queue-title {
            max-width: 100%;
        }
        .player-queue-panel {
            position: fixed;
            background: rgba(255, 255, 255, 0.98);
            z-index: 1060;
        }
        
        @media (min-width: 992px) {
            .player-queue-panel {
                top: calc(var(--site-header-height) + 52px);
                left: 12px;
                width: min(360px, calc(100vw - 24px));
                border: 1px solid #dfe3ef;
                border-radius: 14px;
                box-shadow: 0 18px 42px rgba(37, 48, 106, 0.24);
                backdrop-filter: blur(10px);
                opacity: 0;
                transform: translateY(10px) scale(0.98);
                pointer-events: none;
                transition: opacity 0.18s ease, transform 0.18s ease;
            }
            .player-queue-panel.open {
                opacity: 1;
                transform: translateY(0) scale(1);
                pointer-events: auto;
            }
        }
        .player-queue-panel-head {
            display: flex;
            align-items: center;
            justify-content: space-between;
            padding: 10px 12px;
            border-bottom: 1px solid #eef1f8;
            background: linear-gradient(180deg, rgba(248, 250, 255, 0.92) 0%, rgba(255, 255, 255, 0.9) 100%);
        }
        .player-queue-panel-title {
            font-size: 0.86rem;
            font-weight: 700;
            color: #5262c8;
            letter-spacing: 0.03em;
            text-transform: uppercase;
        }
        .player-queue-meta {
            margin-top: 2px;
            font-size: 0.73rem;
            color: #8790ae;
            font-weight: 600;
            letter-spacing: 0.015em;
        }
        .player-queue-head-actions {
            display: flex;
            align-items: center;
            gap: 0.35rem;
        }
        .player-queue-head-btn {
            width: 28px;
            height: 28px;
            border: 1px solid #dfe3ef;
            border-radius: 8px;
            background: #fff;
            color: #667eea;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            transition: 0.18s ease;
        }
        .player-queue-head-btn:hover:not(:disabled) {
            border-color: #667eea;
            background: #f3f5ff;
        }
        .player-queue-head-btn:disabled {
            opacity: 0.45;
            cursor: not-allowed;
        }
        .player-queue-close {
            width: 28px;
            height: 28px;
            border: 1px solid #dfe3ef;
            border-radius: 8px;
            background: #fff;
            color: #667eea;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            transition: 0.18s ease;
        }
        .player-queue-close:hover {
            border-color: #667eea;
            background: #f3f5ff;
        }
        .player-queue-panel-body {
            max-height: 300px;
            overflow-y: auto;
        }
        .player-queue-panel .list-group-item {
            border-left: 0;
            border-right: 0;
            border-color: #f1f3fb;
            padding: 0.5rem 0.62rem;
        }
        .player-queue-panel .list-group-item:first-child {
            border-top: 0;
        }
        .player-queue-item.active {
            background: linear-gradient(90deg, rgba(102, 126, 234, 0.12) 0%, rgba(102, 126, 234, 0.05) 100%) !important;
            border-color: #dce3ff !important;
        }
        .player-queue-item-main {
            border: none;
            background: transparent;
            width: 100%;
            padding: 0;
            text-align: left;
            display: flex;
            align-items: center;
            gap: 0.55rem;
            min-width: 0;
        }
        .player-queue-item-main:hover .player-queue-title {
            color: #4f61c8;
        }
        .player-queue-order {
            min-width: 1.4rem;
            text-align: right;
            font-size: 0.72rem;
            color: #98a1be;
            font-weight: 700;
            letter-spacing: 0.02em;
        }
        .player-queue-text {
            min-width: 0;
            flex: 1 1 auto;
        }
        .player-queue-title {
            display: block;
            font-size: 0.84rem;
            font-weight: 600;
            color: #3f4a71;
            line-height: 1.2;
            transition: color 0.15s ease;
        }
        .player-queue-subtitle {
            display: block;
            font-size: 0.68rem;
            color: #96a0bb;
            text-transform: uppercase;
            letter-spacing: 0.06em;
            margin-top: 2px;
        }
        .player-queue-pill {
            padding: 0.16rem 0.4rem;
            border-radius: 999px;
            font-size: 0.63rem;
            font-weight: 700;
            letter-spacing: 0.03em;
            color: #5164cf;
            background: #e9eeff;
            text-transform: uppercase;
        }
        .player-queue-remove {
            width: 24px;
            height: 24px;
            border: none;
            border-radius: 7px;
            background: transparent;
            color: #a0aac6;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            flex-shrink: 0;
            transition: 0.18s ease;
        }
        .player-queue-remove:hover {
            color: #dc5a70;
            background: #ffeef1;
        }
        .player-queue-empty {
            color: #8e97b5;
            text-align: center;
            font-weight: 600;
            letter-spacing: 0.02em;
        }
        .player-queue-empty-subtitle {
            margin-top: 0.25rem;
            margin-bottom: 0.65rem;
            color: #9ba4bf;
            font-weight: 500;
            font-size: 0.78rem;
            letter-spacing: 0.01em;
        }
        .player-queue-empty-cta {
            border: 1px solid #d8e0ff;
            background: #f7f9ff;
            color: #5164cf;
            border-radius: 10px;
            font-size: 0.76rem;
            font-weight: 700;
            letter-spacing: 0.02em;
            padding: 0.34rem 0.6rem;
            transition: 0.18s ease;
        }
        .player-queue-empty-cta:hover {
            background: #edf1ff;
            border-color: #c8d3ff;
            color: #4157cc;
        }

        @media (max-width: 992px) {
            :root {
                --site-header-height: 66px;
            }
            #global-player-bar.player-mode-header {
                width: 250px;
                min-width: 250px;
                max-width: 250px;
                margin-left: 8px;
                flex: 0 0 250px;
            }
            #global-player-bar .player-shell {
                gap: 0.5rem !important;
            }
            #global-player-bar .player-volume-wrap {
                min-width: 100px !important;
            }
            #player-track-title {
                max-width: 170px !important;
            }
        }

        /* --- SIYA Р¤РЈРќРљР¦Р˜РЇ --- */
        @keyframes kiya-glow {
            0% { background-position: 0% 50%; box-shadow: 0 0 5px rgba(40, 167, 69, 0.2); }
            50% { background-position: 100% 50%; box-shadow: 0 0 20px rgba(40, 167, 69, 0.6); }
            100% { background-position: 0% 50%; box-shadow: 0 0 5px rgba(40, 167, 69, 0.2); }
        }

        .track-item.playing-now {
            background: linear-gradient(-45deg, #ffffff, #f0fff0, #d7ffd9, #ffffff) !important;
            background-size: 400% 400% !important;
            animation: kiya-glow 3s ease infinite !important;
            border: 1px solid #28a745 !important;
            transition: 0.3s;
            transform: translateY(-2px);
        }

        /* Navbar alignment */
        @media (min-width: 1200px) {
            .app-navbar .container-fluid {
                padding-left: 30px;
                padding-right: 30px;
            }
        }
        
        /* Fix mobile header layout (prevent column stacking) */
        @media (max-width: 991px) {
            .app-navbar .container-fluid {
                flex-wrap: nowrap; /* Запрещаем перенос лого и бургера */
                gap: 10px;
            }
        }

        /* Bottom Navigation for Mobile */
        .bottom-navbar {
            position: fixed;
            bottom: 0;
            left: 0;
            right: 0;
            background: white;
            border-top: 1px solid #eee;
            display: flex;
            justify-content: space-around;
            align-items: center;
            height: calc(60px + env(safe-area-inset-bottom)); /* Учитываем зону жестов iPhone */
            z-index: 1030;
            padding-bottom: env(safe-area-inset-bottom);
            box-shadow: 0 -2px 10px rgba(0,0,0,0.03);
        }
        .bottom-navbar .nav-item {
            color: #999;
            font-size: 1.6rem;
            padding: 10px;
            position: relative;
            display: flex;
            align-items: center;
            justify-content: center;
        }
        .bottom-navbar .nav-item.active {
            color: #667eea;
        }
        
        @media (max-width: 991px) {
            body {
                padding-top: 70px; /* Space for mobile top bar */
                padding-bottom: 70px; /* Space for bottom nav */
            }
            .app-navbar {
                display: none !important;
            }
            /* Оптимизация производительности для мобильных (убираем тяжелые эффекты) */
            .custom-toast, #global-player-bar.player-mode-bottom, .player-queue-panel {
                backdrop-filter: none !important;
                -webkit-backdrop-filter: none !important;
                background: rgba(255, 255, 255, 0.98) !important;
            }
            .custom-toast {
                background: rgba(33, 37, 41, 0.95) !important;
            }
            
            /* Fix Notifications Dropdown on Mobile */
            .bottom-navbar .dropdown-menu {
                position: fixed !important;
                bottom: 80px !important;
                top: auto !important;
                left: 50% !important;
                transform: translateX(-50%) !important;
                width: 90% !important;
                max-width: 350px !important;
                margin: 0 !important;
                z-index: 1050 !important;
            }
            
            /* Mobile Player Queue Panel */
            .player-queue-panel {
                top: auto !important;
                bottom: 80px !important;
                left: 50% !important;
                transform: translateX(-50%) translateY(10px) scale(0.95) !important;
                width: 95% !important;
            }
            .player-queue-panel.open {
                transform: translateX(-50%) translateY(0) scale(1) !important;
            }
        }
        
        /* --- MOBILE PLAYER STYLES --- */
        @keyframes purpleShimmer {
            0% { background-position: 0% 50%; }
            50% { background-position: 100% 50%; }
            100% { background-position: 0% 50%; }
        }

        @media (max-width: 991px) {
            /* Mini Player (Global Bar transformation) */
            #global-player-bar, #global-player-bar.player-mode-bottom {
                position: fixed;
                bottom: calc(60px + env(safe-area-inset-bottom)) !important;
                left: 10px;
                right: 10px;
                width: auto !important;
                max-width: none !important;
                height: 56px;
                background: linear-gradient(270deg, #8ea2ff, #aebbf7, #8ea2ff) !important;
                background-size: 200% 200%;
                animation: purpleShimmer 3s ease infinite;
                border-radius: 12px;
                z-index: 1040;
                padding: 0 15px !important;
                box-shadow: 0 5px 15px rgba(118, 75, 162, 0.3);
                color: white;
                cursor: pointer;
                margin: 0 !important;
                flex: none !important;
                border: none !important;
            }
            
            /* Hide desktop specific elements in mini player */
            #global-player-bar .player-volume-wrap,
            #global-player-bar.player-mode-bottom .player-volume-wrap,
            #global-player-bar .player-extra-controls,
            #global-player-bar.player-mode-bottom .player-extra-controls,
            #global-player-bar #visualizer-container,
            #global-player-bar.player-mode-bottom #visualizer-container,
            #global-player-bar #player-time,
            #global-player-bar.player-mode-bottom #player-time,
            #global-player-bar .player-main-controls button:not(#master-play-btn),
            #global-player-bar.player-mode-bottom .player-main-controls button:not(#master-play-btn) {
                display: none !important;
            }

            #global-player-bar .player-details, #global-player-bar.player-mode-bottom .player-details {
                margin-right: auto !important;
            }

            #global-player-bar #player-track-title, #global-player-bar.player-mode-bottom #player-track-title {
                color: white !important;
                font-size: 0.95rem !important;
                max-width: 220px !important;
            }

            #global-player-bar #master-play-btn, #global-player-bar.player-mode-bottom #master-play-btn {
                color: white !important;
                background: rgba(255,255,255,0.2) !important;
                width: 36px !important;
                height: 36px !important;
                margin-left: 10px;
                box-shadow: none !important;
                border-radius: 7px !important;
            }
            
            /* Full Screen Player Styles */
            #mobile-full-player {
                position: fixed;
                top: 100%;
                left: 0;
                width: 100%;
                height: 100%;
                background: white;
                z-index: 10000;
                transition: top 0.3s cubic-bezier(0.4, 0, 0.2, 1);
                display: flex;
                flex-direction: column;
                padding: 20px;
                padding-top: calc(20px + env(safe-area-inset-top));
                padding-bottom: calc(20px + env(safe-area-inset-bottom));
                overflow-y: auto;
            }
            
            /* Mobile Queue Page */
            .player-queue-panel {
                position: fixed !important;
                top: 0 !important;
                left: 0 !important;
                right: 0 !important;
                bottom: 0 !important;
                width: 100% !important;
                height: 100% !important;
                transform: translateY(100%) !important;
                border-radius: 0 !important;
                border: none !important;
                z-index: 11000 !important;
                display: flex;
                flex-direction: column;
                transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1) !important;
                opacity: 1 !important;
                background: #fff !important;
            }
            .player-queue-panel.open {
                transform: translateY(0) !important;
            }
            .player-queue-panel-head {
                padding: 20px 15px !important;
                background: #fff !important;
                border-bottom: 1px solid #f0f0f0 !important;
            }
            .player-queue-panel-title { font-size: 1.2rem !important; color: #333 !important; }
            .player-queue-panel-body {
                max-height: none !important;
                flex: 1;
                overflow-y: auto;
                width: 100%;
            }
        }

        /* Sidebar Layout Barrier */
        @media (min-width: 1200px) {
            body {
                padding-left: 300px; /* 30px слева + 240px ширина + 30px справа */
                padding-right: 300px; /* Балансировка для центрирования контента */
                transition: padding 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
            }
            body.sidebar-collapsed-mode {
                padding-left: 140px;
                padding-right: 30px;
            }
            /* Чтобы контейнер не вылезал за пределы экрана из-за отступа */
            .container {
                max-width: 100%;
            }
        }

        /* Left Sidebar Navigation */
        .left-sidebar-nav {
            position: fixed;
            left: 30px;
            top: calc(var(--site-header-height) + 30px);
            z-index: 900;
            width: 240px;
            background: var(--sidebar-bg);
            border-radius: 24px;
            padding: 20px 12px;
            box-shadow: 0 10px 40px rgba(0,0,0,0.04);
            display: flex;
            flex-direction: column;
            gap: 5px;
            transition: width 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
        }

        .left-sidebar-nav.collapsed {
            width: 80px;
        }

        .left-sidebar-nav.collapsed .sidebar-nav-btn {
            justify-content: center;
            padding: 14px 0;
        }

        .left-sidebar-nav.collapsed .sidebar-nav-btn span {
            display: none;
        }

        .left-sidebar-nav.collapsed .sidebar-nav-btn i {
            margin-right: 0;
            font-size: 1.5rem;
        }

        .sidebar-nav-btn {
            display: flex;
            align-items: center;
            padding: 14px 20px;
            border-radius: 16px;
            text-decoration: none;
            color: #6c757d;
            font-weight: 600;
            font-size: 1.05rem;
            transition: all 0.2s ease;
            border: none;
            background: transparent;
            margin-bottom: 0;
            box-shadow: none;
            white-space: nowrap;
            overflow: hidden;
        }

        .sidebar-nav-btn:hover {
            background: #f8f9fa;
            color: var(--primary-color);
            transform: translateX(5px);
        }

        .sidebar-nav-btn.active {
            background: #eef2ff;
            color: var(--primary-color);
            font-weight: 700;
        }

        .sidebar-nav-btn i {
            font-size: 1.4rem;
            margin-right: 16px;
            width: 36px;
            height: 36px;
            display: flex;
            align-items: center;
            justify-content: center;
            border-radius: 10px;
            transition: all 0.3s ease;
            background: rgba(108, 117, 125, 0.05);
        }

        .sidebar-nav-btn:hover i {
            transform: scale(1.05);
            background: rgba(102, 126, 234, 0.15);
            color: var(--primary-color);
        }
        
        .sidebar-nav-btn.active i {
            background: var(--primary-gradient);
            color: white;
            box-shadow: 0 4px 10px rgba(102, 126, 234, 0.3);
        }

        /* Verified Badge Global Style */
        .verified-badge {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            vertical-align: middle;
            margin-left: 2px;
        }
        .verified-badge svg {
            width: 0.9em;
            height: 0.9em;
        }

        /* Notification styles */
        .notification-item.notification-unread {
            background-color: #f0f5ff;
        }
        .notification-item a {
            white-space: normal;
        }
        .dropdown-menu#notifications-dropdown-menu {
            padding-top: 0;
            padding-bottom: 0;
        }

        /* Custom Cursor Tooltip */
        .custom-cursor-tooltip {
            position: fixed;
            background: rgba(0, 0, 0, 0.9);
            color: #fff;
            padding: 6px 12px;
            border-radius: 8px;
            font-size: 0.8rem;
            pointer-events: none;
            z-index: 10000;
            display: none;
            white-space: nowrap;
            box-shadow: 0 4px 12px rgba(0,0,0,0.15);
            border: 1px solid rgba(255,255,255,0.1);
            font-weight: 500;
        }

        /* Image Nav Arrows (Global) */
        .nav-arrow { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(0,0,0,0.3); color: white; border: none; padding: 15px; border-radius: 50%; z-index: 100; backdrop-filter: blur(4px); transition: 0.3s; }
        .nav-arrow:hover { background: rgba(255,255,255,0.2); }
        .left-arrow { left: 20px; }
        .right-arrow { right: 20px; }
        @media (max-width: 768px) { .nav-arrow { padding: 10px; font-size: 1rem; } }

        /* Global Enhanced Track Progress Bar */
        .track-inline-progress {
            position: relative;
            height: 16px;
            display: flex;
            align-items: center;
            margin-top: 6px;
            cursor: pointer;
        }
        .track-rail {
            width: 100%;
            height: 4px;
            border-radius: 10px;
            background: rgba(102, 126, 234, 0.15);
            overflow: hidden;
            position: absolute;
            left: 0;
            top: 50%;
            transform: translateY(-50%);
            pointer-events: none;
        }
        .track-inline-progress-fill {
            display: block;
            width: 100%;
            height: 100%;
            border-radius: 10px;
            background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
            transform-origin: left center;
            transform: scaleX(0);
            transition: transform 0.1s linear;
        }
        .track-seek-range {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            opacity: 0; /* Hidden by default, visible on hover/active via CSS below */
            cursor: pointer;
            margin: 0;
            z-index: 5;
            -webkit-appearance: none;
            background: transparent;
            transition: opacity 0.2s;
        }
        /* Show thumb on hover or when active */
        .track-inline-progress:hover .track-seek-range,
        .track-seek-range:active {
            opacity: 1;
        }
        .track-seek-range::-webkit-slider-runnable-track {
            background: transparent;
            height: 100%;
        }
        .track-seek-range::-webkit-slider-thumb {
            -webkit-appearance: none;
            height: 12px;
            width: 12px;
            border-radius: 50%;
            background: #fff;
            box-shadow: 0 1px 4px rgba(0,0,0,0.3);
            margin-top: 2px; /* Center vertically: (16px - 12px)/2 */
            cursor: pointer;
            border: 1px solid #f0f0f0;
            transition: transform 0.1s;
        }
        .track-seek-range:active::-webkit-slider-thumb {
            transform: scale(1.2);
            background: #f8f9fa;
        }

        /* Call Interface Styles */
        #call-interface-layer {
            position: fixed;
            inset: 0;
            z-index: 2147483000;
            font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
            display: flex;
            align-items: center;
            justify-content: center;
            pointer-events: none;
            isolation: isolate;
        }
        #active-call-ui {
            pointer-events: auto;
        }
        #incoming-call-ui {
            pointer-events: none;
            align-items: center;
            justify-content: center;
            padding: 16px;
            background: transparent !important;
        }
        #incoming-call-ui .wa-overlay-bg {
            display: none !important;
        }
        #incoming-call-ui .wa-incoming-content {
            pointer-events: none;
            width: 100%;
            align-items: center;
            justify-content: center;
            padding: 0;
        }
        #incoming-call-ui .wa-window-shell {
            pointer-events: auto;
            width: min(390px, calc(100vw - 24px));
        }
        body.call-overlay-modal-open .modal-backdrop {
            z-index: 2147483605 !important;
        }
        body.call-overlay-modal-open #callParticipantModal,
        body.call-overlay-modal-open #callMembersModal {
            z-index: 2147483610 !important;
        }
        .wa-call-screen {
            position: absolute;
            inset: 0;
            display: flex;
            flex-direction: column;
            overflow: hidden;
            background: var(--card-bg);
            contain: layout paint;
            overscroll-behavior: none;
        }
        @media (min-width: 992px) {
            .wa-fullscreen-video {
                width: auto !important;
                max-height: 85vh !important;
                max-width: 95vw;
                position: absolute;
                top: 42%;
                left: 50%;
                transform: translate(-50%, -50%);
                border-radius: 24px;
                box-shadow: 0 30px 60px rgba(0,0,0,0.3);
                object-fit: cover;
            }
        }
        .wa-overlay-bg {
            position: absolute;
            inset: 0;
            background-size: cover;
            background-position: center;
            filter: blur(26px) brightness(0.5) saturate(0.9);
            transform: scale(1.12);
            z-index: 1;
        }
        .wa-incoming-content {
            position: relative;
            z-index: 2;
            flex: 1;
            display: flex;
            flex-direction: column;
            justify-content: center;
            align-items: center;
            padding: max(68px, env(safe-area-inset-top)) 20px 120px;
            color: #f2f3f5;
        }
        .wa-window-shell {
            width: min(430px, calc(100vw - 30px));
            border-radius: 16px;
            border: 1px solid rgba(160, 184, 220, 0.55);
            background: linear-gradient(180deg, rgba(255, 255, 255, 0.95) 0%, rgba(246, 250, 255, 0.97) 100%);
            box-shadow: 0 20px 44px rgba(64, 94, 148, 0.2);
            overflow: hidden;
        }
        #incoming-call-ui .wa-window-shell {
            background: linear-gradient(120deg, #ffffff 0%, #edf4ff 25%, #e8fff6 52%, #eef2ff 76%, #ffffff 100%);
            background-size: 280% 280%;
            animation: waIncomingCardShimmer 6s ease-in-out infinite;
        }
        .wa-window-header {
            display: none;
            align-items: center;
            justify-content: space-between;
            gap: 10px;
            height: 44px;
            padding: 0 14px;
            border-bottom: 1px solid rgba(96, 103, 136, 0.42);
            background: linear-gradient(180deg, rgba(56, 60, 89, 0.95) 0%, rgba(49, 54, 81, 0.95) 100%);
        }
        .wa-window-dots {
            display: inline-flex;
            gap: 6px;
        }
        .wa-window-dot {
            width: 8px;
            height: 8px;
            border-radius: 50%;
            display: inline-block;
            background: rgba(168, 175, 207, 0.68);
        }
        .wa-window-dot.wa-dot-red { background: #ed4245; }
        .wa-window-dot.wa-dot-yellow { background: #faa81a; }
        .wa-window-dot.wa-dot-green { background: #3ba55d; }
        .wa-window-title {
            margin: 0;
            font-size: 0.76rem;
            letter-spacing: 0.08em;
            text-transform: uppercase;
            color: #c7ccf1;
            font-weight: 700;
        }
        .wa-window-body {
            padding: 24px 20px 18px;
        }
        .wa-window-footer {
            border-top: 1px solid rgba(187, 206, 235, 0.55);
            background: rgba(242, 248, 255, 0.86);
            padding: 14px 16px;
        }
        .wa-contact-info {
            display: flex;
            flex-direction: column;
            align-items: center;
            text-align: center;
            gap: 6px;
        }
        .wa-contact-info h2 {
            margin-top: 14px;
            margin-bottom: 2px;
            font-weight: 700;
            letter-spacing: 0.012em;
            color: #1d3557;
        }
        .wa-avatar-wrap,
        .wa-avatar-wrap-lg {
            position: relative;
            width: 104px;
            height: 104px;
        }
        .wa-avatar-wrap-lg {
            width: 92px;
            height: 92px;
            margin-bottom: 15px;
        }
        .wa-avatar,
        .wa-avatar-large {
            width: 100%;
            height: 100%;
            border-radius: 50%;
            object-fit: cover;
            border: 2px solid rgba(255,255,255,0.35);
            box-shadow: 0 16px 40px rgba(7, 10, 26, 0.42);
            background: rgba(255,255,255,0.08);
        }
        .wa-avatar-fallback,
        .wa-mini-avatar-fallback {
            position: absolute;
            inset: 0;
            border-radius: 50%;
            display: none;
            align-items: center;
            justify-content: center;
            font-size: 2rem;
            background: linear-gradient(145deg, rgba(255,255,255,0.28), rgba(255,255,255,0.12));
            border: 2px solid rgba(255,255,255,0.36);
            box-shadow: 0 16px 36px rgba(0,0,0,0.28);
        }
        .wa-avatar-fallback.wa-avatar-fallback-lg {
            font-size: 1.8rem;
        }
        .wa-subtext {
            color: #59779e;
            font-size: 0.93rem;
        }
        .wa-incoming-actions {
            display: flex;
            width: 100%;
            justify-content: center;
            max-width: none;
            gap: 40px;
        }
        .wa-action-col {
            display: flex;
            flex-direction: column;
            align-items: center;
            color: #38597c;
            text-shadow: none;
        }
        .wa-btn-decline,
        .wa-btn-accept {
            width: 64px;
            height: 64px;
            border-radius: 50%;
            border: none;
            color: white;
            font-size: 1.45rem;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            box-shadow: 0 10px 30px rgba(0,0,0,0.3);
        }
        .wa-btn-decline {
            background: linear-gradient(145deg, #ff5a62 0%, #e93442 100%);
            animation: shake 1.3s infinite;
        }
        .wa-btn-accept {
            background: linear-gradient(145deg, #25d366 0%, #1faa58 100%);
            animation: pulse-accept 1.6s infinite;
        }
        .wa-fullscreen-video {
            width: 100%;
            height: 100%;
            object-fit: contain !important;
            background: #0f1722;
            transition: object-fit 0.18s ease;
        }
        .wa-remote-grid {
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 96px;
            display: none;
            grid-template-columns: repeat(1, minmax(0, 1fr));
            grid-template-columns: 1fr;
            gap: 10px;
            padding: 12px;
            z-index: 15;
            grid-auto-rows: minmax(0, 1fr);
            align-content: stretch;
            overflow-y: auto;
            overscroll-behavior: contain;
        }
        .wa-remote-grid.is-visible {
            display: grid;
        }
        /* Discord-like Layouts */
        @media (min-width: 768px) {
            .wa-remote-grid.items-2 {
                grid-template-columns: 1fr 1fr;
                grid-template-rows: 1fr;
            }
            .wa-remote-grid.items-3 {
                grid-template-columns: repeat(3, 1fr);
                grid-template-rows: 1fr;
            }
            .wa-remote-grid.items-4 {
                grid-template-columns: 1fr 1fr;
                grid-template-rows: 1fr 1fr;
            }
            .wa-remote-grid.items-5, .wa-remote-grid.items-6 {
                grid-template-columns: repeat(3, 1fr);
            }
        }
        .wa-remote-grid:not(:empty) {
            display: grid !important;
        }
        .wa-remote-grid:empty {
            display: none !important;
        }
        .wa-remote-grid.mode-single {
            grid-template-columns: 1fr;
            grid-template-rows: 1fr;
            overflow-y: hidden;
        }
        .wa-remote-grid.mode-split-2 {
            grid-template-columns: repeat(2, minmax(0, 1fr));
        }
        .wa-remote-grid.mode-grid-3 {
            grid-template-columns: repeat(2, minmax(0, 1fr));
        }
        .wa-remote-grid.mode-grid-3 .wa-remote-tile:nth-child(3) {
            grid-column: 1 / span 2;
            justify-self: center;
            width: min(52%, 520px);
        }
        .wa-remote-grid.mode-grid-4 {
            grid-template-columns: repeat(2, minmax(0, 1fr));
        }
        .wa-remote-grid.mode-grid-many {
            grid-template-columns: repeat(3, minmax(0, 1fr));
        }
        .wa-remote-grid.mode-avatars {
            grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
        }
        .wa-remote-grid.mode-focus {
            grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
            gap: 10px;
        }
        .wa-remote-grid.mode-focus .wa-grid-item.is-main,
        .wa-remote-grid.mode-focus .wa-remote-tile.is-main {
            grid-column: 1 / -1 !important;
            width: 100%;
        }
        .wa-remote-grid.cols-2 {
            grid-template-columns: repeat(2, minmax(0, 1fr));
        }
        .wa-remote-grid.cols-3 {
            grid-template-columns: repeat(3, minmax(0, 1fr));
        }
        .wa-remote-tile {
            position: relative;
            overflow: hidden;
            border-radius: 14px;
            background: #0f1722;
            min-height: 0;
            border: 1px solid rgba(149, 171, 209, 0.28);
            box-shadow: 0 10px 24px rgba(24, 44, 75, 0.24);
            transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
            cursor: pointer;
        }
        .wa-remote-tile.is-main {
            min-height: 0;
        }
        .wa-remote-grid.mode-focus .wa-remote-tile.is-main {
            grid-row: 1 / span 20;
            min-height: 0;
        }
        .wa-remote-grid.mode-focus .wa-remote-tile.is-thumbnail {
            min-height: 0;
        }
        .wa-remote-tile.is-speaking {
            border-color: rgba(168, 85, 247, 0.8);
            box-shadow: 0 0 0 2px rgba(168, 85, 247, 0.4), 0 14px 30px rgba(24, 44, 75, 0.28);
        }
        .wa-remote-tile:hover {
            transform: translateY(-1px);
        }
        .wa-remote-tile.is-local {
            border-style: dashed;
            border-color: rgba(168, 187, 226, 0.7);
        }
        .wa-remote-tile video {
            width: 100%;
            height: 100%;
            object-fit: contain;
            background: #0f1722;
        }
        .wa-remote-tile-head {
            position: absolute;
            left: 10px;
            right: 10px;
            bottom: 10px;
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 8px;
            padding: 6px 10px;
            border-radius: 999px;
            background: rgba(8, 15, 24, 0.58);
            color: #f5f8ff;
            font-size: 0.78rem;
            z-index: 2;
        }
        .wa-call-picker-call-btn {
            width: 34px;
            height: 34px;
            border-radius: 50%;
            border: 1px solid rgba(73, 115, 186, 0.28);
            background: rgba(235, 244, 255, 0.95);
            color: #2c4c82;
            display: inline-flex;
            align-items: center;
            justify-content: center;
        }
        .wa-call-picker-call-btn:disabled {
            opacity: 0.46;
            cursor: not-allowed;
        }
        .wa-call-picker-status {
            font-size: 0.72rem;
            padding: 0.2rem 0.48rem;
            border-radius: 999px;
            background: #eef2fa;
            color: #4f617f;
        }
        .wa-call-picker-status.is-calling {
            color: #1f6f42;
            background: rgba(37, 211, 102, 0.18);
            animation: waCallPulse 1.5s ease-in-out infinite;
        }
        .wa-participants-btn {
            position: relative;
            display: inline-flex;
            align-items: center;
            justify-content: center;
        }
        .wa-participants-count {
            position: absolute;
            top: -7px;
            right: -5px;
            min-width: 18px;
            height: 18px;
            border-radius: 999px;
            background: #2f7ef8;
            color: #fff;
            font-size: 0.68rem;
            font-weight: 700;
            line-height: 18px;
            text-align: center;
            padding: 0 4px;
        }
        .wa-member-row {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 10px;
            padding: 10px 4px;
            border-bottom: 1px solid rgba(173, 191, 227, 0.25);
        }
        .wa-member-row:last-child {
            border-bottom: 0;
        }
        .wa-member-meta {
            display: flex;
            align-items: center;
            gap: 10px;
            min-width: 0;
        }
        .wa-member-actions {
            display: inline-flex;
            align-items: center;
            gap: 6px;
        }
        .wa-member-action-btn {
            width: 32px;
            height: 32px;
            border-radius: 50%;
            border: 1px solid rgba(124, 146, 188, 0.36);
            background: #f6f9ff;
            color: #2b3f66;
            display: inline-flex;
            align-items: center;
            justify-content: center;
        }
        .wa-member-action-btn.wa-danger {
            border-color: rgba(224, 70, 86, 0.35);
            color: #b32233;
            background: #fff4f6;
        }
        @keyframes waCallPulse {
            0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.34); }
            70% { box-shadow: 0 0 0 11px rgba(37, 211, 102, 0); }
            100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
        }
        .wa-remote-tile-name {
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            font-weight: 600;
        }
        .wa-remote-tile-status {
            font-size: 0.72rem;
            color: #c8d9fb;
        }
        .wa-remote-tile-avatar {
            position: absolute;
            inset: 0;
            display: none;
            align-items: center;
            justify-content: center;
            color: #c8d9fb;
            font-size: 2.1rem;
            background: radial-gradient(circle at 30% 20%, #233a57 0%, #121f2e 100%);
            z-index: 1;
        }
        .wa-remote-tile-avatar img {
            width: 76px;
            height: 76px;
            border-radius: 50%;
            object-fit: cover;
            border: 2px solid rgba(196, 214, 249, 0.75);
        }
        .wa-remote-tile-avatar span {
            font-size: 1.9rem;
            font-weight: 700;
            letter-spacing: 0.01em;
        }
        .wa-remote-tile.avatar-only .wa-remote-tile-avatar {
            display: flex;
        }
        .wa-remote-tile.avatar-only video {
            opacity: 0;
        }
        .wa-remote-grid.mode-focus .wa-remote-tile-head {
            border-radius: 10px;
        }
        .wa-fullscreen-video.wa-screen-share-feed {
            object-fit: contain;
            background: #e9efff;
        }
        /* Side Grid Layout for Expanded Modes */
        @media (min-width: 992px) {
            .wa-screen-share-max .wa-remote-grid,
            .wa-video-expanded .wa-remote-grid {
                top: 16px;
                left: 16px;
                right: auto;
                bottom: 112px;
                width: 240px;
                display: flex !important;
                flex-direction: column;
                gap: 12px;
                padding: 0;
                overflow-y: auto;
                z-index: 20;
                background: transparent;
                pointer-events: none;
                grid-template-columns: 1fr !important;
                grid-auto-rows: auto !important;
            }
            .wa-screen-share-max .wa-remote-grid .wa-remote-tile,
            .wa-video-expanded .wa-remote-grid .wa-remote-tile {
                width: 100%;
                height: 135px;
                min-height: 135px;
                flex-shrink: 0;
                pointer-events: auto;
                box-shadow: 0 4px 12px rgba(0,0,0,0.2);
            }
            .wa-screen-share-max .wa-fullscreen-video.wa-screen-share-feed,
            .wa-video-expanded .wa-fullscreen-video {
                width: calc(100% - 272px) !important;
                left: auto !important;
                right: 16px !important;
                top: 50% !important;
                transform: translateY(-50%) !important;
                height: calc(100% - 120px) !important;
                border-radius: 16px !important;
            }
            .wa-screen-share-max .wa-remote-grid:not(:empty),
            .wa-video-expanded .wa-remote-grid:not(:empty) {
                display: flex !important;
            }
        }
        @media (min-width: 992px) {
            .wa-call-screen .wa-remote-grid.mode-focus {
                display: block !important;
            }
            .wa-remote-grid.mode-focus .wa-remote-tile.is-main {
                float: left;
                width: calc(100% - 256px) !important;
                height: calc(100vh - 140px) !important;
                position: sticky !important;
                top: 0 !important;
                z-index: 5;
            }
            .wa-remote-grid.mode-focus .wa-remote-tile:not(.is-main) {
                float: right;
                width: 240px !important;
                height: 135px !important;
                margin-bottom: 12px;
                clear: right;
            }
        }
        @media (max-width: 991px) {
            .wa-remote-grid.mode-focus {
                grid-template-columns: 1fr;
                grid-auto-rows: minmax(100px, auto);
            }
            .wa-remote-grid.mode-focus .wa-remote-tile.is-main {
                grid-row: auto;
                min-height: 220px;
            }
            .wa-remote-grid.mode-grid-many {
                grid-template-columns: repeat(2, minmax(0, 1fr));
            }
        }
        .wa-audio-layer {
            position: absolute;
            inset: 0;
            display: flex;
            flex-direction: column;
            align-items: flex-start;
            justify-content: flex-start;
            padding: max(14px, env(safe-area-inset-top)) 14px 118px;
            background: linear-gradient(180deg, rgba(240, 247, 255, 0.35) 0%, rgba(240, 247, 255, 0.08) 45%, rgba(227, 239, 255, 0.55) 100%);
            color: #173458;
            pointer-events: none;
            z-index: 10;
            display: none !important;
        }
        .wa-active-panel {
            width: auto;
            max-width: min(92vw, 640px);
            border-radius: 0;
            border: none;
            background: transparent;
            box-shadow: none;
            pointer-events: auto;
        }
        .wa-active-panel-body {
            display: flex;
            align-items: center;
            gap: 18px;
            padding: 0;
        }
        .wa-active-meta {
            min-width: 0;
            display: flex;
            flex-direction: column;
            justify-content: center;
        }
        .wa-active-panel .wa-avatar-wrap-lg {
            width: 88px;
            height: 88px;
            margin-bottom: 0;
            flex: 0 0 88px;
        }
        .wa-active-panel .wa-avatar-large {
            border-width: 3px;
            box-shadow: 0 10px 26px rgba(72, 108, 162, 0.24);
            transition: box-shadow 0.22s ease, transform 0.22s ease;
        }
        #wa-active-name {
            font-size: 1rem;
            line-height: 1.2;
            font-weight: 700;
            letter-spacing: 0.01em;
            color: #1c3658;
            margin: 0 0 2px;
            max-width: min(52vw, 330px);
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }
        .wa-status-text {
            font-size: 0.82rem;
            font-weight: 500;
            opacity: 1;
            color: #5a779d;
            margin: 0;
        }
        .wa-active-panel.is-speaking .wa-avatar-large,
        .wa-active-panel.is-speaking #wa-active-avatar-fallback {
            box-shadow: 0 0 0 4px rgba(168, 85, 247, 0.4), 0 0 30px rgba(168, 85, 247, 0.6);
            transform: translateY(-1px);
        }
        .wa-active-panel.is-speaking #wa-active-name {
            text-shadow: 0 0 14px rgba(168, 85, 247, 0.5);
        }
        .wa-pip-wrapper {
            position: absolute;
            bottom: 116px;
            right: 18px;
            width: 116px;
            height: 158px;
            border-radius: 14px;
            overflow: hidden;
            border: 1px solid rgba(90, 112, 160, 0.28);
            background: rgba(250, 252, 255, 0.95);
            box-shadow: 0 14px 30px rgba(66, 84, 125, 0.28);
            z-index: 20;
            transition: transform 0.22s ease, opacity 0.22s ease;
            will-change: transform, opacity;
        }
        .wa-pip-video {
            width: 100%;
            height: 100%;
            object-fit: cover;
            transform: scaleX(-1);
            background: #d6e0fb;
        }
        .wa-pip-video.wa-screen-share-preview {
            object-fit: contain;
            transform: none;
            background: #e9efff;
        }
        .wa-top-actions {
            position: absolute;
            top: max(12px, env(safe-area-inset-top));
            right: 12px;
            z-index: 35;
            display: flex;
            gap: 8px;
        }
        .wa-controls-bar {
            position: absolute;
            bottom: 0;
            left: 0;
            width: 100%;
            min-height: 96px;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 14px;
            padding: 12px 14px calc(12px + env(safe-area-inset-bottom));
            background: linear-gradient(180deg, rgba(244, 248, 255, 0.98) 0%, rgba(236, 242, 255, 0.99) 100%);
            border-top: 1px solid rgba(144, 164, 207, 0.34);
            z-index: 220 !important;
            overflow: visible;
        }
        .wa-control-btn {
            width: 50px;
            height: 50px;
            border-radius: 50%;
            border: 1px solid rgba(129, 149, 196, 0.42);
            background: rgba(255, 255, 255, 0.88);
            color: #27304d;
            font-size: 1.15rem;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            transition: transform 0.18s ease, background 0.18s ease, border-color 0.18s ease;
            will-change: transform;
            transform: translateZ(0);
            backface-visibility: hidden;
        }
        .wa-control-btn:hover {
            background: rgba(240, 246, 255, 0.95);
            transform: translateY(-1px);
        }
        .wa-control-btn:active {
            transform: scale(0.96);
        }
        .wa-btn-hangup {
            width: 56px;
            height: 56px;
            background: linear-gradient(145deg, #ff5560 0%, #e53243 100%);
            border-color: rgba(255,255,255,0.4);
        }
        .wa-btn-minimize {
            background: rgba(255, 255, 255, 0.82);
            color: #27304d;
        }
        #wa-btn-screen.is-active {
            background: linear-gradient(145deg, #6f8cf5 0%, #7998ff 100%);
            border-color: rgba(82, 112, 190, 0.42);
            color: #fff;
        }
        #wa-btn-screen[disabled] {
            opacity: 0.52;
            cursor: not-allowed;
        }
        #wa-btn-whiteboard {
            display: inline-flex;
        }
        #wa-btn-whiteboard.is-host {
            display: inline-flex;
        }
        #wa-whiteboard-panel {
            position: absolute;
            inset: 16px 16px 112px 16px;
            z-index: 80;
            display: none;
            flex-direction: column;
            border-radius: 14px;
            border: 1px solid rgba(155, 173, 210, 0.45);
            background: rgba(255, 255, 255, 0.98);
            box-shadow: 0 16px 30px rgba(38, 62, 101, 0.24);
            overflow: hidden;
        }
        #wa-whiteboard-toolbar {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 10px;
            padding: 10px 12px;
            border-bottom: 1px solid rgba(173, 192, 227, 0.4);
            background: linear-gradient(180deg, rgba(247, 251, 255, 0.98), rgba(239, 246, 255, 0.98));
        }
        .wa-wb-left,
        .wa-wb-right {
            display: inline-flex;
            align-items: center;
            gap: 8px;
        }
        .wa-wb-btn {
            border: 1px solid rgba(130, 152, 196, 0.4);
            background: #fff;
            color: #274170;
            border-radius: 9px;
            min-width: 36px;
            height: 36px;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            padding: 0 10px;
        }
        .wa-wb-btn.is-active {
            background: #e9f2ff;
            border-color: rgba(61, 109, 198, 0.56);
            color: #1e4c93;
        }
        #wa-whiteboard-canvas {
            width: 100%;
            height: 100%;
            touch-action: none;
            background: #fff;
            cursor: crosshair;
        }
        #wa-whiteboard-cursor-layer {
            position: absolute;
            inset: 56px 0 0 0;
            pointer-events: none;
            z-index: 3;
        }
        .wa-wb-cursor {
            position: absolute;
            transform: translate(-2px, -2px);
            display: inline-flex;
            flex-direction: column;
            align-items: flex-start;
            gap: 3px;
            white-space: nowrap;
        }
        .wa-wb-cursor-dot {
            width: 9px;
            height: 9px;
            border-radius: 50%;
            border: 1px solid rgba(255,255,255,0.95);
            box-shadow: 0 2px 8px rgba(9, 21, 38, 0.25);
        }
        .wa-wb-cursor-name {
            font-size: 0.68rem;
            line-height: 1;
            padding: 2px 6px;
            border-radius: 999px;
            color: rgba(255,255,255,0.95);
            background: rgba(24, 34, 54, 0.46);
        }
        @keyframes shake {
            0%, 100% { transform: rotate(0deg); }
            25% { transform: rotate(-9deg); }
            75% { transform: rotate(9deg); }
        }
        @keyframes pulse-accept {
            0% { box-shadow: 0 0 0 0 rgba(102, 126, 234, 0.55); }
            70% { box-shadow: 0 0 0 16px rgba(102, 126, 234, 0); }
            100% { box-shadow: 0 0 0 0 rgba(102, 126, 234, 0); }
        }
        .audio-call-mode .wa-fullscreen-video { display: none; }
        .audio-call-mode .wa-remote-grid { display: grid !important; }
        .audio-call-mode .wa-audio-layer {
            background: linear-gradient(165deg, rgba(245, 250, 255, 0.96) 0%, rgba(237, 246, 255, 0.96) 100%);
            pointer-events: auto;
            align-items: center;
            justify-content: center;
            padding-bottom: 118px;
            display: flex !important;
        }
        .video-call-mode .wa-audio-layer {
            display: none !important;
        }
        .wa-remote-grid:not(:empty) ~ .wa-audio-layer {
            display: none !important;
        }
        .video-call-mode .wa-active-panel {
            width: auto;
            max-width: min(78vw, 470px);
            margin-top: 2px;
            border-radius: 0;
            background: transparent;
            border-color: transparent;
            backdrop-filter: none;
            -webkit-backdrop-filter: none;
            box-shadow: none;
        }
        .video-call-mode .wa-active-panel-body {
            padding: 0;
            gap: 12px;
        }
        .video-call-mode .wa-avatar-wrap-lg {
            width: 58px;
            height: 58px;
            margin-bottom: 0;
            flex: 0 0 58px;
        }
        .video-call-mode #wa-active-name {
            max-width: min(44vw, 230px);
            font-size: 1rem;
            line-height: 1.2;
            margin-bottom: 1px;
        }
        .video-call-mode .wa-status-text {
            font-size: 0.82rem;
            line-height: 1.2;
        }
        .wa-controls-bar .dropup {
            z-index: 400;
        }
        .wa-controls-bar .dropdown-menu {
            z-index: 500 !important;
        }
        #wa-btn-expand-share {
            display: none;
        }
        .wa-pip-wrapper.wa-local-preview-center {
            left: 50% !important;
            top: 50% !important;
            right: auto !important;
            bottom: auto !important;
            width: min(40vw, 320px);
            height: min(50vh, 400px);
            transform: translate(-50%, -50%);
            border-radius: 18px;
            z-index: 24;
            box-shadow: 0 18px 36px rgba(42, 65, 103, 0.3);
        }
        .wa-pip-wrapper.wa-local-preview-center .wa-pip-video {
            object-fit: contain;
            background: #0f1722;
        }
        .wa-screen-share-max .wa-fullscreen-video.wa-screen-share-feed {
            width: 100vw !important;
            height: calc(100vh - 96px) !important;
            max-width: none !important;
            border-radius: 0 !important;
            top: 0 !important;
            left: 0 !important;
            transform: none !important;
            object-fit: contain !important;
            background: #f2f7ff !important;
            z-index: 8;
        }
        .wa-screen-share-max .wa-audio-layer {
            background: linear-gradient(180deg, rgba(247, 251, 255, 0.06) 0%, rgba(247, 251, 255, 0.02) 100%);
        }
        @media (min-width: 992px) {
            .wa-video-expanded .wa-fullscreen-video {
                width: 100% !important;
                height: 100% !important;
                max-width: none !important;
                max-height: none !important;
                top: 0 !important;
                left: 0 !important;
                transform: none !important;
                border-radius: 0 !important;
            }
        }
        @keyframes waIncomingCardShimmer {
            0% { background-position: 0% 45%; }
            50% { background-position: 100% 55%; }
            100% { background-position: 0% 45%; }
        }
        .video-call-mode #wa-active-name,
        .video-call-mode #wa-call-status {
            text-shadow: none;
        }
        .wa-tile-controls {
            position: absolute;
            top: 8px;
            right: 8px;
            display: flex;
            gap: 6px;
            z-index: 20;
            opacity: 0;
            transition: opacity 0.2s ease;
        }
        .wa-remote-tile:hover .wa-tile-controls {
            opacity: 1;
        }
        .wa-tile-btn {
            width: 44px;
            height: 44px;
            border-radius: 12px;
            background: rgba(0, 0, 0, 0.6);
            color: white;
            border: 1px solid rgba(255, 255, 255, 0.3);
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            font-size: 1.3rem;
            transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
            box-shadow: 0 4px 12px rgba(0,0,0,0.2);
        }
        .wa-tile-btn:hover {
            background: rgba(0, 0, 0, 0.85);
            transform: scale(1.15);
            border-color: rgba(255, 255, 255, 0.8);
        }
        .wa-tile-btn:active {
            transform: scale(0.95);
        }
        @media (hover: none) {
            .wa-tile-controls { opacity: 1; }
        }
        .audio-call-mode #wa-btn-expand-video {
            display: none;
        }
        @media (max-width: 991px) {
            #wa-btn-expand-video { display: none; }
        }
        @media (max-width: 991px) {
            #incoming-call-ui {
                padding: 10px;
            }
            .wa-window-shell {
                width: calc(100vw - 24px);
            }
            .wa-active-panel {
                width: calc(100vw - 24px);
            }
            .wa-active-panel-body {
                padding: 12px 14px 14px;
            }
            .wa-pip-wrapper.wa-local-preview-center {
                width: min(80vw, 300px);
                height: min(45vh, 350px);
            }
        }
        #wa-btn-screen {
            display: none;
        }
        #wa-mini-call-window {
            position: fixed;
            right: 16px;
            bottom: 86px;
            width: 280px;
            max-width: calc(100vw - 24px);
            height: 170px;
            border-radius: 14px;
            overflow: hidden;
            display: none;
            z-index: 10001;
            background: rgba(244, 248, 255, 0.97);
            border: 1px solid rgba(141, 162, 205, 0.48);
            box-shadow: 0 16px 32px rgba(67, 86, 128, 0.28);
            touch-action: none;
            user-select: none;
            cursor: grab;
        }
        #wa-mini-call-window.dragging { cursor: grabbing; }
        #wa-mini-remote-video {
            width: 100%;
            height: 100%;
            object-fit: cover;
            background: #d9e3ff;
        }
        #wa-mini-remote-video.wa-screen-share-feed {
            object-fit: contain;
            background: #edf3ff;
        }
        #wa-mini-audio-fallback {
            position: absolute;
            inset: 0;
            display: none;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            gap: 8px;
            background: radial-gradient(circle at top, #e7efff 0%, #c9d7f8 72%);
            color: #243457;
        }
        .wa-mini-avatar-wrap {
            position: relative;
            width: 54px;
            height: 54px;
        }
        .wa-mini-avatar-wrap img {
            width: 100%;
            height: 100%;
            border-radius: 50%;
            object-fit: cover;
            border: 1px solid rgba(255,255,255,0.4);
        }
        .wa-mini-avatar-fallback {
            font-size: 1.2rem;
            background: linear-gradient(145deg, rgba(255,255,255,0.3), rgba(255,255,255,0.12));
            border: 1px solid rgba(255,255,255,0.36);
        }
        #wa-mini-top-actions {
            position: absolute;
            top: 8px;
            right: 8px;
            z-index: 5;
            display: flex;
            gap: 6px;
        }
        #wa-mini-overlay {
            position: absolute;
            inset: 0;
            background: linear-gradient(180deg, rgba(255,255,255,0.05) 20%, rgba(27,40,71,0.62) 100%);
            display: flex;
            align-items: flex-end;
            padding: 10px;
            color: #fff;
            pointer-events: none;
        }
        .wa-mini-meta {
            display: flex;
            width: 100%;
            align-items: flex-end;
            justify-content: space-between;
            gap: 8px;
        }
        #wa-mini-name {
            font-size: 0.9rem;
            font-weight: 600;
            max-width: 150px;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }
        #wa-mini-status {
            font-size: 0.74rem;
            opacity: 0.9;
            line-height: 1.2;
        }
        .wa-mini-actions {
            display: flex;
            gap: 6px;
            pointer-events: auto;
        }
        .wa-mini-btn {
            width: 32px;
            height: 32px;
            border-radius: 50%;
            border: 1px solid rgba(127, 149, 194, 0.4);
            display: inline-flex;
            align-items: center;
            justify-content: center;
            color: #2b3d67;
            background: rgba(255, 255, 255, 0.82);
        }
        .wa-mini-btn-hangup {
            background: linear-gradient(145deg, #ff5560 0%, #e53243 100%);
            border-color: rgba(255,255,255,0.4);
        }
        #wa-mini-top-actions .wa-mini-btn {
            pointer-events: auto;
        }
        @media (min-width: 992px) {
            #wa-btn-speaker {
                display: none;
            }
            #wa-btn-screen {
                display: inline-flex;
            }
        }
        @media (max-width: 991px) {
            #wa-mini-call-window {
                width: 228px;
                height: 150px;
                right: 10px;
                bottom: 82px;
            }
            #wa-mini-name {
                max-width: 110px;
            }
            .wa-controls-bar {
                gap: 10px;
                padding-left: 10px;
                padding-right: 10px;
            }
        }

        /* --- NEW COMMENT SYSTEM DESIGN --- */
        .comment-node { position: relative; margin-bottom: 16px; animation: fadeIn 0.3s ease; }
        .comment-main { display: flex; gap: 12px; }
        .comment-avatar-img { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; flex-shrink: 0; border: 1px solid rgba(0,0,0,0.05); }
        .comment-body { flex: 1; min-width: 0; }
        
        .comment-header { font-size: 0.9rem; line-height: 1.3; margin-bottom: 2px; display: flex; align-items: baseline; flex-wrap: wrap; }
        .comment-author { font-weight: 700; color: #0f1419; text-decoration: none; margin-right: 6px; }
        .comment-author:hover { text-decoration: underline; }
        .comment-meta { color: #536471; font-weight: 400; font-size: 0.85rem; }
        
        .comment-text { font-size: 0.95rem; color: #0f1419; line-height: 1.5; margin-bottom: 6px; white-space: pre-wrap; word-break: break-word; }
        
        .comment-actions { display: flex; gap: 18px; align-items: center; }
        .comment-act-btn { background: none; border: none; padding: 0; color: #536471; font-size: 0.85rem; display: flex; align-items: center; gap: 5px; cursor: pointer; transition: color 0.2s; }
        .comment-act-btn:hover { color: #1d9bf0; }
        .comment-act-btn.like-btn:hover { color: #f91880; }
        .comment-act-btn.delete-btn:hover { color: #dc3545; }
        
        /* Threading */
        .comment-replies { 
            margin-left: 18px; 
            padding-left: 12px; 
            border-left: 2px solid #eff3f4; 
            margin-top: 12px; 
        }
        @media (min-width: 768px) {
            .comment-replies { margin-left: 24px; padding-left: 20px; }
        }

        /* Load More */
        .load-more-comments {
            width: 100%; text-align: left; background: none; border: none;
            color: #1d9bf0; font-size: 0.9rem; padding: 10px 0; font-weight: 500;
            transition: opacity 0.2s;
        }
        .load-more-comments:hover { opacity: 0.8; }

        /* Sticky Input */
        .comment-input-area {
            position: sticky; bottom: 0; background: rgba(255,255,255,0.95);
            backdrop-filter: blur(10px); padding: 12px 0; border-top: 1px solid #eff3f4;
            z-index: 10; margin-top: auto;
        }
        .comment-input-box {
            background: #eff3f4; border-radius: 24px; padding: 4px 12px;
            display: flex; align-items: center; transition: background 0.2s;
        }
        .comment-input-box:focus-within { background: #fff; box-shadow: 0 0 0 2px #667eea; }
        .comment-input {
            border: none; background: transparent; width: 100%; padding: 8px 0; outline: none; font-size: 0.95rem;
        }
        textarea.comment-input { resize: none; height: 40px; max-height: 120px; }
        div.comment-input { min-height: 40px; max-height: 120px; overflow-y: auto; cursor: text; }
        div.comment-input[contenteditable]:empty:before {
            content: attr(data-placeholder);
            color: #6c757d;
            pointer-events: none;
            display: block;
        }

        /* Скрываем полностью белую панель звонка */
        #active-call-ui .wa-call-top-bar,
        .wa-call-header,
        div[class*="call"] [class*="header"],
        div[style*="position: fixed"][style*="top:"] > div > div > div > img + span {
            display: none !important;
        }

        /* УДАЛЯЕМ ВСЕ ФОНЫ КАРТОЧЕК (ПО ЗАПРОСУ) */
        .wa-active-panel,
        .wa-active-panel-body,
        .wa-pip-wrapper,
        .wa-window-header,
        .wa-window-footer {
            background: transparent !important;
            box-shadow: none !important;
            border: none !important;
        }

        /* Restore background for incoming call card */
        #incoming-call-ui .wa-window-shell {
            background: linear-gradient(120deg, #ffffff 0%, #edf4ff 25%, #e8fff6 52%, #eef2ff 76%, #ffffff 100%) !important;
            box-shadow: 0 20px 44px rgba(64, 94, 148, 0.2) !important;
            border: 1px solid rgba(160, 184, 220, 0.55) !important;
        }

        /* Стили для карточек звонка (темные с мягкими границами) */
        .wa-remote-tile {
            background: rgba(0, 0, 0, 0.65) !important;
            border: 1px solid rgba(255, 255, 255, 0.15) !important;
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3) !important;
            transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
        }
        .wa-remote-tile.is-speaking {
            border-color: rgba(168, 85, 247, 0.9) !important;
            box-shadow: 0 0 15px rgba(168, 85, 247, 0.6) !important;
        }

        /* Text Effects CSS (Global) */
        .effect-rainbow { background: linear-gradient(to right, red, orange, yellow, green, blue, indigo, violet); -webkit-background-clip: text; color: transparent; animation: rainbow 2s linear infinite; font-weight: bold; }
        @keyframes rainbow { 0% { filter: hue-rotate(0deg); } 100% { filter: hue-rotate(360deg); } }

        .effect-fire { color: #ff8c00; text-shadow: 0 0 3px #ffef00, 0 0 5px #ff4500; animation: fire 1s ease-in-out infinite alternate; }
        @keyframes fire { from { text-shadow: 0 0 3px #ffef00, 0 0 5px #ff4500; } to { text-shadow: 0 -2px 5px #ffef00, 0 -5px 10px #ff4500; } }

        .effect-neon { color: #fff; text-shadow: 0 0 5px #fff, 0 0 10px #fff, 0 0 20px #ff00de, 0 0 30px #ff00de; }
        
        .effect-glitch { position: relative; display: inline-block; animation: glitch 1s infinite; }
        @keyframes glitch { 0% { transform: translate(0); } 20% { transform: translate(-2px, 2px); } 40% { transform: translate(-2px, -2px); } 60% { transform: translate(2px, 2px); } 80% { transform: translate(2px, -2px); } 100% { transform: translate(0); } }

        .effect-wavy { position: relative; display: inline-block; animation: wavy 1s ease-in-out infinite; }
        @keyframes wavy { 0%, 100% { top: 0; } 50% { top: -3px; } }

        .effect-blur { color: transparent; text-shadow: 0 0 5px rgba(255,255,255,0.8); }
        
        .effect-pulse { display: inline-block; animation: pulse-text 1s infinite; }
        @keyframes pulse-text { 0% { transform: scale(1); } 50% { transform: scale(1.1); } 100% { transform: scale(1); } }

        .effect-shake { display: inline-block; animation: shake-text 0.5s infinite; }
        @keyframes shake-text { 0% { transform: translateX(0); } 25% { transform: translateX(2px); } 75% { transform: translateX(-2px); } 100% { transform: translateX(0); } }

        .effect-glow { animation: glow 1.5s ease-in-out infinite alternate; }
        @keyframes glow { from { text-shadow: 0 0 5px #fff; } to { text-shadow: 0 0 20px #fff, 0 0 30px #667eea; } }

        .effect-ice { color: #a5f2f3; text-shadow: 0 0 5px #00b7ff; }
        .effect-toxic { color: #39ff14; text-shadow: 0 0 5px #39ff14; font-family: monospace; }
        .effect-gold { background: linear-gradient(to bottom, #cfc09f 22%, #634f2c 24%, #cfc09f 26%, #cfc09f 27%, #ffecb3 40%, #3a2c0f 78%); -webkit-background-clip: text; color: transparent; font-weight: bold; }
        .effect-retro { font-family: 'Courier New', Courier, monospace; color: #0f0; background: #000; padding: 0 4px; }
        .effect-comic { font-family: 'Comic Sans MS', cursive, sans-serif; color: #ff0066; letter-spacing: 1px; font-weight: bold; }
        .effect-3d { color: #fff; text-shadow: 1px 1px 0 #000, 2px 2px 0 #000, 3px 3px 0 #000; }
        .effect-outline { -webkit-text-stroke: 1px #fff; color: transparent; font-weight: bold; }
        .effect-squeeze { display: inline-block; animation: squeeze 2s infinite; }
        @keyframes squeeze { 0%, 100% { letter-spacing: normal; } 50% { letter-spacing: -2px; } }
        .effect-expand { display: inline-block; animation: expand 2s infinite; }
        @keyframes expand { 0%, 100% { letter-spacing: normal; } 50% { letter-spacing: 4px; } }
        .effect-fade { animation: fade 2s infinite; }
        @keyframes fade { 0%, 100% { opacity: 1; } 50% { opacity: 0.3; } }
        .effect-mirror { display: inline-block; transform: scaleX(-1); }
