﻿.bi {
    font-family: "Bootstrap Icons" !important;
}

.hover-card {
    transition: all 0.3s ease;
    cursor: pointer;
}

.hover-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15) !important;
}

.card-header {
    border-bottom: none !important;
}

.display-5 {
    font-size: 2.5rem;
}

.btn {
    transition: all 0.2s ease;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.card-body .list-unstyled li {
    padding: 2px 0;
}

.bg-light {
    background-color: #f8f9fa !important;
}

/* Dashboard-specific color enhancements */
.card-header.bg-primary {
    background: linear-gradient(135deg, #0d6efd 0%, #0a58ca 100%) !important;
}

.card-header.bg-success {
    background: linear-gradient(135deg, #198754 0%, #146c43 100%) !important;
}

.card-header.bg-info {
    background: linear-gradient(135deg, #0dcaf0 0%, #087990 100%) !important;
}

.card-header.bg-warning {
    background: linear-gradient(135deg, #ffc107 0%, #ffca2c 100%) !important;
}

/* Responsive improvements */
@media (max-width: 768px) {
    .display-4 {
        font-size: 2rem;
    }
    
    .display-1 {
        font-size: 3rem;
    }
    
    .col-lg-4 {
        margin-bottom: 1rem;
    }
}

/* Slicer Filter Container - Card Style with Fixed Height */
.slicer-filter-card {
    border: 1px solid #dee2e6;
    border-radius: 0.375rem;
    background-color: #ffffff;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    overflow: hidden;
}

.slicer-filter-card .card-header {
    background-color: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
    padding: 0.75rem 1rem;
    font-weight: 600;
    color: #495057;
}

.slicer-filter-card .card-body {
    padding: 0;
    height: 200px; /* Fixed height for exactly 5 items at ~40px each */
    overflow-y: auto;
    overflow-x: hidden;
}

/* Slicer Items - Clean List Style */
.slicer-item {
    display: block;
    padding: 0.75rem 0.5rem; /* Reduced horizontal padding from 1rem to 0.5rem */
    margin: 0;
    border: none;
    border-bottom: 1px solid #f1f3f4;
    background-color: #ffffff;
    color: #000000 !important; /* Black text as requested */
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
    font-size: 0.875rem;
    line-height: 1.2;
}

.slicer-item:last-child {
    border-bottom: none;
}

/* Available items (default state) */
.slicer-item.slicer-available {
    background-color: #ffffff !important;
    color: #000000 !important;
}

.slicer-item.slicer-available:hover {
    background-color: #f8f9fa !important;
    color: #000000 !important;
}

/* Cross-highlighted items (available based on current filters) */
.slicer-item.slicer-cross-highlighted {
    background-color: #e7f3ff !important;
    color: #000000 !important;
    font-weight: 500;
    border-left: 3px solid #0d6efd;
}

.slicer-item.slicer-cross-highlighted:hover {
    background-color: #cce7ff !important;
    color: #000000 !important;
}

/* Unavailable items (grayed out) */
.slicer-item.slicer-unavailable {
    background-color: #f8f9fa !important;
    color: #6c757d !important;
    opacity: 0.6;
    cursor: not-allowed !important;
}

.slicer-item.slicer-unavailable:hover {
    background-color: #f8f9fa !important;
    color: #6c757d !important;
}

/* Selected items */
.slicer-item.selected {
    background-color: #0d6efd !important;
    color: #ffffff !important;
    font-weight: 600;
    border-left: 3px solid #0a58ca;
}

.slicer-item.selected:hover {
    background-color: #0b5ed7 !important;
    color: #ffffff !important;
}

/* Checkbox styling within slicer items */
.slicer-item .form-check {
    margin: 0;
    padding: 0;
}

.slicer-item .form-check-input {
    margin-right: 0.25rem; /* Reduced from 0.5rem */
    margin-top: 0.125rem;
}

.slicer-item .form-check-label {
    color: inherit;
    margin: 0;
    padding: 0;
    width: 100%;
    cursor: inherit;
}

/* Scrollbar styling for slicer containers */
.slicer-filter-card .card-body::-webkit-scrollbar {
    width: 6px;
}

.slicer-filter-card .card-body::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.slicer-filter-card .card-body::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.slicer-filter-card .card-body::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Animation for highlight changes */
@keyframes highlight-pulse {
    0% {
        transform: scale(1);
        box-shadow: inset 0 0 0 1px rgba(13, 110, 253, 0.2);
    }
    50% {
        transform: scale(1.01);
        box-shadow: inset 0 0 0 2px rgba(13, 110, 253, 0.3);
    }
    100% {
        transform: scale(1);
        box-shadow: inset 0 0 0 1px rgba(13, 110, 253, 0.2);
    }
}

.slicer-item.slicer-cross-highlighted {
    animation: highlight-pulse 0.3s ease-out;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .slicer-filter-card .card-body {
        height: 150px; /* Smaller height on mobile */
    }
    
    .slicer-item {
        padding: 0.5rem 0.75rem;
        font-size: 0.8rem;
    }
}

    /* Updated Filter Container to match slicer card style */
    .filter-container {
        height: 200px; /* Fixed height for exactly 5 items */
        overflow-y: auto;
        overflow-x: hidden;
        border: 1px solid #dee2e6;
        border-radius: 0.375rem;
        padding: 0;
        background-color: #ffffff;
        box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    }

    .filter-search {
        position: sticky;
        top: 0;
        background-color: #f8f9fa;
        z-index: 10;
        margin: 0;
        padding: 0.75rem 0.5rem; /* Reduced horizontal padding */
        border-bottom: 1px solid #dee2e6;
    }

    .filter-search input {
        border: 1px solid #ced4da;
        border-radius: 0.25rem;
        padding: 0.375rem 0.75rem;
        font-size: 0.875rem;
    }

    .filter-search .btn {
        padding: 0.375rem 0.75rem;
        font-size: 0.875rem;
    }

    .filter-item-row {
        padding: 0.75rem 0.5rem; /* Reduced horizontal padding */
        margin: 0;
        border: none;
        border-bottom: 1px solid #f1f3f4;
        background-color: #ffffff;
        color: #000000;
        transition: background-color 0.2s ease;
        cursor: pointer;
        font-size: 0.875rem;
        line-height: 1.2;
    }

    .filter-item-row:last-child {
        border-bottom: none;
    }

    .filter-item-row:hover {
        background-color: #f8f9fa;
    }

    .filter-item-row input[type="checkbox"] {
        margin-right: 0.5rem;
        margin-top: 0.125rem;
    }

    .filter-count-badge {
        font-size: 0.75rem;
        padding: 0.25rem 0.5rem;
    }

    .date-filter-section {
        background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        color: white;
        border-radius: 0.5rem;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    }

    .date-filter-section .card-header {
        background: transparent !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.2);
        color: white;
    }

    .date-filter-section .form-control {
        background-color: rgba(255, 255, 255, 0.9);
        border: 1px solid rgba(255, 255, 255, 0.3);
    }

    .date-filter-section .btn-outline-light {
        border-color: rgba(255, 255, 255, 0.5);
        color: white;
    }

    .date-filter-section .btn-outline-light:hover {
        background-color: rgba(255, 255, 255, 0.1);
        border-color: white;
    }

    .chart-config-section {
        background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
        color: white;
        border-radius: 0.5rem;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    }

    .chart-config-section .card-header {
        background: transparent !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.2);
        color: white;
    }

    .chart-config-section .form-control,
    .chart-config-section .form-select {
        background-color: rgba(255, 255, 255, 0.9);
        border: 1px solid rgba(255, 255, 255, 0.3);
    }

    .chart-config-section .btn-outline-light {
        border-color: rgba(255, 255, 255, 0.5);
        color: white;
    }

    .chart-config-section .btn-outline-light:hover {
        background-color: rgba(255, 255, 255, 0.1);
        border-color: white;
    }

    .chart-config-item {
        background-color: rgba(255, 255, 255, 0.1);
        border: 1px solid rgba(255, 255, 255, 0.2);
        border-radius: 0.375rem;
        padding: 1rem;
        margin-bottom: 1rem;
    }

    .chart-config-item .form-label {
        color: white;
        font-weight: 500;
    }

    .formula-column-header {
        background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
        color: white;
        border: none;
        font-weight: 500;
    }

    .formula-column-header .form-control {
        background-color: rgba(255, 255, 255, 0.9);
        border: 1px solid rgba(255, 255, 255, 0.3);
        color: #333;
    }

    .card {
        border: none;
        box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
        transition: box-shadow 0.15s ease-in-out;
    }

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

    .scrollable-container::-webkit-scrollbar {
        width: 6px;
    }

    .scrollable-container::-webkit-scrollbar-track {
        background: #f1f1f1;
        border-radius: 3px;
    }

    .scrollable-container::-webkit-scrollbar-thumb {
        background: #c1c1c1;
        border-radius: 3px;
    }

    .scrollable-container::-webkit-scrollbar-thumb:hover {
        background: #a8a8a8;
    }

    .filter-container::-webkit-scrollbar {
        width: 6px;
    }

    .filter-container::-webkit-scrollbar-track {
        background: #f1f1f1;
        border-radius: 3px;
    }

    .filter-container::-webkit-scrollbar-thumb {
        background: #c1c1c1;
        border-radius: 3px;
    }

    .filter-container::-webkit-scrollbar-thumb:hover {
        background: #a8a8a8;
    }

    @media (max-width: 768px) {
        .filter-container {
            height: 150px; /* Smaller height on mobile */
        }
        
        .chart-config-section,
        .date-filter-section {
            margin-bottom: 1rem;
        }
        
        .filter-item-row {
            padding: 0.5rem 0.75rem;
            font-size: 0.8rem;
        }
    }