/* Component imports */
[data-slot="toggle-field"] {
  align-items: center !important;
}

input[type="search"]::-webkit-search-decoration,
input[type="search"]::-webkit-search-cancel-button,
input[type="search"]::-webkit-search-results-button,
input[type="search"]::-webkit-search-results-decoration {
  display: none;
}

body:has(remote-modal-container div[aria-modal="true"]) [drawer-backdrop] {
  z-index: 32;
}

tags.tagify {
  border-radius: 5px;
  outline-style: var(--tw-outline-style);
  outline-width: 1px;
  outline-color: var(--color-gray-300);
  border: none !important;
}

tags.tagify .tagify__input {
  padding: 4px 8px;
  margin: 0;
  height: 32px;
}

.tagify--empty .tagify__input::before {
  line-height: 24px;
  top: 50%;
  margin-top: -12px;
  font-size: 16px;
}

/* app/assets/stylesheets/application.css */
.badge-container {
  width: 100%;
  max-width: 400px;
  margin: 0 auto;
}

.badge-preview {
  width: 100%;
  aspect-ratio: attr(data-aspect-ratio);
  max-width: 100%;
  height: auto;
}

.badge-preview.flipped {
  transform: scaleX(-1) scaleY(-1);
}

@media (max-width: 768px) {
  .badge-container {
    max-width: 300px;
  }
}

@media (max-width: 480px) {
  .badge-container {
    max-width: 250px;
  }
}

[class*="[&>input]:mt-[0.15em]"] > input {
  margin-top: 0 !important;
}

/* Override Tailwind form styles so Lexxy's language picker keeps its inline size */
.lexxy-code-language-picker {
  display: inline-flex;
  width: auto;
}

.lexxy-content ul {
  list-style: disc;
  padding-inline-start: 1.5rem;
}

.lexxy-content ol {
  list-style: decimal;
  padding-inline-start: 1.5rem;
}

.lexxy-content ul ul,
.lexxy-content ol ul {
  list-style: circle;
}

.lexxy-content ol ol,
.lexxy-content ul ol {
  list-style: lower-latin;
}

body::-webkit-scrollbar {
  width: 5px;
  background: transparent;
}

body::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.3);
  border-radius: 10px;
}

.overflow-y-auto::-webkit-scrollbar {
  width: 5px;
  background: transparent;
}

.overflow-y-auto::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.3);
  border-radius: 10px;
}
