/* ----------------------------------
   GLOBAL
---------------------------------- */
body {
  font-family: 'Poppins', sans-serif;
  background: linear-gradient(135deg, #0f2027, #203a43, #2c5364);
  color: #f5f5f5;
  margin: 0;
  padding: 0;
  text-align: center;
  min-height: 100vh;
}

/* Défilement fluide */
html {
  scroll-behavior: smooth;
}

::selection {
  background-color: #4dd0e1;
  color:#fff;
}

/* ----------------------------------
   HEADER
---------------------------------- */
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 60px;
  background: rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(10px);
  position: sticky;
  top: 0;
  z-index: 10;
}

.logo {
  display: block;
  width: 200px;       /* taille raisonnable */
  max-width: 60%;     /* responsive */
  height: auto;       /* garde les proportions */
  margin: 0;           /* pas de centrage, reste à gauche */
}

.logo img {
  width: 100%;
  height: auto;       /* conserve les proportions */
  display: block;
}

nav a {
  margin: 0 15px;
  text-decoration: none;
  color: #fff;
  transition: 0.3s;
  font-weight: 500;
}

nav a:hover {
  color: #4dd0e1;
}

/* --- PAGE D’ACCUEIL --- */

.hero-accueil {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 100px 5% 60px;
  min-height: 80vh;
  text-align: center;
  color: white;
  background: linear-gradient(135deg, rgba(15,32,39,0.8), rgba(44,83,100,0.8)),
              url('../img/hero_img.jpg') center/cover no-repeat;
}

.hero-content h1 {
  font-size: 3em;
  margin-bottom: 10px;
  font-weight: 700;
}

.hero-content p {
  font-size: 1.2em;
  margin-bottom: 30px;
  color: #ddd;
}

.about {
  padding: 80px 50px;
  background: linear-gradient(120deg, #0f2027, #203a43, #2c5364);
  color: white;
  text-align: center;
}

.about-content {
  max-width: 800px;
  margin: auto;
}

.about-content ul {
  list-style: none;
  padding: 0;
  margin-top: 25px;
}

.about-content li {
  margin: 10px 0;
  font-size: 1.1em;
}

/* ----------------------------------
   SECTION DE RECHERCHE
---------------------------------- */

.search-box {
  margin-top: 30px;
}

.search-box input {
  padding: 12px;
  width: 300px;
  border: none;
  border-radius: 25px 0 0 25px;
  outline: none;
}

.search-box button {
  padding: 12px 20px;
  border: none;
  background-color: #4dd0e1;
  color: black;
  border-radius: 0 25px 25px 0;
  cursor: pointer;
  font-weight: 600;
}

/* ----------------------------------
   HERO SECTION
---------------------------------- */
.hero {
  padding: 100px 5% 60px;
  text-align: center;
}

.hero h1 {
  font-size: 2.3em;
  color: #fff;
  margin-bottom: 40px;
}

/* ----------------------------------
   RESULTS GRID
---------------------------------- */

.results-section {
  padding: 80px 5%;
  text-align: center;
}

.results-section h1 {
  font-size: 2em;
  margin-bottom: 50px;
  color: #fff;
}

.results {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  padding: 0 5% 80px;
  justify-items: center;
}

/* ----------------------------------
   PRODUCT CARD
---------------------------------- */
.product {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 20px;
  padding: 20px;
  width: 100%;
  max-width: 320px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  transition: all 0.3s ease;
  box-shadow: 0 10px 25px rgba(0,0,0,0.1);
  min-height: 450px;
}

.product:hover {
  transform: translateY(-6px);
  background: rgba(255, 255, 255, 0.12);
  box-shadow: 0 15px 30px rgba(0,0,0,0.25);
}

.product img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: 15px;
  margin-bottom: 15px;
}

/* ----------------------------------
   PRODUCT CONTENT
---------------------------------- */
.product h3 {
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
  margin-bottom: 10px;
  line-height: 1.3em;
  height: 2.6em;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.price {
  font-size: 1.3em;
  font-weight: 700;
  color: #4dd0e1;
  margin-bottom: 8px;
}

.shipping {
  display: block;
  font-size: 0.9em;
  margin-bottom: 12px;
}

.shipping.free {
  color: #4dd0e1;
  font-weight: 600;
}

.shipping.paid {
  color: #ffb74d;
}

.shipping.unknown {
  color: #bbb;
}

/* ----------------------------------
   BUTTON LINK
---------------------------------- */
.product a {
  background: #4dd0e1;
  color: #000;
  text-decoration: none;
  padding: 10px 25px;
  border-radius: 25px;
  font-weight: 600;
  transition: 0.3s;
}

.product a:hover {
  background: #2bc2d8;
  transform: scale(1.05);
}

/* ----------------------------------
   FOOTER
---------------------------------- */
footer {
  background: rgba(0,0,0,0.3);
  color: #aaa;
  text-align: center;
  padding: 25px;
  font-size: 0.9em;
  border-top: 1px solid rgba(255,255,255,0.1);
}

/* ----------------------------------
   RESPONSIVE
---------------------------------- */

/* Tablettes et petits écrans */
@media screen and (max-width: 1024px) {
  header {
    flex-direction: column;
    padding: 15px 20px;
  }

  nav {
    margin-top: 10px;
  }

  nav a {
    margin: 0 10px;
    font-size: 0.95em;
  }

  .hero-accueil {
    padding: 80px 5% 40px;
  }

  .hero-content h1 {
    font-size: 2.5em;
  }

  .hero-content p {
    font-size: 1.1em;
  }

  .results {
    gap: 20px;
    padding: 0 3% 60px;
  }
}

/* Smartphones (portrait) */
@media screen and (max-width: 768px) {
  header {
    flex-direction: column;
    align-items: flex-start;
    padding: 12px 15px;
  }

  .logo {
    max-width: 50%;
    margin-bottom: 10px;
  }

  nav a {
    margin: 5px 8px;
    font-size: 0.9em;
  }

  .hero-accueil {
    padding: 60px 5% 30px;
  }

  .hero-content h1 {
    font-size: 2em;
  }

  .hero-content p {
    font-size: 1em;
  }

  .search-box input {
    width: 200px;
    padding: 10px;
  }

  .search-box button {
    padding: 10px 15px;
  }

  .results {
    grid-template-columns: 1fr;
    padding: 0 5% 40px;
  }

  .product {
    min-height: auto;
    padding: 15px;
  }

  .product img {
    height: 180px;
  }

  .product h3 {
    font-size: 0.95rem;
    height: auto;
  }

  .price {
    font-size: 1.1em;
  }

  .product a {
    padding: 8px 20px;
    font-size: 0.9em;
  }
}

/* Très petits écrans (téléphones anciens ou portrait très fin) */
@media screen and (max-width: 480px) {
  header {
    padding: 10px 10px;
  }

  .logo {
    max-width: 60%;
  }

  .hero-content h1 {
    font-size: 1.7em;
  }

  .hero-content p {
    font-size: 0.95em;
  }

  .search-box input {
    width: 150px;
    padding: 8px;
  }

  .search-box button {
    padding: 8px 12px;
  }

  .product img {
    height: 150px;
  }

  .price {
    font-size: 1em;
  }

  .product a {
    padding: 7px 15px;
    font-size: 0.85em;
  }
}