/* =========================================
   1. PURE CSS ENTRANCE ANIMATIONS (LCP OPTIMIZED)
   ========================================= */

/* --- Keyframes --- */
@keyframes oabFadeDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes oabFadeUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes oabImageEntrance {
  from {
    opacity: 0;
    transform: scale(0.8) rotate(-6deg);
  }
  to {
    opacity: 1;
    transform: scale(1) rotate(0deg);
  }
}

/* --- 1. The Breadcrumbs: Gentle slide down --- */
.product-breadcrumbs,
.mob-product-breadcrumbs {
  opacity: 0; /* Start invisible */
  animation: oabFadeDown 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}
.breadcrumb-product {
  color: var(--color-text-muted);
}

/* --- 2. The Main Image: Scale + Rotate --- */
.main-product-image {
  opacity: 1 !important;
  transform-origin: center;
  will-change: transform, opacity;
  animation: oabImageEntrance 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* --- 3. The Text Column (Price, Title, etc): Slide Up --- */
.product-column-left {
  opacity: 0;
  animation: oabFadeUp 0.8s ease-out forwards;
  animation-delay: 0.2s; /* Wait slightly for image to start */
}

/* --- 4. Thumbnails & Swatches (Optional: Simple Fade) --- */
.thumbnail-item,
.gallery-swatch-nav {
  opacity: 0;
  animation: oabFadeUp 0.8s ease-out forwards;
  animation-delay: 0.4s;
}

/* --- VISIBILITY CONTROL --- */
/* IMPORTANT: Removed main image, breadcrumbs, and left column 
   from this list so they render immediately with CSS.
   Only keep elements that absolutely require JS to layout correctly.
*/

#product-page .discount-badge {
  padding: 8px 21px;
  border-radius: 10px !important;
}
#product-page .fav-discount-wrapper {
  justify-content: start;
  gap: 14px;
}
#product-page .fav-discount-wrapper:has(.discount-badge) {
  justify-content: end;
}

#product-page .discount-badge p {
  font-size: 18px;
}
/* --- Main Product Layout --- */
.product-row-1 {
  display: flex;
  flex-wrap: wrap;
  column-gap: 96px; /* Increased gap for a more spacious layout */
  row-gap: 21px; /* Increased gap for a more spacious layout */
  align-items: flex-start; /* Aligns columns to the top */
}
.product-column-left,
.product-column-right {
  flex: 1;
  position: relative;
  width: 50%;
  min-width: 320px;
  max-width: 100%;
}
/* --- Sticky Add to Cart Bar --- */

/* 1. Hide the bar by default */
.oab-sticky-add-to-cart-bar {
  display: none;
}
.product-breadcrumbs {
  display: none;
}
.mob-product-breadcrumbs {
  display: flex;
}
.woocommerce:where(body:not(.woocommerce-uses-block-theme))
  .woocommerce-breadcrumb {
  color: var(--color-text-h6);
}
@media (max-width: 729px) {
  .price {
    order: 1;
  }
  #oab-in-page-selector-trigger {
    order: 2;
  }
  #pgl-product-details {
    order: 3;
  }
  .pgl-swatches-container {
    justify-content: center;
    /* gap: 24px !important; */
  }
  .pgl-swatch-item.is-active .pgl-swatch-title {
    padding-top: 6px;
  }
  .pgl-swatch-item {
    /* min-width: 40%; */
    width: 90px;
    text-align: center;
  }
  .pgl-swatch-image {
    min-width: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    aspect-ratio: 1 !important;
  }
  .product-column-left {
    background: var(--color-card-bg);
    border-radius: 47px;
    padding: 44px 32px;
    margin-top: 22px;
  }
  .woocommerce:where(body:not(.woocommerce-uses-block-theme))
    .woocommerce-breadcrumb {
    font-size: 1.1em;
  }
}
@media (min-width: 730px) {
  .mob-product-breadcrumbs {
    display: none;
  }
  .product-breadcrumbs {
    display: flex;
  }
}
@media (max-width: 731px) {
  .standalone-qty-btn {
    background: var(--color-border) !important;
  }
  .standalone-qty-count-wrapper {
    background: #fefcf9b8 !important;
  }
}
@media (max-width: 1024px) {
  .product-row-1 {
    gap: 42px;
  }
  .swatch-link {
    min-width: 12vw;
    min-height: 12vw;
  }

  .product_title.entry-title {
    font-size: 32px;
  }
  .product-title-desc p {
    font-size: 17px;
  }
  .sticky-element img {
    height: 60vh !important; /* Or set a max-height */
    max-height: 420px !important;
  }
}
.standalone-single-button .plus-cart {
  display: none;
}
/* 2. On mobile, set up the sticky bar */
@media (max-width: 767px) {
  .oab-sticky-bar-content:has(.standalone-selector-wrapper.is-active) {
    padding: 8px;
  }
  .oab-sticky-bar-content:has(.standalone-selector-wrapper.is-active)
    .standalone-qty-minus {
    border-radius: 28px 9px 9px 28px;
  }
  .oab-sticky-bar-content:has(.standalone-selector-wrapper.is-active)
    .standalone-qty-btn {
    background-color: var(--color-border);
  }
  .oab-sticky-bar-content:has(.standalone-selector-wrapper.is-active)
    .standalone-qty-plus {
    border-radius: 9px 28px 28px 9px;
  }
  .oab-sticky-add-to-cart-bar .plus-cart {
    background-color: var(--color-accent);
    flex-shrink: 0;
    height: 48px;
    width: 48px;
    border-radius: 50%;
    color: var(--color-badge-accent-text);
    font-size: 17px;
    display: flex;
    align-items: center;
    opacity: 100 !important;
    pointer-events: all !important;
    z-index: 2 !important;
    justify-content: center;
    transition: all 0.3s ease-in-out;
  }

  .oab-sticky-add-to-cart-bar .standalone-single-button {
    background-color: transparent !important;
    font-size: 17px;
    color: var(--color-btn-secondary-border);
    padding: 0 !important;
  }
  .oab-sticky-add-to-cart-bar {
    display: flex;
    gap: 8px;
    position: fixed;
    bottom: 15px;
    left: 0;
    right: 0;
    z-index: 999;

    /* Animation setup: Start hidden below the screen */
    transform: translateY(120%);
    /* This cubic-bezier creates a nice "bounce" effect */
    transition: transform 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  }

  /* 3. The "visible" state, triggered by JavaScript */
  .oab-sticky-add-to-cart-bar.is-visible {
    transform: translateY(0);
  }
  .product-features-title {
    font-size: 24px !important;
    text-align: center !important;
  }
  /* 4. Styling for the bar content */
  .oab-sticky-bar-content {
    display: flex;
    align-items: center;
    justify-content: space-between;

    /* Center it with a max-width */
    width: fit-content;
    max-width: 90%;
    margin: 0 auto;

    /* Spacing */
    padding: 8px 18px 8px 8px; /* A bit more padding on the right */

    /* --- The Glass Effect --- */

    /* 1. Frosted Glass Background */
    /* Using 70% opacity white. Your 28% (..47) is too transparent for a white bg */

    background-color: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(5px);
    /* 2. The Blur */
    -webkit-backdrop-filter: blur(5px);

    /* 3. The Pill Shape */
    border-radius: 55px;

    border: 1px solid #6e8c6514;
    background-color: #bfb6ad70;
    backdrop-filter: blur(5px);
    box-shadow: inset 0 0 2000px rgba(255, 255, 255, 0.5);
  }
  .sms-notif-enable-label:hover,
  .sms-notif-enable-label:hover strong {
    background-color: transparent !important;
  }
  /* 5. Styling for the price and selector inside */
  .oab-sticky-bar-price {
    font-size: 16px;
    font-weight: bold;
    color: #000; /* Ensure text is readable */
  }

  .oab-sticky-bar-selector {
    /* Shrink the selector to fit */
    display: flex;
    align-items: center;
    width: 100%;
    justify-content: space-between;
    transform: scale(1);
    transform-origin: right;
  }
}
/* Add this media query to target screens *up to* 480px wide.
  (You might want to use 479px or 481px depending on your breakpoints)
*/
@media (max-width: 480px) {
  .dropdown-label,
  .pfaq-question-text {
    font-size: 18px;
  }

  .product-column-left,
  .product-column-right {
    min-width: auto; /* Or min-width: 0; */

    /* You might also want them to stack instead of being side-by-side */
    width: 100%;
    flex-basis: 100%;
  }
}
.product-column-left {
  padding-top: 48px;
  display: flex;
  flex-direction: column;
  gap: 34px;
}
.product-breadcrumbs {
  margin-top: 160px;
  padding: 0 32px;

  margin-bottom: 24px;
  font-size: 17px;
}
.product-title-desc p {
  text-align: justify;
  font-size: 18px;
  color: var(--color-text-h4);
}
/* --- Custom Gallery (Right Column) --- */
.custom-gallery-wrapper {
  /* Set the maximum height relative to the viewport */
  /* Use flexbox to arrange the images vertically */
  display: flex;
  flex-direction: column;
  gap: 16px;
  height: fit-content;
}

/* The container for the big main image */
.main-image-container {
  height: auto;
  aspect-ratio: 1 / 1;
  border-radius: 21px;
  overflow: hidden;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.03);
  background-color: var(--color-product-card-bg);
  position: relative;
}
/* Position the badge wrapper at the top right */
.main-image-container .fav-discount-wrapper {
  top: 16px;
  right: 16px;
  z-index: 5;
}

.fav-discount-wrapper {
  position: absolute;
  top: 12px;
  left: 12px;
  right: 12px;

  z-index: 105 !important;
}
.main-image-container .fav-discount-wrapper {
  z-index: 10 !important;
}
.fav-discount-wrapper.discounted {
  direction: rtl;
}
.fav-discount-wrapper {
  direction: ltr;
}
/* Favorite Button Styling */
.favorite-btn {
  box-shadow: 0 8px 30px rgb(42 42 42 / 15%) !important;
  backdrop-filter: blur(6px);
  /* border: 1px solid #e6ded59c; */
  padding: 0;
  background: rgba(255, 255, 255, 0.9);
  border: none;
  border-radius: 50%;
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  transition: transform 0.2s;
}

.favorite-btn .heart-icon {
  width: 18px;
  height: 18px;
  stroke: #bcb4b4; /* Icon outline color */
  stroke-width: 2;
  fill: transparent; /* Make the inside transparent by default */
  transition: all 0.2s ease-in-out;
}
.favorite-btn:not(.loading):hover .heart-icon {
  fill: var(--color-primary);
  stroke: var(--color-primary);
}
/* Active state for when a product is a favorite */
.favorite-btn.active .heart-icon {
  fill: var(--color-primary);
  stroke: var(--color-primary);
}

/* Loading state to prevent double-clicks */
.favorite-btn.loading {
  opacity: 0.4;
  cursor: default;
}

/* The big main image itself */
.main-product-image {
  border-radius: 21px;
  width: 100%;
  height: 100%;
  aspect-ratio: 1 / 1; /* Enforces a square 1:1 ratio */
  object-fit: cover; /* Fills the square without distorting, cropping if necessary */
  /* TODO Remove later */
  mix-blend-mode: multiply;
}

.woocommerce img,
.woocommerce-page img {
  border-radius: 21px;
  height: 100% !important;
  max-height: 100%;
}
/* Container for the 2-column thumbnails */
.custom-gallery-thumbnails {
  display: flex;
  gap: 16px;
}

/* Each individual thumbnail column */
.thumbnail-item {
  aspect-ratio: 1 / 1;
  flex: 1; /* Makes each thumbnail take up equal space */
}

/* The images inside the thumbnail columns */
.thumbnail-item img {
  border-radius: 21px;
  width: 100%;
  height: 100%;
  display: block;
  aspect-ratio: 1 / 1; /* Also enforce a square ratio on thumbnails */
  object-fit: cover; /* Also cover for thumbnails */
}

/* nutritional Info */
/* --- Custom Nutrition Facts Section --- */
.product_dropdown-wrapper {
  border-radius: 16px;
  padding: 18px;
  background-color: var(--color-card-bg);
}

.product_dropdown-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
}
.product_dropdown-top .type-secondary {
  max-width: 92%;
}

.product_dropdown-button {
  background-color: transparent;
  border: none;

  cursor: pointer;
  color: #333; /* Set a default color */
}

.pfaq-section-content .product_dropdown-button {
  padding: 8px;
}
.button-icon-plus {
  width: 14px;
  height: 14px;
  position: relative;
}

.button-plus-vertical,
.button-plus-horizontal {
  background-color: var(--color-text-h4);
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.button-plus-vertical {
  width: 2px;
  height: 100%;
}

.button-plus-horizontal {
  width: 100%;
  height: 2px;
}

.product_dropdown-bottom {
  overflow: hidden;
}

.product_dropdown-content-inner {
  /*padding-top: 16px;*/
  /*padding-bottom: 16px;*/
}

.text-weight-medium {
  font-weight: 500;
}

.product_dropdown-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.product_dropdown-label {
  color: var(--color-text-body);
}
/* --- Indent for Nutrition Subcategories --- */
.product_dropdown-content.is-indented {
  padding-right: 20px;
}
.product_dropdown-content.is-indented .product_dropdown-label {
  opacity: 0.7;
}
/* StoryTelling */
.scrollytelling-section {
  display: flex;
  gap: 3rem;
  margin-top: 5rem;
  margin-bottom: 5rem;
}
/*  to make text full width when image is missing */
.scrollytelling-section.no-image-layout .scrolling-column {
  width: 80%;
  flex: 0 0 80%;
  margin-top: 80px !important;
  max-width: 100%;
  margin: 0 auto;
}
.scrollytelling-section.no-image-layout .content-panel {
  padding-bottom: 21px !important;
}
/* 1. Ensure the product link is the positioning anchor */
.pgl-similar-products li.product.outofstock .woocommerce-LoopProduct-link {
  position: relative;
  display: block;
}

/* 2. Create the Badge using Pseudo-elements */
.pgl-similar-products
  li.product.outofstock
  .woocommerce-LoopProduct-link::before {
  z-index: 999;
  content: "ناموجود"; /* Farsi for Out of Stock */
  position: absolute;
  top: 30%;
  left: 50%;
  transform: translate(-50%, -50%);
  background-color: rgba(0, 0, 0, 0.4); /* White with slight transparency */
  color: #fff;
  padding: 8px 20px;
  border-radius: 12px;
  font-weight: 800;
  font-size: 16px;
  z-index: 9999;
  white-space: nowrap;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  pointer-events: none; /* Allows user to still click the product link underneath */
}

/* 3. Optional: Dim the image slightly to make the badge pop */
.pgl-similar-products li.product.outofstock img {
  opacity: 0.6;
  filter: grayscale(60%);
}
.pgl-similar-products li.product .added_to_cart {
  transform: translateY(-10px);
  margin: 0 auto;
  font-size: 14px;
}
/* The sticky column for the image */
.sticky-column {
  flex: 1;
  height: 100vh;
  width: 50%;
  position: relative;
}

/* The element that will be pinned */
.sticky-element {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 100%;
  height: 80vh; /* Give it a more specific height */
  display: flex;
  align-items: center;
  justify-content: center;

  /* NEW: Contain the image zoom */
  border-radius: 24px;
  overflow: hidden;
}

.sticky-element img {
  width: 100%;
  height: 100%; /* Fill the container */
  object-fit: cover !important;
  /* Radius is now on the parent .sticky-element */
}

/* The scrolling column for the text panels */
.scrolling-column {
  flex: 1;
  max-width: 50%;
  margin-top: 25vh; /* Pushes first panel down */
}


.product-column-left .price {
  flex-direction: row;
  display: flex;
  justify-content: flex-start;
  align-items: center;
}
.product-column-left .price:has(del) {
  gap: 8px;
}
.product-column-left .price svg {
  height: 26px;
  width: 26px;
}
.product-column-left .price *,
.product-column-left .price,
.product-column-left .price ins,
.product-column-left .price ins *,
.product-column-left .price bdi,
.product-column-left .price bdi * {
  text-decoration: none !important;
  color: var(--color-text-body) !important;
  font-size: 22px !important;
  font-weight: 600 !important;
}
.product-column-left .price del bdi,
.product-column-left .price del,
.product-column-left .price del * {
  display: inline-block !important;
  text-decoration: line-through !important;
  color: var(--color-text-h3) !important;
  font-size: 19px !important;
  margin-left: 2px !important;
}

@media (max-width: 368px) {
  .sticky-element img {
    height: auto !important;
    max-height: 420px;
    aspect-ratio: 1;
  }
}
/* --- MOBILE STYLES --- */
@media (max-width: 768px) {
  .scrollytelling-section {
    flex-direction: column;
    gap: 2rem;
  }

  .sticky-column {
    /* Un-stick the column */
    position: static;
    height: auto;
    width: auto;
    z-index: 10;
  }

  .sticky-element {
    /* Remove desktop positioning */
    position: static;
    transform: none;
    height: auto; /* Let image define height */
    width: 100%;
    /* Keep the radius and overflow */
  }

  #pgl-product-reviews {
    margin-bottom: 0;
  }
  .scrolling-column {
    z-index: 10;
    background: var(--color-card-border);
    border-radius: 24px;
    padding: 42px 36px;
    max-width: none !important;
    margin-top: 0; /* Remove desktop spacing */
    width: 100% !important;
    max-width: 100% !important;
  }

  .content-panel {
    padding-bottom: 3rem; /* Reduce padding on mobile */
  }
  .product-column-left .price svg {
    height: 21px;
    width: 21px;
  }
  .product-column-left .price *,
  .product-column-left .price,
  .product-column-left .price ins,
  .product-column-left .price ins *,
  .product-column-left .price bdi,
  .product-column-left .price bdi * {
    text-decoration: none !important;
    color: var(--color-text-body) !important;
    font-size: 19px !important;
    font-weight: 600 !important;
  }
}
/* End of StoryTelling Section */

