/* ===== Reset & Base ===== */
* { margin: 0; padding: 0; box-sizing: border-box; }
:root {
  --sidebar-w: 60px;
  --glass-bg: rgba(255,255,255,0.05);
  --glass-bg-hover: rgba(255,255,255,0.12);
  --glass-border: rgba(255,255,255,0.1);
  --glass-strong: rgba(255,255,255,0.08);
  --glass-blur: blur(35px);
  --dropdown-bg: rgba(12,12,28,0.94);
  --text-primary: #e8eaff;
  --text-secondary: rgba(200,210,255,0.55);
  --text-dark: #333;
  --accent: #6c5ce7;
  --accent-light: #a29bfe;
  --accent-glow: rgba(108,92,231,0.35);
  --cyan: #00d4ff;
  --cyan-glow: rgba(0,212,255,0.25);
  --hot1: #ff4757; --hot2: #ff6348; --hot3: #ffa502;
  --radius: 15px;
  --radius-lg: 20px;
  --shadow-glass: 0 10px 40px rgba(0,0,0,0.25);
  --card-border: rgba(255,255,255,0.08);
}
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'PingFang SC', 'Microsoft YaHei', sans-serif;
  overflow-x: hidden;
  overflow-y: auto;
  min-height: 100vh;
  color: var(--text-primary);
}

/* ===== Background ===== */
.bg-layer {
  position: fixed; inset: 0; z-index: -1;
  background: linear-gradient(135deg, #06060f 0%, #0c0c20 30%, #0f1228 60%, #0a0e22 100%);
  background-size: 400% 400%;
  animation: bgShift 20s ease infinite;
  transition: background 0.5s ease;
}
.bg-layer::after {
  content: '';
  position: absolute; inset: 0;
  background:
    radial-gradient(circle at 15% 20%, rgba(108,92,231,0.12) 0%, transparent 35%),
    radial-gradient(circle at 85% 80%, rgba(0,212,255,0.08) 0%, transparent 35%);
  pointer-events: none;
}
@keyframes bgShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}
/* Theme/skin backgrounds are applied via JS applyTheme() */
.bg-layer.custom-image {
  background-size: cover;
  background-position: center;
}

/* ===== Sidebar ===== */
.sidebar {
  position: fixed; left: 0; top: 0; bottom: 0;
  width: var(--sidebar-w);
  background: rgba(8,8,20,0.65);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-right: 1px solid var(--glass-border);
  display: flex; flex-direction: column; align-items: center;
  padding: 20px 0;
  z-index: 100;
}
.sidebar::after {
  content: '';
  position: absolute; right: 0; top: 20%; bottom: 20%; width: 1px;
  background: linear-gradient(180deg, transparent, var(--accent-glow), transparent);
}
.sidebar-logo {
  width: 35px; height: 35px;
  display: flex; align-items: center; justify-content: center;
  color: var(--accent-light);
  cursor: pointer;
  margin-bottom: 25px;
  transition: transform 0.2s;
}
.sidebar-logo:hover { transform: scale(1.1); }
.sidebar-nav {
  flex: 1;
  display: flex; flex-direction: column; align-items: center;
  gap: 10px;
  overflow-y: auto;
}
.sidebar-item {
  width: 35px; height: 35px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 13px;
  cursor: pointer;
  color: var(--text-secondary);
  transition: all 0.25s;
  position: relative;
  font-size: 13px;
  white-space: nowrap;
}
.sidebar-item:hover {
  background: var(--glass-bg-hover);
  color: var(--text-primary);
  transform: scale(1.08);
}
.sidebar-item.active {
  background: rgba(108,92,231,0.2);
  color: var(--accent-light);
  transform: scale(1.08);
}
.sidebar-item.active::before {
  content: '';
  position: absolute; left: -13px; top: 50%; transform: translateY(-50%);
  width: 4px; height: 28px;
  background: var(--accent-light);
  border-radius: 3px;
  box-shadow: 0 0 13px var(--accent-glow);
}
.sidebar-item[title]:hover::after {
  content: attr(title);
  position: absolute;
  left: calc(100% + 10px);
  top: 50%; transform: translateY(-50%);
  background: rgba(0,0,0,0.85);
  color: #fff;
  font-size: 15px;
  padding: 5px 13px;
  border-radius: 8px;
  white-space: nowrap;
  pointer-events: none;
  z-index: 999;
}
.sidebar-add {
  width: 35px; height: 35px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 13px;
  cursor: pointer;
  color: var(--text-secondary);
  transition: all 0.25s;
}
.sidebar-add:hover {
  background: var(--glass-bg-hover);
  color: var(--text-primary);
  transform: scale(1.08);
}

/* ===== Main Content ===== */
.main-content {
  margin-left: var(--sidebar-w);
  padding: 38px 50px 100px;
  min-height: 100vh;
  position: relative;
}
.top-controls {
  position: absolute; top: 22px; right: 38px;
  display: flex; gap: 12px;
  align-items: center;
}
.top-btn {
  width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,0.05);
  backdrop-filter: blur(13px);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.25s;
}
.top-btn svg { width: 22px; height: 22px; }
.top-btn:hover {
  background: rgba(108,92,231,0.15);
  border-color: var(--accent);
  color: var(--accent-light);
  box-shadow: 0 0 15px var(--accent-glow);
  transform: translateY(-2px);
}
.top-btn:active { transform: translateY(0); }

/* Login button in top bar (not logged in) */
.top-login-btn {
  display: flex; align-items: center; gap: 7px;
  padding: 0 16px;
  height: 40px;
  background: linear-gradient(135deg, rgba(108,92,231,0.2), rgba(162,155,254,0.1));
  border: 1px solid rgba(108,92,231,0.3);
  border-radius: 12px;
  color: var(--accent-light);
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.25s;
  white-space: nowrap;
}
.top-login-btn svg { width: 22px; height: 22px; }
.top-login-btn:hover {
  background: linear-gradient(135deg, rgba(108,92,231,0.35), rgba(162,155,254,0.2));
  border-color: var(--accent);
  box-shadow: 0 0 15px var(--accent-glow);
  transform: translateY(-2px);
}

/* ===== Clock ===== */
.clock-section {
  text-align: center;
  margin-top: 63px;
  margin-bottom: 25px;
}
.clock-time {
  font-size: 64px;
  font-weight: 100;
  letter-spacing: 4px;
  background: linear-gradient(135deg, #e8eaff 0%, #a29bfe 60%, #00d4ff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: none;
  filter: drop-shadow(0 3px 25px rgba(108,92,231,0.35));
}
.clock-date {
  font-size: 15px;
  color: var(--text-secondary);
  margin-top: 10px;
  letter-spacing: 3px;
  text-transform: uppercase;
}

/* ===== Search ===== */
.search-section {
  max-width: 850px;
  margin: 0 auto 38px;
  position: relative;
}
.search-box {
  display: flex;
  align-items: center;
  background: rgba(255,255,255,0.05);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--card-border);
  border-radius: 63px;
  padding: 5px 8px 5px 5px;
  transition: all 0.3s;
  box-shadow: var(--shadow-glass);
}
.search-box:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 25px var(--accent-glow), 0 10px 40px rgba(0,0,0,0.25);
}
.search-box:focus-within .search-submit {
  box-shadow: 0 0 15px var(--accent-glow);
}
.search-engine-btn {
  width: 42px; height: 42px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  cursor: pointer;
  flex-shrink: 0;
  transition: transform 0.2s;
}
.search-engine-btn:hover { transform: scale(1.08); }
.search-engine-btn .se-badge {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px;
  border-radius: 50%;
  font-size: 16px; font-weight: 700;
  color: #fff;
}
.se-badge.baidu { background: #3388ff; }
.se-badge.google { background: #4285f4; }
.se-badge.bing { background: #00809d; }
.se-badge.sogou { background: #fb6022; }

.search-box input {
  flex: 1;
  background: none;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-size: 19px;
  padding: 10px 20px;
}
.search-box input::placeholder {
  color: var(--text-secondary);
}
.search-submit {
  width: 42px; height: 42px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--accent), var(--accent-light));
  border-radius: 50%;
  border: none;
  color: #fff;
  cursor: pointer;
  transition: all 0.25s;
  flex-shrink: 0;
}
.search-submit:hover {
  background: linear-gradient(135deg, var(--accent-light), var(--cyan));
  transform: scale(1.05);
}
.search-engine-dropdown {
  position: absolute; top: 65px; left: 0;
  background: var(--dropdown-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 10px 0;
  min-width: 200px;
  z-index: 200;
  box-shadow: var(--shadow-glass);
}
.se-item {
  display: flex; align-items: center; gap: 13px;
  padding: 10px 20px;
  cursor: pointer;
  color: var(--text-primary);
  transition: background 0.2s;
}
.se-item:hover { background: rgba(108,92,231,0.25); }
.se-item .se-badge {
  display: inline-flex; align-items: center; justify-content: center;
  width: 25px; height: 25px;
  border-radius: 50%;
  font-size: 14px; font-weight: 700;
  color: #fff;
}

/* ===== Search Suggest Dropdown ===== */
.search-suggest {
  position: absolute; top: 65px; left: 0; right: 0;
  background: var(--dropdown-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 8px 0;
  z-index: 300;
  max-height: 450px;
  overflow-y: auto;
  box-shadow: var(--shadow-glass);
}
.suggest-item {
  display: flex; align-items: center; gap: 13px;
  padding: 10px 20px;
  cursor: pointer;
  transition: background 0.15s;
}
.suggest-item:hover, .suggest-item.active {
  background: var(--accent);
}
.suggest-icon {
  width: 30px; height: 30px;
  border-radius: 10px;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 18px; font-weight: 700;
  color: #fff;
  flex-shrink: 0;
  overflow: hidden;
}
.suggest-icon img {
  width: 100%; height: 100%; object-fit: cover;
}
.suggest-info {
  display: flex; flex-direction: column; gap: 3px;
  overflow: hidden;
}
.suggest-name {
  font-size: 15px; color: var(--text-primary);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.suggest-url {
  font-size: 13px; color: var(--text-secondary);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.suggest-empty {
  padding: 20px; text-align: center;
  font-size: 16px; color: var(--text-secondary);
}

/* ===== Widget Cards ===== */
.widget-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 20px;
  margin-bottom: 38px;
}
.widget-card {
  background: rgba(255,255,255,0.04);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-lg);
  padding: 20px;
  cursor: pointer;
  transition: all 0.3s;
  max-height: 375px;
  overflow: hidden;
  box-shadow: var(--shadow-glass);
  position: relative;
}
.widget-card::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent-glow), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}
.widget-card:hover {
  background: rgba(255,255,255,0.08);
  border-color: rgba(108,92,231,0.3);
  transform: translateY(-4px);
  box-shadow: 0 15px 50px rgba(0,0,0,0.3), 0 0 25px var(--accent-glow);
}
.widget-card:hover::before { opacity: 1; }
.widget-ai {
  background: linear-gradient(135deg, rgba(108,92,231,0.15), rgba(0,212,255,0.05));
  border-color: rgba(108,92,231,0.25);
}
.widget-ai:hover {
  background: linear-gradient(135deg, rgba(108,92,231,0.25), rgba(0,212,255,0.1));
  border-color: rgba(108,92,231,0.4);
}
.widget-header {
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 15px;
  color: var(--text-secondary);
}
.widget-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
}
.widget-subtitle {
  font-size: 13px;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-left: auto;
  letter-spacing: 1px;
}
/* Unified widget body icon style (replaces emoji icons with SVG) */
.widget-body-icon {
  flex-shrink: 0;
  color: var(--text-secondary);
  opacity: 0.8;
}
/* Legacy emoji icon classes kept for backward compat but unified */
.ai-sparkle,
.lrc-sparkle,
.tasks-icon,
.hosting-icon,
.tickets-icon,
.md-editor-icon,
.meeting-icon,
.compress-icon,
.photoshop-icon {
  font-size: 20px;
}
/* Unified widget body layout: flex row with icon + text, consistent gap */
.ai-body,
.lrc-body {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Todo */
.todo-input-row {
  display: flex; gap: 10px;
  margin-bottom: 13px;
}
.todo-input-row input {
  flex: 1;
  background: rgba(255,255,255,0.12);
  border: 1px solid var(--card-border);
  border-radius: 10px;
  padding: 8px 15px;
  color: var(--text-primary);
  font-size: 14px;
  outline: none;
}
.todo-input-row input::placeholder { color: var(--text-secondary); }
.todo-input-row button {
  width: 35px; height: 35px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 20px;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.todo-list {
  list-style: none;
  max-height: 200px;
  overflow-y: auto;
}
.todo-list::-webkit-scrollbar { width: 4px; }
.todo-list::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.2); border-radius: 4px; }
.todo-item {
  display: flex; align-items: center; gap: 10px;
  padding: 5px 0;
  font-size: 14px;
  color: var(--text-secondary);
}
.todo-item.done .todo-text { text-decoration: line-through; opacity: 0.5; }
.todo-checkbox {
  width: 18px; height: 18px;
  border: 2px solid var(--text-secondary);
  border-radius: 5px;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.todo-checkbox.checked {
  background: var(--accent);
  border-color: var(--accent);
}
.todo-checkbox.checked::after {
  content: '✓'; color: #fff; font-size: 13px;
}
.todo-text { flex: 1; }
.todo-delete {
  color: rgba(255,255,255,0.3);
  cursor: pointer;
  font-size: 18px;
  display: block;
  opacity: 0.4;
  transition: opacity 0.2s;
  padding: 5px 10px;
}
.todo-item:hover .todo-delete { opacity: 1; }

/* Calendar */
.calendar-body {
  font-size: 14px;
}
.cal-header {
  display: flex; justify-content: center; align-items: center; gap: 10px;
  margin-bottom: 13px;
}
.cal-nav-btn {
  width: 28px; height: 28px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 10px;
  border: 1px solid var(--card-border);
  background: rgba(255,255,255,0.06);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
  font-size: 15px;
  line-height: 1;
  font-family: monospace;
}
.cal-nav-btn:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  box-shadow: 0 0 15px rgba(108,92,231,0.4);
}
.cal-today-btn {
  width: 28px; height: 28px;
  border-radius: 10px;
  border: 1px solid var(--accent);
  background: rgba(108,92,231,0.15);
  color: var(--accent-light);
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.2s;
}
.cal-today-btn:hover {
  background: var(--accent);
  color: #fff;
}
.cal-month { font-weight: 600; font-size: 16px; color: var(--text-primary); min-width: 100px; text-align: center; }
.cal-today-row {
  display: flex; align-items: baseline; justify-content: center; gap: 10px;
  margin-bottom: 10px;
}
.cal-day-big {
  font-size: 35px;
  font-weight: 200;
  color: var(--accent-light);
  line-height: 1;
}
.cal-info {
  font-size: 13px;
  color: var(--text-secondary);
}
.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
  text-align: center;
}
.cal-dow {
  font-size: 13px;
  color: var(--text-secondary);
  padding: 5px 0;
  font-weight: 600;
}
.cal-dow.weekend { color: rgba(255,107,107,0.7); }
.cal-day {
  padding: 5px 0;
  font-size: 13px;
  color: var(--text-secondary);
  border-radius: 8px;
  transition: all 0.15s;
}
.cal-day.other-month {
  color: rgba(255,255,255,0.15);
}
.cal-day.weekend { color: rgba(255,107,107,0.65); }
.cal-day.today {
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  box-shadow: 0 0 15px rgba(108,92,231,0.5);
}

/* ===== Bookmarks Grid ===== */
.bookmarks-section {
  margin-bottom: 30px;
}
.bookmarks-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 22px;
}
.bookmark-item {
  display: flex; flex-direction: column; align-items: center;
  gap: 12px;
  padding: 16px 10px;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 0.25s;
  text-decoration: none;
}
.bookmark-item:hover {
  background: rgba(108,92,231,0.1);
  transform: translateY(-4px);
  border-radius: var(--radius);
}
.bookmark-item:hover .bookmark-icon {
  box-shadow: 0 0 25px var(--accent-glow);
  transform: scale(1.06);
}
.bookmark-icon {
  width: 68px; height: 68px;
  border-radius: 20px;
  display: flex; align-items: center; justify-content: center;
  font-size: 29px; font-weight: 700;
  color: #fff;
  position: relative;
  overflow: hidden;
  transition: all 0.25s;
}
.bookmark-icon img {
  width: 100%; height: 100%;
  object-fit: cover;
}
.bookmark-name {
  font-size: 14px;
  color: var(--text-secondary);
  text-align: center;
  max-width: 90px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.bookmark-item.add-bookmark {
  border: 2px dashed rgba(255,255,255,0.15);
  opacity: 0.6;
}
.bookmark-item.add-bookmark:hover {
  opacity: 1;
  border-color: var(--accent-light);
}

/* ===== Bottom Widgets ===== */
.bottom-widgets {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
  margin-bottom: 50px;
}
.bottom-widget {
  background: rgba(255,255,255,0.04);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-glass);
  position: relative;
  overflow: hidden;
}
.bottom-widget::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent, var(--cyan-glow), transparent);
}
.bw-header { margin-bottom: 10px; }
.bw-header h3 {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 5px;
}
.bw-days {
  font-size: 40px;
  font-weight: 200;
  color: var(--accent-light);
}
.bw-location { font-size: 14px; color: var(--text-secondary); }
.bw-temp { font-size: 45px; font-weight: 200; color: var(--text-primary); }
.bw-range { font-size: 14px; color: var(--text-secondary); }
.bw-forecast {
  display: flex; gap: 20px; margin-top: 10px;
  font-size: 13px; color: var(--text-secondary);
}
.bw-poem-text {
  font-size: 16px;
  line-height: 1.8;
  color: var(--text-primary);
  margin-bottom: 10px;
}
.bw-poem-author {
  font-size: 14px;
  color: var(--text-secondary);
}
.eat-btn {
  background: linear-gradient(135deg, var(--accent), var(--accent-light));
  color: #fff;
  border: none;
  border-radius: 20px;
  padding: 8px 25px;
  font-size: 15px;
  cursor: pointer;
  margin-top: 10px;
  transition: all 0.25s;
}
.eat-btn:hover {
  background: linear-gradient(135deg, var(--accent-light), var(--cyan));
  box-shadow: 0 0 15px var(--accent-glow);
}
.eat-result {
  font-size: 20px;
  font-weight: 600;
  color: var(--accent-light);
  margin-top: 10px;
  min-height: 30px;
}

