/* Archive Product Page Styles - OceanWP Child Theme */

/* Woo Product Grid Styles */
#uc_woocommerce_product_grid_elementor_23e294d .uc_post_grid_style_one_button>a,
#uc_woocommerce_product_grid_elementor_23e294d .uc_post_grid_style_one_button>button,
#uc_woocommerce_product_grid_elementor_23e294d .uc-button-addcart,
#uc_woocommerce_product_grid_elementor_23e294d .added_to_cart,
#uc_woocommerce_product_grid_elementor_23e294d .uc_more_btn-custom-field {
  display: inline-block;
  text-align: center;
  text-decoration: none;
  text-transform: none;
  transition: all 0.25s ease-in-out;
  vertical-align: middle;
}

#uc_woocommerce_product_grid_elementor_23e294d .uc-button-addcart.added {
  display: none;
}

#uc_woocommerce_product_grid_elementor_23e294d.uc_post_grid_style_one .uc_post_grid_style_one_wrap {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(3, 1fr);
}

#uc_woocommerce_product_grid_elementor_23e294d.uc_post_grid_style_one .uc_content {
  flex-grow: 1;
  display: flex;
  flex-flow: column nowrap;
}

#uc_woocommerce_product_grid_elementor_23e294d .ue_grid_item_bottom {
  margin-top: auto;
}

.uc_post_grid_style_one .uc_post_grid_style_one_item {
  flex-direction: column;
  display: flex;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
  transition: all 0.3s ease;
  overflow: hidden;
}

.uc_post_grid_style_one .uc_post_grid_style_one_item:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 20px rgba(0,0,0,0.15);
}

.uc_post_grid_style_one_image-wrapper {
  position: relative;
  overflow: hidden;
}

.uc_post_grid_style_one_image {
  display: block;
  text-decoration: none;
}

.uc_post_image img {
  width: 100%;
  height: auto;
  transition: transform 0.3s ease;
}

.uc_post_grid_style_one_item:hover .uc_post_image img {
  transform: scale(1.05);
}

.uc_content.padding {
  padding: 15px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.uc_title {
  margin-bottom: 10px;
}

.uc_title a {
  color: #333;
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.uc_title a:hover {
  color: #007cba;
}

.ue_grid_prices {
  margin-bottom: 15px;
}

.uc_regular_price {
  font-size: 14px;
  color: #999;
  text-decoration: line-through;
  margin-bottom: 5px;
}

.uc_price {
  font-size: 18px;
  font-weight: 700;
  color: #333;
}

.uc_post_grid_style_one_button {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.uc_more_btn {
  flex: 1;
  min-width: 120px;
  padding: 10px 15px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  text-align: center;
  border: 2px solid #000;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(.4,0,.2,1);
  box-sizing: border-box;
}

/* Buy Now button */
.uc_post_grid_style_one_button .uc_more_btn:first-child {
  background: #fff !important;
  color: #000 !important;
  border: 2px solid #000 !important;
}
.uc_post_grid_style_one_button .uc_more_btn:first-child:hover,
.uc_post_grid_style_one_button .uc_more_btn:first-child:focus {
  background: #000 !important;
  color: #fff !important;
  border: 2px solid #000 !important;
}

/* Add To Cart button */
.uc_post_grid_style_one_button .uc_more_btn.uc-button-addcart {
  background: #000 !important;
  color: #fff !important;
  border: 2px solid #000 !important;
}
/* .uc_post_grid_style_one_button .uc_more_btn.uc-button-addcart:hover,
.uc_post_grid_style_one_button .uc_more_btn.uc-button-addcart:focus {
  background: #fff !important;
  color: #000 !important;
  border: 2px solid #000 !important;
} */
.uc_post_grid_style_one_button .uc-button-addcart:hover,
.uc_post_grid_style_one_button .uc-button-addcart:focus {
  background: #fff !important;
  color: #000 !important;
  border: 2px solid #000 !important;
}


/* Responsive adjustments for buttons */
@media (max-width: 767px) {
  #uc_woocommerce_product_grid_elementor_23e294d .uc_post_grid_style_one_button {
    width: 100%;
    display: flex;
    flex-direction: row;
    gap: 8px;
    align-items: center;
    justify-content: center;
    margin-top: 8px;
  }
  #uc_woocommerce_product_grid_elementor_23e294d .uc_post_grid_style_one_button .uc_more_btn,
  #uc_woocommerce_product_grid_elementor_23e294d .uc_post_grid_style_one_button .uc-button-addcart {
    width: 47%;
    min-width: unset;
    max-width: unset;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    padding: 5px 0 !important;
    margin: 0;
    box-shadow: none;
    text-align: center;
    display: block;
    min-height: 10px !important;
  }
}

/* Category Navigation Responsive */
.wpr-taxonomy-list {
  display: flex;
  flex-wrap: nowrap !important;
  gap: 10px;
  margin-bottom: 20px;
}

.wpr-taxonomy {
  flex: 0 0 auto;
}

.wpr-taxonomy a {
  display: inline-block;
  padding: 8px 16px;
  background: #f8f9fa;
  border: 1px solid #ddd;
  border-radius: 20px;
  text-decoration: none;
  color: #333;
  font-size: 14px;
  transition: all 0.3s ease;
}

.wpr-taxonomy a:hover,
.wpr-taxonomy a.active {
  background: #007cba;
  color: white;
  border-color: #007cba;
}

@media (max-width: 767px) {
  .wpr-taxonomy-list {
    display: flex;
    flex-wrap: nowrap !important;
    gap: 10px;
    margin-bottom: 20px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: #ccc #f8f9fa;
  }
  .wpr-taxonomy-list::-webkit-scrollbar {
    height: 6px;
    background: #f8f9fa;
  }
  .wpr-taxonomy-list::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 3px;
  }
  .wpr-taxonomy {
    flex: 0 0 auto;
  }
  .wpr-taxonomy a {
    padding: 6px 12px;
    font-size: 13px;
  }
}

