/* สไตล์ของเว็บไซต์สาธารณะ — รุ่นสาม
 *
 * ## หลักที่ยึดเหมือนเดิมทุกรุ่น
 *
 * เขียนแบบ mobile-first · หน้าต้องไม่มีการเลื่อนซ้ายขวา
 * ระยะห่างทุกค่ามาจากสเกลเดียว · ไม่ใช้ backdrop-filter (แลกความลื่นทั้งหน้า)
 *
 * ## อะไรที่เปลี่ยนในรุ่นสาม
 *
 * รุ่นสองออกแบบตอนหน้าเว็บยังไม่มีเนื้อหา ทุกอย่างจึงเน้น "ไม่ให้ดูเหมือน
 * ยังทำไม่เสร็จ" · ตอนนี้เจ้าของใส่ผลงานและข่าวจริงแล้ว หน้าเว็บจึงเปลี่ยน
 * บทบาทจาก "หน้ารอ" เป็น "หน้าร้าน" — รุ่นสามจึงเพิ่มมิติที่หน้าร้านต้องมี
 *
 *   มุมโค้งใหญ่ขึ้น (20–26px) และเงาสองชั้น ให้การ์ดลอยแยกชั้นจากพื้น
 *   ป้ายกำกับหัวข้อเป็นชิปมีพื้น ไม่ใช่ตัวหนังสือลอย ๆ
 *   การ์ดและรูปตอบสนองตอนชี้ (ยกขึ้นเบา ๆ หรือขยายรูปเล็กน้อย)
 *   ปุ่มหลักไล่เฉียงสองสีพร้อมเงารอบ ให้เด่นเหมือนปุ่มจริงบนหน้าจอสัมผัส
 *
 * ชื่อคลาสทั้งหมดคงเดิม — ตัววาดฝั่งเซิร์ฟเวอร์ไม่ต้องแก้ตาม
 */

:root {
  /* สเกลระยะห่าง — ทุกค่าในไฟล์นี้ต้องมาจากรายการนี้เท่านั้น */
  --s-1: 4px;
  --s-2: 8px;
  --s-3: 12px;
  --s-4: 16px;
  --s-5: 24px;
  --s-6: 32px;
  --s-7: 48px;
  --s-8: 64px;
  --s-9: 96px;

  /* โทนเดิมของกิจการ — กลางคืน + ไฟสัญญาณ */
  --night: #0b1f2a;
  --night-soft: #14303f;
  --night-deep: #071722;
  --signal: #f0a323;
  --signal-deep: #c47f10;
  --signal-glow: rgba(240, 163, 35, 0.28);
  --on-night: #eef4f7;
  --on-night-soft: #a9c0cc;

  --ink: #10222c;
  --ink-soft: #51666f;
  --brand: #14372e;
  --brand-deep: #0f2b24;
  --brand-bright: #1f5a49;
  --line: #e2ebe8;
  --line-strong: #c9d7d2;
  --bg: #ffffff;
  --soft: #f4f8f6;
  --soft-deep: #e9f1ee;

  --radius: 20px;
  --radius-lg: 26px;
  --radius-sm: 14px;

  --shadow-sm: 0 1px 2px rgba(16, 34, 44, 0.05);
  --shadow: 0 1px 2px rgba(16, 34, 44, 0.05),
            0 12px 32px -20px rgba(16, 34, 44, 0.4);
  --shadow-lift: 0 2px 4px rgba(16, 34, 44, 0.06),
                 0 24px 48px -24px rgba(16, 34, 44, 0.45);
  --shadow-glow: 0 8px 24px -8px var(--signal-glow);

  --shell: 1120px;
}

* { box-sizing: border-box; }

/* **ไม่ใช้ `overflow-x: hidden`** — กันล้นที่ต้นเหตุ ไม่ใช่ซ่อนมัน */
html, body { max-width: 100%; }

/* ตัวหนังสือยืดตามอุปกรณ์ — มือถือพอดีจอ จอคอมใหญ่ตามสัดส่วน
 *
 * ทุกขนาดฟอนต์ในไฟล์นี้เป็น rem ทั้งหมด การขยับค่าเดียวที่นี่
 * จึงปรับทั้งหน้าพร้อมกันโดยสัดส่วนยังเท่าเดิมทุกจุด
 */
html { font-size: 16px; }
@media (min-width: 640px)  { html { font-size: 16.25px; } }
@media (min-width: 960px)  { html { font-size: 16.75px; } }
@media (min-width: 1280px) { html { font-size: 17.25px; } }
@media (min-width: 1600px) { html { font-size: 17.5px; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  /* ใช้ rem ไม่ใช่ px — ให้บันได html font-size ด้านบนขยับย่อหน้าทั้งหน้าตามอุปกรณ์ */
  font: 1rem/1.75 "Noto Sans Thai", "Leelawadee UI", "Segoe UI", Tahoma, system-ui, sans-serif;
  overflow-wrap: anywhere;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand-bright); }

