/* 菲罗帝尔角色站 —— 白色简明风格 */
:root {
  --ink: #1c1c1c;
  --ink-soft: #444444;
  --ink-faint: #6f6f6f;
  --line: #e3e3e3;
  --accent: #a03040;
  --bg: #ffffff;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 84px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'Noto Serif SC', 'Source Han Serif SC', '思源宋体', 'Songti SC', 'STSong', 'SimSun', serif;
  font-size: 16px;
  line-height: 1.9;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ---------- 顶部导航（常驻） ---------- */
.topnav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  padding: 10px 28px;
}

.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.nav-left {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 26px;
}

/* 导航最左的"返回总站"链接 */
.nav-home {
  display: block;
  padding: 2px 0;
  font-size: 14.5px;
  color: var(--ink-soft);
}
.nav-home:hover { color: var(--accent); text-decoration: none; }

.nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 22px;
}
.nav-list a {
  display: block;
  padding: 2px 0;
  font-size: 14.5px;
  color: var(--ink-soft);
}
.nav-list a:hover { color: var(--accent); text-decoration: none; }
.nav-list a.active { color: var(--accent); font-weight: 700; }

/* 导航中文上方的英文标签（打字机字体，全部大写） */
.nav-en {
  display: block;
  margin-bottom: 1px;
  font-family: 'Special Elite', 'Courier New', Courier, monospace;
  font-size: 10px;
  letter-spacing: 0.16em;
  line-height: 1.3;
  color: var(--ink-faint);
}
.nav-zh { display: block; }

/* ---------- 导航下拉二级菜单 ---------- */
.nav-item { position: relative; }
.submenu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 150px;
  margin: 0;
  padding: 6px 0;
  list-style: none;
  display: none;
  background: var(--bg);
  border: 1px solid var(--line);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
  z-index: 110;
}
.nav-item:hover .submenu,
.nav-item:focus-within .submenu { display: block; }
.submenu a {
  padding: 5px 18px;
  font-size: 13.5px;
  color: var(--ink-soft);
  white-space: nowrap;
}
.submenu a:hover {
  color: var(--accent);
  background: #fafafa;
  text-decoration: none;
}

/* ---------- 导航右侧 BGM 波形图标（静止：扁平灰；播放：加高、与文字同黑） ---------- */
.bgm-btn {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 26px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}
.bgm-btn svg {
  display: block;
  width: 24px;
  height: 22px;
}
.bgm-btn .b {
  fill: #a9a9a9;
  transform-box: fill-box;
  transform-origin: center;
  transition: transform 0.3s ease, fill 0.3s ease;
}
.bgm-btn:hover .b { fill: var(--ink-soft); }
.bgm-btn.playing .b { fill: var(--ink); }
.bgm-btn.playing .b1 { transform: scaleY(2); }
.bgm-btn.playing .b2 { transform: scaleY(1.667); }
.bgm-btn.playing .b3 { transform: scaleY(1.556); }
.bgm-btn.playing .b4 { transform: scaleY(1.667); }
.bgm-btn.playing .b5 { transform: scaleY(2); }

/* ---------- 正文 ---------- */
.content {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 32px 80px;
}

.hero { margin-bottom: 48px; }
.hero h1 {
  position: relative;
  font-size: 44px;
  font-weight: 700;
  margin: 0 0 29px;
  letter-spacing: 0.06em;
}
/* 标题英文签名：手写体、深红、斜跨在中文上、图层在前（位置按样图比例：起于“罗”字中段，右端超出一个标题宽，底边略低于标题底线） */
.h1-en {
  position: absolute;
  left: 83px;
  top: -35px;
  z-index: 1;
  font-family: 'Thesignature', 'Segoe Script', 'Brush Script MT', cursive;
  font-size: 140px;
  font-weight: 400;
  line-height: 1;
  letter-spacing: 0;
  color: #8c0020;
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
}
.h1-zh {
  position: relative;
  z-index: 0;
}
/* “菲”字左下角装饰圆点：右上四分之一扇形被“菲”字压住 */
.h1-zh::before {
  content: '';
  position: absolute;
  left: -4px;
  bottom: -2px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #988a81;
  z-index: -1;
}
.hero .epigraph {
  margin: 0;
  color: var(--ink-soft);
  font-size: 14.5px;
  font-style: italic;
}
.hero .epigraph-en {
  margin: 2px 0 0;
  font-family: 'Special Elite', 'Courier New', Courier, monospace;
  font-style: normal;
  font-size: 13px;
  letter-spacing: 0.03em;
  color: #969491;
  text-align: right;
}

