/* Bài viết: danh sách, thẻ bài, trang chi tiết. Màu theo biến chủ đề (--accent, --dark) và màu chuyên mục (--tile). */
.crumbs-light { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; color: #bdbdbd; font-weight: 600; }
.crumbs-light a { color: #e6e6e6; text-decoration: none; }
.crumbs-light a:hover { color: #fff; text-decoration: underline; }
.blog-head { color: #fff; }
.blog-head p { max-width: 720px; }
.blog-search { display: flex; gap: 8px; max-width: 460px; margin-top: 20px; }
.blog-search input { flex: 1; min-width: 0; padding: 11px 16px; border: 1px solid rgb(255 255 255 / .25); border-radius: 999px; background: rgb(255 255 255 / .08); color: #fff; }
.blog-search input::placeholder { color: #cfcfcf; }
.blog-search .btn { padding: 11px 22px; }

.blog-wrap { padding-top: 24px; padding-bottom: 24px; }
.blog-tabs { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 24px; scrollbar-width: none; }
.blog-tabs a { flex: none; padding: 8px 16px; border: 1px solid var(--line); border-radius: 999px; font-size: .875rem; font-weight: 600; text-decoration: none; transition: border-color .15s, background .15s; }
.blog-tabs a small { margin-left: 2px; color: var(--muted); font-weight: 500; }
.blog-tabs a:hover { border-color: var(--tile, var(--accent)); }
.blog-tabs a[aria-current] { background: var(--ink); border-color: var(--ink); color: #fff; }
.blog-tabs a[aria-current] small { color: #cfcfcf; }

.post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 290px), 1fr)); gap: 28px 24px; margin-bottom: 40px; }
.post-card { display: flex; flex-direction: column; min-width: 0; }
.post-media { display: block; aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--r, 16px); background: var(--mist); }
.post-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease, ease); }
.post-card:hover .post-media img { transform: scale(1.04); }
.post-art { display: flex; align-items: flex-end; width: 100%; height: 100%; padding: 18px; color: #fff;
  background: radial-gradient(90% 120% at 100% 0%, color-mix(in srgb, var(--tile) 85%, transparent), transparent 70%), linear-gradient(135deg, var(--dark), color-mix(in srgb, var(--tile) 35%, var(--dark))); }
.post-art b { font-family: var(--display); font-size: 1.375rem; line-height: 1.1; letter-spacing: -.01em; }
.post-body { padding-top: 14px; }
.post-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; font-size: .75rem; color: var(--muted); }
.post-cat { color: color-mix(in srgb, var(--tile, var(--accent)) 70%, var(--ink)); font-weight: 700; text-decoration: none; }
.post-cat:hover { text-decoration: underline; }
.post-title { margin-top: 6px; font-family: var(--display); font-size: 1.1875rem; line-height: 1.3; letter-spacing: -.01em; }
.post-title a { text-decoration: none; }
.post-title a:hover { color: var(--accent); }
.post-excerpt { margin-top: 8px; color: var(--muted); font-size: .9rem; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
@media (min-width: 900px) {
  .post-card-big { grid-column: 1 / -1; display: grid; grid-template-columns: 1.25fr 1fr; gap: 32px; align-items: center; }
  .post-card-big .post-body { padding: 0; }
  .post-card-big .post-title { font-size: clamp(1.6rem, 2.6vw, 2.25rem); }
  .post-card-big .post-excerpt { font-size: 1rem; -webkit-line-clamp: 4; }
}
.post-grid-3 { grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); }

/* Trang chi tiết */
.article-head { background: radial-gradient(55% 170% at 92% -20%, color-mix(in srgb, var(--tile) 60%, transparent), transparent), var(--dark); color: #fff; padding: clamp(28px, 4vw, 56px) var(--gutter) 0; }
.article-head-in { max-width: 860px; margin: 0 auto; padding-bottom: clamp(28px, 4vw, 48px); }
.article-head h1 { font-family: var(--display); font-weight: 700; font-size: clamp(1.9rem, 4.2vw, 3.1rem); line-height: 1.14; letter-spacing: -.025em; }
.article-lede { margin-top: 14px; font-size: clamp(1rem, 1.4vw, 1.15rem); color: #d9d9d9; max-width: 760px; }
.article-byline { display: flex; align-items: center; gap: 12px; margin-top: 22px; font-size: .875rem; line-height: 1.45; }
.byline-avatar { display: grid; place-items: center; flex: none; width: 42px; height: 42px; border-radius: 50%; background: var(--accent); color: var(--on-accent); font-weight: 700; }
.muted-light { color: #bdbdbd; }
.article-cover { max-width: 1080px; margin: 0 auto; transform: translateY(40px); margin-top: -12px; }
.article-cover img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--r-lg, 24px); box-shadow: 0 20px 50px rgb(0 0 0 / .25); }
.article-head:has(.article-cover) + .article-layout { padding-top: 76px; }

.article-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; max-width: 1180px; margin: 0 auto; padding-top: 32px; padding-bottom: 32px; }
@media (min-width: 961px) {
  .article-layout { grid-template-columns: 260px minmax(0, 760px); justify-content: center; gap: 56px; }
  .article-aside { position: sticky; top: 92px; align-self: start; max-height: calc(100vh - 110px); overflow-y: auto; }
}
.toc { border: 1px solid var(--line); border-radius: var(--r, 16px); padding: 14px 16px; }
.toc summary { cursor: pointer; font-weight: 700; font-size: .875rem; }
.toc ol { list-style: none; margin: 10px 0 0; padding: 0; }
.toc li a { display: block; padding: 5px 0 5px 10px; border-left: 2px solid var(--line); font-size: .8125rem; line-height: 1.4; color: var(--muted); text-decoration: none; }
.toc li.toc-3 a { padding-left: 22px; }
.toc li a:hover, .toc li a.on { color: var(--ink); border-left-color: var(--accent); }
.toc li a.on { font-weight: 600; }
.share { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 16px; font-size: .8125rem; }
.share span { color: var(--muted); }
.share a, .share button { padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; background: none; color: inherit; font-size: .8125rem; text-decoration: none; cursor: pointer; }
.share a:hover, .share button:hover { border-color: var(--accent); color: var(--accent); }

