/* ==========================================================================
   BOUTIQUE EXTRAS: badge, checkout fields, related grid, home blog, footer
   icons, live search dropdown
   ========================================================================== */

/* ---- Product card "UK Warehouse" badge: a proper pill on the photo ---- */
.boutique-product-media .boutique-badge-stock {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(255, 255, 255, 0.96);
  color: #3D7055;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1;
  padding: 6px 10px;
  border-radius: 9999px;
  border: 1px solid rgba(61, 112, 85, 0.18);
  box-shadow: 0 2px 8px rgba(31, 26, 25, 0.08);
  pointer-events: none;
}
@media (max-width: 768px) {
  .boutique-product-media .boutique-badge-stock {
    top: 6px;
    left: 6px;
    font-size: 0.5625rem;
    padding: 4px 7px;
  }
}

/* ---- Checkout: floating labels must not sit on top of the typed value ---- */
body.woocommerce-checkout .wc-block-components-text-input input[type="text"],
body.woocommerce-checkout .wc-block-components-text-input input[type="email"],
body.woocommerce-checkout .wc-block-components-text-input input[type="tel"],
body.woocommerce-checkout .wc-block-components-text-input input[type="number"],
body.woocommerce-checkout .wc-block-components-text-input input[type="password"],
body.woocommerce-checkout .wc-block-components-combobox .wc-block-components-combobox-control input.components-combobox-control__input {
  padding: 24px 16px 8px !important;
  height: 54px !important;
  line-height: 1.3 !important;
}
body.woocommerce-checkout .wc-blocks-components-select .wc-blocks-components-select__select {
  padding: 24px 40px 8px 16px !important;
  height: 54px !important;
  line-height: 1.3 !important;
}
body.woocommerce-checkout .wc-block-components-textarea textarea {
  padding: 16px !important;
}
body.woocommerce-checkout .wc-block-components-text-input label,
body.woocommerce-checkout .wc-block-components-combobox .components-base-control__label,
body.woocommerce-checkout .wc-blocks-components-select .wc-blocks-components-select__label {
  left: 16px !important;
  max-width: calc(100% - 48px) !important;
  color: #8E8480 !important;
  font-size: 0.9375rem !important;
}
body.woocommerce-checkout .wc-block-components-text-input.is-active label,
body.woocommerce-checkout .wc-block-components-text-input input:focus + label,
body.woocommerce-checkout .wc-block-components-combobox.is-active .components-base-control__label,
body.woocommerce-checkout .wc-blocks-components-select .wc-blocks-components-select__label {
  transform: translateY(6px) scale(0.75) !important;
  transform-origin: top left !important;
}
body.woocommerce-checkout .wc-block-components-order-summary-item__description .wc-block-components-product-metadata__description {
  display: none !important;
}

/* ---- Single product page ONLY: 4 related cards ---- */
body.single-product .boutique-related-grid {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 20px !important;
}
@media (max-width: 1024px) {
  body.single-product .boutique-related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 14px !important;
  }
}

/* ---- Home: bestsellers = 4 dolls + 4 prams (2 clean rows of 4) ---- */
@media (min-width: 900px) {
  .boutique-front-products-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 20px !important;
  }
}
@media (min-width: 769px) and (max-width: 899px) {
  .boutique-front-products-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

/* ---- Home: 4 blog cards ---- */
.boutique-blog-grid.boutique-blog-grid--4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}
.boutique-blog-grid--4 .boutique-blog-body {
  padding: 20px 18px 18px;
}
.boutique-blog-grid--4 .boutique-blog-title {
  font-size: 1.0625rem;
  min-height: 2.7em;
}
.boutique-blog-grid--4 .boutique-blog-excerpt {
  font-size: 0.875rem;
  -webkit-line-clamp: 3;
  margin-bottom: 16px;
}
@media (max-width: 1100px) {
  .boutique-blog-grid.boutique-blog-grid--4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 600px) {
  .boutique-blog-grid.boutique-blog-grid--4 {
    grid-template-columns: 1fr;
  }
}
.boutique-section-cta {
  text-align: center;
  margin-top: 44px;
}

/* ---- Footer + pre-footer icons (SVG, brand-coloured) ---- */
.bq-ico {
  display: inline-block;
  vertical-align: middle;
  flex-shrink: 0;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.boutique-prefooter-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 14px;
  border-radius: 50%;
  background: #F8EFEA;
  border: 1px solid rgba(197, 123, 116, 0.25);
  color: #C57B74;
  display: flex;
  align-items: center;
  justify-content: center;
}
.boutique-prefooter-icon .bq-ico {
  width: 26px;
  height: 26px;
}
.boutique-footer-line {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.8125rem;
  color: #A89F9B;
  margin: 0 0 10px;
}
.boutique-footer-line .bq-ico {
  width: 17px;
  height: 17px;
  margin-top: 1px;
  color: #C57B74;
}
.boutique-footer-line a {
  color: #E6DEDA;
  font-weight: 600;
}
.boutique-footer-line a:hover {
  color: #C57B74;
}

