:root {
  --color-green-dark: #2d4a2d;
  --color-green-main: #5a8a3c;
  --color-green-btn: #4d7c3a;
  --color-page: #fbfbf8;
  --color-text: #101828;
  --color-muted: #667085;
  --color-border: #e4e7ec;

  --font-display: "Playfair Display", Georgia, serif;
  --font-body: "Inter", Arial, sans-serif;

  --radius-md: 16px;
  --radius-lg: 22px;
  --radius-xl: 999px;

  --shadow-soft: 0 8px 28px rgba(16, 24, 40, 0.08);
  --transition: 0.25s ease;
  --max-width: 1200px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  min-width: 320px;
  font-family: var(--font-body);
  color: var(--color-text);
  background: #fff;
  line-height: 1.6;
}

a {
  color: inherit;
  text-decoration: none;
}

ul {
  list-style: none;
}

button,
input,
select {
  font: inherit;
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--color-border);
  backdrop-filter: blur(10px);
}

.header.scrolled {
  box-shadow: 0 8px 30px rgba(16, 24, 40, 0.08);
}

.header__inner {
  height: 74px;
  display: flex;
  align-items: center;
  gap: 36px;
}

.logo {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 800;
  color: var(--color-green-main);
  white-space: nowrap;
}

.logo--light {
  color: #8fcc6a;
}

.nav {
  display: flex;
  align-items: center;
  gap: 30px;
}

.nav__link {
  font-size: 15px;
  font-weight: 500;
  color: #0f172a;
  transition: color var(--transition);
  white-space: nowrap;
}

.nav__link:hover {
  color: var(--color-green-main);
}

.header__actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 20px;
}

.header__icon {
  display: flex;
  color: #0f172a;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 42px;
  padding: 10px 24px;
  border: 0;
  border-radius: var(--radius-xl);
  background: transparent;
  cursor: pointer;
  font-size: 15px;
  font-weight: 600;
  transition: transform var(--transition), background var(--transition), box-shadow var(--transition);
}

.btn:hover {
  transform: translateY(-1px);
}

.btn--primary {
  background: #6a9858;
  color: #fff;
}

.btn--primary:hover {
  background: var(--color-green-dark);
  box-shadow: 0 10px 24px rgba(77, 124, 58, 0.22);
}

.btn--outline {
  background: #f5f2df;
  color: #0f172a;
}

.btn__plus {
  font-size: 22px;
  line-height: 1;
  font-weight: 400;
}

.burger {
  display: none;
  width: 42px;
  height: 42px;
  margin-left: auto;
  border: 0;
  background: transparent;
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.burger span {
  width: 24px;
  height: 2px;
  background: var(--color-text);
  border-radius: 999px;
  transition: transform var(--transition), opacity var(--transition);
}

.burger.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.burger.open span:nth-child(2) {
  opacity: 0;
}

.burger.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.category-page {
  padding: 36px 0 80px;
}

.page-title {
  margin-bottom: 28px;
  font-family: var(--font-display);
  font-size: clamp(34px, 4vw, 46px);
  font-weight: 800;
  line-height: 1.15;
  color: #030712;
}

.search-panel {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 32px;
  padding: 10px 12px 10px 24px;
  border: 1px solid var(--color-border);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 4px 16px rgba(16, 24, 40, 0.06);
}

.search-panel input {
  flex: 1;
  min-width: 0;
  height: 42px;
  border: 0;
  outline: none;
  font-size: 16px;
  color: var(--color-text);
}

.search-panel input::placeholder {
  color: #8a8f98;
}

.search-panel button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 10px 24px;
  border: 0;
  border-radius: 999px;
  background: #6a9858;
  color: #fff;
  cursor: pointer;
  font-weight: 600;
  transition: background var(--transition), transform var(--transition);
}

.search-panel button:hover {
  background: var(--color-green-dark);
  transform: translateY(-1px);
}

.category-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 34px;
  align-items: start;
}

