/* ============================================================
   口子的灵感库 · 样式表
   对标花瓣网 · 柔粉色点缀 · 简约高级现代图库风格
   ============================================================ */

/* ========== 1. CSS 变量（设计 Token） ========== */
:root {
  /* 主强调色：柔粉（仅用于点缀，不过度使用） */
  --pink:       #ff8fa3;
  --pink-hover: #ff6b82;
  --pink-subtle: rgba(255,143,163,.10);
  --pink-border: rgba(255,143,163,.30);

  /* 底色：纯白 / 极浅灰白，干净为主 */
  --bg:         #ffffff;
  --bg-sub:     #f8f8f8;
  --bg-card:    #ffffff;

  /* 文字：深灰 / 浅灰分层，不使用浓重纯黑 */
  --text:       #3a3a3a;
  --text-light: #8a8a8a;
  --text-xlight:#b0b0b0;

  /* 边框与阴影 */
  --border:     #e8e8e8;
  --border-hi:  #d0d0d0;
  --shadow-xs:  0 1px 4px rgba(0,0,0,.05);
  --shadow-sm:  0 2px 8px rgba(0,0,0,.07);
  --shadow-md:  0 4px 20px rgba(0,0,0,.09);
  --shadow-lg:  0 8px 40px rgba(0,0,0,.12);

  /* 圆角 */
  --r-sm:   6px;
  --r-md:   10px;
  --r-lg:   14px;
  --r-xl:   20px;
  --r-full: 999px;
}

/* ========== 2. 基础重置 ========== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: "Microsoft YaHei", "PingFang SC", -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

/* ============================================================
   2026-08 UI refresh · 灵感档案
   只覆盖视觉表现，不改变页面功能与数据结构
   ============================================================ */
:root {
  --pink: #d890a2;
  --pink-hover: #c9788e;
  --pink-subtle: #fff2f5;
  --pink-border: #f0d6dc;
  --bg: #ffffff;
  --bg-sub: #f7f5f6;
  --bg-card: #ffffff;
  --text: #373135;
  --text-light: #81777c;
  --text-xlight: #a89ea3;
  --border: #e9e1e3;
  --border-hi: #d9ced1;
  --shadow-xs: 0 1px 4px rgba(77, 55, 64, .045);
  --shadow-sm: 0 5px 18px rgba(77, 55, 64, .075);
  --shadow-md: 0 12px 32px rgba(77, 55, 64, .095);
  --r-sm: 8px;
  --r-md: 11px;
  --r-lg: 16px;
  --r-xl: 22px;
}

body,
button,
input,
textarea,
select {
  font-family: "Microsoft YaHei", "PingFang SC", sans-serif;
}

body { background: #faf9f9; }

.daily-quote-section,
.daily-quote-section * {
  font-family: SimSun, "Songti SC", serif;
}

.navbar {
  background: rgba(255, 255, 255, .94);
  border-color: var(--border);
  box-shadow: 0 1px 0 rgba(89, 61, 71, .02);
}

.navbar > .container { min-height: 66px; }

.brand-logo-image {
  width: 40px;
  height: 40px;
  margin-right: 2px;
  border-radius: 0;
  object-fit: contain;
  flex: 0 0 auto;
}

.logo {
  gap: 8px;
  color: var(--text);
  letter-spacing: .01em;
}

.logo span { color: var(--text); }

.nav-search input {
  height: 38px;
  background: #f7f5f6;
  border-color: #ebe3e5;
}

.btn {
  min-height: 38px;
  border-radius: 9px;
  font-weight: 600;
  letter-spacing: .01em;
  transition: border-color .2s, background .2s, color .2s, box-shadow .2s, transform .2s;
}

.btn:hover { transform: translateY(-1px); }
.btn-primary { box-shadow: 0 7px 18px rgba(201, 120, 142, .22); }
.btn-secondary { background: #fff; border-color: var(--border-hi); }

.project-card {
  border-radius: 17px;
  border-color: var(--border);
  box-shadow: 0 5px 18px rgba(77, 55, 64, .055);
}

.project-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 36px rgba(77, 55, 64, .11);
}

.project-card .project-info { padding: 13px 16px 14px; }
.project-title-row { justify-content: flex-start; align-items: flex-start; margin-bottom: 5px; }
.project-info h3 { color: var(--text); font-weight: 700; letter-spacing: .01em; }
.project-count { top: 2px; transform: none; }
.project-info p { min-height: 38px; line-height: 1.55; }
.project-material-count { display: inline-flex; align-items: center; gap: 4px; }
.ui-icon { width: 18px; height: 18px; flex-shrink: 0; object-fit: contain; }
.ui-icon-sm { width: 15px; height: 15px; }
.admin-brand-mark { width: 18px; height: 18px; object-fit: contain; }

/* 项目页顶部：方案 3「灵感档案」 */
.project-detail-header.is-archive {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  min-height: 154px;
  margin: 26px 0 22px;
  padding: 26px 30px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: 0 12px 36px rgba(77, 55, 64, .055);
  overflow: hidden;
}

.project-detail-header.is-archive::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 180px;
  height: 3px;
  background: linear-gradient(90deg, transparent, #e8aebc);
}

.project-heading-group {
  position: relative;
  min-width: 0;
  padding: 0 0 0 20px;
  text-align: left;
  border-left: 1px solid #d9c8cc;
}

.project-heading-group::before {
  content: "";
  position: absolute;
  left: -2px;
  top: 31px;
  width: 3px;
  height: 40px;
  border-radius: 3px;
  background: #e3a2b2;
}

.project-archive-label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  color: #aa7f89;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .18em;
}

.project-sparkle {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.55;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.project-name-line {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.project-heading-group .project-name-line h2 {
  max-width: 100%;
  margin: 0;
  color: var(--text);
  font-size: clamp(30px, 3vw, 40px);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: .055em;
  overflow-wrap: anywhere;
}

.project-category-label {
  flex: 0 0 auto;
  padding: 4px 9px;
  color: #bd7387;
  background: #fff2f5;
  border: 1px solid #f1d8de;
  border-radius: 999px;
  font-size: 12px;
  line-height: 1.4;
}

.project-heading-group .project-description {
  margin: 7px 0 0;
  color: var(--text-light);
  font-size: 13px;
  line-height: 1.55;
}

.project-heading-group .project-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
  color: var(--text-xlight);
  font-size: 12px;
}

.project-heading-group .badge {
  padding: 0;
  color: var(--text-xlight);
  background: transparent;
  border: 0;
  font-weight: 400;
}

.project-meta-dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #d0c3c7;
}

.project-detail-header.is-archive .project-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 9px;
  flex: 0 0 auto;
  flex-wrap: nowrap;
}

.project-detail-header.is-archive .project-actions .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
}

.project-detail-header.is-archive .project-actions img { opacity: .72; }
.project-detail-header.is-archive .project-actions .btn-primary img { filter: brightness(0) invert(1); opacity: 1; }

@media (max-width: 768px) {
  .brand-logo-image { width: 36px; height: 36px; }
  .project-detail-header.is-archive {
    align-items: stretch;
    flex-direction: column;
    gap: 22px;
    min-height: 0;
    margin: 18px 0;
    padding: 23px 20px 20px;
  }
  .project-heading-group { padding-left: 16px; }
  .project-heading-group::before { top: 29px; height: 36px; }
  .project-heading-group .project-name-line h2 { font-size: 31px; }
  .project-name-line { align-items: flex-start; flex-wrap: wrap; gap: 9px; }
  .project-detail-header.is-archive .project-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 100%;
  }
  .project-detail-header.is-archive .project-actions .btn-primary { grid-column: 1 / -1; }
}

@media (prefers-reduced-motion: reduce) {
  .project-card,
  .btn { transition: none; }
}
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
img { display: block; max-width: 100%; }
input, textarea, select { font-family: inherit; }

/* ========== 3. 页面容器 ========== */
.page-wrapper { min-height: 100vh; display: flex; flex-direction: column; }
.container {
  max-width: 1320px;
  margin: 0 auto;
  width: 100%;
  padding: 0 28px;
  position: relative; /* 移动端 .nav-actions-mobile 绝对定位的包含块（相对于 container，而非整条 navbar） */
}
.main-content { flex: 1; }

/* ========== 4. 顶部导航栏 ========== */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg);           /* 纯白底，无整块粉色 */
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.navbar > .container {
  display: flex;
  align-items: center;
  gap: 20px;
  padding-top: 13px;
  padding-bottom: 13px;
  flex-wrap: nowrap;
}

/* 站点名称：柔粉色 */
.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 18px;
  font-weight: 700;
  color: var(--pink);             /* 粉色强调——网站标题 */
  flex-shrink: 0;
  letter-spacing: -.3px;
}
.logo-icon {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: var(--pink-subtle);
  border: 1px solid var(--pink-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: var(--pink);
}
.logo span { color: var(--pink); }

/* 导航搜索框：细线边框，聚焦粉色 */
.nav-search {
  flex: 1;
  min-width: 180px;
  max-width: 420px;
  position: relative;
}
.nav-search input {
  width: 100%;
  height: 36px;
  padding: 0 16px 0 38px;
  border: 1.5px solid var(--border);
  border-radius: var(--r-full);
  background: var(--bg-sub);
  font-size: 13.5px;
  color: var(--text);
  outline: none;
  transition: border-color .2s, background .2s, box-shadow .2s;
}
.nav-search input::placeholder { color: var(--text-xlight); }
.nav-search input:focus {
  background: var(--bg);
  border-color: var(--pink);
  box-shadow: 0 0 0 3px var(--pink-subtle);
}
.nav-search-icon {
  position: absolute;
  left: 13px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-xlight);
  font-size: 14px;
  pointer-events: none;
}

