/**
 * Design system — Bois Simonet (base Linear / SaaS premium, blanc + bleu)
 * Portée : html.ui-premium uniquement. Aucune logique métier (CSS seul).
 * Charger après styles.css.
 */

/* -------------------------------------------------------------------------- */
/* Tokens : réinjectés dans les variables historiques + tokens DS explicites */
/* -------------------------------------------------------------------------- */
html.ui-premium {
  /* DS — palette */
  --ds-bg-app: #f6f7f9;
  --ds-bg-elevated: #ffffff;
  --ds-border: rgba(15, 23, 42, 0.08);
  --ds-border-strong: rgba(15, 23, 42, 0.12);
  --ds-text: #0f172a;
  --ds-text-secondary: #475569;
  --ds-text-muted: #64748b;
  --ds-action: #0095c8;
  --ds-action-hover: #007fae;
  --ds-action-soft: rgba(0, 149, 200, 0.12);
  --ds-success: #059669;
  --ds-success-soft: rgba(5, 150, 105, 0.12);
  --ds-warning: #d97706;
  --ds-warning-soft: rgba(217, 119, 6, 0.14);
  --ds-danger: #dc2626;
  --ds-danger-soft: rgba(220, 38, 38, 0.12);

  /* Sous la topbar sticky : Retour + onglets sur une ligne */
  --app-topbar-sticky-offset: calc(6px + 60px + env(safe-area-inset-top, 0px) + 4px);

  --app-page-gutter: max(20px, calc((100vw - min(1520px, calc(100vw - 40px))) / 2));

  /* Hauteur réservée : une ligne Retour + onglets centrés */
  --app-restaurant-margins-chrome-stack: 44px;

  /* DS — structure */
  --ds-font-sans: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --ds-text-xs: 0.75rem;
  --ds-text-sm: 0.8125rem;
  --ds-text-md: 0.9375rem;
  --ds-text-lg: 1.0625rem;
  --ds-leading-tight: 1.25;
  --ds-leading-normal: 1.45;
  --ds-space-1: 4px;
  --ds-space-2: 8px;
  --ds-space-3: 12px;
  --ds-space-4: 16px;
  --ds-space-5: 20px;
  --ds-space-6: 24px;
  --ds-space-8: 32px;
  --ds-radius-sm: 8px;
  --ds-radius-md: 10px;
  --ds-radius-lg: 14px;
  --ds-radius-xl: 18px;
  --ds-shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.05);
  --ds-shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.04), 0 6px 16px rgba(15, 23, 42, 0.06);
  --ds-shadow-md: 0 4px 12px rgba(15, 23, 42, 0.07);
  --ds-focus-ring: 0 0 0 3px rgba(0, 149, 200, 0.28);
  --ds-shadow-panel:
    0 1px 0 rgba(15, 23, 42, 0.04),
    0 1px 2px rgba(15, 23, 42, 0.04),
    0 12px 40px rgba(15, 23, 42, 0.07);
  --ds-shadow-panel-hover:
    0 1px 0 rgba(15, 23, 42, 0.05),
    0 4px 14px rgba(15, 23, 42, 0.08),
    0 20px 50px rgba(15, 23, 42, 0.08);
  --ds-ease-premium: cubic-bezier(0.25, 0.1, 0.25, 1);
  --ds-duration-fast: 140ms;
  --ds-duration-base: 220ms;
  /* Bleu proche identité Camping Paradis (lisible sur fond clair) */
  --ds-camping-paradis-blue: #0095c8;
  --ds-camping-paradis-blue-soft: rgba(0, 149, 200, 0.12);

  /* Alignement sur l’existant (styles.css consomme ces noms) */
  --bg-top: #fafbfc;
  --bg-bottom: #f1f5f9;
  --ink: var(--ds-text);
  --muted: var(--ds-text-muted);
  --line: var(--ds-border);
  --panel: #ffffff;
  --panel-strong: #ffffff;
  --shadow: var(--ds-shadow-sm);
  --shadow-soft: var(--ds-shadow-xs);
  --radius-xl: var(--ds-radius-xl);
  --radius-lg: var(--ds-radius-lg);
  --radius-md: var(--ds-radius-md);
  --success: var(--ds-success);
  --success-soft: var(--ds-success-soft);
  --alert: var(--ds-warning);
  --alert-soft: var(--ds-warning-soft);
  --danger: var(--ds-danger);
  --danger-soft: var(--ds-danger-soft);
  --neutral-soft: rgba(15, 23, 42, 0.05);
  --accent: var(--ds-action);
  --accent-soft: var(--ds-action-soft);
  --accent-strong: var(--ds-action-hover);
}

/* -------------------------------------------------------------------------- */
/* Fond application & typo globale                                            */
/* -------------------------------------------------------------------------- */
html.ui-premium body {
  font-family: var(--ds-font-sans);
  color: var(--ds-text);
  background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
  -webkit-font-smoothing: antialiased;
}

/* Page sans bandeau titre : topbar sticky premium */
html.ui-premium .page-shell {
  padding-top: 10px;
  padding-bottom: 40px;
}

html.ui-premium .app-layout {
  margin-top: 0;
  display: block;
}

html.ui-premium .sidebar-shell {
  display: none;
}

/* -------------------------------------------------------------------------- */
/* Topbar globale                                                              */
/* -------------------------------------------------------------------------- */
html.ui-premium .app-topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  width: min(1520px, calc(100% - 40px));
  margin: 14px auto 0;
  padding: 10px 18px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 16px;
  min-height: 60px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: var(--ds-radius-xl);
  box-shadow: var(--ds-shadow-panel);
  backdrop-filter: blur(16px) saturate(1.15);
  -webkit-backdrop-filter: blur(16px) saturate(1.15);
  transition: box-shadow var(--ds-duration-base) var(--ds-ease-premium),
    border-color var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium .app-topbar-left {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

html.ui-premium .app-topbar-logo {
  display: block;
  width: auto;
  height: 62px;
  max-width: 220px;
  object-fit: contain;
}

html.ui-premium .app-topbar-brand {
  display: grid;
  gap: 1px;
}

html.ui-premium .app-topbar-brand strong {
  font-size: 0.875rem;
  font-weight: 650;
  line-height: 1.2;
  letter-spacing: -0.015em;
  color: var(--ds-text);
}

html.ui-premium .app-topbar-brand span {
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ds-text-muted);
}

html.ui-premium .topbar-nav-cluster {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-width: 0;
  max-width: 100%;
}

html.ui-premium .topbar-nav-cluster .topbar-nav {
  flex: 1 1 auto;
  min-width: 0;
  justify-content: center;
}

html.ui-premium .topbar-launch-app-button {
  flex: 0 0 auto;
  margin: 0;
  padding: 5px 12px;
  border-radius: 999px;
  appearance: none;
  -webkit-appearance: none;
  border: 1px solid rgba(0, 127, 174, 0.45);
  background: linear-gradient(135deg, rgba(0, 149, 200, 0.14) 0%, rgba(255, 255, 255, 0.96) 100%);
  color: rgb(0, 95, 130);
  font-family: inherit;
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.25;
  white-space: nowrap;
  cursor: pointer;
  box-shadow: var(--ds-shadow-xs);
  transition:
    background-color 0.25s ease,
    border-color 0.25s ease,
    box-shadow 0.25s ease;
}

html.ui-premium .topbar-launch-app-button:hover:not(:disabled) {
  border-color: rgba(0, 127, 174, 0.65);
  background: linear-gradient(135deg, rgba(0, 149, 200, 0.22) 0%, rgba(255, 255, 255, 1) 100%);
  box-shadow: 0 2px 8px rgba(0, 149, 200, 0.18);
}

html.ui-premium .topbar-launch-app-button:disabled {
  opacity: 0.6;
  cursor: default;
}

#topbar-launch-app-button.topbar-launch-app-button {
  border-color: rgba(0, 127, 174, 0.45);
  background: linear-gradient(135deg, rgba(0, 149, 200, 0.14) 0%, rgba(255, 255, 255, 0.96) 100%);
  color: rgb(0, 95, 130);
}

html.ui-premium .topbar-bridge-cancel-sync {
  flex: 0 0 auto;
  margin: 0;
  padding: 5px 11px;
  border-radius: 999px;
  appearance: none;
  -webkit-appearance: none;
  border: 1px solid rgba(180, 83, 9, 0.42);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.16) 0%, rgba(255, 255, 255, 0.97) 100%);
  color: rgb(146, 64, 14);
  font-family: inherit;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.25;
  white-space: nowrap;
  cursor: pointer;
  box-shadow: var(--ds-shadow-xs);
  transition:
    background-color 0.25s ease,
    border-color 0.25s ease,
    box-shadow 0.25s ease;
}

html.ui-premium .topbar-bridge-cancel-sync:hover:not(:disabled) {
  border-color: rgba(180, 83, 9, 0.62);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.24) 0%, rgba(255, 255, 255, 1) 100%);
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.2);
}

html.ui-premium .topbar-bridge-cancel-sync:disabled {
  opacity: 0.55;
  cursor: default;
}

#topbar-bridge-cancel-sync.topbar-bridge-cancel-sync {
  border-color: rgba(180, 83, 9, 0.42);
  color: rgb(146, 64, 14);
}

html.ui-premium .topbar-bridge-indicator {
  flex: 0 0 auto;
  max-width: min(300px, 62vw);
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px 3px 10px;
  border-radius: 999px;
  border: 1px solid rgba(15, 23, 42, 0.09);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: var(--ds-shadow-xs);
  font-size: 0.64rem;
  font-weight: 650;
  line-height: 1.25;
  color: var(--ds-text-secondary);
  white-space: nowrap;
  overflow: visible;
  transition:
    background-color 0.5s cubic-bezier(0.22, 1, 0.36, 1),
    border-color 0.5s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.5s cubic-bezier(0.22, 1, 0.36, 1),
    color 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

html.ui-premium .topbar-bridge-indicator-dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--ds-text-muted);
  flex-shrink: 0;
  box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.06) inset;
  transition: background-color 0.45s ease, box-shadow 0.45s ease;
}

html.ui-premium .topbar-bridge-indicator-prefix {
  flex-shrink: 0;
  letter-spacing: 0.01em;
}

html.ui-premium .topbar-bridge-indicator-prefix::after {
  content: "\00a0";
}

/* Emplacement OK / Relancer : même case, crossfade (pas de placeholder « … ») */
html.ui-premium .topbar-bridge-suffix-slot {
  position: relative;
  display: inline-block;
  min-width: 3.5rem;
  min-height: 1.38rem;
  vertical-align: middle;
}

html.ui-premium .topbar-bridge-suffix-slot[data-visible="relaunch"] {
  min-width: 5.35rem;
}

html.ui-premium .topbar-bridge-suffix-slot > * {
  position: absolute;
  left: 0;
  top: 50%;
  white-space: nowrap;
  visibility: hidden;
  transform: translateY(-50%) scale(0.9);
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 0.42s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.42s cubic-bezier(0.22, 1, 0.36, 1),
    visibility 0.42s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.35s ease,
    background-color 0.35s ease,
    border-color 0.35s ease,
    color 0.35s ease;
}

html.ui-premium .topbar-bridge-suffix-slot[data-visible="ok"] .topbar-bridge-relaunch-btn {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

html.ui-premium .topbar-bridge-suffix-slot[data-visible="relaunch"] .topbar-bridge-ok-inline {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

html.ui-premium .topbar-bridge-suffix-slot[data-visible="ok"] .topbar-bridge-ok-inline {
  z-index: 2;
  visibility: visible;
  opacity: 1;
  transform: translateY(-50%) scale(1);
  pointer-events: auto;
}

html.ui-premium .topbar-bridge-suffix-slot[data-visible="relaunch"] .topbar-bridge-relaunch-btn {
  z-index: 2;
  visibility: visible;
  opacity: 1;
  transform: translateY(-50%) scale(1);
  pointer-events: auto;
}

/* OK + Relancer visibles en meme temps (passerelle locale http://127.0.0.1) */
html.ui-premium .topbar-bridge-suffix-slot[data-visible="dual"] {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-width: auto;
  min-height: 1.38rem;
  vertical-align: middle;
}

html.ui-premium .topbar-bridge-suffix-slot[data-visible="dual"] > * {
  position: static;
  visibility: visible;
  opacity: 1;
  transform: none;
  pointer-events: auto;
  transition: none;
}

html.ui-premium .topbar-bridge-ok-inline {
  font-weight: 800;
  font-size: 0.66rem;
  letter-spacing: 0.04em;
  color: inherit;
}

/* OK : vert explicite (lisible sur le fond vert du pilule) */
html.ui-premium .topbar-bridge-indicator[data-state="up"] .topbar-bridge-ok-inline {
  display: inline-block;
  padding: 1px 8px 2px;
  border-radius: 999px;
  border: 1px solid rgba(5, 150, 105, 0.55);
  background: rgba(255, 255, 255, 0.92);
  color: rgb(4, 120, 87);
  box-shadow: 0 0 0 1px rgba(16, 185, 129, 0.15);
}

html.ui-premium .topbar-bridge-relaunch-btn {
  margin: 0;
  padding: 2px 10px;
  border-radius: 999px;
  appearance: none;
  -webkit-appearance: none;
  border: 1px solid rgba(220, 38, 38, 0.45);
  background: rgba(255, 255, 255, 0.98);
  color: rgb(185, 28, 28);
  font-size: 0.58rem;
  font-weight: 750;
  letter-spacing: 0.02em;
  cursor: pointer;
  line-height: 1.25;
  font-family: inherit;
}

html.ui-premium .topbar-bridge-relaunch-btn:hover:not(:disabled) {
  background: rgba(254, 226, 226, 0.75);
}

html.ui-premium .topbar-bridge-indicator[data-state="checking"] .topbar-bridge-relaunch-btn {
  border-color: rgba(100, 116, 139, 0.32);
  color: rgb(71, 85, 105);
  background: rgba(255, 255, 255, 0.94);
}

html.ui-premium .topbar-bridge-indicator[data-state="checking"] .topbar-bridge-relaunch-btn:hover:not(:disabled) {
  background: rgba(241, 245, 249, 0.95);
}

html.ui-premium .topbar-bridge-relaunch-btn:disabled {
  opacity: 0.55;
  cursor: default;
}

html.ui-premium .topbar-bridge-indicator[data-state="up"] {
  border-color: rgb(5, 150, 105);
  background: linear-gradient(135deg, rgba(209, 250, 229, 0.98) 0%, rgba(167, 243, 208, 0.92) 100%);
  color: rgb(4, 100, 72);
  box-shadow:
    0 0 0 1px rgba(16, 185, 129, 0.35),
    0 2px 8px rgba(5, 150, 105, 0.18);
}

/* Relancer reste rouge meme quand le pont est OK (action visible) */
html.ui-premium .topbar-bridge-indicator[data-state="up"] .topbar-bridge-suffix-slot[data-visible="dual"] .topbar-bridge-relaunch-btn {
  border-color: rgba(220, 38, 38, 0.55);
  color: rgb(185, 28, 28);
  background: rgb(255, 255, 255);
}

html.ui-premium .topbar-bridge-indicator[data-state="up"] .topbar-bridge-suffix-slot[data-visible="dual"] .topbar-bridge-relaunch-btn:hover:not(:disabled) {
  background: rgba(254, 226, 226, 0.9);
}

html.ui-premium .topbar-bridge-indicator[data-state="up"] .topbar-bridge-indicator-dot {
  background: rgb(5, 150, 105);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.45);
}

html.ui-premium .topbar-bridge-indicator[data-state="down"] {
  border-color: rgb(220, 38, 38);
  background: linear-gradient(135deg, rgba(254, 226, 226, 0.98) 0%, rgba(254, 202, 202, 0.94) 100%);
  color: rgb(127, 29, 29);
  box-shadow:
    0 0 0 1px rgba(239, 68, 68, 0.35),
    0 2px 8px rgba(220, 38, 38, 0.16);
}

html.ui-premium .topbar-bridge-indicator[data-state="down"] .topbar-bridge-indicator-dot {
  background: rgb(239, 68, 68);
  box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.4);
}

/* Couleurs bouton explicites (évite héritage gris / neutre du pill) */
html.ui-premium .topbar-bridge-indicator[data-state="down"] .topbar-bridge-relaunch-btn {
  border-color: rgba(220, 38, 38, 0.55);
  background: rgb(255, 255, 255);
  color: rgb(185, 28, 28);
  box-shadow:
    0 0 0 1px rgba(220, 38, 38, 0.12),
    0 1px 2px rgba(127, 29, 29, 0.08);
}

html.ui-premium .topbar-bridge-indicator[data-state="down"] .topbar-bridge-relaunch-btn:hover:not(:disabled) {
  background: rgba(254, 226, 226, 0.95);
}

html.ui-premium .topbar-bridge-indicator[data-state="checking"] {
  border-color: rgb(217, 119, 6);
  background: linear-gradient(135deg, rgba(255, 251, 235, 0.98) 0%, rgba(254, 243, 199, 0.94) 100%);
  color: rgb(146, 64, 14);
}

html.ui-premium .topbar-bridge-indicator[data-state="checking"] .topbar-bridge-indicator-dot {
  background: rgb(245, 158, 11);
  box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.35);
  animation: topbar-bridge-dot-pulse 1.2s ease-in-out infinite;
}

@keyframes topbar-bridge-dot-pulse {
  0%,
  100% {
    opacity: 0.65;
  }
  50% {
    opacity: 1;
  }
}

/* Voyant Bridge : couleurs garanties (ID = priorité, même si cache CSS partiel) */
#topbar-bridge-indicator.topbar-bridge-indicator {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px 3px 10px;
  border-radius: 999px;
  border-width: 1px;
  border-style: solid;
  font-size: 0.64rem;
  font-weight: 650;
  line-height: 1.25;
  white-space: nowrap;
}

#topbar-bridge-indicator.topbar-bridge-indicator[data-state="up"] {
  border-color: rgb(5, 150, 105);
  background: linear-gradient(135deg, rgba(209, 250, 229, 0.98) 0%, rgba(167, 243, 208, 0.92) 100%);
  color: rgb(4, 100, 72);
}

#topbar-bridge-indicator.topbar-bridge-indicator[data-state="up"] .topbar-bridge-indicator-dot {
  background: rgb(5, 150, 105);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.45);
}

#topbar-bridge-indicator.topbar-bridge-indicator[data-state="down"] {
  border-color: rgb(220, 38, 38);
  background: linear-gradient(135deg, rgba(254, 226, 226, 0.98) 0%, rgba(254, 202, 202, 0.94) 100%);
  color: rgb(127, 29, 29);
}

#topbar-bridge-indicator.topbar-bridge-indicator[data-state="down"] .topbar-bridge-indicator-dot {
  background: rgb(239, 68, 68);
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.4);
}

#topbar-bridge-indicator.topbar-bridge-indicator[data-state="checking"] {
  border-color: rgb(217, 119, 6);
  background: linear-gradient(135deg, rgba(255, 251, 235, 0.98) 0%, rgba(254, 243, 199, 0.94) 100%);
  color: rgb(146, 64, 14);
}

#topbar-bridge-indicator.topbar-bridge-indicator[data-state="checking"] .topbar-bridge-indicator-dot {
  background: rgb(245, 158, 11);
  box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.35);
}

#topbar-bridge-indicator.topbar-bridge-indicator[data-state="up"] .topbar-bridge-ok-inline {
  border-color: rgb(5, 150, 105);
  background: rgb(255, 255, 255);
  color: rgb(4, 120, 87);
  font-weight: 800;
}

#topbar-bridge-indicator.topbar-bridge-indicator .topbar-bridge-relaunch-btn {
  border-color: rgba(220, 38, 38, 0.55);
  background: rgb(255, 255, 255);
  color: rgb(185, 28, 28);
  font-weight: 750;
}

/* Modales progression (pont + mercuriale) */
html.ui-premium .bridge-launch-overlay,
.bridge-launch-overlay,
html.ui-premium .mercuriale-price-overlay,
.mercuriale-price-overlay,
html.ui-premium .progress-job-overlay,
.progress-job-overlay {
  position: fixed;
  inset: 0;
  z-index: 240;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(14, 30, 50, 0.42);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 240ms ease,
    visibility 0ms linear 240ms;
}

html.ui-premium .bridge-launch-overlay[data-active="true"],
.bridge-launch-overlay[data-active="true"],
html.ui-premium .mercuriale-price-overlay[data-active="true"],
.mercuriale-price-overlay[data-active="true"],
html.ui-premium .progress-job-overlay[data-active="true"],
.progress-job-overlay[data-active="true"] {
  opacity: 1;
  visibility: visible;
  transition:
    opacity 240ms ease,
    visibility 0ms linear;
}