/* ---------- 抬头图（全宽横幅，初始只显示 180~800px 横带，滚动展开全图） ---------- */
.hero-banner {
  position: relative;
  overflow: hidden;
  height: 25.8333vw;
  margin: 0 calc(50% - 50vw) 30px;
}
.hero-banner img {
  position: absolute;
  left: 0;
  top: -7.5vw;
  display: block;
  width: 100%;
  height: auto;
}

section { margin-bottom: 72px; }

h2 {
  font-size: 26px;
  font-weight: 700;
  margin: 0 0 20px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

h3 {
  font-size: 19px;
  font-weight: 700;
  margin: 28px 0 12px;
}

p { margin: 0 0 14px; color: var(--ink); }
p.link-line { font-size: 14px; margin-top: 4px; }
p.tagline { font-weight: 700; }

blockquote {
  margin: 16px 0;
  padding: 2px 0 2px 18px;
  border-left: 2px solid #cccccc;
  color: var(--ink-soft);
  font-size: 13.5px;
}
blockquote p { color: var(--ink-soft); margin-bottom: 8px; }
blockquote p:last-child { margin-bottom: 0; }

/* ---------- 折叠章节 ---------- */
.fold { margin-bottom: 72px; }
.fold > summary {
  list-style: none;
  cursor: pointer;
  position: relative;
  padding: 0 36px 10px 0;
  border-bottom: 1px solid var(--line);
  font-size: 26px;
  font-weight: 700;
  user-select: none;
  -webkit-user-select: none;
}
.fold > summary::-webkit-details-marker { display: none; }
.fold > summary::after {
  content: '−';
  position: absolute;
  right: 6px;
  top: 0;
  color: var(--ink-faint);
  font-weight: 400;
}
.fold:not([open]) > summary::after { content: '+'; }
.fold:not([open]) > summary { margin-bottom: 0; }
.fold[open] > summary { margin-bottom: 24px; }
.fold-title {
  margin: 0 0 24px;
  padding: 0 0 10px;
  border-bottom: 1px solid var(--line);
  font-size: 26px;
  font-weight: 700;
}

/* ---------- 时间线圆弧轮盘 ---------- */
/* 全宽突破：内带上限 1240px 居中，两侧随屏宽自适应 */
.arc-timeline {
  margin: 28px calc(50% - 50vw) 0;
  padding: 0 max(32px, calc(50vw - 620px));
  display: grid;
  grid-template-columns: 340px minmax(0, 1fr);
  align-items: start;
}
.arc-stage {
  position: sticky;
  top: 96px;
  height: 620px;
  overflow: hidden;
}
.arc-rim {
  position: absolute;
  left: 0;
  top: 0;
  width: 340px;
  height: 620px;
}
.arc-spin {
  transition: transform 0.55s cubic-bezier(0.4, 0, 0.2, 1);
  transform-origin: 0 310px;
}
.arc-spin text {
  font-family: inherit;
  transition: transform 0.55s cubic-bezier(0.4, 0, 0.2, 1);
}
.arc-node {
  position: absolute;
  left: 0;
  top: 0;
  transition: transform 0.55s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.4s ease;
}
.arc-node.d0 { z-index: 3; }
.arc-node.d1 { z-index: 2; }
.arc-node.d2 { z-index: 1; }
.arc-label {
  position: absolute;
  left: 0;
  top: 0;
  transform: translate(-50%, -50%);
  padding: 6px 10px;
  border: 0;
  background: transparent;
  font-family: inherit;
  line-height: 1.45;
  text-align: center;
  white-space: nowrap;
  cursor: pointer;
  transition: font-size 0.3s ease, color 0.3s ease;
}
.arc-label .al-title { display: block; }
.arc-node.d0 .arc-label { font-size: 17px; font-weight: 700; color: var(--accent); }
.arc-node.d1 .arc-label { font-size: 14px; color: var(--ink-soft); }
.arc-node.d2 .arc-label { font-size: 12px; color: var(--ink-faint); }
.arc-label:hover { color: var(--accent); }
.arc-panel { padding: 130px 24px 40px 28px; }
.arc-panel-item {
  animation: arcIn 0.45s ease both;
}
.arc-panel-item h3 { margin-top: 0; }
/* 时期图文并排：文字在左、图片在右 */
.arc-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 240px;
  gap: 0 20px;
  align-items: start;
}
.arc-split .arc-text p:last-child { margin-bottom: 0; }
.arc-split figure, .arc-split figure.wide { margin: 0; }
.arc-split figure img { width: 100%; }
.arc-split figcaption { text-align: center; }
@keyframes arcIn {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}

