/* ---- page-range extract: data-analysis (14 blocks) ---- */
/* block 1 */

        .data-analysis-container {
            max-width: 1400px;
            width: 100%;
            margin: 0 auto;
            padding: 10px;
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            box-sizing: border-box;
        }

        /* Section */
        #data-analysis-page {
            padding-right: 200px !important;
            box-sizing: border-box;
        }

        :root {
            --stat-green: #37b24d;
            --stat-blue: #1c7ed6;
            --stat-red: #f03e3e;
            --stat-orange: #f59f00;
            --stat-purple: #4c6ef5;
            --stat-indigo: #4263eb;
        }

        .dashboard-grid {
            display: grid;
            grid-template-rows: auto auto auto auto;
            gap: 14px;
        }

        /* Row 1 */
        .row-grid-4 {
            display: grid;
            grid-template-columns: 2fr 1fr 1fr 1.5fr;
            gap: 14px;
        }

        /* Row */
        .row-grid-map {
            display: grid;
            grid-template-columns: 1fr 2fr;
            gap: 14px;
            margin-top: 14px;
        }
        .row-grid-map .monthly-card { grid-column: 1 / -1; }
        .row-grid-map .regions-card  { grid-column: 1; }
        .row-grid-map .map-card      { grid-column: 2; }

        /* Bottom Row */
        .row-bottom {
            margin-top: 14px;
        }

        /* Dark Mode Support */
        body.dark-mode .news-ticker-container {
            background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
            border: 1px solid rgba(255, 255, 255, 0.1);
        }

        body.dark-mode .news-ticker-icon {
            background: rgba(255, 255, 255, 0.15);
        }

        body.dark-mode .news-ticker-wrapper {
            box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
        }
    

/* block 2 */

        .data-nav-pills {
            display: flex;
            justify-content: center;
            gap: 6px;
            margin-bottom: 10px;
            background: white;
            padding: 4px 8px;
            border-radius: 50px;
            box-shadow: 0 2px 8px rgba(15, 23, 42, 0.05);
            width: fit-content;
            margin-left: auto;
            margin-right: auto;
            flex-wrap: wrap;
        }

        .data-nav-pill {
            padding: 6px 12px;
            border-radius: 25px;
            background: transparent;
            border: 1px solid transparent;
            color: #64748b;
            font-weight: 600;
            font-size: 0.75rem;
            cursor: pointer;
            transition: all 0.2s;
            display: flex;
            align-items: center;
            gap: 6px;
            white-space: nowrap;
        }

        .data-nav-pill.active {
            background: #1e40af;
            color: white;
            box-shadow: 0 4px 12px rgba(30, 64, 175, 0.25);
        }

        .data-nav-pill:hover:not(.active) {
            color: #1e40af;
            background: #f8fafc;
        }

        .data-tab-content {
            display: none;
        }

        .data-tab-content.active {
            display: block;
        }
    

