/* Siam Relax · หน้าตัวอย่างร้านนวด/สปา (perdna) */
:root {
  --green: #6A4128;   /* สีหลัก น้ำตาลไม้ */
  --green-2: #8A5A36;
  --ink: #2B211A;
  --muted: #6E6257;
  --cream: #F4EDE4;
  --cream-2: #FBF8F4;
  --sand: #E5D7C5;
  --border: #EBE1D4;
  --gold: #7A4A22;
  --line: #00873C;
  --line-d: #00722F;
  --ok: #2F7A3A;
  --warn: #A5481A;
  --note: #FFF5CF;
  --note-b: #F1D77A;
  --radius: 14px;
  --shadow: 0 8px 24px rgba(106, 65, 40, .08);
  --dock-h: 64px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "IBM Plex Sans Thai", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 16px; line-height: 1.6; color: var(--ink); background: #fff;
  padding-bottom: calc(var(--dock-h) + env(safe-area-inset-bottom));
}
img { max-width: 100%; display: block; }
svg { flex: none; }
a { color: inherit; }
h1, h2, h3 { font-family: "Prompt", "IBM Plex Sans Thai", sans-serif; color: var(--green); line-height: 1.3; margin: 0; font-weight: 600; }
h1 { font-size: clamp(30px, 8.4vw, 50px); color: #fff; }
h2 { font-size: clamp(22px, 5.8vw, 30px); }
h2::after { content: ""; display: block; width: 44px; height: 3px; border-radius: 3px; background: var(--green-2); margin-top: 10px; }
h3 { font-size: 17px; }
p { margin: 0; }

.wrap { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.sub { color: var(--muted); margin-top: 12px; }
.link { color: var(--green-2); text-decoration: underline; text-underline-offset: 3px; }
.eyebrow { font-size: 14px; font-weight: 600; letter-spacing: .02em; margin-bottom: 8px; }

.ic { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ic-line { width: 22px; height: 22px; fill: currentColor; --li: var(--line); flex: none; }

/* ปุ่ม */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 18px; border-radius: 12px; border: 1.5px solid transparent;
  font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; transition: background .15s, transform .1s;
}
.btn:active { transform: scale(.98); }
.btn-sm { min-height: 44px; padding: 0 16px; font-size: 15px; }
.btn-block { width: 100%; }
.btn-dark { background: var(--green); color: #fff; }
.btn-dark:hover { background: #55331F; }
.btn-line { background: var(--line); color: #fff; }
.btn-line:hover { background: var(--line-d); }
.btn-cream { background: var(--cream); color: var(--green); border-color: var(--sand); }
.btn-ghost { background: #fff; color: var(--green); border-color: var(--sand); }
.btn-ghost:hover { background: var(--cream-2); }
:focus-visible { outline: 3px solid #D9B993; outline-offset: 2px; }

/* แถบหน้าตัวอย่าง */
.demo-bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; background: #2E2018; color: #fff; font-size: 13px; padding: 8px 16px; }
.demo-explain { min-height: 36px; background: #FFD95A; color: #3A2A00; border: 0; border-radius: 999px; padding: 6px 12px; font: inherit; font-weight: 600; cursor: pointer; white-space: nowrap; }
.demo-bar .demo-sub { display: none; }
@media (min-width: 420px) { .demo-bar .demo-sub { display: inline; } }
.note { display: none; margin-top: 16px; padding: 12px 14px; border-radius: 12px; background: var(--note); border: 1px dashed var(--note-b); color: #5A4300; font-size: 14px; }
.note::before { content: "แก้ปัญหา: "; font-weight: 600; }
body.explain .note { display: block; }

/* หัวเว็บ */
.topbar { position: sticky; top: 0; z-index: 20; background: rgba(255,255,255,.97); backdrop-filter: blur(8px); border-bottom: 1px solid var(--border); }
.topbar-in { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: flex; flex-direction: column; text-decoration: none; line-height: 1; }
.brand-row { flex-direction: row; align-items: center; gap: 10px; }
.brand-lotus-img { width: 46px; height: auto; display: block; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-mark { font-family: "Prompt", sans-serif; font-weight: 600; font-size: 19px; color: var(--green); letter-spacing: .06em; }
.brand-sub2 { font-size: 11.5px; font-weight: 600; letter-spacing: .14em; color: var(--green-2); margin-top: 3px; }

/* รูปสำรอง */
.ph { position: relative; overflow: hidden; background: linear-gradient(135deg, #E7DACB, #F7F1EA); margin: 0; }
.ph img { width: 100%; height: 100%; object-fit: cover; position: relative; z-index: 1; }
.ph-label { position: absolute; inset: 0; display: grid; place-items: center; color: #9C8F78; font-size: 14px; }

/* ฮีโร่ */
.hero { position: relative; background: #2A2620; color: #fff; }
.ph-hero { position: absolute; inset: 0; background: linear-gradient(135deg, #5A3E2B, #2A1D15); }
.ph-hero img { object-position: 60% 70%; }
.ph-hero .ph-label { color: rgba(255,255,255,.4); align-items: end; padding-bottom: 90px; }
.ph-hero::after { content: ""; position: absolute; inset: 0; z-index: 2; background: linear-gradient(180deg, rgba(30,18,10,.72) 0%, rgba(30,18,10,.35) 55%, rgba(30,18,10,.15) 100%); }
.hero-text { position: relative; z-index: 3; padding-top: 36px; padding-bottom: 96px; min-height: 340px; }
.hero .eyebrow { color: #F2D8B8; }
.hero h1 { text-shadow: 0 2px 12px rgba(0,0,0,.35); }
.lead { font-size: 17px; margin-top: 10px; color: #F3EDE3; text-shadow: 0 1px 8px rgba(0,0,0,.4); }

.hero-card { position: relative; z-index: 4; margin-top: -64px; }
.hero-actions { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; background: #fff; padding: 14px; border-radius: 18px; box-shadow: 0 10px 30px rgba(0,0,0,.12); }
.hero-actions .btn { padding: 0 8px; }

.quick { list-style: none; margin: 14px 0 0; padding: 4px 14px; border: 1px solid var(--border); border-radius: var(--radius); background: #fff; }
.quick li { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--border); font-size: 15px; }
.quick li:last-child { border-bottom: 0; }
.quick .ic { color: var(--green-2); }
.q-k { color: var(--muted); min-width: 60px; }
.q-v { font-weight: 600; margin-left: auto; text-align: right; }
.q-v .link { display: inline-block; padding: 10px 0; margin: -10px 0; }
.q-v.is-open { color: var(--ok); }
.q-v.is-closed { color: var(--warn); }

.feats { list-style: none; margin: 12px 0 0; padding: 14px 8px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; background: var(--cream); border-radius: var(--radius); }
.feats li { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; font-size: 13px; color: var(--muted); line-height: 1.35; }
.feats .ic { width: 28px; height: 28px; color: var(--green); }
.feats strong { display: block; color: var(--green); font-size: 14px; }

/* ส่วนทั่วไป */
.section { padding: 44px 0; }
.section-tint { background: var(--cream-2); }
.two-col { display: grid; gap: 24px; }
.two-col > .note { grid-column: 1 / -1; margin-top: 0; }

/* เมนู */
.dishes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 20px; }
.dish { position: relative; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; padding-bottom: 10px; }
.ph-dish { aspect-ratio: 1; }
.dish h3 { font-family: "IBM Plex Sans Thai", sans-serif; font-weight: 600; font-size: 14px; color: var(--ink); line-height: 1.35; margin: 8px 8px 2px; }
.price { font-size: 14px; font-weight: 600; color: var(--gold); margin: 0 8px; }
.tag { position: absolute; z-index: 2; top: 6px; left: 6px; font-size: 11.5px; font-weight: 600; padding: 2px 8px; border-radius: 999px; background: rgba(255,255,255,.94); color: var(--green); }
.tag-hot { background: #B3261E; color: #fff; }

.fullmenu { margin-top: 22px; background: var(--cream-2); border: 1px solid var(--border); border-radius: 18px; padding: 16px; }
.fullmenu h3 { margin-bottom: 8px; }
.fullmenu details { border-top: 1px solid var(--border); }
.fullmenu summary { cursor: pointer; padding: 13px 26px 13px 0; font-weight: 600; color: var(--green); list-style: none; position: relative; }
.fullmenu summary::-webkit-details-marker { display: none; }
.fullmenu summary::after { content: "+"; position: absolute; right: 2px; top: 10px; font-size: 20px; }
.fullmenu details[open] summary::after { content: "–"; }
.mlist { list-style: none; margin: 0 0 12px; padding: 0; }
.mlist li { display: flex; align-items: baseline; gap: 8px; padding: 5px 0; font-size: 15px; }
.mlist li::after { content: ""; order: 1; flex: 1; border-bottom: 1px dotted #CDBFA6; transform: translateY(-4px); }
.mlist b { order: 2; font-weight: 600; color: var(--gold); }
.fullmenu > .small { margin-top: 12px; }

/* จองโต๊ะ */
.book { margin-top: 20px; background: #fff; border: 1px solid var(--border); border-radius: 18px; padding: 18px; box-shadow: var(--shadow); }
.book-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.field { display: block; }
.f-label { display: block; font-weight: 600; color: var(--green); font-size: 15px; margin-bottom: 6px; }
.field input, .field select {
  width: 100%; min-height: 50px; border: 1.5px solid var(--border); border-radius: 12px; padding: 0 12px;
  font: inherit; color: var(--ink); background: #fff; -webkit-appearance: none; appearance: none;
}
.field select { padding-right: 34px; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%236A4128' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 10px center; }
.field-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 16px 0 8px; }
.field-row .f-label { margin: 0; }
.stepper { display: flex; align-items: center; border: 1.5px solid var(--border); border-radius: 12px; overflow: hidden; }
.stepper button { width: 46px; height: 46px; border: 0; background: var(--cream); color: var(--green); cursor: pointer; display: grid; place-items: center; }
.stepper button svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; }
.stepper button:disabled { color: #C4B9A5; cursor: default; }
.stepper output { min-width: 48px; text-align: center; font-weight: 600; font-size: 18px; }
.book-hint { min-height: 22px; font-size: 14px; color: var(--green-2); margin-bottom: 10px; }
.book .btn + .small { margin-top: 10px; }

/* โซน */
.zones { display: grid; gap: 14px; margin: 20px 0 16px; }
.zone { margin: 0; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.ph-zone { aspect-ratio: 16 / 10; }
.zone figcaption { padding: 12px 14px; }
.zone strong { display: block; color: var(--green); }
.zone span { font-size: 14px; color: var(--muted); }

/* สั่งกลับบ้าน */
.order-grid { display: grid; gap: 10px; margin-top: 18px; }
.order { display: flex; align-items: center; gap: 12px; padding: 12px 14px; text-decoration: none; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); }
.order strong { display: block; color: var(--ink); }
.order small { display: block; color: var(--muted); font-size: 13.5px; }
.order::after { content: "›"; margin-left: auto; font-size: 24px; color: #B9AC93; }
.order-badge { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; font-weight: 700; font-size: 13px; color: #fff; flex: none; }
.order-grab { background: #00824A; }
.order-lm { background: #007A3D; }
.order-call { background: var(--cream); color: var(--green); }

/* การเดินทาง */
.addr { margin-top: 16px; }
.addr-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 14px 0 6px; }
.addr-actions .btn { padding: 0 10px; }
.checks { list-style: none; margin: 12px 0 0; padding: 0; }
.checks li { display: flex; gap: 10px; padding: 7px 0; font-size: 15px; }
.checks .ic { color: var(--ok); margin-top: 3px; stroke-width: 2.4; }
.ph-entrance { aspect-ratio: 4 / 3; border-radius: 18px; }

/* รีวิว */
.rating { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 8px; margin-top: 16px; color: var(--muted); }
.rating strong { color: var(--green); font-size: 18px; }
.stars { display: inline-flex; gap: 2px; }
.stars svg { width: 18px; height: 18px; fill: #E0A526; stroke: none; }
.reviews { display: grid; gap: 12px; margin-top: 16px; }
.reviews blockquote { margin: 0; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; }
.reviews footer { margin-top: 8px; font-size: 13.5px; color: var(--muted); }

/* เวลา + แชร์ */
.hours { width: 100%; border-collapse: collapse; margin: 18px 0 12px; }
.hours th, .hours td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--border); }
.hours th { font-weight: 500; }
.hours td { text-align: right; font-weight: 600; }
.hours td.closed { color: var(--warn); }
.hours tr.today { background: var(--cream); }
.hours tr.today th::after { content: " · วันนี้"; color: var(--green-2); font-size: 13px; }
.share-box { background: var(--cream); border-radius: 18px; padding: 18px; align-self: start; }
.share-box .muted { margin: 6px 0 14px; }

/* FAQ */
.faq { margin-top: 18px; display: grid; gap: 8px; }
.faq details { background: #fff; border: 1px solid var(--border); border-radius: 12px; padding: 0 16px; }
.faq summary { cursor: pointer; padding: 14px 24px 14px 0; font-weight: 600; color: var(--green); list-style: none; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 0; top: 12px; font-size: 20px; color: var(--green-2); }
.faq details[open] summary::after { content: "–"; }
.faq details p { padding-bottom: 14px; color: var(--muted); }

/* perdna */
.perdna-cta { background: var(--green); color: #fff; text-align: center; }
.perdna-cta h2 { color: #fff; }
.perdna-cta h2::after { margin: 10px auto 0; background: #FFD95A; }
.perdna-cta .eyebrow { color: #FFD95A; }
.perdna-cta p:not(.eyebrow) { margin: 12px auto 20px; max-width: 520px; color: #EADCCD; }
.perdna-cta .btn-line { background: #fff; color: var(--line); --li: #fff; }
.perdna-cta .btn-line .ic-line { color: var(--line); --li: #fff; }
.perdna-link { display: block; margin-top: 6px; padding: 10px 0; color: #fff; }

.footer { padding: 28px 0 24px; border-top: 1px solid var(--border); }
.footer p { margin-bottom: 4px; }

/* แถบปุ่มล่าง */
.dock {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  display: grid; grid-template-columns: 1fr 1.5fr 1fr; gap: 8px;
  padding: 8px 10px calc(8px + env(safe-area-inset-bottom));
  background: rgba(255,255,255,.97); border-top: 1px solid var(--border); box-shadow: 0 -4px 16px rgba(106,65,40,.08);
}
.dock a { display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 48px; border-radius: 12px; text-decoration: none; font-weight: 600; font-size: 15px; color: var(--green); background: var(--cream); }
.dock .dock-main { background: var(--line); color: #fff; }

.toast {
  position: fixed; left: 50%; bottom: calc(var(--dock-h) + 18px + env(safe-area-inset-bottom)); z-index: 40;
  transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  width: max-content; max-width: calc(100% - 32px); padding: 12px 16px; border-radius: 12px;
  background: var(--green); color: #fff; font-size: 14.5px; text-align: center; transition: .25s;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* จอใหญ่ */
@media (min-width: 720px) {
  .dishes { grid-template-columns: repeat(6, 1fr); }
  .zones { grid-template-columns: repeat(3, 1fr); }
  .reviews { grid-template-columns: repeat(3, 1fr); }
  .order-grid { grid-template-columns: repeat(3, 1fr); }
  .book { max-width: 620px; }
}
@media (min-width: 900px) {
  .section { padding: 64px 0; }
  .hero-text { padding-top: 90px; padding-bottom: 150px; min-height: 520px; }
  .hero-text > * { max-width: 560px; }
  .ph-hero::after { background: linear-gradient(90deg, rgba(30,18,10,.78) 0%, rgba(30,18,10,.45) 45%, rgba(30,18,10,.05) 80%); }
  .hero-card { display: grid; grid-template-columns: 1.1fr 1fr; gap: 14px 20px; margin-top: -90px; }
  .hero-actions { grid-column: 1 / -1; max-width: 560px; }
  .quick, .feats { margin-top: 0; align-self: start; }
  .hero-card > .note { grid-column: 1 / -1; }
  .two-col { grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; }
  .dock { left: auto; right: 20px; bottom: 20px; width: 420px; border-radius: 18px; border: 1px solid var(--border); padding: 8px; }
  body { padding-bottom: 0; }
  .toast { bottom: 100px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
.btn.is-off { opacity: .5; }

/* ตารางราคาสปา */
.ptable { width: 100%; border-collapse: collapse; font-size: 14.5px; margin: 6px 0 12px; }
.ptable th, .ptable td { padding: 9px 4px; border-bottom: 1px solid var(--border); text-align: right; white-space: nowrap; }
.ptable th:first-child, .ptable td:first-child { text-align: left; white-space: normal; }
.ptable thead th { color: var(--muted); font-weight: 500; font-size: 13.5px; }
.ptable td:not(:first-child) { font-weight: 600; color: var(--gold); }
.ptable td[colspan] { text-align: center; }
.field-full { margin-bottom: 12px; }
.zones + .checks { margin-top: 0; }
.dur { font-size: 12.5px; color: var(--muted); margin: 0 8px; line-height: 1.35; }

/* ===== สวิตช์แพ็กเกจในหน้าตัวอย่าง (ชั้นหน้าตัวอย่าง: ไม่มีผลกับร้านจริง) ===== */
.demo-bar { flex-wrap: nowrap; gap: 8px; padding-left: 12px; padding-right: 12px; }
.demo-title { white-space: nowrap; }
.tier { display: inline-flex; background: rgba(255,255,255,.14); border-radius: 999px; padding: 3px; margin-left: auto; }
.tier button { border: 0; background: transparent; color: #fff; font: inherit; font-size: 13px; padding: 6px 12px; border-radius: 999px; cursor: pointer; min-height: 32px; white-space: nowrap; }
.tier button b { font-weight: 600; margin-left: 2px; }
.tier button[aria-pressed="true"] { background: #fff; color: #1d1d1d; }
.tier + .demo-explain { margin-left: 0; }
@media (max-width: 419px) {
  .tier button { font-size: 12px; padding: 6px 9px; }
  .demo-bar .demo-explain { font-size: 12.5px; padding: 6px 10px; }
}
body.tier-quick [data-tier="trust"] { display: none !important; }
body.tier-trust [data-tier="trust"] > .wrap::before {
  content: "+ มีใน Trust Page"; display: inline-block; grid-column: 1 / -1; justify-self: start;
  font-size: 12.5px; font-weight: 600; padding: 3px 10px; border-radius: 999px;
  background: #FFF0C2; color: #6B4E00; margin-bottom: 10px;
}

/* ===== ปรับเลย์เอาต์จอคอม (≥900px) ===== */
@media (min-width: 900px) {
  /* แถบปุ่มล่างใช้เฉพาะมือถือ จอคอมมีปุ่มบนหัวเว็บและส่วนบนสุดแล้ว */
  .dock { display: none !important; }
  body { padding-bottom: 0; }
  .toast { bottom: 32px; }

  /* ส่วนบนสุด: แถบจุดเด่นสูงเท่าช่องข้อมูล เรียงแนวตั้ง */
  .hero-card { align-items: stretch; }
  .hero-card .feats { align-self: stretch; grid-template-columns: 1fr; align-content: center; gap: 4px; padding: 14px 22px; }
  .hero-card .feats li { flex-direction: row; text-align: left; gap: 14px; padding: 8px 0; font-size: 14px; }
  .hero-card .feats li + li { border-top: 1px solid rgba(0,0,0,.06); }
  .hero-card .feats strong { font-size: 15px; }

  /* ฟอร์ม/ตัวคำนวณ: หัวข้อซ้าย ฟอร์มขวา */
  .split .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); column-gap: 56px; align-items: start; }
  .split .wrap > * { grid-column: 1; }
  .split .wrap > .book, .split .wrap > .calc, .split .wrap > .price-table { grid-column: 2; margin-top: 0; max-width: none; }
  .split .wrap > .book, .split .wrap > .calc { grid-row: 1 / span 6; }
  .split .wrap > .price-table { grid-row: 7; }
  body.tier-trust .split[data-tier="trust"] > .wrap::before { grid-column: 1; }

  /* รายการยาว ๆ ไม่ยืดเต็มจอ */
  .faq, .fullmenu, .sched-wrap { max-width: 820px; }
}

/* ===== เก็บระยะ ช่องไฟ ===== */
.dish { display: flex; flex-direction: column; }
.dish .ph { flex: none; }
.dish .price { margin-top: auto; }
.reviews blockquote { display: flex; flex-direction: column; }
.reviews blockquote footer { margin-top: auto; padding-top: 8px; }
.book-hint:empty { min-height: 0; margin: 0 0 16px; }
@media (min-width: 900px) {
  .hero-card .quick { align-self: stretch; display: flex; flex-direction: column; justify-content: space-around; }
  .zones + .btn-block { display: flex; width: max-content; margin-left: auto; margin-right: auto; padding: 0 28px; }
  .split .wrap > .faq { grid-column: 2; grid-row: 1 / span 6; margin-top: 0; max-width: none; }
  .fullmenu { max-width: none; }
}
@media (min-width: 900px) {
  .sched-wrap { max-width: none; }
  #gift .order-grid { grid-template-columns: 1fr 1fr; }
}
.dish .price { margin-top: 0; } /* สปามีคำอธิบายใต้ราคา ไม่ดันราคาลงล่าง */

/* จอคอม: เว้นระยะกล่องข้อมูลจากขอบรูปหัวเว็บ */
@media (min-width: 900px) { .hero-card .quick, .hero-card .feats { margin-top: 22px; } }
/* Quick: ซ่อนส่วนพื้นอ่อนที่คั่นกลาง ทำให้ส่วนพื้นขาวติดกัน ไม่ต้องเว้นซ้ำ */
body.tier-quick #rooms, body.tier-quick #hours-sec { padding-top: 0; }
