/*
 Tim's Cloud V576 · Safe Mobile Touch Hotfix
 Behebt v575-Überlagerungen/Scrollprobleme und ergänzt nur konservative Touch-Hilfen.
 Bestehende Seitenlayouts aus style.css bleiben die Quelle der Darstellung.
*/
:root{--v576-touch:46px;--v576-safe-bottom:env(safe-area-inset-bottom,0px)}
html.touch-v576,body.touch-v576{max-width:100%;overflow-x:hidden!important;-webkit-tap-highlight-color:transparent}
body.touch-v576{overflow-y:auto!important;-webkit-overflow-scrolling:touch!important;overscroll-behavior-y:auto!important}
body.touch-v576 input,body.touch-v576 textarea,body.touch-v576 select{font-size:16px!important}
body.touch-v576 button,body.touch-v576 a,body.touch-v576 select{touch-action:manipulation}
body.touch-v576 button:active,body.touch-v576 .btn:active{filter:brightness(1.07)}
.v576-zoomable{touch-action:none!important;transform-origin:center center;will-change:transform;user-select:none;-webkit-user-drag:none}
.v576-zooming{transition:none!important}
.v576-zoom-hint{position:absolute;left:50%;bottom:16px;transform:translateX(-50%);z-index:15;padding:7px 11px;border-radius:999px;background:rgba(10,15,24,.72);border:1px solid rgba(135,160,203,.25);color:#e4edfb;font-size:12px;pointer-events:none;animation:v576hint 2.7s ease forwards}
@keyframes v576hint{0%,8%,100%{opacity:0}18%,73%{opacity:1}}
@media (max-width:900px),(pointer:coarse){
  body.touch-v576 .toast-wrap{left:10px;right:10px;max-width:none;bottom:calc(72px + var(--v576-safe-bottom))}
  /* Nur primäre Bedienelemente vergrößern; keine Layoutcontainer neu positionieren. */
  body.touch-v576 .topbar button,
  body.touch-v576 .mobile-bottom-nav-v437 button,
  body.touch-v576 .settings-card-v540 button,
  body.touch-v576 .settings-main-v540 button,
  body.touch-v576 .admin-main-v522 button,
  body.touch-v576 .auth-card button,
  body.touch-v576 .v317-card button,
  body.touch-v576 .vault-toolbar-actions-v561 button{
    min-height:var(--v576-touch)!important;
  }
  body.touch-v576 .modal-card,
  body.touch-v576 .settings-dialog-card-v541{max-width:calc(100vw - 18px)!important;max-height:calc(100dvh - 18px)!important;overflow:auto!important}
  body.touch-v576 img,body.touch-v576 video{max-width:100%}
  /* Einstellungen/Admin dürfen wieder normal vertikal scrollen. */
  body.touch-v576 .settings-main-v540,
  body.touch-v576 .admin-main-v522,
  body.touch-v576 .admin-layout-v522 main{
    overflow:visible!important;
    min-height:auto!important;
  }
}