:focus-visible {
  outline: 3px solid var(--signal);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

.shell {
  width: 100%;
  max-width: var(--shell);
  margin: 0 auto;
  padding-inline: var(--s-4);
}

.skip { position: absolute; left: -9999px; }
.skip:focus {
  left: var(--s-2); top: var(--s-2); z-index: 40;
  background: #fff; padding: var(--s-3) var(--s-4);
  border-radius: var(--radius-sm); box-shadow: var(--shadow);
}

/* ป้ายกำกับหัวข้อ — รุ่นสามเป็นชิปมีพื้นแทนตัวหนังสือลอย */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0 0 var(--s-3);
  padding: var(--s-1) var(--s-3);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--signal-deep);
  background: rgba(240, 163, 35, 0.1);
  border: 1px solid rgba(240, 163, 35, 0.35);
  border-radius: 999px;
}
.eyebrow::before {
  content: "";
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--signal);
}

/* ---------------------------------------------------------------- ส่วนหัว */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
}

.header-row {
  display: flex;
  align-items: center;
  gap: var(--s-4);
  min-height: 72px;
}

.brand {
  display: flex; align-items: center; gap: var(--s-3);
  text-decoration: none; color: inherit; margin-inline-end: auto;
}
.brand-mark {
  display: grid; place-items: center;
  width: 44px; height: 44px; flex: 0 0 44px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--night) 0%, var(--night-soft) 100%);
  color: var(--signal);
  font-weight: 700; font-size: 1.15rem;
  box-shadow: inset 0 0 0 1px rgba(240, 163, 35, 0.4);
}
.brand-text { display: flex; flex-direction: column; line-height: 1.25; }
.brand-text strong { font-size: 1.02rem; letter-spacing: -0.01em; }
.brand-text small { color: var(--ink-soft); font-size: 0.76rem; }

.nav-desktop { display: none; gap: var(--s-2); }
.nav-desktop a {
  text-decoration: none; color: var(--ink-soft); font-weight: 600;
  padding: var(--s-2) var(--s-3);
  border-radius: 999px;
  transition: color 120ms ease, background-color 120ms ease;
}
.nav-desktop a:hover {
  color: var(--ink);
  background: var(--soft);
}

.header-login { display: none; }

/* ลิงก์หลังบ้านเว็บ — ทางเข้าของเจ้าของ แยกโทนทองจากลิงก์เจ้าหน้าที่ */
.header-login-admin {
  color: var(--signal-deep);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  border: 1px solid rgba(240, 163, 35, 0.4);
  border-radius: 999px;
  padding: var(--s-1) var(--s-3);
}
.header-login-admin:hover {
  border-color: var(--signal);
  background: rgba(240, 163, 35, 0.08);
}
@media (max-width: 959px) {
  .header-login-admin { display: none; }
}

/* เมนูหน้าจอเล็กใช้ `<details>` — ไม่มี JavaScript สักบรรทัด */
.menu { position: relative; }
.menu summary {
  list-style: none;
  display: flex; align-items: center; gap: var(--s-2);
  min-height: 44px; padding-inline: var(--s-4);
  border: 1px solid var(--line-strong); border-radius: 999px;
  cursor: pointer; font-weight: 600; color: var(--ink);
  transition: border-color 120ms ease;
}
.menu summary:hover { border-color: var(--signal); }
.menu summary::-webkit-details-marker { display: none; }
.menu-bars {
  width: 18px; height: 2px; background: currentColor; position: relative;
}
.menu-bars::before, .menu-bars::after {
  content: ""; position: absolute; left: 0;
  width: 18px; height: 2px; background: currentColor;
}
.menu-bars::before { top: -6px; }
.menu-bars::after { top: 6px; }
.menu-label { font-size: 0.9rem; }

.menu-panel {
  position: absolute; right: 0; top: calc(100% + var(--s-2));
  min-width: 248px;
  display: flex; flex-direction: column;
  padding: var(--s-2);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lift);
}
.menu-panel a {
  text-decoration: none; color: var(--ink);
  padding: var(--s-3); border-radius: var(--radius-sm);
  min-height: 44px; display: flex; align-items: center;
}
.menu-panel a:hover { background: var(--soft); }
.menu-login {
  margin-top: var(--s-2);
  border-top: 1px solid var(--line);
  color: var(--brand-bright) !important;
  font-weight: 700;
}

