/* DataTables CSS */
@import url('https://cdn.datatables.net/1.13.7/css/jquery.dataTables.min.css');
@import url('https://cdn.datatables.net/buttons/2.4.2/css/buttons.dataTables.min.css');

/* Header */
#groupedTable thead th {
    background-color: #e8f5e9 !important;
    color: #2e7d32 !important;
    border-bottom: 2px solid #a5d6a7 !important;
    border-top: none !important;
    font-weight: 600;
    font-size: 11px;
    vertical-align: top;
    padding: 8px 4px !important;
    text-align: left;
    white-space: nowrap;
}
#groupedTable thead th:hover { background-color: #c8e6c9 !important; }
#groupedTable thead th .header-wrapper { display: flex; flex-direction: column; gap: 4px; }
#groupedTable thead th .header-title { font-weight: 600; white-space: nowrap; }

/* Column filter inputs */
#groupedTable thead th input {
    width: 100%; min-width: 40px; font-size: 10px;
    padding: 3px 5px; border: 1px solid #ced4da;
    border-radius: 3px; background-color: #fff; box-sizing: border-box;
}
#groupedTable thead th input:focus {
    border-color: #6c9c3a; outline: none;
    box-shadow: 0 0 0 2px rgba(108, 156, 58, 0.2);
}
#groupedTable thead th input::placeholder { color: #aaa; font-size: 9px; }

/* Rows */
#groupedTable { border-collapse: collapse !important; font-size: 13px; }
#groupedTable td { border: none !important; border-bottom: 1px solid #eee !important; padding: 12px 8px !important; vertical-align: middle; }
#groupedTable th { border: none !important; }
#groupedTable tbody tr { border-bottom: 1px solid #dee2e6; }
#groupedTable tbody tr:hover { background-color: #f1f8e9 !important; }

/* Footer */
#groupedTable tfoot th {
    background-color: #f8f9fa !important; font-weight: 600;
    font-size: 12px; padding: 8px 6px !important;
    border-top: 2px solid #dee2e6 !important;
}

/* Excel button */
.dt-buttons .dt-button {
    background-color: transparent !important; background-image: none !important;
    border: 1px solid #198754 !important; color: #198754 !important;
    padding: 6px 12px !important; border-radius: 5px !important;
    font-size: 14px !important; font-weight: 500 !important;
    transition: all 0.15s ease-in-out !important;
}
.dt-buttons .dt-button:hover { background-color: #198754 !important; color: #fff !important; }

/* DataTables search box */
.dataTables_filter { margin-bottom: 15px; }
.dataTables_filter label { display: flex !important; align-items: center; font-weight: 500; color: #495057; }
.dataTables_filter label::before { content: "\F52A"; font-family: "bootstrap-icons"; margin-right: 8px; color: #6c9c3a; font-size: 16px; }
.dataTables_filter input {
    border: 2px solid #e8f5e9 !important; border-radius: 25px !important;
    padding: 10px 18px !important; margin-left: 10px !important;
    width: 280px !important; font-size: 14px !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.dataTables_filter input:focus { border-color: #6c9c3a !important; outline: none !important; box-shadow: 0 0 0 4px rgba(108, 156, 58, 0.15) !important; }
.dataTables_filter input::placeholder { color: #adb5bd; }

/* Pagination */
.dataTables_info { font-size: 13px; color: #6c757d; }
.dataTables_paginate .paginate_button { border-radius: 4px !important; }
.dataTables_paginate .paginate_button.current,
.dataTables_paginate .paginate_button.current:hover,
.dataTables_wrapper .dataTables_paginate .paginate_button.current,
.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
    background: #6c9c3a !important; border: 1px solid #6c9c3a !important; color: #ffffff !important;
}

/* Collapse icon */
.collapse-icon { transition: transform 0.3s ease; }
[aria-expanded="false"] .collapse-icon { transform: rotate(-90deg); }
[aria-expanded="true"] .collapse-icon { transform: rotate(0deg); }

/* Zone colors */
.zone-northern { color: #0d6efd; font-weight: 500; }
.zone-central { color: #198754; font-weight: 500; }
.zone-southern { color: #fd7e14; font-weight: 500; }

/* Info buttons */
.btn-area-info { padding: 2px 6px; font-size: 10px; border-radius: 12px; margin-left: 4px; }

/* Print button — même style que Excel */
.dt-buttons .dt-button.buttons-print {
    border: 1px solid #6c757d !important;
    color: #6c757d !important;
}
.dt-buttons .dt-button.buttons-print:hover {
    background-color: #6c757d !important;
    color: #fff !important;
}