@font-face { font-family: "GoAITN Sans"; src: url("/fonts/AdwaitaSans-Regular.ttf") format("truetype"); font-weight: 100 900; font-display: block; }
:root { font-family: "GoAITN Sans", system-ui, sans-serif; color: #050a13; background: #fff; color-scheme: light; --blue: #176bff; }
* { box-sizing: border-box; }
html, body { margin: 0; width: 100%; height: 100%; overflow: hidden; }
button, textarea, a { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
[hidden] { display: none !important; }
svg { width: 23px; height: 23px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
a { color: var(--blue); }
:focus-visible { outline: 3px solid #176bff66; outline-offset: 3px; }
.chat-shell { position: fixed; top: var(--viewport-top, 0px); left: 0; right: 0; margin: auto; height: var(--viewport-height, 100dvh); max-width: 880px; display: grid; grid-template-rows: auto auto minmax(0, 1fr) auto; padding: 0 32px; }
.chat-header { height: 100px; display: flex; align-items: center; justify-content: space-between; flex-shrink: 0; }
.wordmark { font-size: 22px; font-weight: 800; letter-spacing: .26em; text-decoration: none; color: #050a13; white-space: nowrap; }
.wordmark span { color: var(--blue); }
.icon-button { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; flex: 0 0 44px; border: 0; padding: 0; border-radius: 50%; background: transparent; color: #050a13; text-decoration: none; }
.close-chat { border: 1px solid #050a1329; }
.icon-button:hover { background: #edf4ff; color: var(--blue); }
.chat-heading { padding: 16px 0 22px; }
h1 { font-size: 36px; letter-spacing: -.035em; margin: 0 0 8px; line-height: 1.1; }
.chat-heading p { font-size: 14px; color: #657184; margin: 0; line-height: 1.5; }
.conversation { overflow-y: auto; overflow-x: hidden; overscroll-behavior: contain; padding: 16px 0 24px; scrollbar-width: thin; }
.empty-state { min-height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 20px 24px 50px; }
.empty-state svg { width: 54px; height: 54px; color: var(--blue); stroke-width: 1.5; margin-bottom: 22px; }
.empty-state h2 { font-size: 23px; letter-spacing: -.035em; margin: 0 0 10px; }
.empty-state p { color: #657184; font-size: 14px; line-height: 1.6; max-width: 250px; margin: 0; text-wrap: pretty; }
#messages { display: flex; flex-direction: column; gap: 20px; }
.message { max-width: 82%; align-self: flex-start; min-width: 0; }
.message.visitor { align-self: flex-end; }
.message-bubble { background: #f0f4fa; border-radius: 17px 17px 17px 4px; padding: 13px 17px; overflow-wrap: anywhere; }
.visitor .message-bubble { background: var(--blue); color: #fff; border-radius: 17px 17px 4px 17px; }
.message-text { margin: 0; white-space: pre-wrap; font-size: 16px; line-height: 1.5; }
.message-meta { margin-top: 6px; color: #6c7583; font-size: 11px; }
.visitor .message-meta { text-align: right; }
.download-file { display: flex; align-items: center; gap: 9px; border: 1px solid #050a1326; color: inherit; background: transparent; border-radius: 9px; padding: 10px; margin-top: 9px; text-align: left; max-width: 100%; }
.download-file:first-child { margin-top: 0; }
.download-file span { overflow-wrap: anywhere; min-width: 0; }
.visitor .download-file { border-color: #ffffff66; }
.download-file svg { flex-shrink: 0; width: 18px; height: 18px; }
.composer { min-width: 0; padding: 14px 0 max(18px, env(safe-area-inset-bottom)); background: white; }
.composer-row { display: flex; gap: 6px; align-items: flex-end; border: 1px solid #d7e1ee; border-radius: 22px; padding: 7px; background: #fafcff; }
.composer-row:focus-within { border-color: var(--blue); }
textarea { resize: none; border: 0; padding: 11px 2px; line-height: 22px; height: 44px; max-height: 128px; width: 100%; min-width: 0; outline: none !important; background: transparent; font-size: 16px; color: #050a13; }
textarea::placeholder { color: #778394; }
.attach-button { color: #64748b; }
.send-button { position: relative; background: var(--blue); color: #fff; }
.send-attachment-count { position: absolute; top: -4px; right: -4px; display: grid; place-items: center; width: 20px; height: 20px; padding: 0; border: 2px solid #fff; border-radius: 50%; background: var(--blue); color: #fff; font-size: 11px; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; pointer-events: none; }
/* Optically center the diagonal plane, not just its square SVG bounds. */
.send-button svg { display: block; flex: none; transform: translate(-1px, 1px); }
.send-button:hover { background: #0d61f3; color: #fff; }
.send-button:disabled { background: #e6edf6; color: #98a8be; cursor: default; }
.composer-hint { margin: 9px 0 0; font-size: 11px; color: #738093; text-align: center; }
.composer-hint[data-pending="true"] { display: block; color: var(--blue); }
.attachments { display: flex; gap: 7px; overflow-x: auto; padding-bottom: 10px; }
.attachment { display: flex; align-items: center; gap: 7px; border: 1px solid #d7e1ee; border-radius: 10px; padding: 3px 4px 3px 10px; font-size: 12px; flex: 0 0 auto; }
.attachment span { max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.attachment button { border: 0; background: transparent; width: 32px; height: 32px; border-radius: 5px; font-size: 20px; color: #657184; }
.chat-status { font-size: 13px; line-height: 1.4; color: #a12a2a; margin: 0 0 10px; }
@media (max-width: 600px) {
  .chat-shell { padding-inline: 20px; }
  .chat-header { height: 80px; }
  .wordmark { font-size: 18px; letter-spacing: .23em; }
  .chat-heading { padding: 17px 0; }
  h1 { font-size: 32px; }
  .message { max-width: 88%; }
  .composer { padding-top: 8px; }
}
@media (max-height: 500px) {
  .chat-header { height: 54px; }
  .chat-heading { padding: 0 0 6px; }
  h1 { font-size: 23px; margin-bottom: 3px; }
  .chat-heading p { font-size: 12px; }
  .composer { padding-bottom: max(6px, env(safe-area-inset-bottom)); }
  .composer-hint { display: none; }
  .empty-state { padding: 12px; }
  .empty-state svg { display: none; }
}
