.chat-panel {
    font-family: inherit, Arial, Helvetica, sans-serif;
    position: fixed;
    right: 24px;
    bottom: 95px;
    width: 380px;
    height: 600px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 8px 30px rgba(0,0,0,.18);
    overflow: hidden;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    opacity: 0;
    visibility: hidden;
    transform:
        translateY(20px)
        scale(.95);
    transition:
        opacity .2s ease,
        visibility .2s ease,
        transform .2s ease;
}

.chat-panel.open {
    opacity: 1;
    visibility: visible;
    transform:
        translateY(0)
        scale(1);
}

.chat-header {
    font-family: "Ubuntu", Arial, sans-serif;
    font-weight: 500;
    font-style: normal;

    height: 50px;
    background: #1f4e79;
    color: white;
    display: flex;
    align-items: center;
    padding: 0 15px;
    box-sizing: border-box;
    font-weight: bold;
}

.chat-header-logo {
    height: 30px !important;
    width: auto !important;

    display: inline-block !important;
    vertical-align: middle !important;

    margin: 0 !important;
    padding: 0 !important;
    margin-right: 8px !important;
    border: 0 !important;
}

.chat-panel h2,
.chat-panel h3,
.webchat__initialsAvatar__initials {
    font-family: "Ubuntu", Arial, sans-serif;
    font-weight: 500;
    font-style: normal;
}

.chat-body-wrap {
    position: relative;
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.chat-body {
    flex: 1;
    overflow: auto;
    padding: 15px;
    white-space: pre-wrap;
    font-family: monospace;
}
/* .chat-body {
    height: calc(100% - 50px);
    overflow: auto;
    padding: 15px;
    white-space: pre-wrap;
    font-family: monospace;
} */

.chat-body a {
    color: #055BA7;
    text-decoration: none;
}
.chat-body a:hover {
    text-decoration: underline;
}

/* Suggested prompt chips shown at the start of a new session */
.chat-suggestions {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 10px 12px 12px;
    background: linear-gradient(to top, #ffffff 65%, rgba(255,255,255,0));
    display: flex;
    flex-direction: column;
    gap: 6px;
    pointer-events: none;
}

.chat-suggestions[hidden] {
    display: none;
}

.chat-suggestions-label {
    margin: 0 0 2px 2px;
    font-family: "Ubuntu", Arial, sans-serif;
    font-size: 12px;
    font-weight: 500;
    color: #5a6b7a;
    pointer-events: none;
}

.chat-suggestions-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
    pointer-events: auto;
}

.chat-suggestion-chip {
    font-family: "Ubuntu", Arial, sans-serif;
    text-align: left;
    background: #f3f6f9;
    border: 1px solid #d7e2ec;
    color: #1f4e79;
    font-size: 13px;
    line-height: 1.3;
    border-radius: 14px;
    padding: 8px 12px;
    cursor: pointer;
    transition: background .15s ease, border-color .15s ease;
}

.chat-suggestion-chip:hover,
.chat-suggestion-chip:focus-visible {
    background: #e6eef7;
    border-color: #1f4e79;
}

.chat-suggestion-chip:disabled {
    opacity: .5;
    cursor: default;
}

/* Collapsed launcher: sliding square that opens on hover, like a pull-tab */
.chat-button {
    position: fixed;
    right: 24px;
    bottom: 24px;
    height: 60px;
    width: 60px;
    border: none;
    border-radius: 14px;
    background: #1f4e79;
    color: #ffffff;
    cursor: pointer;
    z-index: 10000;
    box-shadow: 0 6px 20px rgba(0,0,0,.28);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding: 0 10px;
    box-sizing: border-box;
    gap: 10px;

    transition:
        width .28s ease,
        box-shadow .2s ease,
        background-color .2s ease;
}

.chat-button-icon {
    flex: 0 0 auto;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    overflow: hidden;
}

.chat-button-logo {
    width: 40px !important;
    height: 40px !important;
    object-fit: cover;
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
}

.chat-button-label {
    flex: 0 0 auto;
    font-family: "Ubuntu", Arial, sans-serif;
    font-weight: 600;
    font-size: 14px;
    color: #ffffff;
    white-space: nowrap;
    opacity: 0;
    transform: translateX(-4px);
    transition: opacity .2s ease .05s, transform .2s ease .05s;
}

.chat-button:hover,
.chat-button:focus-visible,
.chat-button:focus-within {
    width: 190px;
    background: #163a59;
}

.chat-button:hover .chat-button-label,
.chat-button:focus-visible .chat-button-label,
.chat-button:focus-within .chat-button-label {
    opacity: 1;
    transform: translateX(0);
}

.chat-notification {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 14px;
    height: 14px;
    background: #d71920;
    border: 2px solid #ffffff;
    border-radius: 50%;
    box-sizing: border-box;
}

.chat-button.has-notification {
    box-shadow:
        0 0 0 4px rgba(215, 25, 32, 0.18),
        0 6px 20px rgba(0,0,0,.2);
}


.webchat__send-box__main form {
    min-height: 50px;
}

@media (max-width: 600px) {

    .chat-panel {
        left: 10px;
        right: 10px;
        width: auto;
        height: calc(100vh - 100px);
    }
}

/* Fix oversized markdown headings inherited from NSCA site */
.chat-panel .webchat__render-markdown h2 {
    font-size: 20px !important;
    line-height: 1.3 !important;
    margin: 8px 0 !important;
}

/* Fix links inside markdown bullet lists only */
.chat-panel .webchat__render-markdown li > a {
    display: inline !important;
}

/* Fix external-link image/icon inside markdown bullet lists only */
.chat-panel .webchat__render-markdown li img {
    display: inline-block !important;
    vertical-align: middle;
}

/* Adding footer with alliantAI logo */

.chat-footer {
    height: 28px;
    min-height: 28px;

    display: flex;
    align-items: center;
    justify-content: center;

    gap: 3px;

    border-top: 1px solid #e5e5e5;
    background: #ffffff;

    font-family: Arial, Helvetica, sans-serif !important;
    font-size: 11px !important;
    font-weight: 400 !important;
}

.chat-footer-text {
    color: #00008f !important;
    font-size: 11px !important;
    font-weight: 600 !important;
    margin-right: 2px !important;
}

.chat-footer-link {
    display: inline-flex !important;
    align-items: center !important;

    gap: 0 !important;
    margin: 0 !important;
    padding: 0 !important;

    color: #00008f !important;
    text-decoration: none !important;

    font-size: 11px !important;
    font-weight: 600 !important;
}

.chat-footer-link:hover {
    text-decoration: underline !important;
}

.chat-footer-logo {
    height: 20px !important;
    width: auto !important;

    margin: 0 0 0 -2px !important;
    padding: 0 !important;

    vertical-align: middle !important;
}