* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f5f5f5;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
}

/* 导航栏 */
.navbar {
  background-color: #1890ff;
  color: white;
  padding: 15px 0;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.navbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.navbar h1 {
  font-size: 24px;
  font-weight: 600;
}

.nav-links a {
  color: white;
  text-decoration: none;
  margin-left: 20px;
  padding: 8px 15px;
  border-radius: 4px;
  transition: background-color 0.3s;
}

.nav-links a:hover {
  background-color: rgba(255,255,255,0.2);
}

/* 面包屑导航 */
.breadcrumb {
  margin-bottom: 20px;
}

.breadcrumb a {
  color: #1890ff;
  text-decoration: none;
}

/* 标题 */
h2 {
  margin-bottom: 20px;
  color: #262626;
  font-size: 28px;
}

h3 {
  margin: 20px 0 10px;
  color: #595959;
  font-size: 20px;
}

/* 会话列表 */
.conversation-list {
  display: grid;
  gap: 15px;
}

.conversation-item {
  background: white;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  transition: transform 0.2s, box-shadow 0.2s;
}

.conversation-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.conversation-item a {
  display: block;
  padding: 20px;
  text-decoration: none;
  color: inherit;
}

.conv-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.conv-id {
  font-weight: 600;
  color: #262626;
  font-size: 16px;
}

.conv-type {
  background-color: #e6f7ff;
  color: #1890ff;
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 12px;
}

.conv-info {
  display: flex;
  justify-content: space-between;
  color: #8c8c8c;
  font-size: 14px;
}

/* 会话详情 */
.conv-details {
  background: white;
  padding: 20px;
  border-radius: 8px;
  margin-bottom: 20px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.conv-details p {
  margin-bottom: 8px;
  color: #595959;
}

/* 消息列表 */
.message-list {
  display: grid;
  gap: 12px;
}

.message-item {
  background: white;
  padding: 15px;
  border-radius: 8px;
  border-left: 4px solid #1890ff;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.message-item.text {
  border-left-color: #1890ff;
}

.message-item.image {
  border-left-color: #52c41a;
}

.message-item.voice {
  border-left-color: #faad14;
}

.message-item.video {
  border-left-color: #f5222d;
}

.msg-header {
  display: flex;
  gap: 15px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}

.sender {
  font-weight: 600;
  color: #262626;
}

.conversation {
  color: #8c8c8c;
  font-size: 14px;
}

.time {
  color: #8c8c8c;
  font-size: 14px;
  margin-left: auto;
}

.msg-content {
  margin: 10px 0;
  color: #595959;
  word-wrap: break-word;
}

.media-tag {
  background-color: #fafafa;
  color: #8c8c8c;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 14px;
}

.msg-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid #f0f0f0;
}

.msg-type {
  background-color: #f0f0f0;
  color: #595959;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 12px;
}

.msg-meta a {
  color: #1890ff;
  text-decoration: none;
  font-size: 14px;
}

.msg-meta a:hover {
  text-decoration: underline;
}

/* 搜索表单 */
.search-form {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
  background: white;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.search-form input {
  flex: 1;
  padding: 10px 15px;
  border: 1px solid #d9d9d9;
  border-radius: 4px;
  font-size: 16px;
}

.search-form input:focus {
  outline: none;
  border-color: #1890ff;
  box-shadow: 0 0 0 2px rgba(24,144,255,0.2);
}

.search-form button {
  padding: 10px 30px;
  background-color: #1890ff;
  color: white;
  border: none;
  border-radius: 4px;
  font-size: 16px;
  cursor: pointer;
  transition: background-color 0.3s;
}

.search-form button:hover {
  background-color: #40a9ff;
}

.search-result-count {
  margin-bottom: 15px;
  color: #8c8c8c;
}

/* 用户表格 */
.user-table {
  width: 100%;
  background: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  border-collapse: collapse;
}

.user-table thead {
  background-color: #fafafa;
}

.user-table th {
  padding: 15px;
  text-align: left;
  font-weight: 600;
  color: #262626;
  border-bottom: 2px solid #f0f0f0;
}

.user-table td {
  padding: 15px;
  border-bottom: 1px solid #f0f0f0;
  color: #595959;
}

.user-table tbody tr:hover {
  background-color: #fafafa;
}

/* 分页 */
.pagination {
  display: flex;
  justify-content: center;
  gap: 15px;
  align-items: center;
  margin-top: 20px;
  padding: 20px;
  background: white;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.pagination a {
  color: #1890ff;
  text-decoration: none;
  padding: 8px 16px;
  border: 1px solid #d9d9d9;
  border-radius: 4px;
  transition: all 0.3s;
}

.pagination a:hover {
  border-color: #1890ff;
  background-color: #e6f7ff;
}

/* 空状态 */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  background: white;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.empty-state p {
  color: #8c8c8c;
  font-size: 16px;
}

/* 响应式设计 */
@media (max-width: 768px) {
  .navbar .container {
    flex-direction: column;
    gap: 15px;
  }

  .nav-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
  }

  .nav-links a {
    margin: 5px;
  }

  .msg-header {
    flex-direction: column;
    gap: 5px;
  }

  .time {
    margin-left: 0;
  }

  .user-table {
    font-size: 14px;
  }

  .user-table th,
  .user-table td {
    padding: 10px 8px;
  }
}
