:root {
    --primary: #00f2fe;
    --secondary: #4facfe;
    --bg: #050608;
    --card-bg: rgba(18, 22, 30, 0.9);
    --text: #ffffff;
    --text-dim: #94a3b8;
    --success: #00ff88;
    --warning: #ffbb00;
    --orange: #ff8800;
    --danger: #ff4d4d;
    --glass-border: rgba(255, 255, 255, 0.1);
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Outfit', sans-serif; }

body {
    background: var(--bg);
    background-image: 
        radial-gradient(circle at 0% 0%, rgba(0, 242, 254, 0.1) 0%, transparent 40%),
        radial-gradient(circle at 100% 100%, rgba(79, 172, 254, 0.1) 0%, transparent 40%);
    color: var(--text);
    height: 100vh;
    display: flex;
    overflow: hidden;
}

/* Sidebar */
.sidebar {
    width: 280px;
    background: rgba(10, 14, 22, 0.8);
    backdrop-filter: blur(30px);
    border-right: 1px solid var(--glass-border);
    display: flex;
    flex-direction: column;
    padding: 60px 30px;
}

.logo-small {
    font-size: 20px;
    font-weight: 900;
    letter-spacing: 4px;
    background: linear-gradient(135deg, #fff, var(--primary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 70px;
}

.sidebar li {
    padding: 16px 22px;
    border-radius: 18px;
    margin-bottom: 12px;
    cursor: pointer;
    color: var(--text-dim);
    transition: all 0.3s;
    font-weight: 600;
}

.sidebar li.active {
    background: rgba(0, 242, 254, 0.1);
    color: var(--primary);
}

/* Main */
.content { flex-grow: 1; padding: 60px; overflow-y: auto; }
.page { display: none; }
.page.active { display: block; }

/* Cards */
.card {
    background: var(--card-bg);
    border: 1px solid var(--glass-border);
    border-radius: 32px;
    padding: 40px;
    margin-bottom: 30px;
}
.card h3 { font-size: 11px; text-transform: uppercase; letter-spacing: 3px; color: var(--text-dim); margin-bottom: 30px; }

/* SVG Gauges */
.gauge-container { position: relative; display: flex; justify-content: center; align-items: center; }
.gauge-track { fill: none; stroke: rgba(255, 255, 255, 0.05); stroke-linecap: round; }
.gauge-fill { fill: none; stroke-linecap: round; transition: stroke-dashoffset 1s cubic-bezier(0.4, 0, 0.2, 1), stroke 0.5s; }
.gauge-val-text { position: absolute; width: 100%; text-align: center; font-weight: 900; color: #fff; }

/* Disk Bar - Threshold Fix */
.disk-bar-bg { width: 100%; height: 16px; background: rgba(255,255,255,0.05); border-radius: 8px; overflow: hidden; margin: 15px 0; }
.disk-bar-fill { 
    height: 100%; 
    border-radius: 8px; 
    transition: width 1s ease-out;
    /* Red only appears after 90% */
    background: linear-gradient(to right, 
        #00ff88 0%, 
        #00ff88 60%, 
        #ffbb00 80%, 
        #ff4d4d 95%
    );
    background-size: 100% 100%;
}

/* Tables */
.table-card { padding: 50px; }
table { width: 100%; border-collapse: separate; border-spacing: 0 12px; }
th { text-align: left; padding: 0 25px 15px; color: var(--text-dim); font-size: 11px; text-transform: uppercase; letter-spacing: 2px; }
td { background: rgba(255,255,255,0.03); padding: 22px 25px; border: 1px solid rgba(255,255,255,0.02); }
td:first-child { border-radius: 20px 0 0 20px; }
td:last-child { border-radius: 0 20px 20px 0; }

.btn-action {
    background: rgba(255,255,255,0.08);
    border: 1px solid var(--glass-border);
    color: #fff;
    padding: 12px 20px;
    border-radius: 14px;
    cursor: pointer;
    font-weight: 700;
    font-size: 12px;
}
.btn-action:hover { background: #fff; color: #000; }
.btn-danger { color: var(--danger); border-color: rgba(255, 77, 77, 0.2); }
.btn-danger:hover { background: var(--danger); color: #fff; }

#login-overlay { position: fixed; inset: 0; background: #000; display: flex; justify-content: center; align-items: center; z-index: 9999; }
.login-box { width: 440px; padding: 60px; background: #0a0c10; border-radius: 40px; text-align: center; border: 1px solid var(--glass-border); }
.login-box input { width: 100%; padding: 20px; background: rgba(255,255,255,0.03); border: 1px solid var(--glass-border); border-radius: 18px; color: #fff; margin-bottom: 15px; outline: none; }
.login-box button { width: 100%; padding: 20px; border-radius: 18px; border: none; background: linear-gradient(135deg, var(--secondary), var(--primary)); color: #000; font-weight: 800; cursor: pointer; }
