/****************************************************
 * Fichier : dashboard.css
 * Version "Professionnel & Fun - Inspiration Canva"
 ****************************************************/

/*----------------------------------------------------
  BLOC 1) VARIABLES : Charte "Fun Canva"
-----------------------------------------------------*/
:root {
  /* Couleurs principales (branding) */
  --wpt-brand-color: #615EFF;             /* Accent principal (bleu-violet) */
  --wpt-brand-color-secondary: #FF746B;   /* Second accent (rose fun) */
  
  /* Couleur de fond global */
  --wpt-bg-color: #F8F9FD;
  /* Couleur de texte par défaut */
  --wpt-text-color: #333;

  /* Couleurs pastel (pour fonds, hovers, highlights) */
  --wpt-pastel-1: #FFD7D2;  /* Rose pastel */
  --wpt-pastel-2: #e8e6ff;  /* Lavande pastel */
  --wpt-pastel-3: #f97471;  /* Corail pastel */
  --wpt-pastel-4: #FFF3D2;  /* Jaune pastel */
  
  /* Autres variables */
  --wpt-border-color:  #DDE1E7;
  --wpt-shadow-color: rgba(0, 0, 0, 0.1);

  /* Hauteurs fixes pour le header + subheader */
  --wpt-header-height: 60px;
  --wpt-subheader-height: 48px;

  /* Largeur fixe des sidebars */
  --wpt-sidebar-width: 320px;
}

/*----------------------------------------------------
  BLOC 2) RESET DE BASE
-----------------------------------------------------*/
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center, dl, dt, dd, ol, ul, li,
fieldset, form, label, legend, caption,
tbody, tfoot, thead, tr, th, td,
article, aside, figure, figcaption, footer, header,
hgroup, menu, nav, output, ruby, section,
summary, time, mark, audio, video {
  margin: 0;
  padding: 0;
  border: 0;
  vertical-align: baseline;
  font: inherit;
}
html {
  box-sizing: border-box;
}
*, *::before, *::after {
  box-sizing: inherit;
}

/*----------------------------------------------------
  BLOC 3) BODY & BASICS
-----------------------------------------------------*/
body {
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 16px;
  color: var(--wpt-text-color);
  background-color: var(--wpt-bg-color);
  line-height: 1.45;
  min-height: 100vh;
  overflow-x: hidden;
}
img {
  max-width: 100%;
  height: auto;
  display: block;
}
a {
  text-decoration: none;
  color: var(--wpt-text-color);
}
button {
  cursor: pointer;
  border: none;
  background: none;
}
.screen-reader-text {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  border: 0;
}

/*----------------------------------------------------
  BLOC 4) WRAPPER GLOBAL
-----------------------------------------------------*/
.wpt-dashboard-wrapper {
  display: block;
  width: 100%;
  position: relative;
}

/*----------------------------------------------------
  BLOC 5) HEADER FIXE - Style Fun
-----------------------------------------------------*/
.wpt-dashboard-header {
  position: fixed;
  top: 0; 
  left: 0; 
  right: 0;
  height: var(--wpt-header-height);
  /* Dégradé pastel fun */
  background: linear-gradient(
    144deg,
    #4535b9 0%,   /* Couleur 1 */
    #df4ecd 60%,  /* Couleur intermédiaire */
    #3dffd2 100%  /* Couleur 2 */
  );
  border-bottom: 0.5px solid rgba(0, 0, 0, 0.05);
  z-index: 999;
  display: flex;
  align-items: center;
}

.wpt-dashboard-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1400px;
  width: 100%;
  margin: 0 auto;
  padding: 0 16px;
}

.wpt-dashboard-header__left {
  display: flex;
  align-items: center;
}
.wpt-dashboard-header__brand-link {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}
.wpt-dashboard-header__logo {
  height: 50px;
  width: auto;
  object-fit: contain;
}

/* Barre centrale */
.wpt-dashboard-header__center {
  display: flex;
  align-items: center;
  gap: 30px;
}