html.ui-premium .bridge-launch-panel,
.bridge-launch-panel,
html.ui-premium .mercuriale-price-panel,
.mercuriale-price-panel,
html.ui-premium .progress-job-panel,
.progress-job-panel {
  width: min(100%, 460px);
  display: grid;
  gap: 12px;
  padding: 22px 22px 18px;
  border-radius: 20px;
  border: 1px solid rgba(15, 23, 42, 0.1);
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  box-shadow:
    0 28px 64px rgba(16, 52, 87, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
}

html.ui-premium .bridge-launch-overlay[data-outcome="success"] .bridge-launch-panel,
.bridge-launch-overlay[data-outcome="success"] .bridge-launch-panel,
html.ui-premium .mercuriale-price-overlay[data-outcome="success"] .mercuriale-price-panel,
.mercuriale-price-overlay[data-outcome="success"] .mercuriale-price-panel,
html.ui-premium .progress-job-overlay[data-outcome="success"] .progress-job-panel,
.progress-job-overlay[data-outcome="success"] .progress-job-panel {
  border-color: rgba(5, 150, 105, 0.35);
}

html.ui-premium .bridge-launch-overlay[data-outcome="error"] .bridge-launch-panel,
.bridge-launch-overlay[data-outcome="error"] .bridge-launch-panel,
html.ui-premium .mercuriale-price-overlay[data-outcome="error"] .mercuriale-price-panel,
.mercuriale-price-overlay[data-outcome="error"] .mercuriale-price-panel,
html.ui-premium .progress-job-overlay[data-outcome="error"] .progress-job-panel,
.progress-job-overlay[data-outcome="error"] .progress-job-panel {
  border-color: rgba(220, 38, 38, 0.35);
}

html.ui-premium .bridge-launch-title,
.bridge-launch-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 750;
  color: var(--ds-text, #0f172a);
}

html.ui-premium .bridge-launch-detail,
.bridge-launch-detail {
  margin: 0;
  font-size: 0.84rem;
  line-height: 1.45;
  color: var(--ds-text-secondary, #475569);
}

html.ui-premium .bridge-launch-progress-track,
.bridge-launch-progress-track {
  position: relative;
  height: 10px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(148, 163, 184, 0.22);
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.08);
}

html.ui-premium .bridge-launch-progress-fill,
.bridge-launch-progress-fill {
  display: block;
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, #0095c8 0%, #06b6d4 55%, #10b981 100%);
  transition: width 320ms ease;
}

html.ui-premium .bridge-launch-overlay[data-outcome="success"] .bridge-launch-progress-fill,
.bridge-launch-overlay[data-outcome="success"] .bridge-launch-progress-fill {
  background: linear-gradient(90deg, #059669 0%, #10b981 100%);
}

html.ui-premium .bridge-launch-overlay[data-outcome="error"] .bridge-launch-progress-fill,
.bridge-launch-overlay[data-outcome="error"] .bridge-launch-progress-fill {
  background: linear-gradient(90deg, #dc2626 0%, #f87171 100%);
}

html.ui-premium .bridge-launch-percent,
.bridge-launch-percent {
  margin: -4px 0 0;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--ds-text-muted, #64748b);
  text-align: right;
}

html.ui-premium .bridge-launch-steps,
.bridge-launch-steps {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 6px;
}

html.ui-premium .bridge-launch-step,
.bridge-launch-step {
  position: relative;
  padding: 6px 10px 6px 28px;
  border-radius: 10px;
  font-size: 0.78rem;
  line-height: 1.35;
  color: var(--ds-text-muted, #64748b);
  background: rgba(248, 250, 252, 0.9);
}

html.ui-premium .bridge-launch-step::before,
.bridge-launch-step::before {
  content: "";
  position: absolute;
  left: 10px;
  top: 50%;
  width: 8px;
  height: 8px;
  margin-top: -4px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.55);
}

html.ui-premium .bridge-launch-step[data-state="active"],
.bridge-launch-step[data-state="active"] {
  color: rgb(0, 95, 130);
  background: rgba(0, 149, 200, 0.1);
  font-weight: 650;
}

html.ui-premium .bridge-launch-step[data-state="active"]::before,
.bridge-launch-step[data-state="active"]::before {
  background: rgb(0, 149, 200);
  box-shadow: 0 0 0 3px rgba(0, 149, 200, 0.22);
}

html.ui-premium .bridge-launch-step[data-state="done"],
.bridge-launch-step[data-state="done"] {
  color: rgb(4, 100, 72);
  background: rgba(16, 185, 129, 0.08);
}

html.ui-premium .bridge-launch-step[data-state="done"]::before,
.bridge-launch-step[data-state="done"]::before {
  background: rgb(5, 150, 105);
}

html.ui-premium .bridge-launch-elapsed,
.bridge-launch-elapsed {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 650;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ds-text-muted, #64748b);
}

html.ui-premium .bridge-launch-actions,
.bridge-launch-actions {
  display: flex;
  justify-content: flex-end;
}

html.ui-premium .bridge-launch-dismiss,
.bridge-launch-dismiss {
  margin: 0;
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: #fff;
  color: var(--ds-text, #0f172a);
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 650;
  cursor: pointer;
}

html.ui-premium .bridge-launch-dismiss:hover,
.bridge-launch-dismiss:hover,
html.ui-premium .mercuriale-price-dismiss:hover,
.mercuriale-price-dismiss:hover,
html.ui-premium .progress-job-dismiss:hover,
.progress-job-dismiss:hover {
  background: rgba(248, 250, 252, 1);
}

html.ui-premium .mercuriale-price-title,
.mercuriale-price-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 750;
  color: var(--ds-text, #0f172a);
}

html.ui-premium .mercuriale-price-detail,
.mercuriale-price-detail {
  margin: 0;
  font-size: 0.84rem;
  line-height: 1.45;
  color: var(--ds-text-secondary, #475569);
}

html.ui-premium .mercuriale-price-hint,
.mercuriale-price-hint {
  margin: 2px 0 0;
  font-size: 0.76rem;
  line-height: 1.4;
  color: var(--ds-text-muted, #64748b);
  font-style: italic;
}

html.ui-premium .mercuriale-price-progress-track,
.mercuriale-price-progress-track,
html.ui-premium .progress-job-track,
.progress-job-track {
  position: relative;
  height: 10px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(148, 163, 184, 0.22);
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.08);
}

html.ui-premium .mercuriale-price-progress-fill,
.mercuriale-price-progress-fill,
html.ui-premium .progress-job-fill,
.progress-job-fill {
  display: block;
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, #0095c8 0%, #06b6d4 55%, #10b981 100%);
  transition: width 320ms ease;
}

html.ui-premium .mercuriale-price-overlay[data-outcome="success"] .mercuriale-price-progress-fill,
.mercuriale-price-overlay[data-outcome="success"] .mercuriale-price-progress-fill,
html.ui-premium .mercuriale-price-overlay[data-outcome="success"] .progress-job-fill,
.mercuriale-price-overlay[data-outcome="success"] .progress-job-fill {
  background: linear-gradient(90deg, #059669 0%, #10b981 100%);
}

html.ui-premium .mercuriale-price-overlay[data-outcome="error"] .mercuriale-price-progress-fill,
.mercuriale-price-overlay[data-outcome="error"] .mercuriale-price-progress-fill,
html.ui-premium .mercuriale-price-overlay[data-outcome="error"] .progress-job-fill,
.mercuriale-price-overlay[data-outcome="error"] .progress-job-fill {
  background: linear-gradient(90deg, #dc2626 0%, #f87171 100%);
}

html.ui-premium .mercuriale-price-overlay[data-outcome="alert-increase"] .mercuriale-price-panel,
.mercuriale-price-overlay[data-outcome="alert-increase"] .mercuriale-price-panel {
  border-color: rgba(220, 38, 38, 0.38);
  box-shadow:
    0 28px 64px rgba(127, 29, 29, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
}

html.ui-premium .mercuriale-price-overlay[data-outcome="alert-decrease"] .mercuriale-price-panel,
.mercuriale-price-overlay[data-outcome="alert-decrease"] .mercuriale-price-panel {
  border-color: rgba(5, 150, 105, 0.38);
  box-shadow:
    0 28px 64px rgba(6, 95, 70, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
}

html.ui-premium .mercuriale-price-overlay[data-outcome="alert-stable"] .mercuriale-price-panel,
.mercuriale-price-overlay[data-outcome="alert-stable"] .mercuriale-price-panel,
html.ui-premium .mercuriale-price-overlay[data-outcome="alert-initial"] .mercuriale-price-panel,
.mercuriale-price-overlay[data-outcome="alert-initial"] .mercuriale-price-panel {
  border-color: rgba(100, 116, 139, 0.32);
}

.mercuriale-price-alert-body {
  display: grid;
  gap: 14px;
  margin-top: 2px;
}

.mercuriale-price-alert-pill {
  justify-self: start;
}

.mercuriale-price-alert-prices {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.mercuriale-price-alert-prices-secondary {
  padding-top: 10px;
  border-top: 1px solid rgba(148, 163, 184, 0.28);
}

.mercuriale-price-alert-price-col {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(248, 250, 252, 0.95);
  border: 1px solid rgba(148, 163, 184, 0.22);
}

.mercuriale-price-alert-price-col-new {
  border-color: rgba(15, 23, 42, 0.12);
  background: #fff;
}

.mercuriale-price-alert-price-label {
  font-size: 0.72rem;
  font-weight: 650;
  color: var(--ds-text-muted, #64748b);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.mercuriale-price-alert-price-value {
  font-size: 1rem;
  font-weight: 750;
  color: var(--ds-text, #0f172a);
  font-variant-numeric: tabular-nums;
}

.mercuriale-price-alert-variation {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.mercuriale-price-alert-variation.supplier-alert-cell-variation-good {
  color: var(--ds-success, #059669);
}

.mercuriale-price-alert-variation.supplier-alert-cell-variation-danger {
  color: var(--ds-danger, #dc2626);
}

.mercuriale-price-alert-variation.supplier-alert-cell-variation-neutral {
  color: var(--ds-text-secondary, #475569);
}

.mercuriale-price-alert-variation-secondary {
  font-size: 0.92rem;
  font-weight: 700;
}

.mercuriale-price-alert-comparable-unit,
.mercuriale-price-alert-meta {
  margin: 0;
  font-size: 0.8rem;
  line-height: 1.45;
  color: var(--ds-text-secondary, #475569);
}

html.ui-premium .mercuriale-price-percent,
.mercuriale-price-percent,
html.ui-premium .progress-job-percent,
.progress-job-percent {
  margin: -4px 0 0;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--ds-text-muted, #64748b);
  text-align: right;
}

html.ui-premium .mercuriale-price-steps,
.mercuriale-price-steps,
html.ui-premium .progress-job-steps,
.progress-job-steps {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 6px;
}

html.ui-premium .mercuriale-price-step,
.mercuriale-price-step {
  position: relative;
  padding: 6px 10px 6px 28px;
  border-radius: 10px;
  font-size: 0.78rem;
  line-height: 1.35;
  color: var(--ds-text-muted, #64748b);
  background: rgba(248, 250, 252, 0.9);
}

html.ui-premium .mercuriale-price-step::before,
.mercuriale-price-step::before {
  content: "";
  position: absolute;
  left: 10px;
  top: 50%;
  width: 8px;
  height: 8px;
  margin-top: -4px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.55);
}

html.ui-premium .mercuriale-price-step[data-state="active"],
.mercuriale-price-step[data-state="active"] {
  color: rgb(0, 95, 130);
  background: rgba(0, 149, 200, 0.1);
  font-weight: 650;
}

html.ui-premium .mercuriale-price-step[data-state="active"]::before,
.mercuriale-price-step[data-state="active"]::before {
  background: rgb(0, 149, 200);
  box-shadow: 0 0 0 3px rgba(0, 149, 200, 0.22);
}

html.ui-premium .mercuriale-price-step[data-state="done"],
.mercuriale-price-step[data-state="done"] {
  color: rgb(4, 100, 72);
  background: rgba(16, 185, 129, 0.08);
}

html.ui-premium .mercuriale-price-step[data-state="done"]::before,
.mercuriale-price-step[data-state="done"]::before {
  background: rgb(5, 150, 105);
}

html.ui-premium .mercuriale-price-elapsed,
.mercuriale-price-elapsed,
html.ui-premium .progress-job-elapsed,
.progress-job-elapsed {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 650;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ds-text-muted, #64748b);
}

html.ui-premium .mercuriale-price-actions,
.mercuriale-price-actions,
html.ui-premium .progress-job-actions,
.progress-job-actions {
  display: flex;
  justify-content: flex-end;
}

html.ui-premium .mercuriale-price-dismiss,
.mercuriale-price-dismiss,
html.ui-premium .progress-job-dismiss,
.progress-job-dismiss {
  margin: 0;
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: #fff;
  color: var(--ds-text, #0f172a);
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 650;
  cursor: pointer;
}

/* Synchro prix fournisseur : visible sur toute l’app (arrière-plan OK) */
html.ui-premium .topbar-supplier-sync-indicator {
  flex: 0 0 auto;
  max-width: min(185px, 20vw);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 6px 3px 8px;
  border-radius: 999px;
  border: 1px solid var(--ds-border);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(248, 250, 252, 0.94));
  box-shadow: var(--ds-shadow-xs);
  font-size: 0.62rem;
  line-height: var(--ds-leading-tight);
  color: var(--ds-text-secondary);
  white-space: nowrap;
  overflow: hidden;
  animation: topbar-supplier-sync-enter 0.45s ease-out;
}

html.ui-premium .topbar-supplier-sync-indicator[data-state="loading"] {
  border-color: rgba(37, 99, 235, 0.22);
  background: var(--ds-action-soft);
  color: var(--ds-text);
}

html.ui-premium .topbar-supplier-sync-indicator[data-state="success"] {
  border-color: rgba(5, 150, 105, 0.28);
  background: var(--ds-success-soft);
  color: var(--ds-text);
}

html.ui-premium .topbar-supplier-sync-indicator[data-state="partial"] {
  border-color: rgba(217, 119, 6, 0.32);
  background: var(--ds-warning-soft);
  color: var(--ds-text);
}

html.ui-premium .topbar-supplier-sync-indicator[data-state="error"] {
  border-color: rgba(220, 38, 38, 0.26);
  background: var(--ds-danger-soft);
  color: var(--ds-text);
}

html.ui-premium .topbar-supplier-sync-indicator-dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--ds-text-muted);
  flex-shrink: 0;
}

html.ui-premium .topbar-supplier-sync-indicator[data-state="loading"] .topbar-supplier-sync-indicator-dot {
  background: var(--ds-action);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.15);
  animation: topbar-supplier-sync-pulse 1.1s ease-in-out infinite;
}

html.ui-premium .topbar-supplier-sync-indicator[data-state="success"] .topbar-supplier-sync-indicator-dot {
  background: var(--ds-success);
}

html.ui-premium .topbar-supplier-sync-indicator[data-state="partial"] .topbar-supplier-sync-indicator-dot {
  background: var(--ds-warning);
}

html.ui-premium .topbar-supplier-sync-indicator[data-state="error"] .topbar-supplier-sync-indicator-dot {
  background: var(--ds-danger);
}

html.ui-premium .topbar-supplier-sync-indicator-body {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  overflow: hidden;
}

html.ui-premium .topbar-supplier-sync-indicator-text {
  width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

html.ui-premium .topbar-supplier-sync-indicator-errors-detail {
  flex-shrink: 0;
  align-self: flex-start;
  margin: 0;
  padding: 0;
  border: none;
  background: none;
  font: inherit;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
  opacity: 0.95;
}

html.ui-premium .topbar-supplier-sync-indicator-cancel,
.topbar-supplier-sync-cancel {
  margin: 0;
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid rgba(220, 38, 38, 0.45);
  background: rgba(255, 255, 255, 0.96);
  color: rgb(185, 28, 28);
  font-family: inherit;
  font-size: 0.58rem;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}

html.ui-premium .topbar-supplier-sync-indicator[data-state="loading"] .topbar-supplier-sync-cancel:hover,
.topbar-supplier-sync-indicator[data-state="loading"] .topbar-supplier-sync-cancel:hover {
  background: rgba(254, 226, 226, 0.9);
}

html.ui-premium .topbar-supplier-sync-indicator-errors-detail:hover {
  opacity: 1;
}

html.ui-premium .topbar-supplier-sync-indicator-errors-detail:focus-visible {
  outline: none;
  box-shadow: var(--ds-focus-ring);
  border-radius: 4px;
}

html.ui-premium .topbar-supplier-sync-indicator-dismiss {
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  padding: 0;
  border: none;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.06);
  color: var(--ds-text-secondary);
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
}

html.ui-premium .topbar-supplier-sync-indicator-dismiss:hover {
  background: rgba(15, 23, 42, 0.1);
}

@keyframes topbar-supplier-sync-pulse {
  0%,
  100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(0.86);
    opacity: 0.55;
  }
}

@keyframes topbar-supplier-sync-enter {
  from {
    opacity: 0;
    transform: translateY(-3px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

html.ui-premium .supplier-refresh-review-overlay {
  background: rgba(15, 23, 42, 0.42);
  backdrop-filter: blur(10px);
}

html.ui-premium .supplier-refresh-review-panel {
  width: min(100%, 560px);
  padding: 22px 24px;
  border-radius: var(--ds-radius-xl);
  border: 1px solid rgba(15, 23, 42, 0.08);
  box-shadow: 0 24px 48px rgba(15, 23, 42, 0.16);
}

html.ui-premium .supplier-refresh-review-title {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

html.ui-premium .supplier-refresh-review-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

html.ui-premium .supplier-refresh-review-stat {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: var(--ds-text-xs);
  font-weight: 700;
}

html.ui-premium .supplier-refresh-review-stat--ok {
  color: #166534;
  background: rgba(22, 163, 74, 0.12);
  border: 1px solid rgba(22, 163, 74, 0.22);
}

html.ui-premium .supplier-refresh-review-stat--error {
  color: #991b1b;
  background: rgba(220, 38, 38, 0.1);
  border: 1px solid rgba(220, 38, 38, 0.2);
}

html.ui-premium .supplier-refresh-global-error-banner {
  margin: 10px 2px 14px;
  padding: 12px 14px;
  border-radius: var(--ds-radius-md);
  border: 1px solid rgba(220, 38, 38, 0.25);
  background: var(--ds-danger-soft);
  color: var(--ds-text);
  font-size: var(--ds-text-sm);
  line-height: var(--ds-leading-normal);
}

html.ui-premium .topbar-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  min-width: 0;
  flex-wrap: nowrap;
  overflow: visible;
  scrollbar-width: none;
  position: relative;
  z-index: 65;
}

html.ui-premium .topbar-nav::-webkit-scrollbar {
  display: none;
}

html.ui-premium .app-topbar-right {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

html.ui-premium .topbar-icon-button {
  width: 34px;
  height: 34px;
  border: 1px solid var(--ds-border);
  border-radius: 999px;
  background: #fff;
  box-shadow: var(--ds-shadow-xs);
  cursor: pointer;
}

html.ui-premium .topbar-nav-item {
  min-height: 34px;
  padding: 0.34rem 0.7rem;
  border-radius: 10px;
  white-space: nowrap;
  transition: background-color var(--ds-duration-fast) var(--ds-ease-premium),
    color var(--ds-duration-fast) var(--ds-ease-premium),
    box-shadow var(--ds-duration-fast) var(--ds-ease-premium);
}

@media (max-width: 1360px) {
  html.ui-premium .topbar-supplier-sync-indicator {
    max-width: 145px;
  }

  html.ui-premium .topbar-bridge-indicator {
    max-width: min(240px, 52vw);
  }

  html.ui-premium .topbar-supplier-sync-indicator-errors-detail {
    display: none;
  }
}

html.ui-premium .topbar-nav-item .sidebar-icon-module {
  display: none;
}

html.ui-premium .topbar-nav .sidebar-nav-item::before,
html.ui-premium .topbar-nav .sidebar-nav-item[data-active="true"]::before {
  display: none;
  content: none;
}

html.ui-premium .topbar-profile-menu {
  position: relative;
}

html.ui-premium .topbar-profile-trigger {
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  min-height: 36px;
  padding: 4px 8px 4px 4px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 8px 20px rgba(15, 23, 42, 0.05);
  cursor: pointer;
  transition: box-shadow var(--ds-duration-fast) var(--ds-ease-premium),
    border-color var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium .topbar-profile-trigger:hover {
  border-color: rgba(37, 99, 235, 0.18);
  box-shadow: var(--ds-shadow-panel);
}

html.ui-premium .topbar-profile-avatar {
  width: 27px;
  height: 27px;
}

html.ui-premium .topbar-profile-name {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--ds-text);
}

html.ui-premium .topbar-profile-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  min-width: 170px;
  padding: 6px;
  border-radius: 12px;
  border: 1px solid var(--ds-border);
  background: #fff;
  box-shadow: var(--ds-shadow-sm);
  display: none;
}

html.ui-premium .topbar-profile-menu:focus-within .topbar-profile-dropdown,
html.ui-premium .topbar-profile-menu:hover .topbar-profile-dropdown {
  display: grid;
  gap: 4px;
}

html.ui-premium .topbar-profile-dropdown-item {
  border: 0;
  background: transparent;
  text-align: left;
  border-radius: 8px;
  padding: 8px;
  color: var(--ds-text-secondary);
  font-size: 0.8rem;
  cursor: pointer;
}

html.ui-premium .topbar-profile-dropdown-item:hover {
  background: rgba(15, 23, 42, 0.05);
}

html.ui-premium .topbar-nav-item-wrap {
  position: relative;
  display: inline-flex;
  align-items: stretch;
  flex-shrink: 0;
}

html.ui-premium .topbar-nav-submenu {
  position: absolute;
  top: calc(100% - 2px);
  left: 0;
  transform: none;
  min-width: max(100%, 200px);
  max-width: min(320px, 92vw);
  max-height: min(70vh, 360px);
  overflow-y: auto;
  overflow-x: hidden;
  padding: 6px;
  border-radius: 10px;
  border: 1px solid var(--ds-border);
  background: #fff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.12);
  display: none;
  grid-template-columns: 1fr;
  gap: 1px;
  z-index: 60;
}

html.ui-premium .topbar-nav-submenu::before {
  content: "";
  position: absolute;
  left: -14px;
  right: -14px;
  top: -18px;
  height: 18px;
}

html.ui-premium .topbar-nav-item-wrap:hover .topbar-nav-submenu,
html.ui-premium .topbar-nav-item-wrap:focus-within .topbar-nav-submenu {
  display: grid;
}

html.ui-premium .topbar-nav-submenu-item {
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 0.46rem 0.72rem;
  min-height: 34px;
  background: transparent;
  color: var(--ds-text-secondary);
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  white-space: normal;
  line-height: 1.3;
  transition: 140ms ease;
  width: 100%;
  text-align: left;
}

html.ui-premium .topbar-nav-submenu-item:hover {
  border-color: var(--ds-border);
  background: rgba(15, 23, 42, 0.04);
}

html.ui-premium .topbar-nav-submenu-item[data-active="true"] {
  border-color: rgba(37, 99, 235, 0.3);
  background: rgba(37, 99, 235, 0.08);
  color: var(--ds-action-hover);
}

html.ui-premium .sidebar-nav-item {
  border-radius: var(--ds-radius-md);
  border: 1px solid transparent;
  color: var(--ds-text-secondary);
  transition: background-color 140ms ease, border-color 140ms ease, color 140ms ease;
}

html.ui-premium .sidebar-nav-item:hover {
  background: rgba(15, 23, 42, 0.04);
}

html.ui-premium .sidebar-nav-item[data-active="true"] {
  background: var(--ds-action-soft);
  border-color: rgba(37, 99, 235, 0.22);
  color: var(--ds-text);
}

html.ui-premium .sidebar-nav-item[data-active="true"] .sidebar-nav-item-label {
  color: var(--ds-text);
  font-weight: 600;
}

/* -------------------------------------------------------------------------- */
/* Zone principale & panneaux                                                 */
/* -------------------------------------------------------------------------- */
html.ui-premium .views-stack > .view-panel {
  background: var(--ds-bg-elevated);
  border: 1px solid var(--ds-border);
  border-radius: var(--ds-radius-xl);
  box-shadow: var(--ds-shadow-sm);
  color: var(--ds-text);
}

html.ui-premium .views-stack .panel {
  background: var(--ds-bg-elevated);
  border: 1px solid var(--ds-border);
  border-radius: var(--ds-radius-lg);
  box-shadow: var(--ds-shadow-xs);
  color: var(--ds-text);
}

/* Titres : bleu identité Camping Paradis (lisible sur fond clair). */
html.ui-premium .dashboard-section-title,
html.ui-premium #dashboard-view .panel-head h2.dashboard-section-title {
  color: var(--ds-camping-paradis-blue);
  font-weight: 800;
  font-size: clamp(0.95rem, 1.2vw, 1.12rem);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

html.ui-premium .panel-head h2:not(.dashboard-section-title),
html.ui-premium .radar-title,
html.ui-premium .simulator-title,
html.ui-premium .pricing-advisor-title {
  color: var(--ds-camping-paradis-blue);
  font-weight: 650;
  letter-spacing: 0.04em;
}

html.ui-premium #overview-view .panel-head h2,
html.ui-premium .supplier-alert-section-title,
html.ui-premium .module-placeholder-title,
html.ui-premium .settings-panel-title,
html.ui-premium .dashboard-chart-title,
html.ui-premium .dashboard-action-title,
html.ui-premium .dashboard-category-title,
html.ui-premium .dashboard-data-footer-title {
  color: var(--ds-camping-paradis-blue);
}

html.ui-premium .restaurant-view-header {
  color: var(--ds-text);
}

html.ui-premium .restaurant-view-title {
  color: var(--ds-camping-paradis-blue);
  font-weight: 650;
}

html.ui-premium #module-placeholder.is-settings-module,
html.ui-premium .module-placeholder.is-settings-module {
  margin-inline: auto;
  justify-items: center;
}

html.ui-premium .is-settings-module .settings-tab-content {
  justify-items: center;
  width: 100%;
}

html.ui-premium .is-settings-module .settings-tab-content > * {
  width: min(100%, 780px);
}

html.ui-premium .is-settings-module .settings-margin-groups,
html.ui-premium .is-settings-module .settings-priority-summary,
html.ui-premium .is-settings-module .settings-priority-groups,
html.ui-premium .is-settings-module .settings-sysco-readiness {
  width: min(100%, 920px);
}

html.ui-premium .settings-sysco-readiness {
  display: grid;
  gap: 14px;
  padding: 16px;
  border-radius: var(--ds-radius-lg);
  border: 1px solid var(--ds-border);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(248, 250, 252, 0.94));
  box-shadow: var(--ds-shadow-xs);
}

html.ui-premium .settings-sysco-readiness-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

html.ui-premium .settings-sysco-readiness-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
  flex: 1 1 280px;
}

html.ui-premium .settings-sysco-readiness-title {
  font-size: 0.94rem;
  font-weight: 700;
  color: var(--ds-text);
}

html.ui-premium .settings-sysco-readiness-subtitle {
  margin: 0;
  font-size: 0.8rem;
  line-height: 1.45;
  color: var(--ds-text-secondary);
  max-width: 62ch;
}

html.ui-premium .settings-sysco-readiness-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

html.ui-premium .settings-sysco-readiness-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
}

html.ui-premium .settings-sysco-readiness-stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 10px 12px;
  border-radius: var(--ds-radius-md);
  border: 1px solid var(--ds-border);
  background: rgba(248, 250, 252, 0.94);
}

html.ui-premium .settings-sysco-readiness-stat-label {
  font-size: 0.74rem;
  color: var(--ds-text-secondary);
  font-weight: 600;
  letter-spacing: 0.01em;
}

html.ui-premium .settings-sysco-readiness-stat-value {
  font-size: 1.4rem;
  font-weight: 750;
  color: var(--ds-text);
  letter-spacing: -0.01em;
}

html.ui-premium .settings-sysco-readiness-stat-success {
  border-color: rgba(5, 150, 105, 0.32);
  background: var(--ds-success-soft);
}

html.ui-premium .settings-sysco-readiness-stat-success .settings-sysco-readiness-stat-value {
  color: rgb(5, 150, 105);
}

html.ui-premium .settings-sysco-readiness-stat-warning {
  border-color: rgba(217, 119, 6, 0.32);
  background: var(--ds-warning-soft);
}

html.ui-premium .settings-sysco-readiness-stat-warning .settings-sysco-readiness-stat-value {
  color: rgb(180, 83, 9);
}

html.ui-premium .settings-sysco-readiness-toggle-row {
  display: flex;
  justify-content: flex-start;
}

html.ui-premium .settings-sysco-readiness-detail {
  display: grid;
  gap: 10px;
  padding: 12px;
  border-radius: var(--ds-radius-md);
  border: 1px dashed rgba(217, 119, 6, 0.35);
  background: rgba(254, 252, 232, 0.6);
}

html.ui-premium .settings-sysco-readiness-detail-subtitle {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--ds-text-secondary);
}

html.ui-premium .settings-sysco-readiness-detail-list {
  display: grid;
  gap: 8px;
}

html.ui-premium .settings-sysco-readiness-row {
  display: grid;
  grid-template-columns: minmax(180px, 1.4fr) minmax(160px, 2fr) auto;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--ds-radius-md);
  border: 1px solid var(--ds-border);
  background: #ffffff;
}

html.ui-premium .settings-sysco-readiness-row-main {
  display: grid;
  gap: 2px;
  min-width: 0;
}

html.ui-premium .settings-sysco-readiness-row-name {
  font-size: 0.86rem;
  font-weight: 650;
  color: var(--ds-text);
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
}

html.ui-premium .settings-sysco-readiness-row-ref {
  font-size: 0.74rem;
  color: var(--ds-text-secondary);
}

html.ui-premium .settings-sysco-readiness-row-missing {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

html.ui-premium .settings-sysco-readiness-row-tag {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}

html.ui-premium .settings-sysco-readiness-row-tag-blocking {
  background: rgba(220, 38, 38, 0.1);
  color: rgb(185, 28, 28);
  border: 1px solid rgba(220, 38, 38, 0.25);
}

html.ui-premium .settings-sysco-readiness-row-tag-soft {
  background: rgba(217, 119, 6, 0.08);
  color: rgb(146, 64, 14);
  border: 1px solid rgba(217, 119, 6, 0.22);
}

html.ui-premium .settings-sysco-readiness-row-actions {
  display: flex;
  justify-content: flex-end;
}

html.ui-premium .settings-priority-badges {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

html.ui-premium .settings-readiness-pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 650;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

html.ui-premium .settings-readiness-pill-ready {
  background: var(--ds-success-soft);
  color: rgb(5, 150, 105);
  border: 1px solid rgba(5, 150, 105, 0.28);
}

html.ui-premium .settings-readiness-pill-to-complete {
  background: var(--ds-warning-soft);
  color: rgb(180, 83, 9);
  border: 1px solid rgba(217, 119, 6, 0.32);
}

html.ui-premium .mercuriale-readiness-pill {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  margin-top: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 650;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: filter 0.12s ease, box-shadow 0.12s ease;
}

html.ui-premium .mercuriale-readiness-pill-to-complete {
  background: var(--ds-warning-soft);
  color: rgb(180, 83, 9);
  border: 1px solid rgba(217, 119, 6, 0.32);
}

html.ui-premium .mercuriale-readiness-pill-to-complete:hover {
  filter: brightness(0.97);
  box-shadow: 0 1px 4px rgba(217, 119, 6, 0.18);
}

@media (max-width: 720px) {
  html.ui-premium .settings-sysco-readiness-row {
    grid-template-columns: 1fr;
  }
  html.ui-premium .settings-sysco-readiness-row-actions {
    justify-content: flex-start;
  }
}

html.ui-premium .settings-panel-header {
  display: grid;
  gap: 6px;
  margin-bottom: 14px;
}

html.ui-premium .is-settings-module .settings-panel-header {
  text-align: center;
  justify-items: center;
}

html.ui-premium .settings-panel-copy {
  margin: 0;
  font-size: 0.84rem;
  line-height: 1.45;
  color: var(--ds-text-secondary);
  max-width: 62ch;
}

html.ui-premium .is-settings-module .settings-panel-copy {
  margin-inline: auto;
  text-align: center;
}

html.ui-premium .is-settings-module .settings-bridge-actions,
html.ui-premium .is-settings-module .settings-bridge-sync-actions {
  justify-content: center;
}

html.ui-premium .settings-bridge-status-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  border-radius: var(--ds-radius-lg);
  border: 1px solid var(--ds-border);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(248, 250, 252, 0.94));
  box-shadow: var(--ds-shadow-xs);
}

html.ui-premium .settings-bridge-status-card[data-state="up"] {
  border-color: rgba(5, 150, 105, 0.28);
  background: var(--ds-success-soft);
}

html.ui-premium .settings-bridge-status-card[data-state="down"] {
  border-color: rgba(220, 38, 38, 0.24);
  background: rgba(254, 242, 242, 0.92);
}

html.ui-premium .settings-bridge-status-card[data-state="checking"] {
  border-color: rgba(217, 119, 6, 0.28);
  background: var(--ds-warning-soft);
}

html.ui-premium .settings-bridge-status-dot {
  flex: 0 0 auto;
  width: 11px;
  height: 11px;
  margin-top: 4px;
  border-radius: 50%;
  background: rgba(148, 163, 184, 0.8);
}

html.ui-premium .settings-bridge-status-card[data-state="up"] .settings-bridge-status-dot {
  background: rgb(5, 150, 105);
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.18);
}

html.ui-premium .settings-bridge-status-card[data-state="down"] .settings-bridge-status-dot {
  background: rgb(220, 38, 38);
  box-shadow: 0 0 0 4px rgba(248, 113, 113, 0.2);
}

html.ui-premium .settings-bridge-status-card[data-state="checking"] .settings-bridge-status-dot {
  background: rgb(217, 119, 6);
  animation: settings-bridge-pulse 1.1s ease-in-out infinite;
}

@keyframes settings-bridge-pulse {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.55;
    transform: scale(0.92);
  }
}

html.ui-premium .settings-bridge-status-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

html.ui-premium .settings-bridge-status-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--ds-text);
}

html.ui-premium .settings-bridge-status-detail {
  font-size: 0.8rem;
  line-height: 1.4;
  color: var(--ds-text-secondary);
}

html.ui-premium .settings-bridge-actions,
html.ui-premium .settings-bridge-sync-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

html.ui-premium .settings-bridge-action-primary {
  flex: 0 0 auto;
}

html.ui-premium .settings-bridge-action-secondary,
html.ui-premium .settings-bridge-action-ghost {
  appearance: none;
  -webkit-appearance: none;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: #fff;
  color: var(--ds-text);
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 650;
  cursor: pointer;
}

html.ui-premium .settings-bridge-action-secondary {
  border-color: rgba(180, 83, 9, 0.35);
  color: rgb(146, 64, 14);
  background: rgba(255, 251, 235, 0.95);
}

html.ui-premium .settings-bridge-action-secondary:hover:not(:disabled),
html.ui-premium .settings-bridge-action-ghost:hover:not(:disabled) {
  border-color: rgba(0, 127, 174, 0.35);
  background: rgba(0, 149, 200, 0.08);
}

html.ui-premium .settings-bridge-action-secondary:disabled,
html.ui-premium .settings-bridge-action-ghost:disabled {
  opacity: 0.55;
  cursor: default;
}

html.ui-premium .settings-bridge-sync-block {
  margin-top: 16px;
  padding: 12px 14px;
  border-radius: var(--ds-radius-lg);
  border: 1px solid rgba(37, 99, 235, 0.18);
  background: var(--ds-action-soft);
}

html.ui-premium .settings-bridge-sync-block[data-state="success"] {
  border-color: rgba(5, 150, 105, 0.28);
  background: var(--ds-success-soft);
}

html.ui-premium .settings-bridge-sync-block[data-state="partial"] {
  border-color: rgba(217, 119, 6, 0.32);
  background: var(--ds-warning-soft);
}

html.ui-premium .settings-bridge-sync-block[data-state="error"] {
  border-color: rgba(220, 38, 38, 0.24);
  background: rgba(254, 242, 242, 0.92);
}

html.ui-premium .settings-bridge-sync-head {
  display: grid;
  gap: 4px;
}

html.ui-premium .settings-bridge-sync-text {
  font-size: 0.8rem;
  line-height: 1.4;
  color: var(--ds-text-secondary);
}

html.ui-premium .settings-bridge-hint {
  margin: 14px 0 0;
  font-size: 0.74rem;
  line-height: 1.45;
  color: var(--ds-text-muted);
}

html.ui-premium .supplier-sysco-catalog-meta {
  margin: 0;
  padding: 8px 10px;
  border-radius: var(--ds-radius-md);
  border: 1px dashed rgba(0, 127, 174, 0.28);
  background: rgba(0, 149, 200, 0.06);
  font-size: 0.76rem;
  line-height: 1.45;
  color: var(--ds-text-secondary);
}

/* Onglets vues restaurant (pilote) */
html.ui-premium .restaurant-view-tabs {
  --overview-sticky-top: 72px;
  --overview-tabs-stack-height: 52px;
  --overview-sticky-gap: 8px;
  gap: var(--ds-space-2);
  padding: var(--ds-space-2);
  background:
    radial-gradient(120% 140% at 0% 0%, rgba(0, 149, 200, 0.12) 0%, rgba(0, 149, 200, 0) 48%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.92) 0%, rgba(247, 250, 255, 0.88) 100%);
  border: 1px solid rgba(15, 23, 42, 0.1);
  border-radius: var(--ds-radius-lg);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.65),
    0 8px 22px rgba(15, 23, 42, 0.08),
    0 1px 0 rgba(15, 23, 42, 0.05);
  position: sticky;
  top: var(--overview-sticky-top);
  z-index: 34;
  backdrop-filter: blur(10px) saturate(120%);
  margin-bottom: 0;
}

html.ui-premium .restaurant-view-tabs::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: inherit;
  background-image: linear-gradient(
    115deg,
    rgba(255, 255, 255, 0.34) 0%,
    rgba(255, 255, 255, 0) 42%
  );
}

html.ui-premium .restaurant-view-tabs button {
  border-radius: var(--ds-radius-md);
  border: 1px solid rgba(15, 23, 42, 0.04);
  background: rgba(255, 255, 255, 0.5);
  color: var(--ds-text-secondary);
  font-weight: 600;
  font-size: var(--ds-text-sm);
  padding: var(--ds-space-2) var(--ds-space-4);
  min-height: 36px;
  transition: background-color 140ms ease, color 140ms ease, border-color 140ms ease, box-shadow 140ms ease;
}

html.ui-premium .restaurant-view-tabs button:hover {
  border-color: rgba(37, 99, 235, 0.24);
  background: rgba(255, 255, 255, 0.82);
  color: var(--ds-text);
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.06);
}

html.ui-premium .restaurant-view-tabs button[data-active="true"] {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(240, 247, 255, 0.96) 100%);
  border-color: rgba(37, 99, 235, 0.3);
  color: #0b3c68;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.55),
    0 6px 16px rgba(37, 99, 235, 0.16);
}

html.ui-premium .restaurant-margins-sticky-chrome {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  min-height: 40px;
  margin-bottom: 10px;
  padding: 0;
  background: transparent;
  border: none;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

html.ui-premium .restaurant-margins-sticky-chrome .restaurant-margins-back-toolbar {
  grid-column: 1;
  justify-self: start;
}

html.ui-premium .restaurant-margins-sticky-chrome .settings-tabs.restaurant-view-tabs {
  grid-column: 2;
  justify-self: center;
  position: relative;
  left: auto;
  top: auto;
  transform: none;
  justify-content: center;
}

html.ui-premium .restaurant-margins-sticky-chrome:hover {
  border-color: transparent;
  box-shadow: none;
}

html.ui-premium .restaurant-margins-sticky-chrome .settings-tabs.restaurant-view-tabs {
  scrollbar-color: rgba(37, 99, 235, 0.28) transparent;
  transition:
    background 180ms ease,
    box-shadow 180ms ease,
    border-color 180ms ease;
}

html.ui-premium .restaurant-margins-sticky-chrome .settings-tabs.restaurant-view-tabs:hover {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.94) 0%, rgba(247, 250, 255, 0.9) 100%);
  border-color: rgba(37, 99, 235, 0.16);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.72),
    0 8px 20px rgba(15, 23, 42, 0.07);
}

