/* =========================================================
   Accueil PC / mobile : classique, intégré ou fenêtre en salon
   - Sur PC, le mode fenêtre ne change pas la vue active.
   - Sur mobile, les cadres restent intégrés à Accueil.
   - Aucun flou ni voile bloquant derrière la fenêtre PC.
   ========================================================= */
/* =========================================================
   Anti-clignotement au chargement / reconnexion
   - N'affiche jamais la barre « Votre message » pendant que
     l'Accueil personnalisé est en cours de mise en place.
   - Garde la liste source des salons invisible jusqu'au montage
     du vrai cadre Accueil et jusqu'à la première liste serveur.
   ========================================================= */
html.dc-home-mode-pending body.home-active #message-input-container,
html.dc-home-mode-pending body.home-active #mobile-message-toggle,
html.dc-preload-custom-home body.home-active #message-input-container,
html.dc-preload-custom-home body.home-active #mobile-message-toggle,
body.dc-home-custom-mode-enabled.home-active #message-input-container,
body.dc-home-custom-mode-enabled.home-active #mobile-message-toggle {
  display: none !important;
}

html.dc-home-mode-pending body.home-active #channel-sidebar,
html.dc-preload-custom-home body.home-active #channel-sidebar,
body.dc-home-custom-mode-enabled.home-active:not(.dc-home-surface-open) #channel-sidebar {
  visibility: hidden !important;
  pointer-events: none !important;
}

.dc-desktop-home-surface.dc-home-salons-pending .dc-desktop-home-salons-list-wrap {
  visibility: hidden !important;
  pointer-events: none !important;
}

