@import url('box.css');

.rightbox-container {
    right: 0;
    width: 350px;
    box-shadow: -2px 0 8px var(--border-shadow-color);
    border-left: 1px solid var(--border-color);
}

.rightbox-chat-area {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: 16px;
    background: var(--1-color);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.rightbox-resizer,
.rightbox-textarea-top-resizer {
    background: transparent;
    transition: background 0.2s;
}

.rightbox-resizer {
    position: absolute;
    top: 0;
    width: 6px;
    height: 100%;
    cursor: ew-resize;
    z-index: 1001;
    left: 0;
}

.rightbox-textarea-top-resizer {
    height: 6px;
    cursor: ns-resize;
    width: 100%;
    margin-bottom: -2px;
    z-index: 2;
}

.rightbox-resizer:hover,
.rightbox-textarea-top-resizer:hover {
    background: var(--hover-color);
}

.rightbox-message {
    max-width: 80%;
    padding: 8px 14px;
    border-radius: 16px;
    font-size: var(--fontsize-normal);
    line-height: 1.5;
    word-break: break-word;
}

.rightbox-message-user {
    align-self: flex-end;
    background: var(--selected-color);
    color: var(--selected-text-color);
}

.rightbox-message-ai {
    align-self: flex-start;
    background: var(--2-color);
    color: var(--text-color);
}

.rightbox-input-area {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 10px 12px;
    padding-top: 0px;
    border-top: 1px solid var(--border-color);
    background: var(--1-color);
}

.rightbox-input-area .rightbox-input-textarea {
    min-height: 72px;
    max-height: 200px;
    padding: 8px 12px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background: var(--0-color);
    color: var(--text-color);
    font-family: var(--fonttype-normal);
    font-size: var(--fontsize-normal);
    outline: none;
    resize: vertical;
    box-sizing: border-box;
    line-height: 1.5;
    width: 100%;
    overflow-x: auto;
    white-space: pre-wrap;
    word-break: break-word;
    max-width: 100%;
}

.rightbox-send-btn-wrapper {
    display: flex;
    justify-content: flex-end;
    margin-top: 2px;
}

.rightbox-send-btn-wrapper button {
    padding: 6px 8px;
    min-width: 40px;
    border-radius: 6px;
    border: none;
    background: var(--selected-color);
    color: var(--selected-text-color);
    font-family: var(--fonttype-normal);
    font-size: var(--fontsize-button);
    cursor: pointer;
    transition: background 0.2s;
}

.rightbox-send-btn-wrapper button:hover {
    background: var(--hover-color);
}

.rightbox-typing-indicator {
    display: flex;
    align-items: center;
    min-height: 24px;
    padding: 4px 12px;
}

.typing-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    margin: 0 2px;
    background: #bbb;
    border-radius: 50%;
    opacity: 0.6;
    animation: typing-bounce 1.2s infinite both;
}

.typing-dot:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-dot:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typing-bounce {
    0%, 80%, 100% { transform: scale(0.7); opacity: 0.6; }
    40% { transform: scale(1); opacity: 1; }
}