@media (max-width: 480px) {
  .wpr-taxonomy-list {
    gap: 6px;
    margin-bottom: 12px;
  }
  
  .wpr-taxonomy a {
    padding: 5px 10px;
    font-size: 12px;
  }
}

/* Breadcrumbs Responsive */
.hfe-breadcrumbs {
  margin-bottom: 15px;
}

@media (max-width: 767px) {
  .hfe-breadcrumbs {
    margin-bottom: 12px;
  }
  
  .hfe-breadcrumbs-item {
    font-size: 13px;
  }
}

@media (max-width: 480px) {
  .hfe-breadcrumbs-item {
    font-size: 12px;
  }
}

/* Loading States and Animations */
.uc_post_grid_style_one_item {
  animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Accessibility Improvements */
.uc_more_btn:focus {
  outline: 2px solid #007cba;
  outline-offset: 2px;
}

.uc_title a:focus {
  outline: 2px solid #007cba;
  outline-offset: 2px;
}

/* Touch Device Optimizations */
@media (hover: none) and (pointer: coarse) {
  .uc_more_btn {
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
  .uc_title a {
    min-height: 44px;
    display: flex;
    align-items: center;
  }
}

/* Additional Responsive Improvements */

/* Container Responsiveness */
.elementor-element-23e294d {
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
}

/* Improved Mobile Experience */
@media (max-width: 767px) {
  .elementor-element-23e294d {
    padding: 0 10px;
  }
  
  .uc_post_grid_style_one_item {
    margin-bottom: 0;
  }
  
  /* Better touch targets */
  .uc_more_btn {
    min-height: 44px;
    touch-action: manipulation;
  }
  
  /* Improved image loading */
  .uc_post_image img {
    aspect-ratio: 4/3;
    object-fit: cover;
  }
}

/* Landscape Mobile Optimization */
@media (max-width: 767px) and (orientation: landscape) {
  #uc_woocommerce_product_grid_elementor_23e294d.uc_post_grid_style_one .uc_post_grid_style_one_wrap {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* High DPI Display Support */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
  .uc_post_image img {
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
  }
}

/* Print Styles */
@media print {
  .uc_post_grid_style_one_item {
    break-inside: avoid;
    box-shadow: none;
    border: 1px solid #ddd;
  }
  
  .uc_more_btn {
    display: none;
  }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
  .uc_post_grid_style_one_item,
  .uc_post_image img,
  .uc_more_btn {
    transition: none;
    animation: none;
  }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
  .uc_post_grid_style_one_item {
    background: #2d3748;
    color: #e2e8f0;
  }
  
  .uc_title a {
    color: #e2e8f0;
  }
  
  .uc_price {
    color: #e2e8f0;
  }
  
  .uc_regular_price {
    color: #a0aec0;
  }
}

/* Unlimited Elements Background Overlay */
.unlimited-elements-background-overlay {
  position: absolute;
  top: 0px;
  left: 0px;
  width: 100%;
  height: 100%;
  z-index: 0;
}

.unlimited-elements-background-overlay.uc-bg-front {
  z-index: 999;
}

/* WooCommerce Product Grid Specific Styles */
#uc_woocommerce_product_grid_elementor_23e294d .ue_category_label {
  display: block;
  text-decoration: none;
  transition: all .3s ease;
  position: relative;
}

/* Hide default arrows in input type number */
/* Chrome, Safari, Edge, Opera */
#uc_woocommerce_product_grid_elementor_23e294d input.uc-grid-count-buttons__number::-webkit-outer-spin-button,
#uc_woocommerce_product_grid_elementor_23e294d input.uc-grid-count-buttons__number::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* Firefox */
#uc_woocommerce_product_grid_elementor_23e294d input.uc-grid-count-buttons__number[type=number] {
  -moz-appearance: textfield;
}

