@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;600&family=Poppins:wght@300;400;600&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background: radial-gradient(circle at 20% 20%, #0f2027, #203a43, #2c5364);
    color: #fff;
    overflow-x: hidden;
}

/* Animated background glow */
body::before {
    content: "";
    position: fixed;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, #00f2ff33, transparent);
    top: -200px;
    left: -200px;
    animation: moveGlow 8s infinite alternate;
    z-index: -1;
}

@keyframes moveGlow {
    from {
        transform: translate(0, 0);
    }

    to {
        transform: translate(200px, 200px);
    }
}

/* Sidebar */

.sidebar {
    width: 240px;
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    background: #0a0f1c;
    padding: 25px;
    border-right: 1px solid #00f2ff33;
    transition: left 0.3s ease;
    z-index: 1000;
}

.sidebar h2 {
    font-family: 'Orbitron', sans-serif;
    text-align: center;
    margin-bottom: 40px;
    color: #00f2ff;
    text-shadow: 0 0 10px #00f2ff;
}

.sidebar ul {
    list-style: none;
}

.sidebar ul li {
    margin: 20px 0;
}

.sidebar ul li a {
    color: #fff;
    text-decoration: none;
    padding: 10px 15px;
    display: block;
    border-radius: 10px;
    transition: 0.3s;
}

.sidebar ul li a:hover {
    background: #00f2ff22;
    box-shadow: 0 0 10px #00f2ff;
}


/* Mobile hidden state */
@media(max-width: 768px) {
    .sidebar {
        left: -240px;
    }

    .sidebar.active {
        left: 0;
    }

    .main {
        margin-left: 0;
    }

    .menu-btn {
        display: inline-block;
    }
}

/* Desktop layout */
@media(min-width: 769px) {
    .main {
        margin-left: 240px;
    }

    .menu-btn {
        display: none;
    }
}

/* ===== PREMIUM SIDEBAR ===== */
.sidebar {
    width: 240px;
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    background: #0a0f1c;
    padding: 25px;
    border-right: 1px solid #00f2ff33;
    transition: left 0.3s ease;
    z-index: 1000;
}

.sidebar h2 {
    text-align: center;
    color: #00f2ff;
    text-shadow: 0 0 10px #00f2ff;
    margin-bottom: 40px;
}

/* Neon hover */
.sidebar ul li a {
    color: #fff;
    text-decoration: none;
    padding: 12px 15px;
    display: block;
    border-radius: 10px;
    transition: 0.3s;
}

.sidebar ul li a:hover {
    background: #00f2ff22;
    box-shadow: 0 0 10px #00f2ff;
}

/* Active link highlight */
.sidebar ul li a.active {
    background: #00f2ff33;
    box-shadow: 0 0 15px #00f2ff;
}

/* ===== Overlay background ===== */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(3px);
    display: none;
    z-index: 900;
}

.overlay.active {
    display: block;
}

/* ===== Responsive ===== */
@media(max-width: 768px) {
    .sidebar {
        left: -240px;
    }

    .sidebar.active {
        left: 0;
    }

    .main {
        margin-left: 0;
    }

    .menu-btn {
        display: inline-block;
        margin-bottom: 20px;
    }
}

@media(min-width: 769px) {
    .main {
        margin-left: 240px;
    }

    .menu-btn {
        display: none;
    }
}

/* Main */
.main {
    margin-left: 240px;
    padding: 40px;
}

h1 {
    font-family: 'Orbitron', sans-serif;
    margin-bottom: 30px;
    color: #00f2ff;
    text-shadow: 0 0 15px #00f2ff;
}

/* Cards */
.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.card {
    background: #111827;
    padding: 30px;
    border-radius: 20px;
    border: 1px solid #00f2ff33;
    box-shadow: 0 0 20px #00f2ff22;
    transition: 0.3s;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 0 25px #00f2ff;
}

.card h3 {
    margin-bottom: 10px;
}

.card p {
    font-size: 32px;
    font-weight: 600;
    color: #00f2ff;
}

/* Button */
button {
    padding: 12px 20px;
    border: none;
    border-radius: 10px;
    background: #00f2ff;
    color: #000;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 0 15px #00f2ff;
    margin-bottom: 20px;
}

/* AI Badge */
.ai-badge {
    display: inline-block;
    padding: 8px 15px;
    border-radius: 20px;
    background: #00f2ff22;
    color: #00f2ff;
    font-size: 12px;
    margin-bottom: 20px;
    box-shadow: 0 0 10px #00f2ff;
}

