/* ------------------------------------------------------------------------- *
 * Qaysarii storefront
 *
 * Page-level styles for the marketplace SPA. The shared brand, buttons and
 * About-page sections stay in styles.css; this file adds the catalogue,
 * shop, product and browse surfaces that the storefront needs.
 * ------------------------------------------------------------------------- */

/* Accessibility helpers --------------------------------------------------- */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  inset-inline-start: 16px;
  top: -60px;
  z-index: 100;
  background: var(--ink);
  color: var(--white);
  padding: 10px 18px;
  border-radius: 0 0 12px 12px;
  font-weight: 700;
  transition: top .2s;
}
.skip-link:focus { top: 0; }

:focus-visible {
  outline: 3px solid rgba(0, 168, 120, .55);
  outline-offset: 2px;
}

.app-main { min-height: 60vh; outline: none; }
.page-block { padding-top: 34px; padding-bottom: 74px; }
.page-loading {
  min-height: min(58vh, 480px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 70px 22px;
}
.page-loader-mark {
  position: relative;
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  border-radius: 20px;
  background: var(--white);
  border: 1px solid rgba(0, 168, 120, .16);
  box-shadow: 0 18px 44px rgba(0, 120, 90, .14);
  opacity: 0;
  animation:
    page-loader-in .2s ease .14s forwards,
    page-loader-pulse 1.6s ease-in-out .14s infinite;
}
.page-loader-mark::before {
  content: "";
  position: absolute;
  inset: -9px;
  border-radius: 27px;
  border: 2px solid transparent;
  border-top-color: var(--jade);
  border-inline-end-color: rgba(0, 168, 120, .2);
  animation: page-loader-spin .9s linear infinite;
}
.page-loader-mark img {
  width: 42px;
  height: 42px;
  border-radius: 12px;
}
@keyframes page-loader-in {
  to { opacity: 1; }
}
@keyframes page-loader-spin {
  to { transform: rotate(360deg); }
}
@keyframes page-loader-pulse {
  0%, 100% { transform: scale(.97); box-shadow: 0 14px 34px rgba(0, 120, 90, .12); }
  50% { transform: scale(1); box-shadow: 0 20px 48px rgba(0, 120, 90, .2); }
}
.page-head { max-width: 760px; margin-bottom: 30px; }
.page-head h1 { font-size: clamp(30px, 4vw, 44px); font-weight: 900; margin: 10px 0 0; }
.page-head p { color: var(--muted); font-size: 17px; margin: 12px 0 0; }
.page-head .count-pill { margin-top: 14px; }

.breadcrumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; font-size: 13px; font-weight: 600; color: var(--muted); }
.breadcrumbs a:hover { color: var(--jade-deep); }
.breadcrumbs span[aria-hidden], .breadcrumbs > span:not(:last-child) { color: #B9C0BE; }
.breadcrumbs > span:last-child { color: var(--ink); }

.noscript-note {
  margin: 20px auto;
  padding: 16px 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #FFF8E8;
}
.noscript-note a { color: var(--jade-deep); font-weight: 700; text-decoration: underline; }

/* Header ---------------------------------------------------------------- */
.header-search {
  display: flex;
  align-items: center;
  flex: 1 1 240px;
  max-width: 340px;
  background: #F1F3F2;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 3px 3px 3px 14px;
  transition: border-color .2s, background .2s;
}
[dir="rtl"] .header-search { padding: 3px 14px 3px 3px; }
.header-search:focus-within { background: var(--white); border-color: var(--jade); }
.header-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  background: transparent;
  font: inherit;
  font-size: 14px;
  color: var(--ink);
  padding: 8px 6px;
}
.header-search input:focus { outline: none; }
.header-search-btn {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  flex: none;
  border: 0;
  border-radius: 50%;
  background: var(--jade);
  color: var(--ink);
  cursor: pointer;
  transition: background .2s, color .2s;
}
.header-search-btn:hover { background: var(--jade-deep); color: var(--white); }

.nav a.active { color: var(--jade-deep); }
.nav a.active::after {
  content: "";
  display: block;
  height: 3px;
  margin-top: 3px;
  border-radius: 3px;
  background: var(--jade);
}

.mobile-nav { display: none; }

/* Shared pills, badges and small bits ----------------------------------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: .01em;
  line-height: 1;
  white-space: nowrap;
}
.badge-sale { background: #FFE9E2; color: var(--clay); }
.badge-new { background: var(--light-jade); color: var(--jade-deep); }
.badge-featured { background: #FFF1D8; color: #9A6412; }
.badge-soft { background: #F0F2F1; color: var(--muted); }
.badge-row { display: flex; flex-wrap: wrap; gap: 6px; }

.rating { color: #B47712; font-weight: 800; font-size: 13px; white-space: nowrap; }
.stars { color: var(--amber); letter-spacing: 2px; font-size: 15px; }
.dot { color: #C2C8C6; }

.count-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #F1F3F2;
  color: var(--muted);
  border-radius: 999px;
  padding: 7px 13px;
  font-size: 12.5px;
  font-weight: 700;
}

.muted { color: var(--muted); }
.small { font-size: 12px; }
.text-link { color: var(--jade-deep); font-weight: 800; }
.text-link:hover { text-decoration: underline; }

/* Home hero ------------------------------------------------------------- */
.market-hero {
  position: relative;
  overflow: hidden;
  padding: 58px 0 40px;
  background:
    radial-gradient(900px 480px at 82% -16%, rgba(0, 168, 120, .2), transparent 62%),
    radial-gradient(620px 380px at 2% 8%, rgba(232, 163, 61, .16), transparent 58%),
    var(--white);
}
.market-hero-inner {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 44px;
  align-items: center;
}
.market-hero-copy h1 {
  font-size: clamp(34px, 4.7vw, 56px);
  font-weight: 900;
  margin-top: 2px;
}
.market-hero .lead { max-width: 580px; }