#uc_woocommerce_product_grid_elementor_23e294d .uc_regular_price:not(.uc_regular_price--single) {
  text-decoration: line-through !important;
}

#uc_woocommerce_product_grid_elementor_23e294d del {
  display: block;
  color: #000;
  opacity: .5;
  font-size: 26px;
  font-weight: 400;
  text-decoration: line-through !important;
}

#uc_woocommerce_product_grid_elementor_23e294d ins {
  color: #000;
  font-size: 36px;
  font-weight: 400;
  text-decoration: none;
}

#uc_woocommerce_product_grid_elementor_23e294d .ue_woocommerce_product_carousel_sale_label {
  display: inline-block;
  position: absolute;
  z-index: 1;
  left: 10px;
  top: 10px;
}

#uc_woocommerce_product_grid_elementor_23e294d .ue_woocommerce_product_grid_out_of_stock_label {
  position: absolute;
  width: fit-content;
  left: 10px;
  top: 10px;
  z-index: 1;
}

#uc_woocommerce_product_grid_elementor_23e294d .ue-inner-btn-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  pointer-events: none;
}

/* --- Product Grid: 3 Columns on Desktop --- */
@media (min-width: 1200px) {
  #uc_woocommerce_product_grid_elementor_23e294d.uc_post_grid_style_one .uc_post_grid_style_one_wrap {
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
  }
}
@media (max-width: 1199px) and (min-width: 1024px) {
  #uc_woocommerce_product_grid_elementor_23e294d.uc_post_grid_style_one .uc_post_grid_style_one_wrap {
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
  }
}
@media (max-width: 1023px) and (min-width: 768px) {
  #uc_woocommerce_product_grid_elementor_23e294d.uc_post_grid_style_one .uc_post_grid_style_one_wrap {
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
  }
}
@media (max-width: 767px) {
  #uc_woocommerce_product_grid_elementor_23e294d.uc_post_grid_style_one .uc_post_grid_style_one_wrap {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px !important;
  }
  #uc_woocommerce_product_grid_elementor_23e294d .uc_post_grid_style_one_image-wrapper {
    padding: 4px 0 0 0;
    display: flex;
    justify-content: center;
    align-items: center;
  }
  #uc_woocommerce_product_grid_elementor_23e294d .uc_post_image img {
    max-width: 100% !important;
    max-height: 100% !important;
    width: auto;
    height: auto;
    border-radius: 8px;
    box-shadow: none;
    margin: 0 auto;
    display: block;
  }
  #uc_woocommerce_product_grid_elementor_23e294d .uc_title a {
    font-size: 13px;
    font-weight: 600;
    line-height: 1.2;
  }
  #uc_woocommerce_product_grid_elementor_23e294d .uc_price {
    font-size: 14px;
    font-weight: 700;
  }
  #uc_woocommerce_product_grid_elementor_23e294d .uc_regular_price {
    font-size: 11px;
  }
  #uc_woocommerce_product_grid_elementor_23e294d .ue-offer {
    display: block;
    margin-left: 0 !important;
    margin-top: 2px;
  }
  #uc_woocommerce_product_grid_elementor_23e294d .uc_post_grid_style_one_button .uc_more_btn,
  #uc_woocommerce_product_grid_elementor_23e294d .uc_post_grid_style_one_button .uc-button-addcart {
    width: 47%;
    min-width: unset;
    max-width: unset;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    padding: 5px 0 !important;
    margin: 0;
    box-shadow: none;
    text-align: center;
    display: block;
    min-height: 10px !important;
  }
}

/* img:is([sizes="auto" i], [sizes^="auto," i]) { contain-intrinsic-size: 3000px 1500px } */
.woocommerce-product-gallery{ opacity: 1 !important; }

/* Custom CSS for archive-product.php */

/* Image sizing optimization */
/* img:is([sizes="auto" i], [sizes^="auto," i]) { 
    contain-intrinsic-size: 3000px 1500px; 
} */

/* WooCommerce product gallery opacity fix */
.woocommerce-product-gallery{ 
    opacity: 1 !important; 
}

