/* =========================================================
   NgroupTH theme — วางทับ Sandbox theme (clients/css/style.css)
   ========================================================= */
:root {
    --ng-navy: #14215a;
    --ng-navy-900: #0b1440;
    --ng-navy-700: #1f2f78;
    --ng-orange: #f7941d;
    --ng-orange-600: #e07c06;
    --ng-orange-700: #a85500;
    --ng-orange-50: #fff4e6;
    --ng-gold: #c9a64b;
    --ng-ink: #1a2142;
    --ng-muted: #5a6280;
    --ng-line: #e5e8f1;
    --ng-bg: #f5f7fc;
    --ng-white: #fff;
    --ng-success: #17a467;
    --ng-radius: 18px;
    --ng-radius-sm: 12px;
    --ng-shadow: 0 10px 30px rgba(20, 33, 90, .08);
    --ng-shadow-lg: 0 24px 60px rgba(11, 20, 64, .16);
    --ng-header-h: 72px;
    --ng-mobile-bar-h: 0px;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--ng-header-h) + 12px);
}

body.ng {
    font-family: 'Anuphan', system-ui, -apple-system, 'Segoe UI', sans-serif;
    font-size: 1.0625rem;
    line-height: 1.75;
    color: var(--ng-ink);
    background: var(--ng-white);
    -webkit-font-smoothing: antialiased;
    padding-bottom: var(--ng-mobile-bar-h);
}

body.ng h1, body.ng h2, body.ng h3, body.ng h4, body.ng h5, body.ng h6 {
    font-family: inherit;
    color: var(--ng-navy);
    letter-spacing: 0;
    line-height: 1.35;
    font-weight: 700;
}

body.ng p { color: var(--ng-muted); }
body.ng a { color: var(--ng-navy-700); }
body.ng a:hover { color: var(--ng-orange-600); }
body.ng img { max-width: 100%; height: auto; }
body.ng .content-wrapper { overflow-x: clip; }