/* block 3 */

        .data-card {
            background: white;
            border-radius: 16px;
            padding: 24px;
            box-shadow: 0 10px 15px -3px rgba(15, 23, 42, 0.1), 0 4px 6px -2px rgba(15, 23, 42, 0.05);
            border: 1px solid #e2e8f0;
            text-align: center;
            color: #1f2937;
            box-sizing: border-box;
            width: 100%;
            overflow: hidden;
        }

        .data-card h2 {
            font-size: 1.15rem;
            margin-bottom: 10px;
            color: #111827;
            font-weight: 700;
        }

        .data-card p {
            margin: 0;
            font-size: 0.95rem;
            color: #4b5563;
        }

        .data-badge {
            display: inline-flex;
            align-items: center;
            gap: 6px;
            padding: 4px 10px;
            border-radius: 999px;
            background: #fee2e2;
            color: #b91c1c;
            font-size: 0.8rem;
            font-weight: 600;
            margin-top: 10px;
        }

        .data-badge i {
            font-size: 0.85rem;
        }

        /* Days Counter Card - Small & Elegant */
        .days-counter-card {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            color: white;
            padding: 8px 16px;
            border-radius: 12px;
            box-shadow: 0 4px 12px rgba(102, 126, 234, 0.25);
            display: flex;
            align-items: center;
            gap: 10px;
            z-index: 10;
            min-width: 150px;
            transition: all 0.3s ease;
        }

        .days-counter-card:hover {
            transform: translateY(-2px);
            box-shadow: 0 6px 16px rgba(102, 126, 234, 0.35);
        }

        .days-counter-icon-small {
            font-size: 1.3rem;
            opacity: 0.9;
        }

        .days-counter-content-small {
            display: flex;
            flex-direction: column;
            gap: 2px;
            flex: 1;
            align-items: center;
            text-align: center;
        }

        .days-counter-label-small {
            font-size: 0.75rem;
            opacity: 0.9;
            font-weight: 500;
            line-height: 1.2;
            text-align: center;
            width: 100%;
        }

        .days-counter-number-small {
            font-size: 1.5rem;
            font-weight: 900;
            line-height: 1;
            text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
            display: flex;
            align-items: baseline;
            gap: 4px;
            justify-content: center;
            width: 100%;
        }

        .days-counter-day-label {
            font-size: 0.85rem;
            font-weight: 600;
            opacity: 0.95;
        }

        .days-counter-wrapper {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 10px;
            padding: 3px 2px;
            width: 100%;
            flex-wrap: wrap;
            gap: 10px;
        }

        .days-counter-left {
            display: flex;
            align-items: center;
            gap: 12px;
        }

        /* Top Header Stats */
        .stats-header {
            display: grid;
            grid-template-columns: repeat(3, 1fr);
            gap: 12px;
            border-radius: 8px;
            overflow: visible;
            box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08);
        }

        .stat-header-box {
            padding: 22px 14px;
            text-align: center;
            color: white;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            position: relative;
            border-radius: 12px;
            box-shadow: 0 4px 10px rgba(0, 0, 0, 0.12);
            transition: transform 0.3s ease, box-shadow 0.3s ease;
            min-height: 126px;
            overflow: hidden;
        }

        .stat-header-box::before {
            content: '';
            position: absolute;
            top: -45%;
            left: -25%;
            width: 95px;
            height: 95px;
            background: radial-gradient(circle, rgba(255, 255, 255, 0.28), transparent 70%);
            border-radius: 50%;
            pointer-events: none;
        }

        .stat-header-box:hover {
            transform: translateY(-3px);
            box-shadow: 0 10px 20px rgba(0, 0, 0, 0.22);
        }

        .stat-header-box .icon {
            position: relative;
            z-index: 1;
            width: 42px;
            height: 42px;
            border-radius: 50%;
            background: rgba(255, 255, 255, 0.22);
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 1.15rem;
            margin-bottom: 8px;
            opacity: 1;
        }

        .stat-header-box h3 {
            position: relative;
            z-index: 1;
            font-size: 0.9rem;
            margin: 0 0 6px 0;
            font-weight: 700;
            opacity: 0.95;
            letter-spacing: 0.2px;
            line-height: 1.2;
        }

        .stat-header-box .number {
            position: relative;
            z-index: 1;
            font-size: 2.2rem;
            font-weight: 900;
            line-height: 1.1;
            text-shadow: 0 2px 4px rgba(0, 0, 0, 0.25);
            letter-spacing: 0.3px;
            font-variant-numeric: tabular-nums;
        }

        .dash-card {
            background: white;
            border-radius: 12px;
            box-shadow: 0 4px 12px rgba(15, 23, 42, 0.06);
            padding: 12px;
            border: 1px solid #e2e8f0;
            transition: transform 0.3s ease, box-shadow 0.3s ease;
        }

        .dash-card:hover {
            transform: translateY(-2px);
            box-shadow: 0 8px 20px rgba(15, 23, 42, 0.1);
        }

        .dash-card-title {
            font-size: 0.92rem;
            font-weight: 800;
            color: #0f172a;
            margin-bottom: 10px;
            text-align: center;
            border-bottom: 2px solid #eef2f7;
            padding-bottom: 6px;
            letter-spacing: 0.2px;
        }

        /* Additional Statistics Cards - Region Style */
        .additional-stats-list {
            list-style: none;
            padding: 0;
            margin: 0;
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
            gap: 12px;
        }

        .additional-stat-item {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 18px 15px;
            border-radius: 12px;
            background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
            border: 2px solid #e2e8f0;
            box-shadow: 0 3px 6px rgba(0, 0, 0, 0.08);
            transition: all 0.3s ease;
            cursor: pointer;
        }

        .additional-stat-item:hover {
            background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
            box-shadow: 0 5px 12px rgba(0, 0, 0, 0.12);
            transform: translateY(-3px);
            border-color: #cbd5e1;
        }

        .additional-stat-item>div:first-child {
            display: flex;
            flex-direction: column;
            gap: 6px;
            flex: 1;
            min-width: 0;
            overflow: hidden;
        }

        .additional-stat-item h4 {
            margin: 0;
            font-size: 1.1rem;
            font-weight: 800;
            color: #1e40af;
            letter-spacing: 0.3px;
            display: flex;
            align-items: center;
            gap: 8px;
        }

        .additional-stat-item .stat-icon {
            font-size: 1.3rem;
            opacity: 0.8;
        }

        .additional-stat-item .sub {
            font-size: 0.85rem;
            color: #64748b;
            font-weight: 600;
        }

        .additional-stat-item .stat-val {
            font-weight: 900;
            color: #059669;
            font-size: 1.6rem;
            min-width: 100px;
            text-align: center;
            padding: 10px 15px;
            background: linear-gradient(135deg, #ffffff 0%, #f0fdf4 100%);
            border-radius: 10px;
            box-shadow: 0 2px 6px rgba(5, 150, 105, 0.15);
            border: 2px solid #d1fae5;
            transition: all 0.3s ease;
            flex-shrink: 0;
            visibility: visible;
            opacity: 1;
            display: inline-block;
            white-space: nowrap;
            font-variant-numeric: tabular-nums;
        }

        .additional-stat-item:hover .stat-val {
            background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
            box-shadow: 0 3px 8px rgba(5, 150, 105, 0.2);
            transform: scale(1.05);
        }

        /* Different colors for each stat item */
        .additional-stat-item.stat-languages { border-left: 4px solid #3b82f6; }
        .additional-stat-item.stat-languages:hover { border-color: #3b82f6; box-shadow: 0 5px 12px rgba(59, 130, 246, 0.15); }
        .additional-stat-item.stat-languages .stat-val { color: #3b82f6; background: linear-gradient(135deg, #ffffff 0%, #eff6ff 100%); border-color: #bfdbfe; }
        .additional-stat-item.stat-countries { border-left: 4px solid #10b981; }
        .additional-stat-item.stat-countries:hover { border-color: #10b981; box-shadow: 0 5px 12px rgba(16, 185, 129, 0.15); }
        .additional-stat-item.stat-countries .stat-val { color: #10b981; background: linear-gradient(135deg, #ffffff 0%, #f0fdf4 100%); border-color: #d1fae5; }

        /* Countries Count with Map Background */
        .countries-count-card { position: relative; overflow: hidden; text-align: center; display: flex; flex-direction: column; justify-content: center; }
        .countries-count-card .dash-card-title { border: none; position: relative; z-index: 1; }
        .countries-count-label { color: #64748b; position: relative; z-index: 1; }
        .map-background-svg { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 100%; height: 100%; z-index: 0; pointer-events: none; opacity: 0.35; }
        .map-background-svg img { width: 100%; height: 100%; object-fit: contain; object-position: center; }
        .countries-count-content { position: relative; z-index: 1; }

        .countries-number {
            font-size: 2.2rem;
            font-weight: 900;
            position: relative;
            z-index: 1;
            background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
            -webkit-background-clip: text;
            background-clip: text;
            color: transparent;
            animation: countriesPulse 2.6s ease-in-out infinite;
        }

        @keyframes countriesPulse {
            0%, 100% { transform: scale(1); }
            50% { transform: scale(1.06); }
        }

        /* Section */
        .stat-total { background: linear-gradient(135deg, #22c55e 0%, #15803d 100%); }
        .stat-year { background: linear-gradient(135deg, #3b82f6 0%, #1e40af 100%); }
        .stat-month { background: linear-gradient(135deg, #ef4444 0%, #b91c1c 100%); }
        .stat-week { background: linear-gradient(135deg, #fb923c 0%, #ea580c 100%); }
        .stat-today { background: linear-gradient(135deg, #6366f1 0%, #4338ca 100%); }

        /* Section */
        .dash-card-flush { padding: 0; border: none; overflow: hidden; }

        /* Section */
        .dash-card-col-center { display: flex; flex-direction: column; justify-content: center; }
        .dash-card-span-2 { grid-column: span 2; }

        /* Section */
        .gender-label { font-size: 0.85rem; margin-top: 3px; }
        .gender-label-female { color: #db2777; }
        .gender-label-male { color: #1e40af; }
        .gender-percent { font-size: 0.75rem; color: #64748b; }
    

/* block 4 */

        /* ========================================
           Date Filter Styles - Compact Version
           ======================================== */
        .date-filter-container {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            border-radius: 10px;
            padding: 8px 12px;
            margin-bottom: 8px;
            box-shadow: 0 4px 12px rgba(102, 126, 234, 0.2);
            color: white;
        }

        .date-filter-wrapper {
            background: white;
            border-radius: 6px;
            padding: 8px 12px;
            color: #1e293b;
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 12px;
            flex-wrap: wrap;
        }

        .date-filter-header {
            display: flex;
            align-items: center;
            gap: 6px;
            font-weight: 700;
            color: #1e293b;
            font-size: 0.85rem;
            white-space: nowrap;
            margin-bottom: 0;
            margin-left: 8px;
        }

        .date-filter-main-controls {
            display: flex;
            align-items: center;
            gap: 8px;
            flex: 1;
        }

        .date-filter-inputs {
            display: flex;
            gap: 8px;
            align-items: center;
        }

        .date-input-group {
            display: flex;
            align-items: center;
            gap: 4px;
        }

        .date-input-group label {
            font-size: 0.75rem;
            font-weight: 600;
            color: #64748b;
            white-space: nowrap;
        }

        .date-input {
            padding: 4px 8px;
            border: 1px solid #e2e8f0;
            border-radius: 4px;
            font-size: 0.8rem;
            transition: all 0.3s ease;
            width: 130px;
            font-family: inherit;
        }

        .date-input:focus {
            outline: none;
            border-color: #667eea;
            box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.1);
        }

        .date-filter-actions {
            display: flex;
            gap: 4px;
        }

        .btn-apply-filter,
        .btn-reset-filter {
            padding: 5px 10px;
            border: none;
            border-radius: 4px;
            font-weight: 600;
            font-size: 0.75rem;
            cursor: pointer;
            transition: all 0.3s ease;
            display: flex;
            align-items: center;
            gap: 4px;
            font-family: inherit;
        }

        .btn-apply-filter {
            background: linear-gradient(135deg, #10b981 0%, #059669 100%);
            color: white;
        }

        .btn-apply-filter:hover {
            transform: translateY(-1px);
            box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
        }

        .btn-reset-filter {
            background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
            color: white;
        }

        .btn-reset-filter:hover {
            transform: translateY(-1px);
            box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
        }

        .quick-filters {
            display: flex;
            gap: 4px;
            flex-wrap: wrap;
            margin-top: 0;
            padding-right: 8px;
            border-right: 1px solid #e2e8f0;
        }

        .quick-filter-btn {
            padding: 4px 8px;
            background: #f1f5f9;
            border: 1px solid #e2e8f0;
            border-radius: 12px;
            font-size: 0.65rem;
            font-weight: 600;
            color: #475569;
            cursor: pointer;
            transition: all 0.2s ease;
            font-family: inherit;
        }

        .quick-filter-btn:hover {
            background: #667eea;
            color: white;
            border-color: #667eea;
        }

        .filter-status {
            padding: 4px 8px;
            background: #eff6ff;
            border: 1px solid #bfdbfe;
            border-radius: 4px;
            font-size: 0.7rem;
            color: #1e40af;
            display: flex;
            align-items: center;
            gap: 4px;
            animation: fadeIn 0.3s ease;
            white-space: nowrap;
        }

        /* Continent Filter Buttons - Premium Redesign */
        .continent-filters {
            display: flex;
            flex-wrap: wrap;
            justify-content: center;
            align-items: center;
            gap: 10px 15px;
            margin: 16px auto 8px;
            padding: 12px 20px;
            background: rgba(255, 255, 255, 0.9);
            backdrop-filter: blur(10px);
            border-radius: 20px;
            box-shadow: 0 8px 32px rgba(15, 23, 42, 0.08);
            border: 1px solid #eef2f6;
            max-width: 100%;
            z-index: 10;
            transition: all 0.4s ease;
        }

        .continent-filter {
            padding: 12px 24px;
            border-radius: 14px;
            border: 1px solid #f1f5f9;
            background: #ffffff;
            color: #64748b;
            font-weight: 700;
            cursor: pointer;
            transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
            font-size: 0.95rem;
            display: flex;
            align-items: center;
            gap: 10px;
            position: relative;
            box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
        }

        .continent-filter i {
            font-size: 1.1rem;
            transition: all 0.3s ease;
        }

        .continent-filter:hover {
            transform: translateY(-4px);
            box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
            background: #f8fafc;
            border-color: #e2e8f0;
            color: #1e293b;
        }

        .continent-filter.active {
            color: white !important;
            border-color: transparent;
            box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
        }

        .continent-filter.active i {
            color: white !important;
            transform: scale(1.2) rotate(5deg);
        }

        /* Section */
        .continent-filter.active { background: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%); }

        .continent-filter[onclick*="'all'"]:hover i { color: #3b82f6; }
        .continent-filter[onclick*="1"]:hover i { color: #10b981; }
        .continent-filter[onclick*="2"]:hover i { color: #f59e0b; }
        .continent-filter[onclick*="5"]:hover i { color: #8b5cf6; }
        .continent-filter[onclick*="'americas'"]:hover i { color: #ef4444; }
    

/* block 5 */

        /* Combined Map and Pie Chart Container */
        .map-pie-container {
            position: relative;
            height: 420px;
            display: flex;
            gap: 12px;
        }

        .map-section {
            flex: 2;
            position: relative;
            background: #f8fafc;
            border-radius: 8px;
            overflow: hidden;
        }

        /* Leaflet Map Container */
        .leaflet-map-container {
            width: 100%;
            height: 100%;
            min-height: 250px;
            border-radius: 8px;
            overflow: hidden;
            z-index: 1;
        }

        /* Custom Marker Styles */
        .custom-div-icon { background: transparent; border: none; }
        .custom-marker {
            background: #ec4899;
            border: 2px solid white;
            border-radius: 50%;
            width: 100%;
            height: 100%;
            position: relative;
            box-shadow: 0 0 10px rgba(236, 72, 153, 0.5);
            transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
            cursor: pointer;
            z-index: 1;
        }

        .custom-marker:hover {
            transform: scale(1.5);
            background: #db2777;
            box-shadow: 0 0 20px rgba(236, 72, 153, 0.8);
            z-index: 1000 !important;
        }

        .custom-marker-large { width: 24px !important; height: 24px !important; }
        .custom-marker-medium { width: 18px !important; height: 18px !important; }
        .custom-marker-small { width: 12px !important; height: 12px !important; }

        /* Modern Popup Styles (Glassmorphism) */
        .custom-popup .leaflet-popup-content-wrapper {
            background: rgba(255, 255, 255, 0.9) !important;
            backdrop-filter: blur(8px);
            border-radius: 12px;
            box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
            border: 1px solid rgba(255, 255, 255, 0.5);
            padding: 2px;
            font-family: inherit;
        }

        .custom-popup .leaflet-popup-tip { background: rgba(255, 255, 255, 0.9); }
        .custom-popup .leaflet-popup-content { margin: 0; padding: 0; overflow: visible !important; }
        .custom-popup .leaflet-popup-content-wrapper { overflow: visible !important; }

        /* popup */
        @media (max-width: 768px) {
            .custom-popup .leaflet-popup-content-wrapper { max-width: 240px !important; }
            .custom-popup .leaflet-popup-content { max-width: 220px !important; }
        }

        .leaflet-container { font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; }
        .leaflet-container .leaflet-tile-pane { filter: brightness(1.1) saturate(0.8) hue-rotate(180deg); }
        .leaflet-container .leaflet-tile { opacity: 0.9; }
        .leaflet-control-zoom { border: none; box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15); }
        .leaflet-control-zoom a { background-color: white; color: #1e3a8a; border: 1px solid #e2e8f0; }
        .leaflet-control-zoom a:hover { background-color: #f8fafc; color: #1e40af; }

        /* Monthly Statistics Table Styles */
        .monthly-stats-table-container { padding: 10px; max-height: 400px; overflow-y: auto; }
        .monthly-stats-table-container::-webkit-scrollbar { width: 6px; }
        .monthly-stats-table-container::-webkit-scrollbar-track { background: #f1f5f9; border-radius: 3px; }
        .monthly-stats-table-container::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 3px; }
        .monthly-stats-table-container::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

        .monthly-stats-loading { text-align: center; padding: 40px; color: #64748b; font-size: 0.9rem; }
        .monthly-stats-table { width: 100%; border-collapse: collapse; font-size: 0.85rem; }
        .monthly-stats-table thead { position: sticky; top: 0; background: #1e40af; color: white; z-index: 10; }
        .monthly-stats-table th { padding: 12px 10px; text-align: right; font-weight: 700; font-size: 0.9rem; border-bottom: 2px solid #1e3a8a; }
        .monthly-stats-table th:first-child { border-radius: 8px 0 0 0; }
        .monthly-stats-table th:last-child { border-radius: 0 8px 0 0; }
        .monthly-stats-table tbody tr { border-bottom: 1px solid #e2e8f0; transition: background-color 0.2s; }
        .monthly-stats-table tbody tr:hover { background-color: #f8fafc; }
        .monthly-stats-table td { padding: 12px 10px; text-align: right; color: #334155; }
        .monthly-stats-table td:first-child { font-weight: 600; color: #1e40af; min-width: 120px; }
        .monthly-stats-table td:last-child { font-weight: 700; color: #059669; font-size: 1rem; text-align: center; min-width: 80px; }
        .monthly-stats-table tbody tr:nth-child(even) { background-color: #f8fafc; }

        /* Section */
        /* Section */
        .monthly-card { display: flex; flex-direction: column; }
        .monthly-card .dash-card-title { flex: 0 0 auto; }
        .monthly-card .monthly-stats-table-container {
            flex: 1;
            display: flex;
            flex-direction: column;
            max-height: none;
            padding: 6px;
        }

        .monthly-bar-chart {
            display: flex;
            align-items: flex-end;
            gap: 6px;
            flex: 1 0 auto;
            min-height: 210px;
            padding: 10px 4px 0;
            margin-bottom: 8px;
            border-bottom: 1px dashed #e2e8f0;
            overflow-x: auto;
        }
        .monthly-bar-item {
            flex: 1 1 0;
            min-width: 0;
            height: 100%;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: flex-end;
            gap: 3px;
        }
        .monthly-bar-val {
            font-size: 0.6rem;
            font-weight: 800;
            color: #1e40af;
            font-variant-numeric: tabular-nums;
            white-space: nowrap;
        }
        .monthly-bar {
            width: 100%;
            height: 0;
            background: linear-gradient(180deg, #60a5fa, #1e40af);
            border-radius: 5px 5px 0 0;
            transition: height 1s cubic-bezier(0.22, 1, 0.36, 1), filter 0.2s ease;
            cursor: pointer;
        }
        .monthly-bar:hover { filter: brightness(1.15); }
        .monthly-bar-label {
            font-size: 0.6rem;
            color: #64748b;
            white-space: nowrap;
            margin-top: 2px;
        }

        /* skeleton */
        .monthly-skeleton {
            display: flex;
            align-items: flex-end;
            gap: 8px;
            height: 150px;
            padding: 12px 4px 0;
        }
        .monthly-skeleton .sk-bar {
            flex: 1 0 30px;
            min-width: 30px;
            border-radius: 5px 5px 0 0;
            background: linear-gradient(90deg, #eef2f7 25%, #e2e8f0 50%, #eef2f7 75%);
            background-size: 200% 100%;
            animation: skShimmer 1.4s ease-in-out infinite;
        }
        @keyframes skShimmer {
            0% { background-position: 200% 0; }
            100% { background-position: -200% 0; }
        }
        .monthly-skeleton .sk-bar:nth-child(1) { height: 45%; }
        .monthly-skeleton .sk-bar:nth-child(2) { height: 65%; }
        .monthly-skeleton .sk-bar:nth-child(3) { height: 80%; }
        .monthly-skeleton .sk-bar:nth-child(4) { height: 55%; }
        .monthly-skeleton .sk-bar:nth-child(5) { height: 90%; }
        .monthly-skeleton .sk-bar:nth-child(6) { height: 70%; }
        .monthly-skeleton .sk-bar:nth-child(7) { height: 50%; }
        .monthly-skeleton .sk-bar:nth-child(8) { height: 75%; }
    

/* block 6 */

        /* Languages */
        .languages-card {
            max-height: 260px;
            overflow-y: auto;
        }

        .flags-container {
            display: flex;
            flex-direction: column;
            gap: 8px;
            align-items: stretch;
            padding: 4px 2px;
        }

        .flag-item {
            display: grid;
            grid-template-columns: 30px 1fr auto;
            align-items: center;
            gap: 10px;
            padding: 7px 8px;
            border-radius: 8px;
            background: #f8fafc;
            transition: background 0.2s ease, transform 0.2s ease;
        }

        .flag-item:hover {
            background: #eff6ff;
            transform: translateX(-2px);
        }

        .flag-item img {
            width: 26px;
            height: 26px;
            border-radius: 50%;
            object-fit: cover;
            border: 2px solid #fff;
            box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
        }

        .flag-info {
            display: flex;
            flex-direction: column;
            gap: 3px;
            min-width: 0;
        }

        .flag-bar-track {
            height: 6px;
            background: #e2e8f0;
            border-radius: 4px;
            overflow: hidden;
        }

        .flag-bar {
            height: 100%;
            width: 0;
            background: linear-gradient(90deg, #3b82f6, #2563eb);
            border-radius: 4px;
            transition: width 1.2s cubic-bezier(0.22, 1, 0.36, 1);
        }

        .flag-item .count {
            font-weight: 900;
            color: #1e40af;
            font-size: 0.85rem;
            font-variant-numeric: tabular-nums;
            min-width: 52px;
            text-align: left;
        }

        .flag-item .label {
            font-size: 0.78rem;
            font-weight: 700;
            color: #1e3a8a;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        /* Box */
        .daily-avg-box {
            position: relative;
            background: linear-gradient(135deg, #0ea5e9 0%, #2563eb 60%, #1e40af 100%);
            color: #fff;
            text-align: center;
            border-radius: 8px;
            overflow: hidden;
            height: 100%;
            min-height: 130px;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            padding: 12px 8px;
            box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
            transition: transform 0.3s ease, box-shadow 0.3s ease;
        }

        .daily-avg-box::before {
            content: '';
            position: absolute;
            top: -50%;
            right: -30%;
            width: 120px;
            height: 120px;
            background: radial-gradient(circle, rgba(255, 255, 255, 0.25), transparent 70%);
            border-radius: 50%;
            pointer-events: none;
        }

        .daily-avg-box:hover {
            transform: translateY(-3px) scale(1.01);
            box-shadow: 0 8px 20px rgba(37, 99, 235, 0.4);
        }

        .daily-avg-icon {
            position: relative;
            z-index: 1;
            width: 38px;
            height: 38px;
            border-radius: 50%;
            background: rgba(255, 255, 255, 0.2);
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 1.1rem;
            margin-bottom: 6px;
        }

        .daily-avg-content {
            position: relative;
            z-index: 1;
        }

        .daily-avg-label {
            font-size: 0.72rem;
            font-weight: 700;
            opacity: 0.95;
            letter-spacing: 0.2px;
            margin-bottom: 2px;
        }

        .daily-avg-number {
            font-size: 1.9rem;
            font-weight: 900;
            line-height: 1.1;
            text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
        }

        .daily-avg-sub {
            font-size: 0.62rem;
            opacity: 0.85;
            margin-top: 4px;
        }

        .daily-avg-sub span { font-weight: 800; }

        /* Gender Stats */
        .gender-container {
            display: flex;
            justify-content: center;
            align-items: flex-end;
            gap: 20px;
            position: relative;
        }

        .gender-chart-center {
            width: 110px;
            height: 110px;
            border-radius: 50%;
            background: conic-gradient(#ec4899 0% 49%, #3b82f6 49% 100%);
            display: flex;
            align-items: center;
            justify-content: center;
            color: white;
            font-weight: bold;
            position: relative;
            box-shadow: 0 6px 16px rgba(0, 0, 0, 0.18);
            animation: genderDonutIn 0.9s cubic-bezier(0.22, 1, 0.36, 1) both;
        }

        @keyframes genderDonutIn {
            from { transform: scale(0); opacity: 0; }
            to { transform: scale(1); opacity: 1; }
        }

        .gender-chart-center::after {
            content: '';
            position: absolute;
            width: 70px;
            height: 70px;
            background: #fff;
            border-radius: 50%;
            z-index: 1;
            box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.08);
        }

        .gender-center-label {
            position: relative;
            z-index: 2;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            line-height: 1.1;
        }

        .gender-center-num {
            font-size: 1rem;
            font-weight: 900;
            color: #1e3a8a;
            font-variant-numeric: tabular-nums;
        }

        .gender-center-text {
            font-size: 0.5rem;
            color: #64748b;
            font-weight: 700;
            margin-top: 2px;
        }

        .gender-item { text-align: center; }
        .gender-item img { width: 40px; height: 48px; object-fit: contain; margin-bottom: 3px; }
        .gender-item .count { font-weight: bold; color: #1e40af; font-size: 1.1rem; }
        .gender-item .count.female { color: #e91e63; }

        /* Chart Placeholder */
        .chart-placeholder {
            width: 100%;
            height: 140px;
            background: linear-gradient(180deg, #f0f9ff 0%, #e0f2fe 100%);
            border-bottom: 1px solid #bda;
            position: relative;
            display: flex;
            align-items: flex-end;
            padding: 0 10px;
        }

        .chart-line {
            width: 100%;
            height: 100px;
            background: rgba(236, 72, 153, 0.5);
            clip-path: polygon(0 100%, 10% 80%, 20% 85%, 30% 60%, 40% 90%, 50% 40%, 60% 50%, 70% 20%, 80% 30%, 90% 10%, 100% 60%, 100% 100%);
        }

        /* Region List */
        .region-list {
            list-style: none;
            padding: 10px;
            margin: 0;
            display: flex;
            flex-direction: column;
            gap: 15px;
            justify-content: center;
        }

        .region-item {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 18px 15px;
            border-radius: 12px;
            background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
            border: 2px solid #e2e8f0;
            box-shadow: 0 3px 6px rgba(0, 0, 0, 0.08);
            transition: all 0.3s ease;
        }

        .region-item h4 { margin: 0; font-size: 1.25rem; font-weight: 800; color: #1e40af; letter-spacing: 0.3px; }
        .region-item .sub { font-size: 0.95rem; color: #64748b; font-weight: 600; }
        .region-item .val { font-weight: 900; color: #059669; font-size: 1.6rem; min-width: 100px; text-align: center; padding: 10px 15px; background: linear-gradient(135deg, #ffffff 0%, #f0fdf4 100%); border-radius: 10px; border: 2px solid #d1fae5; }

        /* Pie Chart Styles */
        .pie-section { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; padding: 12px 8px; min-width: 200px; }
        .pie-chart-container { width: 160px; height: 160px; position: relative; margin: 8px auto; }
        .pie-chart { width: 100%; height: 100%; border-radius: 50%; position: relative; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); cursor: pointer; }
        .pie-chart-svg { width: 100%; height: 100%; border-radius: 50%; }
        .pie-chart-segment { cursor: pointer; transition: opacity 0.2s ease, filter 0.2s ease; }
        .pie-chart-segment:hover { opacity: 0.8; filter: brightness(1.1); }
        .pie-chart-tooltip { position: absolute; background: rgba(15, 23, 42, 0.95); color: white; padding: 6px 10px; border-radius: 6px; font-size: 0.65rem; pointer-events: none; z-index: 1000; white-space: nowrap; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3); opacity: 0; transform: translate(-50%, -100%) translateY(-8px); transition: opacity 0.2s ease, transform 0.2s ease; }
        .pie-chart-tooltip.show { opacity: 1; }
        .pie-chart::after { content: ''; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 55%; height: 55%; background: white; border-radius: 50%; box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1); }
        .pie-legend { list-style: none; padding: 0; margin: 10px 0 0 0; font-size: 0.85rem; display: block; max-height: 320px; overflow-y: auto; width: 100%; border-radius: 8px; border: 1px solid #e2e8f0; }
        .pie-legend::-webkit-scrollbar { width: 4px; }
        .pie-legend::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 2px; }
    

/* block 7 */

        /* Section */
        #data-analysis-page .page-loader {
            position: fixed; top: 0; left: 0; width: 100%; height: 100%;
            background: transparent; display: flex; flex-direction: column;
            justify-content: center; align-items: center; z-index: 9999;
            transition: opacity 0.4s ease, visibility 0.4s ease;
        }

        #data-analysis-page .page-loader.hidden { opacity: 0; visibility: hidden; pointer-events: none; }
        #data-analysis-page .loader-percent-wrapper { position: relative; width: 140px; height: 140px; display: flex; align-items: center; justify-content: center; }
        #data-analysis-page .loader-circle-svg { width: 100%; height: 100%; transform: rotate(-90deg); }
        #data-analysis-page .loader-circle-bg { fill: none; stroke: #e2e8f0; stroke-width: 8; stroke-dasharray: 12 8; }
        #data-analysis-page .loader-circle-progress { fill: none; stroke: #4f46e5; stroke-width: 8; stroke-linecap: round; stroke-dasharray: 12 8; transition: stroke-dashoffset 0.15s ease-out; }
        #data-analysis-page .loader-percent-text { position: absolute; font-size: 1.75rem; font-weight: 800; color: #3730a3; letter-spacing: -0.5px; }
        #data-analysis-page .loader-text { margin-top: 20px; color: #64748b; font-size: 0.95rem; font-weight: 600; }

        .live-badge {
            background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
            color: white; padding: 10px 18px; border-radius: 25px;
            box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
            display: flex; align-items: center; gap: 8px; z-index: 10;
            font-size: 0.9rem; font-weight: 700; letter-spacing: 0.5px;
            animation: pulse-live-strong 1.5s infinite, shake-live 3s infinite;
            transform-origin: center;
        }

        .live-badge::before { content: ''; width: 10px; height: 10px; background: #ffffff; border-radius: 50%; display: inline-block; animation: blink-live-strong 0.8s infinite, glow-live 1.5s infinite; box-shadow: 0 0 8px rgba(255, 255, 255, 0.8); }

        @keyframes pulse-live-strong { 0%, 100% { box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4), 0 0 0 0 rgba(239, 68, 68, 0.7); transform: scale(1); } 50% { box-shadow: 0 6px 24px rgba(239, 68, 68, 0.7), 0 0 0 8px rgba(239, 68, 68, 0); transform: scale(1.05); } }
        @keyframes blink-live-strong { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.2; transform: scale(0.8); } }
        @keyframes glow-live { 0%, 100% { box-shadow: 0 0 8px rgba(255, 255, 255, 0.8), 0 0 12px rgba(255, 255, 255, 0.6); } 50% { box-shadow: 0 0 12px rgba(255, 255, 255, 1), 0 0 20px rgba(255, 255, 255, 0.8); } }
        @keyframes shake-live { 0%, 100% { transform: translateX(0) translateY(0); } 25% { transform: translateX(-1px) translateY(-1px); } 75% { transform: translateX(1px) translateY(1px); } }
        @keyframes marker-pulse { 0% { transform: scale(1); opacity: 0.8; } 100% { transform: scale(2.5); opacity: 0; } }

        /* News Ticker Animations */
        @keyframes pulse-icon { 0%, 100% { transform: scale(1); box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); } 50% { transform: scale(1.05); box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2); } }
        @keyframes shake-icon { 0%, 100% { transform: rotate(0deg); } 10%, 30% { transform: rotate(-10deg); } 20%, 40% { transform: rotate(10deg); } 50% { transform: rotate(0deg); } }
        /* Section */
        @keyframes ticker-slide { 0% { transform: translate(-50%, -50%); } 100% { transform: translate(0%, -50%); } }

        .news-ticker-wrapper { margin-top: 22px; overflow: hidden; border-radius: 16px; box-shadow: 0 8px 24px rgba(15, 23, 42, 0.14); }
        .news-ticker-container { background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 45%, #2563eb 100%); padding: 16px 0; display: flex; align-items: center; position: relative; overflow: hidden; border: 1px solid rgba(255, 255, 255, 0.08); }
        .news-ticker-container::before { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.06) 50%, transparent 100%); animation: ticker-shine 6s ease-in-out infinite; pointer-events: none; }
        @keyframes ticker-shine { 0%, 100% { transform: translateX(-100%); } 50% { transform: translateX(100%); } }
        .news-ticker-icon { position: absolute; right: 20px; z-index: 3; background: rgba(255, 255, 255, 0.22); backdrop-filter: blur(10px); width: 45px; height: 45px; border-radius: 50%; display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.18); animation: pulse-icon 2s ease-in-out infinite; }
        .news-ticker-icon i { color: #ffffff; font-size: 1.2rem; animation: shake-icon 3s ease-in-out infinite; }
        .news-ticker-content { flex: 1; margin-right: 80px; overflow: hidden; position: relative; height: 32px; display: flex; align-items: center; direction: rtl; }
        .news-ticker-text { color: #ffffff; font-size: 1.1rem; font-weight: 600; letter-spacing: 0.3px; position: absolute; left: 0; top: 50%; display: inline-flex; align-items: center; white-space: nowrap; direction: ltr; transform: translate(0%, -50%); animation: ticker-slide 60s linear infinite; will-change: transform; text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25); }
        .news-ticker-text .ticker-item { direction: rtl; unicode-bidi: isolate; }
        .news-ticker-text .ticker-separator { margin: 0 22px; color: #fde68a; opacity: 0.9; font-size: 1rem; }

        .chart-placeholder path {
            transition: opacity 1s ease-out, transform 1s ease-out;
        }

        /* Number Animations */
        .number, .count, .val, .stat-val, .daily-avg-number, .countries-number, .gender-percent, .monthly-bar-val, .gender-center-num {
            transition: transform 0.3s ease-out;
            font-variant-numeric: tabular-nums;
        }

        .number.animating, .count.animating, .val.animating {
            transform: scale(1.1);
        }
    

/* block 8 */

        @media (max-width: 768px) {
            #data-analysis-page { padding-right: 15px !important; padding-left: 15px !important; }
        }

        @media (max-width: 768px) {
            .days-counter-card { position: relative; top: auto; right: auto; margin-bottom: 8px; width: 100%; min-width: auto; }
            .live-badge { position: relative; top: auto; right: auto; margin: 8px auto; display: inline-flex; }
        }

        @media (max-width: 992px) {
            .date-filter-wrapper { flex-direction: column; align-items: stretch; gap: 8px; }
            .date-filter-header { font-size: 0.8rem; justify-content: center; margin-left: 0; margin-bottom: 4px; display: none; }
            .date-filter-main-controls { flex-wrap: wrap; justify-content: center; }
            .quick-filters { justify-content: center; border-right: none; padding-right: 0; order: 3; width: 100%; border-top: 1px solid #f1f5f9; padding-top: 6px; }
        }

        @media (max-width: 600px) {
            .date-filter-inputs { flex-direction: row; flex-wrap: wrap; gap: 4px; }
            .date-input-group { width: 48%; flex-direction: column; align-items: flex-start; }
            .date-input-group label { font-size: 0.65rem; }
            .date-input { width: 100%; font-size: 0.7rem; }
            .date-filter-actions { width: 100%; margin-top: 4px; }
            .btn-apply-filter, .btn-reset-filter { flex: 1; justify-content: center; }
        }

        @media (max-width: 1400px) {
            .data-analysis-container { max-width: calc(100% - 190px); }
            .stats-header { grid-template-columns: repeat(3, 1fr); }
        }

        @media (max-width: 1200px) {
            .data-analysis-container { max-width: calc(100% - 190px); padding: 8px; }
            .stats-header { grid-template-columns: repeat(3, 1fr); }
            .row-grid-4, .row-grid-map { grid-template-columns: repeat(2, 1fr); }
            .additional-stats-list { grid-template-columns: repeat(2, 1fr); }
            .map-pie-container { flex-direction: column; height: auto; }
            .map-section { min-height: 200px; }
            /* Section */
            .map-background-svg img { object-fit: cover; }
            .countries-count-card { min-height: 120px; }
            /* Section */
            .gender-container { justify-content: space-between; gap: 10px; }
        }

        @media (max-width: 768px) {
            #data-analysis-page { padding-right: 15px !important; padding-left: 15px !important; }
            .data-analysis-container { max-width: 100%; padding: 8px 10px; margin: 0; width: 100%; overflow-x: hidden; }
            .data-nav-pills { padding: 3px 6px; gap: 4px; margin-bottom: 8px; }
            .data-nav-pill { padding: 5px 10px; font-size: 0.65rem; gap: 4px; }
            .data-nav-pill i { font-size: 0.7rem; }
            .dashboard-grid { gap: 6px; }
            .stats-header { grid-template-columns: 1fr !important; gap: 6px; box-shadow: none; margin-bottom: 12px; }
            .stat-header-box { min-height: 60px; padding: 8px 10px; flex-direction: row; justify-content: space-between; align-items: center; text-align: right; gap: 8px; overflow: visible; }
            .stat-header-box h3 { font-size: 0.75rem !important; margin: 0; order: 2; line-height: 1.1; white-space: nowrap; overflow: visible; }
            .stat-header-box .number { font-size: 1.2rem; font-weight: 800; order: 1; white-space: nowrap; overflow: visible; font-variant-numeric: tabular-nums; }
            .stat-header-box .icon { width: 26px; height: 26px; font-size: 0.8rem; margin: 0; opacity: 1; position: static; order: 3; flex-shrink: 0; }
            .days-counter-wrapper { display: flex; flex-direction: column; align-items: stretch; gap: 6px; margin-bottom: 12px; }
            .days-counter-card { width: 100%; padding: 8px; min-height: auto; justify-content: center; border-radius: 8px; }
            .days-counter-icon-small { font-size: 1rem; }
            .days-counter-number-small { font-size: 1.1rem; }
            .days-counter-label-small { font-size: 0.7rem; }
            .live-badge { width: 100%; justify-content: center; padding: 6px; font-size: 0.8rem; border-radius: 8px; }
            .row-grid-4, .row-grid-map, .additional-stats-list { grid-template-columns: 1fr !important; gap: 8px; }
            /* grid-column */
            .row-grid-map .monthly-card,
            .row-grid-map .regions-card,
            .row-grid-map .map-card { grid-column: 1 / -1 !important; }
            .monthly-bar-chart { min-height: 150px; }
            .dash-card { padding: 10px 8px; border-radius: 10px; }
            .dash-card-title { font-size: 0.85rem; padding-bottom: 4px; margin-bottom: 6px; }
            .flags-container { gap: 6px; padding: 0; }
            .flag-item { padding: 6px 8px; gap: 8px; min-width: 0; }
            .flag-item img { width: 24px; height: 24px; flex-shrink: 0; }
            .flag-item .count { font-size: 0.8rem !important; min-width: 50px; text-align: center; white-space: nowrap; font-variant-numeric: tabular-nums; }
            .flag-item .label { font-size: 0.7rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
            .flag-info { min-width: 0; flex: 1; }
            .gender-container { gap: 14px; padding: 8px 4px; justify-content: center; align-items: center; flex-direction: column; }
            .gender-item { display: flex; flex-direction: row; align-items: center; justify-content: center; gap: 10px; min-width: 0; }
            .gender-item img { width: 30px; height: 36px; margin-bottom: 0; flex-shrink: 0; }
            .gender-item .count { font-size: 1.05rem !important; white-space: nowrap; font-variant-numeric: tabular-nums; }
            .gender-percent { font-size: 0.78rem; white-space: nowrap; font-variant-numeric: tabular-nums; }
            .gender-chart-center { width: 92px !important; height: 92px !important; flex-shrink: 0; }
            .gender-chart-center::after { width: 58px !important; height: 58px !important; }
            .gender-center-num { font-size: 0.85rem !important; white-space: nowrap; font-variant-numeric: tabular-nums; }
            .gender-center-text { font-size: 0.5rem !important; white-space: nowrap; }
            .map-section, .leaflet-map-container { height: 200px !important; min-height: 200px !important; }
            .pie-chart-container { width: 140px !important; height: 140px !important; margin: 10px auto; }
            .pie-legend { font-size: 0.72rem; margin-top: 5px; max-height: 220px; overflow-x: hidden; }
            .pie-legend table { font-size: 0.72rem; width: 100%; table-layout: fixed; }
            .pie-legend th, .pie-legend td { padding: 6px 4px; word-break: break-word; }
            .region-item { padding: 8px; border-width: 1px; flex-wrap: nowrap; gap: 8px; }
            .region-item h4 { font-size: 0.85rem !important; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
            .region-item .sub { font-size: 0.75rem; white-space: nowrap; }
            .region-item .val { font-size: 1rem !important; min-width: 60px; padding: 5px 8px; white-space: nowrap; font-variant-numeric: tabular-nums; }
            .additional-stat-item { padding: 12px 10px; flex-wrap: nowrap; gap: 8px; }
            .additional-stat-item > div:first-child { min-width: 0; flex: 1 1 auto; }
            .additional-stat-item h4 { font-size: 0.88rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
            .additional-stat-item .sub { font-size: 0.78rem; white-space: nowrap; }
            .additional-stat-item .stat-val { font-size: 1.05rem !important; min-width: 72px; padding: 5px 8px; white-space: nowrap; font-variant-numeric: tabular-nums; flex-shrink: 0; display: inline-block; visibility: visible; opacity: 1; }
            .daily-avg-box { min-height: 110px; padding: 10px 6px; }
            .daily-avg-label { font-size: 0.7rem; white-space: nowrap; }
            .daily-avg-number { font-size: 1.5rem !important; white-space: nowrap; font-variant-numeric: tabular-nums; }
            .daily-avg-sub { font-size: 0.6rem; white-space: nowrap; }
            .countries-number { font-size: 2rem !important; white-space: nowrap; line-height: 1.1; overflow: visible; }
            .countries-count-card { min-height: 120px; padding: 14px 10px; }
            .countries-count-label { font-size: 0.82rem; }
            .stat-header-content { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; }
            .continent-filters { gap: 8px 10px; padding: 10px 8px !important; margin-top: 10px; justify-content: center !important; flex-wrap: wrap !important; overflow-x: visible !important; border-radius: 12px; }
            .continent-filter { padding: 8px 14px; font-size: 0.8rem; min-width: fit-content; flex: 0 0 auto; border-radius: 10px; }
            .continent-filter i { font-size: 0.9rem; gap: 5px; }
            .date-filter-wrapper { padding: 8px; gap: 8px; }
            .date-input { width: 100%; font-size: 0.75rem; padding: 4px 8px; }
            .quick-filter-btn { padding: 3px 8px; font-size: 0.7rem; }
        }

        @media (max-width: 480px) {
            .data-analysis-container { padding: 6px 8px; }
            .stat-header-box { min-height: 56px; padding: 8px 8px; }
            .stat-header-box h3 { font-size: 0.62rem; }
            .stat-header-box .number { font-size: 1rem; }
            .dash-card { padding: 8px 6px; }
            .dash-card-title { font-size: 0.8rem; }
            /* Section */
            .gender-container { gap: 10px; padding: 6px 2px; }
            .gender-item .count { font-size: 0.95rem !important; }
            .gender-percent { font-size: 0.7rem; }
            .gender-chart-center { width: 80px !important; height: 80px !important; }
            .gender-chart-center::after { width: 50px !important; height: 50px !important; }
            .gender-center-num { font-size: 0.75rem !important; }
            .gender-center-text { font-size: 0.45rem !important; }
            .gender-item img { width: 26px; height: 32px; }
            /* Section */
            .additional-stat-item { padding: 10px 8px; gap: 6px; }
            .additional-stat-item h4 { font-size: 0.78rem; }
            .additional-stat-item .sub { font-size: 0.7rem; }
            .additional-stat-item .stat-val { font-size: 0.95rem !important; min-width: 58px; padding: 4px 6px; flex-shrink: 0; display: inline-block; }
            /* Section */
            .countries-number { font-size: 1.7rem !important; }
            .countries-count-card { min-height: 110px; padding: 12px 8px; }
            .countries-count-label { font-size: 0.75rem; }
            /* Section */
            .flag-item { padding: 5px 6px; gap: 6px; }
            .flag-item .count { font-size: 0.72rem !important; min-width: 42px; }
            .flag-item .label { font-size: 0.65rem; }
            /* Section */
            .map-section, .leaflet-map-container { height: 220px !important; min-height: 220px !important; }
            /* pie legend */
            .pie-legend { font-size: 0.65rem; max-height: 180px; }
            .pie-legend table { font-size: 0.65rem; }
            /* Section */
            .region-item { padding: 8px 6px; gap: 6px; }
            .region-item h4 { font-size: 0.78rem !important; }
            .region-item .sub { font-size: 0.68rem; }
            .region-item .val { font-size: 0.9rem !important; min-width: 52px; padding: 4px 6px; }
        }

        @media (max-width: 360px) {
            .data-analysis-container { padding: 4px 6px; }
            .stat-header-box { min-height: 50px; padding: 6px 6px; gap: 6px; }
            .stat-header-box h3 { font-size: 0.55rem; }
            .stat-header-box .number { font-size: 0.95rem; }
            .stat-header-box .icon { width: 22px; height: 22px; font-size: 0.7rem; }
            .dash-card-title { font-size: 0.75rem; }
            /* Section */
            .gender-container { gap: 8px; padding: 6px 0; }
            .gender-item .count { font-size: 0.85rem !important; }
            .gender-percent { font-size: 0.65rem; }
            .gender-chart-center { width: 72px !important; height: 72px !important; }
            .gender-chart-center::after { width: 46px !important; height: 46px !important; }
            .gender-center-num { font-size: 0.7rem !important; }
            .gender-center-text { font-size: 0.4rem !important; }
            .gender-item img { width: 22px; height: 28px; }
            /* Section */
            .additional-stat-item { padding: 8px 6px; gap: 5px; }
            .additional-stat-item h4 { font-size: 0.72rem; }
            .additional-stat-item .sub { font-size: 0.65rem; }
            .additional-stat-item .stat-val { font-size: 0.85rem !important; min-width: 50px; padding: 3px 5px; flex-shrink: 0; display: inline-block; }
            /* Section */
            .countries-number { font-size: 1.4rem !important; }
            .countries-count-card { min-height: 100px; padding: 10px 6px; }
            .countries-count-label { font-size: 0.7rem; }
            /* Section */
            .flag-item .count { font-size: 0.68rem !important; min-width: 38px; }
            .flag-item .label { font-size: 0.6rem; }
            /* Section */
            .map-section, .leaflet-map-container { height: 200px !important; min-height: 200px !important; }
            .pie-legend { font-size: 0.6rem; max-height: 160px; }
            .region-item { padding: 6px 5px; }
            .region-item h4 { font-size: 0.72rem !important; }
            .region-item .val { font-size: 0.85rem !important; min-width: 46px; padding: 3px 5px; }
        }

        @media (max-width: 768px) {
            .news-ticker-icon { width: 35px; height: 35px; right: 10px; }
            .news-ticker-icon i { font-size: 1rem; }
            .news-ticker-content { margin-right: 55px; }
            .news-ticker-text { font-size: 0.95rem; }
            .ticker-separator { margin: 0 15px; }
        }
    

/* block 9 */

/* Reports Tab Styles */

.reports-container {
    padding: 16px;
    direction: rtl;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* ===== Header ===== */
.reports-header {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 24px;
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 50%, #3b82f6 100%);
    border-radius: 16px;
    color: white;
    margin-bottom: 24px;
    box-shadow: 0 8px 24px rgba(30, 58, 138, 0.25);
    position: relative;
    overflow: hidden;
}

.reports-header::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 50%;
    pointer-events: none;
}

.reports-header::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -5%;
    width: 200px;
    height: 200px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    pointer-events: none;
}

.reports-header-icon {
    width: 72px;
    height: 72px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.reports-header-content {
    flex: 1;
    position: relative;
    z-index: 1;
    min-width: 0;
}

.reports-title {
    font-size: 1.75rem;
    font-weight: 800;
    margin: 0 0 6px 0;
    letter-spacing: -0.3px;
}

.reports-subtitle {
    font-size: 0.95rem;
    opacity: 0.9;
    margin: 0;
    font-weight: 400;
    line-height: 1.5;
}

/* ===== Header Status Indicator ===== */
.reports-header-status {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    position: relative;
    z-index: 1;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: white;
    flex-shrink: 0;
}

.status-dot.loading {
    background: #fbbf24;
    animation: pulse-dot 1.5s ease-in-out infinite;
}

.status-dot.success {
    background: #34d399;
    box-shadow: 0 0 8px rgba(52, 211, 153, 0.6);
}

.status-dot.warning {
    background: #fbbf24;
    animation: pulse-dot 2s ease-in-out infinite;
}

.status-dot.error {
    background: #f87171;
}

@keyframes pulse-dot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.6; transform: scale(1.3); }
}

/* ===== Panel Container ===== */
.reports-panel {
    background: #ffffff;
    border-radius: 16px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
    overflow: hidden;
}

/* ===== Sub Tabs ===== */
.reports-sub-tabs {
    display: flex;
    background: #f8fafc;
    border-bottom: 2px solid #e2e8f0;
    padding: 0 16px;
    gap: 4px;
    overflow-x: auto;
}

.reports-sub-tab {
    padding: 14px 20px;
    background: transparent;
    border: none;
    color: #64748b;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    font-family: inherit;
}

.reports-sub-tab:hover {
    color: #1e40af;
    background: rgba(30, 64, 175, 0.05);
}

.reports-sub-tab.active {
    color: #1e40af;
}

.reports-sub-tab.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    right: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, #1e40af, #3b82f6);
    border-radius: 2px 2px 0 0;
}

.reports-sub-content {
    display: none;
    padding: 20px;
}

.reports-sub-content.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ===== Toolbar ===== */
.reports-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding: 12px 16px;
    background: #f8fafc;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    gap: 12px;
    flex-wrap: wrap;
}

.reports-toolbar-info {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #475569;
    font-size: 0.88rem;
    flex: 1;
    min-width: 200px;
}

.reports-toolbar-info i {
    color: #1e40af;
}

.reports-toolbar-actions {
    display: flex;
    gap: 8px;
}

/* ===== Buttons ===== */
.report-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 16px;
    border: none;
    border-radius: 10px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
    white-space: nowrap;
    color: white;
}

.report-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.report-btn-primary {
    background: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%);
    box-shadow: 0 2px 8px rgba(30, 64, 175, 0.3);
}

.report-btn-primary:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(30, 64, 175, 0.4);
}

.report-btn-success {
    background: linear-gradient(135deg, #047857 0%, #10b981 100%);
    box-shadow: 0 2px 8px rgba(5, 150, 105, 0.3);
}

.report-btn-success:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.4);
}

.report-btn-secondary {
    background: #e2e8f0;
    color: #475569;
}

.report-btn-secondary:hover:not(:disabled) {
    background: #cbd5e1;
}

.report-btn-excel {
    background: linear-gradient(135deg, #047857 0%, #10b981 100%);
    box-shadow: 0 2px 8px rgba(5, 150, 105, 0.3);
}

.report-btn-excel:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.4);
}

.report-btn-csv {
    background: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%);
    box-shadow: 0 2px 8px rgba(30, 64, 175, 0.3);
}

.report-btn-csv:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(30, 64, 175, 0.4);
}

.report-btn-json {
    background: linear-gradient(135deg, #7c3aed 0%, #a855f7 100%);
    box-shadow: 0 2px 8px rgba(124, 58, 237, 0.3);
}

.report-btn-json:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(124, 58, 237, 0.4);
}


/* ===== Table ===== */
.reports-table-wrapper {
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
    background: white;
}

.reports-table-container {
    max-height: 500px;
    overflow: auto;
}

.reports-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.82rem;
}

.reports-table thead {
    position: sticky;
    top: 0;
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
    color: white;
    z-index: 5;
}

.reports-table th {
    padding: 12px 10px;
    text-align: right;
    font-weight: 700;
    font-size: 0.78rem;
    white-space: nowrap;
    border-bottom: 2px solid #1e3a8a;
}

.reports-table td {
    padding: 10px;
    border-bottom: 1px solid #f1f5f9;
    color: #334155;
    white-space: nowrap;
}

.reports-table tbody tr {
    transition: background 0.15s;
}

.reports-table tbody tr:hover {
    background: #f8fafc;
}

.reports-table tbody tr:nth-child(even) {
    background: #fafbfc;
}

.reports-table tbody tr:nth-child(even):hover {
    background: #f1f5f9;
}

.reports-table-notice {
    padding: 12px;
    text-align: center;
    background: #fef3c7;
    color: #92400e;
    font-size: 0.85rem;
    border-top: 1px solid #e2e8f0;
}

/* ===== Scrollbar ===== */
.reports-table-container::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

.reports-table-container::-webkit-scrollbar-track {
    background: #f1f5f9;
}

.reports-table-container::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

.reports-table-container::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* ===== Empty State ===== */
.reports-empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #94a3b8;
}

.reports-empty-state i {
    font-size: 3.5rem;
    margin-bottom: 16px;
    opacity: 0.5;
    display: block;
}

.reports-empty-state h3 {
    font-size: 1.1rem;
    color: #475569;
    margin: 0 0 6px 0;
    font-weight: 700;
}

.reports-empty-state p {
    font-size: 0.9rem;
    margin: 0;
    color: #94a3b8;
}

/* ===== Filters Grid ===== */
.reports-filters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
    margin-bottom: 20px;
}

.filter-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
}

.filter-card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: linear-gradient(135deg, #ffffff 0%, #f1f5f9 100%);
    border-bottom: 1px solid #e2e8f0;
}

.filter-card-header i {
    color: #1e40af;
    font-size: 1rem;
}

.filter-card-header h4 {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 700;
    color: #1e293b;
}

.filter-card-body {
    padding: 16px;
}

.quick-filters-reports {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.quick-filter-reports-btn {
    padding: 6px 12px;
    background: white;
    border: 1px solid #e2e8f0;
    color: #475569;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
}

.quick-filter-reports-btn:hover {
    background: #f1f5f9;
    border-color: #cbd5e1;
}

.quick-filter-reports-btn.active {
    background: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%);
    color: white;
    border-color: #1e40af;
}

.date-filter-inputs-reports {
    display: flex;
    gap: 8px;
}

.date-input-group-reports {
    flex: 1;
}

.date-input-group-reports label {
    display: block;
    font-size: 0.78rem;
    color: #64748b;
    margin-bottom: 4px;
    font-weight: 600;
}

.date-input-reports {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.85rem;
    font-family: inherit;
    direction: ltr;
    text-align: right;
    background: white;
    transition: border 0.2s;
}

.date-input-reports:focus {
    outline: none;
    border-color: #1e40af;
    box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}

.filter-select-reports {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.85rem;
    font-family: inherit;
    background: white;
    min-height: 140px;
    cursor: pointer;
}

.filter-select-reports:focus {
    outline: none;
    border-color: #1e40af;
}

.filter-hint {
    font-size: 0.72rem;
    color: #94a3b8;
    margin: 8px 0 0 0;
    line-height: 1.4;
}

.filter-radio-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.filter-radio-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.88rem;
    transition: all 0.2s;
}

.filter-radio-item:hover {
    background: #f1f5f9;
}

.filter-radio-item input[type="radio"] {
    accent-color: #1e40af;
    cursor: pointer;
}

.reports-filters-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
    padding: 16px;
    background: #f8fafc;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
}

/* ===== Summary Cards ===== */
.reports-summary-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 14px;
}

.summary-stat-card {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 16px;
    text-align: center;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

.summary-stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, #1e40af, #3b82f6);
}

.summary-stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.summary-stat-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 10px;
    color: #1e40af;
    font-size: 1.2rem;
}

.summary-stat-value {
    font-size: 1.8rem;
    font-weight: 800;
    color: #1e3a8a;
    margin: 4px 0;
    letter-spacing: -0.5px;
}

.summary-stat-label {
    font-size: 0.85rem;
    color: #64748b;
    font-weight: 500;
}

.summary-stat-sublabel {
    font-size: 0.72rem;
    color: #94a3b8;
    margin-top: 4px;
}

/* ===== Export Bar ===== */
.reports-export-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border-top: 2px solid #bfdbfe;
    flex-wrap: wrap;
    gap: 12px;
}

.reports-export-bar-info {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #1e3a8a;
    font-size: 0.9rem;
}

.reports-export-bar-info i {
    color: #047857;
    font-size: 1.1rem;
}

.reports-export-bar-info strong {
    font-size: 1.1rem;
    color: #047857;
    font-weight: 800;
}

.reports-export-bar-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .reports-header {
        flex-direction: column;
        text-align: center;
        gap: 12px;
        padding: 20px;
    }

    .reports-title {
        font-size: 1.4rem;
    }

    .reports-header-status {
        align-self: center;
    }

    .reports-sub-tabs {
        padding: 0 8px;
    }

    .reports-sub-tab {
        padding: 12px 14px;
        font-size: 0.82rem;
    }

    .reports-toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .reports-export-bar {
        flex-direction: column;
        align-items: stretch;
    }

    .reports-export-bar-actions {
        justify-content: center;
    }

    .reports-export-bar-actions .report-btn {
        flex: 1;
        justify-content: center;
    }

    .date-filter-inputs-reports {
        flex-direction: column;
    }
}

/* ===== Dark Mode ===== */
body.dark-mode .reports-panel {
    background: #1e293b;
    border-color: #334155;
}

body.dark-mode .reports-sub-tabs {
    background: #0f172a;
    border-color: #334155;
}

body.dark-mode .reports-sub-tab {
    color: #94a3b8;
}

body.dark-mode .reports-sub-tab:hover {
    color: #93c5fd;
    background: rgba(30, 64, 175, 0.2);
}

body.dark-mode .reports-sub-tab.active {
    color: #93c5fd;
}

body.dark-mode .reports-toolbar {
    background: #0f172a;
    border-color: #334155;
}

body.dark-mode .reports-toolbar-info {
    color: #cbd5e1;
}

body.dark-mode .reports-table {
    background: #1e293b;
}

body.dark-mode .reports-table td {
    color: #cbd5e1;
    border-color: #334155;
}

body.dark-mode .reports-table tbody tr:hover {
    background: #0f172a;
}

body.dark-mode .reports-table tbody tr:nth-child(even) {
    background: #172033;
}

body.dark-mode .filter-card {
    background: #0f172a;
    border-color: #334155;
}

body.dark-mode .filter-card-header {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border-color: #334155;
}

body.dark-mode .filter-card-header h4 {
    color: #e2e8f0;
}

body.dark-mode .filter-radio-item {
    background: #1e293b;
    border-color: #334155;
    color: #cbd5e1;
}

body.dark-mode .filter-radio-item:hover {
    background: #334155;
}

body.dark-mode .date-input-reports,
body.dark-mode .filter-select-reports {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

body.dark-mode .quick-filter-reports-btn {
    background: #1e293b;
    border-color: #334155;
    color: #cbd5e1;
}

body.dark-mode .quick-filter-reports-btn:hover {
    background: #334155;
}

body.dark-mode .quick-filter-reports-btn.active {
    background: linear-gradient(135deg, #3b82f6 0%, #60a5fa 100%);
    color: white;
    border-color: #3b82f6;
}

body.dark-mode .reports-filters-actions {
    background: #0f172a;
    border-color: #334155;
}

body.dark-mode .reports-empty-state h3 {
    color: #cbd5e1;
}

body.dark-mode .summary-stat-card {
    background: #1e293b;
    border-color: #334155;
}

body.dark-mode .summary-stat-icon {
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
    color: #93c5fd;
}

body.dark-mode .summary-stat-value {
    color: #93c5fd;
}

body.dark-mode .summary-stat-label {
    color: #94a3b8;
}

body.dark-mode .reports-export-bar {
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
    border-color: #3b82f6;
}

body.dark-mode .reports-export-bar-info {
    color: #dbeafe;
}

body.dark-mode .reports-export-bar-info strong {
    color: #6ee7b7;
}


/* block 10 */

    /* Education Stats Custom Styles */
    .edu-grid {
        display: flex;
        flex-direction: column;
        gap: 12px;
        padding: 5px;
    }

    /* marker edu-filters-bar */
    .edu-filters-bar {
        position: relative;
        display: flex;
        flex-wrap: wrap;
        align-items: flex-end;
        gap: 14px 18px;
        padding: 14px 16px;
        border-radius: 16px;
        background:
            linear-gradient(135deg, rgba(16, 185, 129, 0.08) 0%, rgba(14, 165, 233, 0.06) 50%, rgba(99, 102, 241, 0.05) 100%),
            #ffffff;
        border: 1px solid rgba(16, 185, 129, 0.22);
        box-shadow: 0 8px 24px -12px rgba(15, 23, 42, 0.18);
        overflow: hidden;
        animation: eduFiltersIn 0.45s ease-out;
    }

    @keyframes eduFiltersIn {
        from { opacity: 0; transform: translateY(-8px); }
        to { opacity: 1; transform: translateY(0); }
    }

    .edu-filters-bar-glow {
        position: absolute;
        inset: auto -20% -60% auto;
        width: 220px;
        height: 220px;
        border-radius: 50%;
        background: radial-gradient(circle, rgba(16, 185, 129, 0.18), transparent 70%);
        pointer-events: none;
    }

    .edu-filters-lead {
        display: flex;
        align-items: center;
        gap: 10px;
        min-width: 180px;
        z-index: 1;
    }

    .edu-filters-icon {
        width: 40px;
        height: 40px;
        border-radius: 12px;
        display: flex;
        align-items: center;
        justify-content: center;
        background: linear-gradient(135deg, #10b981 0%, #0ea5e9 100%);
        color: #fff;
        box-shadow: 0 6px 14px -6px rgba(16, 185, 129, 0.7);
        flex-shrink: 0;
    }

    .edu-filters-lead-text {
        display: flex;
        flex-direction: column;
        gap: 2px;
    }

    .edu-filters-lead-text strong {
        font-size: 0.95rem;
        color: #0f172a;
        font-weight: 800;
    }

    .edu-filters-lead-text span {
        font-size: 0.75rem;
        color: #64748b;
        font-weight: 600;
    }

    .edu-filters-fields {
        display: flex;
        flex-wrap: wrap;
        align-items: flex-end;
        gap: 10px;
        flex: 1;
        z-index: 1;
    }

    .edu-filter-field {
        display: flex;
        flex-direction: column;
        gap: 5px;
        min-width: 140px;
    }

    .edu-filter-lang {
        min-width: 180px;
        flex: 1.2;
    }

    .edu-filter-date {
        min-width: 150px;
        flex: 1;
    }

    .edu-filter-field label {
        font-size: 0.75rem;
        font-weight: 700;
        color: #475569;
        display: flex;
        align-items: center;
        gap: 6px;
    }

    .edu-filter-field label i {
        color: #10b981;
        font-size: 0.8rem;
    }

    .edu-filter-select,
    .edu-filter-input {
        width: 100%;
        padding: 9px 12px;
        border: 1px solid #dbe3ee;
        border-radius: 10px;
        background: #fff;
        color: #0f172a;
        font-size: 0.88rem;
        font-weight: 600;
        font-family: inherit;
        transition: border-color 0.2s, box-shadow 0.2s;
        outline: none;
    }

    .edu-filter-select:focus,
    .edu-filter-input:focus {
        border-color: #10b981;
        box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.18);
    }

    .edu-filters-actions {
        display: flex;
        align-items: center;
        gap: 8px;
        z-index: 1;
        margin-inline-start: auto;
    }

    .edu-filter-btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 6px;
        border: none;
        border-radius: 10px;
        padding: 10px 14px;
        font-family: inherit;
        font-size: 0.85rem;
        font-weight: 700;
        cursor: pointer;
        transition: transform 0.15s ease, box-shadow 0.2s, background 0.2s;
    }

    .edu-filter-btn:active {
        transform: scale(0.97);
    }

    .edu-filter-btn-apply {
        background: linear-gradient(135deg, #059669 0%, #0ea5e9 100%);
        color: #fff;
        box-shadow: 0 8px 16px -8px rgba(14, 165, 233, 0.8);
        min-width: 100px;
    }

    .edu-filter-btn-apply:hover {
        box-shadow: 0 10px 20px -8px rgba(5, 150, 105, 0.85);
    }

    .edu-filter-btn-reset {
        width: 40px;
        height: 40px;
        padding: 0;
        background: #f1f5f9;
        color: #475569;
        border: 1px solid #e2e8f0;
    }

    .edu-filter-btn-reset:hover {
        background: #e2e8f0;
        color: #0f172a;
    }

    .edu-filter-btn-pdf {
        background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
        color: #fff;
        box-shadow: 0 8px 16px -8px rgba(220, 38, 38, 0.75);
        min-width: 74px;
    }

    .edu-filter-btn-pdf:hover {
        box-shadow: 0 10px 20px -8px rgba(185, 28, 28, 0.85);
    }

    .edu-filter-btn-pdf.is-loading {
        opacity: 0.75;
        pointer-events: none;
    }

    /* PDF */
    #stats-pdf-loading-overlay {
        position: fixed;
        inset: 0;
        z-index: 99999;
        display: none;
        align-items: center;
        justify-content: center;
        background: rgba(15, 23, 42, 0.55);
        backdrop-filter: blur(3px);
    }

    #stats-pdf-loading-overlay .stats-pdf-loading-card {
        background: #ffffff;
        border-radius: 18px;
        padding: 28px 36px;
        min-width: 280px;
        text-align: center;
        box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
        direction: rtl;
    }

    #stats-pdf-loading-overlay .stats-pdf-spinner {
        width: 48px;
        height: 48px;
        margin: 0 auto 16px;
        border: 4px solid #e2e8f0;
        border-top-color: #dc2626;
        border-radius: 50%;
        animation: statsPdfSpin 0.8s linear infinite;
    }

    @keyframes statsPdfSpin {
        to { transform: rotate(360deg); }
    }

    #stats-pdf-loading-overlay .stats-pdf-loading-title {
        font-size: 1.05rem;
        font-weight: 800;
        color: #0f172a;
        margin-bottom: 6px;
    }

    #stats-pdf-loading-overlay .stats-pdf-loading-sub {
        font-size: 0.85rem;
        font-weight: 600;
        color: #64748b;
    }

    #stats-pdf-capture-root {
        position: fixed;
        left: -12000px;
        top: 0;
        width: 1000px;
        background: #ffffff;
        z-index: -1;
        pointer-events: none;
    }

    .edu-filter-count {
        min-width: 52px;
        height: 40px;
        padding: 0 12px;
        border-radius: 999px;
        display: flex;
        align-items: center;
        justify-content: center;
        background: rgba(15, 23, 42, 0.04);
        border: 1px dashed #cbd5e1;
        color: #0f172a;
        font-weight: 800;
        font-size: 0.9rem;
        font-variant-numeric: tabular-nums;
    }

    .edu-filter-count.is-active {
        background: linear-gradient(135deg, rgba(16, 185, 129, 0.15), rgba(14, 165, 233, 0.12));
        border-style: solid;
        border-color: rgba(16, 185, 129, 0.35);
        color: #047857;
    }

    body.dark-mode .edu-filters-bar {
        background:
            linear-gradient(135deg, rgba(16, 185, 129, 0.12) 0%, rgba(14, 165, 233, 0.08) 100%),
            #1e293b;
        border-color: rgba(16, 185, 129, 0.28);
    }

    body.dark-mode .edu-filters-lead-text strong { color: #f8fafc; }
    body.dark-mode .edu-filters-lead-text span { color: #94a3b8; }
    body.dark-mode .edu-filter-field label { color: #cbd5e1; }
    body.dark-mode .edu-filter-select,
    body.dark-mode .edu-filter-input {
        background: #0f172a;
        border-color: #334155;
        color: #f1f5f9;
    }
    body.dark-mode .edu-filter-btn-reset {
        background: #334155;
        border-color: #475569;
        color: #e2e8f0;
    }
    body.dark-mode .edu-filter-count {
        background: rgba(255, 255, 255, 0.04);
        border-color: #475569;
        color: #e2e8f0;
    }

    @media (max-width: 900px) {
        .edu-filters-bar {
            align-items: stretch;
        }
        .edu-filters-actions {
            margin-inline-start: 0;
            width: 100%;
        }
        .edu-filter-btn-apply {
            flex: 1;
        }
    }

    /* Levels Cards */
    .edu-levels-row {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 12px;
    }

    .edu-level-card {
        background: white;
        border-radius: 12px;
        padding: 16px;
        text-align: center;
        box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
        border-bottom: 4px solid #eee;
        transition: transform 0.3s ease;
    }

    .edu-level-card:hover {
        transform: translateY(-8px);
        box-shadow: 0 12px 20px -5px rgba(0, 0, 0, 0.15);
        cursor: help;
    }

    .edu-level-card.l1 {
        border-color: #6366f1;
    }

    .edu-level-card.l2 {
        border-color: #0ea5e9;
    }

    .edu-level-card.l3 {
        border-color: #10b981;
    }

    .edu-level-card.l4 {
        border-color: #f59e0b;
    }

    .edu-level-card h3 {
        font-size: 0.85rem;
        color: #64748b;
        margin-bottom: 8px;
        font-weight: 600;
    }

    .edu-level-number {
        font-size: 1.5rem;
        font-weight: 800;
        color: #1e293b;
        margin-bottom: 4px;
    }

    .edu-level-pct {
        font-size: 0.85rem;
        font-weight: 700;
        color: #475569;
        background: #f1f5f9;
        padding: 2px 10px;
        border-radius: 20px;
        display: inline-block;
        margin-top: 5px;
        border: 1px solid #e2e8f0;
    }

    /* Tables Row */
    .edu-tables-row {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }

    .edu-card {
        background: white;
        border-radius: 12px;
        padding: 16px;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
        border: 1px solid #e2e8f0;
    }

    .edu-card-title {
        font-size: 1rem;
        font-weight: 700;
        color: #1e3a8a;
        margin-bottom: 12px;
        display: flex;
        align-items: center;
        gap: 8px;
        border-right: 4px solid #1e3a8a;
        padding-right: 10px;
    }

    .edu-card-title .refresh-btn {
        margin-right: auto;
        background: #1e40af;
        color: white;
        border: none;
        padding: 5px 12px;
        border-radius: 6px;
        font-size: 0.75rem;
        cursor: pointer;
    }

    .edu-table-wrapper {
        overflow-x: auto;
        max-height: 300px;
    }

    .edu-table {
        width: 100%;
        border-collapse: collapse;
        font-size: 0.75rem;
        text-align: right;
    }

    .edu-table th {
        background: #f8fafc;
        padding: 10px 8px;
        color: #475569;
        font-weight: 700;
        border-bottom: 2px solid #e2e8f0;
        position: sticky;
        top: 0;
        z-index: 10;
        white-space: nowrap;
    }

    .edu-table td {
        padding: 8px;
        border-bottom: 1px solid #f1f5f9;
        vertical-align: middle;
    }

    .rating-badge {
        display: inline-flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 5px 8px;
        border-radius: 8px;
        color: white;
        font-weight: 800;
        font-size: 0.9rem;
        min-width: 55px;
        text-align: center;
        line-height: 1.2;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
        transition: transform 0.2s;
    }

    .rating-badge:hover {
        transform: scale(1.05);
    }

    .rb-count {
        display: block;
        font-size: 0.95rem;
    }

    .rb-pct {
        display: block;
        font-size: 0.65rem;
        opacity: 0.9;
        font-weight: 600;
        border-top: 1px solid rgba(255, 255, 255, 0.2);
        margin-top: 2px;
        padding-top: 2px;
        width: 100%;
    }

    .r-exc {
        background: #10b981;
    }

    /* Section */
    .r-vg {
        background: #06b6d4;
    }

    /* Section */
    .r-g {
        background: #3b82f6;
    }

    /* Section */
    .r-acc {
        background: #f59e0b;
    }

    /* Section */
    .r-w {
        background: #ef4444;
    }

    /* Section */
    .r-none {
        background: #94a3b8;
    }

    /* Section */

    /* Timeline Section */
    .edu-timeline-section {
        display: grid;
        grid-template-columns: 2fr 1fr;
        gap: 12px;
    }

    .edu-timeline-section.edu-timeline-solo {
        grid-template-columns: 1fr;
    }

    .edu-tables-row.prc-tables-row {
        grid-template-columns: 1fr;
    }

    .prc-filters-bar {
        border-color: rgba(99, 102, 241, 0.28);
        background:
            linear-gradient(135deg, rgba(99, 102, 241, 0.09) 0%, rgba(14, 165, 233, 0.06) 55%, rgba(245, 158, 11, 0.05) 100%),
            #ffffff;
    }

    .prc-filters-icon {
        background: linear-gradient(135deg, #6366f1 0%, #0ea5e9 100%) !important;
        box-shadow: 0 6px 14px -6px rgba(99, 102, 241, 0.75) !important;
    }

    .prc-filter-btn-apply {
        background: linear-gradient(135deg, #4f46e5 0%, #0ea5e9 100%) !important;
        box-shadow: 0 8px 16px -8px rgba(79, 70, 229, 0.85) !important;
    }

    .prc-filters-bar .edu-filter-field label i {
        color: #6366f1;
    }

    body.dark-mode .prc-filters-bar {
        background:
            linear-gradient(135deg, rgba(99, 102, 241, 0.14) 0%, rgba(14, 165, 233, 0.08) 100%),
            #1e293b;
        border-color: rgba(99, 102, 241, 0.32);
    }

    .edu-chart-container {
        height: 300px;
        position: relative;
    }

    #eduTimelineSvg,
    #prcTimelineSvg {
        width: 100%;
        height: 100%;
    }

    /* Groups Table */
    .group-progress-bar {
        width: 100%;
        height: 8px;
        background: #e2e8f0;
        border-radius: 10px;
        overflow: hidden;
        margin-top: 4px;
    }

    .group-progress-fill {
        height: 100%;
        border-radius: 10px;
        transition: width 1s ease-out;
    }

    .fill-low {
        background: #10b981;
    }

    .fill-med {
        background: #f59e0b;
    }

    .fill-high {
        background: #ef4444;
    }

    /* Custom Tooltip Styling */
    .edu-custom-tooltip {
        position: fixed;
        background: rgba(15, 23, 42, 0.95);
        color: white;
        padding: 12px 16px;
        border-radius: 12px;
        font-size: 0.85rem;
        z-index: 10000;
        pointer-events: none;
        display: none;
        box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.4);
        border: 1px solid rgba(255, 255, 255, 0.1);
        backdrop-filter: blur(8px);
        max-width: 250px;
        line-height: 1.5;
        transition: opacity 0.2s, transform 0.2s;
        transform: translateY(10px);
    }

    .edu-custom-tooltip.show {
        display: block;
        opacity: 1;
        transform: translateY(0);
    }

    .tooltip-title {
        color: #fbbf24;
        font-weight: 800;
        border-bottom: 1px solid rgba(255, 255, 255, 0.2);
        margin-bottom: 8px;
        padding-bottom: 4px;
        display: block;
        font-size: 0.9rem;
    }

    .tooltip-row {
        margin-bottom: 4px;
        display: flex;
        align-items: flex-start;
        gap: 6px;
    }

    .tooltip-row i {
        margin-top: 4px;
        font-size: 0.7rem;
        color: #10b981;
    }

    @media (max-width: 1024px) {
        .edu-levels-row {
            grid-template-columns: 1fr 1fr;
        }

        .edu-tables-row {
            grid-template-columns: 1fr;
        }

        .edu-timeline-section {
            grid-template-columns: 1fr;
        }
    }

    @media (max-width: 600px) {
        .edu-levels-row {
            grid-template-columns: 1fr;
        }
    }


/* block 11 */

    /* Dialogue Documentation Center */

    /* Mini Dashboard Stats */
    .dlg-mini-dashboard {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 10px;
        margin-bottom: 14px;
    }

    .dlg-stat-card {
        background: white;
        border-radius: 12px;
        padding: 14px 10px;
        text-align: center;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
        border-bottom: 4px solid #e2e8f0;
        transition: transform 0.3s, box-shadow 0.3s;
        cursor: default;
    }

    .dlg-stat-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    }

    .dlg-stat-card.sc-all {
        border-color: #3b82f6;
    }

    .dlg-stat-card.sc-image {
        border-color: #10b981;
    }

    .dlg-stat-card.sc-audio {
        border-color: #f59e0b;
    }

    .dlg-stat-card.sc-video {
        border-color: #ef4444;
    }

    .dlg-stat-card i {
        font-size: 1.4rem;
        margin-bottom: 6px;
        display: block;
    }

    .dlg-stat-card.sc-all i {
        color: #3b82f6;
    }

    .dlg-stat-card.sc-image i {
        color: #10b981;
    }

    .dlg-stat-card.sc-audio i {
        color: #f59e0b;
    }

    .dlg-stat-card.sc-video i {
        color: #ef4444;
    }

    .dlg-stat-number {
        font-size: 1.6rem;
        font-weight: 900;
        color: #1e293b;
        line-height: 1;
        margin-bottom: 4px;
    }

    .dlg-stat-label {
        font-size: 0.75rem;
        color: #64748b;
        font-weight: 600;
    }

    /* Filter Bar */
    .dlg-filter-bar {
        display: flex;
        align-items: center;
        gap: 8px;
        margin-bottom: 14px;
        flex-wrap: wrap;
    }

    /* Filter Bar Enhancement */
    .dlg-filter-bar {
        display: flex;
        align-items: center;
        gap: 12px;
        margin-bottom: 20px;
        flex-wrap: wrap;
        background: white;
        padding: 14px;
        border-radius: 16px;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
        border: 1px solid #f1f5f9;
    }

    /* Search Input Styled */
    .dlg-search-wrap {
        position: relative;
        flex: 1;
        min-width: 240px;
    }

    .dlg-search-input {
        width: 100%;
        padding: 10px 42px 10px 14px;
        border: 1px solid #e2e8f0;
        border-radius: 12px;
        font-size: 0.88rem;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        outline: none;
        background: #f8fafc;
        font-weight: 500;
    }

    .dlg-search-input:focus {
        border-color: #3b82f6;
        background: white;
        box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
    }

    .dlg-search-icon {
        position: absolute;
        right: 15px;
        top: 50%;
        transform: translateY(-50%);
        color: #64748b;
        font-size: 1rem;
    }

    /* Date Inputs Premium */
    .dlg-date-input {
        padding: 9px 12px;
        border: 1px solid #e2e8f0;
        border-radius: 10px;
        font-size: 0.82rem;
        color: #1e293b;
        outline: none;
        background: #f8fafc;
        cursor: pointer;
        font-weight: 600;
        transition: all 0.2s;
    }

    .dlg-date-input:focus {
        border-color: #3b82f6;
        background: white;
    }

    /* Type Buttons Modern */
    .dlg-filter-btn {
        padding: 8px 16px;
        border: 1px solid #e2e8f0;
        border-radius: 10px;
        background: white;
        color: #64748b;
        font-weight: 700;
        font-size: 0.8rem;
        cursor: pointer;
        transition: all 0.2s;
        display: flex;
        align-items: center;
        gap: 6px;
    }

    .dlg-filter-btn:hover {
        background: #f1f5f9;
        color: #1e293b;
        transform: translateY(-1px);
    }

    .dlg-filter-btn.active {
        background: #1e40af;
        color: white;
        border-color: #1e40af;
        box-shadow: 0 4px 10px rgba(30, 64, 175, 0.25);
    }

    /* Dashboard Toggle - Premium Look */
    .dlg-dashboard-toggle-btn {
        padding: 9px 18px;
        border: none;
        border-radius: 10px;
        background: linear-gradient(135deg, #1e293b, #334155);
        color: white;
        font-weight: 800;
        font-size: 0.8rem;
        cursor: pointer;
        display: flex;
        align-items: center;
        gap: 8px;
        transition: all 0.3s;
        box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
    }

    .dlg-dashboard-toggle-btn:hover {
        transform: scale(1.03);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    }

    .dlg-dashboard-toggle-btn.active {
        background: linear-gradient(135deg, #ef4444, #dc2626);
    }

    /* Clear Reset Button */
    .dlg-clear-btn {
        padding: 8px 12px;
        border: 1.5px dashed #f87171;
        background: rgba(254, 226, 226, 0.5);
        color: #b91c1c;
        border-radius: 10px;
        cursor: pointer;
        font-size: 0.78rem;
        font-weight: 800;
        display: none;
        align-items: center;
        gap: 6px;
        transition: all 0.2s;
    }

    .dlg-clear-btn:hover {
        background: #fee2e2;
        border-style: solid;
    }

    .dlg-refresh-btn {
        padding: 9px;
        width: 38px;
        height: 38px;
        border: none;
        border-radius: 10px;
        background: #f1f5f9;
        color: #475569;
        cursor: pointer;
        transition: all 0.3s;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .dlg-refresh-btn:hover {
        background: #e2e8f0;
        color: #1e293b;
        transform: rotate(180deg);
    }

    .dlg-refresh-btn:hover {
        background: #1e3a8a;
        transform: scale(1.04);
    }

    .dlg-refresh-btn.spinning i {
        animation: dlg-spin 1s linear infinite;
    }

    @keyframes dlg-spin {
        from {
            transform: rotate(0deg);
        }

        to {
            transform: rotate(360deg);
        }
    }

    /* Telegram Sending Button Style - Moved to Body */
    .dlg-tg-btn {
        position: absolute;
        top: 10px;
        left: 10px;
        width: 32px;
        height: 32px;
        border-radius: 50%;
        border: none;
        background: #2AABEE;
        color: white;
        font-size: 0.9rem;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        box-shadow: 0 3px 8px rgba(42, 171, 238, 0.3);
        transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
        z-index: 10;
        /* Always semi-visible in body or appears on card hover */
        opacity: 0.4;
    }

    .dlg-doc-card:hover .dlg-tg-btn {
        opacity: 1;
        transform: scale(1.1) rotate(-15deg);
        box-shadow: 0 5px 15px rgba(42, 171, 238, 0.5);
    }

    .dlg-tg-btn:hover {
        background: #229ED9;
        transform: scale(1.15) !important;
        box-shadow: 0 6px 16px rgba(42, 171, 238, 0.6);
    }

    .dlg-tg-btn.tg-sending {
        background: #f59e0b;
        pointer-events: none;
    }

    .dlg-tg-btn.tg-sending i {
        animation: dlg-spin 1s linear infinite;
    }

    .dlg-tg-btn.tg-done {
        background: #10b981;
        transform: scale(1.1) !important;
    }

    .dlg-tg-btn.tg-error {
        background: #ef4444;
    }

    /* Privacy Mode Toggle Button Styles */
    .dlg-privacy-toggle-btn {
        background: #f1f5f9;
        border: 1px solid #e2e8f0;
        color: #475569;
        padding: 6px 12px;
        border-radius: 8px;
        cursor: pointer;
        display: flex;
        align-items: center;
        gap: 6px;
        font-size: 0.85rem;
        font-weight: 600;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: 0 1px 2px rgba(0,0,0,0.05);
    }

    .dlg-privacy-toggle-btn.active {
        background: #fee2e2;
        color: #dc2626;
        border-color: #fecaca;
        box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
    }

    .dlg-privacy-toggle-btn.unlocked {
        background: #dcfce7;
        color: #16a34a;
        border-color: #bbf7d0;
    }

    .dlg-privacy-toggle-btn:hover {
        transform: translateY(-1px);
        box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    }

    .dlg-privacy-toggle-btn i {
        font-size: 1rem;
    }

    /* Cards Grid */
    .dlg-cards-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
        gap: 12px;
    }

    .dlg-doc-card {
        background: white;
        border-radius: 14px;
        overflow: hidden;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
        border: 1px solid #e2e8f0;
        transition: all 0.3s ease;
        position: relative;
    }

    .dlg-doc-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 10px 25px rgba(0, 0, 0, 0.12);
        border-color: #93c5fd;
    }

    /* Card Preview / Icon Area */
    .dlg-card-preview {
        height: 120px;
        display: flex;
        align-items: center;
        justify-content: center;
        position: relative;
        overflow: hidden;
    }

    .dlg-card-preview.type-image {
        background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
    }

    .dlg-card-preview.type-audio {
        background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    }

    .dlg-card-preview.type-video {
        background: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%);
    }

    .dlg-card-preview img.dlg-thumb {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .dlg-card-preview .dlg-type-icon {
        font-size: 2.5rem;
        opacity: 0.6;
    }

    .dlg-card-preview.type-image .dlg-type-icon {
        color: #059669;
    }

    .dlg-card-preview.type-audio .dlg-type-icon {
        color: #d97706;
    }

    .dlg-card-preview.type-video .dlg-type-icon {
        color: #dc2626;
    }

    /* Type Badge */
    .dlg-type-badge {
        position: absolute;
        top: 8px;
        left: 8px;
        padding: 3px 10px;
        border-radius: 20px;
        font-size: 0.65rem;
        font-weight: 800;
        color: white;
        text-transform: uppercase;
        letter-spacing: 0.5px;
    }

    .dlg-type-badge.badge-image {
        background: #059669;
    }

    .dlg-type-badge.badge-audio {
        background: #d97706;
    }

    .dlg-type-badge.badge-video {
        background: #dc2626;
    }

    /* ID Badge */
    .dlg-id-badge {
        position: absolute;
        top: 8px;
        right: 8px;
        padding: 3px 8px;
        border-radius: 6px;
        font-size: 0.6rem;
        font-weight: 800;
        background: rgba(0, 0, 0, 0.5);
        color: white;
        backdrop-filter: blur(4px);
    }

    /* Card Body */
    .dlg-card-body {
        padding: 12px;
    }

    .dlg-card-name {
        font-size: 0.9rem;
        font-weight: 800;
        color: #1e293b;
        margin-bottom: 8px;
        line-height: 1.3;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .dlg-card-meta {
        display: flex;
        flex-direction: column;
        gap: 4px;
        margin-bottom: 10px;
    }

    .dlg-meta-row {
        display: flex;
        align-items: center;
        gap: 6px;
        font-size: 0.72rem;
        color: #64748b;
    }

    .dlg-meta-row i {
        width: 14px;
        text-align: center;
        font-size: 0.7rem;
        color: #94a3b8;
    }

    .dlg-meta-row span {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    /* Card Action Button */
    .dlg-card-action {
        width: 100%;
        padding: 8px;
        border: none;
        border-radius: 8px;
        background: linear-gradient(135deg, #1e40af, #3b82f6);
        color: white;
        font-weight: 700;
        font-size: 0.78rem;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 6px;
        transition: all 0.25s;
    }

    .dlg-card-action:hover {
        background: linear-gradient(135deg, #1e3a8a, #2563eb);
        transform: scale(1.02);
    }

    /* Modal */
    .dlg-modal-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.75);
        backdrop-filter: blur(6px);
        z-index: 999999;
        justify-content: center;
        align-items: center;
        padding: 20px;
    }

    .dlg-modal-overlay.show {
        display: flex;
    }

    .dlg-modal-content {
        background: white;
        border-radius: 20px;
        max-width: 750px;
        width: 100%;
        max-height: 90vh;
        overflow-y: auto;
        box-shadow: 0 25px 60px rgba(0, 0, 0, 0.4);
        animation: dlg-modal-in 0.35s ease;
    }

    @keyframes dlg-modal-in {
        from {
            opacity: 0;
            transform: scale(0.92) translateY(20px);
        }

        to {
            opacity: 1;
            transform: scale(1) translateY(0);
        }
    }

    .dlg-modal-header {
        padding: 16px 20px;
        border-bottom: 1px solid #e2e8f0;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .dlg-modal-title {
        font-size: 1rem;
        font-weight: 800;
        color: #1e293b;
        display: flex;
        align-items: center;
        gap: 8px;
    }

    .dlg-modal-close {
        width: 34px;
        height: 34px;
        border-radius: 50%;
        border: none;
        background: #f1f5f9;
        color: #64748b;
        font-size: 1.1rem;
        cursor: pointer;
        transition: all 0.2s;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .dlg-modal-close:hover {
        background: #fee2e2;
        color: #ef4444;
    }

    /* Modal Metadata Grid */
    .dlg-modal-meta {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
        gap: 8px;
        padding: 14px 20px;
        background: #f8fafc;
        border-bottom: 1px solid #e2e8f0;
    }

    .dlg-modal-meta-item {
        display: flex;
        align-items: center;
        gap: 6px;
        font-size: 0.78rem;
        color: #475569;
    }

    .dlg-modal-meta-item i {
        color: #1e40af;
        width: 16px;
        text-align: center;
    }

    .dlg-modal-meta-item strong {
        color: #1e293b;
        font-weight: 700;
    }

    /* Privacy Mode Masking - Comprehensive Protection */
    .dlg-privacy-active .dlg-card-name,
    .dlg-privacy-active .dlg-meta-row span,
    .dlg-privacy-active .dlg-meta-row a,
    .dlg-privacy-active .dlg-id-badge,
    .dlg-privacy-active .dlg-modal-meta-item strong,
    .dlg-privacy-active .dlg-modal-meta-item span {
        filter: blur(8px) grayscale(1);
        user-select: none;
        pointer-events: none;
        transition: filter 0.3s ease;
    }

    /* Phone Spoiler */
    .dlg-phone-spoiler {
        background: #1e293b;
        color: #1e293b;
        padding: 2px 8px;
        border-radius: 4px;
        cursor: pointer;
        transition: all 0.3s;
        font-weight: 700;
        user-select: none;
    }

    .dlg-phone-spoiler.revealed {
        background: transparent;
        color: #059669;
    }

    /* Modal Player */
    .dlg-modal-player {
        padding: 20px;
        display: flex;
        align-items: center;
        justify-content: center;
        min-height: 200px;
        background: #0f172a;
    }

    .dlg-modal-player video,
    .dlg-modal-player audio {
        width: 100%;
        max-height: 450px;
        border-radius: 8px;
    }

    .dlg-modal-player img {
        max-width: 100%;
        max-height: 500px;
        border-radius: 8px;
        object-fit: contain;
    }

    .dlg-modal-player .dlg-player-loading {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 12px;
        color: #94a3b8;
        font-size: 0.85rem;
    }

    .dlg-modal-player .dlg-player-loading i {
        font-size: 2rem;
        animation: dlg-spin 1s linear infinite;
    }

    .dlg-modal-player .dlg-player-error {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 12px;
        color: #f87171;
        text-align: center;
        font-size: 0.85rem;
    }

    .dlg-open-external {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        padding: 8px 18px;
        border-radius: 8px;
        background: #3b82f6;
        color: white;
        text-decoration: none;
        font-weight: 700;
        font-size: 0.8rem;
        margin-top: 8px;
        transition: background 0.2s;
    }

    .dlg-open-external:hover {
        background: #2563eb;
    }

    /* Loading State */
    .dlg-loading-state {
        text-align: center;
        padding: 60px 20px;
        color: #64748b;
    }

    .dlg-loading-state i {
        font-size: 2.5rem;
        color: #3b82f6;
        animation: dlg-spin 1s linear infinite;
        margin-bottom: 14px;
    }

    /* Empty State */
    .dlg-empty-state {
        text-align: center;
        padding: 60px 20px;
        color: #94a3b8;
    }

    .dlg-empty-state i {
        font-size: 3rem;
        margin-bottom: 12px;
        opacity: 0.5;
    }

    /* Responsive */
    @media (max-width: 768px) {
        .dlg-mini-dashboard {
            grid-template-columns: repeat(2, 1fr);
        }

        .dlg-cards-grid {
            grid-template-columns: 1fr;
        }

        .dlg-modal-meta {
            grid-template-columns: 1fr 1fr;
        }

        .dlg-filter-bar {
            gap: 5px;
        }

        .dlg-filter-btn {
            padding: 5px 10px;
            font-size: 0.7rem;
        }
    }

    @media (max-width: 480px) {
        .dlg-mini-dashboard {
            grid-template-columns: 1fr 1fr;
            gap: 6px;
        }

        .dlg-modal-meta {
            grid-template-columns: 1fr;
        }
    }

    /* ════════════════════════════════════════════════════════
       Video Play Overlay
       ════════════════════════════════════════════════════════ */
    .dlg-play-overlay {
        position: absolute;
        inset: 0;
        display: flex;
        align-items: center;
        justify-content: center;
        background: rgba(0, 0, 0, 0.28);
        opacity: 0;
        transition: opacity 0.25s ease;
        border-radius: 0;
    }

    .dlg-doc-card:hover .dlg-play-overlay {
        opacity: 1;
    }

    .dlg-play-overlay i {
        font-size: 2.8rem;
        color: white;
        filter: drop-shadow(0 2px 10px rgba(0, 0, 0, 0.7));
        transition: transform 0.2s ease;
    }

    .dlg-doc-card:hover .dlg-play-overlay i {
        transform: scale(1.12);
    }

    /* ════════════════════════════════════════════════════════
       Pagination Bar
       ════════════════════════════════════════════════════════ */
    .dlg-pagination-bar {
        display: flex;
        justify-content: center;
        align-items: center;
        gap: 6px;
        margin-top: 20px;
        flex-wrap: wrap;
        padding: 4px 0 10px;
    }

    .dlg-page-btn {
        min-width: 36px;
        height: 36px;
        padding: 0 10px;
        border: 2px solid #e2e8f0;
        border-radius: 10px;
        background: white;
        color: #475569;
        font-weight: 700;
        font-size: 0.82rem;
        cursor: pointer;
        transition: all 0.2s ease;
        display: flex;
        align-items: center;
        justify-content: center;
        box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
    }

    .dlg-page-btn:hover:not(:disabled) {
        border-color: #3b82f6;
        color: #1e40af;
        background: #eff6ff;
        transform: translateY(-1px);
    }

    .dlg-page-btn.active {
        background: linear-gradient(135deg, #1e40af, #3b82f6);
        color: white;
        border-color: #1e40af;
        pointer-events: none;
        box-shadow: 0 4px 12px rgba(30, 64, 175, 0.35);
    }

    .dlg-page-btn:disabled {
        opacity: 0.35;
        cursor: not-allowed;
    }

    .dlg-page-info {
        font-size: 0.78rem;
        color: #64748b;
        font-weight: 600;
        padding: 0 6px;
    }

    .dlg-page-dots {
        font-size: 0.82rem;
        color: #94a3b8;
        padding: 0 2px;
        font-weight: 700;
    }

    @media (max-width: 480px) {
        .dlg-page-btn {
            min-width: 32px;
            height: 32px;
            font-size: 0.75rem;
        }
    }

    /* ════════════════════════════════════════════════════════
       Inline Video Preview in Card
       ════════════════════════════════════════════════════════ */
    .dlg-card-video-preview {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
        border-radius: 0;
        position: absolute;
        top: 0;
        left: 0;
    }

    /* Shimmer effect while video preview is loading */
    .dlg-card-preview.loading-preview {
        background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
        background-size: 200% 100%;
        animation: dlg-shimmer 1.4s infinite;
    }

    @keyframes dlg-shimmer {
        0% {
            background-position: 200% 0;
        }

        100% {
            background-position: -200% 0;
        }
    }

    /* Mobile Responsive for Media Modal */
    @media (max-width: 768px) {
        .dlg-modal-overlay {
            padding: 0.5rem !important;
        }

        .dlg-modal-content {
            width: 95% !important;
            max-width: 95% !important;
            max-height: 90vh !important;
            max-height: 90dvh !important;
            border-radius: 12px !important;
            overflow-y: auto !important;
        }

        .dlg-modal-header {
            padding: 12px 14px !important;
        }

        .dlg-modal-title {
            font-size: 0.9rem !important;
        }

        .dlg-modal-meta {
            padding: 10px 14px !important;
            gap: 6px !important;
        }

        .dlg-modal-player {
            padding: 12px !important;
            min-height: 160px !important;
        }

        .dlg-modal-player video,
        .dlg-modal-player audio {
            max-height: 300px !important;
        }

        .dlg-modal-player img {
            max-height: 300px !important;
        }
    }

    @media (max-width: 480px) {
        .dlg-modal-overlay {
            padding: 0.25rem !important;
        }

        .dlg-modal-content {
            width: 100% !important;
            max-width: 100vw !important;
            border-radius: 8px !important;
        }

        .dlg-modal-header {
            padding: 10px 12px !important;
        }

        .dlg-modal-title {
            font-size: 0.85rem !important;
        }

        .dlg-modal-meta {
            grid-template-columns: 1fr !important;
            padding: 8px 12px !important;
        }

        .dlg-modal-player {
            padding: 8px !important;
            min-height: 140px !important;
        }

        .dlg-modal-player video,
        .dlg-modal-player audio {
            max-height: 220px !important;
        }

        .dlg-modal-player img {
            max-height: 220px !important;
        }
    }


/* block 12 */

            .dlg-dashboard-panel {
                width: 100%;
                margin-bottom: 25px;
                display: none;
                animation: dlg-slide-down 0.4s cubic-bezier(0.16, 1, 0.3, 1);
            }

            .dlg-dashboard-panel.open {
                display: block;
            }

            @keyframes dlg-slide-down {
                from {
                    opacity: 0;
                    transform: translateY(-15px);
                }

                to {
                    opacity: 1;
                    transform: translateY(0);
                }
            }

            .dlg-dashboard-grid {
                display: grid;
                grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
                gap: 16px;
            }

            /* Individual Stat Card */
            .dlg-dash-card {
                background: white;
                border-radius: 18px;
                padding: 18px;
                box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
                border: 1px solid #f1f5f9;
                position: relative;
                overflow: hidden;
                transition: transform 0.3s;
            }

            .dlg-dash-card:hover {
                transform: translateY(-3px);
                box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
            }

            .dlg-dash-card::before {
                content: '';
                position: absolute;
                top: 0;
                left: 0;
                right: 0;
                height: 5px;
            }

            /* Colors by section */
            .dlg-card-preacher::before {
                background: linear-gradient(90deg, #3b82f6, #60a5fa);
            }

            .dlg-card-language::before {
                background: linear-gradient(90deg, #10b981, #34d399);
            }

            .dlg-card-country::before {
                background: linear-gradient(90deg, #f59e0b, #fbbf24);
            }

            .dlg-card-gender::before {
                background: linear-gradient(90deg, #6366f1, #818cf8);
            }

            .dlg-dash-title {
                display: flex;
                align-items: center;
                gap: 8px;
                font-size: 1rem;
                font-weight: 900;
                color: #1e293b;
                margin-bottom: 14px;
            }

            .dlg-dash-title i {
                font-size: 1.1rem;
                opacity: 0.8;
            }

            .dlg-card-preacher i {
                color: #3b82f6;
            }

            .dlg-card-language i {
                color: #10b981;
            }

            .dlg-card-country i {
                color: #f59e0b;
            }

            .dlg-card-gender i {
                color: #6366f1;
            }

            .dlg-bar-item {
                margin-bottom: 12px;
            }

            .dlg-bar-header {
                display: flex;
                justify-content: space-between;
                font-size: 0.76rem;
                margin-bottom: 5px;
                color: #475569;
            }

            .dlg-bar-label {
                font-weight: 800;
                color: #334155;
            }

            .dlg-bar-val {
                font-weight: 700;
                color: #64748b;
                font-variant-numeric: tabular-nums;
            }

            .dlg-bar-track {
                height: 7px;
                background: #f1f5f9;
                border-radius: 10px;
                overflow: hidden;
            }

            .dlg-bar-fill {
                height: 100%;
                border-radius: 10px;
                transition: width 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
            }

            .dlg-card-preacher .dlg-bar-fill {
                background: #3b82f6;
            }

            .dlg-card-language .dlg-bar-fill {
                background: #10b981;
            }

            .dlg-card-country .dlg-bar-fill {
                background: #f59e0b;
            }

            .dlg-card-gender .dlg-bar-fill {
                background: #6366f1;
            }

            .dlg-dash-summary-bar {
                background: #1e293b;
                color: white;
                padding: 10px 20px;
                border-radius: 14px;
                margin-bottom: 16px;
                display: flex;
                justify-content: space-between;
                align-items: center;
                font-size: 0.82rem;
            }

            .dlg-summary-count {
                font-weight: 900;
                color: #3b82f6;
                font-size: 1rem;
            }
        

/* block 13 */

    /* Leaflet Custom Styles */
    .custom-div-icon {
        background: transparent;
        border: none;
    }

    .custom-popup .leaflet-popup-content-wrapper {
        border-radius: 8px;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    }

    .custom-popup .leaflet-popup-content {
        margin: 0;
        padding: 0;
    }

    .leaflet-container {
        font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    }

    /* Section */
    .leaflet-container .leaflet-tile-pane {
        filter: brightness(1.1) saturate(0.8) hue-rotate(180deg);
    }

    .leaflet-container .leaflet-tile {
        opacity: 0.9;
    }

    .leaflet-control-zoom {
        border: none;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    }

    .leaflet-control-zoom a {
        background-color: white;
        color: #1e3a8a;
        border: 1px solid #e2e8f0;
    }

    .leaflet-control-zoom a:hover {
        background-color: #f8fafc;
        color: #1e40af;
    }

    /* Animation Styles */
    .number,
    .count,
    .val,
    .stat-val,
    .daily-avg-number,
    .countries-number,
    .gender-percent,
    .monthly-bar-val,
    .gender-center-num {
        transition: transform 0.3s ease-out;
        font-variant-numeric: tabular-nums;
    }

    .number.animating,
    .count.animating,
    .val.animating {
        transform: scale(1.1);
    }

    .pie-chart {
        transition: opacity 1s ease-out, transform 1s ease-out;
    }

    .gender-chart-center {
        transition: background 1.5s ease-out;
    }

    .chart-placeholder path {
        transition: opacity 1s ease-out, transform 1s ease-out;
    }

    /* Monthly Statistics Table Styles */
    .monthly-stats-table-container {
        padding: 6px;
        max-height: 280px;
        overflow-y: auto;
    }

    .monthly-stats-loading {
        text-align: center;
        padding: 20px;
        color: #64748b;
        font-size: 0.75rem;
    }

    .monthly-stats-table {
        width: 100%;
        border-collapse: collapse;
        font-size: 0.7rem;
    }

    .monthly-stats-table thead {
        position: sticky;
        top: 0;
        background: #1e40af;
        color: white;
        z-index: 10;
    }

    .monthly-stats-table th {
        padding: 8px 6px;
        text-align: right;
        font-weight: 700;
        font-size: 0.75rem;
        border-bottom: 2px solid #1e3a8a;
    }

    .monthly-stats-table th:first-child {
        border-radius: 8px 0 0 0;
    }

    .monthly-stats-table th:last-child {
        border-radius: 0 8px 0 0;
    }

    .monthly-stats-table tbody tr {
        border-bottom: 1px solid #e2e8f0;
        transition: background-color 0.2s;
    }

    .monthly-stats-table tbody tr:hover {
        background-color: #f8fafc;
    }

    .monthly-stats-table tbody tr:last-child {
        border-bottom: none;
    }

    .monthly-stats-table td {
        padding: 8px 6px;
        text-align: right;
        color: #334155;
    }

    .monthly-stats-table td:first-child {
        font-weight: 600;
        color: #1e40af;
        min-width: 90px;
        font-size: 0.7rem;
    }

    .monthly-stats-table td:last-child {
        font-weight: 700;
        color: #059669;
        font-size: 0.8rem;
        text-align: center;
        min-width: 60px;
    }

    .monthly-stats-table tbody tr:nth-child(even) {
        background-color: #f8fafc;
    }

    .monthly-stats-table tbody tr:nth-child(even):hover {
        background-color: #f1f5f9;
    }

    /* Scrollbar Styling */
    .monthly-stats-table-container::-webkit-scrollbar {
        width: 6px;
    }

    .monthly-stats-table-container::-webkit-scrollbar-track {
        background: #f1f5f9;
        border-radius: 3px;
    }

    .monthly-stats-table-container::-webkit-scrollbar-thumb {
        background: #cbd5e1;
        border-radius: 3px;
    }

    .monthly-stats-table-container::-webkit-scrollbar-thumb:hover {
        background: #94a3b8;
    }

    /* News Ticker */
    .news-ticker-wrapper {
        margin-top: 22px;
        overflow: hidden;
        border-radius: 16px;
        box-shadow: 0 8px 24px rgba(15, 23, 42, 0.14);
    }

    .news-ticker-container {
        background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 45%, #2563eb 100%);
        padding: 16px 0;
        display: flex;
        align-items: center;
        position: relative;
        overflow: hidden;
        border: 1px solid rgba(255, 255, 255, 0.08);
    }

    .news-ticker-container::before {
        content: '';
        position: absolute;
        inset: 0;
        background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.06) 50%, transparent 100%);
        animation: ticker-shine 6s ease-in-out infinite;
        pointer-events: none;
    }

    @keyframes ticker-shine {
        0%, 100% { transform: translateX(-100%); }
        50% { transform: translateX(100%); }
    }

    .news-ticker-icon {
        position: absolute;
        right: 20px;
        z-index: 3;
        background: rgba(255, 255, 255, 0.22);
        backdrop-filter: blur(10px);
        width: 45px;
        height: 45px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.18);
        animation: pulse-icon 2s ease-in-out infinite;
    }

    .news-ticker-icon i {
        color: #ffffff;
        font-size: 1.2rem;
        animation: shake-icon 3s ease-in-out infinite;
    }

    @keyframes pulse-icon {

        0%,
        100% {
            transform: scale(1);
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
        }

        50% {
            transform: scale(1.05);
            box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
        }
    }

    @keyframes shake-icon {

        0%,
        100% {
            transform: rotate(0deg);
        }

        10%,
        30% {
            transform: rotate(-10deg);
        }

        20%,
        40% {
            transform: rotate(10deg);
        }

        50% {
            transform: rotate(0deg);
        }
    }

    .news-ticker-content {
        flex: 1;
        margin-right: 80px;
        overflow: hidden;
        position: relative;
        height: 32px;
        display: flex;
        align-items: center;
        direction: rtl;
    }

    /* Section */
    .news-ticker-text {
        color: #ffffff;
        font-size: 1.1rem;
        font-weight: 600;
        letter-spacing: 0.3px;
        position: absolute;
        left: 0;
        top: 50%;
        display: inline-flex;
        align-items: center;
        white-space: nowrap;
        direction: ltr;
        transform: translate(0%, -50%);
        animation: ticker-slide 60s linear infinite;
        will-change: transform;
        text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
    }

    .news-ticker-text .ticker-item {
        direction: rtl;
        unicode-bidi: isolate;
    }

    @keyframes ticker-slide {
        0% {
            transform: translate(-50%, -50%);
        }

        100% {
            transform: translate(0%, -50%);
        }
    }

    .ticker-separator {
        margin: 0 22px;
        color: #fde68a;
        opacity: 0.9;
        font-size: 1rem;
    }

    /* Hover Effect */
    .news-ticker-container:hover .news-ticker-text {
        animation-play-state: paused;
    }

    /* Dark Mode Support */
    body.dark-mode .news-ticker-container {
        background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
        border: 1px solid rgba(255, 255, 255, 0.1);
    }

    body.dark-mode .news-ticker-icon {
        background: rgba(255, 255, 255, 0.15);
    }

    body.dark-mode .news-ticker-wrapper {
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    }

    /* Responsive Design */
    @media (max-width: 768px) {
        .news-ticker-wrapper {
            margin-top: 10px;
        }

        .news-ticker-container {
            padding: 6px 0;
        }

        .news-ticker-icon {
            width: 28px;
            height: 28px;
            right: 8px;
        }

        .news-ticker-icon i {
            font-size: 0.8rem;
        }

        .news-ticker-content {
            margin-right: 55px;
            height: 26px;
        }

        .news-ticker-text {
            font-size: 0.95rem;
        }

        .ticker-separator {
            margin: 0 15px;
        }

        .monthly-stats-table-container {
            max-height: 200px;
            padding: 4px;
        }

        .monthly-stats-table {
            font-size: 0.65rem;
        }

        .monthly-stats-table th {
            padding: 6px 4px;
            font-size: 0.7rem;
        }

        .monthly-stats-table td {
            padding: 6px 4px;
        }

        .monthly-stats-table td:first-child {
            min-width: 70px;
            font-size: 0.65rem;
        }

        .monthly-stats-table td:last-child {
            font-size: 0.75rem;
            min-width: 50px;
        }
    }

    /* Section */
    #manual-refresh-btn {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        padding: 7px 16px;
        background: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%);
        color: #ffffff;
        border: none;
        border-radius: 20px;
        font-size: 0.8rem;
        font-weight: 600;
        cursor: pointer;
        transition: all 0.3s ease;
        box-shadow: 0 2px 10px rgba(30, 64, 175, 0.35);
        font-family: inherit;
        direction: rtl;
        white-space: nowrap;
        letter-spacing: 0.2px;
    }

    #manual-refresh-btn:hover:not(:disabled) {
        transform: translateY(-2px);
        box-shadow: 0 5px 18px rgba(30, 64, 175, 0.5);
        background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
    }

    #manual-refresh-btn:active:not(:disabled) {
        transform: translateY(0);
        box-shadow: 0 2px 8px rgba(30, 64, 175, 0.35);
    }

    #manual-refresh-btn:disabled {
        opacity: 0.75;
        cursor: not-allowed;
        transform: none;
    }

    /* Section */
    #manual-refresh-btn.loading #refresh-btn-icon {
        animation: spin-refresh 0.9s linear infinite;
    }

    @keyframes spin-refresh {
        from { transform: rotate(0deg); }
        to   { transform: rotate(360deg); }
    }

    /* Section */
    #manual-refresh-btn.success {
        background: linear-gradient(135deg, #059669 0%, #10b981 100%);
        box-shadow: 0 2px 10px rgba(5, 150, 105, 0.4);
    }

    /* Dark Mode */
    body.dark-mode #manual-refresh-btn {
        background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
        box-shadow: 0 2px 10px rgba(37, 99, 235, 0.3);
    }

    body.dark-mode #manual-refresh-btn.success {
        background: linear-gradient(135deg, #047857 0%, #059669 100%);
    }

    /* Responsive */
    @media (max-width: 768px) {
        #manual-refresh-btn {
            padding: 6px 12px;
            font-size: 0.72rem;
        }
    }

    /* Tab refresh buttons (dialogue + education) */
    .dlg-refresh-btn.has-label {
        width: auto;
        height: 38px;
        padding: 8px 16px;
        gap: 8px;
        background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
        color: #fff;
        font-size: 0.78rem;
        font-weight: 700;
        border-radius: 10px;
        box-shadow: 0 2px 10px rgba(79, 70, 229, 0.35);
        white-space: nowrap;
    }
    .dlg-refresh-btn.has-label:hover {
        background: linear-gradient(135deg, #4338ca 0%, #6d28d9 100%);
        color: #fff;
        transform: translateY(-1px);
    }
    .dlg-refresh-btn.has-label:disabled {
        opacity: 0.75;
        cursor: not-allowed;
        transform: none;
    }
    #edu-refresh-btn {
        background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
        color: #fff;
        border: none;
        box-shadow: 0 2px 10px rgba(79, 70, 229, 0.35);
        white-space: nowrap;
    }
    #edu-refresh-btn:hover:not(:disabled) {
        background: linear-gradient(135deg, #4338ca 0%, #6d28d9 100%);
        transform: translateY(-1px);
    }
    #edu-refresh-btn:disabled {
        opacity: 0.75;
        cursor: not-allowed;
    }
    #edu-refresh-btn.loading i {
        animation: dlg-spin 0.9s linear infinite;
    }



/* block 14 */

/* CSS for Notification System */
.notification-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    animation: fadeIn 0.4s ease;
}

.notification-modal {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 24px;
    padding: 40px;
    width: 90%;
    max-width: 500px;
    text-align: center;
    color: white;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    transform: scale(0.8);
    animation: popIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

.notification-icon-wrapper {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #fbbf24 0%, #d97706 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: 0 10px 20px rgba(217, 119, 6, 0.3);
}

.notification-icon {
    font-size: 35px;
    color: white;
    animation: bellPulse 2s infinite;
}

.notification-header h2 {
    margin: 0 0 15px;
    font-size: 24px;
    font-weight: 700;
    font-family: 'Cairo', sans-serif;
}

.notification-body {
    margin-bottom: 25px;
    line-height: 1.6;
    font-size: 17px;
    color: rgba(255, 255, 255, 0.9);
    font-family: 'Cairo', sans-serif;
}

.notification-footer {
    display: flex;
    justify-content: center;
}

.notification-btn {
    background: linear-gradient(135deg, #3b82f6 0%, #1e40af 100%);
    border: none;
    padding: 12px 40px;
    border-radius: 50px;
    color: white;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 10px 20px rgba(59, 130, 246, 0.3);
    font-family: 'Cairo', sans-serif;
}

.notification-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 25px rgba(59, 130, 246, 0.4);
}

.notification-btn:active {
    transform: translateY(0);
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes popIn {
    to { transform: scale(1); }
}

@keyframes bellPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}
