/**
 * FRIO Ice Cream & Botana - Menu Page Styles
 * Light theme CSS for menu hub page with filtering and search
 * All comments and debugging in English as requested
 */

/* === MENU HERO SECTION === */

.menu-hero-section {
  background: linear-gradient(135deg, var(--color-bg-body) 0%, var(--color-primary-light) 100%);
  padding: var(--space-16) 0;
  position: relative;
}

.menu-hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('/images/patterns/ice-cream-pattern.svg') repeat;
  opacity: 0.03;
  pointer-events: none;
}

.hero-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-12);
  align-items: center;
  position: relative;
  z-index: 1;
}

.hero-text {
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
}

.hero-title {
  font-size: clamp(2rem, 4vw, 3.5rem);
  font-weight: var(--font-weight-extrabold);
  line-height: var(--line-height-tight);
  color: var(--color-text-primary);
  margin-bottom: var(--space-4);
}

.hero-subtitle {
  font-size: var(--font-size-xl);
  color: var(--color-text-secondary);
  line-height: var(--line-height-relaxed);
  margin-bottom: var(--space-4);
}

.hero-description p {
  font-size: var(--font-size-lg);
  color: var(--color-text-secondary);
  line-height: var(--line-height-relaxed);
}

/* Hero Stats */
.hero-stats {
  display: flex;
  gap: var(--space-6);
  flex-wrap: wrap;
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-3) var(--space-4);
  background: var(--color-bg-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-border-light);
}

.stat-number {
  font-size: var(--font-size-2xl);
  font-weight: var(--font-weight-bold);
  color: var(--color-accent-pink);
}

.stat-label {
  font-size: var(--font-size-sm);
  color: var(--color-text-muted);
  font-weight: var(--font-weight-medium);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.hero-image {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.hero-img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-2xl);
  box-shadow: var(--shadow-xl);
  filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.1));
}

/* Mobile hero adjustments */
@media (max-width: 768px) {
  .menu-hero-section {
    padding: var(--space-12) 0;
    text-align: center;
  }
  
  .hero-content {
    grid-template-columns: 1fr;
    gap: var(--space-8);
  }
  
  .hero-text {
    order: 1;
  }
  
  .hero-image {
    order: 2;
  }
  
  .hero-stats {
    justify-content: center;
  }
}

/* === MENU FILTERS SECTION === */

.menu-filters-section {
  background: var(--color-bg-white);
  padding: var(--space-12) 0;
  border-bottom: 1px solid var(--color-border-light);
}

.filters-container {
  max-width: var(--container-section);
  margin: 0 auto;
  padding: 0 var(--space-6);
}

/* === SEARCH SECTION === */

.search-section {
  margin-bottom: var(--space-8);
}

.search-wrapper {
  position: relative;
  max-width: 600px;
  margin: 0 auto;
}

.search-input {
  width: 100%;
  padding: var(--space-4) var(--space-12) var(--space-4) var(--space-6);
  font-size: var(--font-size-lg);
  border: 2px solid var(--color-border-light);
  border-radius: var(--radius-full);
  background: var(--color-bg-white);
  transition: var(--transition-all);
}

.search-input:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px var(--color-primary-alpha);
  outline: none;
}

.search-btn {
  position: absolute;
  right: var(--space-2);
  top: 50%;
  transform: translateY(-50%);
  background: var(--color-primary);
  color: var(--color-text-primary);
  border: none;
  border-radius: var(--radius-full);
  padding: var(--space-3);
  cursor: pointer;
  transition: var(--transition-all);
}

.search-btn:hover {
  background: var(--color-primary-dark);
  transform: translateY(-50%) scale(1.05);
}

.search-clear {
  position: absolute;
  right: var(--space-12);
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  color: var(--color-text-muted);
  cursor: pointer;
  padding: var(--space-2);
  border-radius: var(--radius-full);
  transition: var(--transition-all);
}

.search-clear:hover {
  background: var(--color-bg-gray-light);
  color: var(--color-accent-pink);
}

.search-results-info {
  text-align: center;
  margin-top: var(--space-4);
  font-size: var(--font-size-base);
  color: var(--color-text-secondary);
}

/* === FILTER CONTROLS === */

.filters-controls {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--space-6);
  margin-bottom: var(--space-6);
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.filter-label {
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
  color: var(--color-text-primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.filter-select {
  padding: var(--space-3) var(--space-4);
  border: 1px solid var(--color-border-light);
  border-radius: var(--radius-lg);
  background: var(--color-bg-white);
  font-size: var(--font-size-base);
  transition: var(--transition-all);
}

.filter-select:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px var(--color-primary-alpha);
  outline: none;
}

/* Price Range Filter */
.price-range-wrapper {
  position: relative;
  padding: var(--space-4) 0;
}

.price-range-input {
  width: 100%;
  height: 6px;
  border-radius: 3px;
  background: var(--color-bg-gray-light);
  outline: none;
  -webkit-appearance: none;
}

.price-range-input::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--color-primary);
  cursor: pointer;
  border: 2px solid var(--color-bg-white);
  box-shadow: var(--shadow-sm);
}

.price-range-input::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--color-primary);
  cursor: pointer;
  border: 2px solid var(--color-bg-white);
  box-shadow: var(--shadow-sm);
}

