/* General Styles */
body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  margin: 0;
  padding: 0;
  background-color: #dda3a3; /* Soft light gray background */
}

h1, h2, h3 {
  color: #333;
}

a {
  text-decoration: none;
  color: #007bff;
  transition: color 0.3s ease;
}

a:hover {
  color: #0056b3;
}

button {
  background-color: #007bff;
  color: white;
  padding: 10px 20px;
  border: none;
  cursor: pointer;
  font-size: 18px;
  border-radius: 5px;
  transition: background-color 0.3s ease, transform 0.2s ease;
}

button:hover {
  background-color: #0056b3;
  transform: scale(1.05);
}

/* Header Section */
header {
  position: relative;
  color: #f0f0f0; /* Light color for readability */
  padding: 70px 0;
  text-align: center;
  background: url('bg.png') center/cover no-repeat;
  background-size: cover; /* Ensures the image fully covers the area */
  background-position: center center; /* Centers the image within the header */
  background-attachment: fixed; /* Keeps the background fixed during scroll (parallax effect) */
  transition: background-color 0.5s ease;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.6); /* Subtle shadow for readability */
}

header .profile-img {
  border: 5px solid rgb(16, 7, 7);
  margin-bottom: 20px;
  transition: transform 0.3s ease;
}

header .profile-img:hover {
  transform: scale(1.1);
}

header h1 {
  font-size: 36px;
  margin-bottom: 10px;
}

header p {
  font-size: 18px;
  margin-top: 10px;
}

/* Navigation Section */
nav {
  background-color: #0066cc; /* New color */
  padding: 15px 0;
  transition: background-color 0.3s ease;

}

nav:hover {
  background-color: #6f1d1d;
}

.navbar-nav {
  display: flex;
  align-items: center;
  width: 100%;
}

nav ul {
  list-style: none;
  display: flex; /* Align items horizontally */
  justify-content: space-evenly; /* Space items evenly */
  width: 100%;
  padding-left: 0;
}

nav ul li {
  display: inline;
  margin: 0 20px;
}

nav ul li a {
  text-decoration: none;
  color: #635050;
  font-size: 1.2rem;
  transition: color 0.3s ease, transform 0.3s ease;
}

nav ul li a:hover {
  color: #f4f4f4;
  transform: translateY(-3px);
}

/* About Me Section */
#personal-details {
  padding: 60px 0;
  background-color: #ffffff; /* White background for a clean look */
}

.details-box {
  display: flex;
  align-items: center; /* Align items vertically in the center */
  justify-content: flex-start; /* Align the items to the left (default behavior) */
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1); /* Soft shadow for the box */
  padding: 20px;
  border-radius: 10px; /* Rounded corners */
  background-color: #f9f9f9; /* Light gray background for the details box */
}

.image-container {
  flex: 1;
  max-width: 150px; /* Ensure the image doesn't take up too much space */
  margin-right: 20px; /* Space between the image and details */
}

.profile-img2 {
  width: 100%;
  height: 100%; /* Ensure it is square by making width and height equal */
  object-fit: cover; /* Ensures the image covers the square area */
  border: 3px solid #007bff; /* Border color matching the links */
  transition: transform 0.3s ease, border 0.3s ease; /* Transition effect for transform and border */
}

.profile-img2:hover {
  transform: scale(1.05); /* Slightly enlarge the image when hovered */
  border-color: #0056b3; /* Change border color on hover */
}

.details {
  flex: 2;
  font-size: 18px;
}

.details p {
  margin: 10px 0;
}

.details a {
  color: #007bff;
  transition: color 0.3s ease;
}

.details a:hover {
  color: #0056b3;
}

/* Responsive adjustments */
@media screen and (max-width: 768px) {
  .details-box {
    flex-wrap: nowrap; /* Keep the text and image in the same row */
    flex-direction: row; /* Ensure a single row layout */
    align-items: center; /* Align items vertically in the center */
    justify-content: space-between; /* Space between text and image */
  }

  .details {
    font-size: 16px; /* Adjust text size for smaller screens */
    text-align: left; /* Ensure text is left-aligned */
  }

  .image-container {
    margin-left: 10px; /* Adjust spacing between image and text */
    max-width: 100px; /* Reduce image size for smaller screens */
  }
  nav ul {
      flex-direction: column; /* Stack navigation items vertically on smaller screens */
      align-items: left; /* Center align the navigation items */
  }

  #header {
    flex: 0 0 100%; /* Stacks the columns on smaller screens */
    background: url(bg.png);
  }
  header h1 {
      font-size: 28px; /* Adjust font size for smaller screens */
  }

  header p {
      font-size: 16px; /* Adjust font size for smaller screens */
  }

  button {
      font-size: 16px; /* Adjust font size for smaller screens */
      padding: 8px 16px;
  }

  .project-card {
      width: 100%; /* Full width on small screens */
  }

  .container {
      padding-left: 15px;
      padding-right: 15px;
  }

  .row {
      flex-direction: column;
  }
}

