@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  color-scheme: light;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 4.5rem;
  overflow-x: clip;
  -webkit-text-size-adjust: 100%;
  background-color: #ffffff;
  color: #111827;
  font-family: var(--font-sans);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

@media (min-width: 640px) {
  html {
    scroll-padding-top: 5.5rem;
  }
}

body {
  background-color: #ffffff;
  color: #111827;
  min-height: 100vh;
  min-height: 100dvh;
  overflow-x: clip;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0.08);
  line-height: 1.6;
}

a,
button,
input,
select,
textarea {
  touch-action: manipulation;
}

/* Custom Minimal Scrollbar pour Thème Clair */
::-webkit-scrollbar {
  width: 7px;
  height: 7px;
}

::-webkit-scrollbar-track {
  background: #f3f4f6;
}

::-webkit-scrollbar-thumb {
  background: #d1d5db;
  border-radius: 9999px;
}

::-webkit-scrollbar-thumb:hover {
  background: #9ca3af;
}

/* Smooth selection colors */
::selection {
  background-color: #000000;
  color: #ffffff;
}

/* Accessible focus visible outlines */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid #2563eb;
  outline-offset: 2px;
}

/* Subtle fade in keyframes */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-fade-in {
  animation: fadeIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Mobile Layout & Scroll Helpers */
.no-scrollbar {
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.no-scrollbar::-webkit-scrollbar {
  display: none;
}

.mobile-drawer-panel {
  max-height: calc(100vh - 4rem);
  max-height: calc(100dvh - 4rem);
  padding-bottom: max(1.5rem, env(safe-area-inset-bottom));
}

@media (min-width: 640px) {
  .mobile-drawer-panel {
    max-height: calc(100vh - 5rem);
    max-height: calc(100dvh - 5rem);
  }
}

.modal-panel {
  max-height: 90vh;
  max-height: 90dvh;
}

.palette-results-scroll {
  max-height: 52vh;
  max-height: 52dvh;
}

@media (min-width: 640px) {
  .palette-results-scroll {
    max-height: 20rem;
  }
}

.hero-section-height {
  min-height: 100vh;
  min-height: 100svh;
}

@media (min-width: 640px) {
  .hero-section-height {
    min-height: 90vh;
  }
}

/* Respect Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