html.ui-premium .restaurant-margins-sticky-chrome .settings-tabs.restaurant-view-tabs .settings-tab-button.restaurant-view-tab {
  transition:
    transform 160ms cubic-bezier(0.22, 1, 0.36, 1),
    background-color 160ms ease,
    color 160ms ease,
    border-color 160ms ease,
    box-shadow 160ms ease;
}

html.ui-premium .restaurant-margins-sticky-chrome .settings-tabs.restaurant-view-tabs .settings-tab-button.restaurant-view-tab:hover {
  border-color: rgba(37, 99, 235, 0.28);
  background: rgba(255, 255, 255, 0.88);
  color: var(--ds-text);
  box-shadow: 0 5px 14px rgba(15, 23, 42, 0.08);
}

html.ui-premium .restaurant-margins-sticky-chrome .settings-tabs.restaurant-view-tabs .settings-tab-button.restaurant-view-tab[data-active="true"]:hover {
  border-color: rgba(37, 99, 235, 0.38);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.55),
    0 8px 20px rgba(37, 99, 235, 0.18);
}

html.ui-premium .restaurant-margins-sticky-chrome .settings-tabs.restaurant-view-tabs .settings-tab-button.restaurant-view-tab:focus-visible {
  outline: 2px solid rgba(37, 99, 235, 0.45);
  outline-offset: 2px;
}

html.ui-premium .restaurant-margins-sticky-chrome .restaurant-margins-back-toolbar .app-back-button:focus-visible {
  outline: 2px solid rgba(37, 99, 235, 0.45);
  outline-offset: 2px;
}

html.ui-premium .restaurant-margins-sticky-chrome .app-back-button .app-back-label {
  color: var(--ds-text-muted);
  font-weight: 500;
  font-size: 0.6rem;
}

/* -------------------------------------------------------------------------- */
/* Boutons : primaire / secondaire (classes existantes)                       */
/* -------------------------------------------------------------------------- */
html.ui-premium .dashboard-refresh-button,
html.ui-premium .dashboard-link-button,
html.ui-premium .dashboard-history-link-button,
html.ui-premium .dashboard-history-back-button,
html.ui-premium .app-back-button {
  border-radius: var(--ds-radius-md);
  font-weight: 600;
  font-size: var(--ds-text-sm);
  border: 1px solid var(--ds-border-strong);
  background: #ffffff;
  color: var(--ds-text);
  box-shadow: var(--ds-shadow-xs);
  transition: border-color 140ms ease, background-color 140ms ease, box-shadow 140ms ease;
}

html.ui-premium .dashboard-refresh-button:hover,
html.ui-premium .dashboard-link-button:hover,
html.ui-premium .dashboard-history-link-button:hover,
html.ui-premium .dashboard-history-back-button:hover,
html.ui-premium .app-back-button:hover {
  border-color: rgba(37, 99, 235, 0.35);
  background: #fafbff;
}

html.ui-premium .restaurant-margins-sticky-chrome .app-back-button {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  height: 34px;
  min-height: 0;
  padding: 0 12px 0 10px;
  font-weight: 600;
  font-size: var(--ds-text-sm);
  border-radius: var(--ds-radius-md);
  background: #ffffff;
  border: 1px solid var(--ds-border-strong);
  box-shadow: var(--ds-shadow-xs);
}

html.ui-premium .restaurant-margins-sticky-chrome .app-back-title {
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
}

html.ui-premium .dashboard-refresh-button-secondary,
html.ui-premium .dashboard-refresh-button-compact {
  background: #ffffff;
  color: var(--ds-text-secondary);
}

html.ui-premium .dashboard-refresh-button-primary,
html.ui-premium .editor-save-button {
  background: var(--ds-action);
  border-color: rgba(37, 99, 235, 0.45);
  color: #ffffff;
  box-shadow: var(--ds-shadow-xs);
}

html.ui-premium .dashboard-refresh-button-primary:hover,
html.ui-premium .editor-save-button:hover {
  background: var(--ds-action-hover);
  border-color: rgba(29, 78, 216, 0.55);
}

html.ui-premium .dashboard-refresh-button:disabled,
html.ui-premium .editor-save-button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

/* -------------------------------------------------------------------------- */
/* Filtres & onglets de sections (carte, détail, mercuriale…)                 */
/* -------------------------------------------------------------------------- */
html.ui-premium .section-tab,
html.ui-premium .supplier-filter,
html.ui-premium .purchase-category-chip,
html.ui-premium .purchase-category-chip-sub {
  border-radius: var(--ds-radius-md);
  border: 1px solid var(--ds-border);
  background: #ffffff;
  color: var(--ds-text-secondary);
  font-weight: 600;
  font-size: var(--ds-text-sm);
  box-shadow: none;
  min-height: 38px;
}

html.ui-premium .section-tab[data-active="true"],
html.ui-premium .supplier-filter[data-active="true"],
html.ui-premium .purchase-category-chip[data-active="true"] {
  background: var(--ds-action);
  border-color: rgba(37, 99, 235, 0.45);
  color: #ffffff;
  box-shadow: var(--ds-shadow-xs);
}

html.ui-premium .dish-card-link {
  border-radius: var(--ds-radius-md);
  border: 1px solid var(--ds-border-strong);
  background: #ffffff;
  color: var(--ds-action);
  font-weight: 600;
  font-size: var(--ds-text-sm);
  box-shadow: var(--ds-shadow-xs);
}

html.ui-premium .dish-card-link:hover {
  border-color: rgba(37, 99, 235, 0.35);
  background: #fafbff;
}

/* -------------------------------------------------------------------------- */
/* Cartes KPI dashboard                                                       */
/* -------------------------------------------------------------------------- */
html.ui-premium .dashboard-kpi-card {
  background: #ffffff;
  border: 1px solid var(--ds-border);
  border-radius: var(--ds-radius-lg);
  box-shadow: var(--ds-shadow-xs);
}

html.ui-premium #dashboard-view .dashboard-kpi-card {
  text-align: center;
  justify-items: center;
}

html.ui-premium #dashboard-view .dashboard-kpi-card::before,
html.ui-premium #dashboard-view .dashboard-kpi-card::after {
  display: none;
}

html.ui-premium #dashboard-view .dashboard-kpi-label {
  justify-self: center;
  text-align: center;
  width: 100%;
}

html.ui-premium #dashboard-view .dashboard-kpi-value {
  display: block;
  width: 100%;
  text-align: center;
  font-weight: 800;
  letter-spacing: -0.03em;
}

html.ui-premium #dashboard-view .dashboard-kpi-card-good .dashboard-kpi-value {
  color: #059669;
}

html.ui-premium #dashboard-view .dashboard-kpi-card-alert .dashboard-kpi-value {
  color: #d97706;
}

html.ui-premium #dashboard-view .dashboard-kpi-card-danger .dashboard-kpi-value {
  color: #dc2626;
}

html.ui-premium #dashboard-view .dashboard-kpi-card-neutral .dashboard-kpi-value {
  color: var(--ds-text);
}

html.ui-premium #dashboard-view .dashboard-kpi-footer {
  justify-items: center;
  width: 100%;
}

html.ui-premium #dashboard-view .dashboard-kpi-trend {
  text-align: center;
  justify-self: center;
}

/* « Donnée provisoire » : bleu type Camping Paradis (pas le bleu action SaaS) */
html.ui-premium #dashboard-view .dashboard-kpi-trend-provisional {
  color: var(--ds-camping-paradis-blue) !important;
  background: var(--ds-camping-paradis-blue-soft);
  border: 1px solid rgba(0, 149, 200, 0.28);
}

html.ui-premium .dashboard-kpi-label {
  color: var(--ds-text-muted);
  font-size: var(--ds-text-xs);
  font-weight: 600;
  letter-spacing: 0.06em;
}

/* -------------------------------------------------------------------------- */
/* Tableaux mercuriale                                                        */
/* -------------------------------------------------------------------------- */
html.ui-premium .mercuriale-table-shell {
  border: 1px solid var(--ds-border);
  border-radius: var(--ds-radius-lg);
  background: #ffffff;
  box-shadow: var(--ds-shadow-xs);
}

html.ui-premium .mercuriale-head-cell {
  color: var(--ds-text-muted);
  font-size: var(--ds-text-xs);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

html.ui-premium .mercuriale-row {
  border-color: var(--ds-border);
}

html.ui-premium .mercuriale-row-shell[data-expanded="true"] {
  box-shadow: var(--ds-shadow-sm);
}

html.ui-premium .mercuriale-admin-tabs {
  display: inline-flex;
  gap: 8px;
  padding: 4px;
  border-radius: 12px;
  border: 1px solid var(--ds-border);
  background: rgba(255, 255, 255, 0.88);
  margin: 8px 0 10px;
}

html.ui-premium #purchases-view .mercuriale-admin-tabs {
  margin: 4px 0 8px;
}

html.ui-premium .mercuriale-admin-tab {
  min-height: 32px;
  border-radius: 9px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--ds-text-secondary);
  font-size: 0.72rem;
  font-weight: 620;
  padding: 0 12px;
}

html.ui-premium .mercuriale-admin-tab[data-active="true"] {
  border-color: rgba(0, 149, 200, 0.28);
  background: rgba(0, 149, 200, 0.1);
  color: var(--ds-camping-paradis-blue);
}

html.ui-premium .mercuriale-category-admin-shell {
  border-radius: 16px;
  border: 1px solid var(--ds-border);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--ds-shadow-xs);
  padding: 16px;
  display: grid;
  gap: 14px;
}

html.ui-premium .mercuriale-category-admin-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

html.ui-premium .mercuriale-category-admin-head-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

html.ui-premium .mercuriale-category-admin-title {
  font-size: 0.9rem;
  font-weight: 650;
  color: var(--ds-text);
  letter-spacing: -0.005em;
}

html.ui-premium .mercuriale-category-admin-note {
  font-size: 0.74rem;
  color: var(--ds-text-muted);
  line-height: 1.45;
}

html.ui-premium .mercuriale-category-admin-add-main {
  min-height: 34px;
  padding: 0 14px;
  font-size: 0.78rem;
  border-radius: 9px;
  white-space: nowrap;
}

html.ui-premium .mercuriale-category-admin-head-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}

html.ui-premium .mercuriale-category-admin-reset-all {
  min-height: 34px;
  padding: 0 14px;
  font-size: 0.78rem;
  border-radius: 9px;
  white-space: nowrap;
  border-style: dashed;
}

html.ui-premium .mercuriale-category-admin-tree {
  display: grid;
  gap: 10px;
}

html.ui-premium .mercuriale-category-card {
  border: 1px solid var(--ds-border);
  border-radius: 12px;
  background: #ffffff;
  overflow: hidden;
  transition:
    border-color 0.12s ease,
    box-shadow 0.15s ease,
    background-color 0.12s ease;
}

html.ui-premium .mercuriale-category-card[data-expanded="true"] {
  border-color: rgba(0, 149, 200, 0.32);
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.06);
}

html.ui-premium .mercuriale-category-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  background: rgba(247, 249, 252, 0.7);
}

html.ui-premium .mercuriale-category-card[data-expanded="true"] .mercuriale-category-card-header {
  background: rgba(0, 149, 200, 0.06);
}

html.ui-premium .mercuriale-category-card-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  padding: 0;
  border-radius: 8px;
  border: 1px solid var(--ds-border);
  background: #ffffff;
  color: var(--ds-text-secondary);
  cursor: pointer;
  font: inherit;
  transition:
    border-color 0.12s ease,
    color 0.12s ease,
    background-color 0.12s ease,
    box-shadow 0.12s ease;
}

html.ui-premium .mercuriale-category-card-toggle:hover {
  border-color: rgba(0, 149, 200, 0.45);
  background: rgba(0, 149, 200, 0.08);
  color: var(--ds-camping-paradis-blue, #007aa8);
}

html.ui-premium .mercuriale-category-card-toggle:focus-visible {
  outline: none;
  box-shadow: var(--ds-focus-ring);
}

html.ui-premium .mercuriale-category-card[data-expanded="true"] .mercuriale-category-card-toggle {
  background: rgba(0, 149, 200, 0.12);
  border-color: rgba(0, 149, 200, 0.55);
  color: var(--ds-camping-paradis-blue, #007aa8);
}

html.ui-premium .mercuriale-category-card-caret {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 14px;
  height: 14px;
  line-height: 1;
  font-size: 0.85rem;
  transition: transform 0.18s ease;
}

html.ui-premium .mercuriale-category-card[data-expanded="true"] .mercuriale-category-card-caret {
  transform: rotate(90deg);
}

html.ui-premium .mercuriale-category-card-name-wrap {
  display: grid;
  gap: 2px;
  min-width: 0;
  flex: 1 1 auto;
}

html.ui-premium .mercuriale-category-card-name {
  font-size: 0.86rem;
  font-weight: 650;
  color: var(--ds-text);
  letter-spacing: -0.005em;
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
}

html.ui-premium .mercuriale-category-card-count {
  font-size: 0.7rem;
  color: var(--ds-text-muted);
  font-weight: 500;
}

html.ui-premium .mercuriale-category-card-actions {
  display: inline-flex;
  gap: 6px;
  flex-shrink: 0;
}

html.ui-premium .mercuriale-category-action {
  min-height: 28px;
  padding: 0 10px;
  font-size: 0.7rem;
  border-radius: 7px;
}

html.ui-premium .mercuriale-category-action--danger {
  color: var(--ds-danger, #b91c1c);
  border-color: rgba(220, 38, 38, 0.22);
}

html.ui-premium .mercuriale-category-action--danger:hover {
  background: rgba(220, 38, 38, 0.05);
  border-color: rgba(220, 38, 38, 0.4);
  color: var(--ds-danger, #b91c1c);
}

html.ui-premium .mercuriale-category-card-body {
  padding: 10px 12px 14px;
  display: grid;
  gap: 10px;
}

html.ui-premium .mercuriale-category-card[data-expanded="false"] .mercuriale-category-card-body {
  display: none;
}

html.ui-premium .mercuriale-category-card-body[hidden] {
  display: none;
}

html.ui-premium .mercuriale-category-subcategory-list {
  display: grid;
  gap: 6px;
}

html.ui-premium .mercuriale-category-subcategory-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 12px;
  border-radius: 8px;
  background: rgba(247, 249, 252, 0.8);
  border: 1px solid transparent;
  transition: background-color 0.12s ease, border-color 0.12s ease;
}

html.ui-premium .mercuriale-category-subcategory-row:hover {
  background: rgba(0, 149, 200, 0.05);
  border-color: rgba(0, 149, 200, 0.15);
}

html.ui-premium .mercuriale-category-subcategory-info {
  display: grid;
  gap: 2px;
  min-width: 0;
}

html.ui-premium .mercuriale-category-subcategory-name {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--ds-text);
}

html.ui-premium .mercuriale-category-subcategory-count {
  font-size: 0.66rem;
  color: var(--ds-text-muted);
}

html.ui-premium .mercuriale-category-subcategory-actions {
  display: inline-flex;
  gap: 6px;
  flex-shrink: 0;
}

html.ui-premium .mercuriale-category-subcategory-empty {
  margin: 0;
  padding: 8px 4px;
  font-size: 0.74rem;
  color: var(--ds-text-muted);
}

html.ui-premium .mercuriale-category-add-sub {
  justify-self: start;
  margin-top: 4px;
  border-style: dashed;
  font-size: 0.74rem;
}

html.ui-premium .mercuriale-category-add-sub:hover {
  border-color: rgba(0, 149, 200, 0.45);
  background: rgba(0, 149, 200, 0.06);
  color: var(--ds-action, #007aa8);
}

html.ui-premium .mercuriale-category-admin-empty {
  margin: 0;
  padding: 16px;
  text-align: center;
  font-size: 0.78rem;
  color: var(--ds-text-muted);
  border: 1px dashed var(--ds-border);
  border-radius: 12px;
  background: rgba(247, 249, 252, 0.7);
}

@media (max-width: 600px) {
  html.ui-premium .mercuriale-category-card-header {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }
  html.ui-premium .mercuriale-category-card-actions {
    justify-content: flex-end;
  }
}

html.ui-premium .mercuriale-row-menu {
  position: relative;
  margin-left: auto;
}

html.ui-premium .mercuriale-row-menu-trigger {
  min-width: 34px;
  min-height: 34px;
  border-radius: 10px;
  border: 1px solid var(--ds-border);
  background: rgba(255, 255, 255, 0.95);
  color: var(--ds-text-secondary);
  font-size: 1rem;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--ds-shadow-xs);
  transition: background-color 140ms ease, border-color 140ms ease, box-shadow 140ms ease;
}

html.ui-premium .mercuriale-row-menu-trigger:hover,
html.ui-premium .mercuriale-row-menu-trigger[aria-expanded="true"] {
  border-color: rgba(0, 149, 200, 0.35);
  background: rgba(0, 149, 200, 0.08);
  color: var(--ds-camping-paradis-blue);
}

html.ui-premium .mercuriale-row-menu-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  z-index: 4;
  min-width: 170px;
  padding: 6px;
  border-radius: 10px;
  border: 1px solid var(--ds-border);
  background: rgba(255, 255, 255, 0.98);
  box-shadow: var(--ds-shadow-sm);
}

html.ui-premium .mercuriale-row-menu-item {
  width: 100%;
  min-height: 34px;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: var(--ds-text);
  text-align: left;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0 10px;
}

html.ui-premium .mercuriale-row-menu-item:hover {
  background: rgba(15, 23, 42, 0.06);
}

html.ui-premium .mercuriale-row-menu-item-danger {
  color: var(--ds-danger);
}

html.ui-premium .mercuriale-row-menu-item-danger:hover {
  background: rgba(220, 38, 38, 0.12);
}

/* -------------------------------------------------------------------------- */
/* Badges & pills                                                             */
/* -------------------------------------------------------------------------- */
html.ui-premium .margin-pill,
html.ui-premium .strip-pill,
html.ui-premium .supplier-link-badge,
html.ui-premium .advisor-chip,
html.ui-premium .sidebar-badge {
  font-weight: 650;
  font-size: var(--ds-text-xs);
  border-radius: 999px;
}

html.ui-premium .advisor-chip-good,
html.ui-premium .margin-pill-good,
html.ui-premium .strip-pill-good,
html.ui-premium .sidebar-badge-good {
  background: var(--ds-success-soft);
  color: var(--ds-success);
  border: 1px solid rgba(5, 150, 105, 0.25);
}

html.ui-premium .advisor-chip-alert,
html.ui-premium .margin-pill-alert,
html.ui-premium .strip-pill-alert,
html.ui-premium .sidebar-badge-alert {
  background: var(--ds-warning-soft);
  color: #b45309;
  border: 1px solid rgba(217, 119, 6, 0.28);
}

html.ui-premium .advisor-chip-danger,
html.ui-premium .margin-pill-danger,
html.ui-premium .strip-pill-danger,
html.ui-premium .sidebar-badge-danger {
  background: var(--ds-danger-soft);
  color: var(--ds-danger);
  border: 1px solid rgba(220, 38, 38, 0.28);
}

html.ui-premium .sidebar-badge-neutral {
  background: rgba(15, 23, 42, 0.06);
  color: var(--ds-text-secondary);
  border: 1px solid var(--ds-border);
}

/* Carte: retire le surlignage de marge */
html.ui-premium #menu-view .margin-pill,
html.ui-premium #menu-view .margin-pill-good,
html.ui-premium #menu-view .margin-pill-alert,
html.ui-premium #menu-view .margin-pill-danger,
html.ui-premium #menu-view .margin-pill-neutral {
  background: transparent;
  border: none;
  box-shadow: none;
  padding: 0;
  min-height: 0;
  color: var(--ds-text-secondary);
}

html.ui-premium #menu-view .margin-pill-good {
  color: var(--ds-success);
}

html.ui-premium #menu-view .margin-pill-alert {
  color: var(--ds-warning);
}

html.ui-premium #menu-view .margin-pill-danger {
  color: var(--ds-danger);
}

/* Carte: parité visuelle avec dashboard */
html.ui-premium #menu-view .panel {
  border: none;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.06),
    0 4px 18px rgba(15, 23, 42, 0.05),
    0 1px 0 rgba(15, 23, 42, 0.03);
}

html.ui-premium #menu-view .panel-head h2 {
  color: var(--ds-camping-paradis-blue);
  font-size: 0.84rem;
  font-weight: 650;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

html.ui-premium #menu-view .panel-head h2 {
  display: none;
}

html.ui-premium #menu-view .dish-card {
  border: none;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.06),
    0 4px 14px rgba(15, 23, 42, 0.05);
  transition: transform var(--ds-duration-fast) var(--ds-ease-premium),
    box-shadow var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium #menu-view .dish-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--ds-shadow-panel-hover);
}

/* Carte — phase amélioration premium */
html.ui-premium #menu-view {
  gap: 12px;
}

html.ui-premium #menu-view .panel {
  padding: 14px 16px;
}

html.ui-premium #menu-view .panel-head {
  min-height: 40px;
  margin-bottom: 8px;
}

html.ui-premium #menu-view .menu-top-actions {
  margin: 0 0 8px;
}

html.ui-premium #menu-view .menu-top-actions .editor-save-button {
  min-height: 34px;
  border-radius: 10px;
  padding: 0 12px;
  font-size: 0.75rem;
  font-weight: 620;
}

html.ui-premium #menu-view .menu-search-field {
  margin-bottom: 8px;
}

html.ui-premium #menu-view .menu-search-field input {
  min-height: 36px;
  border-radius: 10px;
  font-size: 0.78rem;
}

html.ui-premium #menu-view .menu-section-tabs,
html.ui-premium #menu-view .section-tabs {
  gap: 8px;
  margin-bottom: 8px;
}

html.ui-premium #menu-view .section-tab {
  min-height: 34px;
  border-radius: 10px;
  padding: 0 11px;
  font-size: 0.72rem;
  font-weight: 620;
}

html.ui-premium #menu-view .menu-grid {
  gap: 10px;
}

html.ui-premium #menu-view .dish-card {
  min-height: 176px;
  padding: 12px 13px;
}

html.ui-premium #menu-view .dish-name {
  font-size: 0.98rem;
  font-weight: 700;
}

html.ui-premium #menu-view .dish-note {
  font-size: 0.7rem;
  line-height: 1.35;
  color: var(--ds-text-muted);
}

html.ui-premium #menu-view .dish-card-footer-row {
  margin-top: 6px;
}

html.ui-premium #menu-view .dish-card-link {
  min-height: 30px;
  border-radius: 9px;
  padding: 0 10px;
  font-size: 0.68rem;
  font-weight: 620;
}

/* -------------------------------------------------------------------------- */
/* Champs formulaire                                                          */
/* -------------------------------------------------------------------------- */
html.ui-premium .field input,
html.ui-premium .field select,
html.ui-premium .search-field input,
html.ui-premium .simulator-panel .field input,
html.ui-premium .simulator-panel .field select,
html.ui-premium .detail-editor-field input,
html.ui-premium .detail-editor-field select,
html.ui-premium .supplier-link-field input,
html.ui-premium .supplier-link-field select {
  border-radius: var(--ds-radius-md);
  border: 1px solid var(--ds-border-strong);
  background: #ffffff;
  color: var(--ds-text);
  box-shadow: none;
}

html.ui-premium .field input:focus-visible,
html.ui-premium .field select:focus-visible,
html.ui-premium .search-field input:focus-visible,
html.ui-premium .simulator-panel .field input:focus-visible,
html.ui-premium .simulator-panel .field select:focus-visible {
  outline: none;
  border-color: rgba(37, 99, 235, 0.55);
  box-shadow: var(--ds-focus-ring);
}

/* -------------------------------------------------------------------------- */
/* Accordéons (analyse marché / advisor)                                      */
/* -------------------------------------------------------------------------- */
html.ui-premium .advisor-accordion {
  border: 1px solid var(--ds-border);
  border-radius: var(--ds-radius-lg);
  background: #ffffff;
  box-shadow: var(--ds-shadow-xs);
}

html.ui-premium .advisor-accordion-trigger {
  border-radius: var(--ds-radius-lg);
  background: #fafbfc;
  border: none;
  color: var(--ds-text);
}

html.ui-premium .advisor-accordion-trigger:hover {
  background: #f3f4f6;
}

html.ui-premium .advisor-accordion-shell {
  border-top: 1px solid var(--ds-border);
}

/* -------------------------------------------------------------------------- */
/* Modale mercuriale (ajout produit)                                          */
/* -------------------------------------------------------------------------- */
html.ui-premium .mercuriale-add-overlay {
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(4px);
}

html.ui-premium .mercuriale-add-panel {
  border-radius: var(--ds-radius-xl);
  border: 1px solid var(--ds-border);
  box-shadow: var(--ds-shadow-md);
  background: #ffffff;
}

html.ui-premium .mercuriale-add-panel-title {
  color: var(--ds-camping-paradis-blue);
  font-weight: 650;
}

html.ui-premium .mercuriale-add-close {
  border-radius: var(--ds-radius-sm);
  border: 1px solid var(--ds-border);
  background: #ffffff;
  color: var(--ds-text-secondary);
}

html.ui-premium .mercuriale-add-submit {
  background: var(--ds-action);
  color: #ffffff;
  border-radius: var(--ds-radius-md);
  border: 1px solid rgba(37, 99, 235, 0.45);
  font-weight: 600;
}

html.ui-premium .mercuriale-add-progress-track {
  border: 1px solid rgba(37, 99, 235, 0.12);
}

html.ui-premium .mercuriale-add-progress-fill {
  background: linear-gradient(90deg, var(--ds-action), rgb(56, 189, 248));
}

html.ui-premium .mercuriale-add-progress-fill-indeterminate.mercuriale-add-progress-fill {
  background: linear-gradient(
    105deg,
    rgba(37, 99, 235, 0.22) 0%,
    rgb(96, 165, 250) 48%,
    rgba(37, 99, 235, 0.22) 100%
  ) !important;
  background-size: 200% 100%;
  animation: mercuriale-add-progress-shimmer 1.15s linear infinite;
}

html.ui-premium .mercuriale-add-progress-detail {
  color: var(--ds-text-secondary);
  font-weight: 600;
}

/* Confirmation suppression produit / catégorie (style type Linear, compact) */
html.ui-premium .mercuriale-delete-confirm-overlay {
  background: rgba(15, 23, 42, 0.42);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

html.ui-premium .mercuriale-delete-confirm-overlay[data-active="true"] {
  background: rgba(15, 23, 42, 0.5);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

html.ui-premium .mercuriale-delete-confirm-panel {
  width: min(100%, 380px);
  max-width: min(100%, 380px);
  padding: 16px 16px 12px;
  gap: 0;
  border-radius: 10px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: #fcfcfd;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.75) inset,
    0 24px 48px -12px rgba(15, 23, 42, 0.28),
    0 8px 16px -4px rgba(15, 23, 42, 0.1);
}

html.ui-premium .mercuriale-delete-confirm-panel .mercuriale-add-panel-head {
  align-items: flex-start;
  gap: 10px;
}

html.ui-premium .mercuriale-delete-confirm-panel .mercuriale-add-panel-title {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--ds-text);
}

html.ui-premium .mercuriale-delete-confirm-panel .mercuriale-add-panel-note {
  margin: 0;
  margin-top: 6px;
  font-size: 0.75rem;
  line-height: 1.5;
  font-weight: 400;
  color: var(--ds-text-muted);
}

html.ui-premium .mercuriale-delete-confirm-close {
  width: 28px;
  height: 28px;
  padding: 0;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 500;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.9);
  color: var(--ds-text-muted);
}

html.ui-premium .mercuriale-delete-confirm-close:hover {
  background: rgba(15, 23, 42, 0.04);
  color: var(--ds-text-secondary);
  border-color: rgba(15, 23, 42, 0.12);
}