/* Career Objective Section */
#career-objective {
  background-color: #e9ecef; /* Light gray background */
  padding: 60px 0;
  transition: background-color 0.5s ease;
}

#career-objective p {
  font-size: 18px;
  line-height: 1.7;
}

#career-objective:hover p {
  font-size: 20px;
}

/* Education Section */
#education {
  padding: 60px 0;
  background-color: #f8f9fa; /* Very light gray background */
}

#education ul {
  list-style-type: none;
  padding-left: 0;
}

#education ul li {
  font-size: 18px;
  margin-bottom: 10px;
}

#education ul li:hover {
  transform: scale(1.05);
}

/* Experience Section */
#experience {
  background-color: #f1f1f1; /* Soft gray background */
  padding: 60px 0;
}

.job {
  margin-bottom: 30px;
  transition: transform 0.3s ease;
}

.job:hover {
  transform: scale(1.05);
}

.job h3 {
  font-size: 24px;
}

.job p {
  font-size: 18px;
  margin-bottom: 10px;
}

.job ul {
  list-style-type: square;
  margin-left: 20px;
}

/* Projects Section */
#projects {
  padding: 60px 0;
  background-color: #fcfcfce0; /* White background for a fresh look */
}

.project-row {
  display: flex;
  flex-wrap: wrap; /* Allows cards to wrap on smaller screens */
  gap: 20px; /* Space between project cards */
  justify-content: space-between; /* Distributes the cards evenly */
}

.project-card {
  background-color: white;
  padding: 15px;
  border-radius: 10px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  margin-bottom: 30px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  width: 48%; /* Each card takes up about half the width of the container */
}

.project-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

.project-card img {
  max-width: 70%;
  height: auto;
  transition: transform 0.3s ease;
}

.project-card img:hover {
  transform: scale(1.05);
}

/* Skills Section 
#skills {
  padding: 60px 0;
  background-color: #f9f9f9; /* Subtle light gray background 
} */
/*
#skills h2 {
  margin-bottom: 20px;
}

#skills .row {
  display: flex;
  justify-content: space-between;
}

#skills .col-md-4 {
  flex: 0 0 32%;
  background-color: #ffffff;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  text-align: center;
  margin-bottom: 20px;
}

#skills .col-md-4 h3 {
  font-size: 24px;
}

#skills .col-md-4 p {
  font-size: 16px;
}

#skills .col-md-4:hover {
  transform: scale(1.05);
}
  */

 /* Skills Section */
#skills {
  padding: 60px 0;
  background-color: #f9f9f9; /* Subtle light gray background */
}

#skills h2 {
  margin-bottom: 20px;
}

#skills .row {
  display: flex;
  justify-content: space-between;
}

#skills .col-md-4 {
  flex: 0 0 32%;
  background-color: #ffffff;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

#skills .col-md-4:hover {
  transform: translateY(-10px);
}

#skills p {
  font-size: 18px;
  color: #333;
}

/* Contact Section */
#contact {
  padding: 60px 0;
  background-color: #e9ecef; /* Light gray background for contact */
}

#contact form {
  max-width: 600px;
  margin: 0 auto;
}

#contact input, #contact textarea {
  width: 100%;
  padding: 10px;
  margin: 10px 0;
  font-size: 18px;
  border: 1px solid #ccc;
  border-radius: 5px;
}

#contact button {
  background-color: #007bff;
  color: white;
  padding: 12px 20px;
  font-size: 18px;
  border: none;
  cursor: pointer;
  border-radius: 5px;
  transition: background-color 0.3s ease;
}

#contact button:hover {
  background-color: #0056b3;
}

/* Footer Section */
footer {
  background-color: #343a40;
  color: white;
  text-align: center;
  padding: 20px;
}

footer p {
  margin: 0;
  font-size: 14px;
}

/* Scroll Animations */
.fade-in {
  opacity: 0;
  transition: opacity 0.5s ease-in-out;
}

.fade-in.visible {
  opacity: 1;
}

/* Responsive Design */
@media only screen and (max-width: 558px) {
  .container {
      padding-left: 15px;
      padding-right: 15px;
  }
  
  #header {
    flex: 0 0 100%; /* Stacks the columns on smaller screens */
    background: url(bg.png);
  }
 nav ul {
    flex-direction: column; /* Stack items vertically */
    align-items: center; /* Center align items */
    padding: 0;
  }

  nav ul li {
    margin: 10px 0; /* Add space between items */
  }

  nav ul li a {
    font-size: 1.5rem; /* Adjust font size for better readability */
  }


  #personal-details {
    padding: 10px 0;
    background-color: #ffffff; /* White background for a clean look */
  }

  .details-box {
  flex-wrap: nowrap; /* Keep the text and image in the same row */
  flex-direction: row; /* Ensure a single row layout */
  align-items: center; /* Align items vertically in the center */
  justify-content: space-between; /* Space between text and image */
}

