/* WMS — compléments Duralux (ne pas écraser le thème) */

/* Feather — WOFF uniquement (évite l'avertissement Firefox "Glyph bbox" sur feather.ttf) */
@font-face {
    font-family: feather;
    src: url('../../theme/vendors/fonts/feather.woff?oz8w89') format('woff');
    font-weight: 400;
    font-style: normal;
    font-display: block;
}

.scan-feedback.ok { background: #d1e7dd; }

.scan-feedback.err { background: #f8d7da; }

.card-menu { transition: transform 0.25s ease, box-shadow 0.25s ease; }

.card-menu:hover { transform: translateY(-4px); box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08); }

#adminToast .toast { min-width: 280px; }

#adminToast .wms-toast-feedback.text-bg-success,
#adminToast .wms-toast-feedback.text-bg-danger,
#adminToast .wms-toast-feedback.text-bg-primary,
#adminToast .wms-toast-feedback.text-bg-info,
#adminToast .wms-toast-feedback.text-bg-warning {
    color: #fff !important;
}

#adminToast .wms-toast-feedback .toast-body,
#adminToast .wms-toast-feedback .toast-body .fw-semibold {
    color: #fff !important;
}



/* Modals / offcanvas au-dessus du layout (overflow / flou) */

.modal-backdrop { z-index: 1050 !important; }

.modal { z-index: 1065 !important; }

.modal.show { z-index: 1065 !important; }

.offcanvas-backdrop { z-index: 1050 !important; }

.offcanvas { z-index: 1070 !important; }

.offcanvas.show { z-index: 1070 !important; }

body.modal-open .nxl-navigation,

body.modal-open .nxl-header,

body.modal-open .nxl-container,

body.offcanvas-open .nxl-navigation,

body.offcanvas-open .nxl-header,

body.offcanvas-open .nxl-container {

    filter: none !important;

    -webkit-filter: none !important;

}

.wms-quarantine-offcanvas {

    width: min(420px, 100vw);

}

.nxl-container,

.nxl-content,

.main-content,

.card.stretch .card-body {

    overflow: visible;

}

.table-responsive { overflow-x: auto; }



/* Tables style leads */

.wms-table thead tr th {

    font-size: 11px;

    font-weight: 700;

    text-transform: uppercase;

    letter-spacing: 0.04em;

    color: var(--bs-secondary-color);

    border-bottom-width: 1px;

    white-space: nowrap;

}

.wms-table tbody tr {

    transition: background-color 0.15s ease;

}

.wms-table .row-num {

    color: var(--bs-secondary-color);

    font-weight: 600;

    font-size: 12px;

    width: 48px;

}



/* Confirm modal animation */

.wms-confirm-modal .modal-content {

    animation: wmsModalIn 0.28s cubic-bezier(0.22, 1, 0.36, 1);

}

@keyframes wmsModalIn {

    from { transform: scale(0.9) translateY(8px); opacity: 0; }

    to { transform: scale(1) translateY(0); opacity: 1; }

}

.wms-confirm-pop {

    animation: wmsIconPop 0.35s cubic-bezier(0.22, 1, 0.36, 1) 0.05s both;

}

@keyframes wmsIconPop {

    from { transform: scale(0.6); opacity: 0; }

    to { transform: scale(1); opacity: 1; }

}

.wms-table tbody td { vertical-align: middle; }
.wms-table .row-num { width: 48px; text-align: center; }
table.dataTable.wms-table thead th { border-bottom: 1px solid var(--bs-border-color); }
.dataTables_wrapper .dataTables_filter input,
.dataTables_wrapper .dataTables_length select {
    border-radius: 0.375rem;
    border: 1px solid var(--bs-border-color);
    padding: 0.35rem 0.65rem;
}
.dataTables_wrapper .dataTables_paginate .paginate_button.current {
    background: var(--bs-primary) !important;
    border-color: var(--bs-primary) !important;
    color: #fff !important;
}
.apps-email .single-items {
    cursor: pointer;
    border-bottom: 1px solid var(--bs-border-color);
    transition: background 0.15s ease;
}
.apps-email #msgList {
    overflow-y: auto;
    max-height: calc(100vh - 12rem);
    min-height: 320px;
    background: #fff;
}
.apps-email .content-area-body {
    min-height: calc(100vh - 12rem);
}
.apps-email .msg-detail-body img {
    max-width: 100%;
    height: auto;
}
.apps-email .single-items:hover,
.apps-email .single-items.active { background: rgba(var(--bs-primary-rgb), 0.06); }
.apps-email .single-items.unread { background: rgba(var(--bs-primary-rgb), 0.03); }
.apps-email .content-sidebar .nav-link.active { color: var(--bs-primary); font-weight: 600; }

