/* Styles complémentaires à theme.json */

:root {
  --gm-line: #818181;
  --gm-icon-arrow: url("../icons/arrow-gold.svg");
  --gm-icon-arrow-sm: url("../icons/arrow-gold-sm.svg");
  --gm-icon-arrow-white: url("../icons/arrow-white.svg");
  --gm-icon-search: url("../icons/search.svg");
}

.screen-reader-text {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/* Les sections s'enchaînent sans marge : chacune gère son propre espacement. */
.wp-site-blocks > * + *,
.gm-home > * + * {
  margin-block-start: 0;
}

.gm-label,
.gm-footer__titre {
  margin: 0;
  font-family: var(--wp--preset--font-family--sans);
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1.3;
  text-transform: uppercase;
  color: var(--wp--preset--color--accent);
}

.gm-label--lg {
  font-size: 1.125rem;
}

.gm-label a {
  color: inherit;
  text-decoration: none;
}

/* ---------- Liens fléchés (icônes de la maquette) ---------- */

.gm-arrow-link {
  display: inline-block;
  width: 28px;
  height: 15px;
  background: var(--gm-icon-arrow-sm) center / contain no-repeat;
}

.gm-button-arrow {
  display: inline-flex;
  align-items: center;
  gap: 1.75rem;
  padding: 0.9rem 1.25rem;
  border: 2px solid var(--wp--preset--color--accent);
  border-radius: 4px;
  color: var(--wp--preset--color--accent);
  font-size: 1.0625rem;
  font-weight: 700;
  text-decoration: none;
  text-transform: uppercase;
  transition: background-color 0.2s, color 0.2s;
}

.gm-button-arrow::after,
.gm-link-arrow a::after {
  content: "";
  flex: none;
  width: 22px;
  height: 15px;
  background: var(--gm-icon-arrow) center / contain no-repeat;
}

.gm-button-arrow:hover,
.gm-button-arrow:focus-visible {
  background: rgb(182 139 76 / 15%);
  color: var(--wp--preset--color--accent);
}

.gm-link-arrow {
  margin: 0;
  font-size: 0.875rem;
  text-transform: uppercase;
}

.gm-link-arrow a {
  display: inline-flex;
  align-items: center;
  gap: 1.25rem;
  text-decoration: none;
}

/* ---------- En-tête ---------- */

/* Mesures de la maquette (1280 px) : hauteur 95, logo à 22 px du haut, menu à 37, loupe à 36. */
.gm-header {
  padding-block: 22px 27px;
  padding-inline: clamp(1rem, 2.81vw, 36px);
}

.gm-header__inner {
  grid-template-columns: 1fr auto 1fr !important;
  align-items: start;
}

/* padding plutôt que margin : les règles de mise en page des blocs remettent les marges à 0. */
.gm-header__nav {
  padding-top: 6px;
  padding-inline-start: clamp(0px, 0.55vw, 7px);
}

.gm-header__end {
  padding-top: 4px;
}

.gm-header .wp-block-navigation a {
  text-decoration: none;
}

.gm-header .wp-block-navigation a:hover,
.gm-header .current-menu-item > a {
  color: var(--wp--preset--color--accent);
}

.gm-header .current-menu-item > a {
  font-weight: 700;
}

.gm-header__nav .wp-block-navigation__container {
  column-gap: 1.75rem;
}

.gm-header__secondary .wp-block-navigation__container {
  column-gap: 47px;
}

.gm-header__end {
  gap: clamp(1.5rem, 6.1vw, 78px);
}

.gm-header__brand {
  gap: 0;
}

.gm-header__tools {
  gap: 22px;
}

.gm-account {
  display: block;
  width: 22px;
  height: 22px;
  background: url("../icons/account.svg") center / contain no-repeat;
}

.gm-account:hover,
.gm-account:focus-visible {
  opacity: 0.75;
}

.gm-header__logo {
  margin: 0;
}

.gm-header__logo a,
.gm-header__logo img {
  display: block;
  height: auto;
}

.gm-header__tagline {
  margin: 0;
  font-size: 0.5625rem;
  line-height: 11px;
  font-weight: 500;
  text-align: center;
  text-transform: uppercase;
  color: var(--wp--preset--color--accent);
}

/* Bouton de recherche : icône de la maquette à la place de l'icône du bloc. */
.gm-search .wp-block-search__button {
  width: 22px;
  height: 22px;
  min-width: 22px;
  margin: 0;
  padding: 0;
  border: 0;
  background: var(--gm-icon-search) center / contain no-repeat;
}

.gm-search .wp-block-search__button svg {
  display: none;
}

.gm-search .wp-block-search__inside-wrapper {
  align-items: center;
}

.gm-search .wp-block-search__input {
  border: 1px solid var(--gm-line);
  border-radius: 4px;
  background: transparent;
  color: inherit;
}

.wp-block-navigation .is-mobile-only {
  display: none;
}

.wp-block-navigation__responsive-container.is-menu-open .is-mobile-only {
  display: flex;
}

.gm-header .wp-block-navigation__responsive-container.is-menu-open {
  background: var(--wp--preset--color--contrast);
  color: var(--wp--preset--color--base);
}

@media (max-width: 599px) {
  .gm-header__inner {
    align-items: center;
  }

  .gm-header__nav,
  .gm-header__end {
    padding-top: 0;
  }

  .gm-header__secondary {
    display: none;
  }
}

/* ---------- À la une ---------- */

.gm-une {
  position: relative;
}

/* Slider : défilement horizontal par paliers, fonctionne même sans JavaScript (glisser au doigt). */
.gm-une .wp-block-post-template {
  display: flex;
  margin: 0;
  padding: 0;
  list-style: none;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.gm-une .wp-block-post-template::-webkit-scrollbar {
  display: none;
}

.gm-une .wp-block-post-template:focus-visible {
  outline: 2px solid var(--wp--preset--color--accent);
  outline-offset: -4px;
}

.gm-une .wp-block-post-template > li {
  flex: 0 0 100%;
  margin: 0;
  scroll-snap-align: start;
}

@media (prefers-reduced-motion: reduce) {
  .gm-une .wp-block-post-template {
    scroll-behavior: auto;
  }
}

/* Tirets de navigation de la maquette : 39 × 4 px, 18 px d'écart, à 42 px du bas. */
.gm-une__dots {
  position: absolute;
  bottom: 32px;
  left: 50%;
  z-index: 2;
  display: flex;
  gap: 18px;
  transform: translateX(-50%);
  filter: drop-shadow(0 1px 2px rgb(0 0 0 / 60%)); /* lisibles même sur une photo claire */
}

.gm-une__dots button {
  position: relative;
  width: 39px;
  height: 24px;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
}

.gm-une__dots button::before,
.gm-une__dots button[aria-current="true"]::after {
  content: "";
  display: block;
  height: 4px;
  margin-block: 10px;
  border-radius: 2px;
  background: var(--wp--preset--color--muted);
}

/* Tiret actif : jauge dorée qui se remplit pendant l'affichage de la diapositive. */
.gm-une__dots button[aria-current="true"]::after {
  position: absolute;
  inset: 0;
  background: var(--wp--preset--color--accent);
  transform-origin: left;
  animation: gm-une-progress var(--gm-une-delay, 6s) linear forwards;
}

@keyframes gm-une-progress {
  from {
    transform: scaleX(0);
  }

  to {
    transform: scaleX(1);
  }
}

/* Pause : bouton, focus clavier dans le slider, ou survol (souris uniquement). */
.gm-une:has(:focus-visible) .gm-une__dots button::after {
  animation-play-state: paused;
}

@media (hover: hover) {
  .gm-une:hover .gm-une__dots button::after {
    animation-play-state: paused;
  }
}

.gm-une.is-paused .gm-une__dots button[aria-current="true"]::after {
  animation: none;
  transform: none;
}

/* Bouton pause / lecture, à droite des tirets sans décaler leur centrage. */
.gm-une__dots .gm-une__toggle {
  position: absolute;
  top: 0;
  left: calc(100% + 14px);
  width: 24px;
}

.gm-une__dots .gm-une__toggle::before,
.gm-une__dots .gm-une__toggle::after {
  content: "";
  position: absolute;
  top: 6px;
  width: 3px;
  height: 12px;
  margin: 0;
  border-radius: 1px;
  background: var(--wp--preset--color--base);
}

.gm-une__dots .gm-une__toggle::before {
  left: 7px;
}

.gm-une__dots .gm-une__toggle::after {
  left: 14px;
}

.gm-une.is-paused .gm-une__toggle::before {
  left: 8px;
  width: 0;
  height: 0;
  border-block: 6px solid transparent;
  border-inline-start: 10px solid var(--wp--preset--color--base);
  border-radius: 0;
  background: none;
}

.gm-une.is-paused .gm-une__toggle::after {
  display: none;
}

.gm-une__dots .gm-une__toggle:hover::before,
.gm-une__dots .gm-une__toggle:hover::after {
  background-color: var(--wp--preset--color--accent);
}

.gm-une.is-paused .gm-une__toggle:hover::before {
  background: none;
  border-inline-start-color: var(--wp--preset--color--accent);
}

.gm-une__dots button:focus-visible {
  outline: 2px solid var(--wp--preset--color--accent);
  outline-offset: 2px;
}

.gm-une__cover {
  padding-inline: max(var(--wp--style--root--padding-left), calc((100% - var(--wp--style--global--wide-size)) / 2));
}

.gm-une__cover img.wp-block-cover__image-background {
  object-position: 50% 15%;
}

/* Cadrage de la maquette (1280 × 688) : photo à 124,4 % de large, calée à gauche, haut à -189 px. */
@media (min-width: 782px) {
  .gm-une__cover img.wp-block-cover__image-background {
    object-position: 0% 15.3%;
    transform: scale(1.244);
    transform-origin: 0 0;
  }
}

/* Pas de voile dans la maquette (la photo est déjà sombre) : un léger dégradé sous le texte
   garde la lisibilité si le client met une photo plus claire. */
.gm-une__cover::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(90deg, rgb(15 15 15 / 35%) 0%, rgb(15 15 15 / 0%) 55%);
  pointer-events: none;
}

/* Sur mobile, le texte occupe toute la largeur : voile uniforme. */
@media (max-width: 781px) {
  .gm-une__cover::before {
    background: rgb(15 15 15 / 40%);
  }
}

.gm-une__cover .wp-block-cover__inner-container {
  padding-inline-start: clamp(0rem, 3.75vw, 3rem);
}

.gm-une__rubrique a {
  text-decoration: none;
}

.gm-une__rubrique {
  margin: 0 0 2.5rem;
  font-family: var(--wp--preset--font-family--serif);
  font-size: 1.5rem;
  text-shadow: 3px 4px 4px rgb(0 0 0 / 25%);
}

.gm-une__titre {
  max-width: 24rem;
  margin: 0;
}

.gm-une__titre a {
  color: var(--wp--preset--color--base);
  text-decoration: none;
}

.gm-une__titre::after {
  content: "";
  display: block;
  width: 65px;
  height: 3px;
  margin-top: 2.5rem;
  background: var(--wp--preset--color--accent);
}

.gm-une .gm-button-arrow {
  margin-top: 6.5rem;
}

/* ---------- Derniers articles ---------- */

.gm-derniers {
  padding-block: 2.6rem 4rem;
  border-radius: 29px 29px 0 0;
}

.gm-derniers__entete {
  margin-bottom: 4rem;
}

.gm-liste {
  margin: 0;
  padding: 0;
  list-style: none;
}

.gm-liste > li + li {
  margin-top: 2.25rem;
}

.gm-liste > li:not(:last-child) {
  padding-bottom: 2.25rem;
  border-bottom: 1px solid var(--wp--preset--color--accent);
}

.gm-liste__item {
  gap: 2rem;
}

.gm-liste__texte {
  max-width: 28.5rem;
}

.gm-liste__texte .wp-block-post-title {
  margin-block: 1.75rem 0.75rem;
}

.gm-liste__texte .wp-block-post-title a {
  text-decoration: none;
}

.gm-liste__extrait p {
  margin: 0;
}

.gm-liste__meta {
  flex: none;
  gap: 1.5rem;
}

.gm-liste__date {
  text-transform: uppercase;
}

@media (max-width: 599px) {
  .gm-liste__item {
    flex-wrap: wrap !important;
  }
}

/* ---------- Pied de page ---------- */

/* Mesures de la maquette (1280 px) : grille de 1160 px (x 58 → 1218), colonnes à 416, 584, 758 et 1000. */
.gm-footer {
  padding-block: 40px 45px;
  border-top: 1px solid var(--gm-line);
}

.gm-footer__grid.alignwide {
  display: grid;
  grid-template-columns: 358fr 168fr 174fr 242fr 218fr;
  max-width: 1164px;
  padding-inline-end: 4px; /* la maquette n'est pas centrée : 58 px à gauche, 62 px à droite */
}

.gm-footer__grid > * {
  margin-block: 0;
}

.gm-footer__logo,
.gm-footer__logo a,
.gm-footer__logo img {
  display: block;
  margin: 0;
}

.gm-socials {
  display: flex;
  gap: 19.6px;
  margin: 46px 0 0 32px;
  padding: 0;
  list-style: none;
}

.gm-socials a,
.gm-socials img {
  display: block;
  width: 27px;
  height: 27px;
}

.gm-socials a:hover,
.gm-socials a:focus-visible {
  opacity: 0.75;
}

.gm-footer__titre {
  margin-bottom: 27px;
  font-size: 0.875rem;
  color: var(--wp--preset--color--base);
}

.gm-footer__nav {
  font-size: 0.875rem;
  font-weight: 400;
  line-height: 17px;
  text-transform: none;
}

.gm-footer__nav .wp-block-navigation__container {
  gap: 14px;
}

.gm-footer__nav .wp-block-navigation-item {
  white-space: nowrap;
}

.gm-footer__nav a {
  text-decoration: none;
}

.gm-footer__accroche {
  margin: -1rem 0 1.5rem;
  font-size: 0.875rem;
  opacity: 0.75;
}

.gm-newsletter {
  display: flex;
  align-items: center;
  box-sizing: border-box;
  height: 57px;
  padding: 0 17px 0 13px;
  border: 1px solid var(--wp--preset--color--accent);
  border-radius: 4px;
}

.gm-newsletter input {
  flex: 1;
  min-width: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  font-size: 0.875rem;
  letter-spacing: inherit;
}

.gm-newsletter input::placeholder {
  color: var(--wp--preset--color--base);
  opacity: 1;
}

.gm-newsletter input:focus {
  outline: none;
}

.gm-newsletter:focus-within {
  outline: 2px solid var(--wp--preset--color--accent);
  outline-offset: 2px;
}

.gm-newsletter button {
  flex: none;
  width: 21px;
  height: 8px;
  padding: 0;
  border: 0;
  background: var(--gm-icon-arrow-white) center / contain no-repeat;
  cursor: pointer;
}

@media (max-width: 999px) {
  .gm-footer__grid.alignwide {
    grid-template-columns: repeat(3, 1fr);
    row-gap: 2.5rem;
  }

  .gm-footer__brand,
  .gm-footer__col--newsletter {
    grid-column: 1 / -1;
  }

  .gm-newsletter {
    max-width: 218px;
  }
}

@media (max-width: 599px) {
  .gm-footer__grid.alignwide {
    grid-template-columns: 1fr 1fr;
  }

  .gm-socials {
    margin-inline-start: 0;
  }
}

/* ---------- Sections éditoriales ---------- */

/* Espace blanc généreux : chaque section respire. */
.gm-section {
  padding-block: clamp(4rem, 8vw, 7.5rem);
}

.gm-section__entete {
  align-items: baseline;
  margin-bottom: 3rem;
}

.gm-kicker {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 0 0 1.5rem;
  font-family: var(--wp--preset--font-family--sans);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--wp--preset--color--accent);
}