.takeaways { margin-bottom: 28px; padding: 20px 22px; border-radius: var(--r, 16px); background: color-mix(in srgb, var(--tile) 9%, var(--paper)); border: 1px solid color-mix(in srgb, var(--tile) 28%, transparent); }
.takeaways h2 { margin: 0 0 8px; font-size: 1rem; text-transform: uppercase; letter-spacing: .04em; }
.takeaways ul { margin: 0; padding-left: 20px; }
.takeaways li { margin: 6px 0; }

.article-body { font-size: 1.0625rem; line-height: 1.75; overflow-wrap: anywhere; }
.article-body > * + * { margin-top: 1.05em; }
.article-body h2 { margin-top: 1.9em; font-family: var(--display); font-size: clamp(1.4rem, 2.2vw, 1.75rem); line-height: 1.25; letter-spacing: -.015em; scroll-margin-top: 90px; }
.article-body h3 { margin-top: 1.5em; font-size: 1.2rem; line-height: 1.35; scroll-margin-top: 90px; }
.article-body ul, .article-body ol { padding-left: 1.4em; }
.article-body li + li { margin-top: .4em; }
.article-body a { color: color-mix(in srgb, var(--accent) 80%, var(--ink)); text-underline-offset: 3px; }
.article-body strong { font-weight: 700; }
.article-body .note { padding: 14px 18px; border-left: 4px solid var(--accent); border-radius: 0 var(--r-sm, 10px) var(--r-sm, 10px) 0; background: var(--mist); font-size: .98rem; }
.article-body figure { margin: 1.6em 0; }
.article-body figure img { display: block; width: 100%; height: auto; border-radius: var(--r, 16px); }
.article-body figcaption { margin-top: 8px; font-size: .8125rem; color: var(--muted); text-align: center; }
.table-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r-sm, 10px); }
.article-body table { width: 100%; border-collapse: collapse; font-size: .9375rem; line-height: 1.5; }
.article-body th, .article-body td { padding: 10px 14px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.article-body thead th { background: var(--mist); font-weight: 700; white-space: nowrap; }
.article-body tbody tr:last-child td { border-bottom: 0; }

.faq { margin-top: 44px; }
.faq > h2, .sources h2 { font-family: var(--display); font-size: clamp(1.4rem, 2.2vw, 1.75rem); margin-bottom: 12px; scroll-margin-top: 90px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { display: flex; justify-content: space-between; gap: 16px; padding: 16px 0; cursor: pointer; list-style: none; overflow: hidden; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; flex: none; font-size: 1.4rem; line-height: 1; color: var(--accent); transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq summary h3 { flex: 1; min-width: 0; font-size: 1.0625rem; line-height: 1.4; overflow-wrap: anywhere; }
.faq details p { padding: 0 0 16px; color: #333; }
.sources { margin-top: 40px; font-size: .9rem; }
.sources ol { padding-left: 1.3em; color: var(--muted); }
.sources li { margin: 6px 0; overflow-wrap: anywhere; }
.sources a { color: inherit; }
.article-note { margin-top: 32px; padding: 14px 16px; border-radius: var(--r-sm, 10px); background: var(--mist); color: var(--muted); font-size: .8125rem; }
.article-foot { margin-top: 24px; }
.article-products { padding-top: 8px; }
.related-posts { padding-top: 24px; }
.related-posts h2 { font-family: var(--display); font-size: clamp(1.5rem, 2.6vw, 2rem); margin-bottom: 18px; }
@media (max-width: 960px) { .article-cover { transform: translateY(24px); } .article-head:has(.article-cover) + .article-layout { padding-top: 52px; } }
