/* ===== Template: Social Boost =====
   เปลี่ยนสีทั้งเว็บ: แก้ --brand / --brand-2 (สีไล่เฉดของปุ่มและหัวข้อ)
*/
:root {
  --brand: #7c3aed;
  --brand-2: #ec4899;
  --brand-dark: #5b21b6;
  --brand-soft: #f3edff;
  --accent: #f97316;
  --gradient: linear-gradient(120deg, var(--brand), var(--brand-2));

  --text: #1a1033;
  --muted: #5b5670;
  --line: #e9e5f2;
  --bg: #ffffff;
  --bg-soft: #faf8ff;
  --dark: #150b2e;

  --success: #16a34a;
  --success-soft: #dcfce7;
  --warning: #b45309;
  --warning-soft: #fef3c7;
  --info: #2563eb;
  --info-soft: #dbeafe;
  --danger: #dc2626;
  --danger-soft: #fee2e2;

  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 10px 30px rgba(76, 29, 149, 0.08);
  --shadow-lg: 0 24px 60px rgba(76, 29, 149, 0.16);
  --font: "IBM Plex Sans Thai", system-ui, -apple-system, "Segoe UI", Tahoma, sans-serif;
  --container: 1160px;
  --header-h: 72px;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); color: var(--text); background: var(--bg); line-height: 1.7; font-size: 16px; overflow-x: hidden; }
img, svg { max-width: 100%; display: block; }
a { color: var(--brand); }
h1, h2, h3, h4 { line-height: 1.3; margin: 0 0 .5em; }
p { margin: 0 0 1em; }
button, input, select, textarea { font: inherit; color: inherit; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 24px; }
.skip-link { position: absolute; left: -999px; top: 8px; background: var(--dark); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip-link:focus { left: 8px; }
.gradient-text { background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--brand) 45%, transparent); outline-offset: 2px; }

/* ---------- ปุ่ม ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 24px; border-radius: 999px; border: 1px solid transparent;
  font-weight: 600; text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: transform .2s, box-shadow .2s, background-color .2s, color .2s, border-color .2s;
}
.btn-primary { background: var(--gradient); color: #fff; box-shadow: 0 8px 20px rgba(124, 58, 237, .28); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(124, 58, 237, .36); }
.btn-ghost { background: #fff; color: var(--text); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--brand); color: var(--brand); }
.btn-light { background: #fff; color: var(--brand-dark); }
.btn-light:hover { transform: translateY(-2px); }
.btn-lg { padding: 15px 30px; font-size: 1.05rem; }
.btn-sm { padding: 8px 16px; font-size: .92rem; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .6; cursor: not-allowed; transform: none; }

/* ---------- เมนูด้านบน ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .86); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); transition: box-shadow .2s; }
.site-header.is-scrolled { box-shadow: 0 1px 0 var(--line), 0 8px 24px rgba(21, 11, 46, .06); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: var(--header-h); }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.2rem; color: var(--text); text-decoration: none; }
.brand img { width: 36px; height: 36px; }
.brand-accent { color: var(--brand-2); }
.nav { display: flex; align-items: center; gap: 28px; }
.nav-list { display: flex; gap: 24px; list-style: none; margin: 0; padding: 0; }
.nav-list a { color: var(--muted); text-decoration: none; font-weight: 500; position: relative; padding: 6px 0; }
.nav-list a:hover, .nav-list a.is-active { color: var(--brand); }
.nav-list a.is-active::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; border-radius: 2px; background: var(--gradient); }
.nav-actions { display: flex; gap: 10px; }
.nav-toggle { display: none; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 12px; background: #fff; cursor: pointer; flex-direction: column; justify-content: center; align-items: center; gap: 5px; }
.nav-toggle span { width: 20px; height: 2px; background: var(--text); border-radius: 2px; transition: transform .2s, opacity .2s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- section ทั่วไป ---------- */
.section { padding: 96px 0; }
.section-soft { background: var(--bg-soft); }
.section-head { text-align: center; max-width: 680px; margin: 0 auto 52px; }
.eyebrow { display: inline-block; font-weight: 600; font-size: .9rem; color: var(--brand); background: var(--brand-soft); padding: 4px 14px; border-radius: 999px; margin-bottom: 14px; }
.section-head h2 { font-size: clamp(1.7rem, 3.4vw, 2.4rem); }
.section-head p { color: var(--muted); font-size: 1.05rem; }