/* Recherche : input arrondi + halo focus */
.wpt-dashboard-header__search-container {
  position: relative;
  display: flex;
  align-items: center;
}
.wpt-dashboard-header__search-input {
  width: 220px;
  padding: 8px 32px 8px 14px;
  border: 1px solid  #DDE1E7;
  border-radius: 9999px; /* Arrondi complet */
  font-size: 0.9rem;
  transition: border-color 0.3s, box-shadow 0.3s;
}
.wpt-dashboard-header__search-input:focus {
  border-color: var(--wpt-brand-color);
  outline: none;
  box-shadow: 0 0 0 3px rgba(97,94,255,0.15); 
}
.wpt-dashboard-header__search-button {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  color: #666;
  font-size: 1rem;
  cursor: pointer;
}

/* ----------------------------------------------------
   Dimensions + style pour les icônes SVG
----------------------------------------------------- */
.wpt-header-icon-link svg,
.js-load-page,
.wpt-dashboard-header__icon-btn svg {
  width: 24px;
  height: 24px;
  stroke: #fff;
  stroke-width: 0px;
  fill: #fff;
  transition: stroke 0.2s, fill 0.2s, transform 0.2s;
}

/* Icônes type FB (accueil, watch, etc.) : petit effet "pop" au survol */
.wpt-dashboard-header__center-icons,
.js-load-page {
  display: flex;
  align-items: center;
  gap: 24px;
}
.wpt-header-icon-link,
.js-load-page {
  color: #ffffffa6; 
  font-size: 1.2rem;
  padding: 6px;
  border-radius: 50%;
  transition: background-color 0.2s, transform 0.2s;
}
.wpt-header-icon-link:hover,
.js-load-page:hover {
  background-color: rgba(0,0,0,0.05);
  transform: scale(1.1);
}
.wpt-header-icon-link:hover svg,
.js-load-page:hover svg {
  stroke: #fff;
  fill: #442ac69b; 
}

/* Variante icône plus grande */
.wpt-header-icon-link-cible svg {
  width: 30px;
  height: 30px;
  stroke: #fff;
  stroke-width: 0px;
  fill: #fff;
  transition: stroke 0.2s, fill 0.2s, transform 0.2s;
}
.wpt-header-icon-link-cible {
  color: #ffffffa6; 
  font-size: 1.2rem;
  padding: 6px;
  border-radius: 50%;
  transition: background-color 0.2s, transform 0.2s;
}
.wpt-header-icon-link-cible:hover {
  background-color: rgba(0,0,0,0.05);
  transform: scale(1.1);
}
.wpt-header-icon-link-cible:hover svg {
  stroke: #fff;
  fill: #442ac69b; 
}

/* Right (notifications, profil, menu) */
.wpt-dashboard-header__right {
  display: flex;
  align-items: center;
  gap: 10px;
}
.wpt-dashboard-header__icon-btn {
  background: none;
  color: #ffffffa6;
  font-size: 1.2rem;
  padding: 6px;
  border-radius: 50%;
  transition: background-color 0.2s, transform 0.2s;
}
.wpt-dashboard-header__icon-btn:hover {
  background-color: rgba(0,0,0,0.05);
  transform: scale(1.1);
  
}
.wpt-dashboard-header__icon-btn:hover svg {
  stroke: #fff;
  fill: #442ac69b;
}

.icon_user2a {
  width: 22px;
  height: 22px;
  color: #273dff;
}

