/* ==========================================================================
   nexus-overrides.css
   Load AFTER nexus.css. Neutralizes legacy hardcoded indigo shades
   (#6366f1, #818cf8, #a5b4fc, rgba(99,102,241,...)) still present in
   per-template inline <style> blocks so the cobalt direction applies
   consistently across chat/projects/documents/etc.
   ========================================================================== */

/* --- Markdown blocks inside chat bubbles --- */
.msg-bubble code {
    background: rgba(79,99,255,0.12) !important;
    color: #c4ccff !important;
    font-family: 'JetBrains Mono', monospace;
}
.msg-bubble pre {
    background: #0d0f16 !important;
    border: 1px solid var(--panel-border) !important;
    border-radius: var(--radius) !important;
}
.msg-bubble pre code {
    background: none !important;
    color: #d8dbe6 !important;
}
.msg-bubble pre .copy-code-btn {
    background: rgba(255,255,255,0.04) !important;
    border: 1px solid var(--panel-border) !important;
    color: var(--text2) !important;
}
.msg-bubble pre .copy-code-btn:hover {
    background: var(--accent-soft) !important;
    color: #c4ccff !important;

}
.msg-bubble blockquote {

    background: var(--accent-soft) !important;
    border-radius: 0 6px 6px 0;
}
.msg-bubble th {
    background: var(--accent-soft) !important;
}
.msg-bubble a { color: var(--accent2) !important; }

/* --- Model selector --- */
.model-select {
    background: var(--accent-soft) !important;
    border: 1px solid rgba(79,99,255,0.22) !important;
    color: #c4ccff !important;
    border-radius: 6px !important;
    font-family: 'JetBrains Mono', monospace;
    letter-spacing: 0.02em;
}
.model-select:hover, .model-select:focus {
    background: rgba(79,99,255,0.18) !important;
    border-color: var(--accent) !important;
}

/* --- Any element still using the legacy hex in inline style --- */
[style*="#6366f1"] { color: var(--accent) !important; }
[style*="#818cf8"] { color: var(--accent2) !important; }
[style*="#a5b4fc"] { color: #c4ccff !important; }

/* --- Generic fallback for any ::before/::after or nested pill using the
       old indigo glow --- */
.pill, .chip, .tag {
    font-family: 'JetBrains Mono', monospace;
    letter-spacing: 0.04em;
}

/* --- Light mode parity --- */
body.light .msg-bubble code { background: rgba(79,99,255,0.08) !important; color: #2a3bcc !important; }
body.light .msg-bubble pre { background: #f7f8fa !important; }
body.light .msg-bubble pre code { color: #0f1220 !important; }
body.light .model-select { color: #2a3bcc !important; }
