/* 现代化音乐用户中心样式 - 响应式设计 */

/* 基础变量 */
:root {
  --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --secondary-gradient: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  --accent-gradient: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
  --bg-gradient: linear-gradient(120deg, #a8edea 0%, #fed6e3 100%);
  --card-bg: rgba(255, 255, 255, 0.95);
  --card-hover: rgba(255, 255, 255, 1);
  --text-primary: #2d3748;
  --text-secondary: #4a5568;
  --text-accent: #667eea;
  --border-radius: 16px;
  --border-radius-lg: 24px;
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.15);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.2);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 全局样式 */
* {
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background: var(--bg-gradient);
  margin: 0;
  padding: 0;
  min-height: 100vh;
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

/* 容器布局 */
.app-container {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* 顶部导航栏 */
.top-nav {
  background: var(--card-bg);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-sm);
}

.nav-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-title {
  font-size: 1.5rem;
  font-weight: bold;
  background: var(--primary-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin: 0;
}

.user-info {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.user-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--primary-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: bold;
}

/* 主要内容区域 */
.main-content {
  flex: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1rem;
  width: 100%;
}

/* 标签页导航 */
.tab-nav {
  display: flex;
  background: var(--card-bg);
  border-radius: var(--border-radius-lg);
  padding: 0.5rem;
  margin-bottom: 2rem;
  box-shadow: var(--shadow-md);
  backdrop-filter: blur(20px);
}

.tab-btn {
  flex: 1;
  padding: 0.75rem 1rem;
  border: none;
  background: none;
  color: var(--text-secondary);
  border-radius: var(--border-radius);
  cursor: pointer;
  transition: var(--transition);
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.tab-btn.active {
  background: var(--primary-gradient);
  color: white;
  box-shadow: var(--shadow-sm);
}

.tab-btn:hover:not(.active) {
  background: rgba(102, 126, 234, 0.1);
  color: var(--text-accent);
}

/* 标签页内容 */
.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
  animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* 卡片样式 */
.card {
  background: var(--card-bg);
  border-radius: var(--border-radius-lg);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow-md);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: var(--transition);
}

.card:hover {
  background: var(--card-hover);
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.card-title {
  font-size: 1.25rem;
  font-weight: bold;
  color: var(--text-primary);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* 输入组 */
.input-group {
  position: relative;
  margin-bottom: 1rem;
}

.input-label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: var(--text-secondary);
}

/* 输入框图标样式 */
.input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.input-icon {
  position: absolute;
  left: 12px;
  color: #999;
  font-size: 16px;
  z-index: 1;
  pointer-events: none;
}

.input-wrapper .form-input {
  padding-left: 40px;
}

.input-wrapper .form-select {
  padding-left: 40px;
}

.form-input {
  width: 100%;
  padding: 0.75rem 1rem 0.75rem 3rem;
  border: 2px solid rgba(102, 126, 234, 0.2);
  border-radius: var(--border-radius);
  background: rgba(255, 255, 255, 0.8);
  font-size: 1rem;
  transition: var(--transition);
  outline: none;
}

.form-input:focus {
  border-color: var(--text-accent);
  background: white;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-select {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 2px solid rgba(102, 126, 234, 0.2);
  border-radius: var(--border-radius);
  background: rgba(255, 255, 255, 0.8);
  font-size: 1rem;
  transition: var(--transition);
  outline: none;
}

/* 按钮样式 */
.btn {
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: var(--border-radius);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  text-decoration: none;
  outline: none;
}

.btn-primary {
  background: var(--primary-gradient);
  color: white;
  box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.btn-secondary {
  background: var(--secondary-gradient);
  color: white;
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--text-accent);
  color: var(--text-accent);
}

.btn-outline:hover {
  background: var(--text-accent);
  color: white;
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
}

.btn-lg {
  padding: 1rem 2rem;
  font-size: 1.125rem;
}

/* 歌单列表 */
.playlist-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.playlist-card {
  background: var(--card-bg);
  border-radius: var(--border-radius);
  padding: 1rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  cursor: pointer;
  border: 2px solid transparent;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.playlist-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.playlist-card.selected {
  border-color: var(--text-accent);
  background: rgba(102, 126, 234, 0.05);
}

.playlist-cover {
  width: 80px;
  height: 80px;
  border-radius: var(--border-radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 2rem;
  font-weight: bold;
  align-self: center;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.playlist-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.playlist-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.playlist-name {
  font-weight: bold;
  color: var(--text-primary);
  margin: 0;
  font-size: 1rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
}

.playlist-count {
  background: var(--accent-gradient);
  color: white;
  padding: 0.25rem 0.5rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: bold;
  white-space: nowrap;
  margin-left: 0.5rem;
}

.playlist-meta {
  margin-bottom: 0.5rem;
}

.playlist-update {
  color: var(--text-secondary);
  font-size: 0.75rem;
}

.playlist-actions {
  display: flex;
  gap: 0.5rem;
  margin-top: auto;
}

/* 歌曲卡片 */
.song-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1rem;
}

.song-card {
  background: var(--card-bg);
  border-radius: var(--border-radius);
  padding: 1rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 1rem;
}

.song-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.song-card img {
  width: 80px;
  height: 80px;
  border-radius: 16px;
  object-fit: cover;
  flex-shrink: 0;
}

.song-card .placeholder-img {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 2rem;
  font-weight: bold;
}

.song-card .info {
  flex: 1;
  min-width: 0;
}

.song-card .title {
  font-weight: bold;
  color: var(--text-primary);
  margin: 0 0 0.25rem 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.song-card .artist {
  color: var(--text-secondary);
  font-size: 0.875rem;
  margin: 0 0 0.25rem 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.song-card .album {
  color: var(--text-secondary);
  font-size: 0.75rem;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.song-card .actions {
  display: flex;
  gap: 0.5rem;
  flex-shrink: 0;
}

/* 滚动列表 */
.scroll-container {
  overflow-x: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(102, 126, 234, 0.3) transparent;
}

.scroll-container::-webkit-scrollbar {
  height: 6px;
}

.scroll-container::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.05);
  border-radius: 3px;
}

.scroll-container::-webkit-scrollbar-thumb {
  background: rgba(102, 126, 234, 0.3);
  border-radius: 3px;
}

.scroll-container::-webkit-scrollbar-thumb:hover {
  background: rgba(102, 126, 234, 0.5);
}

.scroll-list {
  display: flex;
  gap: 1rem;
  padding-bottom: 0.5rem;
}

.scroll-item {
  flex-shrink: 0;
  min-width: 280px;
}

/* 消息提示 */
.message {
  padding: 0.75rem 1rem;
  border-radius: var(--border-radius);
  margin-bottom: 1rem;
  font-weight: 500;
}

.message-success {
  background: rgba(72, 187, 120, 0.1);
  color: #2f855a;
  border: 1px solid rgba(72, 187, 120, 0.2);
}

.message-error {
  background: rgba(245, 101, 101, 0.1);
  color: #c53030;
  border: 1px solid rgba(245, 101, 101, 0.2);
}

.message-info {
  background: rgba(66, 153, 225, 0.1);
  color: #2b6cb0;
  border: 1px solid rgba(66, 153, 225, 0.2);
}

/* 加载状态 */
.loading {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  color: var(--text-secondary);
}

.spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(102, 126, 234, 0.2);
  border-top: 3px solid var(--text-accent);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-right: 1rem;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* 手机端底部导航 */
.mobile-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--card-bg);
  backdrop-filter: blur(20px);
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  padding: 0.5rem 0;
  z-index: 100;
}

.mobile-nav-content {
  display: flex;
  justify-content: space-around;
  align-items: center;
  max-width: 500px;
  margin: 0 auto;
}

.mobile-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.5rem;
  border: none;
  background: none;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
  border-radius: 12px;
  min-width: 60px;
}

.mobile-nav-item.active {
  color: var(--text-accent);
  background: rgba(102, 126, 234, 0.1);
}

.mobile-nav-item i {
  font-size: 1.5rem;
  margin-bottom: 0.25rem;
}

.mobile-nav-item span {
  font-size: 0.75rem;
  font-weight: 500;
}

/* 响应式设计 */
@media (max-width: 768px) {
  /* 移动端样式 */
  .main-content {
    padding: 1rem 0.5rem 5rem 0.5rem; /* 底部留空给导航栏 */
  }
  
  .tab-nav {
    display: none; /* 隐藏顶部标签，使用底部导航 */
  }
  
  .mobile-nav {
    display: block; /* 显示底部导航 */
  }
  
  .playlist-grid {
    grid-template-columns: 1fr;
  }
  
  .song-grid {
    grid-template-columns: 1fr;
  }
  
  .card {
    padding: 1rem;
    border-radius: var(--border-radius);
  }
  
  .nav-content {
    padding: 0 0.5rem;
  }
  
  .nav-title {
    font-size: 1.25rem;
  }
  
  .user-info {
    gap: 0.5rem;
  }
  
  .user-avatar {
    width: 32px;
    height: 32px;
  }
  
  /* 歌曲卡片在移动端的调整 */
  .song-card {
    padding: 0.75rem;
  }
  
  .song-card img, .song-card .placeholder-img {
    width: 80px;
    height: 80px;
    border-radius: 16px;
  }
  
  /* 按钮在移动端的调整 */
  .btn {
    padding: 0.625rem 1.25rem;
  }
  
  .btn-sm {
    padding: 0.5rem 0.75rem;
    font-size: 0.8rem;
  }
}

@media (max-width: 480px) {
  /* 小屏手机样式 */
  .main-content {
    padding: 0.5rem 0.25rem 5rem 0.25rem;
  }
  
  .card {
    padding: 0.75rem;
    margin-bottom: 1rem;
  }
  
  .song-card {
    flex-direction: column;
    text-align: center;
    gap: 0.75rem;
  }
  
  .song-card img, .song-card .placeholder-img {
    width: 100px;
    height: 100px;
    border-radius: 20px;
  }
  
  .song-card .info {
    order: 2;
  }
  
  .song-card .actions {
    order: 3;
    justify-content: center;
  }
}

/* 深色模式支持 */
@media (prefers-color-scheme: dark) {
  :root {
    --bg-gradient: linear-gradient(120deg, #1a202c 0%, #2d3748 100%);
    --card-bg: rgba(45, 55, 72, 0.95);
    --card-hover: rgba(45, 55, 72, 1);
    --text-primary: #f7fafc;
    --text-secondary: #e2e8f0;
  }
}

/* 滑动动画 */
.slide-in {
  animation: slideIn 0.3s ease-out;
}

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

/* 工具类 */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }
.font-bold { font-weight: bold; }
.font-normal { font-weight: normal; }
.hidden { display: none !important; }
.visible { display: block !important; }
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-1 { gap: 0.25rem; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 0.75rem; }
.mt-4 { margin-top: 1rem; }

/* 电台分类样式 */
.radio-tag-card {
  background: var(--card-bg);
  border-radius: var(--border-radius);
  padding: 1rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  cursor: pointer;
  border: 2px solid transparent;
  min-width: 260px;
}

.radio-tag-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
  border-color: rgba(102, 126, 234, 0.3);
}

.radio-tag-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.radio-tag-title {
  font-weight: bold;
  color: var(--text-primary);
  font-size: 1.1rem;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
}

.radio-tag-count {
  background: var(--accent-gradient);
  color: white;
  padding: 0.25rem 0.5rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: bold;
  white-space: nowrap;
  margin-left: 0.5rem;
}

.radio-tag-desc {
  color: var(--text-secondary);
  font-size: 0.875rem;
  line-height: 1.4;
  margin: 0 0 1rem 0;
  min-height: 1.2em;
}

.radio-tag-actions {
  display: flex;
  justify-content: flex-end;
}

/* 面包屑导航样式 */
.radio-breadcrumb {
  background: rgba(102, 126, 234, 0.1);
  border-radius: var(--border-radius);
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
}

.radio-breadcrumb span {
  color: var(--text-accent);
  cursor: pointer;
  padding: 0.25rem 0.5rem;
  border-radius: 6px;
  transition: var(--transition);
}

.radio-breadcrumb span:hover {
  background: rgba(102, 126, 234, 0.2);
}

.radio-breadcrumb .separator {
  color: var(--text-secondary);
  cursor: default;
  padding: 0;
}

.radio-breadcrumb .separator:hover {
  background: none;
} 

/* 横向滑动发现页歌曲卡片 */
.discover-song-list {
  display: flex;
  flex-direction: row;
  gap: 1rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
}
.discover-song-card {
  min-width: 180px;
  max-width: 220px;
  background: #f6f8ff;
  border-radius: 16px;
  box-shadow: 0 2px 8px rgba(102,126,234,0.06);
  padding: 1rem 1rem 0.7rem 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.discover-song-cover {
  position: relative;
  width: 110px;
  height: 110px;
  margin-bottom: 0.7rem;
}
.discover-song-cover img {
  width: 100%;
  height: 100%;
  border-radius: 14px;
  object-fit: cover;
  box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}
.discover-song-actions {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.5rem;
  justify-content: center;
}
.discover-play-btn, .discover-fav-btn {
  width: 44px;
  height: 44px;
  font-size: 1.5rem;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 8px rgba(31,214,97,0.10);
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
}
.discover-play-btn:hover, .discover-fav-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 12px rgba(31,214,97,0.20);
}
.discover-play-btn { color: #1fd661; }
.discover-fav-btn { color: #f43f5e; }
.discover-song-title {
  font-size: 1rem;
  font-weight: 600;
  color: #222;
  margin-top: 0.2rem;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}
.discover-song-desc {
  font-size: 0.85rem;
  color: #666;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

/* 电台卡片样式 */
.radio-song-card {
  min-width: 180px;
  max-width: 220px;
  background: #f6f8ff;
  border-radius: 16px;
  box-shadow: 0 2px 8px rgba(102,126,234,0.06);
  padding: 1rem 1rem 0.7rem 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: all 0.2s ease;
}
.radio-song-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(102,126,234,0.12);
}
.radio-song-cover {
  position: relative;
  width: 110px;
  height: 110px;
  margin-bottom: 0.7rem;
}
.radio-song-cover img {
  width: 100%;
  height: 100%;
  border-radius: 14px;
  object-fit: cover;
  box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}
.radio-song-actions {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.5rem;
  justify-content: center;
}
.radio-play-btn {
  width: 44px;
  height: 44px;
  font-size: 1.5rem;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 8px rgba(31,214,97,0.10);
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  color: #1fd661;
}
.radio-play-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 12px rgba(31,214,97,0.20);
}
.radio-song-title {
  font-size: 1rem;
  font-weight: 600;
  color: #222;
  margin-top: 0.2rem;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}
.radio-song-desc {
  font-size: 0.85rem;
  color: #666;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

@media (max-width: 600px) {
  .discover-song-card {
    flex-direction: column;
    align-items: stretch;
    padding: 0.7rem 0.5rem;
    gap: 0.7rem;
  }
  .discover-song-cover img {
    width: 120px;
    height: 120px;
    border-radius: 16px;
  }
  .discover-song-title {
    font-size: 1.1rem;
  }
  .discover-song-desc {
    font-size: 0.95rem;
  }
  .discover-play-btn, .discover-fav-btn {
    width: 38px;
    height: 38px;
    font-size: 1.1rem;
  }
}

@media (max-width: 400px) {
  .discover-song-cover img {
    width: 90px;
    height: 90px;
    border-radius: 12px;
  }
  .discover-song-title {
    font-size: 1rem;
  }
  .discover-song-desc {
    font-size: 0.85rem;
  }
} 

/* 好友申请样式 */
.friend-request-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
  background: #f8fafc;
  border-radius: 12px;
  margin-bottom: 0.8rem;
  border: 1px solid #e2e8f0;
  transition: all 0.2s ease;
}

.friend-request-item:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

.friend-request-info {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.friend-request-info .friend-username {
  font-weight: 600;
  color: #1e293b;
  font-size: 1rem;
}

.friend-request-info .friend-nickname {
  color: #64748b;
  font-size: 0.875rem;
}

.friend-request-info .friend-remark {
  color: #64748b;
  font-size: 0.875rem;
  font-style: italic;
}

.friend-request-info .request-time {
  color: #94a3b8;
  font-size: 0.75rem;
}

.friend-request-actions {
  display: flex;
  gap: 0.5rem;
}

.friend-request-actions .btn {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.friend-request-actions .btn-success {
  background: #10b981;
  color: white;
}

.friend-request-actions .btn-success:hover {
  background: #059669;
}

.friend-request-actions .btn-danger {
  background: #ef4444;
  color: white;
}

.friend-request-actions .btn-danger:hover {
  background: #dc2626;
  border-color: #dc2626;
}

/* 好友申请标签页样式 */
.friend-tabs {
  display: flex;
  border-bottom: 2px solid #e2e8f0;
  margin-bottom: 1.5rem;
}

.friend-tab {
  padding: 0.75rem 1.5rem;
  background: none;
  border: none;
  cursor: pointer;
  font-weight: 500;
  color: #64748b;
  border-bottom: 2px solid transparent;
  transition: all 0.2s ease;
}

.friend-tab.active {
  color: #3b82f6;
  border-bottom-color: #3b82f6;
}

.friend-tab:hover {
  color: #3b82f6;
}

.friend-tab-content {
  display: none;
}

.friend-tab-content.active {
  display: block;
}

/* 好友申请数量徽章 */
.friend-tab-badge {
  background: #ef4444;
  color: white;
  border-radius: 50%;
  padding: 0.2rem 0.5rem;
  font-size: 0.75rem;
  margin-left: 0.5rem;
  min-width: 1.2rem;
  text-align: center;
}

/* 好友标签页移动端适配 */
@media (max-width: 768px) {
    .friend-tabs {
        flex-direction: column;
        gap: 0.5rem;
        border-bottom: none;
        margin-bottom: 1rem;
    }
    
    .friend-tab {
        width: 100%;
        justify-content: center;
        padding: 1rem;
        font-size: 1rem;
        border-radius: 12px;
        background: #f8fafc;
        border: 1px solid #e2e8f0;
        margin-bottom: 0.5rem;
        border-bottom: none;
        transition: all 0.3s ease;
        display: flex;
        align-items: center;
        gap: 0.5rem;
    }
    
    .friend-tab.active {
        background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
        color: white;
        border-color: #3b82f6;
        box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
    }
    
    .friend-tab:hover {
        background: #f1f5f9;
        border-color: #cbd5e1;
        transform: translateY(-1px);
    }
    
    .friend-tab.active:hover {
        background: linear-gradient(135deg, #2563eb 0%, #1e40af 100%);
        transform: translateY(-1px);
    }
    
    .friend-tab-content {
        padding: 1rem 0;
    }
    
    .friend-tab-badge {
        font-size: 0.75rem;
        padding: 0.25rem 0.5rem;
        border-radius: 10px;
        background: rgba(255, 255, 255, 0.2);
        color: white;
    }
}

@media (max-width: 480px) {
    .friend-tabs {
        gap: 0.375rem;
    }
    
    .friend-tab {
        padding: 0.875rem;
        font-size: 0.9375rem;
    }
    
    .friend-tab-badge {
        font-size: 0.6875rem;
        padding: 0.25rem 0.375rem;
    }
}

/* 个人中心功能分类样式 */
.personal-center-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.function-card {
  background: var(--card-bg);
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: var(--shadow-md);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: var(--transition);
  cursor: pointer;
  position: relative;
  overflow: hidden;
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 200px;
}

.function-card:hover {
  background: var(--card-hover);
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.function-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--primary-gradient);
  opacity: 0;
  transition: var(--transition);
}

.function-card:hover::before {
  opacity: 1;
}

.function-icon {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--primary-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.5rem;
  margin-bottom: 1rem;
  transition: var(--transition);
}

.function-card:hover .function-icon {
  transform: scale(1.1);
}

.function-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.function-info h3 {
  font-size: 1.1rem;
  font-weight: bold;
  color: var(--text-primary);
  margin: 0 0 0.5rem 0;
}

.function-info p {
  color: var(--text-secondary);
  margin: 0;
  font-size: 0.85rem;
  line-height: 1.4;
}

.function-status {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
}

.status-badge {
  padding: 0.25rem 0.5rem;
  border-radius: 1rem;
  font-size: 0.7rem;
  font-weight: 500;
  background: #e8f5e8;
  color: #2d5a2d;
  border: 1px solid #c3e6c3;
}

.status-badge.disconnected {
  background: #ffe8e8;
  color: #5a2d2d;
  border-color: #e6c3c3;
}

.status-badge.warning {
  background: #fff3cd;
  color: #856404;
  border-color: #ffeaa7;
}

.status-badge.error {
  background: #f8d7da;
  color: #721c24;
  border-color: #f5c6cb;
}

/* 功能内容区域 */
.function-content-area {
  position: relative;
  margin-top: 2rem;
}

.function-content {
  display: none;
  animation: slideInUp 0.3s ease-out;
}

.function-content.active {
  display: block;
}

@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 移动端适配 */
@media (max-width: 768px) {
  .personal-center-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
  }
  
  .function-card {
    padding: 1rem;
    min-height: 160px;
  }
  
  .function-icon {
    width: 50px;
    height: 50px;
    font-size: 1.25rem;
  }
  
  .function-info h3 {
    font-size: 1rem;
  }
  
  .function-info p {
    font-size: 0.8rem;
  }
}

@media (max-width: 480px) {
  .personal-center-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
  }
  
  .function-card {
    padding: 0.75rem;
    min-height: 140px;
  }
  
  .function-icon {
    width: 45px;
    height: 45px;
    font-size: 1.1rem;
  }
  
  .function-info h3 {
    font-size: 0.9rem;
  }
  
  .function-info p {
    font-size: 0.75rem;
  }
  
  .status-badge {
    font-size: 0.65rem;
    padding: 2px 4px;
  }
} 

/* 二维码扫描相关样式 */
.qr-scanner-container {
  display: flex;
  justify-content: center;
  margin-bottom: 1rem;
  position: relative;
}

.qr-scanner-container video {
  border: 2px solid var(--text-accent);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-md);
}

.qr-scan-tips {
  background: rgba(102, 126, 234, 0.1);
  border-radius: var(--border-radius);
  padding: 1rem;
  margin-bottom: 1rem;
  border-left: 4px solid var(--text-accent);
}

.qr-scan-tips p {
  margin: 0.5rem 0;
  font-size: 0.9rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.qr-scan-tips i {
  color: var(--text-accent);
  font-size: 1rem;
}

#qr-manual-input {
  padding: 1rem 0;
}

#qr-manual-input .input-group {
  margin-bottom: 1rem;
}

#qr-manual-input .modal-footer {
  display: flex;
  gap: 0.5rem;
  justify-content: flex-end;
}

/* 二维码扫描按钮样式 */
.btn-outline[onclick*="scanQRCode"] {
  border-color: var(--text-accent);
  color: var(--text-accent);
  transition: var(--transition);
}

.btn-outline[onclick*="scanQRCode"]:hover {
  background: var(--text-accent);
  color: white;
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.btn-outline[onclick*="scanQRCode"] i {
  margin-right: 0.25rem;
}

/* 响应式二维码扫描 */
@media (max-width: 768px) {
  .qr-scanner-container video {
    max-width: 100%;
    height: auto;
  }
  
  .qr-scan-tips {
    padding: 0.75rem;
  }
  
  .qr-scan-tips p {
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  .qr-scanner-container video {
    border-width: 1px;
  }
  
  .qr-scan-tips {
    padding: 0.5rem;
  }
  
  .qr-scan-tips p {
    font-size: 0.8rem;
  }
  
  #qr-manual-input .modal-footer {
    flex-direction: column;
  }
  
  #qr-manual-input .modal-footer .btn {
    width: 100%;
  }
} 

.function-card.active,
.function-card:active,
.function-card.selected {
  background: var(--card-hover);
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
  border: 2px solid var(--text-accent);
}

.function-card.active .function-icon,
.function-card.selected .function-icon {
  transform: scale(1.1);
  background: var(--text-accent);
}

.function-card.active .function-info h3,
.function-card.selected .function-info h3 {
  color: var(--text-accent);
}

.function-card.active .function-info p,
.function-card.selected .function-info p {
  color: var(--text-primary);
} 

/* 可折叠卡片样式 */
.collapsible-card {
  background: var(--card-bg);
  border-radius: var(--border-radius-lg);
  box-shadow: var(--shadow-md);
  margin-bottom: 1rem;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.collapsible-header {
  cursor: pointer;
  user-select: none;
  position: relative;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.5rem;
  background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  transition: var(--transition);
  transform: scale(1);
}

.collapsible-header:hover {
  background: linear-gradient(135deg, #f0f2ff 0%, #ffffff 100%);
}

.collapsible-header:active {
  background: linear-gradient(135deg, #e8ecff 0%, #ffffff 100%);
}

.collapse-btn {
  background: none;
  border: none;
  color: var(--text-accent);
  font-size: 1.25rem;
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 0.5rem;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 2.25rem;
  height: 2.25rem;
}

.collapse-btn:hover {
  background: rgba(102, 126, 234, 0.1);
  transform: scale(1.05);
}

.collapse-btn:active {
  transform: scale(0.95);
}

.collapse-btn.collapsed {
  transform: rotate(-90deg);
}

.card-content {
  max-height: 2000px;
  opacity: 1;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
  padding: 1.5rem;
  background: var(--card-bg);
}

.card-content.collapsed {
  max-height: 0;
  opacity: 0;
  padding: 0 1.5rem;
}

/* 待机屏幕设置卡片特殊样式 - 添加滚动支持 */
#standby-card-content:not(.collapsed) {
    max-height: 70vh;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #c1c1c1 #f1f1f1;
}

#standby-card-content:not(.collapsed)::-webkit-scrollbar {
    width: 6px;
}

#standby-card-content:not(.collapsed)::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

#standby-card-content:not(.collapsed)::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

#standby-card-content:not(.collapsed)::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* 移动端适配 */
@media (max-width: 768px) {
  .collapsible-card {
    margin-bottom: 0.75rem;
    border-radius: 0.625rem;
  }
  
  .collapsible-header {
    padding: 0.875rem 1rem;
  }
  
  .card-content {
    padding: 1rem;
  }
  
  .card-title {
    font-size: 1rem;
  }
  
  .collapse-btn {
    width: 2rem;
    height: 2rem;
    font-size: 1.125rem;
  }
    
    /* 待机屏幕设置在手机端的滚动高度 */
    #standby-card-content:not(.collapsed) {
        max-height: 60vh;
    }
}

@media (max-width: 480px) {
    #standby-card-content:not(.collapsed) {
        max-height: 50vh;
    }
}

