/* ===== 成长影像资料库 · 全新设计 v2 ===== */
* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --primary: #FF6B6B;
  --primary-dark: #E85555;
  --primary-light: #FFF0F0;
  --secondary: #FF8E53;
  --accent: #4ECDC4;
  --text-main: #2D3436;
  --text-sub: #636E72;
  --text-light: #B2BEC3;
  --border: #E8ECEF;
  --bg: #F7F8FA;
  --card-bg: #FFFFFF;
  --tag-bg: #F0F3F5;
  --shadow: 0 2px 12px rgba(45, 52, 54, 0.06);
  --shadow-hover: 0 8px 24px rgba(45, 52, 54, 0.12);
  --radius: 16px;
  --radius-sm: 10px;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  background: var(--bg);
  color: var(--text-main);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  padding-bottom: 80px;
}

/* ===== 顶部Header ===== */
.site-header {
  background: linear-gradient(135deg, #FF6B6B 0%, #FF8E53 100%);
  color: #fff;
  padding: 36px 20px 28px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.site-header::before {
  content: "";
  position: absolute;
  top: -60px;
  right: -40px;
  width: 180px;
  height: 180px;
  background: rgba(255,255,255,0.12);
  border-radius: 50%;
}
.site-header::after {
  content: "";
  position: absolute;
  bottom: -50px;
  left: -30px;
  width: 140px;
  height: 140px;
  background: rgba(255,255,255,0.08);
  border-radius: 50%;
}
.header-inner { position: relative; z-index: 1; }
.site-header h1 {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 1px;
  text-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
.site-desc {
  margin-top: 6px;
  font-size: 13px;
  opacity: 0.9;
}
.header-stats {
  margin-top: 16px;
  display: flex;
  justify-content: center;
  gap: 12px;
  font-size: 12px;
  flex-wrap: wrap;
}
.header-stats .stat-item {
  background: rgba(255,255,255,0.2);
  backdrop-filter: blur(8px);
  padding: 6px 16px;
  border-radius: 20px;
  font-weight: 500;
}
.header-stats .stat-num {
  font-weight: 700;
  font-size: 16px;
  margin-right: 2px;
}

/* ===== 公告栏 ===== */
.notice-bar {
  background: linear-gradient(90deg, #FFF3E0, #FFE0B2);
  border-bottom: 1px solid #FFCC80;
  color: #E65100;
  font-size: 13px;
  padding: 10px 16px;
  text-align: center;
  font-weight: 500;
}

/* ===== 工具栏 ===== */
.toolbar {
  background: #fff;
  border-bottom: 1px solid var(--border);
  padding: 14px 16px;
  position: sticky;
  top: 0;
  z-index: 20;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.toolbar-inner { max-width: 860px; margin: 0 auto; }
.search-box {
  position: relative;
  margin-bottom: 12px;
}
.search-box input {
  width: 100%;
  padding: 12px 16px 12px 42px;
  border: 1.5px solid var(--border);
  border-radius: 25px;
  font-size: 14px;
  background: var(--bg);
  transition: all 0.3s;
  outline: none;
}
.search-box input:focus {
  border-color: var(--primary);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(255,107,107,0.1);
}
.search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 16px;
  opacity: 0.5;
}
.filter-tags {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 2px;
  -webkit-overflow-scrolling: touch;
}
.filter-tags::-webkit-scrollbar { display: none; }
.filter-tag {
  flex-shrink: 0;
  padding: 6px 16px;
  background: var(--tag-bg);
  border-radius: 20px;
  font-size: 13px;
  color: var(--text-sub);
  cursor: pointer;
  transition: all 0.25s;
  white-space: nowrap;
}
.filter-tag.active {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  font-weight: 500;
  box-shadow: 0 2px 8px rgba(255,107,107,0.3);
}

/* ===== 区块标题 ===== */
.section-title {
  font-size: 18px;
  font-weight: 700;
  margin: 20px 16px 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.section-title::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--border), transparent);
  margin-left: 8px;
}

/* ===== 最近活动 ===== */
.recent-section { padding: 0 16px; }
.recent-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 12px;
}
.recent-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: all 0.3s;
  position: relative;
}
.recent-card:active { transform: scale(0.97); }
.recent-cover {
  width: 100%;
  height: 110px;
  object-fit: cover;
  background: linear-gradient(135deg, #FFE0E0, #FFF0E0);
}
.recent-info {
  padding: 10px;
}
.recent-title {
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.recent-date {
  font-size: 11px;
  color: var(--text-light);
  margin-top: 2px;
}

/* ===== 活动列表 ===== */
.activity-list, .activity-grid {
  padding: 0 16px;
  max-width: 860px;
  margin: 0 auto;
}
.year-section { margin-bottom: 8px; }
.year-title {
  font-size: 18px;
  font-weight: 700;
  margin: 20px 16px 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.year-count {
  font-size: 12px;
  font-weight: 400;
  color: var(--text-light);
  background: var(--tag-bg);
  padding: 2px 10px;
  border-radius: 10px;
}
.activity-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  margin-bottom: 16px;
  cursor: pointer;
  transition: all 0.3s;
}
.activity-card:active {
  transform: scale(0.98);
  box-shadow: var(--shadow-hover);
}
.card-cover {
  width: 100%;
  background: linear-gradient(135deg, #FFE0E0, #FFF0E0);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.card-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover !important;
  display: block;
}
.activity-cover, .activity-cover-placeholder {
  width: 100%;
  height: 180px;
  object-fit: cover;
  background: linear-gradient(135deg, #FFE0E0, #FFF0E0);
}
.activity-cover-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
}
.card-top {
  padding: 14px 16px 4px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.card-name {
  font-size: 17px;
  font-weight: 700;
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.card-tag {
  background: var(--primary-light);
  color: var(--primary);
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 10px;
  font-weight: 500;
  flex-shrink: 0;
}
.card-date {
  padding: 0 16px;
  font-size: 12px;
  color: var(--text-light);
  margin-bottom: 6px;
}
.card-note {
  padding: 0 16px;
  font-size: 13px;
  color: var(--text-sub);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 10px;
}
.card-actions, .activity-actions {
  display: flex;
  gap: 10px;
  margin: 0 16px 16px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}
.card-link {
  flex: 1;
  text-align: center;
  padding: 10px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s;
  border: none;
  cursor: pointer;
}
.card-link.view {
  background: var(--primary-light);
  color: var(--primary);
}
.card-link.view:active { background: #FFE0E0; }
.card-link.upload {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  box-shadow: 0 2px 8px rgba(255,107,107,0.3);
}
.card-link.upload:active { opacity: 0.9; }
.card-link.disabled {
  background: var(--tag-bg);
  color: var(--text-light);
  cursor: not-allowed;
}

/* ===== 空状态 ===== */
.empty-tip {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-light);
}
.empty-tip .empty-icon {
  font-size: 56px;
  margin-bottom: 12px;
}
.empty-tip p { font-size: 14px; }

/* ===== 悬浮上传按钮 ===== */
.fab-upload {
  position: fixed;
  bottom: 24px;
  right: 20px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  border: none;
  font-size: 24px;
  box-shadow: 0 4px 16px rgba(255,107,107,0.4);
  cursor: pointer;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s;
}
.fab-upload:active { transform: scale(0.9); }

/* ===== 家长登记遮罩 ===== */
.access-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}
.access-box {
  background: #fff;
  border-radius: 24px;
  padding: 32px 24px;
  width: 100%;
  max-width: 380px;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0,0,0,0.2);
  animation: slideUp 0.3s ease;
}
@keyframes slideUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}
.access-icon {
  font-size: 56px;
  margin-bottom: 12px;
}
.access-box h2 {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--text-main);
}
.access-box > p {
  font-size: 13px;
  color: var(--text-sub);
  margin-bottom: 20px;
}
.access-box input {
  width: 100%;
  padding: 14px 16px;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  font-size: 15px;
  margin-bottom: 12px;
  outline: none;
  transition: all 0.3s;
  background: var(--bg);
}
.access-box input:focus {
  border-color: var(--primary);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(255,107,107,0.1);
}
.access-box button {
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  margin-top: 8px;
  box-shadow: 0 4px 12px rgba(255,107,107,0.3);
  transition: all 0.2s;
}
.access-box button:active { transform: scale(0.98); }
.access-qr {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px dashed var(--border);
}
.access-qr-wrapper {
  width: 120px;
  height: 120px;
  margin: 0 auto 10px;
  padding: 8px;
  background: #fff;
  border-radius: 12px;
  box-shadow: var(--shadow);
}
.access-qr-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.access-qr p {
  font-size: 12px;
  color: var(--text-light);
}
.access-tip {
  margin-top: 12px !important;
  font-size: 12px !important;
  color: var(--text-light) !important;
}

/* ===== 弹窗通用 ===== */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
  padding: 20px;
}
.modal {
  background: #fff;
  border-radius: 20px;
  width: 100%;
  max-width: 420px;
  max-height: 85vh;
  overflow-y: auto;
  padding: 24px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.2);
  animation: slideUp 0.3s ease;
}
.modal h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.modal-close {
  background: none;
  border: none;
  font-size: 24px;
  color: var(--text-light);
  cursor: pointer;
  padding: 0;
  line-height: 1;
}

