/* General reset and styling */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Poppins', sans-serif;
  background-color: #f0f0f0;
  overflow-x: hidden;
  overflow-y: auto;
}

.fade-out { opacity: 0; transition: opacity 0.5s ease-out; }
.fade-in  { opacity: 1; transition: opacity 0.5s ease-in; }

/* Navigation Bar */
.navbar {
  background-color: white;
  padding: 10px 50px;
  position: fixed;
  top: 0;
  width: 100%;
  display: flex;
  justify-content: flex-end;
  z-index: 1000;
  border-bottom: 5px solid #f8f8f8;
}

.navbar nav ul {
  list-style: none;
  display: flex;
  gap: 20px;
}

.navbar nav ul li a {
  text-decoration: none;
  font-size: 1.2rem;
  color: #001f59;
  padding: 10px 20px;
  border-radius: 5px;
}

.navbar nav ul li a:hover {
  background-color: transparent;
  color: #ff9800;
  border-bottom: 2px solid #ff9800;
}

/* Home Section */
.home {
  position: relative;
  height: 100vh;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #f0f0f0;
  overflow: hidden;
}

@media (max-width: 768px) {
  .home { display: none; }
  .navbar nav ul li:first-child { display: none; }
}

#particles-js {
  position: absolute;
  width: 100%;
  height: 100%;
  z-index: 1;
  top: 0;
  left: 0;
  pointer-events: none;
}

.content {
  z-index: 2;
  position: relative;
  color: #001f59;
  margin-left: 120px;
}

.content h1 {
  font-size: 4rem;
  color: #001f59;
  margin-bottom: 10px;
}

.highlight { color: #ff9800; }

.unity-developer {
  font-size: 2.5rem;
  color: #86edbc !important;
  white-space: nowrap;
  overflow: hidden;
  margin-bottom: 60px;
  z-index: 2;
  position: relative;
}

/* Blinking caret effect for dynamic text */
@keyframes blink-caret {
  0%, 100% { border-color: transparent; }
  50% { border-color: #86edbc; }
}

.dynamic-text {
  border-right: 2px solid #86edbc;
  animation: blink-caret 0.7s step-end infinite;
}

.btn {
  margin-top: 40px;
  padding: 10px 20px;
  background-color: #001f59;
  color: white;
  border-radius: 50px;
  font-size: 1.2rem;
  text-decoration: none;
  transition: all 0.3s ease;
  border: none;
}

.btn:hover {
  background-color: #ff9800;
  transform: scale(1.1);
}

/* Social Icons */
.social-icons {
  margin-top: 20px;
  display: flex;
  gap: 20px;
}

.social-icons a {
  color: #001f59;
  font-size: 2rem;
  padding: 10px;
  transition: color 0.3s ease;
}

.social-icons a:hover { color: #ff9800; }

/* Skill Image Styling */
.image {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-right: 200px;
  position: relative;
  display: inline-block;
}

.image img {
  max-width: 400px;
  height: auto;
  border-radius: 50%;
  transition: transform 0.3s ease;
}

.image img:hover { transform: scale(1.05); }

.skill-box {
  position: absolute;
  background-color: rgb(218 218 218);
  color: #001f59;
  padding: 12px 12px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: bold;
  text-align: center;
}

.skill-box:hover {
  box-shadow: 0 0 15px rgba(128, 128, 128, 0.6);
  transform: scale(1.1);
  cursor: pointer;
}

.skill-box-1 { top: -40px; left: 50px; }
.skill-box-2 { top: -60px; right: 50px; }
.skill-box-3 { top: 20px; left: -150px; }
.skill-box-4 { top: 20px; right: -150px; }
.skill-box-5 { top: 160px; left: -170px; }
.skill-box-6 { top: 120px; right: -170px; }
.skill-box-7 { top: 280px; left: -190px; }
.skill-box-8 { top: 220px; right: -150px; }
.skill-box-9 { bottom: -50px; left: 50px; }
.skill-box-10 { bottom: -50px; right: 50px; }
.skill-box-11 { bottom: 50px; right: -80px; }

/* About Section */
.about-section {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 100px 50px;
  background-color: #f0f0f0;
  flex-direction: row;
}

.about-image {
  flex-shrink: 0;
  width: 350px;
  height: auto;
  margin-right: 100px;
}

.about-image img {
  width: 100%;
  height: auto;
  border-radius: 200px;
  box-shadow: 0px 10px 100px rgba(0, 0, 0, 0.1);
}

.about-text {
  flex-grow: 1;
  text-align: left;
  max-width: 50%;
  line-height: 1.6;
  color: #333;
}

.about-text h2 {
  font-size: 2.5rem;
  color: #001f59;
  font-weight: bold;
  margin-bottom: 10px;
}

/* Resume Button */
.resume-btn {
  display: inline-block;
  margin-top: 20px;
  padding: 15px 40px;
  background-color: #001f59;
  color: white;
  border-radius: 50px;
  font-size: 1.1rem;
  font-weight: bold;
  text-decoration: none;
  transition: background-color 0.3s ease;
  box-shadow: 0px 5px 15px rgba(0,0,0,0.1);
}

.resume-btn:hover {
  background-color: #ff9800;
  box-shadow: 0px 7px 20px rgba(0,0,0,0.2);
}

/* Portfolio Section */
.portfolio-section {
  padding: 100px 50px;
  background-color: #f0f0f0;
  text-align: center;
  margin-bottom: 150px;
}

.grid-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  padding: 20px;
}

.project-card {
  background-color: white;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0px 5px 15px rgba(0, 0, 0, 0.1);
  text-align: left;
  transition: transform 0.3s ease;
}

.project-card:hover { transform: scale(1.05); }

.project-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 10px;
}

/* Modal Styling */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.8);
  justify-content: center;
  align-items: center;
  z-index: 2000;
}

