/* Vegeterija – javni meni */
:root {
  --bg: #f3f6ee;          /* svetla, blago zelena podloga */
  --surface: #ffffff;
  --ink: #15241b;
  --ink-soft: #4d5e53;
  --line: #d9e0d3;
  --hero: #000000;        /* crna iz logoa */
  --hero-ink: #f4f7ef;
  --hero-soft: #b8c98f;   /* svetlozelena slova iz logoa */
  --brand: #0f7a40;       /* zeleni prsten, tamniji za čitljiv tekst */
  --brand-ink: #ffffff;
  --ring: #19a65a;
  --carrot: #f07d1a;      /* šargarepa */
  --carrot-ink: #1d1206;
  --placeholder: #e4ecdc;
  --alert: #b3470b;
  --matcha: #4f7a1f;
  --millet: #9a6a06;
  --sky: #2f6a8a;
  --shadow: 0 10px 30px -18px rgba(21, 36, 27, .45);
  --display: "Bricolage Grotesque", ui-sans-serif, system-ui, sans-serif;
  --text: "Instrument Sans", ui-sans-serif, system-ui, sans-serif;
  --gutter: 16px;
  --max: 720px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0c110e;
    --surface: #151d18;
    --ink: #e7eee5;
    --ink-soft: #a3b3a8;
    --line: #25322a;
    --brand: #1f9a55;
    --brand-ink: #ffffff;
    --placeholder: #1d2a22;
    --alert: #ffa463;
    --matcha: #a3c46a;
    --millet: #e3b553;
    --sky: #7fb8d6;
    --shadow: 0 10px 30px -18px rgba(0, 0, 0, .8);
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 132px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.5 var(--text);
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }
button { font: inherit; color: inherit; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 3px solid var(--sky); outline-offset: 2px; border-radius: 6px; }

/* ---------- Zaglavlje ---------- */
.hero {
  background: var(--hero);
  color: var(--hero-ink);
  padding: calc(28px + env(safe-area-inset-top)) var(--gutter) 26px;
}
.hero-inner {
  max-width: var(--max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 18px;
}
.logo {
  width: clamp(96px, 28vw, 132px);
  height: auto;
  aspect-ratio: 1;
  border-radius: 50%;
  box-shadow: 0 0 0 1px rgba(25, 166, 90, .35), 0 0 36px -6px rgba(25, 166, 90, .55);
}
.hero h1 {
  font: 800 clamp(34px, 10vw, 60px)/.95 var(--display);
  font-variation-settings: "opsz" 96;
  letter-spacing: -.03em;
  margin: 0;
}
.tagline {
  font: 500 17px/1.3 var(--display);
  color: var(--hero-soft);
  margin: 8px 0 0;
}
.status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 14px 0 0;
  font-size: 14px;
  font-weight: 600;
  padding: 6px 12px 6px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .1);
}
.status::before {
  content: "";
  width: 8px; height: 8px; border-radius: 50%;
  background: #f0a060;
}
.status.open::before { background: #3ad07a; box-shadow: 0 0 0 4px rgba(58, 208, 122, .25); }

/* ---------- Traka sa pretragom i kategorijama ---------- */
.toolbar {
  position: sticky;
  top: 0;
  z-index: 10;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line);
}
.search-row {
  max-width: var(--max);
  margin: 0 auto;
  display: flex;
  gap: 8px;
  padding: 10px var(--gutter) 6px;
}
.search {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0 12px;
}
.search svg { width: 18px; height: 18px; flex: none; fill: none; stroke: var(--ink-soft); stroke-width: 2; stroke-linecap: round; }
.search input {
  flex: 1; min-width: 0;
  border: 0; background: transparent; color: var(--ink);
  font: inherit; font-size: 16px;
  padding: 10px 0;
  outline: none;
}
.search:focus-within { border-color: var(--ink-soft); }
.filter {
  flex: none;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 12px;
  padding: 0 12px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}
.filter[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }

.cats {
  max-width: var(--max);
  margin: 0 auto;
  display: flex;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
  padding: 2px var(--gutter) 8px;
}
.cats::-webkit-scrollbar { display: none; }
.cats a {
  flex: none;
  text-decoration: none;
  color: var(--ink-soft);
  font-weight: 600;
  font-size: 15px;
  padding: 7px 12px;
  border-radius: 10px;
  white-space: nowrap;
}
.cats a.active { color: var(--brand-ink); background: var(--brand); }

/* ---------- Meni ---------- */
main {
  max-width: var(--max);
  margin: 0 auto;
  padding: 8px var(--gutter) 40px;
  min-height: 50vh;
}
.loading, .empty { color: var(--ink-soft); padding: 40px 0; text-align: center; }

.popular { margin: 18px 0 8px; }
.popular h2, .section h2 {
  font: 700 26px/1.15 var(--display);
  letter-spacing: -.015em;
  margin: 0 0 4px;
}
.popular-row {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: var(--gutter);
  margin: 12px calc(-1 * var(--gutter)) 0;
  padding: 0 var(--gutter) 10px;
  scrollbar-width: none;
}
.popular-row::-webkit-scrollbar { display: none; }
.pop {
  flex: none;
  width: 156px;
  scroll-snap-align: start;
  text-align: left;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}
