:root {
  color-scheme: light dark;
  font:
    15px/1.45 system-ui,
    sans-serif;
  background: #f4f5f7;
  color: #16181d;
}

body {
  margin: 0;
}

header {
  padding: 16px 24px;
  background: Canvas;
  border-bottom: 1px solid #bbb;
}

h1 {
  margin: 0 0 4px;
  font-size: 18px;
}

h2 {
  font-size: 16px;
}

code {
  overflow-wrap: anywhere;
  font-size: 12px;
}

figure {
  margin: 0;
  border: 1px solid #bbb;
  border-radius: 10px;
  background: Canvas;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: 6px;
  background: white;
}

figcaption {
  font-weight: 600;
}

.sample-frame {
  position: relative;
  display: grid;
  place-items: center;
  box-sizing: border-box;
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: 6px;
  background: #e9eaed;
}

.sample-frame img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

body.gallery-index .gallery-controls {
  padding: 14px 20px 0;
}

body.gallery-index .gallery-controls label {
  margin-right: 8px;
  font-weight: 600;
}

body.gallery-index main {
  padding: 20px;
}

body.gallery-index section {
  margin-bottom: 28px;
}

body.gallery-index .assets {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(360px, 100%), 1fr));
  gap: 16px;
}

body.gallery-index .assets .sample-frame {
  max-width: 420px;
  margin-inline: auto;
}

body.gallery-index figure {
  padding: 10px;
}

body.gallery-index figcaption {
  padding-top: 8px;
}

body.gallery-test main {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(520px, 100%), 1fr));
  gap: 20px;
  padding: 20px;
  align-items: start;
}

body.gallery-test figure {
  padding: 12px;
}

body.gallery-test .sample-frame--empty {
  box-sizing: border-box;
  padding: 12px;
  color: #555;
  font-size: 13px;
  text-align: center;
}

body.gallery-test figcaption {
  padding-top: 9px;
}

body.gallery-test .pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

body.gallery-test .pair > div {
  color: #666;
  font-size: 12px;
}

body.gallery-test .comparison-labels {
  display: flex;
  justify-content: space-between;
}

body.gallery-test .comparison-slider {
  display: block;
  width: 100%;
  overflow: hidden;
  border-radius: 6px;
  background: white;
}

body.gallery-test .comparison-slider img {
  width: 100%;
}

body.gallery-test .source-pair {
  margin-top: 8px;
}

body.gallery-test .source-pair summary {
  color: #666;
  font-size: 13px;
}

body.gallery-test .badge {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 7px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}

body.gallery-test .modified {
  background: #ffe1e1;
  color: #8a1f1f;
}

body.gallery-test .new {
  background: #e1f4ff;
  color: #0b4a78;
}

body.gallery-test .removed {
  background: #f0e1ff;
  color: #5a1a8a;
}

body.gallery-test .metric {
  color: #666;
  font-weight: 400;
}

body.gallery-test .label-line {
  margin-top: 8px;
  color: #666;
  font-size: 12px;
}

body.gallery-test details {
  grid-column: 1 / -1;
}

body.gallery-test details summary {
  padding: 8px 0;
  cursor: pointer;
}

@media (max-width: 700px) {
  body.gallery-test .pair {
    grid-template-columns: 1fr;
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    background: #17181b;
    color: #eee;
  }

  figure,
  header {
    border-color: #444;
  }

  .sample-frame {
    background: #292b30;
  }

  body.gallery-test .sample-frame--empty {
    color: #ccc;
  }

  body.gallery-test .metric,
  body.gallery-test .pair > div,
  body.gallery-test .label-line {
    color: #aaa;
  }
}
.variant-provenance {
  overflow-wrap: anywhere;
}
