
/* Founder Grotesk (fichier Light du site d’origine) — 400 / 800 sont synthétisés par le navigateur */
@font-face {
  font-family: "Founder Grotesk";
  src: url("../fonts/FoundersGrotesk-Light.otf") format("opentype");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}

/* DIN 2014 — fichier du site WordPress (Fontspring demo) */
@font-face {
  font-family: "DIN 2014";
  src: url("../fonts/DIN-2014-demo.otf") format("opentype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

/* ============================================================
   Design Tokens — Agape HLS
   ============================================================ */
:root {
  --color-bg-page:    #000000;
  --color-bg-black:   #000000;
  --color-accent:     #da4b10;
  --color-text:       #e8e8e8;
  --color-text-muted: #aaaaaa;
  --color-border:     rgba(170,170,170,0.45);
  --font-condensed:   var(--font-barlow-condensed), "Barlow Condensed", sans-serif;
  --font-founder:     "Founder Grotesk", var(--font-dm-sans), "DM Sans", system-ui, sans-serif;
  --font-body:        var(--font-dm-sans), "DM Sans", system-ui, sans-serif;
  --header-h:         72px;
  --container-max:    1200px;
  --container-pad:    clamp(16px, 3vw, 32px);
  /* Google Fonts (équivalent layout Next.js) — liées dans inc/head.php */
  --font-barlow-condensed: "Barlow Condensed", sans-serif;
  --font-dm-sans:          "DM Sans", sans-serif;

  /* ── Type scale ─────────────────────────────────────────────
     h2-section : grands titres de section (Barlow Condensed)
     card-title  : titres de cards / items (Founder Grotesk Light)
     body-large  : corps principal (panneaux, colonnes)
     body        : corps courant
     body-small  : texte secondaire, légendes
  ─────────────────────────────────────────────────────────── */
  --fs-h2-section:  52px;
  --fw-h2-section:  400;

  --fs-card-title:  20px;
  --fw-card-title:  400;

  --fs-body-large:  18px;
  --fw-body-large:  400;

  --fs-body:        17px;
  --fw-body:        400;

  --fs-body-small:  15px;
  --fw-body-small:  400;
}

/* ── Responsive type scale — surcharge des tokens par breakpoint ────────────
   Tous les composants qui utilisent var(--fs-...) scalent automatiquement.
   ─────────────────────────────────────────────────────────────────────────── */

/* Tablette / laptop compact ≤ 1024px */
@media (max-width: 1024px) {
  :root {
    --fs-h2-section:  44px;
    --fs-card-title:  18px;
    --fs-body-large:  17.5px;
    --fs-body:        17px;
    --fs-body-small:  15px;
  }
}

/* Petite tablette / grand mobile ≤ 768px */
@media (max-width: 768px) {
  :root {
    --fs-h2-section:  34px;
    --fs-card-title:  17px;
    --fs-body-large:  17px;
    --fs-body:        17px;
    --fs-body-small:  15px;
  }
}

/* Mobile ≤ 560px */
@media (max-width: 560px) {
  :root {
    --fs-h2-section:  28px;
    --fs-card-title:  16px;
    --fs-body-large:  17px;
    --fs-body:        17px;
    --fs-body-small:  15px;
  }
}

/* ============================================================
   Base
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

/* Décalage scroll pour header fixe — s'applique à tous les targets d'ancre */
section[id] {
  scroll-margin-top: var(--header-h);
}

/* Conteneur centré commun aux sections structurantes du site */
.site-inner,
.site-header__inner,
.services-tabs-container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding-inline: var(--container-pad);
}

body {
  margin: 0;
  background-color: var(--color-bg-page);
  color: var(--color-text);
  font-family: var(--font-body);
}

/* ============================================================
   Header
   ============================================================ */
.site-header {
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  height: var(--header-h);
  z-index: 100;
  background-color: var(--color-bg-black);
}

/* Inner wrapper centré — même largeur que le reste du site */
.site-header__inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-header__logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}

.site-header__logo-img {
  display: block;
  width: 38px;
  height: auto;
}

.site-header__logo-name {
  font-family: var(--font-condensed);
  font-size: 0.9375rem;
  font-weight: 400;
  letter-spacing: 0.14em;
  color: #ffffff;
}

.site-header__nav {
  display: flex;
  align-items: center;
  gap: clamp(6px, 0.9vw, 18px);
}

