:root {
  --bg: #f3f5f0;
  --surface: #ffffff;
  --ink: #18211b;
  --muted: #657069;
  --line: #dfe4dd;
  --accent: #0b7f58;
  --accent-dark: #075b40;
  --accent-soft: #dff2e6;
  --gold: #f2c94c;
  --price: #c5162d;
  --cta: #07864f;
  --cta-dark: #05633b;
  --soft: #eef5ef;
  --shadow: 0 12px 32px rgba(24, 33, 27, 0.08);
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at top left, rgba(242, 201, 76, 0.16), transparent 32rem),
    linear-gradient(180deg, #fbfcf8 0%, var(--bg) 18rem);
  color: var(--ink);
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.45;
}

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

button,
input {
  font: inherit;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(10px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.brand-mark {
  display: grid;
  width: 50px;
  height: 50px;
  place-items: center;
  flex: 0 0 auto;
  overflow: hidden;
  border: 2px solid #fff;
  border-radius: 50%;
  background:
    linear-gradient(140deg, var(--gold), #fff 44%, #e93e3a 45%, #0b7f58 72%);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  box-shadow: 0 8px 18px rgba(24, 33, 27, 0.16);
}

.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.brand-mark img + span {
  display: none;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  font-size: 16px;
  line-height: 1.12;
}

.brand small {
  color: var(--muted);
  font-size: 12px;
}

.top-actions {
  display: flex;
  gap: 8px;
  flex: 0 0 auto;
}

.top-actions a {
  min-height: 40px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  font-weight: 700;
  font-size: 14px;
}

.sticky-search {
  position: fixed;
  right: 12px;
  bottom: 10px;
  left: 12px;
  z-index: 80;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  width: auto;
  max-width: 680px;
  margin: 0 auto;
  padding: 8px;
  border: 1px solid rgba(7, 134, 79, 0.26);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 10px 28px rgba(24, 33, 27, 0.22);
  backdrop-filter: blur(12px);
}

.sticky-search.is-detail {
  display: none;
}

.sticky-search input {
  width: 100%;
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid #cfdacf;
  border-radius: 8px;
  background: #fff;
  font-size: 15px;
}

.sticky-search button {
  min-height: 42px;
  padding: 0 14px;
  border: 0;
  border-radius: 8px;
  background: var(--cta);
  color: #fff;
  font-weight: 900;
}

main {
  width: min(1120px, 100%);
  max-width: 100%;
  margin: 0 auto;
  padding: 16px 16px 78px;
}

.hero {
  display: grid;
  gap: 16px;
  margin: 6px 0 18px;
  padding: 18px;
  border: 1px solid #dbe5d8;
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.92), rgba(255, 255, 255, 0.74)),
    linear-gradient(120deg, rgba(11, 127, 88, 0.16), rgba(242, 201, 76, 0.24));
  box-shadow: var(--shadow);
}

.hero-copy {
  display: grid;
  gap: 10px;
}

.eyebrow {
  margin: 0;
  color: var(--accent-dark);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero h1 {
  margin: 0;
  font-size: 36px;
  line-height: 1.02;
}

.hero p {
  margin: 0;
  color: #445049;
  font-size: 17px;
}

.hero-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 9px;
  margin-top: 4px;
}

.primary-link,
.secondary-link {
  display: grid;
  min-height: 48px;
  place-items: center;
  border-radius: 8px;
  font-weight: 900;
}

.primary-link {
  background: var(--cta);
  color: #fff;
}

.secondary-link {
  border: 1px solid #cfdacf;
  background: #fff;
}

.hero-badge {
  display: grid;
  gap: 4px;
  align-content: center;
  min-height: 118px;
  padding: 16px;
  border-radius: 8px;
  background: #12231a;
  color: #fff;
  transition: transform 150ms ease, background 150ms ease;
}

.hero-badge:hover {
  transform: translateY(-2px);
  background: #0d2b1d;
}

.hero-badge strong {
  color: var(--gold);
  font-size: 14px;
  text-transform: uppercase;
}

.hero-badge span {
  font-size: 30px;
  font-weight: 900;
}

.hero-badge small {
  color: rgba(255, 255, 255, 0.78);
}

.toolbar {
  display: grid;
  gap: 16px;
  padding: 8px 0 14px;
}

.search-box {
  display: grid;
  gap: 8px;
  max-width: 560px;
}

.search-box label,
.category-heading {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.search-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}

.search-row input {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.search-row button,
.wa-button,
.pager button {
  min-height: 48px;
  border: 0;
  border-radius: 8px;
  background: var(--cta);
  color: #fff;
  font-weight: 900;
  cursor: pointer;
}

.search-row button {
  padding: 0 18px;
}

.category-tools {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 10px;
  border: 1px solid #d7e5d8;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.68);
}

.category-strip {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  overflow: visible;
}

.category-link {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  width: 100%;
  max-width: 100%;
  min-height: 38px;
  padding: 7px 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-weight: 800;
  font-size: 12px;
}

.category-link span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.category-link small {
  display: grid;
  min-width: 22px;
  height: 22px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 999px;
  background: var(--soft);
  color: var(--accent-dark);
  font-size: 11px;
  font-weight: 900;
}

.category-link.is-active {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--accent-dark);
}

.category-link.is-active small {
  background: #fff;
}

.category-new-dot {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: #c1121f;
  box-shadow: 0 0 0 2px #fff;
}

.notice {
  margin: 2px 0 18px;
  padding: 12px 14px;
  border: 1px solid #cbdccd;
  border-radius: 8px;
  background: var(--soft);
  color: #243229;
  font-size: 14px;
}

.loading-state {
  margin: 12px 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffbe6;
  color: #6f4b00;
  font-weight: 800;
  text-align: center;
}

.loading-state[hidden] {
  display: none;
}

.page-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 10px;
  margin: 8px 0 14px;
}