.hero-search {
  display: flex;
  gap: 8px;
  margin-top: 26px;
  max-width: 560px;
  padding: 6px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 999px;
  box-shadow: 0 14px 34px rgba(10, 10, 10, .07);
}
.hero-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  background: transparent;
  font: inherit;
  font-size: 15px;
  padding: 9px 16px;
  color: var(--ink);
}
.hero-search input:focus { outline: none; }
.hero-search .btn { flex: none; padding: 11px 22px; }

.market-hero-art { position: relative; display: grid; place-items: center; min-height: 330px; }
.market-hero-art .glow {
  position: absolute;
  inset: 12% 16%;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--jade), var(--jade-deep));
  filter: blur(54px);
  opacity: .32;
}
.market-hero-art .app-icon {
  position: relative;
  width: min(250px, 64%);
  border-radius: 30%;
  box-shadow: var(--shadow);
}
.floating-pill {
  position: absolute;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  border-radius: 999px;
  background: var(--white);
  border: 1px solid var(--line);
  box-shadow: 0 12px 30px rgba(10, 10, 10, .12);
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}
.floating-pill-one { top: 8%; inset-inline-start: 0; }
.floating-pill-two { bottom: 16%; inset-inline-end: 0; }
.floating-pill-three { bottom: 0; inset-inline-start: 10%; }

.market-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-top: 48px;
}
.market-stats .stat {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 20px;
  text-align: center;
  box-shadow: 0 8px 24px rgba(10, 10, 10, .05);
}
.market-stats .stat strong { display: block; font-size: 25px; font-weight: 900; color: var(--jade-deep); }
.market-stats .stat span { font-size: 12.5px; font-weight: 600; color: var(--muted); }

/* Kind picker ----------------------------------------------------------- */
.kinds-section { padding-top: 60px; }
.kind-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.kind-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 20px 16px 18px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: transform .2s, box-shadow .25s, border-color .2s;
}
.kind-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: transparent; }
.kind-card strong { font-size: 15px; font-weight: 800; }
.kind-card > span:not(.kind-icon) { font-size: 12px; color: var(--muted); line-height: 1.4; }
.kind-card em {
  position: absolute;
  top: 12px;
  inset-inline-end: 12px;
  font-style: normal;
  font-size: 11px;
  font-weight: 800;
  color: var(--jade-deep);
  background: var(--light-jade);
  border-radius: 999px;
  padding: 3px 7px;
}
.kind-icon {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  font-size: 23px;
  background: var(--light-jade);
  border-radius: 14px;
  margin-bottom: 6px;
}
.kind-icon-sm { width: 44px; height: 44px; font-size: 21px; margin: 0; flex: none; }

/* Rail headings --------------------------------------------------------- */
.rail-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 26px;
}
.rail-head h2 { font-size: clamp(24px, 3vw, 32px); font-weight: 900; }
.rail-head p { color: var(--muted); font-size: 15px; margin: 8px 0 0; }
.rail-link { flex: none; font-weight: 800; font-size: 14px; color: var(--jade-deep); }
.rail-link:hover { text-decoration: underline; }

