
    /* ==========================================
       🛍️ แอปบริการ (store.html) — ธีมเดียวกับหน้าเข้าสู่ระบบ/หน้าติดตั้งเดิม: พื้นดำ ตัวอักษรขาว ปุ่มเหลี่ยมสีขาว ฟอนต์ของเครื่อง
       • hQ (แอปหลัก) อยู่ในรายการเสมอ ไม่ต้องอัปโหลด — ติดตั้ง "หน้าเว็บ" ลงหน้าจอหลักเท่านั้น (ไม่มีไฟล์ APK):
         iPhone/iPad = โปรไฟล์ติดตั้ง (/install/ios) · Android/คอม = ติดตั้งผ่านเบราว์เซอร์ (beforeinstallprompt) · ติดตั้งแล้ว/เปิดเป็นแอปอยู่ = "ติดตั้งแล้ว"
       • แอปอื่นมาจากแผงแอดมิน (utils/store.py) — เลือกไฟล์ตามระบบของเครื่องเอง · ไม่มีของระบบนี้ = "ไม่รองรับอุปกรณ์นี้"
    ========================================== */
    #view-store, #st-detail, .st-light {
        --s-ink: #f5f5f5; --s-sub: #8e8e8e; --s-dim: #555; --s-line: #2e2e2e; --s-row: #161616;
        /* ฟอนต์ของเครื่องล้วน (ไม่ใช้ Noto Sans Thai ที่ทั้งเว็บโหลดไว้) — ภาษาไทยใช้ฟอนต์ไทยของระบบ (iOS/macOS: Thonburi · Android: ฟอนต์ระบบ · Windows: Leelawadee) */
        font-family: -apple-system, BlinkMacSystemFont, system-ui, 'Segoe UI', sans-serif;
    }
    #view-store *, #st-detail *, .st-light * { font-family: inherit; }
    #view-store { background: #000; color: var(--s-ink); min-height: 100vh; min-height: 100dvh; }
    #view-store *, #st-detail * { box-sizing: border-box; }
    .sx-page { max-width: 1120px; margin: 0 auto; min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; padding: 0 0 calc(env(safe-area-inset-bottom) + 96px); }
    .sx-top { position: sticky; top: 0; z-index: 5; background: #000; display: flex; align-items: center; gap: 10px; padding: calc(env(safe-area-inset-top) + 10px) 14px 10px 8px; }
    .sx-ib { flex: none; width: 40px; height: 40px; background: none; border: 0; color: var(--s-ink); display: flex; align-items: center; justify-content: center; cursor: pointer; padding: 0; -webkit-tap-highlight-color: transparent; }
    .sx-ib svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
    .sx-ib:active { opacity: .5; }
    .sx-ib svg.sx-share { width: 23px; height: 23px; stroke-width: 1.4; stroke-linecap: square; stroke-linejoin: miter; }   /* แชร์: เส้นบาง มินิมอล */
    .sx-title { font-size: 17px; font-weight: 600; flex: none; display: flex; align-items: center; gap: 9px; }
    .sx-title img { width: 22px; height: 22px; object-fit: contain; filter: brightness(0) invert(1); -webkit-user-drag: none; user-select: none; }   /* ไอคอนแอปแบบมินิมอล (ขาวล้วน) */
    /* ปุ่มติดตั้งท้ายแถวในรายการ */
    .sx-mini { flex: none; height: 32px; padding: 0 16px; border: 0; border-radius: 0; background: var(--s-ink); color: #000; font: inherit; font-size: 13px; font-weight: 600; cursor: pointer;
        white-space: nowrap; position: relative; -webkit-tap-highlight-color: transparent; transition: transform .1s; }
    .sx-mini:active { transform: scale(.96); }
    .sx-mini.na { background: transparent; color: var(--s-sub); border: 1px solid var(--s-line); font-weight: 500; font-size: 12px; padding: 0 10px; cursor: default; }
    .sx-mini.na:active { transform: none; }
    .sx-mini.busy { color: transparent; pointer-events: none; }
    .sx-mini.busy, .sx-cta.busy { animation: sxPulse 1.1s ease-in-out infinite; }   /* กำลังทำงาน = ปุ่มกระพริบแบบโครงกระดูก (ไม่ใช้วงแหวนหมุน) */
    .sx-search { flex: 1; max-width: 360px; margin-left: auto; position: relative; }
    .sx-search input { width: 100%; height: 38px; border: 1px solid var(--s-line); border-radius: 0; background: #000; color: var(--s-ink); font: inherit; font-size: 14px; padding: 0 12px 0 36px; outline: none; -webkit-appearance: none; }
    .sx-search input:focus { border-color: var(--s-sub); }
    .sx-search svg { position: absolute; left: 11px; top: 50%; width: 16px; height: 16px; transform: translateY(-50%); fill: none; stroke: var(--s-sub); stroke-width: 2; stroke-linecap: round; pointer-events: none; }
    @media (max-width: 559px) { .sx-search { max-width: none; margin-left: 2px; } }
    /* minmax(0, …) = คอลัมน์ไม่ขยายตามข้อความยาว (ชื่อ/คำอธิบายตัดด้วย … แทนดันปุ่มหลุดจอ) */
    .sx-list { display: grid; grid-template-columns: minmax(0, 1fr); padding: 6px 20px 0; column-gap: 40px; flex: 1; align-content: start; }
    @media (min-width: 760px) { .sx-list { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 16px 32px 0; } }
    @media (min-width: 1080px) { .sx-list { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
    .sx-row { display: flex; align-items: center; gap: 14px; padding: 14px 0; cursor: pointer; -webkit-tap-highlight-color: transparent; position: relative; }
    .sx-row::after { content: ''; position: absolute; left: 72px; right: 0; bottom: 0; height: 1px; background: var(--s-row); }   /* เส้นคั่นเริ่มที่ชื่อแอป ไม่ลากใต้ไอคอน */
    .sx-row:active { opacity: .6; }
    .sx-ic { flex: none; width: 58px; height: 58px; border-radius: 22%; object-fit: cover; background: #111; display: block; box-shadow: 0 0 0 1px rgba(255,255,255,0.08); -webkit-user-drag: none; }
    .sx-tx { flex: 1; min-width: 0; }
    .sx-nm { font-size: 15.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .sx-sb { font-size: 13px; color: var(--s-sub); margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .sx-empty { text-align: center; color: var(--s-sub); font-size: 14px; padding: 80px 20px; grid-column: 1 / -1; }
    .sx-brand { text-align: center; font-size: 11px; letter-spacing: .25em; color: var(--s-dim); font-weight: 700; padding: 36px 0 0; }
    .sx-skel { display: flex; align-items: center; gap: 14px; padding: 14px 0; }
    /* 🏷️ หมวดหมู่ · หัวข้อส่วน · การ์ดแนวนอน (อัปเดตล่าสุด) · อันดับยอดนิยม */
    .sx-chips { display: flex; gap: 8px; overflow-x: auto; padding: 4px 20px 2px; scrollbar-width: none; }
    .sx-chips::-webkit-scrollbar { display: none; }
    @media (min-width: 760px) { .sx-chips { padding: 8px 32px 2px; } }
    .sx-chip { flex: none; height: 32px; padding: 0 14px; border: 1px solid var(--s-line); background: transparent; color: var(--s-ink); font: inherit; font-size: 13px; cursor: pointer; -webkit-tap-highlight-color: transparent; }
    .sx-chip.on { background: var(--s-ink); color: #000; border-color: var(--s-ink); font-weight: 600; }
    .sx-body { flex: 1; min-width: 0; }
    .sx-sec { padding-top: 26px; min-width: 0; }
    .sx-h { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 0 20px 12px; font-size: 19px; font-weight: 700; }
    .sx-h small { font-size: 12.5px; color: var(--s-sub); font-weight: 500; }
    @media (min-width: 760px) { .sx-h { padding: 0 32px 14px; font-size: 21px; } }
    .sx-sec .sx-list { padding-top: 0; }
    .sx-rail { display: flex; gap: 14px; overflow-x: auto; padding: 0 20px 4px; scroll-padding-inline: 20px; scroll-snap-type: x proximity; scrollbar-width: none; }
    .sx-rail::-webkit-scrollbar { display: none; }
    @media (min-width: 760px) { .sx-rail { padding: 0 32px 4px; gap: 18px; scroll-padding-inline: 32px; } }
    .sx-card { flex: none; width: min(80vw, 320px); scroll-snap-align: start; cursor: pointer; -webkit-tap-highlight-color: transparent; }
    .sx-card:active { opacity: .7; }
    .sx-cover { height: 176px; background: #111; overflow: hidden; border: 1px solid var(--s-row); position: relative; }
    .sx-cover img { width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; opacity: 0; transition: opacity .3s; }
    .sx-cover.ok img { opacity: 1; }
    .sx-cover.plain { display: flex; align-items: center; justify-content: center; background: #0b0b0b; }
    .sx-cover.plain img { width: 76px; height: 76px; border-radius: 22%; opacity: 1; object-fit: cover; }
    .sx-cmeta { display: flex; align-items: center; gap: 12px; padding-top: 12px; }
    .sx-cmeta .sx-ic { width: 46px; height: 46px; }
    .sx-plat { font-size: 11.5px; color: var(--s-dim); margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: .01em; }
    .sx-no { flex: none; width: 22px; font-size: 17px; font-weight: 700; color: var(--s-sub); text-align: center; font-variant-numeric: tabular-nums; }
    .sx-row.rk::after { left: 108px; }

    /* ปุ่มเหลี่ยมแบบหน้าเข้าสู่ระบบ */
    .sx-cta { height: 46px; width: 100%; border: 0; border-radius: 0; background: var(--s-ink); color: #000; font: inherit; font-size: 15px; font-weight: 600; cursor: pointer;
        display: flex; align-items: center; justify-content: center; position: relative; -webkit-tap-highlight-color: transparent; transition: transform .1s, opacity .2s; }
    .sx-cta:active { transform: scale(.98); }
    .sx-cta.na { background: transparent; color: var(--s-sub); border: 1px solid var(--s-line); cursor: default; font-weight: 500; }
    .sx-cta.na:active { transform: none; }
    .sx-cta.busy { color: transparent; pointer-events: none; }
    @keyframes sxPulse { 0%, 100% { opacity: .85; } 50% { opacity: .3; } }
    @media (prefers-reduced-motion: reduce) { .sx-mini.busy, .sx-cta.busy { animation: none; opacity: .5; } }
    /* ⬇️ กำลังติดตั้ง: ปุ่มกลายเป็นแถบหลอดสีขาวแบบ Google Play (แตะอีกครั้ง = ยกเลิก) */
    .sx-cta.ld, .sx-mini.ld { background: transparent; color: var(--s-ink); border: 1px solid var(--s-line); font-weight: 600; overflow: hidden; cursor: pointer; }
    .sx-cta.ld .pl, .sx-mini.ld .pl { position: relative; z-index: 1; font-variant-numeric: tabular-nums; }
    .sx-cta.ld .pt, .sx-mini.ld .pt { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: var(--s-line); overflow: hidden; }
    .sx-mini.ld .pt { height: 2px; }
    .sx-cta.ld .pt i, .sx-mini.ld .pt i { display: block; height: 100%; width: 0; background: var(--s-ink); transition: width .18s linear; }
    .sx-cta.ind .pt i, .sx-mini.ind .pt i { width: 35% !important; animation: sxInd 1.1s cubic-bezier(.4, 0, .2, 1) infinite; transition: none; }
    @keyframes sxInd { from { transform: translateX(-100%); } to { transform: translateX(290%); } }
    .sx-mini.ld { min-width: 92px; }

    /* หน้าแอป */
    #st-detail { position: fixed; inset: 0; z-index: 1000040; background: #000; color: var(--s-ink); overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; display: none; }
    #st-detail.open { display: block; animation: sxIn .26s ease; }
    #st-detail.closing { animation: sxOut .18s ease forwards; }
    @keyframes sxIn { from { opacity: 0; transform: translateY(8px); } }
    @keyframes sxOut { to { opacity: 0; transform: translateY(8px); } }
    .sd-bar { position: sticky; top: 0; z-index: 3; background: #000; display: flex; align-items: center; justify-content: space-between; padding: calc(env(safe-area-inset-top) + 10px) 8px 10px; transition: box-shadow .2s; }
    .sd-bar.sh { box-shadow: 0 1px 0 var(--s-row); }
    .sd-bar .sd-mini { flex: 1; text-align: center; font-size: 15px; font-weight: 600; opacity: 0; transition: opacity .2s; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding: 0 8px; }
    .sd-bar.sh .sd-mini { opacity: 1; }
    .sd-wrap { max-width: 1120px; margin: 0 auto; padding: 8px 20px calc(env(safe-area-inset-bottom) + 60px); }
    @media (min-width: 760px) { .sd-wrap { padding: 20px 32px 80px; } }
    .sd-top { display: grid; grid-template-columns: 1fr; gap: 26px; }
    @media (min-width: 900px) { .sd-top { grid-template-columns: minmax(0, 1fr) 350px; align-items: center; gap: 56px; } }
    .sd-head { display: flex; align-items: center; gap: 18px; }
    .sd-head .sx-ic { width: 88px; height: 88px; }
    @media (min-width: 760px) { .sd-head .sx-ic { width: 128px; height: 128px; } .sd-head { gap: 26px; } }
    .sd-name { font-size: 24px; font-weight: 700; line-height: 1.2; overflow-wrap: anywhere; }
    @media (min-width: 760px) { .sd-name { font-size: 36px; letter-spacing: -.4px; } }
    .sd-sub { font-size: 14px; color: var(--s-sub); margin-top: 6px; line-height: 1.45; }
    .sd-act { display: flex; flex-direction: column; gap: 12px; }
    .sd-stats { display: flex; justify-content: center; gap: 0; font-size: 12.5px; color: var(--s-sub); }
    .sd-stats span + span::before { content: '·'; margin: 0 8px; color: var(--s-dim); }
    .sd-qr { display: none; justify-content: center; }
    .sd-qr.on { display: flex; }
    .sd-qr > div { padding: 10px; background: var(--s-ink); }
    .sd-qr svg { display: block; width: 132px; height: 132px; }
    .sd-shots { display: flex; gap: 10px; overflow-x: auto; margin: 34px -20px 0; padding: 0 20px 4px; scroll-snap-type: x proximity; scrollbar-width: none; }
    .sd-shots::-webkit-scrollbar { display: none; }
    @media (min-width: 760px) { .sd-shots { margin: 44px 0 0; padding: 0 0 4px; } }
    /* ภาพตัวอย่าง: การ์ดโหลดขนาดเท่าภาพจริง (กระพริบแบบเดียวกับโพสต์) → ภาพจางเข้ามาเมื่อโหลดเสร็จ */
    .sd-shot { flex: none; height: 260px; aspect-ratio: 9 / 16; scroll-snap-align: start; cursor: zoom-in; border: 1px solid var(--s-row); overflow: hidden; position: relative; }
    @media (min-width: 760px) { .sd-shot { height: 400px; } }
    .sd-shot img { width: 100%; height: 100%; object-fit: cover; display: block; opacity: 0; transition: opacity .3s; }
    .sd-shot.ok img { opacity: 1; }
    .sd-info { display: grid; grid-template-columns: 1fr; border-top: 1px solid var(--s-row); }
    @media (min-width: 760px) { .sd-info { grid-template-columns: 1fr 1fr; column-gap: 40px; } }
    .sd-info > div { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--s-row); font-size: 14px; }
    .sd-info span { color: var(--s-sub); flex: none; }
    .sd-info b { font-weight: 500; text-align: right; overflow-wrap: anywhere; }
    .sd-sec { margin-top: 36px; max-width: 760px; }
    .sd-sec h2 { margin: 0 0 10px; font-size: 15px; font-weight: 600; }
    .sd-text { font-size: 14.5px; line-height: 1.65; color: #cfcfcf; white-space: pre-wrap; overflow-wrap: anywhere; }
    .sd-text.clamp { display: -webkit-box; -webkit-line-clamp: 5; -webkit-box-orient: vertical; overflow: hidden; }
    .sd-more { margin-top: 6px; background: none; border: 0; padding: 4px 0; color: var(--s-ink); font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
    .sd-upd { font-size: 12.5px; color: var(--s-sub); margin: -4px 0 8px; }
    .st-light { position: fixed; inset: 0; z-index: 1000045; background: rgba(0,0,0,.96); display: flex; align-items: center; overflow-x: auto; scroll-snap-type: x mandatory; animation: sxFade .2s; }
    @keyframes sxFade { from { opacity: 0; } }
    .st-light img { flex: none; width: 100vw; height: 100vh; height: 100dvh; object-fit: contain; scroll-snap-align: center; padding: calc(env(safe-area-inset-top) + 56px) 16px calc(env(safe-area-inset-bottom) + 24px); box-sizing: border-box; }
    .st-light button { position: fixed; top: calc(env(safe-area-inset-top) + 10px); right: 8px; }
    /* 🔑 แผ่นล่าง: เลือกมือถือ/จอรถ · คีย์ใช้งาน (แอปที่ต้องใช้คีย์) */
    .sx-sheet-bg { position: fixed; inset: 0; z-index: 1000065; background: rgba(0,0,0,.6); display: flex; align-items: flex-end; justify-content: center; opacity: 0; transition: opacity .2s; }
    .sx-sheet-bg.on { opacity: 1; }
    .sx-sheet { width: 100%; max-width: 520px; background: #111; color: var(--s-ink, #f5f5f5); border-top: 1px solid #2e2e2e; padding: 22px 20px calc(env(safe-area-inset-bottom) + 22px);
        transform: translateY(24px); transition: transform .25s cubic-bezier(.22,1,.36,1); font-family: -apple-system, BlinkMacSystemFont, system-ui, 'Segoe UI', sans-serif; }
    .sx-sheet-bg.on .sx-sheet { transform: none; }
    .sx-sheet h3 { margin: 0 0 4px; font-size: 18px; font-weight: 700; }
    .sx-sheet p { margin: 0 0 16px; color: #8e8e8e; font-size: 13.5px; line-height: 1.5; }
    .sx-opt { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 64px; padding: 12px 14px; margin-bottom: 10px; background: #000; border: 1px solid #2e2e2e; color: inherit;
        font: inherit; text-align: left; cursor: pointer; -webkit-tap-highlight-color: transparent; }
    .sx-opt:active { background: #161616; }
    .sx-opt svg { width: 30px; height: 30px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
    .sx-opt b { display: block; font-size: 15px; } .sx-opt small { color: #8e8e8e; font-size: 12.5px; }
    .sx-key { font: 600 22px ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .06em; padding: 16px 12px; text-align: center; border: 1px solid #2e2e2e; background: #000; margin-bottom: 10px; user-select: all; word-break: break-all; }
    .sx-key-st { font-size: 13px; color: #8e8e8e; text-align: center; margin-bottom: 14px; line-height: 1.5; }
    .sx-btn { width: 100%; height: 46px; border: 0; background: var(--s-ink, #f5f5f5); color: #000; font: inherit; font-size: 14.5px; font-weight: 600; cursor: pointer; margin-bottom: 8px; }
    .sx-btn.ghost { background: transparent; color: var(--s-ink, #f5f5f5); border: 1px solid #2e2e2e; }
    .sx-keylink { display: inline-block; margin-top: 10px; background: none; border: 0; color: var(--s-sub, #8e8e8e); font: inherit; font-size: 13px; text-decoration: underline; cursor: pointer; padding: 4px 0; }
    @media (prefers-reduced-motion: reduce) { .sx-sheet-bg, .sx-sheet { transition: none; } }
    /* 🔑 ปุ่มกุญแจ (แอปที่ใช้คีย์ · ดาวน์โหลดแล้ว) ข้างปุ่มติดตั้ง */
    .sx-keyb { flex: none; width: 32px; height: 32px; border: 1px solid var(--s-line); background: transparent; color: var(--s-ink); display: flex; align-items: center; justify-content: center; cursor: pointer; padding: 0; -webkit-tap-highlight-color: transparent; }
    .sx-keyb svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
    .sx-keyb:active { opacity: .6; }
    .sd-ctarow { display: flex; flex-direction: column; gap: 10px; }
    .sx-keyl { height: 46px; border: 1px solid var(--s-line); background: transparent; color: var(--s-ink); font: inherit; font-size: 14.5px; font-weight: 600; display: flex; align-items: center; justify-content: center; gap: 9px; cursor: pointer; -webkit-tap-highlight-color: transparent; }
    .sx-keyl svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
    .sx-keyl:active { opacity: .6; }
    .sd-ctarow .sx-keyb { width: 46px; height: 46px; }
    .sd-ctarow .sx-keyb svg { width: 21px; height: 21px; }
    .sx-acts { flex: none; display: flex; align-items: center; gap: 8px; }
    /* คีย์ระหว่างโหลด */
    .sx-key.ld { color: transparent; }
    .sx-key-sk { display: block; height: 26px; margin: 0 auto; width: 74%; }
    /* 🧪 เบต้าเทสต์ */
    .sd-beta { margin-top: 30px; max-width: 760px; border: 1px solid var(--s-line); padding: 18px; }
    .sd-beta-h { display: flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 600; }
    .sx-tag { flex: none; font-size: 10.5px; font-weight: 700; letter-spacing: .08em; padding: 2px 6px; border: 1px solid var(--s-ink); color: var(--s-ink); line-height: 1.3; }
    .sd-beta-v { font-size: 12.5px; color: var(--s-sub); margin-top: 4px; }
    .sd-beta .sd-text { margin-top: 12px; font-size: 13.5px; }
    .sd-beta .sx-cta { margin-top: 16px; }
    .sd-beta-leave { margin-top: 10px; background: none; border: 0; padding: 4px 0; color: var(--s-sub); font: inherit; font-size: 13px; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
    .sx-nm .sx-tag { margin-left: 6px; vertical-align: 2px; font-size: 9.5px; padding: 1px 5px; }
    /* ⋯ เมนูสามจุด */
    .sx-menu-bg { position: fixed; inset: 0; z-index: 1000060; }
    .sx-menu { position: fixed; min-width: 210px; background: #161616; border: 1px solid #2e2e2e; padding: 6px 0; box-shadow: 0 16px 40px rgba(0,0,0,.6);
        font-family: -apple-system, BlinkMacSystemFont, system-ui, 'Segoe UI', sans-serif; animation: sxPop .14s ease; transform-origin: top right; }
    @keyframes sxPop { from { opacity: 0; transform: scale(.96); } }
    .sx-menu button { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px 16px; background: none; border: 0; color: #f5f5f5; font: inherit; font-size: 14.5px; text-align: left; cursor: pointer; }
    .sx-menu button:active, .sx-menu button:hover { background: #222; }
    .sx-menu button.on::after { content: '✓'; margin-left: auto; color: #8e8e8e; }
    .sx-menu svg { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
    /*  แจ้งเตือนแบบ App Store: กล่องกลางจอ หัวข้อ + ข้อความ + ปุ่มตกลง */
    .sx-alert-bg { position: fixed; inset: 0; z-index: 1000070; background: rgba(0,0,0,.55); display: flex; align-items: center; justify-content: center; padding: 24px; animation: sxFade .15s; }
    .sx-alert { width: 100%; max-width: 280px; background: rgba(38,38,40,.97); -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); border-radius: 14px; overflow: hidden; text-align: center; color: #f5f5f5;
        font-family: -apple-system, BlinkMacSystemFont, system-ui, 'Segoe UI', sans-serif; animation: sxAl .22s cubic-bezier(.2,.9,.3,1.2); }
    @keyframes sxAl { from { opacity: 0; transform: scale(1.12); } }
    .sx-alert b { display: block; padding: 20px 18px 4px; font-size: 17px; font-weight: 600; }
    .sx-alert p { margin: 0; padding: 0 18px 20px; font-size: 13px; line-height: 1.45; color: #d0d0d0; white-space: pre-line; }
    .sx-alert button { display: block; width: 100%; height: 44px; border: 0; border-top: .5px solid rgba(255,255,255,.18); background: none; color: #0a84ff; font: inherit; font-size: 17px; font-weight: 600; cursor: pointer; }
    .sx-alert button:active { background: rgba(255,255,255,.08); }
    .sx-alert-2 { display: flex; }
    .sx-alert-2 button { flex: 1; font-weight: 400; }
    .sx-alert-2 button + button { border-left: .5px solid rgba(255,255,255,.18); }
    .sx-alert-2 button.danger { color: #ff453a; font-weight: 600; }
    /* 🔑 หน้าคีย์และอุปกรณ์ */
    .sx-kh { display: flex; align-items: center; gap: 6px; margin: -6px 0 14px -8px; }
    .sx-kh h3 { margin: 0; }
    .sx-kback { width: 40px; height: 40px; border: 0; background: none; color: var(--s-ink, #f5f5f5); display: flex; align-items: center; justify-content: center; cursor: pointer; }
    .sx-kback svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
    .sx-kl { font-size: 12.5px; color: #8e8e8e; margin: 16px 0 8px; }
    .sx-keypage .sx-btn { margin-bottom: 0; }
    .sx-dev { display: flex; align-items: center; gap: 14px; padding: 14px; border: 1px solid #2e2e2e; min-height: 70px; }
    .sx-dev > svg { flex: none; width: 40px; height: 40px; padding: 8px; border: 1px solid #2e2e2e; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; box-sizing: border-box; }
    .sx-dev-tx { flex: 1; min-width: 0; }
    .sx-dev-tx b { display: block; font-size: 15px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .sx-dev-tx small { display: block; font-size: 12.5px; color: #8e8e8e; margin-top: 3px; }
    .sx-dev-rm { flex: none; height: 34px; padding: 0 16px; border: 1px solid #ff453a; background: none; color: #ff453a; font: inherit; font-size: 13.5px; font-weight: 600; cursor: pointer; }
    .sx-dev-rm:disabled { opacity: .4; }
    .sx-dev.empty { color: #8e8e8e; font-size: 13.5px; justify-content: center; text-align: center; }
    .sx-keypage .sx-key-st { margin: 14px 0 0; }