/* ---------------------------------------------------------------- ปุ่ม */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 52px; padding-inline: var(--s-6);
  border-radius: 999px;
  text-decoration: none; font-weight: 700;
  border: 1px solid transparent;
  transition: background-color 140ms ease, border-color 140ms ease,
              box-shadow 140ms ease, transform 140ms ease;
}
.btn-primary {
  background: linear-gradient(160deg, #f7b73f 0%, var(--signal) 45%, var(--signal-deep) 100%);
  color: #241800;
  box-shadow: var(--shadow-glow);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px -8px var(--signal-glow);
}
.btn-outline {
  border-color: rgba(238, 244, 247, 0.45);
  color: #fff;
}
.btn-outline:hover {
  border-color: #fff;
  background: rgba(238, 244, 247, 0.08);
}
.btn-ghost {
  border-color: var(--line-strong); color: var(--ink);
  min-height: 44px; padding-inline: var(--s-5);
  background: #fff;
}
.btn-ghost:hover { border-color: var(--brand); color: var(--brand); }

/* ---------------------------------------------------------------- ฮีโร่ */

.hero {
  background:
    radial-gradient(52% 44% at 88% 6%, rgba(240, 163, 35, 0.14) 0%, transparent 100%),
    radial-gradient(120% 90% at 12% 0%, var(--night-soft) 0%, transparent 58%),
    linear-gradient(160deg, var(--night) 0%, var(--night-deep) 100%);
  color: var(--on-night);
  padding: var(--s-8) 0 var(--s-9);
  position: relative;
  overflow: hidden;
}

/* ภาพรถจริงของกิจการเป็นพื้นหลังฮีโร่ — ทับด้วยชั้นมืดโทนเดิมของแบรนด์
 * มือถือเน้นอ่านง่าย (ชั้นมืดสม่ำเสมอ) จอกว้างค่อยเปิดให้เห็นรถด้านขวา
 * ถ้าภาพโหลดไม่ได้ พื้นไล่เฉียงของ .hero ยังทำหน้าที่เดิม */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(rgba(7, 23, 34, 0.88), rgba(7, 23, 34, 0.88)),
    url("/site/hero-bg.webp") center 62% / cover no-repeat;
}

@media (min-width: 1024px) {
  .hero::before {
    background:
      linear-gradient(
        100deg,
        rgba(7, 23, 34, 0.95) 0%,
        rgba(7, 23, 34, 0.82) 46%,
        rgba(7, 23, 34, 0.45) 100%
      ),
      url("/site/hero-bg.webp") center 62% / cover no-repeat;
  }
}

/* เส้นเฉียงสัญญาณที่ขอบล่าง — เอกลักษณ์ของกิจการ รุ่นสามหนาขึ้นเป็นสองชั้น */
.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 -1px 0;
  height: var(--s-7);
  background:
    linear-gradient(160deg, transparent 55%, rgba(240, 163, 35, 0.22) 55%),
    repeating-linear-gradient(
      135deg,
      rgba(240, 163, 35, 0.18) 0 var(--s-3),
      transparent var(--s-3) var(--s-5)
    );
  pointer-events: none;
}

.hero-inner {
  max-width: 58ch;
  position: relative;
  z-index: 1;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0 0 var(--s-4);
  padding: var(--s-1) var(--s-3);
  border: 1px solid rgba(240, 163, 35, 0.45);
  border-radius: 999px;
  color: var(--signal);
  font-weight: 700;
  letter-spacing: 0.05em;
  font-size: 0.88rem;
}
.hero-eyebrow::before {
  content: "";
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--signal);
  box-shadow: 0 0 0 4px rgba(240, 163, 35, 0.2);
}

.hero h1 {
  color: var(--on-night);
  font-size: clamp(1.9rem, 7vw, 3.1rem);
  line-height: 1.12;
  letter-spacing: -0.02em;
  margin: 0 0 var(--s-4);
  overflow-wrap: break-word;
}

.hero .lede {
  color: var(--on-night-soft);
  font-size: clamp(1.02rem, 2.6vw, 1.24rem);
  line-height: 1.8;
  margin: 0 0 var(--s-6);
}

.hero .cta-row { gap: var(--s-3); }

/* แถบข้อเท็จจริงใต้ปุ่มหลัก — ตัวเลขเด่นแบบเว็บหน้าร้าน แต่เป็นข้อเท็จจริง ไม่ใช่สถิติปลอม */
.hero-stats {
  list-style: none;
  margin: var(--s-7) 0 0;
  padding: var(--s-5) 0 0;
  border-top: 1px solid rgba(238, 244, 247, 0.16);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s-5) var(--s-4);
}
.hero-stats li { display: grid; gap: 2px; }
.hero-stats strong {
  font-size: 1.25rem;
  letter-spacing: -0.01em;
  color: var(--signal);
}
.hero-stats span { font-size: 0.86rem; color: var(--on-night-soft); }
@media (min-width: 960px) {
  .hero-stats { grid-template-columns: repeat(4, 1fr); }
}

/* การ์ดบริการพร้อมภาพหัว — ภาพมาจากแกลเลอรี่ของเจ้าของเองเท่านั้น */
.card-media {
  margin: calc(-1 * var(--s-6)) calc(-1 * var(--s-6)) var(--s-5);
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--soft);
}
.card-media img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 240ms ease;
}
.card:hover .card-media img { transform: scale(1.04); }
.card-body { display: grid; gap: var(--s-2); align-content: start; }
.card-body .link-arrow { margin-top: var(--s-1); }

