/* ================================= */
/* STYLES PLEIN ÉCRAN PHARMACIES - VERSION CORRIGÉE TRADUCTIONS ET MOBILE */
/* ================================= */

/* ================================= */
/* BOUTONS PLEIN ÉCRAN PRINCIPAUX */
/* ================================= */

.fullscreen-map-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
    border: none;
    border-radius: 12px;
    padding: 15px 25px;
    font-size: 16px;
    font-weight: 600;
    box-shadow: 0 6px 20px rgba(0, 123, 255, 0.4);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    backdrop-filter: blur(10px);
    animation: pulseAttention 2s ease-in-out infinite;
}

.fullscreen-map-btn:hover {
    background: linear-gradient(135deg, #0056b3, #004085);
    transform: translate(-50%, -50%) translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 123, 255, 0.5);
    animation: none;
}

.fullscreen-map-btn:active {
    transform: translate(-50%, -50%) translateY(-1px);
}

.fullscreen-map-btn i {
    font-size: 18px;
}

/* Bouton liste - UNIFIÉ POUR TOUS LES ÉCRANS */
.fullscreen-list-btn,
.fullscreen-list-btn-desktop {
    position: absolute;
    top: 15px;
    right: 15px;
    background: linear-gradient(135deg, #17a2b8, #138496);
    color: white;
    border: none;
    border-radius: 10px;
    padding: 12px 18px;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(23, 162, 184, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 100;
    display: flex;
    align-items: center;
    gap: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.fullscreen-list-btn:hover,
.fullscreen-list-btn-desktop:hover {
    background: linear-gradient(135deg, #138496, #117a8b);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(23, 162, 184, 0.4);
}

/* ================================= */
/* RESPONSIVE DESIGN CORRIGÉ - PAS DE MODIFICATION DU TEXTE SUR MOBILE */
/* ================================= */

@media (max-width: 768px) {
    .fullscreen-search-controls {
        top: 10px;
        left: 10px;
        right: 10px;
        padding: 12px;
    }
    
    .search-container-enhanced {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }
    
    .search-input-wrapper {
        min-width: auto;
    }
    
    .radius-controls {
        justify-content: center;
        padding: 10px 15px;
    }
    
    .radius-display {
        min-width: 50px;
        font-size: 13px;
    }
    
    .radius-btn {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }
    
    .my-position-btn {
        justify-content: center;
        padding: 10px 14px;
    }
    
    .fullscreen-map-btn {
        padding: 12px 20px;
        font-size: 14px;
        gap: 8px;
        /* GARDER LE TEXTE COMPLET SUR MOBILE */
        max-width: none;
    }
    
    /* CORRECTION IMPORTANTE: Les boutons liste gardent leur texte complet */
    .fullscreen-list-btn,
    .fullscreen-list-btn-desktop {
        padding: 12px 20px;
        font-size: 14px;
        gap: 8px;
        /* Assurer que le texte reste visible */
        white-space: nowrap;
    }
    
    .fullscreen-header {
        padding: 1rem;
        min-height: 60px;
    }
    
    .fullscreen-title {
        font-size: 1.2rem;
    }
    
    .fullscreen-close,
    .fullscreen-back {
        padding: 10px 14px;
        min-width: 80px;
        font-size: 14px;
    }
    
    .control-panel {
        padding: 12px;
        gap: 8px;
        margin: 0 15px;
    }
    
    .control-btn {
        padding: 10px 12px;
        font-size: 12px;
        min-width: 100px;
    }
    
    .search-filters {
        gap: 8px;
    }
    
    .filter-chip {
        padding: 10px 16px;
        font-size: 12px;
    }
    
    .fullscreen-list-container {
        padding: 15px;
    }
    
    .fullscreen-pharmacy-item {
        padding: 15px;
        margin-bottom: 15px;
    }
    
    .pharmacy-name {
        font-size: 1.2rem;
    }
    
    .pharmacy-header {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
    
    .pharmacy-actions {
        flex-direction: column;
    }
    
    .action-btn {
        min-width: auto;
        flex: none;
    }
    
    .fullscreen-notification {
        top: 70px;
        right: 10px;
        left: 10px;
        max-width: none;
    }
}

@media (max-width: 576px) {
    .fullscreen-search-controls {
        top: 5px;
        left: 5px;
        right: 5px;
        padding: 10px;
    }
    
    .search-container-enhanced {
        gap: 10px;
    }
    
    .fullscreen-search-controls .search-input {
        padding: 10px 40px 10px 15px;
        font-size: 14px;
    }
    
    .radius-controls {
        padding: 8px 12px;
    }
    
    .radius-display {
        font-size: 12px;
        min-width: 45px;
    }
    
    .radius-btn {
        width: 34px;
        height: 34px;
        font-size: 13px;
    }
    
    .my-position-btn {
        padding: 8px 12px;
        font-size: 13px;
    }
    
    .fullscreen-map-btn {
        padding: 10px 16px;
        font-size: 13px;
        left: 50%;
        top: 40%;
        /* CORRECTION: Garder le texte complet même sur très petit écran */
        max-width: 280px;
        white-space: nowrap;
    }
    
    .fullscreen-list-btn,
    .fullscreen-list-btn-desktop {
        padding: 10px 16px;
        font-size: 13px;
        /* CORRECTION: Garder le texte complet */
        white-space: nowrap;
    }
    
    /* SUPPRESSION DES RÈGLES QUI CACHENT LE TEXTE */
    /* .btn-text,
    .btn-text-desktop {
        display: none;
    } */
    
    /* Les icônes gardent leur taille normale */
    .fullscreen-map-btn i,
    .fullscreen-list-btn i,
    .fullscreen-list-btn-desktop i {
        font-size: 16px;
        margin-right: 8px;
    }
    
    .control-panel {
        flex-direction: column;
        align-items: stretch;
    }
    
    .control-btn {
        justify-content: flex-start;
        text-align: left;
    }
    
    .search-filters {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
    
    .filter-chip {
        justify-content: center;
        text-align: center;
    }
    
    .detail-row {
        font-size: 14px;
    }
    
    .detail-row i {
        width: 20px;
        margin-right: 12px;
    }
}

/* ================================= */
/* OVERLAYS PLEIN ÉCRAN */
/* ================================= */

.fullscreen-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #ffffff;
    z-index: 9999;
    display: none;
    flex-direction: column;
    animation: fadeInScale 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.fullscreen-overlay.active {
    display: flex;
}

/* ================================= */
/* HEADER DES OVERLAYS */
/* ================================= */

.fullscreen-header {
    background: linear-gradient(135deg, #6c757d, #495057);
    color: white;
    padding: 1.2rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    flex-shrink: 0;
    position: relative;
    min-height: 70px;
}

.fullscreen-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin: 0;
    flex: 1;
    text-align: center;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.fullscreen-close,
.fullscreen-back {
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: white;
    padding: 12px 18px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 100px;
    justify-content: center;
}

.fullscreen-close:hover,
.fullscreen-back:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    transform: scale(1.05);
}

.fullscreen-content {
    flex: 1;
    overflow: hidden;
    position: relative;
    background: #f8f9fa;
}

/* ================================= */
/* BARRE DE RECHERCHE ET CONTRÔLES PLEIN ÉCRAN */
/* ================================= */

.fullscreen-search-controls {
    position: absolute;
    top: 20px;
    left: 20px;
    right: 20px;
    z-index: 200;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 15px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.search-container-enhanced {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.search-input-wrapper {
    position: relative;
    flex: 1;
    min-width: 250px;
}

.fullscreen-search-controls .search-input {
    width: 100%;
    padding: 12px 45px 12px 20px;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 500;
    transition: all 0.3s ease;
    background: #f8f9fa;
}

.fullscreen-search-controls .search-input:focus {
    outline: none;
    border-color: #007bff;
    background: white;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.fullscreen-search-controls .search-icon {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #6c757d;
    font-size: 16px;
    pointer-events: none;
}

/* ================================= */
/* CONTRÔLES DE RAYON PLEIN ÉCRAN */
/* ================================= */

.radius-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 8px 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.radius-controls:hover {
    border-color: #007bff;
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.15);
}

.radius-display {
    display: flex;
    align-items: center;
    font-weight: 600;
    font-size: 14px;
    color: #495057;
    min-width: 60px;
    justify-content: center;
}

.radius-display i {
    color: #17a2b8;
    margin-right: 4px;
}

.radius-buttons {
    display: flex;
    gap: 4px;
}

.radius-btn {
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 8px;
    background: #f8f9fa;
    color: #6c757d;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
}

.radius-btn:hover {
    background: #e9ecef;
    color: #495057;
    transform: scale(1.05);
}

.radius-btn.decrease:hover {
    background: #dc3545;
    color: white;
}

.radius-btn.increase:hover {
    background: #28a745;
    color: white;
}

.radius-btn:active {
    transform: scale(0.95);
}

.radius-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* ================================= */
/* BOUTON MA POSITION PLEIN ÉCRAN */
/* ================================= */

.my-position-btn {
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
    border: none;
    border-radius: 12px;
    padding: 12px 16px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3);
}

.my-position-btn:hover {
    background: linear-gradient(135deg, #20c997, #17a2b8);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(40, 167, 69, 0.4);
}

.my-position-btn:active {
    transform: translateY(0);
}

.my-position-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

/* ================================= */
/* CARTE PLEIN ÉCRAN */
/* ================================= */

.fullscreen-map-container {
    width: 100%;
    height: 100%;
    position: relative;
    background: linear-gradient(135deg, #e3f2fd, #f8f9fa);
}

.fullscreen-controls {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;
}

.control-panel {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 15px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(15px);
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.control-btn {
    background: rgba(108, 117, 125, 0.1);
    border: 2px solid transparent;
    color: #495057;
    padding: 12px 16px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 120px;
    justify-content: center;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.control-btn:hover {
    background: rgba(0, 123, 255, 0.1);
    border-color: #007bff;
    color: #007bff;
    transform: translateY(-2px);
}

.control-btn.active {
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
    border-color: #0056b3;
    box-shadow: 0 4px 15px rgba(0, 123, 255, 0.3);
}

.control-btn.location-btn {
    background: linear-gradient(135deg, #17a2b8, #138496);
    color: white;
    border-color: #138496;
}

.control-btn.location-btn:hover {
    background: linear-gradient(135deg, #138496, #117a8b);
    transform: translateY(-2px);
}

/* ================================= */
/* LISTE PLEIN ÉCRAN */
/* ================================= */

.fullscreen-search-bar {
    background: white;
    padding: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 10;
    border-bottom: 1px solid #e9ecef;
}

.search-container {
    position: relative;
    margin-bottom: 20px;
}

.search-input {
    width: 100%;
    padding: 15px 50px 15px 20px;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.3s ease;
    background: #f8f9fa;
}

.search-input:focus {
    outline: none;
    border-color: #007bff;
    background: white;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.search-icon {
    position: absolute;
    right: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: #6c757d;
    font-size: 18px;
    pointer-events: none;
}

.search-filters {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
}

.filter-chip {
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    color: #495057;
    padding: 12px 20px;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.filter-chip:hover {
    background: #e9ecef;
    border-color: #007bff;
    color: #007bff;
    transform: translateY(-2px);
}

.filter-chip.active {
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
    border-color: #0056b3;
    box-shadow: 0 4px 15px rgba(0, 123, 255, 0.3);
}

.fullscreen-list-container {
    height: calc(100% - 140px);
    overflow-y: auto;
    padding: 20px;
    scroll-behavior: smooth;
}

/* ================================= */
/* ITEMS DE PHARMACIES */
/* ================================= */

.fullscreen-pharmacy-item {
    background: white;
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border-left: 5px solid #17a2b8;
    position: relative;
    overflow: hidden;
    animation: slideInUp 0.5s ease-out;
}

.fullscreen-pharmacy-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 5px;
    height: 100%;
    background: linear-gradient(to bottom, #17a2b8, rgba(23, 162, 184, 0.7));
    transition: all 0.3s ease;
}

.fullscreen-pharmacy-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
}

.fullscreen-pharmacy-item:hover::before {
    width: 8px;
}

/* Variantes par statut */
.fullscreen-pharmacy-item.current {
    border-left-color: #28a745;
}

.fullscreen-pharmacy-item.current::before {
    background: linear-gradient(to bottom, #28a745, rgba(40, 167, 69, 0.7));
}

.fullscreen-pharmacy-item.closed {
    border-left-color: #dc3545;
}

.fullscreen-pharmacy-item.closed::before {
    background: linear-gradient(to bottom, #dc3545, rgba(220, 53, 69, 0.7));
}

.fullscreen-pharmacy-item.upcoming {
    border-left-color: #ffc107;
}

.fullscreen-pharmacy-item.upcoming::before {
    background: linear-gradient(to bottom, #ffc107, rgba(255, 193, 7, 0.7));
}

.pharmacy-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
    gap: 15px;
}

.pharmacy-name {
    font-size: 1.4rem;
    font-weight: 700;
    color: #212529;
    line-height: 1.3;
    flex: 1;
}

.pharmacy-status {
    padding: 8px 16px;
    border-radius: 25px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    white-space: nowrap;
    flex-shrink: 0;
}

.pharmacy-status.current {
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
    animation: pulseGlow 2s ease-in-out infinite;
}

.pharmacy-status.closed {
    background: linear-gradient(135deg, #dc3545, #e83e8c);
    color: white;
}

.pharmacy-status.upcoming {
    background: linear-gradient(135deg, #ffc107, #fd7e14);
    color: #212529;
}

.pharmacy-status.normal {
    background: linear-gradient(135deg, #17a2b8, #6f42c1);
    color: white;
}

.pharmacy-details {
    margin-bottom: 20px;
}

.detail-row {
    display: flex;
    align-items: flex-start;
    margin-bottom: 12px;
    font-size: 15px;
    color: #495057;
    line-height: 1.5;
}

.detail-row i {
    width: 24px;
    margin-right: 15px;
    color: #007bff;
    margin-top: 2px;
    flex-shrink: 0;
}

.detail-row.guard-info {
    background: rgba(255, 243, 205, 0.8);
    border: 1px solid #ffeaa7;
    border-radius: 8px;
    padding: 10px;
    margin-top: 10px;
}

.detail-row.guard-info i {
    color: #856404;
}

.phone-link {
    color: #28a745;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.phone-link:hover {
    color: #20c997;
    text-decoration: underline;
}

.pharmacy-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.action-btn {
    flex: 1;
    min-width: 120px;
    padding: 12px 20px;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-decoration: none;
}

.action-btn.primary {
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
}

.action-btn.primary:hover {
    background: linear-gradient(135deg, #0056b3, #004085);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 123, 255, 0.3);
    color: white;
    text-decoration: none;
}

.action-btn.success {
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
}

.action-btn.success:hover {
    background: linear-gradient(135deg, #20c997, #17a2b8);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3);
    color: white;
    text-decoration: none;
}

.action-btn.info {
    background: linear-gradient(135deg, #17a2b8, #6f42c1);
    color: white;
}

.action-btn.info:hover {
    background: linear-gradient(135deg, #6f42c1, #e83e8c);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(23, 162, 184, 0.3);
    color: white;
    text-decoration: none;
}

/* ================================= */
/* NOTIFICATIONS PLEIN ÉCRAN */
/* ================================= */

.fullscreen-notification {
    position: fixed;
    top: 90px;
    right: 20px;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    z-index: 10000;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.3s ease;
    max-width: 300px;
    backdrop-filter: blur(10px);
}

.fullscreen-notification.success {
    background: #28a745;
    color: white;
}

.fullscreen-notification.error {
    background: #dc3545;
    color: white;
}

.fullscreen-notification.warning {
    background: #ffc107;
    color: #212529;
}

.fullscreen-notification.info {
    background: #17a2b8;
    color: white;
}

/* ================================= */
/* BADGE SOURCE API */
/* ================================= */

/* ================================= */
/* SUITE DU CSS PLEIN ÉCRAN CORRIGÉ */
/* ================================= */

.api-source-badge {
    background: rgba(23, 162, 184, 0.1);
    border: 1px solid #17a2b8;
    border-radius: 4px;
    padding: 6px;
    margin-bottom: 8px;
    font-size: 11px;
    color: #17a2b8;
}

/* ================================= */
/* ÉTATS SPÉCIAUX */
/* ================================= */

.no-pharmacies,
.no-results {
    text-align: center;
    padding: 60px 20px;
    color: #6c757d;
}

.no-pharmacies i,
.no-results i {
    font-size: 4rem;
    margin-bottom: 20px;
    opacity: 0.5;
    color: #dee2e6;
}

.no-pharmacies h3,
.no-results h3 {
    color: #495057;
    margin-bottom: 10px;
    font-size: 1.5rem;
}

.no-pharmacies p,
.no-results p {
    font-size: 1.1rem;
    line-height: 1.6;
}

/* ================================= */
/* ANIMATIONS */
/* ================================= */

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulseAttention {
    0%, 100% {
        box-shadow: 0 6px 20px rgba(0, 123, 255, 0.4);
        transform: translate(-50%, -50%) scale(1);
    }
    50% {
        box-shadow: 0 8px 30px rgba(0, 123, 255, 0.6);
        transform: translate(-50%, -50%) scale(1.05);
    }
}

@keyframes pulseGlow {
    0%, 100% {
        box-shadow: 0 0 5px rgba(40, 167, 69, 0.5);
    }
    50% {
        box-shadow: 0 0 20px rgba(40, 167, 69, 0.8);
    }
}

/* ================================= */
/* RESPONSIVE DESIGN AMÉLIORÉ - FOCUS SUR LE TEXTE MOBILE */
/* ================================= */

/* Tablettes */
@media (max-width: 1024px) and (min-width: 769px) {
    .fullscreen-map-btn,
    .fullscreen-list-btn,
    .fullscreen-list-btn-desktop {
        font-size: 15px;
        padding: 14px 22px;
    }
    
    .fullscreen-search-controls {
        top: 15px;
        left: 15px;
        right: 15px;
    }
}

/* Smartphones paysage */
@media (max-width: 768px) and (orientation: landscape) {
    .fullscreen-map-btn {
        top: 30%;
        left: 50%;
        font-size: 13px;
        padding: 10px 18px;
    }
    
    .fullscreen-list-btn,
    .fullscreen-list-btn-desktop {
        top: 10px;
        right: 10px;
        font-size: 13px;
        padding: 10px 16px;
    }
    
    .fullscreen-search-controls {
        top: 5px;
        left: 5px;
        right: 5px;
        padding: 8px;
    }
}

/* Petits smartphones portrait - TEXTE PRÉSERVÉ */
@media (max-width: 480px) {
    .fullscreen-map-btn {
        position: absolute;
        top: 35%;
        left: 50%;
        transform: translate(-50%, -50%);
        font-size: 12px;
        padding: 10px 16px;
        gap: 6px;
        /* IMPORTANT: Préserver le texte même sur très petit écran */
        white-space: nowrap;
        max-width: 250px;
        overflow: visible;
    }
    
    .fullscreen-list-btn,
    .fullscreen-list-btn-desktop {
        top: 10px;
        right: 10px;
        font-size: 12px;
        padding: 10px 14px;
        gap: 6px;
        /* IMPORTANT: Préserver le texte */
        white-space: nowrap;
        overflow: visible;
    }
    
    /* S'assurer que les icônes et textes restent visibles */
    .fullscreen-map-btn i,
    .fullscreen-list-btn i,
    .fullscreen-list-btn-desktop i {
        font-size: 14px;
        flex-shrink: 0;
    }
    
    .fullscreen-map-btn span,
    .fullscreen-list-btn span,
    .fullscreen-list-btn-desktop span {
        display: inline !important;
        white-space: nowrap;
    }
}

/* Très petits écrans - PROTECTION DU TEXTE */
@media (max-width: 360px) {
    .fullscreen-map-btn {
        font-size: 11px;
        padding: 8px 14px;
        gap: 5px;
        max-width: 220px;
        /* Forcer l'affichage du texte */
        line-height: 1.2;
    }
    
    .fullscreen-list-btn,
    .fullscreen-list-btn-desktop {
        font-size: 11px;
        padding: 8px 12px;
        gap: 5px;
        /* Texte sur une ligne si nécessaire */
        line-height: 1.2;
    }
    
    /* Réduire légèrement les icônes si nécessaire */
    .fullscreen-map-btn i,
    .fullscreen-list-btn i,
    .fullscreen-list-btn-desktop i {
        font-size: 12px;
    }
}

/* ================================= */
/* ACCESSIBILITÉ ET UX AMÉLIORÉS */
/* ================================= */

/* Focus amélioré pour tous les boutons */
.fullscreen-map-btn:focus,
.fullscreen-list-btn:focus,
.fullscreen-list-btn-desktop:focus,
.control-btn:focus,
.filter-chip:focus,
.action-btn:focus,
.radius-btn:focus,
.my-position-btn:focus {
    outline: 3px solid rgba(0, 123, 255, 0.5);
    outline-offset: 2px;
    z-index: 1001;
}

/* Focus spécial pour les boutons principaux */
.fullscreen-map-btn:focus,
.fullscreen-list-btn:focus,
.fullscreen-list-btn-desktop:focus {
    outline: 3px solid rgba(255, 255, 255, 0.8);
    outline-offset: 3px;
    box-shadow: 0 0 0 6px rgba(0, 123, 255, 0.3);
}

/* Smooth scrolling pour tous les conteneurs */
.fullscreen-list-container {
    scroll-behavior: smooth;
}

/* Scrollbar personnalisée */
.fullscreen-list-container::-webkit-scrollbar {
    width: 8px;
}

.fullscreen-list-container::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.fullscreen-list-container::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #c1c1c1, #a8a8a8);
    border-radius: 10px;
}

.fullscreen-list-container::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #a8a8a8, #909090);
}

/* ================================= */
/* SUPPORT POUR LE MODE SOMBRE */
/* ================================= */

@media (prefers-color-scheme: dark) {
    .fullscreen-overlay {
        background: #1a1a1a;
        color: #e0e0e0;
    }
    
    .fullscreen-content {
        background: #2d2d2d;
    }
    
    .fullscreen-pharmacy-item {
        background: #3a3a3a;
        color: #e0e0e0;
        border-left-color: #4a9eff;
    }
    
    .fullscreen-search-bar,
    .fullscreen-search-controls {
        background: rgba(58, 58, 58, 0.95);
        border-color: #555;
    }
    
    .search-input {
        background: #4a4a4a;
        border-color: #666;
        color: #e0e0e0;
    }
    
    .search-input:focus {
        background: #5a5a5a;
        border-color: #4a9eff;
    }
    
    .filter-chip {
        background: #4a4a4a;
        border-color: #666;
        color: #e0e0e0;
    }
    
    .filter-chip:hover {
        background: #5a5a5a;
        border-color: #4a9eff;
        color: #4a9eff;
    }
    
    .filter-chip.active {
        background: linear-gradient(135deg, #4a9eff, #0056b3);
        color: white;
        border-color: #0056b3;
    }
    
    .control-panel {
        background: rgba(58, 58, 58, 0.95);
        border-color: #555;
    }
    
    .control-btn {
        background: rgba(255, 255, 255, 0.1);
        color: #e0e0e0;
    }
    
    .control-btn:hover {
        background: rgba(74, 158, 255, 0.2);
        border-color: #4a9eff;
        color: #4a9eff;
    }
    
    .control-btn.active {
        background: linear-gradient(135deg, #4a9eff, #0056b3);
        color: white;
        border-color: #0056b3;
    }
    
    .radius-controls {
        background: #4a4a4a;
        border-color: #666;
    }
    
    .radius-btn {
        background: #5a5a5a;
        color: #e0e0e0;
    }
    
    .radius-btn:hover {
        background: #6a6a6a;
    }
}

/* ================================= */
/* AMÉLIORATIONS POUR L'IMPRESSION */
/* ================================= */

@media print {
    .fullscreen-overlay,
    .fullscreen-map-btn,
    .fullscreen-list-btn,
    .fullscreen-list-btn-desktop,
    .fullscreen-search-controls,
    .fullscreen-controls,
    .fullscreen-notification {
        display: none !important;
    }
    
    .fullscreen-pharmacy-item {
        border: 1px solid #000;
        break-inside: avoid;
        margin-bottom: 10mm;
    }
    
    .pharmacy-name {
        font-size: 14pt;
        font-weight: bold;
    }
    
    .detail-row {
        font-size: 10pt;
        margin-bottom: 2mm;
    }
}

/* ================================= */
/* ANIMATIONS SUPPLÉMENTAIRES ET ÉTATS */
/* ================================= */

/* Animation pour les boutons lors du chargement */
.fullscreen-map-btn.loading,
.fullscreen-list-btn.loading,
.fullscreen-list-btn-desktop.loading {
    pointer-events: none;
    opacity: 0.7;
}

.fullscreen-map-btn.loading i,
.fullscreen-list-btn.loading i,
.fullscreen-list-btn-desktop.loading i {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Animation pour les changements de rayon */
.radius-controls.updating {
    border-color: #28a745;
    box-shadow: 0 0 0 0.2rem rgba(40, 167, 69, 0.25);
    animation: radiusUpdate 0.5s ease-out;
}

@keyframes radiusUpdate {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Animation de recherche active */
.search-input-wrapper.searching .search-icon {
    animation: spin 1s linear infinite;
    color: #007bff;
}

/* États de transition pour les overlays */
.fullscreen-overlay {
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.fullscreen-overlay:not(.active) {
    opacity: 0;
    transform: scale(0.98);
    pointer-events: none;
}

.fullscreen-overlay.active {
    opacity: 1;
    transform: scale(1);
    pointer-events: all;
}

/* ================================= */
/* GESTION DES PRÉFÉRENCES UTILISATEUR */
/* ================================= */

/* Réduction d'animations pour les utilisateurs qui préfèrent moins d'animations */
@media (prefers-reduced-motion: reduce) {
    .fullscreen-overlay,
    .fullscreen-pharmacy-item,
    .pharmacy-status.current,
    .fullscreen-map-btn,
    .fullscreen-list-btn,
    .fullscreen-list-btn-desktop {
        animation: none !important;
    }
    
    * {
        transition: none !important;
    }
    
    .fullscreen-map-btn,
    .fullscreen-list-btn,
    .fullscreen-list-btn-desktop {
        transform: translate(-50%, -50%);
    }
    
    .fullscreen-list-btn,
    .fullscreen-list-btn-desktop {
        transform: none;
    }
}

/* Respect du contraste élevé */
@media (prefers-contrast: high) {
    .fullscreen-map-btn,
    .fullscreen-list-btn,
    .fullscreen-list-btn-desktop {
        border: 3px solid #000;
        background: #fff;
        color: #000;
    }
    
    .fullscreen-map-btn:hover,
    .fullscreen-list-btn:hover,
    .fullscreen-list-btn-desktop:hover {
        background: #000;
        color: #fff;
    }
    
    .fullscreen-pharmacy-item {
        border: 2px solid #000;
    }
    
    .filter-chip {
        border: 2px solid #000;
    }
    
    .filter-chip.active {
        background: #000;
        color: #fff;
    }
}

/* ================================= */
/* SUPPORT RTL POUR LES LANGUES ARABES */
/* ================================= */

[dir="rtl"] .fullscreen-list-btn,
[dir="rtl"] .fullscreen-list-btn-desktop {
    right: auto;
    left: 15px;
}

[dir="rtl"] .fullscreen-search-controls {
    text-align: right;
}

[dir="rtl"] .search-icon {
    right: auto;
    left: 15px;
}

[dir="rtl"] .radius-display i {
    margin-right: 0;
    margin-left: 4px;
}

[dir="rtl"] .detail-row i {
    margin-right: 0;
    margin-left: 15px;
}

/* ================================= */
/* OPTIMISATIONS FINALES */
/* ================================= */

/* GPU acceleration pour les animations fluides */
.fullscreen-overlay,
.fullscreen-map-btn,
.fullscreen-list-btn,
.fullscreen-list-btn-desktop,
.fullscreen-pharmacy-item {
    will-change: transform;
    transform-style: preserve-3d;
}

/* Optimisation de la performance */
.fullscreen-list-container {
    contain: layout style paint;
}

.fullscreen-pharmacy-item {
    contain: layout paint;
}

/* Préchargement des gradients pour éviter les saccades */
.fullscreen-map-btn::before,
.fullscreen-list-btn::before,
.fullscreen-list-btn-desktop::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: inherit;
    opacity: 0;
    z-index: -1;
    transition: opacity 0.3s ease;
}

/* ================================= */
/* CLASSES UTILITAIRES POUR LES TRADUCTIONS */
/* ================================= */

/* Classes pour les éléments qui changent selon la langue */
.text-dynamic {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 200px;
}

.text-dynamic-mobile {
    font-size: 13px;
    line-height: 1.2;
}

/* Adaptation automatique selon la longueur du texte */
.fullscreen-map-btn[data-text-length="long"],
.fullscreen-list-btn[data-text-length="long"],
.fullscreen-list-btn-desktop[data-text-length="long"] {
    font-size: 12px;
    padding: 10px 16px;
}

.fullscreen-map-btn[data-text-length="short"],
.fullscreen-list-btn[data-text-length="short"],
.fullscreen-list-btn-desktop[data-text-length="short"] {
    font-size: 14px;
    padding: 12px 20px;
}

/* Support pour les caractères spéciaux et accents */
.fullscreen-map-btn,
.fullscreen-list-btn,
.fullscreen-list-btn-desktop {
    font-feature-settings: "liga" 1, "kern" 1;
    text-rendering: optimizeLegibility;
}

/* ================================= */
/* CLASSES DE FALLBACK POUR LA COMPATIBILITÉ */
/* ================================= */

/* Fallback pour les navigateurs qui ne supportent pas les custom properties */
.no-css-variables .fullscreen-map-btn {
    background: #007bff;
}

.no-css-variables .fullscreen-list-btn,
.no-css-variables .fullscreen-list-btn-desktop {
    background: #17a2b8;
}

/* Fallback pour les navigateurs sans support flexbox */
.no-flexbox .fullscreen-map-btn,
.no-flexbox .fullscreen-list-btn,
.no-flexbox .fullscreen-list-btn-desktop {
    display: inline-block;
    text-align: center;
}

/* ================================= */
/* STYLES POUR LES ÉTATS D'ERREUR */
/* ================================= */

.fullscreen-error {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    margin: 20px;
}

.fullscreen-error i {
    font-size: 3rem;
    color: #dc3545;
    margin-bottom: 15px;
}

.fullscreen-error h3 {
    color: #721c24;
    margin-bottom: 10px;
}

.fullscreen-error p {
    margin-bottom: 15px;
}

.fullscreen-error button {
    background: #dc3545;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
}

.fullscreen-error button:hover {
    background: #c82333;
}

/* ================================= */
/* FIN DU FICHIER CSS */
/* ================================= */