<head>
  {% assign file = page.fileName %}
  {% assign lang = page.lang %}
  {% assign dataArr = site.data.[page.folderName][lang][file] %}
  {% assign dataToShow = dataArr %}
  {% assign title = dataToShow.title | replace: "$variable", page.value | default: page.title | default: site.title %}
  {%- assign title = title | split: ' ' -%}
  {%- assign newtitle = '' %}
  {% for operation in title %}
  {%- if forloop.first -%}
  {% assign word = operation | capitalize %}
  {% assign newtitle = newtitle | append: word %}
  {% assign newtitle = newtitle | append: " " %}
  {%- else -%}
  {% assign word = operation %}
  {%- if forloop.last -%}
  {% assign newtitle = newtitle | append: word %}
  {%- else -%}
  {% assign newtitle = newtitle | append: word %}
  {% assign newtitle = newtitle | append : " " %}
  {%- endif -%}
  {%- endif -%}
  {% endfor %}
  {% assign favicon = site.favicon %}

  <meta charset="utf-8" />
  <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" />
  <meta http-equiv="X-UA-Compatible" content="IE=edge" />
  <link rel="shortcut icon" href="{{favicon}}" />

  {%- if page.noindex -%}
  <meta name="robots" content="noindex" />
  {%- endif -%}

  {% assign whitelist_urls = site.data.noindexURLs.internatlionalization_whitelist_urls %}
  {% assign noindex_languages = site.data.noindexURLs.noindex_languages %}
  {% if noindex_languages contains page.lang %}
  {% unless whitelist_urls contains page.url %}
  <meta name="robots" content="noindex" />
  {% endunless %}
  {% endif %}

  {% assign blacklist_urls = site.data.noindexURLs.blacklist_urls %}
  {% if blacklist_urls contains page.url %}
  <meta name="robots" content="noindex" />
  {% endif %}


  <title>{{ newtitle }}</title>

  {% include wordgames/seo/seo.html %}

  <link rel="canonical" href="{{site.url | append:  page.url}}" />

  {%- if site.keyboard -%}
  <meta name="keywords" content="{{site.keyboard}}" />
  {%- endif -%}

  <link rel="stylesheet" href="/assets/css/bootstrap.min.css" />
  <link rel="stylesheet" href="/assets/css/wordgames-variables.css" />
  <link rel="stylesheet" href="/assets/css/wordgames-theme.css" />
  <link rel="stylesheet" href="/assets/css/wordgames-home.css" />


  {%- if site.noResultPage or page.noResultPage -%}
  <link rel="stylesheet" href="/assets/css/wordgames-result.css" />
  {%- endif -%}

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

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

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

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

  {%- if site.internationalizationall -%}
  {%- include alternates/alternates.html -%}
  {%- endif -%}

  {% include /cssfile/links.html %}


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

    .trywordle:hover {
      color: #fff !important;
    }

    @media (max-width: 768px) {
      .trywordle {
        margin-bottom: 2rem;
      }

    }
  </style>
  {%- endif -%}

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

  <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 wordgames/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>