/* ===== 图片灯箱 ===== */
#lightbox {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.95);
  z-index: 2000;
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}
#lightbox.active { display: flex; }
#lightbox-img {
  max-width: 100%;
  max-height: 80vh;
  object-fit: contain;
}
#lightbox-info {
  color: #fff;
  padding: 16px;
  text-align: center;
  font-size: 14px;
}
.lightbox-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(4px);
  border: none;
  color: #fff;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.lightbox-btn.prev { left: 16px; }
.lightbox-btn.next { right: 16px; }
.lightbox-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: rgba(255,255,255,0.15);
  border: none;
  color: #fff;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 20px;
  cursor: pointer;
}

/* ===== 上传区域 ===== */
.upload-area {
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  padding: 32px 20px;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s;
  background: var(--bg);
  margin-bottom: 16px;
}
.upload-area:active, .upload-area:hover {
  border-color: var(--primary);
  background: var(--primary-light);
}
.upload-area .upload-icon {
  font-size: 40px;
  margin-bottom: 8px;
}
.upload-area p {
  font-size: 14px;
  color: var(--text-sub);
}
.upload-progress {
  margin-top: 12px;
  font-size: 13px;
  color: var(--text-sub);
}
.progress-bar {
  width: 100%;
  height: 6px;
  background: var(--border);
  border-radius: 3px;
  overflow: hidden;
  margin-top: 8px;
}
.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  border-radius: 3px;
  transition: width 0.3s;
}