@media (min-width: 769px) {
  /* Empêche l'ancien Accueil classique d'apparaître brièvement avant
     la réception du réglage du panel. Le cadre correct prend ensuite sa place. */
  html.dc-home-mode-pending body.home-active #home-layout > #home-salons-col,
  html.dc-home-mode-pending body.home-active #home-layout > #home-right-col,
  html.dc-preload-custom-home body.home-active #home-layout > #home-salons-col,
  html.dc-preload-custom-home body.home-active #home-layout > #home-right-col {
    display: none !important;
  }

  #home-tab.dc-home-tab-modal-mode {
    cursor: pointer;
  }

  #home-tab.dc-home-modal-open-tab {
    box-shadow: 0 0 0 1px rgba(0, 218, 222, .72),
                0 0 12px rgba(251, 0, 255, .38) !important;
  }

  #home-tab.dc-home-tab-window-mode::after {
    content: "↗";
    margin-left: 7px;
    font-size: 12px;
    opacity: .72;
  }

  .dc-desktop-home-close {
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    display: grid;
    place-items: center;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, .14);
    border-radius: 12px;
    color: #fff;
    background: rgba(255, 255, 255, .055);
    font-size: 30px;
    line-height: 1;
    cursor: pointer;
  }

  .dc-desktop-home-close[hidden] {
    display: none !important;
  }

  .dc-desktop-home-close:hover,
  .dc-desktop-home-close:focus-visible {
    outline: none;
    border-color: rgba(255, 91, 117, .75);
    background: rgba(255, 91, 117, .16);
  }

  /* Accueil intégré : aucune barre « Votre message » sous les cadres,
     sur PC comme sur mobile. La saisie reste inchangée dans les salons et les MP. */
  body.dc-home-embedded-open.home-active #message-input-container {
    display: none !important;
  }

  /* En mode intégré, les deux anciennes colonnes de l'Accueil classique
     ne doivent jamais apparaître derrière le nouveau cadre. */
  body.dc-home-custom-mode-enabled.home-active #home-layout > #home-salons-col,
  body.dc-home-custom-mode-enabled.home-active #home-layout > #home-right-col {
    display: none !important;
  }

  body.dc-home-embedded-open.home-active #home-layout {
    flex: 1 1 auto !important;
    width: auto !important;
    max-width: none !important;
    min-width: 0 !important;
    min-height: 0 !important;
    align-items: stretch !important;
    justify-content: center !important;
    gap: 0 !important;
    margin: 0 !important;
    padding: 14px !important;
    overflow: hidden !important;
    border-radius: 10px !important;
    background: #272729 !important;
    box-sizing: border-box !important;
  }

  .dc-desktop-home-surface {
    flex: 1 1 auto;
    width: min(1320px, 100%);
    max-width: 1320px;
    min-width: 0;
    min-height: 0;
    height: 100%;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    color: #fff;
    background: linear-gradient(145deg, rgba(25, 25, 32, .99), rgba(13, 13, 18, .99));
    border: 1px solid rgba(180, 125, 255, .68);
    border-radius: 18px;
    box-shadow: 0 20px 58px rgba(0, 0, 0, .48),
                0 0 24px rgba(0, 218, 222, .12),
                0 0 24px rgba(251, 0, 255, .11);
    box-sizing: border-box;
  }

  .dc-desktop-home-surface[hidden] {
    display: none !important;
  }


  .dc-desktop-home-window {
    position: fixed;
    left: 50%;
    top: 160px;
    bottom: 14px;
    z-index: 2147482500;
    width: min(1320px, calc(100vw - 48px));
    max-width: none;
    height: auto;
    min-height: 0;
    max-height: none;
    margin: 0;
    transform: translateX(-50%);
    box-shadow: 0 25px 80px rgba(0, 0, 0, .62),
                0 0 28px rgba(0, 218, 222, .15),
                0 0 28px rgba(251, 0, 255, .14);
  }

  /* La fenêtre n'ajoute volontairement ni voile ni flou. Les boutons de
     la top bar et les onglets restent accessibles autour du cadre. */
  body.dc-home-window-open {
    overflow: visible !important;
  }

  .dc-desktop-home-header {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 18px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, .11);
    background: rgba(255, 255, 255, .025);
    box-sizing: border-box;
  }

  .dc-desktop-home-heading {
    min-width: 0;
  }

  .dc-desktop-home-heading h2 {
    margin: 0;
    font-size: 25px;
    line-height: 1.15;
  }

  .dc-desktop-home-heading p {
    margin: 6px 0 0;
    color: rgba(255, 255, 255, .7);
    font-size: 14px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
  }

  .dc-desktop-home-grid {
    flex: 1 1 auto;
    min-width: 0;
    min-height: 0;
    display: grid;
    grid-template-columns: minmax(320px, .82fr) minmax(0, 1.45fr);
    gap: 16px;
    padding: 16px;
    box-sizing: border-box;
    overflow: hidden;
  }

  .dc-desktop-home-pane {
    min-width: 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, .1);
    border-radius: 14px;
    background: rgba(34, 34, 34, .72);
    box-sizing: border-box;
  }

  .dc-desktop-home-pane-header {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, .09);
    background: rgba(255, 255, 255, .025);
    box-sizing: border-box;
  }

  .dc-desktop-home-pane-header > div {
    min-width: 0;
  }

  .dc-desktop-home-pane-header h3 {
    margin: 0;
    color: #fff;
    font-size: 18px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
  }

  .dc-desktop-home-pane-header span {
    display: block;
    max-width: 100%;
    margin-top: 4px;
    color: rgba(255, 255, 255, .58);
    font-size: 12px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
  }

  .dc-desktop-home-search {
    flex: 0 0 auto;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 12px 14px 0;
    padding: 0 12px;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 10px;
    background: rgba(8, 8, 12, .72);
    box-sizing: border-box;
  }

  .dc-desktop-home-search > span {
    flex: 0 0 auto;
    color: rgba(255, 255, 255, .5);
    font-size: 20px;
  }

  .dc-desktop-home-search input {
    flex: 1 1 auto;
    width: 100%;
    min-width: 0;
    height: 42px;
    padding: 0;
    border: 0;
    outline: 0;
    color: #fff;
    background: transparent;
    font: inherit;
  }

  .dc-desktop-home-search:focus-within {
    border-color: rgba(0, 218, 222, .7);
    box-shadow: 0 0 0 2px rgba(0, 218, 222, .09);
  }

  .dc-desktop-home-user-search[hidden] {
    display: none !important;
  }

  .dc-desktop-home-salons-list-wrap {
    flex: 1 1 auto;
    min-width: 0;
    min-height: 0;
    margin: 12px 14px 14px;
    overflow-y: auto;
    overflow-x: hidden;
    border: 1px solid rgba(0, 0, 0, .55);
    border-radius: 0 0 12px 12px;
    background: rgba(0, 0, 0, .16);
    padding: 6px 8px;
    box-sizing: border-box;
  }

  body.dc-home-surface-open .dc-desktop-home-salons-list-wrap > #channel-list {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
    flex: 0 0 auto !important;
    box-sizing: border-box !important;
  }

  body.dc-home-surface-open #channel-list li.channel,
  body.dc-home-surface-open #channel-list li.create-channel-slot {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  body.dc-home-surface-open #channel-list li.channel {
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    min-height: 38px !important;
    padding: 8px 10px !important;
    margin: 0 0 10px 0 !important;
    border-radius: 13px !important;
    border: 1px solid var(--mk-pc-card-bd, rgba(79, 131, 255, .22)) !important;
    background: linear-gradient(180deg, rgba(255, 255, 255, .045), rgba(255, 255, 255, .025)) !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .03),
                0 4px 12px rgba(0, 0, 0, .14) !important;
    transition: border-color .12s ease,
                box-shadow .12s ease,
                background .12s ease !important;
    animation: none !important;
    background-size: auto !important;
  }

  body.dc-home-surface-open #channel-list li.channel:hover,
  body.dc-home-surface-open #channel-list li.channel.selected,
  body.dc-home-surface-open #channel-list li.channel.selected:hover {
    background: linear-gradient(180deg, rgba(255, 255, 255, .060), rgba(255, 255, 255, .032)) !important;
    border-color: rgba(79, 131, 255, .22) !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .035),
                0 8px 20px rgba(0, 0, 0, .18),
                0 0 0 1px rgba(79, 131, 255, .06) !important;
    color: #fff !important;
  }

  body.dc-home-surface-open #channel-list li.channel .channel-left {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    max-width: 100% !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  body.dc-home-surface-open #channel-list li.channel .user-count {
    flex: 0 0 28px !important;
    margin-left: auto !important;
    text-align: right !important;
    font-variant-numeric: tabular-nums;
    opacity: .9;
  }

  body.dc-home-surface-open #channel-list > li.channel.dc-home-search-hidden,
  body.dc-home-surface-open #channel-list > li.channel-group-title.dc-home-search-hidden,
  body.dc-home-surface-open #channel-list > li.create-channel-slot.dc-home-search-hidden {
    display: none !important;
  }

  body.dc-home-surface-open #channel-list li.channel-group-title {
    position: static !important;
    inset: auto !important;
    z-index: auto !important;
    margin: 10px 0 6px !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: none !important;
    box-shadow: none !important;
  }

  body.dc-home-surface-open #create-channel.in-channel-list {
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  body.dc-home-surface-open #create-channel.in-channel-list .create-channel-title {
    font-size: 16px !important;
  }

  body.dc-home-surface-open #create-channel.in-channel-list .create-channel-options {
    gap: 12px 16px !important;
    font-size: 15px !important;
    line-height: 1.3 !important;
  }

  body.dc-home-surface-open #create-channel.in-channel-list .create-opt {
    gap: 7px !important;
    font-size: 15px !important;
    font-weight: 600 !important;
  }

  body.dc-home-surface-open #create-channel.in-channel-list .create-opt > input[type="checkbox"] {
    width: 16px !important;
    height: 16px !important;
    flex: 0 0 16px !important;
    margin: 0 !important;
  }

  .dc-desktop-home-mount {
    flex: 1 1 auto;
    min-width: 0;
    min-height: 0;
    display: flex;
    overflow: hidden;
  }

  .dc-desktop-home-region-mount {
    padding: 12px;
    box-sizing: border-box;
  }

  body.dc-home-surface-open #home-right-col {
    flex: 1 1 auto !important;
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    min-height: 0 !important;
    height: 100% !important;
    display: flex !important;
    align-items: stretch !important;
    justify-content: stretch !important;
    overflow: hidden !important;
  }

  body.dc-home-surface-open #regionalList {
    flex: 1 1 auto !important;
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    min-height: 0 !important;
    height: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    justify-content: flex-start !important;
    position: static !important;
    inset: auto !important;
    padding: 0 !important;
    overflow: hidden !important;
    transform: none !important;
    box-sizing: border-box !important;
  }

  body.dc-home-surface-open #regionalList > .dc-modal-region-shell {
    flex: 1 1 auto !important;
    width: 100% !important;
    min-width: 0 !important;
    min-height: 0 !important;
    height: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    justify-content: flex-start !important;
    overflow: hidden !important;
  }


  /* Les commandes de la barre région doivent rester au-dessus du corps de
     liste et recevoir les clics dans l'Accueil intégré hors salon. */
  body.dc-home-embedded-open #regionalList,
  body.dc-home-embedded-open #regionalList > .dc-modal-region-shell,
  body.dc-home-embedded-open #regionalList .coco-acc-top,
  body.dc-home-embedded-open #regionalList .coco-acc-right,
  body.dc-home-embedded-open #regionalList .coco-acc-filters,
  body.dc-home-embedded-open #regionalList .coco-filter-toggle,
  body.dc-home-embedded-open #regionalList .coco-filter-chip,
  body.dc-home-embedded-open #regionalList #homeStaffViewBtn {
    pointer-events: auto !important;
  }

  body.dc-home-embedded-open #regionalList .coco-acc-top,
  body.dc-home-embedded-open #regionalList .coco-acc-filters {
    position: relative !important;
    z-index: 20 !important;
  }

  body.dc-home-embedded-open #regionalList .coco-acc-body {
    position: relative !important;
    z-index: 1 !important;
  }

  body.dc-home-surface-open #regionalList .coco-acc-top,
  body.dc-home-surface-open #regionalList .coco-acc-filters,
  body.dc-home-surface-open #regionalList .coco-acc-head {
    flex: 0 0 auto !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    position: static !important;
    inset: auto !important;
    transform: none !important;
    box-sizing: border-box !important;
  }

  body.dc-home-surface-open #regionalList .coco-acc-top {
    order: 1 !important;
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 8px 12px !important;
    min-height: 42px !important;
    padding: 7px 10px !important;
  }

  body.dc-home-surface-open #regionalList .coco-acc-left {
    flex: 1 1 180px !important;
    min-width: 0 !important;
    max-width: 100% !important;
    margin: 0 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  body.dc-home-surface-open #regionalList .coco-acc-right {
    flex: 0 1 auto !important;
    min-width: 0 !important;
    max-width: 100% !important;
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 8px !important;
    margin: 0 0 0 auto !important;
    white-space: normal !important;
  }

  body.dc-home-surface-open #regionalList .coco-acc-filters {
    order: 2 !important;
    overflow: hidden !important;
  }

  body.dc-home-surface-open #regionalList .coco-acc-head {
    order: 3 !important;
    overflow: hidden !important;
  }

  body.dc-home-surface-open #regionalList .coco-acc-body {
    order: 4 !important;
    flex: 1 1 auto !important;
    width: 100% !important;
    min-width: 0 !important;
    min-height: 0 !important;
    max-width: 100% !important;
    position: static !important;
    inset: auto !important;
    transform: none !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    box-sizing: border-box !important;
  }

  body.dc-home-surface-open #regionalList.home-region-cards-mode {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    transform: none !important;
  }

  body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  body.dc-home-surface-open #regionalList .coco-acc-top,
  body.dc-home-surface-open #regionalList .coco-acc-filters,
  body.dc-home-surface-open #regionalList .coco-acc-head,
  body.dc-home-surface-open #regionalList .coco-acc-body,
  body.dc-home-surface-open #regionalList .reg-title,
  body.dc-home-surface-open #regionalList .reg-group,
  body.dc-home-surface-open #regionalList .reg-empty,
  body.dc-home-surface-open #regionalList .reg-list-wrap,
  body.dc-home-surface-open #regionalList .reg-card-grid,
  body.dc-home-surface-open #regionalList .reg-card {
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  body.dc-home-surface-open #regionalList .reg-title,
  body.dc-home-surface-open #regionalList .reg-group,
  body.dc-home-surface-open #regionalList .reg-empty {
    width: 100% !important;
    overflow: hidden !important;
    white-space: nowrap !important;
    text-overflow: ellipsis !important;
  }

  body.dc-home-surface-open #regionalList .reg-card-grid {
    width: 100% !important;
    overflow-x: hidden !important;
  }

  body.dc-home-surface-open #regionalList .reg-card {
    width: 100% !important;
    overflow: hidden !important;
  }

  body.dc-home-surface-open #regionalList .reg-card-main,
  body.dc-home-surface-open #regionalList .reg-card-topline,
  body.dc-home-surface-open #regionalList .reg-card-meta,
  body.dc-home-surface-open #regionalList .reg-card-pseudo,
  body.dc-home-surface-open #regionalList .reg-card-pseudo-text,
  body.dc-home-surface-open #regionalList .reg-card-city {
    min-width: 0 !important;
    max-width: 100% !important;
  }

  body.dc-home-surface-open #regionalList .reg-card-pseudo-text,
  body.dc-home-surface-open #regionalList .reg-card-city {
    overflow: hidden !important;
    white-space: nowrap !important;
    text-overflow: ellipsis !important;
  }

  body.dc-home-surface-open #regionalList .coco-filter-toggle,
  body.dc-home-surface-open #regionalList .coco-filter-chip {
    max-width: 100% !important;
    flex: 0 1 auto !important;
    box-sizing: border-box !important;
  }

  body.dc-home-surface-open #regionalList .coco-filter-toggle-value {
    min-width: 0 !important;
    overflow: hidden !important;
    white-space: nowrap !important;
    text-overflow: ellipsis !important;
  }

  @media (max-width: 1120px) {
    .dc-desktop-home-grid {
      grid-template-columns: minmax(280px, .82fr) minmax(0, 1.18fr);
      gap: 12px;
      padding: 12px;
    }

    .dc-desktop-home-header {
      padding: 14px 16px;
    }

    body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card-grid {
      grid-template-columns: minmax(0, 1fr) !important;
    }
  }

  @media (max-width: 900px) {
    body.dc-home-embedded-open.home-active #home-layout {
      padding: 8px !important;
    }

    .dc-desktop-home-grid {
      grid-template-columns: minmax(250px, .78fr) minmax(0, 1.22fr);
      gap: 8px;
      padding: 8px;
    }

    .dc-desktop-home-pane-header {
      padding: 11px 12px;
    }

    .dc-desktop-home-search {
      margin: 9px 10px 0;
    }

    .dc-desktop-home-salons-list-wrap {
      margin: 9px 10px 10px;
    }

    .dc-desktop-home-region-mount {
      padding: 9px;
    }
  }
}

