/* ===== RESET & BASE ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #4a90e2;
    --primary-dark: #2c6cb0;
    --secondary-color: #7b68ee;
    --success-color: #2ecc71;
    --warning-color: #f39c12;
    --danger-color: #e74c3c;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
    --gray-light: #e9ecef;
    --gray: #6c757d;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.15);
    --border-radius: 8px;
    --transition: all 0.3s ease;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    color: var(--dark-color);
    min-height: 100vh;
    overflow-x: hidden;
}

/* ===== HEADER ===== */
.main-header {
    background: white;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-left {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.header-left h1 {
    color: var(--primary-color);
    font-size: 1.8rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.breadcrumb {
    display: flex;
    gap: 0.5rem;
    font-size: 0.9rem;
}

.breadcrumb-item {
    color: var(--gray);
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    transition: var(--transition);
}

.breadcrumb-item:hover {
    background: var(--gray-light);
}

.breadcrumb-item.active {
    color: var(--primary-color);
    font-weight: 600;
    background: var(--gray-light);
}

.breadcrumb-separator {
    color: var(--gray);
}

.header-center {
    flex: 1;
    max-width: 500px;
    margin: 0 2rem;
}

.search-box {
    display: flex;
    background: white;
    border: 2px solid var(--gray-light);
    border-radius: 50px;
    padding: 0.5rem 1rem;
    transition: var(--transition);
}

.search-box:focus-within {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.2);
}

.search-box i {
    color: var(--gray);
    margin-right: 0.5rem;
    align-self: center;
}

.search-box input {
    flex: 1;
    border: none;
    outline: none;
    font-size: 1rem;
    background: transparent;
}

.btn-search {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 0.5rem 1.5rem;
    border-radius: 50px;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
    margin-left: 0.5rem;
}

.btn-search:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

.header-right {
    display: flex;
    gap: 1rem;
}

/* ===== BOUTONS ===== */
.btn {
    padding: 0.5rem 1.5rem;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.btn:active {
    transform: translateY(0);
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: var(--primary-dark);
}

.btn-success {
    background: var(--success-color);
    color: white;
}

.btn-success:hover {
    background: #27ae60;
}

.btn-secondary {
    background: var(--gray);
    color: white;
}

.btn-sm {
    padding: 0.25rem 0.75rem;
    font-size: 0.9rem;
}

/* ===== LAYOUT PRINCIPAL ===== */
.main-container {
    display: flex;
    height: calc(100vh - 90px);
}

/* ===== SIDEBARS ===== */
.sidebar-left, .sidebar-right {
    width: 280px;
    background: white;
    padding: 1.5rem;
    overflow-y: auto;
    box-shadow: var(--shadow);
    z-index: 10;
    transition: var(--transition);
}

.sidebar-section {
    margin-bottom: 2rem;
}

.sidebar-section h3 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    color: var(--primary-dark);
    font-size: 1.1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--gray-light);
}

/* Outils */
.toolbox {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
}

.tool-btn {
    aspect-ratio: 1;
    border: 2px solid var(--gray-light);
    background: white;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-size: 1.2rem;
    color: var(--gray);
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.tool-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-2px);
}

.tool-btn.active {
    border-color: var(--primary-color);
    background: var(--primary-color);
    color: white;
}

/* Panneaux propriétés et contenu */
.properties-panel, .slot-contents, .stats-panel {
    background: var(--light-color);
    padding: 1rem;
    border-radius: var(--border-radius);
    min-height: 150px;
}

.no-selection {
    color: var(--gray);
    font-style: italic;
    text-align: center;
    margin-top: 2rem;
}

/* Statistiques */
.stat-item {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--gray-light);
}

.stat-item:last-child {
    border-bottom: none;
}

.stat-label {
    font-weight: 500;
}

.stat-value {
    font-weight: 600;
    color: var(--primary-color);
}

/* ===== ZONE CENTRALE (VUES) ===== */
.view-container {
    flex: 1;
    padding: 1.5rem;
    overflow: hidden;
    position: relative;
}

.view {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    height: 100%;
    display: none;
    flex-direction: column;
    overflow: hidden;
}

.view.active {
    display: flex;
}

.view-header {
    padding: 1.5rem;
    border-bottom: 2px solid var(--gray-light);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.view-header h2 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary-dark);
}

.back-btn {
    cursor: pointer;
    color: var(--gray);
    transition: var(--transition);
    margin-right: 0.5rem;
}

.back-btn:hover {
    color: var(--primary-color);
    transform: translateX(-3px);
}

.view-actions {
    display: flex;
    gap: 0.5rem;
}

/* Canvas - Vue Plan */
.canvas-container {
    flex: 1;
    position: relative;
    overflow: auto;
    background: #f0f2f5;
    background-image:
        linear-gradient(rgba(0,0,0,0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0,0,0,0.05) 1px, transparent 1px);
    background-size: 40px 40px;
    border: 1px solid var(--gray-light);
    margin: 1.5rem;
    border-radius: var(--border-radius);
}

