/* Page Layout */
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background: linear-gradient(135deg, #e3f2fd 0%, #f5f5f5 100%);
  color: #333;
  margin: 0;
  padding: 0;
  min-height: 100vh;
  line-height: 1.6;
}

/* Enhanced Container with proper spacing */
.categories-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem;
  margin-top: 0;
  padding-top: 1rem;
}

/* Category Page Styles */

/* Auth Button Styles */
.btn-primary {
  background: linear-gradient(135deg, #2196f3 0%, #1976d2 100%);
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.2s ease;
  text-decoration: none;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(33, 150, 243, 0.3);
}

.btn-secondary {
  background: rgba(33, 150, 243, 0.1);
  color: #1976d2;
  border: 1px solid rgba(33, 150, 243, 0.3);
  border-radius: 8px;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.2s ease;
}

.btn-secondary:hover {
  background: rgba(33, 150, 243, 0.15);
  transform: translateY(-1px);
}

/* Auth Actions */
#auth-actions .user-info {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

#auth-actions .username {
  font-weight: 500;
  color: #1976d2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 120px;
}

/* Main Container */
.categories-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem;
}

.categories-content {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(15px);
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Breadcrumbs */
.breadcrumbs {
  margin-bottom: 1.5rem;
  font-size: 0.9rem;
  color: #666;
}

.breadcrumbs a {
  color: #1976d2;
  text-decoration: none;
  transition: color 0.2s;
}

.breadcrumbs a:hover {
  color: #2196f3;
  text-decoration: underline;
}

/* Header Section */
.page-header {
  text-align: center;
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 2px solid rgba(33, 150, 243, 0.1);
}

.page-header h1 {
  font-size: 3rem;
  font-weight: 800;
  color: #1976d2;
  margin-bottom: 1rem;
  letter-spacing: -1px;
}

.page-header .subtitle {
  font-size: 1.2rem;
  color: #4a5568;
  margin-bottom: 2rem;
}

/* Search and Filter Section */
.search-filter-section {
  display: flex;
  gap: 1rem;
  align-items: center;
  margin-bottom: 3rem;
  flex-wrap: wrap;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  padding: 1.5rem;
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.search-box {
  flex: 1;
  min-width: 300px;
  position: relative;
}

.search-box input {
  width: 100%;
  padding: 1rem 1.5rem;
  border-radius: 50px;
  border: 2px solid rgba(33, 150, 243, 0.2);
  font-size: 1rem;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 15px rgba(33, 150, 243, 0.1);
  outline: none;
  transition: all 0.3s ease;
  box-sizing: border-box;
}

.search-box input:focus {
  border-color: #2196f3;
  box-shadow: 0 4px 20px rgba(33, 150, 243, 0.3);
  background: white;
}

.search-box input::placeholder {
  color: #9ca3af;
  font-weight: 400;
}

.filter-dropdown {
  padding: 1rem 1.5rem;
  border-radius: 50px;
  border: 2px solid rgba(33, 150, 243, 0.2);
  font-size: 1rem;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  cursor: pointer;
  outline: none;
  transition: all 0.3s ease;
  min-width: 200px;
}

.filter-dropdown:focus,
.filter-dropdown:hover {
  border-color: #2196f3;
  box-shadow: 0 4px 20px rgba(33, 150, 243, 0.3);
  background: white;
}

/* Stats Section */
.stats-section {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  margin-bottom: 3rem;
}

.stat-card {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(248, 249, 250, 0.95) 100%);
  color: #1976d2;
  border: 2px solid rgba(33, 150, 243, 0.2);
  padding: 1.5rem;
  border-radius: 16px;
  text-align: center;
  box-shadow: 0 8px 25px rgba(33, 150, 243, 0.15);
  backdrop-filter: blur(10px);
}

.stat-card {
  position: relative;
  overflow: hidden;
}

.stat-card::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  transform: rotate(45deg);
  transition: all 0.6s ease;
  opacity: 0;
}

.stat-card:hover::before {
  animation: shimmer 0.8s ease-in-out;
}