/* ===== Settings Panel ===== */
.settings-panel {
  position: fixed; inset: 0;
  z-index: 500;
  display: flex;
}
.settings-overlay {
  position: absolute; inset: 0;
  background: rgba(0,0,0,0.5);
}
.settings-content {
  position: absolute; right: 0; top: 0; bottom: 0;
  width: 525px;
  background: rgba(15,15,35,0.92);
  backdrop-filter: blur(38px);
  -webkit-backdrop-filter: blur(38px);
  border-left: 1px solid var(--glass-border);
  display: flex; flex-direction: column;
  overflow-y: auto;
}
.settings-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 25px 30px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.settings-header h2 { font-size: 23px; font-weight: 600; }
.settings-header button {
  background: none; border: none;
  color: var(--text-secondary);
  cursor: pointer;
}
.settings-body { padding: 25px 30px; }
.setting-group {
  margin-bottom: 30px;
}
.setting-group h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 15px;
  color: var(--accent-light);
}
.setting-row {
  display: flex; align-items: center; gap: 15px;
  margin-bottom: 13px;
}
.setting-row label {
  font-size: 16px;
  color: var(--text-secondary);
  min-width: 100px;
}
.setting-row input[type="text"], .setting-group select {
  flex: 1;
  background: rgba(255,255,255,0.1);
  border: 1px solid var(--card-border);
  border-radius: 10px;
  padding: 10px 15px;
  color: var(--text-primary);
  font-size: 16px;
  outline: none;
}
.setting-group select option {
  background: #3a3a3a;
  color: #fff;
}
.setting-group select { width: 100%; }
.setting-toggle {
  display: flex; align-items: center; gap: 13px;
  padding: 10px 0;
  font-size: 16px;
  color: var(--text-secondary);
  cursor: pointer;
}
.setting-toggle input[type="checkbox"] {
  width: 20px; height: 20px;
  accent-color: var(--accent);
}
.btn-add-bookmark {
  width: 100%;
  background: rgba(255,255,255,0.08);
  border: 2px dashed rgba(255,255,255,0.15);
  border-radius: 10px;
  padding: 13px;
  color: var(--text-secondary);
  font-size: 16px;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-add-bookmark:hover {
  border-color: var(--accent-light);
  color: var(--text-primary);
}
.bookmark-admin-item {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 0;
  font-size: 15px;
  color: var(--text-secondary);
}
.bookmark-admin-item .bm-admin-del {
  color: #ff4757; cursor: pointer; margin-left: auto;
  opacity: 0.4; transition: opacity 0.2s;
  padding: 3px 8px;
}
.bookmark-admin-item:hover .bm-admin-del { opacity: 1; }

/* ===== Modal ===== */
.modal {
  position: fixed; inset: 0;
  z-index: 600;
  display: flex; align-items: center; justify-content: center;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.modal-overlay {
  position: absolute; inset: 0;
  background: rgba(0,0,0,0.5);
}
.modal-content {
  position: relative;
  background: rgba(15,15,35,0.92);
  backdrop-filter: blur(38px);
  -webkit-backdrop-filter: blur(38px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: 30px;
  width: 90%;
  max-width: 500px;
  box-shadow: var(--shadow-glass);
}
.modal-content h3 {
  font-size: 20px;
  margin-bottom: 25px;
}
.form-group {
  margin-bottom: 14px;
}
.form-group label {
  display: block;
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 6px;
}
.form-group input, .form-group select {
  width: 100%;
  background: rgba(255,255,255,0.1);
  border: 1px solid var(--card-border);
  border-radius: 10px;
  padding: 10px 15px;
  color: var(--text-primary);
  font-size: 16px;
  outline: none;
}
.form-group select option {
  background: #3a3a3a;
  color: #fff;
}
.form-group select { width: 100%; }
.form-actions {
  display: flex; gap: 12px; justify-content: flex-end;
  margin-top: 18px;
}
.btn-cancel {
  background: rgba(255,255,255,0.08);
  border: none;
  border-radius: 9px;
  padding: 8px 20px;
  color: var(--text-secondary);
  cursor: pointer;
  font-size: 14px;
}
.btn-confirm {
  background: var(--accent);
  border: none;
  border-radius: 9px;
  padding: 8px 20px;
  color: #fff;
  cursor: pointer;
  font-size: 14px;
}

/* ===== Simple Mode ===== */
body.simple-mode .widget-cards,
body.simple-mode .bookmarks-section,
body.simple-mode .bottom-widgets {
  display: none;
}
body.simple-mode .clock-section {
  margin-top: 250px;
}

/* ===== Responsive ===== */
@media (max-width: 1024px) {
  .bookmarks-grid {
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  }
  .chat-panel { width: 525px; }
}

@media (max-width: 768px) {
  :root { --sidebar-w: 0px; --radius: 14px; }

  /* Global touch improvements */
  * { -webkit-tap-highlight-color: transparent; }
  body { -webkit-text-size-adjust: 100%; }

  /* Sidebar -> bottom nav — rewritten with refined aesthetics */
  .sidebar {
    position: fixed;
    bottom: 0; top: auto; left: 0; right: 0;
    width: 100%; height: 82px;
    flex-direction: row;
    align-items: center;
    padding: 0 10px;
    border-right: none;
    border-top: 1px solid rgba(255,255,255,0.08);
    z-index: 500;
    gap: 0;
    background: rgba(8,8,20,0.92);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    box-shadow: 0 -4px 20px rgba(0,0,0,0.35);
  }
  .sidebar::after { display: none; }
  .sidebar-logo {
    width: 42px; height: 42px; margin-bottom: 0; margin-right: 6px; margin-left: 4px;
    flex-shrink: 0; opacity: 0.7;
    border-radius: 12px;
  }
  .sidebar-logo:active { transform: scale(0.92); }
  .sidebar-logo svg { width: 26px; height: 26px; }
  .sidebar-nav {
    flex: 1; flex-direction: row; align-items: center;
    justify-content: center; /* 居中显示 Tab 菜单 */
    gap: 6px;
    padding: 8px 4px; /* 上下留白，避免点击态光晕/波纹被裁剪 */
  }
  .sidebar-item {
    width: 58px; height: 66px; flex-shrink: 0;
    border-radius: 16px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.06);
    display: flex; align-items: center; justify-content: center;
    flex-direction: column; gap: 4px;
    opacity: 1;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    -webkit-tap-highlight-color: transparent;
  }
  .sidebar-item:active {
    transform: scale(0.9);
    transition: transform 0.1s;
  }
  .sidebar-item-icon {
    display: flex; align-items: center; justify-content: center;
    width: 24px; height: 24px; flex-shrink: 0;
    line-height: 1;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }
  .sidebar-item-icon svg { width: 24px; height: 24px; display: block; }
  .sidebar-item-icon img { width: 24px; height: 24px; object-fit: contain; display: block; }
  .sidebar-item-icon span { display: flex; align-items: center; justify-content: center; line-height: 1; }
  .sidebar-item-label {
    font-size: 10px;
    color: rgba(255,255,255,0.55);
    line-height: 1;
    max-width: 54px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-align: center;
    display: block;
    transition: color 0.3s;
  }
  .sidebar-item:hover {
    background: rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.9);
  }
  .sidebar-item.active {
    background: linear-gradient(135deg, rgba(108,92,231,0.25), rgba(108,92,231,0.12));
    color: #fff;
    border-color: rgba(108,92,231,0.4);
    box-shadow: 0 0 20px rgba(108,92,231,0.3), inset 0 1px 0 rgba(255,255,255,0.08);
  }
  .sidebar-item.active .sidebar-item-label { color: #fff; }
  .sidebar-item.active .sidebar-item-icon { transform: scale(1.1); }
  .sidebar-item.active::after {
    content: '';
    position: absolute;
    bottom: 3px; left: 50%; transform: translateX(-50%);
    width: 22px; height: 3px;
    background: var(--accent-light);
    border-radius: 3px;
    box-shadow: 0 0 8px var(--accent-glow);
  }
  /* Ripple animation on switch */
  .sidebar-item.ripple {
    animation: tabRipple 0.4s ease-out;
  }
  @keyframes tabRipple {
    0% { box-shadow: 0 0 0 0 rgba(108,92,231,0.5); }
    100% { box-shadow: 0 0 0 16px rgba(108,92,231,0); }
  }
  /* More button */
  .sidebar-item-more .sidebar-item-icon {
    color: rgba(255,255,255,0.5);
  }
  .sidebar-item-more.active .sidebar-item-icon {
    color: var(--accent-light);
  }
  .sidebar-add { display: none; }
  .sidebar-item.active::before { display: none; }
  .sidebar-item[title]:hover::after { display: none; }

  /* Mobile Tab Overflow Dropdown */
  .mobile-tab-overflow {
    display: none;
    position: fixed;
    bottom: 90px; right: 10px;
    z-index: 501;
    background: rgba(15,15,30,0.92);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 18px;
    padding: 8px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.5);
    max-width: 260px;
    flex-wrap: wrap;
    gap: 4px;
    transform-origin: bottom right;
    animation: overflowPop 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  }
  @keyframes overflowPop {
    from { opacity: 0; transform: scale(0.85) translateY(8px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
  }
  .mobile-tab-overflow.show {
    display: flex;
  }
  .overflow-tab-item {
    flex: 0 0 auto;
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    width: 62px; height: 58px;
    border-radius: 14px;
    gap: 4px;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s;
    color: rgba(255,255,255,0.6);
  }
  .overflow-tab-item:active { background: rgba(255,255,255,0.1); transform: scale(0.92); }
  .overflow-tab-item.active {
    background: linear-gradient(135deg, rgba(108,92,231,0.25), rgba(108,92,231,0.1));
    color: #fff;
    border: 1px solid rgba(108,92,231,0.3);
  }
  .overflow-tab-icon {
    width: 22px; height: 22px;
    display: flex; align-items: center; justify-content: center;
  }
  .overflow-tab-icon svg { width: 22px; height: 22px; display: block; }
  .overflow-tab-icon img { width: 22px; height: 22px; object-fit: contain; display: block; }
  .overflow-tab-label {
    font-size: 10px;
    color: rgba(255,255,255,0.6);
    max-width: 56px;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
    text-align: center;
  }
  .overflow-tab-item.active .overflow-tab-label { color: #fff; }

  /* "更多" button — softer style to distinguish from normal tabs */
  .sidebar-item-more {
    background: rgba(255,255,255,0.03);
    border: 1px dashed rgba(255,255,255,0.1);
  }
  .sidebar-item-more .sidebar-item-icon {
    color: rgba(255,255,255,0.45);
  }
  .sidebar-item-more .sidebar-item-label {
    color: rgba(255,255,255,0.4);
  }
  .sidebar-item-more.active {
    background: rgba(108,92,231,0.15);
    border-color: rgba(108,92,231,0.3);
  }
  .sidebar-item-more.active .sidebar-item-icon,
  .sidebar-item-more.active .sidebar-item-label {
    color: var(--accent-light);
  }

  /* Main content */
  .main-content {
    margin-left: 0;
    padding: 20px 15px 120px;
  }
  .clock-time { font-size: 42px; letter-spacing: 2px; }
  .clock-date { font-size: 14px; letter-spacing: 4px; }
  .widget-cards { grid-template-columns: 1fr; gap: 15px; }
  .bookmarks-grid { grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 12px; }
  .bottom-widgets { grid-template-columns: 1fr; gap: 15px; }
  .settings-content { width: 100%; }
  .footer-inner { flex-direction: column; gap: 5px; }

  /* Top controls — touch targets */
  .top-controls { right: 20px; gap: 8px; }
  .top-btn { width: 44px; height: 44px; }
  .top-btn svg { width: 22px; height: 22px; }
  .top-login-btn { height: 44px; padding: 0 14px; font-size: 13px; gap: 6px; }
  /* 用户头像下拉菜单移动端向右展开，避免被屏幕左边缘遮挡 */
  .user-avatar { width: 40px; height: 40px; font-size: 16px; border-width: 2px; }
  .user-menu { right: auto; left: 0; top: 52px; min-width: 160px; }
  .top-login-btn svg { width: 20px; height: 20px; }

  /* Clock — larger on mobile */
  .clock-section { margin-top: 80px; }
  .clock-time { font-size: 48px; letter-spacing: 3px; }
  .clock-date { font-size: 14px; }

  /* Search — larger touch targets */
  .search-box input { font-size: 16px; padding: 12px 16px; }
  .search-engine-btn { width: 46px; height: 46px; }
  .search-engine-btn .se-badge { width: 36px; height: 36px; font-size: 16px; }
  .search-submit { width: 46px; height: 46px; }
  .search-submit svg { width: 22px; height: 22px; }
  .se-item { padding: 10px 15px; font-size: 15px; }
  .se-item .se-badge { width: 25px; height: 25px; font-size: 14px; }
  .suggest-icon { width: 30px; height: 30px; font-size: 15px; }
  .suggest-name { font-size: 15px; }
  .suggest-url { font-size: 13px; }

  /* Todo — touch targets */
  .todo-input-row input { font-size: 14px; padding: 6px 13px; }
  .todo-input-row button { width: 33px; height: 33px; font-size: 18px; }
  .todo-checkbox { width: 18px; height: 18px; }
  .todo-checkbox.checked::after { font-size: 11px; }
  .todo-item { padding: 5px 0; font-size: 14px; gap: 8px; }
  .todo-delete { font-size: 15px; }

  /* Calendar — touch targets */
  .cal-nav-btn { width: 28px; height: 28px; font-size: 15px; }
  .cal-today-btn { width: 28px; height: 28px; font-size: 13px; }
  .cal-month { font-size: 15px; min-width: 88px; }
  .cal-day-big { font-size: 30px; }
  .cal-info { font-size: 13px; }
  .cal-dow { font-size: 11px; padding: 4px 0; }
  .cal-day { padding: 5px 0; font-size: 13px; }

  /* Widget text */
  .widget-title { font-size: 15px; font-weight: 600; }
  .widget-subtitle { font-size: 12px; }
  .widget-header { gap: 8px; margin-bottom: 13px; }
  .widget-header svg { width: 18px; height: 18px; }
  /* Mobile: unified icon sizes */
  .widget-body-icon,
  .ai-sparkle,
  .lrc-sparkle,
  .tasks-icon,
  .hosting-icon,
  .tickets-icon,
  .md-editor-icon,
  .meeting-icon,
  .compress-icon,
  .photoshop-icon { font-size: 18px; }
  .widget-body-icon { width: 18px; height: 18px; }
  .ai-body,
  .lrc-body { font-size: 14px; }

  /* Bookmarks — touch-friendly */
  .bookmark-item { padding: 14px 8px; gap: 10px; transition: all 0.2s; }
  .bookmark-item:active { transform: scale(0.93); background: rgba(108,92,231,0.15); border-radius: var(--radius); }
  .bookmark-icon { width: 56px; height: 56px; border-radius: 16px; font-size: 24px; }
  .bookmark-name { font-size: 12px; max-width: 78px; }

  /* Bottom widgets */
  .bw-header h3 { font-size: 15px; }
  .bw-days { font-size: 35px; }
  .bw-location { font-size: 14px; }
  .bw-temp { font-size: 40px; }
  .bw-range { font-size: 14px; }
  .bw-forecast { font-size: 13px; gap: 15px; }
  .bw-poem-text { font-size: 15px; margin-bottom: 8px; }
  .bw-poem-author { font-size: 13px; }
  .eat-btn { font-size: 15px; padding: 8px 25px; }
  .eat-result { font-size: 18px; min-height: 25px; }
  .wallpaper-picker { width: calc(100vw - 40px); max-width: 400px; right: 20px; }

  /* Modal — scrollable, full width */
  .modal-content {
    width: 92%;
    max-width: 500px;
    max-height: 85vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 25px;
  }
  .auth-modal-content { max-width: 340px; padding: 22px 18px 20px; }
  .auth-brand-icon { width: 32px; height: 32px; }
  .auth-brand-name { font-size: 16px; }
  .auth-tab { font-size: 14px; padding: 10px 0 8px; }
  .auth-subtab { font-size: 11px; padding: 5px 6px; }
  .auth-subtabs { padding: 2px; }
  .auth-code-btn { min-width: 80px; padding: 8px 10px; font-size: 12px; }
  .auth-submit-btn { font-size: 14px; padding: 9px 16px; }
  .oauth-btn { width: 42px; height: 42px; font-size: 12px; }

  /* Form actions wrap-safe */
  .form-actions { flex-wrap: wrap; }
  .btn-cancel, .btn-confirm { padding: 13px 25px; font-size: 18px; }

  /* Browser modal — full screen on mobile */
  .browser-modal { align-items: stretch; }
  .browser-window {
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
    border-radius: 0;
  }
  .browser-window.browser-minimized { width: 100%; height: 100%; border-radius: 0; }
  .browser-titlebar {
    flex-wrap: wrap;
    padding: 8px 10px;
    gap: 5px;
  }
  .browser-controls { gap: 3px; }
  .browser-btn { width: 45px; height: 45px; }
  .browser-btn svg { width: 23px; height: 23px; }
  .browser-url-display { font-size: 14px; padding: 5px 10px; order: 5; flex-basis: 100%; }
  .browser-tab { display: none; }
  .browser-tabs { display: none; }

  /* Browser blocked UI */
  .browser-blocked { padding: 25px; }
  .browser-blocked-desc { max-width: 90%; }
  .browser-blocked-url { max-width: 90%; }

  /* Eat button */
  .eat-btn { padding: 13px 30px; }
}

/* ===== Small phones (<=600px) ===== */
@media (max-width: 480px) {
  .main-content { padding: 15px 13px 150px; }
  .clock-time { font-size: 38px; letter-spacing: 2px; }
  .clock-date { font-size: 13px; letter-spacing: 4px; }

  /* Search — compact */
  .search-section { flex-direction: column; gap: 10px; }
  .search-engine-dropdown {
    position: static;
    min-width: unset;
    width: 100%;
    box-shadow: none;
    background: transparent;
    border: 1px solid var(--card-border);
    border-radius: var(--radius);
    max-height: 250px;
  }
  .search-engine-btn { width: 50px; height: 50px; }

  /* Bookmarks — 4 columns max, compact */
  .bookmarks-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
  }
  .bookmark-item { padding: 10px 4px; gap: 6px; }
  .bookmark-item:active { transform: scale(0.93); background: rgba(108,92,231,0.15); border-radius: var(--radius); }
  .bookmark-icon { width: 46px; height: 46px; border-radius: 13px; font-size: 18px; }
  .bookmark-name { font-size: 11px; max-width: 64px; }

  /* Widget cards compact */
  .widget-cards { gap: 13px; }

  /* Browser buttons — essential only on very small screens */
  .browser-btn-min, .browser-btn-max { display: none; }

  /* Modal padding */
  .modal-content { padding: 20px; }
  .modal-content h3 { font-size: 18px; margin-bottom: 18px; }

  /* Top controls compact */
  .top-controls .top-btn:nth-child(1) { display: none; }
  .top-btn { width: 40px; height: 40px; }
  .top-btn svg { width: 20px; height: 20px; }
  .top-login-btn { height: 40px; padding: 0 12px; font-size: 12px; gap: 5px; }
  .top-login-btn svg { width: 18px; height: 18px; }

  /* Clock — compact small phones */
  .clock-section { margin-top: 60px; }
  .clock-time { font-size: 40px; letter-spacing: 2px; }

  /* Bottom nav — compact */
  .sidebar { padding: 0 6px; height: 70px; }
  .sidebar-logo { display: none; }
  .sidebar-item { width: 48px; height: 56px; border-radius: 13px; gap: 3px; }
  .sidebar-item-icon { width: 20px; height: 20px; }
  .sidebar-item-icon svg { width: 20px; height: 20px; }
  .sidebar-item-icon img { width: 20px; height: 20px; }
  .sidebar-item-label { font-size: 8px; max-width: 44px; }
  .sidebar-item.active::after { width: 18px; height: 2px; bottom: 2px; }
  .sidebar-item.active .sidebar-item-icon { transform: scale(1.08); }
  .sidebar-nav { gap: 4px; padding: 4px 3px; }
  .mobile-tab-overflow { bottom: 68px; max-width: 200px; }
  .overflow-tab-item { width: 52px; height: 50px; }
  .overflow-tab-icon { width: 20px; height: 20px; }
  .overflow-tab-icon svg { width: 20px; height: 20px; }
  .overflow-tab-icon img { width: 20px; height: 20px; }
  .main-content { padding: 15px 13px 100px; }

  /* Font sizes */
  .widget-title { font-size: 15px; }
  .widget-subtitle { font-size: 12px; }
}

/* ===== Footer ===== */
.site-footer {
  margin-left: var(--sidebar-w);
  padding: 20px 30px;
  text-align: right;
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 15px;
  flex-wrap: wrap;
}
.footer-copyright,
.footer-icp,
.footer-police {
  font-size: 15px;
  color: var(--text-secondary);
  opacity: 0.7;
}
.footer-icp a,
.footer-police a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: opacity 0.2s;
}
.footer-icp a:hover,
.footer-police a:hover {
  opacity: 0.9;
  text-decoration: underline;
}
body.simple-mode .site-footer {
  display: none;
}

/* ===== Global select option fix ===== */
select option {
  background: #3a3a3a;
  color: #fff;
}

/* ===== Wallpaper Picker ===== */
.wallpaper-picker {
  position: absolute; top: 65px; right: 0;
  background: var(--dropdown-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 15px;
  z-index: 250;
  width: 350px;
  max-height: 400px;
  overflow-y: auto;
  box-shadow: var(--shadow-glass);
}
.wallpaper-picker-title {
  font-size: 15px;
  color: var(--text-secondary);
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.wallpaper-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 13px;
}
.wallpaper-thumb {
  aspect-ratio: 16/10;
  border-radius: 10px;
  cursor: pointer;
  border: 3px solid transparent;
  transition: all 0.2s;
  overflow: hidden;
  position: relative;
}
.wallpaper-thumb:hover {
  border-color: var(--accent-light);
  transform: scale(1.05);
}
.wallpaper-thumb.active {
  border-color: var(--accent);
}
.wallpaper-thumb-gradient {
  width: 100%; height: 100%;
}
.wallpaper-thumb img {
  width: 100%; height: 100%; object-fit: cover;
}
.wallpaper-thumb .wp-delete {
  position: absolute; top: 3px; right: 3px;
  width: 23px; height: 23px;
  background: rgba(0,0,0,0.6);
  border-radius: 50%;
  color: #ff4757;
  font-size: 15px;
  display: none;
  align-items: center; justify-content: center;
  cursor: pointer;
}
.wallpaper-thumb:hover .wp-delete { display: flex; }
/* 触屏设备无 hover，删除按钮常显，保证可点击 */
@media (hover: none) {
  .wallpaper-thumb .wp-delete { display: flex; }
}
.wallpaper-upload-btn {
  width: 100%;
  background: rgba(255,255,255,0.1);
  border: 1px dashed var(--card-border);
  border-radius: 10px;
  padding: 10px;
  color: var(--text-secondary);
  font-size: 15px;
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
}
.wallpaper-upload-btn:hover {
  border-color: var(--accent-light);
  color: var(--text-primary);
  background: rgba(255,255,255,0.15);
}

/* ===== User Auth UI ===== */
.user-area {
  position: relative;
}
.user-avatar {
  width: 48px; height: 48px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--accent), var(--accent-light));
  border-radius: 50%;
  color: #fff;
  font-size: 18px; font-weight: 700;
  cursor: pointer;
  border: 3px solid var(--card-border);
  transition: all 0.25s;
}
.user-avatar:hover {
  box-shadow: 0 0 15px var(--accent-glow);
  border-color: var(--accent-light);
}
.user-menu {
  position: absolute; top: 60px; right: 0;
  background: var(--dropdown-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 10px 0;
  min-width: 175px;
  z-index: 300;
  box-shadow: var(--shadow-glass);
}
.user-menu-header {
  padding: 10px 20px;
  font-size: 16px;
  font-weight: 600;
  color: var(--accent-light);
  border-bottom: 1px solid var(--glass-border);
  margin-bottom: 5px;
}
.user-menu-item {
  padding: 10px 20px;
  font-size: 16px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
}
.user-menu-item:hover {
  background: rgba(108,92,231,0.2);
  color: var(--text-primary);
}

/* ===== Auth Modal ===== */
.auth-modal-content {
  max-width: 360px;
  padding: 26px 22px 22px;
  border-radius: 18px;
  background: rgba(12,12,28,0.95);
  border: 1px solid rgba(108,92,231,0.15);
  box-shadow: 0 20px 60px rgba(0,0,0,0.5), 0 0 80px rgba(108,92,231,0.08);
  animation: authSlideIn 0.35s cubic-bezier(0.22, 0.61, 0.36, 1);
}
@keyframes authSlideIn {
  from { opacity: 0; transform: translateY(20px) scale(0.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
/* Brand header */
.auth-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 16px;
}
.auth-brand-icon {
  width: 36px; height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, #6c5ce7, #a29bfe);
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  box-shadow: 0 4px 15px rgba(108,92,231,0.4);
}
.auth-brand-name {
  font-size: 18px;
  font-weight: 700;
  background: linear-gradient(135deg, #a29bfe, #dfe6e9);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
/* Top tabs: login / register */
.auth-tabs {
  display: flex;
  gap: 0;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--glass-border);
}
.auth-tab {
  flex: 1;
  text-align: center;
  padding: 11px 0 9px;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-secondary);
  cursor: pointer;
  border-bottom: 3px solid transparent;
  transition: all 0.25s;
  position: relative;
  letter-spacing: 0.5px;
}
.auth-tab.active {
  color: var(--accent-light);
  border-bottom-color: var(--accent);
}
.auth-tab:hover:not(.active) {
  color: var(--text-primary);
}

/* Input wrapper with icon */
.auth-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.auth-input-wrap input {
  padding-left: 38px !important;
  width: 100%;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  padding: 9px 13px;
  color: var(--text-primary);
  font-size: 14px;
  outline: none;
  transition: all 0.25s;
}
.auth-input-wrap input::placeholder { color: rgba(255,255,255,0.3); }
.auth-input-wrap input:focus {
  background: rgba(255,255,255,0.09);
  border-color: rgba(108,92,231,0.5);
  box-shadow: 0 0 0 3px rgba(108,92,231,0.12);
}
.auth-input-icon {
  position: absolute;
  left: 12px;
  color: rgba(255,255,255,0.35);
  pointer-events: none;
  transition: color 0.25s;
  z-index: 1;
}
.auth-input-wrap input:focus + .auth-input-icon,
.auth-input-wrap input:focus ~ .auth-input-icon {
  color: var(--accent-light);
}
/* When input is focused, change icon color via parent */
.auth-input-wrap:has(input:focus) .auth-input-icon {
  color: var(--accent-light);
}
.auth-input-wrap input:focus {
  border-color: rgba(108,92,231,0.5);
}
/* Password visibility toggle */
.auth-pwd-toggle {
  position: absolute;
  right: 10px;
  background: none;
  border: none;
  color: rgba(255,255,255,0.3);
  cursor: pointer;
  padding: 4px;
  border-radius: 6px;
  transition: all 0.2s;
  z-index: 1;
}
.auth-pwd-toggle:hover { color: var(--accent-light); background: rgba(108,92,231,0.15); }

/* Verify code row */
.auth-code-input-wrap { flex: 1; }
.auth-code-row {
  display: flex;
  gap: 10px;
  align-items: stretch;
}
.auth-code-row input {
  flex: 1;
}
.auth-code-btn {
  white-space: nowrap;
  background: rgba(108,92,231,0.15);
  border: 1px solid rgba(108,92,231,0.3);
  border-radius: 10px;
  color: var(--accent-light);
  padding: 9px 14px;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.25s;
  min-width: 88px;
  font-weight: 500;
}
.auth-code-btn:hover:not(:disabled) {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  box-shadow: 0 4px 12px rgba(108,92,231,0.3);
}
.auth-code-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* Inline error message */
.auth-error-msg {
  background: rgba(231,76,60,0.12);
  border: 1px solid rgba(231,76,60,0.3);
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 12px;
  color: #ff7b6b;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  animation: authShake 0.4s;
}
@keyframes authShake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-6px); }
  75% { transform: translateX(6px); }
}

/* Submit area */
.auth-actions { margin-top: 20px; }
.auth-submit-btn {
  flex: 1;
  background: linear-gradient(135deg, #6c5ce7, #a29bfe);
  border: none;
  border-radius: 10px;
  padding: 10px 20px;
  color: #fff;
  cursor: pointer;
  font-size: 15px;
  font-weight: 600;
  transition: all 0.25s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.auth-submit-btn:hover {
  box-shadow: 0 6px 20px rgba(108,92,231,0.4);
  transform: translateY(-1px);
}
.auth-submit-btn:active { transform: translateY(0); }
.auth-submit-btn.loading {
  pointer-events: none;
  opacity: 0.7;
}
.auth-submit-btn .auth-spinner {
  width: 16px; height: 16px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ===== Auth OAuth Section ===== */
.auth-oauth-section { margin-top: 18px; }
.auth-divider {
  display: flex;
  align-items: center;
  margin-bottom: 14px;
}
.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--glass-border);
}
.auth-divider span {
  padding: 0 12px;
  font-size: 12px;
  color: var(--text-secondary);
  white-space: nowrap;
}
.auth-oauth-btns {
  display: flex;
  gap: 14px;
  justify-content: center;
}
.oauth-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid var(--glass-border);
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s;
}
.oauth-btn.qq { background: #12b7f5; }
.oauth-btn.wechat { background: #07c160; }
.oauth-btn.weibo { background: #e6162d; }
.oauth-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 20px rgba(0,0,0,0.3);
}

/* ===== In-app Browser Modal ===== */
.browser-modal {
  position: fixed;
  inset: 0;
  z-index: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}
.browser-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
}
.browser-window {
  position: relative;
  width: 80%;
  max-width: 1500px;
  height: 80%;
  max-height: 1000px;
  background: #1a1a2e;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 30px 100px rgba(0,0,0,0.5);
  border: 1px solid rgba(255,255,255,0.08);
  display: flex;
  flex-direction: column;
  transition: all 0.3s ease;
}
.browser-window.browser-minimized {
  width: 500px;
  height: 375px;
}
.browser-window.browser-maximized {
  width: 100%;
  max-width: 100%;
  height: 100%;
  max-height: 100%;
  border-radius: 0;
}
.browser-titlebar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 15px;
  background: rgba(0,0,0,0.3);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  flex-shrink: 0;
}
.browser-tabs {
  display: flex;
  gap: 5px;
  flex-shrink: 0;
  max-width: 188px;
  overflow: hidden;
}
.browser-tab {
  font-size: 15px;
  color: rgba(255,255,255,0.6);
  padding: 5px 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 175px;
}
.browser-controls {
  display: flex;
  align-items: center;
  gap: 5px;
  flex: 1;
}
.browser-btn {
  width: 35px;
  height: 35px;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: rgba(255,255,255,0.5);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  flex-shrink: 0;
}
.browser-btn:hover {
  background: rgba(255,255,255,0.1);
  color: #fff;
}
.browser-btn-close:hover {
  background: #e6162d;
  color: #fff;
}
.browser-url-display {
  flex: 1;
  font-size: 15px;
  color: rgba(255,255,255,0.4);
  padding: 5px 13px;
  background: rgba(0,0,0,0.3);
  border-radius: 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin: 0 5px;
}
.browser-body {
  flex: 1;
  position: relative;
  overflow: hidden;
  background: #0d0d1a;
}
.browser-iframe {
  width: 100%;
  height: 100%;
  border: none;
  background: #fff;
}
.browser-blocked {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 15px;
  color: rgba(255,255,255,0.4);
  background: #0d0d1a;
}
.browser-blocked p { font-size: 18px; margin: 0; }
.browser-blocked-title { font-size: 20px !important; color: rgba(255,255,255,0.7); font-weight: 500; }
.browser-blocked-desc { font-size: 15px !important; color: rgba(255,255,255,0.35); max-width: 400px; text-align: center; line-height: 1.5; }
.browser-blocked-url { font-size: 15px !important; color: rgba(255,255,255,0.25); word-break: break-all; max-width: 450px; }
.browser-blocked-link {
  color: var(--accent, #6c5ce7);
  font-size: 16px;
  text-decoration: none;
  padding: 8px 20px;
  border: 1px solid var(--accent, #6c5ce7);
  border-radius: 8px;
  transition: all 0.2s;
}
.browser-blocked-link:hover {
  background: var(--accent, #6c5ce7);
  color: #fff;
}

/* ===== User Profile Modal ===== */
.profile-modal-content {
  max-width: 420px;
  max-height: 88vh;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  display: flex;
  flex-direction: column;
  padding: 0;
}
/* 吸顶头部：头像/用户名始终可见 */
.profile-sticky-header {
  position: sticky;
  top: 0;
  z-index: 3;
  flex-shrink: 0;
  padding: 20px 30px 16px;
  background: rgba(16,16,32,0.98);
  border-bottom: 1px solid rgba(255,255,255,0.08);
  border-radius: 20px 20px 0 0;
}
.profile-sticky-header h3 { margin-bottom: 16px; }
.profile-sticky-header .profile-display { margin-bottom: 0; }
.profile-scroll-body {
  padding: 20px 30px 26px;
}
/* 自定义右侧滚动条 */
.profile-modal-content::-webkit-scrollbar { width: 8px; }
.profile-modal-content::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.16); border-radius: 4px; }
.profile-modal-content::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.3); }
.profile-modal-content::-webkit-scrollbar-track { background: transparent; }
.profile-modal-content { scrollbar-width: thin; scrollbar-color: rgba(255,255,255,0.16) transparent; }
.profile-display {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  background: rgba(255,255,255,0.06);
  border-radius: 12px;
  margin-bottom: 20px;
}
.profile-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent, #6c5ce7), #a29bfe);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 25px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
  overflow: hidden;
}
.profile-avatar-wrapper {
  position: relative;
  width: 56px;
  height: 56px;
  flex-shrink: 0;
}
.profile-avatar-upload {
  position: absolute;
  bottom: -2px;
  right: -2px;
  width: 22px;
  height: 22px;
  background: var(--accent, #6c5ce7);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #fff;
  border: 2px solid rgba(20,20,35,0.8);
  transition: transform 0.2s, background 0.2s;
}
.profile-avatar-upload:hover {
  transform: scale(1.15);
  background: var(--accent-light, #a29bfe);
}
.profile-info {
  flex: 1;
  min-width: 0;
}
.profile-username {
  font-size: 19px;
  font-weight: 600;
  color: rgba(255,255,255,0.9);
  margin-bottom: 4px;
}
.profile-meta {
  font-size: 12px;
  color: rgba(255,255,255,0.4);
  line-height: 1.5;
}
.profile-section-title {
  font-size: 14px;
  font-weight: 600;
  color: rgba(255,255,255,0.7);
  margin: 20px 0 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.realname-status {
  padding: 12px 14px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  margin-bottom: 12px;
}

/* ===== E2EE 密聊加密密钥（个人中心） ===== */
.e2ee-key-box {
  padding: 12px 14px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  margin-bottom: 12px;
}
.e2ee-key-status {
  margin-bottom: 10px;
}
.e2ee-key-hint {
  font-size: 12px;
  color: rgba(255,255,255,0.45);
  line-height: 1.6;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed rgba(255,255,255,0.1);
}

/* ===== Auth Sub-Tabs (密码/手机验证码登录切换) ===== */
/* Sub-tabs: pill-style toggle group */
.auth-subtabs {
  display: flex;
  gap: 0;
  margin-bottom: 14px;
  background: rgba(255,255,255,0.06);
  border-radius: 9px;
  padding: 2px;
  border: 1px solid rgba(255,255,255,0.06);
}
.auth-subtab {
  flex: 1;
  text-align: center;
  padding: 6px 8px;
  font-size: 12px;
  font-weight: 500;
  color: rgba(255,255,255,0.45);
  cursor: pointer;
  transition: all 0.25s;
  border-radius: 7px;
  border-bottom: none;
  letter-spacing: 0.3px;
}
.auth-subtab.active {
  color: #fff;
  background: rgba(108,92,231,0.35);
  box-shadow: 0 2px 8px rgba(108,92,231,0.2);
}
.auth-subtab:hover:not(.active) {
  color: rgba(255,255,255,0.7);
  background: rgba(255,255,255,0.04);
}
.auth-verify-hint {
  font-size: 12px;
  color: rgba(255,255,255,0.45);
  margin: -8px 0 14px;
  padding: 9px 13px;
  background: rgba(108,92,231,0.08);
  border-radius: 8px;
  border-left: 3px solid var(--accent, #6c5ce7);
}

/* ===== Bookmark Drag & Drop ===== */
.bookmark-item.dragging {
  opacity: 0.4;
  cursor: grabbing !important;
}
.bookmark-item.drag-over {
  outline: 2px dashed var(--accent, #6c5ce7);
  outline-offset: 2px;
}
.bookmark-item.drag-over-folder {
  outline: 2px solid var(--accent, #6c5ce7);
  outline-offset: 2px;
  background: rgba(108,92,231,0.18);
  transform: scale(1.06);
  transition: transform .15s ease, background .15s ease;
}
.bookmark-item.drag-over-folder .folder-icon {
  transform: scale(1.1);
}

/* ===== Folder Items ===== */
.folder-item .folder-icon {
  display: flex;
  align-items: center;
  justify-content: center;
}
.folder-delete {
  position: absolute;
  top: -4px;
  right: -4px;
  width: 18px;
  height: 18px;
  background: rgba(231,76,60,0.9);
  color: #fff;
  border-radius: 50%;
  font-size: 12px;
  line-height: 18px;
  text-align: center;
  cursor: pointer;
  z-index: 5;
}
.bookmark-item.folder-item {
  position: relative;
}
.folder-bookmark {
  animation: folderExpand 0.2s ease;
}
@keyframes folderExpand {
  from { opacity: 0; transform: scale(0.8); }
  to { opacity: 0.8; transform: scale(0.9); }
}

/* ===== 文件夹图标框（双击文件夹弹出） ===== */
.folder-icons-content {
  background: rgba(20, 20, 40, 0.96);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 18px;
  width: 92%;
  max-width: 560px;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.folder-icons-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 22px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.folder-icons-header h3 { margin: 0; font-size: 17px; }
.folder-icons-close { cursor: pointer; font-size: 20px; color: rgba(255,255,255,0.5); }
.folder-icons-close:hover { color: #fff; }
.folder-icons-grid {
  padding: 20px 22px;
  overflow-y: auto;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(88px, 1fr));
  gap: 14px;
}
.folder-icon-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 12px 6px;
  border-radius: 12px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.06);
  transition: background .15s, transform .15s;
}
.folder-icon-card:hover { background: rgba(255,255,255,0.09); transform: translateY(-2px); }
.folder-icon-card-main {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  width: 100%;
}
.folder-icon-card .bookmark-icon {
  width: 48px; height: 48px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px; font-weight: 600;
  color: #fff;
}
.folder-icon-card .bookmark-icon img { width: 100%; height: 100%; object-fit: cover; border-radius: 12px; }
.folder-icon-card-name {
  font-size: 12px;
  color: rgba(255,255,255,0.85);
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: center;
}
.folder-icon-card-remove {
  position: absolute;
  top: -6px;
  right: -6px;
  width: 20px; height: 20px;
  background: rgba(231,76,60,0.9);
  color: #fff;
  border-radius: 50%;
  font-size: 13px;
  line-height: 20px;
  text-align: center;
  cursor: pointer;
  z-index: 5;
  display: none;
}
.folder-icon-card:hover .folder-icon-card-remove { display: block; }
.folder-icons-empty {
  grid-column: 1 / -1;
  text-align: center;
  color: rgba(255,255,255,0.4);
  font-size: 13px;
  padding: 30px 0;
}

/* ===== Message Bell Badge ===== */
.msg-badge {
  position: absolute;
  top: -2px;
  right: -2px;
  min-width: 16px;
  height: 16px;
  background: #e74c3c;
  color: #fff;
  font-size: 10px;
  line-height: 16px;
  text-align: center;
  border-radius: 8px;
  padding: 0 4px;
  font-weight: 600;
}
/* 左侧菜单消息中心入口 */
.sidebar-msg-entry {
  flex-shrink: 0;
  color: var(--text-secondary);
}
.sidebar-msg-entry:hover {
  background: var(--glass-bg-hover);
  color: var(--text-primary);
}
@media (max-width: 768px) {
  .sidebar-msg-entry {
    width: 48px; height: 56px;
    border-radius: 13px;
    display: flex; align-items: center; justify-content: center;
  }
  .sidebar-msg-entry svg { width: 22px; height: 22px; }
}

/* ===== Message Center ===== */
.message-modal-content {
  max-width: 550px;
  max-height: 80vh;
  overflow-y: auto;
}
.message-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
  max-height: 50vh;
  overflow-y: auto;
}
.message-item {
  padding: 12px 16px;
  background: rgba(255,255,255,0.03);
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.05);
  cursor: pointer;
  transition: background 0.2s;
}
.message-item:hover {
  background: rgba(255,255,255,0.06);
}
.message-item.unread {
  border-left: 3px solid var(--accent, #6c5ce7);
  background: rgba(108,92,231,0.08);
}
.message-item-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
}
.message-type {
  font-size: 12px;
  color: var(--accent-light, #a29bfe);
}
.message-time {
  font-size: 11px;
  color: rgba(255,255,255,0.3);
}
.message-title {
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 4px;
}
.message-content {
  font-size: 13px;
  color: rgba(255,255,255,0.5);
  line-height: 1.5;
}

/* ===== Topics Plaza ===== */
.topics-modal-content {
  max-width: 600px;
  max-height: 85vh;
  overflow-y: auto;
}
.topics-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.topic-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: rgba(255,255,255,0.03);
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.05);
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
}
.topic-item:hover {
  background: rgba(255,255,255,0.06);
  transform: translateY(-2px);
}
.topic-icon {
  font-size: 28px;
}
.topic-info {
  flex: 1;
}
.topic-name {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 2px;
}
.topic-desc {
  font-size: 12px;
  color: rgba(255,255,255,0.4);
  margin-bottom: 4px;
}
.topic-meta {
  font-size: 11px;
  color: rgba(255,255,255,0.3);
}
.topics-back {
  font-size: 13px;
  color: var(--accent-light, #a29bfe);
  cursor: pointer;
  margin-bottom: 12px;
}
.topics-back:hover {
  text-decoration: underline;
}
.topic-posts-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
  max-height: 40vh;
  overflow-y: auto;
}
.topic-post-item {
  padding: 12px 16px;
  background: rgba(255,255,255,0.03);
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.05);
}
.post-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}
.post-author {
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-light, #a29bfe);
}
.post-time {
  font-size: 11px;
  color: rgba(255,255,255,0.3);
}
.post-emoji {
  font-size: 20px;
}
.post-content {
  font-size: 14px;
  color: rgba(255,255,255,0.7);
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-word;
}
.post-image {
  max-width: 100%;
  border-radius: 8px;
  margin-top: 8px;
}

