/**
 * Long labels / ledger reasons — fit column width (all menus).
 */
.r2go-text-fit {
    box-sizing: border-box;
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
    overflow-wrap: anywhere;
    word-break: keep-all;
    line-height: 1.45;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 4;
}

.r2go-ledger-reason-block {
    display: grid;
    gap: 2px;
    min-width: 0;
    max-width: 100%;
}

.r2go-ledger-reason-head {
    display: block;
    line-height: 1.45;
    min-width: 0;
}

.r2go-ledger-reason-tail {
    display: block;
    min-width: 0;
    max-width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: inherit;
    line-height: 1.45;
}

.r2go-ledger-reason {
    white-space: pre-line;
    min-width: 0;
    max-width: 100%;
}

table td.r2go-text-fit,
table td .r2go-ledger-reason-block,
table th.r2go-text-fit {
    max-width: min(100%, 20rem);
    vertical-align: top;
}

.r2go-ref__table td.r2go-text-fit,
.r2go-ref__table td .r2go-ledger-reason-block {
    max-width: min(100%, 14rem);
}

.r2go-pts__detail .r2go-ledger-reason-block {
    width: 100%;
}

.r2go-match__title.r2go-text-fit,
.r2go-asub__note.r2go-text-fit {
    margin: 0;
    -webkit-line-clamp: 3;
}

@media (max-width: 480px) {
    table td.r2go-text-fit,
    table td .r2go-ledger-reason-block {
        max-width: min(100%, 100%);
    }
}
