/* HUMAN CARE FOR WORLD — Design system */
:root {
  --green: #1a7a4c;
  --green-light: #2d9d66;
  --green-dark: #0f5c38;
  --blue: #1e5a8a;
  --blue-light: #2b7cb8;
  --blue-dark: #134066;
  --white: #ffffff;
  --off-white: #f7faf8;
  --gray-100: #f0f4f2;
  --gray-200: #e2e8e5;
  --gray-500: #6b7c75;
  --gray-600: #4a5c54;
  --gray-800: #2d3b35;
  --gray-900: #1a2420;
  --shadow: 0 4px 24px rgba(26, 122, 76, 0.08);
  --shadow-lg: 0 12px 48px rgba(26, 122, 76, 0.12);
  --radius: 12px;
  --radius-lg: 20px;
  --font: 'Segoe UI', system-ui, -apple-system, sans-serif;
  --transition: 0.25s ease;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  color: var(--gray-800);
  background: var(--white);
  line-height: 1.6;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--green);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--green-light);
}

/* Typography */
h1, h2, h3, h4 {
  color: var(--gray-900);
  line-height: 1.25;
  font-weight: 700;
}

h1 { font-size: clamp(2rem, 5vw, 3.25rem); }
h2 { font-size: clamp(1.75rem, 4vw, 2.5rem); }
h3 { font-size: clamp(1.15rem, 2.5vw, 1.4rem); }

.section-label {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--green);
  margin-bottom: 0.75rem;
}

.section-title {
  margin-bottom: 1rem;
}

.section-intro {
  font-size: 1.1rem;
  color: var(--gray-500);
  max-width: 640px;
}

/* Layout */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 5rem 0;
}

.section--alt {
  background: var(--off-white);
}

.section--dark {
  background: linear-gradient(135deg, var(--blue-dark) 0%, var(--green-dark) 100%);
  color: var(--white);
}

.section--dark h2,
.section--dark h3,
.section--dark .section-label {
  color: var(--white);
}

.section--dark .section-intro {
  color: rgba(255, 255, 255, 0.85);
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  /* Pas d'overflow:hidden ici — sinon les sous-menus nav sont coupés */
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--gray-200);
  transition: box-shadow var(--transition);
}

.header.scrolled {
  box-shadow: var(--shadow);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h, 88px);
}

.logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  height: 100%;
  max-height: var(--header-h, 88px);
  overflow: hidden;
  flex-shrink: 0;
  font-weight: 700;
  font-size: 1rem;
  color: var(--gray-900);
  text-decoration: none;
}

.logo:hover {
  color: var(--green);
}

.logo picture {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  max-height: inherit;
}

/* Logo contenu dans la bannière nav (sans débordement) */
.header .header__inner {
  max-width: 1440px;
}

.logo__img {
  width: auto;
  height: 72px;
  max-height: calc(var(--header-h, 88px) - 12px);
  max-width: min(380px, 48vw);
  object-fit: contain;
  object-position: center left;
  display: block;
}

@media (max-width: 1199px) {
  .logo__img {
    height: 64px;
    max-width: min(320px, 44vw);
  }
}

@media (max-width: 992px) {
  .logo__img {
    height: 56px;
    max-width: min(260px, calc(100vw - 100px));
  }
}

.logo__icon {
  width: 42px;
  height: 42px;
  background: linear-gradient(135deg, var(--green) 0%, var(--blue) 100%);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.logo--footer .logo__img {
  width: auto;
  height: 88px;
  max-width: min(420px, 100%);
  max-height: none;
  background: rgba(255, 255, 255, 0.95);
  padding: 0.4rem 0.6rem;
  border-radius: 8px;
}

.logo__text span {
  display: block;
  font-size: 0.65rem;
  font-weight: 500;
  color: var(--gray-500);
  letter-spacing: 0.05em;
}

.nav {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav__list {
  display: flex;
  list-style: none;
  gap: 1.75rem;
}

.nav__link {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--gray-800);
  position: relative;
}

.nav__link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--green);
  transition: width var(--transition);
}

