/* Mopypop — feuille de style application */
:root {
  --navy: #0B1F3A;
  --navy-soft: #16304F;
  --ink: #12161C;
  --muted: #6B7280;
  --line: #E4E7EC;
  --bg: #FFFFFF;
  --bg-tint: #F5F7FA;
  --accent: #F0A62A;
  --accent-soft: #FDF3E2;
  --ok: #1B7F5A;
  --ok-soft: #E7F5EE;
  --warn: #B45309;
  --warn-soft: #FDF1DF;
  --danger: #B42318;
  --danger-soft: #FDECEA;
  --radius: 20px;
  --radius-sm: 14px;
  --shadow: 0 4px 16px rgba(11, 31, 58, .07);
  --tabbar-h: 78px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; padding: 0; max-width: 100%; overflow-x: hidden; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--ink);
  font-size: 15px;
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
}
img { max-width: 100%; height: auto; object-fit: cover; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { margin: 0; line-height: 1.15; letter-spacing: -.02em; }
p { margin: 0 0 10px; }
button, input, select, textarea { font: inherit; color: inherit; }
.ic { flex: none; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* ---------- logos de marque ---------- */
.brand-logo, .sidebar-logo, .foot-logo, .admin-top-logo, .drawer-logo { border-radius: 0 !important; }
.brand-logo { width: min(168px, 56vw); height: auto; }
.sidebar-logo { width: 156px; height: auto; }
.foot-logo { width: 142px; height: auto; }
.admin-top-logo { width: 128px; height: auto; flex: none; }
/* logos un peu plus grands sur grand ecran (ordinateur), en restant discrets */
@media (min-width: 900px) {
  .brand-logo { width: min(230px, 26vw); }
  .sidebar-logo { width: 176px; }
  .foot-logo { width: 158px; }
  .admin-top-logo { width: 168px; }
}
@media (min-width: 1400px) {
  .brand-logo { width: min(250px, 22vw); }
}

/* ---------- ecran d ouverture ---------- */
#app-splash {
  display: none; position: fixed; inset: 0; z-index: 99999; pointer-events: none;
  flex-direction: column; align-items: center; justify-content: center; gap: 14px;
  background: var(--navy); color: #fff; font-weight: 700; letter-spacing: .04em;
}
#app-splash img { width: min(330px, 70vw); height: auto; border-radius: 0; }
#app-splash.show { display: flex; animation: splashOut .4s ease 1.2s forwards; }
@keyframes splashOut { to { opacity: 0; visibility: hidden; } }

/* ---------- bouton menu + tiroir ---------- */
.menu-btn {
  position: fixed; top: calc(8px + env(safe-area-inset-top, 0px)); left: 12px; z-index: 60;
  width: 44px; height: 44px; display: flex; align-items: center; justify-content: center;
  background: transparent; border: 0; color: var(--navy); cursor: pointer;
}
.drawer-scrim {
  position: fixed; inset: 0; background: rgba(11, 31, 58, .45); z-index: 90;
  opacity: 0; visibility: hidden; transition: opacity .25s ease, visibility .25s ease;
}
.drawer-scrim.open { opacity: 1; visibility: visible; }
.drawer {
  position: fixed; top: 0; bottom: 0; left: 0; width: 82%; max-width: 320px; z-index: 95;
  background: #fff; border-radius: 0 24px 24px 0; padding: 18px 16px calc(20px + env(safe-area-inset-bottom, 0px));
  display: flex; flex-direction: column; transform: translateX(-100%); visibility: hidden; pointer-events: none;
  transition: transform .28s ease, visibility .28s ease; box-shadow: 0 20px 50px rgba(11, 31, 58, .2);
  padding-top: calc(18px + env(safe-area-inset-top, 0px));
}
.drawer.open { transform: translateX(0); visibility: visible; pointer-events: auto; }
.drawer-head { display: flex; align-items: center; gap: 12px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.drawer-head img { border-radius: 12px; }
.drawer-head strong { display: block; font-size: 17px; }
.drawer-head span { font-size: 12px; color: var(--muted); }
.drawer-close { margin-left: auto; background: none; border: 0; color: var(--muted); width: 36px; height: 36px; cursor: pointer; }
.drawer-nav { display: flex; flex-direction: column; gap: 2px; padding: 14px 0; overflow-y: auto; flex: 1; }
.drawer-link { display: flex; align-items: center; gap: 12px; padding: 12px 6px; font-size: 15px; color: var(--ink); border-radius: 12px; }
.drawer-link:active { background: var(--bg-tint); }
.drawer-foot { border-top: 1px solid var(--line); padding-top: 14px; display: flex; flex-direction: column; gap: 8px; }
.drawer-user { font-size: 14px; margin: 0 0 6px; }
.drawer-user small { color: var(--muted); font-size: 12px; }

/* ---------- conteneur ---------- */
.page { padding: 0 18px 40px; }
.page-title { font-size: 34px; font-weight: 800; margin: 0 0 6px; padding-top: calc(56px + env(safe-area-inset-top, 0px)); }
.page-sub { color: var(--muted); font-size: 14px; margin: 0 0 20px; }
.brand-row { display: flex; align-items: center; gap: 12px; padding-top: calc(60px + env(safe-area-inset-top, 0px)); margin-bottom: 18px; }
.brand-row img { border-radius: 12px; }
.brand-name { font-size: 40px; font-weight: 800; line-height: 1.05; }
.brand-sub { font-size: 13px; color: var(--muted); margin: 2px 0 0; }
.notice-line { display: inline-flex; align-items: center; gap: 8px; background: var(--accent-soft); color: var(--warn); font-size: 13px; padding: 8px 12px; border-radius: 999px; margin-bottom: 16px; }

/* ---------- cartes ---------- */
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; margin-bottom: 16px; box-shadow: var(--shadow); }
.card.soft { background: var(--bg-tint); box-shadow: none; border-color: transparent; }
.card-title { font-size: 20px; font-weight: 700; margin-bottom: 14px; }
.card-sub { font-size: 16px; font-weight: 700; margin-bottom: 8px; }
.muted { color: var(--muted); font-size: 13px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin: 28px 0 14px; }
.section-head h2 { font-size: 24px; font-weight: 800; }
.section-head a { font-size: 13px; color: var(--muted); }
.section-title { font-size: 24px; font-weight: 800; margin: 28px 0 14px; }

/* ---------- boutons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 50px; padding: 0 20px; border-radius: 999px; border: 1px solid transparent; font-weight: 600; font-size: 15px; cursor: pointer; transition: transform .12s ease, opacity .12s ease, background .2s ease; }
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--navy); color: #fff; }
.btn-primary:hover { background: var(--navy-soft); }
.btn-accent { background: var(--accent); color: #24170A; }
.btn-ghost { background: #fff; border-color: var(--line); color: var(--navy); }
.btn-danger { background: var(--danger-soft); color: var(--danger); }
.btn-block { width: 100%; }
.btn-sm { height: 38px; padding: 0 14px; font-size: 13px; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }

/* ---------- formulaires ---------- */
.form label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 12px; color: var(--navy); }
.form input, .form select, .form textarea { width: 100%; margin-top: 6px; padding: 13px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: #fff; font-size: 15px; font-weight: 400; }
.form input:focus, .form select:focus, .form textarea:focus { outline: 2px solid var(--navy); outline-offset: 1px; border-color: var(--navy); }
.form-row { display: grid; gap: 10px; }
.form-error { background: var(--danger-soft); color: var(--danger); border-radius: var(--radius-sm); padding: 10px 12px; font-size: 13px; margin: 4px 0 12px; }
.form-alt { font-size: 13px; color: var(--muted); text-align: center; margin: 14px 0 0; }
.form-alt a { color: var(--navy); font-weight: 600; }
.auth-wrap { max-width: 460px; margin: 0 auto; }
.check-grid { display: grid; grid-template-columns: 1fr; gap: 8px; margin: 4px 0 14px; }
.check-item { display: flex; align-items: center; gap: 10px; font-size: 14px; background: var(--bg-tint); border-radius: 12px; padding: 10px 12px; }
.check-item input { width: 18px; height: 18px; margin: 0; }

/* ---------- hero galerie ---------- */
.hero { margin: 0 -18px 22px; position: relative; }
.hero-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.hero-track::-webkit-scrollbar { display: none; }
.hero-slide { flex: 0 0 100%; scroll-snap-align: center; position: relative; overflow: hidden; }
.hero-slide img { width: 100%; height: min(66vh, 520px); object-fit: cover; animation: heroZoom 6s ease forwards; }
.hero-slide:not(.active) img { opacity: .7; animation: none; }
@keyframes heroZoom { from { transform: scale(1.08); } to { transform: scale(1); } }
.hero-caption { position: absolute; left: 0; right: 0; bottom: 0; padding: 60px 22px 20px; color: #fff; background: linear-gradient(to top, rgba(6, 14, 26, .82), rgba(6, 14, 26, 0)); pointer-events: none; }
.hero-caption h2 { font-size: 28px; font-weight: 800; }
.hero-caption p { font-size: 14px; opacity: .92; margin: 6px 0 0; }
.hero-dots { position: absolute; top: 16px; left: 22px; display: flex; gap: 6px; }
.hero-dots i { width: 8px; height: 8px; border-radius: 99px; background: rgba(255, 255, 255, .55); display: block; transition: width .3s ease, background .3s ease; }
.hero-dots i.on { width: 22px; background: #fff; }
.hero-cta { padding: 0 18px; margin-top: 14px; }
.hero-cta .btn { width: 100%; }

/* ---------- pages qui se tournent ---------- */
.band { margin-bottom: 30px; }
.book-wrap { position: relative; }
.book { position: relative; perspective: 1600px; height: 320px; overflow: hidden; touch-action: pan-y; }
.book-page { position: absolute; inset: 0; transform-origin: left center; transform-style: preserve-3d; will-change: transform; }
.book-face, .book-back { position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; border-radius: var(--radius); overflow: hidden; background: #fff; border: 1px solid var(--line); }
.book-back { transform: rotateY(180deg); background: #EFF1F5; }
.book-face img { width: 100%; height: 200px; object-fit: cover; }
.book-body { padding: 12px 14px; }
.book-body strong { display: block; font-size: 16px; }
.book-body span { display: block; font-size: 12px; color: var(--muted); margin: 2px 0 8px; }
.book-price-row { display: flex; align-items: center; justify-content: space-between; }
.book-price { font-weight: 800; font-size: 17px; }
.book-add { width: 38px; height: 38px; border-radius: 999px; border: 1px solid var(--line); background: #fff; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.book-shadow { position: absolute; inset: 0; pointer-events: none; opacity: 0; background: linear-gradient(to right, rgba(11, 31, 58, .35), rgba(11, 31, 58, 0)); border-radius: var(--radius); }
.band-nav { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 12px; }
.band-nav button { width: 38px; height: 38px; border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--navy); display: flex; align-items: center; justify-content: center; cursor: pointer; }
.band-nav button:disabled { opacity: .4; }
.band-count { font-size: 13px; color: var(--muted); min-width: 52px; text-align: center; }
.band-hint { display: flex; align-items: center; justify-content: center; gap: 8px; color: var(--muted); font-size: 12px; margin-top: 6px; }

/* ---------- grilles produits ---------- */
.cat-strip { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 4px 0 14px; }
.cat-strip::-webkit-scrollbar { display: none; }
.chip { flex: none; padding: 9px 14px; border-radius: 999px; border: 1px solid var(--line); background: #fff; font-size: 13px; font-weight: 600; color: var(--navy); white-space: nowrap; }
.chip.on { background: var(--navy); color: #fff; border-color: var(--navy); }
.grid-products { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 12px; }
.prod-card { border: 1px solid var(--line); border-radius: 16px; overflow: hidden; background: #fff; display: flex; flex-direction: column; }
.prod-card img { width: 100%; aspect-ratio: 1; object-fit: cover; }
.prod-body { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.prod-body strong { font-size: 15px; }
.prod-body .cat { font-size: 11px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.prod-body .desc { font-size: 12px; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.prod-foot { display: flex; align-items: center; justify-content: space-between; margin-top: auto; padding-top: 8px; }
.price { font-weight: 800; font-size: 16px; }
.list-rows { display: flex; flex-direction: column; gap: 10px; }

/* ---------- boutiques ---------- */
.shop-card { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: #fff; margin-bottom: 14px; }
.shop-card img.cover { width: 100%; height: 160px; object-fit: cover; }
.shop-overlay { padding: 14px 16px 16px; }
.shop-overlay h3 { font-size: 18px; font-weight: 800; }
.shop-meta { font-size: 12px; color: var(--muted); display: flex; gap: 8px; flex-wrap: wrap; margin: 6px 0 10px; }
.tag { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; padding: 4px 9px; border-radius: 999px; background: var(--bg-tint); color: var(--navy); }
.tag.official { background: var(--navy); color: #fff; }
.tag.pro { background: var(--accent-soft); color: var(--warn); }
.tag.locked { background: var(--warn-soft); color: var(--warn); }
.tag.ok { background: var(--ok-soft); color: var(--ok); }
.tag.danger { background: var(--danger-soft); color: var(--danger); }

/* ---------- personnalisation ---------- */
.photo-strip { display: flex; gap: 10px; overflow-x: auto; scrollbar-width: none; padding: 4px 0 10px; }
.photo-strip::-webkit-scrollbar { display: none; }
.photo-thumb { flex: none; width: 68px; height: 68px; border-radius: 12px; overflow: hidden; border: 2px solid transparent; background: var(--bg-tint); cursor: pointer; padding: 0; }
.photo-thumb img { width: 100%; height: 100%; object-fit: cover; }
.photo-thumb.on { border-color: var(--navy); }
.preview { position: relative; border-radius: var(--radius); overflow: hidden; background: var(--bg-tint); margin-bottom: 14px; }
.preview img.base { width: 100%; height: 300px; object-fit: cover; }
.preview .overlay-photo { position: absolute; top: var(--py, 50%); left: var(--px, 50%); width: var(--pw, 34%); transform: translate(-50%, -50%) scale(var(--ps, 1)); border-radius: 6px; box-shadow: 0 6px 18px rgba(0, 0, 0, .35); border: 4px solid rgba(255, 255, 255, .85); }
.mock-note { font-size: 12px; color: var(--muted); margin: 0 0 14px; }
.variant-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 14px; }
.variant { display: flex; align-items: center; justify-content: space-between; gap: 10px; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px 14px; background: #fff; cursor: pointer; }
.variant.on { border-color: var(--navy); box-shadow: inset 0 0 0 1px var(--navy); }
.variant small { display: block; color: var(--muted); font-size: 12px; }
.sticky-actions { position: fixed; left: 12px; right: 12px; bottom: calc(var(--tabbar-h) + 16px + env(safe-area-inset-bottom, 0px)); z-index: 40; display: flex; gap: 10px; align-items: center; background: rgba(255, 255, 255, .96); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border: 1px solid var(--line); border-radius: 999px; padding: 8px 10px; box-shadow: 0 10px 26px rgba(11, 31, 58, .14); }
.sticky-actions .price { font-size: 18px; }

/* ---------- panier / commande ---------- */
.cart-line { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; border-bottom: 1px solid var(--line); }
.cart-line:last-child { border-bottom: 0; }
.cart-line img { width: 74px; height: 74px; border-radius: 12px; object-fit: cover; flex: none; }
.cart-line .info { flex: 1; min-width: 0; }
.cart-line .info strong { font-size: 15px; display: block; }
.qty { display: inline-flex; align-items: center; gap: 8px; margin-top: 8px; }
.qty button { width: 32px; height: 32px; border-radius: 999px; border: 1px solid var(--line); background: #fff; cursor: pointer; }
.qty span { min-width: 22px; text-align: center; font-weight: 600; }
.summary-row { display: flex; justify-content: space-between; font-size: 14px; padding: 6px 0; }
.summary-row.total { font-weight: 800; font-size: 18px; padding-top: 10px; border-top: 1px solid var(--line); margin-top: 8px; }
.steps { display: flex; gap: 8px; align-items: center; font-size: 12px; color: var(--muted); margin-bottom: 16px; flex-wrap: wrap; }
.steps b { color: var(--navy); }
.timeline { list-style: none; padding: 0; margin: 0; }
.timeline li { position: relative; padding: 0 0 16px 26px; border-left: 2px solid var(--line); margin-left: 6px; }
.timeline li:last-child { border-left-color: transparent; padding-bottom: 0; }
.timeline li::before { content: ""; position: absolute; left: -7px; top: 2px; width: 12px; height: 12px; border-radius: 99px; background: var(--line); }
.timeline li.done::before { background: var(--ok); }
.timeline li.current::before { background: var(--accent); }
.timeline b { font-size: 14px; }
.timeline span { display: block; font-size: 12px; color: var(--muted); }

/* ---------- divers ---------- */
.empty { text-align: center; padding: 34px 18px; color: var(--muted); border: 1px dashed var(--line); border-radius: var(--radius); }
.tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.tile { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.tile span { font-size: 12px; color: var(--muted); display: block; }
.tile b { font-size: 24px; font-weight: 800; }
.notice { border-radius: var(--radius-sm); padding: 12px 14px; font-size: 13px; margin-bottom: 14px; }
.notice.info { background: var(--bg-tint); color: var(--navy); }
.notice.warn { background: var(--warn-soft); color: var(--warn); }
.notice.ok { background: var(--ok-soft); color: var(--ok); }
.notice.danger { background: var(--danger-soft); color: var(--danger); }
.toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(var(--tabbar-h) + 26px); background: var(--navy); color: #fff; padding: 12px 18px; border-radius: 999px; font-size: 14px; z-index: 200; box-shadow: 0 10px 30px rgba(11, 31, 58, .3); }
.modal { position: fixed; inset: 0; background: rgba(11, 31, 58, .5); z-index: 300; display: flex; align-items: center; justify-content: center; padding: 20px; }
.modal-card { background: #fff; border-radius: var(--radius); padding: 22px; max-width: 420px; width: 100%; position: relative; }
.modal-card h3 { font-size: 20px; margin-bottom: 10px; }
.modal-close { position: absolute; top: 10px; right: 10px; background: none; border: 0; color: var(--muted); cursor: pointer; }
.modal-icons { display: flex; gap: 10px; margin: 14px 0 18px; }
.brand-badge { display: inline-flex; align-items: center; gap: 8px; background: var(--bg-tint); border-radius: 999px; padding: 8px 14px; font-size: 13px; font-weight: 600; }
.tabs { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin-bottom: 16px; }
.tabs::-webkit-scrollbar { display: none; }
.tab-btn { flex: none; padding: 10px 14px; border-radius: 999px; border: 1px solid var(--line); background: #fff; font-size: 13px; font-weight: 600; cursor: pointer; }
.tab-btn.on { background: var(--navy); color: #fff; border-color: var(--navy); }
.kv { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; padding: 7px 0; border-bottom: 1px dashed var(--line); }
.kv:last-child { border-bottom: 0; }
.kv span { color: var(--muted); }

/* ---------- footer ---------- */
.site-foot { background: var(--bg-tint); border-radius: 24px 24px 0 0; padding: 28px 20px calc(var(--tabbar-h) + 28px); margin-top: 34px; }
.foot-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.foot-brand img { border-radius: 10px; }
.foot-tag { font-size: 13px; color: var(--muted); max-width: 520px; }
.foot-info { list-style: none; padding: 0; margin: 14px 0; display: flex; flex-direction: column; gap: 8px; }
.foot-info li { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--navy); }
.foot-social { display: flex; gap: 10px; margin-bottom: 14px; }
.foot-social a { width: 38px; height: 38px; border-radius: 999px; border: 1px solid var(--line); display: flex; align-items: center; justify-content: center; color: var(--navy); background: #fff; }
.foot-links { display: flex; flex-wrap: wrap; gap: 8px 16px; font-size: 13px; margin-bottom: 14px; }
.foot-links .foot-admin { font-size: 12px; color: var(--muted); }
.foot-copy { font-size: 12px; color: var(--muted); margin: 0; }

/* ---------- barre du bas ---------- */
.tabbar {
  position: fixed; left: 12px; right: 12px; bottom: calc(10px + env(safe-area-inset-bottom, 0px)); z-index: 70;
  display: flex; justify-content: space-around; align-items: center; height: 62px;
  background: rgba(255, 255, 255, .88); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--line); border-radius: 28px; box-shadow: 0 10px 26px rgba(11, 31, 58, .14);
}
.tab { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; color: var(--muted); font-size: 11px; padding: 6px 2px; border-radius: 20px; transition: transform .12s ease; }
.tab:active { transform: scale(.96); }
.tab.active { color: var(--navy); }
.tab.active .tab-ic { background: var(--navy); color: #fff; }
.tab-ic { position: relative; display: flex; align-items: center; justify-content: center; width: 38px; height: 30px; border-radius: 999px; }
.tab-lb { font-weight: 600; }
.badge { position: absolute; top: -4px; right: -2px; background: var(--accent); color: #24170A; font-size: 10px; font-weight: 800; border-radius: 999px; padding: 2px 5px; font-style: normal; }

/* ---------- vue ordinateur ---------- */
.sidebar { display: none; }
@media (min-width: 900px) {
  .menu-btn, .drawer, .drawer-scrim, .tabbar { display: none !important; }
  body.app-body { padding-left: 260px; }
  .sidebar { display: flex; flex-direction: column; position: fixed; top: 0; bottom: 0; left: 0; width: 260px; background: #fff; border-right: 1px solid var(--line); padding: 22px 16px; z-index: 50; }
  .sidebar-brand { display: flex; align-items: center; gap: 10px; font-size: 18px; font-weight: 800; margin-bottom: 22px; }
  .sidebar-brand img { border-radius: 10px; }
  .sidebar-links { display: flex; flex-direction: column; gap: 2px; flex: 1; }
  .side-link { display: flex; align-items: center; gap: 10px; padding: 11px 12px; border-radius: 12px; font-size: 14px; color: var(--navy); }
  .side-link:hover { background: var(--bg-tint); }
  .side-link.active { background: var(--bg-tint); font-weight: 700; }
  .side-link .badge { position: static; margin-left: auto; }
  .side-sep { height: 1px; background: var(--line); margin: 12px 4px; }
  .sidebar-foot { border-top: 1px solid var(--line); padding-top: 10px; }
  .page { max-width: 1100px; margin: 0 auto; padding: 34px 40px 60px; }
  .page-title { padding-top: 0; font-size: 34px; }
  .brand-row { padding-top: 0; }
  .hero { margin: 0 0 26px; border-radius: var(--radius); overflow: hidden; }
  .hero-slide img { height: 460px; }
  .hero-cta { padding: 0; }
  .hero-cta .btn { width: auto; }
  .grid-products { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
  .book { height: 380px; }
  .book-face img { height: 240px; }
  .band-next { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .sticky-actions { position: static; background: transparent; box-shadow: none; border: 0; padding: 0; margin-top: 16px; }
  .site-foot { margin-top: 40px; border-radius: 24px; padding-bottom: 28px; }
  .tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 1400px) {
  .grid-products { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .001ms !important; transition-duration: .001ms !important; }
  .hero-slide img { animation: none; }
}

/* ---------- administration ---------- */
.admin-body { background: var(--bg-tint); }
.admin-top { background: var(--navy); color: #fff; padding: calc(16px + env(safe-area-inset-top, 0px)) 18px 16px; display: flex; align-items: center; gap: 12px; position: sticky; top: 0; z-index: 40; }
.admin-top img { border-radius: 10px; }
.admin-top .who { margin-left: auto; font-size: 12px; opacity: .85; display: flex; align-items: center; gap: 10px; }
.admin-top button { background: rgba(255, 255, 255, .14); border: 0; color: #fff; height: 36px; border-radius: 999px; padding: 0 14px; font-size: 13px; cursor: pointer; }
.admin-wrap { padding: 18px 16px calc(var(--tabbar-h) + 40px); max-width: 1200px; margin: 0 auto; }
.admin-panel[hidden] { display: none !important; }
.admin-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.stat span { font-size: 12px; color: var(--muted); display: block; }
.stat b { font-size: 22px; font-weight: 800; display: block; margin-top: 4px; }
.stat small { font-size: 11px; color: var(--muted); }
.table-wrap { overflow-x: auto; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); }
table { border-collapse: collapse; width: 100%; font-size: 13px; min-width: 620px; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
th { font-size: 11px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); background: var(--bg-tint); }
tr:last-child td { border-bottom: 0; }
.admin-form-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
.chart-box { position: relative; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; }
.chart-box canvas { width: 100%; display: block; height: 240px; }
.chart-head { display: flex; flex-direction: column; gap: 6px; margin-bottom: 8px; }
.chart-head strong { font-size: 15px; }
.chart-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 12px; color: var(--muted); }
.chart-legend span { display: inline-flex; align-items: center; gap: 6px; }
.dot { width: 9px; height: 9px; border-radius: 99px; display: inline-block; flex: none; }
.dot-accounts { background: var(--navy); }
.dot-elements { background: #5A8DEE; }
.dot-orders { background: var(--accent); }
.stat-head { display: flex; align-items: baseline; gap: 8px; }
.stat-head b { font-size: 26px; font-weight: 800; }
.stat-delta { font-size: 11px; font-weight: 700; border-radius: 999px; padding: 2px 8px; }
.stat-delta.up { background: var(--ok-soft); color: var(--ok); }
.stat-delta.flat { background: var(--bg-tint); color: var(--muted); }
.stat-split { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 8px; font-size: 11px; color: var(--muted); }
.stat-split i { font-style: normal; color: var(--ink); font-weight: 700; }
.admin-tabbar { position: fixed; left: 12px; right: 12px; bottom: calc(10px + env(safe-area-inset-bottom, 0px)); z-index: 70; display: flex; justify-content: space-around; align-items: center; height: 62px; background: rgba(255, 255, 255, .92); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border: 1px solid var(--line); border-radius: 28px; box-shadow: 0 10px 26px rgba(11, 31, 58, .14); }
.admin-tabbar .tab.active .tab-ic { background: var(--navy); color: #fff; }
/* ---------- tableau de bord : alertes, statistiques, journal ---------- */
.alert-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
.alert-card { display: block; width: 100%; text-align: left; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; cursor: pointer; font: inherit; color: inherit; transition: transform .12s ease, border-color .2s ease; }
.alert-card:active { transform: scale(.985); }
.alert-card.has { border-left: 4px solid var(--accent); }
.alert-card.clear { border-left: 4px solid var(--ok); }
.alert-card .alert-count { font-size: 26px; font-weight: 800; display: block; margin-bottom: 2px; }
.alert-card.has .alert-count { color: var(--warn); }
.alert-card.clear .alert-count { color: var(--ok); }
.alert-card .alert-label { font-size: 13px; font-weight: 700; color: var(--navy); display: block; }
.alert-card .alert-hint { font-size: 11px; color: var(--muted); display: block; margin-top: 2px; }
.alert-card .alert-go { font-size: 11px; font-weight: 700; color: var(--navy); display: block; margin-top: 10px; }

.bar-row { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.rows-box { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.bar-row:last-child { border-bottom: 0; }
.bar-row .bar-label { flex: 1; min-width: 0; font-size: 13px; font-weight: 600; }
.bar-row .bar-label small { display: block; font-size: 11px; font-weight: 400; color: var(--muted); }
.bar-row .bar-value { font-size: 13px; font-weight: 700; white-space: nowrap; }
.bar-track { flex: none; width: 84px; height: 8px; border-radius: 99px; background: var(--bg-tint); overflow: hidden; }
.bar-track i { display: block; height: 100%; border-radius: 99px; background: var(--navy); }
.bar-track i.accent { background: var(--accent); }

.feed { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.feed-item { display: flex; align-items: flex-start; gap: 12px; padding: 12px 14px; border-bottom: 1px solid var(--line); width: 100%; text-align: left; background: none; border-left: 0; border-right: 0; border-top: 0; font: inherit; color: inherit; cursor: pointer; }
.feed-item:last-child { border-bottom: 0; }
.feed-item .feed-tag { flex: none; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; padding: 4px 9px; border-radius: 999px; background: var(--bg-tint); color: var(--navy); }
.feed-item .feed-body { flex: 1; min-width: 0; }
.feed-item .feed-body strong { font-size: 13px; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.feed-item .feed-body small { font-size: 11px; color: var(--muted); display: block; }
.feed-item .feed-when { flex: none; font-size: 11px; color: var(--muted); white-space: nowrap; }

@media (min-width: 480px) {
  .alert-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
/* barre de navigation haute, ordinateur uniquement */
.admin-topnav { display: none; }

@media (min-width: 900px) {
  .admin-tabbar:not(.admin-topnav) { display: none !important; }
  .admin-top { position: static; }
  .admin-topnav {
    display: flex; position: sticky; top: 0; bottom: auto; left: 0; right: 0;
    height: auto; justify-content: flex-start; align-items: center; gap: 6px;
    padding: 9px 16px; border-radius: 0; border-left: 0; border-right: 0; border-top: 0;
    background: #fff; box-shadow: 0 2px 10px rgba(11, 31, 58, .07);
    overflow-x: auto; scrollbar-width: none; z-index: 45;
  }
  .admin-topnav::-webkit-scrollbar { display: none; }
  .admin-topnav .tab { flex: none; flex-direction: row; gap: 8px; font-size: 14px; font-weight: 600; padding: 9px 16px; border-radius: 999px; white-space: nowrap; }
  .admin-topnav .tab:active { transform: none; }
  .admin-topnav .tab:hover { background: var(--bg-tint); }
  .admin-topnav .tab .tab-ic { width: 22px; height: 22px; border-radius: 0; background: transparent; }
  .admin-topnav .tab.active { background: var(--navy); color: #fff; }
  .admin-topnav .tab.active .tab-ic { background: transparent; color: #fff; }
  .admin-wrap { padding-bottom: 60px; }
  .admin-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .admin-form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .alert-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
