/* Blog article page (Concept C, approved 2026-09-29): contents list beside the text, reading progress, boxes, checklists,
   recommended mosaics in pages of 4 x 2, compact related articles. Scoped under .ixb so the site header, menu, footer
   and FB/LINE dock stay as they are. Built from blog-redesign/prototype/src/article.css. */
.ixb {
  --navy: #003761; --blue: #2478b6; --ink: #1d2a36; --text: #2c3a47; --muted: #66737f; --line: #e3e8ed; --soft: #f4f7fa; --sand: #f6f1ea;
  --tip: #0f7a55; --tip-bg: #eef8f3; --warn: #a15c00; --warn-bg: #fff6e8; --info: #2478b6; --info-bg: #eef5fb;
  --ease: cubic-bezier(.22,.61,.36,1);
  --measure: 700px; --wide: 1040px; --page: 1240px;
  --body: 'Open Sans', system-ui, sans-serif; --head: 'Open Sans', system-ui, sans-serif; --display: 'Cormorant Garamond', Georgia, serif;
  --fs: 16px; --lh: 1.72;
  color: var(--text); font-family: var(--body); font-size: var(--fs); line-height: var(--lh);
  padding-bottom: 72px; -webkit-font-smoothing: antialiased;
}
.ixb.ixb-lang-th { --body: 'Sarabun', 'Prompt', system-ui, sans-serif; --head: 'Prompt', 'Sarabun', sans-serif; --display: 'Noto Serif Thai', 'Prompt', serif; --fs: 16.5px; --lh: 1.8; }
.ixb *, .ixb *::before, .ixb *::after { box-sizing: border-box; }
.ixb a { color: var(--blue); text-underline-offset: 3px; }
.ixb img { display: block; max-width: 100%; height: auto; }

/* ---------- reading column + headings ---------- */
.ixb .ixb-body, .ixb .ixb-head, .ixb .ixb-col { max-width: var(--measure); margin-inline: auto; padding-inline: 20px; }
.ixb .ixb-body > * { margin: 0 0 1.15em; }
.ixb .ixb-body p { font-size: var(--fs); line-height: var(--lh); color: var(--text); }
.ixb .ixb-lead { font-size: calc(var(--fs) * 1.06) !important; color: var(--ink) !important; }
.ixb h1, .ixb h2, .ixb h3, .ixb h4 { font-family: var(--head); color: var(--ink); text-wrap: balance; }
.ixb h1 { margin: 0 0 .45em; font-size: clamp(26px, 3.2vw, 36px); line-height: 1.18; font-weight: 700; letter-spacing: -.01em; }
.ixb.ixb-lang-th h1 { line-height: 1.35; letter-spacing: 0; }
.ixb .ixb-body h2 { margin: 2em 0 .55em !important; font-size: clamp(21px, 2.2vw, 24px); line-height: 1.3; font-weight: 700; scroll-margin-top: 130px; }
.ixb .ixb-body h3 { margin: 1.6em 0 .4em !important; font-size: 18px; line-height: 1.4; font-weight: 600; scroll-margin-top: 130px; }
.ixb .ixb-body h4 { margin: 1.3em 0 .3em !important; font-size: 14.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--navy); }
.ixb.ixb-lang-th .ixb-body h4 { text-transform: none; letter-spacing: 0; font-size: 16px; }
.ixb .ixb-body ul, .ixb .ixb-body ol { padding-left: 1.3em; }
.ixb .ixb-body li { margin: .35em 0; padding-left: .2em; }
.ixb .ixb-body li::marker { color: var(--blue); }
.ixb .ixb-body strong { color: var(--ink); font-weight: 600; }

