.theme-preview[hidden] {
  display: none;
}

.theme-preview {
  position: fixed;
  z-index: 1000;
  right: 16px;
  bottom: 16px;
  left: 16px;
  display: flex;
  width: min(100% - 32px, 760px);
  min-height: 52px;
  margin-inline: auto;
  padding: 8px 10px 8px 16px;
  align-items: center;
  gap: 18px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 4px;
  background: rgba(16, 18, 16, 0.96);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.28);
  color: #f6f4ed;
  font: 600 12px/1.2 Inter, ui-sans-serif, system-ui, sans-serif;
  letter-spacing: 0;
  text-transform: none;
  backdrop-filter: blur(14px);
}

.theme-preview > span {
  flex: 0 0 auto;
  color: #a9aaa3;
}

.theme-preview nav {
  display: flex;
  min-width: 0;
  flex: 1;
  gap: 4px;
  overflow-x: auto;
}

.theme-preview nav a,
.theme-preview-close {
  border-radius: 2px;
  color: inherit;
  text-decoration: none;
}

.theme-preview nav a {
  flex: 0 0 auto;
  padding: 9px 12px;
}

.theme-preview nav a:hover,
.theme-preview nav a[aria-current="page"] {
  background: #f6f4ed;
  color: #171913;
}

.theme-preview-close {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  place-items: center;
  color: #a9aaa3;
  font-size: 20px;
  font-weight: 400;
}

.theme-preview-close:hover {
  color: #fff;
}

@media (max-width: 620px) {
  .theme-preview {
    align-items: flex-start;
  }

  .theme-preview > span {
    display: none;
  }
}
