/* ============================================
   CSS VARIABLES & THEME
   ============================================ */
:root {
  /* Dark Theme */
  --bg: #121212;
  --card: #1e1e1e;
  --text: #f2f2f2;
  --text-secondary: #b0b0b0;
  --accent: #cfa8ff;
  --accent-hover: #b88ff0;
  --border: #333;
  --error: #ff5555;
  --success: #50fa7b;
  --warning: #ffb86c;
  --instagram: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
  
  /* Spacing */
  --spacing-xs: 4px;
  --spacing-sm: 8px;
  --spacing-md: 12px;
  --spacing-lg: 20px;
  --spacing-xl: 40px;
  
  /* Border Radius */
  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  
  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-medium: 0.3s ease;
  --transition-slow: 0.5s ease;
  
  /* Shadows */
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.2);
  --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.3);
}

body.light {
  --bg: #f5f5f5;
  --card: #ffffff;
  --text: #222;
  --text-secondary: #666;
  --border: #e0e0e0;
}

/* ============================================
   RESET & BASE STYLES
   ============================================ */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--text);
  transition: background var(--transition-medium), color var(--transition-medium);
  line-height: 1.6;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  padding: var(--spacing-sm) var(--spacing-md);
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
  color: var(--text);
}

button:hover {
  background: rgba(207, 168, 255, 0.1);
}

button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ============================================
   ACCESSIBILITY
   ============================================ */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--accent);
  color: #000;
  padding: var(--spacing-sm);
  text-decoration: none;
  z-index: 10000;
}

.skip-link:focus {
  top: 0;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* ============================================
   HEADER
   ============================================ */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--spacing-md) var(--spacing-lg);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: var(--bg);
  z-index: 1000;
  box-shadow: var(--shadow-sm);
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: transform var(--transition-fast);
}

.logo:hover {
  transform: scale(1.05);
}

.logo:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: var(--radius-md);
}

.logo img {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  object-fit: cover;
}

.logo-text h1 {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
}

.logo-text span {
  font-family: 'Chewy', cursive;
  font-size: 12px;
  color: var(--accent);
}

/* ============================================
   NAVIGATION
   ============================================ */
nav {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
}

.nav-button {
  position: relative;
  font-weight: 500;
}

.dropdown {
  position: relative;
  display: inline-block;
}

.dropdown-menu {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  background: var(--card);
  border-radius: var(--radius-md);
  overflow: hidden;
  z-index: 1000;
  box-shadow: var(--shadow-lg);
  min-width: 180px;
  animation: slideDown var(--transition-fast);
}

.dropdown-menu.open {
  display: block;
}

.dropdown-menu button {
  display: block;
  width: 100%;
  text-align: left;
  padding: var(--spacing-md) var(--spacing-md);
  background: transparent;
  border-radius: 0;
}

.dropdown-menu button:hover {
  background: var(--accent);
  color: #000;
}

.cart-btn, .favorites-btn {
  position: relative;
}

.cart-count, .favorites-count {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--accent);
  color: #000;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 600;
}

.favorites-count {
  background: #ff6b9d;
}

/* ============================================
   SEARCH & FILTERS
   ============================================ */
.search-container {
  padding: var(--spacing-lg);
  background: var(--card);
  border-bottom: 1px solid var(--border);
}

.search-bar {
  position: relative;
  max-width: 600px;
  margin: 0 auto var(--spacing-md);
}

.search-bar input {
  width: 100%;
  padding: var(--spacing-md) var(--spacing-xl) var(--spacing-md) var(--spacing-md);
  border: 2px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--bg);
  color: var(--text);
  font-size: 16px;
  transition: border-color var(--transition-fast);
}

.search-bar input:focus {
  outline: none;
  border-color: var(--accent);
}

.search-bar button {
  position: absolute;
  right: var(--spacing-sm);
  top: 50%;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.filter-bar {
  display: flex;
  gap: var(--spacing-md);
  max-width: 600px;
  margin: 0 auto;
}

.filter-bar select {
  flex: 1;
  padding: var(--spacing-sm) var(--spacing-md);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  cursor: pointer;
}

.filter-bar select:focus {
  outline: 2px solid var(--accent);
  outline-offset: 0;
}

.search-results {
  margin-top: var(--spacing-md);
  font-size: 14px;
  color: var(--text-secondary);
  text-align: center;
}

/* ============================================
   TESTIMONIALS
   ============================================ */
.testimonials-section {
  padding: var(--spacing-xl) var(--spacing-lg);
  background: var(--card);
  border-bottom: 1px solid var(--border);
}

.testimonials-section h2 {
  text-align: center;
  margin-bottom: var(--spacing-xl);
  font-size: 28px;
}

.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--spacing-lg);
  max-width: 1200px;
  margin: 0 auto;
}

.testimonial-card {
  background: var(--bg);
  padding: var(--spacing-lg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.testimonial-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.testimonial-card .stars {
  color: #ffd700;
  font-size: 18px;
  margin-bottom: var(--spacing-sm);
}

.testimonial-card p {
  margin: var(--spacing-md) 0;
  font-style: italic;
  color: var(--text-secondary);
}

.testimonial-author {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-xs);
}

.testimonial-author strong {
  color: var(--text);
  font-weight: 600;
}

.testimonial-author span {
  color: var(--text-secondary);
  font-size: 14px;
}

/* ============================================
   CATEGORIES & PRODUCTS
   ============================================ */
.category {
  padding: var(--spacing-xl) var(--spacing-lg);
}

.category h2 {
  margin: 0 0 var(--spacing-lg) 0;
  font-size: 28px;
  font-weight: 600;
}

.scroll-container {
  position: relative;
}

.product-scroll {
  display: flex;
  gap: var(--spacing-lg);
  overflow-x: auto;
  padding-bottom: var(--spacing-md);
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
}

.product-scroll::-webkit-scrollbar {
  height: 8px;
}

.product-scroll::-webkit-scrollbar-track {
  background: var(--card);
  border-radius: var(--radius-sm);
}

.product-scroll::-webkit-scrollbar-thumb {
  background: var(--accent);
  border-radius: var(--radius-sm);
}

/* Enhanced Product Card */
.product-card {
  min-width: 220px;
  max-width: 220px;
  flex-shrink: 0;
  scroll-snap-align: start;
  background: var(--card);
  padding: var(--spacing-md);
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
  box-shadow: var(--shadow-sm);
  position: relative;
  display: flex;
  flex-direction: column;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.product-card:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.product-card-image {
  position: relative;
  width: 100%;
  height: 180px;
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: var(--spacing-sm);
}

.product-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #f0f0f0;
}

.product-badge {
  position: absolute;
  top: var(--spacing-sm);
  right: var(--spacing-sm);
  background: var(--accent);
  color: #000;
  padding: var(--spacing-xs) var(--spacing-sm);
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
}

.product-badge.new {
  background: var(--success);
}

.product-badge.popular {
  background: var(--warning);
}

.product-favorite {
  position: absolute;
  top: var(--spacing-sm);
  left: var(--spacing-sm);
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  cursor: pointer;
  transition: transform var(--transition-fast);
  z-index: 10;
}

.product-favorite:hover {
  transform: scale(1.1);
}

.product-favorite.active {
  background: rgba(255, 107, 157, 0.9);
}

.product-card-content {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.product-card-title {
  font-weight: 600;
  margin-bottom: var(--spacing-xs);
  font-size: 15px;
}

.product-card-rating {
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
  margin-bottom: var(--spacing-sm);
}

.product-card-rating .stars {
  color: #ffd700;
  font-size: 14px;
}

.product-card-rating .rating-text {
  font-size: 12px;
  color: var(--text-secondary);
}

.product-card-price {
  font-size: 18px;
  font-weight: 700;
  color: var(--accent);
  margin-top: auto;
}

.product-card-price-from {
  font-size: 12px;
  font-weight: 400;
  color: var(--text-secondary);
}

/* Scroll Buttons */
.scroll-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  color: #fff;
  font-size: 24px;
  width: 40px;
  height: 60px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.7;
  transition: opacity var(--transition-fast), background var(--transition-fast);
}

.scroll-btn:hover {
  background: var(--accent);
  color: #000;
  opacity: 1;
}

.scroll-btn.left {
  left: 0;
}

.scroll-btn.right {
  right: 0;
}

.scroll-hint {
  position: absolute;
  bottom: 0;
  right: 10px;
  font-size: 12px;
  color: var(--accent);
  animation: blink 1.5s infinite;
  pointer-events: none;
}

@keyframes blink {
  0%, 50%, 100% { opacity: 1; }
  25%, 75% { opacity: 0.3; }
}

.product-scroll::after {
  content: "";
  position: absolute;
  right: 0;
  top: 0;
  width: 60px;
  height: 100%;
  pointer-events: none;
  background: linear-gradient(to left, var(--bg), transparent);
}

/* ============================================
   MODAL
   ============================================ */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(4px);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 2000;
  padding: var(--spacing-lg);
  animation: fadeIn var(--transition-fast);
}

