/* Universals */
@font-face {
  src: url(../fonts/bahnschrift.ttf) format("TrueType");
  font-family: "bahnschrift";
}
:root {
  --primary-color: #1a1a1a;
  --secondary-color: #f4f4f4;
  --accent-color: #ff6f61;
  --font-family: "bahnschrift";
}

* {
  box-sizing: border-box;
}

select {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  background-image: url('data:image/svg+xml;utf8,<svg fill="%23f4f4f4" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg"><path d="M7 10l5 5 5-5z"/></svg>');
  background-repeat: no-repeat;
  background-position: right 10px center;
  padding-right: 40px;
}

/* Primary Elements */

body {
  display: flex;
  position: relative;
  flex-direction: column;
  margin: 0;
  background-color: var(--primary-color);
  padding: 0;
  min-width: 300px;
  min-height: 100vh;
  color: var(--secondary-color);
  font-family: var(--font-family);
}
.de-em {
  opacity: 0.5;
}
main {
  margin: auto;
  margin-top: 0;
  margin-bottom: 0;
  padding: 2rem;
  width: 100%;
  max-width: 1200px;
  max-height: fit-content;
}

header {
  display: flex;
  position: relative;
  justify-content: center;
  align-items: center;
  padding: 10px 0;
  padding: 2.5rem;
  aspect-ratio: 2.5 / 1;
  color: var(--secondary-color);
  text-align: center;
  text-shadow: 0 0.5rem 0.5rem rgba(0, 0, 0, 1);
}
header h1 {
  margin-bottom: -1.5rem;
}
header p {
  margin-top: 0.5rem;
  margin-bottom: 0px;
  padding-right: 10rem;
  padding-left: 5rem;
  font-size: 1.2rem;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0;
  margin-bottom: 1rem;
  padding: 0;
  font-weight: bold;
  font-stretch: condensed;
  font-family: "bahnschrift";
  letter-spacing: 0.5rem;
  text-align: center;
  text-transform: uppercase;
}
h1 {
  font-size: 8rem;
  letter-spacing: 1.6rem;
}
h2 {
  font-size: 2rem;
  letter-spacing: 0.2;
}
h3 {
  opacity: 0.5;
  font-size: 1.5rem;
  letter-spacing: 0.18rem;
}
p {
  margin: 0;
  margin-bottom: 1rem;
  padding: 0;
  font-size: 1rem;
  line-height: 1.5;
  font-family: Arial, Helvetica, sans-serif;
  text-align: justify;
}
a {
  text-decoration: none;
  color: inherit;
}
select {
  margin: 2rem;
  box-shadow: 0rem 1rem 1rem 0rem rgba(0, 0, 0, 0.8);
  border: none;
  border-bottom: #333 2px solid;
  border-radius: 0.5rem;
  background-color: var(--primary-color);
  padding: 1rem;
  color: var(--secondary-color);
  font-size: 1rem;
  font-family: var(--font-family);
}
select option {
  border: none;
  border-radius: 0.5rem;
  background-color: var(--primary-color);
}
select:active,
select:focus {
  outline: none;
}
footer {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  margin-top: auto;
  box-shadow: 0rem -2rem 2rem 0rem rgba(0, 0, 0, 0.8);
  border-top: #333 2px solid;
  padding: 1rem;
  color: var(--secondary-color);
  font-size: 0.9rem;
  text-align: center;
}

footer > * {
  margin-bottom: 0px;
}

/* Id Selectors */

#header-img {
  position: absolute;
  top: 0px;
  right: 0px;
  bottom: 0px;
  left: 0px;
  z-index: -1;
  filter: brightness(0.75);
}

#header-img:before {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 1;
  box-shadow: inset 0rem -2rem 2rem 0rem rgba(0, 0, 0, 0.8);
  content: "";
}

#header-img > video {
  min-width: 100%;
  height: 100%;
  object-fit: cover;
}
#portfolio-menu {
  display: flex;
  width: 100%;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
}
#portfolio-menu > * > * {
  margin: 2rem;
  box-shadow: 0rem 1rem 1rem 0rem rgba(0, 0, 0, 0.8);
  border: none;
  border-bottom: #333 2px solid;
  border-radius: 0.5rem;
  background-color: var(--primary-color);
  padding: 1rem;
  color: var(--secondary-color);
  font-size: 1rem;
  font-family: var(--font-family);
  transition: 0.1s ease-in-out;
}
#portfolio-menu > * > *:hover {
  cursor: pointer;
  scale: 1.1;
}

#about {
  display: grid;
  grid-template-rows: auto auto;
  grid-template-columns: 2fr 5fr;
  gap: 3rem;
  max-height: fit-content;
}

#about > :nth-child(1) {
  grid-area: 1 / 2 / 2 / 2;
}

