body {
  margin: 0;
  font-family: "Lato", Arial, sans-serif;
  background-color: #cfcfcf;
  color: #222;
}

/* Whole page layout: sidebar + main content */
.page-layout {
  display: flex;
  /* align-items: flex-start; */
  max-width: 1100px;
  margin: 60px auto;
  padding: 0 30px;
  gap: 30px;
}

/* Left sidebar */
.sidebar {
  width: 220px;
  flex-shrink: 0;

  background-color: rgb(235, 235, 235);
  border-radius: 12px;
  padding: 28px 24px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);

  position: sticky;
  top: 30px;
  align-self: flex-start;

  /* New: lets us put dark mode button at the bottom */
  display: flex;
  flex-direction: column;
  min-height: calc(100vh - 120px);
}

.sidebar-name {
  margin-top: 0;
  margin-bottom: 24px;
  font-size: 24px;
  font-weight: bold;
}

.sidebar a {
  display: block;
  padding: 4px 0;
  color: #012169;
  text-decoration: none;
  font-weight: bold;
  font-size: 20px;
}

.sidebar a:hover,
.sidebar a.active {
  color: #222;
}

.sidebar hr {
  border: none;
  border-top: 1px solid #ddd;
  margin: 18px 0;
}


/* Dark mode button */
.dark-mode-button {
  display: inline-block;
  margin-top: 10px;
  padding: 8px 14px;

  background-color: #222;
  color: #cfcfcf;

  border: none;
  border-radius: 10px;

  font-family: inherit;
  font-size: 20px;
  font-weight: bold;

  cursor: pointer;
  text-align: center;

  transition: background-color 0.2s ease, transform 0.2s ease;
}

.dark-mode-button:hover {
  background-color: #444;
  transform: translateY(-2px);
}

html.dark-mode .dark-mode-button {
  background-color: #cfcfcf;
  color: rgb(0, 0, 0);
}

html.dark-mode .dark-mode-button:hover {
  background-color: rgb(227, 227, 227);
  /* transform: translateY(-4px); */
  text-decoration: none;
}

/* Main content box */
.container {
  flex: 1;
  max-width: 750px;
  padding: 40px;
  background-color: rgb(235, 235, 235);
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

/* Optional hover effect */
.sidebar:hover,
.container:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

h1 {
  margin-top: 0;
  font-size: 35px;
}

h2 {
  margin-top: 0px;
  font-size: 22px;
  font-weight: normal;
  color: #666;
}


p {
  font-size: 18px;
  line-height: 1.6;
  margin-top: 0;
  margin-bottom: 10px;
}


li {
  font-size: 18px;
  line-height: 1.6;
  margin-bottom: 12px;
}

ul ul {
  margin-top: 4px;
  margin-bottom: 4px;
}

ul ul li {
  margin-bottom: 2px;
}

a {
  color: #012169;
  text-decoration: none;
  font-weight: normal;
}

a:hover {
  text-decoration: underline;
}

/* This only affects the ZONES button on your main website pages */
.zones-button-row {
  text-align: center;
}

.zones-button {
  display: inline-block;
  padding: 2px 8px;
  background-color: #cfcfcf;
  color: #000000;
  text-decoration: none;
  border-radius: 10px;
  font-family: Consolas, monospace;
  font-size: 20px;
  transition: transform 0.2s ease, background-color 0.2s ease;
}

.zones-button:hover {
  background-color: #444;
  color: white;
  text-decoration: none;
  transform: translateY(-2px);
}

html.dark-mode .zones-button {
  background-color: #121212;
  color: #cfcfcf;
}

html.dark-mode .zones-button:hover {
  background-color: #cfcfcf;
  color: #000000;
}



/* Publications page */
.publication-list {
  padding-left: 24px;
}

.publication-list li {
  margin-bottom: 22px;
}

.profile-photo {
  display: block;
  width: auto;
  height: auto;
  max-width: 200px;
  margin-bottom: 20px;
  border-radius: 12px;
}


/* Dark mode colors */

.profile-photo-dark {
  display: none;
}

html.dark-mode .profile-photo-light {
  display: none;
}



html.dark-mode .profile-photo-dark {
  display: block;
}

html.dark-mode body {
  background-color: #121212;
  color: #cfcfcf;
}

html.dark-mode .container,
html.dark-mode .sidebar {
  background-color: #1e1e1e;
  color: #cfcfcf;
  box-shadow: 0 4px 16px rgba(255, 255, 255, 0.06);
}

html.dark-mode a:hover {
  color: #cfcfcf;
}

html.dark-mode h1 {
  color: #cfcfcf;
}

html.dark-mode h2,
html.dark-mode .sidebar-name {
  color: #bbbbbb;
}

html.dark-mode a {
  /* color: #0058F8; */
  /* color: #afa8d6 */
  color: #9b91d6; 
}

html.dark-mode .sidebar a.active {
  color: #cfcfcf;
}

html.dark-mode .sidebar hr {
  border-top: 1px solid #444444;
}


/* copy button of email */
.copy-email-btn {
  margin-left: 8px;
  padding: 3px 8px;
  border: none;
  border-radius: 6px;
  background: rgb(235, 235, 235);
  color: #666;
  cursor: pointer;
  font-size: 18px;
}

html.dark-mode .copy-email-btn {
  background: #1e1e1e
}


.copy-email-btn:hover {
  background: #f0f0f0;
}

html.dark-mode .copy-email-btn:hover {
  background: #252525
}

#copy-status {
  margin-left: 6px;
  color: #555;
  font-size: 0.9em;
}

/* Mobile version */
@media (max-width: 800px) {
  .page-layout {
    flex-direction: column;
    margin: 30px auto;
    padding: 0 20px;
  }

  .sidebar {
    width: auto;
    position: static;
  }

  .sidebar a {
    display: inline-block;
    margin-right: 16px;
  }

  .container {
    padding: 30px 24px;
  }

  h1 {
    font-size: 34px;
  }
}