:root {
    --primary-gradient: linear-gradient(135deg, #4facfe 0%, #1e3a8a 100%);
    --secondary-gradient: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --success-gradient: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --warning-gradient: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
    --danger-gradient: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
    --dark-bg: #0f0f23;
    --card-bg: rgba(255, 255, 255, 0.05);
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --border-color: rgba(255, 255, 255, 0.1);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    --shadow-hover: 0 12px 40px rgba(0, 0, 0, 0.4);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--dark-bg);
    min-height: 100vh;
    color: var(--text-primary);
    overflow-x: hidden;
    position: relative;
}

/* Animated background */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 20% 80%, rgba(79, 172, 254, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(30, 58, 138, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(56, 189, 248, 0.2) 0%, transparent 50%);
    animation: bgShift 20s ease-in-out infinite;
    z-index: 0;
}

@keyframes bgShift {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

body {
    /* Default 75% zoom on desktop */
    zoom: 0.75;
}

@media (max-width: 768px) {
    body {
        zoom: 1;
    }
}

.container {
    position: relative;
    z-index: 1;
    max-width: 1600px;
    margin: 0 auto;
    padding: 2rem;
    overflow-y: auto;
    overflow-x: hidden;
    /* Performance optimizations for smooth scrolling */
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-y: contain;
}

.header {
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.header::before {
    content: '';
    position: absolute;
    top: -50px;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
    height: 200px;
    background: var(--primary-gradient);
    border-radius: 50%;
    opacity: 0.1;
    filter: blur(40px);
}

.header h1 {
    font-size: 3.5rem;
    font-weight: 700;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
    text-shadow: 0 0 30px rgba(79, 172, 254, 0.5);
    animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
    from { filter: drop-shadow(0 0 20px rgba(79, 172, 254, 0.5)); }
    to { filter: drop-shadow(0 0 30px rgba(79, 172, 254, 0.8)); }
}

.header p {
    font-size: 1.2rem;
    color: var(--text-secondary);
    font-weight: 300;
    margin-bottom: 0.75rem;
}

.header-links {
    display: flex;
    align-items: center;
    gap: 1rem;
    justify-content: center;
}

.version-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.version-current {
    font-family: 'Courier New', monospace;
    color: rgba(255, 255, 255, 0.6);
    background: rgba(255, 255, 255, 0.05);
    padding: 0.4rem 0.75rem;
    border-radius: 8px;
    font-size: 0.8rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.update-badge a {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    color: white;
    padding: 0.4rem 0.75rem;
    border-radius: 8px;
    text-decoration: none;
    font-size: 0.8rem;
    font-weight: 600;
    transition: all 0.2s ease;
    box-shadow: 0 2px 6px rgba(79, 172, 254, 0.3);
}

.update-badge a:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(79, 172, 254, 0.4);
}

.github-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.25rem;
    font-size: 0.9rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(10px);
}

.github-link:hover {
    color: rgba(255, 255, 255, 0.95);
    background: rgba(79, 172, 254, 0.12);
    border-color: rgba(79, 172, 254, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(79, 172, 254, 0.2);
}

.header .github-link svg {
    opacity: 0.8;
    transition: all 0.3s ease;
}

.header .github-link:hover svg {
    opacity: 1;
    transform: scale(1.05);
}

.status-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 1.5rem 2rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.status-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--success-gradient);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.gpu-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.gpu-card {
    background: linear-gradient(135deg, rgba(15, 15, 35, 0.85) 0%, rgba(20, 20, 50, 0.7) 100%);
    backdrop-filter: blur(30px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 32px;
    padding: 0;
    /* Performance: isolate rendering context & GPU acceleration */
    contain: layout style paint;
    will-change: transform;
    transform: translateZ(0);
    backface-visibility: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255, 255, 255, 0.05) inset;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.gpu-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 30% 20%, rgba(79, 172, 254, 0.08) 0%, transparent 60%);
    pointer-events: none;
    z-index: 0;
}

.gpu-card > * {
    position: relative;
    z-index: 1;
}

.gpu-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 48px rgba(79, 172, 254, 0.25), 0 0 0 1px rgba(79, 172, 254, 0.2) inset;
}

.gpu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.gpu-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
}

.gpu-name {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
}

.gpu-status {
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 500;
    background: var(--success-gradient);
    color: white;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Enhanced GPU Header */
.gpu-header-enhanced {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 0;
    padding: 2.5rem;
    background: linear-gradient(135deg, rgba(79, 172, 254, 0.12) 0%, rgba(30, 58, 138, 0.08) 100%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
}

.gpu-header-enhanced::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent 30%, rgba(255,255,255,0.03) 50%, transparent 70%);
    animation: shine 3s ease-in-out infinite;
}

@keyframes shine {
    0%, 100% { transform: translateX(-100%); }
    50% { transform: translateX(100%); }
}

.gpu-info-section {
    flex: 1;
    z-index: 2;
}

.gpu-title-large {
    font-size: 2rem;
    font-weight: 800;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
    letter-spacing: 1px;
}

.gpu-specs {
    display: flex;
    gap: 1.5rem;
    margin-top: 0.75rem;
    flex-wrap: wrap;
}

.spec-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.8rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.spec-mode {
    background: rgba(79, 172, 254, 0.15);
    border: 1px solid rgba(79, 172, 254, 0.3);
    color: #4facfe;
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.gpu-status-badge {
    padding: 0.75rem 1.5rem;
    background: rgba(67, 234, 123, 0.15);
    border: 2px solid rgba(67, 234, 123, 0.4);
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 700;
    color: #43e97b;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    letter-spacing: 1px;
    box-shadow: 0 0 20px rgba(67, 234, 123, 0.3);
    z-index: 2;
}

.status-text {
    text-shadow: 0 0 10px rgba(67, 234, 123, 0.5);
}

/* Circular Progress Gauge */
.metric-card-featured {
    grid-column: span 2;
    position: relative;
    overflow: hidden;
    padding: 2rem 0 !important; /* Remove left/right padding */
}

.util-background-chart {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    opacity: 0.2;
}

.metric-card-featured .metric-header,
.metric-card-featured .circular-progress-container,
.metric-card-featured .progress-bar {
    position: relative;
    z-index: 1;
    padding-left: 2rem;
    padding-right: 2rem;
}

.circular-progress-container {
    display: flex;
    justify-content: center;
    margin: 1rem 0;
}

.circular-progress {
    width: 150px;
    height: 150px;
}

.progress-ring-bg {
    fill: none;
    stroke: rgba(255, 255, 255, 0.1);
    stroke-width: 10;
}

.progress-ring {
    fill: none;
    stroke: url(#gradient);
    stroke-width: 10;
    stroke-linecap: round;
    stroke-dasharray: 314;
    transition: stroke-dashoffset 0.5s ease;
}

.progress-text {
    fill: white !important;
    font-size: 24px;
    font-weight: 700;
    text-anchor: middle;
    dominant-baseline: central;
    pointer-events: none;
    opacity: 1 !important;
    visibility: visible !important;
}

@media (max-width: 768px) {
    .metric-card-featured {
        grid-column: span 1;
    }
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.metrics-grid-enhanced {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    padding: 2.5rem;
    padding-top: 2rem;
}

.metric-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.06) 0%, rgba(255, 255, 255, 0.02) 100%);
    border-radius: 24px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: 2rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    /* Performance: isolate rendering */
    contain: layout style;
    position: relative;
    overflow: visible;
    backdrop-filter: blur(10px);
    min-width: 0;
}

.metric-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--primary-gradient);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.metric-card::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 24px;
    padding: 1px;
    background: linear-gradient(135deg, rgba(79, 172, 254, 0.2), rgba(30, 58, 138, 0.2));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.metric-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 60px rgba(79, 172, 254, 0.3);
}

