/* General Styles */
body {
  font-family: 'Roboto', Arial, sans-serif;
  margin: 0;
  padding: 0;
  background-color: #f7f7f7;
  color: #333;
  line-height: 1.6;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

header {
  background-color: #fff;
  padding: 20px 0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

nav ul {
  list-style-type: none;
  padding: 0;
  margin: 0;
  display: flex;
  justify-content: center;
}

nav li {
  display: inline-block;
  margin: 0 10px;
  position: relative;
}

nav a {
  font-size: 16px;
  font-weight: bold;
  text-decoration: none;
  color: #333;
  transition: color 0.3s ease-in-out;
}

nav a:hover,
nav a:focus {
  color: #e74c3c;
  transform: scale(1.1);
}

nav a::before {
  content: "";
  position: absolute;
  width: 100%;
  height: 2px;
  background-color: #e74c3c;
  bottom: 0;
  left: 0;
  transform: scaleX(0);
  transition: transform 0.3s ease-in-out;
}

nav a:hover::before,
nav a:focus::before {
  transform: scaleX(1);
}

nav a.active {
  color: #e74c3c;
  font-weight: bold;
}

nav a.active::before {
  transform: scaleX(1);
}

.profile {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

.profile img {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  margin-right: 10px;
}

section {
  padding: 50px 0;
  text-align: center;
}

section h2 {
  font-size: 32px;
  margin-bottom: 30px;
}

section p {
  font-size: 18px;
  margin-bottom: 30px;
}

section .project {
  margin-bottom: 40px;
}

section .project h3 {
  font-size: 24px;
  margin-bottom: 10px;
}

section .project p {
  font-size: 16px;
}

section .project a {
  display: inline-block;
  padding: 10px 20px;
  background-color: #e74c3c;
  color: #fff;
  text-decoration: none;
  border-radius: 4px;
  transition: background-color 0.3s ease-in-out;
}

section .project a:hover {
  background-color: #c0392b;
}

footer {
  background-color: #333;
  color: #fff;
  padding: 20px 0;
  text-align: center;
}

footer p {
  margin: 0;
}

/* Dark Mode Styles */
body.dark-mode {
  background-color: #161616;
  color: #f7f7f7;
}

header.dark-mode {
  background-color: #222;
  color: #f7f7f7;
}

nav a.dark-mode {
  color: #f7f7f7;
}

.profile img.dark-mode {
  filter: invert(1);
}

.toggle-container {
  position: absolute;
  top: 50%;
  right: 15px;
  transform: translateY(-50%);
}

.switch {
  position: relative;
  display: inline-block;
  width: 60px;
  height: 34px;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: .4s;
  border-radius: 34px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 26px;
  width: 26px;
  left: 4px;
  bottom: 4px;
  background-color: #fff;
  transition: .4s;
  border-radius: 50%;
}

input:checked + .slider {
  background-color: #1abc9c;
}

input:checked + .slider:before {
  transform: translateX(26px);
}

/* Additional Colors for Dark Mode */
section {
  background-color: #222;
}

section h2 {
color: #f7f7f7;
}

section p {
  color: #f7f7f7;
}

section .project a {
  background-color: #1abc9c;
}

section .project a:hover {
  background-color: #16a085;
}

footer {
  background-color: #222;
}

/* Responsive Styles */
@media screen and (max-width: 768px) {
  .profile {
    flex-direction: column;
  }

  .profile img {
    margin-bottom: 10px;
  }

  .toggle-container {
    position: absolute;
    top: 15px;
    right: 15px;
    transform: none;
  }
}
