* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'IranSans', 'Segoe UI', system-ui, -apple-system, sans-serif;
}
:root {
    --primary: #4361ee;
    --primary-light: #4895ef;
    --primary-dark: #3a56d4;
    --secondary: #7209b7;
    --secondary-light: #9d4edd;
    --success: #06d6a0;
    --warning: #ffd166;
    --danger: #ef476f;
    --dark: #1a1a2e;
    --light: #f8f9fa;
    --gray: #6c757d;
    --border: #dee2e6;
    --card-bg: #ffffff;
    --sidebar-bg: #16213e;
    --sidebar-text: #e6e6e6;
    --sidebar-active: #0f3460;
    --shadow: rgba(0, 0, 0, 0.08);
    --surface: #1e1e2e;
    --surface-light: #2d2d44;
    --text: #e6e6e6;
    --text-secondary: #a0a0a0;
    --ai-color: #8b5cf6;
    --security-color: #7c3aed;
    --performance-color: #06b6d4;
    /* UI neutral tokens for components (adjust per theme) */
    --muted-border: rgba(255,255,255,0.04);
    --row-hover: rgba(255,255,255,0.02);
    --progress-bg: rgba(0,0,0,0.06);
    --badge-progress-bg: rgba(255,255,255,0.3);
}
.light-mode {
    --primary: #4361ee;
    --primary-light: #4895ef;
    --primary-dark: #3a56d4;
    --secondary: #7209b7;
    --secondary-light: #9d4edd;
    --success: #06d6a0;
    --warning: #ffd166;
    --danger: #ef476f;
    --dark: #f8f9fa;
    --light: #ffffff;
    --gray: #6c757d;
    --border: #dee2e6;
    --card-bg: #ffffff;
    --sidebar-bg: #e9ecef;
    --sidebar-text: #495057;
    --sidebar-active: #dfe0e1;
    --shadow: rgba(0, 0, 0, 0.08);
    --surface: #ffffff;
    --surface-light: #f1f3f5;
    --text: #212529;
    --text-secondary: #6c757d;
    --ai-color: #8b5cf6;
    --security-color: #7c3aed;
    --performance-color: #06b6d4;
    /* Light theme overrides for neutral tokens */
    --muted-border: rgba(0,0,0,0.08);
    --row-hover: rgba(0,0,0,0.03);
    --progress-bg: rgba(0,0,0,0.06);
    --badge-progress-bg: rgba(0,0,0,0.08);
}
body {
    background: linear-gradient(135deg, #0f3460 0%, #16213e 100%);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    padding: 16px;
    margin: 0;
    transition: background 0.3s ease, color 0.3s ease;
}
.light-mode {
    background: linear-gradient(135deg, #f0f2f5 0%, #e9ecef 100%);
}
.dashboard-container {
    max-width: 100%;
    width: 100%;
    background: var(--dark);
    border-radius: 16px;
    box-shadow: 0 10px 25px -5px var(--shadow);
    overflow: visible;
    display: flex;
    flex-direction: column;
    margin: 0 auto;
}
.light-mode .dashboard-container {
    background: var(--light);
    box-shadow: 0 10px 25px -5px rgba(0,0,0,0.1);
}
.dashboard-header {
    background: var(--surface);
    padding: 1rem 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.5rem;
    position: relative;
    z-index: 100;
}
.light-mode .dashboard-header {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
}
@media (min-width: 1201px) {
    .dashboard-header {
        position: sticky;
        top: 0;
        z-index: 1000;
        box-shadow: 0 1px 5px var(--shadow);
        transition: all 0.3s ease;
    }
}
.header-left {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    flex: 1;
}
.header-title h1 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text);
}
.header-title p {
    color: var(--text-secondary);
    font-size: 0.8rem;
    margin-top: 2px;
}
.search-container {
    flex: 1;
    max-width: 400px;
    position: relative;
}
.search-box {
    width: 100%;
    padding: 0.6rem 1rem 0.6rem 2.5rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    background: var(--surface-light);
    color: var(--text);
    font-size: 0.8rem;
    transition: all 0.3s ease;
}
.light-mode .search-box {
    background: #fff;
    border: 1px solid var(--border);
    color: var(--text);
}
.search-box:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(67, 97, 238, 0.2);
    outline: none;
}
.search-icon {
    position: absolute;
    left: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
}
.light-mode .search-icon {
    color: var(--text-secondary);
}
.header-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}
.company-badges {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    flex-direction: row-reverse;
}
.badge-container {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.badge {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.5rem 0.7rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    color: white;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}
.badge:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}
.badge-cost {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}
.badge-users {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
}
.badge-health {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}
.badge-health.medium {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}
.badge-health.low {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
}
.badge-security {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}
.badge-security.medium {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}
.badge-security.low {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
}
.badge-performance {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}
.badge-performance.medium {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}
.badge-performance.low {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
}
.badge-energy {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}
.badge-energy.medium {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}
.badge-energy.low {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
}
.badge-cloud {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}
.badge-cloud.medium {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}
.badge-cloud.low {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
}
.badge-icon {
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
}
.badge-text {
    font-size: 0.7rem;
    font-weight: 700;
}
.badge-tooltip {
    position: absolute;
    bottom: -40px;
    background: var(--dark);
    color: white;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    font-size: 0.7rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
    z-index: 100;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}
