/* ==========================================================================
   products-modern.css — Clean & minimal redesign for the products page
   Loaded ONLY on products.php, AFTER products.css, so it overrides without
   affecting any other page. Every selector is scoped to `body.products-modern`
   to keep specificity high and bleed at zero. Mirrors home-modern.css tokens.
   ========================================================================== */

/* ---- Design tokens ---- */
body.products-modern {
  --pp-primary: #2563eb;
  --pp-primary-dark: #1d4ed8;
  --pp-primary-soft: #eff6ff;
  --pp-ink: #0f172a;
  --pp-body: #475569;
  --pp-muted: #64748b;
  --pp-line: #e2e8f0;
  --pp-bg: #ffffff;
  --pp-bg-alt: #f8fafc;
  --pp-radius: 18px;
  --pp-radius-sm: 12px;
  --pp-shadow: 0 1px 3px rgba(15, 23, 42, 0.06), 0 12px 32px -12px rgba(15, 23, 42, 0.12);
  --pp-shadow-hover: 0 18px 48px -16px rgba(37, 99, 235, 0.28);
  font-family: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
  color: var(--pp-body);
  -webkit-font-smoothing: antialiased;
}

body.products-modern h1,
body.products-modern h2,
body.products-modern h3,
body.products-modern h4 {
  font-family: "Poppins", "Inter", system-ui, sans-serif;
  letter-spacing: -0.01em;
}

body.products-modern .title-blue {
  color: var(--pp-primary);
  font-weight: 700;
}

/* ==========================================================================
   HERO
   ========================================================================== */
body.products-modern .products-hero {
  background: radial-gradient(1200px 600px at 80% -10%, #eef4ff 0%, rgba(238, 244, 255, 0) 60%),
    linear-gradient(180deg, #ffffff 0%, var(--pp-bg-alt) 100%);
  padding: 80px 0 64px;
  min-height: auto;
}

body.products-modern .products-hero-container {
  max-width: 1240px;
  padding: 0 40px;
}

body.products-modern .products-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--pp-primary-soft);
  color: var(--pp-primary-dark);
  padding: 8px 16px;
  border: 1px solid #dbeafe;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  margin-bottom: 22px;
}
body.products-modern .products-hero-badge i {
  color: var(--pp-primary);
}

body.products-modern .products-hero-title {
  font-size: clamp(34px, 4.4vw, 54px);
  line-height: 1.1;
  font-weight: 700;
  color: var(--pp-ink);
  margin: 0 0 18px;
}

body.products-modern .products-hero-description {
  font-size: 17px;
  color: var(--pp-muted);
  line-height: 1.7;
  margin: 0 auto;
  max-width: 640px;
}

/* ==========================================================================
   SEARCH + FILTER
   ========================================================================== */
body.products-modern .search-filter-section {
  background: #fff;
  border-bottom: 1px solid var(--pp-line);
  padding: 48px 0;
}
body.products-modern .container {
  max-width: 1240px;
  padding: 0 40px;
}
body.products-modern .search-filter-content {
  gap: 32px;
}

body.products-modern .search-bar {
  background: var(--pp-bg-alt);
  border: 1px solid var(--pp-line);
  border-radius: 999px;
  padding: 13px 22px;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}
body.products-modern .search-bar:focus-within {
  border-color: var(--pp-primary);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}
body.products-modern .search-icon {
  color: var(--pp-muted);
  font-size: 16px;
  margin-right: 14px;
}
body.products-modern .search-input {
  font-size: 15px;
  color: var(--pp-ink);
}
body.products-modern .search-input::placeholder {
  color: var(--pp-muted);
}
body.products-modern .search-clear {
  color: var(--pp-muted);
  font-size: 14px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
}
body.products-modern .search-clear:hover {
  background: var(--pp-primary-soft);
  color: var(--pp-primary);
}

/* Filter tabs */
body.products-modern .filter-tabs {
  gap: 12px;
}
body.products-modern .filter-tab {
  background: #fff;
  border: 1px solid var(--pp-line);
  color: var(--pp-body);
  padding: 11px 22px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  transition: transform 0.18s ease, border-color 0.18s ease, color 0.18s ease, background 0.18s ease;
}
body.products-modern .filter-tab:hover {
  border-color: var(--pp-primary);
  color: var(--pp-primary);
  transform: translateY(-2px);
}
body.products-modern .filter-tab.active {
  background: var(--pp-primary);
  border-color: var(--pp-primary);
  color: #fff;
  box-shadow: 0 10px 24px -12px rgba(37, 99, 235, 0.6);
}

/* ==========================================================================
   PRODUCTS GRID
   ========================================================================== */
body.products-modern .products-grid-section {
  background: var(--pp-bg-alt);
  padding: 72px 0;
}
body.products-modern .products-header {
  margin-bottom: 36px;
}
body.products-modern .products-count {
  font-size: 22px;
  color: var(--pp-ink);
  font-weight: 600;
}

body.products-modern .products-grid {
  grid-template-columns: repeat(auto-fill, minmax(300px, 360px));
  gap: 28px;
  justify-content: center;
}

/* Clean product card */
body.products-modern .product-card {
  background: #fff;
  border: 1px solid var(--pp-line);
  border-radius: var(--pp-radius);
  overflow: hidden;
  box-shadow: var(--pp-shadow);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
  min-height: 0;
}
body.products-modern .product-card:hover {
  transform: translateY(-8px);
  border-color: #dbeafe;
  box-shadow: var(--pp-shadow-hover);
}