canvas {
    display: block;
    cursor: crosshair;
}

.canvas-overlay {
    position: absolute;
    top: 0;
    left: 0;
    pointer-events: auto;
}

.view-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--gray-light);
    display: flex;
    justify-content: space-between;
    background: var(--light-color);
    font-size: 0.9rem;
    color: var(--gray);
}

/* ===== VUE ÉTAGÈRE ===== */
.rack-container {
    flex: 1;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    overflow-y: auto;
}

.rack-level {
    background: var(--light-color);
    border: 2px solid var(--gray-light);
    border-radius: var(--border-radius);
    padding: 1rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
    cursor: pointer;
}

.rack-level:hover {
    border-color: var(--primary-color);
    transform: translateX(5px);
    box-shadow: var(--shadow);
}

.rack-level-header {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.level-number {
    background: var(--primary-color);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.2rem;
}

.level-info h4 {
    color: var(--dark-color);
    margin-bottom: 0.25rem;
}

.level-slots {
    font-size: 0.9rem;
    color: var(--gray);
}

.level-actions {
    display: flex;
    gap: 0.5rem;
}

/* VUE ÉTAGE */
.level-container {
    flex: 1;
    padding: 2rem;
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-content: flex-start;
    overflow-y: auto;
}

.slot-item {
    width: 120px;
    height: 120px;
    background: white;
    border: 2px solid var(--gray-light);
    border-radius: var(--border-radius);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    cursor: pointer;
    position: relative;
}

.slot-item:hover {
    border-color: var(--primary-color);
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.slot-item.occupied {
    border-color: var(--success-color);
    background: rgba(46, 204, 113, 0.1);
}

.slot-item.full {
    border-color: var(--danger-color);
    background: rgba(231, 76, 60, 0.1);
}

.slot-code {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-dark);
    margin-bottom: 0.5rem;
}

.slot-status {
    font-size: 0.8rem;
    padding: 0.25rem 0.5rem;
    border-radius: 20px;
    background: var(--gray-light);
    color: var(--gray);
}

.slot-item.occupied .slot-status {
    background: rgba(46, 204, 113, 0.2);
    color: var(--success-color);
}

/* Contrôles étage/étagère */
.rack-controls, .level-controls {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--gray-light);
    background: var(--light-color);
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
}

.control-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.control-group label {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--gray);
}

.form-control {
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--gray-light);
    border-radius: 4px;
    font-size: 1rem;
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.2);
}

/* États vides */
.empty-state {
    text-align: center;
    margin: auto;
    color: var(--gray);
}

.empty-state i {
    margin-bottom: 1rem;
    opacity: 0.5;
}