/* ---------- ปุ่ม ---------- */
.ng-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    min-height: 48px;
    padding: .7rem 1.4rem;
    border-radius: 999px;
    border: 2px solid transparent;
    font-weight: 600;
    font-size: 1rem;
    line-height: 1.2;
    text-decoration: none;
    transition: transform .15s ease, box-shadow .15s ease, background-color .15s ease, color .15s ease;
    white-space: nowrap;
}
.ng-btn i { font-size: 1.25rem; line-height: 1; }
.ng-btn:hover { transform: translateY(-1px); }
.ng-btn:focus-visible { outline: 3px solid rgba(247, 148, 29, .45); outline-offset: 2px; }
body.ng .ng-btn-primary { background: var(--ng-orange); color: #1b1300; box-shadow: 0 8px 20px rgba(247, 148, 29, .35); }
body.ng .ng-btn-primary:hover { background: var(--ng-orange-600); color: #1b1300; }
body.ng .ng-btn-navy { background: var(--ng-navy); color: #fff; }
body.ng .ng-btn-navy:hover { background: var(--ng-navy-700); color: #fff; }
body.ng .ng-btn-line { background: #006e2e; color: #fff; }
body.ng .ng-btn-line:hover { background: #005a25; color: #fff; }
body.ng .ng-btn-ghost { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .35); color: #fff; }
body.ng .ng-btn-ghost:hover { background: rgba(255, 255, 255, .16); color: #fff; }
body.ng .ng-btn-outline { background: #fff; border-color: var(--ng-line); color: var(--ng-navy); }
body.ng .ng-btn-outline:hover { border-color: var(--ng-navy); color: var(--ng-navy); }
.ng-btn-block { width: 100%; }

/* ---------- Header / Navbar ---------- */
.ng-header {
    position: sticky;
    top: 0;
    z-index: 1030;
    /* ห้ามใช้ backdrop-filter/transform ที่นี่: จะทำให้เมนู offcanvas (position: fixed) ติดอยู่ใน header */
    background: #fff;
    border-bottom: 1px solid transparent;
    transition: box-shadow .2s ease, border-color .2s ease;
}
.ng-header.is-scrolled { box-shadow: 0 6px 24px rgba(20, 33, 90, .08); border-color: var(--ng-line); }
.ng-header .navbar { min-height: var(--ng-header-h); padding-top: .5rem; padding-bottom: .5rem; }
.ng-brand { display: inline-flex; align-items: center; gap: .65rem; text-decoration: none; }
.ng-brand img { width: 48px; height: 48px; object-fit: contain; }
.ng-brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.ng-brand-text strong { color: var(--ng-navy); font-size: 1.15rem; font-weight: 700; }
.ng-brand-text small { color: var(--ng-muted); font-size: .78rem; }

body.ng .ng-header .navbar-nav .nav-link {
    color: var(--ng-ink);
    font-size: 1rem;
    font-weight: 500;
    padding: .5rem .85rem;
    border-radius: 999px;
    letter-spacing: 0;
}
body.ng .ng-header .navbar-nav .nav-link:hover,
body.ng .ng-header .navbar-nav .nav-link.active { color: var(--ng-navy); background: var(--ng-bg); }
body.ng .ng-header .dropdown-menu {
    border: 1px solid var(--ng-line);
    border-radius: var(--ng-radius-sm);
    box-shadow: var(--ng-shadow-lg);
    padding: .5rem;
    min-width: 260px;
    width: max-content;
    max-width: calc(100vw - 2rem);
}
body.ng .ng-header .dropdown-item {
    border-radius: 8px;
    padding: .55rem .8rem;
    font-size: .98rem;
    color: var(--ng-ink);
    white-space: nowrap;
}
body.ng .ng-header .dropdown-item:hover { background: var(--ng-orange-50); color: var(--ng-navy); }
.ng-nav-actions { display: flex; align-items: center; gap: .5rem; }
.ng-nav-actions .ng-btn { min-height: 42px; padding: .5rem 1.1rem; font-size: .95rem; }

.ng-hamburger {
    width: 44px; height: 44px;
    border: 1px solid var(--ng-line);
    border-radius: 12px;
    background: #fff;
    display: inline-flex; align-items: center; justify-content: center;
    color: var(--ng-navy);
    font-size: 1.5rem;
}

@media (max-width: 991.98px) {
    :root { --ng-header-h: 64px; }
    .ng-brand img { width: 40px; height: 40px; }
    body.ng .ng-header .navbar-collapse.offcanvas-nav {
        background: var(--ng-navy-900);
        width: min(86vw, 340px);
    }
    body.ng .ng-header .offcanvas-nav .nav-link {
        color: #fff;
        font-size: 1.1rem;
        padding: .8rem 0;
        border-radius: 0;
        border-bottom: 1px solid rgba(255, 255, 255, .08);
    }
    body.ng .ng-header .offcanvas-nav .nav-link:hover { background: transparent; color: var(--ng-orange); }
    body.ng .ng-header .offcanvas-nav .dropdown-menu {
        background: transparent; border: 0; box-shadow: none; padding: 0 0 .5rem .75rem; min-width: 0;
    }
    body.ng .ng-header .offcanvas-nav .dropdown-item { color: rgba(255, 255, 255, .8); padding: .5rem 0; white-space: normal; }
    body.ng .ng-header .offcanvas-nav .dropdown-item:hover { background: transparent; color: var(--ng-orange); }
    .ng-offcanvas-contact { color: rgba(255, 255, 255, .75); font-size: .95rem; }
    .ng-offcanvas-contact a { color: #fff !important; }
}

/* ---------- ส่วนประกอบทั่วไป ---------- */
.ng-section { padding: 88px 0; position: relative; }
.ng-section-sm { padding: 56px 0; }
.ng-bg-soft { background: var(--ng-bg); }
.ng-bg-navy { background: var(--ng-navy); }
.ng-eyebrow {
    display: inline-flex; align-items: center; gap: .4rem;
    font-size: .9rem; font-weight: 600;
    color: var(--ng-orange-700);
    background: var(--ng-orange-50);
    padding: .3rem .85rem;
    border-radius: 999px;
    margin-bottom: 1rem;
}
.ng-section-head { max-width: 760px; margin: 0 auto 3rem; text-align: center; }
body.ng .ng-title { font-size: clamp(1.65rem, 1.2rem + 1.8vw, 2.5rem); margin-bottom: .75rem; }
body.ng .ng-lead { font-size: clamp(1.02rem, .98rem + .3vw, 1.15rem); color: var(--ng-muted); margin-bottom: 0; }
.ng-highlight { color: var(--ng-orange-600); }

.ng-card {
    background: #fff;
    border: 1px solid var(--ng-line);
    border-radius: var(--ng-radius);
    box-shadow: var(--ng-shadow);
}

.ng-check-list { list-style: none; padding: 0; margin: 0; display: grid; gap: .7rem; }
.ng-check-list li { position: relative; padding-left: 2rem; color: var(--ng-ink); line-height: 1.6; }
.ng-check-list li::before {
    content: '';
    position: absolute; left: 0; top: .2rem;
    width: 1.35rem; height: 1.35rem; border-radius: 50%;
    background: var(--ng-success) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5L20 7'/%3E%3C/svg%3E") center / 62% no-repeat;
}
.ng-on-dark .ng-check-list li { color: #fff; }

/* ---------- Hero ---------- */
.ng-hero {
    position: relative;
    color: #fff;
    background:
        radial-gradient(1200px 500px at 85% -10%, rgba(247, 148, 29, .22), transparent 60%),
        radial-gradient(900px 600px at -10% 110%, rgba(31, 47, 120, .9), transparent 60%),
        linear-gradient(160deg, var(--ng-navy-900) 0%, var(--ng-navy) 55%, var(--ng-navy-700) 100%);
    padding: 72px 0 96px;
    overflow: hidden;
}
.ng-hero::after {
    content: '';
    position: absolute; inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, .07) 1px, transparent 1px);
    background-size: 22px 22px;
    pointer-events: none;
}
.ng-hero .container { position: relative; z-index: 1; }
body.ng .ng-hero h1 {
    color: #fff;
    font-size: clamp(2rem, 1.4rem + 2.2vw, 3.1rem);
    line-height: 1.25;
    margin-bottom: 1.1rem;
}
body.ng .ng-hero h1 .ng-highlight { color: var(--ng-orange); }
body.ng .ng-hero p.ng-lead { color: rgba(255, 255, 255, .82); max-width: 560px; }
.ng-hero-badge {
    display: inline-flex; align-items: center; gap: .5rem;
    background: rgba(255, 255, 255, .1);
    border: 1px solid rgba(255, 255, 255, .18);
    color: #fff;
    border-radius: 999px;
    padding: .35rem .9rem .35rem .4rem;
    font-size: .92rem;
    margin-bottom: 1.25rem;
}
.ng-hero-badge span { background: var(--ng-orange); color: #1b1300; border-radius: 999px; padding: .1rem .6rem; font-weight: 700; font-size: .82rem; }
.ng-hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2rem; }
.ng-hero-chips { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem 1.25rem; margin-top: 2rem; padding: 0; list-style: none; }
.ng-hero-chips li { display: flex; align-items: center; gap: .5rem; color: rgba(255, 255, 255, .9); font-size: .98rem; }
.ng-hero-chips i { color: var(--ng-orange); font-size: 1.25rem; }

.ng-hero-media { position: relative; }
.ng-hero-media img.ng-hero-img {
    width: 100%;
    aspect-ratio: 4 / 3.4;
    object-fit: cover;
    border-radius: 28px;
    box-shadow: var(--ng-shadow-lg);
    border: 6px solid rgba(255, 255, 255, .08);
}
.ng-float-card {
    position: absolute;
    background: #fff;
    color: var(--ng-ink);
    border-radius: 16px;
    box-shadow: var(--ng-shadow-lg);
    padding: .85rem 1.1rem;
    display: flex; align-items: center; gap: .75rem;
}
.ng-float-card .ng-float-icon {
    width: 44px; height: 44px; border-radius: 12px;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--ng-orange-50); color: var(--ng-orange-600); font-size: 1.4rem; flex: none;
}
.ng-float-card strong { display: block; font-size: 1.15rem; color: var(--ng-navy); line-height: 1.2; }
.ng-float-card small { color: var(--ng-muted); font-size: .85rem; }
.ng-float-card.is-top { top: 8%; left: -28px; }
.ng-float-card.is-bottom { bottom: 8%; right: -20px; }

.ng-hero-wave { position: absolute; left: 0; right: 0; bottom: -1px; height: 48px; color: #fff; z-index: 1; }
.ng-hero-wave svg { width: 100%; height: 100%; display: block; }

/* ---------- Benefits ---------- */
.ng-benefits { margin-top: -64px; position: relative; z-index: 2; }
.ng-benefit {
    height: 100%;
    padding: 1.6rem 1.4rem;
    display: flex; flex-direction: column; gap: .65rem;
    transition: transform .2s ease, box-shadow .2s ease;
}
.ng-benefit:hover { transform: translateY(-4px); box-shadow: var(--ng-shadow-lg); }
.ng-icon {
    width: 56px; height: 56px; border-radius: 16px;
    display: inline-flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, var(--ng-navy), var(--ng-navy-700));
    color: #fff; font-size: 1.6rem; flex: none;
}
.ng-icon.is-orange { background: linear-gradient(135deg, var(--ng-orange), var(--ng-orange-600)); color: #1b1300; }
body.ng .ng-benefit h3 { font-size: 1.15rem; margin: 0; }
body.ng .ng-benefit p { font-size: .97rem; margin: 0; line-height: 1.6; }

/* ---------- Problems / About ---------- */
.ng-media-frame { position: relative; }
.ng-media-frame img { border-radius: var(--ng-radius); box-shadow: var(--ng-shadow-lg); width: 100%; }
.ng-media-frame::before {
    content: '';
    position: absolute; inset: 24px -16px -16px 24px;
    border-radius: var(--ng-radius);
    background: var(--ng-orange-50);
    z-index: -1;
}
.ng-note {
    display: flex; gap: .85rem; align-items: flex-start;
    background: var(--ng-orange-50);
    border: 1px solid #ffd9a8;
    color: #7a4300;
    border-radius: var(--ng-radius-sm);
    padding: 1rem 1.15rem;
    font-weight: 500;
    line-height: 1.6;
}
.ng-note i { font-size: 1.4rem; color: var(--ng-orange-600); line-height: 1.2; }

/* ---------- Promo slider ---------- */
.ng-promo .swiper-slide img { border-radius: var(--ng-radius); width: 100%; }

/* ---------- Business type cards ---------- */
.ng-biz-card {
    display: flex; flex-direction: column;
    height: 100%;
    overflow: hidden;
    text-decoration: none;
    transition: transform .2s ease, box-shadow .2s ease;
}
.ng-biz-card:hover { transform: translateY(-4px); box-shadow: var(--ng-shadow-lg); }
.ng-biz-card figure { margin: 0; aspect-ratio: 4 / 3; overflow: hidden; background: var(--ng-bg); }
.ng-biz-card figure img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.ng-biz-card:hover figure img { transform: scale(1.05); }
.ng-biz-body { padding: 1.25rem 1.35rem 1.4rem; display: flex; flex-direction: column; gap: .4rem; flex: 1; }
body.ng .ng-biz-body h3 { font-size: 1.15rem; margin: 0; }
body.ng .ng-biz-body p { font-size: .95rem; margin: 0; line-height: 1.6; }
.ng-biz-more { margin-top: auto; padding-top: .6rem; font-weight: 600; color: var(--ng-orange-700); display: inline-flex; align-items: center; gap: .3rem; }

/* ---------- Steps ---------- */
.ng-steps { counter-reset: step; position: relative; }
.ng-step { position: relative; text-align: center; padding: 0 .5rem; }
.ng-step-num {
    position: relative; z-index: 1;
    width: 88px; height: 88px; margin: 0 auto 1.1rem;
    border-radius: 50%;
    background: #fff;
    border: 2px dashed rgba(247, 148, 29, .55);
    display: flex; align-items: center; justify-content: center;
}
.ng-step-num .ng-icon { width: 64px; height: 64px; border-radius: 50%; font-size: 1.8rem; }
.ng-step-num b {
    position: absolute; top: -4px; right: -4px;
    width: 30px; height: 30px; border-radius: 50%;
    background: var(--ng-orange); color: #1b1300;
    font-size: .9rem; display: flex; align-items: center; justify-content: center;
}
body.ng .ng-step h3 { font-size: 1.12rem; margin-bottom: .35rem; }
body.ng .ng-step p { font-size: .96rem; margin: 0; line-height: 1.6; }
@media (min-width: 992px) {
    .ng-steps::before {
        content: '';
        position: absolute; top: 44px; left: 12.5%; right: 12.5%;
        border-top: 2px dashed var(--ng-line);
    }
}

/* ---------- Form ---------- */
.ng-form-card { padding: 2rem; }
.ng-form-card .form-label { font-weight: 600; color: var(--ng-ink); font-size: .98rem; margin-bottom: .4rem; }
.ng-form-card .form-label .req { color: #e03131; }
body.ng .ng-form-card .form-control,
body.ng .ng-form-card .form-select {
    min-height: 50px;
    border-radius: 12px;
    border: 1.5px solid var(--ng-line);
    font-size: 1rem;
    color: var(--ng-ink);
    background-color: #fbfcfe;
    box-shadow: none;
}
body.ng .ng-form-card .form-control:focus,
body.ng .ng-form-card .form-select:focus { border-color: var(--ng-orange); background: #fff; box-shadow: 0 0 0 4px rgba(247, 148, 29, .15); }
.ng-form-card .form-text { color: var(--ng-muted); font-size: .88rem; }
.ng-upload {
    display: block;
    border: 2px dashed #cdd3e4;
    border-radius: 14px;
    padding: 1.4rem 1rem;
    text-align: center;
    background: #fbfcfe;
    cursor: pointer;
    transition: border-color .15s ease, background .15s ease;
}
.ng-upload:hover, .ng-upload.is-filled { border-color: var(--ng-orange); background: var(--ng-orange-50); }
.ng-upload i { font-size: 2rem; color: var(--ng-orange-600); }
.ng-upload strong { display: block; color: var(--ng-navy); margin-top: .25rem; }
.ng-upload small { color: var(--ng-muted); }
.ng-upload input[type=file] { position: absolute; width: 1px; height: 1px; opacity: 0; }
.ng-upload-files { font-size: .9rem; color: var(--ng-success); margin-top: .5rem; word-break: break-word; }
.ng-recaptcha { overflow-x: auto; }

.ng-aside-card { padding: 1.5rem; }
body.ng .ng-aside-card h3 { font-size: 1.12rem; display: flex; align-items: center; gap: .5rem; margin-bottom: 1rem; }
body.ng .ng-aside-card h3 i { color: var(--ng-orange-600); font-size: 1.35rem; }
.ng-line-card {
    background: linear-gradient(135deg, var(--ng-navy), var(--ng-navy-700));
    color: #fff;
    border: 0;
    display: flex; gap: 1rem; align-items: center;
}
.ng-line-card img { width: 104px; height: 104px; border-radius: 12px; background: #fff; padding: 6px; flex: none; object-fit: contain; }
body.ng .ng-line-card h3 { color: #fff; }
body.ng .ng-line-card p { color: rgba(255, 255, 255, .8); }

/* ---------- FAQ ---------- */
.ng-faq { display: grid; gap: .85rem; max-width: 860px; margin: 0 auto; }
.ng-faq details {
    background: #fff;
    border: 1px solid var(--ng-line);
    border-radius: 14px;
    transition: box-shadow .2s ease, border-color .2s ease;
}
.ng-faq details[open] { box-shadow: var(--ng-shadow); border-color: #ffd9a8; }
.ng-faq summary {
    list-style: none;
    cursor: pointer;
    padding: 1.1rem 3.2rem 1.1rem 1.3rem;
    font-weight: 600;
    color: var(--ng-navy);
    position: relative;
    font-size: 1.04rem;
    line-height: 1.5;
}
.ng-faq summary::-webkit-details-marker { display: none; }
.ng-faq summary::after {
    content: '+';
    position: absolute; right: 1.1rem; top: 50%; transform: translateY(-50%);
    width: 30px; height: 30px; border-radius: 50%;
    background: var(--ng-bg); color: var(--ng-navy);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.25rem; font-weight: 500;
    transition: transform .2s ease, background .2s ease;
}
.ng-faq details[open] summary::after { content: '−'; background: var(--ng-orange); color: #1b1300; }
.ng-faq details p { padding: 0 1.3rem 1.2rem; margin: 0; line-height: 1.7; }

/* ---------- CTA band ---------- */
.ng-cta {
    background:
        radial-gradient(600px 300px at 90% 0%, rgba(247, 148, 29, .3), transparent 60%),
        linear-gradient(135deg, var(--ng-navy-900), var(--ng-navy-700));
    border-radius: 28px;
    padding: 3rem;
    color: #fff;
}
body.ng .ng-cta h2 { color: #fff; font-size: clamp(1.5rem, 1.1rem + 1.6vw, 2.2rem); margin-bottom: .5rem; }
body.ng .ng-cta p { color: rgba(255, 255, 255, .8); margin: 0; }

/* ---------- Page hero (หน้าย่อย) ---------- */
.ng-page-hero {
    background: linear-gradient(160deg, var(--ng-navy-900), var(--ng-navy) 70%);
    color: #fff;
    padding: 56px 0 64px;
    position: relative;
    overflow: hidden;
}
.ng-page-hero::after {
    content: '';
    position: absolute; inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, .07) 1px, transparent 1px);
    background-size: 22px 22px;
}
.ng-page-hero .container { position: relative; z-index: 1; }
body.ng .ng-page-hero h1 { color: #fff; font-size: clamp(1.8rem, 1.3rem + 2vw, 2.75rem); margin-bottom: .6rem; }
body.ng .ng-page-hero p { color: rgba(255, 255, 255, .82); margin: 0; max-width: 720px; }
.ng-breadcrumb { display: flex; flex-wrap: wrap; gap: .35rem; list-style: none; padding: 0; margin: 0 0 1rem; font-size: .92rem; }
.ng-breadcrumb li { color: rgba(255, 255, 255, .6); }
.ng-breadcrumb li + li::before { content: '›'; margin-right: .35rem; }
body.ng .ng-breadcrumb a { color: rgba(255, 255, 255, .85); text-decoration: none; }
body.ng .ng-breadcrumb a:hover { color: var(--ng-orange); }

/* เนื้อหาจาก editor */
.ng-prose { font-size: 1.06rem; line-height: 1.85; color: var(--ng-ink); }
.ng-prose p, .ng-prose li { color: var(--ng-ink); }
.ng-prose h2, .ng-prose h3, .ng-prose h4 { margin: 1.75rem 0 .75rem; }
.ng-prose img { border-radius: var(--ng-radius-sm); margin: 1rem 0; height: auto !important; }
.ng-prose ul, .ng-prose ol { padding-left: 1.3rem; }
.ng-prose table { width: 100%; display: block; overflow-x: auto; }
.ng-prose iframe { max-width: 100%; }

.ng-sticky { position: sticky; top: calc(var(--ng-header-h) + 20px); }
.ng-side-links { list-style: none; padding: 0; margin: 0; }
.ng-side-links li + li { border-top: 1px solid var(--ng-line); }
body.ng .ng-side-links a {
    display: flex; justify-content: space-between; align-items: center; gap: .5rem;
    padding: .7rem 0; color: var(--ng-ink); text-decoration: none; font-size: .98rem;
}
body.ng .ng-side-links a:hover, body.ng .ng-side-links a.active { color: var(--ng-orange-600); }

/* ---------- Footer ---------- */
.ng-footer { background: var(--ng-navy-900); color: rgba(255, 255, 255, .75); padding: 72px 0 0; font-size: .98rem; }
body.ng .ng-footer h2 { color: #fff; font-size: 1.05rem; margin-bottom: 1rem; }
body.ng .ng-footer p, body.ng .ng-footer address { color: rgba(255, 255, 255, .72); }
body.ng .ng-footer a { color: rgba(255, 255, 255, .85); text-decoration: none; }
body.ng .ng-footer a:hover { color: var(--ng-orange); }
.ng-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: .55rem; }
.ng-footer .ng-qr { width: 120px; height: 120px; object-fit: contain; background: #fff; border-radius: 12px; padding: 6px; }
.ng-social { display: flex; gap: .5rem; margin-top: 1rem; }
.ng-social a {
    width: 40px; height: 40px; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    background: rgba(255, 255, 255, .08); font-size: 1.15rem;
}
.ng-footer-bottom { border-top: 1px solid rgba(255, 255, 255, .1); margin-top: 48px; padding: 20px 0; font-size: .9rem; }

/* ---------- ปุ่มลอย / แถบมือถือ ---------- */
.ng-float-line {
    position: fixed; right: 24px; bottom: 96px; z-index: 1020;
    width: 56px; height: 56px; border-radius: 50%;
    box-shadow: 0 8px 24px rgba(6, 199, 85, .4);
    transition: transform .15s ease;
}
.ng-float-line:hover { transform: scale(1.06); }
.ng-float-line img { width: 56px; height: 56px; border-radius: 50%; }

.ng-mobile-bar {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 1040;
    display: none;
    grid-auto-flow: column;
    grid-auto-columns: minmax(0, 1fr);
    gap: .5rem;
    padding: .6rem .75rem calc(.6rem + env(safe-area-inset-bottom));
    background: rgba(255, 255, 255, .97);
    border-top: 1px solid var(--ng-line);
    box-shadow: 0 -8px 24px rgba(20, 33, 90, .08);
}
.ng-mobile-bar .ng-btn { min-height: 46px; padding: .5rem .6rem; font-size: .95rem; }

@media (max-width: 767.98px) {
    :root { --ng-mobile-bar-h: 70px; }
    .ng-mobile-bar { display: grid; }
    .ng-float-line { display: none; }
    body.ng .progress-wrap { bottom: calc(var(--ng-mobile-bar-h) + 14px) !important; right: 14px !important; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1199.98px) {
    .ng-float-card.is-top { left: -8px; }
    .ng-float-card.is-bottom { right: -8px; }
}
@media (max-width: 991.98px) {
    .ng-section { padding: 64px 0; }
    .ng-hero { padding: 40px 0 88px; }
    .ng-hero-media { margin-top: 2.5rem; }
    .ng-section-head { margin-bottom: 2.25rem; }
    .ng-step { display: grid; grid-template-columns: 72px 1fr; gap: 1rem; text-align: left; align-items: start; padding: 0; }
    .ng-step-num { width: 72px; height: 72px; margin: 0; }
    .ng-step-num .ng-icon { width: 52px; height: 52px; font-size: 1.5rem; }
    .ng-steps > [class*=col] { position: relative; }
    .ng-steps > [class*=col]:not(:last-child)::after {
        content: '';
        position: absolute; left: calc(36px + var(--bs-gutter-x) * .5); top: 80px; bottom: -14px;
        border-left: 2px dashed var(--ng-line);
    }
}
@media (max-width: 767.98px) {
    body.ng { font-size: 1rem; }
    .ng-section { padding: 52px 0; }
    .ng-section-sm { padding: 40px 0; }
    .ng-hero-actions .ng-btn { flex: 1 1 100%; }
    .ng-hero-chips { grid-template-columns: 1fr 1fr; gap: .5rem .75rem; }
    .ng-hero-chips li { font-size: .9rem; }
    .ng-float-card { padding: .6rem .8rem; }
    .ng-float-card .ng-float-icon { width: 36px; height: 36px; font-size: 1.15rem; }
    .ng-float-card strong { font-size: 1rem; }
    .ng-float-card.is-top { top: auto; bottom: -22px; left: 12px; }
    .ng-float-card.is-bottom { display: none; }
    .ng-benefits { margin-top: -56px; }
    .ng-benefit { padding: 1.1rem 1rem; }
    .ng-benefit .ng-icon { width: 46px; height: 46px; font-size: 1.35rem; border-radius: 12px; }
    body.ng .ng-benefit h3 { font-size: 1.02rem; }
    body.ng .ng-benefit p { font-size: .9rem; }
    .ng-form-card { padding: 1.25rem; }
    .ng-aside-card { padding: 1.25rem; }
    .ng-cta { padding: 2rem 1.4rem; border-radius: 22px; text-align: center; }
    .ng-cta .ng-btn { width: 100%; }
    .ng-media-frame::before { inset: 14px -8px -8px 14px; }
    .ng-footer { padding-top: 52px; }
    .ng-line-card img { width: 88px; height: 88px; }
}
@media (max-width: 399.98px) {
    .ng-hero-chips { grid-template-columns: 1fr; }
    .ng-brand-text small { display: none; }
}
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .ng-btn, .ng-benefit, .ng-biz-card, .ng-biz-card figure img { transition: none; }
}

/* ---------- ปรับช่วงจอ 992–1199px (แท็บเล็ตแนวนอน / โน้ตบุ๊กเล็ก) ---------- */
body.ng .ng-title, body.ng .ng-page-hero h1 { text-wrap: balance; }
@media (min-width: 992px) and (max-width: 1199.98px) {
    .ng-brand-text { display: none; }
    body.ng .ng-header .navbar-nav .nav-link { padding: .5rem .6rem; font-size: .95rem; }
    body.ng .ng-hero h1 { font-size: 2.5rem; }
}
/* label ที่ตัดบรรทัดไม่ให้ช่องกรอกเหลื่อมกัน */
.ng-form-card .row > .col-md-6 { display: flex; flex-direction: column; justify-content: flex-end; }
@media (max-width: 575.98px) {
    .ng-benefits .ng-benefit { flex-direction: row; align-items: flex-start; gap: .9rem; }
    .ng-benefits .ng-benefit h3 { margin-bottom: .15rem; }
}
.ng-benefit > div > h3 { margin-bottom: .35rem !important; }
@media (max-width: 575.98px) {
    .ng-biz-card { flex-direction: row; }
    .ng-biz-card figure { width: 38%; aspect-ratio: auto; flex: none; min-height: 132px; }
    .ng-biz-body { padding: .9rem 1rem; gap: .25rem; }
    body.ng .ng-biz-body h3 { font-size: 1.02rem; }
    body.ng .ng-biz-body p { font-size: .88rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
    .ng-biz-more { padding-top: .3rem; font-size: .9rem; }
}
@media (max-width: 575.98px) {
    .ng-biz-card figure { position: relative; }
    .ng-biz-card figure img { position: absolute; inset: 0; }
}
@media (max-width: 767.98px) {
    .ng-footer-bottom { padding-bottom: calc(20px + var(--ng-mobile-bar-h)); }
}
/* header เป็น sticky อยู่แล้ว ซ่อน navbar ที่ theme โคลนไว้ตอนเลื่อน */
body.ng .navbar-clone { display: none !important; }
body.ng .ng-footer-bottom span { color: rgba(255, 255, 255, .7); }
@media (max-width: 991.98px) {
    body.ng .ng-header .offcanvas-nav .nav-link.active { background: transparent; color: var(--ng-orange); }
    body.ng .ng-header .offcanvas-footer { display: block; }
    body.ng:has(.offcanvas-nav.show) .ng-mobile-bar { display: none; }
}
@media (max-width: 575.98px) {
    .ng-page-hero .ng-btn { flex: 1 1 100%; }
}
body.ng .ng-highlight span { color: inherit; }

/* ---------- ภาพพื้นหลังจางใน hero (กำหนดรูปผ่าน --ng-bg-img) ---------- */
.ng-hero::before, .ng-page-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: var(--ng-bg-img, none);
    background-size: cover;
    background-position: center;
    pointer-events: none;
    /* ค่อยๆ จางไปทางซ้ายที่เป็นตัวหนังสือ */
    -webkit-mask-image: linear-gradient(90deg, rgba(0, 0, 0, .35) 0%, #000 65%);
    mask-image: linear-gradient(90deg, rgba(0, 0, 0, .35) 0%, #000 65%);
}
.ng-hero::before { opacity: .3; filter: saturate(.85); }
.ng-page-hero::before { opacity: .38; filter: saturate(.8); background-position: center 40%; }
@media (max-width: 767.98px) {
    /* มือถือ: ข้อความเต็มกว้าง ให้ภาพจางทั่วทั้งพื้นที่ */
    .ng-hero::before, .ng-page-hero::before { -webkit-mask-image: none; mask-image: none; opacity: .22; }
}

/* ลิงก์ในเนื้อความต้องแยกจากข้อความได้โดยไม่พึ่งสีอย่างเดียว */
body.ng p a:not([class]), body.ng .ng-prose a:not([class]) { text-decoration: underline; text-underline-offset: 2px; }

/* จุดเลื่อนสไลด์: เว้นระยะให้แตะง่ายบนมือถือ (อย่างน้อย 24px ต่อจุด) */
body.ng .swiper-pagination-bullet { margin: 0 9px !important; }
