

.party-page { padding-top: var(--s-5); }

.pc-tabs {
  display: flex; flex-wrap: wrap; align-items: stretch; gap: 2px;
  margin: 0 0 var(--s-6); border-bottom: 1px solid var(--line);
}
.pc-tab {
  position: relative; flex: 0 0 auto; min-width: 104px; display: grid; justify-items: center; align-content: start; gap: 8px;
  padding: 12px 10px 14px; text-align: center;
  color: var(--ink-2); text-decoration: none; border-radius: var(--r-2) var(--r-2) 0 0;
  transition: background var(--dur-1), color var(--dur-1);
}
.pc-tab > span:last-child { display: grid; justify-items: center; gap: 2px; line-height: 1.15; }
.pc-tab .t-name { font-family: var(--f-display); font-size: 1.15rem; color: var(--ink); white-space: nowrap; }
.pc-tab .t-cls { font-family: var(--f-ui-sc); font-weight: 700; font-size: 10.5px; letter-spacing: .08em; color: var(--ink-3); font-variant-numeric: lining-nums; white-space: nowrap; }
.pc-tab:hover { background: var(--ground-2); }
.pc-tab:hover .t-name { color: var(--brass-hi); }
.pc-tab.on::after {
  content: ""; position: absolute; left: 24%; right: 24%; bottom: -1px; height: 3px; border-radius: 3px 3px 0 0; background: var(--brass);
}
.pc-tab.on .t-name { color: var(--brass-hi); }
.pc-tab.former { opacity: .78; min-width: 96px; }
.pc-tab.former .portrait { margin: 6px 0; } 
.pc-tab.former .t-name { font-size: 1rem; }
.pc-tab.former:hover, .pc-tab.former.on { opacity: 1; }
.pc-tabs-sep { flex: none; width: 1px; margin: 18px 12px; background: var(--line-2); }

.dossier { display: grid; grid-template-columns: minmax(260px, 340px) minmax(0, 1fr); gap: clamp(28px, 3.4vw, 56px); align-items: start; }
.dossier-art { position: sticky; top: calc(var(--bar-h) + 24px); display: grid; gap: var(--s-5); }
.art-frame {
  margin: 0; padding: 7px; border-radius: var(--r-2); background: var(--ground-2);
  box-shadow: 0 0 0 1px var(--line-2), var(--shadow-2);
}
.art-frame img {
  display: block; width: 100%; aspect-ratio: 4 / 5; height: auto; object-fit: cover; object-position: var(--focus-pos, 50% 30%);
  border-radius: 3px; box-shadow: 0 0 0 1px color-mix(in srgb, var(--brass) 55%, transparent);
}
.art-frame { position: relative; }
.art-frame.lost img { filter: grayscale(1) sepia(.2) brightness(.82) contrast(1.05); }

