/* Mycologie de la Broye — style principal */

/* Reset */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; }
img, picture, svg, video { max-width: 100%; display: block; height: auto; }
button, input, textarea, select { font: inherit; color: inherit; }
a { color: inherit; font-weight: 600;}

/* Design tokens (extraits du site Wix d'origine) */
:root {
  --color-orange: #ef982e;
  --color-orange-hover: #d88526;
  --color-salmon: #ff9166;
  --color-brown: #40241a;
  --color-dark: #002833;
  --color-white: #ffffff;
  --color-off-white: #fafafa;
  --color-grey-100: #f5f5f5;
  --color-grey-200: #e8e6e6;
  --color-grey-400: #999997;
  --color-grey-700: #4a4a4a;

  --font-heading: 'Poppins', 'Helvetica Neue', Arial, sans-serif;
  --font-body: 'Poppins', 'Helvetica Neue', Arial, sans-serif;

  --max-width: 1200px;
  --nav-height: 76px;
  --radius: 4px;
  --shadow-soft: 0 6px 20px rgba(0, 40, 51, .08);
}

/* Base typography */
body {
  font-family: var(--font-body);
  color: var(--color-dark);
  background: var(--color-white);
  line-height: 1.55;
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 600;
  color: var(--color-dark);
  margin: 0 0 .6em;
  line-height: 1.2;
}
p { margin: 0 0 1em; }
p:last-child{ margin-bottom: 0 !important;}
a:hover { text-decoration: underline; }

/* Layout */
.container {
  width: min(100% - 2.5rem, var(--max-width));
  margin-inline: auto;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid rgba(0, 40, 51, .06);
}
.site-header .inner {
  display: flex;
  align-items: center;
  gap: 2rem;
  min-height: var(--nav-height);
  padding: .75rem 0;
}
.brand {
  display: flex;
  align-items: center;
  gap: .8rem;
  flex-shrink: 0;
  text-decoration: none;
}
.brand:hover { text-decoration: none; }
.brand img {
  width: 42px;
  height: auto;
}
.brand-name {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1rem;
  color: var(--color-brown);
  letter-spacing: .04em;
}

.main-nav {
  flex: 1;
}
.main-nav ul {
  display: flex;
  gap: 2rem;
  list-style: none;
  padding: 0;
  margin: 0;
  flex-wrap: wrap;
}
.main-nav a {
  font-weight: 500;
  font-size: .82rem;
  letter-spacing: .06em;
  color: var(--color-dark);
  padding: .5rem 0;
  text-decoration: none;
  transition: color .2s ease;
}
.main-nav a:hover,
.main-nav a.active {
  color: var(--color-orange);
  text-decoration: none;
}

.btn {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  justify-content: center;
  gap: .5rem;
  padding: .75rem 1.5rem;
  border-radius: var(--radius);
  font-family: var(--font-heading);
  font-weight: 500;
  font-size: .9rem;
  letter-spacing: .03em;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all .2s ease;
  text-align: center;
}
.btn-primary {
  background: var(--color-orange);
  color: var(--color-white);
}
.btn-primary:hover {
  background: var(--color-orange-hover);
  text-decoration: none;
  color: var(--color-white);
}
.btn-outline {
  background: transparent;
  color: var(--color-orange);
  border-color: var(--color-orange);
}
.btn-outline:hover {
  background: var(--color-orange);
  color: var(--color-white);
  text-decoration: none;
}
.btn-light {
  background: transparent;
  color: var(--color-white);
  border-color: var(--color-white);
}
.btn-light:hover {
  background: var(--color-white);
  color: var(--color-dark);
  text-decoration: none;
}

.btn-dark {
  background: transparent;
  color: var(--color-brown);
  border-color: var(--color-brown);
}
.btn-dark:hover {
  background: var(--color-brown);
  color: var(--color-white);
  text-decoration: none;
}

/* Menu burger (mobile) */
.nav-toggle {
  display: none;
  background: none;
  border: 0;
  padding: .5rem;
  cursor: pointer;
  margin-left: auto;
}
.nav-toggle span {
  display: block;
  width: 26px;
  height: 2px;
  background: var(--color-dark);
  margin: 6px 0;
  transition: transform .2s, opacity .2s;
}

