/* 遍觀页 */
.gv-main { max-width: 1080px; margin: 0 auto; padding: 0 20px 60px; position: relative; z-index: 1; display: block; }
.gv-intro { color: var(--muted); font: 14px/1.7 var(--font-ui); margin: 6px 0 16px; }
.gv-card { background: radial-gradient(ellipse at 25% 15%, #fdfbf6 0%, #f7f1e6 55%, #f1e9da 100%); border: 1px solid #e6dccb; border-radius: 10px;
  padding: 24px 28px 22px; margin-bottom: 24px; box-shadow: 0 1px 0 #fff inset, 0 6px 18px rgba(80, 60, 30, .05); }
.gv-card h2 { font: 26px var(--font-scripture); color: #7a4f26; letter-spacing: .14em; margin: 0 0 4px; }
svg .kai, svg text.kai { font-family: var(--font-scripture); }
.gv-sub { font: 13px/1.7 var(--font-ui); color: var(--muted); margin: 0 0 12px; }
.gv-cap { font: 14px/1.7 var(--font-ui); color: var(--ink); min-height: 1.7em; margin-top: 6px; }
.gv-cap a { color: var(--accent); }
.gv-cap b { font-family: var(--font-answer); }
svg text { font-family: var(--font-ui); }

/* 同心圆 */
.gv-sun-wrap { max-width: 720px; margin: 0 auto; }
#sun { width: 100%; height: auto; display: block; }
#sun path { cursor: pointer; transition: opacity .15s; }
#sun path:hover { opacity: 1 !important; filter: brightness(1.06); }
#sun .ctr { cursor: pointer; }

/* 千丝万缕 */
.gv-weave-wrap { width: 100%; }
#weave { width: 100%; height: auto; display: block; touch-action: pan-y; }
#weave .ln { fill: none; stroke-width: .7; }
#weave.focus .ln { opacity: .05 !important; }
#weave .hl { fill: none; stroke-width: 1.3; opacity: .9; }
#weave.focus .axl { opacity: .12; }

/* 名相分布：一条一个词，共用五分刻度 */
.gv-form { display: flex; gap: 8px; margin: 0 0 16px; max-width: 520px; }
#gv-q { flex: 1; min-width: 0; font: 14px var(--font-ui); padding: 7px 10px; border: 1px solid var(--line); border-radius: 4px; background: var(--bg); color: var(--ink); }
.gv-form button { font: 14px var(--font-ui); padding: 6px 18px; border: 0; border-radius: 4px; background: var(--accent); color: #fff; cursor: pointer; }
.tm { --lbl: 150px; }
.tm-row { display: grid; grid-template-columns: var(--lbl) 1fr; align-items: center; gap: 10px; margin-bottom: 10px; }
.tm-lb { position: relative; min-width: 0; padding-right: 22px; }
.tm-lb b { display: block; font: 19px var(--font-scripture); color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tm-lb small { display: block; font: 11.5px/1.5 var(--font-ui); color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tm-x { position: absolute; right: 0; top: 0; border: 0; background: none; color: var(--muted); font-size: 18px; line-height: 1; cursor: pointer; padding: 2px 4px; }
.tm-x:hover { color: var(--accent); }
.tm-bar { display: flex; align-items: flex-end; height: 48px; background: #f1ece2; border-radius: 2px; position: relative; }
.tm-bar i { flex: 1 1 0; height: 100%; display: flex; align-items: flex-end; padding: 0 .5px; }
.tm-bar i b { width: 100%; background: var(--accent); border-radius: 1px 1px 0 0; }
.tm-bar i.on { cursor: pointer; }
.tm-bar i.on:hover b { background: var(--ink); }
.tm-bar i.cut { box-shadow: inset 1px 0 0 #b9ab95; }          /* 五分分界 */
.tm-head { display: grid; grid-template-columns: var(--lbl) 1fr; gap: 10px; margin-bottom: 6px; }
.tm-parts { display: flex; font: 12px var(--font-ui); color: var(--muted); }
.tm-parts span { text-align: center; border-bottom: 4px solid var(--accent); padding-bottom: 2px; white-space: nowrap; overflow: hidden; }
.tm-ax { display: flex; font: 10px var(--font-ui); color: #9a8f80; }
.tm-ax i { flex: 1 1 0; font-style: normal; text-align: center; white-space: nowrap; overflow: visible; }
.tm-peak { font: 11px var(--font-ui); color: var(--muted); }
.tm-empty { color: var(--muted); font: 13px var(--font-ui); padding: 4px 0 10px; }

/* 标题行与「全屏」 */
.gv-h { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.gv-fs { flex: none; font: 13px var(--font-ui); border: 1px solid var(--line); background: var(--panel); color: var(--ink); border-radius: 4px; padding: 3px 12px; cursor: pointer; }
.gv-fs:hover { border-color: var(--accent); color: var(--accent); }
.gv-card:fullscreen, .gv-card.gv-full { margin: 0; border-radius: 0; border: 0; overflow: auto; background: var(--bg); padding: 22px 34px; }
.gv-card.gv-full { position: fixed; inset: 0; z-index: 1000; }
.gv-card:fullscreen .gv-sun-wrap, .gv-card.gv-full .gv-sun-wrap { max-width: min(96vw, calc(100vh - 170px)); }
.gv-card:fullscreen .net-wrap, .gv-card.gv-full .net-wrap { height: calc(100vh - 230px); }

/* 名相之网 */
.net-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: -6px 0 10px; }
.net-chips span { font: 13px var(--font-ui); border: 1px solid var(--line); border-radius: 14px; padding: 2px 6px 2px 12px; background: var(--bg); }
.net-chips button { border: 0; background: none; color: var(--muted); cursor: pointer; font-size: 15px; padding: 0 4px; }
.net-chips button:hover { color: var(--accent); }
.net-wrap { height: 460px; border: 1px solid #e6dccb; border-radius: 8px; background: radial-gradient(ellipse at 50% 45%, #fdfaf3 0%, #f4ecdd 70%, #ede4d3 100%); }
#net { width: 100%; height: 100%; display: block; touch-action: none; }
#net .edge { stroke: #a07a4c; stroke-linecap: round; cursor: pointer; fill: none; }
#net .edge:hover, #net .edge.on { stroke: #b5432f; opacity: .95 !important; }
#net .node circle { fill: #fbf6ec; stroke: #8a5a2b; stroke-width: 1.4; cursor: grab; }
#net .node .ink { fill: #8a5a2b; fill-opacity: .12; stroke: none; pointer-events: none; }
#net .node text { font: 17px var(--font-scripture); fill: #2b2620; pointer-events: none; }
#net .node .ct { font: 11px var(--font-ui); fill: #7a7064; }
#net .ew { font: 11px var(--font-ui); fill: #8a5a2b; paint-order: stroke; stroke: var(--bg); stroke-width: 3px; pointer-events: none; }
.net-list { list-style: none; margin: 6px 0 0; padding: 0; max-height: 320px; overflow: auto; }
.net-list li { padding: 5px 0; border-bottom: 1px dashed var(--line); font: 15px/1.7 var(--font-scripture); }
.net-list a { font: 12px var(--font-ui); color: var(--accent); margin-right: 10px; text-decoration: none; white-space: nowrap; }
.net-list mark { background: color-mix(in srgb, var(--accent) 22%, transparent); color: inherit; }

/* 古德之声 */
.ms-wrap { overflow-x: auto; }
.ms { display: grid; grid-template-columns: 52px repeat(48, minmax(11px, 1fr)) 58px; gap: 2px; align-items: center; min-width: 720px; }
.ms .nm { font: 20px var(--font-scripture); color: #3a3128; text-align: center; }
.ms .nm.hot, .ms .ax.hot { color: #b5432f; }
.ms.hov .ax:not(.hot) { opacity: .15; }
.ms .ax.hot { position: relative; z-index: 1; overflow: visible; }
.ms .c { height: 30px; border-radius: 2px; background: #ece6da; }
.ms .c.on { cursor: pointer; }
.ms .c.on:hover { outline: 1.5px solid var(--ink); }
.ms .tot { font: 12px var(--font-ui); color: var(--muted); padding-left: 6px; }
.ms .ax { font: 10px var(--font-ui); color: #9a8f80; white-space: nowrap; overflow: visible; height: 16px; }
.ms .band { height: 6px; border-radius: 1px; }

/* 3D：深色画布，像夜空 */
.g3 { position: relative; height: 520px; border-radius: 8px; overflow: hidden; touch-action: none; border: 1px solid #e6dccb;
  background: radial-gradient(ellipse at 50% 45%, #fdfaf3 0%, #f4ecdd 65%, #ebe1cf 100%); }
.g3 canvas { display: block; width: 100% !important; height: 100% !important; cursor: grab; }
.g3-wait { color: #9a8f80; font: 14px var(--font-ui); text-align: center; padding-top: 240px; margin: 0; }
.g3-labels { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.g3-tag { position: absolute; left: 0; top: 0; font: 13px var(--font-scripture); color: #3a3128; white-space: nowrap;
  text-shadow: 0 0 3px #f8f3ea, 0 0 3px #f8f3ea, 0 0 6px #f8f3ea; }
.g3-tag.big { font-size: 18px; color: #6e4520; letter-spacing: .12em; }
.g3-tag.on { color: #b5432f; }
.g3-tag { transition: opacity .2s; }
.g3-quote { margin-top: 6px; font: 16px/1.8 var(--font-scripture); color: var(--ink); }
.gv-card:fullscreen .g3, .gv-card.gv-full .g3 { height: calc(100vh - 220px); }

@media (max-width: 640px) {
  .gv-main { padding: 0 10px 40px; }
  .gv-card { padding: 16px 14px 14px; }
  .gv-card h2 { font-size: 19px; }
  /* 窄屏：名字一行在上，横带占满整宽 */
  .tm-head { grid-template-columns: 1fr; }
  .tm-head > span:first-child { display: none; }
  .tm-row { grid-template-columns: 1fr; gap: 4px; margin-bottom: 14px; }
  .tm-lb { display: flex; align-items: baseline; gap: 8px; }
  .tm-lb b { font-size: 15px; flex: none; }
  .tm-lb .tm-peak { display: none; }
  .tm-bar { height: 40px; }
  .g3 { height: 380px; }
}