/* Product cards --------------------------------------------------------- */
.product-grid { display: grid; gap: 20px; }
.product-grid.grid-3, .store-grid.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.product-grid.grid-4, .store-grid.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.product-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform .2s, box-shadow .25s, border-color .2s;
}
.product-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: transparent; }
.product-media {
  position: relative;
  display: block;
  aspect-ratio: 4 / 3;
  background: #F1F3F2;
  overflow: hidden;
}
.product-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .35s;
}
.product-card:hover .product-media img { transform: scale(1.04); }
.product-media .badge-row { position: absolute; top: 10px; inset-inline-start: 10px; }
.product-body { display: flex; flex-direction: column; gap: 5px; padding: 13px 14px 15px; min-width: 0; }
.card-category { font-size: 11px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--jade-deep); }
.card-store { color: var(--muted); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.product-name {
  font-size: 15px;
  font-weight: 800;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.7em;
}
.product-price-row { display: flex; align-items: baseline; flex-wrap: wrap; gap: 7px; margin-top: 2px; }
.price { font-size: 16px; font-weight: 900; color: var(--ink); }
.price-old { font-size: 12px; color: var(--muted); text-decoration: line-through; }
.price-request { font-size: 13px; color: var(--jade-deep); }
.product-meta { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; min-height: 18px; font-size: 12px; }
.product-meta .card-store { flex: 1 1 auto; }

/* Store cards ----------------------------------------------------------- */
.store-grid { display: grid; gap: 20px; }
.store-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform .2s, box-shadow .25s, border-color .2s;
}
.store-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: transparent; }
.store-card-cover { display: block; aspect-ratio: 16 / 7; background: linear-gradient(135deg, #E7F7F1, #F5FAF8); overflow: hidden; }
.store-card-cover img { width: 100%; height: 100%; object-fit: cover; }
.store-card-body { position: relative; display: block; padding: 0 16px 16px; }
.store-card-logo {
  width: 58px;
  height: 58px;
  border-radius: 16px;
  object-fit: cover;
  border: 3px solid var(--white);
  background: var(--white);
  margin-top: -26px;
  box-shadow: 0 6px 16px rgba(10, 10, 10, .12);
}
.store-card-name { display: block; margin-top: 8px; font-size: 16px; font-weight: 900; }
.store-card-place { display: block; margin-top: 2px; font-size: 12.5px; color: var(--muted); }
.store-card-meta { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 6px; font-size: 12px; color: var(--muted); }

/* Category tiles -------------------------------------------------------- */
.category-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 16px; }
.category-grid-home { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.category-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform .2s, box-shadow .25s, border-color .2s;
}
.category-tile:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: transparent; }
.category-tile-media {
  display: block;
  height: 104px;
  background-color: #F1F3F2;
  background-position: center;
  background-size: cover;
}
.category-tile-fallback { display: grid; place-items: center; font-size: 32px; background: linear-gradient(135deg, #E7F7F1, #F7FBF9); }
.category-tile-body { display: flex; flex-direction: column; gap: 3px; padding: 11px 13px 13px; }
.category-tile-body strong { font-size: 13.5px; font-weight: 800; line-height: 1.3; }
.category-tile-note { font-size: 11.5px; color: var(--muted); }

/* App band -------------------------------------------------------------- */
.app-band { padding: 0 0 64px; }
.app-band-inner {
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 30px 34px;
  background: var(--ink);
  color: var(--white);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.app-band-icon { width: 74px; height: 74px; border-radius: 22px; flex: none; }
.app-band-inner h2 { font-size: clamp(22px, 2.7vw, 30px); font-weight: 900; }
.app-band-inner p { color: rgba(255, 255, 255, .68); margin: 7px 0 0; font-size: 14.5px; max-width: 560px; }
.app-band-actions { margin-inline-start: auto; display: flex; flex-direction: column; align-items: flex-end; gap: 8px; flex: none; }
.app-band-note { font-size: 11.5px; color: rgba(255, 255, 255, .6); }

/* Browse ---------------------------------------------------------------- */
.browse-layout { display: grid; grid-template-columns: 252px minmax(0, 1fr); gap: 28px; align-items: start; }
.filters {
  position: sticky;
  top: 88px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
}
.filter-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.filter-head h2 { font-size: 17px; font-weight: 900; }
.filter-head a { font-size: 12.5px; font-weight: 700; color: var(--muted); }
.filter-head a:hover { color: var(--ink); }
.filter-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 13px; }
.filter-field span { font-size: 12px; font-weight: 800; color: var(--muted); }
.filter-field select,
.filter-field input {
  width: 100%;
  font: inherit;
  font-size: 13.5px;
  color: var(--ink);
  background: #F7F9F8;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 9px 11px;
}
.filter-field select:focus,
.filter-field input:focus { outline: none; border-color: var(--jade); background: var(--white); }
.filter-prices { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.filter-check { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--ink-soft); margin: 0 0 10px; cursor: pointer; }
.filter-check input { accent-color: var(--jade); width: 16px; height: 16px; }
#browse-filters .btn { margin-top: 8px; }

.browse-results { min-width: 0; }
.results-toolbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.results-count { margin: 0; font-size: 14px; font-weight: 700; color: var(--muted); }
.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--light-jade);
  color: var(--jade-deep);
  font-size: 12.5px;
  font-weight: 800;
}
.filter-chip:hover { background: var(--jade); color: var(--ink); }
.sort-field { display: flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 700; color: var(--muted); }
.sort-field select {
  font: inherit;
  font-size: 13px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--white);
  color: var(--ink);
}