/* ===== 文件列表 ===== */
.files-modal {
  background: #fff;
  border-radius: 20px 20px 0 0;
  width: 100%;
  max-width: 500px;
  max-height: 85vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  margin: 0 auto;
}
.files-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-weight: 600;
}
.files-grid {
  padding: 12px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  overflow-y: auto;
  flex: 1;
}
.thumb-card {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  aspect-ratio: 1;
  background: var(--bg);
  cursor: pointer;
}
.thumb-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.thumb-card .thumb-name {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(0,0,0,0.7));
  color: #fff;
  font-size: 10px;
  padding: 12px 6px 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ===== 底部客服按钮 ===== */
.cs-fab {
  position: fixed;
  bottom: 90px;
  right: 20px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  cursor: pointer;
  z-index: 99;
  border: none;
}

/* ===== 添加到桌面提示条 ===== */
.add-to-home-bar {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  background: linear-gradient(135deg, #FF6B6B, #FF8E53);
  color: #fff;
  font-size: 13px;
  cursor: pointer;
}
.add-to-home-bar .ath-icon { margin-right: 8px; font-size: 18px; }
.add-to-home-bar .ath-text { flex: 1; }
.add-to-home-bar .ath-close {
  font-size: 20px;
  padding: 0 8px;
  opacity: 0.8;
  cursor: pointer;
}

/* ===== 夜晚模式 ===== */
body.dark-mode {
  --bg: #1A1A2E;
  --card-bg: #16213E;
  --text-main: #E8E8E8;
  --text-sub: #A0A0B0;
  --text-light: #6C6C80;
  --border: #2A2A4A;
  --tag-bg: #252540;
  --primary-light: #2A2040;
  --shadow: 0 2px 12px rgba(0,0,0,0.3);
}
body.dark-mode .site-header {
  background: linear-gradient(135deg, #C44569, #E77F67);
}
body.dark-mode .access-box,
body.dark-mode .modal,
body.dark-mode .files-modal {
  background: #16213E;
  color: var(--text-main);
}
body.dark-mode .access-box input,
body.dark-mode .search-box input {
  background: #0F1626;
  border-color: #2A2A4A;
  color: var(--text-main);
}
body.dark-mode .activity-cover-placeholder {
  background: linear-gradient(135deg, #2A2040, #1A2A40);
}
body.dark-mode #lightbox { background: rgba(0,0,0,0.98); }

/* ===== 响应式 · PC端优化 ===== */
@media (min-width: 768px) {
  body { padding-bottom: 40px; }
  .site-header { padding: 48px 20px 36px; }
  .site-header h1 { font-size: 30px; }
  .activity-list, .activity-grid {
    padding: 0 24px;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    max-width: 1000px;
  }
  .activity-card { margin-bottom: 0; }
  .card-cover { height: 220px !important; }
  .year-section { grid-column: 1 / -1; margin-bottom: 0; }
  .year-title { margin: 24px 0 16px; }
  .recent-grid { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; }
  .recent-cover { height: 140px; }
  .toolbar-inner { max-width: 1000px; }
  .header-stats { gap: 16px; }
  .header-stats .stat-item { padding: 8px 20px; font-size: 14px; }
  .fab-upload { bottom: 32px; right: 32px; width: 64px; height: 64px; font-size: 28px; }
  .cs-fab { bottom: 108px; right: 32px; width: 52px; height: 52px; }
}

@media (min-width: 1024px) {
  .activity-list, .activity-grid {
    grid-template-columns: repeat(3, 1fr);
    max-width: 1200px;
  }
  .card-cover { height: 200px !important; }
}

/* ===== 最近活动文字优化 ===== */
.recent-card {
  position: relative;
}
.recent-info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(0,0,0,0.75));
  padding: 24px 10px 10px;
  color: #fff;
}
.recent-title {
  color: #fff !important;
  font-size: 14px;
  font-weight: 600;
  text-shadow: 0 1px 3px rgba(0,0,0,0.5);
}
.recent-date {
  color: rgba(255,255,255,0.85) !important;
  font-size: 11px;
  text-shadow: 0 1px 2px rgba(0,0,0,0.5);
}

/* ===== 提升整体质感 ===== */
.activity-card {
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s;
}
.activity-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(45, 52, 54, 0.15);
}
.card-cover img {
  transition: transform 0.5s ease;
}
.activity-card:hover .card-cover img {
  transform: scale(1.05);
}
.card-link {
  transition: all 0.25s ease;
}
.card-link:hover {
  transform: translateY(-1px);
}
.card-link.upload:hover {
  box-shadow: 0 4px 16px rgba(255,107,107,0.4);
}

