/**
 * Homepage v3 — compact middle layout (PHP-injected)
 * Scoped: body.hipopo-hp-v3
 */

/* Hide legacy oversized Elementor blocks */
.hipopo-hp-v3 .hp-section.hp-categories,
.hipopo-hp-v3 .hp-products-section {
  display: none !important;
}

.hipopo-hp-v3 .hp-v3-middle {
  position: relative;
  z-index: 2;
}

.hipopo-hp-v3 .hp-v3-block {
  padding: 16px 0 20px;
}

.hipopo-hp-v3 .hp-v3-picks {
  padding-block: 20px 24px;
  background: linear-gradient(180deg, #f6fcff 0%, #fff 100%);
}

.hipopo-hp-v3 .hp-v3-split--dog {
  background: #fff;
}

.hipopo-hp-v3 .hp-v3-split--cat {
  background: linear-gradient(180deg, #f6fcff 0%, #fff 100%);
}

.hipopo-hp-v3 .hp-v3-blog {
  background: linear-gradient(180deg, #fff 0%, #eef9ff 100%);
  padding-bottom: 28px;
}

.hipopo-hp-v3 .hp-v3-picks .hp-v3-product-grid--carousel ul.products {
  display: flex !important;
  flex-wrap: nowrap !important;
  overflow-x: auto !important;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  grid-template-columns: none !important;
  gap: 12px !important;
  padding-bottom: 8px;
  scrollbar-width: thin;
}

.hipopo-hp-v3 .hp-v3-picks .hp-v3-product-grid--carousel ul.products li.product {
  flex: 0 0 calc((100% - 60px) / 6);
  min-width: 168px;
  max-width: 220px;
  scroll-snap-align: start;
  min-height: 268px;
  padding: 12px 10px 14px !important;
}

.hipopo-hp-v3 .hp-v3-picks .hp-v3-product-grid--carousel ul.products li.product img {
  height: 100px !important;
}

.hipopo-hp-v3 .hp-v3-picks .hp-v3-product-grid--carousel .woocommerce-loop-product__title {
  font-size: 13px !important;
}

.hipopo-hp-v3 .hp-v3-picks .hp-v3-product-grid--carousel .price {
  font-size: 14px !important;
}

.hipopo-hp-v3 .hp-v3-picks__scroll-hint {
  display: none;
  margin: 8px 0 0;
  color: #058ee8;
  font-size: 13px;
  font-weight: 800;
  text-align: left;
}

@media (max-width: 1280px) {
  .hipopo-hp-v3 .hp-v3-picks .hp-v3-product-grid--carousel ul.products li.product {
    flex: 0 0 calc((100% - 36px) / 4);
  }

  .hipopo-hp-v3 .hp-v3-picks__scroll-hint {
    display: block;
  }
}

.hipopo-hp-v3 .hp-v3-block__head {
  text-align: right;
  margin-bottom: 14px;
}

.hipopo-hp-v3 .hp-v3-block__title {
  margin: 0;
  color: #061d44;
  font-size: clamp(22px, 2.2vw, 30px);
  font-weight: 950;
  line-height: 1.15;
}

.hipopo-hp-v3 .hp-v3-block__sub {
  margin: 6px 0 0;
  color: #4d6f92;
  font-size: 14px;
  font-weight: 700;
}

/* Brands — compact */
.hipopo-hp-v3 .hp-v3-middle .hp-brands-showcase {
  margin: 0;
  padding: 14px 0 8px;
}

.hipopo-hp-v3 .hp-brands-showcase__head {
  text-align: right;
  margin-bottom: 12px;
}

.hipopo-hp-v3 .hp-brands-showcase__kicker {
  margin: 0 0 4px;
  color: #058ee8;
  font-size: 13px;
  font-weight: 900;
}

.hipopo-hp-v3 .hp-brands-showcase__title {
  margin: 0;
  color: #061d44;
  font-size: clamp(20px, 2vw, 28px);
  font-weight: 950;
  line-height: 1.15;
}

.hipopo-hp-v3 .hp-brands-showcase__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.hipopo-hp-v3 .hp-brands-showcase__card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 16px;
  text-decoration: none;
  color: inherit;
  border: 1px solid rgba(5, 142, 232, 0.1);
  box-shadow: 0 10px 24px rgba(2, 80, 140, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  background: #fff;
}

.hipopo-hp-v3 .hp-brands-showcase__card:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 32px rgba(2, 80, 140, 0.12);
}

.hipopo-hp-v3 .hp-brands-showcase__media img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.hipopo-hp-v3 .hp-brands-showcase__copy {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 12px 12px;
  text-align: right;
}

.hipopo-hp-v3 .hp-brands-showcase__copy strong {
  color: #061d44;
  font-size: 15px;
  font-weight: 950;
}

.hipopo-hp-v3 .hp-brands-showcase__copy span {
  color: #4d6f92;
  font-size: 12px;
  font-weight: 700;
}

/* Tabs */
.hipopo-hp-v3 .hp-v3-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.hipopo-hp-v3 .hp-v3-tabs__btn {
  min-height: 40px;
  padding: 0 20px;
  border-radius: 999px;
  border: 1.5px solid rgba(0, 161, 216, 0.35);
  background: #f3fbff;
  color: #064276;
  font-weight: 900;
  font-size: 14px;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.hipopo-hp-v3 .hp-v3-tabs__btn.is-active {
  background: linear-gradient(180deg, #1bd8ff, #0787da);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 8px 18px rgba(0, 139, 220, 0.2);
}

.hipopo-hp-v3 .hp-v3-tab-panel[hidden] {
  display: none !important;
}

/* Product grids — reset WooCommerce floats/columns */
.hipopo-hp-v3 .hp-v3-product-grid .woocommerce {
  width: 100%;
  margin: 0;
}

.hipopo-hp-v3 .hp-v3-product-grid ul.products {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 12px !important;
  margin: 0 !important;
  padding: 0 !important;
  list-style: none;
  width: 100% !important;
  clear: both !important;
}

.hipopo-hp-v3 .hp-v3-product-grid ul.products::before,
.hipopo-hp-v3 .hp-v3-product-grid ul.products::after {
  display: none !important;
  content: none !important;
}

.hipopo-hp-v3 .hp-v3-product-grid ul.products li.product {
  width: 100% !important;
  max-width: none !important;
  float: none !important;
  clear: none !important;
  margin: 0 !important;
  padding: 14px 12px 16px !important;
  border-radius: 14px !important;
  background: #fff !important;
  box-shadow: 0 10px 24px rgba(2, 80, 140, 0.1) !important;
  min-height: 0;
  display: flex !important;
  flex-direction: column;
  align-items: stretch;
}

.hipopo-hp-v3 .hp-v3-product-grid ul.products li.product img {
  height: 120px !important;
  object-fit: contain !important;
  margin-bottom: 8px !important;
}

.hipopo-hp-v3 .hp-v3-product-grid .woocommerce-loop-product__title {
  min-height: 0;
  color: #0c2454 !important;
  font-weight: 800 !important;
  font-size: 14px !important;
  line-height: 1.35 !important;
}

.hipopo-hp-v3 .hp-v3-product-grid .price {
  color: #063f90 !important;
  font-weight: 950 !important;
}

.hipopo-hp-v3 .hp-v3-product-grid a.button {
  width: 100%;
  border-radius: 999px !important;
  background: linear-gradient(180deg, #1bd8ff, #0787da) !important;
  color: #fff !important;
  font-weight: 900 !important;
  font-size: 13px !important;
}

.hipopo-hp-v3 .hp-v3-product-grid--split ul.products {
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
}

.hipopo-hp-v3 .hp-v3-product-grid--split ul.products li.product {
  padding: 10px 8px 12px !important;
}

.hipopo-hp-v3 .hp-v3-product-grid--split ul.products li.product img {
  height: 88px !important;
}

.hipopo-hp-v3 .hp-v3-product-grid--split .woocommerce-loop-product__title {
  min-height: 36px;
  font-size: 12px !important;
}

.hipopo-hp-v3 .hp-v3-product-grid--split .price {
  font-size: 14px !important;
}

.hipopo-hp-v3 .hp-v3-product-grid--split a.button {
  min-height: 36px;
  font-size: 12px !important;
  padding: 0 8px !important;
}

/* Path duo — banners + leading sub-category links */
.hipopo-hp-v3 .hp-v3-path-duo {
  padding: 18px 0 22px;
  background: #fff;
}

.hipopo-hp-v3 .hp-v3-path-duo__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  direction: ltr;
}

.hipopo-hp-v3 .hp-v3-path-duo__col {
  display: grid;
  gap: 12px;
  align-items: center;
  min-width: 0;
}

.hipopo-hp-v3 .hp-v3-path-duo__col--dog {
  grid-template-columns: minmax(150px, 42%) minmax(0, 1fr);
}

.hipopo-hp-v3 .hp-v3-path-duo__col--cat {
  grid-template-columns: minmax(0, 1fr) minmax(150px, 42%);
}

.hipopo-hp-v3 .hp-v3-path-duo__banner {
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: 16px;
  border: 1px solid rgba(5, 142, 232, 0.1);
  box-shadow: 0 10px 24px rgba(2, 80, 140, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  background: #f6fcff;
  min-height: 132px;
  padding: 6px;
}

.hipopo-hp-v3 .hp-v3-path-duo__banner:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 28px rgba(2, 80, 140, 0.12);
}

.hipopo-hp-v3 .hp-v3-path-duo__banner img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 120px;
  object-fit: contain;
  object-position: center;
}

.hipopo-hp-v3 .hp-v3-path-duo__links {
  direction: rtl;
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: right;
  min-width: 0;
}

.hipopo-hp-v3 .hp-v3-path-duo__links a {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 12px;
  background: #f6fcff;
  border: 1px solid rgba(0, 161, 216, 0.14);
  color: #061d44;
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.hipopo-hp-v3 .hp-v3-path-duo__links a::before {
  content: "←";
  color: #058ee8;
  font-size: 12px;
  font-weight: 900;
}

.hipopo-hp-v3 .hp-v3-path-duo__links a:hover {
  background: #fff;
  border-color: rgba(0, 161, 216, 0.28);
  color: #058ee8;
}

.hipopo-hp-v3 .hp-v3-path-duo__links-hot {
  background: rgba(255, 47, 153, 0.08) !important;
  border-color: rgba(255, 47, 153, 0.22) !important;
  color: #c4146e !important;
}

.hipopo-hp-v3 .hp-v3-path-duo__links-hot::before {
  color: #ff2f99 !important;
}

/* Split rows — banner + one product row */
.hipopo-hp-v3 .hp-v3-split {
  padding-block: 14px 18px;
}

.hipopo-hp-v3 .hp-v3-split__grid {
  display: grid;
  grid-template-columns: minmax(180px, 26%) minmax(0, 1fr);
  gap: 14px;
  align-items: center;
}

.hipopo-hp-v3 .hp-v3-split--cat .hp-v3-split__grid {
  grid-template-columns: minmax(0, 1fr) minmax(180px, 26%);
}

.hipopo-hp-v3 .hp-v3-split__banner {
  display: block;
  overflow: hidden;
  border-radius: 16px;
  border: 1px solid rgba(5, 142, 232, 0.1);
  box-shadow: 0 10px 22px rgba(2, 80, 140, 0.08);
  transition: transform 0.2s ease;
  background: #eafaff;
  align-self: center;
}

.hipopo-hp-v3 .hp-v3-split__banner:hover {
  transform: translateY(-1px);
}

.hipopo-hp-v3 .hp-v3-split__banner img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 230px;
  aspect-ratio: 4 / 5;
  object-fit: contain;
  object-position: center;
}

.hipopo-hp-v3 .hp-v3-split__products {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
  justify-content: center;
}

.hipopo-hp-v3 .hp-v3-split__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  text-align: right;
}

.hipopo-hp-v3 .hp-v3-split__head h3 {
  margin: 0;
  color: #061d44;
  font-size: 18px;
  font-weight: 950;
}

.hipopo-hp-v3 .hp-v3-split__head a {
  color: #058ee8;
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}

.hipopo-hp-v3 .hp-v3-split__head a:hover {
  text-decoration: underline;
}

/* Blog placeholders */
.hipopo-hp-v3 .hp-v3-blog__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.hipopo-hp-v3 .hp-v3-blog-card {
  position: relative;
  padding: 18px 16px;
  border-radius: 16px;
  background: linear-gradient(180deg, #f6fcff 0%, #fff 100%);
  border: 1px solid rgba(0, 161, 216, 0.16);
  box-shadow: 0 10px 24px rgba(2, 80, 140, 0.07);
  text-align: right;
}

.hipopo-hp-v3 .hp-v3-blog-card__tag {
  display: inline-flex;
  margin-bottom: 10px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255, 47, 153, 0.12);
  color: #d41472;
  font-size: 11px;
  font-weight: 900;
}

.hipopo-hp-v3 .hp-v3-blog-card h3 {
  margin: 0 0 8px;
  color: #061d44;
  font-size: 16px;
  font-weight: 950;
  line-height: 1.35;
}

.hipopo-hp-v3 .hp-v3-blog-card p {
  margin: 0;
  color: #4d6f92;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.45;
}

.hipopo-hp-v3 .hp-v3-blog-card--soon {
  opacity: 0.92;
}

@media (max-width: 1100px) {

  .hipopo-hp-v3 .hp-v3-split__grid,
  .hipopo-hp-v3 .hp-v3-split--cat .hp-v3-split__grid {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .hipopo-hp-v3 .hp-v3-split__banner {
    max-width: 360px;
    margin-inline: auto;
  }

  .hipopo-hp-v3 .hp-v3-split__banner img {
    max-height: 150px;
    aspect-ratio: 16 / 9;
  }

  .hipopo-hp-v3 .hp-v3-product-grid--split ul.products {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  }

  .hipopo-hp-v3 .hp-v3-blog__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 767px) {
  .hipopo-hp-v3 .hp-brands-showcase__grid {
    grid-template-columns: 1fr;
  }

  .hipopo-hp-v3 .hp-v3-path-duo__grid {
    grid-template-columns: 1fr;
    direction: rtl;
  }

  .hipopo-hp-v3 .hp-v3-path-duo__col--dog,
  .hipopo-hp-v3 .hp-v3-path-duo__col--cat {
    grid-template-columns: 1fr;
  }

  .hipopo-hp-v3 .hp-v3-path-duo__col--cat .hp-v3-path-duo__banner {
    order: 1;
  }

  .hipopo-hp-v3 .hp-v3-path-duo__col--cat .hp-v3-path-duo__links {
    order: 2;
  }

  .hipopo-hp-v3 .hp-v3-path-duo__banner {
    min-height: 112px;
  }

  .hipopo-hp-v3 .hp-v3-path-duo__banner img {
    max-height: 104px;
  }

  .hipopo-hp-v3 .hp-v3-path-duo__links {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .hipopo-hp-v3 .hp-v3-split__grid,
  .hipopo-hp-v3 .hp-v3-split--cat .hp-v3-split__grid {
    grid-template-columns: 1fr;
  }

  .hipopo-hp-v3 .hp-v3-split--dog .hp-v3-split__banner {
    order: 1;
  }

  .hipopo-hp-v3 .hp-v3-split--dog .hp-v3-split__products {
    order: 2;
  }

  .hipopo-hp-v3 .hp-v3-split--cat .hp-v3-split__products {
    order: 1;
  }

  .hipopo-hp-v3 .hp-v3-split--cat .hp-v3-split__banner {
    order: 2;
  }

  .hipopo-hp-v3 .hp-v3-split__banner img {
    max-height: 140px;
    aspect-ratio: 16 / 9;
  }

  .hipopo-hp-v3 .hp-v3-picks .hp-v3-product-grid--carousel ul.products li.product {
    flex: 0 0 min(68vw, 220px) !important;
    scroll-snap-align: start;
  }

  .hipopo-hp-v3 .hp-v3-picks .hp-v3-product-grid--carousel ul.products::-webkit-scrollbar {
    display: none;
  }

  .hipopo-hp-v3 .hp-v3-product-grid--split ul.products {
    display: flex !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    grid-template-columns: none !important;
    gap: 10px !important;
    padding-bottom: 6px;
    scrollbar-width: none;
  }

  .hipopo-hp-v3 .hp-v3-product-grid--split ul.products::-webkit-scrollbar {
    display: none;
  }

  .hipopo-hp-v3 .hp-v3-product-grid--split ul.products li.product {
    flex: 0 0 min(68vw, 220px) !important;
    scroll-snap-align: start;
  }

  .hipopo-hp-v3 .hp-v3-blog__grid {
    grid-template-columns: 1fr;
  }

  .hipopo-hp-v3 .hp-v3-tabs {
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: 4px;
    scrollbar-width: none;
  }

  .hipopo-hp-v3 .hp-v3-tabs::-webkit-scrollbar {
    display: none;
  }

  .hipopo-hp-v3 .hp-v3-tabs__btn {
    flex: 0 0 auto;
  }
}
