﻿/* Variabili per Tema Dark e Accento */
:root {
    --accent-color: #CCFF00;
    --accent-color-hover: #b3e600;
    --bg-sidebar: #121212;
    --bg-main: #0a0a0a;
    --card-bg: #1a1a1a;
    --text-primary: #ffffff;
    --text-secondary: #a0a0a0;
    --border-color: rgba(255, 255, 255, 0.08);
}

/* Base Styles */
body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-main) !important;
    color: var(--text-primary);
    overflow-x: hidden;
}

/* Custom Utilities */
.accent-color {
    color: var(--accent-color) !important;
}

.bg-accent {
    background-color: var(--accent-color) !important;
}


.subtle-border {
    border-color: var(--border-color) !important;
}

.border-accent {
    border-top-color: var(--accent-color) !important;
}

.pulse-danger {
    position: relative;
    animation: pulse-danger-animation 2s infinite;
}

.pulse-warning {
    position: relative;
    animation: pulse-warning-animation 2s infinite;
}

@keyframes pulse-danger-animation {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(220, 53, 69, 0.6);
    }

    70% {
        transform: scale(1.03);
        box-shadow: 0 0 0 10px rgba(220, 53, 69, 0);
    }

    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(220, 53, 69, 0);
    }
}

@keyframes pulse-warning-animation {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 193, 7, 0.55); /* warning */
    }

    70% {
        transform: scale(1.03);
        box-shadow: 0 0 0 12px rgba(255, 193, 7, 0);
    }

    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 193, 7, 0);
    }
}

.extra-small {
    font-size: 0.65rem;
}


.backdrop-blur-sm {
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

/* Sidebar Styling */
#sidebar {
    min-width: 250px;
    max-width: 250px;
    background-color: var(--bg-sidebar) !important;
    min-height: 100vh;
    transition: all 0.3s ease;
}

    #sidebar.active {
        margin-left: -250px;
    }

.sidebar-header {
    background-color: transparent;
}

    .sidebar-header img {
        /* Trasforma qualsiasi colore del logo in bianco puro */
        filter: brightness(0) invert(1);
    }

#sidebar ul.components {
    padding: 20px 0;
}

#sidebar ul li a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.2s;
    font-weight: 500;
}

    #sidebar ul li a:hover {
        color: var(--text-primary);
        background: rgba(255, 255, 255, 0.05);
    }

    #sidebar ul li a.active {
        color: #000;
        background-color: var(--accent-color);
    }

        #sidebar ul li a.active i {
            color: #000 !important;
        }

/* Custom Main Components */
#content {
    background-color: var(--bg-main) !important;
    min-height: 100vh;
    transition: all 0.3s ease;
}

.navbar {
    background-color: var(--bg-sidebar) !important;
}

/* Cards */
.custom-card {
    background-color: var(--card-bg) !important;
    border-radius: 16px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

    .custom-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 10px 20px rgba(0,0,0,0.4) !important;
    }

.icon-box {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background-color: rgba(204, 255, 0, 0.1);
    color: var(--accent-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

/* Buttons */
.btn-custom {
    background-color: var(--accent-color);
    color: #000;
    border: none;
    border-radius: 8px;
    padding: 0.5rem 1.2rem;
    transition: all 0.2s;
}

    .btn-custom:hover {
        background-color: var(--accent-color-hover);
        transform: scale(1.02);
    }

.btn-outline-light {
    border-color: var(--border-color);
    color: var(--text-secondary);
}

    .btn-outline-light:hover {
        background-color: var(--border-color);
        color: var(--text-primary);
    }

.badge-cta {
    transition: all 0.2s ease;
}

    .badge-cta:hover {
        transform: scale(1.05);
        box-shadow: 0 0 10px rgba(204,255,0,0.4);
    }
/* Table */
.table-dark {
    --bs-table-bg: var(--card-bg);
    --bs-table-striped-bg: rgba(255, 255, 255, 0.02);
    border-color: var(--border-color);
}

.table-dark-subtle th {
    background-color: rgba(255, 255, 255, 0.02) !important;
    color: var(--text-secondary);
    font-weight: 500;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
    border-bottom: 2px solid var(--border-color);
}

.table > :not(caption) > * > * {
    padding: 1rem 0.5rem;
}

td .badge {
    font-weight: 500;
}

/* Chart Canvas adjustments */
canvas {
    max-height: 300px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    #sidebar {
        margin-left: -250px;
        position: absolute;
        z-index: 999;
    }

        #sidebar.active {
            margin-left: 0;
        }

    #sidebarCollapse {
        display: inline-block;
    }
}


