/* ================================================
   FABARA — Design System Global
   Utilisé sur toutes les pages du site
   ================================================ */

/* ========== VARIABLES ========== */
:root {
  --green-dark:  #1B5E20;
  --green-main:  #2E7D32;
  --green-mid:   #388E3C;
  --green-light: #4CAF50;
  --green-pale:  #C8E6C9;
  --green-bg:    #F1F8E9;
  --gold:        #F9A825;
  --gold-light:  #FFF8E1;
  --white:       #FFFFFF;
  --gray-light:  #F5F5F5;
  --gray-mid:    #757575;
  --gray-dark:   #212121;
  --text:        #1A2E1A;
  --danger:      #EF4444;
  --font-display:'Playfair Display', Georgia, serif;
  --font-body:   'DM Sans', sans-serif;
  --radius:      12px;
  --radius-lg:   20px;
  --shadow:      0 4px 24px rgba(46,125,50,0.10);
  --shadow-lg:   0 12px 40px rgba(46,125,50,0.15);
  --transition:  0.25s ease;

  /* Tons de pastilles d'icônes (espace pro) — repris des badges de statut existants */
  --tone-green-bg:  var(--green-bg);   --tone-green-fg:  var(--green-dark);
  --tone-gold-bg:   var(--gold-light); --tone-gold-fg:   #B45309;
  --tone-blue-bg:   #dbeafe;           --tone-blue-fg:   #1d4ed8;
  --tone-purple-bg: #f3e8ff;           --tone-purple-fg: #7c3aed;
  --tone-teal-bg:   #ccfbf1;           --tone-teal-fg:   #0f766e;
  --tone-red-bg:    #fee2e2;           --tone-red-fg:    #dc2626;
  --tone-amber-bg:  #fef3c7;           --tone-amber-fg:  #b45309;
  --tone-slate-bg:  #f1f5f9;           --tone-slate-fg:  #475569;
}

/* ========== RESET ========== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body { font-family: var(--font-body); color: var(--text); background: var(--white); overflow-x: hidden; line-height: 1.6; }
img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
button { font-family: var(--font-body); cursor: pointer; }

/* ========== UTILITAIRES ========== */
.container-page { max-width: 1140px; margin: 0 auto; padding: 0 5%; }
.section        { padding: 5rem 5%; }
.section-alt    { background: var(--green-bg); }
.section-white  { background: var(--white); }
.text-center    { text-align: center; }

/* ========== TYPOGRAPHIE ========== */
.section-tag {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 0.82rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 1.5px;
  color: var(--green-main); margin-bottom: 0.8rem;
}
.section-tag::before {
  content: ''; width: 20px; height: 2px;
  background: var(--green-main); flex-shrink: 0;
}
.section-tag-center { justify-content: center; }

.section-title-page {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  font-weight: 700; line-height: 1.15;
  color: var(--text); margin-bottom: 0.8rem;
}

.section-sub {
  font-size: 1.05rem; color: var(--gray-mid);
  line-height: 1.7; max-width: 540px;
}

.section-header        { margin-bottom: 3rem; }
.section-header-center { text-align: center; }
.section-header-center .section-sub { margin: 0 auto; }

.section-header-flex {
  display: flex; justify-content: space-between;
  align-items: flex-end; flex-wrap: wrap;
  gap: 1.5rem; margin-bottom: 2.5rem;
}

/* ========== NAVBAR ========== */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  background: rgba(255,255,255,0.97);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--green-pale);
  padding: 0 5%;
  display: flex; align-items: center; justify-content: space-between;
  height: 72px;
  transition: box-shadow var(--transition);
}
.nav-logo {
  font-family: var(--font-display);
  font-size: 1.9rem; font-weight: 900;
  color: var(--green-dark); letter-spacing: -1px;
}
.nav-logo span { color: var(--gold); }
.nav-links { display: flex; gap: 2rem; align-items: center; }
.nav-links a {
  font-size: 0.95rem; font-weight: 500;
  color: var(--gray-dark); transition: color var(--transition);
}
.nav-links a:hover,
.nav-links a.active { color: var(--green-main); }

