/* ═══════════════════════════════════════════════════════════════
   หน้ารายละเอียดร้าน — /explore/{id}
   แบบที่เลือก: public/mockup/shop-11.html (2026-09-14) · prefix .sp-*

   ต้องโหลดหลัง onzon.css · blocks.css · page-explore.css (การ์ด "ร้านอื่นในจังหวัด" ใช้ของหน้า explore)
   ⚠️ สไตล์หน้าเดิม .sd-* ใน onzon.css เลิกใช้แล้ว (ไม่มีหน้าไหนเรียก) — ลบทิ้งได้ภายหลัง
   ═══════════════════════════════════════════════════════════════ */

.sp-wrap {
  width: min(1240px, 94vw);
  margin: 0 auto;
}

/* ───────── ปุ่ม ───────── */
.sp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 24px;
  border: 1px solid transparent;
  border-radius: 999px;
  font: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition: filter 0.2s, transform 0.2s, background 0.2s, color 0.2s, border-color 0.2s;
}
.sp-btn:hover {
  transform: translateY(-1px);
}
.sp-btn.is-main {
  /* บนแบนเนอร์ — สีตายตัว */
  background: #2f5f19;
  color: #fdfbf6;
  box-shadow: 0 10px 24px -12px rgba(47, 95, 25, 0.9);
}
.sp-btn.is-main:hover,
.sp-btn.is-accent:hover {
  filter: brightness(1.12);
}
.sp-btn.is-glass {
  background: rgba(253, 251, 246, 0.14);
  border-color: rgba(253, 251, 246, 0.4);
  color: #fdfbf6;
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}
.sp-btn.is-glass:hover {
  background: rgba(253, 251, 246, 0.26);
}
.sp-btn.is-icon {
  width: 46px;
  height: 46px;
  padding: 0;
}
.sp-btn.is-accent {
  background: var(--accent);
  color: var(--accent-ink);
}
.sp-btn.is-block {
  width: 100%;
  margin-top: 12px;
}
/* ปุ่มถูกใจ — fav-shops.js ติด .is-on */
.sp-fav.is-on {
  background: rgba(253, 251, 246, 0.95);
  border-color: transparent;
  color: #c2483c;
}
.sp-fav.is-on svg {
  fill: currentColor;
}

/* ───────── แบนเนอร์ ─────────
   ⚠️ ตัวอักษรสีตายตัว — วางบนรูปที่คลุมฟิล์มเข้มทั้งสองโหมด */
.sp-hero {
  position: relative;
  display: flex;
  align-items: flex-end;
  min-height: clamp(380px, 32vw, 480px);
  overflow: hidden;
  background: #2b2a24;
  color: #fdfbf6;
}
.sp-hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.sp-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, rgba(15, 20, 10, 0.15) 0%, rgba(15, 20, 10, 0.35) 45%, rgba(15, 20, 10, 0.88) 100%);
}
.sp-hero-in {
  position: relative;
  z-index: 2;
  padding: 26px 0 86px;   /* ล่างเผื่อที่ให้แถบข้อมูลด่วนลอยทับ */
}
.sp-crumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  color: rgba(253, 251, 246, 0.8);
}
.sp-crumb a {
  color: #fdfbf6;
  text-decoration: none;
}
.sp-crumb a:hover {
  text-decoration: underline;
}
.sp-hero-row {
  display: flex;
  align-items: flex-end;
  gap: 20px;
  margin-top: 14px;
}
.sp-logo {
  flex: 0 0 auto;
  width: 104px;
  height: 104px;
  overflow: hidden;
  border: 4px solid rgba(253, 251, 246, 0.95);
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 14px 30px -12px rgba(0, 0, 0, 0.6);
}
.sp-logo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.sp-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.sp-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(253, 251, 246, 0.92);
  font-size: 0.74rem;
  font-weight: 600;
  color: #2f5f19;
}
.sp-chip.is-glass {
  background: rgba(253, 251, 246, 0.16);
  border: 1px solid rgba(253, 251, 246, 0.35);
  color: #fdfbf6;
}
.sp-hero h1 {
  margin-top: 8px;
  font-size: clamp(1.9rem, 3.6vw, 3rem);
  font-weight: 700;
  line-height: 1.15;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.35);
}
.sp-en {
  margin-top: 4px;
  font-size: 0.95rem;
  color: rgba(253, 251, 246, 0.8);
}
.sp-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 18px;
  margin-top: 10px;
  font-size: 0.92rem;
}
.sp-meta > span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.sp-meta b {
  font-size: 1rem;
}
.sp-hero .sp-stars {
  color: #f3b847;
}
.sp-stars {
  letter-spacing: 1px;
  color: #e8a13a;
}
.sp-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