.modal.open {
  display: flex;
}

.modal-content {
  background: var(--card);
  padding: var(--spacing-lg);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 500px;
  position: relative;
  box-shadow: var(--shadow-lg);
  animation: slideUp var(--transition-medium);
  max-height: 90vh;
  overflow-y: auto;
}

.close {
  position: absolute;
  top: var(--spacing-md);
  right: var(--spacing-md);
  background: rgba(0, 0, 0, 0.2);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  z-index: 10;
}

.close:hover {
  background: var(--accent);
  color: #000;
}

.modal-image-container {
  position: relative;
  margin-bottom: var(--spacing-md);
}

.modal-content img {
  width: 100%;
  max-height: 350px;
  object-fit: contain;
  border-radius: var(--radius-lg);
  background: #f0f0f0;
}

.gallery-controls {
  display: flex;
  justify-content: space-between;
  gap: var(--spacing-sm);
  margin: var(--spacing-sm) 0 0;
}

.gallery-controls button {
  flex: 1;
  padding: var(--spacing-sm);
  background: rgba(207, 168, 255, 0.1);
  border-radius: var(--radius-md);
}

.gallery-controls button:hover {
  background: var(--accent);
  color: #000;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--spacing-sm);
}

.modal-header h3 {
  margin: 0;
  font-size: 24px;
}

.favorite-btn {
  background: rgba(0, 0, 0, 0.1);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  transition: transform var(--transition-fast);
}

.favorite-btn:hover {
  transform: scale(1.1);
}

.favorite-btn.active .heart-icon {
  color: #ff6b9d;
}

.modal-rating {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  margin-bottom: var(--spacing-md);
}

.modal-rating .stars {
  color: #ffd700;
  font-size: 18px;
}

.modal-rating span {
  font-size: 14px;
  color: var(--text-secondary);
}

.modal-content p {
  color: var(--text-secondary);
  margin-bottom: var(--spacing-md);
  line-height: 1.6;
}

.modal-price {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  margin-bottom: var(--spacing-md);
  padding: var(--spacing-md);
  background: rgba(207, 168, 255, 0.1);
  border-radius: var(--radius-md);
}

.price-label {
  font-weight: 500;
  color: var(--text-secondary);
}

.price {
  font-size: 24px;
  font-weight: 700;
  color: var(--accent);
}

.form-group {
  margin: var(--spacing-md) 0;
}

.form-group label {
  display: block;
  margin-bottom: var(--spacing-xs);
  font-weight: 500;
}

.form-group select {
  width: 100%;
  padding: var(--spacing-sm) var(--spacing-md);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
}

.form-group select:focus {
  outline: 2px solid var(--accent);
  outline-offset: 0;
}

.qty {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: var(--spacing-md);
  margin: var(--spacing-md) 0;
}

