:root {
  --bg-main:        #f7f5ef;
  --bg-accent:      #eee8aa;
  --bg-card:        #ffffff;
  --bg-list:        #f9f7f4;

  --text-primary:   #1f1f1f;
  --text-secondary: #555555;
  --text-muted:     #888888;

  --accent:         #e3a008;
  --accent-strong:  #b7791f;
  --accent-light:   #f6e7a1;

  --border:         #e5e2dc;
  --border-strong:  #e3a008;
  --border-light:   #f6f2f8;

  --success:        #4caf50;
  --error:          #d64545;
}

body {
  background-color: var(--bg-main);
  background-image: url(/static/glaze_transparent_websafe.png);
  background-position: calc(100vw - 256px) calc(100vh - 200px);
  background-repeat: no-repeat;
  color: var(--text-primary);
  line-height: 1.6;
  font-family: system-ui, -apple-system, sans-serif;
}

.header h1, .header h2, .header h3, .header h4, .header h5, .header h6 {
  margin: 0.5em 1.5em;
}

.card-title {
  margin: 0.5em 1.5em;
}

hr {
  border: none;
  border-bottom: 1px solid var(--accent-light);
}

.container {
  max-width: 900px;
  margin: 0 auto;
  padding: 2em  1em;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 0.5em;
  box-shadow: 0 0 0.75em var(--border);
  padding: 0 0;
  overflow: hidden;
}

.repo-list {
  box-shadow: 0 0 0.4em var(--border);
  border: 1px solid var(--border);
  border-radius: 0.4em;
  margin: 0.5em 1.5em;
  background: var(--bg-list);
}

.repo-row {
  display: flex;
  flex-direction: column;
  line-height: 1.2em;
  border-bottom: 1px solid var(--border);
}

.repo-row:last-child {
  border-bottom: none;
}

.repo-row:last-child {
  border-radius: 0 0 0.4em 0.4em;
}

.repo-row:hover {
  background: var(--accent-light);
}

.repo-title {
  display: flex;
  justify-content: space-between;
  font-weight: bold;
  color: var(--text-primary);
  margin-bottom: 0.5em;
}

.repo-link {
  text-decoration: none;
  padding: 0.5em 0.5em;
}

.repo-updated-at {
  font-weight: normal;
  font-size: 0.9em;
  text-align: right;
}

.repo-description {
  color: var(--text-secondary);
  font-style: italic;
  font-size: 0.9em;
}

.header {
  display: flex;
  flex-direction: row;
  align-items: center;
  background-color: var(--bg-accent);
  border-bottom: 1px solid var(--border-strong);
}

.header h1 > a {
  text-decoration: none;
  color: inherit;
}

.breadcrumbs {
  margin: 0.5em 1.5em;
  font-weight: normal;
  font-style: italic;
  font-size: 1.1em;
  color: var(--text-primary);
}

.breadcrumbs > a {
  text-decoration: none;
  font-style: inherit;
  color: var(--text-secondary);
}

.footer {
  text-align: center;
  padding: 0.5em 1.5em;
  background-color: var(--bg-accent);
  border-top: 1px solid var(--border-strong);
}

.footer-link {
  text-decoration: none;
  font-weight: bold;
  color: inherit;
}

.card ul {
  list-style: none;
  padding: 0 0;
}

code {
  border: 1px solid var(--border);
  background: var(--bg-main);
  font-family: ui-monospace, monospace;
  margin: 0;
  padding: 0 0.25em;
  border-radius: 0.2em;
}

pre > code {
  display: block;
  margin: 0.5em 1.5em;
  padding: 0.5em;
  overflow: hidden;
  overflow-x: auto;
}

.readme  {
  display: block;
  margin: 0.5em 1.5em;
  padding: 0.5em;
  overflow: hidden;
  overflow-x: auto;
}

.readme ul {
  list-style: auto;
}

.repo-tree {
}

.repo-tree-head {
  display: flex;
  justify-content: space-between;
  background-color: lightyellow;
  color: var(--text-secondary);
  margin: 0.5em 1.5em;
  border: 1px solid var(--border);
  border-radius: 0.4em;
  line-height: 1.2em;
  padding: 0.5em 0.5em;
}

.repo-tree-list {
  box-shadow: 0 0 4px var(--border);
  border: 1px solid var(--border);
  border-radius: 0.4em;
  margin: 0.5em 1.5em;
  background: var(--bg-list);
  color: var(--text-primary);
}

.repo-tree-row {
  display: flex;
  justify-content: space-between;
  line-height: 1.2em;
  border-bottom: 1px solid var(--border);
}

.repo-tree-row:last-child {
  border-bottom: none;
}

.repo-tree-row:last-child {
  border-radius: 0 0 0.4em 0.4em;
}

.repo-tree-row:hover {
  background: var(--accent-light);
}

.repo-tree-link, .repo-tree-link-dir, .repo-tree-raw-link {
  text-decoration: none;
  padding: 0.5em 0.5em;
  color: inherit;
}

.repo-tree-link, .repo-tree-link-dir {
  width: 100%
}

.repo-tree-link-dir {
  font-weight: bold;
}