@font-face { font-family: "Noto Sans Thai"; src: url("/assets/fonts/NotoSansThai-Regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Noto Sans Thai"; src: url("/assets/fonts/NotoSansThai-Bold.ttf") format("truetype"); font-weight: 700; font-display: swap; }

:root {
  color-scheme: light;
  --ink: #102a43;
  --muted: #526579;
  --paper: #fbfbf7;
  --surface: #ffffff;
  --line: #d9e0e7;
  --soft: #eef3f8;
  --accent: #1d4ed8;
  --accent-dark: #173ea8;
  --good: #047857;
  --warn: #9a3412;
  --radius: 16px;
  --shadow: 0 14px 38px rgba(16, 42, 67, .09);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 17px/1.68 "Noto Sans", Inter, system-ui, -apple-system, sans-serif;
  text-rendering: optimizeLegibility;
}
html[lang^="th"] body { font-family: "Noto Sans Thai", "Noto Sans", sans-serif; }
a { color: var(--accent); text-decoration-thickness: .08em; text-underline-offset: .18em; }
a:hover { color: var(--accent-dark); }
a:focus-visible, button:focus-visible, select:focus-visible {
  outline: 3px solid #f59e0b;
  outline-offset: 3px;
}
.skip-link { position: fixed; left: 1rem; top: -5rem; z-index: 20; background: var(--ink); color: white; padding: .65rem 1rem; }
.skip-link:focus { top: 1rem; }
.site-header { border-bottom: 1px solid var(--line); background: rgba(251, 251, 247, .94); }
.header-inner, .shell { width: min(1240px, calc(100% - 48px)); margin-inline: auto; }
.header-inner { min-height: 72px; display: flex; align-items: center; gap: 30px; }
.brand { color: var(--ink); font-size: 1.05rem; font-weight: 820; letter-spacing: .02em; text-decoration: none; }
.brand-mark { display: inline-flex; align-items: end; justify-content: center; gap: 2px; width: 1.85rem; aspect-ratio: 1; margin-right: .5rem; padding: 6px; border: 2px solid currentColor; border-radius: 50%; }
.brand-mark i { display: block; width: 3px; border-radius: 2px; background: currentColor; }
.brand-mark i:nth-child(1) { height: 6px; }
.brand-mark i:nth-child(2) { height: 9px; }
.brand-mark i:nth-child(3) { height: 13px; }
.main-nav { display: flex; gap: 22px; margin-left: auto; }
.main-nav a { color: var(--ink); font-size: .9rem; font-weight: 680; text-decoration: none; }
.language-link { border-left: 1px solid var(--line); padding-left: 22px; }
.eyebrow { margin: 0 0 .55rem; color: var(--accent); font-size: .78rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.hero { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(360px, .95fr); gap: clamp(40px, 6vw, 92px); align-items: center; padding-block: clamp(64px, 8vw, 116px); }
.hero h1, .article-head h1 { margin: 0; font-size: clamp(2.55rem, 5.5vw, 5.4rem); line-height: .98; letter-spacing: -.055em; overflow-wrap: anywhere; }
.hero-copy { max-width: 720px; }
.hero-copy > p:not(.eyebrow) { max-width: 620px; margin: 1.5rem 0 0; color: var(--muted); font-size: 1.12rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 2rem; }
.button { display: inline-flex; align-items: center; min-height: 48px; padding: .65rem 1.05rem; border: 1px solid var(--ink); border-radius: 10px; color: var(--ink); font-weight: 760; text-decoration: none; }
.button.primary { border-color: var(--accent); background: var(--accent); color: white; }
.button.primary:hover { background: var(--accent-dark); color: white; }
.compat-card { position: relative; min-height: 430px; overflow: hidden; border: 1px solid #c9d4df; border-radius: 26px; background: #e9f0f6; box-shadow: var(--shadow); }
.compat-grid { position: absolute; inset: 0; opacity: .6; background-image: linear-gradient(#cbd7e2 1px, transparent 1px), linear-gradient(90deg, #cbd7e2 1px, transparent 1px); background-size: 28px 28px; }
.part { position: absolute; display: grid; place-items: center; border: 2px solid var(--ink); background: white; font: 750 .85rem/1.2 ui-monospace, monospace; text-align: center; box-shadow: 7px 7px 0 rgba(16, 42, 67, .12); }
.part.gpu { width: 62%; height: 32%; left: 8%; top: 17%; border-radius: 10px; }
.part.psu { width: 32%; aspect-ratio: 1.2; right: 8%; bottom: 14%; border-radius: 12px; }
.cable { position: absolute; width: 38%; height: 4px; left: 46%; top: 52%; background: var(--warn); transform: rotate(24deg); transform-origin: left; }
.status-chip { position: absolute; left: 8%; bottom: 10%; padding: .55rem .7rem; border-radius: 999px; background: var(--ink); color: white; font-size: .78rem; font-weight: 800; letter-spacing: .04em; }
.section { padding-block: 70px; border-top: 1px solid var(--line); }
.section-heading { display: flex; justify-content: space-between; gap: 24px; align-items: end; margin-bottom: 30px; }
.section-heading h2 { max-width: 720px; margin: 0; font-size: clamp(1.8rem, 3.5vw, 3rem); line-height: 1.08; letter-spacing: -.035em; }
.section-heading p { max-width: 430px; margin: 0; color: var(--muted); }
.topic-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.topic-card { min-height: 220px; padding: 26px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: var(--ink); text-decoration: none; transition: transform .18s, box-shadow .18s; }
.topic-card:hover { color: var(--ink); transform: translateY(-3px); box-shadow: var(--shadow); }
.topic-number { color: var(--accent); font: 750 .78rem ui-monospace, monospace; }
.topic-card h3 { margin: 2.7rem 0 .65rem; font-size: 1.3rem; line-height: 1.2; }
.topic-card p { margin: 0; color: var(--muted); font-size: .93rem; }
.latest-list { display: grid; border-top: 1px solid var(--line); }
.latest-item { display: grid; grid-template-columns: 150px minmax(0, 1fr) auto; gap: 24px; align-items: baseline; padding: 23px 0; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.latest-item time, .latest-item span { color: var(--muted); font-size: .84rem; }
.latest-item strong { font-size: 1.06rem; }
.method-strip { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 1px; overflow: hidden; border: 1px solid var(--ink); border-radius: var(--radius); background: var(--ink); }
.method-strip div { padding: 24px; background: var(--surface); }
.method-strip strong { display: block; margin-bottom: .45rem; }
.method-strip p { margin: 0; color: var(--muted); font-size: .9rem; }
.site-footer { margin-top: 80px; padding: 42px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: .86rem; }
.footer-inner { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.article-head { padding: 76px 0 46px; }
.article-head h1 { max-width: 990px; font-size: clamp(2.6rem, 6vw, 5.8rem); }
.article-dek { max-width: 760px; margin: 1.4rem 0 0; color: var(--muted); font-size: 1.16rem; }
.article-meta { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 1.6rem; color: var(--muted); font-size: .84rem; }
.article-layout { display: grid; grid-template-columns: 200px minmax(0, 760px) minmax(0, 1fr); gap: 42px; align-items: start; }
.toc { position: sticky; top: 24px; padding-top: 8px; font-size: .82rem; }
.toc strong { display: block; margin-bottom: .65rem; color: var(--muted); text-transform: uppercase; letter-spacing: .09em; }
.toc a { display: block; margin: .48rem 0; color: var(--ink); text-decoration: none; }
.article-body { min-width: 0; }
.article-body > p:first-of-type { font-size: 1.16rem; }
.article-body h2 { margin: 3.25rem 0 1rem; font-size: clamp(1.65rem, 3vw, 2.25rem); line-height: 1.16; letter-spacing: -.028em; }
.answer-box { margin: 0 0 2.1rem; padding: 24px; border-left: 5px solid var(--good); background: #edf9f4; }
.answer-box strong { display: block; margin-bottom: .35rem; font-size: 1.12rem; }
.fact-note { margin: 2rem 0; padding: 18px 20px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); font-size: .92rem; }
.wide-table { width: min(1100px, calc(100vw - 48px)); margin: 2rem 0 2rem 50%; transform: translateX(-50%); overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
table { width: 100%; min-width: 760px; border-collapse: collapse; font-size: .9rem; }
caption { padding: 15px 18px; color: var(--muted); font-size: .78rem; text-align: left; }
th, td { padding: 14px 16px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
th { background: var(--soft); font-size: .78rem; letter-spacing: .03em; }
tbody tr:last-child td { border-bottom: 0; }
.side-proof { margin-top: 10px; padding: 20px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); font-size: .82rem; }
.side-proof strong { display: block; margin-bottom: .5rem; }
.check-list, .fact-list { display: grid; gap: 10px; padding: 0; list-style: none; }
.check-list li, .fact-list li { display: flex; justify-content: space-between; gap: 18px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.result-chip { color: var(--good); white-space: nowrap; }
.claim-list { display: grid; gap: 18px; padding: 0; list-style: none; }
.claim-list li { padding: 18px 20px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.claim-list details { margin-top: .55rem; color: var(--muted); font-size: .86rem; }
.claim-list summary { cursor: pointer; font-weight: 700; }
.claim-list blockquote { margin: .8rem 0 0; padding-left: 1rem; border-left: 3px solid var(--line); }
.fixture-banner { padding: .7rem 1rem; background: #fff4df; color: #713f12; font-size: .8rem; font-weight: 700; text-align: center; }
.language-page { min-height: calc(100vh - 72px); padding-block: clamp(60px, 10vw, 130px); }
.language-page h1 { max-width: 850px; margin: 0; font-size: clamp(2.8rem, 7vw, 6.4rem); line-height: .95; letter-spacing: -.06em; }
.language-page > p { max-width: 650px; color: var(--muted); font-size: 1.08rem; }
.language-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-top: 48px; }
.language-card { display: flex; min-height: 124px; flex-direction: column; justify-content: space-between; padding: 20px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--ink); text-decoration: none; }
.language-card:hover { border-color: currentColor; color: var(--accent); }
.language-card small { color: var(--muted); }
.language-card.disabled { opacity: .62; cursor: not-allowed; }

@media (max-width: 1180px) {
  .main-nav { display: none; }
  .language-link { margin-left: auto; }
  .hero { grid-template-columns: 1fr; }
  .compat-card { min-height: 360px; }
  .topic-grid { grid-template-columns: 1fr 1fr; }
  .article-layout { grid-template-columns: minmax(0, 760px); justify-content: center; }
  .toc, .side-proof { display: none; }
  .language-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
  body { font-size: 16px; line-height: 1.64; }
  .header-inner, .shell { width: min(100% - 32px, 1240px); }
  .header-inner { min-height: 62px; }
  .language-link { padding-left: 14px; font-size: .8rem; }
  .hero { padding-block: 52px; }
  .hero h1 { font-size: clamp(2.45rem, 14vw, 4rem); }
  .compat-card { min-height: 300px; }
  .section { padding-block: 52px; }
  .section-heading { display: block; }
  .section-heading p { margin-top: 1rem; }
  .topic-grid, .method-strip { grid-template-columns: 1fr; }
  .latest-item { grid-template-columns: 1fr auto; gap: 8px 14px; }
  .latest-item time { grid-column: 1 / -1; }
  .article-head { padding: 48px 0 30px; }
  .article-head h1 { font-size: clamp(2.35rem, 13vw, 4.3rem); }
  .article-layout { display: block; }
  .check-list li, .fact-list li { align-items: start; }
  .wide-table { width: calc(100vw - 32px); }
  .language-grid { grid-template-columns: 1fr; }
}

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