@import url("https://fonts.googleapis.com/css2?family=Montserrat&display=swap");

/* Default styling for classless elements */

h1 {
  padding: 2vh;
  font-size: 10vh;
  font-weight: 2000;
  font-family: monospace, sans-serif;
  text-align: center;
  color: #030511;
}

h2 {
  font-size: 5vh;
  font-family: monospace, sans-serif;
  text-align: center;
  color: #030511;
}

h3 {
  font-weight: 400;
  font-size: 4vh;
  font-family: monospace, sans-serif;
  text-align: center;
}

h4 {
  font-size: 3vh;
  font-family: Montserat, sans-serif;
  text-align: center;
  padding-bottom: 1.25vh;
}

p {
  font-size: 15px;
  font-family: Montserat, sans-serif;
  padding: 1em 1em 2em 2em;
  line-height: 20px;
}

b {
  color: #14248a;
  line-height: 5vh;
}

.lilac {
  color: #cdb4dbcd;
}

.darkerpurple {
  color: #998fc7;
} 

/* automatically sets content into 100& viewport */
.limited {
  margin: 0;
  padding: 0;
  background-color: #fdfdfd;
  color: #212121;
  font-family: Montserrat, sans-serif;
  text-rendering: optimizeLegibility;
}

/* forces image to fit viewport without being too large */
img {
  display: block;
  max-width: 1024px;
  max-height: 600px;
  width: auto;
  height: auto;
}

/* container class then keeps the max-width content to 1024 px and 95% of the page */
/* entire page is kept into this container */

/* modifies fixed-width of Bootstrap's container */
.container {
  margin: 0;
  width: 95%;
  max-width: 1024px;
}

/* grid with sections for each component of the portfolio */

.grid {
  display: grid;
  width: 100%;
  grid-template-columns: 2fr 2fr 2fr 0.25fr;
  grid-template-rows: 0.5fr 0.5fr 0.15fr;
  padding-bottom: 1vh;
  align-items: center;
  grid-template-areas:
    "header header header header"
    "img info info links"
    "about about honesty honesty"
    "education-header education-header education-header education-header"
    "education education education-text education-text"
    "education2 education2 education2-text education2-text";
}

/* header elements inside of the grid styled to be a certain colour and handle text length */
.grid > header {
  grid-area: header;
  background-color: #28262c;
  text-align: justify;
  inline-size: 100%;
  overflow-wrap: break-word;
  max-width: 100%;
}

.grid > header h1 {
  padding: 3vh;
  color: #f9f5ff;
  font-size: 8vh;
  font-weight: 2000;
  font-family: monospace, sans-serif;
  text-align: center;
}

.grid .me {
  grid-area: img;
  object-fit: fill;
  height: auto;
  width: 100%;
}

#me-text {
  text-align: center;
}

.grid .info {
  padding: 2vh;
  font-family: Montserrat, sans-serif;
  grid-area: info;
  display: flex;
  flex-direction: column;
  max-width: 1024px;
  text-align: center;
  justify-content: space-around;
  align-self: start;
}

.grid .info h2 {
  color: #4a3e79;
}

.info-text {
  line-height: 2.5 vh;
}

.grid .links {
  grid-area: links;
  text-align: center;
}

.grid .about {
  grid-area: about;
  text-align: justify;
  padding: 2vh;
  height: 100%;
  background-color: #f9f5ff;
}

.grid .about h3 {
  padding-bottom: 2vh;
}

.grid .education-header {
  grid-area: education-header;
}
.grid .honesty {
  border-left: 3px solid #998fc7;
  padding: 2vh;
  height: 100%;
  background-color: #f9f5ff;
  grid-area: honesty;
  grid-row: 3 / 4;
  grid-template-columns: 1fr;
}

.grid .honesty h3 {
  padding-bottom: 2vh;
}

.grid h2 {
  color: #998fc7;
}

.education {
  grid-area: education;
  background-color: #6152a3;
  color: #f9f5ff;
  height: 99%;
  max-height: 1024px;
  overflow-wrap: break-word;
  padding: 1.75vh;
  font-size: 2.5vh;

  /* forces text to align vertically AND horizontally */
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  line-height: 5vh;
}
.grid .education-text {
  grid-area: education-text;
  padding-top: 1vh;
  padding-left: 4vh;
}
.grid .education2 {
  grid-area: education2;
  height: 99%;
  max-height: 1024px;
  background-color: #41376d;
  text-align: center;
  color: #f9f5ff;
  padding: 1.75vh;
  font-size: 2.5vh;
  /* forces text to align vertically AND horizontally */
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  line-height: 5vh;
}

.grid .education2-text {
  grid-area: education2-text;
  padding-left: 4vh;
}

/* styling for when a link is hovered */
a:hover {
  color: #ffafcc;
}

a.link {
  display: inline-block;
  padding: 10px 20px;
  color: white;
  text-decoration: none;
  border-radius: 5px;
  box-shadow: 0px 3px 0px 0px lightgrey;
}

.link {
  background-color: #cdb4dbcd;
  padding: 10px 15px;
  border-radius: 5px;
}

a.link:hover {
  color: white;
  background-color: #ffafcc;
  cursor: pointer;
  opacity: 0.5;
  transition: 0.5s ease;
}

/* Form Styling */
#contact-jump {
  padding-top: 5vh;
  color: white;
  font-size: 10vh;
}

#error {
  display: none;
  padding: 0 0.25vh;
}
#error-box {
  display: none;
  border-style: solid;
  border-color: hotpink;
  text-align: center;
  margin-top: 1vh;
  background-color: white;
}

.heading {
  padding-top: 1.5vh;
  color: #030511;
  font-family: Montserat, sans-serif;
  font-size: 2vh;
}

.options {
  color: #030511;
  font-family: Montserat, sans-serif;
  font-size: 2vh;
}

#info-form {
  background-color: #d4c2fc;
  padding: 5vh;
}

/* Grid layout will change to a vertical column in the case of mobile resizing */

@media (max-width: 768px) {
  .grid {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
    grid-gap: 1vh 0vh;
    grid-template-areas:
      "header"
      "img"
      "links"
      "info"
      "about"
      "honesty"
      "education-header"
      "education"
      "education-text"
      "education2"
      "education2-text";
  }
  .grid > header {
    text-align: center;
  }

  img {
    width: 100%;
  }

  .grid .honesty {
    display: block;
    grid-area: honesty;
  }
}
