/* 
  VykroikiHub — Design System & Custom Stylesheet
  Theme: Warm Light Fashion Minimalism
*/

:root {
  /* Color Palette */
  --primary: #9E765C;       /* Terracotta / clay accent */
  --primary-dark: #7F5C44;  /* Darker clay for active states */
  --primary-light: #F6EFEA; /* Light background for accent chips */
  --text-main: #2C2623;     /* Deep charcoal with warm undertone */
  --text-muted: #7E746F;    /* Soft warm gray for subtitles */
  --bg-main: #FAF9F6;       /* Warm alabaster off-white */
  --bg-card: #FFFFFF;       /* Pure white for surface cards */
  --border: #EDEAE4;        /* Soft sand border */
  --border-focus: #C4B9B1;  /* Medium border for active states */
  --danger: #D15151;        /* Red for favorites heart */
  --danger-light: #FFF0F0;  /* Soft red background */

  /* Fonts */
  --font-serif: 'Playfair Display', Georgia, serif;
  --font-sans: 'Montserrat', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

  /* Spacings */
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 36px;

  /* Corner Radii */
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(44, 38, 35, 0.04);
  --shadow-md: 0 8px 24px rgba(44, 38, 35, 0.06);
  --shadow-lg: 0 16px 40px rgba(44, 38, 35, 0.1);

  /* Transitions */
  --transition-fast: 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-medium: 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  
  /* Layout */
  --header-height: 70px;
  --nav-bar-height: 64px;
}

[hidden] { display: none !important; }

.catalog-help {
  max-width: 850px;
  margin: 10px 0 20px;
  color: #645a54;
  font-size: 12px;
  line-height: 1.7;
}

