/* kp.css — โทนสว่างสดใสของ kingpilot.app
   ใช้กับหน้าแรก, KING WAVE PRO, บทเรียน และหน้าโฆษณา
   แก้ไฟล์นี้ไฟล์เดียวเปลี่ยนทั้งเว็บ (หน้าโฆษณากับหน้าบทเรียนเรนเดอร์จากเซิร์ฟเวอร์
   แต่ดึง kp.css ตัวนี้ไปใช้เหมือนกัน) */

:root {
  --bg: #f5f8ff;
  --bg-tint: #e8f0ff;
  --surface: #ffffff;
  --line: #e2e8f5;
  --ink: #0f1b33;
  --ink-soft: #4a5b75;
  --ink-faint: #7d8da6;
  --brand: #2f6bff;
  --brand-dark: #1d4ed8;
  --brand-soft: #eaf1ff;
  --cyan: #06b6d4;
  --mint: #10b981;
  --amber: #f59e0b;
  --line-green: #06c755;
  --shadow: 0 10px 30px rgba(24, 51, 105, 0.08);
  --shadow-lift: 0 16px 40px rgba(24, 51, 105, 0.14);
  --radius: 16px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "IBM Plex Sans Thai", system-ui, -apple-system, sans-serif;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

/* พื้นหลังไล่สีอ่อน ๆ ด้านบน ให้หน้าดูสว่างแต่ไม่โล่ง */
body::before {
  content: "";
  position: fixed;
  inset: 0 0 auto;
  height: 420px;
  background: linear-gradient(180deg, var(--bg-tint) 0%, rgba(245, 248, 255, 0) 100%);
  z-index: -1;
}

.wrap { max-width: 1020px; margin: 0 auto; padding: 0 18px; }

h1, h2, h3 { font-family: "Chakra Petch", "IBM Plex Sans Thai", sans-serif; color: var(--ink); line-height: 1.2; }
h1 { font-size: clamp(30px, 6vw, 54px); margin: 14px 0 16px; letter-spacing: -0.01em; }
h2 { font-size: clamp(21px, 4vw, 31px); margin: 0 0 10px; }
p { margin: 0 0 14px; }
a { color: var(--brand-dark); }

.lead { color: var(--ink-soft); font-size: 17px; }
.muted { color: var(--ink-faint); }

/* แถบเมนูบนสุด */
.topbar { position: sticky; top: 0; z-index: 20; background: rgba(245, 248, 255, 0.88); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.topbar-in { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; padding: 13px 0; }
.brand { display: inline-flex; align-items: center; gap: 9px; font-family: "Chakra Petch", sans-serif; font-weight: 700; font-size: 17px; color: var(--ink); text-decoration: none; letter-spacing: 0.02em; }
.brand-dot { width: 11px; height: 11px; border-radius: 50%; background: linear-gradient(135deg, var(--brand), var(--cyan)); box-shadow: 0 0 0 4px var(--brand-soft); }
.brand small { display: block; color: var(--ink-faint); font-size: 10.5px; font-weight: 500; letter-spacing: 0.14em; }
.topnav { display: flex; flex-wrap: wrap; gap: 16px; margin-left: auto; font-size: 14.5px; }
.topnav a { color: var(--ink-soft); text-decoration: none; }
.topnav a:hover { color: var(--brand); }

/* ปุ่ม */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 26px; border: 0; border-radius: 11px;
  font: inherit; font-weight: 700; font-size: 16px; text-decoration: none; cursor: pointer;
}
.btn-main { background: linear-gradient(135deg, var(--brand), var(--cyan)); color: #fff; box-shadow: 0 10px 24px rgba(47, 107, 255, 0.28); }
.btn-main:hover { transform: translateY(-1px); box-shadow: 0 14px 30px rgba(47, 107, 255, 0.34); }
.btn-line { background: var(--line-green); color: #04220f; box-shadow: 0 10px 24px rgba(6, 199, 85, 0.26); }
.btn-soft { background: var(--surface); color: var(--brand-dark); border: 1px solid var(--line); }
.btn-full { width: 100%; }
.btn:disabled { opacity: 0.6; cursor: default; box-shadow: none; }

/* กล่องและการ์ด */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 24px; }
.eyebrow { display: inline-block; padding: 5px 13px; border-radius: 999px; background: var(--brand-soft); color: var(--brand-dark); font-size: 12px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; }

.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: 13px; padding: 17px; box-shadow: var(--shadow); }
.stat b { display: block; font-family: "Chakra Petch", sans-serif; font-size: 20px; color: var(--brand-dark); }
.stat span { color: var(--ink-faint); font-size: 13px; }

/* ขั้นตอนแบบมีเลข */
.steps { display: grid; gap: 12px; }
.step-row { display: grid; grid-template-columns: 46px 1fr; gap: 15px; align-items: start; background: var(--surface); border: 1px solid var(--line); border-radius: 13px; padding: 17px; box-shadow: var(--shadow); }
.step-row b { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 12px; background: linear-gradient(135deg, var(--brand), var(--cyan)); color: #fff; font-family: "Chakra Petch", sans-serif; font-size: 15px; }
.step-row span { color: var(--ink-soft); }
.step-row strong { color: var(--ink); }

.section { padding: 46px 0; }
.section + .section { border-top: 1px solid var(--line); }

.checklist { list-style: none; margin: 22px 0 0; padding: 0; }
.checklist li { position: relative; padding: 10px 0 10px 32px; color: var(--ink-soft); border-bottom: 1px solid var(--line); }
.checklist li::before { content: "✓"; position: absolute; left: 6px; color: var(--mint); font-weight: 700; }

.note { border-left: 4px solid var(--amber); background: #fffaf0; border-radius: 12px; padding: 18px 20px; color: var(--ink-soft); }
.note strong { color: var(--ink); }

details { border-bottom: 1px solid var(--line); padding: 14px 0; }
summary { cursor: pointer; font-weight: 600; color: var(--ink); }
details p { color: var(--ink-soft); margin: 10px 0 2px; }

footer.site { margin-top: 40px; padding: 26px 0 54px; border-top: 1px solid var(--line); color: var(--ink-faint); font-size: 12.5px; }

@media (max-width: 560px) {
  .topnav { width: 100%; margin-left: 0; gap: 14px; font-size: 13.5px; }
  .btn { width: 100%; }
}