.filters {
  position: sticky;
  top: 98px;
  padding: 26px 24px;
  border: 1px solid var(--color-border);
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.filters h2 {
  margin-bottom: 20px;
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
}

.filter-group {
  margin-bottom: 22px;
}

.filter-group label {
  display: block;
  margin-bottom: 9px;
  font-size: 14px;
  font-weight: 600;
  color: #344054;
}

.filter-group select,
.filter-group input {
  width: 100%;
  height: 38px;
  padding: 0 14px;
  border: 1px solid #cfd6df;
  border-radius: 999px;
  outline: none;
  background: #fff;
}

.price-inputs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.reset-btn {
  width: 100%;
  min-height: 38px;
  border: 0;
  border-radius: 999px;
  background: #f3f0dc;
  color: #0f172a;
  cursor: pointer;
  font-weight: 600;
  transition: background var(--transition), transform var(--transition);
}

.reset-btn:hover {
  background: #ebe6c8;
  transform: translateY(-1px);
}

.products-count {
  margin-bottom: 16px;
  color: #344054;
  font-size: 15px;
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.product-card {
  overflow: hidden;
  border: 1px solid var(--color-border);
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 6px 20px rgba(16, 24, 40, 0.06);
  transition: transform var(--transition), box-shadow var(--transition);
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 34px rgba(16, 24, 40, 0.12);
}

.product-card__image {
  width: 100%;
  height: 220px;
  background: #f0f1f3;
  overflow: hidden;
}

.product-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-card__body {
  padding: 20px;
}

.product-card h3 {
  margin-bottom: 8px;
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 800;
  line-height: 1.25;
  color: #030712;
}

.product-card__description {
  min-height: 46px;
  margin-bottom: 14px;
  color: #475467;
  font-size: 14px;
  line-height: 1.45;
}

.product-card__district {
  margin-bottom: 12px;
  color: #667085;
  font-size: 14px;
}

.product-card__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.product-card__price {
  color: #030712;
  font-size: 22px;
  font-weight: 800;
}

.product-card__more {
  color: var(--color-green-main);
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
}

.empty-state {
  margin-top: 20px;
  padding: 44px 28px;
  border: 1px solid var(--color-border);
  border-radius: 24px;
  background: #fff;
  text-align: center;
}

.empty-state h2 {
  margin-bottom: 8px;
  font-family: var(--font-display);
  font-size: 28px;
}

.empty-state p {
  margin-bottom: 20px;
  color: var(--color-muted);
}

.footer {
  background: var(--color-green-dark);
  color: rgba(255, 255, 255, 0.75);
  padding-top: 56px;
}

.footer__inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 44px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.footer__brand p {
  max-width: 310px;
  margin-top: 16px;
  font-size: 14px;
  line-height: 1.65;
}

.footer__col h4 {
  margin-bottom: 16px;
  color: #fff;
  font-size: 15px;
  font-weight: 700;
}

.footer__col ul {
  display: grid;
  gap: 10px;
}

.footer__col a {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.72);
}

.footer__bottom {
  padding: 20px 0;
  text-align: center;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.42);
}

@media (max-width: 1024px) {
  .products-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 980px) {
  .header__inner {
    height: 68px;
  }

  .nav,
  .header__actions {
    display: none;
  }

  .burger {
    display: flex;
  }

  .nav.open {
    position: fixed;
    top: 68px;
    left: 0;
    right: 0;
    z-index: 99;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
    padding: 24px;
    background: #fff;
    border-bottom: 1px solid var(--color-border);
    box-shadow: 0 18px 35px rgba(16, 24, 40, 0.12);
  }

  .nav.open .nav__link {
    font-size: 18px;
  }

  .category-layout {
    grid-template-columns: 1fr;
  }

  .filters {
    position: static;
  }

  .footer__inner {
    grid-template-columns: 1fr 1fr;
  }

  .footer__brand {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .container {
    padding: 0 16px;
  }

  .category-page {
    padding: 28px 0 60px;
  }

  .search-panel {
    flex-direction: column;
    align-items: stretch;
    padding: 12px;
  }

  .search-panel button {
    width: 100%;
  }

  .products-grid {
    grid-template-columns: 1fr;
  }

  .product-card__image {
    height: 210px;
  }

  .footer__inner {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

.product-card {
  cursor: pointer;
}

.product-card__more {
  position: relative;
  z-index: 2;
}

.nav__link--mobile {
  display: none;
}

@media (max-width: 980px) {
  .nav__link--mobile {
    display: block;
  }
}

.category-load {
  display: flex;
  justify-content: center;
  margin-top: 32px;
}

#loadMoreProducts {
  min-width: 190px;
}

#loadMoreProducts:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.product-card__image img {
  display: block;
}

@media (max-width: 480px) {
  .product-card__body {
    padding: 18px;
  }

  .product-card h3 {
    font-size: 19px;
  }

  .product-card__bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
}