:root {
  --offwhite: #f5f5f5;
  --off-black: #0B1D28;
  --dark-blue: #4472c4;
  --blue: #698ecf;
  --light-blie: #b5c7e7;

  --bg-color: #f5f5f5;
  --text-color: #0B1D28;
  --header-color: #698ecf;
  --link-color: #698ecf;
  --nav-active-text-color: #f5f5f5;
  --nav-active-bg-color: #4472c4;
  --border-color: #698ecf;
}

body.dark-mode {
  --bg-color: #0B1D28;
  --text-color: #f5f5f5;
  --header-color: #b5c7e7;
  --link-color: #b5c7e7;
  --nav-active-text-color: #0B1D28;
  --nav-active-bg-color: #b5c7e7;
  --border-color: #b5c7e7;
}
  
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: Verdana, sans-serif;
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-color);
  transition: background-color 0.5s ease;
}

h1, h2 {
  color: var(--header-color);
}

h1 {
  font-size: 2rem;
}

a {
  color: var(--link-color);
}

hr {
  border-top: 1.5px dashed var(--border-color);
  margin: 2rem 0 0 0;
}

nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: var(--bg-color);
  padding: 0.75rem 0;
  border-bottom: 2.5px solid var(--border-color);
  z-index: 999;
  transition: background-color 0.5s ease;
}

#navbar {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  align-content: center;
  width: 90%;
  max-width: 850px;
  margin: 0 auto;
  font-size: 0.95rem;
}

.nav-list {
  list-style-type: none;
}

.nav-link {
  padding: 0.5rem 0.5rem;
  border-radius: 5px;
  margin: 0 0.1rem;
  text-decoration: none;
}

.active {
  background-color: var(--nav-active-bg-color);
  color: var(--nav-active-text-color);
  font-weight: bold;
  transition: background-color 0.5s ease, color 0.5s ease;
}

.nav-link:hover:not(.active) {
  background-color: rgba(68,114,196,0.5);
  color: var(--text-color);
}

.nav-link:not(.active) {
  color: var(--text-color);
}

button {
  border-style: none;
  background-color: var(--bg-color);
  cursor: pointer;
}

#themeIcon {
  font-size: 1rem;
}

main {
  width: 90%;
  max-width: 850px;
  margin: 6rem auto 3rem auto;
  padding: 0 1rem;
}

#name {
  margin-bottom: 1rem;
}

.bio {
  text-align: justify;
  color: var(--text-color);
  transition: color 0.3s ease;
}

#about-me {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

#img {
  border-style: none;
  border-radius: 45%;
  width: 225px;
  height: 225px;
  border: 3px outset var(--blue);
}

#img-icons {
  margin: 0 0 4rem 2.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
}

.icon-btn:hover {
  color: rgba(68,114,196,0.5);
}

.fab, .fa {
  margin: 1rem 0.4rem;
  font-size: 2rem; 
}

#updates, #publications {
  margin: 2rem 0 1rem 0;
}

#updates-table {
  margin: 1rem 0 0 0;
}

.date {
  font-style: italic;
  color: var(--header-color);
  transition: color 0.3s ease;
}

.info {
  color: var(--text-color);
  transition: color 0.3s ease;
  padding-left: 1rem;
}

td {
  vertical-align: top;
}

td:not(.nospace){
  padding-top: 1.25rem;
}

#footer-text {
  text-align: center;
  border-top: 2.5px solid var(--border-color);
  margin: 0 auto;
  padding: 1rem 0;
  color: var(--text-color);
  transition: color 0.3s ease;
}

@media (max-width: 768px) {
  #about-me {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  #img-icons {
    margin: 2rem 0 0 0;
  }

  #img {
    width: 175px;
    height: 175px;
  }

  .bio {
    font-size: 0.95rem;
    line-height: 1.5;
  }

  #navbar {
    flex-direction: row;
    width: 100%;
    padding-right: 1rem;
  }

  .nav-link {
    font-size: 0.85rem;
  }

  h1 {
    font-size: 2rem;
  }

  #name {
  margin-bottom: -0.5rem;
  text-align: center;
  }

  #about-me {
    flex-direction: column-reverse;
  }

  .bio {
    font-size: 0.95rem;
  }

  #footer-text {
    font-size: 0.75rem;
    padding: 1rem;
  }
}

@media (max-width: 480px) {
  h1 {
    font-size: 1.55rem;
  }

  #name {
  margin-bottom: -0.50rem;
  }

  #about-me {
    flex-direction: column-reverse;
  }

  .bio {
    font-size: 0.85rem;
  }

  .fa, .fab {
    font-size: 1.8rem;
    margin-bottom: 1.75rem;
  }

  h2 {
    font-size: 1.4rem;
  }

  td {
    font-size: 0.85rem;
  }

  .date {
    font-weight: normal;
    font-style: italic;
    color: var(--header-color);
  }

  #footer-text {
    font-size: 0.75rem;
    padding: 1rem;
  }
}