/*
 * SAVOY.FR — Composition éditoriale : un ouvrage, non une succession de cartes.
 * 12 octobre 2026 | Ciblé sur Comprendre, Cheminer et la porte Encyclopédie.
 *
 * Objectif : laisser respirer les titres et les textes, réserver les bordures
 * aux séparations utiles, garder les parcours cliquables et lisibles.
 * Aucun changement aux contenus, au lecteur biblique ni aux illustrations.
 */

body:not([data-theme="dark"]) main:is(.faith-page,.journey-page,.ency-page) {
  --book-rule:rgba(113,101,77,.27);
}

/* Comprendre : les sujets forment un sommaire, pas un mur de boîtes. */
body:not([data-theme="dark"]) main.faith-page .faith-section .faith-texts {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  column-gap:clamp(25px,4vw,64px);
  row-gap:0;
}
body:not([data-theme="dark"]) main.faith-page .faith-section .faith-texts > a.faith-card {
  display:flex;
  flex-direction:column;
  justify-content:flex-start;
  min-height:0!important;
  margin:0!important;
  padding:20px 6px 22px 0!important;
  border:0!important;
  border-top:1px solid var(--book-rule)!important;
  border-radius:0!important;
  background:transparent!important;
  box-shadow:none!important;
  transform:none!important;
  transition:color .14s ease!important;
}
body:not([data-theme="dark"]) main.faith-page .faith-section .faith-texts > a.faith-card:hover {
  background:transparent!important;
  box-shadow:none!important;
  transform:none!important;
}
body:not([data-theme="dark"]) main.faith-page .faith-section .faith-texts > a.faith-card strong {
  line-height:1.3;
}
body:not([data-theme="dark"]) main.faith-page .faith-section .faith-texts > a.faith-card span {
  line-height:1.58;
}

/* Cheminer : ce sont six portes libres, et non les étapes 01 à 06 d'un cours. */
body:not([data-theme="dark"]) main.journey-page > section.journey-orient,
  padding:clamp(12px,2.3vw,32px) 0!important;
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
  box-shadow:none!important;
}
body:not([data-theme="dark"]) main.journey-page .journey-orient .journey-grid {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:0 clamp(28px,4vw,64px);
}
body:not([data-theme="dark"]) main.journey-page .journey-orient a.journey-card {
  display:flex!important;
  flex-direction:column;
  align-items:stretch;
  gap:10px;
  min-height:0!important;
  margin:0!important;
  padding:23px 8px 24px 0!important;
  border:0!important;
  border-top:1px solid var(--book-rule)!important;
  border-radius:0!important;
  background:transparent!important;
  box-shadow:none!important;
  transform:none!important;
  transition:color .14s ease!important;
}
body:not([data-theme="dark"]) main.journey-page .journey-orient a.journey-card:hover {
  background:transparent!important;
  box-shadow:none!important;
  transform:none!important;
}
body:not([data-theme="dark"]) main.journey-page .journey-orient .journey-card .journey-no {
  display:none!important;
}
body:not([data-theme="dark"]) main.journey-page .journey-orient a.journey-card::before,
body:not([data-theme="dark"]) main.journey-page .journey-orient a.journey-card::after {
  display:none!important;
}
body:not([data-theme="dark"]) main.journey-page .journey-orient .journey-card > div {
  min-width:0;
}
body:not([data-theme="dark"]) main.journey-page .journey-orient .journey-card strong {
  line-height:1.3;
}
body:not([data-theme="dark"]) main.journey-page .journey-orient .journey-card p {
  margin:8px 0 0;
  line-height:1.62;
}
body:not([data-theme="dark"]) main.journey-page .journey-orient .journey-card > small {
  margin-top:auto;
  padding-top:7px;
  line-height:1.5;
}

/* Encyclopédie : le panneau sage reste la page de garde, sans doubles cadres. */
body:not([data-theme="dark"]) main.ency-page .ency-section .ency-primary-grid {
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:0 clamp(23px,2.7vw,44px);
}
body:not([data-theme="dark"]) main.ency-page .ency-section .ency-primary-grid > a.ency-primary-card {
  min-height:0!important;
  padding:20px 4px 23px 0!important;
  border:0!important;
  border-top:1px solid var(--book-rule)!important;
  border-radius:0!important;
  background:transparent!important;
  box-shadow:none!important;
  transform:none!important;
  transition:color .14s ease!important;
}
body:not([data-theme="dark"]) main.ency-page .ency-section .ency-primary-grid > a.ency-primary-card:hover {
  background:transparent!important;
  box-shadow:none!important;
  transform:none!important;
}
body:not([data-theme="dark"]) main.ency-page .ency-section .ency-primary-card .ency-card-visual {
  border-color:transparent!important;
  background:transparent!important;
  box-shadow:none!important;
}
body:not([data-theme="dark"]) main.ency-page .ency-section .ency-primary-card strong {
  line-height:1.27;
}
body:not([data-theme="dark"]) main.ency-page .ency-section .ency-primary-card > span:not(.ency-view-kicker):not(.ency-card-visual) {
  line-height:1.58;
}

/* Keyboard focus remains visible even though the card outlines disappear. */
body:not([data-theme="dark"]) main:is(.faith-page,.journey-page,.ency-page)
:is(.faith-card,.journey-card,.ency-primary-card):focus-visible {
  outline:3px solid #a87937!important;
  outline-offset:4px!important;
  border-radius:2px!important;
}
@media(max-width:899px) {
  body:not([data-theme="dark"]) main.ency-page .ency-section .ency-primary-grid {
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}
@media(max-width:599px) {
  body:not([data-theme="dark"]) main.faith-page .faith-section .faith-texts,
  body:not([data-theme="dark"]) main.journey-page .journey-orient .journey-grid,
  body:not([data-theme="dark"]) main.ency-page .ency-section .ency-primary-grid {
    grid-template-columns:minmax(0,1fr);
    column-gap:0;
  }
  body:not([data-theme="dark"]) main.faith-page .faith-section .faith-texts > a.faith-card,
  body:not([data-theme="dark"]) main.journey-page .journey-orient a.journey-card,
  body:not([data-theme="dark"]) main.ency-page .ency-section .ency-primary-grid > a.ency-primary-card {
    padding:19px 0 21px!important;
  }
}
