:root {
    --sidebar-width: 280px;
}

body {
    font-size: 0.95rem;
}

/* Sidebar */
.sidebar {
    position: fixed;
    top: 56px;
    bottom: 0;
    left: 0;
    z-index: 100;
    padding: 0;
    box-shadow: inset -1px 0 0 rgba(0, 0, 0, .1);
    overflow-y: auto;
}

.sidebar-heading {
    font-size: .75rem;
    text-transform: uppercase;
}

.sidebar .nav-link {
    font-weight: 500;
    color: var(--bs-body-color);
    padding: .75rem 1rem;
    transition: all 0.2s;
}

.sidebar .nav-link:hover {
    background-color: var(--bs-tertiary-bg);
}

.sidebar .nav-link.active {
    color: var(--bs-primary);
    background-color: var(--bs-primary-bg-subtle);
    border-left: 3px solid var(--bs-primary);
}

.sidebar .nav-link i {
    margin-right: 0.5rem;
    width: 20px;
    text-align: center;
}

/* Main content */
main {
    padding-top: 56px;
}

/* Cards */
.stat-card {
    transition: transform 0.2s, box-shadow 0.2s;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.stat-icon {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    font-size: 1.5rem;
}

/* Severity badges */
.badge-critical {
    background-color: #dc3545;
}

.badge-high {
    background-color: #fd7e14;
}

.badge-medium {
    background-color: #ffc107;
    color: #000;
}

.badge-low {
    background-color: #0dcaf0;
    color: #000;
}

/* Table enhancements */
.table-hover tbody tr {
    cursor: pointer;
    transition: background-color 0.2s;
}

/* Loading spinner */
.spinner-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 300px;
}

/* Modal improvements */
.modal-content {
    border-radius: 1rem;
}

/* Search box */
.search-box {
    position: relative;
}

.search-box .bi-search {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--bs-secondary);
}

.search-box input {
    padding-left: 40px;
}

/* Pagination */
.pagination {
    margin-bottom: 0;
}

/* Chart containers */
.chart-container {
    position: relative;
    height: 300px;
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bs-tertiary-bg);
}

::-webkit-scrollbar-thumb {
    background: var(--bs-secondary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--bs-secondary-hover);
}

/* Responsive */
@media (max-width: 767.98px) {
    .sidebar {
        position: relative;
        top: 0;
    }
    
    main {
        padding-top: 0;
    }
}

/* Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.3s ease-in;
}

/* Code blocks */
.code-block {
    background-color: var(--bs-secondary-bg);
    border: 1px solid var(--bs-border-color);
    border-radius: 0.375rem;
    padding: 1rem;
    font-family: 'Courier New', monospace;
    font-size: 0.875rem;
    overflow-x: auto;
}

/* Status indicators */
.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 0.5rem;
}

.status-dot.online {
    background-color: #198754;
}

.status-dot.offline {
    background-color: #6c757d;
}

/* Timeline */
.timeline {
    position: relative;
    padding-left: 30px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 10px;
    top: 0;
    bottom: 0;
    width: 2px;
    background-color: var(--bs-border-color);
}

.timeline-item {
    position: relative;
    padding-bottom: 20px;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -24px;
    top: 5px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: var(--bs-primary);
    border: 2px solid var(--bs-body-bg);
}

/* Utilities */
.cursor-pointer {
    cursor: pointer;
}

.text-break-word {
    word-break: break-word;
}
