/* New shell: full-width column */
:root {
    --haycu-topbar-height: 61px;
}

.app-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Make header span full width */
.app-header {
    width: 100%;
}

/* Main content spacing */
.app-main {
    flex: 1;
    padding: 1rem 1.5rem;
}
.topbar {
    position: sticky;
    top: 0;
    z-index: 1030; /* sits above content */
}

.content {
    padding-top: 1rem;
}

html, body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

a, .btn-link {
    color: var(--bs-link-color);
}

.btn-primary {
    color: var(--bs-white);
    background-color: var(--bs-primary);
    border-color: var(--bs-primary);
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem var(--bs-body-bg), 0 0 0 0.25rem var(--bs-focus-ring-color);
}

.details-panel .list-item button:focus,
.details-panel .list-item button:focus-visible,
.details-panel .list-item .btn:focus,
.details-panel .list-item .btn:focus-visible,
.details-panel .list-item .btn-link:focus,
.details-panel .list-item .btn-link:focus-visible,
.details-panel .list-item button.btn:focus,
.details-panel .list-item button.btn:focus-visible,
.details-panel .list-item button.btn-link:focus,
.details-panel .list-item button.btn-link:focus-visible {
  outline: none !important;
  box-shadow: none !important;
}

.content {
    padding-top: 1.1rem;
}

h1:focus {
    outline: none;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid var(--bs-success);
}

.invalid {
    outline: 1px solid var(--bs-danger);
}

.validation-message {
    color: var(--bs-danger);
}

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, var(--bs-danger);
    padding: 1rem 1rem 1rem 3.7rem;
    color: var(--bs-white);
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.darker-border-checkbox.form-check-input {
    border-color: var(--bs-border-color);
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

.page {
    position: relative;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}




.top-row {
    background-color: var(--bs-tertiary-bg);
    border-bottom: 1px solid var(--bs-border-color);
    justify-content: flex-end;
    height: 3.5rem;
    display: flex;
    align-items: center;
}

.top-row  a, .top-row  .btn-link {
    white-space: nowrap;
    margin-left: 1.5rem;
    text-decoration: none;
}

.top-row a:hover, .top-row .btn-link:hover {
    text-decoration: underline;
}

.top-row a:first-child {
    overflow: hidden;
    text-overflow: ellipsis;
}

@media (max-width: 640.98px) {
    .top-row {
        justify-content: space-between;
    }

    .top-row a, .top-row .btn-link {
        margin-left: 0;
    }
}

@media (min-width: 641px) {
    .page {
        flex-direction: row;
    }

    .sidebar {
        width: 250px;
        height: 100vh;
        position: sticky;
        top: 0;
    }

    .top-row {
        position: sticky;
        top: 0;
        z-index: 1;
    }

    .top-row.auth a:first-child {
        flex: 1;
        text-align: right;
        width: 0;
    }

    .top-row, article {
        padding-left: 2rem !important;
        padding-right: 1.5rem !important;
    }
}

#blazor-error-ui {
    color-scheme: light dark;
    background: var(--bs-warning-bg-subtle);
    color: var(--bs-warning-text-emphasis);
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(var(--bs-black-rgb), 0.2);
    box-sizing: border-box;
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    position: absolute;
    right: 0.75rem;
    top: 0.5rem;
}

.page-wrapper .nav-item:first-of-type{
    padding-top:0px!important;
}


.feed-calendar-item-container {
    width: 86px;
    height: 85px;
    text-align: center;
    background-color: var(--bs-secondary-bg);
    border-radius: 12px;
    margin-bottom: 10px;
    padding: 10px;
}
.feed-calendar-item-container .day{
    font-size: 10px; 
    color: var(--bs-danger);
}
.feed-calendar-item-container .date{
    font-size: 35px;
}