#about > :nth-child(2) {
  grid-area: 2 / 2 / 3 / 3;
  padding-bottom: 0px;
  text-align: left;
}

#about > :nth-child(3) {
  grid-area: 1 / 1 / 3 / 2;
}
.profile-photo {
  box-shadow: 0rem 1rem 2rem 0rem rgba(0, 0, 0, 0.8);
  border-radius: 0.5rem;
  background-image: url(/assets/imgs/JamesIngallsHeadshot_01.jpg);
  background-position: center;
  background-size: cover;
}

#portfolio {
  display: flex;
  flex-grow: 1;
  flex-direction: column;
  align-items: center;
  box-shadow: inset 0rem 2rem 2rem 0rem rgba(0, 0, 0, 1);
  border-top: #333 2px solid;
  background-color: rgba(0, 0, 0, 60%);
  width: 100%;
  height: 100%;
}

#scroll-text-container {
  width: fit-content;
}

#projects {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  padding: 2rem;
  width: 100%;
}

/* Class Selectors */

.img-column {
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  gap: 1rem;
}

.img-column > * {
  flex: 1 1 0;
  filter: drop-shadow(0px 10px 10px rgba(0, 0, 0, 1));
  border-bottom: #333 2px solid;
  border-radius: 0.5rem;
  background-position: center;
  background-size: cover;
  background-color: var(--secondary-color);
  aspect-ratio: 16 / 9;
  min-width: 0;
}

.portfolio-card {
  transition: transform 0.1s ease-in-out;
  box-shadow: 0rem 1rem 2rem 0rem rgba(0, 0, 0, 0.5);
  border-bottom: #333 2px solid;
  border-radius: 0.5rem;
  border-radius: 0.5rem;
  background-color: #000000;
  height: min-content !important;
}
.portfolio-card:hover {
  transform: scale(1.05);
}
.portfolio-card > video {
  border-radius: 0.5rem;
  background-color: black;
  width: 100%;
  height: auto;
  object-fit: fit;
}

@media screen and (max-width: 768px) {
  #about {
    grid-template-rows: auto auto auto;
    grid-template-columns: 1fr;
    gap: 0.2rem;
  }

  #about > :nth-child(1) {
    grid-area: 1 / 1 / 2 / 2;
  }

  #about > :nth-child(2) {
    grid-area: 3 / 1 / 4 / 2;
  }
  #scroll-text-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 100%;
  }

  #about > :nth-child(3) {
    grid-area: 2 / 1 / 3 / 2;
    align-self: center;
    justify-self: center;
    margin-bottom: 2rem;
    aspect-ratio: 1 /1;
    height: 200px;
  }
  .profile-photo {
    border-radius: 50%;
  }
  .img-column {
    flex-direction: row;
    margin-top: 1rem;
    margin-bottom: 1rem;
  }
  header h1 {
    margin-bottom: 0.5rem;
  }
  header p {
    margin-top: 0rem;
    padding-right: 8rem;
    padding-left: 5rem;
  }
  .portfolio-card {
    width: 100%;
  }
}

@media screen and (max-width: 800px) {
  .img-column :nth-child(3) {
    display: none;
  }
  h1 {
    font-size: 5rem;
    letter-spacing: 1rem;
  }
  header h1 {
    margin-bottom: 0.5rem;
  }
  header p {
    margin-top: 0.5rem;
    padding-right: 1rem;
    padding-left: 1rem;
    font-size: 1.2rem;
  }
}

@media screen and (max-width: 400px) {
  .img-column :nth-child(2) {
    display: none;
  }
  h1 {
    font-size: 4rem;
    letter-spacing: 0.5rem;
  }
  header h1 {
    margin-bottom: 0.5rem;
  }
  header p {
    display: none;
  }
  h2 {
    font-size: 1.8rem;
    letter-spacing: 0.15rem;
  }
  h3 {
    font-size: 1.5rem;
    letter-spacing: calc(0.18rem / 2);
  }
}

/* Utility Classes */
.left-align {
  text-align: left;
}

.right-align {
  text-align: right;
}

.italic {
  font-style: italic;
}

.uppercase {
  text-transform: uppercase;
}

.center {
  text-align: center;
}

/* Modal Styles */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.9);
}

.modal-open {
  overflow: hidden;
}

.modal-content {
  background-color: var(--primary-color);
  margin: auto;
  padding: 20px;
  width: 80%;
  max-width: 500px;
  border-bottom: #333 2px solid;
  color: var(--secondary-color);
  border-radius: 0.5rem;
  filter: drop-shadow(0px 10px 10px rgba(0, 0, 0, 1));
}

.close {
  color: #aaa;
  float: right;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
}

.close:hover,
.close:focus {
  color: var(--accent-color);
}
