/* ============================================================================
   今日の10問 月間ランキング発表セレモニー (Monthly Ranking Ceremony)
   高級アワード授賞式風「光・スポットライト・箔押し（Foil Sheen）」演出
   グローバル .table スタイルから独立した高コントラスト・無音デザイン
   ============================================================================ */

/* モーダル外形 */
#monthlyResultModal .modal-dialog {
    --bs-modal-width: 580px;
}

.mrc-modal-content {
    border: 1.5px solid rgba(250, 204, 21, 0.52);
    border-radius: 22px;
    overflow: hidden;
    background: #0b1120;
    color: #f8fafc;
    box-shadow:
        0 28px 65px -12px rgba(2, 6, 23, 0.78),
        0 0 46px rgba(250, 204, 21, 0.16);
}

/* ステージラッパー */
.mrc-stage-wrap {
    position: relative;
    overflow: hidden;
}

/* 右上閉じるボタン */
.mrc-stage-controls {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 25;
    display: flex;
    align-items: center;
}

.mrc-icon-btn {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.28);
    background: rgba(15, 23, 42, 0.62);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.88rem;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.15s ease;
}

.mrc-icon-btn:hover {
    background: rgba(255, 255, 255, 0.22);
    transform: scale(1.06);
}

/* ============================================================================
   シネマティック光学演出レイヤー（スポットライト・ボケ光粒・レンズフレア）
   ============================================================================ */

/* 劇場スポットライト光線 */
.mrc-spotlight-beam {
    position: absolute;
    top: -35%;
    width: 44%;
    height: 155%;
    pointer-events: none;
    z-index: 1;
    opacity: 0.42;
    transform-origin: top center;
    background: linear-gradient(
        180deg,
        rgba(254, 240, 138, 0.34) 0%,
        rgba(250, 204, 21, 0.12) 45%,
        rgba(250, 204, 21, 0) 85%
    );
    filter: blur(18px);
}

.mrc-spotlight-beam.is-left {
    left: -4%;
    transform: rotate(-24deg);
    animation: mrcBeamSwayLeft 7.5s ease-in-out infinite;
}

.mrc-spotlight-beam.is-right {
    right: -4%;
    transform: rotate(24deg);
    animation: mrcBeamSwayRight 8.2s ease-in-out infinite;
}

@keyframes mrcBeamSwayLeft {
    0%, 100% {
        transform: rotate(-24deg);
        opacity: 0.36;
    }
    50% {
        transform: rotate(-18deg);
        opacity: 0.52;
    }
}

@keyframes mrcBeamSwayRight {
    0%, 100% {
        transform: rotate(24deg);
        opacity: 0.36;
    }
    50% {
        transform: rotate(18deg);
        opacity: 0.52;
    }
}

/* Act 2 中央ヒーロー・スポットライト（1位登場で点灯） */
.mrc-center-spotlight {
    position: absolute;
    top: -18%;
    left: 50%;
    width: 320px;
    height: 120%;
    transform: translateX(-50%) scaleY(0.88);
    pointer-events: none;
    z-index: 1;
    opacity: 0;
    background: radial-gradient(
        ellipse at 50% 42%,
        rgba(254, 240, 138, 0.28) 0%,
        rgba(250, 204, 21, 0.12) 40%,
        transparent 74%
    );
    transition: opacity 0.75s cubic-bezier(0.22, 1, 0.36, 1), transform 0.75s ease;
}

.mrc-center-spotlight.is-lit {
    opacity: 1;
    transform: translateX(-50%) scaleY(1);
}

/* 繊細なシャンパンゴールドのボケ光粒 */
.mrc-bokeh-field {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 1;
}

.mrc-bokeh-dot {
    position: absolute;
    left: var(--x, 50%);
    bottom: -12px;
    width: var(--size, 4px);
    height: var(--size, 4px);
    border-radius: 50%;
    background: radial-gradient(
        circle,
        rgba(254, 249, 195, 0.95) 0%,
        rgba(250, 204, 21, 0.55) 45%,
        rgba(250, 204, 21, 0) 75%
    );
    box-shadow: 0 0 8px rgba(250, 204, 21, 0.45);
    opacity: 0;
    animation: mrcBokehRise var(--dur, 7s) linear var(--delay, 0s) infinite;
}

