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

:root {
  --night: #0d1712;      /* พื้นหลักโทนป่าลึก */
  --night-2: #13221a;
  --night-3: #1b2e24;
  --gold: #e0b44c;
  --gold-dark: #c99a2e;
  --forest: #1d4a37;
  --jade: #23a69a;
  --jade-soft: #e3f4f1;
  --sand: #f7f4ec;
  --ink: #1f2a24;
  --muted: #5f6d65;
  --on-dark: rgba(255, 255, 255, .78);
  --line: #dfe5df;
  --warn-soft: #fdf3e1;
  --bad: #c0392b;
  --bad-soft: #fbe9e7;
  --good: #2e7d4f;
  --good-soft: #e5f3ea;
  --line-green: #06c755;
  --radius: 16px;
  --shadow: 0 10px 30px rgba(0, 0, 0, .18);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'Sarabun', system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  color: #fff;
  background: var(--night);
}
h1, h2, h3, .brand, .btn { font-family: 'Kanit', 'Sarabun', sans-serif; }
h1, h2, h3 { line-height: 1.25; }
h2 { font-size: clamp(1.6rem, 3.4vw, 2.6rem); font-weight: 700; margin: 0 0 .4em; }
h2 .gold, h1 .gold, .gold-text {
  background: linear-gradient(100deg, #f7e2a0 0%, #e0b44c 30%, #b98a2c 55%, #f3d27a 75%, #e0b44c 100%);
  background-size: 220% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: shimmer 7s ease-in-out infinite;
}
@keyframes shimmer { 0%, 100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
h3 { font-size: 1.15rem; font-weight: 600; margin: 0 0 .3em; }
a { color: var(--gold); }
img { max-width: 100%; }
.wrap { width: min(1200px, 100% - 2.5rem); margin-inline: auto; }
.narrow { width: min(640px, 100% - 2rem); margin-inline: auto; }
.muted { color: var(--on-dark); }
.small { font-size: .9rem; }
.eyebrow { display: block; font: 400 .95rem 'Kanit', sans-serif; letter-spacing: .04em; color: var(--gold); margin-bottom: .4rem; }

/* ---------- header ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20;
  background: rgba(13, 23, 18, .92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(255, 255, 255, .06);
}
.topbar.over { position: absolute; left: 0; right: 0; background: linear-gradient(180deg, rgba(8, 14, 10, .75), rgba(8, 14, 10, 0)); border: 0; backdrop-filter: none; }
.topbar .wrap { display: flex; align-items: center; gap: 1rem; min-height: 72px; }
.brand { display: flex; align-items: center; gap: .7rem; text-decoration: none; color: #fff; font-weight: 600; font-size: 1.1rem; }
.brand img { width: 44px; height: 44px; object-fit: contain; }
.brand small { display: block; font-weight: 300; font-size: .8rem; color: var(--on-dark); }
.nav { margin-left: auto; display: flex; align-items: center; gap: 1.6rem; }
.nav a:not(.btn) { color: #fff; text-decoration: none; font: 500 1rem 'Kanit', sans-serif; text-shadow: 0 1px 8px rgba(0, 0, 0, .6); }
.nav a:not(.btn):hover { color: var(--gold); }
@media (max-width: 860px) { .nav a:not(.btn) { display: none; } }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: .75rem 1.5rem; border-radius: 999px; border: 0;
  font-weight: 600; font-size: 1rem; text-decoration: none; cursor: pointer;
  background: linear-gradient(135deg, #f3d27a, #e0b44c 45%, #c99a2e); color: #1a1a12;
  box-shadow: 0 6px 20px rgba(224, 180, 76, .25), inset 0 1px 0 rgba(255, 255, 255, .45);
  transition: transform .2s, box-shadow .2s, filter .2s;
}
.btn:hover { transform: translateY(-2px); filter: brightness(1.06); box-shadow: 0 10px 30px rgba(224, 180, 76, .4), inset 0 1px 0 rgba(255, 255, 255, .5); }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }
.btn.ghost { background: rgba(8, 14, 10, .35); color: #fff; box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .75); backdrop-filter: blur(6px); }
.btn.ghost:hover { background: rgba(255, 255, 255, .12); box-shadow: inset 0 0 0 2px #fff; }
.btn.dark { background: var(--forest); color: #fff; }
.btn.dark:hover { background: #163a2b; }
.btn.line { background: var(--line-green); color: #fff; font-size: 1.1rem; padding: .85rem 1.6rem; }
.btn.line:hover { background: #05a948; }
.btn.bad { background: var(--bad); color: #fff; }
.btn.sm { padding: .45rem 1rem; font-size: .92rem; }

/* ---------- hero (ชั้น: รูป → เงา → หิ่งห้อย → ตัวหนังสือ) ---------- */
.hero { position: relative; overflow: hidden; min-height: min(780px, 94vh); display: flex; align-items: center; background: var(--night-2); isolation: isolate; }
.hero-bg { position: absolute; inset: -8% 0 -8% 0; background: url('img/hero.jpg') center 45% / cover no-repeat; z-index: -3; will-change: transform; }
.hero-shade {
  position: absolute; inset: 0; z-index: -2;
  background:
    linear-gradient(90deg, rgba(8, 14, 10, .9) 0%, rgba(8, 14, 10, .6) 33%, rgba(8, 14, 10, .08) 58%, rgba(8, 14, 10, 0) 70%),
    radial-gradient(60% 50% at 18% 60%, rgba(35, 166, 154, .18), transparent 70%),
    linear-gradient(0deg, var(--night) 0%, rgba(13, 23, 18, 0) 22%);
}
.fireflies { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }
.hero .wrap { padding: 7rem 0 5rem; }
.hero-text { max-width: 600px; }
.hero h1 { font-size: clamp(2.6rem, 6.2vw, 4.9rem); font-weight: 800; line-height: 1.06; margin: .5rem 0 1.1rem; }
.hero p.lead { font-size: 1.22rem; color: rgba(255, 255, 255, .9); max-width: 32em; }
.hero .cta { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 2rem; }
.scroll-cue { position: absolute; left: 50%; bottom: 1.4rem; translate: -50% 0; width: 26px; height: 42px; border: 2px solid rgba(255, 255, 255, .5); border-radius: 14px; }
.scroll-cue::after { content: ''; position: absolute; left: 50%; top: 7px; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: var(--gold); animation: cue 1.8s ease-in-out infinite; }
@keyframes cue { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(14px); } }
@media (max-width: 760px) {
  .hero { align-items: flex-end; min-height: 88vh; }
  .hero-bg { background-image: url('img/hero-m.jpg'); background-position: center top; }
  .hero-shade { background: linear-gradient(0deg, var(--night) 0%, rgba(8, 14, 10, .82) 42%, rgba(8, 14, 10, .15) 75%, rgba(8, 14, 10, .45) 100%); }
  .hero .wrap { padding: 6rem 0 3.5rem; }
  .scroll-cue { display: none; }
}

/* ---------- sections ---------- */
section.block { position: relative; padding: 5.5rem 0; isolation: isolate; overflow: hidden; }
section.block.alt { background: var(--night-2); }
/* แสงออโรร่าจางๆ หลังแต่ละหัวข้อ สลับซ้าย-ขวา */
section.block::before {
  content: ''; position: absolute; z-index: -1; pointer-events: none;
  width: 70vw; height: 70vw; max-width: 900px; max-height: 900px; top: -20%; right: -20%;
  background: radial-gradient(closest-side, rgba(35, 166, 154, .16), rgba(35, 166, 154, 0));
  filter: blur(40px);
}
section.block.alt::before { right: auto; left: -25%; top: 10%; background: radial-gradient(closest-side, rgba(224, 180, 76, .11), rgba(224, 180, 76, 0)); }
section.block::after {
  content: ''; position: absolute; z-index: -1; pointer-events: none;
  width: 50vw; height: 50vw; max-width: 640px; max-height: 640px; bottom: -25%; left: 10%;
  background: radial-gradient(closest-side, rgba(63, 143, 95, .12), rgba(63, 143, 95, 0));
  filter: blur(40px);
}
/* เกรนฟิล์มทั้งหน้า */
body::after {
  content: ''; position: fixed; inset: 0; z-index: 100; pointer-events: none; opacity: .07; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.section-head { max-width: 980px; margin-bottom: 2.4rem; }
h1, h2, .hero p.lead, .section-head p { text-wrap: balance; }
.section-head p { color: var(--on-dark); margin: 0; }
.grid { display: grid; gap: 1.2rem; }
.card {
  background: #fff; color: var(--ink); border-radius: var(--radius);
  padding: 1.5rem; box-shadow: var(--shadow);
}
.card h2 { color: var(--forest); }
.card .muted { color: var(--muted); }
.card a { color: var(--jade); }

/* Leave No Trace — ตัวเลขเส้นขอบทอง */
.lnt { list-style: none; padding: 0; margin: 0; display: grid; gap: 1.4rem 1rem; grid-template-columns: repeat(7, 1fr); }
@media (max-width: 1000px) { .lnt { grid-template-columns: repeat(4, 1fr); } }
@media (max-width: 560px) { .lnt { grid-template-columns: repeat(2, 1fr); } }
.lnt li { border-top: 2px solid rgba(224, 180, 76, .5); padding-top: .7rem; }
.lnt b { display: block; font: 200 4rem/1 'Kanit', sans-serif; color: transparent; -webkit-text-stroke: 1.5px var(--gold); }
.lnt span { display: block; font: 400 1rem/1.4 'Kanit', sans-serif; margin-top: .5rem; }
.lnt small { display: block; font-size: .78rem; color: var(--on-dark); margin-top: .2rem; }

/* เกี่ยวกับ */
.about { display: grid; grid-template-columns: 1fr 1fr; gap: 3.5rem; align-items: center; }
@media (max-width: 860px) { .about { grid-template-columns: 1fr; gap: 2rem; } }
.about .pic { aspect-ratio: 4 / 3; border-radius: 24px; background: url('img/about.jpg') center / cover; box-shadow: var(--shadow); }
.about p { color: var(--on-dark); font-size: 1.08rem; }
.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: .8rem; margin: 1.4rem 0 1.8rem; }
@media (max-width: 520px) { .pillars { grid-template-columns: 1fr; } }
.pillars div { border: 1px solid rgba(224, 180, 76, .4); border-radius: 14px; padding: .9rem 1rem; font: 600 1rem 'Kanit', sans-serif; }
.pillars small { display: block; font: 400 .88rem 'Sarabun', sans-serif; color: var(--on-dark); }

/* ขั้นตอน */
.steps { counter-reset: step; display: grid; gap: 1rem; grid-template-columns: repeat(5, 1fr); }
@media (max-width: 1000px) { .steps { grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); } }
.step { position: relative; background: linear-gradient(160deg, rgba(255, 255, 255, .075), rgba(255, 255, 255, .015) 60%); border: 1px solid rgba(255, 255, 255, .09); backdrop-filter: blur(6px); border-radius: var(--radius); padding: 1.5rem 1.3rem 1.3rem; transition: transform .25s, border-color .25s, box-shadow .25s; }
.step::before {
  counter-increment: step; content: counter(step);
  display: grid; place-items: center; width: 2.6rem; height: 2.6rem; margin-bottom: .8rem;
  border-radius: 50%; background: var(--gold); color: #1a1a12;
  font: 700 1.2rem 'Kanit', sans-serif;
}
.step p { color: var(--on-dark); font-size: .95rem; margin: 0 0 .6rem; }
.step .where { display: inline-block; font: 400 .8rem 'Kanit', sans-serif; padding: .1rem .7rem; border-radius: 999px; background: rgba(255, 255, 255, .08); color: var(--on-dark); }
.step .where.ours { background: rgba(224, 180, 76, .18); color: var(--gold); }