/* AI Search */
.ai-search {
    width: 100%;
    padding: 14px;
    margin: 20px 0;
    border-radius: 12px;
    border: 1px solid #00f2ff33;
    background: #0f172a;
    color: white;
}

.ai-search:focus {
    box-shadow: 0 0 10px #00f2ff;
}

/* Table wrapper */
.table-wrapper {
    overflow-x: auto;
}

/* Status badges */
.status-active {
    color: #00f2ff;
    font-weight: 600;
}

.status-inactive {
    color: #ff4c4c;
    font-weight: 600;
}

/* Risk badges */
.risk-low {
    color: #00ff99;
    font-weight: 600;
}

.risk-high {
    color: #ff4c4c;
    font-weight: 600;
}

/* Alert cards */
.alert-card {
    padding: 20px;
    margin: 15px 0;
    border-radius: 15px;
    backdrop-filter: blur(15px);
    background: #111827;
    border: 1px solid #00f2ff33;
    box-shadow: 0 0 15px #00f2ff22;
    transition: 0.3s;
}

.alert-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 0 25px #00f2ff;
}

.alert-card.high {
    border-left: 5px solid #ff4c4c;
}

.alert-card.medium {
    border-left: 5px solid #ffaa00;
}

.alert-card.low {
    border-left: 5px solid #00f2ff;
}

/* Blinking red border for critical alerts */
.alert-card.critical {
    animation: blinkBorder 1s infinite alternate;
}

@keyframes blinkBorder {
    from {
        box-shadow: 0 0 10px #ff0000;
    }

    to {
        box-shadow: 0 0 25px #ff0000;
    }
}

/* High-risk device pulse */
.risk-high {
    color: #ff4c4c;
    font-weight: 700;
    animation: pulseRisk 1.5s infinite;
}

@keyframes pulseRisk {
    0% {
        text-shadow: 0 0 5px #ff0000;
    }

    50% {
        text-shadow: 0 0 20px #ff0000;
    }

    100% {
        text-shadow: 0 0 5px #ff0000;
    }
}

/* Sidebar alert badge */
.alert-count {
    background: #ff0000;
    color: white;
    font-size: 12px;
    padding: 3px 8px;
    border-radius: 50px;
    margin-left: 8px;
}

/* AI scanning bar animation */
.risk-high::after {
    content: " • AI SCANNING...";
    font-size: 10px;
    margin-left: 5px;
    animation: scanning 1.5s infinite;
}

@keyframes scanning {
    0% {
        opacity: 0.3;
    }

    50% {
        opacity: 1;
    }

    100% {
        opacity: 0.3;
    }
}

/* JARVIS ORB */
.jarvis-orb {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: radial-gradient(circle, #00f2ff, #005f73);
    box-shadow: 0 0 30px #00f2ff;
    animation: pulseOrb 2s infinite;
    cursor: pointer;
}

@keyframes pulseOrb {
    0% {
        box-shadow: 0 0 15px #00f2ff;
    }

    50% {
        box-shadow: 0 0 35px #00f2ff;
    }

    100% {
        box-shadow: 0 0 15px #00f2ff;
    }
}

/* Row fade animation */
.fade-row {
    animation: fadeInRow 0.5s ease;
}

@keyframes fadeInRow {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Medium risk */
.risk-medium {
    color: #ffaa00;
    font-weight: 600;
}


@keyframes pulseRisk {
    0% { text-shadow: 0 0 5px #ff0000; }
    50% { text-shadow: 0 0 20px #ff0000; }
    100% { text-shadow: 0 0 5px #ff0000; }
}

/* ENTERPRISE ALERT SYSTEM */

.alert-card-enterprise {
    padding: 20px;
    margin: 15px 0;
    border-radius: 15px;
    background: #111827;
    border-left: 5px solid #00f2ff;
    box-shadow: 0 0 15px #00f2ff22;
    animation: fadeInAlert 0.4s ease;
    transition: 0.3s;
}

.alert-card-enterprise:hover {
    transform: translateY(-5px);
    box-shadow: 0 0 25px #00f2ff;
}

@keyframes fadeInAlert {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Severity Colors */
.alert-card-enterprise.low {
    border-left: 5px solid #00f2ff;
}

.alert-card-enterprise.medium {
    border-left: 5px solid #ffaa00;
}

.alert-card-enterprise.high {
    border-left: 5px solid #ff4c4c;
}

.alert-card-enterprise.critical {
    border-left: 5px solid #ff0000;
    animation: blinkCritical 1s infinite alternate;
}

@keyframes blinkCritical {
    from { box-shadow: 0 0 15px #ff0000; }
    to { box-shadow: 0 0 35px #ff0000; }
}