/* Hero */
.hero {
  position: relative;
  min-height: 620px;
  display: flex;
  align-items: center;
  color: var(--color-white);
  overflow: hidden;
  background: var(--color-dark);
}
.hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}
.hero .container {
  position: relative;
  z-index: 2;
  padding: 4rem 0;
}
/* Décalage du bloc texte, comme sur le site d'origine */
.hero-content {
  padding-left: clamp(0rem, 11vw, 9rem);
}
.hero-eyebrow {
  font-weight: 300;
  font-size: clamp(1rem, 1.6vw, 1.35rem);
  opacity: .92;
  margin-bottom: .4rem;
  letter-spacing: .01em;
}
.hero-title {
  font-size: clamp(2.4rem, 5.2vw, 4.2rem);
  color: var(--color-white);
  line-height: 1.06;
  margin-bottom: 1.6rem;
  font-weight: 600;
  letter-spacing: .01em;
}

/* Flèche de défilement */
.hero-scroll {
  display: inline-block;
  color: var(--color-white);
  margin-bottom: 2.2rem;
  transition: transform .3s ease, opacity .3s ease;
}
.hero-scroll svg {
  width: clamp(34px, 3.4vw, 46px);
  height: auto;
  display: block;
}
.hero-scroll:hover {
  transform: translateY(6px);
  opacity: .85;
  text-decoration: none;
}
@media (prefers-reduced-motion: reduce) {
  .hero-scroll { transition: none; }
  .hero-scroll:hover { transform: none; }
}

.hero-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1.1rem;
}
.hero-flyer {
  color: var(--color-white);
  font-size: .92rem;
  text-decoration: underline;
  text-underline-offset: 4px;
  opacity: .92;
  transition: opacity .2s ease;
}
.hero-flyer:hover { opacity: 1; }

/* Sections */
.section {
  padding: 3rem 0;
}

.section-home-cta {
  text-align: center;
  border-top: 1px solid var(--color-grey-700);
  max-width: 780px;
    margin: 0 auto;
}
.section-title {
  color: var(--color-orange);
  /* Gabarit du site d'origine : poppins-semibold 35px, graisse 700 */
  font-size: clamp(1.75rem, 2.9vw, 2.1875rem);
  font-weight: 700;
  text-align: center;
  letter-spacing: normal;
  line-height: 1.3;
  margin-bottom: 2.5rem;
}
.section-lead {
  max-width: 780px;
  margin: 0 auto 3rem;
  text-align: center;
  color: var(--color-grey-700);
  font-size: 1.05rem;
  line-height: 1.75;
}
.section-lead p { margin-bottom: 1em; text-wrap:balance; text-align: left; line-height: 1.4em;}

.section-lead a {
  margin: auto;
}

/* Event / Poster block */
.events {
  background: var(--color-off-white);
}
.event-card {
  max-width: 520px;
  margin: 0 auto;
  background: var(--color-white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}
.event-card img {
  width: 100%;
  height: auto;
  display: block;
}
.section-cta {
  text-align: center;
  margin-top: 2.5rem;
}

/* CTA banner (rejoindre la société) */
.cta-banner {
  background: var(--color-orange);
  color: var(--color-white);
  text-align: center;
  padding: 4rem 1rem;
}
.cta-banner h2 {
  color: var(--color-white);
  font-size: clamp(1.6rem, 3.6vw, 2.2rem);
  font-weight: 700;
  letter-spacing: normal;
  margin-bottom: 2rem;
}

/* Comité grid */
.comite-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 3rem 2rem;
  max-width: 900px;
  margin: 0 auto;
}
.comite-card {
  text-align: left;
}
.comite-role {
  color: var(--color-orange);
  font-size: .78rem;
  letter-spacing: .1em;
  font-weight: 600;
  text-transform: uppercase;
  margin-bottom: .6rem;
  padding-bottom: .6rem;
  border-bottom: 1px solid var(--color-grey-200);
}
.comite-card h3 {
  font-size: 1.1rem;
  margin-bottom: .3rem;
  color: var(--color-dark);
  font-weight: 600;
}
.comite-email {
  font-size: .9rem;
  color: var(--color-grey-700);
  word-break: break-word;
}
.comite-email a {
  color: var(--color-grey-700);
  font-weight: 300;
  text-decoration: none;
}
.comite-email a:hover { color: var(--color-orange); text-decoration: none; }

/* Programme */
.programme-wrap {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
  max-width: 900px;
  margin: 0 auto 2rem;
}
.programme-wrap img {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
}