html.ui-premium .mercuriale-delete-confirm-footer {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid rgba(15, 23, 42, 0.06);
  justify-content: flex-end;
}

html.ui-premium .mercuriale-delete-confirm-actions {
  width: auto;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
}

html.ui-premium .mercuriale-dialog-btn {
  margin: 0;
  min-height: 0;
  min-width: 0;
  padding: 5px 11px;
  font-size: 0.6875rem;
  font-weight: 550;
  letter-spacing: 0.01em;
  line-height: 1.35;
  border-radius: 6px;
  cursor: pointer;
  border: 1px solid transparent;
  font-family: inherit;
  appearance: none;
  -webkit-appearance: none;
  transition:
    background-color 0.12s ease,
    border-color 0.12s ease,
    color 0.12s ease,
    box-shadow 0.12s ease;
}

html.ui-premium .mercuriale-dialog-btn--ghost {
  background: #ffffff;
  color: var(--ds-text-secondary);
  border-color: rgba(15, 23, 42, 0.1);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

html.ui-premium .mercuriale-dialog-btn--ghost:hover {
  background: rgba(15, 23, 42, 0.03);
  border-color: rgba(15, 23, 42, 0.14);
}

html.ui-premium .mercuriale-dialog-btn--danger {
  background: rgb(220, 38, 38);
  color: #ffffff;
  border-color: rgba(185, 28, 28, 0.95);
  box-shadow: 0 1px 2px rgba(127, 29, 29, 0.12);
}

html.ui-premium .mercuriale-dialog-btn--danger:hover {
  background: rgb(185, 28, 28);
  border-color: rgb(153, 27, 27);
}

html.ui-premium .mercuriale-dialog-btn:focus-visible {
  outline: none;
  box-shadow: var(--ds-focus-ring);
}

html.ui-premium .mercuriale-dialog-btn--danger:focus-visible {
  box-shadow: var(--ds-focus-ring), 0 1px 2px rgba(127, 29, 29, 0.12);
}

html.ui-premium .mercuriale-dialog-btn--primary {
  background: var(--ds-action);
  color: #ffffff;
  border-color: rgba(0, 122, 168, 0.55);
  box-shadow: 0 1px 2px rgba(0, 100, 140, 0.12);
}

html.ui-premium .mercuriale-dialog-btn--primary:hover {
  background: var(--ds-action-hover);
  border-color: rgba(0, 100, 140, 0.65);
}

html.ui-premium .mercuriale-dialog-btn--primary:focus-visible {
  box-shadow: var(--ds-focus-ring), 0 1px 2px rgba(0, 100, 140, 0.12);
}

html.ui-premium .mercuriale-delete-confirm-panel .mercuriale-delete-confirm-form {
  margin-top: 4px;
  display: grid;
  gap: 12px;
}

html.ui-premium .mercuriale-delete-confirm-field {
  display: grid;
  gap: 5px;
}

html.ui-premium .mercuriale-delete-confirm-field > span {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--ds-text-secondary);
}

html.ui-premium .mercuriale-delete-confirm-field input {
  width: 100%;
  min-height: 32px;
  padding: 6px 10px;
  border-radius: 6px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: #ffffff;
  font-size: 0.75rem;
  font-family: inherit;
  color: var(--ds-text);
  box-sizing: border-box;
}

html.ui-premium .mercuriale-delete-confirm-field input::placeholder {
  color: var(--ds-text-muted);
  opacity: 0.85;
}

html.ui-premium .mercuriale-delete-confirm-field input:focus {
  outline: none;
  border-color: rgba(0, 149, 200, 0.45);
  box-shadow: 0 0 0 3px rgba(0, 149, 200, 0.12);
}

/* -------------------------------------------------------------------------- */
/* Modale « Modifier la fiche » mercuriale                                    */
/* -------------------------------------------------------------------------- */
html.ui-premium .mercuriale-edit-panel {
  width: min(100%, 560px);
  max-height: calc(100vh - 48px);
  overflow-y: auto;
  overflow-x: hidden;
  padding: 24px 26px;
  gap: 22px;
  border-radius: 22px;
  background: #ffffff;
  border-color: rgba(15, 23, 42, 0.08);
  box-shadow: var(--ds-shadow-lg, 0 28px 56px rgba(16, 52, 87, 0.12));
  -webkit-overflow-scrolling: touch;
}

html.ui-premium .mercuriale-edit-panel::-webkit-scrollbar {
  width: 10px;
}

html.ui-premium .mercuriale-edit-panel::-webkit-scrollbar-thumb {
  background: rgba(15, 23, 42, 0.18);
  border-radius: 10px;
  border: 2px solid #ffffff;
}

html.ui-premium .mercuriale-edit-panel::-webkit-scrollbar-thumb:hover {
  background: rgba(15, 23, 42, 0.3);
}

html.ui-premium .mercuriale-edit-panel .mercuriale-add-panel-head {
  align-items: flex-start;
  gap: 20px;
}

html.ui-premium .mercuriale-edit-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

html.ui-premium .mercuriale-edit-eyebrow-pill {
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(0, 149, 200, 0.1);
  color: var(--ds-action, #007aa8);
  font-size: 0.6875rem;
  font-weight: 650;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

html.ui-premium .mercuriale-edit-eyebrow-pill[data-supplier-slug="sysco"] {
  background: rgba(56, 132, 255, 0.12);
  color: #1b56d8;
}

html.ui-premium .mercuriale-edit-eyebrow-pill[data-supplier-slug="relais-dor"] {
  background: rgba(220, 134, 0, 0.14);
  color: #a8590c;
}

html.ui-premium .mercuriale-edit-eyebrow-pill[data-supplier-slug="fruits-legumes"] {
  background: rgba(46, 138, 73, 0.12);
  color: #1f6b34;
}

html.ui-premium .mercuriale-edit-eyebrow-pill[data-supplier-slug="supermarche"] {
  background: rgba(122, 92, 184, 0.14);
  color: #5d3fa0;
}

html.ui-premium .mercuriale-edit-eyebrow-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ds-text-muted, rgba(15, 23, 42, 0.55));
}

html.ui-premium .mercuriale-edit-title {
  font-size: 1.22rem;
  font-weight: 650;
  letter-spacing: -0.01em;
  color: var(--ds-text, #0f172a);
  margin: 0;
}

html.ui-premium .mercuriale-edit-breadcrumb {
  display: inline-flex;
  align-items: center;
  margin-top: 4px;
  padding: 2px 10px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.05);
  color: var(--ds-text-secondary, rgba(15, 23, 42, 0.7));
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

html.ui-premium .mercuriale-edit-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  padding: 12px 4px;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(247, 249, 252, 0.6);
  border-radius: 12px;
}

html.ui-premium .mercuriale-edit-summary-cell {
  display: grid;
  gap: 4px;
  padding: 4px 14px;
  border-right: 1px solid rgba(15, 23, 42, 0.06);
}

html.ui-premium .mercuriale-edit-summary-cell:last-child {
  border-right: none;
}

html.ui-premium .mercuriale-edit-summary-label {
  font-size: 0.68rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--ds-text-muted, rgba(15, 23, 42, 0.55));
}

html.ui-premium .mercuriale-edit-summary-value {
  font-size: 0.92rem;
  font-weight: 650;
  color: var(--ds-text, #0f172a);
  letter-spacing: -0.005em;
}

html.ui-premium .mercuriale-edit-summary--compact {
  grid-template-columns: minmax(0, 1fr);
  padding: 8px 4px;
}

html.ui-premium .mercuriale-edit-supplier-cards-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 12px;
}

html.ui-premium .mercuriale-edit-supplier-card {
  display: grid;
  gap: 6px;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid rgba(15, 23, 42, 0.1);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(248, 250, 252, 0.94));
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
}

html.ui-premium .mercuriale-edit-supplier-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 2px;
}

html.ui-premium .mercuriale-edit-supplier-card-product {
  font-size: 0.96rem;
  font-weight: 700;
  color: var(--ds-text, #0f172a);
  line-height: 1.25;
  word-break: break-word;
}

html.ui-premium .mercuriale-edit-supplier-card-empty {
  color: var(--ds-text-muted, rgba(15, 23, 42, 0.5));
  font-weight: 550;
  font-style: italic;
}

html.ui-premium .mercuriale-edit-supplier-card-ref {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--ds-text-secondary, rgba(15, 23, 42, 0.65));
  letter-spacing: 0.02em;
}

html.ui-premium .mercuriale-edit-supplier-card-price {
  font-size: 0.92rem;
  font-weight: 700;
  color: rgb(5, 150, 105);
  letter-spacing: -0.01em;
}

html.ui-premium .mercuriale-edit-supplier-card-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 6px;
}

html.ui-premium .mercuriale-edit-supplier-card-actions .mercuriale-dialog-btn {
  font-size: 0.78rem;
  padding: 6px 10px;
}

html.ui-premium .mercuriale-edit-supplier-card-picker {
  display: grid;
  gap: 8px;
  margin-top: 8px;
  padding: 10px;
  border-radius: 10px;
  border: 1px dashed rgba(15, 23, 42, 0.16);
  background: rgba(248, 250, 252, 0.7);
}

html.ui-premium .mercuriale-edit-supplier-card-picker-input {
  min-height: 34px;
  padding: 6px 10px;
  font-size: 0.84rem;
}

html.ui-premium .mercuriale-edit-supplier-card-picker-results {
  display: grid;
  gap: 4px;
  max-height: 220px;
  overflow-y: auto;
}

html.ui-premium .mercuriale-edit-supplier-card-picker-empty {
  margin: 0;
  padding: 8px 4px;
  font-size: 0.78rem;
  color: var(--ds-text-muted, rgba(15, 23, 42, 0.5));
  font-style: italic;
  text-align: center;
}

html.ui-premium .mercuriale-edit-supplier-card-picker-option {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid transparent;
  background: #ffffff;
  text-align: left;
  cursor: pointer;
  transition: background 0.12s ease, border-color 0.12s ease;
}

html.ui-premium .mercuriale-edit-supplier-card-picker-option:hover {
  background: rgba(59, 130, 246, 0.06);
  border-color: rgba(59, 130, 246, 0.2);
}

html.ui-premium .mercuriale-edit-supplier-card-picker-option-name {
  font-size: 0.86rem;
  font-weight: 650;
  color: var(--ds-text, #0f172a);
}

html.ui-premium .mercuriale-edit-supplier-card-picker-option-meta {
  font-size: 0.72rem;
  color: var(--ds-text-muted, rgba(15, 23, 42, 0.55));
}

@media (max-width: 720px) {
  html.ui-premium .mercuriale-edit-supplier-cards-row {
    grid-template-columns: minmax(0, 1fr);
  }
}

html.ui-premium .mercuriale-edit-form {
  display: grid;
  gap: 22px;
  margin: 0;
  padding: 0;
}

html.ui-premium .mercuriale-edit-section {
  display: grid;
  gap: 10px;
}

html.ui-premium .mercuriale-edit-section-title {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ds-text-muted, rgba(15, 23, 42, 0.55));
}

html.ui-premium .mercuriale-edit-section-help {
  margin: -2px 0 4px;
  font-size: 0.78rem;
  line-height: 1.4;
  color: var(--ds-text-secondary, rgba(15, 23, 42, 0.65));
}

html.ui-premium .mercuriale-edit-grid {
  display: grid;
  gap: 12px;
}

html.ui-premium .mercuriale-edit-grid-two {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

@media (max-width: 540px) {
  html.ui-premium .mercuriale-edit-grid-two {
    grid-template-columns: minmax(0, 1fr);
  }
  html.ui-premium .mercuriale-edit-summary {
    grid-template-columns: minmax(0, 1fr);
  }
  html.ui-premium .mercuriale-edit-summary-cell {
    border-right: none;
    border-bottom: 1px solid rgba(15, 23, 42, 0.06);
    padding: 8px 14px;
  }
  html.ui-premium .mercuriale-edit-summary-cell:last-child {
    border-bottom: none;
  }
}

html.ui-premium .mercuriale-edit-field {
  display: grid;
  gap: 6px;
}

html.ui-premium .mercuriale-edit-field-label {
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--ds-text-secondary, rgba(15, 23, 42, 0.7));
}

html.ui-premium .mercuriale-edit-input {
  width: 100%;
  min-height: 38px;
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid rgba(15, 23, 42, 0.14);
  background: #ffffff;
  font-size: 0.88rem;
  font-weight: 500;
  font-family: inherit;
  color: var(--ds-text, #0f172a);
  text-align: left;
  box-sizing: border-box;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease;
}

html.ui-premium .mercuriale-edit-input::placeholder {
  color: var(--ds-text-muted, rgba(15, 23, 42, 0.4));
  font-weight: 400;
}

html.ui-premium .mercuriale-edit-input:focus {
  outline: none;
  border-color: rgba(0, 149, 200, 0.55);
  box-shadow: 0 0 0 3px rgba(0, 149, 200, 0.15);
}

html.ui-premium .mercuriale-edit-input-affix {
  display: flex;
  align-items: stretch;
  border: 1px solid rgba(15, 23, 42, 0.14);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  overflow: hidden;
}

html.ui-premium .mercuriale-edit-input-affix .mercuriale-edit-input {
  border: 0;
  box-shadow: none;
  flex: 1 1 auto;
  background: transparent;
}

html.ui-premium .mercuriale-edit-input-affix:focus-within {
  border-color: rgba(0, 149, 200, 0.55);
  box-shadow: 0 0 0 3px rgba(0, 149, 200, 0.15);
}

html.ui-premium .mercuriale-edit-input-suffix {
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--ds-text-muted, rgba(15, 23, 42, 0.55));
  background: rgba(15, 23, 42, 0.04);
  border-left: 1px solid rgba(15, 23, 42, 0.08);
}

html.ui-premium .mercuriale-edit-quickpicks {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
}

html.ui-premium .mercuriale-edit-quickpicks-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--ds-text-muted, rgba(15, 23, 42, 0.55));
  margin-right: 4px;
}

html.ui-premium .mercuriale-edit-chip {
  display: inline-flex;
  align-items: center;
  height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  border: 1px solid rgba(15, 23, 42, 0.1);
  background: #ffffff;
  color: var(--ds-text-secondary, rgba(15, 23, 42, 0.7));
  font-size: 0.74rem;
  font-weight: 600;
  cursor: pointer;
  transition:
    background-color 0.12s ease,
    border-color 0.12s ease,
    color 0.12s ease;
}

html.ui-premium .mercuriale-edit-chip:hover {
  background: rgba(15, 23, 42, 0.04);
  border-color: rgba(15, 23, 42, 0.18);
}

html.ui-premium .mercuriale-edit-chip[data-active="true"] {
  background: rgba(0, 149, 200, 0.12);
  border-color: rgba(0, 149, 200, 0.5);
  color: var(--ds-action, #007aa8);
}

html.ui-premium .mercuriale-edit-footer {
  display: flex;
  justify-content: flex-end;
  padding-top: 8px;
  border-top: 1px solid rgba(15, 23, 42, 0.06);
}

html.ui-premium .mercuriale-edit-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  width: auto;
}

html.ui-premium .mercuriale-edit-actions .mercuriale-dialog-btn {
  min-height: 34px;
  padding: 6px 16px;
  font-size: 0.82rem;
}

/* Toasts Mercuriale (premium) */
html.ui-premium .mercuriale-toast {
  border-radius: var(--ds-radius-xl);
  border-color: var(--ds-border);
  box-shadow: var(--ds-shadow-md);
  background: #ffffff;
}

html.ui-premium .mercuriale-toast-title {
  color: var(--ds-text);
  font-weight: 650;
}

html.ui-premium .mercuriale-toast-text {
  color: var(--ds-text-secondary);
}

html.ui-premium .mercuriale-toast-close {
  border-radius: var(--ds-radius-sm);
  border: 1px solid var(--ds-border);
  background: var(--ds-bg-app);
}

/* -------------------------------------------------------------------------- */
/* Focus clavier cohérent                                                     */
/* -------------------------------------------------------------------------- */
html.ui-premium :where(
    button,
    [role="button"],
    a,
    input,
    select,
    textarea,
    .section-tab,
    .supplier-filter,
    .purchase-category-chip,
    .mercuriale-row,
    .advisor-accordion-trigger,
    .detail-product-card
  ):focus-visible {
  outline: none;
  box-shadow: var(--ds-focus-ring);
}

@media (prefers-reduced-motion: reduce) {
  html.ui-premium *,
  html.ui-premium *::before,
  html.ui-premium *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* -------------------------------------------------------------------------- */
/* Dashboard : accueil (sans dégradés ni couleurs décoratives)                */
/* Typo hero titre : bloc « SaaS Dashboard » ci-dessous                       */
/* -------------------------------------------------------------------------- */
html.ui-premium #dashboard-view .dashboard-hero-greeting {
  font-weight: 600;
  font-size: 0.58em;
  letter-spacing: 0.02em;
  color: var(--ds-text-muted);
  text-transform: none;
}

html.ui-premium #dashboard-view .dashboard-hero-name {
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--ds-camping-paradis-blue);
}

html.ui-premium #dashboard-view .dashboard-hero-wave {
  font-family: var(--ds-font-sans);
  font-weight: 500;
  font-size: 0.55em;
}

html.ui-premium #dashboard-view .dashboard-hero-panel {
  border: 1px solid rgba(15, 23, 42, 0.05);
  box-shadow: var(--ds-shadow-panel);
  background: linear-gradient(160deg, #ffffff 0%, #fafbfc 45%, #ffffff 100%);
}

html.ui-premium #dashboard-view .dashboard-hero-copy {
  justify-items: center;
  text-align: center;
}

html.ui-premium .dashboard-supplier-progress-count {
  color: var(--ds-text-secondary);
}

html.ui-premium .dashboard-supplier-progress-percent {
  color: var(--ds-camping-paradis-blue);
}

html.ui-premium .dashboard-supplier-progress-track {
  background: rgba(15, 23, 42, 0.06);
  box-shadow: inset 0 0 0 1px var(--ds-border);
}

html.ui-premium .dashboard-supplier-progress-fill {
  background: linear-gradient(90deg, var(--ds-camping-paradis-blue), #33b5e0);
}

html.ui-premium .dashboard-supplier-progress-detail {
  color: var(--ds-text-secondary);
}

/* -------------------------------------------------------------------------- */
/* SaaS Dashboard Redesign (Dashboard only)                                   */
/* -------------------------------------------------------------------------- */
html.ui-premium .topbar-nav-item {
  border-color: transparent;
  background: transparent;
}

html.ui-premium .topbar-nav-item .sidebar-nav-item-lead {
  width: 100%;
  justify-content: center;
}

html.ui-premium .topbar-nav-item .sidebar-nav-item-label {
  text-align: center;
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: -0.01em;
}

html.ui-premium .topbar-nav-item:hover {
  background: rgba(15, 23, 42, 0.045);
  border-color: transparent;
}

html.ui-premium .topbar-nav-item[data-active="true"],
html.ui-premium .sidebar-nav-item.topbar-nav-item[data-active="true"] {
  background: rgba(37, 99, 235, 0.07);
  border-color: transparent;
  color: var(--ds-action);
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.14);
}

html.ui-premium .topbar-nav-item[data-active="true"] .sidebar-nav-item-label,
html.ui-premium .sidebar-nav-item.topbar-nav-item[data-active="true"] .sidebar-nav-item-label {
  font-weight: 600;
}

html.ui-premium #dashboard-view {
  border: 0;
  box-shadow: none;
  background: transparent;
  padding: 0;
  display: grid;
  gap: clamp(18px, 2vw, 26px);
}

html.ui-premium #dashboard-view > .panel {
  border-radius: var(--ds-radius-xl);
  border: 1px solid rgba(15, 23, 42, 0.055);
  box-shadow: var(--ds-shadow-panel);
  transition: box-shadow var(--ds-duration-base) var(--ds-ease-premium);
}

html.ui-premium #dashboard-view .dashboard-hero-panel {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1.3fr);
  align-items: stretch;
  gap: clamp(16px, 2vw, 22px);
  padding: clamp(18px, 2.2vw, 26px);
}

html.ui-premium .topbar-profile-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

html.ui-premium .topbar-profile-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  text-align: center;
}

html.ui-premium #dashboard-view .dashboard-hero-copy {
  align-content: start;
  justify-items: center;
  text-align: center;
  gap: 10px;
}

html.ui-premium #dashboard-view .dashboard-hero-title {
  font-family: "Outfit", var(--ds-font-sans);
  font-weight: 700;
  display: inline-flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: center;
  text-align: center;
  gap: 0.15em 0.28em;
  width: 100%;
  font-size: clamp(1.55rem, 2.65vw, 2.35rem);
  line-height: 1.12;
  letter-spacing: -0.035em;
}

html.ui-premium #dashboard-view .dashboard-hero-subtitle {
  margin: 0;
  color: var(--ds-text-muted);
  font-size: 0.875rem;
  font-weight: 400;
  line-height: 1.5;
  max-width: 36ch;
  margin-inline: auto;
}

html.ui-premium #dashboard-view .dashboard-hero-mini-kpis {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  width: 100%;
}

html.ui-premium #dashboard-view .dashboard-hero-mini-kpi {
  display: grid;
  gap: 3px;
  justify-items: center;
  text-align: center;
  border-radius: 12px;
  border: none;
  background: rgba(255, 255, 255, 0.72);
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.06),
    0 4px 14px rgba(15, 23, 42, 0.04);
  padding: 10px 12px;
  transition: box-shadow var(--ds-duration-fast) var(--ds-ease-premium),
    transform var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium #dashboard-view .dashboard-hero-mini-kpi:hover {
  box-shadow:
    inset 0 0 0 1px rgba(37, 99, 235, 0.1),
    0 8px 20px rgba(15, 23, 42, 0.07);
}

html.ui-premium #dashboard-view .dashboard-hero-mini-kpi small {
  font-size: 0.66rem;
  line-height: 1.2;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ds-text-muted);
}

html.ui-premium #dashboard-view .dashboard-hero-mini-kpi strong {
  font-size: 0.82rem;
  line-height: 1.3;
  font-weight: 650;
  color: var(--ds-text);
}

html.ui-premium #dashboard-view .dashboard-hero-mini-kpi-emphasis strong {
  font-size: clamp(1.55rem, 2.4vw, 2rem);
  line-height: 1;
  letter-spacing: -0.02em;
  font-weight: 800;
}

html.ui-premium #dashboard-view .dashboard-hero-mini-kpi-meta {
  display: block;
  margin-top: 1px;
  font-size: 0.76rem;
  line-height: 1.25;
  font-weight: 400;
  color: var(--ds-text-secondary);
}

html.ui-premium #dashboard-view .dashboard-hero-wave {
  font-family: inherit;
  font-size: 1em;
  font-weight: inherit;
  line-height: inherit;
}

html.ui-premium #dashboard-view .dashboard-hero-mini-kpi-good {
  background: rgba(5, 150, 105, 0.08);
  box-shadow:
    inset 0 0 0 1px rgba(5, 150, 105, 0.18),
    0 4px 14px rgba(5, 150, 105, 0.07);
}

html.ui-premium #dashboard-view .dashboard-hero-mini-kpi-alert {
  background: rgba(217, 119, 6, 0.08);
  box-shadow:
    inset 0 0 0 1px rgba(217, 119, 6, 0.2),
    0 4px 14px rgba(217, 119, 6, 0.06);
}

html.ui-premium #dashboard-view .dashboard-kpi-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  align-self: stretch;
  height: 100%;
}

html.ui-premium #dashboard-view .dashboard-kpi-card {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  text-align: center;
  gap: 0;
  border-radius: 14px;
  border: none;
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.06),
    0 4px 18px rgba(15, 23, 42, 0.05),
    0 1px 0 rgba(15, 23, 42, 0.03);
  padding: clamp(14px, 2vw, 18px);
  min-height: 100%;
  background: rgba(255, 255, 255, 0.92);
  transition: transform var(--ds-duration-fast) var(--ds-ease-premium),
    box-shadow var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium #dashboard-view .dashboard-kpi-head {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  width: 100%;
}

html.ui-premium #dashboard-view .dashboard-kpi-mid {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 2.5rem;
  width: 100%;
}

html.ui-premium #dashboard-view .dashboard-kpi-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--ds-shadow-panel-hover);
}

html.ui-premium #dashboard-view .dashboard-kpi-label {
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.055em;
  text-transform: uppercase;
  color: var(--ds-text-muted);
}

html.ui-premium #dashboard-view .dashboard-kpi-value {
  font-feature-settings: "tnum";
  font-variant-numeric: tabular-nums;
  font-weight: 800;
  font-size: clamp(2.35rem, 4.2vw, 3.45rem);
  line-height: 0.94;
  letter-spacing: -0.045em;
  color: var(--ds-text);
  display: block;
  width: 100%;
  text-align: center;
}

html.ui-premium #dashboard-view .dashboard-kpi-footer {
  flex: 0 0 auto;
  margin-top: 0;
  padding-top: 6px;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
}

html.ui-premium #dashboard-view .dashboard-kpi-trend {
  border-radius: 999px;
  min-height: 26px;
  padding: 4px 10px;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  background: rgba(15, 23, 42, 0.045);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  max-width: 100%;
  text-align: center;
}

html.ui-premium #dashboard-view .dashboard-kpi-trend-good::before {
  content: "↗";
  font-size: 0.85em;
  font-weight: 700;
  opacity: 0.85;
}

html.ui-premium #dashboard-view .dashboard-kpi-trend-alert::before {
  content: "↑";
  font-size: 0.75em;
  font-weight: 700;
  opacity: 0.75;
}

html.ui-premium #dashboard-view .dashboard-kpi-trend-danger::before {
  content: "↘";
  font-size: 0.85em;
  font-weight: 700;
  opacity: 0.85;
}

/* Nouvelles réservations : liste des résas, une ligne chacune (troncature si trop long) */
html.ui-premium #dashboard-view .dashboard-kpi-card-reservations .dashboard-kpi-footer {
  align-items: stretch;
  max-width: 100%;
}

html.ui-premium #dashboard-view .dashboard-kpi-card-reservations .dashboard-kpi-trend-list {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 4px;
  width: 100%;
  padding: 0;
  margin: 0;
  background: none;
  border: none;
  box-shadow: none;
}

html.ui-premium #dashboard-view .dashboard-kpi-card-reservations .dashboard-kpi-trend-line {
  font-size: clamp(0.58rem, 1.35vw, 0.625rem);
  font-weight: 400;
  line-height: 1.3;
  letter-spacing: 0.005em;
  color: var(--ds-text-muted);
  text-align: center;
  width: 100%;
  max-width: 100%;
  padding-inline: 2px;
  box-sizing: border-box;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

html.ui-premium #dashboard-view .dashboard-kpi-card-ca-total .dashboard-kpi-footer {
  align-items: stretch;
  width: 100%;
}

html.ui-premium #dashboard-view .dashboard-kpi-card-ca-total .dashboard-kpi-trend {
  width: 100%;
  max-width: 100%;
  justify-content: center;
  box-sizing: border-box;
  color: var(--ds-text-secondary);
  font-weight: 500;
}

html.ui-premium #dashboard-view .dashboard-kpi-card-ca-total .dashboard-kpi-trend::before {
  content: none;
}

html.ui-premium #dashboard-view .panel-head {
  margin-bottom: 14px;
}

html.ui-premium #dashboard-view .panel-head h2.dashboard-section-title {
  font-family: var(--ds-font-sans);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ds-text-secondary);
}

html.ui-premium #dashboard-view .dashboard-panel-copy {
  margin-top: 6px;
  font-size: 0.875rem;
  color: var(--ds-text-muted);
  line-height: 1.5;
  font-weight: 400;
  max-width: 52ch;
}

html.ui-premium #dashboard-view .dashboard-supplier-alerts-panel {
  padding: clamp(16px, 2vw, 22px);
  border: 1px solid rgba(15, 23, 42, 0.055);
  box-shadow: var(--ds-shadow-panel);
  background: linear-gradient(180deg, #ffffff 0%, #fafbfc 100%);
}

html.ui-premium #dashboard-view .dashboard-supplier-alerts .dashboard-empty-state {
  padding: 14px 16px;
  border-radius: var(--ds-radius-lg);
  border: 1px dashed var(--ds-border);
  background: rgba(15, 23, 42, 0.02);
  color: var(--ds-text-secondary);
  font-size: var(--ds-text-sm);
  line-height: var(--ds-leading-normal);
}

