/* Purchasing 101 — ส่วนกลางที่ทุกหน้าใช้ร่วมกัน (โครงพื้นฐาน, ฟอร์ม, ช่องรูป, ภาพเคลื่อนไหว)
   หน้าตา/สี/ฟอนต์ของแต่ละกลุ่มอยู่ใน <style> ของแต่ละหน้า (src/pages/purchasing-101/*.astro) */
*{box-sizing:border-box}
html{scroll-behavior:smooth;scroll-padding-top:80px;-webkit-text-size-adjust:100%}
body{margin:0;font-size:19px;line-height:1.7;overflow-x:hidden}
a{color:inherit;text-decoration:none}
button,input{font:inherit;color:inherit}
img{max-width:100%;height:auto;display:block}
.wrap{width:min(1180px,100% - 32px);margin-inline:auto}
.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
[hidden]{display:none!important}

/* ค่อย ๆ โผล่ */
.rv{opacity:0;transform:translateY(28px);transition:opacity .8s cubic-bezier(.2,.7,.2,1),transform .8s cubic-bezier(.2,.7,.2,1)}
.rv.in{opacity:1;transform:none}

/* ช่องรูปที่ยังไม่มีไฟล์ = พื้นไล่สี (ป้ายบอกขนาดเห็นเฉพาะ localhost) */
.p-img{width:100%;border-radius:inherit;object-fit:cover}
.ph{position:relative;background:var(--ph,linear-gradient(135deg,rgba(255,255,255,.18),rgba(255,255,255,.04)));overflow:hidden}
.ph::after{content:"";position:absolute;inset:0;background:radial-gradient(60% 50% at 30% 30%,rgba(255,255,255,.25),transparent 70%)}
.ph-label{display:none}
.is-local .ph{outline:3px dashed rgba(255,0,128,.7);outline-offset:-3px}
.is-local .ph-label{display:block;position:absolute;inset:auto 12px 12px 12px;z-index:2;background:rgba(0,0,0,.78);color:#fff;font:600 13px/1.45 system-ui,sans-serif;padding:10px 12px;border-radius:10px}
.is-local .ph-label small{font-weight:400;opacity:.85}

/* ฟอร์ม (โครง) */
.pf-field{margin:0 0 14px}
.pf-field label{display:block;font-size:15px;font-weight:600;margin-bottom:6px}
.pf-field input{width:100%;border-radius:12px;padding:12px 14px;font-size:17px;border:2px solid transparent}
.pf-row{display:grid;gap:0 12px;grid-template-columns:1fr}
@media(min-width:560px){.pf-row{grid-template-columns:1fr 1fr}}
.pf-help{font-size:13px;margin:5px 0 0;opacity:.75}
.pf-note{font-size:15px;margin:0 0 20px;opacity:.8}
.pf-consent{display:flex;gap:10px;font-size:13.5px;line-height:1.55;align-items:flex-start;opacity:.85}
.pf-consent input{margin-top:4px;width:18px;height:18px;flex:0 0 auto}
.pf-consent a{text-decoration:underline}
.pf-submit{width:100%;margin-top:20px}
.form-status{font-size:15px;margin:14px 0 0;min-height:1em}
.form-status.ok{background:#e7f7ee;color:#0f6b43;border-radius:12px;padding:12px 14px}
.form-status.err{color:#c0362c}
.form-status a{text-decoration:underline}
.pf-closed{text-align:center;padding:30px;border-radius:24px}

/* แถบสมัครบนมือถือ */
.m-cta{position:fixed;left:12px;right:12px;bottom:12px;z-index:40;display:flex;align-items:center;justify-content:space-between;gap:10px;border-radius:20px;padding:10px 10px 10px 18px;transform:translateY(160%);transition:transform .45s cubic-bezier(.2,.7,.2,1)}
.m-cta.show{transform:none}
.m-cta b{font-size:19px;display:block;line-height:1.2}
.m-cta small{font-size:12.5px;opacity:.8}
@media(min-width:900px){.m-cta{display:none}}

/* ปุ่มหยุดภาพเคลื่อนไหว */
.motion-btn{background:none;border:1px solid currentColor;border-radius:99px;padding:5px 12px;font-size:12px;cursor:pointer;opacity:.65}

/* FAQ (โครง) */
.faq details{padding:18px 0}
.faq summary{cursor:pointer;font-weight:600;list-style:none;display:flex;justify-content:space-between;gap:16px;font-size:18px}
.faq summary::-webkit-details-marker{display:none}
.faq summary::after{content:"+";font-size:26px;line-height:1;transition:transform .3s}
.faq details[open] summary::after{transform:rotate(45deg)}
.faq details p{margin:10px 0 0;opacity:.8;font-size:17px}

/* ปิดภาพเคลื่อนไหว */
.motion-off *,.motion-off *::before,.motion-off *::after{animation:none!important;transition:none!important}
.motion-off .rv{opacity:1;transform:none}

/* มือถือ: แถบบนให้โล่ง */
.cta{white-space:nowrap}
@media(max-width:600px){.motion-btn{display:none}}

/* แถบบน: โลโก้บริษัท + ชื่อหลักสูตรให้ใหญ่ เห็นชัด */
html{scroll-padding-top:100px}
header.nav .wrap{height:86px}
header.nav .logo{gap:16px}
header.nav .logo img{height:52px;width:auto}
.lg-t{display:flex;flex-direction:column;line-height:1;font-size:26px;font-weight:800;letter-spacing:.03em;white-space:nowrap}
.lg-t b{font-weight:900}
.lg-t small{font-size:13.5px;font-weight:500;letter-spacing:0;opacity:.75;margin-top:5px}
@media(max-width:600px){header.nav .wrap{height:72px}header.nav .logo{gap:10px}header.nav .logo img{height:40px}.lg-t{font-size:19px}.lg-t small{font-size:11px}}
