/* Généré par tools/make-wood-art.py — ne pas modifier à la main.
   Bois massif foncé : textures WebP (public/img), gravures runiques, cadres. CSP : tout est en 'self'. */
:root {
  --wood-body: url("/img/wood-body.webp");
  --wood-beam: url("/img/wood-beam.webp");
  --wood-frame: url("/img/wood-frame.webp");
}
body {
  background: #1a0f08 var(--wood-body); background-size: 1024px 1024px; background-attachment: fixed;
  box-shadow: inset 0 0 160px rgba(0,0,0,.65);
}

/* ── En-tête : poutre de chêne + frise de runes ── */
.site-header { background: var(--wood-beam); background-size: 1024px 100%; border-bottom: 0; position: sticky; box-shadow: 0 6px 18px rgba(0,0,0,.7); }
.site-header::after { content: none; display: block; height: 18px; background: url("/img/frieze.webp") repeat-x left top / 640px 18px; border-top: 1px solid #0c0603; box-shadow: 0 2px 0 #b08d45; }
.brand { text-shadow: 0 -1px 0 rgba(0,0,0,.9), 0 1px 0 rgba(255,220,150,.25); }
.nav a:hover, .linkbtn:hover { background: rgba(0,0,0,.35); }

/* ── Barre d'outils : plaque de bois sombre ── */
.toolbar { background: linear-gradient(rgba(20,11,5,.78), rgba(20,11,5,.9)), var(--wood-frame); background-size: auto, 256px 256px; border: 2px solid #2a170b; box-shadow: inset 0 0 0 1px rgba(212,175,106,.35), 0 4px 12px rgba(0,0,0,.6); }

/* ── Étagères : fond de meuble, tablettes gravées de runes, montants latéraux ── */
.shelves {
  position: relative; border: 0; border-radius: 3px; padding: 0 52px;
  background-color: #150b05;
  background-image:
    linear-gradient(to right, rgba(0,0,0,.6), transparent 6%, transparent 94%, rgba(0,0,0,.6)),
    url("/img/shelf-desk.webp");
  background-size: 100% var(--rowh), 960px calc(var(--rowh) * 4);
  background-repeat: repeat-y, repeat;
  box-shadow: inset 0 14px 30px rgba(0,0,0,.75), 0 10px 28px rgba(0,0,0,.8), 0 0 0 3px #0f0804;
}
.shelves::before, .shelves::after { content: ""; position: absolute; top: 0; bottom: 0; width: 52px; background-repeat: repeat-y; background-position: center top; background-size: 52px 1200px; z-index: 0; pointer-events: none; }
.shelves::before { left: 0; background-image: url("/img/post-left.webp"); box-shadow: inset -6px 0 8px rgba(0,0,0,.6); }
.shelves::after { right: 0; background-image: url("/img/post-right.webp"); box-shadow: inset 6px 0 8px rgba(0,0,0,.6); }
.book { z-index: 1; }

/* ── Panneaux : cadre en bois autour du papier ── */
.card, .entry, .detail {
  border: 10px solid transparent; border-radius: 4px;
  background-image: linear-gradient(var(--paper), var(--paper)), var(--paper-tex), var(--wood-frame);
  background-origin: padding-box, padding-box, border-box; background-clip: padding-box, padding-box, border-box;
  background-size: auto, auto, 256px 256px; background-color: transparent;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.5), 0 8px 20px rgba(0,0,0,.65);
}
.detail { border-width: 12px; }
.btn { border-color: #2a170b; box-shadow: inset 0 1px 0 rgba(255,255,255,.18), 0 2px 4px rgba(0,0,0,.5); }

@media (max-width: 600px) {
  .site-header { position: static; }   /* en-tête + recherche : trop haut pour rester collé sur mobile */
  .shelves { padding: 0 20px; background-image: linear-gradient(to right, rgba(0,0,0,.6), transparent 8%, transparent 92%, rgba(0,0,0,.6)), url("/img/shelf-mobile.webp"); background-size: 100% var(--rowh), 960px calc(var(--rowh) * 4); }
  .shelves::before, .shelves::after { width: 16px; background-image: url("/img/wood-post.webp"); background-size: 16px 200px; }
  .site-header::after { height: 12px; background-size: 427px 12px; }
  .card, .entry, .detail { border-width: 6px; }
  .header-inner { gap: 0 4px; padding: 2px 8px; }
  .brand { flex: 1 1 auto; padding: 4px 0 0; font-size: 1.25rem; }
  .nav { flex: 1 1 auto; order: 1; gap: 0; }
  .linkbtn { order: 2; }
  .site-header .toolbar { order: 4; }
  .nav a, .linkbtn { min-height: 44px; padding: 0 7px; font-size: .98rem; }
}