.pop img, .pop .ph {
  width: 156px; height: 156px;
  border-radius: 20px;
  object-fit: cover;
  background: var(--placeholder);
  box-shadow: var(--shadow);
}
.pop strong { display: block; font: 650 15px/1.25 var(--display); margin-top: 10px; }
.pop span { display: block; font-size: 14px; color: var(--ink-soft); margin-top: 2px; font-variant-numeric: tabular-nums; }

.section { padding-top: 26px; }
.section-desc { color: var(--ink-soft); margin: 0; font-size: 15px; }
.list { list-style: none; margin: 10px 0 0; padding: 0; }
.list li + li { border-top: 1px solid var(--line); }

.item {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 14px;
  align-items: start;
  text-align: left;
  background: none;
  border: 0;
  padding: 16px 0;
  cursor: pointer;
}
.item-name {
  display: block;
  font: 650 18px/1.25 var(--display);
  letter-spacing: -.01em;
}
.item-desc {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  color: var(--ink-soft);
  font-size: 14.5px;
  line-height: 1.45;
  margin-top: 4px;
}
.item-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  margin-top: 8px;
}
.price {
  font: 700 17px/1 var(--display);
  font-variant-numeric: tabular-nums;
  color: var(--ink);
  margin-right: 4px;
}
.price small { font-size: 12px; font-weight: 600; color: var(--ink-soft); margin-left: 2px; }
.weight { font-size: 13.5px; color: var(--ink-soft); }
.thumb {
  width: 92px; height: 92px;
  border-radius: 16px;
  object-fit: cover;
  background: var(--placeholder);
}

.tags { display: inline-flex; gap: 4px; }
.tag {
  font-size: 11.5px;
  font-weight: 700;
  line-height: 1;
  padding: 4px 6px;
  border-radius: 6px;
  border: 1px solid currentColor;
}
.tag-V { color: var(--matcha); }
.tag-VG { color: var(--millet); }
.tag-GF { color: var(--sky); }
.badge-new {
  font-size: 12px; font-weight: 700; line-height: 1;
  padding: 4px 8px; border-radius: 999px;
  background: var(--carrot); color: var(--carrot-ink);
}
.soldout { font-size: 13px; font-weight: 600; color: var(--alert); }
.item.is-out .item-name, .item.is-out .price { opacity: .5; }
.item.is-out .thumb { filter: grayscale(1); opacity: .5; }

mark { background: color-mix(in srgb, var(--millet) 30%, transparent); color: inherit; border-radius: 3px; }

/* ---------- Detalji (donji list) ---------- */
.sheet {
  border: 0;
  padding: 0;
  width: min(560px, 100%);
  max-width: 100%;
  max-height: 92dvh;
  margin: auto auto 0;
  border-radius: 24px 24px 0 0;
  background: var(--surface);
  color: var(--ink);
  overflow: auto;
}
@media (min-width: 640px) { .sheet { margin: auto; border-radius: 24px; } }
.sheet::backdrop { background: rgba(10, 20, 16, .55); }
.sheet[open] { animation: rise .28s cubic-bezier(.2, .8, .2, 1); }
@keyframes rise { from { transform: translateY(40px); opacity: 0; } }
.sheet img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; background: var(--placeholder); }
.sheet img[hidden] { display: none; }
.sheet-body { padding: 20px 20px calc(24px + env(safe-area-inset-bottom)); }
.sheet h2 { font: 700 26px/1.15 var(--display); letter-spacing: -.015em; margin: 0; }
.sheet p { margin: 10px 0 0; color: var(--ink-soft); }
.sheet-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; font-size: 14px; }
.sheet-meta .tag { font-size: 13px; padding: 5px 8px; }
.sheet-price { font: 700 24px/1 var(--display) !important; color: var(--ink) !important; margin-top: 18px !important; }
.close {
  position: absolute; top: 12px; right: 12px;
  width: 38px; height: 38px; border-radius: 50%;
  border: 0; background: rgba(255, 255, 255, .92); color: #16302b;
  font-size: 16px; cursor: pointer; box-shadow: var(--shadow);
}

/* ---------- Podnožje ---------- */
.foot {
  background: var(--surface);
  border-top: 1px solid var(--line);
  padding: 32px var(--gutter) calc(40px + env(safe-area-inset-bottom));
}
.foot-inner { max-width: var(--max); margin: 0 auto; display: grid; gap: 26px; }
.foot h3 { font: 700 18px/1.2 var(--display); margin: 0 0 8px; }
.foot p { margin: 0; color: var(--ink-soft); }
.foot a { color: var(--ink); font-weight: 600; }
.legend { display: grid; gap: 6px; font-size: 15px; color: var(--ink-soft); }
.legend .tag { margin-right: 8px; }
.hours { border-collapse: collapse; font-size: 15px; font-variant-numeric: tabular-nums; }
.hours td { padding: 3px 18px 3px 0; color: var(--ink-soft); }
.hours tr.today td { color: var(--ink); font-weight: 700; }
@media (min-width: 640px) { .foot-inner { grid-template-columns: 1fr 1fr; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .sheet[open] { animation: none; }
}