.qty button {
  width: 36px;
  height: 36px;
  background: rgba(207, 168, 255, 0.1);
  border-radius: var(--radius-md);
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.qty button:hover {
  background: var(--accent);
  color: #000;
}

.qty span {
  font-size: 18px;
  font-weight: 600;
  min-width: 30px;
}

.add-cart {
  width: 100%;
  margin-top: var(--spacing-md);
  padding: var(--spacing-md);
  background: var(--accent);
  color: #000;
  font-weight: 600;
  border-radius: var(--radius-md);
  font-size: 16px;
}

.add-cart:hover {
  background: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* Social Share */
.social-share {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-sm);
  margin-top: var(--spacing-lg);
  padding-top: var(--spacing-lg);
  border-top: 1px solid var(--border);
}

.share-btn {
  padding: var(--spacing-sm);
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-xs);
}

.share-btn.instagram {
  background: var(--instagram);
  color: white;
}

.share-btn.whatsapp {
  background: #25D366;
  color: white;
}

.share-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* Related Products */
.related-products {
  margin-top: var(--spacing-lg);
  padding-top: var(--spacing-lg);
  border-top: 1px solid var(--border);
}

.related-products h4 {
  margin: 0 0 var(--spacing-md) 0;
  font-size: 18px;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--spacing-sm);
}

.related-product {
  cursor: pointer;
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: transform var(--transition-fast);
}

.related-product:hover {
  transform: scale(1.05);
}

.related-product img {
  width: 100%;
  height: 100px;
  object-fit: cover;
}

.related-product-title {
  padding: var(--spacing-xs);
  font-size: 12px;
  text-align: center;
  background: var(--bg);
}

/* ============================================
   CART DRAWER
   ============================================ */
.cart-drawer, .favorites-drawer {
  position: fixed;
  top: 0;
  right: -400px;
  width: 100%;
  max-width: 400px;
  height: 100%;
  background: var(--card);
  padding: var(--spacing-lg);
  transition: right var(--transition-medium);
  z-index: 2500;
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

.cart-drawer.open, .favorites-drawer.open {
  right: 0;
}

.cart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-md);
  border-bottom: 1px solid var(--border);
}

.cart-header h3 {
  margin: 0;
  font-size: 24px;
}

.cart-header button {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-header button:hover {
  background: var(--accent);
  color: #000;
}

#cartItems, #favoritesItems {
  flex: 1;
  overflow-y: auto;
}

.cart-item, .favorite-item {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-md);
  padding: var(--spacing-md);
  background: var(--bg);
  border-radius: var(--radius-md);
}

.cart-item img, .favorite-item img {
  width: 70px;
  height: 70px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}

.cart-item-info, .favorite-item-info {
  flex: 1;
  min-width: 0;
}

.cart-item-name, .favorite-item-name {
  font-weight: 500;
  margin-bottom: var(--spacing-xs);
  font-size: 14px;
}

.cart-item-price {
  color: var(--accent);
  font-weight: 600;
  font-size: 14px;
  margin-bottom: var(--spacing-xs);
}

.qty-drawer {
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
}

.qty-drawer button {
  width: 28px;
  height: 28px;
  background: rgba(207, 168, 255, 0.1);
  border-radius: var(--radius-sm);
  font-size: 16px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.qty-drawer button:hover {
  background: var(--accent);
  color: #000;
}

.qty-drawer span {
  min-width: 24px;
  text-align: center;
  font-weight: 500;
  font-size: 14px;
}

.cart-empty {
  text-align: center;
  padding: var(--spacing-xl);
  color: var(--text-secondary);
}

.cart-summary {
  margin-top: auto;
  padding: var(--spacing-lg) 0;
  border-top: 2px solid var(--border);
}

.summary-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: var(--spacing-sm);
  font-size: 14px;
}

.summary-row.total {
  font-size: 18px;
  font-weight: 700;
  color: var(--accent);
  margin-top: var(--spacing-md);
  padding-top: var(--spacing-md);
  border-top: 1px solid var(--border);
}

