/* Variables for easier color customization */
:root {
  --primary-color: #007bff; /* Blue */
  --secondary-color: #005079; /* Purple */
  --background-color: #181818; /* Dark background */
  --text-color: #fff; /* Light text color */
  --accent-color: #ff5722; /* Orange */
}

/* General Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Montserrat', sans-serif;
}

/* Dark Background */
body {
  background-color: var(--background-color);
  color: var(--text-color);
  overflow-x: hidden; /* Hide horizontal scrollbar */
}

/* Header Styles */
.header {
  min-height: 80vh;
  width: 100%;
  background-image: var(--background-color); 
  background-position: center;
  background-size: cover;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

nav {
  position: fixed; /* Fix navigation to the top */
  top: 0;
  left: 0;
  width: 100%;
  background: rgba(0, 0, 0, 0.8); /* Semi-transparent background */
  padding: 15px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 10; /* Ensure nav is on top */
}

nav img {
  width: 50px;
}

.nav-links {
  flex: 1;
  text-align: right;
}

.nav-links ul li {
  list-style: none;
  display: inline-block;
  padding: 8px 12px;
  position: relative;
  margin-left: 20px; /* Add some space between links */
}

.nav-links ul li a {
  color: var(--text-color);
  text-decoration: none;
  font-size: 13px;
  transition: color 0.3s ease-in-out;
}

.nav-links ul li:hover a {
  color: var(--primary-color);
}

.nav-links ul li::after {
  content: '';
  width: 0%;
  height: 2px;
  background: var(--primary-color);
  display: block;
  margin: auto;
  transition: width 0.3s ease-in-out;
}

.nav-links ul li:hover::after {
  width: 100%;
}

.text-box {
  text-align: center;
  z-index: 1; /* Ensure text is on top */
}

.text-box h1 {
  font-size: 50px;
  color: var(--primary-color);
  text-shadow: 0 2px 5px rgba(0, 0, 0, 0.5); /* Add a subtle shadow */
  margin-bottom: 20px;
}

.text-box p {
  font-size: 20px;
  color: var(--text-color);
  margin: 10px 0px 40px;
}

/* About Section */
#about {
  width: 100%;
  padding: 100px 0;
  background-color: #282828; /* Darker background for About section */
  color: #fff;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  text-align: center;
  min-height: 100vh;
  position: relative;
  overflow: hidden;
}

/* Main Container */
.main {
  width: 90%;
  max-width: 1200px;
  background-color: #333;
  border-radius: 15px;
  padding: 40px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  position: relative;
}

/* Header Section */
.about-text h2 {
  font-size: 48px;
  font-weight: 700;
  color: var(--primary-color); /* Primary color for the heading */
  margin-bottom: 20px;
  text-transform: uppercase;
  letter-spacing: 3px;
  text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.2);
  font-family: 'Montserrat', sans-serif;
}

/* Paragraph Section */
.about-text p {
  font-size: 20px;
  line-height: 1.8;
  color: #aaa;
  max-width: 700px;
  margin: 20px auto 40px;
  font-family: 'Lora', serif;
  text-align: justify;
  margin-top: 20px;
}

/* Image Grid Section */
.image-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
}

.image-grid img {
  width: 200px;
  height: 200px;
  object-fit: cover;
  border-radius: 10px;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
}

.image-grid img:hover {
  transform: scale(1.05);
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.2);
}

/* Extra Styling for Responsive Design */
@media (max-width: 768px) {
  #about {
    padding: 80px 0;
  }

  .about-text h2 {
    font-size: 36px;
  }

  .about-text p {
    font-size: 18px;
  }

  .image-grid img {
    width: 160px;
    height: 160px;
  }
}





/* Skills Section */
.skills-section {
  padding: 50px 0;
  text-align: center;
}

.skills-section h2 {
  font-size: 3rem;
  margin-bottom: 30px;
  color: #007bff; /* Blue */
}

.skills-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
}

.skill-item {
  margin: 20px;
  width: 200px;
  text-align: center;
}

.skill-item i {
  font-size: 4rem;
  color: #007bff; /* Blue */
  margin-bottom: 20px;
}