.light-mode .badge-tooltip {
    background: var(--light);
    color: var(--text);
    border: 1px solid var(--border);
}
.badge-tooltip::before {
    content: '';
    position: absolute;
    top: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-bottom: 5px solid var(--dark);
}
.light-mode .badge-tooltip::before {
    border-bottom: 5px solid var(--light);
    border-top: 5px solid transparent;
}
.badge-container:hover .badge-tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.badge-progress {
    width: 100%;
    height: 3px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
    margin-top: 0.4rem;
    overflow: hidden;
}
.light-mode .badge-progress {
    background: rgba(0, 0, 0, 0.1);
}
.badge-progress-bar {
    height: 100%;
    border-radius: 2px;
    background: white;
    transition: width 0.5s ease;
}
.light-mode .badge-progress-bar {
    background: var(--primary);
}
.user-profile {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.75rem;
    background: var(--surface-light);
    border-radius: 12px;
    font-size: 0.8rem;
    transition: background 0.2s ease;
    cursor: pointer;
    color: var(--text);
}
.light-mode .user-profile {
    background: #e9ecef;
    color: var(--text);
}
.user-profile:hover {
    background: rgba(255, 255, 255, 0.1);
}
.light-mode .user-profile:hover {
    background: #dfe0e1;
}
.avatar {
    width: 28px;
    height: 28px;
    background: var(--primary);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.75rem;
}
.dark-mode-toggle {
    position: relative;
    width: 40px;
    height: 24px;
    background: var(--surface-light);
    border-radius: 12px;
    cursor: pointer;
    transition: background 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
}
.light-mode .dark-mode-toggle {
    background: #e9ecef;
}
.dark-mode-toggle.active {
    background: var(--primary);
}
.hamburger-menu {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 24px;
    height: 18px;
    cursor: pointer;
    margin-left: 1rem;
    z-index: 1000;
    position: relative;
}
.hamburger-menu span {
    display: block;
    height: 2px;
    width: 100%;
    background: var(--text);
    border-radius: 2px;
    transition: all 0.3s ease;
    transform-origin: center;
}
.hamburger-menu.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}
.hamburger-menu.active span:nth-child(2) {
    opacity: 0;
}

