/* Provashot — sections de la page d'accueil (FR et EN), chargée après
 * style.css. Histoire d'exemple unique, celle des captures de l'app :
 * « Extension arrière », famille Lambert, 1300 Wavre, Brique & Bois SRL. */

:root {
  /* Papier du rapport : blanc dans les deux thèmes, comme le PDF de l'app */
  --paper: #fefefe;
  --paper-ink: #1d2026;
  --paper-muted: #5f6670;
  --paper-line: #e4e6ea;
  --paper-mark: #24503f;
  --paper-mark-ink: #f4f1e6;
  --paper-before: #a8620f;
  --paper-after: #1b7f55;
  --paper-tag-ink: #fefefe;
  --stamp-ring: #0b102966;
  --paper-shadow: 0 30px 60px -24px #121a3e80, 0 6px 16px -8px #121a3e40;
}

/* ---------- Héros ---------- */
.pv-hero { position: relative; isolation: isolate; overflow: hidden; text-align: center; padding-top: var(--space-7); }
.pv-hero::before { content: ""; position: absolute; z-index: -1; left: 50%; bottom: -200px; width: min(1180px, 150%); height: 760px; transform: translateX(-50%); background: radial-gradient(closest-side, var(--glow), transparent); }
.pv-hero h1 { margin: 0 auto; max-width: none; font-size: clamp(42px, 6vw, 78px); line-height: 0.98; font-weight: 700; letter-spacing: -0.02em; }
.pv-hero h1 > span { display: block; }
@media (min-width: 1024px) { .pv-hero h1 > span { white-space: nowrap; } }
.pv-hero__lede { margin: var(--space-5) auto 0; max-width: 52ch; font-size: 19px; line-height: 1.55; color: var(--ink-muted); }
.pv-hero .pv-stores { justify-content: center; margin-top: var(--space-6); }
.pv-hero__stage { position: relative; display: flex; justify-content: center; height: 500px; margin-top: var(--space-7); }
.pv-hero__stage .pv-screen { --w: 300px; }
.pv-hero__float { position: absolute; }
.pv-hero__float { z-index: 1; }
/* Accrochées aux bords de l'écran (300 px), comme émises par lui */
/* Accrochées au bord de l'écran (300 px) sans couvrir de texte : 8 px sur sa marge */
.pv-hero__float--a { right: calc(50% + 142px); top: 112px; }
.pv-hero__float--b { left: calc(50% + 142px); top: 236px; }
/* Le déclic : un éclair sur l'écran, puis la photo enregistrée arrive.
 * Tout est visible au repos ; seul le mouvement est retiré si l'utilisateur
 * réduit les animations. */
.pv-hero__stage .pv-screen::after { content: ""; position: absolute; inset: 0; background: var(--surface); opacity: 0; pointer-events: none; }
@media (prefers-reduced-motion: no-preference) {
  .pv-hero__stage .pv-screen::after { animation: pv-flash 520ms var(--ease-out) 420ms 1 both; }
  .pv-hero__float { animation: pv-settle 900ms var(--ease-out) both; }
  .pv-hero__float--a { animation-delay: 620ms; }
  .pv-hero__float--b { animation-delay: 760ms; }
  .pv-hero__float--a .pv-float__dot { animation: pv-rec 1.2s ease-out 1200ms 2; }
}
@keyframes pv-flash { 0% { opacity: 0; } 18% { opacity: .85; } 100% { opacity: 0; } }
@keyframes pv-settle { from { transform: translateY(14px) scale(.97); } to { transform: none; } }
@keyframes pv-rec { 0%, 100% { box-shadow: 0 0 0 0 var(--signal); } 60% { box-shadow: 0 0 0 6px transparent; } }
@media (max-width: 760px) {
  /* Sur mobile, les deux cartes passent en rangée juste au-dessus de l'écran,
   * dans le premier écran, sans rien couvrir. */
  .pv-hero__stage { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-content: start; gap: 8px; height: auto; max-height: 580px; margin-top: var(--space-6); padding-inline: var(--gutter); }
  .pv-hero__stage .pv-screen { --w: 250px; order: 2; grid-column: 1 / -1; justify-self: center; margin-top: var(--space-3); }
  .pv-hero h1 { max-width: 13ch; }
  .pv-hero__float, .pv-hero__float--a, .pv-hero__float--b { position: static; order: 1; min-width: 0; }
  .pv-hero__float .pv-float { display: flex; flex-direction: column; align-items: flex-start; width: 100%; height: 100%; gap: 6px; padding: 10px; }
  .pv-hero__float .pv-float__title { white-space: nowrap; }
  .pv-hero__float .pv-float__icon, .pv-hero__float .pv-float__thumb { width: 34px; height: 34px; padding: 6px; }
  .pv-hero__float .pv-float__thumb { padding: 0; }
  .pv-hero__float .pv-float__icon .pv-icon { font-size: 20px; }
  .pv-hero__float .pv-float__title { font-size: 13px; }
  .pv-hero__float .pv-float__meta { font-size: 12px; }
}

