/* --- Brand Variables --- */
:root {
  --hl-dark-green: #1B4D3E;
  --hl-gold: #D4AF37;
  --hl-medium-green: #25624B;
  --hl-secondary-gold: #C59E30;
  --hl-black: #000000;
  --hl-white: #FFFFFF;
  
  --hl-font-heading: 'Cormorant Garamond', serif;
  --hl-font-body: 'DM Sans', sans-serif;
  
  --hl-transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* --- Container & Layout Rules --- */
.hl-shop-container {
  display: block;
  width: 100%;
  box-sizing: border-box;
  background-color: var(--hl-white);
  padding-left: 20px;
  padding-right: 20px;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  margin-left: auto;
  margin-right: auto;
}

.hl-shop-wrapper {
  max-width: 1400px;
  margin: 0 auto;
  box-sizing: border-box;
}

@media (max-width: 1366px) {
  .hl-shop-container {
    width: 85vw !important;
    max-width: 85vw !important;
    padding-left: 0;
    padding-right: 0;
  }
  .hl-shop-wrapper {
    max-width: 100%;
  }
}

@media (max-width: 991px) {
  .hl-shop-container {
    width: 90vw !important;
    max-width: 90vw !important;
  }
}

/* --- Mobile Filter Bar --- */
.hl-shop-mobile-bar {
  display: none;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  background-color: #F8FAFC;
  border: 1px solid #E2E8F0;
  border-radius: 16px;
  margin-bottom: 24px;
  box-sizing: border-box;
}

.hl-shop-mob-count {
  font-family: var(--hl-font-body);
  font-size: 0.9rem;
  color: #4A5568;
  font-weight: 600;
  margin: 0;
}

.hl-shop-drawer-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background-color: var(--hl-dark-green);
  color: var(--hl-white);
  border: none;
  padding: 10px 18px;
  border-radius: 10px;
  font-family: var(--hl-font-body);
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--hl-transition);
}

.hl-shop-drawer-btn:hover {
  background-color: var(--hl-gold);
  color: var(--hl-black);
}

@media (max-width: 991px) {
  .hl-shop-mobile-bar {
    display: flex;
  }
}

/* --- Layout Grid --- */
.hl-shop-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 48px;
  align-items: start;
}

@media (max-width: 991px) {
  .hl-shop-layout {
    grid-template-columns: 1fr;
    gap: 0;
  }
}

/* --- Sidebar Columns (Desktop vs Drawer) --- */
.hl-shop-sidebar {
  position: sticky;
  top: 100px;
  box-sizing: border-box;
}

.hl-shop-sidebar-header {
  display: none;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 30px;
  padding-bottom: 16px;
  border-bottom: 1px solid #E2E8F0;
}

.hl-shop-drawer-close {
  background: transparent;
  border: none;
  color: #A0AEC0;
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.3s;
}

.hl-shop-drawer-close:hover {
  color: var(--hl-black);
}

/* Mobile drawer mode overlay conversion */
@media (max-width: 991px) {
  .hl-shop-sidebar {
    position: fixed;
    top: 0;
    left: -320px;
    width: 320px;
    height: 100vh;
    background-color: var(--hl-white);
    z-index: 9999;
    box-shadow: 20px 0 60px rgba(0,0,0,0.15);
    padding: 30px 24px;
    overflow-y: auto;
    transition: left 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  }
  .hl-shop-sidebar.active {
    left: 0;
  }
  .hl-shop-sidebar-header {
    display: flex;
  }
}

/* --- Filter Groups --- */
.hl-shop-filter-group {
  margin-bottom: 36px;
}

.hl-shop-filter-title {
  font-family: var(--hl-font-heading);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--hl-dark-green);
  margin: 0 0 24px 0;
}

.hl-shop-group-title {
  font-family: var(--hl-font-heading);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--hl-dark-green);
  margin: 0 0 16px 0;
  padding-bottom: 8px;
  border-bottom: 2px solid rgba(27, 77, 62, 0.08);
}

/* Category list filters */
.hl-shop-cat-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.hl-shop-cat-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border: 1px solid #E2E8F0;
  background-color: var(--hl-white);
  border-radius: 10px;
  text-decoration: none;
  font-family: var(--hl-font-body);
  font-size: 0.88rem;
  font-weight: 600;
  color: #4A5568;
  transition: var(--hl-transition);
}

.hl-shop-cat-btn:hover {
  border-color: var(--hl-gold);
  color: var(--hl-dark-green);
  background-color: rgba(212, 175, 55, 0.05);
}

.hl-shop-cat-btn.active {
  background-color: var(--hl-dark-green);
  color: var(--hl-white);
  border-color: var(--hl-dark-green);
}

.hl-shop-cat-count {
  font-size: 0.72rem;
  background-color: #EDF2F7;
  color: #718096;
  padding: 2px 7px;
  border-radius: 50px;
  font-weight: 700;
}

.hl-shop-cat-btn.active .hl-shop-cat-count {
  background-color: rgba(255, 255, 255, 0.2);
  color: var(--hl-white);
}

/* Radio button selections */
.hl-shop-radio-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.hl-shop-radio-label {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-family: var(--hl-font-body);
  font-size: 0.9rem;
  color: #4A5568;
  font-weight: 500;
  user-select: none;
}

.hl-shop-radio-label input[type="radio"] {
  appearance: none;
  width: 18px;
  height: 18px;
  border: 2px solid #CBD5E0;
  border-radius: 50%;
  outline: none;
  margin: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: var(--hl-transition);
}

.hl-shop-radio-label input[type="radio"]:checked {
  border-color: var(--hl-dark-green);
  background-color: var(--hl-dark-green);
}

.hl-shop-radio-label input[type="radio"]:checked::after {
  content: "";
  width: 6px;
  height: 6px;
  background-color: var(--hl-white);
  border-radius: 50%;
  display: block;
}

.hl-shop-radio-label:hover input[type="radio"] {
  border-color: var(--hl-gold);
}

/* Clear Filters Button */
.hl-shop-clear-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 44px;
  border-radius: 10px;
  border: 1.5px dashed rgba(27, 77, 62, 0.3);
  text-decoration: none;
  font-family: var(--hl-font-body);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--hl-dark-green);
  transition: var(--hl-transition);
}

.hl-shop-clear-btn:hover {
  background-color: rgba(27, 77, 62, 0.05);
  border-color: var(--hl-dark-green);
}

/* --- Main Store Column --- */
.hl-shop-main {
  box-sizing: border-box;
}

/* Store catalog header */
.hl-shop-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 30px;
}

@media (max-width: 991px) {
  .hl-shop-header {
    display: none; /* Relies on mobile bar counts instead */
  }
}

.hl-shop-count-label {
  font-family: var(--hl-font-body);
  font-size: 0.95rem;
  color: #718096;
  margin: 0;
  font-weight: 500;
}

/* Sorting controls dropdown */
.hl-shop-sort-box {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.hl-shop-sort-label {
  font-family: var(--hl-font-body);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--hl-dark-green);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.hl-shop-sort-select {
  border: 1px solid #E2E8F0;
  background-color: var(--hl-white);
  height: 42px;
  padding: 0 16px;
  border-radius: 10px;
  font-family: var(--hl-font-body);
  font-size: 0.88rem;
  font-weight: 600;
  color: #4A5568;
  outline: none;
  cursor: pointer;
  transition: var(--hl-transition);
}

.hl-shop-sort-select:focus {
  border-color: var(--hl-gold);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.15);
}

/* --- Product Grid & Cards --- */
.hl-shop-grid {
  display: grid;
  gap: 30px;
  width: 100%;
  box-sizing: border-box;
  margin-bottom: 48px;
}

.hl-shop-cols-3 { grid-template-columns: repeat(3, 1fr); }
.hl-shop-cols-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 1200px) {
  .hl-shop-cols-4 {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .hl-shop-cols-3,
  .hl-shop-cols-4 {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
}

@media (max-width: 480px) {
  .hl-shop-cols-3,
  .hl-shop-cols-4 {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}

/* Product Card */
.hl-shop-card {
  background-color: var(--hl-white);
  border: 1px solid #E2E8F0;
  border-radius: 20px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: var(--hl-transition);
  box-sizing: border-box;
}

.hl-shop-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.05);
  border-color: rgba(27, 77, 62, 0.12);
}

/* Image */
.hl-shop-thumb-link {
  display: block;
  text-decoration: none;
}

.hl-shop-thumb-wrapper {
  position: relative;
  width: 100%;
  padding-top: 100%; /* Perfect Square aspect ratios */
  overflow: hidden;
  background-color: #F8FAFC;
}

.hl-shop-thumb {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.hl-shop-card:hover .hl-shop-thumb {
  transform: scale(1.05);
}

/* Sale/Outofstock Badges */
.hl-shop-badge {
  position: absolute;
  top: 14px;
  left: 14px;
  background-color: var(--hl-gold);
  color: var(--hl-black);
  font-family: var(--hl-font-body);
  font-size: 0.68rem;
  font-weight: 800;
  padding: 5px 10px;
  border-radius: 50px;
  letter-spacing: 0.05em;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.hl-shop-stockout {
  background-color: #718096 !important;
  color: var(--hl-white) !important;
}

/* Card Body */
.hl-shop-card-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  box-sizing: border-box;
}

.hl-shop-prod-title {
  font-family: var(--hl-font-heading);
  font-size: 1.15rem;
  font-weight: 600;
  line-height: 1.35;
  margin: 0 0 10px 0;
  height: 2.7em; /* Caps name heights cleanly */
  overflow: hidden;
}

.hl-shop-prod-title a {
  color: var(--hl-dark-green);
  text-decoration: none;
  transition: color 0.3s;
}

.hl-shop-prod-title a:hover {
  color: var(--hl-gold);
}

/* Price block */
.hl-shop-prod-price {
  font-family: var(--hl-font-body);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--hl-dark-green);
  margin-bottom: 20px;
}

.hl-shop-prod-price del {
  font-size: 0.9rem;
  color: #A0AEC0;
  margin-right: 6px;
  font-weight: 500;
}

.hl-shop-prod-price ins {
  text-decoration: none;
  color: var(--hl-gold);
}

/* Add to Cart button */
.hl-shop-add-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 46px;
  width: 100%;
  background-color: var(--hl-dark-green);
  color: var(--hl-white);
  text-decoration: none;
  font-family: var(--hl-font-body);
  font-size: 0.85rem;
  font-weight: 700;
  border-radius: 10px;
  box-sizing: border-box;
  margin-top: auto;
  transition: var(--hl-transition);
}

.hl-shop-add-btn:hover:not(.disabled) {
  background-color: var(--hl-gold);
  color: var(--hl-black);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(212, 175, 55, 0.3);
}

.hl-shop-add-btn.disabled {
  background-color: #EDF2F7;
  color: #A0AEC0;
  cursor: not-allowed;
}

/* Empty State */
.hl-shop-empty-state {
  text-align: center;
  padding: 60px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  background-color: #F8FAFC;
  border: 1px solid #E2E8F0;
  border-radius: 20px;
}

.hl-shop-empty-state svg {
  color: #A0AEC0;
  margin-bottom: 20px;
}

.hl-shop-empty-state h4 {
  font-family: var(--hl-font-heading);
  font-size: 1.5rem;
  color: var(--hl-dark-green);
  margin: 0 0 10px 0;
}

.hl-shop-empty-state p {
  font-family: var(--hl-font-body);
  font-size: 0.95rem;
  color: #718096;
  margin: 0 0 24px 0;
}

.hl-shop-empty-state .hl-shop-add-btn {
  width: auto;
  padding: 0 28px;
}

/* --- Pagination --- */
.hl-shop-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.hl-shop-page-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  border: 1px solid #E2E8F0;
  background-color: var(--hl-white);
  color: #4A5568;
  font-family: var(--hl-font-body);
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: 8px;
  transition: var(--hl-transition);
}

.hl-shop-page-btn.active {
  background-color: var(--hl-dark-green);
  color: var(--hl-white);
  border-color: var(--hl-dark-green);
}

.hl-shop-page-btn:hover:not(.active) {
  background-color: var(--hl-gold);
  color: var(--hl-black);
  border-color: var(--hl-gold);
  box-shadow: 0 6px 16px rgba(212, 175, 55, 0.25);
}
