/* ============================================================
   SECTIONS.CSS – Styles spécifiques à chaque section
   Bonege Conseil – Consultant en Services Bancaires
   ============================================================ */

/* ============================================================
   1. HERO
   ============================================================ */

.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  background-color: var(--color-navy-dark);
}

/* Arrière-plan */
.hero__bg {
  position: absolute;
  inset: 0;
  z-index: var(--z-below);
}

.hero__bg-gradient {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 15% 60%, rgba(201, 169, 110, 0.07) 0%, transparent 55%),
    radial-gradient(ellipse at 85% 15%, rgba(36, 54, 84, 0.8) 0%, transparent 50%),
    linear-gradient(135deg, #0D1B2A 0%, #1B2E4A 45%, #243654 100%);
}

.hero__bg-pattern {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.015) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.015) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse at center, black 30%, transparent 80%);
}

/* Ligne verticale droite décorative */
.hero__bg::after {
  content: '';
  position: absolute;
  top: 10%;
  right: 38%;
  bottom: 10%;
  width: 1px;
  background: linear-gradient(
    to bottom,
    transparent 0%,
    rgba(201, 169, 110, 0.25) 20%,
    rgba(201, 169, 110, 0.25) 80%,
    transparent 100%
  );
}

/* Ligne horizontale bas */
.hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(
    to right,
    transparent,
    rgba(201, 169, 110, 0.35) 30%,
    rgba(201, 169, 110, 0.35) 70%,
    transparent
  );
  z-index: 1;
}

/* Contenu hero */
.hero__content {
  display: grid;
  grid-template-columns: 55% 1fr;
  gap: var(--space-16);
  align-items: center;
  padding-top: calc(80px + var(--space-16));
  padding-bottom: var(--space-24);
  position: relative;
  z-index: 1;
}

@media (max-width: 1100px) {
  .hero__content {
    grid-template-columns: 60% 1fr;
    gap: var(--space-12);
  }
}

@media (max-width: 900px) {
  .hero__content {
    grid-template-columns: 1fr;
    gap: 0;                /* Le portrait gère son propre margin-bottom */
    text-align: center;
    padding-top: calc(80px + var(--space-8));
    padding-bottom: var(--space-16);
  }
}

/* Texte hero */
.hero__eyebrow {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  font-size: var(--fs-xs);
  font-weight: var(--fw-semi);
  letter-spacing: var(--ls-widest);
  text-transform: uppercase;
  color: var(--color-gold);
  margin-bottom: var(--space-6);
}

.hero__eyebrow-line {
  display: inline-block;
  width: 32px;
  height: 1px;
  background: var(--color-gold);
}

@media (max-width: 900px) {
  .hero__eyebrow { justify-content: center; }
}

.hero__title {
  font-family: var(--font-heading);
  font-size: clamp(var(--fs-4xl), 7vw, 5.5rem);
  font-weight: var(--fw-bold);
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin-bottom: var(--space-5);
  color: var(--color-white);
}

.hero__title-first {
  display: block;
  font-weight: var(--fw-light);
  font-style: italic;
  opacity: 0.85;
  font-size: 0.75em;
  color: var(--color-gold-light);
  letter-spacing: -0.01em;
}

.hero__title-last {
  display: block;
  color: var(--color-white);
}

.hero__subtitle {
  font-size: var(--fs-sm);
  font-weight: var(--fw-regular);
  letter-spacing: var(--ls-wider);
  color: rgba(255, 255, 255, 0.50);
  text-transform: uppercase;
  margin-bottom: var(--space-6);
}

.hero__pitch {
  font-size: var(--fs-md);
  color: rgba(255, 255, 255, 0.72);
  line-height: var(--lh-relaxed);
  max-width: 520px;
  margin-bottom: var(--space-10);
}

@media (max-width: 900px) {
  .hero__pitch { margin-inline: auto; }
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  margin-bottom: var(--space-6);
}