@keyframes shimmer {
  0% {
    transform: translateX(-100%) translateY(-100%) rotate(45deg);
    opacity: 0;
  }
  50% {
    opacity: 1;
  }
  100% {
    transform: translateX(100%) translateY(100%) rotate(45deg);
    opacity: 0;
  }
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(128, 34, 34, 0.1);
}

.stat-label {
  font-size: 1rem;
  font-weight: 600;
  color: #435068;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Categories Grid */
.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-bottom: 3rem;
}

.category-card {
  background: rgba(255, 255, 255, 0.9);
  border-radius: 20px;
  padding: 2rem;
  text-align: center;
  box-shadow: 0 8px 25px rgba(33, 150, 243, 0.15);
  border: 1px solid rgba(33, 150, 243, 0.1);
  transition: all 0.3s ease;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.category-card {
  transform-style: preserve-3d;
  will-change: transform;
}

.category-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, rgba(33, 150, 243, 0.05), rgba(25, 118, 210, 0.1));
  opacity: 0;
  transition: opacity 0.3s ease;
  border-radius: 20px;
  pointer-events: none;
}

.category-card:hover::after {
  opacity: 1;
}

.category-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(33, 150, 243, 0.1), transparent);
  transition: left 0.5s ease;
}

.category-card:hover::before {
  left: 100%;
}

.category-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 15px 40px rgba(33, 150, 243, 0.25);
  border-color: #2196f3;
}

.category-icon {
  font-size: 4rem;
  margin-bottom: 1.5rem;
  display: block;
}

