/*
 * Get-AI public chat, style C "modern cards" (1.1 phase 16, A8): /chat, the widget's frame (/chat?embed=1) and the
 * home page's box. A gradient header from the buyer's brand colour (--brand; color-mix where the browser has it, the
 * plain colour elsewhere), message cards with soft shadows, big source cards, a rounded input bar, the model card.
 * Light / dark follow the Kit's theme tokens. Motion only under prefers-reduced-motion: no-preference.
 * Mobile first from 320 px without sideways scrolling.
 */
.gai-chat-page { padding-block: var(--space-6) var(--space-10); }

.gai-chat, .lp-chat, .gai-model {
  --gai-grad: var(--brand);
  --gai-tint: var(--bg-subtle);
  --gai-on: var(--brand-fg);
}
@supports (color: color-mix(in oklch, red, blue)) {
  .gai-chat, .lp-chat, .gai-model {
    --gai-grad: linear-gradient(135deg, var(--brand) 0%, color-mix(in oklch, var(--brand) 68%, #6d28d9) 100%);
    --gai-tint: color-mix(in srgb, var(--brand) 6%, var(--bg-subtle));
  }
}

.gai-chat {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  max-width: 860px;
  margin-inline: auto;
  min-width: 0;
  padding-bottom: var(--space-4);
  border: 1px solid var(--border);
  border-radius: 22px;
  background: var(--surface);
  box-shadow: var(--shadow-lg);
}
.gai-chat * { min-width: 0; }
.gai-chat > :not(.gai-chat-head, .gai-chat-log, script) { margin-inline: var(--space-4); }

/* ---- header ---- */
.gai-chat-head {
  position: relative;
  z-index: 3;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2) var(--space-3);
  padding: var(--space-3) var(--space-4);
  border-radius: 21px 21px 0 0;
  background: var(--brand);
  background: radial-gradient(circle at 100% 0, rgb(255 255 255 / .18), transparent 46%), var(--gai-grad);
  color: var(--gai-on);
}
.gai-chat-avatar, .gai-msg-avatar {
  display: inline-grid; place-items: center; flex: none;
  width: 40px; height: 40px; border-radius: 50%;
  background: rgb(255 255 255 / .2); box-shadow: inset 0 0 0 1px rgb(255 255 255 / .35);
}
.gai-chat-avatar .icon { width: 22px; height: 22px; }
.gai-chat-title { flex: 1 1 9rem; }
.gai-chat-title h1, .gai-chat-title h2 {
  margin: 0; color: inherit; font-size: var(--text-lg); line-height: var(--leading-tight);
  letter-spacing: -0.01em; overflow-wrap: anywhere;
}
.gai-chat-sub { display: flex; align-items: center; gap: 6px; margin: 2px 0 0; font-size: var(--text-xs); opacity: .92; }
.gai-chat-dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: #4ade80; box-shadow: 0 0 0 2px rgb(255 255 255 / .35); }
.gai-chat-tools { display: flex; flex-wrap: wrap; gap: var(--space-1); margin-inline-start: auto; }
.gai-chat-tools [hidden] { display: none; }
.gai-head-btn, .gai-model-badge {
  display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 0 var(--space-3);
  border: 1px solid rgb(255 255 255 / .38); border-radius: var(--radius-full);
  background: rgb(255 255 255 / .16); color: inherit; font: inherit; font-size: var(--text-xs); font-weight: 600;
  text-decoration: none; cursor: pointer; white-space: nowrap;
}
.gai-head-btn:hover, .gai-model-badge:hover { background: rgb(255 255 255 / .28); color: inherit; }
.gai-head-btn:focus-visible, .gai-model-badge:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }
.gai-head-btn .icon { width: 16px; height: 16px; }
@media (max-width: 639px) {
  .gai-head-btn { padding: 0 9px; }
  .gai-head-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
}

