/* =========================================================================
   2Pets Directory — מערכת עיצוב
   ========================================================================= */

:root {
  /* ground */
  --tp-ground:   #F8F8F5;
  --tp-card:     #FFFFFF;
  --tp-tile:     #F2F2EE;
  --tp-hair:     #EFEFE9;
  --tp-line:     #DEDED6;

  /* ink */
  --tp-ink:      #12180F;
  --tp-body:     #3A4034;
  --tp-muted:    #767A6E;

  /* brand */
  --tp-lime:     #8CCF14;
  --tp-lime-dim: #74AE0F;
  --tp-lime-air: #E4F3C6;
  --tp-lime-mark:#D3EE9B;
  --tp-forest:   #14432C;
  --tp-coral:    #F2542D;

  /* depth */
  --tp-sh-1: 0 1px 2px rgba(20,24,15,.04), 0 8px 24px rgba(20,24,15,.05);
  --tp-sh-2: 0 2px 6px rgba(20,24,15,.05), 0 18px 40px rgba(20,24,15,.07);
  --tp-sh-3: 0 6px 14px rgba(20,24,15,.07), 0 30px 60px rgba(20,24,15,.10);
  --tp-inner: inset 0 1px 0 rgba(255,255,255,.9);

  /* rhythm */
  --tp-r-sm: 16px;
  --tp-r-md: 24px;
  --tp-r-lg: 34px;
  --tp-gut:  clamp(16px, 4vw, 56px);
  --tp-max:  1280px;

  /* type */
  --tp-dsp:  "Rubik", "Assistant", system-ui, sans-serif;
  --tp-txt:  "Assistant", "Segoe UI", system-ui, sans-serif;

  /* motion */
  --tp-ease: cubic-bezier(.22, .9, .28, 1);
}

/* ---------- shell ---------- */

.tp-wrap { position: relative; z-index: 1; }

.tp-wrap {
  max-width: var(--tp-max);
  margin: 0 auto;
  padding: 0 var(--tp-gut) 80px;
  font-family: var(--tp-txt);
  color: var(--tp-ink);
  direction: rtl;
}
.tp-wrap * { box-sizing: border-box; }


/* ---------- motion ---------- */

[data-reveal] {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity .62s var(--tp-ease), transform .62s var(--tp-ease);
  transition-delay: var(--d, 0ms);
}
[data-reveal].is-in { opacity: 1; transform: none; }
.no-js [data-reveal] { opacity: 1; transform: none; }

@keyframes tp-drift {
  0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
  50%      { transform: translate3d(-18px, 14px, 0) scale(1.04); }
}

@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1 !important; transform: none !important; transition: none !important; }
  .tp-hero__blob { animation: none !important; }
  * { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}


/* ---------- crumbs ---------- */

.tp-crumbs {
  display: flex; align-items: center; gap: 9px; flex-wrap: wrap;
  padding: 22px 0 0;
  font-size: 14px; font-weight: 600; color: var(--tp-muted);
}
.tp-crumbs a { color: var(--tp-muted); text-decoration: none; }
.tp-crumbs a:hover { color: var(--tp-lime-dim); }
.tp-crumbs [aria-current] { color: var(--tp-ink); }


/* ---------- hero ---------- */

.tp-hero { position: relative; padding: 34px 0 44px; isolation: isolate; }

.tp-hero__blob {
  position: absolute; z-index: -1;
  inset-inline-start: -8%;
  top: -70px;
  width: min(620px, 58vw); aspect-ratio: 6 / 5;
  background: radial-gradient(circle at 34% 32%, var(--tp-lime-air), rgba(228,243,198,0) 70%);
  filter: blur(6px);
  border-radius: 48% 52% 44% 56% / 56% 44% 56% 44%;
  animation: tp-drift 19s var(--tp-ease) infinite;
}
.tp-hero__blob.is-soft { opacity: .8; }

.tp-hero__dots {
  position: absolute; z-index: -1;
  top: 180px; inset-inline-end: 32%;
  width: 108px; height: 74px;
  background-image: radial-gradient(rgba(242,84,45,.55) 2px, transparent 2px);
  background-size: 14px 14px;
}

.tp-hero__inner { display: flex; flex-direction: column; gap: 20px; max-width: 62ch; }

.tp-hero__eyebrow {
  margin: 0;
  font-size: 12.5px; font-weight: 700; letter-spacing: .11em;
  color: var(--tp-muted);
}

