// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
// SPDX-License-Identifier: MIT-0

@use '@cloudscape-design/design-tokens' as cs;

.chat-container {
    display: flex;
    flex-direction: column;
    gap: cs.$space-static-l;
    height: calc(100vh - var(--header-height, 60px) - var(--layout-spacing, 32px));
    width: 100%;
    overflow: hidden;
    position: relative;

    @media only screen and (min-width: 688px) and (max-width: 1280px) {
        padding-inline: 60px;
    }
}

.messages {
    display: flex;
    flex-direction: column;
    gap: cs.$space-scaled-xs;

    padding-block-start: cs.$space-scaled-xxs;
    padding-block-end: cs.$space-container-horizontal;
    padding-inline: cs.$space-container-horizontal;
}

.access-denied-alert-wrapper {
    display: flex;
    gap: cs.$space-scaled-s;

    &__box {
        flex: 1;
        overflow-x: auto;
        padding-inline: cs.$space-scaled-m;
        padding-block: cs.$space-scaled-s;
        border: 2px solid cs.$color-border-input-default;
        border-radius: cs.$border-radius-input;
        background: cs.$color-background-input-default;
    }
}

/* Ensure the ScrollableContainer gets remaining height */
.scrollable-container {
    flex: 1;
    overflow-y: auto;
    min-height: 0; /* Important for Firefox */
}