/* ---- the model badge and card ---- */
.gai-model > summary { list-style: none; }
.gai-model > summary::-webkit-details-marker { display: none; }
.gai-model-caret { width: 14px; height: 14px; transition: transform var(--duration) var(--ease); }
.gai-model[open] .gai-model-caret { transform: rotate(180deg); }
.gai-model-card {
  position: absolute; z-index: 5; top: calc(100% - 4px); inset-inline: var(--space-3);
  max-height: min(70vh, 32rem); overflow-y: auto;
  padding: var(--space-4); border: 1px solid var(--border); border-radius: 18px;
  background: var(--surface); color: var(--text); box-shadow: var(--shadow-xl);
  font-size: var(--text-sm); line-height: var(--leading-normal);
}
@media (min-width: 640px) { .gai-model-chat .gai-model-card { inset-inline: auto var(--space-4); width: 380px; } }
.gai-model-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--space-2); margin: 0; font-size: var(--text-lg); }
.gai-model-version { color: var(--text-muted); font-size: var(--text-xs); }
.gai-model-about { margin: var(--space-1) 0 0; color: var(--text-muted); }
.gai-model-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-2); margin: var(--space-3) 0 0; }
.gai-model-stats > div { padding: var(--space-2) var(--space-3); border-radius: 12px; background: var(--gai-tint); }
.gai-model-stats .gai-model-wide { grid-column: 1 / -1; }
.gai-model-stats dt { color: var(--text-muted); font-size: var(--text-xs); }
.gai-model-stats dd { margin: 0; font-weight: 700; overflow-wrap: anywhere; }
.gai-model-lists { display: grid; gap: var(--space-3); margin-top: var(--space-3); }
.gai-model-list-title { margin: 0 0 var(--space-1); font-weight: 700; }
.gai-model-lists ul { display: grid; gap: 4px; margin: 0; padding: 0; list-style: none; }
.gai-model-lists li { position: relative; padding-inline-start: 18px; color: var(--text-muted); }
.gai-model-lists li::before { content: ""; position: absolute; inset-inline-start: 2px; top: .55em; width: 8px; height: 8px; border-radius: 50%; background: var(--success); }
.gai-model-can li::before { background: var(--success); }
.gai-model-cannot li::before { background: var(--danger); }
.gai-model-label { max-width: 14ch; overflow: hidden; text-overflow: ellipsis; }
.gai-model-admin { position: relative; display: inline-block; }
.gai-model-admin .gai-model-badge { border-color: var(--brand-border); background: var(--brand-soft); color: var(--brand-text); }
/* Try it: the badge stays at the end of the page head (also when the head wraps), and its card opens from there
   toward the start, so it never runs past the right edge (phase 18 sweep: at 1366 px it ended at 1606 px). */
.admin-page-head > .gai-model-admin { margin-inline-start: auto; }
.gai-model-admin .gai-model-card { inset-inline: auto 0; width: min(380px, calc(100vw - 3rem)); }

/* ---- messages ---- */
.gai-chat-log {
  display: flex; flex-direction: column; gap: var(--space-4);
  min-height: 16rem; max-height: min(62vh, 38rem);
  overflow-y: auto; overflow-x: hidden; overscroll-behavior: contain;
  padding: var(--space-5) var(--space-4);
  background: var(--gai-tint);
  border-block: 1px solid var(--border);
}
.gai-chat-log:focus-visible { outline: 2px solid var(--brand-ring); outline-offset: -2px; }
.gai-chat-empty { display: grid; justify-items: center; gap: var(--space-2); margin: auto; max-width: 34rem; text-align: center; }
.gai-chat-empty[hidden] { display: none; }
.gai-empty-icon { display: inline-grid; place-items: center; width: 52px; height: 52px; border-radius: 16px; background: var(--gai-grad); color: var(--gai-on); box-shadow: var(--shadow-md); }
.gai-empty-title { margin: 0; font-weight: 600; }
.gai-chat-intro, .gai-chat-note { margin: 0; color: var(--text-muted); font-size: var(--text-sm); line-height: var(--leading-normal); }
.gai-chat-note { text-align: center; }

