/* Home page product switcher: a product list on the left, the selected product's media and details on the right.
   Uses the theme's font (Raleway), lime accent and neutral greys. */

.qv-products {
  padding: 96px 0 104px;
  background: #ffffff;
}

.qv-products-head {
  max-width: 640px;
  margin-bottom: 48px;
}

.qv-products-head h2 {
  margin: 0 0 12px;
  font-size: 40px;
  font-weight: 800;
  line-height: 1.15;
  color: #1f2a10;
}

.qv-products-head p {
  margin: 0;
  font-size: 18px;
  line-height: 1.6;
  color: #555555;
}

.qv-switcher {
  display: grid;
  grid-template-columns: minmax(260px, 340px) 1fr;
  gap: 40px;
  align-items: start;
}

/* Product list */
.qv-switcher-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0;
  padding: 0;
}

.qv-tab {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 14px 16px;
  overflow: hidden;
  font-family: inherit;
  text-align: left;
  color: #1f2a10;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 12px;
  cursor: pointer;
  transition: background-color 0.25s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.qv-tab:hover {
  background: #f6f7f3;
}

.qv-tab[aria-selected="true"] {
  background: #ffffff;
  border-color: #e6e8e1;
  box-shadow: 0 16px 32px -24px rgba(40, 55, 15, 0.45);
}

.qv-tab:focus-visible {
  outline: 3px solid #5c7a12;
  outline-offset: 2px;
}

.qv-tab-icon {
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  font-size: 18px;
  color: #5c7a12;
  background: #f1f8e0;
  border-radius: 10px;
  transition: background-color 0.25s ease, color 0.25s ease;
}

.qv-tab[aria-selected="true"] .qv-tab-icon {
  color: #1f2a10;
  background: #b2dd4c;
}

.qv-tab-text {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
}

.qv-tab-name {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.3;
}

.qv-tab-category {
  overflow: hidden;
  font-size: 13px;
  line-height: 1.4;
  color: #6b6f63;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.qv-tab-badge {
  flex-shrink: 0;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #1f2a10;
  background: #b2dd4c;
  border-radius: 999px;
}

/* Auto-advance progress on the selected tab */
.qv-tab-progress {
  position: absolute;
  right: 16px;
  bottom: 0;
  left: 16px;
  height: 2px;
  background: #b2dd4c;
  transform: scaleX(0);
  transform-origin: left center;
  opacity: 0;
}

.qv-switcher.is-auto .qv-tab[aria-selected="true"] .qv-tab-progress {
  opacity: 1;
  animation: qv-progress var(--qv-interval, 8s) linear forwards;
}

.qv-switcher.is-paused .qv-tab[aria-selected="true"] .qv-tab-progress {
  animation-play-state: paused;
}

@keyframes qv-progress {
  to {
    transform: scaleX(1);
  }
}

/* Panels */
.qv-switcher-panels {
  position: relative;
  min-width: 0;
}

.qv-product-panel {
  background: #ffffff;
  border: 1px solid #e6e8e1;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 32px 64px -48px rgba(40, 55, 15, 0.5);
}

.qv-product-panel[hidden] {
  display: none;
}

.qv-product-panel.is-entering {
  animation: qv-panel-in 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes qv-panel-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
}

.qv-product-media {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #f6f7f3;
  border-bottom: 1px solid #e6e8e1;
}

.qv-product-media img,
.qv-product-media video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}

.qv-product-media--contain img {
  padding: 24px;
  object-fit: contain;
  background: #ffffff;
}

.qv-product-body {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px 32px;
  align-items: end;
  padding: 28px 32px 32px;
}

.qv-product-body h3 {
  margin: 0 0 6px;
  font-size: 26px;
  font-weight: 800;
  line-height: 1.2;
  color: #1f2a10;
}

.qv-product-tagline {
  margin: 0 0 10px;
  font-size: 16px;
  font-weight: 600;
  color: #5c7a12;
}

.qv-product-body p.qv-product-text {
  max-width: 62ch;
  margin: 0;
  font-size: 16px;
  line-height: 1.65;
  color: #444444;
}

.qv-product-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
}

.qv-product-chips li {
  padding: 5px 12px;
  font-size: 13px;
  font-weight: 600;
  color: #2b2f26;
  background: #f6f7f3;
  border: 1px solid #e6e8e1;
  border-radius: 999px;
}

.qv-product-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
}

.qv-product-actions .qodef-btn {
  margin: 0;
}

.qv-product-link {
  font-size: 15px;
  font-weight: 700;
  color: #1f2a10;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.qv-product-link:hover {
  color: #5c7a12;
}

/* Tablet and phone: product list becomes a swipeable row above the panel */
@media (max-width: 991px) {
  .qv-products {
    padding: 64px 0 72px;
  }

  .qv-products-head h2 {
    font-size: 30px;
  }

  .qv-switcher {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .qv-switcher-list {
    flex-direction: row;
    gap: 8px;
    margin: 0 -16px;
    padding: 4px 16px 8px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-left: 16px;
    scrollbar-width: none;
  }

  .qv-switcher-list::-webkit-scrollbar {
    display: none;
  }

  .qv-tab {
    flex: 0 0 auto;
    width: auto;
    padding: 10px 14px;
    background: #f6f7f3;
    scroll-snap-align: start;
  }

  .qv-tab-icon {
    width: 32px;
    height: 32px;
    font-size: 15px;
  }

  .qv-tab-category,
  .qv-tab-badge {
    display: none;
  }

  .qv-product-body {
    grid-template-columns: 1fr;
    padding: 22px 20px 24px;
  }

  .qv-product-actions {
    align-items: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  .qv-tab,
  .qv-tab-icon {
    transition: none;
  }

  .qv-product-panel.is-entering {
    animation: none;
  }
}
