:root {
  --background-color: #F1F1F1;
  --border-color: #C4C4C4;
  --hover: #444444;
  --text-primary: #444444;
  --text-hover: #ffffff;
  --focus: #6B9AFF;
  --type-book: #CE89FF;
  --type-article: #6B9AFF;
  --type-paper: #FFCA67;
}

body {
  background-color: var(--background-color);
  color: var(--text-primary);
  margin: 0;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-size: 1em;
  font-weight: normal;
  margin: 0;
}

p,
ul {
  margin: 0;
}

.top-row {
  display: grid;
  grid-template-columns: 60px 1fr;
  align-items: center;
  padding: .5em;
}

.article-grid {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
}

.article-row {
  color: var(--text-primary);
  text-decoration: none;
  display: grid;
  grid-template-columns: 60px 90px auto;
  align-items: stretch;
}

.article-row:hover {
  background-color: var(--hover);
  color: var(--text-hover);
}

.article-row,
.top-row {
  border-bottom: 1px solid var(--border-color);
}

.inner-row {
  display: grid;
  grid-template-columns: 2fr 180px 1fr;
}

.row {
  /*min-height: 2em;*/
  padding: .5em;
}

.row-spacer {
  min-height: 34.5px;
  padding: 0;
}

.cell {
  border-right: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  padding: .5em;
}

.cell-tags {
  border-right: 0;
}

/*.cell-title::after {
  content: '↗';
  padding-left: 6px;
}*/

.cell-type {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.cell-type::before {
  content: '';
  display: inline-block;
  height: 6px;
  width: 6px;
}

.type-book::before {
  border-radius: 100px;
  background-color: var(--type-book);
}

.type-article::before {
  background-color: var(--type-article);
}

.type-paper::before {
  width: 0;
  height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-bottom: 6px solid var(--type-paper);
}

/* Helpers */
.screenreader-only {
    position: absolute;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
    border: 0;
  }

@media screen and (max-width: 620px) {
  .article-row,
  .top-row {
    grid-template-columns: 1fr 2fr;
  }
  .inner-row {
    display: inline-flex;
    flex-direction: column;
  }
  .cell-year {
    display: none;
  }
  .cell-tags {
    font-style: italic;
  }
  .cell-title,
  .cell-author {
    border-right: 0;
  }
}