<?xml version="1.0" encoding="utf-8"?>
<xbrl
  xmlns="http://www.xbrl.org/2003/instance"
  xmlns:dei="http://xbrl.sec.gov/dei/2024"
  xmlns:ffd="http://xbrl.sec.gov/ffd/2024"
  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/2024/ffd-2024.xsd"
      xlink:type="simple"/>
    <context id="rc">
        <entity>
            <identifier scheme="http://www.sec.gov/CIK">0001682472</identifier>
        </entity>
        <period>
            <startDate>2025-11-19</startDate>
            <endDate>2025-11-19</endDate>
        </period>
    </context>
    <unit id="USD">
        <measure>iso4217:USD</measure>
    </unit>
    <unit id="pure">
        <measure>pure</measure>
    </unit>
    <unit id="Shares">
        <measure>shares</measure>
    </unit>
    <ffd:FormTp contextRef="rc" id="ixv-36">S-3</ffd:FormTp>
    <ffd:SubmissnTp contextRef="rc" id="ixv-37">424B2</ffd:SubmissnTp>
    <ffd:FeeExhibitTp contextRef="rc" id="ixv-38">EX-FILING FEES</ffd:FeeExhibitTp>
    <ffd:RegnFileNb contextRef="rc" id="ixv-39">333-268718-01</ffd:RegnFileNb>
    <dei:EntityCentralIndexKey contextRef="rc" id="ixv-40">0001682472</dei:EntityCentralIndexKey>
    <dei:EntityRegistrantName contextRef="rc" id="ixv-41">BofA Finance LLC</dei:EntityRegistrantName>
    <ffd:NrrtvDsclsr contextRef="rc" id="ixv-61">&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;"&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;"&gt;5,000,000.00&lt;/span&gt;&lt;span style="color:#000000;white-space:pre-wrap;font-size:12pt;font-family:Times New Roman;"&gt;.&lt;/span&gt;&lt;/p&gt;</ffd:NrrtvDsclsr>
    <ffd:NrrtvMaxAggtOfferingPric contextRef="rc" decimals="INF" id="ixv-59" unitRef="USD">5000000.00</ffd:NrrtvMaxAggtOfferingPric>
</xbrl>