.gm-kicker::before {
  content: "";
  flex: none;
  width: 32px;
  height: 1px;
  background: currentColor;
}

.has-text-align-center.gm-kicker {
  justify-content: center;
}

.gm-section__entete .gm-kicker {
  margin: 0;
}

.gm-chapo {
  font-size: 1.0625rem;
  line-height: 1.7;
}

.gm-chapo p {
  margin: 0;
}

/* Visuels : recadrage propre et léger zoom au survol. */
.gm-media {
  overflow: hidden;
  margin: 0;
}

.gm-media img {
  display: block;
  width: 100%;
  object-fit: cover;
  transition: transform 0.8s cubic-bezier(0.2, 0.6, 0.2, 1);
}

.gm-media a:hover img,
.gm-media a:focus-visible img {
  transform: scale(1.03);
}

@media (prefers-reduced-motion: reduce) {
  .gm-media img {
    transition: none;
  }
}

/* Grilles d'articles */
.gm-grille {
  gap: 3rem 2rem !important;
  margin: 0;
  padding: 0;
  list-style: none;
}

.gm-grille > li > * {
  margin-block: 0;
}

.gm-grille .gm-media {
  margin-bottom: 1.25rem;
}

.gm-carte__titre {
  margin-top: 0.625rem !important;
}

