h1,h2,h3 {
  font-family: 'Montserrat', sans-serif;
  text-align: center;
 }
 
 p,p2,figcaption {
  font-family: 'Roboto', sans-serif;
 }
 

  .container {
    text-align: center;
  }
  
  .topnav {
    overflow: hidden;
    background-color: #333;
    position: relative;
    justify-content: flex-end;
    font-family: 'Montserrat', sans-serif;
  
  }
  
  /* Hide the links inside the navigation menu (except for logo/home) */
  .topnav #myLinks {
    display: none;
    transform: translateX(-100%); /* Move the menu off-screen to the left */
    animation: slideIn 0.5s forwards; /* Apply the animation and keep the final state */
  }
  
  /* Style navigation menu links */
  .topnav a {
    color: white;
    padding: 14px 16px;
    text-decoration: none;
    font-size: 17px;
    display: block;
  }
  
  /* Style the hamburger menu */
  .topnav a.icon {
    background: white;
    display: block;
    position: absolute;
    right: 0;
    top: 0;
  }

  .topnav a:hover {
    background-color: #ddd; /* Light grey background */
    color: black; /* Black text */
   }
   
  
  @keyframes slideIn {
    from {
      transform: translateX(-100%); 
    }
    to {
      transform: translateX(0); 
    }
  }
  
  .logo {
    width: 100px;
    height: 100px;
  }
  .logo img {
    display: block;
    max-width: 100%;
    max-height: 100%;
  }
  
  .topnav {
    overflow: hidden;
    background-color: #F2F5F7;
    position: relative;
  }
  
  .menu-container {
    display: flex;
    justify-content: space-between;
  }
  
  .topnav a {
    color: white;
    padding: 14px 16px;
    text-decoration: none;
    font-size: 17px;
    display: block;
  }
  
  @media screen and (min-width: 769px) {
    .topnav #myLinks {
      display: block;
      transform: none;
      animation: none;
    }
    
    .topnav a.icon {
      display: none;
    }
    
    .topnav a {
      float: right;
      justify-content: center;
      color: black;
    }
    
    .topnav a:first-child {
      float: left;
    }
  }

  footer {
    text-align: center;
    padding: 3px;
    background-color: rgba(117,210,150,.5);
    width: 100%; /* Ensure the footer spans the full width */
  }
  
  /* Additional rule to ensure the footer clears any floats within it */
  footer::after {
    content: "";
    display: table;
    clear: both;
  }
  

.main-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
 }

 header {
  position: relative;
  height: 500px;
  width: 100%;
  margin-bottom: 3em;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: white;
  overflow: hidden;
}

header video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover; /* Ensures the video covers the area without stretching */
  z-index: -1; /* Places the video behind your content */
}

 
 .grid-container {
  display: grid;
  column-gap: 50px;
  grid-template-columns: 1fr 1fr;
  padding: 10px;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  place-items: center;
  align-items: center; 
  justify-items: center; 
 }
 
 .grid-item-skills {
  align-self: start;
 } 


.grid-item {
  padding: 20px;
  text-align: center;
  display: flex; /* Make each grid item a flex container */
 flex-direction: column; /* Stack content vertically */
 align-items: center; /* Center content horizontally */
 justify-content: center;
}

.about {
  background-color: rgba(117,210,150,.5);
  display: flex; /* Make .about a flex container */
  flex-direction: column; /* Stack children vertically */
  align-items: center; /* Center children horizontally */
  justify-content: center; /* Center children vertically */
  text-align: right; /* Align text to the left */
 }
 
 .protrait {
 float: left; /* Move the image to the right */
 margin-left: 20px; /* Add some space between the image and the text */
 vertical-align: text-top; /* Align the image with the top of the text */
}

 .about p {
  text-align: left; /* Move the text to the right */
  clear: both; /* Clear the float to prevent text wrapping around the image */
 }
 
 

.project iframe {
  display: block;
  margin-left: auto;
  margin-right: auto;
}

.project {
  text-align: center;
  background-color: rgba(117,210,150,.5)
}

.project2 iframe {
  display: block;
  margin-left: auto;
  margin-right: auto;
}

.project2 {
  text-align: center;
}

@media (max-width: 768px) {
  .grid-container {
    grid-template-columns: 1fr;
  }
}



 
 a:link, a:visited, a:hover, a:active {
  text-decoration: none;
  color: black;
 }
 
.project-grid {
  display: flex;
  flex-direction: column; /* Stack projects vertically */
  align-items: center; /* Center projects horizontally */
  gap: 20px; /* Adjusts the gap between grid items */
}

