:root {
  --ink: #162033;
  --muted: #617088;
  --line: #dbe2ec;
  --soft: #f4f7fb;
  --paper: #ffffff;
  --blue: #2481cc;
  --blue-dark: #1765a5;
  --green: #1f9d72;
  --amber: #d98b12;
  --shadow: 0 18px 50px rgba(31, 49, 76, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: Arial, "Noto Sans Thai", "Tahoma", sans-serif;
  line-height: 1.65;
  background: var(--paper);
}

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

a:hover {
  text-decoration: underline;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(14px);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(1120px, calc(100% - 32px));
  min-height: 68px;
  margin: 0 auto;
  gap: 18px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 700;
}

.brand-mark {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border-radius: 8px;
  color: white;
  background: var(--blue);
  font-size: 20px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 18px;
  font-size: 15px;
}

.hero {
  background:
    linear-gradient(100deg, rgba(255,255,255,0.98) 0%, rgba(255,255,255,0.92) 42%, rgba(255,255,255,0.58) 66%, rgba(255,255,255,0.24) 100%),
    url("assets/telegram-pc-hero.svg");
  background-size: cover;
  background-position: center right;
  border-bottom: 1px solid var(--line);
}

.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 40px;
  align-items: center;
  width: min(1120px, calc(100% - 32px));
  min-height: calc(100vh - 68px);
  max-height: 760px;
  margin: 0 auto;
  padding: 62px 0 72px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--blue-dark);
  font-weight: 700;
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.22;
}

h1 {
  max-width: 760px;
  font-size: clamp(36px, 7vw, 64px);
}

h2 {
  font-size: clamp(26px, 4vw, 38px);
}

h3 {
  font-size: 20px;
}

.lead {
  max-width: 710px;
  margin: 20px 0 0;
  color: #40506a;
  font-size: 19px;
}

.hero-actions,
.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 11px 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  color: var(--ink);
  font-weight: 700;
}

.button.primary {
  border-color: var(--blue);
  color: white;
  background: var(--blue);
}

.button.primary:hover {
  background: var(--blue-dark);
  text-decoration: none;
}

.button:hover {
  text-decoration: none;
  border-color: var(--blue);
}

.trust-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
  padding: 0;
  list-style: none;
}

.trust-strip li {
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255,255,255,0.78);
  color: #354763;
  font-size: 14px;
}

.status-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255,255,255,0.88);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--line);
}

.dots {
  display: flex;
  gap: 6px;
}

.dots span {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--line);
}

.panel-body {
  padding: 20px;
}

.version-line {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
}

.version-line strong {
  color: var(--ink);
}

.section {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 68px 0;
}

.section.tight {
  padding-top: 42px;
}

.section-intro {
  max-width: 820px;
  margin-bottom: 28px;
  color: var(--muted);
  font-size: 18px;
}

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

.card {
  min-height: 100%;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
}

.card.accent {
  border-color: rgba(36, 129, 204, 0.34);
  background: #f7fbff;
}

.icon {
  display: grid;
  width: 42px;
  height: 42px;
  margin-bottom: 16px;
  place-items: center;
  border-radius: 8px;
  background: #e8f3fd;
  color: var(--blue-dark);
  font-weight: 700;
}

.band {
  background: var(--soft);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.steps {
  display: grid;
  gap: 16px;
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
}

.step {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 16px;
  align-items: start;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}

.number {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 8px;
  color: white;
  background: var(--blue);
  font-weight: 700;
}

.download-box {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 24px;
  align-items: center;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbff;
}

.download-meta {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.meta-row {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
}

.meta-row strong {
  color: var(--ink);
}

.notice {
  margin-top: 18px;
  padding: 14px 16px;
  border-left: 4px solid var(--amber);
  background: #fff7e8;
  color: #674a13;
}

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

details {
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}

summary {
  cursor: pointer;
  font-weight: 700;
}

footer {
  border-top: 1px solid var(--line);
  background: #101827;
  color: #d9e1ef;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0;
  font-size: 14px;
}

.footer-inner a {
  color: white;
}

.error-layout {
  display: grid;
  min-height: calc(100vh - 68px);
  place-items: center;
  padding: 56px 16px;
  background:
    linear-gradient(100deg, rgba(255,255,255,0.98), rgba(255,255,255,0.82)),
    url("assets/telegram-pc-hero.svg");
  background-size: cover;
  background-position: center;
}

.error-box {
  width: min(760px, 100%);
  padding: 36px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255,255,255,0.94);
  box-shadow: var(--shadow);
}

.error-code {
  color: var(--blue-dark);
  font-size: 18px;
  font-weight: 700;
}

@media (max-width: 860px) {
  .hero-inner,
  .download-box {
    grid-template-columns: 1fr;
  }

  .status-panel {
    max-width: 460px;
  }

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

@media (max-width: 640px) {
  .nav {
    align-items: flex-start;
    flex-direction: column;
    padding: 12px 0;
  }

  .nav-links {
    flex-wrap: wrap;
    gap: 12px;
  }

  .hero-inner {
    min-height: auto;
    padding: 44px 0 54px;
  }

  .section {
    padding: 48px 0;
  }

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

  .footer-inner {
    flex-direction: column;
  }
}
