/* nuteo-web — v2 styles. Dark-mode aware, mobile-first, accessible. */

/* ============================================
   Design tokens (light + dark via CSS vars)
   ============================================ */
:root {
  /* Palette */
  --bg:           #ffffff;
  --bg-alt:       #f8fafc;
  --bg-elev:      #ffffff;
  --fg:           #0f172a;
  --fg-muted:     #64748b;
  --fg-subtle:    #94a3b8;
  --border:       #e2e8f0;
  --accent:       #2563eb;
  --accent-hover: #1d4ed8;
  --accent-soft:  #dbeafe;
  --success:      #16a34a;
  --success-soft: #dcfce7;
  --error:        #dc2626;
  --error-soft:   #fee2e2;
  --warning:      #d97706;
  --warning-soft: #fef3c7;

  /* Spacing scale (rem) */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-8: 3rem;
  --space-10: 4rem;
  --space-12: 6rem;

  /* Type scale */
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "Inter",
               Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas,
               "Liberation Mono", "Courier New", monospace;

  /* Radii + shadow */
  --radius-sm:  4px;
  --radius:     8px;
  --radius-lg:  12px;
  --radius-xl:  20px;

  --shadow-sm:  0 1px 2px rgba(15, 23, 42, 0.06);
  --shadow:     0 4px 12px rgba(15, 23, 42, 0.08);
  --shadow-lg:  0 12px 32px rgba(15, 23, 42, 0.10);
  --shadow-xl:  0 24px 64px rgba(15, 23, 42, 0.12);

  /* Motion */
  --transition: 200ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 400ms cubic-bezier(0.4, 0, 0.2, 1);

  /* Container */
  --container-max: 1100px;
}

/* Dark mode tokens */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg:           #0b1220;
    --bg-alt:       #111827;
    --bg-elev:      #1f2937;
    --fg:           #e2e8f0;
    --fg-muted:     #94a3b8;
    --fg-subtle:    #64748b;
    --border:       #1f2937;
    --accent:       #60a5fa;
    --accent-hover: #93c5fd;
    --accent-soft:  #1e3a8a;
    --success:      #4ade80;
    --success-soft: #14532d;
    --error:        #f87171;
    --error-soft:   #7f1d1d;
    --warning:      #fbbf24;
    --warning-soft: #78350f;
    --shadow-sm:  0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow:     0 4px 12px rgba(0, 0, 0, 0.4);
    --shadow-lg:  0 12px 32px rgba(0, 0, 0, 0.5);
    --shadow-xl:  0 24px 64px rgba(0, 0, 0, 0.6);
  }
}

:root[data-theme="dark"] {
  --bg:           #0b1220;
  --bg-alt:       #111827;
  --bg-elev:      #1f2937;
  --fg:           #e2e8f0;
  --fg-muted:     #94a3b8;
  --fg-subtle:    #64748b;
  --border:       #1f2937;
  --accent:       #60a5fa;
  --accent-hover: #93c5fd;
  --accent-soft:  #1e3a8a;
  --success:      #4ade80;
  --success-soft: #14532d;
  --error:        #f87171;
  --error-soft:   #7f1d1d;
  --warning:      #fbbf24;
  --warning-soft: #78350f;
  --shadow-sm:  0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow:     0 4px 12px rgba(0, 0, 0, 0.4);
  --shadow-lg:  0 12px 32px rgba(0, 0, 0, 0.5);
  --shadow-xl:  0 24px 64px rgba(0, 0, 0, 0.6);
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  transition: background var(--transition), color var(--transition);
}

h1, h2, h3, h4, h5, h6 {
  margin: 0 0 var(--space-4);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

/* Inside long-form content (about, FAQ, blog post body), reset the
   cascade so h2/h3 don't all hug the line above. */
article h2,
.section h2,
article h3,
.section h3 {
  margin-top: var(--space-6);
}

h1 { font-size: clamp(2rem, 5vw, 3.25rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.25rem); }
h3 { font-size: clamp(1.25rem, 3vw, 1.5rem); }
h4 { font-size: 1.125rem; }

p {
  margin: 0 0 var(--space-4);
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color var(--transition);
}

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

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

button {
  font: inherit;
  cursor: pointer;
}

/* ============================================
   Layout
   ============================================ */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--space-5);
}

.section {
  padding-block: var(--space-12);
}

.section.narrow {
  max-width: 720px;
  margin: 0 auto;
}

main:focus { outline: none; } /* skip-link target */

/* Skip link for accessibility */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--accent);
  color: white;
  padding: var(--space-2) var(--space-4);
  z-index: 100;
  text-decoration: none;
  border-radius: var(--radius);
  transition: top var(--transition);
}

.skip-link:focus {
  top: var(--space-2);
  left: var(--space-2);
}

/* ============================================
   Header & nav
   ============================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  min-height: 64px;
  flex-wrap: nowrap;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-weight: 700;
  color: var(--fg);
  text-decoration: none;
  letter-spacing: -0.02em;
  white-space: nowrap;
  flex-shrink: 0;
}

.brand img {
  width: 32px;
  height: 32px;
}

.brand span {
  white-space: nowrap;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  flex-wrap: nowrap;
  flex: 1;
  justify-content: flex-end;
}

.site-nav a {
  display: inline-block;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius);
  color: var(--fg);
  font-weight: 500;
  transition: all var(--transition);
  white-space: nowrap;
  flex-shrink: 0;
}

.site-nav a:hover {
  background: var(--bg-alt);
  color: var(--fg);
}

.site-nav a.active {
  background: var(--accent-soft);
  color: var(--accent);
}

.site-nav a.btn {
  background: var(--accent);
  color: white;
  padding: var(--space-2) var(--space-4);
}

.site-nav a.btn:hover {
  background: var(--accent-hover);
  color: white;
}

/* Mini search box in nav */
.search-mini {
  display: flex;
  align-items: center;
}

.search-mini input {
  width: 160px;
  padding: var(--space-2) var(--space-3);
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.875rem;
  color: var(--fg);
  transition: all var(--transition);
}

.search-mini input:focus {
  outline: none;
  border-color: var(--accent);
  background: var(--bg-elev);
  width: 200px;
  box-shadow: 0 0 0 3px var(--accent-soft);
}

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

/* Language switcher */
.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 0;
  padding: 3px;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  flex-shrink: 0;
  margin-left: var(--space-2);
}

.lang-switch a {
  padding: 4px 10px;
  border-radius: 999px;
  color: var(--fg-muted);
  text-decoration: none;
  transition: all var(--transition);
  white-space: nowrap;
}

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

.lang-switch a.active {
  background: var(--bg);
  color: var(--fg);
  box-shadow: var(--shadow-sm);
}

@media (max-width: 720px) {
  .lang-switch {
    margin-left: 0;
  }
}

@media (max-width: 1200px) {
  .search-mini {
    display: none;
  }
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: transparent;
  color: var(--fg);
  transition: all var(--transition);
}

.theme-toggle:hover {
  background: var(--bg-alt);
  border-color: var(--accent);
}

.theme-toggle svg {
  width: 18px;
  height: 18px;
}

.mobile-menu-btn {
  display: none;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  width: 36px;
  height: 36px;
  padding: 0;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.mobile-menu-btn svg { width: 20px; height: 20px; }

/* Responsive: collapse nav to hamburger at narrower breakpoint
   so Thai nav (longer labels) doesn't break the row. */
@media (max-width: 1200px) {
  /* Reduce nav padding so longer Thai labels fit on one line */
  .site-nav a {
    padding: var(--space-2);
    font-size: 0.875rem;
  }
  /* Hide search-mini inline, keep it in mobile menu */
  .site-nav .search-mini {
    display: none;
  }
}

@media (max-width: 1000px) {
  .mobile-menu-btn { display: inline-flex; }
  .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    padding: var(--space-3);
    gap: var(--space-1);
    transform: translateY(-10px);
    opacity: 0;
    pointer-events: none;
    transition: all var(--transition);
    justify-content: flex-start;
  }
  .site-nav.is-open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }
  .site-nav a { padding: var(--space-3); font-size: 1rem; }
  .site-nav a.btn { margin-top: var(--space-2); }
  /* Show search inside the mobile menu */
  .site-nav .search-mini {
    display: flex;
    width: 100%;
  }
  .site-nav .search-mini input {
    width: 100%;
    height: 44px;
  }
}

/* ============================================
   Hero
   ============================================ */
.hero {
  padding-block: var(--space-12) var(--space-10);
  background:
    radial-gradient(ellipse at top, var(--accent-soft) 0%, transparent 60%),
    var(--bg);
}

.hero .container {
  max-width: 880px;
  text-align: center;
}