.price-range-display {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: var(--space-2);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
  color: var(--color-cone-brown);
}

.price-separator {
  color: var(--color-text-muted);
}

/* Clear Filters Button */
.clear-filters-btn {
  align-self: flex-end;
  margin-top: auto;
}

/* === ACTIVE FILTERS === */

.active-filters {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-4);
}

.active-filter-tag {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  background: var(--color-accent-blue-alpha);
  color: var(--color-accent-blue);
  border-radius: var(--radius-full);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-medium);
}

.filter-tag-remove {
  background: transparent;
  border: none;
  color: var(--color-accent-blue);
  cursor: pointer;
  padding: 0;
  font-size: var(--font-size-sm);
  transition: var(--transition-all);
}

.filter-tag-remove:hover {
  color: var(--color-accent-pink);
}

/* === CATEGORIES NAVIGATION === */

.categories-nav-section {
  background: var(--color-bg-gray-light);
  padding: var(--space-8) 0;
}

.categories-nav-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--space-4);
}

.category-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-4);
  background: var(--color-bg-white);
  border-radius: var(--radius-xl);
  text-decoration: none;
  transition: var(--transition-all);
  border: 1px solid var(--color-border-light);
}

.category-nav-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  border-color: var(--color-primary);
  text-decoration: none;
}

.category-nav-icon {
  font-size: var(--font-size-3xl);
}

.category-nav-name {
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-semibold);
  color: var(--color-text-primary);
}

.category-nav-count {
  font-size: var(--font-size-sm);
  color: var(--color-text-muted);
}

/* === PRODUCTS GRID SECTION === */

.products-grid-section {
  padding: var(--space-16) 0;
}

/* Results Header */
.results-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-8);
  padding-bottom: var(--space-4);
  border-bottom: 1px solid var(--color-border-light);
}

.results-info {
  color: var(--color-text-secondary);
}

.results-count strong {
  color: var(--color-text-primary);
  font-weight: var(--font-weight-bold);
}

/* View Toggle */
.view-toggle {
  display: flex;
  gap: var(--space-2);
  border: 1px solid var(--color-border-light);
  border-radius: var(--radius-lg);
  padding: var(--space-1);
  background: var(--color-bg-white);
}

.view-btn {
  background: transparent;
  border: none;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-base);
  cursor: pointer;
  transition: var(--transition-all);
  color: var(--color-text-muted);
}

.view-btn.active,
.view-btn:hover {
  background: var(--color-primary);
  color: var(--color-text-primary);
}

/* === NO PRODUCTS FOUND === */

.no-products-found {
  text-align: center;
  padding: var(--space-16) var(--space-8);
  grid-column: 1 / -1;
}

.no-products-icon {
  font-size: 4rem;
  margin-bottom: var(--space-4);
  opacity: 0.5;
}

.no-products-title {
  font-size: var(--font-size-2xl);
  font-weight: var(--font-weight-bold);
  color: var(--color-text-primary);
  margin-bottom: var(--space-4);
}

.no-products-message {
  font-size: var(--font-size-lg);
  color: var(--color-text-secondary);
  margin-bottom: var(--space-6);
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

/* === LOADING STATE === */

.products-loading {
  text-align: center;
  padding: var(--space-12);
  grid-column: 1 / -1;
}

.loading-spinner {
  font-size: 3rem;
  animation: spin 2s linear infinite;
  margin-bottom: var(--space-4);
}

.loading-text {
  font-size: var(--font-size-lg);
  color: var(--color-text-secondary);
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* === MENU CTA SECTION === */

.menu-cta-section {
  background: linear-gradient(135deg, var(--color-accent-pink) 0%, var(--color-accent-pink-dark) 100%);
  color: var(--color-text-inverse);
  padding: var(--space-16) 0;
}

.cta-content {
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.cta-title {
  font-size: var(--font-size-3xl);
  font-weight: var(--font-weight-bold);
  margin-bottom: var(--space-4);
  color: var(--color-text-inverse);
}

.cta-description {
  font-size: var(--font-size-lg);
  margin-bottom: var(--space-8);
  opacity: 0.9;
}

.cta-buttons {
  display: flex;
  justify-content: center;
  gap: var(--space-4);
  flex-wrap: wrap;
}

/* === MOBILE RESPONSIVENESS === */

@media (max-width: 768px) {
  .filters-controls {
    grid-template-columns: 1fr;
    gap: var(--space-4);
  }
  
  .categories-nav-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-3);
  }
  
  .category-nav-item {
    padding: var(--space-3);
  }
  
  .category-nav-icon {
    font-size: var(--font-size-2xl);
  }
  
  .results-header {
    flex-direction: column;
    gap: var(--space-4);
    align-items: stretch;
  }
  
  .cta-buttons {
    flex-direction: column;
    align-items: center;
  }
  
  .cta-buttons .btn {
    width: 100%;
    max-width: 300px;
  }
}

/* === ACCESSIBILITY === */

.search-input:focus,
.filter-select:focus,
.view-btn:focus,
.category-nav-item:focus {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* === REDUCED MOTION === */

@media (prefers-reduced-motion: reduce) {
  .loading-spinner {
    animation: none;
  }
  
  .category-nav-item:hover,
  .search-btn:hover {
    transform: none;
  }
}