/* ส่วนค่าบริการ — สี่ปัจจัยที่กำหนดราคา แทนตารางราคาที่เดาขึ้นเอง */
.pricing-grid {
  list-style: none;
  margin: 0 0 var(--s-6);
  padding: 0;
  display: grid;
  gap: var(--s-4);
  grid-template-columns: 1fr;
}
.pricing-item {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--s-5);
  box-shadow: var(--shadow-sm);
  display: grid;
  gap: var(--s-2);
  align-content: start;
  counter-increment: pricing;
  position: relative;
  padding-top: calc(var(--s-5) + 6px);
}
.pricing-item::before {
  counter-reset: none;
  content: counter(pricing, decimal-leading-zero);
  position: absolute;
  top: var(--s-4); right: var(--s-4);
  font-size: 1.6rem;
  font-weight: 800;
  color: rgba(240, 163, 35, 0.28);
  line-height: 1;
}
.pricing-item h3 {
  margin: 0;
  font-size: 1.05rem;
  display: flex; align-items: center; gap: var(--s-3);
}
.pricing-item h3::before {
  content: "";
  flex: 0 0 10px;
  width: 10px; height: 10px;
  border-radius: 3px;
  background: var(--signal);
  box-shadow: 0 0 0 4px rgba(240, 163, 35, 0.15);
}
.pricing-item p { margin: 0; color: var(--ink-soft); line-height: 1.7; }
@media (min-width: 640px) {
  .pricing-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
  .pricing-grid { grid-template-columns: repeat(4, 1fr); }
}
.pricing-grid { counter-reset: pricing; }

/* แถบชวนติดต่อท้ายหน้า — พื้นเดียวกับ hero ปิดเรื่องก่อนท้ายหน้า */
.cta-band {
  background:
    radial-gradient(52% 90% at 85% 10%, rgba(240, 163, 35, 0.14) 0%, transparent 100%),
    linear-gradient(160deg, var(--night) 0%, var(--night-deep) 100%);
  color: var(--on-night);
  border-top: 3px solid var(--signal);
  border-bottom: 3px solid var(--signal);
  margin-top: var(--s-6);
}
.cta-band-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-5);
  flex-wrap: wrap;
  padding-block: var(--s-7);
}
.cta-band h2 {
  margin: 0 0 var(--s-1);
  font-size: clamp(1.4rem, 3.6vw, 2rem);
  letter-spacing: -0.015em;
  color: #fff;
}
.cta-band p { margin: 0; color: var(--on-night-soft); }

.header-cta {
  padding: var(--s-2) var(--s-5);
  font-size: 0.95rem;
  min-height: 46px;
}

/* สถานะที่บอกความจริง — ไม่ใช่ที่ว่างให้เติมของปลอม */
.contact-pending {
  margin: var(--s-6) 0 0;
  padding: var(--s-4);
  border: 1px dashed rgba(255, 255, 255, 0.3);
  border-radius: var(--radius);
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.93rem;
  max-width: 60ch;
}

/* ------------------------------------------------------- เส้นทางนำกลับ */
.breadcrumb {
  padding-block: var(--s-4) 0;
  font-size: 0.9rem;
  color: var(--ink-soft);
}
.breadcrumb a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid transparent;
}
.breadcrumb a:hover,
.breadcrumb a:focus-visible { border-bottom-color: currentColor; }
.breadcrumb .shell {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.15rem;
  overflow-wrap: anywhere;
}

/* ---------------------------------------------------------------- ส่วนเนื้อ */
.section { padding-block: var(--s-8); }
.section-alt { background: var(--soft); }
.section h2 {
  margin: 0 0 var(--s-6);
  font-size: clamp(1.5rem, 4.2vw, 2.2rem);
  letter-spacing: -0.02em;
  line-height: 1.22;
}

.cards {
  display: grid; gap: var(--s-4);
  grid-template-columns: 1fr;
  list-style: none; margin: 0; padding: 0;
}
.card {
  position: relative;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--s-6);
  box-shadow: var(--shadow);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lift);
  border-color: var(--line-strong);
}
.card-index {
  display: block; margin-bottom: var(--s-3);
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.16em;
  color: var(--signal-deep);
}
.card h3 { margin: 0 0 var(--s-2); font-size: 1.15rem; letter-spacing: -0.01em; }
.card p { margin: 0; color: var(--ink-soft); }
.card h3 a { color: inherit; text-decoration: none; }
.card h3 a:hover { color: var(--brand-bright); }

/* ที่ว่างของผลงาน — ออกแบบให้รอภาพจริง ไม่ใช่ดูเหมือนทำไม่เสร็จ */
.gallery {
  display: grid; gap: var(--s-4);
  grid-template-columns: 1fr;
  margin-bottom: var(--s-4);
}
.gallery-slot {
  aspect-ratio: 4 / 3;
  border-radius: var(--radius);
  border: 1px solid var(--line-strong);
  background:
    repeating-linear-gradient(
      135deg,
      transparent 0 12px,
      rgba(20, 55, 46, 0.045) 12px 13px
    ),
    #fff;
}

.empty {
  background: #fff;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  padding: var(--s-4);
  color: var(--ink-soft);
  margin: 0;
}
.section-alt .empty { background: rgba(255, 255, 255, 0.7); }

