/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

/*
 *= require_tree .
 *= require_self
 *= require pickr/classic.min
 */

 .pcr-app {
    z-index: 10000 !important;
  }
  
  [data-color-picker-target="recentColors"] {
    transition: all 0.3s ease;
  }

/* Hide Coloris text input */
input.coloris {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

/* Style the color picker button */
.color-picker-button {
  cursor: pointer;
  box-sizing: border-box;
  height: 2.5rem;
  width: 2.5rem;
  border-radius: 9999px;
  border: 1px solid #e5e7eb;
  transition: border-color 0.2s ease;
}

.color-picker-button:hover {
  border-color: #9ca3af;
}

/* Dark theme: the swatch button's hairline must read against
   gray-900 cards instead of white (the fill itself is creator
   color content and stays). */
[data-theme="dark"] .color-picker-button {
  border-color: #374151; /* gray-700 */
}

[data-theme="dark"] .color-picker-button:hover {
  border-color: #6b7280; /* gray-500 */
}

/* Modal transitions */
.transform {
  transition-property: transform;
}

.duration-300 { 
  transition-duration: 300ms;
}

.ease-in-out {
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

.translate-x-full {
  transform: translateX(100%);
}

/* Off-screen is +100% in LTR but −100% in RTL, because the drawers using this
   are anchored to the inline-end edge. The Tailwind self-variant that used to
   say so in the markup — rtl:[&.translate-x-full]:-translate-x-full — is not
   generated by v4, so nothing flipped it and in Arabic the checkout drawer sat
   ONTO the page, covering the product on load.

   BOTH declarations have to flip. Tailwind v4 writes the modern `translate`
   property while the rule above writes `transform`, and they add up rather
   than override: flipping only one left +100% and −100% cancelling to zero,
   which parks the drawer exactly on screen. In LTR they have always doubled
   up the same way, which is why nothing looked wrong there. */
[dir="rtl"] .translate-x-full {
  transform: translateX(-100%);
  translate: -100%;
}

.transition-transform {
  transition-property: transform;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  transition-duration: 300ms;
}

.transition-opacity {
  transition-property: opacity;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  transition-duration: 300ms;
}