.details {
  font-size: 14px; /* Adjust text size for smaller screens */
  text-align: left; /* Ensure text is left-aligned */
}

.image-container {
  margin-left: 10px; /* Adjust spacing between image and text */
  max-width: 80px; /* Reduce image size for smaller screens */
}
  
 .details-box{
  padding: 6px; /* Reduce padding */
  font-size: 0.9rem; /* Reduce font size */
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); /* Softer shadow for smaller screens */
 }
  
  .image-container {
    flex: 1;
    max-width: 150px; /* Ensure the image doesn't take up too much space */
    margin-right: 10px; /* Space between the image and details */
  }
  
  .profile-img2 {
    width: 50%;
    height: 50%; /* Ensure it is square by making width and height equal */
    object-fit: cover; /* Ensures the image covers the square area */
  }


  .row {
      flex-direction: row;
      gap: 20px; /* Adds space between columns when stacked vertically */
  }

  #skills .col-md-4 {
      flex: 0 0 100%; /* Stacks the columns on smaller screens */
  }

  #contact form {
      max-width: 90%; /* Allow the form to use more space on smaller devices */
  }

  #contact input, #contact textarea, #contact button {
      font-size: 16px; /* Slightly smaller font size for mobile */
  }

  footer p {
      font-size: 12px; /* Slightly smaller text for the footer */
  }
}

@media only screen and (max-width: 450px) {
  /* Further tweaks for very small screens like phones */

  nav ul {
    flex-direction: column; /* Stack items vertically */
    align-items: center; /* Center align items */
    padding: 0;
  }

  nav ul li {
    margin: 10px 0; /* Add space between items */
  }

  nav ul li a {
    font-size: 1.5rem; /* Adjust font size for better readability */
  }



  .details-box {
    flex-direction: row; /* Maintain text on the left and image on the right */
    align-items: center; /* Keep vertical alignment consistent */
  }

  .details {
    font-size: 10px; /* Adjust text size for small screens */
    text-align: left; /* Text remains aligned to the left */
  }

  .image-container {
    max-width: 640px; /* Slightly reduce image size for smaller screens */
    max-height: 500px;
    margin-left: 50px; /* Maintain spacing between text and image */
  }

  .profile-img2 {
    border: 2px solid #007bff; /* Slightly thinner border for small screens */
  }

  #skills h2 {
      font-size: 24px; /* Make headings smaller on mobile */
  }

  #skills .col-md-4 {
      flex: 0 0 100%; /* Stacks columns to full width */
      padding: 15px; /* Reduce padding to make room for content */
  }


  .project-card {
    width: 48%; /* Two cards per row */
    margin-bottom: 10px; /* Reduce margin for better spacing */
  }

  .project-row {
    gap: 10px; /* Reduce gap between cards for smaller screens */
  }

  #projects {
    padding: 30px 10px; /* Reduce padding for smaller screens */
  }


  #contact input, #contact textarea, #contact button {
      padding: 8px; /* Adjust input padding for smaller screens */
  }

  #contact form {
      max-width: 100%; /* Use full width for form elements on small screens */
  }

  footer p {
      font-size: 10px; /* Small font size for the footer on phones */
  }
}

@media only screen and (max-width: 350px) {
  /* Very small screens like phones with 350px resolution */

  .navbar-nav {
    flex-direction: column; /* Stack items vertically */
    align-items: flex-start; /* Align items to the start of the container */
  }

  .details-box {
    flex-direction: row; /* Keep text on the left and image on the right */
    align-items: center; /* Ensure vertical alignment */
  }

  .details {
    font-size: 8px; /* Further reduce text size for smaller screens */
    text-align: left; /* Keep text aligned to the left */
  }

  .image-container {
    max-width: 120px; /* Reduce image size for smaller screens */
    max-height: 120px; /* Maintain aspect ratio and fit the screen */
    margin-left: 15px; /* Slightly reduce spacing between text and image */
  }

  .profile-img2 {
    border: 1px solid #007bff; /* Thinner border for smaller screens */
  }

  #skills h2 {
    font-size: 18px; /* Smaller headings for skills section */
  }

  #skills .col-md-4 {
    flex: 0 0 100%; /* Stack skill columns in a single row */
    padding: 10px; /* Further reduce padding for compactness */
  }

  .project-card {
    width: 100%; /* Each card takes up the full width */
    margin-bottom: 8px; /* Reduce margin between cards */
  }

  .project-row {
    gap: 8px; /* Smaller gap between project cards */
  }

  #projects {
    padding: 20px 5px; /* Smaller padding for the projects section */
  }

  #contact input, #contact textarea, #contact button {
    padding: 6px; /* Adjust input and button padding for smaller screens */
    font-size: 10px; /* Adjust font size for inputs */
  }

  #contact form {
    max-width: 100%; /* Use full width for form elements on small screens */
  }

  footer p {
    font-size: 8px; /* Smaller font size for the footer */
  }
}
