:root {
  --table: #26221f;
  --paper: #e9e4d6;
  --paper-2: #e5dcc8;
  --ink: #221f1d;
  --ink-2: #4b4541;
  --rule: #2a2622;
  --red: #c3202b;
  --serif: 'Newsreader', Georgia, 'Times New Roman', serif;
  --head: 'Playfair Display', 'Times New Roman', Georgia, serif;
  --gothic: 'UnifrakturMaguntia', 'Old English Text MT', Georgia, serif;
  --hand: 'Caveat Brush', 'Segoe Print', 'Bradley Hand', cursive;
  --mono: ui-monospace, 'Cascadia Mono', Consolas, 'Courier New', monospace;
  --tilt: -0.6deg;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { -webkit-text-size-adjust: 100%; }

body {
  min-height: 100vh;
  padding: 36px 18px 60px;
  background: var(--table);
  background-image:
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(255, 255, 255, .07), transparent 70%),
    radial-gradient(ellipse 120% 80% at 50% 100%, rgba(0, 0, 0, .35), transparent 70%);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 16.5px;
  line-height: 1.42;
  overflow-x: hidden;
}

a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--red); }
b { font-weight: 800; }

.mono { font-family: var(--mono); font-size: .86em; overflow-wrap: anywhere; }

.scene { perspective: 1800px; perspective-origin: 50% 20%; }

/* ------------------------------------------------------------ Le papier */
.paper {
  position: relative;
  isolation: isolate;
  max-width: 1140px;
  margin: 0 auto;
  padding: 18px clamp(16px, 3.4vw, 42px) 22px;
  color: var(--ink);
  /* Papier journal : base gris-jaune, taches de jaunissement, fibres, grain, bords plus jaunis */
  background-color: var(--paper);
  background-image:
    radial-gradient(ellipse 80% 75% at 50% 45%, transparent 60%, rgba(130, 105, 60, .13) 100%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='800' height='800'%3E%3Cfilter id='f' x='0' y='0' width='100%' height='100%'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.0035' numOctaves='2' seed='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .7 0 0 0 0 .64 0 0 0 0 .5 .35 0 0 0 -.12'/%3E%3C/filter%3E%3Crect width='100%' height='100%' filter='url(%23f)'/%3E%3C/svg%3E"),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='380' height='380'%3E%3Cfilter id='f' x='0' y='0' width='100%' height='100%'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.55' numOctaves='1' seed='19' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .25 0 0 0 0 .22 0 0 0 0 .18 -42 0 0 0 9.2'/%3E%3C/filter%3E%3Crect width='100%' height='100%' filter='url(%23f)'/%3E%3C/svg%3E"),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='f' x='0' y='0' width='100%' height='100%'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='1.1 .7' numOctaves='3' seed='4' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .3 0 0 0 0 .28 0 0 0 0 .24 0 0 0 .3 -.03'/%3E%3C/filter%3E%3Crect width='100%' height='100%' filter='url(%23f)'/%3E%3C/svg%3E");
  background-size: 100% 100%, 800px 800px, 380px 380px, 240px 240px;
  background-blend-mode: multiply;
  box-shadow:
    inset 0 0 0 1px rgba(120, 95, 50, .18),
    inset 0 0 26px rgba(130, 105, 60, .1),
    0 1px 1px rgba(0, 0, 0, .3),
    0 14px 28px -10px rgba(0, 0, 0, .55),
    0 40px 60px -24px rgba(0, 0, 0, .6);
  /* L'encre bave légèrement dans les fibres */
  text-shadow: 0 0 .7px rgba(33, 30, 28, .55);
  transform: rotate(var(--tilt));
  transform-origin: 50% 30%;
}
/* Manques d'encre, par-dessus tout le contenu */
.paper::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='f' x='0' y='0' width='100%' height='100%'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.7' numOctaves='2' seed='7' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .925 0 0 0 0 .9 0 0 0 0 .83 16 0 0 0 -11.6'/%3E%3C/filter%3E%3Crect width='100%' height='100%' filter='url(%23f)'/%3E%3C/svg%3E");
  background-size: 300px 300px;
  mix-blend-mode: lighten;
  opacity: .75;
}
/* Pli horizontal du quotidien : la moitié basse un peu dans l'ombre, l'arête accroche la lumière */
.paper-une::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: linear-gradient(180deg,
    transparent 0,
    transparent calc(50% - 46px),
    rgba(60, 45, 25, .05) calc(50% - 10px),
    rgba(60, 45, 25, .12) calc(50% - 1px),
    rgba(255, 252, 240, .45) 50%,
    rgba(255, 252, 240, .12) calc(50% + 3px),
    rgba(60, 45, 25, .045) calc(50% + 22px),
    rgba(60, 45, 25, .03) 75%,
    rgba(60, 45, 25, .045) 100%);
}
/* Ce qui est imprimé au verso se devine à travers le papier */
.verso {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  padding: 26px clamp(16px, 3.4vw, 42px);
  transform: scaleX(-1);
  opacity: .05;
  filter: blur(.8px);
  pointer-events: none;
  user-select: none;
  text-shadow: none;
}
.verso-head {
  font-family: var(--head);
  font-weight: 900;
  font-size: clamp(30px, 5vw, 60px);
  line-height: 1;
  text-align: left;
  margin: 70px 0 16px;
}
.verso-photo {
  float: right;
  width: 38%;
  aspect-ratio: 4 / 3;
  margin: 0 0 14px 20px;
  background: #6d6660;
}
.verso-cols { columns: 4; column-gap: 20px; font-size: 15px; line-height: 1.4; text-align: justify; }
.verso-cols p { margin-bottom: .5em; }

