/* site.css —— 站点公共样式（由 lib/generate.js 生成） */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  min-height: 100vh;
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  line-height: 1.6;
}

/* 顶栏 */
.topbar {
  position: relative;
  z-index: 10;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}
.topbar-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 18px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.brand .site-title { font-size: 26px; font-weight: 700; }
.brand .site-intro { font-size: 13px; opacity: 0.7; margin-top: 2px; }
.nav { display: flex; gap: 8px; flex-wrap: wrap; }
.nav-item {
  display: inline-block;
  padding: 8px 16px;
  border-radius: 999px;
  text-decoration: none;
  color: #1f2329;
  background: #eef1f5;
  font-size: 14px;
  transition: all 0.2s;
}
.nav-item:hover { background: #dfe6f0; }
.nav-item.active { background: #2e7cf6; color: #fff; }

/* 简历下载条 */
.resume-bar { max-width: 1200px; margin: 14px auto 0; display: flex; justify-content: flex-end; padding: 0 20px; }
.dl-btn {
  display: inline-block;
  padding: 10px 22px;
  border-radius: 999px;
  background: #2e7cf6;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}
.dl-btn:hover { background: #1f6ae0; }

/* 顶部展示框 */
.hero {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  overflow: hidden;
}
.hero-text {
  font-size: clamp(2.6rem, 9vh, 6.5rem);
  font-weight: 800;
  line-height: 1.35;
  text-align: center;
  letter-spacing: 2px;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.18);
  padding: 0 24px;
}
@media (max-width: 767px) {
  .hero-text { letter-spacing: 1px; }
}

/* 内容区 */
.content { position: relative; }
.has-bg-image .content { background: rgba(255, 255, 255, 0.88); }

/* 画布与等比缩放 */
.scale-wrap { width: 1200px; margin: 0 auto; }
.canvas { position: relative; width: 1200px; min-height: 900px; }

/* 懒加载淡入 */
img.lazy { opacity: 0; transition: opacity 0.5s ease; }
img.lazy.loaded { opacity: 1; }

/* 页脚 */
.footer {
  text-align: center;
  padding: 30px 20px 40px;
  font-size: 14px;
  opacity: 0.75;
}
.footer-icp { margin-top: 10px; font-size: 12px; opacity: 0.85; }
.footer-icp a { color: inherit; text-decoration: none; }
.footer-icp a:hover { text-decoration: underline; }

/* 状态角标 */
.status-badge {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
  cursor: pointer;
  user-select: none;
}
.status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #bbb;
}
.status-dot.ok { background: #2ecc71; }
.status-dot.bad { background: #e74c3c; }
.status-label { font-size: 13px; color: #1f2329; }
.status-panel {
  position: absolute;
  right: 0;
  bottom: 46px;
  width: 240px;
  padding: 12px 14px;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.2);
  display: none;
  cursor: default;
  text-align: left;
}
.status-badge:hover .status-panel { display: block; }
.status-row { display: flex; justify-content: space-between; gap: 8px; font-size: 13px; padding: 3px 0; }
.status-row .k { color: #666; }
.status-row .v { color: #1f2329; font-weight: 600; }

/* 灯箱 */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(0, 0, 0, 0.9);
  display: none;
  align-items: center;
  justify-content: center;
}
.lightbox.show { display: flex; }
.lightbox-close {
  position: absolute;
  top: 18px;
  right: 24px;
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
}
.lightbox-img { max-width: 92vw; max-height: 90vh; object-fit: contain; }

/* 简历 PDF */
.pdf-frame {
  display: block;
  width: 1120px;
  height: 1300px;
  margin: 40px auto;
  border: 1px solid #e0e3e8;
  border-radius: 8px;
  background: #fff;
}

/* 状态页（简约版）：红绿灯 + 服务器时间 + 服务版本 */
.status-page {
  padding: 46px 30px;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 2px 14px rgba(0, 0, 0, 0.05);
  margin: 40px auto;
  max-width: 560px;
  text-align: center;
}
.st-light {
  width: 22px; height: 22px;
  border-radius: 50%;
  margin: 0 auto 12px;
  background: #bbb;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.15);
}
.st-light.ok { background: #2ecc71; box-shadow: 0 0 16px rgba(46, 204, 113, 0.7); }
.st-light.bad { background: #e74c3c; box-shadow: 0 0 16px rgba(231, 76, 60, 0.7); }
.st-state { font-size: 20px; font-weight: 700; margin-bottom: 18px; }
.st-line {
  display: flex; justify-content: space-between; gap: 12px;
  font-size: 14px; padding: 8px 0;
  border-top: 1px solid #f0f2f5;
  max-width: 360px; margin: 0 auto;
}
.st-line .k { color: #8a919c; }
.st-line .v { font-weight: 600; font-variant-numeric: tabular-nums; }
.st-hint { margin-top: 20px; font-size: 12px; color: #b3b9c2; }

/* 任务状态行 */
.st-task {
  margin: 16px auto 0;
  border-top: 1px solid #f0f2f5;
  padding-top: 14px;
  max-width: 360px;
  text-align: left;
}
.st-task-title { font-size: 13px; color: #8a919c; margin-bottom: 8px; }
.st-task-row { display: flex; justify-content: space-between; align-items: center; font-size: 14px; }
.st-task-row .k { color: #8a919c; }
.st-task-val { display: flex; align-items: center; gap: 7px; font-weight: 600; }
.st-task-light {
  width: 10px; height: 10px;
  border-radius: 50%;
  display: inline-block;
  background: #ccc;
}
.st-task-light.green { background: #2ecc71; box-shadow: 0 0 8px rgba(46, 204, 113, 0.6); }
.st-task-light.yellow { background: #f5c518; box-shadow: 0 0 8px rgba(245, 197, 24, 0.6); }

/* ===== 音乐播放器 ===== */
.mp-player {
  display: flex;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid #e0e3e8;
  border-radius: 12px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.12);
  padding: 12px 14px;
  overflow: hidden;
}
.mp-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.mp-now {
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
}
.mp-controls { display: flex; gap: 6px; }
.mp-btn {
  width: 34px; height: 34px;
  border: 1px solid #d8dce3;
  border-radius: 50%;
  background: #fff;
  font-size: 15px;
  cursor: pointer;
  line-height: 1;
  display: flex; align-items: center; justify-content: center;
  color: #1f2329;
}
.mp-btn:hover { background: #f2f5f9; border-color: #2e7cf6; }
.mp-btn.on { background: #eaf1fe; border-color: #2e7cf6; color: #2e7cf6; }
.mp-play { background: #2e7cf6; border-color: #2e7cf6; color: #fff; }
.mp-play:hover { background: #1f6ae0; color: #fff; }
.mp-bar {
  height: 5px;
  background: #e8ebf0;
  border-radius: 3px;
  margin: 10px 0 4px;
  overflow: hidden;
  cursor: pointer;
}
.mp-fill { height: 100%; width: 0%; background: #2e7cf6; border-radius: 3px; }
.mp-time { font-size: 11px; color: #8a919c; margin-bottom: 6px; }
.mp-list {
  list-style: none;
  margin: 0;
  padding: 0;
  overflow-y: auto;
  flex: 1;
  min-height: 0;
}
.mp-track {
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding: 6px 8px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
}
.mp-track:hover { background: #f2f5f9; }
.mp-track.active { background: #eaf1fe; }
.mp-t-title { font-weight: 600; }
.mp-t-desc { font-size: 11.5px; color: #8a919c; }

/* 空闲动作触发后提示访客点击播放 */
.mp-pulse {
  animation: mpPulse 1.2s ease-in-out infinite;
  border-color: #2e7cf6;
  box-shadow: 0 0 0 6px rgba(46, 124, 246, 0.15);
}
@keyframes mpPulse {
  0% { box-shadow: 0 0 0 4px rgba(46, 124, 246, 0.25); }
  50% { box-shadow: 0 0 0 10px rgba(46, 124, 246, 0.08); }
  100% { box-shadow: 0 0 0 4px rgba(46, 124, 246, 0.25); }
}

/* ===== 手机端流式排版（<768px 自动切换，排版整齐不缩字） ===== */
.mobile-flow { display: none; }
@media (max-width: 767px) {
  .scale-wrap { display: none; }
  .mobile-flow { display: block; padding: 0 10px; }
  .mobile-flow .m-el {
    margin: 0 auto 12px;
    max-width: 640px;
    border-radius: 10px;
    overflow: hidden;
  }
  .mobile-flow .m-img img { width: 100%; height: auto; display: block; }
  .mobile-flow .mp-player {
    position: static !important;
    width: 100% !important;
    height: auto !important;
    min-height: 230px;
    max-width: 640px;
    margin: 0 auto 12px;
  }
  .mobile-flow .pdf-frame { width: 100% !important; height: 1100px; margin: 12px auto; }
  .mobile-flow .status-page { padding: 20px 16px; }
  .topbar-inner { padding: 12px 14px; }
  .footer { padding: 20px 14px 30px; }
}
