.hdu-chat { --chat-accent: #f36a1b; position: fixed; right: 24px; bottom: 26px; z-index: 99990; font: 15px/1.55 Arial, sans-serif; color: #f7f1e9; }
.hdu-chat *, .hdu-chat *::before, .hdu-chat *::after { box-sizing: border-box; }
.hdu-chat [hidden] { display: none !important; }
.hdu-chat button, .hdu-chat input, .hdu-chat textarea { font: inherit; }
.hdu-chat button, .hdu-chat a { -webkit-tap-highlight-color: transparent; }
.hdu-chat-launcher { display: flex; align-items: center; gap: 11px; background: #f36a1b; color: #140d08; border: 1px solid #ff9b58; border-radius: 999px; padding: 15px 22px; cursor: pointer; font-weight: 700 !important; box-shadow: 0 8px 32px #0005; min-height: 54px; }
.hdu-chat-launcher svg { width: 24px; height: 24px; }
.hdu-chat-launcher:hover { background: #ff9148; }
.hdu-unread { position: absolute; right: 0; top: -24px; background: #f7f1e9; color: #12100e; padding: 2px 10px; border-radius: 10px; font-size: 11px; }
.hdu-chat-panel { position: absolute; right: 0; bottom: 72px; width: 390px; max-width: calc(100vw - 32px); max-height: min(720px, calc(100dvh - 128px)); background: #171410; border: 1px solid #5a4836; border-radius: 18px; box-shadow: 0 20px 80px #0009; overflow: hidden; display: flex; flex-direction: column; }
.hdu-chat-header { display: flex; align-items: center; justify-content: space-between; flex-shrink: 0; padding: 23px 22px 18px; border-bottom: 1px solid #45382b; background: #211a13; }
.hdu-chat-header strong { display: block; font: 29px/1.15 Georgia,serif; }
.hdu-chat-header span { display: block; font-size: 12px; color: #c4b4a1; margin-top: 7px; }
.hdu-chat-close { border: 0; background: transparent; color: #eee3d5; font-size: 28px !important; cursor: pointer; width: 44px; height: 44px; border-radius: 50%; }
.hdu-chat-close:hover { background: #423327; }
.hdu-chat-content { overflow-y: auto; overscroll-behavior: contain; padding: 20px 22px; min-height: 0; }
.hdu-chat p { margin: 0 0 14px; }
.hdu-chat-intro { color: #ded2c4; }
.hdu-chat-explain { color: #c4b4a1; font-size: 13px; }
.hdu-chat-topics { display: flex; flex-wrap: wrap; gap: 7px; margin: 18px 0; }
.hdu-chat-topics button { border: 1px solid #68513c; border-radius: 20px; padding: 7px 11px; font-size: 12px; color: #e9d6c2; background: #271e16; cursor: pointer; }
.hdu-chat-topics button:hover { border-color: #f36a1b; color: #fff; }
.hdu-chat label { display: block; margin-bottom: 7px; color: #eee1d2; font-size: 13px; }
.hdu-chat input:not([type="checkbox"]):not([type="file"]), .hdu-chat textarea { display: block; width: 100%; padding: 10px 12px; border: 1px solid #68513c; border-radius: 7px; color: #f7f1e9; background: #0f0d0b; margin-bottom: 15px; font-size: 16px; min-height: 44px; }
.hdu-chat textarea { resize: vertical; max-height: 160px; }
.hdu-chat-primary { display: flex; align-items: center; justify-content: center; width: 100%; min-height: 48px; padding: 12px 15px; background: #f36a1b; color: #170e07 !important; font-weight: 700; text-decoration: none; border: 0; border-radius: 7px; cursor: pointer; margin: 14px 0; }
.hdu-chat-primary:hover { background: #ff9148; }
.hdu-chat-primary:disabled { opacity: .55; cursor: wait; }
.hdu-chat-small { font-size: 12px; color: #c6b6a5; }
.hdu-chat-book, .hdu-chat-connect { color: #ffac6c; text-decoration: underline; text-underline-offset: 3px; font-size: 13px; }
.hdu-chat-connect { display: block; margin: 12px 0; }
.hdu-chat-note { padding: 12px 22px; margin: 0 !important; font-size: 11px; color: #bdad9b; background: #211a13; flex-shrink: 0; border-top: 1px solid #45382b; }
.hdu-chat-error { color: #ffba8d; font-size: 13px; }
.hdu-chat-error:empty { display: none; }
.hdu-chat-consent { display: flex !important; gap: 10px; align-items: flex-start; margin: 16px 0 !important; }
.hdu-chat-consent input { flex-shrink: 0; margin-top: 4px; accent-color: #f36a1b; }
.hdu-chat-consent span { font-size: 12px; }
.hdu-chat-log { margin: 18px 0; }
.hdu-message { margin: 0 16px 12px 0; padding: 12px; background: #30251c; border-radius: 10px; overflow-wrap: anywhere; }
.hdu-message strong { display: block; font-size: 11px; color: #d6bea5; margin-bottom: 5px; }
.hdu-message p { white-space: pre-wrap; margin-bottom: 0; }
.hdu-message small { display: block; color: #c6b6a5; font-size: 10px; margin-top: 8px; }
.hdu-message-client { margin-left: 16px; margin-right: 0; background: #443021; }
.hdu-message-system { font-size: 12px; color: #cdbca7; background: transparent; border: 1px solid #45382b; }
.hdu-message img { display: block; max-width: 100%; height: auto; border-radius: 6px; margin-top: 8px; }
.hdu-chat-photo { cursor: pointer; color: #ffac6c !important; }
.hdu-chat-photo input { display: block; width: 100%; font-size: 12px; margin-top: 8px; }
.hdu-chat-composer > small { color: #bdad9b; font-size: 11px; }
.hdu-chat-forget { border: 0; background: transparent; color: #bdad9b; text-decoration: underline; padding: 14px 0 0; cursor: pointer; font-size: 11px !important; }
.hdu-chat :is(a,button,input,textarea):focus-visible { outline: 2px solid #ffad71; outline-offset: 3px; }
.hdu-chat { display: flex; flex-direction: row; align-items: center; gap: 0; padding: 5px; background: #171410; border: 1px solid #6b5945; border-radius: 8px; box-shadow: 0 6px 24px #0004; font-family: inherit; }
.hdu-chat-direct { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 14px; border-radius: 4px; background: #f47c20; color: #140d08 !important; font-size: 13px; font-weight: 700; text-decoration: none; white-space: nowrap; }
.hdu-chat-direct svg { width: 19px; height: 19px; flex-shrink: 0; }
.hdu-chat-direct:hover { background: #ff9148; }
.hdu-chat .hdu-chat-launcher { min-height: 44px; padding: 10px 13px; gap: 7px; background: transparent; color: #f4eee3; border: 0; border-radius: 4px; font-size: 12px; box-shadow: none; white-space: nowrap; }
.hdu-chat .hdu-chat-launcher:hover { background: #30271e; }
.hdu-chat .hdu-chat-launcher svg { width: 17px; height: 17px; }
.hdu-chat .hdu-chat-panel { bottom: 66px; max-height: calc(100dvh - 110px); }
@media(max-width: 600px) {
  .hdu-chat { right: 14px; bottom: max(18px, env(safe-area-inset-bottom)); }
  .hdu-chat-launcher { padding: 12px 16px; font-size: 13px; }
  .hdu-chat-panel { bottom: 66px; max-height: calc(100dvh - 110px); width: calc(100vw - 28px); }
  .hdu-chat-header { padding: 18px; }
  .hdu-chat-content { padding: 18px; }
}

.hdu-chat.hdu-chat-inline { position: relative; right: auto; bottom: auto; width: fit-content; max-width: 100%; margin: 20px 0 24px; z-index: 10; }
.hdu-chat.hdu-chat-inline .hdu-chat-panel { position: fixed; right: 24px; bottom: 24px; max-height: calc(100dvh - 48px); z-index: 99990; }
.hdu-chat.hdu-chat-inline:has(.hdu-chat-panel:not([hidden])) { z-index: 99990; }
@media(max-width: 600px) {
  .hdu-chat.hdu-chat-inline { margin-top: 20px; }
  .hdu-chat.hdu-chat-inline .hdu-chat-panel { right: 14px; bottom: max(14px, env(safe-area-inset-bottom)); max-height: calc(100dvh - 40px); }
}
