/* =====================================================
   도감 · 카드 보기 · 보상표 (2026-11-15 확정 목업, scratchpad/dexmock/tpl.html ①~⑤)
   - 격자 칸은 그림 + 등급색 도트 테두리만 (가벼움), S 만 은은한 빛. 애니메이션은 '받을 칸' 반짝 하나뿐
   ===================================================== */
.dx-rank { display: flex; align-items: center; gap: 6px; padding: 6px; margin-bottom: 6px; font-size: 11px; background: var(--p-surface); border: 3px solid var(--p-line); box-shadow: inset 0 0 0 2px #3a3550; cursor: pointer; color: var(--p-text); }
.dx-rank .bar { flex: 1; min-width: 30px; height: 8px; background: #000; border: 1px solid #3a3550; }
.dx-rank .bar i { display: block; height: 100%; background: var(--p-accent); }
.dx-rank > span:last-child { white-space: nowrap; color: var(--p-muted); }
.gtag { display: inline-grid; place-items: center; min-width: 22px; height: 18px; padding: 0 3px; font-weight: 700; color: #fff; border: 2px solid #000; font-size: 11px; line-height: 1; text-shadow: 1px 1px 0 #0008; }
.rd { position: absolute; top: -4px; right: -4px; width: 8px; height: 8px; background: #e3263f; border: 1px solid #000; }
/* 광산 탭 (가로로 넘김) */
.dx-mines { display: flex; gap: 4px; overflow-x: auto; padding: 4px 2px 6px; margin-bottom: 4px; scrollbar-width: thin; }
.dx-mine { flex: 0 0 auto; position: relative; padding: 4px 6px; font-size: 10px; line-height: 1.3; text-align: center; background: #2c283b; border: 2px solid #000; color: var(--p-muted); cursor: pointer; }
.dx-mine b { display: block; color: var(--p-text); font-size: 11px; }
.dx-mine.on { background: #3a2a12; box-shadow: inset 0 -3px 0 var(--p-accent); color: var(--p-text); }
.dx-mine.done b::after { content: " ✓"; color: #9be3a8; }
/* 등급별 | 세트 */
.dx-sub { display: flex; gap: 6px; margin-bottom: 8px; }
.dx-sub > div { flex: 1; position: relative; text-align: center; padding: 6px; font-size: 12px; font-weight: 700; background: #2c283b; border: 3px solid #000; color: var(--p-muted); cursor: pointer; }
.dx-sub > div.on { background: var(--p-accent); color: var(--p-on-accent); }
/* 광산 요약 */
.dx-sum { padding: 7px; margin-bottom: 8px; font-size: 11px; background: var(--p-surface); border: 3px solid #000; box-shadow: inset 0 0 0 2px #3a3550; }
.dx-sum .top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 5px; color: var(--p-muted); }
.dx-sum .top b { font-size: 14px; color: var(--p-text); }
.dx-steps { display: grid; gap: 3px; margin-bottom: 5px; }
.dx-step { text-align: center; font-size: 9px; padding: 3px 0; background: #2c283b; border: 2px solid #000; color: var(--p-muted); white-space: nowrap; }
.dx-step.got { background: #23402a; color: #9be3a8; }
.dx-step.ready { background: var(--p-accent); color: var(--p-on-accent); font-weight: 700; cursor: pointer; animation: dxPulse 1.2s steps(2) infinite; }
@keyframes dxPulse { 50% { opacity: .72; } }
.dx-stats { display: flex; gap: 4px; }
.dx-stats span { flex: 1; text-align: center; background: #000; padding: 3px; font-size: 10px; color: var(--p-muted); }
.dx-stats b { color: var(--p-text); }
.hint { font-size: 10px; color: var(--p-muted); margin: 4px 0; line-height: 1.4; }
.hint.gold { color: var(--p-accent); }
/* 등급 줄 */
.dx-gsec { margin-bottom: 8px; }
.ghead { display: flex; align-items: center; gap: 6px; margin-bottom: 4px; font-size: 11px; color: var(--p-muted); }
.ghead .ok { color: #9be3a8; }
.dx-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 4px; }
.dx-grid.six { grid-template-columns: repeat(6, minmax(0, 1fr)); }
/* 작은 그림 칸 */
.th { position: relative; aspect-ratio: 132 / 193; background: var(--gc); padding: 2px; cursor: pointer; min-width: 0;
  clip-path: polygon(0 3px, 3px 3px, 3px 0, calc(100% - 3px) 0, calc(100% - 3px) 3px, 100% 3px, 100% calc(100% - 3px), calc(100% - 3px) calc(100% - 3px), calc(100% - 3px) 100%, 3px 100%, 3px calc(100% - 3px), 0 calc(100% - 3px)); }
.th img { width: 100%; height: 100%; object-fit: cover; display: block; border: 1px solid #000; background: #000; }
.th .cnt { position: absolute; right: 2px; bottom: 2px; background: #000c; color: var(--p-text); font-size: 8px; padding: 0 2px; line-height: 1.3; }
.th .st { position: absolute; right: 2px; top: 2px; width: 8px; height: 8px; background: #ffb03b; border: 1px solid #000; }
.th.byshard .cnt { color: var(--p-info); }
.th.none { background: #2a2638; }
.th.none .q { position: absolute; inset: 2px; background: #16131f; border: 1px dashed #3a3550; display: flex; flex-direction: column; align-items: center; justify-content: center; font-size: 14px; color: #4b4562; font-weight: 700; }
.th.none .q small { font-size: 8px; color: var(--p-muted); font-weight: 400; white-space: nowrap; }
.th.none.shardable { background: var(--p-info); }
.th.none.shardable .q small { color: var(--p-info); }
.th.gS:not(.none) { clip-path: none; box-shadow: 0 0 6px #b98cff; } /* S 만 은은한 빛 (클립하면 빛이 잘려서 S 는 네모 그대로) */
/* 세트 */
.dx-set { padding: 6px; margin-bottom: 6px; background: var(--p-surface); border: 3px solid #000; box-shadow: inset 0 0 0 2px #3a3550; }
.dx-set .h { display: flex; justify-content: space-between; font-size: 11px; margin-bottom: 4px; color: var(--p-muted); }
.dx-set .h b { color: var(--p-accent); }
.dx-set .pb { height: 6px; background: #000; margin-top: 5px; }
.dx-set .pb i { display: block; height: 100%; background: var(--p-accent); }
.dx-set.done { box-shadow: inset 0 0 0 2px #9be3a8; }
.dx-set .rowbtn { margin-top: 6px; }
/* 카드 보기 */
.zoom.cardview { padding: 16px; overflow-y: auto; justify-content: flex-start; }
.cv-box { width: min(100%, 340px); margin: auto 0; background: var(--p-surface); border: 3px solid #000; box-shadow: inset 0 0 0 2px #3a3550; padding: 10px 12px 12px; display: flex; flex-direction: column; align-items: center; gap: 8px; font-size: 12px; color: var(--p-text); }
.cv-title { color: var(--p-accent); font-size: 16px; font-weight: 700; width: 100%; text-align: center; padding-bottom: 6px; border-bottom: 2px dashed var(--p-accent); }
.zoom.cardview .card.fcard.big { width: 170px; font-size: 14.2px; margin: 8px 0 6px; }
.cv-miss { width: 120px; background: #2a2638; padding: 5px; margin: 6px 0; }
.cv-miss .q { aspect-ratio: 300 / 438; background: #16131f; border: 2px dashed #3a3550; display: grid; place-items: center; font-size: 30px; color: #4b4562; font-weight: 700; }
.cv-miss .nm { margin-top: 4px; background: #14111d; border: 2px solid #000; text-align: center; font-size: 11px; font-weight: 700; padding: 4px; box-shadow: inset 0 -3px 0 var(--gc); }
.cv-kv { width: 100%; display: grid; grid-template-columns: auto 1fr; gap: 5px 10px; margin: 0; padding: 8px; background: var(--p-well); border: 2px solid #000; font-size: 11px; }
.cv-kv dt { color: var(--p-muted); }
.cv-kv dd { margin: 0; text-align: right; }
.cv-kv dd small { display: block; color: var(--p-muted); font-size: 10px; }
.cv-box .rowbtn, .cv-box .closebtn { width: 100%; margin: 0; }
.cv-shard small { font-weight: 400; }
.cv-shard.off { opacity: .55; }
/* 보상표 */
.pr-bets { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 3px; margin-bottom: 6px; }
.pr-bet { text-align: center; font-size: 10px; padding: 5px 0; background: #2c283b; border: 2px solid #000; color: var(--p-muted); cursor: pointer; white-space: nowrap; }
.pr-bet.on { background: var(--p-accent); color: var(--p-on-accent); font-weight: 700; }
.pr-mline { display: flex; align-items: center; justify-content: space-between; gap: 6px; font-size: 11px; margin: 4px 0 8px; color: var(--p-muted); }
.pr-mline b { color: var(--p-text); }
.pr-mline .modetag { font-size: 10px; }
.pr-view { flex: 0 0 auto; padding: 4px 7px; font-size: 10px; font-weight: 700; background: #2c283b; border: 2px solid #000; color: var(--p-text); cursor: pointer; }
.pr-row { display: flex; align-items: center; gap: 6px; padding: 7px 6px; border-bottom: 1px solid #000; font-size: 11px; background: var(--p-well); cursor: pointer; color: var(--p-muted); }
.pr-row.on { background: #221f30; }
.pr-row .gtag { min-width: 26px; height: 22px; font-size: 12px; }
.pr-row .sc { flex: 1; }
.pr-row .sc b { font-size: 13px; color: var(--p-text); }
.pr-row .cn { font-size: 10px; }
.pr-row .pr { color: var(--p-accent); font-weight: 700; min-width: 40px; text-align: right; }
.pr-row .ar { font-size: 10px; width: 10px; }
.pr-open { background: #1a1726; padding: 6px; border-bottom: 1px solid #000; }
.pr-pc { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 4px 4px; }
.pr-cell { text-align: center; font-size: 8px; color: var(--p-muted); min-width: 0; }
.pr-cell b { display: block; color: var(--p-text); font-size: 10px; margin-top: 2px; }
.pr-note { font-size: 9px; color: var(--p-muted); margin-top: 5px; line-height: 1.4; }
.pr-gtabs { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 2px; margin-bottom: 6px; }
.pr-gtabs > div { text-align: center; padding: 5px 0; font-size: 11px; font-weight: 700; border: 2px solid #000; color: #fff; opacity: .45; cursor: pointer; }
.pr-gtabs > div.on { opacity: 1; box-shadow: inset 0 -3px 0 #fff; }
.pr-tbox { padding: 6px; background: var(--p-surface); border: 3px solid #000; box-shadow: inset 0 0 0 2px #3a3550; }
.pr-th { font-size: 11px; margin-bottom: 4px; color: var(--p-muted); }
.ptable { width: 100%; border-collapse: collapse; font-size: 10px; table-layout: auto; }
.ptable th { color: var(--p-muted); font-weight: 400; text-align: left; padding: 3px 2px; border-bottom: 2px solid #000; white-space: nowrap; }
.ptable td { padding: 3px 2px; border-bottom: 1px solid #2a2638; vertical-align: middle; color: var(--p-text); }
.ptable tr[data-key] { cursor: pointer; }
.ptable td.n { word-break: keep-all; }
.ptable .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.ptable .mini { width: 24px; aspect-ratio: 132 / 193; background: var(--gc); padding: 1px; }
.ptable .mini img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ptable .mini.miss { background: #2a2638; }
@media (prefers-reduced-motion: reduce) { .dx-step.ready { animation: none; } }
/* 설정 > 오픈소스 라이선스 */
.oss { margin-top: 8px; font-size: 11px; line-height: 1.5; color: var(--p-muted); }
.oss summary { cursor: pointer; font-size: 12px; color: var(--p-text); }
.oss p { margin: 6px 0; } .oss b { color: var(--p-text); }
/* 세트 11개 · 난이도 · 광산 완성 · 받기 창 (2026-11-16, docs/luckydig-sets.md) */
.dtag { display: inline-block; padding: 0 4px; margin-right: 5px; font-size: 10px; font-weight: 700; line-height: 16px; color: #1a1420; border: 2px solid #000; }
.dx-set { border-left: 6px solid var(--dc, #000); }
.dx-set .h { align-items: center; justify-content: flex-start; gap: 0; }
.dx-set .h b { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dx-set .hook { font-size: 10px; color: var(--p-muted); margin: -1px 0 5px; }
.dx-set .pb i { background: var(--dc, var(--p-accent)); }
.dx-set.ready { box-shadow: inset 0 0 0 2px var(--p-accent); }
.dx-set .hint .rw { color: var(--p-accent); }
.dx-full { display: flex; justify-content: space-between; align-items: center; gap: 6px; padding: 5px 7px; margin: 5px 0; font-size: 11px; background: #000; color: var(--p-muted); border: 2px solid #3a3550; }
.dx-full b { color: var(--p-text); }
.dx-full.ready { background: var(--p-accent); color: var(--p-on-accent); border-color: #000; cursor: pointer; animation: dxPulse 1.2s steps(2) infinite; }
.dx-full.ready b { color: var(--p-on-accent); }
.dx-full.done b { color: #9be3a8; }
.cv-kv .dtag { margin-right: 3px; }
.rwclaim .rw-title { color: var(--p-accent); font-size: 18px; font-weight: 700; margin-bottom: 6px; }
.rwclaim .rw-head { font-size: 14px; }
.rwclaim .rw-sub { font-size: 11px; color: var(--p-muted); margin-top: 2px; }
.rwclaim .rw-amt { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; margin: 12px 0; padding: 8px 10px; background: var(--p-well, #000); border: 2px solid #000; font-size: 12px; text-align: left; }
.rwclaim .rw-amt b { text-align: right; }
.rwclaim .rw-amt .x { color: var(--p-muted); }
.rwclaim .rw-amt b.ad { color: var(--p-accent); font-size: 15px; }
.rwclaim .rbtns button { display: inline-flex; align-items: center; justify-content: center; gap: 4px; padding: 10px 6px; }
.rwclaim .rw-later { margin-top: 8px; background: none; border: 0; color: var(--p-muted); font: inherit; font-size: 11px; text-decoration: underline; cursor: pointer; }
@media (prefers-reduced-motion: reduce) { .dx-full.ready { animation: none; } }
.rwclaim .rbtns .mico { width: 18px; height: 18px; margin: 0 2px 0 0; color: currentColor; }
