/* Extrait de student_dashboard.html. Ordre historique : 9. */
.ws-rh { position:absolute; z-index:10100; }
            .ws-rh.n  { top:-4px;    left:18px; right:18px; height:8px;  cursor:n-resize; background:rgba(102,126,234,0.5); border-radius:4px; }
            .ws-rh.s  { bottom:-4px; left:18px; right:18px; height:8px;  cursor:s-resize; background:rgba(102,126,234,0.5); border-radius:4px; }
            .ws-rh.w  { left:-4px;   top:18px; bottom:18px; width:8px;   cursor:w-resize; background:rgba(102,126,234,0.5); border-radius:4px; }
            .ws-rh.e  { right:-4px;  top:18px; bottom:18px; width:8px;   cursor:e-resize; background:rgba(102,126,234,0.5); border-radius:4px; }
            .ws-rh.nw,.ws-rh.ne,.ws-rh.sw,.ws-rh.se { width:18px; height:18px; background:transparent; }
            .ws-rh.nw { top:-4px;    left:-4px;  cursor:nw-resize; }
            .ws-rh.ne { top:-4px;    right:-4px; cursor:ne-resize; }
            .ws-rh.sw { bottom:-4px; left:-4px;  cursor:sw-resize; }
            .ws-rh.se { bottom:-4px; right:-4px; cursor:se-resize; }
            .ws-rh.se::after { content:''; position:absolute; bottom:0; right:0; width:0; height:0; border-style:solid; border-width:0 0 18px 18px; border-color:transparent transparent #667eea transparent; }
            .ws-rh.sw::after { content:''; position:absolute; bottom:0; left:0;  width:0; height:0; border-style:solid; border-width:18px 0 0 18px; border-color:transparent transparent transparent #667eea; }
            .ws-rh.ne::after { content:''; position:absolute; top:0; right:0;    width:0; height:0; border-style:solid; border-width:0 18px 18px 0; border-color:transparent #667eea transparent transparent; }
            .ws-rh.nw::after { content:''; position:absolute; top:0; left:0;     width:0; height:0; border-style:solid; border-width:18px 18px 0 0; border-color:#667eea transparent transparent transparent; }
            .ws-rh:hover { filter:brightness(1.6); }
            body.ws-resizing, body.ws-resizing * { user-select:none !important; cursor:inherit !important; }
            #tpWorkspacePanel { position:absolute; inset:0; background:white; border-radius:12px; display:flex; flex-direction:column; overflow:hidden; box-shadow:0 25px 60px rgba(0,0,0,0.5); }
/* MOBILE - PORTRAIT + PAYSAGE */
@media (max-width:900px){
  #hourglassContainer{display:none!important;}
  #tpWorkspace{background:#fff!important;align-items:stretch!important;justify-content:stretch!important;padding:0!important;}
  .ws-resize-wrapper{width:100%!important;max-width:100%!important;height:100%!important;min-height:unset!important;position:fixed!important;inset:0!important;}
  #tpWorkspacePanel{border-radius:0!important;box-shadow:none!important;}
  .ws-rh{display:none!important;}
  /* Header ultra-compact : 1 ligne seulement */
  .ws-header-bar{padding:5px 10px!important;}
  /* Masquer la barre de progression du header - elle est dans le bandeau bas */
  #wsHeaderProgress{display:none!important;}
  #wsTPTitle{font-size:.85rem!important;margin:0!important;}
  #wsTPCode{font-size:.7rem!important;margin:0!important;}
  /* Boutons header = icone seule */
  .ws-btn-label{display:none!important;}
  #wsSaveBtn{padding:5px 8px!important;border-width:1px!important;}
  .ws-close-btn{padding:5px 8px!important;}
  /* Onglets compacts */
  .ws-tabs-bar{padding:4px 8px!important;gap:4px!important;}
  .ws-tabs-bar button{padding:5px 9px!important;font-size:.73rem!important;border-radius:6px!important;}
  /* Contenu */
  #wsContentScroller{padding:8px!important;}
  /* Bandeau bas */
  #wsNavBar{height:48px!important;padding:0 8px!important;}
  #wsNavBar button{padding:5px 11px!important;font-size:.8rem!important;}
}
/* PORTRAIT smartphone strict */
@media (max-width:480px) and (orientation:portrait){
  .ws-tabs-bar button{padding:4px 7px!important;font-size:.68rem!important;}
  #wsContentScroller{font-size:13px!important;padding:6px!important;}
  #wsNavBar{padding:0 5px!important;}
  #wsNavBar>div{gap:5px!important;}
  #wsNavCenter,#wsNavDivider{display:none!important;}
  #wsNavLabel{font-size:.68rem!important;}
  #wsNavBar button{padding:5px 8px!important;font-size:.72rem!important;}
}
/* PAYSAGE smartphone */
@media (max-width:900px) and (orientation:landscape){
  #wsNavLabel{display:none!important;}
  #wsNavProgress{display:none!important;}
  #wsNavCenter,#wsNavDivider{display:none!important;}
  .ws-tabs-bar{display:none!important;}
  #wsContentScroller{padding:6px 8px!important;}
  #wsNavBar{height:42px!important;}
}