/* Unlimited Elements background overlay styles */
.unlimited-elements-background-overlay{
    position: absolute;
    top: 0px;
    left: 0px;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.unlimited-elements-background-overlay.uc-bg-front{
    z-index: 999;
}

/* OceanWP WooCommerce button styles */
body.wcz-btns.wcz-woocommerce ul.products li.product a.button,
body.wcz-btns.wcz-woocommerce .related.products ul.products li.product a.button,
body.wcz-btns.wcz-woocommerce.single-product div.product form.cart .button,
body.wcz-btns.wcz-woocommerce.wcz-wooblocks ul.wc-block-grid__products li.wc-block-grid__product .add_to_cart_button{
    font-size: 16px;
    border-radius: 8px ;
    padding: 14px 28px 15px;
}

body.wcz-btns.wcz-woocommerce ul.products li.product a.button,
body.wcz-btns.wcz-woocommerce .related.products ul.products li.product a.button,
body.wcz-btns.wcz-woocommerce.single-product div.product form.cart .button,
body.wcz-btns.wcz-woocommerce.single-product .woocommerce-Reviews form.comment-form input.submit,
body.wcz-btns.wcz-woocommerce.wcz-wooblocks ul.wc-block-grid__products li.wc-block-grid__product .add_to_cart_button{
    background-color: #000000 !important;
    color: #ffffff !important;
    text-shadow: none;
}

body.wcz-btns.wcz-woocommerce ul.products li.product a.button:hover,
body.wcz-btns.wcz-woocommerce .related.products ul.products li.product a.button:hover,
body.wcz-btns.wcz-woocommerce.single-product div.product form.cart .button:hover,
body.wcz-btns.wcz-woocommerce.single-product .woocommerce-Reviews form.comment-form input.submit:hover,
body.wcz-btns.wcz-woocommerce.wcz-wooblocks ul.wc-block-grid__products li.wc-block-grid__product .add_to_cart_button:hover{
    background-color: #0a0a0a !important;
    color: #ffffff !important;
}

/* Product title styles */
body.woocommerce.wcz-woocommerce ul.products li.product .woocommerce-loop-product__title,
body.wcz-woocommerce .products .product .woocommerce-loop-product__title,
body.wcz-wooblocks ul.wc-block-grid__products li.wc-block-grid__product .wc-block-grid__product-title{
    font-size: 24px !important;
}

body.woocommerce.wcz-woocommerce ul.products li.product .woocommerce-loop-product__title,
body.wcz-woocommerce .products .product .woocommerce-loop-product__title,
body.wcz-wooblocks ul.wc-block-grid__products li.wc-block-grid__product .wc-block-grid__product-title a{
    color: #0a0a0a !important;
}

/* Price styles */
body.woocommerce.wcz-woocommerce ul.products li.product .price,
body.wcz-woocommerce .products .product .price,
body.wcz-wooblocks ul.wc-block-grid__products li.wc-block-grid__product .wc-block-grid__product-price{
    font-size: 21px !important;
}

body.woocommerce.wcz-woocommerce ul.products li.product .price,
body.wcz-woocommerce .products .product .price,
body.wcz-wooblocks ul.wc-block-grid__products li.wc-block-grid__product .wc-block-grid__product-price__value,
body.wcz-wooblocks ul.wc-block-grid__products li.wc-block-grid__product .wc-block-grid__product-price ins{
    color: #0a0000 !important;
}

body.wcz-wooblocks ul.wc-block-grid__products li.wc-block-grid__product .wc-block-grid__product-price del{
    color: rgba(10, 0, 0, 0.45);
}

/* Hide product meta */
body.single-product .product_meta .posted_in{
    display: none !important;
}

/* WooCommerce form styles */
.woocommerce form .form-row .required { 
    visibility: visible; 
}

/* Add here all other custom CSS blocks you want to keep from your archive-product.php */

/* Active Category Styling */
.elementor-widget-container .wpr-taxonomy.active a {
    background-color: #000000;
    color: #ffffff;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.elementor-widget-container .wpr-taxonomy.active a {
  background-color: #000 !important;
    color: #ffffff !important;
}

.wpr-taxonomy.active .wpr-tax-wrap span {
    color: #ffffff;
}

.wpr-taxonomy.active .wpr-term-count {
    color: #ffffff;
}

/* Hover effect for active state */
.wpr-taxonomy.active:hover {
    background-color: #000;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* Alternative styling option - outline style */
/* 
.wpr-taxonomy.active {
    border: 2px solid #000000;
    background-color: transparent;
    color: #000000;
    font-weight: 600;
}

.wpr-taxonomy.active a {
    color: #000000 !important;
}
*/ 

@media (max-width: 767px) {
  #uc_woocommerce_product_grid_elementor_23e294d .ue-offer {
    display: block;
    margin-left: 0 !important;
    margin-top: 2px;
  }
} 

ul.products li.product {
  background: #fff;
  border-radius: 24px;
  box-shadow: 0 2px 16px rgba(0,0,0,0.07);
  padding: 24px 16px 16px 16px;
  width: 320px !important;
  min-width: 320px !important;
  max-width: 100% !important;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: box-shadow 0.2s;
}