/* =========================================================
   DAEN THAI — ธีมหน้าบ้าน
   โทน: ถ่านดำ + ประกายไฟส้ม (Free Fire)
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Chakra+Petch:wght@600;700&family=Kanit:wght@300;400;500;600;700&display=swap');

:root {
    /* พื้นหลัง */
    --ink:        #0A0B0F;
    --ink-2:      #12141B;
    --ink-3:      #191C25;
    --line:       #262A36;
    --line-soft:  #1F222D;

    /* สีหลัก (เปลี่ยนโทนเว็บทั้งหมดได้จากตรงนี้) */
    --ember:      #FF6B00;
    --ember-lt:   #FFA23C;
    --blaze:      #E5321B;
    --gold:       #FFC24B;

    /* ตัวอักษร */
    --paper:      #F3F4F8;
    --mute:       #888DA1;

    /* ระบบ */
    --r-sm: 10px;
    --r-md: 14px;
    --r-lg: 20px;
    --ring: 0 0 0 1px rgba(255,107,0,.35);
    --glow: 0 18px 46px -22px rgba(255,107,0,.75);
    --lift: 0 24px 48px -28px rgba(0,0,0,.9);
    --ease: cubic-bezier(.2, .7, .3, 1);

    --font-display: 'Chakra Petch', 'Kanit', sans-serif;
    --font-body: 'Kanit', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: var(--font-body);
    font-weight: 300;
    background: var(--ink);
    color: var(--paper);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* ประกายไฟจาง ๆ เป็นบรรยากาศพื้นหลัง */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    background:
        radial-gradient(760px 420px at 8% -6%,  rgba(255,107,0,.14), transparent 70%),
        radial-gradient(680px 400px at 98% 4%,  rgba(229,50,27,.10), transparent 70%);
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }

:focus-visible {
    outline: 2px solid var(--ember-lt);
    outline-offset: 3px;
    border-radius: 4px;
}

.container {
    width: min(1240px, 100% - 40px);
    margin-inline: auto;
    position: relative;
    z-index: 1;
}

/* =========================================================
   แถบความน่าเชื่อถือด้านบนสุด
   ========================================================= */
.topbar-trust {
    background: linear-gradient(90deg, var(--blaze), var(--ember));
    color: #fff;
    font-size: 12.5px;
    font-weight: 500;
}
.topbar-trust-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    padding: 7px 0;
    flex-wrap: wrap;
}
.trust-item { display: inline-flex; align-items: center; gap: 6px; }
.trust-item::before {
    content: "";
    width: 5px; height: 5px;
    border-radius: 50%;
    background: rgba(255,255,255,.9);
}
.trust-sep { width: 1px; height: 12px; background: rgba(255,255,255,.35); }

/* =========================================================
   Header
   ========================================================= */
.site-header {
    position: sticky;
    top: 0;
    z-index: 60;
    background: rgba(10, 11, 15, .72);
    backdrop-filter: blur(14px) saturate(140%);
    -webkit-backdrop-filter: blur(14px) saturate(140%);
    border-bottom: 1px solid transparent;
    transition: border-color .25s var(--ease), background .25s var(--ease);
}
.site-header.is-scrolled {
    background: rgba(10, 11, 15, .93);
    border-bottom-color: var(--line);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
    padding: 12px 0;
}