.hero h1 {
  background: linear-gradient(135deg, var(--fg) 0%, var(--accent) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  word-break: keep-all;       /* keep words together when possible */
  overflow-wrap: anywhere;     /* break only at character boundaries if needed */
  line-height: 1.15;
}

.hero .lede {
  font-size: clamp(1rem, 2vw, 1.25rem);
  color: var(--fg-muted);
  max-width: 720px;
  margin-inline: auto;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.hero-actions {
  display: flex;
  gap: var(--space-3);
  justify-content: center;
  margin-top: var(--space-6);
  flex-wrap: wrap;
}

/* ============================================
   Buttons
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-5);
  border-radius: var(--radius);
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  cursor: pointer;
  transition: all var(--transition);
  min-height: 44px;
}

.btn-primary {
  background: var(--accent);
  color: white;
  box-shadow: var(--shadow);
}

.btn-primary:hover {
  background: var(--accent-hover);
  color: white;
  transform: translateY(-1px);
  box-shadow: var(--shadow-lg);
}

.btn-secondary {
  background: var(--bg-elev);
  color: var(--fg);
  border-color: var(--border);
  font-weight: 600;
}

.btn-secondary:hover {
  background: var(--bg-alt);
  border-color: var(--accent);
  color: var(--fg);
  transform: translateY(-1px);
}

/* ============================================
   Grid + cards
   ============================================ */
.grid {
  display: grid;
  gap: var(--space-5);
  margin-top: var(--space-6);
}

.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
}

.card {
  display: flex;
  flex-direction: column;
  padding: var(--space-6);
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: all var(--transition);
  text-decoration: none;
  color: inherit;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  border-color: var(--accent);
}

.card h3 {
  margin-top: 0;
  font-size: 1.125rem;
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.card p {
  color: var(--fg-muted);
  flex-grow: 1;
  margin-bottom: var(--space-3);
}

.card .arrow {
  color: var(--accent);
  font-weight: 600;
  font-size: 0.875rem;
}

.card .meta {
  color: var(--fg-subtle);
  font-size: 0.875rem;
  margin-bottom: var(--space-2);
}

/* Service card with icon */
.service-card .icon {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-soft);
  color: var(--accent);
  border-radius: var(--radius);
  margin-bottom: var(--space-3);
}

.service-card .tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-top: var(--space-3);
}

.tag {
  display: inline-block;
  padding: var(--space-1) var(--space-3);
  background: var(--bg-alt);
  color: var(--fg-muted);
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 500;
  font-family: var(--font-mono);
}

.tag-accent {
  background: var(--accent-soft);
  color: var(--accent);
}

/* ============================================
   Detail page (service / portfolio / post)
   ============================================ */
.detail {
  max-width: 800px;
  margin: 0 auto;
}

.detail .meta {
  color: var(--fg-subtle);
  font-size: 0.875rem;
  margin-bottom: var(--space-4);
}

.detail .body {
  margin-top: var(--space-6);
}

.detail .body h2,
.detail .body h3 {
  margin-top: var(--space-8);
  margin-bottom: var(--space-3);
}

.detail .body pre {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: var(--space-4);
  overflow-x: auto;
  font-size: 0.875rem;
  line-height: 1.5;
}

.detail .body code {
  background: var(--bg-alt);
  padding: 0.125rem 0.375rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
  font-size: 0.875em;
}

.detail .body pre code {
  background: transparent;
  padding: 0;
}

.detail .body ul,
.detail .body ol {
  padding-left: var(--space-6);
  margin-bottom: var(--space-4);
}

.detail .body li {
  margin-bottom: var(--space-2);
}

.detail .body table {
  width: 100%;
  border-collapse: collapse;
  margin: var(--space-4) 0;
  font-size: 0.9rem;
}

.detail .body th,
.detail .body td {
  text-align: left;
  padding: var(--space-3);
  border-bottom: 1px solid var(--border);
}

.detail .body th {
  background: var(--bg-alt);
  font-weight: 600;
}

.detail .body blockquote {
  border-left: 4px solid var(--accent);
  padding-left: var(--space-4);
  margin-left: 0;
  color: var(--fg-muted);
  font-style: italic;
}

.back {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--fg-muted);
  font-size: 0.875rem;
  margin-bottom: var(--space-4);
}

.back:hover { color: var(--accent); }

/* ============================================
   Portfolio detail (project)
   ============================================ */
.project-hero {
  background: linear-gradient(135deg, var(--accent-soft) 0%, var(--bg) 100%);
  padding-block: var(--space-12) var(--space-10);
}

.project-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-4);
}

.project-meta .meta-item {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4);
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.875rem;
}

/* ============================================
   Forms
   ============================================ */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  max-width: 600px;
  margin-top: var(--space-6);
}

.form-row {
  display: flex;
  gap: var(--space-4);
}

.form-row > * {
  flex: 1;
}

label {
  display: block;
  font-weight: 500;
  margin-bottom: var(--space-2);
  color: var(--fg);
}

label .required {
  color: var(--error);
  margin-left: 2px;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="url"],