.page-head h1 {
  margin: 0;
  font-size: 24px;
  line-height: 1.14;
}

.page-head p {
  margin: 4px 0 0;
  color: var(--muted);
}

.page-head .search-note {
  color: var(--accent-dark);
  font-weight: 800;
}

.result-actions {
  display: grid;
  gap: 8px;
  justify-items: end;
  flex: 0 0 auto;
}

.result-actions p {
  margin: 0;
}

.clear-search {
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid #cfdacf;
  border-radius: 8px;
  background: #fff;
  color: var(--accent-dark);
  font-weight: 900;
  cursor: pointer;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.product-grid.is-loading {
  opacity: 0.58;
  pointer-events: none;
}

.product-card {
  display: grid;
  grid-template-rows: auto 1fr;
  overflow: hidden;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
  transition: transform 150ms ease, box-shadow 150ms ease;
}

.product-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 38px rgba(24, 33, 27, 0.13);
}

.product-image,
.detail-image {
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
  padding: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.74), rgba(255, 255, 255, 0.08)),
    var(--tile);
}

.product-image {
  aspect-ratio: 1 / 1;
}

.detail-image {
  aspect-ratio: 1 / 1;
  min-width: 0;
  min-height: 0;
  max-height: none;
}

.detail-image.has-image {
  display: block;
  aspect-ratio: auto;
  overflow: visible;
  padding: 0;
  background: #fff;
  cursor: zoom-in;
}

.detail-image.has-image::before {
  display: none;
}

.product-image::before,
.detail-image::before {
  content: "";
  position: absolute;
  width: 56%;
  height: 56%;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.44);
  transform: rotate(-8deg);
}

.product-image span,
.detail-image span {
  position: relative;
  z-index: 1;
  width: min(74%, 230px);
  padding: 18px 14px;
  border: 2px solid rgba(255, 255, 255, 0.68);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  text-align: center;
  font-weight: 900;
}

.image-placeholder {
  display: grid;
  gap: 7px;
  align-content: center;
}

.image-placeholder strong,
.image-placeholder small {
  display: block;
}

.image-placeholder strong {
  color: var(--ink);
  font-size: 17px;
  line-height: 1.15;
}

.image-placeholder small {
  color: var(--accent-dark);
  font-size: 12px;
  text-transform: uppercase;
}

.product-image.has-image .image-fallback,
.detail-image.has-image .image-fallback {
  display: none;
}

.zoom-hint {
  width: 100%;
  min-height: 44px;
  padding: 8px 11px;
  border: 0;
  border-radius: 999px;
  background: #ffdf2e;
  color: #102016;
  font-size: 15px;
  font-weight: 900;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.28);
}

.product-image img,
.detail-image img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #fff;
  border-radius: 6px;
}

.detail-image.has-image img {
  display: block;
  height: auto;
  max-height: none;
}

.product-body {
  display: grid;
  grid-template-rows: auto auto auto auto 1fr;
  gap: 7px;
  padding: 12px;
}

.product-category {
  width: fit-content;
  padding: 5px 8px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-dark);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.product-title {
  display: -webkit-box;
  min-height: 42px;
  margin: 0;
  font-size: 17px;
  line-height: 1.22;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.product-desc {
  display: -webkit-box;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.28;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.price {
  width: fit-content;
  padding: 4px 8px 5px;
  border-radius: 8px;
  background: #fff1f2;
  color: var(--price);
  font-size: 26px;
  font-weight: 900;
  line-height: 1;
}

.card-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 9px;
  align-self: end;
  margin-top: 2px;
}

.detail-link {
  min-height: 42px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  text-align: center;
  font-weight: 800;
}

.wa-button {
  display: grid;
  min-height: 50px;
  place-items: center;
  padding: 10px;
  text-align: center;
  font-size: 16px;
  box-shadow: 0 8px 18px rgba(7, 134, 79, 0.2);
}

.wa-button:hover,
.search-row button:hover,
.sticky-search button:hover,
.pager button:hover {
  background: var(--cta-dark);
}

.pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 56px;
  margin: 16px 0;
}