@media (max-width: 768px) {
  /* Évite l'affichage bref de l'ancien Accueil pendant le chargement du
     réglage. Les deux colonnes sont ensuite replacées dans les nouveaux cadres. */
  html.dc-preload-custom-home body.home-active #home-layout > #home-salons-col,
  html.dc-preload-custom-home body.home-active #home-layout > #home-right-col,
  body.dc-home-custom-mode-enabled.home-active #home-layout > #home-salons-col,
  body.dc-home-custom-mode-enabled.home-active #home-layout > #home-right-col {
    display: none !important;
  }

  /* Sur mobile, les deux modes personnalisés de l'Accueil restent intégrés
     et n'affichent jamais la barre « Votre message » sous les cadres. */
  body.dc-home-custom-mode-enabled.home-active #message-input-container {
    display: none !important;
  }

  /* La zone principale récupère la hauteur libérée par la barre masquée.
     Les onglets mobiles restent toujours réservés en bas. */
  body.dc-home-custom-mode-enabled.home-active #chat-wrapper,
  body.dc-home-custom-mode-enabled.home-active main,
  body.dc-home-custom-mode-enabled.home-active #chat-wrapper > main,
  body.dc-home-custom-mode-enabled.home-active #chat-wrapper main {
    bottom: calc(var(--mk-tabs-h, 48px) + var(--mk-safe-b, env(safe-area-inset-bottom, 0px))) !important;
  }

  body.dc-home-embedded-open.home-active #home-layout {
    flex: 1 1 auto !important;
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    min-height: 0 !important;
    height: 100% !important;
    align-items: stretch !important;
    justify-content: stretch !important;
    gap: 0 !important;
    margin: 0 !important;
    padding: 6px !important;
    overflow: hidden !important;
    border-radius: 10px !important;
    background: #272729 !important;
    box-sizing: border-box !important;
  }

  .dc-desktop-home-surface {
    flex: 1 1 auto;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    min-height: 0;
    height: 100%;
    margin: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    color: #fff;
    background: linear-gradient(145deg, rgba(25, 25, 32, .99), rgba(13, 13, 18, .99));
    border: 1px solid rgba(180, 125, 255, .68);
    border-radius: 14px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, .46),
                0 0 18px rgba(0, 218, 222, .10),
                0 0 18px rgba(251, 0, 255, .09);
    box-sizing: border-box;
  }

  .dc-desktop-home-surface[hidden] {
    display: none !important;
  }

  /* Sécurité responsive : même si la largeur change pendant qu'une fenêtre
     PC est ouverte, elle redevient immédiatement un cadre intégré sur mobile. */
  .dc-desktop-home-window,
  .dc-desktop-home-embedded {
    position: static !important;
    inset: auto !important;
    z-index: auto !important;
    width: 100% !important;
    max-width: 100% !important;
    height: 100% !important;
    max-height: none !important;
    margin: 0 !important;
    transform: none !important;
  }

  .dc-desktop-home-close {
    display: none !important;
  }

  .dc-desktop-home-header {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 9px 11px;
    border-bottom: 1px solid rgba(255, 255, 255, .11);
    background: rgba(255, 255, 255, .025);
    box-sizing: border-box;
  }

  .dc-desktop-home-heading {
    min-width: 0;
  }

  .dc-desktop-home-heading h2 {
    margin: 0;
    font-size: 20px;
    line-height: 1.1;
  }

  .dc-desktop-home-heading p {
    margin: 3px 0 0;
    color: rgba(255, 255, 255, .68);
    font-size: 11px;
    line-height: 1.2;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
  }

  .dc-desktop-home-grid {
    flex: 1 1 auto;
    min-width: 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 0;
    padding: 7px;
    box-sizing: border-box;
    overflow: hidden;
  }

  .dc-desktop-home-pane {
    flex: 1 1 auto;
    width: 100%;
    min-width: 0;
    min-height: 0;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, .1);
    border-radius: 12px;
    background: rgba(34, 34, 34, .72);
    box-sizing: border-box;
  }

  /* Les onglets mobiles « Salons » et « Connectés » continuent de choisir
     le cadre affiché. Les deux cadres utilisent désormais le même rendu que PC. */
  .dc-desktop-home-salons-pane {
    display: flex;
  }

  .dc-desktop-home-region-pane {
    display: none;
  }

  body.show-region .dc-desktop-home-salons-pane {
    display: none !important;
  }

  body.show-region .dc-desktop-home-region-pane {
    display: flex !important;
  }

  .dc-desktop-home-pane-header {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 10px 11px;
    border-bottom: 1px solid rgba(255, 255, 255, .09);
    background: rgba(255, 255, 255, .025);
    box-sizing: border-box;
  }

  .dc-desktop-home-pane-header > div {
    min-width: 0;
  }

  .dc-desktop-home-pane-header h3 {
    margin: 0;
    color: #fff;
    font-size: 17px;
    line-height: 1.15;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
  }

  .dc-desktop-home-pane-header span {
    display: block;
    max-width: 100%;
    margin-top: 3px;
    color: rgba(255, 255, 255, .58);
    font-size: 11px;
    line-height: 1.15;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
  }

  .dc-desktop-home-search {
    flex: 0 0 auto;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 7px;
    margin: 8px 9px 0;
    padding: 0 10px;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 10px;
    background: rgba(8, 8, 12, .72);
    box-sizing: border-box;
  }

  .dc-desktop-home-search > span {
    flex: 0 0 auto;
    color: rgba(255, 255, 255, .5);
    font-size: 19px;
  }

  .dc-desktop-home-search input {
    flex: 1 1 auto;
    width: 100%;
    min-width: 0;
    height: 40px;
    padding: 0;
    border: 0;
    outline: 0;
    color: #fff;
    background: transparent;
    font: inherit;
    font-size: 15px;
  }

  .dc-desktop-home-search:focus-within {
    border-color: rgba(0, 218, 222, .7);
    box-shadow: 0 0 0 2px rgba(0, 218, 222, .09);
  }

  .dc-desktop-home-user-search[hidden] {
    display: none !important;
  }

  .dc-desktop-home-salons-list-wrap {
    flex: 1 1 auto;
    min-width: 0;
    min-height: 0;
    margin: 8px 9px 9px;
    overflow-y: auto;
    overflow-x: hidden;
    border: 1px solid rgba(0, 0, 0, .55);
    border-radius: 0 0 11px 11px;
    background: rgba(0, 0, 0, .16);
    padding: 6px 7px;
    box-sizing: border-box;
    -webkit-overflow-scrolling: touch;
  }

  body.dc-home-surface-open .dc-desktop-home-salons-list-wrap > #channel-list {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
    flex: 0 0 auto !important;
    box-sizing: border-box !important;
  }

  body.dc-home-surface-open #channel-list li.channel,
  body.dc-home-surface-open #channel-list li.create-channel-slot {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  body.dc-home-surface-open #channel-list li.channel .channel-left {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    max-width: 100% !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  body.dc-home-surface-open #channel-list li.channel .user-count {
    flex: 0 0 28px !important;
    margin-left: auto !important;
    text-align: right !important;
    font-variant-numeric: tabular-nums;
    opacity: .9;
  }

  body.dc-home-surface-open #channel-list > li.channel.dc-home-search-hidden,
  body.dc-home-surface-open #channel-list > li.channel-group-title.dc-home-search-hidden,
  body.dc-home-surface-open #channel-list > li.create-channel-slot.dc-home-search-hidden {
    display: none !important;
  }

  body.dc-home-surface-open #channel-list li.channel-group-title {
    position: static !important;
    inset: auto !important;
    z-index: auto !important;
    margin: 10px 0 6px !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: none !important;
    box-shadow: none !important;
  }

  /* Espace mobile identique au PC entre le dernier salon et la catégorie suivante.
     Règle plus spécifique pour ne pas être écrasée par le margin mobile générique ci-dessus. */
  body.dc-home-surface-open #channel-list li.channel + li.channel-group-title,
  body.dc-home-surface-open #channel-list li.channel + li.create-channel-slot + li.channel-group-title {
    margin-top: 25px !important;
  }

  body.dc-home-surface-open #create-channel.in-channel-list {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  body.dc-home-surface-open #create-channel.in-channel-list .create-channel-title {
    font-size: 16px !important;
  }

  body.dc-home-surface-open #create-channel.in-channel-list .create-channel-options {
    gap: 10px 13px !important;
    font-size: 15px !important;
    line-height: 1.3 !important;
  }

  body.dc-home-surface-open #create-channel.in-channel-list .create-opt {
    gap: 7px !important;
    font-size: 15px !important;
    font-weight: 600 !important;
  }

  body.dc-home-surface-open #create-channel.in-channel-list .create-opt > input[type="checkbox"] {
    width: 16px !important;
    height: 16px !important;
    flex: 0 0 16px !important;
    margin: 0 !important;
  }

  .dc-desktop-home-mount {
    flex: 1 1 auto;
    min-width: 0;
    min-height: 0;
    display: flex;
    overflow: hidden;
  }

  .dc-desktop-home-region-mount {
    padding: 8px;
    box-sizing: border-box;
  }

  body.dc-home-surface-open #home-right-col {
    flex: 1 1 auto !important;
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    min-height: 0 !important;
    height: 100% !important;
    display: flex !important;
    align-items: stretch !important;
    justify-content: stretch !important;
    overflow: hidden !important;
  }

  body.dc-home-surface-open #regionalList {
    flex: 1 1 auto !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    min-height: 0 !important;
    height: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    justify-content: flex-start !important;
    position: static !important;
    inset: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
    transform: none !important;
    box-sizing: border-box !important;
  }

  body.dc-home-surface-open #regionalList > .dc-modal-region-shell {
    flex: 1 1 auto !important;
    width: 100% !important;
    min-width: 0 !important;
    min-height: 0 !important;
    height: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    justify-content: flex-start !important;
    overflow: hidden !important;
  }

  body.dc-home-embedded-open #regionalList,
  body.dc-home-embedded-open #regionalList > .dc-modal-region-shell,
  body.dc-home-embedded-open #regionalList .coco-acc-top,
  body.dc-home-embedded-open #regionalList .coco-acc-right,
  body.dc-home-embedded-open #regionalList .coco-acc-filters,
  body.dc-home-embedded-open #regionalList .coco-filter-toggle,
  body.dc-home-embedded-open #regionalList .coco-filter-chip,
  body.dc-home-embedded-open #regionalList #homeStaffViewBtn {
    pointer-events: auto !important;
  }

  body.dc-home-surface-open #regionalList .coco-acc-top,
  body.dc-home-surface-open #regionalList .coco-acc-filters,
  body.dc-home-surface-open #regionalList .coco-acc-head {
    flex: 0 0 auto !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    position: static !important;
    inset: auto !important;
    transform: none !important;
    box-sizing: border-box !important;
  }

  body.dc-home-surface-open #regionalList .coco-acc-top {
    order: 1 !important;
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 6px 8px !important;
    min-height: 38px !important;
    padding: 6px 8px !important;
  }

  body.dc-home-surface-open #regionalList .coco-acc-left {
    flex: 1 1 145px !important;
    min-width: 0 !important;
    max-width: 100% !important;
    margin: 0 !important;
    font-size: 14px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  body.dc-home-surface-open #regionalList .coco-acc-right {
    flex: 0 1 auto !important;
    min-width: 0 !important;
    max-width: 100% !important;
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 6px !important;
    margin: 0 0 0 auto !important;
    font-size: 11px !important;
    white-space: normal !important;
  }

  body.dc-home-surface-open #regionalList .coco-acc-filters {
    order: 2 !important;
    gap: 6px !important;
    padding: 6px 8px !important;
    overflow: hidden !important;
  }

  body.dc-home-surface-open #regionalList .coco-acc-head {
    order: 3 !important;
    overflow: hidden !important;
  }

  body.dc-home-surface-open #regionalList .coco-acc-body {
    order: 4 !important;
    flex: 1 1 auto !important;
    width: 100% !important;
    min-width: 0 !important;
    min-height: 0 !important;
    max-width: 100% !important;
    position: static !important;
    inset: auto !important;
    transform: none !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
    box-sizing: border-box !important;
  }

  body.dc-home-surface-open #regionalList.home-region-cards-mode,
  body.dc-home-surface-open #regionalList .coco-acc-top,
  body.dc-home-surface-open #regionalList .coco-acc-filters,
  body.dc-home-surface-open #regionalList .coco-acc-head,
  body.dc-home-surface-open #regionalList .coco-acc-body,
  body.dc-home-surface-open #regionalList .reg-title,
  body.dc-home-surface-open #regionalList .reg-group,
  body.dc-home-surface-open #regionalList .reg-empty,
  body.dc-home-surface-open #regionalList .reg-list-wrap,
  body.dc-home-surface-open #regionalList .reg-card-grid,
  body.dc-home-surface-open #regionalList .reg-card {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    transform: none !important;
  }

  body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card-grid {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 8px !important;
    padding: 8px !important;
    overflow-x: hidden !important;
  }

  body.dc-home-surface-open #regionalList .reg-card {
    overflow: hidden !important;
  }

  body.dc-home-surface-open #regionalList .reg-card-main,
  body.dc-home-surface-open #regionalList .reg-card-topline,
  body.dc-home-surface-open #regionalList .reg-card-meta,
  body.dc-home-surface-open #regionalList .reg-card-pseudo,
  body.dc-home-surface-open #regionalList .reg-card-pseudo-text,
  body.dc-home-surface-open #regionalList .reg-card-city {
    min-width: 0 !important;
    max-width: 100% !important;
  }

  body.dc-home-surface-open #regionalList .reg-card-pseudo-text,
  body.dc-home-surface-open #regionalList .reg-card-city,
  body.dc-home-surface-open #regionalList .reg-title,
  body.dc-home-surface-open #regionalList .reg-group,
  body.dc-home-surface-open #regionalList .reg-empty {
    overflow: hidden !important;
    white-space: nowrap !important;
    text-overflow: ellipsis !important;
  }

  body.dc-home-surface-open #regionalList .coco-filter-toggle,
  body.dc-home-surface-open #regionalList .coco-filter-chip {
    max-width: 100% !important;
    flex: 0 1 auto !important;
    box-sizing: border-box !important;
    font-size: 11px !important;
  }

  body.dc-home-surface-open #regionalList .coco-filter-toggle-value {
    min-width: 0 !important;
    overflow: hidden !important;
    white-space: nowrap !important;
    text-overflow: ellipsis !important;
  }
}


