/* ============ 调查系统页专用样式 ============ */

.investigate-header {
  padding-bottom: 32px;
}

.investigate-header .container {
  position: relative;
  z-index: 1;
}

/* 阶段进度条 */
.stage-progress-bar {
  display: flex;
  align-items: center;
  margin-top: 32px;
  gap: 8px;
}

.stage-step {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 16px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-pill);
  backdrop-filter: blur(4px);
  transition: all 0.3s;
}

.stage-step.active {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.5);
}

.stage-step.completed {
  background: var(--accent);
  border-color: var(--accent-light);
}

.stage-step-num {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
}

.stage-step.completed .stage-step-num {
  background: #fff;
  color: var(--accent);
}

.stage-step-label {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 500;
}

.stage-step-divider {
  flex: 1;
  height: 1px;
  background: rgba(255, 255, 255, 0.2);
  max-width: 40px;
}

@media (max-width: 768px) {
  .stage-step-label { display: none; }
  .stage-progress-bar { gap: 4px; }
  .stage-step { padding: 6px 10px; }
}

/* ============ 主体布局 ============ */
.investigate-main {
  padding: 40px 0 64px;
  flex: 1;
}

/* 姊妹系统联动入口条 */
.sister-system-bar {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 18px;
  margin-bottom: 24px;
  background: var(--info-bg);
  border: 1px solid var(--info);
  border-left: 4px solid var(--info);
  border-radius: var(--radius);
  font-size: 13.5px;
  color: #2a4258;
}
.sister-system-bar .ss-icon { font-size: 22px; flex-shrink: 0; }
.sister-system-bar .ss-text { flex: 1; line-height: 1.6; }
.sister-system-bar .ss-text strong { color: var(--info); }
@media (max-width: 600px) {
  .sister-system-bar { flex-wrap: wrap; }
  .sister-system-bar .btn { width: 100%; }
}

.investigate-layout {
  display: grid;
  /* 内容区在左，侧边栏（搜索块/已查阅档案）在右 */
  grid-template-columns: 1fr 280px;
  gap: 28px;
  align-items: start;
  min-width: 0;
}

@media (max-width: 900px) {
  .investigate-layout {
    grid-template-columns: 1fr;
  }
  /* 单列布局下恢复自动排列，保持移动端搜索框在上的体验 */
  .investigate-content,
  .investigate-sidebar {
    grid-column: auto;
    grid-row: auto;
  }
}

/* ============ 左侧内容区 ============ */
.investigate-content {
  display: flex;
  flex-direction: column;
  gap: 24px;
  min-width: 0;
  grid-column: 1;
  grid-row: 1;
}

/* ============ 档案馆 ============ */
.archive-hall {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 24px 28px;
  box-shadow: var(--shadow-sm);
}

.hall-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--primary-bg);
}

.hall-title {
  font-family: var(--font-serif);
  font-size: 20px;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 4px;
}

.hall-desc {
  font-size: 13px;
  color: var(--text-light);
}

.hall-section {
  margin-bottom: 24px;
}

.hall-section:last-child {
  margin-bottom: 0;
}

.hall-section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  padding: 6px 0;
}

.hall-section-title {
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 600;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 8px;
}

.hall-section-title .chapter-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  font-family: var(--font-sans);
}

.hall-section-title .chapter-tag.completed {
  background: var(--accent);
}

.hall-section-title .chapter-tag.locked {
  background: var(--text-muted);
}

.hall-section-status {
  font-size: 12px;
  color: var(--text-light);
  font-family: var(--font-mono);
  padding: 3px 10px;
  background: var(--bg-alt);
  border-radius: var(--radius-pill);
}

.hall-section-status.completed {
  color: var(--accent);
  background: var(--accent-bg);
}

.hall-section-status.active {
  color: var(--primary);
  background: var(--primary-bg);
}

.hall-section-status.locked {
  color: var(--text-muted);
}

.hall-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 10px;
}

.hall-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 20px;
  color: var(--text-muted);
  font-size: 13px;
  font-style: italic;
}

