/* Telegram-inspired presentation; original LibreChat message/Markdown DOM preserved. */
/* Keep the navigation rail focused on conversations and documents. */
[data-testid="nav-panel-memories"] {display:none!important;}
/* Files uses the same fine, diagonal paperclip as the composer. */
[data-testid="nav-panel-files"]>svg {display:none!important;}
[data-testid="nav-panel-files"]::before {content:'';display:block;width:24px;height:24px;background:currentColor;mask:url('/alexys-icons/attach.svg') center/contain no-repeat;}
[data-testid="nav-panel-files"][aria-pressed="true"] {color:#168acd!important;background:#168acd14!important;}
/* Native search has no <main>; reserve space for the shared Alexys header. */
.bg-presentation:has(> .min-h-0 > [role="grid"]) {padding-top:70px!important;background:var(--alexys-bg)!important;}
.bg-presentation:has(> .min-h-0 > [role="grid"]) .agent-turn .mt-1.flex.gap-3 {position:static;opacity:1;pointer-events:auto;margin-top:6px;}
#alexys-search-history {display:none;}
@media(max-width:760px){body[data-alexys-page="search"] #alexys-search-history {display:flex;align-items:center;justify-content:center;position:fixed;left:8px;top:7px;z-index:35;width:40px;height:40px;border:1px solid #17334820;border-radius:12px;background:var(--alexys-bubble);color:var(--alexys-ink);font-size:20px;cursor:pointer;}}
@font-face {font-family:'Roboto';font-style:normal;font-weight:400;font-display:swap;src:url('/alexys-fonts/Roboto-Regular.woff2') format('woff2');}
@font-face {font-family:'Roboto';font-style:normal;font-weight:500 800;font-display:swap;src:url('/alexys-fonts/Roboto-Medium.woff2') format('woff2');}
body {--alexys-bg:#e8eef2;--alexys-ink:#000000;--alexys-blue:#168acd;--alexys-user:#effdde;--alexys-bubble:#f1f2f4;font-family:Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;}
body.dark {--alexys-bg:#17212b;--alexys-ink:#ecf1f5;--alexys-blue:#70b8e8;--alexys-user:#2b5278;--alexys-bubble:#182533;}
/* Telegram-like colour fields: warm lime, leafy green and deeper teal. */
main {background-color:#c6d4ab!important;background-image:url('/alexys-wallpaper.svg'),radial-gradient(ellipse at 100% 100%,#dce49b 0%,transparent 62%),radial-gradient(ellipse at 0% 100%,#86b783 0%,transparent 68%),radial-gradient(ellipse at 85% 0%,#6ca48f 0%,transparent 75%)!important;background-size:420px 420px,100% 100%,100% 100%,100% 100%;background-repeat:repeat,no-repeat,no-repeat,no-repeat;background-attachment:local;}
body.dark main {background-image:url('/alexys-wallpaper.svg'),linear-gradient(135deg,#172c25,#1c3029)!important;}
.m-auto:has(>.message-render .agent-turn) {padding-left:0!important;padding-right:0!important;}
.m-auto:has(>.message-render .user-turn) {padding-left:0!important;padding-right:0!important;}
.message-render:has(.agent-turn) {max-width:none!important;margin-left:20px!important;margin-right:20px!important;width:calc(100% - 40px)!important;padding-left:0!important;padding-right:0!important;}
.message-render:has(.user-turn) {max-width:none!important;margin-left:20px!important;margin-right:20px!important;width:calc(100% - 40px)!important;padding-left:0!important;padding-right:0!important;justify-content:flex-end!important;}
@media(max-width:760px){.message-render:has(.agent-turn){margin-left:10px!important;margin-right:10px!important;width:calc(100% - 20px)!important;}}
.message-render {margin-top:3px!important;margin-bottom:3px!important;}
.agent-turn {background:var(--alexys-bubble);border-radius:15px 15px 15px 4px;padding:4px 8px 5px!important;box-shadow:0 1px 2px #17334812;max-width:780px;color:var(--alexys-ink);}
.user-turn {background:transparent!important;padding:0!important;box-shadow:none;margin-left:auto!important;text-align:left;}
.user-turn .bg-surface-tertiary {background:var(--alexys-user)!important;padding:4px 8px 5px!important;border-radius:12px 12px 3px 12px!important;}
.user-turn .markdown {color:var(--alexys-ink)!important;text-align:left!important;}
.user-turn .w-full.flex.justify-end {position:absolute;right:0;top:100%;z-index:5;opacity:0;pointer-events:none;}
.user-turn:hover .w-full.flex.justify-end,.user-turn:focus-within .w-full.flex.justify-end {opacity:1;pointer-events:auto;}
.user-turn .flex.w-full.flex-col.gap-1 {gap:0!important;}
.agent-turn .markdown,.user-turn .markdown {font-family:'Roboto',Arial,sans-serif!important;font-size:13px;line-height:18px;font-weight:400;color:var(--alexys-ink);}
.agent-turn .markdown p {margin:0 0 .45em;}
.agent-turn .markdown p:last-child {margin-bottom:0;}
.agent-turn .markdown strong {font-weight:600;color:inherit;}
.agent-turn .markdown .alexys-section>strong {color:var(--alexys-blue);}
.agent-turn .markdown :is(h1,h2,h3) {font-size:1.08em;color:var(--alexys-blue);margin:1em 0 .45em;font-weight:750;}
.agent-turn .markdown li {margin:.1em 0;}
.agent-turn .markdown :is(ul,ol) {padding-left:1.25em;margin:.3em 0 .45em;}
.agent-turn .mt-1.flex.gap-3 {position:absolute;right:4px;bottom:-28px;z-index:5;opacity:0;pointer-events:none;}
.agent-turn:hover .mt-1.flex.gap-3,.agent-turn:focus-within .mt-1.flex.gap-3 {opacity:1;pointer-events:auto;}
.agent-turn .markdown blockquote {border-left:3px solid var(--alexys-blue);background:#168acd0b;padding:8px 12px;border-radius:0 8px 8px 0;}
.agent-turn .markdown a {color:var(--alexys-blue);text-underline-offset:3px;}
.agent-turn .markdown pre {border-radius:10px;font-size:13px;}
.agent-turn .markdown table {font-size:13px;display:block;overflow:auto;max-width:100%;}
#alexys-status {position:fixed;z-index:45;bottom:148px;left:calc(50% + 130px);transform:translateX(-50%);display:flex;align-items:center;gap:10px;background:var(--alexys-bubble);color:var(--alexys-blue);padding:9px 15px;border-radius:18px;box-shadow:0 2px 12px #14334c15;font-size:13px;pointer-events:none;}
#alexys-status[hidden] {display:none!important;}
#alexys-status .alexys-dots {display:inline-flex;gap:4px;align-items:center;height:14px;}
#alexys-status i {display:block;width:5px;height:5px;background:currentColor;border-radius:50%;animation:alexys-bounce 1.05s infinite ease-in-out;}
#alexys-status i:nth-child(2) {animation-delay:.14s;}#alexys-status i:nth-child(3) {animation-delay:.28s;}
@keyframes alexys-bounce {0%,60%,100%{transform:translateY(0);opacity:.4}30%{transform:translateY(-4px);opacity:1}}
/* The banner is the progress indicator: LibreChat's grey dot under the avatar (empty message) stays hidden. */
.result-thinking {display:none!important;}
#alexys-suggestions {position:fixed;z-index:24;left:calc(var(--alexys-chat-left,288px) + 20px);right:20px;bottom:70px;display:flex;flex-wrap:wrap;justify-content:center;gap:8px;margin:0 auto;max-width:600px;padding:0;}
@media(max-width:760px){#alexys-suggestions{left:10px;right:10px;bottom:64px;}}
#alexys-suggestions button {font-size:13px;padding:8px 13px;border-radius:16px;background:var(--alexys-bubble);border:1px solid #168acd35;color:var(--alexys-blue);cursor:pointer;}
#alexys-suggestions button:hover {background:#168acd15;}
button[aria-label="Tools Options"] {display:none!important;}
@media(max-width:760px){.agent-turn{padding:4px 8px 5px!important;max-width:100%;}.agent-turn .markdown{font-size:13px;}#alexys-status{left:50%;bottom:142px;white-space:nowrap;}.message-render{margin-top:3px!important;}}
/* Rectangular composer, native handlers, Telegram Web SVG controls. */
.bg-surface-chat:has(#prompt-textarea) {position:relative;padding:0 42px!important;border-radius:4px!important;min-height:44px;}
.bg-surface-chat:has(#prompt-textarea)>div:first-child>div:last-child:empty {display:none;}
.bg-surface-chat:has(#prompt-textarea)>div:last-child {position:absolute;inset:0;padding:0!important;gap:0!important;pointer-events:none;}
.bg-surface-chat:has(#prompt-textarea)>div:last-child>:not(:first-child):not(:last-child):not(#audio-recorder):not(.alexys-rec-ui) {display:none!important;}
.bg-surface-chat:has(#prompt-textarea)>div:last-child>div:first-child {position:absolute;left:5px;top:50%;transform:translateY(-50%);}
.bg-surface-chat:has(#prompt-textarea)>div:last-child>div:last-child {position:absolute;right:5px;top:50%;transform:translateY(-50%);}
.bg-surface-chat:has(#prompt-textarea) #audio-recorder {position:absolute;right:5px;top:50%;transform:translateY(-50%);}
.bg-surface-chat:has(#prompt-textarea) :is(:is(#attach-file-menu-button,#attach-file-button),#audio-recorder,#send-button,[data-testid="stop-generation-button"]) {display:flex!important;align-items:center;justify-content:center;width:34px!important;height:34px!important;padding:0!important;border-radius:4px!important;background:transparent!important;opacity:1!important;pointer-events:auto!important;color:#6f7e86!important;}
.bg-surface-chat:has(#prompt-textarea) :is(:is(#attach-file-menu-button,#attach-file-button),#audio-recorder,#send-button)::before {content:'';display:block;width:24px;height:24px;background:currentColor;mask-position:center;mask-size:contain;mask-repeat:no-repeat;}
:is(#attach-file-menu-button,#attach-file-button)::before {mask-image:url('/alexys-icons/attach.svg');}
#audio-recorder::before {mask-image:url('/alexys-icons/microphone.svg');}
#send-button::before {mask-image:url('/alexys-icons/send.svg');}
.bg-surface-chat:has(#prompt-textarea) #send-button {color:#3390ec!important;}
.bg-surface-chat:has(#prompt-textarea) :is(:is(#attach-file-menu-button,#attach-file-button),#audio-recorder,#send-button)>* {display:none!important;}
.bg-surface-chat:has(#prompt-textarea)[data-alexys-mode="voice"] #send-button,.bg-surface-chat:has(#prompt-textarea)[data-alexys-mode="send"] #audio-recorder,.bg-surface-chat:has(#prompt-textarea)[data-alexys-mode="stop"] :is(#audio-recorder,#send-button) {display:none!important;}
.bg-surface-chat:has(#prompt-textarea) :is(:is(#attach-file-menu-button,#attach-file-button),#audio-recorder):disabled {cursor:default!important;}
.bg-surface-chat:has(#prompt-textarea) #audio-recorder[data-alexys-insecure] {opacity:.35!important;cursor:not-allowed!important;}
#alexys-status {bottom:100px;}
@media(max-width:760px){#alexys-status{bottom:88px;}.bg-surface-chat:has(#prompt-textarea){border-radius:4px!important;}}
@media(prefers-reduced-motion:reduce){#alexys-status i{animation:none;opacity:.8;}}
#alexys-header {position:fixed;z-index:30;top:0;left:360px;right:0;height:55px;display:flex;align-items:center;gap:11px;padding:0 18px;background:color-mix(in srgb,var(--alexys-bubble) 95%,transparent);border-bottom:1px solid #17334810;pointer-events:none;}
#alexys-header .alexys-avatar {width:34px;height:34px;border-radius:50%;}
#alexys-header strong {display:block;color:var(--alexys-ink);font-size:15px;line-height:20px;}
#alexys-header small {display:block;color:#6d8395;font-size:11px;line-height:15px;}
main {padding-top:0!important;}
#alexys-header {right:56px;}
@media(max-width:760px){#alexys-header{left:52px;padding-left:9px;}#alexys-header .alexys-avatar{width:32px;height:32px;}}
/* Conversation folders replace endpoint robots without changing stored titles. */
nav [data-testid="convo-icon"]>:is(span,img,div) {display:none!important;}
nav [data-testid="convo-icon"]::after {content:'📁';font-size:16px;line-height:20px;}
.agent-turn [role="img"]:has(svg.lucide-bot) {background:url('/alexys-alexys-bolt.svg') center/contain no-repeat!important;width:19px!important;height:22px!important;}
.agent-turn [role="img"]>svg.lucide-bot {display:none!important;}
/* Scale the entire left workspace by 20%, preserving full viewport height. */
aside {zoom:.8;height:100%!important;}
aside nav [role="row"],aside nav [role="row"] :is(button,span),aside nav h2 {color:#4b5563!important;}
/* No footer panel: the composer sits directly on the wallpaper. */
main .bg-presentation:has(>form) {background:transparent!important;padding:0!important;min-height:64px;}
main form:has(#prompt-textarea) {position:fixed!important;left:calc(var(--alexys-chat-left,288px) + 20px);right:20px;bottom:10px!important;z-index:25;max-width:none!important;width:auto!important;padding:0!important;margin:0!important;}
#prompt-textarea {display:block;font-family:'Roboto',Arial,sans-serif!important;font-size:13px!important;line-height:18px!important;padding:12px 0!important;min-height:42px;}
@media(max-width:760px){main form:has(#prompt-textarea){left:10px;right:10px;bottom:8px!important;width:auto!important;margin:0!important;}.message-render:has(.user-turn){margin-left:10px!important;margin-right:10px!important;width:calc(100% - 20px)!important;}}
.alexys-conversation-section-heading,.alexys-date-heading {display:none!important;}
nav [data-pinned-section] {margin-bottom:0!important;padding-bottom:0!important;}
nav [data-testid="convo-unpin-button"] {display:inline-flex!important;opacity:1!important;visibility:visible!important;align-items:center;justify-content:center;align-self:center;width:24px!important;height:24px!important;padding:0!important;color:#7a8690;}
nav [data-testid="convo-unpin-button"]>svg {display:none!important;}
nav [data-testid="convo-unpin-button"]::before {content:'';width:16px;height:16px;display:block;background:currentColor;mask:url('/alexys-icons/pin.svg') center/contain no-repeat;}


/* No regenerate, edit or fork on a message: a regenerated or edited exchange would not match what the PSD
   kept, and a fork starts a conversation whose correspondence table is empty. */
button[data-testid="regenerate-generation-button"],
button[aria-label="Régénérer"], button[aria-label="Regenerate"],
button[aria-label="Modifier"], button[aria-label="Edit"],
button[aria-label="Ouvrir le menu de fork"], button[aria-label="Open fork menu"], button[aria-label="Fork"]{display:none!important}
/* Welcome line of a new conversation: black on the light green background, also when the browser is dark. */
main p.split-parent, main p.split-parent span {color:#111!important;}
/* Replay of a dictation (stt flag, alexys-dictation.js): small control under the user message. */
/* Dictation, Telegram Web style (alexys-composer.js sets data-alexys-mic from LibreChat's aria-pressed). Idle: the
   timer and the bin are absent. Recording: dot + timer in the field, red bin instead of the clip, blue send circle. */
.alexys-rec-ui {display:none!important;}
.bg-surface-chat:has(#prompt-textarea) #audio-recorder {touch-action:none;user-select:none;-webkit-user-select:none;-webkit-touch-callout:none;transition:background-color .15s,color .15s;}
.bg-surface-chat:has(#prompt-textarea)[data-alexys-mic="recording"] #prompt-textarea {visibility:hidden;}
.bg-surface-chat:has(#prompt-textarea)[data-alexys-mic="recording"] :is(#attach-file-menu-button,#attach-file-button) {visibility:hidden;}
.bg-surface-chat:has(#prompt-textarea)[data-alexys-mic="recording"] .alexys-rec-timer {display:flex!important;align-items:center;gap:8px;position:absolute;left:44px;top:50%;transform:translateY(-50%);font-size:15px;color:var(--alexys-ink);font-variant-numeric:tabular-nums;pointer-events:none;}
.alexys-rec-timer::before {content:'';width:10px;height:10px;border-radius:50%;background:#e53935;animation:alexys-rec-blink 1s infinite;}
.bg-surface-chat:has(#prompt-textarea)[data-alexys-mic="recording"] .alexys-rec-cancel {display:flex!important;align-items:center;justify-content:center;position:absolute;left:5px;top:50%;transform:translateY(-50%);width:34px;height:34px;padding:0;border:0;border-radius:50%;background:transparent;color:#e53935;cursor:pointer;pointer-events:auto;transition:background-color .15s,color .15s;}
.alexys-rec-cancel::before {content:'';width:24px;height:24px;background:currentColor;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zM8 9h8v10H8V9zm7.5-5l-1-1h-5l-1 1H5v2h14V4z'/%3E%3C/svg%3E") center/contain no-repeat;}
.alexys-rec-cancel:hover {background:#e539351a;}
.bg-surface-chat:has(#prompt-textarea)[data-alexys-mic="recording"] #audio-recorder {background:#3390ec!important;color:#fff!important;border-radius:50%!important;animation:alexys-rec-pulse 1.5s infinite ease-out;}
.bg-surface-chat:has(#prompt-textarea)[data-alexys-mic="recording"] #audio-recorder::before {mask-image:url('/alexys-icons/send.svg');width:20px;height:20px;}
/* hold released outside the composer cancels: shown while the pointer is out */
.bg-surface-chat:has(#prompt-textarea)[data-alexys-cancel-armed] .alexys-rec-cancel {background:#e53935;color:#fff;}
.bg-surface-chat:has(#prompt-textarea)[data-alexys-cancel-armed] #audio-recorder {background:#aab4bb!important;animation:none;}
.bg-surface-chat:has(#prompt-textarea)[data-alexys-cancel-armed] .alexys-rec-timer {color:#e53935;}
.bg-surface-chat:has(#prompt-textarea)[data-alexys-mic="transcribing"] #audio-recorder {pointer-events:none!important;color:#3390ec!important;}
.bg-surface-chat:has(#prompt-textarea)[data-alexys-mic="transcribing"] #audio-recorder::before {mask:none;background:none;width:18px;height:18px;border:2px solid currentColor;border-right-color:transparent;border-radius:50%;animation:alexys-spin .75s linear infinite;}
@keyframes alexys-rec-pulse {0%{box-shadow:0 0 0 0 #3390ec66}70%{box-shadow:0 0 0 9px #3390ec00}100%{box-shadow:0 0 0 0 #3390ec00}}
@keyframes alexys-rec-blink {50%{opacity:.2}}
@keyframes alexys-spin {to{transform:rotate(360deg)}}
@media(prefers-reduced-motion:reduce){.bg-surface-chat #audio-recorder,.bg-surface-chat #audio-recorder::before,.alexys-rec-timer::before{animation:none!important;}}
/* no black focus ring left on the mic after a dictation (pointer); keyboard focus keeps a light background */
.bg-surface-chat:has(#prompt-textarea) #audio-recorder:focus {outline:none!important;--tw-ring-shadow:0 0 #0000;--tw-ring-offset-shadow:0 0 #0000;--tw-ring-color:transparent;}
.bg-surface-chat:has(#prompt-textarea):not([data-alexys-mic="recording"]) #audio-recorder:focus-visible {background:#6f7e861f!important;}

/* live waveform while recording (alexys-composer.js draws it in currentColor) */
.bg-surface-chat:has(#prompt-textarea)[data-alexys-mic="recording"] .alexys-rec-wave {display:block!important;position:absolute;left:118px;width:calc(100% - 166px);top:50%;height:24px;transform:translateY(-50%);color:#3390ec;pointer-events:none;}
.bg-surface-chat:has(#prompt-textarea)[data-alexys-cancel-armed] .alexys-rec-wave {color:#e5393999;}
/* Voice note bubble, Telegram outgoing: round play button, waveform with the played part coloured, "00:34, 183.5 KB" */
.alexys-voice {display:flex;align-items:center;gap:10px;min-width:220px;max-width:300px;padding:2px 0 4px;}
.alexys-voice-play {flex:none;width:44px;height:44px;border:0;border-radius:50%;background:var(--alexys-voice,#4fae4e);cursor:pointer;display:flex;align-items:center;justify-content:center;}
.alexys-voice-play::before {content:'';width:0;height:0;margin-left:4px;border-style:solid;border-width:9px 0 9px 15px;border-color:transparent transparent transparent var(--alexys-voice-icon,#fff);}
.alexys-voice.playing .alexys-voice-play::before {width:4px;height:16px;margin:0;border:0;border-left:4px solid var(--alexys-voice-icon,#fff);border-right:4px solid var(--alexys-voice-icon,#fff);box-sizing:content-box;padding:0 2px;background:transparent;}
.alexys-voice.unavailable .alexys-voice-play {opacity:.45;cursor:not-allowed;}
.alexys-voice-body {flex:1;min-width:0;display:flex;flex-direction:column;gap:3px;}
.alexys-voice-wave {position:relative;height:24px;color:var(--alexys-voice-rest,#4fae4e66);}
.alexys-voice-wave svg {display:block;width:100%;height:24px;fill:currentColor;}
.alexys-voice-played {position:absolute;inset:0;color:var(--alexys-voice,#4fae4e);clip-path:inset(0 calc(100% - var(--p,0%)) 0 0);}
.alexys-voice-meta {font:12px/1.2 Roboto,Arial,sans-serif;color:var(--alexys-voice,#4fae4e);font-variant-numeric:tabular-nums;}
body.dark {--alexys-voice:#fff;--alexys-voice-icon:#2b5278;--alexys-voice-rest:#ffffff66;}
/* on the sent message: bubble first, transcript below with the mic like Telegram's transcription */
.alexys-voice-turn [data-testid="message-body"] {background:var(--alexys-user);padding:6px 10px 6px 8px;border-radius:12px 12px 3px 12px;}
.alexys-voice-turn .markdown p:first-child::before {content:'🎙️ ';}
/* pending: the same bubble on the right above the composer while the transcription runs */
#alexys-voice-pending {position:fixed;z-index:30;display:flex;flex-direction:column;align-items:flex-end;gap:4px;background:var(--alexys-user);padding:6px 10px 6px 8px;border-radius:12px 12px 3px 12px;box-shadow:0 1px 2px #0000001f;animation:alexys-voice-in .18s ease-out;}
#alexys-voice-pending .alexys-voice-status {align-self:stretch;display:flex;align-items:center;gap:6px;font:12px/1.2 Roboto,Arial,sans-serif;color:#6f7e86;}
#alexys-voice-pending .alexys-voice-status::before {content:'';width:10px;height:10px;border:2px solid currentColor;border-right-color:transparent;border-radius:50%;animation:alexys-spin .75s linear infinite;}
#alexys-voice-pending.failed .alexys-voice-status {color:#e53935;}
#alexys-voice-pending.failed .alexys-voice-status::before {display:none;}
@keyframes alexys-voice-in {from{transform:translateY(8px);opacity:0}}
body:has(#alexys-voice-pending) #alexys-suggestions {visibility:hidden;}
/* hold to talk: Telegram's hint in the field, the waveform moves right of it */
.bg-surface-chat:has(#prompt-textarea)[data-alexys-mic="recording"][data-alexys-holding] .alexys-rec-hint {display:block!important;position:absolute;left:118px;top:50%;transform:translateY(-50%);font:14px/1 Roboto,Arial,sans-serif;color:#6f7e86;white-space:nowrap;pointer-events:none;}
.alexys-rec-hint b {font-weight:400;}
.alexys-rec-hint i {display:none;font-style:normal;color:#e53935;}
[data-alexys-cancel-armed] .alexys-rec-hint b {display:none;}
[data-alexys-cancel-armed] .alexys-rec-hint i {display:inline;}
.bg-surface-chat:has(#prompt-textarea)[data-alexys-mic="recording"][data-alexys-holding] .alexys-rec-wave {left:400px;width:calc(100% - 448px);}
@media(max-width:760px){.bg-surface-chat:has(#prompt-textarea)[data-alexys-mic="recording"][data-alexys-holding] .alexys-rec-wave{display:none!important;}.alexys-rec-hint b{font-size:12px;}}
/* Alexys icon: the black disc fills LibreChat's round holder (no white ring around a smaller logo) */
.rounded-full:has(>img[src*="/assets/alexys.svg"]) {background:transparent!important;box-shadow:none!important;--tw-shadow:0 0 #0000;}
.rounded-full:has(>img[src*="/assets/alexys.svg"])::after,.rounded-full:has(>img[src*="/assets/alexys.svg"])::before {display:none!important;}
.rounded-full>img[src*="/assets/alexys.svg"] {width:100%!important;height:100%!important;}

/* ==== Alexys.ai look (trial, dev): ivory paper, Inter + Georgia, burgundy accent, square shapes ====
   Overrides the Telegram presentation above; remove this block to roll back. */
body {--alexys-bg:#faf9f6;--alexys-ink:#151515;--alexys-blue:#761d2b;--alexys-user:#f1e4e6;--alexys-bubble:#ffffff;--alexys-line:#d8d6d1;--alexys-muted:#5c5852;font-family:Inter,Arial,sans-serif!important;}
body.dark {--alexys-bg:#161514;--alexys-ink:#f3f1ec;--alexys-blue:#d79aa4;--alexys-user:#3a2328;--alexys-bubble:#1f1e1c;--alexys-line:#3a3834;--alexys-muted:#a8a39a;}
main,body.dark main {background:var(--alexys-bg)!important;background-image:none!important;}
.bg-presentation:has(> .min-h-0 > [role="grid"]) {background:var(--alexys-bg)!important;}
/* messages: hairline rectangles; the answer reads like a page, the question carries a burgundy rule */
.agent-turn {background:var(--alexys-bubble)!important;border:1px solid var(--alexys-line);border-radius:0!important;box-shadow:none!important;padding:14px 18px!important;max-width:820px;}
.user-turn .bg-surface-tertiary,.alexys-voice-turn [data-testid="message-body"],#alexys-voice-pending {background:var(--alexys-user)!important;border-radius:0!important;border-left:2px solid var(--alexys-blue);padding:8px 12px!important;box-shadow:none!important;}
.message-render {margin-top:8px!important;margin-bottom:8px!important;}
.agent-turn .markdown,.user-turn .markdown,#prompt-textarea {font-family:Inter,Arial,sans-serif!important;font-size:14px!important;line-height:1.65!important;color:var(--alexys-ink)!important;}
.agent-turn .markdown p {margin:0 0 .7em;}
.agent-turn .markdown :is(h1,h2,h3) {font-family:Georgia,'Times New Roman',serif;font-weight:400;font-size:1.3em;letter-spacing:-.02em;color:var(--alexys-ink);margin:1.1em 0 .5em;}
.agent-turn .markdown strong,.agent-turn .markdown .alexys-section>strong {color:var(--alexys-ink);font-weight:650;}
.agent-turn .markdown li::marker {color:var(--alexys-blue);}
.agent-turn .markdown a {color:var(--alexys-blue);text-underline-offset:4px;}
.agent-turn .markdown blockquote {border-left:2px solid var(--alexys-blue);background:transparent;border-radius:0;padding:4px 14px;font-family:Georgia,serif;font-size:1.05em;}
.agent-turn .markdown pre,.agent-turn .markdown code {border-radius:0!important;}
.agent-turn .markdown table {border-collapse:collapse;}
.agent-turn .markdown :is(th,td) {border:0;border-bottom:1px solid var(--alexys-line);padding:8px 10px;}
.agent-turn .markdown th {font-size:11px;text-transform:uppercase;letter-spacing:.08em;color:var(--alexys-muted);font-weight:600;}
.agent-turn [role="img"]:has(svg.lucide-bot) {filter:none;}
main p.split-parent,main p.split-parent span {font-family:Georgia,serif!important;color:var(--alexys-ink)!important;letter-spacing:-.02em;}
/* header */
#alexys-header {background:var(--alexys-bg)!important;border-bottom:1px solid var(--alexys-line)!important;height:56px;}
#alexys-header strong {font-family:Georgia,serif;font-weight:400;font-size:20px;letter-spacing:-.04em;}
#alexys-header small {color:var(--alexys-muted);}
body #psd-switch,body #skills-switch {border-radius:0!important;font:550 12px/1 Inter,Arial,sans-serif!important;padding:8px 14px!important;background:var(--alexys-bg)!important;border:1px solid #a9a7a1!important;color:var(--alexys-ink)!important;}
body #psd-switch[aria-pressed="true"],body #skills-switch[aria-pressed="true"] {background:#761d2b!important;border-color:#761d2b!important;color:#fff!important;}
body .psd-badge {border-radius:0!important;}
body .psd-text {border-radius:0!important;}
/* composer: a white rectangle on paper, burgundy send */
.bg-surface-chat:has(#prompt-textarea) {background:var(--alexys-bubble)!important;border:1px solid var(--alexys-line)!important;border-radius:0!important;box-shadow:none!important;}
.bg-surface-chat:has(#prompt-textarea):focus-within {border-color:var(--alexys-ink)!important;}
.bg-surface-chat:has(#prompt-textarea) #send-button,.bg-surface-chat:has(#prompt-textarea)[data-alexys-mic="transcribing"] #audio-recorder {color:#761d2b!important;}
.bg-surface-chat:has(#prompt-textarea)[data-alexys-mic="recording"] #audio-recorder {background:#761d2b!important;border-radius:0!important;animation:none;}
.bg-surface-chat:has(#prompt-textarea)[data-alexys-mic="recording"] .alexys-rec-wave {color:#761d2b;}
.bg-surface-chat:has(#prompt-textarea) :is(#attach-file-menu-button,#attach-file-button,#audio-recorder,#send-button) {border-radius:0!important;}
/* suggestions and status: square, quiet */
#alexys-suggestions button {border-radius:0;background:var(--alexys-bubble);border:1px solid var(--alexys-line);color:var(--alexys-ink);font-family:Inter,Arial,sans-serif;}
#alexys-suggestions button:hover {border-color:#761d2b;color:#761d2b;background:var(--alexys-bubble);}
#alexys-status {border-radius:0;background:var(--alexys-bubble);border:1px solid var(--alexys-line);box-shadow:none;color:#761d2b;}
/* voice notes */
body {--alexys-voice:#761d2b;--alexys-voice-rest:#761d2b55;}
.alexys-voice-meta,#alexys-voice-pending .alexys-voice-status {font-family:Inter,Arial,sans-serif;}
/* sidebar: paper, dark ink, burgundy selection */
aside,aside nav,aside > div {background:var(--alexys-bg)!important;}
aside {border-right:1px solid var(--alexys-line);}
aside nav [role="row"],aside nav [role="row"] :is(button,span),aside nav h2 {color:var(--alexys-ink)!important;font-family:Inter,Arial,sans-serif;}
aside nav a,aside nav [role="row"] > * {border-radius:0!important;}
nav [data-testid="convo-icon"]::after {content:'';display:block;width:12px;height:14px;background:#761d2b;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Cpath d='M18 3 7 18h8l-2 11 12-17h-9z'/%3E%3C/svg%3E") center/contain no-repeat;}
[data-testid="nav-panel-files"][aria-pressed="true"] {color:#761d2b!important;background:#761d2b14!important;}
/* menus and dialogs from the app keep their structure, only squarer */
[role="menu"],[role="dialog"],[role="listbox"] {border-radius:0!important;}
/* Layout C: the edge writes the rail, the phone tabs and the header into the page (alexys-nav.html; alexys-nav.js
   wires them), so the first paint already has the final layout. LibreChat lives in a fixed box right of the rail and
   under the header; its icon column is hidden except the account button, moved to the bottom of the rail. */
#alexys-rail,#alexys-tabs,#alexys-thread {display:none;}
body[data-alexys-nav] {background:var(--alexys-bg)!important;}
body[data-alexys-nav] #alexys-header {display:none!important;}
body[data-alexys-nav] #alexys-rail {display:flex;position:fixed;left:0;top:0;bottom:0;width:72px;z-index:1;flex-direction:column;align-items:center;gap:2px;padding:14px 0;background:#f0eee9;border-right:1px solid var(--alexys-line,#d8d6d1);font-family:Inter,Arial,sans-serif;}
body.dark[data-alexys-nav] #alexys-rail,body.dark[data-alexys-nav] #alexys-tabs {background:#1b1a18;}
#alexys-rail a,#alexys-tabs a {display:flex;flex-direction:column;align-items:center;gap:5px;font-size:10.5px;font-weight:500;color:var(--alexys-muted,#5c5852);text-decoration:none;position:relative;}
#alexys-rail a {width:62px;padding:10px 0 8px;}
#alexys-rail a svg,#alexys-tabs a svg {width:20px;height:20px;}
#alexys-rail a:hover,#alexys-tabs a:hover {color:var(--alexys-ink,#151515);}
#alexys-rail a.is-on,#alexys-tabs a.is-on {color:#761d2b;}
#alexys-rail a.is-on::before {content:'';position:absolute;left:-5px;top:8px;bottom:8px;width:2px;background:#761d2b;}
#alexys-rail .alexys-rail-logo {color:#761d2b;margin-bottom:14px;padding:4px 0;}
#alexys-rail .alexys-rail-logo svg {width:22px;height:28px;}
body[data-alexys-nav] #alexys-thread {display:flex;position:fixed;top:0;left:72px;right:0;height:56px;z-index:30;align-items:center;gap:12px;padding:0 12px 0 16px;background:var(--alexys-bg);border-bottom:1px solid var(--alexys-line,#d8d6d1);}
body[data-alexys-nav] #root {position:fixed!important;top:57px;left:72px;right:0;bottom:0;width:auto!important;height:auto!important;margin:0!important;z-index:2;}
body[data-alexys-nav] #root div.relative.z-0:has(>aside) {z-index:2!important;}
body[data-alexys-nav] aside {zoom:1!important;}
body[data-alexys-nav] aside[style*="width: 52px"] {width:0!important;min-width:0!important;max-width:0!important;}
body[data-alexys-nav] aside>div>div:first-child {position:fixed!important;left:0;bottom:12px;top:auto!important;width:72px!important;height:auto!important;z-index:46;align-items:center;background:transparent!important;border:0!important;padding:0!important;}
body[data-alexys-nav] aside>div>div:first-child>:not(.mt-auto) {display:none!important;}
body[data-alexys-nav] aside nav [role="row"]:is(:hover,:focus-within),body[data-alexys-nav] aside nav [aria-current="page"] {border-radius:0!important;}
body[data-alexys-nav] #psd-switch,body[data-alexys-nav] #skills-switch {display:none!important;}
/* LibreChat's top bar over the messages (share, ephemeral, model): the Alexys header replaces it */
body[data-alexys-nav] main div.absolute.top-0.z-20[class*="h-[52px]"] {display:none!important;}
.alexys-head-button {width:36px;height:36px;display:flex;align-items:center;justify-content:center;border:1px solid transparent;background:transparent;color:var(--alexys-ink,#151515);cursor:pointer;flex:none;padding:0;}
.alexys-head-button svg {width:20px;height:20px;}
.alexys-head-button:hover {border-color:var(--alexys-line,#d8d6d1);}
.alexys-head-button.is-on,.alexys-head-button[aria-expanded="true"] {background:#761d2b14;color:#761d2b;}
#alexys-dots {margin-left:auto;}
#alexys-dots svg {width:18px;height:18px;}
#alexys-title {font-family:Georgia,'Times New Roman',serif;font-size:18px;letter-spacing:-.02em;color:var(--alexys-ink,#151515);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;min-width:0;}
#alexys-menu {position:fixed;top:52px;right:12px;z-index:70;width:250px;background:var(--alexys-bubble,#fff);border:1px solid var(--alexys-line,#d8d6d1);box-shadow:0 22px 40px -20px rgba(21,21,21,.35);padding:6px 0;font:13px/1.3 Inter,Arial,sans-serif;color:var(--alexys-ink,#151515);}
#alexys-menu[hidden] {display:none;}
#alexys-menu button {display:flex;align-items:center;gap:12px;width:100%;padding:11px 16px;border:0;background:transparent;color:inherit;font:inherit;text-align:left;cursor:pointer;}
#alexys-menu button:hover {background:#761d2b0f;}
#alexys-menu hr {border:0;border-top:1px solid var(--alexys-line,#d8d6d1);margin:6px 0;}
.alexys-menu-label {font-size:10.5px;letter-spacing:.1em;text-transform:uppercase;color:var(--alexys-muted,#5c5852);font-weight:600;padding:8px 16px 4px;}
.alexys-check {width:15px;height:15px;border:1px solid #a9a7a1;display:inline-flex;align-items:center;justify-content:center;font-size:11px;color:#fff;flex:none;}
.alexys-check.is-on {background:#761d2b;border-color:#761d2b;}
/* phone: no rail, bottom tabs; LibreChat's own header toggle gives way to the one in the Alexys header */
@media(max-width:760px){
 body[data-alexys-nav] #alexys-rail {display:none;}
 body[data-alexys-nav] #alexys-thread {left:0;height:54px;padding:0 6px;}
 body[data-alexys-nav] #root {top:55px;left:0;bottom:58px;}
 body[data-alexys-nav] aside>div>div:first-child {position:static!important;width:auto!important;}
 body[data-alexys-nav] aside>div>div:first-child>:not(.mt-auto) {display:revert!important;}
 body[data-alexys-nav] [data-testid="header-open-sidebar-button"] {display:none!important;}
 body[data-alexys-nav] #alexys-tabs {display:flex;position:fixed;left:0;right:0;bottom:0;z-index:44;height:58px;background:#f0eee9;border-top:1px solid var(--alexys-line,#d8d6d1);font-family:Inter,Arial,sans-serif;}
 #alexys-tabs a {flex:1;justify-content:center;gap:3px;}
 #alexys-tabs a.is-on {box-shadow:inset 0 2px #761d2b;}
 body[data-alexys-nav] main form:has(#prompt-textarea) {bottom:68px!important;}
 body[data-alexys-nav] #alexys-suggestions {bottom:124px;}
 body[data-alexys-nav] #alexys-menu {top:50px;right:6px;}
}
/* sign-in pages (/login, /register, /forgot-password): LibreChat's green and teal tokens take the burgundy accent
   (RGB triplets, as LibreChat reads them); on the dark accent the submit text turns dark for contrast */
html:not(.dark) {--surface-submit:118 29 43;--surface-submit-hover:94 23 34;--accent-primary:118 29 43;--accent-primary-hover:94 23 34;}
html.dark {--surface-submit:215 154 164;--surface-submit-hover:229 183 190;--accent-primary:215 154 164;--accent-primary-hover:229 183 190;}
html.dark .bg-surface-submit.text-text-on-status {color:#161514!important;}
/* ==== end Alexys.ai look ==== */