/* 导航链接与操作 */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  margin-left: auto;
}
.nav-link {
  height: 34px;
  padding: 0 13px;
  border-radius: var(--r-md);
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: color .2s, background .2s;
  cursor: pointer;
  white-space: nowrap;
  position: relative;
}
.nav-link:hover {
  color: var(--pink-hover);
  background: var(--pink-subtle);
}
.nav-link.is-pink { color: var(--pink); }
.nav-link.is-pink:hover { color: var(--pink-hover); }

/* 下拉菜单 */
.nav-dropdown {
  position: relative;
}
.nav-dropdown-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 200px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg);
  padding: 14px 6px 6px;   /* 顶部 padding 吸收视觉间隙，避免 hover 断层 */
  display: none;
  z-index: 200;
}
.nav-dropdown-menu::before {
  content: '';
  position: absolute;
  top: -6px;
  left: 0; right: 0;
  height: 14px;
  background: transparent;
}
.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown-menu.show { display: block; }
.nav-dropdown-item {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 9px 12px;
  border-radius: var(--r-sm);
  font-size: 13.5px;
  color: var(--text);
  cursor: pointer;
  transition: background .15s, color .15s;
  border: none;
  width: 100%;
  text-align: left;
}
.nav-dropdown-item:hover {
  background: var(--pink-subtle);
  color: var(--pink-hover);
}
.nav-dropdown-divider {
  height: 1px;
  background: var(--border);
  margin: 5px 0;
}

/* 通知图标 */
.nav-icon-btn {
  width: 34px;
  height: 34px;
  border-radius: var(--r-md);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: var(--text-light);
  transition: color .2s, background .2s;
  cursor: pointer;
  position: relative;
}
.nav-icon-btn:hover { color: var(--pink-hover); background: var(--pink-subtle); }
.nav-badge {
  position: absolute;
  top: 3px;
  right: 3px;
  min-width: 16px;
  height: 16px;
  background: var(--pink-hover);
  color: white;
  font-size: 10px;
  font-weight: 700;
  border-radius: var(--r-full);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 3px;
  line-height: 1;
}

/* 通用按钮 - 花瓣胶囊圆角规范 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 24px;
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s;
  border: 1px solid transparent;
  text-align: center;
  white-space: nowrap;
  line-height: 1.4;
}
/* 主按钮 - 粉色填充 */
.btn-primary {
  background: #f8b8c8;
  color: #fff;
  border: none;
}
.btn-primary:hover {
  background: var(--pink-hover);
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(255,107,130,.30);
}
/* 次要按钮 - 白底+细边框 */
.btn-secondary,
.btn-default {
  background: #fff;
  color: #333;
  border: 1px solid #ddd;
}
.btn-secondary:hover,
.btn-default:hover {
  border-color: #f8b8c8;
  color: var(--pink-hover);
  background: #fff5f7;
}
/* 文字链接按钮 - 无边框无背景 */
.btn-text {
  background: transparent;
  color: var(--pink);
  padding: 10px 14px;
  border-radius: 999px;
}
.btn-text:hover { background: var(--pink-subtle); }
/* 高危按钮 - 浅红边框 */
.btn-danger {
  background: transparent;
  color: #e84141;
  border: 1px solid #f5c6c6;
}
.btn-danger:hover {
  background: #fff5f5;
  border-color: #e84141;
  color: #c62828;
}
/* 高危按钮 - 实心红（确认删除等关键操作） */
.btn-danger-solid {
  background: #e84141;
  color: #fff;
  border: none;
}
.btn-danger-solid:hover {
  background: #c62828;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(232,65,65,.30);
}
.btn-sm { padding: 6px 16px; font-size: 12.5px; border-radius: 999px; }
.btn-lg { padding: 13px 32px; font-size: 15px; border-radius: 999px; }
.btn-block { width: 100%; }
.btn-icon {
  width: 36px; height: 36px; padding: 0;
  border-radius: 50%;
  border: 1px solid #e8e8e8;
  background: #fff;
  color: #555;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all .2s;
}
.btn-icon:hover { border-color: #f8b8c8; color: var(--pink-hover); background: #fff5f7; }
.btn-icon-danger {}
.btn-icon-danger:hover { border-color: #e84141; color: #e84141; background: #fff5f5; }
.card-footer-actions { display: flex; gap: 6px; flex-shrink: 0; align-items: center; }


.nav-caret { font-size: 10px; opacity: .6; margin-left: 2px; }
.nav-link.is-caret::after { content: '▾'; font-size: 10px; opacity: .55; margin-left: 3px; }

/* ========== 5. Hero 区 ========== */
.hero {
  text-align: center;
  padding: 52px 24px 36px;
  background: var(--bg);
}
.hero h1 {
  font-size: 40px;
  font-weight: 800;
  letter-spacing: -.8px;
  margin-bottom: 12px;
  /* 标题渐变粉色 */
  background: linear-gradient(120deg, var(--pink-hover) 0%, var(--pink) 60%, #ffb3c1 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero p {
  font-size: 16px;
  color: var(--text-light);
  max-width: 560px;
  margin: 0 auto 28px;
  line-height: 1.7;
}
.hero-tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  max-width: 640px;
}
.hero-tag {
  padding: 7px 16px;
  background: var(--bg-sub);
  border: 1px solid var(--border);
  border-radius: var(--r-full);
  font-size: 13px;
  color: var(--text-light);
  cursor: pointer;
  transition: all .2s;
}
.hero-tag:hover {
  border-color: var(--pink-border);
  color: var(--pink-hover);
  background: var(--pink-subtle);
}

/* ========== 6. 筛选条 ========== */
.filter-bar {
  max-width: 1320px;
  margin: 0 auto;
  padding: 14px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}
.filter-pills { display: flex; gap: 8px; flex-wrap: wrap; }
.pill {
  height: 32px;
  padding: 0 14px;
  border-radius: var(--r-full);
  font-size: 13px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  color: var(--text-light);
  cursor: pointer;
  transition: all .2s;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.pill:hover { color: var(--pink-hover); border-color: var(--pink-border); background: var(--pink-subtle); }
.pill.active { background: var(--pink); color: white; border-color: var(--pink); }
.pill .badge { font-size: 11px; opacity: .75; }

/* ========== 7. 瀑布流 ========== */
.waterfall {
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  padding: 8px 0 80px;
  column-count: 4;
  column-gap: 16px;
}
@media (max-width: 1100px) { .waterfall { column-count: 3; } }
@media (max-width: 720px)  { .waterfall { column-count: 2; padding: 8px 0 80px; } }
@media (max-width: 420px)  { .waterfall { column-count: 1; } }

/* ========== 8. 瀑布流卡片 ========== */
.card {
  break-inside: avoid;
  margin-bottom: 16px;
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-xs);
  cursor: pointer;
  transition: transform .25s ease, box-shadow .25s ease;
  position: relative;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}
.card-img {
  width: 100%;
  display: block;
  position: relative;
}

/* 确保卡片内图片等比例、不溢出、圆角裁切 */
.waterfall .card > img,
.card > img {
  width: 100%;
  height: auto;
  display: block;
  background: var(--bg-sub);
}
/* hover 时图片稍变亮 */
.card:hover .card-img { filter: brightness(1.03); }

/* 卡片悬浮时渐变遮罩 */
.card-img::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 50%, rgba(0,0,0,.38) 100%);
  opacity: 0;
  transition: opacity .25s;
}
.card:hover .card-img::after { opacity: 1; }

/* 卡片操作按钮 */
.card-actions {
  position: absolute;
  top: 9px;
  right: 9px;
  display: flex;
  gap: 6px;
  opacity: 0;
  transition: opacity .2s;
  z-index: 2;
}
.card:hover .card-actions { opacity: 1; }
.action-btn {
  width: 30px; height: 30px;
  background: rgba(255,255,255,.92);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  color: var(--text);
  box-shadow: var(--shadow-sm);
  transition: all .15s;
}
.action-btn:hover { background: var(--pink); color: white; transform: scale(1.12); }
.action-btn.liked { background: var(--pink); color: white; }

/* 私有项目锁图标 */
.card-private-badge {
  position: absolute;
  top: 9px;
  left: 9px;
  width: 24px;
  height: 24px;
  background: rgba(255,255,255,.88);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  z-index: 2;
  backdrop-filter: blur(4px);
}

/* 卡片信息 */
.card-info { padding: 10px 12px 11px; }
.card-title {
  font-size: 13px;
  color: var(--text);
  font-weight: 500;
  margin-bottom: 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: color .2s;
}
.card:hover .card-title { color: var(--pink-hover); }
.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-xlight);
}

/* 卡片内：素材编号（INS000001） */
.card-serial {
  position: absolute;
  top: 4px;
  left: 4px;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 9px;
  font-family: monospace;
  padding: 1px 4px;
  border-radius: 3px;
  z-index: 3;
  pointer-events: none;
  opacity: 0.75;
}