.empty-state p {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

/* ===== MODALS ===== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-overlay.active {
    display: flex;
}

.modal {
    background: white;
    border-radius: var(--border-radius);
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-header {
    padding: 1.5rem;
    border-bottom: 1px solid var(--gray-light);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    color: var(--primary-dark);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.8rem;
    cursor: pointer;
    color: var(--gray);
    transition: var(--transition);
}

.modal-close:hover {
    color: var(--danger-color);
    transform: scale(1.1);
}

.modal-body {
    padding: 1.5rem;
}

.modal-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--gray-light);
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--dark-color);
}

.form-row {
    display: flex;
    gap: 1rem;
}

.form-row .form-group {
    flex: 1;
}

/* ===== NOTIFICATIONS & LOADER ===== */
.notification {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: var(--success-color);
    color: white;
    padding: 1rem 1.5rem;
    border-radius: var(--border-radius);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    box-shadow: var(--shadow);
    z-index: 1001;
    transform: translateY(100px);
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.notification.show {
    transform: translateY(0);
    opacity: 1;
}

.loader-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1002;
}

.loader-overlay.active {
    display: flex;
}

.loader {
    text-align: center;
}

.loader-spinner {
    width: 50px;
    height: 50px;
    border: 5px solid var(--gray-light);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ===== ANIMATIONS ===== */
@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

.highlight {
    animation: blink 0.5s ease-in-out 3;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.pulse {
    animation: pulse 0.5s ease-in-out;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1200px) {
    .sidebar-left, .sidebar-right {
        width: 240px;
    }
}

@media (max-width: 992px) {
    .main-container {
        flex-direction: column;
    }

    .sidebar-left, .sidebar-right {
        width: 100%;
        height: auto;
        max-height: 200px;
    }

    .view-container {
        order: 2;
        height: calc(100vh - 290px);
    }
}

@media (max-width: 768px) {
    .main-header {
        flex-direction: column;
        gap: 1rem;
        padding: 1rem;
    }

    .header-center {
        margin: 0;
        max-width: 100%;
        width: 100%;
    }

    .view-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }

    .view-actions {
        align-self: flex-end;
    }
}

/* ===== CANVAS & ÉTAGÈRES SUR LE PLAN ===== */
.rack-on-plan {
    position: absolute !important;
    border: 2px solid white !important;
    border-radius: 6px !important;
    cursor: move !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: white !important;
    font-weight: bold !important;
    box-shadow: var(--shadow) !important;
    transition: transform 0.2s, box-shadow 0.2s !important;
    user-select: none !important;
    z-index: 1 !important;
    font-size: 14px !important;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5) !important;
}

.rack-on-plan:hover {
    box-shadow: 0 6px 12px rgba(0,0,0,0.2) !important;
    transform: translateY(-2px) !important;
    z-index: 10 !important;
}

.rack-on-plan.selected {
    border: 3px solid #ffeb3b !important;
    box-shadow: 0 0 0 3px rgba(255, 235, 59, 0.3), 0 6px 12px rgba(0,0,0,0.2) !important;
    z-index: 100 !important;
}

.rack-on-plan .rack-handle {
    position: absolute;
    width: 12px;
    height: 12px;
    background: white;
    border: 2px solid #333;
    border-radius: 50%;
    cursor: pointer;
}

.rack-on-plan .handle-nw {
    top: -6px;
    left: -6px;
    cursor: nw-resize;
}

.rack-on-plan .handle-ne {
    top: -6px;
    right: -6px;
    cursor: ne-resize;
}

.rack-on-plan .handle-sw {
    bottom: -6px;
    left: -6px;
    cursor: sw-resize;
}

.rack-on-plan .handle-se {
    bottom: -6px;
    right: -6px;
    cursor: se-resize;
}

.rack-on-plan .rotate-handle {
    position: absolute;
    top: -30px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 20px;
    background: #4a90e2;
    border: 2px solid white;
    border-radius: 50%;
    cursor: grab;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 12px;
}

.rack-on-plan .rotate-handle:active {
    cursor: grabbing;
}

.rack-dimensions {
    position: absolute;
    bottom: 4px;
    right: 4px;
    font-size: 10px !important;
    background: rgba(0,0,0,0.5);
    padding: 1px 4px;
    border-radius: 2px;
}

/* Grille magnétique */
.grid-dot {
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(0,0,0,0.1);
    border-radius: 50%;
    pointer-events: none;
}

/* Zone de sélection */
.selection-rect {
    position: absolute;
    border: 2px dashed #4a90e2;
    background: rgba(74, 144, 226, 0.1);
    pointer-events: none;
    z-index: 1000;
}

/* Indicateur de position */
.position-marker {
    position: absolute;
    width: 10px;
    height: 10px;
    background: #e74c3c;
    border: 2px solid white;
    border-radius: 50%;
    pointer-events: none;
    z-index: 1000;
}

.rack-handle, .rotate-handle { pointer-events: all; }

.rack-on-plan {
    position: absolute !important;
    border: 2px solid #333 !important;
    border-radius: 4px !important;
    box-sizing: border-box !important;
    transition: transform 0.1s ease !important;
    user-select: none !important;
}

.rack-on-plan.selected {
    border-color: #007bff !important;
    border-width: 3px !important;
    box-shadow: 0 0 10px rgba(0, 123, 255, 0.5) !important;
}

.rack-handle {
    position: absolute !important;
    width: 12px !important;
    height: 12px !important;
    background-color: #fff !important;
    border: 2px solid #007bff !important;
    border-radius: 2px !important;
    z-index: 20 !important;
}

.rotate-handle {
    position: absolute !important;
    top: -25px !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    width: 20px !important;
    height: 20px !important;
    background-color: #fff !important;
    border: 2px solid #007bff !important;
    border-radius: 50% !important;
    cursor: grab !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 12px !important;
    z-index: 20 !important;
}

.rack-dimensions {
    position: absolute !important;
    bottom: -25px !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    font-size: 12px !important;
    color: #666 !important;
    background-color: rgba(255, 255, 255, 0.8) !important;
    padding: 2px 6px !important;
    border-radius: 3px !important;
    z-index: 15 !important;
}

/* vuestock.css - AJOUTEZ à la fin du fichier */

/* ===== VUE QUAD-SPLIT ===== */
.quad-split-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: 10px;
    height: 100%;
    padding: 1.5rem;
    background: #f0f2f5;
}

.quad-view {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    position: relative;
    border: 1px solid var(--gray-light);
}

.quad-view-header {
    padding: 0.75rem 1rem;
    background: var(--light-color);
    border-bottom: 1px solid var(--gray-light);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--primary-dark);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.quad-view-content {
    position: relative;
    height: calc(100% - 45px);
    overflow: auto;
}

/* Canvas spécifiques pour chaque vue */
.quad-canvas {
    width: 100%;
    height: 100%;
    background: #f8f9fa;
}

/* Vue du haut */
.view-top {
    /* Utilise le canvas existant */
}

/* Vue de face */
.view-front {
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 39px,
        rgba(0,0,0,0.05) 39px,
        rgba(0,0,0,0.05) 40px
    );
}

