/* Chat button and panel (tawk.to's direct chat page in an iframe), opened by js/app.js (tastyChat) from the
   button and the "contact us" links. footer.php renders the button. Kept out of master.css, which CodeKit
   compiles from the scss/ sources. */
#ChatLauncher {
  position: fixed;
  right: 20px;
  bottom: 58px;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #f15c22;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.25);
  color: #fff;
  transition: right 0.3s, opacity 0.3s, visibility 0.3s, background-color 0.2s;
}
#ChatLauncher:hover,
#ChatLauncher:focus-visible {
  background: #d9501b;
}
#ChatLauncher:focus-visible {
  outline: 3px solid #65612f;
  outline-offset: 2px;
}
#ChatLauncher svg {
  display: block;
  width: 26px;
  height: 26px;
  fill: currentColor;
}
#ChatLauncher .close-icon,
#ChatLauncher.open .chat-icon {
  display: none;
}
#ChatLauncher.open .close-icon {
  display: block;
}
#ChatLauncher.sidebar,
#ChatPanel.sidebar {
  right: 220px;
}
#ChatLauncher.hidden {
  opacity: 0;
  visibility: hidden;
}

#ChatPanel {
  position: fixed;
  right: 20px;
  bottom: 126px;
  z-index: 1001;
  display: none;
  flex-direction: column;
  box-sizing: border-box;
  width: 360px;
  height: 540px;
  max-height: calc(100vh - 146px);
  overflow: hidden;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 6px 28px rgba(0, 0, 0, 0.28);
  transition: right 0.3s;
}
#ChatPanel.open {
  display: flex;
}
#ChatPanel .bar {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: space-between;
  height: 44px;
  padding: 0 0 0 16px;
  background: #f15c22;
  color: #fff;
}
#ChatPanel .bar p {
  margin: 0;
  font-family: "museo-sans-rounded", Helvetica, sans-serif;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.5px;
}
#ChatPanel .bar .close {
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 28px;
  line-height: 44px;
  cursor: pointer;
}
#ChatPanel .bar .close:focus-visible {
  outline: 2px solid #fff;
  outline-offset: -6px;
}
/* Sits behind the iframe, whose page is transparent until tawk.to draws the chat over it (a second or two) */
#ChatPanel .loading {
  position: absolute;
  top: 44px;
  right: 0;
  bottom: 0;
  left: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  color: #8e8e8e;
  font-family: "museo-sans-rounded", Helvetica, sans-serif;
  font-size: 14px;
}
#ChatPanel iframe {
  position: relative;
  z-index: 1;
  display: block;
  flex: 1 1 auto;
  width: 100%;
  min-height: 0;
  border: 0;
  background: transparent;
}

/* Phones: the chat takes the whole screen, with the bar's close button at the top */
@media all and (max-width: 600px) {
  #ChatPanel,
  #ChatPanel.sidebar {
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    width: auto;
    height: auto;
    max-height: none;
    border-radius: 0;
  }
  html.chat-open,
  html.chat-open body {
    overflow: hidden;
  }
  #ChatLauncher.open {
    visibility: hidden;
  }
}