/* ----------------------------------------------------
   Tooltip moderne en pur CSS (utilise data-tooltip)
----------------------------------------------------- */
.wpt-tooltip {
  position: relative; /* Pour positionner le tooltip en absolu */
}
.wpt-tooltip[data-tooltip]:hover::after {
  content: attr(data-tooltip);
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.8);
  color: #fff;
  padding: 6px 10px;
  border-radius: 5px;
  font-size: 0.75rem;
  white-space: nowrap;
  z-index: 9999;
  pointer-events: none;
  opacity: 0;
  animation: fadeInOpacity 0.2s forwards;
}
.wpt-tooltip[data-tooltip]:hover::before {
  content: "";
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-bottom-color: rgba(0, 0, 0, 0.8);
  z-index: 9998;
  opacity: 0;
  animation: fadeInOpacity 0.2s forwards;
}
@keyframes fadeInOpacity {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/*----------------------------------------------------
  BLOC 6) SUBHEADER FIXE + Scroll horizontal masqué
-----------------------------------------------------*/
.wpt-dashboard-subheader {
  position: fixed;
  top: var(--wpt-header-height);
  left: 0; 
  right: 0;
  z-index: 998;
  height: var(--wpt-subheader-height);
  display: flex;
  align-items: center;
  border-radius: 0 0 12px 12px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  background-color: #eaf0f9; /* Couleur par défaut */
}
.wpt-dashboard-subheader__inner {
  max-width: 1400px;
  width: 100%;
  margin: 0 auto;
  padding: 0 16px;
  display: flex;
  align-items: center;
  justify-content: space-between; 
  height: 100%;

  /* Scroll horizontal si contenu trop large, scrollbar masquée */
  overflow-x: auto;
  white-space: nowrap;
  scrollbar-width: none;       /* Firefox */
  -ms-overflow-style: none;    /* IE & Edge */
}
.wpt-dashboard-subheader__inner::-webkit-scrollbar {
  display: none; /* Chrome, Safari, Opera */
}

/* Couleurs dynamiques selon le rôle */
.wpt-dashboard-subheader--role-wpt_vendor {
  background: linear-gradient(135deg, #fee1ff 0%, #dde9ff 100%);
}
.wpt-dashboard-subheader--role-wpt_couple {
  background: linear-gradient(135deg, #FFE7D2 0%, #f4f8ff 100%);
}
.wpt-dashboard-subheader--role-anonymous {
  background: linear-gradient(135deg, #f9f8ff 0%, #ded9ff 100%);
}

/* role-switcher */
.wpt-dashboard-subheader__role-switcher {
  display: flex;
  align-items: center;
  gap: 10px;
}
.subheader-role-icon {
  width: 24px; 
  height: 24px;
  object-fit: contain;
}
.subheader-role-label {
  font-weight: 600;
  font-size: 0.9rem;
}
.subheader-btn {
  background-color: #fff;
  color: #333;
  border: 1px solid  #DDE1E7;
  border-radius: 20px;
  padding: 5px 12px;
  font-size: 0.85rem;
  cursor: pointer;
  transition: 0.3s;
}
.subheader-btn:hover {
  background-color: #f7f7f7;
}

/* ZONE ACTIONS du module actif */
.wpt-dashboard-subheader__actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.wpt-dashboard-subheader__no-actions {
  color: #666;
  font-size: 0.95rem;
}
.wpt-button--subheader {
  font-size: 0.85rem;
  padding: 6px 12px;
  margin: 4px 0;
  border-radius: 20px;
  border: none;
  background-color: #dfe7f3;
  cursor: pointer;
  transition: background-color 0.2s;
}
.wpt-button--subheader:hover {
  background-color: #cddaf0;
}

/*----------------------------------------------------
  BLOC 7) LAYOUT PRINCIPAL
-----------------------------------------------------*/
.wpt-dashboard-main-container {
  position: relative;
  margin-top: calc(var(--wpt-header-height) + var(--wpt-subheader-height));
  margin-left: var(--wpt-sidebar-width);
  margin-right: var(--wpt-sidebar-width);
  height: auto;
  max-width: 1400px;
  background: transparent;
  display: flex;
  flex-direction: row;
  flex: 1 1 auto;
  z-index: 99;
}

/*----------------------------------------------------
  BLOC 8) SIDEBAR GAUCHE FIXE
-----------------------------------------------------*/
.wpt-dashboard-sidebar--left {
  position: fixed;
  top: calc(var(--wpt-header-height) + var(--wpt-subheader-height));
  left: 0;
  width: var(--wpt-sidebar-width);
  bottom: 0;
  background-color: #fff;
  border-right: 1px solid #e0e0e0;
  border-radius: 0;
  overflow-y: auto;
  z-index: 997;
}

.wpt-dashboard-sidebar__inner {
  display: flex;
  flex-direction: column;
  padding: 12px;
}

/* Entête de la sidebar gauche : dégradé vif */
.wpt-sidebar-left-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: linear-gradient(135deg, var(--wpt-brand-color) 0%, #43fbe9 100%);
  padding: 1rem;
  height: 58px;
  display: flex;
  align-items: center;
  margin-bottom: 0;
  border-radius: 10px 10px 0 0;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
.wpt-sidebar-left-title {
  flex: 1;
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
}
.wpt-sidebar-left-btns {
  display: flex;
  align-items: center;
  gap: 8px;
}
.wpt-sidebar-settings-btn,
.wpt-sidebar-add-btn {
  background: none;
  color: #fff;
  font-size: 1.2rem;
  padding: 6px;
  border-radius: 50%;
  transition: transform 0.2s, background-color 0.3s;
}
.wpt-sidebar-settings-btn:hover,
.wpt-sidebar-add-btn:hover {
  transform: scale(1.1);
  background-color: rgba(255,255,255,0.2);
}

/* Contenu de la sidebar gauche */
.wpt-sidebar-left-content {
  flex: 1;
  overflow-y: auto;
  padding-right: 6px;
}

/* Blocs de modules */
.wpt-dashboard-sidebar-block {
  margin-bottom: 16px;
}
.wpt-dashboard-sidebar-block__title {
  font-size: 0.95rem;
  font-weight: 600;
  color: #444;
  margin-bottom: 6px;
  padding-left: 2px;
  border-left: 4px solid #ececec;
}

/* Items de modules : effet "carte" */
.wpt-dashboard-sidebar__item {
  margin: 6px 0;
}
.wpt-dashboard-sidebar__item-main {
  display: flex;
  align-items: center;
  position: relative; /* Permet au menu contextuel d'être au-dessus */
  padding: 6px 8px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid #eee;
  margin: 4px 0;
  transition: box-shadow 0.3s, background-color 0.2s;
  z-index: auto;
  overflow: visible; /* pour que le pseudo-élément puisse "déborder" */
}
.wpt-dashboard-sidebar__item-main::before {
  /* Le pseudo-élément va simuler le "décalage + ombre" */
  content: "";
  position: absolute;
  inset: 0; 
  background-color: transparent;
  border-radius: 8px;
  box-shadow: none;
  transition: transform 0.2s, box-shadow 0.3s, background-color 0.2s;
  z-index: -1;
}
.wpt-dashboard-sidebar__item-main:hover::before {
  transform: translateY(-2px);
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
  background-color: #fafafa;
}
.wpt-dashboard-sidebar__item-main:hover {
  background-color: transparent; 
  z-index: 1; 
}
.wpt-dashboard-sidebar__link {
  display: inline-flex;
  align-items: center;
  flex: 1;
  font-size: 0.88rem;
  color: #333;
  text-decoration: none;
}
.wpt-dashboard-sidebar__icon {
  width: 35px;
  height: auto;
  margin-right: 6px;
}
.wpt-dashboard-sidebar__link.wpt-active {
  font-weight: 600;
  background-color: var(--wpt-pastel-2);
  border-left: 4px solid var(--wpt-brand-color);
  color: var(--wpt-brand-color);
  border-radius: 8px;
  padding-left: 4px;
}

/* Bouton "..." */
.wpt-sidebar-options-btn {
  background: none;
  color: #666;
  font-size: 1.1rem;
  padding: 2px 6px;
  border-radius: 4px;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.2s;
  margin-left: auto;
}
.wpt-dashboard-sidebar__item-main:hover .wpt-sidebar-options-btn {
  opacity: 1;
}
.wpt-sidebar-options-btn:hover {
  background-color: #ddd;
}

/* Menu contextuel */
.wpt-sidebar-options-menu {
  position: absolute;
  top: 36px;
  right: 8px;
  background-color: #fff;
  border: 1px solid  #f1f4f7;
  box-shadow: 0 2px 6px #7f90a361;
  border-radius: 8px;
  z-index: 9999;
  min-width: 140px;
  margin-left: 15px;
  display: none; 
}
.wpt-sidebar-options-menu-item {
  width: 100%;
  background: none;
  border: none;
  text-align: left;
  padding: 12px;
  font-size: 0.9rem;
  color: #050505;
  cursor: pointer;
}
.wpt-sidebar-options-menu-item:hover {
  background-color: #e7f3ff;
  color: var(--wpt-brand-color);
}
.wpt-no-active-modules {
  font-size: 0.9rem;
  color: #666;
}

/*----------------------------------------------------
  BLOC 9) SIDEBAR DROITE FIXE (avec toggle)
-----------------------------------------------------*/
.wpt-dashboard-sidebar--right {
  position: fixed;
  top: calc(var(--wpt-header-height) + var(--wpt-subheader-height));
  right: 0;
  width: var(--wpt-sidebar-width);
  bottom: 0;
  background-color: #fbf7ff;
  overflow-y: auto;
  z-index: 997;
  transform: translateX(0%);
  transition: transform 0.3s ease;
}
.wpt-dashboard-sidebar--right.wpt-sidebar-right-collapsed {
  transform: translateX(100%);
}
.wpt-dashboard-main-container.wpt-sidebar-right-collapsed {
  margin-right: 0;
  transition: margin-right 0.3s ease;
}

/* Bouton flottant pour ouvrir/fermer la sidebar droite */
#wpt-toggle-right-sidebar-btn {
  position: fixed;
  top: calc(var(--wpt-header-height) + var(--wpt-subheader-height) + 32px);
  right: 0;
  z-index: 100000; /* Important : se placer au-dessus du layout */
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 30px 0 0 30px;
  background-color: var(--wpt-brand-color);
  color: #fff;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  cursor: pointer;
  transition: background-color 0.3s, transform 0.3s;
}
#wpt-toggle-right-sidebar-btn:hover {
  background-color: var(--wpt-brand-color-secondary);
  transform: scale(1.05);
}

/* Intérieur de la sidebar droite */
.wpt-dashboard-sidebar--right .wpt-dashboard-sidebar__inner {
  padding: 10px;
  background: #fff;
  border-radius: 8px;
  margin: 30px 15px 15px 15px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}
.wpt-dashboard-sidebar--right .wpt-dashboard-sidebar__title {
  font-size: 1rem;
  margin-bottom: 8px;
  color: var(--wpt-brand-color);
  font-weight: 700;
}
.wpt-sidebar-right-separator {
  height: 1px;
  background-color: #787878;
  margin-top: 0;
  border: none;
}
.wpt-dashboard-sidebar__no-info {
  font-size: 0.9rem;
  color: #666;
}

/*----------------------------------------------------
  BLOC 10) MAIN CONTENT
-----------------------------------------------------*/
.wpt-dashboard-main {
  background-color: #fff;
  border-radius: 12px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.06);
  position: relative;
  padding: 24px;
  margin: 16px;
  min-height: 400px;
  flex: 1;
  min-width: 0;
  transition: background-color 0.3s;
}
.wpt-dashboard-main__placeholder {
  color: #666;
  font-size: 1rem;
  margin-top: 20px;
}

/* Loader */
.wpt-main-loader {
  position: absolute;
  inset: 0;
  background-color: rgba(255,255,255,0.8);
  z-index: 999;
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}
.wpt-spinner {
  width: 32px; 
  height: 32px;
  border: 4px solid #DDE1E7;
  border-top: 4px solid var(--wpt-brand-color);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-bottom: 6px;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Animation fadeInUp */
.fade-in {
  animation: fadeInUp 0.3s ease forwards;
}
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(-5px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Barre d’en-tête du module (dans la zone main) */
.wpt-main-content-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.wpt-main-content-title {
  font-size: 1.2rem;
  font-weight: 600;
  color: #333;
}
.wpt-main-content-header-icons {
  display: flex;
  align-items: center;
  gap: 8px;
}
.wpt-main-content-icon-btn {
  background: none;
  border: none;
  color: #666;
  font-size: 1.2rem;
  padding: 4px 6px;
  border-radius: 4px;
  transition: background-color 0.2s, transform 0.2s;
}
.wpt-main-content-icon-btn:hover {
  background-color: #eee;
  transform: scale(1.05);
}
.wpt-main-content-separator {
  border: none;
  height: 1px;
  background-color: #ddd;
  margin: 8px 0;
}

/* Bloc KPI en scroll horizontal */
.wpt-module-kpis {
  white-space: nowrap;  
  overflow-x: auto;  
  padding: 8px 0;
  margin-bottom: 12px;
  background: #fafafa;
  border: 1px solid #eee;
  border-radius: 6px;
}
.wpt-module-kpi {
  display: inline-block;
  margin-right: 16px;
  padding: 6px 12px;
  border-radius: 4px;
  background: #fff;
  border: 1px solid #ddd;
  font-size: 0.9rem;
  color: #333;
}
.wpt-module-kpi:last-child {
  margin-right: 0;
}

/* Menu “…” contextuel dans le main */
.wpt-main-content-more-menu {
  position: absolute;
  right: 0;
  margin-top: 4px;
  background: #fff;
  border: 1px solid  #DDE1E7;
  border-radius: 4px;
  padding: 4px 0;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
  z-index: 2000;
}
.wpt-main-content-more-menu button {
  display: block;
  background: none;
  border: none;
  width: 100%;
  text-align: left;
  padding: 6px 12px;
  font-size: 0.9rem;
  color: #333;
  cursor: pointer;
}
.wpt-main-content-more-menu button:hover {
  background-color: #eee;
}

/*----------------------------------------------------
  BLOC 11) FOOTER
-----------------------------------------------------*/
.wpt-dashboard-footer {
  background-color: #fff;
  text-align: center;
  padding: 10px;
  border-top: 1px solid #e0e0e0;
}
.wpt-dashboard-footer small {
  color: #555;
}

/*----------------------------------------------------
  BLOC 12) BOUTONS GÉNÉRIQUES
-----------------------------------------------------*/
.wpt-button {
  min-height: var(--btn-height, 32px);
  text-transform: var(--btn-transform, none);
  background-color: #fff;
  color: #707070;
  border: none;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.2s, transform 0.2s;
}
.wpt-button:hover {
  background-color: #e2e5e9;
  transform: translateY(-1px);
  color: var(--wpt-brand-color);
}
.wpt-button:active {
  background-color: var(--wpt-brand-color);
  transform: translateY(0);
  color: #fff;
}

/*----------------------------------------------------
  BLOC 13) AUTRE VERSION TOOLTIP (via .wpt-tooltiptext)
-----------------------------------------------------*/
.wpt-tooltip .wpt-tooltiptext {
  visibility: hidden;
  background-color: #333;
  color: #fff;
  padding: 4px 6px;
  border-radius: 4px;
  font-size: 0.75rem;
  position: absolute;
  top: -30px;
  right: 0;
  white-space: nowrap;
  z-index: 9999;
  opacity: 0;
  transition: opacity 0.2s;
}
.wpt-tooltip:hover .wpt-tooltiptext {
  visibility: visible;
  opacity: 1;
}

/*----------------------------------------------------
  BLOC 14) SIDEBAR COLLAPSED (optionnel)
-----------------------------------------------------*/
.wpt-sidebar-collapsed {
  width: 60px !important;
  min-width: 60px !important;
  overflow: hidden;
}


/* Boutons spécifiques (optionnel) */
.filter-close-btn.close-modal {
  position: absolute;
  top: 10px;
  right: 10px;
  background: #615eff;
  color: #fff !important;
  border-radius: 12px;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
}
.btn-highlight {
  background-color: #f90 !important; 
  color: #fff;
  border: none;
  padding: 8px 12px;
  border-radius: 4px;
  margin-right: 5px;
}
.btn-highlight:hover {
  background-color: #e70; 
}
.btn-sm {
  font-size: 12px;
  padding: 4px 8px;
}

/*------------- Divers */
.fa-ellipsis-h:before {
  color:white;
}
.fa-chevron-right:before {
  color:white;
}

/* ==============================================================
   BLOC CONSEILS – Styles peaufinés (mis à jour)
   ============================================================== */

/* 1) Wrapper du bandeau + module */
.wpt-conseils-wrapper {
  width: 100%;
  position: relative;
  z-index: 990;
}

/* 2) Bandeau “Conseils” */
#conseils-bandeau {
  top: calc(var(--wpt-header-height) + var(--wpt-subheader-height) + 0.5rem);
  display: flex;
  align-items: flex-start;
  background-color: var(--wpt-pastel-2);
  border-radius: 0.5rem;
  
  padding: 1rem 1.25rem;
  transition: transform 0.3s ease, opacity 0.3s ease, max-height 0.3s ease;
  margin-bottom: 40px;

  /* suppression du overflow hidden */
  /* overflow: hidden; */
  
  max-height: 300px;    /* hauteur « ouverte » par défaut */
  overflow-y: auto;     /* scroll interne si le contenu dépasse */
  box-sizing: border-box;
}

/* 2.1) État FERMÉ */
#conseils-bandeau.conseils-closed {
  opacity: 0;
  transform: translateY(-1rem);
  pointer-events: none;

  max-height: 0;
  padding-top: 0;
  padding-bottom: 0;
  margin-bottom: 0;
}

/* 3) Croix “×” à gauche */
#conseils-close-btn {
  background: #fff;
  border: none;
  color: var(--wpt-text-color);
  font-size: 1.5rem;
  line-height: 1;
  padding: 8px 12px;
  cursor: pointer;
  flex-shrink: 0;
  transition: color 0.2s ease;
  order: 0;
  margin-right: 0.75rem;
  border-radius: 50%;
  align-items: center;
  justify-content: center;
}
#conseils-close-btn:hover {
  color: var(--wpt-brand-color);
}

