/* TentoniNumérik R44.3.27.1
   Portée stricte : téléphone connecté uniquement.
   Aucune modification tablette / ordinateur.
   Aucun changement de structure DOM. */

@media(max-width:720px){
  html.tn-r42-phone body.tn-authenticated .topbar{
    min-height:112px!important;
    height:112px!important;
    background:#fff!important;
  }

  html.tn-r42-phone body.tn-authenticated .topbar-inner{
    display:grid!important;
    grid-template-columns:minmax(124px,1fr) 50px 50px 42px 42px!important;
    grid-template-rows:52px 44px!important;
    column-gap:5px!important;
    row-gap:4px!important;
    align-items:center!important;
    width:100%!important;
    max-width:none!important;
    min-height:112px!important;
    height:112px!important;
    padding:6px 8px!important;
    margin:0!important;
    box-sizing:border-box!important;
    overflow:hidden!important;
    transition:none!important;
  }

  /* Les métadonnées météo/date/heure restent hors de l'en-tête téléphone connecté. */
  html.tn-r42-phone body.tn-authenticated .top-meta{
    display:contents!important;
  }
  html.tn-r42-phone body.tn-authenticated .top-meta .top-date,
  html.tn-r42-phone body.tn-authenticated .top-meta .top-time,
  html.tn-r42-phone body.tn-authenticated .top-meta .top-weather-inline{
    display:none!important;
    visibility:hidden!important;
  }

  /* Les contrôles top-actions participent directement à la grille 2 lignes. */
  html.tn-r42-phone body.tn-authenticated .top-actions{
    display:contents!important;
  }

  /* LIGNE 1 — logo + Tentoni | Tableau de bord | Accueil */
  html.tn-r42-phone body.tn-authenticated .brand{
    grid-column:1 / 4!important;
    grid-row:1!important;
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    min-width:0!important;
    width:auto!important;
    max-width:none!important;
    height:50px!important;
    padding:0!important;
    margin:0!important;
    gap:6px!important;
    overflow:hidden!important;
    transition:none!important;
  }

  html.tn-r42-phone body.tn-authenticated .brand-mark,
  html.tn-r42-phone body.tn-authenticated .brand-mark img{
    display:block!important;
    flex:0 0 38px!important;
    width:38px!important;
    min-width:38px!important;
    max-width:38px!important;
    height:38px!important;
    object-fit:contain!important;
    margin:0!important;
  }

  html.tn-r42-phone body.tn-authenticated .brand-copy{
    display:flex!important;
    flex:1 1 auto!important;
    min-width:0!important;
    align-items:center!important;
    overflow:hidden!important;
  }

  /* Masquer nom complet + devise existants, afficher simplement Tentoni. */
  html.tn-r42-phone body.tn-authenticated .brand-copy strong,
  html.tn-r42-phone body.tn-authenticated .brand-copy small{
    display:none!important;
  }

  html.tn-r42-phone body.tn-authenticated .brand-copy::after{
    content:"Tentoni"!important;
    display:block!important;
    color:#082d68!important;
    font-size:18px!important;
    line-height:1!important;
    font-weight:900!important;
    white-space:nowrap!important;
  }

  html.tn-r42-phone body.tn-authenticated #tn141-manager-launch{
    grid-column:4!important;
    grid-row:1!important;
    position:static!important;
    display:grid!important;
    visibility:visible!important;
    place-items:center!important;
    align-content:center!important;
    grid-template-rows:20px 9px!important;
    width:48px!important;
    min-width:48px!important;
    max-width:48px!important;
    height:48px!important;
    min-height:48px!important;
    padding:3px!important;
    margin:0!important;
    border-radius:50%!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
    font-size:0!important;
    color:transparent!important;
    transition:none!important;
  }

  html.tn-r42-phone body.tn-authenticated #tn141-manager-launch span{
    display:none!important;
  }

  html.tn-r42-phone body.tn-authenticated #tn141-manager-launch::before{
    content:""!important;
    display:block!important;
    width:20px!important;
    height:20px!important;
    background:url('/assets/r44-3-27-1/dashboard-phone.svg') center/contain no-repeat!important;
  }

  html.tn-r42-phone body.tn-authenticated #tn141-manager-launch::after{
    content:"TDB"!important;
    display:block!important;
    color:#174b86!important;
    font-size:6.5px!important;
    font-weight:900!important;
    line-height:8px!important;
  }

  html.tn-r42-phone body.tn-authenticated .mobile-menu-btn{
    grid-column:5!important;
    grid-row:1!important;
    position:static!important;
    display:grid!important;
    place-items:center!important;
    align-content:center!important;
    grid-template-rows:20px 9px!important;
    width:48px!important;
    min-width:48px!important;
    max-width:48px!important;
    height:48px!important;
    min-height:48px!important;
    padding:3px!important;
    margin:0!important;
    border-radius:12px!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
    font-size:0!important;
    transition:none!important;
  }

  html.tn-r42-phone body.tn-authenticated .mobile-menu-btn span{
    display:none!important;
  }

  html.tn-r42-phone body.tn-authenticated .mobile-menu-btn::before{
    content:""!important;
    display:block!important;
    width:20px!important;
    height:20px!important;
    background:url('/assets/r44-3-27-1/home-phone.svg') center/contain no-repeat!important;
  }

  html.tn-r42-phone body.tn-authenticated .mobile-menu-btn::after{
    content:"Accueil"!important;
    display:block!important;
    color:#31597f!important;
    font-size:6.5px!important;
    font-weight:900!important;
    line-height:8px!important;
  }

  /* LIGNE 2 — compte | France | enveloppe | alerte */
  html.tn-r42-phone body.tn-authenticated #header-logout{
    grid-column:2!important;
    grid-row:2!important;
    display:grid!important;
    place-items:center!important;
    width:40px!important;
    min-width:40px!important;
    max-width:40px!important;
    height:40px!important;
    min-height:40px!important;
    padding:0!important;
    margin:0!important;
    border-radius:50%!important;
    transition:none!important;
  }

  html.tn-r42-phone body.tn-authenticated #header-logout span{
    display:none!important;
  }

  html.tn-r42-phone body.tn-authenticated #header-logout img{
    width:23px!important;
    height:23px!important;
  }

  html.tn-r42-phone body.tn-authenticated #language-btn{
    grid-column:3!important;
    grid-row:2!important;
    display:inline-flex!important;
    visibility:visible!important;
    opacity:1!important;
    align-items:center!important;
    justify-content:center!important;
    width:38px!important;
    min-width:38px!important;
    max-width:38px!important;
    height:36px!important;
    min-height:36px!important;
    padding:0!important;
    margin:0!important;
    border-radius:9px!important;
    transition:none!important;
  }

  html.tn-r42-phone body.tn-authenticated #language-btn::before{
    width:25px!important;
    height:17px!important;
  }

  html.tn-r42-phone body.tn-authenticated .top-actions>a.round-action{
    grid-column:4!important;
    grid-row:2!important;
    display:grid!important;
    place-items:center!important;
    width:38px!important;
    min-width:38px!important;
    max-width:38px!important;
    height:38px!important;
    min-height:38px!important;
    margin:0!important;
    transition:none!important;
  }

  html.tn-r42-phone body.tn-authenticated .top-actions .education-alert-bell{
    grid-column:5!important;
    grid-row:2!important;
    display:grid!important;
    place-items:center!important;
    width:38px!important;
    min-width:38px!important;
    max-width:38px!important;
    height:38px!important;
    min-height:38px!important;
    margin:0!important;
    transition:none!important;
  }

  html.tn-r42-phone body.tn-authenticated .top-actions .round-action img,
  html.tn-r42-phone body.tn-authenticated .top-actions .education-alert-bell img{
    width:22px!important;
    height:22px!important;
  }

  /* Stabilisation de cette seule zone. */
  html.tn-r42-phone body.tn-authenticated .topbar *,
  html.tn-r42-phone body.tn-authenticated .topbar *::before,
  html.tn-r42-phone body.tn-authenticated .topbar *::after{
    transition-property:none!important;
    animation-duration:0s!important;
    animation-delay:0s!important;
  }
}
