/* Sanoris Zones Map - Front-end Styles */

:root {
    --szm-primary: #2271b1;
    --szm-primary-hover: #135e96;
    --szm-border: #ddd;
    --szm-bg-light: #f9f9f9;
    --szm-text: #333;
    --szm-text-light: #666;
    --szm-success: #46b450;
    --szm-warning: #ffa726;
    --szm-radius: 8px;
    --szm-transition: cubic-bezier(0.4, 0, 0.2, 1);
    --szm-shadow-sm: 0 1px 3px rgba(0,0,0,0.12);
    --szm-shadow-md: 0 4px 6px rgba(0,0,0,0.1);
    --szm-shadow-lg: 0 10px 25px rgba(0,0,0,0.15);
}

/* Container */
.szm-map-wrapper {
    max-width: 1400px;
    margin: 2rem auto;
    padding: 0 20px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, sans-serif;
}

/* Filter Section */
.szm-filter-section {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 30px;
    padding: 20px;
    background: var(--szm-bg-light);
    border-radius: var(--szm-radius);
    border: 1px solid var(--szm-border);
}

.szm-filter-label {
    font-weight: 600;
    font-size: 16px;
    color: var(--szm-text);
    white-space: nowrap;
}

.szm-select {
    flex: 1;
    max-width: 400px;
    padding: 10px 15px;
    font-size: 15px;
    border: 1px solid var(--szm-border);
    border-radius: 5px;
    background: white;
    cursor: pointer;
    transition: border-color 0.2s;
}

.szm-select:hover {
    border-color: var(--szm-primary);
}

.szm-select:focus {
    outline: none;
    border-color: var(--szm-primary);
    box-shadow: 0 0 0 3px rgba(34, 113, 177, 0.1);
}

/* Neutralize WordPress default focus styles */
.szm-select:focus-visible,
.szm-list-item:focus,
.szm-list-item:focus-visible,
.szm-list-item:active {
    outline: none;
    box-shadow: none;
}

/* Main Grid */
.szm-main-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 30px;
    margin-bottom: 50px;
    min-height: 600px;
}

@media (max-width: 1024px) {
    .szm-main-grid {
        grid-template-columns: 1fr;
        min-height: auto;
    }
}

/* Map Section */
.szm-map-section {
    background: white;
    border: 1px solid var(--szm-border);
    border-radius: var(--szm-radius);
    padding: 20px;
    min-height: 600px;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

/* SEO links block under department map */
.szm-departement-links {
    display: block;
    margin: 24px 0 0;
    padding: 16px 20px;
    background: #fff;
    border: 1px solid var(--szm-border);
    border-radius: var(--szm-radius);
}

.szm-departement-links table {
    width: 100%;
    border-collapse: collapse;
}

.szm-departement-links td,
.szm-departement-links th {
    padding: 10px 8px;
    border-bottom: 1px solid #eee;
    text-align: left;
}

.szm-svg-container {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: transform 300ms var(--szm-transition);
}

.szm-svg-container.zoomed {
    transform: scale(1.5);
}

.szm-svg-container svg {
    max-width: 100%;
    height: auto;
    cursor: pointer;
}

/* Tooltip */
.szm-tooltip {
    position: absolute;
    background: rgba(0, 0, 0, 0.9);
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    pointer-events: none;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 200ms, transform 200ms;
    z-index: 1000;
    box-shadow: var(--szm-shadow-lg);
    white-space: nowrap;
}

.szm-tooltip.visible {
    opacity: 1;
    transform: translateY(0);
}

.szm-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: rgba(0, 0, 0, 0.9);
}