.gai-msg { position: relative; display: flex; flex-direction: column; max-width: 100%; }
.gai-msg-visitor { align-items: flex-end; }
.gai-msg-bot { align-items: flex-start; padding-inline-start: 40px; }
.gai-msg-avatar { position: absolute; inset-inline-start: 0; top: 0; width: 30px; height: 30px; background: var(--gai-grad); color: var(--gai-on); box-shadow: var(--shadow-sm); }
.gai-msg-avatar .icon { width: 16px; height: 16px; }
.gai-bubble {
  max-width: min(100%, 40rem);
  padding: var(--space-3) var(--space-4);
  line-height: var(--leading-normal);
  overflow-wrap: anywhere;
}
.gai-bubble p { margin: 0; }
.gai-bubble p + p { margin-top: var(--space-2); }
.gai-msg-visitor .gai-bubble {
  border-radius: 20px 20px 6px 20px;
  background: var(--brand); background: var(--gai-grad); color: var(--gai-on);
  box-shadow: 0 8px 20px -10px rgb(15 23 41 / .45);
}
.gai-msg-bot .gai-bubble {
  border: 1px solid var(--border); border-radius: 6px 20px 20px 20px;
  background: var(--surface); color: var(--text);
  box-shadow: 0 1px 2px rgb(15 23 41 / .05), 0 10px 24px -14px rgb(15 23 41 / .3);
}

/* ---- source cards ---- */
.gai-sources {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr)); gap: var(--space-2);
  width: min(100%, 40rem); margin: var(--space-2) 0 0; padding: 0; list-style: none;
}
.gai-source-card {
  position: relative;
  display: grid; grid-template-columns: 36px minmax(0, 1fr); align-items: center; gap: 2px var(--space-3);
  padding: var(--space-2) var(--space-3);
  border: 1px solid var(--border); border-radius: 14px; background: var(--surface); box-shadow: var(--shadow-sm);
  transition: border-color var(--duration) var(--ease), box-shadow var(--duration) var(--ease), transform var(--duration) var(--ease);
}
.gai-source-card:hover { border-color: var(--brand-border); box-shadow: var(--shadow-md); }
.gai-source-icon { grid-row: span 2; width: 36px; height: 36px; padding: 9px; box-sizing: border-box; border-radius: 10px; background: var(--brand-soft); color: var(--brand-text); }
.gai-source { display: grid; color: var(--text); text-decoration: none; }
.gai-source::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.gai-source:focus-visible { outline: none; }
.gai-source-card:focus-within { box-shadow: 0 0 0 3px var(--brand-ring); }
.gai-source-title { font-size: var(--text-sm); font-weight: 650; line-height: var(--leading-snug); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gai-source-host { color: var(--text-muted); font-size: var(--text-xs); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gai-licence {
  position: relative; z-index: 1; justify-self: start; grid-column: 2;
  padding: 0 6px; border-radius: var(--radius-full); background: var(--bg-muted);
  color: var(--text-muted); font-size: 11px; text-decoration: none;
}
a.gai-licence:hover { color: var(--brand-text); text-decoration: underline; }

/* ---- answer actions ---- */
.gai-actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-1); margin-top: var(--space-2); }
.gai-action {
  display: inline-flex; align-items: center; justify-content: center; gap: 4px; min-height: 32px; min-width: 32px; padding: 2px 10px;
  border: 1px solid var(--border); border-radius: var(--radius-full); background: var(--surface); color: var(--text-muted);
  font: inherit; font-size: var(--text-xs); cursor: pointer;
}
.gai-action:hover { border-color: var(--brand-border); background: var(--brand-soft); color: var(--brand-text); }
.gai-action:focus-visible { outline: 2px solid var(--brand-ring); outline-offset: 1px; }
.gai-action svg { width: 15px; height: 15px; flex: none; }
.gai-action[aria-pressed="true"] { border-color: var(--brand-border); background: var(--brand-soft); color: var(--brand-text); }

.gai-typing .gai-bubble { padding-block: var(--space-3); }
.gai-dots { display: inline-flex; gap: 5px; }
.gai-dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--text-subtle); opacity: .7; }

/* ---- suggestions, errors, the input bar ---- */
.gai-suggest[hidden] { display: none; }
.gai-suggest-title { margin: 0 0 var(--space-2); font-size: var(--text-sm); color: var(--text-muted); }
.gai-suggest ul { display: flex; flex-wrap: wrap; gap: var(--space-2); margin: 0; padding: 0; list-style: none; }
.gai-suggest li { max-width: 100%; }
.gai-chip {
  max-width: 100%; min-height: 36px; padding: var(--space-1) var(--space-3);
  border: 1px solid var(--border-strong); border-radius: var(--radius-full); background: var(--surface); color: var(--text);
  font: inherit; font-size: var(--text-sm); text-align: start; cursor: pointer; overflow-wrap: anywhere; box-shadow: var(--shadow-xs);
}
.gai-chip:hover { border-color: var(--brand-border); background: var(--brand-soft); color: var(--brand-text); }
.gai-chip:focus-visible { outline: 2px solid var(--brand-ring); outline-offset: 2px; }

