/*
Theme Name: LQ Child
Theme URI: https://lesquietudes-lautrec.fr
Description: Child theme GeneratePress du magazine « Le Cout du Grand Age ».
Author: La Redaction
Template: generatepress
Version: 1.0
*/

/* Polices self-hebergees, cf lq-fonts.css (charge separement). */

/* ==========================================================================
   Le Cout du Grand Age - feuille de style
   Direction : dossier de presse imprime. Papier creme, encre chaude,
   serif editoriale, chiffres traites comme des infographies.
   ========================================================================== */


:root {
  /* papier / encre */
  --paper:      #f7f4ed;
  --paper-2:    #efe9dc;
  --paper-3:    #e6decd;
  --ink:        #1a1815;
  --ink-2:      #4a443c;
  --ink-3:      #7d756a;
  --rule:       #d5cbb8;

  /* accents */
  --brick:      #a8432a;   /* CTA, chiffres cles */
  --brick-dark: #8a3320;
  --slate:      #23303f;   /* confiance, aplats */
  --slate-2:    #35485e;

  /* typo */
  --serif: 'Newsreader', Charter, Georgia, 'Times New Roman', serif;
  --didot: 'Bodoni Moda', 'Didot', 'Playfair Display', Georgia, serif;
  --mono:  'IBM Plex Mono', 'SFMono-Regular', Consolas, monospace;

  --measure: 34rem;        /* largeur de lecture */
  --shell:   76rem;
}

/* ------------------------------------------------------------------ reset */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 19px;           /* public senior : corps genereux */
  line-height: 1.65;
  font-optical-sizing: auto;
  /* grain papier */
  background-image:
    radial-gradient(circle at 15% 12%, rgba(168,67,42,.045), transparent 45%),
    radial-gradient(circle at 85% 8%,  rgba(35,48,63,.04),  transparent 40%);
  background-attachment: fixed;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--brick); text-underline-offset: .18em; text-decoration-thickness: .06em; }
a:hover { color: var(--brick-dark); }

/* --------------------------------------------------------------- primitifs */
.lq-shell { width: min(100% - 2.5rem, var(--shell)); margin-inline: auto; }
.lq-kicker {
  font-family: var(--mono);
  font-size: .68rem;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--brick);
}
.lq-kicker--slate { color: var(--slate-2); }
.lq-rule { height: 1px; background: var(--rule); border: 0; margin: 0; }

h1, h2, h3, h4 { font-weight: 600; line-height: 1.12; letter-spacing: -.015em; margin: 0; }
h1 { font-size: clamp(2.4rem, 5.2vw, 4.1rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
h3 { font-size: 1.3rem; }

/* ----------------------------------------------------------------- entete */
.lq-masthead { border-bottom: 2px solid var(--ink); background: var(--paper); }
.lq-masthead__bar {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 1.5rem; padding: 1.1rem 0 .9rem; flex-wrap: wrap;
}
.lq-wordmark { text-decoration: none; color: var(--ink); display: block; }
.lq-wordmark__name {
  font-family: var(--didot);
  font-weight: 900;
  font-size: 1.55rem;
  letter-spacing: -.02em;
  line-height: 1;
}
.lq-wordmark__name em { font-style: normal; color: var(--brick); }
.lq-wordmark__tag {
  font-family: var(--mono); font-size: .62rem; letter-spacing: .13em;
  text-transform: uppercase; color: var(--ink-3); margin-top: .3rem;
}
.lq-nav { display: flex; gap: 1.6rem; flex-wrap: wrap; }
.lq-nav a {
  font-family: var(--mono); font-size: .72rem; letter-spacing: .09em;
  text-transform: uppercase; color: var(--ink-2); text-decoration: none;
  padding-bottom: .2rem; border-bottom: 2px solid transparent;
}
.lq-nav a:hover, .lq-nav a[aria-current] { color: var(--ink); border-bottom-color: var(--brick); }

/* ------------------------------------------------------------------- hero */
.lq-hero { padding: 3.6rem 0 2.8rem; border-bottom: 1px solid var(--rule); }
.lq-hero__grid { display: grid; grid-template-columns: 1.35fr .85fr; gap: 3.2rem; align-items: start; }
.lq-hero h1 { margin: .9rem 0 0; }
.lq-hero h1 .lq-accent { color: var(--brick); font-style: italic; }
.lq-hero__lede {
  font-size: 1.18rem; color: var(--ink-2); max-width: var(--measure);
  margin: 1.4rem 0 0;
}
.lq-hero__meta {
  font-family: var(--mono); font-size: .7rem; letter-spacing: .08em;
  color: var(--ink-3); text-transform: uppercase; margin-top: 1.8rem;
}

/* bloc chiffre : la signature graphique du site */
.lq-figure-block {
  border: 1px solid var(--ink); background: var(--paper-2);
  padding: 1.6rem 1.5rem 1.4rem; position: relative;
}
.lq-figure-block::after {           /* ombre portee dure, effet impression */
  content: ''; position: absolute; inset: 8px -8px -8px 8px;
  border: 1px solid var(--ink); z-index: -1;
}
.lq-figure-block + .lq-figure-block { margin-top: 2rem; }
.lq-figure-block__n {
  font-family: var(--didot); font-weight: 900;
  font-size: clamp(2.6rem, 6vw, 3.6rem); line-height: .95;
  color: var(--brick); letter-spacing: -.03em;
  font-variant-numeric: lining-nums tabular-nums;
}
.lq-figure-block__n sup { font-size: .42em; vertical-align: super; }
.lq-figure-block__u { font-size: .95rem; color: var(--ink-2); margin-top: .45rem; }
.lq-figure-block__src {
  font-family: var(--mono); font-size: .6rem; letter-spacing: .06em;
  color: var(--ink-3); margin-top: .9rem; text-transform: uppercase;
}

/* ----------------------------------------------------------------- grille */
.lq-section { padding: 3.2rem 0; }
.lq-section__head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 1rem; border-bottom: 2px solid var(--ink); padding-bottom: .6rem;
  margin-bottom: 2rem; flex-wrap: wrap;
}
.lq-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; }
.lq-card {
  padding: 0 1.6rem; border-left: 1px solid var(--rule);
  text-decoration: none; color: inherit; display: block;
  transition: background .25s ease;
}
.lq-card:first-child { border-left: 0; padding-left: 0; }
.lq-card:last-child { padding-right: 0; }
.lq-card:hover { background: var(--paper-2); }
.lq-card h3 { margin: .55rem 0 .5rem; font-size: 1.22rem; }
.lq-card:hover h3 { color: var(--brick); }
.lq-card p { margin: 0; color: var(--ink-2); font-size: .97rem; line-height: 1.55; }
.lq-card__read {
  font-family: var(--mono); font-size: .63rem; letter-spacing: .1em;
  text-transform: uppercase; color: var(--ink-3); margin-top: .9rem;
}

/* ---------------------------------------------------------------- article */
.lq-article { display: grid; grid-template-columns: minmax(0,1fr) 19rem; gap: 3.4rem; padding: 2.8rem 0 4rem; }
/* min-width:0 est indispensable : un enfant de grid vaut min-width:auto par
   defaut, donc il s'elargit au contenu et overflow-x sur .lq-tbl-wrap ne contient
   rien. C'est la cause classique du debordement horizontal en mobile. */
.lq-article__body { max-width: var(--measure); min-width: 0; }
.lq-article__body > * + * { margin-top: 1.25rem; }
.lq-article__body h2 { margin-top: 2.6rem; padding-top: .9rem; border-top: 1px solid var(--rule); }
.lq-article__body p { margin-bottom: 0; }
.lq-article__body strong { font-weight: 600; }
.lq-lede { font-size: 1.16rem; color: var(--ink-2); }
.lq-lede::first-letter {
  font-family: var(--didot); font-weight: 900; float: left;
  font-size: 3.6em; line-height: .78; padding: .06em .09em 0 0; color: var(--brick);
}
.lq-article__body ul { padding-left: 1.1rem; }
.lq-article__body li { margin-bottom: .5rem; }
.lq-article__body li::marker { color: var(--brick); }

.lq-dataline {
  display: grid; grid-template-columns: auto 1fr auto; gap: .8rem;
  align-items: baseline; padding: .55rem 0; border-bottom: 1px dotted var(--rule);
  font-size: .98rem;
}
.lq-dataline__v {
  font-family: var(--didot); font-weight: 700; color: var(--brick);
  font-variant-numeric: tabular-nums;
}

blockquote {
  margin: 2rem 0; padding-left: 1.3rem; border-left: 3px solid var(--brick);
  font-size: 1.15rem; font-style: italic; color: var(--ink-2);
}

