/* Grille principale */
.deal-grid {
  display: grid;
  grid-template-rows: repeat(3, auto);
  gap: 10px;
  justify-content: center;
  padding: 10px;
  max-width: 580px;
  margin: 10px auto;
}
.deal-grid.all-visible {
  /*background: #E6EEF9;*/
  padding: 20px;
  border-radius: 10px;
}
.deal-format-schema.small-format .deal-grid{
	padding: 0 !important;
}

.deal-grid .row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.deal-format-schema.small-format .deal-grid .row {
  gap: 6px;
}

/* Cellules */

.deal-grid .cell {
  background: #ffffff;
  border-radius: 6px;
  border: 4px solid var(--color-blue-80);
  text-align: center;
  box-sizing: border-box;
  aspect-ratio: 1 / 1; /* ðŸ”¥ garantit un carrÃ© */
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  max-width: 180px;
  min-width: 180px;
  width: 100%;
  min-height: 180px;
  word-break: break-word;

}
.deal-format-schema.small-format .deal-grid .cell {
    max-width: 120px;
    min-width: 120px;
    min-height: 120px;
}


.deal-grid .cell.null {
  background: transparent;
  border: none;
  padding: 0;
}

.deal-grid .cell.center {
  background: var(--color-blue-80);
  color: white;
  font-weight: bold;
  font-size: 1.5em;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 6px;
}

/* Noms des joueurs */
.player-name {
  font-weight: 400;
  font-size: 0.8em;
  background: #ffffff;
  padding: 4px 8px;
  border-bottom: 2px solid var(--color-blue-80);
  margin-bottom: 8px;
  width: 100%;
	text-align:left
}

/* Main du joueur */
.player-hand {
  font-size: 0.95em;
  width:100%;
  padding: 4px 8px;
}
.deal-format-schema.small-format .player-hand {
  font-size: 0.75em;
  padding: 0px 8px;
}

.suit-row {
  display: flex;
  justify-content: start;
  align-items: center;
  margin: 3px 0;
  gap: 5px;
}
.deal-format-schema.small-format .suit-row {
  margin: 0;
}

.suit-symbol {
  width: 1.2em;
  display: inline-block;
  text-align: center;
  font-weight: bold;
}

.suit-cards {
  font-size: 1.2em;
  letter-spacing: 1px;
	font-weight: bold;
    max-width: 130px;
    /*overflow-x: scroll;*/
    white-space: nowrap;
}

/* Couleurs â™  â™¥ â™¦ â™£ */
.spades .suit-symbol {
  color: black;
}
.hearts .suit-symbol {
  color: #c00;
}
.diamonds .suit-symbol {
  color: orange;
}
.clubs .suit-symbol {
  color: green;
}
.cell.center-compass {
  background: var(--color-blue-80);
  color: white;
  font-weight: bold;
  font-size: 1.2em;
  border-radius: 6px;
  aspect-ratio: 1 / 1;         /* ðŸ‘ˆ identique aux autres */
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  width: 100%;
  max-width: 250px;            /* ðŸ‘ˆ mÃªme que .cell */
}
.deal-format-schema.small-format .cell.center-compass {
  font-size: 1.0em;
}

.center-compass .compass-n,
.center-compass .compass-s,
.center-compass .compass-e,
.center-compass .compass-w {
  position: absolute;
}

.center-compass .compass-n {
  top: 8px;
  left: 50%;
  transform: translateX(-50%);
}

.center-compass .compass-s {
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
}

.center-compass .compass-e {
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
}

.center-compass .compass-w {
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
}

/* === Affichage cartes à jouer en ligne === */
/* === Main en ligne === */
/* === Main en ligne === */
.card-hand.card-style-line {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  position: relative;
  margin: 1rem auto;
  width: 100%;
  max-width: 800px;
  padding: 20px 0;
  height: auto;
  overflow: visible;
}

/* === Variables animables === */
@property --base-ty {
  syntax: '<length>';
  initial-value: 0px;
  inherits: false;
}
@property --hover-lift {
  syntax: '<length>';
  initial-value: 0px;
  inherits: false;
}

