/* FRBC V36.12 — RETOUR DISPOSITION ORDINATEUR + CARTE "JEU" A DROITE.
   Ne remplace aucun script, aucun moteur, ni aucun panneau mobile.
   Retire le Fluid PC V36.9 de la liste des styles dans index.html.
   La carte native est #v28-match-hint; ses donnees et son repli sont conserves.
*/
/* Desktop classique V35 (grand ecran): la pile V32 calcule dynamiquement
   --frbc-v32-popup-top a partir du bord inferieur du rail V28. */
@media screen and (min-width:980px) and (pointer:fine) and (hover:hover) {
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-ui) #v28-match-hint#v28-match-hint:not([hidden]) {
    position:fixed!important;
    left:auto!important;
    right:var(--v28-edge,10px)!important;
    top:var(--frbc-v32-popup-top,auto)!important;
    bottom:auto!important;
    width:var(--v28-right,184px)!important;
    max-width:var(--v28-right,184px)!important;
    max-height:var(--frbc-v32-popup-max-height,128px)!important;
    overflow-y:auto!important;
    box-sizing:border-box!important;
  }
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-ui) #v28-match-hint#v28-match-hint.v28-hint-collapsed:not([hidden]) {
    width:38px!important;min-width:38px!important;max-width:38px!important;
  }
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-ui) #toast#toast.show:not([hidden]) {
    position:fixed!important;
    left:auto!important;
    right:var(--v28-edge,10px)!important;
    top:var(--frbc-v32-popup-top,auto)!important;
    bottom:auto!important;
    max-width:var(--v28-right,184px)!important;
  }
  /* La pile V32 conserve le rail defilable au-dessus des notifications. */
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-ui) #v28-rail#v28-rail:not([hidden]) {
    max-height:var(--frbc-v32-rail-max-height,calc(100dvh - var(--v28-menu-top,166px) - 170px))!important;
    overflow-y:auto!important;
  }
}
/* Une petite FENETRE D'ORDINATEUR n'est pas un mobile paysage.
   Les media queries V36 qui ne regardent que largeur et hauteur sont
   neutralisees ici lorsqu'une vraie souris avec survol est presente.
   Les simulations tactiles (hover:none) et tous les mobiles sont exclus. */