/* Pagination ------------------------------------------------------------ */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 38px;
}
.page-numbers { display: flex; flex-wrap: wrap; gap: 6px; }
.page-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  height: 38px;
  padding: 0 12px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--white);
  font-size: 13px;
  font-weight: 800;
  color: var(--ink);
}
.page-btn:hover { border-color: var(--jade); color: var(--jade-deep); }
.page-btn.current { background: var(--jade); border-color: var(--jade); color: var(--ink); }
.page-btn.disabled { color: #B9C0BE; background: #F7F9F8; pointer-events: none; }
.page-gap { display: inline-flex; align-items: center; padding: 0 4px; color: var(--muted); }
.page-of { flex-basis: 100%; text-align: center; font-size: 12px; color: var(--muted); }

/* Categories page ------------------------------------------------------- */
.category-group { padding: 30px 0; border-top: 1px solid var(--line); }
.category-group:first-of-type { border-top: 0; padding-top: 0; }
.category-group-head { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; }
.category-group-head h2 { font-size: 21px; font-weight: 900; }
.category-group-head p { margin: 3px 0 0; font-size: 13px; color: var(--muted); }
.category-group-head .count-pill { margin-inline-start: auto; }

/* Product detail -------------------------------------------------------- */
.product-detail {
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(0, .96fr);
  gap: 40px;
  margin-top: 22px;
  align-items: start;
}
.product-gallery { min-width: 0; }
.gallery-main {
  position: relative;
  aspect-ratio: 1 / 1;
  background: #F1F3F2;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.gallery-main img { width: 100%; height: 100%; object-fit: cover; }
.gallery-main .badge-row { position: absolute; top: 14px; inset-inline-start: 14px; }
.gallery-thumbs { display: flex; gap: 10px; overflow-x: auto; padding: 12px 2px 4px; }
.gallery-thumb {
  width: 76px;
  height: 76px;
  flex: none;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 12px;
  overflow: hidden;
  background: #F1F3F2;
  cursor: pointer;
}
.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; }
.gallery-thumb.active { border-color: var(--jade); }

.product-info { min-width: 0; padding-top: 6px; }
.product-info h1 { font-size: clamp(26px, 3.2vw, 38px); font-weight: 900; margin: 8px 0 0; }
.product-lede { color: var(--muted); font-size: 16px; margin: 12px 0 0; }
.price-block { display: flex; align-items: baseline; flex-wrap: wrap; gap: 10px; margin: 18px 0 10px; }
.price-block .price { font-size: 30px; font-weight: 900; }
.price-block .price-old { font-size: 15px; }
.product-info .product-meta { gap: 12px; color: var(--muted); margin-bottom: 18px; }
.stock { font-size: 12.5px; font-weight: 800; color: var(--jade-deep); background: var(--light-jade); border-radius: 999px; padding: 4px 10px; }
.stock.out { color: var(--clay); background: #FFE9E2; }

.buy-box {
  display: grid;
  gap: 9px;
  padding: 16px;
  background: #F7FAF9;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin: 6px 0 16px;
}
.buy-box .muted { margin: 2px 0 0; text-align: center; }
.btn-whatsapp { background: #25D366; color: #06331A; }
.btn-whatsapp:hover { background: #1FBE5B; color: #042312; }

.store-line {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: border-color .2s, box-shadow .2s;
}
.store-line:hover { border-color: var(--jade); box-shadow: 0 10px 24px rgba(0, 168, 120, .12); }
.store-line img { width: 42px; height: 42px; border-radius: 12px; object-fit: cover; flex: none; }
.store-line span { display: flex; flex-direction: column; min-width: 0; }
.store-line strong { font-size: 14px; }
.store-line em { font-style: normal; font-size: 12px; color: var(--muted); }
.store-line > span + span,
.store-line > span { margin-inline-end: auto; }
.store-line::after { content: "→"; color: var(--jade-deep); font-weight: 800; }
[dir="rtl"] .store-line::after { content: "←"; }

.product-lower {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(0, .75fr);
  gap: 34px;
  margin-top: 44px;
}
.product-copy, .product-side { min-width: 0; }
.copy-block {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 24px;
  margin-bottom: 18px;
}
.copy-block h2 { font-size: 20px; font-weight: 900; margin-bottom: 12px; }
.copy-block p { color: var(--muted); font-size: 15px; line-height: 1.7; margin: 0 0 12px; }
.copy-block p:last-child { margin-bottom: 0; }
.copy-block a { color: var(--jade-deep); font-weight: 700; }

.detail-list, .spec-list { margin: 0; display: grid; gap: 0; }
.detail-list > div, .spec-list > div {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 14px;
  padding: 10px 0;
  border-top: 1px solid var(--line);
  font-size: 14px;
}
.detail-list > div:first-child, .spec-list > div:first-child { border-top: 0; padding-top: 0; }
.detail-list dt, .spec-list dt { color: var(--muted); font-weight: 700; text-transform: capitalize; }
.detail-list dd, .spec-list dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }

.seller-card {
  display: flex;
  align-items: flex-start;
  gap: 13px;
  flex-wrap: wrap;
  padding: 18px;
  background: #F7FAF9;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin-bottom: 24px;
}
.seller-card::after {
  content: "";
  display: block;
  width: 100%;
  height: 1px;
  background: var(--line);
  margin: 12px 0;
}
.seller-logo { width: 54px; height: 54px; border-radius: 14px; object-fit: cover; flex: none; }
.seller-card h3 { font-size: 17px; font-weight: 900; margin: 3px 0 4px; }
.seller-card p { margin: 3px 0 0; font-size: 12.5px; }
.seller-card .btn { margin-inline-start: auto; width: auto; }
.seller-card > div { min-width: 0; }
.seller-card .eyebrow { margin-bottom: 0; font-size: 10px; padding: 4px 9px; }

.review-block { margin-top: 6px; }
.review-summary { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; }
.review-summary strong { font-size: 30px; font-weight: 900; }
.review-list { display: grid; gap: 14px; }
.review-item { border-top: 1px solid var(--line); padding-top: 14px; }
.review-item:first-child { border-top: 0; padding-top: 0; }
.review-item header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.review-item h3 { font-size: 15px; font-weight: 800; margin: 8px 0 4px; }
.review-item p { margin: 0 0 6px; }
.review-item .muted { font-size: 12px; }

/* Store detail ---------------------------------------------------------- */
.store-hero { position: relative; background: var(--white); }
.store-hero-cover {
  height: 220px;
  background: linear-gradient(135deg, #D9F4EB, #F4FAF8 60%, #FDF3E2);
  overflow: hidden;
}
.store-hero-cover img { width: 100%; height: 100%; object-fit: cover; }
.store-hero-inner {
  display: flex;
  align-items: flex-start;
  gap: 22px;
  padding-top: 0;
  padding-bottom: 8px;
}
.store-logo {
  width: 108px;
  height: 108px;
  border-radius: 24px;
  object-fit: cover;
  border: 5px solid var(--white);
  background: var(--white);
  box-shadow: 0 16px 34px rgba(10, 10, 10, .14);
  margin-top: -54px;
  flex: none;
}
.store-hero-copy { padding-top: 16px; min-width: 0; }
.store-hero-copy h1 { font-size: clamp(26px, 3.4vw, 38px); font-weight: 900; margin: 4px 0 8px; }
.store-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 14px; color: var(--muted); font-size: 13px; }
.store-description { color: var(--muted); font-size: 15px; margin: 12px 0 0; max-width: 680px; }
.store-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 16px; }

.section-block { margin-bottom: 36px; }
.section-block .rail-head { margin-bottom: 20px; }

/* Empty and error states ------------------------------------------------ */
.empty-state, .error-box {
  max-width: 560px;
  margin: 40px auto;
  padding: 42px 30px;
  text-align: center;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: 0 14px 40px rgba(10, 10, 10, .06);
}
.empty-icon, .error-icon { font-size: 44px; margin-bottom: 10px; }
.empty-state h1, .empty-state h3, .error-box h1 { font-size: clamp(22px, 3vw, 30px); font-weight: 900; }
.empty-state p, .error-box p { color: var(--muted); margin: 10px 0 20px; }
.empty-state .btn { margin: 0 4px; }

/* About additions ------------------------------------------------------- */
.about-more { margin: 26px 0 0; text-align: center; font-size: 15px; }
.about-hero .hero-copy { min-width: 0; }
.about-hero #about-features,
.about-hero [id] { scroll-margin-top: 90px; }
#about-features, #about-plans, #about-why, #about-download, #about-faq { scroll-margin-top: 86px; }

/* RTL tweaks ------------------------------------------------------------ */
[dir="rtl"] .rail-link,
[dir="rtl"] .text-link { unicode-bidi: plaintext; }
[dir="rtl"] .page-btn { font-family: var(--font); }

/* Responsive ------------------------------------------------------------ */
@media (max-width: 1080px) {
  .kind-grid { grid-template-columns: repeat(3, 1fr); }
  .category-grid-home { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 980px) {
  .header-search {
    flex: 1 1 auto;
    max-width: 240px;
    min-width: 0;
    order: 5;
  }
  .header-inner {
    flex-wrap: wrap;
    height: auto;
    min-width: 0;
    padding-top: 10px;
    padding-bottom: 10px;
    row-gap: 10px;
  }
  .brand,
  .header-actions { min-width: 0; }
  /* 16px keeps iOS Safari from zooming the page when the search field is
     focused, which is what made the mobile storefront feel wider than the
     screen. */
  .header-search input { font-size: 16px; }
  .nav { display: none; }
  .mobile-nav {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 8px 22px;
    border-top: 1px solid var(--line);
    scrollbar-width: none;
  }
  .mobile-nav::-webkit-scrollbar { display: none; }
  .mobile-nav a {
    flex: none;
    padding: 7px 13px;
    border-radius: 999px;
    background: #F1F3F2;
    font-size: 13px;
    font-weight: 700;
    color: var(--ink-soft);
    white-space: nowrap;
  }
  .mobile-nav a.active { background: var(--jade); color: var(--ink); }

  .market-hero-inner { grid-template-columns: 1fr; gap: 30px; }
  .market-hero-art { order: -1; min-height: 250px; }
  .market-hero-art .app-icon { width: min(190px, 52%); }
  .market-stats { grid-template-columns: repeat(2, 1fr); margin-top: 34px; }

  .product-grid.grid-4, .store-grid.grid-4 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .category-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }

  .product-detail { grid-template-columns: 1fr; gap: 26px; }
  .gallery-main { aspect-ratio: 4 / 3; }
  .product-lower { grid-template-columns: 1fr; gap: 18px; }
  .product-side { order: -1; }
}

@media (max-width: 820px) {
  .browse-layout { grid-template-columns: 1fr; }
  .filters { position: static; }
  .filter-prices { grid-template-columns: 1fr 1fr; }
  .app-band-inner { flex-wrap: wrap; padding: 26px; }
  .app-band-actions { margin-inline-start: 0; align-items: flex-start; }
  .category-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .category-grid-home { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 640px) {
  /* 16px keeps iOS Safari from zooming the page when the search field is
     focused, which is what made the mobile storefront feel wider than the
     screen. */
  .header-search input { font-size: 16px; }
  .header-search { margin-inline: 0; }
  .product-grid.grid-3, .product-grid.grid-4,
  .store-grid.grid-3, .store-grid.grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .product-grid { gap: 13px; }
  .store-grid { gap: 14px; }
  .product-body { padding: 10px 11px 12px; }
  .product-name { font-size: 14px; }
  .kind-grid { grid-template-columns: repeat(2, 1fr); }
  .category-grid, .category-grid-home { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .category-tile-media { height: 84px; }
  .market-hero { padding: 40px 0 30px; }
  .market-hero-copy h1 { font-size: clamp(30px, 8vw, 40px); }
  .hero-search { flex-direction: column; border-radius: var(--radius); padding: 8px; }
  .hero-search .btn { width: 100%; }
  .floating-pill { font-size: 11.5px; padding: 7px 10px; }
  .app-band-icon { width: 58px; height: 58px; border-radius: 17px; }
  .store-hero-cover { height: 150px; }
  .store-hero-inner { gap: 14px; }
  .store-logo { width: 82px; height: 82px; border-radius: 20px; margin-top: -42px; }
  .store-hero-copy { padding-top: 10px; }
  .detail-list > div, .spec-list > div { grid-template-columns: 1fr; gap: 2px; }
  .copy-block { padding: 18px; }
  .seller-card .btn { margin-inline-start: 0; width: 100%; }
  .empty-state, .error-box { padding: 30px 20px; }
}

@media (max-width: 480px) {
  .store-grid { grid-template-columns: 1fr; }
  .market-stats .stat strong { font-size: 21px; }
  .app-cta { display: none; }
  .header-inner { gap: 10px; }
  .header-actions { gap: 8px; }
  .lang-switch { flex: none; }
  .page-block { padding-top: 22px; padding-bottom: 54px; }
}

/* Product-first home feed ------------------------------------------------ */
/*
 * The storefront opens with a compact promotional slider, then the category
 * rail and product rails. The slider is a merchandising strip, not a large
 * editorial hero, so products still appear inside the first viewport.
 */
.home-feed { background: var(--white); }

/* Top showcase slider ----------------------------------------------------- */
.home-showcase {
  position: relative;
  padding: 24px 0 26px;
  overflow: hidden;
  border-bottom: 1px solid rgba(0, 120, 90, .08);
  background:
    radial-gradient(900px 320px at 8% 0%, rgba(0, 168, 120, .12), transparent 62%),
    radial-gradient(720px 280px at 100% 10%, rgba(232, 163, 61, .12), transparent 62%),
    linear-gradient(180deg, #F6FBF9 0%, #FFFFFF 100%);
}
.home-showcase::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: radial-gradient(rgba(0, 120, 90, .12) 1px, transparent 1px);
  background-size: 22px 22px;
  -webkit-mask-image: linear-gradient(180deg, rgba(0, 0, 0, .3), transparent 72%);
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, .3), transparent 72%);
}
.home-showcase-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 18px;
}

.home-slider {
  position: relative;
  min-width: 0;
  height: 338px;
  overflow: hidden;
  border-radius: 26px;
  background: #071C15;
  box-shadow: 0 24px 60px rgba(6, 48, 36, .18), inset 0 0 0 1px rgba(255, 255, 255, .08);
  isolation: isolate;
}
.home-slider-track { position: absolute; inset: 0; }
.home-slider-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.035);
  pointer-events: none;
  transition: opacity .65s ease, transform .9s cubic-bezier(.2, .7, .2, 1);
}
.home-slider-slide.is-active {
  z-index: 2;
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
}
.home-slide-link { position: absolute; inset: 0; display: block; color: var(--white); }
.home-slide-media { position: absolute; inset: 0; display: block; }
.home-slide-media img { width: 100%; height: 100%; object-fit: cover; }
.home-slide-media-fallback {
  background:
    radial-gradient(420px 220px at 72% 26%, rgba(0, 168, 120, .42), transparent 65%),
    radial-gradient(380px 220px at 88% 90%, rgba(232, 163, 61, .25), transparent 60%),
    linear-gradient(135deg, #052F24 0%, #063F30 45%, #00785A 100%);
}
.home-slide-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(3, 22, 16, .88) 0%, rgba(3, 22, 16, .56) 42%, rgba(3, 22, 16, .1) 68%, rgba(3, 22, 16, .18) 100%),
    linear-gradient(0deg, rgba(3, 22, 16, .5), transparent 46%);
}
[dir="rtl"] .home-slide-shade {
  background:
    linear-gradient(270deg, rgba(3, 22, 16, .88) 0%, rgba(3, 22, 16, .56) 42%, rgba(3, 22, 16, .1) 68%, rgba(3, 22, 16, .18) 100%),
    linear-gradient(0deg, rgba(3, 22, 16, .5), transparent 46%);
}
.home-slide-copy {
  position: absolute;
  inset-inline-start: clamp(22px, 4vw, 46px);
  bottom: clamp(24px, 4vw, 42px);
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 9px;
  max-width: min(72%, 490px);
}
.home-slide-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 11px;
  border: 1px solid rgba(255, 255, 255, .22);
  border-radius: 999px;
  background: rgba(255, 255, 255, .14);
  color: rgba(255, 255, 255, .92);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .1em;
  line-height: 1.2;
  text-transform: uppercase;
  backdrop-filter: blur(10px);
}
.home-slide-eyebrow i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--jade);
  box-shadow: 0 0 0 0 rgba(0, 168, 120, .35);
  animation: homePulse 2s infinite;
}
@keyframes homePulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(0, 168, 120, .35); }
  50% { box-shadow: 0 0 0 5px rgba(0, 168, 120, 0); }
}
.home-slide-title {
  display: -webkit-box;
  overflow: hidden;
  color: var(--white);
  font-size: clamp(25px, 3.4vw, 43px);
  font-weight: 900;
  line-height: 1.03;
  letter-spacing: -.03em;
  text-wrap: balance;
  text-shadow: 0 3px 26px rgba(0, 0, 0, .3);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}
