XML 75 R60.htm IDEA: XBRL DOCUMENT
v3.22.0.1

Intangible Assets - Gross Carrying Amount and Accumulated Amortization (Details) - USD ($) $ in Thousands | 12 Months Ended |
--- | --- | ---
Dec. 31, 2021 | Dec. 31, 2020
Finite-Lived Intangible Assets [Line Items] |  |
Gross Amount | $ 187,571 | $ 217,380
Accumulated Amortization | (128,190) | (119,944)
Impairment |  | (28,794)
Net Carrying Amount | 59,381 | 68,642
Customer relationships |  |
Finite-Lived Intangible Assets [Line Items] |  |
Gross Amount | 112,109 | 116,101
Accumulated Amortization | (80,319) | (75,649)
Impairment |  | (2,206)
Net Carrying Amount | $ 31,790 | 38,246
Customer relationships | Minimum |  |
Finite-Lived Intangible Assets [Line Items] |  |
Useful Life (Years) | 5 years |
Customer relationships | Maximum |  |
Finite-Lived Intangible Assets [Line Items] |  |
Useful Life (Years) | 18 years |
Software/Technology |  |
Finite-Lived Intangible Assets [Line Items] |  |
Useful Life (Years) | 3 years |
Gross Amount | $ 52,265 | 77,326
Accumulated Amortization | (26,415) | (23,519)
Impairment |  | (25,874)
Net Carrying Amount | $ 25,850 | 27,933
Software/Technology | Minimum |  |
Finite-Lived Intangible Assets [Line Items] |  |
Useful Life (Years) | 3 years |
Software/Technology | Maximum |  |
Finite-Lived Intangible Assets [Line Items] |  |
Useful Life (Years) | 15 years |
Covenants not to compete |  |
Finite-Lived Intangible Assets [Line Items] |  |
Gross Amount | $ 12,623 | 12,833
Accumulated Amortization | (12,390) | (12,162)
Impairment |  | (212)
Net Carrying Amount | $ 233 | 459
Covenants not to compete | Minimum |  |
Finite-Lived Intangible Assets [Line Items] |  |
Useful Life (Years) | 2 years |
Covenants not to compete | Maximum |  |
Finite-Lived Intangible Assets [Line Items] |  |
Useful Life (Years) | 5 years |
Other |  |
Finite-Lived Intangible Assets [Line Items] |  |
Gross Amount | $ 10,574 | 11,120
Accumulated Amortization | (9,066) | (8,614)
Impairment |  | (502)
Net Carrying Amount | $ 1,508 | $ 2,004
Other | Minimum |  |
Finite-Lived Intangible Assets [Line Items] |  |
Useful Life (Years) | 2 years |
Other | Maximum |  |
Finite-Lived Intangible Assets [Line Items] |  |
Useful Life (Years) | 12 years |

X
- Definition Finite-Lived Intangible Assets, Accumulated Impairment + References No definition available. + Details
Name: | mg_FiniteLivedIntangibleAssetsAccumulatedImpairment
Namespace Prefix: | mg_
Data Type: | xbrli:monetaryItemType
Balance Type: | credit
Period Type: | instant

X
- Definition Useful life of finite-lived intangible assets, in 'PnYnMnDTnHnMnS' format, for example, 'P1Y5M13D' represents the reported fact of one year, five months, and thirteen days. + References No definition available. + Details
Name: | us-gaap_FiniteLivedIntangibleAssetUsefulLife
Namespace Prefix: | us-gaap_
Data Type: | xbrli:durationItemType
Balance Type: | na
Period Type: | duration

X
- Definition Accumulated amount of amortization of assets, excluding financial assets and goodwill, lacking physical substance with a finite life. + References Reference 1: http://www.xbrl.org/2003/role/disclosureRef -Publisher FASB -Name Accounting Standards Codification -Topic 350 -SubTopic 30 -Section 50 -Paragraph 2 -Subparagraph (a)(1) -URI http://asc.fasb.org/extlink&oid=66006027&loc=d3e16323-109275 + Details
Name: | us-gaap_FiniteLivedIntangibleAssetsAccumulatedAmortization
Namespace Prefix: | us-gaap_
Data Type: | xbrli:monetaryItemType
Balance Type: | credit
Period Type: | instant

X
- Definition Amount before amortization of assets, excluding financial assets and goodwill, lacking physical substance with a finite life. + References Reference 1: http://www.xbrl.org/2003/role/disclosureRef -Publisher FASB -Name Accounting Standards Codification -Topic 928 -SubTopic 340 -Section 50 -Paragraph 1 -URI http://asc.fasb.org/extlink&oid=6473545&loc=d3e61844-108004 Reference 2: http://fasb.org/us-gaap/role/ref/legacyRef -Publisher FASB -Name Accounting Standards Codification -Topic 350 -SubTopic 30 -Section 50 -Paragraph 2 -Subparagraph (a)(1) -URI http://asc.fasb.org/extlink&oid=66006027&loc=d3e16323-109275 + Details
Name: | us-gaap_FiniteLivedIntangibleAssetsGross
Namespace Prefix: | us-gaap_
Data Type: | xbrli:monetaryItemType
Balance Type: | debit
Period Type: | instant

X
- Definition Line items represent financial concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes to the table. + References No definition available. + Details
Name: | us-gaap_FiniteLivedIntangibleAssetsLineItems
Namespace Prefix: | us-gaap_
Data Type: | xbrli:stringItemType
Balance Type: | na
Period Type: | duration

X
- Definition Sum of the carrying amounts of all intangible assets, excluding goodwill, as of the balance sheet date, net of accumulated amortization and impairment charges. + References Reference 1: http://fasb.org/us-gaap/role/ref/legacyRef -Publisher FASB -Name Accounting Standards Codification -Topic 350 -SubTopic 30 -Section 50 -Paragraph 2 -Subparagraph ((a)(1),(b)) -URI http://asc.fasb.org/extlink&oid=66006027&loc=d3e16323-109275 Reference 2: http://fasb.org/us-gaap/role/ref/legacyRef -Publisher FASB -Name Accounting Standards Codification -Topic 350 -SubTopic 30 -Section 45 -Paragraph 1 -URI http://asc.fasb.org/extlink&oid=6388964&loc=d3e16212-109274 + Details
Name: | us-gaap_IntangibleAssetsNetExcludingGoodwill
Namespace Prefix: | us-gaap_
Data Type: | xbrli:monetaryItemType
Balance Type: | debit
Period Type: | instant

X
- Details
Name: | us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis=us-gaap_CustomerRelationshipsMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | srt_RangeAxis=srt_MinimumMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | srt_RangeAxis=srt_MaximumMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis=us-gaap_ComputerSoftwareIntangibleAssetMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis=us-gaap_NoncompeteAgreementsMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_FiniteLivedIntangibleAssetsByMajorClassAxis=us-gaap_OtherIntangibleAssetsMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |