@tailwind base;
@tailwind components;
@tailwind utilities;

@layer utilities {
  .scrollbar-thin {
    scrollbar-width: thin;
    scrollbar-color: #374151 transparent;
  }
  .scrollbar-thin::-webkit-scrollbar {
    width: 6px;
  }
  .scrollbar-thin::-webkit-scrollbar-track {
    background: transparent;
  }
  .scrollbar-thin::-webkit-scrollbar-thumb {
    background-color: #374151;
    border-radius: 3px;
  }
}
/* https://github.com/leongersen/noUiSlider/blob/b24da2482912124696964e99c64cd2caad7616ce/dist/nouislider.css */

/* Functional styling;
 * These styles are required for noUiSlider to function.
 * You don't need to change these rules to apply your design.
 */
.noUi-target,
.noUi-target * {
  -webkit-touch-callout: none;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  -webkit-user-select: none;
  -ms-touch-action: none;
  touch-action: none;
  -ms-user-select: none;
  -moz-user-select: none;
  user-select: none;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
}
.noUi-target {
  position: relative;
}
/* Offset direction
 */
.noUi-txt-dir-rtl.noUi-horizontal .noUi-origin {
  left: 0;
  right: auto;
}
/* Give origins 0 height/width so they don't interfere with clicking the
 * connect elements.
 */
.noUi-horizontal .noUi-origin {
  height: 0;
}
.noUi-state-drag * {
  cursor: inherit !important;
}
/* Slider size and handle placement;
 */
.noUi-horizontal {
  /* height: 18px; */
  height: 8px;
}
/* Styling;
 * Giving the connect element a border radius causes issues with using transform: scale
 */
.noUi-target {
  background: #1c2128;
  /* border-radius: 4px; */
  border-radius: 9999px;
  /* border: 1px solid #D3D3D3; */
  /* box-shadow: inset 0 1px 1px #F0F0F0, 0 3px 6px -5px #BBB; */
}
/* Handles and cursors;
 */
.noUi-draggable {
  cursor: ew-resize;
}
.noUi-active {
  /* box-shadow: inset 0 0 1px #FFF, inset 0 1px 7px #DDD, 0 3px 6px -3px #BBB; */
}
/* Disabled state;
 */
[disabled].noUi-target,
[disabled].noUi-handle,
[disabled] .noUi-handle {
  cursor: not-allowed;
}
/* Base;
 *
 */
.noUi-pips,
.noUi-pips * {
  -moz-box-sizing: border-box;
  box-sizing: border-box;
}
.noUi-pips {
  position: absolute;
  color: #999;
}
/* Values;
 *
 */
.noUi-value {
  position: absolute;
  white-space: nowrap;
  text-align: center;
}
.noUi-value-sub {
  color: #ccc;
  font-size: 10px;
}
/* Markings;
 *
 */
.noUi-marker {
  position: absolute;
  background: #CCC;
}
.noUi-marker-sub {
  background: #AAA;
}
.noUi-marker-large {
  background: #AAA;
}
/* Horizontal layout;
 *
 */
.noUi-pips-horizontal {
  padding: 10px 0;
  height: 80px;
  top: 100%;
  left: 0;
  width: 100%;
}
.noUi-value-horizontal {
  -webkit-transform: translate(-50%, 50%);
  transform: translate(-50%, 50%);
}
.noUi-rtl .noUi-value-horizontal {
  -webkit-transform: translate(50%, 50%);
  transform: translate(50%, 50%);
}
.noUi-marker-horizontal.noUi-marker {
  margin-left: -1px;
  width: 2px;
  height: 5px;
}
.noUi-marker-horizontal.noUi-marker-sub {
  height: 10px;
}
.noUi-marker-horizontal.noUi-marker-large {
  height: 15px;
}
.noUi-base,
.noUi-connects {
  width: 100%;
  height: 100%;
  position: relative;
  z-index: 1;
}
/* Wrapper for all connect elements.
 */
.noUi-connects {
  overflow: hidden;
  z-index: 0;
}
.noUi-connect,
.noUi-origin {
  will-change: transform;
  position: absolute;
  z-index: 1;
  top: 0;
  right: 0;
  height: 100%;
  width: 100%;
  -ms-transform-origin: 0 0;
  -webkit-transform-origin: 0 0;
  -webkit-transform-style: preserve-3d;
  transform-origin: 0 0;
  transform-style: flat;
}

.noUi-state-tap .noUi-connect,
.noUi-state-tap .noUi-origin {
  -webkit-transition: transform 0.3s;
  transition: transform 0.3s;
}

.noUi-connects {
  border-radius: 3px;
}
.noUi-connect {
  /* background: #3FB8AF; */
  background: #18a34a;
}

/* Disabled state;
 */
[disabled] .noUi-connect {
  background: #B8B8B8;
}
.noUi-handle {
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  position: absolute;
}

.noUi-horizontal .noUi-handle {
  /* width: 34px; */
  /* height: 28px; */
  right: -17px;
  /* top: -6px; */

  height: 1.5rem;
  width: 1.5rem;
  top: -0.5rem;
  background-color: rgb(34 197 94);
  align-items: center;
}

.noUi-txt-dir-rtl.noUi-horizontal .noUi-handle {
  /* left: -17px; */
  right: auto;
}

