/* Layout and typography adapted from Jon Barron's website template (https://github.com/jonbarron/jonbarron.github.io). */

:root {
  --text: #222;
  --muted: #666;
  --link: #1772d0;
  --link-hover: #f09228;
  --rule: #e6e6e6;
  --highlight: #fffbe0;
  --page-bg: #fff;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--page-bg);
  color: var(--text);
  font-family: 'Lato', Verdana, Helvetica, sans-serif;
  font-size: 15px;
  line-height: 1.55;
}

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

a:hover,
a:focus {
  color: var(--link-hover);
}

strong {
  font-weight: 700;
}

.page {
  max-width: 860px;
  margin: 0 auto;
  padding: 24px 20px 40px;
}

/* ---------- Header ---------- */

.intro {
  display: flex;
  align-items: center;
  gap: 32px;
}

.intro-text {
  flex: 1 1 auto;
}

.name {
  margin: 8px 0 14px;
  font-size: 34px;
  font-weight: 400;
  text-align: center;
}

.intro-text p {
  margin: 0 0 12px;
}

.links {
  text-align: center;
  margin-top: 16px;
}

.links a {
  white-space: nowrap;
}

.links .sep {
  color: #999;
  margin: 0 6px;
}

.photo {
  flex: 0 0 240px;
}

.photo img {
  width: 100%;
  border-radius: 50%;
  display: block;
}

/* ---------- Sections ---------- */

section {
  margin-top: 30px;
}

h2 {
  margin: 0 0 10px;
  font-size: 23px;
  font-weight: 400;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--rule);
}

.note {
  color: var(--muted);
  margin: 0 0 6px;
}

.callout {
  margin: 24px 0 0;
  padding: 10px 14px;
  background: #f1f7fe;
  border-left: 3px solid var(--link);
  border-radius: 4px;
}


/* ---------- News ---------- */

.news {
  list-style: none;
  padding: 0;
  margin: 0;
  max-height: 260px;
  overflow-y: auto;
}

.news li {
  display: flex;
  gap: 12px;
  padding: 3px 0;
}

.news .date {
  flex: 0 0 76px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

/* ---------- Publications ---------- */

.paper {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 16px 12px;
  border-radius: 6px;
}

.paper.highlight {
  background: var(--highlight);
}

.paper + .paper {
  margin-top: 6px;
}

.paper .thumb {
  flex: 0 0 220px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.paper .thumb img {
  max-width: 100%;
  max-height: 150px;
  border: 1px solid var(--rule);
  background: #fff;
  border-radius: 3px;
}

.paper .info {
  flex: 1 1 auto;
}

.paper-title {
  font-weight: 700;
}

.paper .authors,
.paper .venue,
.paper .paper-links,
.paper .summary {
  display: block;
  margin-top: 2px;
}

.paper .venue em {
  font-style: italic;
}


.paper .summary {
  margin-top: 6px;
  color: #444;
}

/* ---------- Experience / Education ---------- */

.entry {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 10px 12px;
}

.entry .logo {
  flex: 0 0 110px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.entry .logo img {
  max-width: 100%;
  max-height: 100%;
}

.entry .info {
  flex: 1 1 auto;
}

.entry .role {
  font-weight: 700;
}

.entry .when {
  color: var(--muted);
  float: right;
  margin-left: 12px;
}

.entry .detail {
  display: block;
  color: #444;
}

.plain-list {
  margin: 0;
  padding-left: 20px;
}

.plain-list li {
  padding: 2px 0;
}

/* ---------- Visitor globe ---------- */

/* The MapMyVisitors globe sizes itself to its parent's width. */
.visitor-globe {
  width: 190px;
  margin: 36px auto 0;
}

/* ---------- Footer ---------- */

footer {
  margin-top: 40px;
  padding-top: 12px;
  border-top: 1px solid var(--rule);
  text-align: right;
  font-size: 13px;
  color: var(--muted);
}

/* ---------- Narrow screens ---------- */

@media (max-width: 640px) {
  .intro {
    flex-direction: column-reverse;
    gap: 12px;
  }

  .photo {
    flex: 0 0 auto;
    width: 170px;
  }

  .paper,
  .entry {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .paper .thumb {
    flex: 0 0 auto;
    width: 100%;
  }

  .paper .thumb img {
    max-height: 200px;
  }

  .entry .logo {
    flex: 0 0 auto;
    justify-content: flex-start;
    height: 30px;
  }

  .entry .when {
    float: none;
    display: block;
    margin-left: 0;
  }

  .news .date {
    flex-basis: 70px;
  }
}