/* DIRECTCHAT_REGION_SCROLL_FINAL_20260806 */
/* Le corps de la liste région devient l'unique zone scrollable, avec une
   hauteur réellement contrainte dans toute la chaîne flex sur PC et mobile. */
body.dc-home-surface-open .dc-desktop-home-region-pane,
body.dc-home-surface-open .dc-desktop-home-region-mount,
body.dc-home-surface-open #home-right-col,
body.dc-home-surface-open #regionalList,
body.dc-home-surface-open #regionalList > .dc-modal-region-shell {
  min-height: 0 !important;
  max-height: 100% !important;
}

body.dc-home-surface-open #regionalList > .dc-modal-region-shell {
  flex: 1 1 0 !important;
  height: 100% !important;
  overflow: hidden !important;
}

body.dc-home-surface-open #regionalList .coco-acc-body {
  flex: 1 1 0 !important;
  height: 0 !important;
  min-height: 0 !important;
  max-height: none !important;
  overflow-x: hidden !important;
  overflow-y: scroll !important;
  overscroll-behavior-y: contain !important;
  -webkit-overflow-scrolling: touch;
  scrollbar-gutter: stable;
  pointer-events: auto !important;
  position: relative !important;
}

@media (max-width: 768px) {
  body.dc-home-surface-open .dc-desktop-home-region-mount,
  body.dc-home-surface-open #regionalList .coco-acc-body {
    touch-action: none !important;
  }
}