.selected-filters { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.selected-filter {
  padding: 7px 12px;
  border: 1px solid var(--border-focus);
  border-radius: var(--radius-full);
  background: var(--primary-light);
  color: var(--primary-dark);
  font-size: 12px;
  cursor: pointer;
}
.selected-filter:hover { border-color: var(--primary-dark); }
.filter-label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 10px; }
.filter-select {
  width: 100%; padding: 12px;
  border: 1px solid var(--border-focus); border-radius: var(--radius-sm);
  background: var(--bg-card); color: var(--text-main); min-height: 44px;
}
.smart-size-group { padding: 20px 0; border-bottom: 1px solid var(--border); }
.smart-filter-group { border-bottom: 1px solid var(--border); padding: 16px 0; }
.smart-filter-group summary {
  font-size: 13px; font-weight: 600; cursor: pointer;
  padding: 6px 0; color: var(--text-main);
}
.group-selected { margin-left: 8px; color: var(--primary-dark); font-size: 12px; }
.smart-options { display: flex; flex-direction: column; gap: 4px; padding-top: 12px; max-height: 320px; overflow-y: auto; }
.filter-check { display: flex; align-items: center; gap: 9px; min-height: 36px; font-size: 13px; cursor: pointer; }
.filter-check input { accent-color: var(--primary-dark); width: 17px; height: 17px; flex-shrink: 0; }
.filter-check > span:first-of-type { flex: 1; }
.option-count { font-size: 11px; font-variant-numeric: tabular-nums; color: #645a54; }
.filter-check.unavailable { opacity: .45; cursor: default; }
.unknown-option { margin-top: 10px; font-size: 11px; line-height: 1.6; }
.filter-help { font-size: 11px; line-height: 1.7; color: #645a54; margin-top: 10px; }
.price-unknown { margin: -12px 0 16px; }
#desktop-smart-filters { margin-bottom: 24px; }
#mobile-smart-filters { margin-bottom: 24px; }
.unknown-price { font-size: 11px; font-weight: 400; color: #645a54; }
.modal-features { margin: 24px 0; }
.modal-features h3 { font-size: 14px; margin-bottom: 12px; }
.modal-features dl { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 16px; font-size: 12px; }
.modal-features dt { color: #645a54; }
.modal-features dd { margin: 0; }
.feature-proof { margin-top: 16px; font-size: 12px; line-height: 1.7; }
.feature-proof summary { cursor: pointer; font-weight: 600; }
.feature-proof p { margin-top: 10px; white-space: pre-line; max-height: 260px; overflow-y: auto; }
button:focus-visible, input:focus-visible, select:focus-visible, summary:focus-visible, a:focus-visible {
  outline: 2px solid var(--primary-dark); outline-offset: 3px;
}
@media (max-width: 1023px) {
  .filter-check { min-height: 44px; }
  .smart-filter-group summary { padding: 10px 0; }
  .filter-select { font-size: 16px; }
  .catalog-help { font-size: 11px; }
  .selected-filter { min-height: 36px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

/* Base Reset & Typography */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  padding-bottom: calc(var(--nav-bar-height) + 20px); /* For bottom nav bar on mobile */
}

a {
  color: inherit;
  text-decoration: none;
}

button, input, select {
  font-family: inherit;
  font-size: inherit;
  border: none;
  background: none;
  outline: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Remove tap highlight on iOS */
button, a, input, select {
  -webkit-tap-highlight-color: transparent;
}

/* Container */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-md);
}

/* Header */
.app-header {
  height: var(--header-height);
  background-color: rgba(250, 249, 246, 0.8);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border-bottom: 1px solid var(--border);
  position: relative;
  z-index: 100;
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 100%;
}

.logo-area {
  display: flex;
  flex-direction: column;
}

.logo-subtitle {
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--text-muted);
  font-weight: 600;
  line-height: 1;
  margin-bottom: 2px;
}

.logo-title {
  font-family: var(--font-serif);
  font-size: 20px;
  font-weight: 600;
  color: var(--text-main);
  letter-spacing: -0.02em;
}

.logo-title span {
  font-family: var(--font-sans);
  font-weight: 300;
  color: var(--primary);
  margin-left: 2px;
}

.header-actions {
  display: flex;
  align-items: center;
}

.header-fav-link {
  position: relative;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  background-color: var(--bg-card);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.header-fav-link:active {
  transform: scale(0.95);
}

.header-fav-link i {
  font-size: 18px;
  color: var(--text-muted);
  transition: color var(--transition-fast);
}

.header-fav-link.active i {
  color: var(--danger);
  font-weight: 900;
}

.fav-count {
  position: absolute;
  top: -4px;
  right: -4px;
  background-color: var(--primary);
  color: white;
  font-size: 10px;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  border: 2px solid var(--bg-main);
}

/* Desktop-only elements hidden on mobile */
.desktop-only {
  display: none !important;
}

/* Search Bar */
.search-section {
  margin: var(--space-md) 0;
}

.search-bar-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  background-color: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0 var(--space-md);
  height: 52px;
  box-shadow: var(--shadow-sm);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.search-bar-wrapper:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px var(--primary-light), var(--shadow-sm);
}

.search-icon {
  color: var(--text-muted);
  font-size: 16px;
  margin-right: var(--space-sm);
}

.search-bar-wrapper input {
  width: 100%;
  height: 100%;
  color: var(--text-main);
  font-weight: 500;
}

.search-bar-wrapper input:focus-visible {
  outline: none;
}

.search-bar-wrapper input::placeholder {
  color: var(--text-muted);
  font-weight: 400;
  opacity: 0.7;
}

.clear-search-btn {
  color: var(--text-muted);
  cursor: pointer;
  padding: var(--space-xs);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Categories Carousel */
.categories-carousel-section {
  margin-bottom: var(--space-md);
}

.categories-scroll {
  display: flex;
  gap: var(--space-sm);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none; /* Hide scrollbar for Firefox */
  padding-bottom: var(--space-xs);
}

.categories-scroll::-webkit-scrollbar {
  display: none; /* Hide scrollbar for Chrome/Safari */
}

.category-pill {
  flex-shrink: 0;
  padding: 8px 16px;
  background-color: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  cursor: pointer;
  scroll-snap-align: start;
  transition: all var(--transition-fast);
}

.category-pill:active {
  transform: scale(0.96);
}

.category-pill.active {
  background-color: var(--primary);
  color: white;
  border-color: var(--primary);
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(158, 118, 92, 0.2);
}

/* Catalog Info bar */
.catalog-info-section {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-md);
}

.results-meta {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.results-count {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 500;
}

.active-filters-indicator {
  font-size: 12px;
  color: var(--primary);
  font-weight: 600;
  background-color: var(--primary-light);
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  gap: var(--space-xs);
}

.text-btn {
  text-decoration: underline;
  cursor: pointer;
  font-size: 12px;
  color: var(--primary-dark);
  font-weight: 700;
}

/* Products Grid */
.products-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-md);
}

@media (min-width: 481px) {
  .products-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Mobile Sticky Search & Filters Bar */
.mobile-sticky-bar {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: var(--bg-main);
  border-bottom: 1px solid var(--border);
  margin-left: calc(-1 * var(--space-md));
  margin-right: calc(-1 * var(--space-md));
  padding-left: var(--space-md);
  padding-right: var(--space-md);
  padding-top: var(--space-sm);
  padding-bottom: var(--space-xs);
}

.mobile-sticky-bar .search-section {
  margin: var(--space-sm) 0;
}

.mobile-sticky-bar .categories-carousel-section {
  margin-bottom: var(--space-xs);
}

@media (min-width: 1024px) {
  .mobile-sticky-bar {
    position: relative;
    top: auto;
    z-index: auto;
    background-color: transparent;
    border-bottom: none;
    margin-left: 0;
    margin-right: 0;
    padding-left: 0;
    padding-right: 0;
    padding-top: 0;
    padding-bottom: 0;
  }
  .mobile-sticky-bar .search-section {
    margin: var(--space-md) 0;
  }
  .mobile-sticky-bar .categories-carousel-section {
    margin-bottom: var(--space-md);
  }
}

/* Catalog Container & Grid for Desktop */
.catalog-grid-section {
  display: block;
}

.catalog-container {
  width: 100%;
}

/* Product Card */
.product-card {
  background-color: var(--bg-card);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: relative;
  transition: transform var(--transition-medium), box-shadow var(--transition-medium), border-color var(--transition-medium);
}

.product-card:active {
  transform: scale(0.98);
}

.card-image-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 3/4;
  overflow: hidden;
  background: linear-gradient(90deg, #f2f1ed 25%, #e8e6e0 50%, #f2f1ed 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite linear;
  cursor: pointer;
}

@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

.card-image-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 0.3s ease-in-out, transform var(--transition-medium);
  opacity: 0;
}

.card-image-wrapper img.loaded {
  opacity: 1;
}

.product-card:hover .card-image-wrapper img.loaded {
  transform: scale(1.04);
}

/* Placeholder for missing images */
.placeholder-image {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background-color: var(--primary-light);
  color: var(--primary);
  gap: var(--space-sm);
}

.placeholder-image i {
  font-size: 32px;
}

.placeholder-image span {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

/* "New" badge style */
.badge-new {
  position: absolute;
  top: 10px;
  left: 10px;
  background: linear-gradient(135deg, #FF4B2B, #FF416C);
  color: white;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  box-shadow: 0 4px 10px rgba(255, 75, 43, 0.3);
  z-index: 10;
  pointer-events: none;
}

/* Source badge logo & wrapper */
.source-badge-wrapper {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background-color: var(--primary-light);
  color: var(--primary-dark);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 600;
  border: 1px solid rgba(158, 118, 92, 0.15);
  transition: all var(--transition-fast);
}

.source-badge-wrapper:hover {
  background-color: var(--primary);
  color: white;
  border-color: var(--primary);
}

.source-badge-wrapper:hover .source-mini-logo {
  filter: brightness(0) invert(1);
}

.source-letter {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  font-size: 8px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.load-more-sentinel {
  height: 1px;
  width: 100%;
  grid-column: 1 / -1;
}

.modal-price[hidden],
.modal-sizes-section[hidden] {
  display: none !important;
}

.source-fallback-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 14px;
  height: 14px;
  font-size: 11px;
}

.card-fav-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background-color: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0,0,0,0.06);
  z-index: 10;
  transition: transform var(--transition-fast), background-color var(--transition-fast);
}

.card-fav-btn:active {
  transform: scale(0.9);
}

.card-fav-btn i {
  font-size: 16px;
  color: var(--text-muted);
  transition: color var(--transition-fast);
}

.card-fav-btn.active i {
  color: var(--danger);
  font-weight: 900;
  animation: heartBeat 0.3s ease-in-out;
}

/* Favorite heart heart-beat animation */
@keyframes heartBeat {
  0% { transform: scale(1); }
  50% { transform: scale(1.3); }
  100% { transform: scale(1); }
}

.card-details {
  padding: var(--space-md);
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.card-category {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: var(--space-xs);
}

.card-title {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
  color: var(--text-main);
  margin-bottom: var(--space-sm);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  height: 36px; /* fixed height for 2 lines alignment */
  cursor: pointer;
}

.card-title:hover {
  color: var(--primary);
}

.card-meta {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: var(--space-md);
  flex-wrap: wrap;
  gap: var(--space-xs);
}

.card-price {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-main);
}

.card-source {
  font-size: 11px;
  color: var(--primary);
  font-weight: 500;
}

.card-sizes-label {
  font-size: 9px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: var(--space-xs);
  font-weight: 600;
}

.card-sizes {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: var(--space-md);
}

.size-badge {
  font-size: 9px;
  font-weight: 600;
  background-color: var(--bg-main);
  border: 1px solid var(--border);
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  color: var(--text-main);
}

.card-button {
  margin-top: auto;
  width: 100%;
  padding: 10px;
  background-color: var(--bg-main);
  border: 1px solid var(--border);
  color: var(--text-main);
  font-size: 12px;
  font-weight: 600;
  border-radius: var(--radius-sm);
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
}

.card-button:hover {
  background-color: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary-dark);
}

/* Larger accessible click targets on mobile/tablet */
@media (max-width: 1023px) {
  .card-fav-btn {
    width: 44px;
    height: 44px;
    top: 12px;
    right: 12px;
  }
  .card-fav-btn i {
    font-size: 20px;
  }
  .card-button {
    padding: 14px;
    font-size: 13px;
    border-radius: var(--radius-md);
  }
}

/* Loading & Empty States */
.loading-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: var(--space-xl) 0;
  color: var(--text-muted);
}