/* 1. The Sticky Swatch Navigator Bar */
.gallery-swatch-nav {
  position: sticky;
  bottom: 20px;

  width: auto;
  height: auto;
  display: flex;
  justify-content: center;
  z-index: 9;
  /* This makes it only sticky within its parent, .product-column-right */
}

.swatch-nav-inner {
  display: flex;
  gap: 5px;
  padding: 8px;
  width: fit-content;
  backdrop-filter: blur(10px);
  background: #e9e5e16e;
  -webkit-backdrop-filter: blur(10px);
  border-radius: 12px;
}

.swatch-link {
  width: 70px;
  height: 70px;
  max-width: 70px;
  max-height: 70px;
  background-color: var(--color-border);
  aspect-ratio: 1 / 1;
  border-radius: 10px;
}

.swatch-link img {
  width: 100%;
  border-radius: 8px;
  height: 100%;
  object-fit: cover;
  opacity: 0.4;
  will-change: transform;
  transition: all 0.3s ease-in-out;
}
.swatch-link:hover img,
.swatch-link.is-active img {
  opacity: 1; /* Fully visible when active */
}

/* Give our gallery images a class for JS to target */
.custom-gallery-wrapper .gallery-image-item {
  margin-bottom: 20px; /* Add some space between images */
}
/* 1. Main Features Section Container */
.pgl-features {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 46px;
  /*background: var(--color-nutrition-bg);*/
  border-radius: 24px;
  /*border: 1px solid var(--color-nutrition-border);*/
  margin-top: 140px;
  /*margin-bottom: 64px;*/
  padding: 48px 20px;

  position: relative; /* This is the anchor for the ::before element */
  overflow: hidden; /* This hides the background circle and is crucial for the title mask */
  
}
#pgl-features {
  position: relative;
  overflow: hidden;
}

/* 3. The Header (Title) and Wrapper for the Badges */
/* These do not need z-index or position because the ::before is now z-index: 0 */
.product-features-header {
  text-align: center;
}

.product-features-wrapper {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 21px;
  width: 70%;
}

/* 4. The Title Itself */
/* The overflow:hidden is the "mask" that makes the reveal animation work */
.product-features-title {
  overflow: hidden;
  font-size: 28px;
}

.product-features-title .reveal-text {
  display: block;
  font-weight: 600;
  color: var(--color-text-h3);
}
/* --- The rest of your badge styling is correct --- */

.feature-badge {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  padding: 9px 9px 12px;
  font-size: 14px;
  font-weight: 500;
  color: var(--color-text-h2);
  /* background-color: #ffffff8c; */
  /* border: 1px solid #ffffff; */
  border-radius: 87px;
}

.feature-badge p {
  padding-bottom: 12px;
  padding-top: 8px;
  max-width: 80px;
  text-align: center;
  font-size: 13px;
}

.feature-icon {
  width: 90px;
  height: 90px !important;
  max-height: 90px !important;
  background-color: #fffffff2;
  /* background-color: #ece8dc; */
  border-radius: 50% !important;
  object-fit: contain;
}

/* WYSIWYG */
/**
 * Minimal & Elegant WYSIWYG Content Styles
 * for the Scrollytelling Section
 */

/* Target the div that wraps the content from your plugin's WYSIWYG editor. */
.content-panel div {
  color: var(--color-text-body);
  font-size: clamp(
    1rem,
    0.95rem + 0.2vw,
    1.125rem
  ); /* Scales from 16px to 18px */
  line-height: 1.7; /* Generous line height for readability */
}

/* === Headings === */
/* Assumes you will use H3, H4, etc., inside your content */
.content-panel h3,
.content-panel h4 {
  margin-top: 2em;
  margin-bottom: 0.5em;
  line-height: 1.3;
}

.content-panel h3 {
  color: var(--color-text-h3);
  font-size: clamp(
    1.25rem,
    1.1rem + 0.5vw,
    1.5rem
  ); /* Scales from 20px to 24px */
}

.content-panel h4 {
  color: var(--color-text-h4);
  font-size: clamp(
    1.1rem,
    1rem + 0.2vw,
    1.25rem
  ); /* Scales from 17.6px to 20px */
}

/* === Paragraphs === */
.content-panel p {
  margin-bottom: 1.25em;
}
.content-panel p:last-child {
  margin-bottom: 0;
}

/* === Lists (UL & OL) === */
.content-panel ul,
.content-panel ol {
  margin-bottom: 1.5em;
  padding-right: 1.5rem; /* Indentation for RTL */
}

.content-panel li {
  position: relative;
  padding-right: 1rem; /* Space between bullet and text */
  margin-bottom: 0.75em;
}

/* Custom, elegant bullets for Unordered Lists */
.content-panel ul > li::before {
  content: "■"; /* A simple, minimal square */
  position: absolute;
  top: 0.4em; /* Adjust vertical alignment */
  right: 0; /* Position for RTL */
  font-size: 0.5em; /* Make the bullet smaller than the text */
  color: var(--color-primary); /* Use your theme's sage green accent */
}

/* Style the numbers for Ordered Lists */
.content-panel ol {
  list-style: none;
  counter-reset: custom-counter;
}
.content-panel ol > li::before {
  counter-increment: custom-counter;
  content: counter(custom-counter) ".";
  position: absolute;
  right: 0;
  font-weight: 600;
  color: var(--color-text-muted);
}

/* === Links === */
.content-panel a {
  color: var(--color-text-link);
  text-decoration: none;
  font-weight: 600;
  background-image: linear-gradient(
    to right,
    var(--color-primary),
    var(--color-primary)
  );
  background-size: 0% 2px;
  background-repeat: no-repeat;
  background-position: 0 100%;
  transition: background-size 0.3s ease;
}

.content-panel a:hover {
  background-size: 100% 2px;
}

/* === Blockquotes === */
.content-panel blockquote {
  margin: 2em 0;
  padding: 1em 1.5em;
  border-right: 3px solid var(--color-primary); /* Sage green border for RTL */
  background-color: var(
    --color-product-card-bg
  ); /* Use your subtle card background */
  border-radius: 8px;
  font-style: italic;
  color: var(--color-text-muted);
}
.content-panel blockquote p {
  margin-bottom: 0;
}

/* === Horizontal Rule === */
.content-panel hr {
  border: none;
  height: 1px;
  background-color: var(--color-border-subtle);
  margin: 2.5em 0;
}

/* FAQ */
.pfaq-accordion-section .pfaq-item {
  opacity: 0; /* Start invisible */
}
/* FAQ Section Title Animation Prep */
.pfaq-section-title {
  opacity: 1; /* Default visible state (JS will hide if animating) */
  /* Optional: Add overflow hidden if blur causes layout shifts */
  /* overflow: hidden; */
}

/* In your CSS file or Added via wp_add_inline_style */
.faq-title-word {
  display: inline-block;
  opacity: 0; /* Make absolutely sure this rule is present and applying */
  will-change: transform, opacity, filter;
}
/* Ensure spaces are treated correctly */
.faq-title-char:empty {
  /* Targets the spans with &nbsp; */
  display: inline;
  opacity: 1; /* Spaces don't need to fade in */
}

/* Ensure the title is visible if JS fails */
.pfaq-section-title:not(.chars-split) {
  opacity: 1 !important;
}
.no-js .pfaq-section-title .faq-title-char {
  opacity: 1 !important; /* Show chars if JS is disabled */
  transform: none !important;
  filter: none !important;
}

/* Make sure FAQ items also start hidden via CSS */
.pfaq-accordion-section .pfaq-item {
  opacity: 0;
  will-change: transform, opacity;
}
.no-js .pfaq-accordion-section .pfaq-item {
  opacity: 1 !important;
  transform: none !important;
}
.pfaq-accordion-section {
  display: flex;
  flex-direction: row;
  row-gap: 8px;
  column-gap: 44px;
  margin: 64px 0;
  margin-top:86px;
  justify-content: space-around;
  flex-wrap: wrap;
  align-items: start;
}
.pfaq-section-title {
  font-size: 1.8em;
  margin-bottom: 1.4em;
  color: var(--color-primary);
  text-align: center;
}

.pfaq-section-content {
  width: 700px;
  max-width: 100%;
}
.pfaq-answer-content p {
  margin-bottom: 10px;
}

/* --- FAQ Title Words Animation --- */
.faq-title-word {
    display: inline-block;
    opacity: 0;
    transform: translateY(30px);
    filter: blur(5px);
    /* The transition handles the fade, slide, and un-blur all at once */
    transition: all 0.6s cubic-bezier(0.215, 0.61, 0.355, 1);
    will-change: opacity, transform, filter;
}

/* When the parent title gets the .is-visible class, animate the words */
.pfaq-section-title.is-visible .faq-title-word {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
}

/* --- FAQ Accordion Items Animation --- */
.pfaq-item {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s cubic-bezier(0.215, 0.61, 0.355, 1), 
                transform 0.6s cubic-bezier(0.215, 0.61, 0.355, 1);
    will-change: opacity, transform;
}

.pfaq-item.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* --- WhatsApp Block Animation --- */
.pfaq-whatsapp-link {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s cubic-bezier(0.215, 0.61, 0.355, 1);
    will-change: opacity, transform;
}

.pfaq-whatsapp-link.is-visible {
    opacity: 1;
    transform: translateY(0);
}


.scrolling-column figure {
  width: 100% !important;
  margin: 32px auto;
  max-width: 100% !important;
  display: flex;
  flex-direction: column;
  gap: 7px;
  align-items: center;
  justify-content: center;
}
.scrolling-column figure img {
  margin: 0 auto;
}
.scrolling-column img {
  justify-self: center;
}
.scrolling-column figcaption {
  text-align: center;
  margin-top: 5px;
}
.related.products > h2 {
    font-size: 1.8rem;
    text-align: center;
    margin-bottom: 23px;
    color: var(--color-primary);
}
/* Related Posts */
/* 1. Hides the title *before* the JS splits it.
   The JS will set this to opacity: 1 after it runs.
*/
.related-products {
  margin: 0px 0 150px 0;
}
.related-products-title {
  opacity: 0;
  color: var(--color-primary);
  font-size: 1.8em;
  margin-bottom: 1.4em;
  text-align: center;
}

/* 2. Hides the product cards *before* GSAP animates them.
   This is the initial state for the card animation.
*/
.related-products .products-grid > * {
  opacity: 0;
}

/* 3. Tablet (780px to 1280px): 3 columns */
@media (min-width: 780px) and (max-width: 1279px) {
  /* 4. IMPORTANT: Show the 3rd product again on tablet */
  .related-products .products-grid > *:nth-child(4) {
    display: none !important; /* or 'flex', 'grid' depending on layout */
  }
}
.pgl-similar-products {
  margin-top: 150px;
}


/*
 * ===================================================
 * == Misc
 * ===================================================
 */

/* * ===================================================
 * == Placeholder Card Loader
 * ===================================================
 */
.blog-posts-loader {
  /* Mimic the card shape */
  position: absolute;
  width: 100%;
  height: 70vh;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border-radius: 16px;
  background-color: var(--color-card-bg); /* Dark base */
  overflow: hidden; /* Important for the shimmer */
}

.blog-loader-shimmer {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  /* The animated gradient */
  background: linear-gradient(
    0deg,
    var(--color-border-subtle) 0%,
    var(--color-footer-bg) 100%
  );
  background-size: 200% 100%;
  animation: blogShimmer 1.5s infinite linear;
}

@keyframes blogShimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/*
 * ===================================================
 * == 2-Column Sticky Blog Layout
 * ===================================================
 */

/* 1. Make the main section a container */
.related-blog-section {
  padding-top: 4rem;
  padding-bottom: 4rem;
}