.feed-calendar-item-container .count{
    background-color: var(--bs-danger);
    width: 26px;
    border-radius: 50%;
    padding-left: 0px;
    color: var(--bs-white);
    text-align: center;
    height: 26px;
    line-height: 27px;
    position: relative;
    top: -83px;
    right: -18px;
    float: right;
}
.feed-item-type-bubble{
    float: right;
    background-color: var(--bs-primary);
    width: 26px;
    height: 26px;
    color: var(--bs-white);
    text-align: center;
    font-size: 14px;
    line-height: 24px;
    border-radius: 50%;
    position: relative;
    right: 8px;
    bottom: -25px;
    border: 1px solid var(--bs-white);
}
.thread-message-say-bubble {
    float: right; 
    background-color: var(--bs-secondary); 
    color: var(--bs-white); 
    width: 19px; 
    height: 20px; 
    font-size: 11px; 
    text-align: center; 
    line-height: 20px; 
    border-radius: 50%; 
    position: relative; 
    top: -15px; 
    right: -13px;
}
.thread-message-say-bubble:hover{
    opacity: 0.7;
}

.react{
    position: relative; 
    float: left; 
    display: none;
     left: -5px; 
}

.chat-message:hover .react{
    display: block;
}

.react-bubble {
    color: white;
    width: 23px;
    height: 23px;
    font-size: 13px;
    text-align: center;
    line-height: 23px;
    border-radius: 50%;
    display: inline-block;
}

.react-bubble:hover{
    opacity: 0.7;
}

.loading{
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    min-width: 100vw;
    min-height: 100vh;
    background-color: rgba(var(--bs-black-rgb), 0.36);
    padding-left: calc(50vw - 24px);
    padding-top: calc(50vh - 24px);
    z-index: 10000000;
}

.avatar {
    vertical-align: middle;
    width: 50px;
    color: var(--bs-white);
    text-align: center;
    line-height: 50px;
    background-color: var(--bs-danger);
    height: 50px;
    border-radius: 50%;
}
.avatar-sm {
    width: 35px;
    height: 35px;
    line-height: 35px;
    font-size: 15px;
}
.loader {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    position: relative;
    animation: rotate 1s linear infinite;
    background-color: var(--bs-primary);
}
/*rgb(35 175 245)*/
.loader::before , .loader::after {
    content: "";
    box-sizing: border-box;
    position: absolute;
    inset: 0px;
    border-radius: 50%;
    border: 5px solid var(--bs-primary);
    animation: prixClipFix 2s linear infinite ;
}
.loader::after{
    transform: rotate3d(90, 90, 0, 180deg );
    border-color: var(--bs-info);
}

@keyframes rotate {
     0%   {transform: rotate(0deg)}
     100%   {transform: rotate(360deg)}
 }

@keyframes prixClipFix {
     0%   {clip-path:polygon(50% 50%,0 0,0 0,0 0,0 0,0 0)}
     50%  {clip-path:polygon(50% 50%,0 0,100% 0,100% 0,100% 0,100% 0)}
     75%, 100%  {clip-path:polygon(50% 50%,0 0,100% 0,100% 100%,100% 100%,100% 100%)}
 }





.navbar-toggler {
    appearance: none;
    cursor: pointer;
    width: 3.5rem;
    height: 2.5rem;
    color: var(--bs-white);
    position: absolute;
    top: 0.5rem;
    right: 1rem;
    border: 1px solid rgba(var(--bs-white-rgb), 0.1);
    background: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.55%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") no-repeat center/1.75rem rgba(var(--bs-white-rgb), 0.1);
}

.navbar-toggler:checked {
    background-color: rgba(var(--bs-white-rgb), 0.5);
}

.top-row {
    min-height: 3.5rem;
    background-color: rgba(var(--bs-black-rgb), 0.4);
}

.navbar-brand {
    font-size: 1.1rem;
}

.bi {
    display: inline-block;
    position: relative;
    width: 1.25rem;
    height: 1.25rem;
    margin-right: 0.75rem;
    top: -1px;
    background-size: cover;
}

