/* ═══════════════════════════════════════════
   青沐书笺 · 编辑器 · Esther Editorial
   沉浸式写作 · 让作者忘记工具
   ═══════════════════════════════════════════ */

/* ─── 导航 ─── */
.ed-nav {
  text-align: left;
  padding: 10px 18px 0;
  position: sticky;
  top: 0;
  z-index: 5;
  background: var(--bg);
}
.ed-back {
  background: none;
  border: none;
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--muted);
  cursor: pointer;
  padding: 4px 0;
  opacity: .5;
  transition: opacity .2s;
}
.ed-back:hover { opacity: 1; }

/* ─── 正文主区 ─── */
.ed-body {
  max-width: 620px;
  margin: 0 auto;
  padding: 0 22px 140px;
}

/* ─── 标题 ─── */
.ed-title {
  width: 100%;
  padding: 24px 0 10px;
  border: none;
  background: none;
  font-family: var(--font-disp);
  font-size: 26px;
  font-weight: 700;
  color: var(--text);
  outline: none;
  line-height: 1.3;
  letter-spacing: -.02em;
}
.ed-title::placeholder {
  color: var(--muted);
  font-weight: 400;
  opacity: .5;
}
.ed-title:focus::placeholder { opacity: .25; }

/* ─── 分类标签 ─── */
.ed-genre-wrap { padding: 0 0 18px; }
.ed-genre-label {
  font-family: var(--font-body);
  font-size: 11px;
  color: var(--muted);
  cursor: pointer;
  display: inline-block;
  padding: 2px 0;
  transition: color .2s;
  animation: genrePulse 2s ease-in-out infinite;
}
.ed-genre-label:hover { color: var(--accent); animation: none; }
@keyframes genrePulse {
  0%, 100% { opacity: .4; color: var(--muted); }
  50%      { opacity: 1; color: var(--accent); }
}

/* ─── 分类浮层 ─── */
.ed-genre-picker {
  position: fixed;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-panel);
  z-index: 300;
  display: none;
  overflow: hidden;
  min-width: 90px;
}
.ed-genre-item {
  padding: 10px 16px;
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--text);
  cursor: pointer;
  transition: background .1s, color .1s;
}
.ed-genre-item:hover { background: var(--accent-tint); color: var(--accent); }

/* ─── 正文 ─── */
.ed-textarea {
  width: 100%;
  min-height: 220px;
  max-height: calc(100vh - 320px);
  padding: 0;
  border: none;
  background: none;
  font-family: 'Noto Serif SC', serif;
  font-size: 16px;
  line-height: 1.85;
  color: var(--text);
  letter-spacing: .02em;
  resize: none;
  outline: none;
}
.ed-textarea::placeholder { color: var(--muted); opacity: .4; }

/* ─── 落款 ─── */
.ed-colophon { height: 20px; }

/* ─── 发布按钮（右下角悬浮） ─── */
.ed-status {
  position: fixed;
  bottom: 108px; right: 18px;
  font-family: var(--font-body);
  font-size: 11px;
  color: var(--muted);
  z-index: 20;
  display: none;
  max-width: 70%;
  text-align: right;
  line-height: 1.4;
  transition: opacity .4s;
}
.ed-publish {
  position: fixed;
  bottom: 72px; right: 18px;
  padding: 10px 20px;
  border-radius: var(--radius-lg);
  border: none;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-warm) 100%);
  color: #fff;
  font-family: var(--font-disp);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  z-index: 20;
  transition: all .2s var(--ease);
  box-shadow: 0 4px 14px rgba(196,154,108,.3);
  letter-spacing: .02em;
}
.ed-publish:hover {
  opacity: .9;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(196,154,108,.4);
}
.ed-publish:disabled {
  opacity: .35;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

/* ─── 监视器（右下角极弱） ─── */
.ed-metrics {
  position: fixed;
  bottom: 72px; left: 18px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text);
  opacity: .4;
  pointer-events: none;
  z-index: 10;
}
.ed-metrics #edWc { font-weight: 600; }