.metric-card:hover::before,
.metric-card:hover::after {
    opacity: 1;
}

.metric-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
    opacity: 0.9;
}

.metric-label {
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-secondary);
}

.metric-value-large {
    font-size: 2.8rem;
    font-weight: 800;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
    line-height: 1;
    letter-spacing: -1px;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: nowrap;
    overflow: visible;
}

.temp-display {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.temp-gauge {
    width: 100%;
    max-width: 200px;
    height: 12px;
    background: linear-gradient(90deg,
        #48dbfb 0%,
        #4facfe 20%,
        #feca57 50%,
        #ff9a3c 70%,
        #ff6b6b 100%);
    border-radius: 20px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 0 20px rgba(255, 107, 107, 0.3);
}

.temp-gauge::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    animation: shimmer 2s infinite;
}

.temp-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.2rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 30px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-secondary);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.metric-sublabel {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.progress-bar {
    height: 6px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2);
}

.progress-fill {
    height: 100%;
    background: var(--success-gradient);
    border-radius: 12px;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    box-shadow: 0 0 10px rgba(79, 172, 254, 0.5);
}

.progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.mem-bar {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    box-shadow: 0 0 10px rgba(79, 172, 254, 0.5);
}

.power-bar {
    background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
    box-shadow: 0 0 10px rgba(67, 234, 123, 0.5);
}

.status-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #43e97b;
    margin-right: 0.5rem;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; box-shadow: 0 0 10px #43e97b; }
    50% { opacity: 0.5; box-shadow: 0 0 20px #43e97b; }
}

.metric {
    text-align: center;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 16px;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.metric::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--primary-gradient);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.metric:hover::before {
    transform: scaleX(1);
}

.metric:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.05);
}

.metric-value {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.metric-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 500;
}

.charts-section {
    padding: 0 2.5rem 2.5rem 2.5rem;
}

.chart-container {
    position: relative;
    height: 340px;
    margin-bottom: 2.5rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0.015) 100%);
    border-radius: 16px;
    /* Performance: optimize canvas rendering */
    contain: layout style;
    will-change: contents;
    padding: 16px 20px 32px 20px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 10px 30px rgba(0,0,0,0.25);
    overflow: visible;
}

.chart-container canvas {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
}

.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.chart-title {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.85);
    text-transform: uppercase;
    letter-spacing: 1.2px;
    font-weight: 600;
}

.chart-stats {
    display: flex;
    gap: 0.75rem;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.chart-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0.25rem 0.5rem;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.chart-stat-label {
    font-size: 0.55rem;
    opacity: 0.65;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
}

.chart-stat-value {
    font-size: 0.75rem;
    font-weight: 700;
    margin-top: 0.1rem;
}

.chart-stat-value.current {
    color: #4facfe;
}

.chart-stat-value.min {
    color: #43e97b;
}

.chart-stat-value.max {
    color: #fa709a;
}

.chart-stat-value.avg {
    color: #f093fb;
}

.processes-section {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 0;
    margin-top: 2rem;
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: all 0.3s ease;
}

.processes-header {
    padding: 1.25rem 1.75rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: background 0.2s ease;
    border-bottom: 1px solid transparent;
}

.processes-header:hover {
    background: rgba(255, 255, 255, 0.02);
}

.processes-header.expanded {
    border-bottom-color: var(--border-color);
}

.processes-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
    transition: color 0.2s ease;
}

.processes-header:hover .processes-toggle {
    color: var(--text-primary);
}

.toggle-icon {
    font-size: 0.75rem;
    transition: transform 0.3s ease;
}

.toggle-icon.expanded {
    transform: rotate(180deg);
}

.processes-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.processes-content.expanded {
    max-height: 500px;
}

.processes-inner {
    padding: 1.5rem;
}

.empty-state {
    text-align: center;
    padding: 2rem;
    color: var(--text-secondary);
}

.empty-state-text {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.empty-state-subtext {
    font-size: 0.8rem;
    opacity: 0.6;
}

.processes-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.process-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    margin: 0.75rem 0;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.process-item:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateX(8px);
}

.process-name {
    font-weight: 500;
    color: var(--text-primary);
}

.process-memory {
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
}

.system-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 2rem;
    margin-top: 2rem;
    box-shadow: var(--shadow);
}

.system-metric {
    text-align: center;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 16px;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.system-metric::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: linear-gradient(180deg, transparent 0%, rgba(79, 172, 254, 0.1) 100%);
    z-index: 0;
}

.system-metric > * {
    position: relative;
    z-index: 1;
}

.system-metric:hover {
    transform: translateY(-4px);
    background: rgba(255, 255, 255, 0.05);
}

.system-metric-chart {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50px;
    z-index: 0;
}

.system-metric-value {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.system-metric-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 500;
}

.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 200px;
    font-size: 1.1rem;
    color: var(--text-secondary);
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border-color);
    border-top: 3px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-right: 1rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Sleek Segmented Control Navigation */
.view-selector {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    margin-bottom: 2rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    padding: 0.25rem;
}

.view-option {
    padding: 0.6rem 1.5rem;
    background: transparent;
    border: none;
    border-radius: 10px;
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    white-space: nowrap;
    letter-spacing: 0.3px;
    min-width: 140px;
    text-align: center;
}

.view-option:hover:not(.active) {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.03);
}

.view-option.active {
    background: rgba(79, 172, 254, 0.15);
    color: white;
    box-shadow: 0 0 0 1px rgba(79, 172, 254, 0.3);
}

/* Tab Content with smooth transitions */
.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* Overview Grid - Compact comparison view */
.overview-grid {
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
    margin-bottom: 2rem;
}

/* Minimal Node Grouping */
.node-group {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.node-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: rgba(79, 172, 254, 0.9);
    text-transform: uppercase;
    letter-spacing: 1px;
    padding-left: 0.5rem;
    border-left: 3px solid rgba(79, 172, 254, 0.5);
}