/* 配置网格优化 */
.config-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 16px;
}

.config-item {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.config-label {
  font-size: 13px;
  font-weight: 500;
  color: #495057;
  margin-bottom: 4px;
}

/* 预览区域优化 */
.preview-section {
  margin-bottom: 24px;
  padding: 20px;
  background: #f8f9fa;
  border-radius: 12px;
  border: 1px solid #e9ecef;
  max-height: 400px;
  overflow-y: auto;
}

.preview-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 280px;
  padding: 20px 0;
}

/* 设备选择区域优化 */
.device-select-section {
    margin-bottom: 16px;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.device-select-section select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ced4da;
    border-radius: 6px;
    font-size: 14px;
    background: #ffffff;
    color: #495057;
}

.device-select-section select:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
}

/* 操作按钮区域优化 */
.config-actions {
    margin-top: 20px;
  display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
}

.config-actions .btn {
    flex: 1;
    min-width: 120px;
    max-width: 200px;
}

/* 响应式优化 */
@media (max-width: 768px) {
    .config-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .config-actions {
        flex-direction: column;
        gap: 8px;
    }
    
    .config-actions .btn {
        width: 100%;
        max-width: none;
    }
    
    .preview-section {
        padding: 16px;
        margin-bottom: 16px;
    }
    
    .preview-container {
        min-height: 240px;
        padding: 16px 0;
    }
    
    .device-select-section {
        padding: 10px;
    }
}