.nav__link:hover,
.nav__link.active {
  color: var(--green);
}

.nav__link:hover::after,
.nav__link.active::after {
  width: 100%;
}

.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav__toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--gray-800);
  transition: var(--transition);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: 8px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
  font-family: inherit;
}

.btn--primary {
  background: var(--green);
  color: var(--white);
  border-color: var(--green);
}

.btn--primary:hover {
  background: var(--green-dark);
  border-color: var(--green-dark);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.btn--secondary {
  background: var(--blue);
  color: var(--white);
  border-color: var(--blue);
}

.btn--secondary:hover {
  background: var(--blue-dark);
  border-color: var(--blue-dark);
  color: var(--white);
  transform: translateY(-2px);
}

.btn--outline {
  background: transparent;
  color: var(--green);
  border-color: var(--green);
}

.btn--outline:hover {
  background: var(--green);
  color: var(--white);
}

.btn--white {
  background: var(--white);
  color: var(--green-dark);
  border-color: var(--white);
}

.btn--white:hover {
  background: var(--off-white);
  color: var(--green-dark);
  transform: translateY(-2px);
}

.btn--lg {
  padding: 1rem 2rem;
  font-size: 1rem;
}

.btn--sm {
  padding: 0.45rem 1rem;
  font-size: 0.82rem;
}

.btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

/* Hero */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 72px;
  background: linear-gradient(160deg, var(--off-white) 0%, #e8f4ed 50%, #e3eef8 100%);
  background-size: 200% 200%;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 70%;
  height: 140%;
  background: radial-gradient(ellipse, rgba(26, 122, 76, 0.06) 0%, transparent 70%);
  pointer-events: none;
}

.hero__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(26, 122, 76, 0.1);
  color: var(--green-dark);
  padding: 0.4rem 1rem;
  border-radius: 100px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
}

.hero__title {
  margin-bottom: 1.25rem;
}

.hero__title em {
  font-style: normal;
  color: var(--green);
}

.hero__text {
  font-size: 1.15rem;
  color: var(--gray-500);
  margin-bottom: 2rem;
  max-width: 520px;
}

.hero__visual {
  position: relative;
}

.hero__card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--gray-200);
}

.hero__stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 2rem;
}

.hero__stat {
  text-align: center;
  padding: 1rem;
  background: var(--off-white);
  border-radius: var(--radius);
}

.hero__stat strong {
  display: block;
  font-size: 1.75rem;
  color: var(--green);
  font-weight: 700;
}

.hero__stat span {
  font-size: 0.8rem;
  color: var(--gray-500);
}

.hero__image {
  width: 100%;
  aspect-ratio: 4/3;
  background: linear-gradient(135deg, var(--green-light) 0%, var(--blue) 100%);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 4rem;
  opacity: 0.9;
}

.hero__image--logo {
  background: var(--white);
  border: 1px solid var(--gray-200);
  box-shadow: var(--shadow-lg);
  padding: 2.5rem;
}

.hero__logo {
  width: 100%;
  max-width: 340px;
  height: auto;
  object-fit: contain;
}

.hero--compact {
  min-height: auto;
  padding: 4rem 0;
  padding-top: 4rem;
}

/* Cards grid */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

.card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 2rem;
  border: 1px solid var(--gray-200);
  transition: all var(--transition);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--green-light);
}

.card__icon {
  width: 52px;
  height: 52px;
  background: linear-gradient(135deg, rgba(26, 122, 76, 0.12) 0%, rgba(30, 90, 138, 0.12) 100%);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1.25rem;
}

