/* ---------------------------
試合速報ボックス
--------------------------- */
.match_report {
    width: auto;
    border-radius: 4px;
    box-shadow: 1px 2px 4px 0px #ddd;
    position: relative;
    overflow: hidden;
    min-width: 280px;
    background-color: var(--reverse-color);
    display: flex;
    flex-direction: column;
    transition: .3s;
}

.video_icon {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    width: 1.25rem;
    height: 1.25rem;
    background-color: var(--alert-color);
    border: 1px solid var(--site-white-color);
    border-radius: 50%;
    z-index: 1;
    opacity: 0.9;
    display: flex;
    align-items: center;
    justify-content: center;
}

.video_icon > img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.match_report:hover {
    cursor: pointer;
    opacity: 0.8;
}

.match_report:active {
    box-shadow: none;
    transform: translateY(2px);
}

.match_img_block {
    width: 100%;
    height: 0;
    padding-top: 56.25%;
    background-color: #F6F6F6;
    overflow: hidden;
    position: relative;
}


.match_img_block img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: .3s;
    position: absolute;
    top: 0;
    left: 0;
}

.match_img_block:has(> :nth-child(2)) img {
    width: 50%;
}

.match_img_block:has(> :nth-child(2)) img:last-child {
    left: 50%;
}

.match_report:hover > .match_img_block img {
    -webkit-transform: scale(1.05);
    transform: scale(1.05);
}

.match_tag {
    padding: 2px 8px;
    background-color: #fab534;
    position: absolute;
    top: 0;
    left: 8px;
    transform: translateY(-50%);
    font-size: 10px;
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
    max-width: 80%;
    color: var(--reverse-color);
}

@media screen and (max-width: 640px) {
    .match_tag {
        left: 16px;
    }
}

.match_info {
    width: 100%;
    padding: 24px 16px 20px;
    background-color: var(--reverse-color);
    display: flex;
    align-items: center;
    gap: 16px;
    flex: 1;
    position: relative;
}

.score_block {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.score_team {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
}

.score_team .team_info {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
}

.score_team .team_info .emblem {
    width: 20px;
    height: 20px;
}

.score_team .team_info .emblem img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.score_team .team_info .match_team_name {
    font-size: 0.9rem;
    flex: 1;
    text-align: left;
    flex-grow: 1;
}

.score_team .score {
    font-size: 14px;
    color: var(--text-color);
}

.date_info {
    padding: 4px 0 4px 14px;
    border-left: 1px solid #ddd;
}

.date_info p {
    font-size: 12px;
    color: var(--gray-text-color);
}

@media screen and (max-width: 640px) {
    .match_info {
        padding: 24px 24px 20px;
        gap: 24px;
    }

    .date_info {
        padding: 4px 0 4px 22px;
    }
}

.report_link {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    text-indent: 100%;
    white-space: nowrap;
    overflow: hidden;
}

/* ---------------------------
   .match_report_wrapper--grid（試合カード一覧をグリッド表示する modifier）
   デフォルトの .match_report_wrapper（index.css）は display:flex / overflow-x:scroll の
   横スクロール仕様。home トップなどはそのまま使う。
   front/convention/top のような全件表示が望ましいページではこの modifier を
   付けることで、PC 3 カラム / タブレット 2 カラム / SP 1 カラムの全表示にする。
--------------------------- */
.match_report_wrapper.match_report_wrapper--grid {
    width: 100%;
    display: grid;
    /* minmax(0, 1fr) でカード側 min-width(280px) を無視して横はみ出しを防ぐ */
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    padding: 0 4px 1rem;
    /* index.css の overflow-x: scroll を打ち消す */
    overflow-x: visible;
}

/* カード内 min-width を解除して PC でも全幅収まるようにする */
.match_report_wrapper.match_report_wrapper--grid .match_report {
    min-width: 0;
}

@media screen and (max-width: 820px) {
    .match_report_wrapper.match_report_wrapper--grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media screen and (max-width: 640px) {
    .match_report_wrapper.match_report_wrapper--grid {
        grid-template-columns: 1fr;
    }
}