/* DIRECTCHAT_MOBILE_HOME_COMPACT_SEARCH_HEADER_20260806
   Sur mobile uniquement, les recherches remplacent les doubles titres de
   l'Accueil afin de conserver davantage de hauteur pour les listes. */
@media (max-width: 768px) {
  body.dc-home-surface-open .dc-desktop-home-header,
  body.dc-home-surface-open .dc-desktop-home-pane-header {
    display: none !important;
  }

  body.dc-home-surface-open .dc-desktop-home-grid {
    padding: 7px !important;
  }

  body.dc-home-surface-open .dc-desktop-home-search {
    margin: 8px 9px 0 !important;
  }

  body.dc-home-surface-open .dc-desktop-home-salons-list-wrap {
    margin-top: 8px !important;
  }

  body.dc-home-surface-open .dc-desktop-home-region-mount {
    padding-top: 8px !important;
  }

  body.dc-home-surface-open .dc-desktop-home-user-search:not([hidden]) + .dc-desktop-home-region-mount {
    padding-top: 8px !important;
  }
}

/* DIRECTCHAT_PC_HOME_COMPACT_SEARCH_HEADER_20260806
   Sur PC, les champs de recherche remplacent les titres des deux cadres.
   La recherche pseudo conserve les permissions déjà gérées par le JavaScript. */
@media (min-width: 769px) {
  body.dc-home-surface-open .dc-desktop-home-pane-header {
    display: none !important;
  }
}

/* DIRECTCHAT_PC_HOME_FULL_WIDTH_20260808
   Hors salon sur PC, l'Accueil intégré utilise toute la largeur disponible.
   La fenêtre flottante ouverte au-dessus d'un salon / MP conserve sa largeur actuelle. */
@media (min-width: 769px) {
  body.dc-home-embedded-open.home-active .dc-desktop-home-surface.dc-desktop-home-embedded {
    width: 100% !important;
    max-width: none !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }
}


/* DIRECTCHAT_PC_HOME_COMPACT_COLUMNS_20260808 */
/* Sur les grands écrans, la liste des salons garde une largeur cohérente
   avec la longueur maximale des titres. La liste région récupère le reste. */
@media (min-width: 1200px) {
  body.dc-home-embedded-open.home-active #home-layout {
    padding: 10px !important;
  }

  body.dc-home-embedded-open.home-active .dc-desktop-home-grid {
    grid-template-columns: minmax(360px, 440px) minmax(0, 1fr) !important;
    gap: 12px !important;
    padding: 12px !important;
  }
}

/* =========================================================
   ACCUEIL INTÉGRÉ / FENÊTRE — création de salon repliable
   Le formulaire réel est déplacé dans ce menu : aucune logique du formulaire
   n'est dupliquée et le mode Accueil classique reste inchangé.
   ========================================================= */
