/* Chatwoot exclusivo das páginas públicas de autenticação. */
/* A maior parte do visual vem do Inbox settings + chatwootSettings. */
.gpix-mobile-support-launcher{
  display:none;
}

.gpix-mobile-support-launcher.is-collision-hidden{
  opacity:0;
  visibility:hidden;
  pointer-events:none;
}

body.gpix-chat-is-open #gpix-mascote{
  display:none !important;
}

/* Modal layers stay above the support widget; the sidebar backdrop is excluded. */
.gpix-modal-layer,
.overlay:not(#overlay),
.modal.show,
.home-alert-modal,
.ref-modal-overlay,
.token-modal,
#secretOverlay,
dialog[open]{
  z-index:2147483500 !important;
}

.ref-modal-overlay,
.token-modal,
.home-alert-modal{
  max-width:100vw;
  max-height:100dvh;
  overflow:auto;
  overscroll-behavior:contain;
  padding:calc(12px + env(safe-area-inset-top, 0px)) 12px calc(12px + env(safe-area-inset-bottom, 0px)) !important;
}

.ref-modal,
.token-modal-card,
.home-alert-card{
  max-width:100%;
  max-height:calc(100dvh - 24px - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px)) !important;
  overflow:auto;
}

html.gpix-any-modal-open,
body.gpix-any-modal-open{
  overflow:hidden !important;
  overscroll-behavior:none;
}

@media (max-width: 760px){
  .ref-modal-overlay,
  .token-modal,
  .home-alert-modal{
    padding:calc(8px + env(safe-area-inset-top, 0px)) 8px calc(8px + env(safe-area-inset-bottom, 0px)) !important;
  }

  .ref-modal,
  .token-modal-card,
  .home-alert-card{
    max-height:calc(100dvh - 16px - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px)) !important;
  }

  .gpix-mobile-support-launcher{
    position:fixed;
    right:max(14px, env(safe-area-inset-right, 0px));
    bottom:max(14px, env(safe-area-inset-bottom, 0px));
    z-index:2147483000;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    gap:0;
    width:48px;
    min-width:48px;
    height:48px;
    border:0;
    border-radius:999px;
    padding:0;
    background:#20d8c8;
    color:#fff;
    box-shadow:0 10px 28px rgba(16,216,200,.28), 0 4px 18px rgba(0,0,0,.22);
    font:800 14px/1 system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
    letter-spacing:0;
  }

  .gpix-mobile-support-icon{
    width:24px;
    height:24px;
    flex:0 0 24px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
  }

  .gpix-mobile-support-icon svg{
    width:24px;
    height:24px;
    display:block;
    fill:none;
    stroke:#fff;
    stroke-width:2.25;
    stroke-linecap:round;
    stroke-linejoin:round;
  }

  .gpix-mobile-support-text{
    position:absolute;
    width:1px;
    height:1px;
    padding:0;
    margin:-1px;
    overflow:hidden;
    clip:rect(0,0,0,0);
    white-space:nowrap;
    border:0;
  }

  .gpix-mobile-support-launcher.hidden{
    display:none;
  }

  body.gpix-chat-hidden-mobile .gpix-mobile-support-launcher,
  body.gpix-any-modal-open .gpix-mobile-support-launcher,
  body.modal-open .gpix-mobile-support-launcher,
  body.gpix-virtual-keyboard .gpix-mobile-support-launcher{
    display:none !important;
  }

  .gpix-mobile-support-launcher:disabled{
    opacity:.72;
  }

  .woot-widget-bubble,
  .woot--bubble-holder{
    right: 12px !important;
    bottom: calc(74px + env(safe-area-inset-bottom, 0px)) !important;
  }

  .woot-widget-holder{
    right: 8px !important;
    left: 8px !important;
    bottom: calc(86px + env(safe-area-inset-bottom, 0px)) !important;
    width: calc(100vw - 16px) !important;
    max-width: calc(100vw - 16px) !important;
    height: min(70vh, 620px) !important;
    max-height: min(70vh, 620px) !important;
  }

  body.gpix-chat-hidden-mobile .woot-widget-bubble,
  body.gpix-chat-hidden-mobile .woot--bubble-holder,
  body.gpix-chat-hidden-mobile .woot-widget-holder,
  body.gpix-any-modal-open .woot-widget-bubble,
  body.gpix-any-modal-open .woot--bubble-holder,
  body.gpix-any-modal-open .woot-widget-holder,
  body.modal-open .woot-widget-bubble,
  body.modal-open .woot--bubble-holder,
  body.modal-open .woot-widget-holder,
  body.gpix-virtual-keyboard .woot-widget-bubble,
  body.gpix-virtual-keyboard .woot--bubble-holder,
  body.gpix-virtual-keyboard .woot-widget-holder,
  body.gpix-virtual-keyboard #gpix-mascote{
    display: none !important;
  }
}