/* 4) Contenu texte */
#conseils-bandeau .conseils-contenu {
  flex: 1;
}
.bb-conseils-title {
  display: block;
  font-size: 1.0625rem;
  font-weight: 700;
  color: var(--wpt-brand-color);
  margin-bottom: 0.75rem;
}
.bb-conseils-list {
  list-style-position: inside;
  padding-left: 1.25rem;
  margin: 0;
}
.bb-conseils-item {
  margin-bottom: 0.5rem;
  font-size: 0.9375rem;
  line-height: 1.4;
}
.bb-conseils-item strong {
  font-weight: 600;
}

/* 5) Icône “?” */
#conseils-icon {
  position: fixed;
  top: calc(var(--wpt-header-height) + var(--wpt-subheader-height) + 1rem);
  right: 1rem;
  z-index: 901;
  width: 2.5rem;
  height: 2.5rem;
  background-color: #615eff;
  color: #fff;
  font-weight: bold;
  font-size: 1.125rem;
  border-radius: 50%;
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0.25rem 0.5rem var(--wpt-shadow-color);
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.2s ease;
  margin-right: 40px;
  margin-top: -120px !important;
}
#conseils-icon:hover {
  background-color: var(--wpt-brand-color-secondary);
  transform: scale(1.05);
}
#conseils-icon.visible {
  display: flex;
}

