:root {
  color-scheme: light;
  --ink: #15243a;
  --sub: #46576b;
  --quiet: #586a7e;
  --line: #d6e0eb;
  --soft: #edf2f8;
  --page: #f4f7fb;
  --paper: #fff;
  --blue: #1455bf;
  --blue-deep: #123e86;
  --blue-pale: #e9f2ff;
  --navy: #132541;
  --measure: 77rem;
  --gutter: clamp(1.5rem, 5vw, 5rem);
  font-family: "Pretendard", "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", "DM Sans", sans-serif;
  color: var(--ink);
  background: var(--page);
  font-variant-numeric: tabular-nums;
  -webkit-text-size-adjust: 100%;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-width: 280px; font-size: 1rem; line-height: 1.5; }
input, select, button { font: inherit; color: inherit; }
button, select { cursor: pointer; }
button, a, select { -webkit-tap-highlight-color: transparent; }
a { text-decoration: none; color: inherit; }
h1, h2, h3, p, ol, ul, dl, dd { margin: 0; }
ol, ul { padding: 0; }
h1, h2, h3 { line-height: 1.25; letter-spacing: -.045em; }
h2 { font-size: 1.22rem; }
h3 { font-size: 1rem; }
main { display: block; }
:focus-visible { outline: 3px solid #3479d9; outline-offset: 3px; }
.wrap { width: min(calc(100% - var(--gutter)),var(--measure)); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip-link { position: fixed; left: .6rem; top: .4rem; z-index: 20; padding: .55rem 1rem; background: white; color: var(--blue); transform: translateY(-200%); }
.skip-link:focus { transform: none; }

/* 브랜드와 네 메뉴가 한 줄에 놓이는 상단 탐색 */
.masthead { background: var(--paper); border-top: 3px solid var(--blue); border-bottom: 1px solid #ced8e6; }
.masthead-inner { display: flex; align-items: stretch; gap: clamp(1rem,4vw,3.35rem); min-height: 3.7rem; }
.brand { display: inline-flex; align-items: center; gap: .65rem; white-space: nowrap; color: var(--navy); }
.wordmark { font-size: 1.38rem; font-weight: 800; letter-spacing: -.075em; }
.wordmark b { color: var(--blue); font-weight: 800; }
.brand-mark { width: 2.25rem; height: 2.25rem; object-fit: contain; flex: none; }
.main-nav { display: flex; align-items: stretch; gap: .45rem; }
.main-nav a { display: inline-flex; align-items: center; justify-content: center; gap: .44rem; padding: 0 .82rem; color: var(--sub); font-size: .92rem; font-weight: 700; border-bottom: 3px solid transparent; padding-top: 3px; }
.main-nav a[aria-current] { color: var(--blue); border-color: var(--blue); }
.main-nav a:hover { color: var(--blue); background: var(--blue-pale); }
.menu-count { color: var(--quiet); font-size: .7rem; font-weight: 600; }
.main-nav a[aria-current] .menu-count { color: var(--blue); }
.edition-line { margin-left: auto; display: flex; gap: .45rem; align-items: center; font-size: .78rem; color: var(--quiet); white-space: nowrap; }
.edition-line strong { padding: .18rem .48rem; border: 1px solid #bcd0eb; border-radius: .25rem; color: var(--blue-deep); background: #f4f8ff; }
.ico { display: inline-block; position: relative; width: .96rem; height: .96rem; flex: none; color: currentColor; }
.ico-characters::before { content: ""; position: absolute; top: .08rem; left: .08rem; width: .33rem; height: .33rem; background: currentColor; box-shadow: .46rem 0, 0 .46rem, .46rem .46rem; }
.ico-parties::before { content: ""; position: absolute; top: .08rem; left: .23rem; width: .33rem; height: .33rem; background: currentColor; border-radius: 50%; box-shadow: .37rem .13rem; }
.ico-parties::after { content: ""; position: absolute; bottom: .09rem; left: .06rem; width: .62rem; height: .35rem; border-radius: .35rem .35rem .05rem .05rem; background: currentColor; box-shadow: .28rem .06rem; }
.ico-slots::before { content: ""; position: absolute; inset: .16rem; border: 2px solid currentColor; transform: rotate(45deg); }
.ico-search { width: .89rem; height: .89rem; border: 1.7px solid currentColor; border-radius: 50%; }
.ico-search::after { content: ""; position: absolute; right: -.28rem; bottom: -.13rem; width: .39rem; height: 1.8px; transform: rotate(45deg); background: currentColor; }

/* 대균열의 수정과 다리를 화면 오른쪽에 두어 작은 화면에서도 제목이 읽히게 한다. */
.hero { position: relative; isolation: isolate; overflow: hidden; color: white; background: #152342; }
.hero::before { content: ""; position: absolute; z-index: -1; inset: 0; background: linear-gradient(90deg,#12233e 3%,#15294aee 23%,#152849aa 49%,#15284924 76%), url("./assets/대균열_풍경.webp") 68% 49% / cover no-repeat; }
.hero-inner { display: flex; align-items: center; min-height: 10.5rem; gap: 1.4rem; }
.hero-copy { max-width: min(44rem,82%); padding-block: 1.35rem 1.45rem; }
.hero-meta, .detail-tags { display: flex; flex-wrap: wrap; align-items: center; gap: .55rem; }
.hero-meta { margin-bottom: .45rem; font-size: .76rem; font-weight: 650; }
.hero-patch { padding: .11rem .4rem; border: 1px solid #a1caf386; border-radius: .2rem; color: #d7eeff; background: #123866ad; }
.hero-inventory { color: #dce6f3; }
.hero h1 { font-size: clamp(2rem,3.5vw,3rem); line-height: 1.12; font-weight: 800; letter-spacing: -.072em; overflow-wrap: anywhere; word-break: keep-all; }
.hero h1:focus { outline: none; }
.hero p { margin-top: .48rem; color: #e4ecf5; font-size: .95rem; word-break: keep-all; }
.content { padding-block: 1.15rem 4rem; }
.controls, .entry-filter { display: flex; flex-wrap: wrap; align-items: center; gap: .52rem; }
.controls { padding: .6rem .73rem; margin-bottom: .9rem; background: white; border: 1px solid var(--line); border-radius: .4rem; }
.role-filters { display: flex; flex-wrap: wrap; align-items: center; gap: .2rem; border-right: 1px solid var(--line); padding-right: .72rem; margin-right: .15rem; }
.role-choice { background: transparent; border: 1px solid transparent; border-radius: .25rem; padding: .4rem .72rem; min-height: 2.25rem; font-size: .9rem; font-weight: 700; color: var(--sub); }
.role-choice:hover { background: var(--soft); }
.role-choice[aria-current] { background: var(--blue); border-color: var(--blue); color: white; }
.role-choice[data-role]:not([data-role=""])::before { content: ""; display: inline-block; width: .84rem; height: .84rem; margin-right: .28rem; background: currentColor; vertical-align: -.07rem; }
.role-choice[data-role="딜러"]::before { clip-path: polygon(0 80%,16% 64%,8% 56%,16% 48%,28% 59%,74% 11%,100% 0,90% 27%,42% 73%,54% 85%,46% 93%,36% 83%,18% 100%); }
.role-choice[data-role="보조"]::before { clip-path: polygon(35% 0,65% 0,65% 35%,100% 35%,100% 65%,65% 65%,65% 100%,35% 100%,35% 65%,0 65%,0 35%,35% 35%); }
.search-box, .select-box { display: flex; align-items: center; min-height: 2.35rem; border: 1px solid #c9d4e1; border-radius: .27rem; background: var(--paper); color: var(--sub); }
.search-box { flex: 1 1 12rem; gap: .7rem; padding: 0 .78rem; }
.search-box input, .select-box select { min-width: 0; width: 100%; border: 0; height: 2.35rem; background: transparent; font-size: .88rem; color: var(--ink); }
.search-box input::placeholder { color: var(--quiet); }
.select-box { position: relative; max-width: 42%; }
.select-box select { appearance: none; padding: 0 2.15rem 0 .72rem; text-overflow: ellipsis; }
.select-box::after { content: ""; position: absolute; right: .75rem; top: 38%; width: .42rem; height: .42rem; border-right: 1.5px solid; border-bottom: 1.5px solid; transform: rotate(45deg); pointer-events: none; }
.search-box:focus-within, .select-box:focus-within { outline: 2px solid #3f7bd2; outline-offset: 1px; }
.search-box input:focus, .select-box select:focus { outline: 0; }

/* 도감 목록과 캐릭터 초상 */
.results, .entry-section, .comparison-scroll { min-width: 0; background: var(--paper); border: 1px solid var(--line); border-radius: .4rem; }
.results-head { display: flex; align-items: center; min-height: 3.4rem; padding: .8rem 1rem; }
.avatar { --avatar-base: #dce8f6; --avatar-ink: #38577b; display: inline-grid; position: relative; place-items: center; flex: none; overflow: hidden; width: 3.1rem; height: 3.1rem; background: var(--avatar-base); color: var(--avatar-ink); border-radius: .25rem; }
.avatar[data-shade="1"] { --avatar-base: #d4e9e1; --avatar-ink: #426854; }
.avatar[data-shade="2"] { --avatar-base: #eeded3; --avatar-ink: #775641; }
.avatar[data-shade="3"] { --avatar-base: #e8e2f5; --avatar-ink: #5e5372; }
.avatar[data-shade="4"] { --avatar-base: #ede7ce; --avatar-ink: #695d3d; }
.avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.monogram { font-size: 1.05rem; font-weight: 750; }
.small.avatar { width: 2rem; height: 2rem; }
.results-head { justify-content: space-between; gap: .6rem; }
.results-title { display: flex; align-items: center; gap: .45rem; }
.result-count { padding: .09rem .38rem; border-radius: .2rem; font-size: .73rem; font-weight: 700; white-space: nowrap; color: var(--blue-deep); background: var(--blue-pale); }
.scope-note { padding: 0 1rem .76rem; margin-top: -.25rem; color: var(--quiet); font-size: .8rem; }
.clear-link, .back-link { font-weight: 700; font-size: .83rem; text-underline-offset: .2rem; }
.clear-link { color: var(--blue); }
.clear-link:hover, .back-link:hover { text-decoration: underline; }
.rank-S { --rank-paper: #ffe4ec; --rank-ink: #a4234e; }
.rank-A { --rank-paper: #fff0d6; --rank-ink: #85500c; }
.rank-B { --rank-paper: #ddf4ec; --rank-ink: #12624a; }
.rank-C { --rank-paper: #e4edff; --rank-ink: #27599a; }
.rank-D, .rank-other { --rank-paper: #e9edf2; --rank-ink: #4d5e71; }
.comparison { width: 100%; border-collapse: collapse; }
.party-columns { color: var(--sub); font-size: .76rem; font-weight: 650; background: var(--soft); }
.tier-chip { display: inline-block; padding: .16rem .45rem; min-width: 2.2rem; max-width: 100%; border-radius: .24rem; background: var(--rank-paper); color: var(--rank-ink); font: 800 .93rem/1.3 "Barlow", "Malgun Gothic", sans-serif; text-align: center; }
.character-link { display: flex; align-items: center; gap: .55rem; width: fit-content; max-width: 100%; color: var(--ink); font-size: .94rem; }
.character-link:hover, .person[href]:hover { color: var(--blue); text-decoration: underline; text-underline-offset: .16em; }
.character-link .avatar { border: 1px solid #c8d4e2; }
.patch { display: inline-block; width: fit-content; max-width: 100%; padding: .09rem .35rem; background: var(--blue-pale); color: var(--blue-deep); border-radius: .2rem; font-size: .74rem; line-height: 1.45; font-weight: 700; overflow-wrap: anywhere; }

/* 조합 원문 순위와 단수별 성적 */
.party-layout { display: grid; grid-template-columns: 8.2rem minmax(0,1fr); border-top: 1px solid var(--line); }
.board-index { align-self: start; position: sticky; top: .5rem; padding: .8rem .55rem; }
.index-title { margin: 0 .3rem .48rem; font-size: .83rem; color: var(--quiet); }
.index-items { display: grid; gap: .18rem; }
.index-jump { min-height: 2rem; padding: .28rem .48rem; border: 0; border-radius: .2rem; background: transparent; text-align: left; font-weight: 650; font-size: .82rem; }
.index-jump:hover { background: var(--blue-pale); color: var(--blue); }
.party-board { min-width: 0; border-top: 1px solid var(--line); }
.party-layout .party-board { border-top: 0; border-left: 1px solid var(--line); }
.party-columns, .party-card { display: grid; grid-template-columns: 4.5rem minmax(10rem,1fr) minmax(14rem,36%) 5.4rem; align-items: center; }
.party-columns { padding-block: .54rem; text-align: center; }
.party-columns > span:nth-child(2) { text-align: left; }
.party-card { position: relative; border-top: 1px solid #e3e9f1; }
.party-card:hover { background: #f6f9ff; }
.party-open { grid-column: 1 / 4; display: grid; grid-template-columns: subgrid; align-items: center; min-width: 0; padding-block: .67rem; scroll-margin-top: 1rem; }
.source-rank { display: block; color: var(--blue); text-align: center; font-size: 1.02rem; font-weight: 800; }
.party-identity { min-width: 0; padding-right: .6rem; }
.party-name { font-size: .92rem; line-height: 1.3; overflow-wrap: anywhere; }
.party-badges { display: inline-flex; align-items: center; gap: .3rem; }
.party-badges { margin-top: .23rem; }
.release-title { margin: 0; padding: .7rem 1rem .45rem; color: var(--navy); }
.fixed-band { border-top: 1px solid var(--line); }
.fixed-heading { display: flex; align-items: center; gap: .55rem; padding: .6rem 1rem; background: var(--soft); }
.fixed-heading h4 { margin: 0; font-size: .86rem; color: var(--sub); }
.fixed-band > .scope-note { margin: 0; padding-block: .48rem; }
.fixed-card { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: .65rem; padding: .7rem .9rem; border-top: 1px solid var(--line); }
.fixed-card:hover { background: var(--blue-pale); }
.fixed-open { min-width: 0; display: grid; grid-template-columns: minmax(11rem,1fr) minmax(0,1.5fr); align-items: center; gap: .8rem; }
.fixed-identity { min-width: 0; }
.fixed-identity > .patch { margin-left: .4rem; }
.fixed-metrics { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,7rem),1fr)); gap: .5rem; }
.fixed-metric dt { color: var(--quiet); font-size: .77rem; }
.fixed-metric dd { font-size: .9rem; font-weight: 700; overflow-wrap: anywhere; font-variant-numeric: tabular-nums; }
.fixed-summary { font-size: .88rem; color: var(--sub); }
.party-method { display: grid; grid-template-columns: max-content minmax(0,1fr); gap: .35rem .85rem; margin: 0 1rem .5rem; font-size: .84rem; }
.party-method dt { font-weight: 700; color: var(--navy); }
.party-method dd { margin: 0; color: var(--sub); }
.all-parties-link { display: inline-block; margin: 0 1rem .8rem; color: var(--blue-deep); font-weight: 700; text-decoration: underline; text-underline-offset: .2em; font-size: .88rem; }
.previous-parties > summary { cursor: pointer; }
.unique-switcher { display: flex; align-items: center; gap: .6rem; margin: .35rem 0 .8rem; font-size: .88rem; color: var(--sub); }
.unique-switcher select { color: var(--ink); background: var(--paper); border: 1px solid var(--line); border-radius: .25rem; padding: .35rem .55rem; }
.members { display: flex; flex-wrap: wrap; align-items: center; list-style: none; gap: .32rem .5rem; }
.members.compact { margin-top: .3rem; }
.person { display: inline-flex; gap: .35rem; align-items: center; color: var(--sub); font-size: .84rem; }
.members.compact .person .avatar { width: 1.65rem; height: 1.65rem; border-radius: .2rem; }
.members.compact .person > span:last-child { position: absolute; width: 1px; height: 1px; clip-path: inset(50%); overflow: hidden; }
.stage-labels, .metric-preview { display: grid; grid-auto-columns: minmax(0,1fr); grid-auto-flow: column; align-items: center; text-align: center; }
.preview-cell { padding: .1rem .18rem; }
.preview-cell dt { position: absolute; width: 1px; height: 1px; clip-path: inset(50%); overflow: hidden; }
.preview-cell dd { color: var(--ink); font-weight: 700; font-size: .78rem; overflow-wrap: anywhere; }
.compare-toggle, .entry-reset { border: 1px solid #c3d2e2; border-radius: .25rem; background: white; color: var(--blue-deep); font-size: .76rem; font-weight: 700; }
.compare-toggle { justify-self: center; padding: .32rem .43rem; }
.compare-toggle[aria-pressed="true"] { color: white; background: var(--blue); border-color: var(--blue); }
.compare-toggle:disabled { opacity: .47; cursor: default; }
.tray-host { position: sticky; bottom: 0; z-index: 3; }
.compare-tray { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .75rem max(1rem,calc((100% - var(--measure)) / 2)); background: var(--navy); color: white; box-shadow: 0 -.15rem .55rem #14243c29; }
.tray-copy { display: grid; min-width: 0; font-size: .86rem; }
.tray-copy span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #d1ddf0; }
.tray-hint { font-size: .82rem; color: #e1e9f8; }
.primary-button { flex: none; display: inline-flex; align-items: center; padding: .45rem .8rem; background: white; color: var(--blue-deep); border-radius: .3rem; font-size: .85rem; font-weight: 700; }

/* 부위별 장비와 옵션 */
.catalog { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: .75rem; padding: .9rem 1rem 1rem; border-top: 1px solid var(--line); }
.catalog-card { display: grid; grid-template-columns: minmax(0,1fr) auto; align-content: start; align-items: center; gap: .6rem; padding: 1rem; border: 1px solid #cdd9e6; border-radius: .35rem; background: #fafcfe; }
.catalog-card:hover { border-color: #77a2d9; background: #f1f7ff; }
.catalog-title { display: flex; align-items: center; gap: .58rem; }
.catalog-title h3 { font-size: 1.1rem; }
.catalog-title .ico { width: 2.35rem; height: 2.35rem; border: 1px solid #d2e0f2; border-radius: .42rem; background: #e9f2ff; color: #345a9b; }
.catalog-title .ico::before { inset: 18%; background: currentColor; border: 0; transform: none; }
.catalog-card[data-record-id="weapon"] .ico::before { clip-path: polygon(8% 89%,25% 70%,16% 60%,23% 53%,35% 64%,72% 14%,97% 3%,88% 28%,44% 74%,55% 85%,48% 92%,36% 81%,18% 100%); }
.catalog-card[data-record-id="helmet"] .ico::before { clip-path: polygon(4% 61%,8% 32%,26% 12%,50% 5%,74% 12%,92% 32%,96% 61%,89% 86%,73% 96%,65% 65%,34% 65%,27% 96%,11% 86%); }
.catalog-card[data-record-id="armor"] .ico::before { clip-path: polygon(26% 4%,39% 6%,45% 21%,56% 21%,62% 6%,76% 4%,98% 23%,86% 45%,77% 39%,74% 95%,26% 95%,23% 39%,14% 45%,2% 23%); }
.catalog-card[data-record-id="gloves"] .ico::before { clip-path: polygon(18% 86%,18% 52%,6% 36%,15% 32%,28% 43%,24% 13%,34% 10%,40% 39%,39% 7%,50% 6%,54% 37%,56% 8%,67% 10%,68% 40%,74% 16%,84% 20%,79% 56%,72% 73%,69% 93%,21% 93%); }
.catalog-card[data-record-id="boots"] .ico::before { clip-path: polygon(40% 7%,86% 7%,80% 39%,84% 73%,92% 79%,92% 92%,7% 92%,8% 77%,28% 69%,43% 54%); }
.catalog-card[data-record-id="accessory"] .ico::before { clip-path: polygon(13% 9%,25% 6%,50% 36%,75% 6%,87% 9%,60% 46%,76% 64%,50% 97%,24% 64%,40% 46%); }
.catalog-preview, .catalog-count { grid-column: 1 / -1; }
.catalog-preview { font-size: .84rem; color: var(--sub); overflow-wrap: anywhere; }
.catalog-count { font-size: .78rem; font-weight: 700; color: var(--blue); }
.empty-state { display: grid; justify-items: center; gap: .3rem; padding: 2rem 1rem; text-align: center; }
.empty-state p, .missing-entry { color: var(--quiet); font-size: .9rem; }

/* 상세 탭과 두 조합 비교표 */
.hero-detail .hero-inner { justify-content: flex-start; }
.hero-detail .hero-copy { max-width: min(58rem,100%); }
.hero-detail .hero-inner > .avatar { width: 5rem; height: 5rem; border: 2px solid #dbe9f9; }
.back-link { display: inline-block; margin-bottom: .35rem; color: #d3e4fb; }
.back-link::before { content: "‹"; margin-right: .32rem; }
.detail-tags { margin-top: .55rem; font-size: .87rem; color: #e3edfb; }
.detail-summary { max-width: 84ch; margin-bottom: 1rem; color: var(--sub); line-height: 1.6; }
.member-links { margin-bottom: .85rem; }
.member-links .person { padding: .23rem .48rem .23rem .25rem; border: 1px solid var(--line); border-radius: .28rem; background: white; }
.detail-tabs { display: flex; align-items: stretch; max-width: 100%; overflow-x: auto; gap: .18rem; border: 1px solid var(--line); border-bottom: 2px solid #b9cbe1; border-radius: .35rem .35rem 0 0; background: white; }
.detail-tab { flex: 0 0 auto; padding: .72rem 1.12rem .6rem; border-bottom: 3px solid transparent; color: var(--sub); font-size: .92rem; font-weight: 700; }
.detail-tab[aria-selected="true"] { background: #f4f8ff; color: var(--blue); border-color: var(--blue); }
.detail-tab:focus-visible { outline-offset: -4px; }
.detail-panel { display: grid; gap: .75rem; margin-top: .75rem; }
.entry-section { padding: .95rem 1.05rem .25rem; }
.entry-section > h2 { margin-bottom: .8rem; font-size: 1.12rem; }
.entry-list { list-style: none; }
.entry-filter { margin-bottom: .75rem; }
.entry-filter .search-box { flex: 1 1 10rem; }
.entry-count { font-size: .8rem; color: var(--quiet); }
.entry-reset { padding: .38rem .54rem; }
.entry-row { display: grid; grid-template-columns: minmax(8.5rem,23%) minmax(0,1fr); gap: .8rem; padding: .8rem 0; border-top: 1px solid var(--line); }
.entry-label { color: var(--blue-deep); font-size: .91rem; overflow-wrap: anywhere; }
.entry-body { min-width: 0; overflow-wrap: anywhere; }
.entry-value { font-size: .95rem; white-space: pre-line; }
.entry-note, .summary-text { margin-top: .3rem; color: var(--sub); font-size: .9rem; line-height: 1.55; white-space: pre-line; }
.entry-evidence { display: flex; flex-wrap: wrap; align-items: baseline; gap: .28rem .48rem; margin: .42rem 0; font-size: .76rem; color: var(--quiet); }
.extra-fields { display: grid; grid-template-columns: fit-content(33%) minmax(0,1fr); gap: .24rem .7rem; margin: .52rem 0; font-size: .84rem; }
.extra-fields dt { color: var(--quiet); }
.extra-fields dd { white-space: pre-line; overflow-wrap: anywhere; }
.ordered .entry-label { border-left: 3px solid #8cb1e2; padding-left: .55rem; }
.missing-entry { padding: .3rem 0 .85rem; }
.comparison-scroll { overflow-x: auto; }
.comparison { table-layout: fixed; }
.comparison th, .comparison td { vertical-align: top; text-align: left; padding: .75rem .88rem; overflow-wrap: anywhere; }
.comparison tr > * + * { border-left: 1px solid var(--line); }
.comparison tbody tr { border-top: 1px solid var(--line); }
.comparison th:first-child { width: 19%; }
.comparison thead { background: var(--navy); color: white; }
.comparison thead a { text-decoration: underline; text-underline-offset: .18em; }
.comparison tbody th { background: #f4f7fb; color: var(--sub); font-size: .85rem; }
.comparison tbody .compare-group { color: var(--blue-deep); background: #e8f1ff; }
.comparison .member-links { margin: 0; }

@media (max-width: 1000px) {
  .party-layout { grid-template-columns: 7rem minmax(0,1fr); }
  .party-columns, .party-card { grid-template-columns: 3.5rem minmax(9rem,1fr) minmax(12rem,36%) 4.7rem; }
  .hero-inner { min-height: 9rem; }
}
@media (max-width: 900px) {
  .party-layout { display: flex; flex-direction: column; gap: .55rem; }
  .party-layout > * { width: 100%; }
  .board-index { position: static; padding: .44rem .65rem; }
  .index-title { display: inline; }
  .index-items { display: inline-flex; flex-wrap: wrap; }
  .index-jump { padding: .1rem .4rem; font-size: .77rem; }
  .party-layout .party-board { border-left: 0; border-top: 1px solid var(--line); }
}
@media (max-width: 720px) {
  .fixed-open { grid-template-columns: 1fr; gap: .55rem; }
  .fixed-card { align-items: start; }
  :root { --gutter: 1.4rem; }
  .masthead-inner { gap: .58rem; }
  .main-nav { gap: 0; }
  .main-nav a { padding-inline: .58rem; }
  .menu-count { display: none; }
  .hero-inner { min-height: 8.25rem; }
  .hero-copy { max-width: 92%; }
  .hero::before { background-position: center,69% 48%; }
  .catalog { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .role-filters { width: 100%; border-right: 0; border-bottom: 1px solid var(--line); padding: 0 0 .42rem; margin: 0; }
  .role-choice { flex: 1; }
}
@media (max-width: 580px) {
  .masthead-inner { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 0; }
  .brand { min-height: 2.95rem; }
  .wordmark { font-size: 1.26rem; }
  .brand-mark { width: 1.95rem; height: 1.95rem; }
  .edition-line { grid-column: 2; grid-row: 1; }
  .main-nav { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); }
  .main-nav a { min-height: 2.55rem; font-size: .89rem; }
  .hero-inner { min-height: 7.9rem; }
  .hero-copy { padding-block: 1.05rem; }
  .hero h1 { font-size: 1.85rem; }
  .hero p { font-size: .82rem; }
  .content { padding-block: .7rem 2.8rem; }
  .controls { padding: .46rem; gap: .37rem; margin-bottom: .55rem; }
  .controls .search-box { flex-basis: 55%; }
  .select-box { flex: 1 1 6rem; max-width: 100%; }
  .results-head { min-height: 2.8rem; padding: .62rem .68rem; }
  .scope-note { padding-inline: .68rem; }
  .tier-chip { min-width: 1.85rem; font-size: .8rem; }
  .character-link { gap: .35rem; font-size: .83rem; }
  .character-link .avatar { width: 1.75rem; height: 1.75rem; }
  .party-columns { display: none; }
  .party-card { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: .35rem; align-items: start; padding: .65rem; }
  .party-open { grid-column: auto; grid-template-columns: 2.4rem minmax(0,1fr); gap: .35rem; padding: 0; }
  .source-rank { align-self: start; text-align: left; font-size: .9rem; }
  .metric-preview { grid-column: 2; display: flex; flex-wrap: wrap; gap: .22rem .65rem; text-align: left; }
  .preview-cell { padding: 0; }
  .preview-cell dt { position: static; width: auto; height: auto; clip-path: none; font-size: .65rem; color: var(--quiet); }
  .preview-cell dd { font-size: .72rem; }
  .party-name { font-size: .85rem; }
  .compare-toggle { font-size: .69rem; }
  .catalog { gap: .44rem; padding: .55rem; }
  .catalog-card { padding: .6rem; gap: .4rem; }
  .catalog-title { gap: .34rem; }
  .catalog-title h3 { font-size: .95rem; }
  .catalog-title .ico { width: 1.65rem; height: 1.65rem; }
  .catalog-preview { font-size: .78rem; }
  .hero-detail .hero-inner { gap: .62rem; }
  .hero-detail .hero-inner > .avatar { width: 3.4rem; height: 3.4rem; }
  .detail-tab { padding: .62rem .7rem .48rem; font-size: .85rem; }
  .entry-section { padding: .75rem .7rem .15rem; }
  .entry-row { grid-template-columns: 1fr; gap: .3rem; padding: .67rem 0; }
  .entry-filter .search-box { flex-basis: 100%; }
  .comparison th, .comparison td { padding: .45rem .36rem; font-size: .82rem; }
  .comparison .entry-value, .comparison .entry-note { font-size: .82rem; }
  .compare-tray { padding: .55rem .75rem; }
  .tray-hint { max-width: 7.2rem; }
}
@media (max-width: 385px) {
  .catalog { grid-template-columns: 1fr; }
  .hero-detail .hero-inner > .avatar { width: 2.85rem; height: 2.85rem; }
}
@supports not (grid-template-columns: subgrid) {
  @media (min-width: 581px) {
    .party-open { display: contents; }
    .party-card { min-height: 4.1rem; }
    .party-identity { padding-block: .45rem; }
  }
}
/* 상성도와 보스별 특성 */
.ico-matchups::before { content: ""; position: absolute; inset: .1rem; background: currentColor; clip-path: polygon(50% 0,62% 37%,100% 50%,62% 63%,50% 100%,37% 63%,0 50%,37% 37%); }
.matchup-content { display: grid; gap: 1rem; }
.matchup-lead { display: grid; grid-template-columns: minmax(0,1fr) minmax(14rem,33%); align-items: center; gap: clamp(.8rem,3vw,3rem); overflow: hidden; border: 1px solid #d8cbb4; border-radius: .5rem; background: #fcf7ed; }
.matchup-copy { padding: clamp(1.3rem,3.5vw,3.6rem); }
.matchup-copy .patch { color: #655039; background: #efe5d4; }
.matchup-copy h1 { margin: .48rem 0; font-size: clamp(1.9rem,3.8vw,3.3rem); color: #262e38; line-height: 1.12; }
.matchup-copy p { max-width: 32em; font-size: .96rem; color: #514b43; word-break: keep-all; }
.damage-modifiers { display: flex; flex-wrap: wrap; gap: .6rem 1.5rem; margin-top: clamp(.9rem,2vw,1.5rem); }
.modifier dt { font-size: .77rem; color: #544b40; }
.modifier dd { font-size: clamp(1.03rem,2.1vw,1.65rem); font-weight: 800; font-variant-numeric: tabular-nums; line-height: 1.15; }
.modifier.weak dd { color: #165948; }
.modifier.strong dd { color: #8d3548; }
.matchup-figure { margin: 0; overflow: hidden; }
.matchup-figure figcaption { padding: .4rem .65rem; font-size: .82rem; color: var(--sub); text-align: center; word-break: keep-all; }
.diagram-open { display: grid; place-items: center; position: relative; }
.diagram-open:focus-visible { outline-offset: -4px; }
.diagram-open img { display: block; width: 100%; height: auto; aspect-ratio: 1; object-fit: contain; }
.diagram-zoom { position: absolute; bottom: .6rem; right: .6rem; padding: .28rem .6rem; background: #102239e8; color: white; border: 1px solid #a4b9d4; border-radius: .25rem; font-size: .75rem; font-weight: 650; }
.matchup-panel .results-head { flex-wrap: wrap; }
.trait-legend, .boss-traits { display: flex; flex-wrap: wrap; gap: .3rem; }
.trait-chip { display: inline-flex; align-items: center; gap: .32em; padding: .17rem .45rem; color: #294660; background: #eff3f8; border-radius: .25rem; font-size: .87rem; font-weight: 650; white-space: nowrap; }
.trait-chip[data-trait="원소"] { background: #fff0e0; color: #8e481e; }
.trait-chip[data-trait="이능"] { background: #f0eaff; color: #62448e; }
.trait-chip[data-trait="투쟁"] { background: #fbeae6; color: #863e32; }
.trait-chip[data-trait="자연"] { background: #e3f2e9; color: #27604a; }
.trait-chip[data-trait="신성"] { background: #f7efd5; color: #775b18; }
.trait-legend .trait-chip { background: transparent; font-size: .77rem; padding: .1rem .25rem; }
.trait-symbol { display: inline-grid; place-items: center; min-width: 1em; }
.matchup-table, .performance-table { width: 100%; border-collapse: collapse; }
.matchup-table { table-layout: fixed; }
.matchup-table :is(th,td), .performance-table :is(th,td) { padding: .7rem 1rem; text-align: left; border-top: 1px solid var(--line); }
.matchup-table thead th, .performance-table thead th { background: var(--soft); color: var(--sub); font-size: .79rem; }
.matchup-table th:first-child { width: 44%; }
.matchup-table tbody th { font-size: .94rem; font-weight: 650; overflow-wrap: anywhere; }
.matchup-table tr:nth-child(even), .performance-table tbody tr:nth-child(even) { background: #f9fbfd; }

/* 역할 내 순위와 측정값 */
.role-choice { text-align: center; }
.ranked-select > span { padding-left: .7rem; color: var(--quiet); font-size: .78rem; white-space: nowrap; }
.ranking-notes { display: grid; gap: .16rem; padding: 0 1rem .8rem; color: var(--sub); font-size: .82rem; }
.ranking-notes:empty { display: none; }
.measurement-conditions summary, .matchup-sources summary { width: fit-content; cursor: pointer; color: var(--blue-deep); font-weight: 650; }
.measurement-conditions p, .matchup-sources p { margin-block: .4rem; }
.matchup-sources { border-top: 1px solid var(--line); padding: .8rem 1rem; color: var(--sub); font-size: .8rem; }
.ranking-mode { font-size: .8rem; color: var(--blue-deep); font-weight: 700; }
.performance-table td { vertical-align: middle; font-size: .87rem; }
.performance-table tbody tr:hover { background: #f0f5fd; }
.performance-table .character-link { gap: .46rem; word-break: keep-all; }
.performance-table .standing { color: var(--blue-deep); font-weight: 750; white-space: nowrap; }
.performance-stat { display: grid; align-content: start; }
.stat-number, .standing { font-variant-numeric: tabular-nums; }
.stat-number { line-height: 1.5; }
.stat-basis { color: var(--quiet); font-size: .73rem; line-height: 1.4; overflow-wrap: anywhere; }
.no-reading .stat-number { color: var(--sub); }
.stat-label { display: none; }
.equipment-summary { max-width: 13rem; word-break: keep-all; overflow-wrap: anywhere; }
.loadout-guide { display: grid; gap: .8rem; }
.guide-options { display: grid; gap: .42rem; min-width: 0; padding: 0 0 .8rem; margin: 0; border: 0; list-style: none; }
.guide-option { display: flex; align-items: baseline; gap: .7rem; padding: .65rem .8rem; border: 1px solid var(--line); border-radius: .3rem; background: #f9fbfd; }
label.guide-option { cursor: pointer; }
label.guide-option:has(:checked) { border-color: var(--blue); background: var(--blue-pale); }
.guide-option input { accent-color: var(--blue); }
.guide-copy { display: flex; align-items: baseline; flex-wrap: wrap; column-gap: .4rem; min-width: 0; }
.guide-copy p { width: 100%; margin-top: .16rem; color: var(--sub); font-size: .87rem; }
.guide-slot { color: var(--blue-deep); font-size: .74rem; font-weight: 700; }
.skill-options .guide-slot { flex: none; }

/* 속성 중립 실측의 조합 비교와 본인 피해 지분 */
.combo-panel { padding-bottom: .9rem; }
.combo-meta, .combo-facts, .combo-facts > div { display: flex; flex-wrap: wrap; align-items: baseline; gap: .3rem .55rem; }
.combo-status { color: var(--blue-deep); font-size: .86rem; }
.combo-facts { margin: .55rem 0; gap: .3rem 1rem; font-size: .82rem; }
.combo-facts dt, .combo-note, .combo-notice, .share-damage { color: var(--sub); }
.combo-facts dd, .combo-table, .omitted-gap { font-variant-numeric: tabular-nums; }
.combo-note, .combo-notice { margin-block: .45rem; font-size: .84rem; line-height: 1.55; }
.combo-table { border-collapse: collapse; width: 100%; font-size: .86rem; }
.combo-table thead { color: var(--sub); background: var(--soft); }
.combo-table th, .combo-table td { padding: .52rem .6rem; text-align: left; }
.combo-table thead th { font-size: .76rem; }
.combo-table tbody { border-top: 1px solid var(--line); }
.combo-table tbody tr + tr td { padding-top: 0; }
.combo-table .combo-rank { width: 4.1rem; white-space: nowrap; color: var(--blue-deep); }
.combo-table .combo-summary td:last-child { white-space: nowrap; }
.combo-skills { display: flex; flex-wrap: wrap; align-items: baseline; list-style: none; gap: .25rem .35rem; }
.combo-skills li { color: var(--ink); background: var(--soft); border-radius: .24rem; padding: .12rem .36rem; }
.combo-skills .combo-ultimate { background: #eee9fc; color: #573989; }
.skill-type { font-size: .72rem; font-weight: 750; }
.combo-shares summary, .combo-omitted summary, .combo-build summary { color: var(--blue-deep); font-weight: 650; cursor: pointer; }
.combo-shares summary { width: fit-content; font-size: .79rem; }
.share-list { max-width: 34rem; padding-bottom: .3rem; }
.share-row { display: grid; grid-template-columns: minmax(5rem,1fr) auto auto; gap: .25rem .75rem; align-items: baseline; padding: .24rem 0; border-top: 1px solid var(--line); }
.share-row :is(dt,dd) { overflow-wrap: anywhere; }
.share-damage, .share-pct { text-align: right; }
.share-pct { font-weight: 650; }
.combo-omitted { border-top: 1px solid var(--line); padding-top: .65rem; }
.omitted-group { margin-top: .8rem; }
.omitted-group > .combo-skills { margin: .4rem 0; font-size: .84rem; }
.omitted-skill { border-top: 1px solid var(--line); padding: .55rem 0; }
.omitted-skill h4 { font-size: .93rem; margin: 0; }
.omitted-gap { margin: .22rem 0; font-size: .85rem; }
.omitted-best { margin: .45rem 0; display: grid; justify-items: start; gap: .2rem; font-size: .82rem; }
.combo-build { padding-bottom: .75rem; }
.combo-build[open] summary { margin-bottom: .65rem; }
.combo-mobile-label { display: none; }
@media (max-width: 620px) {
  .combo-table, .combo-table tbody, .combo-table tbody tr:last-child, .combo-table td[colspan] { display: block; }
  .combo-table thead { position: absolute; width: 1px; height: 1px; clip-path: inset(50%); overflow: hidden; }
  .combo-summary { display: grid; grid-template-columns: auto minmax(0,1fr); align-items: baseline; gap: .35rem; padding: .45rem 0; }
  .combo-table .combo-summary th, .combo-table .combo-summary td { padding: 0; }
  .combo-summary td:nth-child(2) { grid-row: 2; grid-column: 1 / -1; }
  .combo-summary td:nth-child(3) { text-align: right; }
  .combo-table td[colspan] { padding-inline: 0; }
  .combo-mobile-label { display: inline; color: var(--sub); font-size: .72rem; }
  .share-row { gap: .25rem; font-size: .8rem; }
}

@media (max-width: 840px) {
  .performance-table { display: block; }
  .performance-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .performance-table tbody { display: block; }
  .performance-table tbody tr { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); align-items: start; gap: .45rem .6rem; padding: .75rem; border-top: 1px solid var(--line); }
  .performance-table tbody :is(th,td) { min-width: 0; padding: 0; border: 0; }
  .performance-table tbody tr > :first-child { grid-column: 2; grid-row: 1; align-self: center; text-align: right; }
  .performance-table tbody th { grid-column: 1; grid-row: 1; }
  .performance-table tbody tr > :nth-child(3) { grid-column: 1; }
  .performance-table .equipment-summary { grid-column: 1 / -1; display: flex; align-items: baseline; gap: .5rem; max-width: none; }
  .stat-label { display: block; color: var(--quiet); font-size: .72rem; }
  .equipment-summary .stat-label { min-width: 3.25rem; }
}
@media (max-width: 580px) {
  .main-nav a { gap: .3rem; padding-inline: .15rem; }
  .menu-extra { display: none; }
  .ranking-notes { padding-inline: .7rem; }
  .ranked-select { flex: 1 1 7rem; }
  .matchup-lead { grid-template-columns: 1fr; gap: 0; }
  .matchup-copy { padding: 1rem; }
  .matchup-figure { width: min(100%,21rem); margin: 0 auto .75rem; }
  .matchup-table :is(td,th) { padding: .52rem .45rem; }
  .matchup-table th:first-child { width: 40%; }
  .trait-chip { font-size: .77rem; padding: .13rem .25rem; }
}
