:root {
  --background-white: #f6f2f2;
  --text-grey: #408372;
  --text-dark: #295031;
  --border: #52cbb9;
  --navbar: #3db8a5;
  --box-background: #fff;
  --card-box-background: #ADDAA1;
  --box-shadow: rgba(0,0,0,0.10);
}

@font-face {
  font-family: pixel-monke;
  src: url("Assets/Fonts/pixel_monke.ttf");
}

* { box-sizing: border-box; }  /*width includes padding and border*/

body {
  margin: 0;
  padding: 8px 0;
  min-height: 100vh;
  font-family: "Lucida Grande",verdana,"Helvetica Neue",Helvetica,Arial,sans-serif;
  color: var(--text-grey);
  background: url("Assets/Homepage/background.png") fixed;
  background-size: cover;
  background-position: bottom center;
}

.container, .opaque-container, .homepage {
  max-width: 1200px;
  min-height: 100vh;
  margin: 0 auto;
  background-color: rgba(255, 255, 255, 0.785);
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 1px 5px var(--box-shadow);
  border: 2px dotted var(--border);
}

.opaque-container { background-color: var(--background-white);}

header,
.main-content,
.project-grid,
aside,
footer {
  padding: 0.5em;
}

.main-content,
aside {
  min-width: 0;
}

img {
  max-width: 100%;
  height: auto;
}

header {
  width: 100%;
  height: 220px;
  background: url(Assets/Homepage/banner.png) center;
  background-size: cover;
  background-position: center;
  border-bottom: 1px solid var(--border);
  padding-top: 30px;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  align-content: center;
  justify-content: center;
}

.site-name {
  max-height: 80px;
  margin: 6px 14px;
}

nav {
  background-color: var(--navbar);
  display: flex;
  justify-content: center;
}

.nav-list {
  list-style: none;
  margin: 0;
  padding: 0;

  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;

  max-width: 900px;
  width: 100%;
}

.nav-list li {
  display: flex;
}

.nav-image {
  max-height: 40px;
  margin: 0 15px;
  align-self: center;
}

.nav-link {
  display: block;
  color: white;
  padding: 14px 25px;
  font-size: 18px;
  text-decoration: none;
}

.nav-link:hover {
  background-color: #499683;
}

aside {
  border-right: var(--border) 2px dotted;
}

.sidebar-title {
  border-bottom: var(--border) 1px solid;
  text-transform:uppercase;
  font-weight:bold;
  margin-bottom:1px;
  padding-left: 5px;
}

.box-left {
  color: var(--text-grey);
  background-color: var(--box-background);
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 1px 3px var(--box-shadow);
  text-align: left;
  margin: 8px 0;
  display: inline-block;
  width: 100%;
}

