/* =========================================================
   System Evolution: design layer
   โหลดหลัง CSS ของ theme ทั้งหมด ใช้ prefix .sx- สำหรับ component ใหม่
   ========================================================= */
:root {
   --sx-primary: #0249c0;
   --sx-primary-600: #013a9a;
   --sx-primary-50: #eaf1fd;
   --sx-ink: #172033;
   --sx-body: #3d4757;
   --sx-muted: #6a7486;
   --sx-line: #e2e8f1;
   --sx-soft: #f4f7fc;
   --sx-white: #ffffff;
   --sx-line-green: #06c755;
   --sx-radius: 14px;
   --sx-radius-sm: 10px;
   --sx-shadow: 0 1px 2px rgba(16, 24, 40, .05), 0 8px 24px rgba(16, 24, 40, .06);
   --sx-shadow-lg: 0 12px 40px rgba(2, 40, 110, .14);
   --sx-font-head: "Prompt", "IBM Plex Sans Thai", sans-serif;
   --sx-font-body: "IBM Plex Sans Thai", "Prompt", sans-serif;
}

/* ---------- พื้นฐาน / ตัวอักษรไทย ---------- */
body { font-family: var(--sx-font-body); color: var(--sx-body); }
p, li, td, input, select, textarea, .description, .short_desc { font-family: var(--sx-font-body); line-height: 1.75; }
h1, h2, h3, h4, h5, h6 { font-family: var(--sx-font-head); }
a:focus-visible, button:focus-visible, summary:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
   outline: 3px solid rgba(2, 73, 192, .45); outline-offset: 2px;
}
img { max-width: 100%; height: auto; }

/* preloader เดิมบังเนื้อหาทั้งหน้า ทำให้โหลดช้า (LCP) */
.preloader-wrap { display: none !important; }

/* ---------- Header ---------- */
.header .sx-header-cta.theme-btn { padding: 11px 24px !important; line-height: 1.3 !important; min-height: 0 !important; height: auto !important; border-radius: 999px !important; font-weight: 600; white-space: nowrap; text-decoration: none !important; }
.header_right_content ul { display: flex; align-items: center; margin: 0; padding: 0; list-style: none; }
.sx-menu-cat { font-family: var(--sx-font-head); font-weight: 600; color: var(--sx-primary); font-size: 14px; padding: 0 0 8px; margin-bottom: 6px; border-bottom: 1px solid var(--sx-line); }
.header .dropdown-menu a, .top_bar a, .sx-contact-list a, .sx-form__alt a { text-decoration: none; }
.header .dropdown-menu a:hover { color: var(--sx-primary); }
@media (max-width: 991px) { .header_right_content { display: none; } }

/* หน้า Landing page: ซ่อนเมนู เหลือโลโก้ + ปุ่ม */
.sx-lp .header_menu_box, .sx-lp .navbar_togglers, .sx-lp .top_bar .right_side { display: none !important; }
.sx-lp .header_right_content { display: block !important; }

/* ---------- Layout helpers ---------- */
.sx-section { padding: 88px 0; }
.sx-section--soft { background: var(--sx-soft); }
.sx-section--tight { padding: 56px 0; }
.sx-container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.sx-eyebrow { display: inline-block; font-family: var(--sx-font-head); font-size: 14px; font-weight: 600; letter-spacing: .04em; color: var(--sx-primary); background: var(--sx-primary-50); padding: 6px 14px; border-radius: 999px; margin-bottom: 14px; }
.sx-title { font-size: clamp(26px, 3.2vw, 38px); line-height: 1.35; font-weight: 600; color: var(--sx-ink); margin: 0 0 14px; }
.sx-lead { font-size: 17px; color: var(--sx-muted); max-width: 720px; margin: 0 auto; }
.sx-head { text-align: center; margin-bottom: 48px; }
.sx-grid { display: grid; gap: 22px; }
.sx-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.sx-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.sx-grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 991px) { .sx-grid--3, .sx-grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) {
   .sx-section { padding: 60px 0; }
   .sx-grid--2, .sx-grid--3, .sx-grid--4 { grid-template-columns: 1fr; }
   .sx-head { margin-bottom: 32px; }
}

