#ws-test-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 15px;
}

#ws-test-container .preview-card {
    flex: 1;
    min-height: 300px;
}

#ws-test-container .response-body {
    min-height: 200px;
    max-height: 500px;
    overflow-y: auto;
}

.message-item {
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 10px;
    transition: all 0.2s;
}

.message-item:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.message-item.sent {
    background: #dbeafe;
    border-left: 4px solid #3b82f6;
}

.message-item.received {
    background: #dcfce7;
    border-left: 4px solid #16a34a;
}

.message-item.system {
    background: #fef3c7;
    border-left: 4px solid #d97706;
}

.message-item.error {
    background: #fee2e2;
    border-left: 4px solid #dc2626;
}

.message-time {
    font-size: 12px;
    color: #6b7280;
    margin-bottom: 5px;
}

.message-type {
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 8px;
}

.message-item.sent .message-type {
    color: #3b82f6;
}

.message-item.received .message-type {
    color: #16a34a;
}

.message-item.system .message-type {
    color: #d97706;
}

.message-item.error .message-type {
    color: #dc2626;
}

.message-content pre {
    margin: 0;
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 13px;
    line-height: 1.6;
    color: #374151;
    white-space: pre-wrap;
    word-break: break-all;
}

.message-actions {
    display: flex;
    gap: 8px;
    margin-top: 10px;
}

.message-count {
    font-size: 13px;
    color: #6b7280;
}

body.dark .message-item.sent {
    background: #1e3a5f;
}

body.dark .message-item.received {
    background: #1e3a2f;
}

body.dark .message-item.system {
    background: #4a3d1f;
}

body.dark .message-item.error {
    background: #5f1e1e;
}

body.dark .message-content pre {
    color: #e5e7eb;
}

body.dark .message-time {
    color: #9ca3af;
}

@media (max-width: 768px) {
    .form-group-inline {
        flex-direction: column;
    }

    .form-select-inline {
        border-radius: 8px 8px 0 0;
        border-right: none;
        border-bottom: 2px solid #e5e7eb;
    }

    body.dark .form-select-inline {
        border-bottom-color: #495057;
    }

    .form-group-inline .setting-input {
        border-radius: 0 0 8px 8px;
        border-left: none;
        border-top: none;
    }
}