/* 2. The 2-Column Grid */
.blog-layout-grid {
  display: grid;
  grid-template-columns: 1fr; /* 1 column on mobile */
  gap: 2rem;
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

/* 3. The STICKY Card Stack Column (Left) */
.blog-stack-column {
  position: relative;
  /* This column will be pinned by GSAP */
}

/* 4. The SCROLLING Title Column (Right) */
.blog-title-column {
  position: relative;
  overflow: hidden;
  /* This column will scroll naturally */
}

/* 5. The Title Styling */
.blog-section-title-mask {
  text-align: right;
}

/*
 * ===================================================
 * == Desktop Layout (The Sticky Part)
 * ===================================================
 */

@media (min-width: 768px) {
  .blog-layout-grid {
    /* 6fr for cards (left), 4fr for text (right) */
    grid-template-columns: 4fr 6fr;
    gap: 4rem;
    align-items: start; /* Align items to the top */
  }

  .blog-stack-column {
    /* Set height to the VISIBLE pinned area */
    height: calc(100vh - 100px); /* Adjust 100px if your header is different */

    /* These lines vertically center the content of this column */
    display: flex;
    align-items: center; /* Vertically center its child (.blog-card-stack-pinned-element) */
    justify-content: center; /* Horizontally center its child */
  }

  .blog-card-stack-pinned-element {
    /* Set height to match the card height for simple centering, and for the loader */
    height: 70vh;
    border-radius: 12px;
  }
  /* =================================================== */

  .blog-title-column {
    /* This column SCROLLS. */
    position: relative;
  }

  .blog-section-title-mask {
    text-align: left; /* Or right, your preference */
  }
}
/*
 * ===================================================
 * Dynamic Content List (Right Column)
 * ===================================================
 */

.blog-dynamic-content {
  margin-top: 20vh;
}

.blog-dynamic-list-scroller {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0vh;
}

.blog-dynamic-list-item {
  min-height: 60vh;
  /* padding-bottom: 25vh; */

  opacity: 0.3;
  transition: opacity 0.4s ease;

  /* This centers the text vertically within its block */
  display: flex;
  flex-direction: column;
  justify-content: start;
}

.blog-dynamic-list-item.is-active {
  opacity: 1; /* Active item is fully visible */
}

.blog-dynamic-title {
  font-size: 1.75rem;
  line-height: 1.3;
  color: var(--color-text-body); /* White title */
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.blog-dynamic-desc {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--color-text-h2); /* Light grey text */
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* On desktop, align text with the title */
@media (min-width: 768px) {
  .blog-dynamic-content {
    text-align: right;
  }
}

@media (max-width: 400px) {
  .pgl-features {
    padding: 48px 16px;
  }
  .blog-section-title-mask h2 {
    font-size: 1.6rem;
  }
  .related-products-title {
    font-size: 1.8rem;
    margin-bottom: 38px;
  }
  .pfaq-accordion-section {
    margin: 8rem 0;
  }
  .content-panel {
    padding-bottom: 0;
  }
}

/* --- 1. The Main Feature Section --- */
.pgl-features {
    opacity: 0;
    transition: opacity 0.5s cubic-bezier(0.25, 1, 0.5, 1);
    will-change: opacity;
}

.pgl-features.is-visible {
    opacity: 1;
}

/* --- 2. The Title Text --- */
.pgl-features .reveal-text {
    opacity: 0;
    transform: translateY(110%);
    /* Matches duration: 1.0, ease: 'power3.out' */
    transition: opacity 1s cubic-bezier(0.215, 0.61, 0.355, 1), 
                transform 1s cubic-bezier(0.215, 0.61, 0.355, 1);
    /* The 0.2s delay mimics the GSAP "-=0.3" offset relative to the parent fade */
    transition-delay: 0.2s; 
    will-change: transform, opacity;
}

.pgl-features.is-visible .reveal-text {
    opacity: 1;
    transform: translateY(0);
}

/* --- 3. The Feature Badges (Circles) --- */
.pgl-features .feature-badge {
    opacity: 0;
    transform: translateY(30px);
    /* Matches duration: 0.6, ease: 'power3.out' */
    transition: opacity 0.6s cubic-bezier(0.215, 0.61, 0.355, 1), 
                transform 0.6s cubic-bezier(0.215, 0.61, 0.355, 1);
    will-change: transform, opacity;
}

.pgl-features.is-visible .feature-badge {
    opacity: 1;
    transform: translateY(0);
}
/*
 * ===================================================
 * == NEW: Mobile Responsiveness (Overrides)
 * ===================================================
 */
@media (max-width: 767px) {
  .product-features-wrapper {
    width: 100%;
  }

  /* 1. Hide the dynamic text column's content */
  .blog-dynamic-content {
    display: none;
  }
  .pgl-similar-products {
    margin-top: 180px;
  }
  /* 2. Show the in-card content */
  .blog-stack-card-content {
    display: block;
    transform: translateY(0);
    padding: 0 1.6rem 1.8rem 1.6rem;
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: 5;
    transition: none;
    background: linear-gradient(180deg, transparent, #3e3e3e);
  }

  .blog-stack-card-content h3 {
    font-size: 1.25rem;
    color: white;
  }
  .blog-stack-card-content p {
    font-size: 0.9rem;
    -webkit-line-clamp: 2;
    color: #fff;
  }

  /* 3. Adjust card inner padding/layout */
  .blog-stack-card-inner {
    padding: 0;
    justify-content: flex-end;
  }

  /* 4. Disable hover effects on mobile */
  .blog-stack-card-inner img {
    transform: scale(1);
    transition: none;
  }

  .blog-stack-card-inner {
    transition: none;
  }

  .blog-stack-card:hover .blog-stack-card-inner img,
  .blog-stack-card:hover .blog-stack-card-inner {
    transform: scale(1);
  }

  /* 6. Adjust card stack layout */
  .blog-stack-container.sticky-cards {
    max-width: 100%;
    height: auto;
  }

  .blog-card-stack-pinned-element {
    height: 60vh;
    max-height: 400px;
  }

  /* Override placeholder for mobile */
  .blog-posts-loader {
    height: 60vh;
    max-height: 400px;
  }

  .blog-stack-card {
    height: 60vh;
    max-height: 400px;
  }
  .related-products-title {
    font-size: 2.3em;
    margin-bottom: 1.8em;
  }
  /* 7. Adjust title alignment */
  .blog-section-title-mask {
    text-align: right;
    margin-bottom: 14px;
  }
  .blog-section-title-mask h2 {
    font-size: 2.4rem;
    text-align: center;
  }
}

.blog-dynamic-link {
  color: #4f5a49 !important;
}
.blog-dynamic-link::before {
  background-image: linear-gradient(
    to left,
    hsl(98.8, 10.4%, 32%) 45%,
    hsl(98.8, 10.4%, 32%, 20.2%) 55%
  ) !important;
}

/* 1. Hide the plugin's "On Sale" / "In Stock" checkboxes */

.sms-notif-form .sms-notif-groups-label {
  display: none !important;
}

/* 2. Hide the form content (the phone field, etc.) by default.

   The plugin's own JS will show this by setting 'display: block'.

*/

.sms-notif-form .sms-notif-content {
  display: none;
}

/* 3. The full-screen overlay (hidden by default) */

/* 1. The Overlay: High Z-index, Fixed to Viewport */
.oab-pwsms-overlay {
  z-index: 9998 !important;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(5px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s;
}
.oab-pwsms-overlay.is-visible {
  opacity: 1;
  visibility: visible;
}
.oab-pwsms-popup-title {
  padding-bottom: 12px;
}
.sms-notif-content br {
  display: none;
}
input.sms-notif-mobile:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.sms-notif-disabled {
  padding-top: 14px;
  max-width: 90%;
  color: var(--color-badge-bg);
  font-weight: 600;
  margin: 0 auto;
}
/* 2. The Popup: Highest Z-index, Fixed to Viewport */
.sms-notif-content.oab-is-popup {
  z-index: 9999 !important; /* Higher than Overlay */
  position: fixed !important; /* Must be fixed to break out of relative parents */
  top: 50% !important;
  left: 50% !important;
  background: #fff;
  padding: 30px;
  padding-top: 40px;
  border-radius: 12px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
  transform: translate(-50%, -50%) !important;
  pointer-events: auto !important;
  width: 90%;
  max-width: 400px;
}

/* 3. The Column: RESET Z-index */
/* When open, we ensure it doesn't have a high z-index, so it sits BEHIND overlay */
.product-column-left.modal-is-open {
  z-index: auto !important;
  transform: none !important;
  animation: none !important;
  opacity: 1 !important;
}

/* 4. Input Fix */
.sms-notif-mobile {
  pointer-events: auto !important;
  direction: rtl !important;
  text-align: right !important;
}

/* --- Standalone Quantity Selector (cleaned) --- */

/* --- Wrapper for Both States --- */
.standalone-selector-wrapper {
  position: relative;
  min-width: 168px;
  display: inline-block;
  height: 48px; /* Set a fixed height */
  user-select: none;
  font-family: inherit; /* Ensure font matches theme */
}

/* --- The Single "Add to Cart" Button --- */
.standalone-single-button {
  background-color: var(--color-btn-primary, #6e8c65);
  color: var(--color-btn-primary-text, #fff);
  border: none;
  border-radius: 12px;
  padding: 0 24px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  height: 100%;
  width: 168px;
  opacity: 1;
  transform: scale(1);
  transition:
    opacity 0.3s ease,
    transform 0.3s ease background-color 0.2s ease-in-out;
  pointer-events: auto;
  z-index: 2;

  position: absolute;
  top: 0;
  right: 0;
  white-space: nowrap;
  width: 100%;
}
.standalone-single-button:hover {
  background-color: var(--color-btn-primary-hover);
  color: var(--color-btn-primary-text) !important;
}

/* --- Positioning the States --- */
/* By default, the quantity selector is hidden and shrunken */
.standalone-qty-selector {
  display: inline-flex;
  align-items: center;
  border-radius: 12px;
  overflow: hidden;
  gap: 6px;

  position: absolute; /* Stacked on top */
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;

  /* Transition for appearing/disappearing */
  opacity: 0;
  transform: scale(0.9);
  transition:
    opacity 0.3s ease,
    transform 0.3s ease;
  pointer-events: none;
  z-index: 1;
}

/* When the wrapper is active, hide the single button */
.standalone-selector-wrapper.is-active .standalone-single-button {
  opacity: 0;
  transform: scale(0.9);
  pointer-events: none;
  z-index: 1;
}
.standalone-qty-add.standalone-qty-btn {
  padding: 12px 16px;
  width: fit-content;
  border-radius: 12px;
  font-size: 16px;
  background-color: var(--color-btn-primary);
  color: var(--color-btn-primary-text);
}
.standalone-qty-add.standalone-qty-btn:hover {
  background-color: var(--color-btn-primary-hover) !important;
}
/* Buttons */

.standalone-qty-btn:hover:not(:disabled) {
  background-color: #f2f1ee;
}

.button-primary {
  background-color: var(--color-btn-primary) !important;
  color: var(--color-btn-primary-text) !important;
  transition: all 0.3s ease-in-out;
  padding: 12px !important;
  border-radius: 24px;
}
.button-primary:hover {
  background-color: var(--color-btn-primary-hover) !important;
}

@keyframes pulse {
  50% {
    opacity: 0.5;
  }
}

/* 5. Close Button (Added by JS) */
.oab-pwsms-popup-close {
  position: absolute;
  top: 8px;
  right: 12px;
  font-size: 28px;
  font-weight: 300;
  color: #888;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  line-height: 1;
}

/* Plugin Input Styling Overrides */
.sms-notif-submit {
  margin-top: 8px !important;
  width: 100% !important;
  border-radius: 12px !important;
  background: var(--color-text-h3) !important;
  color: #fff;
}

.sms-notif-result-p {
  margin-top: 17px;
}

.sms-notif-result img {
  display: none !important;
}

.sms-notif-mobile::placeholder {
  text-align: right !important;
  direction: rtl !important;
}

/* Hide the actual checkbox input */
input.sms-notif-enable {
  display: none !important;
}

/* Style the Label to look like a Button */
.sms-notif-enable-label strong {
  background: var(--color-btn-primary) !important;
  color: var(--color-btn-primary-text) !important;
  border-radius: 12px !important;
  padding: 12px 24px !important;
  font-size: 16px !important;
  font-weight: 600 !important;
  transition: all 0.3s ease-in-out !important;
  cursor: pointer !important;
  display: inline-block;
}

.sms-notif-enable-label:hover strong {
  background: var(--color-btn-primary-hover) !important;
}

/* Result Message Styling */
.sms-notif-result:not(:empty) {
  background: var(--color-accent-subtle) !important;
  border-radius: 12px !important;
  padding: 12px !important;
  width: 100% !important;
  display: block !important;
  color: var(--color-badge-accent) !important;
  text-align: center !important;
}

/* Mobile Sticky Bar Override */
.oab-sticky-add-to-cart-bar .sms-notif-enable-label strong {
  background: transparent !important;
  padding: 0 !important;
  display: inline-flex;
  width: 100%;
  color: var(--color-text-body) !important;
  font-size: 14px !important;
  font-weight: 600 !important;
  padding-left: 12px !important;
}

.oab-sticky-add-to-cart-bar .sms-notif-enable-label:hover strong {
  background-color: transparent !important;
}

/* Product variations */
/* --- Product Group Swatches --- */
.pgl-swatches-container {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 14px;
  margin-bottom: 24px;
}
.pgl-swatch-item {
  display: flex;

  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 8px;
  border-radius: 12px;
  text-decoration: none;
  color: #3b352f;
  transition:
    border-color 0.2s,
    box-shadow 0.2s;
  width: 110px;
  text-align: center;
  cursor: pointer;
}
.pgl-swatch-image {
  transition: transform 0.3s cubic-bezier(0.075, 0.82, 0.165, 1);
  transform: scale(1);
}
.pgl-swatch-item:not(.is-active):hover .pgl-swatch-image img {
  transform: scale(1.05);
}
.pgl-swatch-item.is-active .pgl-swatch-image {
  transform: scale(1.18);
  pointer-events: none;
  opacity: 1;
}
.pgl-swatch-image {
  overflow: hidden;

  flex-shrink: 0;
  border-radius: 14px;
  position: relative;
  border-radius: 12px;
  background: var(--color-card-bg);
  transition: all 0.5s cubic-bezier(0.075, 0.82, 0.165, 1);
  border: 1px solid var(--color-card-border);
}
.pgl-swatch-image img {
  object-position: center;
  transition: all 0.3s ease-in-out;
  height: 100% !important;
  object-fit: cover;
  border-radius: 0 !important;
}
.pgl-swatch-item.is-active .pgl-swatch-title {
  padding-top: 8px;
  color: var(--color-text-h3);
}
.pgl-swatch-title {
  transition: all 0.3s ease-in-out;
  font-weight: 500;
  padding-top: 0px;
  font-size: 14px;
  color: var(--color-text-h6);
  font-size: 14px;
}
/* Loading State for AJAX */
#main-product-content.pgl-loading {
  opacity: 0.5;
  pointer-events: none;
  transition: opacity 0.3s;
}
@media (max-width: 767px) {
  .site-content {
    margin-top: 40px;
  }
}

/* --- Similar Products Section --- */
.pgl-similar-products {

  direction: rtl;
}

.pgl-similar-products h2 {
  font-size: 1.6rem;
  margin-bottom: 20px;
  font-weight: 800;
}

/* --- The Grid --- */
.pgl-similar-products ul.products {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
  padding: 0;
}

/* --- The Card Structure --- */
.pgl-similar-products li.product {
  background: var(--color-product-card-bg, #f6f5f3);
  border-radius: 18px;
  padding: 14px;
  transition:
    transform 0.2s ease,
    background 0.2s ease;
  display: flex !important;
  flex-direction: column !important;
  height: 100% !important;
  box-sizing: border-box !important;
}

.pgl-similar-products li.product:hover {
  background: #ffffff;
  transform: translateY(-4px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.04);
}

/* --- REMOVE STARS & EXTRANEOUS DATA --- */
.pgl-similar-products .star-rating,
.pgl-similar-products .on-woo-wallet-cashback,
.pgl-similar-products .screen-reader-text {
  display: none !important;
}

/* --- Content Styling --- */
.pgl-similar-products li.product img {
  border-radius: 12px;
  margin-bottom: 12px;
  width: 100% !important;
  height: auto !important;
  mix-blend-mode: multiply;
  object-fit: contain !important; /* Keeps image proportions perfect */
}

.pgl-similar-products .woocommerce-loop-product__title {
  font-size: 1rem !important;
  font-weight: 700 !important;
  margin: 0 0 10px 0 !important;
  color: var(--color-text-heading);
  line-height: 1.4;
  display: block;
  padding: 0px 10% !important;
}

.pgl-similar-products li.product .price {
  font-size: 0.95rem !important;
  font-weight: 800 !important;
  margin-bottom: 0 !important;
  display: flex;
  gap: 3px;
  color: var(--color-text-body) !important;
  padding: 0px 10% !important;
  flex-wrap: wrap !important;
}

/* --- Minimal Button --- */
.pgl-similar-products li.product .add_to_cart_button,
.outofstock .button {
  background: var(--color-btn-primary, #d73f3f) !important;
  color: #fff !important;
  border-radius: 12px !important;
  padding: 10px !important;
  font-size: 0.85rem !important;
  font-weight: 700 !important;
  text-align: center;
  border: none !important;
  margin-top: auto;
  width: 80%;
  margin: 0 auto;
  margin-bottom: 24px;
}
.outofstock .button {
  margin-right: auto !important;
  margin-left: auto !important;
}
.pgl-similar-products
  .woocommerce-LoopProduct-link.woocommerce-loop-product__link {
  padding: 8px !important;
}
.woocommerce .products ul::after,
.woocommerce .products ul::before,
.woocommerce ul.products::after,
.woocommerce ul.products::before {
  display: none !important;
}
.pgl-similar-products li.product .add_to_cart_button:hover {
  background: var(--color-btn-primary-hover, #b83535) !important;
}

/* --- Mobile Grid Fix --- */
@media (max-width: 600px) {
  .pgl-similar-products ul.products {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
}
/* 1. RESET LEGACY WOOMMERCE FLOATS */
.woocommerce ul.products[class*="columns-"] li.product,
.woocommerce-page ul.products[class*="columns-"] li.product {
  width: 100% !important; /* Let the Grid container handle the width */
  float: none !important;
  margin: 0 !important;
  clear: none !important;
  padding: 0px !important;
}

/* 2. RE-APPLY THE STABLE GRID */
.pgl-similar-products ul.products {
  display: grid !important;
  /* This ensures 4 columns on desktop, 2 on mobile, NO STRETCHING */
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)) !important;
  gap: 16px !important;
  padding: 0 !important;
}
/* --- MOBILE RESPONSIVENESS --- */
@media screen and (min-width: 820px) {
  .pgl-similar-products ul.products {
    grid-template-columns: repeat(
      4,
      1fr
    ) !important; /* 2 columns for tablets/phones */
  }
}

/* 4. PREVENT IMAGE STRETCHING */

.content-area {
  margin-bottom: 120px;
}

.awdr_discount_bar,
.shahkar-favorite-box {
  display: none !important;
}

/* Active State (Red Filled Heart) */
/* JS will add 'is-active' to the button */
.favorite-btn.is-active .heart-icon {
  fill: #ff4d4d;
  stroke: #ff4d4d;
  transform: scale(1.1); /* Subtle pulse */
}

/* Optional: Button container style */

.favorite-btn:hover {
  transform: scale(1.05);
}

/*Woocommerce*/

.woocommerce div.product p.price ins,
.woocommerce div.product span.price ins {
  background: inherit;
  font-weight: 700;
  display: inline-block;
  text-decoration: none !important;
}

.woocommerce div.product p.price del,
.woocommerce div.product span.price del {
  opacity: 0.5;
  display: inline-block;
}

.woocommerce div.product p.cart {
  margin-bottom: 2em;
}

.woocommerce div.product p.cart::after,
.woocommerce div.product p.cart::before {
  content: " ";
  display: table;
}

.woocommerce div.product p.cart::after {
  clear: both;
}

.woocommerce div.product form.cart {
  margin-bottom: 2em;
}

.woocommerce div.product form.cart::after,
.woocommerce div.product form.cart::before {
  content: " ";
  display: table;
}

.woocommerce div.product form.cart::after {
  clear: both;
}

.woocommerce div.product form.cart div.quantity {
  float: right;
  margin: 0 0 0 4px;
}

.woocommerce div.product form.cart table {
  border-width: 0 0 1px;
}

.woocommerce div.product form.cart table td {
  padding-right: 0;
}

.woocommerce div.product form.cart table div.quantity {
  float: none;
  margin: 0;
}

.woocommerce div.product form.cart table small.stock {
  display: block;
  float: none;
}

.woocommerce .quantity .qty {
  width: 58px;
  text-align: center;
}

.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles))
  #respond
  input#submit,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles))
  a.button,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles))
  button.button,
.woocommerce:where(body:not(.woocommerce-block-theme-has-button-styles))
  input.button,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(
    :not(.edit-post-visual-editor)
  )
  .woocommerce
  #respond
  input#submit,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(
    :not(.edit-post-visual-editor)
  )
  .woocommerce
  a.button,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(
    :not(.edit-post-visual-editor)
  )
  .woocommerce
  button.button,
:where(body:not(.woocommerce-block-theme-has-button-styles)):where(
    :not(.edit-post-visual-editor)
  )
  .woocommerce
  input.button {
  font-size: 100%;
  margin: 0;
  line-height: 1;
  cursor: pointer;
  position: relative;
  text-decoration: none;
  overflow: visible;
  padding: 0.618em 1em;
  font-weight: 700;
  border-radius: 3px;
  right: auto;
  color: var(--color-btn-primary-text, #fff) !important;
  background-color: #e9e6ed;
  border: 0;
  display: inline-block;
  background-image: none;
  box-shadow: none;
  text-shadow: none;
}
.woocommerce ul.products li.product .button {
  display: inline-block;
  margin-top: auto;
  margin-bottom: 18px;
}

/*reviews-style*/

//* --- Modal Styles --- */
/* --- Modern Reviews Section Entrance Animations --- */

/* 1. Base Hidden State for the Main Container */
#reviews.modern-reviews-section {
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s ease-out, visibility 0s linear 0.4s;
}

/* 2. Base Hidden States for Inner Elements (Slide Up) */
.reviews-header,
.modern-reviews-swiper,
.woocommerce-noreviews {
  opacity: 0;
  transform: translateY(30px);
  will-change: opacity, transform;
}

/* Base Hidden State for Buttons (Scale Up) */
.reviews-swiper-container .swiper-button-prev,
.reviews-swiper-container .swiper-button-next {
  opacity: 0;
  transform: translateY(-50%) scale(0.5) !important; /* Note: keep the Y translate for vertical centering */
  will-change: opacity, transform;
}

/* --- ACTIVE STATES (Triggered by .is-visible) --- */

/* 1. Fade in Main Container */
#reviews.modern-reviews-section.is-visible {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.4s ease-out, visibility 0s linear 0s;
}

/* 2. Slide Up Header (Delay 0.2s) */
#reviews.modern-reviews-section.is-visible .reviews-header {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.8s cubic-bezier(0.215, 0.610, 0.355, 1) 0.2s, 
              transform 0.8s cubic-bezier(0.215, 0.610, 0.355, 1) 0.2s;
}

