/* ===== فیلتر محصولات به شکل کتاب ورق‌خور ===== */
.fb-root { direction: rtl; }

.fb-layout { display: grid; grid-template-columns: 330px 1fr; gap: 24px; align-items: start; }
@media (max-width: 900px) { .fb-layout { grid-template-columns: 1fr; } }

.fb-book-head {
  display: flex; align-items: center; gap: 8px;
  font-weight: 800; font-size: 15px; margin-bottom: 10px; color: #123;
}
.fb-stage { perspective: 1800px; }
.fb-book {
  position: relative; height: 420px;
  transform-style: preserve-3d;
  border-radius: 12px 5px 5px 12px;
  background: #e9ecef;
  box-shadow: 0 14px 34px rgba(0,0,0,.16);
}
.fb-book::before {
  content: ""; position: absolute; top: 0; bottom: 0; right: 0; width: 8px;
  background: linear-gradient(to left, rgba(0,0,0,.18), transparent);
  border-radius: 0 5px 5px 0; pointer-events: none; z-index: 200;
}
.fb-page {
  position: absolute; inset: 0;
  transform-origin: 100% 50%;
  transform-style: preserve-3d;
  transition: transform .75s cubic-bezier(.4,.05,.3,1);
  pointer-events: none;
}
.fb-face {
  position: absolute; inset: 0; backface-visibility: hidden;
  background: #fff; border: 1px solid #e5e8ee;
  border-radius: 12px 5px 5px 12px;
  box-shadow: inset 14px 0 22px -18px rgba(0,0,0,.3);
  display: flex; flex-direction: column; overflow: hidden;
}
.fb-face-back {
  transform: rotateY(180deg);
  background: linear-gradient(to left, #e9ecef, #fff);
  border-radius: 5px 12px 12px 5px;
  box-shadow: inset -14px 0 22px -18px rgba(0,0,0,.3);
  align-items: center; justify-content: center;
}
.fb-back-note { color: #98a1ad; font-size: 11px; writing-mode: vertical-rl; letter-spacing: 3px; }
.fb-page.is-turnable { pointer-events: auto; }
.fb-page.is-turned { transform: rotateY(-180deg); }

.fb-page-head { padding: 14px 16px 10px; border-bottom: 1px solid #eef1f5; }
.fb-step-tag { font-size: 11px; color: #0a4aa8; font-weight: 700; }
.fb-page-title { font-weight: 800; font-size: 15px; margin-top: 2px; color: #16202b; }
.fb-page-body { padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; flex: 1; overflow-y: auto; }

.fb-opt {
  display: flex; align-items: center; gap: 10px; width: 100%; text-align: right;
  background: #fff; border: 1.5px solid #e5e8ee; border-radius: 10px;
  padding: 10px 12px; font: inherit; font-size: 13.5px; color: #16202b;
  cursor: pointer; transition: background .15s, border-color .15s;
}
.fb-opt:hover { background: #f4f7fb; }
.fb-check {
  width: 18px; height: 18px; border-radius: 6px; border: 1.5px solid #b8c0cc;
  display: inline-flex; align-items: center; justify-content: center; flex: none;
  color: transparent; font-size: 12px; font-weight: 800; transition: all .15s;
}
.fb-opt.is-selected { border-color: #0a4aa8; background: #eef4fd; font-weight: 700; }
.fb-opt.is-selected .fb-check { background: #0a4aa8; border-color: #0a4aa8; color: #fff; }
.fb-icon { flex: none; font-style: normal; }
.fb-count { margin-right: auto; font-size: 11px; color: #98a1ad; }

.fb-foot { padding: 12px; border-top: 1px solid #eef1f5; display: flex; gap: 8px; align-items: stretch; }
.fb-btn-next {
  flex: 1; border: 0; border-radius: 10px; padding: 10px; font: inherit; font-size: 13.5px; font-weight: 800;
  background: #0a4aa8; color: #fff; cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 6px;
  transition: opacity .2s, background .15s;
}
.fb-btn-next:hover:not([disabled]) { background: #0e5fd8; }
.fb-btn-next[disabled] { opacity: .35; cursor: not-allowed; }
.fb-btn-back {
  border: 1px solid #dde3ec; background: #fff; color: #7b8593; border-radius: 10px;
  padding: 10px 14px; font: inherit; font-size: 13.5px; cursor: pointer;
}
.fb-btn-back:hover { color: #16202b; border-color: #b8c0cc; }
.fb-btn-reset { border: 1px solid #dde3ec; background: #fff; color: #7b8593; border-radius: 10px; padding: 10px 14px; font: inherit; cursor: pointer; }
.fb-btn-reset:hover { color: #c0392b; border-color: #e5b4ae; }

.fb-progress { display: flex; gap: 5px; margin-top: 10px; justify-content: center; }
.fb-dot { width: 26px; height: 5px; border-radius: 3px; background: #dde3ec; transition: background .3s; }
.fb-dot.is-active { background: #0a4aa8; }

.fb-summary-line { display: flex; justify-content: space-between; gap: 8px; font-size: 13px; padding: 9px 4px; border-bottom: 1px dashed #e5e8ee; }
.fb-summary-line span:first-child { color: #7b8593; }
.fb-summary-line span:last-child { font-weight: 700; }
.fb-result-note { font-size: 12.5px; color: #0a7a4f; background: #e9f7f0; border-radius: 8px; padding: 8px 10px; margin-top: 10px; }

.fb-product-hidden { display: none !important; }
@media (prefers-reduced-motion: reduce) { .fb-page { transition: none; } }
