/* ===== Dark mode surface remap (keeps light-designed pages readable) ===== */
html.dark .bg-white {
  background-color: #1e293b !important; /* slate-800 */
}
html.dark .bg-gray-50 {
  background-color: #0f172a !important; /* slate-900 */
}
html.dark .bg-gray-100 {
  background-color: #1e293b !important;
}
html.dark .border-gray-100,
html.dark .border-gray-200 {
  border-color: #334155 !important; /* slate-700 */
}
html.dark .text-gray-900,
html.dark .text-gray-800,
html.dark .text-slate-900,
html.dark .text-slate-800 {
  color: #e2e8f0 !important; /* slate-200 */
}
html.dark .text-gray-700,
html.dark .text-slate-700 {
  color: #cbd5e1 !important; /* slate-300 */
}
html.dark .text-gray-600,
html.dark .text-gray-500,
html.dark .text-gray-400,
html.dark .text-slate-600,
html.dark .text-slate-500,
html.dark .text-slate-400 {
  color: #94a3b8 !important; /* slate-400 */
}
html.dark .text-blue-900 {
  color: #93c5fd !important; /* blue-300 */
}
html.dark .text-green-800,
html.dark .text-emerald-800,
html.dark .text-emerald-900 {
  color: #6ee7b7 !important; /* emerald-300 */
}
html.dark .text-emerald-700,
html.dark .text-green-700 {
  color: #34d399 !important; /* emerald-400 */
}
/* Light-tint surfaces → dark equivalents so light text stays readable */
html.dark .bg-red-50 {
  background-color: #450a0a !important; /* red-950 */
}
html.dark .bg-red-100 {
  background-color: #450a0a !important;
}
html.dark .border-red-100,
html.dark .border-red-200 {
  border-color: #7f1d1d !important;
}
html.dark .bg-teal-50 {
  background-color: #042f2e !important; /* teal-950 */
}
html.dark .bg-amber-50,
html.dark .bg-amber-200 {
  background-color: #451a03 !important; /* amber-950 */
}
html.dark .bg-emerald-50 {
  background-color: #022c22 !important; /* emerald-950 */
}
html.dark .bg-green-50 {
  background-color: #052e16 !important; /* green-950 */
}
html.dark .bg-orange-50 {
  background-color: #431407 !important; /* orange-950 */
}
html.dark .bg-\[\#fffae5\] {
  background-color: #3b2f0a !important; /* dark yellow */
}
html.dark .bg-\[\#f0f9ff\] {
  background-color: #0c1f2e !important; /* dark blue */
}
html.dark .border-blue-100 {
  border-color: #1e3a5f !important;
}
/* Keep hover/focus text readable in dark mode */
html.dark .hover\:text-gray-800:hover {
  color: #e2e8f0 !important;
}
/* Native <select> dropdown in dark mode */
html.dark select,
html.dark select option {
  background-color: #1e293b !important;
  color: #e2e8f0 !important;
  border-color: #334155 !important;
}
html.dark .shadow-sm,
html.dark .shadow-lg,
html.dark .shadow-xl {
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.6) !important;
}
/* Keep inputs/textarea readable in dark mode — stop the browser autofill
   layer from painting the field background white (and keep placeholder text
   visible). Applied to form controls across the storefront. */
html.dark input,
html.dark textarea,
html.dark select {
  color-scheme: dark;
}
html.dark input:-webkit-autofill,
html.dark input:-webkit-autofill:hover,
html.dark input:-webkit-autofill:focus,
html.dark textarea:-webkit-autofill,
html.dark textarea:-webkit-autofill:hover,
html.dark textarea:-webkit-autofill:focus {
  -webkit-text-fill-color: #e2e8f0 !important;
  -webkit-box-shadow: 0 0 0 1000px #0f172a inset !important;
  caret-color: #e2e8f0 !important;
  transition: background-color 9999s ease-in-out 0s;
}

/* ===== Product gallery hover-swap (global so shop/index cards swap too) ===== */
.otut-gallery-swap:hover .otut-gallery-img:nth-child(2) {
  opacity: 1 !important;
}
.otut-gallery-swap:hover .otut-gallery-img:nth-child(1) {
  opacity: 0 !important;
}

/* ===== Admin-authored rich HTML description ===== */
.prose-desc h1, .prose-desc h2, .prose-desc h3 {
  font-weight: 800;
  color: #1f2937;
  margin: 0.75rem 0 0.5rem;
  line-height: 1.3;
}
.prose-desc h2 { font-size: 1.25rem; }
.prose-desc h3 { font-size: 1.1rem; }
.prose-desc p { margin: 0.5rem 0; }
.prose-desc ul, .prose-desc ol { margin: 0.5rem 0 0.5rem 1.25rem; list-style: revert; }
.prose-desc li { margin: 0.25rem 0; }
.prose-desc a { color: #dc2626; text-decoration: underline; }
.prose-desc img { border-radius: 0.5rem; margin: 0.5rem 0; max-width: 100%; }
.prose-desc strong { color: #111827; }
html.dark .prose-desc h1, html.dark .prose-desc h2, html.dark .prose-desc h3,
html.dark .prose-desc strong { color: #f1f5f9; }
html.dark .prose-desc { color: #cbd5e1; }
html.dark .prose-desc a { color: #f87171; }