/* 卡片内：灵感备注（简短，截断） */
.card-note {
  padding: 6px 12px 0;
  font-size: 12px;
  color: var(--text-light);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* 卡片内：我的笔记（仅自己可见，粉色调，最多 2 行截断） */
.card-mynote {
  padding: 6px 12px 10px;
  font-size: 12px;
  line-height: 1.45;
  color: var(--pink, #ff8fa3);
  background: rgba(255, 143, 163, 0.08);
  border-top: 1px solid var(--border);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* 预览面板：我的笔记正文 */
.preview-panel-note.is-mynote {
  color: var(--pink, #ff8fa3);
  background: rgba(255, 143, 163, 0.06);
  border-radius: var(--radius-sm, 8px);
  padding: 6px 8px;
}

/* 选中态 */
.card.selected { outline: 2px solid var(--pink); outline-offset: 2px; }
.card-select {
  position: absolute;
  top: 10px; right: 10px;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .92);
  border: 2px solid var(--pink);
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: white;
  box-shadow: 0 2px 8px rgba(71, 52, 60, .18);
}
.card-select.checked { background: var(--pink); }
.card-select.checked::after {
  content: '✓';
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
}

/* 占位图（渐变色） */
.placeholder {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 52px;
}
.placeholder-1  { background: linear-gradient(135deg,#ff9a9e,#fad0c4); height:260px; }
.placeholder-2  { background: linear-gradient(135deg,#a18cd1,#fbc2eb); height:340px; }
.placeholder-3  { background: linear-gradient(135deg,#fad0c4,#ffd1ff); height:200px; }
.placeholder-4  { background: linear-gradient(135deg,#ffecd2,#fcb69f); height:300px; }
.placeholder-5  { background: linear-gradient(135deg,#84fab0,#8fd3f4); height:240px; }
.placeholder-6  { background: linear-gradient(135deg,#cfd9df,#e2ebf0); height:380px; }
.placeholder-7  { background: linear-gradient(135deg,#a1c4fd,#c2e9fb); height:260px; }
.placeholder-8  { background: linear-gradient(135deg,#fbc2eb,#a6c1ee); height:320px; }
.placeholder-9  { background: linear-gradient(135deg,#ffd26f,#ff8a65); height:280px; }
.placeholder-10 { background: linear-gradient(135deg,#43e97b,#38f9d7); height:300px; }
.placeholder-11 { background: linear-gradient(135deg,#fa709a,#fee140); height:220px; }
.placeholder-12 { background: linear-gradient(135deg,#30cfd0,#330867); height:360px; }

/* ========== 9. 项目卡片（首页 / Dashboard） ========== */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}
.project-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
  transition: transform .25s ease, box-shadow .25s ease;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  box-shadow: var(--shadow-xs);
}
.project-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--pink-border);
}
.project-header {
  padding: 16px 18px 12px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}
.project-info { flex: 1; min-width: 0; }
.project-info h3 {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: color .2s;
}
.project-card:hover .project-info h3 { color: var(--pink-hover); }
.project-meta { font-size: 12px; color: var(--text-xlight); display: flex; align-items: center; gap: 6px; }
.project-desc {
  padding: 0 18px 12px;
  font-size: 13px;
  color: var(--text-light);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.project-footer {
  padding: 10px 18px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-xlight);
  margin-top: auto;
}
.project-footer .project-name-link { color: var(--pink); }
.project-footer .project-name-link:hover { color: var(--pink-hover); }

/* 素材网格 */
.materials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 14px;
}
.material-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  overflow: hidden;
  transition: transform .25s, box-shadow .25s;
  cursor: pointer;
  box-shadow: var(--shadow-xs);
}
.material-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--pink-border);
}
.material-card img { width: 100%; display: block; aspect-ratio: 1/1; object-fit: cover; background: var(--bg-sub); }

/* ========== 10. Dashboard 布局 ========== */
.dashboard-layout {
  display: flex;
  max-width: 1320px;
  margin: 0 auto;
  min-height: calc(100vh - 60px);
  gap: 0;
}
.sidebar {
  width: 220px;
  flex-shrink: 0;
  background: var(--bg);
  border-right: 1px solid var(--border);
  padding: 22px 14px;
}
.sidebar-title {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-xlight);
  text-transform: uppercase;
  letter-spacing: .8px;
  padding: 0 8px;
  margin-bottom: 8px;
}
.sidebar-new-btn { width: 100%; margin-bottom: 14px; }
.project-list { list-style: none; }
.project-item {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 9px 10px;
  border-radius: var(--r-sm);
  cursor: pointer;
  transition: background .15s, color .15s;
  font-size: 13.5px;
  color: var(--text);
}
.project-item:hover { background: var(--pink-subtle); color: var(--pink-hover); }
.project-item.active { background: var(--pink-subtle); color: var(--pink-hover); font-weight: 600; }
.project-item-icon { width: 26px; height: 26px; border-radius: 6px; flex-shrink: 0; }
.project-item-name { flex: 1; min-width: 0; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.project-item-count { font-size: 11px; color: var(--text-xlight); flex-shrink: 0; }
.dashboard-main { flex: 1; padding: 24px 28px; min-width: 0; }
.dashboard-topbar {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 20px; flex-wrap: wrap; gap: 12px;
}
.dashboard-topbar h2 { font-size: 20px; font-weight: 700; }
.batch-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* ========== 11. 表单元素 ========== */
.form-group { margin-bottom: 18px; }
.form-group label {
  display: block;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 7px;
}
.form-group input[type="text"],
.form-group input[type="password"],
.form-group input[type="url"],
.form-group input[type="file"],
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--r-md);
  font-size: 14px;
  font-family: inherit;
  background: var(--bg);
  color: var(--text);
  outline: none;
  transition: border-color .2s, box-shadow .2s;
}
.form-group input::placeholder { color: var(--text-xlight); }
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--pink);
  box-shadow: 0 0 0 3px var(--pink-subtle);
}
textarea.form-group { min-height: 90px; resize: vertical; }
select.form-group {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%238a8a8a' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 32px;
}
.form-hint { display: block; margin-top: 5px; font-size: 12px; color: var(--text-xlight); }
.form-error { display: block; margin-top: 5px; font-size: 12px; color: #e84141; }
.form-actions { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--border); }

/* 复选框 */
.checkbox-label {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13.5px; color: var(--text-light); cursor: pointer;
}
.checkbox-label input[type="checkbox"] {
  width: 16px; height: 16px;
  accent-color: var(--pink);
  cursor: pointer;
}

/* ========== 12. 弹窗 ========== */
.modal {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.52);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal.show, .modal.open, .modal.active { display: flex; z-index: 9999; }
.modal-content {
  background: var(--bg);
  border-radius: var(--r-xl);
  max-width: 90vw;
  max-height: 90vh;
  position: relative;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-lg);
  overflow: visible;
  z-index: 1;
}
.modal-close {
  position: absolute;
  top: 12px; right: 12px;
  width: 32px; height: 32px;
  border-radius: 50%;
  border: none;
  background: rgba(0,0,0,.06);
  color: var(--text);
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  transition: background .2s;
}
.modal-close:hover { background: rgba(0,0,0,.14); }
.modal-title {
  padding: 20px 22px 0;
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
}
.modal-body { padding: 16px 22px; overflow-y: auto; flex: 1; }
.modal-footer {
  padding: 14px 22px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}
.modal-form {
  background: var(--bg);
  border-radius: var(--r-xl);
  padding: 28px;
  min-width: 340px;
  max-width: 460px;
  box-shadow: var(--shadow-lg);
  z-index: 1;
  position: relative;
}

/* ========== 13. 大图预览弹窗 ========== */
.preview-modal {
  background: rgba(0,0,0,.80);
  padding: 28px;
}
.preview-modal .modal-close {
  background: rgba(255,255,255,.18);
  color: white;
  top: 20px; right: 24px;
  width: 40px; height: 40px;
  font-size: 22px;
  backdrop-filter: blur(6px);
}
.preview-modal .modal-close:hover { background: rgba(255,255,255,.32); }

.preview-box {
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border-radius: var(--r-xl);
  box-shadow: 0 20px 60px rgba(0,0,0,.40);
  max-width: min(960px, 92vw);
  max-height: 90vh;
  overflow: hidden;
}
.preview-stage {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #faf7f8;
  padding: 20px 72px;
  min-height: 300px;
  flex-shrink: 0;
}
#preview-image {
  max-width: 100%;
  max-height: 60vh;
  object-fit: contain;
  border-radius: var(--r-md);
  display: none;
}
.preview-loading { display: flex; align-items: center; justify-content: center; height: 280px; font-size: 14px; color: var(--text-xlight); }

.preview-nav {
  position: absolute;
  top: 50%; transform: translateY(-50%);
  width: 44px; height: 44px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,.92);
  color: var(--text);
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .2s;
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(4px);
}
.preview-prev { left: 16px; }
.preview-next { right: 16px; }
.preview-nav:hover:not(:disabled) {
  background: var(--pink);
  color: white;
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 4px 14px rgba(255,107,130,.35);
}
.preview-nav:disabled {
  opacity: .28;
  cursor: not-allowed;
  background: rgba(255,255,255,.6);
  color: #aaa;
}

.preview-panel {
  border-top: 1px solid var(--border);
  padding: 16px 22px;
  overflow-y: auto;
  max-height: 26vh;
  background: var(--bg);
}
.preview-panel-block { margin-bottom: 12px; text-align: center; }
.preview-panel-block:last-child { margin-bottom: 0; }
/* 预览弹窗：编号文字（可点击复制） */
.preview-serial-number {
  color: var(--pink, #ff8fa3);
  transition: opacity 0.15s;
  user-select: none;
}
.preview-serial-number:hover {
  opacity: 0.7;
  text-decoration: underline;
}
.preview-panel-label {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--pink);              /* 粉色标签 */
  letter-spacing: .5px;
  margin-bottom: 5px;
  text-align: center;
}
.preview-panel-note { font-size: 13.5px; line-height: 1.65; color: var(--text); white-space: pre-wrap; word-break: break-word; text-align: center; }
.preview-panel-note.is-empty { color: var(--text-xlight); font-style: italic; }
.preview-panel-source { font-size: 13.5px; color: #5b8def; text-decoration: none; word-break: break-all; line-height: 1.6; display: inline-block; }
.preview-panel-source:hover { text-decoration: underline; }
.preview-panel-actions { display: flex; gap: 8px; margin-top: 12px; padding-top: 12px; border-top: 1px dashed var(--border); justify-content: center; }

/* 项目内搜索栏 */
.project-search {
  display: flex; gap: 8px;
  margin: 8px 0 18px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--r-lg);
  padding: 6px 10px;
  transition: border-color .2s;
}
.project-search:focus-within { border-color: var(--pink); }
.project-search input {
  flex: 1; border: none; padding: 6px 10px;
  font-size: 13.5px; background: transparent;
  color: var(--text); outline: none;
}
.project-search input::placeholder { color: var(--text-xlight); }

@media (max-width: 768px) {
  .project-search {
    flex-direction: column;
    padding: 12px;
    gap: 10px;
  }
  .project-search input {
    width: 100%;
    min-width: 0;
    padding: 12px 10px;
    font-size: 14px;
    border-bottom: 1px solid var(--border);
  }
  .project-search .btn-row {
    display: flex;
    gap: 10px;
    width: 100%;
  }
  .project-search .btn {
    flex: 1;
    justify-content: center;
    padding: 10px 16px;
    font-size: 14px;
  }
}

/* ========== 14. 公开/私有切换开关 ========== */
.visibility-toggle { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.visibility-toggle .toggle-label {
  display: inline-flex; align-items: center; gap: 10px;
  cursor: pointer; user-select: none; margin-bottom: 0;
  white-space: nowrap;
}
.toggle-track {
  position: relative; width: 42px; height: 23px;
  background: rgba(0,0,0,.12);
  border-radius: 12px;
  transition: background .25s;
  flex-shrink: 0;
}
.toggle-thumb {
  position: absolute;
  top: 2px; left: 2px;
  width: 19px; height: 19px;
  border-radius: 50%;
  background: white;
  box-shadow: 0 1px 4px rgba(0,0,0,.2);
  transition: transform .25s;
}
.visibility-toggle input[type="checkbox"] { display: none; }
.visibility-toggle input[type="checkbox"]:checked + .toggle-label .toggle-track { background: var(--pink); }
.visibility-toggle input[type="checkbox"]:checked + .toggle-label .toggle-thumb { transform: translateX(19px); }
.toggle-text { font-size: 14px; color: var(--text); line-height: 1.4; }

/* 预览面板可见性徽章 */
.preview-visibility { display: flex; align-items: center; gap: 10px; margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--border); }
.visibility-badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 10px; border-radius: 20px;
  font-size: 12px; font-weight: 600;
}
.visibility-badge.is-public { background: rgba(34,197,94,.10); color: #16a34a; }
.visibility-badge.is-private { background: rgba(0,0,0,.06); color: var(--text-light); }
#toggle-visibility-btn { font-size: 12.5px; padding: 4px 12px; }

/* ========== 15. 认证页（登录/注册） ========== */
.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-sub);
  padding: 32px 20px;
}
.auth-card {
  width: 100%;
  max-width: 400px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: 36px 32px;
  box-shadow: var(--shadow-md);
}
.auth-logo {
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 28px; justify-content: center;
}
.auth-logo-icon {
  width: 38px; height: 38px;
  border-radius: 10px;
  background: var(--pink-subtle);
  border: 1.5px solid var(--pink-border);
  display: flex; align-items: center; justify-content: center;
  font-size: 20px;
  color: var(--pink);
}
.auth-logo span {
  font-size: 20px; font-weight: 700;
  color: var(--pink);               /* 粉色站点名 */
  letter-spacing: -.3px;
}
.auth-title { font-size: 22px; font-weight: 700; color: var(--text); text-align: center; margin-bottom: 6px; }
.auth-subtitle { font-size: 13.5px; color: var(--text-light); text-align: center; margin-bottom: 26px; }
.auth-form { width: 100%; }
.auth-form .form-group input {
  width: 100%;
  height: 44px;
  padding: 0 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--r-md);
  font-size: 14.5px;
  color: var(--text);
  background: var(--bg);
  outline: none;
  transition: border-color .2s, box-shadow .2s;
  box-sizing: border-box;
}
.auth-form .form-group input::placeholder { color: var(--text-xlight); }
.auth-form .form-group input:focus {
  border-color: var(--pink);
  box-shadow: 0 0 0 3px var(--pink-subtle);
}
.auth-footer {
  text-align: center; margin-top: 18px;
  font-size: 13.5px; color: var(--text-light);
}
.auth-footer a { color: var(--pink); font-weight: 600; }
.auth-footer a:hover { color: var(--pink-hover); }

/* ========== 16. 搜索页 ========== */
.search-layout {
  display: flex;
  max-width: 1320px;
  margin: 0 auto;
  min-height: calc(100vh - 60px);
  gap: 24px;
}
.search-sidebar { width: 190px; flex-shrink: 0; padding: 22px 0; }
.filter-section { margin-bottom: 22px; }
.filter-section-title {
  font-size: 11px; font-weight: 700;
  color: var(--text-xlight);
  text-transform: uppercase; letter-spacing: .8px;
  margin-bottom: 8px;
}
.filter-option {
  display: flex; align-items: center; gap: 8px;
  padding: 7px 9px; border-radius: var(--r-sm);
  cursor: pointer; font-size: 13.5px;
  color: var(--text); transition: background .15s, color .15s;
}
.filter-option:hover { background: var(--pink-subtle); color: var(--pink-hover); }
.filter-option.active { color: var(--pink-hover); font-weight: 600; }
.search-results-area { flex: 1; min-width: 0; padding: 22px 0; }
.search-header {
  margin-bottom: 18px;
  padding: 18px 22px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-xs);
}
.search-header h2 { font-size: 18px; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.search-header p { font-size: 13.5px; color: var(--text-light); }
.search-header strong { color: var(--pink); }

.search-form-inline {
  display: flex; gap: 10px;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--r-lg);
  padding: 6px 6px 6px 14px;
  margin-bottom: 18px;
  transition: border-color .2s;
}
.search-form-inline:focus-within { border-color: var(--pink); box-shadow: 0 0 0 3px var(--pink-subtle); }
.search-form-inline input {
  flex: 1; border: none; padding: 8px 0;
  font-size: 14.5px; background: transparent;
  color: var(--text); outline: none;
}
.search-form-inline input::placeholder { color: var(--text-xlight); }

.search-history {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 14px 18px;
  margin-bottom: 18px;
}
.search-history h4 { font-size: 12px; font-weight: 700; color: var(--text-xlight); margin-bottom: 10px; }
.history-tag {
  display: inline-block;
  padding: 5px 12px; margin: 0 6px 6px 0;
  background: var(--pink-subtle);
  border: 1px solid var(--pink-border);
  border-radius: var(--r-full);
  font-size: 12.5px; cursor: pointer;
  color: var(--text); transition: all .2s;
  font-family: inherit;
}
.history-tag:hover { background: var(--pink); color: white; border-color: var(--pink); }

/* ========== 17. 空状态 & 加载 ========== */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  background: var(--bg);
  border: 1px dashed var(--border);
  border-radius: var(--r-lg);
  color: var(--text-light);
}
.empty-state .empty-icon { font-size: 48px; margin-bottom: 14px; opacity: .55; }
.empty-state p { font-size: 14.5px; margin: 0 0 20px; }
.loading-indicator {
  align-items: center;
  justify-content: center;
  min-height: 86px;
  padding: 28px 20px;
  color: var(--text-xlight);
  font-size: 13.5px;
}
.loading-indicator .spinner {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background:
    conic-gradient(from 14deg,
      rgba(108, 141, 255, 0) 0deg,
      rgba(108, 141, 255, .14) 46deg,
      #6f8cff 118deg,
      var(--pink) 206deg,
      rgba(216, 144, 162, .18) 282deg,
      rgba(216, 144, 162, 0) 360deg);
  filter: drop-shadow(0 8px 16px rgba(111, 140, 255, .20));
  animation: inspiration-spin .72s linear infinite;
  position: relative;
}
.loading-indicator .spinner::after {
  content: '';
  position: absolute;
  inset: 6px;
  border-radius: 50%;
  background: #faf9f9;
}
.loading-indicator span { display: none; }
.waterfall-sentinel { width: 100%; height: 1px; }
.no-more {
  text-align: center;
  padding: 18px 20px 42px;
  color: var(--text-light);
  font-size: 13px;
  letter-spacing: .02em;
}
@keyframes inspiration-spin {
  to { transform: rotate(360deg); }
}
@media (prefers-reduced-motion: reduce) {
  .loading-indicator .spinner { animation-duration: 1.8s; }
}

/* ========== 18. 上传页 ========== */
.upload-page { width: 100%; }
.upload-form {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 24px;
  box-shadow: var(--shadow-xs);
}
.upload-area {
  border: 2px dashed var(--border);
  border-radius: var(--r-lg);
  padding: 44px 24px;
  text-align: center;
  cursor: pointer;
  transition: all .2s;
  background: var(--bg-sub);
}
.upload-area:hover, .upload-area.dragover {
  border-color: var(--pink);
  background: var(--pink-subtle);
}
.upload-placeholder { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.upload-icon { font-size: 40px; opacity: .5; }
.upload-placeholder p { color: var(--text-light); font-size: 14px; margin: 0; }
.upload-placeholder .upload-hint { font-size: 12px; color: var(--text-xlight); }
.preview-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; margin-top: 14px; }

.preview-item {
  position: relative;
  border: 2px solid transparent;
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0,0,0,.08);
}
.preview-item img {
  width: 100%;
  height: 110px;
  object-fit: cover;
  display: block;
}
/* 查重命中：标黄提醒 */
.preview-item.duplicate {
  border-color: #ffb300;
  background: #fff8e1;
}
.dup-badge {
  position: absolute;
  bottom: 24px;          /* 在删除按钮上方 */
  left: 4px;
  right: 4px;
  background: #ffb300;
  color: #fff;
  font-size: 10px;
  line-height: 1.3;
  padding: 3px 6px;
  border-radius: 4px;
  pointer-events: none;
  z-index: 2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: center;
}

/* 查重进度条 */
#dup-progress-bar {
  background: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 6px;
  padding: 8px 12px;
  margin-bottom: 8px;
  font-size: 13px;
  color: #333;
}
#dup-progress-text { margin-bottom: 5px; color: #666; }
#dup-progress-fill {
  height: 6px;
  background: linear-gradient(90deg, #ff9800, #ff6b00);
  border-radius: 3px;
  transition: width 0.3s ease;
}
.preview-remove {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 22px;
  height: 22px;
  border: none;
  border-radius: 50%;
  background: rgba(0,0,0,.55);
  color: #fff;
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
  z-index: 2;
}
.preview-remove:hover { background: rgba(0,0,0,.8); }

/* ========== 19. Toast ========== */
.toast {
  position: fixed; bottom: 28px; left: 50%;
  transform: translateX(-50%) translateY(12px);
  background: var(--text);
  color: white;
  padding: 11px 22px;
  border-radius: var(--r-full);
  font-size: 13.5px;
  box-shadow: var(--shadow-md);
  opacity: 0; pointer-events: none;
  transition: all .28s;
  z-index: 3000;
  white-space: nowrap;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ========== 20. 页脚 ========== */
.footer {
  text-align: center;
  padding: 28px 24px;
  color: var(--text-xlight);
  font-size: 12.5px;
  border-top: 1px solid var(--border);
  background: var(--bg);
  margin-top: auto;
}

/* ========== 21. 分享页 ========== */
.share-banner {
  background: linear-gradient(135deg, var(--pink-hover), var(--pink));
  color: white;
  text-align: center;
  padding: 36px 24px;
}
.share-banner h1 { font-size: 26px; font-weight: 800; margin-bottom: 8px; }
.share-banner p { font-size: 14px; opacity: .88; }

/* ========== 22. 错误页 ========== */
.error-page { flex: 1; display: flex; align-items: center; justify-content: center; text-align: center; padding: 60px 24px; }
.error-code { font-size: 88px; font-weight: 800; color: var(--pink); line-height: 1; margin-bottom: 12px; }
.error-page h2 { font-size: 22px; font-weight: 700; margin-bottom: 8px; }
.error-page p { color: var(--text-light); margin-bottom: 24px; }

/* ========== 23. 项目设置弹窗 ========== */
.settings-section { margin-bottom: 16px; padding-bottom: 14px; border-bottom: 1px solid var(--border); }
.settings-section:last-child { border-bottom: none; margin-bottom: 0; }
.settings-section h4 { font-size: 13.5px; font-weight: 600; margin-bottom: 9px; color: var(--text); }

/* ========== 24. 进度条 ========== */
.progress-bar { height: 5px; background: var(--border); border-radius: 3px; overflow: hidden; margin-top: 8px; }
.progress-fill { height: 100%; background: var(--pink); width: 0; transition: width .3s; border-radius: 3px; }
.progress-label { font-size: 12px; color: var(--text-xlight); margin-top: 5px; text-align: center; }

/* ========== 25. 插件弹窗 ========== */
.plugin-popup { width: 370px; height: 490px; background: white; display: flex; flex-direction: column; overflow: hidden; font-size: 13px; }
.plugin-header {
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  color: var(--text);
  padding: 13px 16px;
  display: flex; align-items: center; gap: 10px; flex-shrink: 0;
}
.plugin-header-icon { width: 34px; height: 34px; border-radius: 8px; background: var(--pink-subtle); border: 1px solid var(--pink-border); display: flex; align-items: center; justify-content: center; font-size: 18px; color: var(--pink); }
.plugin-header-title { font-size: 14px; font-weight: 700; color: var(--pink); }
.plugin-header-sub { font-size: 10.5px; color: var(--text-xlight); }
.plugin-body { flex: 1; padding: 14px; overflow-y: auto; display: flex; flex-direction: column; gap: 11px; }
.plugin-url { padding: 7px 11px; background: var(--bg-sub); border: 1px solid var(--border); border-radius: var(--r-sm); font-size: 11px; color: var(--text-xlight); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.plugin-thumb-wrap { border-radius: var(--r-sm); overflow: hidden; height: 115px; }
.plugin-thumb { width: 100%; height: 115px; object-fit: cover; background: var(--bg-sub); }
.plugin-recent { border-top: 1px solid var(--border); padding-top: 11px; margin-top: auto; }
.plugin-recent-title { font-size: 11.5px; font-weight: 600; color: var(--text-xlight); margin-bottom: 7px; }
.plugin-recent-item { display: flex; align-items: center; gap: 8px; padding: 5px 0; font-size: 12px; color: var(--text); cursor: pointer; transition: color .15s; }
.plugin-recent-item:hover { color: var(--pink-hover); }
.plugin-recent-thumb { width: 30px; height: 30px; border-radius: 4px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; font-size: 15px; background: var(--bg-sub); }

/* ========== 26. 首页导航新建项目按钮 ========== */
.btn-new-project {
  background: #f8b8c8;
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 7px 18px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: all .2s;
  line-height: 1.4;
}
.btn-new-project:hover { background: var(--pink-hover); transform: scale(1.03); }


/* ========== Project Header 按钮组（项目设置/分享/上传素材） ========== */
.project-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

@media (max-width: 768px) {
  .project-actions {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }
  .project-actions .btn {
    min-width: 0;
    justify-content: center;
    font-size: 13px;
    padding: 10px 8px;
    white-space: nowrap;
  }
  .project-actions .btn img {
    display: none; /* 移动端隐藏图标节省空间 */
  }
  /* 上传素材按钮占满整行 */
  .project-actions .btn-primary {
    grid-column: 1 / -1;
  }
}

/* ========== 项目封面图 (index 瀑布流卡片内) ========== */
.project-cover-img {
    width: 100%;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: var(--bg-sub);
    display: flex;
    align-items: center;
    justify-content: center;
}
.project-cover-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .35s ease;
}
.project-card:hover .project-cover-img img { transform: scale(1.04); }

.project-cover-placeholder {
    width: 100%; height: 100%;
    display: flex; align-items: center; justify-content: center;
    font-size: 36px;
    background: linear-gradient(135deg, #f7f7f7, #ebebeb);
    color: #d0d0d0;
}
.project-info { padding: 14px 16px 12px; }
.project-title-row { display: flex; align-items: baseline; justify-content: flex-start; gap: 8px; margin-bottom: 6px; position: relative; }
.project-info h3 { margin-right: auto; text-align: left; font-size: 15px; font-weight: 600; color: var(--pink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: color .2s; max-width: calc(100% - 70px); }
.project-card:hover .project-info h3 { color: var(--pink-hover); }
.project-count { position: absolute; right: 0; top: 50%; transform: translateY(-50%); font-size: 11px; color: var(--text-xlight); white-space: nowrap; }
.project-info p { font-size: 12.5px; color: var(--text-light); }
.project-meta-row {
    display: flex; justify-content: space-between; align-items: center;
    margin-top: 9px; padding-top: 10px;
    border-top: 1px dashed var(--border);
    font-size: 11.5px; color: var(--text-xlight);
    gap: 8px;
}
.project-meta-row .project-owner,
.project-meta-row .project-collab { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.project-meta-row .project-collab { flex: 0 1 auto; }
.project-meta-row .project-time { flex: 0 0 auto; margin-left: auto; }
.project-meta-row .project-badge { display: inline-flex; align-items: center; gap: 4px; }

/* ========== 27. 通知页 ========== */
.notif-list { display: flex; flex-direction: column; gap: 10px; }
.notif-item {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 14px 16px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  transition: box-shadow .2s, border-color .2s;
  cursor: pointer;
}
.notif-item:hover { box-shadow: var(--shadow-sm); border-color: var(--pink-border); }
.notif-item.is-unread { border-left: 3px solid var(--pink); }
.notif-icon { width: 36px; height: 36px; border-radius: 50%; background: var(--pink-subtle); display: flex; align-items: center; justify-content: center; font-size: 16px; flex-shrink: 0; color: var(--pink); }
.notif-content { flex: 1; min-width: 0; }
.notif-content .notif-title { font-size: 13.5px; font-weight: 600; color: var(--text); margin-bottom: 3px; }
.notif-content .notif-time { font-size: 12px; color: var(--text-xlight); }
.notif-delete { color: var(--text-xlight); font-size: 16px; cursor: pointer; padding: 4px; transition: color .15s; }
.notif-delete:hover { color: #e84141; }

/* ========== 28. 响应式 ========== */
@media (max-width: 768px) {
  .navbar > .container { flex-wrap: wrap; gap: 10px; }
  .nav-search { order: 3; max-width: 100%; width: 100%; }
  .search-layout { flex-direction: column; }
  .search-sidebar { width: 100%; }
  .dashboard-layout { flex-direction: column; }
  .sidebar { width: 100%; border-right: none; border-bottom: 1px solid var(--border); }
  .projects-grid, .materials-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
  .modal-content { max-width: 100vw; max-height: 100vh; border-radius: 0; }
  .modal-form { min-width: auto; }
}

/* ========== 旧版类名兼容（保留以防漏改） ========== */
.nav-links { display: flex; align-items: center; gap: 4px; margin-left: auto; flex-wrap: wrap; }
.nav-links a { color: var(--text); font-size: 13.5px; font-weight: 500; padding: 7px 12px; border-radius: var(--r-md); transition: all .15s; }
.nav-links a:hover { color: var(--pink-hover); background: var(--pink-subtle); }
.nav-links a.active { color: var(--pink-hover); background: var(--pink-subtle); font-weight: 600; }
.nav-user { font-size: 13.5px; color: var(--text-light); padding: 7px 12px; }
/* .btn-logout 已废弃 - 退出是导航文字链接，保持纯文字样式 */
.nav-search-inline { display: flex; align-items: center; background: var(--bg-sub); border: 1.5px solid var(--border); border-radius: var(--r-full); padding: 0 6px 0 14px; gap: 4px; transition: all .15s; }
.nav-search-inline:focus-within { background: var(--bg); border-color: var(--pink); box-shadow: 0 0 0 3px var(--pink-subtle); }
.nav-search-inline input { border: none; background: transparent; outline: none; font-size: 13px; color: var(--text); width: 100%; padding: 6px 0; }
.nav-search-inline input::placeholder { color: var(--text-xlight); }
.nav-search-inline button { border: none; background: none; cursor: pointer; padding: 4px 8px; opacity: .55; }
.nav-search-inline button:hover { opacity: 1; }

/* ========== 28. 通知页 ========== */
.notifications-page { padding-top: 32px; padding-bottom: 60px; }
.notifications-header {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 22px; padding-bottom: 14px;
    border-bottom: 1px solid var(--border);
}
.notifications-header h1 {
    font-size: 22px; font-weight: 600; color: var(--text);
    display: flex; align-items: center; gap: 9px;
}
.notifications-header h1::before { content: ''; display: inline-block; width: 4px; height: 18px; background: var(--pink); border-radius: 2px; }

.notification-list { display: flex; flex-direction: column; gap: 12px; }

.notification-card {
    display: flex; align-items: center; gap: 16px;
    padding: 18px 20px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--r-lg);
    cursor: default;
    transition: all .2s;
    position: relative;
}
.notification-card:hover { border-color: var(--pink-border); box-shadow: var(--shadow-sm); }
.notification-card.unread { border-left: 3px solid var(--pink); background: linear-gradient(90deg, var(--pink-subtle), var(--bg) 30%); }

.notification-icon {
    flex-shrink: 0;
    width: 42px; height: 42px;
    background: var(--pink-subtle);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 20px;
}
.notification-body { flex: 1; min-width: 0; }
.notification-title {
    font-size: 14.5px; font-weight: 600; color: var(--text);
    margin-bottom: 4px;
}
.notification-content {
    font-size: 13px; color: var(--text-light);
    line-height: 1.5;
    margin-bottom: 4px;
}
.notification-time {
    font-size: 11.5px; color: var(--text-xlight);
}
.notification-dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    background: var(--pink);
    flex-shrink: 0;
}

.empty-notifications {
    text-align: center; padding: 80px 20px;
    color: var(--text-light);
}
.empty-notifications .empty-icon { font-size: 56px; margin-bottom: 14px; opacity: .4; }
.empty-notifications p { font-size: 14px; }

/* ========== 29. Auth 表单（登录 / 注册 统一样式） ========== */
.auth-page { padding-top: 0; padding-bottom: 60px; }

.auth-card {
    max-width: 420px;
    width: 100%;
    margin: 40px auto 0;
    padding: 36px 40px 30px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--r-lg);
    box-shadow: var(--shadow-md);
}
.auth-card h2 {
    font-size: 22px; font-weight: 600;
    text-align: center;
    margin-bottom: 26px;
    color: var(--text);
    display: flex; align-items: center; justify-content: center; gap: 8px;
}
.auth-card h2::before { content: ''; display: inline-block; width: 28px; height: 3px; background: var(--pink); border-radius: 2px; margin-right: 4px; }

.auth-form { display: flex; flex-direction: column; gap: 18px; }

.auth-form .form-group { display: flex; flex-direction: column; gap: 7px; margin: 0; }
.auth-form .form-group label {
    font-size: 13px; font-weight: 500; color: var(--text);
    margin: 0; padding: 0;
}
.auth-form .form-group input,
.auth-form .form-group textarea {
    width: 100%;
    height: 42px;                       /* 统一高度 */
    padding: 0 14px;                    /* 统一 padding */
    font-size: 14px;
    font-family: inherit;
    color: var(--text);
    background: var(--bg-sub);
    border: 1.5px solid var(--border);
    border-radius: var(--r-md);
    transition: all .2s;
    box-sizing: border-box;
    outline: none;
}
.auth-form .form-group textarea { height: auto; min-height: 88px; padding: 12px 14px; resize: vertical; }
.auth-form .form-group input:hover,
.auth-form .form-group textarea:hover { border-color: #d4d4d4; background: var(--bg); }
.auth-form .form-group input:focus,
.auth-form .form-group textarea:focus {
    border-color: var(--pink);
    background: var(--bg);
    box-shadow: 0 0 0 3px var(--pink-subtle);
}
.auth-form .form-group input::placeholder { color: var(--text-xlight); }

.auth-form .form-error {
    padding: 10px 14px;
    background: #fff0f3;
    border: 1px solid #ffd6e0;
    border-radius: var(--r-md);
    color: #e84141;
    font-size: 13px;
    text-align: center;
}
.auth-form .form-hint { font-size: 11.5px; color: var(--text-xlight); margin-top: 2px; }

.auth-form .btn-block {
    width: 100%;
    height: 44px;
    margin-top: 6px;
    font-size: 14.5px; font-weight: 500;
    border-radius: var(--r-md);
}

.auth-footer {
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid var(--border);
    text-align: center;
    font-size: 13.5px;
    color: var(--text-light);
}
.auth-footer a { color: var(--pink); font-weight: 500; }
.auth-footer a:hover { color: var(--pink-hover); text-decoration: underline; }

/* ========== 30. Dashboard 我的项目列表 ========== */
.dashboard-header {
    display: flex; justify-content: space-between; align-items: center;
    margin: 32px 0 22px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--border);
}
.dashboard-header h2 {
    font-size: 22px; font-weight: 600; color: var(--text);
    display: flex; align-items: center; gap: 9px;
}
.dashboard-header h2::before { content: ''; display: inline-block; width: 4px; height: 18px; background: var(--pink); border-radius: 2px; }

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    padding-bottom: 40px;
}

.empty-state {
    text-align: center; padding: 80px 20px;
    color: var(--text-light);
    background: var(--bg-sub);
    border: 1.5px dashed var(--border);
    border-radius: var(--r-lg);
    margin-top: 20px;
}
.empty-state .empty-icon { font-size: 48px; margin-bottom: 12px; opacity: .45; }
.empty-state p { font-size: 14px; margin-bottom: 16px; }

.dashboard-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--r-lg);
    padding: 18px 18px 14px;
    cursor: pointer;
    transition: all .2s;
    position: relative;
}
.dashboard-card:hover {
    border-color: var(--pink-border);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}
.dashboard-card-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; margin-bottom: 8px; }
.dashboard-card-header h3 { font-size: 15.5px; font-weight: 600; color: var(--text); flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dashboard-card-desc { font-size: 13px; color: var(--text-light); line-height: 1.5; min-height: 38px; margin-bottom: 12px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.dashboard-card-footer {
    display: flex; justify-content: space-between; align-items: center;
    padding-top: 10px;
    border-top: 1px dashed var(--border);
    font-size: 12px;
    color: var(--text-xlight);
}
.dashboard-card-footer .badge-row { display: flex; gap: 6px; }
.project-badge {
    font-size: 10.5px; padding: 2px 8px; border-radius: var(--r-full);
    font-weight: 500;
}
.project-badge.public { background: var(--pink-subtle); color: var(--pink-hover); }
.project-badge.private { background: var(--bg-sub); color: var(--text-light); }
.project-badge.collaborator { background: #f0f8ff; color: #4a90e2; }
.dashboard-card-actions { display: flex; gap: 4px; }
/* .btn-icon 由全局样式定义（胶囊圆角 + 粉色边框 hover），不要重复覆盖 */

/* ── 每日语录 ── */
.daily-quote-section {
    text-align: center;
    padding: 40px 24px 32px;
    max-width: 680px;
    margin: 0 auto;
}

/* 素材预览：画廊工作台 */
.preview-modal {
    padding: 4vh 4vw;
    background: rgba(55, 45, 49, .68);
    backdrop-filter: blur(8px);
}
.preview-modal .modal-close {
    top: calc(4vh + 14px);
    right: calc(4vw + 14px);
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, .9);
    color: #70666a;
    box-shadow: 0 4px 18px rgba(57, 43, 49, .14);
}
.preview-box {
    width: min(1380px, 92vw);
    height: min(840px, 90vh);
    max-width: none;
    max-height: none;
    display: grid;
    grid-template-columns: minmax(0, 7fr) minmax(310px, 3fr);
    background: #f6f3f4;
    border: 1px solid rgba(255, 255, 255, .72);
    border-radius: 22px;
    box-shadow: 0 28px 80px rgba(49, 37, 42, .28);
}
.preview-stage {
    min-width: 0;
    min-height: 0;
    padding: 48px 68px;
    background: linear-gradient(145deg, #f8f6f7 0%, #f0ecee 100%);
}
.preview-image-wrap {
    width: 100%;
    height: 100%;
    display: grid;
    place-items: center;
    min-width: 0;
    min-height: 0;
}
#preview-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 12px;
    box-shadow: 0 18px 48px rgba(57, 43, 49, .14);
}
.preview-loading { height: 100%; min-height: 280px; }
.preview-panel {
    display: flex;
    flex-direction: column;
    min-width: 0;
    max-height: none;
    padding: 0;
    overflow: hidden;
    border-top: 0;
    border-left: 1px solid #eee5e8;
    background: #fff;
}
.preview-panel-head {
    position: relative;
    padding: 34px 30px 22px;
    border-bottom: 1px solid #f1e9eb;
}
.preview-eyebrow {
    display: block;
    margin-bottom: 9px;
    color: #c98798;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.8px;
}
.preview-filename {
    padding-right: 64px;
    color: #3d3639;
    font-size: 20px;
    font-weight: 700;
    line-height: 1.45;
    word-break: break-word;
}
.preview-panel-head .preview-visibility {
    position: absolute;
    top: 34px;
    right: 28px;
    margin: 0;
}
.preview-panel-scroll {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 24px 30px;
}
.preview-panel-block {
    margin-bottom: 22px;
    text-align: left;
}
.preview-panel-label {
    margin-bottom: 8px;
    color: #b87789;
    font-size: 11px;
    letter-spacing: .8px;
    text-align: left;
}
.preview-panel-note {
    color: #51484c;
    font-size: 13.5px;
    line-height: 1.75;
    text-align: left;
}
.preview-panel-note.is-mynote {
    padding: 12px 14px;
    background: #fff5f7;
    border: 1px solid #f4dce2;
}
.preview-serial-number {
    padding: 5px 10px;
    border: 1px solid #efd5dc;
    border-radius: 999px;
    background: #fff5f7;
    color: #c9788e;
    font-family: monospace;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .8px;
    cursor: pointer;
}
.preview-panel-source {
    display: block;
    max-width: 100%;
    overflow: hidden;
    color: #a46476;
    font-size: 12.5px;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.preview-action-dock {
    flex: 0 0 auto;
    padding: 18px 24px 22px;
    border-top: 1px solid #f1e9eb;
    background: #fffafb;
}
.preview-primary-actions,
.preview-panel-actions {
    display: flex;
    gap: 8px;
    margin: 0;
    padding: 0;
    border: 0;
}
.preview-primary-actions .btn { flex: 1; }
.preview-panel-actions { margin-top: 9px; flex-wrap: wrap; justify-content: flex-start; }
.preview-panel-actions .btn { flex: 1 1 calc(50% - 5px); }
.preview-nav { z-index: 2; }

@media (max-width: 768px) {
    .preview-modal { padding: 0; align-items: flex-end; }
    .preview-modal .modal-close { top: 12px; right: 12px; }
    .preview-box {
        width: 100%;
        height: 94vh;
        max-width: 100%;
        max-height: 94vh;
        grid-template-columns: 1fr;
        grid-template-rows: minmax(260px, 52vh) minmax(0, 1fr);
        border-radius: 20px 20px 0 0;
    }
    .preview-stage { padding: 42px 44px 22px; }
    .preview-panel { border-left: 0; border-top: 1px solid #eee5e8; }
    .preview-panel-head { padding: 20px 20px 14px; }
    .preview-filename { padding-right: 52px; font-size: 17px; }
    .preview-panel-head .preview-visibility { top: 20px; right: 18px; }
    .preview-panel-scroll { padding: 18px 20px; }
    .preview-action-dock { padding: 14px 18px 18px; }
}
.daily-quote-text {
    font-size: 26px;
    line-height: 1.9;
    color: var(--pink);
    font-weight: 600;
    margin-bottom: 14px;
    word-break: break-word;
}
.daily-quote-source {
    font-size: 14px;
    color: var(--text-light);
    font-style: normal;
}

/* ============================================================
   全站响应式改造（移动端适配）
   ============================================================ */

/* ── 桌面端：汉堡按钮和移动菜单默认隐藏 ─────────────────── */
.nav-hamburger,
.nav-actions-mobile {
    display: none !important;
}

/* ── 平板：768px ~ 1023px ─────────────────────────────────── */
@media (max-width: 1023px) {
    .container {
        padding: 0 20px;
    }

    .projects-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 16px;
    }

    .navbar > .container {
        gap: 12px;
    }

    .nav-search {
        min-width: 160px;
    }
}

/* ── 手机竖屏：< 768px ────────────────────────────────────── */
@media (max-width: 768px) {
    /* 容器 */
    .container {
        padding: 0 14px;
    }

    /* 导航栏：允许换行，防止内容被挤压撑高容器 */
    .navbar > .container {
        gap: 8px;
        flex-wrap: wrap;
    }

    /* 桌面端导航在手机端完全隐藏 */
    .nav-actions {
        display: none;
    }

    /* 移动菜单改为相对于 container 定位 */
    .nav-actions-mobile {
        top: 100%;
        left: 0;
        right: 0;
    }

    .logo {
        font-size: 15px;
        flex-shrink: 0;
    }

    .logo span {
        max-width: 120px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    /* 搜索框在手机上占满整行 */
    .nav-search {
        flex: 1 1 100%;
        min-width: 0;
        order: 3;
    }

    .nav-search input {
        font-size: 13px;
        padding: 6px 10px;
    }

    /* 下拉菜单 */
    .nav-dropdown-menu {
        right: 0;
        left: auto;
        min-width: 180px;
    }

    /* 导航移动端折叠 */
    .nav-hamburger {
        display: flex !important;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        width: 32px;
        height: 32px;
        border: none;
        background: none;
        cursor: pointer;
        padding: 4px;
        border-radius: 6px;
        gap: 5px;
        flex-shrink: 0;
    }
    .nav-hamburger span {
        display: block;
        width: 20px;
        height: 2px;
        background: var(--text);
        border-radius: 2px;
        transition: all .2s;
    }
    .nav-hamburger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
    .nav-hamburger.active span:nth-child(2) { opacity: 0; }
    .nav-hamburger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
    .nav-actions-mobile {
        display: none !important;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg);
        border-bottom: 1px solid var(--border);
        padding: 12px 16px 16px;
        z-index: 200;
        flex-direction: column;
        gap: 6px;
        box-shadow: 0 4px 12px rgba(0,0,0,.08);
    }
    .nav-actions-mobile.show { display: flex !important; }
    .nav-actions-mobile a,
    .nav-actions-mobile button {
        display: flex;
        align-items: center;
        gap: 8px;
        padding: 10px 12px;
        border-radius: 8px;
        font-size: 14px;
        color: var(--text);
        text-decoration: none;
        border: none;
        background: none;
        cursor: pointer;
        width: 100%;
        text-align: left;
    }
    .nav-actions-mobile a:hover,
    .nav-actions-mobile button:hover { background: var(--pink-subtle); color: var(--pink); }
    .nav-actions-mobile .nav-mobile-divider {
        height: 1px;
        background: var(--border);
        margin: 4px 0;
    }
    .nav-actions-mobile .nav-mobile-logout { color: #e53935; }
    .nav-actions { position: relative; }

    /* 通知图标 */
    .nav-icon-btn {
        padding: 5px 6px;
    }

    /* 首页语录 */
    .daily-quote-text {
        font-size: 18px;
    }

    /* 项目网格 */
    .projects-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    /* 瀑布流 */
    .waterfall {
        column-count: 2;
        padding: 8px 0 80px;
    }

    /* 模态框全屏 */
    .modal-content,
    .modal-form {
        max-width: 100%;
        width: 100%;
        border-radius: 16px 16px 0 0;
        margin: auto auto 0;
        padding: 20px 16px;
        min-width: unset;
        max-height: 92vh;
    }

    .modal {
        align-items: flex-end;
        padding: 0;
    }

    .modal.active,
    .modal.show,
    .modal.open {
        display: flex;
    }

    .preview-modal {
        padding: 0;
        align-items: flex-end;
    }

    .preview-box {
        max-width: 100%;
        width: 100%;
        border-radius: 16px 16px 0 0;
        max-height: 95vh;
    }

    /* 大图预览控制栏 */
    .preview-controls {
        flex-wrap: wrap;
        gap: 6px;
    }

    /* Dashboard */
    .dashboard-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    /* 上传页面 */
    .upload-zone {
        min-height: 180px;
    }

    /* 搜索结果 */
    .search-bar {
        flex-direction: column;
        gap: 10px;
    }

    .search-bar input[type="text"] {
        width: 100%;
    }

    /* 通用表单 */
    .form-group input,
    .form-group textarea,
    .form-group select {
        font-size: 15px; /* 防止 iOS 自动缩放 */
    }

    /* 按钮手机端适当放大 */
    .btn {
        padding: 10px 20px;
        font-size: 14px;
        min-height: 44px;
    }

    .btn.btn-sm {
        padding: 7px 14px;
        font-size: 13px;
        min-height: 36px;
    }
}

/* ── 手机小屏：< 480px ────────────────────────────────────── */
@media (max-width: 479px) {
    .projects-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .waterfall {
        column-count: 2;
    }

    /* 模态框内表单 */
    .modal-form {
        padding: 18px 14px;
    }

    .modal-body,
    .modal-title,
    .modal-footer {
        padding-left: 14px;
        padding-right: 14px;
    }

    /* Dashboard 紧凑 */
    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    /* 项目卡片 */
    .project-card .project-info h3 {
        font-size: 13px;
    }

    .project-card .project-info p {
        font-size: 11px;
    }

    /* 导航栏 */
    .nav-search {
        display: none; /* 极窄屏隐藏搜索框，由主页提供搜索入口 */
    }
}

/* ========== 拼图功能 ========== */
.collage-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    background: #fff0f5;
    border: 1.5px solid #ffb3d9;
    border-radius: 10px;
    margin-top: 12px;
    gap: 12px;
}
.collage-bar-info {
    font-size: 14px;
    color: #c7256b;
}
.collage-bar-info strong {
    font-size: 16px;
}

/* 拼图弹窗内 loading */
#collage-loading { vertical-align: middle; margin-right: 4px; }

/* ========== 拼图功能 ========== */
.collage-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    background: #fff0f5;
    border: 1.5px solid #ffb3d9;
    border-radius: 10px;
    margin-top: 12px;
    gap: 12px;
}
.collage-bar-info {
    font-size: 14px;
    color: #c7256b;
}
.collage-bar-info strong {
    font-size: 16px;
}
#collage-loading {
    vertical-align: middle;
    margin-right: 4px;
}

/* ── 项目内素材分页栏 ────────────────────────────────────── */
#pagination-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin: 24px auto 12px;
    padding: 10px 14px;
    font-size: 13px;
    color: var(--text-light);
}
#pagination-bar .pagi-info {
    color: var(--text-light);
    margin-right: 10px;
}
#pagination-bar .pagi-btn {
    min-width: 32px;
    height: 32px;
    padding: 0 10px;
    border: 1px solid var(--border);
    background: #fff;
    color: var(--text-light);
    border-radius: 6px;
    font-size: 13px;
    cursor: pointer;
    transition: all .15s;
}
#pagination-bar .pagi-btn:hover:not(:disabled) {
    border-color: var(--pink);
    color: var(--pink);
    background: var(--pink-subtle);
}
#pagination-bar .pagi-btn.active {
    background: var(--pink);
    border-color: var(--pink);
    color: #fff;
    font-weight: 600;
}
#pagination-bar .pagi-btn:disabled {
    opacity: .35;
    cursor: not-allowed;
}
#pagination-bar .pagi-nav {
    font-weight: 700;
    color: var(--pink);
}
#pagination-bar .pagi-ellipsis {
    color: var(--text-xlight);
    padding: 0 4px;
}

