/* Appily Seventeen — Sowing Bench Catalog shop */

.page-sow-bench .page-main {
  background: linear-gradient(180deg, #f3f8f5 0%, #fafcfb 24%, #fff 100%);
}

/* ── Ledger hero ── */
.sb-ledger {
  position: relative;
  padding: 44px 0 0;
  overflow: hidden;
  background: linear-gradient(135deg, #1a3d32 0%, #253d4e 55%, #2d4a3e 100%);
  color: #fff;
}
.sb-ledger-texture {
  position: absolute;
  inset: 0;
  opacity: 0.08;
  background-image:
    repeating-linear-gradient(0deg, transparent, transparent 27px, rgba(255,255,255,.4) 28px),
    repeating-linear-gradient(90deg, transparent, transparent 27px, rgba(255,255,255,.15) 28px);
  pointer-events: none;
}
.sb-ledger-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.2fr 280px;
  gap: 32px;
  align-items: end;
  padding-bottom: 32px;
}
.sb-kicker {
  display: inline-block;
  margin: 0 0 10px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.65);
}
.sb-ledger-copy h1 {
  margin: 0 0 10px;
  font-family: var(--fv-font-alt, 'Quicksand', sans-serif);
  font-size: clamp(1.75rem, 3.5vw, 2.5rem);
  line-height: 1.15;
}
.sb-ledger-copy h1 em {
  font-style: normal;
  color: #7ee0ad;
}
.sb-note {
  margin: 0 0 20px;
  font-size: 0.88rem;
  opacity: 0.85;
  max-width: 48ch;
}
.sb-search-bar {
  display: flex;
  align-items: stretch;
  max-width: 480px;
  border-radius: 10px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(6px);
}
.sb-search-tag {
  display: grid;
  place-items: center;
  padding: 0 14px;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: rgba(0, 0, 0, 0.2);
  color: #7ee0ad;
}
.sb-search-bar input {
  flex: 1;
  border: 0;
  background: transparent;
  padding: 12px 14px;
  font: inherit;
  font-size: 0.92rem;
  color: #fff;
  min-width: 0;
}
.sb-search-bar input::placeholder { color: rgba(255, 255, 255, 0.45); }
.sb-search-bar button {
  border: 0;
  background: var(--fv-green, #3BB77E);
  color: #fff;
  padding: 0 20px;
  font: inherit;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  white-space: nowrap;
}
.sb-clear-search {
  display: inline-block;
  margin-top: 12px;
  font-size: 0.82rem;
  color: #7ee0ad;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Tally card */
.sb-tally {
  padding: 22px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.18);
  text-align: center;
}
.sb-tally-face {
  padding: 16px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.22);
  margin-bottom: 12px;
}
.sb-tally-num {
  display: block;
  font-family: var(--fv-font-alt);
  font-size: 2.4rem;
  font-weight: 800;
  line-height: 1;
  color: #7ee0ad;
}
.sb-tally-label {
  display: block;
  margin-top: 4px;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.75;
}
.sb-tally-range {
  margin: 0 0 12px;
  font-size: 0.8rem;
  opacity: 0.8;
}
.sb-crumb {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 0.78rem;
  opacity: 0.7;
}
.sb-crumb a { color: #fff; }
.sb-crumb a:hover { color: #7ee0ad; }

.sb-bench-lip {
  height: 12px;
  background: linear-gradient(180deg, #8b6914 0%, #c4a035 40%, #a8862a 100%);
  box-shadow: inset 0 2px 4px rgba(255, 255, 255, 0.25);
}

/* ── Category lanes ── */
.sb-lanes {
  padding: 20px 0;
  background: #fff;
  border-bottom: 1px solid var(--fv-line);
}
.sb-lane-wrap { position: relative; }
.sb-lane-wire {
  position: absolute;
  top: 18px;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(59, 183, 126, 0.35), transparent);
}
.sb-lane-rail {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 4px 0 8px;
  scrollbar-width: none;
}
.sb-lane-rail::-webkit-scrollbar { display: none; }
.sb-lane {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  min-width: 88px;
  padding: 12px 14px 10px;
  border-radius: 12px;
  background: var(--fv-bg);
  border: 1px solid var(--fv-line);
  text-align: center;
  transition: transform 0.2s, border-color 0.2s, background 0.2s;
}
.sb-lane:hover {
  transform: translateY(-2px);
  border-color: var(--fv-green);
}
.sb-lane.is-active {
  background: var(--fv-green-pale);
  border-color: var(--fv-green);
  box-shadow: 0 4px 14px rgba(59, 183, 126, 0.15);
}
.sb-lane-icon { font-size: 1.2rem; line-height: 1; }
.sb-lane-name {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--fv-heading);
  line-height: 1.25;
}
.sb-lane-count {
  font-size: 0.68rem;
  color: var(--fv-muted);
  font-weight: 600;
}

/* ── Floor layout ── */
.sb-floor { padding: 32px 0 72px; }
.sb-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 28px;
  align-items: start;
  position: relative;
}
.sb-drawer-toggle {
  display: none;
  grid-column: 1 / -1;
  align-items: center;
  gap: 8px;
  padding: 12px 18px;
  border: 1px solid var(--fv-line);
  border-radius: 10px;
  background: #fff;
  font: inherit;
  font-weight: 600;
  font-size: 0.88rem;
  cursor: pointer;
  color: var(--fv-heading);
}