@keyframes mrcBokehRise {
    0% {
        transform: translate3d(0, 0, 0) scale(0.7);
        opacity: 0;
    }
    18% {
        opacity: 0.75;
    }
    80% {
        opacity: 0.45;
    }
    100% {
        transform: translate3d(var(--drift, 14px), -340px, 0) scale(1.1);
        opacity: 0;
    }
}

/* アナモルフィック・ゴールデン・レンズフレア切替 */
.mrc-cine-transition {
    position: absolute;
    inset: 0;
    z-index: 32;
    pointer-events: none;
    opacity: 0;
}

.mrc-flare-bar {
    position: absolute;
    top: 44%;
    left: 50%;
    width: 120%;
    height: 3px;
    transform: translate(-50%, -50%) scaleX(0.15);
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(250, 204, 21, 0.4) 22%,
        rgba(254, 249, 195, 0.98) 50%,
        rgba(250, 204, 21, 0.4) 78%,
        transparent 100%
    );
    box-shadow:
        0 0 18px rgba(254, 240, 138, 0.85),
        0 0 42px rgba(245, 158, 11, 0.55);
}

.mrc-flare-ring {
    position: absolute;
    top: 44%;
    left: 50%;
    width: 110px;
    height: 110px;
    border-radius: 50%;
    border: 1.5px solid rgba(254, 240, 138, 0.85);
    box-shadow: 0 0 22px rgba(250, 204, 21, 0.45);
    transform: translate(-50%, -50%) scale(0.35);
    opacity: 0;
}

.mrc-cine-transition.is-playing {
    animation: mrcCineBackdrop 0.62s ease-out forwards;
}

