/**
 * Skills Section - System Monitoring Dashboard
 * =============================================
 */

.dashboard-section {
    padding: var(--spacing-2xl) 0;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

/* === MODULE CARD === */
.skill-module {
    position: relative;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 20px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(10px);
}



.skill-module:hover {
    background: rgba(var(--accent-primary-rgb), 0.05);
    border-color: rgba(var(--accent-primary-rgb), 0.3);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

/* Header */
.module-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: monospace;
    font-size: 0.65rem;
    margin-bottom: 15px;
    opacity: 0.6;
    letter-spacing: 1px;
}

.module-status {
    color: #10b981;
    display: flex;
    align-items: center;
    gap: 5px;
}

.module-status::before {
    content: '';
    width: 6px;
    height: 6px;
    background: currentColor;
    border-radius: 50%;
    box-shadow: 0 0 8px currentColor;
    animation: blink 2s infinite;
}

/* Body */
.module-body {
    display: flex;
    gap: 20px;
    align-items: center;
}

.skill-icon-box {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 2rem;
    color: var(--accent-primary);
    transition: all 0.3s;
}

.skill-module:hover .skill-icon-box {
    background: rgba(var(--accent-primary-rgb), 0.1);
    border-color: var(--accent-primary);
    transform: scale(1.1) rotate(5deg);
}

.skill-info {
    flex: 1;
}

.skill-name {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 2px;
}

.skill-category {
    font-size: 0.7rem;
    text-transform: uppercase;
    color: var(--text-muted);
    letter-spacing: 1px;
}

/* Data Stream (Progress) */
.data-stream {
    margin-top: 15px;
}

.stream-label {
    font-family: monospace;
    font-size: 0.6rem;
    margin-bottom: 4px;
    opacity: 0.5;
}

.stream-bar {
    width: 100%;
    height: 8px;
    /* Thicker for better visibility */
    background: var(--bg-tertiary);
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    border: 1px solid var(--border-color);
}


.stream-fill {
    height: 100%;
    background: var(--accent-primary);
    box-shadow: 0 0 15px var(--accent-primary);
    position: relative;
    transition: width 1s ease-out;
}

/* Pulsing glow animation for the fill */
.stream-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, var(--accent-primary), transparent);
    opacity: 0.3;
    animation: bar-shine 2s infinite;
}

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

    100% {
        transform: translateX(100%);
    }
}

.stream-value {
    font-family: monospace;
    font-size: 0.8rem;
    /* Slightly larger */
    font-weight: 700;
    text-align: right;
    margin-top: 6px;
    color: var(--accent-primary);
    text-shadow: 0 0 10px rgba(var(--accent-primary-rgb), 0.3);
}

/* Decorative Elements */
.module-corner {
    position: absolute;
    width: 10px;
    height: 10px;
    border: 1px solid rgba(var(--accent-primary-rgb), 0.3);
    pointer-events: none;
}

.top-left {
    top: 5px;
    left: 5px;
    border-right: none;
    border-bottom: none;
}

.bottom-right {
    bottom: 5px;
    right: 5px;
    border-left: none;
    border-top: none;
}

/* Scanner Effect */
.module-scanner {
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg,
            transparent,
            rgba(var(--accent-primary-rgb), 0.05),
            transparent);
    pointer-events: none;
}

.skill-module:hover .module-scanner {
    animation: scan 2s linear infinite;
}

@keyframes scan {
    0% {
        left: -100%;
    }

    100% {
        left: 100%;
    }
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.3;
    }
}

/* Specific Skill Colors for Dashboard Modules */
[data-skill^="réseaux"] {
    --accent-primary: #1BA0D7;
    --accent-primary-rgb: 27, 160, 215;
}

[data-skill^="déploiement"] {
    --accent-primary: #F05032;
    --accent-primary-rgb: 240, 80, 50;
}

[data-skill^="virtualisation"] {
    --accent-primary: #00B4E5;
    --accent-primary-rgb: 0, 180, 229;
}

[data-skill^="hardware"] {
    --accent-primary: #FCC624;
    --accent-primary-rgb: 252, 198, 36;
}

[data-skill^="nas"] {
    --accent-primary: #4FACFE;
    --accent-primary-rgb: 79, 172, 254;
}

[data-skill^="voip"] {
    --accent-primary: #FF7E5F;
    --accent-primary-rgb: 255, 126, 95;
}

[data-skill^="dev"] {
    --accent-primary: #7C3AED;
    --accent-primary-rgb: 124, 58, 237;
}

[data-skill*="linux"] {
    --accent-primary: #FCC624;
    --accent-primary-rgb: 252, 198, 36;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .dashboard-section {
        padding: var(--spacing-xl) 0;
    }

    .skill-module {
        padding: 15px;
    }

    .skill-icon-box {
        width: 45px;
        height: 45px;
        font-size: 1.5rem;
    }

    .module-body {
        gap: 15px;
    }

    .skill-name {
        font-size: 1rem;
    }
}