@media screen and (orientation:landscape) and (min-width:700px) and (max-width:979.99px) and (min-height:456px) and (max-height:600px) and (pointer:fine) and (hover:hover) {
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-ui) {
    --v28-right:clamp(155px,19vw,190px);
    --v28-edge:10px;
    --v28-menu-top:clamp(70px,16dvh,112px);
  }
  /* Dock de jeu horizontal bas-gauche, comme avant Fluid UI. */
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-horizontal) #game-dock#game-dock:not([hidden]) {
    position:fixed!important;
    top:auto!important;right:auto!important;left:clamp(8px,2vw,20px)!important;
    bottom:8px!important;
    width:calc(100dvw - var(--v28-right) - 35px)!important;
    min-width:0!important;max-width:calc(100dvw - var(--v28-right) - 35px)!important;
    height:auto!important;max-height:min(30dvh,180px)!important;
    display:flex!important;flex-flow:row wrap!important;align-items:center!important;
    gap:6px!important;padding:8px!important;
    overflow-x:hidden!important;overflow-y:auto!important;
    transform:none!important;box-sizing:border-box!important;
  }
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-horizontal) #game-dock#game-dock .turn-info {
    display:block!important;flex:1 1 170px!important;min-width:120px!important;
    max-width:340px!important;text-align:left!important;
  }
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-horizontal) #game-dock#game-dock :is(.dice-values,.dock-actions,.dock-secondary,.frbc-multiplayer-actions):not([hidden]) {
    display:flex!important;flex-flow:row wrap!important;align-items:center!important;
    flex:0 1 auto!important;max-width:100%!important;min-width:0!important;
    width:auto!important;gap:5px!important;margin:0!important;
  }
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-horizontal) #game-dock#game-dock :is(.dock-actions,.dock-secondary,.frbc-multiplayer-actions) button:not([hidden]) {
    width:auto!important;min-width:0!important;min-height:40px!important;
  }
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-horizontal) #game-dock#game-dock .dock-actions .primary:not([hidden]) {
    flex:1 1 auto!important;max-width:100%!important;
  }
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-horizontal) #v28-dock-handle#v28-dock-handle {
    position:fixed!important;left:clamp(8px,2vw,20px)!important;
    right:auto!important;top:auto!important;bottom:10px!important;
    min-width:35px!important;min-height:40px!important;
  }
  /* Rail ancien, colonne droite, defilable et independante du dock. */
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-horizontal) #v28-rail#v28-rail:not([hidden]) {
    position:fixed!important;left:auto!important;right:var(--v28-edge)!important;
    top:var(--v28-menu-top)!important;bottom:auto!important;
    width:var(--v28-right)!important;min-width:0!important;max-width:var(--v28-right)!important;
    max-height:calc(100dvh - var(--v28-menu-top) - 84px)!important;
    overflow-y:auto!important;overflow-x:hidden!important;
    transform:none!important;box-sizing:border-box!important;
  }
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-horizontal) #v28-rail-handle#v28-rail-handle {
    top:var(--v28-menu-top)!important;right:calc(var(--v28-edge) + var(--v28-right) + 3px)!important;
    left:auto!important;
  }
  /* La carte jeu est sous le rail DROIT, jamais sous le dock gauche. */
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-horizontal) #v28-match-hint#v28-match-hint:not([hidden]) {
    position:fixed!important;inset:auto!important;
    top:auto!important;right:var(--v28-edge)!important;left:auto!important;bottom:8px!important;
    width:var(--v28-right)!important;max-width:var(--v28-right)!important;
    min-height:0!important;max-height:65px!important;
    overflow-y:auto!important;box-sizing:border-box!important;
  }
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-horizontal) #v28-match-hint#v28-match-hint.v28-hint-collapsed:not([hidden]) {
    width:38px!important;max-width:38px!important;
  }
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-horizontal) #toast#toast.show:not([hidden]) {
    position:fixed!important;inset:auto!important;top:auto!important;
    right:var(--v28-edge)!important;left:auto!important;bottom:78px!important;
    max-width:var(--v28-right)!important;
  }
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-horizontal) .frbc-notification-root {
    left:auto!important;right:var(--v28-edge)!important;
  }
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-horizontal) :is(#game-dock,#v28-rail,#v28-match-hint,#toast)[hidden] {
    display:none!important;
  }
}

/* V36.12 — CORRECTIF V13 FINAL, petite fenetre d'ordinateur.
   Cache les ANCIENS compteurs Ivoire/Bleu, pas le score natif V28.
   Conserve une seule action primaire BLEUE dans le vrai dock.
   Ne s'applique jamais en portrait. */
@media screen and (orientation:landscape) and (min-width:700px) and (max-width:979.99px) and (pointer:fine) {
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-ui)
  #side-stats#side-stats,
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-ui)
  .side-stats.side-stats {
    display:none!important;
    visibility:hidden!important;
  }
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-ui)
  #game-dock#game-dock .dock-actions .primary:not([hidden]) {
    display:flex!important;
    justify-content:center!important;
    align-items:center!important;
    background:linear-gradient(120deg,#f2f8ff,#9dd5ff)!important;
    color:#092744!important;
    border:1px solid #c8edff!important;
    border-radius:9px!important;
    min-height:44px!important;
    box-shadow:none!important;
  }
}

@media screen and (orientation:landscape) and (min-width:900px) and (max-width:979.99px) and (min-height:456px) and (pointer:fine) and (hover:hover) {
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-ui)
  #v28-match-hint#v28-match-hint:not([hidden]) {
    top:var(--frbc-v32-popup-top,calc(var(--v28-menu-top,80px) + 198px))!important;
    bottom:auto!important;
  }
  html.frbc-v28-demo:not(.frbc-mobile-vertical):not(.frbc-mobile-ui)
  #toast#toast.show:not([hidden]) {
    top:var(--frbc-v32-popup-top,calc(var(--v28-menu-top,80px) + 198px))!important;
    bottom:auto!important;
  }
}
