/* WP Flipbook PDF — Menu restaurant optimise PC + Mobile */

.wpfb-container {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  font-family: system-ui, sans-serif;
  background: #111;
  border-radius: 10px;
  box-shadow: 0 4px 32px rgba(0,0,0,.45);
  -webkit-tap-highlight-color: transparent;
}

/* ── Loading ── */
.wpfb-loading {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 14px;
  color: #fff; font-size: 15px;
  background: #111; z-index: 60;
  transition: opacity .4s;
}
.wpfb-loading.hidden { opacity: 0; pointer-events: none; }
.wpfb-spinner {
  width: 48px; height: 48px;
  border: 4px solid rgba(255,255,255,.12);
  border-top-color: var(--wpfb-btn, #e94560);
  border-radius: 50%;
  animation: wpfb-spin .75s linear infinite;
}
@keyframes wpfb-spin { to { transform: rotate(360deg); } }

/* ── Zone image : pleine largeur ── */
.wpfb-canvas-wrap {
  position: relative;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: #000;
  min-height: 0;
}
.wpfb-canvas-wrap canvas {
  display: block;
  width: 100% !important;
  height: auto !important;
}

/* ── Fleches flottantes SUR l'image ── */
.wpfb-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  background: rgba(0,0,0,.5);
  border: none;
  color: #fff;
  cursor: pointer;
  width: 48px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  transition: background .2s, opacity .25s;
}
.wpfb-arrow:hover  { background: var(--wpfb-btn, #e94560); }
.wpfb-arrow:active { transform: translateY(-50%) scale(.95); }
.wpfb-arrow svg    { width: 28px; height: 28px; fill: #fff; }
.wpfb-prev { left: 0;  border-radius: 0 6px 6px 0; }
.wpfb-next { right: 0; border-radius: 6px 0 0 6px; }

/* ── Barre du bas ── */
.wpfb-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 14px;
  background: rgba(0,0,0,.75);
  flex-shrink: 0;
  gap: 10px;
  min-height: 48px;
}

/* Compteur page */
.wpfb-counter {
  color: rgba(255,255,255,.85);
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  min-width: 50px;
}

/* Points de navigation */
.wpfb-dots {
  display: flex;
  align-items: center;
  gap: 7px;
  flex: 1;
  justify-content: center;
  flex-wrap: wrap;
}
.wpfb-dot {
  width: 9px; height: 9px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,.3);
  cursor: pointer;
  padding: 0;
  transition: background .2s, transform .2s;
}
.wpfb-dot.active {
  background: var(--wpfb-btn, #e94560);
  transform: scale(1.4);
}
.wpfb-dot:hover { background: rgba(255,255,255,.6); }

/* Boutons action */
.wpfb-actions { display: flex; align-items: center; gap: 8px; }
.wpfb-btn {
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 6px;
  color: #fff;
  cursor: pointer;
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  text-decoration: none;
  transition: background .2s;
  flex-shrink: 0;
}
.wpfb-btn svg { width: 18px; height: 18px; fill: #fff; }
.wpfb-btn:hover { background: var(--wpfb-btn, #e94560); border-color: transparent; }

/* Barre de progression (fine) */
.wpfb-progress-bar  { height: 3px; background: rgba(255,255,255,.08); flex-shrink: 0; }
.wpfb-progress-fill { height: 100%; background: var(--wpfb-btn, #e94560); width: 0%; transition: width .35s ease; }

/* Erreur */
.wpfb-error {
  padding: 1em 1.5em; color: #e05555;
  background: #fff5f5; border-left: 4px solid #e05555;
  border-radius: 4px; margin: 1em; font-size: 14px;
}

/* Popup partage */
.wpfb-share-popup {
  position: absolute; inset: 0;
  background: rgba(0,0,0,.65);
  display: flex; align-items: center; justify-content: center; z-index: 50;
}
.wpfb-share-popup[hidden] { display: none !important; }
.wpfb-share-inner {
  background: #1e1e2e; border: 1px solid rgba(255,255,255,.15);
  border-radius: 14px; padding: 28px 32px;
  color: #fff; min-width: 270px; position: relative; text-align: center;
}
.wpfb-share-inner p  { margin: 0 0 16px; font-size: 15px; font-weight: 600; }
.wpfb-share-btns     { display: flex; gap: 10px; justify-content: center; }
.wpfb-share-btns a {
  background: var(--wpfb-btn, #e94560);
  color: #fff; text-decoration: none; border-radius: 6px;
  padding: 8px 14px; font-size: 13px; font-weight: 500;
}
.wpfb-share-close {
  position: absolute; top: 10px; right: 14px;
  background: none; border: none; color: rgba(255,255,255,.45);
  font-size: 22px; cursor: pointer; line-height: 1;
}
.wpfb-share-close:hover { color: #fff; }

/* Plein ecran */
.wpfb-container:fullscreen,
.wpfb-container:-webkit-full-screen {
  border-radius: 0 !important;
  width: 100vw !important; height: 100vh !important;
}
.wpfb-container:fullscreen .wpfb-canvas-wrap,
.wpfb-container:-webkit-full-screen .wpfb-canvas-wrap {
  flex: 1;
}

/* ── Mobile ── */
@media (max-width: 600px) {
  .wpfb-arrow { width: 36px; height: 64px; }
  .wpfb-arrow svg { width: 22px; height: 22px; }
  .wpfb-bar { padding: 6px 10px; min-height: 44px; }
  .wpfb-counter { font-size: 13px; }
}