/* ---------- Hero ---------- */
.hero { position: relative; padding: 72px 0 88px; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: -20% -10% auto auto; width: 720px; height: 720px; border-radius: 50%; background: radial-gradient(circle, rgba(236, 72, 153, .16), transparent 65%); pointer-events: none; }
.hero::after { content: ""; position: absolute; left: -200px; bottom: -260px; width: 600px; height: 600px; border-radius: 50%; background: radial-gradient(circle, rgba(124, 58, 237, .14), transparent 65%); pointer-events: none; }
.hero-inner { position: relative; z-index: 1; display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: center; }
.hero-badge { display: inline-flex; align-items: center; gap: 8px; background: #fff; border: 1px solid var(--line); padding: 6px 14px 6px 8px; border-radius: 999px; font-size: .92rem; color: var(--muted); box-shadow: var(--shadow); margin-bottom: 20px; }
.hero-badge b { background: var(--gradient); color: #fff; padding: 2px 10px; border-radius: 999px; font-size: .8rem; }
.hero h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); letter-spacing: -.01em; }
.hero-lead { font-size: 1.15rem; color: var(--muted); max-width: 540px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 28px 0 32px; }
.hero-points { display: flex; flex-wrap: wrap; gap: 10px 22px; list-style: none; padding: 0; margin: 0; color: var(--muted); font-size: .95rem; }
.hero-points li { display: flex; align-items: center; gap: 8px; }
.hero-points svg { width: 18px; height: 18px; color: var(--success); flex: none; }
.hero-visual { position: relative; }
.hero-visual img { width: 100%; height: auto; filter: drop-shadow(0 30px 50px rgba(76, 29, 149, .18)); }

/* ---------- แพลตฟอร์ม ---------- */
.platforms { padding: 28px 0; border-block: 1px solid var(--line); }
.platforms-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 12px 14px; }
.platforms-label { color: var(--muted); font-size: .95rem; margin-right: 8px; }
.platform-chip { display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; border-radius: 999px; background: var(--bg-soft); border: 1px solid var(--line); font-weight: 600; font-size: .95rem; }
.platform-chip i { width: 10px; height: 10px; border-radius: 50%; background: var(--dot, var(--brand)); }