/* 6) Décaler le module sous le bandeau quand il est ouvert */
.wpt-conseils-wrapper:not(.conseils-closed) .module-content-inner {
  padding-top: 4rem;
}
.wpt-conseils-wrapper.conseils-closed .module-content-inner {
  padding-top: 0;
}

/* ── Conteneur général ── */
.wpt-conseils-wrapper #conseils-bandeau {
  position: sticky;
  top: 0; left: 0; right: 0;

  border: 12px solid #fafaff;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, opacity 0.3s ease;
  z-index: 1000;
}

/* ── Header minimaliste ── */
.wpt-conseils-wrapper #conseils-bandeau .conseils-header {
  display: flex;
      justify-content: space-between;
      align-items: center;
      padding: 0.75rem 1rem;
      width: 100%;
}

/* Titre */
.wpt-conseils-wrapper #conseils-bandeau .bb-conseils-title {
  margin: 0;
  font-size: 1.2rem;
  font-weight: 600;
  color: #615eff;
}

/* Bouton fermer */
.wpt-conseils-wrapper #conseils-bandeau #conseils-close-btn {
  background: #ffffff;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  transition: transform 0.2s ease;
}
.wpt-conseils-wrapper #conseils-bandeau #conseils-close-btn:hover {
  transform: scale(1.2);
}

