/* Doodimo — design system. Papier crème, encre, une touche de vermillon. */
@font-face { font-family: "Inter"; src: url("../fonts/Inter-Regular.otf") format("opentype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/Inter-Medium.otf") format("opentype"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/Inter-SemiBold.otf") format("opentype"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/Inter-Bold.otf") format("opentype"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Lora"; src: url("../fonts/Lora-Variable.ttf") format("truetype"); font-weight: 400 700; font-display: swap; }
@font-face { font-family: "Lora"; src: url("../fonts/Lora-Italic-Variable.ttf") format("truetype"); font-weight: 400 700; font-style: italic; font-display: swap; }

:root {
  --paper: #FBF8F3;
  --paper-2: #F4EEE4;
  --paper-3: #EDE5D8;
  --card: #FFFFFF;
  --ink: #17151C;
  --ink-2: #3A3640;
  --muted: #76717D;
  --line: #E6DED1;
  --line-2: #D9CFBF;
  --accent: #E4572E;
  --accent-ink: #C2410C;
  --accent-soft: #FCE6DC;
  --gold: #E9A23B;
  --lilac: #E7DEF6;
  --mint: #DCEFE3;
  --ok: #2F8F5B;
  --ok-soft: #E2F3E8;
  --warn: #B7791F;
  --warn-soft: #FBF0D9;
  --bad: #C53030;
  --bad-soft: #FBE3E3;
  --r-sm: 10px;
  --r: 16px;
  --r-lg: 24px;
  --shadow-sm: 0 1px 2px rgba(23, 21, 28, .06), 0 1px 1px rgba(23, 21, 28, .04);
  --shadow: 0 10px 30px -12px rgba(23, 21, 28, .18), 0 2px 6px rgba(23, 21, 28, .05);
  --shadow-lg: 0 40px 80px -30px rgba(23, 21, 28, .35), 0 10px 24px -12px rgba(23, 21, 28, .15);
  --serif: "Lora", Georgia, "Times New Roman", serif;
  --sans: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --container: 1180px;
}

*, *::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(--sans);
  font-size: 16px; line-height: 1.55; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
::selection { background: var(--accent-soft); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 24px; }
.serif { font-family: var(--serif); }
.muted { color: var(--muted); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.grain { position: fixed; inset: 0; pointer-events: none; z-index: 0; opacity: .35; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0.09 0 0 0 0 0.08 0 0 0 0 0.11 0 0 0 .06 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
main, header, footer { position: relative; z-index: 1; }

/* --- Typographie ------------------------------------------------------- */
h1, h2, h3, h4 { margin: 0; letter-spacing: -.02em; line-height: 1.08; font-weight: 600; }
.display { font-family: var(--serif); font-weight: 500; letter-spacing: -.025em; }
.display em, h2 em { font-style: italic; color: var(--accent); font-weight: 500; }
.kicker { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--accent-ink); }
.kicker::before { content: ""; width: 18px; height: 2px; background: var(--accent); border-radius: 2px; }
.lead { font-size: 19px; color: var(--ink-2); max-width: 46ch; }
.section-title { font-family: var(--serif); font-weight: 500; font-size: clamp(32px, 4.4vw, 52px); margin-top: 14px; max-width: 20ch; }

/* --- Boutons ----------------------------------------------------------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; height: 48px; padding: 0 22px; border-radius: 999px;
  border: 1px solid transparent; font-weight: 600; font-size: 15px; text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: transform .2s var(--ease), background .2s, box-shadow .2s, border-color .2s, color .2s; user-select: none; }
.btn:active { transform: translateY(1px) scale(.99); }
.btn-primary { background: var(--ink); color: var(--paper); box-shadow: 0 8px 20px -8px rgba(23,21,28,.55); }
.btn-primary:hover { background: #000; transform: translateY(-1px); box-shadow: 0 14px 28px -10px rgba(23,21,28,.6); }
.btn-accent { background: var(--accent); color: #fff; box-shadow: 0 10px 24px -10px rgba(228,87,46,.7); }
.btn-accent:hover { background: var(--accent-ink); transform: translateY(-1px); }
.btn-ghost { background: transparent; border-color: var(--line-2); color: var(--ink); }
.btn-ghost:hover { background: var(--card); border-color: var(--ink); }
.btn-soft { background: var(--paper-2); color: var(--ink); }
.btn-soft:hover { background: var(--paper-3); }
.btn-sm { height: 36px; padding: 0 14px; font-size: 14px; }
.btn-lg { height: 56px; padding: 0 28px; font-size: 16px; }
.btn-block { width: 100%; }
.btn[disabled], .btn.is-loading { opacity: .55; pointer-events: none; }
.btn .spin { width: 16px; height: 16px; }
.icon-btn { width: 38px; height: 38px; border-radius: 12px; display: inline-grid; place-items: center; border: 1px solid var(--line); background: var(--card); cursor: pointer; transition: .2s; color: var(--ink-2); }
.icon-btn:hover { border-color: var(--ink); color: var(--ink); }
.icon { width: 18px; height: 18px; flex: none; }

/* --- En-tête ----------------------------------------------------------- */
.site-header { position: sticky; top: 0; z-index: 40; backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px);
  background: rgba(251, 248, 243, .78); border-bottom: 1px solid transparent; transition: border-color .3s; }
.site-header.scrolled { border-bottom-color: var(--line); }
.nav { height: 72px; display: flex; align-items: center; gap: 28px; }
.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; font-size: 19px; letter-spacing: -.02em; }
.logo-mark { width: 30px; height: 30px; }
.nav-links { display: flex; gap: 24px; margin-left: 8px; }
.nav-links a { text-decoration: none; color: var(--ink-2); font-size: 15px; font-weight: 500; transition: color .2s; }
.nav-links a:hover, .nav-links a.active { color: var(--ink); }
.nav-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.lang-switch { display: inline-flex; align-items: center; background: var(--paper-2); border-radius: 999px; padding: 3px; font-size: 13px; font-weight: 600; }
.lang-switch a { text-decoration: none; padding: 5px 10px; border-radius: 999px; color: var(--muted); transition: .2s; }
.lang-switch a.on { background: var(--card); color: var(--ink); box-shadow: var(--shadow-sm); }
.credits-pill { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 14px; border-radius: 999px; background: var(--accent-soft); color: var(--accent-ink); font-weight: 600; font-size: 14px; text-decoration: none; }
.credits-pill:hover { background: #fadccd; }
.menu-btn { display: none; }
.mobile-menu { display: none; }

/* --- Hero -------------------------------------------------------------- */
.hero { padding: 64px 0 40px; position: relative; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; padding: 6px 14px 6px 6px; border-radius: 999px; background: var(--card); border: 1px solid var(--line); font-size: 13px; font-weight: 500; color: var(--ink-2); box-shadow: var(--shadow-sm); }
.eyebrow .dot { width: 22px; height: 22px; border-radius: 50%; background: var(--accent-soft); display: grid; place-items: center; color: var(--accent); }
.hero h1 { font-family: var(--serif); font-weight: 500; font-size: clamp(42px, 5.3vw, 70px); letter-spacing: -.035em; line-height: 1.0; margin: 22px 0 22px; }
.hero h1 em { color: var(--accent); font-style: italic; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-top: 30px; }
.cta-note { font-size: 13px; color: var(--muted); display: flex; align-items: center; gap: 6px; margin-top: 12px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 34px; }
.chip { display: inline-flex; align-items: center; gap: 7px; padding: 7px 12px; border-radius: 999px; border: 1px solid var(--line); background: rgba(255,255,255,.6); font-size: 13px; color: var(--ink-2); }
.chip svg { color: var(--ok); }

.hero-visual { position: relative; height: 600px; perspective: 1800px; }
.blob { position: absolute; border-radius: 50%; filter: blur(60px); opacity: .55; }
.blob.a { width: 380px; height: 380px; background: #F8C9B4; right: 0; top: 40px; }
.blob.b { width: 300px; height: 300px; background: #DCD0F5; left: 10px; bottom: 30px; }
.book3d { position: absolute; left: 50%; top: 50%; width: 330px; height: 427px; transform-style: preserve-3d;
  transform: translate(-50%, -50%) rotateY(-24deg) rotateX(6deg) rotateZ(1deg); animation: float 7s ease-in-out infinite; }
.book3d .face { position: absolute; inset: 0; border-radius: 4px 12px 12px 4px; overflow: hidden; box-shadow: var(--shadow-lg); background: #fff; }
.book3d .face img { width: 100%; height: 100%; object-fit: cover; }
.book3d .face::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(0,0,0,.18), rgba(255,255,255,.12) 4%, transparent 10%, transparent 85%, rgba(0,0,0,.06)); }
.book3d .pages-edge { position: absolute; top: 6px; bottom: 6px; right: -18px; width: 20px; transform: rotateY(90deg) translateZ(-1px); transform-origin: left;
  background: repeating-linear-gradient(90deg, #fff 0 2px, #ece6dc 2px 3px); border-radius: 2px; }
.float-page { position: absolute; width: 170px; height: 220px; background: #fff; border-radius: 10px; box-shadow: var(--shadow); padding: 12px; border: 1px solid var(--line); }
.float-page img { width: 100%; height: 100%; object-fit: contain; }
.float-page.p1 { left: 0; top: 70px; transform: rotate(-9deg); animation: float 8s ease-in-out infinite reverse; }
.float-page.p2 { right: 6px; bottom: 40px; transform: rotate(8deg); animation: float 9s ease-in-out infinite; }
.float-chip { position: absolute; display: flex; align-items: center; gap: 10px; padding: 10px 14px; background: #fff; border-radius: 14px; box-shadow: var(--shadow); font-size: 13px; font-weight: 600; border: 1px solid var(--line); }
.float-chip.c1 { right: 0; top: 60px; }
.float-chip.c2 { left: 24px; bottom: 80px; }
.float-chip .bar { width: 90px; height: 6px; border-radius: 6px; background: var(--paper-3); overflow: hidden; }
.float-chip .bar i { display: block; height: 100%; width: 30%; background: var(--accent); border-radius: 6px; animation: grow 3.4s var(--ease) infinite; }
.badge-ok { width: 22px; height: 22px; border-radius: 50%; background: var(--ok-soft); color: var(--ok); display: grid; place-items: center; }
@keyframes float { 0%, 100% { translate: 0 0; } 50% { translate: 0 -12px; } }
@keyframes grow { 0% { width: 8%; } 70%, 100% { width: 100%; } }

/* --- Sections ---------------------------------------------------------- */
section { padding: 96px 0; position: relative; }
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 32px; margin-bottom: 48px; flex-wrap: wrap; }
.section-head p { max-width: 44ch; color: var(--ink-2); margin: 0; }
.band { background: var(--paper-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

.deliver-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.d-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 26px; box-shadow: var(--shadow-sm); transition: transform .35s var(--ease), box-shadow .35s; }
.d-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.d-icon { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; margin-bottom: 20px; }
.d-card h3 { font-size: 18px; margin-bottom: 8px; }
.d-card p { margin: 0; color: var(--muted); font-size: 15px; }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; counter-reset: step; }
.step { padding: 28px; border-radius: var(--r-lg); background: var(--card); border: 1px solid var(--line); position: relative; overflow: hidden; }
.step .num { font-family: var(--serif); font-size: 64px; line-height: 1; color: var(--accent); font-style: italic; opacity: .9; }
.step h3 { font-size: 21px; margin: 18px 0 8px; }
.step p { margin: 0; color: var(--muted); }
.step .mini { margin-top: 22px; height: 150px; border-radius: 14px; background: var(--paper); border: 1px dashed var(--line-2); overflow: hidden; position: relative; }

/* mini-maquettes des étapes */
.mini-themes { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 14px; }
.mini-themes span { height: 34px; border-radius: 10px; background: #fff; border: 1px solid var(--line); font-size: 12px; display: flex; align-items: center; padding: 0 10px; font-weight: 500; color: var(--ink-2); }
.mini-themes span.on { border-color: var(--ink); box-shadow: 0 0 0 3px var(--accent-soft); }
.mini-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; padding: 14px; }
.mini-grid img { aspect-ratio: 17/22; object-fit: contain; background: #fff; border-radius: 6px; border: 1px solid var(--line); padding: 3px; }
.mini-grid img:nth-child(2) { outline: 2px solid var(--accent); outline-offset: 2px; }
.mini-files { padding: 16px; display: grid; gap: 8px; }
.mini-files div { display: flex; align-items: center; gap: 10px; height: 36px; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 0 12px; font-size: 13px; font-weight: 500; }
.mini-files b { margin-left: auto; color: var(--ok); font-size: 12px; }

/* --- Feuilletoir (flipbook) ------------------------------------------- */
.flip-wrap { display: grid; grid-template-columns: 1fr; justify-items: center; gap: 20px; }
.flipbook { position: relative; width: min(860px, 100%); aspect-ratio: 17 / 11; perspective: 2600px; user-select: none; touch-action: pan-y; }
.flipbook .spread { position: absolute; inset: 0; display: grid; grid-template-columns: 1fr 1fr; filter: drop-shadow(0 30px 40px rgba(23,21,28,.18)); }
.flipbook .leaf { position: relative; background: #fff; overflow: hidden; display: grid; place-items: center; }
.flipbook .leaf.left { border-radius: 10px 0 0 10px; box-shadow: inset -24px 0 30px -24px rgba(0,0,0,.22); }
.flipbook .leaf.right { border-radius: 0 10px 10px 0; box-shadow: inset 24px 0 30px -24px rgba(0,0,0,.22); }
.flipbook .leaf img { width: 84%; height: 84%; object-fit: contain; cursor: zoom-in; }
.flipbook .leaf .pno { position: absolute; bottom: 10px; font-size: 11px; color: var(--muted); }
.flipbook .leaf.left .pno { left: 16px; } .flipbook .leaf.right .pno { right: 16px; }
.flipbook .leaf .fm { padding: 12%; text-align: center; font-family: var(--serif); }
.flipbook .leaf .fm h4 { font-family: var(--sans); font-size: clamp(16px, 2.4vw, 26px); font-weight: 700; margin-bottom: 10px; letter-spacing: -.02em; }
.flipbook .leaf .fm p { font-style: italic; color: var(--ink-2); font-size: clamp(11px, 1.3vw, 14px); margin: 0; }
.flipbook .leaf.blank::after { content: ""; }
.flipbook .turn { position: absolute; top: 0; bottom: 0; width: 50%; transform-style: preserve-3d; transition: transform .75s cubic-bezier(.45,.05,.2,1); z-index: 3; }
.flipbook .turn.fwd { right: 0; transform-origin: left center; }
.flipbook .turn.back { left: 0; transform-origin: right center; }
.flipbook .turn .side { position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; background: #fff; display: grid; place-items: center; overflow: hidden; }
.flipbook .turn .side img { width: 84%; height: 84%; object-fit: contain; }
.flipbook .turn .side.b { transform: rotateY(180deg); }
.flipbook .turn.fwd .side.a { border-radius: 0 10px 10px 0; } .flipbook .turn.fwd .side.b { border-radius: 10px 0 0 10px; }
.flipbook .turn.back .side.a { border-radius: 10px 0 0 10px; } .flipbook .turn.back .side.b { border-radius: 0 10px 10px 0; }
.flipbook .turn .shade { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(90deg, rgba(0,0,0,.0), rgba(0,0,0,.12)); opacity: 0; transition: opacity .75s; }
.flipbook .turn.go.fwd { transform: rotateY(-180deg); }
.flipbook .turn.go.back { transform: rotateY(180deg); }
.flipbook .gutter { position: absolute; left: 50%; top: 0; bottom: 0; width: 2px; transform: translateX(-1px); background: linear-gradient(180deg, rgba(0,0,0,.06), rgba(0,0,0,.14), rgba(0,0,0,.06)); z-index: 2; pointer-events: none; }
.flipbook.single { aspect-ratio: 17 / 22; width: min(440px, 100%); }
.flipbook.single .spread { grid-template-columns: 1fr; }
.flipbook.single .leaf.left { display: none; }
.flipbook.single .leaf.right { border-radius: 10px; box-shadow: none; }
.flipbook.single .gutter { display: none; }
.flip-controls { display: flex; align-items: center; gap: 14px; }
.flip-controls .counter { min-width: 120px; text-align: center; font-variant-numeric: tabular-nums; font-weight: 600; font-size: 14px; color: var(--ink-2); }
.flip-scrub { width: min(520px, 100%); accent-color: var(--accent); }

/* --- Pourquoi / calcul ---------------------------------------------------- */
.why-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.calc { background: var(--ink); color: var(--paper); border-radius: var(--r-lg); padding: 34px; box-shadow: var(--shadow-lg); position: relative; overflow: hidden; }
.calc::before { content: ""; position: absolute; width: 260px; height: 260px; border-radius: 50%; background: radial-gradient(circle, rgba(228,87,46,.45), transparent 65%); right: -80px; top: -90px; }
.calc .row { display: flex; justify-content: space-between; gap: 16px; padding: 14px 0; border-bottom: 1px dashed rgba(255,255,255,.14); font-size: 15px; position: relative; }
.calc .row:last-of-type { border-bottom: 0; font-size: 20px; font-weight: 700; padding-top: 20px; }
.calc .row:last-of-type b { color: #FFB59C; font-family: var(--serif); font-size: 30px; font-weight: 600; }
.calc .row span { color: rgba(251,248,243,.72); }
.calc .row b { white-space: nowrap; }
.calc .note { margin-top: 18px; font-size: 12.5px; color: rgba(251,248,243,.55); line-height: 1.5; position: relative; }

/* --- Tarifs -------------------------------------------------------------- */
.price-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; align-items: stretch; }
.price { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 30px; display: flex; flex-direction: column; gap: 18px; position: relative; transition: transform .35s var(--ease), box-shadow .35s; }
.price:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.price.featured { background: var(--ink); color: var(--paper); border-color: var(--ink); box-shadow: var(--shadow-lg); }
.price.featured .muted, .price.featured li { color: rgba(251,248,243,.75); }
.price .tag { position: absolute; top: -12px; left: 30px; background: var(--accent); color: #fff; font-size: 12px; font-weight: 700; padding: 5px 12px; border-radius: 999px; letter-spacing: .02em; }
.price h3 { font-size: 15px; text-transform: uppercase; letter-spacing: .08em; font-weight: 700; }
.price .amount { font-family: var(--serif); font-size: 54px; font-weight: 500; letter-spacing: -.03em; line-height: 1; }
.price .amount small { font-family: var(--sans); font-size: 15px; color: var(--muted); font-weight: 500; letter-spacing: 0; margin-left: 4px; }
.price.featured .amount small { color: rgba(251,248,243,.6); }
.price ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; font-size: 15px; color: var(--ink-2); }
.price li { display: flex; gap: 10px; align-items: flex-start; }
.price li svg { color: var(--accent); margin-top: 3px; }
.price .btn { margin-top: auto; }
.price.featured .btn-primary { background: var(--accent); }
.price.featured .btn-primary:hover { background: var(--accent-ink); }

/* --- FAQ ------------------------------------------------------------------ */
.faq { max-width: 820px; margin: 0 auto; }
.faq details { border-bottom: 1px solid var(--line); padding: 4px 0; }
.faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 22px 0; font-size: 18px; font-weight: 600; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary .plus { width: 30px; height: 30px; border-radius: 50%; border: 1px solid var(--line-2); display: grid; place-items: center; flex: none; transition: transform .3s var(--ease), background .3s; }
.faq details[open] summary .plus { transform: rotate(45deg); background: var(--ink); color: var(--paper); border-color: var(--ink); }
.faq details p { margin: 0 0 22px; color: var(--ink-2); max-width: 64ch; }

.final { background: var(--ink); color: var(--paper); border-radius: 32px; padding: 72px 48px; text-align: center; position: relative; overflow: hidden; }
.final h2 { font-family: var(--serif); font-weight: 500; font-size: clamp(32px, 5vw, 58px); max-width: 18ch; margin: 0 auto 28px; }
.final::before, .final::after { content: ""; position: absolute; border-radius: 50%; filter: blur(50px); opacity: .5; }
.final::before { width: 320px; height: 320px; background: var(--accent); left: -120px; top: -120px; }
.final::after { width: 280px; height: 280px; background: #7C5CD6; right: -90px; bottom: -110px; }
.final > * { position: relative; }

.site-footer { padding: 56px 0 40px; border-top: 1px solid var(--line); margin-top: 40px; font-size: 14px; color: var(--muted); }
.footer-grid { display: flex; justify-content: space-between; gap: 32px; flex-wrap: wrap; align-items: flex-start; }
.footer-links { display: flex; gap: 22px; flex-wrap: wrap; }
.footer-links a { text-decoration: none; } .footer-links a:hover { color: var(--ink); }
.footer-note { margin-top: 28px; font-size: 12px; }

/* --- Révélation au défilement --------------------------------------------- */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .8s var(--ease), transform .8s var(--ease); }  /* sans JavaScript : contenu visible */
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .js .reveal { opacity: 1; transform: none; } * { animation: none !important; transition-duration: .01ms !important; } }

/* --- Formulaires ------------------------------------------------------------ */
.field { display: grid; gap: 8px; }
.field label, .label { font-size: 14px; font-weight: 600; color: var(--ink-2); }
.hint { font-size: 13px; color: var(--muted); }
.input, .select, textarea.input { height: 50px; border-radius: 14px; border: 1px solid var(--line-2); background: var(--card); padding: 0 16px; font-size: 16px; transition: border-color .2s, box-shadow .2s; width: 100%; }
textarea.input { height: auto; padding: 14px 16px; resize: vertical; }
.input:focus, .select:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 4px rgba(228,87,46,.14); }
.select { appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none'%3E%3Cpath d='M1 1.5 6 6.5l5-5' stroke='%2317151C' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 16px center; padding-right: 40px; }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; color: var(--ink-2); cursor: pointer; }
.check input { width: 20px; height: 20px; accent-color: var(--accent); margin-top: 1px; flex: none; }
.alert { padding: 14px 16px; border-radius: 14px; font-size: 14px; display: flex; gap: 12px; align-items: flex-start; }
.alert-warn { background: var(--warn-soft); color: #6B4A12; }
.alert-bad { background: var(--bad-soft); color: #7A1C1C; }
.alert-ok { background: var(--ok-soft); color: #1C5537; }
.alert-info { background: var(--lilac); color: #2E2152; }

/* --- Auth ------------------------------------------------------------------ */
.auth-wrap { min-height: calc(100vh - 72px); display: grid; place-items: center; padding: 48px 20px; }
.auth-card { width: min(440px, 100%); background: var(--card); border: 1px solid var(--line); border-radius: 28px; padding: 40px; box-shadow: var(--shadow); }
.auth-card h1 { font-family: var(--serif); font-weight: 500; font-size: 38px; margin-bottom: 10px; }
.auth-card form { display: grid; gap: 16px; margin-top: 26px; }

/* --- Studio ----------------------------------------------------------------- */
.studio-head { padding: 40px 0 28px; display: flex; justify-content: space-between; align-items: end; gap: 20px; flex-wrap: wrap; }
.studio-head h1 { font-family: var(--serif); font-weight: 500; font-size: clamp(32px, 4vw, 46px); }
.books-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 22px; padding-bottom: 40px; }
.book-card { text-decoration: none; background: var(--card); border: 1px solid var(--line); border-radius: 20px; overflow: hidden; display: flex; flex-direction: column; transition: transform .35s var(--ease), box-shadow .35s; }
.book-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.book-card .thumb { aspect-ratio: 17/20; background: var(--paper-2); display: grid; place-items: center; position: relative; overflow: hidden; }
.book-card .thumb img { width: 76%; height: 84%; object-fit: contain; background: #fff; box-shadow: var(--shadow); border-radius: 4px; padding: 8px; }
.book-card .body { padding: 16px 18px 18px; display: grid; gap: 6px; }
.book-card h3 { font-size: 17px; line-height: 1.25; }
.book-card .meta { font-size: 13px; color: var(--muted); display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.status { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; padding: 4px 10px; border-radius: 999px; background: var(--paper-2); color: var(--ink-2); }
.status::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.status.generating { background: var(--lilac); color: #5A3FB0; }
.status.generating::before { animation: pulse 1.2s ease-in-out infinite; }
.status.ready { background: var(--ok-soft); color: var(--ok); }
.status.attention { background: var(--warn-soft); color: var(--warn); }
@keyframes pulse { 50% { opacity: .3; } }
.new-card { border: 1.5px dashed var(--line-2); border-radius: 20px; display: grid; place-items: center; text-align: center; padding: 30px; min-height: 320px; text-decoration: none; color: var(--ink-2); transition: .25s; background: rgba(255,255,255,.4); }
.new-card:hover { border-color: var(--ink); background: var(--card); color: var(--ink); }
.new-card .plus-big { width: 56px; height: 56px; border-radius: 50%; background: var(--ink); color: var(--paper); display: grid; place-items: center; margin: 0 auto 14px; }
.empty { text-align: center; padding: 80px 20px; background: var(--card); border: 1px solid var(--line); border-radius: 28px; }
.empty h2 { font-family: var(--serif); font-weight: 500; font-size: 32px; margin: 18px 0 10px; }

/* --- Assistant -------------------------------------------------------------- */
.wizard { display: grid; grid-template-columns: 1fr 340px; gap: 32px; padding: 32px 0 80px; align-items: start; }
.stepper { display: flex; gap: 6px; margin-bottom: 28px; }
.stepper button { flex: 1; text-align: left; border: 0; background: none; padding: 0; cursor: pointer; color: var(--muted); font-size: 13px; font-weight: 600; }
.stepper button i { display: block; height: 4px; border-radius: 4px; background: var(--paper-3); margin-bottom: 10px; overflow: hidden; position: relative; }
.stepper button i::after { content: ""; position: absolute; inset: 0; background: var(--ink); transform: scaleX(0); transform-origin: left; transition: transform .5s var(--ease); }
.stepper button.done i::after, .stepper button.on i::after { transform: scaleX(1); }
.stepper button.on { color: var(--ink); }
.stepper button span { opacity: .6; margin-right: 4px; }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: 28px; padding: 36px; box-shadow: var(--shadow-sm); }
.panel h2 { font-family: var(--serif); font-weight: 500; font-size: 32px; margin-bottom: 6px; }
.panel .lead { font-size: 16px; margin: 0 0 26px; }
.wstep { display: none; animation: fadeUp .45s var(--ease); }
.wstep.on { display: block; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.preset-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; margin-bottom: 22px; }
.preset { border: 1px solid var(--line-2); background: var(--paper); border-radius: 16px; padding: 14px 16px; text-align: left; cursor: pointer; font-weight: 600; font-size: 15px; transition: .2s; min-height: 64px; display: flex; align-items: center; }
.preset:hover { border-color: var(--ink); background: #fff; }
.preset.on { border-color: var(--ink); background: #fff; box-shadow: 0 0 0 4px var(--accent-soft); }
.style-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.style-card { border: 1px solid var(--line-2); background: var(--paper); border-radius: 18px; padding: 10px; cursor: pointer; text-align: left; transition: .2s; }
.style-card img { aspect-ratio: 17/20; object-fit: contain; background: #fff; border-radius: 10px; width: 100%; padding: 6px; }
.style-card b { display: block; margin: 10px 4px 2px; font-size: 15px; }
.style-card small { display: block; margin: 0 4px 4px; color: var(--muted); font-size: 12.5px; line-height: 1.35; }
.style-card.on, .style-card:hover { border-color: var(--ink); background: #fff; }
.style-card.on { box-shadow: 0 0 0 4px var(--accent-soft); }
.seg { justify-self: start; width: max-content; display: inline-flex; background: var(--paper-2); padding: 4px; border-radius: 14px; gap: 4px; }
.seg button { border: 0; background: none; padding: 10px 18px; border-radius: 10px; cursor: pointer; font-weight: 600; font-size: 14px; color: var(--muted); transition: .2s; }
.seg button.on { background: #fff; color: var(--ink); box-shadow: var(--shadow-sm); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-grid .full { grid-column: 1 / -1; }
.trim-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.trim { border: 1px solid var(--line-2); border-radius: 16px; padding: 14px; cursor: pointer; background: var(--paper); text-align: left; transition: .2s; display: flex; gap: 12px; align-items: center; }
.trim .shape { background: #fff; border: 1.5px solid var(--ink-2); border-radius: 3px; flex: none; }
.trim b { display: block; font-size: 14px; } .trim small { color: var(--muted); font-size: 12px; }
.trim.on { border-color: var(--ink); background: #fff; box-shadow: 0 0 0 4px var(--accent-soft); }
.range { width: 100%; accent-color: var(--accent); height: 28px; }
.range-row { display: flex; align-items: center; gap: 16px; }
.range-row output { font-family: var(--serif); font-size: 34px; min-width: 56px; text-align: right; }
.palettes { display: flex; gap: 10px; flex-wrap: wrap; }
.swatch { width: 46px; height: 46px; border-radius: 14px; border: 2px solid transparent; cursor: pointer; position: relative; box-shadow: inset 0 0 0 1px rgba(0,0,0,.08); transition: transform .2s; }
.swatch i { position: absolute; right: 6px; bottom: 6px; width: 12px; height: 12px; border-radius: 50%; }
.swatch.on { border-color: var(--ink); transform: scale(1.06); }
.wizard-nav { display: flex; justify-content: space-between; align-items: center; margin-top: 34px; gap: 12px; }
.summary { position: sticky; top: 96px; display: grid; gap: 16px; }
.mini-cover { aspect-ratio: 17/22; border-radius: 6px 14px 14px 6px; padding: 22px; display: flex; flex-direction: column; gap: 10px; box-shadow: var(--shadow-lg); position: relative; overflow: hidden; transition: background .4s; }
.mini-cover::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 10px; background: linear-gradient(90deg, rgba(0,0,0,.15), transparent); }
.mini-cover .mc-badge { align-self: flex-start; font-size: 10px; font-weight: 700; padding: 4px 9px; border-radius: 999px; color: #fff; }
.mini-cover .mc-title { font-weight: 800; font-size: 24px; line-height: 1.05; letter-spacing: -.02em; word-break: break-word; }
.mini-cover .mc-sub { font-family: var(--serif); font-style: italic; font-size: 12px; opacity: .85; }
.mini-cover .mc-art { flex: 1; background: #fff; border-radius: 12px; border: 1.5px solid; display: grid; place-items: center; overflow: hidden; }
.mini-cover .mc-art img { width: 82%; height: 82%; object-fit: contain; }
.mini-cover .mc-author { font-size: 11px; font-weight: 600; }
.summary-list { background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 18px 20px; font-size: 14px; display: grid; gap: 10px; }
.summary-list div { display: flex; justify-content: space-between; gap: 12px; }
.summary-list span { color: var(--muted); }
.summary-list b { text-align: right; }

/* --- Éditeur ------------------------------------------------------------------- */
.editor-top { padding: 26px 0 0; }
.crumb { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; color: var(--muted); text-decoration: none; margin-bottom: 14px; }
.crumb:hover { color: var(--ink); }
.editor-title-row { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.title-input { font-family: var(--serif); font-weight: 500; font-size: clamp(28px, 3.6vw, 42px); letter-spacing: -.025em; border: 0; background: transparent; padding: 4px 8px; margin-left: -8px; border-radius: 12px; min-width: 0; flex: 1; transition: background .2s; }
.title-input:hover { background: rgba(255,255,255,.6); }
.title-input:focus { outline: none; background: #fff; box-shadow: 0 0 0 1px var(--line-2); }
.progress-card { margin-top: 18px; background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 18px 20px; display: grid; grid-template-columns: 1fr auto; gap: 8px 20px; align-items: center; }
.progress-card .ptext { font-weight: 600; font-size: 15px; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.progress-card .ptext small { font-weight: 500; color: var(--muted); }
.pbar { grid-column: 1 / -1; height: 8px; border-radius: 8px; background: var(--paper-3); overflow: hidden; }
.pbar i { display: block; height: 100%; background: linear-gradient(90deg, var(--accent), var(--gold)); border-radius: 8px; transition: width .6s var(--ease); position: relative; }
.pbar.live i::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, rgba(255,255,255,.55), transparent); animation: shimmer 1.4s linear infinite; }
@keyframes shimmer { from { transform: translateX(-100%); } to { transform: translateX(100%); } }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin: 26px 0 26px; overflow-x: auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { border: 0; background: none; padding: 14px 16px; font-weight: 600; font-size: 15px; color: var(--muted); cursor: pointer; position: relative; white-space: nowrap; }
.tabs button.on { color: var(--ink); }
.tabs button.on::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: -1px; height: 2px; background: var(--ink); border-radius: 2px; }
.tab { display: none; animation: fadeUp .35s var(--ease); }
.tab.on { display: block; }
.toolbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 18px; flex-wrap: wrap; }
.toolbar .hint { display: flex; align-items: center; gap: 8px; }
.pages-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 18px; padding-bottom: 120px; }
.pcard { position: relative; background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 10px 10px 12px; transition: transform .25s var(--ease), box-shadow .25s, border-color .2s, opacity .2s; cursor: grab; }
.pcard:hover { box-shadow: var(--shadow); border-color: var(--line-2); }
.pcard.dragging { opacity: .35; }
.pcard.drop-before { box-shadow: -4px 0 0 0 var(--accent); }
.pcard.drop-after { box-shadow: 4px 0 0 0 var(--accent); }
.pcard .art { aspect-ratio: 17/22; border-radius: 10px; background: var(--paper); display: grid; place-items: center; overflow: hidden; position: relative; }
.pcard .art img { width: 100%; height: 100%; object-fit: contain; background: #fff; transition: opacity .4s; cursor: zoom-in; }
.pcard .art img.loading { opacity: 0; }
.pcard .foot { display: flex; align-items: center; justify-content: space-between; margin-top: 10px; gap: 6px; }
.pcard .num { font-size: 13px; font-weight: 700; color: var(--ink-2); }
.pcard .acts { display: flex; gap: 4px; }
.pcard .acts .icon-btn { width: 32px; height: 32px; border-radius: 10px; }
.pcard .acts .icon-btn .icon { width: 16px; height: 16px; }
.pcard .state { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; padding: 14px; font-size: 13px; font-weight: 600; color: var(--ink-2); background: var(--paper); }
.pcard .state .sk { position: absolute; inset: 0; background: linear-gradient(110deg, var(--paper) 30%, #fff 50%, var(--paper) 70%); background-size: 220% 100%; animation: sheen 1.6s linear infinite; }
@keyframes sheen { from { background-position: 120% 0; } to { background-position: -120% 0; } }
.pcard .state > div { position: relative; display: grid; gap: 10px; justify-items: center; }
.pcard .state.err { background: var(--bad-soft); color: var(--bad); }
.pcard .state.lock { background: repeating-linear-gradient(135deg, var(--paper) 0 10px, var(--paper-2) 10px 20px); color: var(--muted); font-weight: 500; }
.pcard.busy .art::after { content: ""; position: absolute; inset: 0; background: rgba(251,248,243,.65); backdrop-filter: blur(2px); }
.pcard.busy .art .busy-tag { position: absolute; z-index: 2; display: flex; gap: 8px; align-items: center; background: #fff; padding: 8px 12px; border-radius: 999px; font-size: 12px; font-weight: 600; box-shadow: var(--shadow); }
.pcard .art .warn-tag { position: absolute; z-index: 2; left: 10px; right: 10px; bottom: 10px; display: flex; gap: 6px; align-items: center; background: #FFF6E5; color: #7A4B00; border: 1px solid #F3D9A4; padding: 6px 10px; border-radius: 10px; font-size: 11.5px; font-weight: 600; line-height: 1.3; box-shadow: var(--shadow); }
.spinner { width: 22px; height: 22px; border-radius: 50%; border: 2.5px solid var(--line-2); border-top-color: var(--accent); animation: spin .8s linear infinite; }
.spinner.sm { width: 14px; height: 14px; border-width: 2px; }
@keyframes spin { to { transform: rotate(360deg); } }
.color-wait { position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%); background: #fff; border-radius: 999px; padding: 6px 14px; font-size: 13px; font-weight: 600; box-shadow: var(--shadow); }
.lock-more { grid-column: span 2; border: 1.5px dashed var(--line-2); border-radius: 16px; display: grid; place-items: center; min-height: 240px; background: #fff; padding: 18px; text-align: center; }
.lock-more .lm-in { display: grid; gap: 10px; justify-items: center; color: var(--muted); }
.lock-more .lm-in b { color: var(--ink); font-size: 15px; }
.stall-note { margin-top: 8px; font-size: 13px; color: var(--muted); display: flex; gap: 6px; align-items: flex-start; }
.add-card { border: 1.5px dashed var(--line-2); border-radius: 16px; display: grid; place-items: center; min-height: 240px; cursor: pointer; background: transparent; color: var(--muted); font-weight: 600; transition: .2s; }
.add-card:hover { border-color: var(--ink); color: var(--ink); background: #fff; }
.menu { position: absolute; z-index: 30; background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); padding: 6px; min-width: 230px; display: grid; }
.menu button svg { flex: none; }
.menu button { border: 0; background: none; text-align: left; padding: 10px 12px; border-radius: 10px; cursor: pointer; font-size: 14px; display: flex; gap: 10px; align-items: center; }
.menu button:hover { background: var(--paper-2); }
.menu button.danger { color: var(--bad); }
.menu hr { border: 0; border-top: 1px solid var(--line); margin: 4px 6px; }

.cover-layout { display: grid; grid-template-columns: 1fr 340px; gap: 28px; align-items: start; padding-bottom: 120px; }
.cover-stage { background: var(--paper-2); border: 1px solid var(--line); border-radius: 24px; padding: 28px; display: grid; place-items: center; min-height: 380px; position: relative; }
.cover-stage img { border-radius: 4px; box-shadow: var(--shadow-lg); max-height: 70vh; width: auto; transition: opacity .4s; }
.cover-stage .spinner { position: absolute; }
.side-card { background: var(--card); border: 1px solid var(--line); border-radius: 22px; padding: 22px; display: grid; gap: 18px; }

.export-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; padding-bottom: 120px; align-items: start; }
.checks { display: grid; gap: 2px; }
.check-row { display: flex; align-items: center; gap: 12px; padding: 12px 4px; border-bottom: 1px solid var(--line); font-size: 14.5px; }
.check-row:last-child { border-bottom: 0; }
.check-row .ic { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; flex: none; }
.check-row .ic.ok { background: var(--ok-soft); color: var(--ok); }
.check-row .ic.no { background: var(--warn-soft); color: var(--warn); }
.check-row .val { margin-left: auto; color: var(--muted); font-size: 13px; text-align: right; font-variant-numeric: tabular-nums; }
.files { display: grid; gap: 10px; }
.file-row { display: flex; align-items: center; gap: 14px; padding: 14px; border-radius: 14px; border: 1px solid var(--line); background: var(--paper); text-decoration: none; transition: .2s; font-weight: 600; font-size: 14.5px; }
.file-row:hover { border-color: var(--ink); background: #fff; }
.file-row .fi { width: 38px; height: 38px; border-radius: 10px; background: #fff; border: 1px solid var(--line); display: grid; place-items: center; color: var(--accent); }
.file-row small { display: block; color: var(--muted); font-weight: 500; font-size: 12.5px; }

.unlock-bar { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); z-index: 35; width: min(880px, calc(100% - 24px)); background: var(--ink); color: var(--paper); border-radius: 22px; padding: 14px 14px 14px 22px; display: flex; align-items: center; gap: 18px; box-shadow: var(--shadow-lg); animation: rise .5s var(--ease); }
.unlock-bar b { display: block; font-size: 15px; }
.unlock-bar span { font-size: 13px; color: rgba(251,248,243,.7); }
.unlock-bar .btn { margin-left: auto; }
@keyframes rise { from { transform: translate(-50%, 30px); opacity: 0; } }

.banner { display: flex; gap: 12px; align-items: flex-start; padding: 12px 16px; border-radius: 14px; background: var(--lilac); color: #2E2152; font-size: 13.5px; margin-top: 16px; }

/* --- Visionneuse (zoom) ------------------------------------------------------ */
.lightbox { position: fixed; inset: 0; z-index: 80; background: rgba(18,16,22,.92); display: none; flex-direction: column; color: #fff; }
.lightbox.on { display: flex; animation: fadeIn .25s; }
@keyframes fadeIn { from { opacity: 0; } }
.lb-top { display: flex; align-items: center; gap: 12px; padding: 14px 18px; }
.lb-top .t { font-weight: 600; } .lb-top .s { font-size: 13px; color: rgba(255,255,255,.6); max-width: 60ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lb-top .sp { margin-left: auto; display: flex; gap: 8px; }
.lb-btn { height: 40px; min-width: 40px; padding: 0 12px; border-radius: 12px; background: rgba(255,255,255,.1); border: 0; color: #fff; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: 14px; }
.lb-btn:hover { background: rgba(255,255,255,.18); }
.lb-stage { flex: 1; overflow: hidden; position: relative; touch-action: none; cursor: grab; }
.lb-stage.grabbing { cursor: grabbing; }
.lb-stage.loading::after { content: ""; position: absolute; left: 50%; top: 50%; width: 34px; height: 34px; margin: -17px; border-radius: 50%; border: 3px solid rgba(255,255,255,.2); border-top-color: #fff; animation: spin .8s linear infinite; }
.lb-stage img { transition: opacity .25s; position: absolute; left: 50%; top: 50%; max-width: none; transform-origin: 0 0; background: #fff; border-radius: 4px; user-select: none; -webkit-user-drag: none; }
.lb-nav { position: absolute; top: 50%; transform: translateY(-50%); width: 48px; height: 48px; border-radius: 50%; background: rgba(255,255,255,.12); border: 0; color: #fff; display: grid; place-items: center; cursor: pointer; z-index: 2; }
.lb-nav:hover { background: rgba(255,255,255,.22); }
.lb-nav.prev { left: 16px; } .lb-nav.next { right: 16px; }
.lb-zoom { position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%); display: flex; gap: 6px; background: rgba(0,0,0,.45); padding: 6px; border-radius: 14px; z-index: 2; align-items: center; }
.lb-zoom span { min-width: 56px; text-align: center; font-size: 13px; font-variant-numeric: tabular-nums; }

/* --- Modale & toasts ------------------------------------------------------------ */
.modal { position: fixed; inset: 0; z-index: 70; display: none; place-items: center; padding: 20px; background: rgba(23,21,28,.45); backdrop-filter: blur(4px); }
.modal.on { display: grid; animation: fadeIn .2s; }
.modal-card { width: min(760px, 100%); max-height: calc(100vh - 40px); overflow: auto; background: var(--paper); border-radius: 28px; padding: 32px; box-shadow: var(--shadow-lg); animation: fadeUp .35s var(--ease); }
.modal-card h2 { font-family: var(--serif); font-weight: 500; font-size: 32px; }
.modal-head { display: flex; justify-content: space-between; align-items: start; gap: 16px; margin-bottom: 20px; }
.packs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 18px 0; }
.pack { border: 1px solid var(--line-2); border-radius: 18px; padding: 18px; background: #fff; cursor: pointer; text-align: left; transition: .2s; position: relative; }
.pack.on { border-color: var(--ink); box-shadow: 0 0 0 4px var(--accent-soft); }
.pack b { font-size: 13px; text-transform: uppercase; letter-spacing: .06em; }
.pack .amt { font-family: var(--serif); font-size: 34px; margin: 6px 0 2px; }
.pack small { color: var(--muted); font-size: 13px; }
.pack .tag { position: absolute; top: -10px; right: 12px; background: var(--accent); color: #fff; font-size: 11px; font-weight: 700; padding: 3px 9px; border-radius: 999px; }
.toasts { position: fixed; bottom: 24px; right: 24px; z-index: 90; display: grid; gap: 10px; }
.toast { background: var(--ink); color: var(--paper); padding: 12px 18px; border-radius: 14px; font-size: 14px; box-shadow: var(--shadow); animation: fadeUp .3s var(--ease); max-width: 360px; }
.toast.bad { background: var(--bad); }

.prose { max-width: 760px; margin: 0 auto; padding: 48px 0 40px; }
.prose h1 { font-family: var(--serif); font-weight: 500; font-size: clamp(32px, 4.5vw, 50px); margin-bottom: 18px; }
.prose h2 { font-size: 22px; margin: 40px 0 12px; }
.prose p, .prose li { color: var(--ink-2); font-size: 16.5px; }
.prose .step-box { background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 22px 24px; margin: 18px 0; }
.prose .step-box h3 { font-size: 18px; margin-bottom: 8px; }
.prose code { background: var(--paper-2); padding: 2px 6px; border-radius: 6px; font-size: 14px; }
.placeholder { background: var(--warn-soft); padding: 0 4px; border-radius: 4px; }

/* --- Responsive ----------------------------------------------------------------- */
@media (max-width: 1080px) {
  .deliver-grid { grid-template-columns: 1fr 1fr; }
  .style-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 960px) {
  .hero-grid, .why-grid, .wizard, .cover-layout, .export-layout { grid-template-columns: 1fr; }
  .hero { padding-top: 32px; }
  .hero-visual { height: 470px; margin-top: 10px; }
  .book3d { width: 260px; height: 336px; }
  .float-page { width: 130px; height: 168px; }
  .summary { position: static; grid-template-columns: 180px 1fr; align-items: start; }
  .steps, .price-grid { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  .menu-btn { display: inline-grid; }
  .mobile-menu.on { display: grid; position: absolute; top: 72px; left: 0; right: 0; background: var(--paper); border-bottom: 1px solid var(--line); padding: 12px 24px 20px; gap: 4px; box-shadow: var(--shadow); }
  .mobile-menu a { padding: 12px 0; text-decoration: none; font-weight: 600; border-bottom: 1px solid var(--line); }
  section { padding: 72px 0; }
}
@media (max-width: 640px) {
  .container { padding: 0 18px; }
  .nav { gap: 12px; height: 64px; }
  .nav-right .hide-sm { display: none; }
  .nav-right { gap: 6px; min-width: 0; }
  .nav-right .btn-sm { padding-left: 12px; padding-right: 12px; }
  .lang-switch a { padding: 5px 8px; }
  .logo { min-width: 0; }
  .hero h1 { font-size: 46px; }
  .lead { font-size: 17px; }
  .hero-cta .btn { width: 100%; }
  .hero-visual { height: 400px; }
  .book3d { width: 220px; height: 285px; }
  .float-page { width: 104px; height: 135px; padding: 7px; }
  .float-chip { font-size: 12px; padding: 8px 10px; }
  .float-chip.c1 { top: 8px; right: 0; } .float-chip.c2 { left: 0; bottom: 18px; }
  .deliver-grid { grid-template-columns: 1fr; }
  .panel { padding: 24px 20px; border-radius: 22px; }
  .form-grid, .trim-grid { grid-template-columns: 1fr; }
  .summary { grid-template-columns: 1fr; }
  .summary .mini-cover { max-width: 240px; }
  .packs { grid-template-columns: 1fr; }
  .final { padding: 52px 22px; border-radius: 24px; }
  .pages-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .pcard { padding: 8px 8px 10px; }
  .lb-top .s { display: none; }
  .modal-card { padding: 24px 20px; }
  .auth-card { padding: 28px 22px; }
  .studio-head .btn { width: 100%; }
  .title-input { flex-basis: 100%; font-size: 30px; }
  .editor-title-row { gap: 10px; }
  .unlock-bar { flex-direction: row; align-items: center; padding: 12px 12px 12px 16px; }
  .unlock-bar span { display: none; }
  .unlock-bar b { font-size: 14px; }
  .unlock-bar .btn { margin-left: auto; height: 42px; padding: 0 14px; font-size: 14px; }
  .tabs button { padding: 12px 10px; font-size: 14px; }
  .progress-card { padding: 14px 16px; }
  .toasts { left: 12px; right: 12px; bottom: 12px; }
}
@media (max-width: 400px) {
  .container { padding: 0 16px; }
  .nav { gap: 8px; }
  .nav-right .btn-sm { font-size: 13px; padding-left: 10px; padding-right: 10px; }
  .logo { font-size: 17px; gap: 6px; }
}

/* Assistant sur téléphone (≤ 560 px) : rien ne doit dépasser de l'écran (constaté à 360-432 px le 26/10/2026) */
.wizard > * { min-width: 0; }
@media (max-width: 560px) {
  .stepper { gap: 4px; }
  .stepper button { min-width: 0; font-size: 11px; line-height: 1.25; overflow-wrap: anywhere; }
  .stepper button span { display: block; margin: 0 0 2px; }
  .wizard-nav { flex-wrap: wrap; }
  .wizard-nav #wCreate, .wizard-nav #wNext { flex: 1 1 auto; justify-content: center; }
}


/* --- Accueil (version validée le 27/10/2026) --- */
.home-hero { padding: 56px 0 30px; position: relative; overflow: hidden; }
.home-hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.home-hero-grid > *, .home-why > * { min-width: 0; }
  .home-hero h1 { font-size: clamp(38px, 4.8vw, 62px); }
.home-assure { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 18px; color: var(--ink-2); font-size: 14px; }
.home-assure span { display: inline-flex; gap: 6px; align-items: center; }
.home-assure svg { color: #2F8F5B; }
.home-stage { position: relative; height: 600px; }
.home-phone { position: absolute; left: 50%; top: 0; transform: translateX(-30%); width: 290px; aspect-ratio: 9 / 16; border-radius: 38px;
            background: #17151C; padding: 10px; box-shadow: 0 40px 70px -30px rgba(23,21,28,.55); }
.home-phone video, .home-phone img { width: 100%; height: 100%; object-fit: cover; border-radius: 30px; display: block; background: #fff; }
.home-live { position: absolute; top: -40px; left: 50%; transform: translateX(-50%); background: rgba(23,21,28,.85); color: #fff; font-size: 12px;
           font-weight: 600; padding: 6px 12px; border-radius: 999px; white-space: nowrap; display: inline-flex; gap: 6px; align-items: center; }
.home-live i { width: 8px; height: 8px; border-radius: 50%; background: #E4572E; animation: homepulse 1.4s infinite; }
@keyframes homepulse { 50% { opacity: .3; } }
.home-cover { position: absolute; left: 0; top: 120px; width: 230px; transform: rotate(-6deg); border-radius: 10px; box-shadow: var(--shadow); }
.home-maze { position: absolute; left: 30px; bottom: 10px; width: 170px; transform: rotate(5deg); border-radius: 8px; background: #fff;
           border: 1px solid var(--line); box-shadow: var(--shadow); }
.home-tag { position: absolute; right: 0; bottom: 70px; background: var(--card, #fff); border: 1px solid var(--line); border-radius: 14px;
          padding: 10px 14px; font-size: 13px; font-weight: 600; box-shadow: var(--shadow); }
.home-tag small { display: block; color: var(--muted); font-weight: 500; }
.home-path { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 8px; }
.home-path .s { background: var(--card, #fff); border: 1px solid var(--line); border-radius: 20px; padding: 22px; position: relative; }
.home-path .s .n { font-family: var(--serif, Lora, serif); font-size: 34px; color: var(--accent); }
.home-path .s h3 { margin: 6px 0 6px; font-size: 19px; }
.home-path .s p { margin: 0; color: var(--ink-2); font-size: 15px; }
.home-path .s .free { position: absolute; top: 18px; right: 18px; font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 999px; }
.free.g { background: #DCEFE3; color: #2F8F5B; } .free.p { background: #FCE6DC; color: #C2410C; }
.home-gallery { display: grid; grid-template-columns: 1.2fr repeat(4, 1fr); gap: 14px; align-items: start; }
.home-gallery img { width: 100%; height: auto; border-radius: 10px; border: 1px solid var(--line); background: #fff; display: block; }
.home-gallery figure { margin: 0; } .home-gallery figcaption { font-size: 12px; color: var(--muted); margin-top: 6px; }
.home-gallery .big { grid-row: span 2; }
.home-proof { width: 100%; border-collapse: collapse; font-size: 15px; background: var(--card, #fff); border-radius: 16px; overflow: hidden; }
.home-proof th, .home-proof td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.home-proof th { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); background: var(--paper-2); }
.home-note { font-size: 13px; color: var(--muted); margin-top: 10px; }
.home-why { display: grid; grid-template-columns: 1.2fr .8fr; gap: 32px; align-items: start; }
.home-own { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 18px; }
.home-own div { background: var(--paper-2); border-radius: 14px; padding: 14px; font-size: 14px; }
.home-own b { display: block; margin-bottom: 4px; }
@media (max-width: 900px) {
  .home-hero-grid, .home-why { grid-template-columns: minmax(0, 1fr); }
  .home-stage { height: 520px; }
  .home-path { grid-template-columns: 1fr; }
  .home-gallery { grid-template-columns: repeat(2, 1fr); } .home-gallery .big { grid-column: span 2; grid-row: auto; }
  .home-own { grid-template-columns: 1fr; }
  .home-proof { font-size: 13px; } .home-proof th:nth-child(3), .home-proof td:nth-child(3) { display: none; }
}
@media (max-width: 480px) {
  .home-phone { width: 230px; left: auto; right: 0; transform: none; } .home-cover { width: 170px; top: 90px; } .home-maze { width: 120px; }
  .home-stage { height: 440px; }
}
.home-note-sm { font-size: 13px; color: var(--muted); margin-top: 10px; }
.home-hero .home-note { display: flex; gap: 8px; align-items: flex-start; font-size: 13px; color: var(--muted); margin: 14px 0 0; max-width: 54ch; }
.home-hero .home-note svg { flex: none; margin-top: 2px; }

/* Aperçu gratuit : lien vers l'exemple terminé (nouvel onglet, le livre en cours reste ouvert) */
.unlock-bar .ub-example { margin-left: auto; display: inline-flex; align-items: center; gap: 8px; color: var(--paper); text-decoration: none;
  font-size: 14px; font-weight: 600; padding: 10px 14px; border-radius: 999px; border: 1px solid rgba(251,248,243,.25); white-space: nowrap; }
.unlock-bar .ub-example:hover { background: rgba(251,248,243,.08); }
.unlock-bar .ub-example em { font-style: normal; }
.unlock-bar .ub-example + .btn { margin-left: 0; }
@media (max-width: 560px) { .unlock-bar .ub-example { padding: 0; width: 42px; height: 42px; justify-content: center; } .unlock-bar .ub-example em { display: none; } }
@media (max-width: 560px) {
  .unlock-bar { flex-wrap: wrap; row-gap: 10px; }
  .unlock-bar > div { flex: 1 1 100%; }
  .unlock-bar .ub-example { margin-left: 0; flex: none; }
  .unlock-bar .ub-example + .btn { flex: 1 1 auto; justify-content: center; }
}
.sub-info { margin: 14px 0 0; padding-left: 18px; font-size: 13.5px; line-height: 1.5; color: var(--muted); }
.sub-info li { margin: 0 0 4px; }
.legal-box { border: 2px solid var(--ink); border-radius: 14px; padding: 16px 20px; margin: 16px 0; background: var(--card); }
.legal-box p { margin: 0 0 10px; }
