/* 加入群聊 - 全新设计风格 */
:root {
  --primary: #6366f1;
  --primary-dark: #4f46e5;
  --accent: #f59e0b;
  --bg: #f0f4f8;
  --card-bg: #ffffff;
  --text-primary: #1e293b;
  --text-secondary: #64748b;
  --border: #e2e8f0;
  --success: #10b981;
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text-primary);
  line-height: 1.6;
  font-size: 14px;
}

.page-container {
  min-height: 100vh;
  padding: 16px;
  max-width: 480px;
  margin: 0 auto;
}

/* 顶部横幅 */
.hero-banner {
  background: linear-gradient(135deg, var(--primary) 0%, #8b5cf6 100%);
  border-radius: 16px;
  padding: 28px 24px;
  margin-bottom: 20px;
  color: #fff;
  text-align: center;
  box-shadow: 0 4px 20px rgba(99, 102, 241, 0.3);
}

.hero-icon {
  font-size: 48px;
  margin-bottom: 12px;
}

.hero-title {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 6px;
}

.hero-subtitle {
  font-size: 14px;
  opacity: 0.9;
}

/* 群组信息卡片 */
.info-card {
  background: var(--card-bg);
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 16px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  border: 1px solid var(--border);
}

.info-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px dashed var(--border);
}

.group-avatar {
  width: 56px;
  height: 56px;
  background: linear-gradient(135deg, #f59e0b 0%, #ef4444 100%);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: #fff;
}

.group-details h3 {
  font-size: 17px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.group-id {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #f1f5f9;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 12px;
  color: var(--text-secondary);
}

.group-id span {
  font-weight: 600;
  color: var(--primary);
}

/* 二维码区域 */
.qr-section {
  text-align: center;
  margin-bottom: 24px;
}

.qr-box {
  background: #fff;
  border: 2px solid var(--border);
  border-radius: 12px;
  padding: 16px;
  display: inline-block;
  margin-bottom: 12px;
}

.qr-box img {
  width: 180px;
  height: 180px;
  display: block;
  border-radius: 8px;
}

.qr-label {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 12px;
}

/* 操作按钮 */
.action-btns {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}

.action-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 20px;
  border: none;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.action-btn.primary {
  background: var(--primary);
  color: #fff;
}

.action-btn.primary:active {
  background: var(--primary-dark);
  transform: scale(0.98);
}

.action-btn.secondary {
  background: #f1f5f9;
  color: var(--text-primary);
  border: 1px solid var(--border);
}

.action-btn.secondary:active {
  background: #e2e8f0;
  transform: scale(0.98);
}

.action-btn .icon {
  font-size: 18px;
}

/* 下载区域 */
.download-box {
  background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
  border-radius: 12px;
  padding: 20px;
  text-align: center;
  border: 1px solid #fcd34d;
}

.download-title {
  font-size: 15px;
  font-weight: 600;
  color: #92400e;
  margin-bottom: 12px;
}

.download-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: #f59e0b;
  color: #fff;
  padding: 14px 28px;
  border-radius: 25px;
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
  transition: all 0.2s;
}

.download-btn:hover {
  background: #d97706;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(245, 158, 11, 0.4);
}

.download-btn .icon {
  font-size: 20px;
}

/* 复制客服ID按钮 */
.copy-service-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: #fff;
  color: var(--text-primary);
  border: 2px solid var(--border);
  padding: 12px 20px;
  border-radius: 25px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
}

.copy-service-btn .icon {
  font-size: 18px;
}

.copy-service-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.copy-service-btn:active {
  transform: scale(0.97);
  background: #f0f9ff;
}

.copy-service {
  cursor: pointer;
  transition: opacity 0.2s;
}

.copy-service:active {
  opacity: 0.7;
}

/* 底部提示 */
.tips-box {
  background: #f8fafc;
  border-radius: 10px;
  padding: 16px;
  margin-top: 16px;
  border: 1px solid var(--border);
}

.tips-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.tips-list {
  list-style: none;
}

.tips-list li {
  font-size: 13px;
  color: var(--text-secondary);
  padding: 6px 0;
  padding-left: 20px;
  position: relative;
}

.tips-list li::before {
  content: "•";
  position: absolute;
  left: 4px;
  color: var(--primary);
  font-weight: bold;
}

/* 弹窗 */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  z-index: 1000;
  align-items: center;
  justify-content: center;
}

.modal-overlay.show {
  display: flex;
}

.modal-content {
  background: #fff;
  border-radius: 16px;
  padding: 20px;
  max-width: 90vw;
  max-height: 85vh;
  position: relative;
}

.modal-content img {
  max-width: 100%;
  max-height: 70vh;
  border-radius: 12px;
  display: block;
}

.modal-close {
  position: absolute;
  top: -16px;
  right: -16px;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  font-size: 24px;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

/* Toast提示 */
.toast-msg {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(0,0,0,0.8);
  color: #fff;
  padding: 14px 28px;
  border-radius: 10px;
  font-size: 14px;
  z-index: 2000;
  opacity: 0;
  transition: opacity 0.3s;
}

.toast-msg.show {
  opacity: 1;
}

/* 响应式 */
@media (max-width: 400px) {
  .hero-banner {
    padding: 24px 20px;
  }
  
  .hero-title {
    font-size: 20px;
  }
  
  .qr-box img {
    width: 150px;
    height: 150px;
  }
  
  .action-btns {
    gap: 10px;
  }
  
  .action-btn {
    padding: 12px 16px;
    font-size: 14px;
  }
}