.loading-state i {
  font-size: 28px;
  margin-bottom: var(--space-md);
  color: var(--primary);
}

.empty-state {
  text-align: center;
  padding: var(--space-xl) var(--space-md);
  background-color: var(--bg-card);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  margin: var(--space-md) auto;
  max-width: 400px;
}

.empty-icon {
  font-size: 40px;
  color: var(--border-focus);
  margin-bottom: var(--space-md);
}

.empty-state h3 {
  font-family: var(--font-serif);
  font-size: 18px;
  margin-bottom: var(--space-sm);
}

.empty-state p {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: var(--space-md);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: 12px 24px;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
  width: auto;
}

.btn-primary {
  background-color: var(--primary);
  color: white;
}

.btn-primary:hover, .btn-primary:active {
  background-color: var(--primary-dark);
}

.btn-secondary {
  background-color: var(--bg-main);
  border: 1px solid var(--border);
  color: var(--text-main);
}

.btn-secondary:hover, .btn-secondary:active {
  background-color: var(--border);
}

.btn-block {
  width: 100%;
}

/* Mobile Navigation Bar */
.mobile-nav-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--nav-bar-height);
  background-color: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-around;
  align-items: center;
  z-index: 90;
  box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.03);
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  cursor: pointer;
  flex-grow: 1;
  height: 100%;
  position: relative;
}