.box-title {
  transition: 0.2s;
  background: linear-gradient(145deg, #EFFDE9, #ADDAA1);
  font-family: monospace;
  font-weight: bold;
  font-size: 18px;
  margin-bottom:1px;
  padding: 5px;
}

.aside-blog-content {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 5px;
}

.aside-blog-image {
  height: 85px;
  width: 85px;
  background-color: var(--text-grey);
  padding: 1px;
  margin: 2px;
}

.aside-blog-preview {
  margin: 2px 0;
  font-family: monospace;
  font-size: 14px;
}

.socials {
  list-style: none;
  line-height: 1.5;
  margin: 0;
  padding: 5px 10px;
}

.main-content {
  justify-items: center;
  align-items: center;
}

.main-intro {
  padding: 0 14px;
  font-size: 22px;
}

.main-pic {
  display: block;
  margin: auto;
  background: transparent;
}

.main-image {
  width: 100%;
  max-height: 300px;
  object-fit: contain;
}

.card-box {
  max-width: 300px;
  border-radius: 10px;
  overflow: hidden;
  background-color: var(--card-box-background);
  box-shadow: 0 1px 3px var(--box-shadow);
  text-align:center;
  margin: 14px 14px 30px 14px; 
}

.card-image {
  width: 100%;
}

footer {
  padding-top: 30px;
  text-align: center;
  font-size: 14px;
}


/*The homepage grid*/

.homepage {
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: minmax(auto, 220px) minmax(60px, auto) auto auto auto;
    grid-template-areas:
        "header"
        "nav"
        "main"
        "side"
        "footer";
}

@media only screen and (min-width: 900px) {
    .homepage {
        grid-template-columns: minmax(250px, 350px) 1fr;
        grid-template-rows: minmax(auto, 220px) minmax(auto, 60px) auto auto;
        grid-template-areas:
            "header header"
            "nav    nav"
            "side   main"
            "footer footer";
    }
}

header { grid-area: header; }
nav { grid-area: nav; }
.main-content { grid-area: main; }
aside { grid-area: side; }
footer { grid-area: footer; }



/*The homepage main content grid*/

.main-content {
    display: grid;
    grid-template-columns: 1fr;
    grid-template-areas:
        "intro"
        "pic"
        "box-one"
        "box-two"
        "box-three";
    gap: 0.5em;
}

@media only screen and (min-width: 600px) {
    .main-content {
        grid-template-columns: 1fr 1fr 1fr;
        grid-template-rows: auto minmax(auto, 250px);
        grid-template-areas:
        "intro intro pic"
        "box-one box-two box-three";
    }
}

.main-intro { grid-area: intro; }
.main-pic { grid-area: pic; }
.main-box-one { grid-area: box-one; }
.main-box-two { grid-area: box-two; }
.main-box-three { grid-area: box-three; }


/*Container grid for all other pages - flexible side margins*/
.opaque-container, .container {
    display: grid;
    grid-template-columns: 1fr minmax(0, 900px) 1fr;
    grid-template-rows: minmax(auto, 220px) minmax(60px, auto) auto auto;
    grid-template-areas:
        "header header header"
        "nav    nav    nav"
        "left   main   right"
        "footer footer footer";
}

header { grid-area: header; }
nav { grid-area: nav; }
.left-margin { grid-area: left; }
.right-margin { grid-area: right; }
.main { grid-area: main; }
footer { grid-area: footer; }


/*----------------------------------------------------------------
   Privacy
-----------------------------------------------------------------*/
.privacy {
  text-align: left;
  padding: 10px 8px;
  line-height: 1.5;
  font-size: 15px;
}

.privacy h2 {
  padding-top: 12px;
}

/*----------------------------------------------------------------
   Blog
-----------------------------------------------------------------*/

.preview-box {
  color: var(--text-grey);
  background-color: var(--box-background);
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 1px 3px var(--box-shadow);
  text-align: left;
  margin: 40px 16px;
}

.preview-title {
  transition: 0.2s;
  background: linear-gradient(145deg, #EFFDE9, #ADDAA1);
  font-family: monospace;
  font-size: 20px;
  margin-bottom:1px;
  padding: 5px 12px;
}

.preview-content {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 5px;
}

.preview-image {
  height: 100px;
  width: 100px;
  background-color: var(--text-grey);
  padding: 1px;
  margin: 5px 10px;
}

.preview-text-container {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.preview-subtitle {
  margin: 2px 0;
  font-family: monospace;
  font-size: 16px;
  font-weight: bold;
  padding-bottom: 5px;
  border-bottom: var(--border) solid 1px;
  margin-right: 10px;
}

.preview-text {
  margin: 2px 0;
  font-family: monospace;
  font-size: 16px;
}

.blog-link { text-decoration: none; color: var(--text-grey); }
.blog-link:hover { text-decoration: underline; color: var(--text-dark); }
.blog-link:active { text-decoration: underline; color: var(--text-dark); }
.blog-link:visited { text-decoration: none; color: var(--text-grey); }

/*----------------------------------------------------------------
   Blog posts
-----------------------------------------------------------------*/

.blog {
  text-align: left;
  padding: 10px 8px;
  line-height: 1.5;
  font-size: 15px;
}

.blog h2 {
  background-color: var(--card-box-background);
  font-family: monospace;
  border-top: var(--border) dotted 2px;
  padding-left: 5px;
}

.blog-image {
  display: block;
  margin: 0 auto;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 1px 3px var(--box-shadow);
}

.blog blockquote {
  background-color: var(--card-box-background);
  color: var(--text-dark);
  margin: 0 20px;
  padding: 20px;
  border-radius: 20px;
  overflow: hidden;
}

.blog-quote {
  background-color: var(--card-box-background);
  color: var(--text-dark);
  margin: 0 20px;
  padding: 20px;
  border-radius: 20px;
  overflow: hidden;
  text-align: center;
  border: 1px solid var(--border);
}

.blog a { text-decoration: underline; color: var(--text-dark); }
.blog a:hover { text-decoration: underline; color: hotpink; }
.blog a:active { text-decoration: underline; color: hotpink; }
.blog a:visited { text-decoration: underline; color: var(--text-dark); }

.blog-subtitle {
  margin-bottom: 20px;
  font-family: monospace;
  font-size: 18px;
  font-weight: bold;
  padding-bottom: 5px;
  border-bottom: var(--border) solid 1px;
}

.blog-break {
  border-bottom: var(--border) dotted 2px;
}

.back-content {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 5px 5px 5px 10px;
  border-bottom: 1px solid var(--border);
}

.back-arrow { 
  max-height: 30px;
}

.back-text {
  font-family: monospace;
  font-size: 22px;
  font-weight: bold;
}

.twin {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 0;
}

.twin img {
  flex: 1 1 280px;
  width: 100%;
  max-width: 350px;
  object-fit: cover;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 1px 3px var(--box-shadow);
  margin: 8px;
}

.twin-text {
  flex: 1 1 280px;
  width: 100%;
  padding: 0;
  line-height: 1.5;
}

.video-wrapper {
  width: 100%;
  max-width: 500px;
  margin: 0 auto;
  aspect-ratio: 16 / 9;
}

.video-wrapper iframe {
  width: 100%;
  height: 100%;
}

.blog img.emoji {
  margin: 0;
  vertical-align: middle;
  object-fit: contain;
  display: inline;
}

/*----------------------------------------------------------------
   Projects
-----------------------------------------------------------------*/

.project-grid {
    display: grid;
    grid-template-areas:
        "one-h"
        "one-t"
        "one-i"
        "two-h"
        "two-t"
        "two-i";
    gap: 2em;
}

@media only screen and (min-width: 600px) {
    .project-grid {
        grid-template-columns: 1fr 1fr;
        grid-template-areas:
        "one-h one-h"
        "one-t one-i"
        "two-h two-h"
        "two-i two-t";
    }
}

.project-one-head { grid-area: one-h; }
.project-one-text { grid-area: one-t; }
.project-one-image { grid-area: one-i; }
.project-two-head { grid-area: two-h; }
.project-two-text { grid-area: two-t; }
.project-two-image { grid-area: two-i; }


.project-one-head, .project-two-head {
  font-family: 'pixel-monke';
  font-size: 40px;
  color: black;
  text-align: center;
  line-height: 2;
  padding: 50px 0 25px 0;
}

.project-one-text, .project-two-text {
  font-size: 18px;
}

.project-one-image {
  border-radius: 10px;
  box-shadow: 0 1px 3px var(--box-shadow);
}

.project-two-image {
  border-radius: 10px;
  overflow: hidden;
}

img.project-two-image {
  box-shadow: 0 1px 3px var(--box-shadow);
  border-radius: 10px;
}

.project-grid {
  align-items: center;
  margin-bottom: 40px;
}

/*----------------------------------------------------------------
   About
-----------------------------------------------------------------*/
.about-title {
  text-align: center;
  padding-top: 30px;
}

.about-subtitle {
  text-align: center;
  font-family: monospace;
  padding: 10px;
}

.profile-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 32px;
  margin: 50px 0;
}

.profile-box {
  flex: 0 1 270px;
  border-radius: 10px;
  overflow: hidden;
  background-color: rgb(188, 216, 189);
  box-shadow: 0 1px 3px var(--box-shadow);
}

.profile-image {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
  background-color: var(--background-white);
}

.profile-name {
  color: var(--text-dark);
  font-size: 18px;
  font-weight: bold;
  text-align: center;
  margin: 16px 0 10px 0;
  padding: 0;
}

.profile-title {
  color: var(--text-dark);
  font-size: 14px;
  text-align: center;
  font-style: italic;
  margin: 0;
  padding: 0;
}

.profile-text {
  color: var(--text-dark);
  font-size: 14px;
  margin: 14px;
  padding: 0;
  line-height: 1.5;
}

.profile-icons {
  display: flex;
  justify-content: center;
  gap: 8px;
  padding: 0 14px 14px 14px;
}

.icon {
  max-height: 36px;
  border-radius: 5px;
  overflow: hidden;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.icon:hover {
  transform: scale(1.1);
  opacity: 0.8;
}

/*----------------------------------------------------------------
   Contact
-----------------------------------------------------------------*/

.contact {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 0;
}

.contact-image {
  flex: 1;
  max-width: 300px;
  min-width: 280px;
  object-fit: cover;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 1px 3px var(--box-shadow);
  margin: 8px;
}

.contact-text-box {
  min-width: 200px;
}

.contact-text {
  flex: 1;
  min-width: 200px;
  font-size: 18px;
  padding: 8px;
}

.contact-email-box {
  margin: 0 auto;
  width: fit-content;
}

.contact-email {
  text-align: center;
  transition: 0.2s;
  background: linear-gradient(145deg, #EFFDE9, #ADDAA1);
  border: var(--border) 1px solid;
  border-radius: 20px;
  overflow: hidden;
  color: var(--text-dark);
  font-family: monospace;
  font-weight: bold;
  font-size: 18px;
  margin: 40px 5px 40px 5px;
  padding: 0 20px;
}