/* 档案卡片 */
.hall-card {
  padding: 12px 14px;
  background: var(--bg-page);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 0.2s;
  position: relative;
  overflow: hidden;
}

.hall-card::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--border);
  transition: background 0.2s;
}

.hall-card:hover:not(.locked) {
  background: #fff;
  border-color: var(--primary-light);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.hall-card:hover:not(.locked)::before {
  background: var(--primary);
}

.hall-card.read {
  background: var(--primary-bg);
  border-color: var(--primary-light);
}

.hall-card.read::before {
  background: var(--primary);
}

.hall-card.read .hall-card-status {
  color: var(--primary);
  font-weight: 600;
}

.hall-card.locked {
  opacity: 0.55;
  cursor: not-allowed;
  background: var(--bg-alt);
}

.hall-card.locked::before {
  background: var(--text-muted);
}

.hall-card.easter {
  background: var(--accent-bg);
  border-color: var(--accent-light);
}

.hall-card.easter::before {
  background: var(--accent);
}

.hall-card.easter .hall-card-status {
  color: var(--accent);
}

.hall-card.final {
  border-color: var(--danger);
}

.hall-card.final::before {
  background: var(--danger);
}

.hall-card-num {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 4px;
  letter-spacing: 0.5px;
}

.hall-card-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 6px;
  line-height: 1.4;
  min-height: 18px;
}

.hall-card.locked .hall-card-title {
  color: var(--text-muted);
  font-style: italic;
}

.hall-card-status {
  font-size: 11px;
  color: var(--text-light);
  display: flex;
  align-items: center;
  gap: 4px;
}

/* ============ 档案详情区 ============ */
.archive-detail {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  box-shadow: var(--shadow-sm);
}

.detail-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-light);
}

.detail-title {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 600;
  color: var(--text-main);
}

.detail-hint {
  font-size: 12px;
  color: var(--text-light);
}

/* ============ 侧边栏 ============ */
.investigate-sidebar {
  position: sticky;
  top: 88px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-height: calc(100vh - 100px);
  grid-column: 2;
  grid-row: 1;
}

@media (max-width: 900px) {
  .investigate-sidebar {
    position: static;
    max-height: none;
  }
}

.sidebar-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow-sm);
}

.sidebar-card-title {
  font-family: var(--font-serif);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 6px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-light);
}

.sidebar-icon {
  font-size: 16px;
}

.history-count {
  margin-left: auto;
  background: var(--primary-bg);
  color: var(--primary);
  font-size: 12px;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  font-weight: 600;
}

/* 搜索框 */
.search-input-wrap {
  display: flex;
  gap: 8px;
  width: 100%;
}

.search-input {
  flex: 1 1 auto;
  min-width: 0;
  padding: 9px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-page);
  color: var(--text-main);
  font-size: 14px;
  outline: none;
  transition: all 0.2s;
}

.search-input:focus {
  border-color: var(--primary);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(45, 90, 63, 0.12);
}

.search-btn {
  flex: 0 0 auto;
  padding: 9px 18px;
  background: var(--primary);
  color: #fff;
  border-radius: var(--radius);
  font-size: 13px;
  font-weight: 500;
  transition: all 0.2s;
  white-space: nowrap;
}

.search-btn:hover {
  background: var(--primary-dark);
}

.search-result {
  margin-top: 10px;
  font-size: 12px;
  color: var(--text-light);
  min-height: 16px;
}

.search-result.error { color: var(--danger); }
.search-result.success { color: var(--primary); }

.search-suggestions {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px dashed var(--border);
}

.suggestion-label {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.suggestion-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.suggestion-tag {
  display: inline-block;
  padding: 3px 10px;
  background: var(--bg-alt);
  color: var(--text-light);
  border-radius: var(--radius-pill);
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s;
  border: 1px solid transparent;
}

.suggestion-tag:hover {
  background: var(--primary-bg);
  color: var(--primary);
  border-color: var(--primary-light);
}

/* 字母收集 */
.letter-collection {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}

.letter-slot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 34px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
  font-size: 16px;
  font-weight: 700;
  color: var(--text-muted);
  background: var(--bg-page);
  transition: all 0.3s;
}

