/* IT Hardware Management System - Custom Stylesheet */
:root {
    --sidebar-bg: #0f172a;
    --sidebar-hover: #1e293b;
    --sidebar-active: #2563eb;
    --sidebar-text: #94a3b8;
    --sidebar-text-hover: #f8fafc;
    --content-bg: #f8fafc;
    --card-border: #e2e8f0;
    --primary-color: #2563eb;
    --primary-hover: #1d4ed8;
}

body {
    background-color: var(--content-bg);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: #1e293b;
    min-height: 100vh;
}

/* Sidebar Styling */
#sidebar {
    width: 270px;
    background-color: var(--sidebar-bg);
    min-height: 100vh;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1040;
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.05);
}

.sidebar-brand {
    padding: 1.25rem 1.5rem;
    font-weight: 700;
    font-size: 1.15rem;
    color: #f8fafc;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-brand .brand-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: linear-gradient(135deg, #2563eb, #38bdf8);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.2rem;
}

.nav-category {
    padding: 1rem 1.5rem 0.35rem 1.5rem;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #64748b;
}

.nav-module-link {
    color: var(--sidebar-text);
    padding: 0.65rem 1.25rem;
    margin: 0.15rem 0.75rem;
    border-radius: 8px;
    display: flex;
    align-items: center;
    font-weight: 500;
    font-size: 0.9rem;
    text-decoration: none;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
}

.nav-module-link:hover {
    color: var(--sidebar-text-hover);
    background-color: var(--sidebar-hover);
}

.nav-module-link.active {
    color: #ffffff;
    background: linear-gradient(90deg, rgba(37, 99, 235, 0.25), rgba(37, 99, 235, 0.08));
    border-left-color: #38bdf8;
    font-weight: 600;
}

.nav-module-link .module-icon {
    font-size: 1.15rem;
    margin-right: 0.85rem;
    width: 22px;
    text-align: center;
    color: #94a3b8;
}

.nav-module-link.active .module-icon {
    color: #38bdf8;
}

.nav-sub-item-link {
    color: #94a3b8;
    padding: 0.4rem 1.25rem 0.4rem 2.85rem;
    margin: 0.1rem 0.75rem;
    border-radius: 6px;
    display: flex;
    align-items: center;
    font-size: 0.825rem;
    text-decoration: none;
    transition: all 0.2s ease;
}

.nav-sub-item-link:hover {
    color: #f1f5f9;
    background-color: rgba(255, 255, 255, 0.04);
}

.nav-sub-item-link.active {
    color: #38bdf8;
    font-weight: 600;
    background-color: rgba(56, 189, 248, 0.08);
}

.nav-sub-item-link i {
    font-size: 0.65rem;
    margin-right: 0.65rem;
}

/* Main Content Area */
#main-content {
    flex-grow: 1;
    min-width: 0;
    background-color: var(--content-bg);
    overflow-y: auto;
}

/* Top Navbar */
.top-navbar {
    background-color: #ffffff;
    border-bottom: 1px solid var(--card-border);
    padding: 0.85rem 1.75rem;
}

/* Metric Cards */
.stat-card {
    background: #ffffff;
    border: 1px solid var(--card-border);
    border-radius: 12px;
    padding: 1.25rem 1.5rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.04);
}

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

/* Status Badges */
.badge-status {
    font-size: 0.75rem;
    padding: 0.35em 0.75em;
    font-weight: 600;
    border-radius: 9999px;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    display: inline-block;
}

/* Tables */
.table-custom {
    vertical-align: middle;
}

.table-custom thead th {
    background-color: #f8fafc;
    color: #475569;
    font-weight: 600;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    border-bottom: 2px solid #e2e8f0;
    padding: 0.85rem 1rem;
}

.table-custom tbody tr {
    transition: background-color 0.15s ease;
}

.table-custom tbody tr:hover {
    background-color: #f1f5f9;
}

.table-custom td {
    padding: 0.9rem 1rem;
    font-size: 0.875rem;
    color: #334155;
    border-bottom: 1px solid #e2e8f0;
}

/* Asset Tag Pill */
.asset-tag-badge {
    font-family: monospace;
    font-size: 0.85rem;
    font-weight: 700;
    color: #1e40af;
    background-color: #dbeafe;
    padding: 0.2rem 0.55rem;
    border-radius: 6px;
    border: 1px solid #bfdbfe;
    display: inline-block;
}

/* Card Container */
.card-shell {
    background: #ffffff;
    border: 1px solid var(--card-border);
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
}

/* Filter Bar */
.filter-card {
    background: #ffffff;
    border: 1px solid var(--card-border);
    border-radius: 10px;
    padding: 1rem 1.25rem;
}

/* Form Styles */
.form-label {
    font-weight: 600;
    font-size: 0.85rem;
    color: #334155;
    margin-bottom: 0.35rem;
}

.form-control, .form-select {
    border-radius: 8px;
    border: 1px solid #cbd5e1;
    padding: 0.6rem 0.85rem;
    font-size: 0.9rem;
}

.form-control:focus, .form-select:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

/* Pulse animation for live status */
.pulse-indicator {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-right: 4px;
}

.pulse-indicator.pulse-green {
    background-color: #10b981;
    box-shadow: 0 0 0 rgba(16, 185, 129, 0.4);
    animation: pulse-green 2s infinite;
}

@keyframes pulse-green {
    0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.4); }
    70% { box-shadow: 0 0 0 6px rgba(16, 185, 129, 0); }
    100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

/* Mobile Sidebar Behavior */
@media (max-width: 991.98px) {
    #sidebar {
        position: fixed;
        top: 0;
        bottom: 0;
        left: -270px;
    }
    #sidebar.show {
        left: 0;
    }
    .sidebar-backdrop {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(15, 23, 42, 0.5);
        z-index: 1030;
    }
}