.art-frame.erased img:first-child {
  filter: grayscale(1) contrast(.9) brightness(1.04); opacity: .72;
  -webkit-mask: linear-gradient(180deg, #000 0 30%, transparent 96%), repeating-linear-gradient(0deg, #000 0 2px, rgba(0,0,0,.25) 2px 4px);
  -webkit-mask-composite: source-in;
          mask: linear-gradient(180deg, #000 0 30%, transparent 96%), repeating-linear-gradient(0deg, #000 0 2px, rgba(0,0,0,.25) 2px 4px);
          mask-composite: intersect;
  box-shadow: none;
}
.art-frame .erased-badge {
  position: absolute; right: -16px; bottom: -16px; width: 92px; height: 92px; aspect-ratio: 1; border-radius: 50%;
  object-fit: cover; box-shadow: 0 0 0 2px var(--ground), var(--shadow-2);
}

.moment-list { display: grid; gap: 14px; }
.moment-list li { display: grid; grid-template-columns: 52px minmax(0, 1fr); gap: 12px; align-items: start; }
.moment-list .chip.session { justify-self: start; margin-top: 2px; }
.moment-list .m-title { font-family: var(--f-display); font-size: 1.1rem; color: var(--ink); text-decoration: none; }
.moment-list .m-title:hover { color: var(--brass-hi); }
.moment-list p { margin-top: 2px; color: var(--ink-2); line-height: 1.5; max-width: 70ch; }
details.moments-all { margin-top: var(--s-4) !important; }
details.moments-all .moment-list { margin-top: var(--s-4); }
.former .spotlight, .former .spotlight + section { margin-top: var(--s-7); }

.companions h4 { font-family: var(--f-ui-sc); font-weight: 700; font-size: 12px; letter-spacing: .12em; color: var(--ink-3); margin-bottom: 10px; }
.companion { display: grid; grid-template-columns: auto 1fr; gap: 12px; align-items: start; }
.companion + .companion { margin-top: 12px; }
.companion strong { font-family: var(--f-display); font-weight: 400; font-size: 1.15rem; }
.companion p { margin-top: 2px; line-height: 1.4; }

.pc-head { margin-bottom: var(--s-5); }
.pc-head h1 { font-size: var(--t-3xl); margin: 6px 0 8px; text-wrap: balance; }
.pc-tagline { font-family: var(--f-body); font-style: italic; font-size: var(--t-lg); color: var(--ink-2); max-width: 46ch; text-wrap: pretty; }
.pc-build { margin-top: 10px; font-family: var(--f-ui-sc); font-weight: 700; font-size: 13px; letter-spacing: .08em; color: var(--ink-3); }
.pc-build .num { font-family: inherit; color: var(--brass); }
.lede-sm { font-size: var(--t-body); line-height: 1.6; max-width: 62ch; color: var(--ink-2); margin-bottom: var(--s-4); }

.dossier-main > section, .dossier-main > details { margin-top: var(--s-7); }
.dossier-main > .spotlight:first-of-type { margin-top: var(--s-5); }

.spotlight-chart { position: relative; }
.spotlight-svg { display: block; width: 100%; height: auto; overflow: visible; }
.sp-axis { stroke: var(--line-2); stroke-width: 1; }
.sp-present { fill: var(--ink-4); }
.sp-moment { fill: var(--brass); stroke: var(--ground); stroke-width: 2; transition: r var(--dur-1); }
.sp-hitarea { fill: transparent; }
.sp-hit { cursor: pointer; outline: none; }
.sp-hit:hover .sp-moment, .sp-hit:focus-visible .sp-moment { r: 7.5; fill: var(--brass-hi); }
.sp-hit:focus-visible .sp-hitarea { stroke: var(--brass-glint); stroke-width: 2; }
.sp-lbl { fill: var(--ink-3); font-family: var(--f-ui-sc); font-weight: 700; font-size: 11px; letter-spacing: .06em; }
.sp-legend { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin-top: 8px; font-family: var(--f-ui); font-size: var(--t-xs); color: var(--ink-3); }
.sp-legend span { display: inline-block; }
.lg-moment { width: 11px; height: 11px; border-radius: 50%; background: var(--brass); }
.lg-present { width: 2px; height: 11px; border-radius: 1px; background: var(--ink-4); margin-left: 8px; }

.dossier-cols { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: var(--s-7); }
.dossier-cols > section { margin-top: var(--s-7); }
.pc-arc { list-style: none; padding: 0; margin: 0 0 var(--s-4); counter-reset: arc; display: grid; gap: 0; }
.pc-arc li {
  counter-increment: arc; position: relative; padding: 0 0 14px 34px; font-size: var(--t-md); line-height: 1.5; color: var(--ink-2);
}
.pc-arc li::before {
  content: ""; position: absolute; left: 7px; top: .45em; width: 9px; height: 9px; border-radius: 50%;
  border: 1.5px solid var(--brass); background: var(--ground);
}
.pc-arc li::after { content: ""; position: absolute; left: 11px; top: calc(.45em + 12px); bottom: 2px; width: 1px; background: var(--line-2); }
.pc-arc li:last-child::after { display: none; }
.pc-arc li:last-child::before { background: var(--brass); }

.tt-card {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: start; gap: 8px; padding: 18px 14px 14px;
  border-radius: var(--r-3); background: var(--ground-2); box-shadow: 0 0 0 1px var(--line);
}
.tt-side { margin: 0; display: grid; justify-items: center; gap: 10px; text-align: center; }
.tt-side .tag { line-height: 1.35; max-width: 16ch; }
.tt-rift { width: 26px; height: 64px; align-self: center; }
.tt-rift svg { width: 100%; height: 100%; fill: none; stroke: var(--future); stroke-width: 1.6; stroke-linejoin: bevel; filter: drop-shadow(0 0 4px color-mix(in srgb, var(--future) 55%, transparent)); }
.roundel { --size: 64px; position: relative; width: var(--size); height: var(--size); border-radius: 50%; overflow: hidden; display: block; background: var(--ground-3); box-shadow: 0 0 0 1.5px var(--brass), 0 2px 6px -2px rgba(0,0,0,.4); }
.roundel img { width: 100%; height: 100%; object-fit: cover; }
.roundel.paper { background: var(--paper); }

.roundel.unknown { display: grid; place-items: center; background: var(--ground-2); box-shadow: 0 0 0 1.5px var(--line-2); }
.roundel.unknown span { font-family: var(--f-display); font-size: 1.9rem; line-height: 1; color: var(--ink-3); }
.roundel.paper img { object-fit: contain; padding: 8px; mix-blend-mode: multiply; }
.tt-title { font-family: var(--f-display); font-size: 1.35rem; margin: 14px 0 4px; }
.tt-text { color: var(--ink-2); line-height: 1.5; }

.item-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.item-card {
  display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 14px; align-items: start; padding: 10px 16px 10px 10px; border-radius: var(--r-2);
  background: var(--paper); color: var(--paper-ink); text-decoration: none; box-shadow: 0 1px 0 rgba(255,255,255,.35) inset, var(--shadow-2);
  transition: transform var(--dur-2) var(--ease), box-shadow var(--dur-2);
}
.item-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-3); }
.item-card .item-art { display: block; aspect-ratio: 1; }
.item-card .item-art img { width: 100%; height: 100%; object-fit: contain; mix-blend-mode: multiply; }
.item-card .item-text { display: grid; gap: 2px; min-width: 0; }
.item-card .item-name { font-family: var(--f-display); font-size: 1.15rem; line-height: 1.2; color: inherit; text-decoration: none; }
.item-card a.item-name:hover { color: #7a4a0c; }
.item-card .item-meta { font-family: var(--f-ui-sc); font-weight: 700; font-size: 11px; letter-spacing: .08em; color: #6b5a40; }
.item-card .item-props { margin-top: 3px; font-size: var(--t-xs); line-height: 1.45; color: #4a3b27; display: grid; gap: 5px; }
.item-card .item-props p + p { margin-top: 0; }
.item-card .rules-table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.item-card .rules-table th { text-align: left; border-bottom: 1px solid rgba(90, 60, 20, .35); padding: 2px 6px 3px 0; }
.item-card .rules-table td { padding: 1px 6px 1px 0; border-bottom: 1px dotted rgba(90, 60, 20, .18); }

.item-more { margin-top: 4px; }
.item-more summary { cursor: pointer; list-style: none; display: inline-flex; align-items: center; gap: 6px; font-family: var(--f-ui-sc); font-weight: 700; font-size: 11px; letter-spacing: .08em; color: #7a4a0c; }
.item-more summary::-webkit-details-marker { display: none; }
.item-more summary::before { content: ""; width: 6px; height: 6px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(-45deg); transition: transform var(--dur-2) var(--ease); }
.item-more[open] summary::before { transform: rotate(45deg); }
.item-more[open] summary { margin-bottom: 4px; }

.pc-threads { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 2px 24px; }
.pc-threads .gunline { display: flex; align-items: center; gap: 12px; padding: 7px 8px; border-radius: var(--r-2); color: var(--ink); text-decoration: none; font-size: var(--t-md); }
.pc-threads .gunline:hover { background: var(--ground-2); color: var(--brass-hi); }
.pc-threads .gunline-title { flex: 1; min-width: 0; }

details.background { border-top: 1px solid var(--line); padding-top: var(--s-4); }
details.background summary { cursor: pointer; list-style: none; display: flex; align-items: center; gap: 10px; font-family: var(--f-display); font-size: 1.35rem; }
details.background summary::-webkit-details-marker { display: none; }
details.background summary::before { content: ""; width: 8px; height: 8px; border-right: 1.5px solid var(--brass); border-bottom: 1.5px solid var(--brass); transform: rotate(-45deg); transition: transform var(--dur-2) var(--ease); }
details.background[open] summary::before { transform: rotate(45deg); }
details.background p { margin-top: 12px; max-width: 68ch; line-height: 1.65; color: var(--ink-2); }

@media (max-width: 1280px) {
  .dossier-cols { grid-template-columns: minmax(0, 1fr); gap: 0; }
}
@media (max-width: 900px) {
  .dossier { grid-template-columns: minmax(0, 1fr); }
  .dossier-art { position: static; grid-template-columns: minmax(0, 200px) minmax(0, 1fr); align-items: start; }
}
@media (max-width: 560px) {
  .dossier-art { grid-template-columns: minmax(0, 1fr); }
  .art-frame { max-width: 280px; }
  .pc-tab { min-width: 54px; padding: 8px 2px 10px; gap: 6px; }
  .pc-tab .portrait { --size: 40px !important; }
  .pc-tab.former .portrait { --size: 32px !important; margin: 4px 0; }
  .pc-tab .t-name { font-size: 1rem; }
  .pc-tab .t-cls { display: none; }
  .pc-tabs-sep { flex-basis: 100%; height: 0; margin: 0; } 
}
