/* =========================================================
   home.css  —  Homepage-only sections
   (categories, banner carousel, offers, delivery-location modal)
   Shared pieces now live in:
     lb-base.css     tokens, reset, buttons, sheet/modal shell, toast
     restaurant.css  restaurant cards / rows
     product.css     product cards, price, filters, variation rows
     header_food.css site header
   ========================================================= */

/* ---------- 1. Categories ---------- */
.cat {
  width: 96px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 8px;
}
.cat__img {
  width: 82px; height: 82px; border-radius: 50%; overflow: hidden;
  background: var(--leaf-100); border: 3px solid #fff; box-shadow: var(--shadow-1);
  transition: transform .2s, box-shadow .2s;
}
.cat__img img { width: 100%; height: 100%; object-fit: cover; }
.cat:hover .cat__img { transform: translateY(-3px); box-shadow: 0 0 0 3px var(--mango), var(--shadow-1); }
.cat__name { font-size: 13px; font-weight: 600; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.skel--cat { width: 82px; height: 82px; border-radius: 50%; }

/* ---------- 2. Banners ---------- */
.banner { position: relative; border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow-1); }
.banner__track { display: flex; transition: transform .6s cubic-bezier(.65, 0, .25, 1); }
.banner__slide {
  min-width: 100%; position: relative; isolation: isolate;
  min-height: clamp(170px, 30vw, 330px);
  display: flex; align-items: center; padding: clamp(20px, 5vw, 64px);
  color: #fff; background-size: cover; background-position: center;
}
.banner__slide::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(8, 40, 28, .72), rgba(8, 40, 28, .1) 75%); }
.banner__slide--g1 { background-image: radial-gradient(circle at 85% 20%, #ffd45c 0 12%, transparent 13%), linear-gradient(120deg, #0b3d2c, #138556); }
.banner__slide--g2 { background-image: radial-gradient(circle at 80% 70%, #ff8a5c 0 14%, transparent 15%), linear-gradient(120deg, #7a1f12, #e4432d); }
.banner__slide--g3 { background-image: radial-gradient(circle at 88% 30%, #fff 0 9%, transparent 10%), linear-gradient(120deg, #3b2a00, #b57b00); }
.banner__body { max-width: 520px; }
.banner__body h3 { font-size: clamp(24px, 4.6vw, 48px); font-weight: 800; }
.banner__body p { margin: 10px 0 18px; font-size: clamp(13px, 1.6vw, 17px); opacity: .92; }
.banner__dots { position: absolute; left: 50%; bottom: 14px; translate: -50% 0; display: flex; gap: 7px; }
.banner__dots button { width: 8px; height: 8px; border-radius: 999px; background: rgba(255, 255, 255, .5); transition: width .25s, background .25s; }
.banner__dots button[aria-current="true"] { width: 26px; background: #fff; }

/* ---------- 3. Offers ---------- */
.offer {
  width: 290px; padding: 16px 16px 16px 20px; border-radius: var(--r-md); background: var(--card);
  border: 1px dashed #d9c58a; position: relative; text-align: left;
  display: flex; flex-direction: column; gap: 6px; box-shadow: var(--shadow-1);
  transition: transform .2s, border-color .2s;
}
.offer::before, .offer::after {
  content: ""; position: absolute; left: -9px; width: 18px; height: 18px; border-radius: 50%; background: var(--bg); border: 1px dashed #d9c58a;
  clip-path: inset(0 0 0 50%);
}
.offer::before { top: 18px; }
.offer::after { bottom: 18px; }
.offer:hover { transform: translateY(-3px); border-color: var(--mango); }
.offer__tag { align-self: flex-start; background: var(--mango-soft); color: #7a5300; font-weight: 700; font-size: 12px; padding: 3px 10px; border-radius: 999px; }
.offer__title { font-size: 17px; font-weight: 700; font-family: var(--font-head); }
.offer__desc { color: var(--ink-2); font-size: 13px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 38px; }
.offer__foot { font-size: 12px; color: var(--ink-3); font-weight: 600; margin-top: 2px; }
.skel--offer { width: 290px; height: 124px; }

/* ---------- Delivery location selector (modal) ---------- */
.location-sheet {
  box-sizing: border-box;
  width: min(620px, calc(100vw - 24px));
  max-width: calc(100vw - 24px);
  max-height: min(88vh, 760px);
  overflow: hidden;
}
.location-sheet .sheet__head,
.location-sheet .sheet__title-row,
.location-sheet .sheet__label,
.location-sheet .sheet__list { min-width: 0; box-sizing: border-box; }
.location-sheet .sheet__list { overflow-x: hidden; overflow-y: auto; }
.location-sheet__hint { margin: 4px 0 0; color: var(--ink-2); font-size: 13px; }
.location-current { margin: 12px 0 4px; }
.location-option {
  box-sizing: border-box; width: 100%; min-width: 0;
  display: flex; align-items: flex-start; gap: 10px; text-align: left;
  padding: 12px; border-bottom: 1px solid var(--line); border-radius: 10px;
}
.location-option:hover, .location-option.is-selected { background: var(--leaf-100); }
.location-option__icon { width: 38px; height: 38px; border-radius: 50%; background: var(--leaf-100); display: grid; place-items: center; flex: none; }
.location-option__body { min-width: 0; flex: 1 1 auto; display: flex; flex-direction: column; overflow-wrap: anywhere; }
.location-option__body strong { font-size: 15px; }
.location-option__body strong,
.location-option__body small { display: block; white-space: normal; overflow-wrap: anywhere; word-break: normal; line-height: 1.4; }
.location-option__body small { color: var(--ink-3); margin-top: 2px; }
.location-option__check { flex: 0 0 auto; max-width: 90px; font-weight: 800; color: var(--leaf-700); white-space: normal; text-align: right; overflow-wrap: anywhere; }
.location-sheet .location-status { flex: 0 1 auto; max-width: 100%; white-space: normal; overflow-wrap: anywhere; line-height: 1.35; }
.location-loading, .location-empty { min-height: 150px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; text-align: center; color: var(--ink-2); }
.location-empty__icon { font-size: 32px; }
.location-empty span { font-size: 13px; color: var(--ink-3); }

/* ---------- Responsive ---------- */
@media (max-width: 560px) {
  .cat { width: 78px; }
  .cat__img { width: 68px; height: 68px; }
  .offer { width: 250px; }
  .location-sheet { width: 100%; max-width: 100%; max-height: 90vh; border-radius: var(--r-lg) var(--r-lg) 0 0; }
  .location-sheet .sheet__list { padding-left: 14px; padding-right: 14px; }
  .location-option { padding: 11px 10px; gap: 8px; }
  .location-option__icon { width: 32px; height: 32px; }
}
