/* ========================================
   COMPOSANTS MOBILES SUPPLÉMENTAIRES
   ======================================== */

/* ========================================
   6. ROUE DE LA FORTUNE (WHEEL OF FORTUNE)
   ======================================== */
.wheel-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.wheel-container {
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 2rem;
    max-width: 400px;
    width: 100%;
    text-align: center;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.5s ease;
}

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

.wheel-close {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    color: var(--text-light);
    font-size: 1.5rem;
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all var(--transition-base);
}

.wheel-close:hover {
    background: var(--bg-light);
    color: var(--primary-color);
}

.wheel-container h2 {
    color: var(--primary-color);
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
}

.wheel-container > p {
    color: var(--text-light);
    margin-bottom: 2rem;
}

.wheel-wrapper {
    position: relative;
    margin: 2rem auto;
    width: 300px;
    height: 300px;
}

.wheel-pointer {
    position: absolute;
    top: -30px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 2rem;
    color: var(--accent-color);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    z-index: 10;
}

#wheelCanvas {
    border-radius: 50%;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.btn-spin {
    background: linear-gradient(135deg, var(--accent-color), var(--accent-dark));
    color: var(--primary-color);
    border: none;
    padding: 1rem 3rem;
    border-radius: 30px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all var(--transition-base);
    box-shadow: 0 8px 25px rgba(118, 255, 3, 0.4);
}

.btn-spin:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(118, 255, 3, 0.5);
}

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

.wheel-result {
    margin-top: 2rem;
    animation: slideInUp 0.5s ease;
}

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

.wheel-result h3 {
    color: var(--accent-color);
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.prize-display {
    margin: 1.5rem 0;
}

.prize-icon {
    font-size: 4rem;
    margin-bottom: 0.5rem;
}

.prize-name {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary-color);
}

.btn-claim {
    background: var(--primary-color);
    color: white;
    padding: 1rem 2rem;
    border-radius: 30px;
    text-decoration: none;
    display: inline-block;
    margin-top: 1rem;
    transition: all var(--transition-base);
    font-weight: 600;
}

.btn-claim:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(26, 35, 126, 0.3);
}

/* ========================================
   7. STORIES (CAS CLIENTS)
   ======================================== */
.btn-view-stories {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    border: none;
    padding: 1.2rem 2.5rem;
    border-radius: 30px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    margin: 0 auto;
    transition: all var(--transition-base);
    box-shadow: 0 8px 25px rgba(26, 35, 126, 0.3);
}

.btn-view-stories:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 35px rgba(26, 35, 126, 0.4);
}

.stories-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: black;
    z-index: 2001;
    animation: fadeIn 0.3s ease;
}

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

.stories-container {
    width: 100%;
    height: 100%;
    position: relative;
}

.stories-header {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 10;
    padding: 1rem;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.8), transparent);
}

.story-progress-bars {
    display: flex;
    gap: 4px;
    margin-bottom: 1rem;
}

.story-progress-bar {
    flex: 1;
    height: 3px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
    overflow: hidden;
}

.story-progress-fill {
    height: 100%;
    background: var(--accent-color);
    width: 0%;
    transition: width 5s linear;
}

.stories-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    cursor: pointer;
    backdrop-filter: blur(10px);
}

.stories-slides {
    width: 100%;
    height: 100%;
}

.story-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none;
}

.story-slide.active {
    display: block;
}

.story-image {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    position: relative;
}

.story-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
}

.story-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 2rem;
    color: white;
    z-index: 2;
}

.story-content h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.story-content p {
    font-size: 1rem;
    line-height: 1.5;
    margin-bottom: 1rem;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

.story-highlights {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
}

.story-highlight {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.story-highlight i {
    color: var(--accent-color);
}

.story-nav {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 30%;
    cursor: pointer;
}

.story-nav-left {
    left: 0;
}

.story-nav-right {
    right: 0;
}

/* ========================================
   8. VILLES CHIPS
   ======================================== */
.cities-chips-wrapper {
    margin: 2rem 0;
}

.cities-title {
    text-align: center;
    color: var(--primary-color);
    font-size: 1.3rem;
    margin-bottom: 1.5rem;
}

.cities-chips-container {
    overflow-x: auto;
    margin: 0 -15px;
    padding: 0 15px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.cities-chips-container::-webkit-scrollbar {
    display: none;
}

.cities-chips {
    display: flex;
    gap: 0.8rem;
    padding-bottom: 1rem;
    min-width: max-content;
}

.city-chip {
    flex: 0 0 auto;
    padding: 0.8rem 1.5rem;
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 25px;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    transition: all var(--transition-base);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}

.city-chip::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--accent-color), var(--accent-dark));
    transition: left 0.3s ease;
    z-index: 0;
}