/* ---------- ปุ่ม ---------- */
.sx-btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 50px; padding: 12px 26px; border-radius: 999px; font-family: var(--sx-font-head); font-weight: 600; font-size: 16px; line-height: 1.2; text-decoration: none !important; border: 2px solid transparent; transition: transform .15s ease, background-color .15s ease, box-shadow .15s ease; cursor: pointer; }
.sx-btn:hover { transform: translateY(-1px); }
.sx-btn--primary { background: var(--sx-primary); color: #fff !important; box-shadow: 0 6px 18px rgba(2, 73, 192, .28); }
.sx-btn--primary:hover { background: var(--sx-primary-600); }
.sx-btn--white { background: #fff; color: var(--sx-primary) !important; }
.sx-btn--ghost { background: transparent; color: #fff !important; border-color: rgba(255, 255, 255, .55); }
.sx-btn--ghost:hover { background: rgba(255, 255, 255, .1); }
.sx-btn--outline { background: transparent; color: var(--sx-primary) !important; border-color: var(--sx-primary); }
.sx-btn--line { background: var(--sx-line-green); color: #fff !important; }
.sx-btn--block { width: 100%; }
.sx-btns { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Hero ---------- */
.sx-hero { position: relative; color: #fff; background: #0b2a66 url(../../images/home/slide_home.jpg) center / cover no-repeat; overflow: hidden; }
.sx-hero::before { content: ""; position: absolute; inset: 0; background: linear-gradient(100deg, rgba(4, 22, 64, .94) 0%, rgba(2, 46, 128, .86) 48%, rgba(2, 73, 192, .45) 100%); }
.sx-hero .sx-container { position: relative; z-index: 1; }
.sx-hero__inner { padding: 110px 0 96px; max-width: 760px; }
.sx-hero__tag { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 500; padding: 6px 14px; border-radius: 999px; background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .22); margin-bottom: 22px; }
.sx-hero h1 { font-size: clamp(30px, 4.6vw, 52px); line-height: 1.28; font-weight: 600; color: #fff; margin: 0 0 18px; }
.sx-hero h1 .sx-hero__h1-2 { display: block; color: #9cc3ff; }
.sx-nw { white-space: nowrap; }
.sx-hero h1, .sx-lp-hero h1, .sx-title, .sx-cta h2 { text-wrap: balance; }
.sx-hero__sub { font-size: clamp(16px, 1.6vw, 19px); color: rgba(255, 255, 255, .86); margin: 0 0 32px; max-width: 640px; }
.sx-hero__stats { display: grid; grid-template-columns: repeat(4, max-content); justify-content: start; gap: 0; margin-top: 48px; border-top: 1px solid rgba(255, 255, 255, .18); padding-top: 26px; }
.sx-hero__stats div { padding-right: 28px; }
.sx-hero__stats div + div { border-left: 1px solid rgba(255, 255, 255, .18); padding-left: 28px; }
.sx-hero__stats strong { display: block; font-family: var(--sx-font-head); font-size: clamp(24px, 2.6vw, 34px); font-weight: 600; color: #fff; line-height: 1.15; white-space: nowrap; }
.sx-hero__stats span { font-size: 14px; color: rgba(255, 255, 255, .75); }
@media (max-width: 640px) {
   .sx-hero__inner { padding: 72px 0 64px; }
   .sx-hero__stats div + div { padding-left: 14px; }
   .sx-hero__stats { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 18px; }
   .sx-hero__stats div { padding-right: 10px; }
   .sx-hero__stats div:nth-child(3) { border-left: 0; padding-left: 0; }
   .sx-hero .sx-btn { width: 100%; }
}

/* ---------- โลโก้ลูกค้า ---------- */
.sx-logos { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 14px; align-items: center; }
.sx-logos__item { display: flex; align-items: center; justify-content: center; height: 84px; padding: 14px; background: #fff; border: 1px solid var(--sx-line); border-radius: var(--sx-radius-sm); }
.sx-logos__item img { max-height: 54px; width: auto; object-fit: contain; filter: grayscale(1); opacity: .75; transition: filter .2s, opacity .2s; }
.sx-logos__item:hover img { filter: none; opacity: 1; }
@media (max-width: 991px) { .sx-logos { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 640px) { .sx-logos { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; } .sx-logos__item { height: 64px; padding: 10px; } }
.sx-trust-label { text-align: center; font-size: 15px; color: var(--sx-muted); margin: 0 0 22px; }

/* ---------- การ์ด ---------- */
.sx-card { background: #fff; border: 1px solid var(--sx-line); border-radius: var(--sx-radius); padding: 28px; box-shadow: var(--sx-shadow); height: 100%; }
.sx-card h3 { font-size: 20px; font-weight: 600; color: var(--sx-ink); margin: 0 0 10px; line-height: 1.4; }
.sx-card p { margin: 0; color: var(--sx-muted); font-size: 15.5px; }
.sx-icon { width: 52px; height: 52px; border-radius: 14px; display: inline-flex; align-items: center; justify-content: center; background: var(--sx-primary-50); color: var(--sx-primary); font-size: 22px; margin-bottom: 18px; }

/* การ์ดโปรแกรม */
.sx-cat { margin-bottom: 56px; }
.sx-cat:last-child { margin-bottom: 0; }
.sx-cat__head { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; }
.sx-cat__head .sx-icon { margin: 0; width: 44px; height: 44px; font-size: 19px; }
.sx-cat__head h3 { font-size: 22px; font-weight: 600; color: var(--sx-ink); margin: 0; }
.sx-cat__head small { display: block; color: var(--sx-muted); font-size: 13px; letter-spacing: .03em; }
.sx-product { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--sx-line); border-radius: var(--sx-radius); overflow: hidden; text-decoration: none !important; height: 100%; transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease; }
.sx-product:hover { transform: translateY(-3px); box-shadow: var(--sx-shadow-lg); border-color: #c9d7f0; }
.sx-product__img { aspect-ratio: 16 / 10; background: var(--sx-soft); overflow: hidden; }
.sx-product__img img { width: 100%; height: 100%; object-fit: cover; }
.sx-product__body { padding: 20px 22px 22px; display: flex; flex-direction: column; flex: 1; }
.sx-product__body h4 { font-size: 18px; font-weight: 600; color: var(--sx-ink); margin: 0 0 4px; line-height: 1.4; }
.sx-product__en { font-size: 12.5px; letter-spacing: .04em; text-transform: uppercase; color: var(--sx-primary); margin-bottom: 10px; }
.sx-product__body p { font-size: 15px; color: var(--sx-muted); margin: 0 0 16px; line-height: 1.7; }
.sx-product__more { margin-top: auto; font-family: var(--sx-font-head); font-weight: 600; font-size: 15px; color: var(--sx-primary); }
.sx-product__more::after { content: " \2192"; }

/* รายการ check */
.sx-checks { list-style: none; padding: 0; margin: 0; }
.sx-checks li { position: relative; padding-left: 34px; margin-bottom: 12px; color: var(--sx-body); }
.sx-checks li::before { content: ""; position: absolute; left: 0; top: 4px; width: 22px; height: 22px; border-radius: 50%; background: var(--sx-primary-50) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230249c0' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / 13px no-repeat; }
.sx-hero .sx-checks li, .sx-lp-hero .sx-checks li, .sx-pd-hero .sx-checks li { color: rgba(255, 255, 255, .9); }
.sx-hero .sx-checks li::before, .sx-lp-hero .sx-checks li::before, .sx-pd-hero .sx-checks li::before { background-color: rgba(255, 255, 255, .16); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E"); }

/* ---------- FAQ (details/summary ไม่ต้องใช้ JS) ---------- */
.sx-faq { max-width: 860px; margin: 0 auto; }
.sx-faq details { background: #fff; border: 1px solid var(--sx-line); border-radius: var(--sx-radius-sm); margin-bottom: 12px; transition: box-shadow .2s; }
.sx-faq details[open] { box-shadow: var(--sx-shadow); border-color: #c9d7f0; }
.sx-faq summary { list-style: none; cursor: pointer; padding: 20px 56px 20px 22px; position: relative; font-family: var(--sx-font-head); font-weight: 500; font-size: 17px; color: var(--sx-ink); line-height: 1.5; }
.sx-faq summary::-webkit-details-marker { display: none; }
.sx-faq summary::after { content: "+"; position: absolute; right: 20px; top: 50%; transform: translateY(-50%); width: 28px; height: 28px; border-radius: 50%; background: var(--sx-primary-50); color: var(--sx-primary); font-size: 20px; line-height: 28px; text-align: center; }
.sx-faq details[open] summary::after { content: "\2212"; }
.sx-faq details p { padding: 0 22px 20px; margin: 0; color: var(--sx-body); }

/* ---------- CTA band ---------- */
.sx-cta { background: linear-gradient(110deg, #0a2d73 0%, var(--sx-primary) 100%); color: #fff; border-radius: 22px; padding: 48px; display: flex; align-items: center; justify-content: space-between; gap: 28px; flex-wrap: wrap; }
.sx-cta h2 { color: #fff; font-size: clamp(24px, 2.6vw, 32px); font-weight: 600; margin: 0 0 8px; }
.sx-cta p { color: rgba(255, 255, 255, .85); margin: 0; }
@media (max-width: 640px) { .sx-cta { padding: 32px 24px; } .sx-cta .sx-btns, .sx-cta .sx-btn { width: 100%; } }

/* ---------- ฟอร์มลีด ---------- */
.sx-lead-wrap { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 40px; align-items: start; }
@media (max-width: 991px) { .sx-lead-wrap { grid-template-columns: 1fr; } }
.sx-contact-list { list-style: none; padding: 0; margin: 24px 0 0; }
.sx-contact-list li { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 18px; }
.sx-contact-list .sx-icon { margin: 0; flex: 0 0 auto; width: 44px; height: 44px; font-size: 18px; }
.sx-contact-list strong { display: block; color: var(--sx-ink); font-family: var(--sx-font-head); font-weight: 500; }
.sx-contact-list a { color: var(--sx-primary); }
.sx-form { background: #fff; border: 1px solid var(--sx-line); border-radius: 18px; padding: 32px; box-shadow: var(--sx-shadow-lg); }
.sx-form h3 { font-size: 22px; font-weight: 600; color: var(--sx-ink); margin: 0 0 4px; }
.sx-form__note { color: var(--sx-muted); font-size: 15px; margin: 0 0 22px; }
.sx-form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 640px) { .sx-form { padding: 24px 18px; } .sx-form__row { grid-template-columns: 1fr; gap: 0; } }
.sx-field { margin-bottom: 16px; }
.sx-field label { display: block; font-weight: 500; color: var(--sx-ink); font-size: 15px; margin-bottom: 6px; }
.sx-field label em { color: #c62828; font-style: normal; }
.sx-field input, .sx-field select, .sx-field textarea { width: 100%; min-height: 48px; padding: 11px 14px; border: 1px solid #cfd8e6; border-radius: var(--sx-radius-sm); background: #fff; font-size: 16px; color: var(--sx-ink); transition: border-color .15s, box-shadow .15s; }
.sx-field textarea { min-height: 96px; resize: vertical; }
.sx-field input:focus, .sx-field select:focus, .sx-field textarea:focus { border-color: var(--sx-primary); box-shadow: 0 0 0 4px rgba(2, 73, 192, .12); outline: none; }
.sx-consent { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--sx-muted); margin: 4px 0 18px; line-height: 1.6; }
.sx-consent input { margin-top: 4px; width: 18px; height: 18px; flex: 0 0 auto; accent-color: var(--sx-primary); }
#lead-form { scroll-margin-top: 90px; }
.sx-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.sx-form__alt { text-align: center; font-size: 14px; color: var(--sx-muted); margin: 14px 0 0; }

/* ---------- Landing page ---------- */
.sx-lp-hero { position: relative; color: #fff; background: linear-gradient(115deg, #061d4d 0%, #0a3591 55%, var(--sx-primary) 100%); padding: 64px 0 72px; overflow: hidden; }
.sx-lp-hero__grid { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: 44px; align-items: start; }
@media (max-width: 991px) { .sx-lp-hero__grid { grid-template-columns: 1fr; } }
.sx-lp-hero h1 { color: #fff; font-size: clamp(30px, 4vw, 46px); line-height: 1.3; font-weight: 600; margin: 0 0 16px; }
.sx-lp-hero .sx-hero__sub { margin-bottom: 26px; }
.sx-lp-hero .sx-form { color: var(--sx-body); }
.sx-lp-shot { border-radius: 16px; overflow: hidden; box-shadow: var(--sx-shadow-lg); background: #fff; }

/* ---------- Thank you ---------- */
.sx-thanks { text-align: center; max-width: 640px; margin: 0 auto; }
.sx-thanks .sx-icon { width: 76px; height: 76px; font-size: 34px; border-radius: 50%; background: #e7f8ee; color: #138a43; }

/* ---------- ปุ่มติดต่อ ติดล่างจอมือถือ ---------- */
.sx-mobilebar { display: none; }
@media (max-width: 767px) {
   .sx-mobilebar { display: grid; grid-template-columns: 1fr 1fr 1.25fr; gap: 8px; position: fixed; left: 0; right: 0; bottom: 0; z-index: 9990; padding: 10px 12px calc(10px + env(safe-area-inset-bottom)); background: rgba(255, 255, 255, .97); box-shadow: 0 -6px 20px rgba(16, 24, 40, .12); }
   .sx-mobilebar a { display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 46px; border-radius: 12px; font-family: var(--sx-font-head); font-weight: 600; font-size: 15px; text-decoration: none !important; }
   .sx-mobilebar__call { background: var(--sx-primary-50); color: var(--sx-primary) !important; }
   .sx-mobilebar__line { background: var(--sx-line-green); color: #fff !important; }
   .sx-mobilebar__demo { background: var(--sx-primary); color: #fff !important; }
   body { padding-bottom: 74px; }
   .scroll-top, .prgoress_indicator, #scroll-top { bottom: 90px !important; }
}

/* ---------- ปรับหน้าเดิมให้เข้าชุด ---------- */
.page_header_default .title_page { letter-spacing: .02em; }
.woocommerce div.product .product_title { font-size: clamp(26px, 3vw, 34px); line-height: 1.35; }
.sx-related .sx-product__img { aspect-ratio: 16 / 9; }

@media (prefers-reduced-motion: reduce) {
   .sx-btn, .sx-product, .sx-logos__item img { transition: none; }
   .sx-btn:hover, .sx-product:hover { transform: none; }
}

/* =========================================================
   เรียบหรู: หัวหน้า (ติดต่อ/นโยบาย), หน้าติดต่อ, หน้านโยบาย, footer
   ========================================================= */
:root { --sx-ink-900: #0a1730; --sx-ink-800: #10224a; --sx-hair: rgba(255, 255, 255, .12); }

.sx-pagehead { background: var(--sx-ink-900); color: #fff; padding: 72px 0 64px; border-bottom: 1px solid var(--sx-hair); }
.sx-crumbs { display: flex; gap: 10px; align-items: center; font-size: 13px; color: rgba(255, 255, 255, .55); margin-bottom: 28px; }
.sx-crumbs a { color: rgba(255, 255, 255, .75); text-decoration: none; }
.sx-crumbs a:hover { color: #fff; }
.sx-pagehead__eyebrow { display: block; font-family: var(--sx-font-head); font-size: 13px; font-weight: 500; letter-spacing: .22em; text-transform: uppercase; color: #9cc3ff; margin-bottom: 12px; }
.sx-pagehead h1 { font-size: clamp(34px, 4.4vw, 54px); font-weight: 500; color: #fff; line-height: 1.2; margin: 0 0 14px; }
.sx-pagehead p { font-size: 17px; color: rgba(255, 255, 255, .7); max-width: 620px; margin: 0; }
@media (max-width: 640px) { .sx-pagehead { padding: 48px 0 44px; } .sx-crumbs { margin-bottom: 20px; } }

.sx-link { font-family: var(--sx-font-head); font-weight: 500; color: var(--sx-primary); text-decoration: none; border-bottom: 1px solid currentColor; padding-bottom: 1px; }

/* ---------- หน้าติดต่อ ---------- */
.sx-contact__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px; align-items: stretch; }
.sx-contact__cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.sx-ccard { display: block; background: #fff; border: 1px solid var(--sx-line); border-radius: 16px; padding: 22px 22px 20px; text-decoration: none !important; color: var(--sx-ink); transition: border-color .2s, transform .2s, box-shadow .2s; }
a.sx-ccard:hover { border-color: var(--sx-primary); transform: translateY(-2px); box-shadow: var(--sx-shadow); }
.sx-ccard__label { display: block; font-size: 12px; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; color: var(--sx-muted); margin-bottom: 10px; }
.sx-ccard strong { display: block; font-family: var(--sx-font-head); font-size: 21px; font-weight: 500; color: var(--sx-ink); line-height: 1.3; }
.sx-ccard__email { font-size: 16px !important; word-break: break-all; }
.sx-ccard__sub { display: block; font-size: 14px; color: var(--sx-muted); margin-top: 6px; }
.sx-contact__addr { display: flex; justify-content: space-between; gap: 20px; align-items: center; margin-top: 14px; background: var(--sx-soft); border-radius: 16px; padding: 22px; }
.sx-contact__addr p { margin: 0 0 10px; color: var(--sx-body); }
.sx-contact__addr p strong { color: var(--sx-ink); font-weight: 500; }
.sx-contact__qr { flex: 0 0 auto; text-align: center; text-decoration: none !important; color: var(--sx-muted); font-size: 12px; }
.sx-contact__qr img { display: block; width: 104px; height: 104px; border-radius: 12px; background: #fff; padding: 6px; border: 1px solid var(--sx-line); margin: 0 auto 6px; }
.sx-contact__map { border-radius: 18px; overflow: hidden; border: 1px solid var(--sx-line); min-height: 420px; }
.sx-contact__map iframe { width: 100%; height: 100%; min-height: 420px; border: 0; display: block; filter: grayscale(.35); }
@media (max-width: 991px) { .sx-contact__grid { grid-template-columns: 1fr; } }
@media (max-width: 640px) {
   .sx-contact__cards { grid-template-columns: 1fr; }
   .sx-contact__addr { flex-direction: column; align-items: flex-start; }
   .sx-contact__map, .sx-contact__map iframe { min-height: 320px; }
}

/* ---------- หน้านโยบาย ---------- */
.sx-policy__intro { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 64px; align-items: center; margin-bottom: 72px; }
.sx-policy__media { position: relative; }
.sx-policy__media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 20px; display: block; }
.sx-policy__since { position: absolute; right: -18px; bottom: -22px; background: var(--sx-ink-900); color: #fff; border-radius: 16px; padding: 18px 22px; }
.sx-policy__since strong { display: block; font-family: var(--sx-font-head); font-size: 34px; font-weight: 500; line-height: 1; }
.sx-policy__since span { font-size: 12px; letter-spacing: .08em; color: rgba(255, 255, 255, .65); }
.sx-quote { font-family: var(--sx-font-head); font-size: clamp(24px, 2.6vw, 32px); font-weight: 500; line-height: 1.45; color: var(--sx-ink); margin: 6px 0 22px; padding: 0 0 0 22px; border-left: 2px solid var(--sx-primary); }
.sx-policy__intro p { color: var(--sx-body); font-size: 16.5px; margin: 0; }
.sx-pillars { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--sx-line); }
.sx-pillar { padding: 30px 26px 8px 0; }
.sx-pillar + .sx-pillar { padding-left: 26px; border-left: 1px solid var(--sx-line); }
.sx-pillar__no { display: block; font-family: var(--sx-font-head); font-size: 14px; font-weight: 500; letter-spacing: .1em; color: var(--sx-primary); margin-bottom: 16px; }
.sx-pillar h3 { font-size: 19px; font-weight: 500; color: var(--sx-ink); margin: 0 0 8px; }
.sx-pillar p { font-size: 15px; color: var(--sx-muted); margin: 0; }
@media (max-width: 991px) {
   .sx-policy__intro { grid-template-columns: 1fr; gap: 48px; }
   .sx-policy__since { right: 16px; }
   .sx-pillars { grid-template-columns: repeat(2, minmax(0, 1fr)); }
   .sx-pillar:nth-child(3) { padding-left: 0; border-left: 0; }
   .sx-pillar:nth-child(n+3) { border-top: 1px solid var(--sx-line); }
}
@media (max-width: 640px) {
   .sx-pillars { grid-template-columns: 1fr; }
   .sx-pillar, .sx-pillar + .sx-pillar { padding: 24px 0 16px; border-left: 0; }
   .sx-pillar + .sx-pillar { border-top: 1px solid var(--sx-line); }
}

/* ---------- Footer ---------- */
.sx-footer { background: var(--sx-ink-900); color: rgba(255, 255, 255, .68); padding: 80px 0 0; font-size: 15px; }
.sx-footer a { color: rgba(255, 255, 255, .78); text-decoration: none; transition: color .15s; }
.sx-footer a:hover { color: #fff; }
.sx-footer__grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, .8fr) minmax(0, 1.1fr); gap: 48px; padding-bottom: 56px; }
.sx-footer__logo img { width: 64px; height: auto; margin-bottom: 18px; }
.sx-footer__name { font-family: var(--sx-font-head); font-size: 17px; font-weight: 500; color: #fff; line-height: 1.5; margin: 0 0 12px; }
.sx-footer__name span { font-size: 13px; letter-spacing: .06em; color: rgba(255, 255, 255, .55); font-weight: 400; }
.sx-footer__brand p { margin: 0 0 20px; line-height: 1.75; }
.sx-footer__social { display: flex; gap: 10px; }
.sx-footer__social a { width: 40px; height: 40px; border: 1px solid var(--sx-hair); border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 16px; }
.sx-footer__social a:hover { border-color: rgba(255, 255, 255, .5); }
.sx-footer__title { font-family: var(--sx-font-head); font-size: 13px; font-weight: 500; letter-spacing: .18em; text-transform: uppercase; color: #9cc3ff; margin: 6px 0 20px; }
.sx-footer__links, .sx-footer__contact { list-style: none; padding: 0; margin: 0; }
.sx-footer__links li, .sx-footer__contact li { margin-bottom: 12px; line-height: 1.6; }
.sx-footer__qr { display: inline-flex; align-items: center; gap: 12px; margin-top: 8px; font-size: 13px; }
.sx-footer__qr img { width: 64px; height: 64px; border-radius: 10px; background: #fff; padding: 4px; }
.sx-footer__bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; border-top: 1px solid var(--sx-hair); padding: 22px 0 26px; font-size: 13px; color: rgba(255, 255, 255, .5); letter-spacing: .02em; }
@media (max-width: 991px) { .sx-footer__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px 32px; } }
@media (max-width: 640px) { .sx-footer { padding-top: 56px; } .sx-footer__grid { grid-template-columns: 1fr; gap: 32px; } }

.sx-block { display: block; }
.sx-crumbs { flex-wrap: wrap; row-gap: 4px; }
.sx-crumbs > a, .sx-crumbs > span { white-space: nowrap; }
.sx-crumbs > span:last-child { white-space: normal; flex: 1 1 100%; color: rgba(255, 255, 255, .55); }
@media (min-width: 641px) { .sx-crumbs > span:last-child { flex: 0 1 auto; } }

/* หัวหน้าใน: ไล่สีเหมือน Hero หน้าแรก + footer น้ำเงินกรมท่า (เลือกแบบ 1) */
.sx-pagehead { position: relative; overflow: hidden; background: #0b2a66 url(../../images/home/slide_home.jpg) center / cover no-repeat; border-bottom: 0; }
.sx-pagehead::before { content: ""; position: absolute; inset: 0; background: linear-gradient(100deg, rgba(4, 22, 64, .94) 0%, rgba(2, 46, 128, .86) 48%, rgba(2, 73, 192, .55) 100%); }
.sx-pagehead .sx-container { position: relative; z-index: 1; }
.sx-pagehead p { color: rgba(255, 255, 255, .82); }
.sx-footer, .sx-policy__since { background: #0b2558; }

/* ---------- แบนเนอร์คุกกี้ (PDPA) ---------- */
.sx-cookie { position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 9995; max-width: 980px; margin: 0 auto; background: #fff; border: 1px solid var(--sx-line); border-radius: 16px; box-shadow: 0 16px 48px rgba(11, 37, 88, .18); padding: 18px 20px; display: flex; gap: 18px; align-items: center; }
.sx-cookie[hidden] { display: none; }
.sx-cookie__text { font-size: 14.5px; color: var(--sx-body); line-height: 1.65; }
.sx-cookie__text strong { display: block; font-family: var(--sx-font-head); font-weight: 500; color: var(--sx-ink); font-size: 16px; margin-bottom: 2px; }
.sx-cookie__text a { color: var(--sx-primary); }
.sx-cookie__btns { display: flex; gap: 10px; flex: 0 0 auto; }
.sx-cookie .sx-btn { min-height: 44px; padding: 10px 18px; font-size: 15px; }
.sx-cookie__short { display: none; }
@media (max-width: 767px) {
   /* มือถือ: แถบเตี้ย ไม่บังฟอร์ม/เนื้อหา */
   .sx-cookie { flex-direction: column; align-items: stretch; gap: 8px; bottom: 76px; left: 8px; right: 8px; padding: 10px 12px; border-radius: 12px; }
   .sx-cookie__text { font-size: 12.5px; line-height: 1.5; }
   .sx-cookie__text strong, .sx-cookie__long { display: none; }
   .sx-cookie__short { display: inline; }
   .sx-cookie__btns { gap: 8px; }
   .sx-cookie__btns .sx-btn { flex: 1; min-height: 36px; padding: 6px 10px; font-size: 13.5px; }
}

/* ---------- หน้านโยบายความเป็นส่วนตัว ---------- */
.sx-legal { max-width: 860px; margin: 0 auto; }
.sx-legal h2 { font-size: 22px; font-weight: 500; color: var(--sx-ink); margin: 40px 0 12px; }
.sx-legal h2:first-child { margin-top: 0; }
.sx-legal p, .sx-legal li { color: var(--sx-body); font-size: 16px; }
.sx-legal ul { padding-left: 22px; margin: 0 0 12px; }
.sx-legal li { margin-bottom: 6px; }
.sx-legal table { width: 100%; border-collapse: collapse; margin: 8px 0 12px; font-size: 15px; }
.sx-legal th, .sx-legal td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--sx-line); vertical-align: top; }
.sx-legal th { font-family: var(--sx-font-head); font-weight: 500; color: var(--sx-muted); background: var(--sx-soft); }
.sx-legal__meta { color: var(--sx-muted); font-size: 14px; }

/* ---------- Landing page ปรับตามแหล่งที่มา ---------- */
.sx-lp-hero__grid { grid-template-areas: "head form" "body form"; row-gap: 0; }
.sx-lp-head { grid-area: head; }
.sx-lp-body { grid-area: body; }
.sx-lp-form { grid-area: form; }
.sx-lp-product { font-family: var(--sx-font-head); font-weight: 500; color: #9cc3ff; margin: -6px 0 12px; font-size: 18px; }
.sx-btn--lg { min-height: 58px; font-size: 18px; }
.sx-lp-note { color: rgba(255, 255, 255, .78); font-size: 14.5px; margin: 10px 0 22px; text-align: center; }
.sx-lp-note a { color: #fff; }
@media (max-width: 991px) {
   .sx-lp-hero__grid { grid-template-areas: "head" "body" "form"; row-gap: 24px; }
   /* Google: คนค้นหาพร้อมตัดสินใจ -> ฟอร์มขึ้นก่อนจุดเด่น */
   .sx-lp--search .sx-lp-hero__grid { grid-template-areas: "head" "form" "body"; }
}
/* Facebook / TikTok: LINE เด่นในแถบล่างจอมือถือ */
@media (max-width: 767px) {
   .sx-mobilebar--social { grid-template-columns: 1.45fr .85fr 1.1fr; }
   .sx-mobilebar--social .sx-mobilebar__line { order: -1; }
}

/* ---------- หน้าโปรแกรมแบบใหม่ (details-*.php) ---------- */
.sx-pd-hero { position: relative; overflow: hidden; color: #fff; background: #0b2a66 url(../../images/home/slide_home.jpg) center / cover no-repeat; padding: 56px 0 48px; }
.sx-pd-hero::before { content: ""; position: absolute; inset: 0; background: linear-gradient(100deg, rgba(4, 22, 64, .95) 0%, rgba(2, 46, 128, .9) 55%, rgba(2, 73, 192, .7) 100%); }
.sx-pd-hero .sx-container { position: relative; z-index: 1; }
.sx-pd-hero__grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 48px; align-items: center; }
.sx-pd-hero h1 { font-size: clamp(30px, 4vw, 48px); line-height: 1.28; font-weight: 600; color: #fff; margin: 0 0 16px; text-wrap: balance; }
.sx-pd-hero__h1-2 { display: block; font-size: .62em; font-weight: 500; color: #9cc3ff; margin-top: 6px; }
.sx-pd-hero .sx-btns { margin-bottom: 26px; }
.sx-pd-hero__checks { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 18px; }
.sx-pd-hero__checks li { margin-bottom: 10px; font-size: 15px; }
.sx-pd-hero__shot { display: block; border-radius: 14px; overflow: hidden; background: #fff; box-shadow: 0 24px 60px rgba(0, 10, 40, .45); border: 6px solid rgba(255, 255, 255, .14); }
.sx-pd-hero__shot img { display: block; width: 100%; height: auto; }
.sx-pd-stats { margin-top: 44px; }
@media (max-width: 991px) { .sx-pd-hero__grid { grid-template-columns: 1fr; gap: 32px; } }
@media (max-width: 640px) { .sx-pd-hero { padding: 40px 0 36px; } .sx-pd-hero__checks { grid-template-columns: 1fr; } .sx-pd-hero .sx-btn { width: 100%; } }

.sx-pd-problems { display: grid; gap: 14px; max-width: 980px; margin: 0 auto; }
.sx-pd-problem { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); background: #fff; border: 1px solid var(--sx-line); border-radius: var(--sx-radius); overflow: hidden; }
.sx-pd-problem > div { padding: 20px 22px; }
.sx-pd-problem p { margin: 6px 0 0; font-size: 16px; }
.sx-pd-problem__bad p { color: var(--sx-muted); }
.sx-pd-problem__good { background: var(--sx-primary-50); }
.sx-pd-problem__good p { color: var(--sx-ink); font-weight: 500; }
.sx-pd-tag { display: inline-block; font-family: var(--sx-font-head); font-size: 12.5px; font-weight: 600; letter-spacing: .04em; color: var(--sx-primary); }
.sx-pd-tag--bad { color: #b4232c; }
@media (max-width: 640px) { .sx-pd-problem { grid-template-columns: 1fr; } }

.sx-pd-feature { position: relative; padding: 24px; }
.sx-pd-feature h3 { font-size: 18px; }
.sx-pd-feature p { font-size: 15px; }
.sx-pd-feature__no { position: absolute; top: 18px; right: 20px; font-family: var(--sx-font-head); font-weight: 600; font-size: 14px; color: #b9c8e4; }

.sx-pd-shots { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.sx-pd-shot { display: flex; flex-direction: column; text-decoration: none !important; color: var(--sx-body); }
.sx-pd-shot__img { display: block; aspect-ratio: 16 / 9; border-radius: 12px; overflow: hidden; border: 1px solid var(--sx-line); background: var(--sx-soft); margin-bottom: 12px; transition: box-shadow .2s, transform .2s; }
.sx-pd-shot__img img { width: 100%; height: 100%; object-fit: cover; object-position: top center; }
.sx-pd-shot:hover .sx-pd-shot__img { box-shadow: var(--sx-shadow-lg); transform: translateY(-2px); }
.sx-pd-shot strong { font-family: var(--sx-font-head); font-weight: 600; color: var(--sx-ink); font-size: 15.5px; line-height: 1.4; }
.sx-pd-shot span:not(.sx-pd-shot__img) { font-size: 14px; color: var(--sx-muted); margin-top: 4px; line-height: 1.6; }
@media (max-width: 991px) { .sx-pd-shots { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .sx-pd-shots { grid-template-columns: 1fr; } .sx-pd-shot:nth-of-type(n+5) { display: none; } }

.sx-pd-video { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); gap: 44px; align-items: center; }
.sx-pd-video p { color: var(--sx-body); margin: 0 0 24px; }
.sx-pd-video__frame { border-radius: 16px; overflow: hidden; box-shadow: var(--sx-shadow-lg); background: #0b2a66; }
.sx-pd-video__frame video { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; }
@media (max-width: 991px) { .sx-pd-video { grid-template-columns: 1fr; gap: 28px; } }

.sx-pd-steps { list-style: none; counter-reset: sxstep; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 16px; padding: 0; margin: 0 0 72px; }
.sx-pd-steps li { counter-increment: sxstep; position: relative; background: #fff; border: 1px solid var(--sx-line); border-radius: var(--sx-radius); padding: 56px 18px 20px; }
.sx-pd-steps li::before { content: counter(sxstep); position: absolute; top: 16px; left: 18px; width: 30px; height: 30px; border-radius: 50%; background: var(--sx-primary); color: #fff; font-family: var(--sx-font-head); font-weight: 600; font-size: 15px; line-height: 30px; text-align: center; }
.sx-pd-steps strong { display: block; font-family: var(--sx-font-head); font-weight: 600; color: var(--sx-ink); font-size: 16.5px; margin-bottom: 6px; }
.sx-pd-steps span { font-size: 14.5px; color: var(--sx-muted); line-height: 1.6; }
@media (max-width: 991px) { .sx-pd-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .sx-pd-steps { grid-template-columns: 1fr; } }

.sx-pd-included { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 44px; align-items: center; background: var(--sx-soft); border-radius: 22px; padding: 44px; }
.sx-pd-included p { color: var(--sx-body); margin: 0; }
.sx-pd-included .sx-checks li:last-child { margin-bottom: 0; }
@media (max-width: 991px) { .sx-pd-included { grid-template-columns: 1fr; gap: 24px; padding: 32px 24px; } }
.sx-pd-shot__img--contain { background: #fff; }
.sx-pd-shot__img--contain img { object-fit: contain; object-position: center; }


/* ===== หน้าต่างดูรูป (fancybox 3.5.7): โทนเดียวกับ present.sysevo.co.th = พื้นเข้ม ปุ่มกลม คำอธิบายอยู่ล่าง ===== */
.fancybox-bg { background: #070d1c !important; }
.fancybox-is-open .fancybox-bg { opacity: .96; }
.fancybox-slide--image { padding: 64px 84px 96px; }
.fancybox-image { border-radius: 12px; background: #fff; box-shadow: 0 12px 48px rgba(0, 0, 0, .45); }
.fancybox-infobar { display: none !important; }
.fancybox-toolbar { top: 18px; right: 20px; }
.fancybox-button, .fancybox-button:link, .fancybox-button:visited { color: #fff; }
.fancybox-button { background: rgba(255, 255, 255, .12); border-radius: 50%; transition: background .2s; }
.fancybox-button:hover { background: rgba(255, 255, 255, .26); }
.fancybox-button--close { width: 46px; height: 46px; padding: 12px; }
.fancybox-navigation .fancybox-button { width: 50px; height: 50px; padding: 0; top: calc(50% - 25px); background-clip: border-box; margin: 0 18px; }
.fancybox-navigation .fancybox-button div { padding: 13px; }
.fancybox-navigation .fancybox-button--arrow_left, .fancybox-navigation .fancybox-button--arrow_right { padding: 0; }
.fancybox-caption { background: none; padding: 0 90px 26px; font-family: "IBM Plex Sans Thai", sans-serif; font-size: 15px; color: #fff; }
.fancybox-caption--separate { margin-top: 0; }
.fancybox-caption .sx-fb-cap { font-weight: 500; }
.fancybox-caption .sx-fb-count { margin-left: 14px; color: #9fb0cc; font-size: 14px; white-space: nowrap; }
body.fancybox-active .sx-cookie { display: none !important; }
@media (max-width: 700px) {
   .fancybox-slide--image { padding: 64px 10px 118px; }
   .fancybox-caption { padding: 0 14px 18px; font-size: 13px; }
   .fancybox-navigation .fancybox-button { width: 42px; height: 42px; top: auto; bottom: 62px; margin: 0 10px; }
   .fancybox-navigation .fancybox-button div { padding: 10px; }
}