/* === Cartes === */
.card-hand.card-style-line .card-img {
  width: var(--card-width, 11%);
  height: auto;
  flex-shrink: 0;
  margin-left: var(--card-overlap, -55px);
  transition: transform 0.25s ease, filter 0.25s ease;
  z-index: 1;
  opacity: 0;

  /* variables de position */
  --base-ty: 0px;
  --hover-lift: 0px;
  transform: translateY(calc(var(--base-ty) + var(--hover-lift)));

  /* animation d’entrée */
  animation: dealLineIn 0.45s ease forwards;
}

/* Première carte sans chevauchement */
.card-hand.card-style-line .card-img:first-child {
  margin-left: 0;
}

/* === Animation d’entrée === */
@keyframes dealLineIn {
  0% {
    opacity: 0;
    --base-ty: 50px;
  }
  100% {
    opacity: 1;
    --base-ty: 0px;
  }
}

/* Quand l’animation est terminée → on fige sa valeur finale */
.card-hand.card-style-line .card-img {
  animation-fill-mode: forwards;
  animation-delay: var(--anim-delay, 0s);
}

/* Hover : indépendant de l’animation */
.card-hand.card-style-line .card-img:hover {
  --hover-lift: -25px; /* soulève la carte */
  z-index: 10;
  filter: brightness(1.1);
  transition: transform 0.25s cubic-bezier(.22,.61,.36,1), filter 0.25s ease;
}

/* === Responsive === */
@media (max-width: 768px) {
  .card-hand.card-style-line {
    max-width: 100%;
    padding: 10px 0;
  }
  .card-hand.card-style-line .card-img {
    --card-width: 14%;
    --card-overlap: -35px;
  }
}


/* Délai progressif pour effet “distribution” */
.card-hand.card-style-line .card-img:nth-child(1)  { animation-delay: 0.00s; }
.card-hand.card-style-line .card-img:nth-child(2)  { animation-delay: 0.05s; }
.card-hand.card-style-line .card-img:nth-child(3)  { animation-delay: 0.10s; }
.card-hand.card-style-line .card-img:nth-child(4)  { animation-delay: 0.15s; }
.card-hand.card-style-line .card-img:nth-child(5)  { animation-delay: 0.20s; }
.card-hand.card-style-line .card-img:nth-child(6)  { animation-delay: 0.25s; }
.card-hand.card-style-line .card-img:nth-child(7)  { animation-delay: 0.30s; }
.card-hand.card-style-line .card-img:nth-child(8)  { animation-delay: 0.35s; }
.card-hand.card-style-line .card-img:nth-child(9)  { animation-delay: 0.40s; }
.card-hand.card-style-line .card-img:nth-child(10) { animation-delay: 0.45s; }
.card-hand.card-style-line .card-img:nth-child(11) { animation-delay: 0.50s; }
.card-hand.card-style-line .card-img:nth-child(12) { animation-delay: 0.55s; }
.card-hand.card-style-line .card-img:nth-child(13) { animation-delay: 0.60s; }




/* Style CURVE : main en éventail */
.card-hand.card-style-curve {
  position: relative;
  width: 100%;
  max-width: 800px;
  aspect-ratio: 3 / 1;
  margin: 2rem auto;
  overflow: visible;
  min-height: 400px;
}

/* === Base : toutes les cartes === */
.card-hand.card-style-curve .card-img {
  position: absolute;
  left: 50%;
  top: 50%;
  transform-origin: center bottom;
  width: var(--card-width, 60px);
  height: auto;
  transition:
    transform 0.3s ease,
    filter 0.3s ease,
    z-index 0.1s;
  opacity: 0;
  animation: handFanOpen 0.8s cubic-bezier(.22, .61, .36, 1) forwards;

  /* Nouvelle variable pour le hover */
  --hover-lift: 0px;
}

/* === Animation d’ouverture réaliste === */
@keyframes handFanOpen {
  0% {
    opacity: 0;
    transform:
      translate(-50%, -20%)
      rotate(0deg)
      scale(0.4);
  }
  40% {
    opacity: 1;
    transform:
      translate(-50%, -40%)
      rotate(var(--ang))
      scale(0.8);
  }
  100% {
    opacity: 1;
    transform:
      translate(var(--tx), calc(var(--ty) + var(--hover-lift)))
      rotate(var(--ang))
      scale(1);
  }
}