.modal-content {
  width: 70%;
  max-width: 800px;
  height: auto;
  max-height: 85vh;
  background-color: white;
  padding: 20px;
  border-radius: 15px;
  box-shadow: 0px 5px 15px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  position: relative;
  overflow-y: auto;
}

/* Carousel Styles */
.carousel-container {
  position: relative;
  width: 100%;
  overflow: hidden;
}

.carousel {
  display: flex;
  overflow: hidden;
}

.carousel-item {
  min-width: 100%;
}

.carousel-item img,
.carousel-item video {
  width: 100%;
  height: auto;
  max-height: 400px;
  object-fit: contain;
  display: block;
  margin: 0 auto;
  border-radius: 10px;
}

/* Carousel Navigation Buttons */
.prev, .next {
  cursor: pointer;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  color: #333;
  font-size: 36px;
  padding: 20px;
  background-color: rgba(255, 255, 255, 0.8);
  border-radius: 50%;
  user-select: none;
  z-index: 2001;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  transition: background-color 0.3s ease;
}

.prev { left: 20px; }
.next { right: 20px; }
.prev:hover, .next:hover { background-color: rgba(255, 255, 255, 1); }

/* Modal Close Button */
.btn-large-close {
  background-color: #001f59;
  color: white;
  padding: 10px 20px;
  border-radius: 5px;
  font-size: 1.2rem;
  cursor: pointer;
  text-decoration: none;
  transition: background-color 0.3s;
  border: none;
  margin-top: 15px;
}

.btn-large-close:hover { background-color: #ff9800; }

/* Contact Section */
.contact-section {
  padding: 100px 50px;
  background-color: #f0f0f0;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  position: relative;
  z-index: 1;
  height: auto;
}

.contact-container {
  display: flex;
  flex-direction: row;
  justify-content: space-around;
  width: 100%;
  max-width: 1200px;
}

.contact-image img { max-width: 500px; height: auto; }

.contact-form {
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 50%;
  padding: 20px;
}

.form-group { margin-bottom: 20px; }
.form-group label { display: block; margin-bottom: 5px; font-size: 1.1rem; }

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 5px;
  font-size: 1rem;
  outline: none;
}

.form-group textarea { resize: none; height: 150px; }

.submit-btn {
  background-color: #001f59;
  color: white;
  padding: 12px 20px;
  border: none;
  border-radius: 5px;
  font-size: 1.1rem;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.submit-btn:hover { background-color: #ff9800; }

/* Responsive */
@media (max-width: 768px) {
  .navbar { display: flex; justify-content: center; }
  .about-section {
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-top: 50px;
    padding: 20px;
  }
  .about-image { margin: 0 0 20px 0; width: 80%; max-width: 300px; }
  .about-text { max-width: 90%; }
  .portfolio-section { text-align: center; padding: 20px; }

  .grid-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
  }

  .contact-section { flex-direction: column; align-items: center; text-align: center; padding: 20px; }
  .contact-image img { max-width: 300px; width: 100%; height: auto; }
  .contact-container { flex-direction: column; align-items: center; }
  .contact-form, .contact-image { width: 90%; max-width: 400px; }
}
