[hidden] {
  display: none !important;
}

:root {
  --examples-stage-background: linear-gradient(180deg, #0b1119 0%, #000 100%);
  --examples-sidebar-width: 354px;
  --examples-header-height: 55px;
  --examples-mobile-search-height: 42px;
  --examples-mobile-navigation-height: 134px;
  --examples-shell-background: #181818;
  --examples-shell-surface: #212121;
  --examples-shell-border: #303030;
  --examples-shell-text: #dfdfdf;
  --examples-shell-muted: #8f8f8f;
  --examples-shell-focus: rgb(51 156 255 / 70%);
}

html,
body {
  min-width: 100%;
  min-height: 100%;
  margin: 0;
  background: var(--examples-stage-background);
}

html.example-background-cloth {
  --examples-stage-background: #cce0ff;
}

html.example-background-solitaire {
  --examples-stage-background: linear-gradient(180deg, #008000 0%, #003d00 100%);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.examples-sidebar,
.examples-sidebar *,
.example-info {
  box-sizing: border-box;
}

.examples-sidebar-persistence {
  display: contents;
}

.examples-sidebar {
  position: fixed;
  z-index: 100;
  inset: 0 auto 0 0;
  display: grid;
  grid-template-rows: var(--examples-header-height) auto minmax(0, 1fr);
  width: var(--examples-sidebar-width);
  min-width: 0;
  min-height: 0;
  color: var(--examples-shell-text);
  background: var(--examples-shell-background);
  border-right: 1px solid var(--examples-shell-border);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  color-scheme: dark;
}

.examples-header {
  position: relative;
  display: flex;
  grid-row: 1;
  align-items: center;
}

.examples-wordmark {
  display: inline-flex;
  align-items: center;
  margin-left: 10px;
  color: var(--examples-shell-text);
  opacity: 0.72;
  text-decoration: none;
}

.examples-wordmark svg {
  display: block;
  width: 156px;
  height: 36px;
  overflow: visible;
  transform: translateY(-3px);
}

.examples-wordmark text {
  fill: currentColor;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 22px;
  font-weight: 400;
  letter-spacing: 0.1px;
}

.examples-wordmark-dot,
.examples-wordmark-graphics {
  font-weight: 100;
}

.examples-contact-link,
.examples-github-link {
  color: var(--examples-shell-text);
  font-size: 14px;
  opacity: 0.6;
  text-decoration: none;
}

.examples-contact-link {
  margin-left: auto;
}

.examples-header-separator {
  margin: 0 7px;
  color: var(--examples-shell-text);
  font-size: 14px;
  opacity: 0.6;
}

.examples-github-link {
  padding-right: 14px;
}

.examples-contact-link:hover,
.examples-contact-link:focus-visible,
.examples-github-link:hover,
.examples-github-link:focus-visible {
  opacity: 1;
}

.examples-search-panel svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: #afafaf;
  stroke-width: 1.8;
}

.examples-search-panel {
  display: grid;
  grid-row: 2;
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: center;
  min-height: 56px;
  background: var(--examples-shell-background);
  border-top: 1px solid var(--examples-shell-border);
  border-bottom: 1px solid var(--examples-shell-border);
}

.examples-search-panel svg {
  justify-self: center;
}

.examples-search-panel input {
  width: 100%;
  height: 100%;
  padding: 0 14px 0 0;
  color: var(--examples-shell-text);
  background: transparent;
  border: 0;
  outline: 0;
  font: inherit;
  font-size: 14px;
}

.examples-search-panel input::placeholder {
  color: var(--examples-shell-muted);
}

#asset-list {
  grid-row: 3;
  min-height: 0;
  padding: 10px 8px 22px;
  overflow-x: hidden;
  overflow-y: auto;
  scrollbar-color: #4f4f4f transparent;
  scrollbar-width: thin;
}

.project-thumbnail {
  position: relative;
  display: grid;
  grid-template-rows: auto 44px;
  margin-bottom: 12px;
  overflow: hidden;
  color: #afafaf;
  background: var(--examples-shell-surface);
  border: 1px solid #282828;
  border-radius: 3px;
  text-decoration: none;
  opacity: 0.6;
}

.project-thumbnail:hover,
.project-thumbnail:focus-visible {
  border-color: #5d5d5d;
  outline: 0;
  opacity: 1;
}

.project-thumbnail[aria-current="page"] {
  border-color: #707070;
  opacity: 0.96;
}

.project-thumbnail img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #0d0d0d;
}

