:root {
  --cream: #fff2de;
  --paper: #fffaf3;
  --surface: #ffffff;
  --ink: #702e25;
  --muted: #8f704d;
  --soft: #f7ead9;
  --line: rgba(112, 46, 37, 0.08);
  --rose: #ffb7c5;
  --sage: #acc572;
  --peach: #ffac91;
  --sky: #bfecff;
  --lavender: #ebdeff;
  --lime: #e3e76f;
  --brown: #702e25;
  --orange: #ff824d;
  --radius: 14px;
  --shadow: 0 18px 60px rgba(112, 46, 37, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: Mali, Sarabun, "Noto Sans Thai", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 15px;
  line-height: 1.55;
  letter-spacing: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
}

.page-shell {
  min-height: 100vh;
  background: var(--cream);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid rgba(112, 46, 37, 0.06);
  background: rgba(255, 242, 222, 0.88);
  backdrop-filter: blur(18px);
}

.nav-wrap,
.section-wrap,
.footer-wrap,
.legal-wrap {
  width: min(1100px, calc(100% - 32px));
  margin: 0 auto;
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 72px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  white-space: nowrap;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: linear-gradient(180deg, #fff, var(--soft));
  color: var(--brown);
  box-shadow: 0 8px 24px rgba(112, 46, 37, 0.08);
}

.brand-mark::before {
  content: "";
  width: 14px;
  height: 18px;
  border-radius: 12px 12px 12px 4px;
  background: var(--sage);
  transform: rotate(16deg);
}

.app-tabs,
.sub-tabs,
.lang-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.62);
}

.app-tab,
.sub-tab,
.lang-button,
.nav-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
}

.app-tab,
.sub-tab,
.lang-button {
  min-height: 34px;
  padding: 0 14px;
}

.app-tab.is-active,
.sub-tab.is-active,
.lang-button.is-active {
  color: var(--ink);
  background: var(--surface);
  box-shadow: 0 6px 18px rgba(112, 46, 37, 0.08);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 14px;
}

.primary-link {
  color: var(--ink);
  border: 1px solid rgba(112, 46, 37, 0.14);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(255, 242, 222, 0.72));
}

.hero {
  padding: 74px 0 50px;
}

.eyebrow {
  margin: 0 0 18px;
  color: var(--orange);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 48px;
  align-items: end;
}

.hero h1 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(30px, 4.8vw, 46px);
  font-weight: 700;
  line-height: 1.36;
  letter-spacing: 0;
}

.hero-copy {
  max-width: 700px;
  margin: 20px 0 0;
  color: var(--muted);
  font-size: clamp(15px, 1.55vw, 17px);
  line-height: 1.72;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 30px;
}

.pill-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border: 1px solid rgba(112, 46, 37, 0.18);
  border-radius: 999px;
  background: linear-gradient(180deg, var(--sage), #9bb85d);
  color: var(--ink);
  font-weight: 700;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.54), 0 12px 24px rgba(112, 46, 37, 0.1);
}

.text-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.mini-panel {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.58);
  box-shadow: var(--shadow);
}

.mini-panel-title {
  margin: 0 0 12px;
  font-size: 13px;
  font-weight: 700;
}

.mini-list {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.mini-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 2px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.mini-list li:last-child {
  border-bottom: 0;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--sage);
}

.dot.rose {
  background: var(--rose);
}

.dot.sky {
  background: var(--sky);
}

.dot.lime {
  background: var(--lime);
}

.product-panel {
  display: none;
}

.product-panel.is-active {
  display: block;
}

.section {
  padding: 56px 0;
}

.section-header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 34px;
}

.section-header h2 {
  max-width: 640px;
  margin: 0;
  font-size: clamp(23px, 2.8vw, 32px);
  line-height: 1.24;
  font-weight: 700;
}

.section-header p {
  max-width: 360px;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.feature-card {
  min-height: 238px;
  padding: 26px 26px 24px;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: rgba(255, 250, 243, 0.76);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.6);
}

.feature-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 40px;
}

.feature-icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: var(--soft);
}

.feature-icon::before {
  content: "";
  width: 18px;
  height: 18px;
  border-radius: 7px;
  background: var(--sage);
  box-shadow: 10px 0 0 var(--sky);
}