/* โลโก้ + ชื่อร้าน */
.brand { display: flex; align-items: center; gap: 12px; }
.brand-logo-wrap {
    position: relative;
    width: 46px; height: 46px;
    border-radius: 50%;
    padding: 2px;
    background: linear-gradient(140deg, var(--ember), var(--blaze));
    flex-shrink: 0;
    display: grid;
    place-items: center;
    box-shadow: 0 6px 18px -8px rgba(255,107,0,.9);
}
.brand-logo {
    width: 100%; height: 100%;
    border-radius: 50%;
    object-fit: cover;
    background: var(--ink-2);
}
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-name {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 20px;
    letter-spacing: .6px;
    text-transform: uppercase;
    background: linear-gradient(100deg, #fff 25%, var(--ember-lt));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.brand-sub {
    font-size: 11px;
    font-weight: 400;
    color: var(--mute);
    letter-spacing: .4px;
}

/* เมนูหลัก */
.main-nav { display: flex; gap: 4px; }
.main-nav a {
    position: relative;
    padding: 9px 15px;
    border-radius: 999px;
    font-size: 14.5px;
    font-weight: 400;
    color: var(--mute);
    transition: color .2s var(--ease), background .2s var(--ease);
    white-space: nowrap;
}
.main-nav a:hover { color: var(--paper); background: var(--ink-3); }
.main-nav a.active {
    color: #fff;
    font-weight: 500;
    background: linear-gradient(135deg, var(--ember), var(--blaze));
    box-shadow: 0 8px 20px -12px rgba(255,107,0,.95);
}

/* ปุ่มติดต่อบน header */
.header-actions { display: flex; align-items: center; gap: 8px; }
.btn-head {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 9px 15px;
    border-radius: 999px;
    font-size: 13.5px;
    font-weight: 500;
    transition: transform .2s var(--ease), filter .2s var(--ease);
}
.btn-head svg { width: 17px; height: 17px; flex-shrink: 0; }
.btn-head:hover { transform: translateY(-1px); filter: brightness(1.08); }
.btn-head-fb { background: #1877F2; color: #fff; }
.btn-head-wa { background: #25D366; color: #05331C; }

/* ปุ่มเปิดเมนูมือถือ */
.nav-toggle {
    display: none;
    width: 42px; height: 42px;
    border-radius: var(--r-sm);
    border: 1px solid var(--line);
    background: var(--ink-2);
    padding: 11px 10px;
    flex-direction: column;
    justify-content: space-between;
}
.nav-toggle span {
    display: block;
    height: 2px;
    background: var(--paper);
    border-radius: 2px;
    transition: transform .25s var(--ease), opacity .2s var(--ease);
}
.nav-toggle.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.is-open span:nth-child(2) { opacity: 0; }
.nav-toggle.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* เมนูมือถือ */
.mobile-nav {
    display: none;
    border-top: 1px solid var(--line);
    background: var(--ink-2);
    max-height: 0;
    overflow: hidden;
    transition: max-height .3s var(--ease);
}
.mobile-nav.is-open { max-height: 520px; }
.mobile-nav .container { padding-block: 10px 16px; }
.mobile-nav a {
    display: block;
    padding: 12px 4px;
    font-size: 15px;
    color: var(--mute);
    border-bottom: 1px solid var(--line-soft);
}
.mobile-nav a.active { color: var(--ember-lt); font-weight: 500; }
.mobile-nav-actions {
    display: flex;
    gap: 10px;
    margin-top: 16px;
}
.mobile-nav-actions .btn-head {
    flex: 1;
    justify-content: center;
    border-bottom: none;
    padding: 12px;
}

/* =========================================================
   Hero — สไลด์แบนเนอร์
   ========================================================= */
.hero { padding: 24px 0 0; }
.hero-slider {
    position: relative;
    width: min(1240px, 100% - 40px);
    margin-inline: auto;
    height: clamp(340px, 42vw, 470px);
    border-radius: var(--r-lg);
    overflow: hidden;
    border: 1px solid var(--line);
    box-shadow: var(--lift);
    z-index: 1;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    visibility: hidden;
    transition: opacity .8s var(--ease), visibility .8s;
}
.hero-slide.is-active { opacity: 1; visibility: visible; }

.hero-inner {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    background: linear-gradient(115deg, #240C04 0%, #4A1405 48%, #7E2206 100%);
}

/* รูปแบนเนอร์ + เอฟเฟกต์ซูมช้า ๆ
   หมายเหตุ: ใช้แท็ก <img> จริง ไม่ใช่ background-image ผ่านตัวแปร CSS
   เพราะเบราว์เซอร์จะคำนวณ path ของ url() ในตัวแปร CSS เทียบกับไฟล์ .css
   ทำให้รูปที่อัปโหลดหาไม่เจอ */
.hero-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transform: scale(1.06);
    transition: transform 8s linear;
}
.hero-slide.is-active .hero-bg { transform: scale(1); }

/* ไล่เฉดทับให้ตัวอักษรอ่านง่าย */
.hero-inner::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(96deg, rgba(8,9,13,.95) 6%, rgba(8,9,13,.55) 48%, rgba(8,9,13,.15) 100%),
        linear-gradient(0deg, rgba(8,9,13,.7), transparent 55%);
}

/* สไลด์ที่โชว์รูปล้วน (ไม่มีหัวข้อ/ข้อความ) — ไม่ต้องทับเงาหนัก ให้เห็นรูปเต็ม ๆ */
.hero-slide--plain .hero-inner::after {
    background: linear-gradient(0deg, rgba(8,9,13,.42), transparent 34%);
}
.hero-plain-link {
    position: absolute;
    inset: 0;
    z-index: 4;
}

.hero-content {
    position: relative;
    z-index: 2;
    padding: 0 clamp(26px, 5vw, 62px);
    max-width: 660px;
}
.hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 15px;
    border-radius: 999px;
    background: rgba(255,107,0,.13);
    border: 1px solid rgba(255,162,60,.45);
    color: var(--ember-lt);
    font-size: 12.5px;
    font-weight: 500;
    margin-bottom: 18px;
    backdrop-filter: blur(4px);
}
.hero-title {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: clamp(34px, 5.6vw, 60px);
    line-height: 1.05;
    letter-spacing: .5px;
    margin: 0 0 14px;
    background: linear-gradient(178deg, #FFFFFF 28%, var(--ember-lt) 92%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    filter: drop-shadow(0 6px 26px rgba(255,107,0,.35));
}
.hero-subtitle {
    font-size: clamp(14.5px, 1.5vw, 17px);
    color: #DDD9D4;
    max-width: 520px;
    margin: 0 0 28px;
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    border-radius: var(--r-sm);
    font-weight: 600;
    font-size: 15px;
    color: #fff;
    background: linear-gradient(135deg, var(--ember), var(--blaze));
    box-shadow: var(--glow);
    transition: transform .2s var(--ease), box-shadow .2s var(--ease);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 22px 50px -20px rgba(255,107,0,.95);
}
.btn-secondary {
    display: inline-flex;
    align-items: center;
    padding: 14px 26px;
    border-radius: var(--r-sm);
    font-weight: 500;
    font-size: 15px;
    color: #fff;
    background: rgba(255,255,255,.07);
    border: 1px solid rgba(255,255,255,.22);
    backdrop-filter: blur(6px);
    transition: background .2s var(--ease), border-color .2s var(--ease);
}
.btn-secondary:hover { background: rgba(255,255,255,.13); border-color: rgba(255,255,255,.4); }

/* ปุ่มควบคุมสไลด์ */
.hero-nav {
    position: absolute;
    z-index: 3;
    right: clamp(18px, 3vw, 30px);
    bottom: clamp(18px, 3vw, 26px);
    display: flex;
    align-items: center;
    gap: 12px;
}
.hero-arrow {
    width: 40px; height: 40px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 15px;
    color: #fff;
    background: rgba(10,11,15,.55);
    border: 1px solid rgba(255,255,255,.22);
    backdrop-filter: blur(6px);
    transition: background .2s var(--ease), border-color .2s var(--ease);
}
.hero-arrow:hover { background: var(--ember); border-color: var(--ember); }
.hero-dots { display: flex; gap: 7px; }
.hero-dot {
    width: 8px; height: 8px;
    padding: 0;
    border-radius: 999px;
    background: rgba(255,255,255,.35);
    transition: width .3s var(--ease), background .3s var(--ease);
}
.hero-dot.is-active { width: 26px; background: var(--ember); }

/* =========================================================
   หัวข้อ Section
   ========================================================= */
.section { padding: clamp(44px, 6vw, 72px) 0; }

.section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 18px;
    flex-wrap: wrap;
    margin-bottom: 28px;
}
.section-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: clamp(21px, 2.6vw, 28px);
    letter-spacing: .4px;
    margin: 0;
}
.section-title .dot {
    width: 5px;
    height: 26px;
    border-radius: 999px;
    background: linear-gradient(180deg, var(--ember), var(--blaze));
    flex-shrink: 0;
}
.section-sub {
    color: var(--mute);
    font-size: 14px;
    margin-top: 6px;
    padding-left: 17px;
}

