:root {
  --bg-main: #1a1a1a;
  --bg-code: #2d2d2d;
  --bg-inline-code: #333;
  --text-main: #e0e0e0;
  --text-code: #f8f8f2;
  --accent: #4a9eff;
  --border-color: #444;
  --font-body: 'Excalifont', sans-serif;
  --font-mono: 'Hack', monospace;
}

@font-face {
  font-family: 'Excalifont';
  src: url('Excalifont-Regular.woff2') format('woff2');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

body {
  font-family: var(--font-body);
  line-height: 1.4;
  max-width: 1000px;
  margin: 40px auto;
  padding: 0 20px;
  background-color: var(--bg-main);
  color: var(--text-main);
  text-rendering: optimizeLegibility;
}

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

a:hover {
  text-decoration: underline;
}

.back {
  font-size: large;
  text-decoration: none; !important
}

/* Inline code */
code {
  background: var(--bg-inline-code);
  padding: 0.2rem 0.4rem;
  border-radius: 4px;
  font-size: 0.9em;
}

/* Code blocks */
pre {
  background-color: var(--bg-code);
  padding: 15px;
  border-radius: 5px;
  overflow-x: auto;
  margin: 20px 0;
  border: 1px solid var(--border-color);
}

pre code {
  font-family: var(--font-mono);
  line-height: 1; /* Slightly more breathable than 1 */
  background-color: transparent;
  color: var(--text-code);
  padding: 0;
}

/* Prism Toolbar Positioning */
div.code-toolbar {
  position: relative;
}

div.code-toolbar > .toolbar {
  position: absolute;
  top: 10px;
  right: 10px;
  opacity: 0.5;
  transition: opacity 0.2s ease;
}

div.code-toolbar:hover > .toolbar {
  opacity: 1;
}

/* Prism Copy Button */
div.code-toolbar > .toolbar .toolbar-item > button {
  background: var(--bg-inline-code);
  color: #eee;
  border: 1px solid #555;
  border-radius: 5px;
  padding: 4px 8px;
  font-size: 0.8rem;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

div.code-toolbar > .toolbar .toolbar-item > button:hover {
  background: #444;
  color: #fff;
}