/* --- Styles généraux --- */
body {
  margin: 0;
  font-family: Arial, sans-serif;
  background: #f7fff7;
  color: #333;
}

h1, h2, h3 {
  font-family: "Trebuchet MS", sans-serif;
}

/* --- Header & Menu --- */
header {
  background: #2d6a4f;
  color: white;
  padding: 20px;
  text-align: center;
}

nav a {
  color: white;
  margin: 0 10px;
  text-decoration: none;
  font-weight: bold;
}

nav a:hover {
  text-decoration: underline;
}

/* --- Intro / Sections --- */
.intro, .content {
  text-align: center;
  padding: 40px 20px;
}

.cta {
  display: inline-block;
  padding: 12px 20px;
  background: #40916c;
  color: white;
  border-radius: 6px;
  text-decoration: none;
  margin-top: 15px;
}

.cta:hover {
  background: #1b4332;
}

/* --- Galerie animée Ken Burns --- */
.hero-gallery {
  position: relative;
  width: 100%;
  height: 60vh;
  overflow: hidden;
}

.hero-gallery .slide {
  position: absolute;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  animation: kenburns 24s infinite;
  opacity: 0;
}

.hero-gallery .slide:nth-child(1) { animation-delay: 0s; }
.hero-gallery .slide:nth-child(2) { animation-delay: 6s; }
.hero-gallery .slide:nth-child(3) { animation-delay: 12s; }
.hero-gallery .slide:nth-child(4) { animation-delay: 18s; }

@keyframes kenburns {
  0% { opacity: 0; transform: scale(1); }
  5% { opacity: 1; }
  25% { opacity: 1; transform: scale(1.1); }
  30% { opacity: 0; }
  100% { opacity: 0; }
}

/* --- Grille des arbres --- */
.tree-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 25px;
  padding: 30px;
}

.tree-card {
  width: 260px;
  padding: 15px;
  border-radius: 12px;
  background: #f4fff4;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  animation: slideIn 1s ease forwards;
  opacity: 0;
}

.tree-card img {
  width: 100%;
  border-radius: 8px;
}

.tree-card .icon {
  font-size: 2rem;
  display: block;
  text-align: center;
  animation: pulse 2s infinite;
}

@keyframes slideIn {
  from { transform: translateY(40px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.3); }
  100% { transform: scale(1); }
}

/* --- Transition Terre → Plante → Arbre (version mosaïque animée évolutive) --- */
.transition-container {
  position: relative;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 15px;
  margin: 20px auto;
  max-width: 700px;
}

.transition-container img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  border-radius: 8px;
  opacity: 0;
  animation: fadeZoom 8s ease-in-out infinite;
  position: relative;
}

/* Délais automatiques basés sur --i */
.transition-container img:nth-child(n) {
  animation-delay: calc(var(--i) * 1.7s);
}

/* Positions pseudo-aléatoires (effet naturel) */
.transition-container img:nth-child(odd) {
  top: -10px;
  left: 8px;
  transform: rotate(-2deg);
}

.transition-container img:nth-child(even) {
  top: 12px;
  left: -6px;
  transform: rotate(2deg);
}

/* Animation douce */
@keyframes fadeZoom {
  0%   { opacity: 0; transform: scale(1); }
  10%  { opacity: 1; transform: scale(1.05); }
  40%  { opacity: 1; transform: scale(1.1); }
  60%  { opacity: 0; transform: scale(1.1); }
  100% { opacity: 0; transform: scale(1); }
}

/* Responsive */
@media (max-width: 600px) {
  .transition-container img {
    height: 120px;
  }
}




/* --- Formulaire de contact --- */
.contact-form {
  max-width: 500px;
  margin: auto;
  text-align: left;
}

.contact-form label {
  display: block;
  margin-top: 15px;
  font-weight: bold;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 10px;
  border-radius: 6px;
  border: 1px solid #ccc;
  margin-top: 5px;
}

.contact-form button {
  margin-top: 20px;
  padding: 12px 20px;
  background: #2d6a4f;
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}

.contact-form button:hover {
  background: #1b4332;
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .hero-gallery {
    height: 40vh;
  }
  header h1 {
    font-size: 1.4rem;
  }
  .tree-grid {
    flex-direction: column;
    align-items: center;
  }
}
.contact-page {
  max-width: 900px;
  margin: 0 auto;
  padding: 40px 20px;
  text-align: center;
}

.contact-header h2 {
  font-size: 1.8rem;
  color: #02163f;
  margin-bottom: 20px;
}

