/* ==========================================================================
   Systemist-มนุษย์ระบบ — Landing Page Styles
   Mobile-first: ออกแบบบนจอ 390px ก่อนเสมอ แล้วค่อยขยายด้วย media query
   อ้างอิง: 23-07-69-landing-page-deep-research.md หมวด 1, 7
   ========================================================================== */

:root {
  --color-bg: #0f1115;
  --color-bg-alt: #171a21;
  --color-card: #1c1f27;
  --color-text: #eef0f4;
  --color-text-muted: #a6acb9;
  --color-accent: #35c2a0;
  --color-accent-dark: #279b80;
  --color-warn: #e0a13c;
  --color-border: #2a2e38;
  --radius: 14px;
  --max-width: 640px;
  font-size: 16px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: "Noto Sans Thai", "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
  border-radius: var(--radius);
}

a {
  color: var(--color-accent);
}

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* ไม่มี nav menu ตามกฎ deep-research หมวด 1 — เหลือ logo ที่คลิกไม่ได้ */
.topbar {
  padding: 18px 20px 6px;
  text-align: center;
}

.topbar__logo {
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.02em;
  color: var(--color-text-muted);
}

section {
  padding: 40px 0;
}

.section--alt {
  background: var(--color-bg-alt);
}

h1, h2, h3 {
  line-height: 1.35;
  margin: 0 0 14px;
}

h1 {
  font-size: 26px;
}

h2 {
  font-size: 21px;
}

h3 {
  font-size: 17px;
}

p {
  margin: 0 0 14px;
}

.eyebrow {
  color: var(--color-accent);
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 8px;
  display: block;
}

.muted {
  color: var(--color-text-muted);
  font-size: 14px;
}

.caption {
  color: var(--color-text-muted);
  font-size: 12.5px;
  margin: 8px 0 0;
  text-align: center;
}

/* ---------- CTA ---------- */
.btn {
  display: inline-block;
  width: 100%;
  text-align: center;
  padding: 16px 20px;
  font-size: 17px;
  font-weight: 700;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.06s ease, opacity 0.15s ease;
  min-height: 44px; /* กติกาปุ่มแตะง่ายด้วยนิ้วโป้ง */
}

.btn:active {
  transform: scale(0.98);
}

.btn--primary {
  background: var(--color-accent);
  color: #06120f;
}

.btn--primary:hover {
  background: var(--color-accent-dark);
}

.btn--disabled {
  background: var(--color-border);
  color: var(--color-text-muted);
  cursor: not-allowed;
  pointer-events: none;
}

.cta-note {
  text-align: center;
  font-size: 13px;
  color: var(--color-text-muted);
  margin-top: 10px;
}

/* sticky CTA มือถือ — บังคับตาม deep-research หมวด 7 */
.sticky-cta {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 40;
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  background: linear-gradient(180deg, rgba(15,17,21,0) 0%, var(--color-bg) 35%);
  transform: translateY(100%);
  transition: transform 0.25s ease;
}

.sticky-cta.is-visible {
  transform: translateY(0);
}

.sticky-cta .btn {
  box-shadow: 0 6px 24px rgba(53, 194, 160, 0.35);
}

/* ---------- Hero ---------- */
.hero {
  padding-top: 20px;
  text-align: center;
}

.hero__tagline {
  color: var(--color-text-muted);
  font-size: 14px;
  margin-bottom: 10px;
}

.hero__sub {
  font-size: 15.5px;
  color: var(--color-text-muted);
}

.hero__image-wrap {
  margin: 22px 0 6px;
}

/* ---------- Problem list ---------- */
.pain-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.pain-list li {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 14px 16px;
  margin-bottom: 10px;
  font-size: 15px;
}

/* ---------- Offer stack ---------- */
.offer-list {
  list-style: none;
  margin: 0 0 18px;
  padding: 0;
}

.offer-list li {
  display: flex;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 1px solid var(--color-border);
  font-size: 15px;
}

.offer-list li:last-child {
  border-bottom: none;
}

.offer-list .check {
  color: var(--color-accent);
  font-weight: 700;
  flex-shrink: 0;
}

.premium-note {
  background: var(--color-card);
  border: 1px dashed var(--color-border);
  border-radius: var(--radius);
  padding: 14px 16px;
  font-size: 14px;
  color: var(--color-text-muted);
}

/* ---------- Fit / Not fit ---------- */
.fit-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.fit-card {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 16px;
}

.fit-card--no {
  border-color: rgba(224, 161, 60, 0.4);
}

.fit-card h3 {
  margin-bottom: 8px;
}