/* === Hover : modifie juste la variable === */
.card-hand.card-style-curve .card-img:hover {
  --hover-lift: -25px; /* la carte monte */
  z-index: 999;
  filter: brightness(1.1);
  transition: transform 0.25s cubic-bezier(.22, .61, .36, 1), filter 0.25s ease;
}

/* === Délai d'apparition échelonné === */
.card-hand.card-style-curve .card-img:nth-child(1)  { animation-delay: 0.00s; }
.card-hand.card-style-curve .card-img:nth-child(2)  { animation-delay: 0.05s; }
.card-hand.card-style-curve .card-img:nth-child(3)  { animation-delay: 0.10s; }
.card-hand.card-style-curve .card-img:nth-child(4)  { animation-delay: 0.15s; }
.card-hand.card-style-curve .card-img:nth-child(5)  { animation-delay: 0.20s; }
.card-hand.card-style-curve .card-img:nth-child(6)  { animation-delay: 0.25s; }
.card-hand.card-style-curve .card-img:nth-child(7)  { animation-delay: 0.30s; }
.card-hand.card-style-curve .card-img:nth-child(8)  { animation-delay: 0.35s; }
.card-hand.card-style-curve .card-img:nth-child(9)  { animation-delay: 0.40s; }
.card-hand.card-style-curve .card-img:nth-child(10) { animation-delay: 0.45s; }
.card-hand.card-style-curve .card-img:nth-child(11) { animation-delay: 0.50s; }
.card-hand.card-style-curve .card-img:nth-child(12) { animation-delay: 0.55s; }
.card-hand.card-style-curve .card-img:nth-child(13) { animation-delay: 0.60s; }



/* Responsive */
@media (max-width: 600px) {
  .card-hand.card-style-curve {
    aspect-ratio: 2.5 / 1;
  }
  .card-hand.card-style-curve .card-img {
    width: var(--card-width, 12vw);
  }
}
@media (max-width: 768px) {
  .card-hand.card-style-curve {
    transform: scale(0.8);
    transform-origin: center bottom;
  }
}
@media (max-width: 500px) {
  .card-hand.card-style-curve {
    transform: scale(0.65);
  }
}
/* === Ombre légère pour toutes les cartes === */
.card-hand .card-img {
  box-shadow: 0 3px 6px rgba(0, 0, 0, 0.15),
              0 1px 3px rgba(0, 0, 0, 0.1);
  background: white; /* pour éviter la transparence du SVG */
  transition: box-shadow 0.25s ease, transform 0.25s ease;
}

/* Au survol : ombre plus marquée */
.card-hand .card-img:hover {
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.25),
              0 3px 6px rgba(0, 0, 0, 0.15);
}




/* Responsive */
@media (max-width: 768px) {
  
	.deal-grid .cell {
		max-width: 140px;
		min-width: 140px;
		min-height: 140px;

	}
}

.deal-format-schema{
	display: flex;
    flex-direction: column;
    justify-content: center;
}
.deal-content{
	text-align:center;
}

/* === Tableau d'enchères === */
.auction-table {
  display: inline-block;
  border-radius: 8px;
  background: #f8fbff;
  padding: 10px;
  font-size: 1.2rem;
  text-align: center;
  margin: 1.5rem auto;
}

.auction-header, .auction-row {
  display: grid;
  grid-template-columns: repeat(4, 70px);
  gap: 6px;
  margin-bottom: 4px;
}

.auction-cell {
  position: relative;
  background: white;
  padding: 6px 0;
  border-radius: 6px;
  min-height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 500;
  color: #1a1a1a;
}

.auction-cell.header {
  background: #eaf3ff;
  font-weight: 900;
  color: #123;
}