/* Vue 3D isométrique */
/* Vue 3D isométrique */
.view-3d {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    position: relative;
    overflow: hidden;
}

/* Animation de fond pour la vue 3D */
.view-3d::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    animation: rotate3DBg 20s linear infinite;
    pointer-events: none;
}

@keyframes rotate3DBg {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Canvas 3D avec curseur interactif */
.view-3d .quad-canvas {
    cursor: grab;
    transition: filter 0.3s ease, transform 0.3s ease;
    position: relative;
    z-index: 1;
}

.view-3d .quad-canvas:active {
    cursor: grabbing;
}

/* Effet de glow quand on survole */
.view-3d:hover .quad-canvas {
    filter: brightness(1.1);
}

/* Animation pulse subtile pour attirer l'attention */
@keyframes canvas3DPulse {
    0%, 100% {
        box-shadow: inset 0 0 20px rgba(0, 255, 255, 0.1);
    }
    50% {
        box-shadow: inset 0 0 30px rgba(0, 255, 255, 0.2);
    }
}

.view-3d .quad-canvas {
    animation: canvas3DPulse 4s ease-in-out infinite;
}

/* Vue étage */
.view-level {
    display: flex;
    flex-direction: column;
}

.level-slots-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 15px;
    align-content: flex-start;
}

.quad-slot {
    width: 100px !important;  /* Augmenté de 80px */
    height: 100px !important; /* Augmenté de 80px */
    background: white;
    border: 2px solid var(--gray-light);
    border-radius: 6px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.quad-slot:hover {
    border-color: var(--primary-color);
    transform: scale(1.05);
}

.quad-slot.occupied {
    border-color: var(--success-color);
    background: rgba(46, 204, 113, 0.1);
}

.quad-slot.full {
    border-color: var(--danger-color);
    background: rgba(231, 76, 60, 0.1);
}

.quad-slot-code {
    font-size: 0.9rem;
    font-weight: bold;
    color: var(--primary-dark);
}

.quad-slot-status {
    font-size: 0.7rem;
    padding: 1px 4px;
    border-radius: 3px;
    background: var(--gray-light);
    color: var(--gray);
}

/* Contrôles de vue */
.view-switch-container {
    display: flex;
    gap: 10px;
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--gray-light);
    background: white;
}

.view-switch-btn {
    padding: 0.5rem 1rem;
    border: 1px solid var(--gray-light);
    background: white;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: var(--transition);
}

.view-switch-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.view-switch-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* Styles pour le panneau Propriétés Quad */
.property-group {
    margin-bottom: 1rem;
}

.property {
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.property-label {
    font-weight: 500;
    color: var(--dark-color);
    font-size: 0.9rem;
    min-width: 80px;
}

.property-input, .coord-input, .dim-input, .property-color {
    padding: 0.25rem 0.5rem;
    border: 1px solid var(--gray-light);
    border-radius: 4px;
    font-size: 0.9rem;
    width: 120px;
}

.property-input:focus, .coord-input:focus, .dim-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(74, 144, 226, 0.2);
}

.property-coords, .property-dimensions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.coord-input, .dim-input {
    width: 50px;
    text-align: center;
}

.property-rotation {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex: 1;
}

.rotation-slider {
    flex: 1;
    height: 6px;
    border-radius: 3px;
    background: var(--gray-light);
    outline: none;
    -webkit-appearance: none;
}

.rotation-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
}

.rotation-value {
    min-width: 40px;
    text-align: center;
    font-weight: 600;
    color: var(--primary-color);
}

.property-value {
    font-weight: 600;
    color: var(--primary-color);
}

.property-actions {
    margin-top: 1.5rem;
    border-top: 1px solid var(--gray-light);
    padding-top: 1rem;
}

.action-buttons {
    display: flex;
    gap: 0.5rem;
    margin: 0.75rem 0;
    justify-content: center;
}

.action-buttons .btn {
    padding: 0.5rem;
    min-width: 40px;
}

.btn-block {
    display: block;
    width: 100%;
    margin-bottom: 0.5rem;
}

/* ===== TIRROIR RÉALISTE POUR LES SLOTS ===== */
#quadLevelSlots {
    overflow: hidden;
    position: relative;
    height: 100%;
}

/* Conteneur principal du tiroir */
.quad-drawer-container {
    height: 100%;
    display: flex;
    flex-direction: column;
    perspective: 1200px;
}

/* Panneau avant du tiroir (la face) */
.drawer-front {
    background: linear-gradient(135deg, #8B7355 0%, #6B5B4D 100%);
    border: 3px solid #5D4C3A;
    border-radius: 12px 12px 0 0;
    padding: 10px 15px;
    color: white;
    font-weight: bold;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.3);
    position: relative;
    z-index: 2;
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 40px;
}