.feature-card:nth-child(2) .feature-icon::before {
  background: var(--peach);
  box-shadow: 10px 0 0 var(--rose);
}

.feature-card:nth-child(3) .feature-icon::before {
  background: var(--lavender);
  box-shadow: 10px 0 0 var(--lime);
}

.feature-card:nth-child(4) .feature-icon::before {
  background: var(--sky);
  box-shadow: 10px 0 0 var(--sage);
}

.feature-card:nth-child(5) .feature-icon::before {
  background: var(--orange);
  box-shadow: 10px 0 0 var(--peach);
}

.feature-card:nth-child(6) .feature-icon::before {
  background: var(--lime);
  box-shadow: 10px 0 0 var(--lavender);
}

.feature-number {
  color: rgba(112, 46, 37, 0.36);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px;
}

.feature-card h3 {
  margin: 0 0 12px;
  font-size: 17px;
  line-height: 1.25;
}

.feature-card p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
}

.footer {
  margin-top: 56px;
  padding: 44px 0 34px;
  border-top: 1px solid var(--line);
  background: rgba(255, 250, 243, 0.56);
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) repeat(3, minmax(140px, 1fr));
  gap: 34px;
}

.footer h2,
.footer h3 {
  margin: 0 0 12px;
  font-size: 14px;
}

.footer p,
.footer a {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.8;
}

.footer-links {
  display: grid;
  gap: 7px;
}

.fine-print {
  margin-top: 30px;
  color: rgba(125, 115, 108, 0.72);
  font-size: 12px;
}

.legal-page {
  background: var(--cream);
}

.legal-header {
  border-bottom: 1px solid var(--line);
  background: rgba(255, 242, 222, 0.88);
}

.legal-main {
  padding: 56px 0 72px;
}

.legal-card {
  padding: clamp(24px, 5vw, 56px);
  border: 1px solid var(--line);
  border-radius: 28px;
  background: var(--surface);
}

.legal-article {
  display: none;
}

.legal-article.is-active {
  display: block;
}

.legal-article h1 {
  margin: 0 0 8px;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.16;
}

.legal-article .updated,
.legal-article .contact {
  color: var(--muted);
  font-size: 14px;
}

.legal-article h2 {
  margin: 34px 0 10px;
  font-size: 18px;
  line-height: 1.3;
}

.legal-article p,
.legal-article li {
  color: #514842;
  font-size: 14px;
  line-height: 1.85;
}

.legal-article ul {
  padding-left: 22px;
}

.empty-product {
  padding: 56px 0;
}

.empty-card {
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: rgba(255, 250, 243, 0.76);
}

.empty-card h1 {
  margin: 10px 0 12px;
  font-size: clamp(26px, 3.8vw, 40px);
  line-height: 1.22;
}

.empty-card p {
  max-width: 620px;
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.75;
}

@media (max-width: 900px) {
  .nav-wrap {
    flex-wrap: wrap;
    padding: 12px 0;
  }

  .app-tabs {
    order: 3;
    width: 100%;
    overflow-x: auto;
    justify-content: flex-start;
  }

  .hero {
    padding-top: 46px;
  }

  .hero-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .mini-panel {
    max-width: 420px;
  }

  .section-header {
    display: block;
  }

  .section-header p {
    margin-top: 14px;
  }

  .feature-grid,
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 620px) {
  .nav-wrap,
  .section-wrap,
  .footer-wrap,
  .legal-wrap {
    width: min(100% - 28px, 1100px);
  }

  .brand span:last-child {
    max-width: 112px;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .nav-actions {
    margin-left: auto;
  }

  .nav-link {
    display: none;
  }

  .hero h1 {
    font-size: clamp(28px, 8.8vw, 38px);
  }

  .hero-copy {
    font-size: 14px;
  }

  .hero-actions {
    align-items: stretch;
  }

  .pill-button,
  .text-link {
    width: 100%;
    justify-content: center;
  }

  .feature-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .feature-card {
    min-height: auto;
    padding: 22px;
    border-radius: 22px;
  }

  .feature-top {
    margin-bottom: 34px;
  }

  .legal-main {
    padding: 28px 0 54px;
  }

  .legal-card {
    border-radius: 20px;
  }
}