/* ===== 底部修复 ===== */
body { padding-bottom: 100px; }
@media (min-width: 768px) {
  body { padding-bottom: 60px; }
}

/* ===== 封面图清晰度优化 ===== */
.card-cover img {
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
}

/* ===== 悬浮客服按钮 ===== */
.customer-service-btn {
  position: fixed;
  right: 16px;
  bottom: 100px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, #FF6B6B, #FF8E53);
  color: #fff;
  border: 3px solid #fff;
  font-size: 24px;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(255,107,107,0.4);
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s;
}
.customer-service-btn:active {
  transform: scale(0.9);
}

/* ===== 悬浮添加到桌面按钮 ===== */
.add-home-btn {
  position: fixed;
  right: 16px;
  bottom: 165px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, #FF6B6B, #FF8E53);
  color: #fff;
  border: 3px solid #fff;
  font-size: 22px;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(255,107,107,0.4);
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ===== 底部信息栏 ===== */
.site-footer {
  text-align: center;
  padding: 24px 16px;
  color: var(--text-light);
  font-size: 12px;
  line-height: 1.8;
  border-top: 1px solid var(--border);
  margin-top: 20px;
  background: var(--card-bg);
}
.site-footer .footer-tip {
  color: var(--text-light);
  margin-top: 4px;
}

/* ===== 客服弹窗 ===== */
.cs-modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}
.cs-modal {
  background: #fff;
  width: 100%;
  max-width: 420px;
  border-radius: 20px 20px 0 0;
  padding: 24px;
  animation: slideUp 0.3s ease;
}
@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}
.cs-modal-title {
  font-size: 18px;
  font-weight: 700;
  text-align: center;
  margin-bottom: 4px;
}
.cs-modal-sub {
  font-size: 13px;
  color: var(--text-light);
  text-align: center;
  margin-bottom: 20px;
}
.cs-option {
  display: flex;
  align-items: center;
  padding: 16px;
  background: var(--bg);
  border-radius: 12px;
  margin-bottom: 12px;
  text-decoration: none;
  color: inherit;
  border: none;
  width: 100%;
  cursor: pointer;
  text-align: left;
}
.cs-option:active { background: var(--border); }
.cs-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, #FF6B6B, #FF8E53);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  margin-right: 14px;
  flex-shrink: 0;
}
.cs-option-text { flex: 1; }
.cs-option-title { font-size: 15px; font-weight: 600; }
.cs-option-desc { font-size: 12px; color: var(--text-light); margin-top: 2px; }
.cs-arrow { color: var(--text-light); font-size: 20px; }
.cs-close {
  width: 100%;
  padding: 14px;
  background: var(--bg);
  border: none;
  border-radius: 12px;
  font-size: 15px;
  color: var(--text-sub);
  cursor: pointer;
  margin-top: 8px;
}