.wms-stat-card { transition: transform 0.2s ease, box-shadow 0.2s ease; border-radius: 0.75rem; }
.wms-stat-card:hover { transform: translateY(-4px); box-shadow: 0 12px 28px rgba(0,0,0,0.12) !important; }
.bg-teal { background-color: #20c997 !important; }
.bg-indigo { background-color: #6610f2 !important; }
.wms-signature-pad { border: 2px dashed var(--bs-border-color); border-radius: 0.5rem; height: 200px; touch-action: none; background: #fff; }
.min-h-120 { min-height: 120px; }

/* Operations cards — dégradés */
.wms-op-card {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: 1.5rem 1.75rem;
    min-height: 130px;
    border-radius: 1rem;
    color: #fff;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.14);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.wms-op-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 18px 36px rgba(0, 0, 0, 0.2);
    color: #fff;
}
.wms-op-card__icon {
    width: 72px;
    height: 72px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.22);
    font-size: 2rem;
    line-height: 1;
    color: #fff !important;
}
.wms-op-card__icon i,
.wms-op-card__icon svg {
    color: #fff !important;
    stroke: #fff !important;
}
.wms-op-card__body h4 { font-size: 1.35rem; }
.wms-op-card__body p { font-size: 0.85rem; }
.wms-op-card--entries { background: linear-gradient(135deg, #0b3d7a 0%, #1565c0 100%); }
.wms-op-card--exits { background: linear-gradient(135deg, #0d47a1 0%, #1976d2 100%); }
.wms-op-card--requests { background: linear-gradient(135deg, #1565c0 0%, #2196f3 100%); }
.wms-op-card--products { background: linear-gradient(135deg, #1976d2 0%, #42a5f5 100%); }
.wms-op-card--transfers { background: linear-gradient(135deg, #1e88e5 0%, #64b5f6 100%); }
.wms-op-card--inventories { background: linear-gradient(135deg, #2196f3 0%, #90caf9 100%); }
.wms-op-card--scan { background: linear-gradient(135deg, #0b3d7a 0%, #64b5f6 100%); }
.wms-op-card--quarantine { background: linear-gradient(135deg, #e65100 0%, #ffb74d 100%); }
.wms-op-card--reports { background: linear-gradient(135deg, #0d47a1 0%, #42a5f5 100%); }
.wms-op-card--client-exit { background: linear-gradient(135deg, #0b3d7a 0%, #2196f3 100%); }
.wms-op-card--consignations { background: linear-gradient(135deg, #0d47a1 0%, #42a5f5 100%); }
.wms-op-card--profile { background: linear-gradient(135deg, #1e88e5 0%, #81d4fa 100%); }
.wms-op-card--security { background: linear-gradient(135deg, #1976d2 0%, #90caf9 100%); }
.wms-op-card--discussions { background: linear-gradient(135deg, #1565c0 0%, #64b5f6 100%); }
.wms-op-card--imports { background: linear-gradient(135deg, #0b3d7a 0%, #42a5f5 100%); }
.wms-op-section-divider {
    border: 0;
    border-top: 1px solid rgba(var(--bs-primary-rgb), 0.12);
    opacity: 1;
}
.wms-op-card--compact {
    min-height: 92px;
    padding: 1rem 1.15rem;
    gap: 0.85rem;
    border-radius: 0.85rem;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.1);
}
.wms-op-card--compact:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.14);
}
.wms-op-card--compact .wms-op-card__icon {
    width: 46px;
    height: 46px;
    font-size: 1.25rem;
}
.wms-op-card--compact .wms-op-card__body h4 { font-size: 1.05rem; }
.wms-op-card--compact .wms-op-card__body p { font-size: 0.72rem; margin-top: 0.15rem; }
.wms-op-card__notif-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 2;
    min-width: 1.35rem;
    height: 1.35rem;
    padding: 0 0.35rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: #dc3545;
    color: #fff;
    font-size: 0.68rem;
    font-weight: 700;
    line-height: 1;
    border: 2px solid rgba(255, 255, 255, 0.95);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
}
.letter-spacing-1 { letter-spacing: 0.06em; }

/* Import CSV hub — type tabs (avoid card-header-tabs overlap with pane content) */
.wms-import-hub-tabs {
    position: relative;
    z-index: 3;
    gap: 0.15rem;
}
.wms-import-hub-tabs .nav-link {
    cursor: pointer;
}
.wms-import-tab-content > .tab-pane:not(.active):not(.show) {
    display: none !important;
}

/* Import CSV wizard */
.wms-import-steps .wms-import-step {
    display: inline-block;
    font-size: 0.75rem;
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    color: var(--bs-secondary);
    background: rgba(0, 0, 0, 0.04);
    margin-right: 0.35rem;
    cursor: default;
}
.wms-import-steps .wms-import-step.active {
    background: var(--wms-blue-700, #1976d2);
    color: #fff;
}
.wms-import-steps .wms-import-step.wms-step-locked:not(.active) {
    opacity: 0.45;
}
.wms-import-preview-table tr.wms-import-row--ok td { background: rgba(25, 135, 84, 0.06); }
.wms-import-preview-table tr.wms-import-row--error td { background: rgba(220, 53, 69, 0.06); }

.wms-theme .client-discussion-card .card-header {
    border-bottom: 1px dashed rgba(25, 118, 210, 0.15);
}
.wms-theme .client-discussion-list .list-group-item {
    border-style: dashed;
    border-color: rgba(25, 118, 210, 0.12);
    padding: 0;
}
.wms-theme .client-discussion-item-link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    text-decoration: none;
    color: inherit;
}
.wms-theme .client-discussion-item-link:hover {
    background: rgba(25, 118, 210, 0.04);
}
.wms-theme .client-discussion-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 700;
    font-size: 0.875rem;
    flex-shrink: 0;
}
.wms-theme .client-discussion-body { flex: 1; min-width: 0; }
.wms-theme .client-discussion-title-row {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    align-items: baseline;
}
.wms-theme .client-discussion-title { font-weight: 600; color: #1a237e; }
.wms-theme .client-discussion-time { font-size: 0.6875rem; color: #90a4ae; white-space: nowrap; }
.wms-theme .client-discussion-preview {
    display: block;
    font-size: 0.8125rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.wms-theme .client-discussion-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
    flex-shrink: 0;
}
.wms-theme .client-discussion-messages {
    overflow-y: auto;
    max-height: 420px;
    padding: 16px;
    background: #fafbfd;
}
.wms-theme .client-discussion-message {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
}
.wms-theme .client-discussion-message-head {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    align-items: center;
    margin-bottom: 4px;
}
.wms-theme .client-discussion-message-text { font-size: 0.875rem; line-height: 1.45; }
.wms-theme .client-discussion-link-btn {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 12px;
    border: 0;
    background: transparent;
    text-align: left;
    padding: 10px 0;
}
.wms-theme .client-discussion-link-btn:hover { opacity: 0.85; }
.wms-theme .client-discussion-link-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.wms-theme .client-discussion-link-text { flex: 1; min-width: 0; }
.wms-theme .client-link-preview-card {
    display: flex;
    gap: 16px;
    align-items: flex-start;
}
.wms-theme .client-link-preview-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}
.wms-theme .client-discussion-profile-avatar,
#discussionProfileAvatar.client-discussion-profile-avatar {
    width: 72px;
    height: 72px;
    min-width: 72px;
    min-height: 72px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.5rem;
    font-weight: 700;
    flex-shrink: 0;
    line-height: 1;
}
.wms-theme .client-discussion-item-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
}
.wms-theme .client-discussion-item-row .client-discussion-item-link {
    flex: 1;
    min-width: 0;
    padding: 0;
}
.wms-theme .client-discussion-list .list-group-item {
    padding: 0;
}
.wms-theme .client-discussion-participants-stack {
    display: inline-flex;
    align-items: center;
    cursor: pointer;
}
.wms-theme .client-discussion-participants-stack__avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 2px solid #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 0.625rem;
    font-weight: 700;
    margin-left: -10px;
    box-shadow: 0 0 0 1px rgba(25, 118, 210, 0.08);
    position: relative;
}
.wms-theme .client-discussion-participants-stack__avatar:first-child {
    margin-left: 0;
}
.wms-theme .client-discussion-participants-stack__more {
    margin-left: 6px;
    color: #546e7a;
    font-size: 1.1rem;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.08em;
}
.wms-theme .client-discussion-participants-list-item:hover {
    background: rgba(25, 118, 210, 0.04);
}

.wms-op-card--stock { background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%); color: var(--wms-blue-900, #0b3d7a); }
.msg-time { cursor: help; border-bottom: 1px dotted rgba(100, 116, 139, 0.45); }
.wms-op-card--stock .wms-op-card__icon { background: rgba(11, 61, 122, 0.12); color: var(--wms-blue-900, #0b3d7a) !important; }
.wms-op-card--stock .wms-op-card__icon i { color: var(--wms-blue-900, #0b3d7a) !important; stroke: var(--wms-blue-900, #0b3d7a) !important; }

.serial-product-list .list-group-item.active,
.serial-product-list .list-group-item.active .text-muted {
    color: #fff !important;
}
.serial-product-list .list-group-item.active .serial-product-sub {
    color: rgba(255, 255, 255, 0.92) !important;
}

/* Produits — pills & KPI */
.wms-prod-pill {
    display: inline-block;
    padding: 0.2rem 0.65rem;
    border-radius: 999px;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: #fff !important;
    line-height: 1.4;
    white-space: nowrap;
}
.wms-prod-pill--std { background: #64748b; }
.wms-prod-pill--serial { background: #3454d1; }
.wms-prod-pill--basse { background: #17c666; }
.wms-prod-pill--haute { background: #ea4d4d; }
.wms-prod-pill--warn { background: #fd7e14; color: #fff !important; }

.wms-kpi-tile {
    border-radius: 0.75rem;
    padding: 1rem 0.75rem;
    color: #fff;
}
.wms-kpi-tile__label {
    display: block;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    opacity: 0.92;
    margin-bottom: 0.35rem;
    color: #fff;
}
.wms-kpi-tile__value {
    display: block;
    font-size: 1.65rem;
    font-weight: 800;
    line-height: 1.1;
    color: #fff;
}
.wms-kpi-tile--success { background: linear-gradient(135deg, #17c666 0%, #20df7a 100%); }
.wms-kpi-tile--danger { background: linear-gradient(135deg, #ea4d4d 0%, #f56b6b 100%); }

.wms-prod-detail-scroll {
    max-height: calc(100vh - 11rem);
    overflow-y: auto;
}

#productDetailRoot > [class*="col-"] > .card {
    height: auto !important;
}

#productDetailRoot .dataTables_wrapper {
    min-height: 0;
}

#productDetailRoot #movementsTable_wrapper .dataTables_scrollBody {
    min-height: 0 !important;
    max-height: none !important;
}

.border-soft-warning { border-color: rgba(255, 193, 7, 0.5) !important; }
.border-soft-success { border-color: rgba(23, 198, 102, 0.45) !important; }
.border-soft-danger { border-color: rgba(234, 77, 77, 0.45) !important; }

.msg-read-receipt {
    display: inline-flex;
    align-items: center;
    color: #94a3b8;
    font-size: 0.75rem;
    line-height: 1;
    gap: 0.15rem;
}
.msg-read-receipt i + i { margin-left: -0.45rem; }
.msg-read-receipt--read { color: #25d366; }
.msg-read-date {
    font-size: 0.65rem;
    color: #25d366;
    white-space: nowrap;
    max-width: 5.5rem;
    overflow: hidden;
    text-overflow: ellipsis;
}
.msg-read-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.1rem;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
    border: 1px solid transparent;
}
.msg-read-badge i + i { margin-left: -0.4rem; }
.msg-read-badge--sent {
    color: #64748b;
    background: #f1f5f9;
    border-color: #e2e8f0;
}
.msg-read-badge--read {
    color: #25d366;
    background: rgba(37, 211, 102, 0.1);
    border-color: rgba(37, 211, 102, 0.35);
}
.msg-body blockquote,
.msg-detail-body blockquote {
    border-left: 3px solid #cbd5e1;
    margin: 0.75rem 0;
    padding: 0.35rem 0.75rem;
    color: #64748b;
    background: #f8fafc;
}

.wms-products-table { font-size: 0.82rem; }
.wms-products-table td, .wms-products-table th { vertical-align: middle; }
.wms-products-table .avatar-text { width: 2rem; height: 2rem; display: inline-flex; align-items: center; justify-content: center; }

/* Bons — états */
.doc-state { font-weight: 600; letter-spacing: 0.02em; }
.doc-state-prep { background: rgba(255, 193, 7, 0.18) !important; color: #856404 !important; }
.doc-state-wait { background: rgba(253, 126, 20, 0.18) !important; color: #c45a00 !important; }
.doc-state-ok { background: rgba(25, 135, 84, 0.18) !important; color: #146c43 !important; }
.doc-state-default { background: rgba(108, 117, 125, 0.15) !important; color: #495057 !important; }
.doc-card { transition: transform 0.2s ease, box-shadow 0.2s ease; }
.doc-card:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(0,0,0,0.08) !important; }
.doc-card-meta li { padding: 0.2rem 0; }
.doc-card-meta .text-muted { display: inline-block; min-width: 5.5rem; }
.doc-card-compact { transition: transform 0.2s ease, box-shadow 0.2s ease; }
.doc-card-compact:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(0,0,0,0.08) !important; }
.doc-card-compact code { font-size: 0.8rem !important; }

.doc-card-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
}

.doc-stat-tile {
    border: 1px dashed var(--bs-border-color, #e5e7eb);
    border-radius: 0.5rem;
    padding: 0.45rem 0.5rem;
    text-align: center;
    min-height: 3.25rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.doc-stat-tile--ok { border-color: rgba(23, 198, 102, 0.35); background: rgba(23, 198, 102, 0.06); }
.doc-stat-tile--muted { opacity: 0.85; }

.doc-stat-label {
    display: block;
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--bs-secondary-color);
    margin-bottom: 0.15rem;
}

.doc-stat-value {
    display: block;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--bs-body-color);
    line-height: 1.2;
}

.doc-stat-value--sm { font-size: 0.78rem; font-weight: 600; }

.doc-stat-sub {
    display: block;
    font-size: 0.68rem;
    color: var(--bs-secondary-color);
    margin-top: 0.1rem;
}

.wms-doc-comments-offcanvas { width: min(440px, 100vw); }

/* KPIs produits — inline compact (header) */
.wms-products-kpi-inline {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem;
}

.wms-products-kpi-pill {
    display: inline-flex;
    align-items: baseline;
    gap: 0.3rem;
    padding: 0.2rem 0.45rem;
    border: 1px solid var(--bs-border-color, #e5e7eb);
    border-radius: 999px;
    background: var(--bs-body-bg, #fff);
    font-size: 0.68rem;
    line-height: 1.2;
    white-space: nowrap;
}

.wms-products-kpi-pill__label {
    color: var(--bs-secondary-color);
    font-weight: 500;
}

.wms-products-kpi-pill strong {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--bs-primary);
}

.wms-products-kpi-pill--serial strong { color: #0288d1; }
.wms-products-kpi-pill--active strong { color: #17c666; }

/* Détail bon — layout compact 6+6 */
.doc-view-head .doc-state { font-size: 0.75rem; }
.doc-meta-card .card-header { background: #fff; }
.doc-meta-grid .doc-meta-item { min-height: 2.5rem; }
.doc-meta-grid .fs-11 { font-size: 0.68rem; text-transform: uppercase; letter-spacing: 0.03em; }
.doc-lines-card { min-height: 420px; }
.doc-lines-table thead th { font-size: 0.75rem; white-space: nowrap; }
.doc-lines-table tbody td { vertical-align: middle; }
#productListContainer .product-pick-item { border-left: 0; border-right: 0; }
#productListContainer .product-pick-item:first-child { border-top: 0; }
.doc-att-table th { font-size: 0.68rem; text-transform: uppercase; letter-spacing: 0.03em; }
.doc-lines-table tfoot td { border-top: 2px solid rgba(0,0,0,0.08); }
.doc-line-actions {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.35rem;
    white-space: nowrap;
}
.doc-line-actions .btn-icon {
    width: 30px;
    height: 30px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    line-height: 1;
}
.doc-line-actions .btn-icon i { font-size: 14px; }
.doc-line-locked { color: #adb5bd; display: inline-flex; align-items: center; }
.doc-comment-tag { font-weight: 600; letter-spacing: 0.02em; }
.doc-comment-tag.doc-tag-urgent,
.doc-comment-tag-select.doc-tag-urgent { background: rgba(220, 53, 69, 0.15) !important; color: #b02a37 !important; border-color: rgba(220, 53, 69, 0.35); }
.doc-comment-tag.doc-tag-info,
.doc-comment-tag-select.doc-tag-info { background: rgba(13, 110, 253, 0.12) !important; color: #0a58ca !important; border-color: rgba(13, 110, 253, 0.3); }
.doc-comment-tag.doc-tag-neutral,
.doc-comment-tag-select.doc-tag-neutral { background: rgba(52, 58, 64, 0.12) !important; color: #343a40 !important; border-color: rgba(52, 58, 64, 0.25); }
.doc-comment-tag-select { width: auto; min-width: 7.5rem; font-size: 0.72rem; font-weight: 600; padding: 0.15rem 1.5rem 0.15rem 0.45rem; }

.wms-client-card {
    background: #fff !important;
    border-color: rgba(13, 110, 253, 0.12) !important;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.wms-client-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 28px rgba(13, 110, 253, 0.12) !important;
    border-color: rgba(13, 110, 253, 0.25) !important;
}
.wms-client-card__icon {
    width: 52px;
    height: 52px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(13, 110, 253, 0.08);
    color: var(--bs-primary);
    font-size: 1.35rem;
}
.wms-signature-pad { touch-action: none; cursor: crosshair; }

/* Admin — layout compact */
.page-header-compact {
    margin-bottom: 0.75rem !important;
    padding-bottom: 0 !important;
    min-height: 0 !important;
}
.main-content > .card.stretch-full,
.main-content > .card.mb-2 {
    margin-bottom: 0.75rem !important;
}
.main-content .card-header {
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
}

/* Rapports admin — layout compact */
.report-page {
    margin-top: -0.25rem;
}
.report-page-head {
    margin-bottom: 0.75rem !important;
}
.report-results-intro {
    background: rgba(var(--bs-primary-rgb), 0.03);
}
.report-results-intro #reportDynamicTitle {
    color: var(--bs-body-color);
    line-height: 1.35;
}
.report-results-intro #reportFilterSummary {
    line-height: 1.4;
}
.report-kpi-card .card-body {
    padding: 1.25rem 1.5rem !important;
    min-height: 7.5rem;
}
.report-kpi-label {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    margin-bottom: 0.5rem;
}
.report-kpi-value {
    font-size: 1.65rem;
    font-weight: 700;
    line-height: 1.15;
    margin-bottom: 0.4rem;
}
.report-kpi-meta {
    font-size: 0.75rem;
    line-height: 1.3;
    margin-bottom: 0;
}

/* Menu rapports — cartes pro avec bordure thématique */
.report-menu-card {
    --report-accent: var(--bs-primary);
    transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.28s ease;
}
.report-menu-card .card {
    border-left: 4px solid var(--report-accent);
    transition: box-shadow 0.28s ease, border-color 0.28s ease;
    overflow: hidden;
}
.report-menu-card:hover,
.report-menu-card:focus-visible {
    transform: translateY(-4px);
}
.report-menu-card:hover .card,
.report-menu-card:focus-visible .card {
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.12);
}
.report-menu-card__category {
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--bs-secondary-color);
}
.report-menu-card__title {
    font-size: 1.05rem;
    line-height: 1.35;
    transition: color 0.2s ease;
}
.report-menu-card__desc {
    line-height: 1.55;
}
.report-menu-card__action {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--report-accent);
    transition: letter-spacing 0.2s ease, opacity 0.2s ease;
}
.report-menu-card__action i {
    transition: transform 0.25s ease;
    vertical-align: -2px;
}
.report-menu-card:hover .report-menu-card__action i,
.report-menu-card:focus-visible .report-menu-card__action i {
    transform: translateX(4px);
}
.report-menu-card--red { --report-accent: #dc3545; }
.report-menu-card--orange { --report-accent: #fd7e14; }
.report-menu-card--green { --report-accent: #198754; }
.report-menu-card--blue { --report-accent: #3454d1; }
.report-menu-card--teal { --report-accent: #0dcaf0; }
.report-menu-card--purple { --report-accent: #6f42c1; }

/* KPI dashboard — timelines documents */
.kpi-doc-timeline {
    position: relative;
    z-index: 1;
}
.kpi-doc-timeline::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--bs-border-color);
    transform: translateY(calc(-50% - 12px));
    z-index: -1;
}
.kpi-doc-node {
    width: 32px;
    height: 32px;
    box-shadow: 0 0 0 4px #fff;
}
.kpi-volume-scroll {
    max-height: 520px;
    overflow-y: auto;
}
.kpi-timeline-scroll {
    max-height: 470px;
    overflow-y: auto;
}

/* Journal — select produit (Select2 Bootstrap 5) */
.journal-product-picker {
    position: relative;
    min-width: 0;
}
.journal-product-picker select.form-select {
    width: 100%;
}
.journal-product-picker .select2-container--bootstrap-5 {
    width: 100% !important;
}
.journal-product-picker .select2-container--bootstrap-5 .select2-selection--single {
    overflow: hidden;
}
.journal-product-picker .select2-container--bootstrap-5 .select2-selection--single .select2-selection__rendered {
    display: flex;
    align-items: center;
    min-width: 0;
    overflow: hidden;
}
.journal-product-selection {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 0;
    width: 100%;
}
.journal-product-selection__name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex: 1;
    min-width: 0;
}
.journal-product-selection__code {
    flex-shrink: 0;
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: var(--bs-primary);
    background: rgba(52, 84, 209, 0.08);
    padding: 0.12rem 0.4rem;
    border-radius: 0.25rem;
    max-width: 38%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.journal-product-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    min-width: 0;
    padding: 0.15rem 0;
}
.journal-product-option__name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex: 1;
    min-width: 0;
    font-size: 0.875rem;
}
.journal-product-option__code {
    flex-shrink: 0;
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--bs-secondary-color);
    background: var(--bs-light);
    border: 1px solid var(--bs-border-color);
    padding: 0.15rem 0.45rem;
    border-radius: 0.25rem;
}
.journal-product-picker .select2-dropdown {
    min-width: 100%;
    border-color: var(--bs-border-color);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.1);
}
.journal-product-picker .select2-results__option--highlighted .journal-product-option__code {
    background: rgba(255, 255, 255, 0.85);
}

.select2-container--default .select2-selection--single {
    min-height: 31px;
    border-color: var(--bs-border-color);
    font-size: 0.875rem;
}
.select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 29px;
    padding-left: 0.65rem;
}
.select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 29px;
}
.profile-signature-preview img,
.profile-signature-preview-img {
    max-height: 140px;
    width: auto;
    display: block;
    margin: 0 auto;
}

.wms-user-avatar {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.wms-user-avatar--sm { width: 28px; height: 28px; }
.wms-user-avatar--md { width: 40px; height: 40px; }
.wms-user-avatar--lg { width: 52px; height: 52px; }
.wms-user-avatar--xl { width: 72px; height: 72px; }
.wms-user-avatar__img,
.wms-user-avatar__initials {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}
.wms-user-avatar__initials {
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(var(--bs-primary-rgb, 13, 110, 253), 0.12);
    color: var(--bs-primary);
    font-weight: 600;
    font-size: 0.85em;
}
.wms-user-avatar--xl .wms-user-avatar__initials { font-size: 1.35rem; }
.wms-presence-badge {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 11px;
    height: 11px;
    border-radius: 50%;
    border: 2px solid var(--bs-body-bg, #fff);
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.06);
}
.wms-user-avatar--lg .wms-presence-badge,
.wms-user-avatar--xl .wms-presence-badge {
    width: 14px;
    height: 14px;
}
.wms-presence-option {
    cursor: pointer;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.wms-presence-option:has(input:checked) {
    border-color: var(--bs-primary) !important;
    box-shadow: 0 0 0 1px rgba(var(--bs-primary-rgb), 0.25);
}
.wms-header-avatar-trigger {
    padding: 0;
    border: 0;
    background: transparent;
    line-height: 1;
}
.select2-results__option .wms-user-avatar { vertical-align: middle; }

/* Messagerie — select destinataire */
.wms-recipient-picker .select2-container--bootstrap-5 {
    width: 100% !important;
}
.wms-recipient-picker .select2-container--bootstrap-5 .select2-selection--single {
    min-height: calc(1.5em + 0.5rem + 2px);
    overflow: hidden;
}
.wms-recipient-picker .select2-container--bootstrap-5 .select2-selection--single .select2-selection__rendered {
    display: flex;
    align-items: center;
    min-width: 0;
    overflow: hidden;
    padding-right: 2rem;
}
.wms-recipient-selection {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 0;
    max-width: 100%;
}
.wms-recipient-selection__name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 600;
    font-size: 0.875rem;
}
.wms-recipient-option {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    min-width: 0;
    padding: 0.15rem 0;
}
.wms-recipient-option__name {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 0.875rem;
}
.wms-recipient-option__status {
    flex-shrink: 0;
    font-size: 0.68rem;
    font-weight: 600;
    color: var(--bs-secondary-color);
    background: var(--bs-light);
    border: 1px solid var(--bs-border-color);
    padding: 0.12rem 0.45rem;
    border-radius: 999px;
}
.select2-results__option--highlighted .wms-recipient-option__status {
    background: rgba(255, 255, 255, 0.9);
}

/* ========== Storeman theme (bleu foncé / bleu ciel) ========== */
.wms-theme {
    --wms-blue-900: #0b3d7a;
    --wms-blue-800: #0d47a1;
    --wms-blue-700: #1565c0;
    --wms-blue-500: #2196f3;
    --wms-blue-400: #42a5f5;
    --wms-blue-300: #64b5f6;
    --wms-blue-200: #90caf9;
    --wms-blue-100: #e3f2fd;
    --bs-primary: var(--wms-blue-700);
    --bs-primary-rgb: 21, 101, 192;
}

/* Horizontal layout — nav intégrée dans le header */
.wms-theme.wms-nav-horizontal {
    --wms-topbar-h: 56px;
}

.wms-theme.wms-nav-horizontal .wms-header--horizontal {
    min-height: var(--wms-topbar-h);
    left: 0 !important;
    width: 100% !important;
}

.wms-theme.wms-nav-horizontal .wms-header--horizontal .header-wrapper {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0 1rem;
    min-height: var(--wms-topbar-h);
    flex-wrap: nowrap;
}

.wms-theme.wms-nav-horizontal .wms-header--horizontal .nxl-h-item {
    min-height: var(--wms-topbar-h);
}

.wms-header-nav {
    flex: 1 1 auto;
    min-width: 0;
    overflow: visible;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.wms-header-nav__item.dropdown {
    position: static;
}
.wms-header-nav .dropdown-menu {
    z-index: 1055;
    max-height: min(70vh, 520px);
    overflow-y: auto;
}
.wms-header-nav::-webkit-scrollbar { display: none; }

.wms-header-nav__list {
    display: flex;
    align-items: center;
    gap: 0.15rem;
    list-style: none;
    margin: 0;
    padding: 0;
    min-width: max-content;
}

.wms-header-nav__link {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.4rem 0.7rem;
    border-radius: 0.5rem;
    color: #283c50;
    text-decoration: none;
    font-size: 0.8125rem;
    font-weight: 500;
    white-space: nowrap;
    transition: background 0.15s ease, color 0.15s ease;
}
.wms-header-nav__link i { font-size: 0.95rem; color: #64748b; }
.wms-header-nav__link:hover {
    color: var(--wms-blue-700);
    background: rgba(21, 101, 192, 0.08);
}
.wms-header-nav__link:hover i { color: var(--wms-blue-700); }
.wms-header-nav__link.active {
    color: var(--wms-blue-700);
    background: rgba(21, 101, 192, 0.12);
    font-weight: 600;
}
.wms-header-nav__link.active i { color: var(--wms-blue-700); }

/* Contenu principal — scroll interne, header toujours visible */
html:has(body.wms-theme.wms-nav-horizontal),
body.wms-theme.wms-nav-horizontal {
    height: 100%;
    overflow: hidden;
}

.wms-theme.wms-nav-horizontal .wms-header--horizontal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1030;
    min-height: var(--wms-topbar-h);
    background: #fff;
}

.wms-theme.wms-nav-horizontal .nxl-container.wms-main {
    position: fixed !important;
    top: var(--wms-topbar-h, 56px) !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    margin-left: 0 !important;
    width: auto !important;
    max-width: none !important;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    min-height: unset !important;
    height: auto !important;
    background-color: #f0f2f8;
}
.wms-theme.wms-nav-horizontal .nxl-content,
.wms-theme.wms-nav-horizontal .main-content {
    overflow-x: hidden;
    overflow-y: visible;
    height: auto;
}
.wms-theme.wms-nav-horizontal .nxl-content .main-content {
    padding-top: 1.25rem;
}
.wms-theme.wms-nav-horizontal .wms-landing-hero {
    margin-bottom: 1.25rem;
}
html.minimenu body.wms-theme.wms-nav-horizontal .nxl-container.wms-main {
    margin-left: 0 !important;
}
html.minimenu body.wms-theme.wms-nav-horizontal .nxl-header {
    left: 0 !important;
    width: 100% !important;
}
.wms-theme.wms-nav-horizontal .nxl-header {
    left: 0 !important;
    width: 100% !important;
}

@media (max-width: 991.98px) {
    .wms-theme.wms-nav-horizontal {
        --wms-topbar-h: 52px;
    }
    .wms-header-nav__link span {
        display: none;
    }
    .wms-header-nav__link {
        padding: 0.4rem 0.55rem;
    }
}

/* Vertical mode — classic sidebar */
.wms-nav-vertical .nxl-link.active {
    background: rgba(21, 101, 192, 0.12);
    color: var(--wms-blue-700);
}
.wms-nav-vertical .wms-sidebar-card {
    border-color: var(--wms-blue-100);
}
.wms-theme.wms-nav-vertical .wms-main {
    /* Duralux gère margin-left via nxl-navigation */
}
.wms-theme.wms-nav-vertical .wms-header {
    left: var(--nxl-navigation-width, 280px);
    width: calc(100% - var(--nxl-navigation-width, 280px));
}

/* Header storeman */
.wms-theme .wms-header {
    background: #fff;
    border-bottom: 1px solid var(--wms-blue-100);
}
.wms-header-brand .logo-lg { max-height: 32px; width: auto; }
.wms-header-brand .logo-sm { max-height: 34px; width: auto; display: none; }
@media (max-width: 991.98px) {
    .wms-header-brand .logo-lg { display: none !important; }
    .wms-header-brand .logo-sm { display: inline-block !important; }
}
.wms-login-logo { max-height: 72px; width: auto; }

/* Badge client — header */
.wms-client-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 0.85rem;
    border-radius: 2rem;
    background: var(--wms-blue-100);
    border: 1px solid rgba(21, 101, 192, 0.2);
    line-height: 1.2;
    max-width: 220px;
}
.wms-client-badge--compact {
    padding: 0.3rem 0.65rem;
    max-width: 140px;
}
.wms-client-badge__label {
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--wms-blue-700);
}
.wms-client-badge__name {
    font-size: 0.9375rem;
    font-weight: 800;
    color: var(--wms-blue-900);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Emphase client — hero pages */
.wms-client-emphasis {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    margin-top: 0.65rem;
    padding: 0.5rem 1.1rem;
    border-radius: 2rem;
    background: #fff;
    border: 1px dashed rgba(21, 101, 192, 0.35);
    box-shadow: 0 4px 14px rgba(21, 101, 192, 0.08);
}
.wms-client-emphasis__label {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #64748b;
}
.wms-client-emphasis__name {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--wms-blue-700);
    letter-spacing: 0.01em;
}
.wms-client-emphasis--compact {
    margin-top: 0;
    padding: 0.2rem 0.75rem;
    gap: 0.45rem;
}
.wms-client-emphasis--compact .wms-client-emphasis__label {
    font-size: 0.625rem;
}
.wms-client-emphasis--compact .wms-client-emphasis__name {
    font-size: 0.8125rem;
    font-weight: 700;
}
.wms-discussion-client-banner--compact {
    margin: 0.15rem 0 0.35rem;
}
.wms-theme .client-discussion-item-link .wms-discussion-client-banner--compact {
    pointer-events: none;
}
.wms-btn-home,
.wms-btn-quick {
    background: var(--wms-blue-100);
    color: var(--wms-blue-700);
    border: none;
    border-radius: 50%;
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.wms-btn-quick {
    background: var(--wms-blue-500);
    color: #fff;
}
.wms-btn-home:hover { background: var(--wms-blue-200); color: var(--wms-blue-900); }
.wms-btn-quick:hover { background: var(--wms-blue-700); color: #fff; }
.wms-avatar { background: var(--wms-blue-700) !important; }

/* Landing zone centrée */
.wms-landing-wrap { padding: 0 0 2rem; }
.wms-landing {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 1rem;
}
.wms-theme .wms-page-header {
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 1rem;
    padding-right: 1rem;
}
.wms-theme .btn-primary {
    background-color: var(--wms-blue-700);
    border-color: var(--wms-blue-700);
}
.wms-theme .btn-primary:hover {
    background-color: var(--wms-blue-900);
    border-color: var(--wms-blue-900);
}
.wms-theme .text-primary { color: var(--wms-blue-700) !important; }
.wms-theme .bg-soft-primary { background: var(--wms-blue-100) !important; }

/* Quick actions modal */
.wms-quick-modal__icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--wms-blue-500), var(--wms-blue-300));
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.wms-quick-tile {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
    padding: 1rem 1.1rem;
    border: 1px dashed rgba(21, 101, 192, 0.25);
    border-radius: 0.75rem;
    background: #fff;
    text-decoration: none;
    color: inherit;
    height: 100%;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    cursor: pointer;
}
.wms-quick-tile:hover:not(.is-disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(21, 101, 192, 0.12);
    border-color: var(--wms-blue-300);
    color: inherit;
}
.wms-quick-tile.is-disabled {
    opacity: 0.45;
    cursor: not-allowed;
    pointer-events: none;
}
.wms-quick-tile__icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
}
.wms-quick-tile--blue .wms-quick-tile__icon { background: var(--wms-blue-100); color: var(--wms-blue-700); }
.wms-quick-tile--sky .wms-quick-tile__icon { background: rgba(100, 181, 246, 0.25); color: var(--wms-blue-500); }
.wms-quick-tile--navy .wms-quick-tile__icon { background: rgba(11, 61, 122, 0.12); color: var(--wms-blue-900); }
.wms-quick-tile__label { font-weight: 700; font-size: 0.875rem; color: #1e293b; }
.wms-quick-tile__desc { font-size: 0.75rem; color: #64748b; line-height: 1.3; }

/* Landing hero */
.wms-landing-hero {
    text-align: center;
    margin-bottom: 1.75rem;
}
.wms-landing-hero h2 {
    font-weight: 700;
    color: var(--wms-blue-900);
    margin-bottom: 0.35rem;
}
.wms-landing-hero p { color: #64748b; margin-bottom: 0; }

/* Client mini-cards (landing) */
.wms-client-tile {
    border: 1px dashed rgba(21, 101, 192, 0.3);
    border-radius: 0.75rem;
    padding: 1.25rem;
    background: #fff;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    height: 100%;
}
.wms-client-tile:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 24px rgba(21, 101, 192, 0.1);
    border-color: var(--wms-blue-300);
}

.wms-display-option {
    border-color: rgba(21, 101, 192, 0.15) !important;
    transition: border-color 0.15s ease, background 0.15s ease;
}
.wms-display-option:has(input:checked) {
    border-color: var(--wms-blue-300) !important;
    background: var(--wms-blue-100);
}

/* Dark mode — nav dans le header */
html.app-skin-dark .wms-theme.wms-nav-horizontal .wms-header-nav__link {
    color: rgba(255, 255, 255, 0.78);
}
html.app-skin-dark .wms-theme.wms-nav-horizontal .wms-header-nav__link i {
    color: rgba(255, 255, 255, 0.55);
}
html.app-skin-dark .wms-theme.wms-nav-horizontal .wms-header-nav__link:hover,
html.app-skin-dark .wms-theme.wms-nav-horizontal .wms-header-nav__link.active {
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
}
html.app-skin-dark .wms-theme.wms-nav-horizontal .wms-header-nav__link:hover i,
html.app-skin-dark .wms-theme.wms-nav-horizontal .wms-header-nav__link.active i {
    color: #fff;
}
html.app-skin-dark .wms-theme.wms-nav-horizontal .nxl-container.wms-main {
    background-color: transparent;
}
html.app-skin-dark .wms-theme .wms-header {
    background: #0f172a;
    border-bottom-color: rgba(255, 255, 255, 0.08);
}
html.app-skin-dark .wms-theme .wms-header-title-wrap h5 {
    color: rgba(255, 255, 255, 0.9) !important;
}
html.app-skin-dark .wms-client-badge {
    background: rgba(33, 150, 243, 0.15);
    border-color: rgba(255, 255, 255, 0.12);
}
html.app-skin-dark .wms-client-badge__label { color: var(--wms-blue-300); }
html.app-skin-dark .wms-client-badge__name { color: #fff; }
html.app-skin-dark .wms-client-emphasis {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.15);
}
html.app-skin-dark .wms-client-emphasis__name { color: var(--wms-blue-300); }

/* Rapports magasinier — sélecteur produit */
.wms-report-product-picker { position: relative; }
.wms-report-product-picker__control {
    display: flex;
    align-items: stretch;
    gap: 0.35rem;
}
.wms-report-product-picker__icon {
    position: absolute;
    left: 0.65rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--bs-secondary-color);
    font-size: 0.85rem;
    pointer-events: none;
    z-index: 2;
}
.wms-report-product-picker__search {
    padding-left: 2rem !important;
    flex: 1 1 auto;
    min-width: 0;
}
.wms-report-product-picker__search.is-selected {
    background: var(--wms-blue-50, #e3f2fd);
    border-color: var(--wms-blue-300, #64b5f6);
    font-weight: 500;
}
.wms-report-product-picker__clear {
    flex: 0 0 auto;
    align-self: center;
    padding: 0.15rem 0.45rem;
    line-height: 1;
    color: var(--bs-secondary-color);
}
.wms-report-product-picker__dropdown {
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 4px);
    z-index: 1050;
    max-height: 240px;
    overflow-y: auto;
    border-radius: 0.5rem;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12);
    border: 1px solid var(--bs-border-color);
}
.wms-report-product-picker__dropdown .list-group-item {
    border-left: 0;
    border-right: 0;
    padding: 0.55rem 0.75rem;
    cursor: pointer;
}
.wms-report-product-picker__dropdown .list-group-item:first-child { border-top: 0; }
.wms-report-product-picker__dropdown .list-group-item-action:hover,
.wms-report-product-picker__dropdown .list-group-item-action:focus {
    background: var(--wms-blue-50, #e3f2fd);
}
.report-page .dataTables_wrapper { padding: 0.75rem 1rem 1rem; }
.report-page #reportExportBtns .dt-buttons { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.report-page #reportExportBtns .dt-buttons .btn { margin: 0; }
.report-page #reportExportBtns .buttons-excel,
.report-page #reportExportBtns .btn-success.text-white {
    background-color: #198754 !important;
    border-color: #198754 !important;
    color: #fff !important;
}
.report-page #reportExportBtns .buttons-excel:hover,
.report-page #reportExportBtns .btn-success.text-white:hover {
    background-color: #157347 !important;
    border-color: #146c43 !important;
    color: #fff !important;
}
.report-page .report-pd-link { text-decoration: none; }
.report-page .report-pd-link:hover { text-decoration: underline; }
.report-page tr.report-month-row,
.report-page tr.report-product-row { cursor: pointer; }
.report-page tr.report-month-row:hover td,
.report-page tr.report-product-row:hover td { background-color: rgba(var(--bs-primary-rgb), 0.04); }
.report-page .report-month-label { font-weight: 600; }

.wms-snap-card { cursor: pointer; transition: box-shadow 0.15s ease; overflow: hidden; }
.wms-snap-card:hover { box-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.08); }
.wms-snap-card__thumb {
    height: 160px;
    background-size: cover;
    background-position: center;
    background-color: var(--bs-light, #f8f9fa);
    position: relative;
}
.wms-snap-card__thumb--empty {
    background-image: none;
}
.wms-snap-card__thumb-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2px;
    height: 160px;
    overflow: hidden;
}
.wms-snap-card__thumb-grid--3 {
    grid-template-columns: 2fr 1fr;
    grid-template-rows: 1fr 1fr;
}
.wms-snap-card__thumb-cell {
    background-size: cover;
    background-position: center;
    background-color: var(--bs-light, #f8f9fa);
    min-height: 0;
}
.wms-snap-card__thumb-grid--3 .wms-snap-card__thumb-cell--main {
    grid-row: span 2;
}
.wms-snap-lightbox .carousel-inner {
    min-height: 240px;
    background: var(--bs-light, #f8f9fa);
    border-radius: 0.375rem;
}
.wms-snap-lightbox-img {
    max-height: 70vh;
    width: auto;
    max-width: 100%;
    object-fit: contain;
}
.wms-snap-lightbox .carousel-indicators [data-bs-target] {
    background-color: var(--bs-primary, #0d6efd);
}
.wms-snap-preview-thumb {
    width: 72px;
    height: 72px;
    object-fit: cover;
    border: 1px solid rgba(0, 0, 0, 0.08);
}

.wms-sec-agent-photo {
    width: 48px;
    height: 48px;
    object-fit: cover;
    border: 2px solid rgba(var(--bs-primary-rgb), 0.12);
    background: var(--bs-light, #f8f9fa);
}
.wms-sec-agent-photo--lg {
    width: 56px;
    height: 56px;
}
.wms-sec-agent-photo-wrap {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wms-auth-creative-card {
    max-width: 960px;
    margin-left: auto;
    margin-right: auto;
}
.wms-auth-hero-img {
    max-height: 280px;
    width: auto;
}

/* Admin — validations mobile */
.adm-doc-mobile {
    background: #f4f6f9;
    min-height: 100vh;
}
.adm-doc-mobile__header {
    background: linear-gradient(135deg, #7f1d1d 0%, #b91c1c 45%, #dc2626 100%);
    color: #fff;
    padding: 1rem 1rem 1.25rem;
    position: sticky;
    top: 0;
    z-index: 1020;
    box-shadow: 0 4px 16px rgba(127, 29, 29, 0.25);
}
.adm-doc-mobile__main {
    padding: 0.85rem 0.85rem 1.5rem;
    max-width: 480px;
    margin: 0 auto;
}
.adm-doc-chip {
    border-radius: 999px;
    border: 1px solid #dee2e6;
    background: #fff;
    color: #495057;
    font-size: 0.78rem;
    font-weight: 600;
    padding: 0.35rem 0.75rem;
}
.adm-doc-chip.active {
    background: #dc2626;
    border-color: #dc2626;
    color: #fff;
}
.adm-doc-card {
    background: #fff;
    border-radius: 0.85rem;
    padding: 0.85rem 0.9rem;
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.06);
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-left: 4px solid #94a3b8;
    transition: transform 0.2s ease, opacity 0.25s ease;
}
.adm-doc-card--entry { border-left-color: #0ea5e9; }
.adm-doc-card--exit { border-left-color: #8b5cf6; }
.adm-doc-card--pending {
    border-left-color: #dc2626;
    box-shadow: 0 4px 14px rgba(220, 38, 38, 0.12);
}
.adm-doc-card--validated {
    opacity: 0;
    transform: scale(0.96);
}
.adm-doc-card__top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.35rem;
}
.adm-doc-card__code {
    font-size: 1.05rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: #0f172a;
    margin-bottom: 0.2rem;
}
.adm-doc-card__client {
    font-size: 0.82rem;
    color: #475569;
    margin-bottom: 0.45rem;
}
.adm-doc-card__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    font-size: 0.72rem;
    color: #64748b;
    margin-bottom: 0.65rem;
}
.adm-doc-card__meta span:first-child {
    color: #475569;
    font-weight: 500;
}
.adm-doc-mob-section + .adm-doc-mob-section {
    border-top: 1px dashed rgba(0, 0, 0, 0.08);
    padding-top: 0.75rem;
}
.adm-doc-mob-attach:last-child {
    margin-bottom: 0 !important;
}
.adm-doc-card__actions {
    display: flex;
    gap: 0.5rem;
}

/* ── Guide magasinier (documentation) ── */
.wms-doc-toolbar {
    background: var(--wms-surface, #fff);
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
    padding: 0.85rem 1rem;
    margin: -0.5rem -0.5rem 1rem;
    z-index: 100;
}
.wms-doc-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 1.5rem;
    align-items: start;
}
@media (max-width: 991.98px) {
    .wms-doc-layout { grid-template-columns: 1fr; }
}
.wms-doc-sidebar {
    position: sticky;
    top: 72px;
    max-height: calc(100vh - 88px);
    overflow: auto;
    background: var(--wms-surface, #fff);
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 0.75rem;
}
.wms-doc-sidebar-inner { padding-bottom: 0.5rem; }
.wms-doc-module-list { padding: 0.25rem 0; }
.wms-doc-module-link {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.55rem 1rem;
    color: #475569;
    text-decoration: none;
    font-size: 0.875rem;
    border-left: 3px solid transparent;
    transition: background 0.15s, color 0.15s;
}
.wms-doc-module-link:hover { background: rgba(59, 130, 246, 0.06); color: #1e40af; }
.wms-doc-module-link.active {
    background: rgba(59, 130, 246, 0.1);
    color: #1d4ed8;
    font-weight: 600;
    border-left-color: #3b82f6;
}
.wms-doc-module-link i { width: 1.1rem; text-align: center; flex-shrink: 0; }
.wms-doc-toc-link {
    display: block;
    padding: 0.25rem 0;
    font-size: 0.8rem;
    color: #64748b;
    text-decoration: none;
}
.wms-doc-toc-link:hover, .wms-doc-toc-link.active { color: #1d4ed8; }
.wms-doc-toc-level-3 .wms-doc-toc-link { padding-left: 0.75rem; }
.wms-doc-content {
    background: var(--wms-surface, #fff);
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 0.75rem;
    padding: 1.5rem 1.75rem;
    min-width: 0;
}
.wms-doc-article-body {
    font-size: 0.9375rem;
    line-height: 1.65;
    color: #334155;
}
.wms-doc-article-body h1 { font-size: 1.5rem; font-weight: 700; margin-bottom: 0.75rem; color: #0f172a; }
.wms-doc-article-body h2 {
    font-size: 1.125rem;
    font-weight: 700;
    margin: 1.75rem 0 0.75rem;
    padding-bottom: 0.35rem;
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
    color: #1e293b;
}
.wms-doc-article-body h3 { font-size: 1rem; font-weight: 600; margin: 1.25rem 0 0.5rem; color: #334155; }
.wms-doc-article-body p { margin-bottom: 0.85rem; }
.wms-doc-article-body > blockquote:first-of-type {
    font-size: 1rem;
    color: #475569;
    border-left: none;
    padding: 0;
    margin-bottom: 1rem;
    background: transparent;
}
.wms-doc-list { margin-bottom: 1rem; padding-left: 1.25rem; }
.wms-doc-list li { margin-bottom: 0.35rem; }
.wms-doc-table { font-size: 0.875rem; margin-bottom: 1rem; }
.wms-doc-table th { background: #f8fafc; font-weight: 600; }
.wms-doc-callout {
    border-radius: 0.5rem;
    padding: 0.85rem 1rem;
    margin: 1rem 0;
    border-left: 4px solid #94a3b8;
    background: #f8fafc;
    font-size: 0.9rem;
}
.wms-doc-callout--remember { border-left-color: #3b82f6; background: #eff6ff; }
.wms-doc-callout--tip { border-left-color: #10b981; background: #ecfdf5; }
.wms-doc-callout--warn { border-left-color: #f59e0b; background: #fffbeb; }
.wms-doc-print .wms-doc-print-cover { page-break-after: avoid; }
.wms-doc-print-section { page-break-inside: avoid; }
.wms-doc-print-page .wms-doc-article-body { font-size: 11pt; }
.wms-doc-offcanvas { width: min(320px, 90vw); }

/* Bouton retour circulaire (icône) */
.wms-back-fab {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    color: #3454d1;
    border: 1px solid rgba(52, 84, 209, 0.22);
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.08);
    text-decoration: none;
    transition: transform 0.15s ease, box-shadow 0.15s ease, color 0.15s ease;
    flex-shrink: 0;
}
.wms-back-fab:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(52, 84, 209, 0.16);
    color: #243eb8;
}
.wms-back-fab i {
    font-size: 18px;
    line-height: 1;
}
.wms-back-fab--fixed,
.wms-back-fab--anchor-right {
    position: fixed;
    top: calc(var(--wms-topbar-h, 56px) + 12px);
    right: 24px;
    z-index: 1040;
}
.wms-page-back-toolbar {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 1rem;
    min-height: 40px;
    width: 100%;
}
.wms-page-back-toolbar__left {
    flex-shrink: 0;
}
.wms-page-back-toolbar__right {
    flex-shrink: 0;
    margin-left: auto;
}
.wms-landing-hero--with-page-back {
    padding-top: 0.25rem;
}

/* Storeman UX refonte */
.wms-ops-center {
    max-width: 920px;
    width: 100%;
}
.wms-ops-hub { max-width: 100%; }
.wms-other-actions-page {
    max-width: 640px;
    width: 100%;
}
.wms-other-actions-hero {
    max-width: 640px;
}
.wms-other-actions-list__link {
    transition: background 0.15s ease;
}
.wms-other-actions-list__link:hover,
.wms-other-actions-list__link.active {
    background: rgba(21, 101, 192, 0.08);
}
.wms-other-actions-list__link.active .fw-semibold {
    color: var(--wms-blue-700) !important;
}
.wms-nav-horizontal .dropdown-menu.wms-header-actions-menu {
    max-height: min(70vh, 520px);
    overflow-y: auto;
}
.card.border-dashed { border-style: dashed !important; }
.wms-product-more-link { z-index: 1030; }
.doc-attachment-list .list-group-item {
    border-left: 0;
    border-right: 0;
}
.doc-attachment-item {
    transition: background 0.15s ease;
}
.doc-attachment-item:hover {
    background: rgba(52, 84, 209, 0.04);
}
.doc-file-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.1rem;
}
.doc-file-icon--pdf { background: rgba(239, 68, 68, 0.12); color: #dc2626; }
.doc-file-icon--image { background: rgba(34, 197, 94, 0.12); color: #16a34a; }
.doc-file-icon--doc { background: rgba(59, 130, 246, 0.12); color: #2563eb; }
.doc-file-icon--sheet { background: rgba(22, 163, 74, 0.12); color: #15803d; }
.doc-file-icon--archive { background: rgba(245, 158, 11, 0.15); color: #d97706; }
.doc-file-icon--generic { background: rgba(100, 116, 139, 0.12); color: #475569; }
.wms-daily-check-kpi {
    border-left: 4px solid var(--wms-blue-500, #3454d1);
}
.wms-daily-check-kpi--entry { border-left-color: #3454d1; }
.wms-daily-check-kpi--exit { border-left-color: #e55353; }
.wms-daily-check-kpi--total { border-left-color: #64748b; }
.wms-daily-check-kpi__label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #64748b;
    font-weight: 600;
}
.wms-daily-check-kpi__value {
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1.1;
    color: #0f172a;
}
.wms-daily-check-tabs .nav-link {
    font-weight: 600;
    font-size: 0.8125rem;
    border-radius: 999px;
    padding: 0.45rem 1rem;
    color: #475569;
}
.wms-daily-check-tabs .nav-link.active {
    background: rgba(52, 84, 209, 0.12);
    color: var(--wms-blue-700, #243eb8);
}
.wms-daily-check-table thead th {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    white-space: nowrap;
}
.wms-daily-check-report {
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    color: #0f172a;
    padding: 1.5rem;
    max-width: 1100px;
    margin: 0 auto;
}
.wms-daily-check-report__brand {
    font-size: 1.25rem;
    font-weight: 700;
    color: #3454d1;
    margin-bottom: 0.25rem;
}
.wms-daily-check-report__meta {
    font-size: 0.875rem;
    color: #64748b;
    margin-bottom: 1.25rem;
}
.wms-daily-check-report__kpi {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.5rem;
}
.wms-daily-check-report__kpi span {
    background: #f1f5f9;
    border-radius: 0.5rem;
    padding: 0.5rem 0.85rem;
    font-size: 0.8125rem;
}
.wms-daily-check-report h2 {
    font-size: 1rem;
    font-weight: 700;
    margin: 1.25rem 0 0.5rem;
    color: #3454d1;
}
.wms-daily-check-report table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8125rem;
    margin-bottom: 0.5rem;
}
.wms-daily-check-report th,
.wms-daily-check-report td {
    border: 1px solid #cbd5e1;
    padding: 0.4rem 0.55rem;
    text-align: left;
}
.wms-daily-check-report th {
    background: #f8fafc;
    font-weight: 600;
}
.wms-daily-check-report .text-end { text-align: right; }
@media print {
    .daily-check-section { break-inside: avoid; page-break-inside: avoid; }
}
