body {
  font-family: 'Times New Roman', Times, serif;
  margin: 0;
  background-color: #fefefe;
  color: #222;
  line-height: 1.6;
  transition: background-color 0.3s, color 0.3s;
}

header {
  background-color: #004080;
  color: white;
  padding: 1rem 18rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 100;
}

nav a {
  color: white;
  text-decoration: none;
  margin-left: 1.5rem;
  font-weight: 600;
  transition: color 0.3s ease;
}

nav a:hover {
  color: #ffcc00;
}

main {
  max-width: 800px;
  margin: 2rem auto;
  text-align: justify;
  padding: 0 1rem;
}

section {
  margin-bottom: 3rem;
}

h1, h2 {
  margin-top: 0;
}

footer {
  text-align: center;
  padding: 1rem;
  font-size: 0.9rem;
  color: #666;
  border-top: 1px solid #ccc;
  margin-top: 4rem;
  transition: color 0.3s;
}

body.dark {
  background-color: #121212;
  color: #ddd;
}
body.dark header {
  background-color: #1e1e1e;
  color: #ddd;
}
body.dark nav a {
  color: #ddd;
}
body.dark nav a:hover {
  color: #ffcc00;
}
body.dark footer {
  color: #999;
  border-top-color: #444;
}
body.dark .profile img {
  box-shadow: 0 0 8px rgba(255, 255, 255, 0.3);
}

.icon-gray {
  filter: brightness(0) saturate(0%) opacity(0.85);
  vertical-align: -4.5px;
}

body.dark .icon-gray {
  filter: brightness(100%) invert(1) opacity(0.8);
}

#dark-mode-toggle {
  background: none;
  border: 2px solid white;
  color: white;
  font-weight: 600;
  padding: 0.3rem 0.7rem;
  border-radius: 5px;
  cursor: pointer;
  transition: background-color 0.3s, color 0.3s;
}
#dark-mode-toggle:hover {
  background-color: white;
  color: #004080;
}

@media(max-width: 600px) {
  header {
    flex-direction: column;
    align-items: flex-start;
  }
  nav a {
    margin-left: 0;
    margin-right: 1rem;
  }
  .about-container {
    flex-direction: column;
    align-items: center;
  }
  .profile {
    align-items: center;
  }
}

.about-container {
  display: flex;
  align-items: flex-start;
  gap: 2rem;
  margin-bottom: 2rem;
}

.profile {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 200px;
}

.profile-photo {
  width: 180px;
  height: 180px;
  object-fit: cover;
  border-radius: 16px;
  box-shadow: 0 0 8px rgba(0,0,0,0.2);
  background-color: #fff;
}

.photo-info {
  text-align: center;
  margin-top: 1rem;
}

.photo-info p {
  font-style: italic;
  font-size: 0.8rem;
  margin: 0.3em 0;
}

.bio h1 {
  margin-top: 0;
}

.bio p {
  margin: 0.5em 0;
}