/* Filter drawer */
.sb-drawer {
  position: sticky;
  top: 96px;
  border-radius: 14px;
  background: #fff;
  border: 1px solid var(--fv-line);
  box-shadow: var(--fv-shadow-soft);
  overflow: hidden;
}
.sb-drawer-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  padding: 18px 18px 14px;
  background: linear-gradient(180deg, #f0f7f3 0%, #fff 100%);
  border-bottom: 2px solid #c4a035;
}
.sb-drawer-head h2 {
  margin: 0;
  font-size: 0.95rem;
  color: var(--fv-heading);
}
.sb-drawer-head span {
  display: block;
  font-size: 0.75rem;
  color: var(--fv-muted);
  margin-top: 2px;
}
.sb-drawer-close {
  display: none;
  border: 0;
  background: transparent;
  font-size: 1.4rem;
  cursor: pointer;
  color: var(--fv-muted);
  line-height: 1;
}
.sb-filter-form { padding: 8px 0 16px; }
.sb-filter-block {
  border-bottom: 1px solid var(--fv-line);
}
.sb-filter-block:last-child { border-bottom: 0; }
.sb-filter-title {
  padding: 14px 18px;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--fv-heading);
  cursor: pointer;
  list-style: none;
}
.sb-filter-block > .sb-filter-title {
  padding: 14px 18px 10px;
  cursor: default;
}
details.sb-filter-block > summary.sb-filter-title { cursor: pointer; }
details.sb-filter-block > summary.sb-filter-title::-webkit-details-marker { display: none; }
.sb-filter-body { padding: 0 18px 16px; }

/* Price slider */
.sb-price-slider {
  position: relative;
  height: 28px;
  margin-bottom: 10px;
}
.sb-price-track {
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 5px;
  margin-top: -2px;
  background: #e8ece9;
  border-radius: 99px;
}
.sb-price-fill {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--fv-green);
  border-radius: 99px;
}
.sb-range {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 28px;
  margin: 0;
  pointer-events: none;
  appearance: none;
  background: transparent;
}
.sb-range::-webkit-slider-thumb {
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--fv-green);
  border: 3px solid #fff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
  pointer-events: auto;
  cursor: pointer;
}
.sb-range::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--fv-green);
  border: 3px solid #fff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
  pointer-events: auto;
  cursor: pointer;
}
.sb-range-max { z-index: 2; }
.sb-price-label {
  margin: 0 0 12px;
  font-size: 0.82rem;
  color: var(--fv-ink);
}
.sb-filter-btn {
  display: block;
  width: 100%;
  border: 0;
  border-radius: 8px;
  padding: 11px;
  background: var(--fv-green);
  color: #fff;
  font: inherit;
  font-weight: 700;
  font-size: 0.82rem;
  cursor: pointer;
}
.sb-filter-btn:hover { background: var(--fv-green-dark); }

