/* BDStall - pages/market-list.css
   Shopping Malls directory (market/list), redesigned 2026-10-20 to match the Stall Directory.
   Mobile first; corners stay at 5px or less. */

.mkt-page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 14px 40px;
}
@media (min-width: 768px) {
  .mkt-page { padding: 0 20px 60px; }
}
@media (min-width: 1200px) {
  .mkt-page { padding-left: 0; padding-right: 0; }
}

/* ─── Hero ─── */
.mkt-hero {
  position: relative;
  display: flex; align-items: flex-start; gap: 16px;
  margin-bottom: 16px;
  padding: 20px 18px;
  overflow: hidden;
  background:
    radial-gradient(120% 140% at 100% 0%, rgba(20,154,73,0.12) 0%, rgba(20,154,73,0) 55%),
    linear-gradient(135deg, #F3FBF6 0%, #FFFFFF 70%);
  border: 1px solid #E3F1E8;
  border-radius: 5px;
}
.mkt-hero-icon {
  flex: none;
  width: 56px; height: 56px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 5px;
  background: linear-gradient(135deg, #149A49, #0F7A3B);
  color: #fff;
  box-shadow: 0 10px 22px rgba(15,122,59,0.25);
}
.mkt-hero-text { position: relative; z-index: 1; min-width: 0; flex: 1 1 auto; }
.mkt-hero-title { margin: 0 0 6px; font-size: 1.5rem; font-weight: 800; line-height: 1.2; color: #14171A; }
.mkt-hero-lede { margin: 0 0 12px; max-width: 560px; font-size: 0.9375rem; line-height: 1.55; color: #4B5563; }
.mkt-hero-stats { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.mkt-hero-stats li {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 12px;
  background: #fff;
  border: 1px solid #E5EEE8;
  border-radius: 5px;
  font-size: 0.8125rem; color: #374151;
}
.mkt-hero-stats strong { font-weight: 800; color: #149A49; }
.mkt-hero-stat-icon { display: inline-flex; color: #149A49; }
@media (min-width: 768px) {
  .mkt-hero { align-items: center; padding: 32px 36px; gap: 22px; }
  .mkt-hero-icon { width: 76px; height: 76px; }
  .mkt-hero-title { font-size: 2rem; }
}

/* Decorative row of shopfronts (desktop only). */
.mkt-hero-art { display: none; }
@media (min-width: 900px) {
  .mkt-hero-art {
    position: relative;
    display: flex; align-items: flex-end; gap: 10px;
    flex: none;
    width: 260px; height: 130px;
  }
  .mkt-art-shop {
    position: relative;
    display: block;
    width: 74px;
    background: #fff;
    border: 1px solid #DCEDE2;
    border-radius: 4px 4px 0 0;
    box-shadow: 0 8px 18px rgba(20,154,73,0.10);
  }
  .mkt-art-shop::before {
    content: "";
    position: absolute; top: 0; left: -4px; right: -4px;
    height: 16px;
    border-radius: 3px;
    background: repeating-linear-gradient(90deg, #149A49 0 12px, #fff 12px 24px);
  }
  .mkt-art-shop span {
    position: absolute; left: 50%; bottom: 0;
    width: 22px; height: 30px;
    transform: translateX(-50%);
    border-radius: 3px 3px 0 0;
    background: #E8F5EC;
  }
  .mkt-art-shop-1 { height: 84px; }
  .mkt-art-shop-2 { height: 112px; }
  .mkt-art-shop-2::before { background: repeating-linear-gradient(90deg, #F58320 0 12px, #fff 12px 24px); }
  .mkt-art-shop-3 { height: 96px; }
  .mkt-art-pin {
    position: absolute; top: 0; right: 6px;
    color: #DC2626;
    filter: drop-shadow(0 4px 6px rgba(220,38,38,0.3));
  }
}

/* ─── Division filter + search ─── */
.mkt-toolbar {
  display: flex; flex-direction: column; gap: 10px;
  margin-bottom: 18px;
}
.mkt-cities {
  display: flex; gap: 6px;
  overflow-x: auto;
  padding-bottom: 2px;
  scrollbar-width: none;
}
.mkt-cities::-webkit-scrollbar { display: none; }
.mkt-city-btn {
  flex: none;
  min-height: 40px;
  padding: 0 14px;
  display: inline-flex; align-items: center; gap: 6px;
  background: #fff;
  border: 1px solid #E5E7EB;
  border-radius: 5px;
  font-family: inherit; font-size: 0.875rem; font-weight: 600; color: #374151;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.mkt-city-btn span {
  padding: 1px 6px;
  border-radius: 4px;
  background: #F3F4F6;
  font-size: 0.75rem; font-weight: 700; color: #6B7280;
}
.mkt-city-btn:hover { border-color: #149A49; color: #0F7A3B; }
.mkt-city-btn.is-active { background: #149A49; border-color: #149A49; color: #fff; }
.mkt-city-btn.is-active span { background: rgba(255,255,255,0.22); color: #fff; }
.mkt-search {
  display: flex; align-items: center; gap: 10px;
  min-height: 46px;
  padding: 0 14px;
  background: #fff;
  border: 1px solid #E5E7EB;
  border-radius: 5px;
}
.mkt-search:focus-within { border-color: #149A49; box-shadow: 0 0 0 3px rgba(20,154,73,0.12); }
.mkt-search-icon { display: inline-flex; color: #9CA3AF; }
.mkt-search input {
  flex: 1 1 auto; min-width: 0;
  height: 44px;
  border: 0; outline: 0; background: transparent;
  font-size: 0.9375rem; color: #1F2937;
}
/* Division buttons on one row, search on its own full-width row below (owner, 2026-10-20). */

/* ─── Division sections ─── */
.mkt-city { margin-bottom: 26px; }
.mkt-city-head {
  display: flex; align-items: center; gap: 8px;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid #E8ECE9;
  color: #149A49;
}
.mkt-city-head h2 { margin: 0; font-size: 1.125rem; font-weight: 800; color: #14171A; }
.mkt-city-count {
  min-width: 24px;
  padding: 1px 7px;
  border-radius: 4px;
  background: #149A49;
  font-size: 0.75rem; font-weight: 700; color: #fff; text-align: center;
}

/* ─── Cards ─── */
.mkt-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
}
@media (min-width: 600px) {
  .mkt-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
}
@media (min-width: 1024px) {
  .mkt-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
}
.mkt-card {
  min-width: 0;
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  grid-template-areas: "icon info";
  align-items: start;
  gap: 10px 12px;
  padding: 14px;
  background: #fff;
  border: 1px solid #ECEFEC;
  border-radius: 5px;
  box-shadow: 0 2px 8px rgba(20,23,26,0.03);
  text-decoration: none;
  color: inherit;
  transition: transform 0.18s, box-shadow 0.18s, border-color 0.18s;
}
.mkt-card[hidden] { display: none; }
.mkt-card:hover { transform: translateY(-2px); border-color: #D3E9DB; box-shadow: 0 12px 26px rgba(20,23,26,0.08); text-decoration: none; color: inherit; }
.mkt-card-icon {
  grid-area: icon;
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 5px;
  background: #E8F5EC;
  color: #149A49;
}
.mkt-card-info { grid-area: info; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.mkt-card-name { font-size: 0.9375rem; font-weight: 800; line-height: 1.3; color: #14171A; overflow-wrap: anywhere; }
.mkt-card-bn { font-size: 0.8125rem; color: #6B7280; }
.mkt-card-place {
  display: flex; align-items: flex-start; gap: 5px;
  margin-top: 4px;
  font-size: 0.8125rem; line-height: 1.4; color: #4B5563;
}
.mkt-card-place svg { flex: none; margin-top: 2px; color: #2563EB; }
/* ─── No results ─── */
.mkt-empty { padding: 48px 16px; text-align: center; color: #9CA3AF; }
.mkt-empty p { margin: 10px 0 0; font-size: 0.9375rem; color: #6B7280; }
