/* ============================================
   CATALOG — products.php
   ============================================ */
.catalog {
  padding-bottom: 3rem;
}
.catalog-hero {
  background:
    radial-gradient(700px 280px at 100% 0%, rgba(61, 95, 217, 0.22), transparent 55%),
    linear-gradient(160deg, #031b4e 0%, #15358a 55%, #2448c6 120%);
  color: #fff;
  padding: 2.25rem 1.25rem 2.5rem;
  margin-bottom: 0;
}
.catalog-hero-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  gap: 1.5rem;
}
@media (min-width: 900px) {
  .catalog-hero-inner {
    grid-template-columns: 1.4fr 1fr;
    align-items: end;
  }
}
.catalog-hero .shop-eyebrow { color: #9db0ff; }
.catalog-hero .shop-h1 { color: #fff; margin-bottom: 0.5rem; }
.catalog-hero .shop-lead {
  color: rgba(255, 255, 255, 0.82);
  max-width: 42ch;
}
.catalog-hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}
.catalog-hero-stats .catalog-stat {
  min-width: 96px;
  padding: 0.85rem 1rem;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(8px);
}
.catalog-hero-stats .catalog-stat strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.35rem;
  color: #fff;
  line-height: 1;
}
.catalog-hero-stats .catalog-stat span {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.7);
  font-weight: 600;
}

.catalog-toolbar {
  position: relative;
  z-index: 1;
  background: var(--paper, #f5f7fc);
  border-bottom: 1px solid transparent;
  padding: 1rem 1.25rem 0.85rem;
}
.catalog-toolbar.is-stuck {
  /* legacy no-op — toolbar nie jest sticky */
}
.catalog-search {
  max-width: 1280px;
  margin: 0 auto 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  height: 52px;
  padding: 0 0.45rem 0 1rem;
  border-radius: 16px;
  background: #fff;
  border: 1.5px solid var(--line);
  box-shadow: var(--shadow);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.catalog-search:focus-within {
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(36, 72, 198, 0.14);
}
.catalog-search-ico {
  width: 34px;
  height: 34px;
  border-radius: 11px;
  background: linear-gradient(145deg, #2448c6, #1a3594);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.catalog-search-ico svg { width: 16px !important; height: 16px !important; color: #fff !important; }
.catalog-search input {
  flex: 1;
  min-width: 0;
  border: none;
  background: transparent;
  font: inherit;
  font-size: 1rem;
  font-weight: 500;
  color: var(--ink);
  outline: none;
  height: 100%;
}
.catalog-search-clear {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: var(--blue-mist);
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  flex-shrink: 0;
}
.catalog-search-clear svg { width: 14px !important; height: 14px !important; }
.catalog-search-btn {
  height: 40px;
  padding: 0 1.1rem;
  border: none;
  border-radius: 12px;
  background: var(--blue);
  color: #fff;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  flex-shrink: 0;
}
.catalog-search-btn:hover { background: var(--blue-deep); }

.catalog-meta-row {
  max-width: 1280px;
  margin: 0 auto 0.75rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
}
.catalog-count {
  margin: 0;
  font-size: 0.92rem;
  color: var(--muted);
}
.catalog-count strong { color: var(--ink); font-size: 1.05rem; }
.catalog-sort {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--ink-soft);
}
.catalog-sort select {
  height: 40px;
  padding: 0 2rem 0 0.85rem;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23031b4e' stroke-width='2.5'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 0.75rem center;
  appearance: none;
  font: inherit;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
}

.catalog-filters {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  gap: 0.45rem;
  overflow-x: auto;
  padding-bottom: 0.35rem;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.catalog-filters::-webkit-scrollbar { display: none; }
.catalog-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  flex-shrink: 0;
  height: 38px;
  padding: 0 0.9rem;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
  transition: background 0.15s, border-color 0.15s, color 0.15s, box-shadow 0.15s;
}
.catalog-chip svg { width: 14px !important; height: 14px !important; color: var(--blue); }
.catalog-chip:hover {
  border-color: rgba(36, 72, 198, 0.35);
  color: var(--blue);
}
.catalog-chip.is-active {
  background: var(--blue);
  border-color: var(--blue);
  color: #fff;
  box-shadow: 0 8px 20px rgba(36, 72, 198, 0.28);
}
.catalog-chip.is-active svg { color: #fff !important; }

.catalog-body {
  max-width: 1280px;
  margin: 0 auto;
  padding: 1.5rem 1.25rem 0;
}
.catalog-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1.15rem;
}
.catalog-item.is-hidden { display: none !important; }

.ccard {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: #fff;
  border-radius: 22px;
  overflow: hidden;
  border: 1px solid rgba(3, 27, 78, 0.07);
  box-shadow: var(--shadow);
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s, box-shadow 0.2s;
}
.ccard:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.ccard.is-special {
  box-shadow: 0 0 0 2px rgba(36, 72, 198, 0.25), var(--shadow);
}
.ccard-media {
  position: relative;
  aspect-ratio: 2 / 1;
  background: var(--blue-wash);
  overflow: hidden;
}
.ccard-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.ccard-badge {
  position: absolute;
  top: 0.65rem;
  left: 0.65rem;
  padding: 0.25rem 0.55rem;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  color: #fff;
  backdrop-filter: blur(6px);
}
.ccard-badge-hot { background: rgba(252, 42, 0, 0.9); }
.ccard-badge-special {
  left: auto;
  right: 0.65rem;
  background: rgba(36, 72, 198, 0.92);
}
.ccard-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 1rem 1.05rem 1.1rem;
  gap: 0.25rem;
}
.ccard-body h2 {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.2;
}
.ccard-range {
  margin: 0;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--blue);
}
.ccard-range small {
  font-weight: 600;
  color: var(--muted);
  font-size: 0.8rem;
}
.ccard-pts {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin: 0.15rem 0 0;
  padding: 0.3rem 0.55rem;
  width: fit-content;
  border-radius: 999px;
  background: var(--blue-mist);
  color: var(--blue);
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.2;
}
.ccard-pts .shop-icon,
.ccard-pts svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}
.ccard-desc {
  margin: 0.35rem 0 0.75rem;
  font-size: 0.84rem;
  line-height: 1.45;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}