.city-chip i,
.city-chip span {
    position: relative;
    z-index: 1;
    transition: color 0.3s ease;
}

.city-chip i {
    color: var(--primary-color);
    font-size: 1rem;
}

.city-chip span {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 0.9rem;
}

.city-chip:hover {
    border-color: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(118, 255, 3, 0.2);
}

.city-chip:hover::before {
    left: 0;
}

.city-chip:hover i,
.city-chip:hover span {
    color: var(--primary-color);
}

.city-chip.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    box-shadow: 0 5px 15px rgba(26, 35, 126, 0.3);
}

.city-chip.active i,
.city-chip.active span {
    color: white;
}

/* ========================================
   9. INSURANCE MODAL
   ======================================== */
.insurance-mobile-grid {
    text-align: center;
}

.insurance-grid-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}

.insurance-grid-item {
    background: white;
    padding: 1rem;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    height: 60px;
    transition: all var(--transition-base);
}

.insurance-grid-item:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

.insurance-grid-item img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.btn-view-all-insurance {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all var(--transition-base);
    box-shadow: 0 5px 20px rgba(26, 35, 126, 0.3);
}

.btn-view-all-insurance:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(26, 35, 126, 0.4);
}

.insurance-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 1999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.insurance-modal-content {
    background: white;
    border-radius: var(--border-radius);
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.5s ease;
}

.insurance-modal-header {
    padding: 1.5rem;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.insurance-modal-header h2 {
    font-size: 1.3rem;
    margin: 0;
}

.insurance-modal-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition-base);
}

.insurance-modal-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.insurance-modal-search {
    padding: 1rem;
    background: var(--bg-light);
    position: relative;
}

.insurance-modal-search i {
    position: absolute;
    left: 2rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-light);
}

.insurance-search-input {
    width: 100%;
    padding: 0.8rem 1rem 0.8rem 3rem;
    border: 2px solid transparent;
    border-radius: 25px;
    font-size: 1rem;
    transition: all var(--transition-base);
}

.insurance-search-input:focus {
    outline: none;
    border-color: var(--accent-color);
}

.insurance-modal-grid {
    flex: 1;
    overflow-y: auto;
    padding: 1rem;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.insurance-modal-item {
    background: var(--bg-light);
    padding: 1rem;
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    transition: all var(--transition-base);
    text-align: center;
}

.insurance-modal-item:hover {
    background: white;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.insurance-modal-item img {
    height: 40px;
    width: auto;
    object-fit: contain;
}

.insurance-modal-item span {
    font-size: 0.85rem;
    color: var(--text-dark);
    font-weight: 500;
}

/* ========================================
   10. EXPANDABLE SERVICE CARDS
   ======================================== */
@media (max-width: 768px) {
    .service-preview-card.expanded .service-preview-header {
        background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    }
    
    .service-preview-card.expanded .service-preview-header h3,
    .service-preview-card.expanded .service-preview-header i {
        color: white;
    }
    
    .service-preview-card.expanded .expand-icon {
        color: var(--accent-color);
    }
}

/* ========================================
   11. TOUCH STATES
   ======================================== */
.touching {
    opacity: 0.8;
    transform: scale(0.98);
}

.long-pressed {
    animation: longPressAnim 0.3s ease;
}

@keyframes longPressAnim {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* ========================================
   12. RESPONSIVE UTILITIES
   ======================================== */
@media (max-width: 768px) {
    /* Hide desktop elements */
    .hero-features:not(.hero-features-carousel),
    .insurance-logos-scroll,
    .process-steps:not(.process-timeline-mobile) {
        display: none !important;
    }
    
    /* Mobile-specific spacing */
    section {
        padding: 3rem 0;
    }
    
    .container {
        padding: 0 15px;
    }
    
    /* Typography adjustments */
    .section-title {
        font-size: 2rem;
    }
    
    .section-subtitle {
        font-size: 1rem;
    }
    
    /* Adjust fixed elements for bottom nav */
    body {
        padding-bottom: 70px;
    }
}

/* ========================================
   13. PERFORMANCE OPTIMIZATIONS
   ======================================== */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* GPU Acceleration for smooth animations */
.hero-features-carousel,
.timeline-track,
.cities-chips,
.fab-main,
.fab-actions {
    will-change: transform;
}

/* Optimize touch scrolling */
.hero-features-carousel,
.timeline-track,
.cities-chips-container {
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
}
