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

/* Base RTL-friendly et police arabe */
:root { --accent: #6366F1; }
html[dir="rtl"] { direction: rtl; }

body {
  @apply bg-gray-50 text-gray-900 antialiased;
  font-family: 'Noto Naskh Arabic', 'Cairo', 'Segoe UI', Tahoma, system-ui, -apple-system, sans-serif;
}

/* Header helpers */
.header-logo { @apply flex items-center gap-3; }

/* Utility to reverse space when using RTL (Tailwind v3 doesn't include rtl by default) */
.rtl\:space-x-reverse > * + * { margin-inline-start: 0; margin-inline-end: 0; }

/* Small component styles */
.btn-primary {
  @apply inline-flex items-center px-4 py-2 rounded-md text-white bg-indigo-600 hover:bg-indigo-500;
}

/* Ensure focus outlines for accessibility */
:focus { outline: 2px solid transparent; outline-offset: 2px; }

/* Logo rectangulaire : hauteur fixe, largeur auto, conserve le ratio */
.logo-rect {
  height: 40px; /* taille par défaut */
  width: auto;
  display: block;
  object-fit: contain;
}

/* Responsive: augmenter légèrement sur écrans moyens/grands */
@media (min-width: 768px) {
  .logo-rect { height: 48px; }
}
@media (min-width: 1024px) {
  .logo-rect { height: 56px; }
}
