/* Cyber Roulette - Styles CSS */

/* Conteneur principal */
.cyber-roulette-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

/* En-tête */
.cyber-roulette-header {
    text-align: center;
    margin-bottom: 30px;
    color: #fff;
}

.cyber-roulette-title {
    font-size: 2.5em;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.icon-shield {
    font-size: 1.2em;
    animation: pulse 2s infinite;
}

.cyber-roulette-subtitle {
    font-size: 1.2em;
    margin-top: 10px;
    opacity: 0.9;
}

/* Wrapper principal */
.cyber-roulette-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: start;
}

@media (max-width: 768px) {
    .cyber-roulette-wrapper {
        grid-template-columns: 1fr;
    }
}

/* Conteneur Canvas */
.cyber-roulette-canvas-container {
    position: relative;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

#cyber-roulette-svg {
    width: 100%;
    height: auto;
    max-width: 500px;
    display: block;
    margin: 0 auto;
}

/* Animation de rotation */
.spinning {
    animation: spin 4s cubic-bezier(0.17, 0.67, 0.83, 0.67);
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(3600deg); }
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

/* Bouton Spin */
.cyber-spin-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 50%;
    width: 140px;
    height: 140px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
    z-index: 10;
}

.cyber-spin-button:hover {
    transform: translate(-50%, -50%) scale(1.1);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.4);
}

.cyber-spin-button:active {
    transform: translate(-50%, -50%) scale(0.95);
}

.cyber-spin-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.spin-icon {
    font-size: 30px;
}

.spin-text {
    font-size: 14px;
}

/* Panneau d'information */
.cyber-roulette-info-panel {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Tâche actuelle */
.task-current, .task-result {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.task-current h3, .task-result h3 {
    margin: 0 0 20px 0;
    color: #2c3e50;
    font-size: 1.5em;
    display: flex;
    align-items: center;
    gap: 10px;
}

.task-category, .result-category {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 10px;
}

.category-label {
    font-weight: bold;
    color: #7f8c8d;
}

.category-value, .category-name {
    font-size: 1.2em;
    color: #2c3e50;
    font-weight: 600;
}

.category-icon {
    font-size: 2em;
}

.task-description, .result-description {
    padding: 20px;
    background: linear-gradient(135deg, #667eea15 0%, #764ba215 100%);
    border-left: 4px solid #667eea;
    border-radius: 8px;
    margin: 15px 0;
    line-height: 1.6;
    color: #34495e;
}

.task-status {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #ecf0f1;
}

.task-status label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-size: 1.1em;
}

.task-status input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

/* Actions */
.result-actions {
    display: flex;
    gap: 15px;
    margin-top: 25px;
}

.btn-save, .btn-new {
    flex: 1;
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-save {
    background: linear-gradient(135deg, #27ae60 0%, #2ecc71 100%);
    color: white;
}

.btn-save:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(39, 174, 96, 0.3);
}

.btn-new {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: white;
}

.btn-new:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(52, 152, 219, 0.3);
}

/* Statistiques */
.cyber-stats {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.cyber-stats h4 {
    margin: 0 0 20px 0;
    color: #2c3e50;
    font-size: 1.3em;
    display: flex;
    align-items: center;
    gap: 10px;
}

.stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.stat-item {
    text-align: center;
    padding: 15px;
    background: linear-gradient(135deg, #667eea15 0%, #764ba215 100%);
    border-radius: 10px;
}

.stat-value {
    display: block;
    font-size: 2.5em;
    font-weight: bold;
    color: #667eea;
    margin-bottom: 5px;
}

.stat-label {
    display: block;
    font-size: 0.9em;
    color: #7f8c8d;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Historique */
.cyber-history {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.cyber-history h4 {
    margin: 0 0 20px 0;
    color: #2c3e50;
    font-size: 1.3em;
    display: flex;
    align-items: center;
    gap: 10px;
}

.history-list {
    max-height: 300px;
    overflow-y: auto;
}

.history-item {
    padding: 12px;
    border-bottom: 1px solid #ecf0f1;
    transition: background 0.3s ease;
}

.history-item:hover {
    background: #f8f9fa;
}

.history-item:last-child {
    border-bottom: none;
}

.history-date {
    font-size: 0.85em;
    color: #95a5a6;
    margin-bottom: 5px;
}

.history-category {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 3px;
}

.history-task {
    font-size: 0.9em;
    color: #7f8c8d;
}

.history-completed {
    display: inline-block;
    padding: 2px 8px;
    background: #27ae60;
    color: white;
    border-radius: 4px;
    font-size: 0.75em;
    margin-left: 10px;
}

/* Modal */
.cyber-modal {
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
}

.modal-content {
    position: relative;
    background-color: white;
    margin: 10% auto;
    padding: 30px;
    border-radius: 15px;
    width: 80%;
    max-width: 600px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-close {
    position: absolute;
    right: 20px;
    top: 20px;
    font-size: 28px;
    font-weight: bold;
    color: #95a5a6;
    cursor: pointer;
    transition: color 0.3s ease;
}

.modal-close:hover {
    color: #2c3e50;
}

#modal-title {
    margin: 0 0 20px 0;
    color: #2c3e50;
    font-size: 1.8em;
}

#modal-body {
    line-height: 1.6;
    color: #34495e;
}

/* Loader */
.cyber-loader {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* Notifications */
.cyber-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 25px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
    animation: slideIn 0.3s ease;
    z-index: 2000;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.notification-success {
    border-left: 4px solid #27ae60;
}

.notification-error {
    border-left: 4px solid #e74c3c;
}

.notification-info {
    border-left: 4px solid #3498db;
}

/* Responsive Design */
@media (max-width: 992px) {
    .cyber-roulette-wrapper {
        grid-template-columns: 1fr;
    }
    
    .cyber-roulette-title {
        font-size: 2em;
    }
}

@media (max-width: 576px) {
    .cyber-roulette-container {
        padding: 15px;
    }
    
    .cyber-roulette-title {
        font-size: 1.5em;
    }
    
    .cyber-spin-button {
        width: 120px;
        height: 120px;
        font-size: 14px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .result-actions {
        flex-direction: column;
    }
}

/* Animations supplémentaires */
@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

.bounce {
    animation: bounce 2s infinite;
}

@keyframes glow {
    0% {
        box-shadow: 0 0 5px rgba(102, 126, 234, 0.5);
    }
    50% {
        box-shadow: 0 0 20px rgba(102, 126, 234, 0.8), 0 0 30px rgba(102, 126, 234, 0.6);
    }
    100% {
        box-shadow: 0 0 5px rgba(102, 126, 234, 0.5);
    }
}

.glow {
    animation: glow 2s infinite;
}
