/* Reset et styles de base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #EEFBFF;
    color: #333;
    overflow-x: hidden;
}

#app {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Gestion des pages */
.page {
    display: none;
    min-height: 100vh;
    flex-direction: column;
}

.page.active {
    display: flex;
}

/* Boutons génériques */
button {
    cursor: pointer;
    border: none;
    outline: none;
    transition: all 0.3s ease;
}

button:hover {
    transform: scale(1.05);
}

button:active {
    transform: scale(0.95);
}

/* Conteneur de publicités */
.ad-container {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: #f0f0f0;
    padding: 10px;
    text-align: center;
    display: none;
}

.ad-container.active {
    display: block;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    justify-content: center;
    align-items: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 15px;
    padding: 20px;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.modal-header h3 {
    color: #686EC2;
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 10px;
}

.modal-body {
    padding: 15px 0;
    border-top: 1px solid #ccc;
    border-bottom: 1px solid #ccc;
    margin: 10px 0;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 15px;
}

.btn-ad, .btn-cancel {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 15px;
    border-radius: 8px;
    font-weight: bold;
}

.btn-ad {
    background: #4CAF50;
    color: white;
}

.btn-ad img {
    width: 35px;
    height: 35px;
}

.btn-cancel {
    background: #f44336;
    color: white;
}

.btn-cancel img {
    width: 35px;
    height: 35px;
}

/* États de chargement */
.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 15px;
    padding: 60px 20px;
    color: #666;
    font-size: 15px;
}

.loading-spinner,
.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(91, 88, 235, 0.15);
    border-top-color: #5B58EB;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

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

.fade-in {
    animation: fadeIn 0.3s ease;
}

.slide-in {
    animation: slideIn 0.3s ease;
}

/* Responsive */
@media (max-width: 768px) {
    .modal-content {
        max-width: 95%;
    }
}