/* 3. Slide Up Swiper/Content (Delay 0.6s) */
#reviews.modern-reviews-section.is-visible .modern-reviews-swiper,
#reviews.modern-reviews-section.is-visible .woocommerce-noreviews {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.8s cubic-bezier(0.215, 0.610, 0.355, 1) 0.6s, 
              transform 0.8s cubic-bezier(0.215, 0.610, 0.355, 1) 0.6s;
}

/* 4. Scale Up Buttons (Delay 0.7s and 0.8s for Stagger) */
/*#reviews.modern-reviews-section.is-visible .swiper-button-prev {*/
/*  opacity: 1;*/
/*  transform: translateY(-50%) scale(1) !important;*/
/*  transition: opacity 0.5s cubic-bezier(0.215, 0.610, 0.355, 1) 0.7s, */
/*              transform 0.5s cubic-bezier(0.215, 0.610, 0.355, 1) 0.7s;*/
/*}*/

/*#reviews.modern-reviews-section.is-visible .swiper-button-next {*/
/*  opacity: 1;*/
/*  transform: translateY(-50%) scale(1) !important;*/
/*  transition: opacity 0.5s cubic-bezier(0.215, 0.610, 0.355, 1) 0.8s, */
/*              transform 0.5s cubic-bezier(0.215, 0.610, 0.355, 1) 0.8s;*/
/*}*/
.review-modal-wrapper,
.replies-modal-wrapper {
  visibility: hidden;
  opacity: 0;
  position: fixed;
  pointer-events: none; /* Prevent interaction when hidden */
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1000;
  justify-content: center;
  align-items: center;
  transition: opacity 0.3s ease; /* Transition only opacity when opening */
}
.review-modal-wrapper.is-open,
.replies-modal-wrapper.is-open {
  visibility: visible;
  pointer-events: auto; /* Allow interaction when open */
  opacity: 1;
}
.review-modal-overlay,
.replies-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.6);
  cursor: pointer;
}
.review-modal-container,
.replies-modal-container {
  position: relative;
  background-color: var(--color-popup-bg, #fff);
  border-radius: 12px;
  width: 90%;
  padding: 24px;

  width: 600px;
  max-width: 90%;
  max-height: 80vh;
  overflow-y: auto;
  z-index: 1001;
  display: flex;
  flex-direction: column;
  transform: translateY(20px);
  transition: transform 0.3s ease;
}
.replies-modal-wrapper.is-open .replies-modal-container {
  transform: translateY(0);
}
.review-modal-header,
.replies-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
  border-bottom: 1px solid #e0e0e0;
}
.review-modal-close,
.replies-modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
}
.review-modal-content,
.replies-modal-content {
  padding: 1.5rem;
}
.replies-modal-content {
  display: flex;
  flex-direction: column-reverse;
  gap: 32px;
}

