:root {
  --bg: #eee8ff;
  --bg-deep: #e1d7ff;
  --card: #ffffff;
  --text: #17151f;
  --muted: #666172;
  --border: #ebe7f6;
  --purple: #7357d8;
  --purple-dark: #4d39a9;
  --line: #06c755;
  --line-dark: #05a948;
  --android: #16c85f;
  --android-dark: #0d9f48;
  --ios: #13284f;
  --ios-dark: #0d1b38;
  --shadow: 0 16px 40px rgba(52, 36, 96, 0.14);
  --soft-shadow: 0 10px 24px rgba(52, 36, 96, 0.1);
  --radius: 22px;
  --radius-sm: 16px;
  --container: 720px;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.72), transparent 34rem),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-deep) 100%);
  color: var(--text);
  font-family: Arial, "Tahoma", "Noto Sans Thai", sans-serif;
  line-height: 1.75;
  overflow-x: hidden;
  text-rendering: optimizeLegibility;
}

img,
svg {
  display: block;
  max-width: 100%;
}

a {
  color: var(--purple-dark);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.page {
  min-height: 100vh;
  padding: 18px 12px 28px;
}

.container {
  width: min(100%, var(--container));
  margin: 0 auto;
}

.stack {
  display: grid;
  gap: 16px;
}

.card {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: var(--shadow);
}

.hero-card {
  position: relative;
  padding: 58px 14px 16px;
  overflow: visible;
}

.hero-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
}

.brand-logo {
  width: min(250px, 72vw);
  height: auto;
  max-height: 64px;
  border-radius: 0;
  object-fit: contain;
}

.brand-name {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.hero-banner {
  width: 100%;
  border-radius: 18px;
  object-fit: cover;
  background: #f2efff;
}

.hero-actions {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.menu-wrap {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 10;
}

.menu-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  border: 0;
  border-radius: 999px;
  padding: 9px 14px;
  background: var(--purple);
  color: #fff;
  font: inherit;
  font-size: 0.84rem;
  font-weight: 800;
  letter-spacing: 0;
  box-shadow: 0 10px 22px rgba(115, 87, 216, 0.28);
  cursor: pointer;
}

.menu-pill:hover,
.menu-pill:focus-visible {
  background: var(--purple-dark);
}

.hamburger {
  position: relative;
  width: 16px;
  height: 12px;
}

.hamburger::before,
.hamburger::after,
.hamburger span {
  position: absolute;
  left: 0;
  width: 16px;
  height: 2px;
  border-radius: 2px;
  background: #fff;
  content: "";
}

.hamburger::before {
  top: 0;
}

.hamburger span {
  top: 5px;
}

.hamburger::after {
  bottom: 0;
}

.menu-panel {
  position: absolute;
  top: 48px;
  left: 0;
  width: min(250px, calc(100vw - 42px));
  max-height: min(78vh, 430px);
  overflow-y: auto;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--shadow);
  padding: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity 160ms ease, transform 160ms ease, visibility 160ms ease;
}

.menu-panel.is-open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.menu-panel a {
  display: block;
  border-radius: 12px;
  padding: 10px 12px;
  color: var(--text);
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.35;
}

.menu-panel a:hover,
.menu-panel a:focus-visible {
  background: #f3f0ff;
  color: var(--purple-dark);
  text-decoration: none;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 52px;
  border: 0;
  border-radius: 16px;
  padding: 13px 18px;
  color: #fff;
  font-size: 1rem;
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  box-shadow: 0 12px 20px rgba(20, 20, 40, 0.12);
  cursor: pointer;
}

.btn:hover,
.btn:focus-visible {
  text-decoration: none;
  transform: translateY(-1px);
}

.btn-line {
  background: linear-gradient(180deg, var(--line) 0%, var(--line-dark) 100%);
}

.btn-android {
  background: linear-gradient(180deg, var(--android) 0%, var(--android-dark) 100%);
}

.btn-ios {
  background: linear-gradient(180deg, var(--ios) 0%, var(--ios-dark) 100%);
}