/* FAQ */
details.faq { background: linear-gradient(160deg, rgba(255, 255, 255, .075), rgba(255, 255, 255, .015) 60%); border: 1px solid rgba(255, 255, 255, .09); backdrop-filter: blur(6px); border-radius: 12px; padding: 1rem 1.2rem; }
details.faq + details.faq { margin-top: .7rem; }
details.faq summary { cursor: pointer; font: 500 1.05rem 'Kanit', sans-serif; }
details.faq p { margin: .6rem 0 0; color: var(--on-dark); }

/* ติดต่อ */
.contact-list { display: flex; flex-wrap: wrap; gap: .8rem; }

footer.site { background: #08100c; color: var(--on-dark); padding: 2.2rem 0; font-size: .92rem; }

/* ---------- ฟอร์ม / หน้าสมาชิก (การ์ดขาวบนพื้นป่า) ---------- */
.page { padding: 2.4rem 0 4rem; min-height: calc(100vh - 72px); background: linear-gradient(180deg, rgba(13, 23, 18, .9), var(--night) 420px), url('img/hero.jpg') center top / cover no-repeat; }
.field { display: grid; gap: .3rem; margin-bottom: 1rem; }
.field label { font-weight: 600; }
.field .hint { font-size: .85rem; color: var(--muted); }
input[type=text], input[type=tel], input[type=email], input[type=number], input[type=password], input[type=url], input[type=date], input[type=time], select, textarea {
  width: 100%; padding: .7rem .9rem; border: 1.5px solid var(--line); border-radius: 10px;
  font: inherit; background: #fff; color: var(--ink);
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(224, 180, 76, .25); }
.row2 { display: grid; gap: 0 1rem; grid-template-columns: 1fr 1fr; }
@media (max-width: 520px) { .row2 { grid-template-columns: 1fr; } }
.check { display: flex; gap: .6rem; align-items: flex-start; }
.check input { margin-top: .35rem; width: 1.1rem; height: 1.1rem; }

.notice { border-radius: 12px; padding: .9rem 1.1rem; margin-bottom: 1rem; color: var(--ink); }
.notice.info { background: var(--jade-soft); }
.notice.warn { background: var(--warn-soft); }
.notice.bad { background: var(--bad-soft); color: var(--bad); }
.notice.good { background: var(--good-soft); color: var(--good); }

.pdpa { max-height: 9.5rem; overflow-y: auto; font-size: .88rem; color: var(--muted); background: var(--sand); border-radius: 10px; padding: .8rem 1rem; margin-bottom: .8rem; }

/* แถบความคืบหน้า (อยู่บนพื้นเข้ม) */
.progress { display: flex; gap: .3rem; margin: 0 0 1.5rem; padding: 0; list-style: none; }
.progress li { flex: 1; text-align: center; font: 400 .8rem 'Kanit', sans-serif; color: var(--on-dark); }
.progress li::before { content: ''; display: block; height: 6px; border-radius: 3px; background: rgba(255, 255, 255, .15); margin-bottom: .35rem; }
.progress li.done::before { background: rgba(224, 180, 76, .6); }
.progress li.now { color: var(--gold); font-weight: 600; }
.progress li.now::before { background: var(--gold); }

.profile-head { display: flex; align-items: center; gap: .8rem; margin-bottom: 1rem; }
.profile-head img { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; background: rgba(255, 255, 255, .15); }

.drop {
  display: grid; place-items: center; gap: .4rem; text-align: center;
  border: 2px dashed var(--line); border-radius: var(--radius); padding: 1.8rem 1rem;
  cursor: pointer; background: #fff; transition: border-color .15s;
}
.drop:hover, .drop.over { border-color: var(--gold); }
.drop img.preview { max-height: 260px; border-radius: 8px; }
.big-icon { font-size: 2.6rem; line-height: 1; }

/* แบบทดสอบ */
.quiz { padding-left: 1.4rem; margin: 0; }
.quiz > li { padding: 1rem 0; border-bottom: 1px solid var(--line); }
.quiz > li::marker { font-weight: 700; color: var(--forest); }
.quiz p { margin: 0 0 .6rem; font-weight: 600; }
.choice { display: flex; gap: .6rem; align-items: flex-start; padding: .55rem .8rem; border-radius: 10px; cursor: pointer; }
.choice:hover { background: var(--sand); }
.choice input { margin-top: .35rem; width: 1.05rem; height: 1.05rem; flex: none; accent-color: var(--forest); }
.choice:has(input:checked) { background: var(--good-soft); }
.quiz-submit { position: sticky; bottom: 0; background: #fff; padding: .9rem 0 .3rem; margin: 0; display: flex; gap: .8rem; align-items: center; }

/* รอบกิจกรรม */
.round { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .9rem 1rem; border: 1.5px solid var(--line); border-radius: 12px; }
.round + .round { margin-top: .6rem; }
.round.full { opacity: .6; }
.round-act { display: flex; align-items: center; gap: .7rem; flex: none; }
.seats { font: 600 .9rem 'Kanit', sans-serif; color: var(--forest); }
@media (max-width: 520px) { .round { flex-direction: column; align-items: stretch; } .round-act { justify-content: space-between; } }
.booked-box { display: grid; gap: .2rem; background: var(--good-soft); border-radius: 12px; padding: 1rem 1.2rem; margin-bottom: .8rem; }
.booked-box b { font: 600 1.25rem 'Kanit', sans-serif; color: var(--forest); }

/* ---------- QR เช็คอิน / แบบประเมิน / ใบประกาศ ---------- */
.qr-box { display: flex; gap: 1rem; align-items: center; margin: .2rem 0 .8rem; color: var(--ink); }
.qr-box img { width: 168px; height: 168px; image-rendering: pixelated; background: #fff; border-radius: 10px; flex: none; }
.qr-box b { font: 600 1.05rem 'Kanit', sans-serif; color: var(--forest); }
.qr-box .code { font: 600 1.6rem/1.2 'Kanit', monospace; letter-spacing: .25em; color: var(--forest); margin-top: .4rem; }
@media (max-width: 480px) { .qr-box { flex-direction: column; text-align: center; } .qr-box img { width: 200px; height: 200px; } }
.scale { display: flex; gap: .4rem; }
.scale label { flex: 1; max-width: 3.4rem; cursor: pointer; }
.scale input { position: absolute; opacity: 0; }
.scale span { display: block; text-align: center; padding: .45rem 0; border-radius: 10px; border: 1.5px solid var(--line); font: 600 1rem 'Kanit', sans-serif; color: var(--forest); }
.scale label:hover span { border-color: var(--gold); }
.scale input:checked + span { background: var(--forest); border-color: var(--forest); color: #fff; }
.scale input:focus-visible + span { outline: 2px solid var(--gold); outline-offset: 2px; }
.survey { margin-top: 1rem; border-top: 1px solid var(--line); padding-top: .6rem; }
.cert-view { margin-top: 1rem; }
.cert-view img { display: block; width: 100%; border-radius: 8px; box-shadow: 0 6px 20px rgba(0, 0, 0, .18); }

/* ---------- หลังบ้าน ---------- */
.tabs { display: flex; gap: .4rem; flex-wrap: wrap; margin-bottom: 1.2rem; }
.tabs button { border: 0; padding: .55rem 1.1rem; border-radius: 999px; background: var(--night-3); font: 600 .95rem 'Kanit', sans-serif; color: var(--on-dark); cursor: pointer; }
.tabs button.on { background: var(--gold); color: #1a1a12; }
.badge { display: inline-block; min-width: 1.5em; padding: 0 .4em; border-radius: 999px; background: var(--bad); color: #fff; font-size: .78rem; text-align: center; margin-left: .3rem; }
.stats { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.2rem; }
.stats .card { flex: 1; min-width: 150px; padding: 1rem 1.2rem; }
.stats b { display: block; font: 700 1.8rem 'Kanit', sans-serif; color: var(--forest); }

.review { display: grid; grid-template-columns: 220px 1fr; gap: 1.2rem; }
.review + .review { margin-top: 1rem; }
@media (max-width: 640px) { .review { grid-template-columns: 1fr; } }
.review .thumb { display: grid; place-items: center; min-height: 160px; border-radius: 10px; background: var(--sand); overflow: hidden; text-decoration: none; color: var(--forest); font-weight: 600; }
.review .thumb img { width: 100%; height: 100%; object-fit: contain; }
.review dl { display: grid; grid-template-columns: auto 1fr; gap: .15rem .8rem; margin: 0 0 .8rem; }
.review dt { color: var(--muted); }
.review dd { margin: 0; }
.actions { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.actions input { flex: 1; min-width: 180px; }
.actions input[type=checkbox] { flex: none; min-width: 0; }
.empty { text-align: center; padding: 2.5rem 1rem; color: var(--muted); }
.btn.ghost-dark { background: transparent; color: var(--forest); box-shadow: inset 0 0 0 2px var(--line); }
.row4 { display: grid; gap: 0 1rem; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
#q-summary { color: var(--on-dark); margin: 1.2rem 0 .6rem; }
#round-list > .card, #q-list > .card { margin-top: 1rem; }
.round-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .6rem 1rem; align-items: center; }
.round-head h3 { margin: 0; }
.cancel-round { margin-top: .8rem; padding: .8rem; border-radius: 12px; background: var(--bad-soft); }
.tag { display: inline-block; padding: .1rem .7rem; border-radius: 999px; font: 600 .8rem 'Kanit', sans-serif; background: var(--sand); color: var(--muted); }
.tag.open { background: var(--good-soft); color: var(--good); }
.tag.full { background: var(--warn-soft); color: #8a5a00; }
.people { width: 100%; border-collapse: collapse; margin-top: .8rem; font-size: .92rem; }
.people th, .people td { text-align: left; padding: .5rem .4rem; border-top: 1px solid var(--line); vertical-align: top; }
.people tr.cancelled td { color: var(--muted); text-decoration: line-through; }
.people tr.cancelled td:last-child { text-decoration: none; }
@media (max-width: 640px) { .people thead { display: none; } .people td { display: block; border: 0; padding: .1rem 0; } .people tr { display: block; border-top: 1px solid var(--line); padding: .5rem 0; } }
.q-item ol { list-style: none; padding: 0; margin: .4rem 0 0; }
.q-item li.ans { color: var(--good); font-weight: 700; }
.q-item.off { opacity: .55; }
.toast { position: fixed; left: 50%; bottom: 1.5rem; transform: translateX(-50%); background: #fff; color: var(--ink); padding: .7rem 1.3rem; border-radius: 999px; z-index: 50; box-shadow: var(--shadow); font-weight: 600; }

/* เตรียมตัว */
.kit { display: grid; gap: 1rem; grid-template-columns: repeat(4, 1fr); }
@media (max-width: 1000px) { .kit { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .kit { grid-template-columns: 1fr; } }
.kit-card { background: linear-gradient(160deg, rgba(255, 255, 255, .075), rgba(255, 255, 255, .015) 60%); border: 1px solid rgba(255, 255, 255, .09); backdrop-filter: blur(6px); border-radius: var(--radius); padding: 1.4rem 1.3rem; transition: transform .25s, border-color .25s, box-shadow .25s; }
.kit-card i { display: grid; place-items: center; width: 3rem; height: 3rem; border-radius: 14px; background: rgba(224, 180, 76, .15); font-style: normal; font-size: 1.5rem; margin-bottom: .8rem; }
.kit-card ul { list-style: none; padding: 0; margin: .4rem 0 0; }
.kit-card li { position: relative; padding-left: 1.5rem; color: var(--on-dark); font-size: .95rem; margin-bottom: .35rem; }
.kit-card li::before { content: '✓'; position: absolute; left: 0; color: var(--gold); font-weight: 700; }
.note { margin: 1.4rem 0 0; color: var(--on-dark); font-size: .95rem; }

/* การเดินทาง */
.travel { display: grid; grid-template-columns: 1.1fr 1fr; gap: 1.6rem; align-items: start; }
@media (max-width: 860px) { .travel { grid-template-columns: 1fr; } }
.map iframe { width: 100%; aspect-ratio: 4 / 3; border: 0; border-radius: var(--radius); background: var(--night-3); display: block; margin-bottom: .8rem; }
.travel-info p { color: var(--on-dark); }
.travel-info .small a { color: var(--gold); }
.bus { display: grid; grid-template-columns: 2fr 1fr; gap: .8rem; margin-top: .8rem; }
.bus table, table.fee { width: 100%; border-collapse: collapse; font-size: .95rem; }
.bus th { font: 500 .85rem 'Kanit', sans-serif; color: var(--gold); padding: .3rem; border-bottom: 1px solid rgba(224, 180, 76, .4); }
.bus td { text-align: center; padding: .28rem; border-bottom: 1px solid rgba(255, 255, 255, .06); font-variant-numeric: tabular-nums; }
table.fee { margin: .8rem 0 .4rem; }
table.fee td { padding: .4rem 0; border-bottom: 1px solid rgba(255, 255, 255, .08); color: var(--on-dark); }
table.fee td:last-child { text-align: right; color: #fff; font-weight: 600; white-space: nowrap; }
@media (min-width: 861px) { .map { position: sticky; top: 90px; } }
.bus td { height: 2.3rem; }
.store { display: flex; flex-wrap: wrap; gap: .5rem; }

.step:hover, .kit-card:hover { transform: translateY(-4px); border-color: rgba(224, 180, 76, .45); box-shadow: 0 16px 40px rgba(0, 0, 0, .35), 0 0 0 1px rgba(224, 180, 76, .15); }
.step::before { background: linear-gradient(135deg, #f3d27a, #c99a2e); box-shadow: 0 0 20px rgba(224, 180, 76, .35); }
.lnt li { transition: border-color .3s; }
.lnt li:hover b { color: var(--gold); -webkit-text-stroke-color: var(--gold); text-shadow: 0 0 24px rgba(224, 180, 76, .45); }
.lnt b { transition: color .3s, text-shadow .3s; }
.about .pic { transition: transform .4s; }
.about .pic:hover { transform: scale(1.015); }
.eyebrow { display: inline-flex; align-items: center; gap: .5rem; }
.eyebrow::before { content: ''; width: 1.8rem; height: 1px; background: linear-gradient(90deg, transparent, var(--gold)); }

/* ลดการเคลื่อนไหวตามที่ผู้ใช้ตั้งค่าไว้ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .fireflies, .scroll-cue { display: none; }
}

/* ---------- แดชบอร์ดหลังบ้าน (โทนป่าเข้ม + ทอง กระจกฝ้า) ---------- */
.admin, #v-dashboard { --glass-line: rgba(255, 255, 255, .08); --dim: rgba(255, 255, 255, .55); --track: rgba(255, 255, 255, .06); --goldbar: linear-gradient(90deg, #b8892a, #e0b44c 55%, #f3d68a); }
.glass {
  position: relative; padding: 1.4rem 1.5rem; border-radius: 22px; color: #fff;
  background: linear-gradient(160deg, rgba(255, 255, 255, .075), rgba(255, 255, 255, .018) 55%, rgba(224, 180, 76, .03));
  border: 1px solid var(--glass-line); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 24px 60px -20px rgba(0, 0, 0, .55), inset 0 1px 0 rgba(255, 255, 255, .06);
  transition: border-color .35s, transform .35s cubic-bezier(.2, .8, .2, 1), box-shadow .35s;
  animation: dash-rise .7s cubic-bezier(.2, .8, .2, 1) both; animation-delay: calc(var(--i, 0) * 70ms);
}
.glass:hover { border-color: rgba(224, 180, 76, .28); transform: translateY(-2px); box-shadow: 0 30px 70px -22px rgba(0, 0, 0, .6), 0 0 0 1px rgba(224, 180, 76, .06), inset 0 1px 0 rgba(255, 255, 255, .08); }
@keyframes dash-rise { from { opacity: 0; transform: translateY(14px); } }
@media (prefers-reduced-motion: reduce) { .glass { animation: none; } #v-dashboard * { transition: none !important; } }

.dash-tiles { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); margin-bottom: 1rem; }
.dash-tiles.mini { gap: .6rem; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); margin: .2rem 0 0; }
.tile span { display: block; font-size: .85rem; color: var(--dim); }
.tile b {
  display: block; font: 700 2.3rem/1.15 'Kanit', sans-serif; letter-spacing: -.01em;
  background: linear-gradient(135deg, #fff1c4, #e0b44c 60%, #c99a2e); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.tile b small { font-size: .5em; font-weight: 400; -webkit-text-fill-color: var(--dim); }
.tile > small { display: block; font-size: .8rem; color: var(--dim); margin-top: .1rem; }
.dash-tiles.mini .tile { padding: .75rem .9rem; border-radius: 14px; background: rgba(255, 255, 255, .035); border: 1px solid rgba(255, 255, 255, .05); }
.dash-tiles.mini .tile b { font-size: 1.45rem; }

.dash-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(420px, 1fr)); margin-bottom: 1rem; }
@media (max-width: 520px) { .dash-grid { grid-template-columns: 1fr; } .glass { padding: 1.1rem 1.1rem; } }
.dash-card { margin-bottom: 1rem; }
.dash-grid .dash-card { margin-bottom: 0; }
.dash-card h3 { margin: 0 0 .3rem; font: 500 1.15rem 'Kanit', sans-serif; display: flex; align-items: center; gap: .5rem; }
.dash-card h3 .ic { display: grid; place-items: center; width: 2rem; height: 2rem; border-radius: 10px; background: rgba(224, 180, 76, .14); font-size: 1rem; }
.dash-card h4 { margin: 1.3rem 0 .3rem; font: 500 .98rem 'Kanit', sans-serif; color: rgba(255, 255, 255, .9); }
.dash-card .note { font-size: .82rem; color: var(--dim); margin: 0 0 .8rem; }
.dash-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .6rem; }
.dash-head select { width: auto; background: rgba(255, 255, 255, .06); color: #fff; border: 1px solid rgba(255, 255, 255, .14); border-radius: 999px; padding: .45rem 1rem; }
.dash-head select option { color: var(--ink); }
.dash-foot { color: var(--dim); }
.dash-foot a { color: var(--gold); }

.todo { display: flex; justify-content: space-between; align-items: center; gap: 1rem; border-radius: 14px; padding: .85rem 1rem; background: linear-gradient(120deg, rgba(224, 180, 76, .18), rgba(224, 180, 76, .05)); border: 1px solid rgba(224, 180, 76, .25); }
.todo b { font: 700 1.5rem 'Kanit', sans-serif; color: var(--gold); }
.ok-line { color: var(--dim); font-size: .9rem; }
.soon { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .6rem .2rem; border-top: 1px solid rgba(255, 255, 255, .06); }
.soon b { font-weight: 600; }
.soon .when { font-size: .82rem; color: var(--dim); }
.soon.warn { background: rgba(240, 160, 60, .09); margin: 0 -.6rem; padding: .6rem .8rem; border-radius: 12px; border-top-color: transparent; }
.warn-text { color: #f2bd6b; font-size: .82rem; }
.soon-fill { display: flex; align-items: center; gap: .6rem; flex: 0 0 150px; font-weight: 600; }
.soon-fill .hbar-track { flex: 1; }

.hbars { display: grid; gap: .55rem; }
.hbar { display: grid; grid-template-columns: minmax(0, 11rem) 1fr auto; gap: .7rem; align-items: center; font-size: .9rem; border-radius: 8px; }
.hbar-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: rgba(255, 255, 255, .85); }
.hbar-track { display: block; height: 10px; background: var(--track); border-radius: 999px; overflow: hidden; }
.hbar-track i { display: block; height: 100%; width: 0; background: var(--goldbar); border-radius: 999px; box-shadow: 0 0 12px rgba(224, 180, 76, .35); transition: width 1.1s cubic-bezier(.2, .8, .2, 1); }
.in .hbar-track i { width: var(--w); }
.hbar-val { font-weight: 600; min-width: 3.5rem; text-align: right; white-space: nowrap; }
.hbar-val em { font-style: normal; font-weight: 400; color: var(--dim); font-size: .85em; }
.hbar:hover .hbar-label { color: #fff; }
.hbar:hover .hbar-track i { filter: brightness(1.15); }

.cols { display: flex; align-items: flex-end; gap: 8px; height: 210px; padding-top: .5rem; margin: .6rem 0 1rem; }
.col { flex: 1; display: grid; grid-template-rows: auto 1fr auto; height: 100%; text-align: center; min-width: 0; }
.col-val { font-size: .8rem; font-weight: 600; color: rgba(255, 255, 255, .9); }
.col-bar { display: flex; align-items: flex-end; justify-content: center; border-bottom: 1px solid rgba(255, 255, 255, .1); }
.col-bar i { display: block; width: min(100%, 46px); height: 0; border-radius: 10px 10px 3px 3px; background: linear-gradient(180deg, #f3d68a, #e0b44c 45%, rgba(201, 154, 46, .55)); box-shadow: 0 -4px 18px rgba(224, 180, 76, .25); transition: height 1s cubic-bezier(.2, .8, .2, 1); }
.in .col-bar i { height: var(--h); }
.col:hover .col-bar i { filter: brightness(1.15); }
.col-label { font-size: .75rem; color: var(--dim); padding-top: .35rem; white-space: nowrap; height: 1.7rem; line-height: 1.4; overflow: visible; }
.cols.dense .col-val { font-size: .68rem; }
.cols.dense .col-label { font-size: .62rem; }

.table-scroll { overflow-x: auto; }
.dtable { width: 100%; border-collapse: collapse; font-size: .88rem; }
.dtable th { font-weight: 500; color: var(--dim); }
.dtable th, .dtable td { padding: .55rem .6rem; border-top: 1px solid rgba(255, 255, 255, .06); white-space: nowrap; text-align: right; }
.dtable th:first-child, .dtable td:first-child { text-align: left; }
.dtable tbody tr:hover td { background: rgba(255, 255, 255, .03); }
.dtable tfoot th { color: var(--gold); font-weight: 600; border-top: 1px solid rgba(255, 255, 255, .18); }

.heat { display: grid; grid-template-columns: 2.2rem repeat(24, 1fr); gap: 3px; font-size: .7rem; color: var(--dim); }
.heat-h { text-align: center; }
.heat-d { align-self: center; }
.heat-c { aspect-ratio: 1; background: rgba(255, 255, 255, .04); border-radius: 4px; min-width: 6px; transition: transform .2s; }
.heat-c:hover { transform: scale(1.35); }

.split { display: flex; gap: 2px; height: 12px; border-radius: 999px; overflow: hidden; background: var(--track); margin: .4rem 0 .5rem; }
.split i { display: block; height: 100%; }
.legend { display: flex; flex-wrap: wrap; gap: .3rem 1rem; font-size: .82rem; color: var(--dim); }
.legend span::before { content: ''; display: inline-block; width: .7em; height: .7em; border-radius: 3px; margin-right: .35em; background: var(--c); vertical-align: -.05em; }

/* ตัวเลขโครงการบนหน้าแรก */
.impact { background: linear-gradient(180deg, var(--night), var(--night-2)); padding: 2.2rem 0; border-top: 1px solid rgba(224, 180, 76, .12); border-bottom: 1px solid rgba(255, 255, 255, .05); }
.impact-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 1rem; text-align: center; }
.impact-row b { display: block; font: 700 clamp(2rem, 4.5vw, 3rem)/1.1 'Kanit', sans-serif; background: linear-gradient(135deg, #fff1c4, #e0b44c 60%, #c99a2e); -webkit-background-clip: text; background-clip: text; color: transparent; }
.impact-row span { font: 400 .95rem 'Kanit', sans-serif; color: var(--on-dark); }

/* ---------- หลังบ้านทุกแท็บ: โทนเดียวกับแดชบอร์ด (การ์ดขาว → กระจกฝ้า) ---------- */
.admin .card {
  color: #fff; border-radius: 22px; padding: 1.4rem 1.5rem;
  background: linear-gradient(160deg, rgba(255, 255, 255, .075), rgba(255, 255, 255, .018) 55%, rgba(224, 180, 76, .03));
  border: 1px solid var(--glass-line); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 24px 60px -20px rgba(0, 0, 0, .55), inset 0 1px 0 rgba(255, 255, 255, .06);
  transition: border-color .35s, box-shadow .35s;
  animation: dash-rise .6s cubic-bezier(.2, .8, .2, 1) both;
}
.admin .card:hover { border-color: rgba(224, 180, 76, .22); }
.admin .card h2, .admin .card h3 { color: #fff; }
.admin .card h2 { font-size: 1.5rem; font-weight: 600; }
.admin .card .muted, .admin .muted, .admin .hint, .admin .field .hint { color: var(--dim); }
.admin .card a { color: var(--gold); }
.admin .empty { color: var(--dim); }

/* ฟอร์มบนพื้นเข้ม */
.admin input[type=text], .admin input[type=tel], .admin input[type=email], .admin input[type=number], .admin input[type=password],
.admin input[type=url], .admin input[type=date], .admin input[type=time], .admin select, .admin textarea {
  background: rgba(255, 255, 255, .05); color: #fff; border: 1px solid rgba(255, 255, 255, .14); border-radius: 12px;
  transition: border-color .2s, background .2s, box-shadow .2s;
}
.admin input::placeholder, .admin textarea::placeholder { color: rgba(255, 255, 255, .38); }
.admin input:focus, .admin select:focus, .admin textarea:focus { background: rgba(255, 255, 255, .08); border-color: var(--gold); box-shadow: 0 0 0 3px rgba(224, 180, 76, .18); }
.admin select option { color: var(--ink); background: #fff; }
.admin input[type=date]::-webkit-calendar-picker-indicator, .admin input[type=time]::-webkit-calendar-picker-indicator { filter: invert(1) opacity(.7); }
.admin .check input { accent-color: var(--gold); }
.admin .btn.ghost-dark { color: #fff; background: rgba(255, 255, 255, .04); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .22); }
.admin .btn.ghost-dark:hover { box-shadow: inset 0 0 0 1px var(--gold); color: var(--gold); }
.admin .btn.bad { background: linear-gradient(135deg, #d4553f, #a8321f); box-shadow: 0 8px 22px -8px rgba(192, 57, 43, .7); }

/* ข้อความแจ้ง */
.admin .notice.bad { background: rgba(192, 57, 43, .16); color: #ffb4a6; border: 1px solid rgba(192, 57, 43, .3); }
.admin .notice.good { background: rgba(46, 125, 79, .18); color: #9fe0b7; }
.admin .notice.warn { background: rgba(224, 180, 76, .14); color: #f3d68a; }

/* การ์ดตรวจใบรับรอง */
.admin .review .thumb { background: rgba(255, 255, 255, .04); color: var(--gold); border: 1px solid rgba(255, 255, 255, .06); }
.admin .review dt { color: var(--dim); }
.admin .review dd a { color: var(--gold); }

/* รอบกิจกรรม + ตารางรายชื่อ */
.admin .tag { background: rgba(255, 255, 255, .08); color: var(--dim); }
.admin .tag.open { background: rgba(46, 125, 79, .25); color: #9fe0b7; }
.admin .tag.full { background: rgba(224, 180, 76, .2); color: #f3d68a; }
.admin .people th { color: var(--dim); font-weight: 500; }
.admin .people th, .admin .people td { border-top-color: rgba(255, 255, 255, .07); }
.admin .people tbody tr:hover td { background: rgba(255, 255, 255, .03); }
.admin .people tr.cancelled td { color: rgba(255, 255, 255, .4); }
.admin .people a { color: var(--gold); }
.admin .cancel-round { background: rgba(192, 57, 43, .12); border: 1px solid rgba(192, 57, 43, .25); }

/* คลังข้อสอบ */
.admin .q-item li { color: rgba(255, 255, 255, .78); padding: .1rem 0; }
.admin .q-item li.ans { color: #f3d68a; }
.admin .q-item.off { opacity: .45; }

/* snap ของเบราว์เซอร์ (ใช้เมื่อไม่มี Lenis) */
html.snap-css { scroll-snap-type: y proximity; }
html.snap-css .hero, html.snap-css section.block { scroll-snap-align: start; }

/* เช็คอินวันงาน */
.scan-box { position: relative; max-width: 420px; margin: 0 0 1rem; border-radius: 18px; overflow: hidden; background: #000; }
.scan-box video { display: block; width: 100%; }
.scan-frame { position: absolute; inset: 18%; border: 3px solid var(--gold); border-radius: 18px; box-shadow: 0 0 0 999px rgba(0, 0, 0, .28); pointer-events: none; }
.ci-flash { font-size: 1.15rem; animation: dash-rise .35s ease-out both; }
.ci-count { font: 600 1.4rem 'Kanit', sans-serif; color: var(--gold); }
#ci-code { text-transform: uppercase; letter-spacing: .2em; font-family: 'Kanit', monospace; }
.sq-row { margin-bottom: .5rem; }
.sq-row.off { opacity: .5; }
.sig-box { margin-top: 1.6rem; padding-top: 1rem; border-top: 1px solid rgba(255, 255, 255, .1); }
.sig-box img#sig-img { display: block; max-width: 280px; background: #fbf7ec; border-radius: 12px; padding: .6rem 1rem; margin-bottom: .6rem; }
.comments { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.comments li { background: rgba(255, 255, 255, .04); border-radius: 12px; padding: .6rem .8rem; font-size: .92rem; white-space: pre-line; }
.comments small { display: block; color: var(--dim); font-size: .78rem; margin-top: .2rem; }
#ci-code:placeholder-shown { letter-spacing: normal; text-transform: none; font-family: inherit; }
/* หน้าตรวจสอบใบประกาศ /v/<เลขที่> */
.verify { display: grid; grid-template-columns: 6.5rem 1fr; gap: .45rem 1rem; margin: 0; color: var(--ink); }
.verify dt { color: var(--muted); }
.verify dd { margin: 0; }

/* รายชื่อรอบ: ข้อมูลสุขภาพ (S10) */
.people .health { margin-top: .3rem; padding: .2rem .5rem; border-radius: 6px; background: var(--warn-soft); color: #8a5a00; font-size: .85rem; }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: .3rem 1.2rem; margin: .8rem 0; }
.kv dt { color: var(--dim); }
.kv dd { margin: 0; }

/* แถบเว็บทดสอบ (common.js) */
.staging-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 1000; pointer-events: none; padding: .4rem 1rem; background: #e8590c; color: #fff; font: 600 .9rem 'Kanit', sans-serif; text-align: center; }

/* หลักสูตรออนไลน์ (หน้าสมาชิก) */
.lessons { list-style: none; padding: 0; margin: 1rem 0 0; display: grid; gap: .6rem; }
.lessons button { width: 100%; display: flex; gap: .9rem; align-items: center; text-align: left; padding: .9rem 1rem; border-radius: 12px; border: 1px solid var(--line); background: #fff; font: inherit; color: inherit; cursor: pointer; }
.lessons li.open button { border-color: var(--jade); box-shadow: 0 0 0 3px var(--jade-soft); }
.lessons li.done button { background: var(--sand); }
.lessons li.locked button { opacity: .55; cursor: not-allowed; }
.lessons small { display: block; color: var(--muted); }
.lessons .ls-icon { font-size: 1.5rem; }
.lessons .ls-sum { text-align: right; }
.video-box { position: relative; aspect-ratio: 16 / 9; border-radius: 12px; overflow: hidden; background: #000; }
.video-box iframe, .video-box > div { position: absolute; inset: 0; width: 100%; height: 100%; }
.slide-box img { display: block; width: 100%; border-radius: 12px; background: #13251d; }
.slide-nav { justify-content: center; margin-top: .6rem; }
.lesson-meter { display: flex; align-items: center; gap: .8rem; margin: 1rem 0 .4rem; }
.lesson-meter .hbar-track { flex: 1; background: var(--line); }
.lesson-meter .hbar-track i { width: var(--w); background: var(--jade); box-shadow: none; transition: width .4s; }
/* ปุ่มเข้ากลุ่ม LINE ของรอบ (หน้าสมาชิก) */
.group-box { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; justify-content: space-between; }
/* แถบชวนโหลดหน้าใหม่เมื่อมี deploy ระหว่างเปิดหน้าค้าง (common.js checkVersion) */
.new-version { position: sticky; top: 0; z-index: 1001; display: flex; gap: .8rem; justify-content: center; align-items: center; padding: .55rem 1rem; background: #1f6feb; color: #fff; font: 600 .95rem 'Kanit', sans-serif; }
.new-version button { border: 0; border-radius: 999px; padding: .3rem 1rem; background: #fff; color: #1f6feb; font: inherit; cursor: pointer; }

/* ป็อปอัพผลสแกนเช็คอิน (หลังบ้าน) */
.ci-modal { position: fixed; inset: 0; z-index: 2000; display: grid; place-items: center; padding: 1.2rem; background: rgba(6, 14, 10, .78); backdrop-filter: blur(4px); }
.ci-modal-box { width: min(420px, 100%); padding: 1.8rem 1.4rem; border-radius: 22px; text-align: center; background: #fff; color: #1f2a24; box-shadow: 0 20px 60px rgba(0, 0, 0, .45); animation: dash-rise .25s ease-out both; border-top: 10px solid #2f9e44; }
.ci-modal-box.warn { border-top-color: #f59f00; }
.ci-modal-box.bad { border-top-color: #e03131; }
.ci-m-icon { font-size: 4rem; line-height: 1; }
.ci-modal-box h2 { margin: .5rem 0; font-size: 1.6rem; color: #2f9e44; }
.ci-modal-box.warn h2 { color: #c77700; }
.ci-modal-box.bad h2 { color: #e03131; }
.ci-modal-box p { display: grid; gap: .35rem; margin: 0 0 1.2rem; font-size: 1.05rem; }
.ci-m-name { font-size: 1.35rem; }
.ci-m-count { display: inline-block; justify-self: center; padding: .2rem .9rem; border-radius: 999px; background: #ebfbee; color: #2b8a3e; font-weight: 600; }
.ci-modal-box .btn { width: 100%; font-size: 1.1rem; padding: .9rem; }