.bi-house-door-fill-nav-menu {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='white' class='bi bi-house-door-fill' viewBox='0 0 16 16'%3E%3Cpath d='M6.5 14.5v-3.505c0-.245.25-.495.5-.495h2c.25 0 .5.25.5.5v3.5a.5.5 0 0 0 .5.5h4a.5.5 0 0 0 .5-.5v-7a.5.5 0 0 0-.146-.354L13 5.793V2.5a.5.5 0 0 0-.5-.5h-1a.5.5 0 0 0-.5.5v1.293L8.354 1.146a.5.5 0 0 0-.708 0l-6 6A.5.5 0 0 0 1.5 7.5v7a.5.5 0 0 0 .5.5h4a.5.5 0 0 0 .5-.5Z'/%3E%3C/svg%3E");
}

.bi-plus-square-fill-nav-menu {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='white' class='bi bi-plus-square-fill' viewBox='0 0 16 16'%3E%3Cpath d='M2 0a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V2a2 2 0 0 0-2-2H2zm6.5 4.5v3h3a.5.5 0 0 1 0 1h-3v3a.5.5 0 0 1-1 0v-3h-3a.5.5 0 0 1 0-1h3v-3a.5.5 0 0 1 1 0z'/%3E%3C/svg%3E");
}

.bi-list-nested-nav-menu {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='white' class='bi bi-list-nested' viewBox='0 0 16 16'%3E%3Cpath fill-rule='evenodd' d='M4.5 11.5A.5.5 0 0 1 5 11h10a.5.5 0 0 1 0 1H5a.5.5 0 0 1-.5-.5zm-2-4A.5.5 0 0 1 3 7h10a.5.5 0 0 1 0 1H3a.5.5 0 0 1-.5-.5zm-2-4A.5.5 0 0 1 1 3h10a.5.5 0 0 1 0 1H1a.5.5 0 0 1-.5-.5z'/%3E%3C/svg%3E");
}

.sidebar .nav-item {
    font-size: 0.9rem;
    padding-bottom: 0.5rem;
}

.sidebar .nav-item:last-of-type {
    padding-bottom: 1rem;
}

.sidebar .nav-item .nav-link {
    color: var(--bs-secondary-color);
    background: none;
    border: none;
    border-radius: 4px;
    height: 3rem;
    display: flex;
    align-items: center;
    line-height: 3rem;
    width: 100%;
}

.sidebar .nav-item a.active {
    background-color: rgba(var(--bs-white-rgb), 0.37);
    color: var(--bs-white);
}

.sidebar .nav-item .nav-link:hover {
    background-color: rgba(var(--bs-white-rgb), 0.1);
    color: var(--bs-white);
}

.sidebar .nav-scrollable {
    display: none;
}

.sidebar .navbar-toggler:checked ~ .nav-scrollable {
    display: block;
}

@media (min-width: 641px) {
    .sidebar .navbar-toggler {
        display: none;
    }

    .sidebar .nav-scrollable {
        /* Never collapse the sidebar for wide screens */
        display: block;

        /* Allow sidebar to scroll for tall menus */
        height: calc(100vh - 3.5rem);
        overflow-y: auto;
    }
}



 .in-active{
     background-color: var(--bs-secondary);
     color: var(--bs-white) !important;
 }
.in-active:hover{
    opacity: 0.9;
}

.label-truncate {
    display: -webkit-box;
    max-width: 200px;        /* set your width */
    overflow: hidden;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
}

.plaintext {
    white-space: pre-wrap;      /* Preserve \n line breaks AND wrap long lines */
    word-wrap: break-word;      /* Break long words if needed */
    overflow-wrap: break-word;  /* Modern equivalent for safety */
    max-width: 100%;            /* Prevent horizontal overflow */
    display: block;             /* Ensures correct container behavior */
}











.magical-border {

}

