/* bonbit website lab — shared tokens and primitives (brand book v1 + app design tokens). */
@font-face { font-family: "Outfit"; font-weight: 500; font-display: swap; src: url("fonts/outfit-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Outfit"; font-weight: 600; font-display: swap; src: url("fonts/outfit-latin-600-normal.woff2") format("woff2"); }

:root {
  --bg: #f5f7f4; --surface: #fff; --ink: #12261d; --muted: #5c6d63; --primary: #087f5b; --primary-pressed: #066348;
  --primary-soft: #e4f4eb; --forest: #062d23; --night: #0c4934; --card-end: #176344; --light-green: #8ccb3f;
  --lime: #d2f87a; --mint: #bfe8d0; --line: #dce5dd; --warning: #8a5300; --warning-soft: #fff1d6; --success: #146c43; --success-soft: #e7f5ec;
  --grad: linear-gradient(135deg, #062d23 0%, #0c4934 58%, #176344 100%);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --display: "Outfit", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --text: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans Thai", sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--text); color: var(--ink); background: var(--bg); font-size: 17px; line-height: 1.55; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
h1, h2, h3 { font-family: var(--display); font-weight: 600; letter-spacing: -0.025em; line-height: 1.06; margin: 0; }
h1 { font-size: clamp(40px, 6.4vw, 84px); }
h2 { font-size: clamp(30px, 4vw, 52px); }
h3 { font-size: 22px; letter-spacing: -0.015em; line-height: 1.2; }
p { margin: 0; }
a { color: inherit; text-decoration: none; }
.wrap { width: min(1120px, 100% - 40px); margin-inline: auto; }
.muted { color: var(--muted); }
.eyebrow { font-size: 13px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--primary); }
.on-dark .eyebrow, .eyebrow.on-dark { color: var(--mint); }
.lead { font-size: clamp(17px, 1.5vw, 21px); color: var(--muted); max-width: 34em; }
.on-dark { color: #fff; }
.on-dark .lead, .on-dark .muted { color: var(--mint); }
.tnum { font-variant-numeric: tabular-nums; }

/* nav */
.nav { position: fixed; inset: 0 0 auto 0; z-index: 50; }
.nav-in { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.nav .logo { display: inline-flex; align-items: center; gap: 9px; font-family: var(--display); font-weight: 600; font-size: 25px; letter-spacing: -0.024em; }
.nav { transition: background 300ms var(--ease); }
.nav.glass, .nav.scrolled { background: rgba(245, 247, 244, 0.86); -webkit-backdrop-filter: blur(20px) saturate(140%); backdrop-filter: blur(20px) saturate(140%); border-bottom: 1px solid rgba(220, 229, 221, 0.7); }
.nav-links { display: flex; align-items: center; gap: 26px; font-size: 15px; font-weight: 600; }
.nav-links a.t { opacity: 0.78; }
.nav-links a.t:hover { opacity: 1; }
@media (max-width: 720px) { .nav-links a.t { display: none; } }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 56px; padding: 0 26px; border-radius: 18px; font-size: 17px; font-weight: 600; border: 0; cursor: pointer; font-family: inherit; transition: transform 140ms var(--ease), background-color 140ms var(--ease); }
.btn:active { transform: scale(0.98); }
.btn.primary { background: var(--primary); color: #fff; }
.btn.primary:hover { background: var(--primary-pressed); }
.btn.secondary { background: #fff; color: var(--ink); border: 1px solid var(--line); }
.btn.lime { background: var(--lime); color: var(--forest); }
.btn.ghost-dark { background: rgba(255, 255, 255, 0.08); color: #fff; border: 1px solid rgba(255, 255, 255, 0.35); }
.btn.sm { min-height: 44px; padding: 0 18px; border-radius: 14px; font-size: 15px; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* sections */
.sec { padding: clamp(72px, 10vw, 136px) 0; }
.sec-head { display: flex; flex-direction: column; gap: 16px; margin-bottom: clamp(36px, 5vw, 64px); }
.dark { background: var(--grad); color: #fff; }
.card { background: #fff; border: 1px solid var(--line); border-radius: 24px; padding: 24px; box-shadow: 0 4px 18px rgba(18, 38, 29, 0.04); }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.grid2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
@media (max-width: 860px) { .grid3, .grid2 { grid-template-columns: 1fr; } }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: 999px; background: var(--primary-soft); color: var(--primary); font-size: 14px; font-weight: 700; }
.pill.warn { background: var(--warning-soft); color: var(--warning); }
.pill.ok { background: var(--success-soft); color: var(--success); }
.num { display: inline-flex; width: 36px; height: 36px; align-items: center; justify-content: center; border-radius: 50%; background: var(--primary-soft); color: var(--primary); font-weight: 700; font-family: var(--display); }

/* reveal on scroll */
[data-reveal] { opacity: 0; transform: translateY(22px); transition: opacity 700ms var(--ease), transform 700ms var(--ease); transition-delay: var(--d, 0ms); }
[data-reveal="scale"] { transform: scale(0.94); }
[data-reveal="left"] { transform: translateX(-28px); }
[data-reveal="right"] { transform: translateX(28px); }
[data-reveal].in { opacity: 1; transform: none; }

/* reward card */
.rcard { position: relative; width: 100%; aspect-ratio: 1.586; border-radius: 26px; padding: 7%; background: var(--grad); color: #fff; box-shadow: 0 18px 36px rgba(6, 45, 35, 0.2); overflow: hidden; display: flex; flex-direction: column; container-type: inline-size; }
.rcard::after { content: ""; position: absolute; right: -32%; top: -40%; width: 92%; aspect-ratio: 1.4; border-radius: 50%; border: 1px solid rgba(191, 232, 208, 0.1); box-shadow: 0 0 0 9cqw rgba(191, 232, 208, 0.025), 0 0 0 18cqw rgba(191, 232, 208, 0.02); pointer-events: none; }
.rcard .top { display: flex; justify-content: space-between; align-items: center; }
.rcard .lg { display: inline-flex; align-items: center; gap: 2cqw; font-family: var(--display); font-weight: 600; font-size: 7.6cqw; letter-spacing: -0.024em; }
.rcard .lg svg { width: 7.4cqw; height: 7.4cqw; }
.rcard .mem { border: 1px solid rgba(255, 255, 255, 0.55); background: rgba(255, 255, 255, 0.08); border-radius: 999px; font-size: 2.9cqw; font-weight: 650; letter-spacing: 0.12em; padding: 1.6cqw 3.4cqw; }
.rcard .claim { margin-top: 7.5cqw; font-size: 7.1cqw; line-height: 1.16; font-weight: 600; letter-spacing: -0.02em; }
.rcard .bot { margin-top: auto; display: flex; justify-content: space-between; align-items: flex-end; font-size: 3.2cqw; }
.rcard .bot b { display: block; font-size: 4cqw; font-weight: 600; }
.rcard .bot span { color: rgba(255, 255, 255, 0.76); }
.rcard .bot .r { text-align: right; color: var(--mint); }
.rcard .bot .r b { color: #fff; font-size: 3.5cqw; }

/* phone */
.phone { position: relative; width: 300px; aspect-ratio: 390 / 800; border-radius: 44px; background: #0b1f18; padding: 9px; box-shadow: 0 40px 80px rgba(6, 45, 35, 0.22), 0 0 0 1px rgba(18, 38, 29, 0.5); }
.phone .scr { position: relative; width: 100%; height: 100%; border-radius: 36px; background: var(--bg); overflow: hidden; font-size: 13px; line-height: 1.4; }
.phone .isl { position: absolute; top: 9px; left: 50%; translate: -50% 0; width: 78px; height: 22px; border-radius: 12px; background: #0b1f18; z-index: 5; }

/* faq + footer */
.faq details { border-bottom: 1px solid var(--line); padding: 20px 0; }
.faq summary { cursor: pointer; font-family: var(--display); font-weight: 600; font-size: 21px; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::after { content: "+"; color: var(--primary); font-size: 26px; line-height: 1; transition: rotate 220ms var(--ease); }
.faq details[open] summary::after { rotate: 45deg; }
.faq details p { margin-top: 10px; color: var(--muted); max-width: 44em; }
.foot { padding: 44px 0 56px; border-top: 1px solid var(--line); font-size: 14px; color: var(--muted); }
.foot .row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; align-items: center; }
.foot .logo { display: inline-flex; align-items: center; gap: 8px; font-family: var(--display); font-weight: 600; font-size: 21px; color: var(--ink); letter-spacing: -0.024em; }

/* lab switcher */
.lab-sw { position: fixed; left: 50%; bottom: 16px; translate: -50% 0; z-index: 90; display: flex; align-items: center; gap: 4px; padding: 5px; border-radius: 16px; background: rgba(255, 255, 255, 0.9); border: 1px solid var(--line); box-shadow: 0 8px 28px rgba(18, 38, 29, 0.14); -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); font-size: 13px; font-weight: 600; color: var(--ink); }
.lab-sw a { min-width: 34px; height: 34px; padding: 0 10px; display: inline-flex; align-items: center; justify-content: center; border-radius: 11px; color: var(--muted); }
.lab-sw a.on { background: var(--primary-soft); color: var(--primary); }
.lab-sw a:hover { color: var(--ink); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; scroll-behavior: auto !important; }
  [data-reveal] { opacity: 1; transform: none; }
}