/* --- Custom Comment Form --- */
.oab-comment-form {
  display: flex;
  flex-direction: column;
  gap: 0px;
}
.oab-form-row {
  width: 100%;
}
*:focus-visible {
  outline: none !important;
}
.oab-star-rating-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 20px;
}
.oab-stars {
  display: inline-flex; /* Use inline-flex to respect text direction */
  cursor: pointer;
  gap: 4px;
}
.oab-star {
  width: 26px;
  height: 26px;
  stroke: var(--color-nutrition-border, #e8e9e4);
  fill: var(--color-nutrition-border, #e8e9e4);
  transition: fill 0.2s ease-in-out, stroke 0.2s ease-in-out;
}

/* A single class now controls the filled state. JavaScript will manage it. */
.oab-star.is-active {
  fill: #f5a623;
  stroke: #f5a623;
}

.oab-editor-toolbar {
  display: flex;
  gap: 5px;
  padding: 12px 16px;
  border-radius: 21px;
  background: none;
  position: absolute;
  bottom: 0;
}

.oab-toolbar-btn {
  cursor: pointer;
  border: 1px solid transparent;
  background: #ffffff78;
  border-radius: 8px;
  aspect-ratio: 1 / 1;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.oab-toolbar-btn b,
.oab-toolbar-btn i {
  height: 100%;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  justify-content: center;
  color: var(--color-accent, #6e8c65);
  margin-top: 4px;
  font-size: 15px;
}
.oab-toolbar-btn:hover {
  background-color: #ffffffba;
}
.oab-image-upload-label {
  position: relative;
}
.oab-image-upload-label svg {
  height: 16px;
  color: var(--color-accent, #6e8c65);
  width: 16px;
}
.oab-image-upload-input {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}
.oab-comment-textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #ddd;
  border-top: none;
  border-radius: 0 0 4px 4px;
  resize: vertical;
  min-height: 120px;
}

.oab-image-preview img {
  min-width: 100% !important;
  height: 100% !important;
  max-height: 100% !important;
  width: 100% !important;
  object-fit: cover;
  border-radius: 12px;
}
.oab-form-messages {
  padding: 10px;
  border-radius: 12px;
  display: none;
}
.oab-form-messages.error {
  background-color: #f8d7da;
  color: #721c24;
  display: block;
  margin-bottom: 8px;
}
.oab-form-messages.success {
  background-color: #d4edda;
  color: #155724;
  display: block;
  margin-bottom: 8px;
}
.form-submit {
  display: flex;
  align-items: center;
  gap: 15px;
}
.oab-submit-btn {
  /* Add your button styles here */
  padding: 10px 20px;
  cursor: pointer;
  width: 100% !important;
  background: var(--color-btn-primary, #d73f3f);
  border-radius: 12px;
  color: var(--color-btn-primary-text, #fffdfc);
}
.oab-submit-btn:hover {
  background: var(--color-btn-primary-hover, #b83535);
}
.oab-loader {
  border: 4px solid #f3f3f3;
  border-radius: 50%;
  border-color: var(--color-accent, #6e8c65) var(--color-border-subtle, #e9e5e1)
    var(--color-border-subtle, #e9e5e1);
  border-top: 4px solid var(--color-accent, #6e8c65);
  width: 24px;
  height: 24px;
  min-width: 24px;
  min-height: 24px;
  max-width: 24px;
  max-height: 24px;
  animation: spin 1s linear infinite;
}
@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* Newly added comment styles */

.reply-item {
  display: flex;
  gap: 15px;
  padding: 1rem 0;
  border-bottom: 1px solid #eee;
}
.reply-item:last-child {
  border-bottom: none;
}

/* --- Comment Action Buttons --- */

/* Base styles for all action containers */
.oab-comment-actions {
  display: flex;
  gap: 10px;
}

/* Styles ONLY for actions IN THE REVIEW CARD */
.review-card .oab-comment-actions {
  position: absolute;
  top: 12px;
  right: 21px;
}

/* Styles ONLY for actions IN A REPLY ITEM */
.reply-item .oab-comment-actions {
  position: static; /* This puts the buttons back in the normal flow */
  margin-top: 10px; /* This adds some space above the buttons */
}
.oab-edit-comment,
.oab-delete-comment {
  background: none;
  border: none;
  color: #666;
  cursor: pointer;
  font-size: 14px;
  text-decoration: underline;
  padding: 0;
}
.oab-delete-comment {
  color: #c00;
}

/* --- Edit Form --- */
.oab-edit-form {
  width: 100%;
  margin-top: 10px;
}
.oab-edit-textarea {
  width: 100%;
  min-height: 100px;
  padding: 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
}
.oab-edit-actions {
  margin-top: 8px;
  display: flex;
  gap: 10px;
}
.oab-save-edit,
.oab-cancel-edit {
  padding: 5px 15px;
  border-radius: 3px;
  cursor: pointer;
  border: 1px solid #ccc;
}
.oab-save-edit {
  background-color: #2684ff;
  color: white;
  border-color: #2684ff;
}

.comment-image-attachment {
  height: 48px;
  width: 48px;
  border-radius: 7px !important;
}
.comment-image-attachment:hover img {
  transform: scale(1.04);
}

.comment-image-attachment img {
  transition: all 0.3s ease-in-out;
  height: 100% !important;
  width: 100% !important;
  border-radius: 7px !important;
  border: 2px solid var(--color-border, #e5e2de);
  cursor: pointer;
}
/* --- Vanilla Lightbox Core --- */
.oab-lightbox-wrapper {
    visibility: hidden;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 99999;
    /* Delay visibility hidden until opacity transition finishes */
    transition: visibility 0s linear 0.3s; 
    display:flex;
    align-items:center;
    justify-content:center;
}

/* When the JS adds the is-open class */
.oab-lightbox-wrapper.is-open {
    visibility: visible;
    transition: visibility 0s linear 0s;
}

/* --- Overlay Fade --- */
.oab-lightbox-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--color-popup-overlay, #1a1c184d);
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.oab-lightbox-wrapper.is-open .oab-lightbox-overlay {
    opacity: 1;
}

/* --- Content Scale & Fade (The Image Container) --- */
/* --- Content Scale & Fade (The Image Container) --- */
.oab-lightbox-content-wrapper {
    opacity: 0;
    transform: scale(0.8);
    transition: opacity 0.3s cubic-bezier(0.25, 1, 0.5, 1), 
                transform 0.3s cubic-bezier(0.25, 1, 0.5, 1);
    will-change: opacity, transform;
    
    /* NEW: Use flexbox for perfect centering instead of hardcoded translates */
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    pointer-events: none; /* Let clicks pass through the wrapper to the overlay */
}

.oab-lightbox-wrapper.is-open .oab-lightbox-content-wrapper {
    opacity: 1;
    transform: scale(1);
}
.oab-lightbox-content-wrapper{
    width: 90vw !important;
    max-width: 90vw !important;
}
.oab-lightbox-content{
      max-width: 90vw !important;
  width: fit-content !important;
}
/* Container for the image and close button */
.oab-lightbox-content,
.oab-lightbox-content-wrapper {
  position: relative;
  z-index: 10000;

  max-height: 60vh !important;
  height: 60vh !important;
  background: var(--color-popup-overlay, #1a1c184d);
  border-radius: 21px;
  /* GSAP will animate this from a smaller scale */
}
/* Container for the image and close button */
.oab-lightbox-content {
    position: relative;
    z-index: 10000;
    pointer-events: auto; /* Re-enable clicks on the actual content */
    
    /* NEW: Max bounds to ensure it never overflows the screen */
    max-width: 90vw !important;
    max-height: 80vh !important;
    width: fit-content !important;
    height: fit-content !important;
    
    background: transparent; /* Remove the dark background from the image container itself */
    border-radius: 21px;
}
.oab-lightbox-content img {
    display: block;
    /* Limit the image size to the viewport minus some padding */
    max-width: 90vw;
    max-height: 80vh;
    width: auto;
    height: auto;
    object-fit: contain;

    position: relative;
    left: 0;
    top: 0;

    border-radius: 4px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3); /* Slightly stronger shadow for depth */
    transition: transform 0.25s ease;
    cursor: zoom-in;
}
.oab-lightbox-input[type="checkbox"] {
  display: none;
}
.oab-lightbox-input[type="checkbox"]:checked ~ label > img {
  transform: scale(2);
  cursor: grab;
}
.oab-lightbox-input[type="checkbox"]:checked ~ label > img.is-dragging {
  cursor: grabbing;
}
/* Close button */
.oab-lightbox-close {
  position: absolute;
  top: -15px;
  right: -15px;
  width: 30px;
  height: 30px;
  background-color: #fff;
  color: #333;
  border: none;
  border-radius: 50%;
  font-size: 20px;
  line-height: 30px;
  text-align: center;
  cursor: pointer;
  z-index: 10000;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.oab-preview-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;

  padding: 16px;
}

.oab-preview-item {
  position: relative;
  width: 64px;
  height: 64px;
  border: 1px solid #ddd;
  border-radius: 12px;
  overflow: hidden;
}

.oab-remove-preview-btn {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 20px;
  height: 20px;
  background-color: rgba(0, 0, 0, 0.6);
  color: white;
  border: none;
  border-radius: 50%;
  font-size: 14px;
  font-weight: bold;
  line-height: 18px;
  text-align: center;
  cursor: pointer;
  padding: 0;
  opacity: 0.8;
  transition: opacity 0.2s;
}

.oab-remove-preview-btn:hover {
  opacity: 1;
}
.comment-image-gallery {
  display: flex;
  gap: 6px;
  align-items: center;
  justify-content: start;
  margin-top: 12px;
}
.comment-text {
  margin-top: 2px;
}

/* --- Inline Edit Form for Replies --- */
.oab-inline-edit-form-wrapper {
  width: 100%;
  margin-top: 0px;
  padding: 15px;
  background-color: var(--color-nav-bg, #f7f6f3);
  border: 1px solid var(--color-top-nav-bg, #f2f1ee);
  border-radius: 24px;
}

.oab-inline-edit-form .form-submit {
  gap: 10px;
  justify-content: flex-end;
}

.oab-inline-edit-form .oab-submit-btn,
.oab-inline-edit-form .oab-cancel-edit-btn {
  padding: 8px 16px;
  font-size: 14px;
  border-radius: 12px;
  border: 1px solid transparent;
}

/* --- Inline Edit Form for Replies (from previous update) --- */

.oab-inline-edit-form .form-submit {
  gap: 10px;
  flex-direction: row-reverse;
  justify-content: end;
}
.oab-inline-edit-form .oab-submit-btn,
.oab-inline-edit-form .oab-cancel-edit-btn {
  padding: 8px 16px;
  font-size: 14px;
  border: 1px solid transparent;
}
.oab-cancel-edit-btn {
  cursor: pointer;
  background-color: var(--color-border-subtle, #e9e5e1);
  color: var(--color-text-h3, #5a5048);
  transition: all 0.3s ease-in-out;
}
.oab-cancel-edit-btn:hover {
  background-color: var(--color-border, #e5e2de);
}

/* --- NEW: Deletion Pending State --- */
.comment-is-deleting {
  opacity: 0.5;
  position: relative;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.comment-is-deleting::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 24px;
  height: 24px;
  margin-top: -12px;
  margin-left: -12px;
  border: 3px solid rgba(0, 0, 0, 0.2);
  border-top-color: #000;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}
.reply-item .comment-is-deleting::after {
  border: 3px solid rgba(255, 255, 255, 0.5);
  border-top-color: #fff;
}

/* --- NEW: Custom Alert Modal --- */
.oab-alert-modal-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 10001; /* Higher than other modals */
  display: flex;
  justify-content: center;
  align-items: center;
  visibility: hidden;
  opacity: 0;
  transition: visibility 0s 0.2s, opacity 0.2s ease-in-out;
}
.oab-alert-modal-wrapper.is-open {
  visibility: visible;
  opacity: 1;
  transition: opacity 0.2s ease-in-out;
}
.oab-alert-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--color-popup-overlay, #1a1c184d);
}
.oab-alert-modal-container {
  position: relative;
  background: var(--color-popup-bg, #fff);
  padding: 25px 30px;
  border-radius: 8px;
  width: 90%;
  max-width: 400px;
  text-align: center;
  transform: scale(0.95);
  transition: transform 0.2s ease-in-out;
}
.oab-alert-modal-wrapper.is-open .oab-alert-modal-container {
  transform: scale(1);
}
.oab-alert-modal-title {
  font-size: 1.25rem;
  margin-top: 0;
  margin-bottom: 10px;
}
.oab-alert-modal-title.is-error {
  color: #dc3545;
}
.oab-alert-modal-message {
  margin: 0;
  color: #495057;
}
.oab-alert-modal-actions {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-top: 25px;
}
.oab-alert-btn {
  padding: 10px 25px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-weight: bold;
  transition: background-color 0.2s;
}
.oab-alert-btn-confirm {
  background-color: #c82333;
  color: white;
}
.oab-alert-btn-confirm:hover {
  background-color: #a81c2b;
}
.oab-alert-btn-cancel,
.oab-alert-btn-ok {
  background-color: #7f7773;
  color: white;
}
.oab-alert-btn-cancel:hover,
.oab-alert-btn-ok:hover {
  background-color: #6a615d;
}
.review-card.is-saving {
  opacity: 0.6;
  pointer-events: none; /* Prevents clicks while saving */
}

/* --- Modern Reviews Section --- */
.modern-reviews-section {
  padding: 4rem 0;
  position: relative;
}
#pgl-product-reviews {
  margin-top: 130px !important;
  margin-bottom: 130px;
}
.modern-reviews-swiper .swiper-wrapper {
  align-items: center;
}

.review-card-content p {
  font-size: 18px;
  text-align: center;
}
.reviews-header {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  margin: 0 auto 2.5rem auto;
  max-width: 800px;
  padding: 0 1rem;
  gap: 16px;
}
.reviews-title {
  font-size: clamp(1.5rem, 4vw, 2.25rem);
  margin: 0;
}
.average-rating-display {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.5rem;
}
.review-author-avatar img {
  height: 30px !important;
  width: 30px !important;
  border-radius: 50%;
  object-fit: cover;
}
.reply-button-wrapper {
  transition: all 0.3s ease-in-out;
}
.show-replies-button:hover .reply-button-wrapper {
  transform: translateX(-1px);
}
.review-card-footer-wrapper {
  flex-direction: row-reverse;
  position: absolute;
  bottom: 12px;
  row-gap: 21px;
  right: 12px;
  flex-wrap: wrap-reverse;
  left: 12px;
  justify-content: space-between;
}
@media (max-width: 380px) {
  .review-author-meta {
    flex-grow: 1;

    /* position: absolute; */
    /* bottom: 12px; */
    /* right: 12px; */
  }
}
.review-author-avatar {
  display: flex;
  background: #f2f1eec2;
  border-radius: 36px;
  align-items: center;
  justify-content: start;
  padding-right: 5px;
  padding-left: 14px;
  border: 1px solid var(--color-card-border, #eae9e4);
  gap: 8px;
}
.review-author-name {
  font-size: 12px;
  font-weight: 500;
}
.avg-rating-count {
  font-weight: 500;
  color: #777;
}
.write-review-button {
  background-color: #d73f3f;
  color: white;
  border: none;
  padding: 0.8rem 1.5rem;
  border-radius: 21px !important;
  cursor: pointer;
  font-weight: bold;
}

/* This new container will clip the overflow */
.reviews-swiper-container {
  position: relative;
  width: 100%;
  overflow: hidden; /* This is the key fix */
  padding: 0 30px; /* Add padding so arrows are not on the very edge */
  box-sizing: border-box;
}
/* --- Swiper Carousel (KEY STYLES) --- */
.modern-reviews-swiper {
  width: 100%;
  overflow: visible; /* CRITICAL: Allows side slides to be seen */
}

.modern-reviews-swiper .swiper-slide {
  width: 40%; /* Give slides a fixed width */
  min-width: 380px;
  max-width: 90%;
  height: fit-content;
  transition: transform 0.4s ease, opacity 0.4s ease;

  /* Default state: scaled down and faded */
  transform: scale(0.85);
  opacity: 0.5;
}

/* Add this media query to target mobile phones.
  Using 480px is a common breakpoint.
*/
@media (max-width: 480px) {
  .modern-reviews-swiper .swiper-slide {
    /* 1. Remove the minimum width */
    min-width: 0;
    opacity: 0.8;
    /* 2. Set a new width for mobile (e.g., 90% or 100%) */
    width: 100%;
  }
}
/* The active (center) slide */
.modern-reviews-swiper .swiper-slide-active {
  transform: scale(1);
  opacity: 1;
}

.review-card {
  width: 100%;
  height: 100%;
  background: var(--color-content-bg, #fdfdfd);
  border: 1px solid #f2f1ee;
  border-radius: 32px;
  padding: 40px;
  padding-bottom: 92px;
  box-shadow: 0 4px 25px rgba(0, 0, 0, 0.07);
}

@media (max-width: 680px) {
  .review-card {
    padding: 35px 25px;
    padding-bottom: 86px;
  }
}

@media (max-width: 400px) {
  .review-card {
    padding-bottom: 131px;
  }
}
/* --- Navigation Arrows --- */
.modern-reviews-swiper .swiper-button-next,
.modern-reviews-swiper .swiper-button-prev {
  color: #3b352f; /* Your body text color */
  top: 50%;
  transform: translateY(-50%);
}

@media (max-width: 768px) {
  .modern-reviews-swiper .swiper-button-next {
    right: 0px;
  }
  .modern-reviews-swiper .swiper-button-prev {
    left: 0px;
  }
}

/* --- NEW FIX: Hide Swiper buttons if disabled OR if no reviews exist --- */

/* * 1. Hides buttons when Swiper disables them (e.g., 1-2 slides)
 * We target the parent .reviews-swiper-container instead of the swiper div.
*/
.reviews-swiper-container .swiper-button-disabled {
  opacity: 0 !important; /* Use !important to override other styles if needed */
  pointer-events: none;
  transition: opacity 0.3s ease;
}

/* * 2. Hides buttons if there are 0 reviews.
 * This looks for the "no reviews" message and hides any
 * button elements that are siblings *after* it.
*/
.woocommerce-noreviews {
  margin-bottom: 100px;
}
.woocommerce-noreviews ~ .swiper-button-prev,
.woocommerce-noreviews ~ .swiper-button-next {
  display: none;
}
.reviews-summary {
  text-align: center;
}

#pgl-product-reviews {
  display: flex;
  flex-direction: column;
}

/* --- Modals --- */

.review-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--color-popup-overlay, #1a1c184d);
  z-index: 1000;
}
.review-modal-container {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: var(--color-popup-bg, #fff);
  border-radius: 12px;
  width: 90%;
  max-width: 500px;
  z-index: 1001;
}
.review-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid #eae9e4;
}
.review-modal-title {
  font-size: 1.25rem;
  margin: 0;
}

.review-modal-content {
  padding: 1.5rem;
}

#review_form #reply-title {
  display: none; /* Hide the default title */
}

/* --- Custom SVG Star Rating --- */
.custom-star-rating {
  display: inline-flex;
  gap: 4px;
}

.star-icon-wrapper svg {
  width: 21px;
  height: 21px;
}

/* "Filled" star style */
.star-icon-wrapper.is-filled svg path {
  fill: #d4a25f;
  stroke: #d4a25f;
  stroke-width: 1.5px;
}

/* "Empty" star style */
.star-icon-wrapper.is-empty svg path {
  fill: transparent;
  stroke: var(--color-border-muted, #d8cfc6);
  stroke-width: 1.5px;
}

.show-replies-button {
  border-radius: 24px;
  display: flex;
  gap: 6px;
  height: fit-content;
  width: fit-content;
  align-items: center;
}
.reply-button-wrapper {
  border-radius: 50%;
  height: 100%;
  aspect-ratio: 1;
  width: auto;
  display: flex;
  align-items: center;
  justify-content: center;
}
.review-card-footer {
  margin-right: 24px;
  margin-left: 8px;
  /* position: absolute;
  
  left: 20px;
  bottom: 24px; */
}
.reply-button {
  fill: var(--color-badge-accent, #6e8c65);
  font-size: 19px;
  margin-bottom: 2px;
}

/* Replies */
/* --- Replies Modal --- */
.replies-modal-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  visibility: hidden;
  opacity: 0;
  transition: visibility 0s 0.3s, opacity 0.3s ease;
}
.replies-modal-wrapper.is-open {
  visibility: visible;
  opacity: 1;
  transition-delay: 0s;
}
.replies-modal-overlay {
  position: fixed;
  inset: 0;
  background-color: var(--color-popup-overlay, #1a1c184d);
  cursor: pointer;
}

.replies-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #eee;
  padding-bottom: 16px;
  margin-bottom: 16px;
}
.replies-modal-title {
  font-size: 18px;
  font-weight: 700;
  margin: 0;
}
.replies-modal-close {
  /* Basic close button styling */
  width: 24px;
  height: 24px;
  border: none;
  background: none;
  cursor: pointer;
  position: relative;
}
.replies-modal-close::before,
.replies-modal-close::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 11px;
  width: 14px;
  height: 2px;
  background-color: #333;
}
.replies-modal-close::before {
  transform: rotate(45deg);
}
.replies-modal-close::after {
  transform: rotate(-45deg);
}

/* Replies List Styling */
.replies-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 30px;
}
.reply-item {
  display: flex;
  gap: 12px;
}
.reply-author-avatar img {
  border-radius: 50%;
  aspect-ratio: 1 !important;
  height: 50px !important;
  width: auto !important;
  max-width: 50px !important;
  max-height: 50px !important;
  min-width: 50px !important;
  min-height: 50px !important;
}
.reply-meta {
  display: flex;
  align-items: baseline;
  gap: 8px;
}
.reply-date {
  font-size: 12px;
  color: #888;
}
.reply-text p {
  margin: 4px 0 0;
}
.no-replies {
  text-align: center;
  color: #888;
}

/* Reply Form Styling */

.reply-form-container .comment-form-comment,
.reply-form-container .comment-form-author,
.reply-form-container .comment-form-email {
  margin-bottom: 15px;
}
.reply-form-container input[type="text"],
.reply-form-container textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 4px;
}

/* Styling for the new rich text editor */
.oab-rich-textarea {
  width: 100%;
  resize: vertical;
  min-height: 150px;
  overflow-y: auto; /* Add scroll for long content */
  cursor: text;

  background: var(--color-card-bg, #f2f1ee);
  border-radius: 16px 16px 0 0;
  border: 1px solid var(--color-card-border, #eae9e4);
  padding: 16px;
  padding-bottom: 48px;
}
.oab-image-preview {
  background: var(--color-card-bg, #f2f1ee);
  border-radius: 0 0 16px 16px;
  border: 1px solid var(--color-card-border, #eae9e4);
  margin-bottom: 12px;
  border-top: none;
  transition: height 0.3s cubic-bezier(0.075, 0.82, 0.165, 1);

  height: 96px;
}
.oab-image-preview.empty,
.oab-image-preview:empty {
  height: 0;
}
.oab-comment-form:has(.oab-image-preview.empty) .oab-rich-textarea,
.oab-comment-form:not(:has(.oab-image-preview)) .oab-rich-textarea,
.oab-comment-form:has(.oab-image-preview:empty) .oab-rich-textarea {
  border-radius: 16px !important;
}
.oab-comment-form:has(.oab-image-preview.empty) .oab-image-preview,
.oab-comment-form:not(:has(.oab-image-preview)) .oab-image-preview,
.oab-comment-form:has(.oab-image-preview:empty) .oab-image-preview {
  border: none !important;
}
/* Placeholder text styling */
.oab-rich-textarea:empty:before {
  content: attr(data-placeholder);
  color: var(--color-text-h4, #6a6159);
  cursor: text;
}

.oab-image-upload-notice {
  color: #721c24;
  background-color: #f8d7da;
  border: 1px solid #f5c6cb;
  padding: 0.75rem 1.25rem;
  margin-bottom: 12px;
  border-radius: 0.25rem;
  font-size: 0.9em;
  line-height: 1.5;
}

/* --- Verified Owner Badge --- */
.oab-verified-owner-badge {
  display: inline-block;
  background-color: var(--color-accent-subtle, #d5e5d6);
  color: var(--color-accent, #6e8c65);
  padding: 2px 8px;
  margin-right: 6px;
  font-size: 0.75em;
  font-weight: 600;
  border-radius: 23px;
  vertical-align: middle;
  line-height: 1.5;
}

/* Adjust alignment within the flex container */
.review-author-avatar .flex-col {
  padding: 4px 0px;
  align-items: flex-start; /* Ensure items start from the left (in LTR context) */
}
.review-author-name {
  display: inline-flex; /* Make sure name and badge flow correctly */
  align-items: center;
  margin-bottom: 0;
}
.review-author-name:has(.oab-verified-owner-badge) {
  margin-bottom: 4px;
}

/* Styles for the badge within replies */
.reply-meta .oab-verified-owner-badge {
  margin-left: 0; /* Adjust spacing if needed for replies */
  margin-right: 6px;
}


/*Add to Cart*/

/* --- State 1: Quantity Selector (+ / -) --- */

/* --- ACTIVE STATE (Swapping the buttons) --- */
.standalone-selector-wrapper.is-active .standalone-qty-selector {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
  z-index: 2;
}

/* --- Buttons (+/-) --- */
.standalone-qty-btn {
  border: none;
  line-height: 1;
  cursor: pointer;
  padding: 0;
  font-size: 20px;
  width: 48px;
  height: 100%;
  border-radius: 9px;
  z-index: 2;
  background: var(--color-card-bg, #f2f1ee);
  color: #333;
  transition: background 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}
.standalone-qty-btn:hover {
  background-color: #e0ded9;
}
.standalone-qty-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* --- Number Display (The Animation Container) --- */
.standalone-qty-count-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 18px;
  font-weight: 600;
  width: 60px;
  flex: 1;
  height: 100%;
  position: relative;
  overflow: hidden; /* Masking the sliding numbers */
  border: 1px solid var(--color-card-border, #e5e5e5);
  border-radius: 9px;
  background: transparent;
}

/* The vertical strip that holds numbers */
.standalone-qty-count-inner {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  /* This is what we animate */
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Each digit takes up full height */
.count-digit {
  position: absolute;
  top: 0;
  left: 0;
  line-height: 48px; /* vertical centering */
  text-align: center;
  will-change: transform;
  pointer-events: none; /* avoid clicks on digits */
  height: 48px; /* Must match container height */
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 600;
  flex-shrink: 0;
}

/* --- Loading Spinner --- */
.standalone-selector-wrapper.loading {
  opacity: 0.7;
  pointer-events: none;
  cursor: wait;
  animation: pulse 1.3s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}
/* Safe Bounce Animation */
.site-cart-count {
  /* Ensure the browser knows to transition the scale property */
  transition: scale 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  scale: 1; /* Default scale */
  transform-origin: center center;
}

.site-cart-count.oab-bounce-active {
  scale: 1.2; /* Zooms in without moving position */
}

/*PGL Swatches*/
/* Styling for the new Product Group Links */

.pgl-custom-links-list {
  list-style: none;
  padding: 0;
  margin: 20px 0;
  display: flex; /* Enable flexbox for horizontal layout */
  flex-wrap: wrap; /* Allow items to wrap to the next line */
  gap: 15px; /* Spacing between items */
}

.pgl-custom-links-list h2 {
  font-size: 1.2em;
  margin-bottom: 15px;
  padding-bottom: 5px;
  border-bottom: 1px solid #eee;
  width: 100%; /* Ensure heading spans full width */
}

/* Individual link item styling */
.pgl-link-item {
  flex: 0 0 100px; /* Base width: 100px wide */
  text-align: center;
  border: 1px solid #eee;
  padding: 8px;
  border-radius: 4px;
  transition: all 0.2s ease-in-out;
  cursor: pointer;
}

.pgl-link-item:hover {
  border-color: #0073aa; /* Highlight border on hover */
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.pgl-link-item a {
  text-decoration: none;
  color: inherit;
  display: flex; /* Flex on the link itself */
  flex-direction: column; /* Stack image and title vertically */
  align-items: center;
  justify-content: space-between;
  height: 100%; /* Ensure the link fills the list item */
}

/* Image styling */
.pgl-link-thumbnail {
  width: 80px; /* Control image width */
  height: 80px; /* Control image height */
  object-fit: contain;
  display: block;
  margin: 0 auto;
  border-radius: 2px;
}

/* Title styling */
.pgl-link-title {
  font-size: 0.85em;
  font-weight: 500;
  line-height: 1.2;
  margin-top: 5px;
  display: -webkit-box;
  -webkit-line-clamp: 2; /* Limit title to two lines */
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/*Mini Swiper BUndle*/
/* --- LEAN SWIPER CORE (Only what you need) --- */
:root {
  --swiper-theme-color: #007aff;
  --swiper-navigation-size: 44px;
}
.swiper {
  margin-left: auto;
  margin-right: auto;
  position: relative;
  overflow: hidden;
  list-style: none;
  padding: 0;
  z-index: 1;
  display: block;
}
.swiper-wrapper {
  position: relative;
  width: 100%;
  height: 100%;
  z-index: 1;
  display: flex;
  transition-property: transform;
  box-sizing: content-box;
}
.swiper-android .swiper-slide,
.swiper-ios .swiper-slide,
.swiper-wrapper {
  transform: translate3d(0px, 0, 0);
}
.swiper-horizontal {
  touch-action: pan-y;
}
.swiper-slide {
  flex-shrink: 0;
  width: 100%;
  height: 100%;
  position: relative;
  transition-property: transform;
  display: block;
}
.swiper-slide-invisible-blank {
  visibility: hidden;
}
.swiper-autoheight,
.swiper-autoheight .swiper-slide {
  height: auto;
}
.swiper-autoheight .swiper-wrapper {
  align-items: flex-start;
  transition-property: transform, height;
}

/* --- Navigation Arrows --- */
.swiper-button-next,
.swiper-button-prev {
  position: absolute;
  top: 50%;
  width: calc(var(--swiper-navigation-size) / 44 * 27);
  height: var(--swiper-navigation-size);
  margin-top: calc(0px - (var(--swiper-navigation-size) / 2));
  z-index: 10;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--swiper-navigation-color, var(--swiper-theme-color));
}
.swiper-button-next.swiper-button-disabled,
.swiper-button-prev.swiper-button-disabled {
  opacity: 0.35;
  cursor: auto;
  pointer-events: none;
}
.swiper-button-next.swiper-button-hidden,
.swiper-button-prev.swiper-button-hidden {
  opacity: 0;
  cursor: auto;
  pointer-events: none;
}
.swiper-button-next svg,
.swiper-button-prev svg {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transform-origin: center;
}
.swiper-rtl .swiper-button-next svg,
.swiper-rtl .swiper-button-prev svg {
  transform: rotate(180deg);
}
.swiper-button-prev,
.swiper-rtl .swiper-button-next {
  left: 10px;
  right: auto;
}
.swiper-button-next,
.swiper-rtl .swiper-button-prev {
  right: 10px;
  left: auto;
}

/* --- Pagination (Dots) - Keep only if you use dots --- */
.swiper-pagination {
  position: absolute;
  text-align: center;
  transition: 0.3s opacity;
  transform: translate3d(0, 0, 0);
  z-index: 10;
}
.swiper-pagination.swiper-pagination-hidden {
  opacity: 0;
}
.swiper-horizontal > .swiper-pagination-bullets,
.swiper-pagination-bullets.swiper-pagination-horizontal {
  bottom: 8px;
  top: auto;
  left: 0;
  width: 100%;
}
.swiper-pagination-bullet {
  width: 8px;
  height: 8px;
  display: inline-block;
  border-radius: 50%;
  background: #000;
  opacity: 0.2;
  margin: 0 4px;
  cursor: pointer;
}
.swiper-pagination-bullet-active {
  opacity: 1;
  background: var(--swiper-pagination-color, var(--swiper-theme-color));
}





/*content panel*/


/* 1. Main Layout: Wider Container (950px) */
.content-panel .single-product .site-main {
  margin-top: 120px;
  max-width: 950px !important; /* Increased width */
}
@media (max-width: 950px) {
     .content-panel .single-product .site-main {
        padding-left:3rem !important;
          padding-right:3rem !important;
     }
}
@media (max-width: 767px) {
 .content-panel .single-product .site-main {
     margin-top: 36px;
     padding-left:2rem !important;
          padding-right:2rem !important;
  }
}


/* 2. Header Area (Title & Meta - Centered) */
.content-panel .single-product .entry-header {
  text-align: center;
  margin-bottom: 50px;
  max-width: 800px; /* Limits title width so it doesn't stretch too far */
  margin-left: auto;
  margin-right: auto;
}

.content-panel .single-product .entry-title {
  font-size: 2.8rem;
  font-weight: 900;
  line-height: 1.3;
  color: var(--color-text-heading);
  margin-bottom: 25px;
}
.shahkar-add-to-favorite-text {
  font-size: 16px !important;
}

.content-panel .single-product .entry-content h2 {
  color: var(--color-primary) !important;
}
.content-panel .single-product .entry-content p {
  font-size: 17px !important;
}
/* Meta Data (Date, Author) */
.content-panel .single-product .entry-meta {
  font-size: 0.95rem;
  color: var(--color-text-muted);
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 20px;
  /*border-top: 1px solid var(--color-border-subtle);*/
  /*border-bottom: 1px solid var(--color-border-subtle);*/
  padding: 15px 0;
  width: fit-content;
  margin: 0 auto;
}
.content-panel .single-product .entry-meta a {
  color: var(--color-primary);
  text-decoration: none;
  font-weight: 700;
}
/* --- 3. IMAGES (Updated Layout) --- */
/* Force FontAwesome to load instantly without blocking text */
@font-face {
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    font-display: swap;
    src: url('/wp-content/plugins/wpdiscuz/assets/third-party/font-awesome-5.13.0/webfonts/fa-solid-900.woff2') format('woff2');
}

@font-face {
    font-family: 'Font Awesome 5 Free';
    font-weight: 400;
    font-display: swap;
    src: url('/wp-content/plugins/wpdiscuz/assets/third-party/font-awesome-5.13.0/webfonts/fa-regular-400.woff2') format('woff2');
}
/* TYPE A: The "Main" Featured Image (Restricted to 680px) */
.content-panel .single-product .post-thumbnail img {
  display: block;
  margin: 50px auto;
  margin-top: 0 !important;
  width: 100%;
  max-width: 680px; /* Kept smaller as requested */
  height: auto;

  border-radius: 24px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.08);
}
#wpdcom .wpd-auth .wpd-login a{
    color:var(--color-primary) !important;
}
/* TYPE B: Images inside the text (FULL WIDTH) */
.content-panel .single-product .entry-content figure,
.content-panel .single-product .entry-content img {
  display: block;

  /* FULL WIDTH settings */
  width: 100%;
  max-width: 100%; /* Allows it to fill the 950px container */
  height: auto; /* Natural height (no cropping) */
  background-color:var(--color-card-bg);
  /* Styling */
  border-radius: 20px;
}

.content-panel .single-product .entry-content figure{
    margin-bottom:24px;
    padding-bottom: 8px;
}
img.size-medium{
    
   width: 300px !important;
    margin: 0 auto !important;
}



/* Captions */
.content-panel .single-product .wp-caption-text,
.content-panel .single-product figcaption {
  text-align: center;
  font-size: 0.9rem;
  color: var(--color-text-muted);
  margin-top: 15px;
  max-width: 400px;
  margin-left: auto;
    font-style: italic;
  margin-right: auto;
}
.content-panel .single-product figcaption {
     margin-top: 8px !important;
       padding:0 12px;
}
/* 4. Intro Paragraph (Centered Summary) */
.content-panel .single-product .entry-content > p.intro {
  font-size: 1.35rem;
  line-height: 1.9;
  color: var(--color-text-h2);
  font-weight: 600;
  text-align: center;
  margin-bottom: 50px;
  padding-right: 30px;
  border-right: 2px solid var(--color-accent-subtle);
  max-width: 800px; /* Keeps intro neat */
  margin-left: auto;
  text-align: right;
  margin-right: auto;
}

/* 5. Standard Body Text (Right Aligned) */
.content-panel .single-product .entry-content {
  font-size: 1.25rem;
  line-height: 2.1;
  color: var(--color-text-body);
}

.content-panel .single-product .entry-content p {
  text-align: right;
  margin-bottom: 32px;
}

.content-panel .single-product .entry-content a{
    color: #8C5A3C;
    text-underline-offset: 5px;
    text-decoration: underline;
    transition:color 0.3s ease-in-out;
}
.content-panel .single-product .entry-content a:hover{
    color:#7a3326 !important;
}
/* Headings (Right Aligned) */
.content-panel .single-product .entry-content h2,
.content-panel .single-product .entry-content h3 {
  text-align: right;
  color: var(--color-text-heading);
  font-weight: 800;
  margin-top: 60px;
  line-height: 1.7 !important;
  margin-bottom: 25px;
}
.content-panel .single-product .entry-content h2 {
  font-size: 1.8rem;
}
.content-panel .single-product .entry-content h3 {
  font-size: 1.6rem;
}

/* 6. Breadcrumbs (Centered) */
.content-panel .single-product .breadcrumb-wrapper {
  text-align: center;
  margin-bottom: 30px;
  font-size: 0.9rem;
  color: var(--color-text-muted);
}
.content-panel .single-product .breadcrumb-wrapper a {
  color: var(--color-accent);
  text-decoration: none;
}

/* 7. Responsiveness */
@media (max-width: 700px) {
  /* On tablets/phones, let the main image fill the screen width */
  .content-panel .single-product .post-thumbnail img {
    max-width: 100%;
    border-radius: 12px;
  }
  /* Let content images fill screen too if needed */
  .content-panel .single-product .entry-content img {
    max-width: 100%;
  }
}
/* --- Post Sources Accordion (SVG Version) --- */

.post-sources-accordion {
  max-width: 100%;
  width: fit-content;
  margin: 12px 0 48px 0 !important;
  direction: rtl;
  font-family: inherit;
}

@media (max-width: 641px) {
  .post-sources-accordion {
    width: 100% !important;
  }
}

/* Container */
.post-sources-accordion details {
  background: #fff;
  border-radius: 10px;
  transition: all 0.3s ease;
  border: 1px solid transparent;
}

.post-sources-accordion details[open] {
  background: var(--color-card-bg) !important; /* #f2f1ee */
  padding: 0 21px;
  border-color: var(--color-border-subtle) !important;
}

/* Header (Summary) */
.post-sources-accordion summary {
  padding: 1rem 0;
  user-select: none;
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
  list-style: none; /* Hide default arrow */
  display: flex;
  justify-content: start;
  align-items: center;
  gap: 15px;
  color: var(--color-text-heading) !important;
}

/* Hide default marker in Webkit */
.post-sources-accordion summary::-webkit-details-marker {
  display: none;
}
.post-sources-accordion summary:focus {
  outline: none;
}

/* --- THE SVG ICON STYLING --- */
.accordion-icon {
  /* Box Styling (Matches your previous look) */
  background: var(--color-card-bg) !important;
  width: 28px;
  height: 28px;
  padding: 5px; /* Adjusts the icon size inside the box */
  border-radius: 6px;
  color: var(--color-primary) !important; /* Red Icon */

  /* Animation */
  transition:
    transform 0.3s ease,
    background-color 0.3s;
}

/* When Open: Rotate to make an 'X' and change background */
.post-sources-accordion details[open] .accordion-icon {
  transform: rotate(45deg); /* Plus becomes X */
  background: #fff;
  color: var(--color-primary) !important;
}

/* List & Cards (Same as before) */
.post-sources-list {
  display: flex;
  flex-direction: column;
  padding: 1rem 0;
  gap: 0.5rem;
  animation: fadeIn 0.3s ease;
}

.post-sources-card {
  background: #fff;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  text-decoration: none;
  color: var(--color-text-body) !important;
  text-align: left !important;
  transition: all 0.2s ease;
  display: block;
  font-size: 0.9rem;
}

.post-sources-card:hover {
  background: #fff;
  color: var(--color-primary) !important;
  transform: translateX(-5px);
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* --- Related Posts Section --- */

.related-posts-section {
  max-width: 950px;
  margin: 80px auto 40px auto;
  direction: rtl;
  padding: 0 20px;
}

.related-title {
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 30px;
  color: var(--color-text-heading);
  text-align: right;
  border-right: 4px solid var(--color-primary);
  padding-right: 15px;
}

/* THE CONTAINER: Grid on Desktop, Slider on Mobile */
.related-grid-wrapper {
  display: grid;
  grid-template-columns: repeat(4, 1fr); /* 4 items side-by-side */
  gap: 20px;

  /* Animation: "Slowly goes up" */
  animation: slideUpFade 0.8s ease-out forwards;
  opacity: 0; /* Start hidden for animation */
  transform: translateY(30px);
}

/* The Card Link */
.related-card {
  text-decoration: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: transform 0.3s ease;
}

.related-card:hover {
  transform: translateY(-5px); /* Lift up on hover */
}

/* Image Styling */
.related-image {
  width: 100%;
  aspect-ratio: 1 / 1; /* Perfect Square */
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 15px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.related-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.related-card:hover .related-image img {
  transform: scale(1.05); /* Zoom effect */
}

/* Title Styling */
.related-card-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--color-text-body);
  text-align: center;
  line-height: 1.4;
  margin: 0;
  transition: color 0.2s;
}

.related-card:hover .related-card-title {
  color: var(--color-primary);
}

/* --- THE "SWIPER" FOR MOBILE (CSS Scroll Snap) --- */
@media (max-width: 768px) {
  .related-grid-wrapper {
    display: flex; /* Switch to Flex row */
    overflow-x: auto; /* Allow horizontal scrolling */
    scroll-snap-type: x mandatory; /* Force items to snap into place */
    padding-bottom: 20px; /* Space for scrollbar */
    gap: 15px;

    /* Hide Scrollbar for cleaner look */
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE/Edge */
  }

  .related-grid-wrapper::-webkit-scrollbar {
    display: none; /* Chrome/Safari */
  }

  .related-card {
    /* Sizing Logic for Mobile */
    flex: 0 0 40%; /* Shows 2.5 items (good for encouraging scroll) */
    scroll-snap-align: start; /* Snaps to start */
  }
}

@media (max-width: 480px) {
  .related-card {
    flex: 0 0 75%; /* On very small screens, show 1 large item + peek of next */
  }
}

/* Animation Keyframes */
@keyframes slideUpFade {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* --- WPDISCUZ AWWWARDS MINIMAL STYLE (RTL) --- */

/* 1. Container & Typography Reset */
#comments {
  max-width: 850px;
  margin: 80px auto 0;
  font-family: inherit;
  direction: rtl;
  color: var(--color-text-body);
}

/* 2. Rating Section (Top) - Invisible/Subtle */
#wpd-post-rating {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding-bottom: 30px !important;
  border-bottom: 1px solid var(--color-border-subtle) !important;
  margin-bottom: 50px !important;
}

.wpd-rating-title {
  font-size: 1.2rem;
  font-weight: 800;
  text-align: center;
  color: var(--color-text-heading);
}
.ql-container.ql-snow {
  border-radius: 12px 12px 0 0 !important;
}
.ql-toolbar.ql-snow {
  border-radius: 0 0 12px 12px !important;
}
.wpd-rating-stars svg {
  width: 22px;
  height: 22px;
  fill: var(--color-border-muted) !important;
}
.entry-content table{
      height:fit-content !Important;
  }

.wpd-rating-value {
  margin: 0 !important;
  background: var(--color-cat-olive-oils);
  color: var(--color-text-heading);
  padding: 5px 15px;
  border-radius: 50px;
  font-weight: 800;
}

/* 3. The Input Form (Clean & Modern) */
.wpd-form-wrap {
  background: transparent;
  padding: 0;
  margin-bottom: 60px;
}

/* Toolbar */
.wpd-form-wrap .ql-toolbar {
  background: transparent !important;
  border: 1px solid var(--color-input-border) !important;
  border-bottom: 1px dashed var(--color-input-border) !important;
  border-radius: 16px 16px 0 0;
  padding: 12px 20px !important;
}

/* Text Area */
.wpd-form-wrap .ql-container {
  background: #fff !important;
  border: 1px solid var(--color-input-border) !important;
  border-top: none !important;
  border-radius: 0 0 16px 16px;
  font-size: 1.05rem;
  color: var(--color-text-body) !important;
  min-height: 140px;
}
.wpd-form-wrap .ql-container:focus-within {
  border-color: var(--color-border-muted) !important;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.03);
}

/* Submit Button */
.wpd_comm_form .wc_comm_submit {
  background-color: var(--color-btn-primary) !important;
  color: #fff !important;
  border-radius: 12px !important;
  padding: 14px 35px !important;
  font-weight: 700 !important;
  border: none !important;
  font-size: 1rem !important;
  margin-top: 20px !important;
  box-shadow: 0 5px 15px rgba(215, 63, 63, 0.25);
  transition: transform 0.2s ease !important;
}
.wpd_comm_form .wc_comm_submit:hover {
  transform: translateY(-2px);
  background-color: var(--color-btn-primary-hover) !important;
}

/* 4. Comment Thread Structure */
.wpd-thread-head {
  border-bottom: none !important;
  margin-bottom: 30px;
  color: var(--color-text-heading);
  font-weight: 700;
  font-size: 1.1rem;
}

/* SORT BUTTONS (Minimal text only) */
.wpd-filter.wpdf-sorting {
  border: 1px solid var(--color-border-subtle);
  border-radius: 50px;
  padding: 5px 15px;
  background: #fff;
}
.wpdiscuz-sort-button {
  color: var(--color-text-muted) !important;
  font-weight: 600;
}
.wpdiscuz-sort-button-active {
  color: var(--color-primary) !important;
}

/* 5. COMMENT CARDS (The "Floating" Look) */
.wpd-comment-wrap {
  background: #fff !important; /* Crisp White Card */
  border: 1px solid var(--color-border-subtle) !important;
  border-radius: 20px !important; /* Soft corners */
  padding: 30px !important;
  margin-bottom: 25px !important;
  position: relative;
  transition: all 0.3s ease;
}

/* Hover Effect */
.wpd-comment-wrap:hover {
  border-color: var(--color-border-muted) !important;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.04);
  transform: translateY(-3px);
}

/* AVATAR */
.wpd-comment-left {
  padding: 0 !important;
  width: auto !important;
  margin-left: 20px !important;
}
.wpd-avatar img {
  border-radius: 50% !important;
  width: 56px !important;
  height: 56px !important;
  border: 2px solid #fff;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.06);
}

/* CONTENT HEADER */
.wpd-comment-header {
  margin-bottom: 10px;
}
.wpd-comment-author {
  font-size: 1.05rem !important;
  font-weight: 800 !important;
  color: var(--color-text-heading) !important;
}
.wpd-comment-date {
  font-size: 0.8rem !important;
  color: var(--color-text-muted) !important;
  opacity: 0.8;
}
.wpd-comment-date i {
  display: none;
} /* Remove clock icon */

/* "Replying To" Text */
.wpd-reply-to {
  background: var(--color-cat-olive-oils);
  display: inline-block;
  padding: 4px 12px;
  border-radius: 6px;
  font-size: 0.75rem;
  margin-bottom: 10px;
  color: var(--color-text-muted);
}
.wpd-reply-to a {
  color: var(--color-primary);
  font-weight: 700;
}

/* BODY TEXT */
.wpd-comment-text p {
  font-size: 1.05rem !important;
  line-height: 1.8 !important;
  color: var(--color-text-body) !important;
  margin-top: 5px !important;
}

/* FOOTER ACTIONS */
.wpd-comment-footer {
  margin-top: 20px !important;
  padding-top: 20px !important;
  border-top: 1px dashed var(--color-border-subtle) !important;
  display: flex;
  align-items: center;
  justify-content: flex-start;
}

/* VOTE BUTTONS (Pill Shape) */
.wpd-vote {
  display: flex;
  align-items: center;
  background: var(--color-card-bg); /* Beige background */
  border-radius: 50px;
  padding: 6px 14px;
}
.wpd-vote-up svg,
.wpd-vote-down svg {
  width: 12px;
  fill: var(--color-text-muted);
  transition: fill 0.2s;
}
.wpd-vote-result {
  font-weight: 700;
  color: var(--color-text-heading);
  margin: 0 10px;
  font-size: 0.9rem;
}
.wpd-vote-up:hover svg {
  fill: var(--color-accent);
}
.wpd-vote-down:hover svg {
  fill: var(--color-primary);
}

/* REPLY BUTTON */
.wpd-reply-button {
  cursor: pointer;
  margin-right: 20px !important;
  color: var(--color-text-muted) !important;
  font-size: 0.9rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: color 0.2s;
}
#wpdcom .wpd-comment-footer .wpd-vote {
  padding-left: 14px !important;
}
.wpd-reply-button svg {
  width: 16px;
  fill: var(--color-text-muted) !important;
}
.wpd-reply-button:hover {
  color: var(--color-primary) !important;
}
.wpd-reply-button:hover svg {
  fill: var(--color-primary) !important;
}

/* 6. NESTED REPLIES STYLING */

/* Indentation for Level 2 (Replied) Comments */
.wpd_comment_level-2 {
  margin-right: 50px !important; /* Push inwards from right */
  position: relative;
  width: auto !important;
}

/* The Connector Line (Visual Hierarchy) */
.wpd_comment_level-2::before {
  content: "";
  position: absolute;
  right: -30px; /* Position line in the margin gap */
  top: -20px; /* Connect from previous comment */
  bottom: 50%; /* Go halfway down */
  width: 2px;
  background: var(--color-border-subtle);
  border-radius: 2px;
}

/* Curved connector to the card */
.wpd_comment_level-2::after {
  content: "";
  position: absolute;
  right: -30px;
  top: 50%;
  width: 20px;
  height: 2px;
  background: var(--color-border-subtle);
  border-radius: 2px;
  display: none; /* Optional: Un-comment to show horizontal connector line */
}

/* Mobile Adjustment for Replies */
@media (max-width: 600px) {
  .wpd_comment_level-2 {
    margin-right: 20px !important;
  }
  .wpd_comment_level-2::before {
    right: -10px;
  }
}
/* --- WPDISCUZ EDIT FORM STYLING --- */

#wpdiscuz-edit-form {
  background-color: var(--color-card-bg); /* Matches comment bg */
  padding: 20px;
  border-radius: 16px;
  margin-top: 15px;
  border: 1px dashed var(--color-primary); /* Dashed Red border indicates "Editing" */
  direction: rtl;
  animation: fadeIn 0.3s ease;
}

/* Character Counter */
#wpdiscuz-edit-form .wpd-editor-char-counter {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  font-weight: 700;
  text-align: left; /* Keep it out of the way */
  margin-bottom: 8px;
  opacity: 0.7;
}

/* The Textarea (Input) */
#wpdiscuz-edit-form textarea.wc_comment {
  width: 100%;
  background: #fff !important; /* Crisp white for input */
  border: 1px solid var(--color-input-border) !important;
  border-radius: 12px !important;
  padding: 15px !important;
  font-family: inherit;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--color-text-body) !important;
  transition: all 0.2s ease;
  box-shadow: none !important;
  outline: none !important;
  min-height: 120px; /* Comfortable typing space */
}

/* Focus State */
#wpdiscuz-edit-form textarea.wc_comment:focus {
  border-color: var(--color-border-muted) !important;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05) !important;
}

/* Button Wrapper */
.wc_save_wrap {
  display: flex;
  align-items: center;
  justify-content: flex-end; /* Buttons on left (in RTL) */
  gap: 12px; /* Space between buttons */
  margin-top: 20px;
}

/* SAVE Button (Primary) */
.wc_save_edited_comment {
  background-color: var(--color-btn-primary) !important;
  color: #fff !important;
  border: none !important;
  padding: 10px 30px !important;
  border-radius: 8px !important;
  font-weight: 700 !important;
  font-size: 0.9rem !important;
  cursor: pointer;
  transition:
    transform 0.2s ease,
    background 0.2s !important;
  box-shadow: 0 4px 12px rgba(215, 63, 63, 0.2);
}

.wc_save_edited_comment:hover {
  background-color: var(--color-btn-primary-hover) !important;
  transform: translateY(-2px);
}

/* CANCEL Button (Secondary) */
.wc_cancel_edit {
  background-color: transparent !important;
  color: var(--color-text-muted) !important;
  border: 1px solid var(--color-border-muted) !important;
  padding: 10px 20px !important;
  border-radius: 8px !important;
  font-weight: 600 !important;
  font-size: 0.9rem !important;
  cursor: pointer;
  transition: all 0.2s ease !important;
}

.wc_cancel_edit:hover {
  border-color: var(--color-text-heading) !important;
  color: var(--color-text-heading) !important;
  background: #fff !important;
}

/* Animation for opening the edit form */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
/* 7. Hide Visual Clutter */
.wpd-comment-label,
.wpd-sbs-toggle,
.wpdiscuz-subscribe-bar {
  display: none !important;
  /* Hide author label and subscription toggles for minimal look */
  /* Remove display:none if you want them back */
}
*:focus {
  outline: none !important;
}

/* 8. Load More Button */
.wpd-load-more-submit {
  background: #fff !important;
  border: 2px solid var(--color-border-muted) !important;
  color: var(--color-text-heading) !important;
  border-radius: 50px !important;
  padding: 12px 40px !important;
  font-weight: 700 !important;
  display: block !important;
  margin: 30px auto !important;
  width: fit-content !important;
  transition: all 0.2s;
}
.wpd-load-more-submit:hover {
  border-color: var(--color-text-heading) !important;
  background: var(--color-text-heading) !important;
  color: #fff !important;
}
.wpd-avatar img {
  aspect-ratio: 1/1 !important;
  height: auto !important;
}
#wpdcom .wpd-thread-head .wpd-thread-info {
  margin-bottom: 19px;
}

#wpdcom .wpd-form-row .wpdiscuz-item input[type="text"],
#wpdcom .wpd-form-row .wpdiscuz-item input[type="email"],
#wpdcom .wpd-form-row .wpdiscuz-item input[type="url"],
#wpdcom .wpd-form-row .wpdiscuz-item input[type="color"],
#wpdcom .wpd-form-row .wpdiscuz-item input[type="date"],
#wpdcom .wpd-form-row .wpdiscuz-item input[type="datetime"],
#wpdcom .wpd-form-row .wpdiscuz-item input[type="datetime-local"],
#wpdcom .wpd-form-row .wpdiscuz-item input[type="month"],
#wpdcom .wpd-form-row .wpdiscuz-item input[type="number"],
#wpdcom .wpd-form-row .wpdiscuz-item input[type="time"],
#wpdcom textarea,
#wpdcom select {
  border: 1px solid var(--color-input-border) !important;
  color: var(--color-text-body) !important;
  border-radius: 8px;
}
#wpdcom input:required {
  box-shadow: none !important;
}
@media only screen and (max-width: 768px) {
    .shahkar-favorite-box {
        bottom: 17px !important;
    }
}
/*table*/
/* --- TARGET ALL BLOG TABLES AUTOMATICALLY --- */
.entry-content table {
  display: block !important;
  width: fit-content !important;
  max-width:100% !important;
  overflow-x: auto !important;
  border-spacing: 0 !important;
  border-collapse: separate;
  margin: 2.8rem auto;
  background-color: var(--color-content-bg) !important;
  border: 1px solid var(--color-border) !important;
  border-radius: 12px !important; /* Rounded corners on all screens */
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03) !important;

  /* Smaller Font */
  font-size: 0.9rem !important;

  /* Green Scrollbar */
  scrollbar-width: thin !important;
  scrollbar-color: var(--color-accent) var(--color-nav-bg);

}

.group.TyagGW_tableWrapper{
    max-width:100% !important;
}

/* --- HEADERS (Soft Green) --- */
.entry-content table thead th,
.entry-content table tr:first-child td,
.entry-content table th {
  /* Using 'nutrition-bg' for a softer, earthier green */
  background-color: var(--color-nutrition-bg);
  color: var(--color-text-heading);
  font-weight: 800;
  text-align: right;
  padding: 15px 12px;

  /* Sharp Green Underline for definition */
  border-bottom: 2px solid var(--color-accent);
  white-space: nowrap;
      white-space: pre-wrap;
}

/* --- CELLS --- */
.entry-content table td {
  padding: 14px 12px;
  border-bottom: 1px solid var(--color-border-subtle);
  color: var(--color-text-body);
  vertical-align: middle;
  line-height: 1.5;
  min-width: 160px;
  
}
.entry-content table td *{
    overflow-wrap: anywhere;
    max-width: 100%;
    white-space: pre-wrap;
}

/* --- THE "STICKY" FIRST COLUMN --- */
.entry-content table td:first-child,
.entry-content table th:first-child {
  position: sticky;
  right: 0;
  /* Warm beige background to balance the green */
  background-color: var(--color-card-bg);
  z-index: 2;
  border-left: 2px solid var(--color-nutrition-border);

  /* Green Text for the Label */
  color: var(--color-accent);
  font-weight: bold;
  min-width: 110px;
  max-width: 130px;
}

/* Fix for Top-Right Corner Header */
.entry-content table tr:first-child td:first-child,
.entry-content table thead th:first-child {
  z-index: 5;
  background-color: var(--color-nutrition-bg);
  color: var(--color-text-heading);
}

/* --- STRIPING & HOVER --- */
.entry-content table tbody tr:nth-child(even) td:not(:first-child) {
  background-color: var(--color-product-card-bg);
}

.entry-content table tbody tr:hover td:not(:first-child) {
  /* Very subtle green tint on hover */
  background-color: var(--cat-pickles);
  transition: background 0.2s;
}

/* --- MOBILE ADJUSTMENTS --- */
@media screen and (max-width: 768px) {
  .entry-content table {
    font-size: 0.8rem;
  }

  .entry-content table td,
  .entry-content table th {
    padding: 10px 8px;
  }

  .entry-content table td:first-child {
    box-shadow: -4px 0 8px -4px rgba(0, 0, 0, 0.1);
  }
  .entry-content table{
      height:fit-content !Important;
  }
}

/* --- 1. DEFINITIONS --- */

/* Slide Up (For Title & Text) */
@keyframes slideUpFade {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Premium Focus Effect (For Image) */
/* Starts slightly zoomed in and blurry, then settles */
@keyframes imageFocus {
  from {
    opacity: 0;
    transform: scale(1.15); /* Zoomed in */
    filter: blur(10px); /* Blurry */
  }
  to {
    opacity: 1;
    transform: scale(1); /* Normal size */
    filter: blur(0px); /* Sharp */
  }
}

/* --- 2. APPLY TO ELEMENTS --- */

/* A. The Title (Appears First) */
.entry-title {
  opacity: 0; /* Start hidden to prevent flash */
  animation: slideUpFade 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  animation-delay: 0.1s; /* Instant start */
}

/* B. The Meta (Date/Author) */
.entry-meta {
  opacity: 0;
  animation: slideUpFade 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  animation-delay: 0.2s; /* Follows title */
}

/* 1. Container: Essential to clip the zoomed edges */
.post-thumbnail {
  overflow: hidden;
  /* No height, bg, or shadow changes here */
}

/* 2. Image: Starting State (Hidden, Zoomed, Blurry) */
.post-thumbnail img {
  opacity: 0;
  transform: scale(1.15); /* Zoomed in 15% */
  filter: blur(10px); /* Blurry */

  /* Hardware acceleration hint */
  will-change: transform, opacity, filter;

  /* The Transition settings (Speed & Smoothing) */
  transition:
    opacity 1s ease-out,
    transform 1.5s cubic-bezier(0.22, 1, 0.36, 1),
    /* Premium "settle" curve */ filter 1.2s ease-out;
}

/* 3. Active State: Triggered by JS */
.post-thumbnail img.in-view {
  opacity: 1;
  transform: scale(1); /* Normal size */
  filter: blur(0); /* Sharp */
}

/* --- 1. THE ANIMATION KEYFRAMES --- */
@keyframes revealFocus {
  0% {
    opacity: 0;
    transform: scale(1.15); /* Start Zoomed In */
    filter: blur(10px); /* Start Blurry */
  }
  100% {
    opacity: 1;
    transform: scale(1); /* End Normal */
    filter: blur(0); /* End Sharp */
  }
}

/* --- 2. CONTAINER --- */
/* We only touch overflow (needed for zoom clipping) */
.post-thumbnail {
  overflow: hidden;
  /* No height, bg, or shadow changes */
}

/* --- 3. IMAGE --- */
.post-thumbnail img {
  /* Important: Start hidden so we don't see a flash of the unstyled image */
  opacity: 0;

  /* Apply the animation */
  /* Duration: 1.5s | Curve: smooth ease-out | Fill Mode: forwards (stays visible at end) */
  animation: revealFocus 1.5s cubic-bezier(0.22, 1, 0.36, 1) forwards;

  /* Delay: 0.2s (Runs almost instantly, just after title) */
  animation-delay: 0.2s;

  /* Performance: Tells browser to use GPU */
  will-change: transform, opacity, filter;
}

/* =========================================
   TablePress: Clean Up & Minimal Style
   ========================================= */

/* 1. Hide the Top Control Row (Search & Entry Count) */
.dt-container .dt-length, 
.dt-container .dt-search {
    display: none !important;
}

/* Optional: Hide the spacing associated with the top row */
.dt-container .dt-layout-row:has(.dt-length),
.dt-container .dt-layout-row:has(.dt-search) {
    display: none !important;
}

/* 2. Hide Sorting Arrows in Headers */
.tablepress thead .dt-column-order {
    display: none !important;
}

/* 3. Remove "Clickable" Cursor from Headers */
.tablepress thead th {
    cursor: default !important;
    pointer-events: none; /* Disables the sort click action entirely */
    padding-right: 10px !important; /* Reset padding used for the arrow */
}

.dt-paging.paging_simple_numbers ,.dt-container .dt-info {
    display: none !important;
}

.dt-container .tablepress {
    width: fit-content !important;
    max-width: 100% !important;
    margin: 0 !important;
}



.content-panel .single-product .entry-content ul {
  padding-right: 21px;
  margin: 18px 0;
}
.content-panel .single-product .entry-content ul,.content-panel .single-product .entry-content ol{
    
   list-style-position: inside !important;
    padding-inline-start: 24px;
}
.content-panel .single-product .entry-content li {
  list-style: disc !important;
  padding: 6px 8px;
}
/*
 * =========================================================================
 * == OAB APPLE BENTO BOX GRID (With Universal Gradient Fades)
 * =========================================================================
 */
.apple-bento-section {
    padding: 6rem 0;
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

.apple-bento-header {
    text-align: center;
    margin-bottom: 3.5rem;
}

.apple-bento-header h2 {
    font-size: 2.8rem;
    font-weight: 700;
    color: var(--color-accent,#6e8c65);
}

/* --- THE GRID --- */
.apple-bento-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 340px; 
    gap: 24px;
}

/* Grid Mapping */
.bento-card-1 { grid-column: span 2; grid-row: span 2; }
.bento-card-2 { grid-column: span 2; grid-row: span 1; }
.bento-card-3 { grid-column: span 1; grid-row: span 1; }
.bento-card-4 { grid-column: span 1; grid-row: span 1; }

/* --- CARD BASE --- */
.apple-bento-card {
    /* Critical: This color must match the gradient color exactly */
    background-color: var(--color-card-bg, #ffffff);
    border: 1px solid var(--color-border-subtle, #f0f0f0);
    border-radius: 32px;
    display: block; 
    text-decoration: none !important;
    overflow: hidden;
    position: relative;
    box-shadow: 0 4px 24px rgba(0,0,0,0.04);
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1), box-shadow 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    
    /* GSAP Prep */
    opacity: 0;
    transform: translateY(40px) scale(0.95);
    will-change: transform, opacity;
    -webkit-mask-image: -webkit-radial-gradient(white, black);
}

.apple-bento-card:hover {
    transform: scale(1.02) translateY(-4px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.08);
}

/* --- STRICT ZONING WITH UNIVERSAL FADE --- */
.bento-info {
    position: absolute;
    top: 0; right: 0; left: 0;
    padding: 32px 32px 0 32px;
    height: 50%; /* Text lives in the top half */
    z-index: 3; /* Sits above the gradient */
}

.bento-image {
    position: absolute;
    bottom: 0; right: 0; left: 0;
    height: 65%; /* Tucks UNDER the text area to allow blending */
    z-index: 1;
    overflow: hidden; /* <--- ADD THIS: Traps the scaled image! */
}

.bento-image img {
    width: 100%; height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
    border-radius:0 !important;
}

.apple-bento-card:hover .bento-image img {
    transform: scale(1.06);
}

/* THE MAGIC: The Universal Vertical Fade */
.bento-image::after {
    content: '';
    position: absolute;
    top: -2px; /* Pulls up slightly to prevent a hard pixel line */
    left: 0; right: 0;
    height: 45%; /* Fades the top 45% of the image */
    /* Fades from solid background color down to transparent */
    background: linear-gradient(to bottom, var(--color-card-bg, #ffffff) 0%, transparent 100%);
    z-index: 2;
    pointer-events: none;
}


/* --- TEXT STYLING --- */
.bento-info h3 {
    color: var(--color-text-body, #1d1d1f);
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 8px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.bento-info p {
    color: var(--color-text-h2, #86868b);
    font-size: 0.95rem;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* --- CARD 1 (BIG FEATURE) TWEAKS --- */
.bento-card-1 .bento-info h3 { font-size: 2.2rem; margin-bottom: 12px; }
.bento-card-1 .bento-info p { font-size: 1.1rem; -webkit-line-clamp: 3; }

/* --- CARD 2 (SIDE-BY-SIDE DESKTOP TWEAKS) --- */
@media (min-width: 1024px) {
    .bento-card-2 .bento-info {
        height: 100%;
        width: 55%;
        display: flex;
        flex-direction: column;
        justify-content: center; /* Centers text vertically */
        padding-top: 0;
    }
    .bento-card-2 .bento-image {
        height: 100%;
        width: 60%; /* Tucks under text */
        left: 0; right: auto;
    }
    /* Changes Card 2's fade from Vertical to Horizontal! */
    .bento-card-2 .bento-image::after {
        top: 0; bottom: 0; 
        right: -2px; left: auto; /* Places gradient on the right edge */
        height: 100%; width: 40%;
        background: linear-gradient(to right, transparent 0%, var(--color-card-bg, #ffffff) 100%);
    }
}

/* --- MOBILE RESPONSIVENESS --- */
@media (max-width: 1024px) {
    .apple-bento-grid {
        grid-template-columns: repeat(2, 1fr);
        grid-auto-rows: 320px;
    }
    .bento-card-1 { grid-column: span 2; grid-row: span 2; }
    .bento-card-2 { grid-column: span 2; grid-row: span 1; }
    .bento-card-3 { grid-column: span 1; grid-row: span 1; }
    .bento-card-4 { grid-column: span 1; grid-row: span 1; }
}

@media (max-width: 768px) {
    .apple-bento-header h2 { font-size: 2.2rem; }
    .apple-bento-grid {
        grid-template-columns: 1fr;
        grid-auto-rows: 400px; /* Taller on mobile so images are huge */
    }
    .bento-card-1, .bento-card-2, .bento-card-3, .bento-card-4 {
        grid-column: span 1;
        grid-row: span 1;
    }
    .bento-info { padding: 28px; }
    .bento-card-1 .bento-info h3 { font-size: 1.6rem; }
    
    /* On mobile, Card 2 stacks vertically like the rest, so we reset the gradient to vertical */
    .bento-card-2 .bento-image::after {
        top: -2px; left: 0; right: 0; bottom: auto;
        height: 45%; width: 100%;
        background: linear-gradient(to bottom, var(--color-card-bg, #ffffff) 0%, transparent 100%);
    }
}

/* Base state: Hidden, pushed down, and scaled down */
.apple-bento-card {
    opacity: 0;
    transform: translateY(50px) scale(0.95);
    /* This cubic-bezier mimics GSAP's power3.out ease beautifully */
    transition: opacity 0.9s cubic-bezier(0.215, 0.61, 0.355, 1), 
                transform 0.9s cubic-bezier(0.215, 0.61, 0.355, 1);
    will-change: opacity, transform; /* Hints to GPU to optimize this */
}

/* Active state: Visible and in position */
.apple-bento-card.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}


/* --- ACCORDION CORE (Vanilla CSS) --- */
.product_dropdown-bottom {
    display: grid !important;
    grid-template-rows: 0fr !important;
    transition: grid-template-rows 0.4s cubic-bezier(0.25, 1, 0.5, 1) !important;
    height: auto !important;
    padding: 0 !important;
    margin: 0 !important;
}


.product_dropdown-wrapper.is-open .product_dropdown-bottom {
    grid-template-rows: 1fr !important;
}

/* The magic trick: Inner div must have hidden overflow and min-height 0 */
.product_dropdown-content-inner {
    overflow: hidden !important;
    min-height: 0 !important;
}

/* --- ICON ROTATION --- */
.button-icon-plus {
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1) !important;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product_dropdown-wrapper.is-open .button-icon-plus {
    transform: rotate(45deg) !important;
}

/* Ensure the top trigger looks clickable */
.product_dropdown-top {
    cursor: pointer;
    user-select: none;
}



/* Each individual content block */
.content-panel {
  padding-bottom: 50vh; /* Creates scroll space */

  /* NEW ANIMATION (Initial State) */
  opacity: 0.3;
  transform: translateY(20px); /* Start 20px down */
  transition:
    opacity 0.5s ease-out,
    transform 0.5s ease-out;
}

/* The panel that is currently active/in view */
.content-panel.is-active {
  /* NEW ANIMATION (Active State) */
  opacity: 1;
  transform: translateY(0); /* Move to original position */
}


/* Container needs to trap the numbers while they slide */
.standalone-qty-count-inner {
    position: relative;
    overflow: hidden;
}

/* Base style for the numbers */
.count-digit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    /* This mimics GSAP's power2.inOut ease perfectly */
    transition: transform 0.3s cubic-bezier(0.455, 0.03, 0.515, 0.955);
}

/* This class is temporarily added during the animation so they can overlap */
.count-digit.is-animating {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
}


/*Related Prodcuts*/
/* Similar Products Section */
.pgl-similar-products {

    padding: 20px 0;

}
.similar-product-card {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.similar-product-card.is-visible {
    opacity: 1;
    transform: translateY(0);
}
.similar-products-grid {
    display: flex;
    gap: 16px;
    min-height:350px;
    display: flex;
    overflow-x: auto;
    padding: 10px 15px 20px;
    /* Smooth Snapping for Mobile */
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    
    
    /* 1. PREMIUM SCROLLBAR FOR DESKTOP (Visual Cue) */
    scrollbar-width: thin;
    scrollbar-color: var(--color-border-muted) transparent;
}

.similar-products-grid::-webkit-scrollbar {
    display: none;
}

.similar-product-card {
    flex: 0 0 200px; /* Fixed width prevents stretching */
    scroll-snap-align: start;
 
    border-radius: 20px;
    padding: 12px;
gap:9px;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
}

.similar-product-card:hover {

    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

/* Custom Webkit Scrollbar for Chrome/Safari */
.similar-products-grid::-webkit-scrollbar {
    height: 6px; /* Very thin and elegant */
}
.similar-products-grid::-webkit-scrollbar-track {
    background: transparent;
    margin: 0 20px; /* Keeps it from hitting the edges */
}
.similar-products-grid::-webkit-scrollbar-thumb {
    background-color: var(--color-border-muted);
    border-radius: 10px;
}
.similar-products-grid:hover::-webkit-scrollbar-thumb {
    background-color: var(--color-text-muted); /* Darkens slightly on hover */
}

/* --- The Cards --- */
.similar-product-card {
    /* 2. THE PEEK EFFECT (Crucial for Mobile) 
       Using 'vw' ensures the card width is tied to the screen width.
       60vw means it takes up 60% of the screen, so the second card is 
       always cut off at 40%, forcing the user to swipe to see the rest.
    */
    flex: 0 0 clamp(220px, 65vw, 260px); 
    
    scroll-snap-align: start;
    scroll-margin-right: 20px;
    
    background: var(--color-product-card-bg, #f6f5f3);
    border-radius: 24px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease, box-shadow 0.3s ease;
}

/* On larger screens (Tablets), show more cards, but still force the peek */
@media (min-width: 600px) {
    .similar-product-card {
        flex: 0 0 clamp(220px, 40vw, 280px); /* Shows ~2.5 cards */
    }
}

/* Desktop sizing (Shows ~3.5 cards so it always looks scrollable) */
@media (min-width: 1024px) {
    .similar-product-card {
        flex: 0 0 280px; 
    }
}

/* Fix Stretched Images */
.similar-product-image-link {
    display: block;
    width: 100%;
    aspect-ratio: 1 / 1; /* Forces a perfect square */
    margin-bottom: 12px;
    background: #f9f9f9;
    border-radius: 12px;
    overflow: hidden;
}

.similar-product-card img {
    width: 100%;
    height: 100% !important;
    object-fit: contain; /* Prevents stretching, fits image inside square */
    border-radius: 12px;
}

.similar-product-card h3 {
    font-size: 0.95rem;
    line-height: 1.4;
    font-weight: 600;
    color: #111;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    text-align: center;
}

/* Adjust Standalone Buttons for Card Size */
.similar-product-card .standalone-selector-wrapper {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* Desktop Grid Override */
@media (min-width: 1024px) {
    .similar-products-grid {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        overflow-x: hidden;
        gap: 24px;
        padding: 20px 0;
    }
    .similar-product-card {
        flex: none;
        padding: 20px;
    }
}