body.dc-home-surface-open .dc-desktop-home-search-row{
  flex:0 0 auto;
  display:flex;
  align-items:stretch;
  gap:8px;
  min-width:0;
  margin:12px 14px 0;
  box-sizing:border-box;
}
body.dc-home-surface-open .dc-desktop-home-search-row > .dc-desktop-home-search{
  flex:1 1 auto;
  width:auto;
  min-width:0;
  margin:0 !important;
}
body.dc-home-surface-open .dc-home-create-toggle{
  flex:0 0 42px;
  width:42px;
  min-width:42px;
  height:42px;
  margin:0;
  padding:0;
  display:flex;
  align-items:center;
  justify-content:center;
  border:1px solid rgba(0,218,222,.44);
  border-radius:10px;
  background:linear-gradient(180deg,rgba(255,255,255,.07),rgba(255,255,255,.035));
  box-shadow:inset 0 1px 0 rgba(255,255,255,.04),0 3px 10px rgba(0,0,0,.18);
  color:#fff;
  font:700 25px/1 Arial,sans-serif;
  cursor:pointer;
  box-sizing:border-box;
  -webkit-tap-highlight-color:transparent;
}
body.dc-home-surface-open .dc-home-create-toggle:hover,
body.dc-home-surface-open .dc-home-create-toggle.active{
  border-color:rgba(251,0,255,.72);
  box-shadow:0 0 0 1px rgba(0,218,222,.10),0 0 12px rgba(251,0,255,.18);
}
body.dc-home-surface-open .dc-home-create-toggle[hidden]{
  display:none !important;
}
body.dc-home-surface-open .dc-home-create-menu[hidden]{
  display:none !important;
}
body.dc-home-surface-open .dc-home-create-menu{
  flex:0 0 auto;
  min-width:0;
  margin:8px 14px 0;
  padding:10px;
  border:1px solid rgba(155,74,255,.48);
  border-radius:12px;
  background:rgba(18,18,22,.96);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.035),0 8px 18px rgba(0,0,0,.22);
  box-sizing:border-box;
  z-index:4;
}
/* Dans les modes Accueil personnalisé, le formulaire n'occupe plus une carte
   dans la liste : il vit uniquement dans le menu + au-dessus. */
body.dc-home-surface-open #channel-list > li.create-channel-slot{
  display:none !important;
}
body.dc-home-surface-open .dc-home-create-menu #create-channel.in-channel-list,
body.dc-home-surface-open .dc-home-create-menu #create-channel.dc-home-create-panel{
  position:static !important;
  inset:auto !important;
  width:100% !important;
  max-width:100% !important;
  margin:0 !important;
  padding:0 !important;
  border:0 !important;
  background:transparent !important;
  box-sizing:border-box !important;
}

/* =========================================================
   LISTE RÉGION MOBILE — pseudo/humeur stables sur une seule ligne
   Règles finales après les styles de la fenêtre Accueil.
   ========================================================= */
@media (max-width:768px){
  body.dc-home-surface-open .dc-desktop-home-search-row{
    gap:7px;
    margin:8px 9px 0;
  }
  body.dc-home-surface-open .dc-desktop-home-search-row > .dc-desktop-home-search{
    margin:0 !important;
  }
  body.dc-home-surface-open .dc-home-create-toggle{
    flex-basis:40px;
    width:40px;
    min-width:40px;
    height:40px;
    border-radius:9px;
    font-size:23px;
  }
  body.dc-home-surface-open .dc-home-create-menu{
    margin:7px 9px 0;
    padding:9px;
  }

  body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card .mk-user-meta{
    display:flex !important;
    flex-direction:row !important;
    flex-wrap:nowrap !important;
    align-items:center !important;
    gap:4px !important;
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    overflow:hidden !important;
  }
  body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card .badge-wrapper{
    flex:0 0 auto !important;
    width:auto !important;
    min-width:0 !important;
    max-width:none !important;
  }
  body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card .mk-user-city,
  body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card .reg-card-city{
    display:block !important;
    flex:1 1 0 !important;
    flex-basis:0 !important;
    width:auto !important;
    min-width:0 !important;
    max-width:none !important;
    height:18px !important;
    max-height:18px !important;
    line-height:18px !important;
    overflow:hidden !important;
    white-space:nowrap !important;
    text-overflow:ellipsis !important;
    overflow-wrap:normal !important;
    word-break:normal !important;
    transform:none !important;
  }
  body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card .username-span,
  body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card .mk-username-text{
    transform:none !important;
  }
}


/* =========================================================
   REGION MOBILE FINAL v20 — ville/humeur toujours à côté de l'âge
   Priorité volontairement supérieure aux anciens blocs home-active/show-region.
   ========================================================= */
@media (max-width:768px){
  body.home-active.show-region #regionalList.home-region-cards-mode .reg-card .mk-user-maintext,
  body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card .mk-user-maintext{
    min-width:0 !important;
    max-width:100% !important;
    overflow:hidden !important;
  }

  body.home-active.show-region #regionalList.home-region-cards-mode .reg-card .mk-user-meta,
  body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card .mk-user-meta{
    display:flex !important;
    flex-direction:row !important;
    flex-wrap:nowrap !important;
    align-items:center !important;
    align-content:center !important;
    gap:4px !important;
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    min-height:18px !important;
    height:18px !important;
    overflow:hidden !important;
  }

  body.home-active.show-region #regionalList.home-region-cards-mode .reg-card .mk-user-meta > .badge-wrapper,
  body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card .mk-user-meta > .badge-wrapper{
    display:inline-flex !important;
    flex:0 0 auto !important;
    align-items:center !important;
    align-self:center !important;
    width:auto !important;
    min-width:0 !important;
    max-width:none !important;
    margin:0 !important;
  }

  body.home-active.show-region #regionalList.home-region-cards-mode .reg-card .mk-user-city,
  body.home-active.show-region #regionalList.home-region-cards-mode .reg-card .reg-card-city,
  body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card .mk-user-city,
  body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card .reg-card-city{
    display:block !important;
    flex:1 1 0 !important;
    flex-basis:0 !important;
    width:0 !important;
    min-width:0 !important;
    max-width:100% !important;
    height:18px !important;
    min-height:18px !important;
    max-height:18px !important;
    margin:0 !important;
    padding:0 !important;
    line-height:18px !important;
    white-space:nowrap !important;
    overflow:hidden !important;
    text-overflow:ellipsis !important;
    overflow-wrap:normal !important;
    word-break:normal !important;
    transform:none !important;
    vertical-align:middle !important;
  }

  body.home-active.show-region #regionalList.home-region-cards-mode .reg-card .mk-user-topline,
  body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card .mk-user-topline{
    min-width:0 !important;
    max-width:100% !important;
    min-height:18px !important;
    overflow:hidden !important;
  }

  body.home-active.show-region #regionalList.home-region-cards-mode .reg-card .username-span,
  body.home-active.show-region #regionalList.home-region-cards-mode .reg-card .mk-username-text,
  body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card .username-span,
  body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card .mk-username-text{
    min-width:0 !important;
    max-width:100% !important;
    overflow:hidden !important;
    white-space:nowrap !important;
    text-overflow:ellipsis !important;
    overflow-wrap:normal !important;
    word-break:normal !important;
    transform:none !important;
  }
}