@media (max-width: 900px) {
  .hero__actions { justify-content: center; }
  .hero__trust-badges { justify-content: center; }
}

/* Scroll hint */
.hero__scroll-hint {
  position: absolute;
  bottom: var(--space-8);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  color: rgba(255, 255, 255, 0.40);
  font-size: var(--fs-xs);
  letter-spacing: var(--ls-widest);
  text-transform: uppercase;
  text-decoration: none;
  z-index: 2;
  animation: bounceDown 2s ease-in-out infinite;
  transition: color var(--transition-base);
}

.hero__scroll-hint:hover { color: var(--color-gold); }

/* ── Portrait Hero – Desktop ───────────────────────────── */
.hero__portrait {
  display: flex;
  justify-content: center;
  align-items: center;
}

.portrait-frame {
  position: relative;
  width: 340px;
  max-width: 100%;
}

.portrait-frame__inner {
  position: relative;
  width: 100%;
  padding-bottom: 125%;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid rgba(201, 169, 110, 0.30);
  box-shadow: var(--shadow-xl);
}

/* ── Portrait Hero – Mobile : avatar circulaire ─────────
   Le portrait remonte au-dessus du texte (order: -1)
   et adopte une forme circulaire avec anneau doré.
   ─────────────────────────────────────────────────────── */
@media (max-width: 900px) {
  .hero__portrait {
    display: flex;        /* Visible (était: display:none) */
    order: -1;            /* Au-dessus du texte hero */
    margin-bottom: var(--space-6);
  }

  .portrait-frame {
    width: 160px;
  }

  /* Forme circulaire */
  .portrait-frame__inner {
    padding-bottom: 100%;          /* Ratio carré → cercle parfait */
    border-radius: 50%;
    border: 3px solid rgba(201, 169, 110, 0.65);
    box-shadow:
      0 0 0 7px rgba(201, 169, 110, 0.12),  /* halo doré externe */
      var(--shadow-lg);
  }

  /* Masquer les éléments décoratifs desktop inutiles sur mobile */
  .portrait-frame__deco,
  .portrait-frame__accent {
    display: none;
  }
}

@media (max-width: 480px) {
  .portrait-frame { width: 140px; }
}

.portrait-placeholder,
.portrait-placeholder__bg {
  position: absolute;
  inset: 0;
}

.portrait-placeholder__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}

/* (portrait-placeholder__overlay supprimé – remplacé par .portrait-placeholder__badge) */

/* Coins décoratifs */
.portrait-frame__deco {
  position: absolute;
  width: 20px;
  height: 20px;
  border-color: var(--color-gold);
  border-style: solid;
  opacity: 0.60;
  z-index: 2;
}

.portrait-frame__deco--tl {
  top: -8px;
  left: -8px;
  border-width: 2px 0 0 2px;
  border-radius: 2px 0 0 0;
}

.portrait-frame__deco--br {
  bottom: -8px;
  right: -8px;
  border-width: 0 2px 2px 0;
  border-radius: 0 0 2px 0;
}

/* Accent lateral */
.portrait-frame__accent {
  position: absolute;
  right: -16px;
  top: 15%;
  bottom: 15%;
  width: 3px;
  background: linear-gradient(
    to bottom,
    transparent,
    var(--color-gold) 30%,
    var(--color-gold) 70%,
    transparent
  );
  border-radius: 2px;
  opacity: 0.5;
}

/* ============================================================
   2. ABOUT
   ============================================================ */

.about {
  background-color: var(--color-white);
}

.about__text {
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
}

.about__lead {
  font-family: var(--font-heading);
  font-size: clamp(var(--fs-lg), 2vw, var(--fs-xl));
  font-style: italic;
  color: var(--color-navy-dark);
  line-height: var(--lh-snug);
}

.about__text p {
  font-size: var(--fs-base);
  color: var(--color-text-secondary);
  line-height: var(--lh-relaxed);
}

/* ============================================================
   3. EXPERTISE
   ============================================================ */