html.ui-premium #dashboard-view .dashboard-supplier-alerts-toolbar {
  gap: 10px;
  margin-bottom: 12px;
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-summary-grid {
  gap: 10px;
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-summary-card {
  min-height: 86px;
  padding: 13px 15px;
  border-radius: var(--ds-radius-lg);
  border: none;
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.06);
  background: rgba(255, 255, 255, 0.9);
  transition: box-shadow var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-summary-card:hover {
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.09);
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-summary-card-neutral {
  background: rgba(15, 23, 42, 0.02);
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-summary-card-alert {
  background: rgba(255, 255, 255, 0.9);
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.06);
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-summary-card-good {
  background: rgba(255, 255, 255, 0.9);
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.06);
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-summary-card-danger {
  background: rgba(255, 255, 255, 0.9);
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.06);
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-summary-label {
  color: var(--ds-text-muted);
  font-weight: 650;
  letter-spacing: 0.1em;
  font-size: 0.66rem;
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-summary-value {
  color: var(--ds-text);
  font-weight: 750;
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-summary-detail {
  color: var(--ds-text-secondary);
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-filter {
  border: 1px solid var(--ds-border);
  border-radius: var(--ds-radius-md);
  background: #ffffff;
  box-shadow: var(--ds-shadow-xs);
  min-height: 34px;
  padding: 0.34rem 0.78rem;
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-filter:hover {
  border-color: rgba(37, 99, 235, 0.22);
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-filter span {
  color: var(--ds-text-secondary);
  font-weight: 650;
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-filter strong {
  font-weight: 750;
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-filter-danger {
  background: var(--ds-danger-soft);
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-filter-alert {
  background: var(--ds-warning-soft);
}

html.ui-premium #dashboard-view .panel-head {
  margin-bottom: 10px;
}

html.ui-premium #dashboard-view .supplier-alert-section {
  gap: 10px;
  border-radius: var(--ds-radius-lg);
  border: none;
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.06);
  background: rgba(255, 255, 255, 0.82);
  padding: 11px 13px;
}

html.ui-premium #dashboard-view .supplier-alert-section-head {
  margin-bottom: 4px;
}

html.ui-premium #dashboard-view .supplier-alert-section-title {
  margin: 0;
  font-size: 0.6875rem;
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ds-text-muted);
}

html.ui-premium #dashboard-view .supplier-alert-section-count {
  font-size: 0.625rem;
  font-weight: 650;
  padding: 0.22rem 0.55rem;
  border-radius: 999px;
  border: none;
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.07);
  background: rgba(15, 23, 42, 0.035);
  color: var(--ds-text-secondary);
}

html.ui-premium #dashboard-view .supplier-alert-section-note {
  margin: 0;
  font-size: 0.74rem;
  color: var(--ds-text-muted);
  line-height: var(--ds-leading-normal);
}

html.ui-premium #dashboard-view .supplier-alert-section-danger {
  box-shadow: inset 0 0 0 1px rgba(220, 38, 38, 0.12);
  background: rgba(254, 242, 242, 0.45);
}

html.ui-premium #dashboard-view .supplier-alert-section-count-danger {
  border: none;
  box-shadow: inset 0 0 0 1px rgba(220, 38, 38, 0.22);
  background: var(--ds-danger-soft);
  color: var(--ds-text);
}

html.ui-premium #dashboard-view .supplier-alert-section-count-good {
  border: none;
  box-shadow: inset 0 0 0 1px rgba(5, 150, 105, 0.24);
  background: var(--ds-success-soft);
  color: var(--ds-text);
}

html.ui-premium #dashboard-view .supplier-alert-section-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

html.ui-premium #dashboard-view .supplier-alert-card {
  padding: 9px 11px;
  min-height: 0;
  gap: 6px;
  border-radius: 12px;
  border: none;
  background: rgba(255, 255, 255, 0.94);
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.05),
    0 3px 12px rgba(15, 23, 42, 0.04);
  transition: box-shadow var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium #dashboard-view .supplier-alert-card:hover {
  box-shadow:
    inset 0 0 0 1px rgba(37, 99, 235, 0.1),
    0 8px 22px rgba(15, 23, 42, 0.06);
}

html.ui-premium #dashboard-view .supplier-alert-card::before {
  width: 3px;
  border-radius: 2px;
}

html.ui-premium #dashboard-view .supplier-alert-card-increase::before,
html.ui-premium #dashboard-view .supplier-alert-card-critique::before,
html.ui-premium #dashboard-view .supplier-alert-card-attention::before {
  background: var(--ds-danger);
}

html.ui-premium #dashboard-view .supplier-alert-card-decrease::before,
html.ui-premium #dashboard-view .supplier-alert-card-info::before {
  background: var(--ds-success);
}

html.ui-premium #dashboard-view .supplier-alert-content {
  gap: 6px;
}

html.ui-premium #dashboard-view .supplier-alert-header {
  gap: 3px;
}

html.ui-premium #dashboard-view .supplier-alert-supplier {
  font-size: 0.61rem;
}

html.ui-premium #dashboard-view .supplier-alert-product-block {
  gap: 2px;
}

html.ui-premium #dashboard-view .supplier-alert-title {
  font-size: 0.775rem;
  line-height: 1.22;
}

html.ui-premium #dashboard-view .supplier-alert-reference {
  font-size: 0.655rem;
}

html.ui-premium #dashboard-view .supplier-alert-footer {
  gap: 6px;
}

html.ui-premium #dashboard-view .supplier-alert-price-stack {
  gap: 3px;
}

html.ui-premium #dashboard-view .supplier-alert-prices {
  font-size: 0.72rem;
}

html.ui-premium #dashboard-view .supplier-alert-variation {
  font-size: 0.65625rem;
  min-height: 0;
  padding: 0.26rem 0.52rem;
  border-radius: 999px;
  border: none;
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.07);
  background: rgba(15, 23, 42, 0.03);
  backdrop-filter: none;
  font-weight: 650;
}

html.ui-premium #dashboard-view .supplier-alert-variation-good {
  background: var(--ds-success-soft);
  border-color: rgba(5, 150, 105, 0.22);
  color: var(--ds-success);
  box-shadow: none;
}

html.ui-premium #dashboard-view .supplier-alert-variation-danger {
  background: var(--ds-danger-soft);
  border-color: rgba(220, 38, 38, 0.22);
  color: var(--ds-danger);
  box-shadow: none;
}

html.ui-premium #dashboard-view .supplier-alert-variation-alert {
  background: var(--ds-warning-soft);
  border-color: rgba(217, 119, 6, 0.26);
  color: var(--ds-warning);
  box-shadow: none;
}

html.ui-premium #dashboard-view .supplier-alert-status-summary {
  gap: 4px;
}

html.ui-premium #dashboard-view .supplier-alert-status-pill {
  min-height: 22px;
  padding: 0.18rem 0.5rem;
  font-size: 0.5625rem;
  font-weight: 650;
  letter-spacing: 0.04em;
  border-radius: 999px;
  box-shadow: inset 0 0 0 1px transparent;
}

html.ui-premium #dashboard-view .supplier-alert-status-actions {
  gap: 5px;
}

html.ui-premium #dashboard-view .supplier-alert-status-button {
  min-height: 27px;
  padding: 0.24rem 0.52rem;
  font-size: 0.63rem;
}

html.ui-premium #dashboard-view .supplier-alert-processed-date {
  font-size: 0.65rem;
}

html.ui-premium #dashboard-view .supplier-alert-impact-grid {
  gap: 6px;
}

html.ui-premium #dashboard-view .supplier-alert-impact-card {
  padding: 8px 10px;
  border-radius: 10px;
}

html.ui-premium #dashboard-view .supplier-alert-impact-label {
  font-size: 0.6rem;
}

html.ui-premium #dashboard-view .supplier-alert-impact-value {
  font-size: 0.85rem;
}

html.ui-premium #dashboard-view .supplier-alert-impact-detail {
  font-size: 0.65rem;
}

html.ui-premium #dashboard-view .supplier-alert-comment-label {
  font-size: 0.65rem;
}

html.ui-premium #dashboard-view .supplier-alert-comment-input {
  min-height: 34px;
  padding: 0 10px;
  border-radius: 12px;
  font-size: 0.76rem;
}

html.ui-premium #dashboard-view .supplier-alert-comment {
  min-height: 56px;
  padding: 8px 10px;
  border-radius: 12px;
  font-size: 0.76rem;
}

/* -------------------------------------------------------------------------- */
/* Hub « Alertes prix fournisseurs » : contrôle, synthèse, sections & cartes   */
/* -------------------------------------------------------------------------- */
html.ui-premium #dashboard-view .dashboard-supplier-alerts-hub .panel-head {
  margin-bottom: 6px;
  justify-content: flex-start;
  text-align: left;
}

html.ui-premium #dashboard-view .dashboard-supplier-alerts-hub .panel-head > div {
  margin-inline: 0;
}

html.ui-premium #dashboard-view .dashboard-supplier-alerts-hub .dashboard-section-title {
  font-size: clamp(1.22rem, 1.9vw, 1.55rem);
  font-weight: 680;
  line-height: 1.2;
  letter-spacing: -0.02em;
  text-transform: none;
  color: var(--ds-text);
  text-align: left;
}

html.ui-premium #dashboard-view .dashboard-supplier-alerts-lede {
  margin: 8px 0 0;
  font-size: 0.83rem;
  line-height: 1.45;
  max-width: 52ch;
  margin-inline: 0;
  text-align: left;
}

html.ui-premium #dashboard-view .dashboard-supplier-alerts-stack {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

html.ui-premium #dashboard-view .dashboard-supplier-alerts {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

html.ui-premium #dashboard-view .dashboard-supplier-alerts-hub .dashboard-supplier-refresh-zone {
  display: grid;
  gap: 10px;
  margin: 0 0 12px;
  padding: 0;
  background: transparent;
  box-shadow: none;
}

html.ui-premium #dashboard-view .dashboard-supplier-alerts-hub .dashboard-supplier-refresh-zone::before {
  content: none;
}

html.ui-premium #dashboard-view .dashboard-supplier-refresh-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
}

html.ui-premium #dashboard-view .dashboard-supplier-refresh-actions .dashboard-supplier-refresh-button {
  flex: 0 1 auto;
  min-width: min(100%, 16rem);
}

html.ui-premium #dashboard-view .dashboard-supplier-refresh-cancel {
  flex: 0 0 auto;
  min-height: 40px;
}

html.ui-premium #dashboard-view .dashboard-refresh-note .dashboard-bridge-help-actions {
  margin-top: 6px;
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
}

html.ui-premium #dashboard-view .dashboard-bridge-help-button {
  min-height: 26px;
  padding: 0.24rem 0.6rem;
  border-radius: 8px;
  border: 1px solid rgba(37, 99, 235, 0.25);
  background: rgba(37, 99, 235, 0.08);
  color: var(--ds-action-hover);
  font-size: 0.64rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: background-color var(--ds-duration-fast) var(--ds-ease-premium),
    border-color var(--ds-duration-fast) var(--ds-ease-premium),
    transform var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium #dashboard-view .dashboard-bridge-help-button:hover:not(:disabled) {
  background: rgba(37, 99, 235, 0.12);
  border-color: rgba(37, 99, 235, 0.36);
  transform: translateY(-1px);
}

html.ui-premium #dashboard-view .dashboard-bridge-help-button-secondary {
  background: rgba(15, 23, 42, 0.04);
  border-color: rgba(15, 23, 42, 0.14);
  color: var(--ds-text-secondary);
}

html.ui-premium #dashboard-view .dashboard-bridge-help-button:disabled {
  opacity: 0.65;
  cursor: not-allowed;
  transform: none;
}

html.ui-premium #dashboard-view .dashboard-supplier-alerts-hub .dashboard-supplier-refresh-button {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: auto;
  min-height: 40px;
  padding: 0 16px;
}

html.ui-premium #dashboard-view .dashboard-supplier-refresh-btn-icon::before {
  content: "↻";
  font-size: 1rem;
  line-height: 1;
  opacity: 0.9;
}

html.ui-premium #dashboard-view .dashboard-supplier-refresh-zone.is-running .dashboard-supplier-refresh-btn-icon::before {
  display: inline-block;
  animation: supplier-refresh-spin 0.85s linear infinite;
}

html.ui-premium #dashboard-view .dashboard-supplier-refresh-panel {
  padding: 14px 16px;
  border-radius: var(--ds-radius-lg);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(247, 250, 255, 0.96) 100%);
  border: 1px solid rgba(37, 99, 235, 0.14);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.7),
    0 8px 24px rgba(37, 99, 235, 0.08);
}

html.ui-premium #dashboard-view .dashboard-supplier-refresh-panel[hidden] {
  display: none !important;
}

html.ui-premium #dashboard-view .dashboard-supplier-refresh-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
  font-variant-numeric: tabular-nums;
}

html.ui-premium #dashboard-view .dashboard-supplier-refresh-panel-title-wrap {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

html.ui-premium #dashboard-view .dashboard-supplier-refresh-panel-spinner {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid rgba(37, 99, 235, 0.18);
  border-top-color: var(--ds-action);
  animation: supplier-refresh-spin 0.75s linear infinite;
}

html.ui-premium #dashboard-view .dashboard-supplier-refresh-panel-title {
  font-size: var(--ds-text-sm);
  font-weight: 650;
  color: var(--ds-text);
}

html.ui-premium #dashboard-view .dashboard-supplier-alerts-hub .dashboard-supplier-progress-track {
  height: 7px;
  border-radius: 999px;
  margin-top: 6px;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.055);
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.05);
}

html.ui-premium #dashboard-view .dashboard-supplier-alerts-hub .dashboard-supplier-progress-fill {
  border-radius: 999px;
  transition: width 0.4s var(--ds-ease-premium);
  box-shadow: 0 0 10px rgba(0, 149, 200, 0.22);
}

html.ui-premium #dashboard-view .dashboard-supplier-alerts-hub .dashboard-supplier-progress-detail {
  margin-top: 6px;
  font-size: 0.65625rem;
  line-height: 1.35;
  text-align: center;
  color: var(--ds-text-secondary);
}

html.ui-premium #dashboard-view .dashboard-supplier-alerts-toolbar {
  margin-bottom: 0;
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-toolbar-surface {
  padding: 8px 10px;
  border-radius: var(--ds-radius-lg);
  background: rgba(248, 250, 252, 0.95);
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.05);
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-summary-grid {
  gap: 8px;
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-summary-card {
  padding: 10px 11px;
}

html.ui-premium #dashboard-view .supplier-alert-section {
  padding: 9px 11px 10px;
}

html.ui-premium #dashboard-view .supplier-alert-section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
  padding-bottom: 6px;
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
}

html.ui-premium #dashboard-view .supplier-alert-section-good {
  background: rgba(240, 253, 250, 0.72);
  box-shadow: inset 0 0 0 1px rgba(5, 150, 105, 0.14);
}

html.ui-premium #dashboard-view .supplier-alert-section-neutral {
  background: rgba(239, 246, 255, 0.65);
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.12);
}

html.ui-premium #dashboard-view .supplier-alert-section-count-neutral {
  border: none;
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.18);
  background: rgba(37, 99, 235, 0.08);
  color: var(--ds-text);
}

html.ui-premium #dashboard-view .supplier-alert-price-row {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: nowrap;
  gap: 0.4rem 0.55rem;
  width: 100%;
  font-variant-numeric: tabular-nums;
}

html.ui-premium #dashboard-view .supplier-alert-price-prev {
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--ds-text-secondary);
}

html.ui-premium #dashboard-view .supplier-alert-price-arrow {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--ds-text-muted);
  opacity: 0.45;
  flex-shrink: 0;
}

html.ui-premium #dashboard-view .supplier-alert-price-new {
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--ds-text);
}

html.ui-premium #dashboard-view .supplier-alert-price-stack {
  gap: 5px;
}

html.ui-premium #dashboard-view .supplier-alert-status-pill {
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.06);
}

html.ui-premium #dashboard-view .supplier-alert-status-button {
  border-radius: 9px;
  font-weight: 600;
  letter-spacing: 0.02em;
  border: 1px solid rgba(15, 23, 42, 0.08);
  transition:
    background-color var(--ds-duration-fast) var(--ds-ease-premium),
    border-color var(--ds-duration-fast) var(--ds-ease-premium),
    box-shadow var(--ds-duration-fast) var(--ds-ease-premium),
    transform var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium #dashboard-view .supplier-alert-status-button:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
}

html.ui-premium #dashboard-view .supplier-alert-status-button:disabled {
  transform: none;
  box-shadow: none;
}

html.ui-premium #dashboard-view .supplier-alert-card {
  padding: 8px 10px;
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-history-cta {
  margin-top: 2px;
  display: flex;
  justify-content: center;
}

/* -------------------------------------------------------------------------- */
/* Pilotage Restaurant — mode dense analytique                                */
/* -------------------------------------------------------------------------- */
html.ui-premium #overview-view {
  display: grid;
  gap: 10px;
}

html.ui-premium #overview-view .panel {
  padding: 14px 16px;
  border: none;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.06),
    0 4px 18px rgba(15, 23, 42, 0.05),
    0 1px 0 rgba(15, 23, 42, 0.03);
}

html.ui-premium #overview-view .radar-panel .panel-head,
html.ui-premium #overview-view .simulator-panel .panel-head {
  margin-bottom: 8px;
}

html.ui-premium #overview-view .radar-panel .panel-head {
  justify-content: flex-start;
  text-align: left;
}

html.ui-premium #overview-view .pricing-advisor-panel .panel-head {
  justify-content: flex-start;
  text-align: left;
}

html.ui-premium #overview-view .radar-title,
html.ui-premium #overview-view .simulator-title,
html.ui-premium #overview-view .pricing-advisor-title {
  font-size: 0.84rem;
  font-weight: 650;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ds-camping-paradis-blue);
}

html.ui-premium #overview-view .overview-strips {
  display: grid;
  grid-template-columns: 1fr;
  width: 100%;
  margin-top: 0;
}

html.ui-premium #overview-view .overview-analytics-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  border-radius: 10px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.96);
  overflow: hidden;
}

html.ui-premium #overview-view .overview-analytics-head,
html.ui-premium #overview-view .overview-analytics-row {
  display: grid;
  grid-template-columns: 2fr 1fr 0.65fr 0.85fr 1fr 0.7fr;
  align-items: center;
  column-gap: 12px;
}

html.ui-premium #overview-view .overview-analytics-head {
  min-height: 36px;
  padding: 0 14px;
  background: rgba(248, 250, 252, 0.9);
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

html.ui-premium #overview-view .overview-analytics-head-cell {
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ds-text-muted);
  white-space: nowrap;
}

html.ui-premium #overview-view .overview-analytics-head-cell:nth-child(2) {
  text-align: center;
}

html.ui-premium #overview-view .overview-analytics-head-cell:nth-child(3),
html.ui-premium #overview-view .overview-analytics-head-cell:nth-child(4),
html.ui-premium #overview-view .overview-analytics-head-cell:nth-child(5) {
  text-align: center;
  justify-self: center;
}

html.ui-premium #overview-view .overview-analytics-head-cell:nth-child(6) {
  text-align: right;
}

html.ui-premium #overview-view .overview-analytics-row {
  min-height: 56px;
  max-height: 56px;
  width: 100%;
  padding: 0 14px;
  border: 0;
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
  background: rgba(255, 255, 255, 0.96);
  text-align: left;
  cursor: pointer;
  transition: background-color var(--ds-duration-fast) var(--ds-ease-premium),
    box-shadow var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium #overview-view .overview-analytics-row:last-child {
  border-bottom: none;
}

html.ui-premium #overview-view .overview-analytics-row:hover {
  background: rgba(37, 99, 235, 0.05);
  box-shadow:
    inset 2px 0 0 rgba(37, 99, 235, 0.35),
    0 2px 10px rgba(37, 99, 235, 0.06);
}

html.ui-premium #overview-view .overview-analytics-cell {
  min-width: 0;
  font-size: 0.76rem;
  color: var(--ds-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-variant-numeric: tabular-nums;
}

html.ui-premium #overview-view .overview-analytics-cell-category {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

html.ui-premium #overview-view .overview-analytics-category {
  font-size: 0.79rem;
  font-weight: 620;
  color: var(--ds-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

html.ui-premium #overview-view .overview-analytics-meta {
  font-size: 0.62rem;
  color: var(--ds-text-muted);
}

html.ui-premium #overview-view .overview-analytics-cell-margin,
html.ui-premium #overview-view .overview-analytics-cell-count,
html.ui-premium #overview-view .overview-analytics-cell-target {
  text-align: center;
  font-weight: 620;
}

html.ui-premium #overview-view .overview-analytics-cell-margin {
  font-size: 0.92rem;
  font-weight: 760;
}

html.ui-premium #overview-view .overview-analytics-cell-margin-good {
  color: var(--ds-success);
}

html.ui-premium #overview-view .overview-analytics-cell-margin-alert {
  color: var(--ds-warning);
}

html.ui-premium #overview-view .overview-analytics-cell-margin-danger {
  color: var(--ds-danger);
}

html.ui-premium #overview-view .overview-analytics-cell-action {
  text-align: right;
  display: flex;
  justify-content: flex-end;
}

html.ui-premium #overview-view .overview-analytics-open-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 0.2rem 0.68rem;
  border-radius: 999px;
  background: var(--ds-camping-paradis-blue);
  color: #ffffff;
  border: 1px solid rgba(0, 149, 200, 0.45);
  font-size: 0.64rem;
  font-weight: 620;
  letter-spacing: 0.02em;
  box-shadow: 0 3px 10px rgba(0, 149, 200, 0.2);
  transition: transform var(--ds-duration-fast) var(--ds-ease-premium),
    background-color var(--ds-duration-fast) var(--ds-ease-premium),
    box-shadow var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium #overview-view .overview-analytics-row:hover .overview-analytics-open-button {
  background: #007fc0;
  box-shadow: 0 6px 16px rgba(0, 149, 200, 0.24);
  transform: translateY(-2px);
}

html.ui-premium #overview-view .overview-analytics-state {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 22px;
  border-radius: 999px;
  padding: 0.14rem 0.48rem;
  font-size: 0.58rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border: 1px solid transparent;
}

html.ui-premium #overview-view .overview-analytics-cell-state {
  display: flex;
  justify-content: center;
  align-items: center;
}

html.ui-premium #overview-view .overview-analytics-state-good {
  background: var(--ds-success-soft);
  color: var(--ds-success);
  border-color: rgba(5, 150, 105, 0.2);
}

html.ui-premium #overview-view .overview-analytics-state-alert {
  background: var(--ds-warning-soft);
  color: var(--ds-warning);
  border-color: rgba(217, 119, 6, 0.24);
}

html.ui-premium #overview-view .overview-analytics-state-danger {
  background: var(--ds-danger-soft);
  color: var(--ds-danger);
  border-color: rgba(220, 38, 38, 0.22);
}

html.ui-premium #overview-view .overview-layout {
  grid-template-columns: 1fr;
  gap: 10px;
}

html.ui-premium #overview-view .radar-panel,
html.ui-premium #overview-view .simulator-panel,
html.ui-premium #overview-view .pricing-advisor-panel {
  width: 100%;
}

html.ui-premium #overview-view .market-pricing-advisor {
  width: 100%;
  max-width: none;
  margin: 0;
}

html.ui-premium #overview-view .simulator-stack {
  display: grid;
  grid-template-columns: minmax(280px, 2fr) minmax(230px, 1.2fr) minmax(140px, 0.8fr) minmax(140px, 0.8fr);
  gap: 8px;
  align-items: stretch;
}

html.ui-premium #overview-view .simulator-controls-card,
html.ui-premium #overview-view .sim-focus-card,
html.ui-premium #overview-view .simulator-stack > .simulator-fields,
html.ui-premium #overview-view .sim-results {
  margin: 0;
  min-height: 0;
}

html.ui-premium #overview-view .simulator-controls-card,
html.ui-premium #overview-view .sim-focus-card {
  padding: 10px 12px;
  border-radius: 12px;
  border: none;
  background: rgba(255, 255, 255, 0.94);
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.06),
    0 4px 14px rgba(15, 23, 42, 0.04);
}

html.ui-premium #overview-view .simulator-controls-card {
  grid-column: 1 / -1;
}

html.ui-premium #overview-view .sim-focus-card {
  grid-column: 1 / 3;
  display: grid;
  gap: 6px;
}

html.ui-premium #overview-view .sim-focus-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
}

html.ui-premium #overview-view .sim-focus-grid .strip-meta-card {
  min-height: 0;
  padding: 6px 8px;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

html.ui-premium #overview-view .sim-focus-grid .strip-meta-card span {
  font-size: 0.6rem;
  color: var(--ds-text-muted);
}

html.ui-premium #overview-view .sim-focus-grid .strip-meta-card strong {
  font-size: 0.86rem;
  font-weight: 700;
}

html.ui-premium #overview-view .sim-focus-grid .strip-meta-card-good strong {
  color: var(--ds-success);
}

html.ui-premium #overview-view .sim-focus-grid .strip-meta-card-alert strong {
  color: var(--ds-warning);
}

html.ui-premium #overview-view .sim-focus-grid .strip-meta-card-danger strong {
  color: var(--ds-danger);
}

html.ui-premium #overview-view .simulator-stack > .simulator-fields {
  grid-column: 3 / 5;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  align-items: stretch;
}

html.ui-premium #overview-view .simulator-toolbar,
html.ui-premium #overview-view .simulator-field-wide,
html.ui-premium #overview-view .sim-dish-combobox,
html.ui-premium #overview-view .sim-dish-trigger {
  width: 100%;
  max-width: 100%;
}

html.ui-premium #overview-view .simulator-stack > .simulator-fields .simulator-field {
  min-height: 0;
}

html.ui-premium #overview-view .simulator-stack > .simulator-fields .simulator-field input {
  min-height: 38px;
}

html.ui-premium #overview-view .sim-results {
  grid-column: 1 / -1;
  padding: 10px 12px;
  border-radius: 10px;
  width: 100%;
  overflow: visible;
  border: none;
  background: rgba(255, 255, 255, 0.94);
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.06),
    0 4px 14px rgba(15, 23, 42, 0.04);
}

html.ui-premium .app-back-toolbar {
  position: sticky;
  top: calc(var(--overview-sticky-top) + var(--overview-tabs-stack-height) + var(--overview-sticky-gap));
  z-index: 33;
  padding: 0;
  margin-bottom: 8px;
  width: max-content;
  max-width: 100%;
  background: transparent;
  backdrop-filter: none;
}

html.ui-premium .restaurant-margins-sticky-chrome .app-back-toolbar {
  position: relative;
  top: auto;
  left: auto;
  transform: none;
  z-index: 2;
  margin: 0;
  padding: 0;
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

html.ui-premium #overview-view .sim-results-header {
  margin-bottom: 6px;
}

html.ui-premium #overview-view .sim-results-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

html.ui-premium #overview-view .sim-results-title {
  color: var(--ds-camping-paradis-blue);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-size: 0.68rem;
}

html.ui-premium #overview-view .sim-results-note {
  color: var(--ds-text-muted);
  font-size: 0.64rem;
}

html.ui-premium #overview-view .sim-result-card {
  min-height: 84px;
  padding: 8px 10px;
  flex: 0 1 calc((100% - 16px) / 3);
  max-width: calc((100% - 16px) / 3);
}

html.ui-premium #overview-view .sim-result-card strong {
  font-size: 1.06rem;
}

html.ui-premium #overview-view .sim-result-card span {
  font-size: 0.6rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  white-space: normal;
  line-height: 1.25;
}

html.ui-premium #overview-view .sim-result-card[data-primary="true"] {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(241, 247, 255, 0.96) 100%);
  border-color: rgba(37, 99, 235, 0.2);
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.08);
}

html.ui-premium #overview-view .sim-result-card[data-primary="true"] strong,
html.ui-premium #overview-view .sim-result-card.result-card-highlight strong {
  font-size: 1.06rem;
}

html.ui-premium #overview-view .sim-results-grid .sim-result-card:nth-child(2) {
  margin-left: auto;
  margin-right: auto;
}

html.ui-premium #overview-view .sim-results-grid .sim-result-card:nth-child(4),
html.ui-premium #overview-view .sim-results-grid .sim-result-card:nth-child(5) {
  text-align: center;
  align-items: center;
  justify-content: center;
}

@media (max-width: 1220px) {
  html.ui-premium #overview-view .overview-layout {
    grid-template-columns: 1fr;
  }

  html.ui-premium #overview-view .simulator-stack {
    grid-template-columns: 1fr 1fr;
  }

  html.ui-premium #overview-view .simulator-controls-card {
    grid-column: 1 / -1;
  }

  html.ui-premium #overview-view .sim-focus-card {
    grid-column: 1 / -1;
  }

  html.ui-premium #overview-view .simulator-stack > .simulator-fields {
    grid-column: 1 / -1;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  html.ui-premium #overview-view .sim-focus-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  html.ui-premium #overview-view .sim-result-card {
    flex-basis: calc((100% - 8px) / 2);
    max-width: calc((100% - 8px) / 2);
  }

  html.ui-premium #overview-view .overview-analytics-head,
  html.ui-premium #overview-view .overview-analytics-row {
    grid-template-columns: 1.8fr 1fr 0.7fr 0.8fr 0.9fr 0.7fr;
  }
}

@media (max-width: 760px) {
  html.ui-premium #overview-view .simulator-stack {
    grid-template-columns: 1fr;
  }

  html.ui-premium #overview-view .sim-focus-card,
  html.ui-premium #overview-view .simulator-stack > .simulator-fields,
  html.ui-premium #overview-view .sim-results {
    grid-column: 1 / -1;
  }

  html.ui-premium #overview-view .overview-analytics-list {
    overflow-x: auto;
  }

  html.ui-premium #overview-view .overview-analytics-head,
  html.ui-premium #overview-view .overview-analytics-row {
    min-width: 640px;
  }

  html.ui-premium #overview-view .sim-focus-grid,
  html.ui-premium #overview-view .sim-results-grid {
    grid-template-columns: 1fr;
  }

  html.ui-premium #overview-view .sim-result-card {
    flex-basis: 100%;
    max-width: 100%;
  }
}

/* -------------------------------------------------------------------------- */
/* Dashboard only — professional refinement pass                              */
/* -------------------------------------------------------------------------- */
html.ui-premium #dashboard-view {
  gap: 12px;
}

html.ui-premium #dashboard-view > .panel,
html.ui-premium #dashboard-view .dashboard-suppliers-grid .panel {
  padding: 14px 16px;
  border-radius: 14px;
  border: none;
  background: rgba(255, 255, 255, 0.94);
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.045),
    0 3px 12px rgba(15, 23, 42, 0.04);
}

html.ui-premium #dashboard-view .panel-head {
  margin-bottom: 8px;
  min-height: 42px;
  display: flex;
  align-items: flex-start;
}