.pager button {
  min-width: 92px;
  padding: 0 12px;
}

.pager button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.detail-view {
  display: none;
}

.detail-view.is-open {
  display: block;
}

.detail-layout {
  display: grid;
  gap: 18px;
  min-width: 0;
}

.detail-media {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.image-note {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}

.detail-copy {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.back-link {
  color: var(--accent-dark);
  font-weight: 900;
}

.detail-copy h1 {
  margin: 0;
  font-size: 32px;
  line-height: 1.1;
}

.detail-copy p {
  margin: 0;
  color: var(--muted);
  font-size: 17px;
}

.detail-specs {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.detail-specs h2 {
  margin: 0;
  color: var(--accent-dark);
  font-size: 20px;
  line-height: 1.15;
}

.detail-specs ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.detail-specs li {
  padding: 9px 10px;
  border-radius: 8px;
  background: var(--soft);
  color: #243229;
  font-weight: 800;
}

.detail-consult {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid #b8d9c3;
  border-radius: 8px;
  background: linear-gradient(135deg, #ecfff4, #ffffff);
  box-shadow: 0 10px 22px rgba(7, 134, 79, 0.1);
}

.detail-consult strong {
  color: var(--accent-dark);
  font-size: 18px;
}

.detail-consult span {
  color: #445049;
  font-size: 15px;
}

.info-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.info-list li {
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.empty-state {
  display: grid;
  gap: 12px;
  justify-items: center;
  grid-column: 1 / -1;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  text-align: center;
}

.empty-state h2,
.empty-state p {
  margin: 0;
}

.empty-state p {
  color: var(--muted);
}

.empty-state .wa-button {
  width: min(100%, 340px);
}

.store-info {
  display: grid;
  gap: 12px;
  margin: 26px 0 6px;
  padding: 18px;
  border: 1px solid #cfdacf;
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.store-info h2 {
  margin: 0;
  font-size: 22px;
  line-height: 1.15;
}

.store-info p {
  margin: 0;
  color: #445049;
}

.store-info ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.store-info li {
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--soft);
  color: #223128;
  font-weight: 700;
}

.store-wa-link {
  display: grid;
  min-height: 50px;
  place-items: center;
  border-radius: 8px;
  background: var(--cta);
  color: #fff;
  font-size: 16px;
  font-weight: 900;
  box-shadow: 0 8px 18px rgba(7, 134, 79, 0.2);
}

.site-footer {
  width: min(1120px, 100%);
  margin: 20px auto 0;
  padding: 18px 16px 28px;
  color: var(--muted);
  font-size: 13px;
}

.site-footer p {
  margin: 4px 0;
}

.image-viewer {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
  align-content: center;
  justify-items: center;
  gap: 10px;
  padding: 18px 12px;
  background: rgba(8, 18, 12, 0.9);
}

.image-viewer.is-open {
  display: grid;
}

.image-viewer img {
  order: 1;
  width: 100%;
  max-width: 980px;
  max-height: 78vh;
  object-fit: contain;
  border-radius: 8px;
  background: #fff;
}

.viewer-title {
  display: none;
}

.viewer-close {
  order: 2;
  position: static;
  width: min(100%, 980px);
  min-height: 44px;
  padding: 0 16px;
  border: 0;
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-weight: 900;
}

  @media (min-width: 720px) {
  .topbar {
    padding: 14px 28px;
  }

  .sticky-search {
    right: 24px;
    bottom: 18px;
    left: 24px;
    width: auto;
    grid-template-columns: minmax(260px, 520px) auto;
  }

  main {
    padding: 24px 24px 86px;
  }

  .hero {
    grid-template-columns: 1fr 310px;
    align-items: stretch;
    padding: 26px;
  }

  .hero h1 {
    font-size: 46px;
  }

  .hero-actions {
    grid-template-columns: repeat(2, minmax(0, 190px));
  }

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

  .page-head h1 {
    font-size: 32px;
  }

  .product-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
  }

  .detail-layout {
    grid-template-columns: minmax(280px, 0.92fr) 1fr;
    align-items: start;
  }

  .detail-image {
    min-height: min(68vh, 560px);
    max-height: none;
  }

  .detail-copy h1 {
    font-size: 38px;
  }

  .store-info {
    padding: 24px;
  }

  .store-info ul {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
