/* Shared component styles. Gutenberg and GeneratePress consume the same definitions. */
:is(.gm-product-directory,.is-style-gm-product-directory) {
  display: flex;
  flex-direction: column;
  gap: 48px;
  padding-top: 40px;
}

.gm-directory-category {
  scroll-margin-top: 35px;
}

.gm-directory-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: nowrap;
  white-space: nowrap;
  font-size: clamp(28px,3vw,42px);
  line-height: 1.2;
  margin: 0 0 22px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--fsc-line);
}

.gm-directory-heading .gm-coming-soon {
  margin: 0;
  flex-shrink: 0;
  font-size: 12px;
  line-height: 1.4;
  letter-spacing: 0;
}

.gm-directory-list {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 0 50px;
}

.gm-directory-product {
  min-width: 0;
  padding: 24px 0;
  border-bottom: 1px solid var(--fsc-line);
  display: grid;
  grid-template-columns: 1fr;
  gap: 22px;
  align-items: start;
}

.gm-directory-product figure {
  margin: 0;
}

.gm-directory-product figure a {
  display: block;
}

.gm-directory-product figure img {
  display: block;
  width: 110px;
  height: 110px;
  object-fit: cover;
}

.gm-directory-product h3 {
  font-size: 25px;
  font-weight: 600;
  line-height: 1.2;
  margin: 0 0 12px;
  letter-spacing: -.02em;
}

.gm-directory-product h3 a {
  text-decoration: none;
}

.gm-directory-product h3 a:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.gm-directory-product h3 a:focus-visible {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.gm-directory-product p {
  font-size: 17px;
  line-height: 1.5;
  max-width: 42ch;
  margin: 0;
}

.gm-directory-availability {
  display: inline-block;
  margin-bottom: 12px;
  padding: 3px 9px;
  background: var(--fsc-sand);
  font-size: 12px;
  font-weight: 600;
}

.gm-mega__directory-bar {
  background: var(--fsc-sand);
  border-top: 1px solid var(--fsc-line);
}

.gm-mega__directory-bar p {
  margin: 0;
}

.gm-mega__category--future h2 {
  flex-wrap: nowrap;
  white-space: nowrap;
}

.gm-mega__category--future h2 .gm-coming-soon {
  font-size: 11px;
  padding: 5px 8px;
}

@media(max-width:767px) {
  :is(.gm-product-directory,.is-style-gm-product-directory) {
    padding-top: 28px;
    gap: 35px;
  }
}

@media(max-width:767px) {
  .gm-directory-list {
    grid-template-columns: 1fr;
    gap: 0;
  }
}

@media(max-width:767px) {
  .gm-directory-heading {
    font-size: 28px;
    gap: 10px;
  }
}

@media(max-width:767px) {
  .gm-directory-heading .gm-coming-soon {
    font-size: 11px;
    padding: 5px 8px;
  }
}

@media(max-width:767px) {
  .gm-directory-product h3 {
    font-size: 24px;
  }
}

@media(max-width:767px) {
  .gm-directory-product figure img {
    width: 85px;
    height: 85px;
  }
}

.gm-other-compost__product:not(:has(>figure)) {
  grid-template-columns: 1fr;
}

.gm-directory-product .wp-block-post-title {
  font-size: 25px;
  font-weight: 600;
  line-height: 1.2;
  margin: 0 0 12px;
  letter-spacing: -.02em;
}

.gm-directory-product .wp-block-post-featured-image img {
  width: 110px;
  height: 110px;
  object-fit: cover;
}

@media(max-width:767px) {
  .gm-directory-product .wp-block-post-title {
    font-size: 24px;
  }
}

@media(max-width:767px) {
  .gm-directory-product .wp-block-post-featured-image img {
    width: 85px;
    height: 85px;
  }
}


/* Shared wireframe component: no product photo or generated image asset. */
.is-style-gm-image-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  aspect-ratio: 4 / 3;
  min-width: 0;
  margin: 0;
  border: 1px dashed var(--fsc-sage);
  background-color: var(--fsc-paper);
  background-image: linear-gradient(to top right,transparent calc(50% - .5px),var(--fsc-line) 50%,transparent calc(50% + .5px)),linear-gradient(to bottom right,transparent calc(50% - .5px),var(--fsc-line) 50%,transparent calc(50% + .5px));
  color: var(--fsc-ink);
}
.is-style-gm-image-placeholder p {
  margin: 0;
  padding: 5px 10px;
  background: var(--fsc-paper);
  font-size: 14px;
}
.is-style-gm-image-placeholder>.wp-block-group__inner-container {display: contents;}
.gm-directory-product .is-style-gm-image-placeholder {width:110px;height:110px;aspect-ratio:1;}
@media(max-width:767px){.gm-directory-product .is-style-gm-image-placeholder{width:85px;height:85px;}}

