{% assign file = page.fileName %}
{% assign lang = page.lang %}
{% assign dataToShow = site.data.[page.folderName][lang][file] %}
{% assign favicon = site.favicon %}

<head>
  <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta charset="utf-8" />

  <link rel="shortcut icon" href="{{favicon}}" />

  {% include seo.html %}
  <link rel="canonical" href="{{site.url | append:  page.url}}">
  {%- if site.keyboard -%}
  <meta name="keywords" content="{{site.keyboard}}" />
  {%- endif -%}

  {%- if site.removeBootstrapIcons !=
  true -%}
  <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-icons/1.10.5/font/bootstrap-icons.min.css" integrity="sha512-ZnR2wlLbSbr8/c9AgLg3jQPAattCUImNsae6NHYnS9KrIwRdcY9DxFotXhNAKIKbAXlRnujIqUWoXXwqyFOeIQ==" crossorigin="anonymous" referrerpolicy="no-referrer" />
  {%- endif -%}

  <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap/4.6.0/css/bootstrap.min.css" integrity="sha512-P5MgMn1jBN01asBgU0z60Qk4QxiXo86+wlFahKrsQf37c9cro517WzVSPPV1tDKzhku2iJ2FVgL67wG03SGnNA==" crossorigin="anonymous" referrerpolicy="no-referrer" />
  <link rel="stylesheet" href="/assets/css/style.css">

  {%- if page.layout == "autogencontent"-%}
  <link rel="stylesheet" href="/assets/css/content.css">
  {%- endif -%}

  {%- if page.layout == 'page' or page.layout == 'page2' -%}
  <link rel="stylesheet" href="/assets/css/wordGroup.css">
  {%- endif -%}

  {%- if page.layout == 'xyzpages' -%}
  <link rel="stylesheet" href="/assets/css/wordGroup.css">
  {%- endif -%}

  {%- if page.wordle == 'solver' -%}
  <style>
    .trywordle {
      color: #fff;
      background-color: #404040;
      padding: 12px 100px;
      border-radius: 50px;
    }

    .trywordle:hover {
      color: #fff !important;
    }
  </style>
  {%- endif -%}

  {%- if site.show_allow_ad_blocker_pop -%}
  <link rel="stylesheet" href="/assets/css/adBlocker.css">
  {%- endif -%}

  <link rel="manifest" href="/manifest.json">

  {% include cssfile/links.html %}

  <title>
    {%- unless page.layout == "home" -%}
    {{dataToShow.title }}
    {%- endunless -%}
    {{ page.title}}</title>


  <script type="application/ld+json">
      {
      "@context": "http://schema.org",
          "@type": "Organization",
          "url": "{{site.siteurl}}",
          "logo": "{{site.siteurl}}{{site.favicon}}" 
        }
  </script>

  <script type="application/ld+json">
      {
      "@context": "http://schema.org",
      "@type": "WebSite",
      "name": "{{site.name}}",
      "alternateName": "{{site.alternateName}}",
      "url": "{{site.siteurl}}"}
  </script>

  {%- if dataToShow.faqList -%}
  {%- if dataToShow.faqList.first.Question !='' -%}
  <script type="application/ld+json">
      {
     "@context": "http://schema.org",
     "@type": "FAQPage",
    "mainEntity": [
         {%- for item in dataToShow.faqList-%}
         {%- if forloop.last == true -%}
         {"@type": "Question",
         "name": "{{item.Question | replace:'"', "'"}}",
         "acceptedAnswer": {
           "@type": "Answer",
           "text": "{{item.Answer | replace:'"', "'"}}"
         }
       }
         {%- else -%}
         {"@type": "Question",
         "name": "{{item.Question | replace:'"', "'"}}",
         "acceptedAnswer": {
           "@type": "Answer",
           "text": "{{item.Answer | replace:'"', "'"}}"
         }
       },
       {%- endif -%}
         {%- endfor -%}
    ]
    }
  </script>
  {%- endif -%}
  {%- endif -%}

  {%- if page.tool -%}
  {%- include Rating/structureddata.html -%}
  {%- endif -%}


  <script>
    if ('serviceWorker' in navigator) {
      window.addEventListener('load', () => {
        navigator.serviceWorker.register('/serviceworker.js')
          .then((reg) => console.log('Success: ', reg.scope))
          .catch((err) => console.log('Failure: ', err));
      })
    }
  </script>
</head>