/* Checkboxes */
.sb-cat-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.sb-check {
  display: grid;
  grid-template-columns: 18px 1fr auto;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 0.84rem;
  color: var(--fv-ink);
}
.sb-check input { position: absolute; opacity: 0; width: 0; height: 0; }
.sb-check-box {
  width: 16px;
  height: 16px;
  border: 2px solid #ccc;
  border-radius: 4px;
  background: #fff;
  position: relative;
}
.sb-check input:checked + .sb-check-box {
  background: var(--fv-green);
  border-color: var(--fv-green);
}
.sb-check input:checked + .sb-check-box::after {
  content: '';
  position: absolute;
  left: 4px;
  top: 1px;
  width: 4px;
  height: 8px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.sb-check-count { font-size: 0.78rem; color: var(--fv-muted); }

.sb-search-field {
  display: flex;
  align-items: center;
  border: 1px solid var(--fv-line);
  border-radius: 8px;
  background: var(--fv-bg);
  overflow: hidden;
}
.sb-search-field input {
  flex: 1;
  border: 0;
  background: transparent;
  padding: 10px 12px;
  font: inherit;
  font-size: 0.85rem;
}
.sb-search-icon { padding: 0 12px; color: var(--fv-muted); }

.sb-popular-list {
  list-style: none;
  margin: 0;
  padding: 0 18px 8px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.sb-popular-item {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: inherit;
}
.sb-popular-item img {
  width: 52px;
  height: 52px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--fv-line);
}
.sb-popular-copy {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.sb-popular-copy strong {
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.sb-popular-copy em {
  font-style: normal;
  font-weight: 700;
  font-size: 0.82rem;
  color: var(--fv-red);
}

.sb-drawer-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  z-index: 98;
}

/* Toolbar */
.sb-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 24px;
  padding: 14px 18px;
  border-radius: 12px;
  background: #fff;
  border: 1px solid var(--fv-line);
}
.sb-result-count {
  margin: 0;
  font-size: 0.88rem;
  color: var(--fv-ink);
}
.sb-toolbar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}
.sb-sort {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  color: var(--fv-muted);
}
.sb-sort select {
  border: 1px solid var(--fv-line);
  border-radius: 8px;
  padding: 8px 28px 8px 10px;
  font: inherit;
  font-size: 0.82rem;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='%23666' d='M1 1l4 4 4-4'/%3E%3C/svg%3E") no-repeat right 10px center;
  appearance: none;
  cursor: pointer;
}
.sb-view-toggle { display: flex; gap: 4px; }
.sb-view-btn {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--fv-line);
  border-radius: 8px;
  font-size: 1rem;
  color: var(--fv-muted);
  background: #fff;
}
.sb-view-btn.is-active {
  background: var(--fv-green);
  border-color: var(--fv-green);
  color: #fff;
}