/* Cercles d'études background section */
.cercles-hero {
  min-height: 380px;
  background-size: cover;
  background-position: center;
  background-color: var(--color-dark);
}

/* Photos - galerie d'albums */
.albums-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2.5rem 2rem;
}
.album-card {
  display: block;
  color: inherit;
  transition: transform .25s ease;
  background: transparent;
  position: relative;
  text-decoration: none;
  padding-bottom: 1.2rem;
}
.album-card:hover { transform: translateY(-4px); text-decoration: none; }

.album-card .title {
  background: var(--color-orange);
  color: var(--color-white);
  padding: .75rem 1.1rem;
  font-weight: 600;
  font-size: .95rem;
  letter-spacing: .04em;
  width: 88%;
  box-sizing: border-box;
  margin: 0;
  position: relative;
  z-index: 2;
}

/* L'année chevauche le haut de l'image, juste sous le bandeau titre */
.album-card .year {
  background: var(--color-white);
  color: var(--color-grey-700);
    font-size: .85rem;
    padding: .25rem .75rem;
  display: inline-block;
  margin: 0 0 0 .6rem;
  width: fit-content;
  position: relative;
  z-index: 2;
      translate: 0 -8px;
  font-weight: 600;
}

.album-card .cover {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--color-grey-200);
  margin-top: -40px;
}
.album-card .cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .5s ease;
}
.album-card:hover .cover img { transform: scale(1.05); }

/* Album detail — masonry-style */
.album-header {
  text-align: center;
  padding: 3rem 0 1.5rem;
}
.album-header h1 {
  color: var(--color-orange);
  font-size: 2rem;
  letter-spacing: .04em;
  margin-bottom: .3rem;
}
.album-header .year {
  color: var(--color-grey-700);
  font-size: 1.1rem;
}
.back-link {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  color: var(--color-orange);
  margin-bottom: 1.5rem;
  font-weight: 500;
  font-size: .9rem;
}
.back-link:hover { text-decoration: underline; }

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
  padding-bottom: 4rem;
}
.gallery a {
  display: block;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--color-grey-200);
  cursor: zoom-in;
}
.gallery img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}
.gallery a:hover img {
  transform: scale(1.06);
}

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 3rem;
  align-items: start;
}
/* Gabarit de l'ancien site : titre hors cadre, carte blanche à bordure fine */
.contact-info {
  background: transparent;
  padding: 0;
}
.contact-info h2 {
  color: var(--color-dark);
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1.2rem;
}
.contact-card {
  background: var(--color-white);
  border: 1px solid var(--color-grey-200);
  padding: 2.2rem 2.4rem;
}
.contact-info p {
  font-size: 1rem;
  margin: 0 0 .35rem;
  line-height: 1.4em;
  color: var(--color-grey-700);
}
.contact-info strong {
  color: var(--color-dark);
  font-weight: 600;
}
.contact-info a {
  color: var(--color-orange);
  font-weight: 500;
}
.contact-block { margin-bottom: 1.5rem; }
.contact-block:last-child { margin-bottom: 0; }

/* Form */
.form h2 {
  color: var(--color-dark);
  font-size: 1.15rem;
  margin-bottom: 1.4rem;
}
.form .row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}
.form label {
  display: block;
  font-size: .82rem;
  color: var(--color-grey-700);
  margin-bottom: .3rem;
  font-weight: 500;
}
.form input,
.form textarea {
  width: 100%;
  padding: .75rem 1rem;
  border: 1px solid var(--color-grey-200);
  border-radius: var(--radius);
  background: var(--color-white);
  font-size: .95rem;
  transition: border-color .2s ease;
}
.form input:focus,
.form textarea:focus {
  outline: none;
  border-color: var(--color-orange);
}
.form textarea {
  min-height: 140px;
  resize: vertical;
}
.form .single { margin-bottom: 1rem; }
.form-status {
  margin-top: 1rem;
  padding: .75rem 1rem;
  border-radius: var(--radius);
  font-size: .9rem;
  display: none;
}
.form-status.success {
  display: block;
  background: #e6f4ea;
  color: #1b6e2c;
  border: 1px solid #a8dcb4;
}
.form-status.error {
  display: block;
  background: #fdecea;
  color: #a51818;
  border: 1px solid #f4b3ab;
}

