<?php
// RELEASE v1.2.0
session_start();
// require_once "./Resources/config.php";
// These vars will be grabbed from db eventually to enable faster modifications to the whole site.
// Technically just for experimentation with site design, but could be kept for production build.
// Primary content:
$primaryBG = "#020202"; // Very dark grey (nearly black)
$primaryC = "#ffffff"; // White
// Site stuff:
$siteName = "Dylan JH Buchanan";
$siteHeaderName = "My Work";
$logoSubtext = "Dylan JH Buchanan";
// Other:
$adminURLC = "#f585ff"; // Admin URL color (set to pink)
$navBG = ""; // Nav bar background color (not implemented)
$navC = ""; // Nav bar text color (not implemented)
// For enforcing font usage, made into a variable for things where there isn't a quote left to use. (Stylizing PHP echo things)
$montserrat = "font-family: 'Montserrat', sans-serif !important;";

// Footer content:
$ftBG = "#151515"; // Dark Grey
$ftBG2 = "#101010"; // Darker grey
$ftC = "#ffffff"; // White
$ftC2 = "#fefefe"; // Very light grey
// Footer link extensions
$liEXT = "dylanjhbuchanan"; // LinkedIn extension
$ghEXT = "BehemothNano"; // GitHub extension
?>
<!doctype html>
<html lang="en" dir="ltr">
  <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <?php echo "<title>$siteName - My Work</title>"; ?>
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN" crossorigin="anonymous">
    <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/js/bootstrap.bundle.min.js" integrity="sha384-C6RzsynM9kWDrMNeT87bh95OGNyZPhcTNXj1NW7RuBCsyN/o0jlpcV8Qyq46cDfL" crossorigin="anonymous"></script>
    <link rel="preconnect" href="https://fonts.googleapis.com">
    <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
    <link href="https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100;0,200;0,300;0,400;1,100;1,200;1,300;1,400&display=swap" rel="stylesheet">
    <link href="./Resources/global.css" rel="stylesheet">
    <script defer type="text/javascript" src="./Resources/global.js"></script>
  </head>
  <?php
  echo "
  <body style='background-color: $primaryBG; color: $primaryC; $montserrat font-weight: 200;'>
  ";
  ?>
    <div id="contextOverlay" class="overlay" onclick="overlay('contactOverlay', 0)">
      <div class='d-flex justify-content-center overlayText'>
        <h2 class='ms-4' id='contact' style="font-family: 'Montserrat', sans-serif !important;">Contact Us:</h2>
      </div>
      <div class='wrapper d-flex justify-content-center overlayText'>
        <?php
          echo "
          <form action='./contact.php' method='post' style='$montserrat'>
            <div class='form-group ms-4'>
              <label for='msg'>Message:</label><br />
              <input type='text' name='msg' value=''>
              <br />
              <br />
              <label for='name'>Email:</label><br />
              <input type='text' name='name' value=''>
              ";
          if (isset($_SESSION['userID'])) {
            $authorID = $_SESSION['userID'];
            echo "
              <input type='hidden' name='authorID' value='$authorID'>
            ";
          }
          echo '
            </div>
          </form>
          ';
        ?>
      </div>
    </div>
    <?php
      if (isset($_SESSION["fatal"]) && $_SESSION["fatal"]) {
        if (isset($_SESSION['failureMSG'])) {
          $failureMSG = $_SESSION['failureMSG'];
        } else {
          $failureMSG = "An error occured. Please try again later.";
        }
        echo "
        <div class='alert alert-dismissible fade show' style='background-color: #ff6e7c; color: #96181e; $montserrat' role='alert'>
          $failureMSG
          <button type='button' class='btn-close' data-bs-dismiss='alert' aria-label='Close' style='$montserrat'></button>
        </div>
        <br />
        <br />
        ";
        $_SESSION["fatal"] = false;
        $_SESSION["failureMSG"] = "";
      }
      if (isset($_SESSION["oSuccess"]) && $_SESSION["oSuccess"]) {
        if (isset($_SESSION['successMSG'])) {
          $successMSG = $_SESSION['successMSG'];
        } else {
          $successMSG = "Operation successful.";
        }
        echo "
        <div class='alert alert-dismissible fade show' style='background-color: #abedbb; color: #5cb85c; $montserrat' role='alert'>
          $successMSG
          <button type='button' class='btn-close' data-bs-dismiss='alert' aria-label='Close' style='$montserrat'></button>
        </div>
        <br />
        <br />
        ";
        $_SESSION["oSuccess"] = false;
        $_SESSION["successMSG"] = "";
      }
    ?>
    <div style="text-align: center; font-family: 'Montserrat', sans-serif !important; font-size: 80px; font-weight: 300;">
      <?php
        echo "
        <p class='mtsrt' style='display: inline; $montserrat'>$siteHeaderName</p>
        <p class='mtsrt' style='font-size: 16px !important; $montserrat'>$logoSubtext</p>
        ";
      ?>
    </div>
    <nav class="navbar navbar-expand-lg" style="background-color: #101010; font-family: 'Montserrat', sans-serif !important;">
      <div class="container-fluid">
        <button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
          <span class="navbar-toggler-icon"></span>
        </button>
        <div class="collapse navbar-collapse" id="navbarSupportedContent" style="font-family: 'Montserrat', sans-serif !important;">
          <ul class="navbar-nav me-auto mb-2 mb-lg-0">
            <li class="nav-item">
              <a class="nav-link navbar-brand" style="color: #ffffff;" aria-current="page" href="./home.php">Home</a>
            </li>
            <li class="nav-item">
              <a class="nav-link" style="color: #ffffff;" href="#">My Work</a>
            </li>
            <li class="nav-item">
              <a class="nav-link" style="color: #ffffff;" href="./news.php">News</a>
            </li>
          </ul>
          <li class="nav-item dropstart me-4" style="list-style: none;">
            <a class="nav-link" style="color: #ffffff;" href="#" role="button" data-bs-toggle="dropdown" aria-expanded="false">
              Menu
            </a>
            <ul class="dropdown-menu">
              <li><a class="dropdown-item" onclick="overlay('contactOverlay', 1)" style="font-family: 'Montserrat', sans-serif !important; font-weight: 200 !important;">Contact</a></li>
              <li><a class="dropdown-item" onclick="overlay('supportOverlay', 1)" style="font-family: 'Montserrat', sans-serif !important; font-weight: 200 !important;">Support</a></li>
              <li><a class="dropdown-item" href="./settings.php" style="font-family: 'Montserrat', sans-serif !important; font-weight: 200 !important;">Settings</a></li>
              <li><hr class="dropdown-divider"></li>
              <?php
                if (isset($_SESSION["loggedIn"]) && $_SESSION["loggedIn"]) {
                  if ($_SESSION["scope"] == "admin") {
                    echo "
                    <a class='dropdown-item' style='color:$adminURLC; $montserrat font-weight: 200 !important;' href='./Helpers/edit-announcements.php'>Edit Announcements</a>
                    <a class='dropdown-item' style='color:$adminURLC; $montserrat font-weight: 200 !important;' href='./Helpers/edit-quotes.php'>Edit Projects</a>
                    <div class='dropdown-divider'></div>
                    ";
                  }
                  echo "
                  <li><a class='dropdown-item text-secondary' style='$montserrat font-weight: 200 !important;' href='./reset.php'>Reset Password</a></li>
                  <li><a class='dropdown-item text-danger' style='$montserrat font-weight: 200 !important;' href='./logout.php'>Log Out</a></li>
                  ";
                } else {
                  echo "
                  <li><a class='dropdown-item text-secondary' style='$montserrat font-weight: 200 !important;' href='./login.php'>Log In</a></li>
                  <li><a class='dropdown-item text-primary' style='$montserrat font-weight: 200 !important;' href='./register.php'>Sign Up</a></li>
                  ";
                }
              ?>
            </ul>
          </li>
        </div>
      </div>
    </nav>
    <div class="ms-4 me-4">
      <br />
      <br />
      <br />
      <p class='ms-2 me-2' style='font-size: 42px !important; font-family: "Montserrat", sans-serif !important; font-weight: 300 !important;'>
        Ventus - Consumer <br /> <span class='mt-0' style='font-size: 20px !important; font-family: "Montserrat", sans-serif !important; font-weight: 300 !important;'>July/December 2023 - Present</span>
      </p>
      <p class='ms-2 me-2' style='font-size: 18px !important; font-weight: 100 !important;'>
        Initially started in July of 2023 and later rebuilt from the ground up in December of 2023, Ventus is an aerial security system designed to help keep 
        wildlife preserves protected against poachers. With the core principles of accessibility, ease of use, flexibility, and reliability all while maintaining 
        a low environmental impact with little disruption to animals in the protected region, Ventus is aimed at making environmental protection more feasable in 
        challenging applications. Learn more <a href="./ventus.php">here</a>.
      </p>
      <br />
      <br />
      <p class='ms-2 me-2' style='font-size: 42px !important; font-family: "Montserrat", sans-serif !important; font-weight: 300 !important;'>
        Ventus - Enterprise <br /> <span class='mt-0' style='font-size: 20px !important; font-family: "Montserrat", sans-serif !important; font-weight: 300 !important;'>January 2024 - Present</span>
      </p>
      <p class='ms-2 me-2' style='font-size: 18px !important; font-weight: 100 !important;'>
        Like the original, but with a focus on enterprise applications. Utilizes a robust network of independent drones (agents) to secure a vast 
        region in virtually any conditions. Feel free to contact me to learn more: <a href="mailto:contact@djhbuchanan.com">contact@djhbuchanan.com</a>.
      </p>
      <br />
      <br />
      <p class='ms-2 me-2' style='font-size: 42px !important; font-family: "Montserrat", sans-serif !important; font-weight: 300 !important;'>
        Aerium Games // Project One <br /> <span class='mt-0' style='font-size: 20px !important; font-family: "Montserrat", sans-serif !important; font-weight: 300 !important;'>June 2023 - Present</span>
      </p>
      <p class='ms-2 me-2' style='font-size: 18px !important; font-weight: 100 !important;'>
        After longing for a game that would truly provide the multiplayer experience we desired, a close friend and I teamed up to create a game studio, 
        Aerium Games. We quickly began work on our first project, One (our name for it since it's otherwise currently unnamed), which we hope will set a 
        new standard in the video game industry for privacy, consideration for environmental impact, and continual support for players. You can learn more 
        about it on our website <a href="https://www.aerium.games">here</a>. We're currently aiming for a late 2024/early 2025 release for our first project, 
        and we'll post updates as well as news on future projects in the months ahead.
      </p>
      <br />
      <br />
      <p class='ms-2 me-2' style='font-size: 42px !important; font-family: "Montserrat", sans-serif !important; font-weight: 300 !important;'>
        Lodestone <br /> <span class='mt-0' style='font-size: 20px !important; font-family: "Montserrat", sans-serif !important; font-weight: 300 !important;'>April 2023 - Present</span>
      </p>
      <p class='ms-2 me-2' style='font-size: 18px !important; font-weight: 100 !important;'>
        Lodestone is my approach to a cloud hosting platform. Featuring the tools needed to enable swift, native integration with languages like python to 
        enable users to easily relegate intensive processes within a program, host dependencies, content, and a host of other things, Lodestone aims to be 
        a cloud solution like none other. Lodestone's primary philosophy is that since we have the tools to use remote hosting, why not bring part of the 
        cloud down to the user for easier, faster integration in all sorts of projects. It also exists because I wasn't happy with existing options, so 
        naturally decided to make my own. You can learn more about it <a href="https://www.lodestone.cloud">here</a>. Also, several of my projects are
        built off of Lodestone. (Though that should be fairly obvious, and not to say Lodestone is bad, but the fact that I use it shouldn't be considered 
        another reason to try it since I created it.)
      </p>
      <br />
      <br />
      <p class='ms-2 me-2' style='font-size: 42px !important; font-family: "Montserrat", sans-serif !important; font-weight: 300 !important;'>
        Relativity <br /> <span class='mt-0' style='font-size: 20px !important; font-family: "Montserrat", sans-serif !important; font-weight: 300 !important;'>April 2023 - Present</span>
      </p>
      <p class='ms-2 me-2' style='font-size: 18px !important; font-weight: 100 !important;'>
        Why avoid reinventing the wheel when you could? Relativity is a language I'm developing to create a very flexible python-like language with the 
        performance of the C family. I also understand that I'm a mere 18 year old developer, so this probably sounds quite sketchy/terrible, but I can 
        assure you it's far better than you'd expect. As I finalize some legal things with the project, you can reach out to me 
        <a href="mailto:contact@djhbuchanan.com">here</a> for more information.
      </p>
      <br />
      <br />
      <p class='ms-2 me-2' style='font-size: 42px !important; font-family: "Montserrat", sans-serif !important; font-weight: 300 !important;'>
        Aqueduct <br /> <span class='mt-0' style='font-size: 20px !important; font-family: "Montserrat", sans-serif !important; font-weight: 300 !important;'>September 2023 - Present</span>
      </p>
      <p class='ms-2 me-2' style='font-size: 18px !important; font-weight: 100 !important;'>
        As I continue to go about reinventing virtually everything I see, Aqueduct is a scheduling software aimed at simplifying scheduling tasks such as class 
        assignment for educational instiutes, better automation, and much more, while still providing a easy to use but in-depth user interface, as well as an 
        API that allows for seamless integration into other applications. I'm currently targeting a Q2 2025 1.0 release, with more updates to follow, and a beta 
        in Q4 of 2024. To request a demo or more information, once again you can reach out to me at <a href="mailto:contact@djhbuchanan.com">contact@djhbuchanan.com</a>.
      </p>
      <br />
      <br />
      <p class='ms-2 me-2' style='font-size: 42px !important; font-family: "Montserrat", sans-serif !important; font-weight: 300 !important;'>
        BetterTrain <br /> <span class='mt-0' style='font-size: 20px !important; font-family: "Montserrat", sans-serif !important; font-weight: 300 !important;'>November 2023 - Present</span>
      </p>
      <p class='ms-2 me-2' style='font-size: 18px !important; font-weight: 100 !important;'>
        BetterTrain is a set of ML model training utilities aimed at optimizing model training on your system. BetterTrain utilized a machine learning powered model 
        training scheduler that adapts to your system to accelerate the training process as much as possible. It also lets you play a dungeon crawler while you wait. 
        You can disable the dungeon crawler in the settings. I'm targeting a Q3 2024 beta release with a 1.0 release some time in 2025. Feel free to contact me at 
        <a href="mailto:contact@djhbuchanan.com">contact@djhbuchanan.com</a> for more information.
      </p>
      <br />
      <br />
      <p class='ms-2 me-2' style='font-size: 42px !important; font-family: "Montserrat", sans-serif !important; font-weight: 300 !important;'>
        VTS <br /> <span class='mt-0' style='font-size: 20px !important; font-family: "Montserrat", sans-serif !important; font-weight: 300 !important;'>July 2023 - Present</span>
      </p>
      <p class='ms-2 me-2' style='font-size: 18px !important; font-weight: 100 !important;'>
        VTS is the massive library behind my Ventus projects, and it features several utilities that I found to be really useful for other things too. You can find more 
        information here, or contact me directly at <a href="mailto:contact@djhbuchanan.com">contact@djhbuchanan.com</a>. These are mostly stable, and can be downloaded 
        at the link above. Note that compatibility may vary depending on OS and Python version. Compatibility information and documentation can be found 
        <a href="https://docs.lodestone.cloud/VTS-Utils/">here</a>.
      </p>
      <br />
      <br />
      <br />
      <br />
    </div>
    <div class="imgContainer">
      <img src="./Images/Ocean2.jpeg" alt="Download bg image" style="width:100%;">
      <div class="imgCtTxtCntr">
        <a style='font-size: 52px !important; font-family: "Montserrat", sans-serif !important; font-weight: 400 !important; text-align: center;' href='../../../ventus-getting-started.php' target='_blank'>
          Home
        </a>
      </div>
    </div>
    <br />
    <br />
    <br />
    <br />
    <br />
    <br />
    </div>
    <div style="font-family: 'Montserrat', sans-serif; font-weight: 300;" class='ms-0 mt-0 me-0 mb-0'>
    <?php
      $contactOT = "contactOverlay";
      $contactOS = 1;
      echo "
      <!-- Page Footer -->
      <div style='background-color: $ftBG'>
        <div style='background-color: $ftBG2; color: $ftC2; text-align: center'; class='mb-0'>
          <p style='font-size: 30px; $montserrat font-weight 200 !important;' class='mt-4 mb-3'>Contact:</p>
          <p style='font-size: 18px; $montserrat font-weight 200 !important;'>contact@djhbuchanan.com</p>
          <a style='$montserrat font-weight 200 !important;' onclick='contactOverlay($contactOT, $contactOS)'>Or, send a message</a>
          <hr />
        </div>
        <nav class='navbar navbar-expand-lg mt-0 mb-0' style='background-color: $ftBG; $montserrat font-weight 200 !important;'>
          <div class='container-fluid'>
            <a style='$montserrat font-weight 200 !important;' class='navbar-brand' href='./home.php'>
              <!-- Logo icon: <img src='/path/logo.svg' alt='' width='30' height='24'> -->
              <p style='color: $ftC; $montserrat font-weight 200 !important;' class='ms-2 mt-1'>Logo</p>
            <a>
            <div class='navbar-nav'>
              <a class='nav-link' style='color: $ftC; $montserrat font-weight 200 !important;' href='./Extras/terms-of-service.php'>Terms of Service</a>
              <a class='nav-link' style='color: $ftC; $montserrat font-weight 200 !important;' href='./Extras/privacy-notice.php'>Privacy Notice</a>
              <a class='nav-link' style='color: $ftC; $montserrat font-weight 200 !important;' href='./Extras/accessibility.php'>Accessibility</a>
              <a class='nav-link' style='color: $ftC; $montserrat font-weight 200 !important;' href='./Extras/site-map.php'>Site Map</a>
              <a class='nav-link' style='color: $ftC; $montserrat font-weight 200 !important;' href='https://github.com/$ghEXT' target='_blank'>GitHub</a>
              <a class='nav-link' style='color: $ftC; $montserrat font-weight 200 !important;' href='https://www.linkedin.com/in/$liEXT' target='_blank'>LinkedIn</a>
            </div>
          </div>
        </nav>
      </div>
      <div style='background-color: $ftBG;'>
        <!-- Bottom Spacer -->
        <br />
      </div>
      ";
    ?>
    </div>
  </body>
</html>

<?php
  // mysqli_close($link);
?>