
/* === assets/css/base.css === */
/* ========== Font: Kanit ========== */

@font-face {
  font-family: "Kanit";
  src: url("../fonts/kanit/Kanit-Regular.woff2") format("woff2");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "Kanit";
  src: url("../fonts/kanit/Kanit-Medium.woff2") format("woff2");
  font-style: normal;
  font-weight: 500;
  font-display: swap;
}

@font-face {
  font-family: "Kanit";
  src: url("../fonts/kanit/Kanit-SemiBold.woff2") format("woff2");
  font-style: normal;
  font-weight: 600;
  font-display: swap;
}

@font-face {
  font-family: "Kanit";
  src: url("../fonts/kanit/Kanit-Bold.woff2") format("woff2");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}

/* ========== Global Design System ========== */

:root {
  --black:#000;
  --white:#fff;
  --gray:#f5f7fa;
  --mid:#6f7880;
  --accent:#0b7bdc;

  --container:1180px;
  --g:24px;

  /* &#3621;&#3604;&#3594;&#3656;&#3629;&#3591;&#3623;&#3656;&#3634;&#3591;&#3607;&#3633;&#3657;&#3591;&#3619;&#3632;&#3610;&#3610; */
  --section-y:48px;
  --section-y-sm:36px;

  --title-xl:clamp(34px,4.5vw,56px);
  --title-lg:clamp(28px,3.2vw,42px);
  --title-md:24px;

  --text-lg:20px;
  --text:17px;
  --text-sm:14px;

  --radius:12px;
  --radius-sm:5px;

  --gallery-gap:10px;
  --gallery-radius:5px;

  --shadow:0 12px 30px rgba(0,0,0,.08);
  --shadow-sm:0 6px 18px rgba(0,0,0,.06);
}

html{
  scrollbar-gutter:stable;
}

*{
  box-sizing:border-box;
}

body,
button,
input,
textarea,
select{
  font-family:"Kanit", system-ui, -apple-system, "Segoe UI", sans-serif;
}

body{
  margin:0;
  color:#111;
  line-height:1.7;
  background:#fff;
  -webkit-font-smoothing:antialiased;
}

a{
  color:inherit;
  text-decoration:none;
}

ul{
  margin:0;
  padding:0;
}

img{
  max-width:100%;
  height:auto;
}

/* ========== Layout ========== */

.row{
  width:100%;
}

.wrap{
  width:100%;
  max-width:var(--container);
  margin-left:auto;
  margin-right:auto;
  padding-left:var(--g);
  padding-right:var(--g);
}

/* &#3588;&#3640;&#3617;&#3619;&#3632;&#3618;&#3632;&#3627;&#3656;&#3634;&#3591;&#3585;&#3621;&#3634;&#3591;&#3649;&#3610;&#3610;&#3614;&#3629;&#3604;&#3637; &#3652;&#3617;&#3656;&#3651;&#3627;&#3657;&#3607;&#3640;&#3585; section &#3626;&#3641;&#3591;&#3648;&#3585;&#3636;&#3609; */
section[data-section]{
  padding-top:var(--section-y);
  padding-bottom:var(--section-y);
}

/* Section &#3607;&#3637;&#3656;&#3652;&#3617;&#3656;&#3588;&#3623;&#3619;&#3617;&#3637; padding &#3626;&#3641;&#3591; */
section[data-section="banner"]{
  padding-top:0;
  padding-bottom:0;
}

section[data-section="topbar"],
section[data-section="header"]{
  padding-top:0;
  padding-bottom:0;
}

/* Fine tune spacing &#3619;&#3634;&#3618; section */
section[data-section="intro"]{
  padding-top:42px;
  padding-bottom:30px;
}

section[data-section="social-top"]{
  padding-top:0;
  padding-bottom:32px;
}

section[data-section="services"]{
  padding-top:48px;
  padding-bottom:38px;
}

section[data-section="products"]{
  padding-top:48px;
  padding-bottom:48px;
}

section[data-section="gallery"]{
  padding-top:34px;
  padding-bottom:52px;
}

section[data-section="info"],
section[data-section="info-page"]{
  padding-top:50px;
  padding-bottom:50px;
}

section[data-section="map"]{
  padding-top:0;
  padding-bottom:0;
}

section[data-section="tagsbar"]{
  padding-top:0;
  padding-bottom:0;
}

/* ========== Typography ========== */

section[data-section] h1,
section[data-section] h2,
section[data-section] .title,
section[data-section] .section-title,
section[data-section] .sec-title,
section[data-section] .main-title,
section[data-section] [data-key*="title"],
section[data-section] [data-key*="heading"]{
  font-size:var(--title-lg);
  line-height:1.15;
  font-weight:800;
  letter-spacing:-.02em;
  margin-top:0;
  margin-bottom:18px;
}

section[data-section] h3,
section[data-section] h4{
  font-size:var(--title-md);
  line-height:1.35;
  font-weight:700;
  margin-top:22px;
  margin-bottom:10px;
}

section[data-section] p,
section[data-section] li,
section[data-section] .lead{
  font-size:var(--text);
  line-height:1.8;
}

/* ========== Components ========== */

section[data-section] .btn,
section[data-section] .theme-btn,
section[data-section] .map-placeholder-btn,
section[data-section] .load-map-btn,
section[data-section] .load-fanpage-btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:46px;
  padding:11px 22px;
  border-radius:999px;
  font-weight:700;
  text-decoration:none;
}

/* &#3652;&#3617;&#3656;&#3649;&#3605;&#3632;&#3611;&#3640;&#3656;&#3617; social-top &#3650;&#3607;&#3619;/&#3652;&#3621;&#3609;&#3660;/&#3648;&#3615;&#3595;&#3610;&#3640;&#3658;&#3585; */
section[data-section="social-top"] .btn,
section[data-section="social-top"] a{
  min-height:unset;
}

/* Card / Image */
section[data-section] .card,
section[data-section] .box,
section[data-section] .mock{
  border-radius:var(--radius);
  overflow:hidden;
}

section[data-section] .mock img,
section[data-section] .svc-img{
  width:100%;
  height:100%;
  object-fit:cover;
}

/* ========== Better defaults by section ========== */

/* Intro */
section[data-section="intro"] .wrap{
  max-width:980px;
  text-align:center;
}

section[data-section="intro"] .title{
  font-size:var(--title-xl);
}

section[data-section="intro"] .lead{
  font-size:var(--text-lg);
  max-width:900px;
  margin-left:auto;
  margin-right:auto;
}

section[data-section="intro"] .divider{
  width:110px;
  margin:0 auto 26px;
}

/* Services */
section[data-section="services"] .wrap{
  max-width:1180px;
}

section[data-section="services"] .grid{
  display:grid;
  grid-template-columns:minmax(0,1fr) minmax(420px,520px);
  gap:56px;
  align-items:center;
}

section[data-section="services"] h2{
  font-size:var(--title-xl);
}

section[data-section="services"] .mock{
  border:0 !important;
  box-shadow:var(--shadow);
  background:#f4f6f8;
}

section[data-section="services"] .btn{
  margin-top:16px;
  box-shadow:var(--shadow-sm);
}

/* Gallery */
section[data-section="gallery"] .wrap{
  max-width:1180px;
}

section[data-section="gallery"] h2,
section[data-section="gallery"] .title{
  text-align:center;
}

section[data-section="gallery"] .grid,
section[data-section="gallery"] .grid-gal{
  gap:var(--gallery-gap) !important;
}

section[data-section="gallery"] .gal-item{
  border-radius:var(--gallery-radius) !important;
}

section[data-section="gallery"] img{
  border-radius:0;
  box-shadow:none;
}

/* Tagsbar */
.tagsbar .wrap{
  max-width:1180px;
  margin:0 auto;
  padding-left:var(--g);
  padding-right:var(--g);
}

/* Footer */
footer .wrap{
  max-width:1180px;
  margin:0 auto;
  padding-left:var(--g);
  padding-right:var(--g);
}

footer .footer-info .grid{
  max-width:760px;
  margin:0 auto;
  text-align:center;
}

/* ========== Word Wrap ========== */

body,
body p,
body h1, body h2, body h3, body h4, body h5, body h6,
body li,
section[data-section] h1,
section[data-section] h2,
section[data-section] h3,
section[data-section] h4,
section[data-section] h5,
section[data-section] h6,
section[data-section] p,
section[data-section] li,
section[data-section] .title,
section[data-section] .lead,
section[data-section] .name,
section[data-section] .meta,
section[data-section] [data-edit="html"],
section[data-section] [data-editable]{
  white-space:normal !important;
  word-break:normal;
  overflow-wrap:anywhere;
}

/* ========== Responsive ========== */

@media (max-width:900px){
  :root{
    --g:18px;
    --section-y:38px;
    --section-y-sm:30px;

    --title-xl:34px;
    --title-lg:30px;
    --title-md:22px;

    --text-lg:18px;
    --text:16px;
  }

  section[data-section]{
    padding-top:var(--section-y);
    padding-bottom:var(--section-y);
  }

  section[data-section="intro"]{
    padding-top:34px;
    padding-bottom:26px;
  }

  section[data-section="social-top"]{
    padding-top:0;
    padding-bottom:28px;
  }

  section[data-section="services"]{
    padding-top:38px;
    padding-bottom:34px;
  }

  section[data-section="gallery"]{
    padding-top:30px;
    padding-bottom:42px;
  }

  section[data-section="services"] .grid{
    grid-template-columns:1fr;
    gap:34px;
  }
}

/* Banner must have no spacing */
section.row.banner.pxth-sec[data-section="banner"]{
  margin:0 !important;
  padding:0 !important;
}

section.row.banner.pxth-sec[data-section="banner"] .wrap{
  margin:0 auto !important;
  padding:0 !important;
}

section.row.banner.pxth-sec[data-section="banner"] + section{
  margin-top:0 !important;
}


/* PXTH Stage93: restore Kanit normal rendering */
html, body, button, input, textarea, select{
  font-family:'Kanit', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
}


/* === assets/css/section-topbar-header.css === */
/* ================== Topbar ================== */
.topbar{
  background:#0f172a;
  color:#fff;
  font-size:14px;
}

.topbar .wrap{
  max-width:var(--container);
  margin:0 auto;
  padding:0 var(--g);
}

.topbar .grid{
  display:flex;
  align-items:center;
  min-height:42px;
}

.contact{
  display:flex;
  gap:18px;
  flex-wrap:wrap;
  justify-content:center;
}

.flags{
  display:none;
}

/* ================== Header ================== */
header.header{
  background:#fff;
  border-bottom:1px solid rgba(15,23,42,.08);
  position:sticky;
  top:0;
  z-index:100;
  box-shadow:none;
}

.header .wrap{
  max-width:var(--container);
  margin:0 auto;
  padding:0 var(--g);
}

.header .grid{
  display:grid;
  grid-template-columns:auto 1fr;
  align-items:center;
  gap:32px;
  min-height:78px;
}

.logo{
  font-weight:800;
  font-size:24px;
  display:flex;
  align-items:center;
  gap:12px;
  color:#111827;
}

.logo .mark{
  width:30px;
  height:5px;
  border-radius:999px;
  background:var(--global-title-color,#111827);
  display:inline-block;
}

nav ul{
  list-style:none;
  display:flex;
  gap:30px;
  justify-content:flex-end;
  align-items:center;
  flex-wrap:wrap;
}

nav a{
  display:inline-block;
  padding:10px 0;
  font-size:16px;
  font-weight:500;
  color:#111827;
  position:relative;
}

nav a::after{
  content:"";
  position:absolute;
  left:0;
  bottom:4px;
  width:0;
  height:2px;
  border-radius:999px;
  background:var(--global-title-color,#111827);
  transition:.22s;
}

nav a:hover::after{
  width:100%;
}

.search{
  display:none !important;
}

/* ================== Burger + Drawer ================== */
#nav-toggle{
  display:none;
}

.burger{
  display:none;
  align-items:center;
  justify-content:center;
  width:44px;
  height:40px;
  border-radius:10px;
  cursor:pointer;
  background:#f3f4f6;
}

.burger .line{
  position:relative;
  display:block;
  width:24px;
  height:2px;
  background:#111;
  border-radius:2px;
}

.burger .line::before,
.burger .line::after{
  content:"";
  position:absolute;
  left:0;
  right:0;
  height:2px;
  background:#111;
  border-radius:2px;
}

.burger .line::before{
  top:-7px;
}

.burger .line::after{
  top:7px;
}

body .drawer .menu a{
  color:#fff !important;
}

.drawer{
  position:fixed;
  inset:0;
  pointer-events:none;
  z-index:999;
}

.drawer .panel{
  position:absolute;
  right:0;
  top:0;
  height:100%;
  width:clamp(220px, 50vw, 320px);
  background:#0f172a;
  color:#fff;
  transform:translateX(100%);
  transition:.35s cubic-bezier(.22,.61,.36,1);
  padding:26px 22px 32px;
  display:flex;
  flex-direction:column;
  gap:4px;
  box-shadow:none;
}

.drawer .panel .close{
  position:absolute;
  right:14px;
  top:14px;
  width:38px;
  height:38px;
  border-radius:50%;
  background:rgba(255,255,255,.08);
  color:#fff;
  border:1px solid rgba(255,255,255,.15);
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:24px;
  font-weight:700;
  line-height:1;
  font-family: Arial, Helvetica, sans-serif;
  text-align:center;
  cursor:pointer;
  user-select:none;
}

.drawer .panel .title{
  font-weight:800;
  font-size:20px;
  margin:8px 0 14px;
}

.drawer .menu{
  list-style:none;
  margin:16px 0 0;
}

.drawer .menu a{
  display:block;
  padding:15px 4px;
  color:#fff;
  border-bottom:1px solid rgba(255,255,255,.12);
  font-size:17px;
}

.drawer .backdrop{
  position:absolute;
  inset:0;
  background:rgba(0,0,0,.65);
  opacity:0;
  transition:.25s;
}

#nav-toggle:checked ~ .drawer{
  pointer-events:auto;
}

#nav-toggle:checked ~ .drawer .panel{
  transform:none;
}

#nav-toggle:checked ~ .drawer .backdrop{
  opacity:1;
}

/* ================== Mobile ================== */
@media(max-width:900px){
  .topbar .grid{
    justify-content:center;
    text-align:center;
    min-height:auto;
    padding:10px 0;
  }

  .contact{
    gap:10px;
    font-size:13px;
  }

  .header .grid{
    grid-template-columns:1fr auto;
    min-height:68px;
  }

  nav{
    display:none;
  }

  .burger{
    display:flex;
  }
}

/* PXTH mobile drawer half-width + clean close icon */
@media(max-width:900px){
  .drawer .panel{
    width:clamp(220px, 50vw, 320px);
    max-width:50vw;
    min-width:220px;
    padding:24px 18px 24px;
  }
  .drawer .panel .close{
    width:36px;
    height:36px;
    font-size:24px;
    line-height:1;
  }
  .drawer .panel .title{
    margin:6px 0 12px;
    padding-right:44px;
  }
}


/* PXTH mobile drawer close button click fix */
.drawer .panel{
  z-index:1001 !important;
}

.drawer .backdrop{
  z-index:1000 !important;
}

.drawer .panel .close{
  z-index:1002 !important;
  pointer-events:auto !important;
  cursor:pointer !important;
  display:flex !important;
  align-items:center !important;
  justify-content:center !important;
  line-height:1 !important;
  user-select:none !important;
  -webkit-tap-highlight-color:transparent !important;
}


