:root {
  --text: #222;
  --muted: #666;
  --border: #ddd;
  --link: #2b6cb0;
  --bg: #fff;
  --side-bg: #f7f7f7;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--text);
  background: var(--bg);
  font-family: Georgia, "Times New Roman", "Noto Serif SC", "Songti SC", serif;
  font-size: 16px;
  line-height: 1.65;
}

a {
  color: var(--link);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.layout {
  width: min(1080px, calc(100% - 40px));
  margin: 34px auto 56px;
  display: grid;
  grid-template-columns: 250px 1fr;
  gap: 44px;
}

.sidebar {
  align-self: start;
  position: sticky;
  top: 24px;
  padding: 22px;
  background: var(--side-bg);
  border: 1px solid var(--border);
}

.avatar {
  width: 132px;
  height: 132px;
  margin: 0 auto 18px;
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: #fff;
  color: #111;
  font-size: 54px;
  font-weight: 700;
  font-family: "Noto Serif SC", "Songti SC", serif;
}

h1 {
  margin: 0;
  font-size: 28px;
  line-height: 1.2;
  text-align: center;
}

.name-en-inline {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 16px;
  font-weight: 400;
}

.affiliation {
  margin: 0 0 20px;
  color: #333;
  font-size: 15px;
  text-align: center;
}

.lang-toggle {
  position: fixed;
  top: 18px;
  right: 22px;
  z-index: 10;
  padding: 7px 10px;
  border: 1px solid var(--border);
  background: #fff;
  color: #333;
  cursor: pointer;
  font: inherit;
  font-size: 15px;
}

.lang-toggle:hover {
  border-color: #aaa;
}

.nav,
.contact {
  display: grid;
  gap: 6px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.contact {
  margin-top: 16px;
}

.nav a,
.contact a {
  color: #333;
  font-size: 15px;
}

.content {
  max-width: 760px;
}

section {
  margin-bottom: 30px;
}

h2 {
  margin: 0 0 12px;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--border);
  font-size: 22px;
  line-height: 1.3;
}

h3 {
  margin: 0 0 4px;
  font-size: 17px;
  line-height: 1.4;
}

p {
  margin: 0 0 12px;
}

ul {
  margin: 0;
  padding-left: 22px;
}

li {
  margin: 5px 0;
}

.plain-list {
  padding-left: 0;
  list-style: none;
}

.date {
  display: inline-block;
  min-width: 138px;
  color: var(--muted);
}

.small {
  color: var(--muted);
  font-size: 15px;
}

.entry {
  margin: 0 0 18px;
}

.entry p {
  margin-bottom: 0;
}

@media (max-width: 820px) {
  .layout {
    width: min(100% - 28px, 760px);
    margin-top: 20px;
    display: block;
  }

  .sidebar {
    position: static;
    margin-bottom: 28px;
  }

  .nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .date {
    display: block;
    min-width: 0;
  }

  .lang-toggle {
    top: 12px;
    right: 14px;
  }
}