/* Poignée du tiroir */
.drawer-handle {
    width: 60px;
    height: 10px;
    background: #FFD700;
    border: 2px solid #B8860B;
    border-radius: 5px;
    margin: 0 auto 5px;
    position: relative;
    cursor: pointer;
    transition: transform 0.2s;
}

.drawer-handle:hover {
    transform: scale(1.05);
}

.drawer-handle::before {
    content: '━━━━';
    position: absolute;
    top: -2px;
    left: 50%;
    transform: translateX(-50%);
    color: #B8860B;
    font-size: 16px;
    line-height: 1;
}

.drawer-body {
    background: linear-gradient(135deg, #F5DEB3 0%, #E6D3A3 100%);
    border: 3px solid #5D4C3A;
    border-top: none;
    border-radius: 0 0 12px 12px;
    flex: 1;
    padding: 15px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.2);

    transform: translateY(-100%);
    opacity: 0;

    /* MÊME TEMPS OUVERTURE/FERMETURE */
    transition:
        transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94),
        opacity 0.5s ease,
        max-height 0.7s ease; /* AJOUTER max-height */

    position: relative;
    z-index: 1;
    overflow-y: auto;
    max-height: 0;
}

/* État ouvert */
.quad-drawer-container.open .drawer-body {
    transform: translateY(0);
    opacity: 1;
    max-height: 250px; /* MOINS HAUT : 300px au lieu de 400px */
}

/* Intérieur du tiroir avec texture bois */
.drawer-interior {
    background: repeating-linear-gradient(
        90deg,
        transparent,
        transparent 19px,
        rgba(139, 115, 85, 0.1) 19px,
        rgba(139, 115, 85, 0.1) 20px
    );
    height: 100%;
    border-radius: 6px;
    border: 2px solid #D2B48C;
    padding: 15px;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
    gap: 10px;
    align-content: start;
    position: relative;
    overflow: visible;
}

/* Glissières latérales */
.drawer-body::before,
.drawer-body::after {
    content: '';
    position: absolute;
    top: 0;
    width: 6px;
    height: 80%;
    background: linear-gradient(to bottom, #A0522D, #8B4513);
    z-index: 2;
    transition: height 0.7s ease;
}

.drawer-body::before {
    left: -9px;
    border-radius: 3px 0 0 3px;
}

.drawer-body::after {
    right: -9px;
    border-radius: 0 3px 3px 0;
}

/* Slots dans le tiroir */
.quad-slot {
    width: 100%;
    aspect-ratio: 1;
    background: linear-gradient(135deg, #FFF8DC 0%, #FAEBD7 100%);
    border: 2px solid #DEB887;
    border-radius: 6px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;

    /* RALENTI ICI AUSSI */
    transition: all 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);

    position: relative;
    overflow: hidden;
    box-shadow:
        inset 0 1px 2px rgba(255,255,255,0.8),
        0 3px 6px rgba(0,0,0,0.1);
    transform: translateY(20px) scale(0.9);
    opacity: 0;
}

/* Animation d'apparition progressive - RALENTIE */
.quad-drawer-container.open .quad-slot {
    transform: translateY(0) scale(1);
    opacity: 1;
}

/* Délais d'apparition RALENTIS */
.quad-drawer-container.open .quad-slot:nth-child(1) { transition-delay: 0.2s; }
.quad-drawer-container.open .quad-slot:nth-child(2) { transition-delay: 0.25s; }
.quad-drawer-container.open .quad-slot:nth-child(3) { transition-delay: 0.3s; }
.quad-drawer-container.open .quad-slot:nth-child(4) { transition-delay: 0.35s; }
.quad-drawer-container.open .quad-slot:nth-child(5) { transition-delay: 0.4s; }
.quad-drawer-container.open .quad-slot:nth-child(6) { transition-delay: 0.45s; }
.quad-drawer-container.open .quad-slot:nth-child(7) { transition-delay: 0.5s; }
.quad-drawer-container.open .quad-slot:nth-child(8) { transition-delay: 0.55s; }
.quad-drawer-container.open .quad-slot:nth-child(9) { transition-delay: 0.6s; }
.quad-drawer-container.open .quad-slot:nth-child(10) { transition-delay: 0.65s; }

/* Effet au survol */
.quad-slot:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow:
        inset 0 1px 2px rgba(255,255,255,0.9),
        0 6px 12px rgba(0,0,0,0.2);
    z-index: 10;
    border-color: #CD853F;
}

