:root {
  --bg: #faf8f4;
  --card: #ffffff;
  --surface: #f3f0e8;
  --ink: #0f172a;
  --ink-soft: #334155;
  --muted: #64748b;
  --line: #e2e8f0;
  --line-soft: #f1f5f9;
  --accent: #f97316;
  --accent-soft: #fff7ed;
  --accent-tint: rgba(249,115,22,0.08);
  --accent-ring: rgba(249,115,22,0.22);
  --wa: #25d366;
  --wa-glow: rgba(37,211,102,0.28);

  --radius-sm: 10px;
  --radius-md: 18px;
  --radius-lg: 24px;
  --radius-xl: 32px;

  --shadow-sm: 0 1px 2px rgba(15,23,42,0.05);
  --shadow-md: 0 10px 28px rgba(15,23,42,0.08);
  --shadow-accent: 0 8px 20px -6px var(--accent-ring);
  --shadow-wa: 0 12px 26px -6px var(--wa-glow);

  --ease: cubic-bezier(.4,0,.2,1);
  --dur: 180ms;

  --font-body: "Assistant", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-display: "Plus Jakarta Sans", "Assistant", system-ui, sans-serif;

  --dot-grid: radial-gradient(#e2e8f0 1px, transparent 1px);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { background: var(--bg); }
body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  background: var(--bg);
  color: var(--ink-soft);
  direction: rtl;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button { font-family: inherit; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 6px;
}

/* ---------- Header ---------- */
.site-header {
  background: #fff;
  border-bottom: 1px solid var(--line);
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  position: sticky;
  top: 0;
  z-index: 40;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 800;
  font-size: 18px;
  letter-spacing: -0.02em;
}
.brand-mark {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: var(--ink);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.brand-mark svg { width: 18px; height: 18px; }
.brand-text { line-height: 1; }
.brand-accent { color: var(--accent); }

/* ---------- Layout ---------- */
.site-main {
  padding: 16px 20px;
  max-width: 1080px;
  margin: 0 auto;
}

.site-footer {
  padding: 40px 16px 32px;
  text-align: center;
  border-top: 1px solid var(--line);
  margin-top: 48px;
}
.site-footer a {
  color: var(--muted);
  font-weight: 500;
  transition: color var(--dur) var(--ease);
}
.site-footer a:hover { color: var(--accent); }

/* ---------- Tagline (eyebrow caption) ---------- */
.tagline {
  text-align: center;
  color: rgba(15,23,42,0.55);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  margin: 20px 0 24px;
}

/* ---------- Category chips ---------- */
.category-chips {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 14px;
  margin-bottom: 20px;
  scrollbar-width: none;
}
.category-chips::-webkit-scrollbar { display: none; }

.chip {
  padding: 9px 18px;
  border-radius: 999px;
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
  flex-shrink: 0;
  transition: border-color var(--dur) var(--ease),
              background var(--dur) var(--ease),
              color var(--dur) var(--ease),
              box-shadow var(--dur) var(--ease);
}
.chip:hover { border-color: var(--accent); }
.chip-active {
  background: var(--accent);
  color: #fff;
  border-color: transparent;
  box-shadow: var(--shadow-accent);
}

/* ---------- Page title ---------- */
.page-title {
  font-family: var(--font-display);
  font-size: clamp(26px, 6vw, 34px);
  color: var(--ink);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 12px 0 20px;
}

/* ---------- Product grid ---------- */
.product-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.product-card {
  background: var(--card);
  border-radius: var(--radius-lg);
  padding: 8px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--line-soft);
  overflow: hidden;
  transition: transform var(--dur) var(--ease),
              box-shadow var(--dur) var(--ease);
}
.product-card > a { display: block; }
.product-card:active { transform: scale(0.98); }

@media (hover: hover) {
  .product-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
  }
  .product-card:hover .product-image img { transform: scale(1.05); }
}

.product-image {
  aspect-ratio: 1;
  background-color: var(--surface);
  background-image: var(--dot-grid);
  background-size: 16px 16px;
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 10px;
}
.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 500ms var(--ease);
}

/* Striped placeholder for empty product images */
.placeholder {
  width: 100%;
  height: 100%;
  background-color: var(--surface);
  background-image: var(--dot-grid);
  background-size: 20px 20px;
}

.product-name {
  font-size: 14px;
  color: var(--ink);
  font-weight: 700;
  margin: 4px 6px 2px;
  line-height: 1.35;
}
.product-price {
  font-family: var(--font-display);
  font-size: 18px;
  color: var(--accent);
  font-weight: 800;
  margin: 0 6px 6px;
  letter-spacing: -0.01em;
}

