/* ═══════════════════════════════════════════════════
   shop.css — Redesigned Shop Page
═══════════════════════════════════════════════════ */

/* Hero Bar */
.shop-hero-bar {
  background: linear-gradient(135deg, var(--dark) 0%, #0d2137 100%);
  padding: 2rem 0 1.5rem;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.shop-hero-content { display: flex; align-items: center; justify-content: space-between; gap: 2rem; flex-wrap: wrap; }
.shop-hero-left .breadcrumb { color: #64748b; margin-bottom: 0.5rem; }
.shop-hero-left .breadcrumb a { color: #94a3b8; }
.shop-hero-left h1 { font-size: 1.8rem; font-weight: 800; color: #fff; margin: 0 0 0.3rem; }
.shop-hero-left p { color: #64748b; font-size: 0.9rem; margin: 0; }
.result-count { color: #94a3b8; }

.shop-hero-search { flex: 1; min-width: 280px; max-width: 500px; }
.hero-search-wrap { display: flex; align-items: center; background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.12); border-radius: 50px; padding: 0.4rem 0.4rem 0.4rem 1.2rem; transition: 0.3s; }
.hero-search-wrap:focus-within { border-color: var(--blue); background: rgba(255,255,255,0.08); }
.hero-search-wrap i { color: #64748b; margin-right: 0.6rem; }
.hero-search-wrap input { flex: 1; background: none; border: none; outline: none; color: #fff; font-size: 0.9rem; }
.hero-search-wrap input::placeholder { color: #475569; }
.hero-search-wrap button { background: var(--blue); color: #fff; border: none; padding: 0.6rem 1.4rem; border-radius: 50px; font-weight: 700; font-size: 0.85rem; cursor: pointer; transition: 0.3s; white-space: nowrap; }
.hero-search-wrap button:hover { background: var(--blue-dark); }

/* Category Pills */
.cat-pills-bar { background: #fff; border-bottom: 1px solid #f1f5f9; padding: 0.8rem 0; position: sticky; top: 0; z-index: 90; box-shadow: 0 2px 10px rgba(0,0,0,0.04); }
.cat-pills { display: flex; gap: 0.6rem; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.cat-pills::-webkit-scrollbar { display: none; }
.cat-pill { display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.45rem 1rem; border-radius: 50px; border: 1.5px solid #e2e8f0; font-size: 0.8rem; font-weight: 700; color: #475569; white-space: nowrap; transition: 0.3s; text-decoration: none; }
.cat-pill i { font-size: 0.75rem; color: #94a3b8; }
.cat-pill span { background: #f1f5f9; color: #94a3b8; font-size: 0.68rem; padding: 1px 6px; border-radius: 50px; }
.cat-pill:hover { border-color: var(--blue); color: var(--blue); }
.cat-pill.active { background: var(--blue); border-color: var(--blue); color: #fff; }
.cat-pill.active i, .cat-pill.active span { color: rgba(255,255,255,0.8); background: rgba(255,255,255,0.15); }

/* Main Layout */
.shop-page-layout { padding: 2.5rem 0 5rem; background: #f8fafc; }
.shop-page-inner { display: grid; grid-template-columns: 280px 1fr; gap: 2rem; align-items: start; }

/* Sidebar */
.shop-sidebar { background: #fff; border-radius: 20px; border: 1px solid #f1f5f9; position: sticky; top: 60px; overflow: hidden; }
.sidebar-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 299; }
.sidebar-inner { padding: 0; }
.sidebar-header { display: flex; align-items: center; justify-content: space-between; padding: 1.2rem 1.5rem; border-bottom: 1px solid #f1f5f9; background: #fff; }
.sidebar-header h3 { font-size: 1rem; font-weight: 800; color: var(--dark); margin: 0; display: flex; align-items: center; gap: 0.5rem; }
.sidebar-close { background: none; border: none; font-size: 1.1rem; cursor: pointer; color: #94a3b8; display: none; }
.sidebar-section { padding: 1.2rem 1.5rem; border-bottom: 1px solid #f1f5f9; }
.sidebar-section-title { font-size: 0.75rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; color: #94a3b8; margin: 0 0 1rem; }

/* Price Filter */
.price-range-ui { display: flex; flex-direction: column; gap: 0.8rem; }
.price-inputs { display: grid; grid-template-columns: 1fr 1fr; gap: 0.8rem; }
.price-inputs label { font-size: 0.72rem; color: #94a3b8; font-weight: 700; display: block; margin-bottom: 0.3rem; }
.price-inputs input { width: 100%; padding: 0.5rem 0.8rem; border: 1.5px solid #e2e8f0; border-radius: 8px; font-size: 0.85rem; outline: none; transition: 0.3s; }
.price-inputs input:focus { border-color: var(--blue); }
.btn-apply-filter { background: var(--blue); color: #fff; border: none; padding: 0.6rem; border-radius: 8px; font-weight: 700; font-size: 0.85rem; cursor: pointer; transition: 0.3s; }
.btn-apply-filter:hover { background: var(--blue-dark); }

/* Availability filter */
.filter-checkbox { display: flex; align-items: center; gap: 0.6rem; font-size: 0.88rem; color: #475569; cursor: pointer; margin-bottom: 0.6rem; }
.filter-checkbox input { accent-color: var(--blue); width: 16px; height: 16px; }

/* Sidebar CTA */
.sidebar-cta { padding: 1.5rem; background: linear-gradient(135deg, #eff6ff, #f8faff); text-align: center; }
.sidebar-cta i { font-size: 2rem; color: var(--blue); margin-bottom: 0.8rem; display: block; }
.sidebar-cta h4 { font-size: 1rem; margin: 0 0 0.4rem; }
.sidebar-cta p { font-size: 0.8rem; color: #64748b; margin-bottom: 1rem; line-height: 1.5; }
.btn-call-link { display: block; margin-top: 0.8rem; font-size: 0.82rem; font-weight: 700; color: var(--blue); text-decoration: none; }

/* Toolbar */
.shop-toolbar-v2 { display: flex; align-items: center; justify-content: space-between; background: #fff; border-radius: 14px; padding: 0.8rem 1.2rem; margin-bottom: 1.2rem; border: 1px solid #f1f5f9; gap: 1rem; flex-wrap: wrap; }
.toolbar-left { display: flex; align-items: center; gap: 1rem; }
.filter-toggle-btn { display: none; align-items: center; gap: 0.5rem; background: var(--blue); color: #fff; border: none; padding: 0.5rem 1rem; border-radius: 8px; font-weight: 700; font-size: 0.85rem; cursor: pointer; }
.results-label { font-size: 0.85rem; color: #64748b; }
.results-label strong { color: var(--dark); }
.toolbar-right { display: flex; align-items: center; gap: 0.8rem; }
.sort-form { display: flex; align-items: center; }
.sort-select-v2 { padding: 0.5rem 1rem; border: 1.5px solid #e2e8f0; border-radius: 8px; font-size: 0.85rem; outline: none; background: #fff; cursor: pointer; font-weight: 600; color: var(--dark); }
.view-toggle { display: flex; gap: 0.3rem; }
.view-btn { width: 36px; height: 36px; border-radius: 8px; display: flex; align-items: center; justify-content: center; color: #94a3b8; border: 1.5px solid #e2e8f0; transition: 0.3s; text-decoration: none; }
.view-btn.active, .view-btn:hover { background: var(--blue); border-color: var(--blue); color: #fff; }

/* Active Filters */
.active-filters { display: flex; align-items: center; gap: 0.6rem; flex-wrap: wrap; margin-bottom: 1.2rem; font-size: 0.82rem; }
.active-filters > span { color: #94a3b8; font-weight: 700; }
.filter-tag { display: inline-flex; align-items: center; gap: 0.4rem; background: #eff6ff; color: var(--blue); padding: 0.3rem 0.8rem; border-radius: 50px; font-weight: 700; text-decoration: none; border: 1px solid #bfdbfe; }
.filter-tag i { font-size: 0.7rem; }
.clear-all-link { color: #ef4444; font-weight: 700; text-decoration: none; margin-left: 0.5rem; }

/* Product Grid V2 */
.products-grid-v2 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; }
.products-list-v2 { display: flex; flex-direction: column; gap: 1rem; }

/* Product Card V2 */
.product-card-v2 { background: #fff; border-radius: 18px; overflow: hidden; border: 1px solid #f1f5f9; transition: 0.3s; position: relative; display: flex; flex-direction: column; }
.product-card-v2:hover { box-shadow: 0 20px 50px rgba(0,0,0,0.08); transform: translateY(-4px); border-color: #e2e8f0; }
.product-card-v2.list-mode { flex-direction: row; border-radius: 16px; }
.product-card-v2.list-mode .card-img-wrap { width: 220px; flex-shrink: 0; border-radius: 0; }
.product-card-v2.list-mode .card-body { flex: 1; padding: 1.5rem; display: flex; flex-direction: column; justify-content: space-between; }

.card-badge { position: absolute; top: 0.8rem; left: 0.8rem; z-index: 2; font-size: 0.65rem; font-weight: 800; padding: 0.25rem 0.7rem; border-radius: 50px; text-transform: uppercase; }
.card-badge.featured { background: var(--blue); color: #fff; }
.card-badge.sale { background: #ef4444; color: #fff; left: auto; right: 0.8rem; }

.card-img-wrap { position: relative; height: 220px; overflow: hidden; background: #fff; display: flex; align-items: center; justify-content: center; border-bottom: 1px solid #f1f5f9; }
.card-img-wrap img { max-width: 90%; max-height: 90%; width: auto; height: auto; object-fit: contain; padding: 0; transition: 0.4s; }
.product-card-v2:hover .card-img-wrap img { transform: scale(1.06); }
.card-overlay { position: absolute; inset: 0; background: rgba(15,23,42,0.7); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.6rem; opacity: 0; transition: 0.3s; }
.product-card-v2:hover .card-overlay { opacity: 1; }
.overlay-action { display: flex; align-items: center; gap: 0.5rem; background: #fff; color: var(--dark); border: none; padding: 0.5rem 1.1rem; border-radius: 8px; font-size: 0.8rem; font-weight: 700; cursor: pointer; text-decoration: none; transition: 0.3s; }
.overlay-action:hover { background: var(--blue); color: #fff; }

.card-body { padding: 1.1rem; display: flex; flex-direction: column; gap: 0.4rem; flex: 1; }
.card-category { font-size: 0.7rem; font-weight: 700; color: var(--blue); text-transform: uppercase; letter-spacing: 0.05em; text-decoration: none; }
.card-title { margin: 0; font-size: 0.92rem; font-weight: 700; line-height: 1.35; }
.card-title a { color: var(--dark); text-decoration: none; transition: 0.3s; }
.card-title a:hover { color: var(--blue); }
.card-desc { font-size: 0.82rem; color: #64748b; line-height: 1.5; margin: 0; }

.card-footer { display: flex; align-items: center; justify-content: space-between; margin-top: auto; padding-top: 0.8rem; border-top: 1px solid #f8fafc; }
.card-price { display: flex; flex-direction: column; }
.price-now { font-size: 1rem; font-weight: 800; color: var(--blue); }
.price-was { font-size: 0.75rem; text-decoration: line-through; color: #94a3b8; }
.price-on-req { font-size: 0.8rem; color: #64748b; font-style: italic; }
.card-actions { display: flex; align-items: center; gap: 0.5rem; }
.btn-view { display: inline-flex; align-items: center; gap: 0.3rem; font-size: 0.78rem; font-weight: 700; color: #fff; background: var(--blue); padding: 0.45rem 0.9rem; border-radius: 8px; text-decoration: none; transition: 0.3s; }
.btn-view:hover { background: var(--blue-dark); }
.btn-cart { width: 34px; height: 34px; border-radius: 8px; border: 1.5px solid #e2e8f0; background: #fff; color: #64748b; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: 0.3s; font-size: 0.85rem; }
.btn-cart:hover { background: var(--blue); border-color: var(--blue); color: #fff; }
.out-of-stock-badge { font-size: 0.72rem; color: #ef4444; font-weight: 700; }
.low-stock-bar { background: #fff7ed; color: #ea580c; font-size: 0.72rem; font-weight: 700; padding: 0.3rem 0.8rem; text-align: center; border-top: 1px solid #fed7aa; }

/* Empty State */
.shop-empty-state { text-align: center; padding: 5rem 2rem; background: #fff; border-radius: 20px; }
.empty-icon { width: 80px; height: 80px; background: #f1f5f9; border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto 1.5rem; font-size: 2rem; color: #94a3b8; }
.shop-empty-state h3 { font-size: 1.4rem; font-weight: 800; margin-bottom: 0.5rem; }
.shop-empty-state p { color: #64748b; margin-bottom: 1.5rem; line-height: 1.6; }
.shop-empty-state .btn { margin: 0 0.3rem; }

/* Pagination V2 */
.pagination-v2 { display: flex; align-items: center; justify-content: center; gap: 0.4rem; margin-top: 2.5rem; flex-wrap: wrap; }
.pg-btn-v2 { min-width: 40px; height: 40px; padding: 0 0.8rem; border-radius: 10px; border: 1.5px solid #e2e8f0; display: flex; align-items: center; justify-content: center; font-size: 0.88rem; font-weight: 700; color: var(--dark); text-decoration: none; transition: 0.3s; background: #fff; }
.pg-btn-v2:hover, .pg-btn-v2.active { background: var(--blue); border-color: var(--blue); color: #fff; }
.pg-dots { color: #94a3b8; padding: 0 0.4rem; }

/* Responsive */
@media(max-width: 1100px) {
  .products-grid-v2 { grid-template-columns: repeat(2, 1fr); }
}
@media(max-width: 900px) {
  .shop-page-inner { grid-template-columns: 1fr; }
  .shop-sidebar {
    position: fixed;
    top: 0; left: -100%;
    width: 300px; height: 100vh;
    z-index: 300;
    border-radius: 0;
    overflow-y: auto;
    transition: left 0.3s ease;
  }
  .shop-sidebar.open { left: 0; }
  .sidebar-overlay { display: block; opacity: 0; pointer-events: none; transition: 0.3s; z-index: 299; }
  .sidebar-overlay.open { opacity: 1; pointer-events: all; }
  .sidebar-close { display: flex; }
  .filter-toggle-btn { display: flex; }
}
@media(max-width: 600px) {
  .products-grid-v2 { grid-template-columns: 1fr 1fr; gap: 0.8rem; }
  .shop-hero-content { flex-direction: column; }
  .shop-hero-search { width: 100%; max-width: 100%; }
  .product-card-v2.list-mode { flex-direction: column; }
  .product-card-v2.list-mode .card-img-wrap { width: 100%; }
}
@media(max-width: 400px) {
  .products-grid-v2 { grid-template-columns: 1fr; }
}