.category-card h3 {
  color: #1976d2;
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.category-card p {
  color: #4a5568;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.category-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(33, 150, 243, 0.1);
}

.product-count {
  background: rgba(33, 150, 243, 0.1);
  color: #1976d2;
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 600;
}

.view-btn {
  background: linear-gradient(135deg, #2196f3 0%, #1976d2 100%);
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 25px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  transition: all 0.2s ease;
  box-shadow: 0 4px 15px rgba(33, 150, 243, 0.3);
}

.view-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(33, 150, 243, 0.4);
}

/* Loading State */
.loading-container {
  text-align: center;
  padding: 3rem;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 16px;
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  margin: 2rem 0;
}

.loading-container {
  animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.loading-container p {
  color: #4a5568;
  font-size: 1.1rem;
  font-weight: 500;
  margin: 0;
}

.spinner {
  width: 50px;
  height: 50px;
  border: 4px solid rgba(33, 150, 243, 0.2);
  border-top: 4px solid #2196f3;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 1rem;
}

/* Categories Grid - Initially hidden but styled */
.categories-grid {
  display: none;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-bottom: 3rem;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Featured Products Section */
.featured-products-section {
  margin-top: 3rem;
  margin-bottom: 3rem;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  padding: 2.5rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.section-title {
  text-align: center;
  font-size: 2.5rem;
  font-weight: 700;
  background: linear-gradient(135deg, #1976d2 0%, #2196f3 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 2rem;
  letter-spacing: -0.5px;
}

/* Featured Products Grid */
.featured-products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

/* Featured Product Cards */
.featured-product-card {
  background: linear-gradient(135deg, #fff 0%, #f8f9fa 100%);
  border-radius: 16px;
  padding: 1.5rem;
  text-align: center;
  box-shadow: 0 4px 16px rgba(33,150,243,0.08);
  transition: all 0.3s ease;
  cursor: pointer;
  border: 2px solid transparent;
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(5px);
}

.featured-product-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(33, 150, 243, 0.1), transparent);
  transition: left 0.5s ease;
}

.featured-product-card:hover::before {
  left: 100%;
}

.featured-product-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 32px rgba(33,150,243,0.15);
  border-color: #e3f2fd;
}

.featured-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  background: linear-gradient(45deg, #ff6b35, #f7931e);
  color: white;
  padding: 0.3em 0.8em;
  border-radius: 20px;
  font-size: 0.8em;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.product-image {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 12px;
  margin-bottom: 1em;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  transition: transform 0.3s ease;
}

.product-image:hover {
  transform: scale(1.1);
}

.product-name {
  margin: 0 0 0.5em 0;
  font-size: 1.1em;
  font-weight: 600;
  color: #1976d2;
  line-height: 1.3;
  min-height: 2.6em;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-price {
  font-size: 1.3em;
  font-weight: 700;
  color: #2e7d32;
  margin-bottom: 0.5em;
}

.product-category {
  font-size: 0.9em;
  color: #666;
  margin-bottom: 1em;
  padding: 0.3em 0.8em;
  background: #f5f5f5;
  border-radius: 15px;
  display: inline-block;
}

.product-rating {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.3em;
  margin-bottom: 1em;
  font-size: 0.9em;
  color: #ff9800;
}

.product-rating span {
  color: #666;
  margin-left: 0.3em;
}

.add-to-cart-btn {
  background: linear-gradient(45deg, #2196f3, #1976d2);
  color: white;
  border: none;
  padding: 0.7em 1.5em;
  border-radius: 25px;
  font-weight: 600;
  font-size: 0.95em;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 3px 12px rgba(33,150,243,0.25);
  width: 100%;
}

.add-to-cart-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 20px rgba(33,150,243,0.35);
}

/* Mobile-First Responsive Design */

/* Base Mobile Styles (320px+) */
.categories-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem;
}

.categories-content {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(15px);
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Page Header Mobile */
.page-header h1 {
  font-size: 2rem;
  font-weight: 700;
  color: #1976d2;
  margin-bottom: 0.75rem;
  letter-spacing: -0.5px;
  line-height: 1.2;
}

.page-header .subtitle {
  font-size: 1rem;
  color: #4a5568;
  margin-bottom: 1.5rem;
  line-height: 1.5;
}

/* Search Filter Mobile */
.search-filter-section {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2rem;
}

.search-box {
  width: 100%;
}

.search-box input {
  width: 100%;
  padding: 0.875rem 1.25rem;
  border-radius: 12px;
  border: 2px solid rgba(33, 150, 243, 0.2);
  font-size: 1rem;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  box-shadow: 0 2px 8px rgba(33, 150, 243, 0.1);
  outline: none;
  transition: all 0.3s ease;
  touch-action: manipulation;
  min-height: 48px;
}

.search-box input:focus {
  border-color: #2196f3;
  box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.1);
  background: white;
}

.search-box::before {
  content: '🔍';
  position: absolute;
  left: 1.2rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.1rem;
  color: #9ca3af;
  pointer-events: none;
  z-index: 1;
}

.search-box input {
  padding-left: 3rem;
}

.filter-dropdown {
  width: 100%;
  padding: 0.875rem 1.25rem;
  border-radius: 12px;
  border: 2px solid rgba(33, 150, 243, 0.2);
  font-size: 1rem;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  cursor: pointer;
  outline: none;
  transition: all 0.3s ease;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
  background-position: right 1rem center;
  background-repeat: no-repeat;
  background-size: 1.5em 1.5em;
  padding-right: 3rem;
  min-height: 48px;
}

.filter-dropdown:focus {
  border-color: #2196f3;
  box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.1);
}

/* Stats Section Mobile */
.stats-section {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-bottom: 2rem;
}

.stat-card {
  background: linear-gradient(135deg, #2196f3 0%, #1976d2 100%);
  color: white;
  padding: 1.25rem;
  border-radius: 12px;
  text-align: center;
  box-shadow: 0 4px 16px rgba(33, 150, 243, 0.25);
}

.stat-number {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 0.25rem;
  display: block;
}

.stat-label {
  font-size: 0.9rem;
  opacity: 0.9;
  font-weight: 500;
}

/* Categories Grid Mobile */
.categories-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.category-card {
  background: rgba(255, 255, 255, 0.95);
  border-radius: 16px;
  padding: 1.5rem;
  text-align: center;
  box-shadow: 0 4px 16px rgba(33, 150, 243, 0.1);
  border: 1px solid rgba(33, 150, 243, 0.1);
  transition: all 0.3s ease;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  touch-action: manipulation;
}

.category-card:hover,
.category-card:focus {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(33, 150, 243, 0.2);
  border-color: #2196f3;
}

.category-card:active {
  transform: translateY(-2px);
}

.category-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
  display: block;
}

.category-card h3 {
  color: #1976d2;
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  line-height: 1.3;
}

.category-card p {
  color: #4a5568;
  line-height: 1.5;
  margin-bottom: 1rem;
  font-size: 0.9rem;
}

.category-meta {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(33, 150, 243, 0.1);
}

.product-count {
  background: rgba(33, 150, 243, 0.1);
  color: #1976d2;
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
  align-self: center;
}

.view-btn {
  background: linear-gradient(135deg, #2196f3 0%, #1976d2 100%);
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 25px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(33, 150, 243, 0.3);
  display: inline-block;
  touch-action: manipulation;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.view-btn:hover,
.view-btn:focus {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(33, 150, 243, 0.4);
}

.view-btn:active {
  transform: translateY(0);
}

/* Enhanced Category Card Interactions */
.category-card {
  transform-style: preserve-3d;
  will-change: transform;
}

.category-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, rgba(33, 150, 243, 0.05), rgba(25, 118, 210, 0.1));
  opacity: 0;
  transition: opacity 0.3s ease;
  border-radius: 20px;
  pointer-events: none;
}

.category-card:hover::after {
  opacity: 1;
}

/* Enhanced Search Experience */
.search-box::before {
  content: '🔍';
  position: absolute;
  left: 1.2rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.1rem;
  color: #9ca3af;
  pointer-events: none;
  z-index: 1;
}

.search-box input {
  padding-left: 3rem;
}

/* Loading Animation Enhancement */
.loading-container {
  animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Categories Grid Animation */
.categories-grid.show {
  animation: slideInUp 0.8s ease-out;
}

@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Stats Cards Enhancement */
.stat-card {
  position: relative;
  overflow: hidden;
}

.stat-card::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  transform: rotate(45deg);
  transition: all 0.6s ease;
  opacity: 0;
}

.stat-card:hover::before {
  animation: shimmer 0.8s ease-in-out;
}

@keyframes shimmer {
  0% {
    transform: translateX(-100%) translateY(-100%) rotate(45deg);
    opacity: 0;
  }
  50% {
    opacity: 1;
  }
  100% {
    transform: translateX(100%) translateY(100%) rotate(45deg);
    opacity: 0;
  }
}

/* Enhanced Mobile Styles */
@media (max-width: 768px) {
  .categories-container {
    padding: 0.75rem;
    margin-top: 0;
    padding-top: 0.75rem;
  }

  .categories-content {
    padding: 1.25rem;
    border-radius: 12px;
  }

  .page-header h1 {
    font-size: 2.2rem;
  }

  .page-header .subtitle {
    font-size: 1rem;
  }

  .search-filter-section {
    flex-direction: column;
    gap: 1rem;
    padding: 1rem;
  }

  .search-box {
    min-width: unset;
    width: 100%;
  }

  .filter-dropdown {
    width: 100%;
    min-width: unset;
  }

  .stats-section {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .stat-card {
    padding: 1.25rem;
  }

  .categories-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .category-card {
    padding: 1.5rem;
  }

  .category-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
  }

  .category-meta {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }
}

/* Tablet Specific Improvements */
@media (min-width: 768px) and (max-width: 1023px) {
  .categories-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }

  .stats-section {
    grid-template-columns: repeat(3, 1fr);
  }

  .search-filter-section {
    justify-content: space-between;
  }
}

/* Desktop (1024px+) */
@media (min-width: 1024px) {
  .categories-content {
    padding: 3rem;
    border-radius: 24px;
  }
  
  .categories-grid {
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2.5rem;
  }
  
  .featured-products-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  }
}

/* Large Desktop (1200px+) */
@media (min-width: 1200px) {
  .categories-container {
    padding: 3rem 2rem;
  }
}

/* Accessibility & Focus States */
*:focus {
  outline: 2px solid #007bff;
  outline-offset: 2px;
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
  .category-card,
  .featured-product-card {
    border: 2px solid #000;
  }
  
  .view-btn,
  .add-to-cart-btn {
    background: #000;
    border: 2px solid #fff;
  }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* Print Styles */
@media print {
  .categories-container {
    max-width: none;
    padding: 0;
  }
  
  .search-filter-section,
  .view-btn,
  .add-to-cart-btn {
    display: none;
  }
  
  .category-card,
  .featured-product-card {
    break-inside: avoid;
    box-shadow: none;
    border: 1px solid #000;
  }
}