/* Sidebar */
.szm-sidebar {
    background: white;
    border: 1px solid var(--szm-border);
    border-radius: var(--szm-radius);
    padding: 25px;
    max-height: 600px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Stepper Navigation */
.szm-stepper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    padding: 12px 15px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: var(--szm-radius);
    gap: 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.szm-stepper-item {
    display: flex;
    align-items: center;
    gap: 6px;
    flex: 0 0 auto;
    position: relative;
}

.szm-stepper-circle {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #ddd;
    color: #999;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 13px;
    transition: all 300ms var(--szm-transition);
    flex-shrink: 0;
}

.szm-stepper-item.active .szm-stepper-circle {
    background: var(--szm-primary);
    color: white;
    box-shadow: 0 0 0 3px rgba(34, 113, 177, 0.2);
    transform: scale(1.05);
}

.szm-stepper-item.completed .szm-stepper-circle {
    background: var(--szm-success);
    color: white;
}

.szm-stepper-label {
    font-size: 11px;
    color: var(--szm-text-light);
    font-weight: 500;
    white-space: nowrap;
}

.szm-stepper-item.active .szm-stepper-label {
    color: var(--szm-primary);
    font-weight: 700;
}

.szm-stepper-connector {
    flex: 1;
    height: 2px;
    background: #ddd;
    margin: 0 12px;
    position: relative;
}

.szm-stepper-item.completed ~ .szm-stepper-item .szm-stepper-connector::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 100%;
    background: var(--szm-success);
}

/* Search Box */
.szm-search-box {
    margin-bottom: 20px;
    position: relative;
}

.szm-search-input {
    width: 100%;
    padding: 10px 40px 10px 15px;
    border: 2px solid var(--szm-border);
    border-radius: 8px;
    font-size: 14px;
    transition: all 200ms;
    background: white;
}

.szm-search-input:focus {
    outline: none;
    border-color: var(--szm-primary);
    box-shadow: 0 0 0 3px rgba(34, 113, 177, 0.1);
}

.szm-search-input::placeholder {
    color: #999;
}

.szm-search-icon {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--szm-text-light);
    pointer-events: none;
}

.szm-autocomplete-results {
    position: absolute;
    top: calc(100% + 5px);
    left: 0;
    right: 0;
    background: white;
    border: 1px solid var(--szm-border);
    border-radius: 8px;
    max-height: 280px;
    overflow-y: auto;
    box-shadow: var(--szm-shadow-lg);
    z-index: 100;
    display: none;
}

.szm-autocomplete-results.visible {
    display: block;
}

.szm-autocomplete-item {
    padding: 10px 15px;
    cursor: pointer;
    transition: background 150ms;
    border-bottom: 1px solid #f0f0f0;
}

.szm-autocomplete-item:hover,
.szm-autocomplete-item.selected {
    background: var(--szm-bg-light);
}

.szm-autocomplete-item:last-child {
    border-bottom: none;
}

/* Breadcrumb (deprecated but kept for compatibility) */
.szm-breadcrumb {
    display: none;
}

.szm-breadcrumb-item {
    display: none;
}

.szm-breadcrumb-separator {
    display: none;
}

/* Step Sections */
.szm-step {
    display: block;
}

.szm-step h3 {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 15px 0;
    color: var(--szm-text);
}

/* Map Title */
.szm-map-title {
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 15px 0;
    color: var(--szm-text);
    padding-bottom: 15px;
    border-bottom: 2px solid var(--szm-border);
}

/* Lists */
.szm-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    max-height: 420px;
    overflow-y: auto;
    padding-right: 6px;
}

.szm-list-item {
    padding: 14px 18px;
    background: #ffffff;
    border: 1px solid #dfe5ec;
    border-radius: 14px;
    cursor: pointer;
    transition: all 200ms ease;
    font-size: 15px;
    font-weight: 600;
    color: #0f172a;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(17, 24, 39, 0.06);
    outline: none;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
}

.szm-list-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, #2563eb 0%, #1d4ed8 100%);
    transform: scaleY(0);
    transition: transform 200ms ease;
    border-radius: 14px 0 0 14px;
}

.szm-list-item::after {
    content: '→';
    position: absolute;
    right: 20px;
    font-size: 18px;
    font-weight: bold;
    color: #2563eb;
    opacity: 0;
    transform: translateX(-10px);
    transition: all 200ms ease;
}

.szm-list-item:hover::before {
    transform: scaleY(1);
}

.szm-list-item:hover::after {
    opacity: 1;
    transform: translateX(0);
}

.szm-list-item:hover {
    background: #f5f9ff;
    border-color: #3b82f6;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.12);
}

