/* ============================================================================
   DDistillers shop archive
   Carries the /shop-redesign/ visual language onto the real WooCommerce
   catalogue at /products/ so prices, stock and products are always live.

   Scope: every rule is nested under .ddr-archive, a body class added only on
   is_shop() / product taxonomy pages (see inc/ddr-shop.php), so no other
   template on the site is touched.

   The card is Blocksy's own markup re-ordered with flex `order`:
     figure -> .entry-meta (eyebrow) -> h2 (name) -> .latin (subtitle)
     -> .price (amount + size) -> .ct-woo-card-actions (.actions > 2 buttons)
   ========================================================================= */

.ddr-archive {
  --ddr-teal: #004e52;
  --ddr-cream: #fffdee;
  --ddr-sand: #e6e4d6;
  --ddr-line: #cfd9cd;
  --ddr-gold: #e8ae1e;
  --ddr-muted: rgba(0, 78, 82, 0.8);
  --ddr-serif: "Fraunces", Georgia, serif;
  --ddr-sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
}

.ddr-archive,
.ddr-archive .site-main {
  background: var(--ddr-cream);
  color: var(--ddr-teal);
  font-family: var(--ddr-sans);
}

/* ---------------------------------------------------------------- hero --- */
/* The hero is printed by woocommerce_before_main_content, i.e. outside Blocksy's
   sidebar grid, so it brings its own .ct-container wrapper. */
.ddr-archive .ddr-hero-wrap {
  padding-top: 8px;
  padding-bottom: 0;
}

.ddr-archive .ddr-hero {
  width: 100%;
  padding: 0 0 28px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.ddr-archive .ddr-breadcrumb {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--ddr-teal);
}

.ddr-archive .ddr-breadcrumb a {
  color: inherit;
  text-decoration: none;
}

.ddr-archive .ddr-breadcrumb a:hover {
  text-decoration: underline;
}

.ddr-archive .bc-sep {
  color: var(--ddr-muted);
}