.project-copy {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-content: center;
  align-items: baseline;
  gap: 8px;
  min-width: 0;
  padding: 0 10px;
  color: #afafaf;
}

.project-title {
  overflow: hidden;
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.project-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  color: inherit;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  opacity: 0.75;
  white-space: nowrap;
}

.project-number {
  position: absolute;
  top: 8px;
  left: 8px;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  opacity: 0.75;
}

.project-number-dark {
  color: #282828;
}

.project-number-light {
  color: var(--examples-shell-text);
}

#empty-results {
  position: absolute;
  right: 20px;
  bottom: 20px;
  left: 20px;
  margin: 0;
  color: var(--examples-shell-muted);
  font-size: 14px;
  text-align: center;
}

.example-info {
  position: fixed;
  z-index: 90;
  top: 0;
  right: 0;
  left: var(--examples-sidebar-width);
  padding: 10px;
  margin: 0;
  font-family: monospace;
  font-size: 14px;
  line-height: 24px;
  text-align: center;
  user-select: none;
  pointer-events: none;
}

.example-info a {
  color: inherit;
  text-decoration: underline;
  pointer-events: auto;
}

.example-info-dark {
  color: rgb(40 40 40 / 80%);
}

.example-info-dark a:hover {
  color: #282828;
}

.example-info-light {
  color: rgb(223 223 223 / 80%);
}

.example-info-light a:hover {
  color: var(--examples-shell-text);
}

.example-stage {
  position: fixed;
  inset: 0 0 0 var(--examples-sidebar-width);
  min-width: 0;
  min-height: 0;
  margin: 0;
  overflow: hidden;
  background: var(--examples-stage-background);
}

.example-stage > [class$="-error-message"] {
  position: absolute;
}

html body.loading::after,
html body:not(.ready):not(.error)::after {
  inset: 0 0 0 var(--examples-sidebar-width);
  margin: auto;
}

@media (max-width: 760px) {
  :root {
    --examples-header-height: 50px;
  }

  .examples-sidebar {
    inset: 0;
    grid-template-rows:
      var(--examples-header-height)
      minmax(0, 1fr)
      var(--examples-mobile-search-height)
      var(--examples-mobile-navigation-height);
    width: 100%;
    height: 100%;
    pointer-events: none;
    background: transparent;
    border-right: 0;
  }

  .examples-header,
  .examples-search-panel,
  #asset-list {
    pointer-events: auto;
    background: var(--examples-shell-background);
  }

  .examples-wordmark {
    margin-left: 10px;
  }

  .examples-search-panel {
    grid-row: 3;
    min-height: 42px;
  }

  #asset-list {
    grid-row: 4;
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 10px;
    overflow-x: auto;
    overflow-y: hidden;
    border-top: 1px solid var(--examples-shell-border);
  }

  .project-thumbnail {
    flex: 0 0 178px;
    grid-template-rows: 82px 30px;
    margin: 0;
  }

  .project-thumbnail img {
    height: 100%;
  }

  .project-copy {
    display: block;
    padding: 6px 10px;
  }

  .project-title {
    display: block;
  }

  .project-meta {
    display: none;
  }

  .project-number {
    top: 5px;
    right: auto;
    left: 5px;
  }

  .example-stage {
    inset:
      var(--examples-header-height)
      0
      calc(var(--examples-mobile-search-height) + var(--examples-mobile-navigation-height));
  }

  .example-info {
    top: var(--examples-header-height);
    left: 0;
  }

  html body.loading::after,
  html body:not(.ready):not(.error)::after {
    inset:
      var(--examples-header-height)
      0
      calc(var(--examples-mobile-search-height) + var(--examples-mobile-navigation-height));
  }
}