.skill-item h3 {
  font-size: 1.5rem;
  margin-bottom: 10px;
}

.skill-item p {
  color: #aaa;
  font-size: 1rem;
}

/* Portfolio Section */
/* Portfolio Section */
.portfolio-sec {
  background: var(--background-color);
  width: 100%;
  padding: 100px 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.title h2 {
  font-size: 36px;
  color: var(--primary-color);
  margin-bottom: 40px;
  text-align: center;
}

.portfolio-container {
  width: 80%;
  max-width: 1200px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  grid-gap: 30px;
  justify-items: center;
}

.portfolio-box {
  width: 100%;
  perspective: 1000px; /* 3D perspective */
}

.card {
  width: 100%;
  height: 300px;
  background-color: #282828; /* Darker background for cards */
  border-radius: 10px;
  box-shadow: 0 8px 15px rgba(0, 0, 0, 0.3); /* Shadow effect */
  transform-style: preserve-3d;
  transition: transform 0.5s ease, box-shadow 0.5s ease;
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.card:hover {
  transform: rotateY(20deg);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4); /* Stronger shadow on hover */
}

.card-front,
.card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  border-radius: 10px;
}

.card-front {
  transform: rotateY(0deg);
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  color: #fff;
}

.card-front i {
  font-size: 50px;
  margin-bottom: 20px;
}

.card-front h5 {
  font-size: 20px;
  font-weight: 500;
}

.card-back {
  transform: rotateY(180deg);
  background-color: var(--primary-color);
  color: #fff;
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
}

.card-back .portfolio-p {
  font-size: 14px;
  text-align: center;
  margin-bottom: 20px;
}

.card-back .button {
  background-color: #fff;
  color: var(--primary-color);
  padding: 10px 20px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: 500;
  transition: background-color 0.3s ease;
}

.card-back .button:hover {
  background-color: var(--primary-color);
  color: #fff;
}

@media (max-width: 768px) {
  .portfolio-container {
    width: 100%;
    padding: 0 20px;
  }

  .title h2 {
    font-size: 28px;
  }
}


/* Top Projects Section */
.top-projects-sec {
  background: var(--background-color);
  padding: 80px 0;
  text-align: center;
}

.top-projects-sec .title h2 {
  font-size: 36px;
  color: var(--primary-color);
  margin-bottom: 40px;
}

.projects-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 30px;
  justify-items: center;
}

.project-box {
  width: 100%;
  display: flex;
  justify-content: center;
}

.project-card {
  background-color: #282828;
  border-radius: 10px;
  padding: 20px;
  box-shadow: 0 8px 15px rgba(0, 0, 0, 0.3);
  width: 100%;
  max-width: 350px;
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4);
}

.project-card h5 {
  font-size: 24px;
  color: var(--primary-color);
  margin-bottom: 15px;
}

.project-card p {
  font-size: 16px;
  color: #fff;
  margin-bottom: 20px;
}

.project-card .button {
  background-color: var(--primary-color);
  color: #fff;
  padding: 10px 20px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: 500;
  transition: background-color 0.3s ease;
}

.project-card .button:hover {
  background-color: #fff;
  color: var(--primary-color);
}

/* Responsive Design */
@media (max-width: 768px) {
  .top-projects-sec .title h2 {
    font-size: 28px;
  }

  .project-card h5 {
    font-size: 20px;
  }

  .project-card p {
    font-size: 14px;
  }
}


/* Contact Section */
.contact {
  min-height: 50vh;
  width: 100%;
  background: var(--background-color);
  display: flex;
  justify-content: center;
  align-items: center;
  padding-bottom: 50px;
}

