/* HireMitra static chatbot — same pattern as ECSE Assistant */
.hm-chat,
.hm-chat * {
  box-sizing: border-box;
  transition: none;
}
.hm-chat p { opacity: 1; margin: 0; }
.hm-chat button {
  font: inherit;
  border: 0;
  background: none;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  padding: 0;
  margin: 0;
  line-height: inherit;
  color: inherit;
}
.hm-chat .visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.hm-chat {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 1400;
  font-family: "Inter", sans-serif;
}
.hm-chat__launcher {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #FF6219 !important;
  color: #fff !important;
  display: grid;
  place-items: center;
  box-shadow: 0 14px 32px rgba(255, 98, 25, 0.38);
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease !important;
}
.hm-chat__launcher:hover,
.hm-chat__launcher:focus,
.hm-chat__launcher:focus-visible {
  background: #e45510 !important;
  color: #fff !important;
  transform: scale(1.06);
  box-shadow: 0 16px 34px rgba(255, 98, 25, 0.45);
  outline: none;
}
.hm-chat.is-open .hm-chat__launcher,
.hm-chat.is-open .hm-chat__launcher:hover,
.hm-chat.is-open .hm-chat__launcher:focus {
  background: #111 !important;
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.28);
}
.hm-chat__launcher-icon {
  display: grid;
  place-items: center;
  color: #fff;
  pointer-events: none;
}
.hm-chat__launcher-icon svg {
  display: block;
  stroke: currentColor;
}
.hm-chat__launcher-icon--close { display: none; }
.hm-chat.is-open .hm-chat__launcher-icon--open { display: none; }
.hm-chat.is-open .hm-chat__launcher-icon--close { display: grid; }
.hm-chat__panel {
  position: absolute;
  right: 0;
  bottom: 76px;
  width: min(380px, calc(100vw - 32px));
  height: min(560px, calc(100vh - 120px));
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 22px;
  box-shadow: 0 24px 60px rgba(17, 17, 17, 0.18);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform-origin: bottom right;
  animation: hm-chat-in 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}
