XML 59 R48.htm IDEA: XBRL DOCUMENT
v3.23.2

Revenues and Accounts Receivable - Additional Information (Details) | 3 Months Ended | 6 Months Ended | 12 Months Ended
--- | --- | --- | ---
Jun. 30, 2023 USD ($) Customer | Jun. 30, 2022 Customer | Jun. 30, 2023 USD ($) Customer | Jun. 30, 2022 Customer | Dec. 31, 2022 USD ($)
Accounts Notes And Loans Receivable [Line Items] |  |  |  |  |
Contracts assets acquired through business acquisitions |  |  | $ 2,200,000 |  | $ 1,700,000
Contract liabilities acquired through business acquisitions |  |  | 0 |  | 0
Contract with customer liabilities, revenue recognized | $ 500,000 |  | 13,300,000 |  |
Revenue remaining performance obligations | $ 82,300,000 |  | $ 82,300,000 |  | $ 100,400,000
Customer Concentration Risk | Accounts Receivable | Significant Customer |  |  |  |  |
Accounts Notes And Loans Receivable [Line Items] |  |  |  |  |
Concentration risk percentage |  |  | 10.00% |  | 10.00%
Customer Concentration Risk | Revenue | Significant Customer |  |  |  |  |
Accounts Notes And Loans Receivable [Line Items] |  |  |  |  |
Concentration risk percentage | 12.30% | 16.10% | 10.40% | 16.70% |
Number of customers | Customer | 1 | 1 | 1 | 1 |

X
- Definition Contracts with customer assets acquired through business acquisitions. + References No definition available. + Details
Name: | meg_ContractsWithCustomerAssetsAcquiredThroughBusinessAcquisitions
Namespace Prefix: | meg_
Data Type: | xbrli:monetaryItemType
Balance Type: | debit
Period Type: | duration

X
- Definition Contracts with customer liabilities acquired through business acquisitions. + References No definition available. + Details
Name: | meg_ContractsWithCustomerLiabilitiesAcquiredThroughBusinessAcquisitions
Namespace Prefix: | meg_
Data Type: | xbrli:monetaryItemType
Balance Type: | credit
Period Type: | duration

X
- Definition Number of customers. + References No definition available. + Details
Name: | meg_NumberOfCustomer
Namespace Prefix: | meg_
Data Type: | xbrli:integerItemType
Balance Type: | na
Period Type: | duration

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_AccountsNotesAndLoansReceivableLineItems
Namespace Prefix: | us-gaap_
Data Type: | xbrli:stringItemType
Balance Type: | na
Period Type: | duration

X
- Definition For an entity that discloses a concentration risk in relation to quantitative amount, which serves as the "benchmark" (or denominator) in the equation, this concept represents the concentration percentage derived from the division. + References Reference 1: http://www.xbrl.org/2003/role/disclosureRef -Topic 280 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 42 -Publisher FASB -URI https://asc.fasb.org//1943274/2147482810/280-10-50-42 Reference 2: http://fasb.org/us-gaap/role/ref/legacyRef -Name Accounting Standards Codification -Topic 825 -SubTopic 10 -Section 50 -Paragraph 21 -Subparagraph (a) -Publisher FASB -URI https://asc.fasb.org//1943274/2147482907/825-10-50-21 Reference 3: http://fasb.org/us-gaap/role/ref/legacyRef -Name Accounting Standards Codification -Topic 825 -SubTopic 10 -Section 50 -Paragraph 20 -Publisher FASB -URI https://asc.fasb.org//1943274/2147482907/825-10-50-20 Reference 4: http://fasb.org/us-gaap/role/ref/legacyRef -Name Accounting Standards Codification -Topic 275 -SubTopic 10 -Section 50 -Paragraph 18 -Publisher FASB -URI https://asc.fasb.org//1943274/2147482861/275-10-50-18 Reference 5: http://fasb.org/us-gaap/role/ref/legacyRef -Name Accounting Standards Codification -Topic 275 -SubTopic 10 -Section 50 -Paragraph 20 -Publisher FASB -URI https://asc.fasb.org//1943274/2147482861/275-10-50-20 + Details
Name: | us-gaap_ConcentrationRiskPercentage1
Namespace Prefix: | us-gaap_
Data Type: | dtr-types:percentItemType
Balance Type: | na
Period Type: | duration

X
- Definition Amount of revenue recognized that was previously included in balance of obligation to transfer good or service to customer for which consideration from customer has been received or is due. + References Reference 1: http://www.xbrl.org/2003/role/disclosureRef -Topic 606 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 8 -Subparagraph (b) -Publisher FASB -URI https://asc.fasb.org//1943274/2147479806/606-10-50-8 + Details
Name: | us-gaap_ContractWithCustomerLiabilityRevenueRecognized
Namespace Prefix: | us-gaap_
Data Type: | xbrli:monetaryItemType
Balance Type: | credit
Period Type: | duration

X
- Definition Amount of transaction price allocated to performance obligation that has not been recognized as revenue. + References Reference 1: http://www.xbrl.org/2003/role/disclosureRef -Name Accounting Standards Codification -Section 50 -Paragraph 13 -Subparagraph (a) -SubTopic 10 -Topic 606 -Publisher FASB -URI https://asc.fasb.org//1943274/2147479806/606-10-50-13 + Details
Name: | us-gaap_RevenueRemainingPerformanceObligation
Namespace Prefix: | us-gaap_
Data Type: | xbrli:monetaryItemType
Balance Type: | credit
Period Type: | instant

X
- Details
Name: | us-gaap_ConcentrationRiskByTypeAxis=us-gaap_CustomerConcentrationRiskMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_ConcentrationRiskByBenchmarkAxis=us-gaap_AccountsReceivableMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | srt_MajorCustomersAxis=meg_SignificantCustomerMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_ConcentrationRiskByBenchmarkAxis=us-gaap_RevenueFromContractWithCustomerMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |