/* Scoped variables for this page */
:root {
  --sidebar-shadow: 0 8px 24px rgba(0, 0, 0, 0.03);
  --transition-quick: all 0.3s ease;
}

/* ==========================================================================
   PRODUCT CARD CARD CONTAINER STYLING
   ========================================================================== */

/* Scoped card container styling with premium warm champagne gradient and gold-themed border */
.product-page .shop-item {
  background: linear-gradient(
    135deg,
    var(--tl-color-common-white) 0%,
    rgba(191, 153, 107, 0.04) 100%
  );
  border: 1px solid rgba(191, 153, 107, 0.4);
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.02);
  transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  overflow: hidden;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.product-page .shop-item:hover {
  background: var(--tl-color-common-white);
  border-color: var(--tl-color-theme-primary);
  box-shadow: 0 16px 36px rgba(191, 153, 107, 0.12);
  transform: translateY(-6px);
}

/* Horizontal list view card layout override */
.product-page .shop-item.grid-shop {
  flex-direction: row;
  width: 100%;
}

@media (max-width: 767px) {
  .product-page .shop-item.grid-shop {
    flex-direction: column;
  }
}

/* Thumbnail styling: override default 24px border-radius to prevent white corner gaps */
.product-page .shop-item .shop-thumb {
  position: relative;
  overflow: hidden;
  border-radius: 0;
  background-color: #faf9f6;
  border-bottom: 1px solid rgba(191, 153, 107, 0.08);
}

/* List view thumbnail adjustments */
.product-page .shop-item.grid-shop .shop-thumb {
  width: 280px;
  min-width: 280px;
  height: 100%;
  border-bottom: none;
  border-right: 1px solid rgba(191, 153, 107, 0.08);
}

@media (max-width: 767px) {
  .product-page .shop-item.grid-shop .shop-thumb {
    width: 100%;
    min-width: 100%;
    height: 260px;
    border-right: none;
    border-bottom: 1px solid rgba(191, 153, 107, 0.08);
  }
}

.product-page .shop-item .shop-thumb img {
  transition: transform 0.6s ease;
  display: block;
  width: 100%;
}

.product-page .shop-item:hover .shop-thumb img {
  transform: scale(1.04);
}

/* Shop item adjustments for B2B (No price, no shopping cart actions) */
.product-page .shop-item .shop-content {
  padding: 20px 20px;
  margin-top: 0;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  flex-grow: 1;
}

/* Horizontal list view content alignment override */
.product-page .shop-item.grid-shop .shop-content {
  text-align: left;
  padding: 32px 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.product-page .shop-item .shop-content .title {
  font-size: 18px;
  margin-bottom: 8px;
  font-weight: 600;
  font-family: var(--tl-ff-heading);
}

.product-page .shop-item .shop-content .title a {
  color: var(--tl-color-heading-primary);
  transition: var(--transition-quick);
}

.product-page .shop-item .shop-content .title a:hover {
  color: var(--tl-color-theme-secondary);
}

.product-page .shop-item .shop-content .product-meta {
  font-size: 13.5px;
  color: var(--tl-color-grey-1);
  margin-top: 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* Horizontal list view meta items layout */
.product-page .shop-item.grid-shop .shop-content .product-meta {
  flex-direction: row;
  flex-wrap: wrap;
  column-gap: 20px;
  row-gap: 6px;
}

.product-page .shop-item .shop-content .product-meta span {
  font-weight: 600;
  color: var(--tl-color-heading-primary);
}

/* List view panel defaults */
.product-page .grid-shop-items {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-top: 20px;
}

/* ==========================================================================
   SIDEBAR & RECENT PRODUCTS STYLING
   ========================================================================== */
.product-page .shop-sidebar {
  background: var(--tl-color-common-white);
  border: 1px solid var(--tl-color-border-1);
  border-radius: 16px;
  padding: 28px;
  box-shadow: var(--sidebar-shadow);
}

.product-page .shop-sidebar .sidebar-header {
  font-size: 21px;
  font-weight: 700;
  color: var(--tl-color-heading-primary);
  position: relative;
  margin-bottom: 24px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--tl-color-border-1);
  font-family: var(--tl-ff-heading);
}

.product-page .shop-sidebar .sidebar-header::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 45px;
  height: 2px;
  background-color: var(--tl-color-theme-primary);
}

/* Category list items with sliding hover state replicating active design */
.category-sidebar-list .category-link {
  position: relative;
  overflow: hidden;
  z-index: 1;
  display: block;
  padding: 10px 14px;
  color: var(--tl-color-text-body);
  font-size: 15px;
  font-weight: 500;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.3s ease;
  margin-bottom: 4px;
}

/* Sliding background element */
.category-sidebar-list .category-link::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(202, 160, 92, 0.09);
  z-index: -1;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s cubic-bezier(0.25, 0.8, 0.25, 1);
  border-radius: inherit;
}

/* Sliding vertical left border element */
.category-sidebar-list .category-link::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  background-color: var(--tl-color-theme-secondary);
  z-index: 2;
  transform: scaleY(0);
  transform-origin: top;
  transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.category-sidebar-list .category-link:hover {
  color: var(--tl-color-theme-secondary) !important;
  padding-left: 18px;
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}

.category-sidebar-list .category-link:hover::before {
  transform: scaleX(1);
}

.category-sidebar-list .category-link:hover::after {
  transform: scaleY(1);
}

.category-sidebar-list .category-link.active {
  background-color: rgba(202, 160, 92, 0.09);
  color: var(--tl-color-theme-secondary) !important;
  font-weight: 600;
  padding-left: 18px;
  border-left: 3px solid var(--tl-color-theme-secondary);
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}

/* Disable pseudo-elements when link is active to prevent overlapping animations */
.category-sidebar-list .category-link.active::before,
.category-sidebar-list .category-link.active::after {
  display: none !important;
}

/* Sub-category list nested spacing */
.category-sidebar-list .sub-category-list {
  border-left: 1px dashed var(--tl-color-border-1);
  margin-left: 18px;
  padding-left: 12px;
  margin-bottom: 12px;
  margin-top: 4px;
}

.category-sidebar-list .sub-category-link {
  font-size: 13.5px;
  color: var(--tl-color-grey-1) !important;
  padding: 6px 0;
  display: block;
}

.category-sidebar-list .sub-category-link:hover {
  color: var(--tl-color-theme-primary) !important;
  background: transparent;
  padding-left: 4px;
}

.category-sidebar-list .sub-category-link.active {
  color: var(
    --tl-color-theme-secondary
  ) !important; /* Changed to secondary as requested */
  background: transparent;
  padding-left: 4px;
  font-weight: 600;
}

/* Recent Products List Widget */
.product-page .sidebar-items {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.product-page .sidebar-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 8px 12px;
  margin: 0 -12px;
  border-radius: 12px;
  border-bottom: 1px solid rgba(227, 227, 232, 0.3);
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.product-page .sidebar-item:last-child {
  border-bottom: 1px solid transparent;
}

.product-page .sidebar-item:hover {
  background-color: rgba(191, 153, 107, 0.05);
  border-bottom-color: transparent;
  transform: translateX(6px);
}

.product-page .sidebar-item .item-img {
  width: 72px;
  height: 72px;
  min-width: 72px;
  border-radius: 10px;
  border: 1px solid var(--tl-color-border-1);
  overflow: hidden;
  background-color: #fafafa;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.product-page .sidebar-item .item-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.product-page .sidebar-item:hover .item-img {
  border-color: var(--tl-color-theme-secondary);
  box-shadow: 0 4px 12px rgba(191, 153, 107, 0.15);
}

.product-page .sidebar-item:hover .item-img img {
  transform: scale(1.12);
}

.product-page .sidebar-item .content {
  flex-grow: 1;
}

.product-page .sidebar-item .content .title {
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 4px;
  line-height: 1.35;
  font-family: var(--tl-ff-body);
}

.product-page .sidebar-item .content .title a {
  color: var(--tl-color-heading-primary);
  text-decoration: none;
  transition: var(--transition-quick);
}

.product-page .sidebar-item:hover .content .title a {
  color: var(--tl-color-theme-secondary);
}

.product-page .sidebar-item .content .price {
  font-size: 12px;
  font-weight: 600;
  color: var(--tl-color-theme-secondary) !important;
}

/* ==========================================================================
   PAGINATION DESIGN OVERHAUL
   ========================================================================== */
.product-page .pagination-wrap {
  display: flex;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin-top: 50px;
}

.product-page .pagination-wrap li a {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--tl-color-border-1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  font-weight: 600;
  color: var(--tl-color-text-body);
  background-color: var(--tl-color-common-white);
  text-decoration: none;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.02);
  transition: var(--transition-quick);
}

.product-page .pagination-wrap li a:hover {
  background-color: var(--tl-color-theme-primary);
  border-color: var(--tl-color-theme-primary);
  color: var(--tl-color-common-white) !important;
  transform: scale(1.05);
  box-shadow: 0 6px 15px rgba(202, 160, 92, 0.25);
}

.product-page .pagination-wrap li a.active {
  background-color: var(--tl-color-theme-primary);
  border-color: var(--tl-color-theme-primary);
  color: var(--tl-color-common-white) !important;
  box-shadow: 0 6px 15px rgba(202, 160, 92, 0.35);
}

.product-page .pagination-wrap li a i {
  font-size: 13px;
}

/* Ensure the sidebar and its wrapper column span 100% width on tablet/mobile screens */
@media (max-width: 991px) {
  .product-page .col-lg-3.col-md-12.col-12 {
    width: 100% !important;
  }
  .product-page .shop-sidebar {
    width: 100% !important;
    max-width: 100% !important;
    padding: 20px !important;
  }
  .product-page .sidebar-item {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    text-align: left !important;
    gap: 16px !important;
    padding: 12px !important;
    margin: 0 !important;
    border-radius: 12px !important;
    background-color: rgba(191, 153, 107, 0.03) !important;
    border: 1px solid rgba(191, 153, 107, 0.15) !important;
  }
  .product-page .sidebar-item .item-img {
    width: 90px !important;
    height: 90px !important;
    min-width: 90px !important;
    border-radius: 8px !important;
  }
  .product-page .sidebar-item .content {
    text-align: left !important;
  }
}