.site-header__link {
  font-family: var(--font-condensed);
  font-size: 1.125rem; /* 18px */
  font-weight: 400;
  letter-spacing: 0.06em;
  color: var(--color-text);
  text-decoration: none;
  padding: 10px 10px;
  transition: color 0.2s;
}

.site-header__link:hover { color: #fff; }

.site-header__link--active {
  color: rgba(232, 232, 232, 0.55);
  text-decoration: underline;
  text-underline-offset: 5px;
  text-decoration-color: #ffffff;
  text-decoration-thickness: 1px;
}

.site-header__cta {
  font-family: var(--font-condensed);
  font-size: 1.125rem; /* 18px — aligné avec les liens nav */
  font-weight: 400;
  letter-spacing: 1px;
  color: #ffffff;
  text-decoration: none;
  padding: 6px 12px;
  border: 1px solid rgba(255,255,255,0.6);
  transition: background 0.2s, border-color 0.2s;
}

.site-header__cta:hover {
  background: rgba(255,255,255,0.08);
  border-color: #fff;
}

.site-header__cta:focus-visible,
.hero-cta:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
}

/* Burger mobile */
.site-header__burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.site-header__burger span {
  display: block;
  width: 22px;
  height: 2px;
  background: #fff;
  border-radius: 1px;
  transition: transform 0.25s, opacity 0.25s;
}

.site-header__mobile-nav {
  display: none;
  position: fixed;
  inset: var(--header-h) 0 0;
  background: var(--color-bg-black);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
  z-index: 99;
}

.site-header__mobile-nav.open { display: flex; }

@media (max-width: 1024px) {
  .site-header__nav  { display: none; }
  .site-header__burger { display: flex; }
}

/* ============================================================
   Hero
   ============================================================ */
.hero-section {
  background-color: var(--color-bg-page);
  padding: calc(var(--header-h) + 24px) 0 clamp(28px, 4vw, 52px);
}

.hero-shell {
  min-height: calc(85vh - var(--header-h));
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Cadre rectangulaire — reproduit le bloc du site de référence */
.hero-frame {
  position: relative;
  width: 100%;
  max-width: 1100px;
  height: min(68vh, 640px);
  min-height: 420px;
  border-radius: 3px;
  overflow: hidden;
  background-color: #060d12;
}

/* Fond image avec parallaxe fixed */
.hero-frame-bg {
  position: absolute;
  inset: 0;
  background-color: #060d12;
  background-image: url("../images/AgapeGlobalAdvancedSystem_edited.webp");
  background-repeat: no-repeat;
  background-position: center center;
  background-size: cover;
  background-attachment: fixed;
}

/* Overlay radial (vignette) par-dessus l'image */
.hero-frame-scrim {
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse at center,
    rgba(17,17,17,0.50) 0%,
    rgba(17,17,17,0.82) 55%,
    rgba(17,17,17,0.95) 100%
  );
}

/* Contenu centré dans le cadre */
.hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  opacity: 0;
  animation: heroFadeIn 1.5s cubic-bezier(0.22,1,0.36,1) forwards;
}