.hm-chat__panel[hidden] {
  display: none !important;
}
@keyframes hm-chat-in {
  from { opacity: 0; transform: translateY(12px) scale(0.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.hm-chat__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 16px 14px;
  background: linear-gradient(135deg, #FF6219 0%, #F54400 100%);
  color: #fff;
}
.hm-chat__brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.hm-chat__avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fff;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  overflow: hidden;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.35);
  color: #FF6219;
  font-family: "Outfit", sans-serif;
  font-weight: 700;
  font-size: 13px;
}
.hm-chat__avatar img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  padding: 4px;
}
.hm-chat__brand strong {
  display: block;
  font-family: "Outfit", sans-serif;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.2;
  color: #fff !important;
}
.hm-chat__brand span,
.hm-chat__status {
  display: block;
  font-size: 12px;
  opacity: 0.85;
  margin-top: 2px;
  color: #fff;
}
.hm-chat__close {
  position: relative;
  z-index: 2;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  color: #fff;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  cursor: pointer;
  transition: background 0.2s ease;
}
.hm-chat__close svg { pointer-events: none; }
.hm-chat__close:hover { background: rgba(255, 255, 255, 0.12); }
.hm-chat__messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: #FFF8F1;
}
.hm-chat__bubble {
  max-width: 88%;
  padding: 12px 14px;
  border-radius: 16px;
  font-size: 14px;
  line-height: 1.5;
  color: #111;
  white-space: pre-wrap;
}
.hm-chat__bubble p { margin: 0; opacity: 1; }
.hm-chat__bubble--bot {
  align-self: flex-start;
  background: #fff;
  border: 1px solid #f0e6dc;
  border-bottom-left-radius: 6px;
  box-shadow: 0 4px 12px rgba(255, 98, 25, 0.05);
}
.hm-chat__bubble--user {
  align-self: flex-end;
  background: #FF6219;
  color: #fff;
  border-bottom-right-radius: 6px;
}
.hm-chat__typing {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 14px 16px;
  min-height: 44px;
  white-space: nowrap;
}
.hm-chat__typing-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #FF6219;
  opacity: 0.35;
  animation: hm-chat-typing 1.2s ease-in-out infinite;
}
.hm-chat__typing-dot:nth-child(2) { animation-delay: 0.15s; }
.hm-chat__typing-dot:nth-child(3) { animation-delay: 0.3s; }
@keyframes hm-chat-typing {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.35; }
  30% { transform: translateY(-4px); opacity: 1; }
}
.hm-chat__bubble--typing-out p::after {
  content: "";
  display: inline-block;
  width: 2px;
  height: 0.95em;
  margin-left: 2px;
  vertical-align: -2px;
  background: #FF6219;
  animation: hm-chat-caret 0.8s step-end infinite;
}
@keyframes hm-chat-caret {
  50% { opacity: 0; }
}
.hm-chat__suggestions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 4px 16px 14px;
  background: #FFF8F1;
  max-height: 46%;
  overflow-y: auto;
}
.hm-chat__suggestions.is-busy {
  pointer-events: none;
  opacity: 0.55;
}
.hm-chat__menu-label {
  width: 100%;
  margin: 2px 0 4px;
  font-family: "Outfit", sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #9a8f86;
}
.hm-chat__chip {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border-radius: 14px;
  border: 1px solid #f0e4d8;
  background: #fff;
  color: #1a1a1a;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.35;
  text-align: left;
  white-space: normal;
  box-shadow: 0 2px 8px rgba(255, 98, 25, 0.04);
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease !important;
}
.hm-chat__chip-icon {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: rgba(255, 98, 25, 0.1);
  color: #FF6219;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.hm-chat__chip-icon svg,
.hm-chat__chip-arrow svg {
  display: block;
}
.hm-chat__chip-text {
  flex: 1;
  min-width: 0;
}
.hm-chat__chip-arrow {
  color: #c4b6aa;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  transition: transform 0.2s ease, color 0.2s ease;
}
.hm-chat__chip:hover,
.hm-chat__chip:focus {
  border-color: #FF6219;
  background: #fff7f1;
  color: #111;
  box-shadow: 0 6px 16px rgba(255, 98, 25, 0.12);
  transform: translateY(-1px);
  outline: none;
}
.hm-chat__chip:hover .hm-chat__chip-icon,
.hm-chat__chip:focus .hm-chat__chip-icon {
  background: #FF6219;
  color: #fff;
}
.hm-chat__chip:hover .hm-chat__chip-arrow,
.hm-chat__chip:focus .hm-chat__chip-arrow {
  color: #FF6219;
  transform: translateX(2px);
}
.hm-chat__chip--primary {
  background: #FF6219;
  border-color: #FF6219;
  color: #fff;
  box-shadow: 0 8px 18px rgba(255, 98, 25, 0.28);
}
.hm-chat__chip--primary .hm-chat__chip-icon {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
}
.hm-chat__chip--primary .hm-chat__chip-arrow {
  color: rgba(255, 255, 255, 0.8);
}
.hm-chat__chip--primary:hover,
.hm-chat__chip--primary:focus {
  background: #e45510;
  border-color: #e45510;
  color: #fff;
  box-shadow: 0 10px 22px rgba(255, 98, 25, 0.34);
}
.hm-chat__chip--primary:hover .hm-chat__chip-icon,
.hm-chat__chip--primary:focus .hm-chat__chip-icon {
  background: rgba(255, 255, 255, 0.24);
  color: #fff;
}
.hm-chat__chip--primary:hover .hm-chat__chip-arrow,
.hm-chat__chip--primary:focus .hm-chat__chip-arrow {
  color: #fff;
}
.hm-chat__chip--back {
  background: transparent;
  border-color: transparent;
  box-shadow: none;
  color: #7a7068;
  padding: 8px 10px;
}
.hm-chat__chip--back .hm-chat__chip-icon {
  width: 28px;
  height: 28px;
  background: #f3ece6;
  color: #7a7068;
}
.hm-chat__chip--back:hover,
.hm-chat__chip--back:focus {
  background: #fff;
  border-color: #f0e4d8;
  color: #111;
  box-shadow: none;
  transform: none;
}
.hm-chat__chip--back:hover .hm-chat__chip-icon,
.hm-chat__chip--back:focus .hm-chat__chip-icon {
  background: rgba(255, 98, 25, 0.1);
  color: #FF6219;
}
.hm-chat__form {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px;
  border-top: 1px solid #f0e6dc;
  background: #fff;
}
.hm-chat__form.is-disabled {
  opacity: 0.55;
}
.hm-chat__form.is-disabled input,
.hm-chat__form.is-disabled button {
  cursor: not-allowed;
}
.hm-chat__form input,
.hm-chat__form input[type="text"],
.hm-chat__form input[type="email"],
.hm-chat__form input[type="tel"] {
  flex: 1;
  min-width: 0;
  width: auto !important;
  height: 44px;
  border: 1px solid #e8ddd3;
  border-radius: 12px;
  padding: 0 14px;
  font-size: 14px;
  font-weight: 500;
  font-family: "Inter", sans-serif;
  color: #111;
  outline: none;
  background: #fff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.hm-chat__form input:focus {
  border-color: #FF6219;
  box-shadow: 0 0 0 3px rgba(255, 98, 25, 0.12);
}
.hm-chat__form button {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: #FF6219;
  color: #fff;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  transition: background 0.2s ease, transform 0.15s ease;
}
.hm-chat__form button:hover,
.hm-chat__form button:focus {
  background: #e45510;
  color: #fff;
  transform: translateY(-1px);
}
@media (max-width: 560px) {
  .hm-chat { right: 14px; bottom: 14px; }
  .hm-chat__launcher { width: 54px; height: 54px; }
  .hm-chat__panel {
    bottom: 68px;
    width: min(100vw - 28px, 380px);
    height: min(70vh, 520px);
  }
}