.gai-chat-error { display: flex; gap: var(--space-2); align-items: center; margin: 0; padding: var(--space-2) var(--space-3); border-radius: 12px; background: var(--danger-soft); color: var(--danger); font-size: var(--text-sm); }
.gai-chat-error[hidden] { display: none; }

.gai-chat-form {
  display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: end; gap: var(--space-1);
  padding: 6px 6px 6px var(--space-4);
  border: 1px solid var(--border-strong); border-radius: 26px; background: var(--surface); box-shadow: var(--shadow-sm);
  transition: border-color var(--duration) var(--ease), box-shadow var(--duration) var(--ease);
}
.gai-chat-form:focus-within { border-color: var(--brand); box-shadow: 0 0 0 4px var(--brand-ring); }
.gai-input {
  width: 100%; min-height: 44px; max-height: 160px; padding: 10px 0; resize: none;
  border: 0; background: transparent; color: var(--text); font: inherit; font-size: var(--text-base); line-height: var(--leading-snug);
}
.gai-input:focus { outline: none; }
.gai-form-tools { display: inline-flex; gap: 2px; }
.gai-form-tools:empty { display: none; }
.gai-tool {
  display: inline-grid; place-items: center; width: 44px; height: 44px; padding: 0;
  border: 0; border-radius: 50%; background: transparent; color: var(--text-muted); cursor: pointer;
}
.gai-tool:hover, .gai-tool[aria-pressed="true"] { background: var(--brand-soft); color: var(--brand-text); }
.gai-tool:focus-visible { outline: 2px solid var(--brand-ring); outline-offset: 1px; }
.gai-tool svg { width: 20px; height: 20px; }
.gai-send {
  display: inline-grid; place-items: center; width: 44px; height: 44px; padding: 0;
  border: 0; border-radius: 50%; background: var(--brand); background: var(--gai-grad); color: var(--gai-on);
  box-shadow: 0 6px 16px -8px rgb(15 23 41 / .5); cursor: pointer;
}
.gai-send:hover { filter: brightness(1.08); }
.gai-send:focus-visible { outline: 2px solid var(--brand-ring); outline-offset: 2px; }
.gai-send:disabled { opacity: .6; cursor: default; }
.gai-send .icon { width: 20px; height: 20px; }
.gai-hint { margin: calc(-1 * var(--space-2)) var(--space-4) 0; padding-inline: var(--space-4); font-size: var(--text-xs); color: var(--text-subtle); }
.gai-privacy { margin: 0; font-size: var(--text-xs); color: var(--text-subtle); line-height: var(--leading-normal); }

.gai-history { padding: var(--space-3); border: 1px solid var(--border); border-radius: 16px; background: var(--surface); }
.gai-history[hidden] { display: none; }
.gai-history h3 { margin: 0 0 var(--space-2); font-size: var(--text-base); }
.gai-history ul { display: flex; flex-direction: column; gap: var(--space-1); margin: 0; padding: 0; list-style: none; max-height: 14rem; overflow-y: auto; }
.gai-history-item {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--space-2); width: 100%; padding: var(--space-2);
  border: 0; border-radius: 10px; background: transparent; color: var(--text); font: inherit; text-align: start; cursor: pointer;
}
.gai-history-item:hover { background: var(--bg-muted); }
.gai-history-item small { color: var(--text-muted); }

.gai-home-chat { padding-block: var(--space-6) var(--space-10); }

/* ---- the widget's frame: the whole window is the chat ---- */
.gai-embed-body { margin: 0; background: var(--bg); }
.gai-embed { display: flex; flex-direction: column; height: 100vh; height: 100dvh; box-sizing: border-box; }
.gai-chat-embed { flex: 1; width: 100%; max-width: none; min-height: 0; padding-bottom: var(--space-2); border: 0; border-radius: 0; box-shadow: none; gap: var(--space-2); }
.gai-chat-embed .gai-chat-head { border-radius: 0; padding: var(--space-2) var(--space-3); }
.gai-chat-embed > :not(.gai-chat-head, .gai-chat-log, script) { margin-inline: var(--space-3); }
.gai-chat-embed .gai-chat-log { flex: 1; max-height: none; min-height: 6rem; padding: var(--space-4) var(--space-3); }
.gai-chat-embed .gai-hint { display: none; }
.gai-chat-embed .gai-privacy { font-size: 11px; }