/* header */
.ixb .ixb-head { padding-top: 36px; }
.ixb .ixb-crumbs ol { display: flex; flex-wrap: wrap; gap: 4px 0; margin: 0 0 22px; padding: 0; list-style: none; font-size: 13px; color: var(--muted); }
.ixb .ixb-crumbs li { display: inline-flex; align-items: center; }
.ixb .ixb-crumbs li + li::before { content: "/"; margin: 0 9px; color: #b4bec7; }
.ixb .ixb-crumbs a { color: var(--muted); text-decoration: none; }
.ixb .ixb-crumbs a:hover { color: var(--blue); }
.ixb .ixb-crumbs [aria-current] { max-width: 34ch; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; display: inline-block; color: var(--ink); }
.ixb .ixb-cat { margin: 0 0 10px; font: 600 12.5px/1.2 var(--body); letter-spacing: .12em; text-transform: uppercase; color: var(--blue); }
.ixb.ixb-lang-th .ixb-cat { letter-spacing: .04em; font-size: 14px; }
.ixb .ixb-excerpt { margin: 0 0 16px; font-size: calc(var(--fs) * 1.05); line-height: 1.6; color: var(--muted); }
.ixb .ixb-meta { display: flex; flex-wrap: wrap; gap: 4px 0; margin: 0; font-size: 13px; color: var(--muted); }
.ixb .ixb-meta span + span::before { content: "·"; margin: 0 10px; color: #b4bec7; }

/* figures */
.ixb .ixb-fig { margin: 2em auto; }
.ixb .ixb-fig img { width: 100%; border-radius: 14px; background: var(--soft); }
.ixb .ixb-fig figcaption { margin-top: 10px; font-size: 13.5px; line-height: 1.5; color: var(--muted); }
.ixb .ixb-credit { color: #9aa6b1; }
.ixb .ixb-fig--wide { width: min(var(--wide), calc(100vw - 40px)); margin-left: 50%; transform: translateX(-50%); }
.ixb .ixb-hero { max-width: var(--wide); padding-inline: 20px; margin: 30px auto 40px; }

/* boxes */
.ixb .ixb-box { padding: 16px 18px; font-size: calc(var(--fs) * .95); border-radius: 14px; border-left: 3px solid; }
.ixb .ixb-box ul { margin: 0; padding-left: 1.2em; }
.ixb .ixb-box p { margin: 0; }
.ixb .ixb-box > :not(.ixb-box-title) + * { margin-top: 8px; }
.ixb .ixb-box-title { display: flex; align-items: center; gap: 8px; margin: 0 0 8px !important; font: 700 14px/1.3 var(--head); letter-spacing: .02em; }
.ixb .ixb-box-title svg { width: 20px; height: 20px; flex: none; }
.ixb .ixb-box--tip { background: var(--tip-bg); border-color: var(--tip); } .ixb .ixb-box--tip .ixb-box-title { color: var(--tip); }
.ixb .ixb-box--warning { background: var(--warn-bg); border-color: var(--warn); } .ixb .ixb-box--warning .ixb-box-title { color: var(--warn); }
.ixb .ixb-box--info { background: var(--info-bg); border-color: var(--info); } .ixb .ixb-box--info .ixb-box-title { color: var(--info); }
.ixb .ixb-check { list-style: none; padding: 0 !important; display: grid; gap: 2px; }
.ixb .ixb-check li { display: flex; gap: 12px; align-items: flex-start; padding: 8px 0 !important; margin: 0 !important; border-bottom: 1px solid var(--line); }
.ixb .ixb-check svg { width: 22px; height: 22px; flex: none; margin-top: 3px; color: var(--tip); }

/* recommended mosaics and related articles */
.ixb .ixb-products .ixb-kicker, .ixb .ixb-kicker { margin: 0 0 4px !important; font: 600 12px/1.3 var(--body); letter-spacing: .12em; text-transform: uppercase; color: var(--blue); }
.ixb.ixb-lang-th .ixb-kicker { letter-spacing: .03em; font-size: 13.5px; }
.ixb .ixb-btn:focus-visible, .ixb a:focus-visible, .ixb button:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }

/* ---------- C · Long-form: sticky contents beside the text, progress bar ---------- */
.ixb-c .ixb-head { max-width: calc(var(--measure) + 316px); padding-left: 296px; }
.ixb-c .ixb-hero { max-width: calc(var(--measure) + 316px); padding-left: 296px; }
.ixb-c .ixb-layout-c { display: grid; grid-template-columns: 240px minmax(0, var(--measure)); gap: 36px; max-width: calc(var(--measure) + 316px); margin: 0 auto; padding-inline: 20px; }
.ixb-c .ixb-layout-c .ixb-body { padding: 0; margin: 0; }
.ixb-c .ixb-toc { position: sticky; top: 150px; align-self: start; max-height: calc(100vh - 180px); overflow: auto; }
.ixb-c .ixb-toc-toggle { display: none; }
.ixb-c .ixb-toc-title { margin: 0 0 10px; font: 700 12px/1.3 var(--body); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.ixb-c.ixb-lang-th .ixb-toc-title { letter-spacing: .03em; font-size: 14px; }
.ixb-c .ixb-toc ol { margin: 0; padding: 0; list-style: none; border-left: 2px solid var(--line); }
.ixb-c .ixb-toc a { display: flex; gap: 10px; margin-left: -2px; padding: 6px 0 6px 14px; border-left: 2px solid transparent; font-size: 14px; line-height: 1.45; color: var(--muted); text-decoration: none; transition: color 200ms, border-color 200ms; }
.ixb-c .ixb-toc-l3 a { padding-left: 34px; font-size: 13px; }
.ixb-c .ixb-toc-n { font-weight: 700; color: #b4bec7; }
.ixb-c .ixb-toc a:hover { color: var(--ink); }
.ixb-c .ixb-toc a.is-active { color: var(--navy); font-weight: 600; border-left-color: var(--blue); }
.ixb-c .ixb-toc a.is-active .ixb-toc-n { color: var(--blue); }
.ixb-c .ixb-hero img, .ixb-c .ixb-fig img { aspect-ratio: 16 / 9; object-fit: cover; }
.ixb-c .ixb-hero { margin-top: 22px; margin-bottom: 30px; }
.ixb-c .ixb-fig--wide { width: 100%; margin-left: 0; transform: none; }
.ixb-c .ixb-fig { margin: 1.6em 0; }
.ixb-c .ixb-fig.ixb-hero { margin: 22px auto 30px; }            /* the cover keeps its centring (the rule above is for images in the text) */
.ixb-c .ixb-progress { position: fixed; left: 0; right: 0; top: 0; z-index: 1040; height: 3px; pointer-events: none; }
.ixb-c .ixb-progress span { display: block; height: 100%; background: var(--blue); transform-origin: 0 50%; transform: scaleX(0); }

.ixb .ixb-quote { margin: 1.8em 0 !important; padding: 4px 0 4px 22px; border-left: 3px solid var(--blue); }
.ixb .ixb-quote p { margin: 0; font-size: calc(var(--fs) * 1.15) !important; line-height: 1.6 !important; font-style: italic; color: var(--ink) !important; }
.ixb.ixb-lang-th .ixb-quote p { font-style: normal; }
.ixb .ixb-quote cite { display: block; margin-top: 8px; font-size: 13px; font-style: normal; color: var(--muted); }
.ixb .ixb-hr { border: 0; height: 1px; background: var(--line); margin: 2.2em 0 !important; }
.ixb-c .ixb-no-toc { grid-template-columns: 240px minmax(0, var(--measure)); }
/* recommended mosaics: pages of 4 x 2 */
.ixb .ixb-pp { margin: 2.4em 0 0 !important; padding-top: 22px; border-top: 1px solid var(--line); }
.ixb .ixb-pp-h { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.ixb .ixb-body .ixb-pp-title { margin: 0 !important; font: 700 19px/1.3 var(--head); color: var(--ink); }
.ixb .ixb-pp-intro { margin: 3px 0 0 !important; font-size: 13.5px !important; line-height: 1.5 !important; color: var(--muted) !important; }
.ixb .ixb-pp-nav { display: flex; align-items: center; gap: 6px; flex: none; }
.ixb .ixb-pp-nav[hidden] { display: none; }
.ixb .ixb-pp-nav button { display: grid; place-items: center; width: 32px; height: 32px; padding: 0; border: 1px solid var(--line); border-radius: 50%; background: #fff; color: var(--navy); cursor: pointer; transition: border-color 200ms, background 200ms; }
.ixb .ixb-pp-nav button:hover { border-color: var(--blue); background: var(--soft); }
.ixb .ixb-pp-nav svg { width: 14px; height: 14px; }
.ixb .ixb-pp-prev svg { transform: rotate(90deg); } .ixb .ixb-pp-next svg { transform: rotate(-90deg); }
.ixb .ixb-pp-count { min-width: 40px; text-align: center; font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.ixb .ixb-pp-view { overflow: hidden; }
.ixb .ixb-pp-track { display: flex; transition: transform 560ms var(--ease); }
.ixb .ixb-pp-page { flex: 0 0 100%; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-rows: auto; gap: 14px 12px; }
.ixb .ixb-mp { display: flex; flex-direction: column; gap: 2px; min-width: 0; text-decoration: none; color: var(--ink); }
.ixb .ixb-mp-img { display: block; aspect-ratio: 1; overflow: hidden; border-radius: 10px; background: var(--soft); margin-bottom: 6px; }
.ixb .ixb-mp-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 600ms var(--ease); }
.ixb .ixb-mp:hover .ixb-mp-img img { transform: scale(1.05); }
.ixb .ixb-mp-name { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font: 600 13.5px/1.3 var(--head); }
.ixb .ixb-mp-meta { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 11.5px; line-height: 1.3; color: var(--muted); }
.ixb .ixb-pp-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; }
.ixb .ixb-pp-more { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 6px 16px; border: 1px solid var(--navy); border-radius: 999px; background: #fff; font: 600 13.5px var(--head); color: var(--navy); cursor: pointer; transition: background 200ms, color 200ms; }
.ixb .ixb-pp-more:hover { background: var(--navy); color: #fff; }
.ixb .ixb-pp-more[hidden] { display: none; }
.ixb .ixb-pp-more svg { width: 14px; height: 14px; }
.ixb .ixb-pp-all { font-size: 13.5px; font-weight: 600; text-decoration: none; }

/* related articles, compact: 4 x 2 small cards */
.ixb .ixb-rel2 { max-width: calc(var(--measure) + 316px); margin: 48px auto 0; padding: 26px 20px 0; border-top: 1px solid var(--line); }
.ixb .ixb-rel2-h { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.ixb .ixb-rel2 h2 { margin: 0; font: 700 19px/1.3 var(--head); color: var(--ink); }
.ixb .ixb-rel2-h a { display: inline-flex; align-items: center; gap: 6px; font-size: 13.5px; font-weight: 600; text-decoration: none; }
.ixb .ixb-rel2-h svg { width: 14px; height: 14px; }
.ixb .ixb-rel2-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.ixb .ixb-rc { display: flex; gap: 10px; align-items: flex-start; min-width: 0; padding: 8px; border: 1px solid var(--line); border-radius: 12px; text-decoration: none; color: var(--ink); transition: border-color 200ms, box-shadow 200ms; }
.ixb .ixb-rc:hover { border-color: #c9d6e0; box-shadow: 0 6px 16px rgba(0,40,70,.07); }
.ixb .ixb-rc-img { display: block; width: 72px; flex: none; aspect-ratio: 1; overflow: hidden; border-radius: 8px; background: var(--soft); }
.ixb .ixb-rc-img img { width: 100%; height: 100%; object-fit: cover; }
.ixb .ixb-rc-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ixb .ixb-rc-cat { font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--blue); }
.ixb.ixb-lang-th .ixb-rc-cat { letter-spacing: 0; font-size: 12px; }
.ixb .ixb-rc-title { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; font: 600 13px/1.4 var(--head); }
.ixb .ixb-legacy { overflow-x: auto; }
.ixb .ixb-legacy table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.ixb .ixb-legacy td, .ixb .ixb-legacy th { padding: 8px 10px; border: 1px solid var(--line); }

/* ---------- tablet and phone ---------- */
@media (max-width: 999.98px) {
  .ixb-c .ixb-head, .ixb-c .ixb-hero { padding-left: 20px; max-width: var(--measure); }
  .ixb-c .ixb-layout-c { display: block; max-width: var(--measure); }
  .ixb-c .ixb-toc { position: sticky; top: 72px; z-index: 20; max-height: none; overflow: visible; margin: 0 -20px 24px; padding: 0 20px; background: rgba(255,255,255,.96); backdrop-filter: blur(6px); border-bottom: 1px solid var(--line); }
  .ixb-c .ixb-toc-toggle { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 50px; padding: 0; border: 0; background: none; font: 600 14px var(--head); color: var(--ink); text-align: left; cursor: pointer; }
  .ixb-c .ixb-toc-toggle svg { width: 16px; height: 16px; margin-left: auto; transition: transform 300ms var(--ease); }
  .ixb-c .ixb-toc.is-open .ixb-toc-toggle svg { transform: rotate(180deg); }
  .ixb-c .ixb-toc-current { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-weight: 400; color: var(--muted); }
  .ixb-c .ixb-toc-panel { display: none; max-height: 60vh; overflow: auto; padding-bottom: 14px; }
  .ixb-c .ixb-toc.is-open .ixb-toc-panel { display: block; }
  .ixb-c .ixb-toc-title { display: none; }
}
@media (max-width: 999.98px) { .ixb .ixb-rel2 { max-width: var(--measure); } .ixb .ixb-rel2-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 991.98px) { .ixb-c .ixb-toc { top: 64px; } }
@media (max-width: 640px) {
  .ixb { --fs: 15.5px; }
  .ixb.ixb-lang-th { --fs: 16px; }
  .ixb .ixb-head { padding-top: 22px; }
  .ixb .ixb-hero { padding-inline: 0; margin: 20px auto 28px; }
  .ixb .ixb-hero img { border-radius: 0 !important; }
  .ixb .ixb-hero figcaption { padding-inline: 20px; }
  .ixb .ixb-pp-page { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ixb .ixb-rel2-grid { grid-template-columns: 1fr; gap: 8px; }
  .ixb .ixb-rc-img { width: 64px; }
  .ixb .ixb-pp-h { align-items: flex-start; }
}
@media (prefers-reduced-motion: reduce) { .ixb * { transition: none !important; animation: none !important; } }

/* Old article pages (international blog) show the same boxes and checklists without the new template */
.blog blockquote.ixb-tip, .blog blockquote.ixb-warning, .blog blockquote.ixb-info { margin: 1.4em 0; padding: 14px 18px; border-left: 3px solid; border-radius: 14px; font-style: normal; }
.blog blockquote.ixb-tip { background: #eef8f3; border-color: #0f7a55; } .blog blockquote.ixb-warning { background: #fff6e8; border-color: #a15c00; } .blog blockquote.ixb-info { background: #eef5fb; border-color: #2478b6; }
.blog blockquote[class^="ixb-"] > p:first-child > strong { color: #1d2a36; }
.blog blockquote[class^="ixb-"] p:last-child, .blog blockquote[class^="ixb-"] ul:last-child { margin-bottom: 0; }
.blog ul.ixb-check { list-style: none; padding-left: 0; }
.blog ul.ixb-check > li { position: relative; padding-left: 30px; }
.blog ul.ixb-check > li::before { content: "\2713"; position: absolute; left: 6px; top: 0; font-weight: 700; color: #0f7a55; }

/* CMS Preview only (unsaved article) */
.ixb-preview-bar { position: sticky; top: 0; z-index: 1050; padding: 8px 16px; background: #14202b; color: #fff; font: 600 13.5px/1.4 'Open Sans', system-ui, sans-serif; text-align: center; }