/* แท็บกรองหมวดหมู่ */
.filter-tabs { display: flex; gap: 8px; flex-wrap: wrap; }
.filter-tabs a {
    padding: 9px 17px;
    border-radius: 999px;
    background: var(--ink-2);
    border: 1px solid var(--line);
    font-size: 13.5px;
    font-weight: 400;
    color: var(--mute);
    transition: color .2s var(--ease), border-color .2s var(--ease), background .2s var(--ease);
}
.filter-tabs a:hover { color: var(--paper); border-color: rgba(255,162,60,.5); }
.filter-tabs a.active {
    color: #fff;
    font-weight: 500;
    background: linear-gradient(135deg, rgba(255,107,0,.22), rgba(229,50,27,.14));
    border-color: rgba(255,162,60,.65);
}

/* =========================================================
   การ์ดสินค้า
   ========================================================= */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 22px;
}

.product-card {
    position: relative;
    display: flex;
    flex-direction: column;
    background: var(--ink-2);
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    overflow: hidden;
    transition: transform .28s var(--ease), border-color .28s var(--ease), box-shadow .28s var(--ease);
}
.product-card:hover {
    transform: translateY(-6px);
    border-color: rgba(255,162,60,.55);
    box-shadow: 0 28px 50px -30px rgba(255,107,0,.85), var(--lift);
}