/* ---------- การ์ด ---------- */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow); transition: transform .25s, box-shadow .25s, border-color .25s; }
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: color-mix(in srgb, var(--brand) 30%, var(--line)); }
.card h3 { font-size: 1.2rem; }
.card p { color: var(--muted); margin: 0; }
.card-icon { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand); margin-bottom: 18px; }
.card-icon svg { width: 26px; height: 26px; }
.card-icon.is-pink { background: #fde7f3; color: var(--brand-2); }
.card-icon.is-orange { background: #ffedd5; color: var(--accent); }

/* ---------- ตารางราคา ---------- */
.tabs { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-bottom: 32px; }
.tab { border: 1px solid var(--line); background: #fff; padding: 10px 20px; border-radius: 999px; font-weight: 600; cursor: pointer; color: var(--muted); transition: background-color .2s, color .2s, border-color .2s; }
.tab:hover { color: var(--brand); border-color: var(--brand); }
.tab[aria-selected="true"] { background: var(--gradient); color: #fff; border-color: transparent; }
.no-js .tabs { display: none; }
.price-panel + .price-panel { margin-top: 40px; }
.js .price-panel + .price-panel { margin-top: 0; }
.price-panel-title { font-size: 1.15rem; margin-bottom: 16px; }
.js .price-panel-title { display: none; }
.price-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.price-card { position: relative; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow); display: flex; flex-direction: column; }
.price-card.is-popular { border: 2px solid transparent; background: linear-gradient(#fff, #fff) padding-box, var(--gradient) border-box; }
.price-tag { position: absolute; top: -13px; left: 50%; transform: translateX(-50%); background: var(--gradient); color: #fff; font-size: .8rem; font-weight: 600; padding: 3px 14px; border-radius: 999px; white-space: nowrap; }
.price-card h3 { font-size: 1.1rem; margin-bottom: 4px; }
.price-card .price { font-size: 2.2rem; font-weight: 700; line-height: 1.2; margin: 10px 0 2px; }
.price-card .price small { font-size: 1rem; font-weight: 500; color: var(--muted); }
.price-unit { color: var(--muted); font-size: .92rem; margin-bottom: 18px; }
.price-list { list-style: none; padding: 0; margin: 0 0 24px; display: grid; gap: 10px; color: var(--muted); font-size: .95rem; }
.price-list li { display: flex; gap: 10px; }
.price-list li::before { content: ""; flex: none; width: 18px; height: 18px; margin-top: 4px; border-radius: 50%; background: var(--success-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2316a34a' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 12 4 4 8-8'/%3E%3C/svg%3E") center / 12px no-repeat; }
.price-card .btn { margin-top: auto; }
.price-note { text-align: center; color: var(--muted); font-size: .92rem; margin-top: 28px; }

/* ---------- ขั้นตอน ---------- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; counter-reset: step; list-style: none; padding: 0; margin: 0; }
.step { position: relative; text-align: center; padding: 8px 12px; }
.step-num { width: 64px; height: 64px; margin: 0 auto 18px; border-radius: 20px; display: grid; place-items: center; font-size: 1.5rem; font-weight: 700; color: #fff; background: var(--gradient); box-shadow: 0 10px 24px rgba(124, 58, 237, .28); }
.step:not(:last-child)::after { content: ""; position: absolute; top: 40px; left: calc(50% + 48px); right: calc(-50% + 48px); border-top: 2px dashed color-mix(in srgb, var(--brand) 35%, transparent); }
.step h3 { font-size: 1.1rem; }
.step p { color: var(--muted); margin: 0; font-size: .95rem; }

/* ---------- ตัวเลข ---------- */
.stats-band { background: var(--dark); color: #fff; padding: 64px 0; position: relative; overflow: hidden; }
.stats-band::before { content: ""; position: absolute; inset: 0; background: radial-gradient(600px 300px at 15% 0%, rgba(124, 58, 237, .45), transparent 70%), radial-gradient(600px 300px at 85% 100%, rgba(236, 72, 153, .35), transparent 70%); }
.stats-grid { position: relative; display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; text-align: center; }
.stat-num { font-size: clamp(2rem, 4vw, 2.8rem); font-weight: 700; line-height: 1.2; }
.stat-label { color: rgba(255, 255, 255, .72); }

/* ---------- รีวิว ---------- */
.review { display: flex; flex-direction: column; gap: 16px; }
.review-stars { color: #f59e0b; letter-spacing: 2px; }
.review blockquote { margin: 0; color: var(--text); }
.review-author { display: flex; align-items: center; gap: 12px; margin-top: auto; }
.avatar { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; color: #fff; background: var(--gradient); flex: none; }
.review-author b { display: block; line-height: 1.3; }
.review-author span { color: var(--muted); font-size: .9rem; }

/* ---------- คำถาม ---------- */
.faq { max-width: 800px; margin: 0 auto; display: grid; gap: 12px; }
.faq details { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 0 22px; transition: border-color .2s; }
.faq details[open] { border-color: color-mix(in srgb, var(--brand) 40%, var(--line)); }
.faq summary { list-style: none; cursor: pointer; padding: 18px 32px 18px 0; font-weight: 600; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 0; top: 50%; transform: translateY(-50%); font-size: 1.5rem; font-weight: 400; color: var(--brand); transition: transform .2s; }
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details p { color: var(--muted); padding-bottom: 18px; margin: 0; }

/* ---------- CTA ---------- */
.cta { padding: 0 0 96px; }
.cta-box { border-radius: 28px; padding: 56px; background: var(--gradient); color: #fff; display: flex; align-items: center; justify-content: space-between; gap: 32px; position: relative; overflow: hidden; }
.cta-box::after { content: ""; position: absolute; right: -80px; top: -120px; width: 360px; height: 360px; border-radius: 50%; background: rgba(255, 255, 255, .12); }
.cta-box h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); margin-bottom: 8px; }
.cta-box p { margin: 0; opacity: .9; }
.cta-box .btn { position: relative; z-index: 1; }

/* ---------- footer ---------- */
.site-footer { background: var(--dark); color: rgba(255, 255, 255, .75); padding: 64px 0 28px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 32px; }
.site-footer .brand { color: #fff; margin-bottom: 14px; }
.site-footer h4 { color: #fff; font-size: 1rem; margin-bottom: 14px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.site-footer a { color: rgba(255, 255, 255, .75); text-decoration: none; }
.site-footer a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .12); margin-top: 48px; padding-top: 24px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: .9rem; }

/* ---------- เอฟเฟกต์ตอนเลื่อน (ซ่อนเฉพาะเมื่อมี JS) ---------- */
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.js .reveal.is-visible { opacity: 1; transform: none; }

/* ===================================================================
   หน้าสมาชิก (login / register / dashboard)
   =================================================================== */
.demo-banner { background: var(--warning-soft); color: var(--warning); text-align: center; font-size: .9rem; padding: 8px 16px; }
.demo-banner b { font-weight: 700; }

.auth-page { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
.auth-side { background: var(--gradient); color: #fff; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; position: relative; overflow: hidden; }
.auth-side::after { content: ""; position: absolute; right: -120px; bottom: -120px; width: 420px; height: 420px; border-radius: 50%; background: rgba(255, 255, 255, .1); }
.auth-side .brand { color: #fff; }
.auth-side .brand-accent { color: #fff; opacity: .8; }
.auth-side h2 { font-size: clamp(1.6rem, 3vw, 2.3rem); max-width: 420px; }
.auth-side ul { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 12px; position: relative; z-index: 1; }
.auth-side li { display: flex; gap: 10px; align-items: center; }
.auth-side li svg { width: 20px; height: 20px; flex: none; }
.auth-main { display: flex; flex-direction: column; justify-content: center; padding: 48px 24px; }
.auth-card { width: 100%; max-width: 420px; margin: 0 auto; }
.auth-card h1 { font-size: 1.8rem; margin-bottom: 6px; }
.auth-card > p { color: var(--muted); margin-bottom: 28px; }
.auth-switch { text-align: center; margin-top: 24px; color: var(--muted); }
.auth-back { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); text-decoration: none; margin-bottom: 32px; font-size: .95rem; }
.auth-back:hover { color: var(--brand); }

.field { display: grid; gap: 6px; margin-bottom: 16px; }
.field label { font-weight: 600; font-size: .95rem; }
.field input, .field select, .field textarea {
  width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: #fff;
  transition: border-color .2s, box-shadow .2s;
}
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 15%, transparent); }
.field-hint { color: var(--muted); font-size: .85rem; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.password-wrap { position: relative; }
.password-wrap input { padding-right: 76px; }
.password-toggle { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); border: 0; background: none; color: var(--brand); font-weight: 600; font-size: .88rem; cursor: pointer; padding: 6px 10px; border-radius: 8px; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: .92rem; color: var(--muted); margin-bottom: 20px; }
.check input { margin-top: 5px; accent-color: var(--brand); }

.alert { border-radius: var(--radius-sm); padding: 12px 14px; font-size: .95rem; margin-bottom: 16px; }
.alert-error { background: var(--danger-soft); color: var(--danger); }
.alert-success { background: var(--success-soft); color: var(--success); }
.alert-info { background: var(--info-soft); color: var(--info); }

/* แดชบอร์ด */
.dash-header { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 40; }
.dash-header .header-inner { height: 64px; }
.dash-user { display: flex; align-items: center; gap: 12px; }
.dash-user .avatar { width: 38px; height: 38px; font-size: .95rem; }
.dash-user-name { font-weight: 600; line-height: 1.2; }
.dash-user-email { color: var(--muted); font-size: .82rem; }
.dash-main { padding: 32px 0 72px; background: var(--bg-soft); min-height: calc(100vh - 64px); }
.dash-title { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 24px; }
.dash-title h1 { font-size: 1.6rem; margin: 0; }
.dash-title p { margin: 0; color: var(--muted); }
.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 24px; }
.tile { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.tile-label { color: var(--muted); font-size: .9rem; }
.tile-value { font-size: 1.7rem; font-weight: 700; line-height: 1.3; }
.tile.is-balance { background: var(--gradient); color: #fff; border: 0; }
.tile.is-balance .tile-label { color: rgba(255, 255, 255, .85); }
.dash-grid { display: grid; grid-template-columns: 1.5fr 1fr; gap: 24px; align-items: start; margin-bottom: 24px; }
.panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.panel h2 { font-size: 1.2rem; margin-bottom: 18px; }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.panel-head h2 { margin: 0; }
.order-summary { display: flex; justify-content: space-between; align-items: center; gap: 12px; background: var(--bg-soft); border-radius: var(--radius-sm); padding: 14px 16px; margin-bottom: 16px; }
.order-summary b { font-size: 1.4rem; }
.amounts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 16px; }
.amount { border: 1px solid var(--line); background: #fff; border-radius: var(--radius-sm); padding: 10px; font-weight: 600; cursor: pointer; transition: border-color .2s, background-color .2s, color .2s; }
.amount:hover { border-color: var(--brand); }
.amount.is-selected { border-color: var(--brand); background: var(--brand-soft); color: var(--brand-dark); }

.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.table th { text-align: left; font-weight: 600; color: var(--muted); font-size: .85rem; padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.table td { padding: 14px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.table tr:last-child td { border-bottom: 0; }
.table .num { text-align: right; white-space: nowrap; }
.link-cell { max-width: 240px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.muted { color: var(--muted); }
.empty { text-align: center; color: var(--muted); padding: 32px 12px; }
.badge { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: .82rem; font-weight: 600; white-space: nowrap; }
.badge-pending { background: var(--warning-soft); color: var(--warning); }
.badge-processing { background: var(--info-soft); color: var(--info); }
.badge-completed { background: var(--success-soft); color: var(--success); }
.badge-canceled { background: var(--danger-soft); color: var(--danger); }

/* ===================================================================
   จอเล็ก
   =================================================================== */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .tiles { grid-template-columns: repeat(2, 1fr); }
  .dash-grid { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  .nav-toggle { display: flex; }
  .nav {
    position: absolute; top: var(--header-h); left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 16px;
    background: #fff; padding: 16px 24px 24px; border-bottom: 1px solid var(--line); box-shadow: 0 16px 32px rgba(21, 11, 46, .08);
    opacity: 0; visibility: hidden; transform: translateY(-8px); transition: opacity .2s, transform .2s, visibility .2s;
  }
  .nav.is-open { opacity: 1; visibility: visible; transform: none; }
  .nav-list { flex-direction: column; gap: 0; }
  .nav-list a { display: block; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .nav-list a.is-active::after { display: none; }
  .nav-actions .btn { flex: 1; }
  .hero-inner { grid-template-columns: 1fr; }
  .hero-visual { max-width: 480px; margin: 0 auto; }
  .grid-3, .price-grid { grid-template-columns: 1fr 1fr; }
  .steps { grid-template-columns: 1fr 1fr; row-gap: 36px; }
  .step::after { display: none; }
  .stats-grid { grid-template-columns: 1fr 1fr; row-gap: 32px; }
  .cta-box { flex-direction: column; text-align: center; padding: 44px 28px; }
  .auth-page { grid-template-columns: 1fr; }
  .auth-side { display: none; }
}

@media (max-width: 720px) {
  /* ตารางคำสั่งซื้อเป็นการ์ด */
  .table thead { display: none; }
  .table, .table tbody, .table tr, .table td { display: block; width: 100%; }
  .table tr { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 6px 14px; margin-bottom: 12px; }
  .table td { display: flex; justify-content: space-between; gap: 16px; padding: 8px 0; border-bottom: 1px dashed var(--line); text-align: right; }
  .table td::before { content: attr(data-label); color: var(--muted); font-size: .85rem; text-align: left; flex: none; }
  .table tr td:last-child { border-bottom: 0; }
  .table td.empty { justify-content: center; text-align: center; }
  .table .num { text-align: right; }
  .link-cell { max-width: none; min-width: 0; }
  .link-cell a { overflow: hidden; text-overflow: ellipsis; }
}

@media (max-width: 640px) {
  .container { padding: 0 16px; }
  .section { padding: 64px 0; }
  .section-head { margin-bottom: 36px; }
  .hero { padding: 40px 0 64px; }
  .hero-actions .btn { flex: 1 1 100%; }
  .grid-3, .price-grid { grid-template-columns: 1fr; }
  .price-grid { gap: 28px; }
  .steps { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .card, .price-card { padding: 22px; }
  .cta { padding-bottom: 64px; }
  .cta-box { border-radius: 22px; padding: 36px 20px; }
  .cta-box .btn { width: 100%; }
  .field-row { grid-template-columns: 1fr; gap: 0; }
  .tiles { gap: 10px; }
  .tile { padding: 14px; }
  .tile-value { font-size: 1.3rem; }
  .panel { padding: 18px; }
  .dash-user-text { display: none; }
  .amounts { grid-template-columns: repeat(2, 1fr); }
}

@media (hover: none) {
  .btn-primary:hover, .btn-light:hover, .card:hover { transform: none; }
  .card:hover { box-shadow: var(--shadow); border-color: var(--line); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0s !important; animation-duration: 0s !important; }
  .js .reveal { opacity: 1; transform: none; }
}
