/* Shared styles for every page */

:root {
  --text: #222;
  --muted: #666;
  --link: #1a5fa8;
  --border: #ddd;
  --nav-bg: #f8f8f8;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--text);
  background: #fff;
}

body.grey { background: #f2f2f2; }

a { color: var(--link); }
a:hover { text-decoration-thickness: 2px; }

img { max-width: 100%; height: auto; }

/* Navbar */
.site-header {
  background: var(--nav-bg);
  border-bottom: 1px solid var(--border);
}

.site-header nav {
  max-width: 60rem;
  margin: 0 auto;
  padding: 0.75rem 1rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1.5rem;
}

.site-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
}

.nav-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.25rem;
}

.nav-links a {
  color: var(--muted);
  text-decoration: none;
}

.nav-links a:hover {
  color: var(--text);
  text-decoration: underline;
}

/* Main content */
main {
  max-width: 50rem;
  margin: 0 auto;
  padding: 1.5rem 1rem 2rem;
}

h1 { font-size: 2rem; line-height: 1.2; margin: 0.5rem 0 1.5rem; }
h2 { font-size: 1.4rem; margin: 2rem 0 0.75rem; }

/* Home page */
.portrait {
  float: left;
  width: 300px;
  margin: 3px 1.25rem 0.75rem 0;
  border: 1px solid #000;
}

.icon-container {
  clear: both;
  display: flex;
  gap: 1rem;
  padding-top: 1rem;
}

.icon-container a { color: var(--text); }
.icon-container svg { width: 2rem; height: 2rem; fill: currentColor; }

@media (max-width: 36rem) {
  .portrait { float: none; display: block; margin: 0 0 1rem; }
}

/* Publications */
.pub-list li { margin-bottom: 0.9rem; }
.pub-list .venue { font-style: italic; }

/* Carried over from the old mystyle.css */
div.nicebackcolor { background-color: #FFFFF3; }
div.a { text-indent: 10px; }
div.b { line-height: 2; }
p.indent { padding-left: 25px; }

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.9rem;
  text-align: center;
  padding: 1.25rem 1rem;
}