/* PXTH final wp menu no breadcrumb issue */
nav ul li.has-submenu{position:relative}
nav ul li.has-submenu>a{display:inline-flex;align-items:center;gap:6px}
.submenu-caret{font-size:.75em;line-height:1;opacity:.75}
nav ul li.has-submenu>.submenu{position:absolute;top:100%;left:0;min-width:210px;display:none;flex-direction:column;gap:0;padding:8px;margin:0;background:#fff;border:1px solid rgba(15,23,42,.08);border-radius:14px;box-shadow:0 18px 45px rgba(15,23,42,.14);z-index:9999}
nav ul li.has-submenu:hover>.submenu,nav ul li.has-submenu:focus-within>.submenu{display:flex}
nav ul li.has-submenu>.submenu li{width:100%}
nav ul li.has-submenu>.submenu a{display:block;width:100%;padding:10px 12px;white-space:nowrap;border-radius:10px}
nav ul li.has-submenu>.submenu a:hover{background:rgba(15,23,42,.06)}
.drawer .menu li.has-submenu>.submenu{position:static;display:flex;min-width:0;box-shadow:none;border:0;padding:4px 0 4px 16px;margin:4px 0 0;background:transparent}
.drawer .menu li.has-submenu>.submenu a{padding:8px 10px;font-size:.95em;opacity:.9}

/* PXTH mobile header/menu polish 2026-06-24
   - center logo on mobile
   - drawer 70vw
   - drawer text center */
@media (max-width:900px){
  header.header .wrap{
    position:relative !important;
  }
  header.header .grid{
    display:flex !important;
    align-items:center !important;
    justify-content:center !important;
    min-height:68px !important;
    gap:0 !important;
  }
  header.header .burger{
    position:absolute !important;
    left:var(--g,16px) !important;
    top:50% !important;
    transform:translateY(-50%) !important;
    z-index:5 !important;
    display:flex !important;
  }
  header.header .logo{
    position:relative !important;
    left:auto !important;
    right:auto !important;
    margin:0 auto !important;
    display:flex !important;
    justify-content:center !important;
    align-items:center !important;
    text-align:center !important;
    width:auto !important;
    max-width:calc(100% - 120px) !important;
  }
  header.header .logo a{
    justify-content:center !important;
  }
  .drawer .panel{
    width:70vw !important;
    max-width:70vw !important;
    min-width:260px !important;
    padding:26px 22px 28px !important;
    text-align:center !important;
  }
  .drawer .panel .title{
    text-align:center !important;
    padding-right:44px !important;
    padding-left:44px !important;
  }
  .drawer .menu{
    padding:0 !important;
    margin-left:0 !important;
    text-align:center !important;
  }
  .drawer .menu li{
    text-align:center !important;
  }
  .drawer .menu a{
    text-align:center !important;
    justify-content:center !important;
    align-items:center !important;
  }
  .drawer .menu li.has-submenu > .submenu{
    padding-left:0 !important;
    margin-left:0 !important;
    align-items:center !important;
  }
}
@media (max-width:360px){
  .drawer .panel{
    width:78vw !important;
    max-width:78vw !important;
    min-width:0 !important;
  }
}

/* PXTH fix 2026-06-25: responsive drawer align left (requested) */
@media (max-width:900px){
  .drawer .panel{
    width:70vw !important;
    max-width:70vw !important;
    text-align:left !important;
  }
  .drawer .panel .title{
    text-align:left !important;
    padding-left:0 !important;
    padding-right:44px !important;
  }
  .drawer .menu,
  .drawer .menu li{
    text-align:left !important;
    align-items:stretch !important;
  }
  .drawer .menu a{
    text-align:left !important;
    justify-content:flex-start !important;
    align-items:center !important;
  }
  .drawer .menu li.has-submenu > .submenu{
    align-items:stretch !important;
    padding-left:16px !important;
    margin-left:0 !important;
  }
  .drawer .menu li.has-submenu > .submenu a{
    text-align:left !important;
    justify-content:flex-start !important;
  }
}
@media (max-width:360px){
  .drawer .panel{
    width:78vw !important;
    max-width:78vw !important;
  }
}


/* PXTH_SIMPLE_DROPDOWN_MENU_FINAL_20260701
   เรียบ คลีน รองรับเมนูย่อย 2 ระดับ และไม่ชนกับตัวจัดการเมนู */
.nav-desktop ul{gap:0 !important;align-items:stretch !important;}
.nav-desktop > ul > li{position:relative !important;display:flex !important;align-items:center !important;}
.nav-desktop > ul > li > a{display:flex !important;align-items:center !important;gap:6px !important;min-height:42px !important;padding:0 16px !important;border-radius:0 !important;color:#0f172a !important;font-size:15px !important;font-weight:700 !important;line-height:1.2 !important;text-decoration:none !important;}
.nav-desktop > ul > li:hover > a,.nav-desktop > ul > li:focus-within > a{background:#f1f5f9 !important;color:#0f172a !important;}
.nav-desktop a::after{display:none !important;}
.nav-desktop li.has-submenu{position:relative !important;}
.nav-desktop li.has-submenu > .submenu{display:none !important;position:absolute !important;left:0 !important;top:100% !important;min-width:210px !important;margin:0 !important;padding:6px !important;background:#fff !important;border:1px solid #e5e7eb !important;border-radius:4px !important;box-shadow:0 14px 30px rgba(15,23,42,.14) !important;z-index:10000 !important;}
.nav-desktop li.has-submenu:hover > .submenu,.nav-desktop li.has-submenu:focus-within > .submenu{display:block !important;}
.nav-desktop .submenu li{display:block !important;position:relative !important;margin:0 !important;width:100% !important;white-space:nowrap !important;}
.nav-desktop .submenu a{display:flex !important;align-items:center !important;justify-content:space-between !important;gap:14px !important;padding:9px 12px !important;border-radius:3px !important;color:#0f172a !important;font-size:14px !important;font-weight:600 !important;line-height:1.25 !important;text-decoration:none !important;}
.nav-desktop .submenu a:hover,.nav-desktop .submenu li:focus-within > a{background:#f1f5f9 !important;color:#0f172a !important;}
.nav-desktop .submenu .submenu{left:100% !important;top:-6px !important;margin-left:6px !important;}
.submenu-caret{font-size:10px !important;line-height:1 !important;opacity:.7 !important;margin-left:2px !important;}
.drawer .menu li.has-submenu > .submenu{position:static !important;display:block !important;padding-left:16px !important;margin:4px 0 0 !important;background:transparent !important;border:0 !important;box-shadow:none !important;}
.drawer .menu li.has-submenu > .submenu a{padding:8px 10px !important;font-size:.95em !important;opacity:.95 !important;}
.drawer .menu li.has-submenu > .submenu .submenu{padding-left:18px !important;}


/* PXTH_SUBMENU_LEVEL2_RIGHT_FIXED_20260701
   ให้เมนูย่อยระดับ 2 เปิดออกด้านขวาของเมนูย่อยระดับแรก ไม่ทับกัน */
.nav-desktop .submenu > li.has-submenu{position:relative !important;}
.nav-desktop .submenu > li.has-submenu > .submenu{
  left:100% !important;
  right:auto !important;
  top:0 !important;
  margin-left:4px !important;
  margin-top:0 !important;
  min-width:210px !important;
  z-index:10001 !important;
}
.nav-desktop .submenu > li.has-submenu:hover > .submenu,
.nav-desktop .submenu > li.has-submenu:focus-within > .submenu{
  display:block !important;
}
.nav-desktop .submenu > li.has-submenu > a .submenu-caret{
  transform:rotate(-90deg);
}

/* PXTH_MOBILE_DRAWER_COLLAPSIBLE_MENU_20260701
   มือถือ: ซ่อนซับเมนูไว้ก่อน แล้วกดเมนูหลักเพื่อยุบ/ขยาย */
@media (max-width:900px){
  .drawer .menu li.has-submenu > .submenu{
    display:none !important;
    padding-left:18px !important;
    margin:0 !important;
    background:transparent !important;
    border:0 !important;
    box-shadow:none !important;
  }
  .drawer .menu li.has-submenu.open > .submenu{
    display:block !important;
  }
  .drawer .menu li.has-submenu > a{
    display:flex !important;
    align-items:center !important;
    justify-content:space-between !important;
    gap:12px !important;
  }
  .drawer .menu li.has-submenu > a .submenu-caret{
    margin-left:auto !important;
    width:26px !important;
    min-width:26px !important;
    height:26px !important;
    display:inline-flex !important;
    align-items:center !important;
    justify-content:center !important;
    border-radius:999px !important;
    background:rgba(255,255,255,.08) !important;
    color:#fff !important;
    opacity:1 !important;
    font-size:0 !important;
    line-height:1 !important;
    transform:none !important;
  }
  .drawer .menu li.has-submenu > a .submenu-caret::before{
    content:'+';
    font-size:18px !important;
    font-weight:800 !important;
    line-height:1 !important;
  }
  .drawer .menu li.has-submenu.open > a .submenu-caret::before{
    content:'−';
  }
  .drawer .menu li.has-submenu.open > a{
    color:#fff !important;
  }
  .drawer .menu li.has-submenu > .submenu a{
    padding:12px 10px !important;
    font-size:.95em !important;
    opacity:.95 !important;
  }
}


/* === assets/css/section-misc.css === */
/* ================== Generic carousel ================== */
.carousel{position:relative}
.carousel .viewport{overflow:hidden;user-select:none;cursor:grab}
.carousel .viewport:active{cursor:grabbing}
.carousel .track{display:flex;gap:26px;transition:transform .45s ease}
.carousel .track li{list-style:none}
.carousel .nav{
  z-index:9999;
  position:absolute;
  top:50%;
  transform:translateY(-50%) !important;
  background:#fff;
  border:1px solid #eee;
  border-radius:999px;
  width:36px;
  height:36px;
  display:grid;
  place-items:center;
  cursor:pointer;
  box-shadow:var(--shadow);
}
.carousel .nav.prev{left:8px !important}
.carousel .nav.next{right:8px !important}
.carousel .nav[disabled]{opacity:.35;pointer-events:none}
.carousel .dots{
  display:flex;
  gap:10px;
  justify-content:center;
  margin:16px 0 0;
}
.carousel .dots button{
  width:8px;
  height:8px;
  border-radius:50%;
  border:0;
  background:#ddd;
  cursor:pointer;
}
.carousel .dots button.active{
  width:36px;
  height:10px;
  border-radius:999px;
  background:#ff5a3c;
}

/* ================== Lightbox ================== */
.lightbox[hidden]{display:none}
.lightbox{
  position:fixed;
  inset:0;
  z-index:60;
}
.lb-backdrop{
  position:absolute;
  inset:0;
  background:rgba(0,0,0,.65);
  backdrop-filter: blur(2px);
}
.lb-fig{
  position:absolute;
  inset:6% 4%;
  display:grid;
  place-items:center;
}
.lb-fig img{
  max-width:100%;
  max-height:100%;
  object-fit:contain;
}
.lb-close,
.lb-prev,
.lb-next{
  position:absolute;
  background:#fff;
  border:1px solid #eee;
  border-radius:999px;
  width:44px;
  height:44px;
  display:grid;
  place-items:center;
  cursor:pointer;
  box-shadow:var(--shadow);
  z-index:2;
}
.lb-close{top:8px;right:8px}
.lb-prev{left:8px;top:50%;transform:translateY(-50%)}
.lb-next{right:8px;top:50%;transform:translateY(-50%)}

/* ================== Section dynamic color (จาก editor) ================== */
section[data-section]{
  background-color:var(--sec-bg,transparent) !important;
  color:var(--sec-color,inherit);
}

/* ================== Topbar ticker (mobile) ================== */
@media (max-width:900px){
  .topbar .contact{
    display:block !important;
    position:relative !important;
    height:1.6em !important;
    line-height:1.6em !important;
    overflow:hidden !important;
    width:100% !important;
  }
  .topbar .contact > span{
    position:absolute !important;
    left:0;right:0;
    white-space:nowrap !important;
    opacity:0;
    transform:translateY(8px);
    animation:topbar-rotate 9s infinite;
    will-change:opacity,transform;
  }
  .topbar .contact > span:nth-child(1){animation-delay:0s}
  .topbar .contact > span:nth-child(2){animation-delay:3s}
  .topbar .contact > span:nth-child(3){animation-delay:6s}

  @keyframes topbar-rotate{
    0%{opacity:0;transform:translateY(8px)}
    5%{opacity:1;transform:translateY(0)}
    30%{opacity:1;transform:translateY(0)}
    35%{opacity:0;transform:translateY(-8px)}
    100%{opacity:0;transform:translateY(-8px)}
  }
}

/* ตอนแก้ไข ไม่ต้องให้ topbar วิ่ง */
html[data-edit="1"] .topbar .contact{
  height:auto !important;
  overflow:visible !important;
}
html[data-edit="1"] .topbar .contact > span{
  position:static !important;
  animation:none !important;
  opacity:1 !important;
  transform:none !important;
}

/* ================== Responsive ================== */
@media (max-width:1100px){
  .grid-gal.active{grid-template-columns:repeat(3,minmax(0,1fr))}
}
@media (max-width:1024px){
  .info-grid{grid-template-columns:1fr;gap:24px}
}
@media (max-width:900px){
  .burger{display:flex}
  nav{display:none}
  .header .grid{grid-template-columns:auto 1fr auto}
  .services .grid{grid-template-columns:1fr;gap:20px}
  .footer-info .grid{grid-template-columns:1fr}
  #ytCarousel .viewport{padding-inline:40px}
}
@media (max-width:640px){
  .search input{max-width:190px}
  .grid-gal.active{grid-template-columns:repeat(2,minmax(0,1fr))}
  #ytCarousel .viewport{padding-inline:0}
}

/* ================== Lazy embed helpers ================== */
.lazy-box{
  display:flex;
  align-items:center;
  justify-content:center;
  background:#f5f6f7;
  border:1px solid #eee;
  border-radius:12px;
  min-height:220px;
  overflow:hidden;
}

/* แฟนเพจสูงกว่าหน่อย */
.fb-box.lazy-box{
  min-height:260px;
}

/* กล่องวิดีโอ */
#ytCarousel .vid.lazy-box{
  min-height:220px;
  background:#000;
}

/* ปุ่มโหลด embed */
.lazy-embed__btn{
  appearance:none;
  border:0;
  cursor:pointer;
  padding:10px 16px;
  border-radius:999px;
  background:#111;
  color:#fff;
  font-weight:600;
  box-shadow:0 6px 18px rgba(0,0,0,.16);
}


/* === assets/css/section-footer.css === */
/* ================== Footer V2 ================== */

/* Keyword footer */
.footer-key{
  background:#0f172a;
  color:#fff;
}

.footer-key .wrap{
  max-width:var(--container);
  margin:0 auto;
  padding:36px var(--g);
}

.footer-key .keywords{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  justify-content:center;
}

.footer-key .tag{
  background:rgba(255,255,255,.10);
  border:1px solid rgba(255,255,255,.12);
  color:#fff;
  padding:7px 13px;
  border-radius:999px;
  font-size:14px;
}

/* Main footer info */
.footer-info{

}

.footer-info .wrap{
  max-width:var(--container);
  margin:0 auto;
  padding:64px var(--g) 36px;
}

.footer-info .grid{
  display:grid;
  grid-template-columns:1fr;
  gap:22px;
  max-width:760px;
  margin:0 auto;
  text-align:center;
}

.footer-info [data-edit="html"],
.footer-info p,
.footer-info h2,
.footer-info h3{
  text-align:center;
}

.footer-info h2,
.footer-info h3{
  font-size:var(--title-lg);
  line-height:1.25;
  font-weight:800;
  margin:0 0 16px;
}

.footer-info p,
.footer-info [data-edit="html"]{
  font-size:16px;
  line-height:1.85;
}

/* Social footer */
.footer-social{
  border-top:1px solid rgba(15,23,42,.08);
}

.footer-social .wrap{
  max-width:var(--container);
  margin:0 auto;
  padding:26px var(--g) 34px;
  display:flex;
  align-items:center;
  justify-content:center;
  flex-direction:column;
  gap:14px;
}

.social{
  display:flex;
  gap:12px;
  justify-content:center;
  align-items:center;
}

footer .footer-social .social a{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:40px;
  height:40px;
  border-radius:999px;
  text-decoration:none;
  line-height:1;
  background:var(--footer-icon-bg,rgba(15,23,42,.08));
  border:1px solid var(--footer-icon-br,rgba(15,23,42,.10));
  color:currentColor;
  transition:.2s ease;
}

footer .footer-social .social a:hover{
  transform:translateY(-3px);
  background:rgba(15,23,42,.12);
}

footer .footer-social .social a + a{
  margin-left:0;
}

.copy{
  font-size:14px;
  line-height:1.6;
  text-align:center;
}

/* Mobile */
@media(max-width:768px){
  .footer-key .wrap{
    padding:28px var(--g);
  }

  .footer-info .wrap{
    padding:48px var(--g) 30px;
  }

  .footer-social .wrap{
    padding:22px var(--g) 28px;
  }
}

footer .footer-info .footer-title,
footer .footer-info h3.footer-title,
footer .footer-info [data-key="ft-company"]{
  font-size:32px !important;
  line-height:1.15 !important;
  font-weight:800 !important;
  margin:0 0 16px !important;
}


/* === assets/css/section-tagsbar.css === */
/* =============== Tagsbar =============== */

.tagsbar{
  background:var(--global-title-color,#0b72d9);
  color:#fff;
  overflow:hidden;
}

.tagsbar .wrap{
  width:100%;
  max-width:none;
  margin:0 auto;
  padding:28px var(--g);
  overflow:hidden;
}

.tagsbar-inner{
  width:100%;
  max-width:none;
  margin:0 auto;
  text-align:center;
  overflow:hidden;
}

.tagsbar-field{
  display:block;
  width:100%;
  padding:8px 18px;
  box-sizing:border-box;
  text-align:center;
  font-size:28px;
  line-height:1.35;
  font-weight:800;
  white-space:normal;
  word-break:normal;
  overflow-wrap:anywhere;
}

.tagsbar-marquee-text{
  font-size:inherit;
  font-weight:inherit;
  line-height:inherit;
}

/* Edit mode outline */
html[data-edit] .tagsbar-field[data-editable]{
  outline:2px dashed rgba(255,255,255,.65);
  outline-offset:4px;
}

/* Mobile marquee */
@media(max-width:768px){
  .tagsbar .wrap{
    padding:18px 0;
  }

  .tagsbar-inner{
    white-space:nowrap;
  }

  .tagsbar-field{
    display:block;
    width:100%;
    overflow:hidden;
    padding:0;
    white-space:nowrap !important;
    font-size:24px;
    line-height:1.45;
  }

  .tagsbar-marquee-text{
    display:inline-block;
    padding-left:100%;
    white-space:nowrap;
    animation:tagsbar-marquee 16s linear infinite;
  }

  @keyframes tagsbar-marquee{
    from{
      transform:translateX(0);
    }
    to{
      transform:translateX(-100%);
    }
  }
}

/* Edit mode: &#3627;&#3618;&#3640;&#3604;&#3623;&#3636;&#3656;&#3591; */
html[data-edit] .tagsbar-marquee-text{
  animation:none !important;
  transform:none !important;
  padding-left:0 !important;
  white-space:normal !important;
}

html[data-edit] .tagsbar-field{
  white-space:normal !important;
  overflow:visible !important;
  padding:8px 18px !important;
}


/* === assets/styles.css === */
/* === MASTER STYLE LOADER === */
/* PXTH: @import ถูกแยกไป preload แบบ async ใน index.php แล้ว เพื่อลด Render-blocking requests */

/* PXTH_TEXT_BULLET_FRONTEND_FORCE_GLOBAL */
.custom-block .block-text ul,
.custom-block .block-text ol,
.custom-block [data-custom-html] ul,
.custom-block [data-custom-html] ol,
.block-text ul,
.block-text ol{
  padding-left:42px !important;
  margin-left:0 !important;
  list-style-position:outside !important;
}
.custom-block .block-text li,
.custom-block [data-custom-html] li,
.block-text li{
  padding-left:8px !important;
  margin:6px 0 !important;
}
.block-text ul.pxth-list-align-center,
.block-text ol.pxth-list-align-center,
[data-custom-html] ul.pxth-list-align-center,
[data-custom-html] ol.pxth-list-align-center{
  display:table !important;
  margin-left:auto !important;
  margin-right:auto !important;
  padding-left:34px !important;
  text-align:left !important;
}
.block-text ul.pxth-list-align-right,
.block-text ol.pxth-list-align-right,
[data-custom-html] ul.pxth-list-align-right,
[data-custom-html] ol.pxth-list-align-right{
  display:table !important;
  margin-left:auto !important;
  margin-right:0 !important;
  padding-left:34px !important;
  text-align:left !important;
}


/* PXTH PageSpeed Safe Optimize 1782144457 */
img, video {
  max-width: 100%;
  height: auto;
}

iframe {
  max-width: 100%;
}

.pxth-visitor-mode .pxth-editor-only,
.pxth-visitor-mode [data-editor-only] {
  display: none !important;
}

/* Make lazy iframe placeholders stable */
iframe[loading="lazy"] {
  background: #f1f5f9;
}


/* PXTH SAFE CLS FIX: ห้ามใช้ content-visibility กับ section เพราะทำให้ Lighthouse นับ layout shift ได้
   จองพื้นที่ header/banner/image ให้แน่นอนโดยไม่เปลี่ยนเลย์เอาต์เดิม */
.topbar{min-height:42px;}
header.header{min-height:78px;}
header.header .grid{min-height:78px;}
header .logo img.logo-img{width:auto;max-height:56px;aspect-ratio:1/1;}
.block-banner-image{aspect-ratio:1900/700;min-height:0;}
.block-banner-real{display:block;width:100%;height:100%;object-fit:cover;}
.block-image-box,.block-product-image,.block-news-image,.block-gallery-image,.block-gallery-image-item{aspect-ratio:16/9;}
.block-image-box img,.block-product-image img,.block-news-image img,.block-gallery-image img,.block-gallery-image-item img,.product-image-real{display:block;width:100%;height:100%;object-fit:cover;}
.floating-contact,.float-contact,.contact-floating{position:fixed!important;}


/* PXTH PageSpeed real image boxes */
.block-news-image{position:relative;overflow:hidden;background:#eef2f7}
.block-news-image .block-news-img-real{width:100%;height:100%;display:block;object-fit:cover}
.block-gallery-image-item img{width:100%;height:100%;object-fit:cover;display:block}
.block-image-box img,.block-banner-image img{display:block}



/* PXTH_CLEAN_DB_PRODUCT_BLOCK_REWRITE
   Product Block ใหม่ใช้ class pxth-clean-* เท่านั้น ไม่พึ่ง legacy .block-products */
.custom-block[data-block-type="product"],
.custom-block[data-block-type="product"] *{box-sizing:border-box;}
.custom-block[data-block-type="product"]{width:100%;max-width:100%;min-width:0;overflow:hidden;isolation:auto;}
.pxth-clean-product-block{width:100%;max-width:100%;min-width:0;overflow:hidden;}
.pxth-clean-product-items{width:100%;max-width:100%;min-width:0;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px;align-items:stretch;}
.pxth-clean-product-card{width:100%;max-width:100%;min-width:0;display:flex;flex-direction:column;overflow:hidden;background:#fff;border:1px solid #e5e7eb;border-radius:16px;box-shadow:0 10px 24px rgba(15,23,42,.06);}
.pxth-clean-product-thumb{display:flex;align-items:center;justify-content:center;width:100%;aspect-ratio:16/10;background:#eef2f7;color:#8a8f98;text-decoration:none;overflow:hidden;}
.pxth-clean-product-thumb img{display:block;width:100%;height:100%;object-fit:cover;max-width:none;}
.pxth-clean-product-placeholder{font-size:34px;font-weight:800;color:#8a8f98;letter-spacing:.04em;}
.pxth-clean-product-body{display:flex;flex-direction:column;gap:8px;padding:16px;min-width:0;}
.pxth-clean-product-body h3{margin:0!important;font-size:22px!important;line-height:1.25!important;font-weight:900!important;letter-spacing:-.02em!important;overflow-wrap:anywhere;}
.pxth-clean-product-body h3 a{color:inherit;text-decoration:none;}
.pxth-clean-product-price{font-size:15px;font-weight:900;color:#111827;}
.pxth-clean-product-price del{opacity:.55;margin-right:5px;}
.pxth-clean-product-desc{margin:0!important;font-size:14px!important;line-height:1.65!important;color:#64748b;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;}
.pxth-clean-product-actions{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:auto;}
.pxth-clean-product-actions a{display:inline-flex;align-items:center;justify-content:center;min-height:38px;padding:8px 10px;border-radius:10px;text-decoration:none;font-size:13px;font-weight:900;line-height:1.2;white-space:nowrap;}
.pxth-clean-product-detail{background:#eef2f7;color:#111827;}
.pxth-clean-product-line{background:#06c755;color:#fff;}
.pxth-clean-product-empty{grid-column:1/-1;width:100%;padding:24px;border:1px dashed #cbd5e1;border-radius:14px;background:#f8fafc;color:#64748b;font-weight:900;text-align:center;}
.pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-items{grid-template-columns:1fr;}
.pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-card{display:grid;grid-template-columns:minmax(170px,34%) minmax(0,1fr);align-items:stretch;}
.pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-thumb{height:100%;aspect-ratio:auto;min-height:180px;}
.pxth-clean-product-block[data-product-view="carousel"]{position:relative;}
.pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-items{display:flex;gap:18px;overflow-x:auto;overflow-y:hidden;scroll-snap-type:x mandatory;scroll-behavior:smooth;scrollbar-width:none;-ms-overflow-style:none;}
.pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-items::-webkit-scrollbar{display:none;width:0;height:0;}
.pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-card{flex:0 0 calc((100% - 36px)/3);scroll-snap-align:start;}
.pxth-clean-product-nav{display:flex;justify-content:flex-end;gap:8px;margin:0 0 12px;}
.pxth-clean-product-nav button{width:38px;height:38px;border:0;border-radius:999px;background:#111827;color:#fff;font-size:28px;font-weight:900;line-height:1;cursor:pointer;box-shadow:0 8px 20px rgba(15,23,42,.14);}
@media(max-width:900px){.pxth-clean-product-items{grid-template-columns:repeat(2,minmax(0,1fr));}.pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-card{flex-basis:calc((100% - 18px)/2);}.pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-card{grid-template-columns:1fr;}.pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-thumb{aspect-ratio:16/10;min-height:0;}}
@media(max-width:760px){.pxth-clean-product-items{grid-template-columns:1fr;}.pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-card{flex-basis:100%;}.pxth-clean-product-actions{grid-template-columns:1fr;}.pxth-clean-product-nav{justify-content:center;}}

.pxth-clean-product-settings-panel{max-width:760px!important;}
.pxth-clean-product-view-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;}
.pxth-clean-product-view-options label{display:flex;align-items:center;justify-content:center;gap:8px;min-height:54px;border:1px solid #d8dee9;border-radius:14px;background:#fff;font-weight:900;color:#111827;cursor:pointer;}
.pxth-clean-product-view-options input{width:18px;height:18px;margin:0;}
.pxth-clean-product-count-row{display:grid;grid-template-columns:44px minmax(100px,160px) 44px;gap:10px;align-items:center;}
.pxth-clean-product-count-row button{width:44px;height:42px;border:0;border-radius:12px;background:#0f172a;color:#fff;font-size:24px;font-weight:900;line-height:1;cursor:pointer;}
.pxth-clean-product-count-row input{width:100%;height:42px;border:1px solid #cbd5e1;border-radius:12px;text-align:center;font-size:16px;font-weight:900;background:#fff;color:#111827;}
@media(max-width:620px){.pxth-clean-product-view-options{grid-template-columns:1fr}.pxth-clean-product-count-row{grid-template-columns:44px 1fr 44px;}}


/* PXTH_PRODUCT_CLEAN_SETTINGS_FINAL
   Final override: Product Block must not clip its gear controls and must stay inside its own column. */
html[data-edit="1"] .custom-block[data-block-type="product"],
.custom-block[data-block-type="product"]{
  display:block!important;
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  overflow:visible!important;
  position:relative!important;
  isolation:auto!important;
  box-sizing:border-box!important;
}
html[data-edit="1"] .custom-block[data-block-type="product"] > .pxth-block-controls{
  display:inline-flex!important;
  visibility:visible!important;
  opacity:1!important;
  pointer-events:auto!important;
  z-index:2147483000!important;
}
.custom-block[data-block-type="product"] .pxth-clean-product-block{
  display:block!important;
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  overflow:hidden!important;
  box-sizing:border-box!important;
  --pxth-clean-product-cols: var(--pxth-product-cols, 3);
  --pxth-clean-product-mobile-cols: var(--pxth-product-mobile-cols, 1);
}
.custom-block[data-block-type="product"] .pxth-clean-product-items{
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  box-sizing:border-box!important;
  display:grid!important;
  grid-template-columns:repeat(var(--pxth-clean-product-cols,3),minmax(0,1fr))!important;
  gap:18px!important;
  align-items:stretch!important;
}
.custom-block[data-block-type="product"] .pxth-clean-product-card{
  min-width:0!important;
  max-width:100%!important;
  box-sizing:border-box!important;
}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-items{
  grid-template-columns:1fr!important;
}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-card{
  display:grid!important;
  grid-template-columns:minmax(150px,34%) minmax(0,1fr)!important;
  gap:0!important;
}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-items{
  display:flex!important;
  grid-template-columns:none!important;
  gap:18px!important;
  overflow-x:auto!important;
  overflow-y:hidden!important;
  scroll-snap-type:x mandatory!important;
  scroll-behavior:smooth!important;
  scrollbar-width:none!important;
  -ms-overflow-style:none!important;
}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-items::-webkit-scrollbar{display:none!important;width:0!important;height:0!important;}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-card{
  flex:0 0 calc((100% - (18px * (var(--pxth-clean-product-cols,3) - 1))) / var(--pxth-clean-product-cols,3))!important;
  max-width:calc((100% - (18px * (var(--pxth-clean-product-cols,3) - 1))) / var(--pxth-clean-product-cols,3))!important;
  scroll-snap-align:start!important;
}
@media(max-width:760px){
  .custom-block[data-block-type="product"] .pxth-clean-product-items{
    grid-template-columns:repeat(var(--pxth-clean-product-mobile-cols,1),minmax(0,1fr))!important;
  }
  .custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-card{
    display:block!important;
  }
  .custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-card{
    flex:0 0 calc((100% - (14px * (var(--pxth-clean-product-mobile-cols,1) - 1))) / var(--pxth-clean-product-mobile-cols,1))!important;
    max-width:calc((100% - (14px * (var(--pxth-clean-product-mobile-cols,1) - 1))) / var(--pxth-clean-product-mobile-cols,1))!important;
  }
}
.pxth-clean-product-final-modal .pxth-custom-panel{max-width:760px!important;}
.pxth-clean-final-options{display:grid;gap:14px;margin-bottom:14px;}
.pxth-clean-final-card{display:grid;grid-template-columns:28px minmax(0,1fr);gap:12px;align-items:center;padding:16px 18px;border:1px solid #e5e7eb;border-radius:14px;background:#fff;cursor:pointer;}
.pxth-clean-final-card:has(input:checked){border-color:#0b84ff;background:#f8fbff;box-shadow:0 0 0 1px rgba(11,132,255,.12) inset;}
.pxth-clean-final-card input{width:18px;height:18px;margin:0;}
.pxth-clean-final-card strong{display:block;font-size:17px;line-height:1.25;font-weight:900;color:#111827;}
.pxth-clean-final-card small{display:block;margin-top:4px;font-size:13px;line-height:1.35;font-weight:800;color:#64748b;}
.pxth-clean-final-view{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;}
.pxth-clean-final-view label{display:flex;align-items:center;justify-content:center;gap:8px;min-height:44px;border:1px solid #d8dee9;border-radius:12px;background:#fff;font-weight:900;cursor:pointer;}
.pxth-clean-final-view label:has(input:checked){border-color:#0b84ff;background:#f8fbff;color:#0b84ff;}
.pxth-clean-final-view input{width:16px;height:16px;margin:0;}
.pxth-clean-final-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;}
.pxth-clean-final-grid label span{display:block;margin-bottom:6px;font-weight:900;color:#111827;}
.pxth-clean-final-grid select{width:100%;height:42px;border:1px solid #cbd5e1;border-radius:10px;padding:0 10px;background:#fff;font-weight:900;color:#111827;}
.pxth-clean-final-count{display:grid;grid-template-columns:44px minmax(100px,160px) 44px;gap:10px;align-items:center;}
.pxth-clean-final-count button{width:44px;height:42px;border:1px solid #cbd5e1;border-radius:10px;background:#fff;color:#111827;font-size:22px;font-weight:900;cursor:pointer;}
.pxth-clean-final-count input{height:42px;border:1px solid #cbd5e1;border-radius:10px;text-align:center;font-size:16px;font-weight:900;}
@media(max-width:620px){.pxth-clean-final-view,.pxth-clean-final-grid{grid-template-columns:1fr}.pxth-clean-final-count{grid-template-columns:44px 1fr 44px}}


/* PXTH_PRODUCT_CLEAN_LIVE_CATEGORY_CAROUSEL_FIX */
.custom-block[data-block-type="product"]{min-width:0!important;max-width:100%!important;overflow:visible!important;}
.custom-block[data-block-type="product"] .pxth-clean-product-block{width:100%!important;max-width:100%!important;min-width:0!important;overflow:hidden!important;}
.custom-block[data-block-type="product"] .pxth-clean-product-items{width:100%!important;max-width:100%!important;min-width:0!important;}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="grid"] .pxth-clean-product-items,
.custom-block[data-block-type="product"] .pxth-clean-product-block:not([data-product-view]) .pxth-clean-product-items{display:grid!important;grid-template-columns:repeat(var(--pxth-clean-product-cols,3),minmax(0,1fr))!important;gap:18px!important;}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-items{display:grid!important;grid-template-columns:1fr!important;gap:18px!important;overflow:visible!important;}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-items{display:flex!important;gap:18px!important;overflow-x:auto!important;overflow-y:hidden!important;scroll-snap-type:x mandatory!important;scroll-behavior:smooth!important;scrollbar-width:none!important;-ms-overflow-style:none!important;cursor:grab;}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-items:active{cursor:grabbing;}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-card{flex:0 0 calc((100% - (18px * (var(--pxth-clean-product-cols,3) - 1))) / var(--pxth-clean-product-cols,3))!important;max-width:calc((100% - (18px * (var(--pxth-clean-product-cols,3) - 1))) / var(--pxth-clean-product-cols,3))!important;scroll-snap-align:start!important;}
.pxth-clean-product-category-card .pxth-clean-product-thumb{aspect-ratio:16/10!important;}
.pxth-clean-product-final-modal .pxth-custom-panel,.pxth-clean-product-live-modal .pxth-custom-panel{max-width:960px!important;}
.pxth-clean-final-options{display:grid;gap:12px;margin:0 0 14px;}
.pxth-clean-final-card{display:grid!important;grid-template-columns:24px 1fr!important;gap:12px!important;align-items:center!important;min-height:72px!important;padding:14px 16px!important;border:1px solid #d8dee9!important;border-radius:14px!important;background:#fff!important;cursor:pointer!important;}
.pxth-clean-final-card:has(input:checked){border-color:#1683ff!important;background:#f8fbff!important;}
.pxth-clean-final-card input{width:18px!important;height:18px!important;margin:0!important;}
.pxth-clean-final-card strong{display:block!important;font-size:17px!important;line-height:1.25!important;}
.pxth-clean-final-card small{display:block!important;margin-top:4px!important;color:#64748b!important;font-weight:800!important;}
.pxth-clean-final-view{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:12px!important;}
.pxth-clean-final-view label{display:flex!important;align-items:center!important;justify-content:center!important;gap:8px!important;min-height:44px!important;border:1px solid #d8dee9!important;border-radius:12px!important;background:#fff!important;font-weight:900!important;cursor:pointer!important;}
.pxth-clean-final-view label:has(input:checked){border-color:#1683ff!important;color:#1683ff!important;background:#f8fbff!important;}
.pxth-clean-final-count{display:grid!important;grid-template-columns:44px minmax(100px,170px) 44px!important;gap:10px!important;align-items:center!important;}
.pxth-clean-final-count button{width:44px!important;height:42px!important;border:1px solid #cbd5e1!important;border-radius:12px!important;background:#fff!important;color:#0f172a!important;font-size:22px!important;font-weight:900!important;cursor:pointer!important;}
.pxth-clean-final-count input{height:42px!important;border:1px solid #cbd5e1!important;border-radius:12px!important;text-align:center!important;font-size:16px!important;font-weight:900!important;}
.pxth-clean-final-grid{display:grid!important;grid-template-columns:1fr 1fr!important;gap:14px!important;margin:14px 0!important;}
.pxth-clean-final-grid label span{display:block!important;margin:0 0 6px!important;font-weight:900!important;}
.pxth-clean-final-grid select{width:100%!important;height:42px!important;border:1px solid #cbd5e1!important;border-radius:12px!important;padding:0 12px!important;font-weight:900!important;background:#fff!important;}
@media(max-width:760px){.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="grid"] .pxth-clean-product-items{grid-template-columns:repeat(var(--pxth-clean-product-mobile-cols,1),minmax(0,1fr))!important;}.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-card{flex-basis:calc((100% - (14px * (var(--pxth-clean-product-mobile-cols,1) - 1))) / var(--pxth-clean-product-mobile-cols,1))!important;max-width:calc((100% - (14px * (var(--pxth-clean-product-mobile-cols,1) - 1))) / var(--pxth-clean-product-mobile-cols,1))!important;}.pxth-clean-final-view,.pxth-clean-final-grid{grid-template-columns:1fr!important;}}


/* PXTH_PRODUCT_CATEGORY_CARD_CLICK_FIX */
.pxth-clean-product-category-card{
  color:inherit!important;
  text-decoration:none!important;
  cursor:pointer!important;
}
.pxth-clean-product-category-card:hover{
  transform:translateY(-2px);
  box-shadow:0 14px 30px rgba(15,23,42,.10)!important;
}
.pxth-clean-product-category-card .pxth-clean-product-body h3{
  color:inherit!important;
}


/* PXTH PRODUCT SIDEBAR FILTER */
.pxth-clean-product-block{
  width:100%;
  max-width:100%;
  min-width:0;
}
.pxth-product-sidebar-layout{
  display:grid;
  grid-template-columns:minmax(230px,280px) minmax(0,1fr);
  gap:24px;
  align-items:start;
  width:100%;
  max-width:100%;
  min-width:0;
}
.pxth-product-main-area{
  min-width:0;
  width:100%;
}

.pxth-clean-product-block.sidebar-right .pxth-product-sidebar-layout{
  grid-template-columns:minmax(0,1fr) minmax(230px,280px);
}
.pxth-clean-product-block.no-product-sidebar .pxth-product-sidebar-layout{
  grid-template-columns:minmax(0,1fr);
}
.pxth-clean-product-block.no-product-sidebar .pxth-product-mobile-filter-toggle{
  display:none!important;
}
.pxth-product-sidebar{
  display:grid;
  gap:14px;
  width:100%;
  min-width:0;
}
.pxth-product-search-box,
.pxth-product-filter-card{
  border:1px solid #e5e7eb;
  border-radius:18px;
  background:#fff;
  box-shadow:0 12px 36px rgba(15,23,42,.06);
  padding:16px;
}
.pxth-product-search-box label,
.pxth-product-filter-card h3{
  display:block;
  margin:0 0 12px;
  color:#0f172a;
  font-size:16px;
  font-weight:900;
  line-height:1.25;
}
.pxth-product-search-box div{
  display:flex;
  gap:8px;
}
.pxth-product-search-box input,
.pxth-product-filter-form input[type="number"],
.pxth-product-filter-form select{
  width:100%;
  min-width:0;
  height:42px;
  border:1px solid #cbd5e1;
  border-radius:12px;
  background:#fff;
  color:#0f172a;
  padding:0 12px;
  font:800 14px/1.2 Kanit,system-ui,sans-serif;
  box-sizing:border-box;
}
.pxth-product-search-box button,
.pxth-filter-actions button{
  flex:0 0 auto;
  min-height:42px;
  border:0;
  border-radius:12px;
  background:#0f172a;
  color:#fff;
  -webkit-text-fill-color:#fff;
  padding:0 14px;
  font:900 14px/1 Kanit,system-ui,sans-serif;
  cursor:pointer;
}
.pxth-product-filter-card nav{
  display:grid;
  gap:4px;
}
.pxth-product-filter-card nav a{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  min-height:38px;
  padding:8px 10px;
  border-radius:12px;
  color:#334155;
  text-decoration:none;
  font-weight:850;
  line-height:1.25;
}
.pxth-product-filter-card nav a:hover,
.pxth-product-filter-card nav a.active{
  background:#f1f5f9;
  color:#0f172a;
}
.pxth-product-filter-card nav a em{
  flex:0 0 auto;
  min-width:28px;
  height:24px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:999px;
  background:#e2e8f0;
  color:#334155;
  font-style:normal;
  font-size:12px;
  font-weight:900;
}
.pxth-filter-label{
  display:block;
  margin:12px 0 7px;
  color:#334155;
  font-size:13px;
  font-weight:900;
}
.pxth-price-range{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:8px;
}
.pxth-check-row{
  display:flex;
  align-items:center;
  gap:8px;
  min-height:30px;
  color:#334155;
  font-size:14px;
  font-weight:800;
  line-height:1.35;
  cursor:pointer;
}
.pxth-check-row input{
  width:16px;
  height:16px;
  flex:0 0 auto;
}
.pxth-attribute-filter{
  margin-top:12px;
  padding-top:12px;
  border-top:1px solid #e5e7eb;
}
.pxth-attribute-filter strong{
  display:block;
  margin:0 0 8px;
  color:#0f172a;
  font-size:14px;
  font-weight:900;
}
.pxth-filter-actions{
  display:flex;
  align-items:center;
  gap:8px;
  margin-top:14px;
}
.pxth-filter-actions button,
.pxth-filter-actions a{
  flex:1 1 auto;
  min-height:42px;
  border-radius:12px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  text-decoration:none;
  font-weight:900;
}
.pxth-filter-actions a{
  border:1px solid #cbd5e1;
  background:#fff;
  color:#334155;
}
.pxth-product-sidebar-latest{
  display:grid;
  gap:10px;
}
.pxth-product-sidebar-latest a{
  display:grid;
  grid-template-columns:54px minmax(0,1fr);
  gap:10px;
  align-items:center;
  color:#0f172a;
  text-decoration:none;
  font-weight:900;
}
.pxth-product-sidebar-latest span{
  width:54px;
  height:54px;
  border-radius:12px;
  background:#f1f5f9;
  overflow:hidden;
  display:block;
}
.pxth-product-sidebar-latest img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}
.pxth-product-sidebar-latest b{
  overflow:hidden;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  line-height:1.3;
}
.pxth-product-help-box p{
  margin:0 0 12px;
  color:#64748b;
  font-size:14px;
  font-weight:750;
  line-height:1.55;
}
.pxth-product-help-box div{
  display:flex;
  gap:8px;
}
.pxth-product-help-box a{
  flex:1 1 auto;
  min-height:40px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:12px;
  text-decoration:none;
  color:#fff;
  -webkit-text-fill-color:#fff;
  font-weight:900;
}
.pxth-product-help-box a.line{background:#06c755}
.pxth-product-help-box a.call{background:#0f172a}
.pxth-product-mobile-filter-toggle{
  display:none;
  width:100%;
  min-height:44px;
  margin:0 0 14px;
  border:0;
  border-radius:14px;
  background:#0f172a;
  color:#fff;
  -webkit-text-fill-color:#fff;
  font:900 14px/1 Kanit,system-ui,sans-serif;
  cursor:pointer;
}
@media(max-width:980px){
  .pxth-product-sidebar-layout{
    grid-template-columns:1fr;
  }
  .pxth-product-mobile-filter-toggle{
    display:flex;
    align-items:center;
    justify-content:center;
  }
  .pxth-product-sidebar{
    display:none;
  }
  .pxth-clean-product-block.show-product-sidebar .pxth-product-sidebar{
    display:grid;
  }
}


/* === assets/css/custom-section.css === */
/* ===== Clean Custom Section Builder ===== */
.custom-section{
  position:relative;
  overflow:visible;
  background-color:var(--sec-bg, transparent) !important;
}
.custom-section.has-bg-image{
  background-image:var(--section-bg-image) !important;
  background-size:var(--section-bg-size, cover) !important;
  background-position:var(--section-bg-position, center center) !important;
  background-repeat:no-repeat !important;
}
.custom-section .wrap{
  width:100%;
  max-width:var(--container,1180px);
  margin-left:auto;
  margin-right:auto;
  padding-left:var(--g,24px);
  padding-right:var(--g,24px);
}
.custom-grid{
  display:grid;
  gap:22px;
  align-items:stretch;
  overflow:visible;
}
.custom-cols-1{grid-template-columns:1fr}
.custom-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}
.custom-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}
.custom-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}
.custom-cols-5{grid-template-columns:repeat(5,minmax(0,1fr))}
.custom-cols-6{grid-template-columns:repeat(6,minmax(0,1fr))}
.custom-col{min-width:0;position:relative;overflow:visible}
.custom-block{position:relative;margin:0 0 18px;overflow:visible;isolation:isolate}
html[data-edit="1"] .custom-section::before{content:"";position:absolute;inset:0;border:1px solid rgba(156,163,175,.9);pointer-events:none;z-index:20}
html[data-edit="1"] .custom-block::before{content:"";position:absolute;inset:0;border:1px dashed rgba(107,114,128,.75);pointer-events:none;z-index:19}

.pxth-custom-controls{
  position:absolute;top:0;left:50%;transform:translate(-50%,-100%);
  z-index:99990;display:inline-flex;gap:0;height:28px;background:#9ca3af;border-radius:4px 4px 0 0;overflow:hidden;box-shadow:0 8px 18px rgba(0,0,0,.16)
}
.pxth-block-controls{
  position:absolute;top:0;left:50%;transform:translate(-50%,-100%);
  z-index:100000;display:inline-flex;gap:0;height:26px;background:#6b7280;border-radius:4px 4px 0 0;overflow:hidden;box-shadow:0 8px 18px rgba(0,0,0,.16)
}
.pxth-custom-controls button,.pxth-block-controls button{
  min-width:28px;height:100%;margin:0;padding:0 8px;border:0;border-left:1px solid rgba(255,255,255,.25);
  background:transparent;color:#fff;font-size:12px;font-weight:900;cursor:pointer
}
.pxth-custom-controls button:first-child,.pxth-block-controls button:first-child{border-left:0}
.pxth-custom-controls button:hover,.pxth-block-controls button:hover{background:rgba(255,255,255,.18)}
.pxth-custom-controls button:last-child,.pxth-block-controls button:last-child{background:#ef4444}

.pxth-add-section-float{
  position:fixed;right:22px;bottom:24px;z-index:999998;border:0;border-radius:999px;padding:12px 18px;background:#64748b;color:#fff;font-weight:900;box-shadow:0 10px 28px rgba(15,23,42,.22);cursor:pointer
}
.pxth-add-block{
  width:100%;min-height:42px;margin:16px 0 0;padding:10px 14px;border:1px dashed #cbd5e1;border-radius:8px;background:#f8fafc;color:#111827;font-size:13px;font-weight:900;cursor:pointer
}
.pxth-add-block:hover{background:#f1f5f9;border-color:#64748b}

.block-text,.block-contact,.block-banner,.block-image,.block-social,.block-map,.block-facebook,.block-product,.block-gallery,.block-videos,.block-news{
  background:transparent!important;border-radius:0!important;box-shadow:none!important;padding:0!important;min-width:0
}
.custom-block[data-block-type="banner"]{
  width:100vw;margin-left:calc(50% - 50vw);margin-right:calc(50% - 50vw);margin-bottom:0
}
.block-banner-image{
  position:relative;
  width:100%;
  aspect-ratio:1900/700;
  border-radius:0;
  margin:0;
  background:#ddd center/cover no-repeat;
  overflow:hidden;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  color:#888;
  font-size:42px;
  font-weight:500
}
.block-banner-image[style*="url("] .block-banner-placeholder{display:none}
.block-banner-image.has-real-img{
  display:block;
  background-image:none!important;
}
.block-banner-real{
  position:absolute;
  inset:0;
  display:block;
  width:100%;
  height:100%;
  object-fit:cover;
  border:0;
  max-width:none;
}
.block-image-box,.block-product-image,.block-news-image,.block-gallery-image{
  width:100%;aspect-ratio:16/9;border-radius:10px;margin-bottom:14px;background:#eee center/cover no-repeat;overflow:hidden;cursor:pointer
}
.block-image-caption:empty{display:none}
.block-image-caption{font-size:14px;color:#666;text-align:center}
.block-gallery-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.block-product-price{font-weight:900;margin:6px 0 8px}
.block-map iframe,.block-facebook iframe,.block-videos iframe{display:block;width:100%;border-radius:10px}
.block-map-empty,.block-video-empty{min-height:220px;display:flex;align-items:center;justify-content:center;background:#eee;border-radius:10px;color:#666}

.block-social{display:flex;gap:16px;flex-wrap:wrap;align-items:center}
.block-social--left{justify-content:flex-start}
.block-social--center{justify-content:center}
.block-social--right{justify-content:flex-end}
.block-social-btn{
  --social-bg:#64748b;display:inline-flex;align-items:center;gap:12px;min-height:58px;padding:8px 24px 8px 12px;border-radius:999px;background:var(--social-bg);color:#fff;text-decoration:none;box-shadow:0 8px 18px rgba(0,0,0,.18);line-height:1.15
}
.block-social-ico{width:42px;height:42px;min-width:42px;display:inline-flex;align-items:center;justify-content:center;border-radius:999px;background:rgba(0,0,0,.18);color:#fff;font-weight:900;font-size:20px}
.block-social-copy{display:flex;flex-direction:column}
.block-social-copy b{font-size:15px;font-weight:900;color:#fff}
.block-social-copy small{margin-top:3px;font-size:12px;font-weight:700;color:#fff;opacity:.95}
.block-social--icon .block-social-btn{width:52px;min-width:52px;height:52px;min-height:52px;padding:0;justify-content:center}
.block-social--icon .block-social-copy{display:none}
.block-social--icon .block-social-ico{width:52px;height:52px;min-width:52px;background:transparent;color:#fff}

.pxth-custom-modal{position:fixed;inset:0;background:rgba(15,23,42,.48);z-index:999999;display:none;padding:30px 16px;box-sizing:border-box}
.pxth-custom-modal.open{display:block}
.pxth-custom-panel{max-width:760px;margin:0 auto;background:#fff;color:#111;border-radius:14px;padding:22px;box-shadow:0 20px 70px rgba(0,0,0,.25);box-sizing:border-box}
.pxth-custom-panel h3{margin:0 0 16px;font-size:20px;line-height:1.3}
.pxth-custom-options{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}
.pxth-custom-options button{border:1px solid #d1d5db;border-radius:8px;background:#fff;color:#334155;padding:12px;font-weight:900;cursor:pointer}
.pxth-custom-options button:hover{background:#f1f5f9;border-color:#94a3b8}
.pxth-settings-group{margin:0 0 16px;padding:14px;border:1px solid #e5e7eb;border-radius:12px;background:#f8fafc}
.pxth-settings-title{font-weight:900;font-size:14px;margin:0 0 10px}
.pxth-settings-row{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.pxth-settings-row label{display:block;font-size:12px;font-weight:800;color:#334155}
.pxth-settings-row input,.pxth-settings-row select{width:100%;height:34px;margin-top:5px;box-sizing:border-box;border:1px solid #cbd5e1;border-radius:8px;padding:0 8px;font-size:13px;background:#fff}
.pxth-settings-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:16px}
.pxth-settings-actions button{border:0;border-radius:10px;padding:10px 14px;font-weight:900;cursor:pointer}
.pxth-settings-close{background:#e5e7eb;color:#111}
.pxth-settings-save{background:#64748b;color:#fff}
.pxth-color-line{display:grid;grid-template-columns:42px minmax(0,1fr);gap:8px;align-items:center;margin-top:5px}
.pxth-color-line input[type=color]{width:42px;height:34px;padding:0;border:1px solid #cbd5e1;border-radius:8px;background:#fff}

@media(max-width:900px){
  .custom-section .wrap{padding-left:var(--g,18px);padding-right:var(--g,18px)}
  .custom-cols-4,.custom-cols-5,.custom-cols-6{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:760px){
  .custom-grid{grid-template-columns:1fr!important}
  .pxth-custom-options{grid-template-columns:1fr 1fr}
  .pxth-settings-row{grid-template-columns:1fr}
  .block-social{flex-direction:column;align-items:stretch}
  .block-social-btn{width:100%;box-sizing:border-box;justify-content:flex-start}
  .block-social--icon .block-social-btn{width:100%;min-width:0;justify-content:center}
}


/* =========================================================
   CSS Load Fix / Strong Editor UI
   ========================================================= */
html[data-edit="1"] .custom-section{
  position:relative !important;
  min-height:90px !important;
  padding:38px 0 28px !important;
  margin:0 !important;
  border-top:1px solid #d1d5db !important;
  border-bottom:1px solid #e5e7eb !important;
  overflow:visible !important;
}

html[data-edit="1"] .custom-section .wrap{
  display:block !important;
  max-width:1180px !important;
  margin:0 auto !important;
  padding-left:24px !important;
  padding-right:24px !important;
  box-sizing:border-box !important;
}

html[data-edit="1"] .custom-grid{
  display:grid !important;
  gap:22px !important;
  min-height:70px !important;
}

html[data-edit="1"] .custom-col{
  min-height:70px !important;
  border:1px dashed #cbd5e1 !important;
  border-radius:8px !important;
  padding:14px !important;
  box-sizing:border-box !important;
  background:rgba(248,250,252,.55) !important;
}

html[data-edit="1"] .custom-col:empty{
  min-height:70px !important;
}

html[data-edit="1"] .pxth-custom-controls,
html[data-edit="1"] .pxth-block-controls{
  font-family:Arial,sans-serif !important;
}

html[data-edit="1"] .pxth-custom-controls{
  position:absolute !important;
  top:0 !important;
  left:50% !important;
  transform:translate(-50%,-50%) !important;
  z-index:999990 !important;
  display:inline-flex !important;
  gap:0 !important;
  height:30px !important;
  background:#9ca3af !important;
  border-radius:5px !important;
  overflow:hidden !important;
  box-shadow:0 8px 18px rgba(0,0,0,.18) !important;
}

html[data-edit="1"] .pxth-block-controls{
  position:absolute !important;
  top:0 !important;
  left:50% !important;
  transform:translate(-50%,-100%) !important;
  z-index:999999 !important;
  display:inline-flex !important;
  gap:0 !important;
  height:28px !important;
  background:#6b7280 !important;
  border-radius:5px 5px 0 0 !important;
  overflow:hidden !important;
  box-shadow:0 8px 18px rgba(0,0,0,.18) !important;
}

html[data-edit="1"] .pxth-custom-controls button,
html[data-edit="1"] .pxth-block-controls button{
  appearance:none !important;
  -webkit-appearance:none !important;
  min-width:30px !important;
  width:auto !important;
  height:100% !important;
  margin:0 !important;
  padding:0 9px !important;
  border:0 !important;
  border-left:1px solid rgba(255,255,255,.25) !important;
  border-radius:0 !important;
  background:transparent !important;
  color:var(--pxth-button-text,var(--global-button-text-color,#fff)) !important;
  font-size:13px !important;
  line-height:1 !important;
  font-weight:900 !important;
  cursor:pointer !important;
}

html[data-edit="1"] .pxth-custom-controls button:first-child,
html[data-edit="1"] .pxth-block-controls button:first-child{
  border-left:0 !important;
}

html[data-edit="1"] .pxth-custom-controls button:hover,
html[data-edit="1"] .pxth-block-controls button:hover{
  background:rgba(255,255,255,.18) !important;
}

html[data-edit="1"] .pxth-custom-controls button:last-child,
html[data-edit="1"] .pxth-block-controls button:last-child{
  background:#ef4444 !important;
}

html[data-edit="1"] .pxth-add-block{
  appearance:none !important;
  -webkit-appearance:none !important;
  display:flex !important;
  align-items:center !important;
  justify-content:center !important;
  width:100% !important;
  min-height:42px !important;
  margin:12px 0 0 !important;
  padding:10px 14px !important;
  border:1px dashed #cbd5e1 !important;
  border-radius:8px !important;
  background:#f8fafc !important;
  color:#111827 !important;
  font-size:13px !important;
  font-weight:900 !important;
  cursor:pointer !important;
  box-shadow:none !important;
}

html[data-edit="1"] .pxth-add-section-float{
  appearance:none !important;
  -webkit-appearance:none !important;
  position:fixed !important;
  right:22px !important;
  bottom:24px !important;
  z-index:999998 !important;
  border:0 !important;
  border-radius:999px !important;
  padding:12px 18px !important;
  background:#64748b !important;
  color:var(--pxth-button-text,var(--global-button-text-color,#fff)) !important;
  font-weight:900 !important;
  box-shadow:0 10px 28px rgba(15,23,42,.22) !important;
  cursor:pointer !important;
}

/* keep full width banner inside clean builder */
.custom-block[data-block-type="banner"]{
  width:100vw !important;
  margin-left:calc(50% - 50vw) !important;
  margin-right:calc(50% - 50vw) !important;
}



/* =========================================================
   Text Editor Heading Dropdown
   ========================================================= */
.pxth-rt-format-select,
.pxth-mini-format{
  height:34px !important;
  min-width:78px !important;
  border:1px solid #d1d5db !important;
  border-radius:8px !important;
  padding:0 9px !important;
  background:#fff !important;
  color:#111827 !important;
  font-size:13px !important;
  font-weight:900 !important;
  cursor:pointer !important;
}

.pxth-mini-text-modal{
  position:fixed !important;
  inset:0 !important;
  z-index:2147483600 !important;
  display:none !important;
  padding:52px 16px !important;
  background:rgba(15,23,42,.55) !important;
  box-sizing:border-box !important;
}

.pxth-mini-text-modal.open{display:block !important;}

.pxth-mini-text-panel{
  width:min(760px, calc(100vw - 32px)) !important;
  margin:0 auto !important;
  background:#fff !important;
  color:#111827 !important;
  border-radius:14px !important;
  overflow:hidden !important;
  box-shadow:0 24px 80px rgba(0,0,0,.35) !important;
}

.pxth-mini-text-head{
  display:flex !important;
  align-items:center !important;
  justify-content:space-between !important;
  padding:14px 16px !important;
  border-bottom:1px solid #e5e7eb !important;
  font-size:16px !important;
  font-weight:900 !important;
}

.pxth-mini-text-close{
  width:30px !important;
  height:30px !important;
  border:1px solid #d1d5db !important;
  border-radius:6px !important;
  background:#fff !important;
  color:#111 !important;
  font-weight:900 !important;
  cursor:pointer !important;
}

.pxth-mini-text-toolbar{
  display:flex !important;
  gap:7px !important;
  flex-wrap:wrap !important;
  align-items:center !important;
  padding:12px 14px !important;
  border-bottom:1px solid #e5e7eb !important;
  background:#f8fafc !important;
}

.pxth-mini-text-toolbar button{
  height:34px !important;
  border:1px solid #d1d5db !important;
  border-radius:8px !important;
  padding:0 10px !important;
  background:#fff !important;
  color:#111827 !important;
  font-size:13px !important;
  font-weight:900 !important;
  cursor:pointer !important;
}

.pxth-mini-text-toolbar input[type=color]{
  width:42px !important;
  height:34px !important;
  padding:2px !important;
  border:1px solid #d1d5db !important;
  border-radius:8px !important;
  background:#fff !important;
}

.pxth-mini-editor{
  min-height:260px !important;
  padding:16px !important;
  outline:0 !important;
  font-size:16px !important;
  line-height:1.65 !important;
  background:#fff !important;
}

.pxth-mini-text-actions{
  display:flex !important;
  justify-content:flex-end !important;
  gap:10px !important;
  padding:14px !important;
  border-top:1px solid #e5e7eb !important;
  background:#fff !important;
}

.pxth-mini-text-actions button{
  border:0 !important;
  border-radius:999px !important;
  padding:10px 18px !important;
  font-weight:900 !important;
  cursor:pointer !important;
}

.pxth-mini-cancel{background:#e5e7eb !important;color:#111 !important;}
.pxth-mini-save{background:#0b7be8 !important;color:var(--pxth-button-text,var(--global-button-text-color,#fff)) !important;}



/* =========================================================
   Multi Product Block + Grid/List/Carousel
   ========================================================= */
.block-products{
  --product-cols:3;
  width:100%;
}

.block-product-toolbar{
  display:flex;
  gap:8px;
  justify-content:flex-end;
  margin:0 0 14px;
  flex-wrap:wrap;
}

.block-product-toolbar button{
  border:1px solid #cbd5e1;
  border-radius:999px;
  background:#fff;
  color:#334155;
  padding:8px 12px;
  font-size:12px;
  font-weight:900;
  cursor:pointer;
}

.block-product-toolbar button.active,
.block-product-toolbar button:hover{
  background:#64748b;
  color:#fff;
  border-color:#64748b;
}

.block-product-items{
  display:grid;
  grid-template-columns:repeat(var(--product-cols), minmax(0, 1fr));
  gap:22px;
}

.block-product-card{
  position:relative;
  min-width:0;
  background:#fff;
  border:1px solid #e5e7eb;
  border-radius:14px;
  padding:14px;
  box-shadow:0 8px 22px rgba(15,23,42,.06);
}

.block-products.is-list .block-product-items{
  grid-template-columns:1fr;
}

.block-products.is-list .block-product-card{
  display:grid;
  grid-template-columns:240px minmax(0,1fr);
  column-gap:18px;
  align-items:start;
}

.block-products.is-list .block-product-image{
  grid-row:1 / span 3;
  margin-bottom:0;
  aspect-ratio:4/3;
}

.block-products.is-carousel .block-product-items{
  display:flex;
  gap:18px;
  overflow-x:auto;
  scroll-snap-type:x mandatory;
  padding-bottom:10px;
}

.block-products.is-carousel .block-product-card{
  flex:0 0 min(360px, 82vw);
  scroll-snap-align:start;
}

.block-product-add{
  width:100%;
  min-height:42px;
  margin:16px 0 0;
  border:1px dashed #cbd5e1;
  border-radius:10px;
  background:#f8fafc;
  color:#111827;
  font-size:12px;
  font-weight:900;
  cursor:pointer;
}

.block-product-add:hover{
  background:#f1f5f9;
  border-color:#64748b;
}

.block-product-remove{
  margin-top:12px;
  border:0;
  border-radius:999px;
  background:#fee2e2;
  color:#b91c1c;
  padding:7px 11px;
  font-size:12px;
  font-weight:900;
  cursor:pointer;
}

.pxth-product-cols-select{
  width:100%;
  height:36px;
  border:1px solid #cbd5e1;
  border-radius:8px;
  background:#fff;
  padding:0 10px;
  font-weight:800;
}

@media(max-width:900px){
  .block-product-items{
    grid-template-columns:repeat(2, minmax(0, 1fr));
  }
}

@media(max-width:760px){
  .block-product-items,
  .block-products.is-list .block-product-items{
    grid-template-columns:1fr;
  }

  .block-products.is-list .block-product-card{
    display:block;
  }

  .block-products.is-list .block-product-image{
    margin-bottom:14px;
  }

  .block-products.is-carousel .block-product-card{
    flex-basis:88vw;
  }

  .block-product-toolbar{
    justify-content:flex-start;
  }
}


/* =========================================================
   Product Carousel Arrows / No Scrollbar
   ========================================================= */
.block-product-carousel-nav{
  display:none;
  justify-content:flex-end;
  gap:8px;
  margin:0 0 12px;
}

.block-product-carousel-nav button{
  width:38px;
  height:38px;
  border:1px solid #cbd5e1;
  border-radius:999px;
  background:#fff;
  color:#334155;
  font-size:26px;
  line-height:1;
  font-weight:900;
  cursor:pointer;
  box-shadow:0 6px 16px rgba(15,23,42,.08);
}

.block-product-carousel-nav button:hover{
  background:#64748b;
  color:#fff;
  border-color:#64748b;
}

.block-products.is-carousel .block-product-carousel-nav{
  display:flex;
}

.block-products.is-carousel .block-product-items{
  display:flex !important;
  gap:18px !important;
  overflow-x:auto !important;
  overflow-y:hidden !important;
  scroll-snap-type:x mandatory !important;
  scroll-behavior:smooth !important;
  padding-bottom:0 !important;
  scrollbar-width:none !important;
  -ms-overflow-style:none !important;
}

.block-products.is-carousel .block-product-items::-webkit-scrollbar{
  display:none !important;
  width:0 !important;
  height:0 !important;
}

.block-products.is-carousel .block-product-card{
  flex:0 0 calc((100% - (18px * (var(--product-cols) - 1))) / var(--product-cols)) !important;
  max-width:calc((100% - (18px * (var(--product-cols) - 1))) / var(--product-cols)) !important;
  scroll-snap-align:start !important;
}

@media(max-width:900px){
  .block-products.is-carousel .block-product-card{
    flex-basis:calc((100% - 18px) / 2) !important;
    max-width:calc((100% - 18px) / 2) !important;
  }
}

@media(max-width:760px){
  .block-products.is-carousel .block-product-card{
    flex-basis:100% !important;
    max-width:100% !important;
  }

  .block-product-carousel-nav{
    justify-content:center;
  }
}


/* =========================================================
   Gallery Album Builder
   ========================================================= */
.block-gallery-albums{
  --gallery-radius:10px;
  --gallery-cols:3;
  --gallery-mobile-cols:1;
  width:100%;
}

.block-gallery-tabs{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  align-items:flex-start;
  margin:0 0 16px;
}

.block-gallery-tabs button{
  border:1px solid #cbd5e1;
  border-radius:999px;
  background:#fff;
  color:#334155;
  padding:9px 14px;
  font-size:12px;
  font-weight:900;
  cursor:pointer;
}

.block-gallery-tabs button.active,
.block-gallery-tabs button:hover{
  background:#0f172a;
  border-color:#0f172a;
  color:#fff;
}

.block-gallery-albums.tabs-left,
.block-gallery-albums.tabs-right{
  display:grid;
  gap:18px;
  align-items:start;
}

.block-gallery-albums.tabs-left{
  grid-template-columns:180px minmax(0,1fr);
}

.block-gallery-albums.tabs-right{
  grid-template-columns:minmax(0,1fr) 180px;
}

.block-gallery-albums.tabs-left .block-gallery-tabs,
.block-gallery-albums.tabs-right .block-gallery-tabs{
  flex-direction:column;
  margin:0;
}

.block-gallery-albums.tabs-left .block-gallery-tabs button,
.block-gallery-albums.tabs-right .block-gallery-tabs button{
  width:100%;
  text-align:center;
}

.block-gallery-albums.tabs-right .block-gallery-tabs{
  grid-column:2;
  grid-row:1;
}

.block-gallery-albums.tabs-right .block-gallery-main{
  grid-column:1;
  grid-row:1;
}

.block-gallery-panel{
  display:none;
}

.block-gallery-panel.active{
  display:block;
}

.block-gallery-grid{
  display:grid;
  grid-template-columns:repeat(var(--gallery-cols), minmax(0, 1fr));
  gap:14px;
}

.block-gallery-image-item{
  position:relative;
  overflow:hidden;
  border-radius:var(--gallery-radius);
  background:#eef2f7;
  aspect-ratio:1/1;
}

.block-gallery-image-item img{
  width:100%;
  height:100%;
  display:block;
  object-fit:cover;
}

.block-gallery-image-item [data-gallery-image-remove]{
  position:absolute;
  top:8px;
  right:8px;
  z-index:3;
  width:28px;
  height:28px;
  border:0;
  border-radius:999px;
  background:#ef4444;
  color:#fff;
  font-size:16px;
  font-weight:900;
  cursor:pointer;
}

.gallery-dropzone{
  min-height:180px;
  border:2px dashed #93c5fd;
  border-radius:var(--gallery-radius);
  background:#eff6ff;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:10px;
  text-align:center;
  color:#0f172a;
  cursor:pointer;
  padding:18px;
  box-sizing:border-box;
  aspect-ratio:1/1;
}

.gallery-dropzone.dragover{
  background:#dbeafe;
  border-color:#0b7be8;
  transform:scale(.995);
}

.gallery-drop-plus{
  width:48px;
  height:48px;
  border-radius:999px;
  background:#fff;
  color:#0b7be8;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:28px;
  font-weight:900;
  box-shadow:0 8px 22px rgba(15,23,42,.1);
}

.gallery-dropzone strong{
  font-size:15px;
  font-weight:900;
}

.gallery-dropzone span{
  font-size:14px;
  font-weight:800;
  color:#0b7be8;
}

.block-gallery-actions{
  display:flex;
  gap:8px;
  margin-top:14px;
  flex-wrap:wrap;
}

.block-gallery-actions button{
  border:1px solid #cbd5e1;
  border-radius:999px;
  background:#fff;
  color:#111827;
  padding:9px 14px;
  font-size:12px;
  font-weight:900;
  cursor:pointer;
}

.block-gallery-actions button:hover{
  background:#f1f5f9;
}

.block-gallery-actions [data-gallery-delete-album]{
  color:#b91c1c;
  background:#fee2e2;
  border-color:#fecaca;
}

@media(max-width:900px){
  .block-gallery-grid{
    grid-template-columns:repeat(min(var(--gallery-cols), 2), minmax(0, 1fr));
  }

  .block-gallery-albums.tabs-left,
  .block-gallery-albums.tabs-right{
    grid-template-columns:1fr;
  }

  .block-gallery-albums.tabs-right .block-gallery-tabs,
  .block-gallery-albums.tabs-right .block-gallery-main{
    grid-column:auto;
    grid-row:auto;
  }

  .block-gallery-albums.tabs-left .block-gallery-tabs,
  .block-gallery-albums.tabs-right .block-gallery-tabs{
    flex-direction:row;
  }

  .block-gallery-albums.tabs-left .block-gallery-tabs button,
  .block-gallery-albums.tabs-right .block-gallery-tabs button{
    width:auto;
  }
}

@media(max-width:760px){
  .block-gallery-grid{
    grid-template-columns:repeat(var(--gallery-mobile-cols), minmax(0, 1fr));
  }
}



/* =========================================================
   Gallery Album Names + WebP Upload UI
   ========================================================= */
.pxth-gallery-album-name-list{
  display:grid;
  grid-template-columns:repeat(2, minmax(0,1fr));
  gap:10px;
}

.pxth-gallery-album-name-list label{
  display:block;
  font-size:12px;
  font-weight:800;
  color:#334155;
}

.pxth-gallery-album-name-list input{
  display:block;
  width:100%;
  height:34px;
  margin-top:5px;
  box-sizing:border-box;
  border:1px solid #cbd5e1;
  border-radius:8px;
  padding:0 8px;
  background:#fff;
  color:#111827;
  font-size:12px;
}

.gallery-dropzone::after{
  content:"อัปโหลดแล้วแปลงเป็น WebP ไม่เกิน 800x600 และพยายามบีบให้ใกล้ 50KB";
  display:block;
  max-width:260px;
  font-size:12px;
  line-height:1.45;
  color:#64748b;
  font-weight:700;
}

@media(max-width:760px){
  .pxth-gallery-album-name-list{
    grid-template-columns:1fr;
  }
}


/* =========================================================
   Gallery Lightbox + Mobile Columns 1-4
   ========================================================= */
.block-gallery-image-item{
  cursor:zoom-in;
}

.pxth-gallery-lightbox{
  position:fixed;
  inset:0;
  z-index:2147483900;
  background:rgba(2,6,23,.88);
  display:flex;
  align-items:center;
  justify-content:center;
  padding:32px 72px;
  box-sizing:border-box;
}

.pxth-gallery-lightbox figure{
  margin:0;
  width:min(1100px, 100%);
  max-height:calc(100vh - 64px);
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
}

.pxth-gallery-lightbox img{
  display:block;
  max-width:100%;
  max-height:calc(100vh - 110px);
  object-fit:contain;
  border-radius:14px;
  box-shadow:0 24px 80px rgba(0,0,0,.4);
  background:#fff;
}

.pxth-gallery-lightbox figcaption{
  margin-top:10px;
  color:#fff;
  font-size:14px;
  font-weight:900;
}

.pxth-gallery-lightbox-close{
  position:absolute;
  top:18px;
  right:18px;
  width:42px;
  height:42px;
  border:0;
  border-radius:999px;
  background:#fff;
  color:#0f172a;
  font-size:26px;
  line-height:1;
  font-weight:900;
  cursor:pointer;
  box-shadow:0 12px 32px rgba(0,0,0,.25);
}

.pxth-gallery-lightbox-arrow{
  position:absolute;
  top:50%;
  transform:translateY(-50%);
  width:54px;
  height:54px;
  border:0;
  border-radius:999px;
  background:#fff;
  color:#0f172a;
  font-size:42px;
  line-height:1;
  font-weight:900;
  cursor:pointer;
  box-shadow:0 12px 32px rgba(0,0,0,.25);
}

.pxth-gallery-lightbox-arrow.prev{
  left:18px;
}

.pxth-gallery-lightbox-arrow.next{
  right:18px;
}

.pxth-gallery-lightbox-arrow:hover,
.pxth-gallery-lightbox-close:hover{
  background:#0b7be8;
  color:#fff;
}

@media(max-width:760px){
  .block-gallery-grid{
    grid-template-columns:repeat(var(--gallery-mobile-cols), minmax(0, 1fr)) !important;
  }

  .pxth-gallery-lightbox{
    padding:20px 48px;
  }

  .pxth-gallery-lightbox-arrow{
    width:40px;
    height:40px;
    font-size:32px;
  }

  .pxth-gallery-lightbox-arrow.prev{left:6px;}
  .pxth-gallery-lightbox-arrow.next{right:6px;}

  .pxth-gallery-lightbox-close{
    top:10px;
    right:10px;
    width:36px;
    height:36px;
    font-size:22px;
  }

  .pxth-gallery-lightbox img{
    max-height:calc(100vh - 92px);
    border-radius:10px;
  }
}


/* =========================================================
   Contact Info Inline Accordion Editor
   ========================================================= */
.block-contact-editor{
  width:100%;
}

.block-contact-head{
  margin:0 0 18px;
}

.block-contact-kicker{
  display:block;
  margin:0 0 6px;
  font-size:14px;
  font-weight:900;
  color:#64748b;
}

.block-contact-head h2{
  margin:0 0 10px;
  font-size:clamp(30px, 5vw, 54px);
  line-height:1.05;
  font-weight:1000;
  letter-spacing:-.04em;
}

.block-contact-company{
  font-size:16px;
  color:#64748b;
}

.contact-repeater{
  display:flex;
  flex-direction:column;
  gap:10px;
  max-width:520px;
}

.contact-item{
  border:1px solid #e5e7eb;
  border-radius:14px;
  background:#fff;
  overflow:hidden;
  box-shadow:0 8px 20px rgba(15,23,42,.05);
}

.contact-item-summary{
  appearance:none;
  width:100%;
  display:grid;
  grid-template-columns:42px minmax(0,1fr) 24px;
  gap:12px;
  align-items:center;
  border:0;
  background:#fff;
  color:#111827;
  text-align:left;
  padding:10px 12px;
  cursor:pointer;
  text-decoration:none;
}

.contact-item-summary:hover{
  background:#f8fafc;
}

.contact-icon{
  width:42px;
  height:42px;
  border-radius:999px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:color-mix(in srgb, var(--contact-color) 16%, #fff);
  color:var(--contact-color);
  font-size:20px;
  font-weight:900;
}

.contact-copy{
  display:flex;
  flex-direction:column;
  min-width:0;
}

.contact-copy b{
  display:block;
  font-size:15px;
  font-weight:1000;
  color:#111827;
}

.contact-copy small{
  display:block;
  margin-top:3px;
  font-size:12px;
  font-weight:700;
  color:#64748b;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.contact-chevron{
  color:#94a3b8;
  font-size:18px;
  font-weight:900;
  transition:transform .18s ease;
}

.contact-item.open .contact-chevron{
  transform:rotate(180deg);
}

.contact-item-panel{
  display:none;
  border-top:1px solid #e5e7eb;
  background:#f8fafc;
  padding:12px;
}

.contact-item.open .contact-item-panel{
  display:block;
}

.contact-form-grid{
  display:grid;
  grid-template-columns:80px 1fr;
  gap:10px;
}

.contact-form-grid label{
  display:block;
  font-size:12px;
  font-weight:900;
  color:#334155;
}

.contact-form-grid input[type="text"],
.contact-form-grid input:not([type]){
  display:block;
  width:100%;
  height:34px;
  margin-top:5px;
  box-sizing:border-box;
  border:1px solid #cbd5e1;
  border-radius:8px;
  padding:0 8px;
  background:#fff;
  color:#111827;
  font-size:12px;
}

.contact-form-grid label:nth-child(3),
.contact-form-grid label:nth-child(4),
.contact-form-grid label:nth-child(5){
  grid-column:1 / -1;
}

.contact-color-line{
  display:grid;
  grid-template-columns:42px minmax(0,1fr);
  gap:8px;
  align-items:center;
  margin-top:5px;
}

.contact-color-line input[type="color"]{
  width:42px;
  height:34px;
  padding:0;
  border:1px solid #cbd5e1;
  border-radius:8px;
  background:#fff;
}

.contact-color-line input[readonly]{
  color:#64748b;
  background:#f1f5f9;
}

.contact-item-actions{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  margin-top:12px;
}

.contact-item-actions button,
.contact-add-item{
  border:1px solid #cbd5e1;
  border-radius:999px;
  background:#fff;
  color:#111827;
  padding:8px 12px;
  font-size:12px;
  font-weight:900;
  cursor:pointer;
}

.contact-item-actions button:hover,
.contact-add-item:hover{
  background:#f1f5f9;
}

.contact-item-actions [data-contact-remove]{
  background:#fee2e2;
  border-color:#fecaca;
  color:#b91c1c;
}

.contact-add-item{
  margin-top:12px;
  background:#f8fafc;
}

@media(max-width:760px){
  .contact-repeater{
    max-width:none;
  }

  .contact-form-grid{
    grid-template-columns:1fr;
  }

  .contact-form-grid label{
    grid-column:auto !important;
  }
}


/* =========================================================
   Contact Info Compact Icon + Inline Text
   ========================================================= */
.contact-item-summary{
  grid-template-columns:32px minmax(0,1fr) 18px !important;
  gap:10px !important;
  padding:9px 12px !important;
}

.contact-icon{
  width:32px !important;
  height:32px !important;
  min-width:32px !important;
  font-size:15px !important;
}

.contact-copy{
  display:flex !important;
  flex-direction:row !important;
  align-items:center !important;
  gap:8px !important;
  min-width:0 !important;
}

.contact-copy b{
  font-size:15px !important;
  line-height:1.2 !important;
  white-space:nowrap !important;
}

.contact-copy small{
  margin-top:0 !important;
  font-size:13px !important;
  line-height:1.2 !important;
  white-space:nowrap !important;
  overflow:hidden !important;
  text-overflow:ellipsis !important;
}

/* หน้าเว็บจริงที่ไม่ได้อยู่โหมด edit ไม่ต้องแสดงลูกศร */
html:not([data-edit="1"]) .contact-chevron{
  display:none !important;
}

html:not([data-edit="1"]) .contact-item-summary{
  grid-template-columns:32px minmax(0,1fr) !important;
}

.contact-form-grid input[list]{
  padding-right:6px !important;
}

@media(max-width:520px){
  .contact-copy{
    flex-direction:column !important;
    align-items:flex-start !important;
    gap:2px !important;
  }

  .contact-copy b,
  .contact-copy small{
    max-width:100% !important;
  }
}


/* =========================================================
   Contact Design Mode + Optional Link
   ========================================================= */
.contact-design-simple .contact-repeater{
  gap:4px !important;
}

.contact-design-simple .contact-item{
  border:0 !important;
  border-radius:0 !important;
  background:transparent !important;
  box-shadow:none !important;
  overflow:visible !important;
}

.contact-design-simple .contact-item-summary{
  background:transparent !important;
  padding:5px 0 !important;
  border-radius:0 !important;
}

.contact-design-simple .contact-item-summary:hover{
  background:transparent !important;
}

.contact-design-simple .contact-icon{
  background:transparent !important;
  width:24px !important;
  height:24px !important;
  min-width:24px !important;
  font-size:14px !important;
}

.contact-design-simple .contact-item-panel{
  border-top:0 !important;
  background:#f8fafc !important;
  border-radius:12px !important;
  margin:6px 0 8px 34px !important;
  border:1px solid #e5e7eb !important;
}

.contact-link-enable{
  display:flex !important;
  align-items:center !important;
  gap:8px !important;
  margin-top:19px !important;
}

.contact-link-enable span{
  font-size:12px !important;
  font-weight:900 !important;
  color:#334155 !important;
}

.contact-link-enable input[type="checkbox"]{
  width:18px !important;
  height:18px !important;
}

.contact-form-grid input:disabled{
  background:#e5e7eb !important;
  color:#94a3b8 !important;
  cursor:not-allowed !important;
}

.contact-no-link{
  cursor:default !important;
}

html:not([data-edit="1"]) .contact-no-link:hover{
  background:#fff !important;
}

html:not([data-edit="1"]) .contact-design-simple .contact-no-link:hover{
  background:transparent !important;
}



/* =========================================================
   Facebook Page URL Fix
   ========================================================= */
.block-facebook{
  position:relative;
  min-height:220px;
}

.block-facebook iframe{
  width:100% !important;
  max-width:100% !important;
  display:block !important;
  border-radius:10px !important;
  background:#fff !important;
}

.block-facebook [data-edit-custom-facebook]{
  margin-top:12px;
  border:1px solid #cbd5e1;
  border-radius:999px;
  background:#fff;
  color:#111827;
  padding:9px 14px;
  font-size:12px;
  font-weight:900;
  cursor:pointer;
}

.block-facebook [data-edit-custom-facebook]:hover{
  background:#f1f5f9;
}



/* =========================================================
   Facebook Page Settings UI
   ========================================================= */
.pxth-fb-settings-panel{
  max-width:520px !important;
}

.pxth-fb-url-input{
  width:100%;
  height:38px;
  box-sizing:border-box;
  border:1px solid #cbd5e1;
  border-radius:8px;
  padding:0 10px;
  font-size:12px;
  font-weight:700;
  background:#fff;
  color:#111827;
}

.pxth-fb-setting-row{
  display:grid;
  grid-template-columns:minmax(0,1fr) 54px;
  gap:12px;
  align-items:center;
  padding:9px 0;
  font-size:12px;
  font-weight:800;
  color:#475569;
}

.pxth-fb-setting-row input{
  display:none;
}

.pxth-fb-setting-row i{
  position:relative;
  width:54px;
  height:28px;
  border-radius:999px;
  background:#e5e7eb;
  cursor:pointer;
  transition:.18s;
}

.pxth-fb-setting-row i::before{
  content:"NO";
  position:absolute;
  left:22px;
  top:50%;
  transform:translateY(-50%);
  font-size:8px;
  font-weight:900;
  color:#94a3b8;
}

.pxth-fb-setting-row i::after{
  content:"";
  position:absolute;
  top:3px;
  left:3px;
  width:22px;
  height:22px;
  border-radius:999px;
  background:#fff;
  box-shadow:0 2px 8px rgba(0,0,0,.18);
  transition:.18s;
}

.pxth-fb-setting-row input:checked + i{
  background:#67c7e8;
}

.pxth-fb-setting-row input:checked + i::before{
  content:"YES";
  left:8px;
  color:#fff;
}

.pxth-fb-setting-row input:checked + i::after{
  left:29px;
}

.pxth-fb-height-row{
  display:grid;
  grid-template-columns:minmax(0,1fr) 78px;
  gap:14px;
  align-items:center;
}

.pxth-fb-height-row input[type="range"]{
  width:100%;
}

.pxth-fb-height-row input[type="number"]{
  width:78px;
  height:36px;
  border:1px solid #cbd5e1;
  border-radius:8px;
  padding:0 9px;
  box-sizing:border-box;
  font-weight:800;
}


/* =========================================================
   Multi Video Block Grid/List/Carousel
   ========================================================= */
.block-videos{
  width:100%;
}

.block-video-items{
  display:grid;
  gap:22px;
}

.block-videos.is-grid .block-video-items{
  grid-template-columns:repeat(2, minmax(0,1fr));
}

.block-videos.is-list .block-video-items{
  grid-template-columns:1fr;
}

.block-video-item{
  position:relative;
  min-width:0;
}

.block-video-frame{
  width:100%;
  aspect-ratio:16/9;
  background:#eee;
  border-radius:14px;
  overflow:hidden;
  display:flex;
  align-items:center;
  justify-content:center;
}

.block-video-frame iframe,
.block-video-frame video{
  width:100%;
  height:100%;
  display:block;
  border:0;
}

.block-video-empty{
  color:#64748b;
  font-weight:900;
}

.block-video-meta{
  display:grid;
  grid-template-columns:1fr;
  gap:8px;
  margin-top:10px;
}

.block-video-meta input{
  width:100%;
  height:36px;
  border:1px solid #cbd5e1;
  border-radius:8px;
  padding:0 10px;
  box-sizing:border-box;
  font-weight:800;
}

.block-video-actions{
  display:flex;
  gap:8px;
  margin-top:10px;
  flex-wrap:wrap;
}

.block-video-actions button,
.block-video-add{
  border:1px solid #cbd5e1;
  border-radius:999px;
  background:#fff;
  color:#111827;
  padding:8px 12px;
  font-size:12px;
  font-weight:900;
  cursor:pointer;
}

.block-video-actions [data-video-remove]{
  background:#fee2e2;
  border-color:#fecaca;
  color:#b91c1c;
}

.block-video-add{
  display:inline-flex;
  margin-top:14px;
  background:#f8fafc;
}

.block-video-dots{
  display:flex;
  gap:10px;
  justify-content:center;
  align-items:center;
  margin-top:16px;
}

.block-video-dots button{
  width:34px;
  height:34px;
  border:1px solid #cbd5e1;
  border-radius:999px;
  background:#fff;
  color:#0f172a;
  font-size:12px;
  font-weight:900;
  cursor:pointer;
}

.block-video-dots button.active{
  background:#0f172a;
  color:#fff;
  border-color:#0f172a;
}

.block-videos.is-carousel{
  overflow:hidden;
}

.block-videos.is-carousel .block-video-items{
  position:relative;
  display:flex;
  align-items:center;
  justify-content:center;
  min-height:430px;
  gap:0;
}

.block-videos.is-carousel .block-video-item{
  position:absolute;
  left:50%;
  width:min(760px, 72%);
  opacity:0;
  transform:translateX(-50%) scale(.72);
  transition:transform .28s ease, opacity .28s ease, filter .28s ease;
  pointer-events:none;
  z-index:1;
  filter:grayscale(.08);
}

.block-videos.is-carousel .block-video-item.active{
  opacity:1;
  transform:translateX(-50%) scale(1);
  pointer-events:auto;
  z-index:3;
  filter:none;
}

.block-videos.is-carousel .block-video-item.prev{
  opacity:.55;
  transform:translateX(-118%) scale(.68);
  z-index:2;
  pointer-events:auto;
  cursor:pointer;
}

.block-videos.is-carousel .block-video-item.next{
  opacity:.55;
  transform:translateX(18%) scale(.68);
  z-index:2;
  pointer-events:auto;
  cursor:pointer;
}

.block-videos.is-carousel .block-video-item:not(.active) .block-video-meta,
.block-videos.is-carousel .block-video-item:not(.active) .block-video-actions{
  display:none;
}

.block-video-title{
  margin-top:10px;
  font-weight:900;
  color:#111827;
}

@media(max-width:900px){
  .block-videos.is-grid .block-video-items{
    grid-template-columns:1fr;
  }

  .block-videos.is-carousel .block-video-items{
    min-height:340px;
  }

  .block-videos.is-carousel .block-video-item{
    width:80%;
  }

  .block-videos.is-carousel .block-video-item.prev{
    transform:translateX(-112%) scale(.62);
  }

  .block-videos.is-carousel .block-video-item.next{
    transform:translateX(12%) scale(.62);
  }
}

@media(max-width:760px){
  .block-videos.is-carousel .block-video-items{
    min-height:auto;
    display:block;
  }

  .block-videos.is-carousel .block-video-item{
    position:relative;
    left:auto;
    width:100%;
    opacity:0;
    transform:none;
    display:none;
  }

  .block-videos.is-carousel .block-video-item.active{
    display:block;
    opacity:1;
    transform:none;
  }

  .block-videos.is-carousel .block-video-item.prev,
  .block-videos.is-carousel .block-video-item.next{
    display:none;
  }
}


/* =========================================================
   Video Carousel Clip Fix
   แก้ iframe ขอบบนโดนตัดใน carousel
   ========================================================= */
.block-videos.is-carousel{
  overflow:visible !important;
  padding-top:30px !important;
  padding-bottom:10px !important;
}

.block-videos.is-carousel .block-video-items{
  overflow:visible !important;
  min-height:540px !important;
  padding-top:0 !important;
  padding-bottom:0 !important;
}

.block-videos.is-carousel .block-video-item{
  top:50% !important;
  transform-origin:center center !important;
}

.block-videos.is-carousel .block-video-item{
  transform:translate(-50%, -50%) scale(.72) !important;
}

.block-videos.is-carousel .block-video-item.active{
  transform:translate(-50%, -50%) scale(1) !important;
}

.block-videos.is-carousel .block-video-item.prev{
  transform:translate(-118%, -50%) scale(.68) !important;
}

.block-videos.is-carousel .block-video-item.next{
  transform:translate(18%, -50%) scale(.68) !important;
}

.block-videos.is-carousel .block-video-frame{
  overflow:hidden !important;
  border-radius:14px !important;
  box-shadow:0 14px 38px rgba(15,23,42,.16) !important;
}

.block-videos.is-carousel .block-video-dots{
  position:relative !important;
  z-index:5 !important;
  margin-top:8px !important;
}

@media(max-width:900px){
  .block-videos.is-carousel .block-video-items{
    min-height:430px !important;
  }

  .block-videos.is-carousel .block-video-item.prev{
    transform:translate(-112%, -50%) scale(.62) !important;
  }

  .block-videos.is-carousel .block-video-item.next{
    transform:translate(12%, -50%) scale(.62) !important;
  }
}

@media(max-width:760px){
  .block-videos.is-carousel{
    padding-top:0 !important;
    padding-bottom:0 !important;
    overflow:visible !important;
  }

  .block-videos.is-carousel .block-video-items{
    min-height:auto !important;
    overflow:visible !important;
  }

  .block-videos.is-carousel .block-video-item,
  .block-videos.is-carousel .block-video-item.active{
    top:auto !important;
    transform:none !important;
  }
}


/* =========================================================
   Video Grid 1-6 Columns + List Left/Right Layout
   ========================================================= */
.block-videos{
  --video-cols:3;
}

.block-videos.is-grid .block-video-items{
  grid-template-columns:repeat(var(--video-cols), minmax(0,1fr)) !important;
}

.block-videos.is-list .block-video-items{
  grid-template-columns:1fr !important;
  gap:18px !important;
}

.block-videos.is-list .block-video-item{
  display:grid !important;
  grid-template-columns:minmax(240px, 42%) minmax(0,1fr) !important;
  column-gap:18px !important;
  align-items:start !important;
  padding:14px !important;
  border:1px solid #e5e7eb !important;
  border-radius:14px !important;
  background:#fff !important;
  box-shadow:0 8px 22px rgba(15,23,42,.06) !important;
}

.block-videos.is-list .block-video-frame{
  grid-column:1 !important;
  grid-row:1 / span 3 !important;
  margin:0 !important;
}

.block-videos.is-list .block-video-title,
.block-videos.is-list .block-video-meta,
.block-videos.is-list .block-video-actions{
  grid-column:2 !important;
}

.block-videos.is-list .block-video-title{
  margin:0 0 8px !important;
  font-size:20px !important;
  line-height:1.25 !important;
  font-weight:1000 !important;
}

.block-videos.is-list .block-video-meta{
  margin-top:0 !important;
}

.block-videos.is-list .block-video-actions{
  margin-top:12px !important;
}

@media(max-width:1100px){
  .block-videos.is-grid .block-video-items{
    grid-template-columns:repeat(min(var(--video-cols), 3), minmax(0,1fr)) !important;
  }
}

@media(max-width:900px){
  .block-videos.is-grid .block-video-items{
    grid-template-columns:repeat(min(var(--video-cols), 2), minmax(0,1fr)) !important;
  }

  .block-videos.is-list .block-video-item{
    grid-template-columns:220px minmax(0,1fr) !important;
  }
}

@media(max-width:760px){
  .block-videos.is-grid .block-video-items{
    grid-template-columns:1fr !important;
  }

  .block-videos.is-list .block-video-item{
    display:block !important;
  }

  .block-videos.is-list .block-video-frame{
    margin-bottom:12px !important;
  }
}


/* =========================================================
   Video Dots Carousel Only
   ========================================================= */
.block-videos:not(.is-carousel) .block-video-dots{
  display:none !important;
}

.block-videos.is-carousel .block-video-dots{
  display:flex !important;
}


/* =========================================================
   Multi News Block Grid/List/Carousel + Popup
   ========================================================= */
.block-news-list{
  --news-cols:3;
  width:100%;
}

.block-news-items{
  display:grid;
  gap:22px;
}

.block-news-list.is-grid .block-news-items{
  grid-template-columns:repeat(var(--news-cols), minmax(0,1fr));
}

.block-news-card{
  position:relative;
  min-width:0;
  border:1px solid #e5e7eb;
  border-radius:14px;
  overflow:hidden;
  background:#fff;
  box-shadow:none;
  cursor:pointer;
}

.block-news-card:hover{
  box-shadow:none;
}

.block-news-card .block-news-image{
  width:100%;
  aspect-ratio:16/9;
  border-radius:0;
  margin:0;
  background:#eee center/cover no-repeat;
}

.block-news-body{
  padding:14px;
}

.block-news-body h3{
  margin:0 0 8px;
  font-size:20px;
  line-height:1.25;
  font-weight:1000;
}

.block-news-desc{
  display:-webkit-box;
  -webkit-line-clamp:3;
  -webkit-box-orient:vertical;
  overflow:hidden;
  font-size:14px;
  line-height:1.55;
  color:#475569;
}

.block-news-item-actions{
  padding:0 14px 14px;
}

.block-news-item-actions button,
.block-news-add{
  border:1px solid #cbd5e1;
  border-radius:999px;
  background:#fff;
  color:#111827;
  padding:8px 12px;
  font-size:12px;
  font-weight:900;
  cursor:pointer;
}

.block-news-item-actions [data-news-remove]{
  background:#fee2e2;
  border-color:#fecaca;
  color:#b91c1c;
}

.block-news-add{
  display:inline-flex;
  margin-top:14px;
  background:#f8fafc;
}

.block-news-dots{
  display:none;
  gap:10px;
  justify-content:center;
  align-items:center;
  margin-top:16px;
}

.block-news-list.is-carousel .block-news-dots{
  display:flex;
}

.block-news-dots button{
  width:34px;
  height:34px;
  border:1px solid #cbd5e1;
  border-radius:999px;
  background:#fff;
  color:#0f172a;
  font-size:12px;
  font-weight:900;
  cursor:pointer;
}

.block-news-dots button.active{
  background:#0f172a;
  color:#fff;
  border-color:#0f172a;
}

/* News List: image left, text right */
.block-news-list.is-list .block-news-items{
  grid-template-columns:1fr;
}

.block-news-list.is-list .block-news-card{
  display:grid;
  grid-template-columns:260px minmax(0,1fr);
  align-items:stretch;
}

.block-news-list.is-list .block-news-card .block-news-image{
  height:100%;
  min-height:180px;
  aspect-ratio:auto;
  grid-column:1;
  grid-row:1 / span 2;
}

.block-news-list.is-list .block-news-body{
  grid-column:2;
}

.block-news-list.is-list .block-news-item-actions{
  grid-column:2;
}

/* News carousel: center large, side cards smaller */
.block-news-list.is-carousel{
  overflow:visible;
}

.block-news-list.is-carousel .block-news-items{
  position:relative;
  display:flex;
  align-items:center;
  justify-content:center;
  min-height:430px;
  overflow:visible;
}

.block-news-list.is-carousel .block-news-card{
  position:absolute;
  left:50%;
  width:min(620px, 70%);
  opacity:0;
  transform:translate(-50%, 0) scale(.72);
  transition:transform .28s ease, opacity .28s ease, filter .28s ease;
  pointer-events:none;
  z-index:1;
  filter:grayscale(.08);
}

.block-news-list.is-carousel .block-news-card.active{
  opacity:1;
  transform:translate(-50%, 0) scale(1);
  pointer-events:auto;
  z-index:3;
  filter:none;
}

.block-news-list.is-carousel .block-news-card.prev{
  opacity:.55;
  transform:translate(-118%, 0) scale(.68);
  z-index:2;
  pointer-events:auto;
}

.block-news-list.is-carousel .block-news-card.next{
  opacity:.55;
  transform:translate(18%, 0) scale(.68);
  z-index:2;
  pointer-events:auto;
}

/* News popup removed: News cards navigate to article detail pages. */
@media(max-width:1100px){
  .block-news-list.is-grid .block-news-items{
    grid-template-columns:repeat(min(var(--news-cols), 3), minmax(0,1fr));
  }
}

@media(max-width:900px){
  .block-news-list.is-grid .block-news-items{
    grid-template-columns:repeat(min(var(--news-cols), 2), minmax(0,1fr));
  }

  .block-news-list.is-list .block-news-card{
    grid-template-columns:220px minmax(0,1fr);
  }

  .block-news-list.is-carousel .block-news-items{
    min-height:380px;
  }

  .block-news-list.is-carousel .block-news-card{
    width:78%;
  }

  .block-news-list.is-carousel .block-news-card.prev{
    transform:translate(-112%, 0) scale(.62);
  }

  .block-news-list.is-carousel .block-news-card.next{
    transform:translate(12%, 0) scale(.62);
  }
}

@media(max-width:760px){
  .block-news-list.is-grid .block-news-items{
    grid-template-columns:1fr;
  }

  .block-news-list.is-list .block-news-card{
    display:block;
  }

  .block-news-list.is-list .block-news-card .block-news-image{
    height:auto;
    min-height:0;
    aspect-ratio:16/9;
  }

  .block-news-list.is-carousel .block-news-items{
    min-height:auto;
    display:block;
  }

  .block-news-list.is-carousel .block-news-card{
    position:relative;
    left:auto;
    width:100%;
    opacity:0;
    transform:none;
    display:none;
  }

  .block-news-list.is-carousel .block-news-card.active{
    display:block;
    opacity:1;
    transform:none;
  }

  .block-news-list.is-carousel .block-news-card.prev,
  .block-news-list.is-carousel .block-news-card.next{
    display:none;
  }
}


/* =========================================================
   News Carousel Product Style / No Bullets
   ========================================================= */
.block-news-dots{
  display:none !important;
}

.block-news-carousel-nav{
  display:none;
  justify-content:flex-end;
  gap:8px;
  margin:0 0 12px;
}

.block-news-list.is-carousel .block-news-carousel-nav{
  display:flex;
}

.block-news-carousel-nav button{
  width:38px;
  height:38px;
  border:1px solid #cbd5e1;
  border-radius:999px;
  background:#fff;
  color:#334155;
  font-size:26px;
  line-height:1;
  font-weight:900;
  cursor:pointer;
  box-shadow:0 6px 16px rgba(15,23,42,.08);
}

.block-news-carousel-nav button:hover{
  background:#64748b;
  color:#fff;
  border-color:#64748b;
}

/* Override old video-style news carousel */
.block-news-list.is-carousel{
  overflow:visible !important;
}

.block-news-list.is-carousel .block-news-items{
  position:static !important;
  display:flex !important;
  align-items:stretch !important;
  justify-content:flex-start !important;
  gap:18px !important;
  min-height:0 !important;
  overflow-x:auto !important;
  overflow-y:hidden !important;
  scroll-snap-type:x mandatory !important;
  scroll-behavior:smooth !important;
  scrollbar-width:none !important;
  -ms-overflow-style:none !important;
  padding-bottom:0 !important;
}

.block-news-list.is-carousel .block-news-items::-webkit-scrollbar{
  display:none !important;
  width:0 !important;
  height:0 !important;
}

.block-news-list.is-carousel .block-news-card{
  position:relative !important;
  left:auto !important;
  width:auto !important;
  flex:0 0 calc((100% - (18px * (var(--news-cols) - 1))) / var(--news-cols)) !important;
  max-width:calc((100% - (18px * (var(--news-cols) - 1))) / var(--news-cols)) !important;
  opacity:1 !important;
  transform:none !important;
  transition:box-shadow .18s ease, transform .18s ease !important;
  pointer-events:auto !important;
  z-index:auto !important;
  filter:none !important;
  scroll-snap-align:start !important;
}

.block-news-list.is-carousel .block-news-card:hover{
  transform:translateY(-2px) !important;
}

@media(max-width:900px){
  .block-news-list.is-carousel .block-news-card{
    flex-basis:calc((100% - 18px) / 2) !important;
    max-width:calc((100% - 18px) / 2) !important;
  }
}

@media(max-width:760px){
  .block-news-list.is-carousel .block-news-card{
    display:block !important;
    flex-basis:88vw !important;
    max-width:88vw !important;
    opacity:1 !important;
    transform:none !important;
  }

  .block-news-carousel-nav{
    justify-content:center;
  }
}


/* =========================================================
   Map Settings Full Width / Height / Zoom
   ========================================================= */
.block-map{
  --map-height:420px;
  width:100%;
}

.block-map iframe{
  width:100% !important;
  height:var(--map-height) !important;
  min-height:220px !important;
  display:block !important;
  border:0 !important;
  border-radius:10px !important;
}

.block-map.map-full-width{
  width:100vw !important;
  margin-left:calc(50% - 50vw) !important;
  margin-right:calc(50% - 50vw) !important;
}

.block-map.map-full-width iframe,
.block-map.map-full-width .block-map-empty{
  border-radius:0 !important;
}

.block-map-empty{
  height:var(--map-height) !important;
}

.block-map [data-edit-custom-map]{
  margin-top:12px;
  border:1px solid #cbd5e1;
  border-radius:999px;
  background:#fff;
  color:#111827;
  padding:9px 14px;
  font-size:12px;
  font-weight:900;
  cursor:pointer;
}

.pxth-map-settings-panel{
  max-width:680px !important;
}

.pxth-map-html-input{
  width:100%;
  min-height:120px;
  box-sizing:border-box;
  border:1px solid #cbd5e1;
  border-radius:10px;
  padding:10px;
  background:#fff;
  color:#111827;
  font-size:12px;
  line-height:1.5;
  font-family:ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.pxth-map-switch-row{
  display:grid;
  grid-template-columns:minmax(0,1fr) 54px;
  gap:12px;
  align-items:center;
  font-size:12px;
  font-weight:900;
  color:#334155;
}

.pxth-map-switch-row input{
  display:none;
}

.pxth-map-switch-row i{
  position:relative;
  width:54px;
  height:28px;
  border-radius:999px;
  background:#e5e7eb;
  cursor:pointer;
  transition:.18s;
}

.pxth-map-switch-row i::after{
  content:"";
  position:absolute;
  top:3px;
  left:3px;
  width:22px;
  height:22px;
  border-radius:999px;
  background:#fff;
  box-shadow:0 2px 8px rgba(0,0,0,.18);
  transition:.18s;
}

.pxth-map-switch-row input:checked + i{
  background:#67c7e8;
}

.pxth-map-switch-row input:checked + i::after{
  left:29px;
}

.pxth-map-range-row{
  display:grid;
  grid-template-columns:minmax(0,1fr) 86px;
  gap:14px;
  align-items:center;
}

.pxth-map-range-row input[type="range"]{
  width:100%;
}

.pxth-map-range-row input[type="number"]{
  width:86px;
  height:36px;
  border:1px solid #cbd5e1;
  border-radius:8px;
  padding:0 9px;
  box-sizing:border-box;
  font-weight:800;
}

.pxth-map-note{
  display:block;
  margin-top:8px;
  color:#64748b;
  font-size:12px;
  line-height:1.45;
}


/* =========================================================
   Quick Load Buttons: Map / Fanpage / Video
   ========================================================= */
.pxth-load-actions{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  margin-top:12px;
  align-items:center;
}

.pxth-load-actions .btn,
.pxth-load-actions button{
  border:1px solid #cbd5e1 !important;
  border-radius:999px !important;
  background:#fff !important;
  color:#111827 !important;
  padding:9px 14px !important;
  font-size:13px !important;
  font-weight:900 !important;
  cursor:pointer !important;
  line-height:1 !important;
  box-shadow:none !important;
}

.pxth-load-actions [data-load-map],
.pxth-load-actions [data-load-facebook],
.pxth-load-actions [data-load-video]{
  background:#0b7be8 !important;
  border-color:#0b7be8 !important;
  color:var(--pxth-button-text,var(--global-button-text-color,#fff)) !important;
}

.pxth-load-actions button:hover{
  filter:brightness(.96);
}


/* =========================================================
   Lazy Load iframe placeholders for PageSpeed
   ========================================================= */
.pxth-lazy-box{
  min-height:220px;
  width:100%;
  border:1px solid #e5e7eb;
  border-radius:14px;
  background:#f1f5f9;
  display:flex;
  align-items:center;
  justify-content:center;
  box-shadow:0 18px 50px rgba(15,23,42,.06);
  box-sizing:border-box;
}

.pxth-lazy-map,
.pxth-lazy-facebook{
  min-height:var(--map-height, 420px);
}

.pxth-lazy-facebook{
  min-height:420px;
}

.pxth-lazy-video{
  min-height:100%;
  aspect-ratio:16/9;
  border-radius:14px;
}

.pxth-lazy-load-btn{
  border:0;
  border-radius:999px;
  background:#111;
  color:#fff;
  padding:12px 18px;
  font-size:12px;
  font-weight:900;
  cursor:pointer;
  box-shadow:0 14px 28px rgba(0,0,0,.18);
}

.pxth-lazy-load-btn:hover{
  background:#0b7be8;
}

.map-full-width .pxth-lazy-box{
  border-radius:0;
}

.block-video-frame .pxth-lazy-box{
  height:100%;
  min-height:100%;
  border:0;
  box-shadow:none;
}


/* =========================================================
   Hide Lazy Load Buttons in Backend/Edit Mode
   ========================================================= */
html[data-edit="1"] [data-lazy-load],
html[data-edit="1"] [data-load-map],
html[data-edit="1"] [data-load-facebook],
html[data-edit="1"] [data-load-video]{
  display:none !important;
}

/* หน้าเว็บจริงยังให้ปุ่ม lazy load แสดงได้ตามปกติ */
html:not([data-edit="1"]) .pxth-lazy-load-btn{
  display:inline-flex !important;
  align-items:center;
  justify-content:center;
}


/* =========================================================
   Safe Section Settings
   ========================================================= */
/* default เดิมต้องยังอยู่: .custom-block margin 0 0 18px */
.custom-section.no-block-margin .custom-block{
  margin-bottom:0 !important;
}

.pxth-section-settings-panel{
  max-width:760px !important;
}

.pxth-section-settings-group{
  border:1px solid #e5e7eb;
  border-radius:12px;
  padding:14px;
  margin:0 0 14px;
  background:#f8fafc;
}

.pxth-section-settings-title{
  font-size:14px;
  font-weight:1000;
  color:#111827;
  margin:0 0 10px;
}

.pxth-section-settings-row4{
  display:grid;
  grid-template-columns:repeat(4, minmax(0,1fr));
  gap:10px;
}

.pxth-section-settings-row2{
  display:grid;
  grid-template-columns:repeat(2, minmax(0,1fr));
  gap:10px;
}

.pxth-section-settings-row4 label,
.pxth-section-settings-row2 label{
  display:block;
  font-size:12px;
  font-weight:900;
  color:#334155;
}

.pxth-section-settings-row4 input,
.pxth-section-settings-row2 input,
.pxth-section-settings-row2 select{
  width:100%;
  height:34px;
  margin-top:5px;
  box-sizing:border-box;
  border:1px solid #cbd5e1;
  border-radius:8px;
  padding:0 8px;
  background:#fff;
  color:#111827;
  font-size:12px;
  font-weight:800;
}

.pxth-section-settings-row2 input[type="color"]{
  padding:2px;
}

.pxth-section-same,
.pxth-section-toggle{
  display:flex;
  align-items:center;
  gap:8px;
  margin-top:10px;
  font-size:12px;
  font-weight:800;
  color:#334155;
}

.pxth-section-toggle input,
.pxth-section-same input{
  width:17px;
  height:17px;
}

.pxth-section-settings-group small{
  display:block;
  margin-top:8px;
  color:#64748b;
  font-size:12px;
  line-height:1.45;
}

@media(max-width:760px){
  .pxth-section-settings-row4,
  .pxth-section-settings-row2{
    grid-template-columns:1fr 1fr;
  }
}


/* =========================================================
   Section BG Color Fix
   ========================================================= */
.custom-section[data-sec-bg]:not([data-sec-bg=""]){
  background-color:var(--sec-bg) !important;
}

.custom-section[data-sec-color]:not([data-sec-color=""]){
  color:inherit;
}

.custom-section[data-sec-bg]:not([data-sec-bg=""]) .wrap{
  position:relative;
  z-index:1;
}


/* =========================================================
   Section Font Color Deep Fix
   ========================================================= */
.custom-section[data-sec-color]:not([data-sec-color=""]){
  color:var(--sec-color) !important;
}

.custom-section[data-sec-color]:not([data-sec-color=""]) :where(
  h1,h2,h3,h4,h5,h6,
  p,span,strong,b,em,i,small,
  li,dt,dd,
  .block-contact-kicker,
  .block-contact-company,
  .block-news-body h3,
  .block-news-desc,
  .block-product-price,
  .block-video-title,
  [data-custom-html]
){
  color:var(--sec-color) !important;
}

/* link ให้ตามสี section ด้วย แต่ยังคง underline/interaction เดิม */
.custom-section[data-sec-color]:not([data-sec-color=""]) a:not(.btn):not(.button){
  color:var(--sec-color) !important;
}

/* ปุ่มที่เป็นปุ่มจริงไม่บังคับสีทั้งหมด เพื่อไม่ทำให้ปุ่มหายจากแบรนด์ */
.custom-section[data-sec-color]:not([data-sec-color=""]) .btn:not(.pxth-lazy-load-btn),
.custom-section[data-sec-color]:not([data-sec-color=""]) button:not(.pxth-lazy-load-btn):not([data-section-act]):not([data-block-act]){
  color:inherit;
}


/* =========================================================
   Section Settings Compact UI + BG Upload
   ========================================================= */
.pxth-section-settings-panel{
  max-width:820px !important;
}

.pxth-spacing-line{
  display:grid;
  grid-template-columns:72px minmax(0, 1fr) 92px;
  gap:10px;
  align-items:end;
  margin-top:10px;
}

.pxth-spacing-label{
  height:34px;
  display:flex;
  align-items:center;
  font-size:12px;
  font-weight:1000;
  color:#111827;
}

.pxth-section-settings-row4.compact{
  display:grid;
  grid-template-columns:repeat(4, 78px);
  gap:8px;
  justify-content:start;
}

.pxth-section-settings-row4.compact input{
  width:78px !important;
  min-width:0 !important;
}

.pxth-section-settings-row3{
  display:grid;
  grid-template-columns:180px 180px 140px;
  gap:12px;
  align-items:end;
}

.pxth-section-settings-row3 label{
  display:block;
  font-size:12px;
  font-weight:900;
  color:#334155;
}

.pxth-section-settings-row3 input{
  width:100%;
  height:34px;
  margin-top:5px;
  box-sizing:border-box;
  border:1px solid #cbd5e1;
  border-radius:8px;
  padding:0 8px;
  background:#fff;
  color:#111827;
  font-size:12px;
  font-weight:800;
}

.pxth-section-settings-row3 input[type="color"]{
  padding:2px;
}

.pxth-bg-image-line label{
  display:block;
  font-size:12px;
  font-weight:900;
  color:#334155;
}

.pxth-bg-image-picker{
  display:grid;
  grid-template-columns:minmax(0, 1fr) 90px 70px;
  gap:8px;
  margin-top:5px;
  align-items:center;
}

.pxth-bg-image-picker input{
  width:100%;
  height:36px;
  box-sizing:border-box;
  border:1px solid #cbd5e1;
  border-radius:8px;
  padding:0 10px;
  background:#fff;
  color:#111827;
  font-size:12px;
  font-weight:800;
}

.pxth-bg-image-picker button{
  height:36px;
  border:1px solid #cbd5e1;
  border-radius:999px;
  background:#fff;
  color:#111827;
  font-size:12px;
  font-weight:900;
  cursor:pointer;
}

.pxth-bg-image-picker [data-pick-section-bg]{
  background:#0b7be8;
  border-color:#0b7be8;
  color:#fff;
}

.pxth-bg-image-picker [data-clear-section-bg]{
  background:#fee2e2;
  border-color:#fecaca;
  color:#b91c1c;
}

.pxth-section-settings-row2.bg-options{
  grid-template-columns:160px 220px;
  justify-content:start;
  margin-top:10px;
}

.pxth-section-same.inline{
  margin-top:0 !important;
  height:34px;
  align-items:center;
  white-space:nowrap;
}

@media(max-width:860px){
  .pxth-spacing-line{
    grid-template-columns:1fr;
    align-items:start;
  }

  .pxth-section-settings-row4.compact{
    grid-template-columns:repeat(4, minmax(0,1fr));
  }

  .pxth-section-settings-row4.compact input{
    width:100% !important;
  }

  .pxth-section-settings-row3{
    grid-template-columns:1fr;
  }

  .pxth-bg-image-picker{
    grid-template-columns:1fr;
  }

  .pxth-section-settings-row2.bg-options{
    grid-template-columns:1fr;
  }
}



/* =========================================================
   Section BG Upload Click Fix
   ========================================================= */
.pxth-bg-image-picker button{
  pointer-events:auto !important;
  position:relative;
  z-index:2;
}



/* =========================================================
   Gallery Delete Album Save Fix
   ========================================================= */
[data-gallery-album][hidden]{
  display:none !important;
}



/* =========================================================
   Gallery Delete Image / Unique Album Fix
   ========================================================= */
[data-gallery-image-remove],
[data-gallery-remove-image],
[data-delete-gallery-image],
.gallery-image-remove,
.block-gallery-image-remove,
.gallery-img-remove,
[data-gallery-delete-album],
[data-gallery-remove-album],
[data-delete-album]{
  pointer-events:auto !important;
  cursor:pointer !important;
  z-index:20 !important;
}


/* =========================================================
   Gallery Hard Delete Fix
   ========================================================= */
.block-gallery-image-item{
  position:relative !important;
}

.block-gallery-image-item [data-gallery-image-remove]{
  position:absolute !important;
  top:8px !important;
  right:8px !important;
  z-index:50 !important;
  pointer-events:auto !important;
  cursor:pointer !important;
}


/* =========================================================
   Gallery Save Replace Real Fix
   ========================================================= */
.block-gallery-image-item[data-gallery-image]{
  position:relative !important;
}

.block-gallery-image-item[data-gallery-image] [data-gallery-image-remove],
.block-gallery-image-item[data-gallery-image] .pxth-gallery-delete-image{
  position:absolute !important;
  top:8px !important;
  right:8px !important;
  z-index:9999 !important;
  width:30px !important;
  height:30px !important;
  border:0 !important;
  border-radius:999px !important;
  background:#ef4444 !important;
  color:var(--pxth-button-text,var(--global-button-text-color,#fff)) !important;
  display:flex !important;
  align-items:center !important;
  justify-content:center !important;
  line-height:1 !important;
  font-size:18px !important;
  font-weight:900 !important;
  cursor:pointer !important;
  pointer-events:auto !important;
  box-shadow:0 6px 16px rgba(0,0,0,.18) !important;
}


/* =========================================================
   Image Block Natural Ratio Fix
   ========================================================= */
.custom-block[data-block-type="image"] .block-image-box{
  width:100% !important;
  aspect-ratio:auto !important;
  height:auto !important;
  min-height:0 !important;
  margin-bottom:14px;
  border-radius:10px;
  background:#eee !important;
  background-image:none !important;
  background-size:auto !important;
  background-position:center !important;
  background-repeat:no-repeat !important;
  overflow:hidden;
  cursor:pointer;
  display:block;
}

.custom-block[data-block-type="image"] .block-image-box .block-image-real{
  display:block !important;
  width:100% !important;
  height:auto !important;
  max-width:100% !important;
  object-fit:contain !important;
  border-radius:inherit;
}

.custom-block[data-block-type="image"] .block-image-box .block-image-placeholder{
  display:flex;
  align-items:center;
  justify-content:center;
  width:100%;
  min-height:220px;
  color:#8a8a8a;
  font-size:48px;
  font-weight:500;
  background:#cfcfcf;
}

.custom-block[data-block-type="image"] .block-image-box[data-src=""]{
  min-height:220px !important;
}


/* =========================================================
   Product Image Natural Ratio Fix
   ========================================================= */
.custom-block[data-block-type="product"] .block-product-image,
.custom-block[data-block-type="product"] .product-image-box,
.custom-block[data-block-type="product"] [data-product-image]{
  width:100% !important;
  aspect-ratio:auto !important;
  height:auto !important;
  min-height:0 !important;
  border-radius:10px;
  background:#eee !important;
  background-image:none !important;
  background-size:auto !important;
  background-position:center !important;
  background-repeat:no-repeat !important;
  overflow:hidden;
  cursor:pointer;
  display:block;
}

.custom-block[data-block-type="product"] .block-product-image .product-image-real,
.custom-block[data-block-type="product"] .product-image-box .product-image-real,
.custom-block[data-block-type="product"] [data-product-image] .product-image-real{
  display:block !important;
  width:100% !important;
  height:auto !important;
  max-width:100% !important;
  object-fit:contain !important;
  border-radius:inherit;
}

.custom-block[data-block-type="product"] .block-product-image .product-image-placeholder,
.custom-block[data-block-type="product"] .product-image-box .product-image-placeholder,
.custom-block[data-block-type="product"] [data-product-image] .product-image-placeholder{
  display:flex;
  align-items:center;
  justify-content:center;
  width:100%;
  min-height:130px;
  color:#8a8a8a;
  font-size:34px;
  font-weight:500;
  background:#cfcfcf;
}

.custom-block[data-block-type="product"] .block-product-image[data-src=""],
.custom-block[data-block-type="product"] .product-image-box[data-src=""],
.custom-block[data-block-type="product"] [data-product-image][data-src=""]{
  min-height:130px !important;
}

/* กัน CSS เดิมที่บังคับ img เป็น cover */
.custom-block[data-block-type="product"] .block-product-image img,
.custom-block[data-block-type="product"] .product-image-box img{
  object-fit:contain !important;
  height:auto !important;
}



/* =========================================================
   Remove Old Section Toolbar Buttons
   ========================================================= */
#sectionManagerBtn,
#undoBtn,
#resetPageBtn,
[data-old-section-manager],
[data-action="section-manager"],
[data-action="undo"],
[data-action="reset-page"],
button[title="จัดการ Section"],
button[title="ย้อนกลับ (Undo)"],
button[title="รีเซ็ตหน้านี้"]{
  display:none !important;
}



/* =========================================================
   News Popup Frontend Only Safe
   ========================================================= */
.pxth-editor .block-news-card,
.pxth-editor .news-card,
body.is-editor .block-news-card,
body.is-editor .news-card{
  cursor:default !important;
}

.pxth-editor .block-news-card [data-edit-custom-image],
.pxth-editor .block-news-card [data-custom-html],
.pxth-editor .block-news-card button,
body.is-editor .block-news-card [data-edit-custom-image],
body.is-editor .block-news-card [data-custom-html],
body.is-editor .block-news-card button{
  cursor:pointer !important;
}


/* PXTH FIX: real banner block uses background-image, not img.
   Mobile must crop/show as 1200x700 frame, not 1900x700 full ratio. */
@media (max-width:768px){
  html,
  body{
    max-width:100% !important;
    overflow-x:hidden !important;
  }

  section[data-section="custom"],
  .custom-section,
  .custom-row,
  .custom-col{
    max-width:100% !important;
    overflow:visible !important;
  }

  .custom-block[data-block-type="banner"]{
    width:100vw !important;
    max-width:100vw !important;
    min-width:100vw !important;
    margin-left:50% !important;
    margin-right:0 !important;
    transform:translateX(-50%) !important;
    overflow:hidden !important;
    box-sizing:border-box !important;
    margin-bottom:0 !important;
  }

  .custom-block[data-block-type="banner"] .block-banner,
  .custom-block[data-block-type="banner"] .block-banner-image{
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    height:auto !important;
    aspect-ratio:1200 / 700 !important;
    min-height:0 !important;
    max-height:none !important;
    overflow:hidden !important;
    box-sizing:border-box !important;
  }

  .custom-block[data-block-type="banner"] .block-banner-image{
    background-size:cover !important;
    background-position:center center !important;
    background-repeat:no-repeat !important;
  }

  .custom-block[data-block-type="banner"] .block-banner-placeholder{
    width:100% !important;
    height:100% !important;
    min-height:calc(100vw * 700 / 1200) !important;
    display:flex !important;
    align-items:center !important;
    justify-content:center !important;
  }
}







/* PXTH ORGANIZED GLOBAL COLORS
   ระบบสีรวมแบบเป็นระเบียบ:
   - สีไตเติ้ล = หัวข้อหลักของ section/block
   - สีปุ่ม = ปุ่มหน้าเว็บจริงเท่านั้น
   - สีตัวอักษรปุ่ม = auto contrast จาก JS/PHP ไม่ให้กลืนกับพื้นปุ่ม
   - ไม่แตะ toolbar/topbar/header/menu/editor/system buttons */
:root{
  --pxth-title-color: var(--global-title-color, var(--theme-title, inherit));
  --pxth-button-bg: var(--global-button-color, var(--theme-button-bg, #0f172a));
  --pxth-button-text: var(--global-button-text-color, #ffffff);
}

/* ===== Title color: เฉพาะหัวข้อหลัก ไม่ใช่ชื่อสินค้า ===== */
section[data-section] h2,
.custom-section h2,
[data-custom-section] h2,
[data-custom-html] h2,
.block-text h2,
.custom-block[data-block-type="contact-info"] [data-field="title"],
.custom-block[data-block-type="contact-info"] .block-contact-head h2,
.custom-block[data-block-type="videos"] h2,
.custom-block[data-block-type="videos"] .block-title,
.custom-block[data-block-type="videos"] .section-title,
.custom-block[data-block-type="news"] h2,
.custom-block[data-block-type="news"] .block-title,
.custom-block[data-block-type="news"] .section-title,
.custom-block[data-block-type="gallery"] h2,
.custom-block[data-block-type="gallery"] .block-title,
.custom-block[data-block-type="gallery"] .section-title,
.custom-block[data-block-type="map"] h2,
.custom-block[data-block-type="facebook-page"] h2{
  color:var(--pxth-title-color) !important;
}

/* ชื่อสินค้า/หัวข้อย่อยสินค้า ไม่ตามสีไตเติ้ลรวม */
.custom-block[data-block-type="product"] h3,
.custom-block[data-block-type="product"] [data-field="title"],
.block-product-card h3,
.block-product-card [data-field="title"]{
  color:inherit !important;
}

/* ===== Button color: เฉพาะปุ่มหน้าเว็บจริงที่ควรเป็น branding ===== */
body:not([data-edit="1"]) .map-placeholder-btn,
body:not([data-edit="1"]) .load-map-btn,
body:not([data-edit="1"]) .load-fanpage-btn,
body:not([data-edit="1"]) .load-video-btn,
body:not([data-edit="1"]) .gallery-load-btn,
body:not([data-edit="1"]) [data-lazy-load],
body:not([data-edit="1"]) .block-gallery button[data-load-gallery],
body:not([data-edit="1"]) .block-videos [data-lazy-load],
body:not([data-edit="1"]) .block-map [data-lazy-load],
body:not([data-edit="1"]) .block-facebook [data-lazy-load],
html[data-edit="1"] .custom-block[data-block-type="gallery"] .gallery-load-btn,
html[data-edit="1"] .custom-block[data-block-type="gallery"] button[data-load-gallery],
html[data-edit="1"] .custom-block[data-block-type="videos"] .load-video-btn,
html[data-edit="1"] .custom-block[data-block-type="videos"] [data-lazy-load],
html[data-edit="1"] .custom-block[data-block-type="map"] .map-placeholder-btn,
html[data-edit="1"] .custom-block[data-block-type="map"] .load-map-btn,
html[data-edit="1"] .custom-block[data-block-type="map"] [data-lazy-load],
html[data-edit="1"] .custom-block[data-block-type="facebook-page"] .load-fanpage-btn,
html[data-edit="1"] .custom-block[data-block-type="facebook-page"] [data-lazy-load]{
  background:var(--pxth-button-bg) !important;
  background-color:var(--pxth-button-bg) !important;
  border-color:var(--pxth-button-bg) !important;
  color:var(--pxth-button-text) !important;
}

body:not([data-edit="1"]) .map-placeholder-btn *,
body:not([data-edit="1"]) .load-map-btn *,
body:not([data-edit="1"]) .load-fanpage-btn *,
body:not([data-edit="1"]) .load-video-btn *,
body:not([data-edit="1"]) .gallery-load-btn *,
body:not([data-edit="1"]) [data-lazy-load] *,
html[data-edit="1"] .custom-block[data-block-type="gallery"] .gallery-load-btn *,
html[data-edit="1"] .custom-block[data-block-type="videos"] .load-video-btn *,
html[data-edit="1"] .custom-block[data-block-type="map"] .load-map-btn *,
html[data-edit="1"] .custom-block[data-block-type="facebook-page"] .load-fanpage-btn *{
  color:var(--pxth-button-text) !important;
}

/* hover เฉพาะปุ่มหน้าเว็บจริง */
body:not([data-edit="1"]) .map-placeholder-btn:hover,
body:not([data-edit="1"]) .load-map-btn:hover,
body:not([data-edit="1"]) .load-fanpage-btn:hover,
body:not([data-edit="1"]) .load-video-btn:hover,
body:not([data-edit="1"]) .gallery-load-btn:hover,
body:not([data-edit="1"]) [data-lazy-load]:hover{
  filter:brightness(.94);
}

/* ===== Explicit exclusions: ปุ่มระบบ/editor/header/topbar ต้องไม่ตามสีปุ่มรวม ===== */
html[data-edit="1"] #pxth-toolbar button,
html[data-edit="1"] #pxth-toolbar a,
html[data-edit="1"] #pxth-toolbar select,
html[data-edit="1"] .topbar a,
html[data-edit="1"] .topbar button,
html[data-edit="1"] header a,
html[data-edit="1"] header button,
html[data-edit="1"] nav a,
html[data-edit="1"] nav button,
html[data-edit="1"] .pxth-custom-controls button,
html[data-edit="1"] .pxth-block-controls button,
html[data-edit="1"] [data-section-act],
html[data-edit="1"] [data-block-act],
html[data-edit="1"] .pxth-add-block,
html[data-edit="1"] .pxth-add-section-float,
html[data-edit="1"] .block-product-toolbar button,
html[data-edit="1"] .block-product-carousel-nav button,
html[data-edit="1"] .block-product-add,
html[data-edit="1"] .block-product-remove,
html[data-edit="1"] .block-gallery-tabs button,
html[data-edit="1"] .block-gallery-actions button,
html[data-edit="1"] [data-gallery-image-remove],
html[data-edit="1"] .block-video-add,
html[data-edit="1"] .block-video-dots button,
html[data-edit="1"] [data-video-slide],
html[data-edit="1"] .block-news-add,
html[data-edit="1"] [data-news-slide],
html[data-edit="1"] [data-edit-custom-map],
html[data-edit="1"] [data-edit-custom-facebook]{
  filter:none !important;
}

/* restore common editor control colors */
html[data-edit="1"] .pxth-custom-controls button,
html[data-edit="1"] .pxth-block-controls button{
  background:#6b7280 !important;
  color:var(--pxth-button-text,var(--global-button-text-color,#fff)) !important;
  border-color:rgba(255,255,255,.18) !important;
}
html[data-edit="1"] .pxth-custom-controls button:last-child,
html[data-edit="1"] .pxth-block-controls button:last-child,
html[data-edit="1"] [data-section-act="delete"],
html[data-edit="1"] [data-block-act="delete"]{
  background:#ef4444 !important;
  color:var(--pxth-button-text,var(--global-button-text-color,#fff)) !important;
  border-color:#ef4444 !important;
}
html[data-edit="1"] .pxth-add-block{
  background:#f8fafc !important;
  color:#111827 !important;
  border-color:#cbd5e1 !important;
}
html[data-edit="1"] .block-product-toolbar button,
html[data-edit="1"] .block-product-carousel-nav button,
html[data-edit="1"] .block-product-add,
html[data-edit="1"] .block-product-remove,
html[data-edit="1"] .block-gallery-tabs button,
html[data-edit="1"] .block-gallery-actions button,
html[data-edit="1"] [data-gallery-image-remove],
html[data-edit="1"] .block-video-add,
html[data-edit="1"] .block-video-dots button,
html[data-edit="1"] [data-video-slide],
html[data-edit="1"] .block-news-add,
html[data-edit="1"] [data-news-slide],
html[data-edit="1"] [data-edit-custom-map],
html[data-edit="1"] [data-edit-custom-facebook]{
  background:#fff !important;
  color:#0f172a !important;
  border-color:#cbd5e1 !important;
}
html[data-edit="1"] .block-gallery-tabs button.active,
html[data-edit="1"] .block-video-dots button.active{
  background:#0f172a !important;
  color:var(--pxth-button-text,var(--global-button-text-color,#fff)) !important;
  border-color:#0f172a !important;
}


/* PXTH GALLERY BUTTON GLOBAL COLOR FIX
   ปุ่มแกลลอรี่เป็นปุ่มหน้าเว็บจริง ต้องตามสีปุ่มรวม ไม่ใช่ปุ่มระบบ */
:root{
  --pxth-button-bg: var(--global-button-color, var(--theme-button-bg, #0f172a));
  --pxth-button-text: var(--global-button-text-color, #ffffff);
}

/* Gallery tabs / album buttons */
body .custom-block[data-block-type="gallery"] .block-gallery-tabs button,
body .custom-block[data-block-type="gallery"] .block-gallery-tabs button.active,
body .block-gallery-tabs button,
body .block-gallery-tabs button.active,
body .block-gallery-albums .block-gallery-tabs button,
body .block-gallery-albums .block-gallery-tabs button.active{
  background:var(--pxth-button-bg) !important;
  background-color:var(--pxth-button-bg) !important;
  border-color:var(--pxth-button-bg) !important;
  color:var(--pxth-button-text) !important;
  filter:none !important;
}

body .custom-block[data-block-type="gallery"] .block-gallery-tabs button *,
body .block-gallery-tabs button *{
  color:var(--pxth-button-text) !important;
}

/* Gallery load buttons also follow global button color */
body .custom-block[data-block-type="gallery"] .gallery-load-btn,
body .custom-block[data-block-type="gallery"] button[data-load-gallery],
body .block-gallery .gallery-load-btn,
body .block-gallery button[data-load-gallery]{
  background:var(--pxth-button-bg) !important;
  background-color:var(--pxth-button-bg) !important;
  border-color:var(--pxth-button-bg) !important;
  color:var(--pxth-button-text) !important;
}

body .custom-block[data-block-type="gallery"] .gallery-load-btn *,
body .custom-block[data-block-type="gallery"] button[data-load-gallery] *{
  color:var(--pxth-button-text) !important;
}

/* ปุ่มระบบของ gallery ที่ไม่ใช่หน้าเว็บจริง ยังไม่ตามสีรวม */
html[data-edit="1"] .custom-block[data-block-type="gallery"] .block-gallery-actions button,
html[data-edit="1"] .custom-block[data-block-type="gallery"] [data-gallery-delete-album],
html[data-edit="1"] .custom-block[data-block-type="gallery"] [data-gallery-image-remove],
html[data-edit="1"] .custom-block[data-block-type="gallery"] .gallery-dropzone{
  background:#fff !important;
  color:#0f172a !important;
  border-color:#cbd5e1 !important;
}


/* PXTH GALLERY ALBUM TEXT CONTRAST FIX
   แก้คำว่า "อัลบั้ม" บนปุ่มแกลลอรี่ที่ยังเป็นสีดำ */
:root{
  --pxth-button-bg: var(--global-button-color, var(--theme-button-bg, #0f172a));
  --pxth-button-text: var(--global-button-text-color, var(--pxth-button-text, #ffffff));
}

body .custom-block[data-block-type="gallery"] .block-gallery-tabs button,
body .custom-block[data-block-type="gallery"] .block-gallery-tabs button.active,
body .block-gallery-tabs button,
body .block-gallery-tabs button.active,
body .block-gallery-albums .block-gallery-tabs button,
body .block-gallery-albums .block-gallery-tabs button.active{
  background:var(--pxth-button-bg) !important;
  background-color:var(--pxth-button-bg) !important;
  border-color:var(--pxth-button-bg) !important;
  color:var(--pxth-button-text) !important;
  -webkit-text-fill-color:var(--pxth-button-text) !important;
  text-shadow:none !important;
}

/* บังคับลูกข้างในทั้งหมด เพราะบางทีคำว่าอัลบั้มอยู่ใน span/strong */
body .custom-block[data-block-type="gallery"] .block-gallery-tabs button *,
body .block-gallery-tabs button *,
body .block-gallery-albums .block-gallery-tabs button *{
  color:var(--pxth-button-text) !important;
  -webkit-text-fill-color:var(--pxth-button-text) !important;
  text-shadow:none !important;
}

/* active/focus/hover ก็ต้องไม่กลับไปดำ */
body .custom-block[data-block-type="gallery"] .block-gallery-tabs button:hover,
body .custom-block[data-block-type="gallery"] .block-gallery-tabs button:focus,
body .custom-block[data-block-type="gallery"] .block-gallery-tabs button.active:hover,
body .block-gallery-tabs button:hover,
body .block-gallery-tabs button:focus,
body .block-gallery-tabs button.active:hover{
  color:var(--pxth-button-text) !important;
  -webkit-text-fill-color:var(--pxth-button-text) !important;
}


/* PXTH VIDEO DOTS ACTIVE GLOBAL COLOR FIX
   ปุ่มเลข 1 2 3 4 ของวิดีโอ: ตัวที่เลือกต้องตามสีปุ่มรวม */
:root{
  --pxth-button-bg: var(--global-button-color, var(--theme-button-bg, #0f172a));
  --pxth-button-text: var(--global-button-text-color, var(--pxth-button-text, #ffffff));
}

/* video carousel dots / number buttons */
body .custom-block[data-block-type="videos"] .block-video-dots button.active,
body .custom-block[data-block-type="videos"] .block-video-dots button.is-active,
body .custom-block[data-block-type="videos"] .block-video-dots button[aria-selected="true"],
body .custom-block[data-block-type="videos"] .block-video-dots button.current,
body .custom-block[data-block-type="videos"] [data-video-dot].active,
body .custom-block[data-block-type="videos"] [data-video-dot].is-active,
body .block-videos .block-video-dots button.active,
body .block-videos .block-video-dots button.is-active,
body .block-videos .block-video-dots button[aria-selected="true"],
body .block-videos [data-video-dot].active,
body .block-videos [data-video-dot].is-active{
  background:var(--pxth-button-bg) !important;
  background-color:var(--pxth-button-bg) !important;
  border-color:var(--pxth-button-bg) !important;
  color:var(--pxth-button-text) !important;
  -webkit-text-fill-color:var(--pxth-button-text) !important;
  box-shadow:none !important;
  filter:none !important;
}

body .custom-block[data-block-type="videos"] .block-video-dots button.active *,
body .custom-block[data-block-type="videos"] .block-video-dots button.is-active *,
body .custom-block[data-block-type="videos"] .block-video-dots button[aria-selected="true"] *,
body .custom-block[data-block-type="videos"] [data-video-dot].active *,
body .block-videos .block-video-dots button.active *,
body .block-videos .block-video-dots button.is-active *,
body .block-videos [data-video-dot].active *{
  color:var(--pxth-button-text) !important;
  -webkit-text-fill-color:var(--pxth-button-text) !important;
}

/* video dots ที่ยังไม่เลือก ให้เป็นสีปกติ ไม่ตามสีปุ่ม */
body .custom-block[data-block-type="videos"] .block-video-dots button:not(.active):not(.is-active):not([aria-selected="true"]),
body .custom-block[data-block-type="videos"] [data-video-dot]:not(.active):not(.is-active):not([aria-selected="true"]),
body .block-videos .block-video-dots button:not(.active):not(.is-active):not([aria-selected="true"]){
  background:#fff !important;
  background-color:var(--pxth-button-text,var(--global-button-text-color,#fff)) !important;
  border-color:#cbd5e1 !important;
  color:#0f172a !important;
  -webkit-text-fill-color:#0f172a !important;
  filter:none !important;
}


/* PXTH GLOBAL TITLE H1 H2 ONLY
   สีไตเติ้ลรวมทั้งเว็บ บังคับเฉพาะ h1 และ h2 เท่านั้น */
:root{
  --pxth-title-color: var(--global-title-color, var(--theme-title, var(--pxth-global-title-color, inherit)));
}

body h1,
body h2,
section[data-section] h1,
section[data-section] h2,
.custom-section h1,
.custom-section h2,
[data-custom-section] h1,
[data-custom-section] h2,
[data-custom-html] h1,
[data-custom-html] h2,
.block-text h1,
.block-text h2{
  color:var(--pxth-title-color) !important;
}

/* ไม่ให้ h3 ชื่อสินค้า / หัวข้อย่อย ตามสีไตเติ้ล */
body h3,
body h4,
body h5,
body h6,
.custom-block[data-block-type="product"] h3,
.custom-block[data-block-type="product"] [data-field="title"],
.block-product-card h3,
.block-product-card [data-field="title"]{
  color:inherit !important;
}

/* ไม่แตะหัวข้อ/ข้อความใน toolbar และ modal ระบบ */
html[data-edit="1"] #pxth-toolbar h1,
html[data-edit="1"] #pxth-toolbar h2,
html[data-edit="1"] #pxth-toolbar h3,
html[data-edit="1"] .pxth-custom-modal h1,
html[data-edit="1"] .pxth-custom-modal h2,
html[data-edit="1"] .pxth-custom-modal h3,
html[data-edit="1"] .pxth-mini-text-modal h1,
html[data-edit="1"] .pxth-mini-text-modal h2,
html[data-edit="1"] .pxth-mini-text-modal h3{
  color:inherit !important;
}


/* PXTH HARD FORCE H1 H2 TITLE COLOR
   แก้กรณี h1/h2 ใน builder ถูก CSS/inline style เดิมทับ */
:root{
  --pxth-title-color: var(--global-title-color, var(--theme-title, var(--pxth-global-title-color, inherit)));
}

/* เฉพาะ h1/h2 เท่านั้น */
body h1,
body h2,
main h1,
main h2,
section h1,
section h2,
section[data-section] h1,
section[data-section] h2,
.custom-section h1,
.custom-section h2,
[data-custom-section] h1,
[data-custom-section] h2,
.custom-block h1,
.custom-block h2,
[data-custom-block] h1,
[data-custom-block] h2,
[data-custom-html] h1,
[data-custom-html] h2,
[contenteditable] h1,
[contenteditable] h2,
.block-text h1,
.block-text h2,
.block-contact-head h1,
.block-contact-head h2,
.block-videos h1,
.block-videos h2,
.block-news-list h1,
.block-news-list h2,
.block-gallery-albums h1,
.block-gallery-albums h2{
  color:var(--pxth-title-color) !important;
  -webkit-text-fill-color:var(--pxth-title-color) !important;
}

/* ถ้า block ใช้ div เป็น title แต่ไม่ใช่สินค้า ให้ตามสี title */
.custom-block:not([data-block-type="product"]) [data-field="title"],
.custom-block:not([data-block-type="product"]) .section-title,
.custom-block:not([data-block-type="product"]) .block-title,
.custom-block:not([data-block-type="product"]) .main-title{
  color:var(--pxth-title-color) !important;
  -webkit-text-fill-color:var(--pxth-title-color) !important;
}

/* ไม่ให้ชื่อสินค้า h3 ตามสีไตเติ้ล */
.custom-block[data-block-type="product"] h3,
.custom-block[data-block-type="product"] [data-field="title"],
.block-product-card h3,
.block-product-card [data-field="title"],
body h3,
body h4,
body h5,
body h6{
  -webkit-text-fill-color:currentColor !important;
}

/* ไม่แตะ editor toolbar/modal */
html[data-edit="1"] #pxth-toolbar h1,
html[data-edit="1"] #pxth-toolbar h2,
html[data-edit="1"] #pxth-toolbar h3,
html[data-edit="1"] .pxth-custom-modal h1,
html[data-edit="1"] .pxth-custom-modal h2,
html[data-edit="1"] .pxth-custom-modal h3,
html[data-edit="1"] .pxth-mini-text-modal h1,
html[data-edit="1"] .pxth-mini-text-modal h2,
html[data-edit="1"] .pxth-mini-text-modal h3{
  color:inherit !important;
  -webkit-text-fill-color:currentColor !important;
}




/* PXTH Product single active column setting UI */
.product-cols-single .pxth-product-cols-line{
  display:grid !important;
  grid-template-columns:120px minmax(180px,1fr) !important;
  gap:12px !important;
  align-items:center !important;
  margin:10px 0 !important;
}
.product-cols-single .pxth-product-cols-line[hidden]{
  display:none !important;
}
.product-cols-single .pxth-product-cols-line span{
  font-weight:800 !important;
  color:#334155 !important;
}
.product-cols-single .pxth-product-cols-line select{
  width:100% !important;
}
.product-cols-single .pxth-help{
  display:block !important;
  margin-top:8px !important;
  color:#64748b !important;
  font-size:12px !important;
}
@media (max-width:768px){
  .product-cols-single .pxth-product-cols-line{
    grid-template-columns:1fr !important;
    gap:6px !important;
  }
}









/* PXTH PRODUCT COLUMNS MINIMAL FIX
   คอลัมน์สินค้าใช้ data-product-view + data-product-cols เท่านั้น */

/* common */
.custom-block[data-block-type="product"] .block-products{
  position:relative !important;
  width:100% !important;
  max-width:100% !important;
}
.custom-block[data-block-type="product"] .block-product-items{
  gap:18px !important;
  width:100% !important;
  max-width:100% !important;
}
.custom-block[data-block-type="product"] .block-product-card{
  box-sizing:border-box !important;
  min-width:0 !important;
}

/* toolbar / arrows */
.custom-block[data-block-type="product"] .block-product-toolbar{
  display:flex !important;
  justify-content:flex-end !important;
  gap:8px !important;
  margin:0 0 18px auto !important;
}
.custom-block[data-block-type="product"] .block-product-toolbar [hidden]{
  display:none !important;
}
.custom-block[data-block-type="product"] .block-product-carousel-nav{
  display:none !important;
}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-toolbar{
  display:none !important;
}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-carousel-nav{
  display:flex !important;
  position:absolute !important;
  top:-58px !important;
  right:0 !important;
  gap:10px !important;
  z-index:20 !important;
}

/* GRID */
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"] .block-product-items{
  display:grid !important;
  overflow:visible !important;
}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-cols="1"] .block-product-items{grid-template-columns:repeat(1,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-cols="2"] .block-product-items{grid-template-columns:repeat(2,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-cols="3"] .block-product-items{grid-template-columns:repeat(3,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-cols="4"] .block-product-items{grid-template-columns:repeat(4,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-cols="5"] .block-product-items{grid-template-columns:repeat(5,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-cols="6"] .block-product-items{grid-template-columns:repeat(6,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"] .block-product-card{
  width:100% !important;
  max-width:100% !important;
  display:block !important;
}

/* LIST */
.custom-block[data-block-type="product"] .block-products[data-product-view="list"] .block-product-items{
  display:grid !important;
  overflow:visible !important;
}
.custom-block[data-block-type="product"] .block-products[data-product-view="list"][data-product-cols="1"] .block-product-items{grid-template-columns:repeat(1,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="list"][data-product-cols="2"] .block-product-items{grid-template-columns:repeat(2,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="list"][data-product-cols="3"] .block-product-items{grid-template-columns:repeat(3,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="list"] .block-product-card{
  width:100% !important;
  max-width:100% !important;
  display:grid !important;
  grid-template-columns:150px minmax(0,1fr) !important;
  align-items:center !important;
  gap:18px !important;
}
.custom-block[data-block-type="product"] .block-products[data-product-view="list"][data-product-cols="1"] .block-product-card{
  grid-template-columns:220px minmax(0,1fr) !important;
}

/* CAROUSEL */
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-items{
  display:flex !important;
  flex-direction:row !important;
  flex-wrap:nowrap !important;
  overflow-x:auto !important;
  overflow-y:hidden !important;
  scroll-snap-type:x mandatory !important;
}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-card{
  flex-grow:0 !important;
  flex-shrink:0 !important;
  width:auto !important;
  min-width:0 !important;
  scroll-snap-align:start !important;
}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-cols="1"] .block-product-card{flex-basis:100% !important;max-width:100% !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-cols="2"] .block-product-card{flex-basis:calc((100% - 18px) / 2) !important;max-width:calc((100% - 18px) / 2) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-cols="3"] .block-product-card{flex-basis:calc((100% - 36px) / 3) !important;max-width:calc((100% - 36px) / 3) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-cols="4"] .block-product-card{flex-basis:calc((100% - 54px) / 4) !important;max-width:calc((100% - 54px) / 4) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-cols="5"] .block-product-card{flex-basis:calc((100% - 72px) / 5) !important;max-width:calc((100% - 72px) / 5) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-cols="6"] .block-product-card{flex-basis:calc((100% - 90px) / 6) !important;max-width:calc((100% - 90px) / 6) !important;}

/* images */
.custom-block[data-block-type="product"] .block-product-image{
  width:100% !important;
  max-width:100% !important;
  aspect-ratio:1/1 !important;
  overflow:hidden !important;
}
.custom-block[data-block-type="product"] .block-product-image img{
  width:100% !important;
  height:100% !important;
  object-fit:cover !important;
}

/* mobile */
@media (max-width:768px){
  .custom-block[data-block-type="product"] .block-products[data-product-view="grid"] .block-product-items{
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
  }
  .custom-block[data-block-type="product"] .block-products[data-product-view="list"] .block-product-items{
    grid-template-columns:1fr !important;
  }
  .custom-block[data-block-type="product"] .block-products[data-product-view="list"] .block-product-card{
    grid-template-columns:110px minmax(0,1fr) !important;
  }
  .custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-card{
    flex-basis:calc((100% - 12px) / 2) !important;
    max-width:calc((100% - 12px) / 2) !important;
  }
  .custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-cols="1"] .block-product-card{
    flex-basis:100% !important;
    max-width:100% !important;
  }
}


/* PXTH PRODUCT GEAR ONLY MODAL CSS */
.product-settings-only .pxth-product-cols-line{
  display:grid !important;
  grid-template-columns:120px minmax(180px,1fr) !important;
  gap:12px !important;
  align-items:center !important;
  margin:10px 0 !important;
}
.product-settings-only .pxth-product-cols-line[hidden]{
  display:none !important;
}
.product-settings-only .pxth-product-cols-line span{
  font-weight:800 !important;
  color:#334155 !important;
}
.product-settings-only .pxth-product-cols-line select{
  width:100% !important;
}
.product-settings-only .pxth-help{
  display:block !important;
  margin-top:8px !important;
  color:#64748b !important;
  font-size:12px !important;
}


/* PXTH PRODUCT GEAR CLICK EXACT FIX CSS
   ให้ปุ่มควบคุมของ Product Block คลิกได้ ไม่โดน overlay/card ทับ */
html[data-edit="1"] .custom-block[data-block-type="product"]{
  position:relative !important;
  overflow:visible !important;
}

html[data-edit="1"] .custom-block[data-block-type="product"] .pxth-block-controls,
html[data-edit="1"] .custom-block[data-block-type="product"] .pxth-custom-controls,
html[data-edit="1"] .custom-block[data-block-type="product"] [data-block-act],
html[data-edit="1"] .custom-block[data-block-type="product"] [data-block-settings],
html[data-edit="1"] .custom-block[data-block-type="product"] .pxth-block-settings,
html[data-edit="1"] .custom-block[data-block-type="product"] .block-settings,
html[data-edit="1"] .custom-block[data-block-type="product"] .custom-block-settings{
  pointer-events:auto !important;
  position:relative !important;
  z-index:99999 !important;
}

html[data-edit="1"] .custom-block[data-block-type="product"] .block-products,
html[data-edit="1"] .custom-block[data-block-type="product"] .block-product-items,
html[data-edit="1"] .custom-block[data-block-type="product"] .block-product-card{
  z-index:auto !important;
}



/* PXTH PRODUCT MODAL SAVE CLEAN REAL FIX */
.product-settings-only{
  z-index:2147483000 !important;
}
.product-settings-only .pxth-custom-panel{
  pointer-events:auto !important;
}
.product-settings-only .pxth-settings-actions{
  pointer-events:auto !important;
  position:relative !important;
  z-index:2147483002 !important;
}
.product-settings-only .product-save-btn,
.product-settings-only .pxth-settings-save{
  pointer-events:auto !important;
  cursor:pointer !important;
  position:relative !important;
  z-index:2147483003 !important;
}
.product-settings-only .pxth-product-responsive-box{
  display:grid !important;
  gap:10px !important;
  padding:12px !important;
  border:1px solid #dbe3ef !important;
  border-radius:12px !important;
  background:#fff !important;
}
.product-settings-only .pxth-product-responsive-box[hidden]{
  display:none !important;
}
.product-settings-only .pxth-product-responsive-box label{
  display:grid !important;
  grid-template-columns:110px minmax(160px,1fr) !important;
  gap:12px !important;
  align-items:center !important;
}
.product-settings-only .pxth-product-responsive-box select{
  width:100% !important;
}


/* PXTH PRODUCT RESPONSIVE COMPLETE FIX */

/* Product modal responsive UI */
.product-settings-only .pxth-product-responsive-box{
  display:grid !important;
  gap:10px !important;
  padding:12px !important;
  border:1px solid #dbe3ef !important;
  border-radius:12px !important;
  background:#fff !important;
}
.product-settings-only .pxth-product-responsive-box[hidden]{
  display:none !important;
}
.product-settings-only .pxth-product-responsive-box strong{
  font-weight:900 !important;
  color:#1f2937 !important;
}
.product-settings-only .pxth-product-responsive-box label{
  display:grid !important;
  grid-template-columns:110px minmax(160px,1fr) !important;
  gap:12px !important;
  align-items:center !important;
}
.product-settings-only .pxth-product-responsive-box label span{
  font-weight:800 !important;
  color:#475569 !important;
}
.product-settings-only .pxth-product-responsive-box select{
  width:100% !important;
}

/* Base product layout */
.custom-block[data-block-type="product"] .block-products{
  width:100% !important;
  max-width:100% !important;
  position:relative !important;
}
.custom-block[data-block-type="product"] .block-product-items{
  gap:18px !important;
  width:100% !important;
  max-width:100% !important;
  box-sizing:border-box !important;
}
.custom-block[data-block-type="product"] .block-product-card{
  min-width:0 !important;
  box-sizing:border-box !important;
  overflow:hidden !important;
}
.custom-block[data-block-type="product"] .block-product-card h3,
.custom-block[data-block-type="product"] .block-product-card .block-product-price,
.custom-block[data-block-type="product"] .block-product-card [data-field="text"]{
  overflow-wrap:anywhere !important;
  word-break:normal !important;
}

/* desktop grid/list */
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"] .block-product-items,
.custom-block[data-block-type="product"] .block-products[data-product-view="list"] .block-product-items{
  display:grid !important;
  grid-template-columns:repeat(var(--product-cols,4), minmax(0,1fr)) !important;
  overflow:visible !important;
}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"] .block-product-card{
  display:block !important;
  width:100% !important;
  max-width:100% !important;
}
.custom-block[data-block-type="product"] .block-products[data-product-view="list"] .block-product-card{
  display:grid !important;
  grid-template-columns:150px minmax(0,1fr) !important;
  gap:18px !important;
  align-items:center !important;
  width:100% !important;
  max-width:100% !important;
}
.custom-block[data-block-type="product"] .block-products[data-product-view="list"][data-product-cols="1"] .block-product-card{
  grid-template-columns:220px minmax(0,1fr) !important;
}

/* desktop carousel */
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-items{
  display:flex !important;
  flex-wrap:nowrap !important;
  gap:18px !important;
  overflow-x:auto !important;
  overflow-y:hidden !important;
  scroll-snap-type:x mandatory !important;
}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-card{
  flex:0 0 calc((100% - (18px * (var(--product-cols,4) - 1))) / var(--product-cols,4)) !important;
  max-width:calc((100% - (18px * (var(--product-cols,4) - 1))) / var(--product-cols,4)) !important;
  scroll-snap-align:start !important;
}

/* tablet */
@media (max-width:1024px){
  .custom-block[data-block-type="product"] .block-products[data-product-view="grid"] .block-product-items,
  .custom-block[data-block-type="product"] .block-products[data-product-view="list"] .block-product-items{
    grid-template-columns:repeat(var(--product-tablet-cols,2), minmax(0,1fr)) !important;
  }

  .custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-card{
    flex-basis:calc((100% - (18px * (var(--product-tablet-cols,2) - 1))) / var(--product-tablet-cols,2)) !important;
    max-width:calc((100% - (18px * (var(--product-tablet-cols,2) - 1))) / var(--product-tablet-cols,2)) !important;
  }

  .custom-block[data-block-type="product"] .block-products[data-product-view="list"] .block-product-card{
    grid-template-columns:130px minmax(0,1fr) !important;
  }
}

/* mobile: use saved mobile columns, default 1 to avoid squeezed text */
@media (max-width:768px){
  .custom-block[data-block-type="product"] .block-products[data-product-view="grid"] .block-product-items,
  .custom-block[data-block-type="product"] .block-products[data-product-view="list"] .block-product-items{
    grid-template-columns:repeat(var(--product-mobile-cols,1), minmax(0,1fr)) !important;
    gap:14px !important;
  }

  .custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-items{
    gap:12px !important;
  }

  .custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-card{
    flex-basis:calc((100% - (12px * (var(--product-mobile-cols,1) - 1))) / var(--product-mobile-cols,1)) !important;
    max-width:calc((100% - (12px * (var(--product-mobile-cols,1) - 1))) / var(--product-mobile-cols,1)) !important;
  }

  .custom-block[data-block-type="product"] .block-products[data-product-view="list"] .block-product-card{
    grid-template-columns:110px minmax(0,1fr) !important;
    gap:12px !important;
  }

  .custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-mobile-cols="1"] .block-product-card,
  .custom-block[data-block-type="product"] .block-products[data-product-view="list"][data-product-mobile-cols="1"] .block-product-card{
    width:100% !important;
    max-width:100% !important;
  }
}


/* PXTH PRODUCT RESPONSIVE HARD OVERRIDE
   ชุดนี้ต้องอยู่ท้ายไฟล์สุด เพื่อทับ CSS เก่าทั้งหมด */

/* base */
.custom-block[data-block-type="product"] .block-products{
  width:100% !important;
  max-width:100% !important;
  position:relative !important;
}
.custom-block[data-block-type="product"] .block-product-items{
  width:100% !important;
  max-width:100% !important;
  box-sizing:border-box !important;
  gap:18px !important;
}
.custom-block[data-block-type="product"] .block-product-card{
  box-sizing:border-box !important;
  min-width:0 !important;
  overflow:hidden !important;
}
.custom-block[data-block-type="product"] .block-product-card h3,
.custom-block[data-block-type="product"] .block-product-price,
.custom-block[data-block-type="product"] [data-field="text"]{
  overflow-wrap:anywhere !important;
  word-break:normal !important;
}

/* grid/list desktop */
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"] .block-product-items,
.custom-block[data-block-type="product"] .block-products[data-product-view="list"] .block-product-items{
  display:grid !important;
  overflow:visible !important;
}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"] .block-product-card{
  display:block !important;
  width:100% !important;
  max-width:100% !important;
}
.custom-block[data-block-type="product"] .block-products[data-product-view="list"] .block-product-card{
  display:grid !important;
  grid-template-columns:150px minmax(0,1fr) !important;
  gap:18px !important;
  align-items:center !important;
  width:100% !important;
  max-width:100% !important;
}

/* carousel desktop */
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-items{
  display:flex !important;
  flex-direction:row !important;
  flex-wrap:nowrap !important;
  gap:18px !important;
  overflow-x:auto !important;
  overflow-y:hidden !important;
  scroll-snap-type:x mandatory !important;
}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-card{
  flex-grow:0 !important;
  flex-shrink:0 !important;
  min-width:0 !important;
  scroll-snap-align:start !important;
}

.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-cols="1"] .block-product-items{grid-template-columns:repeat(1,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-cols="2"] .block-product-items{grid-template-columns:repeat(2,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-cols="3"] .block-product-items{grid-template-columns:repeat(3,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-cols="4"] .block-product-items{grid-template-columns:repeat(4,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-cols="5"] .block-product-items{grid-template-columns:repeat(5,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-cols="6"] .block-product-items{grid-template-columns:repeat(6,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="list"][data-product-cols="1"] .block-product-items{grid-template-columns:repeat(1,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="list"][data-product-cols="2"] .block-product-items{grid-template-columns:repeat(2,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="list"][data-product-cols="3"] .block-product-items{grid-template-columns:repeat(3,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-cols="1"] .block-product-card{flex:0 0 100% !important;flex-basis:100% !important;max-width:100% !important;width:100% !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-cols="2"] .block-product-card{flex:0 0 calc((100% - 18px) / 2) !important;flex-basis:calc((100% - 18px) / 2) !important;max-width:calc((100% - 18px) / 2) !important;width:calc((100% - 18px) / 2) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-cols="3"] .block-product-card{flex:0 0 calc((100% - 36px) / 3) !important;flex-basis:calc((100% - 36px) / 3) !important;max-width:calc((100% - 36px) / 3) !important;width:calc((100% - 36px) / 3) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-cols="4"] .block-product-card{flex:0 0 calc((100% - 54px) / 4) !important;flex-basis:calc((100% - 54px) / 4) !important;max-width:calc((100% - 54px) / 4) !important;width:calc((100% - 54px) / 4) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-cols="5"] .block-product-card{flex:0 0 calc((100% - 72px) / 5) !important;flex-basis:calc((100% - 72px) / 5) !important;max-width:calc((100% - 72px) / 5) !important;width:calc((100% - 72px) / 5) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-cols="6"] .block-product-card{flex:0 0 calc((100% - 90px) / 6) !important;flex-basis:calc((100% - 90px) / 6) !important;max-width:calc((100% - 90px) / 6) !important;width:calc((100% - 90px) / 6) !important;}

/* tablet exact override */
@media (max-width:1024px){
  .custom-block[data-block-type="product"] .block-products[data-product-view="grid"] .block-product-items,
  .custom-block[data-block-type="product"] .block-products[data-product-view="list"] .block-product-items{
    display:grid !important;
  }
  .custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-items{
    display:flex !important;
    gap:18px !important;
  }
  .custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-tablet-cols="1"] .block-product-items{grid-template-columns:repeat(1,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-tablet-cols="2"] .block-product-items{grid-template-columns:repeat(2,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-tablet-cols="3"] .block-product-items{grid-template-columns:repeat(3,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-tablet-cols="4"] .block-product-items{grid-template-columns:repeat(4,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-tablet-cols="5"] .block-product-items{grid-template-columns:repeat(5,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-tablet-cols="6"] .block-product-items{grid-template-columns:repeat(6,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="list"][data-product-tablet-cols="1"] .block-product-items{grid-template-columns:repeat(1,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="list"][data-product-tablet-cols="2"] .block-product-items{grid-template-columns:repeat(2,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="list"][data-product-tablet-cols="3"] .block-product-items{grid-template-columns:repeat(3,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-tablet-cols="1"] .block-product-card{flex:0 0 100% !important;flex-basis:100% !important;max-width:100% !important;width:100% !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-tablet-cols="2"] .block-product-card{flex:0 0 calc((100% - 18px) / 2) !important;flex-basis:calc((100% - 18px) / 2) !important;max-width:calc((100% - 18px) / 2) !important;width:calc((100% - 18px) / 2) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-tablet-cols="3"] .block-product-card{flex:0 0 calc((100% - 36px) / 3) !important;flex-basis:calc((100% - 36px) / 3) !important;max-width:calc((100% - 36px) / 3) !important;width:calc((100% - 36px) / 3) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-tablet-cols="4"] .block-product-card{flex:0 0 calc((100% - 54px) / 4) !important;flex-basis:calc((100% - 54px) / 4) !important;max-width:calc((100% - 54px) / 4) !important;width:calc((100% - 54px) / 4) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-tablet-cols="5"] .block-product-card{flex:0 0 calc((100% - 72px) / 5) !important;flex-basis:calc((100% - 72px) / 5) !important;max-width:calc((100% - 72px) / 5) !important;width:calc((100% - 72px) / 5) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-tablet-cols="6"] .block-product-card{flex:0 0 calc((100% - 90px) / 6) !important;flex-basis:calc((100% - 90px) / 6) !important;max-width:calc((100% - 90px) / 6) !important;width:calc((100% - 90px) / 6) !important;}
}

/* mobile exact override */
@media (max-width:768px){
  .custom-block[data-block-type="product"] .block-product-items{
    gap:14px !important;
  }
  .custom-block[data-block-type="product"] .block-products[data-product-view="grid"] .block-product-items,
  .custom-block[data-block-type="product"] .block-products[data-product-view="list"] .block-product-items{
    display:grid !important;
  }
  .custom-block[data-block-type="product"] .block-products[data-product-view="list"] .block-product-card{
    grid-template-columns:110px minmax(0,1fr) !important;
    gap:12px !important;
  }
  .custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-items{
    display:flex !important;
    gap:12px !important;
  }
  .custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-mobile-cols="1"] .block-product-items{grid-template-columns:repeat(1,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-mobile-cols="2"] .block-product-items{grid-template-columns:repeat(2,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-mobile-cols="3"] .block-product-items{grid-template-columns:repeat(3,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-mobile-cols="4"] .block-product-items{grid-template-columns:repeat(4,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-mobile-cols="5"] .block-product-items{grid-template-columns:repeat(5,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="grid"][data-product-mobile-cols="6"] .block-product-items{grid-template-columns:repeat(6,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="list"][data-product-mobile-cols="1"] .block-product-items{grid-template-columns:repeat(1,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="list"][data-product-mobile-cols="2"] .block-product-items{grid-template-columns:repeat(2,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="list"][data-product-mobile-cols="3"] .block-product-items{grid-template-columns:repeat(3,minmax(0,1fr)) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-mobile-cols="1"] .block-product-card{flex:0 0 100% !important;flex-basis:100% !important;max-width:100% !important;width:100% !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-mobile-cols="2"] .block-product-card{flex:0 0 calc((100% - 12px) / 2) !important;flex-basis:calc((100% - 12px) / 2) !important;max-width:calc((100% - 12px) / 2) !important;width:calc((100% - 12px) / 2) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-mobile-cols="3"] .block-product-card{flex:0 0 calc((100% - 24px) / 3) !important;flex-basis:calc((100% - 24px) / 3) !important;max-width:calc((100% - 24px) / 3) !important;width:calc((100% - 24px) / 3) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-mobile-cols="4"] .block-product-card{flex:0 0 calc((100% - 36px) / 4) !important;flex-basis:calc((100% - 36px) / 4) !important;max-width:calc((100% - 36px) / 4) !important;width:calc((100% - 36px) / 4) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-mobile-cols="5"] .block-product-card{flex:0 0 calc((100% - 48px) / 5) !important;flex-basis:calc((100% - 48px) / 5) !important;max-width:calc((100% - 48px) / 5) !important;width:calc((100% - 48px) / 5) !important;}
.custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-mobile-cols="6"] .block-product-card{flex:0 0 calc((100% - 60px) / 6) !important;flex-basis:calc((100% - 60px) / 6) !important;max-width:calc((100% - 60px) / 6) !important;width:calc((100% - 60px) / 6) !important;}
}


/* PXTH News Responsive Columns */
.block-news-list{
  --news-cols:3;
  --news-mobile-cols:2;
}

@media(max-width:760px){
  .block-news-list.is-grid .block-news-items{
    grid-template-columns:repeat(var(--news-mobile-cols, 2), minmax(0,1fr)) !important;
  }
  .block-news-list.is-list .block-news-items{
    grid-template-columns:repeat(var(--news-mobile-cols, 2), minmax(0,1fr)) !important;
  }
  .block-news-list.is-list .block-news-card{
    display:block !important;
  }
  .block-news-list.is-list .block-news-card .block-news-image{
    height:auto !important;
    min-height:0 !important;
    aspect-ratio:16/9 !important;
  }
  .block-news-list.is-carousel .block-news-card{
    flex:0 0 calc((100% - (18px * (var(--news-mobile-cols, 2) - 1))) / var(--news-mobile-cols, 2)) !important;
    max-width:calc((100% - (18px * (var(--news-mobile-cols, 2) - 1))) / var(--news-mobile-cols, 2)) !important;
  }
}


/* PXTH News Container Responsive Fix
   ใช้ความกว้างจริงของ News block ไม่ใช่ความกว้าง browser */
.block-news-list{
  container-type:inline-size;
  --news-mobile-cols:2;
}

.block-news-list.is-responsive-mobile.is-grid .block-news-items,
.block-news-list.is-responsive-mobile.is-list .block-news-items{
  grid-template-columns:repeat(var(--news-mobile-cols, 2), minmax(0,1fr)) !important;
}

.block-news-list.is-responsive-mobile.is-list .block-news-card{
  display:block !important;
}

.block-news-list.is-responsive-mobile.is-list .block-news-card .block-news-image{
  height:auto !important;
  min-height:0 !important;
  aspect-ratio:16/9 !important;
}

.block-news-list.is-responsive-mobile.is-carousel .block-news-card{
  flex:0 0 calc((100% - (18px * (var(--news-mobile-cols, 2) - 1))) / var(--news-mobile-cols, 2)) !important;
  max-width:calc((100% - (18px * (var(--news-mobile-cols, 2) - 1))) / var(--news-mobile-cols, 2)) !important;
}

/* Browser container query fallback/extra override */
@container (max-width:760px){
  .block-news-list.is-grid .block-news-items,
  .block-news-list.is-list .block-news-items{
    grid-template-columns:repeat(var(--news-mobile-cols, 2), minmax(0,1fr)) !important;
  }

  .block-news-list.is-list .block-news-card{
    display:block !important;
  }

  .block-news-list.is-list .block-news-card .block-news-image{
    height:auto !important;
    min-height:0 !important;
    aspect-ratio:16/9 !important;
  }

  .block-news-list.is-carousel .block-news-card{
    flex:0 0 calc((100% - (18px * (var(--news-mobile-cols, 2) - 1))) / var(--news-mobile-cols, 2)) !important;
    max-width:calc((100% - (18px * (var(--news-mobile-cols, 2) - 1))) / var(--news-mobile-cols, 2)) !important;
  }
}

/* Exact selector for selected 1/2 columns */
.block-news-list.is-responsive-mobile[data-news-mobile-cols="1"].is-grid .block-news-items,
.block-news-list.is-responsive-mobile[data-news-mobile-cols="1"].is-list .block-news-items{
  grid-template-columns:repeat(1,minmax(0,1fr)) !important;
}

.block-news-list.is-responsive-mobile[data-news-mobile-cols="2"].is-grid .block-news-items,
.block-news-list.is-responsive-mobile[data-news-mobile-cols="2"].is-list .block-news-items{
  grid-template-columns:repeat(2,minmax(0,1fr)) !important;
}

.block-news-list.is-responsive-mobile[data-news-mobile-cols="1"].is-carousel .block-news-card{
  flex-basis:100% !important;
  max-width:100% !important;
}

.block-news-list.is-responsive-mobile[data-news-mobile-cols="2"].is-carousel .block-news-card{
  flex-basis:calc((100% - 18px) / 2) !important;
  max-width:calc((100% - 18px) / 2) !important;
}

/* Make 2 columns readable in narrow editor */
.block-news-list.is-responsive-mobile[data-news-mobile-cols="2"] .block-news-body{
  padding:12px !important;
}

.block-news-list.is-responsive-mobile[data-news-mobile-cols="2"] .block-news-body h3{
  font-size:18px !important;
  line-height:1.25 !important;
}

.block-news-list.is-responsive-mobile[data-news-mobile-cols="2"] .block-news-desc{
  font-size:13px !important;
  line-height:1.45 !important;
}


/* PXTH auto contrast button fallback */
.block-video-dots button,
.block-news-dots button,
.block-product-dots button,
.block-video-carousel-nav button,
.block-news-carousel-nav button,
.block-product-carousel-nav button,
.block-product-toolbar button,
[data-product-view-btn],
[data-news-slide],
[data-product-slide],
[data-video-slide]{
  transition:background-color .15s ease, color .15s ease, -webkit-text-fill-color .15s ease !important;
}

.block-video-dots button *,
.block-news-dots button *,
.block-product-dots button *,
.block-video-carousel-nav button *,
.block-news-carousel-nav button *,
.block-product-carousel-nav button *,
.block-product-toolbar button *,
[data-product-view-btn] *,
[data-news-slide] *,
[data-product-slide] *,
[data-video-slide] *{
  color:inherit !important;
  -webkit-text-fill-color:inherit !important;
}


/* PXTH Clear Cache Button
   Default state is neutral so the button can inherit Sidebar menu design.
   Only the floating fallback button gets a dark background below. */
.pxth-clear-cache-btn{
  border:0;
  border-radius:0;
  padding:10px 13px;
  background:transparent;
  color:#1f2937;
  -webkit-text-fill-color:#1f2937;
  font-weight:500;
  cursor:pointer;
  line-height:1;
  white-space:nowrap;
}

.pxth-clear-cache-btn:hover{
  background:#f9fafb;
  color:#111827;
  -webkit-text-fill-color:#111827;
}

.pxth-clear-cache-floating{
  position:fixed !important;
  right:18px !important;
  bottom:18px !important;
  z-index:2147482999 !important;
  box-shadow:0 10px 30px rgba(15,23,42,.22) !important;
}

.pxth-clear-cache-btn.is-loading{
  opacity:.75 !important;
  cursor:wait !important;
}

/* PXTH Clear Cache Notification */
.pxth-cache-toast{
  position:fixed !important;
  right:18px !important;
  top:18px !important;
  z-index:2147483000 !important;
  min-width:240px !important;
  max-width:min(420px, calc(100vw - 36px)) !important;
  padding:14px 16px !important;
  border-radius:14px !important;
  color:var(--pxth-button-text,var(--global-button-text-color,#fff)) !important;
  -webkit-text-fill-color:var(--pxth-button-text,var(--global-button-text-color,#fff)) !important;
  font-weight:900 !important;
  font-size:14px !important;
  line-height:1.4 !important;
  box-shadow:0 18px 50px rgba(15,23,42,.28) !important;
  opacity:0 !important;
  transform:translateY(-12px) !important;
  pointer-events:none !important;
  transition:opacity .18s ease, transform .18s ease !important;
}

.pxth-cache-toast.show{
  opacity:1 !important;
  transform:translateY(0) !important;
}

.pxth-cache-toast.ok{
  background:#16a34a !important;
}

.pxth-cache-toast.error{
  background:#dc2626 !important;
}


/* PXTH Clear Cache text color only.
   Do not add border here; sidebar menu styling is handled in editor/core.js. */
#pxthClearCache:not(.pxth-clear-cache-floating),
[data-clear-cache]:not(.pxth-clear-cache-floating){
  color:#111827;
  -webkit-text-fill-color:#111827;
  border:0;
  outline:0;
  box-shadow:none;
}

#pxthClearCache:not(.pxth-clear-cache-floating):hover,
[data-clear-cache]:not(.pxth-clear-cache-floating):hover{
  color:#111827;
  -webkit-text-fill-color:#111827;
}

/* ปุ่ม Clear Cache แบบลอย */
#pxthClearCache.pxth-clear-cache-floating,
[data-clear-cache].pxth-clear-cache-floating{
  background:#0f172a !important;
  color:#ffffff !important;
  -webkit-text-fill-color:#ffffff !important;
  border:0 !important;
}

/* loading state: sidebar button stays like a normal menu row; floating fallback may show dark loading state. */
#pxthClearCache.is-loading:not(.pxth-clear-cache-floating),
[data-clear-cache].is-loading:not(.pxth-clear-cache-floating){
  color:#111827;
  -webkit-text-fill-color:#111827;
  background:#ffffff;
}
#pxthClearCache.pxth-clear-cache-floating.is-loading,
[data-clear-cache].pxth-clear-cache-floating.is-loading{
  color:#ffffff;
  -webkit-text-fill-color:#ffffff;
  background:#0f172a;
}

/* กัน auto contrast ไป override ปุ่ม clear cache ผิด */
#pxthClearCache *,
[data-clear-cache] *{
  color:inherit !important;
  -webkit-text-fill-color:inherit !important;
}


/* PXTH gallery tabs position persistent fix */
.block-gallery-albums[data-gallery-tabs="top"],
.block-gallery-albums[data-gallery-tab-position="top"],
.block-gallery-albums.tabs-top{
  display:block !important;
}

.block-gallery-albums[data-gallery-tabs="left"],
.block-gallery-albums[data-gallery-tab-position="left"],
.block-gallery-albums.tabs-left{
  display:grid !important;
  grid-template-columns:180px minmax(0,1fr) !important;
  align-items:start !important;
  gap:18px !important;
}

.block-gallery-albums[data-gallery-tabs="right"],
.block-gallery-albums[data-gallery-tab-position="right"],
.block-gallery-albums.tabs-right{
  display:grid !important;
  grid-template-columns:minmax(0,1fr) 180px !important;
  align-items:start !important;
  gap:18px !important;
}

.block-gallery-albums[data-gallery-tabs="left"] .block-gallery-tabs,
.block-gallery-albums[data-gallery-tab-position="left"] .block-gallery-tabs,
.block-gallery-albums.tabs-left .block-gallery-tabs,
.block-gallery-albums[data-gallery-tabs="right"] .block-gallery-tabs,
.block-gallery-albums[data-gallery-tab-position="right"] .block-gallery-tabs,
.block-gallery-albums.tabs-right .block-gallery-tabs{
  display:flex !important;
  flex-direction:column !important;
  gap:8px !important;
  width:100% !important;
  margin:0 !important;
}

.block-gallery-albums[data-gallery-tabs="right"] .block-gallery-tabs,
.block-gallery-albums[data-gallery-tab-position="right"] .block-gallery-tabs,
.block-gallery-albums.tabs-right .block-gallery-tabs{
  grid-column:2 !important;
  grid-row:1 !important;
}

.block-gallery-albums[data-gallery-tabs="right"] .block-gallery-main,
.block-gallery-albums[data-gallery-tab-position="right"] .block-gallery-main,
.block-gallery-albums.tabs-right .block-gallery-main{
  grid-column:1 !important;
  grid-row:1 !important;
}

.block-gallery-albums[data-gallery-tabs="left"] .block-gallery-main,
.block-gallery-albums[data-gallery-tab-position="left"] .block-gallery-main,
.block-gallery-albums.tabs-left .block-gallery-main{
  grid-column:2 !important;
}

.block-gallery-albums[data-gallery-tabs="left"] .block-gallery-tabs button,
.block-gallery-albums[data-gallery-tab-position="left"] .block-gallery-tabs button,
.block-gallery-albums.tabs-left .block-gallery-tabs button,
.block-gallery-albums[data-gallery-tabs="right"] .block-gallery-tabs button,
.block-gallery-albums[data-gallery-tab-position="right"] .block-gallery-tabs button,
.block-gallery-albums.tabs-right .block-gallery-tabs button{
  width:100% !important;
  text-align:center !important;
}

@media(max-width:768px){
  .block-gallery-albums[data-gallery-tabs="left"],
  .block-gallery-albums[data-gallery-tab-position="left"],
  .block-gallery-albums.tabs-left,
  .block-gallery-albums[data-gallery-tabs="right"],
  .block-gallery-albums[data-gallery-tab-position="right"],
  .block-gallery-albums.tabs-right{
    display:block !important;
  }

  .block-gallery-albums[data-gallery-tabs="left"] .block-gallery-tabs,
  .block-gallery-albums[data-gallery-tab-position="left"] .block-gallery-tabs,
  .block-gallery-albums.tabs-left .block-gallery-tabs,
  .block-gallery-albums[data-gallery-tabs="right"] .block-gallery-tabs,
  .block-gallery-albums[data-gallery-tab-position="right"] .block-gallery-tabs,
  .block-gallery-albums.tabs-right .block-gallery-tabs{
    flex-direction:row !important;
    flex-wrap:wrap !important;
    margin-bottom:14px !important;
  }
}


/* PXTH Module Manager UI */
.pxth-module-manager-btn{border:0!important;padding:12px 18px!important;background:#fff!important;color:#0f172a!important;-webkit-text-fill-color:#0f172a!important;font-weight:900!important;cursor:pointer!important;min-height:44px!important;border-left:1px solid #cbd5e1!important}
.pxth-module-manager-btn:hover{background:#f1f5f9!important}
.pxth-module-manager-floating{position:fixed!important;right:18px!important;bottom:70px!important;z-index:2147482998!important;border-radius:12px!important;box-shadow:0 12px 30px rgba(15,23,42,.22)!important}
.pxth-module-modal{position:fixed!important;inset:0!important;z-index:2147482800!important;background:rgba(15,23,42,.58)!important;display:flex!important;align-items:flex-start!important;justify-content:center!important;padding:52px 18px 18px!important}
.pxth-module-panel{width:min(980px,calc(100vw - 36px))!important;max-height:calc(100vh - 80px)!important;background:#fff!important;border-radius:18px!important;box-shadow:0 30px 90px rgba(15,23,42,.35)!important;overflow:hidden!important;color:#0f172a!important}
.pxth-module-head{display:flex!important;align-items:center!important;justify-content:space-between!important;gap:16px!important;padding:18px 22px!important;border-bottom:1px solid #e2e8f0!important}
.pxth-module-head h3{margin:0!important;font-size:22px!important;font-weight:900!important;color:#0f172a!important}
.pxth-module-close{width:38px!important;height:38px!important;border:0!important;border-radius:999px!important;background:#e5e7eb!important;color:#0f172a!important;font-weight:900!important;cursor:pointer!important}
.pxth-module-layout{display:grid!important;grid-template-columns:230px minmax(0,1fr)!important;min-height:480px!important}
.pxth-module-side{padding:16px!important;background:#f8fafc!important;border-right:1px solid #e2e8f0!important;display:flex!important;flex-direction:column!important;gap:10px!important}
.pxth-module-side button{border:1px solid #cbd5e1!important;background:#fff!important;color:#334155!important;font-weight:900!important;border-radius:12px!important;padding:12px!important;text-align:left!important;cursor:pointer!important}
.pxth-module-side button.active{background:#0f172a!important;color:#fff!important;-webkit-text-fill-color:#fff!important}
.pxth-module-main{padding:18px!important;overflow:auto!important}
.pxth-module-main-head{display:flex!important;align-items:center!important;justify-content:space-between!important;gap:14px!important;margin-bottom:14px!important}
.pxth-module-main h4{margin:0 0 14px!important;font-size:18px!important;font-weight:900!important;color:#0f172a!important}
.pxth-module-main-head h4{margin:0!important}
.pxth-module-main-head button,.pxth-module-main form button,.pxth-module-actions button{border:0!important;border-radius:10px!important;background:#0f172a!important;color:#fff!important;-webkit-text-fill-color:#fff!important;font-weight:900!important;padding:10px 13px!important;cursor:pointer!important}
.pxth-module-main input[type="file"]{display:block!important;width:100%!important;border:1px solid #cbd5e1!important;border-radius:12px!important;padding:13px!important;margin:12px 0!important;background:#fff!important}
.pxth-module-card{display:grid!important;grid-template-columns:minmax(0,1fr) auto!important;gap:16px!important;align-items:center!important;padding:14px!important;border:1px solid #e2e8f0!important;border-radius:14px!important;background:#fff!important;margin-bottom:12px!important}
.pxth-module-card strong{display:block!important;font-size:16px!important;font-weight:900!important;color:#0f172a!important}
.pxth-module-card small{display:block!important;color:#64748b!important;font-weight:700!important;margin-top:4px!important}
.pxth-module-card p{margin:8px 0 0!important;color:#475569!important;font-size:13px!important}
.pxth-module-actions{display:flex!important;align-items:center!important;justify-content:flex-end!important;gap:8px!important;flex-wrap:wrap!important}
.pxth-module-actions .danger{background:#dc2626!important}
.pxth-module-status{display:inline-flex!important;align-items:center!important;border-radius:999px!important;padding:6px 10px!important;font-size:12px!important;font-weight:900!important}
.pxth-module-status.on{background:#dcfce7!important;color:#166534!important}
.pxth-module-status.off{background:#fee2e2!important;color:#991b1b!important}
.pxth-module-empty{padding:20px!important;border:1px dashed #cbd5e1!important;border-radius:14px!important;color:#64748b!important;font-weight:800!important}
.pxth-module-empty.error{color:#dc2626!important}
.pxth-module-help,.pxth-module-note{color:#64748b!important;font-weight:700!important;line-height:1.5!important}
.pxth-module-toast{position:fixed!important;right:18px!important;top:18px!important;z-index:2147483001!important;padding:13px 16px!important;border-radius:14px!important;background:#16a34a!important;color:#fff!important;-webkit-text-fill-color:#fff!important;font-weight:900!important;box-shadow:0 18px 50px rgba(15,23,42,.28)!important;opacity:0!important;transform:translateY(-12px)!important;pointer-events:none!important;transition:opacity .18s ease,transform .18s ease!important}
.pxth-module-toast.show{opacity:1!important;transform:translateY(0)!important}
.pxth-module-toast.error{background:#dc2626!important}
@media(max-width:768px){.pxth-module-layout{grid-template-columns:1fr!important}.pxth-module-side{border-right:0!important;border-bottom:1px solid #e2e8f0!important;flex-direction:row!important;overflow:auto!important}.pxth-module-side button{white-space:nowrap!important}.pxth-module-card{grid-template-columns:1fr!important}.pxth-module-actions{justify-content:flex-start!important}}


/* PXTH Module Manager Full UI */
.pxth-module-manager-btn,.pxth-module-menu-btn{border:0!important;padding:12px 18px!important;background:#fff!important;color:#0f172a!important;-webkit-text-fill-color:#0f172a!important;font-weight:900!important;cursor:pointer!important;min-height:44px!important;border-left:1px solid #cbd5e1!important}
.pxth-module-menu-btn{background:#eff6ff!important;color:#0f376f!important;-webkit-text-fill-color:#0f376f!important}
.pxth-module-manager-btn:hover,.pxth-module-menu-btn:hover{background:#f1f5f9!important}
.pxth-module-manager-floating{position:fixed!important;right:18px!important;bottom:70px!important;z-index:2147482998!important;border-radius:12px!important;box-shadow:0 12px 30px rgba(15,23,42,.22)!important}
.pxth-module-modal{position:fixed!important;inset:0!important;z-index:2147482800!important;background:rgba(15,23,42,.58)!important;display:flex!important;align-items:flex-start!important;justify-content:center!important;padding:52px 18px 18px!important}
.pxth-module-panel{width:min(980px,calc(100vw - 36px))!important;max-height:calc(100vh - 80px)!important;background:#fff!important;border-radius:18px!important;box-shadow:0 30px 90px rgba(15,23,42,.35)!important;overflow:hidden!important;color:#0f172a!important}
.pxth-module-admin-panel{width:min(1180px,calc(100vw - 36px))!important}
.pxth-module-head{display:flex!important;align-items:center!important;justify-content:space-between!important;gap:16px!important;padding:18px 22px!important;border-bottom:1px solid #e2e8f0!important}
.pxth-module-head h3{margin:0!important;font-size:22px!important;font-weight:900!important;color:#0f172a!important}
.pxth-module-close{width:38px!important;height:38px!important;border:0!important;border-radius:999px!important;background:#e5e7eb!important;color:#0f172a!important;font-weight:900!important;cursor:pointer!important}
.pxth-module-layout{display:grid!important;grid-template-columns:230px minmax(0,1fr)!important;min-height:480px!important}
.pxth-module-side{padding:16px!important;background:#f8fafc!important;border-right:1px solid #e2e8f0!important;display:flex!important;flex-direction:column!important;gap:10px!important}
.pxth-module-side button{border:1px solid #cbd5e1!important;background:#fff!important;color:#334155!important;font-weight:900!important;border-radius:12px!important;padding:12px!important;text-align:left!important;cursor:pointer!important}
.pxth-module-side button.active{background:#0f172a!important;color:#fff!important;-webkit-text-fill-color:#fff!important}
.pxth-module-main,.pxth-module-admin-body{padding:18px!important;overflow:auto!important;max-height:calc(100vh - 155px)!important}
.pxth-module-main-head{display:flex!important;align-items:center!important;justify-content:space-between!important;gap:14px!important;margin-bottom:14px!important}
.pxth-module-main h4{margin:0 0 14px!important;font-size:18px!important;font-weight:900!important;color:#0f172a!important}
.pxth-module-main-head button,.pxth-module-main form button,.pxth-module-actions button{border:0!important;border-radius:10px!important;background:#0f172a!important;color:#fff!important;-webkit-text-fill-color:#fff!important;font-weight:900!important;padding:10px 13px!important;cursor:pointer!important}
.pxth-module-main input[type="file"]{display:block!important;width:100%!important;border:1px solid #cbd5e1!important;border-radius:12px!important;padding:13px!important;margin:12px 0!important;background:#fff!important}
.pxth-module-card{display:grid!important;grid-template-columns:minmax(0,1fr) auto!important;gap:16px!important;align-items:center!important;padding:14px!important;border:1px solid #e2e8f0!important;border-radius:14px!important;background:#fff!important;margin-bottom:12px!important}
.pxth-module-card strong{display:block!important;font-size:16px!important;font-weight:900!important;color:#0f172a!important}.pxth-module-card small{display:block!important;color:#64748b!important;font-weight:700!important;margin-top:4px!important}.pxth-module-card p{margin:8px 0 0!important;color:#475569!important;font-size:13px!important}
.pxth-module-actions{display:flex!important;align-items:center!important;justify-content:flex-end!important;gap:8px!important;flex-wrap:wrap!important}.pxth-module-actions .danger{background:#dc2626!important}
.pxth-module-status{display:inline-flex!important;align-items:center!important;border-radius:999px!important;padding:6px 10px!important;font-size:12px!important;font-weight:900!important}.pxth-module-status.on{background:#dcfce7!important;color:#166534!important}.pxth-module-status.off{background:#fee2e2!important;color:#991b1b!important}
.pxth-module-empty,.module-block-placeholder,.module-block-missing{padding:20px!important;border:1px dashed #cbd5e1!important;border-radius:14px!important;color:#64748b!important;font-weight:800!important;background:#f8fafc!important}.pxth-module-empty.error{color:#dc2626!important}
.pxth-module-help,.pxth-module-note{color:#64748b!important;font-weight:700!important;line-height:1.5!important}
.pxth-module-toast{position:fixed!important;right:18px!important;top:18px!important;z-index:2147483001!important;padding:13px 16px!important;border-radius:14px!important;background:#16a34a!important;color:#fff!important;-webkit-text-fill-color:#fff!important;font-weight:900!important;box-shadow:0 18px 50px rgba(15,23,42,.28)!important;opacity:0!important;transform:translateY(-12px)!important;pointer-events:none!important;transition:opacity .18s ease,transform .18s ease!important}.pxth-module-toast.show{opacity:1!important;transform:translateY(0)!important}.pxth-module-toast.error{background:#dc2626!important}
@media(max-width:768px){.pxth-module-layout{grid-template-columns:1fr!important}.pxth-module-side{border-right:0!important;border-bottom:1px solid #e2e8f0!important;flex-direction:row!important;overflow:auto!important}.pxth-module-side button{white-space:nowrap!important}.pxth-module-card{grid-template-columns:1fr!important}.pxth-module-actions{justify-content:flex-start!important}}


/* PXTH Toast Top Layer Fix */
#pxthModuleToast,
.pxth-module-toast,
.pxth-toast,
.pxth-clear-cache-toast,
.pxth-cache-toast,
.pxth-notify,
.editor-toast,
.toast {
  position: fixed !important;
  top: 22px !important;
  right: 22px !important;
  left: auto !important;
  bottom: auto !important;
  z-index: 2147483647 !important;
  pointer-events: none !important;
}

#pxthModuleToast.show,
.pxth-module-toast.show,
.pxth-toast.show,
.pxth-clear-cache-toast.show,
.pxth-cache-toast.show,
.pxth-notify.show,
.editor-toast.show,
.toast.show {
  z-index: 2147483647 !important;
}

.pxth-module-modal,
.pxth-module-admin-modal {
  z-index: 2147483000 !important;
}

.pxth-module-panel,
.pxth-module-admin-panel {
  position: relative !important;
  z-index: 2147483001 !important;
}


/* PXTH Module Block Render Fix */
.module-block-preview,
.module-block-render {
  width: 100% !important;
  min-height: 40px !important;
}

.module-block-preview .house-block,
.module-block-render .house-block {
  margin: 0 !important;
}

.module-block-placeholder,
.module-block-missing {
  padding: 18px !important;
  border: 1px dashed #cbd5e1 !important;
  border-radius: 12px !important;
  background: #f8fafc !important;
  color: #334155 !important;
  font-weight: 900 !important;
}

.module-block-placeholder small {
  display: block !important;
  color: #64748b !important;
  margin-top: 4px !important;
}


/* PXTH Module Block Render Plus Save Fix */
.custom-block[data-module-block] {
  display: block !important;
  min-height: 60px !important;
}

.custom-block[data-module-block] .module-block-render,
.custom-block[data-module-block] .module-block-preview {
  display: block !important;
  width: 100% !important;
}



/* PXTH Toolbar Tools Dropdown removed: unified left sidebar controls tools menu */

/* PXTH: hide mobile setting gear on desktop */
#pxth-mob-gear,
.pxth-mob-gear,
.pxth-mobile-gear,
.mobile-gear,
[data-mobile-gear],
[data-mobile-settings],
.pxth-mobile-settings-btn {
  display: none !important;
}

@media (max-width: 768px) {
  #pxth-mob-gear,
  .pxth-mob-gear,
  .pxth-mobile-gear,
  .mobile-gear,
  [data-mobile-gear],
  [data-mobile-settings],
  .pxth-mobile-settings-btn {
    display: flex !important;
  }
}

/* If the button is injected as fixed/floating but has only a gear icon */
@media (min-width: 769px) {
  button[aria-label*="mobile" i],
  button[title*="mobile" i],
  button[aria-label*="ตั้งค่า" i].pxth-mobile-only,
  button[title*="ตั้งค่า" i].pxth-mobile-only {
    display: none !important;
  }
}



/* PXTH Force Section Add + Duplicate Buttons */
.pxth-custom-controls button[data-section-act="add-before"],
.pxth-custom-controls button[data-section-act="duplicate"] {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  font-weight: 900;
}

.pxth-custom-controls button[data-section-act="add-before"],
.pxth-custom-controls button[data-section-act="duplicate"] {
  background: #64748b !important;
  color: #fff !important;
}

.pxth-custom-controls {
  white-space: nowrap;
}



/* PXTH Add Section Before Column Picker */
.pxth-add-section-before-modal {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, .52);
  z-index: 2147483600;
  display: none;
  padding: 24px;
  box-sizing: border-box;
}

.pxth-add-section-before-modal.open {
  display: flex;
  align-items: center;
  justify-content: center;
}

.pxth-add-section-before-panel {
  width: min(520px, calc(100vw - 32px));
  background: #fff;
  color: #0f172a;
  border-radius: 16px;
  box-shadow: 0 24px 70px rgba(0,0,0,.28);
  overflow: hidden;
}

.pxth-add-section-before-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 18px 20px;
  border-bottom: 1px solid #e5e7eb;
}

.pxth-add-section-before-head h3 {
  margin: 0;
  font-size: 22px;
  font-weight: 900;
}

.pxth-add-section-before-head [data-close-add-section] {
  border: 0;
  background: #f1f5f9;
  color: #0f172a;
  border-radius: 10px;
  width: 38px;
  height: 38px;
  font-weight: 900;
  cursor: pointer;
}

.pxth-add-section-before-options {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  padding: 20px;
}

.pxth-add-section-before-options button {
  border: 1px solid #cbd5e1;
  background: #fff;
  color: #0f172a;
  border-radius: 12px;
  padding: 16px 12px;
  font-weight: 900;
  cursor: pointer;
}

.pxth-add-section-before-options button:hover {
  background: #f1f5f9;
  border-color: #64748b;
}

@media (max-width: 520px) {
  .pxth-add-section-before-options {
    grid-template-columns: repeat(2, 1fr);
  }
}


/* PXTH Social Modal Compact */
.pxth-settings-inline{display:flex;flex-wrap:wrap;gap:14px 18px;align-items:center}
.pxth-settings-inline label{display:inline-flex;align-items:center;gap:6px;font-size:13px;font-weight:800;color:#334155}
.pxth-social-settings{box-sizing:border-box}
.pxth-social-settings .pxth-settings-group{padding:12px 14px}
.pxth-social-settings .pxth-settings-title{margin-bottom:8px}
.pxth-social-item-group .pxth-settings-title{margin-bottom:10px}
.pxth-social-fields-row{display:grid;grid-template-columns:140px minmax(0,1.1fr) minmax(0,1.3fr) 150px;gap:10px;align-items:end}
.pxth-social-fields-row label{display:block;font-size:12px;font-weight:800;color:#334155}
.pxth-social-fields-row input[type=text],
.pxth-social-fields-row input:not([type]){width:100%;height:34px;margin-top:5px;box-sizing:border-box;border:1px solid #cbd5e1;border-radius:8px;padding:0 8px;font-size:13px;background:#fff}
.pxth-social-fields-row .pxth-color-line{margin-top:5px}
@media(max-width:760px){.pxth-social-fields-row{grid-template-columns:1fr 1fr}}
@media(max-width:560px){.pxth-social-fields-row{grid-template-columns:1fr}.pxth-settings-inline{gap:10px 14px}}



/* PXTH Remove Module System UI */
#pxth-module-manager,
#pxth-modules,
#pxthModuleModal,
.pxth-module-modal,
.pxth-module-button,
[data-module-manager],
[data-module-action],
button[data-open-module],
a[href*="/modules/"],
.nav-module,
.menu-module {
  display: none !important;
}


/* PXTH Social Core Save Hardfix 1781765190 */
.block-social.block-social--icon .block-social-copy{display:none!important}
.block-social.block-social--full .block-social-copy{display:flex!important;flex-direction:column}
.block-social.block-social--left{justify-content:flex-start!important;text-align:left!important}
.block-social.block-social--center{justify-content:center!important;text-align:center!important}
.block-social.block-social--right{justify-content:flex-end!important;text-align:right!important}
.block-social.block-social--center .block-social-btn{justify-content:center!important}
.block-social.block-social--right .block-social-btn{justify-content:flex-end!important}
.pxth-settings-inline{display:flex;flex-wrap:wrap;gap:14px 18px;align-items:center}
.pxth-settings-inline label{display:inline-flex;align-items:center;gap:6px;font-size:13px;font-weight:800;color:#334155}
.pxth-social-settings .pxth-settings-group{padding:12px 14px}
.pxth-social-fields-row{display:grid;grid-template-columns:140px minmax(0,1.1fr) minmax(0,1.3fr) 150px;gap:10px;align-items:end}
.pxth-social-fields-row label{display:block;font-size:12px;font-weight:800;color:#334155}
.pxth-social-fields-row input[type=text],.pxth-social-fields-row input:not([type]){width:100%;height:34px;margin-top:5px;box-sizing:border-box;border:1px solid #cbd5e1;border-radius:8px;padding:0 8px;font-size:13px;background:#fff}
@media(max-width:760px){.pxth-social-fields-row{grid-template-columns:1fr 1fr}}
@media(max-width:560px){.pxth-social-fields-row{grid-template-columns:1fr}}


/* PXTH Contact Form Block 1781824950 */
.block-contact-form-wrap{width:100%}
.pxth-contact-form-block{
  width:100%;
  max-width:760px;
  margin:0 auto;
  background:#fff;
  border:1px solid rgba(15,23,42,.10);
  border-radius:22px;
  padding:26px;
  box-shadow:0 16px 40px rgba(15,23,42,.08);
}
.pxth-contact-form-head{margin-bottom:18px;text-align:left}
.pxth-contact-form-head h3{margin:0 0 6px;font-size:28px;line-height:1.25;color:var(--pxth-title,#0f172a)}
.pxth-contact-form-head p{margin:0;color:#64748b;font-size:15px;line-height:1.7}
.pxth-contact-form{display:flex;flex-direction:column;gap:14px}
.pxth-contact-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px}
.pxth-contact-form label{display:flex;flex-direction:column;gap:7px;font-weight:800;color:#334155;font-size:14px}
.pxth-contact-form input,
.pxth-contact-form textarea{
  width:100%;
  box-sizing:border-box;
  border:1px solid #cbd5e1;
  border-radius:12px;
  padding:12px 14px;
  font:inherit;
  color:#0f172a;
  background:#fff;
  outline:none;
}
.pxth-contact-form input:focus,
.pxth-contact-form textarea:focus{
  border-color:var(--pxth-button,#2563eb);
  box-shadow:0 0 0 3px color-mix(in srgb, var(--pxth-button,#2563eb) 16%, transparent);
}
.pxth-contact-submit{
  align-self:flex-start;
  border:0;
  border-radius:999px;
  padding:12px 24px;
  background:var(--pxth-button,#2563eb);
  color:#fff;
  font-weight:900;
  cursor:pointer;
  box-shadow:0 10px 26px color-mix(in srgb, var(--pxth-button,#2563eb) 28%, transparent);
}
.pxth-contact-submit:disabled{opacity:.7;cursor:wait}
.pxth-contact-result{min-height:20px;font-size:13px;font-weight:800}
.pxth-contact-result.is-success{color:#15803d}
.pxth-contact-result.is-error{color:#b91c1c}
.pxth-contact-result.is-loading{color:#475569}
.pxth-hp-field{position:absolute!important;left:-9999px!important;opacity:0!important;height:1px!important;width:1px!important}
.pxth-help{display:block;margin-top:6px;color:#64748b;font-size:12px;font-weight:700}
.pxth-contact-settings textarea,
.pxth-contact-settings input{width:100%;box-sizing:border-box;border:1px solid #cbd5e1;border-radius:10px;padding:10px 12px;font:inherit}
@media(max-width:640px){
  .pxth-contact-form-block{padding:20px;border-radius:18px}
  .pxth-contact-grid{grid-template-columns:1fr}
  .pxth-contact-form-head h3{font-size:24px}
  .pxth-contact-submit{width:100%;justify-content:center}
}

/* PXTH Product Mode Both Sides Final 1781857239 */
:root {
  --pxth-product-btn-bg: var(--pxth-button-bg, var(--pxth-button, #2563eb));
  --pxth-product-btn-text: var(--pxth-button-text, #fff);
}

.pxth-product-mode-btn[data-pxth-product-visible="0"],
.pxth-product-mode-btn[hidden] {
  display: none !important;
}

.pxth-product-mode-btn.pxth-product-mode-active,
.pxth-product-mode-btn.active,
.pxth-product-mode-btn.is-active,
.pxth-product-mode-btn[aria-pressed="true"],
.pxth-product-mode-btn[aria-selected="true"] {
  background: var(--pxth-product-btn-bg) !important;
  background-color: var(--pxth-product-btn-bg) !important;
  border-color: var(--pxth-product-btn-bg) !important;
  color: var(--pxth-product-btn-text) !important;
  box-shadow: 0 3px 8px rgba(15,23,42,.08) !important;
}

.pxth-product-mode-btn:not(.pxth-product-mode-active):not(.active):not(.is-active):not([aria-pressed="true"]):not([aria-selected="true"]) {
  background: #fff !important;
  background-color: #fff !important;
  border-color: rgba(15,23,42,.14) !important;
  color: #0f172a !important;
  box-shadow: none !important;
}

/* PXTH Accordion Restore On Product Final 1781857633 */
.pxth-accordion-block {
  width:100%;
  max-width:920px;
  margin:0 auto;
}
.pxth-accordion-head {
  text-align:center;
  margin-bottom:20px;
}
.pxth-accordion-head h3 {
  margin:0 0 8px;
  font-size:clamp(24px,3vw,36px);
  line-height:1.2;
  color:var(--pxth-title,#0f172a);
}
.pxth-accordion-head p {
  margin:0 auto;
  max-width:680px;
  color:#64748b;
  line-height:1.7;
}
.pxth-accordion-list {
  display:flex;
  flex-direction:column;
  gap:12px;
}
.pxth-accordion-item {
  border:1px solid rgba(15,23,42,.10);
  border-radius:16px;
  background:#fff;
  overflow:hidden;
  box-shadow:0 10px 26px rgba(15,23,42,.06);
}
.pxth-accordion-question {
  width:100%;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  border:0;
  background:#fff;
  color:#0f172a;
  padding:18px 20px;
  cursor:pointer;
  text-align:left;
  font:inherit;
}
.pxth-accordion-title {
  font-weight:900;
  line-height:1.45;
}
.pxth-accordion-icon {
  flex:0 0 auto;
  width:30px;
  height:30px;
  border-radius:999px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  font-weight:900;
  background:var(--pxth-button-bg,var(--pxth-button,#2563eb)) !important;
  color:var(--pxth-button-text,#fff) !important;
  transition:transform .18s ease;
}
.pxth-accordion-item.is-open .pxth-accordion-icon {
  transform:rotate(45deg);
}
.pxth-accordion-answer {
  display:grid;
  grid-template-rows:0fr;
  transition:grid-template-rows .22s ease;
}
.pxth-accordion-item.is-open .pxth-accordion-answer {
  grid-template-rows:1fr;
}
.pxth-accordion-content {
  min-height:0;
  overflow:hidden;
  padding:0 20px;
  color:#475569;
  line-height:1.75;
}
.pxth-accordion-item.is-open .pxth-accordion-content {
  padding-bottom:18px;
}
.pxth-accordion-settings .pxth-accordion-setting-item {
  border:1px solid #e2e8f0;
  border-radius:14px;
  padding:12px;
  background:#f8fafc;
  margin-bottom:10px;
}
.pxth-accordion-setting-head {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  margin-bottom:10px;
}
.pxth-accordion-settings input[type="text"],
.pxth-accordion-settings textarea {
  width:100%;
  box-sizing:border-box;
  border:1px solid #cbd5e1;
  border-radius:10px;
  padding:10px 12px;
  font:inherit;
}
.pxth-accordion-setting-head button,
.pxth-accordion-add {
  border:0;
  border-radius:10px;
  padding:8px 12px;
  font-weight:900;
  cursor:pointer;
}
.pxth-accordion-setting-head button {
  background:#fee2e2;
  color:#991b1b;
}
.pxth-accordion-add {
  background:#dbeafe;
  color:#1d4ed8;
}


/* PXTH Targeted Button Colors Fix 1781872963
   แก้เฉพาะ Album tabs, Contact Form submit, Accordion plus icon */
:root {
  --pxth-target-btn-bg: var(--pxth-button-bg, var(--pxth-button, #2563eb));
  --pxth-target-btn-text: var(--pxth-button-text, #fff);
}

.pxth-album-tab-btn.active,
.pxth-album-tab-btn.is-active,
.pxth-album-tab-btn.current,
.pxth-album-tab-btn[aria-selected="true"],
.pxth-album-tab-btn[aria-pressed="true"],
.pxth-gallery-tabs button.active,
.pxth-gallery-tabs button.is-active,
.pxth-gallery-tabs button.current,
.pxth-gallery-tabs button[aria-selected="true"],
.pxth-gallery-tabs button[aria-pressed="true"],
.gallery-tabs button.active,
.gallery-tabs button.is-active,
.gallery-tabs button.current,
.gallery-tabs button[aria-selected="true"],
.gallery-tabs button[aria-pressed="true"],
.album-tabs button.active,
.album-tabs button.is-active,
.album-tabs button.current,
.album-tabs button[aria-selected="true"],
.album-tabs button[aria-pressed="true"],
.pxth-album-tabs button.active,
.pxth-album-tabs button.is-active,
.pxth-album-tabs button.current,
.pxth-album-tabs button[aria-selected="true"],
.pxth-album-tabs button[aria-pressed="true"],
[data-gallery-tabs] button.active,
[data-gallery-tabs] button.is-active,
[data-gallery-tabs] button[aria-selected="true"],
[data-gallery-tabs] button[aria-pressed="true"],
[data-album-tabs] button.active,
[data-album-tabs] button.is-active,
[data-album-tabs] button[aria-selected="true"],
[data-album-tabs] button[aria-pressed="true"] {
  background: var(--pxth-target-btn-bg) !important;
  background-color: var(--pxth-target-btn-bg) !important;
  border-color: var(--pxth-target-btn-bg) !important;
  color: var(--pxth-target-btn-text) !important;
}

.pxth-album-tab-btn:not(.active):not(.is-active):not(.current):not([aria-selected="true"]):not([aria-pressed="true"]),
.pxth-gallery-tabs button:not(.active):not(.is-active):not(.current):not([aria-selected="true"]):not([aria-pressed="true"]),
.gallery-tabs button:not(.active):not(.is-active):not(.current):not([aria-selected="true"]):not([aria-pressed="true"]),
.album-tabs button:not(.active):not(.is-active):not(.current):not([aria-selected="true"]):not([aria-pressed="true"]),
.pxth-album-tabs button:not(.active):not(.is-active):not(.current):not([aria-selected="true"]):not([aria-pressed="true"]),
[data-gallery-tabs] button:not(.active):not(.is-active):not([aria-selected="true"]):not([aria-pressed="true"]),
[data-album-tabs] button:not(.active):not(.is-active):not([aria-selected="true"]):not([aria-pressed="true"]) {
  background: #fff !important;
  background-color: #fff !important;
  border-color: rgba(15,23,42,.14) !important;
  color: #111827 !important;
  box-shadow: none !important;
}

.pxth-contact-submit,
.pxth-contact-form button[type="submit"],
.block-contact-form-wrap button[type="submit"],
[data-block-type="contact-form"] button[type="submit"] {
  background: var(--pxth-target-btn-bg) !important;
  background-color: var(--pxth-target-btn-bg) !important;
  border-color: var(--pxth-target-btn-bg) !important;
  color: var(--pxth-target-btn-text) !important;
  box-shadow: 0 4px 10px rgba(15,23,42,.10) !important;
}

.pxth-accordion-icon,
.pxth-accordion-question .pxth-accordion-icon {
  color: #fff !important;
}

/* PXTH Auto Button Text Contrast Fix 1781873723
   ถ้า bg ปุ่มเข้ม JS จะตั้ง --pxth-auto-button-text เป็น #fff
   ถ้า bg ปุ่มอ่อน JS จะตั้งเป็น #111827
*/
:root {
  --pxth-auto-button-text: var(--pxth-button-text, #fff);
}

.pxth-contact-submit,
.pxth-contact-form button[type="submit"],
.block-contact-form-wrap button[type="submit"],
[data-block-type="contact-form"] button[type="submit"],
.pxth-accordion-icon,
.pxth-accordion-question .pxth-accordion-icon,
.pxth-album-tab-btn.active,
.pxth-album-tab-btn.is-active,
.pxth-gallery-tabs button.active,
.pxth-gallery-tabs button.is-active,
.gallery-tabs button.active,
.gallery-tabs button.is-active,
.album-tabs button.active,
.album-tabs button.is-active,
.pxth-album-tabs button.active,
.pxth-album-tabs button.is-active,
[data-gallery-tabs] button.active,
[data-gallery-tabs] button.is-active,
[data-album-tabs] button.active,
[data-album-tabs] button.is-active,
.pxth-product-mode-btn.active,
.pxth-product-mode-btn.is-active,
.pxth-product-mode-btn.pxth-product-mode-active,
.pxth-product-mode-btn[aria-pressed="true"],
.pxth-product-mode-btn[aria-selected="true"] {
  color: var(--pxth-auto-button-text) !important;
}

/* PXTH Gallery Tabs Hard Fix 1781874451
   แก้ปุ่ม Gallery/Album ให้เหมือน Product:
   active = สีปุ่ม
   inactive = ขาว/ดำ
*/
:root {
  --pxth-gallery-active-bg: var(--pxth-button-bg, var(--pxth-button, #2563eb));
  --pxth-gallery-active-text: var(--pxth-auto-button-text, var(--pxth-button-text, #fff));
}

.pxth-album-tab-btn.active,
.pxth-album-tab-btn.is-active,
.pxth-album-tab-btn[aria-selected="true"],
.pxth-album-tab-btn[aria-pressed="true"],
.pxth-gallery-tabs .pxth-album-tab-btn.active,
.gallery-tabs .pxth-album-tab-btn.active,
.album-tabs .pxth-album-tab-btn.active,
.pxth-album-tabs .pxth-album-tab-btn.active {
  background: var(--pxth-gallery-active-bg) !important;
  background-color: var(--pxth-gallery-active-bg) !important;
  border-color: var(--pxth-gallery-active-bg) !important;
  color: var(--pxth-gallery-active-text) !important;
}

.pxth-album-tab-btn:not(.active):not(.is-active):not([aria-selected="true"]):not([aria-pressed="true"]) {
  background: #fff !important;
  background-color: #fff !important;
  border-color: rgba(15,23,42,.14) !important;
  color: #111827 !important;
  box-shadow: none !important;
}

/* PXTH Gallery Inactive Element Style Fix 1781874989
   ทำแบบใน DevTools: inactive album button ต้องฟ้อนดำจริง */
.pxth-album-tab-btn:not(.active):not(.is-active):not(.current):not([aria-selected="true"]):not([aria-pressed="true"]),
.pxth-gallery-tabs button:not(.active):not(.is-active):not(.current):not([aria-selected="true"]):not([aria-pressed="true"]),
.gallery-tabs button:not(.active):not(.is-active):not(.current):not([aria-selected="true"]):not([aria-pressed="true"]),
.album-tabs button:not(.active):not(.is-active):not(.current):not([aria-selected="true"]):not([aria-pressed="true"]),
.pxth-album-tabs button:not(.active):not(.is-active):not(.current):not([aria-selected="true"]):not([aria-pressed="true"]),
[data-gallery-tabs] button:not(.active):not(.is-active):not(.current):not([aria-selected="true"]):not([aria-pressed="true"]),
[data-album-tabs] button:not(.active):not(.is-active):not(.current):not([aria-selected="true"]):not([aria-pressed="true"]),
.pxth-gallery-block button:not(.active):not(.is-active):not(.current):not([aria-selected="true"]):not([aria-pressed="true"]),
.gallery-block button:not(.active):not(.is-active):not(.current):not([aria-selected="true"]):not([aria-pressed="true"]),
[data-block-type="gallery"] button:not(.active):not(.is-active):not(.current):not([aria-selected="true"]):not([aria-pressed="true"]) {
  background: #fff !important;
  background-color: #fff !important;
  border-color: rgba(15,23,42,.14) !important;
  color: rgb(17, 24, 39) !important;
  -webkit-text-fill-color: rgb(17, 24, 39) !important;
  text-shadow: none !important;
  box-shadow: none !important;
}

/* PXTH Gallery Active Text Contrast Fix 1781876540
   Gallery/Album:
   - active สีพื้นหลังตามเมนู สีตัวอักษรต้อง contrast
   - inactive ขาว/ดำ
*/
.pxth-album-tab-btn.active,
.pxth-album-tab-btn.is-active,
.pxth-album-tab-btn.current,
.pxth-album-tab-btn[aria-selected="true"],
.pxth-album-tab-btn[aria-pressed="true"] {
  color: var(--pxth-auto-gallery-active-text, #fff) !important;
  -webkit-text-fill-color: var(--pxth-auto-gallery-active-text, #fff) !important;
  text-shadow: none !important;
}

.pxth-album-tab-btn:not(.active):not(.is-active):not(.current):not([aria-selected="true"]):not([aria-pressed="true"]) {
  background: #fff !important;
  background-color: #fff !important;
  border-color: rgba(15,23,42,.14) !important;
  color: rgb(17, 24, 39) !important;
  -webkit-text-fill-color: rgb(17, 24, 39) !important;
  text-shadow: none !important;
  box-shadow: none !important;
}

/* PXTH Contact Email Combined Fix 1781884242 */
.pxth-contact-result,
.pxth-contact-message {
  margin-top: 12px;
  font-weight: 800;
  font-size: 14px;
  line-height: 1.5;
}
.pxth-contact-result.is-loading,
.pxth-contact-message.is-loading {
  color: #475569;
}
.pxth-contact-result.is-success,
.pxth-contact-message.is-success {
  color: #15803d;
}
.pxth-contact-result.is-error,
.pxth-contact-message.is-error {
  color: #dc2626;
}

/* PXTH Contact Email Debug Real Fix 1781901880 */
.pxth-contact-result,.pxth-contact-message{margin-top:12px;font-weight:800;font-size:14px;line-height:1.55}
.pxth-contact-result.is-loading,.pxth-contact-message.is-loading{color:#475569}
.pxth-contact-result.is-success,.pxth-contact-message.is-success{color:#15803d}
.pxth-contact-result.is-error,.pxth-contact-message.is-error{color:#dc2626}

/* PXTH Contact Repeat Send Fix 1781903596 */
.pxth-contact-result,.pxth-contact-message{margin-top:12px;font-weight:800;font-size:14px;line-height:1.55}
.pxth-contact-result.is-loading,.pxth-contact-message.is-loading{color:#475569}
.pxth-contact-result.is-success,.pxth-contact-message.is-success{color:#15803d}
.pxth-contact-result.is-error,.pxth-contact-message.is-error{color:#dc2626}


/* PXTH Product Mode Inline Fix 1781907306 */
.pxth-custom-modal .pxth-product-settings .pxth-product-mode-options,
.pxth-custom-modal .pxth-product-settings .pxth-product-layout-options,
.pxth-custom-modal .pxth-product-settings [data-setting="product-mode"],
.pxth-custom-modal .pxth-product-settings [data-field="mode"] {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(120px, 1fr)) !important;
  gap: 14px !important;
  align-items: stretch !important;
}

.pxth-custom-modal .pxth-product-settings .pxth-product-mode-options label,
.pxth-custom-modal .pxth-product-settings .pxth-product-layout-options label,
.pxth-custom-modal .pxth-product-settings [data-setting="product-mode"] label,
.pxth-custom-modal .pxth-product-settings [data-field="mode"] label {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  min-height: 54px !important;
  margin: 0 !important;
  white-space: nowrap !important;
  text-align: center !important;
}

.pxth-custom-modal .pxth-product-settings .pxth-product-mode-options input[type="radio"],
.pxth-custom-modal .pxth-product-settings .pxth-product-layout-options input[type="radio"],
.pxth-custom-modal .pxth-product-settings [data-setting="product-mode"] input[type="radio"],
.pxth-custom-modal .pxth-product-settings [data-field="mode"] input[type="radio"] {
  margin: 0 !important;
  flex: 0 0 auto !important;
}

@media (max-width: 640px) {
  .pxth-custom-modal .pxth-product-settings .pxth-product-mode-options,
  .pxth-custom-modal .pxth-product-settings .pxth-product-layout-options,
  .pxth-custom-modal .pxth-product-settings [data-setting="product-mode"],
  .pxth-custom-modal .pxth-product-settings [data-field="mode"] {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 8px !important;
  }
}


/* PXTH CLS FIX: reserve space for custom image blocks before lazy images paint */
.custom-block[data-block-type="image"] .block-image-box{
  contain:layout paint;
}
.custom-block[data-block-type="image"] .block-image-box .block-image-real[width][height]{
  aspect-ratio:attr(width number) / attr(height number);
}
@supports not (aspect-ratio: attr(width number) / attr(height number)){
  .custom-block[data-block-type="image"] .block-image-box .block-image-real[width][height]{
    height:auto !important;
  }
}

/* Force social button text/icons white without JS layout calculation */
.block-social-btn,
.block-social-btn *,
.block-social-ico,
.block-social-copy b,
.block-social-copy small{
  color:var(--pxth-button-text,var(--global-button-text-color,#fff)) !important;
  -webkit-text-fill-color:var(--pxth-button-text,var(--global-button-text-color,#fff)) !important;
  text-shadow:none !important;
}

/* =========================================================
   Gallery Rectangle Thumbnail Fix
   ลดความสูงรูปแกลลอรี่ให้เป็นสี่เหลี่ยมผืนผ้า
   ========================================================= */
.custom-block[data-block-type="gallery"] .block-gallery-image-item,
.block-gallery .block-gallery-image-item{
  aspect-ratio:16 / 9 !important;
  min-height:0 !important;
}
.custom-block[data-block-type="gallery"] .block-gallery-image-item img,
.block-gallery .block-gallery-image-item img{
  width:100% !important;
  height:100% !important;
  display:block !important;
  object-fit:cover !important;
}
.custom-block[data-block-type="gallery"] .gallery-dropzone,
.block-gallery .gallery-dropzone{
  aspect-ratio:16 / 9 !important;
  min-height:120px !important;
}
@media (max-width:768px){
  .custom-block[data-block-type="gallery"] .block-gallery-image-item,
  .block-gallery .block-gallery-image-item,
  .custom-block[data-block-type="gallery"] .gallery-dropzone,
  .block-gallery .gallery-dropzone{
    aspect-ratio:16 / 10 !important;
  }
}

/* PXTH Gallery settings: desktop 5/6 columns and inline album tab position controls */
html[data-edit="1"] .pxth-custom-modal .pxth-gallery-tabs-position-row{
  display:flex !important;
  grid-template-columns:none !important;
  align-items:center !important;
  gap:28px !important;
  flex-wrap:wrap !important;
}
html[data-edit="1"] .pxth-custom-modal .pxth-gallery-tabs-position-row label{
  display:inline-flex !important;
  align-items:center !important;
  gap:8px !important;
  width:auto !important;
  margin:0 !important;
  white-space:nowrap !important;
  line-height:1.2 !important;
}
html[data-edit="1"] .pxth-custom-modal .pxth-gallery-tabs-position-row input[type="radio"]{
  width:18px !important;
  height:18px !important;
  min-width:18px !important;
  margin:0 !important;
  padding:0 !important;
}


/* PXTH fix: saved gallery 5/6 columns must render on public page too */
.block-gallery-albums[data-gallery-cols="5"] .block-gallery-grid{grid-template-columns:repeat(5,minmax(0,1fr)) !important;}
.block-gallery-albums[data-gallery-cols="6"] .block-gallery-grid{grid-template-columns:repeat(6,minmax(0,1fr)) !important;}
@media(max-width:900px){
  .block-gallery-albums[data-gallery-cols="5"] .block-gallery-grid,
  .block-gallery-albums[data-gallery-cols="6"] .block-gallery-grid{grid-template-columns:repeat(2,minmax(0,1fr)) !important;}
}
@media(max-width:760px){
  .block-gallery-albums[data-gallery-mobile-cols="1"] .block-gallery-grid{grid-template-columns:repeat(1,minmax(0,1fr)) !important;}
  .block-gallery-albums[data-gallery-mobile-cols="2"] .block-gallery-grid{grid-template-columns:repeat(2,minmax(0,1fr)) !important;}
  .block-gallery-albums[data-gallery-mobile-cols="3"] .block-gallery-grid{grid-template-columns:repeat(3,minmax(0,1fr)) !important;}
  .block-gallery-albums[data-gallery-mobile-cols="4"] .block-gallery-grid{grid-template-columns:repeat(4,minmax(0,1fr)) !important;}
}

/* =========================================================
   PXTH Social mobile layout fix
   - Icon only: mobile shows 4 round icons in one row
   - Icon + text: mobile stays stacked one button per row
   ========================================================= */
@media (max-width:760px){
  .block-social.block-social--full{
    flex-direction:column !important;
    align-items:stretch !important;
  }
  .block-social.block-social--full .block-social-btn{
    width:100% !important;
    min-width:0 !important;
    box-sizing:border-box !important;
    justify-content:flex-start !important;
  }
  .block-social.block-social--icon{
    flex-direction:row !important;
    align-items:center !important;
    gap:12px !important;
    flex-wrap:wrap !important;
  }
  .block-social.block-social--icon.block-social--left{
    justify-content:flex-start !important;
  }
  .block-social.block-social--icon.block-social--center{
    justify-content:center !important;
  }
  .block-social.block-social--icon.block-social--right{
    justify-content:flex-end !important;
  }
  .block-social.block-social--icon .block-social-btn{
    width:52px !important;
    min-width:52px !important;
    max-width:52px !important;
    height:52px !important;
    min-height:52px !important;
    flex:0 0 52px !important;
    padding:0 !important;
    border-radius:999px !important;
    justify-content:center !important;
    align-items:center !important;
    box-sizing:border-box !important;
  }
  .block-social.block-social--icon .block-social-copy{
    display:none !important;
  }
  .block-social.block-social--icon .block-social-ico{
    width:52px !important;
    height:52px !important;
    min-width:52px !important;
    display:inline-flex !important;
    align-items:center !important;
    justify-content:center !important;
    background:transparent !important;
  }
}

/* PXTH: clear color button for background color pickers */
.pxth-clearable-color{display:grid!important;grid-template-columns:1fr auto!important;gap:8px!important;align-items:center!important;width:100%!important;}
.pxth-clearable-color input[type="color"]{width:100%!important;}
.pxth-clearable-color button,
.pxth-clear-bg-color-btn,
.pxth-clearable-social-color button{height:40px!important;border:0!important;border-radius:8px!important;background:#e5e7eb!important;color:#111827!important;font-weight:900!important;padding:0 12px!important;cursor:pointer!important;white-space:nowrap!important;}
.pxth-clearable-color button:hover,
.pxth-clear-bg-color-btn:hover,
.pxth-clearable-social-color button:hover{background:#d1d5db!important;}
.pxth-clearable-social-color{display:grid!important;grid-template-columns:42px 1fr auto!important;gap:8px!important;align-items:center!important;}
.pxth-clearable-social-color input[type="text"]{min-width:0!important;}


/* PXTH Carousel product card standard: carousel is for featured products, not long descriptions */
.block-products.pxth-product-v2[data-product-view="carousel"] .block-product-desc{
  display:none!important;
}
.block-products.pxth-product-v2[data-product-view="carousel"][data-carousel-desc="short"] .block-product-desc{
  display:-webkit-box!important;
  -webkit-line-clamp:2!important;
  -webkit-box-orient:vertical!important;
  overflow:hidden!important;
}
.block-products.pxth-product-v2[data-product-view="carousel"] .block-product-title{
  display:-webkit-box!important;
  -webkit-line-clamp:2!important;
  -webkit-box-orient:vertical!important;
  overflow:hidden!important;
}
@media(max-width:640px){
  .block-products.pxth-product-v2[data-product-view="carousel"] .block-product-desc{
    display:none!important;
  }
  .block-products.pxth-product-v2[data-product-view="carousel"] .block-product-card{
    padding:10px!important;
  }
  .block-products.pxth-product-v2[data-product-view="carousel"] .block-product-title{
    font-size:14px!important;
    line-height:1.35!important;
  }
  .block-products.pxth-product-v2[data-product-view="carousel"] .block-product-price{
    font-size:13px!important;
    line-height:1.35!important;
  }
}


/* PXTH Product view toggle color fix 2026-06-24 */
.custom-block[data-block-type="product"] .block-products .block-product-toolbar button,
.block-products.pxth-product-v2 .block-product-toolbar button,
.block-products .block-product-toolbar [data-product-view-btn]{
  background:#fff !important;
  color:#111827 !important;
  border-color:#e5e7eb !important;
}
.custom-block[data-block-type="product"] .block-products .block-product-toolbar button.active,
.block-products.pxth-product-v2 .block-product-toolbar button.active,
.block-products .block-product-toolbar [data-product-view-btn].active,
.block-products .block-product-toolbar [data-product-view-btn][aria-pressed="true"]{
  background:var(--pxth-button-bg,var(--global-button-color,var(--theme-button-bg,#2563eb))) !important;
  color:var(--pxth-button-text,var(--global-button-text-color,#fff)) !important;
  border-color:var(--pxth-button-bg,var(--global-button-color,var(--theme-button-bg,#2563eb))) !important;
}

/* PXTH fix 2026-06-25: product buttons follow global button color + inactive black */
.block-product-toolbar [data-product-view-btn],
[data-product-view-btn],
.block-product-carousel-nav button,
[data-product-slide]{
  border:1px solid rgba(15,23,42,.12) !important;
  transition:background-color .15s ease,color .15s ease,border-color .15s ease !important;
}
.block-product-toolbar [data-product-view-btn]:not(.active):not(.is-active):not(.pxth-product-mode-active),
[data-product-view-btn]:not(.active):not(.is-active):not(.pxth-product-mode-active){
  background:#fff !important;
  background-color:var(--pxth-button-text,var(--global-button-text-color,#fff)) !important;
  border-color:rgba(15,23,42,.14) !important;
  color:#000 !important;
  -webkit-text-fill-color:#000 !important;
}
.block-product-toolbar [data-product-view-btn].active,
.block-product-toolbar [data-product-view-btn].is-active,
.block-product-toolbar [data-product-view-btn].pxth-product-mode-active,
[data-product-view-btn].active,
[data-product-view-btn].is-active,
[data-product-view-btn].pxth-product-mode-active,
.block-product-carousel-nav button,
[data-product-slide]{
  background:var(--pxth-button-bg,var(--global-button-color,var(--theme-button-bg,#2563eb))) !important;
  background-color:var(--pxth-button-bg,var(--global-button-color,var(--theme-button-bg,#2563eb))) !important;
  border-color:var(--pxth-button-bg,var(--global-button-color,var(--theme-button-bg,#2563eb))) !important;
  color:var(--pxth-button-text,#fff) !important;
  -webkit-text-fill-color:var(--pxth-button-text,#fff) !important;
}
.block-product-toolbar [data-product-view-btn] *,
[data-product-view-btn] *,
.block-product-carousel-nav button *,
[data-product-slide] *{
  color:inherit !important;
  -webkit-text-fill-color:inherit !important;
}

/* PXTH fix 2026-06-25: mobile social full buttons text centered, icons mode unchanged */
@media (max-width:760px){
  .block-social.block-social--full{
    align-items:stretch !important;
  }
  .block-social.block-social--full .block-social-btn{
    width:100% !important;
    box-sizing:border-box !important;
    justify-content:center !important;
    text-align:center !important;
    padding-left:14px !important;
    padding-right:14px !important;
  }
  .block-social.block-social--full .block-social-copy{
    align-items:center !important;
    text-align:center !important;
    flex:0 1 auto !important;
  }
  .block-social.block-social--full .block-social-copy b,
  .block-social.block-social--full .block-social-copy small{
    text-align:center !important;
    width:100% !important;
  }
}


/* PXTH final editor control color fix */
html[data-edit="1"] .pxth-custom-controls button,
html[data-edit="1"] .pxth-block-controls button,
html[data-edit="1"] [data-section-act],
html[data-edit="1"] [data-block-act]{
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
}
html[data-edit="1"] .pxth-custom-controls button svg,
html[data-edit="1"] .pxth-block-controls button svg,
html[data-edit="1"] [data-section-act] svg,
html[data-edit="1"] [data-block-act] svg{
  fill:#fff!important;
  stroke:#fff!important;
}


/* PXTH Mini Text Editor image attachment / alignment / resize */
.pxth-mini-text-toolbar select.pxth-mini-img-vpos{
  height:34px !important;
  min-width:82px !important;
  border:1px solid #d1d5db !important;
  border-radius:8px !important;
  padding:0 8px !important;
  background:#fff !important;
  color:#111827 !important;
  font-size:13px !important;
  font-weight:900 !important;
  cursor:pointer !important;
}

.pxth-mini-editor .pxth-mini-img-wrap,
.custom-block .pxth-mini-img-wrap,
[data-custom-block] .pxth-mini-img-wrap{
  position:relative !important;
  display:block !important;
  max-width:100% !important;
  min-width:80px !important;
  min-height:44px !important;
  box-sizing:border-box !important;
  margin:14px auto !important;
  padding:0 !important;
  clear:both !important;
  line-height:0 !important;
}

.pxth-mini-editor .pxth-mini-img-wrap img,
.custom-block .pxth-mini-img-wrap img,
[data-custom-block] .pxth-mini-img-wrap img{
  display:block !important;
  width:100% !important;
  max-width:100% !important;
  height:auto !important;
  object-fit:cover !important;
  border-radius:10px !important;
}

.pxth-mini-editor .pxth-mini-img-wrap.pxth-img-left,
.custom-block .pxth-mini-img-wrap.pxth-img-left,
[data-custom-block] .pxth-mini-img-wrap.pxth-img-left{
  margin-left:0 !important;
  margin-right:auto !important;
}

.pxth-mini-editor .pxth-mini-img-wrap.pxth-img-center,
.custom-block .pxth-mini-img-wrap.pxth-img-center,
[data-custom-block] .pxth-mini-img-wrap.pxth-img-center{
  margin-left:auto !important;
  margin-right:auto !important;
}

.pxth-mini-editor .pxth-mini-img-wrap.pxth-img-right,
.custom-block .pxth-mini-img-wrap.pxth-img-right,
[data-custom-block] .pxth-mini-img-wrap.pxth-img-right{
  margin-left:auto !important;
  margin-right:0 !important;
}

.pxth-mini-editor .pxth-mini-img-wrap.is-selected{
  outline:3px solid #0b7be8 !important;
  outline-offset:4px !important;
  border-radius:12px !important;
}

.pxth-mini-editor .pxth-mini-img-resize{
  position:absolute !important;
  right:-9px !important;
  bottom:-9px !important;
  width:18px !important;
  height:18px !important;
  border-radius:50% !important;
  background:#0b7be8 !important;
  border:3px solid #fff !important;
  box-shadow:0 4px 12px rgba(15,23,42,.22) !important;
  cursor:nwse-resize !important;
  display:none !important;
  z-index:5 !important;
}

.pxth-mini-editor .pxth-mini-img-wrap.is-selected .pxth-mini-img-resize{
  display:block !important;
}

.custom-block .pxth-mini-img-resize,
[data-custom-block] .pxth-mini-img-resize{
  display:none !important;
}

/* PXTH Mini Text Editor: image right-click menu, no toolbar image position buttons */
.pxth-mini-text-toolbar [data-img-align],
.pxth-mini-text-toolbar .pxth-mini-img-vpos{
  display:none!important;
}
.pxth-mini-img-context-menu{
  position:fixed!important;
  z-index:2147483647!important;
  width:190px!important;
  background:#fff!important;
  border:1px solid #d8e0ea!important;
  border-radius:12px!important;
  box-shadow:0 18px 44px rgba(15,23,42,.22)!important;
  padding:6px!important;
  font-family:inherit!important;
}
.pxth-mini-img-context-menu button{
  display:block!important;
  width:100%!important;
  border:0!important;
  background:#fff!important;
  color:#111827!important;
  text-align:left!important;
  padding:9px 10px!important;
  border-radius:8px!important;
  font-size:13px!important;
  font-weight:800!important;
  cursor:pointer!important;
}
.pxth-mini-img-context-menu button:hover{background:#f1f5f9!important;}
.pxth-mini-img-context-menu button.danger{color:#dc2626!important;}
.pxth-mini-img-context-menu hr{border:0!important;border-top:1px solid #edf2f7!important;margin:5px 0!important;}
.pxth-mini-editor .pxth-mini-img-wrap{
  vertical-align:middle!important;
}

/* PXTH Mini Text Editor image float fix: left/right images let text wrap beside them */
.pxth-mini-editor .pxth-mini-img-wrap.pxth-img-left,
.custom-block .pxth-mini-img-wrap.pxth-img-left,
[data-custom-block] .pxth-mini-img-wrap.pxth-img-left{
  float:left !important;
  display:block !important;
  clear:none !important;
  margin:0 18px 14px 0 !important;
}
.pxth-mini-editor .pxth-mini-img-wrap.pxth-img-right,
.custom-block .pxth-mini-img-wrap.pxth-img-right,
[data-custom-block] .pxth-mini-img-wrap.pxth-img-right{
  float:right !important;
  display:block !important;
  clear:none !important;
  margin:0 0 14px 18px !important;
}
.pxth-mini-editor .pxth-mini-img-wrap.pxth-img-center,
.custom-block .pxth-mini-img-wrap.pxth-img-center,
[data-custom-block] .pxth-mini-img-wrap.pxth-img-center{
  float:none !important;
  display:block !important;
  clear:both !important;
  margin:14px auto !important;
}
.pxth-mini-editor::after,
.custom-block::after,
[data-custom-block]::after{
  content:'';
  display:block;
  clear:both;
}
.pxth-mini-editor .pxth-mini-img-wrap.pxth-img-left + *,
.custom-block .pxth-mini-img-wrap.pxth-img-left + *,
[data-custom-block] .pxth-mini-img-wrap.pxth-img-left + *,
.pxth-mini-editor .pxth-mini-img-wrap.pxth-img-right + *,
.custom-block .pxth-mini-img-wrap.pxth-img-right + *,
[data-custom-block] .pxth-mini-img-wrap.pxth-img-right + *{
  margin-top:0 !important;
}

/* PXTH Mini Text Editor: stable image drag placement */
.pxth-mini-editor .pxth-mini-img-wrap{
  cursor:move!important;
  user-select:none!important;
  -webkit-user-drag:element!important;
}
.pxth-mini-editor .pxth-mini-img-wrap img{
  -webkit-user-drag:none!important;
  user-select:none!important;
  pointer-events:none!important;
}
.pxth-mini-editor .pxth-mini-img-wrap.is-dragging{
  opacity:.45!important;
}
.pxth-mini-editor > img:not(.pxth-mini-img-wrap img){
  max-width:100%!important;
  height:auto!important;
}


/* PXTH PageSpeed real image boxes */
.block-news-image{position:relative;overflow:hidden;background:#eef2f7}
.block-news-image .block-news-img-real{width:100%;height:100%;display:block;object-fit:cover}
.block-gallery-image-item img{width:100%;height:100%;object-fit:cover;display:block}
.block-image-box img,.block-banner-image img{display:block}

/* PXTH_REMOVE_PRODUCT_BLOCK_COMPLETELY removed: product block is enabled again. */

/* PXTH_CLEAN_DB_PRODUCT_BLOCK_REWRITE
   Product Block ใหม่ใช้ class pxth-clean-* เท่านั้น ไม่พึ่ง legacy .block-products */
.custom-block[data-block-type="product"],
.custom-block[data-block-type="product"] *{box-sizing:border-box;}
.custom-block[data-block-type="product"]{width:100%;max-width:100%;min-width:0;overflow:hidden;isolation:auto;}
.pxth-clean-product-block{width:100%;max-width:100%;min-width:0;overflow:hidden;}
.pxth-clean-product-items{width:100%;max-width:100%;min-width:0;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px;align-items:stretch;}
.pxth-clean-product-card{width:100%;max-width:100%;min-width:0;display:flex;flex-direction:column;overflow:hidden;background:#fff;border:1px solid #e5e7eb;border-radius:16px;box-shadow:0 10px 24px rgba(15,23,42,.06);}
.pxth-clean-product-thumb{display:flex;align-items:center;justify-content:center;width:100%;aspect-ratio:16/10;background:#eef2f7;color:#8a8f98;text-decoration:none;overflow:hidden;}
.pxth-clean-product-thumb img{display:block;width:100%;height:100%;object-fit:cover;max-width:none;}
.pxth-clean-product-placeholder{font-size:34px;font-weight:800;color:#8a8f98;letter-spacing:.04em;}
.pxth-clean-product-body{display:flex;flex-direction:column;gap:8px;padding:16px;min-width:0;}
.pxth-clean-product-body h3{margin:0!important;font-size:18px!important;line-height:1.35!important;font-weight:900!important;letter-spacing:-.01em!important;overflow-wrap:anywhere;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;}
.pxth-clean-product-body h3 a{color:inherit;text-decoration:none;}
.pxth-clean-product-price{font-size:15px;font-weight:900;color:#111827;}
.pxth-clean-product-price del{opacity:.55;margin-right:5px;}
.pxth-clean-product-desc{margin:0!important;font-size:14px!important;line-height:1.65!important;color:#64748b;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;}
.pxth-clean-product-actions{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:auto;align-items:center;}
.pxth-clean-product-actions a,.pxth-clean-product-actions button{display:inline-flex;align-items:center;justify-content:center;gap:7px;min-height:38px;padding:8px 10px;border-radius:10px;text-decoration:none;font-size:13px;font-weight:900;line-height:1.2;white-space:nowrap;font-family:inherit;}
.pxth-clean-product-detail{background:#eef2f7;color:#111827;}
.pxth-clean-product-line{background:#06c755;color:#fff;}
.pxth-clean-product-empty{grid-column:1/-1;width:100%;padding:24px;border:1px dashed #cbd5e1;border-radius:14px;background:#f8fafc;color:#64748b;font-weight:900;text-align:center;}
.pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-items{grid-template-columns:1fr;}
.pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-card{display:grid;grid-template-columns:minmax(170px,34%) minmax(0,1fr);align-items:stretch;}
.pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-thumb{height:100%;aspect-ratio:auto;min-height:180px;}
.pxth-clean-product-block[data-product-view="carousel"]{position:relative;}
.pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-items{display:flex;gap:18px;overflow-x:auto;overflow-y:hidden;scroll-snap-type:x mandatory;scroll-behavior:smooth;scrollbar-width:none;-ms-overflow-style:none;}
.pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-items::-webkit-scrollbar{display:none;width:0;height:0;}
.pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-card{flex:0 0 calc((100% - 36px)/3);scroll-snap-align:start;}
.pxth-clean-product-nav{display:flex;justify-content:flex-end;gap:8px;margin:0 0 12px;}
.pxth-clean-product-nav button{width:38px;height:38px;border:0;border-radius:999px;background:#111827;color:#fff;font-size:28px;font-weight:900;line-height:1;cursor:pointer;box-shadow:0 8px 20px rgba(15,23,42,.14);}
@media(max-width:900px){.pxth-clean-product-items{grid-template-columns:repeat(2,minmax(0,1fr));}.pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-card{flex-basis:calc((100% - 18px)/2);}.pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-card{grid-template-columns:1fr;}.pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-thumb{aspect-ratio:16/10;min-height:0;}}
@media(max-width:760px){.pxth-clean-product-items{grid-template-columns:1fr;}.pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-card{flex-basis:100%;}.pxth-clean-product-actions{grid-template-columns:1fr;}.pxth-clean-product-nav{justify-content:center;}}

.pxth-clean-product-settings-panel{max-width:760px!important;}
.pxth-clean-product-view-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;}
.pxth-clean-product-view-options label{display:flex;align-items:center;justify-content:center;gap:8px;min-height:54px;border:1px solid #d8dee9;border-radius:14px;background:#fff;font-weight:900;color:#111827;cursor:pointer;}
.pxth-clean-product-view-options input{width:18px;height:18px;margin:0;}
.pxth-clean-product-count-row{display:grid;grid-template-columns:44px minmax(100px,160px) 44px;gap:10px;align-items:center;}
.pxth-clean-product-count-row button{width:44px;height:42px;border:0;border-radius:12px;background:#0f172a;color:#fff;font-size:24px;font-weight:900;line-height:1;cursor:pointer;}
.pxth-clean-product-count-row input{width:100%;height:42px;border:1px solid #cbd5e1;border-radius:12px;text-align:center;font-size:16px;font-weight:900;background:#fff;color:#111827;}
@media(max-width:620px){.pxth-clean-product-view-options{grid-template-columns:1fr}.pxth-clean-product-count-row{grid-template-columns:44px 1fr 44px;}}


/* PXTH_CLEAN_PRODUCT_ADD_VISIBLE_FIX */
html[data-edit="1"] .custom-block[data-block-type="product"],
.custom-block[data-block-type="product"]{display:block!important;width:100%!important;max-width:100%!important;min-width:0!important;overflow:hidden!important;}
.custom-block[data-block-type="product"] .pxth-clean-product-block{display:block!important;width:100%!important;max-width:100%!important;min-width:0!important;overflow:hidden!important;}
.custom-block[data-block-type="product"] .pxth-clean-product-items{min-height:110px!important;}
.custom-block[data-block-type="product"] .block-products,
.custom-block[data-block-type="product"] .pxth-products-frontend{display:none!important;}


/* PXTH_PRODUCT_CLEAN_SETTINGS_FINAL
   Final override: Product Block must not clip its gear controls and must stay inside its own column. */
html[data-edit="1"] .custom-block[data-block-type="product"],
.custom-block[data-block-type="product"]{
  display:block!important;
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  overflow:visible!important;
  position:relative!important;
  isolation:auto!important;
  box-sizing:border-box!important;
}
html[data-edit="1"] .custom-block[data-block-type="product"] > .pxth-block-controls{
  display:inline-flex!important;
  visibility:visible!important;
  opacity:1!important;
  pointer-events:auto!important;
  z-index:2147483000!important;
}
.custom-block[data-block-type="product"] .pxth-clean-product-block{
  display:block!important;
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  overflow:hidden!important;
  box-sizing:border-box!important;
  --pxth-clean-product-cols: var(--pxth-product-cols, 3);
  --pxth-clean-product-mobile-cols: var(--pxth-product-mobile-cols, 1);
}
.custom-block[data-block-type="product"] .pxth-clean-product-items{
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  box-sizing:border-box!important;
  display:grid!important;
  grid-template-columns:repeat(var(--pxth-clean-product-cols,3),minmax(0,1fr))!important;
  gap:18px!important;
  align-items:stretch!important;
}
.custom-block[data-block-type="product"] .pxth-clean-product-card{
  min-width:0!important;
  max-width:100%!important;
  box-sizing:border-box!important;
}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-items{
  grid-template-columns:1fr!important;
}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-card{
  display:grid!important;
  grid-template-columns:minmax(150px,34%) minmax(0,1fr)!important;
  gap:0!important;
}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-items{
  display:flex!important;
  grid-template-columns:none!important;
  gap:18px!important;
  overflow-x:auto!important;
  overflow-y:hidden!important;
  scroll-snap-type:x mandatory!important;
  scroll-behavior:smooth!important;
  scrollbar-width:none!important;
  -ms-overflow-style:none!important;
}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-items::-webkit-scrollbar{display:none!important;width:0!important;height:0!important;}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-card{
  flex:0 0 calc((100% - (18px * (var(--pxth-clean-product-cols,3) - 1))) / var(--pxth-clean-product-cols,3))!important;
  max-width:calc((100% - (18px * (var(--pxth-clean-product-cols,3) - 1))) / var(--pxth-clean-product-cols,3))!important;
  scroll-snap-align:start!important;
}
@media(max-width:760px){
  .custom-block[data-block-type="product"] .pxth-clean-product-items{
    grid-template-columns:repeat(var(--pxth-clean-product-mobile-cols,1),minmax(0,1fr))!important;
  }
  .custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-card{
    display:block!important;
  }
  .custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-card{
    flex:0 0 calc((100% - (14px * (var(--pxth-clean-product-mobile-cols,1) - 1))) / var(--pxth-clean-product-mobile-cols,1))!important;
    max-width:calc((100% - (14px * (var(--pxth-clean-product-mobile-cols,1) - 1))) / var(--pxth-clean-product-mobile-cols,1))!important;
  }
}
.pxth-clean-product-final-modal .pxth-custom-panel{max-width:760px!important;}
.pxth-clean-final-options{display:grid;gap:14px;margin-bottom:14px;}
.pxth-clean-final-card{display:grid;grid-template-columns:28px minmax(0,1fr);gap:12px;align-items:center;padding:16px 18px;border:1px solid #e5e7eb;border-radius:14px;background:#fff;cursor:pointer;}
.pxth-clean-final-card:has(input:checked){border-color:#0b84ff;background:#f8fbff;box-shadow:0 0 0 1px rgba(11,132,255,.12) inset;}
.pxth-clean-final-card input{width:18px;height:18px;margin:0;}
.pxth-clean-final-card strong{display:block;font-size:17px;line-height:1.25;font-weight:900;color:#111827;}
.pxth-clean-final-card small{display:block;margin-top:4px;font-size:13px;line-height:1.35;font-weight:800;color:#64748b;}
.pxth-clean-final-view{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;}
.pxth-clean-final-view label{display:flex;align-items:center;justify-content:center;gap:8px;min-height:44px;border:1px solid #d8dee9;border-radius:12px;background:#fff;font-weight:900;cursor:pointer;}
.pxth-clean-final-view label:has(input:checked){border-color:#0b84ff;background:#f8fbff;color:#0b84ff;}
.pxth-clean-final-view input{width:16px;height:16px;margin:0;}
.pxth-clean-final-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;}
.pxth-clean-final-grid label span{display:block;margin-bottom:6px;font-weight:900;color:#111827;}
.pxth-clean-final-grid select{width:100%;height:42px;border:1px solid #cbd5e1;border-radius:10px;padding:0 10px;background:#fff;font-weight:900;color:#111827;}
.pxth-clean-final-count{display:grid;grid-template-columns:44px minmax(100px,160px) 44px;gap:10px;align-items:center;}
.pxth-clean-final-count button{width:44px;height:42px;border:1px solid #cbd5e1;border-radius:10px;background:#fff;color:#111827;font-size:22px;font-weight:900;cursor:pointer;}
.pxth-clean-final-count input{height:42px;border:1px solid #cbd5e1;border-radius:10px;text-align:center;font-size:16px;font-weight:900;}
@media(max-width:620px){.pxth-clean-final-view,.pxth-clean-final-grid{grid-template-columns:1fr}.pxth-clean-final-count{grid-template-columns:44px 1fr 44px}}


/* PXTH_PRODUCT_CLEAN_LIVE_CATEGORY_CAROUSEL_FIX */
.custom-block[data-block-type="product"]{min-width:0!important;max-width:100%!important;overflow:visible!important;}
.custom-block[data-block-type="product"] .pxth-clean-product-block{width:100%!important;max-width:100%!important;min-width:0!important;overflow:hidden!important;}
.custom-block[data-block-type="product"] .pxth-clean-product-items{width:100%!important;max-width:100%!important;min-width:0!important;}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="grid"] .pxth-clean-product-items,
.custom-block[data-block-type="product"] .pxth-clean-product-block:not([data-product-view]) .pxth-clean-product-items{display:grid!important;grid-template-columns:repeat(var(--pxth-clean-product-cols,3),minmax(0,1fr))!important;gap:18px!important;}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="list"] .pxth-clean-product-items{display:grid!important;grid-template-columns:1fr!important;gap:18px!important;overflow:visible!important;}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-items{display:flex!important;gap:18px!important;overflow-x:auto!important;overflow-y:hidden!important;scroll-snap-type:x mandatory!important;scroll-behavior:smooth!important;scrollbar-width:none!important;-ms-overflow-style:none!important;cursor:grab;}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-items:active{cursor:grabbing;}
.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-card{flex:0 0 calc((100% - (18px * (var(--pxth-clean-product-cols,3) - 1))) / var(--pxth-clean-product-cols,3))!important;max-width:calc((100% - (18px * (var(--pxth-clean-product-cols,3) - 1))) / var(--pxth-clean-product-cols,3))!important;scroll-snap-align:start!important;}
.pxth-clean-product-category-card .pxth-clean-product-thumb{aspect-ratio:16/10!important;}
.pxth-clean-product-final-modal .pxth-custom-panel,.pxth-clean-product-live-modal .pxth-custom-panel{max-width:960px!important;}
.pxth-clean-final-options{display:grid;gap:12px;margin:0 0 14px;}
.pxth-clean-final-card{display:grid!important;grid-template-columns:24px 1fr!important;gap:12px!important;align-items:center!important;min-height:72px!important;padding:14px 16px!important;border:1px solid #d8dee9!important;border-radius:14px!important;background:#fff!important;cursor:pointer!important;}
.pxth-clean-final-card:has(input:checked){border-color:#1683ff!important;background:#f8fbff!important;}
.pxth-clean-final-card input{width:18px!important;height:18px!important;margin:0!important;}
.pxth-clean-final-card strong{display:block!important;font-size:17px!important;line-height:1.25!important;}
.pxth-clean-final-card small{display:block!important;margin-top:4px!important;color:#64748b!important;font-weight:800!important;}
.pxth-clean-final-view{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:12px!important;}
.pxth-clean-final-view label{display:flex!important;align-items:center!important;justify-content:center!important;gap:8px!important;min-height:44px!important;border:1px solid #d8dee9!important;border-radius:12px!important;background:#fff!important;font-weight:900!important;cursor:pointer!important;}
.pxth-clean-final-view label:has(input:checked){border-color:#1683ff!important;color:#1683ff!important;background:#f8fbff!important;}
.pxth-clean-final-count{display:grid!important;grid-template-columns:44px minmax(100px,170px) 44px!important;gap:10px!important;align-items:center!important;}
.pxth-clean-final-count button{width:44px!important;height:42px!important;border:1px solid #cbd5e1!important;border-radius:12px!important;background:#fff!important;color:#0f172a!important;font-size:22px!important;font-weight:900!important;cursor:pointer!important;}
.pxth-clean-final-count input{height:42px!important;border:1px solid #cbd5e1!important;border-radius:12px!important;text-align:center!important;font-size:16px!important;font-weight:900!important;}
.pxth-clean-final-grid{display:grid!important;grid-template-columns:1fr 1fr!important;gap:14px!important;margin:14px 0!important;}
.pxth-clean-final-grid label span{display:block!important;margin:0 0 6px!important;font-weight:900!important;}
.pxth-clean-final-grid select{width:100%!important;height:42px!important;border:1px solid #cbd5e1!important;border-radius:12px!important;padding:0 12px!important;font-weight:900!important;background:#fff!important;}
@media(max-width:760px){.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="grid"] .pxth-clean-product-items{grid-template-columns:repeat(var(--pxth-clean-product-mobile-cols,1),minmax(0,1fr))!important;}.custom-block[data-block-type="product"] .pxth-clean-product-block[data-product-view="carousel"] .pxth-clean-product-card{flex-basis:calc((100% - (14px * (var(--pxth-clean-product-mobile-cols,1) - 1))) / var(--pxth-clean-product-mobile-cols,1))!important;max-width:calc((100% - (14px * (var(--pxth-clean-product-mobile-cols,1) - 1))) / var(--pxth-clean-product-mobile-cols,1))!important;}.pxth-clean-final-view,.pxth-clean-final-grid{grid-template-columns:1fr!important;}}


/* PXTH_PRODUCT_CATEGORY_CARD_CLICK_FIX */
.pxth-clean-product-category-card{
  color:inherit!important;
  text-decoration:none!important;
  cursor:pointer!important;
}
.pxth-clean-product-category-card:hover{
  transform:translateY(-2px);
  box-shadow:0 14px 30px rgba(15,23,42,.10)!important;
}
.pxth-clean-product-category-card .pxth-clean-product-body h3{
  color:inherit!important;
}


/* PXTH_CONTACT_ICON_ADDRESS_LINE_FIXED */
.contact-icon{
  flex:0 0 auto;
  overflow:hidden;
  font-family:"Kanit", system-ui, -apple-system, "Segoe UI", sans-serif;
}
.contact-icon-svg{
  width:20px;
  height:20px;
  display:block;
}
.contact-icon--address,
.contact-icon--line{
  color:var(--contact-color,#334155) !important;
}
.contact-icon--address{
  background:color-mix(in srgb, var(--contact-color,#334155) 14%, #fff) !important;
}
.contact-icon--line{
  background:color-mix(in srgb, var(--contact-color,#16a34a) 16%, #fff) !important;
}
.contact-line-mark{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:25px;
  height:16px;
  border-radius:5px;
  background:var(--contact-color,#16a34a);
  color:#fff;
  font-family:Arial, Helvetica, sans-serif;
  font-size:7px;
  line-height:1;
  font-weight:900;
  letter-spacing:-.3px;
}
.contact-design-simple .contact-line-mark{
  width:24px;
  height:14px;
  font-size:7px;
  border-radius:4px;
}


/* PXTH TITLE COLOR BLACK CHOICE FIX
   ให้หัวข้อ Contact/Block ใช้สีไตเติ้ลที่ผู้ใช้เลือกจริง แม้เลือกสีดำ */
:root{
  --pxth-title-color: var(--global-title-color, var(--theme-title, var(--pxth-global-title-color, inherit)));
}
.custom-block:not([data-block-type="product"]) [data-field="title"],
.custom-block:not([data-block-type="product"]) .section-title,
.custom-block:not([data-block-type="product"]) .block-title,
.custom-block:not([data-block-type="product"]) .main-title,
.custom-block[data-block-type="contact-info"] .block-contact-head h2,
.custom-block[data-block-type="contact-info"] [data-field="title"]{
  color:var(--global-title-color, var(--theme-title, var(--pxth-title-color, inherit))) !important;
  -webkit-text-fill-color:var(--global-title-color, var(--theme-title, var(--pxth-title-color, inherit))) !important;
}

/* PXTH footer text editor close/newline small fix - mini editor only */
html[data-edit="1"] .pxth-mini-text-modal .pxth-mini-text-close{
  pointer-events:auto!important;
  cursor:pointer!important;
  position:relative!important;
  z-index:2147483647!important;
}
html[data-edit="1"] .pxth-mini-text-modal .pxth-mini-editor{
  white-space:normal!important;
}

/* PXTH footer mini text editor close + single Enter line break fix */
html[data-edit="1"] .pxth-mini-editor{
  white-space:pre-wrap !important;
  word-break:normal !important;
  overflow-wrap:anywhere !important;
}
html[data-edit="1"] .pxth-mini-text-head{
  position:relative !important;
  z-index:3 !important;
}
html[data-edit="1"] .pxth-mini-text-close{
  position:relative !important;
  z-index:2147483647 !important;
  pointer-events:auto !important;
  cursor:pointer !important;
  display:inline-flex !important;
  align-items:center !important;
  justify-content:center !important;
}


/* PXTH_PRODUCT_CARD_ICON_BUTTONS_AUTO_CONTRAST */
.pxth-clean-product-actions .pxth-product-action-btn,
.pxth-product-actions .pxth-product-action-btn,
.pxth-product-detail-actions .pxth-product-action-btn,
.pxth-product-detail-actions .pxth-quote-btn{
  gap:7px!important;
}
.pxth-product-action-icon{
  width:17px;
  height:17px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  flex:0 0 auto;
  color:currentColor;
}
.pxth-product-action-icon svg{
  width:100%;
  height:100%;
  display:block;
  fill:currentColor;
}
.pxth-clean-product-quote.pxth-product-action-btn{
  grid-column:1/-1;
}
@media(max-width:760px){
  .pxth-clean-product-body h3{font-size:16px!important;}
  .pxth-clean-product-actions .pxth-product-action-btn,
  .pxth-clean-product-actions a,
  .pxth-clean-product-actions button{font-size:13px!important;}
}


/* PXTH_PRODUCT_CARD_SQUARE_IMAGE_HOVER_QUOTE */
.pxth-clean-product-block:not([data-product-view="list"]) .pxth-clean-product-thumb{
  aspect-ratio:1/1!important;
}
.pxth-clean-product-block:not([data-product-view="list"]) .pxth-clean-product-thumb img{
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
}
.pxth-clean-product-block:not([data-product-view="list"]) .pxth-clean-product-placeholder{
  font-size:34px!important;
}
.pxth-clean-product-body h3{
  font-size:17px!important;
  line-height:1.32!important;
}
.pxth-products-frontend .pxth-product-thumb{
  aspect-ratio:1/1!important;
}
.pxth-products-frontend .pxth-product-thumb img{
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
}

@media (hover:hover) and (pointer:fine){
  .pxth-clean-product-card{
    transition:box-shadow .18s ease, transform .18s ease, border-color .18s ease;
  }
  .pxth-clean-product-card:hover{
    transform:translateY(-2px);
    box-shadow:0 16px 34px rgba(15,23,42,.12);
    border-color:#d8dee8;
  }
  .pxth-clean-product-actions .pxth-clean-product-quote{
    grid-column:1/-1;
    max-height:0!important;
    min-height:0!important;
    height:0!important;
    padding-top:0!important;
    padding-bottom:0!important;
    margin-top:0!important;
    opacity:0!important;
    overflow:hidden!important;
    pointer-events:none!important;
    transform:translateY(-6px);
    transition:max-height .22s ease, height .22s ease, min-height .22s ease, padding .22s ease, opacity .18s ease, transform .22s ease;
  }
  .pxth-clean-product-card:hover .pxth-clean-product-actions .pxth-clean-product-quote,
  .pxth-clean-product-card:focus-within .pxth-clean-product-actions .pxth-clean-product-quote{
    max-height:44px!important;
    min-height:38px!important;
    height:auto!important;
    padding-top:8px!important;
    padding-bottom:8px!important;
    opacity:1!important;
    pointer-events:auto!important;
    transform:translateY(0);
  }
}
@media (hover:none), (pointer:coarse){
  .pxth-clean-product-actions .pxth-clean-product-quote{
    grid-column:1/-1;
    max-height:none!important;
    height:auto!important;
    opacity:1!important;
    pointer-events:auto!important;
  }
}
@media(max-width:760px){
  .pxth-clean-product-body h3{
    font-size:16px!important;
  }
}


/* PXTH_TEXT_EDITOR_CLOSE_OVERLAP_FIX */
/* ซ่อนปุ่มกากบาทสี่เหลี่ยมที่ระบบ dedupe ใส่ซ้ำเข้ามาใน Text Editor */
html[data-edit="1"] .pxth-rt-box > .pxth-modal-x,
html[data-edit="1"] .pxth-mini-text-panel > .pxth-modal-x,
html[data-edit="1"] .pxth-rt-box > .pxth-settings-close,
html[data-edit="1"] .pxth-mini-text-panel > .pxth-settings-close{
  display:none !important;
  visibility:hidden !important;
  opacity:0 !important;
  pointer-events:none !important;
}
html[data-edit="1"] .pxth-rt-head .pxth-rt-x,
html[data-edit="1"] .pxth-mini-text-head .pxth-mini-text-close{
  position:relative !important;
  z-index:2147483647 !important;
  display:inline-flex !important;
  align-items:center !important;
  justify-content:center !important;
}

/* PXTH_SETTINGS_POPUP_CLEAN_CONTROLS_CSS
   รวม style ปุ่มใน Settings popup ไว้จุดเดียว แทน patch ย่อยซ้ำกันหลายชุด
   - ปุ่มปิด: 47x40px
   - ปุ่มล้างสี / ล้าง favicon: 64x36px
   - ปุ่มบันทึก: สูง 42px
*/
html[data-edit] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-settings-head,
html[data-edit="1"] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-settings-head{
  position:relative!important;
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:12px!important;
  padding:16px 64px 16px 18px!important;
}
html[data-edit] body > #pxth-settings-panel.pxth-settings-modal-root button,
html[data-edit="1"] body > #pxth-settings-panel.pxth-settings-modal-root button{
  writing-mode:horizontal-tb!important;
  text-orientation:mixed!important;
  white-space:nowrap!important;
  word-break:keep-all!important;
  overflow-wrap:normal!important;
  letter-spacing:0!important;
  box-sizing:border-box!important;
}
html[data-edit] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-settings-close,
html[data-edit="1"] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-settings-close{
  position:absolute!important;
  top:12px!important;
  right:14px!important;
  width:47px!important;
  height:40px!important;
  min-width:47px!important;
  min-height:40px!important;
  padding:0!important;
  margin:0!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  border:0!important;
  border-radius:6px!important;
  background:#e5e7eb!important;
  color:#111827!important;
  -webkit-text-fill-color:#111827!important;
  box-shadow:none!important;
  font-size:14px!important;
  font-weight:900!important;
  line-height:1!important;
  cursor:pointer!important;
  pointer-events:auto!important;
  visibility:visible!important;
  opacity:1!important;
  z-index:2147483647!important;
}
html[data-edit] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-settings-close:hover,
html[data-edit="1"] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-settings-close:hover{
  background:#f8fafc!important;
}
html[data-edit] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-clear-bg-color-btn,
html[data-edit] body > #pxth-settings-panel.pxth-settings-modal-root #seo-fav-clear,
html[data-edit="1"] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-clear-bg-color-btn,
html[data-edit="1"] body > #pxth-settings-panel.pxth-settings-modal-root #seo-fav-clear{
  width:64px!important;
  min-width:64px!important;
  height:36px!important;
  min-height:36px!important;
  padding:0 10px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  overflow:hidden!important;
  font-size:13px!important;
  font-weight:800!important;
  line-height:1!important;
}
html[data-edit] body > #pxth-settings-panel.pxth-settings-modal-root #pxth-settings-save-bottom,
html[data-edit] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-popup-page-save,
html[data-edit="1"] body > #pxth-settings-panel.pxth-settings-modal-root #pxth-settings-save-bottom,
html[data-edit="1"] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-popup-page-save{
  min-width:104px!important;
  height:42px!important;
  min-height:42px!important;
  padding:0 18px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  overflow:hidden!important;
  font-size:14px!important;
  font-weight:800!important;
  line-height:1!important;
}
html[data-edit] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-theme-row,
html[data-edit="1"] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-theme-row{
  grid-template-columns:92px 50px 64px minmax(118px,1fr) 50px!important;
  column-gap:10px!important;
  align-items:center!important;
  overflow:visible!important;
}
html[data-edit] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-theme-row button,
html[data-edit="1"] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-theme-row button{
  transform:none!important;
}
html[data-edit] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-settings-footer,
html[data-edit="1"] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-settings-footer{
  justify-content:flex-end!important;
  overflow:visible!important;
}
html[data-edit] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-transparent-check,
html[data-edit="1"] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-transparent-check{
  min-width:0!important;
  white-space:nowrap!important;
}
@media(max-width:720px){
  html[data-edit] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-theme-row,
  html[data-edit="1"] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-theme-row{
    grid-template-columns:1fr 50px 64px!important;
  }
  html[data-edit] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-theme-row .pxth-transparent-check,
  html[data-edit="1"] body > #pxth-settings-panel.pxth-settings-modal-root .pxth-theme-row .pxth-transparent-check{
    grid-column:1 / -1!important;
  }
}

/* =========================================================
   PXTH_COLUMN_RESIZE_STAGE6
   Resizable columns for the Custom Section Builder with editable percentage fields.
   ========================================================= */
.custom-grid[data-column-widths]:not([data-column-widths=""]){
  grid-template-columns:var(--pxth-column-widths, inherit);
}
.custom-col[data-col-width]{
  min-width:0;
}
html[data-edit="1"] .custom-grid.pxth-resizable-columns-ready > .custom-col{
  position:relative;
}
html[data-edit="1"] .custom-grid.pxth-resizable-columns-ready > .custom-col[data-col-width]::after{
  content:attr(data-col-width) "%";
  position:absolute;
  top:8px;
  right:8px;
  z-index:99979;
  min-width:44px;
  height:24px;
  padding:0 9px;
  border-radius:999px;
  background:rgba(15,23,42,.82);
  color:#fff;
  font-size:12px;
  font-weight:800;
  line-height:24px;
  white-space:nowrap;
  text-align:center;
  letter-spacing:.1px;
  box-shadow:0 8px 20px rgba(15,23,42,.18);
  pointer-events:none;
  opacity:.72;
}
html[data-edit="1"] .custom-grid.pxth-resizable-columns-ready:hover > .custom-col[data-col-width]::after,
html[data-edit="1"] body.pxth-column-resizing .custom-grid.pxth-resizable-columns-ready > .custom-col[data-col-width]::after{
  opacity:1;
}
html[data-edit="1"] .custom-grid.pxth-resizable-columns-ready{
  position:relative !important;
}
html[data-edit="1"] .pxth-column-resizer{
  position:absolute;
  top:0;
  bottom:0;
  width:18px;
  transform:translateX(-50%);
  z-index:99980;
  cursor:col-resize;
  display:flex;
  align-items:center;
  justify-content:center;
  touch-action:none;
  user-select:none;
  pointer-events:auto;
}
html[data-edit="1"] .pxth-column-resizer::before{
  content:"";
  width:4px;
  height:100%;
  min-height:52px;
  border-radius:999px;
  background:rgba(59,130,246,.35);
  box-shadow:0 0 0 1px rgba(255,255,255,.9),0 8px 18px rgba(15,23,42,.14);
  transition:width .14s ease,background .14s ease,box-shadow .14s ease;
}
html[data-edit="1"] .pxth-column-resizer::after{
  content:attr(data-column-label);
  position:absolute;
  top:50%;
  left:50%;
  transform:translate(-50%,-50%);
  width:auto;
  min-width:86px;
  height:24px;
  padding:0 10px;
  border-radius:999px;
  background:#2563eb;
  color:#fff;
  font-size:12px;
  font-weight:900;
  line-height:24px;
  white-space:nowrap;
  text-align:center;
  box-shadow:0 8px 22px rgba(37,99,235,.32);
  opacity:0;
  transition:opacity .14s ease;
}
html[data-edit="1"] .pxth-column-resizer:hover::before,
html[data-edit="1"] .pxth-column-resizer.is-dragging::before{
  width:6px;
  background:rgba(37,99,235,.72);
  box-shadow:0 0 0 1px rgba(255,255,255,.95),0 12px 28px rgba(37,99,235,.28);
}
html[data-edit="1"] .pxth-column-resizer:hover::after,
html[data-edit="1"] .pxth-column-resizer.is-dragging::after{
  opacity:1;
}
html[data-edit="1"] body.pxth-column-resizing{
  cursor:col-resize !important;
  user-select:none !important;
}
html[data-edit="1"] body.pxth-column-resizing *{
  cursor:col-resize !important;
  user-select:none !important;
}
/* PXTH column percent labels mobile hide */

@media(max-width:760px){
  html[data-edit="1"] .custom-grid.pxth-resizable-columns-ready > .custom-col[data-col-width]::after{
    display:none !important;
  }
}
@media(max-width:760px){
  .custom-grid[data-column-widths]{
    grid-template-columns:1fr !important;
  }
  html[data-edit="1"] .pxth-column-resizer{
    display:none !important;
  }
}
@media(max-width:900px){
  .custom-grid[data-column-widths].custom-cols-4,
  .custom-grid[data-column-widths].custom-cols-5,
  .custom-grid[data-column-widths].custom-cols-6{
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
  }
  html[data-edit="1"] .custom-grid[data-column-widths].custom-cols-4 .pxth-column-resizer,
  html[data-edit="1"] .custom-grid[data-column-widths].custom-cols-5 .pxth-column-resizer,
  html[data-edit="1"] .custom-grid[data-column-widths].custom-cols-6 .pxth-column-resizer{
    display:none !important;
  }
  html[data-edit="1"] .custom-grid[data-column-widths].custom-cols-4 > .custom-col[data-col-width]::after,
  html[data-edit="1"] .custom-grid[data-column-widths].custom-cols-5 > .custom-col[data-col-width]::after,
  html[data-edit="1"] .custom-grid[data-column-widths].custom-cols-6 > .custom-col[data-col-width]::after{
    display:none !important;
  }
}

/* PXTH_COLUMN_RESIZE_STAGE6 editable percentage inputs */
html[data-edit="1"] .custom-grid.pxth-resizable-columns-ready > .custom-col[data-col-width]::after{
  display:none !important;
}
html[data-edit="1"] .custom-grid.pxth-resizable-columns-ready > .custom-col > .pxth-col-percent-input{
  position:absolute;
  top:8px;
  right:8px;
  z-index:99979;
  width:58px;
  height:26px;
  padding:0 7px;
  border:1px solid rgba(255,255,255,.86);
  border-radius:999px;
  background:rgba(15,23,42,.86);
  color:#fff;
  -webkit-text-fill-color:#fff;
  font-size:12px;
  font-weight:900;
  line-height:24px;
  text-align:center;
  letter-spacing:.1px;
  box-shadow:0 8px 20px rgba(15,23,42,.18);
  outline:none;
  opacity:.76;
  pointer-events:auto;
}
html[data-edit="1"] .custom-grid.pxth-resizable-columns-ready:hover > .custom-col > .pxth-col-percent-input,
html[data-edit="1"] body.pxth-column-resizing .custom-grid.pxth-resizable-columns-ready > .custom-col > .pxth-col-percent-input,
html[data-edit="1"] .custom-grid.pxth-resizable-columns-ready > .custom-col > .pxth-col-percent-input:focus{
  opacity:1;
}
html[data-edit="1"] .custom-grid.pxth-resizable-columns-ready > .custom-col > .pxth-col-percent-input:focus{
  width:66px;
  background:#2563eb;
  border-color:rgba(255,255,255,.98);
  box-shadow:0 10px 26px rgba(37,99,235,.32);
}
@media(max-width:760px){
  html[data-edit="1"] .custom-grid.pxth-resizable-columns-ready > .custom-col > .pxth-col-percent-input{
    display:none !important;
  }
}
@media(max-width:900px){
  html[data-edit="1"] .custom-grid[data-column-widths].custom-cols-4 > .custom-col > .pxth-col-percent-input,
  html[data-edit="1"] .custom-grid[data-column-widths].custom-cols-5 > .custom-col > .pxth-col-percent-input,
  html[data-edit="1"] .custom-grid[data-column-widths].custom-cols-6 > .custom-col > .pxth-col-percent-input{
    display:none !important;
  }
}


/* =========================================================
   PXTH Stage 25 - Mobile Related Product Size + No Bottom Scrollbar
   - ลดขนาดสินค้าที่เกี่ยวข้องบนมือถือให้สมส่วน
   - ซ่อน scrollbar แนวนอนของ carousel แต่ยังปัดเลื่อนได้
   - กัน body เกิด horizontal scroll จาก card/placeholder ที่กว้างเกินจอ
   ========================================================= */
@media (max-width: 768px){
  html:not([data-edit="1"]),
  html:not([data-edit="1"]) body{
    max-width:100% !important;
    overflow-x:hidden !important;
  }

  html:not([data-edit="1"]) .custom-section,
  html:not([data-edit="1"]) .custom-section-inner,
  html:not([data-edit="1"]) .custom-block,
  html:not([data-edit="1"]) .block-products{
    max-width:100% !important;
    box-sizing:border-box !important;
  }

  html:not([data-edit="1"]) .custom-block[data-block-type="product"] .block-products[data-product-view="carousel"]{
    overflow:hidden !important;
    max-width:100% !important;
  }

  html:not([data-edit="1"]) .custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-items{
    display:flex !important;
    flex-wrap:nowrap !important;
    gap:12px !important;
    max-width:100% !important;
    overflow-x:auto !important;
    overflow-y:hidden !important;
    overscroll-behavior-x:contain !important;
    -webkit-overflow-scrolling:touch !important;
    scrollbar-width:none !important;
    -ms-overflow-style:none !important;
    padding-bottom:0 !important;
  }

  html:not([data-edit="1"]) .custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-items::-webkit-scrollbar{
    display:none !important;
    width:0 !important;
    height:0 !important;
  }

  html:not([data-edit="1"]) .custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-card,
  html:not([data-edit="1"]) .custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-mobile-cols="1"] .block-product-card,
  html:not([data-edit="1"]) .custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-cols="1"] .block-product-card{
    flex:0 0 min(76vw, 300px) !important;
    flex-basis:min(76vw, 300px) !important;
    width:min(76vw, 300px) !important;
    max-width:min(76vw, 300px) !important;
    min-width:0 !important;
  }

  html:not([data-edit="1"]) .custom-block[data-block-type="product"] .block-product-image,
  html:not([data-edit="1"]) .custom-block[data-block-type="product"] .product-image-box,
  html:not([data-edit="1"]) .custom-block[data-block-type="product"] [data-product-image]{
    width:100% !important;
    max-width:100% !important;
    height:auto !important;
    min-height:0 !important;
    aspect-ratio:1/1 !important;
    overflow:hidden !important;
  }

  html:not([data-edit="1"]) .custom-block[data-block-type="product"] .block-product-image img,
  html:not([data-edit="1"]) .custom-block[data-block-type="product"] .product-image-box img,
  html:not([data-edit="1"]) .custom-block[data-block-type="product"] [data-product-image] img,
  html:not([data-edit="1"]) .custom-block[data-block-type="product"] .product-image-real{
    width:100% !important;
    height:100% !important;
    max-width:100% !important;
    object-fit:cover !important;
  }

  html:not([data-edit="1"]) .custom-block[data-block-type="product"] .product-image-placeholder{
    width:100% !important;
    min-height:0 !important;
    height:auto !important;
    aspect-ratio:1/1 !important;
    font-size:clamp(22px, 7vw, 34px) !important;
  }

  html:not([data-edit="1"]) .custom-block[data-block-type="product"] .block-product-carousel-nav{
    top:-48px !important;
    right:0 !important;
  }
}

@media (max-width: 420px){
  html:not([data-edit="1"]) .custom-block[data-block-type="product"] .block-products[data-product-view="carousel"] .block-product-card,
  html:not([data-edit="1"]) .custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-mobile-cols="1"] .block-product-card,
  html:not([data-edit="1"]) .custom-block[data-block-type="product"] .block-products[data-product-view="carousel"][data-product-cols="1"] .block-product-card{
    flex-basis:min(74vw, 285px) !important;
    width:min(74vw, 285px) !important;
    max-width:min(74vw, 285px) !important;
  }
}


/* PXTH Stage 41: visitor banner must match edit mode quality */
html:not([data-edit="1"]) .custom-block[data-block-type="banner"] .block-banner-real{
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
  filter:none!important;
  transform:none!important;
  image-rendering:auto!important;
}


/* PXTH Stage49: Banner quality guard */
.block-banner-image,
.block-banner-real{
  filter:none!important;
  image-rendering:auto!important;
  transform:none!important;
}
.block-banner-real{
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
}


/* PXTH Stage50: Stop runtime/banner blur */
.block-banner-real[data-pxth-preserve-original="1"]{
  filter:none!important;
  image-rendering:auto!important;
  transform:none!important;
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
}

/* PXTH Stage51: balanced banner optimization */
.block-banner-real[data-pxth-banner-safe="1"]{
  filter:none!important;
  image-rendering:auto!important;
  transform:none!important;
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
}


/* PXTH Stage69: Gallery AJAX Load More */
.block-gallery-loadmore-wrap{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:12px;
  margin:18px 0 4px;
  flex-wrap:wrap;
}
.block-gallery-loadmore{
  border:0;
  border-radius:999px;
  background:var(--global-button-color,var(--theme-button-bg,#0f172a));
  color:var(--global-button-text-color,#fff);
  font-weight:900;
  padding:12px 22px;
  cursor:pointer;
  box-shadow:0 10px 24px rgba(15,23,42,.12);
}
.block-gallery-loadmore:disabled{
  opacity:.6;
  cursor:wait;
}
.block-gallery-count{
  color:#64748b;
  font-weight:800;
  font-size:13px;
}
.block-gallery-panel:not(.active){
  display:none;
}


/* PXTH Stage70: PageSpeed-friendly gallery thumbnails */
.block-gallery-image-item img.pxth-gallery-img{
  width:100%!important;
  height:100%!important;
  object-fit:cover!important;
  display:block!important;
}


/* PXTH Stage78: News/Article title margin fix */
.custom-block[data-block-type="news"] .block-news-body h1,
.custom-block[data-block-type="news"] .block-news-body h2,
.custom-block[data-block-type="news"] .block-news-body h3,
.custom-block[data-block-type="news"] .block-news-body [data-field="title"],
.block-news-list .block-news-body h1,
.block-news-list .block-news-body h2,
.block-news-list .block-news-body h3,
.block-news-list .block-news-body [data-field="title"],
.block-news-card .block-news-body h1,
.block-news-card .block-news-body h2,
.block-news-card .block-news-body h3,
.block-news-card .block-news-body [data-field="title"]{
  margin-top:0!important;
  margin-block-start:0!important;
}
.block-news-body{
  padding-top:14px!important;
}


/* PXTH Stage80: Product carousel arrows follow global button color */
.block-products .block-product-carousel-nav button,
.block-products .block-product-carousel-nav [data-product-slide],
.block-products.pxth-product-v2 .block-product-carousel-nav button,
.block-products.pxth-product-v2 .block-product-carousel-nav [data-product-slide],
.custom-block[data-block-type="product"] .block-product-carousel-nav button,
.custom-block[data-block-type="product"] .block-product-carousel-nav [data-product-slide],
.pxth-db-product-carousel-nav button{
  background:var(--global-button-color,var(--theme-button-bg,#2563eb))!important;
  background-color:var(--global-button-color,var(--theme-button-bg,#2563eb))!important;
  border-color:var(--global-button-color,var(--theme-button-bg,#2563eb))!important;
  color:var(--global-button-text-color,#fff)!important;
  -webkit-text-fill-color:var(--global-button-text-color,#fff)!important;
}
.block-products .block-product-carousel-nav button *,
.block-products .block-product-carousel-nav [data-product-slide] *,
.block-products.pxth-product-v2 .block-product-carousel-nav button *,
.block-products.pxth-product-v2 .block-product-carousel-nav [data-product-slide] *,
.custom-block[data-block-type="product"] .block-product-carousel-nav button *,
.custom-block[data-block-type="product"] .block-product-carousel-nav [data-product-slide] *,
.pxth-db-product-carousel-nav button *{
  color:inherit!important;
  -webkit-text-fill-color:inherit!important;
}
.block-products .block-product-carousel-nav button[disabled],
.block-products .block-product-carousel-nav [data-product-slide][disabled],
.pxth-db-product-carousel-nav button[disabled]{
  opacity:.45!important;
  filter:grayscale(.35)!important;
}



/* PXTH Stage81: Clean product carousel arrows follow global button color */
.pxth-clean-product-nav button,
.pxth-clean-product-block .pxth-clean-product-nav button,
button[data-clean-product-slide],
.custom-block[data-block-type="product"] .pxth-clean-product-nav button,
.custom-block[data-block-type="product"] button[data-clean-product-slide]{
  background:var(--global-button-color,var(--theme-button-bg,#2563eb))!important;
  background-color:var(--global-button-color,var(--theme-button-bg,#2563eb))!important;
  border-color:var(--global-button-color,var(--theme-button-bg,#2563eb))!important;
  color:var(--global-button-text-color,#fff)!important;
  -webkit-text-fill-color:var(--global-button-text-color,#fff)!important;
}
.pxth-clean-product-nav button *,
.pxth-clean-product-block .pxth-clean-product-nav button *,
button[data-clean-product-slide] *,
.custom-block[data-block-type="product"] .pxth-clean-product-nav button *,
.custom-block[data-block-type="product"] button[data-clean-product-slide] *{
  color:inherit!important;
  -webkit-text-fill-color:inherit!important;
}


/* === assets/css/floating-contact.css === */
/* ================== Floating Contact Clean ================== */

.pxth-floating-contact{
  position:fixed;
  right:18px;
  bottom:24px;
  top:auto;
  transform:none;
  z-index:999;
  display:flex;
  flex-direction:column;
  gap:10px;
}

.pxth-float-btn{
  width:52px;
  height:52px;
  border:0;
  border-radius:50%;
  display:flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
  text-decoration:none;
  color:#fff;
  box-shadow:0 8px 20px rgba(0,0,0,.16);
  transition:.2s ease;
}

.pxth-float-btn:hover{
  transform:translateY(-2px);
}

.pxth-float-btn span{
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:19px;
  font-weight:800;
  line-height:1;
}

/* Phone */
.pxth-phone{
  background:#ff5a1f;
}

/* LINE */
.pxth-line,
.pxth-line-oa{
  background:#06c755;
}

.pxth-line span,
.pxth-line-oa span{
  font-size:12px;
  letter-spacing:.02em;
}

/* Email */
.pxth-email{
  background:#2563eb;
}

/* Messenger */
.pxth-messenger{
  background:#0084ff;
}

/* Close */
.pxth-close{
  background:#0f172a;
}

.pxth-close span{
  font-size:24px;
}

/* Collapse */
.pxth-floating-contact.is-collapsed .pxth-float-btn:not(.pxth-close){
  display:none;
}

/* Mobile */
@media(max-width:768px){
  .pxth-floating-contact{
    right:10px;
    bottom:14px;
    top:auto;
    transform:none;
    gap:8px;
  }

  .pxth-float-btn{
    width:46px;
    height:46px;
  }

  .pxth-float-btn span{
    font-size:17px;
  }

  .pxth-line span,
  .pxth-line-oa span{
    font-size:11px;
  }
}


/* === assets/css/richtext-image.css === */
/* RichText Editor images */
.pxth-rt-editor img.rt-img,
[data-edit="richtext"] img.rt-img{
  max-width:100% !important;
  height:auto !important;
  border-radius:8px !important;
  margin:12px 0 !important;
}
.pxth-rt-editor img.align-left,
[data-edit="richtext"] img.align-left{
  float:left !important;
  width:40% !important;
  margin:6px 16px 10px 0 !important;
}
.pxth-rt-editor img.align-right,
[data-edit="richtext"] img.align-right{
  float:right !important;
  width:40% !important;
  margin:6px 0 10px 16px !important;
}
.pxth-rt-editor img.align-center,
[data-edit="richtext"] img.align-center{
  display:block !important;
  margin:14px auto !important;
  float:none !important;
}
.pxth-rt-editor img.align-full,
[data-edit="richtext"] img.align-full{
  display:block !important;
  width:100% !important;
  margin:14px 0 !important;
  float:none !important;
}
.pxth-rt-editor img.pxth-rt-selected{
  outline:3px solid #1677ff !important;
  outline-offset:2px !important;
}
[data-edit="richtext"]::after{
  content:"";
  display:block;
  clear:both;
}


/* === assets/product-quote.css === */
/* PXTH quote/payment frontend */
.pxth-clean-product-quote,.pxth-product-quote-btn{display:inline-flex;align-items:center;justify-content:center;gap:7px;min-height:42px;border:0;border-radius:12px;padding:10px 15px;background:#f59e0b;color:#111827;font-weight:900;cursor:pointer;text-decoration:none;line-height:1.2;font-family:inherit}
.pxth-clean-product-actions{align-items:center}.pxth-clean-product-actions button{font-family:inherit}.pxth-product-detail-actions .pxth-product-quote-btn{background:#f59e0b;color:#111827}.pxth-product-action-icon{width:17px;height:17px;display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;color:currentColor}.pxth-product-action-icon svg{width:100%;height:100%;display:block;fill:currentColor}
.pxth-quote-modal{position:fixed;inset:0;z-index:2147483647;background:rgba(15,23,42,.58);display:flex;align-items:center;justify-content:center;padding:16px;box-sizing:border-box;font-family:Kanit,system-ui,sans-serif}
.pxth-quote-box{width:min(760px,calc(100vw - 32px));max-height:calc(100dvh - 32px);overflow:hidden;background:#fff;color:#0f172a;border-radius:18px;box-shadow:0 30px 90px rgba(15,23,42,.34);display:flex;flex-direction:column}
.pxth-quote-head{display:flex;align-items:center;justify-content:space-between;padding:16px 18px;border-bottom:1px solid #e5e7eb;background:#f8fafc}.pxth-quote-head strong{font-size:18px}.pxth-quote-close{width:36px;height:36px;border:1px solid #e5e7eb;border-radius:999px;background:#fff;font:900 22px/1 system-ui;cursor:pointer}.pxth-quote-body{padding:16px 18px;overflow:auto;display:grid;gap:14px}
.pxth-quote-items{border:1px solid #e5e7eb;border-radius:14px;overflow:hidden}.pxth-quote-item{display:grid;grid-template-columns:1fr 82px 34px;gap:10px;align-items:center;padding:10px 12px;border-bottom:1px solid #eef2f7}.pxth-quote-item:last-child{border-bottom:0}.pxth-quote-item b{display:block}.pxth-quote-item small{color:#64748b}.pxth-quote-item input{height:36px;border:1px solid #cbd5e1;border-radius:8px;padding:0 8px}.pxth-quote-item button{height:32px;border:0;border-radius:8px;background:#fee2e2;color:#991b1b;font-weight:900;cursor:pointer}
.pxth-quote-form{display:grid;gap:12px}.pxth-quote-grid2{display:grid;grid-template-columns:1fr 1fr;gap:12px}.pxth-quote-form label{display:grid;gap:6px;font-weight:900;color:#334155;font-size:13px}.pxth-quote-form input,.pxth-quote-form textarea,.pxth-quote-form select{width:100%;box-sizing:border-box;border:1px solid #cbd5e1;border-radius:10px;padding:10px;font:inherit;background:#fff;color:#111827}.pxth-quote-actions{display:flex;gap:8px;justify-content:flex-end;flex-wrap:wrap;border-top:1px solid #e5e7eb;padding-top:12px}.pxth-quote-submit,.pxth-payment-submit{border:0;border-radius:12px;background:#071120;color:#fff;font-weight:900;min-height:42px;padding:0 16px;cursor:pointer}.pxth-quote-secondary{border:1px solid #cbd5e1;border-radius:12px;background:#fff;color:#0f172a;font-weight:900;min-height:42px;padding:0 16px;cursor:pointer}.pxth-quote-result{border:1px solid #bbf7d0;background:#f0fdf4;color:#166534;border-radius:12px;padding:12px;font-weight:900}.pxth-payment-box{border:1px dashed #cbd5e1;border-radius:14px;padding:12px;background:#f8fafc}.pxth-payment-info{font-size:13px;color:#334155;line-height:1.7}.pxth-payment-info b{color:#0f172a}.pxth-payment-qr{max-width:140px;border:1px solid #e5e7eb;border-radius:12px;background:#fff;margin-top:8px}.pxth-quote-loading{padding:14px;border:1px dashed #cbd5e1;border-radius:12px;background:#f8fafc;color:#64748b;font-weight:900}
@media(max-width:640px){.pxth-quote-grid2{grid-template-columns:1fr}.pxth-quote-item{grid-template-columns:1fr 70px 32px}.pxth-quote-box{width:calc(100vw - 18px);max-height:calc(100dvh - 18px)}}

.pxth-payment-page-link{display:inline-flex;align-items:center;justify-content:center;text-decoration:none}


/* PXTH Stage85: Quote items scroll area */
.pxth-quote-items{
  max-height:min(320px,36dvh)!important;
  overflow-y:auto!important;
  overflow-x:hidden!important;
  overscroll-behavior:contain!important;
  scrollbar-gutter:stable!important;
}
.pxth-quote-items::-webkit-scrollbar{
  width:8px!important;
}
.pxth-quote-items::-webkit-scrollbar-thumb{
  background:#cbd5e1!important;
  border-radius:999px!important;
}
.pxth-quote-items::-webkit-scrollbar-track{
  background:#f8fafc!important;
}
.pxth-quote-item{
  min-height:56px!important;
}
.pxth-quote-item > div{
  min-width:0!important;
}
.pxth-quote-item b,
.pxth-quote-item small{
  overflow-wrap:anywhere!important;
}
@media(max-height:720px){
  .pxth-quote-items{
    max-height:min(240px,30dvh)!important;
  }
}
@media(max-width:640px){
  .pxth-quote-items{
    max-height:min(260px,34dvh)!important;
  }
}