/* ---- Live search dropdown ---- */
.boutique-header-search.desktop-search,
.boutique-mobile-search-wrap {
  position: relative;
}
.boutique-search-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: min(680px, 94vw);
  max-height: min(78vh, 640px);
  overflow-y: auto;
  background: #FFFFFF;
  border: 1px solid #E7DFD8;
  border-radius: 14px;
  box-shadow: 0 18px 44px rgba(31, 26, 25, 0.18);
  z-index: 1200;
  text-align: left;
  -webkit-overflow-scrolling: touch;
}
.boutique-search-dropdown.active {
  display: block;
}
.boutique-mobile-search-wrap .boutique-search-dropdown {
  left: 0;
  right: 0;
  width: auto;
  top: calc(100% - 2px);
  border-radius: 0 0 14px 14px;
}
.bq-state {
  padding: 22px 18px;
  text-align: center;
  color: #8E8480;
  font-size: 0.875rem;
}
.bq-heading {
  padding: 10px 18px 6px;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #9B918E;
  background: #FAF7F5;
  border-top: 1px solid #F0E9E3;
}
.bq-item {
  position: relative;
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 12px 18px;
  border-bottom: 1px solid #F3EDE7;
  color: #1F1A19;
  text-decoration: none;
  transition: background 0.15s ease;
}
.bq-item:hover,
.bq-item.is-selected {
  background: #FAF3EE;
}
.bq-thumb {
  width: 64px;
  height: 64px;
  border-radius: 8px;
  overflow: hidden;
  background: #F9F6F3;
  border: 1px solid #F0E9E3;
}
.bq-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.bq-info {
  min-width: 0;
}
.bq-title {
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.35;
  color: #1F1A19;
  margin: 0 0 3px;
}
.bq-title strong,
.bq-excerpt strong,
.bq-cat strong {
  color: #C57B74;
  font-weight: 800;
}
.bq-excerpt {
  font-size: 0.78125rem;
  line-height: 1.45;
  color: #6E635F;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.bq-meta {
  font-size: 0.6875rem;
  font-weight: 600;
  color: #3D7055;
  margin-top: 4px;
}
.bq-price {
  text-align: right;
  font-size: 1rem;
  font-weight: 700;
  color: #1F1A19;
  white-space: nowrap;
  padding-right: 4px;
}
.bq-price del {
  display: block;
  font-size: 0.75rem;
  font-weight: 500;
  color: #9B918E;
}
.bq-price ins {
  text-decoration: none;
  color: #C57B74;
}
.bq-ribbon {
  position: absolute;
  top: 8px;
  right: 8px;
  background: #3D7055;
  color: #FFFFFF;
  font-size: 0.625rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 9999px;
}
.bq-item.has-ribbon .bq-price {
  padding-top: 14px;
}
.bq-cat {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 18px;
  font-size: 0.875rem;
  font-weight: 600;
  border-bottom: 1px solid #F3EDE7;
  color: #1F1A19;
  text-decoration: none;
}
.bq-cat:hover,
.bq-cat.is-selected {
  background: #FAF3EE;
}
.bq-cat small {
  color: #9B918E;
  font-weight: 500;
}
.bq-all {
  display: block;
  padding: 14px 18px;
  text-align: center;
  font-size: 0.875rem;
  font-weight: 700;
  color: #FFFFFF;
  background: #1F1A19;
  text-decoration: none;
  position: sticky;
  bottom: 0;
}
.bq-all:hover {
  background: #C57B74;
  color: #FFFFFF;
}
.bq-empty-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  padding: 0 18px 20px;
}
.bq-empty-links a {
  font-size: 0.8125rem;
  font-weight: 600;
  padding: 7px 14px;
  border-radius: 9999px;
  background: #F8EFEA;
  color: #AB655E;
  text-decoration: none;
}
@media (max-width: 600px) {
  .bq-item {
    grid-template-columns: 52px minmax(0, 1fr);
    gap: 10px;
    padding: 10px 12px;
  }
  .bq-thumb {
    width: 52px;
    height: 52px;
  }
  .bq-price {
    grid-column: 2;
    text-align: left;
    display: flex;
    gap: 8px;
    align-items: baseline;
    font-size: 0.9375rem;
  }
  .bq-price del {
    display: inline;
  }
  .bq-item.has-ribbon .bq-price {
    padding-top: 0;
  }
}