.empty {
  grid-column: 1 / -1;
  text-align: center;
  color: var(--muted);
  padding: 48px 16px;
  font-size: 15px;
  list-style: none;
}

/* ---------- Product detail ---------- */
.product-detail { margin: 0; padding-bottom: 120px; }

.carousel {
  margin-inline: calc(50% - 50vw);
  width: 100vw;
}
.carousel-viewport {
  position: relative;
  background-color: var(--surface);
  background-image: var(--dot-grid);
  background-size: 20px 20px;
  aspect-ratio: 1;
  overflow: hidden;
}
.slide { display: none; width: 100%; height: 100%; }
.slide.active { display: block; }
.slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  padding: 16px 0 4px;
}
.dot {
  width: 8px;
  height: 8px;
  padding: 0;
  border: none;
  border-radius: 999px;
  background: rgba(15,23,42,0.25);
  cursor: pointer;
  transition: width var(--dur) var(--ease),
              background var(--dur) var(--ease);
}
.dot:hover { background: rgba(15,23,42,0.5); }
.dot.active {
  width: 24px;
  background: var(--accent);
}

.carousel-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 42px;
  height: 42px;
  border-radius: 999px;
  border: none;
  background: #fff;
  color: var(--ink);
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 24px -6px rgba(15,23,42,0.18);
  z-index: 3;
  transition: transform var(--dur) var(--ease),
              background var(--dur) var(--ease);
}
.carousel-nav:hover { background: var(--accent-soft); color: var(--accent); transform: translateY(-50%) scale(1.08); }
.carousel-nav:active { transform: translateY(-50%) scale(0.94); }
.carousel-prev { left: 14px; }
.carousel-next { right: 14px; }
@media (hover: none) {
  .carousel-nav { display: none; }
}

.detail-body {
  padding: 28px 20px 24px;
  max-width: 720px;
  margin: 0 auto;
}
.category-tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  color: var(--accent);
  background: var(--accent-tint);
  border: 1px solid var(--accent-ring);
  padding: 5px 12px;
  border-radius: 999px;
  margin-bottom: 14px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: background var(--dur) var(--ease);
}
.category-tag:hover { background: var(--accent-soft); }
.detail-name {
  font-family: var(--font-display);
  font-size: clamp(26px, 6vw, 36px);
  font-weight: 800;
  color: var(--ink);
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 8px 0 10px;
}
.detail-price {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 800;
  color: var(--accent);
  margin: 0 0 24px;
  letter-spacing: -0.01em;
}
.detail-description {
  font-size: 16px;
  line-height: 1.75;
  color: var(--ink-soft);
  max-width: 60ch;
}

/* ---------- Sticky WhatsApp CTA ---------- */
.whatsapp-sticky {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 12px 16px 20px;
  background: linear-gradient(to top, var(--bg) 65%, rgba(250,248,244,0) 100%);
  display: flex;
  justify-content: center;
  z-index: 30;
  pointer-events: none;
}
.whatsapp-sticky__btn {
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  max-width: 460px;
  background: var(--wa);
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  padding: 16px 20px;
  border-radius: 18px;
  box-shadow: var(--shadow-wa);
  transition: filter var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.whatsapp-sticky__btn:hover { filter: brightness(1.06); }
.whatsapp-sticky__btn:active { transform: scale(0.97); }
.whatsapp-sticky__btn svg { width: 22px; height: 22px; flex-shrink: 0; }

/* ---------- About ---------- */
.about-text {
  max-width: 60ch;
  margin: 0 auto;
  line-height: 1.75;
  font-size: 16px;
  color: var(--ink-soft);
}

/* ---------- Responsive ---------- */
@media (min-width: 600px) {
  .product-grid { grid-template-columns: repeat(3, 1fr); gap: 18px; }
  .site-main { padding: 20px 24px; }
}
@media (min-width: 720px) {
  .carousel {
    margin-inline: auto;
    width: 100%;
    max-width: 720px;
  }
  .carousel-viewport {
    border-radius: var(--radius-xl);
  }
  .whatsapp-sticky {
    padding: 16px;
    background: transparent;
  }
  .whatsapp-sticky__btn {
    max-width: 440px;
    margin-bottom: 8px;
  }
}
@media (min-width: 900px) {
  .product-grid { grid-template-columns: repeat(4, 1fr); gap: 20px; }
  .site-main { padding: 24px 32px; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
  .product-card:hover { transform: none; }
  .product-card:hover .product-image img { transform: none; }
}
