<?xml version="1.0" encoding="utf-8"?>
<xbrl
  xmlns="http://www.xbrl.org/2003/instance"
  xmlns:dei="http://xbrl.sec.gov/dei/2025"
  xmlns:ffd="http://xbrl.sec.gov/ffd/2025"
  xmlns:iso4217="http://www.xbrl.org/2003/iso4217"
  xmlns:link="http://www.xbrl.org/2003/linkbase"
  xmlns:xlink="http://www.w3.org/1999/xlink">
    <link:schemaRef
      xlink:href="https://xbrl.sec.gov/ffd/2025/ffd-2025.xsd"
      xlink:type="simple"/>
    <context id="C_3005aaae-834c-4817-a768-2212ba043bd0">
        <entity>
            <identifier scheme="http://www.sec.gov/CIK">0000886982</identifier>
        </entity>
        <period>
            <startDate>2025-07-02</startDate>
            <endDate>2025-07-02</endDate>
        </period>
    </context>
    <unit id="U_USD">
        <measure>iso4217:USD</measure>
    </unit>
    <dei:EntityRegistrantName
      contextRef="C_3005aaae-834c-4817-a768-2212ba043bd0"
      id="F_64816e19-68c2-4080-af54-4ea6c0de87dd">The Goldman Sachs Group, Inc.</dei:EntityRegistrantName>
    <ffd:RegnFileNb
      contextRef="C_3005aaae-834c-4817-a768-2212ba043bd0"
      id="F_84b70ecd-f08c-4ebf-bcda-8668c5b6cdab">333-284538</ffd:RegnFileNb>
    <ffd:SubmissnTp
      contextRef="C_3005aaae-834c-4817-a768-2212ba043bd0"
      id="F_ea928879-ffaf-461c-9cd9-5a8d4580be2e">424B2</ffd:SubmissnTp>
    <ffd:FormTp
      contextRef="C_3005aaae-834c-4817-a768-2212ba043bd0"
      id="F_86791395-5f3b-4e4b-9116-7eb9d3086de9">S-3</ffd:FormTp>
    <ffd:FeeExhibitTp
      contextRef="C_3005aaae-834c-4817-a768-2212ba043bd0"
      id="F_c3dd9b3e-45b6-47ff-935b-3c8d7e0e0f68">EX-FILING FEES</ffd:FeeExhibitTp>
    <dei:EntityCentralIndexKey
      contextRef="C_3005aaae-834c-4817-a768-2212ba043bd0"
      id="F_a6d7474b-df2c-4915-b030-2ce79f792fa4">0000886982</dei:EntityCentralIndexKey>
    <ffd:NrrtvDsclsr
      contextRef="C_3005aaae-834c-4817-a768-2212ba043bd0"
      id="F_b11b7ce0-2c8b-48d1-b2cd-1f0f135633f6">&lt;p style="font-size:10pt;margin-top:0;font-family:Times New Roman;margin-bottom:12pt;text-align:left;"&gt;&lt;span style="color:#000000;white-space:pre-wrap;font-size:12pt;font-family:Times New Roman;font-kerning:none;min-width:fit-content;"&gt;The prospectus to which this Exhibit is attached is a final prospectus for the related offering.  The maximum aggregate offering price for such offering is $&lt;/span&gt;&lt;span style="font-size:12pt;font-family:Times New Roman;color:#000000;white-space:pre-wrap;font-kerning:none;min-width:fit-content;"&gt;541,000&lt;/span&gt;&lt;span style="color:#000000;white-space:pre-wrap;font-size:12pt;font-family:Times New Roman;font-kerning:none;min-width:fit-content;"&gt;.&lt;/span&gt;&lt;/p&gt;</ffd:NrrtvDsclsr>
    <ffd:NrrtvMaxAggtOfferingPric
      contextRef="C_3005aaae-834c-4817-a768-2212ba043bd0"
      decimals="0"
      id="F_8bb264af-0cf9-4048-a605-f02ba70d7d15"
      unitRef="U_USD">541000</ffd:NrrtvMaxAggtOfferingPric>
</xbrl>