.hamburger-menu.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}
.dashboard-content {
    display: grid;
    grid-template-columns: 60px 1fr;
    flex: 1;
    overflow: hidden;
    position: relative;
    transition: grid-template-columns 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.dashboard-content.sidebar-expanded {
    grid-template-columns: 240px 1fr;
}
.sidebar {
    background: var(--sidebar-bg);
    padding: 1rem 0.5rem;
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    overflow-y: auto;
    overflow-x: hidden;
    transition: right 0.3s ease;
    position: relative;
    z-index: 99;
    width: 60px;
}
.light-mode .sidebar {
    border-right: 1px solid var(--border);
}
.sidebar.expanded {
    width: 240px;
    padding: 1rem;
}
.sidebar-toggle {
    position: absolute;
    left: -12px;
    top: 20px;
    width: 24px;
    height: 24px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: pointer;
    box-shadow: 0 1px 4px rgba(67, 97, 238, 0.3);
    transition: all 0.2s ease;
    z-index: 100;
    border: 2px solid var(--sidebar-bg);
}
.light-mode .sidebar-toggle {
    border: 2px solid var(--light);
}
.sidebar-toggle:hover {
    background: var(--primary-dark);
    transform: scale(1.05);
}
.sidebar-toggle .toggle-icon {
    transition: transform 0.3s ease;
    font-size: 0.8rem;
}
.sidebar.expanded .sidebar-toggle .toggle-icon {
    transform: rotate(180deg);
}
.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 98;
    backdrop-filter: blur(2px);
}
.sidebar-overlay.active {
    display: block;
    animation: fadeIn 0.3s ease;
}
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
.service-categories {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-bottom: 1.5rem;
}
.category-title {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    margin: 0.75rem 0 0.25rem 0.5rem;
    letter-spacing: 0.5px;
    white-space: nowrap;
    overflow: hidden;
    opacity: 1;
    transition: opacity 0.2s ease;
}
.light-mode .category-title {
    color: var(--text-secondary);
}
.sidebar:not(.expanded) .category-title {
    opacity: 0;
    height: 0;
    margin: 0;
}
.service-item {
    padding: 0.6rem 0.75rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    color: var(--sidebar-text);
    font-size: 0.8rem;
    font-weight: 500;
    position: relative;
    user-select: none;
    white-space: nowrap;
    overflow: hidden;
}
.light-mode .service-item {
    color: var(--text);
}
.service-item:hover {
    background: var(--sidebar-active);
    color: white;
    transform: translateX(0);
}
.light-mode .service-item:hover {
    background: #dfe0e1;
    color: var(--text);
}
.service-item.active {
    background: var(--primary);
    color: white;
    box-shadow: 0 1px 3px rgba(67, 97, 238, 0.1);
}
.light-mode .service-item.active {
    background: var(--primary);
    color: white;
}
.service-item.active::before {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 60%;
    background: var(--primary-dark);
    border-radius: 2px;
}
.service-icon {
    font-size: 1.2rem;
    width: 24px;
    text-align: center;
    transition: transform 0.2s ease;
    flex-shrink: 0;
}
.service-item:hover .service-icon {
    transform: scale(1.05);
}
.service-item-tooltip {
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    background: var(--dark);
    color: white;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    font-size: 0.7rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, transform 0.3s ease;
    z-index: 100;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    margin-left: 10px;
}
.light-mode .service-item-tooltip {
    background: var(--light);
    color: var(--text);
    border: 1px solid var(--border);
}
.service-item-tooltip::before {
    content: '';
    position: absolute;
    right: 100%;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-top: 5px solid transparent;
    border-bottom: 5px solid transparent;
    border-left: 5px solid var(--dark);
}
.light-mode .service-item-tooltip::before {
    border-left: 5px solid var(--light);
    border-right: 5px solid transparent;
}
.sidebar:not(.expanded) .service-item:hover .service-item-tooltip {
    opacity: 1;
    visibility: visible;
}
.main-content {
    padding: 1rem;
    background: var(--dark);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    transition: margin-right 0.3s ease;
}
.light-mode .main-content {
    background: var(--light);
}
.top-section {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}
.top-card {
    background: var(--surface-light);
    border-radius: 12px;
    box-shadow: 0 1px 4px var(--shadow);
    border: 1px solid rgba(255, 255, 255, 0.05);
    overflow: hidden;
    transition: all 0.2s ease;
}
.light-mode .top-card {
    background: var(--light);
    border: 1px solid var(--border);
    box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}
.top-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 8px var(--shadow);
}
.card-header {
    padding: 1rem 1.25rem 0.75rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.light-mode .card-header {
    border-bottom: 1px solid var(--border);
}
.card-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.card-badge {
    background: var(--ai-color);
    color: white;
    padding: 0.2rem 0.5rem;
    border-radius: 6px;
    font-size: 0.65rem;
    font-weight: 600;
}
.card-content {
    padding: 1rem 1.25rem;
}
.view-all-btn {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text);
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 0.25rem 0.6rem;
    border-radius: 4px;
    font-size: 0.65rem;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s ease;
}
.light-mode .view-all-btn {
    background: #e9ecef;
    color: var(--text);
    border: 1px solid var(--border);
}
.view-all-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    color: var(--text);
}
.light-mode .view-all-btn:hover {
    background: #dfe0e1;
    color: var(--text);
}
.recommendation-item {
    display: flex;
    gap: 0.75rem;
    padding: 0.75rem;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.03);
    margin-bottom: 0.75rem;
    transition: all 0.2s ease;
}
.light-mode .recommendation-item {
    background: #f8f9fa;
}
.recommendation-item:hover {
    background: rgba(255, 255, 255, 0.06);
}
.light-mode .recommendation-item:hover {
    background: #e9ecef;
}
.recommendation-item:last-child {
    margin-bottom: 0;
}
.rec-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: white;
    flex-shrink: 0;
}
.rec-content {
    flex: 1;
}
.rec-title {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 0.25rem;
}
.rec-description {
    font-size: 0.7rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
    line-height: 1.4;
}
.rec-actions {
    display: flex;
    gap: 0.5rem;
}
.rec-btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0.25rem 0.6rem;
    border-radius: 4px;
    font-size: 0.65rem;
    cursor: pointer;
    font-weight: 500;
    transition: background 0.2s ease;
}
.rec-btn:hover {
    background: var(--primary-dark);
}
.rec-btn-cancel {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
    border: 1px solid rgba(255, 255, 255, 0.15);
}
.light-mode .rec-btn-cancel {
    background: #e9ecef;
    color: var(--text-secondary);
    border: 1px solid var(--border);
}
.rec-btn-cancel:hover {
    background: rgba(255, 255, 255, 0.15);
    color: var(--text);
}
.light-mode .rec-btn-cancel:hover {
    background: #dfe0e1;
    color: var(--text);
}
.event-list, .alert-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}
.event-item, .alert-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.75rem;
    border-radius: 8px;
    transition: all 0.2s ease;
}
.event-item:hover, .alert-item:hover {
    background: rgba(255, 255, 255, 0.03);
}
.light-mode .event-item:hover, .light-mode .alert-item:hover {
    background: #f8f9fa;
}
.event-icon, .alert-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: white;
    flex-shrink: 0;
}
.event-content, .alert-content {
    flex: 1;
}
.event-title, .alert-title {
    font-size: 0.75rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
    line-height: 1.3;
    color: var(--text);
}
.event-time, .alert-time {
    font-size: 0.65rem;
    color: var(--text-secondary);
}
.alert-critical {
    background: rgba(239, 71, 111, 0.08);
    border-right: 3px solid var(--danger);
}
.light-mode .alert-critical {
    background: #ffebee;
}
.alert-warning {
    background: rgba(255, 209, 102, 0.08);
    border-right: 3px solid var(--warning);
}
.light-mode .alert-warning {
    background: #fff8e1;
}
.alert-info {
    background: rgba(67, 97, 238, 0.08);
    border-right: 3px solid var(--primary);
}
.light-mode .alert-info {
    background: #e3f2fd;
}
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 0.75rem;
    margin-bottom: 1rem;
}
.metric-card {
    background: var(--surface-light);
    padding: 1rem;
    border-radius: 10px;
    box-shadow: 0 1px 3px var(--shadow);
    border: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
}
.light-mode .metric-card {
    background: var(--light);
    border: 1px solid var(--border);
}
.metric-card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    height: 4px;
    background: var(--primary);
    opacity: 0.7;
}
.metric-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}
.metric-title {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--text-secondary);
}
.metric-icon {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    color: white;
}
.metric-value {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 0.25rem;
}
.metric-trend {
    font-size: 0.65rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.2rem;
    margin-bottom: 0.3rem;
}
.trend-up { color: var(--success); }
.trend-down { color: var(--danger); }
.trend-neutral { color: var(--text-secondary); }
.metric-details {
    font-size: 0.6rem;
    color: var(--text-secondary);
}
.metric-chart {
    height: 40px;
    margin-top: 0.5rem;
    position: relative;
}
.metric-chart svg {
    width: 100%;
    height: 100%;
}
.metric-chart svg path {
    transition: all 0.3s ease;
}
.chart-container {
    position: relative;
    width: 100%;
    height: 100%;
}
.chart-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}
.chart-grid-line {
    stroke: rgba(255, 255, 255, 0.05);
    stroke-width: 1;
}
.light-mode .chart-grid-line {
    stroke: rgba(0, 0, 0, 0.05);
}
.chart-area {
    fill: rgba(67, 97, 238, 0.1);
    stroke: none;
}
.network-traffic {
    background: var(--surface-light);
    padding: 1.25rem;
    border-radius: 12px;
    box-shadow: 0 1px 4px var(--shadow);
    border: 1px solid rgba(255, 255, 255, 0.05);
    margin-bottom: 1rem;
}
.light-mode .network-traffic {
    background: var(--light);
    border: 1px solid var(--border);
}
.traffic-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
}
.section-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text);
}
.traffic-overview {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-bottom: 1.25rem;
}
.traffic-stat {
    text-align: center;
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    border-top: 3px solid;
    transition: transform 0.2s ease;
}
.light-mode .traffic-stat {
    background: #f8f9fa;
}
.traffic-stat:hover {
    transform: translateY(-2px);
}
.traffic-stat:nth-child(1) {
    border-color: var(--primary);
}
.traffic-stat:nth-child(2) {
    border-color: var(--success);
}
.traffic-stat:nth-child(3) {
    border-color: var(--warning);
}
.traffic-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 0.25rem;
}
.traffic-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    font-weight: 500;
    margin-bottom: 0.4rem;
}
.traffic-trend {
    font-size: 0.65rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
}
.traffic-chart-container {
    background: rgba(255, 255, 255, 0.02);
    border-radius: 8px;
    padding: 1rem;
    position: relative;
    height: 200px;
}
.light-mode .traffic-chart-container {
    background: #f8f9fa;
}
.chart-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
}
.traffic-chart {
    height: 100%;
    position: relative;
    width: 100%;
}
.chart-overlay {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    pointer-events: none;
    z-index: 10;
}
.chart-legend-mini {
    position: absolute;
    top: 8px;
    left: 8px;
    background: rgba(30, 30, 46, 0.85);
    backdrop-filter: blur(4px);
    border-radius: 6px;
    padding: 6px 10px;
    display: flex;
    gap: 12px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.05);
}
.light-mode .chart-legend-mini {
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid var(--border);
    color: var(--text);
}
.legend-item-mini {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.65rem;
    color: var(--text);
    font-weight: 500;
}
.legend-color-mini {
    width: 8px;
    height: 8px;
    border-radius: 2px;
}
.peak-indicator {
    position: absolute;
    bottom: 8px;
    left: 8px;
    background: rgba(30, 30, 46, 0.85);
    backdrop-filter: blur(4px);
    border-radius: 6px;
    padding: 6px 10px;
    font-size: 0.6rem;
    font-weight: 600;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    gap: 4px;
}
.light-mode .peak-indicator {
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid var(--border);
    color: var(--text);
}
.peak-indicator.inbound {
    color: var(--primary);
}
.x-axis-labels {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    padding: 0 10px;
}
.x-axis-label {
    font-size: 0.6rem;
    color: var(--text-secondary);
    text-align: center;
}
.resource-usage {
    background: var(--surface-light);
    padding: 1rem;
    border-radius: 10px;
    box-shadow: 0 1px 3px var(--shadow);
    border: 1px solid rgba(255, 255, 255, 0.05);
    margin-bottom: 1rem;
}
.light-mode .resource-usage {
    background: var(--light);
    border: 1px solid var(--border);
}
.resource-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 1rem;
}
.resource-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 0.75rem;
}
.resource-card {
    background: rgba(255, 255, 255, 0.03);
    padding: 0.75rem;
    border-radius: 8px;
    text-align: center;
    transition: transform 0.2s ease;
}
.light-mode .resource-card {
    background: #f8f9fa;
}
.resource-card:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.06);
}
.light-mode .resource-card:hover {
    background: #e9ecef;
}
.resource-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: white;
    margin: 0 auto 0.5rem;
}
.resource-name {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 0.3rem;
}
.resource-percentage {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 0.2rem;
}
.resource-progress {
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    overflow: hidden;
    margin-top: 0.3rem;
}
.light-mode .resource-progress {
    background: rgba(0, 0, 0, 0.1);
}
.resource-bar {
    height: 100%;
    border-radius: 2px;
    transition: width 0.5s ease;
}
.resource-actions {
    display: flex;
    justify-content: center;
    gap: 0.3rem;
    margin-top: 0.5rem;
}
.resource-action-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 0.7rem;
    color: var(--text);
    transition: all 0.2s ease;
}
.light-mode .resource-action-btn {
    background: #e9ecef;
    border: 1px solid var(--border);
    color: var(--text);
}
.resource-action-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: scale(1.05);
}
.light-mode .resource-action-btn:hover {
    background: #dfe0e1;
}
.resource-action-btn.settings {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-secondary);
    border: 1px solid rgba(255, 255, 255, 0.1);
}
.light-mode .resource-action-btn.settings {
    background: #e9ecef;
    color: var(--text-secondary);
    border: 1px solid var(--border);
}
.resource-action-btn.settings:hover {
     background: rgba(255, 255, 255, 0.1);
     color: var(--text);
     transform: scale(1.05);
}
.light-mode .resource-action-btn.settings:hover {
     background: #dfe0e1;
     color: var(--text);
}
.services-section {
    background: var(--surface-light);
    padding: 1rem;
    border-radius: 10px;
    box-shadow: 0 1px 3px var(--shadow);
    border: 1px solid rgba(255, 255, 255, 0.05);
    margin-bottom: 1rem;
}
.light-mode .services-section {
    background: var(--light);
    border: 1px solid var(--border);
}
.misc-services-container {
    overflow-x: auto;
    padding-bottom: 0.5rem;
    margin-bottom: 0.5rem;
}
.misc-services-container::-webkit-scrollbar {
    height: 6px;
}
.misc-services-container::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 3px;
}
.light-mode .misc-services-container::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.1);
}
.misc-services-container::-webkit-scrollbar-thumb {
    background: var(--gray);
    border-radius: 3px;
}
.misc-services-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 0.5rem;
    min-width: 1200px;
}
.misc-service-card {
    background: rgba(255, 255, 255, 0.03);
    padding: 0.6rem;
    border-radius: 6px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.05);
    text-align: center;
    transition: transform 0.2s ease;
}
.light-mode .misc-service-card {
    background: #f8f9fa;
    border: 1px solid var(--border);
}
.misc-service-card:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.06);
}
.light-mode .misc-service-card:hover {
    background: #e9ecef;
}
.misc-service-icon {
    width: 24px;
    height: 24px;
    border-radius: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.8rem;
    margin: 0 auto 0.3rem;
}
.misc-service-title {
    font-size: 0.65rem;
    font-weight: 600;
    margin-bottom: 0.1rem;
    color: var(--text);
}
.misc-service-status {
    font-size: 0.6rem;
    color: var(--success);
    font-weight: 600;
}
.dashboard-footer {
    background: var(--sidebar-bg);
    padding: 1rem 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.7rem;
    color: var(--text-secondary);
}
.light-mode .dashboard-footer {
    background: #e9ecef;
    border-top: 1px solid var(--border);
    color: var(--text-secondary);
}
.footer-links {
    display: flex;
    gap: 1rem;
}
.footer-link {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.2s ease;
}
.footer-link:hover {
    color: var(--primary);
}
.notification-bell {
    position: relative;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 8px;
    transition: background 0.2s ease;
}
.notification-bell:hover {
    background: rgba(255, 255, 255, 0.1);
}
.light-mode .notification-bell:hover {
    background: #e9ecef;
}
.notification-badge {
    position: absolute;
    top: 0;
    left: 0;
    width: 16px;
    height: 16px;
    background: var(--danger);
    color: white;
    border-radius: 50%;
    font-size: 0.6rem;
    display: flex;
    align-items: center;
    justify-content: center;
}
@keyframes pulse {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(239, 71, 111, 0.7); }
    70% { transform: scale(1.1); box-shadow: 0 0 0 8px rgba(239, 71, 111, 0); }
    100% { transform: scale(1); }
}
.notification-badge {
    animation: pulse 2s infinite;
}
.capacity-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
}
.capacity-bar {
    flex: 1;
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    overflow: hidden;
}
.light-mode .capacity-bar {
    background: rgba(0, 0, 0, 0.1);
}
.capacity-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.5s ease;
}
.capacity-text {
    font-size: 0.65rem;
    color: var(--text-secondary);
    white-space: nowrap;
}
.metric-chart svg {
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.1));
}
.badge-progress-bar, .resource-bar {
    animation: progressFill 1s ease-out;
}
@keyframes progressFill {
    from { width: 0; }
}
@media (max-width: 768px) {
    .header-actions {
        position: relative;
    }
    .company-badges {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--surface);
        padding: 0.5rem;
        border-radius: 8px;
        box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
        z-index: 10;
        display: none;
        flex-wrap: wrap;
        justify-content: center;
    }
    .light-mode .company-badges {
        background: var(--light);
        border: 1px solid var(--border);
    }
    .company-badges.active {
        display: flex;
    }
}
@media (max-width: 1200px) {
    .company-badges {
        display: none !important;
    }
}
@media (max-width: 1400px) {
    .dashboard-container {
        max-width: 95vw;
    }
    .misc-services-grid {
        grid-template-columns: repeat(8, 1fr);
    }
}
@media (max-width: 1200px) {
    .dashboard-content {
        grid-template-columns: 1fr;
    }
    .dashboard-content.sidebar-expanded {
        grid-template-columns: 1fr;
    }
    .sidebar {
        position: fixed;
        top: 0;
        right: -280px;
        bottom: 0;
        width: 280px;
        z-index: 999;
        box-shadow: -2px 0 8px rgba(0, 0, 0, 0.1);
        transition: right 0.3s ease;
        padding: 1rem;
    }
    .sidebar.active {
        right: 0;
    }
    .sidebar-toggle {
        display: none;
    }
    .sidebar-overlay.active {
        display: block;
    }
    .hamburger-menu {
        display: flex;
    }
    .metrics-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .resource-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .misc-services-grid {
        grid-template-columns: repeat(6, 1fr);
    }
    .top-section {
        grid-template-columns: 1fr;
    }
    .company-badges {
        display: flex;
        flex-direction: row-reverse;
    }
}
@media (max-width: 768px) {
    .metrics-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .resource-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .misc-services-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    .header-actions {
        flex-direction: column;
        gap: 0.5rem;
    }
    .traffic-overview {
        grid-template-columns: 1fr;
    }
    .traffic-chart-container {
        height: 150px;
    }
}
@media (max-width: 480px) {
    .dashboard-header {
        padding: 0.75rem 1rem;
    }
    .header-left {
        gap: 0.75rem;
    }
    .header-title h1 {
        font-size: 1rem;
    }
    .search-container {
        display: none;
    }
    .metrics-grid {
        grid-template-columns: 1fr;
    }
    .resource-grid {
        grid-template-columns: 1fr;
    }
    .misc-services-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}