html.ui-premium #dashboard-view .panel-head h2.dashboard-section-title {
  font-size: 0.78rem;
  letter-spacing: 0.1em;
}

html.ui-premium #dashboard-view .dashboard-panel-copy {
  margin-top: 4px;
  font-size: 0.74rem;
  line-height: 1.35;
  color: var(--ds-text-muted);
}

html.ui-premium #dashboard-view .dashboard-hero-panel {
  gap: 12px;
  padding: 14px 16px;
}

html.ui-premium #dashboard-view .dashboard-kpi-grid {
  gap: 10px;
}

html.ui-premium #dashboard-view .dashboard-kpi-card {
  min-height: 170px;
  padding: 12px;
  border-radius: 12px;
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.05),
    0 3px 12px rgba(15, 23, 42, 0.045);
}

html.ui-premium #dashboard-view .dashboard-kpi-head {
  min-height: 30px;
}

html.ui-premium #dashboard-view .dashboard-kpi-mid {
  min-height: 74px;
}

html.ui-premium #dashboard-view .dashboard-kpi-value {
  font-size: clamp(2rem, 3.8vw, 3rem);
}

html.ui-premium #dashboard-view .dashboard-kpi-trend {
  min-height: 24px;
  padding: 3px 9px;
  font-size: 0.66rem;
}

html.ui-premium #dashboard-view .dashboard-refresh-button,
html.ui-premium #dashboard-view .dashboard-history-link-button,
html.ui-premium #dashboard-view .dashboard-history-back-button,
html.ui-premium #dashboard-view .dashboard-link-button {
  min-height: 34px;
  height: 34px;
  border-radius: 10px;
  padding: 0 12px;
  font-size: 0.75rem;
  font-weight: 620;
}

html.ui-premium #dashboard-view .dashboard-data-footer-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

html.ui-premium #dashboard-view .dashboard-data-footer-actions .dashboard-refresh-button-compact {
  width: 100%;
}

html.ui-premium #dashboard-view .dashboard-refresh-button:hover,
html.ui-premium #dashboard-view .dashboard-history-link-button:hover,
html.ui-premium #dashboard-view .dashboard-history-back-button:hover,
html.ui-premium #dashboard-view .dashboard-link-button:hover {
  transform: translateY(-1px);
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-summary-card {
  min-height: 78px;
  padding: 10px 11px;
  border-radius: 12px;
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.05),
    0 2px 10px rgba(15, 23, 42, 0.04);
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-summary-label {
  font-size: 0.62rem;
  letter-spacing: 0.06em;
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-summary-value {
  font-size: 1.25rem;
  line-height: 1;
}

html.ui-premium #dashboard-view .dashboard-supplier-alert-summary-detail {
  margin-top: 2px;
  font-size: 0.68rem;
}

html.ui-premium #dashboard-view .supplier-alert-list-head {
  min-height: 32px;
}

html.ui-premium #dashboard-view .supplier-alert-row {
  min-height: 58px;
  max-height: 58px;
  border-bottom: 1px solid rgba(15, 23, 42, 0.05);
}

html.ui-premium #dashboard-view .supplier-alert-cell {
  font-size: 0.72rem;
}

html.ui-premium #dashboard-view .supplier-alert-status-button {
  min-height: 28px;
  border-radius: 9px;
  font-size: 0.66rem;
}

html.ui-premium #dashboard-view .dashboard-chart-row {
  min-height: 74px;
  padding: 12px 14px;
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.05),
    0 2px 10px rgba(15, 23, 42, 0.04);
}

html.ui-premium #dashboard-view .dashboard-shortcuts-grid {
  gap: 10px;
}

html.ui-premium #dashboard-view .dashboard-shortcut-card {
  min-height: 86px;
  padding: 12px 13px;
  border-radius: 12px;
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.05),
    0 2px 10px rgba(15, 23, 42, 0.04);
}

html.ui-premium #dashboard-view .dashboard-shortcut-title {
  font-size: 0.82rem;
}

/* -------------------------------------------------------------------------- */
/* Pilotage (overview) — phase amélioration                                   */
/* -------------------------------------------------------------------------- */
html.ui-premium #overview-view {
  gap: 12px;
}

html.ui-premium #overview-view .panel-head {
  min-height: 40px;
  margin-bottom: 8px;
}

html.ui-premium #overview-view .panel-head > div {
  display: grid;
  gap: 2px;
}

html.ui-premium #overview-view .radar-title,
html.ui-premium #overview-view .simulator-title,
html.ui-premium #overview-view .pricing-advisor-title {
  font-size: 0.8rem;
  font-weight: 650;
  letter-spacing: 0.1em;
}

html.ui-premium #overview-view .overview-analytics-head {
  min-height: 34px;
}

html.ui-premium #overview-view .overview-analytics-row {
  min-height: 54px;
  max-height: 54px;
}

html.ui-premium #overview-view .overview-analytics-cell {
  font-size: 0.73rem;
}

html.ui-premium #overview-view .overview-analytics-cell-margin {
  font-size: 1.04rem;
  font-weight: 780;
}

html.ui-premium #overview-view .overview-analytics-category {
  font-size: 0.78rem;
}

html.ui-premium #overview-view .overview-analytics-meta {
  font-size: 0.6rem;
}

html.ui-premium #overview-view .simulator-controls-card,
html.ui-premium #overview-view .sim-focus-card,
html.ui-premium #overview-view .sim-results {
  border-radius: 12px;
}

html.ui-premium #overview-view .simulator-field-label,
html.ui-premium #overview-view .sim-results-note {
  font-size: 0.63rem;
}

html.ui-premium #overview-view .sim-result-card {
  min-height: 80px;
}

html.ui-premium #overview-view .sim-result-card span {
  font-size: 0.58rem;
}

html.ui-premium #overview-view .sim-result-card strong {
  font-size: 1rem;
}

html.ui-premium #dashboard-view .supplier-alert-section {
  padding: 8px 10px 10px;
}

html.ui-premium #dashboard-view .supplier-alert-section-head {
  margin-bottom: 8px;
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
  padding-bottom: 8px;
}

html.ui-premium #dashboard-view .supplier-alert-section-grid {
  display: flex;
  flex-direction: column;
  gap: 0;
  overflow-x: auto;
}

html.ui-premium #dashboard-view .supplier-alert-list-head,
html.ui-premium #dashboard-view .supplier-alert-row {
  min-width: 1120px;
  display: grid;
  grid-template-columns: 1.1fr 2.1fr 0.85fr 0.85fr 1.1fr 0.9fr 1.05fr 2.3fr;
  align-items: center;
  column-gap: 10px;
}

html.ui-premium #dashboard-view .supplier-alert-list-head {
  min-height: 34px;
  padding: 0 10px;
  border-radius: 10px;
  background: rgba(248, 250, 252, 0.95);
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.05);
  margin-bottom: 6px;
}

html.ui-premium #dashboard-view .supplier-alert-list-head-cell {
  font-size: 0.625rem;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ds-text-muted);
  white-space: nowrap;
}

html.ui-premium #dashboard-view .supplier-alert-list-head-cell:last-child {
  text-align: center;
}

html.ui-premium #dashboard-view .supplier-alert-row {
  min-height: 62px;
  max-height: 62px;
  padding: 0 10px;
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
  background: rgba(255, 255, 255, 0.78);
  transition: background-color var(--ds-duration-fast) var(--ds-ease-premium),
    box-shadow var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium #dashboard-view .supplier-alert-row:hover {
  background: rgba(37, 99, 235, 0.045);
  box-shadow: inset 2px 0 0 rgba(37, 99, 235, 0.35);
}

html.ui-premium #dashboard-view .supplier-alert-cell {
  min-width: 0;
  font-size: 0.75rem;
  color: var(--ds-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

html.ui-premium #dashboard-view .supplier-alert-row-title {
  display: block;
  font-size: 0.79rem;
  font-weight: 600;
  line-height: 1.25;
  color: var(--ds-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

html.ui-premium #dashboard-view .supplier-alert-row-meta {
  display: block;
  margin-top: 1px;
  font-size: 0.64rem;
  color: var(--ds-text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

html.ui-premium #dashboard-view .supplier-alert-priority {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 22px;
  border-radius: 999px;
  padding: 0.12rem 0.48rem;
  font-size: 0.58rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  background: rgba(15, 23, 42, 0.05);
  color: var(--ds-text-secondary);
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.08);
}

html.ui-premium #dashboard-view .supplier-alert-priority-critique {
  background: rgba(220, 38, 38, 0.12);
  color: var(--ds-danger);
  box-shadow: inset 0 0 0 1px rgba(220, 38, 38, 0.2);
}

html.ui-premium #dashboard-view .supplier-alert-priority-attention {
  background: rgba(217, 119, 6, 0.12);
  color: var(--ds-warning);
  box-shadow: inset 0 0 0 1px rgba(217, 119, 6, 0.2);
}

html.ui-premium #dashboard-view .supplier-alert-priority-info {
  background: rgba(37, 99, 235, 0.1);
  color: var(--ds-action);
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.18);
}

html.ui-premium #dashboard-view .supplier-alert-cell-price-old {
  color: var(--ds-text-muted);
  text-decoration: line-through;
  text-decoration-thickness: 1px;
  text-decoration-color: rgba(100, 116, 139, 0.5);
}

html.ui-premium #dashboard-view .supplier-alert-cell-price-new {
  font-weight: 700;
  color: var(--ds-text);
}

html.ui-premium #dashboard-view .supplier-alert-cell-variation {
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: -0.01em;
}

html.ui-premium #dashboard-view .supplier-alert-cell-variation-good {
  color: var(--ds-success);
}

html.ui-premium #dashboard-view .supplier-alert-cell-variation-danger {
  color: var(--ds-danger);
}

html.ui-premium #dashboard-view .supplier-alert-cell-impact,
html.ui-premium #dashboard-view .supplier-alert-cell-recipes {
  text-align: center;
  font-variant-numeric: tabular-nums;
}

html.ui-premium #dashboard-view .supplier-alert-cell-status .supplier-alert-status-summary {
  display: flex;
  align-items: center;
  gap: 6px;
}

html.ui-premium #dashboard-view .supplier-alert-cell-status .supplier-alert-processed-date {
  font-size: 0.62rem;
  color: var(--ds-text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

html.ui-premium #dashboard-view .supplier-alert-cell-actions .supplier-alert-status-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
  align-items: center;
  overflow: visible;
  padding-bottom: 0;
}

html.ui-premium #dashboard-view .supplier-alert-cell-actions .supplier-alert-status-button {
  min-height: 29px;
  padding: 0.3rem 0.65rem;
  font-size: 0.68rem;
  font-weight: 650;
  white-space: nowrap;
  flex: 0 0 auto;
}

html.ui-premium #dashboard-view .dashboard-supplier-monitoring {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

html.ui-premium #dashboard-view .dashboard-supplier-monitoring.supplier-trend-shell {
  gap: 10px;
}

html.ui-premium #dashboard-view .supplier-trend-toolbar {
  grid-column: 1 / -1;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  padding: 2px 2px 6px;
}

html.ui-premium #dashboard-view .supplier-trend-toolbar-title {
  display: block;
  font-size: 0.9rem;
  font-weight: 650;
  color: var(--ds-text-primary);
}

html.ui-premium #dashboard-view .supplier-trend-toolbar-note {
  display: block;
  margin-top: 3px;
  font-size: 0.75rem;
  color: var(--ds-text-muted);
}

html.ui-premium .app-segment-switch,
html.ui-premium .supplier-trend-period-switch {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.04);
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.06);
}

html.ui-premium .app-segment-button,
html.ui-premium #dashboard-view .supplier-trend-period-button {
  min-height: 32px;
  padding: 0 12px;
  border: none;
  border-radius: 999px;
  background: transparent;
  color: var(--ds-text-muted);
  font-size: 0.72rem;
  font-weight: 650;
  cursor: pointer;
  transition: background-color var(--ds-duration-fast) var(--ds-ease-premium),
    color var(--ds-duration-fast) var(--ds-ease-premium),
    box-shadow var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium .app-segment-button[data-active="true"],
html.ui-premium #dashboard-view .supplier-trend-period-button[data-active="true"] {
  background: #fff;
  color: var(--ds-text-primary);
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.08);
}

html.ui-premium .app-supplier-switch-host {
  display: flex;
  justify-content: flex-end;
}

html.ui-premium #purchases-view .app-supplier-switch-host {
  justify-content: flex-start;
}

html.ui-premium #purchases-view .app-segment-switch {
  width: min(100%, 620px);
}

html.ui-premium .supplier-links-supplier-filter-block .app-segment-switch {
  width: min(100%, 680px);
}

html.ui-premium .dashboard-supplier-monitoring--quad {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  align-items: start;
}

html.ui-premium .dashboard-supplier-monitoring--quad .supplier-trend-toolbar {
  grid-column: 1 / -1;
}

html.ui-premium .dashboard-supplier-monitoring--quad .supplier-trend-global-link {
  grid-column: 1 / -1;
}

@media (max-width: 900px) {
  html.ui-premium .dashboard-supplier-monitoring--quad {
    grid-template-columns: 1fr;
  }
}

html.ui-premium #dashboard-view .supplier-trend-chart-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 0;
  padding: 12px 12px 10px;
  border-radius: 14px;
  background: linear-gradient(165deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 251, 255, 0.94) 100%);
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.06),
    0 8px 28px rgba(15, 23, 42, 0.06);
}

html.ui-premium #dashboard-view .supplier-trend-chart-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

html.ui-premium #dashboard-view .supplier-trend-chart-title {
  display: block;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

html.ui-premium #dashboard-view .supplier-trend-chart-subtitle {
  display: block;
  margin-top: 3px;
  font-size: 0.72rem;
  color: var(--ds-text-muted);
}

html.ui-premium #dashboard-view .supplier-trend-global {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto auto;
  gap: 1px 8px;
  min-width: 128px;
  padding: 8px 10px;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.03);
}

html.ui-premium #dashboard-view .supplier-trend-global-alert {
  background: linear-gradient(145deg, rgba(255, 247, 242, 0.98), rgba(255, 252, 250, 0.96));
  box-shadow: inset 0 0 0 1px rgba(234, 88, 12, 0.12);
}

html.ui-premium #dashboard-view .supplier-trend-global-good {
  background: linear-gradient(145deg, rgba(240, 253, 244, 0.98), rgba(255, 255, 255, 0.96));
  box-shadow: inset 0 0 0 1px rgba(22, 163, 74, 0.12);
}

html.ui-premium #dashboard-view .supplier-trend-global-value {
  grid-column: 1;
  grid-row: 1 / span 2;
  align-self: center;
  font-size: 1.15rem;
  font-weight: 750;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

html.ui-premium #dashboard-view .supplier-trend-global-label,
html.ui-premium #dashboard-view .supplier-trend-global-meta {
  font-size: 0.68rem;
  color: var(--ds-text-muted);
}

html.ui-premium #dashboard-view .supplier-trend-sparkline {
  grid-column: 1 / -1;
  width: 100%;
  height: 24px;
}

html.ui-premium #dashboard-view .supplier-trend-sparkline-area-alert {
  fill: rgba(234, 88, 12, 0.16);
}

html.ui-premium #dashboard-view .supplier-trend-sparkline-area-good {
  fill: rgba(22, 163, 74, 0.14);
}

html.ui-premium #dashboard-view .supplier-trend-sparkline-area-neutral {
  fill: rgba(59, 130, 246, 0.12);
}

html.ui-premium #dashboard-view .supplier-trend-sparkline-line-alert {
  fill: none;
  stroke: rgba(234, 88, 12, 0.9);
  stroke-width: 2;
}

html.ui-premium #dashboard-view .supplier-trend-sparkline-line-good {
  fill: none;
  stroke: rgba(22, 163, 74, 0.9);
  stroke-width: 2;
}

html.ui-premium #dashboard-view .supplier-trend-sparkline-line-neutral {
  fill: none;
  stroke: rgba(59, 130, 246, 0.85);
  stroke-width: 2;
}

html.ui-premium #dashboard-view .supplier-trend-sparkline-flat {
  stroke: rgba(148, 163, 184, 0.45);
  stroke-width: 1.5;
  stroke-dasharray: 4 4;
}

html.ui-premium #dashboard-view .supplier-trend-chart-body {
  display: flex;
  flex-direction: column;
  gap: 5px;
  max-height: 280px;
  overflow-y: auto;
  padding-right: 2px;
}

html.ui-premium #dashboard-view .supplier-trend-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 4px;
  padding: 5px 8px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.04);
  transition: transform var(--ds-duration-fast) var(--ds-ease-premium),
    box-shadow var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium #dashboard-view .supplier-trend-row-main[role="button"] {
  cursor: pointer;
}

html.ui-premium #dashboard-view .supplier-trend-row-main[role="button"]:hover,
html.ui-premium #dashboard-view .supplier-trend-row-main[role="button"]:focus-visible {
  transform: translateY(-1px);
}

html.ui-premium #dashboard-view .supplier-trend-row-label {
  font-size: 0.78rem;
  font-weight: 650;
}

html.ui-premium #dashboard-view .supplier-trend-row-track {
  position: relative;
  height: 6px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.06);
}

html.ui-premium #dashboard-view .supplier-trend-row-fill {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(59, 130, 246, 0.55), rgba(37, 99, 235, 0.92));
}

html.ui-premium #dashboard-view .supplier-trend-row-fill-alert {
  background: linear-gradient(90deg, rgba(251, 146, 60, 0.65), rgba(234, 88, 12, 0.95));
}

html.ui-premium #dashboard-view .supplier-trend-row-fill-good {
  background: linear-gradient(90deg, rgba(74, 222, 128, 0.55), rgba(22, 163, 74, 0.92));
}

html.ui-premium #dashboard-view .supplier-trend-row-values {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  min-width: 72px;
}

html.ui-premium #dashboard-view .supplier-trend-row-rate {
  font-size: 0.82rem;
  font-weight: 700;
}

html.ui-premium #dashboard-view .supplier-trend-row-meta {
  font-size: 0.64rem;
  color: var(--ds-text-muted);
}

html.ui-premium #dashboard-view .supplier-trend-chart-empty {
  min-height: 88px;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 14px 12px;
  font-size: 0.8rem;
}

html.ui-premium #dashboard-view .dashboard-supplier-summary-strip {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

html.ui-premium #dashboard-view .supplier-trend-row-main {
  display: grid;
  grid-template-columns: minmax(80px, 0.85fr) minmax(0, 1.35fr) auto;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

html.ui-premium #dashboard-view .supplier-trend-row-menu-wrap {
  position: relative;
  flex: 0 0 auto;
}

html.ui-premium #dashboard-view .supplier-trend-row-menu-trigger {
  width: 28px;
  height: 28px;
  border: none;
  border-radius: 10px;
  background: transparent;
  color: var(--ds-text-muted);
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
  transition: background-color var(--ds-duration-fast) var(--ds-ease-premium),
    color var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium #dashboard-view .supplier-trend-row-menu-trigger:hover,
html.ui-premium #dashboard-view .supplier-trend-row-menu-trigger:focus-visible {
  background: rgba(15, 23, 42, 0.05);
  color: var(--ds-text-primary);
}

html.ui-premium #dashboard-view .supplier-trend-popover {
  position: absolute;
  right: 0;
  z-index: 12;
  min-width: 168px;
  padding: 6px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.14), inset 0 0 0 1px rgba(15, 23, 42, 0.06);
}

html.ui-premium #dashboard-view .supplier-trend-row-menu {
  top: calc(100% + 4px);
}

html.ui-premium #dashboard-view .supplier-trend-add-category-popover {
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  max-height: 220px;
  overflow: auto;
}

html.ui-premium #dashboard-view .supplier-trend-popover-action,
html.ui-premium #dashboard-view .supplier-trend-popover-option {
  display: block;
  width: 100%;
  min-height: 32px;
  padding: 0 10px;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: var(--ds-text-primary);
  font-size: 0.75rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
}

html.ui-premium #dashboard-view .supplier-trend-popover-action:hover,
html.ui-premium #dashboard-view .supplier-trend-popover-option:hover {
  background: rgba(15, 23, 42, 0.04);
}

html.ui-premium #dashboard-view .supplier-trend-popover-empty {
  display: block;
  padding: 8px 10px;
  font-size: 0.68rem;
  color: var(--ds-text-muted);
}

html.ui-premium #dashboard-view .supplier-trend-card-footer {
  display: flex;
  justify-content: center;
  padding-top: 12px;
  margin-top: 4px;
  border-top: 1px solid rgba(15, 23, 42, 0.05);
}

html.ui-premium #dashboard-view .supplier-trend-add-category-wrap {
  position: relative;
}

html.ui-premium #dashboard-view .supplier-trend-add-category-button,
html.ui-premium #dashboard-view .supplier-trend-global-link-button {
  min-height: 34px;
  padding: 0 14px;
  border: none;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.04);
  color: var(--ds-text-primary);
  font-size: 0.75rem;
  font-weight: 650;
  cursor: pointer;
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.07);
  transition: transform var(--ds-duration-fast) var(--ds-ease-premium),
    box-shadow var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium #dashboard-view .supplier-trend-add-category-button:hover,
html.ui-premium #dashboard-view .supplier-trend-global-link-button:hover {
  transform: translateY(-1px);
  box-shadow: var(--ds-shadow-panel);
}

html.ui-premium #dashboard-view .supplier-trend-global-link-wrap {
  grid-column: 1 / -1;
  display: flex;
  justify-content: center;
  padding-top: 6px;
}

html.ui-premium #dashboard-view .supplier-trend-global-link-button {
  min-width: 180px;
  background: linear-gradient(180deg, rgba(37, 99, 235, 0.1), rgba(37, 99, 235, 0.04));
  color: rgb(30, 64, 175);
}

html.ui-premium #dashboard-supplier-trends-global-view .panel-head {
  margin-bottom: 14px;
}

html.ui-premium #dashboard-supplier-trends-global-view .panel-head h2.dashboard-section-title {
  font-family: var(--ds-font-sans);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ds-text-secondary);
}

html.ui-premium #dashboard-supplier-trends-global-view .dashboard-panel-copy {
  margin-top: 6px;
  font-size: 0.875rem;
  color: var(--ds-text-muted);
  line-height: 1.5;
  font-weight: 400;
  max-width: 52ch;
}

html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-panel {
  padding: 28px;
}

html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-shell {
  display: grid;
  gap: 16px;
}

html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-suppliers {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-supplier-card {
  display: grid;
  gap: 3px;
  padding: 9px 11px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.06);
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-supplier-card-sysco,
html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-chart-card-sysco {
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.14);
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-supplier-card-relais-dor {
  box-shadow: inset 0 0 0 1px rgba(180, 83, 9, 0.14);
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-supplier-card-merged {
  background: linear-gradient(165deg, rgba(248, 251, 255, 0.98), rgba(255, 255, 255, 0.96));
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-supplier-card-title {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-supplier-card-value {
  font-size: 1.1rem;
  font-weight: 750;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-supplier-card-counts,
html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-supplier-card-movements {
  font-size: 0.68rem;
  color: var(--ds-text-muted);
}

html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-copy {
  display: grid;
  gap: 6px;
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-toolbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-toolbar-controls-only {
  justify-content: flex-start;
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-toolbar-title {
  display: block;
  font-size: 0.9rem;
  font-weight: 650;
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-toolbar-note {
  display: block;
  margin-top: 3px;
  font-size: 0.75rem;
  color: var(--ds-text-muted);
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-period-switch {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.04);
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.06);
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-period-button {
  min-height: 32px;
  padding: 0 12px;
  border: none;
  border-radius: 999px;
  background: transparent;
  color: var(--ds-text-muted);
  font-size: 0.72rem;
  font-weight: 650;
  cursor: pointer;
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-period-button[data-active="true"] {
  background: #fff;
  color: var(--ds-text-primary);
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.08);
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-summary {
  display: grid;
  gap: 4px;
  justify-items: start;
  padding: 14px 16px;
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.03);
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-summary-alert {
  background: linear-gradient(145deg, rgba(255, 247, 242, 0.98), rgba(255, 252, 250, 0.96));
  box-shadow: inset 0 0 0 1px rgba(234, 88, 12, 0.12);
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-summary-good {
  background: linear-gradient(145deg, rgba(240, 253, 244, 0.98), rgba(255, 255, 255, 0.96));
  box-shadow: inset 0 0 0 1px rgba(22, 163, 74, 0.12);
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-summary-value {
  font-size: 1.5rem;
  font-weight: 750;
  letter-spacing: -0.03em;
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-summary-label,
html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-summary-meta {
  display: block;
  font-size: 0.75rem;
  color: var(--ds-text-muted);
}

html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-group {
  display: grid;
  gap: 10px;
  padding: 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.05);
}

html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-group-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-list {
  display: grid;
  gap: 8px;
}

html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-card {
  display: grid;
  gap: 6px;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.02);
}

html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-card-product {
  font-size: 0.82rem;
  line-height: 1.35;
}

html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-card-meta,
html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-card-date {
  display: block;
  font-size: 0.68rem;
  color: var(--ds-text-muted);
}

html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-card-rate {
  flex-shrink: 0;
  font-size: 0.82rem;
  font-weight: 700;
}

html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-card-rate-alert {
  color: rgb(194, 65, 12);
}

html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-card-rate-good {
  color: rgb(21, 128, 61);
}

html.ui-premium #dashboard-view .supplier-trend-chart-card-sysco .supplier-trend-chart-title,
html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-chart-card-sysco .supplier-trend-chart-title {
  color: rgb(30, 64, 175);
}

html.ui-premium #dashboard-view .supplier-trend-chart-card-relais-dor .supplier-trend-chart-title,
html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-chart-card-relais-dor .supplier-trend-chart-title {
  color: rgb(180, 83, 9);
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-chart-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 0;
  padding: 12px 12px 10px;
  border-radius: 14px;
  background: linear-gradient(165deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 251, 255, 0.94) 100%);
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.06),
    0 8px 28px rgba(15, 23, 42, 0.06);
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-chart-card-global .supplier-trend-chart-title {
  color: rgb(51, 65, 85);
}

@media (max-width: 960px) {
  html.ui-premium #dashboard-supplier-trends-global-view .dashboard-supplier-trends-global-suppliers {
    grid-template-columns: 1fr;
  }
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-chart-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-chart-body {
  display: flex;
  flex-direction: column;
  gap: 5px;
  max-height: 320px;
  overflow-y: auto;
  padding-right: 2px;
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 4px;
  padding: 5px 8px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.04);
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-row-main {
  display: grid;
  grid-template-columns: minmax(80px, 0.85fr) minmax(0, 1.35fr) auto;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-row-main[role="button"] {
  cursor: pointer;
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-row-label {
  font-size: 0.78rem;
  font-weight: 650;
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-row-track {
  position: relative;
  height: 6px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.06);
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-row-fill {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(59, 130, 246, 0.55), rgba(37, 99, 235, 0.92));
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-row-fill-alert {
  background: linear-gradient(90deg, rgba(251, 146, 60, 0.65), rgba(234, 88, 12, 0.95));
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-row-fill-good {
  background: linear-gradient(90deg, rgba(74, 222, 128, 0.55), rgba(22, 163, 74, 0.92));
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-row-values {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  min-width: 72px;
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-row-rate {
  font-size: 0.82rem;
  font-weight: 700;
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-row-meta {
  grid-column: 1 / -1;
  font-size: 0.64rem;
  line-height: 1.35;
  color: var(--ds-text-muted);
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto auto;
  gap: 1px 8px;
  min-width: 128px;
  padding: 8px 10px;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.03);
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-value {
  grid-column: 1;
  grid-row: 1 / span 2;
  align-self: center;
  font-size: 1.15rem;
  font-weight: 750;
  line-height: 1.1;
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-label,
html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-meta {
  display: block;
  font-size: 0.72rem;
  color: var(--ds-text-muted);
}

html.ui-premium #dashboard-supplier-trends-global-view .supplier-trend-global-meta {
  grid-column: 1 / -1;
  line-height: 1.35;
}

html.ui-premium #dashboard-view .dashboard-supplier-card {
  border-radius: 14px;
  border: none;
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.06),
    0 2px 12px rgba(15, 23, 42, 0.04);
  padding: 13px 14px;
  background: rgba(255, 255, 255, 0.9);
  transition: box-shadow var(--ds-duration-fast) var(--ds-ease-premium),
    transform var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium #dashboard-view .dashboard-supplier-card:hover {
  transform: translateY(-1px);
  box-shadow: var(--ds-shadow-panel);
}

html.ui-premium #dashboard-view .dashboard-suppliers-grid .panel {
  border-radius: var(--ds-radius-xl);
  border: 1px solid rgba(15, 23, 42, 0.055);
  box-shadow: var(--ds-shadow-panel);
}

html.ui-premium #dashboard-view .dashboard-chart-panel {
  background: rgba(255, 255, 255, 0.98);
}

html.ui-premium #dashboard-view .dashboard-chart {
  gap: 8px;
}

html.ui-premium #dashboard-view .dashboard-chart-row {
  border-radius: 14px;
  border: none;
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.06),
    0 2px 14px rgba(15, 23, 42, 0.05);
  background: rgba(255, 255, 255, 0.98);
  min-height: 80px;
  padding: 14px 16px;
  transition: transform var(--ds-duration-fast) var(--ds-ease-premium),
    box-shadow var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium #dashboard-view .dashboard-chart-row::before {
  left: 14px;
  right: 14px;
  height: 2px;
}

html.ui-premium #dashboard-view .dashboard-chart-row:hover,
html.ui-premium #dashboard-view .dashboard-chart-row:focus-visible {
  transform: translateY(-2px);
  box-shadow: var(--ds-shadow-panel-hover);
}

html.ui-premium #dashboard-view .dashboard-chart-title {
  font-size: 0.9375rem;
  font-weight: 650;
}

html.ui-premium #dashboard-view .dashboard-shortcuts-grid {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(170px, 1fr);
  grid-template-columns: unset;
  gap: 12px;
  overflow-x: auto;
  overflow-y: hidden;
  padding-bottom: 2px;
  scrollbar-width: thin;
}

html.ui-premium #dashboard-view .dashboard-shortcut-card {
  border-radius: 14px;
  border: none;
  box-shadow:
    inset 0 0 0 1px rgba(15, 23, 42, 0.06),
    0 2px 14px rgba(15, 23, 42, 0.05);
  padding: clamp(14px, 2vw, 18px);
  background: rgba(255, 255, 255, 0.95);
  transition: transform var(--ds-duration-fast) var(--ds-ease-premium),
    box-shadow var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium #dashboard-view .dashboard-shortcut-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--ds-shadow-panel-hover);
}

html.ui-premium #dashboard-view .dashboard-shortcut-title {
  font-size: 0.875rem;
  font-weight: 650;
}

html.ui-premium #dashboard-view .dashboard-data-footer-panel {
  padding: clamp(16px, 2vw, 22px);
  border: 1px solid rgba(15, 23, 42, 0.05);
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.7),
    0 1px 2px rgba(15, 23, 42, 0.04),
    0 10px 36px rgba(15, 23, 42, 0.06);
}

html.ui-premium #dashboard-view .dashboard-data-footer-head .dashboard-data-footer-title {
  font-family: var(--ds-font-sans);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ds-text-muted);
}

