/* ==========================================================
   SECTION DIVIDERS
   Adds a very subtle divider only where adjacent sections use
   the same general background family.
   ========================================================== */

:root {
  --section-divider-light: rgba(11, 53, 88, 0.10);
  --section-divider-dark: rgba(244, 240, 231, 0.10);
}

/* Light-background section families */
:is(
  .categories,
  .products,
  .services,
  .testimonials,
  .blog,
  .sustainability,
  .faq,
  .story-section,
  .mission-vision-section,
  .team-section,
  .achievements-section,
  .main-services,
  .how-it-works,
  .why-choose,
  .service-testimonials,
  .faq-section,
  .filters-section,
  .products-main,
  .benefits-section,
  .products-faq,
  .contact-channels,
  .contact-main,
  .visit-section,
  .contact-faq
) {
  position: relative;
}

/* Divider between consecutive light sections */
:is(
  .categories,
  .products,
  .services,
  .testimonials,
  .blog,
  .sustainability,
  .faq,
  .story-section,
  .mission-vision-section,
  .team-section,
  .achievements-section,
  .main-services,
  .how-it-works,
  .why-choose,
  .service-testimonials,
  .faq-section,
  .filters-section,
  .products-main,
  .benefits-section,
  .products-faq,
  .contact-channels,
  .contact-main,
  .visit-section,
  .contact-faq
)
+
:is(
  .categories,
  .products,
  .services,
  .testimonials,
  .blog,
  .sustainability,
  .faq,
  .story-section,
  .mission-vision-section,
  .team-section,
  .achievements-section,
  .main-services,
  .how-it-works,
  .why-choose,
  .service-testimonials,
  .faq-section,
  .filters-section,
  .products-main,
  .benefits-section,
  .products-faq,
  .contact-channels,
  .contact-main,
  .visit-section,
  .contact-faq
)::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: min(90%, 1400px);
  height: 1px;
  transform: translateX(-50%);
  background: var(--section-divider-light);
  z-index: 5;
  pointer-events: none;
}

/* Dark-background section families */
:is(
  .hero,
  .about-hero,
  .services-hero,
  .products-hero,
  .contact-hero,
  .offer-banner,
  .webinars,
  .values-section,
  .pricing-section,
  .special-offers,
  .newsletter
) {
  position: relative;
}

/* Divider if two dark sections ever sit directly together */
:is(
  .hero,
  .about-hero,
  .services-hero,
  .products-hero,
  .contact-hero,
  .offer-banner,
  .webinars,
  .values-section,
  .pricing-section,
  .special-offers,
  .newsletter
)
+
:is(
  .hero,
  .about-hero,
  .services-hero,
  .products-hero,
  .contact-hero,
  .offer-banner,
  .webinars,
  .values-section,
  .pricing-section,
  .special-offers,
  .newsletter
)::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: min(90%, 1400px);
  height: 1px;
  transform: translateX(-50%);
  background: var(--section-divider-dark);
  z-index: 5;
  pointer-events: none;
}

@media (max-width: 700px) {
  :is(
    .categories,
    .products,
    .services,
    .testimonials,
    .blog,
    .sustainability,
    .faq,
    .story-section,
    .mission-vision-section,
    .team-section,
    .achievements-section,
    .main-services,
    .how-it-works,
    .why-choose,
    .service-testimonials,
    .faq-section,
    .filters-section,
    .products-main,
    .benefits-section,
    .products-faq,
    .contact-channels,
    .contact-main,
    .visit-section,
    .contact-faq
  )
  +
  :is(
    .categories,
    .products,
    .services,
    .testimonials,
    .blog,
    .sustainability,
    .faq,
    .story-section,
    .mission-vision-section,
    .team-section,
    .achievements-section,
    .main-services,
    .how-it-works,
    .why-choose,
    .service-testimonials,
    .faq-section,
    .filters-section,
    .products-main,
    .benefits-section,
    .products-faq,
    .contact-channels,
    .contact-main,
    .visit-section,
    .contact-faq
  )::before,
  :is(
    .hero,
    .about-hero,
    .services-hero,
    .products-hero,
    .contact-hero,
    .offer-banner,
    .webinars,
    .values-section,
    .pricing-section,
    .special-offers,
    .newsletter
  )
  +
  :is(
    .hero,
    .about-hero,
    .services-hero,
    .products-hero,
    .contact-hero,
    .offer-banner,
    .webinars,
    .values-section,
    .pricing-section,
    .special-offers,
    .newsletter
  )::before {
    width: 90%;
  }
}
