     /* =========== RESPONSIVE STYLES =========== */
     /* Container principal */
 #products-wrapper {
     width: 100%;
     max-width: 100%;
     overflow-x: hidden;
 }

.center-content {
    padding: 15px;
    max-width: 100%;
}

/* Header responsive */
.header-section-products {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    background: #f5f5dc;
    padding: 15px;
    gap: 15px;
    margin-bottom: 20px;
}

.title-section {
    margin: 0;
    font-size: 20px;
    font-weight: bold;
    color: #333;
    flex: 1;
    min-width: 200px;
}

.group-btns {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.btn-left, .btn-right {
    padding: 8px 16px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    white-space: nowrap;
}

.btn-left { background-color: #4CAF50; color: white; }
.btn-right { background-color: #2196F3; color: white; }

/* Layout responsive */
.pays-layout {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    width: 100%;
}

.pays-col {
    flex: 1;
    min-width: 300px;
    max-width: 100%;
}

.souspays-col {
    flex: 1;
    min-width: 300px;
    max-width: 100%;
}

/* Table responsive */
.table-wrapper {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    overflow: hidden;
}

.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.custom-table {
    width: 100%;
    min-width: 600px;
    border-collapse: collapse;
}

.custom-table thead {
    background-color: #f8f9fa;
}

.custom-table th, .custom-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.custom-table th {
    font-weight: 600;
    color: #333;
    white-space: nowrap;
}

.custom-table .filters th {
    background-color: #f1f3f5;
    padding: 8px 15px;
}

.custom-table .filters input {
    width: 100%;
    padding: 6px 8px;
    font-size: 14px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

/* Lignes sélectionnées */
.pays-row {
    cursor: pointer;
    transition: background-color 0.2s;
}

.pays-row:hover {
    background-color: #f8f9fa;
}

.pays-row.selected {
    background-color: #e3f2fd;
    border-left: 4px solid #2196f3;
}

/* Actions responsive */
.actions {
    display: flex;
    gap: 10px;
    flex-wrap: nowrap;
}

.actions a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.actions a:hover {
    background-color: rgba(0,0,0,0.05);
}

/* Sous-pays section */
.souspays-wrapper {
    position: relative;
    min-height: 300px;
    padding: 20px;
    border-left: 2px solid #c90d7d;
}

.select-pays-message {
    font-size: 14px;
    color: #1a60c2;
    font-weight: 500;
    text-align: center;
    padding: 40px 20px;
}

/* Loader */
#souspays-loader {
    position: absolute;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.9);
    z-index: 10;
}

.loader-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 4px solid #ddd;
    border-top-color: #0c0a3b;
    animation: spin 0.7s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* =========== MEDIA QUERIES =========== */
/* Tablettes */
@media (max-width: 1024px) {
    .pays-layout {
        flex-direction: column;
    }

    .pays-col, .souspays-col {
        min-width: 100%;
    }

    .souspays-wrapper {
        border-left: none;
        border-top: 2px solid #c90d7d;
        padding-left: 0;
        padding-top: 20px;
    }
}

/* Mobiles (portrait) */
@media (max-width: 768px) {
    .header-section-products {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .title-section {
        font-size: 18px;
    }

    .group-btns {
        width: 100%;
        justify-content: stretch;
    }

    .btn-left, .btn-right {
        flex: 1;
        padding: 10px;
        font-size: 13px;
    }

    .center-content {
        padding: 10px;
    }

    .custom-table th, .custom-table td {
        padding: 10px 8px;
        font-size: 13px;
    }

    .custom-table .filters input {
        font-size: 12px;
        padding: 5px;
    }

    .actions {
        gap: 5px;
    }

    .actions a {
        width: 32px;
        height: 32px;
    }

    .actions i {
        font-size: 16px !important;
        margin-right: 8px !important;
    }
}

/* Petits mobiles */
@media (max-width: 480px) {
    .title-section {
        font-size: 16px;
    }

    .btn-left, .btn-right {
        font-size: 12px;
        padding: 8px;
    }

    .custom-table {
        min-width: 500px;
    }

    .custom-table th, .custom-table td {
        padding: 8px 6px;
        font-size: 12px;
    }

    .souspays-wrapper {
        padding: 15px;
    }
}

/* Pour les très petits écrans, rendre le tableau en mode carte */
@media (max-width: 360px) {
    .custom-table thead {
        display: none;
    }

    .custom-table tbody tr {
        display: block;
        margin-bottom: 15px;
        border: 1px solid #ddd;
        border-radius: 8px;
        padding: 15px;
    }

    .custom-table tbody td {
        display: flex;
        justify-content: space-between;
        padding: 8px 0;
        border-bottom: 1px solid #eee;
    }

    .custom-table tbody td:last-child {
        border-bottom: none;
    }

    .custom-table tbody td:before {
        content: attr(data-label);
        font-weight: bold;
        color: #333;
        flex: 0 0 120px;
    }

    .actions {
        justify-content: center;
    }

    .pays-row.selected {
        border-left: none;
        box-shadow: 0 0 0 2px #2196f3;
    }
}

/* Empêcher le débordement horizontal */
body {
    overflow-x: hidden;
    max-width: 100vw;
}

/* Améliorer la lisibilité sur mobile */
@media (max-width: 768px) {
    body {
        font-size: 14px;
    }

    .pays-row {
        font-size: 13px;
    }
}

/* Scrollbar stylisée pour table */
.table-responsive::-webkit-scrollbar {
    height: 6px;
}

.table-responsive::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.table-responsive::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 3px;
}

.table-responsive::-webkit-scrollbar-thumb:hover {
    background: #555;
}