/* RESET */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Couleur UTBDM */
.text-green {
  color: #8dc63f;
}

/* GLOBAL */
html,
body {
  min-height: 100vh;
}

body {
  display: flex;
  flex-direction: column;
  background: #f5f5f5;
  color: #222;
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
  line-height: 1.6;
}

/* TYPO SPORTIVE */
h1,
h2,
h3,
nav a {
  font-family: "Bebas Neue", sans-serif;
  letter-spacing: 1px;
}

/* ===== MAIN ===== */
main {
  flex: 1;
  width: 100%;
  max-width: 1100px;
  margin: 2rem auto;
  padding: 0 1rem;
}

/* ===== HERO (bannière) ===== */
.hero-image {
  width: 100%;
  height: 450px;
  background-image: url("../img/fond-colza.webp");
  background-size: cover;
  background-position: center;
  border-radius: 20px;
  overflow: hidden;
  position: relative;

  display: flex;
  align-items: center;
  justify-content: center;

  margin-bottom: 4rem;
}

.hero-image::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
}

.hero-content {
  z-index: 2;
  color: white;
  text-align: center;
}

.hero-content h1 {
  font-size: 5rem;
  line-height: 1; /* Tighten line height to keep title compact */
}

.hero-by {
  display: block;
  font-size: 2rem; /* Significantly smaller */
  margin-top: 1rem;
  letter-spacing: 2px;
}

/* ===== QUI SOMMES-NOUS ===== */
.about {
  display: flex;
  align-items: center;
  gap: 2.5rem;
  margin-bottom: 4rem;
}

.about-left {
  flex: 0 0 40%;
  display: flex;
  justify-content: center;
}

.about-logo {
  width: 80%;
  max-width: 420px;
}

.about-right {
  flex: 1;
}

.about-right h2 {
  font-size: 3.7rem;
  margin-bottom: 1rem;
}

.about-right p {
  font-size: 1.35rem;
  line-height: 1.85;
  margin-bottom: 1.2rem;
}

/* ===== NOS COURSES ===== */
.courses-section {
  padding: 2rem 0;
}

.courses-section h2 {
  font-size: 3.7rem;
  text-align: center;
  margin-bottom: 1.5rem;
}

.course-link {
  text-decoration: none;
  color: inherit;
  display: block;
}

.course-block {
  background: white;
  border-radius: 15px;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.07);
  margin-bottom: 1.5rem;
  overflow: hidden;
  transition: 0.25s;
}

.course-block:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 25px rgba(0, 0, 0, 0.12);
}

.course-image {
  width: 100%;
}

.course-text {
  padding: 1.5rem;
}

.course-text h3 {
  font-size: 2.1rem;
  margin-bottom: 0.3rem;
}

.course-text p {
  font-size: 1.15rem;
  line-height: 1.6;
}




/* ===== PROCHAIN ÉVÉNEMENT ===== */
.next-event {
  margin-bottom: 4rem;
}

.next-event h2 {
  font-size: 3.7rem;
  text-align: center;
  margin-bottom: 1.5rem;
}

.event-card {
  background: white;
  border-radius: 15px;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.07);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.event-image {
  width: 100%;
  height: 300px;
  object-fit: cover;
}

.event-details {
  padding: 1.5rem;
  text-align: center;
}

.event-details h3 {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
}

.event-date {
  font-size: 1.5rem;
  color: #8dc63f;
  font-weight: bold;
  margin-bottom: 1rem;
  font-family: "Bebas Neue", sans-serif;
  letter-spacing: 1px;
}

@media (min-width: 768px) {
  .event-card {
    flex-direction: row;
  }

  .event-image {
    width: 50%;
    height: 400px;
  }

  .event-details {
    width: 50%;
    padding: 3rem;
    text-align: left;
  }
}

/* ===== DERNIÈRE ACTUALITÉ ===== */
.latest-news-section {
    margin-bottom: 4rem;
}

.latest-news-section h2 {
    font-size: 3.7rem;
    text-align: center;
    margin-bottom: 1.5rem;
}

.latest-news-card {
    background: white;
    border-radius: 15px;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.07);
    overflow: hidden;
    display: flex; /* Flex layout if image exists */
    flex-direction: column;
    margin-bottom: 2rem;
}

@media (min-width: 768px) {
    .latest-news-card.has-image {
        flex-direction: row;
    }
    .latest-news-card.has-image .latest-news-image {
        width: 40%;
        height: auto;
        object-fit: cover;
    }
    .latest-news-card.has-image .latest-news-content {
        width: 60%;
    }
}

.latest-news-image {
    width: 100%;
    height: 300px;
    object-fit: cover;
}