/* Animated border */
.magical-border::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border-radius: var(--bs-card-border-radius);
    padding: 2px;
    background: linear-gradient(90deg, color(srgb 0.1324 0.6843 0.961), color(srgb 0.5609 0.5363 0.9781), var(--bs-white));
    background-size: 300% 300%;
    -webkit-mask:
            linear-gradient(#fff 0 0) content-box,
            linear-gradient(#fff 0 0);
    -webkit-mask-composite: destination-out;
    mask-composite: exclude;
    animation: borderGlow 2.5s linear infinite;
    pointer-events: none; /* ensure clicks pass through */
    z-index: 1;
}


/* Animation for border gradient */
@keyframes borderGlow {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}




/* ---- Fix global horizontal scroll from flex intrinsic sizing ---- */
.page,
main,
article.content {
    min-width: 0;          /* THIS is the big one */
    max-width: 100%;
}

/* Clamp overflow so deep column chains never widen the document */
article.content {
    overflow-x: hidden;
}

/* ---- Give the app a height so “fill vertical space” works ---- */
html, body {
    height: 100%;
}

.page {
    min-height: 100vh;
}

main {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

article.content {
    flex: 1 1 auto;
    min-height: 0;
}
.ct-bubble{
    border-radius: 12px!important;
}
.ct-me .ct-bubble{
    background: var(--bs-primary) !important;
    border-bottom-right-radius:2px!important;
}
.ct-them .ct-bubble{
    background: var(--bs-body-bg) !important;
    border-bottom-left-radius:2px!important;
}
.ct-thread{
    background-color: var(--bs-secondary-bg) !important;
}

.ct-bubble{
    box-shadow: -5px 5px 18px rgba(var(--bs-black-rgb), 0.12);
}

.ct-me .ct-avatar{
    display: none!important;
}



ul,
ol {
    margin: 0;
    padding-left: 1.2em;
}

li {
    margin: 0.25em 0;
}


















:root{

    --v:rgb(35 175 245);
    --c:rgb(155 130 250);
    --m: rgb(224, 130, 250);
    --l: rgb(35, 102, 245);

    --vv: rgb(204, 235, 255);

    --r:18px;
    --gap:1px;
    --pad:2px;

    --spd-prism: 3s;
    --spd-hex:   4.3s;
    --spd-pulse: 5.5s;
    --spd-dots:  3.6s;

    --spd-content: 3.4s;
}

/* ================= AI PROCESSING (FINAL) ================= */
.ai-processing{
    position:relative;
    isolation:isolate;
}

/* shared ring mask */
.ai-processing::before,
.ai-processing::after,
.ai-processing .ai-pulse,
.ai-processing .ai-dots{
    content:"";
    position:absolute;
    inset:calc(-1 * var(--gap));
    border-radius: 12px;
    border-bottom-left-radius: 2px;
    padding:var(--pad);
    pointer-events:none;

    -webkit-mask:
            linear-gradient(#000 0 0) content-box,
            linear-gradient(#000 0 0);
    -webkit-mask-composite:xor;
    mask-composite:exclude;
}

/* prism refraction */
.ai-processing::before{
    background:linear-gradient(120deg,var(--c),var(--v),var(--m),var(--l),var(--c));
    background-size:300% 300%;
    animation:prism var(--spd-prism) ease-in-out infinite;
    z-index:-4;
}

/* hex ticks */
.ai-processing::after{
    background:
            repeating-linear-gradient(60deg,transparent 0 10px,var(--vv) 10px 12px,transparent 12px 22px),
            repeating-linear-gradient(-60deg,transparent 0 12px,var(--vv) 12px 14px,transparent 14px 24px);
    background-size:220px 100%,240px 100%;
    animation:hex var(--spd-hex) linear infinite;
    opacity:.55;
    z-index:-3;
}

/* rune pulse */
.ai-processing .ai-pulse{
    background:linear-gradient(90deg,var(--v),var(--c),var(--m));
    animation:pulse var(--spd-pulse) ease-in-out infinite;
    opacity:.35;
    z-index:-2;
}

/* ================= NEW: CONTENT OPACITY PULSE ================= */
/* subtle opacity pulse for content ONLY */
.ai-processing {
    animation: aiContentPulse var(--spd-content) ease-in-out infinite;
}

/* ================= Animations ================= */
@keyframes prism{
    0%{background-position:0% 50%}
    50%{background-position:100% 50%}
    100%{background-position:0% 50%}
}
@keyframes hex{
    to{background-position:220px 0,-240px 0}
}
@keyframes pulse{
    0%,100%{opacity:.25;transform:scale(.995)}
    50%{opacity:.5;transform:scale(1.01)}
}
@keyframes spin{
    to{transform:rotate(360deg)}
}
/* VERY subtle — safe for text */
@keyframes aiContentPulse{
    0%,100%{ opacity:1 }
    50%{ opacity:.88 }
}


.chat-linked-content{
    --bg: #f6f7fb;
    --panel: rgba(255,255,255,.9);
    --border: rgba(15,23,42,.10);
    --muted: rgba(15,23,42,.62);
    --shadow: 0 14px 40px rgba(15,23,42,.08);
    --assistant: #ffffff;
    --assistant-border: rgba(15,23,42,.12);
    --user: #2563eb;
    --user-border: rgba(37,99,235,.25);
    color: #0f172a;
    width: 90%;
    max-width: 90%;
}

.chat-linked-content .doc-shell{
    width: 100%;
    max-width: none;
    margin: 0 auto;
    padding: 18px 14px 28px;
}

.chat-linked-content .doc-topbar{
    position: sticky;
    top: 0;
    z-index: 10;
    background: rgba(246,247,251,.85);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(15,23,42,.08);
}

.chat-linked-content .doc-topbar .brand{
    display:flex; align-items:center; gap:.65rem;
    padding: 12px 14px;
}

.chat-linked-content .brand .logo{
    width: 36px; height: 36px;
    border-radius: 12px;
    display:flex; align-items:center; justify-content:center;
    background: rgba(37,99,235,.10);
    border: 1px solid rgba(37,99,235,.18);
    color: #2563eb;
    flex: 0 0 auto;
}

.chat-linked-content .layout{
    display:grid;
    grid-template-columns: 280px 1fr;
    gap: 16px;
    margin-top: 14px;
}
@media (max-width: 992px){
    .chat-linked-content .layout{ grid-template-columns: 1fr; }
    .chat-linked-content .sidebar{ position: static !important; }
}

.chat-linked-content .sidebar{
    position: sticky;
    top: 78px;
    align-self: start;
}

.chat-linked-content .card{
    border-radius: 14px;
    border-color: rgba(15,23,42,.10);
    box-shadow: 0 6px 18px rgba(15,23,42,.06);
}
.chat-linked-content .card-header{
    background: rgba(248,250,252,.9);
    border-bottom-color: rgba(15,23,42,.08);
}

.chat-linked-content .chip{
    display:inline-flex; align-items:center; gap:.4rem;
    padding:.32rem .6rem;
    border-radius:999px;
    background: rgba(2,6,23,.04);
    border: 1px solid rgba(2,6,23,.08);
    font-size: .82rem;
    color:#0f172a;
    white-space: nowrap;
}

.chat-linked-content .badge-soft{
    background: rgba(2,6,23,.04);
    border: 1px solid rgba(2,6,23,.08);
    color: #0f172a;
}

.chat-linked-content .muted{ color: var(--muted); }

/* Chat preview bits (bubble + below content) */
.chat-linked-content .preview{
    border: 1px solid rgba(15,23,42,.10);
    background: rgba(255,255,255,.8);
    border-radius: 16px;
    overflow: hidden;
}
.chat-linked-content .preview-head{
    border-bottom: 1px solid rgba(15,23,42,.08);
    padding: 10px 12px;
    display:flex; align-items:center; justify-content:space-between;
    background: rgba(255,255,255,.7);
}
.chat-linked-content .preview-body{
    padding: 12px;
    background: linear-gradient(180deg, rgba(255,255,255,.7), rgba(255,255,255,.9));
}

.chat-linked-content .msg{ display:flex; flex-direction:column; gap:8px; }
.chat-linked-content .bubble-row{ display:flex; gap:10px; align-items:flex-end; }
.chat-linked-content .avatar{
    width: 34px; height: 34px;
    border-radius: 50%;
    border: 1px solid rgba(15,23,42,.10);
    background: rgba(255,255,255,.95);
    display:flex; align-items:center; justify-content:center;
    flex: 0 0 auto;
    color: #0f172a;
}
.chat-linked-content .bubble{
    max-width: min(720px, 94%);
    border: 1px solid var(--assistant-border);
    border-radius: 18px;
    padding: 10px 12px;
    background: linear-gradient(180deg, #ffffff, #fbfdff);
    box-shadow: 0 6px 18px rgba(15,23,42,.06);
}
.chat-linked-content .below{
    margin-left: 0;
    max-width: min(720px, 94%);
    display:grid;
    gap: 10px;
}

/* Code blocks */
.chat-linked-content pre{
    margin: 0;
    padding: 12px;
    border-radius: 14px;
    border: 1px solid rgba(15,23,42,.10);
    background: #0b1220;
    color: #e5e7eb;
    overflow: auto;
    font-size: .86rem;
    line-height: 1.35;
}
.chat-linked-content code{ color: inherit; }

/* Dense contact card */
.chat-linked-content .contact-dense .card-body{ padding: .85rem; }
.chat-linked-content .contact-dense .title-row{
    display:flex; align-items:center; justify-content:space-between; gap:.75rem;
}
.chat-linked-content .contact-dense .identity{
    display:flex; gap:.6rem; align-items:center; min-width:0;
}
.chat-linked-content .contact-dense .identity .icon{
    width: 38px; height: 38px; border-radius: 12px;
    display:flex; align-items:center; justify-content:center;
    background: rgba(37,99,235,.10);
    border: 1px solid rgba(37,99,235,.18);
    color: #2563eb;
    flex: 0 0 auto;
}
.chat-linked-content .contact-dense .kv{
    display:grid;
    grid-template-columns: 22px 1fr;
    gap: .35rem .6rem;
    font-size: .92rem;
}
.chat-linked-content .contact-dense .kv i{ color: rgba(15,23,42,.55); }
.chat-linked-content .contact-dense .actions{ display:flex; flex-wrap:wrap; gap:.4rem; }
.chat-linked-content .btn-round{ border-radius: 14px; }
.chat-linked-content .btn-icon{
    width: 38px; height: 34px;
    display:inline-flex; align-items:center; justify-content:center;
    padding: 0;
}

/* File/Attachment rows */
.chat-linked-content .file-row{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap: 10px;
}
.chat-linked-content .file-left{
    display:flex; gap:.75rem; align-items:center; min-width:0;
}
.chat-linked-content .file-icon{
    width: 40px; height: 40px;
    border-radius: 12px;
    display:flex; align-items:center; justify-content:center;
    background: rgba(2,6,23,.04);
    border: 1px solid rgba(2,6,23,.08);
    flex: 0 0 auto;
}
.chat-linked-content .file-name{ min-width:0; }
.chat-linked-content .file-name .fw-semibold{
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.chat-linked-content .file-meta{
    font-size: .82rem;
    color: var(--muted);
}

/* Table shell */
.chat-linked-content .table-shell{ padding: .5rem; }
@media (min-width: 768px){ .chat-linked-content .table-shell{ padding: .75rem; } }
.chat-linked-content .table-responsive.table-scrollable{ max-height: 320px; overflow: auto; }
.chat-linked-content .table-responsive.table-scrollable thead.sticky-top th{ background: #fff; position: sticky; top: 0; z-index: 2; }
.chat-linked-content .table-responsive{
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(15,23,42,.08);
    background: #fff;
}
.chat-linked-content .table{ margin:0; }
.chat-linked-content .table>:not(caption)>*>*{
    border-color: rgba(15,23,42,.10);
    padding: .6rem .75rem;
}
.chat-linked-content .table .actions-sticky{
    position: sticky;
    right: 0;
    background: #fff;
    z-index: 3;
}
.chat-linked-content .table .actions-sticky .dropdown-menu{
    transform: translateX(-4px);
}
/* Reply options */
.chat-linked-content .reply-grid{
    display:flex;
    flex-wrap:wrap;
    gap: .5rem;
    align-items:center;
}
.chat-linked-content .reply-pill{
    display:inline-flex;
    align-items:center;
    gap:.45rem;
    border-radius: 999px;
    border: 1px solid rgba(15,23,42,.12);
    background: rgba(255,255,255,.85);
    padding: .45rem .7rem;
    font-size: .92rem;
    box-shadow: 0 6px 16px rgba(15,23,42,.06);
    cursor: pointer;
    user-select: none;
    transition: transform .06s ease, box-shadow .06s ease;
    white-space: nowrap;
}
.chat-linked-content .reply-pill:hover{
    transform: translateY(-1px);
    box-shadow: 0 10px 20px rgba(15,23,42,.10);
}
.chat-linked-content .reply-pill.primary{
    border-color: rgba(37,99,235,.25);
    background: rgba(37,99,235,.08);
    color: #1d4ed8;
}
.chat-linked-content .reply-pill.danger{
    border-color: rgba(239,68,68,.25);
    background: rgba(239,68,68,.08);
    color: #b91c1c;
}
.chat-linked-content .reply-pill .kbd{
    font-size: .75rem;
    color: rgba(15,23,42,.55);
    border: 1px solid rgba(15,23,42,.14);
    background: rgba(2,6,23,.03);
    padding: .1rem .35rem;
    border-radius: .5rem;
    margin-left: .15rem;
}

/* Cue cards */
.chat-linked-content .cue{
    border: 1px solid rgba(15,23,42,.10);
    background: rgba(255,255,255,.9);
    border-radius: 14px;
    padding: .75rem .85rem;
    box-shadow: 0 6px 18px rgba(15,23,42,.06);
}
.chat-linked-content .cue-head{
    display:flex;
    align-items:flex-start;
    justify-content:space-between;
    gap: .75rem;
}
.chat-linked-content .cue-title{
    display:flex; align-items:center; gap:.6rem;
    min-width:0;
}
.chat-linked-content .cue-icon{
    width: 34px; height: 34px;
    border-radius: 12px;
    display:flex; align-items:center; justify-content:center;
    border: 1px solid rgba(15,23,42,.10);
    background: rgba(2,6,23,.03);
    flex: 0 0 auto;
}
.chat-linked-content .cue-body{
    margin-top: .45rem;
    color: rgba(15,23,42,.70);
    font-size: .92rem;
}
.chat-linked-content .cue-actions{
    margin-top: .6rem;
    display:flex;
    flex-wrap:wrap;
    gap: .5rem;
}
.chat-linked-content .btn-round{ border-radius: 14px; }




@keyframes slideIn {
    from {
        transform: translateX(30px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.slide-in {
    animation: slideIn 0.8s ease forwards;
}

:root{--brand-c:#6f7bff;--brand-b:#4aa3ff;--brand-a:#7a5bff;}

.topbar .navbar{
    background:linear-gradient(90deg,var(--brand-c),var(--brand-a),var(--brand-b));
    box-shadow:0 17px 26px rgba(35, 58, 120, 0.19)
}
.dropdown-menu{
    padding-top:0px;
    padding-bottom:0px;
}

/* Jira v2 DataGrid overrides (global to avoid scoped CSS hover issues) */
.mq-grid-table-table tbody td{
    background-color:#fff;
}
.mq-grid-table-table tbody td:hover{
    background-color:#f1f5f9;
}
.mq-grid-table-table tbody td.select-col,
.mq-grid-table-table tbody td.sticky-actions{
    background-color:#fff;
}
.mq-grid-table-table tbody td.select-col:hover,
.mq-grid-table-table tbody td.sticky-actions:hover{
    background-color:#fff;
}