.fit-card ul {
  margin: 0;
  padding-left: 18px;
  font-size: 14.5px;
  color: var(--color-text-muted);
}

.fit-card ul li {
  margin-bottom: 6px;
}

/* ---------- Pricing ---------- */
.price-card {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 16px;
}

.price-card--active {
  border-color: var(--color-accent);
}

.price-card__tier {
  font-weight: 700;
  font-size: 15px;
  color: var(--color-text-muted);
  margin-bottom: 4px;
}

.price-card__amount {
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 4px;
}

.price-card__amount span {
  font-size: 15px;
  font-weight: 500;
  color: var(--color-text-muted);
}

.price-card__desc {
  font-size: 14px;
  color: var(--color-text-muted);
  margin-bottom: 16px;
}

.price-card--soon {
  opacity: 0.7;
}

.badge-soon {
  display: inline-block;
  font-size: 12px;
  padding: 3px 10px;
  border-radius: 999px;
  background: rgba(224, 161, 60, 0.15);
  color: var(--color-warn);
  margin-bottom: 10px;
}

.checkout-terms {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 13.5px;
  color: var(--color-text-muted);
  margin: 14px 0;
  text-align: left;
}

.checkout-terms input {
  margin-top: 3px;
  flex-shrink: 0;
  width: 18px;
  height: 18px;
}

.checkout-error {
  color: #ff8a8a;
  font-size: 13px;
  margin-top: 8px;
  display: none;
}

.checkout-error.is-visible {
  display: block;
}

/* ---------- FAQ ---------- */
.faq-item {
  border-bottom: 1px solid var(--color-border);
  padding: 14px 0;
}

.faq-item summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 15px;
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  float: right;
  color: var(--color-accent);
  font-size: 20px;
}

.faq-item[open] summary::after {
  content: "–";
}

.faq-item p {
  margin-top: 10px;
  font-size: 14.5px;
  color: var(--color-text-muted);
}

.faq-item--locked summary::after {
  content: "🔒";
  font-size: 14px;
}

/* ---------- Footer / Trust ---------- */
footer {
  padding: 30px 0 100px;
  text-align: center;
  color: var(--color-text-muted);
  font-size: 13px;
}

footer a {
  color: var(--color-text-muted);
  text-decoration: underline;
}

.trust-badges {
  display: flex;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  margin: 14px 0;
  font-size: 12px;
}

.trust-badges span {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: 999px;
  padding: 6px 12px;
}

/* ---------- Cookie consent ---------- */
#cookie-banner {
  position: fixed;
  left: 12px;
  right: 12px;
  bottom: 12px;
  z-index: 60;
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 16px;
  font-size: 13.5px;
  color: var(--color-text-muted);
  box-shadow: 0 10px 30px rgba(0,0,0,0.4);
  display: none;
}

#cookie-banner.is-visible {
  display: block;
}

#cookie-banner .cookie-actions {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

#cookie-banner button {
  flex: 1;
  padding: 10px 12px;
  border-radius: 999px;
  border: 1px solid var(--color-border);
  background: transparent;
  color: var(--color-text);
  font-size: 13px;
  cursor: pointer;
}

#cookie-banner button.accept {
  background: var(--color-accent);
  border-color: var(--color-accent);
  color: #06120f;
  font-weight: 700;
}

/* ---------- Legal pages ---------- */
.legal-page {
  padding: 30px 0 80px;
}

.legal-page h1 {
  font-size: 22px;
}

.legal-page h2 {
  font-size: 17px;
  margin-top: 26px;
}

.legal-page p, .legal-page li {
  font-size: 14.5px;
  color: var(--color-text-muted);
}

.placeholder-box {
  border: 1px dashed var(--color-warn);
  background: rgba(224, 161, 60, 0.08);
  border-radius: var(--radius);
  padding: 16px;
  color: var(--color-text);
  font-size: 14.5px;
}

/* ---------- Thank-you page ---------- */
.thankyou {
  text-align: center;
  padding-top: 60px;
}

.thankyou .icon {
  font-size: 46px;
  margin-bottom: 12px;
}

/* ---------- Larger screens (desktop = ของแถม) ---------- */
@media (min-width: 720px) {
  :root {
    --max-width: 760px;
  }
  h1 {
    font-size: 34px;
  }
  h2 {
    font-size: 26px;
  }
  .fit-grid {
    grid-template-columns: 1fr 1fr;
  }
  .btn {
    width: auto;
    padding: 16px 40px;
  }
  .sticky-cta .wrap {
    display: flex;
    justify-content: center;
  }
}
