/* ==========================================================================
   TOUT S'EXPLIQUE
   Le socle (couleurs, boutons, en-tête, pied de page) vient de /assets/site.css.
   Ce fichier ajoute le parcours et la « feuille de magazine » : un objet
   imprimé, volontairement différent des cartes de l'interface.
   ========================================================================== */

.tse {
  width: min(100% - 40px, var(--content));
  margin: 0 auto;
}

.step {
  padding: clamp(48px, 9vh, 88px) 0 0;
  scroll-margin-top: var(--header-h);
}
.step:focus { outline: none; }

/* --- Introduction ------------------------------------------------------- */
.intro h1 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(2.8rem, 8vw, 5.4rem);
  line-height: .98;
  letter-spacing: -.045em;
}
.intro .lead { max-width: 54ch; }

.question-form {
  margin-top: 34px;
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  align-items: end;
  gap: 12px;
}
.form-actions { grid-column: 1 / -1; margin-top: 8px; }
.field { min-width: 0; }
.field label {
  display: block;
  margin-bottom: 7px;
  font-size: 13px;
  font-weight: 700;
  color: var(--ink-soft);
}
select {
  width: 100%;
  min-height: 48px;
  padding: 10px 38px 10px 16px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-small);
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23315f5d' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E") right 16px center / 12px 8px no-repeat,
    var(--paper-strong);
  color: var(--ink);
  font-size: 16px;
  text-overflow: ellipsis;
  appearance: none;
}
select:hover { border-color: var(--accent); }

/* --- Intuition ---------------------------------------------------------- */
.intuition { min-height: calc(100svh - var(--header-h)); }
.intuition h2 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(2rem, 5vw, 3.3rem);
  line-height: 1.04;
  letter-spacing: -.04em;
  text-wrap: balance;
}
.choice-row {
  margin-top: 26px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.choice-button {
  min-height: 72px;
  border-radius: var(--radius-small);
  border-color: var(--line-strong);
  background: var(--paper);
  color: var(--ink);
  font-weight: 700;
  font-size: 17px;
  text-align: left;
  display: flex;
  align-items: center;
  gap: 14px;
}
.choice-button svg { width: 22px; height: 22px; flex: none; color: var(--accent); }
.choice-button:hover:not(:disabled) { border-color: var(--accent); background: var(--accent-faint); }
.choice-button[aria-pressed="true"] {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}
.choice-button[aria-pressed="true"] svg { color: #fff; }
.choice-button:disabled { cursor: default; }
.choice-button:disabled:not([aria-pressed="true"]) { opacity: .45; }

/* --- Validation flatteuse ---------------------------------------------- */
.flattery {
  margin: 0 0 22px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 18px;
  border-radius: var(--radius-small);
  background: var(--accent-soft);
  color: var(--accent-deep);
  font-weight: 650;
}
.flattery::before {
  content: "";
  flex: none;
  width: 20px;
  height: 20px;
  margin-top: 2px;
  border-radius: 50%;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5.5 10.5l3 3 6-7' fill='none' stroke='%23fff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 20px no-repeat,
    var(--accent);
}

/* --- Feuille de magazine ------------------------------------------------ */
.sheet {
  position: relative;
  background: var(--paper-strong);
  border: 1px solid #e4ddd1;
  border-radius: 4px;
  box-shadow: 0 1px 0 #e9e3d8, 0 22px 50px -18px rgba(36, 43, 43, .22);
  padding: clamp(24px, 5vw, 56px) clamp(22px, 6vw, 64px) clamp(30px, 5vw, 56px);
  font-family: var(--serif);
  color: #202a2c;
}
.sheet + .sheet { margin-top: 28px; }

.sheet-masthead {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 4px 20px;
  padding-bottom: 12px;
  border-bottom: 3px double #202a2c;
}
.sheet-name {
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  font-weight: 700;
  letter-spacing: -.04em;
  line-height: 1;
}
.sheet-name span { color: var(--accent); }
.sheet-tagline {
  font-style: italic;
  font-size: 14px;
  color: var(--muted);
}
.sheet-meta {
  margin: 12px 0 0;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-family: var(--sans);
  font-size: 12px;
  color: var(--muted);
}
.sheet-rubric { color: var(--warm); font-weight: 700; }

.sheet h2.article-title {
  margin-top: clamp(26px, 5vw, 42px);
  font-size: clamp(2rem, 5.2vw, 3.2rem);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -.035em;
  text-wrap: balance;
}
.standfirst {
  margin: 18px 0 0;
  font-size: clamp(1.12rem, 2.3vw, 1.32rem);
  line-height: 1.5;
  font-style: italic;
  color: #3c4749;
}
.byline {
  margin: 18px 0 0;
  padding-bottom: 18px;
  border-bottom: 1px solid #e4ddd1;
  font-family: var(--sans);
  font-size: 12px;
  color: var(--muted);
}
.article-body {
  margin-top: 24px;
  font-size: 1.1rem;
  line-height: 1.72;
}
.article-body p { margin: 0 0 1.05em; hyphens: auto; }
.article-body > p:first-child::first-letter {
  float: left;
  margin: .06em .08em 0 0;
  font-size: 3.6em;
  line-height: .8;
  font-weight: 700;
  color: var(--accent-deep);
}
.article-body h3 {
  margin: 1.6em 0 .6em;
  font-size: 1.3rem;
  letter-spacing: -.02em;
}
.article-closing { font-style: italic; }
.article-closing::after {
  content: "";
  display: inline-block;
  width: .6em;
  height: .6em;
  margin-left: .35em;
  background: var(--accent);
  vertical-align: baseline;
}

/* Passages sourcés : un surlignage, et la référence à la demande. */
.fact {
  display: inline;
  cursor: pointer;
  padding: 0 .1em;
  border: 0;
  border-radius: 2px;
  background: linear-gradient(transparent 58%, var(--accent-soft) 58%);
  color: inherit;
  font: inherit;
  text-align: inherit;
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}
.fact sup {
  font-family: var(--sans);
  font-size: .62em;
  font-weight: 700;
  color: var(--accent);
  margin-left: .15em;
}
.fact:focus-visible { outline: 3px solid rgba(49, 95, 93, .35); outline-offset: 2px; }
.fact:hover { background: linear-gradient(transparent 20%, var(--accent-soft) 20%); }
.citation {
  margin: -.3em 0 1.1em;
  padding: 10px 14px;
  border-left: 3px solid var(--accent);
  background: var(--accent-faint);
  font-family: var(--sans);
  font-size: 13px;
  line-height: 1.5;
  color: var(--ink-soft);
}
.citation a { color: var(--accent-deep); }
.sheet-legend {
  margin: 26px 0 0;
  padding-top: 14px;
  border-top: 1px solid #e4ddd1;
  font-family: var(--sans);
  font-size: 12px;
  color: var(--muted);
}
.sheet-legend mark {
  background: linear-gradient(transparent 58%, var(--accent-soft) 58%);
  color: inherit;
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-underline-offset: 3px;
}

/* Rectificatif : encadré de la rédaction, en tête du second article. */
.rectification {
  margin: 22px 0 0;
  padding: 14px 18px;
  border: 1px solid #d9c9b4;
  border-left: 4px solid var(--warm);
  background: #f8f1e7;
  font-size: 1.02rem;
  line-height: 1.5;
}
.rectification strong {
  display: block;
  margin-bottom: 2px;
  font-family: var(--sans);
  font-size: 12px;
  color: var(--warm);
}

.step-actions {
  margin-top: 26px;
  display: flex;
  justify-content: flex-end;
}

/* --- Démontage ---------------------------------------------------------- */
.reveal > h2 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(2rem, 5vw, 3.2rem);
  line-height: 1.04;
  letter-spacing: -.04em;
  text-wrap: balance;
}
.lesson {
  margin-top: 54px;
  padding-top: 30px;
  border-top: 1px solid var(--line);
}
.lesson-number {
  display: inline-grid;
  place-items: center;
  width: 30px;
  height: 30px;
  margin-bottom: 14px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 14px;
  font-weight: 750;
}
.lesson h3 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(1.5rem, 3.4vw, 2.1rem);
  line-height: 1.1;
}
.lesson > p,
.lesson-text { margin: 14px 0 0; color: var(--ink-soft); line-height: 1.65; }

.debunk-grid {
  margin-top: 26px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.debunk {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(251, 248, 242, .84);
  padding: 22px 22px 24px;
}
.debunk-side {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
  color: var(--accent);
}
.debunk h4 {
  margin: 6px 0 0;
  font-family: var(--serif);
  font-style: italic;
  font-weight: 500;
  font-size: 1.12rem;
  line-height: 1.3;
}
.debunk dl { margin: 18px 0 0; }
.debunk dt {
  margin-top: 14px;
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
}
.debunk dd { margin: 3px 0 0; font-size: 15px; line-height: 1.58; }
.debunk dd.fallacy-name { font-weight: 700; color: var(--accent-deep); }
.source-jump { color: var(--accent-deep); font-weight: 650; text-decoration: none; }
.source-jump:hover { text-decoration: underline; }

.conclusion {
  margin-top: 22px;
  padding: 22px 24px;
  border-radius: var(--radius);
  background: var(--accent-faint);
  border: 1px solid var(--accent-soft);
}
.conclusion h4 { margin: 0; font-size: 15px; color: var(--accent-deep); }
.conclusion p { margin: 8px 0 0; line-height: 1.62; }
.dilemma {
  margin: 22px 0 0;
  font-family: var(--serif);
  font-size: clamp(1.2rem, 2.4vw, 1.45rem);
  line-height: 1.4;
  font-style: italic;
}

.effort-pair {
  margin-top: 24px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.effort {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px 22px;
  background: rgba(251, 248, 242, .84);
}
.effort.heavy { background: var(--warm-soft); border-color: #e0d3c1; }
.effort-label { margin: 0; font-size: 13px; font-weight: 700; color: var(--muted); }
.effort-count {
  display: block;
  margin-top: 4px;
  font-family: var(--serif);
  font-size: clamp(2.2rem, 6vw, 3.2rem);
  line-height: 1;
  letter-spacing: -.04em;
  font-variant-numeric: tabular-nums;
}
.effort-count small { font-size: .4em; letter-spacing: 0; color: var(--muted); }
.effort p.claim { margin: 12px 0 0; font-family: var(--serif); font-style: italic; }
.effort p.note { margin: 12px 0 0; font-size: 14px; color: var(--ink-soft); }

.sources { margin-top: 20px; }
.sources details {
  border-top: 1px solid var(--line);
  padding: 14px 0;
  scroll-margin-top: calc(var(--header-h) + 16px);
}
.sources details:last-child { border-bottom: 1px solid var(--line); }
.sources summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-weight: 700;
  color: var(--ink);
}
.sources summary::-webkit-details-marker { display: none; }
.sources summary::after { content: "+"; color: var(--muted); font-weight: 500; }
.sources details[open] summary::after { content: "−"; }
.source-id { color: var(--accent); margin-right: 6px; }
.source-body { margin-top: 10px; font-size: 14px; line-height: 1.6; color: var(--ink-soft); }
.source-body p { margin: 8px 0 0; }
.source-body a { color: var(--accent-deep); }
.source-body .access { color: var(--muted); font-size: 13px; }

.end-actions {
  margin-top: 54px;
  padding-top: 30px;
  border-top: 1px solid var(--line);
}
.end-actions h3 { font-family: var(--serif); font-weight: 500; font-size: 1.6rem; }
.share-status { min-height: 1.5em; }
.share-fallback { margin-top: 14px; }
.share-fallback label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 6px; }
.share-fallback textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-small);
  background: var(--paper-strong);
  font: inherit;
  font-size: 14px;
}

/* --- Petits écrans ------------------------------------------------------ */
@media (max-width: 760px) {
  .tse { width: min(100% - 28px, var(--content)); }
  .question-form { grid-template-columns: 1fr; }
  .question-form .primary-button { width: 100%; }
  .intuition { min-height: 0; padding-bottom: 20px; }
  .choice-row,
  .debunk-grid,
  .effort-pair { grid-template-columns: 1fr; }
  .sheet { margin-inline: -4px; }
  .sheet-meta { flex-direction: column; gap: 2px; }
  .article-body { font-size: 1.04rem; }
  .step-actions .primary-button,
  .step-actions .secondary-button { width: 100%; }
}

@media print {
  .step[hidden] { display: none !important; }
  .sheet { box-shadow: none; }
}