/* ───────── แถบข้อมูลด่วน (ลอยทับขอบแบนเนอร์) ───────── */
.sp-facts {
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: repeat(var(--n, 4), minmax(0, 1fr));
  margin-top: -54px;
  overflow: hidden;
  background: var(--panel);
  border: 1px solid var(--hair);
  border-radius: 22px;
  box-shadow: var(--shadow-lg);
}
.sp-fact {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 22px;
}
.sp-fact + .sp-fact {
  border-left: 1px solid var(--hair);
}
.sp-fact i {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: var(--accent-wash);
  color: var(--accent);
}
.sp-fact small {
  display: block;
  font-size: 0.74rem;
  color: var(--ink-faint);
}
.sp-fact b {
  display: block;
  margin-top: 2px;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--ink);
}
.sp-open {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-left: 6px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  vertical-align: 2px;
}
.sp-open::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}
.sp-open.is-on {
  background: color-mix(in srgb, #2f9e6b 14%, transparent);
  color: #2f9e6b;
}
.sp-open.is-off {
  background: color-mix(in srgb, var(--warn) 12%, transparent);
  color: var(--warn);
}

/* ───────── เนื้อหา 2 คอลัมน์ ───────── */
.sp-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  align-items: start;
  gap: 26px;
  margin-top: 30px;
}
.sp-body.no-facts {
  position: relative;
  z-index: 3;
  margin-top: -54px;   /* ไม่มีแถบข้อมูลด่วน → การ์ดลอยทับขอบแบนเนอร์แทน */
}
.sp-main,
.sp-side {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.sp-side {
  position: sticky;
  top: 100px;
}
.sp-card {
  padding: 26px 28px;
  background: var(--panel);
  border: 1px solid var(--hair);
  border-radius: 22px;
  box-shadow: var(--shadow-sm);
}
.sp-card > h2 {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--ink);
}
.sp-card > h2 i {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 11px;
  background: var(--accent-wash);
  color: var(--accent);
}
.sp-card > h2 small {
  margin-left: auto;
  font-size: 0.78rem;
  font-weight: 400;
  color: var(--ink-faint);
}
.sp-about p {
  font-size: 0.98rem;
  line-height: 1.95;
  color: var(--ink-soft);
}
.sp-empty,
.sp-about p.sp-empty {
  font-size: 0.88rem;
  line-height: 1.8;
  color: var(--ink-faint);
}
.sp-sub {
  margin-top: 18px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--ink-faint);
}
.sp-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}
.sp-tag {
  padding: 6px 14px;
  border: 1px solid var(--hair);
  border-radius: 999px;
  background: var(--bg);
  font-size: 0.84rem;
  color: var(--ink);
}
.sp-tag.is-accent {
  border-color: color-mix(in srgb, var(--accent) 30%, transparent);
  background: var(--accent-wash);
  color: var(--accent);
}

/* บริการ */
.sp-services {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
}
.sp-service {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--hair);
  border-radius: 14px;
  background: var(--bg);
  font-size: 0.9rem;
  color: var(--ink);
}
.sp-service svg {
  flex: 0 0 auto;
  color: var(--accent);
}

