.awn-widget { --awn-navy:#2c2f7f; --awn-blue:#5690cc; --awn-ink:#24284e; --awn-border:#e0e5f1; font-family:var(--swaj-arabic-font,'GE SS Two',Arial,sans-serif); color:var(--awn-ink); font-size:14px; font-weight:var(--swaj-arabic-regular,300); line-height:1.8; }
.awn-widget *, .awn-widget *::before, .awn-widget *::after { box-sizing:border-box; }
.awn-widget [hidden] { display:none !important; }
.awn-widget button, .awn-widget textarea { font-family:inherit; font-size:inherit; }
.awn-widget button { cursor:pointer; }
.awn-widget button:disabled { cursor:default; opacity:.5; }
.awn-widget :is(button,a,textarea):focus-visible { outline:3px solid var(--awn-blue); outline-offset:3px; }
.awn-widget svg { width:20px; height:20px; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; flex-shrink:0; }
.awn-launcher { position:fixed; left:max(20px,env(safe-area-inset-left)); bottom:max(22px,env(safe-area-inset-bottom)); z-index:70; display:flex; align-items:center; gap:5px; width:88px; min-height:56px; padding:6px 10px 6px 6px; border:1px solid #dce4f2; border-radius:30px; color:var(--awn-navy); background:#fff; box-shadow:0 5px 24px #17194b24; transition:box-shadow .2s,translate .2s; }
.awn-launcher:hover { translate:0 -2px; box-shadow:0 8px 28px #17194b30; }
.awn-launcher img { display:block; width:44px; height:44px; object-fit:contain; flex-shrink:0; }
.awn-launcher-label { font-size:16px; font-weight:700; line-height:1.4; }
.awn-dialog { position:fixed; inset:auto auto max(90px,calc(env(safe-area-inset-bottom) + 76px)) max(20px,env(safe-area-inset-left)); z-index:100; width:min(400px,calc(100vw - 40px)); height:min(640px,calc(100dvh - 120px)); max-width:none; max-height:none; margin:0; padding:0; overflow:hidden; border:1px solid #d9e1ef; border-radius:22px; background:#fff; color:var(--awn-ink); box-shadow:0 20px 70px #14143b3b; opacity:0; translate:0 16px; scale:.985; transition:opacity 180ms ease,translate 220ms cubic-bezier(.2,.7,.3,1),scale 220ms cubic-bezier(.2,.7,.3,1); }
.awn-dialog[open] { display:flex; flex-direction:column; }
.awn-dialog[data-open='true'] { opacity:1; translate:0 0; scale:1; }
.awn-dialog::backdrop { background:#11132c12; }
.awn-header { display:flex; flex-shrink:0; align-items:center; justify-content:space-between; gap:10px; padding:16px 17px; border-bottom:1px solid var(--awn-border); background:#fafbfe; }
.awn-brand { display:flex; align-items:center; gap:10px; min-width:0; }
.awn-brand > img { display:block; width:45px; height:45px; object-fit:contain; flex-shrink:0; }
.awn-brand-copy h2 { margin:0; color:var(--awn-navy); font-family:inherit; font-size:20px; font-weight:700; line-height:1.45; }
.awn-brand-copy p { margin:2px 0 0; font-size:11px; color:#66708a; line-height:1.6; font-weight:400; }
.awn-scope { flex-shrink:0; margin:0; padding:10px 16px; border-bottom:1px solid var(--awn-border); background:#f4f8fd; color:#66728e; font-size:11px; line-height:1.9; }
.awn-header-actions { display:flex; gap:4px; }
.awn-icon-button { display:grid; place-items:center; width:34px; height:38px; border:0; border-radius:9px; background:transparent; color:#5e6784; padding:0; }
.awn-icon-button:hover { background:#e9eef8; color:var(--awn-navy); }
.awn-content { flex:1; min-height:0; overflow:auto; overscroll-behavior:contain; scrollbar-width:thin; scrollbar-color:#c8d4e8 transparent; padding:20px 16px; }
.awn-intro { padding:13px 2px 16px; }
.awn-greeting { font-size:17px; font-weight:600; line-height:2; margin:0 0 22px; color:var(--awn-navy); }
.awn-suggestions { display:flex; flex-direction:column; align-items:flex-start; gap:8px; }
.awn-suggestions button { width:auto; max-width:100%; text-align:start; border:1px solid var(--awn-border); border-radius:11px; color:#46517d; background:#fff; padding:8px 12px; font-size:13px; font-weight:500; line-height:1.8; transition:background .2s,border-color .2s; }
.awn-suggestions button:hover { background:#f1f6fc; border-color:#a7c1e1; }
.awn-messages { display:flex; flex-direction:column; gap:18px; min-width:0; outline-offset:0; }
.awn-message { width:100%; max-width:100%; overflow-wrap:anywhere; min-width:0; }
.awn-message-author { display:block; font-size:11px; font-weight:600; color:#7a839a; margin-bottom:5px; }
.awn-message-text { font-size:14px; line-height:2; white-space:pre-wrap; text-align:start; overflow-wrap:anywhere; word-break:normal; }
.awn-message-text:empty::after { content:'…'; color:#8e98af; }
.awn-message-text a { color:#386dab; text-decoration:underline; text-underline-offset:4px; }
.awn-message-text strong { font-weight:700; }
.awn-message-user { align-self:flex-start; width:auto; max-width:92%; padding:10px 13px; border:1px solid #e2e7f4; border-radius:13px 3px 13px 13px; background:#f1f4fc; }
.awn-message-user .awn-message-author { color:#56618f; }
.awn-message-assistant { padding:0 2px; }
.awn-message-assistant .awn-message-author { color:var(--awn-blue); }
.awn-message-meta { display:block; font-size:11px; line-height:1.8; margin-top:7px; color:#8a6871; }
.awn-message-meta:empty { display:none; }
.awn-loading { display:flex; align-items:center; gap:4px; margin-top:16px; color:#76819b; font-size:11px; }
.awn-loading span { margin-inline-start:6px; }
.awn-loading i { display:block; width:5px; height:5px; border-radius:50%; background:var(--awn-blue); animation:awn-loading-dot 1s ease-in-out infinite; }
.awn-loading i:nth-child(2) { animation-delay:.12s; }
.awn-loading i:nth-child(3) { animation-delay:.24s; }
@keyframes awn-loading-dot { 0%,65%,100% { opacity:.35; translate:0 0; } 30% { opacity:1; translate:0 -3px; } }
.awn-error { background:#fff8f6; color:#82554d; border:1px solid #f0ddd7; border-radius:10px; padding:10px 12px; margin-top:16px; font-size:12px; }
.awn-error p { margin:0; font-size:inherit; line-height:1.9; }
.awn-retry { display:inline-flex; align-items:center; gap:6px; border:0; background:transparent; color:var(--awn-navy); padding:7px 0 0; font-weight:600; font-size:12px; }
.awn-retry svg { width:16px; height:16px; }
.awn-service-contact { display:inline-block; color:var(--awn-navy); font-weight:600; font-size:12px; margin-inline-start:12px; padding-top:7px; text-decoration:underline; text-underline-offset:3px; }
.awn-footer { flex-shrink:0; border-top:1px solid var(--awn-border); padding:12px 14px 11px; background:#fff; }
.awn-composer { display:flex; align-items:flex-end; gap:7px; border:1px solid #d3dced; border-radius:13px; padding:6px; background:#fff; }
.awn-composer:focus-within { border-color:var(--awn-blue); box-shadow:0 0 0 2px #5690cc14; }
.awn-composer textarea { display:block; flex:1; min-width:0; width:100%; min-height:38px; max-height:110px; resize:none; border:0; border-radius:0; outline:none; box-shadow:none; color:var(--awn-ink); background:transparent; padding:7px 6px; font-size:14px; font-weight:400; line-height:1.8; }
.awn-composer textarea:focus-visible { outline:none; }
.awn-composer textarea::placeholder { color:#9aa4b9; }
.awn-send,.awn-stop { display:grid; place-items:center; width:38px; height:38px; padding:0; flex-shrink:0; border:0; border-radius:9px; background:var(--awn-navy); color:#fff; }
.awn-send:hover,.awn-stop:hover { background:#3b4496; }
.awn-stop svg { fill:currentColor; width:15px; height:15px; }
.awn-input-hint { font-size:9px; margin:5px 3px 8px; color:#8a94aa; line-height:1.7; direction:rtl; }
.awn-footnote { display:flex; align-items:flex-end; gap:8px; }
.awn-privacy { flex:1; margin:0; font-size:9px; color:#8c95a9; line-height:1.8; }
.awn-delete { display:inline-flex; align-items:center; gap:3px; flex-shrink:0; border:0; padding:3px 0; background:transparent; color:#78829c; font-size:9px; line-height:1.8; }
.awn-delete svg { width:12px; height:12px; }
.awn-delete:hover { color:var(--awn-navy); }
.awn-sr-only { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }
@media (max-width:600px) {
  .awn-launcher { left:max(13px,env(safe-area-inset-left)); bottom:max(14px,env(safe-area-inset-bottom)); width:78px; min-height:50px; padding:5px 9px 5px 5px; gap:4px; }
  .awn-launcher img { width:39px; height:39px; }
  .awn-launcher-label { font-size:15px; }
  .awn-dialog { inset:auto 12px auto 12px; top:calc(var(--awn-vtop,0px) + 12px + env(safe-area-inset-top)); width:calc(100vw - 24px); height:calc(var(--awn-vh,100dvh) - 24px - env(safe-area-inset-top) - env(safe-area-inset-bottom)); max-height:800px; border-radius:18px; }
  .awn-dialog::backdrop { background:#10112c70; }
  .awn-header { padding:12px 13px; }
  .awn-brand > img { width:40px; height:40px; }
  .awn-brand-copy h2 { font-size:19px; }
  .awn-content { padding:17px 14px; }
  .awn-message-text { font-size:15px; line-height:2; }
  .awn-composer textarea { font-size:16px; }
  .awn-icon-button { width:38px; height:40px; }
  .awn-footer { padding:10px 12px 12px; }
  .awn-footnote { align-items:center; }
  .awn-privacy { font-size:10px; }
  .awn-delete { min-height:32px; font-size:10px; }
  .awn-icon-button { width:42px; height:44px; }
  .awn-send,.awn-stop { width:42px; height:42px; }
}
@media (max-height:530px) {
  .awn-dialog { height:calc(var(--awn-vh,100dvh) - 20px); top:calc(var(--awn-vtop,0px) + 10px); bottom:auto; }
  .awn-header { padding-block:8px; }
  .awn-input-hint { display:none; }
  .awn-privacy { font-size:8px; }
}
html[data-motion-paused='true'] .awn-widget *, html[data-motion-paused='true'] .awn-widget *::before { transition:none !important; animation:none !important; }
@media (prefers-reduced-motion:reduce) { .awn-widget *, .awn-widget *::before { transition:none !important; animation:none !important; } }