body.products-modern .product-image {
  height: 230px;
  background: var(--pp-bg-alt);
}
body.products-modern .product-image img {
  object-fit: contain;
  background: #fff;
  transition: transform 0.4s ease;
}
body.products-modern .product-card:hover .product-image img {
  transform: scale(1.06);
}

/* Icon tile */
body.products-modern .product-icon {
  top: 16px;
  right: 16px;
  width: 46px;
  height: 46px;
  border-radius: var(--pp-radius-sm);
  background: var(--pp-primary-soft);
  color: var(--pp-primary);
  font-size: 19px;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.1);
  backdrop-filter: none;
}

body.products-modern .product-content {
  padding: 22px 24px 24px;
  min-height: 0;
}
body.products-modern .product-title {
  font-size: 18px;
  color: var(--pp-ink) !important;
  font-weight: 600;
  margin: 0 0 8px;
}
body.products-modern .product-description {
  font-size: 14px;
  color: var(--pp-muted) !important;
  line-height: 1.6;
  margin: 0 0 18px;
}

/* CTA button — white text on blue */
body.products-modern .view-details-btn {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--pp-primary);
  color: #fff;
  border-radius: 12px;
  padding: 12px 24px;
  font-weight: 600;
  font-size: 14.5px;
  box-shadow: 0 10px 22px -12px rgba(37, 99, 235, 0.6);
  transition: background 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}
body.products-modern .view-details-btn:hover {
  background: var(--pp-primary-dark);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: var(--pp-shadow-hover);
}

/* No products message */
body.products-modern .no-products-icon {
  color: var(--pp-primary);
  opacity: 1;
  font-size: 52px;
}
body.products-modern .no-products-title {
  color: var(--pp-ink);
  font-size: 26px;
  font-weight: 600;
}
body.products-modern .no-products-description {
  color: var(--pp-muted);
}
body.products-modern .clear-filters-btn {
  background: var(--pp-primary);
  color: #fff;
  border-radius: 12px;
  font-weight: 600;
  transition: background 0.18s ease, transform 0.18s ease;
}
body.products-modern .clear-filters-btn:hover {
  background: var(--pp-primary-dark);
  transform: translateY(-2px);
}

/* ==========================================================================
   PAGINATION
   ========================================================================== */
body.products-modern .pagination-section {
  background: var(--pp-bg-alt);
  padding: 0 0 72px;
}
body.products-modern .pagination-text {
  color: var(--pp-muted);
  font-size: 15px;
}
body.products-modern .pagination-btn,
body.products-modern .pagination-number {
  background: #fff;
  border: 1px solid var(--pp-line);
  color: var(--pp-body);
  border-radius: 12px;
  font-weight: 600;
  transition: border-color 0.18s ease, color 0.18s ease, transform 0.18s ease, background 0.18s ease;
}
body.products-modern .pagination-btn:hover:not(:disabled),
body.products-modern .pagination-number:hover {
  border-color: var(--pp-primary);
  color: var(--pp-primary);
  transform: translateY(-2px);
}
body.products-modern .pagination-number.active {
  background: var(--pp-primary);
  border-color: var(--pp-primary);
  color: #fff;
  box-shadow: 0 10px 24px -12px rgba(37, 99, 235, 0.6);
}
body.products-modern .pagination-btn:disabled,
body.products-modern .pagination-btn.disabled {
  background: var(--pp-bg-alt);
  color: var(--pp-muted);
}

/* ==========================================================================
   CTA SECTION
   ========================================================================== */
body.products-modern .products-cta {
  background: linear-gradient(135deg, var(--pp-primary) 0%, var(--pp-primary-dark) 100%);
  padding: 64px 0 72px;
}
body.products-modern .cta-content {
  max-width: 760px;
}
body.products-modern .cta-title {
  font-size: clamp(26px, 3vw, 36px);
  color: #fff;
  font-weight: 700;
}
body.products-modern .cta-description {
  color: rgba(255, 255, 255, 0.9);
  font-size: 17px;
  line-height: 1.6;
}
/* Primary: blue text on white */
body.products-modern .btn-cta-primary {
  background: #fff;
  color: var(--pp-primary-dark);
  border-radius: 12px;
  font-weight: 600;
  box-shadow: 0 12px 30px -10px rgba(0, 0, 0, 0.4);
  transition: transform 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}
body.products-modern .btn-cta-primary:hover {
  background: #f1f5f9;
  color: var(--pp-primary-dark);
  transform: translateY(-2px);
}
/* Secondary: white text/border on blue, fills white on hover */
body.products-modern .btn-cta-secondary {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 12px;
  font-weight: 600;
  transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease;
}
body.products-modern .btn-cta-secondary:hover {
  background: #fff;
  color: var(--pp-primary-dark);
  transform: translateY(-2px);
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 992px) {
  body.products-modern .products-hero-container,
  body.products-modern .container {
    padding: 0 28px;
  }
  body.products-modern .products-grid {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  }
}
@media (max-width: 640px) {
  body.products-modern .products-hero {
    padding: 56px 0 44px;
  }
  body.products-modern .search-filter-section {
    padding: 36px 0;
  }
  body.products-modern .products-grid-section {
    padding: 48px 0;
  }
  body.products-modern .products-grid {
    grid-template-columns: 1fr;
  }
  body.products-modern .cta-buttons {
    flex-direction: column;
    align-items: center;
  }
}