.fabara-toast-wrap {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 9998;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  width: calc(100% - 32px);
  max-width: 380px;
}
.fabara-toast {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  padding: 0.9rem 1rem;
  border-radius: 12px;
  font-size: 0.9rem;
  box-shadow: 0 8px 28px rgba(0,0,0,0.15);
  animation: fabaraToastEntree 0.3s ease;
}
.fabara-toast-sortie { animation: fabaraToastSortie 0.25s ease forwards; }
.fabara-toast-icone { font-size: 1.15rem; line-height: 1; flex-shrink: 0; }
.fabara-toast-message { flex: 1; min-width: 0; }
.fabara-toast ul { margin: 0.4rem 0 0 1.1rem; }
.fabara-toast-close {
  background: none; border: none; cursor: pointer; padding: 0;
  font-size: 1.2rem; line-height: 1; color: inherit; opacity: 0.55; flex-shrink: 0;
}
.fabara-toast-close:hover { opacity: 1; }
.fabara-toast-success {
  background: var(--green-bg);
  color: var(--green-dark);
  border: 1px solid var(--green-pale);
}
.fabara-toast-error {
  background: #fee2e2;
  color: #991b1b;
  border: 1px solid #fecaca;
}
@keyframes fabaraToastEntree {
  from { opacity: 0; transform: translateX(24px); }
  to { opacity: 1; transform: translateX(0); }
}
@keyframes fabaraToastSortie {
  from { opacity: 1; transform: translateX(0); }
  to { opacity: 0; transform: translateX(24px); }
}
@media (max-width: 640px) {
  .fabara-toast-wrap { left: 16px; right: 16px; width: auto; max-width: none; }
}
.nav-cta {
  background: var(--green-main); color: var(--white) !important;
  padding: 0.55rem 1.4rem; border-radius: 50px;
  font-weight: 600; font-size: 0.9rem;
  transition: background var(--transition), transform 0.15s;
}
.nav-cta:hover { background: var(--green-dark) !important; transform: translateY(-1px); }
.nav-toggle {
  display: none; flex-direction: column; gap: 5px;
  cursor: pointer; background: none; border: none; padding: 5px;
}
.nav-toggle span {
  width: 24px; height: 2px; background: var(--green-dark);
  border-radius: 2px; transition: 0.3s; display: block;
}
.nav-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.nav-toggle.active span:nth-child(2) { opacity: 0; }
.nav-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* ========== BOUTONS ========== */
.btn-primary {
  background: var(--gold); color: var(--green-dark);
  padding: 0.85rem 2rem; border-radius: 50px;
  font-weight: 700; font-size: 1rem; border: none;
  transition: transform var(--transition), box-shadow var(--transition);
  display: inline-flex; align-items: center; gap: 0.5rem;
  cursor: pointer;
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(249,168,37,0.4);
  color: var(--green-dark);
}

.btn-outline {
  border: 2px solid rgba(255,255,255,0.5); color: var(--white);
  padding: 0.85rem 2rem; border-radius: 50px;
  font-weight: 600; font-size: 1rem; background: transparent;
  transition: background var(--transition), border-color var(--transition);
  display: inline-flex; align-items: center; gap: 0.5rem;
  cursor: pointer;
}
.btn-outline:hover {
  background: rgba(255,255,255,0.1);
  border-color: rgba(255,255,255,0.8);
  color: white;
}

.btn-green {
  background: var(--green-main); color: var(--white);
  padding: 0.7rem 1.6rem; border-radius: 50px;
  font-weight: 600; font-size: 0.9rem; border: none;
  transition: background var(--transition), transform 0.15s;
  display: inline-flex; align-items: center; gap: 0.4rem;
  cursor: pointer;
}
.btn-green:hover { background: var(--green-dark); transform: translateY(-1px); color: white; }

.btn-white {
  background: var(--white); color: var(--green-main);
  padding: 0.7rem 1.6rem; border-radius: 50px;
  font-weight: 600; font-size: 0.9rem;
  border: 2px solid var(--white);
  transition: background var(--transition);
  display: inline-flex; align-items: center; gap: 0.4rem;
}
.btn-white:hover { background: var(--green-pale); }