html.ui-premium #dashboard-view .dashboard-refresh-button,
html.ui-premium #dashboard-view .dashboard-history-link-button {
  transition: transform var(--ds-duration-fast) var(--ds-ease-premium),
    border-color var(--ds-duration-fast) var(--ds-ease-premium),
    background-color var(--ds-duration-fast) var(--ds-ease-premium),
    box-shadow var(--ds-duration-fast) var(--ds-ease-premium);
}

html.ui-premium #dashboard-view .dashboard-refresh-button:hover,
html.ui-premium #dashboard-view .dashboard-history-link-button:hover {
  transform: translateY(-1px);
}

@media (min-width: 1320px) {
  html.ui-premium #dashboard-view .supplier-alert-section-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 1220px) {
  html.ui-premium #dashboard-view .dashboard-hero-panel {
    grid-template-columns: 1fr;
  }

  html.ui-premium #dashboard-view .dashboard-hero-mini-kpis,
  html.ui-premium #dashboard-view .dashboard-kpi-grid,
  html.ui-premium #dashboard-view .dashboard-supplier-monitoring {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  html.ui-premium #dashboard-view .supplier-alert-section-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  html.ui-premium {
    --app-topbar-sticky-offset: calc(4px + 108px + env(safe-area-inset-top, 0px) + 4px);
    --app-restaurant-margins-chrome-stack: 48px;
  }

  html.ui-premium #dashboard-view .dashboard-hero-mini-kpis,
  html.ui-premium #dashboard-view .dashboard-kpi-grid,
  html.ui-premium #dashboard-view .dashboard-supplier-monitoring {
    grid-template-columns: 1fr;
  }

  html.ui-premium .app-topbar {
    grid-template-columns: 1fr;
    gap: 10px;
  }
}

@media (max-width: 520px) {
  html.ui-premium {
    --app-restaurant-margins-chrome-stack: 52px;
  }
}

/* ===== Fournisseurs > Comparer : cartes côté supplier ===== */
html.ui-premium .supplier-compare-sides-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 14px;
}

html.ui-premium .supplier-compare-card-side {
  display: grid;
  gap: 6px;
  padding: 16px;
  border-radius: 16px;
  border: 1px solid rgba(15, 23, 42, 0.1);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(248, 250, 252, 0.94));
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.05);
}

html.ui-premium .supplier-compare-card-side-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

html.ui-premium .supplier-compare-card-side-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: rgba(15, 23, 42, 0.06);
  color: var(--ds-text, #0f172a);
}

html.ui-premium .supplier-compare-card-side-pill[data-supplier-slug="sysco"] {
  background: rgba(0, 149, 200, 0.12);
  color: rgb(0, 105, 145);
}

html.ui-premium .supplier-compare-card-side-pill[data-supplier-slug="relais-or"],
html.ui-premium .supplier-compare-card-side-pill[data-supplier-slug="relais-d-or"],
html.ui-premium .supplier-compare-card-side-pill[data-supplier-slug="relaisor"] {
  background: rgba(217, 119, 6, 0.12);
  color: rgb(146, 64, 14);
}

html.ui-premium .supplier-compare-card-side-product {
  font-size: 1rem;
  font-weight: 700;
  color: var(--ds-text, #0f172a);
  line-height: 1.25;
  word-break: break-word;
}

html.ui-premium .supplier-compare-card-side-product-empty {
  color: var(--ds-text-muted, rgba(15, 23, 42, 0.5));
  font-weight: 550;
  font-style: italic;
}

html.ui-premium .supplier-compare-card-side-ref {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--ds-text-secondary, rgba(15, 23, 42, 0.65));
  letter-spacing: 0.02em;
}

html.ui-premium .supplier-compare-card-side-price {
  font-size: 0.95rem;
  font-weight: 700;
  color: rgb(5, 150, 105);
  letter-spacing: -0.01em;
}

html.ui-premium .supplier-compare-card-side-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 10px;
}

html.ui-premium .supplier-compare-card-side-change,
html.ui-premium .supplier-compare-card-side-detach {
  flex: 0 0 auto;
  padding: 7px 14px;
  border-radius: 8px;
  font-size: 0.8rem;
  font-weight: 650;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition:
    background 0.12s ease,
    border-color 0.12s ease,
    transform 0.06s ease;
}

html.ui-premium .supplier-compare-card-side-change {
  background: var(--ds-accent, #0095c8);
  color: #ffffff;
  border: 1px solid var(--ds-accent, #0095c8);
}

html.ui-premium .supplier-compare-card-side-change:hover {
  background: rgb(0, 130, 175);
  border-color: rgb(0, 130, 175);
}

html.ui-premium .supplier-compare-card-side-change:active {
  transform: translateY(1px);
}

html.ui-premium .supplier-compare-card-side-detach {
  background: transparent;
  color: var(--ds-text-secondary, rgba(15, 23, 42, 0.7));
  border: 1px solid rgba(15, 23, 42, 0.14);
}

html.ui-premium .supplier-compare-card-side-detach:hover {
  background: rgba(15, 23, 42, 0.04);
  border-color: rgba(15, 23, 42, 0.22);
}

@media (max-width: 720px) {
  html.ui-premium .supplier-compare-sides-row {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ===== Popup de recherche de produit (Changer de produit) ===== */
html.ui-premium .supplier-product-picker-layer {
  position: fixed;
  inset: 0;
  z-index: 12000;
  display: none;
  pointer-events: none;
}

html.ui-premium .supplier-product-picker-layer[data-active="true"] {
  display: block;
  pointer-events: auto;
}

html.ui-premium .supplier-product-picker-host {
  position: absolute;
  inset: 0;
}

html.ui-premium .supplier-product-picker-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.42);
  backdrop-filter: blur(3px);
}

html.ui-premium .supplier-product-picker-panel {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(540px, calc(100% - 32px));
  max-height: calc(100vh - 48px);
  display: grid;
  grid-template-rows: auto auto 1fr;
  gap: 12px;
  padding: 22px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 30px 80px rgba(15, 23, 42, 0.32);
}

html.ui-premium .supplier-product-picker-head {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

html.ui-premium .supplier-product-picker-title-wrap {
  flex: 1 1 auto;
  display: grid;
  gap: 6px;
}

html.ui-premium .supplier-product-picker-pill {
  justify-self: start;
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: rgba(15, 23, 42, 0.06);
  color: var(--ds-text, #0f172a);
}

html.ui-premium .supplier-product-picker-pill[data-supplier-slug="sysco"] {
  background: rgba(0, 149, 200, 0.12);
  color: rgb(0, 105, 145);
}

html.ui-premium .supplier-product-picker-pill[data-supplier-slug="relais-or"],
html.ui-premium .supplier-product-picker-pill[data-supplier-slug="relais-d-or"],
html.ui-premium .supplier-product-picker-pill[data-supplier-slug="relaisor"] {
  background: rgba(217, 119, 6, 0.12);
  color: rgb(146, 64, 14);
}

html.ui-premium .supplier-product-picker-title {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--ds-text, #0f172a);
}

html.ui-premium .supplier-product-picker-subtitle {
  margin: 0;
  font-size: 0.82rem;
  line-height: 1.4;
  color: var(--ds-text-secondary, rgba(15, 23, 42, 0.65));
}

html.ui-premium .supplier-product-picker-close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: #ffffff;
  font-size: 1.2rem;
  font-weight: 600;
  cursor: pointer;
  color: var(--ds-text, #0f172a);
}

html.ui-premium .supplier-product-picker-close:hover {
  background: rgba(15, 23, 42, 0.04);
}

html.ui-premium .supplier-product-picker-search {
  display: grid;
  gap: 6px;
}

html.ui-premium .supplier-product-picker-search > span {
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--ds-text-secondary, rgba(15, 23, 42, 0.7));
}

html.ui-premium .supplier-product-picker-search input {
  width: 100%;
  min-height: 40px;
  padding: 9px 14px;
  border-radius: 10px;
  border: 1px solid rgba(15, 23, 42, 0.14);
  background: #ffffff;
  font-size: 0.92rem;
  font-family: inherit;
  color: var(--ds-text, #0f172a);
  box-sizing: border-box;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

html.ui-premium .supplier-product-picker-search input:focus {
  outline: none;
  border-color: rgba(0, 149, 200, 0.55);
  box-shadow: 0 0 0 3px rgba(0, 149, 200, 0.15);
}

html.ui-premium .supplier-product-picker-results {
  display: grid;
  gap: 6px;
  max-height: min(50vh, 480px);
  overflow-y: auto;
  padding-right: 4px;
}

html.ui-premium .supplier-product-picker-empty {
  margin: 0;
  padding: 14px;
  text-align: center;
  font-size: 0.84rem;
  font-style: italic;
  color: var(--ds-text-muted, rgba(15, 23, 42, 0.5));
}

html.ui-premium .supplier-product-picker-option {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 6px 12px;
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: #ffffff;
  text-align: left;
  cursor: pointer;
  transition:
    background 0.12s ease,
    border-color 0.12s ease,
    transform 0.06s ease;
}

html.ui-premium .supplier-product-picker-option:hover {
  background: rgba(0, 149, 200, 0.05);
  border-color: rgba(0, 149, 200, 0.3);
}

html.ui-premium .supplier-product-picker-option:active {
  transform: translateY(1px);
}

html.ui-premium .supplier-product-picker-option-name {
  grid-column: 1 / -1;
  font-size: 0.9rem;
  font-weight: 650;
  color: var(--ds-text, #0f172a);
  line-height: 1.25;
}

html.ui-premium .supplier-product-picker-option-ref {
  grid-column: 1;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--ds-text-secondary, rgba(15, 23, 42, 0.55));
}

html.ui-premium .supplier-product-picker-option-meta {
  grid-column: 2;
  justify-self: end;
  font-size: 0.72rem;
  color: var(--ds-text-muted, rgba(15, 23, 42, 0.55));
}

body.supplier-product-picker-open {
  overflow: hidden;
}

/* ===== Mercuriale > Modifier : nouvelle grille catégorie + sous-cat picker ===== */
html.ui-premium .mercuriale-edit-section-category {
  gap: 8px;
}

html.ui-premium .mercuriale-edit-category-current {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(0, 149, 200, 0.08);
  border: 1px solid rgba(0, 149, 200, 0.18);
}

html.ui-premium .mercuriale-edit-category-current-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgb(0, 105, 145);
}

html.ui-premium .mercuriale-edit-category-current-value {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--ds-text, #0f172a);
  letter-spacing: -0.005em;
}

html.ui-premium .mercuriale-edit-category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 8px;
  margin-top: 4px;
}

html.ui-premium .mercuriale-edit-category-chip {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: #ffffff;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ds-text, #0f172a);
  cursor: pointer;
  text-align: center;
  transition:
    background 0.12s ease,
    border-color 0.12s ease,
    transform 0.06s ease;
}

html.ui-premium .mercuriale-edit-category-chip:hover {
  background: rgba(0, 149, 200, 0.06);
  border-color: rgba(0, 149, 200, 0.35);
}

html.ui-premium .mercuriale-edit-category-chip:active {
  transform: translateY(1px);
}

html.ui-premium .mercuriale-edit-category-chip[data-active="true"] {
  background: rgba(0, 149, 200, 0.14);
  border-color: rgba(0, 149, 200, 0.45);
  color: rgb(0, 105, 145);
}

html.ui-premium .mercuriale-edit-category-chip--new {
  border-style: dashed;
  color: rgb(0, 105, 145);
}

html.ui-premium .mercuriale-edit-category-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 4px;
}

html.ui-premium .mercuriale-edit-category-change-button {
  padding: 10px 16px;
  font-weight: 600;
  font-size: 0.85rem;
  border-radius: 12px;
}

/* Sub-category picker overlay (modal-in-modal) */
html.ui-premium .mercuriale-edit-subcategory-picker-layer {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(2px);
  border-radius: inherit;
}

html.ui-premium .mercuriale-edit-subcategory-picker {
  width: min(480px, 100%);
  max-height: calc(100% - 16px);
  overflow-y: auto;
  background: #ffffff;
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.32);
  display: grid;
  gap: 12px;
}

html.ui-premium .mercuriale-edit-subcategory-picker-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

html.ui-premium .mercuriale-edit-subcategory-picker-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  color: var(--ds-text, #0f172a);
}

html.ui-premium .mercuriale-edit-subcategory-picker-subtitle {
  margin: 0;
  font-size: 0.82rem;
  line-height: 1.4;
  color: var(--ds-text-secondary, rgba(15, 23, 42, 0.65));
}

html.ui-premium .mercuriale-edit-subcategory-picker-close {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid rgba(15, 23, 42, 0.14);
  background: #ffffff;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  color: var(--ds-text, #0f172a);
}

html.ui-premium .mercuriale-edit-subcategory-picker-body {
  display: grid;
  gap: 14px;
}

html.ui-premium .mercuriale-edit-subcategory-picker-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 8px;
}

html.ui-premium .mercuriale-edit-subcategory-picker-chip {
  padding: 9px 12px;
  border-radius: 10px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: #ffffff;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
  transition:
    background 0.12s ease,
    border-color 0.12s ease;
}

html.ui-premium .mercuriale-edit-subcategory-picker-chip:hover {
  background: rgba(0, 149, 200, 0.06);
  border-color: rgba(0, 149, 200, 0.35);
}

html.ui-premium .mercuriale-edit-subcategory-picker-empty {
  margin: 0;
  grid-column: 1 / -1;
  padding: 12px;
  text-align: center;
  font-size: 0.82rem;
  font-style: italic;
  color: var(--ds-text-muted, rgba(15, 23, 42, 0.5));
}

html.ui-premium .mercuriale-edit-subcategory-picker-new {
  display: grid;
  gap: 8px;
  padding: 12px;
  border-radius: 12px;
  border: 1px dashed rgba(15, 23, 42, 0.18);
  background: rgba(248, 250, 252, 0.7);
}

html.ui-premium .mercuriale-edit-subcategory-picker-new-label {
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--ds-text-secondary, rgba(15, 23, 42, 0.65));
}

html.ui-premium .mercuriale-edit-subcategory-picker-new-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

html.ui-premium .mercuriale-edit-subcategory-picker-input {
  flex: 1 1 200px;
  min-height: 38px;
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid rgba(15, 23, 42, 0.14);
  background: #ffffff;
  font-size: 0.88rem;
  font-family: inherit;
  color: var(--ds-text, #0f172a);
  box-sizing: border-box;
}

html.ui-premium .mercuriale-edit-subcategory-picker-input:focus {
  outline: none;
  border-color: rgba(0, 149, 200, 0.55);
  box-shadow: 0 0 0 3px rgba(0, 149, 200, 0.15);
}

/* Échappatoire : "Assigner sans sous-catégorie" — séparé visuellement
   du bloc "créer une nouvelle sous-cat" pour bien signaler qu'on quitte
   le flux de création. */
html.ui-premium .mercuriale-edit-subcategory-picker-skip {
  display: flex;
  justify-content: center;
  padding-top: 4px;
  margin-top: 4px;
  border-top: 1px dashed rgba(15, 23, 42, 0.1);
}

html.ui-premium .mercuriale-edit-subcategory-picker-skip-btn {
  font-size: 0.82rem;
  color: var(--ds-text-secondary, rgba(15, 23, 42, 0.7));
}

html.ui-premium .mercuriale-edit-subcategory-picker-skip-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Sysco URL status */
html.ui-premium .mercuriale-edit-sysco-url-status {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.4;
}

html.ui-premium .mercuriale-edit-sysco-url-status[data-tone="neutral"] {
  color: var(--ds-text-muted, rgba(15, 23, 42, 0.55));
}

html.ui-premium .mercuriale-edit-sysco-url-status[data-tone="good"] {
  color: rgb(5, 150, 105);
}

html.ui-premium .mercuriale-edit-sysco-url-status[data-tone="warning"] {
  color: rgb(202, 138, 4);
}

/* =====================================================================
   MOBILE — Hamburger menu + dashboard responsive (< 768px)
   =====================================================================

   Stratégie :
   1. Bouton hamburger (.app-nav-toggle) caché par défaut sur desktop
      (le HTML met `hidden`, qu'on lève en mobile).
   2. Sur mobile : topbar 2 colonnes (logo+toggle à gauche / profil à
      droite), nav escamotée hors flux et révélée en panneau slide-down
      quand `body.drawer-open` est appliqué (via app.js).
   3. Dashboard : toutes les grilles multi-colonnes passent en 1 colonne.
   4. Tableaux / pseudo-tableaux : `overflow-x: auto` forcé sur les
      wrappers connus pour permettre le scroll horizontal.

   Cette section est placée APRÈS les @media existants (760px / 1220px)
   pour garantir la priorité de cascade. Ne pas déplacer.
   ===================================================================== */

/* Hamburger button — visible uniquement sous le breakpoint mobile. */
html.ui-premium .app-nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  margin-right: 4px;
  padding: 0;
  background: transparent;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 10px;
  cursor: pointer;
  flex-direction: column;
  gap: 5px;
  transition: background 120ms ease, border-color 120ms ease;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  -webkit-user-select: none;
  user-select: none;
  position: relative;
  z-index: 40;
}

html.ui-premium .app-nav-toggle:hover {
  background: rgba(15, 23, 42, 0.04);
  border-color: rgba(15, 23, 42, 0.12);
}

html.ui-premium .app-nav-toggle:active {
  background: rgba(15, 23, 42, 0.06);
}

html.ui-premium .app-nav-toggle:focus-visible {
  outline: 2px solid #38bdf8;
  outline-offset: 2px;
}

html.ui-premium .app-nav-toggle-bar {
  display: block;
  width: 20px;
  height: 2px;
  background: #0f172a;
  border-radius: 2px;
  transition: transform 200ms ease, opacity 200ms ease;
}

/* Animation hamburger → croix quand le menu est ouvert. */
body.drawer-open html.ui-premium .app-nav-toggle .app-nav-toggle-bar:nth-child(1),
html.ui-premium body.drawer-open .app-nav-toggle .app-nav-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
body.drawer-open html.ui-premium .app-nav-toggle .app-nav-toggle-bar:nth-child(2),
html.ui-premium body.drawer-open .app-nav-toggle .app-nav-toggle-bar:nth-child(2) {
  opacity: 0;
}
body.drawer-open html.ui-premium .app-nav-toggle .app-nav-toggle-bar:nth-child(3),
html.ui-premium body.drawer-open .app-nav-toggle .app-nav-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Backdrop : caché par défaut (le HTML met `hidden`, qu'on lève en
   mobile via .drawer-open). */
html.ui-premium .app-nav-backdrop {
  display: none;
}

/* --------------------------------------------------------------- */
/* Breakpoint principal mobile                                      */
/* --------------------------------------------------------------- */
@media (max-width: 768px) {
  /* Bouton hamburger : on l'affiche, on lève le `hidden` HTML. */
  html.ui-premium .app-nav-toggle {
    display: inline-flex;
  }
  html.ui-premium .app-nav-toggle[hidden] {
    display: inline-flex;
  }

  /* Topbar en deux colonnes : (logo + hamburger) | (profil).
     On override la règle empilée 1 colonne du media query 760px
     car ici on veut tout sur une seule ligne — la nav passe en
     panneau séparé. */
  html.ui-premium .app-topbar {
    grid-template-columns: auto 1fr auto;
    gap: 8px;
    padding: 8px 12px;
    width: calc(100% - 16px);
    margin: 8px auto 0;
    min-height: 56px;
    position: sticky;
    top: 8px;
    z-index: 1000;
    /* Supprime backdrop-filter sur mobile : il crée un nouveau containing
       block pour position:fixed, ce qui empêche le drawer de couvrir
       tout le viewport. Le flou n'est pas indispensable sur petit écran. */
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  /* ---- Drawer latéral depuis la gauche ---- */
  /* Toujours présent dans le DOM, caché par transform.
     On n'anime pas display (impossible) — on anime translateX. */
  html.ui-premium .topbar-nav-cluster {
    display: block !important;
    position: fixed;
    top: 0;
    left: 0;
    width: 280px;
    height: 100%;
    height: 100dvh; /* dynamic viewport height iOS */
    z-index: 9999;
    background: #ffffff;
    border-right: 1px solid rgba(15, 23, 42, 0.06);
    box-shadow: 6px 0 40px rgba(15, 23, 42, 0.18);
    /* Safe area iPhone (notch / Dynamic Island) */
    padding-top: max(20px, env(safe-area-inset-top, 20px));
    padding-bottom: max(20px, env(safe-area-inset-bottom, 20px));
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    /* Caché hors écran à gauche par défaut */
    transform: translateX(-100%);
    transition: transform 250ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
    will-change: transform;
  }

  /* Ouvert : panneau visible */
  html.ui-premium body.drawer-open .topbar-nav-cluster {
    transform: translateX(0);
  }

  /* Nav items empilés verticalement avec grande zone de tap */
  html.ui-premium .topbar-nav-cluster .topbar-nav {
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 2px;
    width: 100%;
    padding: 8px 12px;
  }

  /* ---- Backdrop ---- */
  /* Toujours dans le DOM sur mobile, caché via opacity + pointer-events.
     L'animation opacity est plus smooth qu'un display:none/block. */
  html.ui-premium .app-nav-backdrop,
  html.ui-premium .app-nav-backdrop[hidden] {
    display: block !important;
    position: fixed;
    inset: 0;
    z-index: 9998; /* sous le drawer (9999), au-dessus de tout le reste */
    background: rgba(15, 23, 42, 0.5);
    opacity: 0;
    pointer-events: none;
    transition: opacity 250ms ease;
  }

  html.ui-premium body.drawer-open .app-nav-backdrop,
  html.ui-premium body.drawer-open .app-nav-backdrop[hidden],
  html.ui-premium body.drawer-open .app-nav-backdrop,
  html.ui-premium body.drawer-open .app-nav-backdrop[hidden] {
    opacity: 1;
    pointer-events: auto;
  }

  /* Bloque le scroll body quand le drawer est ouvert.
     touch-action: none renforce le blocage sur iOS Safari. */
  body.drawer-open {
    overflow: hidden;
    touch-action: none;
  }

  /* ---- Liens de navigation dans le drawer ---- */

  /* Wraps : flex pleine largeur au lieu d'inline-flex (desktop) */
  html.ui-premium .topbar-nav-cluster .topbar-nav-item-wrap {
    display: flex;
    width: 100%;
    flex-direction: column;
  }

  /* Bouton principal : grande zone de tap, alignement gauche */
  html.ui-premium .topbar-nav-cluster .sidebar-nav-item.topbar-nav-item {
    display: flex;
    align-items: center;
    width: 100%;
    min-height: 52px;
    padding: 12px 16px;
    border-radius: 12px;
    text-align: left;
    white-space: normal;
    background: transparent;
    border: none;
    color: #1e293b;
    cursor: pointer;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    transition: background 120ms ease;
  }

  html.ui-premium .topbar-nav-cluster .sidebar-nav-item.topbar-nav-item:hover,
  html.ui-premium .topbar-nav-cluster .sidebar-nav-item.topbar-nav-item:active {
    background: rgba(15, 23, 42, 0.05);
  }

  html.ui-premium .topbar-nav-cluster .sidebar-nav-item.topbar-nav-item[data-active="true"] {
    background: rgba(37, 99, 235, 0.08);
    color: #1d4ed8;
  }

  /* Lead : gauche + gap généreux */
  html.ui-premium .topbar-nav-cluster .sidebar-nav-item-lead {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 14px;
    width: 100%;
    min-width: 0;
  }

  /* Icônes : réafficher dans le drawer (masquées sur desktop topbar) */
  html.ui-premium .topbar-nav-cluster .topbar-nav-item .sidebar-icon-module {
    display: inline-flex !important;
    width: 36px;
    height: 36px;
    min-width: 36px;
    border-radius: 10px;
    background: rgba(15, 23, 42, 0.06);
    color: #475569;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
  }

  html.ui-premium .topbar-nav-cluster .sidebar-nav-item.topbar-nav-item[data-active="true"] .sidebar-icon-module {
    background: rgba(37, 99, 235, 0.12);
    color: #2563eb;
  }

  /* Icône SVG : taille lisible sur mobile */
  html.ui-premium .topbar-nav-cluster .sidebar-icon-module svg {
    width: 18px;
    height: 18px;
  }

  /* Label : grand, lisible, aligné gauche */
  html.ui-premium .topbar-nav-cluster .sidebar-nav-item-label {
    font-size: 1rem !important;
    font-weight: 600;
    text-align: left !important;
    color: #1e293b;
    letter-spacing: -0.01em;
    flex: 1 1 auto;
    min-width: 0;
  }

  html.ui-premium .topbar-nav-cluster .sidebar-nav-item.topbar-nav-item[data-active="true"] .sidebar-nav-item-label {
    color: #1d4ed8;
    font-weight: 700;
  }

  /* Submenus : masqués dans le drawer (hover-based, inutilisable sur touch) */
  html.ui-premium .topbar-nav-cluster .topbar-nav-submenu {
    display: none !important;
  }

  /* Profil : on garde compact dans la topbar à droite. */
  html.ui-premium .app-topbar-right {
    gap: 6px;
  }

  /* Logo : taille bien visible sur mobile. height=42px sur un logo
     ratio ~2.93:1 donne ~123px de large, ce qui respecte le minimum
     de 120px demandé. max-width hard-cap à 180px pour les cas
     pathologiques. */
  html.ui-premium .app-topbar-logo {
    height: 56px;
    max-width: 200px;
  }

  /* --------------------------------------------------------------- */
  /* Dashboard : tout en une colonne, padding réduit                 */
  /* --------------------------------------------------------------- */
  html.ui-premium #dashboard-view .dashboard-hero-panel,
  html.ui-premium #dashboard-view .dashboard-hero-content,
  html.ui-premium #dashboard-view .dashboard-hero-mini-kpis,
  html.ui-premium #dashboard-view .dashboard-kpi-grid,
  html.ui-premium #dashboard-view .dashboard-supplier-monitoring,
  html.ui-premium #dashboard-view .supplier-alert-section-grid,
  html.ui-premium #dashboard-view .data-footer-panel {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  /* Toutes les cartes du dashboard : padding compact. */
  html.ui-premium #dashboard-view .panel,
  html.ui-premium #dashboard-view .dashboard-hero-panel,
  html.ui-premium #dashboard-view .dashboard-card {
    padding: 16px;
    border-radius: 14px;
  }

  /* Page shell : retire les gutters latéraux trop larges. */
  html.ui-premium .page-shell {
    --app-page-gutter: 12px;
  }

  /* --------------------------------------------------------------- */
  /* Tableaux / pseudo-tables : scroll horizontal garanti            */
  /* --------------------------------------------------------------- */
  /* Toutes les tables HTML : wrap dans un overflow-x scroll via le
     style direct sur table (s'applique aussi aux pseudo-tables CSS
     grid utilisées dans le dashboard). */
  html.ui-premium #dashboard-view table,
  html.ui-premium #dashboard-view .data-table,
  html.ui-premium #dashboard-view .supplier-alert-list,
  html.ui-premium #dashboard-view .supplier-alert-section-grid {
    display: block;
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  /* Le pseudo-tableau d'alertes : on force un min-width interne
     supérieur à la largeur de l'écran pour activer le scroll. */
  html.ui-premium #dashboard-view .supplier-alert-list-head,
  html.ui-premium #dashboard-view .supplier-alert-row {
    min-width: 760px;
  }

  /* Hero : empile titre/refresh proprement. */
  html.ui-premium #dashboard-view .dashboard-hero-actions {
    flex-wrap: wrap;
    gap: 8px;
  }
}

/* Très petits écrans (< 480px) : on resserre encore. */
@media (max-width: 480px) {
  html.ui-premium .app-topbar {
    padding: 6px 10px;
  }

  /* Logo conservé à ~120px de large minimum même sur très petit
     écran (priorité visibilité de la marque). */
  html.ui-premium .app-topbar-logo {
    height: 48px;
    max-width: 180px;
  }

  html.ui-premium #dashboard-view .panel,
  html.ui-premium #dashboard-view .dashboard-hero-panel,
  html.ui-premium #dashboard-view .dashboard-card {
    padding: 14px;
  }
}