/* แกลเลอรี — รูปแรกใหญ่ 2×2 */
.sp-gallery {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-rows: 130px;
  gap: 10px;
}
.sp-gallery a {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 14px;
}
.sp-gallery a:first-child {
  grid-column: span 2;
  grid-row: span 2;
}
.sp-gallery a.is-hidden {
  display: none;
}
.sp-gallery img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s;
}
.sp-gallery a:hover img {
  transform: scale(1.05);
}
.sp-gallery-more {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(15, 20, 10, 0.55);
  font-size: 1.3rem;
  font-weight: 700;
  color: #fdfbf6;
}

/* ทำเลที่ตั้ง */
.sp-addr {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.94rem;
  line-height: 1.7;
  color: var(--ink);
}
.sp-addr svg {
  flex: 0 0 auto;
  margin-top: 3px;
  color: var(--accent);
}
.sp-map {
  height: 320px;
  margin-top: 14px;
  overflow: hidden;
  border: 1px solid var(--hair);
  border-radius: 16px;
  background: var(--bg);
}
.sp-map iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}
.sp-map-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

/* ติดต่อร้าน */
.sp-contact {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.sp-contact a {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 -10px;
  padding: 10px;
  border-radius: 14px;
  color: var(--ink);
  text-decoration: none;
  transition: background 0.2s;
}
.sp-contact a:hover {
  background: var(--accent-wash);
}
.sp-contact i {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--accent-wash);
  color: var(--accent);
}
.sp-contact span {
  min-width: 0;
  font-size: 0.9rem;
  overflow-wrap: anywhere;
}
.sp-contact small {
  display: block;
  font-size: 0.72rem;
  color: var(--ink-faint);
}

/* รีวิว */
.sp-g-sum {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--hair);
}
.sp-g-sum big {
  font-size: 2.6rem;
  font-weight: 700;
  line-height: 1;
  color: var(--ink);
}
.sp-g-sum small {
  display: block;
  margin-top: 3px;
  font-size: 0.78rem;
  color: var(--ink-faint);
}
.sp-review {
  padding: 14px 0;
  border-bottom: 1px dashed var(--hair);
}
.sp-review:last-of-type {
  border-bottom: 0;
}
.sp-review header {
  display: flex;
  align-items: center;
  gap: 10px;
}
.sp-review header i {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent-wash);
  font-size: 0.85rem;
  font-style: normal;
  font-weight: 700;
  color: var(--accent);
}
.sp-review header div {
  min-width: 0;
}
.sp-review header b {
  font-size: 0.86rem;
  color: var(--ink);
}
.sp-review header small {
  display: block;
  font-size: 0.72rem;
  color: var(--ink-faint);
}
.sp-review header .sp-stars {
  flex: 0 0 auto;
  margin-left: auto;
  font-size: 0.8rem;
}
.sp-review p {
  margin-top: 8px;
  font-size: 0.85rem;
  line-height: 1.7;
  color: var(--ink-soft);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.sp-more-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
}

/* ร้านอื่นในจังหวัด */
.sp-nearby {
  margin-top: 46px;
  margin-bottom: 70px;
}
.sp-nearby .blk-h {
  margin-bottom: 14px;
}

/* ───────── จอแคบ ───────── */
@media (max-width: 1080px) {
  .sp-body {
    grid-template-columns: 1fr;
  }
  .sp-side {
    position: static;
  }
  .sp-facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sp-fact:nth-child(odd) {
    border-left: 0;
  }
  .sp-fact:nth-child(n + 3) {
    border-top: 1px solid var(--hair);
  }
}
@media (max-width: 640px) {
  .sp-hero-in {
    padding-bottom: 74px;
  }
  .sp-hero-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  .sp-logo {
    width: 78px;
    height: 78px;
  }
  .sp-cta .sp-btn.is-main {
    flex: 1 1 100%;
  }
  .sp-facts {
    grid-template-columns: 1fr;
  }
  .sp-fact + .sp-fact {
    border-top: 1px solid var(--hair);
    border-left: 0;
  }
  .sp-card {
    padding: 20px 18px;
  }
  .sp-gallery {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-auto-rows: 110px;
  }
}