.ddr-archive .ddr-hero-copy {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ddr-archive .accent {
  width: 44px;
  height: 4px;
  background: var(--ddr-gold);
  display: block;
  margin-bottom: 6px;
}

.ddr-archive .ddr-hero-title {
  font-family: var(--ddr-serif);
  font-weight: 600;
  font-variation-settings: "SOFT" 0, "WONK" 1;
  font-size: 44px;
  line-height: 1.12;
  margin: 0;
  color: var(--ddr-teal);
}

.ddr-archive .ddr-hero-sub {
  margin: 0;
  color: var(--ddr-muted);
  font-size: 16px;
  max-width: 62ch;
}

/* -------------------------------------------------------------- layout --- */
/* Blocksy lays this out as grid 890px / 348px with the sidebar on the right.
   The design wants a 260px filter column on the LEFT and a 3-up grid.

   Both columns need an explicit grid-row: the section is placed in column 2 by
   DOM order first, and without a row the sparse auto-placement cursor pushes
   the aside onto row 2 - i.e. the whole filter column lands below the grid. */
.ddr-archive [data-sidebar] {
  display: grid !important;
  grid-template-columns: 260px minmax(0, 1fr) !important;
  gap: 32px !important;
  /* Blocksy puts 60px of top padding on the archive grid. On its own that is
     most of the space between the hero subheading and the Filters bar. */
  padding-top: 32px !important;
  align-items: start !important;
}

.ddr-archive [data-sidebar] > aside {
  grid-column: 1 !important;
  grid-row: 1 !important;
  width: auto !important;
  min-width: 0 !important;
}

.ddr-archive [data-sidebar] > section {
  grid-column: 2 !important;
  grid-row: 1 !important;
  width: auto !important;
  min-width: 0 !important;
}

/* Blocksy's own page-title hero would print a second "Products" heading */
.ddr-archive .hero-section.is-width-constrained {
  display: none !important;
}

/* ------------------------------------------------------------- toolbar --- */
.ddr-archive .woocommerce-products-header {
  display: none !important;
}

.ddr-archive ul.products {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 24px !important;
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
}

.ddr-archive .ddr-toolbar {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 16px !important;
  width: 100% !important;
  padding-bottom: 20px !important;
}

.ddr-archive .woocommerce-result-count {
  margin: 0 !important;
  float: none !important;
  color: var(--ddr-muted) !important;
  font-size: 14px !important;
}

.ddr-archive .woocommerce-ordering {
  margin: 0 !important;
  float: none !important;
}

.ddr-archive form.woocommerce-ordering select,
.ddr-archive .woocommerce-ordering select {
  height: 40px !important;
  min-width: 240px !important;
  padding: 0 12px !important;
  border: 1px solid var(--ddr-line) !important;
  border-radius: 8px !important;
  background: var(--ddr-cream) !important;
  color: var(--ddr-teal) !important;
  font-size: 14px !important;
  font-family: var(--ddr-sans) !important;
  margin: 0 !important;
}

/* ---------------------------------------------------------------- card --- */
.ddr-archive ul.products li.product {
  display: flex !important;
  flex-direction: column !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  float: none !important;
  background: var(--ddr-cream) !important;
  border: 1px solid var(--ddr-line) !important;
  border-radius: 30px !important;
  overflow: hidden !important;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.ddr-archive ul.products li.product:hover {
  border-color: var(--ddr-teal) !important;
  box-shadow: 0 10px 30px -18px rgba(0, 78, 82, 0.55);
}

/* photo */
.ddr-archive ul.products li.product > figure {
  order: 1;
  position: relative;
  height: 220px;
  margin: 0 !important;
  padding: 16px !important;
  background: var(--ddr-sand);
  border-bottom: 1px solid var(--ddr-line);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.ddr-archive ul.products li.product > figure a {
  display: block;
  width: 100%;
  height: 100%;
}

.ddr-archive ul.products li.product > figure img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  border-radius: 12px;
  display: block;
  margin: 0 !important;
}

/* eyebrow: Blocksy already outputs the category list, just re-order it */
.ddr-archive ul.products li.product > .entry-meta {
  order: 2;
  margin: 16px 16px 0 !important;
  padding: 0 !important;
  list-style: none !important;
  display: block !important;
  background: transparent !important;
  border: 0 !important;
}

.ddr-archive ul.products li.product > .entry-meta li {
  display: inline;
  margin: 0 !important;
  padding: 0 !important;
  background: transparent !important;
  border: 0 !important;
}

.ddr-archive ul.products li.product > .entry-meta a {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  line-height: normal;
  color: var(--ddr-teal);
  text-decoration: none;
  background: transparent !important;
  border: 0 !important;
  padding: 0 !important;
}

/* name */
.ddr-archive ul.products li.product > h2,
.ddr-archive ul.products li.product > h2 a {
  order: 3;
  font-family: var(--ddr-serif) !important;
  font-weight: 600 !important;
  font-variation-settings: "SOFT" 0, "WONK" 1;
  font-size: 24px !important;
  line-height: 1.15 !important;
  color: var(--ddr-teal) !important;
  margin: 6px 16px 0 !important;
  padding: 0 !important;
  text-decoration: none !important;
  text-transform: none !important;
  letter-spacing: 0 !important;
}

.ddr-archive ul.products li.product > h2 a:hover {
  text-decoration: underline !important;
}

/* botanical subtitle */
.ddr-archive ul.products li.product > .latin {
  order: 4;
  font-style: italic;
  font-size: 14px;
  line-height: normal;
  color: var(--ddr-muted);
  margin: 5px 16px 0 !important;
  padding: 0 !important;
}

/* price + size */
.ddr-archive ul.products li.product > .price {
  order: 5;
  display: flex !important;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 8px;
  margin: auto 16px 0 !important;
  padding: 12px 0 0 !important;
  color: var(--ddr-teal) !important;
  font-size: 21px !important;
  font-weight: 600 !important;
  line-height: normal !important;
}

.ddr-archive ul.products li.product > .price .woocommerce-Price-amount {
  font-size: inherit;
  font-weight: inherit;
  color: inherit;
}

.ddr-archive ul.products li.product > .price .is-quote {
  font-size: 16px;
  font-style: italic;
  font-weight: 400;
  color: var(--ddr-muted);
}

.ddr-archive ul.products li.product > .price .vol {
  color: var(--ddr-muted) !important;
  font-size: 14px !important;
  font-weight: 400 !important;
  white-space: nowrap;
}

/* actions */
.ddr-archive ul.products li.product > .ct-woo-card-actions {
  order: 6;
  display: block !important;
  opacity: 1 !important;
  visibility: visible !important;
  margin: 10px 16px 16px !important;
  padding: 0 !important;
  background: transparent !important;
  border: 0 !important;
  width: auto !important;
}

.ddr-archive ul.products li.product .actions {
  display: flex !important;
  gap: 10px !important;
  width: 100%;
}

/* WooCommerce's AJAX success handler injects a third link (.added_to_cart)
   into this same row. It must share the pill geometry or it lands as a square
   55px block beside two rounded 40px buttons. */
.ddr-archive ul.products li.product .actions .btn,
.ddr-archive ul.products li.product .actions .button,
.ddr-archive ul.products li.product .actions .added_to_cart {
  flex: 1 1 0 !important;
  min-width: 0 !important;
  height: 40px !important;
  border-radius: 999px !important;
  border: 1px solid var(--ddr-teal) !important;
  font-size: 15px !important;
  font-weight: 600 !important;
  font-family: var(--ddr-sans) !important;
  white-space: nowrap !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 0 !important;
  min-height: 0 !important;
  line-height: 1 !important;
  text-decoration: none !important;
  text-transform: none !important;
  letter-spacing: 0 !important;
  box-shadow: none !important;
  margin: 0 !important;
  transition: background 0.15s, color 0.15s;
}

.ddr-archive ul.products li.product .actions .btn.solid {
  background: var(--ddr-teal) !important;
  color: var(--ddr-cream) !important;
}

.ddr-archive ul.products li.product .actions .btn.solid:hover {
  background: #003a3d !important;
  color: var(--ddr-cream) !important;
}

.ddr-archive ul.products li.product .actions .btn.outline,
.ddr-archive ul.products li.product .actions .button {
  background: var(--ddr-cream) !important;
  color: var(--ddr-teal) !important;
}

.ddr-archive ul.products li.product .actions .btn.outline:hover,
.ddr-archive ul.products li.product .actions .button:hover {
  background: var(--ddr-teal) !important;
  color: var(--ddr-cream) !important;
}

/* "View cart" only exists after an add-to-cart, so give it the solid variant
   explicitly (it carries neither .btn.solid nor .button). */
.ddr-archive ul.products li.product .actions .added_to_cart {
  background: var(--ddr-teal) !important;
  color: var(--ddr-cream) !important;
}

.ddr-archive ul.products li.product .actions .added_to_cart:hover {
  background: #003a3d !important;
  color: var(--ddr-cream) !important;
}

/* On a 320px viewport the three-pill row is 248px wide -> ~76px per button,
   while "Add to cart" at 15px needs ~77px. Trim the type ONLY in the
   post-add-to-cart state; the normal two-button row keeps its 15px labels. */
@media (max-width: 360px) {
  .ddr-archive ul.products li.product .actions:has(.added_to_cart) .btn,
  .ddr-archive ul.products li.product .actions:has(.added_to_cart) .button,
  .ddr-archive ul.products li.product .actions:has(.added_to_cart) .added_to_cart {
    font-size: 14px !important;
  }
}

.ddr-archive ul.products li.product .actions .button.loading {
  opacity: 0.7;
}

.ddr-archive ul.products li.product .actions .button.added::after {
  display: none !important;
}

/* wishlist button is not part of this design */
.ddr-archive ul.products li.product > .tinv-wraper {
  display: none !important;
}

/* ------------------------------------------------------------- sidebar --- */
.ddr-archive .ct-sidebar {
  position: sticky;
  top: 24px;
  align-self: start;
  color: var(--ddr-teal);
}

.ddr-archive .ct-sidebar .ct-widget,
.ddr-archive .ct-sidebar .widget {
  background: transparent;
  padding: 0;
  margin: 0 0 24px;
}

.ddr-archive .ct-sidebar .widget-title,
.ddr-archive .ct-sidebar h2,
.ddr-archive .ct-sidebar h5,
.ddr-archive .ct-sidebar .wp-block-heading {
  font-family: var(--ddr-sans) !important;
  font-size: 14px !important;
  font-weight: 600 !important;
  letter-spacing: 1.12px !important;
  text-transform: uppercase !important;
  color: var(--ddr-teal) !important;
  margin: 0 0 14px !important;
  line-height: normal !important;
}

.ddr-archive .ct-sidebar .wp-block-heading span {
  color: var(--ddr-teal) !important;
}

.ddr-archive .ct-sidebar ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ddr-archive .ct-sidebar ul li a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 42px;
  padding: 0 12px;
  background: var(--ddr-cream);
  border: 1px solid var(--ddr-line);
  border-radius: 8px;
  font-size: 15px;
  color: var(--ddr-teal);
  text-decoration: none;
  transition: border-color 0.15s;
}

.ddr-archive .ct-sidebar ul li a:hover,
.ddr-archive .ct-sidebar ul li.current-cat a {
  border-color: var(--ddr-teal);
}

.ddr-archive .ct-sidebar ul li.current-cat a {
  font-weight: 600;
}

/* ---- filter panel (rendered by inc/ddr-shop.php) ---- */
/* The Categories block widget would duplicate this panel; hide just that one
   widget rather than every block widget in the area. */
.ddr-archive .ct-sidebar #block-11 {
  display: none !important;
}

