<%
  // In case we're displaying the 404 or 500 page and relevant code in the "custom" hook was not able to run,
  // we make sure certain view locals exist that are commonly used in this layout.ejs file.  This ensures we
  // don't have to do `typeof` checks below.
  var me;
  var isHomepage;
%><!DOCTYPE html>
<html>
  <head>
    <title>Fleet for osquery | Open source device management</title>

    <% /* Viewport tag for sensible mobile support */ %>
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">

    <% /* Script tags should normally be included further down the page- but any
    scripts that load fonts (e.g. Fontawesome ≥v5) are special exceptions to the
    rule. (Include them up here along with any hard-coded «link» tags for Typekit,
    Google Fonts, etc. - above the «body» to prevent the page flickering when fonts
    load.) */ %>
    <link href="https://fonts.googleapis.com/css2?family=Nunito+Sans:wght@300;400;500;600;700;800;900&family=Nunito:wght@300;400;500;600;700;800;900&display=swap&Source+Code+Pro&display=swap" rel="stylesheet">

    <% /* Certain scripts, normally analytics tools like Google Tag Manager and
    Google Analytics, should only be included in production: */
    if (sails.config.environment === 'production') { %>
    <% /* Google Analytics, Google Tag Manager, etc. */ %>
    <!-- Global site tag (gtag.js) - Google Analytics -->
    <script async src="https://www.googletagmanager.com/gtag/js?id=G-JC3DRNY1GV"></script>
    <script>window.dataLayer = window.dataLayer || []; function gtag(){dataLayer.push(arguments);} gtag('js', new Date()); gtag('config', 'G-JC3DRNY1GV');</script>
    <% }
    /* Otherwise, any such scripts are excluded, and we instead inject a
    robots/noindex meta tag to help prevent any unwanted visits from search engines. */
    else { %>
    <meta name="robots" content="noindex">
    <% } %>

    <% /*
        Stylesheets
        ========================

        Stylesheets can be hard-coded as «link» tags, automatically injected
        by the asset pipeline between "STYLES" and "STYLES END", or both.
        (https://sailsjs.com/docs/concepts/assets/task-automation)
    */ %>

    <% /* Auto-injected «link» tags: */ %>
    <!--STYLES-->
    <link rel="stylesheet" href="/dependencies/bootstrap-4/bootstrap-4.css">
    <link rel="stylesheet" href="/dependencies/fontawesome.css">
    <link rel="stylesheet" href="/styles/importer.css">
    <!--STYLES END-->
  </head>
  <body>
    <div purpose="page-wrap">
      <div style="max-width: 1200px; height: 94px;" class="<%= isHomepage ? 'homepage-header' : 'header' %> container-fluid d-flex justify-content-between align-items-center pt-3 pb-3 px-3" purpose="page-header">
        <a href="/">
          <% /* The homepage-header on the homepage has a white fleet logo */ %>
          <% if (isHomepage) { %>
          <img alt="Fleet logo" src="/images/logo-white-118x48@2x.png" style="width: 118px; height: 48px;"/>
          <% } else { %>
          <img alt="Fleet logo" src="/images/logo-blue-162x92@2x.png" style="height: 92px; width: 162px;"/>
          <% } %>
        </a>
        <div class="d-flex d-lg-none">
          <button style="font-size: 16px; text-decoration: none;" class="header-btn btn btn-link d-flex align-items-center" data-toggle="collapse" data-target="#navbarToggleExternalContent">
            <span class="mr-2">Menu</span>
            <% /* The hamburger icon on the homepage is white */ %>
            <% if (isHomepage) { %>
            <img alt="An icon indicating that interacting with this button will open the navigation menu." src="/images/icon-hamburger-16x14@2x.png" style="width: 16px;" />
            <% } else { %>
            <img alt="An icon indicating that interacting with this button will open the navigation menu." src="/images/icon-hamburger-blue-16x14@2x.png" style="width: 16px;" />
            <% } %>
          </button>
          <div class="mobile-menu collapse px-4 px-sm-5" id="navbarToggleExternalContent">
            <div class="d-flex justify-content-between">
              <a href="/">
                <img alt="Fleet logo" src="/images/logo-blue-162x92@2x.png" style="height: 92px; width: 162px;" class="mt-3"/>
              </a>
              <button style="font-size: 16px; text-decoration: none;" class="header-btn btn btn-link d-flex align-items-center" data-toggle="collapse" data-target="#navbarToggleExternalContent">
                <img alt="An 'X' icon indicating that this can be interacted with to close the navigation menu." src="/images/icon-close-16x16@2x.png" style="width: 16px;" />
              </button>
            </div>
            <div class="pt-2">
              <div class="d-flex flex-column mb-4">
                <span style="font-weight: 700;" class="py-2 px-3">Get started</span>
                <a class="mobile-menu-item py-2 px-3" target="_blank" href="/install" data-text="Try Fleet">Try Fleet</a>
                <a class="mobile-menu-item py-2 px-3" target="_blank" href="/documentation" data-text="Documentation">Documentation</a>
                <a class="mobile-menu-item py-2 px-3" target="_blank" href="/contribute" data-text="Contribute">Contribute</a>
                <a class="mobile-menu-item py-2 px-3" target="_blank" href="/hall-of-fame" data-text="Hall of fame">Hall of fame</a>
              </div>
              <a href="/queries" class="menu-link d-flex align-items-center px-3 py-2 mb-4 text-decoration-none" style=" text-decoration: none; font-weight: 700;">Queries</a>
              <a href="/pricing" class="menu-link d-flex align-items-center px-3 py-2 mb-4 text-decoration-none" style=" text-decoration: none; font-weight: 700;">Pricing</a>
              <a href="/blog" class="menu-link d-flex align-items-center px-3 py-2 mb-4 text-decoration-none" style=" text-decoration: none; font-weight: 700;">Blog</a>
              <!-- <a href="/company/contact" class="menu-link d-flex align-items-center px-3 py-2 mb-4 text-decoration-none" style=" text-decoration: none; color: #192147; font-weight: 700;">Contact</a> -->
              <a target="_blank" href="https://github.com/fleetdm/fleet" class="menu-link d-flex align-items-center px-3 py-2" style=" text-decoration: none; font-weight: 700;">
                <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
                  <path fill-rule="evenodd" clip-rule="evenodd" d="M11.9633 0.5C5.3578 0.5 0 5.8578 0 12.4633C0 17.7477 3.44954 22.2248 8.14679 23.8394C8.73394 23.9128 8.95413 23.5459 8.95413 23.2523C8.95413 22.9587 8.95413 22.2248 8.95413 21.1972C5.65138 21.9312 4.91743 19.5826 4.91743 19.5826C4.40367 18.1881 3.59633 17.8211 3.59633 17.8211C2.49541 17.0872 3.66972 17.0872 3.66972 17.0872C4.84404 17.1606 5.50459 18.3349 5.50459 18.3349C6.6055 20.1697 8.29358 19.656 8.95413 19.3624C9.02752 18.555 9.3945 18.0413 9.68807 17.7477C7.04587 17.4541 4.25688 16.4266 4.25688 11.8028C4.25688 10.4817 4.69725 9.45413 5.50459 8.57339C5.43119 8.35321 4.99083 7.1055 5.65138 5.49083C5.65138 5.49083 6.6789 5.19725 8.95413 6.73853C9.90826 6.44495 10.9358 6.37156 11.9633 6.37156C12.9908 6.37156 14.0183 6.51835 14.9725 6.73853C17.2477 5.19725 18.2752 5.49083 18.2752 5.49083C18.9358 7.1055 18.4954 8.35321 18.422 8.64679C19.156 9.45413 19.6697 10.555 19.6697 11.8761C19.6697 16.5 16.8807 17.4541 14.2385 17.7477C14.6789 18.1147 15.0459 18.8486 15.0459 19.9495C15.0459 21.5642 15.0459 22.8119 15.0459 23.2523C15.0459 23.5459 15.2661 23.9128 15.8532 23.8394C20.6239 22.2248 24 17.7477 24 12.4633C23.9266 5.8578 18.5688 0.5 11.9633 0.5Z" fill="#192147"/>
                </svg>
                <span class="ml-2">GitHub</span>
              </a>
            </div>
          </div>
        </div>
        <div class="d-none d-lg-flex">
          <div class="dropdown px-3 py-2 mr-4">
            <button style="font-size: 16px; line-height: 23px; text-decoration: none;" class="header-btn btn btn-link p-0 m-0 dropdown-label" type="button" id="dropdownMenuButton">
              Get started
            </button>
            <div style="border-radius: 8px;" class="dropdown-menu dropdown-container p-2" aria-labelledby="dropdownMenuButton">
              <a style="border-radius: 4px;" class="dropdown-item py-2 px-3" target="_blank" href="/install" data-text="Try Fleet">Try Fleet</a>
              <a style="border-radius: 4px;" class="dropdown-item py-2 px-3" target="_blank" href="/documentation" data-text="Documentation">Documentation</a>
              <a style="border-radius: 4px;" class="dropdown-item py-2 px-3" target="_blank" href="/contribute" data-text="Contribute">Contribute</a>
              <a style="border-radius: 4px;" class="dropdown-item py-2 px-3" target="_blank" href="/hall-of-fame" data-text="Hall of fame">Hall of fame</a>
            </div>
          </div>
          <a href="/queries" class="header-link d-flex align-items-center px-3 py-2 mr-4 text-decoration-none" style=" text-decoration: none;line-height: 23px;">Queries</a>
          <a href="/pricing" class="header-link d-flex align-items-center px-3 py-2 mr-4 text-decoration-none" style=" text-decoration: none;line-height: 23px;">Pricing</a>
          <a target="_blank" href="/blog" class="header-link d-flex align-items-center px-3 py-2 mr-4 text-decoration-none" style=" text-decoration: none;line-height: 23px;">Blog</a>
          <!-- <a href="/company/contact" class="header-link d-flex align-items-center px-3 py-2 mr-4 text-decoration-none" style=" text-decoration: none;line-height: 23px;">Contact</a> -->
          <a target="_blank" href="https://github.com/fleetdm/fleet" class="header-link d-flex align-items-center px-3 py-2" style=" text-decoration: none;line-height: 23px;">
            <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
              <path fill-rule="evenodd" clip-rule="evenodd" d="M11.9633 0.5C5.3578 0.5 0 5.8578 0 12.4633C0 17.7477 3.44954 22.2248 8.14679 23.8394C8.73394 23.9128 8.95413 23.5459 8.95413 23.2523C8.95413 22.9587 8.95413 22.2248 8.95413 21.1972C5.65138 21.9312 4.91743 19.5826 4.91743 19.5826C4.40367 18.1881 3.59633 17.8211 3.59633 17.8211C2.49541 17.0872 3.66972 17.0872 3.66972 17.0872C4.84404 17.1606 5.50459 18.3349 5.50459 18.3349C6.6055 20.1697 8.29358 19.656 8.95413 19.3624C9.02752 18.555 9.3945 18.0413 9.68807 17.7477C7.04587 17.4541 4.25688 16.4266 4.25688 11.8028C4.25688 10.4817 4.69725 9.45413 5.50459 8.57339C5.43119 8.35321 4.99083 7.1055 5.65138 5.49083C5.65138 5.49083 6.6789 5.19725 8.95413 6.73853C9.90826 6.44495 10.9358 6.37156 11.9633 6.37156C12.9908 6.37156 14.0183 6.51835 14.9725 6.73853C17.2477 5.19725 18.2752 5.49083 18.2752 5.49083C18.9358 7.1055 18.4954 8.35321 18.422 8.64679C19.156 9.45413 19.6697 10.555 19.6697 11.8761C19.6697 16.5 16.8807 17.4541 14.2385 17.7477C14.6789 18.1147 15.0459 18.8486 15.0459 19.9495C15.0459 21.5642 15.0459 22.8119 15.0459 23.2523C15.0459 23.5459 15.2661 23.9128 15.8532 23.8394C20.6239 22.2248 24 17.7477 24 12.4633C23.9266 5.8578 18.5688 0.5 11.9633 0.5Z" fill="#192147"/>
            </svg>
            <span style="line-height: 24px;" class="ml-2 mr-4">GitHub</span>
          </a>
          <span class="header-link d-flex align-items-center text-decoration-none">
            <iframe src="//ghbtns.com/github-btn.html?user=fleetdm&amp;repo=fleet&amp;type=watch&amp;count=true"
            allowtransparency="true" frameborder="0" scrolling="0" width="100" height="20"></iframe>
          </span>
        </div>
      </div>

      <%- body %>

      <div style="background-color: #201E43;" purpose="page-footer">
        <div style="background-color: #201E43;">
          <div style="max-width: 1200px;" class="container-fluid d-flex flex-column flex-lg-row justify-content-center justify-content-lg-between px-3 pt-4 pb-0 mt-md-5 mb-lg-5">
          <div class="d-flex flex-grow-1 flex-column align-items-center">
            <div class="container-fluid d-block d-md-flex flex-md-row text-center justify-content-between justify-content-lg-end px-5 px-lg-0 pt-lg-3 pb-4 pb-md-0">
              <a href="https://github.com/fleetdm/fleet/blob/main/README.md" class="d-block pr-lg-4 pb-4">Try Fleet</a>
              <a href="https://github.com/fleetdm/fleet/tree/main/docs" class="d-block pr-lg-4 pb-4">Documentation</a>
              <a href="/pricing" class="d-block pr-lg-4 pb-4">Pricing</a>
              <a href="https://github.com/fleetdm/fleet/tree/main/docs/3-Contributing" class="d-block pr-lg-4 pb-4">Contribute</a>
              <a href="https://medium.com/fleetdm" class="d-block pr-lg-4 pb-4">Blog</a>
              <a href="https://github.com/fleetdm/fleet/pulse" class="d-block pb-4">Hall of fame</a>
            </div>
    
            <div class="container-fluid d-flex flex-column flex-md-row font-weight-bold justify-content-center justify-content-lg-end px-0 pt-3 pt-md-0">
              <a href="https://twitter.com/fleetctl" class="d-flex flex-shrink-1 justify-content-center align-items-center px-0 pb-4 pb-lg-0">
                <img alt="Twitter logo" src="/images/logo-twitter-32x26@2x.png" style="height: 25px; width: auto;" class="mr-3"/>
                Follow us on Twitter
              </a>
              <a href="https://osquery.slack.com/join/shared_invite/zt-h29zm0gk-s2DBtGUTW4CFel0f0IjTEw#/" class="d-flex flex-nowrap justify-content-center align-items-center px-1 px-sm-5 pb-4 pb-lg-0">
                <img alt="Slack logo" src="/images/logo-slack-28x28@2x.png" style="height: 25px; width: auto" class="mr-3"/>
                <span>Join the community<span purpose="join-the-community-on-slack-expanded-text"> on Slack</span></span>
              </a>
              <a href="https://github.com/fleetdm/fleet" class="d-flex flex-shrink-1 justify-content-center align-items-center px-0 pb-4 pb-lg-0">
                <img alt="GitHub logo" src="/images/github-mark-white-24x24@2x.png" style="height: 25px; width: auto" class="mr-3"/>
                GitHub
              </a>
            </div>  
          </div>
          <div class="d-flex flex-column order-lg-first">
            <div class="d-none d-lg-flex">
              <a href="/">
                <img alt="Fleet logo" src="/images/logo-white-118x48@2x.png" style="width: 118px; height: 48px;"/>
              </a>  
            </div>    
            <div style="font-family: 'Lato', sans-serif; font-size: 13px;" class="d-flex flex-column justify-content-center justify-content-lg-start pt-5 pb-5 pt-md-4">
              <div class="text-center text-lg-left">
                <span>&copy; 2021 Fleet Device Management Inc.</span>
              </div>
            </div>
          </div>
          </div>
        </div>
      </div>
    </div>


    <% /*
      Client-side JavaScript
      ========================

      Scripts can be hard-coded as «script» tags, automatically injected
      by the asset pipeline between "SCRIPTS" and "SCRIPTS END", or both.
      (https://sailsjs.com/docs/concepts/assets/task-automation)
    */ %>

    <% /* Chat (Papercups) */ %>
    <script>window.Papercups = { config: { accountId: '5b59eeac-1578-4fdb-b946-e17c1dca0c51', requireEmailUpfront: true } };</script>
    <script type="text/javascript" async defer src="https://app.papercups.io/widget.js"></script>
    <script type="text/javascript" async defer src="https://app.papercups.io/storytime.js"></script>

    <%/* Stripe.js */%>
    <script src="https://js.stripe.com/v3/"></script>

    <% /* Delete the global `self` to help avoid client-side bugs.
    (see https://developer.mozilla.org/en-US/docs/Web/API/Window/self) */ %>
    <script>delete window.self;</script>

    <%/* bowser.js (for browser detection) -- included inline to avoid issues with minification that could affect the unsupported browser overlay */%>
    <script>!function(e,i,s){if("undefined"!=typeof module&&module.exports)module.exports=s();else if("function"==typeof define&&define.amd)define(i,s);else e[i]=s()}(this,"bowser",function(){var e=true;function i(i){function s(e){var s=i.match(e);return s&&s.length>1&&s[1]||""}function o(e){var s=i.match(e);return s&&s.length>1&&s[2]||""}var r=s(/(ipod|iphone|ipad)/i).toLowerCase(),n=/like android/i.test(i),t=!n&&/android/i.test(i),a=/nexus\s*[0-6]\s*/i.test(i),d=!a&&/nexus\s*[0-9]+/i.test(i),l=/CrOS/.test(i),f=/silk/i.test(i),m=/sailfish/i.test(i),v=/tizen/i.test(i),p=/(web|hpw)os/i.test(i),c=/windows phone/i.test(i),u=/SamsungBrowser/i.test(i),h=!c&&/windows/i.test(i),w=!r&&!f&&/macintosh/i.test(i),b=!t&&!m&&!v&&!p&&/linux/i.test(i),g=o(/edg([ea]|ios)\/(\d+(\.\d+)?)/i),k=s(/version\/(\d+(\.\d+)?)/i),x=/tablet/i.test(i)&&!/tablet pc/i.test(i),y=!x&&/[^-]mobi/i.test(i),S=/xbox/i.test(i),B;if(/opera/i.test(i))B={name:"Opera",opera:e,version:k||s(/(?:opera|opr|opios)[\s\/](\d+(\.\d+)?)/i)};else if(/opr\/|opios/i.test(i))B={name:"Opera",opera:e,version:s(/(?:opr|opios)[\s\/](\d+(\.\d+)?)/i)||k};else if(/SamsungBrowser/i.test(i))B={name:"Samsung Internet for Android",samsungBrowser:e,version:k||s(/(?:SamsungBrowser)[\s\/](\d+(\.\d+)?)/i)};else if(/coast/i.test(i))B={name:"Opera Coast",coast:e,version:k||s(/(?:coast)[\s\/](\d+(\.\d+)?)/i)};else if(/yabrowser/i.test(i))B={name:"Yandex Browser",yandexbrowser:e,version:k||s(/(?:yabrowser)[\s\/](\d+(\.\d+)?)/i)};else if(/ucbrowser/i.test(i))B={name:"UC Browser",ucbrowser:e,version:s(/(?:ucbrowser)[\s\/](\d+(?:\.\d+)+)/i)};else if(/mxios/i.test(i))B={name:"Maxthon",maxthon:e,version:s(/(?:mxios)[\s\/](\d+(?:\.\d+)+)/i)};else if(/epiphany/i.test(i))B={name:"Epiphany",epiphany:e,version:s(/(?:epiphany)[\s\/](\d+(?:\.\d+)+)/i)};else if(/puffin/i.test(i))B={name:"Puffin",puffin:e,version:s(/(?:puffin)[\s\/](\d+(?:\.\d+)?)/i)};else if(/sleipnir/i.test(i))B={name:"Sleipnir",sleipnir:e,version:s(/(?:sleipnir)[\s\/](\d+(?:\.\d+)+)/i)};else if(/k-meleon/i.test(i))B={name:"K-Meleon",kMeleon:e,version:s(/(?:k-meleon)[\s\/](\d+(?:\.\d+)+)/i)};else if(c){B={name:"Windows Phone",osname:"Windows Phone",windowsphone:e};if(g){B.msedge=e;B.version=g}else{B.msie=e;B.version=s(/iemobile\/(\d+(\.\d+)?)/i)}}else if(/msie|trident/i.test(i))B={name:"Internet Explorer",msie:e,version:s(/(?:msie |rv:)(\d+(\.\d+)?)/i)};else if(l)B={name:"Chrome",osname:"Chrome OS",chromeos:e,chromeBook:e,chrome:e,version:s(/(?:chrome|crios|crmo)\/(\d+(\.\d+)?)/i)};else if(/edg([ea]|ios)/i.test(i))B={name:"Microsoft Edge",msedge:e,version:g};else if(/vivaldi/i.test(i))B={name:"Vivaldi",vivaldi:e,version:s(/vivaldi\/(\d+(\.\d+)?)/i)||k};else if(m)B={name:"Sailfish",osname:"Sailfish OS",sailfish:e,version:s(/sailfish\s?browser\/(\d+(\.\d+)?)/i)};else if(/seamonkey\//i.test(i))B={name:"SeaMonkey",seamonkey:e,version:s(/seamonkey\/(\d+(\.\d+)?)/i)};else if(/firefox|iceweasel|fxios/i.test(i)){B={name:"Firefox",firefox:e,version:s(/(?:firefox|iceweasel|fxios)[ \/](\d+(\.\d+)?)/i)};if(/\((mobile|tablet);[^\)]*rv:[\d\.]+\)/i.test(i)){B.firefoxos=e;B.osname="Firefox OS"}}else if(f)B={name:"Amazon Silk",silk:e,version:s(/silk\/(\d+(\.\d+)?)/i)};else if(/phantom/i.test(i))B={name:"PhantomJS",phantom:e,version:s(/phantomjs\/(\d+(\.\d+)?)/i)};else if(/slimerjs/i.test(i))B={name:"SlimerJS",slimer:e,version:s(/slimerjs\/(\d+(\.\d+)?)/i)};else if(/blackberry|\bbb\d+/i.test(i)||/rim\stablet/i.test(i))B={name:"BlackBerry",osname:"BlackBerry OS",blackberry:e,version:k||s(/blackberry[\d]+\/(\d+(\.\d+)?)/i)};else if(p){B={name:"WebOS",osname:"WebOS",webos:e,version:k||s(/w(?:eb)?osbrowser\/(\d+(\.\d+)?)/i)};/touchpad\//i.test(i)&&(B.touchpad=e)}else if(/bada/i.test(i))B={name:"Bada",osname:"Bada",bada:e,version:s(/dolfin\/(\d+(\.\d+)?)/i)};else if(v)B={name:"Tizen",osname:"Tizen",tizen:e,version:s(/(?:tizen\s?)?browser\/(\d+(\.\d+)?)/i)||k};else if(/qupzilla/i.test(i))B={name:"QupZilla",qupzilla:e,version:s(/(?:qupzilla)[\s\/](\d+(?:\.\d+)+)/i)||k};else if(/chromium/i.test(i))B={name:"Chromium",chromium:e,version:s(/(?:chromium)[\s\/](\d+(?:\.\d+)?)/i)||k};else if(/chrome|crios|crmo/i.test(i))B={name:"Chrome",chrome:e,version:s(/(?:chrome|crios|crmo)\/(\d+(\.\d+)?)/i)};else if(t)B={name:"Android",version:k};else if(/safari|applewebkit/i.test(i)){B={name:"Safari",safari:e};if(k)B.version=k}else if(r){B={name:"iphone"==r?"iPhone":"ipad"==r?"iPad":"iPod"};if(k)B.version=k}else if(/googlebot/i.test(i))B={name:"Googlebot",googlebot:e,version:s(/googlebot\/(\d+(\.\d+))/i)||k};else B={name:s(/^(.*)\/(.*) /),version:o(/^(.*)\/(.*) /)};if(!B.msedge&&/(apple)?webkit/i.test(i)){if(/(apple)?webkit\/537\.36/i.test(i)){B.name=B.name||"Blink";B.blink=e}else{B.name=B.name||"Webkit";B.webkit=e}if(!B.version&&k)B.version=k}else if(!B.opera&&/gecko\//i.test(i)){B.name=B.name||"Gecko";B.gecko=e;B.version=B.version||s(/gecko\/(\d+(\.\d+)?)/i)}if(!B.windowsphone&&(t||B.silk)){B.android=e;B.osname="Android"}else if(!B.windowsphone&&r){B[r]=e;B.ios=e;B.osname="iOS"}else if(w){B.mac=e;B.osname="macOS"}else if(S){B.xbox=e;B.osname="Xbox"}else if(h){B.windows=e;B.osname="Windows"}else if(b){B.linux=e;B.osname="Linux"}function O(e){switch(e){case"NT":return"NT";case"XP":return"XP";case"NT 5.0":return"2000";case"NT 5.1":return"XP";case"NT 5.2":return"2003";case"NT 6.0":return"Vista";case"NT 6.1":return"7";case"NT 6.2":return"8";case"NT 6.3":return"8.1";case"NT 10.0":return"10";default:return undefined}}var T="";if(B.windows)T=O(s(/Windows ((NT|XP)( \d\d?.\d)?)/i));else if(B.windowsphone)T=s(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i);else if(B.mac){T=s(/Mac OS X (\d+([_\.\s]\d+)*)/i);T=T.replace(/[_\s]/g,".")}else if(r){T=s(/os (\d+([_\s]\d+)*) like mac os x/i);T=T.replace(/[_\s]/g,".")}else if(t)T=s(/android[ \/-](\d+(\.\d+)*)/i);else if(B.webos)T=s(/(?:web|hpw)os\/(\d+(\.\d+)*)/i);else if(B.blackberry)T=s(/rim\stablet\sos\s(\d+(\.\d+)*)/i);else if(B.bada)T=s(/bada\/(\d+(\.\d+)*)/i);else if(B.tizen)T=s(/tizen[\/\s](\d+(\.\d+)*)/i);if(T)B.osversion=T;var P=!B.windows&&T.split(".")[0];if(x||d||"ipad"==r||t&&(3==P||P>=4&&!y)||B.silk)B.tablet=e;else if(y||"iphone"==r||"ipod"==r||t||a||B.blackberry||B.webos||B.bada)B.mobile=e;if(B.msedge||B.msie&&B.version>=10||B.yandexbrowser&&B.version>=15||B.vivaldi&&B.version>=1||B.chrome&&B.version>=20||B.samsungBrowser&&B.version>=4||B.firefox&&B.version>=20||B.safari&&B.version>=6||B.opera&&B.version>=10||B.ios&&B.osversion&&B.osversion.split(".")[0]>=6||B.blackberry&&B.version>=10.1||B.chromium&&B.version>=20)B.a=e;else if(B.msie&&B.version<10||B.chrome&&B.version<20||B.firefox&&B.version<20||B.safari&&B.version<6||B.opera&&B.version<10||B.ios&&B.osversion&&B.osversion.split(".")[0]<6||B.chromium&&B.version<20)B.c=e;else B.x=e;return B}var s=i("undefined"!==typeof navigator?navigator.userAgent||"":"");s.test=function(e){for(var i=0;i<e.length;++i){var o=e[i];if("string"===typeof o)if(o in s)return true}return false};function o(e){return e.split(".").length}function r(e,i){var s=[],o;if(Array.prototype.map)return Array.prototype.map.call(e,i);for(o=0;o<e.length;o++)s.push(i(e[o]));return s}function n(e){var i=Math.max(o(e[0]),o(e[1]));var s=r(e,function(e){var s=i-o(e);e+=new Array(s+1).join(".0");return r(e.split("."),function(e){return new Array(20-e.length).join("0")+e}).reverse()});while(--i>=0)if(s[0][i]>s[1][i])return 1;else if(s[0][i]===s[1][i]){if(0===i)return 0}else return-1}function t(e,o,r){var t=s;if("string"===typeof o){r=o;o=void 0}if(void 0===o)o=false;if(r)t=i(r);var a=""+t.version;for(var d in e)if(e.hasOwnProperty(d))if(t[d]){if("string"!==typeof e[d])throw new Error("Browser version in the minVersion map should be a string: "+d+": "+String(e));return n([a,e[d]])<0}return o}function a(e,i,s){return!t(e,i,s)}s.isUnsupportedBrowser=t;s.compareVersions=n;s.check=a;s._detect=i;s.detect=i;return s});</script>

    <% /* Auto-injected «script» tags: */ %>
    <!--SCRIPTS-->
    <script src="/dependencies/sails.io.js"></script>
    <script src="/dependencies/lodash.js"></script>
    <script src="/dependencies/jquery.min.js"></script>
    <script src="/dependencies/vue.js"></script>
    <script src="/dependencies/vue-router.js"></script>
    <script src="/dependencies/bootstrap-4/bootstrap-4.bundle.js"></script>
    <script src="/dependencies/cloud.js"></script>
    <script src="/dependencies/moment.js"></script>
    <script src="/dependencies/parasails.js"></script>
    <script src="/js/cloud.setup.js"></script>
    <script src="/js/components/ajax-button.component.js"></script>
    <script src="/js/components/ajax-form.component.js"></script>
    <script src="/js/components/cloud-error.component.js"></script>
    <script src="/js/components/js-timestamp.component.js"></script>
    <script src="/js/components/modal.component.js"></script>
    <script src="/js/components/stripe-card-element.component.js"></script>
    <script src="/js/utilities/open-stripe-checkout.js"></script>
    <script src="/js/pages/498.page.js"></script>
    <script src="/js/pages/account/account-overview.page.js"></script>
    <script src="/js/pages/account/edit-password.page.js"></script>
    <script src="/js/pages/account/edit-profile.page.js"></script>
    <script src="/js/pages/contact.page.js"></script>
    <script src="/js/pages/dashboard/welcome.page.js"></script>
    <script src="/js/pages/docs/basic-documentation.page.js"></script>
    <script src="/js/pages/entrance/confirmed-email.page.js"></script>
    <script src="/js/pages/entrance/forgot-password.page.js"></script>
    <script src="/js/pages/entrance/login.page.js"></script>
    <script src="/js/pages/entrance/new-password.page.js"></script>
    <script src="/js/pages/entrance/signup.page.js"></script>
    <script src="/js/pages/faq.page.js"></script>
    <script src="/js/pages/handbook/basic-handbook.page.js"></script>
    <script src="/js/pages/homepage.page.js"></script>
    <script src="/js/pages/legal/privacy.page.js"></script>
    <script src="/js/pages/legal/terms.page.js"></script>
    <script src="/js/pages/pricing.page.js"></script>
    <script src="/js/pages/query-detail.page.js"></script>
    <script src="/js/pages/query-library.page.js"></script>
    <!--SCRIPTS END-->

    <% /* Display an overlay if the current browser is not supported.
    (Relies on `bowser`, which is loaded inline above.) */ %>
    <script>
    (function(){
      if (typeof bowser !== 'undefined') {
        // --------------------------------------------------------------------
        // Additional compatibility tips:
        //
        // • The browser/OS compatibility below is determined by the needs of Vue.js and Bootstrap.js.
        // • All browsers on Windows XP are probably unsupported (because of compatibility issues with modern SSL certs)
        // • See https://getbootstrap.com/docs/4.0/getting-started/browsers-devices/
        // • See also https://github.com/vuejs/vue/tree/0e5306658ad7b83c553a6a3eeedb15f9066ab063#browser-compatibility
        // • For more info, see:
        //    - https://github.com/lancedikson/bowser/blob/1fb99ced0e8834fd9662604bad7e0f0c3eba2786/test/test.js#L110-L123
        //    - https://github.com/lancedikson/bowser/tree/1fb99ced0e8834fd9662604bad7e0f0c3eba2786#rendering-engine-flags
        // --------------------------------------------------------------------
        var LATEST_SUPPORTED_VERSION_BY_OS = {
          iOS: '10',//« earliest version to eliminate rare bug where `window.location` doesn't exist momentarily after doing a server-side redirect
          Android: '6'
        };
        var LATEST_SUPPORTED_VERSION_BY_USER_AGENT = {
          msedge: '16',
          msie: '11',
          safari: '10',//« earliest version to eliminate rare bug where `window.location` doesn't exist momentarily after doing a server-side redirect
          firefox: '28',//« earliest version to support both ES5 (for Vue.js) and unprefixed flexbox (for Bootstrap 4)
          chrome: '29',//« earliest version to support both ES5 (for Vue.js) and unprefixed flexbox (for Bootstrap 4)
          opera: '17',//« earliest version to support both ES5 (for Vue.js) and unprefixed flexbox (for Bootstrap 4)
        };
        var LATEST_SUPPORTED_VERSION_BY_BROWSER_NAME = {
          'microsoft edge': LATEST_SUPPORTED_VERSION_BY_USER_AGENT.msedge,
          'internet explorer': LATEST_SUPPORTED_VERSION_BY_USER_AGENT.msie,
          'safari': LATEST_SUPPORTED_VERSION_BY_USER_AGENT.safari,
          'firefox': LATEST_SUPPORTED_VERSION_BY_USER_AGENT.firefox,
          'chrome': LATEST_SUPPORTED_VERSION_BY_USER_AGENT.chrome,
          'opera': LATEST_SUPPORTED_VERSION_BY_USER_AGENT.opera
        };
        var isUnsupportedBrowser = (
          bowser.isUnsupportedBrowser(LATEST_SUPPORTED_VERSION_BY_USER_AGENT, window.navigator.userAgent)
        );
        var isUnsupportedOS = (
          LATEST_SUPPORTED_VERSION_BY_OS[bowser.osname] &&
          bowser.compareVersions([bowser.osversion, LATEST_SUPPORTED_VERSION_BY_OS[bowser.osname]]) < 0
        );
        if (isUnsupportedBrowser || isUnsupportedOS) {
          document.body.innerHTML =
          '<div class="container browser-warning-message text-center">'+
          '  <a href="https://sailsjs.com/support">'+
          '<img style="display: block; height: 75px; width: auto; margin: 0 auto 15px;" alt="Logo" src="data:image/png;base64,[encoded data, 23736 characters]"/>'+
          '</a>'+
          '  <h5 class="card-title">This '+(isUnsupportedBrowser ? 'browser' : 'operating system')+' is not supported.</h5>'+
          '  <p style="max-width: 500px; margin-left: auto; margin-right: auto;">'+
          '    This app does not currently support '+(
            isUnsupportedBrowser?
            '<strong>'+bowser.name+'</strong> for versions lower than <strong>v'+ LATEST_SUPPORTED_VERSION_BY_BROWSER_NAME[bowser.name.toLowerCase()]+'</strong>. '+
            'To continue, please upgrade your browser to the newest version, or download the <a href="https://www.google.com/chrome">latest version of Google Chrome</a>.'+
            '  </p>'+
            '  <a class="btn btn-primary" style="padding: 5px 10px" href="https://www.google.com/chrome">Download Chrome</a>'
            :
            '<strong>'+bowser.osname+'</strong> for versions lower than <strong>v'+ LATEST_SUPPORTED_VERSION_BY_OS[bowser.osname]+'</strong>. '+
            'To continue, please use a different device, or <a href="'+(bowser.osname === 'iOS' ? 'https://support.apple.com/en-us/HT204204' : 'https://support.google.com/android/?hl=en#topic=7313011')+'">upgrade this device\'s software</a> to the latest compatible version.'+
            '  </p>'+
            '  <a class="btn btn-primary" style="padding: 5px 10px" href="/contact">Need help?</a>'
          )+
          '</div>';
          document.body.style.padding = '75px 0';
        }
      }
    })();
    </script>

  </body>
</html>