/* ---------- Bande des métiers ---------- */
.pv-trades { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px 18px; margin: 0; padding: var(--space-6) 0 0; list-style: none; color: var(--ink-muted); font: 600 16px/1.2 var(--font-display); }
.pv-trades .pv-icon { font-size: 20px; }
.pv-trades li { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }
.pv-trades .pv-icon { color: var(--accent-ink); }
@media (max-width: 640px) {
  .pv-trades { flex-wrap: nowrap; justify-content: flex-start; overflow-x: auto; scroll-snap-type: x proximity; scroll-padding-inline: var(--gutter); scrollbar-width: none; margin-inline: calc(-1 * var(--gutter)); padding: var(--space-5) var(--gutter) var(--space-2); gap: 16px; font-size: 15px; -webkit-mask-image: linear-gradient(to right, #000 78%, transparent); mask-image: linear-gradient(to right, #000 78%, transparent); }
  .pv-trades::-webkit-scrollbar { display: none; }
  .pv-trades li { scroll-snap-align: start; }
}

/* ---------- Deux publics ---------- */
.pv-paths { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-5); }
.pv-path { display: grid; gap: var(--space-4); align-content: start; justify-items: start; padding: var(--space-6); border-radius: var(--radius-lg); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.pv-path--client { background: var(--night); color: var(--on-night); box-shadow: inset 0 0 0 1px var(--night-edge); }
.pv-path__icon { display: grid; place-items: center; width: 52px; height: 52px; padding: var(--space-3); border-radius: var(--radius-card); background: var(--chantier); color: var(--on-chantier); }
.pv-path__icon .pv-icon { font-size: 28px; }
.pv-path h3 { margin: 0; font-size: clamp(26px, 2.6vw, 32px); line-height: 1.08; }
.pv-path > p { margin: 0; color: var(--ink-muted); }
.pv-path--client > p { color: var(--on-night-muted); }
.pv-path .pv-checks { font-size: 16px; }
.pv-path .pv-btn { margin-top: var(--space-2); }
@media (max-width: 860px) { .pv-paths { grid-template-columns: minmax(0, 1fr); } .pv-path { padding: var(--space-5); } }

/* ---------- Étapes autour du téléphone ---------- */
.pv-steps { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); gap: var(--space-5) 56px; align-items: center; }
.pv-steps__col { display: grid; gap: var(--space-5); margin: 0; padding: 0; list-style: none; }
.pv-step { position: relative; padding: var(--space-5); background: var(--surface); border-radius: var(--radius-card); box-shadow: inset 0 0 0 1px var(--line); }
.pv-step .pv-num { margin-bottom: 14px; }
.pv-step h3 { margin: 0 0 6px; font-size: 23px; line-height: 1.15; }
.pv-step p { margin: 0; font-size: 15px; line-height: 1.55; color: var(--ink-muted); }
.pv-step::after { content: ""; position: absolute; top: 50%; width: 56px; border-top: 2px dashed var(--line-strong); }
.pv-steps__col--start .pv-step::after { right: -57px; }
.pv-steps__col--end .pv-step::after { left: -57px; }
@media (max-width: 960px) {
  .pv-steps { grid-template-columns: minmax(0, 1fr); }
  .pv-steps > .pv-screen, .pv-steps > .pv-phasestack { justify-self: center; order: -1; margin-bottom: var(--space-4); }
  .pv-step::after { display: none; }
}

/* Les trois photos du chantier, une par phase, chacune avec son tampon */
.pv-phasestack { display: grid; gap: var(--space-3); width: 300px; max-width: 100%; }
.pv-phasestack__item { position: relative; margin: 0; }
.pv-phasestack__item img { display: block; width: 100%; height: auto; border-radius: var(--radius-card); box-shadow: var(--shadow-screen); }
.pv-phasestack__item:nth-child(1) { transform: rotate(-1.5deg); }
.pv-phasestack__item:nth-child(3) { transform: rotate(1.5deg); }
.pv-phasestack__item .pv-chip { position: absolute; top: 10px; left: 10px; }
@media (max-width: 640px) { .pv-phasestack { width: 260px; } }

/* ---------- Le rapport (aplat jaune gradué + page A4) ---------- */
.pv-showcase { position: relative; overflow: hidden; isolation: isolate; display: flex; justify-content: center; align-items: flex-start; min-height: 560px; padding: 64px 40px 0; border-radius: var(--radius-xl); background: var(--chantier); }
.pv-showcase .pv-report { transform: rotate(-2deg); margin-bottom: -120px; }
@media (max-width: 640px) { .pv-showcase { min-height: 0; padding: 48px 20px 0; } .pv-showcase .pv-report { margin-bottom: -60px; } }

.pv-report { width: 100%; max-width: 470px; padding: 28px 28px 36px; background: var(--paper); color: var(--paper-ink); border-radius: 4px; box-shadow: var(--paper-shadow); font: 400 12px/1.45 var(--font-sans); text-align: left; }
.pv-report__co { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 14px; }
.pv-report__co b { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 7px; background: var(--paper-mark); color: var(--paper-mark-ink); font-size: 12px; }
.pv-report__label { margin: 22px 0 4px; font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--paper-muted); }
.pv-report__title { margin: 0; font: 700 26px/1.1 var(--font-sans); letter-spacing: -0.01em; }
.pv-report__meta { margin: 6px 0 16px; color: var(--paper-muted); }
.pv-report__row { display: grid; grid-template-columns: minmax(0, 1fr) 84px; gap: 12px; align-items: start; padding: 8px 0; border-top: 1px solid var(--paper-line); }
.pv-report__row img { display: block; width: 100%; height: auto; border-radius: 2px; }
.pv-report__tag { display: inline-block; padding: 3px 7px; border-radius: 3px; color: var(--paper-tag-ink); font-size: 11px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
.pv-report__tag--before { background: var(--paper-before); }
.pv-report__tag--after { background: var(--paper-after); }
.pv-report__date { display: block; margin-top: 4px; color: var(--paper-muted); font-variant-numeric: tabular-nums; }

/* ---------- La preuve : photo pleine colonne, lecture du tampon dessous ---------- */
.pv-proof { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: var(--space-8); align-items: start; }
.pv-proof__copy { display: grid; gap: var(--space-5); justify-items: start; }
.pv-proof__copy h2 { margin: 0; font-size: clamp(34px, 4.4vw, 50px); line-height: 1.05; }
.pv-proof__copy > p { margin: 0; font-size: 18px; color: var(--ink-muted); }
@media (max-width: 900px) { .pv-proof { grid-template-columns: minmax(0, 1fr); gap: var(--space-6); } }
/* Lecture du tampon : repères posés sur les trois lignes du tampon incrusté.
 * Géométrie tirée du format de l'app (stamp_renderer.dart) pour cette photo
 * 4:3 : lignes à 78,2 / 84,2 / 90,3 % de la hauteur, fins de ligne à 47,4 /
 * 44,1 / 64,0 %, cadre jusqu'à 66,2 % de la largeur. */
.pv-annot { position: relative; }
.pv-annot__lead { position: absolute; height: 2px; margin-top: -1px; background: var(--chantier); border-radius: 1px; }
.pv-annot__lead--1 { top: 78.2%; left: 48.4%; width: 20.6%; }
.pv-annot__lead--2 { top: 84.2%; left: 45.1%; width: 23.9%; }
.pv-annot__lead--3 { top: 90.3%; left: 65%; width: 4%; }
.pv-annot__pin, .pv-annot__num { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: var(--radius-pill); background: var(--chantier); color: var(--on-chantier); font: 700 13px/1 var(--font-display); font-variant-numeric: tabular-nums; flex: none; }
.pv-annot__pin { position: absolute; left: 69%; transform: translateY(-50%); box-shadow: 0 0 0 2px var(--stamp-ring); }
.pv-annot__pin--1 { top: 78.2%; }
.pv-annot__pin--2 { top: 84.2%; }
.pv-annot__pin--3 { top: 90.3%; }
.pv-annot__key { display: grid; gap: var(--space-3); margin: var(--space-5) 0 0; padding: 0; list-style: none; }
.pv-annot__key li { display: grid; grid-template-columns: 24px minmax(0, 1fr); gap: var(--space-3); align-items: start; color: var(--ink-muted); font-size: 16px; line-height: 1.45; }
.pv-annot__key strong { color: var(--ink); font-weight: 600; }
@media (max-width: 560px) { .pv-annot__lead, .pv-annot__pin { display: none; } }

/* ---------- Vos données ---------- */
.pv-ledger { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr); gap: var(--space-6); align-items: start; }
.pv-ledger h2 { margin: 0; font-size: clamp(30px, 3.4vw, 40px); line-height: 1.08; }
.pv-ledger dl { display: grid; margin: 0; }
.pv-ledger dl div { display: grid; grid-template-columns: 28px minmax(0, 200px) minmax(0, 1fr); gap: var(--space-3); align-items: baseline; padding: var(--space-4) 0; border-top: 1px solid var(--line); }
.pv-ledger dl div:last-child { border-bottom: 1px solid var(--line); }
.pv-ledger .pv-icon { color: var(--accent-ink); align-self: center; }
.pv-ledger dt { font: 600 20px/1.2 var(--font-display); }
.pv-ledger dd { margin: 0; color: var(--ink-muted); font-size: 16px; }
@media (max-width: 860px) { .pv-ledger { grid-template-columns: minmax(0, 1fr); } .pv-ledger dl div { grid-template-columns: 28px minmax(0, 1fr); } .pv-ledger dd { grid-column: 2; } }

/* ---------- Bandeau final : la paire avant/après tamponnée ---------- */
.pv-cta__art--photos { align-self: stretch; height: auto; min-height: 430px; overflow: visible; }
.pv-cta__photo { position: absolute; width: 66%; height: auto; border-radius: var(--radius-card); box-shadow: var(--shadow-screen-night); }
.pv-cta__photo--a { left: 0; top: 40px; transform: rotate(-3deg); }
.pv-cta__photo--b { right: 0; top: 170px; transform: rotate(2deg); }
@media (max-width: 860px) { .pv-cta__art--photos { min-height: 300px; margin-bottom: var(--space-6); } .pv-cta__photo--a { top: 8px; } .pv-cta__photo--b { top: 110px; } }