.contact-mail img {
  max-width: 100%;
  height: auto;
  margin: 20px 0;
}

.contact-intro h3 {
  font-size: 1.6rem;
  font-style: italic;
  color: #ffffff;
  background: #2d6a4f;
  display: inline-block;
  padding: 10px 20px;
  border-radius: 6px;
}

.separator {
  width: 200px;
  height: 4px;
  background: #40916c;
  margin: 10px auto 30px;
}

.contact-map p {
  font-size: 1.3rem;
  color: #02163f;
  margin-bottom: 15px;
}

.contact-map img {
  width: 100%;
  max-width: 780px;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}
.localisation-page {
  max-width: 900px;
  margin: 0 auto;
  padding: 40px 20px;
  text-align: center;
}

.localisation-icons {
  display: flex;
  justify-content: center;
  gap: 40px;
  margin: 30px 0;
}

.localisation-icons a {
  text-decoration: none;
  color: #2d6a4f;
  font-size: 1.1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.localisation-icons svg {
  width: 48px;
  height: 48px;
  margin-bottom: 8px;
}

.map-image {
  width: 100%;
  max-width: 780px;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

/* Animation douce et amusante */
.animated-map {
  animation: floatZoom 6s ease-in-out infinite;
}

@keyframes floatZoom {
  0%   { transform: scale(1) translateY(0); }
  50%  { transform: scale(1.03) translateY(-6px); }
  100% { transform: scale(1) translateY(0); }
}
/* --- MENU MODERNE UNIFIÉ --- */
.main-menu {
  background: #2d6a4f;
  padding: 12px 0;
  margin-bottom: 30px;
}

.main-menu ul {
  list-style: none;
  display: flex;
  justify-content: center;
  gap: 30px;
  padding: 0;
  margin: 0;
}

.main-menu a {
  color: white;
  text-decoration: none;
  font-size: 1.1rem;
  padding: 8px 14px;
  border-radius: 6px;
  transition: background 0.3s;
  font-weight: bold;
}

.main-menu a:hover {
  background: #40916c;
}

.main-menu .active {
  background: #1b4332;
}
/* --- HAMBURGER (mobile) --- */
.hamburger {
  display: none;
  width: 35px;
  height: 28px;
  flex-direction: column;
  justify-content: space-between;
  cursor: pointer;
  margin: 15px;
  z-index: 1001;
}

.hamburger div {
  height: 5px;
  background: #2d6a4f;
  border-radius: 5px;
  transition: 0.4s;
}

/* --- MENU MOBILE : effet branche qui pousse --- */
@media (max-width: 768px) {

  .hamburger {
    display: flex;
  }

  .main-menu {
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    overflow: hidden;
    background: #2d6a4f;
    border-bottom-right-radius: 40px;
    border-top-right-radius: 40px;
    height: 100vh;
    transform-origin: left center;
    transform: scaleX(0);
    transition: transform 0.7s cubic-bezier(0.25, 0.8, 0.25, 1),
                width 0s linear 0.7s;
    padding-top: 80px;
    z-index: 1000;
  }

  .main-menu.open {
    width: 70%;
    transform: scaleX(1);
    transition: transform 0.7s cubic-bezier(0.25, 0.8, 0.25, 1),
                width 0s;
  }

  .main-menu ul {
    flex-direction: column;
    gap: 25px;
    padding-left: 20px;
  }

  /* Effet bourgeons : les liens apparaissent un par un */
  .main-menu li {
    opacity: 0;
    transform: translateX(-20px);
    animation: bud 0.6s forwards;
  }

  .main-menu.open li:nth-child(1) { animation-delay: 0.2s; }
  .main-menu.open li:nth-child(2) { animation-delay: 0.35s; }
  .main-menu.open li:nth-child(3) { animation-delay: 0.5s; }
  .main-menu.open li:nth-child(4) { animation-delay: 0.65s; }
  .main-menu.open li:nth-child(5) { animation-delay: 0.8s; }
  .main-menu.open li:nth-child(6) { animation-delay: 0.95s; }

  @keyframes bud {
    0% { opacity: 0; transform: translateX(-20px) scale(0.9); }
    100% { opacity: 1; transform: translateX(0) scale(1); }
  }

  .main-menu a {
    font-size: 1.3rem;
  }
}

/* --- Animation du hamburger en croix --- */
.hamburger.active div:nth-child(1) {
  transform: rotate(45deg) translateY(10px);
}

.hamburger.active div:nth-child(2) {
  opacity: 0;
}

.hamburger.active div:nth-child(3) {
  transform: rotate(-45deg) translateY(-10px);
}