.noUi-handle {
  /* border: 1px solid #D9D9D9; */
  /* border-radius: 3px; */
  border-radius: 9999px;
  /* background: #FFF; */
  /* cursor: default; */
  cursor: ew-resize;
  /* box-shadow: inset 0 0 1px #FFF, inset 0 1px 7px #EBEBEB, 0 3px 6px -3px #BBB; */
}

/* Handle stripes;
 */
.noUi-handle:before,
.noUi-handle:after {
  /* content: ""; */
  /* content: attr(data-value); */
  /* display: block; */
  /* position: absolute; */
  /* height: 14px; */
  /* width: 1px; */
  /* background: #E8E7E6; */
  /* left: 14px; */
  /* top: 6px; */
}
.noUi-handle:after {
  /* left: 17px; */
}
.noUi-touch-area {
  height: 100%;
  width: 100%;
}
.noUi-tooltip {
  display: block;
  position: absolute;
  /* border: 1px solid #D9D9D9; */
  /* border-radius: 3px; */
  /* background: #fff; */
  /* color: #000; */
  color: rgb(209 213 219);
  /* padding: 5px; */
  text-align: center;
  white-space: nowrap;

  font-size: 12px;
  line-height: 1rem;
}
.noUi-horizontal .noUi-tooltip {
  -webkit-transform: translate(-50%, 0);
  transform: translate(-50%, 0);
  left: 50%;
  bottom: 120%;
}
.noUi-horizontal .noUi-origin > .noUi-tooltip {
  -webkit-transform: translate(50%, 0);
  transform: translate(50%, 0);
  left: auto;
  bottom: 10px;
}
.pagy {
  display: flex;
  /* items-center */
  align-items: center;
  /* justify-center */
  justify-content: center;
   gap: 0.1rem;
}

.pagy > :not([hidden]) ~ :not([hidden]) {
  --space-reverse: 0;
  margin-right: calc(0.25rem * var(--space-reverse));
  margin-left: calc(0.25rem * calc(1 - var(--space-reverse)));
}

.pagy {
  font-family: sans-serif;
  font-size: 0.875rem;
  line-height: 1.25rem;
  font-weight: 600;
  color: rgb(107 114 128);
}

.pagy .page.gap {
  /* mx-auto */
  margin-left: auto;
  margin-right: auto;

  display: flex;
  align-items: center;
  justify-content: center;
}

.pagy .page a {
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;

  /* rounded-lg */
  border-radius: 0.5rem;

  /* text-gray-400 */
  color: rgb(156 163 175);

  /* py-2 */
  padding-top:    0.5rem;
  padding-bottom: 0.5rem;

  /* px-4 */
  padding-left:  1rem;
  padding-right: 1rem;

  /* border-0.5 */
  border-width: 0.5px;
  border-color: transparent;

  width: 40px;
  height: 40px;

}

.pagy .page a:hover {
  /* border-0.5 */
  border-width: 0.5px;

  /* border-gray-500 */
  border-color: rgb(156 163 175);
}

.pagy .page.active a {
  cursor: default;
  background-color: rgb(48,109,202);
  color: rgb(161,172,184)

  /* border-0.5 */
  border-width: 0.5px;
  border-color: transparent;
}

.pagy .page.active a:hover {
  border-width: 0.5px;
}

.pagy .page.disabled a {
  cursor: default;
  background-color: rgb(243 244 246);
  color: rgb(209 213 219)
}

.pagy .pagy-combo-input, .pagy.pagy-items-selector-js {
  display: inline-block;
  border-radius: 0.5rem;
  background-color: rgb(229 231 235);
  padding: 0.125rem 0.75rem;
}

.pagy .pagy-combo-input input, .pagy.pagy-items-selector-js input {
  border-radius: 0.375rem;
  border-style: none;
  background-color: rgb(243 244 246);
}

.page.prev a {
  color: rgb(59 130 246);
}

.page.next a {
  color: rgb(59 130 246);
}

.page.prev.disabled a {
  background-color: transparent;
  /* text-blue-500 */
  color: rgb(55 65 81);
}

.page.next.disabled a {
  background-color: transparent;
  /* text-blue-500 */
  color: rgb(55 65 81);
}

.page.prev.disabled a:hover {
  /* border-0 */
  border: 0;
}

.page.next.disabled a:hover {
  /* border-0 */
  border: 0;
}
/*
 * This is a manifest file that'll be compiled into application.css, which will include all the files
 * listed below.
 *
 * Any CSS (and SCSS, if configured) file within this directory, lib/assets/stylesheets, or any plugin's
 * vendor/assets/stylesheets directory can be referenced here using a relative path.
 *
 * You're free to add application-wide styles to this file and they'll appear at the bottom of the
 * compiled file so the styles you add here take precedence over styles defined in any other CSS
 * files in this directory. Styles in this file should be added after the last require_* statement.
 * It is generally better to create a new file per style scope.
 *


 */

.my-content {
  overflow: hidden;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: var(--read-more-line-clamp, 3); /* Adjust 3 for the number of lines you want to show by default */
}

/* Add this keyframes definition before using the animation */
@keyframes spinner {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Just handle the spinner animation and appearance */
.table-loading-indicator {
  width: 16px;
  height: 16px;
  display: none;
}

.table-loading-indicator::after {
  content: "";
  box-sizing: border-box;
  position: absolute;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid transparent;
  border-top-color: #3b82f6;
  animation: spinner 0.6s linear infinite;
}

/* Make it visible when frame is busy */
turbo-frame[busy] .table-loading-indicator {
  display: block;
}

turbo-frame.is-loading .table-loading-indicator {
  display: block;
}
