<%# This is a header template %>

<!doctype html>

<html lang="en" prefix="https://ogp.me/ns#">

<head>
    <%# Site data %>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="Mutorials is a free, adaptive, web-based science trainer powered by a passionate and experienced team of students, with various fun and competitive game modes to enrich your learning!">
    <meta name="keywords" content="get volunteer hours, homework help, USABO, physics, chemestry, biology, exam, quiz, questionnaire, test, questions database, train">

    <meta property="og:title" content="Mutorials">
    <meta property="og:type" content="website">
    <meta property="og:url" content="https://www.mutorials.org/">
    <meta property="og:image" content="https://f000.backblazeb2.com/file/mutorials/icons/Icon_Main.svg">
    <meta property="og:description" content="Mutorials is a free, adaptive, web-based science trainer powered by a passionate and experienced team of students, with various fun and competitive game modes to enrich your learning!">
    <% try { %>
        <%# EJS idiosyncrasies - the JS || operator and ternary operator both crash the page when pageName isn't defined %>
        <%# existenceTest will test whether pageName exists, and will then throw an error %>
        <%# A test is used because otherwise a stray <title> tag appears in the output %>
        <% let existenceTest = pageName; %>
        <title><%= pageName %></title>
        <meta property="og:title" content="<%= pageName %>" />
    <% } catch(err) { %>
        <title>Mutorials</title>
        <meta property="og:title" content="Mutorials" />
    <% } %>
    <meta property="og:type" content="website" />
    <meta property="og:site_name" content="Mutorials" />
    <link rel="icon" href="https://f000.backblazeb2.com/file/mutorials/icons/Icon_Main.svg" sizes="any" type="image/svg+xml">
    <meta property="og:image" content="https://f000.backblazeb2.com/file/mutorials/icons/Icon_Main.svg" />
    <meta property="og:image" content="Mutorials logo" />

    <%# Google site verification %>
    <meta name="google-site-verification" content="oGS_dGA0Nb7-aoAzQ9DrvXYjhMHzOdOLGkRZvlEjwGc" />

    <%# JQuery import %>
    <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>

    <%# Bootstrap import %>
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.0-beta2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-BmbxuPwQa2lc/FVzBcNJ7UAyJxM6wuqIj61tLrc4wSX0szH/Ev+nYRRuWlolflfl" crossorigin="anonymous">
    <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.0-beta2/dist/js/bootstrap.bundle.min.js" integrity="sha384-b5kHyXgcpbZJO/tY9Ul7kGkf1S0CWuKcCD38l8YkeH8z8QjE0GmW1gYU5S9FOnJ0" crossorigin="anonymous"></script>

    <%# Fontawesome import %>
    <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
    <script src="https://kit.fontawesome.com/63ec6f8c9f.js" crossorigin="anonymous"></script>

    <%# Mathjax import %>
    <script src="https://polyfill.io/v3/polyfill.min.js?features=es6"></script>
    <script id="MathJax-script" async src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script>
    <script>
        window.MathJax = {
            tex: {
                inlineMath: [['$', '$'], ['$$', '$$']]
            }
        };
    </script>

    <%# Chartjs import %>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.9.3/Chart.min.js"></script>
    <script>
        var canvascontainerlist = document.getElementsByClassName("canvas-container-center");
        for (i = 0; i < canvascontainerlist.length; i++) {
            var parentStyle = canvascontainerlist[i].style;
            parentStyle.textAlign = "center";
            parentStyle.width = "100%";
        }
    </script>

    <%# typed.js import %>
    <script src="https://cdn.jsdelivr.net/npm/typed.js@2.0.11"></script>

    <%# animate.css import %>
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/animate.css/4.1.1/animate.min.css"/>

    <%# Animate On Scroll import %>
    <link href="https://unpkg.com/aos@2.3.1/dist/aos.css" rel="stylesheet">
    <script src="https://unpkg.com/aos@2.3.1/dist/aos.js"></script>

    <%# Custom CSS for site %>
    <style>
        .jumbotron {
            padding: 2rem 2rem;
            margin-bottom: 2rem;
            background-color: #e9ecef;
            border-radius: .5rem
        }

        .form-group {
            margin-bottom:1rem;
        }

        .card {
            margin-top: 50px;
        }

        .carousel-inner > .item > img { width:90%; height:570px; }

        .icon-bar {
            position: absolute;
            top: 40%;
            -webkit-transform: translateY(-50%);
            -ms-transform: translateY(-50%);
            transform: translateY(-50%);
            z-index: 5;
        }
        .icon-bar a {
            display: block;
            text-align: center;
            padding: 16px;
            transition: all 0.3s ease;
            color: white;
            font-size: 20px;
        }
        .icon-bar a:hover {
            background-color: #000;
        }

        input[type=number]::-webkit-outer-spin-button, input[type=number]::-webkit-inner-spin-button {
            -webkit-appearance: none;
            margin: 0;
        }

        input[type=number] {
            -moz-appearance:textfield;
        }
        .facebook {
            background: #3B5998;
            color: white;
        }
        .twitter {
            background: #55ACEE;
            color: white;
        }
        .google {
            background: #dd4b39;
            color: white;
        }
        .linkedin {
            background: #007bb5;
            color: white;
        }
        /* Facebook to linkedin aren't used as of rn*/
        .instagram {
            background: #bc2a8d;
            color: white;
        }
        .discord {
            background:#7289DA;
            color: white;
        }
        .youtube {
            background: #bb0000;
            color: white;
        }
        .github {
            background:#696969;
            color: white;
        }

        .crop {
            height: 286px;
            width: 286px;
            overflow: hidden;
        }

        .mu-rounded {
            border-radius: 10%
        }

        tr th:first-child, tr td:first-child {
            -moz-border-radius-topleft: 15px;
            -moz-border-radius-bottomleft: 15px;
            -webkit-border-top-left-radius: 15px;
            -webkit-border-bottom-left-radius: 15px;
        }

        tr td:last-child, tr th:last-child {
            -moz-border-radius-topright: 15px;
            -moz-border-radius-bottomright: 15px;
            -webkit-border-top-right-radius: 15px;
            -webkit-border-bottom-right-radius: 15px;
        }

        .icon-bar a:first-child {
            -moz-border-radius-topright: 15px;
            -webkit-border-top-right-radius: 15px;
        }

        .icon-bar a:last-child {
            -moz-border-radius-bottomright: 15px;
            -webkit-border-bottom-right-radius: 15px;
        }

        .search-result {
            -moz-border-radius-topleft: 15px;
            -moz-border-radius-bottomleft: 15px;
            -webkit-border-top-left-radius: 15px;
            -webkit-border-bottom-left-radius: 15px;
            -moz-border-radius-topright: 15px;
            -moz-border-radius-bottomright: 15px;
            -webkit-border-top-right-radius: 15px;
            -webkit-border-bottom-right-radius: 15px;
        }

        .nav-link, .navbar-brand {
            color: #FFFFFF !important;
            opacity: 1 !important;
        }

        .nav-link:hover {
            color: #FFFFFF !important;
            opacity: 0.75 !important;
        }

        html, body {
            max-width: 100%;
            overflow-x: hidden;
        }

        .bg-main {
            background-color: #fff;
        }
        .bg-alternate {
            background-color: #e9ecef;
        }

        .btn-primary {
            color: #ffffff;
            background-color: #37B2DB;
            border-color: #39ADD4;
        }

        .btn-primary:hover,
        .btn-primary:focus,
        .btn-primary:active,
        .btn-primary.active,
        .open .dropdown-toggle.btn-primary {
            color: #ffffff;
            background-color: #42A9CC;
            border-color: #39ADD4;
        }

        .btn-primary:active,
        .btn-primary.active,
        .open .dropdown-toggle.btn-primary {
            background-image: none;
        }

        .btn-primary.disabled,
        .btn-primary[disabled],
        fieldset[disabled] .btn-primary,
        .btn-primary.disabled:hover,
        .btn-primary[disabled]:hover,
        fieldset[disabled] .btn-primary:hover,
        .btn-primary.disabled:focus,
        .btn-primary[disabled]:focus,
        fieldset[disabled] .btn-primary:focus,
        .btn-primary.disabled:active,
        .btn-primary[disabled]:active,
        fieldset[disabled] .btn-primary:active,
        .btn-primary.disabled.active,
        .btn-primary[disabled].active,
        fieldset[disabled] .btn-primary.active {
            background-color: #37B2DB;
            border-color: #39ADD4;
        }

        .btn-primary .badge {
            color: #37B2DB;
            background-color: #ffffff;
        }

        .ms-options-wrap {
            position: relative;
        }

        .ms-options-wrap,
        .ms-options-wrap * {
            box-sizing: border-box;
        }

        .ms-options-wrap > button:focus,
        .ms-options-wrap > button {
            position: relative;
            width: 100%;
            text-align: left;
            border: 1px solid #ced4da;
            background-color: #fff;
            padding: 6px 20px 6px 12px;
            margin-top: 8px;
            font-size: 15px;
            color: #6c757d;
            outline-offset: -2px;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .ms-options-wrap > button[disabled] {
            background-color: #e5e9ed;
            color: #808080;
            opacity: 0.6;
        }

        .ms-options-wrap > button:after {
            content: ' ';
            height: 0;
            position: absolute;
            top: 50%;
            right: 5px;
            width: 0;
            border: 6px solid rgba(0, 0, 0, 0);
            border-top-color: #999;
            margin-top: -3px;
        }

        .ms-options-wrap.ms-has-selections > button {
            color: #333;
        }

        .ms-options-wrap > .ms-options {
            position: absolute;
            left: 0;
            width: 100%;
            margin-top: 1px;
            margin-bottom: 20px;
            background: white;
            z-index: 2000;
            border: 1px solid #ced4da;
            overflow: auto;
            visibility: hidden;
        }

        .ms-options-wrap.ms-active > .ms-options {
            visibility: visible
        }

        .ms-options-wrap > .ms-options > .ms-search input {
            width: 100%;
            padding: 4px 5px;
            border: none;
            border-bottom: 1px groove;
            outline: none;
        }

        .ms-options-wrap > .ms-options > .no-result-message {
            padding: 4px 5px;
            display: none;
        }

        .ms-options-wrap > .ms-options .ms-selectall {
            display: inline-block;
            font-size: .9em;
            text-transform: lowercase;
            text-decoration: none;
        }
        .ms-options-wrap > .ms-options .ms-selectall:hover {
            text-decoration: underline;
        }

        .ms-options-wrap > .ms-options > .ms-selectall.global {
            margin: 4px 5px;
        }

        .ms-options-wrap > .ms-options > ul,
        .ms-options-wrap > .ms-options > ul > li.optgroup ul {
            list-style-type: none;
            padding: 0;
            margin: 0;
        }

        .ms-options-wrap > .ms-options > ul li.ms-hidden {
            display: none;
        }

        .ms-options-wrap > .ms-options > ul > li.optgroup {
            padding: 5px;
        }
        .ms-options-wrap > .ms-options > ul > li.optgroup + li.optgroup {
            border-top: 1px solid #ced4da;
        }

        .ms-options-wrap > .ms-options > ul > li.optgroup .label {
            display: block;
            padding: 5px 0 0 0;
            font-weight: bold;
        }

        .ms-options-wrap > .ms-options > ul label {
            position: relative;
            display: inline-block;
            width: 100%;
            padding: 4px 4px 4px 20px;
            margin: 1px 0;
            border: 1px dotted transparent;
        }
        .ms-options-wrap > .ms-options.checkbox-autofit > ul label,
        .ms-options-wrap > .ms-options.hide-checkbox > ul label {
            padding: 4px;
        }

        .ms-options-wrap > .ms-options > ul label.focused,
        .ms-options-wrap > .ms-options > ul label:hover {
            background-color: #d0d0d0;
            border-color: #999;
        }

        .ms-options-wrap > .ms-options > ul li.selected label {
            background-color: #d0d0d0;
            border-color: transparent;
        }

        .ms-options-wrap > .ms-options > ul input[type="checkbox"] {
            margin: 0 5px 0 0;
            position: absolute;
            left: 4px;
            top: 7px;
        }

        .ms-options-wrap > .ms-options.hide-checkbox > ul input[type="checkbox"] {
            position: absolute !important;
            height: 1px;
            width: 1px;
            overflow: hidden;
            clip: rect(1px 1px 1px 1px);
            clip: rect(1px, 1px, 1px, 1px);
        }
		
        <% if (locals.darkMode) { %>

		    .ms-options-wrap > button:focus,
            .ms-options-wrap > button {
                background-color: #414449;
            }

            .ms-options-wrap > .ms-options {
                background-color: #414449;
            }

			.ms-options-wrap > .ms-options > ul label.focused,
            .ms-options-wrap > .ms-options > ul label:hover {
                background-color: #34363a;
            }
			
			.ms-options-wrap > .ms-options > ul li.selected label {
                background-color: #34363a;
                border-color: transparent;
            }

			.ms-options-wrap > .ms-options > .ms-search input {
                background-color: #414449;		  
			}
			
			.ms-options-wrap > .ms-options > .ms-search input::placeholder {
                color: #6c757d;		  
			}
			
			.ms-options-wrap.ms-has-selections > button {
                color: white;
            }
			
            .ms-options-wrap > .ms-options > .ms-search input {
                color: white
            }
			
            body, .bg-main {
                background-color: #37393f;
            }

            .progress {
                background-color: #414449;
            }

            .jumbotron {
                background-color: #414449;
            }

            .bg-alternate {
                background-color: #414449;
            }

            .card-body, .card-header {
                background-color: #37393f;
            }

            .form-control {
                background-color: #414449 !important;
                color: #ffffff !important;
            }
        .modal-header, .modal-body, .modal-footer {
                background-color: #37393f;
            }
        .dropdown-menu {
                background-color: #222222;
            }
        .dropdown-item {
                color: #ffffff;
            }

            .dropdown-item:hover {
                background-color: #333333;
                color: #ffffff;
            }

            * :not(.ms-options-wrap *) {
                color: #ffffff;
            }
        <% } %>
    </style>
    <% if (locals.darkMode) { %>
    <script>
        Chart.defaults.global.defaultFontColor = "#ffffff";
    </script>
    <% } %>

    <!-- Global site tag (gtag.js) - Google Analytics -->
    <script async src="https://www.googletagmanager.com/gtag/js?id=UA-187785187-1">
    </script>

    <script>
        window.dataLayer = window.dataLayer || [];
        function gtag(){dataLayer.push(arguments);}
        gtag('js', new Date());

        gtag('config', 'UA-187785187-1');
    </script>

    <!-- Global site tag (gtag.js) - Google Ads: 454194095 -->
    <script async src="https://www.googletagmanager.com/gtag/js?id=AW-454194095"></script>
    <script>
        window.dataLayer = window.dataLayer || [];
        function gtag(){dataLayer.push(arguments);}
        gtag('js', new Date());

        gtag('config', 'AW-454194095');
    </script>

    <!-- Event snippet for Sign-up conversion page
    In your html page, add the snippet and call gtag_report_conversion when someone clicks on the chosen link or button. -->
    <script>
        function gtag_report_conversion(url) {
        var callback = function () {
            if (typeof(url) != 'undefined') {
            window.location = url;
            }
        };
        gtag('event', 'conversion', {
            'send_to': 'AW-454194095/lj2QCNuiookCEK_nydgB',
            'event_callback': callback
        });
        return false;
        }
    </script>
    

</head>

<body>