.nav-item i {
  font-size: 18px;
  margin-bottom: 3px;
  transition: color var(--transition-fast), transform var(--transition-fast);
}

.nav-item span {
  font-size: 10px;
  font-weight: 500;
}

.nav-item.active {
  color: var(--primary);
}

.nav-item.active i {
  transform: scale(1.1);
}

.nav-badge {
  position: absolute;
  top: 6px;
  left: 53%;
  background-color: var(--danger);
  color: white;
  font-size: 9px;
  font-weight: 700;
  min-width: 16px;
  height: 16px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid white;
}

.filter-badge {
  position: absolute;
  top: 10px;
  left: 54%;
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
  background-color: var(--primary);
  border: 1px solid white;
}

/* Bottom Sheet Filter Drawer Drawer */
.drawer-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-medium);
}

.drawer-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.bottom-sheet {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background-color: var(--bg-card);
  border-top-left-radius: var(--radius-lg);
  border-top-right-radius: var(--radius-lg);
  z-index: 1001;
  transform: translateY(100%);
  transition: transform var(--transition-medium);
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.15);
}

.bottom-sheet.open {
  transform: translateY(0);
}

.sheet-header {
  padding: var(--space-md) var(--space-md) var(--space-xs);
  border-bottom: 1px solid var(--border);
  position: relative;
  text-align: center;
}

