/* Softh Technology — marketing site */

:root {
  --bg: #000;
  --fg: #fff;
  --sub: #a0a0a0;
  --muted: #8e8e8e;
  --line: #222;
  --line-hover: #3a3a3a;
  --header-h: 4.5rem;
  --pad: clamp(1.25rem, 4.2vw, 4.25rem);
  --max: 72rem;
  --font: Inter, ui-sans-serif, system-ui, sans-serif;
  --font-th: Prompt, Inter, ui-sans-serif, system-ui, sans-serif;
  --ease: 180ms ease;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font);
  font-optical-sizing: auto;
  line-height: 1.6;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 0.75rem);
  -webkit-text-size-adjust: 100%;
  text-rendering: optimizeLegibility;
}

html[lang="th"] {
  font-family: var(--font-th);
  line-height: 1.72;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  min-width: 320px;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

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

a:hover {
  color: var(--fg);
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}

h1, h2, h3, p, ul {
  margin: 0;
}

::selection {
  background: #fff;
  color: #000;
}

:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: 0.75rem;
  top: -4rem;
  z-index: 100;
  background: #fff;
  color: #000;
  padding: 0.6rem 1rem;
  font-size: 0.875rem;
  font-weight: 500;
}

.skip-link:focus {
  top: 0.75rem;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

html[data-lang="en"] .lang-th,
html[data-lang="th"] .lang-en {
  display: none !important;
}

.wrap {
  width: min(100% - var(--pad) * 2, var(--max));
  margin-inline: auto;
}


html[lang="th"] .hero-index,
html[lang="th"] .section-index,
html[lang="th"] .service-num,
html[lang="th"] .step-num {
  letter-spacing: 0.04em;
  text-transform: none;
}

/* Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  background: rgba(0, 0, 0, 0.86);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--ease);
}

.site-header.is-scrolled {
  border-bottom-color: var(--line);
}

.header-inner {
  height: 100%;
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.logo {
  display: flex;
  align-items: center;
  flex: 0 0 auto;
}

.logo img {
  height: 22px;
  width: auto;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.7rem;
  margin-left: auto;
  list-style: none;
  padding: 0;
}

.nav-links a {
  font-size: 0.875rem;
  font-weight: 450;
  letter-spacing: -0.01em;
  color: var(--sub);
  transition: color var(--ease);
}

.nav-links a:hover,
.nav-links a:focus-visible {
  color: var(--fg);
}

.header-tools {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-left: 0.5rem;
}

.lang-switch {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.08em;
}

.lang-switch button {
  color: var(--muted);
  transition: color var(--ease);
}

.lang-switch button[aria-pressed="true"] {
  color: var(--fg);
}

.lang-switch button:hover {
  color: var(--fg);
}

.lang-sep {
  color: #444;
  user-select: none;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  min-height: 2.85rem;
  padding: 0.7rem 1.25rem;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1.2;
  transition: background-color var(--ease), color var(--ease), border-color var(--ease);
}

.btn svg {
  width: 0.9rem;
  height: 0.9rem;
  flex: 0 0 auto;
}

.btn-primary {
  background: #fff;
  color: #000;
}

.btn-primary:hover {
  background: #d8d8d8;
  color: #000;
}

.btn-ghost {
  background: transparent;
  color: #fff;
  border: 1px solid #fff;
}

.btn-ghost:hover {
  background: #fff;
  color: #000;
}

.btn-header {
  min-height: 2.35rem;
  padding: 0.5rem 1rem;
  font-size: 0.8125rem;
}

.menu-toggle {
  display: none;
  width: 2.5rem;
  height: 2.5rem;
  position: relative;
  margin-right: -0.4rem;
}

.menu-toggle span {
  position: absolute;
  left: 0.6rem;
  right: 0.6rem;
  height: 1px;
  background: #fff;
  transition: transform 200ms ease, opacity 200ms ease, top 200ms ease;
}

.menu-toggle span:first-of-type { top: 0.95rem; }
.menu-toggle span:last-of-type { top: 1.5rem; }

.menu-toggle[aria-expanded="true"] span:first-of-type {
  top: 1.25rem;
  transform: rotate(45deg);
}

.menu-toggle[aria-expanded="true"] span:last-of-type {
  top: 1.25rem;
  transform: rotate(-45deg);
}

body.menu-open {
  overflow: hidden;
}

/* Hero */

.hero {
  position: relative;
  padding: clamp(3.5rem, 10vw, 8.5rem) 0 clamp(3.25rem, 8vw, 6.5rem);
  min-height: calc(100svh - var(--header-h));
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero-index {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2.25rem;
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero-index::after {
  content: "";
  width: 2.75rem;
  height: 1px;
  background: #fff;
}

.hero-title {
  max-width: 16ch;
  font-size: clamp(2.6rem, 7.2vw, 5.4rem);
  font-weight: 600;
  letter-spacing: -0.038em;
  line-height: 0.98;
}

html[lang="th"] .hero-title {
  max-width: 14em;
  letter-spacing: -0.01em;
  line-height: 1.22;
  font-weight: 600;
}

.hero-rule {
  width: 2.75rem;
  height: 1px;
  background: #fff;
  margin: 2rem 0 1.35rem;
  border: 0;
}

.hero-lede {
  max-width: 38rem;
  color: var(--sub);
  font-size: clamp(1.05rem, 1.5vw, 1.25rem);
  font-weight: 400;
  line-height: 1.55;
  letter-spacing: -0.015em;
}

html[lang="th"] .hero-lede {
  letter-spacing: 0;
  line-height: 1.75;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2.25rem;
}

.hero-foot {
  margin-top: clamp(3rem, 10vh, 6rem);
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

/* Sections */

.section {
  padding: clamp(4.25rem, 10vw, 7.5rem) 0;
  border-top: 1px solid var(--line);
}

.section-head {
  display: grid;
  grid-template-columns: 4.5rem minmax(0, 1fr);
  column-gap: 0.5rem;
  row-gap: 1.25rem;
  margin-bottom: 3rem;
  align-items: baseline;
}

.section-index {
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.16em;
}

.section-title {
  font-size: clamp(1.85rem, 3.6vw, 3rem);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.1;
}

html[lang="th"] .section-title {
  letter-spacing: -0.01em;
  line-height: 1.3;
}

.section-lede {
  grid-column: 2;
  max-width: 40rem;
  color: var(--sub);
  font-size: 1.0625rem;
  letter-spacing: -0.01em;
  line-height: 1.65;
}

html[lang="th"] .section-lede {
  letter-spacing: 0;
  line-height: 1.8;
}

@media (max-width: 640px) {
  .section-head {
    grid-template-columns: 1fr;
    gap: 0.65rem;
  }
  .section-lede {
    grid-column: 1;
  }
}

/* Services */

.service-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid var(--line);
}

.service {
  padding: 2.15rem 0 2.35rem;
  border-bottom: 1px solid var(--line);
}

.service:nth-child(odd) {
  padding-right: 2.75rem;
  border-right: 1px solid var(--line);
}

.service:nth-child(even) {
  padding-left: 2.75rem;
}

.service:last-child:nth-child(odd) {
  border-right: 0;
}

.service-num {
  display: block;
  margin-bottom: 1rem;
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.14em;
}

.service h3 {
  font-size: 1.2rem;
  font-weight: 525;
  letter-spacing: -0.025em;
  line-height: 1.25;
  margin-bottom: 0.7rem;
}

html[lang="th"] .service h3 {
  letter-spacing: 0;
  line-height: 1.4;
}

.service p {
  color: var(--sub);
  font-size: 0.975rem;
  letter-spacing: -0.01em;
  line-height: 1.65;
  max-width: 36em;
}

html[lang="th"] .service p {
  letter-spacing: 0;
  line-height: 1.8;
}

/* Industries */

.industry-list {
  list-style: none;
  padding: 0;
  border-top: 1px solid var(--line);
}

.industry-list li {
  border-bottom: 1px solid var(--line);
}

.industry-list span,
.industry-list a {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1.2rem 0;
  font-size: clamp(1.2rem, 2.4vw, 1.7rem);
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.2;
}

html[lang="th"] .industry-list span {
  letter-spacing: -0.01em;
  line-height: 1.4;
}

.industry-list i {
  font-style: normal;
  color: #444;
  font-size: 1rem;
  letter-spacing: 0;
  transition: color var(--ease), transform var(--ease);
}

/* Process */

.process-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border-top: 1px solid var(--line);
}

.step {
  padding: 2rem 1.75rem 0.25rem 0;
  border-right: 1px solid var(--line);
}

.step:first-child {
  padding-left: 0;
}

.step:last-child {
  border-right: 0;
  padding-right: 0;
  padding-left: 1.75rem;
}

.step:nth-child(2),
.step:nth-child(3) {
  padding-left: 1.75rem;
}

.step-num {
  display: block;
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  margin-bottom: 1.35rem;
}

.step h3 {
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: -0.03em;
  margin-bottom: 0.85rem;
}

html[lang="th"] .step h3 {
  letter-spacing: 0;
  line-height: 1.35;
}

.step p {
  color: var(--sub);
  font-size: 0.95rem;
  letter-spacing: -0.01em;
  line-height: 1.65;
}

html[lang="th"] .step p {
  letter-spacing: 0;
  line-height: 1.8;
}

/* Why */

.why-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid var(--line);
}

.why-item {
  padding: 2.1rem 0 2.3rem;
  border-bottom: 1px solid var(--line);
}

.why-item:nth-child(odd) {
  padding-right: 2.75rem;
  border-right: 1px solid var(--line);
}

.why-item:nth-child(even) {
  padding-left: 2.75rem;
}

.why-item h3 {
  font-size: 1.2rem;
  font-weight: 525;
  letter-spacing: -0.025em;
  margin-bottom: 0.7rem;
}

html[lang="th"] .why-item h3 {
  letter-spacing: 0;
  line-height: 1.4;
}

.why-item p {
  color: var(--sub);
  font-size: 0.975rem;
  letter-spacing: -0.01em;
  line-height: 1.65;
  max-width: 36em;
}

html[lang="th"] .why-item p {
  letter-spacing: 0;
  line-height: 1.8;
}

/* Contact */

.contact {
  padding-bottom: clamp(4.5rem, 11vw, 8rem);
}

.contact-title {
  font-size: clamp(2.15rem, 5.4vw, 4.25rem);
  font-weight: 600;
  letter-spacing: -0.038em;
  line-height: 1.02;
  max-width: 14ch;
}

html[lang="th"] .contact-title {
  max-width: 12em;
  letter-spacing: -0.01em;
  line-height: 1.25;
}

.contact .section-lede {
  grid-column: 2;
}

.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2.25rem;
}