/* ---------------------------------------------------------------- ข่าวสาร */
.news-list { display: grid; gap: var(--s-4); grid-template-columns: 1fr; }

.post-card {
  display: flex; flex-direction: column;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
/* `aspect-ratio` ตรึงพื้นที่ของรูปไว้ตั้งแต่ก่อนรูปมาถึง */
.post-media {
  aspect-ratio: 16 / 9;
  background: var(--soft);
  border-bottom: 1px solid var(--line);
}
.post-media img { width: 100%; height: 100%; object-fit: cover; }
.post-body { padding: var(--s-5); }
.post-body time {
  display: block; margin-bottom: var(--s-2);
  font-size: 0.82rem; font-weight: 600; letter-spacing: 0.04em;
  color: var(--signal-deep);
}
.post-body h3 {
  margin: 0 0 var(--s-2);
  font-size: 1.16rem; line-height: 1.35; letter-spacing: -0.01em;
}
.post-body p { margin: 0; color: var(--ink-soft); }

/* ข่าวบนหน้าแรก — มีรูปปกแล้ว จึงทำเป็นการ์ดที่ขยายรูปตอนชี้ */
.news-item {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--s-5);
  box-shadow: var(--shadow);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}
.news-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lift);
}
.news-item .post-media {
  margin: calc(-1 * var(--s-5)) calc(-1 * var(--s-5)) var(--s-4);
  aspect-ratio: 16 / 9;
  border-bottom: 0;
  border-radius: var(--radius) var(--radius) 0 0;
  overflow: hidden;
}
.news-item .post-media img {
  transition: transform 240ms ease;
}
.news-item:hover .post-media img { transform: scale(1.04); }
.news-item h3 {
  margin: 0 0 var(--s-2);
  font-size: 1.18rem; line-height: 1.35; letter-spacing: -0.01em;
}
.news-item h3 a { color: inherit; text-decoration: none; }
.news-item h3 a:hover { color: var(--signal-deep); }
.news-item p { margin: 0; color: var(--ink-soft); }
.news-date {
  font-size: 0.82rem; font-weight: 600; letter-spacing: 0.04em;
  color: var(--signal-deep);
  margin: 0 0 var(--s-2);
}

/* รูปปกของหน้าข่าวรายฉบับ */
.post-cover {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--soft);
  margin-bottom: var(--s-5);
}

/* ภาพผลงานจริง */
.gallery-item {
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line-strong);
  background: #fff;
  box-shadow: var(--shadow);
}
.gallery-item img {
  width: 100%;
  /* ภาพหน้างานเป็นภาพกว้าง — 16:10 เก็บทั้งรถบริการและรถลูกค้าที่ขอบภาพ */
  aspect-ratio: 16 / 10;
  object-fit: cover;
  background: var(--soft);
  display: block;
  transition: transform 240ms ease;
}
.gallery-item:hover img { transform: scale(1.04); }
.gallery-item figcaption {
  margin-top: 0;
  padding: var(--s-3) var(--s-4);
  font-size: 0.9rem;
  color: var(--ink-soft);
  line-height: 1.6;
}

/* ปุ่มพาไปหน้าแกลเลอรี่เต็มจากหน้าแรก */
.gallery-more { margin: 0 0 var(--s-2); }

/* ช่องทางติดต่อ */
.contact-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s-3); }
.contact-list li {
  display: grid; gap: var(--s-1);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: var(--s-4) var(--s-5);
  box-shadow: var(--shadow-sm);
  transition: border-color 140ms ease, box-shadow 140ms ease;
}
.contact-list li:hover { border-color: var(--signal); box-shadow: var(--shadow); }
.contact-list a {
  color: var(--brand-bright);
  font-weight: 600;
  text-decoration: none;
}
.contact-list a:hover { text-decoration: underline; }
.contact-label {
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--signal-deep);
}

/* ---------------------------------------------------------------- เกี่ยวกับ */
.about-grid { display: grid; gap: var(--s-6); grid-template-columns: 1fr; }
.about-grid p { color: var(--ink-soft); max-width: 62ch; }
.about-note {
  background: linear-gradient(160deg, var(--night) 0%, var(--night-soft) 100%);
  border-radius: var(--radius);
  padding: var(--s-6);
  color: var(--on-night);
  box-shadow: var(--shadow);
  align-self: start;
}
.about-note h3 {
  margin: 0 0 var(--s-3); font-size: 1.05rem; color: #fff;
  display: flex; align-items: center; gap: var(--s-2);
}
.about-note h3::before {
  content: "";
  width: 22px; height: 4px;
  border-radius: 999px;
  background: var(--signal);
}
.about-note p { margin: 0 0 var(--s-4); color: var(--on-night-soft); }
.link-arrow {
  display: inline-flex; align-items: center; gap: var(--s-2);
  min-height: 44px; font-weight: 700; text-decoration: none;
}
.link-arrow::after { content: "→"; transition: transform 140ms ease; }
.link-arrow:hover::after { transform: translateX(4px); }