.ddr-archive .ddr-filters {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.ddr-archive .ddr-filters .filter-title {
  min-height: 48px;
  border: 1px solid var(--ddr-line);
  border-radius: 8px;
  padding: 0 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 18px;
  font-weight: 600;
  color: var(--ddr-teal);
}

/* The body is always visible on desktop; the 1024px breakpoint below collapses
   it behind the toggle. Keeping it in one wrapper means the hide/show never
   has to know how many filter groups exist. */
.ddr-archive .ddr-filters .ddr-filter-body {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* Reset theme button styles so the "Filters" bar keeps its original look.
   On desktop it is decorative (pointer-events: none); on mobile JS turns it
   into a real disclosure button. */
.ddr-archive .ddr-filters .ft-toggle {
  flex: 1 1 auto;
  align-self: stretch;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 0;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  background: transparent !important;
  color: inherit !important;
  font: inherit !important;
  text-align: left;
  -webkit-appearance: none;
  appearance: none;
  cursor: default;
  pointer-events: none;
}

.ddr-archive .ddr-filters .ft-toggle:focus-visible {
  outline: 2px solid var(--ddr-teal);
  outline-offset: 3px;
}

.ddr-archive .ddr-filters .ft-chevron {
  display: none;
  width: 9px;
  height: 9px;
  flex: 0 0 auto;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  transition: transform 0.2s ease;
}

.ddr-archive .ddr-filters .ft-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--ddr-teal);
  color: var(--ddr-cream);
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
}