.node-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.overview-gpu-card {
    background: linear-gradient(135deg, rgba(15, 15, 35, 0.9) 0%, rgba(20, 20, 50, 0.8) 100%);
    backdrop-filter: blur(30px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 28px;
    padding: 0;
    /* Performance: isolate rendering & GPU acceleration */
    contain: layout style paint;
    will-change: transform;
    transform: translateZ(0);
    backface-visibility: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.overview-gpu-card::after {
    content: 'Click to view full details →';
    position: absolute;
    bottom: 1rem;
    right: 1.5rem;
    color: var(--text-secondary);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.overview-gpu-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 48px rgba(79, 172, 254, 0.35);
    border-color: rgba(79, 172, 254, 0.4);
}

.overview-gpu-card:hover::after {
    opacity: 1;
}

.overview-header {
    padding: 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.overview-metrics {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.overview-metric {
    padding: 1.5rem;
    text-align: center;
    border-right: 1px solid rgba(255, 255, 255, 0.08);
    transition: background 0.3s ease;
}

.overview-metric:last-child {
    border-right: none;
}

.overview-metric:hover {
    background: rgba(255, 255, 255, 0.03);
}

.overview-metric-value {
    font-size: 1.8rem;
    font-weight: 800;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.25rem;
}

.overview-metric-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.overview-chart-section {
    padding: 2rem;
    padding-top: 1.5rem;
    padding-bottom: 2.5rem;
}

.overview-mini-chart {
    height: 160px;
    position: relative;
    background: linear-gradient(135deg, rgba(79, 172, 254, 0.03) 0%, rgba(30, 58, 138, 0.03) 100%);
    border-radius: 16px;
    padding: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

/* Detailed View - Full GPU card */
.detailed-view {
    max-width: 1600px;
    margin: 0 auto;
}

.gpu-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

/* Enhanced chart sizes for detailed view */
.detailed-view .chart-container {
    height: 340px;
    padding: 28px 36px 52px 36px;
}

@media (max-width: 1200px) {
    .node-grid {
        grid-template-columns: 1fr;
    }

    .overview-metrics {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }

    .header h1 {
        font-size: 2.5rem;
    }

    .view-option {
        font-size: 0.8rem;
        padding: 0.55rem 1.25rem;
        min-width: 100px;
    }

    .overview-metrics {
        grid-template-columns: repeat(2, 1fr);
    }

    .metrics-grid, .metrics-grid-enhanced {
        grid-template-columns: 1fr;
        gap: 1rem;
        padding: 1.5rem;
    }

    .system-info {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .chart-container {
        height: 200px;
        padding: 1rem;
        padding-left: 3rem;
        padding-bottom: 2.5rem;
    }

    .processes-title {
        font-size: 1.2rem;
    }

    .gpu-card {
        border-radius: 24px;
    }

    .gpu-header-enhanced {
        padding: 1.5rem;
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .gpu-title-large {
        font-size: 1.5rem;
    }

    .metric-card {
        padding: 1.5rem;
    }

    .metric-value-large {
        font-size: 2.2rem;
    }

    .overview-mini-chart {
        height: 120px;
    }

    .charts-section {
        padding: 0 1.5rem 1.5rem 1.5rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0.75rem;
    }

    .header h1 {
        font-size: 2rem;
    }

    .header p {
        font-size: 1rem;
    }

    .status-bar {
        padding: 1rem 1.5rem;
        flex-direction: column;
        gap: 0.75rem;
        align-items: flex-start;
    }

    .view-selector {
        flex-direction: column;
        gap: 0.5rem;
    }

    .view-option {
        width: 100%;
        padding: 0.75rem 1rem;
        min-width: auto;
    }

    .overview-metrics {
        grid-template-columns: 1fr;
    }

    .overview-metric {
        padding: 1rem;
    }

    .overview-metric-value {
        font-size: 1.5rem;
    }

    .overview-header {
        padding: 1.5rem;
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .gpu-header-enhanced {
        padding: 1.25rem;
    }

    .gpu-title-large {
        font-size: 1.25rem;
        letter-spacing: 0.5px;
    }

    .gpu-specs {
        gap: 0.75rem;
    }

    .spec-item {
        font-size: 0.75rem;
        padding: 0.3rem 0.6rem;
    }

    .metrics-grid-enhanced {
        grid-template-columns: 1fr;
        padding: 1.25rem;
        gap: 1rem;
    }

    .metric-card {
        padding: 1.25rem;
        border-radius: 16px;
    }

    .metric-value-large {
        font-size: 1.8rem;
    }

    .metric-label {
        font-size: 0.75rem;
    }

    .chart-container {
        height: 200px;
        padding: 1rem 0.5rem 0.5rem 0.5rem;
        margin-bottom: 1.5rem;
        background: linear-gradient(135deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.02) 100%);
        border-radius: 16px;
        border: 1px solid rgba(255, 255, 255, 0.1);
        position: relative;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
        display: flex;
        flex-direction: column;
    }

    .chart-header {
        position: relative;
        display: flex;
        justify-content: space-between;
        align-items: baseline;
        margin-bottom: 0.5rem;
        padding: 0 0.5rem;
        gap: 0.5rem;
        flex-shrink: 0;
    }

    .chart-stats {
        display: none;
    }

    .chart-title {
        font-size: 0.7rem;
        text-transform: uppercase;
        letter-spacing: 0.8px;
        font-weight: 600;
        color: rgba(255, 255, 255, 0.6);
        flex-shrink: 0;
    }

    /* Show current value prominently */
    .chart-header::after {
        content: attr(data-value);
        font-size: 1.5rem;
        font-weight: 800;
        background: var(--primary-gradient);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
        letter-spacing: -0.5px;
    }

    .chart-container canvas {
        display: block !important;
        position: relative !important;
        width: 100% !important;
        height: 120px !important;
        flex: 1;
    }

    .charts-section {
        padding: 1.25rem;
        display: flex;
        flex-direction: column;
        gap: 0;
    }

    .processes-header {
        padding: 1rem 1.25rem;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .processes-toggle {
        width: 100%;
        justify-content: space-between;
    }

    .process-item {
        padding: 0.75rem 1rem;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }

    .system-info {
        padding: 1.5rem;
        gap: 1rem;
    }

    .system-metric {
        padding: 1.25rem;
    }

    .system-metric-value {
        font-size: 1.5rem;
    }

    .circular-progress {
        width: 120px;
        height: 120px;
        overflow: visible !important;
    }

    .progress-text {
        font-size: 22px !important;
        fill: #ffffff !important;
        font-weight: 700 !important;
        opacity: 1 !important;
        visibility: visible !important;
        text-anchor: middle !important;
        dominant-baseline: central !important;
    }
    
    .circular-progress-container {
        overflow: visible !important;
    }
    
    /* Force text to show on mobile SVG */
    .circular-progress text {
        fill: #ffffff !important;
        opacity: 1 !important;
        visibility: visible !important;
        text-anchor: middle !important;
        dominant-baseline: central !important;
        transform: none !important;
    }

    .temp-gauge {
        max-width: 150px;
    }

    .footer-content {
        flex-direction: column;
        gap: 1rem;
    }

    .footer-links {
        flex-direction: column;
        gap: 0.75rem;
        text-align: center;
    }

    /* Ensure touch targets are large enough */
    .copy-btn,
    .cta,
    .github-link,
    button {
        min-height: 44px;
        padding: 0.75rem 1.25rem;
    }

    .overview-gpu-card {
        border-radius: 20px;
    }

    .overview-chart-section {
        padding: 1.25rem;
    }
}

@media (max-width: 375px) {
    .header h1 {
        font-size: 1.75rem;
    }

    .metric-value-large {
        font-size: 1.5rem;
    }

    .gpu-title-large {
        font-size: 1.1rem;
    }

    .overview-metric-value {
        font-size: 1.25rem;
    }

    .chart-container {
        height: 185px;
        padding: 0.85rem 0.5rem 0.5rem 0.5rem;
        margin-bottom: 1.25rem;
    }
    
    .chart-container canvas {
        flex: 1;
        height: 110px !important;
        display: block !important;
        width: 100% !important;
    }

    .chart-header {
        margin-bottom: 0.6rem;
    }

    .chart-title {
        font-size: 0.65rem;
        letter-spacing: 0.6px;
    }

    .chart-header::after {
        font-size: 1.35rem;
    }

    .overview-mini-chart {
        height: 90px;
    }

    .charts-section {
        padding: 1rem;
    }

    .circular-progress {
        width: 110px;
        height: 110px;
        overflow: visible !important;
    }

    .progress-text {
        font-size: 20px !important;
        fill: #ffffff !important;
        font-weight: 700 !important;
        opacity: 1 !important;
    }
    
    /* Force text to show on mobile SVG */
    .circular-progress text {
        fill: #ffffff !important;
        opacity: 1 !important;
        visibility: visible !important;
        text-anchor: middle !important;
        dominant-baseline: central !important;
        transform: none !important;
    }
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

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

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

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

/* Cluster/Hub Mode Styles */
.node-section {
    margin-bottom: 2rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
}

.node-header {
    background: rgba(255, 255, 255, 0.03);
    padding: 1rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
}

.node-name {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    letter-spacing: 0.02em;
}

.node-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.node-status .status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.node-status.online {
    color: #43e97b;
}

.node-status.online .status-dot {
    background: #43e97b;
    box-shadow: 0 0 8px rgba(67, 233, 123, 0.6);
}

.node-status.offline {
    color: #f5576c;
}

.node-status.offline .status-dot {
    background: #f5576c;
    box-shadow: 0 0 8px rgba(245, 87, 108, 0.6);
}

.node-gpus {
    padding: 1rem;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
}