/* ---------------------------------------------------------------- ท้ายหน้า */
.site-footer {
  background:
    radial-gradient(60% 80% at 90% 0%, rgba(240, 163, 35, 0.07) 0%, transparent 100%),
    var(--night-deep);
  color: rgba(238, 244, 247, 0.82);
  padding-block: var(--s-8) var(--s-5);
  margin-top: var(--s-6);
  border-top: 3px solid var(--signal);
}
.footer-grid {
  display: grid; gap: var(--s-6);
  grid-template-columns: 1fr;
  padding-bottom: var(--s-6);
  border-bottom: 1px solid rgba(238, 244, 247, 0.14);
}
.footer-brand { margin: 0 0 var(--s-1); font-weight: 700; color: #fff; font-size: 1.05rem; }
.footer-nav { display: flex; flex-direction: column; gap: var(--s-2); }
.footer-nav a, .footer-systems a {
  color: var(--on-night); text-decoration: none;
  min-height: 44px; display: inline-flex; align-items: center;
}
.footer-nav a:hover, .footer-systems a:hover { text-decoration: underline; }
.footer-systems .fine { margin: 0 0 var(--s-1); }
.footer-legal { padding-top: var(--s-4); }
.fine { font-size: 0.86rem; color: rgba(238, 244, 247, 0.55); margin: 0; }
.section .fine { color: var(--ink-soft); }

/* ---------------------------------------------------------------- จอกลาง */
@media (min-width: 640px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .gallery { grid-template-columns: repeat(3, 1fr); }
  .news-list { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1.4fr 1fr 1.6fr; }
}

/* ---------------------------------------------------------------- จอกว้าง */
@media (min-width: 960px) {
  /* จอ 960-1200 ยังใช้เมนูแฮมเบอร์เกอร์ — พื้นที่ไม่พอให้เมนูเต็มประกอบปุ่มโทร
     และลิงก์เข้าระบบพร้อมกัน เคยทำให้ปุ่มกับลิงก์ตกบรรทัดซ้อนกันเป็นชั้น */
  .header-login {
    display: inline-flex;
    font-size: 0.75rem;
    white-space: nowrap;
    opacity: 0.72;
    transition: opacity 160ms ease;
  }
  .header-login:hover, .header-login:focus-visible { opacity: 1; }
  .header-cta { white-space: nowrap; }

  .hero-inner { padding-block: var(--s-9) var(--s-8); }
  .section { padding-block: var(--s-9); }
  .hero h1 { font-size: clamp(2.5rem, 3.6vw, 3.2rem); }
  .section h2 { font-size: clamp(1.75rem, 2.2vw, 2.1rem); }
  .hero .lede { font-size: clamp(1.08rem, 1.2vw, 1.26rem); max-width: 62ch; }
  .lede { font-size: 1.08rem; }
  .card h3 { font-size: 1.18rem; }
  .card p, .usecase p, .step p, .trust-item p { font-size: 1rem; }
  .hero-stats strong { font-size: 1.35rem; }
  .cards { grid-template-columns: repeat(3, 1fr); }
  .news-list { grid-template-columns: repeat(3, 1fr); }
  .about-grid { grid-template-columns: 1.6fr 1fr; gap: var(--s-8); }
}

/* เมนูลอยเต็มแถบเริ่มที่ 1200px ขึ้นไป — แบรนด์ชิดซ้าย เมนูกลาง ปุ่มโทรชิดขวา
   ทุกลิงก์ห้ามตัดคำ จึงไม่มีข้อความตกบรรทัดซ้อนกันได้อีก */
@media (min-width: 1200px) {
  .brand { margin-inline-end: 0; }
  .nav-desktop {
    display: flex;
    gap: var(--s-4);
    margin-inline: auto;
  }
  .nav-desktop a {
    padding: var(--s-2) var(--s-3);
    font-size: 0.92rem;
    white-space: nowrap;
  }
  .menu { display: none; }
  .header-row { gap: var(--s-5); max-width: 1360px; }
  .header-login { font-size: 0.78rem; }
}

/* คนที่ตั้งค่าให้ลดการเคลื่อนไหว ต้องได้หน้าที่นิ่งจริง */
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
  .card:hover, .news-item:hover { transform: none; }
}

/* ============================================================================
 * รุ่นสาม — ส่วนเสริมของหน้าร้าน
 * ========================================================================== */

/* ------------------------------------------------------------ แถบความน่าเชื่อถือ */
.trust {
  padding-block: var(--s-6);
  background:
    radial-gradient(70% 100% at 50% 0%, rgba(240, 163, 35, 0.05) 0%, transparent 100%),
    var(--soft);
  border-bottom: 1px solid var(--line);
}
.trust-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--s-4);
  grid-template-columns: 1fr;
}
.trust-item {
  position: relative;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--s-5);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: transform 160ms ease, box-shadow 160ms ease;
}
.trust-item::before {
  content: "";
  position: absolute;
  left: 0; top: 0;
  width: 4px; height: 100%;
  background: linear-gradient(180deg, var(--signal) 0%, var(--signal-deep) 100%);
}
.trust-item:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.trust-item h3 {
  margin: 0 0 var(--s-1);
  font-size: 1.02rem;
}
.trust-item p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.95rem;
  line-height: 1.7;
}