@media (max-width: 480px) {
    .preview-section {
        padding: 12px;
    }
    
    .preview-container {
        min-height: 200px;
        padding: 12px 0;
    }
    
    .config-item {
        gap: 6px;
    }
    
    .config-label {
        font-size: 12px;
    }
    
    .device-select-section {
        padding: 8px;
    }
    
    .device-select-section select {
        font-size: 13px;
        padding: 6px 10px;
    }
} 

/* 圆形屏幕预览样式 */
.preview-section {
  margin-bottom: 24px;
  padding: 20px;
  background: #f8f9fa;
  border-radius: 12px;
  border: 1px solid #e9ecef;
}

.preview-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 300px;
}

.circular-screen {
  position: relative;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  background: linear-gradient(145deg, #1a1a1a, #2d2d2d);
  box-shadow: 
    inset 0 0 20px rgba(0, 0, 0, 0.5),
    0 0 30px rgba(0, 0, 0, 0.3),
    0 10px 20px rgba(0, 0, 0, 0.2);
  border: 3px solid #333;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.circular-screen::before {
  content: '';
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  width: 8px;
  height: 8px;
  background: #666;
  border-radius: 50%;
  box-shadow: 0 0 5px rgba(0, 0, 0, 0.5);
}

/* 时间显示预览 */
.time-display-preview {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 10;
}

.time-display {
  font-size: 48px;
  font-weight: bold;
  color: #FFFFFF;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  line-height: 1;
  text-align: center;
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
}

.time-hour {
  font-size: 48px;
  font-weight: bold;
  color: #FFFFFF;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  line-height: 1;
  margin-bottom: 4px;
}

.time-minute {
  font-size: 32px;
  font-weight: bold;
  color: #FFFFFF;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  line-height: 1;
}

/* 消息气泡预览 */
.message-bubble-preview {
  position: absolute;
  background: rgba(0, 0, 0, 0.6);
  border-radius: 12px;
  padding: 8px 12px;
  max-width: 200px;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  z-index: 10;
}

.bubble-text {
  color: #FFFFFF;
  font-size: 12px;
  text-align: center;
  line-height: 1.2;
  word-wrap: break-word;
}

/* 预览控制按钮 */
.preview-controls {
  margin-top: 16px;
  text-align: center;
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.preview-controls .btn {
  padding: 8px 16px;
  font-size: 12px;
}

/* 不同预览模式 */
.circular-screen.preview-mode-dark {
  background: linear-gradient(145deg, #1a1a1a, #2d2d2d);
}

.circular-screen.preview-mode-light {
  background: linear-gradient(145deg, #f0f0f0, #e0e0e0);
  box-shadow: 
    inset 0 0 20px rgba(0, 0, 0, 0.1),
    0 0 30px rgba(0, 0, 0, 0.1),
    0 10px 20px rgba(0, 0, 0, 0.1);
  border: 3px solid #ccc;
}

.circular-screen.preview-mode-light .time-hour,
.circular-screen.preview-mode-light .time-minute {
  color: #333;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.circular-screen.preview-mode-light .message-bubble-preview {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(0, 0, 0, 0.1);
}

.circular-screen.preview-mode-light .bubble-text {
  color: #333;
}

/* 动画效果 */
.time-display-preview {
  transition: all 0.3s ease;
}

.message-bubble-preview {
  transition: all 0.3s ease;
}

.circular-screen {
  transition: all 0.3s ease;
}

/* 响应式预览 */
@media (max-width: 768px) {
  .circular-screen {
    width: 240px;
    height: 240px;
  }
  
  .time-display {
    font-size: 40px;
  }
  
  .time-hour {
    font-size: 40px;
  }
  
  .time-minute {
    font-size: 28px;
  }
  
  .message-bubble-preview {
    max-width: 160px;
  }
  
  .bubble-text {
    font-size: 11px;
  }
}

@media (max-width: 480px) {
  .circular-screen {
    width: 200px;
    height: 200px;
  }
  
  .time-display {
    font-size: 36px;
  }
  
  .time-hour {
    font-size: 36px;
  }
  
  .time-minute {
  font-size: 24px;
  }
  
  .message-bubble-preview {
    max-width: 140px;
  }
  
  .bubble-text {
    font-size: 10px;
  }
  
  .preview-controls {
    flex-direction: column;
  align-items: center;
  }
  
  .preview-controls .btn {
    width: 100%;
    max-width: 200px;
  }
}

/* 方形屏幕预览样式 */
.square-screen {
    width: 240px;
    height: 240px;
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    border-radius: 12px;
    position: relative;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border: 2px solid #333;
    overflow: hidden;
}

.square-screen::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.square-screen.preview-mode-dark {
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
}

.square-screen.preview-mode-light {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-color: #dee2e6;
}

.square-screen.preview-mode-light .time-hour,
.square-screen.preview-mode-light .time-minute {
    color: #495057;
}

.square-screen.preview-mode-light .message-bubble-preview {
    background-color: rgba(0, 0, 0, 0.8) !important;
}

.square-screen.preview-mode-light .bubble-text {
    color: #ffffff;
}

/* 屏幕形状选择器样式 */
.screen-shape-selector {
  display: flex;
  justify-content: center;
    gap: 12px;
    margin-bottom: 16px;
}

.screen-shape-selector .btn {
    padding: 8px 16px;
    font-size: 12px;
    border-radius: 8px;
  transition: all 0.2s ease;
}

.screen-shape-selector .btn-primary {
    background: #007bff;
    border-color: #007bff;
    color: white;
}

.screen-shape-selector .btn-outline {
    background: transparent;
    border-color: #dee2e6;
    color: #6c757d;
}

.screen-shape-selector .btn-outline:hover {
    background: #f8f9fa;
    border-color: #adb5bd;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .square-screen {
        width: 200px;
        height: 200px;
    }
    
    .screen-shape-selector {
        flex-direction: column;
        gap: 8px;
    }
    
    .screen-shape-selector .btn {
        width: 100%;
        max-width: 200px;
        margin: 0 auto;
    }
}

@media (max-width: 480px) {
    .square-screen {
        width: 160px;
        height: 160px;
    }
    
    .screen-shape-selector .btn {
        font-size: 11px;
        padding: 6px 12px;
    }
}

/* 小智设备控制样式 */
.xiaozhi-control-section {
    margin-bottom: 24px;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.xiaozhi-control-section h4 {
    margin: 0 0 12px 0;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    display: flex;
    align-items: center;
    gap: 8px;
}

.xiaozhi-control-section h5 {
    margin: 0 0 12px 0;
    font-size: 13px;
    font-weight: 600;
    color: #333;
    display: flex;
    align-items: center;
    gap: 6px;
}

.control-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
}

.control-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 12px;
    background: white;
    border-radius: 6px;
    border: 1px solid #e0e0e0;
}

.control-item label {
    font-size: 12px;
    font-weight: 500;
    color: #666;
    margin-bottom: 4px;
}

.control-input-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.control-input-group input[type="range"] {
    flex: 1;
    height: 6px;
    border-radius: 3px;
    background: #e9ecef;
    outline: none;
    -webkit-appearance: none;
}

.control-input-group input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #667eea;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.control-input-group input[type="range"]::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #667eea;
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.control-input-group span {
    font-size: 12px;
    color: #666;
    min-width: 30px;
    text-align: center;
    font-weight: 500;
}

.xiaozhi-device-card {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 16px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.xiaozhi-device-card:hover {
    border-color: #667eea;
    box-shadow: 0 4px 16px rgba(102, 126, 234, 0.15);
    transform: translateY(-2px);
}

.xiaozhi-device-header {
    margin-bottom: 16px;
}

.xiaozhi-device-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.device-name {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin: 0;
}

/* 主题切换开关 */
.theme-toggle {
    position: relative;
}

.theme-switch {
    display: none;
}

.theme-switch-label {
    display: flex;
    align-items: center;
    width: 50px;
    height: 24px;
    background: #e0e0e0;
    border-radius: 12px;
    padding: 2px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.theme-switch-label::before {
    content: '';
    position: absolute;
    left: 2px;
    width: 20px;
    height: 20px;
    background: white;
    border-radius: 50%;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.theme-switch:checked + .theme-switch-label {
    background: #667eea;
}

.theme-switch:checked + .theme-switch-label::before {
    transform: translateX(26px);
}

.theme-switch-label i {
    font-size: 12px;
    color: #666;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    transition: all 0.3s ease;
}

.theme-switch-label i:first-child {
    left: 6px;
}

.theme-switch-label i:last-child {
    right: 6px;
}

.theme-switch:checked + .theme-switch-label i:first-child {
    color: #fff;
}

.theme-switch:checked + .theme-switch-label i:last-child {
    color: #fff;
}

/* 设备标签 */
.device-tags {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.device-tag {
    padding: 4px 8px;
    background: #f5f5f5;
    color: #666;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 500;
}

/* 设备控制区域 */
.device-controls {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
    align-items: center;
}

.device-controls .control-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 8px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 60px;
    background: transparent;
    border: none;
}

.device-controls .control-item:hover {
    background: rgba(102, 126, 234, 0.1);
    transform: scale(1.05);
}

.control-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8f9fa;
    color: #667eea;
    font-size: 16px;
    transition: all 0.2s ease;
}

.control-icon:hover {
    background: #667eea;
    color: white;
    transform: scale(1.1);
}

.control-value {
    font-size: 12px;
    color: #666;
    font-weight: 500;
}

.control-slider {
    width: 100%;
    margin-top: 8px;
    padding: 8px;
    background: #f8f9fa;
    border-radius: 6px;
    border: 1px solid #e0e0e0;
}

.control-slider input[type="range"] {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: #e9ecef;
    outline: none;
    -webkit-appearance: none;
}

.control-slider input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #667eea;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.control-slider input[type="range"]::-moz-range-thumb {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #667eea;
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.refresh-btn {
    background: none;
    border: none;
    color: #667eea;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 16px;
}

.refresh-btn:hover {
    background: rgba(102, 126, 234, 0.1);
    transform: scale(1.1);
}

/* 设备操作区域 */
.device-actions {
    display: flex;
    gap: 8px;
    align-items: center;
    justify-content: space-between;
}

.action-btn {
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    padding: 8px 12px;
    color: #666;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 4px;
    text-decoration: none;
}

.action-btn:hover {
    background: #667eea;
    color: white;
    border-color: #667eea;
    transform: translateY(-1px);
}

.device-status-indicator {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    transition: all 0.3s ease;
}

.device-status-indicator.online {
    background: #d1fae5;
    color: #065f46;
    animation: pulse 2s infinite;
}

.device-status-indicator.offline {
    background: #fee2e2;
    color: #991b1b;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* 其他控制卡片 */
.other-control-card {
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 16px;
    margin-top: 16px;
}

.other-control-card .xiaozhi-device-card {
    background: white;
    margin-bottom: 0;
    box-shadow: none;
}

.other-control-card .xiaozhi-device-card:hover {
    transform: none;
    box-shadow: none;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .device-controls {
        flex-wrap: wrap;
        gap: 8px;
    }
    
    .device-controls .control-item {
        min-width: 50px;
        padding: 6px 8px;
    }
    
    .control-icon {
        width: 28px;
        height: 28px;
        font-size: 14px;
    }
    
    .device-actions {
    flex-direction: column;
        gap: 8px;
    }
    
    .action-btn {
        width: 100%;
        justify-content: center;
    }
    
    .control-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .xiaozhi-device-card {
        padding: 16px;
    }
    
    .device-name {
        font-size: 16px;
    }
    
    .device-controls {
        gap: 6px;
    }
    
    .device-controls .control-item {
        min-width: 45px;
        padding: 4px 6px;
    }
    
    .control-icon {
        width: 24px;
        height: 24px;
        font-size: 12px;
    }
    
    .control-value {
    font-size: 11px;
    }
}

/* MAC地址列表样式 */
.mac-list-container {
    border-top: 1px solid #e5e7eb;
    padding-top: 1.25rem;
}

.mac-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.mac-item {
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    padding: 0.75rem;
    transition: var(--transition);
}

.mac-item:hover {
    background: #f1f5f9;
    border-color: #d1d5db;
}

.mac-item.primary {
    background: #eff6ff;
    border-color: #3b82f6;
}

.mac-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.mac-address {
    font-family: 'Courier New', monospace;
    font-weight: 600;
    color: #1f2937;
    font-size: 0.875rem;
}

.mac-device-name {
    font-size: 0.75rem;
    color: #6b7280;
    margin-left: 0.5rem;
}

.primary-badge {
    background: #3b82f6;
    color: white;
    padding: 0.125rem 0.5rem;
    border-radius: 0.75rem;
    font-size: 0.625rem;
    font-weight: 500;
}

.mac-actions {
    display: flex;
    gap: 0.5rem;
}

.mac-actions .btn {
    font-size: 0.6875rem;
    padding: 0.25rem 0.5rem;
}

.no-mac {
    text-align: center;
    padding: 1.25rem;
    color: #6b7280;
    font-style: italic;
}

/* 好友管理样式 */
.friend-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem;
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    margin-bottom: 0.5rem;
    transition: var(--transition);
}

.friend-item:hover {
    background: #f1f5f9;
    border-color: #d1d5db;
}

.friend-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.friend-username {
    font-weight: 600;
    color: #1f2937;
}

.friend-nickname {
    font-size: 0.75rem;
    color: #6b7280;
}

.friend-actions {
    display: flex;
    gap: 0.5rem;
}

.friend-actions .btn {
    font-size: 0.6875rem;
    padding: 0.25rem 0.5rem;
}

/* 配置区域美化样式 */
.config-section {
    background: #ffffff;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.config-section:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    border-color: #667eea;
}

.config-section h6 {
    margin: 0 0 16px 0;
    color: #495057;
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    padding-bottom: 8px;
    border-bottom: 2px solid #f8f9fa;
}

.config-section h6 i {
    margin-right: 8px;
    color: #667eea;
    font-size: 16px;
}

/* 配置网格优化 */
.config-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 16px;
}

.config-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    transition: all 0.2s ease;
}

.config-item:hover {
    background: #ffffff;
    border-color: #667eea;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.1);
}

.config-label {
    font-size: 13px;
    font-weight: 500;
    color: #495057;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* 开关样式 */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.toggle-input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-label {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
    border-radius: 24px;
}

.toggle-label:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.toggle-input:checked + .toggle-label {
    background-color: #667eea;
}

.toggle-input:checked + .toggle-label:before {
    transform: translateX(26px);
}

/* 颜色选择器样式 */
.color-picker {
    width: 100%;
    height: 40px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    /* 移动端兼容性 */
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background: transparent;
    padding: 0;
    margin: 0;
}

.color-picker:hover {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.color-picker::-webkit-color-swatch-wrapper {
    padding: 0;
    border: none;
    border-radius: 6px;
}

.color-picker::-webkit-color-swatch {
    border: none;
    border-radius: 6px;
    padding: 0;
}

/* Firefox 兼容性 */
.color-picker::-moz-color-swatch {
    border: none;
    border-radius: 6px;
    padding: 0;
}

/* 移动端特殊样式 */
@media (max-width: 768px) {
    .color-picker {
        height: 44px; /* 增加触摸区域 */
        min-height: 44px; /* 确保最小高度 */
        font-size: 16px; /* 防止iOS缩放 */
        -webkit-tap-highlight-color: transparent;
    }
    
    .color-picker:focus {
        outline: none;
        border-color: #667eea;
        box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    }
}

@media (max-width: 480px) {
    .color-picker {
        height: 48px; /* 进一步增加触摸区域 */
        min-height: 48px;
    }
}

/* 滑块样式 */
.form-range {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: #e9ecef;
    outline: none;
    -webkit-appearance: none;
    margin: 8px 0;
}

.form-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #667eea;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.form-range::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #667eea;
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* 数值显示 */
.range-value {
    font-size: 12px;
    color: #6c757d;
    font-weight: 500;
    text-align: center;
    margin-top: 4px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .config-section {
        padding: 16px;
        margin-bottom: 16px;
    }
    
    .config-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .config-item {
        padding: 10px;
    }
}

@media (max-width: 480px) {
    .config-section {
        padding: 12px;
    }
    
    .config-section h6 {
        font-size: 13px;
    }
    
    .config-item {
        padding: 8px;
    }
    
    .config-label {
        font-size: 12px;
    }
}

/* QQ音乐歌单列表样式 */
.qq-playlist-container {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.qq-playlist-header {
  display: flex;
}

.qq-playlist-header-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.qq-playlist-title {
  font-size: 18px;
  font-weight: 600;
}

.qq-playlist-count {
  background: rgba(255,255,255,0.2);
  padding: 2px 8px;
  border-radius: 12px;
        font-size: 12px;
  font-weight: 500;
}

.qq-playlist-header-right {
  display: flex;
  gap: 8px;
}

.qq-playlist-btn {
  background: rgba(255,255,255,0.2);
  border: none;
  color: white;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.qq-playlist-btn:hover {
  background: rgba(255,255,255,0.3);
  transform: scale(1.05);
}

.qq-playlist-list {
  max-height: 500px;
  overflow-y: auto;
}

.qq-playlist-item {
  display: flex;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid #f0f0f0;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}

.qq-playlist-item:hover {
  background: #f8f9fa;
}

.qq-playlist-item.selected {
  background: #e3f2fd;
  border-left: 4px solid #667eea;
}

.qq-playlist-item:last-child {
  border-bottom: none;
}

.qq-playlist-cover {
  width: 60px;
  height: 60px;
  border-radius: 8px;
  margin-right: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: white;
  font-weight: bold;
  flex-shrink: 0;
}

.qq-playlist-info {
  flex: 1;
  min-width: 0;
}

.qq-playlist-name {
  font-size: 16px;
  font-weight: 600;
  color: #333;
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.qq-playlist-meta {
}

.qq-playlist-update-time {
  display: flex;
  align-items: center;
  gap: 4px;
}

.qq-playlist-actions {
  display: flex;
  gap: 8px;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.qq-playlist-item:hover .qq-playlist-actions {
  opacity: 1;
}

.qq-playlist-action-btn {
  background: none;
  border: none;
  color: #666;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.qq-playlist-action-btn:hover {
  background: #f0f0f0;
  color: #333;
}

.qq-playlist-action-btn.delete:hover {
  background: #ffebee;
  color: #f44336;
}

.qq-playlist-action-btn.view:hover {
  background: #e8f5e8;
  color: #4caf50;
}

.qq-playlist-empty {
  text-align: center;
  padding: 60px 20px;
  color: #999;
}

.qq-playlist-empty i {
  font-size: 48px;
  color: #ddd;
  margin-bottom: 16px;
}

.qq-playlist-empty h3 {
  font-size: 16px;
  margin-bottom: 8px;
  color: #666;
}

.qq-playlist-empty p {
  font-size: 14px;
  color: #999;
}

/* 响应式设计 */
@media (max-width: 768px) {
  .qq-playlist-item {
    padding: 12px 16px;
  }
  
  .qq-playlist-cover {
    width: 50px;
    height: 50px;
    font-size: 20px;
    margin-right: 12px;
  }
  
  .qq-playlist-name {
    font-size: 14px;
  }
}

/* 歌单歌曲数量样式 */
.qq-playlist-song-count {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* 歌单展开/收起按钮 */
.playlist-toggle-btn {
  background: none;
  border: none;
  color: #6b7280;
  padding: 8px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
}

.playlist-toggle-btn:hover {
  background: #f3f4f6;
  color: #374151;
}

.playlist-toggle-btn.expanded {
  color: #667eea;
}

.playlist-toggle-btn i {
  transition: transform 0.2s ease;
}

.playlist-toggle-btn.expanded i {
  transform: rotate(180deg);
}

/* 歌单歌曲列表容器 */
.playlist-songs-list {
  background: #f8f9fa;
  border-top: 1px solid #e5e7eb;
  max-height: 300px;
  overflow-y: auto;
  display: none;
}

.playlist-songs-list.expanded {
  display: block;
}

.playlist-songs-list::-webkit-scrollbar {
  width: 6px;
}

.playlist-songs-list::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.05);
  border-radius: 3px;
}

.playlist-songs-list::-webkit-scrollbar-thumb {
  background: rgba(102, 126, 234, 0.3);
  border-radius: 3px;
}

.playlist-songs-list::-webkit-scrollbar-thumb:hover {
  background: rgba(102, 126, 234, 0.5);
} 

/* 歌单歌曲项目 */
.playlist-song-item {
  display: flex;
  align-items: center;
  padding: 12px 20px;
  border-bottom: 1px solid #e5e7eb;
  transition: background-color 0.2s ease;
}

.playlist-song-item:hover {
  background: #f1f5f9;
}

.playlist-song-item:last-child {
  border-bottom: none;
}

.playlist-song-info {
  flex: 1;
  min-width: 0;
}

.playlist-song-title {
  font-size: 14px;
  font-weight: 500;
  color: #1f2937;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.playlist-song-artist {
  font-size: 12px;
  color: #6b7280;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.playlist-song-actions {
  display: flex;
  gap: 8px;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.playlist-song-item:hover .playlist-song-actions {
  opacity: 1;
}

.playlist-song-action-btn {
  background: none;
  border: none;
  color: #6b7280;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.playlist-song-action-btn:hover {
  background: #e5e7eb;
  color: #374151;
}

.playlist-song-action-btn.delete:hover {
  background: #fef2f2;
  color: #dc2626;
}

.playlist-song-action-btn.play:hover {
  background: #f0f9ff;
  color: #2563eb;
}

/* 响应式设计 */
@media (max-width: 768px) {
  .playlist-song-item {
    padding: 10px 16px;
  }
  
  .playlist-song-title {
    font-size: 13px;
  }
  
  .playlist-song-artist {
    font-size: 11px;
  }
  
  .playlist-song-action-btn {
    width: 24px;
    height: 24px;
  }
}

@media (max-width: 768px) {
    .square-screen {
        width: 200px;
        height: 200px;
    }
    
    .time-display {
        font-size: 40px;
    }
    
    .screen-shape-selector {
        flex-direction: column;
        gap: 8px;
    }
    
    .screen-shape-selector .btn {
  width: 100%;
        max-width: 200px;
    }
}

@media (max-width: 480px) {
    .square-screen {
        width: 160px;
        height: 160px;
    }
    
    .time-display {
        font-size: 36px;
    }
    
    .screen-shape-selector .btn {
        padding: 8px 12px;
        font-size: 11px;
    }
}

/* 对讲功能样式 */
.intercom-dialog {
    position: fixed;
  top: 0;
  left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
    z-index: 1000;
}

.intercom-dialog-content {
    background: white;
    border-radius: 12px;
    padding: 24px;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.intercom-dialog-header {
  display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.intercom-dialog-header h3 {
    margin: 0;
    color: #1f2937;
    font-size: 18px;
    font-weight: 600;
}

.intercom-close-btn {
    background: none;
  border: none;
    color: #6b7280;
  cursor: pointer;
    padding: 4px;
    border-radius: 4px;
  transition: all 0.2s ease;
}

.intercom-close-btn:hover {
    background: #f3f4f6;
    color: #374151;
}

.intercom-dialog-body {
    margin-bottom: 24px;
}

.intercom-dialog-body p {
    margin: 0 0 12px 0;
    color: #4b5563;
    line-height: 1.5;
}

.intercom-status {
    display: flex;
    align-items: center;
    gap: 8px;
  padding: 12px;
    background: #f0f9ff;
    border: 1px solid #bae6fd;
  border-radius: 8px;
    color: #0369a1;
}

.intercom-status i {
    font-size: 16px;
}

.intercom-dialog-footer {
    display: flex;
  gap: 12px;
    justify-content: flex-end;
}

.intercom-interface {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: white;
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    z-index: 1000;
    min-width: 300px;
    border: 1px solid #e5e7eb;
}

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

.intercom-user-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.intercom-avatar {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
  display: flex;
  align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 16px;
}

.intercom-details h4 {
    margin: 0 0 4px 0;
    color: #1f2937;
    font-size: 14px;
    font-weight: 600;
}

.intercom-details p {
    margin: 0;
    color: #6b7280;
  font-size: 12px;
}

.intercom-controls {
  display: flex;
  gap: 8px;
}

.intercom-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    font-size: 16px;
}

.intercom-mute {
    background: #f3f4f6;
    color: #6b7280;
}

.intercom-mute:hover {
    background: #e5e7eb;
    color: #374151;
}

.intercom-mute.muted {
    background: #fef2f2;
    color: #dc2626;
}

.intercom-end {
    background: #fef2f2;
    color: #dc2626;
}

.intercom-end:hover {
    background: #fee2e2;
    color: #b91c1c;
}

.intercom-status {
    display: flex;
    align-items: center;
    justify-content: space-between;
  padding: 12px;
    background: #f9fafb;
    border-radius: 8px;
}

.intercom-timer {
    font-family: 'Courier New', monospace;
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
}

.intercom-indicator {
    display: flex;
    align-items: center;
    gap: 4px;
}

.intercom-wave {
    width: 20px;
    height: 20px;
    background: linear-gradient(135deg, #10b981, #059669);
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.7;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* 响应式设计 */
@media (max-width: 768px) {
    .intercom-dialog-content {
        width: 95%;
        padding: 20px;
    }
    
    .intercom-interface {
        bottom: 10px;
        right: 10px;
        left: 10px;
        min-width: auto;
        width: calc(100% - 20px);
    }
    
    .intercom-header {
    flex-direction: column;
        gap: 12px;
        align-items: flex-start;
  }
  
    .intercom-controls {
        align-self: flex-end;
  }
}

@media (max-width: 480px) {
    .intercom-dialog-content {
        padding: 16px;
    }
    
    .intercom-dialog-header h3 {
        font-size: 16px;
    }
    
    .intercom-interface {
        padding: 16px;
    }
    
    .intercom-avatar {
        width: 32px;
        height: 32px;
        font-size: 14px;
    }
    
    .intercom-details h4 {
        font-size: 13px;
    }
    
    .intercom-details p {
        font-size: 11px;
    }
    
    .intercom-btn {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }
    
    .intercom-timer {
        font-size: 14px;
  }
} 

/* 搜索歌曲项样式 */
.song-item {
  display: flex;
  align-items: center;
  padding: 12px 20px;
  border-bottom: 1px solid #e5e7eb;
  transition: background-color 0.2s ease;
}

.song-item:hover {
  background: #f1f5f9;
}

.song-item:last-child {
  border-bottom: none;
}

.song-cover {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  overflow: hidden;
  margin-right: 16px;
  flex-shrink: 0;
}

.song-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.song-info {
  flex: 1;
  min-width: 0;
}

.song-title {
  font-size: 14px;
  font-weight: 500;
  color: #1f2937;
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.song-artist {
  font-size: 12px;
  color: #6b7280;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.song-album {
  font-size: 11px;
  color: #9ca3af;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.song-actions {
  display: flex;
  gap: 8px;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.song-item:hover .song-actions {
  opacity: 1;
}

.no-results {
  text-align: center;
  color: #6b7280;
  padding: 2rem;
  font-size: 14px;
}

@media (max-width: 768px) {
  .song-item {
    padding: 10px 16px;
  }
  
  .song-cover {
    width: 40px;
    height: 40px;
    margin-right: 12px;
  }
  
  .song-title {
    font-size: 13px;
  }
  
  .song-artist {
    font-size: 11px;
  }
  
  .song-album {
    font-size: 10px;
  }
} 

/* 智能家居风格样式 */
.smart-home-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 16px;
    padding: 16px;
}

.smart-home-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 16px;
    padding: 16px;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.smart-home-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.smart-home-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 32px rgba(0, 0, 0, 0.15);
}

.smart-home-card:hover::before {
    opacity: 1;
}

.smart-home-card-icon {
    font-size: 24px;
    margin-bottom: 10px;
    opacity: 0.9;
}

.smart-home-card-content {
    position: relative;
    z-index: 1;
}

.smart-home-card-title {
    font-size: 15px;
    font-weight: 600;
    margin: 0 0 5px 0;
    color: white;
}

.smart-home-card-desc {
    font-size: 12px;
    opacity: 0.8;
    margin: 0 0 10px 0;
    line-height: 1.3;
}

.smart-home-card-status {
    display: flex;
    align-items: center;
}

.status-indicator {
    background: rgba(255, 255, 255, 0.2);
    padding: 3px 10px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 500;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.smart-home-card-arrow {
    position: absolute;
    top: 16px;
    right: 16px;
    font-size: 16px;
    opacity: 0.7;
    transition: all 0.3s ease;
}

.smart-home-card:hover .smart-home-card-arrow {
    transform: translateX(3px);
    opacity: 1;
}

/* 智能家居面板样式 */
.smart-home-panel {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: white;
    z-index: 1000;
    overflow-y: auto;
    animation: slideInFromRight 0.3s ease;
}

@keyframes slideInFromRight {
    from {
        transform: translateX(100%);
    }
    to {
        transform: translateX(0);
    }
}

.panel-header {
    display: flex;
    align-items: center;
    padding: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    position: sticky;
    top: 0;
    z-index: 10;
}

.panel-back-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    padding: 8px 12px;
    border-radius: 8px;
    cursor: pointer;
    margin-right: 16px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.panel-back-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateX(-2px);
}

.panel-title {
    font-size: 20px;
    font-weight: 600;
    margin: 0;
    flex: 1;
    display: flex;
    align-items: center;
}

.panel-title i {
    margin-right: 8px;
}

.panel-actions {
    display: flex;
    gap: 8px;
}

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

/* 响应式设计 */
@media (max-width: 768px) {
    .smart-home-grid {
        grid-template-columns: 1fr;
        padding: 12px;
        gap: 12px;
    }
    
    .smart-home-card {
        padding: 14px;
        border-radius: 14px;
    }
    
    .smart-home-card-title {
        font-size: 14px;
    }
    
    .smart-home-card-desc {
        font-size: 11px;
    }
    
    .smart-home-card-icon {
        font-size: 20px;
        margin-bottom: 8px;
    }
    
    .smart-home-card-arrow {
        top: 14px;
        right: 14px;
        font-size: 14px;
    }
    
    .panel-header {
        padding: 16px;
    }
    
    .panel-title {
        font-size: 18px;
    }
    
    .panel-content {
        padding: 16px;
        max-width: 100%;
    }
}

/* 不同主题的卡片颜色 */
.smart-home-card:nth-child(1) {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.smart-home-card:nth-child(2) {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.smart-home-card:nth-child(3) {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.smart-home-card:nth-child(4) {
    background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
}

.smart-home-card:nth-child(5) {
    background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 100%);
}

.smart-home-card:nth-child(6) {
    background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%);
}

/* 状态指示器颜色 */
.status-indicator.online {
    background: rgba(76, 175, 80, 0.3);
    color: #4caf50;
}

.status-indicator.offline {
    background: rgba(244, 67, 54, 0.3);
    color: #f44336;
}

.status-indicator.warning {
    background: rgba(255, 152, 0, 0.3);
    color: #ff9800;
}

/* 加载动画 */
.smart-home-card.loading {
    position: relative;
    overflow: hidden;
}

.smart-home-card.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        left: -100%;
    }
    100% {
        left: 100%;
    }
}

/* 移动设备上的面板优化 */
@media (max-width: 480px) {
    .smart-home-panel {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100%;
        height: 100%;
    }
    
    .panel-header {
        padding: 12px 16px;
    }
    
    .panel-title {
        font-size: 16px;
    }
    
    .panel-content {
        padding: 12px;
    }
    
    .smart-home-card {
        padding: 12px;
        border-radius: 12px;
    }
    
    .smart-home-card-title {
        font-size: 13px;
    }
    
    .smart-home-card-desc {
        font-size: 10px;
    }
    
    .smart-home-card-icon {
        font-size: 18px;
        margin-bottom: 6px;
    }
    
    .smart-home-card-arrow {
        top: 12px;
        right: 12px;
        font-size: 14px;
    }
}

/* 确保面板内容可以滚动 */
.smart-home-panel {
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

/* 面板内容的滚动条样式 */
.smart-home-panel::-webkit-scrollbar {
    width: 6px;
}

.smart-home-panel::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.smart-home-panel::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.smart-home-panel::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* 卡片点击动画 */
.smart-home-card:active {
    transform: scale(0.98);
    transition: transform 0.1s ease;
}

/* 状态指示器更新动画 */
.status-indicator {
    transition: all 0.3s ease;
}

.status-indicator.online {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(76, 175, 80, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(76, 175, 80, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(76, 175, 80, 0);
    }
}

/* 面板切换动画 */
.smart-home-panel {
    animation: slideInFromRight 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.smart-home-panel.closing {
    animation: slideOutToRight 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideOutToRight {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(100%);
    }
}

/* 卡片悬停效果增强 */
.smart-home-card:hover .smart-home-card-icon {
    transform: scale(1.1);
    transition: transform 0.3s ease;
}

.smart-home-card:hover .smart-home-card-title {
    transform: translateY(-2px);
    transition: transform 0.3s ease;
}

/* 移动设备触摸优化 */
@media (max-width: 768px) {
    .smart-home-card {
        -webkit-tap-highlight-color: transparent;
        touch-action: manipulation;
    }
    
    .panel-back-btn {
        min-width: 44px;
        min-height: 44px;
        touch-action: manipulation;
    }
    
    .smart-home-panel {
        touch-action: pan-y;
    }
}

/* 确保卡片在触摸设备上有足够的点击区域 */
.smart-home-card {
    min-height: 120px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* 防止文本选择 */
.smart-home-card,
.panel-header,
.panel-back-btn {
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

/* 图片预览样式 */
.image-preview {
    margin: 16px 0;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.image-preview img {
    max-width: 100%;
    max-height: 200px;
    border-radius: 4px;
    margin-bottom: 8px;
}

.preview-info {
    font-size: 12px;
    color: #666;
    line-height: 1.4;
}

.preview-info div {
    margin-bottom: 4px;
}

/* 图片处理选项样式 */
.process-options-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
    margin: 12px 0;
}

.option-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.option-group label {
    font-size: 12px;
    color: #495057;
    font-weight: 500;
}

.size-inputs {
    display: flex;
    align-items: center;
    gap: 8px;
}

.size-inputs input {
    width: 80px;
    text-align: center;
}

.size-inputs span {
    color: #666;
    font-size: 12px;
}

.process-actions {
    display: flex;
    gap: 8px;
    margin-top: 12px;
}

/* 裁剪区域样式 */
.crop-section {
    margin: 12px 0;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 6px;
    border: 1px solid #e9ecef;
}

.crop-inputs {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    margin: 8px 0;
}

.crop-inputs input {
    width: 100%;
    text-align: center;
}

/* 背景图片库样式 */
.background-gallery {
    margin: 16px 0;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 8px;
    max-height: 300px;
    overflow-y: auto;
    padding: 8px;
    background: white;
    border-radius: 6px;
}

.gallery-item {
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
}

.gallery-item:hover {
    background: #e9ecef;
    transform: scale(1.05);
}

.gallery-item img {
    width: 100%;
    height: 60px;
    object-fit: cover;
    border-radius: 4px;
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease;
    border-radius: 4px;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-actions {
    display: flex;
    gap: 4px;
}

.gallery-actions .btn {
    padding: 4px 6px;
    font-size: 10px;
    min-width: auto;
}

.gallery-actions .btn i {
    font-size: 10px;
}

/* 上传区域样式 */
.upload-section {
    display: flex;
    gap: 8px;
    margin: 12px 0;
    flex-wrap: wrap;
}

.background-url-section {
    margin: 16px 0;
}

.background-url-section input {
    margin-bottom: 8px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .process-options-grid {
        grid-template-columns: 1fr;
    }
    
    .crop-inputs {
        grid-template-columns: 1fr;
    }
    
    .upload-section {
        flex-direction: column;
    }
    
    .upload-section .btn {
        width: 100%;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
    }
}

@media (max-width: 480px) {
    .image-preview {
        padding: 12px;
    }
    
    .image-preview img {
        max-height: 150px;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(50px, 1fr));
    }
    
    .gallery-item img {
        height: 50px;
    }
}

/* 预览模式样式 */
.circular-screen.preview-mode-dark {
    background: #000;
}

.circular-screen.preview-mode-light {
    background: #fff;
    border: 2px solid #ddd;
}

.circular-screen.preview-mode-light .time-hour,
.circular-screen.preview-mode-light .time-minute {
    color: #333;
}

.circular-screen.preview-mode-light .message-bubble-preview {
    background: rgba(255, 255, 255, 0.9);
}

.circular-screen.preview-mode-light .bubble-text {
    color: #333;
}

.square-screen.preview-mode-dark {
    background: #000;
}

.square-screen.preview-mode-light {
    background: #fff;
    border: 2px solid #ddd;
}

.square-screen.preview-mode-light .time-hour,
.square-screen.preview-mode-light .time-minute {
    color: #333;
}

.square-screen.preview-mode-light .message-bubble-preview {
    background: rgba(255, 255, 255, 0.9);
}

.square-screen.preview-mode-light .bubble-text {
    color: #333;
}

/* 配置区域展开/收起样式 */
.config-section-header {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border-radius: 8px;
  margin-bottom: 8px;
  transition: all 0.3s ease;
}

.config-section-header:hover {
  background: linear-gradient(135deg, #e9ecef 0%, #dee2e6 100%);
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.config-section-header h6 {
  color: #495057;
  font-weight: 600;
  transition: color 0.3s ease;
}

.config-section-header:hover h6 {
  color: #212529;
}

.config-section-header i[class*="ri-arrow"] {
  color: #6c757d;
  transition: all 0.3s ease;
}

.config-section-header:hover i[class*="ri-arrow"] {
  color: #495057;
}

.config-section-content {
  padding: 16px;
  background: #ffffff;
  border: 1px solid #e9ecef;
  border-radius: 8px;
  margin-bottom: 16px;
  animation: slideDown 0.3s ease;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 配置操作按钮样式优化 */
.config-actions .btn {
  font-size: 12px;
  padding: 6px 12px;
  border-radius: 6px;
  transition: all 0.3s ease;
}

.config-actions .btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.config-actions .btn-primary {
  background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
  border: none;
}

.config-actions .btn-outline {
  border: 1px solid #dee2e6;
  color: #6c757d;
  background: #ffffff;
}

.config-actions .btn-outline:hover {
  border-color: #007bff;
  color: #007bff;
  background: #f8f9fa;
}

/* 好友管理样式 */
.friend-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem;
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    margin-bottom: 0.5rem;
    transition: var(--transition);
}

.friend-item:hover {
    background: #f1f5f9;
    border-color: #d1d5db;
}

.friend-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.friend-username {
    font-weight: 600;
    color: #1f2937;
}

.friend-nickname {
    font-size: 0.75rem;
    color: #6b7280;
}

.friend-actions {
    display: flex;
    gap: 0.5rem;
}

.friend-actions .btn {
    font-size: 0.6875rem;
    padding: 0.25rem 0.5rem;
}

/* 移动端适配 */
@media (max-width: 768px) {
    .friend-item {
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
        padding: 1.25rem;
        background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
        border: 1px solid #e2e8f0;
        border-radius: 16px;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
        margin-bottom: 1rem;
        transition: all 0.3s ease;
    }
    
    .friend-item:hover {
        background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
        border-color: #cbd5e1;
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
        transform: translateY(-2px);
    }
    
    .friend-info {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
        width: 100%;
    }
    
    .friend-header {
        width: 100%;
        display: flex;
        align-items: center;
        justify-content: space-between;
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    
    .friend-username {
        max-width: none;
        flex: 1;
        font-size: 1.125rem;
        font-weight: 700;
        color: #1e293b;
        display: flex;
        align-items: center;
        gap: 0.5rem;
    }
    
    .friend-username::before {
        content: '';
        width: 8px;
        height: 8px;
        background: #10b981;
        border-radius: 50%;
        display: inline-block;
    }
    
    .friend-nickname {
        max-width: none;
        font-size: 0.875rem;
        color: #64748b;
        background: #f1f5f9;
        padding: 0.25rem 0.75rem;
        border-radius: 12px;
        font-style: italic;
    }
    
    .friend-actions {
        width: 100%;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 0.75rem;
        margin-top: 0.5rem;
    }
    
    .friend-actions .btn {
        flex: 1;
        font-size: 0.875rem;
        padding: 0.75rem 1rem;
        min-width: 0;
        border-radius: 12px;
        font-weight: 600;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 0.5rem;
        transition: all 0.3s ease;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    }
    
    .friend-actions .btn:hover {
        transform: translateY(-1px);
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    }
    
    .friend-actions .btn-primary {
        background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
        color: white;
        border: none;
    }
    
    .friend-actions .btn-primary:hover {
        background: linear-gradient(135deg, #2563eb 0%, #1e40af 100%);
    }
    
    .friend-actions .btn-success {
        background: linear-gradient(135deg, #10b981 0%, #059669 100%);
        color: white;
        border: none;
    }
    
    .friend-actions .btn-success:hover {
        background: linear-gradient(135deg, #059669 0%, #047857 100%);
    }
    
    .friend-actions .btn-danger {
        background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
        color: white;
        border: none;
    }
    
    .friend-actions .btn-danger:hover {
        background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
    }
}

@media (max-width: 480px) {
    .friend-item {
        padding: 1rem;
        border-radius: 12px;
        margin-bottom: 0.75rem;
    }
    
    .friend-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .friend-username {
        font-size: 1rem;
        width: 100%;
    }
    
    .friend-nickname {
        font-size: 0.8125rem;
        padding: 0.25rem 0.5rem;
    }
    
    .friend-actions {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }
    
    .friend-actions .btn {
        width: 100%;
        justify-content: center;
        font-size: 0.875rem;
        padding: 0.875rem 1rem;
        border-radius: 10px;
    }
    
    /* 好友标签页优化 */
    .friend-tabs {
        flex-direction: column;
        gap: 0.5rem;
        margin-bottom: 1rem;
    }
    
    .friend-tab {
        width: 100%;
        justify-content: center;
        padding: 1rem;
        font-size: 1rem;
        border-radius: 12px;
        background: #f8fafc;
        border: 1px solid #e2e8f0;
        margin-bottom: 0.5rem;
    }
    
    .friend-tab.active {
        background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
        color: white;
        border-color: #3b82f6;
    }
    
    .friend-tab-badge {
        font-size: 0.75rem;
        padding: 0.25rem 0.5rem;
        border-radius: 10px;
    }
}

/* 手机端好友申请样式优化 */
@media (max-width: 768px) {
    .friend-request-item {
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
        padding: 1.25rem;
        background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
        border: 1px solid #e2e8f0;
        border-radius: 16px;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
        margin-bottom: 1rem;
        transition: all 0.3s ease;
    }
    
    .friend-request-item:hover {
        background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
        border-color: #cbd5e1;
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
        transform: translateY(-2px);
    }
    
    .friend-request-info {
        width: 100%;
        gap: 0.75rem;
    }
    
    .friend-request-info .friend-username {
        font-size: 1.125rem;
        font-weight: 700;
        color: #1e293b;
        display: flex;
        align-items: center;
        gap: 0.5rem;
    }
    
    .friend-request-info .friend-username::before {
        content: '';
        width: 8px;
        height: 8px;
        background: #f59e0b;
        border-radius: 50%;
        display: inline-block;
    }
    
    .friend-request-info .friend-nickname {
        font-size: 0.875rem;
        color: #64748b;
        background: #fef3c7;
        padding: 0.25rem 0.75rem;
        border-radius: 12px;
    }
    
    .friend-request-info .friend-remark {
        font-size: 0.875rem;
        color: #64748b;
        background: #f1f5f9;
        padding: 0.25rem 0.75rem;
        border-radius: 8px;
        font-style: italic;
    }
    
    .friend-request-info .request-time {
        font-size: 0.75rem;
        color: #94a3b8;
        display: flex;
        align-items: center;
        gap: 0.25rem;
    }
    
    .friend-request-info .request-time::before {
        content: '🕒';
        font-size: 0.875rem;
    }
    
    .friend-request-actions {
        width: 100%;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 0.75rem;
        margin-top: 0.5rem;
    }
    
    .friend-request-actions .btn {
        flex: 1;
        font-size: 0.875rem;
        padding: 0.75rem 1rem;
        border-radius: 12px;
        font-weight: 600;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 0.5rem;
        transition: all 0.3s ease;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    }
    
    .friend-request-actions .btn:hover {
        transform: translateY(-1px);
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    }
    
    .friend-request-actions .btn-success {
        background: linear-gradient(135deg, #10b981 0%, #059669 100%);
        color: white;
        border: none;
    }
    
    .friend-request-actions .btn-success:hover {
        background: linear-gradient(135deg, #059669 0%, #047857 100%);
    }
    
    .friend-request-actions .btn-danger {
        background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
        color: white;
        border: none;
    }
    
    .friend-request-actions .btn-danger:hover {
        background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
    }
}

@media (max-width: 480px) {
    .friend-request-item {
        padding: 1rem;
        border-radius: 12px;
        margin-bottom: 0.75rem;
    }
    
    .friend-request-info .friend-username {
        font-size: 1rem;
    }
    
    .friend-request-info .friend-nickname {
        font-size: 0.8125rem;
        padding: 0.25rem 0.5rem;
    }
    
    .friend-request-info .friend-remark {
        font-size: 0.8125rem;
        padding: 0.25rem 0.5rem;
    }
    
    .friend-request-actions {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }
    
    .friend-request-actions .btn {
        width: 100%;
        justify-content: center;
        font-size: 0.875rem;
        padding: 0.875rem 1rem;
        border-radius: 10px;
    }
}

/* 电台分类样式 */
#radio-categories-list .radio-stations-container {
    min-height: 200px;
}

/* 新的电台UI样式 */
#radio-categories-list .radio-filter-buttons {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
    padding: 0 4px;
    overflow-x: auto;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
}

#radio-categories-list .radio-filter-buttons::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
}

#radio-categories-list .radio-filter-buttons .btn {
    flex-shrink: 0;
    min-width: 100px;
    max-width: 100px;
    white-space: nowrap;
    text-align: center;
    padding: 6px 12px;
    font-size: 13px;
    border-radius: 16px;
}

.radio-stations-list {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    padding: 20px;
    box-shadow: var(--shadow-sm);
}

.radio-station-item {
    display: flex;
    align-items: center;
    padding: 16px;
    border-bottom: 1px solid rgba(102, 126, 234, 0.1);
    transition: var(--transition);
}

.radio-station-item:hover {
    background: var(--card-hover);
}

.radio-station-item:last-child {
    border-bottom: none;
}

.radio-station-info {
    flex: 1;
    margin-right: 16px;
}

.radio-station-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
    line-height: 1.4;
}

.radio-station-desc {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 8px;
    line-height: 1.4;
}

.radio-station-meta {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.radio-station-category,
.radio-station-live {
    font-size: 12px;
    padding: 4px 8px;
    border-radius: 12px;
    background: rgba(102, 126, 234, 0.1);
    color: var(--text-secondary);
}

.radio-station-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: space-between;
}

.radio-play-btn {
    background: var(--primary-gradient);
    border: none;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    color: white;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.radio-play-btn:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow-md);
}

.radio-dropdown {
    position: relative;
}

.radio-dropdown-btn {
    background: transparent;
    border: none;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.radio-dropdown-btn:hover {
    background: rgba(102, 126, 234, 0.1);
    color: var(--text-primary);
}

.radio-dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--card-bg);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    padding: 8px 0;
    min-width: 160px;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: var(--transition);
    border: 1px solid rgba(102, 126, 234, 0.1);
}

.radio-dropdown-menu.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.radio-dropdown-menu button {
    width: 100%;
    padding: 12px 16px;
    background: none;
    border: none;
    text-align: left;
    color: var(--text-primary);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}

.radio-dropdown-menu button:hover {
    background: rgba(102, 126, 234, 0.1);
    color: var(--primary-color);
}

.radio-dropdown-menu button i {
    font-size: 16px;
    width: 16px;
}

/* ==================== 群控功能样式 ==================== */

/* 群控状态显示 */
.group-control-status {
    margin-top: 12px;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 12px;
    line-height: 1.4;
    white-space: pre-line;
    transition: var(--transition);
    border: 1px solid transparent;
}

.group-control-status.success {
    background-color: #d4edda;
    color: #155724;
    border-color: #c3e6cb;
}

.group-control-status.error {
    background-color: #f8d7da;
    color: #721c24;
    border-color: #f5c6cb;
}

.group-control-status.info {
    background-color: #d1ecf1;
    color: #0c5460;
    border-color: #bee5eb;
}

/* 群控输入框特殊样式 */
#group-control-action {
    font-family: 'Courier New', monospace;
    font-weight: 600;
    text-align: center;
}

#group-control-data {
    font-family: 'Courier New', monospace;
    font-size: 11px;
}

/* 群控按钮样式 */
.control-section .btn[onclick="sendGroupControl()"] {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    color: white;
    font-weight: 500;
    transition: var(--transition);
}

.control-section .btn[onclick="sendGroupControl()"]:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.control-section .btn[onclick="sendGroupControl()"]:active {
    transform: translateY(0);
}

/* 群控区域标题图标 */
.control-section h4 i.ri-robot-line {
    color: #667eea;
}

/* 群控输入框图标 */
#group-control-action + .input-wrapper i.ri-number-1 {
    color: #667eea;
}

#group-control-data + .input-wrapper i.ri-settings-3-line {
    color: #667eea;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .group-control-status {
        font-size: 11px;
        padding: 6px 10px;
    }
    
    #group-control-action,
    #group-control-data {
        font-size: 14px;
    }
}

/* 暗色主题适配 */
@media (prefers-color-scheme: dark) {
    .group-control-status.success {
        background-color: rgba(40, 167, 69, 0.2);
        color: #28a745;
        border-color: rgba(40, 167, 69, 0.3);
    }
    
    .group-control-status.error {
        background-color: rgba(220, 53, 69, 0.2);
        color: #dc3545;
        border-color: rgba(220, 53, 69, 0.3);
    }
    
    .group-control-status.info {
        background-color: rgba(23, 162, 184, 0.2);
        color: #17a2b8;
        border-color: rgba(23, 162, 184, 0.3);
    }
}

/* ==================== 设备选择功能样式 ==================== */

/* 设备选择容器 */
.device-selection-container {
    max-height: 200px;
    overflow-y: auto;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    background: white;
}

/* 设备选择列表 */
.device-selection-list {
    padding: 8px;
}

/* 设备选择项 */
.device-selection-item {
    transition: var(--transition);
    cursor: pointer;
}

.device-selection-item:hover {
    background: #f8f9fa !important;
    border-color: #dee2e6 !important;
}

.device-selection-item:has(.device-checkbox:checked) {
    background: #e3f2fd !important;
    border-color: #2196f3 !important;
}

/* 设备复选框 */
.device-checkbox {
    width: 16px;
    height: 16px;
    accent-color: #667eea;
    cursor: pointer;
}

.device-checkbox:checked {
    background-color: #667eea;
}

/* 设备选择头部 */
.device-selection-header {
    padding: 8px 12px;
    background: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
    border-radius: 6px 6px 0 0;
}

/* 选择控制按钮 */
.selection-controls .btn {
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 3px;
    transition: var(--transition);
}

.selection-controls .btn:hover {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

/* 选择摘要 */
.selection-summary {
    padding: 6px 12px;
    background: #f8f9fa;
    border-top: 1px solid #e9ecef;
    border-radius: 0 0 6px 6px;
    font-size: 11px;
    color: #6c757d;
    text-align: center;
}

/* 无设备状态 */
.no-devices {
    padding: 20px;
    text-align: center;
    color: #6c757d;
}

.no-devices i {
    font-size: 24px;
    margin-bottom: 8px;
    display: block;
    opacity: 0.5;
}

/* 错误状态 */
.error-message {
    padding: 20px;
    text-align: center;
    color: #dc3545;
}

.error-message i {
    font-size: 24px;
    margin-bottom: 8px;
    display: block;
    opacity: 0.7;
}

/* 设备状态指示器 */
.device-status .status-indicator {
    padding: 2px 6px;
    border-radius: 10px;
    font-size: 9px;
    font-weight: 500;
    text-transform: uppercase;
}

.device-status .status-indicator.online {
    background: #d4edda;
    color: #155724;
}

.device-status .status-indicator.offline {
    background: #f8d7da;
    color: #721c24;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .device-selection-container {
        max-height: 150px;
    }
    
    .device-selection-item {
        padding: 6px;
    }
    
    .device-selection-header {
        padding: 6px 8px;
    }
    
    .selection-controls .btn {
        font-size: 9px;
        padding: 1px 4px;
    }
}

/* 暗色主题适配 */
@media (prefers-color-scheme: dark) {
    .device-selection-container {
        background: #2d3748;
        border-color: #4a5568;
    }
    
    .device-selection-item {
        background: #2d3748 !important;
        border-color: #4a5568 !important;
    }
    
    .device-selection-item:hover {
        background: #4a5568 !important;
    }
    
    .device-selection-item:has(.device-checkbox:checked) {
        background: rgba(102, 126, 234, 0.2) !important;
        border-color: #667eea !important;
    }
    
    .device-selection-header {
        background: #4a5568;
        border-color: #718096;
    }
    
    .selection-summary {
        background: #4a5568;
        border-color: #718096;
        color: #a0aec0;
    }
    
    .device-status .status-indicator.online {
        background: rgba(40, 167, 69, 0.2);
        color: #28a745;
    }
    
    .device-status .status-indicator.offline {
        background: rgba(220, 53, 69, 0.2);
        color: #dc3545;
    }
}

/* 消息提示样式 */
.message {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 1rem 1.5rem;
    border-radius: 10px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    z-index: 1001;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
    max-width: 400px;
    animation: slideInRight 0.3s ease;
}

.message.success {
    background: #16a34a;
    color: white;
}

.message.error {
    background: #dc2626;
    color: white;
}

.message.warning {
    background: #d97706;
    color: white;
}

.message.info {
    background: #667eea;
    color: white;
}

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

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

/* 响应式设计 */
@media (max-width: 768px) {
    .radio-stations-list {
        padding: 16px;
    }
    
    .radio-station-item {
        padding: 12px;
    }
    
    #radio-categories-list .radio-filter-buttons {
        gap: 8px;
        margin-bottom: 20px;
    }
    
    #radio-categories-list .radio-filter-buttons .btn {
        min-width: 90px;
        max-width: 90px;
        font-size: 12px;
        padding: 5px 10px;
    }
}

@media (max-width: 480px) {
    .radio-stations-list {
        padding: 12px;
    }
    
    .radio-station-item {
        padding: 10px;
    }
    
    .radio-station-name {
        font-size: 15px;
    }
    
    .radio-station-desc {
        font-size: 13px;
    }
    
    .radio-station-meta {
        gap: 8px;
    }
    
    .radio-station-category,
    .radio-station-live {
        font-size: 11px;
        padding: 3px 6px;
    }
}

/* AI聊天相关动画效果 */
@keyframes fadeIn {
    from { 
        opacity: 0; 
        transform: translateY(10px); 
    }
    to { 
        opacity: 1; 
        transform: translateY(0); 
    }
}

@keyframes slideInUp {
    from { 
        opacity: 0; 
        transform: translateY(20px); 
    }
    to { 
        opacity: 1; 
        transform: translateY(0); 
    }
}

/* AI聊天消息动画 */
.ai-chat-message {
    animation: slideInUp 0.3s ease-out;
}

/* AI聊天历史容器动画 */
#ai-chat-history {
    transition: all 0.3s ease;
}

/* AI聊天消息样式优化 */
#ai-chat-history .message-received {
    background: #f0f8ff;
    border-left: 4px solid #667eea;
    animation: fadeIn 0.3s ease-in;
}

#ai-chat-history .message-sent {
    background: #667eea;
    color: white;
    animation: fadeIn 0.3s ease-in;
}