.project-grid figure {
  display: flex;
  flex-direction: column;
  align-items: center; /* Centers items horizontally */
  text-align: center; /* Centers text */
  width: 100%; /* Ensure each figure takes up the full width */
}

 
.header-text {
  display: flex;
 justify-content: center;
 align-items: center;
}

.ultra {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background-color: rgba(117,210,150,.5); /* Sets the background color to green */
  padding: 20px; /* Adds some padding around the content for better appearance */
  text-align: center; /* Centers the text and iframe horizontally */
  position: relative;
 }

.iframe-container{
  position: relative;
  overflow: hidden;
  width: 100%;
  padding-bottom: 56.25%; 
  height: 0;
}
.iframe-container iframe{
  position: absolute;
  top:0;
  left: 0;
  width: 100%;
  height: 100%;
}
 
body, html {
  animation: fadeInAnimation ease 1s;
  animation-iteration-count: 1;
  animation-fill-mode: forwards;
  overflow-x: hidden;
  margin: 0;
  padding: 0;
  width: 100%;
}

@keyframes fadeInAnimation {
  0% {
      opacity: 0;
  }

  100% {
      opacity: 1;
  }
}

/* Default styles for mobile devices */
.grid-container {
  display: grid;
  grid-template-columns: 1fr;
}

/* Styles for tablets and larger devices */
@media screen and (min-width: 768px) {
  .grid-container {
    grid-template-columns: 1fr 1fr;
  }
}


img, picture, video {
  max-width: 100%;
  height: auto;
}

.photo {
  width: 100%;
  height: auto;
}

.gif {
  width: 100%;
  height: auto;
}



footer h2 {
    animation: none;
}
 
 @keyframes fadeInFromBottom {
  0% {
    opacity: 0;
    transform: translateY(50px);
 }
  100% {
    opacity: 1;
    transform: translateY(0);
 }
}

.project-grid figure {
  animation: fadeInFromBottom 2s ease-out forwards;
 }
 


 .image {
  float: left;
  margin-right: 10px; /* Adjust the space between the image and text */
}

.text {
  float: left;
  background-color: rgba(117,210,150,.5);
}

.centered-iframe {
  display: flex;
  justify-content: center;
  align-items: center;
  max-width: 600px; /* Adjust this value based on your preference */
  margin: 0 auto; /* Center the container itself */
}

.centered-iframe iframe {
  border-radius: 12px;
  width: 100%; /* Adjust this to control the iframe size */
  height: 352px; /* Adjust this to control the iframe size */
  box-shadow: 0 4px 8px 0 rgba(0,0,0,0.2); /* Optional: adds shadow for depth */
}

.project-grid2 {
  display: flex;
  flex-wrap: wrap; /* Allows the items to wrap onto multiple lines */
  justify-content: center; /* Centers items horizontally */
  align-items: center; /* Centers items vertically */
  gap: 20px; /* Adjusts the gap between grid items */
 }
 
 .project-grid2 figure {
  display: flex;
  flex-direction: column;
  align-items: center; /* Centers items horizontally */
  text-align: center; /* Centers text */
 }

 .modal {
  display: none; /* Initially hidden */
  position: fixed; /* Fixed positioning */
  z-index: 1; /* Above other elements */
  left: 0;
  top: 0;
  width: 100%; /* Full width */
  height: 100%; /* Full height */
  overflow: auto; /* Allow scrolling if content exceeds the modal size */
  background-color: rgba(0,0,0,0.4); /* Semi-transparent background */
}


.modal-content {
  background-color: transparent;
  margin: auto;
  padding: 10px;
  width: 90%; /* Adjust as needed */
  height: 90%; /* Adjust as needed */
  position: relative;
}

.video-container {
  width: 100%;
  height: 100%;
  position: relative;
}

video {
  width: 100%;
  height: 100%;
  object-fit: contain; /* Maintains aspect ratio */
}



.close {
  color: #aaa;
  font-size: 50px;
  font-weight: bold;
  position: absolute;
  top: 10px; /* Adjust as needed */
  right: 10px; /* Adjust as needed */
}


.close:hover,
.close:focus {
  color: black;
  text-decoration: none;
  cursor: pointer;
}

/* Targeting all unvisited links within p elements */
p a:link {
  color: green;
  background-color: transparent;
  text-decoration: none;
}

/* Optionally, target visited links if needed */
p a:visited {
  color: darkgreen; /* Adjust as needed */
}

.links-container {
  display: flex;
  justify-content: flex-end; /* Aligns items to the end of the container */
  gap: 10px; /* Adjusts the space between links */
}