@media (min-width: 768px) {
  .gai-chat-log { padding: var(--space-6) var(--space-6); }
  .gai-chat-head { padding: var(--space-4) var(--space-5); }
  .gai-chat-title h1, .gai-chat-title h2 { font-size: var(--text-xl); }
  .gai-chat > :not(.gai-chat-head, .gai-chat-log, script) { margin-inline: var(--space-5); }
  .gai-chat-embed > :not(.gai-chat-head, .gai-chat-log, script) { margin-inline: var(--space-3); }
}

/* ---- 1.1 phase 17 (A9): notes, other language, share, reactions + why, edit, the drawer ---- */
.gai-note { margin: var(--space-2) 0 0; padding: var(--space-2) var(--space-3); border-radius: 12px; background: var(--brand-soft); color: var(--text); font-size: var(--text-sm); }
.gai-note-learning { border-inline-start: 3px solid var(--brand); }
.gai-note-limit, .gai-msg-limit .gai-bubble { background: var(--warning-soft); }
.gai-note-learned { padding: var(--space-2) var(--space-3); border-radius: 12px; background: var(--success-soft); color: var(--text); }
.gai-typing-text { cursor: pointer; }
.gai-action-primary { border-color: transparent; background: var(--brand); color: var(--brand-fg); font-weight: 600; }
.gai-action-primary:hover { background: var(--brand-hover); color: var(--brand-fg); }
.gai-action-primary:disabled { opacity: .5; cursor: default; }
.gai-lang-switch span { font-weight: 600; }
.gai-share { position: relative; }
.gai-share > summary { list-style: none; }
.gai-share > summary::-webkit-details-marker { display: none; }
.gai-share-menu { position: absolute; z-index: 4; top: calc(100% + 6px); inset-inline-end: 0; display: grid; min-width: 14rem; max-width: 78vw; padding: 6px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface); box-shadow: var(--shadow-lg); }
.gai-share-item { display: flex; align-items: center; gap: var(--space-2); padding: var(--space-2); border: 0; border-radius: 10px; background: none; color: var(--text); font: inherit; font-size: var(--text-sm); text-align: start; text-decoration: none; cursor: pointer; }
.gai-share-item:hover { background: var(--bg-muted); color: var(--text); }
.gai-reacts { display: inline-flex; flex-wrap: wrap; gap: 2px; }
.gai-react { display: inline-grid; place-items: center; width: 32px; height: 32px; padding: 0; border: 1px solid transparent; border-radius: 50%; background: none; cursor: pointer; filter: grayscale(.6); opacity: .8; }
.gai-react:hover, .gai-react[aria-pressed="true"] { border-color: var(--brand-border); background: var(--brand-soft); filter: none; opacity: 1; }
.gai-react:focus-visible { outline: 2px solid var(--brand-ring); }
.gai-emoji { font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif; font-size: 17px; line-height: 1; }
.gai-why, .gai-edit-form { display: grid; gap: var(--space-2); width: min(100%, 30rem); margin-top: var(--space-2); padding: var(--space-3); border: 1px solid var(--border); border-radius: 16px; background: var(--surface); box-shadow: var(--shadow-sm); }
.gai-why-title { margin: 0; font-weight: 600; font-size: var(--text-sm); }
.gai-why-choices, .gai-why-row { display: flex; flex-wrap: wrap; gap: var(--space-1); }
.gai-why-chip[aria-checked="true"] { border-color: var(--brand); background: var(--brand-soft); color: var(--brand-text); }
.gai-why-input { width: 100%; padding: var(--space-2); border: 1px solid var(--border-strong); border-radius: 10px; background: var(--bg); color: var(--text); font: inherit; font-size: var(--text-sm); resize: vertical; }
.gai-edit-form { justify-self: end; width: min(100%, 34rem); }
.gai-edit-input { min-height: 3rem; padding: var(--space-2); border: 1px solid var(--border-strong); border-radius: 10px; }
.gai-actions-visitor { justify-content: flex-end; margin-top: 4px; }
.gai-edit { border-color: transparent; background: none; }
.gai-voice-note { margin: 0; padding: var(--space-2) var(--space-3); border-radius: 12px; background: var(--info-soft); font-size: var(--text-xs); }
.gai-drawer {
  position: absolute; z-index: 6; inset-block: 0; inset-inline-start: 0; display: flex; flex-direction: column; gap: var(--space-2);
  width: min(330px, 88%); padding: var(--space-3); border-inline-end: 1px solid var(--border); border-radius: 22px 0 0 22px;
  background: var(--surface); box-shadow: var(--shadow-xl);
}
.gai-drawer[hidden] { display: none; }
.gai-chat-embed .gai-drawer { border-radius: 0; }
.gai-drawer-head { display: flex; align-items: center; justify-content: space-between; }
.gai-drawer-title { margin: 0; font-weight: 700; }
.gai-drawer-close { width: 36px; height: 36px; }
.gai-drawer-note, .gai-drawer-empty { margin: 0; color: var(--text-muted); font-size: var(--text-xs); }
.gai-drawer-list { flex: 1; display: grid; align-content: start; gap: 2px; margin: 0; padding: 0; list-style: none; overflow-y: auto; }
.gai-drawer-row { display: flex; align-items: center; gap: 2px; border-radius: 12px; }
.gai-drawer-row:hover { background: var(--bg-muted); }
.gai-drawer-item { display: grid; flex: 1; padding: var(--space-2); border: 0; border-radius: 12px; background: none; color: var(--text); font: inherit; text-align: start; cursor: pointer; }
.gai-drawer-item[aria-current="true"] { background: var(--brand-soft); }
.gai-drawer-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: var(--text-sm); font-weight: 600; }
.gai-drawer-item small { color: var(--text-muted); font-size: 11px; }
.gai-drawer-tools { display: inline-flex; }
.gai-drawer-tools .gai-action { border-color: transparent; background: none; }
.gai-drawer-foot { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.gai-drawer-open .gai-chat-log { overflow: hidden; }

@media print {
  .gai-print-one body * { visibility: hidden !important; animation: none !important; }
  .gai-print-one .gai-chat-log, .gai-print-one .gai-chat-log * { visibility: visible !important; }
  .gai-print-one .gai-chat-log { position: absolute; inset: 0 0 auto; max-height: none; overflow: visible; border: 0; background: #fff; }
  .gai-print-single .gai-chat-log * { visibility: hidden !important; }
  .gai-print-single .gai-print-this, .gai-print-single .gai-print-this * { visibility: visible !important; }
  .gai-print-single .gai-print-this { position: absolute; inset: 0 0 auto; }
  .gai-print-one .gai-actions, .gai-print-one .gai-why, .gai-print-one .gai-msg-avatar { display: none !important; }
  .gai-print-one .gai-bubble, .gai-print-one .gai-source-card { box-shadow: none; }
}

/* ---- motion ---- */
@keyframes gai-in { from { opacity: 0; transform: translateY(8px) scale(.985); } to { opacity: 1; transform: none; } }
@keyframes gai-dot { 0%, 80%, 100% { opacity: .3; transform: translateY(0); } 40% { opacity: 1; transform: translateY(-3px); } }
@keyframes gai-pulse { 0% { box-shadow: 0 0 0 0 rgb(74 222 128 / .7); } 70%, 100% { box-shadow: 0 0 0 7px rgb(74 222 128 / 0); } }
@media (prefers-reduced-motion: no-preference) {
  .gai-chat-log { scroll-behavior: smooth; }
  .gai-msg, .gai-chat-empty, .gai-model[open] .gai-model-card, .gai-share[open] .gai-share-menu, .gai-why, .gai-drawer { animation: gai-in .32s var(--ease) both; }
  .gai-react:hover { transform: scale(1.15); }
  .gai-source-card { animation: gai-in .36s var(--ease) both; }
  .gai-source-card:nth-child(2) { animation-delay: .08s; }
  .gai-source-card:nth-child(3) { animation-delay: .16s; }
  .gai-source-card:hover { transform: translateY(-1px); }
  .gai-dots i { animation: gai-dot 1.2s infinite ease-in-out; }
  .gai-dots i:nth-child(2) { animation-delay: .15s; }
  .gai-dots i:nth-child(3) { animation-delay: .3s; }
  .gai-chat-dot { animation: gai-pulse 2.4s infinite; }
}
