:root {
  --text: #222;
  --muted: #999;
  --line: #e8e8e8;
  --link: crimson;
  --page: #fafafa;
  --tile: #fff;
  --logo-bg: #f4f3f1;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--page);
  color: var(--text);
  font: 300 15px/1.4 "Helvetica Neue", Helvetica, Arial, sans-serif;
  text-transform: lowercase;
}

.all-caps { text-transform: uppercase; }

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

/* header */

header {
  text-align: center;
  padding: 48px 16px 20px;
}
header img {
  display: inline-block;
  width: 120px;
  height: 120px;
  border-radius: 8px;
}
header p { margin: 16px 0 0; line-height: 1.6; }

/* filter bar */

.filters {
  position: sticky;
  top: 0;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  padding: 12px 16px;
  background: rgba(250, 250, 250, 0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}
.filters button {
  font: inherit;
  text-transform: inherit;
  color: #555;
  background: var(--tile);
  border: 1px solid #ddd;
  border-radius: 999px;
  padding: 5px 14px;
  cursor: pointer;
}
.filters button:hover { border-color: #bbb; }
.filters button[aria-pressed="true"] { color: #fff; background: var(--text); border-color: var(--text); }

/* tiles, packed into columns by script.js */

#tiles {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  max-width: 1100px;
  margin: 24px auto 64px;
  padding: 0 16px;
  transition: opacity 0.15s;
}
#tiles.fading { opacity: 0; }

.column {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.tile {
  background: var(--tile);
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
  scroll-margin-top: 72px;
  transition: box-shadow 0.3s;
}
.tile.highlight { box-shadow: 0 0 0 2px var(--link); }

.tile-image img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 380px;
  object-fit: cover;
  object-position: top;
}
.tile-image.logo {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 180px;
  padding: 24px;
  background: var(--logo-bg);
}
.tile-image.logo img {
  width: auto;
  max-width: 100%;
  max-height: 132px;
}
.tile-image.logo img[src$=".svg"] { width: 120px; }

.tile-body { padding: 14px 18px 18px; }

.tile-name {
  margin: 0;
  font-size: 24px;
  font-weight: 300;
}
.year {
  margin-left: 8px;
  font-size: 14px;
  color: #bbb;
}
.tile-category {
  font-size: 12px;
  color: var(--muted);
}
.description {
  margin: 10px 0 12px;
  font-size: 16px;
}

.links {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 14px;
  font-size: 14px;
}
.offline { color: var(--muted); }
.pill {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 8px;
  border-radius: 10px;
  background: #eee;
  color: #888;
  font-size: 11px;
}

.more {
  margin-top: 12px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--muted);
  font: inherit;
  font-size: 13px;
  text-transform: inherit;
  cursor: pointer;
}
.more:hover { color: var(--text); }

.more-info {
  margin-top: 4px;
  font-size: 14px;
  line-height: 1.5;
  color: #444;
}
.more-info .subheading {
  margin-top: 12px;
  font-size: 13px;
  color: var(--muted);
}
.more-info p { margin: 6px 0; }
.more-info video,
.more-info img { max-width: 100%; height: auto; }
.more-info iframe { width: 100%; height: auto; aspect-ratio: 16 / 9; border: 0; }
.collaborator .link + a { margin-left: 8px; }

#extended-info { display: none; }
