/* ========== LLM 대기열 패널 ========== */
#queue-panel {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 350px;
    max-height: 500px;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.15);
    z-index: 9999;
    display: none;
    flex-direction: column;
    overflow: hidden;
}

#queue-panel.visible {
    display: flex;
}

#queue-panel-header {
    padding: 12px 16px;
    background: #f5f5f5;
    border-bottom: 1px solid #e0e0e0;
    font-weight: 600;
    font-size: 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#queue-panel-close {
    cursor: pointer;
    font-size: 18px;
    color: #999;
    background: none;
    border: none;
}

#queue-list {
    padding: 8px;
    overflow-y: auto;
    flex: 1;
}

.queue-item {
    padding: 10px 12px;
    border-radius: 8px;
    margin-bottom: 6px;
    background: #fafafa;
    border: 1px solid #eee;
}

.queue-item-title {
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.queue-item-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
}

.queue-position {
    color: #666;
}

/* 상태 뱃지 */
.status-badge {
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.status-pending {
    background: #fff3cd;
    color: #856404;
}

.status-processing {
    background: #cce5ff;
    color: #004085;
}

.status-completed {
    background: #d4edda;
    color: #155724;
}

.status-failed {
    background: #f8d7da;
    color: #721c24;
}

/* 스피너 */
.spinner {
    display: inline-block;
    width: 12px;
    height: 12px;
    border: 2px solid #ccc;
    border-top-color: #333;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    vertical-align: middle;
    margin-right: 4px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 토스트 알림 */
.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 14px;
    z-index: 10000;
    animation: slideIn 0.3s ease;
    max-width: 400px;
}

.toast-info {
    background: #cce5ff;
    color: #004085;
}

.toast-error {
    background: #f8d7da;
    color: #721c24;
}

.toast-success {
    background: #d4edda;
    color: #155724;
}

@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* 모바일 대응 */
@media (max-width: 768px) {
    #queue-panel {
        width: calc(100% - 20px);
        right: 10px;
        bottom: 10px;
        max-height: 40vh;
    }
}