/* Footer */
.site-footer {
  background: var(--color-dark);
  color: var(--color-white);
  padding: 3.5rem 0 2rem;
  font-size: .9rem;
  line-height: 1.7;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, .15);
}
.footer-grid h4 {
  color: var(--color-orange);
  font-size: .85rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}
.footer-grid a {
  color: var(--color-white);
  transition: color .2s;
}
.footer-grid a:hover { color: var(--color-orange); text-decoration: none; }
.footer-grid ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.footer-grid ul li { margin-bottom: .3rem; }
.footer-bottom {
  padding-top: 1.5rem;
  text-align: center;
  color: rgba(255, 255, 255, .6);
  font-size: .82rem;
}

/* Responsive */
@media (max-width: 900px) {
  .site-header .inner { gap: 1rem; }
  .nav-toggle { display: block; }
  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-white);
    border-bottom: 1px solid var(--color-grey-200);
    display: none;
    padding: 1rem 1.5rem;
  }
  .main-nav.open { display: block; }
  .main-nav ul {
    flex-direction: column;
    gap: 1rem;
    align-items: flex-start;
  }
  .header-cta { display: none; }
  .main-nav.open + .header-cta,
  .site-header .inner .header-cta-mobile { display: inline-flex; }

  .contact-grid { grid-template-columns: 1fr; }
  .form .row { grid-template-columns: 1fr; }

  .footer-grid { grid-template-columns: 1fr; gap: 2rem; }
  .section { padding: 3.5rem 0; }
  .hero { min-height: 480px; }
  /* Sur mobile, le texte du hero s'aligne sur le reste du contenu */
  .hero-content { padding-left: 0; }
}

@media (max-width: 480px) {
  .hero-actions { flex-direction: column; align-items: stretch; }
  .hero-actions .btn { width: 100%; }
  .comite-grid { grid-template-columns: 1fr; gap: 2rem; }
  .brand-name { display: none; }
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0, 0, 0, .92);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}
.lightbox.open { display: flex; }
.lightbox .lb-img {
  max-width: 100%;
  max-height: 85vh;
  object-fit: contain;
  box-shadow: 0 8px 40px rgba(0, 0, 0, .5);
}
.lightbox .lb-close,
.lightbox .lb-prev,
.lightbox .lb-next {
  position: absolute;
  background: rgba(255, 255, 255, .1);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, .3);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  font-size: 1.4rem;
  cursor: pointer;
  transition: background .2s;
  display: flex;
  align-items: center;
  justify-content: center;
}
.lightbox button:hover { background: rgba(255, 255, 255, .2); }
.lightbox .lb-close { top: 1.2rem; right: 1.2rem; }
.lightbox .lb-prev { left: 1.2rem; top: 50%; transform: translateY(-50%); }
.lightbox .lb-next { right: 1.2rem; top: 50%; transform: translateY(-50%); }
.lightbox .lb-caption {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255, 255, 255, .8);
  font-size: .9rem;
  background: rgba(0, 0, 0, .4);
  padding: .35rem .8rem;
  border-radius: 20px;
}
@media (max-width: 640px) {
  .lightbox .lb-prev { left: .5rem; width: 42px; height: 42px; }
  .lightbox .lb-next { right: .5rem; width: 42px; height: 42px; }
}

/* Images de contenu ouvrables en lightbox */
.zoomable {
  cursor: zoom-in;
  transition: opacity .25s ease;
}
.zoomable:hover { opacity: .9; }
.zoomable:focus-visible {
  outline: 3px solid var(--color-orange);
  outline-offset: 3px;
}

/* Champignon du bandeau CTA (dessin du site d'origine) */
.cta-mushroom {
  width: clamp(80px, 9vw, 110px);
  height: auto;
  margin: 0 auto 1.1rem;
  display: block;
}

/* Bloc adresse cliquable vers Google Maps */
.contact-maps-link {
  display: block;
  color: inherit;
  text-decoration: none;
  border-radius: var(--radius);
  transition: background .2s ease;
}
.contact-maps-link:hover {
  text-decoration: none;
  background: rgba(239, 152, 46, .07);
}
.contact-maps-link:hover .maps-hint { text-decoration: underline; }
.maps-hint {
  display: inline-block;
  margin-top: .45rem;
  color: var(--color-orange);
  font-size: .85rem;
  font-weight: 500;
}