.bid-pass { color: #0a662e; font-weight: 600; }
.bid-x    { color: #c00; font-weight: 700; }
.bid-xx   { color: #b00; font-weight: 700; text-decoration: underline; }

.suit-♠, .suit-s { color: #000; }
.suit-♥, .suit-h { color: #c00; }
.suit-♦, .suit-d { color: #e67300; }
.suit-♣, .suit-c { color: #007a33; }

/* Icône d'alerte */
.alert-icon {
  position:absolute; top:-6px; right:-6px;
  background:#5a8ff0; color:#fff; font-size:11px; font-weight:800;
  border-radius:6px; padding:2px 4px; line-height:1; cursor:help;
  box-shadow:0 2px 6px rgba(0,0,0,.15);
  transform:translateZ(0);
}
.alert-icon:hover { transform:scale(1.08); }


/* === Toast Notifications === */
.bdm-toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.bdm-toast {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #84b797;
  color: #000;
  font-weight: 600;
  border-radius: 12px;
  padding: 12px 16px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  opacity: 0;
  transform: translateX(40px);
  transition: all 0.35s ease;
  min-width: 220px;
}

.bdm-toast.show {
  opacity: 1;
  transform: translateX(0);
}

.bdm-toast__icon {
  font-size: 18px;
  flex-shrink: 0;
}

.bdm-toast--error {
  background: #fdeaea;
  color: #8a1c1c;
}

.bdm-toast--error .bdm-toast__icon {
  color: #d23030;
}

.bdm-versions-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-height: 400px;
  overflow-y: auto;
}

/* bloc d’une version */
.bdm-version-card {
  background: #fff;
  border: 1px solid #d5ddf0;
  border-radius: 8px;
  padding: 16px 20px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.bdm-version-card h4 {
  margin: 0 0 8px;
  color: #001a5b;
  font-size: 1.05rem;
}

.bdm-version-meta {
  font-size: 14px;
  color: #223d74;
  margin-bottom: 8px;
}

.bdm-version-links {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.bdm-version-links a {
  font-size: 14px;
  background: var(--color-blue-80);
  border-radius: 24px;
  padding: 4px 10px;
  color: #fff;
  text-decoration: none;
  border: 1px solid var(--color-blue-80);
}
.bdm-version-links a:hover {
  background: var(--color-blue-secondary);
	color: #fff;
}
.bdm-version-links .shortcode {
  font-size: 14px;
  font-family: monospace;
  background: #eaf3ff;
  border-radius: 6px;
  padding: 4px 10px;
  color: #001a5b;
  text-decoration: none;
  border: 1px solid #d5ddf0;
}


.bdm-display-block {
	border: 1px solid #ccc;
	padding: 1.5em;
	margin-bottom: 2em;
	background: #f9f9f9;
	border-radius: 8px;
}
.bdm-display-shortcode input {
	width: 100%;
	padding: 0.5em;
	font-family: monospace;
}
.bdm-display-preview {
	margin-top: 1em;
	margin-bottom: 1em;
}
.bdm-display-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 1.5rem;
  margin: 2rem 0;
  box-shadow: 0 4px 10px rgba(0,0,0,0.05);
  transition: transform .2s ease, box-shadow .2s ease;
}
.bdm-display-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 18px rgba(0,0,0,0.08);
}

.bdm-display-header {
  border-bottom: 1px solid #edf2f7;
  margin-bottom: 1rem;
  padding-bottom: .5rem;
}

.bdm-display-title {
  margin: 0;
  font-size: 1.2rem;
  color: #001a5b;
  font-weight: 700;
}

.bdm-display-sections {
  margin: .25rem 0 0;
  font-size: .9rem;
  color: #555;
}

.bdm-display-sections span {
  font-weight: 600;
  color: #001a5b;
}

.bdm-display-content {
  margin: 1.2rem 0;
  background: #f8fafc;
  border-radius: 8px;
  padding: 1rem;
  overflow-x: auto;
}

.bdm-display-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 1rem;
  border-top: 1px solid #edf2f7;
  padding-top: 1rem;
}

.bdm-shortcode-box {
  position: relative;
  flex: 1;
  min-width: 240px;
}

.bdm-shortcode-input {
  width: 100%;
  border: 1px solid #cbd5e0;
  border-radius: 6px;
  padding: .5rem 2.5rem .5rem .75rem;
  font-family: monospace;
  font-size: .9rem;
  color: #2d3748;
  background: #f1f5f9;
}

.bdm-btn-copy {
  position: absolute;
  right: .4rem;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  background: none;
  color: #001a5b;
  font-size: 1rem;
  cursor: pointer;
  transition: color .2s;
}
.bdm-btn-copy:hover {
  color: #0b2cc2;
}

.bdm-btn-print {
  border: none;
  background: #001a5b;
  color: #fff;
  border-radius: 6px;
  padding: .5rem 1rem;
  cursor: pointer;
  font-size: .9rem;
  display: flex;
  align-items: center;
  gap: .4rem;
  transition: background .2s;
}
.bdm-btn-print:hover {
  background: #0b2cc2;
}

/* Métadonnées de la donne */
.deal-meta-data {
    color: #333;
    line-height: 1.5;
}

.deal-meta-row {
    margin-bottom: 5px;
}

.deal-meta-notes {
    background: #f9f9f9;
    padding: 10px;
    border-radius: 4px;
    border-left: 3px solid #0073aa; /* Couleur WordPress ou celle de votre thème */
}

/* Ajustement mode petit format */
.small-format .deal-meta-data {
    font-size: 0.85em;
}
/* =========================================================
   BDM - FRONT-END : LAYOUT & PINNABLE DEALS
   ========================================================= */

/* --- 1. BOUTON PUNAISE (Pilule) --- */
.bdm-deal-wrapper {
    position: relative;
    margin-bottom: 2em;
}

.bdm-pin-btn {
    position: absolute;
    top: -15px;
    right: 0;
    background: var(--color-blue-primary, #00024E);
    color: #fff;
    border: none;
    border-radius: 20px;
    padding: 6px 14px;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
    opacity: 0.7;
    transition: all 0.2s ease;
}

.bdm-deal-wrapper.bdm-is-pinnable:hover .bdm-pin-btn {
    opacity: 1;
}

.bdm-pin-btn:hover {
    background: var(--color-blue-secondary, #122A70);
    transform: translateY(-2px);
}

/* --- 2. ÉTAT FLOTTANT (POPUP) --- */
.bdm-deal-wrapper.is-pinned {
    position: fixed !important;
    bottom: 20px;
    right: 20px;
    width: max-content; /* Épouse la taille de la donne/enchère */
    max-width: 35vw;
    background: #fff;
    padding: 30px 20px 20px 20px; /* Espace en haut pour la croix */
    box-shadow: 0 10px 40px rgba(0,0,0,0.25);
    z-index: 99999;
    border-radius: 12px;
    border: 1px solid #ddd;
    cursor: grab;
    max-height: 90vh;
    overflow-y: auto;
    margin: 0;
	inset: auto !important;
}

.bdm-deal-wrapper.is-pinned:active {
    cursor: grabbing;
}

/* La croix de fermeture (Transparente, en haut à droite) */
.bdm-deal-wrapper.is-pinned .bdm-pin-btn {
    background: transparent;
    color: #999;
    box-shadow: none;
    padding: 5px;
    top: 5px;
    right: 10px;
    border-radius: 0;
    opacity: 1;
}
.bdm-deal-wrapper.is-pinned .bdm-pin-btn:hover {
    color: var(--color-red-60, #d02b3b);
    transform: scale(1.1);
}

.bdm-deal-wrapper.is-pinned button, 
.bdm-deal-wrapper.is-pinned a {
    cursor: pointer;
}

/* --- 3. LAYOUT CÔTE À CÔTE --- */
.bdm-layout-side-by-side .deal-content {
    display: flex;
    flex-direction: row;
    gap: 40px;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap; /* Passe à la ligne sur mobile si pas de place */
}

.bdm-layout-side-by-side .small-format .deal-content {
    flex-direction: column;
}

/* Retire les marges natives du bloc donne pour un alignement propre */
.bdm-layout-side-by-side .deal-content > div {
    margin: 0; 
}

/* Style du bouton Read More généré en JS */
.bdm-read-more-wrapper {
    text-align: center;
    margin: 32px 0;
}

.bdm-read-more-btn {
    background-color: #0f172a; /* Bleu foncé / Noir */
    color: white;
    border: none;
    padding: 12px 28px;
    border-radius: 30px;
    font-size: 15px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease-in-out;
    display: inline-flex;
    align-items: center;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.bdm-read-more-btn:hover {
    background-color: #334155;
    transform: translateY(-2px);
}

/* Optionnel : petite animation d'apparition du contenu */
.bdm-expandable-content {
    animation: fadeIn 0.5s ease-in-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}
/* ==========================================================================
   COULEURS DES SYMBOLES D'ENCHÈRES
   ========================================================================== */
.suit-s { color: #000; } /* Pique (Bleu foncé) */
.suit-h { color: #d63031; } /* Coeur (Rouge) */
.suit-d { color: #f28c1a; } /* Carreau (Orange) */
.suit-c { color: #1b7a52; } /* Trèfle (Vert) */
.suit-nt { color: #0b1a52; } /* SA / NT */

/* ==========================================================================
   CELLULES D'ENCHÈRES ET BADGES (ALERTES / COMMENTAIRES)
   ========================================================================== */
.auction-cell {
    position: relative;
    /* (Garde tes autres styles pour padding, border, etc.) */
}

/* Conteneur invisible pour ne pas gêner le centrage du texte */
.bdm-cell-badges {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    pointer-events: none; 
}
/* A Bleu en haut à droite */
.bid-badge-alert {
    position: absolute;
    top: 0; /* Collé en haut */
    right: 0; /* Collé à droite */
    width: 16px; /* Plus petit */
    height: 16px;
    background-color: #566cc4;
    color: white;
    font-size: 10px; /* Plus petit */
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 3px;
    pointer-events: auto;
    cursor: help;
    line-height: 1;
}

/* Carré Vert en bas à droite */
.bid-badge-comment {
    position: absolute;
    bottom: 0; /* Collé en bas */
    right: 0; /* Collé à droite */
    width: 18px; /* Plus petit */
    height: 18px;
    background-color: #5e8a5f;
    color: white;
    font-size: 10px; /* Plus petit */
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 3px;
    pointer-events: auto;
    cursor: pointer;
    outline: none;
}
/* ==========================================================================
   INFOBULLE (TOOLTIP) STYLISÉE
   ========================================================================== */
.bdm-comment-popup {
    visibility: hidden;
    opacity: 0;
    position: absolute;
    bottom: calc(100% + 12px); /* Espace pour la flèche */
    left: 50%; /* On centre par rapport à l'icône verte */
    transform: translateX(-50%);
    background: #ffffff;
    color: #0b1a52;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    white-space: normal !important; /* Permet le retour à la ligne */
    min-width: max-content;
    max-width: 250px;
    text-align: center;
    box-shadow: 0px 8px 24px rgba(0, 0, 0, 0.12);
    border: 1px solid #dfe7fb;
    transition: all 0.2s ease;
    z-index: 100;
    pointer-events: none;
}

/* Le petit carré pivoté qui sert de flèche */
.bdm-comment-popup::after {
    content: '';
    position: absolute;
    bottom: -7px; /* Dépasse vers le bas */
    left: 50%;
    margin-left: -6px; /* Moitié de la largeur (12px) pour centrer pile poil */
    width: 12px;
    height: 12px;
    background: #ffffff;
    border-right: 1px solid #dfe7fb;
    border-bottom: 1px solid #dfe7fb;
    border-top: none; /* Annule les anciennes bordures au cas où */
    border-left: none;
    transform: rotate(45deg);
    z-index: 2;
}

/* Animation d'apparition */
.bid-badge-comment:hover .bdm-comment-popup,
.bid-badge-comment:focus .bdm-comment-popup {
    visibility: visible;
    opacity: 1;
    bottom: calc(100% + 15px); /* Petit effet de glissement vers le haut */
}

/* Container & Header */
.bdm-library-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

/* Bouton Create a deal avec icone */
.bdm-btn-create {
    background-color: #F37561;
    color: #ffffff !important;
    padding: 10px 20px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: bold;
    display: inline-flex;
    align-items: center;
    gap: 8px; /* Espace entre le texte et l'icône */
    transition: background 0.3s ease;
}
.bdm-btn-create:hover {
    background-color: #d96653; /* Légèrement plus sombre au survol */
}

/* Filtres et Spinner AJAX */
.bdm-filters-form {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
    align-items: center;
    background: #f9f9fc;
    padding: 15px;
    border-radius: 12px;
}
.bdm-filters-form input, .bdm-filters-form select {
    padding: 8px 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    flex: 1;
    max-width: 300px;
}
#bdm-filter-spinner {
    color: #6393D6;
    font-size: 1.2rem;
}

/* Accordéon des cartes */
.deal-accordion {
    background: #ffffff;
    border-radius: 12px;
    margin-bottom: 15px;
    padding: 15px 20px;
    border: 1px solid #eef2f9; /* Bordure discrète par défaut au lieu de l'ombre */
    box-shadow: none; /* Pas d'ombre au départ */
    transition: all 0.3s ease;
}

/* Ombre au survol ET quand la carte est dépliée */
.deal-accordion:hover, 
.deal-accordion[open] {
    box-shadow: 0 4px 15px rgba(11, 26, 82, 0.1); /* Couleur de l'ombre ajustée */
    border-color: transparent;
}

.deal-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    list-style: none; /* Cache la flèche native sur certains navigateurs */
}
.deal-summary::-webkit-details-marker {
    display: none; /* Cache la flèche sur Chrome/Safari */
}

.deal-summary-info {
    flex-grow: 1;
}

.deal-title {
    margin: 0 0 5px 0;
    font-size: 1.2rem;
    color: #0b1a52; /* BDM Bleu */
}

.deal-meta {
    font-size: 0.9rem;
    color: #666;
    display: flex;
    gap: 10px;
}

.deal-actions {
    display: flex;
    gap: 20px;
    align-items: center;
}

/* Boutons Ghost (Edit / View) */
.bdm-ghost-btn {
    background: transparent !important;
    color: #6393D6 !important;
    border: none;
    padding: 5px 0px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 500;
    transition: all 0.2s ease;
	font-size: 16px;
	border-bottom: 1px solid transparent;
}
.bdm-ghost-btn:hover {
	border-bottom: 1px solid #6393D6;
    background: transparent !important;
}
.bdm-ghost-btn-small {
    font-size: 0.9em;
    padding: 2px 5px;
}
.bdm-ghost-btn i {
    color: #6393D6; /* S'assure que les icônes prennent bien la couleur */
	font-size: 14px;
}

/* Contenu de l'accordéon (déplié) */
.deal-accordion-body {
    padding-top: 20px;
    margin-top: 15px;
    border-top: 1px solid #eee;
}

.deal-tags-wrapper {
    margin: 10px 0;
}
.bdm-tag {
    background: #eef2f9;
    color: #3860B0;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.85rem;
    margin-right: 5px;
}

.deal-displays-section {
    margin-top: 15px;
}

.deal-displays-list {
    margin: 10px 0 0 0;
    padding-left: 20px;
}
.deal-display-item {
    margin-bottom: 5px;
    display: flex;
    align-items: center;
    gap: 10px; /* Espace le label et le bouton view */
}
#deal-id-tag{
	margin-bottom: 0 !important;
}
/* =========================================================
   STYLE DU CONTEXTE ET DE LA NOTE PUBLIQUE (FRONT-END)
   ========================================================= */
.bdm-deal-context-box {
    margin-top: 25px;
    margin-bottom: 20px;
    font-family: inherit;
    color: #0b1a52;
}

/* Grille du contexte (Dealer, Lead, etc.) */
.bdm-context-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 24px;
    justify-content: center;
    background: #f8fafc; /* Gris très très clair */
    padding: 12px 20px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    margin-bottom: 15px;
}

.bdm-context-item {
    display: flex;
    gap: 6px;
    align-items: center;
    font-size: 15px;
}

.bdm-context-item strong {
    font-weight: 700;
    color: #64748b; /* Gris texte */
}

.bdm-lead-card {
    font-weight: 700;
    font-size: 16px;
}

/* Bloc Note de l'auteur */
.bdm-public-note {
    background: #f0fdf4; /* Vert très clair/pastel */
    border-left: 4px solid #22c55e; /* Bordure verte */
    padding: 15px 20px;
    border-radius: 4px 8px 8px 4px;
    text-align: left;
}

.bdm-note-title {
    margin: 0 0 6px 0;
    font-size: 14px;
    font-weight: 700;
    color: #166534;
    display: flex;
    align-items: center;
    gap: 8px;
}

.bdm-note-content {
    color: #14532d;
    line-height: 1.5;
    font-size: 15px;
}