/* Endeavor Specific Global Style */

main.documentation p {
    font-size: 1.05rem;
    line-height: 1.25;
}

main.documentation ul {
    font-size: 1.05rem;
    line-height: 1.25;
}

textarea {
    field-sizing: content;
}

@supports (field-sizing: content) {
    textarea {
        resize: none;
        min-height: 6rem !important;
    }
}

.select2-container--bootstrap-5 .select2-selection--multiple {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    min-height: 38px !important;
}

.select2-container--bootstrap-5 .select2-selection--multiple .select2-selection__rendered {
    display: inline-flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    flex: 1 1 auto !important;
    padding: 2px 4px !important;
    margin: 0 !important;
    list-style: none !important;
    width: auto !important;
    height: auto !important;
    overflow: visible !important;
}

.select2-container--bootstrap-5 .select2-selection__choice {
    display: inline-flex !important;
    align-items: center !important;
}

/* Search sits naturally to the right of the tags */
.select2-container--bootstrap-5 .select2-search--inline {
    display: inline-flex !important;
    align-items: center !important;
    flex: 0 1 auto !important;
}

.select2-container--bootstrap-5 .select2-search--inline textarea {
    height: 1.5em !important;
    min-height: unset !important;
    max-height: 1.5em !important;
    resize: none !important;
    overflow: hidden !important;
    line-height: 1.5 !important;
    padding: 0 !important;
    margin: 0 !important;
    box-sizing: border-box !important;
}

/* Align alert icon center with text */
.align-icon-middle {
    margin-top: 10px !important;
}

/* Text Styles */
.text-code {
    font-size: 0.656rem;
    color: #e83e8c;
    font-family: SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

.metric-description {
    max-width: 50ch;
    white-space: normal;
    overflow-wrap: anywhere;
}

/* Agent Card Custom Left Border Colors */
.border-quill {
    border-left-color: #667EEA !important;
}

.border-forecaster {
    border-left-color: #E67E22 !important;
}

.border-prior-auth {
    border-left-color: #A1887F !important;
}

.border-default {
    border-left-color: #1D65A6 !important;
}

/* Border Left Styles */
.border-start-4 {
    border-left-width: 4px !important;
}

/* Styles the input/output for prompts e.g. model output and rendered prompts */
pre.llm-io {
    white-space: pre-wrap;
    word-break: break-word;
    font-family: 'Poppins', sans-serif;
    font-size: .95rem;
    color: #212529;
    min-height: 128px;
    max-height: 768px;
    overflow-y: auto;
}

/* Avatar styles */
.avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 12px;
}

/* Bao Link Styles */
#bao-link {
    margin-left: 75px;
    padding-bottom: 15.2px;
}

/* Studio Sidebar Agent Name Marquee Styles */
.sidebar .sidebar-header .agent-name-marquee {
    display: inline-block;
    max-width: 20ch;
    overflow: hidden;
    vertical-align: bottom;
}