/* Topic post image upload */
.topic-image-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}
.topic-image-thumb {
  position: relative;
  width: 72px;
  height: 72px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.12);
}
.topic-image-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.topic-image-remove {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 20px;
  height: 20px;
  background: rgba(0,0,0,0.65);
  border-radius: 50%;
  color: #ff4757;
  font-size: 13px;
  line-height: 20px;
  text-align: center;
  cursor: pointer;
}
.topic-image-add-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 16px;
  background: rgba(255,255,255,0.06);
  border: 1px dashed rgba(255,255,255,0.25);
  border-radius: 8px;
  color: rgba(255,255,255,0.6);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
}
.topic-image-add-btn:hover {
  border-color: var(--accent-light, #a29bfe);
  color: #fff;
  background: rgba(255,255,255,0.12);
}

/* ===== Notebook ===== */
.notebook-modal-content {
  max-width: 650px;
  max-height: 85vh;
  overflow-y: auto;
}
.notebook-tabs {
  display: flex;
  gap: 0;
  margin-bottom: 16px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.notebook-tab {
  flex: 1;
  text-align: center;
  padding: 10px;
  font-size: 14px;
  color: rgba(255,255,255,0.4);
  cursor: pointer;
  transition: color 0.2s;
  border-bottom: 2px solid transparent;
}
.notebook-tab.active {
  color: var(--accent-light, #a29bfe);
  border-bottom-color: var(--accent, #6c5ce7);
}
.notebook-tab:hover {
  color: rgba(255,255,255,0.7);
}
.notebook-panel {
  min-height: 300px;
}
.notes-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 50vh;
  overflow-y: auto;
}
.note-item {
  padding: 12px 16px;
  background: rgba(255,255,255,0.03);
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.05);
  cursor: pointer;
  transition: background 0.2s;
}
.note-item:hover {
  background: rgba(255,255,255,0.06);
}
.note-title {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 4px;
}
.note-preview-text {
  font-size: 12px;
  color: rgba(255,255,255,0.4);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.note-time {
  font-size: 11px;
  color: rgba(255,255,255,0.25);
}
.note-preview {
  padding: 16px;
  background: rgba(255,255,255,0.03);
  border-radius: 8px;
  font-size: 14px;
  line-height: 1.7;
  color: rgba(255,255,255,0.7);
  min-height: 200px;
}
.note-preview h1, .note-preview h2, .note-preview h3 {
  margin: 12px 0 8px;
  color: #fff;
}
.note-preview code {
  background: rgba(255,255,255,0.08);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 13px;
}
.note-preview pre {
  background: rgba(0,0,0,0.3);
  padding: 12px;
  border-radius: 8px;
  overflow-x: auto;
}
.note-preview blockquote {
  border-left: 3px solid var(--accent, #6c5ce7);
  padding-left: 12px;
  color: rgba(255,255,255,0.5);
  margin: 8px 0;
}

/* ===== Time Capsules ===== */
.capsule-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 50vh;
  overflow-y: auto;
}
.capsule-item {
  padding: 14px 16px;
  background: rgba(255,255,255,0.03);
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.05);
}
.capsule-item.open {
  border-color: rgba(46,213,115,0.3);
  background: rgba(46,213,115,0.05);
}
.capsule-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}
.capsule-icon {
  font-size: 24px;
}
.capsule-title {
  font-size: 15px;
  font-weight: 600;
}
.capsule-date {
  font-size: 12px;
  color: rgba(255,255,255,0.3);
  margin-bottom: 6px;
}
.capsule-content {
  font-size: 14px;
  color: rgba(255,255,255,0.7);
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-word;
  padding: 12px;
  background: rgba(255,255,255,0.03);
  border-radius: 8px;
  margin-top: 8px;
}
.capsule-locked {
  font-size: 13px;
  color: rgba(255,255,255,0.3);
  padding: 12px;
  text-align: center;
  background: rgba(0,0,0,0.15);
  border-radius: 8px;
}
.capsule-actions {
  margin-top: 8px;
  text-align: right;
}
.capsule-delete {
  font-size: 12px;
  color: #e74c3c;
  cursor: pointer;
  opacity: 0.6;
}
.capsule-delete:hover {
  opacity: 1;
}

/* ===== Dynamic Island (底部固定灵动岛) ===== */
.dynamic-island {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 800;
  max-width: calc(100vw - 40px);
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}
/* Folded (collapsed) state — mobile only */
.dynamic-island.folded {
  left: auto;
  right: 16px;
  transform: none;
}
.dynamic-island.folded .island-inner {
  padding: 6px 14px;
}
.dynamic-island.folded .island-item,
.dynamic-island.folded .island-settings,
.dynamic-island.folded .island-empty {
  display: none;
}
.dynamic-island.folded .island-toggle {
  display: flex;
}
.island-toggle {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: rgba(255,255,255,0.5);
  transition: color 0.2s;
  gap: 2px;
  flex-shrink: 0;
  padding: 2px 4px;
}
.island-toggle:hover { color: rgba(255,255,255,0.85); }
.island-toggle svg { width: 16px; height: 16px; transition: transform 0.3s; }
.island-toggle-label { font-size: 9px; color: rgba(255,255,255,0.4); }
.island-inner {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: rgba(15,15,30,0.55);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-radius: 28px;
  border: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 8px 32px rgba(0,0,0,0.35), inset 0 1px 0 rgba(255,255,255,0.06);
  overflow-x: auto;
  scrollbar-width: none;
  max-width: 100%;
  transition: all 0.3s ease;
}
.island-inner::-webkit-scrollbar { display: none; }
.island-item {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  cursor: pointer;
  transition: transform 0.2s, background 0.2s;
  text-decoration: none;
  position: relative;
  overflow: hidden;
}
.island-item:hover {
  transform: translateY(-3px) scale(1.08);
  background: rgba(255,255,255,0.08);
}
.island-item-icon {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  overflow: hidden;
}
.island-item-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.island-item-label {
  font-size: 9px;
  color: rgba(255,255,255,0.5);
  margin-top: 2px;
  max-width: 44px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: center;
}
.island-empty {
  font-size: 12px;
  color: rgba(255,255,255,0.3);
  padding: 8px 6px;
  white-space: nowrap;
}
.island-settings {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: rgba(255,255,255,0.4);
  transition: color 0.2s, background 0.2s;
  margin-left: 4px;
}
.island-settings:hover {
  color: rgba(255,255,255,0.8);
  background: rgba(255,255,255,0.08);
}

@media (max-width: 768px) {
  .dynamic-island {
    bottom: 92px;
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  }
  /* Folded: right-aligned compact pill */
  .dynamic-island.folded {
    left: auto;
    right: 14px;
    transform: none;
  }
  .dynamic-island.folded .island-inner {
    padding: 0;
    border-radius: 22px;
    background: transparent;
    border: none;
    box-shadow: none;
  }
  .dynamic-island.folded .island-toggle {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 4px;
    padding: 6px 12px 6px 10px;
    border-radius: 22px;
    background: rgba(16,16,32,0.88);
    border: 1px solid rgba(108,92,231,0.25);
    box-shadow: 0 4px 16px rgba(0,0,0,0.4), 0 0 10px rgba(108,92,231,0.08);
    color: rgba(255,255,255,0.7);
    transition: all 0.25s ease;
  }
  .dynamic-island.folded .island-toggle:active {
    transform: scale(0.93);
    background: rgba(108,92,231,0.2);
  }
  .dynamic-island.folded .island-toggle svg {
    transform: rotate(180deg);
    width: 14px;
    height: 14px;
  }
  .dynamic-island.folded .island-toggle-label {
    font-size: 11px;
    color: rgba(255,255,255,0.6);
    line-height: 1;
  }
  /* Default folded on mobile */
  .dynamic-island:not(.unfolded) .island-item,
  .dynamic-island:not(.unfolded) .island-settings,
  .dynamic-island:not(.unfolded) .island-empty {
    display: none;
  }
  .dynamic-island:not(.unfolded) .island-toggle {
    display: flex;
  }
  .island-toggle {
    display: flex;
  }
  .dynamic-island.folded .island-toggle {
    display: flex;
  }
  /* Expanded state */
  .dynamic-island.unfolded .island-inner {
    background: rgba(15,15,30,0.75);
    border: 1px solid rgba(255,255,255,0.1);
    box-shadow: 0 6px 24px rgba(0,0,0,0.4), 0 0 16px rgba(108,92,231,0.06);
    max-width: calc(100vw - 28px);
    justify-content: flex-start;
    padding: 4px 6px 4px 8px;
    gap: 2px;
  }
  /* Divider between bookmarks and toggle */
  .dynamic-island.unfolded .island-toggle {
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 0;
    padding: 5px 8px;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(108,92,231,0.18), rgba(108,92,231,0.08));
    border: 1px solid rgba(108,92,231,0.22);
    color: rgba(255,255,255,0.75);
    flex-shrink: 0;
    margin-left: 10px;
    position: relative;
  }
  .dynamic-island.unfolded .island-toggle::before {
    content: '';
    position: absolute;
    left: -12px;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 20px;
    background: rgba(255,255,255,0.12);
    border-radius: 1px;
  }
  .dynamic-island.unfolded .island-toggle:active {
    transform: scale(0.92);
    background: linear-gradient(135deg, rgba(108,92,231,0.3), rgba(108,92,231,0.15));
  }
  .dynamic-island.unfolded .island-toggle svg {
    width: 14px;
    height: 14px;
    color: var(--accent-light, #a29bfe);
  }
  .dynamic-island.unfolded .island-toggle-label {
    display: none;
  }
  .island-inner {
    gap: 3px;
    padding: 5px 8px;
  }
  .island-item {
    width: 42px;
    height: 42px;
    border-radius: 12px;
  }
  .island-item:active {
    transform: scale(0.9);
    background: rgba(255,255,255,0.08);
  }
  .island-item-icon {
    width: 26px;
    height: 26px;
    font-size: 13px;
    border-radius: 8px;
  }
  .island-item-label {
    display: none;
  }
  .island-settings {
    width: 28px;
    height: 28px;
  }
  .island-settings svg {
    width: 12px;
    height: 12px;
  }
}
@media (max-width: 480px) {
  .dynamic-island {
    bottom: 78px;
  }
  .dynamic-island.folded {
    right: 10px;
  }
  .island-inner {
    padding: 4px 6px;
  }
  .island-item {
    width: 38px;
    height: 38px;
  }
  .island-item-icon {
    width: 24px;
    height: 24px;
    font-size: 12px;
  }
}

/* ===== LRC Lyric Editor ===== */
.widget-lrc {
  background: linear-gradient(135deg, rgba(253,121,168,0.12), rgba(108,92,231,0.05));
  border-color: rgba(253,121,168,0.2);
}
.widget-lrc:hover {
  background: linear-gradient(135deg, rgba(253,121,168,0.2), rgba(108,92,231,0.1));
  border-color: rgba(253,121,168,0.35);
}
.lrc-body { font-size: 14px; color: var(--text-secondary); line-height: 1.5; display: flex; align-items: center; gap: 8px; }
.lrc-sparkle { font-size: 20px; }

.lrc-editor-modal .modal-content { max-width: none; width: 96%; max-height: 92vh; padding: 0; overflow: hidden; }
.lrc-editor-content {
  background: rgba(15,15,30,0.95);
  backdrop-filter: blur(30px) saturate(180%);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: var(--radius-lg);
  display: flex; flex-direction: column;
}
.lrc-editor-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 20px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  flex-shrink: 0;
}
.lrc-editor-header h3 { font-size: 16px; font-weight: 700; color: #fff; }
.lrc-editor-close {
  background: none; border: none; color: rgba(255,255,255,0.5);
  cursor: pointer; padding: 4px; border-radius: 8px; transition: all 0.2s;
  display: flex; align-items: center;
}
.lrc-editor-close:hover { color: #fff; background: rgba(255,255,255,0.1); }
.lrc-editor-body {
  display: grid; grid-template-columns: 1fr 360px; gap: 16px;
  padding: 16px; overflow: hidden; flex: 1; min-height: 0;
}
.lrc-left-panel { display: flex; flex-direction: column; gap: 12px; overflow: hidden; min-height: 0; }
.lrc-right-panel {
  display: flex; flex-direction: column; gap: 10px; overflow: hidden;
  background: rgba(255,255,255,0.03); border-radius: 12px; padding: 14px;
  border: 1px solid rgba(255,255,255,0.05);
}

/* Audio Section */
.lrc-audio-section {
  background: rgba(255,255,255,0.03); border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.05); overflow: hidden; flex-shrink: 0;
}
.lrc-audio-upload {
  padding: 28px; text-align: center; cursor: pointer; transition: all 0.2s;
  border: 2px dashed transparent;
}
.lrc-audio-upload:hover { background: rgba(255,255,255,0.03); }
.lrc-audio-upload.dragover { border-color: var(--accent); background: rgba(108,92,231,0.08); }
.lrc-upload-placeholder { display: flex; flex-direction: column; align-items: center; gap: 6px; color: rgba(255,255,255,0.4); }
.lrc-upload-placeholder svg { color: var(--accent-light); }
.lrc-upload-placeholder p { font-size: 14px; font-weight: 500; }
.lrc-upload-hint { font-size: 12px !important; color: rgba(255,255,255,0.3) !important; font-weight: 400 !important; }
.lrc-audio-player { padding: 14px 18px; }
.lrc-player-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.lrc-track-info { display: flex; align-items: center; gap: 8px; min-width: 0; }
.lrc-track-icon { color: var(--accent-light); flex-shrink: 0; }
.lrc-track-name { font-size: 13px; font-weight: 600; color: rgba(255,255,255,0.85); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lrc-icon-btn { background: none; border: none; color: rgba(255,255,255,0.4); cursor: pointer; padding: 6px; border-radius: 6px; transition: all 0.2s; display: flex; }
.lrc-icon-btn:hover { color: var(--accent-light); background: rgba(255,255,255,0.08); }
.lrc-player-controls { display: flex; align-items: center; gap: 10px; }
.lrc-play-btn {
  width: 40px; height: 40px; border-radius: 50%; border: none;
  background: var(--accent); color: #fff; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; transition: all 0.2s;
}
.lrc-play-btn:hover { background: var(--accent-light); transform: scale(1.05); }
.lrc-play-btn:active { transform: scale(0.95); }
.lrc-time-display { font-size: 12px; font-family: "SF Mono","Courier New",monospace; color: rgba(255,255,255,0.4); min-width: 56px; text-align: center; flex-shrink: 0; }
.lrc-progress-bar { flex: 1; height: 5px; background: rgba(255,255,255,0.1); border-radius: 3px; position: relative; cursor: pointer; min-width: 80px; }
.lrc-progress-fill { height: 100%; background: linear-gradient(90deg, var(--accent), var(--accent-light)); border-radius: 3px; width: 0%; transition: width 0.1s linear; }
.lrc-progress-thumb { position: absolute; top: 50%; transform: translate(-50%, -50%); width: 12px; height: 12px; background: #fff; border: 2px solid var(--accent); border-radius: 50%; left: 0%; transition: left 0.1s linear; box-shadow: 0 1px 4px rgba(0,0,0,0.3); }

/* Toolbar */
.lrc-toolbar {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  background: rgba(255,255,255,0.03); border-radius: 10px; padding: 10px 14px;
  border: 1px solid rgba(255,255,255,0.05); flex-shrink: 0;
}
.lrc-toolbar-group { display: flex; align-items: center; gap: 6px; }
.lrc-toolbar-label { font-size: 12px; color: rgba(255,255,255,0.4); white-space: nowrap; }
.lrc-offset-input { width: 64px; padding: 5px 7px; border: 1px solid rgba(255,255,255,0.1); border-radius: 6px; font-size: 12px; font-family: monospace; text-align: center; background: rgba(0,0,0,0.2); color: #fff; }
.lrc-offset-input:focus { outline: none; border-color: var(--accent); }
.lrc-toolbar-btn { padding: 6px 12px; border: 1px solid rgba(255,255,255,0.1); border-radius: 6px; background: rgba(255,255,255,0.05); color: rgba(255,255,255,0.7); font-size: 12px; cursor: pointer; transition: all 0.2s; display: flex; align-items: center; gap: 5px; white-space: nowrap; }
.lrc-toolbar-btn:hover { border-color: var(--accent); color: var(--accent-light); }
.lrc-toolbar-btn-accent { background: var(--accent); color: #fff; border-color: var(--accent); font-weight: 600; }
.lrc-toolbar-btn-accent:hover { background: #e8588f; color: #fff; border-color: #e8588f; }
.lrc-toolbar-btn-accent:active { transform: scale(0.95); }
.lrc-toolbar-btn-warning { background: var(--warning, #fdcb6e); color: #5a4500; border-color: var(--warning, #fdcb6e); font-weight: 600; }
.lrc-toolbar-btn-warning:hover { background: #f0b836; color: #5a4500; border-color: #f0b836; }
.lrc-shortcut-hint { font-size: 11px; color: rgba(255,255,255,0.3); }
.lrc-shortcut-hint kbd { display: inline-block; padding: 2px 5px; border: 1px solid rgba(255,255,255,0.1); border-radius: 4px; font-size: 10px; font-family: monospace; background: rgba(255,255,255,0.05); margin: 0 2px; }

/* Lyric List */
.lrc-list-container {
  background: rgba(255,255,255,0.03); border-radius: 12px; flex: 1;
  display: flex; flex-direction: column; overflow: hidden; min-height: 200px;
  border: 1px solid rgba(255,255,255,0.05);
}
.lrc-list-header { display: grid; grid-template-columns: 90px 1fr 100px; padding: 9px 14px; background: rgba(0,0,0,0.2); border-bottom: 1px solid rgba(255,255,255,0.05); font-size: 11px; font-weight: 600; color: rgba(255,255,255,0.3); text-transform: uppercase; letter-spacing: 0.5px; }
.lrc-list { flex: 1; overflow-y: auto; min-height: 180px; }
.lrc-list::-webkit-scrollbar { width: 5px; }
.lrc-list::-webkit-scrollbar-track { background: transparent; }
.lrc-list::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 3px; }
.lrc-item { display: grid; grid-template-columns: 90px 1fr 100px; align-items: center; padding: 7px 14px; border-bottom: 1px solid rgba(255,255,255,0.03); transition: all 0.2s; cursor: pointer; }
.lrc-item:hover { background: rgba(255,255,255,0.03); }
.lrc-item.active { background: rgba(108,92,231,0.1); }
.lrc-item.active .lyric-time-lrc { color: var(--accent-light); font-weight: 700; }
.lyric-time-lrc { font-family: "SF Mono","Courier New",monospace; font-size: 12px; color: rgba(255,255,255,0.4); cursor: pointer; padding: 2px 4px; border-radius: 4px; }
.lyric-time-lrc:hover { background: rgba(108,92,231,0.15); color: var(--accent-light); }
.lyric-time-input-lrc { font-family: monospace; font-size: 12px; border: 1px solid var(--accent); border-radius: 4px; padding: 2px 4px; width: 80px; outline: none; background: rgba(0,0,0,0.3); color: #fff; }
.lyric-text-lrc { font-size: 13px; padding: 4px 8px; border-radius: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: rgba(255,255,255,0.7); }
.lyric-text-input-lrc { width: 100%; font-size: 13px; border: 1px solid var(--accent); border-radius: 4px; padding: 4px 8px; outline: none; background: rgba(0,0,0,0.3); color: #fff; }
.lyric-actions-lrc { display: flex; gap: 3px; justify-content: flex-end; }
.lyric-action-btn { background: none; border: none; color: rgba(255,255,255,0.25); cursor: pointer; padding: 4px 5px; border-radius: 4px; transition: all 0.2s; display: flex; }
.lyric-action-btn:hover { background: rgba(255,255,255,0.08); color: var(--accent-light); }
.lyric-action-btn.danger:hover { color: #e74c3c; }
.lyric-action-btn.jump:hover { color: #00b894; }
.lrc-list-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 36px; text-align: center; color: rgba(255,255,255,0.25); }
.lrc-list-empty p { font-size: 14px; }
.lrc-empty-hint { font-size: 12px !important; margin-top: 4px; }

/* Right Panel */
.lrc-editor-section-header { display: flex; align-items: center; justify-content: space-between; flex-shrink: 0; }
.lrc-editor-section-header h4 { font-size: 14px; font-weight: 700; color: rgba(255,255,255,0.8); }
.lrc-editor-actions { display: flex; gap: 6px; }
.lrc-editor-btn { display: flex; align-items: center; gap: 4px; padding: 5px 10px; border: 1px solid rgba(255,255,255,0.1); border-radius: 6px; background: rgba(255,255,255,0.05); color: rgba(255,255,255,0.6); font-size: 11px; cursor: pointer; transition: all 0.2s; }
.lrc-editor-btn:hover { border-color: var(--accent); color: var(--accent-light); }
.lrc-editor-btn-accent { background: var(--accent); color: #fff; border-color: var(--accent); }
.lrc-editor-btn-accent:hover { background: var(--accent-light); color: #fff; }
.lrc-meta { display: flex; flex-direction: column; gap: 6px; flex-shrink: 0; }
.lrc-meta-row { display: flex; align-items: center; gap: 8px; }
.lrc-meta-row label { font-size: 11px; color: rgba(255,255,255,0.35); white-space: nowrap; width: 48px; text-align: justify; text-align-last: justify; flex-shrink: 0; }
.lrc-meta-input { flex: 1; padding: 5px 8px; border: 1px solid rgba(255,255,255,0.08); border-radius: 6px; font-size: 12px; min-width: 0; background: rgba(0,0,0,0.2); color: #fff; }
.lrc-meta-input:focus { outline: none; border-color: var(--accent); }
.lrc-lyric-textarea { flex: 1; min-height: 120px; padding: 10px; border: 1px solid rgba(255,255,255,0.08); border-radius: 8px; font-size: 13px; font-family: inherit; line-height: 1.7; resize: none; color: rgba(255,255,255,0.8); background: rgba(0,0,0,0.2); transition: all 0.2s; }
.lrc-lyric-textarea:focus { outline: none; border-color: var(--accent); background: rgba(0,0,0,0.3); }
.lrc-preview-section { border-top: 1px solid rgba(255,255,255,0.05); padding-top: 10px; display: flex; flex-direction: column; gap: 6px; flex-shrink: 0; max-height: 220px; }
.lrc-preview-header { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 6px; }
.lrc-preview-header h4 { font-size: 12px; font-weight: 600; color: rgba(255,255,255,0.5); }
.lrc-preview-actions { display: flex; gap: 4px; flex-wrap: wrap; }
.lrc-preview-btn { display: flex; align-items: center; gap: 3px; background: none; border: 1px solid rgba(255,255,255,0.1); border-radius: 5px; padding: 3px 8px; font-size: 11px; color: rgba(255,255,255,0.4); cursor: pointer; transition: all 0.2s; }
.lrc-preview-btn:hover { border-color: var(--accent); color: var(--accent-light); }
.lrc-preview-btn-primary { background: var(--accent); color: #fff; border-color: var(--accent); }
.lrc-preview-btn-primary:hover { background: var(--accent-light); color: #fff; }
.lrc-preview-btn-danger { color: #e74c3c; border-color: rgba(231,76,60,0.3); }
.lrc-preview-btn-danger:hover { background: rgba(231,76,60,0.1); color: #e74c3c; border-color: #e74c3c; }
.lrc-preview-btn-success { color: #00b894; border-color: rgba(0,184,148,0.3); }
.lrc-preview-btn-success:hover { background: rgba(0,184,148,0.1); color: #00b894; border-color: #00b894; }
.lrc-preview { flex: 1; overflow: auto; padding: 9px 12px; background: rgba(0,0,0,0.4); color: #cdd6f4; border-radius: 8px; font-family: "SF Mono","Courier New",monospace; font-size: 11px; line-height: 1.7; white-space: pre-wrap; word-break: break-all; min-height: 60px; max-height: 160px; }
.lrc-preview::-webkit-scrollbar { width: 5px; }
.lrc-preview::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.15); border-radius: 3px; }

/* LRC Editor Responsive */
@media (max-width: 1024px) {
  .lrc-editor-body { grid-template-columns: 1fr; }
  .lrc-right-panel { max-height: none; }
}
@media (max-width: 768px) {
  .lrc-editor-modal .modal-content { width: 100%; max-height: 100vh; border-radius: 0; }
  .lrc-editor-body { padding: 10px; gap: 10px; }
  .lrc-toolbar { flex-direction: column; align-items: stretch; }
  .lrc-list-header, .lrc-item { grid-template-columns: 75px 1fr 80px; }
  .lrc-audio-upload { padding: 20px; }
  .lrc-preview-actions { flex-wrap: wrap; }
}

/* ===== TaskBoard Widget Card ===== */
.widget-tasks {
  background: linear-gradient(135deg, rgba(0,184,148,0.15), rgba(108,92,231,0.15));
  border-color: rgba(0,184,148,0.2);
}
.widget-tasks:hover { border-color: rgba(0,184,148,0.4); }
.tasks-body { font-size: 14px; color: rgba(255,255,255,0.6); line-height: 1.6; display: flex; align-items: center; gap: 8px; }
.tasks-icon { font-size: 20px; }

/* ===== TaskBoard Modal ===== */
.tb-modal { z-index: 10000; }
.tb-modal .modal-overlay { z-index: 0; }
.tb-container {
  position: relative; z-index: 1;
  background: rgba(20,20,35,0.95); backdrop-filter: blur(var(--glass-blur, 20px));
  border: 1px solid rgba(255,255,255,0.08); border-radius: 16px;
  width: 95%; max-width: 1200px; max-height: 90vh; margin: auto;
  display: flex; flex-direction: column; overflow: hidden;
}
.tb-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px; border-bottom: 1px solid rgba(255,255,255,0.06); flex-shrink: 0;
}
.tb-header-left { display: flex; align-items: center; gap: 10px; }
.tb-title { font-size: 18px; font-weight: 700; color: #fff; margin: 0; }
.tb-count { font-size: 13px; color: rgba(255,255,255,0.4); }
.tb-header-right { display: flex; align-items: center; gap: 8px; }
.tb-btn {
  padding: 7px 14px; border: none; border-radius: 8px; font-size: 13px;
  cursor: pointer; transition: all .2s; font-weight: 500; white-space: nowrap;
}
.tb-btn-primary { background: var(--accent, #6c5ce7); color: #fff; }
.tb-btn-primary:hover { opacity: .85; }
.tb-btn-ghost { background: rgba(255,255,255,0.06); color: rgba(255,255,255,0.7); border: 1px solid rgba(255,255,255,0.08); }
.tb-btn-ghost:hover { background: rgba(255,255,255,0.1); }
.tb-btn-close { background: transparent; color: rgba(255,255,255,0.4); font-size: 16px; padding: 7px 10px; }
.tb-btn-close:hover { color: #fff; }

.tb-stats { display: grid; grid-template-columns: repeat(4,1fr); gap: 10px; padding: 12px 20px; }
.tb-stat-item { background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.06); border-radius: 10px; padding: 10px 14px; display: flex; align-items: center; gap: 10px; }
.tb-stat-num { font-size: 18px; font-weight: 700; }
.tb-stat-label { font-size: 11px; color: rgba(255,255,255,0.4); }
.tb-stat-blue .tb-stat-num { color: #4facfe; }
.tb-stat-amber .tb-stat-num { color: #ffa726; }
.tb-stat-purple .tb-stat-num { color: #a29bfe; }
.tb-stat-green .tb-stat-num { color: #2ed573; }

.tb-tabbar { display: none; }

.tb-board {
  flex: 1; overflow-y: auto; padding: 16px 20px;
  display: grid; grid-template-columns: repeat(4,1fr); gap: 14px;
}
.tb-col { display: flex; flex-direction: column; }
.tb-col-header { font-size: 13px; font-weight: 600; color: rgba(255,255,255,0.6); margin-bottom: 10px; display: flex; align-items: center; gap: 6px; }
.tb-dot { width: 8px; height: 8px; border-radius: 50%; }
.tb-dot-blue { background: #4facfe; } .tb-dot-amber { background: #ffa726; }
.tb-dot-purple { background: #a29bfe; } .tb-dot-green { background: #2ed573; }
.tb-col-count { font-size: 11px; color: rgba(255,255,255,0.3); }
.tb-col-body { display: flex; flex-direction: column; gap: 10px; min-height: 100px; }

.tb-card {
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.06);
  border-radius: 10px; padding: 12px; cursor: pointer; transition: all .2s;
  border-left-width: 3px;
}
.tb-card:hover { background: rgba(255,255,255,0.07); transform: translateY(-1px); }
.tb-card-pri-urgent { border-left-color: #ef4444; }
.tb-card-pri-high { border-left-color: #f97316; }
.tb-card-pri-medium { border-left-color: #eab308; }
.tb-card-pri-low { border-left-color: #22c55e; }
.tb-card-title { font-size: 13px; font-weight: 500; color: #fff; line-height: 1.4; flex: 1; }
.tb-card-top { display: flex; align-items: flex-start; gap: 8px; }
.tb-pri-badge { font-size: 10px; padding: 2px 6px; border-radius: 4px; font-weight: 600; white-space: nowrap; }
.tb-pri-urgent { background: rgba(239,68,68,0.15); color: #ef4444; }
.tb-pri-high { background: rgba(249,115,22,0.15); color: #f97316; }
.tb-pri-medium { background: rgba(234,179,8,0.15); color: #eab308; }
.tb-pri-low { background: rgba(34,197,94,0.15); color: #22c55e; }
.tb-card-desc { font-size: 12px; color: rgba(255,255,255,0.4); margin-top: 6px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tb-card-deadline { font-size: 11px; color: rgba(255,255,255,0.3); margin-top: 6px; }
.tb-card-deadline.overdue { color: #ef4444; font-weight: 600; }
.tb-card-claims { font-size: 11px; color: rgba(255,255,255,0.3); margin-top: 4px; }
.tb-bar-wrap { height: 4px; background: rgba(255,255,255,0.06); border-radius: 2px; margin-top: 8px; }
.tb-bar-fill { height: 100%; border-radius: 2px; transition: width .5s; }
.tb-card-footer { display: flex; align-items: center; justify-content: space-between; margin-top: 8px; }
.tb-card-time { font-size: 11px; color: rgba(255,255,255,0.25); }
.tb-card-myclaim { font-size: 11px; color: var(--accent, #6c5ce7); font-weight: 600; }
.tb-card-actions { display: flex; gap: 6px; margin-top: 10px; }
.tb-card-btn {
  flex: 1; padding: 5px 8px; border: none; border-radius: 6px; font-size: 11px;
  cursor: pointer; transition: all .15s; font-weight: 500;
}
.tb-card-btn-claim { background: rgba(108,92,231,0.15); color: #a29bfe; }
.tb-card-btn-claim:hover { background: rgba(108,92,231,0.3); }
.tb-card-btn-progress { background: rgba(162,155,254,0.15); color: #a29bfe; }
.tb-card-btn-progress:hover { background: rgba(162,155,254,0.3); }
.tb-card-btn-edit { background: rgba(255,255,255,0.06); color: rgba(255,255,255,0.5); flex: 0 0 auto; width: 30px; }
.tb-card-btn-edit:hover { background: rgba(255,255,255,0.1); }
.tb-card-btn-delete { background: rgba(239,68,68,0.1); color: #ef4444; flex: 0 0 auto; width: 30px; }
.tb-card-btn-delete:hover { background: rgba(239,68,68,0.2); }
.tb-empty { text-align: center; padding: 40px 20px; color: rgba(255,255,255,0.2); font-size: 13px; }

/* Sub modals */
.tb-sub-modal { z-index: 10001; }
.tb-sub-modal .modal-overlay { z-index: 0; }
.tb-sub-content {
  position: relative; z-index: 1;
  background: rgba(25,25,40,0.98); backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.1); border-radius: 14px;
  width: 95%; max-width: 480px; max-height: 90vh; margin: auto;
  display: flex; flex-direction: column; overflow: hidden;
}
.tb-detail-content { max-width: 580px; }
.tb-sub-header { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid rgba(255,255,255,0.06); }
.tb-sub-header h3 { font-size: 16px; font-weight: 600; color: #fff; margin: 0; }
.tb-sub-close { color: rgba(255,255,255,0.4); cursor: pointer; font-size: 16px; }
.tb-sub-close:hover { color: #fff; }
.tb-sub-body { padding: 20px; overflow-y: auto; flex: 1; }
.tb-sub-footer { display: flex; justify-content: flex-end; gap: 10px; padding: 16px 20px; border-top: 1px solid rgba(255,255,255,0.06); }

.tb-field { margin-bottom: 14px; }
.tb-field label { display: block; font-size: 13px; color: rgba(255,255,255,0.6); margin-bottom: 5px; font-weight: 500; }
.tb-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.tb-input {
  width: 100%; padding: 10px 12px; background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1); border-radius: 8px;
  color: #fff; font-size: 14px; outline: none; transition: border .2s;
  font-family: inherit; box-sizing: border-box;
}
.tb-input:focus { border-color: var(--accent, #6c5ce7); }
.tb-input option { background: #1a1a2e; }
.tb-hint { font-size: 11px; color: rgba(255,255,255,0.3); margin-top: 4px; }
.tb-mono { font-family: monospace; font-size: 12px; }
.tb-range { width: 100%; accent-color: var(--accent, #6c5ce7); }

.tb-detail-meta { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.tb-badge { font-size: 11px; padding: 3px 8px; border-radius: 6px; font-weight: 500; }
.tb-badge-status { background: rgba(255,255,255,0.08); color: rgba(255,255,255,0.6); }
.tb-detail-desc { font-size: 13px; color: rgba(255,255,255,0.6); margin-bottom: 14px; line-height: 1.6; white-space: pre-wrap; }
.tb-detail-section { margin-bottom: 16px; }
.tb-detail-section h4 { font-size: 13px; font-weight: 600; color: rgba(255,255,255,0.7); margin: 0 0 8px 0; }
.tb-progress-item { border-left: 2px solid rgba(108,92,231,0.3); padding-left: 10px; padding-bottom: 8px; }
.tb-progress-meta { font-size: 11px; color: rgba(255,255,255,0.3); margin-bottom: 3px; display: flex; gap: 8px; align-items: center; }
.tb-progress-pct { padding: 1px 5px; border-radius: 3px; background: rgba(108,92,231,0.15); color: #a29bfe; }
.tb-progress-content { font-size: 13px; color: rgba(255,255,255,0.7); }
.tb-claim-row { display: flex; align-items: center; gap: 6px; font-size: 13px; color: rgba(255,255,255,0.6); margin-bottom: 5px; }
.tb-claim-avatar { width: 22px; height: 22px; border-radius: 50%; background: rgba(255,255,255,0.08); display: flex; align-items: center; justify-content: center; font-size: 10px; }

/* Mobile */
.tb-mobile-list { display: none; flex-direction: column; gap: 10px; padding: 12px 20px; flex: 1; overflow-y: auto; }

@media (max-width: 768px) {
  .tb-board { display: none; }
  .tb-tabbar { display: flex; }
  .tb-tabbar { overflow-x: auto; gap: 0; padding: 0 16px; border-bottom: 1px solid rgba(255,255,255,0.04); flex-shrink: 0; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
  .tb-tabbar::-webkit-scrollbar { display: none; }
  .tb-tab { flex: 1; min-width: 76px; padding: 10px 4px; font-size: 12px; background: none; border: none; border-bottom: 2px solid transparent; color: rgba(255,255,255,0.4); cursor: pointer; font-weight: 500; transition: all .2s; }
  .tb-tab.active { color: var(--accent, #6c5ce7); border-color: var(--accent, #6c5ce7); }
  .tb-tab-count { font-size: 10px; color: rgba(255,255,255,0.2); }
  .tb-mobile-list { display: flex; }
  .tb-stats { grid-template-columns: repeat(4,1fr); gap: 6px; padding: 10px 14px; }
  .tb-stat-item { padding: 8px 6px; flex-direction: column; align-items: center; text-align: center; gap: 4px; }
  .tb-stat-num { font-size: 15px; }
  .tb-stat-label { font-size: 10px; }
  .tb-header { padding: 12px 14px; }
  .tb-title { font-size: 16px; }
  .tb-sub-content { width: 100%; max-width: 100%; max-height: 92vh; border-radius: 12px 12px 0 0; margin-top: auto; }
  .tb-field-row { grid-template-columns: 1fr; gap: 0; }
  .tb-container { width: 100%; max-width: 100%; max-height: 100vh; border-radius: 0; }
}

/* ===== DevHost 网页托管 暗色主题 ===== */
.widget-hosting { cursor: pointer; background: linear-gradient(135deg, rgba(34,211,238,0.06), rgba(108,92,231,0.04)); border-color: rgba(34,211,238,0.12); }
.widget-hosting .hosting-body { display: flex; align-items: center; gap: 8px; font-size: 14px; color: rgba(255,255,255,0.55); padding: 0; flex: none; overflow: visible; }
.widget-hosting .hosting-icon { font-size: 20px; }

.hosting-modal-content {
  position: relative; z-index: 1;
  width: 92%; max-width: 760px; max-height: 90vh; display: flex; flex-direction: column;
  background: rgba(20, 22, 35, 0.95); border: 1px solid rgba(255,255,255,0.08); border-radius: 18px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5); overflow: hidden;
}
.hosting-header { display: flex; align-items: center; justify-content: space-between; padding: 18px 24px; border-bottom: 1px solid rgba(255,255,255,0.06); }
.hosting-header h3 { margin: 0; font-size: 18px; color: #fff; font-weight: 700; }
.hosting-close { cursor: pointer; font-size: 18px; color: rgba(255,255,255,0.4); transition: color .2s; padding: 4px 8px; border-radius: 8px; }
.hosting-close:hover { color: #fff; background: rgba(255,255,255,0.08); }

.hosting-tabs { display: flex; gap: 2px; padding: 10px 24px 0; border-bottom: 1px solid rgba(255,255,255,0.06); }
.hosting-tab-btn { padding: 8px 20px; border: none; background: none; color: rgba(255,255,255,0.4); font-size: 14px; cursor: pointer; border-bottom: 2px solid transparent; transition: all .2s; font-weight: 500; }
.hosting-tab-btn.active { color: var(--accent, #6c5ce7); border-color: var(--accent, #6c5ce7); }
.hosting-tab-btn:hover { color: rgba(255,255,255,0.7); }

.hosting-body { flex: 1; overflow-y: auto; padding: 20px 24px; }
.hosting-panel { }

/* Upload panel */
.hosting-dropzone {
  border: 2px dashed rgba(255,255,255,0.12); border-radius: 14px; padding: 40px 20px; text-align: center;
  cursor: pointer; transition: all .25s; background: rgba(255,255,255,0.02);
}
.hosting-dropzone:hover, .hosting-dropzone.dragover { border-color: var(--accent, #6c5ce7); background: rgba(108,92,231,0.08); }
.hosting-dropzone svg { color: rgba(255,255,255,0.3); margin-bottom: 12px; }
.hosting-dropzone p { color: rgba(255,255,255,0.6); font-size: 15px; margin: 0 0 4px; }
.hosting-dropzone small { color: rgba(255,255,255,0.3); font-size: 12px; }

.hosting-form-row { margin-top: 12px; }
.hosting-form-row input {
  width: 100%; padding: 10px 14px; border-radius: 10px; border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.04); color: #fff; font-size: 14px; outline: none; transition: border-color .2s;
}
.hosting-form-row input:focus { border-color: var(--accent, #6c5ce7); }

.hosting-progress { margin-top: 16px; }
.hosting-progress-bar { height: 4px; background: rgba(255,255,255,0.08); border-radius: 2px; overflow: hidden; }
.hosting-progress-fill { height: 100%; background: linear-gradient(90deg, #6c5ce7, #22d3ee); border-radius: 2px; transition: width .2s; width: 0%; }
.hosting-progress #hostingProgressText { display: block; margin-top: 8px; font-size: 13px; color: rgba(255,255,255,0.5); }

.hosting-result { margin-top: 16px; padding: 16px; border-radius: 12px; background: rgba(34,211,238,0.06); border: 1px solid rgba(34,211,238,0.15); }
.hosting-result-title { font-size: 15px; color: #22d3ee; font-weight: 600; margin-bottom: 8px; }
.hosting-result-link { display: flex; gap: 8px; align-items: center; margin-top: 8px; }
.hosting-result-link input { flex: 1; padding: 8px 12px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.08); background: rgba(0,0,0,0.3); color: rgba(255,255,255,0.7); font-size: 13px; outline: none; }
.hosting-result-link button { padding: 8px 16px; border-radius: 8px; border: none; background: var(--accent, #6c5ce7); color: #fff; font-size: 13px; cursor: pointer; white-space: nowrap; }
.hosting-result-note { margin-top: 10px; font-size: 12px; color: rgba(255,255,255,0.4); line-height: 1.6; }
.hosting-result-note code { background: rgba(255,255,255,0.08); padding: 2px 6px; border-radius: 4px; font-size: 11px; color: rgba(255,255,255,0.6); }

/* Explore panel */
.hosting-search-row { display: flex; gap: 10px; margin-bottom: 16px; }
.hosting-search-row input { flex: 1; padding: 10px 14px; border-radius: 10px; border: 1px solid rgba(255,255,255,0.08); background: rgba(255,255,255,0.04); color: #fff; font-size: 14px; outline: none; }
.hosting-search-row input:focus { border-color: var(--accent, #6c5ce7); }
.hosting-refresh-btn { padding: 10px 18px; border-radius: 10px; border: 1px solid rgba(255,255,255,0.08); background: rgba(255,255,255,0.04); color: rgba(255,255,255,0.6); font-size: 14px; cursor: pointer; transition: all .2s; white-space: nowrap; }
.hosting-refresh-btn:hover { background: rgba(255,255,255,0.08); color: #fff; }

.hosting-sites-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.hosting-site-card { border: 1px solid rgba(255,255,255,0.06); border-radius: 12px; overflow: hidden; background: rgba(255,255,255,0.02); transition: all .25s; cursor: pointer; }
.hosting-site-card:hover { border-color: rgba(108,92,231,0.3); transform: translateY(-2px); }
.hosting-site-preview { height: 130px; background: rgba(0,0,0,0.3); position: relative; overflow: hidden; }
.hosting-site-preview iframe { width: 100%; height: 100%; border: none; }
.hosting-site-preview .ph { display: flex; align-items: center; justify-content: center; height: 100%; color: rgba(255,255,255,0.15); font-size: 12px; font-family: monospace; }
.hosting-site-info { padding: 10px 12px; }
.hosting-site-info h4 { margin: 0 0 6px; font-size: 14px; color: #fff; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hosting-site-meta { display: flex; gap: 8px; font-size: 11px; color: rgba(255,255,255,0.3); margin-bottom: 8px; }
.hosting-site-actions { display: flex; gap: 6px; }
.hosting-site-actions a, .hosting-site-actions button { flex: 1; padding: 5px 8px; border-radius: 7px; border: none; font-size: 12px; cursor: pointer; text-align: center; text-decoration: none; transition: all .2s; }
.hosting-site-actions .open-btn { background: var(--accent, #6c5ce7); color: #fff; }
.hosting-site-actions .copy-btn { background: rgba(255,255,255,0.06); color: rgba(255,255,255,0.5); border: 1px solid rgba(255,255,255,0.06); }
.hosting-site-actions .copy-btn:hover { background: rgba(255,255,255,0.12); color: #fff; }
.hosting-site-actions .share-btn { background: rgba(34,211,238,0.1); color: rgba(34,211,238,0.8); border: 1px solid rgba(34,211,238,0.2); }
.hosting-site-actions .share-btn:hover { background: rgba(34,211,238,0.2); color: #22d3ee; }
.hosting-lock-badge { font-size: 11px; }

.hosting-load-more { text-align: center; margin-top: 20px; }
.hosting-load-more-btn { padding: 10px 30px; border-radius: 10px; border: 1px solid rgba(255,255,255,0.08); background: rgba(255,255,255,0.04); color: rgba(255,255,255,0.5); font-size: 14px; cursor: pointer; }
.hosting-load-more-btn:hover { background: rgba(255,255,255,0.08); color: #fff; }

.hosting-empty { text-align: center; padding: 40px 20px; color: rgba(255,255,255,0.3); }
.hosting-empty p { margin: 8px 0; }

/* Detail modal */
.hosting-detail-body { padding: 20px 24px; }
.hosting-detail-preview { border-radius: 12px; overflow: hidden; border: 1px solid rgba(255,255,255,0.06); margin-bottom: 16px; }
.hosting-detail-preview iframe { width: 100%; height: 300px; border: none; }
.hosting-detail-info { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px; }
.hosting-detail-info-item { font-size: 13px; }
.hosting-detail-info-item .label { color: rgba(255,255,255,0.3); margin-bottom: 2px; }
.hosting-detail-info-item .value { color: rgba(255,255,255,0.7); }
.hosting-detail-actions { display: flex; gap: 10px; }
.hosting-detail-actions a, .hosting-detail-actions button { flex: 1; padding: 10px; border-radius: 10px; text-align: center; text-decoration: none; font-size: 14px; font-weight: 500; cursor: pointer; border: none; }
.hosting-detail-actions .open-btn { background: var(--accent, #6c5ce7); color: #fff; }
.hosting-detail-actions .copy-btn { background: rgba(255,255,255,0.06); color: rgba(255,255,255,0.5); border: 1px solid rgba(255,255,255,0.06); }
.hosting-detail-actions .share-btn-detail { background: rgba(34,211,238,0.1); color: rgba(34,211,238,0.8); border: 1px solid rgba(34,211,238,0.2); }

/* Mobile responsive */
@media (max-width: 768px) {
  .hosting-modal-content { width: 100%; max-width: 100%; max-height: 100vh; border-radius: 0; }
  .hosting-sites-grid { grid-template-columns: 1fr; }
  .hosting-detail-info { grid-template-columns: 1fr; }
  .hosting-tabs { padding: 10px 16px 0; }
  .hosting-body { padding: 16px; }
}

/* ===== 需求工单系统 暗色主题 ===== */
.widget-tickets { cursor: pointer; }
.widget-tickets .tickets-icon { font-size: 20px; }
.widget-tickets .tickets-body { font-size: 14px; color: rgba(255,255,255,0.7); display: flex; align-items: center; gap: 8px; padding: 0; flex: none; overflow: visible; }
.tickets-modal-content {
  background: rgba(20, 20, 40, 0.95);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 20px;
  width: 90%;
  max-width: 680px;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.tickets-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.tickets-header h3 { font-size: 16px; color: #fff; margin: 0; }
.tickets-close { font-size: 18px; color: rgba(255,255,255,0.5); cursor: pointer; padding: 4px 8px; border-radius: 8px; transition: all 0.2s; }
.tickets-close:hover { color: #fff; background: rgba(255,255,255,0.1); }
.tickets-tabs {
  display: flex;
  gap: 4px;
  padding: 12px 20px 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.tickets-tab {
  padding: 8px 16px;
  border: none;
  background: none;
  color: rgba(255,255,255,0.5);
  font-size: 14px;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: all 0.2s;
}
.tickets-tab.active { color: #a29bfe; border-bottom-color: #a29bfe; }
.tickets-tab:hover { color: rgba(255,255,255,0.8); }
.tickets-body { padding: 16px 20px 20px; overflow-y: auto; flex: 1; }

/* 看板统计 */
.ticket-stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 16px; }
.ticket-stat-card {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  padding: 14px 10px;
  text-align: center;
}
.ticket-stat-card .stat-num { font-size: 24px; font-weight: 700; }
.ticket-stat-card .stat-label { font-size: 12px; color: rgba(255,255,255,0.5); margin-top: 4px; }
.ticket-stat-pending .stat-num { color: #f59e0b; }
.ticket-stat-processing .stat-num { color: #3b82f6; }
.ticket-stat-completed .stat-num { color: #10b981; }
.ticket-stat-closed .stat-num { color: #94a3b8; }

/* 提交表单 */
.ticket-form { display: flex; flex-direction: column; gap: 12px; }
.ticket-form-group { display: flex; flex-direction: column; gap: 4px; }
.ticket-form-group label { font-size: 13px; color: rgba(255,255,255,0.7); }
.ticket-form-group input, .ticket-form-group select, .ticket-form-group textarea {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px;
  padding: 10px 12px;
  color: #fff;
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s;
}
.ticket-form-group input:focus, .ticket-form-group select:focus, .ticket-form-group textarea:focus {
  border-color: rgba(162,155,254,0.5);
}
.ticket-form-group textarea { resize: vertical; min-height: 80px; }
.ticket-form-group select option { background: #1a1a2e; }
.ticket-form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ticket-submit-btn {
  background: linear-gradient(135deg, #6c5ce7, #a29bfe);
  color: #fff;
  border: none;
  border-radius: 12px;
  padding: 12px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.2s;
}
.ticket-submit-btn:hover { opacity: 0.9; }

/* 工单列表 */
.ticket-list-filter { display: flex; gap: 8px; margin-bottom: 12px; flex-wrap: wrap; align-items: center; }
.ticket-list-filter select {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  padding: 6px 10px;
  color: #fff;
  font-size: 13px;
  outline: none;
}
.ticket-list-filter select option { background: #1a1a2e; }
.ticket-list-filter input {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  padding: 6px 12px;
  color: #fff;
  font-size: 13px;
  outline: none;
  flex: 1;
  min-width: 120px;
}
.ticket-card {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 10px;
  cursor: pointer;
  transition: all 0.2s;
}
.ticket-card:hover { background: rgba(255,255,255,0.08); border-color: rgba(162,155,254,0.3); }
.ticket-card-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.ticket-card-title { font-size: 14px; font-weight: 600; color: #fff; max-width: 70%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ticket-card-badges { display: flex; gap: 5px; flex-shrink: 0; }
.ticket-badge { padding: 2px 8px; border-radius: 6px; font-size: 11px; font-weight: 600; white-space: nowrap; }
.ticket-badge-pending { background: rgba(245,158,11,0.15); color: #f59e0b; }
.ticket-badge-processing { background: rgba(59,130,246,0.15); color: #3b82f6; }
.ticket-badge-completed { background: rgba(16,185,129,0.15); color: #10b981; }
.ticket-badge-closed { background: rgba(148,163,184,0.15); color: #94a3b8; }
.ticket-badge-urgent { background: rgba(239,68,68,0.15); color: #ef4444; }
.ticket-badge-high { background: rgba(249,115,22,0.15); color: #f97316; }
.ticket-badge-medium { background: rgba(59,130,246,0.15); color: #3b82f6; }
.ticket-badge-low { background: rgba(148,163,184,0.15); color: #94a3b8; }
.ticket-badge-requirement { background: rgba(108,92,231,0.15); color: #a29bfe; }
.ticket-badge-optimization { background: rgba(14,165,233,0.15); color: #0ea5e9; }
.ticket-badge-bug { background: rgba(239,68,68,0.15); color: #ef4444; }
.ticket-badge-consult { background: rgba(34,197,94,0.15); color: #22c55e; }
.ticket-card-meta { font-size: 12px; color: rgba(255,255,255,0.4); display: flex; gap: 12px; }
.ticket-card-no { font-family: monospace; color: rgba(255,255,255,0.5); }
.ticket-empty { text-align: center; padding: 40px 0; color: rgba(255,255,255,0.4); font-size: 14px; }
.ticket-pagination { display: flex; justify-content: center; gap: 8px; margin-top: 12px; }
.ticket-pagination button {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  padding: 6px 14px;
  color: rgba(255,255,255,0.7);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
}
.ticket-pagination button:disabled { opacity: 0.4; cursor: not-allowed; }
.ticket-pagination button:hover:not(:disabled) { background: rgba(162,155,254,0.15); color: #a29bfe; }

/* 工单详情 */
.ticket-detail-section { margin-bottom: 16px; }
.ticket-detail-section h4 { font-size: 14px; color: rgba(255,255,255,0.7); margin: 0 0 8px; }
.ticket-detail-info { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 16px; }
.ticket-detail-info dt { font-size: 12px; color: rgba(255,255,255,0.4); }
.ticket-detail-info dd { font-size: 13px; color: rgba(255,255,255,0.85); margin: 0 0 6px; }
.ticket-detail-desc { font-size: 13px; color: rgba(255,255,255,0.7); line-height: 1.7; white-space: pre-wrap; background: rgba(255,255,255,0.04); border-radius: 10px; padding: 12px; }
.ticket-timeline { position: relative; padding-left: 18px; }
.ticket-timeline::before { content: ''; position: absolute; left: 5px; top: 4px; bottom: 4px; width: 2px; background: rgba(255,255,255,0.08); border-radius: 1px; }
.ticket-timeline-item { position: relative; margin-bottom: 12px; font-size: 13px; }
.ticket-timeline-item::before { content: ''; position: absolute; left: -16px; top: 6px; width: 8px; height: 8px; border-radius: 50%; background: #6c5ce7; }
.ticket-timeline-item .tl-time { font-size: 11px; color: rgba(255,255,255,0.35); }
.ticket-timeline-item .tl-action { color: rgba(255,255,255,0.8); margin-top: 2px; }
.ticket-timeline-item .tl-content { color: rgba(255,255,255,0.55); margin-top: 2px; font-size: 12px; }
.ticket-action-bar { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.ticket-action-bar button {
  padding: 8px 16px;
  border-radius: 10px;
  border: none;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
}
.ticket-action-btn-primary { background: rgba(108,92,231,0.2); color: #a29bfe; }
.ticket-action-btn-primary:hover { background: rgba(108,92,231,0.35); }
.ticket-action-btn-success { background: rgba(16,185,129,0.15); color: #10b981; }
.ticket-action-btn-success:hover { background: rgba(16,185,129,0.3); }
.ticket-action-btn-warning { background: rgba(245,158,11,0.15); color: #f59e0b; }
.ticket-action-btn-warning:hover { background: rgba(245,158,11,0.3); }
.ticket-action-btn-danger { background: rgba(239,68,68,0.15); color: #ef4444; }
.ticket-action-btn-danger:hover { background: rgba(239,68,68,0.3); }

@media (max-width: 768px) {
  .tickets-modal-content { width: 100%; max-width: 100%; max-height: 100vh; border-radius: 0; }
  .ticket-stats-grid { grid-template-columns: repeat(2, 1fr); }
  .ticket-form-row { grid-template-columns: 1fr; }
  .ticket-detail-info { grid-template-columns: 1fr; }
  .tickets-tabs { padding: 10px 16px 0; }
  .tickets-body { padding: 16px; }
}

/* ===== Markdown 编辑器卡片 ===== */
.widget-md-editor { cursor: pointer; }
.widget-md-editor .md-editor-icon { font-size: 20px; }
.md-editor-body { display: flex; align-items: center; gap: 8px; font-size: 14px; color: rgba(255,255,255,0.7); }

/* ===== 会议纪要卡片 ===== */
.widget-meeting { cursor: pointer; }
.widget-meeting .meeting-icon { font-size: 20px; }
.meeting-body { display: flex; align-items: center; gap: 8px; font-size: 14px; color: rgba(255,255,255,0.7); }

/* ===== 压缩工具卡片 ===== */
.widget-compress { cursor: pointer; }
.widget-compress .compress-icon { font-size: 20px; }
.compress-body { display: flex; align-items: center; gap: 8px; font-size: 14px; color: rgba(255,255,255,0.7); }

/* ===== 在线PS卡片 ===== */
.widget-photoshop { cursor: pointer; }
.widget-photoshop .photoshop-icon { font-size: 20px; }
.photoshop-body { display: flex; align-items: center; gap: 8px; font-size: 14px; color: rgba(255,255,255,0.7); }

/* ===== 会议纪要弹窗 ===== */
.meeting-modal-content {
  background: rgba(20, 20, 40, 0.96);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 20px;
  width: 92%;
  max-width: 900px;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.meeting-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.meeting-header h3 { margin: 0; font-size: 18px; }
.meeting-close { cursor: pointer; font-size: 20px; color: rgba(255,255,255,0.5); }
.meeting-close:hover { color: #fff; }
.meeting-modal-content .meeting-body {
  display: flex; gap: 20px; padding: 20px 24px; overflow-y: auto; flex: 1;
}
.meeting-left { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.meeting-right { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.meeting-upload-zone {
  border: 2px dashed rgba(255,255,255,0.18); border-radius: 12px;
  padding: 22px; text-align: center; cursor: pointer; transition: border-color .2s, background .2s;
}
.meeting-upload-zone:hover { border-color: rgba(108,92,231,0.6); background: rgba(108,92,231,0.05); }
.meeting-upload-icon { font-size: 34px; }
.meeting-upload-zone p { margin: 8px 0 0; color: rgba(255,255,255,0.75); font-size: 14px; }
.meeting-upload-hint { font-size: 12px !important; color: rgba(255,255,255,0.4) !important; }
.meeting-audio-status { font-size: 13px; display: flex; align-items: center; gap: 8px; padding: 10px 12px; background: rgba(255,255,255,0.04); border-radius: 8px; }
.meeting-status-ok { color: #34d399; }
.meeting-status-err { color: #fbbf24; }
.meeting-form { display: flex; flex-direction: column; gap: 8px; }
.meeting-form label { font-size: 13px; color: var(--text-secondary); }
.meeting-form input, .meeting-form textarea {
  width: 100%; box-sizing: border-box; background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12); border-radius: 8px; padding: 10px 12px;
  color: #fff; font-size: 14px; resize: vertical; font-family: inherit;
}
.meeting-model-select {
  width: 100%; box-sizing: border-box; background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12); border-radius: 8px; padding: 9px 12px;
  color: #fff; font-size: 14px; cursor: pointer; font-family: inherit;
  outline: none; -webkit-appearance: none; -moz-appearance: none; appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='%23888' d='M0 0l5 6 5-6z'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center;
}
.meeting-model-select option { background: #1a1a2e; color: #fff; }
.meeting-actions { display: flex; gap: 10px; margin-top: 4px; }
.meeting-btn-primary, .meeting-btn-ghost {
  padding: 9px 16px; border-radius: 8px; border: none; cursor: pointer; font-size: 14px;
}
.meeting-btn-primary { background: linear-gradient(135deg, #6c5ce7, #8b5cf6); color: #fff; }
.meeting-btn-primary:hover { opacity: 0.9; }
.meeting-btn-ghost { background: rgba(255,255,255,0.08); color: rgba(255,255,255,0.85); }
.meeting-btn-ghost:hover { background: rgba(255,255,255,0.14); }
.meeting-output-header { font-size: 13px; color: var(--text-secondary); font-weight: 600; }
.meeting-right textarea {
  width: 100%; box-sizing: border-box; flex: 1; min-height: 200px;
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.12);
  border-radius: 8px; padding: 12px; color: #fff; font-size: 14px; resize: vertical; font-family: inherit;
}
.meeting-list { padding: 0 24px 20px; border-top: 1px solid rgba(255,255,255,0.08); overflow-y: auto; max-height: 200px; }
.meeting-list-header { font-size: 13px; color: var(--text-secondary); font-weight: 600; padding: 14px 0 8px; }
.meeting-item { display: flex; align-items: center; justify-content: space-between; padding: 10px 12px; background: rgba(255,255,255,0.04); border-radius: 8px; margin-bottom: 8px; }
.meeting-item-info { flex: 1; cursor: pointer; min-width: 0; }
.meeting-item-title { font-size: 14px; color: rgba(255,255,255,0.9); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.meeting-item-time { font-size: 12px; color: rgba(255,255,255,0.4); margin-top: 2px; }
.meeting-item-del { cursor: pointer; color: rgba(255,255,255,0.4); padding: 0 6px; font-size: 18px; }
.meeting-item-del:hover { color: #ef4444; }
.meeting-empty { text-align: center; color: rgba(255,255,255,0.4); font-size: 13px; padding: 16px 0; }

/* ===== 压缩工具弹窗 ===== */
.compress-modal-content {
  background: rgba(20, 20, 40, 0.96);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 20px;
  width: 92%;
  max-width: 640px;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.compress-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 24px; border-bottom: 1px solid rgba(255,255,255,0.08);
}
.compress-header h3 { margin: 0; font-size: 18px; }
.compress-close { cursor: pointer; font-size: 20px; color: rgba(255,255,255,0.5); }
.compress-close:hover { color: #fff; }
.compress-tabs { display: flex; gap: 8px; padding: 14px 24px 0; }
.compress-tab {
  padding: 8px 16px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.04); color: rgba(255,255,255,0.7); cursor: pointer; font-size: 14px;
}
.compress-tab.active { background: linear-gradient(135deg, #6c5ce7, #8b5cf6); color: #fff; border-color: transparent; }
.compress-panel { padding: 20px 24px; overflow-y: auto; flex: 1; }
.compress-dropzone {
  border: 2px dashed rgba(255,255,255,0.18); border-radius: 12px; padding: 28px;
  text-align: center; cursor: pointer; transition: border-color .2s, background .2s;
}
.compress-dropzone:hover { border-color: rgba(108,92,231,0.6); background: rgba(108,92,231,0.05); }
.compress-drop-icon { font-size: 36px; }
.compress-dropzone p { margin: 8px 0 0; color: rgba(255,255,255,0.75); font-size: 14px; }
.compress-drop-hint { font-size: 12px !important; color: rgba(255,255,255,0.4) !important; }
.compress-settings { margin-top: 16px; display: flex; flex-direction: column; gap: 12px; }
.compress-row { display: flex; align-items: center; gap: 12px; font-size: 13px; color: rgba(255,255,255,0.75); }
.compress-row label { min-width: 72px; }
.compress-row input[type="range"] { flex: 1; accent-color: #8b5cf6; }
.compress-row select {
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.12);
  border-radius: 8px; padding: 8px 10px; color: #fff; font-size: 13px;
}
.compress-compare { display: flex; flex-direction: column; gap: 6px; }
.compress-file-info { font-size: 13px; color: rgba(255,255,255,0.6); }
.compress-result { color: #34d399; font-weight: 600; }
.compress-btn-primary, .compress-btn-download {
  display: inline-block; text-align: center; padding: 10px 16px; border-radius: 8px;
  border: none; cursor: pointer; font-size: 14px; text-decoration: none;
}
.compress-btn-primary { background: linear-gradient(135deg, #6c5ce7, #8b5cf6); color: #fff; }
.compress-btn-primary:hover { opacity: 0.9; }
.compress-btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }
.compress-btn-download { background: rgba(52,211,153,0.15); color: #34d399; }
.compress-btn-download:hover { background: rgba(52,211,153,0.25); }
.compress-progress { display: flex; flex-direction: column; gap: 8px; }
.compress-progress-bar { height: 8px; background: rgba(255,255,255,0.1); border-radius: 4px; overflow: hidden; }
.compress-progress-fill { height: 100%; width: 0; background: linear-gradient(90deg, #6c5ce7, #8b5cf6); transition: width .3s; }
.compress-progress span { font-size: 12px; color: rgba(255,255,255,0.5); }

@media (max-width: 768px) {
  .meeting-modal-content .meeting-body { flex-direction: column; }
  .meeting-modal-content, .compress-modal-content { width: 100%; max-width: 100%; max-height: 100vh; border-radius: 0; }
  .meeting-list { max-height: 160px; }
}

.drag-active { border-color: #8b5cf6 !important; background: rgba(108,92,231,0.1) !important; }

/* ===== PC 端灵动岛折叠按钮（折叠后靠右） ===== */
@media (min-width: 769px) {
  .dynamic-island {
    display: flex;
    align-items: center;
    gap: 8px;
  }
  .island-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: row;
    gap: 0;
    padding: 0;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: rgba(15,15,30,0.55);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255,255,255,0.08);
    box-shadow: 0 8px 32px rgba(0,0,0,0.35);
    color: rgba(255,255,255,0.55);
    cursor: pointer;
    flex-shrink: 0;
    transition: color 0.2s, background 0.2s;
  }
  .island-toggle:hover {
    color: #fff;
    background: rgba(255,255,255,0.08);
  }
  .island-toggle svg {
    width: 18px;
    height: 18px;
    transition: transform 0.3s;
    transform: rotate(90deg); /* → 指向右，提示折叠后靠右 */
  }
  .island-toggle-label {
    display: none;
  }
  /* 折叠态：隐藏书签 pill，仅保留右侧圆形按钮 */
  .dynamic-island.folded .island-inner .island-item,
  .dynamic-island.folded .island-inner .island-settings,
  .dynamic-island.folded .island-inner .island-empty {
    display: none;
  }
  .dynamic-island.folded .island-inner {
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
    gap: 0;
  }
  .dynamic-island.folded .island-toggle svg {
    transform: rotate(270deg); /* ← 指向左，提示展开回居中 */
  }
}

/* ===== 移动端性能优化：降低 GPU 压力，修复华为浏览器卡顿/闪退 ===== */
@media (max-width: 768px) {
  :root {
    --glass-blur: none;
    --shadow-glass: 0 6px 18px rgba(0,0,0,0.28);
  }

  /* 关闭背景渐变动画，避免持续重绘（移动端 GPU 常驻开销大） */
  .bg-layer {
    animation: none !important;
    background-size: cover !important;
    background-attachment: scroll !important;
  }

  /* 全局关闭 backdrop-filter —— 模糊/饱和滤镜是移动端 GPU 内存压力与闪退主因 */
  * {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }

  /* 关闭模糊后提升玻璃背景不透明度，保证可读性 */
  .sidebar { background: rgba(10,10,24,0.92) !important; }
  .widget-card { background: rgba(255,255,255,0.07) !important; }
  .bottom-widget { background: rgba(255,255,255,0.07) !important; }
  .island-inner { background: rgba(16,16,32,0.88) !important; }
  .dynamic-island.folded .island-inner { background: transparent !important; border: none !important; box-shadow: none !important; }
  .island-toggle { background: rgba(16,16,32,0.88) !important; }

  /* 减轻大面积阴影，降低光栅化开销 */
  .modal-content,
  .chat-panel,
  .tickets-modal-content,
  .hosting-modal-content,
  .meeting-modal-content,
  .compress-modal-content,
  .folder-icons-content,
  .tb-container,
  .lrc-editor-content,
  .auth-modal-content,
  .browser-window {
    box-shadow: 0 8px 24px rgba(0,0,0,0.35) !important;
  }
}

/* 尊重系统「减少动态效果」偏好 */
@media (prefers-reduced-motion: reduce) {
  .bg-layer { animation: none !important; }
  * { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}

/* ===== E2EE 密聊 ===== */
.e2ee-modal-content {
  background: rgba(18, 18, 40, 0.96);
  backdrop-filter: blur(22px);
  -webkit-backdrop-filter: blur(22px);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 20px;
  width: 94%;
  max-width: 880px;
  height: 82vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
  box-shadow: 0 18px 60px rgba(0,0,0,0.45);
}
.e2ee-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.e2ee-header h3 { font-size: 16px; color: #fff; margin: 0; }
.e2ee-header-actions { display: flex; align-items: center; gap: 10px; }
.e2ee-close { font-size: 18px; color: rgba(255,255,255,0.5); cursor: pointer; padding: 4px 8px; border-radius: 8px; transition: all 0.2s; }
.e2ee-close:hover { color: #fff; background: rgba(255,255,255,0.1); }
.e2ee-btn-ghost {
  padding: 7px 14px;
  border: 1px solid rgba(162,155,254,0.4);
  background: rgba(108,92,231,0.15);
  color: #a29bfe;
  border-radius: 10px;
  cursor: pointer;
  font-size: 13px;
  transition: all 0.2s;
}
.e2ee-btn-ghost:hover { background: rgba(108,92,231,0.3); color: #fff; }

.e2ee-body { display: flex; flex: 1; min-height: 0; }
.e2ee-conv-side {
  width: 250px; min-width: 250px;
  border-right: 1px solid rgba(255,255,255,0.08);
  display: flex; flex-direction: column;
}
.e2ee-conv-title {
  padding: 12px 16px 8px;
  font-size: 12px; color: rgba(255,255,255,0.4);
  letter-spacing: 1px;
}
.e2ee-conv-list { flex: 1; overflow-y: auto; padding: 0 8px 12px; }
.e2ee-conv-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 10px;
  border-radius: 12px;
  cursor: pointer;
  transition: background 0.2s;
  margin-bottom: 2px;
}
.e2ee-conv-item:hover { background: rgba(255,255,255,0.06); }
.e2ee-conv-item.active { background: rgba(108,92,231,0.22); }
.e2ee-avatar {
  width: 38px; height: 38px; min-width: 38px;
  border-radius: 50%;
  background: linear-gradient(135deg, #6c5ce7, #00d4ff);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 600; font-size: 15px;
}
.e2ee-conv-info { flex: 1; min-width: 0; }
.e2ee-conv-name { font-size: 14px; color: #e8eaff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.e2ee-conv-preview { font-size: 12px; color: rgba(200,210,255,0.5); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 2px; }
.e2ee-conv-time { font-size: 11px; color: rgba(200,210,255,0.35); white-space: nowrap; }

.e2ee-msg-side { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.e2ee-active-header {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 18px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  font-size: 14px; color: #e8eaff;
}
.e2ee-active-avatar {
  width: 30px; height: 30px; min-width: 30px;
  border-radius: 50%;
  background: linear-gradient(135deg, #00d4ff, #6c5ce7);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 600; font-size: 13px;
}
.e2ee-secure-badge {
  margin-left: auto;
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 20px;
  background: rgba(16,185,129,0.18);
  color: #10b981;
  border: 1px solid rgba(16,185,129,0.3);
}
.e2ee-msg-list { flex: 1; overflow-y: auto; padding: 16px 18px; display: flex; flex-direction: column; gap: 8px; }
.e2ee-empty { color: rgba(200,210,255,0.4); font-size: 13px; text-align: center; padding: 30px 10px; }

.e2ee-msg { display: flex; }
.e2ee-msg.mine { justify-content: flex-end; }
.e2ee-msg.theirs { justify-content: flex-start; }
.e2ee-bubble {
  max-width: 70%;
  padding: 9px 13px;
  border-radius: 14px;
  font-size: 14px;
  line-height: 1.5;
  word-break: break-word;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.08);
  color: #e8eaff;
}
.e2ee-msg.mine .e2ee-bubble { background: rgba(108,92,231,0.35); border-color: rgba(108,92,231,0.4); }
.e2ee-bubble.e2ee-burned { color: rgba(255,255,255,0.55); font-style: italic; }
.e2ee-text { white-space: pre-wrap; }
.e2ee-uncryptable { color: rgba(255,255,255,0.4); font-style: italic; }
.e2ee-burn-hint {
  margin-top: 6px;
  font-size: 11px;
  color: #ff6b6b;
  cursor: pointer;
  user-select: none;
  padding: 3px 8px;
  border-radius: 8px;
  background: rgba(255,71,87,0.12);
  border: 1px solid rgba(255,71,87,0.3);
  display: inline-block;
  transition: all 0.2s;
}
.e2ee-burn-hint:hover { background: rgba(255,71,87,0.25); color: #fff; }
.e2ee-media { max-width: 260px; border-radius: 12px; overflow: hidden; }
.e2ee-media img { display: block; max-width: 100%; border-radius: 12px; cursor: pointer; }
.e2ee-media video { display: block; max-width: 100%; max-height: 240px; border-radius: 12px; }
.e2ee-media-tag { font-size: 11px; color: rgba(200,210,255,0.5); padding: 4px 2px 0; }
.e2ee-file { display: inline-flex; align-items: center; gap: 6px; color: #a29bfe; text-decoration: none; }
.e2ee-file:hover { text-decoration: underline; }
.e2ee-link { color: #00d4ff; text-decoration: none; word-break: break-all; }
.e2ee-link:hover { text-decoration: underline; }
.e2ee-sticker { font-size: 42px; line-height: 1.2; }

.e2ee-input-bar {
  display: flex; align-items: flex-end; gap: 8px;
  padding: 12px 16px;
  border-top: 1px solid rgba(255,255,255,0.08);
}
.e2ee-tools { position: relative; flex-shrink: 0; display: flex; align-items: center; }
.e2ee-more-btn { font-weight: bold; font-size: 20px; }
.e2ee-more-btn.active { border-color: rgba(108,92,231,0.7); background: rgba(108,92,231,0.2); color: #fff; }
.e2ee-tools-menu {
  position: absolute; bottom: 48px; left: 0; z-index: 60;
  display: flex; flex-wrap: wrap; gap: 6px; width: 210px;
  padding: 10px; border-radius: 12px;
  background: rgba(24,24,44,0.97); border: 1px solid rgba(255,255,255,0.14);
  box-shadow: 0 10px 28px rgba(0,0,0,0.45);
}
.e2ee-tools-menu .e2ee-tool-btn { width: 38px; height: 38px; font-size: 17px; }
.e2ee-input-bar textarea {
  flex: 1;
  resize: none;
  max-height: 90px;
  min-height: 38px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 12px;
  color: #e8eaff;
  padding: 9px 12px;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s;
}
.e2ee-input-bar textarea:focus { border-color: rgba(108,92,231,0.6); }
.e2ee-tool-btn {
  width: 36px; height: 36px; min-width: 36px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.05);
  color: rgba(255,255,255,0.7);
  font-size: 16px;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.2s;
}
.e2ee-tool-btn:hover { background: rgba(255,255,255,0.12); color: #fff; }
.e2ee-tool-burn { color: #ff6b6b; border-color: rgba(255,71,87,0.3); }
.e2ee-tool-burn:hover { background: rgba(255,71,87,0.15); }
.e2ee-send-btn {
  padding: 9px 18px;
  border: none;
  border-radius: 12px;
  background: linear-gradient(135deg, #6c5ce7, #00d4ff);
  color: #fff;
  font-size: 14px;
  cursor: pointer;
  transition: opacity 0.2s;
}
.e2ee-send-btn:hover { opacity: 0.85; }

.e2ee-toast {
  position: fixed; bottom: 30px; left: 50%; transform: translateX(-50%);
  z-index: 9999;
  background: rgba(20,20,45,0.95);
  border: 1px solid rgba(255,255,255,0.15);
  color: #fff;
  padding: 10px 20px;
  border-radius: 12px;
  font-size: 13px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.4);
}
.e2ee-toast.error { border-color: rgba(255,71,87,0.5); color: #ff8a8a; }
.e2ee-img-overlay {
  position: fixed; inset: 0; z-index: 7000;
  background: rgba(0,0,0,0.8);
  display: flex; align-items: center; justify-content: center;
  cursor: zoom-out;
}
.e2ee-img-overlay img { max-width: 90%; max-height: 90%; border-radius: 12px; }
.e2ee-img-close {
  position: absolute; top: 20px; right: 28px;
  font-size: 26px; color: #fff; cursor: pointer;
  padding: 6px 12px; border-radius: 10px; background: rgba(255,255,255,0.1);
}
.e2ee-img-close:hover { background: rgba(255,255,255,0.25); }
.e2ee-empty { color: rgba(200,210,255,0.4); font-size: 13px; text-align: center; padding: 30px 10px; }

/* ===== E2EE 密聊增强功能 ===== */
.e2ee-header-tools { margin-left: auto; display: flex; gap: 6px; }
.e2ee-tool-icon {
  width: 30px; height: 30px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.05); color: rgba(255,255,255,0.6); font-size: 14px;
  cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all 0.2s;
}
.e2ee-tool-icon:hover { background: rgba(255,255,255,0.12); color: #fff; }
.e2ee-tool-danger:hover { background: rgba(255,71,87,0.15); color: #ff6b6b; border-color: rgba(255,71,87,0.3); }

.e2ee-search-bar {
  display: flex; gap: 6px; padding: 8px 12px;
  border-bottom: 1px solid rgba(255,255,255,0.06); background: rgba(0,0,0,0.15);
}
.e2ee-search-bar input {
  flex: 1; background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px; color: #e8eaff; padding: 6px 10px; font-size: 13px; outline: none;
}
.e2ee-search-bar input:focus { border-color: rgba(108,92,231,0.5); }
.e2ee-search-btn {
  width: 30px; height: 30px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.05); color: rgba(255,255,255,0.6); font-size: 13px;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
}
.e2ee-search-btn:hover { background: rgba(255,255,255,0.12); color: #fff; }

.e2ee-quote-bar {
  display: flex; align-items: center; gap: 6px; padding: 6px 12px;
  background: rgba(108,92,231,0.1); border-left: 3px solid #6c5ce7; margin: 6px 12px 0;
  border-radius: 6px;
}
.e2ee-quote-label { font-size: 12px; color: #a29bfe; white-space: nowrap; }
.e2ee-quote-text { flex: 1; font-size: 12px; color: rgba(200,210,255,0.7); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.e2ee-quote-cancel {
  width: 22px; height: 22px; border-radius: 6px; border: none;
  background: rgba(255,255,255,0.1); color: rgba(255,255,255,0.5); font-size: 12px; cursor: pointer;
}
.e2ee-quote-cancel:hover { background: rgba(255,71,87,0.3); color: #fff; }

.e2ee-quote-block {
  font-size: 12px; color: rgba(200,210,255,0.55); padding: 4px 8px; margin-bottom: 4px;
  border-left: 2px solid rgba(108,92,231,0.4); background: rgba(108,92,231,0.06); border-radius: 4px;
}

.e2ee-msg-actions {
  display: flex; flex-direction: column; gap: 2px; opacity: 0; transition: opacity 0.15s;
  margin-right: 2px; align-self: center;
}
.e2ee-msg:hover .e2ee-msg-actions { opacity: 0.6; }
.e2ee-msg-actions button {
  width: 22px; height: 22px; border-radius: 6px; border: none;
  background: rgba(255,255,255,0.08); color: rgba(255,255,255,0.5); font-size: 12px;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
}
.e2ee-msg-actions button:hover { background: rgba(108,92,231,0.3); color: #fff; }
.e2ee-msg.mine .e2ee-msg-actions { order: 1; margin-left: 2px; margin-right: 0; }

.e2ee-voice { display: flex; align-items: center; gap: 6px; }
.e2ee-voice-icon { font-size: 20px; }
.e2ee-voice-player { max-width: 200px; height: 32px; }
#e2eeVoiceBtn.recording { background: rgba(255,71,87,0.2); border-color: rgba(255,71,87,0.5); color: #ff6b6b; animation: e2ee-pulse 1s infinite; }
@keyframes e2ee-pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.5; } }

.e2ee-chat-collapsed .e2ee-search-bar,
.e2ee-chat-collapsed .e2ee-quote-bar,
.e2ee-chat-collapsed .e2ee-msg-list,
.e2ee-chat-collapsed .e2ee-input-bar { display: none !important; }

/* ===== E2EE 密聊移动端适配 ===== */
@media (max-width: 768px) {
  .e2ee-modal-content { width: 100%; max-width: 100%; height: 100vh; border-radius: 0; }
  .e2ee-header { padding: 12px 14px; }
  .e2ee-header h3 { font-size: 15px; }
  .e2ee-btn-ghost { padding: 6px 10px; font-size: 12px; }
  /* 双栏布局改为单栏：侧栏抽屉式 */
  .e2ee-body { position: relative; }
  .e2ee-conv-side {
    width: 100%; min-width: 0; position: absolute; z-index: 50;
    top: 0; left: 0; bottom: 0; background: rgba(18,18,40,0.98);
    transform: translateX(0); transition: transform 0.25s ease;
  }
  .e2ee-conv-side.e2ee-collapsed { transform: translateX(-100%); }
  .e2ee-conv-info, .e2ee-conv-time { display: block; }
  .e2ee-msg-side { flex: 1; width: 100%; }
  /* 移动端返回按钮（JS 动态插入） */
  .e2ee-back-btn {
    display: inline-flex; align-items: center; gap: 4px;
    padding: 6px 12px; font-size: 13px; color: #a29bfe;
    background: rgba(108,92,231,0.15); border: 1px solid rgba(162,155,254,0.3);
    border-radius: 10px; cursor: pointer; white-space: nowrap; margin-right: 8px;
  }
  .e2ee-back-btn:active { background: rgba(108,92,231,0.3); }
  /* 消息气泡加宽 */
  .e2ee-bubble { max-width: 82%; font-size: 15px; padding: 10px 14px; }
  .e2ee-msg-list { padding: 12px 14px; }
  /* 输入栏触摸友好 */
  .e2ee-input-bar { padding: 8px 10px; gap: 6px; }
  .e2ee-input-bar textarea { font-size: 16px; min-height: 40px; padding: 10px 14px; }
  /* 移动端 placeholder：缩小字体、单行显示 */
  .e2ee-input-bar textarea::placeholder { font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: rgba(200,210,255,0.45); }
  .e2ee-tool-btn { width: 38px; height: 38px; font-size: 18px; }
  .e2ee-tools-menu { width: 186px; }
  .e2ee-send-btn { padding: 10px 18px; font-size: 15px; }
  .e2ee-active-header { padding: 10px 14px; font-size: 15px; }
  /* 富媒体 */
  .e2ee-media { max-width: 200px; }
  .e2ee-media img { max-width: 200px; }
  .e2ee-sticker { font-size: 38px; }
}
@media (max-width: 480px) {
  .e2ee-bubble { max-width: 88%; font-size: 15px; }
  .e2ee-send-btn { padding: 10px 14px; }
  .e2ee-conv-item { padding: 12px 10px; }
  .e2ee-avatar { width: 42px; height: 42px; font-size: 16px; }
}

/* ===== 群组 ===== */
.groups-modal-content {
  width: 600px; max-width: 92vw; max-height: 85vh;
  background: var(--card-bg, #1a1a2e); border-radius: 16px;
  display: flex; flex-direction: column; overflow: hidden;
  box-shadow: 0 8px 32px rgba(0,0,0,0.4); position: relative;
}
.groups-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px; border-bottom: 1px solid rgba(255,255,255,0.08);
}
.groups-header h3 { margin: 0; font-size: 18px; font-weight: 600; }
.groups-close {
  cursor: pointer; font-size: 20px; opacity: 0.6; transition: opacity 0.2s;
}
.groups-close:hover { opacity: 1; }
.groups-content {
  flex: 1; overflow-y: auto; padding: 20px;
}
.groups-toast {
  position: absolute; bottom: 20px; left: 50%; transform: translateX(-50%);
  background: rgba(0,0,0,0.8); color: #fff; padding: 8px 20px;
  border-radius: 20px; font-size: 14px; z-index: 100; white-space: nowrap;
}

/* Section header */
.gp-section-header {
  display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px;
}
.gp-section-header h3 { margin: 0; font-size: 16px; font-weight: 600; }
.gp-section-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* Buttons */
.gp-btn {
  padding: 8px 16px; border: none; border-radius: 8px; cursor: pointer;
  font-size: 14px; transition: all 0.2s; white-space: nowrap;
}
.gp-btn-primary { background: var(--accent-color, #667eea); color: #fff; }
.gp-btn-primary:hover { opacity: 0.85; }
.gp-btn-ghost { background: rgba(255,255,255,0.08); color: var(--text-color, #eee); }
.gp-btn-ghost:hover { background: rgba(255,255,255,0.15); }
.gp-btn-danger { background: #e74c3c; color: #fff; }
.gp-btn-danger:hover { opacity: 0.85; }
.gp-btn-sm { padding: 4px 12px; font-size: 12px; }
.gp-btn-block { width: 100%; margin-top: 12px; }
.gp-btn:disabled, .gp-disabled { opacity: 0.5; cursor: not-allowed; }

/* Group list */
.gp-group-list { display: flex; flex-direction: column; gap: 12px; }
.gp-group-card {
  display: flex; align-items: center; gap: 12px; padding: 12px;
  background: rgba(255,255,255,0.04); border-radius: 12px; cursor: pointer;
  transition: background 0.2s;
}
.gp-group-card:hover { background: rgba(255,255,255,0.08); }
.gp-group-avatar, .gp-detail-avatar, .gp-member-avatar {
  width: 48px; height: 48px; border-radius: 12px; flex-shrink: 0; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  background: var(--accent-color, #667eea); color: #fff; font-size: 20px; font-weight: 600;
}
.gp-avatar-img { width: 100%; height: 100%; object-fit: cover; }
.gp-avatar-letter { font-size: 20px; font-weight: 600; }
.gp-group-info { flex: 1; min-width: 0; }
.gp-group-name { font-weight: 600; font-size: 15px; margin-bottom: 2px; }
.gp-group-meta { font-size: 12px; opacity: 0.6; }
.gp-group-desc { font-size: 13px; opacity: 0.7; margin-top: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Role badges */
.gp-role-badge {
  display: inline-block; padding: 1px 6px; border-radius: 4px;
  font-size: 11px; font-weight: 600; margin-left: 4px; vertical-align: middle;
}
.gp-role-owner { background: #f39c12; color: #fff; }
.gp-role-admin { background: #3498db; color: #fff; }

/* Tags */
.gp-tag { padding: 4px 10px; border-radius: 12px; font-size: 12px; white-space: nowrap; }
.gp-tag-joined { background: rgba(46,204,113,0.2); color: #2ecc71; }

/* Empty / loading */
.gp-empty { text-align: center; padding: 40px 20px; opacity: 0.6; font-size: 14px; }
.gp-empty-hint { font-size: 12px; display: block; margin-top: 8px; opacity: 0.7; }
.gp-loading { text-align: center; padding: 20px; opacity: 0.5; }

/* Search bar */
.gp-search-bar { display: flex; gap: 8px; margin-bottom: 16px; }
.gp-search-bar input {
  flex: 1; padding: 10px 14px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.05); color: var(--text-color, #eee); font-size: 14px;
}

/* Join by code */
.gp-join-code-box { display: flex; gap: 8px; margin-bottom: 20px; }
.gp-join-code-box input {
  flex: 1; padding: 10px 14px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.05); color: var(--text-color, #eee); font-size: 16px;
  letter-spacing: 2px; text-align: center;
}

/* Form */
.gp-form { display: flex; flex-direction: column; gap: 16px; }
.gp-form-row { display: flex; flex-direction: column; gap: 6px; }
.gp-form-row label { font-size: 13px; opacity: 0.7; }
.gp-form-row input, .gp-form-row textarea {
  padding: 10px 14px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.05); color: var(--text-color, #eee); font-size: 14px;
  font-family: inherit; resize: vertical;
}
.gp-checkbox-label { flex-direction: row !important; align-items: center; gap: 8px !important; cursor: pointer; }
.gp-checkbox-label input { width: auto; }

/* Detail card */
.gp-detail-card {
  display: flex; gap: 16px; padding: 20px;
  background: rgba(255,255,255,0.04); border-radius: 12px; margin-bottom: 16px;
}
.gp-detail-avatar { width: 64px; height: 64px; border-radius: 16px; font-size: 26px; }
.gp-detail-info { flex: 1; }
.gp-detail-name { font-size: 18px; font-weight: 600; margin-bottom: 4px; }
.gp-detail-desc { font-size: 14px; opacity: 0.7; margin-bottom: 4px; }
.gp-detail-meta { font-size: 12px; opacity: 0.5; }
.gp-detail-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 20px; }

/* Share box */
.gp-share-box {
  padding: 16px; background: rgba(255,255,255,0.04); border-radius: 12px; margin-bottom: 20px;
}
.gp-share-title { font-weight: 600; font-size: 14px; margin-bottom: 12px; }
.gp-share-card {
  background: rgba(255,255,255,0.06); border-radius: 10px; padding: 12px; margin-bottom: 12px;
}
.gp-share-card-inner { display: flex; align-items: center; gap: 12px; }
.gp-share-card-avatar {
  width: 40px; height: 40px; border-radius: 10px; flex-shrink: 0; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  background: var(--accent-color, #667eea); color: #fff; font-size: 18px; font-weight: 600;
}
.gp-share-card-info { flex: 1; }
.gp-share-card-name { font-weight: 600; font-size: 14px; }
.gp-share-card-meta { font-size: 12px; opacity: 0.6; }
.gp-share-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* Invite code */
.gp-invite-section { margin: 20px 0; }
.gp-invite-code-box {
  display: flex; align-items: center; gap: 12px; padding: 12px 16px;
  background: rgba(255,255,255,0.04); border-radius: 10px;
}
.gp-invite-code {
  font-size: 22px; font-weight: 700; letter-spacing: 4px;
  font-family: monospace; color: var(--accent-color, #667eea);
}

/* Members */
.gp-members-section { margin-top: 20px; }
.gp-members-section h4 { font-size: 14px; margin: 0 0 12px 0; }
.gp-members-list { display: flex; flex-direction: column; gap: 8px; }
.gp-member-item {
  display: flex; align-items: center; gap: 10px; padding: 8px 12px;
  background: rgba(255,255,255,0.03); border-radius: 8px;
}
.gp-member-avatar { width: 32px; height: 32px; border-radius: 8px; font-size: 14px; }
.gp-member-name { flex: 1; font-size: 14px; }

/* Request list */
.gp-request-list { display: flex; flex-direction: column; gap: 12px; }
.gp-request-item {
  display: flex; align-items: center; gap: 10px; padding: 12px;
  background: rgba(255,255,255,0.04); border-radius: 10px;
}
.gp-request-info { flex: 1; min-width: 0; }
.gp-request-name { font-weight: 600; font-size: 14px; }
.gp-request-msg { font-size: 13px; opacity: 0.7; margin-top: 2px; font-style: italic; }
.gp-request-time { font-size: 11px; opacity: 0.5; margin-top: 2px; }

/* Danger zone */
.gp-danger-zone {
  margin-top: 24px; padding: 16px; border: 1px solid rgba(231,76,60,0.3);
  border-radius: 10px; background: rgba(231,76,60,0.05);
}
.gp-danger-zone h4 { color: #e74c3c; margin: 0 0 12px 0; font-size: 14px; }

/* QR overlay */
.gp-qr-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;
  z-index: 200;
}
.gp-qr-box {
  background: #fff; padding: 20px; border-radius: 16px; text-align: center; position: relative;
}
.gp-qr-close { position: absolute; top: 8px; right: 12px; cursor: pointer; font-size: 18px; color: #333; }
.gp-qr-box img { width: 200px; height: 200px; border-radius: 8px; }
.gp-qr-box p { margin: 8px 0 0 0; color: #333; font-size: 14px; }
.gp-qr-link { font-size: 11px !important; opacity: 0.6; word-break: break-all; }

/* Mobile */
@media (max-width: 768px) {
  .groups-modal-content { width: 100%; max-width: 100%; height: 100vh; border-radius: 0; }
  .groups-header { padding: 12px 14px; }
  .groups-header h3 { font-size: 17px; }
  .groups-content { padding: 14px; }
  .gp-section-actions { flex-direction: row; flex-wrap: wrap; gap: 6px; }
  .gp-section-header { margin-bottom: 12px; }
  .gp-section-header h3 { font-size: 15px; }
  .gp-btn { padding: 8px 14px; font-size: 13px; }
  .gp-share-actions { flex-direction: row; flex-wrap: wrap; gap: 6px; }
  .gp-share-actions .gp-btn { flex: 1; min-width: 0; text-align: center; }
  .gp-detail-actions { flex-direction: row; flex-wrap: wrap; gap: 6px; }
  .gp-detail-actions .gp-btn { flex: 1; min-width: 120px; text-align: center; }
  /* 详情卡片 */
  .gp-detail-card { padding: 14px; gap: 12px; margin-bottom: 12px; }
  .gp-detail-avatar { width: 52px; height: 52px; border-radius: 14px; font-size: 22px; }
  .gp-detail-name { font-size: 16px; }
  .gp-detail-desc { font-size: 13px; }
  /* 分享区 */
  .gp-share-box { padding: 12px; margin-bottom: 14px; }
  /* 成员列表 */
  .gp-members-section { margin-top: 16px; }
  .gp-member-item { padding: 8px 10px; }
  /* 群聊区高度自适应 */
  .gp-chat-section { margin-top: 16px; border-radius: 10px; }
  .gp-chat-messages { height: calc(100vh - 340px); min-height: 200px; }
  .gp-chat-header { padding: 10px 12px; }
  .gp-chat-header h4 { font-size: 14px; }
  .gp-chat-ai-hint { display: none; }
  /* 工具栏横向滚动 + 触摸友好 */
  .gp-chat-input-row { padding: 8px 10px; gap: 4px; flex-wrap: nowrap; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .gp-chat-tool-btn { width: 36px; height: 36px; font-size: 17px; flex-shrink: 0; }
  .gp-chat-tools-menu { width: 196px; }
  .gp-chat-input { font-size: 16px; padding: 10px 12px; min-width: 80px; }
  .gp-chat-input-row .gp-btn { padding: 10px 16px; font-size: 14px; flex-shrink: 0; }
  /* 表情面板 */
  .gp-chat-sticker-panel { max-width: 260px; bottom: 52px; left: 10px; }
}
@media (max-width: 480px) {
  .gp-group-card { padding: 10px; gap: 10px; }
  .gp-group-avatar, .gp-detail-avatar, .gp-member-avatar { width: 44px; height: 44px; }
  .gp-detail-actions .gp-btn { min-width: 0; flex: 1 1 100%; }
  .gp-share-actions .gp-btn { flex: 1 1 100%; }
  .gp-chat-messages { height: calc(100vh - 320px); min-height: 180px; }
  .gp-chat-input-row { gap: 3px; padding: 6px 8px; }
  .gp-chat-tool-btn { width: 34px; height: 34px; font-size: 16px; }
  .gp-chat-input { padding: 10px 10px; }
  .gp-chat-input-row .gp-btn { padding: 10px 14px; }
}

/* ===== 群聊 ===== */
.gp-chat-section {
  margin-top: 24px; border: 1px solid rgba(255,255,255,0.1); border-radius: 12px;
  overflow: hidden; background: rgba(255,255,255,0.02);
}
.gp-chat-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; background: rgba(255,255,255,0.04);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.gp-chat-header h4 { margin: 0; font-size: 14px; }
.gp-chat-ai-hint { font-size: 12px; opacity: 0.6; }
.gp-chat-ai-hint code {
  background: rgba(102,126,234,0.2); color: var(--accent-color, #667eea);
  padding: 1px 6px; border-radius: 4px; font-size: 12px;
}
.gp-chat-messages {
  height: 280px; overflow-y: auto; padding: 12px 14px;
  display: flex; flex-direction: column; gap: 8px;
}
.gp-chat-empty {
  text-align: center; padding: 40px 10px; opacity: 0.55; font-size: 13px; line-height: 1.8;
}
.gp-chat-empty code {
  background: rgba(102,126,234,0.2); color: var(--accent-color, #667eea);
  padding: 1px 6px; border-radius: 4px; font-size: 12px;
}
.gp-chat-msg {
  display: flex; flex-direction: column; max-width: 78%;
  align-items: flex-start;
}
.gp-chat-msg-mine { align-self: flex-end; align-items: flex-end; }
.gp-chat-msg-other { align-self: flex-start; align-items: flex-start; }
.gp-chat-msg-ai { align-self: center; align-items: center; max-width: 92%; }
.gp-chat-sender { font-size: 11px; opacity: 0.55; margin: 0 4px 3px; }
.gp-chat-bubble {
  padding: 8px 12px; border-radius: 12px; font-size: 14px; line-height: 1.55;
  word-break: break-word; white-space: pre-wrap;
  background: rgba(255,255,255,0.07); color: var(--text-color, #eee);
}
.gp-chat-msg-mine .gp-chat-bubble {
  background: var(--accent-color, #667eea); color: #fff;
  border-bottom-right-radius: 4px;
}
.gp-chat-msg-other .gp-chat-bubble { border-bottom-left-radius: 4px; }
.gp-chat-msg-ai .gp-chat-bubble {
  background: rgba(102,126,234,0.18); border: 1px solid rgba(102,126,234,0.35);
  border-radius: 14px; text-align: left;
}
.gp-chat-ai-tag {
  font-size: 10px; color: var(--accent-color, #667eea); margin-top: 3px;
  background: rgba(102,126,234,0.15); padding: 1px 8px; border-radius: 10px;
}
.gp-chat-input-row {
  display: flex; gap: 8px; padding: 10px 14px;
  border-top: 1px solid rgba(255,255,255,0.08); background: rgba(255,255,255,0.03);
}
.gp-chat-tools { position: relative; flex-shrink: 0; display: flex; align-items: center; }
.gp-chat-more-btn { font-weight: bold; font-size: 20px; }
.gp-chat-more-btn.active { border-color: var(--accent-color, #667eea); background: rgba(102,126,234,0.2); color: #fff; }
.gp-chat-tools-menu {
  position: absolute; bottom: 46px; left: 0; z-index: 60;
  display: flex; flex-wrap: wrap; gap: 6px; width: 220px;
  padding: 10px; border-radius: 12px;
  background: rgba(28,28,45,0.97); border: 1px solid rgba(255,255,255,0.14);
  box-shadow: 0 10px 28px rgba(0,0,0,0.45);
}
.gp-chat-tools-menu .gp-chat-tool-btn { width: 38px; height: 38px; font-size: 17px; }
.gp-chat-tool-btn {
  flex-shrink: 0; width: 34px; height: 34px; border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.06); color: var(--text-color, #eee);
  font-size: 16px; cursor: pointer; line-height: 1;
  display: inline-flex; align-items: center; justify-content: center;
}
.gp-chat-tool-btn:hover { border-color: var(--accent-color, #667eea); background: rgba(102,126,234,0.15); }
.gp-chat-input {
  flex: 1; padding: 10px 14px; border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.06); color: var(--text-color, #eee);
  font-size: 14px; outline: none;
}
.gp-chat-input:focus { border-color: var(--accent-color, #667eea); }
.gp-chat-input-row .gp-btn { flex-shrink: 0; }
/* 富媒体消息 */
.gp-chat-media { max-width: 100%; border-radius: 10px; display: block; margin-top: 2px; }
.gp-chat-image img { max-width: 240px; max-height: 240px; border-radius: 10px; cursor: zoom-in; object-fit: cover; display: block; }
.gp-chat-video { max-width: 280px; max-height: 260px; border-radius: 10px; background: #000; }
.gp-chat-file {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 12px; border-radius: 8px;
  background: rgba(102,126,234,0.15); color: var(--accent-color, #667eea);
  text-decoration: none; font-size: 13px; word-break: break-all;
}
.gp-chat-file:hover { background: rgba(102,126,234,0.28); }
.gp-chat-link {
  display: inline-flex; align-items: center; gap: 6px; max-width: 260px;
  padding: 8px 12px; border-radius: 8px;
  background: rgba(255,255,255,0.08); color: var(--accent-color, #667eea);
  text-decoration: none; font-size: 13px; word-break: break-all;
}
.gp-chat-link:hover { background: rgba(255,255,255,0.14); }
.gp-chat-sticker { font-size: 44px; line-height: 1.2; padding: 2px 4px; }
.gp-chat-text { word-break: break-word; white-space: pre-wrap; }
/* 表情面板 */
.gp-chat-sticker-panel {
  position: absolute; bottom: 58px; left: 14px; z-index: 30;
  display: flex; flex-wrap: wrap; gap: 4px; max-width: 300px;
  padding: 10px; border-radius: 12px;
  background: rgba(30,30,45,0.97); border: 1px solid rgba(255,255,255,0.14);
  box-shadow: 0 8px 24px rgba(0,0,0,0.4);
}
.gp-chat-sticker-item {
  font-size: 26px; cursor: pointer; padding: 3px; border-radius: 6px; line-height: 1;
  transition: transform 0.12s ease;
}
.gp-chat-sticker-item:hover { transform: scale(1.25); background: rgba(255,255,255,0.1); }
.gp-chat-section { position: relative; }

@media (max-width: 768px) {
  .gp-chat-msg { max-width: 85%; }
  .gp-chat-msg-ai { max-width: 94%; }
  .gp-chat-bubble { font-size: 15px; padding: 9px 13px; line-height: 1.5; }
  .gp-chat-sender { font-size: 12px; }
  .gp-chat-image img { max-width: 200px; max-height: 200px; }
  .gp-chat-video { max-width: 240px; max-height: 220px; }
}
@media (max-width: 480px) {
  .gp-chat-msg { max-width: 90%; }
  .gp-chat-bubble { font-size: 15px; }
}

/* ===== 群聊增强功能样式 ===== */
.gp-chat-header-tools { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.gp-chat-tool-icon {
  width: 28px; height: 28px; border-radius: 6px; border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.05); color: rgba(255,255,255,0.6); font-size: 13px;
  cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all 0.2s;
}
.gp-chat-tool-icon:hover { background: rgba(255,255,255,0.12); color: #fff; }
.gp-chat-tool-danger:hover { background: rgba(255,71,87,0.15); color: #ff6b6b; border-color: rgba(255,71,87,0.3); }

.gp-chat-search-bar {
  display: flex; gap: 6px; padding: 8px 0; margin-bottom: 4px;
}
.gp-chat-search-bar input {
  flex: 1; background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px; color: #e8eaff; padding: 6px 10px; font-size: 13px; outline: none;
}
.gp-chat-search-bar input:focus { border-color: rgba(0,212,255,0.5); }
.gp-chat-search-btn {
  width: 30px; height: 30px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.05); color: rgba(255,255,255,0.6); font-size: 13px;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
}
.gp-chat-search-btn:hover { background: rgba(255,255,255,0.12); color: #fff; }

.gp-chat-quote-bar {
  display: flex; align-items: center; gap: 6px; padding: 6px 10px; margin-bottom: 4px;
  background: rgba(0,212,255,0.08); border-left: 3px solid #00d4ff; border-radius: 6px;
}
.gp-chat-quote-label { font-size: 12px; color: #00d4ff; white-space: nowrap; }
.gp-chat-quote-text { flex: 1; font-size: 12px; color: rgba(200,210,255,0.7); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gp-chat-quote-cancel {
  width: 22px; height: 22px; border-radius: 6px; border: none;
  background: rgba(255,255,255,0.1); color: rgba(255,255,255,0.5); font-size: 12px; cursor: pointer;
}
.gp-chat-quote-cancel:hover { background: rgba(255,71,87,0.3); color: #fff; }

.gp-chat-quote-block {
  font-size: 12px; color: rgba(200,210,255,0.55); padding: 4px 8px; margin-bottom: 4px;
  border-left: 2px solid rgba(0,212,255,0.4); background: rgba(0,212,255,0.06); border-radius: 4px;
}

.gp-chat-msg-actions {
  display: flex; gap: 2px; opacity: 0; transition: opacity 0.15s; margin-top: 2px;
}
.gp-chat-msg:hover .gp-chat-msg-actions { opacity: 0.6; }
.gp-chat-msg-actions button {
  width: 22px; height: 22px; border-radius: 6px; border: none;
  background: rgba(255,255,255,0.08); color: rgba(255,255,255,0.5); font-size: 12px;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
}
.gp-chat-msg-actions button:hover { background: rgba(0,212,255,0.3); color: #fff; }

.gp-chat-msg-highlight {
  background: rgba(0,212,255,0.06); border-radius: 8px; padding: 2px 4px;
}

.gp-chat-collapsed .gp-chat-search-bar,
.gp-chat-collapsed .gp-chat-quote-bar,
.gp-chat-collapsed .gp-chat-messages,
.gp-chat-collapsed .gp-chat-input-row { display: none !important; }
.gp-chat-collapsed .gp-chat-bookmark-panel,
.gp-chat-collapsed .gp-chat-sticker-panel { display: none !important; }

/* ===== 群组语音消息样式 ===== */
.gp-chat-voice {
  display: flex; align-items: center; gap: 6px; min-width: 180px;
}
.gp-chat-voice-icon { font-size: 18px; }
.gp-chat-voice-player {
  flex: 1; height: 32px;
}
#gpVoiceBtn.recording {
  background: rgba(255,71,87,0.3) !important; color: #ff6b6b !important;
  animation: gp-voice-pulse 1s infinite;
}
@keyframes gp-voice-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

/* ===== 群组书签搜索面板样式 ===== */
.gp-chat-bookmark-panel {
  position: relative; background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px; padding: 8px; margin-bottom: 4px; max-height: 260px; overflow-y: auto;
}
.gp-bookmark-search-input {
  width: 100%; background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.1);
  border-radius: 6px; color: #e8eaff; padding: 6px 10px; font-size: 13px; outline: none; margin-bottom: 6px;
  box-sizing: border-box;
}
.gp-bookmark-search-input:focus { border-color: rgba(0,212,255,0.5); }
.gp-bookmark-list { display: flex; flex-direction: column; gap: 4px; }
.gp-bm-pick-item {
  display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 6px;
  cursor: pointer; transition: background 0.15s;
}
.gp-bm-pick-item:hover { background: rgba(0,212,255,0.1); }
.gp-bm-pick-icon {
  width: 28px; height: 28px; border-radius: 6px; display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700; color: #fff; flex-shrink: 0; overflow: hidden;
}
.gp-bm-pick-icon-img { width: 100%; height: 100%; object-fit: cover; border-radius: 6px; }
.gp-bm-pick-info { flex: 1; min-width: 0; }
.gp-bm-pick-name { font-size: 13px; color: #e8eaff; white-space: nowrap; text-overflow: ellipsis; overflow: hidden; }
.gp-bm-pick-url { font-size: 11px; color: rgba(200,210,255,0.4); white-space: nowrap; text-overflow: ellipsis; overflow: hidden; }

/* ===== 群组书签卡片消息样式 ===== */
.gp-chat-bookmark-card {
  display: flex; align-items: center; gap: 10px; text-decoration: none; color: #e8eaff;
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.12); border-radius: 10px;
  padding: 8px 12px; min-width: 200px; max-width: 280px; transition: all 0.2s;
}
.gp-chat-bookmark-card:hover { border-color: rgba(0,212,255,0.4); background: rgba(0,212,255,0.06); }
.gp-bm-card-icon {
  width: 36px; height: 36px; border-radius: 8px; display: flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 700; color: #fff; flex-shrink: 0; overflow: hidden;
}
.gp-bm-card-icon-img { width: 100%; height: 100%; object-fit: cover; border-radius: 8px; }
.gp-bm-card-info { flex: 1; min-width: 0; }
.gp-bm-card-name { font-size: 13px; font-weight: 600; white-space: nowrap; text-overflow: ellipsis; overflow: hidden; }
.gp-bm-card-url { font-size: 11px; color: rgba(200,210,255,0.4); white-space: nowrap; text-overflow: ellipsis; overflow: hidden; margin-top: 2px; }
.gp-bm-card-badge { font-size: 16px; flex-shrink: 0; }

/* ===== 密聊书签面板样式 ===== */
.e2ee-bookmark-panel {
  position: relative; background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px; padding: 8px; margin-bottom: 4px; max-height: 260px; overflow-y: auto;
}
.e2ee-bookmark-search-input {
  width: 100%; background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.1);
  border-radius: 6px; color: #e8eaff; padding: 6px 10px; font-size: 13px; outline: none; margin-bottom: 6px;
  box-sizing: border-box;
}
.e2ee-bookmark-search-input:focus { border-color: rgba(0,212,255,0.5); }
.e2ee-bookmark-list { display: flex; flex-direction: column; gap: 4px; }
.e2ee-bm-pick-item {
  display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 6px;
  cursor: pointer; transition: background 0.15s;
}
.e2ee-bm-pick-item:hover { background: rgba(0,212,255,0.1); }
.e2ee-bm-pick-icon {
  width: 28px; height: 28px; border-radius: 6px; display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700; color: #fff; flex-shrink: 0; overflow: hidden;
}
.e2ee-bm-pick-icon-img { width: 100%; height: 100%; object-fit: cover; border-radius: 6px; }
.e2ee-bm-pick-info { flex: 1; min-width: 0; }
.e2ee-bm-pick-name { font-size: 13px; color: #e8eaff; white-space: nowrap; text-overflow: ellipsis; overflow: hidden; }
.e2ee-bm-pick-url { font-size: 11px; color: rgba(200,210,255,0.4); white-space: nowrap; text-overflow: ellipsis; overflow: hidden; }

/* ===== 密聊书签卡片消息样式 ===== */
.e2ee-bookmark-card {
  display: flex; align-items: center; gap: 10px; text-decoration: none; color: #e8eaff;
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.12); border-radius: 10px;
  padding: 8px 12px; min-width: 200px; max-width: 280px; transition: all 0.2s;
}
.e2ee-bookmark-card:hover { border-color: rgba(0,212,255,0.4); background: rgba(0,212,255,0.06); }
.e2ee-bm-card-icon {
  width: 36px; height: 36px; border-radius: 8px; display: flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 700; color: #fff; flex-shrink: 0; overflow: hidden;
}
.e2ee-bm-card-icon-img { width: 100%; height: 100%; object-fit: cover; border-radius: 8px; }
.e2ee-bm-card-info { flex: 1; min-width: 0; }
.e2ee-bm-card-name { font-size: 13px; font-weight: 600; white-space: nowrap; text-overflow: ellipsis; overflow: hidden; }
.e2ee-bm-card-url { font-size: 11px; color: rgba(200,210,255,0.4); white-space: nowrap; text-overflow: ellipsis; overflow: hidden; margin-top: 2px; }
.e2ee-bm-card-badge { font-size: 16px; flex-shrink: 0; }

/* ===== 书签右键分享菜单样式 ===== */
.bookmark-share-menu {
  position: fixed; z-index: 10000; width: 200px; background: rgba(30,30,50,0.98);
  backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.15); border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0,0,0,0.5); padding: 8px; animation: bm-share-fadein 0.15s ease;
}
@keyframes bm-share-fadein {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}
.bookmark-share-header {
  display: flex; align-items: center; gap: 6px; padding: 6px 8px; margin-bottom: 4px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.bookmark-share-icon { font-size: 14px; }
.bookmark-share-title {
  flex: 1; font-size: 13px; color: #e8eaff; white-space: nowrap; text-overflow: ellipsis; overflow: hidden;
}
.bookmark-share-close {
  width: 20px; height: 20px; border-radius: 4px; cursor: pointer; font-size: 12px;
  color: rgba(255,255,255,0.4); display: flex; align-items: center; justify-content: center;
}
.bookmark-share-close:hover { background: rgba(255,71,87,0.3); color: #fff; }
.bookmark-share-items { display: flex; flex-direction: column; gap: 2px; }
.bookmark-share-item {
  display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-radius: 8px;
  cursor: pointer; font-size: 13px; color: rgba(230,235,255,0.8); transition: all 0.15s;
}
.bookmark-share-item:hover { background: rgba(0,212,255,0.12); color: #fff; }
.bookmark-share-item-icon { font-size: 16px; width: 20px; text-align: center; }

/* ===== 书签分享二维码弹窗 ===== */
.bookmark-qr-overlay {
  position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: 10001;
  background: rgba(0,0,0,0.6); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center;
}
.bookmark-qr-box {
  background: rgba(30,30,50,0.98); border: 1px solid rgba(255,255,255,0.15); border-radius: 16px;
  padding: 24px; text-align: center; position: relative;
  box-shadow: 0 10px 50px rgba(0,0,0,0.5);
}
.bookmark-qr-box img { border-radius: 12px; border: 2px solid rgba(255,255,255,0.1); }
.bookmark-qr-box p { margin: 12px 0 0; font-size: 14px; color: #e8eaff; }
.bookmark-qr-name { font-size: 12px !important; color: rgba(200,210,255,0.5) !important; word-break: break-all; max-width: 280px; }
.bookmark-qr-close {
  position: absolute; top: 8px; right: 10px; font-size: 18px; color: rgba(255,255,255,0.4);
  cursor: pointer; transition: color 0.15s;
}
.bookmark-qr-close:hover { color: #fff; }

/* 群组书签面板也需折叠 */
.gp-chat-collapsed .gp-chat-bookmark-panel { display: none !important; }

@media (max-width: 600px) {
  .bookmark-share-menu { width: 180px; }
  .gp-chat-bookmark-card, .e2ee-bookmark-card { min-width: 160px; max-width: 220px; }
}
