.mtl-ai-page {
    min-height: 100dvh;
    overflow: hidden;
    background: #050505;
    color: #fff
}

.mtl-ai-page .mtl-site-footer {
    display: none
}

.mtl-ai-stage {
    position: relative;
    isolation: isolate;
    height: calc(100dvh - 74px);
    min-height: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 28px 24px;
    background: #050505;
    overflow: hidden
}

.mtl-ai-stage::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -2;
    background: linear-gradient(180deg, rgba(0, 0, 0, .48), rgba(0, 0, 0, .88)), url("../images/services/AI-Development-images/top-shape.webp") center top/cover no-repeat fixed
}

.mtl-ai-stage::after {
    content: "";
    position: absolute;
    width: 640px;
    height: 640px;
    left: 50%;
    top: 55%;
    z-index: -1;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    background: rgba(13, 182, 218, .14);
    filter: blur(110px);
    pointer-events: none
}

.mtl-ai-shell {
    width: 80vw !important;
    height: 100%;
    min-height: 0;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto auto auto auto;
    padding: 34px;
    /* border: 1px solid rgba(255, 255, 255, .16); */
    border-radius: 28px;
    
    /* box-shadow: 0 32px 90px rgba(0, 0, 0, .55); */
    /* backdrop-filter: blur(20px); */
    /* -webkit-backdrop-filter: blur(20px) */
}

.mtl-ai-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 24px;
    padding: 0 4px 24px;
    border-bottom: 1px solid rgba(255, 255, 255, .12)
}

.mtl-ai-heading span {
    font-size: 12px;
    letter-spacing: .18em;
    color: #11bada;
    font-weight: 700
}

.mtl-ai-heading h1 {
    display: none;
    margin: 0;
    font-size: clamp(30px, 2vw, 50px);
    line-height: 1;
    color: #fff
}

.mtl-ai-transcript {
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 28px 4px;
    overflow-y: auto !important;
    scrollbar-width: thin;
    scrollbar-color: #164a67 transparent;
    overflow-anchor: none;

}

.mtl-ai-message {
    max-width: min(720px, 88%);
    padding: 16px 18px;
    border-radius: 18px
}

.mtl-ai-message span {
    display: block;
    margin-bottom: 6px;
    color: #68dff2;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .1em
}

.mtl-ai-message p {
    margin: 0;
    color: #f4f7fa;
    font-size: 15px;
    line-height: 1.65;
    white-space: pre-wrap;
    overflow-wrap: anywhere
}

.mtl-ai-message--assistant {
    align-self: flex-start;
    border: 1px solid rgba(255, 255, 255, .12);
    background: rgba(255, 255, 255, .08);
    border-bottom-left-radius: 5px
}

.mtl-ai-message--user {
    align-self: flex-end;
    background: linear-gradient(135deg, #0d6ea4, #0bb6d8);
    border-bottom-right-radius: 5px
}

.mtl-ai-message--user span {
    color: rgba(255, 255, 255, .74);
    text-align: right
}

.mtl-ai-status {
    min-height: 24px;
    padding: 0 4px 8px;
    color: #8fe8f6;
    font-size: 13px
}

.mtl-ai-status.is-error {
    color: #ff9d9d
}

.mtl-ai-attachment {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    width: max-content;
    max-width: 100%;
    margin: 0 4px 10px;
    padding: 8px 10px 8px 14px;
    border: 1px solid rgba(104, 223, 242, .35);
    border-radius: 999px;
    background: rgba(13, 182, 218, .1);
    font-size: 13px
}

.mtl-ai-attachment[hidden] {
    display: none
}

.mtl-ai-attachment-name {
    max-width: 360px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis
}

.mtl-ai-remove-file {
    width: 26px;
    height: 26px;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, .12);
    color: #fff;
    font-size: 18px;
    cursor: pointer
}

.mtl-ai-composer {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: end;
    gap: 12px;
    padding: 12px;
    border: 1px solid rgba(255, 255, 255, .15);
    border-radius: 20px;
    background: rgba(0, 0, 0, .54)
}

.mtl-ai-upload {
    height: 52px;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0 14px;
    border-radius: 13px;
    color: #cbd5dd;
    cursor: pointer
}

.mtl-ai-upload input {
    display: none
}

.mtl-ai-upload span {
    font-size: 24px;
    font-weight: 300
}

.mtl-ai-upload b {
    font-size: 13px
}

.mtl-ai-composer textarea {
    width: 100%;
    max-height: 160px;
    min-height: 52px;
    padding: 15px 4px;
    resize: none;
    border: 0;
    outline: 0;
    background: transparent;
    color: #fff;
    font: inherit;
    line-height: 1.45
}

.mtl-ai-composer textarea::placeholder {
    color: #9099a2
}

.mtl-ai-send {
    height: 52px;
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 0 18px;
    border: 0;
    border-radius: 13px;
    background: #fff;
    color: #071017;
    font-weight: 700;
    cursor: pointer
}

.mtl-ai-send b {
    font-size: 18px
}

.mtl-ai-send:disabled,
.mtl-ai-upload:has(input:disabled) {
    opacity: .5;
    cursor: not-allowed
}

.mtl-ai-note {
    margin: 12px 0 0;
    text-align: center;
    color: #89939d;
    font-size: 12px
}

@media(max-width:768px) {
    .mtl-ai-stage {
        height: calc(100dvh - 74px);
        padding: 14px;
        background-attachment: scroll
    }

    .mtl-ai-shell {
        width: 100% !important;
        height: 100%;
        min-height: 0;
        padding: 20px 14px;
        border-radius: 20px
    }

    .mtl-ai-heading {
        display: block
    }

    .mtl-ai-heading span {
        display: block;
        margin-bottom: 10px
    }

    .mtl-ai-heading h1 {
        font-size: 34px
    }

    .mtl-ai-message {
        max-width: 94%
    }

    .mtl-ai-composer {
        grid-template-columns: auto minmax(0, 1fr) auto;
        gap: 4px
    }

    .mtl-ai-upload {
        padding: 0 9px
    }

    .mtl-ai-upload b,
    .mtl-ai-send span {
        display: none
    }

    .mtl-ai-send {
        width: 50px;
        justify-content: center;
        padding: 0
    }

    .mtl-ai-attachment-name {
        max-width: 220px
    }
}