/* Inline notices are native Paragraph + Heading blocks in a reusable Group style. */
.is-style-gm-inline-label{display:flex;align-items:center;gap:10px;flex-wrap:nowrap;}
.is-style-gm-inline-label>.wp-block-group__inner-container{display:contents;}
.is-style-gm-inline-label .wp-block-heading{margin:0;}
.is-style-gm-badge{display:inline-block;flex-shrink:0;margin:0;padding:5px 8px;background:var(--fsc-sand);color:var(--fsc-soil);font-size:12px;font-weight:600;line-height:1.4;white-space:nowrap;}
.gm-directory-heading .wp-block-heading{font-size:inherit;line-height:inherit;}
.gm-mega__label .wp-block-heading{font-size:26px;line-height:1.3;}
.gm-mega__label .is-style-gm-badge{font-size:11px;}
@media(max-width:767px){.gm-directory-heading .is-style-gm-badge{font-size:11px;}}

.gm-mega__label .is-style-gm-badge{margin:0;font-weight:600;}
/* Product-grid photography and wireframes share a consistent frame. */
.gm-mulch-grid .wp-block-post-featured-image img{aspect-ratio:4/3;object-fit:cover;}

/* Reusable native Post Template style for compact product comparisons. */
.wp-block-post-template.is-style-gm-product-grid-four{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:0 28px;}
.is-style-gm-product-grid-four>li{min-width:0;}
.is-style-gm-product-grid-four .gm-mulch-product h2{font-size:28px;line-height:1.15;}
@media(max-width:1099px){.wp-block-post-template.is-style-gm-product-grid-four{grid-template-columns:repeat(2,minmax(0,1fr));}}
@media(max-width:767px){.wp-block-post-template.is-style-gm-product-grid-four{grid-template-columns:1fr;}}

/* One synced native card serves category and all-products queries. */
.gm-product-card{min-width:0;padding-block:40px;border-bottom:1px solid var(--fsc-line);scroll-margin-top:25px;}
.gm-product-card .wp-block-post-featured-image{margin:0 0 18px;}
.gm-product-card .wp-block-post-featured-image a{display:block;}
.gm-product-card .wp-block-post-featured-image img{display:block;width:100%;height:auto;aspect-ratio:4/3;object-fit:cover;}
.gm-product-card .is-style-gm-image-placeholder{width:100%;height:auto;aspect-ratio:4/3;margin-bottom:18px;}
.gm-product-card .wp-block-post-title{margin:0 0 20px;}
.gm-product-card .wp-block-post-title a{text-decoration:none;}
.gm-product-card .wp-block-post-title a:hover{text-decoration:underline;}
.gm-product-card p{font-size:17px;line-height:1.5;}
.gm-product-card .wp-block-post-excerpt__excerpt{margin:0;}

/* Availability is secondary information, never a featured-card treatment. */
.gm-product-card :is(.gm-coming-soon,.gm-directory-availability){display:inline-block;margin:0 0 10px;padding:0;background:transparent;color:var(--fsc-soil);border:0;border-radius:0;font-size:14px;font-weight:500;line-height:1.4;}