/* tableaux : traites comme un tableau de presse, pas comme une grille web */
.lq-tbl-wrap { overflow-x: auto; margin: 1.8rem 0; max-width: 100%; -webkit-overflow-scrolling: touch; }
.lq-tbl { width: 100%; border-collapse: collapse; font-size: .95rem; }
.lq-tbl caption {
  text-align: left; font-family: var(--mono); font-size: .64rem;
  letter-spacing: .12em; text-transform: uppercase; color: var(--brick);
  padding-bottom: .6rem;
}
.lq-tbl th {
  text-align: left; font-weight: 600; font-size: .78rem; letter-spacing: .04em;
  text-transform: uppercase; color: var(--ink-2); padding: .5rem .7rem .5rem 0;
  border-bottom: 2px solid var(--ink); white-space: nowrap;
}
.lq-tbl td { padding: .6rem .7rem .6rem 0; border-bottom: 1px solid var(--rule); vertical-align: top; }
.lq-tbl td:last-child, .lq-tbl th:last-child { text-align: right; padding-right: 0; }
.lq-tbl .lq-num {
  font-family: var(--didot); font-weight: 700; font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.lq-tbl .lq-tot td { border-bottom: 0; border-top: 2px solid var(--ink); font-weight: 600; }
.lq-tbl .lq-tot .lq-num { color: var(--brick); font-size: 1.15rem; }
.lq-tbl .lq-neg .lq-num { color: var(--slate-2); }

/* encadre « ce que personne ne dit » */
.lq-caveat {
  border: 1px solid var(--brick); background: #fbf0ec; padding: 1.2rem 1.3rem;
  margin: 2rem 0;
}
.lq-caveat h3 { font-size: 1.1rem; margin: .4rem 0 .5rem; color: var(--brick-dark); }
.lq-caveat p { margin: 0; font-size: .97rem; color: var(--ink-2); }
.lq-caveat p + p { margin-top: .7rem; }

/* FAQ */
.lq-faq { margin-top: 1rem; }
.lq-faq details {
  border-bottom: 1px solid var(--rule); padding: .85rem 0;
}
.lq-faq summary {
  cursor: pointer; font-weight: 600; font-size: 1.02rem; list-style: none;
  display: flex; justify-content: space-between; gap: 1rem; align-items: baseline;
}
.lq-faq summary::-webkit-details-marker { display: none; }
.lq-faq summary::after { content: '+'; font-family: var(--didot); color: var(--brick); font-size: 1.3rem; }
.lq-faq details[open] summary::after { content: '\2013'; }
.lq-faq details p { margin: .7rem 0 0; color: var(--ink-2); font-size: .97rem; }

/* ------------------------------------------------- BANNIERES DE CONVERSION */
/* A. encart inline : traite comme un encadre editorial, pas comme une pub  */
.lq-cta-inline {
  margin: 2.6rem 0; border: 1px solid var(--ink); background: var(--slate);
  color: var(--paper); padding: 1.7rem 1.6rem; position: relative;
}
.lq-cta-inline .lq-kicker { color: #e8b4a2; }
.lq-cta-inline h3 {
  font-family: var(--didot); font-weight: 700; font-size: 1.5rem;
  margin: .5rem 0 .6rem; color: var(--paper); line-height: 1.15;
}
.lq-cta-inline p { margin: 0 0 1.1rem; color: #cfd6de; font-size: .98rem; }
.lq-cta-inline__row { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }

/* B. encart lateral sticky */
.lq-rail { position: sticky; top: 1.5rem; align-self: start; }
.lq-cta-rail {
  border: 1px solid var(--ink); background: var(--paper-2); padding: 1.4rem 1.3rem;
}
.lq-cta-rail__n {
  font-family: var(--didot); font-weight: 900; font-size: 2.5rem;
  color: var(--brick); line-height: 1; letter-spacing: -.03em;
  font-variant-numeric: lining-nums;
}
.lq-cta-rail h3 { font-size: 1.12rem; margin: .7rem 0 .5rem; }
.lq-cta-rail p { font-size: .9rem; color: var(--ink-2); margin: 0 0 1.1rem; }
.lq-rail__note {
  font-family: var(--mono); font-size: .58rem; line-height: 1.5;
  color: var(--ink-3); margin-top: .9rem; letter-spacing: .03em;
}

/* C. bandeau pleine largeur, fin d'article */
.lq-cta-band { background: var(--slate); color: var(--paper); margin-top: 3rem; }
.lq-cta-band__in {
  display: grid; grid-template-columns: 1fr auto; gap: 2.5rem;
  align-items: center; padding: 2.6rem 0;
}
.lq-cta-band h2 {
  font-family: var(--didot); font-weight: 700; color: var(--paper);
  font-size: clamp(1.5rem, 3vw, 2rem); max-width: 30ch;
}
.lq-cta-band p { color: #cfd6de; margin: .7rem 0 0; max-width: 46ch; font-size: .98rem; }

/* boutons */
.lq-btn {
  display: inline-block; font-family: var(--mono); font-size: .76rem;
  font-weight: 600; letter-spacing: .1em; text-transform: uppercase;
  padding: .95rem 1.6rem; text-decoration: none; border: 1px solid var(--brick);
  background: var(--brick); color: #fff; cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}
.lq-btn:hover {
  background: var(--brick-dark); color: #fff;
  transform: translate(-2px, -2px); box-shadow: 4px 4px 0 rgba(26,24,21,.85);
}
.lq-btn--ghost { background: transparent; color: var(--paper); border-color: var(--paper); }
.lq-btn--ghost:hover { background: var(--paper); color: var(--ink); box-shadow: 4px 4px 0 rgba(0,0,0,.3); }
.lq-btn--lg { padding: 1.1rem 2.2rem; font-size: .82rem; }
.lq-btn--block { display: block; width: 100%; text-align: center; }

.lq-trust {
  font-family: var(--mono); font-size: .62rem; letter-spacing: .05em;
  color: var(--ink-3); margin-top: .8rem;
}
.lq-cta-inline .lq-trust, .lq-cta-band .lq-trust { color: #93a2b3; }

/* ------------------------------------------------------------ landing page */
.lq-lp-hero { background: var(--slate); color: var(--paper); padding: 3.4rem 0 3.8rem; }
.lq-lp-hero__grid { display: grid; grid-template-columns: 1fr 26rem; gap: 3.5rem; align-items: start; }
.lq-lp-hero h1 { color: var(--paper); font-size: clamp(2.1rem, 4.4vw, 3.2rem); }
.lq-lp-hero h1 .lq-accent { color: #e8b4a2; font-style: italic; }
.lq-lp-hero__lede { color: #cfd6de; font-size: 1.12rem; margin-top: 1.2rem; max-width: 46ch; }
.lq-lp-points { list-style: none; padding: 0; margin: 2rem 0 0; }
.lq-lp-points li {
  padding: .75rem 0 .75rem 2.1rem; border-top: 1px solid rgba(247,244,237,.18);
  position: relative; color: #dfe5ec; font-size: 1rem;
}
.lq-lp-points li::before {
  content: '\2713'; position: absolute; left: 0; top: .75rem;
  color: #e8b4a2; font-size: 1rem;
}

/* formulaire */
.lq-form-card {
  background: var(--paper); color: var(--ink); border: 1px solid var(--ink);
  padding: 1.7rem 1.6rem 1.5rem; position: relative;
}
.lq-form-card::after {
  content: ''; position: absolute; inset: 9px -9px -9px 9px;
  border: 1px solid #e8b4a2; z-index: -1;
}
.lq-form-card__head { display: flex; justify-content: space-between; align-items: baseline; }
.lq-steps { display: flex; gap: .3rem; margin: 1rem 0 1.4rem; }
.lq-steps span { height: 3px; flex: 1; background: var(--paper-3); }
.lq-steps span.on { background: var(--brick); }
.lq-step { display: none; }
.lq-step.on { display: block; animation: fade .3s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.lq-field { margin-bottom: 1.1rem; }
.lq-field > label {
  display: block; font-family: var(--mono); font-size: .66rem;
  letter-spacing: .1em; text-transform: uppercase; color: var(--ink-2);
  margin-bottom: .45rem;
}
.lq-field input[type=text], .lq-field input[type=tel], .lq-field input[type=email],
.lq-field input[type=number], .lq-field select {
  width: 100%; padding: .75rem .8rem; font-family: var(--serif); font-size: 1rem;
  border: 1px solid var(--rule); background: #fff; color: var(--ink);
}
.lq-field input:focus, .lq-field select:focus {
  outline: 0; border-color: var(--brick); box-shadow: 0 0 0 3px rgba(168,67,42,.13);
}
.lq-choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(6.5rem, 1fr)); gap: .4rem; }
.lq-choice {
  position: relative; border: 1px solid var(--rule); background: #fff;
  padding: .7rem .5rem; text-align: center; cursor: pointer; font-size: .92rem;
  transition: border-color .15s ease, background .15s ease;
}
.lq-choice:hover { border-color: var(--brick); }
.lq-choice input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.lq-choice:has(input:checked) { border-color: var(--brick); background: #fbf0ec; font-weight: 600; }
.lq-choice:has(input:focus-visible) { box-shadow: 0 0 0 3px rgba(168,67,42,.18); }

.lq-form-nav { display: flex; gap: .6rem; margin-top: 1.3rem; }
.lq-btn--back {
  background: transparent; color: var(--ink-2); border-color: var(--rule); flex: 0 0 auto;
}
.lq-btn--back:hover { background: var(--paper-2); color: var(--ink); box-shadow: none; transform: none; }
.lq-legal {
  font-family: var(--mono); font-size: .58rem; line-height: 1.6; color: var(--ink-3);
  margin-top: 1.1rem; letter-spacing: .02em;
}
.lq-legal a { color: var(--ink-2); }
.lq-err { color: var(--brick); font-size: .82rem; margin-top: .4rem; display: none; }
.lq-err.on { display: block; }
.lq-done { text-align: center; padding: 1.5rem 0; }
.lq-done__tick {
  font-family: var(--didot); font-size: 3rem; color: var(--brick); line-height: 1;
}

/* mention credit obligatoire */
.lq-warn-credit {
  border: 1px solid var(--rule); background: var(--paper-2);
  padding: .9rem 1rem; font-size: .82rem; color: var(--ink-2);
  font-family: var(--mono); line-height: 1.6; letter-spacing: .01em;
}

/* --------------------------------------------------------------- pied */
.lq-foot { background: var(--ink); color: var(--paper-3); margin-top: 0; padding: 3rem 0 2rem; }
.lq-foot a { color: var(--paper-2); text-decoration: none; }
.lq-foot a:hover { color: #fff; text-decoration: underline; }
.lq-foot__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 2.5rem; }
.lq-foot h4 {
  font-family: var(--mono); font-size: .64rem; letter-spacing: .14em;
  text-transform: uppercase; color: #a79e8f; margin-bottom: .9rem; font-weight: 500;
}
.lq-foot ul { list-style: none; padding: 0; margin: 0; font-size: .92rem; }
.lq-foot li { margin-bottom: .45rem; }
.lq-foot__legal {
  border-top: 1px solid #3a352e; margin-top: 2.2rem; padding-top: 1.2rem;
  font-size: .78rem; color: #8d8578; line-height: 1.7;
}

/* ------------------------------------------------------------ responsive */
@media (max-width: 900px) {
  body { font-size: 18px; }
  .lq-hero__grid, .lq-article, .lq-lp-hero__grid, .lq-cta-band__in, .lq-foot__grid { grid-template-columns: 1fr; gap: 2.2rem; }
  .lq-cards { grid-template-columns: 1fr; }
  .lq-card { border-left: 0; border-top: 1px solid var(--rule); padding: 1.4rem 0 0; margin-top: 1.4rem; }
  .lq-card:first-child { border-top: 0; margin-top: 0; padding-top: 0; }
  .lq-rail { position: static; }          /* jamais de sticky colle sur mobile */
  .lq-figure-block::after, .lq-form-card::after { display: none; }
  .lq-masthead__bar { padding-bottom: .6rem; }
  .lq-nav { gap: 1.1rem; }
}
@media (max-width: 520px) {
  .lq-shell { width: calc(100% - 1.8rem); }
  .lq-lede::first-letter { font-size: 3em; }
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}

/* ===================================================================
   Raccords GeneratePress : l'en-tete d'article est genere par
   functions.php, il doit traverser les deux colonnes du grid.
   =================================================================== */
.lq-article__head { grid-column: 1 / -1; }
.lq-title {
  font-family: var(--serif); font-weight: 600; line-height: 1.12;
  letter-spacing: -.015em; font-size: clamp(2rem, 4.2vw, 3rem);
  margin: .7rem 0 0;
}
/* GP enveloppe le contenu : on neutralise ses marges pour garder le gabarit */
.single .inside-article { padding: 0; background: transparent; }
.single .entry-content { margin-top: 0; }
.single .lq-article__body > .entry-content > *:first-child { margin-top: 0; }
.site-content .content-area { padding: 0; }
.separate-containers .inside-article { box-shadow: none; }
/* le fil GP prev/suivant est retire en PHP ; au cas ou, on masque */
.single .post-navigation { display: none; }

@media (max-width: 900px) {
  .lq-article__head { grid-column: 1; }
}

/* lq-no-gp-meta : GP peut reinjecter ses meta selon la version */
.single .entry-meta, .single .posted-on, .single .byline { display: none; }
