/* Thème vert SolHead professionnel uniforme - Pages d'administration */
.admin-layout {
    background: #e5ead5;
    color: #1a2e1f;
    min-height: 100vh;
}

.admin-content {
    background: #e5ead5;
    color: #1a2e1f;
}

.card {
    background: #2a3d2f !important;
    border: 1px solid #3d5544;
    color: #f1f5f9;
    border-radius: 0.5rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.card-header {
    background: linear-gradient(135deg, #4a7c59 0%, #5a8f5e 100%) !important;
    border-bottom: 1px solid #6aa070;
    color: #ffffff !important;
    font-weight: 600;
    border-radius: 0.5rem 0.5rem 0 0 !important;
}

.table {
    color: #f1f5f9;
    background: transparent;
}

.table thead th {
    border-bottom: 2px solid #6aa070;
    color: #ffffff !important;
    background: linear-gradient(135deg, #4a7c59 0%, #5a8f5e 100%) !important;
    font-weight: 600;
    font-size: 14px;
}

.table td {
    border-top: 1px solid #475569;
    color: #f1f5f9 !important;
    background: transparent !important;
    font-size: 14px;
}

/* Effets de survol désactivés - fond blanc */
.table tbody tr {
    cursor: default;
    transition: none;
}

.table tbody tr:hover {
    background-color: #FFFFFF !important;
    color: #212121 !important;
}

.table-hover > tbody > tr:hover > * {
    background-color: #FFFFFF !important;
    color: #212121 !important;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
    transition: all 0.3s ease;
}

/* Sidebar navigation */
.admin-sidebar {
    background: #2E7D32;
    border-right: 1px solid #43A047;
    min-height: 100vh;
}

.admin-nav .nav-item .nav-link {
    color: #e2e8f0 !important;
    padding: 12px 20px;
    border-radius: 0.375rem;
    margin: 2px 0;
    transition: all 0.2s ease;
    font-size: 14px;
    font-weight: 500;
}

.admin-nav .nav-item .nav-link:hover {
    background: rgba(255, 255, 255, 0.2);
    color: #ffffff !important;
    transform: translateX(4px);
}

.admin-nav .nav-item.active .nav-link {
    background: rgba(255, 255, 255, 0.25);
    color: #ffffff !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.logout-link:hover {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%) !important;
    color: #ffffff !important;
}

/* Boutons uniformes avec fond solide - CHARTE GRAPHIQUE SolHead */
.btn-primary, .btn-success, .btn-warning, .btn-danger, .btn-info, .btn-secondary {
    background: #4a7c59 !important;
    border: 2px solid #4a7c59 !important;
    color: #ffffff !important;
    font-weight: 500;
    font-size: 13px;
    padding: 8px 16px;
    border-radius: 0.375rem;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(74, 124, 89, 0.2) !important;
}

.btn-primary:hover, .btn-success:hover, .btn-warning:hover, .btn-danger:hover, 
.btn-info:hover, .btn-secondary:hover {
    background: #5a8f5e !important;
    border-color: #5a8f5e !important;
    color: #ffffff !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 4px 8px rgba(74, 124, 89, 0.3) !important;
}

/* Boutons outline uniformes aussi */
.btn-outline-primary, .btn-outline-success, .btn-outline-warning, .btn-outline-danger,
.btn-outline-info, .btn-outline-secondary {
    background: #ffffff !important;
    border: 2px solid #4a7c59 !important;
    color: #4a7c59 !important;
    font-weight: 500;
    font-size: 13px;
    padding: 8px 16px;
    border-radius: 0.375rem;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(74, 124, 89, 0.1) !important;
}

.btn-outline-primary:hover, .btn-outline-success:hover, .btn-outline-warning:hover, 
.btn-outline-danger:hover, .btn-outline-info:hover, .btn-outline-secondary:hover {
    background: #4a7c59 !important;
    border-color: #4a7c59 !important;
    color: #ffffff !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 4px 8px rgba(74, 124, 89, 0.3) !important;
}

/* Boutons petits (sm) avec meilleure lisibilité */
.btn-sm {
    padding: 8px 12px !important;
    font-size: 12px !important;
    border-radius: 0.25rem !important;
    font-weight: 500 !important;
    min-width: 90px !important;
    text-align: center !important;
}

/* Amélioration de la lisibilité des boutons d'actions */
.btn-group {
    gap: 4px;
}

.btn-group .btn {
    margin-right: 0 !important;
}

/* Colonne Actions plus large */
th:last-child, td:last-child {
    min-width: 200px !important;
    white-space: nowrap;
}

/* Boutons d'actions avec couleurs spécifiques - Fond clair compatible */
.btn-primary {
    background: #4a7c59 !important;
    border-color: #4a7c59 !important;
    color: #ffffff !important;
}

.btn-primary:hover {
    background: #5a8f5e !important;
    border-color: #5a8f5e !important;
    color: #ffffff !important;
}

.btn-warning {
    background: #ef4444 !important;
    border-color: #ef4444 !important;
    color: #ffffff !important;
}

.btn-warning:hover {
    background: #dc2626 !important;
    border-color: #dc2626 !important;
    color: #ffffff !important;
}

.btn-success {
    background: #10b981 !important;
    border-color: #10b981 !important;
    color: #ffffff !important;
}

.btn-success:hover {
    background: #059669 !important;
    border-color: #059669 !important;
    color: #ffffff !important;
}

/* Styles pour les permissions avec coches vertes */
.permissions-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.permission-item {
    flex: 1;
    min-width: 120px;
}

.permission-box {
    border: 1px solid #475569;
    border-radius: 6px;
    padding: 8px 12px;
    background: rgba(51, 65, 85, 0.3);
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #e2e8f0;
}

.permission-box:hover {
    border-color: #64748b;
    background: rgba(51, 65, 85, 0.5);
}

.permission-box.permission-active {
    border-color: #10b981;
    background: rgba(16, 185, 129, 0.1);
}

.permission-check {
    color: #10b981;
    font-size: 16px;
    display: inline;
}

.permission-box:not(.permission-active) .permission-check {
    display: none;
}

/* Styles pour les permissions dans le tableau des utilisateurs */
.permissions-grid-table {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.permission-item-table {
    border: 1px solid #475569;
    border-radius: 4px;
    padding: 4px 8px;
    background: rgba(51, 65, 85, 0.3);
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #e2e8f0;
    min-width: 60px;
    justify-content: center;
}

.permission-item-table.permission-active {
    border-color: #10b981;
    background: rgba(16, 185, 129, 0.1);
}

.permission-item-table .permission-check {
    color: #10b981;
    font-size: 12px;
}

/* Ajustements pour les permissions dans les cartes */
.request-card .permissions-grid-table {
    gap: 8px;
}

.request-card .permission-item-table {
    min-width: 80px;
    font-size: 13px;
    padding: 6px 10px;
}

/* Badges discrets selon charte graphique */
.badge {
    font-weight: 500 !important;
    font-size: 11px !important;
    padding: 4px 8px !important;
    border-radius: 0.25rem !important;
    background: transparent !important;
    border: 1px solid #64748b !important;
    color: #94a3b8 !important;
}

.badge.bg-success {
    border-color: #10b981 !important;
    color: #10b981 !important;
    background: rgba(16, 185, 129, 0.1) !important;
}

.badge.bg-info {
    border-color: #06b6d4 !important;
    color: #06b6d4 !important;
    background: rgba(6, 182, 212, 0.1) !important;
}

.badge.bg-warning {
    border-color: #f59e0b !important;
    color: #f59e0b !important;
    background: rgba(245, 158, 11, 0.1) !important;
}

.badge.bg-primary {
    border-color: #3b82f6 !important;
    color: #3b82f6 !important;
    background: rgba(59, 130, 246, 0.1) !important;
}

.badge.bg-secondary {
    border-color: #64748b !important;
    color: #94a3b8 !important;
    background: rgba(100, 116, 139, 0.1) !important;
}

/* Onglets avec thème uniforme */
.nav-tabs .nav-link {
    background: linear-gradient(135deg, #334155 0%, #475569 100%) !important;
    border: 1px solid #64748b !important;
    color: #e2e8f0 !important;
    font-weight: 500;
    font-size: 14px;
    border-radius: 0.375rem 0.375rem 0 0 !important;
    margin-right: 2px;
    transition: all 0.2s ease;
}

.nav-tabs .nav-link:hover {
    background: linear-gradient(135deg, #475569 0%, #64748b 100%) !important;
    color: #ffffff !important;
    border-color: #64748b !important;
}

.nav-tabs .nav-link.active {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%) !important;
    color: #ffffff !important;
    border-color: #3b82f6 !important;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

/* Éléments vides avec style uniforme */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #94a3b8 !important;
}

.empty-state i {
    color: #64748b !important;
}

.empty-state h4 {
    color: #94a3b8 !important;
    font-weight: 500;
}

.empty-state p {
    color: #64748b !important;
}

/* Garder les couleurs des badges produits */
.badge.bg-success {
    background-color: #198754 !important;
    color: #ffffff !important;
}

.badge.bg-warning {
    background-color: #ffc107 !important;
    color: #000000 !important;
}

.badge.bg-info {
    background-color: #0dcaf0 !important;
    color: #000000 !important;
}

.badge {
    transition: none !important;
}

.text-muted {
    color: #cccccc !important;
}

.form-control {
    background-color: #FFFFFF !important;
    border: 1px solid #E0E0E0 !important;
    color: #212121 !important;
}

.form-control:focus {
    background-color: #FFFFFF !important;
    border-color: #2E7D32 !important;
    color: #212121 !important;
    box-shadow: 0 0 0 0.2rem rgba(46, 125, 50, 0.15) !important;
}

/* Tous les form-select - Thème blanc */
.form-select {
    background-color: #FFFFFF !important;
    border: 1px solid #E0E0E0 !important;
    color: #212121 !important;
    font-weight: 500 !important;
}

.form-select:focus {
    background-color: #FFFFFF !important;
    border-color: #2E7D32 !important;
    color: #212121 !important;
    box-shadow: 0 0 0 0.2rem rgba(46, 125, 50, 0.15) !important;
}

.form-select option {
    background-color: #FFFFFF !important;
    color: #212121 !important;
}

/* Spécifiquement pour les selects de statut - Thème blanc */
select.status-select,
.status-select.form-select {
    background-color: #FFFFFF !important;
    color: #212121 !important;
    border: 1px solid #E0E0E0 !important;
    font-weight: 500 !important;
}

select.status-select option,
.status-select.form-select option {
    background-color: #FFFFFF !important;
    color: #212121 !important;
}

.modal-content {
    background-color: #2d2d2d;
    color: #ffffff;
}

.modal-header {
    background: linear-gradient(135deg, #4a7c59 0%, #5a8f5e 100%) !important;
    color: #ffffff !important;
    border-bottom: 1px solid #6aa070;
}

.modal-footer {
    border-top: 1px solid #404040;
}

/* Styles pour les tooltips Bootstrap - Charte verte SolHead */
.tooltip {
    font-size: 14px !important;
}

.tooltip-inner {
    background: linear-gradient(135deg, #4a7c59 0%, #5a8f5e 100%) !important;
    color: #ffffff !important;
    padding: 12px 16px !important;
    border-radius: 8px !important;
    font-size: 14px !important;
    max-width: 350px !important;
    text-align: left !important;
    box-shadow: 0 4px 12px rgba(74, 124, 89, 0.4) !important;
    border: 2px solid #c5d86d !important;
}

.tooltip.bs-tooltip-auto[data-popper-placement^=top] .tooltip-arrow::before,
.tooltip.bs-tooltip-top .tooltip-arrow::before {
    border-top-color: #4a7c59 !important;
}

.tooltip.bs-tooltip-auto[data-popper-placement^=bottom] .tooltip-arrow::before,
.tooltip.bs-tooltip-bottom .tooltip-arrow::before {
    border-bottom-color: #4a7c59 !important;
}

.tooltip.bs-tooltip-auto[data-popper-placement^=left] .tooltip-arrow::before,
.tooltip.bs-tooltip-start .tooltip-arrow::before {
    border-left-color: #4a7c59 !important;
}

.tooltip.bs-tooltip-auto[data-popper-placement^=right] .tooltip-arrow::before,
.tooltip.bs-tooltip-end .tooltip-arrow::before {
    border-right-color: #4a7c59 !important;
}

/* Badge info plus visible avec la charte verte */
.badge.bg-info {
    background: linear-gradient(135deg, #c5d86d 0%, #b8a62f 100%) !important;
    color: #1e293b !important;
    font-size: 13px !important;
    padding: 6px 10px !important;
    font-weight: 600 !important;
    border: 1px solid #b8a62f !important;
    cursor: help !important;
}

.btn-close {
    filter: invert(1);
}

/* Garder uniquement les boutons interactifs */
.btn:hover {
    opacity: 0.9;
}

/* Style pour les cartes clients */
.client-card {
    background-color: #343a46;
    border: 1px solid #495057;
    border-radius: 12px;
    padding: 0;
    transition: all 0.3s ease;
    overflow: hidden;
}

.client-card:hover {
    border-color: #6c757d;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.client-header {
    background-color: #2d3339;
    padding: 15px 20px;
    border-bottom: 1px solid #495057;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.client-header h6 {
    color: #fff;
    margin: 0;
    font-weight: 600;
}

.client-header small {
    color: #adb5bd;
}

.client-actions {
    margin-left: auto;
}

.client-info {
    padding: 20px;
    color: #e9ecef;
}

.client-info p {
    margin-bottom: 8px;
    font-size: 14px;
}

.client-info strong {
    color: #fff;
}

.products-badges {
    margin-top: 5px;
}

/* FIX: Dropdown départements lisible - Thème blanc */
select[name="departement"] {
    background-color: #FFFFFF !important;
    border: 1px solid #E0E0E0 !important;
    color: #212121 !important;
    font-weight: bold !important;
}

select[name="departement"] option {
    background-color: #FFFFFF !important;
    color: #212121 !important;
    font-weight: bold !important;
    padding: 10px !important;
}

/* Forcer sur tous les selects - Thème blanc */
.admin-content select,
.admin-layout select {
    background-color: #FFFFFF !important;
    border: 1px solid #E0E0E0 !important;
    color: #212121 !important;
    font-weight: bold !important;
}

.admin-content select option,
.admin-layout select option {
    background-color: #FFFFFF !important;
    color: #212121 !important;
    font-weight: bold !important;
    padding: 8px 12px !important;
}