/* ---------- 立绘 ---------- */
.outfit-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 44px 26px;
  align-items: start;
}
.outfit { margin: 0; font-size: 13.5px; }
.outfit p { line-height: 1.8; }
.outfit h3 { font-size: 17px; margin: 0 0 10px; }
.outfit img {
  display: block;
  width: 100%;
  height: auto;
  margin: 0 0 12px;
  border: 1px solid var(--line);
}
.outfit a.img-link { display: block; }
.outfit a.img-link:hover { text-decoration: none; }
.outfit a.img-link img {
  transition: opacity 0.15s ease, border-color 0.15s ease;
}
.outfit a.img-link:hover img {
  opacity: 0.82;
  border-color: var(--accent);
}

/* ---------- 图片（宽图） ---------- */
figure.wide {
  margin: 20px 0;
}
figure.wide img {
  display: block;
  max-width: 100%;
  height: auto;
  border: 1px solid var(--line);
}
figcaption {
  margin-top: 6px;
  font-size: 13px;
  color: var(--ink-faint);
}

/* ---------- 档案三列 ---------- */
.archive-grid {
  display: grid;
  grid-template-columns: 172px minmax(0, 1fr) minmax(0, 2.1fr);
  gap: 0 32px;
  align-items: stretch;
}
.archive-col h3 {
  font-size: 18px;
  margin: 0 0 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}
.archive-photo img {
  display: block;
  width: auto;
  height: 256px;
  border: 1px solid var(--line);
}
.info-line {
  margin: 0 0 6px;
  font-size: 14.5px;
}
.info-line .il-label {
  display: inline-block;
  min-width: 3.5em;
  margin-right: 0.6em;
  color: var(--ink-faint);
}

/* ---------- 雷达图 ---------- */
.radar-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px 40px;
  align-items: start;
  margin: 8px 0 28px;
}
.radar-card h3 {
  text-align: center;
  font-size: 17px;
  margin: 0 0 4px;
}
.radar-card svg {
  display: block;
  width: 100%;
  max-width: 400px;
  height: auto;
  margin: 0 auto;
}
.radar-card svg text { font-family: inherit; }
.radar-card p {
  font-size: 14px;
  margin: 14px 0 0;
}

/* ---------- 人物关系 ---------- */
.relation { margin-bottom: 36px; }
.relation h3 { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.relation .page-link {
  font-size: 13px;
  font-weight: 400;
}

/* ---------- 视频嵌入 ---------- */
.video-wrap {
  margin: 12px 0 8px;
  border: 1px solid var(--line);
  background: #000000;
}
.video-wrap iframe {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 0;
}

/* ---------- 页脚 ---------- */
.footer {
  margin-top: 72px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--ink-faint);
}
.footer p { color: var(--ink-faint); margin-bottom: 6px; }