/* REGION MOBILE — humeur complète dans Accueil intégré / fenêtre en salon */
@media (max-width:768px){
  body.dc-home-surface-open #regionalList.home-region-cards-mode .reg-card .mk-user-city[data-mood-active="1"],
  body.home-active.show-region #regionalList.home-region-cards-mode .reg-card .mk-user-city[data-mood-active="1"]{
    flex:1 1 0 !important;
    width:0 !important;
    min-width:0 !important;
    max-width:100% !important;
    white-space:nowrap !important;
    overflow:hidden !important;
    text-overflow:clip !important;
    overflow-wrap:normal !important;
    word-break:normal !important;
    transform:none !important;
    transform-origin:left center !important;
  }
}

/* =========================================================
   ACCUEIL PC EN SALON / MP — affichage Par défaut / Compact
   - Par défaut : conserve la fenêtre à deux colonnes existante.
   - Compact : une seule colonne de la largeur de la liste Salons,
     avec onglets Salons / Région et les contrôles région adaptés.
   - Aucun effet sur l'Accueil intégré ni sur le mobile.
   ========================================================= */
@media (min-width:769px){
  .dc-desktop-home-header-actions{
    flex:0 0 auto;
    display:flex;
    align-items:center;
    justify-content:flex-end;
    gap:10px;
    min-width:0;
  }

  .dc-home-modal-layout-select{
    flex:0 0 auto;
    display:flex;
    align-items:center;
    gap:8px;
    min-width:0;
    color:rgba(255,255,255,.72);
    font-size:12px;
    white-space:nowrap;
  }

  .dc-home-modal-layout-select[hidden]{
    display:none !important;
  }

  .dc-home-modal-layout-select select{
    height:36px;
    min-width:118px;
    padding:0 30px 0 10px;
    border:1px solid rgba(255,255,255,.14);
    border-radius:9px;
    outline:0;
    color:#fff;
    background:#1c1c22;
    font:inherit;
    cursor:pointer;
    box-sizing:border-box;
  }

  .dc-home-modal-layout-select select:hover,
  .dc-home-modal-layout-select select:focus-visible{
    border-color:rgba(0,218,222,.65);
    box-shadow:0 0 0 2px rgba(0,218,222,.08);
  }

  .dc-home-modal-layout-select select option{
    color:#fff;
    background:#1c1c22;
  }

  .dc-home-compact-tabs{
    grid-column:1 / -1;
    flex:0 0 auto;
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:8px;
    min-width:0;
    margin:0;
    padding:0;
  }

  .dc-home-compact-tabs[hidden]{
    display:none !important;
  }

  .dc-home-compact-tab{
    min-width:0;
    height:40px;
    padding:0 12px;
    border:1px solid rgba(255,255,255,.12);
    border-radius:10px;
    color:rgba(255,255,255,.78);
    background:rgba(255,255,255,.045);
    font:700 14px/1 Arial,sans-serif;
    cursor:pointer;
    box-sizing:border-box;
  }

  .dc-home-compact-tab:hover,
  .dc-home-compact-tab:focus-visible{
    outline:0;
    border-color:rgba(0,218,222,.55);
    color:#fff;
  }

  .dc-home-compact-tab.active{
    color:#fff;
    border-color:rgba(180,125,255,.72);
    background:linear-gradient(180deg,rgba(0,218,222,.12),rgba(251,0,255,.09));
    box-shadow:inset 0 1px 0 rgba(255,255,255,.045),0 0 12px rgba(0,218,222,.08);
  }

  .dc-desktop-home-window.dc-home-modal-compact{
    width:min(470px,calc(100vw - 48px)) !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact .dc-desktop-home-header{
    gap:12px;
    padding:14px 14px;
  }

  .dc-desktop-home-window.dc-home-modal-compact .dc-desktop-home-heading h2{
    font-size:22px;
  }

  .dc-desktop-home-window.dc-home-modal-compact .dc-desktop-home-heading{
    flex:1 1 auto;
    min-width:0;
  }

  .dc-desktop-home-window.dc-home-modal-compact .dc-desktop-home-heading p{
    max-width:none;
    margin-top:4px;
    font-size:12px;
    line-height:1.3;
    white-space:normal;
    overflow:visible;
    text-overflow:clip;
  }

  .dc-desktop-home-window.dc-home-modal-compact .dc-home-modal-layout-select > span{
    display:none;
  }

  .dc-desktop-home-window.dc-home-modal-compact .dc-home-modal-layout-select select{
    min-width:112px;
  }

  .dc-desktop-home-window.dc-home-modal-compact .dc-desktop-home-grid,
  body.dc-home-window-open .dc-desktop-home-window.dc-home-modal-compact .dc-desktop-home-grid{
    display:grid !important;
    grid-template-columns:minmax(0,1fr) !important;
    grid-template-rows:auto minmax(0,1fr) !important;
    gap:10px !important;
    padding:10px !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact .dc-desktop-home-pane{
    grid-column:1 !important;
    min-width:0 !important;
    width:100% !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact .dc-desktop-home-pane[hidden]{
    display:none !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact .dc-desktop-home-pane-header{
    display:none !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact .dc-desktop-home-search-row{
    margin:10px 10px 0 !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact .dc-desktop-home-user-search{
    margin:10px 10px 0 !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact .dc-desktop-home-salons-list-wrap{
    margin:10px !important;
    padding:6px 8px !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact .dc-home-create-menu{
    margin:8px 10px 0 !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact .dc-desktop-home-region-mount{
    padding:8px 10px 10px !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact #regionalList .coco-acc-top{
    display:flex !important;
    flex-direction:column !important;
    flex-wrap:nowrap !important;
    align-items:stretch !important;
    justify-content:flex-start !important;
    gap:6px !important;
    min-height:0 !important;
    padding:7px 8px !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact #regionalList .coco-acc-left{
    flex:0 0 auto !important;
    width:100% !important;
    max-width:100% !important;
    font-size:13px !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact #regionalList .coco-acc-right{
    flex:0 0 auto !important;
    width:100% !important;
    max-width:100% !important;
    margin:0 !important;
    display:grid !important;
    grid-template-columns:minmax(0,1fr) minmax(0,1fr) auto !important;
    align-items:center !important;
    justify-content:stretch !important;
    gap:6px !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact #regionalList .coco-filter-toggle{
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    min-height:30px !important;
    padding:5px 7px !important;
    justify-content:center !important;
    font-size:11px !important;
    overflow:hidden !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact #regionalList #homeStaffViewBtn{
    flex:0 0 28px !important;
    width:28px !important;
    min-width:28px !important;
    height:28px !important;
    margin:0 !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact #regionalList .coco-acc-filters{
    display:grid !important;
    grid-template-columns:repeat(3,minmax(0,1fr)) !important;
    gap:6px !important;
    padding:6px 8px !important;
    overflow:visible !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact #regionalList .coco-filter-chip{
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    min-height:28px !important;
    padding:4px 5px !important;
    margin:0 !important;
    font-size:11px !important;
    text-align:center !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact #regionalList .coco-acc-head{
    font-size:11px !important;
  }

  .dc-desktop-home-window.dc-home-modal-compact #regionalList.home-region-cards-mode .reg-card-grid{
    grid-template-columns:minmax(0,1fr) !important;
    gap:8px !important;
  }
}


/* =========================================================
   LISTE RÉGION — recherche + filtre compact + staff
   Le filtre réutilise les fonctions Genre/Age existantes. Les options sont
   simplement regroupées dans un menu déroulant afin de gagner de la place.
   ========================================================= */
body.dc-home-surface-open .dc-desktop-home-user-search-row{
  flex:0 0 auto;
  display:flex;
  align-items:stretch;
  gap:8px;
  min-width:0;
  margin:12px 14px 0;
  position:relative;
  box-sizing:border-box;
  overflow:visible;
  z-index:45;
}
body.dc-home-surface-open .dc-desktop-home-user-search-row > .dc-desktop-home-user-search{
  flex:1 1 auto;
  width:auto;
  min-width:0;
  margin:0 !important;
}
body.dc-home-surface-open .dc-home-region-actions{
  flex:0 0 auto;
  display:flex;
  align-items:center;
  gap:6px;
  min-width:0;
  position:relative;
  overflow:visible;
}
body.dc-home-surface-open .dc-home-region-filter-btn{
  appearance:none;
  flex:0 0 42px;
  width:42px;
  min-width:42px;
  height:42px;
  margin:0;
  padding:0;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border:1px solid rgba(255,255,255,.14);
  border-radius:10px;
  background:rgba(8,8,12,.72);
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.03);
  color:rgba(255,255,255,.82);
  cursor:pointer;
  box-sizing:border-box;
}
body.dc-home-surface-open .dc-home-region-filter-btn:hover,
body.dc-home-surface-open .dc-home-region-filter-btn.is-open{
  color:#fff;
  border-color:rgba(180,125,255,.72);
  box-shadow:0 0 0 2px rgba(180,125,255,.09), inset 0 0 0 1px rgba(255,255,255,.04);
}
body.dc-home-surface-open .dc-home-region-filter-btn.has-active-filter{
  color:#00dadd;
}
body.dc-home-surface-open .dc-home-region-actions #homeStaffViewBtn{
  flex:0 0 42px !important;
  width:42px !important;
  min-width:42px !important;
  height:42px !important;
  margin:0 !important;
  padding:0 !important;
  display:inline-flex !important;
  align-items:center !important;
  justify-content:center !important;
  border-radius:10px !important;
  box-sizing:border-box !important;
}
body.dc-home-surface-open .dc-home-region-filter-menu{
  position:absolute;
  top:calc(100% + 7px);
  right:0;
  z-index:120;
  width:238px;
  max-width:calc(100vw - 28px);
  padding:8px;
  border:1px solid rgba(180,125,255,.62);
  border-radius:11px;
  background:rgba(20,20,25,.98);
  box-shadow:0 12px 30px rgba(0,0,0,.52), 0 0 16px rgba(180,125,255,.10);
  box-sizing:border-box;
}
body.dc-home-surface-open .dc-home-region-filter-group + .dc-home-region-filter-group{
  margin-top:7px;
}
body.dc-home-surface-open .dc-home-region-filter-menu .coco-filter-toggle{
  appearance:none;
  width:100%;
  min-height:34px;
  margin:0;
  padding:0 10px;
  display:grid;
  grid-template-columns:auto 1fr auto;
  align-items:center;
  gap:6px;
  border:1px solid rgba(255,255,255,.14);
  border-radius:8px;
  background:linear-gradient(180deg, rgba(255,255,255,.08), rgba(0,0,0,.18));
  color:#fff;
  font:inherit;
  font-size:12px;
  font-weight:700;
  cursor:pointer;
  box-sizing:border-box;
}
body.dc-home-surface-open .dc-home-region-filter-menu .coco-filter-toggle-value{
  min-width:0;
  text-align:right;
}
body.dc-home-surface-open .dc-home-region-filter-menu .dc-filter-chevron{
  opacity:.72;
  transition:transform .12s ease;
}
body.dc-home-surface-open .dc-home-region-filter-menu .coco-filter-toggle.is-open .dc-filter-chevron{
  transform:rotate(180deg);
}
body.dc-home-surface-open .dc-home-region-filter-menu .coco-acc-filters{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:6px;
  padding:7px 0 0;
  margin:0;
  border:0;
  background:transparent;
}
body.dc-home-surface-open .dc-home-region-filter-menu .coco-filter-chip{
  appearance:none;
  min-width:0;
  min-height:29px;
  padding:0 7px;
  margin:0;
  border:1px solid rgba(255,255,255,.14);
  border-radius:999px;
  background:linear-gradient(180deg, rgba(255,255,255,.07), rgba(0,0,0,.16));
  color:#d40808;
  font:inherit;
  font-size:12px;
  font-weight:700;
  line-height:1;
  cursor:pointer;
  white-space:nowrap;
}
body.dc-home-surface-open .dc-home-region-filter-menu .coco-filter-chip.is-selected{
  border-color:rgba(255,255,255,.28);
  background:linear-gradient(180deg, rgba(255,255,255,.13), rgba(0,0,0,.22));
}
/* Conservation stricte des couleurs Genre existantes. */
body.dc-home-surface-open .dc-home-region-filter-menu .coco-filter-chip[data-filter-kind="gender"][data-filter-value="Homme"],
body.dc-home-surface-open .dc-home-region-filter-menu .coco-filter-toggle[data-filter-toggle="gender"][data-filter-current="Homme"] .coco-filter-toggle-value{ color:#1E90FF; }
body.dc-home-surface-open .dc-home-region-filter-menu .coco-filter-chip[data-filter-kind="gender"][data-filter-value="Femme"],
body.dc-home-surface-open .dc-home-region-filter-menu .coco-filter-toggle[data-filter-toggle="gender"][data-filter-current="Femme"] .coco-filter-toggle-value{ color:#FF00FF; }
body.dc-home-surface-open .dc-home-region-filter-menu .coco-filter-chip[data-filter-kind="gender"][data-filter-value="Trans"],
body.dc-home-surface-open .dc-home-region-filter-menu .coco-filter-toggle[data-filter-toggle="gender"][data-filter-current="Trans"] .coco-filter-toggle-value{ color:#EE82EE; }
body.dc-home-surface-open .dc-home-region-filter-menu .coco-filter-chip[data-filter-kind="gender"][data-filter-value="Travesti"],
body.dc-home-surface-open .dc-home-region-filter-menu .coco-filter-toggle[data-filter-toggle="gender"][data-filter-current="Travesti"] .coco-filter-toggle-value{ color:#B56BFF; }

@media (max-width:768px){
  body.dc-home-surface-open .dc-desktop-home-user-search-row{
    gap:7px;
    margin:8px 9px 0;
  }
  body.dc-home-surface-open .dc-home-region-filter-btn{
    flex-basis:40px;
    width:40px;
    min-width:40px;
    height:40px;
    border-radius:9px;
  }
  body.dc-home-surface-open .dc-home-region-actions #homeStaffViewBtn{
    flex-basis:40px !important;
    width:40px !important;
    min-width:40px !important;
    height:40px !important;
    border-radius:9px !important;
  }
  body.dc-home-surface-open .dc-home-region-filter-menu{
    width:224px;
    max-width:calc(100vw - 18px);
  }
}

/* Le montage région suit désormais la ligne complète recherche/actions. */
body.dc-home-surface-open .dc-desktop-home-user-search-row + .dc-desktop-home-region-mount{
  padding-top:8px;
}

/* =========================================================
   Mobile — fluidité du scroll des salons
   Les effets restent identiques à l'arrêt. Pendant le scroll uniquement,
   les animations décoratives sont mises en pause pour laisser le compositing
   au défilement natif. Aucun style de la liste Amis n'est concerné.
   ========================================================= */
@media (max-width: 768px) {
  .dc-desktop-home-salons-list-wrap.dc-mobile-salons-scrolling #channel-list *,
  .dc-desktop-home-salons-list-wrap.dc-mobile-salons-scrolling #channel-list *::before,
  .dc-desktop-home-salons-list-wrap.dc-mobile-salons-scrolling #channel-list *::after,
  .dc-desktop-home-salons-list-wrap.dc-mobile-salons-scrolling::-webkit-scrollbar-thumb {
    animation-play-state: paused !important;
  }
}
