/* 랭킹 화면: 명예의 전당 */
.rk-hero .hero-in { grid-template-columns: 1fr; padding-bottom: 30px; }
.rk-hero h1 { font-size: 46px; margin-bottom: 8px; }
.rk-hero .lead { margin-bottom: 22px; }
.rk-wrap { max-width: 900px; }

/* 숫자 네 칸 */
.rk-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 150px)); gap: 10px; margin: 0; }
.rk-stats div { border: 1px solid rgba(255, 255, 255, .22); background: rgba(255, 255, 255, .06); padding: 10px 14px; }
.rk-stats dt { font-size: 12.5px; color: #9aa0a8; }
.rk-stats dd { margin: 2px 0 0; font-size: 14px; color: #c9ccd1; }
.rk-stats dd b { font: 800 30px/1.1 var(--sans); color: #fff; font-variant-numeric: tabular-nums; margin-right: 2px; }

/* 방금 등록 띠 */
.rk-ticker { position: relative; display: flex; align-items: center; gap: 14px; background: #0c0d10; border-top: 1px solid #2a2d33; padding: 0 20px; height: 44px; color: #cfd2d7; font-size: 14px; overflow: hidden; }
.rk-ticker > b { flex: none; color: #ff8fab; font-size: 12.5px; letter-spacing: .04em; display: inline-flex; align-items: center; gap: 6px; }
.rk-ticker > b::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #ff4d5a; animation: blink 1.4s infinite; }
.tk { flex: 1; overflow: hidden; mask-image: linear-gradient(90deg, transparent, #000 30px, #000 calc(100% - 30px), transparent); -webkit-mask-image: linear-gradient(90deg, transparent, #000 30px, #000 calc(100% - 30px), transparent); }
.tk-in { display: inline-flex; gap: 34px; white-space: nowrap; padding-right: 34px; animation: tk 30s linear infinite; }
.tk-in span b { color: #fff; }
.tk-in span i { font-style: normal; color: #7d838c; font-size: 12.5px; margin-left: 4px; }
@keyframes tk { to { transform: translateX(-50%); } }

.rk-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; align-items: center; }
.rk-tabs button, .rk-filter button { height: 38px; padding: 0 14px; border: 1px solid #c9c3b4; background: #fffef9; font-size: 14.5px; color: #555; border-radius: 3px; }
.rk-tabs button.on, .rk-filter button.on { background: #111; border-color: #111; color: #fff; font-weight: 700; }
.rk-tabs select { height: 38px; border: 1px solid #c9c3b4; background: #fffef9; font: inherit; font-size: 14.5px; padding: 0 8px; border-radius: 3px; max-width: 100%; }
.rk-tabs select.on { border-color: #111; font-weight: 700; color: #111; }
.rk-filter { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.rk-filter button { height: 32px; font-size: 13px; padding: 0 11px; }

.rk-me { background: #111; color: #fff; padding: 14px 18px; margin-bottom: 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: 14.5px; border-left: 5px solid var(--red); }
.rk-me b { color: #ff8fab; font-size: 20px; }
.rk-me a { color: #fff; }
.rk-me .pct { display: inline-block; margin-left: 8px; background: var(--red); color: #fff; font-size: 12.5px; font-weight: 700; padding: 2px 8px; border-radius: 10px; }

/* 시상대: 2등 · 1등 · 3등, 단 높이가 다르다 */
.podium { list-style: none; margin: 26px 0 0; padding: 0 6px; display: grid; grid-template-columns: 1fr 1.12fr 1fr; gap: 0; align-items: end; }
.podium li { min-width: 0; text-align: center; animation: rise .6s both; }
.podium li.p1 { order: 2; animation-delay: .25s; }
.podium li.p2 { order: 1; animation-delay: .1s; }
.podium li.p3 { order: 3; }
@keyframes rise { from { transform: translateY(26px); opacity: 0; } }
.podium .who { padding: 0 6px 10px; }
.podium .crown { height: 30px; font-size: 26px; line-height: 30px; }
.podium .p1 .crown { animation: bob 2.2s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(-5px) rotate(-4deg); } }
.podium .n { font-weight: 800; font-size: 16.5px; color: #111; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.podium .p1 .n { font-size: 21px; }
.podium .e { font-size: 12px; color: #8a8372; min-height: 17px; }
.podium .s { font: 800 34px/1.1 var(--serif); color: var(--red); font-variant-numeric: tabular-nums; }
.podium .p1 .s { font-size: 50px; }
.podium .s small { font-size: 14px; color: #777; font-weight: 400; }
.podium .step { display: flex; align-items: flex-start; justify-content: center; padding-top: 10px; font: 800 40px/1 var(--serif); color: rgba(255, 255, 255, .92); }
.podium .p1 .step { height: 120px; background: linear-gradient(180deg, #e0232a, #b90f15); font-size: 56px; box-shadow: 0 -3px 0 #ff6b70 inset, 0 10px 24px rgba(215, 20, 26, .28); }
.podium .p2 .step { height: 84px; background: linear-gradient(180deg, #2b2e35, #14161a); }
.podium .p3 .step { height: 60px; background: linear-gradient(180deg, #a8a294, #8a8372); }
.podium-base { height: 8px; background: #111; margin: 0 0 18px; }

/* 점수 분포 */
.rk-dist { position: relative; padding: 4px 18px 14px; margin-bottom: 16px; }
.rk-dist h3 { display: flex; align-items: baseline; gap: 8px; }
.rk-dist h3 span { font-weight: 400; color: #a39c8b; letter-spacing: 0; font-size: 12.5px; }
.bars { display: flex; align-items: flex-end; gap: 2px; height: 132px; border-bottom: 1px solid #111; padding-top: 22px; }
.bars .b { flex: 1; min-width: 0; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; position: relative; cursor: default; }
.bars .b i { display: block; width: 100%; max-width: 54px; background: #3a3d44; border-radius: 4px 4px 0 0; min-height: 0; transition: height .5s cubic-bezier(.2, .8, .2, 1); }
.bars .b:hover i { background: #111; }
.bars .b.me i { background: var(--red); }
.bars .b em { font-style: normal; font-size: 11.5px; color: #555; margin-bottom: 3px; font-variant-numeric: tabular-nums; }
.bars .b.me em { color: #111; font-weight: 800; }
.bars .b.me em::before { content: "나 · "; color: var(--red); }
.bars .b.zero i { height: 2px !important; background: #dcd7ca; }
.axis { display: flex; gap: 2px; margin-top: 5px; }
.axis span { flex: 1; text-align: center; font-size: 11px; color: #8a8372; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; }
.rk-dist .tip { position: absolute; z-index: 3; pointer-events: none; background: #111; color: #fff; font-size: 12.5px; padding: 6px 9px; border-radius: 4px; white-space: nowrap; transform: translate(-50%, -100%); }

/* 명단 */
.rk-list { padding: 0 0 4px; }
table.rk { width: 100%; border-collapse: collapse; font-size: 15px; }
table.rk th { font-size: 12.5px; color: #8a8372; font-weight: 600; text-align: left; padding: 10px 14px; border-bottom: 1px solid #111; }
table.rk td { padding: 11px 14px; border-bottom: 1px solid #ebe6da; position: relative; }
table.rk th:first-child, table.rk td:first-child { width: 64px; text-align: center; font-variant-numeric: tabular-nums; }
table.rk td:first-child { font: 800 17px var(--serif); color: #8a8372; }
table.rk tr.t10 td:first-child { color: #111; }
table.rk th:last-child, table.rk td:last-child { text-align: right; width: 150px; font-variant-numeric: tabular-nums; }
table.rk td:last-child { font-weight: 800; color: #111; white-space: nowrap; }
/* 점수 막대: 점수 옆에 길이로도 보인다 */
table.rk td:last-child .bar { display: inline-block; vertical-align: middle; width: 70px; height: 6px; background: #ebe6da; border-radius: 3px; margin-right: 10px; overflow: hidden; }
table.rk td:last-child .bar i { display: block; height: 100%; background: #3a3d44; border-radius: 3px; }
table.rk td.el { color: #777; font-size: 13.5px; }
table.rk td:nth-child(2) { font-weight: 600; }
table.rk tr.me td { background: #fff3f5; }
table.rk tr.me td:first-child { box-shadow: inset 4px 0 0 var(--red); }
.badge { display: inline-block; margin-left: 6px; font-size: 10.5px; font-weight: 800; padding: 1px 6px; border-radius: 8px; vertical-align: 2px; letter-spacing: .02em; }
.badge.new { background: #111; color: #fff; }
.badge.mine { background: var(--red); color: #fff; }
.badge.full { border: 1px solid var(--red); color: var(--red); }
table.rk tr { animation: rowin .35s both; }
@keyframes rowin { from { opacity: 0; transform: translateY(6px); } }
.rk-empty { text-align: center; color: #888; padding: 34px 14px; margin: 0; font-size: 14.5px; line-height: 1.8; }
.rk-empty a { display: inline-flex; margin-top: 12px; }

@media (max-width: 860px) {
  .rk-hero h1 { font-size: 30px; }
  .rk-hero .hero-in { padding-bottom: 20px; }
  .rk-hero .lead { margin-bottom: 16px; }
  .rk-stats { grid-template-columns: repeat(4, 1fr); gap: 6px; }
  .rk-stats div { padding: 8px 8px; }
  .rk-stats dt { font-size: 11px; }
  .rk-stats dd { font-size: 11.5px; }
  .rk-stats dd b { font-size: 21px; }
  .rk-ticker { padding: 0 14px; height: 40px; font-size: 13px; gap: 10px; }
  .rk-tabs button { padding: 0 11px; font-size: 14px; }
  .podium { padding: 0; margin-top: 18px; }
  .podium .s { font-size: 26px; }
  .podium .p1 .s { font-size: 36px; }
  .podium .n { font-size: 14px; }
  .podium .p1 .n { font-size: 16.5px; }
  .podium .p1 .step { height: 96px; font-size: 44px; }
  .podium .p2 .step { height: 68px; font-size: 32px; }
  .podium .p3 .step { height: 48px; font-size: 28px; }
  .rk-dist { padding: 4px 10px 12px; }
  .bars { height: 112px; }
  .axis span { font-size: 9.5px; }
  .axis span:nth-child(even) { visibility: hidden; }
  table.rk th, table.rk td { padding: 10px 8px; }
  table.rk th:first-child, table.rk td:first-child { width: 44px; }
  table.rk th:last-child, table.rk td:last-child { width: 96px; }
  table.rk td:last-child .bar { width: 36px; margin-right: 6px; }
  table.rk .el { display: none; }
}
@media (prefers-reduced-motion: reduce) { .tk-in, .podium li, .podium .p1 .crown, table.rk tr { animation: none; } .tk-in { padding-left: 0; } }