/* Footer */

.site-footer {
  border-top: 1px solid var(--line);
  padding: 1.75rem 0 2rem;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 2rem;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.footer-brand img {
  height: 16px;
  width: auto;
}

.footer-copy {
  color: var(--muted);
  font-size: 0.8rem;
}

.footer-meta {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.footer-page {
  color: var(--muted);
  font-size: 0.8rem;
  transition: color var(--ease);
}

.footer-page:hover {
  color: var(--fg);
}

/* Responsive */

@media (max-width: 1040px) {
  .menu-toggle {
    display: block;
  }

  .btn-header {
    display: none;
  }

  .nav-links {
    position: fixed;
    inset: var(--header-h) 0 0 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    gap: 0;
    padding: 1.25rem var(--pad) 2.5rem;
    background: #000;
    transform: translateY(-0.5rem);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 200ms ease, visibility 200ms ease, transform 200ms ease;
    overflow: auto;
  }

  .nav-links.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: none;
  }

  .nav-links li {
    width: 100%;
    border-bottom: 1px solid var(--line);
  }

  .nav-links a {
    display: block;
    padding: 1.15rem 0;
    font-size: 1.5rem;
    font-weight: 525;
    letter-spacing: -0.03em;
    color: var(--fg);
  }

  .nav-cta-mobile {
    display: inline-flex;
    margin-top: 1.75rem;
  }

  .header-tools {
    margin-left: auto;
  }
}

@media (min-width: 1041px) {
  .nav-cta-mobile {
    display: none !important;
  }
}

@media (max-width: 860px) {
  .service-grid,
  .why-grid,
  .process-grid {
    grid-template-columns: 1fr;
  }

  .service,
  .service:nth-child(odd),
  .service:nth-child(even),
  .service:last-child:nth-child(odd),
  .why-item,
  .why-item:nth-child(odd),
  .why-item:nth-child(even),
  .step,
  .step:first-child,
  .step:last-child,
  .step:nth-child(2),
  .step:nth-child(3) {
    padding: 1.75rem 0;
    border-right: 0;
  }

  .hero-title {
    max-width: none;
  }
}

@media (max-width: 720px) {
  .hero-index {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.85rem;
  }
}

@media (max-width: 560px) {
  .hero-actions,
  .contact-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-actions .btn,
  .contact-actions .btn {
    width: 100%;
  }

  .logo img {
    height: 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    transition: none !important;
  }
}