.whatsapp {
  width: 100%;
  margin-top: var(--spacing-md);
  padding: var(--spacing-md);
  background: #25D366;
  color: white;
  font-weight: 600;
  border-radius: var(--radius-md);
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
  box-shadow: var(--shadow-md);
}

.whatsapp:hover {
  background: #20ba5a;
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.favorite-item-actions {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-xs);
}

.favorite-item-actions button {
  padding: var(--spacing-xs) var(--spacing-sm);
  font-size: 12px;
  white-space: nowrap;
}

/* ============================================
   LOADING INDICATOR
   ============================================ */
.loading {
  position: fixed;
  bottom: var(--spacing-lg);
  right: var(--spacing-lg);
  background: var(--card);
  padding: var(--spacing-md) var(--spacing-lg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  z-index: 3000;
  animation: slideUp var(--transition-fast);
}

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideUp {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes slideDown {
  from {
    transform: translateY(-10px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */
@media (max-width: 768px) {
  .header {
    padding: var(--spacing-sm) var(--spacing-md);
  }
  
  .logo img {
    width: 40px;
    height: 40px;
  }
  
  .logo-text h1 {
    font-size: 16px;
  }
  
  .testimonials-grid {
    grid-template-columns: 1fr;
  }
  
  .filter-bar {
    flex-direction: column;
  }
  
  .product-card {
    min-width: 180px;
    max-width: 180px;
  }
  
  .product-card-image {
    height: 150px;
  }
  
  .related-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .social-share {
    grid-template-columns: 1fr;
  }
  
  .cart-drawer, .favorites-drawer {
    max-width: 100%;
    /* Mobilde başlangıçta tamamen gizli */
    right: -100%;
  }
}

@media (max-width: 480px) {
  .product-card {
    min-width: 150px;
    max-width: 150px;
  }
  
  .product-card-image {
    height: 120px;
  }
}

/* ============================================
   CATEGORY HEADING - CLICKABLE
   ============================================ */
.category-heading {
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  user-select: none;
  transition: color var(--transition-fast);
}

.category-heading:hover {
  color: var(--accent);
}

.category-heading:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
  border-radius: var(--radius-sm);
}

.category-toggle-icon {
  font-size: 20px;
  transition: transform var(--transition-fast);
  color: var(--accent);
  opacity: 0.7;
}

.category-heading[aria-expanded="true"] .category-toggle-icon {
  transform: rotate(45deg);
  opacity: 1;
}

.category-back-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: var(--spacing-lg);
  padding: var(--spacing-xs) var(--spacing-md);
  background: rgba(207, 168, 255, 0.12);
  border: 1px solid var(--accent);
  border-radius: var(--radius-md);
  color: var(--accent);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.category-back-btn:hover {
  background: var(--accent);
  color: #000;
}

/* Grid expanded mode */
.product-scroll.grid-mode {
  display: grid !important;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  overflow-x: unset;
  overflow-y: unset;
  scroll-snap-type: unset;
}

.product-scroll.grid-mode .product-card {
  min-width: unset;
  max-width: unset;
  width: 100%;
}

/* ============================================
   BACK TO TOP
   ============================================ */
.back-to-top {
  position: fixed;
  bottom: 80px;
  right: 20px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--accent);
  color: #000;
  font-size: 18px;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 900;
  box-shadow: var(--shadow-md);
  transition: opacity var(--transition-fast), transform var(--transition-fast);
  cursor: pointer;
  border: none;
  padding: 0;
}

.back-to-top:hover {
  transform: translateY(-3px);
  background: var(--accent-hover);
}

/* ============================================
   ADD TO CART ANIMATION
   ============================================ */
@keyframes cartPop {
  0% { transform: scale(1); }
  50% { transform: scale(1.3); }
  100% { transform: scale(1); }
}

.cart-count.pop {
  animation: cartPop 0.3s ease;
}

/* ============================================
   ADMIN PANEL
   ============================================ */
.admin-panel {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  backdrop-filter: blur(6px);
  z-index: 9000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--spacing-lg);
}

.admin-content {
  background: var(--card);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 700px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  animation: slideUp 0.3s ease;
}

.admin-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--spacing-lg);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: var(--card);
  z-index: 1;
}

