/* Carnets à feuilleter et vitrine 3D.
   Papier, toile, élastique : les couleurs des couvertures sont dans oeuvres.js (CARNETS). */
:root {
  --papier: #e8dfc8;
  --papier-ombre: #cfc3a6;
  --encre-papier: #2b2219;
  --tourne: 0.9s;          /* durée d'une page qui tourne */
}

.carnets-intro { max-width: 52ch; color: var(--gris); margin: -0.5rem 0 2.2rem; }

/* ---------- La bibliothèque : étagère + présentoir ---------- */
.bibliotheque { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 56px); align-items: end; }
.meuble { position: relative; padding: 18px 18px 0; border-radius: 4px 4px 0 0;
  background: linear-gradient(180deg, rgba(0,0,0,.35), rgba(0,0,0,.1) 30%, rgba(0,0,0,.4)), linear-gradient(90deg, #22170f, #2d1f14 50%, #22170f);
  box-shadow: inset 0 0 0 10px #3a2819, inset 0 0 0 11px rgba(209,170,94,.18), inset 0 18px 30px rgba(0,0,0,.55), 0 30px 50px rgba(0,0,0,.45); }
.etagere { position: relative; display: flex; align-items: flex-end; gap: 3px; height: clamp(250px, 30vw, 320px); padding: 0 10px 16px; perspective: 900px; }
.etagere::after { /* la planche */
  content: ""; position: absolute; left: -18px; right: -18px; bottom: 0; height: 16px;
  background: linear-gradient(180deg, #5a4129, #3a2819 60%, #22170f); box-shadow: 0 12px 26px rgba(0,0,0,.5); border-top: 1px solid rgba(209,170,94,.28); }

/* carnets de décor */
.dos-deco { flex: none; width: var(--l); height: var(--h); border-radius: 2px 2px 1px 1px;
  background: linear-gradient(90deg, rgba(0,0,0,.35), rgba(255,255,255,.06) 30%, rgba(0,0,0,.12) 70%, rgba(0,0,0,.4)), var(--toile);
  box-shadow: inset 0 10px 0 -6px rgba(209,170,94,.25), inset 0 -14px 0 -10px rgba(209,170,94,.2); }
.dos-deco.penche { transform: rotate(9deg); transform-origin: bottom left; margin-left: 4px; }
.serre-livres { flex: none; width: 10px; height: 34%; margin-left: 18px; border-radius: 2px;
  background: linear-gradient(90deg, #8a6a32, #d1aa5e 40%, #7a5a2c); box-shadow: 0 4px 8px rgba(0,0,0,.4); }

/* les vrais carnets, rangés sur la tranche */
.dos-carnet { --lift: 0px; flex: none; position: relative; width: clamp(46px, 5.4vw, 62px); height: 92%; padding: 0; border: 0; background: none;
  cursor: pointer; color: var(--blanc); transform: translateY(var(--lift)); transition: transform .9s cubic-bezier(.22,.61,.36,1), opacity .6s ease;
  animation: apparaitre .7s var(--d, 0s) ease-out both; }
.dos-carnet:nth-of-type(2) { height: 86%; }
.dos-carnet:nth-of-type(3) { height: 96%; }
.dos-flotte { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 14px 0 12px; border-radius: 3px 3px 2px 2px;
  background:
    repeating-linear-gradient(0deg, rgba(255,255,255,.03) 0 1px, transparent 1px 3px),
    linear-gradient(90deg, rgba(0,0,0,.4), rgba(255,255,255,.1) 28%, rgba(255,255,255,.02) 55%, rgba(0,0,0,.45)),
    var(--toile);
  box-shadow: 0 0 0 1px rgba(0,0,0,.25), 0 10px 18px rgba(0,0,0,.35); transition: box-shadow .9s cubic-bezier(.22,.61,.36,1); }
.dos-coiffe { width: 100%; height: 6px; background: linear-gradient(180deg, rgba(209,170,94,.5), rgba(209,170,94,.15)); }
.dos-coiffe.bas { margin-top: auto; }
.dos-etiquette { width: 72%; padding: 6px 0; background: linear-gradient(180deg, #efe6cf, #d8caa8); box-shadow: 0 1px 3px rgba(0,0,0,.4); text-align: center; }
.dos-etiquette .jp { font-family: var(--f-jp); font-size-adjust: none; font-size: .78rem; color: #7a5a2c; writing-mode: vertical-rl; letter-spacing: .1em; }
.dos-titre { writing-mode: vertical-rl; transform: rotate(180deg); font-family: var(--f-titre); font-size-adjust: none; font-weight: 500; font-size: clamp(.82rem, 1.1vw, 1rem); letter-spacing: .06em;
  white-space: normal; line-height: 1.15; text-align: center; color: #f1e6cc; text-shadow: 0 1px 2px rgba(0,0,0,.5); flex: 1; min-height: 0; margin-bottom: 26px; }
.dos-elastique { position: absolute; left: 0; right: 0; bottom: 30px; height: 7px; background: linear-gradient(180deg, color-mix(in srgb, var(--elastique) 70%, #000 30%), var(--elastique), color-mix(in srgb, var(--elastique) 70%, #000 30%)); box-shadow: 0 2px 3px rgba(0,0,0,.35); }

/* survol : le carnet se soulève tout doucement, puis flotte */
.dos-carnet:hover, .dos-carnet:focus-visible { --lift: -18px; }
.dos-carnet:hover .dos-flotte, .dos-carnet:focus-visible .dos-flotte { animation: flotte 3.6s .5s ease-in-out infinite; box-shadow: 0 0 0 1px rgba(209,170,94,.35), 0 26px 30px rgba(0,0,0,.45), 0 0 26px rgba(209,170,94,.12); }
@keyframes flotte { 0%, 100% { transform: translateY(0) rotate(0deg); } 30% { transform: translateY(-5px) rotate(-.6deg); } 65% { transform: translateY(-2px) rotate(.5deg); } }
.dos-carnet:focus-visible { outline: none; }
.dos-carnet:focus-visible .dos-flotte { outline: 1px solid var(--or); outline-offset: 3px; }
/* sorti de l'étagère : il ne reste que sa place vide */
.dos-carnet.sorti { --lift: -60%; opacity: 0; pointer-events: none; }

/* Le présentoir */
.presentoir { position: relative; min-height: clamp(250px, 30vw, 320px); display: flex; align-items: center; gap: clamp(16px, 3vw, 34px); padding-bottom: 16px; }
.presentoir::after { content: ""; position: absolute; left: 0; width: 46%; bottom: 0; height: 10px; border-radius: 50%;
  background: radial-gradient(ellipse, rgba(209,170,94,.22), transparent 70%); }
.presentoir-vide { margin: 0; width: 100%; display: grid; place-items: center; gap: 10px; text-align: center; color: var(--gris-doux); font-size: .62rem; letter-spacing: .18em; text-transform: uppercase;
  border: 1px dashed rgba(209,170,94,.22); padding: 40px 16px; }
.presentoir-vide .jp { font-family: var(--f-jp); font-size-adjust: none; font-size: 2rem; letter-spacing: 0; color: rgba(209,170,94,.35); }
.presentoir-scene { flex: none; width: 46%; perspective: 1100px; display: flex; justify-content: center; }
.livre3d { --l: clamp(130px, 15vw, 180px); --e: 28px; position: relative; width: var(--l); aspect-ratio: 3 / 4; padding: 0; border: 0; background: none; cursor: pointer;
  transform-style: preserve-3d; transform: rotateY(-24deg) rotateX(4deg); transition: transform 1s cubic-bezier(.22,.61,.36,1); }
.presentoir-scene.arrive .livre3d { animation: devoile 1.25s cubic-bezier(.2,.75,.25,1) both; }
@keyframes devoile {
  0%   { transform: translate3d(-140px, -30px, -80px) rotateY(88deg) rotateX(0deg); opacity: 0; }
  20%  { opacity: 1; }
  100% { transform: rotateY(-24deg) rotateX(4deg); } }
.livre3d:hover, .livre3d:focus-visible { transform: rotateY(-14deg) rotateX(2deg) translateY(-10px); }
.presentoir-scene:hover, .presentoir-scene:focus-within { animation: flotte 3.6s .6s ease-in-out infinite; }
.l3-couv, .l3-dos, .l3-tranche, .l3-haut { position: absolute; }
.l3-couv { inset: 0; border-radius: 2px 8px 8px 2px; transform: translateZ(calc(var(--e) / 2));
  background:
    repeating-linear-gradient(0deg, rgba(255,255,255,.03) 0 1px, transparent 1px 3px),
    repeating-linear-gradient(90deg, rgba(0,0,0,.08) 0 1px, transparent 1px 3px),
    linear-gradient(135deg, color-mix(in srgb, var(--toile) 85%, #fff 15%), var(--toile) 45%, color-mix(in srgb, var(--toile) 70%, #000 30%));
  box-shadow: inset -6px 0 0 rgba(0,0,0,.12), inset 0 0 0 1px rgba(255,255,255,.06), 0 30px 40px rgba(0,0,0,.45); }
.l3-dos { left: 0; top: 0; bottom: 0; width: var(--e); transform-origin: left center; transform: translateZ(calc(var(--e) / 2)) rotateY(-90deg);
  background: linear-gradient(90deg, rgba(0,0,0,.45), rgba(255,255,255,.08), rgba(0,0,0,.3)), var(--toile); border-radius: 3px 0 0 3px; }
.l3-tranche { right: 4px; top: 4px; bottom: 4px; width: calc(var(--e) - 2px); transform-origin: right center; transform: translateZ(calc(var(--e) / 2)) rotateY(90deg);
  background: repeating-linear-gradient(90deg, #e8dfc8 0 2px, #cfc3a6 2px 3px); }
.l3-haut { left: 0; right: 4px; top: 0; height: var(--e); transform-origin: top center; transform: translateZ(calc(var(--e) / 2)) rotateX(-90deg);
  background: repeating-linear-gradient(0deg, #e8dfc8 0 2px, #cfc3a6 2px 3px); }
.carnet-dos { position: absolute; left: 0; top: 0; bottom: 0; width: 14px; background: linear-gradient(90deg, rgba(0,0,0,.35), rgba(0,0,0,.05)); border-radius: 3px 0 0 3px; }
.carnet-elastique { position: absolute; top: 0; bottom: 0; right: 18%; width: 7px; background: linear-gradient(90deg, color-mix(in srgb, var(--elastique) 70%, #000 30%), var(--elastique), color-mix(in srgb, var(--elastique) 70%, #000 30%)); box-shadow: 2px 0 4px rgba(0,0,0,.35); }
.carnet-plaque { position: absolute; left: 20%; right: 30%; top: 18%; padding: 10px 6px; display: flex; flex-direction: column; gap: 4px; text-align: center;
  background: linear-gradient(180deg, #efe6cf, #ddd0b1); color: var(--encre-papier); box-shadow: 0 2px 6px rgba(0,0,0,.35); }
.carnet-plaque .jp { font-family: var(--f-jp); font-size-adjust: none; font-size: .9rem; color: #7a5a2c; }
.carnet-plaque b { font-family: var(--f-titre); font-size-adjust: none; font-weight: 500; font-size: clamp(.78rem, 1.2vw, .95rem); line-height: 1.15; }
.presentoir-info { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; animation: apparaitre .7s .45s ease-out both; }
.presentoir-info .jp { font-family: var(--f-jp); font-size-adjust: none; color: var(--or); letter-spacing: .14em; font-size: .85rem; }
.presentoir-info b { font-family: var(--f-titre); font-size-adjust: none; font-weight: 400; font-size: clamp(1.5rem, 2.6vw, 2.1rem); line-height: 1.05; color: var(--blanc); }
.presentoir-info p { margin: 0; font-size: .8rem; color: var(--gris); line-height: 1.6; max-width: 28ch; }
.presentoir-info small { font-size: .56rem; letter-spacing: .2em; text-transform: uppercase; color: var(--gris-doux); margin-bottom: 8px; }

/* ---------- Le carnet ouvert ---------- */
.table-carnet { margin-top: 34px; outline: none; animation: apparaitre .5s ease-out; }
.carnet-barre { display: flex; align-items: baseline; gap: 18px; flex-wrap: wrap; margin-bottom: 16px; }
.carnet-barre b { font-family: var(--f-titre); font-size-adjust: none; font-weight: 400; font-size: 1.6rem; color: var(--blanc); }
.carnet-compteur { font-size: .62rem; letter-spacing: .18em; text-transform: uppercase; color: var(--or); font-variant-numeric: tabular-nums; }
.carnet-barre .lien { margin-left: auto; background: none; border: 0; border-bottom: 1px solid rgba(246,242,234,.25); color: var(--gris); cursor: pointer; font: inherit; font-size: .62rem; letter-spacing: .14em; text-transform: uppercase; padding: 0 0 3px; }
.livre-cadre { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 14px; align-items: center; }
.carnet-fleche { width: 44px; height: 44px; border: 1px solid var(--or-doux); background: rgba(10, 18, 13, .6); color: var(--creme); cursor: pointer; font-size: 1.1rem; transition: border-color .2s, opacity .2s; }
.carnet-fleche:hover:not(:disabled) { border-color: var(--or); }
.carnet-fleche:disabled { opacity: .25; cursor: default; }
.carnet-astuce { margin-top: 14px; font-size: .62rem; color: var(--gris-doux); text-align: center; }

.livre { position: relative; width: 100%; max-width: min(980px, calc((100vh - 260px) * 1.5)); margin: 0 auto; aspect-ratio: 2 / 1.32; perspective: 2400px; }
.contre-plat { position: absolute; top: -10px; bottom: -10px; width: calc(50% + 10px); background:
    repeating-linear-gradient(90deg, rgba(0,0,0,.08) 0 1px, transparent 1px 3px), var(--toile, #2c4a36);
  box-shadow: 0 24px 40px rgba(0,0,0,.5); }
.contre-plat.gauche { left: -10px; border-radius: 8px 2px 2px 8px; }
.contre-plat.droite { right: -10px; border-radius: 2px 8px 8px 2px; }
.feuillets { position: absolute; inset: 0; }
.feuillet { position: absolute; left: 50%; top: 0; width: 50%; height: 100%; transform-origin: left center; transform-style: preserve-3d;
  transition: transform var(--tourne) cubic-bezier(.45,.05,.25,1); }
.feuillet.tourne { transform: rotateY(-180deg); }
.face { position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; overflow: hidden; cursor: pointer;
  background:
    radial-gradient(ellipse at 30% 20%, rgba(255,255,255,.35), transparent 60%),
    repeating-linear-gradient(0deg, rgba(120,100,60,.035) 0 1px, transparent 1px 4px),
    var(--papier); }
.recto { border-radius: 0 4px 4px 0; box-shadow: inset 14px 0 18px -10px rgba(60,40,20,.45); }
.verso { transform: rotateY(180deg); border-radius: 4px 0 0 4px; box-shadow: inset -14px 0 18px -10px rgba(60,40,20,.45); }
.page { position: absolute; inset: 0; padding: 7% 9% 9%; display: flex; flex-direction: column; color: var(--encre-papier); }

.page-titre { justify-content: center; align-items: center; text-align: center; gap: 10px; }
.page-titre .jp { font-family: var(--f-jp); font-size-adjust: none; font-size: 1.4rem; color: #8a6a3a; letter-spacing: .3em; }
.page-titre h3 { font-family: var(--f-titre); font-size-adjust: none; font-weight: 400; font-style: italic; font-size: clamp(1.4rem, 3.4vw, 2.6rem); line-height: 1.1; }
.page-titre p { font-family: var(--f-titre); font-size-adjust: none; font-size: clamp(.8rem, 1.4vw, 1.05rem); color: #5c4a35; max-width: 26ch; }
.page-titre .signature { margin-top: 18px; font-family: var(--f-titre); font-size-adjust: none; font-style: italic; font-size: .9rem; color: #8a6a3a; }

.page-oeuvre { align-items: center; justify-content: center; gap: 4%; }
.page-dessin { position: relative; flex: 1; min-height: 0; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; display: flex; align-items: center; justify-content: center; }
.page-dessin img { max-width: 100%; max-height: 100%; object-fit: contain; background: #fff; padding: 5px; box-shadow: 0 2px 6px rgba(60,40,20,.25); transform: rotate(-0.6deg); transition: transform .3s; }
.page-dessin:hover img { transform: rotate(0deg) scale(1.02); }
.scotch { position: absolute; width: 22%; height: 7%; background: rgba(226, 214, 176, .72); box-shadow: 0 1px 2px rgba(0,0,0,.08); }
.scotch.haut { top: 2%; left: 39%; transform: rotate(-4deg); }
.scotch.bas { bottom: 2%; right: 12%; transform: rotate(6deg); }
.page-legende { text-align: center; }
.page-legende b { display: block; font-family: var(--f-titre); font-size-adjust: none; font-weight: 500; font-style: italic; font-size: clamp(.85rem, 1.6vw, 1.2rem); line-height: 1.2; }
.page-legende span { font-size: clamp(.45rem, .9vw, .58rem); letter-spacing: .16em; text-transform: uppercase; color: #7a6650; }
.folio { position: absolute; bottom: 4%; font-family: var(--f-titre); font-size-adjust: none; font-size: .8rem; color: #8a7a62; }
.recto .folio { right: 7%; }
.verso .folio { left: 7%; }
.page-fin { justify-content: center; align-items: center; }
.page-fin .jp { font-family: var(--f-jp); font-size-adjust: none; color: #a08a68; letter-spacing: .4em; }

@media (max-width: 700px) {
  .livre-cadre { grid-template-columns: minmax(0, 1fr); }
  .carnet-fleche { display: none; }
  .livre { aspect-ratio: 2 / 1.45; }
  .page { padding: 6% 6% 10%; }
  .folio { font-size: .6rem; }
  .bibliotheque { grid-template-columns: minmax(0, 1fr); }
  .etagere { height: 230px; gap: 2px; padding: 0 4px 16px; }
  .dos-deco:nth-child(n+5):not(.penche) { display: none; }
  .presentoir { min-height: 0; }
  .presentoir-vide { padding: 22px 12px; }
  .presentoir-scene { width: 44%; }
  .livre3d { --l: 120px; --e: 20px; }
  .dos-carnet { width: 44px; }
  .dos-flotte { gap: 6px; padding-top: 10px; }
  .dos-etiquette { display: none; }
  .dos-titre { font-size: .72rem; }
  .presentoir-info .bouton-sceau { padding-inline: 14px; }
}

/* ---------- Vitrine 3D ---------- */
.vitrine-3d { display: grid; grid-template-columns: repeat(2, 1fr); gap: 26px; }
@media (max-width: 640px) { .vitrine-3d { grid-template-columns: 1fr; } }
.o3d { margin: 0; display: flex; flex-direction: column; }
.o3d-socle { position: relative; aspect-ratio: 1; overflow: hidden; border: 1px solid var(--or-doux);
  background: radial-gradient(ellipse 70% 55% at 50% 42%, #2a4433, #14241a 60%, #0b140f); }
.o3d-socle::after { /* ombre au sol */
  content: ""; position: absolute; left: 30%; right: 30%; bottom: 13%; height: 7%; border-radius: 50%;
  background: radial-gradient(ellipse, rgba(0,0,0,.55), transparent 70%); pointer-events: none; animation: o3d-ombre 4.5s ease-in-out infinite; }
@keyframes o3d-ombre { 50% { transform: scaleX(.86); opacity: .7; } }
.o3d-socle canvas { position: relative; z-index: 1; width: 100%; height: 100%; display: block; cursor: grab; touch-action: pan-y; opacity: 0; transition: opacity .8s; }
.o3d-socle.charge canvas { opacity: 1; }
.o3d-socle canvas:active { cursor: grabbing; }
.o3d-bientot { position: absolute; inset: 0; display: grid; place-content: center; gap: 8px; text-align: center; }
.o3d-bientot .jp { font-family: var(--f-jp); font-size-adjust: none; font-size: 2.4rem; color: rgba(209,170,94,.35); }
.o3d-bientot small { font-size: .56rem; letter-spacing: .2em; text-transform: uppercase; color: var(--gris-doux); }
.o3d.vide .o3d-socle::after { display: none; }
.o3d figcaption { padding-top: 14px; display: flex; flex-direction: column; gap: 4px; }
.o3d figcaption div { display: flex; align-items: baseline; gap: 10px; }
.o3d figcaption b { font-family: var(--f-titre); font-size-adjust: none; font-weight: 400; font-size: 1.35rem; color: var(--blanc); }
.o3d figcaption .jp { font-family: var(--f-jp); font-size-adjust: none; color: var(--or); font-size: .8rem; letter-spacing: .12em; }
.o3d figcaption p { font-size: .74rem; color: var(--gris); line-height: 1.6; }
.o3d figcaption small { font-size: .52rem; letter-spacing: .18em; text-transform: uppercase; color: var(--gris-doux); }

@media (prefers-reduced-motion: reduce) {
  .feuillet { transition: none; }
  .carnet { animation: none; }
  .o3d-socle::after { animation: none; }
}

/* Vues de création sous chaque modèle : fil de fer, solide, normales, texturé */
.o3d-vues { position: absolute; z-index: 2; left: 50%; bottom: 12px; transform: translateX(-50%); display: flex;
  border: 1px solid var(--or-doux); background: rgba(10,18,13,.78); backdrop-filter: blur(6px); }
.o3d-vues button { font: inherit; font-size: .54rem; letter-spacing: .14em; text-transform: uppercase; color: var(--gris);
  background: none; border: 0; padding: 8px 10px; cursor: pointer; white-space: nowrap; transition: color .2s, background .2s; }
.o3d-vues button + button { border-left: 1px solid rgba(209,170,94,.18); }
.o3d-vues button:hover { color: var(--blanc); }
.o3d-vues button[aria-pressed="true"] { color: #10180f; background: var(--or); }
.o3d-vues button:focus-visible { outline: 1px solid var(--or); outline-offset: 2px; }
.o3d-stats { position: absolute; z-index: 2; top: 12px; left: 14px; right: 14px; font-size: .5rem; letter-spacing: .16em;
  text-transform: uppercase; color: var(--gris-doux); opacity: 0; transition: opacity .3s; font-variant-numeric: tabular-nums; }
.o3d-socle:not([data-vue="texture"]) .o3d-stats { opacity: 1; }
@media (max-width: 420px) { .o3d-vues button { padding: 7px 7px; letter-spacing: .08em; } }

/* Voir un objet 3D en grand */
.o3d-agrandir { position: absolute; z-index: 2; top: 8px; right: 8px; width: 34px; height: 34px; display: grid; place-items: center; padding: 0;
  color: var(--or); background: rgba(10,18,13,.7); border: 1px solid var(--or-doux); cursor: zoom-in; transition: color .2s, background .2s, transform .2s; }
.o3d-agrandir svg { width: 16px; height: 16px; }
.o3d-agrandir:hover { color: #10180f; background: var(--or); transform: scale(1.06); }
.o3d-agrandir:focus-visible { outline: 1px solid var(--or); outline-offset: 2px; }
.o3d-stats { right: 52px; }
html.o3d-bloque { overflow: hidden; }
.o3d-modale { position: fixed; inset: 0; z-index: 400; display: flex; flex-direction: column; gap: 12px; padding: clamp(12px, 3vw, 36px);
  background: rgba(6,11,8,.9); backdrop-filter: blur(8px); animation: o3d-entre .35s ease-out; }
.o3d-modale[hidden] { display: none; }
@keyframes o3d-entre { from { opacity: 0; } }
.o3d-modale-tete, .o3d-modale-pied { display: flex; align-items: center; justify-content: space-between; gap: 16px; max-width: 1400px; width: 100%; margin: 0 auto; }
.o3d-modale-tete div { display: flex; align-items: baseline; gap: 12px; }
.o3d-modale-tete b { font-family: var(--f-titre); font-size-adjust: none; font-weight: 400; font-size: clamp(1.4rem, 3vw, 2rem); color: var(--blanc); }
.o3d-modale-tete .jp { font-family: var(--f-jp); font-size-adjust: none; color: var(--or); letter-spacing: .12em; }
.o3d-fermer { width: 42px; height: 42px; font-size: 1.6rem; line-height: 1; color: var(--or); background: none; border: 1px solid var(--or-doux); cursor: pointer; }
.o3d-fermer:hover { background: var(--or); color: #10180f; }
.o3d-modale-scene { flex: 1; min-height: 0; max-width: 1400px; width: 100%; margin: 0 auto; display: flex; }
.o3d-modale-scene .o3d-socle { flex: 1; aspect-ratio: auto; animation: o3d-zoom .4s cubic-bezier(.2,.8,.3,1); }
@keyframes o3d-zoom { from { transform: scale(.94); opacity: 0; } }
.o3d-modale .o3d-socle canvas { cursor: grab; touch-action: none; }
.o3d-modale .o3d-agrandir { display: none; }
.o3d-modale .o3d-stats { opacity: 1; font-size: .56rem; }
.o3d-modale .o3d-vues button { font-size: .62rem; padding: 10px 14px; }
.o3d-aide { font-size: .58rem; letter-spacing: .16em; text-transform: uppercase; color: var(--gris-doux); }
.o3d-zoom { display: flex; border: 1px solid var(--or-doux); }
.o3d-zoom button { width: 40px; height: 36px; font-size: 1.2rem; color: var(--or); background: rgba(10,18,13,.7); border: 0; cursor: pointer; }
.o3d-zoom button + button { border-left: 1px solid var(--or-doux); }
.o3d-zoom button:hover { background: var(--or); color: #10180f; }
@media (max-width: 640px) { .o3d-aide { font-size: .5rem; letter-spacing: .08em; } }
@media (prefers-reduced-motion: reduce) { .dos-carnet, .dos-carnet .dos-flotte, .livre3d, .livre3d .l3-couv, .presentoir-scene .livre3d { animation: none !important; transition: none; }
  .o3d-modale, .o3d-modale-scene .o3d-socle { animation: none; } }

/* Petite barre de zoom sur le côté de chaque objet (vitrine) */
.o3d-glissiere { position: absolute; z-index: 2; right: 12px; top: 56px; bottom: 64px; width: 22px; display: flex; flex-direction: column; align-items: center; gap: 6px;
  font-size: .8rem; line-height: 1; color: var(--or); opacity: .55; transition: opacity .3s; }
.o3d-socle:hover .o3d-glissiere, .o3d-glissiere:focus-within { opacity: 1; }
.o3d-glissiere input { flex: 1; min-height: 0; width: 22px; margin: 0; writing-mode: vertical-lr; -webkit-appearance: none; appearance: none; background: none; cursor: ns-resize; }
.o3d-glissiere input::-webkit-slider-runnable-track { width: 2px; background: linear-gradient(var(--or-doux), var(--or-doux)) center / 2px 100% no-repeat; }
.o3d-glissiere input::-moz-range-track { width: 2px; background: var(--or-doux); }
.o3d-glissiere input::-webkit-slider-thumb { -webkit-appearance: none; width: 12px; height: 12px; margin-left: -5px; border-radius: 50%; background: var(--or); border: 2px solid #10180f; box-shadow: 0 0 0 1px var(--or); }
.o3d-glissiere input::-moz-range-thumb { width: 10px; height: 10px; border-radius: 50%; background: var(--or); border: 2px solid #10180f; }
.o3d-glissiere input:focus-visible { outline: 1px solid var(--or); outline-offset: 2px; }
.o3d-modale .o3d-glissiere { display: none; }