/* ------------------------------------------------------------------ บริการ */
.card-icon {
  display: grid;
  place-items: center;
  width: var(--s-7);
  height: var(--s-7);
  margin-bottom: var(--s-4);
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, #f7b73f 0%, var(--signal) 45%, var(--signal-deep) 100%);
  box-shadow: var(--shadow-glow);
}
.card-icon::after {
  content: "";
  width: 18px; height: 18px;
  border-radius: 4px;
  border: 3px solid rgba(36, 24, 0, 0.82);
  border-bottom: 0;
  border-right: 0;
  transform: translateY(2px) rotate(45deg);
}

/* ---------------------------------------------------------- เหมาะกับงานแบบไหน */
.usecase-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--s-4);
  grid-template-columns: 1fr;
}
.usecase {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--s-5);
  transition: transform 160ms ease, box-shadow 160ms ease;
}
.usecase:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.usecase h3 {
  margin: 0 0 var(--s-2);
  font-size: 1.05rem;
  display: flex; align-items: center; gap: var(--s-3);
}
.usecase h3::before {
  content: "";
  flex: 0 0 10px;
  width: 10px; height: 10px;
  border-radius: 3px;
  background: var(--signal);
  box-shadow: 0 0 0 4px rgba(240, 163, 35, 0.15);
}
.usecase p {
  margin: 0;
  color: var(--ink-soft);
  line-height: 1.7;
}

/* ------------------------------------------------------------------ ขั้นตอน */
.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--s-5);
  grid-template-columns: 1fr;
  counter-reset: step;
}
.step {
  position: relative;
  padding-left: calc(var(--s-7) + var(--s-4));
}
.step-num {
  position: absolute;
  left: 0;
  top: 0;
  width: var(--s-7);
  height: var(--s-7);
  border-radius: 14px;
  background: linear-gradient(160deg, var(--night) 0%, var(--night-soft) 100%);
  color: var(--signal);
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 1.05rem;
  box-shadow: inset 0 0 0 1px rgba(240, 163, 35, 0.4);
}
.step h3 {
  margin: 0 0 var(--s-1);
  font-size: 1.05rem;
  padding-top: var(--s-2);
}
.step p {
  margin: 0;
  color: var(--ink-soft);
  line-height: 1.7;
}

/* -------------------------------------------------------- งานที่กำลังดำเนินการ */
.activity-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--s-4);
  grid-template-columns: 1fr;
}
.activity-item {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  padding: 0 0 var(--s-4);
  box-shadow: var(--shadow);
  transition: transform 160ms ease, box-shadow 160ms ease;
}
.activity-item:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.activity-media {
  aspect-ratio: 16 / 10;
  background: var(--soft);
}
.activity-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.activity-status {
  display: inline-block;
  margin: var(--s-4) var(--s-4) var(--s-2);
  padding: var(--s-1) var(--s-3);
  border-radius: 999px;
  background: var(--night);
  color: var(--signal);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}
.activity-item h3 {
  margin: 0 var(--s-4) var(--s-1);
  font-size: 1.05rem;
}
.activity-item p {
  margin: 0 var(--s-4) var(--s-2);
  color: var(--ink-soft);
  line-height: 1.7;
}
.activity-meta,
.activity-date {
  font-size: 0.9rem;
}
.activity-date {
  color: var(--ink-soft);
  opacity: 0.85;
}

/* ------------------------------------------------------------ คำถามที่พบบ่อย */
.faq {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--s-3);
}
.faq-item {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--s-5);
  box-shadow: var(--shadow-sm);
}
.faq-item h3 {
  margin: 0 0 var(--s-2);
  font-size: 1.02rem;
  display: flex; align-items: baseline; gap: var(--s-3);
}
.faq-item h3::before {
  content: "ถาม";
  flex: 0 0 auto;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--signal-deep);
  background: rgba(240, 163, 35, 0.12);
  border: 1px solid rgba(240, 163, 35, 0.35);
  border-radius: 999px;
  padding: 2px 10px;
  transform: translateY(-2px);
}
.faq-item p {
  margin: 0;
  color: var(--ink-soft);
  line-height: 1.75;
}


