:root {
  --bg: #070809;
  --surface: #111316;
  --surface-2: #191c20;
  --ink: #f4f1ea;
  --muted: #9a9ea5;
  --line: rgba(244, 241, 234, .18);
  --accent: #ff3d2e;
  --accent-ink: #100807;
  --shell: 1380px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; background: var(--bg); }
body {
  margin: 0;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--ink);
  font-family: "IBM Plex Sans Thai", Tahoma, sans-serif;
  -webkit-font-smoothing: antialiased;
}
body.menu-open { overflow: hidden; }
a { color: inherit; text-decoration: none; }
button, a { font: inherit; }
button { color: inherit; }
img, video, canvas { display: block; }
::selection { background: var(--accent); color: var(--accent-ink); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.shell { width: min(var(--shell), calc(100% - 56px)); margin-inline: auto; }
.skip {
  position: fixed; top: 8px; left: 8px; z-index: 200;
  padding: 10px 14px; background: var(--ink); color: var(--bg);
  transform: translateY(-150%);
}
.skip:focus { transform: translateY(0); }

.progress { position: fixed; inset: 0 0 auto; z-index: 160; height: 2px; background: rgba(255,255,255,.08); }
.progress span { display: block; width: 0; height: 100%; background: var(--accent); }

.stage { position: fixed; inset: 0; z-index: 0; overflow: hidden; background: var(--bg); }
.scene {
  position: absolute; inset: -3%; width: 106%; height: 106%; object-fit: cover;
  opacity: 0; transform: scale(1.05); filter: saturate(.9) contrast(1.06) brightness(.82);
  transition: opacity .9s cubic-bezier(.16,1,.3,1), transform 2s cubic-bezier(.16,1,.3,1);
}
.scene.is-active { opacity: 1; transform: scale(1); }
#signalCanvas { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .72; mix-blend-mode: screen; pointer-events: none; }
.stage-scrim {
  position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(7,8,9,.82) 0%, rgba(7,8,9,.50) 38%, rgba(7,8,9,.08) 68%, rgba(7,8,9,.30) 100%),
    linear-gradient(180deg, rgba(7,8,9,.50) 0%, transparent 30%, transparent 66%, rgba(7,8,9,.76) 100%);
}
.grain {
  position: absolute; inset: 0; pointer-events: none; opacity: .10;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 160 160' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.88' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.55'/%3E%3C/svg%3E");
  mix-blend-mode: soft-light;
}

.site-header { position: fixed; inset: 0 0 auto; z-index: 150; }
.nav { min-height: 70px; display: flex; align-items: center; gap: 32px; border-bottom: 1px solid rgba(255,255,255,.16); }
.brand { display: inline-flex; align-items: center; gap: 11px; font-family: Archivo, sans-serif; font-size: 14px; font-weight: 700; letter-spacing: -.03em; white-space: nowrap; }
.brand-mark { width: 22px; height: 22px; background: var(--accent); clip-path: polygon(0 0,100% 0,70% 100%,0 100%); }
.nav-links { display: flex; align-items: center; gap: 24px; margin-left: auto; }
.nav-links a { color: rgba(255,255,255,.7); font-size: 13px; }
.nav-links a:hover { color: var(--ink); }
.nav-cta { margin-left: 8px; }
.menu-button { display: none; min-width: 44px; min-height: 44px; border: 1px solid var(--line); border-radius: 999px; background: rgba(7,8,9,.6); cursor: pointer; }