input[type="search"],
textarea,
select {
  width: 100%;
  padding: var(--space-3);
  background: var(--bg-elev);
  color: var(--fg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: inherit;
  font-size: 1rem;
  transition: border-color var(--transition), box-shadow var(--transition);
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

textarea {
  min-height: 140px;
  resize: vertical;
  font-family: inherit;
}

.checkbox {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  font-weight: 400;
  cursor: pointer;
}

.checkbox input { margin-top: 4px; }

/* Honeypot — visually hide but keep in DOM for screen readers to skip */
.honeypot {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
}

/* ============================================
   Alerts
   ============================================ */
.alert {
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius);
  margin-bottom: var(--space-4);
  border: 1px solid;
}

.alert.error {
  background: var(--error-soft);
  color: var(--error);
  border-color: color-mix(in srgb, var(--error) 30%, transparent);
}

.alert.success {
  background: var(--success-soft);
  color: var(--success);
  border-color: color-mix(in srgb, var(--success) 30%, transparent);
}

/* ============================================
   FAQ accordion
   ============================================ */
.faq-list {
  margin-top: var(--space-6);
}

.faq-item {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: var(--space-3);
  overflow: hidden;
}

.faq-item summary {
  padding: var(--space-4) var(--space-5);
  font-weight: 600;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-3);
  transition: background var(--transition);
}

.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  font-size: 1.25rem;
  color: var(--fg-muted);
  transition: transform var(--transition);
}

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

.faq-item summary:hover {
  background: var(--bg-alt);
}

.faq-item .answer {
  padding: 0 var(--space-5) var(--space-4);
  color: var(--fg-muted);
}

/* ============================================
   Testimonials
   ============================================ */
.testimonials {
  margin-top: var(--space-8);
}

.testimonial {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  position: relative;
}

.testimonial::before {
  content: "\201C";
  position: absolute;
  top: -10px;
  left: 16px;
  font-size: 4rem;
  color: var(--accent);
  font-family: Georgia, serif;
  line-height: 1;
}

.testimonial blockquote {
  margin: 0 0 var(--space-4);
  font-style: italic;
  color: var(--fg);
  line-height: 1.6;
}

.testimonial cite {
  display: block;
  font-style: normal;
  color: var(--fg-muted);
  font-size: 0.875rem;
}

.testimonial cite strong {
  display: block;
  color: var(--fg);
  font-weight: 600;
  margin-bottom: 2px;
}

/* ============================================
   Newsletter (inline form)
   ============================================ */
.newsletter {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
  text-align: center;
  margin-top: var(--space-8);
}

.newsletter h3 {
  margin-bottom: var(--space-2);
}

.newsletter p {
  color: var(--fg-muted);
  margin-bottom: var(--space-5);
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
}

.newsletter-form {
  display: flex;
  gap: var(--space-2);
  max-width: 480px;
  margin: 0 auto;
}

.newsletter-form input {
  flex: 1;
  min-width: 0;  /* allow shrinking */
}

@media (max-width: 600px) {
  .newsletter { padding: var(--space-5); }
  .newsletter-form { flex-direction: column; }
}

/* ============================================
   Footer
   ============================================ */
.site-footer {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  padding-block: var(--space-10) var(--space-6);
  margin-top: var(--space-12);
}

.site-footer .container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: var(--space-8);
}

.site-footer h4 {
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--fg-muted);
  margin-bottom: var(--space-3);
}

.site-footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-footer li { margin-bottom: var(--space-2); }

.site-footer a {
  color: var(--fg);
}

.site-footer a:hover { color: var(--accent); }

.site-footer .copyright {
  grid-column: 1 / -1;
  padding-top: var(--space-6);
  margin-top: var(--space-6);
  border-top: 1px solid var(--border);
  color: var(--fg-muted);
  font-size: 0.875rem;
  text-align: center;
}

/* ============================================
   Animations
   ============================================ */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.fade-up {
  animation: fadeUp 0.6s var(--transition-slow) backwards;
}

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

/* ============================================
   Print
   ============================================ */
@media print {
  .site-header, .site-footer, .skip-link, .theme-toggle, .mobile-menu-btn { display: none; }
  body { background: white; color: black; }
  a { color: black; text-decoration: underline; }
}

/* ============================================
   Language-specific typography tuning
   ============================================ */

/* Thai — slightly tighter line-height, no kerning issues */
html[lang="th"],
html[lang="th"] body {
  /* Thai script sits a touch higher than Latin at the same size;
     a slightly tighter line-height and a hair more letter-spacing
     improves readability for paragraph text. */
  line-height: 1.65;
}

html[lang="th"] .hero h1 {
  /* Long Thai headings wrap awkwardly with default line-height; give
     a hair more room so wrapped lines breathe. */
  line-height: 1.25;
}

/* Latin — default spacing already good. */
html[lang="en"] body {
  line-height: 1.6;
}