.product-thumb {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #08090D;
}
.product-thumb img {
    width: 100%; height: 100%;
    object-fit: cover;
    transition: transform .5s var(--ease);
}
.product-card:hover .product-thumb img { transform: scale(1.07); }
/* เงาไล่ขอบล่างรูป ให้ต่อกับเนื้อการ์ด */
.product-thumb::after {
    content: "";
    position: absolute;
    inset: auto 0 0 0;
    height: 45%;
    background: linear-gradient(0deg, var(--ink-2), transparent);
    pointer-events: none;
}

.badge-category {
    position: absolute;
    top: 11px; left: 11px;
    z-index: 2;
    padding: 4px 11px;
    border-radius: 999px;
    font-size: 11.5px;
    font-weight: 500;
    color: var(--ember-lt);
    background: rgba(10,11,15,.72);
    border: 1px solid rgba(255,162,60,.4);
    backdrop-filter: blur(6px);
}
.badge-discount {
    position: absolute;
    top: 11px; right: 11px;
    z-index: 2;
    padding: 5px 11px;
    border-radius: 999px;
    font-family: var(--font-display);
    font-size: 12.5px;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, var(--blaze), #A81C0A);
    box-shadow: 0 6px 16px -8px rgba(229,50,27,.9);
}
.badge-sold {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: grid;
    place-items: center;
    font-family: var(--font-display);
    font-size: 19px;
    font-weight: 700;
    letter-spacing: 3px;
    color: #FF7A7A;
    background: rgba(6,7,10,.74);
    backdrop-filter: blur(1.5px);
}

.product-body {
    position: relative;
    z-index: 2;
    padding: 4px 17px 17px;
    display: flex;
    flex-direction: column;
    flex: 1;
}
.product-name {
    font-size: 15px;
    font-weight: 400;
    line-height: 1.45;
    margin: 0 0 12px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 44px;
}
.price-row {
    display: flex;
    align-items: baseline;
    gap: 9px;
    margin-bottom: 14px;
    margin-top: auto;
}
.price-now {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 22px;
    color: var(--gold);
    letter-spacing: .3px;
}
.price-old {
    font-size: 13px;
    color: var(--mute);
    text-decoration: line-through;
}