.button {
  position: relative; display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 21px; border: 1px solid transparent; border-radius: 999px;
  font-weight: 600; font-size: 14px; white-space: nowrap; cursor: pointer;
  transition: background .25s ease, color .25s ease, border-color .25s ease, transform .2s ease;
}
.button:active { transform: scale(.97); }
.button-red { background: var(--accent); color: #160807; }
.button-red:hover { background: #ff5a4d; }
.button-light { background: var(--ink); color: var(--bg); }
.button-light:hover { background: #fffdf8; }
.button-ghost { border-color: rgba(255,255,255,.35); background: rgba(7,8,9,.24); color: var(--ink); }
.button-ghost:hover { background: rgba(255,255,255,.10); }
.button-dark { border-color: rgba(7,8,9,.32); background: rgba(7,8,9,.14); color: var(--bg); }

.story { position: relative; z-index: 5; }
.story-chapter { position: relative; min-height: 155dvh; }
.chapter-inner {
  position: sticky; top: 0; min-height: 100dvh; display: grid; align-items: center;
  padding-top: 70px;
}
.chapter-inner::before { display: none; }
.chapter-copy { max-width: 690px; will-change: transform, opacity; }
.align-right { justify-items: end; }
.align-right .chapter-copy { text-align: right; }
.eyebrow {
  width: fit-content; margin-bottom: 22px; color: rgba(255,255,255,.72);
  font-family: Archivo, sans-serif; font-size: 11px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
}
.hero h1 { margin: 0; font-family: "Noto Sans Thai", sans-serif; font-size: clamp(68px, 9vw, 136px); font-weight: 800; line-height: .84; letter-spacing: -.075em; }
.hero h1 span { display: block; }
.accent { color: var(--accent); }
.chapter-copy h2 { margin: 0; font-family: "Noto Sans Thai", sans-serif; font-size: clamp(56px, 7.2vw, 108px); font-weight: 700; line-height: .88; letter-spacing: -.068em; }
.chapter-copy > p { max-width: 520px; margin: 24px 0 0; color: rgba(255,255,255,.76); font-size: clamp(17px, 1.5vw, 21px); line-height: 1.55; }
.align-right .chapter-copy > p { margin-left: auto; }
.actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 28px; }
.align-right .actions { justify-content: flex-end; }

.marquee { position: relative; z-index: 10; overflow: hidden; border-block: 1px solid var(--line); background: var(--accent); color: var(--accent-ink); }
.marquee-track { display: flex; align-items: center; width: max-content; min-height: 94px; animation: marquee 22s linear infinite; }
.marquee span { font-family: Archivo, sans-serif; font-size: clamp(34px, 4.5vw, 62px); font-weight: 700; letter-spacing: -.055em; }
.marquee i { width: 10px; height: 10px; margin: 0 30px; border-radius: 50%; background: var(--accent-ink); }
@keyframes marquee { to { transform: translateX(-50%); } }

.solid-section { position: relative; z-index: 10; background: var(--bg); }
.service-system { padding: 150px 0; }
.system-layout { display: grid; grid-template-columns: .85fr 1.15fr; gap: clamp(70px, 10vw, 170px); }
.system-intro { position: sticky; top: 120px; align-self: start; }
.system-intro h2 { margin: 0; font-family: "Noto Sans Thai", sans-serif; font-size: clamp(46px, 5.4vw, 78px); line-height: .96; letter-spacing: -.06em; }
.system-intro p { max-width: 500px; margin: 24px 0 0; color: var(--muted); font-size: 18px; line-height: 1.65; }
.service-list { border-top: 1px solid var(--line); }
.service-row { display: grid; grid-template-columns: 74px 1fr; gap: 10px 22px; padding: 38px 0; border-bottom: 1px solid var(--line); }
.service-code { grid-row: 1 / 3; color: var(--accent); font-family: Archivo, sans-serif; font-size: 11px; letter-spacing: .09em; }
.service-row h3 { margin: 0; font-size: clamp(27px, 3vw, 42px); font-weight: 500; letter-spacing: -.045em; }
.service-row p { max-width: 570px; margin: 0; color: var(--muted); line-height: 1.65; }

.comment-lab { position: relative; z-index: 10; min-height: 90dvh; overflow: hidden; background: #0b0d10; border-block: 1px solid var(--line); }
.comment-lab::after { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none; background: linear-gradient(90deg, #0b0d10 0%, rgba(11,13,16,.96) 28%, rgba(11,13,16,.62) 48%, transparent 73%); }
#commentCanvas { position: absolute; inset: 0; }
#commentCanvas canvas { width: 100% !important; height: 100% !important; }
.comment-copy { position: relative; z-index: 2; min-height: 90dvh; display: grid; align-content: center; pointer-events: none; }
.comment-copy h2 { max-width: 760px; margin: 0; font-family: "Noto Sans Thai", sans-serif; font-size: clamp(64px, 8vw, 120px); line-height: .88; letter-spacing: -.07em; }
.comment-copy p { max-width: 530px; margin: 28px 0 0; color: rgba(255,255,255,.72); font-size: 18px; line-height: 1.65; }

.pricing { padding: 150px 0; }
.pricing-label { margin-bottom: 28px; color: var(--accent); font-family: Archivo, sans-serif; font-size: 11px; letter-spacing: .12em; text-transform: uppercase; }
.pricing-grid { display: grid; grid-template-columns: 1.35fr .65fr; min-height: 560px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.price-display { display: flex; flex-direction: column; justify-content: space-between; padding: 46px 50px 46px 0; }
.price-display h2 { margin: 0; color: var(--accent); font-family: Archivo, sans-serif; font-size: clamp(92px, 15vw, 220px); line-height: .78; letter-spacing: -.085em; }
.price-display p { margin: 0; font-size: 28px; }
.price-detail { display: flex; flex-direction: column; justify-content: center; padding: 48px; border-left: 1px solid var(--line); background: var(--surface); }
.price-detail h3 { margin: 0 0 18px; font-size: 30px; letter-spacing: -.04em; }
.price-detail > p { margin: 0; color: var(--muted); line-height: 1.65; }
.price-detail ul { display: grid; gap: 0; margin: 28px 0 34px; padding: 0; list-style: none; }
.price-detail li { padding: 12px 0; border-bottom: 1px solid var(--line); color: #c6c8cc; }
.price-detail .button { align-self: flex-start; }

.faq { padding: 30px 0 150px; }
.faq-layout { display: grid; grid-template-columns: .65fr 1.35fr; gap: clamp(60px, 10vw, 150px); }
.faq h2 { margin: 0; font-family: "Noto Sans Thai", sans-serif; font-size: clamp(48px, 6vw, 80px); line-height: .95; letter-spacing: -.06em; }
.faq-list { border-top: 1px solid var(--line); }
details { border-bottom: 1px solid var(--line); }
summary { position: relative; padding: 28px 50px 28px 0; cursor: pointer; list-style: none; font-size: 20px; font-weight: 500; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; position: absolute; right: 2px; top: 22px; color: var(--accent); font-family: Archivo, sans-serif; font-size: 28px; }
details[open] summary::after { content: "−"; }
details p { max-width: 680px; margin: 0; padding: 0 48px 28px 0; color: var(--muted); line-height: 1.72; }

.final-cta { position: relative; z-index: 10; overflow: hidden; background: var(--accent); color: var(--accent-ink); }
.final-inner { min-height: 88dvh; display: grid; align-content: center; }
.final-inner h2 { margin: 0; font-family: "Noto Sans Thai", sans-serif; font-size: clamp(65px, 10vw, 150px); line-height: .82; letter-spacing: -.078em; }
.final-inner h2 span { color: var(--ink); }
.final-inner > p { max-width: 620px; margin: 30px 0 0; font-size: 20px; line-height: 1.55; }
.final-actions { margin-top: 32px; }
.footer { position: relative; z-index: 10; padding: 28px 0 96px; background: var(--bg); }
.footer-inner { display: flex; justify-content: space-between; gap: 22px; padding-top: 20px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; }
.mobile-cta { display: none; }
.toast { position: fixed; left: 50%; bottom: 22px; z-index: 200; transform: translate(-50%,150%); padding: 12px 18px; border-radius: 999px; background: var(--ink); color: var(--bg); opacity: 0; transition: .25s ease; }
.toast.show { transform: translate(-50%,0); opacity: 1; }
.noscript { position: fixed; inset: auto 10px 10px; z-index: 220; padding: 12px; background: var(--accent); color: var(--accent-ink); }

@media (max-width: 900px) {
  .shell { width: min(var(--shell), calc(100% - 30px)); }
  .nav-links, .nav-cta { display: none; }
  .menu-button { display: inline-flex; align-items: center; justify-content: center; margin-left: auto; }
  .nav-links.open { position: fixed; inset: 71px 0 auto; display: grid; gap: 0; padding: 14px 22px 24px; background: rgba(7,8,9,.98); border-bottom: 1px solid var(--line); }
  .nav-links.open a { padding: 15px 0; border-bottom: 1px solid var(--line); font-size: 18px; }
  .story-chapter { min-height: 135dvh; }
  .chapter-copy { max-width: 620px; }
  .hero h1 { font-size: clamp(54px, 15vw, 88px); }
  .chapter-copy h2 { font-size: clamp(50px, 13vw, 82px); }
  .align-right { justify-items: start; }
  .align-right .chapter-copy { text-align: left; }
  .align-right .chapter-copy > p { margin-left: 0; }
  .align-right .actions { justify-content: flex-start; }
  .stage-scrim { background: linear-gradient(180deg,rgba(7,8,9,.38),rgba(7,8,9,.54) 42%,rgba(7,8,9,.88)); }
  .system-layout, .pricing-grid, .faq-layout { grid-template-columns: 1fr; }
  .system-intro { position: relative; top: auto; }
  .system-layout { gap: 58px; }
  .service-system, .pricing { padding: 100px 0; }
  .price-detail { border-left: 0; border-top: 1px solid var(--line); }
  .price-display { min-height: 390px; padding-right: 0; }
  .faq { padding-bottom: 110px; }
  .faq-layout { gap: 44px; }
  .footer-inner { display: grid; }
  .mobile-cta { position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 170; display: flex; min-height: 54px; box-shadow: 0 14px 40px rgba(0,0,0,.35); }
  .mobile-cta.is-hidden { opacity: 0; pointer-events: none; transform: translateY(16px); }
}

@media (max-width: 560px) {
  .chapter-inner { padding-top: 82px; align-items: end; padding-bottom: 80px; }
  .hero h1 { font-size: 15vw; line-height: .88; }
  .chapter-copy h2 { font-size: 13.5vw; line-height: .92; }
  .chapter-copy > p { font-size: 16px; }
  .actions { flex-direction: column; }
  .actions .button { width: 100%; }
  .marquee-track { min-height: 72px; }
  .service-row { grid-template-columns: 56px 1fr; padding: 30px 0; }
  .comment-copy h2 { font-size: 16vw; }
  .comment-copy p { font-size: 16px; }
  .price-display { min-height: 320px; }
  .price-display h2 { font-size: 24vw; }
  .price-display p { font-size: 22px; }
  .price-detail { padding: 34px 24px; }
  .final-inner h2 { font-size: 17vw; }
  .final-inner > p { font-size: 17px; }
  .footer { padding-bottom: 110px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  .stage { display: none; }
  .story-chapter { min-height: auto; }
  .chapter-inner { position: relative; min-height: 100dvh; overflow: hidden; }
  .chapter-inner::before { content: ""; position: absolute; inset: 0; z-index: -2; display: block; background: linear-gradient(90deg,rgba(7,8,9,.85),rgba(7,8,9,.28)), var(--poster) center/cover; }
  .chapter-inner::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg,transparent,rgba(7,8,9,.7)); }
  #commentCanvas { opacity: .25; }
}
