/* ===================== פתיח לפני התפריט (js/ui/home.js) =====================
   כרטיסים לבנים ואווריריים, סמל עגול שיושב על קצה הכרטיס, כפתורי "גלולה" עם מסגרת,
   אריחי תמונה עם תווית. צבעי באבי (בורדו/אוקר/קרם) מ-tokens.css. */
.home { display: grid; gap: 28px; padding-top: 18px; padding-bottom: 36px; }
.home:empty { display: none; }

/* כרטיס */
.hways { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; }
.hcard {
  position: relative; background: var(--surface); border-radius: var(--r-xl); padding: 42px 16px 18px; margin-top: 26px;
  display: grid; justify-items: center; align-content: start; gap: 8px; text-align: center;
  box-shadow: 0 10px 30px -12px rgba(36, 22, 13, .28), 0 1px 0 var(--border);
}
.hcard h3 { font-size: var(--fs-l); font-weight: 800; line-height: var(--lh-tight); }
.hcard p { color: var(--text-2); font-size: var(--fs-s); line-height: 1.55; flex: 1; }
.hcard .pill { margin-top: auto; }
/* סמל עגול שחורג מעל הכרטיס */
.hcard__ic {
  position: absolute; top: -28px; left: 50%; transform: translateX(-50%);
  width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center;
  background: var(--surface); color: var(--accent); box-shadow: 0 0 0 2px var(--accent-soft), 0 6px 16px -6px rgba(36, 22, 13, .35);
}
.hcard__ic .ic { width: 26px; height: 26px; }

.hcard__media { position: relative; overflow: hidden; }
/* באים לביקור? — תמונה רחבה + גוף */
.hcard--wide { padding: 0; overflow: visible; margin-top: 0; }
.hcard--wide .hcard__media { width: 100%; aspect-ratio: 16 / 9; border-radius: var(--r-xl) var(--r-xl) 0 0; overflow: hidden; display: grid; place-items: center; }
.hcard--wide .hcard__media img { width: 100%; height: 100%; object-fit: cover; }
.hcard--wide .hcard__media > .ic { position: relative; z-index: 1; width: 64px; height: 64px; margin-bottom: 18px; }
.hcard--nophoto { margin-top: 26px; }
.hcard__body { position: relative; display: grid; justify-items: center; gap: 8px; padding: 42px 18px 20px; }

/* כפתור גלולה עם מסגרת */
.pill {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: var(--tap); padding: 0 20px;
  border-radius: var(--r-pill); border: 2px solid var(--text); background: transparent; color: var(--text);
  font-weight: 800; font-size: var(--fs-s); text-decoration: none; cursor: pointer;
  box-shadow: 0 3px 0 var(--text); transition: transform var(--dur-fast) var(--ease), background-color var(--dur), color var(--dur);
}
.pill:hover { background: var(--text); color: var(--on-selected); }
.pill:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--text); }
.pill:focus-visible { outline: none; box-shadow: var(--focus-ring); }

/* מהתפריט שלנו */
.hsec { display: grid; gap: 10px; }
.hsec__t { font-family: var(--f-display); font-weight: 700; font-size: var(--fs-2xl); line-height: .95; text-align: center; }
.hsec__s { text-align: center; color: var(--text-2); max-width: 40ch; justify-self: center; }
.htiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 6px; }
@media (min-width: 760px) { .htiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .htiles { grid-template-columns: repeat(6, minmax(0, 1fr)); } }
.htile {
  position: relative; display: block; padding: 0; border: 0; border-radius: var(--r-l); overflow: hidden; cursor: pointer;
  aspect-ratio: 1; background: var(--surface-sunk); box-shadow: 0 8px 22px -12px rgba(36, 22, 13, .35);
}
.htile .hcard__media { width: 100%; height: 100%; display: grid; place-items: center; }
.htile .hcard__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.htile .hcard__media > .ic { position: relative; z-index: 1; width: 40%; height: 40%; margin-bottom: 14%; }
.htile:hover img { transform: scale(1.05); }
.htile__label {
  position: absolute; top: 10px; right: 10px; z-index: 2; padding: 6px 12px; border-radius: var(--r-pill);
  background: var(--surface); color: var(--text); font-weight: 800; font-size: var(--fs-s); box-shadow: 0 2px 8px rgba(0, 0, 0, .15);
}
.htile:focus-visible { outline: none; box-shadow: var(--focus-ring); }

/* יתרונות */
.hfeats { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 38px 14px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.hfeats li {
  position: relative; display: grid; justify-items: center; gap: 6px; text-align: center; padding: 40px 16px 18px;
  background: var(--surface-sunk); border-radius: var(--r-xl);
}
.hfeats b { font-weight: 800; font-size: var(--fs-m); }
.hfeats span:last-child { color: var(--text-2); font-size: var(--fs-s); line-height: 1.5; }

@media (min-width: 900px) {
  .home { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; column-gap: 24px; }
  .hways { grid-column: 1; }
  .hcard--wide { grid-column: 2; grid-row: 1; }
  .hsec, .hfeats { grid-column: 1 / -1; }
}

.brand { min-height: var(--tap); }
/* טלפון בסרגל העליון */
.topphone {
  display: inline-flex; align-items: center; gap: 6px; min-height: var(--tap); padding: 0 10px; border-radius: var(--r-pill);
  color: inherit; text-decoration: none; font-weight: 800; font-size: var(--fs-s); white-space: nowrap; margin-inline-start: auto;
}
.topphone .ic { width: 18px; height: 18px; }
.topphone + .topnav { margin-inline-start: 0; }
.topphone:not([hidden]) ~ .cart-btn { margin-inline-start: 0; }
@container topbar (max-width: 22em) { .topphone span { display: none; } }