.gm-carte__titre a,
.gm-dossier__titre a,
.gm-gothaman .wp-block-post-title a {
  text-decoration: none;
}

.gm-carte__extrait,
.gm-carte__date {
  margin-top: 0.75rem !important;
  font-size: 0.875rem;
  color: #5b5b5b;
}

.gm-carte__extrait p {
  margin: 0;
}

@media (max-width: 999px) {
  .gm-grille {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media (max-width: 599px) {
  .gm-grille {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  /* Tendances : visuels portrait, deux par ligne comme dans un magazine. */
  .gm-tendances .gm-grille {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 2rem 1rem !important;
  }

  .gm-tendances .gm-carte__titre {
    font-size: 1rem !important;
  }
}

/* Le dossier de la semaine */
.gm-dossier .wp-block-post-template,
.gm-gothaman .wp-block-post-template {
  margin: 0;
  padding: 0;
  list-style: none;
}

.gm-dossier__cols,
.gm-gothaman__cols {
  gap: clamp(2rem, 6vw, 5rem) !important;
}

.gm-dossier__titre {
  margin-block: 0.75rem 1.5rem;
}

.gm-dossier .gm-button-arrow,
.gm-gothaman .gm-button-arrow {
  margin-top: 2.5rem;
}

/* The Gothaman */
.gm-gothaman__marque {
  margin: 0 0 0.25rem;
  font-size: var(--wp--preset--font-size--xx-large);
  line-height: 1;
}

.gm-gothaman .gm-kicker {
  margin-bottom: 2.5rem;
}

.gm-gothaman .wp-block-post-title {
  margin-bottom: 1.25rem;
}

/* ---------- Rubriques (archives) ---------- */

/* Mesures de la maquette « Page Mode » (1280 px) : fond noir, bannière de 447 px, rangées de 376 px. */
body.archive {
  background: #000;
  color: var(--wp--preset--color--base);
}

/* vw et non % : le pourcentage se calculerait sur la largeur du parent, réduite des marges latérales. */
.gm-banniere {
  padding: 86px max(var(--wp--style--root--padding-left), calc(50vw - 496px)) 2rem;
}

.gm-archive > * {
  margin-block: 0;
}

/* Même cadrage que la une de l'accueil : photo agrandie à 124,4 %, calée en haut à gauche. */
.gm-banniere img.wp-block-cover__image-background {
  object-position: 50% 20%;
}

@media (min-width: 782px) {
  .gm-banniere img.wp-block-cover__image-background {
    object-position: 0% 12.3%;
    transform: scale(1.244);
    transform-origin: 0 0;
  }
}

.gm-banniere::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(90deg, rgb(15 15 15 / 35%) 0%, rgb(15 15 15 / 0%) 55%);
  pointer-events: none;
}

.gm-banniere__titre {
  max-width: 31rem;
  margin: 0;
  font-size: var(--wp--preset--font-size--xx-large);
  color: var(--wp--preset--color--base);
}

.gm-banniere__titre::after {
  content: "";
  display: block;
  width: 65px;
  height: 3px;
  margin-top: 2.25rem;
  background: var(--wp--preset--color--accent);
}

.gm-archive__corps.alignwide {
  position: relative;
  max-width: 1174px;
  padding-block: 61px clamp(4rem, 8vw, 7.5rem);
  padding-inline-start: 7px; /* la maquette n'est pas centrée : 60 px à gauche, 53 px à droite */
}

.gm-rangees {
  margin: 0;
  padding: 0;
  list-style: none;
}

.gm-rangees > li {
  margin: 0;
  padding-bottom: 38px;
  border-bottom: 1px solid var(--gm-line);
}

.gm-rangees > li + li {
  padding-top: 50px;
}

.gm-rangee {
  gap: 34px;
}

.gm-rangee__visuel {
  flex: 0 0 376px;
  margin: 0;
}

.gm-rangee__visuel:empty {
  background: #1c1c1c;
  aspect-ratio: 376 / 536;
}

.gm-rangee__texte {
  max-width: 376px;
  padding-top: 3px;
}

.gm-rangee__texte > * {
  margin-block: 0;
}

.gm-rangee__rubrique {
  font-size: 1.125rem;
  font-weight: 700;
  text-transform: none;
}

.gm-rangee__rubrique a {
  color: var(--wp--preset--color--accent);
  text-decoration: none;
}

.gm-rangee__titre {
  margin-top: 44px !important;
  font-size: 1.4375rem;
  line-height: 1.22;
}

.gm-rangee__titre a {
  color: var(--wp--preset--color--base);
  text-decoration: none;
}

.gm-rangee__titre a:hover {
  color: var(--wp--preset--color--accent);
}

.gm-rangee__extrait {
  margin-top: 23px !important;
  line-height: 1.2;
}

.gm-rangee__extrait p {
  margin: 0;
}

.gm-lire {
  display: inline-flex;
  align-items: center;
  gap: 27px;
  margin-top: 55px !important;
  color: var(--wp--preset--color--accent);
  font-size: 1rem;
  font-weight: 700;
  text-decoration: none;
  text-transform: uppercase;
}

.gm-lire::after {
  content: "";
  width: 28px;
  height: 15px;
  background: var(--gm-icon-arrow-sm) center / contain no-repeat;
  transition: transform 0.2s;
}

.gm-lire:hover::after {
  transform: translateX(4px);
}

.gm-rangee__date {
  margin-top: 25px !important;
  font-size: 0.875rem;
  text-transform: uppercase;
}

/* Les plus lus : colonne de 286 px à droite de la première rangée, filet vertical à gauche. */
.gm-plus-lus {
  position: absolute;
  top: 44px;
  right: 0;
  width: 305px; /* filet vertical à x 922, contenu à x 941 */
  margin: 0;
  min-height: 553px;
  padding-left: 19px;
  border-left: 1px solid var(--gm-line);
}

.gm-plus-lus__titre {
  margin: 0;
  padding: 20px 0 19px;
  border-bottom: 1px solid var(--gm-line);
  font-family: var(--wp--preset--font-family--sans);
  font-size: 1.0625rem;
  font-weight: 400;
  line-height: 1.2;
}

.gm-plus-lus .gm-plus-lus__liste {
  counter-reset: plus-lus;
  margin: 37px 0 0;
  padding: 0;
  list-style: none;
}

.gm-plus-lus__liste > li {
  counter-increment: plus-lus;
  margin: 0;
}

.gm-plus-lus__liste > li + li {
  margin-top: 24px;
}

.gm-plus-lus__item {
  gap: 12px;
  margin-left: -7px; /* le numéro déborde légèrement à gauche du texte, comme dans la maquette */
}

.gm-plus-lus__item::before {
  content: counter(plus-lus, decimal-leading-zero);
  flex: 0 0 25px;
  font-size: 1rem;
  font-weight: 700;
  color: var(--wp--preset--color--accent);
}

.gm-plus-lus__visuel {
  flex: none;
  margin: 0;
}

.gm-plus-lus__visuel img {
  width: 90px;
  height: 86px;
  object-fit: cover;
}

.gm-plus-lus__article {
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.35;
}

.gm-plus-lus__article a {
  color: var(--wp--preset--color--base);
  text-decoration: none;
}

.gm-plus-lus__article a:hover {
  color: var(--wp--preset--color--accent);
}

/* La liste laisse la place à la colonne « Les plus lus ». */
@media (min-width: 1000px) {
  .gm-rangee__texte {
    flex: 0 1 376px;
  }
}

@media (max-width: 999px) {
  .gm-plus-lus {
    position: static;
    width: auto;
    min-height: 0;
    margin-top: 4rem;
    padding-left: 0;
    border-left: 0;
  }

  .gm-plus-lus__item {
    margin-left: 0;
  }
}

@media (max-width: 699px) {
  .gm-rangee {
    flex-direction: column;
    gap: 1.5rem;
  }

  .gm-rangee__visuel {
    flex-basis: auto;
    width: 100%;
  }

  .gm-rangee__titre {
    margin-top: 1rem !important;
  }

  .gm-lire {
    margin-top: 1.75rem !important;
  }
}

body.archive .gm-pagination a,
body.archive .gm-vide {
  color: var(--wp--preset--color--base);
}

/* ---------- Recherche ---------- */

.gm-archive-entete {
  padding-block: clamp(3.5rem, 7vw, 6rem) 3rem;
  text-align: center;
}

.gm-archive-entete > * {
  margin-inline: auto;
}

.gm-fil {
  margin-bottom: 1rem;
}

.gm-archive-entete__titre {
  margin-block: 0 1.25rem;
}

.gm-archive__liste {
  padding-bottom: clamp(4rem, 8vw, 7.5rem);
}

.gm-archive__corps .gm-archive__liste {
  padding-bottom: 0;
}

.gm-pagination {
  margin-top: 4rem;
  font-size: 0.875rem;
}

.gm-pagination a {
  text-decoration: none;
}

.gm-pagination .current {
  color: var(--wp--preset--color--accent);
  font-weight: 700;
}

.gm-vide {
  padding-block: 3rem;
  color: #5b5b5b;
}

.gm-search-page {
  max-width: 32rem;
  margin-top: 2rem;
}

.gm-search-page .wp-block-search__input {
  border: 0;
  border-bottom: 1px solid var(--wp--preset--color--contrast);
  padding-inline: 0;
  font: inherit;
}

/* ---------- Article ---------- */

/* Mesures de la maquette « Page Lire l'article » (1280 px) : fond noir, contenu de x 60 à 1227. */
body.single-post {
  background: #000;
  color: var(--wp--preset--color--base);
}

.gm-article > * {
  margin-block: 0;
}

.gm-article > .alignwide {
  max-width: 1174px;
  padding-inline-start: 7px; /* 60 px à gauche, 53 px à droite, comme les rubriques */
}

.gm-article__entete {
  padding: 89px 0 125px;
  border-bottom: 1px solid var(--gm-line);
}

.gm-article__entete > * {
  margin: 0 0 0 57px;
}

.gm-article__rubrique {
  font-size: 1.125rem;
  font-weight: 700;
  line-height: 1.2;
}

.gm-article__rubrique a {
  color: var(--wp--preset--color--accent);
  text-decoration: none;
}

.gm-article__titre {
  max-width: 741px;
  margin-top: 45px !important;
  font-size: var(--wp--preset--font-size--xx-large);
  line-height: 1.125;
  color: var(--wp--preset--color--base);
}

.gm-article__titre::after {
  content: "";
  display: block;
  width: 65px;
  height: 3px;
  margin-top: 16px;
  background: var(--wp--preset--color--accent);
}

.gm-article__barre {
  gap: 1rem 2rem;
  padding-top: 43px;
}

.gm-partage {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 23px;
  padding-inline-start: 12px;
}

.gm-partage__titre {
  line-height: 1.2;
  font-size: 0.875rem;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--wp--preset--color--accent);
}

.gm-partage .gm-partage__liste {
  margin: 0;
}

.gm-partage__natif {
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
}

.gm-partage__natif:hover,
.gm-partage__natif:focus-visible {
  opacity: 0.75;
}

.gm-partage__statut {
  font-size: 0.8125rem;
  color: var(--wp--preset--color--accent);
}

.gm-article__meta {
  gap: 0;
  font-size: 0.8125rem;
  text-transform: uppercase;
  color: #9a9a9a;
}

.gm-article__meta > * {
  margin: 0;
}

.gm-article__meta > * + *::before {
  content: "·";
  margin-inline: 0.75rem;
}

.gm-article__contenu {
  display: flow-root;
  padding-block: 37px 68px; /* photo à y 636 : 44 px sous les icônes (la barre fait 34 px avec la date) */
}

/* Photo de l'article à gauche, le texte s'enroule autour. */
.gm-article__visuel {
  float: left;
  width: 395px;
  margin: 0 75px 1.25rem 0;
}

.gm-credit {
  margin-top: 0.75rem;
  font-size: 0.75rem;
  color: #9a9a9a;
}

/* display: block — le bloc Contenu est en flow-root par défaut, ce qui empêcherait le texte
   de reprendre toute la largeur sous la photo. */
.gm-article__corps {
  display: block;
  font-size: 1.25rem;
  line-height: 1.45;
}

.gm-article__corps > * {
  margin-block: 0;
}

.gm-article__corps > * + * {
  margin-top: 0.9em;
}

/* Lettrine sur le premier paragraphe. */
.gm-article__corps > p:first-child::first-letter {
  float: left;
  margin: 0.04em 18px 0 0;
  font-family: var(--wp--preset--font-family--serif);
  font-size: 6.0625rem;
  line-height: 0.8;
}

.gm-article__corps h2,
.gm-article__corps h3 {
  margin-top: 2em;
  color: var(--wp--preset--color--base);
}

.gm-article__corps a {
  color: var(--wp--preset--color--accent);
}

/* Images dans le texte, à gauche ou à droite (alignement choisi dans l'éditeur). */
/* clear : une image du texte ne démarre qu'après la photo principale, sinon le texte serait coincé entre les deux. */
.gm-article__corps .alignright {
  clear: both;
  float: right;
  width: min(519px, 45%);
  margin: 0.4em 49px 1.25rem 31px;
}

.gm-article__corps .alignleft {
  clear: both;
  float: left;
  width: min(519px, 45%);
  margin: 0.4em 31px 1.25rem 0;
}

.gm-article__corps figcaption {
  margin-top: 0.75rem;
  font-size: 0.75rem;
  color: #9a9a9a;
}

.gm-article__corps .wp-block-pullquote,
.gm-article__corps .wp-block-quote {
  clear: both;
  padding-block: 2rem;
  border-block: 1px solid var(--wp--preset--color--accent);
  border-inline: 0;
  font-family: var(--wp--preset--font-family--serif);
  font-size: var(--wp--preset--font-size--x-large);
  line-height: 1.35;
  text-align: center;
}

.gm-article__corps cite {
  display: block;
  margin-top: 1rem;
  font-family: var(--wp--preset--font-family--sans);
  font-size: 0.8125rem;
  font-style: normal;
  text-transform: uppercase;
  color: var(--wp--preset--color--accent);
}

/* « À lire aussi » sur fond noir, sous un filet. */
.single-post .gm-a-lire {
  border-top: 1px solid var(--gm-line);
  background: #000 !important;
}

.single-post .gm-a-lire .wp-block-post-title a {
  color: var(--wp--preset--color--base);
}

@media (max-width: 781px) {
  .gm-article__entete {
    padding-block: 3rem 3.5rem;
  }

  .gm-article__entete > *,
  .gm-partage {
    margin-left: 0;
    padding-inline-start: 0;
  }

  .gm-article__titre {
    margin-top: 1.5rem !important;
  }

  .gm-article__visuel,
  .gm-article__corps .alignright,
  .gm-article__corps .alignleft {
    float: none;
    width: auto;
    margin: 0 0 1.5rem;
  }

  .gm-article__corps {
    font-size: 1.125rem;
  }
}

/* ---------- Pages simples et formulaire de connexion ---------- */

.gm-page {
  padding-block: clamp(3.5rem, 7vw, 6rem) clamp(4rem, 8vw, 7.5rem);
}

.gm-page > * {
  margin-block: 0;
}

.gm-page__titre {
  margin-bottom: 2.5rem !important;
}

/* Formulaire de connexion (bloc « Connexion/Déconnexion ») : libellés au-dessus, champs alignés pleine largeur. */
/* Calé sur le bord gauche de la colonne de contenu, comme le titre de la page (et non centré). */
.wp-block-loginout {
  max-width: 420px;
  margin-inline: max(0px, (100% - var(--wp--style--global--content-size)) / 2) auto !important;
}

.wp-block-loginout form > p {
  margin: 0 0 1.5rem;
}

.wp-block-loginout label {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.8125rem;
  font-weight: 600;
  text-transform: uppercase;
}

.wp-block-loginout input.input {
  box-sizing: border-box;
  display: block;
  width: 100%;
  height: 50px;
  padding: 0 1rem;
  border: 1px solid #c9c9c9;
  border-radius: 4px;
  background: var(--wp--preset--color--base);
  color: var(--wp--preset--color--contrast);
  font: inherit;
  letter-spacing: inherit;
}

.wp-block-loginout input.input:focus {
  border-color: var(--wp--preset--color--accent);
  outline: 2px solid var(--wp--preset--color--accent);
  outline-offset: 1px;
}

.wp-block-loginout .login-remember label {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  margin: 0;
  font-weight: 400;
  text-transform: none;
  cursor: pointer;
}

.wp-block-loginout .login-remember input {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--wp--preset--color--accent);
}

