/* Fifth AI / Abhi: one conversation, explicit voice controls. */
#modalBackdrop { z-index: 140; }
.identity-setup { max-width: 440px; margin: 0 auto; line-height: 1.6; }
.identity-setup #mfaQr { display: block; width: 220px; max-width: 100%; height: auto; padding: 12px; background: #fff; margin: 16px auto; border: 1px solid #cbdde5; border-radius: 12px; }
.identity-setup details { margin: 14px 0; }
.identity-setup code { display: block; padding: 10px; background: #eef5f8; overflow-wrap: anywhere; user-select: all; }
.identity-setup #mfaFeedback { color: #a02233; font-size: 14px; }
.identity-setup input { font-variant-numeric: tabular-nums; letter-spacing: .2em; }
.identity-setup [hidden] { display: none !important; }
.abhi-recovery { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 3px; }
.abhi-recovery button { font-size: 12px; padding: 6px 9px; border: 1px solid #adcdd7; border-radius: 7px; background: #f0f8fa; color: #07596a; }
.abhi-recovery [hidden] { display: none; }
#assistantFab { z-index: 110; }
#assistantNudge { z-index: 109; }
#assistantDrawer.abhi-panel {
  --abhi-navy: #072b45; --abhi-teal: #007e87; --abhi-muted: #536a7a;
  z-index: 112; width: min(480px, calc(100vw - 32px)); top: 16px; right: 16px; bottom: 16px;
  display: flex; flex-direction: column; min-height: 0; color: var(--abhi-navy);
  background: #fff; border: 1px solid #cbdde5; border-radius: 22px;
  box-shadow: 0 24px 90px #001a3540; font-size: 16px; line-height: 1.5;
  visibility: hidden; pointer-events: none; transition: transform .22s ease, opacity .22s ease, visibility .22s;
}
#assistantDrawer.abhi-panel.open { visibility: visible; pointer-events: auto; }
.abhi-panel *, .abhi-panel *::before, .abhi-panel *::after { box-sizing: border-box; }
.abhi-panel button, .abhi-panel select, .abhi-panel input, .abhi-panel textarea { font: inherit; }
.abhi-panel button { cursor: pointer; }
.abhi-panel button:disabled { cursor: not-allowed; opacity: .5; }
.abhi-panel [hidden] { display: none !important; }
.abhi-panel :focus-visible { outline: 3px solid #00a8b5; outline-offset: 3px; }
.abhi-icon { width: 20px; height: 20px; display: block; flex: 0 0 auto; }
.abhi-header { padding: 18px 20px; display: flex; gap: 12px; align-items: center; color: #fff; background: #062940; flex-shrink: 0; }
.abhi-portrait { position: relative; width: 54px; height: 54px; flex-shrink: 0; border-radius: 50%; padding: 2px; border: 1px solid #47c7c8; }
.abhi-portrait img { width: 100%; height: 100%; object-fit: cover; object-position: center 25%; border-radius: 50%; background: #e2f1f3; }
.abhi-portrait.speaking { animation: abhiSpeak 1s ease-in-out infinite; }
@keyframes abhiSpeak { 50% { box-shadow: 0 0 0 5px #39dfcb30; } }
.abhi-heading { flex: 1; min-width: 0; }
.abhi-heading h2 { font: inherit; font-size: 21px; font-weight: 700; color: #fff; margin: 0; }
.abhi-heading p { margin: 1px 0 0; color: #c3dae2; font-size: 13px; }
.abhi-header-buttons { display: flex; gap: 4px; }
.abhi-icon-button { display: inline-flex; justify-content: center; align-items: center; width: 40px; height: 40px; border: 0; border-radius: 12px; background: transparent; color: inherit; flex-shrink: 0; }
.abhi-header .abhi-icon-button:hover { background: #ffffff18; }
.abhi-toolbar { display: flex; gap: 10px; align-items: center; padding: 12px 18px; border-bottom: 1px solid #e0e9ef; flex-shrink: 0; flex-wrap: wrap; }
.abhi-hear { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 40px; border: 1px solid #a7d6d9; color: #006872; background: #eaf8f8; border-radius: 11px; padding: 8px 12px; font-weight: 650 !important; font-size: 14px !important; }
.abhi-hear[aria-pressed="true"] { background: #006e79; color: #fff; border-color: #006e79; }
.abhi-mode { font-size: 12px; color: #536a7a; line-height: 1.35; flex: 1; min-width: 95px; }
.abhi-mode b { display: block; font-weight: 600; color: #314f63; }
.abhi-toolbar .abhi-icon-button:hover { background: #edf5f8; }
.abhi-scroll { min-height: 0; flex: 1 1 auto; overflow-y: auto; overscroll-behavior: contain; padding: 20px 18px; background: linear-gradient(180deg, #f5fafc, #fff 180px); }
.abhi-conversation { display: flex; flex-direction: column; gap: 19px; }
.abhi-message { max-width: 100%; overflow-wrap: anywhere; }
.abhi-message-label { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 650; color: #617887; margin-bottom: 6px; }
.abhi-message-label img { width: 18px; height: 18px; object-fit: cover; border-radius: 5px; }
.abhi-message p { font-size: 16px; line-height: 1.6; margin: 0; white-space: pre-wrap; }
.abhi-message.user { align-self: flex-end; max-width: 88%; background: #e8f1f6; color: #123c54; padding: 10px 14px; border-radius: 17px 17px 4px 17px; }
.abhi-message.user .abhi-message-label { color: #486678; }
.abhi-message-actions, .abhi-suggestions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.abhi-message-actions button, .abhi-suggestions button, .abhi-workspace-prompts button { border: 1px solid #c9dde5; border-radius: 10px; padding: 9px 12px; background: #fff; color: #075f73; font-size: 14px; text-align: left; line-height: 1.4; }
.abhi-message-actions button:hover, .abhi-suggestions button:hover { background: #eef8fa; border-color: #59a7b0; }
.abhi-suggestions { margin-top: 20px; }
.abhi-settings { border: 1px solid #d3e2e9; border-radius: 14px; padding: 14px; margin-bottom: 18px; background: #fff; }
.abhi-settings h3 { margin: 0 0 10px; font-size: 16px; }
.abhi-settings label:not(.abhi-check) { display: block; margin-top: 12px; font-size: 14px; font-weight: 600; }
.abhi-settings select, .abhi-settings input:not([type="checkbox"]) { width: 100%; min-height: 42px; border-radius: 8px; border: 1px solid #bdcfd9; background: #fff; color: #183e54; padding: 8px; margin-top: 5px; font-size: 14px; }
.abhi-check { display: flex; align-items: start; gap: 8px; font-size: 14px; margin: 12px 0; }
.abhi-check input { margin-top: 4px; accent-color: #007c87; }
.abhi-settings p { font-size: 13px; color: #516b7a; margin: 10px 0; line-height: 1.5; }
.abhi-settings details { margin-top: 14px; font-size: 14px; }
.abhi-settings summary { cursor: pointer; color: #075f73; font-weight: 600; }
.abhi-settings button { border: 1px solid #adcdd7; border-radius: 8px; background: #f0f8fa; color: #07596a; min-height: 38px; padding: 7px 10px; font-size: 14px; }
.abhi-settings .abhi-clear { background: #fff; }
.abhi-profile-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.abhi-composer { padding: 12px 16px max(14px, env(safe-area-inset-bottom)); border-top: 1px solid #dce7ed; background: #fff; flex-shrink: 0; }
.abhi-input-shell { border: 1px solid #b7cdd8; border-radius: 17px; padding: 10px; background: #fff; box-shadow: 0 2px 6px #123c5410; }
.abhi-input-shell:focus-within { border-color: #007d89; box-shadow: 0 0 0 2px #009cab18; }
.abhi-input-shell textarea { display: block; width: 100%; min-height: 46px; max-height: 125px; resize: none; border: 0; padding: 4px 3px; font-size: 16px; line-height: 1.45; color: #173e55; background: transparent; }
.abhi-input-shell textarea:focus { outline: 0; }
.abhi-input-shell textarea::placeholder { color: #6a7e8b; }
.abhi-compose-tools { display: flex; gap: 7px; align-items: center; justify-content: flex-end; }
.abhi-compose-hint { margin-right: auto; color: #657a88; font-size: 12px; }
.abhi-mic { border: 1px solid #c9dce5; background: #f3f8fb; color: #204e68; width: 42px; height: 42px; }
.abhi-mic[aria-pressed="true"] { border-color: #bd3b48; background: #fff0f1; color: #a02233; }
.abhi-send { display: inline-flex; gap: 7px; justify-content: center; align-items: center; min-height: 42px; min-width: 78px; border-radius: 11px; padding: 9px 12px; border: 0; background: #073d59; color: #fff; font-size: 14px !important; font-weight: 650 !important; }
.abhi-send:not(:disabled):hover { background: #006c7b; }
.abhi-status { font-size: 12px; color: #496577; margin: 8px 3px 0; min-height: 18px; line-height: 1.45; overflow-wrap: anywhere; }
.abhi-status[data-error="true"] { color: #a02233; }
.abhi-memory { font-size: 12px; line-height: 1.4; color: #59717f; margin: 5px 3px 0; }
.abhi-memory[data-error="true"] { color: #a02233; }
.abhi-footnote { display: flex; gap: 6px; align-items: center; justify-content: center; font-size: 12px; color: #647b89; margin: 9px 0 0; }
.abhi-footnote img { width: 17px; height: 17px; border-radius: 4px; }
.abhi-workspace { padding: 26px; }
.abhi-workspace-title { display: flex; gap: 18px; align-items: center; margin-bottom: 20px; }
.abhi-workspace-title img { width: 74px; height: 74px; border-radius: 50%; object-fit: cover; }
.abhi-workspace h2 { margin: 5px 0; font-size: 25px; }
.abhi-workspace p { font-size: 16px; color: #536a7a; }
.abhi-workspace-prompts { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 20px; }
.abhi-workspace .abhi-workspace-note { font-size: 13px; margin-top: 16px; }
@media (max-width: 540px) {
  #assistantDrawer.abhi-panel { inset: 0; width: 100%; height: 100dvh; max-height: 100dvh; border-radius: 0; }
  .abhi-header { padding: max(12px, env(safe-area-inset-top)) 14px 12px; }
  .abhi-toolbar { padding: 10px 14px; gap: 8px; }
  .abhi-scroll { padding: 16px 14px; }
  .abhi-compose-hint { font-size: 12px; }
}
@media (max-height: 580px) {
  .abhi-header { padding-top: 8px; padding-bottom: 8px; }
  .abhi-portrait { width: 42px; height: 42px; }
  .abhi-toolbar { padding-top: 6px; padding-bottom: 6px; }
  .abhi-footnote { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  #assistantDrawer.abhi-panel { transition: none; }
  .abhi-portrait.speaking { animation: none; outline: 2px solid #39dfcb; }
}
