/*
 * MSTX — Industrial Luxury
 * สีหลัก: Graphite / Off-white / Cobalt Blue
 * Graphite = ตัวหลัก, Off-white = พื้นหลัง, Cobalt = CTA / ข้อมูลเทคนิค / เส้นกราฟิก
 * แดง MSTX ใช้เฉพาะจุดเล็กมาก ๆ (โลโก้, จุดในแถบบน, เครื่องหมาย * ช่องบังคับ)
 * สโลแกน MACHINING SOLUTION & TOOLING EXCELLENCE ใช้คลาส .tagline ที่เดียวทั้งเว็บ
 * ตัวเลขราคาใช้ Cobalt Blue สีเดียวทั้งเว็บ (.price-value)
 */
:root {
  --graphite: #1d2024;
  --graphite-2: #2a2e33;
  --graphite-3: #3b4046;
  --ink: #1d2024;
  --muted: #676b70;
  --faint: #9a9da1;
  --paper: #f6f4ef;
  --paper-2: #efece5;
  --white: #fdfcfa;
  --line: #e2ded5;
  --line-dark: #ffffff1f;
  --cobalt: #0047ab;
  --cobalt-dark: #00398a;
  --cobalt-tint: #e8eef8;
  --cobalt-light: #8fb2ea;
  --red: #a41f2c;
  --sans: "IBM Plex Sans Thai", "IBM Plex Sans", "Noto Sans Thai", Tahoma, sans-serif;
  --latin: "IBM Plex Sans", "IBM Plex Sans Thai", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --ease: cubic-bezier(.2, .7, .2, 1);
  font-family: var(--sans);
  color: var(--ink);
  background: var(--paper);
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; background: var(--paper); line-height: 1.7; font-weight: 400; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
button, input, select, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; height: auto; }
svg { display: block; }
[hidden] { display: none !important; }
::selection { background: var(--cobalt); color: #fff; }
:focus-visible { outline: 2px solid var(--cobalt); outline-offset: 3px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; left: 12px; top: 12px; z-index: 60; padding: 10px 18px; background: var(--white); transform: translateY(-160%); }
.skip-link:focus { transform: translateY(0); }
.container { width: min(1200px, calc(100% - 64px)); margin-inline: auto; }
.muted { color: var(--muted); }
.text-link { color: var(--cobalt); font-weight: 500; border-bottom: 1px solid currentColor; padding-bottom: 1px; }
.text-link:hover { color: var(--cobalt-dark); }
.icon { width: 20px; height: 20px; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
[id] { scroll-margin-top: 110px; }

/* ราคา: ตัวเลขเป็น Cobalt Blue เสมอ */
.price { display: flex; align-items: baseline; flex-wrap: wrap; gap: 6px; margin: 0; }
.price small { color: var(--muted); font-size: .76rem; }
.price-value { color: var(--cobalt); font: 500 1.35rem/1.1 var(--latin); letter-spacing: -.01em; font-variant-numeric: tabular-nums lining-nums; }
.price-ask { color: var(--muted); font-size: .82rem; letter-spacing: .02em; }

/* ---------- แถบบนและเมนู ---------- */
.utility-bar { background: var(--graphite); color: #d9d6cf; font-size: .76rem; }
.utility-inner { min-height: 38px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.utility-left { display: inline-flex; align-items: center; gap: 10px; font: 500 .66rem var(--latin); letter-spacing: .2em; text-transform: uppercase; }
.utility-left::before { content: ""; width: 6px; height: 6px; background: var(--red); }
.utility-right { display: inline-flex; align-items: center; gap: 14px; white-space: nowrap; font-family: var(--latin); letter-spacing: .02em; }
.utility-right a:hover { color: #fff; }
.utility-divider { height: 12px; width: 1px; background: #ffffff33; }
.utility-right a[hidden] + .utility-divider { display: none; }

.site-header { position: sticky; top: 0; z-index: 30; background: var(--white); background: color-mix(in srgb, var(--white) 94%, transparent); backdrop-filter: saturate(1.2) blur(10px); -webkit-backdrop-filter: saturate(1.2) blur(10px); border-bottom: 1px solid var(--line); }
.header-inner { min-height: 92px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: block; width: clamp(190px, 20vw, 250px); flex: 0 0 auto; }
.brand img { width: 100%; mix-blend-mode: multiply; }
.primary-nav { display: flex; align-items: center; gap: 4px; }
.primary-nav a { position: relative; min-height: 44px; display: inline-flex; align-items: center; padding: 0 16px; font-weight: 400; font-size: .92rem; letter-spacing: .01em; white-space: nowrap; color: var(--graphite-3); transition: color .25s var(--ease); }
.primary-nav a::after { content: ""; position: absolute; left: 16px; right: 16px; bottom: 6px; height: 1px; background: var(--cobalt); transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease); }
.primary-nav a:hover { color: var(--graphite); }
.primary-nav a:hover::after, .primary-nav a.is-active::after { transform: scaleX(1); }
.primary-nav a.is-active { color: var(--graphite); font-weight: 500; }
.primary-nav a.nav-cta { margin-left: 18px; padding: 0 22px; color: #fff; background: var(--graphite); font-weight: 500; }
.primary-nav a.nav-cta::after { display: none; }
.primary-nav a.nav-cta:hover { background: var(--cobalt); }
.menu-toggle { display: none; width: 44px; height: 44px; padding: 12px 10px; border: 1px solid var(--line); background: transparent; cursor: pointer; }
.menu-toggle span { display: block; height: 1.5px; margin: 5px 0; background: var(--graphite); }

/* ---------- ปุ่มและหัวข้อ ---------- */
.button { display: inline-flex; align-items: center; justify-content: space-between; gap: 28px; min-height: 52px; padding: 10px 24px; border: 1px solid transparent; font-weight: 500; font-size: .9rem; letter-spacing: .02em; cursor: pointer; transition: background .3s var(--ease), color .3s var(--ease), border-color .3s var(--ease); }
.button span { font-family: var(--latin); font-weight: 300; font-size: 1.15rem; line-height: 1; transition: transform .3s var(--ease); }
.button:hover span { transform: translateX(4px); }
.button-primary { background: var(--cobalt); color: #fff; }
.button-primary:hover { background: var(--cobalt-dark); }
.button-dark { background: var(--graphite); color: #fff; }
.button-dark:hover { background: var(--cobalt); }
.button-light { background: var(--white); color: var(--graphite); }
.button-light:hover { background: #fff; color: var(--cobalt); }
.button-outline { border-color: #ffffff66; color: #fff; }
.button-outline:hover { border-color: #fff; background: #ffffff14; }
.button-ghost { border-color: var(--graphite); color: var(--graphite); background: transparent; }
.button-ghost:hover { background: var(--graphite); color: #fff; }

.eyebrow { margin: 0 0 22px; display: flex; align-items: center; gap: 14px; color: var(--muted); font: 400 .7rem var(--mono); letter-spacing: .18em; text-transform: uppercase; }
.eyebrow-line { display: inline-block; width: 18px; height: 1px; background: var(--cobalt); }
.eyebrow-light .eyebrow-line { background: var(--cobalt-light); }

/* สโลแกนบริษัท — รูปแบบเดียวทั้งเว็บ: ตัวพิมพ์ใหญ่ เว้นวรรครอบ & ระยะตัวอักษรกว้าง */
.tagline { margin: 0; font: 500 .72rem/1.6 var(--latin); letter-spacing: .22em; text-transform: uppercase; color: var(--graphite-3); }
.tagline-light { color: #d6d3cc; }
.eyebrow-light { color: #c9c6bf; }

.section { padding: 128px 0; }
.section-soft { background: var(--white); }
.section-dark { color: #f1efea; background: var(--graphite); }
.section h2, .page-section h2 { margin: 0; font-size: clamp(2rem, 3.2vw, 3rem); font-weight: 500; line-height: 1.25; letter-spacing: -.025em; }
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 48px; margin-bottom: 56px; padding-bottom: 28px; border-bottom: 1px solid var(--line); }
.section-dark .section-head { border-color: var(--line-dark); }
.section-head > p { max-width: 380px; margin: 0; color: var(--muted); font-size: .95rem; }
.section-dark .section-head > p { color: #a9a8a3; }
.section-head-center { justify-content: center; text-align: center; border: 0; padding-bottom: 0; }
.section-head-center .eyebrow { justify-content: center; }

/* ---------- หน้าแรก: hero ---------- */
.hero { position: relative; min-height: min(86vh, 820px); display: flex; flex-direction: column; justify-content: center; overflow: hidden; color: #fff; background: var(--graphite); }
.hero-image, .hero-shade { position: absolute; inset: 0; }
.hero-image { background: url("assets/hero-machining.jpg") 70% 49% / cover no-repeat; filter: saturate(.2) contrast(1.08) brightness(.95); }
.hero-shade { background: linear-gradient(90deg, #15171a 0%, #15171aeb 32%, #1d20248c 60%, #1d202426 100%), linear-gradient(0deg, #15171acc, transparent 35%); }
.hero-graphic { position: absolute; right: 6%; top: 50%; width: min(46vw, 620px); transform: translateY(-54%); fill: none; stroke: var(--cobalt-light); stroke-width: .8; opacity: .55; pointer-events: none; }
.hero-graphic-mark { stroke: #fff; stroke-width: 1.2; opacity: .8; }
.hero-graphic-dim { stroke: var(--cobalt-light); stroke-width: 1.4; }
.hero-content { position: relative; z-index: 1; padding: 96px 0 160px; }
.hero .tagline { display: flex; align-items: center; gap: 14px; margin-bottom: 36px; }
.hero .tagline::before { content: ""; flex: 0 0 auto; width: 6px; height: 6px; background: var(--red); }
.hero h1 { max-width: 760px; margin: 0; font-size: clamp(2.6rem, 5.2vw, 4.8rem); font-weight: 500; line-height: 1.12; letter-spacing: -.035em; text-wrap: balance; }
.hero h1 em { font-style: normal; color: var(--cobalt-light); white-space: nowrap; }
.hero-subtitle { max-width: 520px; margin: 28px 0 44px; font-size: clamp(1rem, 1.3vw, 1.12rem); font-weight: 300; line-height: 1.9; color: #c9c6bf; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.hero-index { position: absolute; left: 0; right: 0; bottom: 0; z-index: 1; border-top: 1px solid #ffffff1f; background: #15171a99; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.hero-index-inner { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); }
.hero-index a { display: flex; align-items: baseline; gap: 12px; padding: 22px 0; color: #d6d3cc; font: 500 .74rem var(--latin); letter-spacing: .18em; transition: color .25s var(--ease); }
.hero-index a + a { padding-left: 24px; border-left: 1px solid #ffffff1f; }
.hero-index small { color: var(--cobalt-light); font: 400 .68rem var(--mono); letter-spacing: .08em; }
.hero-index a:hover { color: #fff; }

/* แถบเครื่องมือหลัก (ภาพระยะใกล้ 5 ช่อง) */
.showcase { background: var(--white); border-bottom: 1px solid var(--line); }
.showcase-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1px; background: var(--line); border-inline: 1px solid var(--line); }
.showcase-item { position: relative; display: block; overflow: hidden; background: var(--white); }
.showcase-item img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; filter: saturate(.15) contrast(1.05); transition: transform .7s var(--ease), filter .5s var(--ease); }
.showcase-item:hover img { transform: scale(1.05); filter: saturate(.6) contrast(1.05); }
.showcase-item span { position: absolute; left: 0; right: 0; bottom: 0; display: flex; flex-direction: column; padding: 28px 20px 18px; background: linear-gradient(0deg, #fdfcfaf2 45%, #fdfcfa00); color: var(--graphite); font-size: .92rem; font-weight: 500; }
.showcase-item small { color: var(--cobalt); font: 500 .66rem var(--latin); letter-spacing: .2em; }

/* ตัวเลขข้อมูลบริษัท (นับจาก data.js) */
.figures { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 0 0 40px; border-top: 1px solid var(--graphite); }
.figures div { display: flex; flex-direction: column; padding: 20px 0 0; }
.figures div + div { padding-left: 24px; border-left: 1px solid var(--line); }
.figures dt { order: 2; color: var(--muted); font-size: .8rem; }
.figures dd { margin: 0 0 4px; color: var(--cobalt); font: 500 2.2rem/1.1 var(--latin); letter-spacing: -.02em; font-variant-numeric: tabular-nums; }

/* แคตตาล็อกเล่มหลักบนหน้าแรก */
.catalog-feature { color: #fff; background: var(--graphite); }
.catalog-feature-inner { display: grid; grid-template-columns: 240px 1fr; gap: 72px; align-items: center; padding: 96px 0; }
.catalog-feature-cover { display: block; background: #fff; box-shadow: 0 30px 50px -24px #000c; transition: transform .45s var(--ease); }
.catalog-feature-cover:hover { transform: translateY(-6px); }
.catalog-feature h2 { margin: 0; font-size: clamp(1.8rem, 3vw, 2.6rem); font-weight: 500; line-height: 1.3; letter-spacing: -.025em; }
.catalog-feature-meta { max-width: 620px; margin: 16px 0 36px; color: #b9b7b1; font-weight: 300; line-height: 1.9; }

/* ---------- หมวดสินค้า ---------- */
.category-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.category-card { position: relative; display: flex; flex-direction: column; min-width: 0; background: var(--white); transition: background .3s var(--ease); }
.category-card:hover { background: #fff; }
.category-photo { display: block; aspect-ratio: 1; overflow: hidden; background: #efede8; }
.category-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.category-card:hover .category-photo img { transform: scale(1.04); }
.category-body { display: flex; flex-direction: column; gap: 4px; padding: 22px 56px 26px 24px; }
.category-body small { color: var(--faint); font: 400 .66rem var(--mono); letter-spacing: .12em; text-transform: uppercase; }
.category-body strong { font-size: 1.08rem; font-weight: 500; line-height: 1.45; }
.category-body > span { color: var(--muted); font-size: .8rem; line-height: 1.55; }
.category-grid-compact { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.category-grid-compact .category-body { padding: 16px 16px 20px; }
.category-grid-compact .category-body strong { font-size: .92rem; }
.category-grid-compact .category-body small { font-size: .6rem; }
.category-arrow { position: absolute; right: 22px; bottom: 26px; color: var(--graphite); font: 300 1.2rem var(--latin); transition: transform .3s var(--ease), color .3s var(--ease); }
.category-card:hover .category-arrow { color: var(--cobalt); transform: translateX(4px); }

/* ---------- เกี่ยวกับเรา (แบบแบ่งสองฝั่ง) ---------- */
.split { display: grid; grid-template-columns: 1.05fr .95fr; gap: 96px; align-items: center; }
.split-media { position: relative; margin: 0; }
.split-media img { width: 100%; aspect-ratio: 4 / 4.4; object-fit: cover; filter: saturate(.55); }
.split-media figcaption { position: absolute; left: 0; bottom: 0; max-width: 100%; padding: 18px 24px; color: #fff; background: var(--graphite); border-left: 2px solid var(--cobalt); }
.split-copy h2 span { color: var(--cobalt); }
.split-copy > p { margin: 28px 0; color: #45494e; line-height: 2; font-weight: 300; }
.check-list { margin: 0 0 40px; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.check-list li { position: relative; padding: 14px 0 14px 34px; border-bottom: 1px solid var(--line); font-size: .93rem; }
.check-list li::before { content: ""; position: absolute; left: 2px; top: 23px; width: 14px; height: 1px; background: var(--cobalt); }

/* ---------- จุดเด่น ---------- */
.feature-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--line); }
.feature-card { padding: 40px 32px 8px 0; }
.feature-card + .feature-card { padding-left: 32px; border-left: 1px solid var(--line); }
.feature-number { color: var(--faint); font: 400 .78rem var(--mono); letter-spacing: .1em; }
.feature-card h3 { margin: 22px 0 12px; font-size: 1.12rem; font-weight: 500; line-height: 1.45; }
.feature-card p { margin: 0; color: var(--muted); font-size: .88rem; line-height: 1.85; font-weight: 300; }

/* ---------- อุตสาหกรรม ---------- */
.industry-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; background: var(--line-dark); border: 1px solid var(--line-dark); }
.industry-card { display: grid; grid-template-columns: 44px 1fr; column-gap: 20px; align-items: start; padding: 34px 30px; background: var(--graphite); transition: background .3s var(--ease); }
.industry-card:hover { background: var(--graphite-2); }
.industry-card svg { grid-row: span 2; width: 40px; height: 40px; fill: none; stroke: var(--cobalt-light); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.industry-card strong { font-size: 1.05rem; font-weight: 500; line-height: 1.45; }
.industry-card span { margin-top: 6px; color: #a9a8a3; font-size: .84rem; line-height: 1.7; font-weight: 300; }

/* ---------- ขั้นตอนสั่งซื้อ ---------- */
.process-list { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; margin: 0; padding: 0; list-style: none; }
.process-list li { position: relative; padding: 0 32px 0 0; }
.process-list li::before { content: ""; position: absolute; left: 52px; right: 20px; top: 20px; height: 1px; background: var(--line); }
.process-list li:last-child::before { display: none; }
.process-list span { position: relative; display: grid; place-items: center; width: 40px; height: 40px; margin-bottom: 28px; color: var(--cobalt); border: 1px solid var(--cobalt); font: 400 .85rem var(--mono); }
.process-list strong { display: block; font-size: 1.08rem; font-weight: 500; }
.process-list p { margin: 10px 0 0; color: var(--muted); font-size: .88rem; line-height: 1.85; font-weight: 300; }

/* ---------- แถบแคตตาล็อก / CTA ---------- */
.catalog-band { color: #fff; background: linear-gradient(90deg, #15171a 0%, #15171ae6 45%, #1d202499 100%), url("assets/photos/tools-collection.jpg") center 60% / cover; }
.catalog-band-inner { min-height: 320px; display: flex; align-items: center; justify-content: space-between; gap: 40px; padding: 72px 0; }
.catalog-band h2 { margin: 0; font-size: clamp(1.9rem, 3vw, 2.7rem); font-weight: 500; line-height: 1.3; letter-spacing: -.025em; }
.catalog-band p:last-child { max-width: 540px; margin: 14px 0 0; color: #c9c6bf; font-weight: 300; }

/* ---------- FAQ ---------- */
.faq-layout { display: grid; grid-template-columns: .8fr 1.2fr; gap: 96px; align-items: start; }
.faq-layout h2 { margin-bottom: 18px; }
.faq-list { border-top: 1px solid var(--graphite); }
.faq-list details { border-bottom: 1px solid var(--line); }
.faq-list summary { position: relative; padding: 24px 56px 24px 0; font-weight: 500; cursor: pointer; list-style: none; transition: color .25s var(--ease); }
.faq-list summary:hover { color: var(--cobalt); }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; position: absolute; right: 4px; top: 50%; transform: translateY(-50%); color: var(--graphite); font: 300 1.4rem var(--latin); }
.faq-list details[open] summary::after { content: "−"; color: var(--cobalt); }
.faq-list details p { margin: 0; padding: 0 56px 26px 0; color: var(--muted); line-height: 1.9; font-weight: 300; }

/* ---------- ติดต่อและแบบฟอร์ม ---------- */
.contact-layout { display: grid; grid-template-columns: .9fr 1.1fr; gap: 96px; align-items: start; }
.contact-layout h2 { margin-bottom: 18px; }
.contact-list { display: grid; margin-top: 36px; border-top: 1px solid var(--line); }
.contact-list > a, .contact-list > div { display: flex; align-items: flex-start; gap: 18px; padding: 18px 0; border-bottom: 1px solid var(--line); line-height: 1.6; word-break: break-word; transition: color .25s var(--ease); }
.contact-list > a:hover { color: var(--cobalt); }
.contact-list .icon { width: 22px; height: 22px; margin-top: 3px; color: var(--cobalt); }
.contact-list small { display: block; color: var(--faint); font-size: .76rem; }
.quote-form { display: grid; gap: 22px; padding: 48px; background: var(--white); border: 1px solid var(--line); }
.quote-form h3 { margin: 0 0 6px; font-size: 1.3rem; font-weight: 500; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.quote-form label { display: block; color: var(--graphite-3); font-size: .8rem; font-weight: 500; letter-spacing: .02em; }
.quote-form b { color: var(--red); font-weight: 400; }
.quote-form input, .quote-form select, .quote-form textarea { display: block; width: 100%; margin-top: 8px; padding: 12px 0; border: 0; border-bottom: 1px solid #c9c5bb; background: transparent; color: var(--ink); font-size: .95rem; font-weight: 400; border-radius: 0; transition: border-color .25s var(--ease); }
.quote-form select { padding-right: 20px; }
.quote-form textarea { resize: vertical; min-height: 110px; padding: 12px; border: 1px solid #c9c5bb; }
.quote-form input:focus, .quote-form select:focus, .quote-form textarea:focus { outline: 0; border-color: var(--cobalt); }
/* ปิดพื้นสีฟ้าของ Chrome autofill ให้เข้ากับโทนเว็บ */
.quote-form input:-webkit-autofill, .quote-form input:-webkit-autofill:hover, .quote-form input:-webkit-autofill:focus { -webkit-box-shadow: 0 0 0 40px var(--white) inset; -webkit-text-fill-color: var(--ink); caret-color: var(--ink); transition: background-color 9999s; }
.quote-form input::placeholder, .quote-form textarea::placeholder { color: #a8a59e; }
.quote-form input:user-invalid, .quote-form textarea:user-invalid { border-color: var(--red); }
.form-note { margin: 0; color: var(--muted); font-size: .76rem; }
.form-note a { color: var(--cobalt); text-decoration: underline; text-underline-offset: 2px; }
.quote-form .button { justify-self: start; }
.form-status { margin: 0; color: var(--cobalt); font-size: .85rem; }
.form-status:empty { display: none; }

/* ---------- ส่วนท้าย ---------- */
.site-footer { color: #a9a8a3; background: #15171a; font-size: .86rem; font-weight: 300; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1.2fr; gap: 56px; padding: 88px 0 64px; }
.footer-brand img { width: 210px; padding: 0; background: transparent; margin-bottom: 24px; filter: grayscale(1) contrast(4) invert(1); mix-blend-mode: screen; }
.site-footer p { margin: 0 0 8px; line-height: 1.8; }
.site-footer h2 { margin: 0 0 20px; color: #f1efea; font-size: .9rem; font-weight: 500; }
.site-footer nav { display: flex; flex-direction: column; gap: 10px; }
.site-footer a { transition: color .25s var(--ease); }
.site-footer a:hover { color: #fff; }
.footer-bottom { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 64px; border-top: 1px solid #ffffff14; color: #7d7c78; font-size: .76rem; }

.mobile-actions { display: none; }

.dev-reminder { position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 100; display: flex; align-items: flex-start; gap: 12px; max-width: 760px; margin-inline: auto; padding: 12px 44px 12px 16px; background: #fff7d6; border: 1px solid #e5c55a; color: #4d3a00; font-size: .8rem; line-height: 1.6; box-shadow: 0 10px 30px #0002; }
.dev-reminder button { position: absolute; right: 8px; top: 6px; border: 0; background: none; font-size: 1.3rem; cursor: pointer; color: inherit; }

/* ---------- หน้าย่อย ---------- */
.page-hero { position: relative; overflow: hidden; color: #fff; background: var(--graphite); }
.page-hero-inner { position: relative; z-index: 1; min-height: 300px; display: flex; flex-direction: column; justify-content: center; padding: 64px 0; }
.page-hero h1 { margin: 0 0 14px; font-size: clamp(2.2rem, 4vw, 3.4rem); font-weight: 500; line-height: 1.2; letter-spacing: -.03em; }
.page-hero-tagline { margin: 0 0 10px; }
.page-hero p:last-child { max-width: 600px; margin: 0; color: #c9c6bf; line-height: 1.85; font-weight: 300; }
.page-hero-photo { position: absolute; inset: 0 0 0 42%; background-size: cover; background-position: center; opacity: .5; filter: saturate(.3); mask-image: linear-gradient(90deg, transparent, #000 55%); -webkit-mask-image: linear-gradient(90deg, transparent, #000 55%); }
.breadcrumb { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; min-height: 64px; color: var(--faint); font-size: .8rem; }
.breadcrumb a:hover { color: var(--cobalt); }
.breadcrumb [aria-current="page"] { color: var(--graphite); }
.page-section { padding: 40px 0 128px; }

/* เกี่ยวกับเรา */
.about-intro { display: grid; grid-template-columns: 1.1fr .9fr; gap: 96px; align-items: start; }
.about-intro p { color: #45494e; line-height: 2; font-weight: 300; }
.about-intro h2 span { color: var(--cobalt); }
.info-table { margin: 0; border-top: 1px solid var(--graphite); }
.info-table div { display: grid; grid-template-columns: 150px 1fr; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--line); font-size: .9rem; }
.info-table dt { color: var(--faint); font-size: .84rem; }
.info-table dd { margin: 0; font-weight: 500; word-break: break-word; }
.info-table a { color: var(--cobalt); }
.mission-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 112px; border-top: 1px solid var(--line); }
.mission-card { padding: 40px 36px 0 0; }
.mission-card + .mission-card { padding-left: 36px; border-left: 1px solid var(--line); }
.mission-card small { color: var(--faint); font: 400 .7rem var(--mono); letter-spacing: .16em; }
.mission-card h3 { margin: 14px 0 12px; font-size: 1.25rem; font-weight: 500; }
.mission-card p { margin: 0; color: var(--muted); line-height: 1.9; font-size: .92rem; font-weight: 300; }
.photo-row { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 16px; margin-top: 112px; }
.photo-row figure { margin: 0; }
.photo-row img { width: 100%; height: 340px; object-fit: cover; filter: saturate(.55); }
.photo-row figcaption { margin-top: 12px; color: var(--faint); font-size: .8rem; }

/* แคตตาล็อก (ดาวน์โหลด) */
.catalog-toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 20px; margin-bottom: 44px; padding-bottom: 24px; border-bottom: 1px solid var(--line); }
.catalog-toolbar h2 { font-size: clamp(1.6rem, 2.5vw, 2.2rem) !important; }
.search-field { display: flex; align-items: center; width: 300px; max-width: 100%; height: 46px; border-bottom: 1px solid var(--graphite); }
.search-field:focus-within { border-color: var(--cobalt); }
.search-field svg { width: 18px; height: 18px; fill: none; stroke: var(--graphite-3); stroke-width: 1.5; }
.search-field input { width: 100%; min-width: 0; padding: 7px 10px; border: 0; outline: 0; background: transparent; font-size: .9rem; }
.catalog-featured { display: grid; grid-template-columns: 320px 1fr; margin-bottom: 88px; background: var(--graphite); color: #fff; }
.catalog-featured .catalog-cover { aspect-ratio: auto; height: 100%; min-height: 400px; border: 0; box-shadow: none; }
.catalog-featured-body { display: flex; flex-direction: column; justify-content: center; align-items: flex-start; padding: 56px 64px; }
.catalog-featured-body h3 { margin: 0 0 6px; font-size: clamp(1.7rem, 2.6vw, 2.4rem); font-weight: 500; line-height: 1.3; letter-spacing: -.02em; }
.catalog-featured-body .catalog-en { color: var(--cobalt-light); }
.catalog-featured-body p { color: #c9c6bf; line-height: 1.9; max-width: 520px; font-weight: 300; }
.catalog-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 64px 28px; }
.catalog-card { display: flex; flex-direction: column; min-width: 0; }
.catalog-cover { position: relative; display: flex; flex-direction: column; aspect-ratio: 3 / 4; overflow: hidden; color: #fff; background: var(--graphite); box-shadow: 0 1px 0 var(--line), 0 18px 34px -18px #1d202466; transition: transform .45s var(--ease), box-shadow .45s var(--ease); }
.catalog-card:hover .catalog-cover { transform: translateY(-6px); box-shadow: 0 1px 0 var(--line), 0 28px 44px -20px #1d202480; }
.catalog-cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: saturate(.25) contrast(1.05); }
.catalog-cover::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, #15171af2 0%, #15171aa6 34%, #15171a1a 62%, #15171a8c 100%); }
.cover-head, .cover-title, .cover-foot { position: relative; z-index: 1; }
.cover-head { display: flex; justify-content: space-between; align-items: center; padding: 18px 18px 0; font: 600 .84rem var(--latin); letter-spacing: .04em; }
.cover-head span { font: 400 .5rem var(--mono); letter-spacing: .16em; opacity: .75; }
.cover-title { padding: 18px 18px 0; }
.cover-title strong { display: block; font: 500 clamp(1rem, 1.35vw, 1.25rem) var(--latin); line-height: 1.2; letter-spacing: -.01em; }
.cover-title span { display: block; margin-top: 6px; font-size: .74rem; font-weight: 300; color: #d6d3cc; }
.cover-foot { display: flex; justify-content: space-between; margin-top: auto; padding: 12px 18px; border-top: 2px solid var(--cobalt); background: #15171ad9; font: 400 .55rem var(--mono); letter-spacing: .14em; }
.catalog-info { padding-top: 20px; }
.catalog-info h3 { margin: 0; font-size: 1.04rem; font-weight: 500; line-height: 1.45; }
.catalog-en { margin: 4px 0 0; color: var(--faint); font: 400 .66rem var(--mono); letter-spacing: .1em; text-transform: uppercase; }
.catalog-meta { margin: 8px 0 18px; color: var(--faint); font-size: .76rem; }
.catalog-actions { display: grid; gap: 8px; margin-top: auto; }
.catalog-actions a { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 6px 10px; font-size: .84rem; font-weight: 500; transition: background .3s var(--ease), color .3s var(--ease), border-color .3s var(--ease); }
.catalog-actions .is-primary { color: #fff; background: var(--graphite); }
.catalog-actions .is-primary:hover { background: var(--cobalt); }
.catalog-actions .is-secondary { border: 1px solid var(--line); color: var(--graphite-3); }
.catalog-actions .is-secondary:hover { border-color: var(--graphite); color: var(--graphite); }
.catalog-actions .icon { width: 16px; height: 16px; }
.empty-state { padding: 48px; border: 1px dashed #c9c5bb; text-align: center; color: var(--muted); }
.catalog-cover-page { background: #fff; border: 1px solid var(--line); }
.catalog-cover-page::after { display: none; }
.catalog-cover-page img { object-fit: contain; filter: none; }
.cover-index { position: absolute; right: 0; bottom: 0; z-index: 1; padding: 6px 10px; color: #fff; background: var(--graphite); font: 400 .62rem var(--mono); letter-spacing: .12em; }
.catalog-featured .catalog-cover-page { border: 0; }
.catalog-help { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; margin-top: 96px; padding: 40px 0; border-top: 1px solid var(--graphite); border-bottom: 1px solid var(--line); }
.catalog-help h3 { margin: 0 0 6px; font-size: 1.25rem; font-weight: 500; }
.catalog-help p { margin: 0; color: var(--muted); font-weight: 300; }

/* ติดต่อเรา */
.contact-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; margin-bottom: 112px; background: var(--line); border: 1px solid var(--line); }
.contact-card { display: flex; flex-direction: column; gap: 6px; padding: 36px 32px; background: var(--white); word-break: break-word; }
.contact-card .icon { width: 26px; height: 26px; margin-bottom: 18px; color: var(--cobalt); }
.contact-card small { color: var(--faint); font-size: .78rem; }
.contact-card > small:first-of-type { color: var(--muted); font-size: .8rem; }
.contact-card strong { font-size: 1.05rem; font-weight: 500; line-height: 1.55; }
.contact-card a:hover { color: var(--cobalt); }
.person-card { display: flex; gap: 20px; align-items: center; margin-top: 36px; padding: 26px 0; border-top: 1px solid var(--graphite); border-bottom: 1px solid var(--line); }
.person-card .icon { width: 52px; height: 52px; padding: 14px; color: #fff; background: var(--graphite); border-radius: 50%; }
.person-card strong { display: block; font-size: 1.05rem; font-weight: 500; }
.person-card small { display: block; color: var(--muted); }
.person-card a { display: block; color: var(--cobalt); font-size: .9rem; word-break: break-word; }
.contact-tips { margin-top: 0; color: #45494e; border-top: 0; }
.map-frame { margin-top: 112px; border: 1px solid var(--line); }
.map-frame iframe { display: block; width: 100%; height: 420px; border: 0; filter: grayscale(.85) contrast(1.05); }

/* นโยบาย */
.prose { max-width: 760px; }
.prose h2 { margin: 56px 0 14px !important; font-size: 1.3rem !important; }
.prose p, .prose li { color: #45494e; line-height: 2; font-weight: 300; }
.prose ul { padding-left: 22px; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .primary-nav a { padding: 0 10px; font-size: .86rem; }
  .primary-nav a::after { left: 10px; right: 10px; }
  .primary-nav a.nav-cta { margin-left: 8px; padding: 0 16px; }
  .category-grid, .catalog-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .category-grid-compact { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .hero-index a { letter-spacing: .1em; }
  .hero-index a + a { padding-left: 14px; }
  .feature-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .feature-card:nth-child(3) { padding-left: 0; border-left: 0; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .split, .faq-layout, .contact-layout, .about-intro { gap: 64px; }
}

@media (max-width: 860px) {
  .header-inner { min-height: 72px; }
  .brand { width: 180px; }
  .menu-toggle { display: block; }
  .primary-nav { position: absolute; top: 100%; left: 0; right: 0; display: none; padding: 12px 24px 24px; background: var(--white); border-bottom: 1px solid var(--line); }
  .primary-nav.is-open { display: flex; flex-direction: column; align-items: stretch; }
  .primary-nav a { min-height: 52px; padding: 0 4px; font-size: 1rem; border-bottom: 1px solid var(--line); }
  .primary-nav a::after { display: none; }
  .primary-nav a.is-active { color: var(--cobalt); }
  .primary-nav a.nav-cta { margin: 16px 0 0; justify-content: center; border: 0; }
  .section { padding: 96px 0; }
  .trust-grid { grid-template-columns: 1fr 1fr; }
  .hero-graphic { opacity: .3; right: -10%; width: 80vw; }
  .hero-index-inner { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .hero-index a:nth-child(n+4) { display: none; }
  .showcase-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .showcase-item:nth-child(n+4) { display: none; }
  .category-grid-compact { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .catalog-feature-inner { grid-template-columns: 180px 1fr; gap: 40px; }
  .trust-item:nth-child(2) { border-right: 0; }
  .trust-item:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .split, .faq-layout, .contact-layout, .about-intro { grid-template-columns: 1fr; gap: 56px; }
  .industry-grid { grid-template-columns: 1fr 1fr; }
  .process-list { grid-template-columns: 1fr 1fr; gap: 48px 0; }
  .process-list li:nth-child(2)::before { display: none; }
  .mission-grid, .contact-cards { grid-template-columns: 1fr; }
  .mission-card + .mission-card { padding-left: 0; border-left: 0; }
  .mission-card { padding-bottom: 32px; border-bottom: 1px solid var(--line); }
  .photo-row { grid-template-columns: 1fr 1fr; }
  .photo-row figure:first-child { grid-column: span 2; }
  .catalog-featured { grid-template-columns: 1fr; }
  .catalog-featured .catalog-cover { min-height: 0; aspect-ratio: 16 / 9; }
}

@media (max-width: 640px) {
  [id] { scroll-margin-top: 84px; }
  body { padding-bottom: 60px; }
  .container { width: calc(100% - 40px); }
  .utility-left { display: none; }
  .utility-inner { justify-content: center; }
  .utility-right { font-size: .72rem; gap: 10px; }
  .hero { min-height: 600px; }
  .hero .tagline { font-size: .6rem; letter-spacing: .14em; margin-bottom: 26px; }
  .hero-index { display: none; }
  .showcase-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); border-inline: 0; }
  .showcase-item:nth-child(n+4) { display: block; }
  .showcase-item:first-child { grid-column: span 2; }
  .showcase-item:first-child img { aspect-ratio: 16 / 9; }
  .category-grid-compact { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .figures dd { font-size: 1.7rem; }
  .figures div + div { padding-left: 14px; }
  .catalog-feature-inner { grid-template-columns: 1fr; padding: 72px 0; }
  .catalog-feature-cover { width: 160px; }
  .split-media figcaption { font-size: .58rem; letter-spacing: .12em; padding: 14px 16px; }
  .hero-image { background-position: 66% center; }
  .hero-shade { background: linear-gradient(90deg, #15171af2, #15171ad0 70%, #1d20249a); }
  .hero-content { padding: 64px 0 72px; }
  .hero-actions .button { flex: 1 1 100%; }
  .trust-strip { margin-top: -48px; }
  .trust-grid { grid-template-columns: 1fr; }
  .trust-item { border-right: 0; border-bottom: 1px solid var(--line); padding: 22px 20px; }
  .trust-item:last-child { border-bottom: 0; }
  .section { padding: 80px 0; }
  .section-head { flex-direction: column; align-items: flex-start; gap: 14px; margin-bottom: 36px; }
  .category-grid, .catalog-grid { grid-template-columns: 1fr 1fr; }
  .catalog-grid { gap: 44px 16px; }
  .category-body { padding: 14px 14px 18px; }
  .category-body strong { font-size: .96rem; }
  .category-body > span { font-size: .74rem; }
  .category-arrow { display: none; }
  .feature-grid, .industry-grid, .process-list { grid-template-columns: 1fr; }
  .feature-card, .feature-card + .feature-card { padding: 28px 0; border-left: 0; border-bottom: 1px solid var(--line); }
  .process-list li { padding-right: 0; }
  .process-list li::before { display: none; }
  .catalog-band-inner { flex-direction: column; align-items: flex-start; }
  .form-row { grid-template-columns: 1fr; }
  .quote-form { padding: 32px 22px; }
  .quote-form .button { justify-self: stretch; }
  .footer-grid { grid-template-columns: 1fr; gap: 40px; padding-top: 64px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; justify-content: center; gap: 4px; padding: 14px 0; }
  .mobile-actions { position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; display: grid; grid-template-columns: 1fr 1.6fr; border-top: 1px solid var(--line); }
  .mobile-actions a { display: grid; place-items: center; min-height: 58px; color: #fff; background: var(--cobalt); font-weight: 500; letter-spacing: .02em; }
  .mobile-actions a.mobile-call { background: var(--graphite); }
  .mobile-actions a[hidden] + a { grid-column: span 2; }
  .dev-reminder { bottom: 72px; }
  .catalog-featured-body { padding: 32px 24px; }
  .catalog-actions a { font-size: .78rem; }
  .info-table div { grid-template-columns: 1fr; gap: 4px; }
  .photo-row { grid-template-columns: 1fr; }
  .photo-row figure:first-child { grid-column: auto; }
  .photo-row img { height: 240px; }
  .map-frame iframe { height: 320px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

/* ที่มาของภาพ */
.credits-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 48px; border-top: 1px solid var(--graphite); }
.credit-row { display: grid; grid-template-columns: 84px 1fr; gap: 20px; align-items: center; padding: 18px 0; border-bottom: 1px solid var(--line); }
.credit-row img { width: 84px; height: 84px; object-fit: cover; }
.credit-row div { display: flex; flex-direction: column; gap: 3px; font-size: .86rem; }
.credit-row strong { font-weight: 500; font-size: .95rem; }
.credit-row span { color: var(--muted); }
.credit-row a { color: var(--cobalt); }
.credit-row:target { background: var(--cobalt-tint); }
.credits-notes { margin-top: 72px; }
@media (max-width: 760px) { .credits-list { grid-template-columns: 1fr; } }
.not-found { display: flex; flex-wrap: wrap; gap: 12px; padding-top: 24px; }
