/* Keep sticky header visible while scrolled (theme only shows it on scroll-up). */
body.is-scrolled .header .fixed-header.style-absolute,
.header .fixed-header.style-absolute.mcibe-sticky-on {
  pointer-events: all !important;
  transform: translateY(0) !important;
  opacity: 1 !important;
  transition: none !important;
  visibility: visible !important;
  z-index: 9999 !important;
}

/*
 * Theme page titles use background-attachment: fixed, which fights position:fixed
 * headers on inner pages (home uses a swiper hero instead).
 */
.page-title {
  background-attachment: scroll !important;
}

/* Replace corn/wheat nav markers with Mcibe palm tree */
.header .header-inner .nav-list .item::before,
.mobile-nav-wrap .inner-mobile-nav .mobile-main-nav #menu-mobile-menu .menu-item-has-children-mobile .sub-menu-mobile .menu-item a::before,
.icon-wheat-grains:before,
.icon-barley:before {
  content: "" !important;
  font-family: inherit !important;
  display: inline-block;
  width: 1em;
  height: 1em;
  background-color: currentColor;
  -webkit-mask: url("../../images/logo/palm-tree.svg") center / contain no-repeat;
  mask: url("../../images/logo/palm-tree.svg") center / contain no-repeat;
}

.header .header-inner .nav-list .item::before {
  width: 24px;
  height: 24px;
  font-size: 24px;
}

.mobile-nav-wrap .inner-mobile-nav .mobile-main-nav #menu-mobile-menu .menu-item-has-children-mobile .sub-menu-mobile .menu-item a::before {
  width: 14px;
  height: 14px;
  vertical-align: -2px;
  margin-right: 2px;
}

/* Reusable palm icon: <i class="icon-palm"></i> */
.icon-palm {
  display: inline-block;
  width: 1em;
  height: 1em;
  background-color: currentColor;
  -webkit-mask: url("../../images/logo/palm-tree.svg") center / contain no-repeat;
  mask: url("../../images/logo/palm-tree.svg") center / contain no-repeat;
  vertical-align: -0.125em;
}

/* Outline palm kernels: <i class="icon-palm-kernels"></i> */
.icon-palm-kernels,
.icon-palm-kernels:before {
  font-family: inherit !important;
}
.icon-palm-kernels:before {
  content: "" !important;
  display: none !important;
}
.icon-palm-kernels {
  display: inline-block;
  width: 1em;
  height: 1em;
  background-color: currentColor;
  -webkit-mask: url("../../images/logo/palm-kernels.svg") center / contain no-repeat;
  mask: url("../../images/logo/palm-kernels.svg") center / contain no-repeat;
  vertical-align: -0.125em;
}

/*
 * Home portfolio cards were designed for portrait images (~410×500).
 * Landscape Pixabay photos collapse the card height and crush the write-up
 * (theme pins .content at top: 398px). Keep a portrait frame and cover-crop.
 */
.s-box-portfolio .box-portfolio.style-4 .image {
  aspect-ratio: 410 / 500;
}
.s-box-portfolio .box-portfolio.style-4 .image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

/* Content strip sits near the bottom of the portrait frame, not a fixed px top */
@media (min-width: 992px) {
  .s-box-portfolio .box-portfolio.style-4 .content {
    top: auto;
    bottom: 20px;
    height: 81px;
  }
  .s-box-portfolio .box-portfolio.style-4:hover .content {
    top: 20px;
    bottom: 20px;
    height: calc(100% - 40px);
  }
}

/* Section heading dividers: keep rice-plant-2 footprint (81×15) */
img[src*="palm-kernels-divider"] {
  width: 81px !important;
  height: 15px !important;
  object-fit: contain;
  display: inline-block;
  vertical-align: middle;
}

/* Home counter: two stats centered with divider between them */
.s-counter .wg-counter {
  justify-content: center;
  align-items: stretch;
  gap: 0;
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}
.s-counter .wg-counter .counter-item {
  max-width: 280px;
  padding: 0 48px;
  justify-content: flex-start;
  align-items: center;
}
.s-counter .wg-counter .counter-item .icon {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 40px;
  margin-bottom: 38px;
}
.s-counter .wg-counter .counter {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 65px;
  margin-bottom: 20px;
}
.s-counter .wg-counter .odometer {
  left: 0 !important;
  width: auto;
}
.s-counter .wg-counter .odometer .odometer-value {
  text-align: center !important;
}
.s-counter .wg-counter .odometer .odometer-formatting-mark {
  display: none !important;
}
.s-counter .wg-counter .sub {
  white-space: nowrap;
  text-align: center;
  width: 100%;
  margin: 0;
  line-height: 1.3;
}
@media (max-width: 991px) {
  .s-counter .wg-counter {
    max-width: 100%;
  }
  .s-counter .wg-counter .counter-item {
    padding: 0 24px;
  }
}
@media (max-width: 575px) {
  .s-counter .wg-counter .counter-item {
    padding: 0 15px;
  }
  .s-counter .wg-counter .counter-item:not(:last-child) {
    border-right: none;
    border-bottom: 1px dashed var(--Border-5);
    padding-bottom: 30px;
    margin-bottom: 10px;
  }
}

/* Expertise cards: max-width 383px sits left in wider cols — center them */
.s-service .box-icon.style-6 {
  margin-left: auto;
  margin-right: auto;
}
.s-service .box-icon.style-6 .caption::after {
  left: 50%;
  transform: translateX(-50%);
}

/* Farm tour cards: large bottom gap only on desktop */
@media (min-width: 992px) {
  .s-farm-tour {
    padding-bottom: 150px;
  }
}