/* ===== 主色调筛选色块 ===== */
.color-filter-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin: 16px 0 8px;
    padding: 10px 14px;
    background: var(--card, #fff);
    border: 1px solid var(--border, #eee);
    border-radius: var(--radius-md, 10px);
}
.batch-edit-tools {
    margin-left: auto;
    display: flex;
    align-items: center;
    min-height: 34px;
}
.batch-edit-tools .batch-actions {
    align-items: center;
    justify-content: flex-end;
}
.batch-edit-tools .selected-count {
    color: var(--text-light);
    font-size: 13px;
    white-space: nowrap;
}
.batch-edit-tools .btn {
    min-height: 34px;
    padding: 7px 12px;
}
.batch-edit-tools .btn:disabled,
#confirm-color-btn:disabled {
    cursor: not-allowed;
    opacity: .45;
}
.batch-modal-hint {
    margin: -4px 0 18px;
    color: var(--text-light);
    font-size: 13px;
}
.batch-color-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    margin-bottom: 20px;
}
.batch-color-option {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 9px 8px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--card);
    color: var(--text);
    cursor: pointer;
}
.batch-color-option span {
    width: 18px;
    height: 18px;
    border: 1px solid rgba(0, 0, 0, .1);
    border-radius: 50%;
}
.batch-color-option:hover,
.batch-color-option.selected {
    border-color: var(--pink);
    background: var(--pink-subtle);
    color: var(--pink-hover);
}
.color-filter-label {
    font-size: 13px;
    color: var(--text-light, #888);
    white-space: nowrap;
    margin-right: 4px;
}
.color-dot {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 2px solid rgba(0, 0, 0, 0.08);
    cursor: pointer;
    padding: 0;
    position: relative;
    transition: transform .12s, box-shadow .12s;
    flex: 0 0 auto;
}
.color-dot:hover {
    transform: scale(1.15);
}
.color-dot span {
    font-size: 11px;
    color: var(--text-light, #888);
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
}
.color-dot.active {
    box-shadow: 0 0 0 3px var(--pink, #ff6b9d);
    transform: scale(1.12);
}
/* 全部按钮 */
.color-btn-all {
    background: var(--pink, #ff6b9d);
    color: white;
    border: none;
    border-radius: 16px;
    padding: 6px 18px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all .15s;
    margin-right: 8px;
}
.color-btn-all:hover {
    background: var(--pink-hover, #ff5a8a);
    transform: translateY(-1px);
}
.color-btn-all.active {
    box-shadow: 0 0 0 3px rgba(255, 107, 157, 0.35);
}

/* 查看原图红色长条按钮 */
.btn-view-original {
    background: var(--pink, #ff6b9d);
    color: white;
    border: none;
    border-radius: 6px;
    padding: 8px 24px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all .15s;
    width: 100%;
    max-width: 320px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}
.btn-view-original:hover {
    background: var(--pink-hover, #ff5a8a);
    transform: translateY(-1px);
}

/* ========== 2026-08 导航方案 A + 圆角线性图标系统 ========== */
.ui-svg-icon {
    display: inline-block;
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
    vertical-align: -3px;
    color: currentColor;
}
.btn .ui-svg-icon { width: 16px; height: 16px; margin-right: 5px; }
.heading-with-icon,
.inline-icon-text { display: flex; align-items: center; gap: 8px; }
.heading-with-icon .ui-svg-icon { width: 22px; height: 22px; color: var(--pink); }
.inline-icon-text .ui-svg-icon { width: 17px; height: 17px; }
.empty-icon .ui-svg-icon { width: 40px; height: 40px; stroke-width: 1.25; }
.project-cover-placeholder .ui-svg-icon { width: 34px; height: 34px; }
.btn-icon .ui-svg-icon { width: 17px; height: 17px; }
.modal-close .ui-svg-icon { width: 18px; height: 18px; }

.navbar > .container { min-height: 74px; }
.nav-search { margin-left: auto; }
.nav-search-icon { display: grid; place-items: center; font-size: 0; }
.nav-search-icon .ui-svg-icon { width: 16px; height: 16px; }
.nav-actions { align-self: stretch; gap: 4px; }
.nav-action-link,
.nav-actions .nav-dropdown > .nav-action-link {
    min-width: 46px;
    height: 100%;
    padding: 8px 7px 6px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    border-radius: 10px;
    color: #766d71;
    font-size: 10px;
    line-height: 1.1;
}
.nav-action-icon {
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    color: inherit;
}
.nav-action-icon .ui-svg-icon { width: 17px; height: 17px; }
.nav-action-link:hover { color: var(--pink-hover); background: transparent; }
.nav-action-link:hover .nav-action-icon { background: var(--pink-subtle); }
.nav-action-link.is-active { color: var(--pink-hover); font-weight: 700; }
.nav-action-link.is-active .nav-action-icon { background: var(--pink-subtle); }
.nav-icon-btn.nav-action-link { width: auto; height: 100%; border: 0; }
.nav-actions .nav-dropdown { height: 100%; }
.nav-actions .nav-caret { display: none; }
.nav-dropdown-item { display: flex; align-items: center; gap: 8px; }
.nav-dropdown-item .ui-svg-icon { width: 16px; height: 16px; }
.nav-actions-mobile a,
.nav-mobile-logout { display: flex; align-items: center; gap: 10px; }
.nav-actions-mobile .ui-svg-icon { width: 18px; height: 18px; }

/* 每日歌词直接融入页面，不使用白色卡片 */
.daily-quote-section {
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    border-radius: 0 !important;
}

@media (max-width: 1023px) {
    .nav-action-link { min-width: 40px; padding-left: 4px; padding-right: 4px; }
    .nav-actions { gap: 1px; }
}

@media (max-width: 768px) {
    .navbar > .container { min-height: 0; }
    .nav-search { margin-left: 0; }
    .nav-actions-mobile { padding: 10px; }
    .nav-actions-mobile a,
    .nav-mobile-logout { border-radius: 9px; padding: 11px 12px; }
    .nav-actions-mobile a:hover { background: var(--pink-subtle); color: var(--pink-hover); }
    .batch-edit-tools { width: 100%; margin-left: 0; justify-content: flex-end; }
    .batch-edit-tools .batch-actions { width: 100%; }
    .batch-color-grid { grid-template-columns: repeat(3, 1fr); }
}