.admin-header h2 {
  margin: 0;
  font-size: 22px;
}

.admin-header button {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255,0,0,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
}

.admin-body {
  padding: var(--spacing-lg);
}

.admin-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-xl);
}

@media (max-width: 600px) {
  .admin-stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.admin-stat-card {
  background: var(--bg);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  text-align: center;
  border: 1px solid var(--border);
  transition: transform var(--transition-fast);
}

.admin-stat-card:hover {
  transform: translateY(-2px);
}

.admin-stat-icon {
  font-size: 28px;
  margin-bottom: var(--spacing-sm);
}

.admin-stat-value {
  font-size: 28px;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: var(--spacing-xs);
}

.admin-stat-label {
  font-size: 13px;
  color: var(--text-secondary);
}

.admin-section {
  margin-bottom: var(--spacing-xl);
}

.admin-section h3 {
  font-size: 16px;
  margin-bottom: var(--spacing-md);
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border);
  padding-bottom: var(--spacing-sm);
}

.admin-top-list, .admin-visits-list {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
}

.admin-top-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--spacing-sm) var(--spacing-md);
  background: var(--bg);
  border-radius: var(--radius-md);
  font-size: 14px;
}

.admin-top-item-rank {
  font-weight: 700;
  color: var(--accent);
  min-width: 28px;
}

.admin-top-item-name {
  flex: 1;
}

.admin-top-item-count {
  font-weight: 600;
  background: rgba(207,168,255,0.15);
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  font-size: 13px;
}

.admin-visit-item {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  padding: var(--spacing-xs) var(--spacing-md);
  background: var(--bg);
  border-radius: var(--radius-md);
  color: var(--text-secondary);
}

.admin-actions {
  display: flex;
  gap: var(--spacing-md);
  flex-wrap: wrap;
}

.admin-danger-btn {
  background: rgba(255,85,85,0.15);
  color: var(--error);
  border: 1px solid var(--error);
  padding: var(--spacing-sm) var(--spacing-lg);
  border-radius: var(--radius-md);
  font-weight: 600;
}

.admin-danger-btn:hover {
  background: var(--error);
  color: #fff;
}

.admin-export-btn {
  background: rgba(80,250,123,0.15);
  color: var(--success);
  border: 1px solid var(--success);
  padding: var(--spacing-sm) var(--spacing-lg);
  border-radius: var(--radius-md);
  font-weight: 600;
}

.admin-export-btn:hover {
  background: var(--success);
  color: #000;
}

/* Admin Login Modal */
.admin-login-modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.8);
  z-index: 9500;
  display: flex;
  align-items: center;
  justify-content: center;
}

.admin-login-content {
  background: var(--card);
  padding: var(--spacing-xl);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 340px;
  text-align: center;
  box-shadow: var(--shadow-lg);
  animation: slideUp 0.3s ease;
}

.admin-login-content h3 {
  margin: 0 0 var(--spacing-lg);
  font-size: 20px;
}

.admin-login-content input {
  width: 100%;
  padding: var(--spacing-md);
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg);
  color: var(--text);
  font-size: 16px;
  margin-bottom: var(--spacing-md);
  text-align: center;
  letter-spacing: 4px;
}

.admin-login-content input:focus {
  outline: none;
  border-color: var(--accent);
}

.admin-login-buttons {
  display: flex;
  gap: var(--spacing-md);
  justify-content: center;
}

.admin-login-buttons button:first-child {
  background: var(--accent);
  color: #000;
  font-weight: 600;
  padding: var(--spacing-sm) var(--spacing-xl);
  border-radius: var(--radius-md);
}

.admin-login-buttons button:last-child {
  padding: var(--spacing-sm) var(--spacing-lg);
  border-radius: var(--radius-md);
}