.wp-block-loginout .login-submit {
  margin-bottom: 0;
}

.wp-block-loginout input[type="submit"] {
  width: 100%;
  cursor: pointer;
}

.wp-block-loginout.logged-in a {
  color: var(--wp--preset--color--accent);
}

/* ---------- Rejoignez le cercle ---------- */

.gm-cercle__accroche {
  margin-block: 0 2.5rem;
  font-family: var(--wp--preset--font-family--serif);
}

.gm-newsletter--large {
  max-width: 26rem;
  margin-inline: auto;
}

/* ---------- Compositions vitrine (sections génériques) ---------- */

.is-section {
  padding-block: var(--wp--preset--spacing--60);
  padding-inline: var(--wp--preset--spacing--30);
}

.is-section + .is-section:not(.has-background) {
  padding-block-start: 0;
}

.is-hero {
  min-height: 60vh;
}

.is-card {
  padding: var(--wp--preset--spacing--40);
  background: var(--wp--preset--color--base);
  border-radius: 6px;
}

.is-faq .wp-block-details {
  padding-block: var(--wp--preset--spacing--30);
  border-bottom: 1px solid color-mix(in srgb, currentColor 15%, transparent);
}

.is-faq .wp-block-details summary {
  font-weight: 700;
  cursor: pointer;
}