.ddr-archive .ddr-filters .ft-label {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ddr-archive .ddr-filters .ft-bars {
  width: 16px;
  height: 2px;
  background: currentColor;
  position: relative;
  display: block;
}

.ddr-archive .ddr-filters .ft-bars::before,
.ddr-archive .ddr-filters .ft-bars::after {
  content: "";
  position: absolute;
  left: 0;
  width: 16px;
  height: 2px;
  background: currentColor;
}

.ddr-archive .ddr-filters .ft-bars::before {
  top: -5px;
}

.ddr-archive .ddr-filters .ft-bars::after {
  top: 5px;
}

.ddr-archive .ddr-filters .ft-clear {
  font-size: 14px;
  font-weight: 600;
  color: var(--ddr-teal);
  text-decoration: underline;
}

.ddr-archive .ddr-filters .categories {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ddr-archive .ddr-filters .categories-title {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 1.12px;
  text-transform: uppercase;
  color: var(--ddr-teal);
  margin: 0 0 8px;
}

.ddr-archive .ddr-filters .category {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 42px;
  padding: 0 12px;
  background: var(--ddr-cream);
  border: 1px solid var(--ddr-line);
  border-radius: 8px;
  font-size: 15px;
  color: var(--ddr-teal);
  text-decoration: none;
  transition: border-color 0.15s;
}

.ddr-archive .ddr-filters .category:hover,
.ddr-archive .ddr-filters .category.active {
  border-color: var(--ddr-teal);
}

.ddr-archive .ddr-filters .category.active {
  font-weight: 600;
}

.ddr-archive .ddr-filters .category .count {
  font-size: 12px;
  font-weight: 400;
  color: var(--ddr-muted);
}

/* Price option counts sit flush right, on the same baseline as the label, so
   the four buckets read as a column of figures rather than ragged text. */
.ddr-archive .ddr-filters .filter-option .count {
  margin-left: auto;
  font-size: 12px;
  font-weight: 400;
  color: var(--ddr-muted);
  font-variant-numeric: tabular-nums;
}

.ddr-archive .ddr-filters .group {
  border-top: 1px solid var(--ddr-line);
  padding-top: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.ddr-archive .ddr-filters .group-head {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: var(--ddr-teal);
}

.ddr-archive .ddr-filters .filter-option {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  color: var(--ddr-teal);
  text-decoration: none;
  cursor: pointer;
}

.ddr-archive .ddr-filters .checkbox {
  width: 17px;
  height: 17px;
  min-width: 17px;
  border: 1px solid var(--ddr-teal);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.ddr-archive .ddr-filters .filter-option.is-checked .checkbox {
  background: var(--ddr-teal);
}

.ddr-archive .ddr-filters .filter-option.is-checked .checkbox::after {
  content: "";
  width: 9px;
  height: 5px;
  border-left: 2px solid var(--ddr-cream);
  border-bottom: 2px solid var(--ddr-cream);
  transform: translateY(-1px) rotate(-45deg);
}

.ddr-archive .ddr-filters .filter-option.is-checked .opt-label {
  font-weight: 600;
}

.ddr-archive .ddr-filters .availability {
  border-top: 1px solid var(--ddr-line);
  padding-top: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 15px;
  color: var(--ddr-teal);
}

.ddr-archive .ddr-filters .switch {
  width: 36px;
  height: 20px;
  border-radius: 999px;
  border: 1px solid var(--ddr-teal);
  background: var(--ddr-cream);
  padding: 2px;
  display: flex;
  align-items: center;
  flex: none;
  box-sizing: border-box;
  transition: background 0.15s;
}

.ddr-archive .ddr-filters .switch::before {
  content: "";
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: var(--ddr-teal);
  transition: transform 0.15s, background 0.15s;
  display: block;
}

.ddr-archive .ddr-filters .switch.on {
  background: var(--ddr-teal);
}

.ddr-archive .ddr-filters .switch.on::before {
  background: var(--ddr-cream);
  transform: translateX(16px);
}

/* ---------------------------------------------------------- pagination --- */
/* Blocksy renders its own pagination (nav.ct-pagination), not WooCommerce's. */
.ddr-archive .ct-pagination {
  margin-top: 40px !important;
  display: flex !important;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.ddr-archive .ct-pagination > div {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.ddr-archive .ct-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--ddr-line);
  border-radius: 8px;
  background: var(--ddr-cream);
  color: var(--ddr-teal);
  font-size: 15px;
  line-height: 1;
  text-decoration: none;
  transition: border-color 0.15s, background 0.15s, color 0.15s;
}

.ddr-archive .ct-pagination .page-numbers:hover {
  border-color: var(--ddr-teal);
}

.ddr-archive .ct-pagination .page-numbers.current {
  background: var(--ddr-teal);
  border-color: var(--ddr-teal);
  color: var(--ddr-cream);
  font-weight: 600;
}

.ddr-archive .ct-pagination .page-numbers.dots {
  border-color: transparent;
  background: transparent;
}

.ddr-archive .ct-pagination .page-numbers svg {
  width: 9px;
  height: 9px;
}

/* ------------------------------------------------------------ responsive --- */
@keyframes ddr-filter-in {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: none; }
}

@media (max-width: 1024px) {
  /* Stacked layout: tighten the hero -> Filters bar distance. It used to be
     72px on a 390px screen (hero 18 + wrapper 4 + Blocksy grid 50). */
  .ddr-archive [data-sidebar] {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 20px !important;
    padding-top: 16px !important;
  }

  .ddr-archive .ddr-hero {
    padding-bottom: 12px;
  }

  /* On phones Blocksy centres every flex child of the card (align-items:center),
     so .ct-woo-card-actions shrink-wraps to ~117px. With two 15px labels that
     leaves ~54px per pill and "Add to cart" renders outside its border. Stretch
     the wrapper back to the card's inner width (margins are subtracted). */
  .ddr-archive ul.products li.product > .ct-woo-card-actions {
    align-self: stretch !important;
    width: auto !important;
  }

  /* Filters stay reachable on phones: Blocksy hides the sidebar below md with
     .ct-hidden-sm / .ct-hidden-md, and an archive without filters is useless. */
  .ddr-archive [data-sidebar] > aside {
    grid-column: 1 !important;
    grid-row: 1 !important;
    display: block !important;
  }

  .ddr-archive [data-sidebar] > aside.ct-hidden-sm,
  .ddr-archive [data-sidebar] > aside.ct-hidden-md {
    display: block !important;
  }

  .ddr-archive [data-sidebar] > section {
    grid-column: 1 !important;
    grid-row: 2 !important;
  }

  .ddr-archive .ct-sidebar {
    position: static;
  }

  /* Stacked layout: the sidebar sits above the grid, so an always-open panel
     buries the first products below the fold. Hidden until "Filters" is tapped. */
  .ddr-archive .ddr-filters .ft-toggle {
    cursor: pointer;
    pointer-events: auto;
  }

  .ddr-archive .ddr-filters .ft-chevron {
    display: block;
  }

  .ddr-archive .ddr-filters .ddr-filter-body {
    display: none;
  }

  .ddr-archive .ddr-filters.is-open .ddr-filter-body {
    display: flex;
    animation: ddr-filter-in 0.18s ease-out;
  }

  .ddr-archive .ddr-filters.is-open .ft-chevron {
    transform: rotate(225deg);
  }

  .ddr-archive .ddr-filters.is-open .filter-title {
    border-color: var(--ddr-teal);
    background: rgba(0, 78, 82, 0.04);
  }

  .ddr-archive ul.products {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .ddr-archive .ddr-hero-title {
    font-size: 36px;
  }
}

@media (max-width: 640px) {
  .ddr-archive ul.products {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 18px !important;
  }

  .ddr-archive .ddr-hero-title {
    font-size: 30px;
  }

  .ddr-archive .ddr-hero {
    padding-bottom: 8px;
  }

  .ddr-archive ul.products li.product > figure {
    height: 250px;
  }

  .ddr-archive .ddr-toolbar {
    flex-wrap: wrap;
  }

  /* Blocksy hides the result count on phones. With the filter panel collapsed
     it is the only clue to what the current filter matched, so bring it back. */
  .ddr-archive .ddr-toolbar .woocommerce-result-count {
    display: block !important;
    width: 100%;
    margin: 0 0 4px !important;
  }

  .ddr-archive form.woocommerce-ordering,
  .ddr-archive .woocommerce-ordering {
    width: 100%;
  }

  .ddr-archive form.woocommerce-ordering select,
  .ddr-archive .woocommerce-ordering select {
    width: 100% !important;
    min-width: 0 !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ddr-archive * {
    transition: none !important;
    animation: none !important;
  }
}