.home-slide-subtitle {
  display: -webkit-box;
  overflow: hidden;
  max-width: 400px;
  color: rgba(255, 255, 255, .8);
  font-size: clamp(13px, 1.4vw, 16px);
  line-height: 1.45;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}
.home-slide-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 7px;
  padding: 10px 18px;
  border-radius: 999px;
  background: var(--jade);
  color: #042018;
  font-size: 12.5px;
  font-weight: 900;
  box-shadow: 0 12px 28px rgba(0, 168, 120, .38);
  transition: transform .2s, background .2s;
}
.home-slide-cta::after { content: "→"; font-size: 15px; transition: transform .2s; }
[dir="rtl"] .home-slide-cta::after { content: "←"; }
.home-slide-link:hover .home-slide-cta { background: var(--white); transform: translateY(-1px); }
.home-slide-link:hover .home-slide-cta::after { transform: translateX(3px); }
[dir="rtl"] .home-slide-link:hover .home-slide-cta::after { transform: translateX(-3px); }
.home-slide-count {
  position: absolute;
  inset-inline-end: 22px;
  bottom: 20px;
  z-index: 2;
  color: rgba(255, 255, 255, .55);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .14em;
}
.home-slider-arrow {
  position: absolute;
  top: 50%;
  z-index: 4;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, .3);
  border-radius: 50%;
  background: rgba(5, 30, 23, .28);
  color: var(--white);
  cursor: pointer;
  transform: translateY(-50%);
  backdrop-filter: blur(12px);
  transition: background .2s, transform .2s;
}
.home-slider-arrow:hover { background: rgba(255, 255, 255, .22); transform: translateY(-50%) scale(1.05); }
.home-slider-arrow.prev { inset-inline-start: 16px; }
.home-slider-arrow.next { inset-inline-end: 16px; }
.home-slider-arrow svg { width: 20px; height: 20px; }
[dir="rtl"] .home-slider-arrow svg { transform: scaleX(-1); }
.home-slider-dots {
  position: absolute;
  inset-inline-start: clamp(22px, 4vw, 46px);
  bottom: 20px;
  z-index: 4;
  display: flex;
  align-items: center;
  gap: 6px;
}
.home-slider-dot {
  width: 7px;
  height: 7px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, .35);
  cursor: pointer;
  transition: width .25s, background .25s;
}
.home-slider-dot.is-active { width: 24px; background: var(--jade); }