.expertise {
  position: relative;
  background-color: var(--color-navy-dark);
  overflow: hidden;
}

.expertise__bg-image {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.expertise__bg-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.12;
}

.expertise__bg-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(13, 27, 42, 0.92) 0%,
    rgba(27, 46, 74, 0.88) 100%
  );
}

.expertise__inner {
  position: relative;
  z-index: 1;
}

/* ============================================================
   4. PARCOURS
   ============================================================ */

.parcours {
  background-color: var(--color-cream);
}

.parcours__col {
  /* Colonnes autonomes */
}

/* ============================================================
   5. CERTIFICATIONS
   ============================================================ */

.certifications {
  background: linear-gradient(
    135deg,
    #0D1B2A 0%,
    var(--color-navy-dark) 50%,
    #1B2E4A 100%
  );
  position: relative;
  overflow: hidden;
}

.certifications::before {
  content: '';
  position: absolute;
  top: -120px;
  right: -120px;
  width: 400px;
  height: 400px;
  background: radial-gradient(
    circle,
    rgba(201, 169, 110, 0.06) 0%,
    transparent 70%
  );
  border-radius: 50%;
}

.certifications::after {
  content: '';
  position: absolute;
  bottom: -80px;
  left: -80px;
  width: 300px;
  height: 300px;
  background: radial-gradient(
    circle,
    rgba(27, 46, 74, 0.8) 0%,
    transparent 70%
  );
  border-radius: 50%;
}

.certifications > .container { position: relative; z-index: 1; }

/* ============================================================
   6. CONTACT
   ============================================================ */

.contact {
  position: relative;
  background-color: var(--color-navy-dark);
  overflow: hidden;
}

.contact__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.contact__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.08;
}

.contact__bg-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(13, 27, 42, 0.96) 0%,
    rgba(27, 46, 74, 0.92) 100%
  );
}

.contact__inner {
  position: relative;
  z-index: 1;
}

/* ============================================================
   7. PORTRAIT PLACEHOLDER – Hero (fallback CSS si img échoue)
   ============================================================ */

/* Classe pour image de portrait introuvable */
.portrait-placeholder__img[src=""],
.portrait-placeholder__img:not([src]) {
  background: linear-gradient(135deg, var(--color-navy-mid), var(--color-navy));
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ── Badge "Illustration" discret (coin bas-droite du portrait) ── */
.portrait-placeholder__badge {
  position: absolute;
  bottom: var(--space-3);
  right: var(--space-3);
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: 3px var(--space-3);
  background: rgba(17, 31, 51, 0.72);
  border: 1px solid rgba(201, 169, 110, 0.35);
  border-radius: var(--radius-full);
  font-size: 0.65rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-gold);
  backdrop-filter: blur(6px);
  z-index: 2;
  pointer-events: none;
}

.portrait-placeholder__badge i { font-size: 0.6rem; }

/* ── Image illustrative – section About ─────────────────────── */
.about__visual {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-top: var(--space-4);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--color-border);
}

.about__visual img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform 0.6s var(--ease-out);
}

.about__visual:hover img {
  transform: scale(1.03);
}

.about__visual-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: var(--space-4) var(--space-5);
  background: linear-gradient(
    to top,
    rgba(17, 31, 51, 0.88) 0%,
    transparent 100%
  );
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: var(--fs-xs);
  font-weight: var(--fw-semi);
  letter-spacing: var(--ls-wider);
  text-transform: uppercase;
  color: var(--color-gold-light);
}

.about__visual-caption i { color: var(--color-gold); }

/* ── Badge mini portrait (section Contact) ───────────────────── */
.contact__quote-portrait-badge {
  position: absolute;
  bottom: -6px;
  right: -6px;
  padding: 2px var(--space-2);
  background: var(--color-navy-dark);
  border: 1px solid var(--color-gold);
  border-radius: var(--radius-full);
  font-size: 0.55rem;
  font-weight: var(--fw-semi);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-gold);
  white-space: nowrap;
}