/* ── Contenu ── */
.wpt-conseils-wrapper #conseils-bandeau .conseils-contenu {
  color: #605effad;
  padding: 0.75rem 1rem;
  width: 100%;
}

.wpt-conseils-wrapper #conseils-bandeau .bb-conseils-list {
  margin: 0;
  padding-left: 1.25rem;
}

.wpt-conseils-wrapper #conseils-bandeau .bb-conseils-item {
  margin-bottom: 0.5rem;
  line-height: 1.4;
}

/* ── Icône “?” (inchangée) ── */
.wpt-conseils-wrapper #conseils-icon {
  display: none;
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: #615eff;
  color: #fff;
  border: none;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: opacity 0.3s ease;
}

/* ── État fermé ── */
.wpt-conseils-wrapper.conseils-closed #conseils-bandeau {
  transform: translateY(-120%);
  opacity: 0;
  pointer-events: none;
}

/* Afficher l'icône “?” quand fermé */
.wpt-conseils-wrapper.conseils-closed #conseils-icon {
  display: flex;
}
.wpt-conseils-wrapper:not(.conseils-closed) #conseils-icon {
  display: none;
}


/* 7) Responsive Mobile */
@media (max-width: 768px) {
  #conseils-bandeau {
    max-height: 50vh;
    margin: 20px 10px 40px 10px;
    padding: 0.75rem 1rem;
  }
  #conseils-bandeau.conseils-closed {
    margin: 0 10px;
    margin-bottom: 0;
  }

  /* Scrollable area dans le bloc conseils */
  #conseils-bandeau .conseils-contenu {
    max-height: calc(50vh - 60px);
    overflow-y: auto;
  }

  #conseils-close-btn {
    font-size: 1.25rem;
    margin-right: 0.5rem;
  }
  .bb-conseils-title {
    font-size: 1rem;
    margin-bottom: 0.5rem;
  }
  .bb-conseils-list {
    padding-left: 1rem;
  }
  .bb-conseils-item {
    font-size: 0.875rem;
    margin-bottom: 0.4rem;
  }
  #conseils-icon {
    top: calc(var(--wpt-header-height) + var(--wpt-subheader-height) + 0.75rem);
    width: 2.25rem;
    height: 2.25rem;
    font-size: 1rem;
    right: 0.75rem;
  }
  .wpt-conseils-wrapper:not(.conseils-closed) .module-content-inner {
    padding-top: 3.5rem;
  }
  #conseils-icon {
    margin-top: 22px !important;
  }
  .wpt-conseils-wrapper #conseils-bandeau #conseils-close-btn {
    margin-top: -40px;
    margin-right: -20px;
}
}