.home-side {
  display: grid;
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: 18px;
  min-width: 0;
}
.home-side-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
  overflow: hidden;
  padding: 18px 18px 16px;
  border-radius: 22px;
  transition: transform .2s, box-shadow .25s;
}
.home-side-card:hover { transform: translateY(-3px); box-shadow: 0 18px 38px rgba(6, 48, 36, .14); }
.home-side-card::after {
  content: "";
  position: absolute;
  inset-inline-end: -60px;
  bottom: -70px;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .13);
}
.home-side-deals {
  background: linear-gradient(140deg, #05372A 0%, #00785A 55%, #00A878 100%);
  color: var(--white);
}
.home-side-stores {
  border: 1px solid rgba(232, 163, 61, .25);
  background: linear-gradient(140deg, #FFF9EF 0%, #FFE9C8 100%);
  color: #2B1A04;
}
.home-side-icon {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid rgba(255, 255, 255, .18);
  border-radius: 13px;
  background: rgba(255, 255, 255, .16);
  font-size: 20px;
}
.home-side-stores .home-side-icon { border-color: rgba(232, 163, 61, .22); background: var(--white); }
.home-side-copy {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}
.home-side-copy strong { font-size: 18px; font-weight: 900; letter-spacing: -.01em; line-height: 1.2; }
.home-side-copy span {
  display: -webkit-box;
  overflow: hidden;
  color: rgba(255, 255, 255, .72);
  font-size: 12px;
  line-height: 1.4;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}
.home-side-stores .home-side-copy span { color: rgba(43, 26, 4, .64); }
.home-side-copy em {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 7px;
  color: var(--jade);
  font-size: 11.5px;
  font-style: normal;
  font-weight: 900;
}
.home-side-copy em::after { content: "→"; font-size: 14px; }
[dir="rtl"] .home-side-copy em::after { content: "←"; }
.home-side-stores .home-side-copy em { color: #9A5B06; }

.home-section .rail-head h2 { position: relative; padding-inline-start: 15px; }
.home-section .rail-head h2::before {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  top: .16em;
  width: 5px;
  height: .92em;
  border-radius: 99px;
  background: linear-gradient(180deg, var(--jade), #6FE0BC);
  box-shadow: 0 0 16px rgba(0, 168, 120, .4);
}
.home-section .rail-link { transition: background .2s, color .2s, transform .2s; }
.home-section .rail-link:hover { transform: translateY(-1px); }
.home-grid .product-card:hover { box-shadow: 0 20px 40px rgba(6, 48, 36, .14); }
.home-grid .product-media::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, transparent 55%, rgba(4, 32, 24, .07));
  opacity: 0;
  transition: opacity .25s;
}
.home-grid .product-card:hover .product-media::after { opacity: 1; }

@media (prefers-reduced-motion: reduce) {
  .home-slider-slide,
  .home-slide-cta,
  .home-slide-cta::after,
  .home-slider-dot,
  .home-side-card,
  .home-grid .product-card,
  .home-grid .product-media img,
  .home-grid .product-media::after { transition: none; }
  .home-slide-eyebrow i { animation: none; }
  .page-loader-mark { opacity: 1; animation: none; }
  .page-loader-mark::before { animation: none; border-color: rgba(0, 168, 120, .35); }
}

@media (min-width: 1081px) and (max-height: 840px) {
  .home-showcase { padding: 18px 0 20px; }
  .home-showcase-inner { grid-template-columns: minmax(0, 1fr); }
  .home-side { display: none; }
  .home-slider { height: 270px; }
}
@media (min-width: 1081px) and (max-height: 740px) {
  .home-slider { height: 244px; }
}
@media (max-width: 1080px) {
  .home-showcase-inner { grid-template-columns: minmax(0, 1fr); }
  .home-side { display: none; }
  .home-slider { height: 310px; }
}
@media (max-width: 1080px) and (max-height: 820px) {
  .home-slider { height: 276px; }
}
@media (max-width: 860px) {
  .home-slider { height: 280px; }
  .home-slide-title { font-size: clamp(24px, 5vw, 34px); }
}
@media (max-width: 640px) {
  .home-showcase { padding: 12px 0 16px; }
  .home-slider { height: 222px; border-radius: 20px; }
  .home-slider-arrow { display: none; }
  .home-slide-copy {
    inset-inline-start: 20px;
    bottom: 34px;
    gap: 7px;
    max-width: calc(100% - 40px);
  }
  .home-slide-eyebrow { padding: 5px 9px; font-size: 9.5px; }
  .home-slide-title { font-size: clamp(22px, 7vw, 30px); }
  .home-slide-subtitle { font-size: 12.5px; }
  .home-slide-cta { margin-top: 4px; padding: 8px 14px; font-size: 11.5px; }
  .home-slide-count { display: none; }
  .home-slider-dots { inset-inline-start: 20px; bottom: 12px; }
}
@media (max-width: 480px) {
  .home-slider { height: 204px; }
  .home-slide-subtitle { display: none; }
}

.home-cats {
  padding: 18px 0 16px;
  background: #FBFCFC;
  border-bottom: 1px solid var(--line);
}
.home-cats-inner { min-width: 0; }
.home-cats-scroll {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scrollbar-width: none;
  padding: 2px 0 4px;
}
.home-cats-scroll::-webkit-scrollbar { display: none; }

.home-cat {
  flex: 0 0 80px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  padding: 7px 4px;
  border-radius: 14px;
  color: var(--ink);
  transition: background .2s, transform .2s;
}
.home-cat:hover { background: var(--white); transform: translateY(-2px); }
.home-cat-media {
  position: relative;
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  overflow: hidden;
  border: 1px solid rgba(0, 168, 120, .12);
  border-radius: 18px;
  background: linear-gradient(135deg, #E7F7F1, #F8FBF9);
  color: var(--jade-deep);
  font-size: 25px;
}
.home-cat-media img {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.home-cat-fallback { display: grid; place-items: center; width: 100%; height: 100%; }
.home-cat-media-empty { background: linear-gradient(135deg, #E7F7F1, #F8FBF9); }
.home-cat-media-all { background: var(--ink); border-color: var(--ink); color: var(--white); }
.home-cat-media-deal { background: linear-gradient(135deg, #FFE9E2, #FFF7F3); border-color: #FFD9CE; color: var(--clay); }
.home-cat-media-more { background: var(--light-jade); border-color: #C9EEE1; color: var(--jade-deep); }
.home-cat-name {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.45em;
  font-size: 11.5px;
  font-weight: 700;
  line-height: 1.22;
  text-align: center;
}

.home-section {
  padding: 30px 0 34px;
  border-top: 1px solid var(--line);
}
.home-cats + .home-section { border-top: 0; }
.home-section .rail-head {
  align-items: center;
  margin-bottom: 18px;
}
.home-section .rail-head h2 { font-size: clamp(20px, 2.4vw, 27px); font-weight: 900; }
.home-section .rail-link {
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--light-jade);
  color: var(--jade-deep);
  font-size: 12.5px;
  font-weight: 800;
  white-space: nowrap;
}
.home-section .rail-link:hover { background: var(--jade); color: var(--ink); text-decoration: none; }

.product-grid.grid-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.home-grid { gap: 16px; }
.home-grid .product-card { border-radius: 14px; }
.home-grid .product-media { aspect-ratio: 1 / 1; }
.home-grid .product-body { gap: 4px; padding: 11px 12px 13px; }
.home-grid .card-category { display: none; }
.home-grid .product-name { min-height: 2.7em; font-size: 13.5px; }
.home-grid .product-price-row { margin-top: 1px; }
.home-grid .price { font-size: 15px; }
.home-grid .price-old { font-size: 11px; }
.home-grid .product-meta { min-height: 0; font-size: 11.5px; }
.home-grid .card-store { font-size: 11.5px; }
.home-grid .badge { padding: 4px 8px; font-size: 10.5px; }

.home-feed .app-band {
  padding: 34px 0 54px;
  border-top: 1px solid var(--line);
}

@media (max-width: 1080px) {
  .product-grid.grid-5 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
  .product-grid.grid-5 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .home-cats { padding: 13px 0 11px; }
  .home-cats-scroll { gap: 4px; }
  .home-cat { flex-basis: 72px; padding: 6px 3px; }
  .home-cat-media { width: 54px; height: 54px; border-radius: 16px; font-size: 23px; }
  .home-cat-name { min-height: 2.4em; font-size: 11px; }
  .home-section { padding: 24px 0 28px; }
  .home-section .rail-head { margin-bottom: 14px; }
  .home-section .rail-head h2 { font-size: 20px; }
  .home-section .rail-link { padding: 7px 11px; font-size: 11.5px; }
  .product-grid.grid-5 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .home-grid .product-body { padding: 10px 10px 12px; }
  .home-grid .product-name { font-size: 13px; }
  .home-grid .price { font-size: 14px; }
  .home-feed .app-band { padding: 26px 0 40px; }
}
