/* lux additions on the notes pages (Markdown and Org) */
@font-face { font-family: "Manrope"; font-weight: 400; font-display: swap; src: url("/css/fonts/manrope-400.woff2") format("woff2"); }
@font-face { font-family: "Manrope"; font-weight: 600; font-display: swap; src: url("/css/fonts/manrope-600.woff2") format("woff2"); }

/* images uploaded from the editor: a default height, the width follows */
img[src^="/posts/img/lux/"] {
  height: 20rem;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  vertical-align: top;
}

/* archive.org items as chips (tools/chips.py): icon, title, year */
a.lux-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.45em;
  max-width: 100%;
  margin: 0.1em 0.15em;
  padding: 0.25em 0.6em 0.25em 0.45em;
  vertical-align: middle;
  background: color-mix(in srgb, var(--fg) 8%, transparent);
  color: var(--fg);
  text-decoration: none;
  line-height: 1.3;
  transition: background-color 70ms;
}
a.lux-chip:hover { background: color-mix(in srgb, var(--fg) 15%, transparent); text-decoration: none; }
a.lux-chip::after { content: none !important; }       /* no external-link arrow on chips */
.lux-chip-ico { flex: none; width: 1.05em; height: 1.05em; fill: none; stroke: var(--link); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.lux-chip-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-style: italic; }
.lux-chip-meta { flex: none; font: 400 0.75rem/1 Manrope, system-ui, sans-serif; color: color-mix(in srgb, var(--fg) 55%, transparent); font-variant-numeric: tabular-nums; font-style: normal; }
@media (prefers-reduced-motion: reduce) { a.lux-chip { transition: none; } }

/* draft notes in the list (only the logged-in tree has drafts) */
.lux-draft {
  display: inline-block;
  margin-left: 0.35em;
  padding: 0.1em 0.45em;
  vertical-align: 0.1em;
  font: 600 0.75rem/1.2 Manrope, system-ui, sans-serif;
  letter-spacing: 0.02em;
  color: var(--fg);
  background: color-mix(in srgb, #e8a20a 32%, transparent);
}

/* last change, under the date (tools/updated.py) */
.lux-updated { font-style: italic; color: color-mix(in srgb, var(--fg) 62%, transparent); }
p.lux-updated { margin: -0.4em 0 1.2em; text-align: center; font-size: 0.9em; }

/* long URLs (linked or not) break instead of widening the page */
main, #content { overflow-wrap: break-word; }
main a, #content a, .lux-body a { overflow-wrap: anywhere; word-break: break-word; }

/* phones: the sidebar is full width including its padding */
@media only screen and (max-width: 800px) {
  aside#leftSidebar { box-sizing: border-box; }
}

/* long display equations scroll sideways instead of widening the page */
mjx-container[display="true"] { display: block; max-width: 100%; min-width: 0 !important; overflow-x: auto; overflow-y: hidden; }

/* the note's source link, next to its date */
.lux-src-link { margin-left: 0.4em; font-size: 0.85em; }

/* ||redacted|| words: visitors get U+2588 blocks, the admin sees the words marked */
.lux-redact { color: var(--fg); letter-spacing: 0; font-family: inherit; white-space: pre-wrap; }
.lux-redacted { background: color-mix(in srgb, var(--fg) 12%, transparent); text-decoration: line-through 1px color-mix(in srgb, var(--fg) 40%, transparent); }