/* Hard override to remove any WP/theme pink/magenta states */
button.szm-list-item,
button.szm-list-item:hover,
button.szm-list-item:focus,
button.szm-list-item:focus-visible,
button.szm-list-item:active {
    border-color: #3b82f6 !important;
    color: #0f172a !important;
    outline: none !important;
}

button.szm-list-item {
    background: #ffffff !important;
}

button.szm-list-item:hover {
    background: #f5f9ff !important;
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.12) !important;
    transform: translateY(-2px) !important;
}

button.szm-list-item:focus,
button.szm-list-item:focus-visible {
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.2) !important;
}

button.szm-list-item:active {
    background: #e8f0ff !important;
    border-color: #1d4ed8 !important;
    transform: translateY(0) !important;
}

.szm-list-item:focus-visible {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.2);
}

.szm-list-item:active {
    transform: translateY(0);
    background: #e8f0ff;
    border-color: #1d4ed8;
}

.szm-list-item .szm-item-name {
    font-weight: 600;
    color: var(--szm-text);
}

.szm-list-item .szm-item-code {
    background: #eef2f7;
    color: #4b5563;
    border: 1px solid #d7dde5;
    border-radius: 999px;
    padding: 2px 10px;
    font-size: 12px;
    font-weight: 600;
}

.szm-list-item-icon {
    width: 22px;
    height: 22px;
    opacity: 0.7;
    transition: all 300ms cubic-bezier(0.4, 0, 0.2, 1);
}

.szm-list-item:hover .szm-list-item-icon {
    opacity: 1;
    transform: scale(1.1) rotate(5deg);
}

.szm-list-item .szm-item-name {
    font-weight: 600;
    color: #0f172a;
}

.szm-list-item .szm-item-code {
    background: #eef2f7;
    color: #475569;
    border: 1px solid #d4dae3;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    padding: 2px 10px;
}

/* Skeleton Loader */
.szm-skeleton {
    background: linear-gradient(
        90deg,
        #f0f0f0 0%,
        #e0e0e0 50%,
        #f0f0f0 100%
    );
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s ease-in-out infinite;
    border-radius: 4px;
}

@keyframes skeleton-loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.szm-skeleton-item {
    height: 48px;
    margin-bottom: 10px;
    border-radius: 8px;
}

.szm-skeleton-text {
    height: 16px;
    margin-bottom: 8px;
}

.szm-skeleton-text.short {
    width: 60%;
}

/* Villes Grid */
.szm-villes-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 15px;
    margin-bottom: 20px;
}

.szm-ville-card {
    padding: 15px;
    background: var(--szm-bg-light);
    border: 1px solid var(--szm-border);
    border-radius: 5px;
    transition: all 0.2s;
}