.ccard-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--blue);
  margin-top: auto;
}
.ccard-cta svg { width: 15px !important; height: 15px !important; }
.ccard:hover .ccard-cta { text-decoration: underline; }

.catalog-empty {
  text-align: center;
  padding: 3.5rem 1rem;
  background: #fff;
  border-radius: 22px;
  border: 1px solid var(--line);
}
.catalog-empty.is-hidden { display: none !important; }
.catalog-empty-ico {
  width: 64px;
  height: 64px;
  margin: 0 auto 1rem;
  border-radius: 20px;
  background: var(--blue-mist);
  color: var(--blue);
  display: flex;
  align-items: center;
  justify-content: center;
}
.catalog-empty-ico svg { width: 28px !important; height: 28px !important; }
.catalog-empty h2 {
  margin: 0 0 0.4rem;
  font-family: var(--font-display);
  font-size: 1.4rem;
}
.catalog-empty p {
  margin: 0 auto 1.25rem;
  max-width: 34ch;
  color: var(--muted);
  line-height: 1.45;
}

.catalog-footer-cta {
  max-width: 1280px;
  margin: 2.5rem auto 0;
  padding: 1.5rem 1.35rem;
  border-radius: 22px;
  background:
    radial-gradient(500px 200px at 100% 0%, rgba(61, 95, 217, 0.25), transparent 55%),
    linear-gradient(135deg, #031b4e, #2448c6);
  color: #fff;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.catalog-footer-cta h2 {
  margin: 0 0 0.3rem;
  font-family: var(--font-display);
  font-size: 1.35rem;
}
.catalog-footer-cta p {
  margin: 0;
  opacity: 0.85;
  font-size: 0.92rem;
}
.catalog-footer-cta .shop-btn-primary {
  background: #fff;
  color: var(--blue) !important;
  box-shadow: none;
}
.catalog-footer-cta .shop-btn-primary:hover {
  background: var(--blue-mist);
}

.is-hidden[hidden] { display: none !important; }

@media (max-width: 767px) {
  .catalog-hero { padding: 1.75rem 1rem 2rem; }
  .catalog-toolbar {
    top: 60px;
    padding: 0.75rem 0.85rem 0.65rem;
  }
  .catalog-search {
    height: 46px;
    padding-left: 0.75rem;
    border-radius: 14px;
  }
  .catalog-search-btn { display: none; }
  .catalog-search-ico { width: 30px; height: 30px; border-radius: 9px; }
  .catalog-meta-row { gap: 0.5rem; }
  .catalog-sort {
    width: 100%;
    justify-content: space-between;
  }
  .catalog-sort select { flex: 1; }
  .catalog-body { padding: 1.1rem 0.85rem 0; }
  .catalog-grid {
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
  }
  .ccard { border-radius: 16px; }
  .ccard-body { padding: 0.75rem 0.8rem 0.85rem; }
  .ccard-body h2 { font-size: 0.95rem; }
  .ccard-desc { display: none; }
  .ccard-cta { font-size: 0.78rem; }
  .ccard-range { font-size: 0.82rem; }
  .catalog-footer-cta {
    margin: 1.75rem 0.85rem 0;
    padding: 1.25rem 1.1rem;
    flex-direction: column;
    align-items: stretch;
    text-align: center;
  }
  .catalog-footer-cta .shop-btn { width: 100%; }
}

@media (max-width: 379px) {
  .catalog-grid { grid-template-columns: 1fr; }
}