.mrc-cine-transition.is-playing .mrc-flare-bar {
    animation: mrcFlareBarSweep 0.62s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.mrc-cine-transition.is-playing .mrc-flare-ring {
    animation: mrcFlareRingExpand 0.62s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes mrcCineBackdrop {
    0% {
        opacity: 0;
        background: rgba(250, 204, 21, 0);
    }
    25% {
        opacity: 1;
        background: radial-gradient(circle at 50% 44%, rgba(254, 240, 138, 0.28) 0%, transparent 65%);
    }
    100% {
        opacity: 0;
        background: transparent;
    }
}

@keyframes mrcFlareBarSweep {
    0% {
        transform: translate(-50%, -50%) scaleX(0.12);
        opacity: 0;
    }
    32% {
        transform: translate(-50%, -50%) scaleX(1.05);
        opacity: 1;
    }
    100% {
        transform: translate(-50%, -50%) scaleX(1.45);
        opacity: 0;
    }
}

@keyframes mrcFlareRingExpand {
    0% {
        transform: translate(-50%, -50%) scale(0.35);
        opacity: 0.9;
    }
    100% {
        transform: translate(-50%, -50%) scale(3.4);
        opacity: 0;
    }
}

/* ============================================================================
   ACT 1: クラシック・ゴールド額縁オープニング幕
   ============================================================================ */
.mrc-opening-stage {
    position: relative;
    min-height: 440px;
    padding: 54px 24px 32px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    background:
        radial-gradient(circle at 50% 40%, rgba(250, 204, 21, 0.14) 0%, transparent 56%),
        linear-gradient(165deg, #070b14 0%, #0f172a 46%, #172554 100%);
    overflow: hidden;
}

.mrc-opening-stage.is-hidden {
    display: none;
}

/* クラシック二重額縁ライン＆コーナー装飾 */
.mrc-ornate-frame {
    position: absolute;
    inset: 14px;
    border: 1px solid rgba(250, 204, 21, 0.28);
    border-radius: 14px;
    pointer-events: none;
    z-index: 2;
}

.mrc-ornate-frame::before {
    content: "";
    position: absolute;
    inset: 5px;
    border: 1px solid rgba(250, 204, 21, 0.12);
    border-radius: 10px;
}

.mrc-corner {
    position: absolute;
    width: 14px;
    height: 14px;
    border-color: rgba(253, 224, 71, 0.72);
    border-style: solid;
}

.mrc-corner.is-tl {
    top: -1px;
    left: -1px;
    border-width: 2px 0 0 2px;
    border-top-left-radius: 6px;
}

.mrc-corner.is-tr {
    top: -1px;
    right: -1px;
    border-width: 2px 2px 0 0;
    border-top-right-radius: 6px;
}

.mrc-corner.is-bl {
    bottom: -1px;
    left: -1px;
    border-width: 0 0 2px 2px;
    border-bottom-left-radius: 6px;
}

.mrc-corner.is-br {
    bottom: -1px;
    right: -1px;
    border-width: 0 2px 2px 0;
    border-bottom-right-radius: 6px;
}

.mrc-opening-content {
    position: relative;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: 440px;
}

.mrc-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 14px;
    border-radius: 999px;
    background: rgba(250, 204, 21, 0.13);
    border: 1px solid rgba(250, 204, 21, 0.45);
    color: #fde047;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.mrc-opening-period {
    margin: 14px 0 4px;
    font-size: 2rem;
    font-weight: 900;
    color: #ffffff;
    letter-spacing: 0.03em;
    text-shadow: 0 3px 14px rgba(0, 0, 0, 0.6);
    line-height: 1.2;
}

.mrc-opening-title {
    margin: 0 0 18px;
    font-size: 1.04rem;
    font-weight: 700;
    color: #e2e8f0;
}

/* 月桂樹SVGクレスト＋メダリオン */
.mrc-crest-wrap {
    position: relative;
    width: 148px;
    height: 136px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px;
}

.mrc-crest-ring {
    position: absolute;
    width: 126px;
    height: 126px;
    border-radius: 50%;
    border: 1px dashed rgba(253, 224, 71, 0.36);
    animation: mrcCrestRotate 26s linear infinite;
    pointer-events: none;
}

@keyframes mrcCrestRotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.mrc-laurel-svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    filter: drop-shadow(0 0 12px rgba(250, 204, 21, 0.35));
}

.mrc-trophy-medallion {
    position: relative;
    width: 88px;
    height: 88px;
    border-radius: 50%;
    padding: 3px;
    background: linear-gradient(135deg, #fef08a 0%, #f59e0b 52%, #b45309 100%);
    box-shadow:
        0 0 28px rgba(250, 204, 21, 0.36),
        0 12px 24px rgba(2, 6, 23, 0.6);
    animation: mrcMedallionFloat 3s ease-in-out infinite;
}

.mrc-trophy-medallion-inner {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 30%, #1e293b 0%, #090d16 82%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.2rem;
    color: #fde047;
    text-shadow: 0 2px 12px rgba(250, 204, 21, 0.6);
}

@keyframes mrcMedallionFloat {
    0%, 100% {
        transform: translateY(0) scale(1);
    }
    50% {
        transform: translateY(-4px) scale(1.025);
    }
}

.mrc-opening-meta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 5px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.09);
    border: 1px solid rgba(255, 255, 255, 0.18);
    color: #f1f5f9;
    font-size: 0.84rem;
    font-weight: 600;
    margin-bottom: 22px;
}