.container {
  width: 85%;
  background: #282828; /* Slightly darker background for form */
  border-radius: 30px;
  padding: 25px 5px 35px 35px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.container .content {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.container .content .left-side {
  width: 25%;
  height: 100%;
  position: relative;
}

.content .left
.left-side::before {
  content: '';
  position: absolute;
  height: 70%;
  width: 2px;
  right: -15px;
  top: 50%;
  transform: translateY(-50%);
  background: #444;
}

.container .content .left-side .address {
  margin: 14px;
  text-align: left;
}

.container .content .left-side .address i {
  font-size: 25px;
  color: var(--primary-color);
}

.container .content .left-side .address .topic {
  font-size: 20px;
  color: var(--text-color);
  margin-bottom: 10px;
  font-weight: bold;
}

.container .content .left-side .address .text-one,
.container .content .left-side .address .text-two {
  font-size: 14px;
  color: #aaa;
}

.container .content .right-side {
  width: 70%;
  height: 90%;
}

.content .right-side .message {
  font-size: 23px;
  font-weight: 600;
  color: var(--text-color);
  font-weight: bold;
}

.right-side .input-box {
  height: 35px;
  width: 80%;
  margin: 12px 0;
}

.right-side .input-box input,
.right-side .input-box textarea {
  height: 100%;
  width: 100%;
  border: 1px solid #444; /* Darker border */
  outline: none;
  font-size: 16px;
  padding: 0 15px;
  color: #fff; /* White text in inputs */
  background: #333; /* Darker input background */
  border-radius: 6px;
  resize: none;
}

.right-side .message-box {
  min-height: 120px;
}

.right-side .input-box textarea {
  padding-top: 6px;
}

.right-side .button {
  display: inline-block;
  margin-top: 8px;
}

.right-side .button input[type="button"] {
  color: #fff;
  font-size: 18px;
  outline: none;
  border: none;
  padding: 8px 16px;
  border-radius: 50px;
  background: var(--primary-color);
  cursor: pointer;
  transition: all 0.2s ease;
}

.button input[type="button"]:hover {
  background: var(--secondary-color);
}

@media (max-width: 700px) {
  .container {
    width: 90%;
    padding: 30px 40px 40px 35px;
  }

  .container .content .right-side {
    width: 75%;
    margin-left: 55px;
  }
}

@media (max-width: 820px) {
  .container {
    margin: 40px 0;
    height: 100%;
  }

  .container .content {
    flex-direction: column-reverse;
  }

  .container .content .left-side {
    width: 100%;
    flex-direction: row;
    margin-top: 40px;
    justify-content: center;
    flex-wrap: wrap;
  }

  .container .content .left-side::before {
    display: none;
  }

  .container .content .right-side {
    width: 100%;
    margin-left: 0;
  }
}

/* Footer Styles */
footer {
  position: relative;
  width: 100%;
  background: var(--background-color);
  padding: 40px 0; /* Add padding to footer */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

footer p:nth-child(1) {
  font-size: 20px;
  color: var(--text-color);
  margin-bottom: 10px;
  font-weight: bold;
}

footer p:nth-child(2) {
  font-size: 15px;
  color: #aaa;
  width: 500px;
  text-align: center;
  line-height: 26px;
  margin: 20px 05px;
}

.social {
  display: flex;
}

.social a {
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary-color);
  border-radius: 50%;
  margin: 0 10px; /* Increase spacing between icons */
  color: #fff;
  text-decoration: none;
  font-size: 15px;
  transition: transform 0.3s ease-in-out;
}

.social a:hover {
  transform: scale(1.2);
}

/* Responsive Design */
@media (max-width: 768px) {
  .text-box h1 {
    font-size: 36px;
  }

  .text-box p {
    font-size: 16px;
  }

  .nav-links ul li {
    display: block;
  }

  .nav-links {
    position: absolute;
    background: var(--background-color);
    height: 100vh;
    width: 200px;
    top: 0;
    right: 0;
    text-align: left;
    z-index: 2;
    transform: translateX(100%);
    transition: transform 0.3s ease-in-out;
  }

  .nav-links.active {
    transform: translateX(0);
  }
}

/* Mobile Responsive Design */
@media (max-width: 768px) {
  /* General Adjustments */
  body {
    overflow-x: hidden; /* Prevent horizontal scrolling */
  }

  /* Header Section */
  .header {
    min-height: 60vh; /* Reduce height for mobile */
  }

  .text-box h1 {
    font-size: 36px; /* Smaller font size for mobile */
  }

  .text-box p {
    font-size: 16px; /* Smaller font size for mobile */
  }

  .hamburger {
    display: none; /* Hidden by default */
    cursor: pointer;
    z-index: 11; /* Ensure it's above other elements */
  }
  
  .hamburger span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--text-color);
    margin: 5px 0;
    transition: all 0.3s ease-in-out;
  }
  
  /* Mobile Navigation Menu */
  @media (max-width: 768px) {
    .hamburger {
      display: block; /* Show hamburger on small screens */
    }
  
    .nav-links {
      position: fixed;
      top: 0;
      right: -200px; /* Hide off-screen */
      width: 200px;
      height: 100vh;
      background: rgba(0, 0, 0, 0.9); /* Dark background */
      transition: right 0.3s ease-in-out;
      z-index: 10;
    }
  
    .nav-links.active {
      right: 0; /* Show menu */
    }
  
    .nav-links ul li {
      display: block; /* Stack menu items vertically */
      margin: 20px 0;
      text-align: center;
    }
  
    .nav-links ul li a {
      font-size: 18px; /* Larger font for mobile */
    }
  }

  /* Hamburger Animation */
.hamburger.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

  /* About Section */
  #about {
    padding: 50px 0; /* Reduce padding */
  }

  .about-text h2 {
    font-size: 28px; /* Smaller heading */
  }

  .about-text p {
    font-size: 16px; /* Smaller text */
  }

  .image-grid img {
    width: 150px; /* Smaller images */
    height: 150px;
  }

  /* Skills Section */
  .skills-section h2 {
    font-size: 2rem; /* Smaller heading */
  }

  .skill-item {
    width: 100%; /* Full width for skill items */
    margin: 10px 0;
  }

  /* Portfolio Section */
  .portfolio-container {
    grid-template-columns: 1fr; /* Single column layout */
    gap: 20px;
  }

  .card {
    height: 250px; /* Smaller card height */
  }

  .card-front h5 {
    font-size: 18px; /* Smaller text */
  }

  .card-back .portfolio-p {
    font-size: 12px; /* Smaller text */
  }

  /* Top Projects Section */
  .top-projects-sec .title h2 {
    font-size: 28px; /* Smaller heading */
  }

  .projects-container {
    grid-template-columns: 1fr; /* Single column layout */
  }

  .project-card {
    max-width: 100%; /* Full width */
  }

  .project-card h5 {
    font-size: 20px; /* Smaller heading */
  }

  .project-card p {
    font-size: 14px; /* Smaller text */
  }

  /* Contact Section */
  .contact {
    padding: 20px 0; /* Reduce padding */
  }

  .container {
    width: 90%; /* Full width */
    padding: 20px; /* Reduce padding */
  }

  .content {
    flex-direction: column; /* Stack content vertically */
  }

  .left-side {
    width: 100%; /* Full width */
    margin-bottom: 20px;
  }

  .right-side {
    width: 100%; /* Full width */
  }

  .right-side .input-box {
    width: 100%; /* Full width */
  }

  /* Footer Section */
  footer p:nth-child(2) {
    width: 90%; /* Adjust width for mobile */
  }

  .social a {
    margin: 0 5px; /* Reduce spacing between icons */
  }
}

/* Smaller Screens (e.g., iPhone SE) */
@media (max-width: 480px) {
  .text-box h1 {
    font-size: 28px; /* Even smaller font size */
  }

  .text-box p {
    font-size: 14px; /* Even smaller font size */
  }

  .about-text h2 {
    font-size: 24px; /* Smaller heading */
  }

  .about-text p {
    font-size: 14px; /* Smaller text */
  }

  .image-grid img {
    width: 120px; /* Smaller images */
    height: 120px;
  }

  .skills-section h2 {
    font-size: 1.5rem; /* Smaller heading */
  }

  .portfolio-container {
    gap: 10px; /* Reduce gap */
  }

  .card {
    height: 200px; /* Smaller card height */
  }

  .card-front h5 {
    font-size: 16px; /* Smaller text */
  }

  .card-back .portfolio-p {
    font-size: 10px; /* Smaller text */
  }

  .top-projects-sec .title h2 {
    font-size: 24px; /* Smaller heading */
  }

  .project-card h5 {
    font-size: 18px; /* Smaller heading */
  }

  .project-card p {
    font-size: 12px; /* Smaller text */
  }
}