/* ===== 二维码弹窗 ===== */
.qr-modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.6);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.qr-modal {
  background: #fff;
  border-radius: 20px;
  padding: 24px;
  width: 100%;
  max-width: 360px;
  text-align: center;
}
.qr-modal-header {
  background: linear-gradient(135deg, #FF6B6B, #FF8E53);
  color: #fff;
  margin: -24px -24px 20px;
  padding: 20px;
  border-radius: 20px 20px 0 0;
  font-size: 18px;
  font-weight: 700;
}

/* ===== 上传按钮 ===== */
.upload-btn-main {
  display: block;
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, #FF6B6B, #FF8E53);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(255,107,107,0.3);
}

/* ===== 回到顶部按钮 ===== */
.back-to-top {
  position: fixed;
  right: 16px;
  bottom: 170px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, #FF6B6B, #FF8E53);
  color: #fff;
  border: 2px solid #fff;
  font-size: 20px;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(255,107,107,0.4);
  z-index: 998;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s;
}
.back-to-top:active {
  transform: scale(0.9);
}

/* ===== 夜晚模式补充 ===== */
body.dark-mode .customer-service-btn,
body.dark-mode .add-home-btn {
  background: linear-gradient(135deg, #c0392b, #e67e22);
  box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}
body.dark-mode .cs-modal,
body.dark-mode .qr-modal {
  background: #1e1e1e;
}
body.dark-mode .cs-modal-title,
body.dark-mode .cs-option-title { color: #e0e0e0; }
body.dark-mode .cs-option-desc,
body.dark-mode .cs-modal-sub { color: #999; }
body.dark-mode .cs-option,
body.dark-mode .cs-close { background: #2a2a2a; }
body.dark-mode .site-footer {
  background: #1a1a1a;
  color: #888;
  border-top-color: #333;
}

/* ===== 分享二维码（卡片式） ===== */
.qr-modal {
  max-width: 380px;
  padding: 0;
  overflow: hidden;
  background: #fff;
}
.qr-hero {
  position: relative;
  padding: 24px 20px 20px;
  text-align: center;
  color: #fff;
  background: linear-gradient(135deg, #FF6B6B 0%, #FF8E53 100%);
}
.qr-hero-icon {
  width: 52px;
  height: 52px;
  margin: 0 auto 10px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.22);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  line-height: 1;
}
.qr-hero h3 {
  margin: 0;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0.5px;
  justify-content: center;
}
.qr-hero-sub {
  margin: 6px 0 0;
  font-size: 13px;
  opacity: 0.92;
}
.qr-close {
  position: absolute;
  right: 10px;
  top: 6px;
  background: none;
  border: none;
  color: #fff;
  font-size: 26px;
  line-height: 1;
  padding: 4px 8px;
  cursor: pointer;
  opacity: 0.85;
}
.qr-modal-body {
  padding: 18px 18px 20px;
  text-align: center;
}
.qr-card {
  background: #fff;
  border: 1px solid rgba(255, 107, 107, 0.14);
  border-radius: 18px;
  padding: 16px 14px 12px;
  box-shadow: 0 8px 28px rgba(255, 107, 107, 0.16);
}
.qr-card-desc {
  margin: 0 0 12px;
  font-size: 13px;
  color: var(--text-sub, #636E72);
  line-height: 1.5;
}
.qr-code-wrapper {
  background: #fff;
  padding: 8px;
  border-radius: 14px;
  display: inline-block;
}
.qr-code-wrapper img {
  display: block;
  width: 216px;
  height: 216px;
  border-radius: 8px;
}
.qr-url {
  margin: 12px 0 0;
  font-size: 12px;
  color: var(--text-sub, #636E72);
  word-break: break-all;
  line-height: 1.4;
}
.qr-hint {
  margin: 10px 0 0;
  font-size: 12px;
  color: #E14B4B;
  background: rgba(255, 107, 107, 0.1);
  padding: 7px 12px;
  border-radius: 20px;
  display: inline-block;
}
.qr-actions {
  display: flex;
  gap: 10px;
  margin-top: 14px;
}
.qr-btn {
  flex: 1;
  padding: 12px 0;
  border: none;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  background: #F1F2F6;
  color: #2D3436;
  cursor: pointer;
  transition: transform 0.15s ease;
}
.qr-btn:active { transform: scale(0.97); }
.qr-btn.primary {
  background: linear-gradient(135deg, #FF6B6B, #FF8E53);
  color: #fff;
  box-shadow: 0 4px 14px rgba(255, 107, 107, 0.32);
}

/* 登记页小二维码 */
.access-qr { margin-top: 16px; }
.access-qr-wrapper {
  background: #fff;
  padding: 7px;
  border-radius: 12px;
  display: inline-block;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
}
.access-qr-wrapper img {
  width: 118px;
  height: 118px;
  display: block;
  border-radius: 6px;
}
.access-qr p {
  margin-top: 8px;
  font-size: 12px;
  color: var(--text-sub, #636E72);
}

body.dark-mode .qr-card {
  background: #16213E;
  border-color: rgba(255, 255, 255, 0.06);
}
body.dark-mode .qr-url,
body.dark-mode .qr-card-desc { color: #9BA3B0; }
body.dark-mode .qr-hint { background: rgba(255, 107, 107, 0.14); color: #FF9A8B; }
body.dark-mode .qr-btn { background: #0F1626; color: #E8E8E8; }