/* Slots occupés */
.quad-slot.occupied {
    background: linear-gradient(135deg, #D4EDDA 0%, #C3E6CB 100%);
    border-color: #28a745;
}

.quad-slot.occupied::before {
    content: '📦';
    position: absolute;
    top: 5px;
    right: 5px;
    font-size: 12px;
    opacity: 0.7;
}

.quad-slot.full {
    background: linear-gradient(135deg, #F8D7DA 0%, #F5C6CB 100%);
    border-color: #dc3545;
}

.quad-slot.full::before {
    content: '⚠️';
    position: absolute;
    top: 5px;
    right: 5px;
    font-size: 12px;
}

/* Code du slot */
.quad-slot-code {
    font-family: 'Courier New', monospace;
    font-size: 1rem;
    font-weight: bold;
    color: #5D4037;
    text-shadow: 0 1px 1px rgba(255,255,255,0.5);
    margin-bottom: 4px;
}

/* Statut */
.quad-slot-status {
    font-size: 0.7rem;
    padding: 2px 6px;
    border-radius: 10px;
    background: rgba(255,255,255,0.8);
    color: #5D4037;
    font-weight: 500;
    border: 1px solid rgba(0,0,0,0.1);
}

/* Indicateur de sélection */
.quad-slot.selected {
    border: 3px solid #007bff;
    box-shadow:
        0 0 0 3px rgba(0, 123, 255, 0.3),
        inset 0 1px 2px rgba(255,255,255,0.9),
        0 6px 12px rgba(0,0,0,0.2);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        box-shadow:
            0 0 0 3px rgba(0, 123, 255, 0.3),
            inset 0 1px 2px rgba(255,255,255,0.9),
            0 6px 12px rgba(0,0,0,0.2);
    }
    50% {
        box-shadow:
            0 0 0 5px rgba(0, 123, 255, 0.5),
            inset 0 1px 2px rgba(255,255,255,0.9),
            0 6px 12px rgba(0,0,0,0.2);
    }
}

/* État vide du tiroir */
.quad-drawer-container.empty .drawer-interior {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 150px;
}

.empty-drawer-message {
    text-align: center;
    color: #8B7355;
    font-style: italic;
    padding: 20px;
}

.empty-drawer-message i {
    font-size: 2rem;
    margin-bottom: 10px;
    opacity: 0.5;
}

/* Animation de l'étiquette de l'étage */
.drawer-front .level-label {
    display: inline-block;
    padding: 5px 15px;
    background: rgba(255,255,255,0.1);
    border-radius: 20px;
    border: 1px solid rgba(255,255,255,0.2);
    margin-top: 5px;
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 768px) {
    .drawer-interior {
        grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
        gap: 8px;
        padding: 10px;
    }

    .quad-slot-code {
        font-size: 0.9rem;
    }
}

/* Ajustement automatique des slots selon le nombre */
.drawer-interior {
    background: repeating-linear-gradient(
        90deg,
        transparent,
        transparent 19px,
        rgba(139, 115, 85, 0.1) 19px,
        rgba(139, 115, 85, 0.1) 20px
    );
    height: 100%;
    border-radius: 6px;
    border: 2px solid #D2B48C;
    padding: 15px;

    /* CHANGEMENT : Pas de scroll horizontal */
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-content: flex-start;
    justify-content: center; /* Centrer les slots */

    position: relative;
    overflow-y: auto; /* Scroll vertical seulement */
    overflow-x: hidden; /* Pas de scroll horizontal */
}

/* Ajustement taille des slots selon le nombre */
.drawer-interior:has(.quad-slot:nth-child(1)):has(.quad-slot:nth-child(15)) {
    /* Si plus de 14 slots -> taille réduite */
    grid-template-columns: repeat(auto-fill, minmax(50px, 1fr));
}

.drawer-interior:has(.quad-slot:nth-child(1)):has(.quad-slot:nth-child(10)):not(:has(.quad-slot:nth-child(15))) {
    /* Si 10-14 slots -> taille moyenne */
    grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
}

.drawer-interior:has(.quad-slot:nth-child(1)):not(:has(.quad-slot:nth-child(10))) {
    /* Si moins de 10 slots -> grande taille */
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
}

/* Taille des slots adaptative */
.quad-slot {
    width: 80px; /* Taille par défaut */
    height: 80px;
    background: linear-gradient(135deg, #FFF8DC 0%, #FAEBD7 100%);
    border: 2px solid #DEB887;
    border-radius: 6px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;

    transition: all 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);

    position: relative;
    overflow: hidden;
    box-shadow:
        inset 0 1px 2px rgba(255,255,255,0.8),
        0 3px 6px rgba(0,0,0,0.1);
    transform: translateY(20px) scale(0.9);
    opacity: 0;

    /* CHANGEMENT : Scale selon le nombre */
    flex: 0 0 auto; /* Pas de stretching */
}

/* Ajustement JavaScript pour le zoom */
.generateSlotElements(slots) {
    if (!slots || slots.length === 0) {
        return `
            <div class="empty-drawer-message">
                <i class="fas fa-box-open"></i>
                <p>Tiroir vide</p>
            </div>
        `;
    }

    // Trier les emplacements par code
    const sortedSlots = [...slots].sort((a, b) => {
        return parseInt(a.code) - parseInt(b.code);
    });

    let html = '';

    // Calculer la classe de zoom selon le nombre de slots
    const slotCount = sortedSlots.length;
    let zoomClass = 'zoom-large';
    if (slotCount > 14) zoomClass = 'zoom-small';
    else if (slotCount > 9) zoomClass = 'zoom-medium';

    sortedSlots.forEach(slot => {
        html += `
            <div class="quad-slot ${zoomClass} ${slot.status !== 'free' ? 'occupied' : ''}"
                 data-slot-id="${slot.id}"
                 title="Emplacement ${slot.code} - ${slot.status === 'free' ? 'Libre' : 'Occupé'}">
                <div class="quad-slot-code">${slot.code}</div>
                <div class="quad-slot-status">${slot.status === 'free' ? 'Libre' : 'Occupé'}</div>
            </div>
        `;
    });

    return html;
}

/* Classes de zoom */
.zoom-small {
    transform: scale(0.8) !important;
    width: 60px !important;
    height: 60px !important;
}

.zoom-medium {
    transform: scale(0.9) !important;
    width: 70px !important;
    height: 70px !important;
}

.zoom-large {
    transform: scale(1) !important;
    width: 80px !important;
    height: 80px !important;
}

/* Ajustement du code et statut selon le zoom */
.zoom-small .quad-slot-code {
    font-size: 0.8rem !important;
}

.zoom-small .quad-slot-status {
    font-size: 0.6rem !important;
    padding: 1px 4px !important;
}

/* Assurer que les slots tiennent dans le tiroir */
.drawer-interior {
    max-height: 280px; /* Moins que le 300px du drawer-body */
}

/* Contenu des slots avec articles */
.slot-content {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 5px;
}

/* Image de l'article */
.slot-article-image {
    width: 60px !important;   /* Augmenté de 40px */
    height: 60px !important;  /* Augmenté de 40px */
    margin-bottom: 8px;       /* Augmenté de 5px */
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: 4px;
    border: 1px solid rgba(0,0,0,0.1);
    background: white;
}

.slot-article-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Info article */
.slot-article-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.slot-code-small {
    font-size: 0.7rem;
    font-weight: bold;
    color: #5D4037;
    background: rgba(255,255,255,0.8);
    padding: 1px 4px;
    border-radius: 3px;
}

.article-quantity {
    font-size: 1rem !important;  /* Augmenté de 0.8rem */
    min-width: 28px !important;  /* Augmenté de 24px */
    padding: 3px 8px !important; /* Augmenté de 2px 6px */
    font-weight: bold;
    color: #28a745;
    background: rgba(40, 167, 69, 0.1);
    border-radius: 10px;
    text-align: center;
}

/* Ajustement pour les petits slots */
/* Ajuster les petits slots */
.zoom-small .quad-slot {
    width: 80px !important;
    height: 80px !important;
}

.zoom-small .slot-article-image {
    width: 45px !important;
    height: 45px !important;
}

.zoom-small .slot-code-small {
    font-size: 0.6rem;
}

.zoom-small .article-quantity {
    font-size: 0.7rem;
    padding: 1px 4px;
}

/* Ajuster les slots moyens */
.zoom-medium .quad-slot {
    width: 90px !important;
    height: 90px !important;
}

.zoom-medium .slot-article-image {
    width: 50px !important;
    height: 50px !important;
}

/* Slots occupés - couleur différente selon la quantité */
.quad-slot.occupied.low-stock {
    border-color: #ffc107;
    background: linear-gradient(135deg, #FFF3CD 0%, #FFEAA7 100%);
}

.quad-slot.occupied.medium-stock {
    border-color: #28a745;
    background: linear-gradient(135deg, #D4EDDA 0%, #C3E6CB 100%);
}

.quad-slot.occupied.high-stock {
    border-color: #007bff;
    background: linear-gradient(135deg, #CCE5FF 0%, #B3D7FF 100%);
}

/* Animation au survol */
.quad-slot.occupied:hover .slot-article-image {
    transform: scale(1.1);
    transition: transform 0.2s ease;
}

/* Option : Ajouter une classe pour déterminer le niveau de stock */
function getStockLevel(stock) {
    if (!stock || stock === 0) return '';
    if (stock <= 10) return 'low-stock';
    if (stock <= 50) return 'medium-stock';
    return 'high-stock';
}

/* Couleurs selon le niveau de stock */
.quad-slot.occupied.stock-good {
    /* Stock > stock_minimum - VERT */
    border-color: #28a745 !important;
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%) !important;
}

.quad-slot.occupied.stock-low {
    /* 1 <= stock <= stock_minimum - ORANGE */
    border-color: #fd7e14 !important;
    background: linear-gradient(135deg, #ffe5d0 0%, #ffd8b2 100%) !important;
}

.quad-slot.occupied.stock-zero {
    /* stock = 0 - ROUGE */
    border-color: #dc3545 !important;
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%) !important;
}

/* Indicateur visuel supplémentaire */
.quad-slot.occupied.stock-zero::before {
    content: '⛔';
    position: absolute;
    top: 2px;
    right: 2px;
    font-size: 10px;
    opacity: 0.8;
}

.quad-slot.occupied.stock-low::before {
    content: '⚠️';
    position: absolute;
    top: 2px;
    right: 2px;
    font-size: 10px;
    opacity: 0.8;
}

/* Couleur de la quantité selon le stock */
.stock-good .article-quantity {
    color: #28a745;
    background: rgba(40, 167, 69, 0.15);
}

.stock-low .article-quantity {
    color: #fd7e14;
    background: rgba(253, 126, 20, 0.15);
}

.stock-zero .article-quantity {
    color: #dc3545;
    background: rgba(220, 53, 69, 0.15);
}

/* Image avec overlay pour stock faible/zéro */
.stock-low .slot-article-image,
.stock-zero .slot-article-image {
    opacity: 0.8;
    filter: grayscale(30%);
}

/* Animation pulse pour stock faible */
@keyframes pulse-warning {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.stock-low {
    animation: pulse-warning 2s infinite;
}

/* Animation pour stock zéro */
@keyframes blink-alert {
    0%, 100% { border-width: 2px; }
    50% { border-width: 3px; }
}

.stock-zero {
    animation: blink-alert 1.5s infinite;
}

/* Modal Édition Stock */
.stock-edit-container {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.article-photo-large {
    width: 150px;
    height: 150px;
    border-radius: 8px;
    overflow: hidden;
    border: 2px solid var(--gray-light);
    flex-shrink: 0;
}

.article-photo-large img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.article-info {
    flex: 1;
}

.article-info h4 {
    margin-bottom: 15px;
    color: var(--primary-dark);
    font-size: 1.2rem;
}

.article-details {
    background: var(--light-color);
    padding: 15px;
    border-radius: var(--border-radius);
    margin-bottom: 20px;
}

.detail-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--gray-light);
}

.detail-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.detail-label {
    font-weight: 500;
    color: var(--gray);
}

.detail-value {
    font-weight: 600;
    color: var(--dark-color);
}

.stock-edit-controls {
    background: white;
    padding: 20px;
    border-radius: var(--border-radius);
    border: 1px solid var(--gray-light);
}

.quantity-controls {
    display: flex;
    gap: 10px;
    align-items: center;
    margin: 15px 0;
}

#modalStockInput {
    text-align: center;
    font-size: 1.5rem;
    font-weight: bold;
    padding: 10px;
    width: 120px;
}

.quantity-controls .btn {
    width: 50px;
    height: 50px;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Contrôles 3D améliorés */
.quad-3d-controls {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.5);
    padding: 10px 15px;
    border-radius: 25px;
    backdrop-filter: blur(10px);
    display: flex;
    gap: 10px;
    z-index: 10;
}

.quad-3d-btn {
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    padding: 8px 12px;
    border-radius: 15px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 5px;
}

.quad-3d-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.quad-3d-btn:active {
    transform: translateY(0);
}

.quad-3d-btn i {
    font-size: 1rem;
}

/* Bouton Reset spécial */
#quad3DReset {
    background: rgba(231, 76, 60, 0.3);
    border-color: rgba(231, 76, 60, 0.5);
}

#quad3DReset:hover {
    background: rgba(231, 76, 60, 0.5);
}

/* ===== EFFETS RAYONS X ET ZOOM ===== */

/* Indicateur visuel quand un rack est survolé (rayons X) */
.view-3d.xray-active .quad-canvas {
    filter: brightness(1.2) contrast(1.1);
    box-shadow: inset 0 0 50px rgba(0, 255, 255, 0.3);
}

/* Indicateur visuel quand un rack est en zoom */
.view-3d.zoom-active .quad-canvas {
    transform: scale(1.02);
    box-shadow: 0 0 30px rgba(102, 126, 234, 0.5);
}

/* Info-bulle au survol */
.rack-3d-tooltip {
    position: absolute;
    background: rgba(0, 0, 0, 0.9);
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 12px;
    pointer-events: none;
    z-index: 1000;
    transform: translate(-50%, -100%);
    margin-top: -10px;
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.3s ease;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.rack-3d-tooltip.visible {
    opacity: 1;
}

.rack-3d-tooltip::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-top: 6px solid rgba(0, 0, 0, 0.9);
}

/* Animation pour le texte "Cliquez pour zoomer" */
@keyframes floatHint {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-5px);
    }
}

.zoom-hint {
    position: absolute;
    bottom: 60px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 11px;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    animation: floatHint 2s ease-in-out infinite;
    backdrop-filter: blur(5px);
}

.zoom-hint.visible {
    opacity: 1;
}

/* Dans votre fichier CSS */
.stat-item:nth-child(4) .stat-value {
    font-weight: bold;
    transition: color 0.3s ease;
}

.occupation-low {
    color: #2ecc71 !important; /* Vert pour faible occupation */
}

.occupation-medium {
    color: #f39c12 !important; /* Orange pour occupation moyenne */
}

.occupation-high {
    color: #e74c3c !important; /* Rouge pour forte occupation */
}