.top-card, .metric-card, .resource-card, .misc-service-card {
    animation: fadeInUp 0.4s ease-out forwards;
    opacity: 0;
    transform: translateY(15px);
}
.top-card:nth-child(1) { animation-delay: 0.1s; }
.top-card:nth-child(2) { animation-delay: 0.15s; }
.top-card:nth-child(3) { animation-delay: 0.2s; }
.metric-card:nth-child(1) { animation-delay: 0.1s; }
.metric-card:nth-child(2) { animation-delay: 0.12s; }
.metric-card:nth-child(3) { animation-delay: 0.14s; }
.metric-card:nth-child(4) { animation-delay: 0.16s; }
.metric-card:nth-child(5) { animation-delay: 0.18s; }
.metric-card:nth-child(6) { animation-delay: 0.2s; }
@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Cloud Drive specific styles */
.cloud-drive-page {
    padding: 1rem;
    background: linear-gradient(180deg, rgba(255,255,255,0.02), transparent);
    border-radius: 12px;
}
.cloud-drive-page .page-title {
    font-size: 1.4rem;
    margin-bottom: 0.75rem;
    color: var(--text);
}
.drive-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}
.upload-area {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    background: var(--surface-light);
    padding: 0.5rem 0.75rem;
    border-radius: 10px;
    border: 1px solid var(--border);
}
.upload-label { color: var(--text-secondary); font-size: 0.85rem; }
.action-btn, .btn-download {
    padding: 0.45rem 0.8rem;
    border-radius: 8px;
    background: var(--primary);
    color: white;
    border: none;
    cursor: pointer;
    font-size: 0.85rem;
}
.action-btn:hover, .btn-download:hover { filter: brightness(0.95); }
.drive-search input, #drive-search {
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text);
    min-width: 220px;
}
.drive-list { margin-top: 1rem; overflow: auto; }
.drive-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--surface-light);
    border-radius: 8px;
    overflow: hidden;
}
.drive-table thead tr { background: rgba(0,0,0,0.06); }
.drive-table th, .drive-table td {
    padding: 0.85rem 0.75rem;
    text-align: right;
    border-bottom: 1px solid rgba(255,255,255,0.04);
    color: var(--text);
    font-size: 0.9rem;
}
.drive-table tbody tr:hover { background: rgba(255,255,255,0.03); }
.drive-footer { margin-top: 1rem; color: var(--text-secondary); font-size: 0.9rem; }

@media (max-width: 800px) {
    .drive-actions { flex-direction: column; align-items: stretch; }
    .drive-search input { width: 100%; }
}