/* ---------- 子页面 ---------- */
.sub-head {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  padding: 10px 28px;
  display: flex;
  align-items: baseline;
  gap: 18px;
}
.sub-head .back { font-size: 14.5px; }
.sub-head .back:hover { text-decoration: none; color: var(--accent); }
.sub-head .sub-title { font-size: 15px; font-weight: 700; color: var(--ink-soft); }

.sub-content { padding-top: 92px; }
.sub-article h1 {
  font-size: 28px;
  font-weight: 700;
  margin: 0 0 18px;
}
.sub-article p { font-size: 15px; }
.sub-main-img {
  display: block;
  max-width: 360px;
  width: 100%;
  height: auto;
  margin: 18px 0 8px;
  border: 1px solid var(--line);
}

/* ---------- 稿件画廊 ---------- */
.gallery {
  margin-top: 36px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 20px;
}
.gallery-item { display: block; cursor: zoom-in; }
.gallery-item:hover { text-decoration: none; }
.gallery-item img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
  transition: opacity 0.15s ease, border-color 0.15s ease;
}
.gallery-item:hover img {
  opacity: 0.85;
  border-color: var(--accent);
}

/* ---------- 灯箱 ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(18, 18, 18, 0.92);
  cursor: zoom-out;
}
.lightbox.show { display: flex; }
.lightbox img {
  max-width: 92vw;
  max-height: 86vh;
  border: 1px solid #3a3a3a;
  cursor: default;
}
.lb-close {
  position: absolute;
  top: 12px;
  right: 24px;
  color: #dddddd;
  font-size: 32px;
  line-height: 1;
  cursor: pointer;
  user-select: none;
}
.lb-close:hover { color: #ffffff; }
.lb-prev, .lb-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  color: #dddddd;
  font-size: 36px;
  padding: 14px;
  cursor: pointer;
  user-select: none;
}
.lb-prev:hover, .lb-next:hover { color: #ffffff; }
.lb-prev { left: 10px; }
.lb-next { right: 10px; }
.lb-count {
  position: absolute;
  bottom: 14px;
  left: 0;
  right: 0;
  text-align: center;
  color: #cccccc;
  font-size: 13px;
  user-select: none;
}

/* ---------- 响应式 ---------- */
@media (max-width: 900px) {
  html { scroll-padding-top: 100px; }
  .topnav { padding: 10px 16px; }
  .nav-list { gap: 2px 14px; }
  .nav-list a { font-size: 13.5px; }
  .content { padding: 0 18px 64px; }
  .sub-content { padding-top: 88px; }
  .hero h1 { font-size: 34px; margin: 0 0 22px; }
  .h1-en { font-size: 108px; left: 64px; top: -26px; }
  .h1-zh::before { width: 18px; height: 18px; left: 2px; bottom: -2px; }
  .nav-en { font-size: 9px; letter-spacing: 0.1em; }
  .radar-grid { grid-template-columns: 1fr; }
  .archive-grid { gap: 0 14px; }
  .arc-timeline { display: block; margin: 28px 0 0; padding: 0; }
  .arc-stage {
    position: static !important;
    height: auto !important;
    overflow: visible !important;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 4px 0;
  }
  .arc-rim { display: none; }
  .arc-node { position: static !important; transform: none !important; opacity: 1 !important; }
  .arc-label {
    position: static;
    transform: none !important;
    font-size: 13.5px !important;
    font-weight: 400 !important;
    padding: 4px 14px;
    border: 1px solid var(--line);
    border-radius: 999px;
    color: var(--ink-soft) !important;
  }
  .arc-node.d0 .arc-label {
    background: var(--accent);
    border-color: var(--accent);
    color: #ffffff !important;
    font-weight: 700 !important;
  }
  .arc-panel { padding: 20px 0 8px; }
  .arc-split { grid-template-columns: 1fr; }
  .arc-split figure, .arc-split figure.wide { margin: 16px 0 0; }
}

/* 中宽屏：轮盘仍在左侧但面板变窄，图文改为上下排布 */
@media (max-width: 1100px) {
  .arc-split { grid-template-columns: 1fr; }
  .arc-split figure, .arc-split figure.wide { margin: 16px 0 0; }
}