/* Accueil — 7 domaines avec image */
.card--domain {
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.card--domain .card__media {
  height: 148px;
  background: var(--gray-100, #f3f4f6);
  overflow: hidden;
}

.card--domain .card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}

.card--domain:hover .card__media img {
  transform: scale(1.05);
}

.card--domain .card__body {
  padding: 0.65rem 1.35rem 1.45rem;
  position: relative;
}

/* Icône accrochée à droite, à la jonction photo / texte */
.card--domain .card__icon {
  width: 54px;
  height: 54px;
  margin: -27px 0.15rem 0.95rem auto;
  position: relative;
  z-index: 2;
  flex-shrink: 0;
  border-radius: 14px;
  box-shadow:
    0 6px 18px rgba(15, 92, 56, 0.28),
    0 0 0 3px rgba(255, 255, 255, 0.95);
}

.cards-grid--domains {
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}

.card__title {
  margin-bottom: 0.75rem;
}

.card__text {
  color: var(--gray-500);
  font-size: 0.95rem;
}

.card--project {
  overflow: hidden;
  padding: 0;
}

.card--project .card__image {
  height: 160px;
  background: linear-gradient(135deg, var(--green) 0%, var(--blue) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
}

.card--project .card__body {
  padding: 1.5rem;
}

.card--project .card__tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--green);
  background: rgba(26, 122, 76, 0.1);
  padding: 0.25rem 0.75rem;
  border-radius: 100px;
  margin-bottom: 0.75rem;
}

/* Values */
.values-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 1rem;
}

.value-item {
  text-align: center;
  padding: 1.5rem 1rem;
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--gray-200);
  transition: var(--transition);
}

.value-item:hover {
  border-color: var(--green);
  background: rgba(26, 122, 76, 0.04);
}

.value-item__icon {
  font-size: 1.75rem;
  margin-bottom: 0.5rem;
}

.value-item__name {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--gray-900);
}

/* CTA banner */
.cta-banner {
  text-align: center;
  padding: 4rem 2rem;
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, var(--green-dark) 0%, var(--blue-dark) 100%);
  color: var(--white);
}

.cta-banner h2 {
  color: var(--white);
  margin-bottom: 1rem;
}

.cta-banner p {
  font-size: 1.1rem;
  opacity: 0.9;
  margin-bottom: 2rem;
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

/* Page header */
.page-hero {
  padding: 8rem 0 4rem;
  background: linear-gradient(160deg, var(--off-white) 0%, #e8f4ed 100%);
  background-size: 200% 200%;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.page-hero h1 {
  margin-bottom: 1rem;
}

.page-hero p {
  font-size: 1.15rem;
  color: var(--gray-500);
  max-width: 600px;
  margin: 0 auto;
}

/* Two column */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.two-col__image {
  aspect-ratio: 4/3;
  background: linear-gradient(135deg, var(--green-light) 0%, var(--blue-light) 100%);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: white;
}

/* Action blocks */
.action-block {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 2rem;
  padding: 2.5rem;
  background: var(--white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--gray-200);
  margin-bottom: 1.5rem;
  transition: var(--transition);
}

.action-block:hover {
  box-shadow: var(--shadow);
}

.action-block__icon {
  width: 64px;
  height: 64px;
  background: linear-gradient(135deg, var(--green) 0%, var(--blue) 100%);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  flex-shrink: 0;
}

.action-block__list {
  list-style: none;
  margin-top: 1rem;
}

.action-block__list li {
  padding: 0.35rem 0;
  padding-left: 1.25rem;
  position: relative;
  color: var(--gray-500);
  font-size: 0.95rem;
}

.action-block__list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--green);
  font-weight: 700;
}

/* Engage cards */
.engage-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.engage-card {
  text-align: center;
  padding: 3rem 2rem;
  background: var(--white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--gray-200);
  transition: var(--transition);
}

.engage-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: var(--green);
}

.engage-card__icon {
  font-size: 3rem;
  margin-bottom: 1.25rem;
}

/* Photo en tête de carte (pleine largeur, coins arrondis par la carte) */
.engage-card {
  overflow: hidden;
}

.engage-card__img {
  margin: -3rem -2rem 1.5rem;
  height: 280px;
  overflow: hidden;
}

.engage-card__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 45%;
  display: block;
  transition: transform 0.6s ease;
}

/* Carte bénévole : cadrer le dos du t-shirt + logo entier */
.engage-card--volunteer .engage-card__img {
  height: 300px;
}

.engage-card--volunteer .engage-card__img img {
  object-position: center 35%;
}