/* ------------------------------------------------------ ตารางเทียบสไลด์/ยก */
.compare {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: #fff;
  box-shadow: var(--shadow);
  margin-bottom: var(--s-6);
}
.compare-row {
  display: grid;
  grid-template-columns: 1fr;
  border-bottom: 1px solid var(--line);
}
.compare-row:last-child { border-bottom: 0; }
.compare-head {
  background: linear-gradient(160deg, var(--night) 0%, var(--night-soft) 100%);
  color: var(--on-night);
  font-weight: 700;
}
.compare-head .compare-cell:nth-child(2) { color: var(--signal); }
.compare-cell {
  padding: var(--s-4) var(--s-5);
  font-size: 0.95rem;
  line-height: 1.7;
  border-bottom: 1px dashed var(--line);
}
.compare-cell:last-child { border-bottom: 0; }
.compare-label {
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--signal-deep);
  background: rgba(240, 163, 35, 0.06);
}
.compare-head .compare-label {
  color: var(--on-night-soft);
  background: transparent;
}
@media (min-width: 720px) {
  .compare-row { grid-template-columns: 200px 1fr 1fr; }
  .compare-cell { border-bottom: 0; border-right: 1px solid var(--line); }
  .compare-cell:last-child { border-right: 0; }
}

/* ------------------------------------------------------------- วิซาร์ด */
.wizard {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow);
  padding: var(--s-6);
}
.wizard-step h3 { margin: 0 0 var(--s-4); font-size: 1.08rem; }
.wizard-options {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-3);
  margin-bottom: var(--s-5);
}
.wizard-opt {
  border: 1px solid var(--line-strong);
  background: #fff;
  border-radius: 999px;
  padding: var(--s-2) var(--s-4);
  min-height: 44px;
  font: inherit;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
  transition: border-color 120ms ease, background-color 120ms ease;
}
.wizard-opt:hover { border-color: var(--signal); }
.wizard-opt.picked {
  background: var(--night);
  border-color: var(--night);
  color: var(--signal);
}
.wizard-opt[disabled] { cursor: default; opacity: 0.55; }
.wizard-opt.picked[disabled] { opacity: 1; }
.wizard-result {
  border-top: 1px solid var(--line);
  padding-top: var(--s-5);
}
.wizard-verdict { margin: 0 0 var(--s-2); font-size: 1.2rem; font-weight: 800; }
.wizard-note { margin: 0 0 var(--s-4); color: var(--ink-soft); }

/* ------------------------------------------------------------------ ผลงาน */
.gallery-lead {
  margin: 0 0 var(--s-4);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}
.gallery-lead img {
  width: 100%;
  height: auto;
  display: block;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}
.gallery-lead figcaption {
  padding: var(--s-4) var(--s-5);
  color: var(--ink-soft);
  font-size: 0.95rem;
  background: #fff;
}

/* ------------------------------------------------------------------ ท้ายหน้า */
.footer-about .footer-brand {
  margin-bottom: var(--s-1);
}
.footer-cta {
  display: inline-block;
  margin-bottom: var(--s-2);
  font-weight: 700;
  color: var(--signal);
}

/* ------------------------------------------------------ แถบติดต่อติดหน้าจอ */
/*
   ลอยเป็นแคปซูลเหนือขอบล่าง — ทันสมัยกว่าแถบเต็มความกว้างและไม่บัง
   ปุ่มสัมผัสของระบบปฏิบัติการ ยังไม่ใช้ backdrop-filter ตามหลักของไฟล์นี้
*/
.call-bar {
  position: fixed;
  left: var(--s-3);
  right: var(--s-3);
  bottom: calc(var(--s-3) + env(safe-area-inset-bottom, 0px));
  z-index: 30;
  display: flex;
  gap: var(--s-2);
  padding: var(--s-2);
  background: var(--night);
  border: 1px solid rgba(240, 163, 35, 0.35);
  border-radius: 999px;
  box-shadow: var(--shadow-lift);
}

.call-bar-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding-inline: var(--s-3);
  border-radius: 999px;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.call-bar-phone {
  background: linear-gradient(160deg, #f7b73f 0%, var(--signal) 45%, var(--signal-deep) 100%);
  color: #241800;
}

.call-bar-phone:hover {
  background: linear-gradient(160deg, var(--signal) 0%, var(--signal-deep) 100%);
  color: #1a1200;
}

.call-bar-line {
  background: var(--night-soft);
  color: var(--on-night);
  border: 1px solid rgba(238, 244, 247, 0.3);
}

.call-bar-line:hover {
  border-color: var(--on-night);
}

/* แถบลอยเหนือท้ายหน้า — ท้ายหน้าต้องมีที่ว่างให้เนื้อหาบรรทัดสุดท้าย */
.site-footer {
  padding-bottom: calc(var(--s-8) + 96px);
}

/* ------------------------------------------------------------------ จอกว้าง */

@media (min-width: 640px) {
  /* จอกว้างพอที่ปุ่มบนแถบหัวเว็บมองเห็นได้ตลอด แถบลอยจึงเป็นแค่ที่กินพื้นที่ */
  .call-bar { display: none; }
  .site-footer { padding-bottom: var(--s-5); }

  .trust-grid,
  .usecase-grid,
  .activity-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .steps {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1280px) {
  :root { --shell: 1200px; }
  .section { padding-block: var(--s-9); }
}

@media (min-width: 1024px) {
  .trust-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .usecase-grid,
  .activity-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .steps {
    grid-template-columns: repeat(4, 1fr);
  }

  .hero {
    padding: var(--s-9) 0;
  }
}