.letter-slot.filled {
  color: #fff;
  background: var(--primary);
  border-color: var(--primary);
  box-shadow: 0 2px 6px rgba(45, 90, 63, 0.3);
  animation: fade-in 0.4s;
}

.letter-slot.unlocked {
  color: #fff;
  background: var(--accent);
  border-color: var(--accent);
  box-shadow: 0 2px 8px rgba(184, 132, 46, 0.4);
}

.letter-hint {
  font-size: 12px;
  color: var(--text-light);
  line-height: 1.6;
  padding: 8px 10px;
  background: var(--bg-alt);
  border-radius: var(--radius-sm);
}

.letter-hint strong {
  color: var(--primary);
}

/* 进度列表 */
.progress-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.progress-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 12px;
  background: var(--bg-page);
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--border);
  font-size: 13px;
  transition: all 0.2s;
}

.progress-item.active {
  border-left-color: var(--primary);
  background: var(--primary-bg);
}

.progress-item.completed {
  border-left-color: var(--accent);
  background: var(--accent-bg);
}

.progress-item.locked {
  opacity: 0.55;
}

.progress-stage {
  font-weight: 600;
  color: var(--text-main);
}

.progress-item.locked .progress-stage {
  color: var(--text-light);
}

.progress-status {
  font-size: 12px;
  color: var(--text-light);
  font-family: var(--font-mono);
}

.progress-item.completed .progress-status {
  color: var(--accent);
  font-weight: 600;
}

/* 历史列表 */
.sidebar-card-history {
  display: flex;
  flex-direction: column;
  max-height: 520px;
}

/* 历史记录过滤栏 */
.history-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 1px dashed var(--border);
}

.hf-btn {
  flex: 1 1 auto;
  min-width: 48px;
  padding: 4px 8px;
  font-size: 11px;
  color: var(--text-light);
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}

.hf-btn:hover {
  color: var(--primary);
  border-color: var(--primary-light);
}

.hf-btn.active {
  color: #fff;
  background: var(--primary);
  border-color: var(--primary);
}

.history-list {
  flex: 1;
  overflow-y: auto;
  margin: 0 -4px;
  padding: 0 4px;
}

.history-list::-webkit-scrollbar {
  width: 4px;
}

.history-list::-webkit-scrollbar-thumb {
  background: var(--border-strong);
  border-radius: 2px;
}

.history-empty {
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
  padding: 16px 0;
}

.history-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  color: var(--text-body);
  cursor: pointer;
  transition: all 0.15s;
  margin-bottom: 2px;
}

.history-item:hover {
  background: var(--primary-bg);
  color: var(--primary);
}