/* Carte don : montrer casquette + t-shirts logo des bénévoles */
.engage-card--don .engage-card__img {
  height: 300px;
}

.engage-card--don .engage-card__img img {
  object-position: center 28%;
}

.engage-card:hover .engage-card__img img {
  transform: scale(1.06);
}

.engage-card h3 {
  margin-bottom: 1rem;
}

.engage-card p {
  color: var(--gray-500);
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
}

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 3rem;
}

.contact-info__item {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.contact-info__icon {
  width: 48px;
  height: 48px;
  background: rgba(26, 122, 76, 0.1);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  flex-shrink: 0;
}

.contact-form {
  background: var(--white);
  padding: 2.5rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--gray-200);
  box-shadow: var(--shadow);
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--gray-800);
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.85rem 1rem;
  border: 1px solid var(--gray-200);
  border-radius: 8px;
  font-family: inherit;
  font-size: 1rem;
  transition: border-color var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(26, 122, 76, 0.15);
}

.form-group textarea {
  min-height: 140px;
  resize: vertical;
}

/* Footer */
.footer {
  background: var(--gray-900);
  color: rgba(255, 255, 255, 0.75);
  padding: 4rem 0 2rem;
}

.footer__grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer__brand .logo {
  color: var(--white);
  margin-bottom: 1rem;
}

.footer__brand p {
  font-size: 0.9rem;
  line-height: 1.7;
}

.footer__title {
  color: var(--white);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 1.25rem;
}

.footer__links {
  list-style: none;
}

.footer__links li {
  margin-bottom: 0.6rem;
}

.footer__links a {
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.9rem;
}

.footer__links a:hover {
  color: var(--white);
}

.footer__bottom {
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.85rem;
}

/* Vision list */
.vision-list {
  list-style: none;
  margin-top: 1.5rem;
}

.vision-list li {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 0;
  font-size: 1.05rem;
}

.vision-list li::before {
  content: '';
  width: 8px;
  height: 8px;
  background: var(--green);
  border-radius: 50%;
  flex-shrink: 0;
}

/* Timeline */
.timeline-item {
  padding-left: 2rem;
  border-left: 3px solid var(--green);
  margin-bottom: 2rem;
  position: relative;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -8px;
  top: 0;
  width: 13px;
  height: 13px;
  background: var(--green);
  border-radius: 50%;
  border: 3px solid var(--white);
}

.timeline-item strong {
  color: var(--green);
  font-size: 0.9rem;
}

/* Utility */
.text-center { text-align: center; }
.mb-1 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 2rem; }
.mb-3 { margin-bottom: 3rem; }
.mt-2 { margin-top: 2rem; }

/* Responsive */
@media (max-width: 992px) {
  .hero__grid,
  .two-col,
  .contact-grid,
  .engage-grid {
    grid-template-columns: 1fr;
  }

  .footer__grid {
    grid-template-columns: 1fr 1fr;
  }

  .hero__visual {
    order: -1;
  }
}

@media (max-width: 768px) {
  .section {
    padding: 3.5rem 0;
  }

  .hero__stats {
    grid-template-columns: 1fr;
  }

  .action-block {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .action-block__icon {
    margin: 0 auto;
  }

  .footer__grid {
    grid-template-columns: 1fr;
  }

  .footer__bottom {
    flex-direction: column;
    text-align: center;
  }

  .engage-card__img,
  .engage-card--volunteer .engage-card__img,
  .engage-card--don .engage-card__img {
    height: min(52vw, 240px);
    margin-left: -1.25rem;
    margin-right: -1.25rem;
  }

  .engage-card {
    padding: 1.25rem;
  }

  .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  img {
    max-width: 100%;
    height: auto;
  }
}

@media (max-width: 480px) {
  .engage-page .page-hero--photo {
    height: min(82vw, 440px);
    min-height: 340px;
  }

  .engage-card__img,
  .engage-card--volunteer .engage-card__img,
  .engage-card--don .engage-card__img {
    height: 220px;
  }

  .btn {
    width: 100%;
    justify-content: center;
  }
}