/* Texte clair sur fond d'encre : pas de bavure sombre autour */
.kicker, .coupon-btn, .prose pre { text-shadow: none; }

/* ------------------------------------------------------------ Bandeau titre */
.topline {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--rule);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.topline small { font-weight: 400; letter-spacing: 0; text-transform: none; font-style: italic; }
.topline-date::first-letter { text-transform: uppercase; }

.nameplate {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
  padding: 10px 0 6px;
}
.ear {
  justify-self: start;
  max-width: 180px;
  padding: 5px 8px;
  border: 1px solid var(--rule);
  font-size: 12px;
  line-height: 1.3;
  font-style: italic;
}
.ear small { font-style: normal; color: var(--ink-2); }
.ear-right { justify-self: end; text-align: right; }
.title {
  font-family: var(--gothic);
  font-weight: 400;
  font-size: clamp(42px, 8.2vw, 96px);
  line-height: 1;
  text-align: center;
  white-space: nowrap;
}
.title a { text-decoration: none; color: var(--ink); }

/* Filet anglais : gros trait, puis trait fin */
.masthead { border-bottom: 1px solid var(--rule); }
.summary {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px 0;
  padding: 5px 0 4px;
  border-top: 3px solid var(--rule);
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.summary a { text-decoration: none; padding: 0 12px; }
.summary a + a { border-left: 1px solid var(--rule); }

/* ------------------------------------------------------------ La une */
.lead { padding: 18px 0 8px; text-align: center; }
.kicker {
  display: inline-block;
  padding: 2px 10px 1px;
  background: var(--ink);
  color: var(--paper);
  font-size: 12.5px;
  font-weight: 800;
  letter-spacing: .22em;
  text-transform: uppercase;
}
.headline {
  margin-top: 10px;
  font-family: var(--head);
  font-weight: 900;
  font-size: clamp(28px, 4.5vw, 54px);
  line-height: 1.02;
  letter-spacing: -.012em;
}
.ip-line {
  position: relative;
  display: inline-block;
  max-width: 100%;
  margin: clamp(16px, 2.8vw, 40px) 0 14px;
}
.ip {
  font-family: var(--head);
  font-weight: 900;
  font-variant-numeric: lining-nums tabular-nums;
  font-size: clamp(46px, 12.2vw, 158px);
  line-height: .98;
  letter-spacing: -.03em;
  padding: 0 .12em;
}
.ip span { display: inline-block; }
.ip-long { font-size: clamp(26px, 5.8vw, 76px); letter-spacing: -.01em; line-height: 1.05; }

/* Le coup de feutre et l'annotation */
.mark {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  pointer-events: none;
  mix-blend-mode: multiply;
}
.mark path {
  fill: none;
  stroke: var(--red);
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
}
.scribble {
  display: block;
  margin-right: 4%;
  text-align: right;
  font-family: var(--hand);
  font-size: clamp(22px, 2.8vw, 34px);
  line-height: 1;
  color: var(--red);
  white-space: nowrap;
  mix-blend-mode: multiply;
}
.scribble span { display: inline-block; transform: rotate(-5deg); }
.deck {
  max-width: 46ch;
  margin: 0 auto;
  font-size: clamp(17px, 2vw, 21px);
  font-weight: 600;
  line-height: 1.3;
}

/* ------------------------------------------------------------ Corps */
.body {
  display: grid;
  grid-template-columns: minmax(0, 8fr) minmax(0, 4fr);
  margin-top: 18px;
  border-top: 1px solid var(--rule);
}
.body > * { padding-top: 12px; }
.body > * + * { margin-left: 20px; padding-left: 20px; border-left: 1px solid var(--rule); }

.byline {
  margin-bottom: 8px;
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.cols {
  columns: 3;
  column-gap: 20px;
  column-rule: 1px solid var(--rule);
}
.cols p {
  margin-bottom: .55em;
  text-align: justify;
  text-indent: 1.1em;
  hyphens: auto;
  -webkit-hyphens: auto;
  font-size: 15.5px;
  line-height: 1.4;
}
.cols p:first-child { text-indent: 0; }
/* Lettrine */
.cols p:first-child::first-letter {
  float: left;
  margin: .04em .08em 0 0;
  font-family: var(--head);
  font-weight: 900;
  font-size: 3.55em;
  line-height: .78;
}
.dateline { font-weight: 800; letter-spacing: .06em; }
.jump {
  margin-top: 4px;
  font-size: 12.5px;
  font-style: italic;
  text-align: right;
}
.jump small { font-size: 11px; color: var(--ink-2); }

/* Intertitres de rubrique : petit texte espacé entre deux filets */
.rubric {
  margin-bottom: 8px;
  padding: 3px 0;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  font-family: var(--serif);
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: .2em;
  text-transform: uppercase;
  text-align: center;
}
* + .rubric { margin-top: 16px; }

.facts { display: grid; }
.facts dt {
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.facts dd { margin-bottom: 7px; font-size: 15.5px; line-height: 1.3; overflow-wrap: anywhere; }

.coupon {
  position: relative;
  margin-top: 18px;
  padding: 14px 12px 11px;
  border: 1.5px dashed var(--rule);
  background: var(--paper-2);
  text-align: center;
}
.coupon::before {
  content: '\2702\FE0E';
  position: absolute;
  top: -13px;
  left: 12px;
  padding: 0 4px;
  background: var(--paper);
  font-size: 18px;
  line-height: 1;
}
.coupon-head { font-size: 11.5px; font-weight: 800; letter-spacing: .2em; text-transform: uppercase; }
.coupon-ip { margin: 4px 0 9px; font-size: 19px; font-weight: 700; }
.coupon-btn {
  width: 100%;
  padding: 8px 10px;
  border: 0;
  background: var(--ink);
  color: var(--paper);
  font: 600 14px var(--serif);
  letter-spacing: .04em;
  cursor: pointer;
}
.coupon-btn:hover { background: var(--red); }
.coupon-btn:focus-visible, .link-btn:focus-visible, a:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }
.coupon-fine { margin-top: 6px; font-size: 11px; font-style: italic; color: var(--ink-2); }

.quote { margin-top: 18px; padding-top: 8px; border-top: 3px solid var(--rule); }
.quote p { font-family: var(--head); font-style: italic; font-weight: 700; font-size: 21px; line-height: 1.2; }
.quote footer { margin-top: 5px; font-size: 12.5px; color: var(--ink-2); }
.quote footer::before { content: '— '; }

/* ------------------------------------------------------------ Bas de page */
.bottom {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 18px;
  border-top: 3px solid var(--rule);
  padding-top: 12px;
}
.bottom > * + * { margin-left: 20px; padding-left: 20px; border-left: 1px solid var(--rule); }

.photo svg {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--rule);
  background: var(--paper-2);
}
.photo figcaption { margin-top: 5px; font-size: 12.5px; line-height: 1.35; }
.brief p { font-size: 14.5px; line-height: 1.4; }
.ads ul { list-style: none; }
.ads li { padding: 5px 0; border-bottom: 1px dotted var(--ink-2); font-size: 13px; line-height: 1.35; }
.ads li:last-child { border-bottom: 0; }

.reclame {
  margin-top: 18px;
  padding: 10px 16px 12px;
  border: 1px solid var(--rule);
  box-shadow: inset 0 0 0 3px var(--paper), inset 0 0 0 4px var(--rule);
  text-align: center;
}
.reclame-label { font-size: 10.5px; font-weight: 600; letter-spacing: .3em; text-transform: uppercase; color: var(--ink-2); }
.reclame-name { margin-top: 2px; font-family: var(--head); font-weight: 900; font-size: clamp(22px, 3vw, 32px); line-height: 1.1; }
.reclame-text { max-width: 60ch; margin: 3px auto 0; font-size: 14px; font-style: italic; }

.colophon { margin-top: 18px; padding-top: 6px; border-top: 1px solid var(--rule); font-size: 12.5px; }
.colophon-links { text-align: center; line-height: 1.8; }
.folio-line {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 6px;
  padding-top: 4px;
  border-top: 3px solid var(--rule);
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.link-btn {
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
}
.link-btn:hover { color: var(--red); }

.toast {
  position: fixed;
  left: 50%;
  bottom: 22px;
  z-index: 10;
  max-width: calc(100% - 32px);
  padding: 9px 16px;
  background: var(--ink);
  color: var(--paper);
  font-size: 15px;
  font-style: italic;
  box-shadow: 0 8px 20px rgba(0, 0, 0, .4);
  opacity: 0;
  transform: translate(-50%, 12px);
  transition: opacity .2s, transform .2s;
  pointer-events: none;
}
.toast.in { opacity: 1; transform: translate(-50%, 0); }

/* ------------------------------------------------------------ Pages secondaires */
.paper-static { --tilt: -0.3deg; }
.masthead-small { padding-top: 4px; }
.masthead-small .title { display: block; font-size: clamp(34px, 6vw, 64px); }
.folio {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 8px;
  padding: 4px 0;
  border-top: 3px solid var(--rule);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.page { padding: 20px 0 4px; }
.page .headline { margin: 0 0 14px; text-align: left; font-size: clamp(26px, 4vw, 44px); }
.prose { max-width: 64ch; }
.prose p { margin-bottom: .8em; }
.prose pre {
  margin: 0 0 .9em;
  padding: 9px 12px;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--mono);
  font-size: 14px;
  overflow-x: auto;
}
.page .lede { margin-bottom: 14px; }
.headers { width: 100%; border-collapse: collapse; font-size: 14px; }
.headers td { padding: 6px 8px 6px 0; border-bottom: 1px dotted var(--ink-2); vertical-align: top; }
.headers td:first-child { padding-right: 18px; font-weight: 600; white-space: nowrap; }
.headers td:last-child { font-family: var(--mono); font-size: 13px; overflow-wrap: anywhere; }

/* ------------------------------------------------------------ On pose le journal sur la table */
.js .paper-une { opacity: 0; }
.js .paper-une.go {
  opacity: 1;
  animation:
    land .95s cubic-bezier(.2, .75, .25, 1) both,
    settle .3s .95s ease-out;
}
@keyframes land {
  0% {
    opacity: 0;
    transform: translateY(-32vh) rotate(-7deg) rotateX(26deg) scale(1.1);
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0), 0 120px 60px -20px rgba(0, 0, 0, .25), 0 200px 120px -40px rgba(0, 0, 0, .2);
  }
  15% { opacity: 1; }
  100% {
    opacity: 1;
    transform: translateY(0) rotate(var(--tilt)) rotateX(0) scale(1);
    box-shadow: 0 1px 1px rgba(0, 0, 0, .3), 0 14px 28px -10px rgba(0, 0, 0, .55), 0 40px 60px -24px rgba(0, 0, 0, .6);
  }
}
@keyframes settle {
  0%, 100% { transform: rotate(var(--tilt)); }
  40% { transform: rotate(calc(var(--tilt) + .25deg)) translateY(2px); }
}

/* Le feutre : on trace, puis la flèche, puis l'annotation */
.js .mark path { stroke-dashoffset: 1; }
.js .scribble { opacity: 0; }
.landed .mark .pen { animation: draw .85s cubic-bezier(.4, .05, .25, 1) forwards; }
.landed .mark .pen-2 { animation-delay: .04s; }
.landed .mark .pen-3 { animation-delay: .07s; }
.landed .mark .arrow { animation: draw .3s .95s ease-out forwards; }
.landed .scribble { animation: show .2s 1.2s ease-out forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes show { from { opacity: 0; } to { opacity: 1; } }

@media (prefers-reduced-motion: reduce) {
  .js .paper-une.go { animation: none; }
  .landed .mark path, .landed .scribble { animation-duration: .01s; animation-delay: 0s; }
}

/* ------------------------------------------------------------ Écrans moyens et petits */
@media (max-width: 960px) {
  .cols { columns: 2; }
  .bottom { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .bottom .ads { grid-column: 1 / -1; margin: 16px 0 0; padding: 12px 0 0; border-left: 0; border-top: 1px solid var(--rule); }
}
@media (max-width: 760px) {
  .body { grid-template-columns: minmax(0, 1fr); }
  .body > * + * { margin: 16px 0 0; padding: 12px 0 0; border-left: 0; border-top: 1px solid var(--rule); }
  .side { display: grid; grid-template-columns: 1fr 1fr; gap: 0 20px; align-items: start; }
  .side .quote { grid-column: 1 / -1; }
}
@media (max-width: 600px) {
  :root { --tilt: 0deg; }
  body { padding: 14px 10px 44px; font-size: 16px; }
  .paper { padding-left: 14px; padding-right: 14px; }
  .topline { flex-wrap: wrap; justify-content: center; gap: 2px 14px; }
  .nameplate { grid-template-columns: 1fr; gap: 0; }
  .ear { display: none; }
  .summary a { padding: 0 8px; }
  .cols { columns: 1; }
  .verso-cols { columns: 2; }
  .bottom { grid-template-columns: minmax(0, 1fr); }
  .bottom > * + * { margin: 16px 0 0; padding: 12px 0 0; border-left: 0; border-top: 1px solid var(--rule); }
  .side { display: block; }
  .photo { max-width: 400px; }
  .folio-line { flex-wrap: wrap; justify-content: center; gap: 2px 12px; }
}

/* ------------------------------------------------------------ Site statique */
/* Message posé sur la table pendant que la rotative imprime l'édition */
.press {
  max-width: 640px;
  margin: 18vh auto 0;
  color: #d9d1c0;
  font-size: 19px;
  font-style: italic;
  text-align: center;
}
.press .link-btn { color: #f1ead9; font-style: normal; }
.paper-une:empty { display: none; }

/* Éditions étrangères : les infos au format machine, à déplier */
.editions { margin-bottom: 10px; border-bottom: 1px solid var(--rule); padding-bottom: 8px; }
.editions summary {
  cursor: pointer;
  font-size: 12.5px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
  text-align: center;
}
.editions summary small { font-weight: 400; letter-spacing: .02em; text-transform: none; font-style: italic; }
.editions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 14px 20px;
  margin-top: 10px;
}
.editions figcaption { font-size: 11px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; margin-bottom: 4px; }
.editions pre {
  margin: 0;
  padding: 8px 10px;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--mono);
  font-size: 12px;
  line-height: 1.45;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  text-shadow: none;
}

.prose ul.sources { margin: 0 0 .8em 1.2em; }
.prose ul.sources li { margin-bottom: .35em; }
.prose code { font-family: var(--mono); font-size: .88em; }