.history-item .h-id {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  color: var(--text-body);
  background: var(--bg-alt);
  padding: 1px 6px;
  border-radius: 3px;
  flex: 0 0 auto;
}
.history-item .h-title {
  flex: 1; min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.history-item .h-stage {
  flex: 0 0 auto;
  font-size: 10px; color: var(--text-muted);
  background: var(--bg-page); padding: 1px 5px; border-radius: 3px;
  border: 1px solid var(--border);
}

.reset-btn {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed var(--border);
  color: var(--text-muted);
  font-size: 12px;
  text-align: center;
  width: 100%;
  transition: color 0.2s;
}

.reset-btn:hover {
  color: var(--danger);
}

/* 录音播放器（内联于正文，宽度与文字稿对齐） */
.archive-audio-inline {
  margin: 8px 0 12px;
  max-width: 360px;
  line-height: 1;
  font-size: 0;
}

.archive-audio-label {
  font-size: 12px;
  color: var(--text-light);
  margin-bottom: 4px;
  font-family: var(--font-mono);
  line-height: 1.4;
}

.archive-audio {
  display: block;
  width: 100%;
  max-width: 360px;
  height: 32px;
  line-height: 0;
  vertical-align: bottom;
}

/* ============ 档案展示区 ============ */
.archive-viewer {
  min-height: 200px;
}

/* 空状态 */
.empty-state {
  padding: 40px 24px;
  text-align: center;
}

.empty-icon {
  font-size: 56px;
  color: var(--primary-light);
  margin-bottom: 20px;
  opacity: 0.6;
}

.empty-title {
  font-family: var(--font-serif);
  font-size: 24px;
  color: var(--text-main);
  margin-bottom: 16px;
}

.empty-desc {
  font-size: 14px;
  color: var(--text-light);
  line-height: 2;
  max-width: 640px;
  margin: 0 auto;
  text-align: left;
  background: var(--bg-page);
  padding: 24px 28px;
  border-radius: var(--radius);
  border-left: 3px solid var(--primary);
}

.empty-hint {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: var(--accent-bg);
  border-radius: var(--radius-pill);
  font-size: 13px;
  color: var(--text-body);
}

.empty-hint code {
  font-family: var(--font-mono);
  background: #fff;
  padding: 2px 8px;
  border-radius: 4px;
  color: var(--accent);
  font-weight: 600;
  border: 1px solid var(--accent-light);
}

/* 无结果提示状态 */
.no-result-state {
  padding: 40px 24px;
  text-align: center;
  animation: fade-in 0.4s;
}

.no-result-icon {
  font-size: 56px;
  color: var(--text-muted);
  margin-bottom: 20px;
  opacity: 0.7;
}

.no-result-title {
  font-family: var(--font-serif);
  font-size: 20px;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 12px;
}

.no-result-desc {
  font-size: 14px;
  color: var(--text-light);
  line-height: 1.8;
  margin-bottom: 16px;
}

.no-result-hint {
  font-size: 13px;
  color: var(--text-body);
  line-height: 1.8;
  padding: 12px 18px;
  background: var(--accent-bg);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius-sm);
  max-width: 520px;
  margin: 0 auto;
  text-align: left;
}

/* ============ 密码面板 ============ */
.password-panel {
  background: linear-gradient(135deg, #fffaf0 0%, #fffdf7 100%);
  border: 1px solid var(--accent-light);
  border-left: 4px solid var(--accent);
  border-radius: var(--radius-lg);
  padding: 28px 32px;
  margin-bottom: 24px;
  position: relative;
  overflow: hidden;
  animation: fade-in 0.5s;
}

.password-panel.locked {
  opacity: 0.5;
  pointer-events: none;
  filter: grayscale(0.5);
}

.password-panel::before {
  content: '🔐';
  position: absolute;
  top: 20px;
  right: 24px;
  font-size: 32px;
  opacity: 0.15;
}

.password-panel.unlocked {
  background: linear-gradient(135deg, #f0fff4 0%, #f8fffb 100%);
  border-color: var(--primary-light);
  border-left-color: var(--primary);
}

.password-panel.unlocked::before {
  content: '✓';
  color: var(--primary);
  opacity: 0.3;
  font-size: 48px;
  font-weight: 700;
}

.password-title {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 6px;
  letter-spacing: 1px;
}

.password-panel.unlocked .password-title {
  color: var(--primary);
}

.password-hint {
  font-size: 13px;
  color: var(--text-light);
  margin-bottom: 16px;
  line-height: 1.7;
}

.password-input-row {
  display: flex;
  gap: 10px;
  align-items: stretch;
  width: 100%;
}

.password-input {
  flex: 1 1 auto;
  min-width: 0;
  padding: 12px 16px;
  border: 1.5px solid var(--accent);
  border-radius: var(--radius);
  background: #fff;
  color: var(--text-main);
  font-family: var(--font-mono);
  font-size: 18px;
  letter-spacing: 4px;
  font-weight: 600;
  text-transform: uppercase;
  outline: none;
  transition: all 0.2s;
}

.password-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(184, 132, 46, 0.15);
}

.password-btn {
  flex: 0 0 auto;
  padding: 12px 28px;
  background: var(--accent);
  color: #fff;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 1px;
  transition: all 0.2s;
  white-space: nowrap;
}

.password-btn:hover {
  background: #9a6f24;
  transform: translateY(-1px);
  box-shadow: var(--shadow);
}

.password-msg {
  margin-top: 12px;
  font-size: 13px;
  min-height: 18px;
}

.password-msg.error {
  color: var(--danger);
  animation: shake 0.4s;
}

.password-msg.success {
  color: var(--primary);
  font-weight: 600;
}

/* ============ 档案卡片 ============ */
.archive-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  margin-bottom: 20px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  animation: fade-in 0.4s;
  transition: box-shadow 0.3s;
}