.szm-ville-card:hover {
    background: white;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

.szm-ville-card-title {
    font-size: 16px;
    font-weight: 600;
    margin: 0 0 8px 0;
}

.szm-ville-card-title a {
    color: var(--szm-primary);
    text-decoration: none;
}

.szm-ville-card-title a:hover {
    text-decoration: underline;
}

.szm-ville-card-excerpt {
    font-size: 14px;
    color: var(--szm-text-light);
    line-height: 1.5;
}

/* Buttons */
.szm-btn-back {
    background: transparent !important;
    border: none !important;
    color: var(--szm-primary) !important;
    font-size: 14px !important;
    cursor: pointer !important;
    padding: 8px 0 !important;
    margin-bottom: 15px !important;
    display: inline-block !important;
    transition: color 0.2s !important;
}

.szm-btn-back:hover {
    color: var(--szm-primary-hover) !important;
    text-decoration: underline !important;
    background: transparent !important;
}

.szm-btn-load-more {
    width: 100%;
    padding: 12px;
    background: var(--szm-primary);
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.szm-btn-load-more:hover {
    background: var(--szm-primary-hover);
}

.szm-btn-load-more:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* Loading State */
.szm-loading {
    text-align: center;
    padding: 20px;
    color: var(--szm-text-light);
    font-style: italic;
}

/* Notice */
.szm-notice {
    padding: 30px;
    background: var(--szm-bg-light);
    border: 1px solid var(--szm-border);
    border-radius: var(--szm-radius);
    text-align: center;
}

.szm-notice p {
    margin: 0;
    font-size: 16px;
    color: var(--szm-text-light);
}

/* SEO Links Section */
.szm-seo-links {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 2px solid var(--szm-border);
}

.szm-seo-links h2 {
    font-size: 28px;
    margin-bottom: 30px;
    color: var(--szm-text);
}

.szm-seo-region {
    margin-bottom: 40px;
}

.szm-seo-region h3 {
    font-size: 22px;
    margin-bottom: 20px;
    color: var(--szm-primary);
    padding-bottom: 10px;
    border-bottom: 1px solid var(--szm-border);
}

.szm-seo-departements {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin-left: 15px;
}

.szm-seo-departement {
    background: var(--szm-bg-light);
    padding: 20px;
    border-radius: 5px;
    border: 1px solid var(--szm-border);
}

.szm-seo-departement h4 {
    font-size: 16px;
    margin: 0 0 15px 0;
    color: var(--szm-text);
    font-weight: 600;
}

.szm-seo-villes-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.szm-seo-villes-list li {
    margin-bottom: 8px;
}

.szm-seo-villes-list a {
    color: var(--szm-primary);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.2s;
}

.szm-seo-villes-list a:hover {
    color: var(--szm-primary-hover);
    text-decoration: underline;
}

.szm-seo-footer {
    margin-top: 40px;
    text-align: center;
    padding: 30px;
    background: var(--szm-bg-light);
    border-radius: var(--szm-radius);
}

.szm-btn-view-all {
    display: inline-block;
    padding: 15px 30px;
    background: var(--szm-primary);
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 600;
    font-size: 16px;
    transition: background 0.2s;
}

.szm-btn-view-all:hover {
    background: var(--szm-primary-hover);
}

/* Pagination */
.szm-pagination {
    text-align: center;
    margin-top: 20px;
}

.szm-pagination button {
    background: var(--szm-primary);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 250ms var(--szm-transition);
    box-shadow: var(--szm-shadow-sm);
}

.szm-pagination button:hover {
    background: #c0392b;
    transform: translateY(-2px);
    box-shadow: var(--szm-shadow-lg);
}

.szm-pagination button:disabled {
    background: var(--szm-border);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes zoomIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.szm-fade-in {
    animation: fadeIn 0.4s var(--szm-transition) forwards;
}

.szm-slide-in {
    animation: slideInRight 0.4s var(--szm-transition) forwards;
}

/* Custom Scrollbar */
.szm-list::-webkit-scrollbar,
.szm-sidebar::-webkit-scrollbar {
    width: 8px;
}

.szm-list::-webkit-scrollbar-track,
.szm-sidebar::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.szm-list::-webkit-scrollbar-thumb,
.szm-sidebar::-webkit-scrollbar-thumb {
    background: #bbb;
    border-radius: 10px;
}

.szm-list::-webkit-scrollbar-thumb:hover,
.szm-sidebar::-webkit-scrollbar-thumb:hover {
    background: var(--szm-primary);
}

/* Responsive */
@media (max-width: 768px) {
    .szm-map-wrapper {
        margin: 1rem auto;
        padding: 0 12px;
    }

    .szm-filter-section {
        padding: 12px;
        gap: 10px;
    }

    .szm-filter-label {
        font-size: 14px;
    }

    .szm-select {
        padding: 8px 12px;
        font-size: 14px;
    }

    .szm-filter-section {
        flex-direction: column;
        align-items: stretch;
    }
    
    .szm-select {
        max-width: none;
    }
    
    .szm-seo-departements {
        grid-template-columns: 1fr;
    }
    
    .szm-container {
        flex-direction: column;
    }
    
    .szm-map-wrapper,
    .szm-sidebar {
        width: 100%;
    }
    
    .szm-stepper {
        display: none;
    }

    #szm-step-region,
    #szm-step-departement {
        display: none !important;
    }

    #szm-step-villes {
        display: none !important;
    }
    
    .szm-search-box {
        margin-bottom: 10px;
    }

    .szm-mobile-back-buttons {
        display: flex;
        gap: 10px;
        margin: 0 0 10px;
        flex-wrap: wrap;
    }

    .szm-mobile-back-buttons .szm-btn-back {
        display: none !important;
        margin: 0 !important;
        padding: 6px 0 !important;
        font-size: 13px !important;
    }

    .szm-mobile-providers-btn {
        margin-top: 10px;
        width: 100%;
        padding: 12px 16px;
        background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
        color: #ffffff !important;
        border: none !important;
        outline: none;
        border-radius: 10px;
        font-size: 14px;
        font-weight: 600;
        cursor: pointer;
        box-shadow: 0 6px 16px rgba(37, 99, 235, 0.25);
        transition: transform 0.15s ease, box-shadow 0.2s ease, filter 0.2s ease;
        text-align: center;
        text-transform: uppercase;
        letter-spacing: 0.4px;
        -webkit-tap-highlight-color: transparent;
    }

    .szm-mobile-providers-btn:active {
        transform: translateY(1px);
    }

    .szm-mobile-providers-btn:hover {
        box-shadow: 0 10px 20px rgba(37, 99, 235, 0.3);
        filter: brightness(1.03);
    }

    .szm-mobile-providers-btn:focus-visible {
        outline: 3px solid rgba(37, 99, 235, 0.4);
        outline-offset: 2px;
    }

    

.szm-mobile-providers-modal .szm-modal-content {
    padding: 28px 22px;
}

.szm-providers-search {
    margin-bottom: 16px;
    margin-top: 14px;
}

.szm-providers-search-input {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--szm-border);
    border-radius: 10px;
    font-size: 14px;
    font-family: inherit;
    color: var(--szm-text);
    background: #f8f9fa;
    transition: all 0.2s ease;
}

.szm-providers-search-input:focus {
    outline: none;
    border-color: var(--szm-primary);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.szm-providers-search-input::placeholder {
    color: #999;
    font-size: 13px;
}

.szm-providers-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 16px;
}

.szm-providers-list .szm-loading,
.szm-providers-list .szm-error,
.szm-providers-list .szm-no-results {
    padding: 20px;
    text-align: center;
    color: var(--szm-text-light);
    font-size: 14px;
}

.szm-provider-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 14px;
    border: 1px solid var(--szm-border);
    border-radius: 10px;
    text-decoration: none;
    color: var(--szm-text);
    background: #fff;
}

