/* Contact popup — same quiet white/black/gray language as the OrderX landing. */
#chat-fab[hidden],
#chat-panel[hidden] {
  display: none !important;
}

#chat-fab {
  align-items: center;
  background: #f5f5f5;
  border: none;
  border-radius: 999px;
  bottom: 28px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .10);
  cursor: pointer;
  display: flex;
  height: 56px;
  justify-content: center;
  padding: 0;
  position: fixed;
  right: 28px;
  transition: background-color 180ms cubic-bezier(0.25, 0.1, 0, 1), transform 180ms cubic-bezier(0.25, 0.1, 0, 1);
  width: 56px;
  z-index: 9999;
}

@media (hover: hover) and (pointer: fine) {
  #chat-fab:hover { background: #ebebeb; }
}

@media (hover: none), (pointer: coarse) {
  #chat-fab:active { background: #ebebeb; }
}

#chat-fab:active { transform: scale(0.97); }

#chat-fab:focus { outline: none; }
#chat-fab:focus-visible { outline: 2px solid rgba(17, 17, 17, 0.35); outline-offset: 3px; }
#chat-fab svg { height: 30px; width: 30px; color: #111111; }
#chat-fab .icon-close { display: none; }
#chat-fab.is-open .icon-open { display: none; }
#chat-fab.is-open .icon-close { display: block; }

#chat-panel {
  background: #fff;
  border-radius: 18px;
  bottom: 96px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, .14);
  height: min(560px, 72dvh);
  overflow: hidden;
  position: fixed;
  right: 28px;
  width: min(380px, calc(100vw - 24px));
  z-index: 9999;
}

#chat-frame {
  background: #fff;
  border: 0;
  display: block;
  height: 100%;
  width: 100%;
}

@media (max-width: 480px) {
  #chat-fab { bottom: 20px; right: 16px; }
  #chat-panel {
    bottom: 88px;
    height: min(70dvh, 600px);
    left: 12px;
    right: 12px;
    width: auto;
  }
}
