/* ===== Page groupe ALIKO (sans header / footer site) ===== */
.group-page {
  background: #030303;
  color: var(--white);
  min-height: 100vh;
}

/* Fond atmosphérique */
.group-filiales {
  position: relative;
  padding: 5.5rem 0 0;
  min-height: min(88vh, 920px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.group-filiales__bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(3, 3, 3, 0.88) 0%, rgba(3, 3, 3, 0.72) 45%, rgba(3, 3, 3, 0.94) 100%),
    radial-gradient(ellipse 70% 55% at 50% 0%, rgba(227, 6, 19, 0.18) 0%, transparent 62%),
    var(--group-home-bg) center / cover no-repeat;
}

.group-filiales__head {
  position: relative;
  z-index: 1;
  text-align: center;
}

.group-filiales__title {
  font-size: clamp(2.6rem, 7vw, 4.25rem);
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  line-height: 1.1;
  color: var(--white);
}

.group-filiales__title span {
  color: var(--red);
  letter-spacing: 0.12em;
}

.group-filiales__subtitle {
  margin-top: 1.1rem;
  max-width: 520px;
  margin-inline: auto;
  font-size: 1.02rem;
  line-height: 1.75;
  color: rgba(255, 255, 255, 0.62);
  font-weight: 400;
}

.group-filiales__chart {
  position: relative;
  z-index: 1;
  padding: 3rem 0 6rem;
  flex: 1;
  display: flex;
  align-items: center;
}

/* ===== Organigramme (cartes filiales) ===== */
.organigramme {
  max-width: 1180px;
  margin: 0 auto;
}

.organigramme__tree {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.organigramme__level--top {
  display: flex;
  justify-content: center;
  width: 100%;
}

.organigramme__level--bottom {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem 1.15rem;
  width: 100%;
  max-width: 1080px;
  align-items: start;
}

.organigramme__branch {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 0;
  width: 100%;
}

.organigramme__branch--parent {
  max-width: 280px;
}

/* Connecteurs */
.organigramme__connect {
  position: relative;
  width: min(92%, 900px);
  height: 56px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.organigramme__stem {
  width: 2px;
  height: 28px;
  background: linear-gradient(180deg, var(--red) 0%, rgba(227, 6, 19, 0.45) 100%);
  box-shadow: 0 0 12px rgba(227, 6, 19, 0.45);
}

.organigramme__hub {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--red);
  box-shadow: 0 0 16px rgba(227, 6, 19, 0.7);
  flex-shrink: 0;
}

.organigramme__bar {
  width: 100%;
  height: 2px;
  margin-top: -5px;
  background: linear-gradient(90deg, transparent 0%, var(--red) 8%, var(--red) 92%, transparent 100%);
  box-shadow: 0 0 10px rgba(227, 6, 19, 0.35);
}

.organigramme__branch-stem {
  width: 2px;
  height: 26px;
  background: linear-gradient(180deg, var(--red) 0%, rgba(227, 6, 19, 0.35) 100%);
  flex-shrink: 0;
}

/* Cartes */
.organigramme-card {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.97);
  border-radius: 14px;
  overflow: hidden;
  box-shadow:
    0 4px 24px rgba(0, 0, 0, 0.35),
    0 0 0 1px rgba(255, 255, 255, 0.08);
  border-top: 3px solid rgba(227, 6, 19, 0.35);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.35s ease, border-color 0.35s ease;
}

.organigramme-card:hover {
  transform: translateY(-6px);
  border-top-color: var(--red);
  box-shadow:
    0 14px 40px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(227, 6, 19, 0.25);
}

.organigramme-card--parent {
  border-top-width: 4px;
  border-top-color: var(--red);
}

.organigramme-card--featured {
  border-top-color: var(--red);
}

.organigramme-card__badge {
  position: absolute;
  top: 0.55rem;
  right: 0.55rem;
  z-index: 2;
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--white);
  background: var(--red);
  padding: 0.2rem 0.45rem;
  border-radius: 4px;
  line-height: 1.2;
}

.organigramme-card__logo-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 88px;
  padding: 1rem 0.85rem 0.75rem;
  background: linear-gradient(180deg, #f8f8f8 0%, #f0f0f0 100%);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.organigramme-card--parent .organigramme-card__logo-wrap {
  min-height: 100px;
  padding: 1.15rem 1rem 0.85rem;
}