.sheet-drag-handle {
  width: 36px;
  height: 4px;
  background-color: var(--border-focus);
  border-radius: var(--radius-full);
  margin: 0 auto var(--space-sm);
  opacity: 0.6;
}

.sheet-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.sheet-title-row h2 {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 600;
}

.close-sheet-btn {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  background-color: var(--bg-main);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-muted);
}

.sheet-content {
  overflow-y: auto;
  padding: var(--space-md);
  flex-grow: 1;
}

.sheet-section {
  margin-bottom: var(--space-lg);
}

.sheet-section h3 {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: var(--space-md);
  font-weight: 600;
}

/* Chips Grid for Filters */
.chips-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  padding: 8px 14px;
  background-color: var(--bg-main);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 500;
  color: var(--text-main);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.chip.active {
  background-color: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary-dark);
  font-weight: 600;
}

/* Sort options grid inside Drawer */
.sort-options-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.sort-option-pill {
  padding: 12px var(--space-md);
  background-color: var(--bg-main);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 13px;
  text-align: left;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.sort-option-pill.active {
  background-color: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary-dark);
  font-weight: 600;
}

/* Sizes Filter Grid */
.sizes-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
}

.size-pill {
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--bg-main);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
  color: var(--text-main);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.size-pill.active {
  background-color: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary-dark);
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(158,118,92,0.1);
}

/* Price inputs styling */
.price-inputs {
  display: flex;
  gap: var(--space-md);
}

.price-field {
  display: flex;
  align-items: center;
  background-color: var(--bg-main);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0 var(--space-md);
  height: 44px;
  flex-grow: 1;
}

.price-field span {
  font-size: 12px;
  color: var(--text-muted);
  margin-right: var(--space-sm);
  text-transform: uppercase;
}

.price-field input {
  width: 100%;
  height: 100%;
  color: var(--text-main);
  font-weight: 600;
}

/* Bottom Sheet Footer */
.sheet-footer {
  padding: var(--space-md);
  border-top: 1px solid var(--border);
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: var(--space-md);
  background-color: var(--bg-card);
}

/* Detail Modal Style (Quick view) */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 2000;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-medium);
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.modal-window {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background-color: var(--bg-card);
  border-top-left-radius: var(--radius-lg);
  border-top-right-radius: var(--radius-lg);
  z-index: 2001;
  transform: translateY(100%);
  transition: transform var(--transition-medium), opacity var(--transition-medium), visibility var(--transition-medium);
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 -15px 40px rgba(0,0,0,0.2);
  pointer-events: none;
  visibility: hidden;
}

.modal-window.open {
  transform: translateY(0);
  pointer-events: auto;
  visibility: visible;
}

.close-modal-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background-color: rgba(255, 255, 255, 0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  box-shadow: var(--shadow-sm);
  color: var(--text-main);
}

.modal-layout {
  display: flex;
  flex-direction: column;
}

.modal-image-wrapper {
  position: relative;
  aspect-ratio: 3/4;
  background-color: var(--border);
  overflow: hidden;
}

.modal-image-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.modal-fav-toggle {
  position: absolute;
  bottom: 16px;
  right: 16px;
  width: 46px;
  height: 46px;
  border-radius: var(--radius-full);
  background-color: var(--bg-card);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: var(--shadow-md);
  z-index: 5;
}

.modal-fav-toggle i {
  font-size: 20px;
  color: var(--text-muted);
}

.modal-fav-toggle.active i {
  color: var(--danger);
  font-weight: 900;
  animation: heartBeat 0.3s ease-in-out;
}

.modal-info {
  padding: var(--space-lg);
}

.modal-title {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: var(--space-sm);
  color: var(--text-main);
}

.modal-meta-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border);
  padding-bottom: var(--space-md);
  margin-bottom: var(--space-md);
}

.modal-price {
  font-size: 22px;
  font-weight: 700;
  color: var(--primary-dark);
}

.modal-sizes-section {
  margin-bottom: var(--space-lg);
}