.btn-view {
    display: block;
    text-align: center;
    padding: 11px;
    border-radius: var(--r-sm);
    font-size: 14px;
    font-weight: 500;
    color: var(--ember-lt);
    background: linear-gradient(135deg, rgba(255,107,0,.16), rgba(229,50,27,.08));
    border: 1px solid rgba(255,162,60,.4);
    transition: background .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease);
}
.product-card:hover .btn-view {
    color: #fff;
    background: linear-gradient(135deg, var(--ember), var(--blaze));
    border-color: transparent;
}

/* =========================================================
   ทำไมต้องเลือกเรา
   ========================================================= */
.perks {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2px;
    background: var(--line-soft);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    overflow: hidden;
}
.perk {
    background: var(--ink-2);
    padding: 32px 24px;
    text-align: center;
    transition: background .25s var(--ease);
}
.perk:hover { background: var(--ink-3); }
.perk .icon {
    width: 54px; height: 54px;
    margin: 0 auto 14px;
    display: grid;
    place-items: center;
    font-size: 23px;
    border-radius: var(--r-md);
    background: linear-gradient(140deg, rgba(255,107,0,.2), rgba(229,50,27,.1));
    border: 1px solid rgba(255,162,60,.35);
}
.perk .title { font-weight: 500; font-size: 15.5px; margin-bottom: 5px; }
.perk .desc { font-size: 13px; color: var(--mute); line-height: 1.5; }

/* =========================================================
   แถบชวนติดต่อ (CTA)
   ========================================================= */
.cta-strip {
    margin-top: clamp(40px, 6vw, 64px);
    padding: clamp(30px, 4vw, 44px) 0;
    background:
        linear-gradient(120deg, rgba(255,107,0,.16), rgba(229,50,27,.07)),
        var(--ink-2);
    border-block: 1px solid var(--line);
}
.cta-strip-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 26px;
    flex-wrap: wrap;
}
.cta-copy h2 {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: clamp(20px, 2.4vw, 26px);
    margin: 0 0 6px;
}
.cta-copy p { margin: 0; color: var(--mute); font-size: 14.5px; }
.cta-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.cta-actions a { min-width: 190px; }

/* =========================================================
   Footer
   ========================================================= */
.site-footer {
    background: #07080B;
    border-top: 1px solid var(--line);
    padding-top: clamp(40px, 5vw, 56px);
}
.footer-grid {
    display: grid;
    grid-template-columns: 1.7fr 1fr 1fr 1.3fr;
    gap: 34px;
    padding-bottom: 38px;
}
.footer-brand .brand { margin-bottom: 14px; }
.footer-brand p {
    color: var(--mute);
    font-size: 13.5px;
    line-height: 1.7;
    max-width: 330px;
    margin: 0;
}
.footer-social { display: flex; gap: 9px; margin-top: 18px; }
.footer-social a {
    width: 38px; height: 38px;
    border-radius: var(--r-sm);
    display: grid;
    place-items: center;
    background: var(--ink-2);
    border: 1px solid var(--line);
    color: var(--mute);
    transition: color .2s var(--ease), border-color .2s var(--ease), transform .2s var(--ease);
}
.footer-social a svg { width: 18px; height: 18px; }
.footer-social a:hover { color: var(--ember-lt); border-color: rgba(255,162,60,.5); transform: translateY(-2px); }

.footer-col h4 {
    font-size: 14.5px;
    font-weight: 600;
    color: var(--paper);
    margin: 0 0 16px;
}
.footer-col a, .footer-col span {
    display: block;
    color: var(--mute);
    font-size: 13.8px;
    margin-bottom: 11px;
    transition: color .2s var(--ease);
}
.footer-col a:hover { color: var(--ember-lt); }
.footer-contact span b {
    display: block;
    color: #6E7286;
    font-size: 11.5px;
    font-weight: 400;
    margin-bottom: 1px;
}
.footer-contact span { color: var(--paper); font-size: 14px; }

.footer-bottom {
    border-top: 1px solid var(--line);
    padding: 18px 0;
    display: flex;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
    color: #6E7286;
    font-size: 12.5px;
}

/* =========================================================
   หน้ารายละเอียดสินค้า
   ========================================================= */
