* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: Arial, sans-serif;
}

/* Navbar */
.navbar {
  display: flex;
  align-items: center;
  height: 70px;
  background: linear-gradient(to right, green, white);
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  padding: 0 40px;
  position: relative;
}

/* Logo */
.logo {
  display: flex;          /* inline flex = logo + title جنب بعضهم */
  align-items: center;    /* يحاذيهم وسطياً رأسياً */
  gap: 5px;              /* المسافة بين logo و title */
}

.logo-title {
  color: white;
  text-align: center;
  font-size: 22px;
  font-weight: bold;
  margin: 0;
}

.logo img {
  height: 65px;
}

/* Menu */
.nav-menu {
  list-style: none;
  display: flex;
  gap: 90px;

  /* centre */
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.nav-menu li a {
  text-decoration: none;
  color: #004d00; /* WHITE */
  font-size: 1rem;
  font-weight: bold;
  transition: 0.3s;
}

/* Hover effect */
.nav-menu li a:hover {
  color: #d4ffd9; /* white/green light */
}



.produits-page {
  display: flex;
  gap: 30px;
  padding: 30px;
}

/* LEFT */
.sidebar {
  width: 250px;
  background: #f3f3f3;
  padding: 20px;
  border-radius: 10px;
}

.sidebar h3 {
  margin-bottom: 15px;
  color: green;
}

.filter-btn, .toggle-btn {
  display: block;
  width: 100%;
  margin-bottom: 10px;
  padding: 10px;
  border: none;
  background: white;
  cursor: pointer;
  text-align: left;
}

.filter-btn:hover {
  background: #dff0d8;
}

/* hidden tags */
.sub-tags {
  display: none;
  margin-left: 10px;
}

/* RIGHT */
.products {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 20px;
}

.product {
  border: 1px solid #ddd;
  padding: 15px;
  text-align: center;
  border-radius: 10px;
}

.product img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}


.footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: linear-gradient(to right, #111, #222);
  color: white;
  padding: 25px 60px;
  flex-wrap: wrap;
}

/* Left */
.footer-left {
  flex: 1;
  font-size: 14px;
}

.footer-left p {
  margin-bottom: 8px;
}

.socials span {
  display: inline-block;
  margin-right: 15px;
  font-size: 14px;
}

/* Center */
.footer-center {
  flex: 1;
  text-align: center;
}

.footer-center img {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: white;
  padding: 5px;
}

/* Right */
.footer-right {
  flex: 1;
  text-align: right;
  font-size: 14px;
}

.footer-right p {
  margin-bottom: 8px;
}

.footer a {
  text-decoration: none;
  color: white;
}


/* 📱📱 Mobile + Tablet (no PC) */
@media screen and (max-width: 1024px) {

  /* ===== BODY ===== */
  body {
    overflow-x: hidden;
  }

  /* ===== NAVBAR ===== */
  .navbar {
    flex-direction: column;
    height: auto;
    padding: 15px 20px;
    text-align: center;
  }

  .logo {
    justify-content: center;
  }

  .logo-title {
    display: none;
  }

  .nav-menu {
    position: static;
    transform: none;
    margin-top: 15px;
    flex-direction: column;
    gap: 15px;
    align-items: center;
  }

  /* ===== PAGE LAYOUT ===== */
  .produits-page {
    display: flex;
    flex-direction: row;        /* categorie left / products right */
    gap: 20px;
    padding: 20px;
  }

  /* ===== SIDEBAR / CATEGORIES ===== */
  .sidebar {
    width: 200px;
    max-height: calc(100vh - 140px); /* height dyal screen */
    overflow-y: auto;                /* ✅ scroll مستقل */
    position: sticky;
    top: 20px;
    padding-right: 5px;
  }

  /* scrollbar خفيفة */
  .sidebar::-webkit-scrollbar {
    width: 6px;
  }

  .sidebar::-webkit-scrollbar-thumb {
    background: #2e7d32;
    border-radius: 10px;
  }

  /* ===== PRODUCTS ===== */
  .products {
    flex: 1;
    display: flex;
    flex-direction: column;     /* wa7d t7t wa7d */
    align-items: center;
    gap: 25px;
  }

  .product {
    width: 260px;
    max-width: 100%;
  }

  .product img {
    height: 160px;
    object-fit: contain;
  }

  /* ===== FOOTER ===== */
  .footer {
    flex-direction: column;
    text-align: center;
    padding: 30px 20px;
    gap: 20px;
  }

  .footer-left,
  .footer-center,
  .footer-right {
    width: 100%;
  }
}

@media screen and (max-width: 480px) {

  .produits-page {
    flex-direction: column;
  }

  .sidebar {
    width: 100%;
    max-height: 200px;   /* scroll صغيّر */
  }

  .product {
    width: 200px;
  }
}