.archive-card:hover {
  box-shadow: var(--shadow-md);
}

.archive-card.easter {
  border-left: 3px solid var(--accent);
}

.archive-card.final {
  border: 1px solid var(--danger);
  border-left: 4px solid var(--danger);
}

.archive-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  background: linear-gradient(180deg, var(--bg-section) 0%, var(--bg-card) 100%);
  border-bottom: 1px solid var(--border-light);
  cursor: pointer;
  user-select: none;
  transition: background 0.15s;
}
.archive-header:hover { background: linear-gradient(180deg, var(--bg-tint) 0%, var(--bg-card) 100%); }
.archive-header-main {
  display: flex; align-items: center; gap: 12px;
  flex: 1 1 auto; min-width: 0;
}
.archive-toggle {
  flex: 0 0 auto;
  font-size: 12px; color: var(--text-muted);
  transition: transform 0.2s;
  display: inline-block;
}
.archive-card.expanded .archive-toggle { transform: rotate(90deg); }

.archive-card-body { display: none; }
.archive-card.expanded .archive-card-body { display: block; }

.badge-read {
  background: var(--primary-bg, #e8f0ec);
  color: var(--primary, #2d5a3f);
  font-weight: 600;
}

.archive-title {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 600;
  color: var(--text-main);
}

.archive-meta {
  display: flex;
  gap: 6px;
  align-items: center;
}

.archive-body {
  padding: 24px 28px;
  font-size: 14px;
  line-height: 1.9;
  color: var(--text-body);
  font-family: var(--font-mono);
  white-space: pre-wrap;
  word-break: break-word;
  background: #fdfdfb;
}

.archive-body .hl {
  color: var(--danger);
  font-weight: 600;
  background: var(--danger-bg);
  padding: 0 4px;
  border-radius: 3px;
}

.archive-body .keyword {
  color: var(--primary);
  font-weight: 600;
  border-bottom: 1px dotted var(--primary-light);
}

/* 线索词 - 可搜索的人名/术语/代号，加粗金色提示下一步检索方向 */
.archive-body .clue {
  color: var(--accent);
  font-weight: 700;
  border-bottom: 2px solid var(--accent);
  padding: 0 1px;
  cursor: help;
  transition: background 0.2s;
}

.archive-body .clue:hover {
  background: var(--accent-bg);
}

/* 隐藏批注 */
.archive-hidden {
  margin: 0 28px 20px;
  padding: 14px 18px;
  background: linear-gradient(135deg, var(--accent-bg) 0%, #fffaeb 100%);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius-sm);
  font-style: italic;
  font-size: 13.5px;
  color: var(--text-light);
  font-family: var(--font-serif);
  position: relative;
  transition: all 0.3s;
  cursor: help;
}

.archive-hidden::before {
  content: '✎';
  position: absolute;
  top: 10px;
  right: 14px;
  font-size: 16px;
  color: var(--accent);
  opacity: 0.5;
  font-style: normal;
}

.archive-hidden:hover {
  background: linear-gradient(135deg, #fff5d6 0%, #ffeb99 100%);
  color: var(--text-main);
  box-shadow: var(--shadow);
}

.archive-hidden .key-word {
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 1px;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.5);
  padding: 1px 6px;
  border-radius: 3px;
  border: 1px dashed var(--accent);
}

.archive-hidden:hover .key-word {
  background: #fff;
  color: var(--accent);
}

/* 下一步搜索提示 */
.archive-hint {
  margin: 0 24px 16px;
  padding: 10px 14px;
  background: var(--info-bg, #e8eef4);
  border-left: 3px solid var(--info, #3a5a7c);
  border-radius: var(--radius-sm, 4px);
  font-family: var(--font-sans);
  font-size: 13px;
  color: var(--text-body, #3a4a42);
  line-height: 1.6;
}

/* 档案原件图片 */
.archive-image-wrap {
  padding: 0 28px 16px;
  background: #fdfdfb;
  text-align: center;
}
.archive-image {
  max-width: 100%;
  max-height: 420px;
  border-radius: 4px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
  cursor: zoom-in;
  transition: transform 0.2s;
}
.archive-image:hover { transform: scale(1.01); }

/* 档案页脚 */
.archive-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 24px;
  background: var(--bg-alt);
  border-top: 1px solid var(--border-light);
  font-size: 12px;
  flex-wrap: wrap;
  gap: 8px;
}

.archive-footer .letter-found {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  background: var(--accent-bg);
  color: var(--accent);
  border-radius: var(--radius-pill);
  font-weight: 600;
}

.archive-footer .letter-found .letter-char {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  background: var(--accent);
  color: #fff;
  border-radius: 50%;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 12px;
}

.archive-footer .next-hint {
  color: var(--text-light);
}

.archive-footer .next-hint::before {
  content: '› ';
  color: var(--primary);
  font-weight: 700;
}

/* ============ 阶段通关提示弹窗 ============ */
.stage-complete-modal {
  position: fixed; inset: 0; z-index: 1100;
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
  opacity: 0; transition: opacity 0.3s;
}
.stage-complete-modal.open { opacity: 1; }
.stage-complete-backdrop {
  position: absolute; inset: 0;
  background: rgba(20, 30, 25, 0.6);
  backdrop-filter: blur(6px);
}
.stage-complete-card {
  position: relative; z-index: 1;
  background: linear-gradient(135deg, #fffaf0 0%, #fffdf7 100%);
  border: 1px solid var(--accent-light);
  border-left: 4px solid var(--accent);
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 60px rgba(184, 132, 46, 0.25);
  max-width: 460px; width: 100%;
  padding: 36px 32px 28px;
  text-align: center;
  transform: translateY(16px) scale(0.96);
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.stage-complete-modal.open .stage-complete-card { transform: translateY(0) scale(1); }
.stage-complete-icon {
  font-size: 40px; color: var(--accent);
  margin-bottom: 12px;
  text-shadow: 0 0 16px rgba(184, 132, 46, 0.4);
}
.stage-complete-title {
  font-family: var(--font-serif); font-size: 22px; font-weight: 700;
  color: var(--text-main); margin: 0 0 10px;
}
.stage-complete-subtitle {
  font-size: 14px; line-height: 1.7;
  color: var(--text-light); margin: 0 0 20px;
}
.stage-complete-hint {
  padding: 12px 16px; margin-bottom: 22px;
  background: var(--accent-bg);
  border-radius: var(--radius);
  font-size: 14px; color: var(--text-body);
}
.stage-complete-hint code {
  font-family: var(--font-mono); font-size: 15px;
  background: #fff; color: var(--accent);
  padding: 3px 12px; border-radius: 4px;
  font-weight: 700; margin-left: 4px;
  border: 1px solid var(--accent-light);
}
.stage-complete-btn {
  padding: 10px 32px;
  background: var(--accent); color: #fff;
  border: none; border-radius: var(--radius);
  font-family: var(--font-sans); font-size: 14px; font-weight: 600;
  letter-spacing: 1px; cursor: pointer;
  transition: background 0.2s, transform 0.1s;
}
.stage-complete-btn:hover { background: #9a6f24; transform: translateY(-1px); }
.stage-complete-btn:active { transform: translateY(0); }