.breadcrumb {
    color: var(--mute);
    font-size: 13.5px;
    margin: 26px 0 22px;
}
.breadcrumb a { color: var(--ember-lt); }
.breadcrumb a:hover { text-decoration: underline; }

.product-detail {
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: clamp(26px, 4vw, 46px);
    align-items: start;
    padding-bottom: 20px;
}
/* แกลเลอรีรูปสินค้า */
.detail-gallery { position: relative; }

.gallery-main {
    position: relative;
    border-radius: var(--r-lg);
    overflow: hidden;
    border: 1px solid var(--line);
    background: var(--ink-2);
    box-shadow: var(--lift);
}
.gallery-main img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    display: block;
}

/* ปุ่มเลื่อนรูปซ้าย/ขวา */
.gallery-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 4;
    width: 42px; height: 42px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 15px;
    color: #fff;
    background: rgba(10,11,15,.6);
    border: 1px solid rgba(255,255,255,.22);
    backdrop-filter: blur(6px);
    opacity: 0;
    transition: opacity .25s var(--ease), background .2s var(--ease);
}
.gallery-main:hover .gallery-arrow,
.gallery-arrow:focus-visible { opacity: 1; }
.gallery-arrow:hover { background: var(--ember); border-color: var(--ember); }
.gallery-arrow.prev { left: 14px; }
.gallery-arrow.next { right: 14px; }

.gallery-counter {
    position: absolute;
    bottom: 14px; right: 14px;
    z-index: 4;
    padding: 5px 13px;
    border-radius: 999px;
    font-size: 12.5px;
    font-weight: 500;
    color: #fff;
    background: rgba(10,11,15,.68);
    border: 1px solid rgba(255,255,255,.18);
    backdrop-filter: blur(6px);
}

/* แถบรูปย่อ */
.gallery-thumbs {
    display: flex;
    gap: 10px;
    margin-top: 12px;
    overflow-x: auto;
    padding-bottom: 4px;
    scrollbar-width: thin;
    scrollbar-color: var(--line) transparent;
}
.gallery-thumbs::-webkit-scrollbar { height: 6px; }
.gallery-thumbs::-webkit-scrollbar-thumb { background: var(--line); border-radius: 999px; }

.gallery-thumb {
    flex: 0 0 82px;
    padding: 0;
    border-radius: var(--r-sm);
    overflow: hidden;
    border: 2px solid transparent;
    background: var(--ink-2);
    cursor: pointer;
    transition: border-color .2s var(--ease), opacity .2s var(--ease);
    opacity: .6;
}
.gallery-thumb img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    display: block;
}
.gallery-thumb:hover { opacity: 1; }
.gallery-thumb.is-active {
    opacity: 1;
    border-color: var(--ember);
}

/* ป้ายหมวดหมู่เหนือชื่อสินค้า */
.detail-cat {
    display: inline-block;
    padding: 5px 14px;
    border-radius: 999px;
    margin-bottom: 14px;
    font-size: 12.5px;
    font-weight: 500;
    color: var(--ember-lt);
    background: rgba(255,107,0,.12);
    border: 1px solid rgba(255,162,60,.4);
    transition: background .2s var(--ease);
}
.detail-cat:hover { background: rgba(255,107,0,.22); }

.detail-info h1 {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: clamp(24px, 3vw, 33px);
    line-height: 1.25;
    letter-spacing: .3px;
    margin: 0 0 16px;
}
.detail-price {
    display: flex;
    align-items: baseline;
    gap: 13px;
    flex-wrap: wrap;
    padding-bottom: 22px;
    margin-bottom: 22px;
    border-bottom: 1px solid var(--line);
}
.detail-price .now {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: clamp(30px, 4vw, 38px);
    color: var(--gold);
}
.detail-price .old { font-size: 16px; color: var(--mute); text-decoration: line-through; }
.detail-price .off {
    padding: 5px 12px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
    color: #fff;
    background: linear-gradient(135deg, var(--blaze), #A81C0A);
}

.detail-block-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--ember-lt);
    margin-bottom: 9px;
}
.detail-desc {
    color: #C9CBD6;
    font-size: 14.8px;
    line-height: 1.75;
    margin: 0 0 24px;
    white-space: pre-line;
}