.organigramme-card__logo {
  display: block;
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: 56px;
  object-fit: contain;
  object-position: center;
}

.organigramme-card--parent .organigramme-card__logo {
  max-height: 68px;
}

.organigramme-card__body {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 0.85rem 0.75rem 1rem;
  gap: 0.35rem;
}

.organigramme-card--parent .organigramme-card__body {
  padding: 0.95rem 0.85rem 1.1rem;
}

.organigramme-card__flag {
  width: 32px;
  height: 22px;
  object-fit: cover;
  border-radius: 3px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
  transition: transform 0.3s ease;
}

.organigramme-card:hover .organigramme-card__flag {
  transform: scale(1.08);
}

.organigramme-card__name {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--black);
  line-height: 1.25;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.organigramme-card--parent .organigramme-card__name {
  font-size: 0.88rem;
}

.organigramme-card__meta {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.25rem;
  font-size: 0.68rem;
  font-weight: 500;
  color: var(--gray-500);
  line-height: 1.3;
}

.organigramme-card__meta span:first-child {
  color: var(--gray-600);
}

.organigramme-card__dot {
  color: var(--red);
  font-weight: 700;
}

/* Solutions sur page groupe */
.group-solutions {
  background: var(--white);
  padding: 3.5rem 0 4rem;
}

.group-solutions .section-title {
  color: var(--black);
  font-size: clamp(1.35rem, 2.5vw, 1.65rem);
}

.group-solutions .section-title::after {
  background: var(--red);
}

.group-page .group-solutions .solutions__grid {
  margin-top: 1.75rem;
  gap: 1rem;
  max-width: 900px;
  margin-inline: auto;
}

.group-page .group-solutions .solution-card {
  padding: 1.2rem 1.25rem;
  border-top-width: 3px;
}

.group-page .group-solutions .solution-card:hover {
  transform: translateY(-4px) scale(1.01);
}

.group-page .group-solutions .solution-card__icon {
  width: 46px;
  height: 46px;
  border-radius: 10px;
  margin-bottom: 0.75rem;
}

.group-page .group-solutions .solution-card__icon img {
  width: 34px;
  height: 34px;
}

.group-page .group-solutions .solution-card__name {
  font-size: 0.98rem;
  margin-bottom: 0.45rem;
}

.group-page .group-solutions .solution-card__badge {
  font-size: 0.58rem;
  padding: 0.1rem 0.4rem;
}

.group-page .group-solutions .solution-card__desc {
  font-size: 0.8rem;
  line-height: 1.55;
  margin-bottom: 0.85rem;
}

.group-page .group-solutions .solution-card__btn {
  padding: 0.5rem 0.9rem;
  font-size: 0.78rem;
  border-radius: 6px;
}

.group-solutions .solution-card__desc {
  text-align: justify;
}

.group-footer-note {
  text-align: center;
  padding: 1.5rem;
  background: #000;
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.78rem;
}

@media (max-width: 1024px) {
  .organigramme__level--bottom {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.85rem;
    max-width: 520px;
  }

  .organigramme__connect {
    width: 68%;
  }
}

@media (max-width: 640px) {
  .group-filiales {
    padding-top: 3.5rem;
    min-height: auto;
  }

  .group-filiales__title {
    letter-spacing: 0.08em;
  }

  .group-filiales__subtitle {
    font-size: 0.92rem;
    padding-inline: 0.5rem;
  }

  /* Organigramme mobile : cartes empilées */
  .organigramme__tree {
    width: min(92vw, 340px);
    margin-inline: auto;
  }

  .organigramme__branch--parent {
    max-width: none;
  }

  .organigramme__level--top,
  .organigramme__level--bottom {
    width: 100%;
    max-width: none;
  }

  .organigramme__level--bottom {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  .organigramme__connect,
  .organigramme__branch-stem {
    display: none;
  }

  .organigramme-card__logo-wrap {
    min-height: 76px;
  }

  .organigramme-card__logo {
    max-height: 48px;
  }

  .organigramme__level--top {
    margin-bottom: 0.45rem;
  }
}