.btn-danger {
  background: #fee2e2; color: var(--danger);
  padding: 0.5rem 1rem; border-radius: 8px;
  font-weight: 600; font-size: 0.85rem; border: none;
  transition: background var(--transition);
  cursor: pointer;
}
.btn-danger:hover { background: #fecaca; }

.btn-full { width: 100%; justify-content: center; }

/* ========== HERO GÉNÉRIQUE ========== */
.page-hero {
  padding: 120px 5% 60px;
  background: linear-gradient(135deg, var(--green-dark) 0%, var(--green-main) 60%, var(--green-mid) 100%);
  color: var(--white); text-align: center;
  position: relative; overflow: hidden;
}
.page-hero::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(circle at 30% 70%, rgba(255,255,255,0.05), transparent 60%),
              radial-gradient(circle at 70% 30%, rgba(249,168,37,0.08), transparent 60%);
}
.page-hero-content { position: relative; z-index: 2; max-width: 700px; margin: 0 auto; }
.page-hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.25);
  color: var(--white); padding: 0.4rem 1rem;
  border-radius: 50px; font-size: 0.85rem;
  font-weight: 500; margin-bottom: 1.5rem;
}
.page-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  font-weight: 900; line-height: 1.1;
  margin-bottom: 1rem; color: var(--white);
}
.page-hero h1 em { color: var(--gold); font-style: normal; }
.page-hero p {
  font-size: 1.1rem; color: rgba(255,255,255,0.85);
  line-height: 1.7; margin-bottom: 2rem;
  max-width: 520px; margin-left: auto; margin-right: auto;
}
.page-hero-btns { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* ========== CARDS ========== */
.card {
  background: var(--white); border-radius: var(--radius-lg);
  border: 1px solid var(--green-pale);
  transition: box-shadow var(--transition), transform var(--transition);
  overflow: hidden;
}
.card:hover { box-shadow: var(--shadow); transform: translateY(-4px); }

.card-body { padding: 1.5rem; }
.card-title { font-size: 1.1rem; font-weight: 600; margin-bottom: 0.5rem; }
.card-text  { font-size: 0.9rem; color: var(--gray-mid); line-height: 1.6; }

/* ========== FORMULAIRES ========== */
.form-card {
  background: var(--white); border-radius: var(--radius-lg);
  padding: 2.5rem; border: 1px solid var(--green-pale);
  box-shadow: var(--shadow);
}
.form-title {
  font-family: var(--font-display);
  font-size: 1.8rem; font-weight: 700;
  margin-bottom: 0.4rem; color: var(--text);
}
.form-subtitle {
  font-size: 0.95rem; color: var(--gray-mid);
  margin-bottom: 2rem; line-height: 1.6;
}
.form-group {
  display: flex; flex-direction: column;
  gap: 0.4rem; margin-bottom: 1.2rem;
}
.form-group label {
  font-size: 0.85rem; font-weight: 600;
  color: var(--text);
}
.form-group input,
.form-group select,
.form-group textarea {
  border: 1.5px solid var(--green-pale);
  border-radius: var(--radius); padding: 0.8rem 1rem;
  font-family: var(--font-body); font-size: 0.95rem;
  color: var(--text); background: var(--green-bg);
  transition: border-color var(--transition), background var(--transition);
  outline: none; width: 100%;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--green-main); background: var(--white);
  box-shadow: 0 0 0 3px rgba(46,125,50,0.08);
}
.form-group textarea { min-height: 120px; resize: vertical; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-error { color: var(--danger); font-size: 0.82rem; margin-top: 0.2rem; }
.form-info {
  background: var(--green-bg); color: var(--green-dark);
  border: 1px solid var(--green-pale);
  padding: 1rem 1.2rem; border-radius: var(--radius);
  font-size: 0.9rem; margin-top: 1.2rem;
}
.form-success {
  background: #d1fae5; color: #065f46;
  padding: 1rem 1.2rem; border-radius: var(--radius);
  font-size: 0.9rem; margin-bottom: 1.5rem;
  text-align: center;
}

/* ========== BADGES & TAGS ========== */
.badge {
  display: inline-block; padding: 0.25rem 0.8rem;
  border-radius: 50px; font-size: 0.75rem; font-weight: 600;
}
.badge-green  { background: var(--green-bg);  color: var(--green-main); }
.badge-gold   { background: var(--gold-light); color: #B45309; }
.badge-danger { background: #fee2e2; color: var(--danger); }
.badge-gray   { background: var(--gray-light); color: var(--gray-mid); }

/* ========== STATS BAND ========== */
.stats-band { background: var(--green-main); padding: 3rem 5%; }
.stats-grid {
  max-width: 1140px; margin: 0 auto;
  display: grid; grid-template-columns: repeat(4,1fr);
  gap: 2rem; text-align: center;
}
.stat-item { padding: 1rem; }
.stat-number {
  font-family: var(--font-display);
  font-size: 2.8rem; font-weight: 900;
  color: var(--white); line-height: 1;
}
.stat-label { font-size: 0.88rem; color: rgba(255,255,255,0.8); margin-top: 0.4rem; }
.stat-accent { color: var(--gold); }

/* ========== MODAL ========== */
.modal {
  display: none; position: fixed; inset: 0;
  background: rgba(0,0,0,0.5);
  backdrop-filter: blur(6px);
  align-items: center; justify-content: center;
  z-index: 2000;
}
.modal.open { display: flex; }
.modal-box {
  background: var(--white); border-radius: var(--radius-lg);
  padding: 2.5rem; max-width: 480px; width: 90%;
  box-shadow: var(--shadow-lg);
  animation: modalIn 0.3s ease;
}
@keyframes modalIn {
  from { opacity: 0; transform: scale(0.9) translateY(20px); }
  to   { opacity: 1; transform: scale(1)   translateY(0); }
}
.modal-title {
  font-family: var(--font-display);
  font-size: 1.5rem; font-weight: 700;
  margin-bottom: 0.8rem; color: var(--text);
}
.modal-text  { font-size: 0.95rem; color: var(--gray-mid); margin-bottom: 1.5rem; line-height: 1.6; }
.modal-btns  { display: flex; flex-direction: column; gap: 0.8rem; }

/* ========== FOOTER ========== */
.footer-main {
  background: var(--gray-dark); color: rgba(255,255,255,0.85);
  padding: 4rem 5% 2rem;
}
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem; margin-bottom: 3rem;
  max-width: 1140px; margin-left: auto; margin-right: auto;
}
.footer-logo {
  font-family: var(--font-display);
  font-size: 2rem; font-weight: 900;
  color: var(--white); margin-bottom: 1rem;
}
.footer-logo span { color: var(--gold); }
.footer-desc {
  font-size: 0.88rem; color: rgba(255,255,255,0.55);
  line-height: 1.7; margin-bottom: 1.5rem;
}
.footer-col h4 {
  font-size: 0.88rem; font-weight: 600;
  color: var(--white); margin-bottom: 1rem; letter-spacing: 0.5px;
}
.footer-col ul { display: flex; flex-direction: column; gap: 0.5rem; }
.footer-col ul li a {
  font-size: 0.85rem; color: rgba(255,255,255,0.5);
  transition: color var(--transition);
}
.footer-col ul li a:hover { color: var(--green-light); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 1.5rem; max-width: 1140px;
  margin: 0 auto;
  display: flex; justify-content: space-between;
  align-items: center; flex-wrap: wrap; gap: 1rem;
}
.footer-bottom p { font-size: 0.82rem; color: rgba(255,255,255,0.4); }

/* Footer réellement utilisé par partials/footer.blade.php (.footer-new) —
   ces règles vivaient dans l'ancien public/css/index.css, supprimé lors du
   nettoyage du CSS mort ; celui-ci a été retiré par erreur sans vérifier
   que le footer partagé en dépendait encore. */
.footer-new { background: var(--gray-dark); color: rgba(255,255,255,0.85); padding: 4rem 5% 2rem; }
.footer-brand .logo-footer { font-family: var(--font-display); font-size: 2rem; font-weight: 900; color: var(--white); margin-bottom: 1rem; }
.footer-brand .logo-footer span { color: var(--gold); }
.footer-brand p { font-size: 0.9rem; line-height: 1.7; color: rgba(255,255,255,0.6); margin-bottom: 1.5rem; }
.footer-socials { display: flex; gap: 0.8rem; }
.social-link {
  width: 38px; height: 38px; border-radius: 50%;
  background: rgba(255,255,255,0.08); display: flex; align-items: center; justify-content: center;
  font-size: 0.9rem; color: rgba(255,255,255,0.7); transition: background 0.2s, color 0.2s;
}
.social-link:hover { background: var(--green-main); color: var(--white); }
.footer-bottom-new {
  border-top: 1px solid rgba(255,255,255,0.08); padding-top: 1.5rem;
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 1rem;
}
.footer-bottom-new p { font-size: 0.82rem; color: rgba(255,255,255,0.4); }

/* ========== ANIMATIONS ========== */
.fade-up {
  opacity: 1; transform: translateY(0);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-up.visible { opacity: 1; transform: translateY(0); }

.fade-in {
  opacity: 0;
  transition: opacity 0.6s ease;
}
.fade-in.visible { opacity: 1; }

/* ========== TABLES ========== */
.table-card {
  background: var(--white); border-radius: var(--radius-lg);
  overflow: hidden; box-shadow: var(--shadow);
}
.table-header {
  padding: 1.2rem 1.5rem;
  border-bottom: 1px solid var(--green-pale);
}
.table-header h3 { font-size: 1.1rem; font-weight: 600; }
table { width: 100%; border-collapse: collapse; }
thead tr { background: var(--green-bg); }
th {
  padding: 1rem 1.2rem; text-align: left;
  font-size: 0.82rem; font-weight: 600;
  color: var(--gray-mid); text-transform: uppercase;
  letter-spacing: 0.5px;
}
tbody tr { border-top: 1px solid #f5f5f5; transition: background var(--transition); }
tbody tr:hover { background: var(--green-bg); }
td { padding: 1rem 1.2rem; font-size: 0.92rem; }

/* ========== RESPONSIVE ========== */
@media (max-width: 992px) {
  .stats-grid { grid-template-columns: repeat(2,1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
}

/* NAVBAR — palier tablette + mobile de l'accueil (aligné avec le palier
   1099px introduit dans navbar.blade.php pour nav-right-minimal-home) */
@media (max-width: 1099px) {
  .nav-toggle { display: flex; }
  .nav-links.open {
    display: flex; flex-direction: column;
    position: absolute; top: 72px; left: 0; right: 0;
    background: var(--white); padding: 1.5rem 5%;
    border-bottom: 1px solid var(--green-pale);
    gap: 1rem; box-shadow: 0 8px 20px rgba(0,0,0,0.08);
    z-index: 999;
  }
}

@media (max-width: 768px) {
  .section { padding: 3.5rem 5%; }

  /* HERO */
  .page-hero { padding: 100px 5% 40px; }
  .page-hero h1 { font-size: 2.2rem; }
  .page-hero-btns { flex-direction: column; align-items: center; }
  .page-hero-btns .btn-primary,
  .page-hero-btns .btn-outline { width: 100%; justify-content: center; }

  /* FORMS */
  .form-grid { grid-template-columns: 1fr; }
  .form-card { padding: 1.5rem; }

  /* FOOTER */
  .footer-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .footer-bottom { flex-direction: column; text-align: center; }

  /* STATS */
  .stats-grid { grid-template-columns: 1fr 1fr; gap: 1rem; }
  .stat-number { font-size: 2.2rem; }

  /* SECTION HEADER */
  .section-header-flex { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .section-title-page { font-size: 1.7rem; }
  .navbar { padding: 0 4%; }
}

.nav-logout {
    background: none; border: none;
    color: var(--gray-dark); font-size: 0.95rem;
    font-weight: 500; cursor: pointer;
    font-family: var(--font-body);
    padding: 0; transition: color var(--transition);
}
.nav-logout:hover { color: var(--danger); }

.nav-logout {
    background: none; border: none;
    color: var(--gray-dark); font-size: 0.95rem;
    font-weight: 500; cursor: pointer;
    font-family: var(--font-body); padding: 0;
    transition: color var(--transition);
}
.nav-logout:hover { color: var(--danger); }

/* ── Google OAuth ── */
.auth-google-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    width: 100%;
    padding: 0.75rem 1rem;
    background: #fff;
    color: #3c4043;
    border: 1.5px solid #dadce0;
    border-radius: 8px;
    font-family: 'DM Sans', sans-serif;
    font-size: 0.95rem;
    font-weight: 500;
    text-decoration: none;
    transition: background 0.2s, box-shadow 0.2s;
    margin-bottom: 1.25rem;
}

.auth-google-btn:hover {
    background: #f8f9fa;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.auth-divider {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.25rem;
    color: var(--gray-mid);
    font-size: 0.85rem;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e5e7eb;
}

/* ========== SEARCH ========== */
.nav-search {
    position: relative;
    flex: 1;
    max-width: 380px;
    margin: 0 1.5rem;
}

.search-wrapper {
    display: flex;
    align-items: center;
    background: var(--green-bg);
    border: 1.5px solid var(--green-pale);
    border-radius: 50px;
    padding: 0.45rem 1rem;
    gap: 0.5rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.search-wrapper:focus-within {
    border-color: var(--green-main);
    box-shadow: 0 0 0 3px rgba(46,125,50,0.08);
    background: white;
}

.search-icon {
    width: 16px; height: 16px;
    color: var(--gray-mid);
    flex-shrink: 0;
}

.search-input {
    border: none;
    background: transparent;
    outline: none;
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: var(--text);
    width: 100%;
}

.search-input::placeholder { color: var(--gray-mid); }

.search-clear {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--gray-mid);
    display: flex;
    align-items: center;
    padding: 0;
    flex-shrink: 0;
}

.search-clear:hover { color: var(--text); }

/* DROPDOWN */
.search-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    left: 0; right: 0;
    background: white;
    border-radius: 16px;
    box-shadow: 0 12px 40px rgba(0,0,0,0.12);
    border: 1px solid var(--green-pale);
    overflow: hidden;
    z-index: 9999;
    max-height: 400px;
    overflow-y: auto;
}

.search-result-item {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.8rem 1rem;
    text-decoration: none;
    color: var(--text);
    transition: background 0.15s;
    border-bottom: 1px solid #f5f5f5;
}

.search-result-item:last-child { border-bottom: none; }
.search-result-item:hover { background: var(--green-bg); }

.search-result-img {
    width: 44px; height: 44px;
    border-radius: 8px;
    object-fit: cover;
    flex-shrink: 0;
    background: var(--green-bg);
}

.search-result-placeholder {
    width: 44px; height: 44px;
    border-radius: 8px;
    background: var(--green-bg);
    display: flex; align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.search-result-info { flex: 1; min-width: 0; }
.search-result-nom {
    font-weight: 600;
    font-size: 0.9rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.search-result-meta {
    font-size: 0.78rem;
    color: var(--gray-mid);
    margin-top: 0.1rem;
}
.search-result-prix {
    font-family: var(--font-display);
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--green-main);
    flex-shrink: 0;
}

.search-result-badge {
    font-size: 0.72rem;
    background: var(--green-bg);
    color: var(--green-dark);
    padding: 0.15rem 0.5rem;
    border-radius: 50px;
    font-weight: 600;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* RESPONSIVE SEARCH */
@media (max-width: 992px) {
    .nav-search { max-width: 250px; }
}

@media (max-width: 768px) {
    .nav-search {
        display: none;
        position: fixed;
        top: 72px; left: 0; right: 0;
        max-width: 100%;
        margin: 0;
        padding: 0.8rem 5%;
        background: white;
        border-bottom: 1px solid var(--green-pale);
        box-shadow: 0 4px 12px rgba(0,0,0,0.08);
        z-index: 998;
    }
    .nav-search.mobile-open { display: block; }
    .search-dropdown { border-radius: 0 0 16px 16px; }

    /* Bouton recherche mobile dans navbar */
    .nav-search-toggle {
        display: flex !important;
        background: none;
        border: none;
        cursor: pointer;
        color: var(--green-dark);
        padding: 5px;
    }
}

@media (min-width: 769px) {
    .nav-search-toggle { display: none; }
}

/* ==========================================================
   CATALOGUE — grille produits, carte produit, favoris, filtres
   Partagé par catalogue/produits.blade.php, catalogue/boutique.blade.php
   et favoris/index.blade.php (toutes réutilisent produit-card.blade.php
   et produits-grid.blade.php). 2 colonnes mobile minimum, 6 en grand
   desktop (cf. chantier Catalogue/Tri/Favoris).
   ========================================================== */
.produits-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.9rem; }
.produit-card {
    background: var(--white); border: 1px solid var(--green-pale); border-radius: var(--radius-lg);
    overflow: hidden; cursor: pointer;
    transition: box-shadow 0.3s, transform 0.3s;
}
.produit-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-5px); }
.produit-img-wrap { position: relative; height: 180px; overflow: hidden; }
.produit-img-wrap img { width: 100%; height: 100%; object-fit: cover; }
.produit-placeholder { height: 180px; background: linear-gradient(135deg, var(--green-bg), var(--green-pale)); display: flex; align-items: center; justify-content: center; font-size: 48px; }
.card-carousel-next {
    position: absolute; top: 50%; right: 8px; transform: translateY(-50%);
    width: 32px; height: 32px; border-radius: 50%; border: none;
    background: rgba(0,0,0,0.45); color: #fff; font-size: 1.3rem; line-height: 1;
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    transition: background 0.2s;
}
.card-carousel-next:hover { background: rgba(0,0,0,0.7); }
.produit-body { padding: 1.1rem; }
.produit-nom { font-size: 0.98rem; font-weight: 600; margin-bottom: 0.3rem; color: var(--text); }
.produit-boutique {
    display: flex; align-items: center; justify-content: space-between; gap: 6px;
    font-size: 0.8rem; color: var(--green-main); font-weight: 600; margin-bottom: 0.4rem;
}
.produit-note {
    display: inline-flex; align-items: center; gap: 3px; flex-shrink: 0;
    color: var(--gold); font-weight: 700; font-size: 0.78rem;
}
.produit-note i { color: var(--gold); fill: var(--gold); }

/* Badges produit (Nouveau / Terroir) superposés en haut à gauche de la vignette */
.produit-badges {
    position: absolute; top: 8px; left: 8px; z-index: 2;
    display: flex; flex-direction: column; gap: 4px; align-items: flex-start;
}
.produit-badge {
    padding: 0.28rem 0.65rem; border-radius: 50px;
    font-size: 0.68rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.4px;
    box-shadow: var(--shadow);
}
.badge-nouveau { background: var(--gray-dark); color: var(--white); }
.badge-terroir { background: var(--green-main); color: var(--white); }
.badge-promo { background: var(--gold); color: var(--green-dark); }

.produit-prix-wrap { display: flex; align-items: baseline; gap: 0.5rem; margin-bottom: 0.8rem; flex-wrap: wrap; }
.produit-prix-promo { margin-bottom: 0 !important; color: var(--danger); }
.produit-prix-barre { font-size: 0.85rem; color: var(--gray-mid); text-decoration: line-through; }
.produit-prix { font-family: var(--font-display); font-size: 1.1rem; font-weight: 700; color: var(--green-main); margin-bottom: 0.8rem; }
.card-actions { display: flex; flex-direction: column; gap: 0.5rem; }
.btn-commander-direct {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    width: 100%; padding: 0.65rem 1rem; background: var(--green-main); color: #fff;
    border: none; border-radius: 8px; font-size: 0.85rem; font-weight: 700;
    cursor: pointer; font-family: var(--font-body); transition: background 0.2s, transform 0.1s;
}
.btn-commander-direct:hover { background: var(--green-dark); transform: translateY(-1px); }
.produit-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    background: var(--green-bg); color: var(--green-main); padding: 0.55rem 1rem;
    border-radius: 50px; font-size: 0.82rem; font-weight: 600; border: 1.5px solid var(--green-pale);
    cursor: pointer; transition: background 0.2s; font-family: var(--font-body); width: 100%;
}
.produit-btn:hover { background: var(--green-pale); }
.stock-rupture-badge { display: block; text-align: center; font-size: 0.8rem; color: #991b1b; font-weight: 600; }

/* Boutons favori (cœur) + partager superposés en haut à droite de la vignette */
.produit-card-actions-top {
    position: absolute; top: 8px; right: 8px; z-index: 2;
    display: flex; flex-direction: column; gap: 6px;
}
.produit-favori-btn, .produit-partager-btn {
    width: 34px; height: 34px; border-radius: 50%;
    background: rgba(255,255,255,0.92); border: none; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    box-shadow: var(--shadow); transition: transform 0.15s;
    text-decoration: none;
}
.produit-favori-btn svg { width: 17px; height: 17px; color: var(--gray-mid); transition: color 0.2s; }
.produit-favori-btn.active svg { color: #dc2626; fill: #dc2626; }
.produit-favori-btn:active, .produit-partager-btn:active { transform: scale(0.9); }
.produit-partager-btn svg { width: 16px; height: 16px; color: var(--gray-mid); }

@media (max-width: 599px) {
    .produit-body { padding: 0.8rem; }
    .produit-nom { font-size: 0.86rem; }
    .produit-boutique { font-size: 0.72rem; }
    .produit-prix { font-size: 0.95rem; margin-bottom: 0.6rem; }
    .btn-commander-direct, .produit-btn { font-size: 0.74rem; padding: 0.55rem 0.5rem; }
    .produit-img-wrap, .produit-placeholder { height: 130px; }
}

@media (min-width: 480px) {
    .produits-grid { gap: 1.1rem; }
}
@media (min-width: 768px) {
    .produits-grid { grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
}
@media (min-width: 1100px) {
    .produits-grid { grid-template-columns: repeat(4, 1fr); }
}
@media (min-width: 1400px) {
    .produits-grid { grid-template-columns: repeat(6, 1fr); }
    .cat-wrapper { max-width: 1400px; }
}

/* Chips catégories — toujours visibles, défilement horizontal au pouce */
.categorie-chips-wrap {
    overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none;
    margin-bottom: 0.9rem;
}
.categorie-chips-wrap::-webkit-scrollbar { display: none; }
.categorie-chips { display: flex; gap: 0.6rem; padding-bottom: 2px; }
.categorie-chip {
    flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px;
    padding: 0.55rem 1.1rem; border-radius: 50px;
    border: 1.5px solid var(--green-pale); background: var(--white); color: var(--text);
    font-size: 0.85rem; font-weight: 600; white-space: nowrap;
    transition: background 0.2s, border-color 0.2s, color 0.2s;
}
.categorie-chip:hover { border-color: var(--green-main); }
.categorie-chip.active { background: var(--green-main); border-color: var(--green-main); color: var(--white); }
.categorie-chip.small { padding: 0.4rem 0.85rem; font-size: 0.78rem; }

.souscategorie-chips {
    display: flex; gap: 0.5rem; flex-wrap: wrap; align-items: center;
    margin-bottom: 1.1rem;
}
.souscategorie-label { font-size: 0.8rem; font-weight: 600; color: var(--gray-mid); margin-right: 0.3rem; }

/* Barre résultats + tri — toujours visible au-dessus de la grille */
.resultats-bar {
    display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap;
    gap: 0.75rem; margin-bottom: 1.25rem;
}
.resultats-count { font-size: 0.88rem; color: var(--gray-mid); font-weight: 500; }
.resultats-actions { display: flex; align-items: center; gap: 0.6rem; flex-wrap: wrap; }
.tri-select {
    padding: 0.55rem 0.9rem; border: 1.5px solid var(--green-pale); border-radius: 50px;
    font-family: var(--font-body); font-size: 0.85rem; color: var(--text);
    background: var(--white); cursor: pointer;
}

/* Panneau "Filtres avancés" repliable (catalogue) */
.filtres-toggle-btn {
    display: inline-flex; align-items: center; gap: 0.5rem;
    background: var(--white); color: var(--green-dark); border: 1.5px solid var(--green-pale);
    padding: 0.6rem 1.1rem; border-radius: 50px; font-weight: 600; font-size: 0.88rem;
    cursor: pointer; font-family: var(--font-body); transition: border-color 0.2s, background 0.2s;
}
.filtres-toggle-btn:hover { border-color: var(--green-main); background: var(--green-bg); }
.filtres-toggle-btn i { width: 16px; height: 16px; }
.filtres-badge {
    background: var(--green-main); color: #fff; border-radius: 50%;
    min-width: 20px; height: 20px; padding: 0 4px;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 0.7rem; font-weight: 700;
}
.filtres-panel {
    display: none; background: var(--white); border: 1px solid var(--green-pale);
    border-radius: var(--radius-lg); padding: 1.25rem; margin-bottom: 1.5rem;
    box-shadow: var(--shadow);
}
.filtres-panel.open { display: block; }
.filtres-form { display: flex; flex-direction: column; gap: 1rem; }
.filtre-field { display: flex; flex-direction: column; gap: 0.35rem; }
.filtre-field label { font-size: 0.8rem; font-weight: 600; color: var(--gray-mid); }
.filtre-field input, .filtre-field select {
    padding: 0.65rem 0.8rem; border: 1.5px solid var(--green-pale); border-radius: 8px;
    font-family: var(--font-body); font-size: 0.9rem; color: var(--text);
}
.filtre-field-row { display: flex; gap: 0.75rem; }
.filtre-field-row .filtre-field { flex: 1; }
.filtres-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; }
.filtres-actions .btn-green, .filtres-actions .btn-outline { flex: 1; text-align: center; min-width: 120px; }

@media (min-width: 768px) {
    .filtres-form { flex-direction: row; flex-wrap: wrap; align-items: flex-end; }
    .filtre-field { flex: 1; min-width: 160px; }
    .filtre-field-row { flex: 1.4; min-width: 220px; }
    .filtres-actions { flex: 0 0 auto; align-self: flex-end; }
    .filtres-actions .btn-green, .filtres-actions .btn-outline { flex: none; min-width: auto; }
}

/* ========== MODALE DE CONFIRMATION (remplace confirm() natif, tout le site) ========== */
.fabara-confirm-overlay {
    display: none; position: fixed; inset: 0; z-index: 10000;
    background: rgba(0,0,0,0.55);
    align-items: center; justify-content: center; padding: 1.2rem;
}
.fabara-confirm-overlay.open { display: flex; }
.fabara-confirm-box {
    background: var(--white); border-radius: 16px; padding: 2rem 1.75rem;
    width: 100%; max-width: 380px; text-align: center;
    box-shadow: 0 20px 60px rgba(0,0,0,0.22);
    animation: fabaraConfirmIn 0.2s ease;
}
@keyframes fabaraConfirmIn {
    from { opacity: 0; transform: translateY(14px) scale(0.97); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}
.fabara-confirm-icon {
    width: 52px; height: 52px; border-radius: 50%;
    background: var(--tone-amber-bg); color: var(--tone-amber-fg);
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 1.1rem;
}
.fabara-confirm-icon i { width: 24px; height: 24px; }
.fabara-confirm-message { font-size: 0.97rem; color: var(--text); line-height: 1.55; margin-bottom: 1.6rem; white-space: pre-line; }
.fabara-confirm-actions { display: flex; gap: 0.7rem; }
.fabara-confirm-actions button {
    flex: 1; padding: 0.7rem; border-radius: 50px; font-weight: 600; font-size: 0.9rem;
    cursor: pointer; font-family: var(--font-body); border: 1.5px solid transparent;
    transition: opacity 0.2s, transform 0.15s;
}
.fabara-confirm-annuler { background: var(--white); color: var(--text); border-color: var(--green-pale) !important; }
.fabara-confirm-annuler:hover { background: var(--green-bg); }
.fabara-confirm-ok { background: var(--danger); color: var(--white); }
.fabara-confirm-ok:hover { opacity: 0.88; }
/* Variante « positive » (data-confirm-ton="positif") : accepter, valider… */
.fabara-confirm-icone-positif { display: none; }
.fabara-confirm-positif .fabara-confirm-icone-alerte { display: none; }
.fabara-confirm-positif .fabara-confirm-icone-positif { display: block; }
.fabara-confirm-positif .fabara-confirm-icon { background: var(--green-bg); color: var(--green-main); }
.fabara-confirm-positif .fabara-confirm-ok { background: var(--green-main); }

/* ========== SPINNER DE CHARGEMENT (sur le bouton d'un formulaire envoyé) ========== */
.fabara-spinner {
    display: inline-block; width: 13px; height: 13px;
    border: 2px solid currentColor; border-right-color: transparent;
    border-radius: 50%; vertical-align: -2px; margin-right: 5px;
    animation: fabaraSpin 0.6s linear infinite;
}
@keyframes fabaraSpin { to { transform: rotate(360deg); } }

/* ========== MODALE GÉNÉRIQUE (détail / création / modification en overlay) ========== */
.fabara-modal-overlay {
    position: fixed; inset: 0; background: rgba(0,0,0,0.55);
    z-index: 9990; display: flex; align-items: center; justify-content: center;
    padding: 1.5rem; opacity: 0; pointer-events: none; transition: opacity 0.2s ease;
}
.fabara-modal-overlay.ouvert { opacity: 1; pointer-events: auto; }
.fabara-modal-box {
    background: var(--white); border-radius: var(--radius-lg); box-shadow: 0 20px 60px rgba(0,0,0,0.25);
    width: 100%; max-width: 640px; max-height: 90vh; display: flex; flex-direction: column;
    transform: translateY(16px); transition: transform 0.2s ease;
}
.fabara-modal-overlay.ouvert .fabara-modal-box { transform: translateY(0); }
.fabara-modal-header {
    display: flex; align-items: center; justify-content: space-between; gap: 1rem;
    padding: 1.1rem 1.4rem; border-bottom: 1px solid var(--green-pale); flex-shrink: 0;
}
.fabara-modal-header h3 { font-size: 1.05rem; font-weight: 700; color: var(--green-dark); margin: 0; }
.fabara-modal-close {
    background: var(--green-bg); border: none; width: 32px; height: 32px; border-radius: 50%;
    font-size: 1.3rem; line-height: 1; cursor: pointer; color: var(--green-dark); flex-shrink: 0;
}
.fabara-modal-close:hover { background: var(--green-pale); }
.fabara-modal-body { padding: 1.4rem; overflow-y: auto; }
.fabara-modal-body .vendor-form-wrapper { padding: 0; margin: 0; max-width: none; }
.fabara-modal-body .vendor-form-card { border: none; box-shadow: none; padding: 0; }
.fabara-modal-body .admin-page-header { margin-bottom: 1.2rem; }
.fabara-modal-loading { display: flex; align-items: center; justify-content: center; padding: 3rem; }
body.fabara-modal-ouvert { overflow: hidden; }
@media (max-width: 640px) {
    .fabara-modal-overlay { padding: 0; align-items: flex-end; }
    .fabara-modal-box { max-width: none; width: 100%; max-height: 92vh; border-radius: 20px 20px 0 0; }
}