.modal-sizes-section h3 {
  font-size: 12px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: var(--space-sm);
  font-weight: 600;
}

.sizes-grid.disabled {
  pointer-events: none;
}

.modal-actions {
  display: flex;
  gap: var(--space-md);
}

/* Tablet Media Queries (iPad, etc.) */
@media (min-width: 600px) {
  /* Layout adjustments */
  .products-grid {
    gap: var(--space-lg);
  }

  .logo-title {
    font-size: 24px;
  }

  .modal-window {
    max-width: 580px;
    margin: 0 auto;
    border-radius: var(--radius-lg);
    bottom: 50%;
    transform: translateY(50%) scale(0.9);
    opacity: 0;
    max-height: 85vh;
  }

  .modal-window.open {
    transform: translateY(50%) scale(1);
    opacity: 1;
  }

  .modal-overlay {
    backdrop-filter: blur(8px);
  }

  .bottom-sheet {
    max-width: 500px;
    margin: 0 auto;
    border-top-left-radius: var(--radius-lg);
    border-top-right-radius: var(--radius-lg);
  }
}

/* Desktop Media Queries */
@media (min-width: 1024px) {
  /* Header adjustments */
  .app-header {
    height: 80px;
    position: sticky;
    top: 0;
  }

  body {
    padding-bottom: 0; /* No bottom navigation on desktop */
  }

  /* Catalog Grid Setup with Sidebar */
  .catalog-grid-section {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: var(--space-xl);
    align-items: start;
    margin-top: var(--space-lg);
  }

  .desktop-only {
    display: block !important;
  }

  .mobile-nav-bar {
    display: none; /* Hide bottom nav on desktop */
  }

  /* Sidebar Filters styling */
  .sidebar-filters {
    background-color: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 80px;
    max-height: calc(100vh - 100px);
    overflow-y: auto;
  }

  .filter-group {
    border-bottom: 1px solid var(--border);
    padding-bottom: var(--space-lg);
    margin-bottom: var(--space-lg);
  }

  .filter-group:last-child {
    border-bottom: none;
    padding-bottom: 0;
    margin-bottom: 0;
  }

  .filter-group h3 {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: var(--space-md);
    font-weight: 600;
  }

  /* Checkbox styled list */
  .checkbox-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
  }

  .checkbox-item {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-main);
  }

  .checkbox-item input {
    appearance: none;
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border: 1.5px solid var(--border-focus);
    border-radius: 4px;
    background-color: var(--bg-card);
    cursor: pointer;
    position: relative;
    transition: all var(--transition-fast);
  }

  .checkbox-item input:checked {
    background-color: var(--primary);
    border-color: var(--primary);
  }

  .checkbox-item input:checked::after {
    content: "\f00c";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 10px;
    color: white;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
  }

  /* Grid layouts */
  .products-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  /* Modal Details desktop popup layout */
  .modal-window {
    max-width: 800px;
    max-height: 600px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
  }

  .modal-layout {
    flex-direction: row;
    height: 600px;
  }

  .modal-image-wrapper {
    flex: 1.1;
    height: 100%;
    aspect-ratio: auto;
  }

  .modal-info {
    flex: 1;
    padding: var(--space-xl);
    display: flex;
    flex-direction: column;
    overflow-y: auto;
  }

  .modal-title {
    font-size: 26px;
    margin-bottom: var(--space-md);
  }

  .modal-actions {
    margin-top: auto;
  }

  .sort-select {
    padding: 8px 16px;
    background-color: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
  }

  .sort-select:focus {
    border-color: var(--primary);
  }
}

/* Pagination Styling */
.pagination-container {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin: var(--space-xl) 0;
  width: 100%;
}

.pagination-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 var(--space-sm);
  border-radius: var(--radius-sm);
  background-color: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-main);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.pagination-btn:hover:not(:disabled) {
  background-color: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary-dark);
}

.pagination-btn.active {
  background-color: var(--primary);
  border-color: var(--primary);
  color: white;
  box-shadow: 0 4px 10px rgba(158, 118, 92, 0.2);
}

.pagination-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.pagination-spacer {
  color: var(--text-muted);
  font-weight: 600;
  padding: 0 var(--space-xs);
}