/* Lot cards (seed packet style) */
.sb-lot-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.sb-lot-card {
  position: relative;
  border-radius: 14px;
  background: #fff;
  border: 1px solid var(--fv-line);
  overflow: hidden;
  transition: transform 0.2s, box-shadow 0.2s;
}
.sb-lot-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--fv-shadow);
}
.sb-lot-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 6px;
  background: repeating-linear-gradient(
    90deg,
    var(--fv-green) 0,
    var(--fv-green) 8px,
    #7ee0ad 8px,
    #7ee0ad 16px
  );
  z-index: 1;
}
.sb-lot-tag {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 14px 6px;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--fv-muted);
}
.sb-lot-tag small {
  font-weight: 600;
  color: var(--fv-green-dark);
}
.sb-lot-img {
  position: relative;
  display: block;
  margin: 0 14px;
  border-radius: 10px;
  overflow: hidden;
  background: var(--fv-bg);
}
.sb-lot-img img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: contain;
  padding: 8px;
  transition: transform 0.3s;
}
.sb-lot-card:hover .sb-lot-img img { transform: scale(1.05); }
.sb-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  padding: 4px 8px;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #fff;
  border-radius: 4px;
}
.sb-badge-sale { background: var(--fv-red); }
.sb-badge-new { background: var(--fv-green); }
.sb-lot-body { padding: 12px 14px 16px; }
.sb-lot-lane {
  display: inline-block;
  margin-bottom: 6px;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--fv-green-pale);
  color: var(--fv-green-deep);
  font-size: 0.68rem;
  font-weight: 700;
}
.sb-lot-body h2 {
  margin: 0 0 4px;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.sb-lot-body h2 a {
  color: var(--fv-heading);
  text-decoration: none;
}
.sb-lot-body h2 a:hover { color: var(--fv-green); }
.sb-lot-brand {
  margin: 0 0 6px;
  font-size: 0.72rem;
  color: var(--fv-muted);
}
.sb-stars {
  display: flex;
  gap: 1px;
  margin-bottom: 10px;
  font-size: 0.72rem;
  color: #ddd;
}
.sb-stars .is-on { color: var(--fv-gold, #FDC040); }
.sb-lot-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.sb-price {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--fv-red);
}
.sb-lot-link {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--fv-green);
  white-space: nowrap;
}

/* List view */
.sb-lot-grid.is-list {
  grid-template-columns: 1fr;
  gap: 16px;
}
.sb-lot-grid.is-list .sb-lot-card {
  display: grid;
  grid-template-columns: 140px 1fr;
  grid-template-rows: auto 1fr;
}
.sb-lot-grid.is-list .sb-lot-tag { grid-column: 1 / -1; }
.sb-lot-grid.is-list .sb-lot-img {
  grid-row: 2;
  margin: 0 0 14px 14px;
  align-self: center;
}
.sb-lot-grid.is-list .sb-lot-img img { aspect-ratio: 1; }
.sb-lot-grid.is-list .sb-lot-body {
  grid-row: 2;
  align-self: center;
}

/* Empty */
.sb-empty {
  text-align: center;
  padding: 64px 24px;
  border: 2px dashed rgba(59, 183, 126, 0.35);
  border-radius: 16px;
  background: var(--fv-green-pale);
}
.sb-empty-icon { font-size: 2.5rem; display: block; margin-bottom: 12px; }
.sb-empty p { margin: 0 0 16px; color: var(--fv-muted); }
.sb-empty-btn {
  display: inline-flex;
  padding: 11px 24px;
  border-radius: 999px;
  background: var(--fv-green);
  color: #fff;
  font-weight: 700;
  font-size: 0.88rem;
}

/* Pagination */
.sb-pagination { margin-top: 40px; }
.sb-pagination .catalog-pagination { margin: 0; }
.sb-pagination .pagination-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
}
.sb-pagination .pagination-btn,
.sb-pagination .pagination-num,
.sb-pagination .pagination-ellipsis {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  height: 38px;
  padding: 0 10px;
  border-radius: 8px;
  border: 1px solid var(--fv-line);
  background: #fff;
  font: inherit;
  font-size: 0.88rem;
  color: var(--fv-ink);
  text-decoration: none;
}
.sb-pagination .pagination-num.is-active {
  background: var(--fv-green);
  border-color: var(--fv-green);
  color: #fff;
  font-weight: 700;
}
.sb-pagination .pagination-num:hover,
.sb-pagination .pagination-btn:hover:not(.is-disabled) {
  border-color: var(--fv-green);
  color: var(--fv-green);
}
.sb-pagination .pagination-btn.is-disabled {
  opacity: 0.35;
  pointer-events: none;
}
.sb-pagination .pagination-prev { font-size: 0; min-width: 38px; }
.sb-pagination .pagination-prev::before { content: '←'; font-size: 1rem; }
.sb-pagination .pagination-next { font-size: 0; min-width: 38px; }
.sb-pagination .pagination-next::after { content: '→'; font-size: 1rem; }
.sb-pagination .pagination-pages { display: flex; gap: 6px; }

/* Mobile drawer */
@media (max-width: 960px) {
  .sb-ledger-grid { grid-template-columns: 1fr; }
  .sb-tally { max-width: 280px; }
  .sb-layout { grid-template-columns: 1fr; }
  .sb-drawer-toggle { display: inline-flex; }
  .sb-drawer {
    position: fixed;
    top: 0;
    left: 0;
    width: min(320px, 88vw);
    height: 100vh;
    z-index: 99;
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    overflow-y: auto;
    border-radius: 0;
  }
  .sb-drawer.is-open { transform: translateX(0); }
  .sb-drawer-close { display: block; }
  .sb-drawer-backdrop.is-visible { display: block; }
  body.sb-drawer-open { overflow: hidden; }
  .sb-lot-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 560px) {
  .sb-lot-grid { grid-template-columns: 1fr; }
  .sb-lot-grid.is-list .sb-lot-card {
    grid-template-columns: 1fr;
  }
  .sb-lot-grid.is-list .sb-lot-img { margin: 0 14px; }
  .sb-toolbar { flex-direction: column; align-items: flex-start; }
}