.hero-content-inner {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: max-content;
  max-width: calc(100% - 48px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

@keyframes heroFadeIn { to { opacity: 1; } }

/* Logo : taille forcée via style inline sur <Image> (Next.js 16 = width/height = ratio seulement) */
.hero-logo { display: block; }

.hero-line {
  width: 60px;
  height: 1px;
  background: var(--color-accent);
  margin: 20px auto 24px;
  transform: scaleX(0);
  transform-origin: center;
  animation: lineExpand 1.2s cubic-bezier(0.22,1,0.36,1) 0.5s forwards;
}

@keyframes lineExpand { to { transform: scaleX(1); } }

.hero-tagline {
  font-family: var(--font-condensed);
  font-size: clamp(1.55rem, 2vw + 0.7rem, 2.25rem);
  font-weight: 400;
  color: var(--color-text);
  letter-spacing: 0.12em;
  text-transform: capitalize;
  text-align: center;
  margin: 0 0 52px;
  white-space: nowrap;
  max-width: none;
}

.hero-cta {
  font-family: var(--font-condensed);
  font-size: clamp(0.95rem, 1vw + 0.5rem, 1.375rem);
  font-weight: 400;
  letter-spacing: 1px;
  color: var(--color-text);
  padding: 12px 28px;
  border: 1px solid var(--color-border);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.2s, color 0.2s;
}

.hero-cta:hover { border-color: rgba(232,232,232,0.65); color: #fff; }

/* Tablette — désactiver fixed (iOS / overflow bug) */
@media (max-width: 1024px) {
  .hero-section { padding-top: calc(var(--header-h) + 20px); }
  .hero-shell { min-height: calc(75vh - var(--header-h)); }
  .hero-frame { max-width: 860px; height: min(60vh, 560px); }
  .hero-content-inner {
    width: min(calc(100% - 40px), 640px);
  }
  .hero-tagline {
    font-size: 1.8rem;
    margin-bottom: 32px;
    white-space: normal;
    max-width: 20ch;
    text-wrap: balance;
  }
  .hero-frame-bg { background-attachment: scroll; }
}

/* Mobile */
@media (max-width: 768px) {
  .hero-section {
    padding-top: calc(var(--header-h) + 16px);
    padding-bottom: 24px;
  }
  .hero-shell { min-height: calc(72vh - var(--header-h)); }
  .hero-frame {
    height: min(58vh, 480px);
    min-height: 420px;
  }
  .hero-content-inner { width: min(calc(100% - 32px), 300px); }
  .hero-tagline {
    font-size: 1.35rem;
    letter-spacing: 0.07em;
    white-space: normal;
    margin: 0 auto 24px;
    max-width: 16ch;
    line-height: 1.35;
    text-wrap: balance;
  }
  .hero-cta {
    min-width: 168px;
    margin: 0 auto;
  }
}

/* Accessibilité */
@media (prefers-reduced-motion: reduce) {
  .hero-content { animation: none; opacity: 1; }
  .hero-line { animation: none; transform: scaleX(1); }
}

/* ============================================================
   Footer
   ============================================================ */
.site-footer {
  background-color: var(--color-bg-black);
  padding: clamp(40px, 5vw, 72px) 0;
  width: 100%;
  box-sizing: border-box;
  flex-shrink: 0;
  text-align: left;
  color: #ffffff;
}

/* Conteneur = .site-inner (même axe que Contact / header) */
.site-footer__inner {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
}

.site-footer__email {
  display: block;
  width: 100%;
  font-family: var(--font-founder);
  font-size: 18px;
  font-weight: 400;
  color: #ffffff;
  text-decoration: none;
  letter-spacing: 0.02em;
  transition: opacity 0.2s;
}

.site-footer__email:hover,
.site-footer__email:focus-visible {
  opacity: 0.85;
  outline: none;
}

/*
 * Copyright + Privacy : 12px blanc réel (DM Sans 400 — Founder n’a que le 300,
 * le 400 navigateur paraît gris). Pas d’écart vertical entre les deux lignes.
 */
.site-footer__meta {
  margin: 0;
  padding: 0;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 400;
  line-height: 1;
  letter-spacing: 0;
  color: #ffffff;
  -webkit-font-smoothing: antialiased;
}

.site-footer__metaRow {
  margin: 0;
  padding: 0;
  font-size: 11px;
  line-height: 1.2;
  color: #ffffff;
}

.site-footer__metaRow + .site-footer__metaRow {
  margin-top: 0;
}

.site-footer__meta a {
  font-size: 11px;
  font-weight: 400;
  color: #ffffff;
  text-decoration: none;
  transition: opacity 0.2s;
}

.site-footer__meta a:hover,
.site-footer__meta a:focus-visible {
  opacity: 0.85;
  outline: none;
}

@media (max-width: 1024px) {
  .site-footer__email { font-size: 16.5px; }
}

@media (max-width: 768px) {
  .site-footer__email { font-size: 15.5px; }
}

@media (max-width: 560px) {
  .site-footer__email { font-size: 14.5px; }
}

/* ============================================================
   About Us
   ============================================================ */
.about-title {
  font-family: var(--font-condensed);
  font-size: var(--fs-h2-section);
  font-weight: var(--fw-h2-section);
  color: var(--color-text);
  line-height: 1.1;
  letter-spacing: 0.02em;
  margin: 0;
}

.about-text {
  font-family: var(--font-founder);
  font-size: var(--fs-body-large);
  font-weight: 300; /* Founder Grotesk Light réel */
  line-height: 1.75;
  color: var(--color-text);
  margin: 0;
  letter-spacing: 0.01em;
}

/* Stats row dans la colonne gauche */
.about-stats {
  position: relative;
  /* pas de padding-top : la ligne se centre via top: 30px (moitié des dots 60px) */
}

.about-stats-line {
  position: absolute;
  top: 30px;          /* centre vertical des dots (hauteur 60px / 2) */
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(
    90deg,
    rgba(218, 75, 16, 0.25),
    rgba(218, 75, 16, 0.25) 80%,
    transparent
  );
  z-index: 0;
}

.about-stat-label {
  font-family: var(--font-founder);
  font-size: var(--fs-body-small);
  font-weight: 300;
  color: var(--color-text);
  text-align: center;
}

/* Responsive About — stack sur tablette */
@media (max-width: 1024px) {
  .about-container-inner {
    grid-template-columns: 1fr !important;
  }
  .about-title { font-size: var(--fs-h2-section); }
  .about-text  { font-size: var(--fs-body-large); }
}

@media (max-width: 768px) {
  .about-title      { font-size: var(--fs-h2-section); }
  .about-text       { font-size: var(--fs-body-large); }
  .about-stat-label { font-size: var(--fs-body-small); }
}

/* ============================================================
   Timeline dots (partagé avec Security Division)
   ============================================================ */
.timeline-dot {
  position: relative;
  width: 60px;
  height: 60px;
  background: #000000;   /* masque la ligne horizontale sous le cercle */
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
  flex-shrink: 0;
  z-index: 1;
}

.timeline-number {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-founder);
  font-size: 13px;
  font-weight: 300;
  color: #ffffff;
  pointer-events: none;
  z-index: 2;
  letter-spacing: 0.08em;
}

.timeline-dot svg {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  transform: rotate(-90deg);
  z-index: 1;
}

/* Anneau fantôme — même rendu que la ligne horizontale */
.timeline-dot svg circle.ring-bg {
  fill: none;
  stroke: rgba(218, 75, 16, 0.25);
  stroke-width: 0.8;
}

/* Anneau animé — se dessine au scroll, même opacité que la ligne */
.timeline-dot svg circle.ring-anim {
  fill: none;
  stroke: rgba(218, 75, 16, 0.25);
  stroke-width: 0.8;
  stroke-dasharray: 175.9;
  stroke-dashoffset: 175.9;
  transition: stroke-dashoffset 1.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.timeline-dot.active svg circle.ring-anim {
  stroke-dashoffset: 0;
}

@media (max-width: 768px) {
  .timeline-dot { width: 50px; height: 50px; }
  .timeline-number { font-size: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .timeline-dot svg circle.ring-anim {
    transition: none;
    stroke-dashoffset: 0;
  }
}

/* ============================================================
   Our Services
   ============================================================ */
.services-tabs-container { position: relative; }

.services-title {
  font-family: var(--font-condensed);
  font-size: var(--fs-h2-section);
  font-weight: var(--fw-h2-section);
  color: var(--color-text);
  text-align: center;
  letter-spacing: 0.02em;
  margin: 0 0 44px;
}

/* Tab nav */
.services-tabs-nav {
  display: flex;
  flex-wrap: nowrap;
  justify-content: space-between;
  border-bottom: 1px solid rgba(232, 232, 232, 0.1);
}

.service-tab {
  flex: 1;
  min-width: 0;
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  padding: 14px 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  outline: none;
}

.service-tab:focus-visible {
  outline: 2px solid rgba(218, 75, 16, 0.75);
  outline-offset: 3px;
}

.tab-num {
  font-family: var(--font-condensed);
  font-size: 22px;
  font-weight: 700;
  color: rgba(232, 232, 232, 0.4);
  transition: color 0.3s ease;
  line-height: 1;
}

.tab-label {
  font-family: var(--font-founder);
  font-size: var(--fs-body);
  font-weight: 300;
  color: rgba(232, 232, 232, 0.55);
  letter-spacing: 0.02em;
  text-align: center;
  line-height: 1.25;
  transition: color 0.3s ease;
}

.service-tab:hover .tab-num  { color: rgba(232, 232, 232, 0.7); }
.service-tab:hover .tab-label { color: rgba(232, 232, 232, 0.75); }

.service-tab.active {
  border-bottom-color: #da4b10;
}
.service-tab.active .tab-num  { color: #da4b10; }
.service-tab.active .tab-label { color: #e8e8e8; }

/* Panels */
.services-tabs-content {
  position: relative;
  height: 450px;
  overflow: hidden;
}

.service-tab-panel {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(16px);
  transition:
    opacity 0.55s cubic-bezier(0.22, 1, 0.36, 1),
    visibility 0.55s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.service-tab-panel.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.service-panel-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
  z-index: 1;
  background: #000000;
}

/*
  cover : image pleine largeur/hauteur du panneau (comme version validée), ratio conservé.
  Tailwind preflight met img { height: auto; max-width: 100% } — on neutralise pour le fill Next/Image.
*/
.service-panel-bg img[data-nimg="fill"],
.service-panel-bg .service-panel-img {
  position: absolute;
  inset: 0;
  object-fit: cover !important;
  object-position: center center;
  max-width: none !important;
  width: 100% !important;
  height: 100% !important;
}

/* 07 Drones — cadrage validé (drone lisible haut-gauche, skyline) */
.service-panel-bg[data-service="07"] img[data-nimg="fill"],
.service-panel-bg[data-service="07"] .service-panel-img {
  object-position: 38% 28%;
}

.service-panel-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(0, 0, 0, 0.82) 0%,
    rgba(0, 0, 0, 0.52) 100%
  );
  z-index: 2;
}

.service-panel-content {
  position: relative;
  z-index: 3;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 60px 80px;
  max-width: 680px;
}

.service-panel-content h2 {
  font-family: var(--font-condensed);
  font-size: 38px;
  font-weight: var(--fw-h2-section);
  color: #e8e8e8;
  margin: 0 0 20px;
  letter-spacing: 0.02em;
  line-height: 1.25;
}

.service-divider {
  width: 50px;
  height: 1px;
  background: #da4b10;
  margin-bottom: 24px;
  flex-shrink: 0;
}

.service-panel-content p {
  font-family: var(--font-founder);
  font-size: var(--fs-body-large);
  font-weight: 300; /* Founder Grotesk Light réel */
  line-height: 1.65;
  color: var(--color-text);
  margin: 0;
  letter-spacing: 0.01em;
}

/* Scroll hint — mobile uniquement */
.scroll-hint-bar {
  display: none;
  flex-direction: column;
  align-items: flex-end;
  gap: 5px;
  padding: 0 0 12px;
  pointer-events: none;
  transition: opacity 0.5s ease;
}

.hint-track {
  position: relative;
  width: 56px;
  height: 6px;
  display: flex;
  align-items: center;
}

.hint-progress {
  position: absolute;
  inset: auto 0;
  height: 1px;
  background: rgba(232, 232, 232, 0.15);
  overflow: hidden;
}

.hint-progress::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(232, 232, 232, 0.3), transparent);
  transform-origin: left center;
  animation: hint-progress-pulse 1.8s ease-in-out infinite;
}

.hint-dot {
  position: absolute;
  top: 50%;
  left: 0;
  transform: translateY(-50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #da4b10;
  box-shadow: 0 0 8px rgba(218, 75, 16, 0.7);
  animation: hint-dot-slide 1.6s ease-in-out infinite;
  z-index: 1;
}

.hint-label {
  font-family: var(--font-founder);
  font-size: 12px;
  font-weight: 300;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: rgba(232, 232, 232, 0.55);
}

@keyframes hint-dot-slide {
  0%   { left: 0;                  opacity: 0; }
  15%  {                           opacity: 1; }
  85%  {                           opacity: 1; }
  100% { left: calc(100% - 6px);  opacity: 0; }
}

@keyframes hint-progress-pulse {
  0%   { transform: scaleX(0.15); opacity: 0.3; }
  50%  { transform: scaleX(1);    opacity: 1;   }
  100% { transform: scaleX(0.15); opacity: 0.3; }
}

/* Responsive Services */
@media (max-width: 1024px) {
  .services-tabs-nav {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    justify-content: flex-start;
    scrollbar-width: none;
  }
  .services-tabs-nav::-webkit-scrollbar { display: none; }

  .service-tab {
    flex: 0 0 auto;
    min-width: 160px;
    scroll-snap-align: start;
    padding: 16px 12px;
  }

  .scroll-hint-bar { display: flex; }

  .service-panel-content {
    padding: 40px 30px;
    max-width: 100%;
  }
}

@media (max-width: 768px) {
  .services-title { font-size: var(--fs-h2-section); margin-bottom: 32px; }

  .service-tab { min-width: 130px; padding: 12px 8px; }
  .tab-num   { font-size: 18px; }
  .tab-label { font-size: var(--fs-body-small); }

  .service-panel-content {
    padding: 30px 20px;
  }
  .service-panel-content h2 { font-size: var(--fs-h2-section); }
  .service-panel-content p  { font-size: var(--fs-body-large); }
}