.tp-hero__title,
.tp-single__title {
  font-family: var(--tp-dsp);
  margin: 0;
  font-size: clamp(42px, 7.4vw, 96px);
  line-height: .87;
  font-weight: 800;
  letter-spacing: -.045em;
  text-wrap: balance;
}

/* המילה המוקפת — הסימן הגרפי של המערכת */
.tp-pill {
  font-style: normal;
  display: inline-block;
  border: 2px solid currentColor;
  border-radius: 999px;
  padding: 0 .42em .12em;
  line-height: .92;
}

.tp-hero__lede { display: flex; align-items: stretch; gap: 14px; }
.tp-hero__rule { width: 3px; flex-shrink: 0; background: var(--tp-lime); border-radius: 999px; }
.tp-hero__lede p { margin: 0; font-size: clamp(17px, 1.5vw, 21px); line-height: 1.5; font-weight: 600; }
.tp-hero__lede mark,
.tp-prose mark {
  background: linear-gradient(to top, var(--tp-lime-mark) 60%, transparent 60%);
  color: inherit; padding: 0 3px;
}

.tp-stats { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; margin: 4px 0 0; padding: 0; }
.tp-stat {
  display: flex; align-items: baseline; gap: 8px;
  background: var(--tp-card);
  border: 1px solid var(--tp-hair);
  border-radius: var(--tp-r-sm);
  padding: 12px 18px;
  box-shadow: var(--tp-sh-1), var(--tp-inner);
}
.tp-stat b { font-family: var(--tp-dsp); font-size: 28px; font-weight: 700; line-height: 1; }
.tp-stat span { font-size: 14px; font-weight: 700; }
.tp-stat.is-dark { background: var(--tp-forest); color: #F4F7EE; border-color: var(--tp-forest); }


/* ---------- filters ---------- */

.tp-filters {
  position: sticky; top: 0; z-index: 20;
  display: flex; flex-direction: column; gap: 16px;
  background: rgba(255,255,255,.82);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  backdrop-filter: saturate(160%) blur(14px);
  border: 1px solid var(--tp-hair);
  border-radius: var(--tp-r-md);
  padding: 20px 22px;
  box-shadow: var(--tp-sh-1), var(--tp-inner);
  margin-bottom: 30px;
}

.tp-filters__search { display: flex; gap: 12px; align-items: center; }
.tp-search {
  flex-grow: 1; display: flex; align-items: center; gap: 10px;
  background: var(--tp-tile); border-radius: var(--tp-r-sm); padding: 12px 16px;
}
.tp-search svg { width: 19px; height: 19px; color: var(--tp-muted); flex-shrink: 0; }
.tp-search input {
  flex-grow: 1; border: 0; background: none; outline: none;
  font: inherit; font-size: 16px; color: var(--tp-ink); min-width: 0;
}
.tp-search input::placeholder { color: var(--tp-muted); }

.tp-filters__row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.tp-filters__label {
  font-size: 12.5px; font-weight: 700; letter-spacing: .09em;
  color: var(--tp-muted); min-width: 40px;
}
.tp-filters__ns { margin: 0; font-size: 13px; color: var(--tp-muted); }

.tp-chips { display: flex; gap: 8px; flex-wrap: wrap; }
.tp-chip {
  display: inline-flex; align-items: center;
  background: var(--tp-card); color: var(--tp-body);
  border: 1px solid var(--tp-line); border-radius: 999px;
  padding: 7px 16px; font-size: 14.5px; font-weight: 600;
  text-decoration: none;
  transition: transform .2s var(--tp-ease), box-shadow .2s var(--tp-ease), background .2s;
}
.tp-chip:hover { transform: translateY(-1px); box-shadow: var(--tp-sh-1); color: var(--tp-ink); }
.tp-chip.is-on { background: var(--tp-ink); border-color: var(--tp-ink); color: #F7F8F4; font-weight: 700; }
.tp-chip.is-on.is-warm { background: var(--tp-coral); border-color: var(--tp-coral); color: #fff; }
.tp-chips.is-dark .tp-chip { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.16); color: #EDF1E7; }
.tp-chips.is-dark .tp-chip:hover { background: var(--tp-lime); border-color: var(--tp-lime); color: var(--tp-ink); }


/* ---------- results ---------- */

.tp-results { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; padding-bottom: 18px; }
.tp-results__count { font-family: var(--tp-dsp); margin: 0; font-size: 28px; font-weight: 700; letter-spacing: -.03em; }

.tp-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 22px;
}


/* ---------- card ---------- */

.tp-card {
  position: relative;
  display: flex; flex-direction: column;
  background: var(--tp-card);
  border: 1px solid var(--tp-hair);
  border-radius: var(--tp-r-md);
  box-shadow: var(--tp-sh-1), var(--tp-inner);
  overflow: hidden;
  transition: transform .34s var(--tp-ease), box-shadow .34s var(--tp-ease);
}
.tp-card:hover { transform: translateY(-5px); box-shadow: var(--tp-sh-3), var(--tp-inner); }
.tp-card:focus-within { outline: 2px solid var(--tp-lime-dim); outline-offset: 3px; }

.tp-card__link { position: absolute; inset: 0; z-index: 3; }

.tp-card__logo {
  position: relative;
  display: flex; align-items: center; justify-content: center;
  height: 132px; padding: 20px;
  background: var(--tp-tile);
  border-bottom: 1px solid var(--tp-hair);
}
.tp-card__logo img {
  max-width: 100%; max-height: 100%;
  width: auto; height: auto;
  object-fit: contain;
  transition: transform .45s var(--tp-ease);
}
.tp-card:hover .tp-card__logo img { transform: scale(1.035); }

/* אין לוגו — ירוק כהה והשם בליים. נראה מכוון, לא שבור. */
.tp-card__logo.is-empty { background: var(--tp-forest); }
.tp-card__fallback {
  font-family: var(--tp-dsp);
  font-size: clamp(17px, 2.1vw, 25px);
  font-weight: 700; line-height: 1.06;
  color: var(--tp-lime); text-align: center;
  letter-spacing: -.02em;
}
.tp-card.is-municipal .tp-card__logo.is-empty { background: #E9EEE5; }
.tp-card.is-municipal .tp-card__logo svg { width: 44px; height: 44px; color: var(--tp-forest); }

.tp-card__badge {
  position: absolute; top: 12px; inset-inline-end: 12px;
  background: #FFD542; color: var(--tp-ink);
  border-radius: 999px; padding: 4px 11px;
  font-size: 11.5px; font-weight: 700; white-space: nowrap;
  box-shadow: var(--tp-sh-1);
}
.tp-card__badge.is-quiet { background: var(--tp-card); color: var(--tp-forest); }

.tp-card__body { display: flex; flex-direction: column; gap: 11px; padding: 18px; flex-grow: 1; }

.tp-card__title {
  font-family: var(--tp-dsp);
  margin: 0; font-size: 21px; line-height: 1.15; font-weight: 700; letter-spacing: -.02em;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

.tp-card__tags { display: flex; gap: 6px; flex-wrap: wrap; }
.tp-tag {
  background: var(--tp-tile); color: var(--tp-body);
  border-radius: 999px; padding: 4px 11px;
  font-size: 12px; font-weight: 700; white-space: nowrap;
}
.tp-tag.is-city { background: var(--tp-lime); color: var(--tp-ink); }

.tp-card__excerpt {
  margin: 0; flex-grow: 1;
  font-size: 14.5px; line-height: 1.45; color: var(--tp-muted);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

.tp-card__foot {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  border-top: 1px solid var(--tp-hair); padding-top: 12px;
}
.tp-card__tel {
  position: relative; z-index: 4;
  font-family: var(--tp-dsp); font-size: 17px; font-weight: 700;
  color: var(--tp-ink); text-decoration: none; direction: ltr;
}
.tp-card__tel:hover { color: var(--tp-lime-dim); }
.tp-card__tel.is-muted { font-family: var(--tp-txt); font-size: 14px; font-weight: 600; color: var(--tp-muted); }

.tp-card__go {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; flex-shrink: 0;
  border-radius: 999px; background: var(--tp-tile); color: var(--tp-ink);
  transition: background .28s var(--tp-ease), transform .28s var(--tp-ease);
}
.tp-card__go svg { width: 17px; height: 17px; transition: transform .28s var(--tp-ease); }
.tp-card:hover .tp-card__go { background: var(--tp-lime); }
.tp-card:hover .tp-card__go svg { transform: translateX(-3px); }


/* ---------- tiles (main index) ---------- */

.tp-section { padding: 8px 0 44px; }
.tp-section__head {
  font-family: var(--tp-dsp);
  margin: 0 0 20px; font-size: clamp(26px, 3vw, 34px); font-weight: 700; letter-spacing: -.035em;
}

.tp-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 18px; }
.tp-tile {
  display: flex; flex-direction: column; gap: 12px;
  background: var(--tp-card); border: 1px solid var(--tp-hair);
  border-radius: var(--tp-r-md); padding: 22px 20px;
  box-shadow: var(--tp-sh-1), var(--tp-inner);
  text-decoration: none; color: var(--tp-ink);
  transition: transform .34s var(--tp-ease), box-shadow .34s var(--tp-ease);
}
.tp-tile:hover { transform: translateY(-5px); box-shadow: var(--tp-sh-3), var(--tp-inner); }
.tp-tile__icon {
  display: flex; align-items: center; justify-content: center;
  width: 52px; height: 52px; border-radius: 17px;
  background: var(--tp-lime-air); color: var(--tp-forest);
}
.tp-tile__icon svg { width: 27px; height: 27px; }
.tp-tile__name { font-family: var(--tp-dsp); font-size: 20px; font-weight: 700; letter-spacing: -.02em; }
.tp-tile__count { font-size: 14px; font-weight: 600; color: var(--tp-muted); }
.tp-tile.is-feature { background: var(--tp-forest); border-color: var(--tp-forest); color: #F4F7EE; }
.tp-tile.is-feature .tp-tile__icon { background: var(--tp-lime); color: var(--tp-forest); }
.tp-tile.is-feature .tp-tile__count { color: var(--tp-lime); }


/* ---------- bands ---------- */

.tp-band {
  background: var(--tp-ink); color: #F4F7EE;
  border-radius: var(--tp-r-lg);
  padding: clamp(26px, 4vw, 44px);
  margin: 12px 0 44px;
  display: flex; flex-direction: column; gap: 20px;
  box-shadow: var(--tp-sh-2);
}
.tp-band__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; flex-wrap: wrap; }
.tp-band__head h2 { font-family: var(--tp-dsp); margin: 0; font-size: clamp(24px, 3vw, 32px); font-weight: 700; letter-spacing: -.035em; }
.tp-band__head p { margin: 0; font-size: 15px; color: #AFB8A8; }

.tp-cta {
  display: flex; align-items: center; justify-content: space-between; gap: 30px; flex-wrap: wrap;
  background: linear-gradient(120deg, var(--tp-lime) 0%, #A6DC46 100%);
  border-radius: var(--tp-r-lg);
  padding: clamp(26px, 4vw, 44px);
  margin-top: 46px;
  box-shadow: var(--tp-sh-2);
}
.tp-cta__text { display: flex; flex-direction: column; gap: 8px; max-width: 620px; }
.tp-cta h2 { font-family: var(--tp-dsp); margin: 0; font-size: clamp(26px, 3.4vw, 42px); line-height: .98; font-weight: 700; letter-spacing: -.04em; text-wrap: balance; }
.tp-cta p { margin: 0; font-size: 17px; font-weight: 600; line-height: 1.45; }


/* ---------- buttons ---------- */

.tp-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  border: 1px solid transparent; border-radius: 999px;
  padding: 13px 26px; min-height: 46px;
  font: inherit; font-size: 16px; font-weight: 700;
  text-decoration: none; cursor: pointer;
  transition: transform .24s var(--tp-ease), box-shadow .24s var(--tp-ease), background .24s;
}
.tp-btn svg { width: 18px; height: 18px; }
.tp-btn:hover { transform: translateY(-2px); box-shadow: var(--tp-sh-2); }
.tp-btn.is-primary { background: var(--tp-lime); color: var(--tp-ink); }
.tp-btn.is-dark    { background: var(--tp-ink);  color: #F7F8F4; }
.tp-btn.is-ghost   { background: var(--tp-card); color: var(--tp-ink); border-color: var(--tp-line); }
.tp-btn.is-block   { width: 100%; }


/* ---------- single ---------- */

.tp-single__top {
  position: relative;
  display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 48px;
  align-items: start;
  padding: 26px 0 10px;
}
.tp-single__main { display: flex; flex-direction: column; gap: 20px; }

.tp-badges { display: flex; gap: 8px; flex-wrap: wrap; }
.tp-badge {
  background: var(--tp-card); border: 1px solid var(--tp-line);
  border-radius: 999px; padding: 6px 15px; font-size: 13px; font-weight: 700;
}
.tp-badge.is-city { background: var(--tp-lime); border-color: var(--tp-lime); }

.tp-prose { display: flex; flex-direction: column; gap: 18px; max-width: 68ch; }
.tp-prose p { margin: 0; font-size: 17.5px; line-height: 1.72; color: var(--tp-body); }
.tp-prose h2 { font-family: var(--tp-dsp); margin: 10px 0 0; font-size: 28px; font-weight: 700; letter-spacing: -.03em; line-height: 1.12; }
.tp-prose a { color: var(--tp-forest); text-underline-offset: 3px; }
.tp-prose strong { font-weight: 700; color: var(--tp-ink); }

.tp-contact { position: sticky; top: 22px; display: flex; flex-direction: column; gap: 14px; }
.tp-contact__card {
  background: var(--tp-card); border: 1px solid var(--tp-hair);
  border-radius: var(--tp-r-md); overflow: hidden;
  box-shadow: var(--tp-sh-2), var(--tp-inner);
}
.tp-contact__logo {
  display: flex; align-items: center; justify-content: center;
  height: 148px; padding: 22px;
  background: var(--tp-tile); border-bottom: 1px solid var(--tp-hair);
}
.tp-contact__logo img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; }
.tp-contact__logo.is-empty { background: var(--tp-forest); }
.tp-contact__body { display: flex; flex-direction: column; gap: 13px; padding: 20px; }

.tp-facts { margin: 0; display: flex; flex-direction: column; gap: 12px; }
.tp-facts > div { display: flex; flex-direction: column; gap: 2px; }
.tp-facts dt { font-size: 12px; font-weight: 700; letter-spacing: .07em; color: var(--tp-muted); }
.tp-facts dd { margin: 0; font-size: 16px; font-weight: 600; line-height: 1.4; }
.tp-facts a { color: var(--tp-forest); }

.tp-contact__note {
  margin: 0; font-size: 13px; line-height: 1.45; color: var(--tp-muted);
  background: var(--tp-card); border: 1px dashed var(--tp-line);
  border-radius: var(--tp-r-sm); padding: 13px 15px;
}

.tp-related { margin-top: 52px; display: flex; flex-direction: column; gap: 20px; }
.tp-related h2 { font-family: var(--tp-dsp); margin: 0; font-size: clamp(24px, 3vw, 32px); font-weight: 700; letter-spacing: -.035em; }


/* ---------- pagination / empty ---------- */

.pagination, .tp-pagination { display: flex; justify-content: center; gap: 8px; padding-top: 34px; }
.pagination .page-numbers {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 44px; height: 44px; padding: 0 14px;
  background: var(--tp-card); border: 1px solid var(--tp-line); border-radius: 999px;
  font-weight: 700; text-decoration: none; color: var(--tp-ink);
  transition: transform .2s var(--tp-ease), box-shadow .2s var(--tp-ease);
}
.pagination .page-numbers:hover { transform: translateY(-2px); box-shadow: var(--tp-sh-1); }
.pagination .page-numbers.current { background: var(--tp-ink); border-color: var(--tp-ink); color: #F7F8F4; }

.tp-empty { font-size: 17px; color: var(--tp-muted); padding: 40px 0; }


/* ---------- responsive ---------- */

@media (max-width: 1020px) {
  .tp-single__top { grid-template-columns: 1fr; gap: 30px; }
  .tp-contact { position: static; }
}

@media (max-width: 700px) {
  .tp-hero__dots { display: none; }
  .tp-filters { position: static; padding: 16px; }
  .tp-filters__row { gap: 8px; }
  .tp-chips { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
  .tp-chips::-webkit-scrollbar { display: none; }

  /* מובייל: הכרטיס מתהפך לשורה, והטלפון הופך לפעולה הראשית */
  .tp-grid { grid-template-columns: 1fr; gap: 12px; }
  .tp-card { flex-direction: row; align-items: stretch; padding: 14px; gap: 13px; }
  .tp-card__logo {
    width: 82px; height: 82px; flex-shrink: 0; align-self: flex-start;
    padding: 8px; border: 0; border-radius: 17px;
  }
  .tp-card__logo .tp-card__badge { display: none; }
  .tp-card__body { padding: 0; gap: 8px; }
  .tp-card__title { font-size: 18px; }
  .tp-card__excerpt { -webkit-line-clamp: 2; font-size: 14px; }
  .tp-card__foot { border: 0; padding-top: 2px; gap: 8px; }
  .tp-card__tel {
    flex-grow: 1; display: inline-flex; align-items: center; justify-content: center;
    min-height: 44px; background: var(--tp-lime); border-radius: 999px;
    padding: 0 14px; font-size: 15px;
  }
  .tp-card__tel.is-muted { background: var(--tp-tile); }
  .tp-card__go { width: 44px; height: 44px; }
}
