/* BaanBot — baanbot.shop · โทนม่วงกลางคืน + ส้มพระอาทิตย์ตก (ตามโลโก้/แบนเนอร์) · มุมมน ไม่เหลี่ยมทื่อ */
:root {
  --bg: #120a22;
  --bg-2: #1b1033;
  --card: #22153d;
  --line: #3a2861;
  --text: #f6f0ff;
  --muted: #b9a9d9;
  --orange: #ff8a3d;
  --orange-2: #ffb14d;
  --purple: #9b6bff;
  --pink: #ff5fa2;
  --radius: 28px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: "Kanit", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
}
body::before { /* แสงม่วงส้มฟุ้ง ๆ ด้านหลัง */
  content: ""; position: fixed; inset: -20% -10% auto; height: 90vh; z-index: -1;
  background: radial-gradient(40% 50% at 25% 30%, rgba(155, 107, 255, .35), transparent 70%),
              radial-gradient(35% 45% at 80% 20%, rgba(255, 138, 61, .25), transparent 70%);
  filter: blur(20px);
}
a { color: inherit; text-decoration: none; }
.wrap { width: min(1120px, 100% - 32px); margin-inline: auto; }

/* nav */
nav {
  position: sticky; top: 0; z-index: 10;
  backdrop-filter: blur(14px); background: rgba(18, 10, 34, .72);
  border-bottom: 1px solid rgba(58, 40, 97, .6);
}
nav .wrap { display: flex; align-items: center; justify-content: space-between; height: 68px; gap: 12px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.2rem; }
.brand img { width: 38px; height: 38px; border-radius: 12px; }
.nav-links { display: flex; gap: 22px; color: var(--muted); font-size: .95rem; }
.nav-links a:hover { color: var(--text); }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 26px; border-radius: 999px; font-weight: 600; font-size: 1.02rem;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-main { background: linear-gradient(135deg, var(--orange), var(--orange-2)); color: #2a1406;
  box-shadow: 0 10px 30px rgba(255, 138, 61, .35); }
.btn-ghost { border: 1px solid var(--line); background: rgba(34, 21, 61, .6); }
.btn-ghost:hover { background: var(--card); }
.btn-sm { padding: 10px 18px; font-size: .92rem; }

/* hero */
.hero { padding: 90px 0 70px; text-align: center; }
.hero .mascot { width: 150px; height: 150px; border-radius: 40px; margin-bottom: 26px;
  box-shadow: 0 20px 60px rgba(155, 107, 255, .45); animation: float 5s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-10px) rotate(-2deg); } }
.tag { display: inline-block; font-size: .85rem; letter-spacing: .04em; color: var(--orange-2);
  border: 1px solid rgba(255, 177, 77, .35); background: rgba(255, 138, 61, .08);
  padding: 6px 16px; border-radius: 999px; margin-bottom: 18px; }
h1 { font-size: clamp(2.2rem, 5.6vw, 4rem); line-height: 1.12; font-weight: 800; margin-bottom: 18px; }
h1 .hl { background: linear-gradient(90deg, var(--orange), var(--pink), var(--purple));
  -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { color: var(--muted); font-size: clamp(1.02rem, 2vw, 1.2rem); max-width: 640px; margin: 0 auto 34px; }
.cta { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; }
.note { margin-top: 18px; color: var(--muted); font-size: .9rem; }

/* sections */
section { padding: 80px 0; }
.sec-title { text-align: center; margin-bottom: 44px; }
.sec-title h2 { font-size: clamp(1.7rem, 3.6vw, 2.5rem); font-weight: 700; }
.sec-title p { color: var(--muted); margin-top: 8px; }

.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; }
.card {
  background: linear-gradient(180deg, rgba(34, 21, 61, .95), rgba(27, 16, 51, .95));
  border: 1px solid var(--line); border-radius: var(--radius); padding: 28px;
  transition: transform .2s ease, border-color .2s ease;
}
.card:hover { transform: translateY(-4px); border-color: rgba(255, 138, 61, .5); }
.card .ic { font-size: 2rem; margin-bottom: 12px; }
.card h3 { font-size: 1.25rem; margin-bottom: 8px; }
.card p { color: var(--muted); font-size: .98rem; }
.card code, .steps code {
  font-family: ui-monospace, Consolas, monospace; font-size: .85rem;
  background: rgba(155, 107, 255, .14); color: #d9c8ff; padding: 2px 8px; border-radius: 8px; white-space: nowrap;
}
.cmds { margin-top: 14px; display: flex; flex-wrap: wrap; gap: 6px; }

.star { border-color: rgba(255, 95, 162, .55); position: relative; }
.star::after { content: "ใหม่"; position: absolute; top: 18px; right: 18px; font-size: .75rem;
  background: var(--pink); color: #fff; padding: 2px 10px; border-radius: 999px; }

/* steps */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; counter-reset: s; }
.step { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; }
.step::before { counter-increment: s; content: counter(s); display: grid; place-items: center;
  width: 42px; height: 42px; border-radius: 14px; margin-bottom: 14px; font-weight: 700;
  background: linear-gradient(135deg, var(--purple), var(--pink)); }
.step h3 { font-size: 1.1rem; margin-bottom: 6px; }
.step p { color: var(--muted); font-size: .95rem; }

/* custom bot */
.custom {
  border-radius: 36px; padding: 48px 34px; text-align: center;
  background: linear-gradient(135deg, rgba(255, 138, 61, .16), rgba(155, 107, 255, .2));
  border: 1px solid rgba(255, 177, 77, .35);
}
.custom h2 { font-size: clamp(1.6rem, 3.4vw, 2.3rem); margin-bottom: 10px; }
.custom p { color: var(--muted); max-width: 620px; margin: 0 auto 26px; }
.pill-row { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-bottom: 28px; }
.pill { background: rgba(18, 10, 34, .6); border: 1px solid var(--line); border-radius: 999px; padding: 8px 16px; font-size: .92rem; }

/* faq */
details { background: var(--bg-2); border: 1px solid var(--line); border-radius: 22px; padding: 18px 22px; margin-bottom: 12px; }
summary { cursor: pointer; font-weight: 600; list-style: none; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; float: right; color: var(--orange); font-size: 1.3rem; line-height: 1; }
details[open] summary::after { content: "–"; }
details p { color: var(--muted); margin-top: 10px; }

/* legal pages */
.legal { padding: 60px 0 90px; }
.legal .box { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(22px, 4vw, 46px); }
.legal h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
.legal h2 { font-size: 1.25rem; margin: 28px 0 8px; color: var(--orange-2); }
.legal p, .legal li { color: var(--muted); }
.legal ul { padding-left: 22px; margin-top: 6px; }
.legal .upd { color: var(--muted); font-size: .9rem; margin-bottom: 8px; }

footer { border-top: 1px solid var(--line); padding: 34px 0 46px; color: var(--muted); font-size: .92rem; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 16px; justify-content: space-between; align-items: center; }
footer .links { display: flex; gap: 18px; flex-wrap: wrap; }
footer a:hover { color: var(--text); }

/* reveal on scroll */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.reveal.show { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero .mascot { animation: none; }
}
@media (max-width: 640px) {
  .nav-links { display: none; }
  .hero { padding-top: 60px; }
  section { padding: 60px 0; }
}