@keyframes app-nav-slide-down {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes app-nav-backdrop-fade {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* =====================================================================
   Module COMMANDES (orders) — design sobre, dense, usage matinal
   =====================================================================
   Trois sections empilées :
     1. Header (titre + intro courte)
     2. Recherche produit + liste de résultats inline
     3. Commande en cours, groupée par fournisseur
        avec date de livraison + bouton "Imprimer le bon"
   Le rendu print est délégué à orders-module.js qui ouvre une nouvelle
   fenêtre auto-imprimable (styles inline dans le HTML généré).
   ===================================================================== */

html.ui-premium #orders-view {
  display: block;
  padding: 24px 28px;
  background: #ffffff;
  border-radius: var(--ds-radius-xl);
  box-shadow: var(--ds-shadow-panel);
  border: 1px solid rgba(15, 23, 42, 0.06);
}

html.ui-premium #orders-view[hidden] {
  display: none !important;
}

html.ui-premium .orders-wrapper {
  display: flex;
  flex-direction: column;
  gap: 36px;
  max-width: 1080px;
  margin: 0 auto;
}

html.ui-premium .orders-header {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-bottom: 20px;
  border-bottom: 2px solid rgba(15, 23, 42, 0.06);
}

html.ui-premium .orders-title {
  margin: 0;
  font-size: 1.9rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: #0f172a;
}

html.ui-premium .orders-subtitle {
  margin: 0;
  font-size: 1rem;
  color: #64748b;
}

html.ui-premium .orders-section {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

html.ui-premium .orders-section-title {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #94a3b8;
}

html.ui-premium .orders-empty-note {
  margin: 0;
  padding: 20px 24px;
  background: #f8fafc;
  border: 1.5px dashed rgba(15, 23, 42, 0.10);
  border-radius: 14px;
  font-size: 0.97rem;
  color: #64748b;
  line-height: 1.6;
}

/* ---- Notifications ---- */

html.ui-premium .orders-notif-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 10px;
  padding: 12px 16px;
  background: #f8fafc;
  border: 1px solid rgba(15, 23, 42, 0.07);
  border-radius: 12px;
}

html.ui-premium .orders-notif-status {
  flex: 1 1 auto;
  font-size: 0.84rem;
  color: #475569;
  font-weight: 500;
}

html.ui-premium .orders-notif-status[data-tone="good"] {
  color: #15803d;
}

html.ui-premium .orders-notif-status[data-tone="warn"] {
  color: #b45309;
}

html.ui-premium .orders-notif-status--off {
  color: #94a3b8;
  font-style: italic;
}

html.ui-premium .orders-notif-test-btn {
  flex: 0 0 auto;
  border: 1.5px solid #e2e8f0;
  background: #ffffff;
  color: #475569;
  border-radius: 9px;
  padding: 7px 14px;
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background 120ms ease, border-color 120ms ease, color 120ms ease;
}

html.ui-premium .orders-notif-test-btn:hover {
  background: #f1f5f9;
  border-color: #2563eb;
  color: #2563eb;
}

/* ---- Recherche ---- */

html.ui-premium .orders-search-row {
  display: flex;
  gap: 10px;
  align-items: stretch;
}

html.ui-premium .orders-search-input {
  flex: 1 1 auto;
  min-width: 0;
  appearance: none;
  border: 1.5px solid #e2e8f0;
  background: #ffffff;
  color: #0f172a;
  border-radius: 12px;
  padding: 14px 18px;
  font-size: 1rem;
  font-family: inherit;
  transition: border-color 120ms ease, box-shadow 120ms ease;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
}

html.ui-premium .orders-search-input:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14);
}

html.ui-premium .orders-search-clear {
  flex: 0 0 auto;
  border: 1.5px solid #e2e8f0;
  background: #ffffff;
  color: #475569;
  border-radius: 12px;
  padding: 0 20px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 120ms ease, border-color 120ms ease;
}

html.ui-premium .orders-search-clear:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

html.ui-premium .orders-search-results {
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 1.5px solid #e2e8f0;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.05);
}

html.ui-premium .orders-search-hint {
  margin: 0;
  padding: 18px 20px;
  font-size: 0.92rem;
  color: #94a3b8;
  background: #ffffff;
}

html.ui-premium .orders-result-row {
  display: grid;
  grid-template-columns: 1fr 100px 110px;
  gap: 14px;
  align-items: center;
  padding: 16px 20px;
  border-top: 1px solid #f1f5f9;
  background: #ffffff;
  transition: background 100ms ease;
}

html.ui-premium .orders-result-row:first-child {
  border-top: none;
}

html.ui-premium .orders-result-row:hover {
  background: #f8fafc;
}

html.ui-premium .orders-result-main {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

html.ui-premium .orders-result-name {
  font-size: 1rem;
  font-weight: 600;
  color: #0f172a;
  overflow-wrap: anywhere;
  line-height: 1.4;
}

html.ui-premium .orders-result-meta {
  font-size: 0.82rem;
  color: #64748b;
  overflow-wrap: anywhere;
}

html.ui-premium .orders-qty-input {
  width: 100%;
  appearance: none;
  border: 1.5px solid #e2e8f0;
  background: #ffffff;
  color: #0f172a;
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 0.97rem;
  font-family: inherit;
  font-variant-numeric: tabular-nums;
  text-align: right;
  transition: border-color 120ms ease, box-shadow 120ms ease;
}

html.ui-premium .orders-qty-input:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14);
}

html.ui-premium .orders-add-btn {
  border: none;
  border-radius: 10px;
  padding: 10px 18px;
  background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 100%);
  color: #fff;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  letter-spacing: -0.01em;
  transition: transform 100ms ease, box-shadow 120ms ease;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
  white-space: nowrap;
}

html.ui-premium .orders-add-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(37, 99, 235, 0.45);
}

html.ui-premium .orders-add-btn:active {
  transform: translateY(0);
}

/* ---- Liste en cours ---- */

html.ui-premium .orders-list-titlerow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

html.ui-premium .orders-clear-btn {
  border: 1.5px solid rgba(220, 38, 38, 0.3);
  background: rgba(220, 38, 38, 0.04);
  color: #dc2626;
  border-radius: 8px;
  padding: 7px 14px;
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 120ms ease;
}

html.ui-premium .orders-clear-btn:hover {
  background: rgba(220, 38, 38, 0.09);
}

html.ui-premium .orders-supplier-group {
  border: 1.5px solid rgba(15, 23, 42, 0.08);
  border-radius: 16px;
  overflow: hidden;
  background: #ffffff;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.05);
}

html.ui-premium .orders-supplier-group + .orders-supplier-group {
  margin-top: 20px;
}

html.ui-premium .orders-orphans-group {
  border-color: rgba(202, 138, 4, 0.35);
  background: rgba(254, 252, 232, 0.5);
}

/* ---- Header Sysco (bleu) ---- */
html.ui-premium .orders-supplier-group[data-supplier-id="SYSCO"] .orders-group-head {
  background: linear-gradient(135deg, #1e40af 0%, #2563eb 100%);
  border-bottom: none;
}
html.ui-premium .orders-supplier-group[data-supplier-id="SYSCO"] .orders-group-title {
  color: #ffffff;
}
html.ui-premium .orders-supplier-group[data-supplier-id="SYSCO"] .orders-group-meta {
  color: rgba(255, 255, 255, 0.75);
}
html.ui-premium .orders-supplier-group[data-supplier-id="SYSCO"] .orders-print-btn {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.35);
  color: #ffffff;
}
html.ui-premium .orders-supplier-group[data-supplier-id="SYSCO"] .orders-print-btn:hover {
  background: rgba(255, 255, 255, 0.25);
  border-color: rgba(255, 255, 255, 0.6);
}

/* ---- Header Relais d'Or (vert) ---- */
html.ui-premium .orders-supplier-group[data-supplier-id="RELAIS D'OR"] .orders-group-head {
  background: linear-gradient(135deg, #15803d 0%, #16a34a 100%);
  border-bottom: none;
}
html.ui-premium .orders-supplier-group[data-supplier-id="RELAIS D'OR"] .orders-group-title {
  color: #ffffff;
}
html.ui-premium .orders-supplier-group[data-supplier-id="RELAIS D'OR"] .orders-group-meta {
  color: rgba(255, 255, 255, 0.75);
}
html.ui-premium .orders-supplier-group[data-supplier-id="RELAIS D'OR"] .orders-print-btn {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.35);
  color: #ffffff;
}
html.ui-premium .orders-supplier-group[data-supplier-id="RELAIS D'OR"] .orders-print-btn:hover {
  background: rgba(255, 255, 255, 0.25);
  border-color: rgba(255, 255, 255, 0.6);
}

html.ui-premium .orders-group-head {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  gap: 4px 20px;
  padding: 18px 22px;
  background: #f8fafc;
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
}

html.ui-premium .orders-group-title {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.02em;
  grid-column: 1;
  grid-row: 1;
}

html.ui-premium .orders-group-meta {
  font-size: 0.86rem;
  color: #475569;
  grid-column: 1;
  grid-row: 2;
}

html.ui-premium .orders-group-actions {
  grid-column: 2;
  grid-row: 1 / span 2;
  display: flex;
  align-items: center;
}

html.ui-premium .orders-print-btn {
  border: 1.5px solid rgba(15, 23, 42, 0.15);
  background: #ffffff;
  color: #0f172a;
  border-radius: 9px;
  padding: 9px 16px;
  font-size: 0.87rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 120ms ease, border-color 120ms ease, transform 100ms ease;
  white-space: nowrap;
}

html.ui-premium .orders-print-btn:hover {
  background: #f1f5f9;
  border-color: rgba(15, 23, 42, 0.25);
  transform: translateY(-1px);
}

html.ui-premium .orders-table {
  display: flex;
  flex-direction: column;
}

html.ui-premium .orders-table-head,
html.ui-premium .orders-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 120px 140px 44px;
  gap: 14px;
  align-items: center;
  padding: 14px 22px;
}

html.ui-premium .orders-table-head {
  border-bottom: 1px solid rgba(15, 23, 42, 0.07);
  background: #fafafa;
}

html.ui-premium .orders-th {
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #94a3b8;
}

html.ui-premium .orders-row {
  border-top: 1px solid #f1f5f9;
  transition: background 100ms ease;
}

html.ui-premium .orders-row:first-of-type {
  border-top: none;
}

html.ui-premium .orders-row:hover {
  background: #f8fafc;
}

html.ui-premium .orders-td {
  font-size: 0.96rem;
  color: #0f172a;
  min-width: 0;
  overflow-wrap: anywhere;
}

html.ui-premium .orders-td-name {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 5px;
}

html.ui-premium .orders-row-name {
  font-size: 0.97rem;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.3;
}

html.ui-premium .orders-td-ref {
  font-family: "SFMono-Regular", Menlo, Consolas, monospace;
  font-size: 0.84rem;
  color: #64748b;
}

html.ui-premium .orders-td-qty {
  display: flex;
  align-items: center;
  gap: 8px;
}

html.ui-premium .orders-qty-input-inline {
  width: 76px;
  appearance: none;
  border: 1.5px solid #e2e8f0;
  background: #ffffff;
  color: #0f172a;
  border-radius: 8px;
  padding: 8px 10px;
  font-size: 0.94rem;
  font-family: inherit;
  font-variant-numeric: tabular-nums;
  text-align: right;
  transition: border-color 120ms ease, box-shadow 120ms ease;
}

html.ui-premium .orders-qty-input-inline:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14);
}

html.ui-premium .orders-qty-unit {
  font-size: 0.82rem;
  color: #64748b;
}

html.ui-premium .orders-remove-btn {
  border: none;
  background: transparent;
  color: #cbd5e1;
  cursor: pointer;
  font-size: 1.1rem;
  line-height: 1;
  padding: 8px;
  border-radius: 8px;
  transition: background 120ms ease, color 120ms ease;
}

html.ui-premium .orders-remove-btn:hover {
  background: rgba(220, 38, 38, 0.08);
  color: #dc2626;
}

html.ui-premium .orders-stale-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  font-size: 0.74rem;
  font-weight: 700;
  background: rgba(245, 158, 11, 0.1);
  color: #b45309;
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: 6px;
  cursor: help;
}

html.ui-premium .orders-row-nameline {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

html.ui-premium .orders-needed-row {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 2px;
}

html.ui-premium .orders-needed-label {
  font-size: 0.74rem;
  color: #94a3b8;
  white-space: nowrap;
  font-weight: 500;
}

html.ui-premium .orders-needed-input {
  font-size: 0.82rem;
  padding: 4px 8px;
  border: 1.5px solid #e2e8f0;
  border-radius: 7px;
  background: #f8fafc;
  color: #334155;
  cursor: pointer;
  outline: none;
  font-weight: 500;
  transition: border-color 120ms ease, background 120ms ease;
}

html.ui-premium .orders-needed-input:focus {
  border-color: #2563eb;
  background: #fff;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.12);
}

html.ui-premium .orders-auto-supplier {
  display: none;
}

html.ui-premium .orders-conditionnement {
  font-size: 0.8rem;
  color: #64748b;
  font-weight: 500;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

html.ui-premium .orders-delivery-alert {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 7px;
  background: #fef2f2;
  border: 1px solid #fca5a5;
  color: #dc2626;
  font-size: 0.76rem;
  font-weight: 700;
}

html.ui-premium .orders-delivery-urgent {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 7px;
  background: #fffbeb;
  border: 1px solid #fcd34d;
  color: #b45309;
  font-size: 0.76rem;
  font-weight: 700;
}

/* ---- Panneau d'impression in-app ---- */

html.ui-premium .orders-print-overlay {
  position: fixed;
  inset: 0;
  z-index: 9000;
  background: #0f172a;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

html.ui-premium .orders-print-toolbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 20px;
  background: #1e293b;
  border-bottom: 1px solid #334155;
}

html.ui-premium .orders-print-toolbar-title {
  color: #f1f5f9;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

html.ui-premium .orders-print-toolbar-actions {
  display: flex;
  gap: 8px;
}

html.ui-premium .orders-print-btn-primary {
  padding: 7px 18px;
  background: #f8fafc;
  color: #0f172a;
  border: none;
  border-radius: 7px;
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
  letter-spacing: -0.01em;
  transition: background 0.12s;
}

html.ui-premium .orders-print-btn-primary:hover {
  background: #ffffff;
}

html.ui-premium .orders-print-btn-secondary {
  padding: 7px 14px;
  background: transparent;
  color: #94a3b8;
  border: 1px solid #334155;
  border-radius: 7px;
  font-size: 0.84rem;
  cursor: pointer;
  transition: color 0.12s, border-color 0.12s;
}

html.ui-premium .orders-print-btn-secondary:hover {
  color: #f1f5f9;
  border-color: #475569;
}

/* Contenu blanc du bon */
html.ui-premium .orders-print-content {
  background: #ffffff;
  width: calc(100% - 32px);
  max-width: 760px;
  margin: 28px auto 48px;
  border-radius: 10px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.40);
  padding: 44px 52px;
  color: #0f172a;
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 11pt;
  line-height: 1.55;
  box-sizing: border-box;
}

/* En-tête du bon */
html.ui-premium .op-header {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  padding-bottom: 20px;
  border-bottom: 2px solid #0f172a;
  margin-bottom: 24px;
}

html.ui-premium .op-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

html.ui-premium .op-logo {
  height: 72px;
  width: auto;
  max-width: 260px;
  object-fit: contain;
  flex-shrink: 0;
}

html.ui-premium .op-brand-text {
  display: flex;
  flex-direction: column;
}

html.ui-premium .op-brand-name {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #0f172a;
  line-height: 1.2;
}

html.ui-premium .op-brand-sub {
  font-size: 0.68rem;
  color: #64748b;
  font-weight: 500;
  margin-top: 2px;
}

html.ui-premium .op-title-group {
  flex: 1;
}

html.ui-premium .op-h1 {
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin: 0;
  color: #0f172a;
  line-height: 1.2;
}

html.ui-premium .op-dates {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex-shrink: 0;
  text-align: right;
}

html.ui-premium .op-date-row {
  display: flex;
  flex-direction: column;
}

html.ui-premium .op-date-label {
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #94a3b8;
  line-height: 1;
}

html.ui-premium .op-date-value {
  font-size: 0.8rem;
  font-weight: 600;
  color: #0f172a;
  line-height: 1.3;
}

/* Bandeau récap */
html.ui-premium .op-summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 28px;
  padding: 14px 16px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
}

html.ui-premium .op-summary-card {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

html.ui-premium .op-summary-label {
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: #64748b;
}

html.ui-premium .op-summary-value {
  font-size: 0.92rem;
  font-weight: 700;
  color: #0f172a;
}

/* Tableau du bon */
html.ui-premium .op-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.84rem;
  margin-bottom: 12px;
}

html.ui-premium .op-table thead th {
  padding: 9px 8px;
  border-bottom: 2px solid #0f172a;
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: #475569;
  text-align: left;
}

html.ui-premium .op-table thead th.op-th-right {
  text-align: right;
}

html.ui-premium .op-table tbody td {
  padding: 9px 8px;
  border-bottom: 1px solid #e2e8f0;
  vertical-align: top;
}

html.ui-premium .op-table tfoot td {
  padding: 12px 8px;
  border-top: 2px solid #0f172a;
}

html.ui-premium .op-ref {
  font-family: "Courier New", monospace;
  font-size: 0.78rem;
  white-space: nowrap;
  color: #1e293b;
  width: 100px;
}

html.ui-premium .op-name {
  font-weight: 500;
}

html.ui-premium .op-qty,
html.ui-premium .op-price,
html.ui-premium .op-line-total {
  text-align: right;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

html.ui-premium .op-qty  { width: 90px; }
html.ui-premium .op-price { width: 80px; color: #475569; }
html.ui-premium .op-line-total { width: 90px; font-weight: 600; }

html.ui-premium .op-stale {
  color: #b45309;
  font-size: 0.7rem;
  font-weight: 600;
}

html.ui-premium .op-needed {
  color: #64748b;
  font-size: 0.7rem;
  font-style: italic;
}

html.ui-premium .op-grand-label {
  text-align: right;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #475569;
}

html.ui-premium .op-grand-total {
  text-align: right;
  font-size: 1rem;
  font-weight: 700;
  color: #0f172a;
}

html.ui-premium .op-price-note {
  font-size: 0.7rem;
  color: #94a3b8;
  margin: 2px 0 16px;
}

html.ui-premium .op-footer {
  margin-top: 32px;
  padding-top: 14px;
  border-top: 1px solid #e2e8f0;
  font-size: 0.68rem;
  color: #94a3b8;
  text-align: center;
}

/* ---- Toast notification ---- */

html.ui-premium .orders-toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  z-index: 9999;
  background: #1e293b;
  color: #f1f5f9;
  padding: 10px 22px;
  border-radius: 9px;
  font-size: 0.84rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.28);
  opacity: 0;
  transition: opacity 0.22s ease, transform 0.22s ease;
  pointer-events: none;
  white-space: nowrap;
  max-width: calc(100vw - 32px);
  overflow: hidden;
  text-overflow: ellipsis;
}

html.ui-premium .orders-toast.orders-toast-show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ---- Responsive mobile ---- */

@media (max-width: 768px) {
  html.ui-premium #orders-view {
    padding: 12px;
  }

  /* Wrapper plus compact */
  html.ui-premium .orders-wrapper {
    gap: 24px;
  }

  /* Header notifications compact */
  html.ui-premium .orders-notif-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
  html.ui-premium .orders-notif-test-btn {
    width: 100%;
    text-align: center;
    padding: 11px 14px;
    font-size: 0.9rem;
  }

  /* ---- Recherche : barre pleine largeur ---- */
  html.ui-premium .orders-search-input {
    font-size: 1rem;
    padding: 14px 16px;
  }

  /* Résultats : nom pleine largeur sur ligne 1,
     quantité + Ajouter sur ligne 2 */
  html.ui-premium .orders-result-row {
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto;
    gap: 10px 12px;
    padding: 16px;
  }

  html.ui-premium .orders-result-name {
    grid-column: 1 / span 2;
    grid-row: 1;
    font-size: 1.05rem;
  }

  html.ui-premium .orders-qty-input {
    grid-column: 1;
    grid-row: 2;
    width: 100%;
    font-size: 1rem;
    padding: 12px;
    text-align: left;
  }

  html.ui-premium .orders-add-btn {
    grid-column: 2;
    grid-row: 2;
    padding: 12px 18px;
    font-size: 0.95rem;
    white-space: nowrap;
  }

  /* ---- En-têtes fournisseur pleine largeur ---- */
  html.ui-premium .orders-supplier-group {
    border-radius: 14px;
  }

  html.ui-premium .orders-group-head {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto auto;
    gap: 6px;
    padding: 16px;
  }

  html.ui-premium .orders-group-title {
    font-size: 1.1rem;
    grid-row: 1;
  }

  html.ui-premium .orders-group-meta {
    grid-row: 2;
    font-size: 0.88rem;
  }

  html.ui-premium .orders-group-actions {
    grid-column: 1;
    grid-row: 3;
    width: 100%;
  }

  /* Bouton Imprimer pleine largeur */
  html.ui-premium .orders-print-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 16px;
    font-size: 0.92rem;
    border-radius: 10px;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
  }

  /* ---- Cards produit ---- */
  html.ui-premium .orders-table-head {
    display: none;
  }

  html.ui-premium .orders-row {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 16px;
    position: relative;
  }

  /* Bouton supprimer en haut à droite */
  html.ui-premium .orders-td-actions {
    position: absolute;
    top: 12px;
    right: 12px;
  }

  html.ui-premium .orders-remove-btn {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
  }

  /* Nom du produit en grand */
  html.ui-premium .orders-td-name {
    padding-right: 44px; /* espace pour le bouton supprimer */
  }

  html.ui-premium .orders-row-name {
    font-size: 1rem;
  }

  /* Référence en gris */
  html.ui-premium .orders-td-ref {
    font-size: 0.82rem;
    color: #64748b;
  }
  html.ui-premium .orders-td-ref::before {
    content: "Réf : ";
    color: #94a3b8;
  }

  /* Quantité + unité sur une ligne */
  html.ui-premium .orders-td-qty {
    display: flex;
    align-items: center;
    gap: 10px;
  }

  html.ui-premium .orders-qty-input-inline {
    width: 90px;
    font-size: 1rem;
    padding: 10px 12px;
    touch-action: manipulation;
  }

  html.ui-premium .orders-conditionnement {
    font-size: 0.86rem;
  }

  /* Sélecteur "Besoin pour le" : grande zone de tap */
  html.ui-premium .orders-needed-row {
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 4px;
  }

  html.ui-premium .orders-needed-label {
    font-size: 0.8rem;
  }

  html.ui-premium .orders-needed-input {
    font-size: 0.9rem;
    padding: 8px 12px;
    min-height: 40px;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    border-radius: 8px;
  }

  /* ---- Modale bon de commande ---- */
  html.ui-premium .orders-print-overlay {
    padding: 0;
  }

  html.ui-premium .orders-print-toolbar {
    padding: 12px 16px;
    flex-wrap: wrap;
    gap: 8px;
  }

  html.ui-premium .orders-print-toolbar-actions {
    width: 100%;
    justify-content: stretch;
  }

  html.ui-premium .orders-print-btn-primary,
  html.ui-premium .orders-print-btn-secondary {
    flex: 1;
    text-align: center;
    padding: 11px 12px;
    font-size: 0.9rem;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
  }

  html.ui-premium .orders-print-content {
    width: 100%;
    max-width: 100%;
    margin: 0;
    border-radius: 0;
    padding: 24px 16px;
    box-shadow: none;
    min-height: calc(100vh - 60px);
  }
}

/* =====================================================================
   MOBILE — Garde-fous overflow horizontal + grilles forcées en 1 col
   =====================================================================
   But : empêcher tout débordement horizontal sur mobile (375px et
   moins) sur les vues Dashboard / Restaurant (overview/menu/detail/
   purchases/suppliers) / Mercuriale. Stratégie en 3 couches :

   1. Filet de sécurité : `overflow-x: hidden` sur html + body + les
      conteneurs principaux. `body` l'avait déjà via styles.css:6644,
      mais on l'étend à html et aux niveaux intermédiaires pour blinder.

   2. `min-width: 0` partout sur les enfants de grids/flex (Firefox a un
      bug historique : `min-width: auto` empêche les enfants de rétrécir
      en dessous de leur contenu intrinsèque).

   3. Override des grilles 3-4 colonnes restantes qui n'avaient pas de
      breakpoint <860px et restaient compressées à 375px.

   ===================================================================== */
@media (max-width: 768px) {
  /* ----- Couche 1 : filet de sécurité overflow ----- */
  html,
  body {
    overflow-x: hidden;
    max-width: 100vw;
  }

  html.ui-premium .page-shell,
  html.ui-premium .app-layout,
  html.ui-premium .views-stack,
  html.ui-premium main,
  html.ui-premium .view-panel,
  html.ui-premium section.panel {
    max-width: 100%;
    min-width: 0;
  }

  /* ----- Couche 2 : autorise les enfants de grid/flex à rétrécir
     en dessous de leur contenu intrinsèque (empêche les "min-content"
     overflow). Cible large mais sûre. ----- */
  html.ui-premium .view-panel > *,
  html.ui-premium section.panel > *,
  html.ui-premium .dashboard-hero-panel > *,
  html.ui-premium .dashboard-card > * {
    min-width: 0;
  }

  /* ----- Couche 3 : grilles 3-4 cols qui n'avaient aucun override
     <860px et restaient tassées à 375px. On les passe en 1 col. ----- */
  html.ui-premium .summary-grid,
  html.ui-premium .alert-cards,
  html.ui-premium .menu-grid,
  html.ui-premium .dashboard-supplier-glance,
  html.ui-premium .detail-editor-grid,
  html.ui-premium .supplier-base-grid,
  html.ui-premium #detail-view .detail-metrics,
  html.ui-premium .detail-inline-ingredient-top,
  html.ui-premium .detail-inline-ingredient-bottom,
  html.ui-premium .strip-meta-grid,
  html.ui-premium .health-card-grid,
  html.ui-premium .ingredient-fact-grid {
    grid-template-columns: 1fr !important;
  }

  /* ----- Boutons larges qui pouvaient pousser le viewport ----- */
  html.ui-premium .restaurant-ai-refresh-button,
  html.ui-premium .menu-top-actions .editor-save-button,
  html.ui-premium #detail-view .detail-edit-trigger {
    min-width: 0;
    width: 100%;
  }

  /* ----- Wrap des textes longs (EAN, SKU, URLs, noms produits) ----- */
  html.ui-premium .mercuriale-edit-supplier-card-ref,
  html.ui-premium .mercuriale-cell-product,
  html.ui-premium .mercuriale-row .mercuriale-cell,
  html.ui-premium .supplier-alert-row,
  html.ui-premium .dashboard-card,
  html.ui-premium .health-card,
  html.ui-premium .ingredient-fact {
    overflow-wrap: anywhere;
    word-break: break-word;
  }

  /* ----- Wrappers de pseudo-tableaux : si on a un grid avec
     min-width forcé, on le wrappe automatiquement en scroll-x via
     un parent. Ces wrappers existent déjà pour la mercuriale et
     les alertes ; on ajoute un fallback générique. ----- */
  html.ui-premium .mercuriale-table-wrapper,
  html.ui-premium .product-simple-groups,
  html.ui-premium #product-simple-groups {
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  /* ----- Modales mercuriale : ne dépassent jamais le viewport ----- */
  html.ui-premium .mercuriale-modal-layer,
  html.ui-premium .mercuriale-modal,
  html.ui-premium #mercuriale-add-host,
  html.ui-premium #mercuriale-edit-host,
  html.ui-premium #mercuriale-sysco-url-host {
    max-width: 100vw;
  }

  /* ----- Restaurant view header : padding réduit + retour ligne
     propre sur les actions. ----- */
  html.ui-premium .restaurant-view-header {
    padding-left: 12px;
    padding-right: 12px;
  }

  html.ui-premium .restaurant-margins-sticky-chrome,
  html.ui-premium .app-back-toolbar {
    max-width: 100%;
    min-width: 0;
  }

  /* ----- Tabs / sub-nav : permettent le scroll horizontal interne
     si elles débordent (au lieu de pousser la page). ----- */
  html.ui-premium .restaurant-tabs,
  html.ui-premium .view-switcher,
  html.ui-premium .tabset {
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
  }

  /* ----- Inputs / selects : ne dépassent jamais leur parent ----- */
  html.ui-premium input,
  html.ui-premium select,
  html.ui-premium textarea {
    max-width: 100%;
    box-sizing: border-box;
  }
}

/* ================================================================
   IMPRESSION — bon de commande
   ================================================================ */
@media print {
  /* La toolbar de l'overlay est masquée à l'impression.
     Tout le reste (masquage des éléments de l'app, position: static de
     l'overlay) est géré en JavaScript dans orders-module.js pour garantir
     la compatibilité avec iOS Safari qui ignore parfois les overrides CSS
     de position: fixed → position: static dans les @media print. */
  .orders-print-toolbar {
    display: none !important;
  }

  /* Contenu du bon : mise en page propre pour l'impression. */
  .orders-print-content {
    box-shadow: none !important;
    border-radius: 0 !important;
    margin: 0 !important;
    padding: 16px !important;
    min-height: auto !important;
    max-height: none !important;
    overflow: visible !important;
  }

  /* Évite les coupures de page au milieu du tableau. */
  .op-table {
    page-break-inside: auto;
  }

  .op-table tbody tr {
    page-break-inside: avoid;
    break-inside: avoid;
  }

  .op-summary {
    break-inside: avoid;
  }
}