.szm-provider-name {
    font-weight: 600;
    font-size: 14px;
}

.szm-provider-dept {
    font-size: 12px;
    color: var(--szm-text-light);
}

.szm-provider-distance {
    font-size: 13px;
    font-weight: 700;
    color: var(--szm-primary);
    background: #e3f2fd;
    padding: 4px 8px;
    border-radius: 10px;
    white-space: nowrap;
}
    .szm-main-grid {
        gap: 12px;
    }
    
    .szm-map-section {
        min-height: 320px;
        padding: 12px;
    }

    .szm-map-title {
        font-size: 16px;
        margin-bottom: 10px;
        padding-bottom: 10px;
    }
    
    .szm-sidebar {
        display: none;
    }
    
    .szm-list {
        max-height: 240px;
        gap: 8px;
    }

    .szm-list-item {
        padding: 12px 14px;
        font-size: 14px;
        border-radius: 10px;
    }

    .szm-btn-back {
        font-size: 13px !important;
        margin-bottom: 10px !important;
    }

    .szm-ville-card {
        padding: 12px;
    }

    .szm-ville-card-title {
        font-size: 15px;
    }

    .szm-ville-card-excerpt {
        font-size: 13px;
    }
}

/* Loading Spinner */
.szm-loading-container {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 40px 20px !important;
    gap: 20px !important;
    min-height: 150px;
}

.szm-spinner {
    width: 50px !important;
    height: 50px !important;
    border: 4px solid rgba(34, 113, 177, 0.2) !important;
    border-top-color: var(--szm-primary) !important;
    border-radius: 50% !important;
    animation: szm-spin 1s linear infinite !important;
}

@keyframes szm-spin {
    to {
        transform: rotate(360deg);
    }
}

.szm-loading-message {
    margin: 0 !important;
    font-size: 16px !important;
    color: var(--szm-text-light) !important;
    text-align: center !important;
    font-weight: 500 !important;
}

/* Overlay de chargement sur la carte (mobile uniquement) */
.szm-map-loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Provider Cards in Modal */
.szm-providers-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.szm-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    cursor: pointer;
}

