/**
 * Electron Widget Styles
 */

.electron-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    padding: 20px 0;
    box-sizing: border-box;
}

.electron-container {
    position: relative;
    width: 300px;
    height: 300px;
    max-width: 100%;
    aspect-ratio: 1 / 1;
    box-sizing: border-box;
}

.electron-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: block;
}

/* Animation de pulsation pour le noyau (gérée en CSS aussi comme fallback) */
@keyframes electron-pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
}

/* Responsive - Tablette */
@media screen and (max-width: 1024px) {
    .electron-wrapper {
        padding: 15px 0;
    }
    
    .electron-container {
        width: min(100%, 280px);
        height: auto;
    }
}

/* Responsive - Mobile Landscape */
@media screen and (max-width: 768px) {
    .electron-wrapper {
        padding: 10px 0;
    }
    
    .electron-container {
        width: min(100%, 220px);
        height: auto;
    }
}

/* Responsive - Mobile Portrait */
@media screen and (max-width: 480px) {
    .electron-wrapper {
        padding: 10px 0;
    }
    
    .electron-container {
        width: min(80vw, 180px);
        height: auto;
    }
}

/* Responsive - Très petit écran */
@media screen and (max-width: 360px) {
    .electron-container {
        width: min(75vw, 150px);
        height: auto;
    }
}

/* Fix pour le maintien du ratio dans le canvas */
.electron-container::before {
    content: '';
    display: block;
    padding-top: 100%; /* Ratio 1:1 */
}

.electron-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* Assure que le widget s'adapte bien dans les colonnes Elementor */
.elementor-widget-electron_widget {
    width: 100%;
}

.elementor-widget-electron_widget .elementor-widget-container {
    display: flex;
    justify-content: center;
}
