.mr-heatmaps {
    padding: clamp(16px, 3vw, 34px);
    background: #f8faf6;
}

.mr-heat-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px 30px;
    margin-bottom: 22px;
}

.mr-heat-heading h2 {
    margin: 0;
    color: #11362a;
    font-size: clamp(24px, 2.7vw, 34px);
    line-height: 1.1;
}

.mr-heat-heading p {
    max-width: 66ch;
    margin: 8px 0 0;
    color: #50685d;
}

.mr-heat-legend {
    display: grid;
    grid-template-columns: auto auto;
    justify-content: space-between;
    gap: 5px 14px;
    color: #50685d;
    font-size: 12px;
}

.mr-heat-legend i {
    grid-column: 1 / -1;
    width: 100%;
    min-width: 120px;
    height: 7px;
    border-radius: 5px;
    background: linear-gradient(90deg, #135044, #37bfa1 28%, #f1ca42 60%, #f6633c 100%);
}

.mr-heat-legend span:last-child {
    text-align: right;
}

.mr-heat-teams {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(10px, 2vw, 20px);
}

.mr-heat-team {
    min-width: 0;
    overflow: hidden;
    border: 1px solid #31574b;
    border-radius: 16px;
    background: radial-gradient(ellipse at 50% 25%, #153f34, #091f1a 80%);
    color: #f3fff7;
}

.mr-heat-team > header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px clamp(14px, 2vw, 22px);
    border-bottom: 1px solid #9fcdb333;
    background: #163d33a8;
}

.mr-heat-team h3 {
    min-width: 0;
    margin: 0;
    color: #f3fff7;
    font-size: clamp(16px, 2.1vw, 21px);
    line-height: 1.2;
    overflow-wrap: anywhere;
}

.mr-heat-crest {
    display: grid;
    flex: 0 0 38px;
    width: 38px;
    height: 38px;
    place-items: center;
}

.mr-heat-crest .club-mark,
.mr-heat-crest .club-badge {
    width: 34px;
    height: 38px;
    object-fit: contain;
}

.mr-heat-stage {
    display: grid;
    justify-items: center;
    gap: 8px;
    padding: 14px clamp(12px, 3vw, 24px);
}

.mr-heat-attack,
.mr-heat-count,
.mr-heat-empty {
    color: #bdd5cb;
    font-size: 13px;
    text-align: center;
}

.mr-heat-attack span {
    margin-left: 3px;
    color: #cef16c;
}

.mr-heat-count {
    padding: 11px;
    border-top: 1px solid #9fcdb32b;
    background: #0b241edd;
    font-variant-numeric: tabular-nums;
}

.mr-heat-empty {
    margin: 32px 16px;
}

.mr-heat-pitch {
    position: relative;
    isolation: isolate;
    width: min(100%, 310px);
    aspect-ratio: 68 / 105;
    overflow: hidden;
    border: 1px solid #77af8e55;
    border-radius: 10px;
    background: repeating-linear-gradient(0deg, #123f32 0 8.333%, #154735 8.333% 16.666%);
    box-shadow: inset 0 0 34px #05241cb0, 0 8px 24px #04161270;
}

.mr-heat-cells,
.mr-heat-lines {
    position: absolute;
    inset: 5% 6%;
}

.mr-heat-cells {
    display: grid;
    grid-template: repeat(15, 1fr) / repeat(10, 1fr);
    filter: blur(clamp(5px, 0.5vw, 8px));
}

.mr-heat-lines {
    border: 1px solid #e8fff1b0;
}

.mr-heat-lines::before,
.mr-heat-lines::after,
.mr-heat-lines span {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    border: 1px solid #e8fff1b0;
    content: '';
}

.mr-heat-lines::before {
    top: 50%;
    width: 100%;
    border-width: 1px 0 0;
}

.mr-heat-lines::after {
    top: 50%;
    width: 27%;
    aspect-ratio: 1;
    border-radius: 50%;
    transform: translate(-50%, -50%);
}

.mr-heat-box {
    width: 59%;
    height: 15.7%;
}

.mr-heat-goal-area {
    width: 27%;
    height: 5.2%;
}

.mr-heat-lines :is(.mr-heat-box, .mr-heat-goal-area).top {
    top: 0;
    border-top: 0;
}

.mr-heat-lines :is(.mr-heat-box, .mr-heat-goal-area).bottom {
    bottom: 0;
    border-bottom: 0;
}

.mr-heat-lines .mr-heat-spot {
    width: 3px;
    height: 3px;
    border: 0;
    border-radius: 50%;
    background: #e8fff1cc;
    transform: translate(-50%, -50%);
}

.mr-heat-spot.center { top: 50%; }
.mr-heat-spot.top { top: 10.5%; }
.mr-heat-spot.bottom { top: 89.5%; }

@media (max-width: 760px) {
    .mr-heat-teams {
        grid-template-columns: 1fr;
    }
}