.btn-secondary {
  background: linear-gradient(180deg, var(--purple) 0%, var(--purple-dark) 100%);
}

.download-grid {
  display: grid;
  gap: 16px;
}

.download-card,
.content-card {
  padding: 20px;
}

.download-card {
  display: grid;
  gap: 16px;
}

.download-head {
  display: flex;
  align-items: center;
  gap: 14px;
}

.download-icon,
.app-icon {
  flex: 0 0 auto;
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: #f5f3fb;
  object-fit: cover;
  padding: 10px;
}

.download-icon svg {
  width: 100%;
  height: 100%;
  color: #111;
}

.download-title {
  margin: 0;
  font-size: 1.34rem;
  font-weight: 900;
  line-height: 1.25;
}

.download-meta {
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 0;
  color: var(--muted);
  font-size: 0.96rem;
  list-style: none;
}

.download-meta strong {
  color: var(--text);
}

.content-card {
  overflow-wrap: anywhere;
}

.content-card h1,
.content-card h2,
.content-card h3 {
  margin: 0 0 10px;
  color: var(--text);
  line-height: 1.35;
}

.content-card h1 {
  font-size: 1.72rem;
}

.content-card h2 {
  font-size: 1.32rem;
}

.content-card h3 {
  font-size: 1.08rem;
}

.content-card p {
  margin: 0 0 12px;
}

.content-card p:last-child,
.content-card ul:last-child,
.content-card ol:last-child {
  margin-bottom: 0;
}

.content-card ul,
.content-card ol {
  margin: 0 0 12px;
  padding-left: 1.35rem;
}

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

.muted {
  color: var(--muted);
}

.breadcrumb {
  margin: 2px 0 14px;
  color: var(--muted);
  font-size: 0.92rem;
}

.breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.breadcrumb li:not(:last-child)::after {
  margin-left: 6px;
  color: #8b849b;
  content: "/";
}

.breadcrumb a {
  font-weight: 700;
}

.cta-card {
  padding: 20px;
  text-align: center;
}

.cta-card h2 {
  margin: 0 0 8px;
  font-size: 1.28rem;
  line-height: 1.35;
}

.cta-card p {
  margin: 0 0 14px;
  color: var(--muted);
}

.faq-list {
  display: grid;
  gap: 12px;
}

.faq-item {
  border-top: 1px solid var(--border);
  padding-top: 12px;
}

.faq-item:first-child {
  border-top: 0;
  padding-top: 0;
}

.faq-item h3 {
  margin-bottom: 6px;
}

.footer {
  margin-top: 18px;
  padding: 22px 18px;
  color: #4d475e;
  font-size: 0.93rem;
}

.footer p {
  margin: 0 0 12px;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-bottom: 12px;
}

.footer-nav a {
  color: var(--purple-dark);
  font-weight: 800;
}

.disclaimer {
  color: #625b70;
  font-size: 0.88rem;
}

.copyright {
  color: #756f82;
  font-size: 0.86rem;
}

.inline-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  margin-top: 10px;
}

.inline-links a {
  font-weight: 800;
}

@media (min-width: 640px) {
  .page {
    padding: 28px 18px 40px;
  }

  .stack {
    gap: 18px;
  }

  .hero-card {
    padding: 64px 18px 18px;
  }

  .hero-banner {
    border-radius: 20px;
  }

  .download-grid {
    grid-template-columns: 1fr 1fr;
  }

  .download-card,
  .content-card,
  .cta-card {
    padding: 24px;
  }

  .content-card h1 {
    font-size: 2rem;
  }

  .content-card h2 {
    font-size: 1.48rem;
  }
}

@media (max-width: 380px) {
  .page {
    padding-left: 10px;
    padding-right: 10px;
  }

  .download-card,
  .content-card,
  .cta-card {
    padding: 16px;
  }

  .content-card h1 {
    font-size: 1.48rem;
  }

  .download-title {
    font-size: 1.18rem;
  }

  .btn {
    min-height: 50px;
    padding-left: 12px;
    padding-right: 12px;
    font-size: 0.94rem;
  }
}