.sidebar .sidebar-header .agent-name-static {
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidebar .sidebar-header .agent-name-scroll {
    display: none;
    white-space: nowrap;
}

/* The marquee animation scrolls the scrolling agent name to the left. */
@keyframes marquee-scroll {

    0%,
    10% {
        transform: translateX(0);
    }

    90%,
    100% {
        transform: translateX(calc(-1 * var(--scroll-distance, 0px)));
    }
}

.sidebar .sidebar-header .agent-name-marquee.is-scrolling .agent-name-static {
    display: none;
}

.sidebar .sidebar-header .agent-name-marquee.is-scrolling .agent-name-scroll {
    display: block;
}

.sidebar .sidebar-header .agent-name-marquee.is-scrolling .agent-name-scroll,
.sidebar .sidebar-header .agent-name-marquee:hover .agent-name-scroll {
    animation: marquee-scroll var(--marquee-duration, 8s) linear 1;
}

.sidebar .sidebar-header .agent-name-marquee:hover .agent-name-static {
    display: none;
}

.sidebar .sidebar-header .agent-name-marquee:hover .agent-name-scroll {
    display: block;
}

/* Collapse Button Chevron Right Icon Toggle Styles */
/* When a card is collapsed, the chevron right icon is rotated 90 degrees to the right. */
.collapse-btn i.fa-chevron-right {
    transition: transform 150ms ease;
}

/* When a card is expanded, the chevron right icon is rotated 90 degrees downward. */
.collapse-btn[aria-expanded="true"] i.fa-chevron-right {
    transform: rotate(90deg);
}

/* Add responsive styles to embedded videos */
.embedded-video-container {
    position: relative;
    width: 85%;
    height: 0;
    padding-bottom: 56.25%;
    overflow: hidden;
}

.embedded-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* Upload File Dropzone Styles */
.file-dropzone {
    border: 2px dashed var(--bs-border-color);
    cursor: pointer;
    transition: all 0.2s ease-in-out;
}

.file-dropzone:hover,
.file-dropzone:focus-within {
    border-color: var(--bs-primary);
    background-color: var(--bs-primary-bg-subtle);
    box-shadow: 0 0 0 0.25rem var(--bs-primary-bg-subtle);
}

/* Compass Context Pills Styles */
.compass-pills>.compass-link.active {
    background-color: var(--bs-white);
    border-color: var(--bs-primary) !important;
}

.compass-pills>.compass-link.active .context-icon-container {
    background-color: var(--bs-primary-bg-subtle);
}

.compass-pills>.compass-link.active .context-icon {
    color: var(--bs-primary) !important;
}

/* Compass stepper: progress indicator at top of compass pages */
.compass-stepper-list {
    position: relative;
}

.compass-stepper-item {
    position: relative;
    min-width: 0;
}

/* Horizontal connector between step circles. Each segment is drawn in two halves
   so that the line is not covered by the next item. Halves are extended by half of
   gap-2 (0.25rem) so the line spans the flex gap. A 1px overlap at the join avoids
   subpixel gaps. */
.compass-stepper-item::before,
.compass-stepper-item::after {
    content: "";
    position: absolute;
    background-color: var(--bs-border-color);
    z-index: 0;
    top: 1rem;
    height: 2px;
    transform: translateY(-50%);
    pointer-events: none;
}

.compass-stepper-item::before {
    left: calc(-0.25rem - 1px);
    width: calc(50% + 0.25rem + 1px);
}

.compass-stepper-item::after {
    left: 50%;
    width: calc(50% + 0.25rem + 1px);
}

.compass-stepper-item:first-child::before {
    display: none;
}

.compass-stepper-item:last-child::after {
    display: none;
}

/* Align connector in center of step circle when nav-link has py-2 (< 768px): circle center = 0.5rem + 1rem = 1.5rem */
@media (max-width: 767.98px) {
    .compass-stepper-item::before,
    .compass-stepper-item::after {
        top: 1.5rem;
    }
}

.compass-stepper-item .compass-stepper-number {
    width: 2rem;
    height: 2rem;
    font-size: 0.875rem;
    position: relative;
    z-index: 1;
    background-color: var(--bs-secondary-bg);
    color: var(--bs-secondary-color);
}

.compass-stepper-item.active .compass-stepper-number {
    background-color: var(--bs-primary);
    color: var(--bs-primary-color);
}

.compass-stepper-item .nav-link {
    cursor: default;
}

.compass-stepper-item.active .compass-stepper-title {
    color: var(--bs-body-color);
}

.compass-stepper-item:not(.active) .compass-stepper-title,
.compass-stepper-item:not(.active) .compass-stepper-description {
    color: var(--bs-secondary-color);
}

/* Decrease step name font size and hide step description on mobile devices. */
@media (max-width: 575.98px) {
    .compass-stepper-description {
        display: none !important;
    }
    .compass-stepper-title {
        font-size: 12px;
    }
}

/* Recording Dot Pulse Animation */
.recording-dot {
    animation: recording-dot-pulse 1.2s ease-in-out infinite;
  }
  .recording-dot:nth-child(1) { animation-delay: 0s; }
  .recording-dot:nth-child(2) { animation-delay: 0.2s; }
  .recording-dot:nth-child(3) { animation-delay: 0.4s; }
  
  @keyframes recording-dot-pulse {
    0%, 80%, 100% { opacity: 0.25; }
    40% { opacity: 1; }
  }