.mrc-reveal-btn {
    position: relative;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    max-width: 300px;
    padding: 15px 28px;
    border-radius: 999px;
    border: 2px solid #fef9c3;
    background: linear-gradient(135deg, #fef08a 0%, #facc15 48%, #f59e0b 100%);
    color: #1c1917;
    font-size: 1.12rem;
    font-weight: 900;
    letter-spacing: 0.03em;
    cursor: pointer;
    box-shadow:
        0 10px 28px rgba(245, 158, 11, 0.42),
        inset 0 1px 0 rgba(255, 255, 255, 0.78);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.mrc-reveal-btn::after {
    content: "";
    position: absolute;
    top: 0;
    left: -120%;
    width: 55%;
    height: 100%;
    background: linear-gradient(
        110deg,
        transparent 0%,
        rgba(255, 255, 255, 0.65) 50%,
        transparent 100%
    );
    animation: mrcBtnShimmer 2.8s ease-in-out infinite;
}

@keyframes mrcBtnShimmer {
    0% {
        left: -120%;
    }
    45%, 100% {
        left: 145%;
    }
}

.mrc-reveal-btn:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow:
        0 14px 34px rgba(250, 204, 21, 0.56),
        inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

.mrc-reveal-btn:active {
    transform: translateY(1px) scale(0.99);
}

.mrc-skip-btn {
    margin-top: 14px;
    background: none;
    border: none;
    color: #cbd5e1;
    font-size: 0.84rem;
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 3px;
    cursor: pointer;
    padding: 4px 10px;
}

.mrc-skip-btn:hover {
    color: #ffffff;
}

/* ============================================================================
   ACT 2: 表彰台 & 詳細結果ステージ
   ============================================================================ */
.mrc-results-stage {
    display: block;
}

.mrc-results-stage.is-hidden {
    display: none;
}

/* 上部表彰台ヒーロー */
.mrc-podium-hero {
    position: relative;
    padding: 22px 16px 20px;
    background:
        radial-gradient(circle at 50% 18%, rgba(250, 204, 21, 0.16) 0%, transparent 58%),
        linear-gradient(175deg, #070b14 0%, #0f172a 56%, #172554 100%);
    text-align: center;
    overflow: hidden;
}

.mrc-hero-header {
    position: relative;
    z-index: 3;
    padding: 0 46px;
}

.mrc-hero-period {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(250, 204, 21, 0.16);
    border: 1px solid rgba(250, 204, 21, 0.45);
    color: #fde047;
    font-size: 0.78rem;
    font-weight: 800;
    padding: 4px 12px;
    border-radius: 999px;
}

.mrc-hero-title {
    margin: 8px 0 2px;
    color: #ffffff;
    font-size: 1.28rem;
    font-weight: 900;
    letter-spacing: 0.02em;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.mrc-hero-subtitle {
    margin: 0;
    color: #cbd5e1;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.08em;
}

/* 表彰台グリッド */
.mrc-podium-grid {
    position: relative;
    z-index: 3;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
    min-height: 210px;
}

.mrc-podium-slot {
    position: relative;
    flex: 1 1 0;
    max-width: 170px;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    opacity: 0;
    transform: translateY(34px) scale(0.92);
    transition:
        opacity 0.48s cubic-bezier(0.22, 1, 0.36, 1),
        transform 0.56s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.mrc-podium-slot.is-revealed {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* 1位専用: 二重ゴールド光輪＆4芒星グリント */
.mrc-champion-aura {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.mrc-champion-ring {
    position: absolute;
    top: 20px;
    left: 50%;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    border: 1.5px solid rgba(253, 224, 71, 0.72);
    transform: translate(-50%, -50%) scale(0.5);
    opacity: 0;
    pointer-events: none;
}

.mrc-podium-slot.is-rank-1.is-revealed .mrc-champion-ring.is-r1 {
    animation: mrcChampRingPulse 1.15s cubic-bezier(0.16, 1, 0.3, 1) 0.1s forwards;
}

.mrc-podium-slot.is-rank-1.is-revealed .mrc-champion-ring.is-r2 {
    animation: mrcChampRingPulse 1.35s cubic-bezier(0.16, 1, 0.3, 1) 0.25s forwards;
}

@keyframes mrcChampRingPulse {
    0% {
        transform: translate(-50%, -50%) scale(0.55);
        opacity: 0.9;
    }
    100% {
        transform: translate(-50%, -50%) scale(2.05);
        opacity: 0;
    }
}

.mrc-star-glint {
    position: absolute;
    width: 14px;
    height: 14px;
    color: #fef08a;
    filter: drop-shadow(0 0 6px rgba(250, 204, 21, 0.9));
    opacity: 0;
    pointer-events: none;
}

.mrc-star-glint.is-g1 { top: -8px; left: -24px; }
.mrc-star-glint.is-g2 { top: 2px; right: -26px; width: 11px; height: 11px; }
.mrc-star-glint.is-g3 { top: 34px; left: -30px; width: 10px; height: 10px; }
.mrc-star-glint.is-g4 { top: 38px; right: -24px; width: 12px; height: 12px; }

.mrc-podium-slot.is-rank-1.is-revealed .mrc-star-glint.is-g1 {
    animation: mrcStarGlint 2.6s ease-in-out 0.15s infinite;
}
.mrc-podium-slot.is-rank-1.is-revealed .mrc-star-glint.is-g2 {
    animation: mrcStarGlint 2.6s ease-in-out 0.85s infinite;
}
.mrc-podium-slot.is-rank-1.is-revealed .mrc-star-glint.is-g3 {
    animation: mrcStarGlint 2.6s ease-in-out 1.45s infinite;
}
.mrc-podium-slot.is-rank-1.is-revealed .mrc-star-glint.is-g4 {
    animation: mrcStarGlint 2.6s ease-in-out 2.05s infinite;
}

@keyframes mrcStarGlint {
    0%, 100% {
        opacity: 0;
        transform: scale(0.4) rotate(0deg);
    }
    35% {
        opacity: 0.95;
        transform: scale(1.1) rotate(20deg);
    }
    70% {
        opacity: 0.15;
        transform: scale(0.75) rotate(45deg);
    }
}

.mrc-podium-crown {
    position: relative;
    z-index: 2;
    color: #fde047;
    font-size: 1.35rem;
    margin-bottom: 4px;
    filter: drop-shadow(0 0 10px rgba(250, 204, 21, 0.8));
    animation: mrcCrownBounce 2.4s ease-in-out infinite;
}

@keyframes mrcCrownBounce {
    0%, 100% {
        transform: translateY(0) rotate(-2deg);
    }
    50% {
        transform: translateY(-3px) rotate(2deg);
    }
}

.mrc-podium-medal {
    position: relative;
    z-index: 2;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 0.95rem;
    margin-bottom: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.mrc-podium-slot.is-rank-1 .mrc-podium-medal {
    width: 44px;
    height: 44px;
    font-size: 1.15rem;
    background: linear-gradient(135deg, #fef08a 0%, #facc15 55%, #d97706 100%);
    color: #1c1917;
    border: 2px solid #fef9c3;
    box-shadow: 0 0 18px rgba(250, 204, 21, 0.55), 0 4px 12px rgba(0, 0, 0, 0.45);
}

.mrc-podium-slot.is-rank-2 .mrc-podium-medal {
    background: linear-gradient(135deg, #ffffff 0%, #cbd5e1 65%, #94a3b8 100%);
    color: #0f172a;
    border: 2px solid #f1f5f9;
}

.mrc-podium-slot.is-rank-3 .mrc-podium-medal {
    background: linear-gradient(135deg, #fdba74 0%, #ea580c 60%, #9a3412 100%);
    color: #fff7ed;
    border: 2px solid #fed7aa;
}

.mrc-podium-name-row {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    margin-bottom: 4px;
}

.mrc-podium-name {
    color: #ffffff;
    font-weight: 800;
    font-size: 0.92rem;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.78);
}

.mrc-podium-slot.is-rank-1 .mrc-podium-name {
    font-size: 1rem;
}

.mrc-podium-you {
    flex-shrink: 0;
    background: #2563eb;
    color: #ffffff;
    border: 1px solid #93c5fd;
    font-size: 0.62rem;
    font-weight: 800;
    padding: 1px 6px;
    border-radius: 999px;
}

.mrc-podium-title-badge {
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    background: #fef3c7;
    color: #78350f;
    border: 1px solid #f59e0b;
    font-size: 0.68rem;
    font-weight: 800;
    padding: 1px 8px;
    border-radius: 999px;
    margin-bottom: 6px;
}

.mrc-podium-score-pill {
    font-variant-numeric: tabular-nums;
    font-weight: 900;
    font-size: 0.85rem;
    padding: 3px 11px;
    border-radius: 999px;
    margin-bottom: 8px;
    white-space: nowrap;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.34);
}

.mrc-podium-slot.is-rank-1 .mrc-podium-score-pill {
    background: #fef08a;
    color: #451a03;
    border: 1px solid #facc15;
    font-size: 0.92rem;
}

.mrc-podium-slot.is-rank-2 .mrc-podium-score-pill {
    background: #f1f5f9;
    color: #0f172a;
    border: 1px solid #cbd5e1;
}

.mrc-podium-slot.is-rank-3 .mrc-podium-score-pill {
    background: #ffedd5;
    color: #431407;
    border: 1px solid #fb923c;
}

.mrc-podium-pedestal {
    position: relative;
    overflow: hidden;
    width: 100%;
    border-radius: 12px 12px 0 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    letter-spacing: 0.06em;
    box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.55);
}

.mrc-pedestal-sheen {
    position: absolute;
    top: 0;
    left: -130%;
    width: 65%;
    height: 100%;
    background: linear-gradient(
        112deg,
        transparent 0%,
        rgba(255, 255, 255, 0.52) 50%,
        transparent 100%
    );
    pointer-events: none;
}

.mrc-results-stage:not(.is-instant-reveal) .mrc-podium-slot.is-revealed .mrc-pedestal-sheen {
    animation: mrcFoilSweep 0.85s ease-out 0.25s 1 forwards;
}

@keyframes mrcFoilSweep {
    0% {
        left: -130%;
    }
    100% {
        left: 160%;
    }
}

.mrc-podium-slot.is-rank-1 .mrc-podium-pedestal {
    height: 78px;
    background: linear-gradient(180deg, #fde047 0%, #f59e0b 55%, #b45309 100%);
    color: #451a03;
    font-size: 1.25rem;
}

.mrc-podium-slot.is-rank-2 .mrc-podium-pedestal {
    height: 56px;
    background: linear-gradient(180deg, #f1f5f9 0%, #cbd5e1 55%, #94a3b8 100%);
    color: #1e293b;
    font-size: 1.05rem;
}

.mrc-podium-slot.is-rank-3 .mrc-podium-pedestal {
    height: 42px;
    background: linear-gradient(180deg, #fdba74 0%, #ea580c 60%, #9a3412 100%);
    color: #fff7ed;
    font-size: 0.98rem;
}

/* ============================================================================
   下部クリーンシート（自分の順位・トップ5リスト）
   ============================================================================ */
.mrc-lower-sheet {
    background: #f8fafc;
    color: #0f172a;
    padding: 18px 20px 20px;
    text-align: left;
}

/* 自分の結果カード */
.mrc-user-card {
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    padding: 16px;
    margin-bottom: 18px;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.06);
    transition: opacity 0.45s cubic-bezier(0.22, 1, 0.36, 1), transform 0.48s cubic-bezier(0.22, 1, 0.36, 1);
}

.mrc-user-card.is-anim-hidden {
    opacity: 0;
    transform: translateY(16px);
}

.mrc-user-card.is-revealed {
    opacity: 1;
    transform: translateY(0);
}

.mrc-card-sheen {
    position: absolute;
    top: 0;
    left: -120%;
    width: 55%;
    height: 100%;
    background: linear-gradient(
        112deg,
        transparent 0%,
        rgba(255, 255, 255, 0.55) 50%,
        transparent 100%
    );
    pointer-events: none;
}

.mrc-results-stage:not(.is-instant-reveal) .mrc-user-card.is-revealed .mrc-card-sheen {
    animation: mrcFoilSweep 0.95s ease-out 0.15s 1 forwards;
}

.mrc-user-card.mrc-tier-gold {
    background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
    border: 2px solid #f59e0b;
}

.mrc-user-card.mrc-tier-silver {
    background: linear-gradient(135deg, #ffffff 0%, #e2e8f0 100%);
    border: 2px solid #94a3b8;
}

.mrc-user-card.mrc-tier-bronze {
    background: linear-gradient(135deg, #fff7ed 0%, #fed7aa 100%);
    border: 2px solid #ea580c;
}

.mrc-user-card.mrc-tier-top5 {
    background: linear-gradient(135deg, #eef2ff 0%, #e0e7ff 100%);
    border: 2px solid #6366f1;
}

.mrc-user-card.mrc-tier-participant {
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
}

.mrc-user-card.mrc-tier-unparticipated {
    background: #f1f5f9;
    border: 1.5px dashed #94a3b8;
}

.mrc-user-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.mrc-user-card-label {
    font-size: 0.8rem;
    font-weight: 800;
    color: #334155;
    letter-spacing: 0.03em;
}

.mrc-user-celebration-pill {
    font-size: 0.78rem;
    font-weight: 800;
    padding: 3px 10px;
    border-radius: 999px;
    background: #0f172a;
    color: #fde047;
}

.mrc-tier-unparticipated .mrc-user-celebration-pill {
    background: #e2e8f0;
    color: #334155;
}

.mrc-metrics-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}

.mrc-metrics-grid.is-two-cols {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.mrc-metric-box {
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(15, 23, 42, 0.1);
    border-radius: 12px;
    padding: 10px 8px;
    text-align: center;
}

.mrc-metric-title {
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    color: #475569;
    margin-bottom: 2px;
}

.mrc-metric-value-wrap {
    color: #0f172a;
    line-height: 1.2;
}

.mrc-metric-value {
    font-size: 1.38rem;
    font-weight: 900;
    color: #0f172a;
    font-variant-numeric: tabular-nums;
}

.mrc-tier-gold .mrc-metric-value.is-rank {
    color: #b45309;
}

.mrc-tier-top5 .mrc-metric-value.is-rank {
    color: #4338ca;
}

.mrc-metric-sub {
    font-size: 0.76rem;
    font-weight: 700;
    color: #475569;
}

.mrc-user-msg {
    margin: 10px 0 0;
    font-size: 0.86rem;
    font-weight: 600;
    color: #1e293b;
    line-height: 1.5;
}

.mrc-gap-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 8px;
    padding: 4px 11px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.08);
    color: #0f172a;
    font-size: 0.78rem;
    font-weight: 700;
}

/* ランキング一覧セクション */
.mrc-lb-header-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 10px;
}

.mrc-lb-section-title {
    margin: 0;
    font-size: 0.98rem;
    font-weight: 800;
    color: #0f172a;
    display: flex;
    align-items: center;
    gap: 7px;
}

.mrc-lb-section-title i {
    color: #d97706;
}

.mrc-participants-pill {
    font-size: 0.76rem;
    font-weight: 700;
    color: #334155;
    background: #e2e8f0;
    padding: 3px 10px;
    border-radius: 999px;
}

.mrc-leaderboard {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.05);
}

.mrc-lb-head {
    background: #1e293b;
    color: #f8fafc;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    padding: 10px 14px;
    display: grid;
    grid-template-columns: 56px 1fr auto;
    gap: 8px;
    align-items: center;
}

.mrc-lb-head-score {
    text-align: right;
}

.mrc-lb-row {
    background: #ffffff;
    color: #0f172a;
    border-bottom: 1px solid #e2e8f0;
    padding: 11px 14px;
    display: grid;
    grid-template-columns: 56px 1fr auto;
    gap: 8px;
    align-items: center;
    transition: opacity 0.35s ease, transform 0.35s ease, background-color 0.25s ease, box-shadow 0.25s ease;
}

.mrc-lb-row:last-child {
    border-bottom: none;
}

.mrc-lb-row.is-anim-hidden {
    opacity: 0;
    transform: translateY(10px);
}

.mrc-lb-row.is-revealed {
    opacity: 1;
    transform: translateY(0);
}

.mrc-lb-row.is-current-user {
    background: #eff6ff;
    border-left: 4px solid #2563eb;
    padding-left: 10px;
}

.mrc-lb-row.is-current-user.is-spotlight-pulse {
    animation: mrcUserRowPulse 0.9s ease-out 1;
}

@keyframes mrcUserRowPulse {
    0% {
        background-color: #dbeafe;
        box-shadow: inset 0 0 0 2px rgba(37, 99, 235, 0.35);
    }
    100% {
        background-color: #eff6ff;
        box-shadow: inset 0 0 0 0 rgba(37, 99, 235, 0);
    }
}

.mrc-lb-row.is-out-of-top5 {
    border-top: 2px dashed #93c5fd;
}

.mrc-lb-divider {
    background: #f8fafc;
    color: #64748b;
    text-align: center;
    font-size: 0.85rem;
    font-weight: 800;
    letter-spacing: 0.25em;
    padding: 4px 0;
    border-bottom: 1px solid #e2e8f0;
}

.mrc-lb-rank-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 28px;
    padding: 0 8px;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
}

.mrc-lb-rank-badge.is-r1 {
    background: #fef08a;
    color: #451a03;
    border: 1px solid #f59e0b;
}

.mrc-lb-rank-badge.is-r2 {
    background: #e2e8f0;
    color: #0f172a;
    border: 1px solid #94a3b8;
}

.mrc-lb-rank-badge.is-r3 {
    background: #ffedd5;
    color: #431407;
    border: 1px solid #fb923c;
}

.mrc-lb-rank-badge.is-other {
    background: #f1f5f9;
    color: #334155;
    border: 1px solid #cbd5e1;
}

.mrc-lb-user-cell {
    min-width: 0;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
}

.mrc-lb-username {
    font-weight: 700;
    font-size: 0.94rem;
    color: #0f172a;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 100%;
}

.mrc-lb-title-pill {
    background: #fef3c7;
    color: #78350f;
    border: 1px solid #fcd34d;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 1px 8px;
    border-radius: 999px;
    max-width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mrc-lb-you-pill {
    background: #2563eb;
    color: #ffffff;
    font-size: 0.68rem;
    font-weight: 800;
    padding: 1px 7px;
    border-radius: 999px;
}

.mrc-lb-score {
    font-weight: 800;
    font-size: 0.96rem;
    color: #0f172a;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
    text-align: right;
}

/* フッター */
.mrc-footer {
    background: #ffffff;
    border-top: 1px solid #e2e8f0;
    padding: 13px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
}

.mrc-replay-btn {
    background: #f1f5f9;
    color: #1e293b;
    border: 1px solid #cbd5e1;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 700;
    padding: 8px 16px;
    cursor: pointer;
    transition: background 0.15s ease;
}

.mrc-replay-btn:hover {
    background: #e2e8f0;
    color: #0f172a;
}

.mrc-confirm-btn {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    color: #ffffff;
    border: none;
    border-radius: 999px;
    font-size: 0.92rem;
    font-weight: 800;
    padding: 9px 24px;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.35);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.mrc-confirm-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(37, 99, 235, 0.45);
}

/* ============================================================================
   レスポンシブ対応 (スマートフォン: <= 576px)
   ============================================================================ */
@media (max-width: 576px) {
    #monthlyResultModal .modal-dialog {
        margin: 0.6rem;
    }

    .mrc-opening-stage {
        min-height: 390px;
        padding: 52px 16px 26px;
    }

    .mrc-opening-period {
        font-size: 1.65rem;
    }

    .mrc-podium-hero {
        padding: 18px 10px 18px;
    }

    .mrc-hero-header {
        padding: 0 42px;
    }

    .mrc-hero-title {
        font-size: 1.1rem;
    }

    .mrc-podium-grid {
        gap: 6px;
        min-height: 188px;
    }

    .mrc-podium-name {
        font-size: 0.8rem;
    }

    .mrc-podium-slot.is-rank-1 .mrc-podium-name {
        font-size: 0.86rem;
    }

    .mrc-podium-score-pill {
        font-size: 0.76rem;
        padding: 2px 8px;
    }

    .mrc-lower-sheet {
        padding: 14px 14px 16px;
    }

    .mrc-metrics-grid {
        gap: 6px;
    }

    .mrc-metric-value {
        font-size: 1.15rem;
    }

    .mrc-lb-head,
    .mrc-lb-row {
        grid-template-columns: 48px 1fr auto;
        padding-left: 10px;
        padding-right: 10px;
    }

    .mrc-lb-row.is-current-user {
        padding-left: 6px;
    }

    .mrc-footer {
        padding: 12px 14px;
    }

    .mrc-replay-btn,
    .mrc-confirm-btn {
        flex: 1 1 auto;
        text-align: center;
    }
}

/* ============================================================================
   アクセシビリティ: モーション軽減設定
   ============================================================================ */
@media (prefers-reduced-motion: reduce) {
    .mrc-spotlight-beam,
    .mrc-bokeh-dot,
    .mrc-crest-ring,
    .mrc-trophy-medallion,
    .mrc-reveal-btn::after,
    .mrc-podium-crown,
    .mrc-champion-ring,
    .mrc-star-glint,
    .mrc-pedestal-sheen,
    .mrc-card-sheen,
    .mrc-cine-transition,
    .mrc-flare-bar,
    .mrc-flare-ring,
    .mrc-lb-row.is-current-user.is-spotlight-pulse {
        animation: none !important;
    }

    .mrc-bokeh-dot {
        display: none !important;
    }

    .mrc-podium-slot,
    .mrc-user-card,
    .mrc-lb-row,
    .mrc-center-spotlight {
        transition: none !important;
    }
}