.latest-news-content {
    padding: 2rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.latest-news-date {
    font-size: 0.9rem;
    color: #888;
    margin-bottom: 0.5rem;
    font-weight: bold;
}

.latest-news-title {
    font-family: "Bebas Neue", sans-serif;
    font-size: 2.2rem;
    margin-bottom: 1rem;
    color: #2c3e50;
    line-height: 1.1;
}

.latest-news-text {
    font-size: 1.1rem;
    color: #555;
    margin-bottom: 1.5rem;
    flex-grow: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    /* Fallback for browsers not supporting line-clamp */
    max-height: 5.4rem; /* 1.1rem * 1.6 line-height * 3 lines + epsilon */
}

/* Container for buttons in latest news */
.latest-news-btns {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: auto; /* Push to bottom if flex column */
}

/* Override event-btn style inside latest info specifically */
.latest-news-content .event-btn {
    margin: 0;
    width: fit-content;
    font-size: 0.9rem;
    padding: 0.6rem 1.2rem;
}

.center-btn {
    text-align: center;
}

.btn-secondary {
    display: inline-block;
    padding: 0.8rem 2rem;
    background: transparent;
    color: #8dc63f;
    border: 2px solid #8dc63f;
    text-decoration: none;
    border-radius: 30px;
    font-weight: bold;
    transition: all 0.2s;
}

.btn-secondary:hover {
    background: #8dc63f;
    color: white;
}

/* ===== FOOTER ===== */
footer {
  background: #111827;
  padding: 1.6rem;
  color: #9ca3af;
  text-align: center;
  font-size: 0.9rem;
  margin-top: auto;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  /* On garde la dispo en ligne, on réduit juste les textes */
  .about {
    align-items: center; /* Center vertically */
  }

  .about-left {
    flex: 0 0 30%; /* Reduce logo space */
    margin-bottom: 0;
  }

  .about-logo {
    width: 100%;
  }

  .about-right h2 {
    font-size: 2.2rem;
  }
  
  .about-right p {
    font-size: 1.1rem;
    line-height: 1.4;
  }

  .social-section h2 {
    font-size: 2.7rem;
  }
}

@media (max-width: 600px) {
  .hero-image {
    height: 300px;
  }

  .hero-content h1 {
    font-size: 2.5rem;
    line-height: 1.1;
  }

  .hero-by {
    font-size: 1.3rem;
  }

  /* Ajustements spécifiques pour garder logo + texte côte à côte */
  .about {
      gap: 1rem;
  }
  
  .about-left {
      flex: 0 0 35%; /* Logo un peu plus grand pour qu'on le voie */
  }

  .about-right h2 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
  }

  .courses-section h2 {
    font-size: 2.4rem;
  }

  .about-right p {
    font-size: 0.85rem;
    line-height: 1.3;
    margin-bottom: 0.5rem;
  }
  
  .course-text p {
    font-size: 1rem;
  }

  nav a {
    font-size: 1.15rem;
  }

  .course-text h3 {
    font-size: 1.7rem;
  }
}
@media (max-width: 600px) {
  .next-event h2 {
    font-size: 2.4rem;
  }

  .event-details h3 {
    font-size: 1.7rem;
  }
}

.event-btn {
  display: inline-block;
  margin-top: 1.5rem;
  padding: 0.8rem 2rem;
  background: #8dc63f;
  color: white;
  text-decoration: none;
  border-radius: 30px;
  font-weight: bold;
  transition: transform 0.2s, background 0.2s;
}

.event-btn:hover {
  background: #222;
  transform: translateY(-2px);
}

/* ===== RESEAUX SOCIAUX ===== */
/* ===== RESEAUX SOCIAUX ===== */
.social-section {
  padding: 3rem 0;
  text-align: center;
  background-color: white;
  border-radius: 15px;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.07);
  margin-top: 4rem;
  margin-bottom: 4rem;
}

.social-section h2 {
  font-size: 3.7rem;
  margin-bottom: 2rem;
}

.social-links {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 4rem;
  flex-wrap: wrap;
}

.social-logo {
  width: 120px;
  height: 120px;
  object-fit: cover; /* Ensures both fill the square execution */
  border-radius: 30px; /* Unifies shape */
  transition: transform 0.3s ease, filter 0.3s ease;
  filter: drop-shadow(0 4px 6px rgba(0,0,0,0.1));
}

.social-logo:hover {
  transform: scale(1.1) rotate(5deg);
  filter: drop-shadow(0 8px 12px rgba(0,0,0,0.2));
}

@media (max-width: 600px) {
  .social-section h2 {
    font-size: 2.4rem;
  }
  
  .social-links {
    gap: 2rem;
  }
  
  .social-logo {
    width: 80px;
    height: 80px;
  }
}

/* ===== CONTACT ===== */
.contact-section {
  padding: 3rem 0;
  text-align: center;
  margin-bottom: 4rem;
}

.contact-section h2 {
  font-size: 3.7rem;
  margin-bottom: 2rem;
}

.contact-container {
  display: flex;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
}

.contact-item {
  background: white;
  padding: 2rem;
  border-radius: 15px;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.07);
  flex: 1;
  min-width: 280px;
  max-width: 350px;
  text-align: center;
  transition: transform 0.3s ease;
}

.contact-item:hover {
  transform: translateY(-5px);
}

.contact-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  display: block;
}

.contact-item h3 {
  font-size: 1.8rem;
  margin-bottom: 1rem;
  color: #2c3e50;
  font-family: "Bebas Neue", sans-serif;
}

.contact-item p, 
.contact-item a {
  font-size: 1.1rem;
  color: #555;
  text-decoration: none;
  line-height: 1.6;
}

.contact-item a {
  color: #8dc63f;
  font-weight: bold;
}

.contact-item a:hover {
  text-decoration: underline;
}

@media (max-width: 600px) {
  .contact-section h2 {
    font-size: 2.4rem;
  }
}