.szm-modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 900px;
    width: 90%;
    max-height: 90vh;
    overflow: auto;
    display: flex;
    flex-direction: column;
}

.szm-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px;
    border-bottom: 1px solid #e5e7eb;
    flex-shrink: 0;
}

.szm-modal-header h2 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: #1f2937;
}

.szm-modal-close {
    background: none;
    border: none;
    font-size: 28px;
    color: #9ca3af;
    cursor: pointer;
    padding: 0;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.szm-modal-close:hover {
    background: #f3f4f6;
    color: #1f2937;
}

.szm-modal-body {
    padding: 24px;
    flex: 1;
    overflow-y: auto;
    min-height: 200px;
}

/* Map Container in Modal */
.szm-modal-map-container {
    width: 100%;
    height: 400px;
    border-radius: 8px;
    margin-bottom: 20px;
    overflow: hidden;
}

.szm-modal-map-container .leaflet-container {
    height: 100%;
    width: 100%;
}

.szm-modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 16px 24px;
    border-top: 1px solid #e5e7eb;
    flex-shrink: 0;
}

/* Provider Popup in Map */
.szm-provider-popup {
    padding: 8px 0;
}

.szm-provider-popup h4 {
    margin: 0 0 8px 0;
    font-size: 14px;
    font-weight: 600;
    color: #1f2937;
}

.szm-provider-popup p {
    margin: 0 0 8px 0;
    font-size: 12px;
    color: #6b7280;
}

.szm-provider-popup .szm-provider-link {
    font-size: 12px;
}

/* Responsive Modal */

.szm-provider-card {
    padding: 16px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.szm-provider-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    border-color: #2563eb;
}

.szm-provider-card h4 {
    margin: 0 0 8px 0;
    font-size: 15px;
    font-weight: 600;
    color: #1f2937;
}

.szm-provider-meta {
    margin: 0 0 12px 0;
    font-size: 13px;
    color: #6b7280;
}

.szm-provider-link {
    display: inline-block;
    padding: 8px 16px;
    background: #2563eb;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.szm-provider-link:hover {
    background: #1d4ed8;
    text-decoration: none;
}

/* Modal Loading State */
.szm-providers-loading {
    text-align: center;
    padding: 40px 20px;
    color: #6b7280;
}

/* Modal Error State */
.szm-error {
    color: #dc2626;
    text-align: center;
    padding: 20px;
}

/* Modal No Results State */
.szm-no-providers {
    text-align: center;
    color: #6b7280;
    padding: 40px 20px;
    font-size: 15px;
}

/* Modal Button */
.szm-modal-btn {
    padding: 10px 20px;
    border: 1px solid #2563eb;
    background: #2563eb;
    color: #ffffff;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.szm-modal-btn:hover {
    background: #1d4ed8;
    border-color: #1d4ed8;
}

.szm-mobile-providers-modal .szm-modal-btn {
    background: #2563eb !important;
    color: #ffffff !important;
    border: 1px solid #2563eb !important;
}

.szm-mobile-providers-modal .szm-modal-btn:hover {
    background: #1d4ed8 !important;
    border-color: #1d4ed8 !important;
}

#szm-nuisible-modal .szm-modal-btn {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%) !important;
    color: #ffffff !important;
    border: none !important;
    width: auto !important;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    padding: 12px 28px !important;
    border-radius: 10px !important;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3) !important;
}

#szm-nuisible-modal .szm-modal-btn:hover {
    background: linear-gradient(135deg, #1d4ed8 0%, #1e40af 100%) !important;
}

#szm-nuisible-modal .szm-modal-content {
    max-width: 380px;
    width: 88%;
}

.szm-modal-btn-close {
    border-color: #2563eb !important;
    color: #2563eb !important;
}

.szm-modal-btn-close:hover {
    background: #eff6ff !important;
}

/* Responsive Modal */
@media (max-width: 640px) {
    .szm-modal-content {
        width: 95%;
        max-height: 90vh;
    }
    
    .szm-modal-header {
        padding: 16px;
    }
    
    .szm-modal-body {
        padding: 16px;
    }
    
    .szm-modal-footer {
        padding: 12px 16px;
    }
}