.sold-banner {
    padding: 14px 18px;
    border-radius: var(--r-sm);
    margin-bottom: 22px;
    font-size: 14px;
    font-weight: 400;
    color: #FF9A9A;
    background: rgba(229,50,27,.11);
    border: 1px solid rgba(229,50,27,.4);
}

.detail-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.btn-buy-fb, .btn-buy-wa {
    flex: 1;
    min-width: 210px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 16px 22px;
    border-radius: var(--r-sm);
    font-size: 15.5px;
    font-weight: 600;
    transition: transform .2s var(--ease), filter .2s var(--ease);
}
.btn-buy-fb { background: #1877F2; color: #fff; box-shadow: 0 16px 34px -20px rgba(24,119,242,.95); }
.btn-buy-wa { background: #25D366; color: #05331C; box-shadow: 0 16px 34px -20px rgba(37,211,102,.9); }
.btn-buy-fb:hover, .btn-buy-wa:hover { transform: translateY(-2px); filter: brightness(1.07); }

/* จุดสร้างความมั่นใจใต้ปุ่มซื้อ */
.detail-assurance {
    list-style: none;
    margin: 24px 0 0;
    padding: 20px 22px;
    border-radius: var(--r-md);
    background: var(--ink-2);
    border: 1px solid var(--line);
}
.detail-assurance li {
    position: relative;
    padding-left: 26px;
    font-size: 13.8px;
    color: var(--mute);
}
.detail-assurance li + li { margin-top: 11px; }
.detail-assurance li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 8px;
    width: 13px; height: 7px;
    border-left: 2px solid var(--ember);
    border-bottom: 2px solid var(--ember);
    transform: rotate(-45deg);
}

/* อุปกรณ์สัมผัสไม่มี hover จึงต้องโชว์ปุ่มเลื่อนรูปไว้ตลอด */
@media (hover: none) {
    .gallery-arrow { opacity: 1; }
}

/* =========================================================
   สถานะว่าง
   ========================================================= */
.empty-state {
    text-align: center;
    padding: 70px 20px;
    color: var(--mute);
    background: var(--ink-2);
    border: 1px dashed var(--line);
    border-radius: var(--r-lg);
    font-size: 15px;
}

/* =========================================================
   Responsive
   ========================================================= */
@media (max-width: 1080px) {
    .main-nav { display: none; }
    .nav-toggle { display: flex; }
    .mobile-nav { display: block; }
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 28px; }
}

@media (max-width: 820px) {
    .btn-head span { display: none; }
    .btn-head { padding: 10px 12px; }
    .mobile-nav-actions .btn-head span { display: inline; }
    .perks { grid-template-columns: repeat(2, 1fr); }
    .product-detail { grid-template-columns: 1fr; }
    .topbar-trust-inner { font-size: 11.5px; gap: 10px; }
    .cta-actions { width: 100%; }
    .cta-actions a { flex: 1; }
}

@media (max-width: 560px) {
    .container, .hero-slider { width: min(1240px, 100% - 28px); }
    .hero-slider { height: 400px; }
    .hero-content { max-width: 100%; }
    .hero-subtitle { margin-bottom: 22px; }
    .hero-actions { flex-direction: column; align-items: stretch; }
    .hero-actions a { justify-content: center; }
    .hero-nav { left: clamp(18px, 3vw, 30px); justify-content: center; }
    /* แบนเนอร์แนวยาวที่มีตัวหนังสือในรูป ให้เห็นเต็มใบบนมือถือ ไม่ถูกครอบตัด */
    .hero-slide--plain .hero-bg { object-fit: contain; }
    .product-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 14px; }
    .product-body { padding: 4px 13px 14px; }
    .price-now { font-size: 19px; }
    .perks { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .trust-sep, .trust-item:nth-child(5) { display: none; }
}

/* เคารพการตั้งค่าลดการเคลื่อนไหวของผู้ใช้ */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation-duration: .01ms !important;
        transition-duration: .01ms !important;
    }
    .hero-bg { transform: none; }
}
