/* ==========================================================================
   CFP Santé UI — Page d’accueil
   VERSION 1.3 — version finalisée
   Dépendances :
   - cfps-core.css
   - cfps-drupal.css
   - cfps-typography-v2.4.css
   - cfps-menu-v3.2-final.css
   - cfps-modules-v1.1.css

   Ce fichier contient uniquement les accès rapides et les styles éditoriaux
   propres à la page d’accueil.
   ========================================================================== */

.cfps-home {
  --cfps-home-primary: var(--cfps-color-primary, #00a19b);
  --cfps-home-primary-dark: var(--cfps-color-primary-dark, #007a76);
  --cfps-home-text: var(--cfps-color-text, #1f2933);
  --cfps-home-muted: var(--cfps-color-muted, #5b6770);
  --cfps-home-soft: #f4fbfa;
  --cfps-home-radius: 14px;
}

/* ==========================================================================
   1. Contenu éditorial
   ========================================================================== */

.cfps-home p {
  margin-top: 0;
  margin-bottom: 12px;
}

.cfps-home p:last-child {
  margin-bottom: 0;
}

.cfps-home ul,
.cfps-home ol {
  margin: 4px 0 16px;
  padding-left: 1.4rem;
}

.cfps-home li {
  margin: 0 0 3px;
  line-height: 1.45;
}

.cfps-home ul li::marker {
  color: var(--cfps-home-primary);
}

.cfps-home p a,
.cfps-home li a {
  color: var(--cfps-home-primary-dark);
  font-weight: 500;
  text-decoration-line: underline;
  text-decoration-color: rgba(0, 124, 118, .35);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.cfps-home blockquote {
  margin: 22px 0;
  padding: 16px 20px;
  border: 0;
  border-left: 4px solid var(--cfps-home-primary);
  border-radius: 0 10px 10px 0;
  background: var(--cfps-home-soft);
  color: var(--cfps-home-muted);
  line-height: 1.55;
}

/* ==========================================================================
   2. Accès rapides
   ========================================================================== */

.cfps-home .cfps-acces-publics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  margin: 6px 0 36px;
}

.cfps-home .cfps-acces-publics > p {
  display: contents !important;
}

.cfps-home .cfps-acces-publics a {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 150px;
  padding: 28px 62px 28px 28px;
  overflow: hidden;
  border-radius: var(--cfps-home-radius);
  background: #fff;
  color: var(--cfps-home-text) !important;
  text-decoration: none !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .05);
  transition:
    background-color .25s ease,
    box-shadow .25s ease;
}

.cfps-home .cfps-acces-publics a::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 0;
  background: linear-gradient(
    180deg,
    var(--cfps-home-primary),
    #38c6c0
  );
  transition: width .35s ease;
}

.cfps-home .cfps-acces-publics a::after {
  content: "→";
  position: absolute;
  top: 50%;
  right: 24px;
  color: var(--cfps-home-primary);
  font-size: 1.6rem;
  line-height: 1;
  transform: translateY(-50%) translateX(0);
  transition: none;
}

.cfps-home .cfps-acces-publics strong {
  position: relative;
  z-index: 2;
  display: block;
  margin-bottom: 12px;
  font-family: var(--cfps-font-display, "Outfit", sans-serif);
  font-size: 1.55rem;
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -.018em;
  transition: transform .25s ease;
}

.cfps-home .cfps-acces-publics span {
  position: relative;
  z-index: 2;
  color: var(--cfps-home-muted);
  font-size: .95rem;
  line-height: 1.45;
  transition: none;
}

.cfps-home .cfps-acces-publics a:hover,
.cfps-home .cfps-acces-publics a:focus-visible {
  transform: none;
  box-shadow:
    0 8px 22px rgba(0, 0, 0, .08),
    0 16px 32px rgba(0, 0, 0, .05);
}

.cfps-home .cfps-acces-publics a:hover::before,
.cfps-home .cfps-acces-publics a:focus-visible::before {
  width: 18px;
}

.cfps-home .cfps-acces-publics a:hover::after,
.cfps-home .cfps-acces-publics a:focus-visible::after {
  transform: translateY(-50%) translateX(5px);
}

.cfps-home .cfps-acces-publics a:focus-visible {
  outline: 3px solid rgba(0, 161, 155, .35);
  outline-offset: 3px;
}

/* ==========================================================================
   3. Responsive
   ========================================================================== */

@media (max-width: 768px) {
  .cfps-home .cfps-acces-publics {
    grid-template-columns: 1fr;
    gap: 14px;
    margin-top: 4px;
  }

  .cfps-home .cfps-acces-publics a {
    min-height: 120px;
    padding: 24px 58px 24px 24px;
  }
}

@media (max-width: 380px) {
  .cfps-home .cfps-acces-publics strong {
    font-size: 1.4rem;
  }
}

/* ==========================================================================
   4. Réduction des animations
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  .cfps-home .cfps-acces-publics a,
  .cfps-home .cfps-acces-publics strong,
  .cfps-home .cfps-acces-publics span {
    transition: none !important;
  }

  .cfps-home .cfps-acces-publics a:hover {
    transform: none !important;
  }
}

/* ==========================================================================
   Correctif v1.5 — accès rapides stables
   La carte et son texte restent immobiles ; seule la flèche se déplace.
   ========================================================================== */

html body main .cfps-home .cfps-acces-publics a,
html body main .cfps-home .cfps-acces-publics a:link,
html body main .cfps-home .cfps-acces-publics a:visited,
html body main .cfps-home .cfps-acces-publics a:hover,
html body main .cfps-home .cfps-acces-publics a:focus,
html body main .cfps-home .cfps-acces-publics a:focus-visible,
html body main .cfps-home .cfps-acces-publics a:active {
  transform: none !important;
  translate: none !important;
  border-radius: var(--cfps-home-radius, 14px) !important;
  -webkit-border-radius: var(--cfps-home-radius, 14px) !important;
  overflow: hidden !important;
}

html body main .cfps-home .cfps-acces-publics a strong,
html body main .cfps-home .cfps-acces-publics a span,
html body main .cfps-home .cfps-acces-publics a:hover strong,
html body main .cfps-home .cfps-acces-publics a:hover span,
html body main .cfps-home .cfps-acces-publics a:focus-visible strong,
html body main .cfps-home .cfps-acces-publics a:focus-visible span {
  transform: none !important;
  translate: none !important;
}

html body main .cfps-home .cfps-acces-publics a::after {
  transform: translateY(-50%) translateX(0) !important;
  transition: transform .22s ease !important;
}

html body main .cfps-home .cfps-acces-publics a:hover::after,
html body main .cfps-home .cfps-acces-publics a:focus-visible::after {
  transform: translateY(-50%) translateX(5px) !important;
}

html body main .cfps-home .cfps-acces-publics a::before {
  border-radius:
    var(--cfps-home-radius, 14px) 0 0
    var(--cfps-home-radius, 14px) !important;
}
