/* ===== VIBRANT CATEGORY PAGE – MOBILE FIRST (EDGE‑TO‑EDGE) ===== */
:root {
    --primary: #ff6b6b;
    --primary-dark: #ee5253;
    --primary-light: #ff9f9f;
    --secondary: #48dbfb;
    --secondary-dark: #0abde3;
    --accent: #feca57;
    --accent-dark: #ff9f43;
    --success: #10ac84;
    --warning: #f368e0;
    --danger: #ff6b6b;
    --gray-50: #f9fafc;
    --gray-100: #f0f3f8;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e0;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;
    --surface: #ffffff;
    --glass-bg: rgba(255, 255, 255, 0.8);
    --glass-border: rgba(255, 255, 255, 0.3);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
    --shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 20px 40px -12px rgba(0, 0, 0, 0.2);
    --shadow-lg: 0 30px 60px -15px rgba(0, 0, 0, 0.3);
    --shadow-glow: 0 0 20px rgba(255, 107, 107, 0.3);
    --radius-sm: 0.5rem;
    --radius: 1rem;
    --radius-md: 1.5rem;
    --radius-lg: 2rem;
    --radius-xl: 2.5rem;
    --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-bounce: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  }
  
  *,
  *::before,
  *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
  }
  
  html {
    font-size: 16px;
    -webkit-tap-highlight-color: transparent;
    scroll-behavior: smooth;
  }
  
  body {
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(145deg, #fff9f0 0%, #f8f0ff 100%);
    color: var(--gray-800);
    line-height: 1.5;
    min-height: 100vh;
    margin: 0;
    padding: 0;
  }
  
  /* ===== CONTAINER – edge‑to‑edge on mobile ===== */
  .main-container {
    width: 100%;
    max-width: 100%;
    margin: 0;
    padding: 0 1rem 2rem;  /* side padding for breathing, but background full width */
    overflow-x: hidden;
  }
  
  /* ===== MODERN HEADER – glassmorphism, full width ===== */
  .modern-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
    padding: 0.5rem 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
  }
  
  .back-btn {
    background: none;
    border: none;
    font-size: 1.25rem;
    padding: 0.5rem;
    cursor: pointer;
    color: var(--gray-700);
    text-decoration: none;
    border-radius: 50%;
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-bounce);
  }
  .back-btn:active {
    background: rgba(255,255,255,0.3);
    transform: scale(0.9);
  }
  
  .header-title {
    font-size: 1.25rem;
    font-weight: 700;
    background: linear-gradient(145deg, var(--gray-800), var(--primary));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
  }
  
  .header-actions {
    display: flex;
    gap: 0.25rem;
  }
  
  .header-action-btn {
    background: none;
    border: none;
    font-size: 1.25rem;
    padding: 0.5rem;
    cursor: pointer;
    color: var(--gray-700);
    border-radius: 50%;
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-bounce);
  }
  .header-action-btn:active {
    background: rgba(255,255,255,0.3);
    transform: scale(0.9);
  }
  
  /* ===== SECTION HEADER ===== */
  .section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 1rem 0 1.5rem;
  }
  
  .section-title {
    font-size: 1.5rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(145deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
  }
  .section-title i {
    color: var(--primary);
    font-size: 1.4rem;
  }
  
  .view-all {
    color: var(--primary);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.5rem 0.75rem;
    border-radius: 30px;
    transition: var(--transition);
  }
  .view-all:active {
    background: rgba(255,107,107,0.1);
    transform: scale(0.96);
  }
  .view-all i {
    transition: transform 0.2s;
  }
  .view-all:active i {
    transform: translateX(4px);
  }
  
  /* ===== ITEMS GRID ===== */
  .items-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
  }
  
  /* Product Card – exciting & interactive */
  .product-card {
    position: relative;
    background: var(--surface);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition-bounce);
    border: 1px solid rgba(255,107,107,0.1);
    transform-origin: center;
  }
  .product-card:active {
    transform: scale(0.98);
    box-shadow: var(--shadow-glow);
  }
  .product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
  }
  
  /* Badges */
  .product-badge {
    position: absolute;
    top: 0.5rem;
    left: 0.5rem;
    background: linear-gradient(145deg, var(--primary), #ff8787);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 30px;
    font-size: 0.7rem;
    font-weight: 700;
    z-index: 10;
    box-shadow: 0 4px 10px rgba(255,107,107,0.3);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    animation: pulse 2s infinite;
  }
  @keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(255,107,107,0.7); }
    70% { box-shadow: 0 0 0 6px rgba(255,107,107,0); }
    100% { box-shadow: 0 0 0 0 rgba(255,107,107,0); }
  }
  
  /* Action buttons (like/share) */
  .product-actions {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    display: flex;
    gap: 0.4rem;
    z-index: 10;
  }
  
  .action-btn {
    width: 2.2rem;
    height: 2.2rem;
    border-radius: 50%;
    background: var(--glass-bg);
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255,255,255,0.5);
    box-shadow: var(--shadow-sm);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-700);
    font-size: 1rem;
    transition: var(--transition-bounce);
  }
  .action-btn:active {
    transform: scale(0.85);
    background: white;
    color: var(--primary);
  }
  .action-btn.like.active i {
    font-weight: 900;
    color: var(--primary);
  }
  
  /* Media container */
  .product-media-container {
    position: relative;
    aspect-ratio: 1 / 1;
    background: var(--gray-100);
    overflow: hidden;
  }
  
  .media-content {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
  }
  .product-card:active .media-content {
    transform: scale(1.03);
  }
  
  /* Video play button overlay */
  .video-play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(2px);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    transition: opacity 0.3s;
    border: 2px solid rgba(255,255,255,0.3);
  }
  .video-play-btn i {
    font-size: 1rem;
    margin-left: 2px;
  }
  
  /* Product info */
  .product-info {
    padding: 0.75rem;
  }
  
  .product-title {
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
    color: var(--gray-800);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.3;
  }
  
  .product-price {
    font-weight: 800;
    font-size: 1rem;
    background: linear-gradient(145deg, var(--primary), var(--accent));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    margin-bottom: 0.5rem;
  }
  
  .product-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
  }
  
  .shop-avatar {
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid white;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  }
  
  .shop-name {
    font-size: 0.75rem;
    color: var(--gray-500);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  
  /* Empty state */
  .empty-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3rem 1rem;
    background: var(--surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    color: var(--gray-500);
  }
  
  .empty-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--gray-300);
  }
  
  .empty-text {
    font-size: 1rem;
  }
  
  /* ===== TABLET ADJUSTMENTS ===== */
  @media (min-width: 640px) {
    .main-container {
      padding: 0 1.5rem 2rem;
    }
    .items-grid {
      grid-template-columns: repeat(3, 1fr);
      gap: 1rem;
    }
    .product-title {
      font-size: 1rem;
    }
    .product-price {
      font-size: 1.1rem;
    }
  }
  
  /* ===== DESKTOP LAYOUT ===== */
  @media (min-width: 1024px) {
    .main-container {
      max-width: 1400px;
      margin: 0 auto;
      padding: 0 2rem 3rem;
    }
    .items-grid {
      grid-template-columns: repeat(4, 1fr);
      gap: 1.5rem;
    }
    .modern-header {
      padding: 0.75rem 2rem;
    }
    .header-title {
      font-size: 1.5rem;
    }
    .section-title {
      font-size: 1.75rem;
    }
    .view-all {
      font-size: 1rem;
    }
    .product-card:hover {
      transform: translateY(-6px);
      box-shadow: var(--shadow-xl, 0 30px 50px -20px rgba(0,0,0,0.3));
    }
    .action-btn {
      width: 2.5rem;
      height: 2.5rem;
      font-size: 1.1rem;
    }
    .product-title {
      font-size: 1.05rem;
    }
    .product-price {
      font-size: 1.2rem;
    }
  }
  
  /* ===== LOADING & ANIMATIONS ===== */
  @keyframes shimmer {
    0% { background-position: -1000px 0; }
    100% { background-position: 1000px 0; }
  }
  .loading-skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 1000px 100%;
    animation: shimmer 2s infinite;
  }